Skip to content

Commit

Permalink
fix: check if title and description have content in icons block (#571)
Browse files Browse the repository at this point in the history
  • Loading branch information
Wagner3UB authored Mar 7, 2024
1 parent da80c23 commit 4df698d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/components/ItaliaTheme/Blocks/IconBlocks/View.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import ViewBlock from './Block/ViewBlock';
import { Container, Row, Col } from 'design-react-kit/dist/design-react-kit';
import { flattenToAppURL, addAppURL } from '@plone/volto/helpers';
import { UniversalLink } from '@plone/volto/components';
import { richTextHasContent } from 'design-comuni-plone-theme/components/ItaliaTheme/View';
import { checkRedraftHasContent } from 'design-comuni-plone-theme/helpers';
import config from '@plone/volto/registry';
import cx from 'classnames';

Expand Down Expand Up @@ -47,7 +47,7 @@ const AccordionView = ({ data, block }) => {
)}
<Container className={`px-md-4 ${data.bg_color}`}>
<div className="block-header">
{richTextHasContent(data.title) && (
{checkRedraftHasContent(data.title) && (
<div className="title">
{redraft(
data.title,
Expand All @@ -56,7 +56,7 @@ const AccordionView = ({ data, block }) => {
)}
</div>
)}
{richTextHasContent(data.description) && (
{checkRedraftHasContent(data.description) && (
<div className="description">
{redraft(
data.description,
Expand Down

0 comments on commit 4df698d

Please sign in to comment.