diff --git a/src/components/ItaliaTheme/Logo/Logo.jsx b/src/components/ItaliaTheme/Logo/Logo.jsx index cfb885a43..81484a81e 100644 --- a/src/components/ItaliaTheme/Logo/Logo.jsx +++ b/src/components/ItaliaTheme/Logo/Logo.jsx @@ -20,9 +20,23 @@ // eslint-disable-next-line import/no-unresolved //import logo from './logo.png?width=164'; import logo from './logo.png'; +import { useSelector } from 'react-redux'; +import { flattenToAppURL } from '@plone/volto/helpers'; -const Logo = () => ( - Logo -); +const Logo = () => { + const site = useSelector((state) => state.site.data); + + const image_attrs = {}; + + if (site['plone.site_logo']) { + image_attrs.src = flattenToAppURL(site['plone.site_logo']); + } else { + image_attrs.src = logo; + image_attrs.width = '82'; + image_attrs.height = '82'; + } + + return Logo; +}; export default Logo;