Faster time-to-theme (#109)

This commit is contained in:
Gregory Schier
2024-09-25 07:35:27 -07:00
committed by GitHub
parent 0100a3983d
commit de7097ff1d
14 changed files with 132 additions and 93 deletions

View File

@@ -1,9 +1,9 @@
import { open } from '@tauri-apps/plugin-dialog';
import React, { useState } from 'react';
import { useLocalStorage } from 'react-use';
import { useThemes } from '../../hooks/useThemes';
import { capitalize } from '../../lib/capitalize';
import { invokeCmd } from '../../lib/tauri';
import { getThemes } from '../../lib/theme/themes';
import { yaakDark } from '../../lib/theme/themes/yaak';
import { getThemeCSS } from '../../lib/theme/window';
import { Banner } from '../core/Banner';
@@ -45,9 +45,9 @@ const icons: IconProps['icon'][] = [
'send_horizontal',
];
export function SettingsDesign() {
const themes = useThemes();
const themes = getThemes();
export function SettingsDesign() {
const [exportDir, setExportDir] = useLocalStorage<string | null>('theme_export_dir', null);
const [loadingExport, setLoadingExport] = useState<boolean>(false);