diff --git a/src/components/HelpModal/HelpSection.tsx b/src/components/HelpModal/HelpSection.tsx index 2e04a03..363c1c2 100644 --- a/src/components/HelpModal/HelpSection.tsx +++ b/src/components/HelpModal/HelpSection.tsx @@ -12,7 +12,9 @@ function HelpSection({ name, items }: { name: string; items: SearchShortcut[] }) className={textClasses.helpTitle} classNames={textClasses} style={{ - textShadow: theme.textShadowsEnabled && '2px 2px var(--mantine-color-border-0)', + textShadow: theme.textShadowsEnabled + ? '2px 2px var(--mantine-color-border-0)' + : undefined, }} > {name} diff --git a/src/components/SettingsHeader.tsx b/src/components/SettingsHeader.tsx index 909fc2e..0e67db8 100644 --- a/src/components/SettingsHeader.tsx +++ b/src/components/SettingsHeader.tsx @@ -137,9 +137,11 @@ export function SettingsHeader({ zIndex: 100, }} styles={ - theme.textShadowsEnabled && { - label: { boxShadow: '2px 2px var(--mantine-color-border-0)' }, - } + theme.textShadowsEnabled + ? { + label: { boxShadow: '2px 2px var(--mantine-color-border-0)' }, + } + : undefined } rightSection={ isLoading ? ( diff --git a/src/components/WeatherModal/CurrentWeather.tsx b/src/components/WeatherModal/CurrentWeather.tsx index f3de08d..f6e5b34 100644 --- a/src/components/WeatherModal/CurrentWeather.tsx +++ b/src/components/WeatherModal/CurrentWeather.tsx @@ -49,8 +49,9 @@ export default function CurrentWeather({ current }: { current: CW }) { className={textClasses.weatherTitle} classNames={textClasses} style={{ - textShadow: - theme.textShadowsEnabled && '2px 2px var(--mantine-color-border-0)', + textShadow: theme.textShadowsEnabled + ? '2px 2px var(--mantine-color-border-0)' + : undefined, }} > Current Weather @@ -155,9 +156,9 @@ export default function CurrentWeather({ current }: { current: CW }) { classNames={textClasses} style={{ textAlign: 'center', - textShadow: - theme.textShadowsEnabled && - '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)', + textShadow: theme.textShadowsEnabled + ? '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)' + : undefined, }} w={'100%'} > @@ -200,9 +201,9 @@ export default function CurrentWeather({ current }: { current: CW }) { classNames={textClasses} style={{ textAlign: 'center', - textShadow: - theme.textShadowsEnabled && - '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)', + textShadow: theme.textShadowsEnabled + ? '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)' + : undefined, }} w={'100%'} > @@ -247,9 +248,9 @@ export default function CurrentWeather({ current }: { current: CW }) { classNames={textClasses} style={{ textAlign: 'center', - textShadow: - theme.textShadowsEnabled && - '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)', + textShadow: theme.textShadowsEnabled + ? '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)' + : undefined, }} w={'100%'} > diff --git a/src/components/WeatherModal/ExtendedForecastCard.tsx b/src/components/WeatherModal/ExtendedForecastCard.tsx index a345d18..14af9ff 100644 --- a/src/components/WeatherModal/ExtendedForecastCard.tsx +++ b/src/components/WeatherModal/ExtendedForecastCard.tsx @@ -29,7 +29,9 @@ export default function ExtendedForecastCard({ className={textClasses.weatherTitle} classNames={textClasses} style={{ - textShadow: theme.textShadowsEnabled && '2px 2px var(--mantine-color-border-0)', + textShadow: theme.textShadowsEnabled + ? '2px 2px var(--mantine-color-border-0)' + : undefined, }} > Extended Forecast diff --git a/src/pages/homepage/components/Applications/Applications.tsx b/src/pages/homepage/components/Applications/Applications.tsx index 06f1acd..9622558 100644 --- a/src/pages/homepage/components/Applications/Applications.tsx +++ b/src/pages/homepage/components/Applications/Applications.tsx @@ -46,9 +46,9 @@ function Applications({ contentType }: { contentType: string[] }) { className={textClasses.sectionTitle} classNames={textClasses} style={{ - boxShadow: - theme.textShadowsEnabled && - '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)', + boxShadow: theme.textShadowsEnabled + ? '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)' + : undefined, }} > Applications diff --git a/src/pages/homepage/components/Bookmarks/Bookmarks.tsx b/src/pages/homepage/components/Bookmarks/Bookmarks.tsx index 0de6716..8b00401 100644 --- a/src/pages/homepage/components/Bookmarks/Bookmarks.tsx +++ b/src/pages/homepage/components/Bookmarks/Bookmarks.tsx @@ -65,9 +65,9 @@ function Bookmarks({ contentType }: { contentType: string[] }) { mb={'-.5rem'} mt={'1.25rem'} style={{ - boxShadow: - theme.textShadowsEnabled && - '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)', + boxShadow: theme.textShadowsEnabled + ? '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)' + : undefined, }} > Bookmarks diff --git a/src/pages/homepage/components/Header/Header.tsx b/src/pages/homepage/components/Header/Header.tsx index ff21c48..6d7d45e 100644 --- a/src/pages/homepage/components/Header/Header.tsx +++ b/src/pages/homepage/components/Header/Header.tsx @@ -81,9 +81,9 @@ function Header({ classNames={textClasses} fz={isMobile ? 24 : undefined} style={{ - textShadow: - theme.textShadowsEnabled && - '3px 3px 1px color-mix(in srgb, var(--mantine-color-primary-0), transparent 50%)', + textShadow: theme.textShadowsEnabled + ? '3px 3px 1px color-mix(in srgb, var(--mantine-color-primary-0), transparent 50%)' + : undefined, }} > {greet @@ -104,9 +104,9 @@ function Header({ classNames={textClasses} style={{ width: 'max-content', - textShadow: - theme.textShadowsEnabled && - '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)', + textShadow: theme.textShadowsEnabled + ? '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)' + : undefined, }} > {date} @@ -134,9 +134,9 @@ function Header({ classNames={textClasses} mr={'.25rem'} style={{ - textShadow: - theme.textShadowsEnabled && - '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)', + textShadow: theme.textShadowsEnabled + ? '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)' + : undefined, }} > {current.temperature}°F @@ -147,9 +147,9 @@ function Header({ fz={'.875rem'} mb={'.375rem'} style={{ - textShadow: - theme.textShadowsEnabled && - '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)', + textShadow: theme.textShadowsEnabled + ? '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)' + : undefined, }} > {current.highTemp}°F/{current.lowTemp}°F @@ -159,9 +159,9 @@ function Header({ className={textClasses.dateTime} classNames={textClasses} style={{ - textShadow: - theme.textShadowsEnabled && - '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)', + textShadow: theme.textShadowsEnabled + ? '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)' + : undefined, }} > {`${ diff --git a/src/pages/homepage/components/Header/LargeHeader.tsx b/src/pages/homepage/components/Header/LargeHeader.tsx index cd84b11..3257a65 100644 --- a/src/pages/homepage/components/Header/LargeHeader.tsx +++ b/src/pages/homepage/components/Header/LargeHeader.tsx @@ -72,9 +72,9 @@ function LargeHeader({ classNames={textClasses} fz={isMobile ? '2rem' : '6rem'} style={{ - textShadow: - theme.textShadowsEnabled && - '3px 3px 1px color-mix(in srgb, var(--mantine-color-primary-0), transparent 50%)', + textShadow: theme.textShadowsEnabled + ? '3px 3px 1px color-mix(in srgb, var(--mantine-color-primary-0), transparent 50%)' + : undefined, }} > {greet @@ -90,9 +90,9 @@ function LargeHeader({ m={0} style={{ width: 'max-content', - textShadow: - theme.textShadowsEnabled && - '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)', + textShadow: theme.textShadowsEnabled + ? '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)' + : undefined, }} > {date} @@ -103,9 +103,9 @@ function LargeHeader({ className={textClasses.dateTime} classNames={textClasses} style={{ - textShadow: - theme.textShadowsEnabled && - '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)', + textShadow: theme.textShadowsEnabled + ? '1px 1px 1px color-mix(in srgb, var(--mantine-color-accent-0), transparent 50%)' + : undefined, }} > {`${ diff --git a/src/pages/homepage/components/SettingsButton/SettingsCard.tsx b/src/pages/homepage/components/SettingsButton/SettingsCard.tsx index 4081685..a2d092c 100644 --- a/src/pages/homepage/components/SettingsButton/SettingsCard.tsx +++ b/src/pages/homepage/components/SettingsButton/SettingsCard.tsx @@ -120,9 +120,11 @@ function SettingsCard({ position: 'top', }} styles={ - theme.textShadowsEnabled && { - label: { boxShadow: '2px 2px var(--mantine-color-border-0)' }, - } + theme.textShadowsEnabled + ? { + label: { boxShadow: '2px 2px var(--mantine-color-border-0)' }, + } + : undefined } />