Skip to content

Commit

Permalink
🐛 fix(lib): Fix the problem of quoting the name of the theme category
Browse files Browse the repository at this point in the history
  • Loading branch information
kwooshung committed Feb 20, 2024
1 parent 9ec44f6 commit 1fb3da2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/useThemes/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { useState, useEffect, useCallback } from 'react';
import { theme } from 'lomind';
import { themes } from 'lomind';
import { TThemeResult } from './interfaces';

/**
Expand All @@ -10,7 +10,7 @@ import { TThemeResult } from './interfaces';
* @returns {TThemeResult} 主题管理器返回值
*/
const useTheme = (initialTheme: string = 'auto', initialThemes: string[] = ['light', 'dark', 'auto']): TThemeResult => {
const themeManager = theme.getInstance(initialTheme, initialThemes);
const themeManager = themes.getInstance(initialTheme, initialThemes);
const [currentTheme, setCurrentTheme] = useState<string>(themeManager.getCurrent());

const setTheme = useCallback(
Expand Down

0 comments on commit 1fb3da2

Please sign in to comment.