diff --git a/.github/workflows/qc_checks.yaml b/.github/workflows/qc_checks.yaml index 3fba3bbeb1..d616acde94 100644 --- a/.github/workflows/qc_checks.yaml +++ b/.github/workflows/qc_checks.yaml @@ -222,7 +222,7 @@ jobs: echo "Downloaded api.yaml" - name: Running OpenAPI Spec diff action id: breaking_changes - uses: oasdiff/oasdiff-action/diff@3530478ec30f84adedbfeb28f0d9527a290f50a9 # pin@main + uses: oasdiff/oasdiff-action/diff@5fbe96ede8d0c53aeadef122d7a0abb79152d493 # pin@main with: base: "api.yaml" revision: "src/backend/InvenTree/schema.yml" @@ -363,7 +363,7 @@ jobs: pip install . if: needs.paths-filter.outputs.submit-performance == 'true' - name: Performance Reporting - uses: CodSpeedHQ/action@9d332c4d90b43981c3e55ae8e38e68709996240f # pin@v4.17.0 + uses: CodSpeedHQ/action@c145068895e045cc725ee76fcd2307624b65c3af # pin@v4.17.5 # check if we are in inventree/inventree - reporting only works in that OIDC context if: github.repository == 'inventree/InvenTree' && needs.paths-filter.outputs.submit-performance == 'true' with: @@ -454,7 +454,7 @@ jobs: env: node_version: '>=24' - name: Performance Reporting - uses: CodSpeedHQ/action@9d332c4d90b43981c3e55ae8e38e68709996240f # pin@v4.17.0 + uses: CodSpeedHQ/action@c145068895e045cc725ee76fcd2307624b65c3af # pin@v4.17.5 with: mode: walltime run: inv dev.test --pytest diff --git a/.github/workflows/translations.yaml b/.github/workflows/translations.yaml index 504ac005f6..e1da913823 100644 --- a/.github/workflows/translations.yaml +++ b/.github/workflows/translations.yaml @@ -56,7 +56,7 @@ jobs: echo "Resetting to HEAD~" git reset HEAD~ || true - name: crowdin action - uses: crowdin/github-action@8868a33591d21088edfc398968173a3b98d51706 # pin@v2 + uses: crowdin/github-action@52aa776766211d83d975df51f3b9c53c2f8ba35f # pin@v2 with: upload_sources: true upload_translations: false diff --git a/src/frontend/src/contexts/colorSchema.tsx b/src/frontend/src/contexts/colorSchema.tsx index 131e9da8e4..a2a734a8ce 100644 --- a/src/frontend/src/contexts/colorSchema.tsx +++ b/src/frontend/src/contexts/colorSchema.tsx @@ -1,5 +1,4 @@ import { - type MantineColorScheme, type MantineColorSchemeManager, isMantineColorScheme } from '@mantine/core'; @@ -21,10 +20,18 @@ export function localStorageColorSchemeManager({ } try { - return ( - (window.localStorage.getItem(key) as MantineColorScheme) || - defaultValue - ); + const storedValue = window.localStorage.getItem(key); + + // If a value exists in storage, return it + if (storedValue && isMantineColorScheme(storedValue)) { + return storedValue; + } + + // If no value, check the system preference + const systemPrefersDark = window.matchMedia( + '(prefers-color-scheme: dark)' + ).matches; + return systemPrefersDark ? 'dark' : 'light'; } catch { return defaultValue; }