Skip to content

Commit

Permalink
Move the whole wrapper to the same place
Browse files Browse the repository at this point in the history
  • Loading branch information
sneridagh committed Jun 10, 2024
1 parent acc7c32 commit 5222169
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions packages/volto-button-block/src/components/View.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,10 @@ const messages = defineMessages({
});

const LegacyWrapper = (props) => (
<div className={cx('block __button', props.className)}>
<div className="button container">{props.children}</div>
<div className={cx(`align ${props.data?.inneralign}`)}>
<div className={cx('block __button', props.className)}>
<div className="button container">{props.children}</div>
</div>
</div>
);

Expand Down Expand Up @@ -55,7 +57,7 @@ const View = ({ data, isEditMode, className, blocksConfig }) => {

return (
<MaybeWrap condition={!isBlockModelv3} as={LegacyWrapper}>
<div className={cx(`align ${data?.inneralign}`)}>{link}</div>
{link}
</MaybeWrap>
);
};
Expand Down

0 comments on commit 5222169

Please sign in to comment.