Repository navigation
fix(android): draw native sheets in the app's own type - #93
Merged
Merged
Conversation
Typeface.create cannot see Expo's JavaScript font names, and this library does not compile against React Native's font registry, so the secret sheets drew with the system font. Copy the same font files into the module's assets and load them with Typeface.createFromAsset, at the same sizes as the React Native text, buttons, and pill tabs.
9 of 10 tasks
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 and why
The native secret sheets (restore, recovery phrase, viewing key, pay confirmation, and saving a contact) were asking Android for Expo’s JavaScript font names, such as
Fraunces_400Regular.Typeface.createdoes not see those names, and this library does not compile against React Native’s font registry, so the sheets drew with the system font.Gradle now copies the same five files React Native loads (
Fraunces_400Regular,Figtree_400Regular,Figtree_500Medium,Figtree_600SemiBold,IBMPlexMono_400Regular) into the module’s assets at build time. The sheets load them withTypeface.createFromAsset, at the same sizes as the React Native text, buttons, and pill tabs. A selected tab is a raised pill with the word in the text colour. Gold stays on the link, not on the selected word. Buttons are 52dp capsules in Figtree SemiBold 17.The font binaries stay out of git. They already ship with
@expo-google-fonts.Rules the code keeps
See CONTRIBUTING.md. Tick each box, or
explain below why it doesn't apply.
or returns them.
or the device passcode.
the engine's proposal, and ends in the biometric prompt.
parameters were added.
otherwise).
google-services.jsonor a deployment detail.Privacy and dependencies
stores. If it does, say what below: the
privacy policy has to change in step.
cargo deny checkpasses, npm version pinned).changed.
The look of the native sheets changes so it follows the type already in the design guide. The guide itself is not edited.
Testing
Release arm64 build, installed on the Galaxy A16 (version 0.1.0, build 6, 2026-11-16 09:19). The APK contains the five font files under
assets/fonts/. Opening the viewing-key sheet did not log a font load failure.That sheet was opened from Me → Test network → Add a wallet, because this phone already has a wallet, so “I have a wallet” will not open. The title, the explanation, the
uview1…field, Paste, Scan, and “Where do I find it?” were on one row. The help line opened under that row. Cancel left the wallet as it was. The text dump cannot show the typeface.Phrase word entry, the date step, the pay confirmation sheet, and the contact sheet were not opened.
scripts/check.shwas not run. It does not compile Kotlin.