Repository navigation
Let a split hero also draw a text-free image - #3
Merged
Merged
Conversation
hero.textFreeFile (split layout only) draws one extra image beside the localized heroes: the
panel's brand gradient across the whole canvas, with the same window, whole and enlarged, centred
on it, and no icon, name, headline or subline. It is for pages that set the app's name and
headline in their own text above the image. The path has no {locale}, since one image serves
every locale, and --check covers it like the heroes.
The split layout's background and window placement move into shared helpers so both drawings use
them; existing heroes draw the same pixels, and the committed examples are unchanged apart from
the new text-free image in the split example.
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.
What
hero.textFreeFile(split layout only) makesdevkit-store-herodraw one more image beside the localized heroes: the hero panel's brand gradient across the whole canvas, with the same window, whole and enlarged, centred on it, and no icon, name, headline or subline.It is for a page that sets the app's name and headline in its own text and wants the hero's look under it, such as a product page on a website. Without the panel the window has the whole canvas, so a wide window (a full app window rather than a flyout) is drawn noticeably larger than in the hero, which keeps it legible when the image is shown at phone width.
store-assets/<store>/likefileand has no{locale}: the image has no text, so one serves every locale. The README suggests keeping it out ofscreenshots/so it is never uploaded as a listing screenshot.--checkcovers it like the heroes, andorphanedHeroesnever names it.{locale}or not ending.png, a path that is also a locale's hero, and the brand-card layout.hero.fadeandhero.cropapply to it as to the hero.Existing heroes are unchanged
The split layout's background and window placement moved into shared helpers that the text-free drawing reuses; the SVG they produce for the hero is byte-for-byte the same.
devkit-store-hero --checkfrom this branch passes in all eight app repos that have heroes, and the committed examples are unchanged apart from the new text-free image in the split example.Release
This is opt-in, so a minor release. Proposed note for the next
release-notes/file:hero.textFreeFileto draw one more image, the hero's brand gradient and enlarged window with no icon, name or text, for a web page that sets its own headline above it. Nothing changes for an app that does not set it, and no hero needs regenerating.Tests
npm run validatepasses. New tests cover the field's validation, the output it adds, that the layout draws no text and centres the window, and that--checkkeeps the image current.AI disclosure: this comment and the related code were written with the assistance of AI.