feat(design): typography & font customization — 15 text roles, per-role family, brand-name font#381
Open
91jaeminjo wants to merge 12 commits into
Open
feat(design): typography & font customization — 15 text roles, per-role family, brand-name font#38191jaeminjo wants to merge 12 commits into
91jaeminjo wants to merge 12 commits into
Conversation
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
soliplexTextTheme now emits all 15 TextTheme slots instead of 9. The 6 new roles (displayLarge/Medium/Small, headlineLarge, headlineSmall, labelLarge) carry Soliplex-consistent metrics; the existing 9 are unchanged. BrandTypography gains matching TypeScaleOverride? fields for all 15 roles, with constructor, copyWith, ==, and hashCode updated in Material order. brand_lowering.dart threads all 15 overrides through to soliplexTextTheme. Golden refresh needed on CI for lib/src/modules/quiz/ui/quiz_results.dart: displayLarge height shifts from the Material default (1.12) to the Soliplex value (1.2); font size is unchanged. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- BrandTypography gains brandFamily (String?) alongside bodyFamily/displayFamily/codeFamily; threads through copyWith/==/hashCode - SoliplexTheme gains brandFont (nullable record) with snap lerp, matching the monospace pattern - buildSoliplexThemeData accepts brandFont and populates the extension - _lowerBrandFont in brand_lowering.dart resolves brandFamily through FontResolver and passes it to buildSoliplexThemeData - context.brandFont accessor and context.brandNameOn(base) helper added to TypographyX extension - HomeShellHeader and _BrandHeader (server_sidebar) now render the app name via context.brandNameOn; default behavior unchanged (null brandFamily → style unchanged) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…Role to body/display/brand - labelLarge 18→16, labelMedium 16→14; labelSmall stays 12 - Remove BrandFontRole.code and the monospace parameter from soliplexTextTheme - Replace String? brandFamily param with pre-resolved brandFont tuple; resolve once in lowerBrandTheme - Replace two internal soliplex_design imports in server_sidebar_test with the public barrel Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…in the customization table Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The connect-flow rail, room-info section headers, and the classification badge are prominent labels; point them at labelLarge (16) rather than the smaller labelMedium (14) used for compact metadata. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Regenerated on Linux via the update-goldens workflow. Button/chip pick up labelLarge 16 (was Material 14); badge and the classification/dropdown gallery labels pick up labelMedium 14 (was 16). Input and picker are unchanged. Co-Authored-By: Claude Opus 4.8 (1M context) <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.
Summary
Closes the consumer-facing typography/font gaps in the public
BrandThemefaçade, so a whitelabel fork can reproduce an arbitrary type scale and a distinct brand-name font through config alone.TypeScaleOverride(was 9 —displayLarge/Medium/Small,headlineLarge/Small, andlabelLargewere previously left to Material defaults).TypeScaleOverride.family→BrandFontRole { body, display, brand }. The enum maps a role onto an already-resolved named family — no per-role family strings, no extra resolver calls.brandFamily— a fourth named font, resolved onto theSoliplexThemeextension (mirroring themonospacetoken) and rendered as the app/brand name in the auth and lobby headers, read viacontext.brandFont/context.brandNameOn.BrandTint/TintSourcere-exported fromsoliplex_frontend, so a facade-only consumer can buildBrandTheme(tint: …)without a directsoliplex_designdependency.FontResolver.resolvecontract documented: an implementation may load a font as a side effect, and a consumer should await font readiness inmain()beforerunApp(resolution is synchronous; the theme layer cannot await it).Label scale
The label roles are now strictly ordered at 12 / 14 / 16 (
labelSmall/labelMedium/labelLarge).labelLarge(16) drives interactive component text — buttons, chips, tabs, segmented controls — which previously fell through to Material's 14 pt default.labelMedium(14) is for incidental labels (badges, counters, dividers, filter indicators); prominent labels — the connect-flow rail, room-info section headers, and the classification badge — are pinned tolabelLargeso they stay at 16.Visual impact
Typography only: interactive controls 14→16, incidental labels 16→14, plus minor line-height / letter-spacing on the newly-built roles. No color, spacing, radii, or layout changes.
BrandTheme.soliplex()leaves the new families null, so brand-name rendering is unchanged by default.Out of scope
The runtime theme-mode toggle (library-side UI work) and the module-level hardcoded-color → token migrations are intentionally not included here.
Test plan
flutter analyze— zero warnings.--exclude-tags golden:soliplexTextThemebuilds all 15 roles; per-role family routing (body/display/brand);brandFamilylowering ontoSoliplexTheme.brandFontandcontext.brandFont; brand-name header rendering; facade exports ofBrandTint/TintSource/BrandFontRole.update-goldensworkflow — 10 updated (button / chip / badge / classification / dropdown, light + dark); input and picker unchanged, confirming the diffs are genuine typography changes rather than render drift.🤖 Generated with Claude Code