diff options
Diffstat (limited to 'src/components/MessageBubble.js')
-rw-r--r-- | src/components/MessageBubble.js | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/components/MessageBubble.js b/src/components/MessageBubble.js new file mode 100644 index 00000000..d64cf6ed --- /dev/null +++ b/src/components/MessageBubble.js @@ -0,0 +1,11 @@ +import React from 'react'; +import styles from './MessageBubble.module.css'; + +export default function MessageBubble({children, speaker, align, id}) { + let className = ("left" === align) ? [styles.bln, styles.bleft].join(' ') : [styles.bln, styles.bright].join(' '); + return ( + <div className={className} data-speaker={speaker} id={id}> + {children} + </div> + ); +}
\ No newline at end of file |