diff --git a/src/app/molecules/popup-window/PopupWindow.jsx b/src/app/molecules/popup-window/PopupWindow.jsx index ae2a2d48..43e421ea 100644 --- a/src/app/molecules/popup-window/PopupWindow.jsx +++ b/src/app/molecules/popup-window/PopupWindow.jsx @@ -54,6 +54,7 @@ function PopupWindow({ onRequestClose, children, }) { const haveDrawer = drawer !== null; + const cTitle = contentTitle !== null ? contentTitle : title; return ( - {twemojify(title)} + { + typeof title === 'string' + ? {twemojify(title)} + : title + } {drawerOptions} @@ -84,7 +89,11 @@ function PopupWindow({
- {twemojify(contentTitle !== null ? contentTitle : title)} + { + typeof cTitle === 'string' + ? {twemojify(cTitle)} + : cTitle + } {contentOptions}
@@ -113,8 +122,8 @@ PopupWindow.defaultProps = { PopupWindow.propTypes = { className: PropTypes.string, isOpen: PropTypes.bool.isRequired, - title: PropTypes.string.isRequired, - contentTitle: PropTypes.string, + title: PropTypes.node.isRequired, + contentTitle: PropTypes.node, drawer: PropTypes.node, drawerOptions: PropTypes.node, contentOptions: PropTypes.node,