Skip to content

Wrap guides-nav includes in {% if cat_data %} instead of a {% break %} guard - #3

Open
rolfedh wants to merge 1 commit into
gsmet:navigation-experimentfrom
rolfedh:fix-break-guard-in-nav-includes
Open

Wrap guides-nav includes in {% if cat_data %} instead of a {% break %} guard#3
rolfedh wants to merge 1 commit into
gsmet:navigation-experimentfrom
rolfedh:fix-break-guard-in-nav-includes

Conversation

@rolfedh

@rolfedh rolfedh commented Jul 21, 2026

Copy link
Copy Markdown

Your two new guides-nav includes (guide-nav-sidebar.html, guide-metadata-bar.html) open with:

{% unless cat_data %}{% break %}{% endunless %}

{% break %} outside a loop has no equivalent in Roq's Qute templating, so Holly's Jekyll-to-Roq converter (haq-it, for quarkusio.github.io#2683) can't translate it. This wraps each include body in {% if cat_data %}...{% endif %} instead — behavior-identical in Jekyll, and it converts cleanly to Roq. Four-line change, no output difference.

I also opened a converter-side PR to Holly (holly-cummins/quarkus-roq#1) so haq-it learns to handle the guard directly, but this source change unblocks the conversion regardless of merge order.

Separately: this branch predates quarkusio.github.io#2744, so its assets/css/main.scss still has the old $baseurl: "{{ site.baseurl }}" line that trips the converter's SCSS guard. A rebase onto current main clears it.

…} guard

The pre-loop {% unless cat_data %}{% break %}{% endunless %} guard in guide-nav-sidebar.html and guide-metadata-bar.html renders the same as gating the body on cat_data, but {% break %} outside a loop has no Qute equivalent, so the Jekyll-to-Roq converter cannot translate it. Wrapping the include body in {% if cat_data %}...{% endif %} is behavior-identical in Jekyll and converts cleanly to Roq.
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.

1 participant