mirror of
https://github.com/johannesjo/super-productivity.git
synced 2026-01-23 02:36:05 +00:00
fix(ios): set background color for safe area behind home indicator
- Add backgroundColor to Capacitor iOS config to fill safe area - Add CSS :has() rules to set html background based on theme class
This commit is contained in:
parent
ae0ca10c57
commit
d91d5e892b
2 changed files with 13 additions and 0 deletions
|
|
@ -26,6 +26,9 @@ const config: CapacitorConfig = {
|
|||
ios: {
|
||||
// Content inset for safe areas (notch, home indicator)
|
||||
contentInset: 'automatic',
|
||||
// Background color for safe areas (home indicator, notch)
|
||||
// Use dark color to match dark theme (most common on mobile)
|
||||
backgroundColor: '#131314',
|
||||
// Allow inline media playback
|
||||
allowsLinkPreview: true,
|
||||
// Scroll behavior
|
||||
|
|
|
|||
|
|
@ -21,6 +21,16 @@ html {
|
|||
-webkit-text-size-adjust: 100%;
|
||||
text-size-adjust: 100%;
|
||||
|
||||
// Set html background for iOS safe area (home indicator)
|
||||
// Uses :has() to match body theme class since --bg is defined on body
|
||||
&:has(body.isLightTheme) {
|
||||
background: #f8f8f7;
|
||||
}
|
||||
|
||||
&:has(body.isDarkTheme) {
|
||||
background: #131314;
|
||||
}
|
||||
|
||||
button,
|
||||
a {
|
||||
-webkit-app-region: no-drag !important;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue