Skip to content

Commit 1dfaf75

Browse files
committed
feat: update theme colors and enhance layout for mobile responsiveness
- Changed theme and background colors in the web manifest and meta tags to a darker shade (#121212) for improved aesthetics. - Adjusted the `MainAppBar` component to include safe area insets for better layout on devices with notches. - Modified the `MobilePlayground` component to account for safe area insets in its height calculation, ensuring a more consistent user experience across different devices. - These updates enhance the visual consistency and usability of the application, particularly on mobile devices.
1 parent c31f169 commit 1dfaf75

4 files changed

Lines changed: 12 additions & 5 deletions

File tree

public/site.webmanifest

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"type": "image/png"
1414
}
1515
],
16-
"theme_color": "#ffffff",
17-
"background_color": "#ffffff",
16+
"theme_color": "#121212",
17+
"background_color": "#121212",
1818
"display": "standalone"
1919
}

src/features/appBar/ui/MainAppBar.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,7 @@ export const MainAppBar: React.FC<MainAppBarProps> = ({
155155
variant={appBarVariant}
156156
color={"transparent"}
157157
sx={{
158+
paddingTop: "env(safe-area-inset-top, 0px)",
158159
transition: "all .2s",
159160
backdropFilter: isScrolled ? "blur(12px)" : "blur(0px)",
160161
background: isScrolled

src/features/playground/ui/MobilePlayground.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export const MobilePlayground: React.FC = () => {
2525
<Box
2626
component="main"
2727
sx={{
28-
height: `calc(100vh - ${MOBILE_APPBAR_HEIGHT}px)`,
28+
height: `calc(100vh - ${MOBILE_APPBAR_HEIGHT}px - env(safe-area-inset-top, 0px))`,
2929
overflow: "hidden",
3030
}}
3131
>

src/pages/_document.tsx

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,14 @@ function Document({ emotionStyleTags }: MyDocumentProps) {
6969
/>
7070
<link rel="manifest" href="/site.webmanifest" />
7171
<link rel="mask-icon" href="/safari-pinned-tab.svg" color="#5bbad5" />
72-
<meta name="msapplication-TileColor" content="#da532c" />
73-
{/*<meta name="theme-color" content="#ffffff"/>*/}
72+
<meta name="msapplication-TileColor" content="#121212" />
73+
<meta name="theme-color" content="#121212" />
74+
<meta name="apple-mobile-web-app-capable" content="yes" />
75+
<meta
76+
name="apple-mobile-web-app-status-bar-style"
77+
content="black-translucent"
78+
/>
79+
<meta name="apple-mobile-web-app-title" content="dStruct" />
7480

7581
<link rel="preconnect" href="https://fonts.googleapis.com" />
7682
<link rel="preconnect" href="https://fonts.gstatic.com" />

0 commit comments

Comments
 (0)