Fix total library size chip color in light mode

This commit is contained in:
schroda
2026-01-08 16:09:50 +01:00
parent 23c587b351
commit 9642c85007
2 changed files with 11 additions and 2 deletions

View File

@@ -17,6 +17,9 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
- (**Theme**) Adjust "primary color" of dynamic color theme on manga pages
- (**Theme**) Increase max length of custom theme names to 32 (previously 16)
### Fixed
- (**Library**) Fix total library size chip color in light mode
## [20251230.01] (r2937) - 2025-12-30
### Added

View File

@@ -8,7 +8,7 @@
import Chip, { ChipProps } from '@mui/material/Chip';
import Tab from '@mui/material/Tab';
import { styled } from '@mui/material/styles';
import { styled, useTheme } from '@mui/material/styles';
import { useCallback, useMemo, useState } from 'react';
import { useQueryParam, NumberParam, StringParam } from 'use-query-params';
import { useTranslation } from 'react-i18next';
@@ -60,6 +60,7 @@ const TitleSizeTag = ({ sx, ...props }: ChipProps) => (
export function Library() {
const { t } = useTranslation();
const theme = useTheme();
const {
settings: { showTabSize },
@@ -190,7 +191,12 @@ export function Library() {
useAppTitle(
<TitleWithSizeTag>
{t('library.title')}
{showTabSize && <TitleSizeTag sx={{ color: 'inherit' }} label={librarySize} />}
{showTabSize && (
<TitleSizeTag
sx={{ ...theme.applyStyles('light', { backgroundColor: 'background.paper' }) }}
label={librarySize}
/>
)}
</TitleWithSizeTag>,
t('library.title'),
[t, showTabSize, librarySize],