refactor(project): re-adjust the overall folder

This commit is contained in:
vince
2024-07-23 00:03:59 +08:00
parent a1a566cb2f
commit 14538f7ed5
281 changed files with 1365 additions and 1659 deletions

View File

@@ -1,7 +0,0 @@
# @vben-core/forward
该目录内的包可直接被app所引用其是项目基础功能的一层抽象。允许轻微的副作用耦合`locales`的集成。
## 注意事项
- `forward` 内的包不允许相互引用,有相互引用的情况请考虑是否放到`packages/effects`

View File

@@ -1,43 +0,0 @@
{
"name": "@vben-core/helpers",
"version": "5.0.0",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
"type": "git",
"url": "git+https://github.com/vbenjs/vue-vben-admin.git",
"directory": "packages/@vben-core/forward/helpers"
},
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm unbuild",
"stub": "pnpm unbuild --stub"
},
"files": [
"dist"
],
"sideEffects": false,
"main": "./dist/index.mjs",
"module": "./dist/index.mjs",
"exports": {
".": {
"types": "./src/index.ts",
"development": "./src/index.ts",
"default": "./dist/index.mjs"
}
},
"publishConfig": {
"exports": {
".": {
"types": "./dist/index.d.ts",
"default": "./dist/index.mjs"
}
}
},
"dependencies": {
"@vben-core/toolkit": "workspace:*",
"@vben-core/typings": "workspace:*",
"vue-router": "^4.4.0"
}
}

View File

@@ -1,29 +0,0 @@
import { createPinia } from 'pinia';
interface InitStoreOptions {
/**
* @zh_CN 应用名,由于 @vben-core/stores 是公用的后续可能有多个app为了防止多个app缓存冲突可在这里配置应用名,应用名将被用于持久化的前缀
*/
namespace: string;
}
/**
* @zh_CN 初始化pinia
*/
async function initStore(options: InitStoreOptions) {
const { createPersistedState } = await import('pinia-plugin-persistedstate');
const pinia = createPinia();
const { namespace } = options;
pinia.use(
createPersistedState({
// key $appName-$store.id
key: (storeKey) => `${namespace}-${storeKey}`,
storage: localStorage,
}),
);
return pinia;
}
export { initStore };
export type { InitStoreOptions };

View File

@@ -6,13 +6,12 @@
"repository": {
"type": "git",
"url": "git+https://github.com/vbenjs/vue-vben-admin.git",
"directory": "packages/@vben-core/shared/hooks"
"directory": "packages/@core/hooks"
},
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm unbuild",
"stub": "pnpm unbuild --stub"
"build": "pnpm unbuild"
},
"files": [
"dist"
@@ -37,14 +36,11 @@
},
"dependencies": {
"@vben-core/constants": "workspace:*",
"@vben-core/preferences": "workspace:*",
"@vben-core/stores": "workspace:*",
"@vben-core/toolkit": "workspace:*",
"@vueuse/core": "^10.11.0",
"radix-vue": "^1.9.2",
"sortablejs": "^1.15.2",
"vue": "^3.4.33",
"vue-router": "^4.4.0"
"vue": "^3.4.33"
},
"devDependencies": {
"@types/sortablejs": "^1.15.8"

View File

@@ -1,9 +1,6 @@
export * from './use-content-height';
export * from './use-content-maximize';
export * from './use-namespace';
export * from './use-refresh';
export * from './use-sortable';
export * from './use-tabs';
export {
useEmitAsProps,
useForwardExpose,

View File

@@ -6,13 +6,12 @@
"repository": {
"type": "git",
"url": "git+https://github.com/vbenjs/vue-vben-admin.git",
"directory": "packages/@vben-core/forward/preferences"
"directory": "packages/@core/preferences"
},
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm unbuild",
"stub": "pnpm unbuild --stub"
"build": "pnpm unbuild"
},
"files": [
"dist",

View File

@@ -1,11 +1,10 @@
import type { DeepPartial } from '@vben-core/typings';
import type { Preferences } from './types';
import { preferencesManager } from './preferences';
// 偏好设置(带有层级关系)
const preferences: Preferences = preferencesManager.getPreferences();
const preferences: Preferences =
preferencesManager.getPreferences.apply(preferencesManager);
// 更新偏好设置
const updatePreferences =
@@ -18,13 +17,13 @@ const resetPreferences =
const clearPreferencesCache =
preferencesManager.clearCache.bind(preferencesManager);
function defineOverridesPreferences(preferences: DeepPartial<Preferences>) {
return preferences;
}
// 初始化偏好设置
const initPreferences =
preferencesManager.initPreferences.bind(preferencesManager);
export {
clearPreferencesCache,
defineOverridesPreferences,
initPreferences,
preferences,
preferencesManager,
resetPreferences,

View File

@@ -1,7 +1,7 @@
import { beforeEach, describe, expect, it, vi } from 'vitest';
import { defaultPreferences } from './config';
import { PreferenceManager, isDarkTheme } from './preferences';
import { isDarkTheme, PreferenceManager } from './preferences';
describe('preferences', () => {
let preferenceManager: PreferenceManager;

View File

@@ -1,10 +1,10 @@
import type { DeepPartial } from '@vben-core/typings';
import type { Preferences } from './types';
import type { InitialOptions, Preferences } from './types';
import { markRaw, reactive, readonly, watch } from 'vue';
import { StorageManager, isMacOs, merge } from '@vben-core/toolkit';
import { isMacOs, merge, StorageManager } from '@vben-core/toolkit';
import {
breakpointsTailwind,
@@ -19,11 +19,6 @@ const STORAGE_KEY = 'preferences';
const STORAGE_KEY_LOCALE = `${STORAGE_KEY}-locale`;
const STORAGE_KEY_THEME = `${STORAGE_KEY}-theme`;
interface initialOptions {
namespace: string;
overrides?: DeepPartial<Preferences>;
}
function isDarkTheme(theme: string) {
let dark = theme === 'dark';
if (theme === 'auto') {
@@ -33,7 +28,7 @@ function isDarkTheme(theme: string) {
}
class PreferenceManager {
private cache: StorageManager | null = null;
private cache: null | StorageManager = null;
// private flattenedState: Flatten<Preferences>;
private initialPreferences: Preferences = defaultPreferences;
private isInitialized: boolean = false;
@@ -171,7 +166,7 @@ class PreferenceManager {
* overrides
* namespace
*/
public async initPreferences({ namespace, overrides }: initialOptions) {
public async initPreferences({ namespace, overrides }: InitialOptions) {
// 是否初始化过
if (this.isInitialized) {
return;
@@ -237,4 +232,4 @@ class PreferenceManager {
}
const preferencesManager = new PreferenceManager();
export { PreferenceManager, isDarkTheme, preferencesManager };
export { isDarkTheme, PreferenceManager, preferencesManager };

View File

@@ -4,6 +4,7 @@ import type {
BreadcrumbStyleType,
BuiltinThemeType,
ContentCompactType,
DeepPartial,
LayoutHeaderModeType,
LayoutType,
LoginExpiredModeType,
@@ -232,11 +233,16 @@ interface Preferences {
type PreferencesKeys = keyof Preferences;
interface InitialOptions {
namespace: string;
overrides?: DeepPartial<Preferences>;
}
export type {
AppPreferences,
BreadcrumbPreferences,
FooterPreferences,
HeaderPreferences,
InitialOptions,
LogoPreferences,
NavigationPreferences,
Preferences,

View File

@@ -11,8 +11,7 @@
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm unbuild",
"stub": "pnpm unbuild --stub"
"build": "pnpm unbuild"
},
"files": [
"dist"

View File

@@ -11,8 +11,7 @@
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm unbuild",
"stub": "pnpm unbuild --stub"
"build": "pnpm unbuild"
},
"files": [
"dist"
@@ -36,7 +35,7 @@
},
"dependencies": {
"@iconify/vue": "^4.1.2",
"lucide-vue-next": "^0.411.0",
"lucide-vue-next": "^0.414.0",
"vue": "^3.4.33"
}
}

View File

@@ -11,8 +11,7 @@
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm unbuild",
"stub": "pnpm unbuild --stub"
"build": "pnpm unbuild"
},
"files": [
"dist"

View File

@@ -67,7 +67,7 @@ class StorageManager {
* @param defaultValue 当项不存在或已过期时返回的默认值
* @returns 值,如果项已过期或解析错误则返回默认值
*/
getItem<T>(key: string, defaultValue: T | null = null): T | null {
getItem<T>(key: string, defaultValue: null | T = null): null | T {
const fullKey = this.getFullKey(key);
const itemStr = this.storage.getItem(fullKey);
if (!itemStr) {

View File

@@ -7,7 +7,7 @@ interface StorageValue<T> {
interface IStorageCache {
clear(): void;
getItem<T>(key: string): T | null;
getItem<T>(key: string): null | T;
key(index: number): null | string;
length(): number;
removeItem(key: string): void;

View File

@@ -41,4 +41,4 @@ function isValidColor(color?: string) {
return new TinyColor(color).isValid;
}
export { TinyColor, convertToHsl, convertToHslCssVar, isValidColor };
export { convertToHsl, convertToHslCssVar, isValidColor, TinyColor };

View File

@@ -11,8 +11,7 @@
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm unbuild",
"stub": "pnpm build --stub"
"build": "pnpm unbuild"
},
"files": [
"dist"

View File

@@ -39,7 +39,7 @@ type AnyFunction<T extends any[] = any[], R = void> =
/**
* T | null 包装
*/
type Nullable<T> = T | null;
type Nullable<T> = null | T;
/**
* T | Not null 包装

View File

@@ -1,4 +1,4 @@
import type { RouteRecordRaw, Router } from 'vue-router';
import type { Router, RouteRecordRaw } from 'vue-router';
import type { Component } from 'vue';

View File

@@ -103,11 +103,6 @@ interface VbenLayoutProps {
* @default sidebar-nav
*/
layout?: LayoutType;
/**
* 侧边菜单折叠宽度
* @default 48
*/
sideCollapseWidth?: number;
/**
* 侧边菜单折叠状态
* @default false
@@ -153,6 +148,11 @@ interface VbenLayoutProps {
* @default 210
*/
sidebarWidth?: number;
/**
* 侧边菜单折叠宽度
* @default 48
*/
sideCollapseWidth?: number;
/**
* tab是否可见
* @default true

View File

@@ -38,7 +38,6 @@ const props = withDefaults(defineProps<Props>(), {
headerVisible: true,
isMobile: false,
layout: 'sidebar-nav',
sideCollapseWidth: 60,
sidebarCollapseShowTitle: false,
sidebarExtraCollapsedWidth: 60,
sidebarHidden: false,
@@ -46,6 +45,7 @@ const props = withDefaults(defineProps<Props>(), {
sidebarSemiDark: true,
sidebarTheme: 'dark',
sidebarWidth: 180,
sideCollapseWidth: 60,
tabbarEnable: true,
tabbarHeight: 36,
zIndex: 200,
@@ -130,7 +130,7 @@ const headerWrapperHeight = computed(() => {
});
const getSideCollapseWidth = computed(() => {
const { sideCollapseWidth, sidebarCollapseShowTitle, sidebarMixedWidth } =
const { sidebarCollapseShowTitle, sidebarMixedWidth, sideCollapseWidth } =
props;
return sidebarCollapseShowTitle || isSidebarMixedNav.value

View File

@@ -7,13 +7,13 @@ import type {
} from '../interface';
import {
type VNodeArrayChildren,
computed,
nextTick,
reactive,
ref,
toRef,
useSlots,
type VNodeArrayChildren,
watch,
watchEffect,
} from 'vue';
@@ -22,7 +22,7 @@ import { useNamespace } from '@vben-core/hooks';
import { Ellipsis } from '@vben-core/icons';
import { isHttpUrl } from '@vben-core/toolkit';
import { UseResizeObserverReturn, useResizeObserver } from '@vueuse/core';
import { useResizeObserver, UseResizeObserverReturn } from '@vueuse/core';
import {
createMenuContext,
@@ -121,8 +121,8 @@ createMenuContext(
handleMenuItemClick,
handleSubMenuClick,
isMenuPopup,
openMenu,
openedMenus,
openMenu,
props,
removeMenuItem,
removeSubMenu,
@@ -176,7 +176,7 @@ function calcSliceIndex() {
}
function debounce(fn: () => void, wait = 33.34) {
let timer: ReturnType<typeof setTimeout> | null;
let timer: null | ReturnType<typeof setTimeout>;
return () => {
timer && clearTimeout(timer);
timer = setTimeout(() => {

View File

@@ -44,7 +44,7 @@ const mouseInChild = ref(false);
const items = ref<MenuProvider['items']>({});
const subMenus = ref<MenuProvider['subMenus']>({});
const timer = ref<ReturnType<typeof setTimeout> | null>(null);
const timer = ref<null | ReturnType<typeof setTimeout>>(null);
createSubMenuContext({
addSubMenu,

View File

@@ -105,8 +105,8 @@ interface MenuProvider {
isMenuPopup: boolean;
items: Record<string, MenuItemRegistered>;
openMenu: (path: string, parentLinks: string[]) => void;
openedMenus: string[];
openMenu: (path: string, parentLinks: string[]) => void;
props: MenuProps;
removeMenuItem: (item: MenuItemRegistered) => void;

View File

@@ -48,7 +48,7 @@
"@vben-core/typings": "workspace:*",
"@vueuse/core": "^10.11.0",
"class-variance-authority": "^0.7.0",
"lucide-vue-next": "^0.411.0",
"lucide-vue-next": "^0.414.0",
"radix-vue": "^1.9.2",
"vue": "^3.4.33"
}

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed, useSlots } from 'vue';
import { computed, type HTMLAttributes, useSlots } from 'vue';
import { VbenTooltip } from '@vben-core/shadcn-ui/components/tooltip';
import { ButtonVariants } from '@vben-core/shadcn-ui/components/ui/button';

View File

@@ -1,7 +1,7 @@
<script setup lang="ts">
import type { HoverCardRootEmits, HoverCardRootProps } from 'radix-vue';
import { HTMLAttributes, computed } from 'vue';
import { computed, HTMLAttributes } from 'vue';
import {
HoverCard,

View File

@@ -5,7 +5,7 @@ import type {
PopoverRootProps,
} from 'radix-vue';
import { HTMLAttributes, computed } from 'vue';
import { computed, HTMLAttributes } from 'vue';
import {
PopoverContent,

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { buttonVariants } from '@vben-core/shadcn-ui/components/ui/button';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { buttonVariants } from '@vben-core/shadcn-ui/components/ui/button';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -5,7 +5,7 @@ import { cn } from '@vben-core/toolkit';
import { AvatarRoot } from 'radix-vue';
import { type AvatarVariants, avatarVariant } from './avatar';
import { avatarVariant, type AvatarVariants } from './avatar';
const props = withDefaults(
defineProps<{

View File

@@ -1,4 +1,4 @@
import { type VariantProps, cva } from 'class-variance-authority';
import { cva, type VariantProps } from 'class-variance-authority';
export const avatarVariant = cva(
'inline-flex items-center justify-center font-normal text-foreground select-none shrink-0 bg-secondary overflow-hidden',

View File

@@ -1,4 +1,4 @@
export * from './avatar';
export { default as Avatar } from './Avatar.vue';
export { default as AvatarFallback } from './AvatarFallback.vue';
export { default as AvatarImage } from './AvatarImage.vue';
export * from './avatar';

View File

@@ -1,4 +1,4 @@
import { type VariantProps, cva } from 'class-variance-authority';
import { cva, type VariantProps } from 'class-variance-authority';
export const badgeVariants = cva(
'inline-flex items-center rounded-md border border-border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2',

View File

@@ -1,3 +1,3 @@
export { default as Badge } from './Badge.vue';
export * from './badge';
export { default as Badge } from './Badge.vue';

View File

@@ -1,4 +1,4 @@
import { type VariantProps, cva } from 'class-variance-authority';
import { cva, type VariantProps } from 'class-variance-authority';
export const buttonVariants = cva(
'inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50',

View File

@@ -1,3 +1,3 @@
export { default as Button } from './Button.vue';
export * from './button';
export { default as Button } from './Button.vue';

View File

@@ -1,7 +1,7 @@
<script setup lang="ts">
import type { CheckboxRootEmits, CheckboxRootProps } from 'radix-vue';
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,7 +1,7 @@
<script setup lang="ts">
import type { NumberFieldRootEmits, NumberFieldRootProps } from 'radix-vue';
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,7 +1,7 @@
<script setup lang="ts">
import type { NumberFieldDecrementProps } from 'radix-vue';
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,7 +1,7 @@
<script setup lang="ts">
import type { NumberFieldIncrementProps } from 'radix-vue';
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,3 +1,4 @@
export * from './sheet';
export { default as Sheet } from './Sheet.vue';
export { default as SheetClose } from './SheetClose.vue';
export { default as SheetContent } from './SheetContent.vue';
@@ -5,6 +6,5 @@ export { default as SheetDescription } from './SheetDescription.vue';
export { default as SheetFooter } from './SheetFooter.vue';
export { default as SheetHeader } from './SheetHeader.vue';
export { default as SheetTitle } from './SheetTitle.vue';
export { default as SheetTrigger } from './SheetTrigger.vue';
export * from './sheet';
export { default as SheetTrigger } from './SheetTrigger.vue';

View File

@@ -1,4 +1,4 @@
import { type VariantProps, cva } from 'class-variance-authority';
import { cva, type VariantProps } from 'class-variance-authority';
export const sheetVariants = cva(
'fixed z-50 gap-4 bg-background shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500 border-border',

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { type HTMLAttributes, computed } from 'vue';
import { computed, type HTMLAttributes } from 'vue';
import { cn } from '@vben-core/toolkit';

View File

@@ -1,11 +1,11 @@
export * from './toast';
export { default as Toast } from './Toast.vue';
export { default as ToastAction } from './ToastAction.vue';
export { default as ToastClose } from './ToastClose.vue';
export { default as ToastDescription } from './ToastDescription.vue';
export { default as Toaster } from './Toaster.vue';
export { default as ToastProvider } from './ToastProvider.vue';
export { default as ToastTitle } from './ToastTitle.vue';
export { default as ToastViewport } from './ToastViewport.vue';
export { default as Toaster } from './Toaster.vue';
export * from './toast';
export { toast, useToast } from './use-toast';

Some files were not shown because too many files have changed in this diff Show More