diff options
| author | Claude <noreply@anthropic.com> | 2026-04-11 09:53:34 +0000 |
|---|---|---|
| committer | Claude <noreply@anthropic.com> | 2026-04-11 09:53:34 +0000 |
| commit | e4ae5ac3a83f1da940ab33c93da4ed3e03cd7f14 (patch) | |
| tree | 600809e7ee79707d350f56be9c97a3c0d5282244 /android-app/app/src/main/res/values | |
| parent | 09f5f5bac07970a09369e3d4f350e94a66a47923 (diff) | |
Fix bottom sheet corners; add full light/dark mode palette
Rounded corners:
- Replace androidx CardView with MaterialCardView + ShapeAppearance.Nav.BottomSheet
so only the top-left and top-right corners are rounded (24dp); bottom corners
are square flush with the screen edge
Light/dark mode:
- Introduce values-night/colors.xml with the existing dark M3 palette (moved from
values/colors.xml); instrument values stay dark (#E6E1E5 text, #1C1B1F bg)
- values/colors.xml now carries the light M3 palette: surface #FFFBFE,
onSurface #1C1B1F, surfaceVariant #E7E0EB etc.; instrument text flips to dark
(#1C1B1F normal, #6F6878 secondary) for readability on light backgrounds
- Fix InstrumentUnit hardcoded #6B6070 → ?attr/colorOnSurfaceVariant so the
unit labels adapt automatically in both modes
- Mark the forecast row (ocean navy #0D2137) and WaveView with
android:forceDarkAllowed="false" so the system never inverts them — the
ocean section is intentionally always dark regardless of system theme
https://claude.ai/code/session_01HXPjBsogsJVRwCiekDGkJX
Diffstat (limited to 'android-app/app/src/main/res/values')
| -rwxr-xr-x | android-app/app/src/main/res/values/colors.xml | 36 | ||||
| -rwxr-xr-x | android-app/app/src/main/res/values/themes.xml | 11 |
2 files changed, 28 insertions, 19 deletions
diff --git a/android-app/app/src/main/res/values/colors.xml b/android-app/app/src/main/res/values/colors.xml index eb62cb2..a470c0c 100755 --- a/android-app/app/src/main/res/values/colors.xml +++ b/android-app/app/src/main/res/values/colors.xml @@ -1,28 +1,28 @@ <?xml version="1.0" encoding="utf-8"?> <resources> - <!-- M3 Color Palette --> + <!-- M3 Color Palette (light mode — dark mode overrides in values-night/colors.xml) --> <color name="md_theme_primary">#005FB0</color> <color name="md_theme_onPrimary">#FFFFFF</color> <color name="md_theme_primaryContainer">#D6E3FF</color> <color name="md_theme_onPrimaryContainer">#001B3E</color> - + <color name="md_theme_secondary">#565F71</color> <color name="md_theme_onSecondary">#FFFFFF</color> <color name="md_theme_secondaryContainer">#DAE2F9</color> <color name="md_theme_onSecondaryContainer">#131C2C</color> - + <color name="md_theme_error">#BA1A1A</color> <color name="md_theme_onError">#FFFFFF</color> <color name="md_theme_errorContainer">#FFDAD6</color> <color name="md_theme_onErrorContainer">#410002</color> - - <color name="md_theme_background">#1C1B1F</color> - <color name="md_theme_onBackground">#E6E1E5</color> - <color name="md_theme_surface">#1C1B1F</color> - <color name="md_theme_onSurface">#E6E1E5</color> - <color name="md_theme_surfaceVariant">#49454F</color> - <color name="md_theme_onSurfaceVariant">#CAC4D0</color> - <color name="md_theme_outline">#938F99</color> + + <color name="md_theme_background">#FFFBFE</color> + <color name="md_theme_onBackground">#1C1B1F</color> + <color name="md_theme_surface">#FFFBFE</color> + <color name="md_theme_onSurface">#1C1B1F</color> + <color name="md_theme_surfaceVariant">#E7E0EB</color> + <color name="md_theme_onSurfaceVariant">#49454F</color> + <color name="md_theme_outline">#7A757F</color> <!-- Legacy / Functional Colors --> <color name="black">#FF000000</color> @@ -31,13 +31,13 @@ <color name="primary_dark">#002171</color> <color name="accent">#FF6D00</color> - <!-- Instrument Specific --> - <color name="instrument_text_normal">#E6E1E5</color> - <color name="instrument_text_secondary">#9A94A0</color> - <color name="instrument_text_alarm">#FF5449</color> - <color name="instrument_text_stale">#49454F</color> - <color name="instrument_background">#1C1B1F</color> - <color name="instrument_card_background">#2B2930</color> + <!-- Instrument Specific (light-mode values; dark overrides in values-night/) --> + <color name="instrument_text_normal">#1C1B1F</color> + <color name="instrument_text_secondary">#6F6878</color> + <color name="instrument_text_alarm">#BA1A1A</color> + <color name="instrument_text_stale">#9A94A0</color> + <color name="instrument_background">#FFFBFE</color> + <color name="instrument_card_background">#F2EDF7</color> <color name="mob_button_background">#BA1A1A</color> <color name="anchor_button_background">#005FB0</color> diff --git a/android-app/app/src/main/res/values/themes.xml b/android-app/app/src/main/res/values/themes.xml index 8baa509..a48a721 100755 --- a/android-app/app/src/main/res/values/themes.xml +++ b/android-app/app/src/main/res/values/themes.xml @@ -63,7 +63,7 @@ <style name="InstrumentUnit" parent="android:Widget.TextView"> <item name="android:layout_width">wrap_content</item> <item name="android:layout_height">wrap_content</item> - <item name="android:textColor">#6B6070</item> + <item name="android:textColor">?attr/colorOnSurfaceVariant</item> <item name="android:textSize">@dimen/text_size_instrument_unit</item> <item name="android:textStyle">normal</item> <item name="android:layout_marginStart">2dp</item> @@ -119,6 +119,15 @@ <item name="android:layout_marginStart">4dp</item> </style> + <!-- Bottom sheet top-only rounded corners --> + <style name="ShapeAppearance.Nav.BottomSheet"> + <item name="cornerFamily">rounded</item> + <item name="cornerSizeTopLeft">24dp</item> + <item name="cornerSizeTopRight">24dp</item> + <item name="cornerSizeBottomLeft">0dp</item> + <item name="cornerSizeBottomRight">0dp</item> + </style> + <style name="InstrumentCard" parent="Widget.Material3.CardView.Elevated"> <item name="cardBackgroundColor">@color/instrument_card_background</item> <item name="cardCornerRadius">12dp</item> |
