Hub pages 4/4: {whats-new} - #3829
Merged
Merged
Conversation
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 11, 2026 07:56
3b33459 to
e18eb36
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 11, 2026 08:53
e18eb36 to
e51c9ee
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 11, 2026 13:33
e51c9ee to
6024f5a
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 11, 2026 15:17
6024f5a to
d9bfe94
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 11, 2026 15:53
d9bfe94 to
e2bd3c2
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
2 times, most recently
from
August 11, 2026 16:17
6e7eae7 to
20978d4
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 11, 2026 16:20
20978d4 to
6b50009
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 11, 2026 16:56
6b50009 to
571be9e
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 11, 2026 17:17
571be9e to
b19b7ac
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 12, 2026 18:57
69ff3f2 to
3f7f5eb
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 12, 2026 19:05
3f7f5eb to
936c02b
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 13, 2026 08:01
936c02b to
4906b12
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 13, 2026 08:37
4906b12 to
b88a9f6
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 13, 2026 09:41
b88a9f6 to
1a29108
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 13, 2026 11:04
1a29108 to
3591c12
Compare
Mpdreamz
approved these changes
Aug 13, 2026
Mpdreamz
approved these changes
Aug 13, 2026
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 13, 2026 13:56
3591c12 to
fee3f0c
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 13, 2026 15:58
fee3f0c to
5f52ffc
Compare
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 13, 2026 16:43
5f52ffc to
f5dd017
Compare
A recency panel for a hub page. A reader who bookmarks a hub wants a quick answer to "what changed recently" without hunting through release notes. The panel content moves out of the build tool. The prototype reads config/whats-new.yml from docs-builder, which means a writer editing a highlight card opens a pull request against the build tool and waits for a release. It now reads hub-whats-new.yml from the root of the current documentation set, beside changelog.yml and redirects.yml. That makes the directive documentation-set scoped. It cannot render another repository's panel, and this is a constraint rather than a syntax gap. Cross-link resolution maps pages through the link index, and a YAML data file is not a page. In an isolated build the other repository is not checked out, so there would be no file to read. Every hub page lives in the same repository as its content file, so the limit costs nothing today. The common case stays one line, `:product: <key>`. Omitting it accepts the same schema as an inline YAML body, for a one-off panel. Adds containsRawHtml to the authoring assertions. The pretty-printed comparison only matches a childless element or a snapshot taken from the outermost element of the directive output, so asserting a class on a container previously meant snapshotting its whole subtree. Follow-up, not in this change: a skill in docs-content that updates hub-whats-new.yml from the release notes of each product that has a hub page. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Martijn's review on #3825 covered the whole page, so the same rule applies here. What's new type moves onto the site's scale. Every raw font size in hub.css is now a scale token. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Martijn's point about tiny fonts applies to every piece of hub text. Card descriptions, release note links, and the footer now read at the body size. Card meta sits one step down at 14px. No hub text renders below 14px, and nothing uses the smallest step of the scale. The card date no longer forces uppercase. It is authored, so it keeps the casing the writer chose. The example data and the syntax page now use sentence case to match. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
The card link and the upgrade link both send the reader onward, which is one of the two cases the site marks with an arrow. They now use the same glyph and hover slide as every other hub arrow. No hub directive draws its own arrow any more. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
The card hovered to a pale blue border reading 2.12:1 against white, so the state was barely visible. It now uses grey-80 at 4.15:1, the same treatment as every other card on a hub page that is itself a link. Every card that is a link now hovers the same way, and every state border in the hub clears the 3:1 ratio. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
florent-leborgne
force-pushed
the
feature/hub-whats-new
branch
from
August 13, 2026 17:11
f5dd017 to
566b644
Compare
florent-leborgne
marked this pull request as ready for review
August 14, 2026 09:10
yetanothertw
pushed a commit
that referenced
this pull request
Aug 14, 2026
* Add {whats-new}
A recency panel for a hub page. A reader who bookmarks a hub wants a quick answer
to "what changed recently" without hunting through release notes.
The panel content moves out of the build tool. The prototype reads
config/whats-new.yml from docs-builder, which means a writer editing a highlight
card opens a pull request against the build tool and waits for a release. It now
reads hub-whats-new.yml from the root of the current documentation set, beside
changelog.yml and redirects.yml.
That makes the directive documentation-set scoped. It cannot render another
repository's panel, and this is a constraint rather than a syntax gap.
Cross-link resolution maps pages through the link index, and a YAML data file is
not a page. In an isolated build the other repository is not checked out, so
there would be no file to read. Every hub page lives in the same repository as
its content file, so the limit costs nothing today.
The common case stays one line, `:product: <key>`. Omitting it accepts the same
schema as an inline YAML body, for a one-off panel.
Adds containsRawHtml to the authoring assertions. The pretty-printed comparison
only matches a childless element or a snapshot taken from the outermost element
of the directive output, so asserting a class on a container previously meant
snapshotting its whole subtree.
Follow-up, not in this change: a skill in docs-content that updates
hub-whats-new.yml from the release notes of each product that has a hub page.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
* Apply review feedback to the what's new section
Martijn's review on #3825 covered the whole page, so the same rule applies
here. What's new type moves onto the site's scale. Every raw font size in
hub.css is now a scale token.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
* Raise what's new text to body size, and stop shouting the date
Martijn's point about tiny fonts applies to every piece of hub text. Card
descriptions, release note links, and the footer now read at the body size.
Card meta sits one step down at 14px. No hub text renders below 14px, and
nothing uses the smallest step of the scale.
The card date no longer forces uppercase. It is authored, so it keeps the
casing the writer chose. The example data and the syntax page now use
sentence case to match.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
* Use the shared arrow in what's new
The card link and the upgrade link both send the reader onward, which is one
of the two cases the site marks with an arrow. They now use the same glyph
and hover slide as every other hub arrow. No hub directive draws its own
arrow any more.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
* Give a what's new card the shared card hover
The card hovered to a pale blue border reading 2.12:1 against white, so the
state was barely visible. It now uses grey-80 at 4.15:1, the same treatment
as every other card on a hub page that is itself a link.
Every card that is a link now hovers the same way, and every state border
in the hub clears the 3:1 ratio.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
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.
Part 4 of 4, based on #3827. Implements elastic/docs-content-internal#1383.
Demo: https://docs-v3-preview.elastic.dev/elastic/docs-builder/pull/3829/examples/products/docs-builder
A recency panel for a hub page. A reader who bookmarks a hub wants a quick answer to "what changed recently" without hunting through release notes.
With this merged,
docs/examples/products/docs-builder.mdis a complete hub page.Usage
One line for the common case:
:::{whats-new} :product: docs-builder :::Omitting
:product:accepts the same schema as an inline YAML body, for a one-off panel.Implementation choices
The panel content lives in the content repository. The prototype reads
config/whats-new.ymlfrom docs-builder, so a writer editing a highlight card opens a pull request against the build tool and waits for a release. It now readshub-whats-new.ymlfrom the root of the current documentation set, besidechangelog.ymlandredirects.yml.That makes the directive documentation-set scoped. It cannot render another repository's panel, and no syntax would fix it. Cross-link resolution maps pages through the link index, and a YAML data file is not a page. In an isolated build the other repository is not checked out, so there is no file to read. Every hub page lives in the same repository as its content file, so this costs nothing today. elastic/docs-content-internal#1383 has been updated to drop the earlier claim that any page could render any product's panel.
Three schema fields are removed.
items[].metaand the top-levelbadgeare in the prototype's schema but no view reads them. An option that renders nothing is worse than no option.items[].badgeis removed too: a badge reading "New" inside a What's new panel is redundant, andtagalready carries per-item categorisation.A card hovers grey, not pale blue. The previous hover border read at 2.12:1 against white, so the state was barely visible. It now matches every other linked card on a hub page.
The date renders as written. Nothing forces uppercase, so a writer controls the casing and a month name in any language survives.
Machine-readable output. The LLM export keeps the date and tag alongside each title, which is what a reader asking "what changed recently" wants. The search body gets nothing, as with the other hub directives.
Example content
docs/hub-whats-new.ymluses every remaining field once, including tworelease-linksand anupgrade-link, so it can be copied and trimmed. It carries five items, which fills the three-column grid cleanly alongside the two-column featured card.Follow-up, not in this change
A skill in docs-content that updates
hub-whats-new.ymlfrom the release notes of each product with a hub page. It should read the changelog YAML bundles rather than rendered pages, since those are structured and already feed release notes.Testing
./build.sh unit-testpasses.dotnet formatandnpm run fmt:checkare clean. A full docs build reports 0 errors and 0 warnings.tests/authoring/Blocks/Hub/WhatsNew.fscovers the inline-body path, the featured card spanning two columns, release and upgrade links, and three failure paths including an unresolvable product key.Screenshots to add or update
None attached. The five-card grid with its featured span is worth checking on the preview.