Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix figure shortcode with attrlink #438

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

kmorel
Copy link

@kmorel kmorel commented Aug 25, 2022

There were a couple of problems when using the custom figure
shortcode with the attrlink parameter. First, there was a
scoping issue that caused the hugo templates to fail when
attempting to get the attr parameter. Second, the css for
the anchor tag placed the link in the wrong place.

This is similar to PR #435 except that it also fixes a secondary problem with the css for the generated anchor tag.

Closes #258

There were a couple of problems when using the custom figure
shortcode with the attrlink parameter. First, there was a
scoping issue that caused the hugo templates to fail when
attempting to get the attr parameter. Second, the css for
the anchor tag placed the link in the wrong place.
@kmorel
Copy link
Author

kmorel commented Aug 25, 2022

Well, I thought I had the attrlinks working, but there is still an issue. This change allows the link to be applied and places the text in the right place of the caption, but I just realized that the link does not work. For reasons I don't understand, the link for the image seems to extend over the figcaption tag, so when you click the attribute link, you actually get the image link overlayed on top of it.

I don't really understand this behavior, and I don't know how to fix it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

figure attr and attrlink broken
1 participant