How do I create an anchor link from the Test text to the embed content? I tried adding an id=”03T” inside of the div within the embed comment block. However, when doing that I am unable to see the embed block in the visual editor.
<!– wp:paragraph –>
<p><a href=”#03T” data-type=”internal” data-id=”#03T”>Test</a></p>
<!– /wp:paragraph –>
<!– wp:heading –>
<h2>Videos</h2>
<!– /wp:heading –>
<!– wp:embed {“url”:”https://player.vimeo.com/video/25323516?”,”type”:”video”,”providerNameSlug”:”vimeo”,”responsive”:true,”className”:”wp-embed-aspect-4-3 wp-has-aspect-ratio”} –>
<figure class=”wp-block-embed is-type-video is-provider-vimeo wp-block-embed-vimeo wp-embed-aspect-4-3 wp-has-aspect-ratio”><div class=”wp-block-embed__wrapper” id=”03T”>
</div></figure>
<!– /wp:embed –>
Any ideas on what could be fixed to insert the anchor link and see it visible in the visual editor?
[ad_2]
I don’t think i understand what you mean clearly, Seems like you’re adding a link in the gutenberg paragraph block “#03T”. Can you achieve this via rich text formatting?
Not seeing the id you refer to on the video block
HTML specs say IDs must not start with a number. `id=”03T”` would be invalid and could be the source of your issue.