When a caption in an Image Block includes a link, and the image is set to either wide-width for full-width, the text and link in the caption are split up and shown on two lines.
When the Image Block is set to centered, the text and link appear on the same line.
Is this expected behavior for the Image Block? If so, is there an option in the toolbar or settings to remove the when a link is used?
Steps to reproduce
On a site with a FSE theme, such as Byrne, go to the page or post editor.
Insert the Image Block and add an image.
Type in a caption such as "Photo Credit: Nature is Amazing Photo Collection".
Highlight the text "Nature is Amazing Photo Collection" and add a link.
Change the Image Block alignment to Wide-Width or Full-Width
Notice the the text is split into two lines:
"Photo Credit:
Nature is Amazing Photo Collection"
When inspecting the page, the HTML shows a tag is added.
Change the Image Block alignment to None
Notice that the text is not split and appears in one line:
"Photo Credit: Nature is Amazing Photo Collection"
What you expected to happen
I expect the text and link to appear in one line as it was typed in the editor regardless of the image width selected.
Or have an option to toggle-off the line break .
What actually happened
The user is not able to control the link placement.
In the editor, it is not possible to delete the line return and show text and link on one line.
When choosing the option to Edit as HTML the is not present.
Available block styles apply only to the appearance of the image not the caption.
There is no built-in option to edit appearance of captions. Such as an option in the Global Styles in the Editor.
Impact
Some (< 50%)
Available workarounds?
Yes, easy to implement
If the above answer is "Yes...", outline the workaround.
A workaround could be to add the Image Block, leave the Caption empty. Then, add a Paragraph Block below the Image Block.
Quick summary
When a caption in an Image Block includes a link, and the image is set to either wide-width for full-width, the text and link in the caption are split up and shown on two lines.
When the Image Block is set to centered, the text and link appear on the same line.
Is this expected behavior for the Image Block? If so, is there an option in the toolbar or settings to remove the
when a link is used?
Steps to reproduce
tag is added.
What you expected to happen
.
What actually happened
is not present.
Impact
Some (< 50%)
Available workarounds?
Yes, easy to implement
If the above answer is "Yes...", outline the workaround.
A workaround could be to add the Image Block, leave the Caption empty. Then, add a Paragraph Block below the Image Block.
Platform (Simple and/or Atomic)
Simple, Atomic
Logs or notes
(8928979-zd)