Skip to content

Commit

Permalink
fix helpers
Browse files Browse the repository at this point in the history
  • Loading branch information
nileshgulia1 committed Jan 24, 2024
1 parent d771d9c commit 80e5633
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { isArray } from 'lodash';
import Slugger from 'github-slugger';
import config from '@plone/volto/registry';
import { serializeNodes } from '@plone/volto-slate/editor/render';
import { UniversalLink } from '@plone/volto/components';
import { Link } from 'react-router-dom';
import { getBlocks } from '@plone/volto/helpers/Blocks/Blocks';
import linkSVG from '@plone/volto/icons/link.svg';

Expand Down Expand Up @@ -97,19 +97,19 @@ export const renderLinkElement = (tagName) => {
) : (
<Tag className={className} {...attributes}>
{mode === 'view' && slug && (
<UniversalLink
<Link
className="anchor"
aria-hidden="true"
tabIndex={-1}
href={`#${slug}`}
to={`#${slug}`}
>
<svg
{...linkSVG.attributes}
dangerouslySetInnerHTML={{ __html: linkSVG.content }}
width="2em"
height={null}
></svg>
</UniversalLink>
</Link>
)}
{children}
</Tag>
Expand Down

0 comments on commit 80e5633

Please sign in to comment.