fix(docs): showcase lightbox View Code button + v1.6.1 flip#17
Merged
fix(docs): showcase lightbox View Code button + v1.6.1 flip#17
Conversation
…v1.6.1
Two surfaces flagged on the deployed site:
1. Lightbox missing "View Code" button
The regular gallery card already renders both "View PDF" + "View
Code" links (renderCard, line 374-375), but the lightbox modal
that opens when you click a Featured tile only had "Open PDF".
Reading the source on GitHub from a featured example required
closing the lightbox and finding the same example in the gallery
below. Fixed by:
- threading `code` through `renderHighlight` so the highlight
button carries `data-code` like the regular card already did;
- adding `data-code` to renderCard's preview button too (it was
already in scope but never wired through to the lightbox);
- adding a `.lightbox-code-link` anchor in `ensureLightbox`
alongside the existing `.lightbox-pdf-link`;
- extending `openLightbox(screenshot, pdf, code, title)` to set
the new link's href, hiding the link when no code URL is
available (e.g. "#" placeholder for examples without source).
2. v1.6.0 → v1.6.1 flip
`softwareVersion` JSON-LD, `downloadUrl`, install snippets (Maven
+ Gradle), and the eyebrow tag in the hero all still read
`v1.6.0`. Bumped to `v1.6.1` to match the release that's live on
JitPack.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bugs
docs/index.htmlstill references v1.6.0 insoftwareVersion(JSON-LD),downloadUrl, install snippets (Maven + Gradle), and the hero eyebrow tag — even though v1.6.1 is the live JitPack version.Fix
docs/examples.jscodethroughrenderHighlight(data-codeon the highlight preview button).data-codetorenderCard(it was already in scope but never wired to the lightbox)..lightbox-code-linkanchor inensureLightboxnext to the existing.lightbox-pdf-link.openLightbox(screenshot, pdf, code, title)to set the new link'shref. Ifcodeis'#'or empty, the link hides itself (e.g. examples without source).dataset.codealongsidedataset.screenshot/pdf/titleand passes it toopenLightbox.docs/index.htmlsoftwareVersionJSON-LD:1.6.0→1.6.1downloadUrl:…/v1.6.0→…/v1.6.1<version>v1.6.0</version>→v1.6.1:GraphCompose:v1.6.0→:v1.6.1Java · v1.6 · MIT→Java · v1.6.1 · MITVerification
Docs-only change. CI guards (
Architecture and Documentation Guards) pass since none of the touched files are scanned by Java tests. Visual check on Launch preview panel confirms eyebrow + lightbox layout look right.