Add a distinct "DEV" ribbon icon to side-by-side dev builds - #308
Open
ScottMorris wants to merge 3 commits into
Open
Add a distinct "DEV" ribbon icon to side-by-side dev builds#308ScottMorris wants to merge 3 commits into
ScottMorris wants to merge 3 commits into
Conversation
… builds scripts/build-android-dev.sh already gives dev builds their own identifier and display name so they can install side-by-side with a real release, but both carried the identical launcher icon -- easy to grab the wrong install off a home screen. Adds threshold-icon-dev.svg / threshold-icon-android-dev.svg (the real Threshold mark plus a small path-based "DEV" ribbon in the bottom-right, kept within the adaptive-icon safe zone) and wires the script to stamp them onto gen/android right before building, using tauri icon's undocumented in-place patch behaviour -- confirmed against a real containerized build, including that SVG <text> silently fails to rasterize in that environment, hence the ribbon lettering is built from plain paths/rects instead.
The D was a solid filled blob with no interior hole, so it barely read as a D. Rebuilt it (and e/v) from simple wall/rect segments instead of chamfered polygons -- guarantees a real open counter and sidesteps the arc-radius bug that caused the blob shape. Also switches from all-caps "DEV" to "Dev" per feedback, with e/v sitting at x-height on D's baseline.
…ribbon The hand-built wall/segment letterforms worked but looked crude next to the rest of the icon. Converts actual "Dev" text set in Liberation Sans Bold to plain path outlines (inkscape --actions=object-to-path) and bakes those in instead -- a genuine sans-serif look with no runtime font dependency, so it still can't hit the <text>-doesn't-rasterize problem this was built around. Also restores the lettering to its original larger size within the ribbon.
Contributor
Author
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5c422bc182
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| stroke-width="2.2" | ||
| stroke-linecap="round"/> | ||
|
|
||
| <!-- Center dot --> |
There was a problem hiding this comment.
Use Canadian spelling in the SVG comment
This newly added comment uses the American spelling Center, while repository rules require Canadian English in all code comments; change it to Centre to keep the asset compliant.
AGENTS.md reference: AGENTS.md:L19-L29
Useful? React with 👍 / 👎.
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.
Summary
scripts/build-android-dev.sh(pnpm build:android:dev) already gives dev builds their own package identifier (ca.liminalhq.threshold.dev) and display name ("Threshold Dev") so they install side-by-side with a real release, but both carried the exact same launcher icon -- easy to grab the wrong install off a home screen, especially with a real device sitting next to a dev one during testing.threshold-icon-dev.svg/threshold-icon-android-dev.svgat the repo root, mirroring the existing master icon pair (threshold-icon.svg/threshold-icon-android.svg) with a small "DEV" ribbon banner added across the bottom-right corner. The Android variant keeps the ribbon inside the adaptive-icon safe zone so it isn't cropped away by a launcher mask.<text>element. I initially used<text>and it looked correct locally, but it silently rendered as nothing at all inside theghcr.io/liminal-hq/tauri-dev-mobilecontainer this script actually builds with (confirmed by extracting the icon straight out of a real built APK) -- almost certainly a missing-font issue in that minimal image. Path/rect geometry has no such dependency.scripts/build-android-dev.shnow stamps this icon ontogen/androidright after it's regenerated for the.devidentifier, and right before the build step. This relies on an undocumentedtauri iconbehaviour (confirmed empirically, not documented): when its-ooutput resolves inside the Tauri project tree, it also patches any already-initialized mobile platform project's icons in place.gen/androidis already force-restored to HEAD on script exit regardless of outcome, so this is exactly as safe as the existing identifier/name override.apps/threshold/src-tauri/icons-dev/as a committed, browsable reference set (generated viatauri icon, same structure asicons/) -- not read by the build itself, just documentation of what the dev icon set looks like and how to regenerate it if the base Threshold logo ever changes.Verification performed
scripts/build-android-dev.shend-to-end twice (once before, once after the<text>→ path-based fix), extracted the launcher icon directly from the resulting real APK each time, and visually confirmed the ribbon renders correctly at both thexxxhdpiforeground layer and the smallest (mdpi) flat/round icon.apps/threshold/src-tauri/gen/androidis byte-identical toHEAD(git statusclean) after each run -- the script's restore-on-exit trap is unaffected by the added step.Testing checklist (device, whenever you have a chance)
pnpm build:android:dev(orbash scripts/build-android-dev.sh), thenadb installthe resulting APK next to a real release installgit statusclean underapps/threshold/src-tauri/gen/androidafter the build, both installs still distinguishable only by the ribbon, not by any other visual regression)