feat: add sliding verification to the login form (#4461)

This commit is contained in:
Vben
2024-09-21 21:51:40 +08:00
committed by GitHub
parent 000172e482
commit dac80703d9
16 changed files with 234 additions and 502 deletions

View File

@@ -1 +1,2 @@
export * from './form';
export * from './naive';

View File

@@ -0,0 +1,25 @@
import { computed } from 'vue';
import { preferences } from '@vben/preferences';
import '@vben/styles';
import { createDiscreteApi, darkTheme, lightTheme } from 'naive-ui';
const themeOverridesProviderProps = computed(() => ({
themeOverrides: preferences.theme.mode === 'light' ? lightTheme : darkTheme,
}));
const themeProviderProps = computed(() => ({
theme: preferences.theme.mode === 'light' ? lightTheme : darkTheme,
}));
export const { dialog, loadingBar, message, modal, notification } =
createDiscreteApi(
['message', 'dialog', 'notification', 'loadingBar', 'modal'],
{
configProviderProps: themeProviderProps,
loadingBarProviderProps: themeOverridesProviderProps,
messageProviderProps: themeOverridesProviderProps,
notificationProviderProps: themeOverridesProviderProps,
},
);