base6-ui 1.1.14 → 1.1.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/BaseConfigProvider/constants.d.ts +3 -0
- package/dist/components/BaseConfigProvider/index.d.ts +2 -0
- package/dist/components/BaseConfigProvider/index.vue.d.ts +18 -0
- package/dist/components/BaseConfigProvider/locale-base.d.ts +3 -0
- package/dist/components/BaseConfigProvider/locale-naive.d.ts +4 -0
- package/dist/components/BaseConfigProvider/type.d.ts +16 -0
- package/dist/components/BaseLayout/Default/index.vue.d.ts +7 -5
- package/dist/components/BaseLayout/Default/type.d.ts +6 -8
- package/dist/components/BaseProductIntroduction/cssVar.d.ts +3 -0
- package/dist/components/BaseProgress/cssVar.d.ts +8 -0
- package/dist/components/BaseProgress/index.d.ts +128 -3
- package/dist/components/BaseRadio/cssVar.d.ts +5 -0
- package/dist/components/BaseSwitch/cssVar.d.ts +7 -0
- package/dist/components/BaseSystemActions/cssVar.d.ts +7 -0
- package/dist/components/BaseSystemActions/index.d.ts +2 -0
- package/dist/components/BaseSystemActions/index.vue.d.ts +13 -0
- package/dist/components/BaseSystemActions/type.d.ts +9 -0
- package/dist/components/index.d.ts +2 -0
- package/dist/config/themes/components/progress/dark.d.ts +2 -3
- package/dist/config/themes/components/progress/light.d.ts +2 -3
- package/dist/config/themes/components/radio/dark.d.ts +2 -3
- package/dist/config/themes/components/radio/light.d.ts +2 -3
- package/dist/config/themes/components/switch/common.d.ts +2 -3
- package/dist/config/themes/components/switch/dark.d.ts +2 -3
- package/dist/config/themes/components/switch/light.d.ts +2 -3
- package/dist/enum/locale.d.ts +4 -0
- package/dist/hooks/useLocale.d.ts +17 -0
- package/dist/index.css +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.umd.js +1 -1
- package/dist/locale/index.d.ts +3 -0
- package/dist/locale/lang/en-us.d.ts +26 -0
- package/dist/locale/lang/zh-cn.d.ts +3 -0
- package/dist/types/themes/components.d.ts +5 -0
- package/dist/utils/typescript.d.ts +61 -0
- package/es/components/BaseConfigProvider/constants.d.ts +3 -0
- package/es/components/BaseConfigProvider/constants.mjs +4 -0
- package/es/components/BaseConfigProvider/index.d.ts +2 -0
- package/es/components/BaseConfigProvider/index.vue.d.ts +18 -0
- package/es/components/BaseConfigProvider/index.vue.mjs +54 -0
- package/es/components/BaseConfigProvider/index.vue2.mjs +4 -0
- package/es/components/BaseConfigProvider/locale-base.d.ts +3 -0
- package/es/components/BaseConfigProvider/locale-base.mjs +9 -0
- package/es/components/BaseConfigProvider/locale-naive.d.ts +4 -0
- package/es/components/BaseConfigProvider/locale-naive.mjs +12 -0
- package/es/components/BaseConfigProvider/type.d.ts +16 -0
- package/es/components/BaseLayout/Default/index.vue.d.ts +7 -5
- package/es/components/BaseLayout/Default/index.vue.mjs +2 -2
- package/es/components/BaseLayout/Default/index.vue2.mjs +42 -38
- package/es/components/BaseLayout/Default/layoutHeader/index.vue.mjs +26 -19
- package/es/components/BaseLayout/Default/type.d.ts +6 -8
- package/es/components/BaseProductIntroduction/cssVar.d.ts +3 -0
- package/es/components/BaseProductIntroduction/cssVar.mjs +29 -24
- package/es/components/BaseProductIntroduction/index.vue.mjs +1 -1
- package/es/components/BaseProductIntroduction/index.vue2.mjs +86 -80
- package/es/components/BaseProgress/cssVar.d.ts +8 -0
- package/es/components/BaseProgress/cssVar.mjs +14 -0
- package/es/components/BaseProgress/index.d.ts +128 -3
- package/es/components/BaseProgress/index.mjs +22 -34
- package/es/components/BaseRadio/cssVar.d.ts +5 -0
- package/es/components/BaseRadio/cssVar.mjs +8 -0
- package/es/components/BaseRadio/index.vue.mjs +2 -2
- package/es/components/BaseRadio/index.vue2.mjs +16 -26
- package/es/components/BaseSwitch/cssVar.d.ts +7 -0
- package/es/components/BaseSwitch/cssVar.mjs +10 -0
- package/es/components/BaseSwitch/index.vue.mjs +2 -2
- package/es/components/BaseSwitch/index.vue2.mjs +17 -29
- package/es/components/BaseSystemActions/cssVar.d.ts +7 -0
- package/es/components/BaseSystemActions/cssVar.mjs +63 -0
- package/es/components/BaseSystemActions/index.d.ts +2 -0
- package/es/components/BaseSystemActions/index.vue.d.ts +13 -0
- package/es/components/BaseSystemActions/index.vue.mjs +7 -0
- package/es/components/BaseSystemActions/index.vue2.mjs +102 -0
- package/es/components/BaseSystemActions/type.d.ts +9 -0
- package/es/components/index.d.ts +2 -0
- package/es/config/themes/components/progress/dark.d.ts +2 -3
- package/es/config/themes/components/progress/light.d.ts +2 -3
- package/es/config/themes/components/radio/dark.d.ts +2 -3
- package/es/config/themes/components/radio/light.d.ts +2 -3
- package/es/config/themes/components/switch/common.d.ts +2 -3
- package/es/config/themes/components/switch/dark.d.ts +2 -3
- package/es/config/themes/components/switch/light.d.ts +2 -3
- package/es/enum/locale.d.ts +4 -0
- package/es/hooks/useLocale.d.ts +17 -0
- package/es/hooks/useLocale.mjs +24 -0
- package/es/index.css +1 -1
- package/es/index.d.ts +1 -0
- package/es/index.mjs +62 -54
- package/es/locale/index.d.ts +3 -0
- package/es/locale/lang/en-us.d.ts +26 -0
- package/es/locale/lang/en-us.mjs +27 -0
- package/es/locale/lang/zh-cn.d.ts +3 -0
- package/es/locale/lang/zh-cn.mjs +27 -0
- package/es/node_modules/.pnpm/es-toolkit@1.41.0/node_modules/es-toolkit/dist/compat/_internal/isDeepKey.mjs +12 -0
- package/es/node_modules/.pnpm/es-toolkit@1.41.0/node_modules/es-toolkit/dist/compat/_internal/toKey.mjs +6 -0
- package/es/node_modules/.pnpm/es-toolkit@1.41.0/node_modules/es-toolkit/dist/compat/object/get.mjs +44 -0
- package/es/node_modules/.pnpm/es-toolkit@1.41.0/node_modules/es-toolkit/dist/compat/util/toPath.mjs +21 -0
- package/es/node_modules/.pnpm/es-toolkit@1.41.0/node_modules/es-toolkit/dist/compat/util/toString.mjs +13 -0
- package/es/types/themes/components.d.ts +5 -0
- package/es/utils/typescript.d.ts +61 -0
- package/lib/components/BaseConfigProvider/constants.d.ts +3 -0
- package/lib/components/BaseConfigProvider/constants.js +1 -0
- package/lib/components/BaseConfigProvider/index.d.ts +2 -0
- package/lib/components/BaseConfigProvider/index.vue.d.ts +18 -0
- package/lib/components/BaseConfigProvider/index.vue.js +1 -0
- package/lib/components/BaseConfigProvider/index.vue2.js +1 -0
- package/lib/components/BaseConfigProvider/locale-base.d.ts +3 -0
- package/lib/components/BaseConfigProvider/locale-base.js +1 -0
- package/lib/components/BaseConfigProvider/locale-naive.d.ts +4 -0
- package/lib/components/BaseConfigProvider/locale-naive.js +1 -0
- package/lib/components/BaseConfigProvider/type.d.ts +16 -0
- package/lib/components/BaseLayout/Default/index.vue.d.ts +7 -5
- package/lib/components/BaseLayout/Default/index.vue.js +1 -1
- package/lib/components/BaseLayout/Default/index.vue2.js +1 -1
- package/lib/components/BaseLayout/Default/layoutHeader/index.vue.js +1 -1
- package/lib/components/BaseLayout/Default/type.d.ts +6 -8
- package/lib/components/BaseProductIntroduction/cssVar.d.ts +3 -0
- package/lib/components/BaseProductIntroduction/cssVar.js +1 -1
- package/lib/components/BaseProductIntroduction/index.vue.js +1 -1
- package/lib/components/BaseProductIntroduction/index.vue2.js +1 -1
- package/lib/components/BaseProgress/cssVar.d.ts +8 -0
- package/lib/components/BaseProgress/cssVar.js +1 -0
- package/lib/components/BaseProgress/index.d.ts +128 -3
- package/lib/components/BaseProgress/index.js +1 -1
- package/lib/components/BaseRadio/cssVar.d.ts +5 -0
- package/lib/components/BaseRadio/cssVar.js +1 -0
- package/lib/components/BaseRadio/index.vue.js +1 -1
- package/lib/components/BaseRadio/index.vue2.js +1 -1
- package/lib/components/BaseSwitch/cssVar.d.ts +7 -0
- package/lib/components/BaseSwitch/cssVar.js +1 -0
- package/lib/components/BaseSwitch/index.vue.js +1 -1
- package/lib/components/BaseSwitch/index.vue2.js +1 -1
- package/lib/components/BaseSystemActions/cssVar.d.ts +7 -0
- package/lib/components/BaseSystemActions/cssVar.js +1 -0
- package/lib/components/BaseSystemActions/index.d.ts +2 -0
- package/lib/components/BaseSystemActions/index.vue.d.ts +13 -0
- package/lib/components/BaseSystemActions/index.vue.js +1 -0
- package/lib/components/BaseSystemActions/index.vue2.js +1 -0
- package/lib/components/BaseSystemActions/type.d.ts +9 -0
- package/lib/components/index.d.ts +2 -0
- package/lib/config/themes/components/progress/dark.d.ts +2 -3
- package/lib/config/themes/components/progress/light.d.ts +2 -3
- package/lib/config/themes/components/radio/dark.d.ts +2 -3
- package/lib/config/themes/components/radio/light.d.ts +2 -3
- package/lib/config/themes/components/switch/common.d.ts +2 -3
- package/lib/config/themes/components/switch/dark.d.ts +2 -3
- package/lib/config/themes/components/switch/light.d.ts +2 -3
- package/lib/enum/locale.d.ts +4 -0
- package/lib/hooks/useLocale.d.ts +17 -0
- package/lib/hooks/useLocale.js +1 -0
- package/lib/index.css +1 -1
- package/lib/index.d.ts +1 -0
- package/lib/index.js +1 -1
- package/lib/locale/index.d.ts +3 -0
- package/lib/locale/lang/en-us.d.ts +26 -0
- package/lib/locale/lang/en-us.js +1 -0
- package/lib/locale/lang/zh-cn.d.ts +3 -0
- package/lib/locale/lang/zh-cn.js +1 -0
- package/lib/node_modules/.pnpm/es-toolkit@1.41.0/node_modules/es-toolkit/dist/compat/_internal/isDeepKey.js +1 -0
- package/lib/node_modules/.pnpm/es-toolkit@1.41.0/node_modules/es-toolkit/dist/compat/_internal/toKey.js +1 -0
- package/lib/node_modules/.pnpm/es-toolkit@1.41.0/node_modules/es-toolkit/dist/compat/object/get.js +1 -0
- package/lib/node_modules/.pnpm/es-toolkit@1.41.0/node_modules/es-toolkit/dist/compat/util/toPath.js +1 -0
- package/lib/node_modules/.pnpm/es-toolkit@1.41.0/node_modules/es-toolkit/dist/compat/util/toString.js +1 -0
- package/lib/types/themes/components.d.ts +5 -0
- package/lib/utils/typescript.d.ts +61 -0
- package/package.json +1 -1
- package/es/components/BaseLayout/Default/layoutHeader/action.vue.mjs +0 -7
- package/es/components/BaseLayout/Default/layoutHeader/action.vue2.mjs +0 -85
- package/lib/components/BaseLayout/Default/layoutHeader/action.vue.js +0 -1
- package/lib/components/BaseLayout/Default/layoutHeader/action.vue2.js +0 -1
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
declare const enUS: {
|
|
2
|
+
name: string;
|
|
3
|
+
base: {
|
|
4
|
+
systemActions: {
|
|
5
|
+
userCenter: string;
|
|
6
|
+
logout: string;
|
|
7
|
+
};
|
|
8
|
+
productIntroduction: {
|
|
9
|
+
allProducts: string;
|
|
10
|
+
BasePlatform: string;
|
|
11
|
+
BasePlatformDescription: string;
|
|
12
|
+
AdsPlatform: string;
|
|
13
|
+
AdsPlatformDescription: string;
|
|
14
|
+
StudioPlatform: string;
|
|
15
|
+
StudioPlatformDescription: string;
|
|
16
|
+
MultiModalPlatform: string;
|
|
17
|
+
MultiModalPlatformDescription: string;
|
|
18
|
+
BlinkPlatform: string;
|
|
19
|
+
BlinkPlatformDescription: string;
|
|
20
|
+
BcollectionPlatform: string;
|
|
21
|
+
BcollectionPlatformDescription: string;
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
export type BaseLocale = typeof enUS;
|
|
26
|
+
export default enUS;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { RadioProps, SwitchProps, ProgressProps } from 'naive-ui';
|
|
2
|
+
import { ExtendThemeRadio, ExtendThemeSwitch, ExtendProgress } from './extendThemes';
|
|
3
|
+
export type BaseRadioThemeOverrides = RadioProps['themeOverrides'] & ExtendThemeRadio;
|
|
4
|
+
export type BaseSwitchThemeOverrides = SwitchProps['themeOverrides'] & ExtendThemeSwitch;
|
|
5
|
+
export type BaseProgressThemeOverrides = ProgressProps['themeOverrides'] & ExtendProgress;
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
type Primitive = null | undefined | string | number | boolean | symbol | bigint;
|
|
2
|
+
type BrowserNativeObject = Date | FileList | File | Blob | RegExp;
|
|
3
|
+
/**
|
|
4
|
+
* Check whether it is tuple
|
|
5
|
+
*
|
|
6
|
+
* 检查是否为元组
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* IsTuple<[1, 2, 3]> => true
|
|
10
|
+
* IsTuple<Array[number]> => false
|
|
11
|
+
*/
|
|
12
|
+
type IsTuple<T extends ReadonlyArray<any>> = number extends T['length'] ? false : true;
|
|
13
|
+
/**
|
|
14
|
+
* Array method key
|
|
15
|
+
*
|
|
16
|
+
* 数组方法键
|
|
17
|
+
*/
|
|
18
|
+
type ArrayMethodKey = keyof any[];
|
|
19
|
+
/**
|
|
20
|
+
* Tuple index key
|
|
21
|
+
*
|
|
22
|
+
* 元组下标键
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* TupleKey<[1, 2, 3]> => '0' | '1' | '2'
|
|
26
|
+
*/
|
|
27
|
+
type TupleKey<T extends ReadonlyArray<any>> = Exclude<keyof T, ArrayMethodKey>;
|
|
28
|
+
/**
|
|
29
|
+
* Array index key
|
|
30
|
+
*
|
|
31
|
+
* 数组下标键
|
|
32
|
+
*/
|
|
33
|
+
type ArrayKey = number;
|
|
34
|
+
/**
|
|
35
|
+
* Helper type for recursively constructing paths through a type
|
|
36
|
+
*
|
|
37
|
+
* 用于通过一个类型递归构建路径的辅助类型
|
|
38
|
+
*/
|
|
39
|
+
type PathImpl<K extends string | number, V> = V extends Primitive | BrowserNativeObject ? `${K}` : `${K}` | `${K}.${Path<V>}`;
|
|
40
|
+
/**
|
|
41
|
+
* Type which collects all paths through a type
|
|
42
|
+
*
|
|
43
|
+
* 通过一个类型收集所有路径的类型
|
|
44
|
+
*
|
|
45
|
+
* @see {@link FieldPath}
|
|
46
|
+
*/
|
|
47
|
+
type Path<T> = T extends ReadonlyArray<infer V> ? IsTuple<T> extends true ? {
|
|
48
|
+
[K in TupleKey<T>]-?: PathImpl<Exclude<K, symbol>, T[K]>;
|
|
49
|
+
}[TupleKey<T>] : PathImpl<ArrayKey, V> : {
|
|
50
|
+
[K in keyof T]-?: PathImpl<Exclude<K, symbol>, T[K]>;
|
|
51
|
+
}[keyof T];
|
|
52
|
+
/**
|
|
53
|
+
* Type which collects all paths through a type
|
|
54
|
+
*
|
|
55
|
+
* 通过一个类型收集所有路径的类型
|
|
56
|
+
*
|
|
57
|
+
* @example
|
|
58
|
+
* FieldPath<{ 1: number; a: number; b: string; c: { d: number; e: string }; f: [{ value: string }]; g: { value: string }[]; h: Date; i: FileList; j: File; k: Blob; l: RegExp }> => '1' | 'a' | 'b' | 'c' | 'f' | 'g' | 'c.d' | 'c.e' | 'f.0' | 'f.0.value' | 'g.number' | 'g.number.value' | 'h' | 'i' | 'j' | 'k' | 'l'
|
|
59
|
+
*/
|
|
60
|
+
export type FieldPath<T> = T extends object ? Path<T> : never;
|
|
61
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { BaseConfigProviderProps } from './type';
|
|
2
|
+
declare function __VLS_template(): {
|
|
3
|
+
attrs: Partial<{}>;
|
|
4
|
+
slots: {
|
|
5
|
+
default?(_: {}): any;
|
|
6
|
+
};
|
|
7
|
+
refs: {};
|
|
8
|
+
rootEl: any;
|
|
9
|
+
};
|
|
10
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
11
|
+
declare const __VLS_component: import('vue').DefineComponent<BaseConfigProviderProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<BaseConfigProviderProps> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
12
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
13
|
+
export default _default;
|
|
14
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
15
|
+
new (): {
|
|
16
|
+
$slots: S;
|
|
17
|
+
};
|
|
18
|
+
};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { defineComponent as i, computed as t, provide as m, createBlock as p, openBlock as d, unref as c, withCtx as l, createVNode as f, renderSlot as u } from "vue";
|
|
2
|
+
import { NConfigProvider as b } from "naive-ui";
|
|
3
|
+
import h from "../AppProvider/index.vue.mjs";
|
|
4
|
+
import { naiveLocales as g, naiveDateLocales as v } from "./locale-naive.mjs";
|
|
5
|
+
import { baseLocales as y } from "./locale-base.mjs";
|
|
6
|
+
import { BaseLocaleContextKey as k } from "./constants.mjs";
|
|
7
|
+
const M = /* @__PURE__ */ i({
|
|
8
|
+
__name: "index",
|
|
9
|
+
props: {
|
|
10
|
+
abstract: { type: Boolean },
|
|
11
|
+
breakpoints: {},
|
|
12
|
+
clsPrefix: {},
|
|
13
|
+
inlineThemeDisabled: { type: Boolean },
|
|
14
|
+
katex: {},
|
|
15
|
+
namespace: {},
|
|
16
|
+
preflightStyleDisabled: { type: Boolean },
|
|
17
|
+
styleMountTarget: {},
|
|
18
|
+
tag: {},
|
|
19
|
+
lang: {},
|
|
20
|
+
theme: {},
|
|
21
|
+
themeOverrides: {}
|
|
22
|
+
},
|
|
23
|
+
setup(r) {
|
|
24
|
+
const a = r, o = t(() => g[a.lang]), n = t(() => v[a.lang]), s = t(() => y[a.lang]);
|
|
25
|
+
return m(k, s), (e, L) => (d(), p(c(b), {
|
|
26
|
+
theme: e.theme,
|
|
27
|
+
"theme-overrides": e.themeOverrides,
|
|
28
|
+
abstract: e.abstract,
|
|
29
|
+
breakpoints: e.breakpoints,
|
|
30
|
+
"cls-prefix": e.clsPrefix,
|
|
31
|
+
"inline-theme-disabled": e.inlineThemeDisabled,
|
|
32
|
+
katex: e.katex,
|
|
33
|
+
namespace: e.namespace,
|
|
34
|
+
"preflight-style-disabled": e.preflightStyleDisabled,
|
|
35
|
+
"style-mount-target": e.styleMountTarget,
|
|
36
|
+
tag: e.tag,
|
|
37
|
+
locale: o.value,
|
|
38
|
+
"date-locale": n.value
|
|
39
|
+
}, {
|
|
40
|
+
default: l(() => [
|
|
41
|
+
f(h, null, {
|
|
42
|
+
default: l(() => [
|
|
43
|
+
u(e.$slots, "default")
|
|
44
|
+
]),
|
|
45
|
+
_: 3
|
|
46
|
+
})
|
|
47
|
+
]),
|
|
48
|
+
_: 3
|
|
49
|
+
}, 8, ["theme", "theme-overrides", "abstract", "breakpoints", "cls-prefix", "inline-theme-disabled", "katex", "namespace", "preflight-style-disabled", "style-mount-target", "tag", "locale", "date-locale"]));
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
export {
|
|
53
|
+
M as default
|
|
54
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ConfigProviderProps } from 'naive-ui';
|
|
2
|
+
import { LOCALE_LANG } from '../../enum/locale';
|
|
3
|
+
export type BaseConfigProviderProps = {
|
|
4
|
+
abstract: boolean;
|
|
5
|
+
breakpoints?: ConfigProviderProps['breakpoints'];
|
|
6
|
+
clsPrefix?: ConfigProviderProps['clsPrefix'];
|
|
7
|
+
inlineThemeDisabled?: ConfigProviderProps['inlineThemeDisabled'];
|
|
8
|
+
katex?: ConfigProviderProps['katex'];
|
|
9
|
+
namespace?: ConfigProviderProps['namespace'];
|
|
10
|
+
preflightStyleDisabled?: ConfigProviderProps['preflightStyleDisabled'];
|
|
11
|
+
styleMountTarget?: ConfigProviderProps['styleMountTarget'];
|
|
12
|
+
tag?: ConfigProviderProps['tag'];
|
|
13
|
+
lang?: LOCALE_LANG;
|
|
14
|
+
theme?: ConfigProviderProps['theme'];
|
|
15
|
+
themeOverrides?: ConfigProviderProps['themeOverrides'];
|
|
16
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { MenuOption } from 'naive-ui';
|
|
2
2
|
import { BaseDefaultLayoutProps, BaseDefaultLayoutMode } from './type';
|
|
3
3
|
declare function __VLS_template(): {
|
|
4
4
|
attrs: Partial<{}>;
|
|
@@ -13,15 +13,17 @@ declare function __VLS_template(): {
|
|
|
13
13
|
};
|
|
14
14
|
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
15
15
|
declare const __VLS_component: import('vue').DefineComponent<BaseDefaultLayoutProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
16
|
-
toggleLogo: (...args: any[]) => void;
|
|
17
16
|
toggleSystemTheme: (...args: any[]) => void;
|
|
17
|
+
toggleSystemLang: (...args: any[]) => void;
|
|
18
18
|
toggleUserItem: (...args: any[]) => void;
|
|
19
|
+
toggleLogo: (...args: any[]) => void;
|
|
19
20
|
toggleMenuItem: (...args: any[]) => void;
|
|
20
21
|
toggleMixMenuItem: (...args: any[]) => void;
|
|
21
22
|
}, string, import('vue').PublicProps, Readonly<BaseDefaultLayoutProps> & Readonly<{
|
|
22
|
-
onToggleLogo?: ((...args: any[]) => any) | undefined;
|
|
23
23
|
onToggleSystemTheme?: ((...args: any[]) => any) | undefined;
|
|
24
|
+
onToggleSystemLang?: ((...args: any[]) => any) | undefined;
|
|
24
25
|
onToggleUserItem?: ((...args: any[]) => any) | undefined;
|
|
26
|
+
onToggleLogo?: ((...args: any[]) => any) | undefined;
|
|
25
27
|
onToggleMenuItem?: ((...args: any[]) => any) | undefined;
|
|
26
28
|
onToggleMixMenuItem?: ((...args: any[]) => any) | undefined;
|
|
27
29
|
}>, {
|
|
@@ -51,14 +53,14 @@ declare const __VLS_component: import('vue').DefineComponent<BaseDefaultLayoutPr
|
|
|
51
53
|
footerVisible: boolean;
|
|
52
54
|
fixedFooter: boolean;
|
|
53
55
|
footerIsFullWidth: boolean;
|
|
56
|
+
userActionOption: (MenuOption | import('naive-ui').MenuGroupOption | import('naive-ui').MenuDividerOption | import('naive-ui/es/menu/src/interface').MenuRenderOption)[];
|
|
57
|
+
userInfo: import('../../BaseSystemActions/type').UserInfoType;
|
|
54
58
|
sliderMixWidth: number;
|
|
55
59
|
sliderMixCollapseWidth: number;
|
|
56
60
|
sliderMixChildMenuWidth: number;
|
|
57
61
|
mixSliderFixed: boolean;
|
|
58
62
|
reverseHorizontalMix: boolean;
|
|
59
63
|
menuList: import('./type').BaseMenuOptionType[];
|
|
60
|
-
userActionOption: Array<DropdownOption | import('naive-ui').DropdownGroupOption | import('naive-ui').DropdownDividerOption | import('naive-ui').DropdownRenderOption>;
|
|
61
|
-
userInfo: import('./type').UserInfoType;
|
|
62
64
|
curRoute: any;
|
|
63
65
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
64
66
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./index.vue2.mjs";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../../../_virtual/_plugin-vue_export-helper.mjs";
|
|
4
|
-
const
|
|
4
|
+
const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-8da8ff01"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
m as default
|
|
7
7
|
};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import { defaultLayoutProviderInjectKey as
|
|
6
|
-
import
|
|
7
|
-
import { setupMixMenuContext as
|
|
8
|
-
const
|
|
1
|
+
import { defineComponent as z, mergeDefaults as F, defineAsyncComponent as T, computed as l, provide as $, createBlock as A, openBlock as D, withCtx as n, renderSlot as a, createVNode as m, unref as O } from "vue";
|
|
2
|
+
import P from "../index.vue.mjs";
|
|
3
|
+
import k from "./layoutHeader/index.vue.mjs";
|
|
4
|
+
import N from "./layoutSlider/index.vue.mjs";
|
|
5
|
+
import { defaultLayoutProviderInjectKey as U, DefaultLayoutPropsInDefault as E } from "./options.mjs";
|
|
6
|
+
import R from "../../../hooks/useNaiveConfigProvideContext.mjs";
|
|
7
|
+
import { setupMixMenuContext as j } from "../../../hooks/useMenu.mjs";
|
|
8
|
+
const Y = /* @__PURE__ */ z({
|
|
9
9
|
__name: "index",
|
|
10
|
-
props: /* @__PURE__ */
|
|
10
|
+
props: /* @__PURE__ */ F({
|
|
11
11
|
scrollMode: {},
|
|
12
12
|
scrollElId: {},
|
|
13
13
|
scrollWrapperClass: {},
|
|
@@ -44,7 +44,7 @@ const X = /* @__PURE__ */ L({
|
|
|
44
44
|
userActionOption: {},
|
|
45
45
|
userInfo: {}
|
|
46
46
|
}, {
|
|
47
|
-
...
|
|
47
|
+
...E,
|
|
48
48
|
menuList: () => [],
|
|
49
49
|
userActionOption: () => [],
|
|
50
50
|
userInfo: () => ({ name: "" })
|
|
@@ -53,56 +53,60 @@ const X = /* @__PURE__ */ L({
|
|
|
53
53
|
"toggleLogo",
|
|
54
54
|
"toggleMenuItem",
|
|
55
55
|
"toggleMixMenuItem",
|
|
56
|
+
"toggleSystemLang",
|
|
56
57
|
"toggleSystemTheme",
|
|
57
58
|
"toggleUserItem"
|
|
58
59
|
],
|
|
59
60
|
setup(c, { emit: v }) {
|
|
60
|
-
const M =
|
|
61
|
+
const M = T(() => import("./layoutMenu/index.vue.mjs")), o = c, i = v, C = R(), { childLevelMenus: g } = j(o), b = l(() => {
|
|
61
62
|
const {
|
|
62
63
|
name: e = "light"
|
|
63
64
|
} = C?.mergedThemeRef.value || {};
|
|
64
65
|
return e !== "light";
|
|
65
|
-
}), y =
|
|
66
|
+
}), y = l(() => {
|
|
66
67
|
const e = "vertical";
|
|
67
68
|
return o.mode.includes(e) ? e : "horizontal";
|
|
68
|
-
}), x =
|
|
69
|
+
}), x = l(() => o.mode !== "horizontal"), r = l(() => o.mode === "horizontal-mix"), d = l(() => o.mode === "vertical-mix"), I = () => {
|
|
69
70
|
const { reverseHorizontalMix: e } = o, { sliderCollapseWidth: t, sliderMixCollapseWidth: u, sliderMixChildMenuWidth: h } = o;
|
|
70
71
|
if (r.value && e)
|
|
71
72
|
return t;
|
|
72
73
|
let s = d.value || r.value ? u : t;
|
|
73
|
-
return d.value && o.mixSliderFixed &&
|
|
74
|
-
},
|
|
74
|
+
return d.value && o.mixSliderFixed && g.value.length && (s += h), s;
|
|
75
|
+
}, f = l(() => I());
|
|
75
76
|
function W() {
|
|
76
77
|
const { reverseHorizontalMix: e } = o, { sliderWidth: t, sliderMixChildMenuWidth: u, sliderMixWidth: h } = o;
|
|
77
78
|
if (r.value && e)
|
|
78
79
|
return t;
|
|
79
80
|
let s = d.value || r.value ? h : t;
|
|
80
|
-
return d.value && o.mixSliderFixed &&
|
|
81
|
+
return d.value && o.mixSliderFixed && g.value.length && (s += u), s;
|
|
81
82
|
}
|
|
82
|
-
const p =
|
|
83
|
-
|
|
84
|
-
},
|
|
85
|
-
|
|
86
|
-
},
|
|
87
|
-
|
|
88
|
-
},
|
|
89
|
-
|
|
90
|
-
},
|
|
91
|
-
|
|
83
|
+
const p = l(() => W()), B = () => {
|
|
84
|
+
i("toggleLogo");
|
|
85
|
+
}, L = (e, t) => {
|
|
86
|
+
i("toggleMenuItem", e, t);
|
|
87
|
+
}, S = (e, t) => {
|
|
88
|
+
i("toggleMixMenuItem", e, t);
|
|
89
|
+
}, H = (e) => {
|
|
90
|
+
i("toggleSystemTheme", e);
|
|
91
|
+
}, V = () => {
|
|
92
|
+
i("toggleSystemLang");
|
|
93
|
+
}, w = (e, t) => {
|
|
94
|
+
i("toggleUserItem", e, t);
|
|
92
95
|
};
|
|
93
|
-
return
|
|
96
|
+
return $(U, {
|
|
94
97
|
layoutConfig: o,
|
|
95
98
|
isDarkMode: b,
|
|
96
99
|
userActionOption: o.userActionOption,
|
|
97
100
|
userInfo: o.userInfo,
|
|
98
|
-
_sliderCollapseWidth:
|
|
101
|
+
_sliderCollapseWidth: f,
|
|
99
102
|
_sliderWidth: p,
|
|
100
103
|
toggleLogo: B,
|
|
101
|
-
toggleMenuItem:
|
|
102
|
-
toggleMixMenuItem:
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
104
|
+
toggleMenuItem: L,
|
|
105
|
+
toggleMixMenuItem: S,
|
|
106
|
+
toggleSystemLang: V,
|
|
107
|
+
toggleSystemTheme: H,
|
|
108
|
+
toggleUserItem: w
|
|
109
|
+
}), (e, t) => (D(), A(P, {
|
|
106
110
|
mode: y.value,
|
|
107
111
|
"scroll-mode": e.scrollMode,
|
|
108
112
|
"scroll-el-id": e.scrollElId,
|
|
@@ -115,7 +119,7 @@ const X = /* @__PURE__ */ L({
|
|
|
115
119
|
"slider-class": e.sliderClass,
|
|
116
120
|
"slider-collapse": e.sliderCollapse,
|
|
117
121
|
"slider-width": p.value,
|
|
118
|
-
"slider-collapse-width":
|
|
122
|
+
"slider-collapse-width": f.value,
|
|
119
123
|
"footer-visible": e.footerVisible,
|
|
120
124
|
"fixed-footer": e.fixedFooter,
|
|
121
125
|
"footer-is-full-width": e.footerIsFullWidth,
|
|
@@ -123,12 +127,12 @@ const X = /* @__PURE__ */ L({
|
|
|
123
127
|
}, {
|
|
124
128
|
header: n(() => [
|
|
125
129
|
a(e.$slots, "header", {}, () => [
|
|
126
|
-
m(
|
|
130
|
+
m(k)
|
|
127
131
|
], !0)
|
|
128
132
|
]),
|
|
129
133
|
slider: n(() => [
|
|
130
134
|
a(e.$slots, "slider", {}, () => [
|
|
131
|
-
m(
|
|
135
|
+
m(N)
|
|
132
136
|
], !0)
|
|
133
137
|
]),
|
|
134
138
|
footer: n(() => [
|
|
@@ -136,12 +140,12 @@ const X = /* @__PURE__ */ L({
|
|
|
136
140
|
]),
|
|
137
141
|
default: n(() => [
|
|
138
142
|
a(e.$slots, "default", {}, void 0, !0),
|
|
139
|
-
m(
|
|
143
|
+
m(O(M))
|
|
140
144
|
]),
|
|
141
145
|
_: 3
|
|
142
146
|
}, 8, ["mode", "scroll-mode", "scroll-el-id", "fixed-top", "header-visible", "header-height", "tab-visible", "tab-height", "slider-visible", "slider-class", "slider-collapse", "slider-width", "slider-collapse-width", "footer-visible", "fixed-footer", "footer-is-full-width", "footer-height"]));
|
|
143
147
|
}
|
|
144
148
|
});
|
|
145
149
|
export {
|
|
146
|
-
|
|
150
|
+
Y as default
|
|
147
151
|
};
|
|
@@ -1,31 +1,38 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
const
|
|
1
|
+
import { defineComponent as c, computed as d, createBlock as t, openBlock as n, withCtx as o, createElementVNode as g, unref as e, createVNode as f, createCommentVNode as p } from "vue";
|
|
2
|
+
import _ from "../../Header/index.vue.mjs";
|
|
3
|
+
import y from "./title.vue.mjs";
|
|
4
|
+
import { LAYOUT_HEADER_MENU_ID as h } from "../constants.mjs";
|
|
5
|
+
import T from "../../../BaseSystemActions/index.vue.mjs";
|
|
6
|
+
import x from "../hooks/useBaseLayoutContext.mjs";
|
|
7
|
+
const L = ["id"], N = /* @__PURE__ */ c({
|
|
8
8
|
name: "GlobalHeader",
|
|
9
9
|
__name: "index",
|
|
10
|
-
setup(
|
|
11
|
-
const { layoutConfig: r } =
|
|
12
|
-
return (
|
|
13
|
-
headerTitle:
|
|
14
|
-
|
|
10
|
+
setup(A) {
|
|
11
|
+
const { layoutConfig: r, userActionOption: s, userInfo: l, toggleSystemTheme: m, toggleSystemLang: a, toggleUserItem: i } = x(), u = d(() => !(r.mode.indexOf("vertical") > -1));
|
|
12
|
+
return (I, S) => (n(), t(_, null, {
|
|
13
|
+
headerTitle: o(() => [
|
|
14
|
+
u.value ? (n(), t(y, { key: 0 })) : p("", !0)
|
|
15
15
|
]),
|
|
16
|
-
headerActions:
|
|
17
|
-
|
|
16
|
+
headerActions: o(() => [
|
|
17
|
+
f(T, {
|
|
18
|
+
mode: "horizontal",
|
|
19
|
+
userActionOption: e(s),
|
|
20
|
+
userInfo: e(l),
|
|
21
|
+
onToggleSystemTheme: e(m),
|
|
22
|
+
onToggleSystemLang: e(a),
|
|
23
|
+
onToggleUserItem: e(i)
|
|
24
|
+
}, null, 8, ["userActionOption", "userInfo", "onToggleSystemTheme", "onToggleSystemLang", "onToggleUserItem"])
|
|
18
25
|
]),
|
|
19
|
-
default:
|
|
20
|
-
|
|
21
|
-
id:
|
|
26
|
+
default: o(() => [
|
|
27
|
+
g("div", {
|
|
28
|
+
id: e(h),
|
|
22
29
|
class: "h-full flex-y-center flex-1-hidden pl-[16px]"
|
|
23
|
-
}, null, 8,
|
|
30
|
+
}, null, 8, L)
|
|
24
31
|
]),
|
|
25
32
|
_: 1
|
|
26
33
|
}));
|
|
27
34
|
}
|
|
28
35
|
});
|
|
29
36
|
export {
|
|
30
|
-
|
|
37
|
+
N as default
|
|
31
38
|
};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { LayoutProps, LayoutMode } from '../type';
|
|
2
|
-
import { DropdownOption,
|
|
2
|
+
import { DropdownOption, MenuOption } from 'naive-ui';
|
|
3
3
|
import { VNode, ComputedRef } from 'vue';
|
|
4
|
+
import { BaseSystemActionsProps } from '../../BaseSystemActions';
|
|
4
5
|
export type BaseDefaultLayoutMode = LayoutMode | 'horizontal-mix' | 'vertical-mix';
|
|
5
6
|
export type BaseDefaultLayoutProps = Omit<LayoutProps, 'mode'> & {
|
|
6
7
|
mode?: BaseDefaultLayoutMode;
|
|
@@ -11,8 +12,8 @@ export type BaseDefaultLayoutProps = Omit<LayoutProps, 'mode'> & {
|
|
|
11
12
|
mixSliderFixed?: boolean;
|
|
12
13
|
menuList: BaseMenuOptionType[];
|
|
13
14
|
reverseHorizontalMix?: boolean;
|
|
14
|
-
userActionOption?:
|
|
15
|
-
userInfo?:
|
|
15
|
+
userActionOption?: BaseSystemActionsProps['userActionOption'];
|
|
16
|
+
userInfo?: BaseSystemActionsProps['userInfo'];
|
|
16
17
|
};
|
|
17
18
|
export type BaseMenuOptionType = {
|
|
18
19
|
key: string;
|
|
@@ -25,13 +26,10 @@ export type BaseMenuOptionType = {
|
|
|
25
26
|
activeIcon?: () => VNode;
|
|
26
27
|
children?: BaseMenuOptionType[];
|
|
27
28
|
};
|
|
28
|
-
export type UserInfoType = {
|
|
29
|
-
name: string;
|
|
30
|
-
};
|
|
31
29
|
export type BaseLayoutProviderType = {
|
|
32
30
|
layoutConfig: Required<BaseDefaultLayoutProps>;
|
|
33
|
-
userInfo:
|
|
34
|
-
userActionOption?:
|
|
31
|
+
userInfo: BaseSystemActionsProps['userInfo'];
|
|
32
|
+
userActionOption?: BaseSystemActionsProps['userActionOption'];
|
|
35
33
|
isDarkMode: ComputedRef<boolean>;
|
|
36
34
|
toggleLogo: () => void;
|
|
37
35
|
toggleMenuItem: (key: string, item: MenuOption) => void;
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
import
|
|
1
|
+
import t from "../../config/themes/token/dark.mjs";
|
|
2
|
+
import l from "../../config/themes/token/light.mjs";
|
|
3
|
+
import p from "../../config/themes/color/dark.mjs";
|
|
2
4
|
import o from "../../config/themes/color/light.mjs";
|
|
3
5
|
import "../../config/themes/components/alert/light.mjs";
|
|
4
6
|
import "../../config/themes/components/button/light.mjs";
|
|
@@ -49,35 +51,38 @@ import "../../config/themes/components/baseComponent/dark.mjs";
|
|
|
49
51
|
import "../../config/themes/common/dark.mjs";
|
|
50
52
|
import "../../config/themes/components/charts/dark.mjs";
|
|
51
53
|
import "../../config/themes/components/charts/light.mjs";
|
|
52
|
-
const
|
|
54
|
+
const i = {
|
|
53
55
|
"light-1": o["color-gray-10"],
|
|
54
56
|
"light-3": o["color-gray-6"],
|
|
55
|
-
"dark-1": "
|
|
56
|
-
"dark-3": "
|
|
57
|
-
},
|
|
57
|
+
"dark-1": t["color-text-1"],
|
|
58
|
+
"dark-3": t["color-text-3"]
|
|
59
|
+
}, e = {
|
|
58
60
|
"light-1": o["color-gray-2"],
|
|
59
|
-
"dark-1": "
|
|
60
|
-
},
|
|
61
|
-
"light-2": "
|
|
62
|
-
"dark-2": "
|
|
63
|
-
},
|
|
61
|
+
"dark-1": t["fill-color-1"]
|
|
62
|
+
}, a = {
|
|
63
|
+
"light-2": l["bg-color-2"],
|
|
64
|
+
"dark-2": t["bg-color-2"]
|
|
65
|
+
}, m = {
|
|
64
66
|
"light-1": o["color-gray-3"],
|
|
65
|
-
"dark-1":
|
|
66
|
-
},
|
|
67
|
+
"dark-1": p["color-gray-3"]
|
|
68
|
+
}, ar = (r) => ({
|
|
67
69
|
fontSizeMedium: "12px",
|
|
68
70
|
titleFontSizeMedium: "14px",
|
|
69
|
-
borderColor:
|
|
70
|
-
color:
|
|
71
|
-
textColor:
|
|
72
|
-
titleTextColor:
|
|
73
|
-
}),
|
|
74
|
-
"--base-title-color":
|
|
75
|
-
"--base-text-color":
|
|
76
|
-
"--base-color":
|
|
77
|
-
"--base-card-border-hover-color": r ?
|
|
78
|
-
height: "620px"
|
|
71
|
+
borderColor: m[r ? "dark-1" : "light-1"],
|
|
72
|
+
color: e[r ? "dark-1" : "light-1"],
|
|
73
|
+
textColor: i[r ? "dark-3" : "light-3"],
|
|
74
|
+
titleTextColor: i[r ? "dark-1" : "light-1"]
|
|
75
|
+
}), cr = (r) => ({
|
|
76
|
+
"--base-title-color": i[r ? "dark-1" : "light-1"],
|
|
77
|
+
"--base-text-color": i[r ? "dark-3" : "light-3"],
|
|
78
|
+
"--base-color": a[r ? "dark-2" : "light-2"],
|
|
79
|
+
"--base-card-border-hover-color": r ? p["color-primary-6"] : o["color-primary-6"],
|
|
80
|
+
height: "620px",
|
|
81
|
+
borderRight: `1px solid ${m[r ? "dark-1" : "light-1"]}`,
|
|
82
|
+
borderBottom: `1px solid ${m[r ? "dark-1" : "light-1"]}`,
|
|
83
|
+
overflow: "hidden"
|
|
79
84
|
});
|
|
80
85
|
export {
|
|
81
|
-
|
|
82
|
-
|
|
86
|
+
ar as createCardThemeOverrides,
|
|
87
|
+
cr as createPopoverCssVar
|
|
83
88
|
};
|
|
@@ -2,7 +2,7 @@ import o from "./index.vue2.mjs";
|
|
|
2
2
|
/* empty css */
|
|
3
3
|
/* empty css */
|
|
4
4
|
import t from "../../_virtual/_plugin-vue_export-helper.mjs";
|
|
5
|
-
const c = /* @__PURE__ */ t(o, [["__scopeId", "data-v-
|
|
5
|
+
const c = /* @__PURE__ */ t(o, [["__scopeId", "data-v-9f76a352"]]);
|
|
6
6
|
export {
|
|
7
7
|
c as default
|
|
8
8
|
};
|