@robot-admin/naive-ui-components 0.13.8 → 0.14.0
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/CHANGELOG.md +17 -0
- package/README.md +63 -5
- package/README_EN.md +63 -5
- package/dist/C_ActionBar.css +11 -10
- package/dist/C_AntV.css +206 -204
- package/dist/C_AudioPlayer.css +11 -10
- package/dist/C_AvatarGroup.css +7 -5
- package/dist/C_Barcode.css +3 -1
- package/dist/C_Breadcrumb.css +17 -16
- package/dist/C_Captcha.css +14 -13
- package/dist/C_Cascade.css +7 -5
- package/dist/C_Chat.css +9 -8
- package/dist/C_City.css +8 -6
- package/dist/C_Code.css +15 -14
- package/dist/C_CollapsePanel.css +12 -11
- package/dist/C_ContextMenu.css +28 -28
- package/dist/C_Cron.cjs +1 -1
- package/dist/C_Cron.css +472 -251
- package/dist/C_Cron.d.cts +2 -2
- package/dist/C_Cron.d.ts +2 -2
- package/dist/C_Cron.js +1 -1
- package/dist/C_Cron2.cjs +1 -1
- package/dist/C_Cron2.js +1 -1
- package/dist/C_Date.css +2 -1
- package/dist/C_Draggable.css +2 -1
- package/dist/C_Editor.css +2 -1
- package/dist/C_FilePreview.css +185 -184
- package/dist/C_Form.base.css +334 -332
- package/dist/C_Form.css +333 -332
- package/dist/C_FormModal.css +13 -11
- package/dist/C_FormSearch.css +2 -1
- package/dist/C_FormulaEditor.cjs +1 -1
- package/dist/C_FormulaEditor.css +430 -273
- package/dist/C_FormulaEditor.d.cts +2 -2
- package/dist/C_FormulaEditor.d.ts +2 -2
- package/dist/C_FormulaEditor.js +1 -1
- package/dist/C_FullCalendar.css +12 -11
- package/dist/C_GlobalSearch.css +13 -11
- package/dist/C_Guide.css +8 -8
- package/dist/C_Icon.css +9 -7
- package/dist/C_ImageCropper.css +70 -68
- package/dist/C_Language.css +8 -8
- package/dist/C_Loading.css +10 -8
- package/dist/C_Login.css +20 -21
- package/dist/C_Map.css +24 -22
- package/dist/C_Markdown.css +8 -6
- package/dist/C_Menu.css +2 -1
- package/dist/C_NotificationCenter.css +362 -360
- package/dist/C_OrgChart.css +6 -5
- package/dist/C_PageLoading.cjs +1 -0
- package/dist/C_PageLoading.css +153 -0
- package/dist/C_PageLoading.d.cts +2 -0
- package/dist/C_PageLoading.d.ts +2 -0
- package/dist/C_PageLoading.js +1 -0
- package/dist/C_Progress.css +1 -1
- package/dist/C_QRCode.css +7 -5
- package/dist/C_Signature.css +7 -5
- package/dist/C_Skeleton.css +8 -6
- package/dist/C_SplitPane.css +25 -23
- package/dist/C_Steps.css +7 -5
- package/dist/C_Table.base.css +536 -537
- package/dist/C_Table.css +536 -538
- package/dist/C_Tabs.css +78 -1
- package/dist/C_TagsView.css +8 -8
- package/dist/C_Theme.css +9 -7
- package/dist/C_Time.css +3 -1
- package/dist/C_Timeline.css +9 -8
- package/dist/C_Transfer.css +10 -9
- package/dist/C_Tree.css +2 -1
- package/dist/C_Upload.css +176 -174
- package/dist/C_VideoPlayer.css +186 -184
- package/dist/C_VtableGantt.css +2 -1
- package/dist/C_WaterFall.css +19 -17
- package/dist/C_WorkFlow.css +976 -976
- package/dist/constants.d.cts +15 -20
- package/dist/constants.d.ts +15 -20
- package/dist/constants2.d.cts +44 -19
- package/dist/constants2.d.ts +44 -19
- package/dist/constants3.d.cts +4 -4
- package/dist/constants3.d.ts +4 -4
- package/dist/constants4.d.cts +6 -6
- package/dist/constants4.d.ts +6 -6
- package/dist/constants5.d.cts +2 -2
- package/dist/constants5.d.ts +2 -2
- package/dist/createPageLoading.cjs +1 -0
- package/dist/createPageLoading.d.cts +32 -0
- package/dist/createPageLoading.d.ts +32 -0
- package/dist/createPageLoading.js +1 -0
- package/dist/data.d.cts +8 -8
- package/dist/data.d.ts +8 -8
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +24 -23
- package/dist/index.d.ts +24 -23
- package/dist/index.js +1 -1
- package/dist/index.vue.d.cts +4 -4
- package/dist/index.vue.d.ts +4 -4
- package/dist/index10.vue.d.cts +3 -3
- package/dist/index10.vue.d.ts +1 -1
- package/dist/index11.vue.d.cts +1 -1
- package/dist/index11.vue.d.ts +2 -2
- package/dist/index12.vue.d.cts +2 -2
- package/dist/index12.vue.d.ts +2 -2
- package/dist/index13.vue.d.cts +2 -2
- package/dist/index13.vue.d.ts +5 -5
- package/dist/index14.vue.d.cts +5 -5
- package/dist/index14.vue.d.ts +6 -6
- package/dist/index15.vue.d.cts +6 -6
- package/dist/index15.vue.d.ts +1 -1
- package/dist/index16.vue.d.cts +1 -1
- package/dist/index17.vue.d.ts +1 -1
- package/dist/index18.vue.d.cts +1 -1
- package/dist/index18.vue.d.ts +5 -5
- package/dist/index19.vue.d.cts +5 -5
- package/dist/index19.vue.d.ts +1 -1
- package/dist/index2.vue.d.cts +2 -2
- package/dist/index2.vue.d.ts +2 -2
- package/dist/index20.vue.d.cts +1 -1
- package/dist/index20.vue.d.ts +1 -1
- package/dist/index21.vue.d.cts +1 -1
- package/dist/index21.vue.d.ts +1 -1
- package/dist/index22.vue.d.cts +1 -1
- package/dist/index22.vue.d.ts +1 -1
- package/dist/index23.vue.d.cts +2 -2
- package/dist/index23.vue.d.ts +2 -2
- package/dist/index25.vue.d.cts +4 -4
- package/dist/index25.vue.d.ts +4 -4
- package/dist/index27.vue.d.cts +2 -2
- package/dist/index27.vue.d.ts +2 -2
- package/dist/index28.vue.d.cts +1 -1
- package/dist/index28.vue.d.ts +1 -1
- package/dist/index3.vue.d.cts +4 -4
- package/dist/index3.vue.d.ts +4 -4
- package/dist/index4.vue.d.cts +1 -1
- package/dist/index6.vue.d.ts +2 -2
- package/dist/index7.vue.d.cts +2 -2
- package/dist/index8.vue.d.ts +3 -3
- package/dist/index9.vue.d.cts +3 -3
- package/dist/index9.vue.d.ts +3 -3
- package/dist/mapUtils.d.cts +2 -2
- package/dist/mapUtils.d.ts +2 -2
- package/dist/presets.d.cts +1 -1
- package/dist/presets.d.ts +1 -1
- package/dist/resolver.cjs +1 -1
- package/dist/resolver.d.cts +1 -1
- package/dist/resolver.d.ts +1 -1
- package/dist/resolver.js +1 -1
- package/dist/style.css +9976 -9652
- package/dist/useCropperCore.d.cts +9 -9
- package/dist/useCropperCore.d.ts +9 -9
- package/dist/useDraggableLayout.d.cts +6 -6
- package/dist/useDraggableLayout.d.ts +6 -6
- package/dist/useDynamicFormState.d.cts +2 -2
- package/dist/useDynamicFormState.d.ts +2 -2
- package/dist/useEdgeInteraction.d.cts +2 -2
- package/dist/useEdgeInteraction.d.ts +2 -2
- package/dist/useFormulaEvaluator.cjs +2 -0
- package/dist/useFormulaEvaluator.js +2 -0
- package/dist/useInfiniteScroll.d.cts +2 -2
- package/dist/useInfiniteScroll.d.ts +2 -2
- package/dist/useQRCode.d.cts +4 -4
- package/dist/useQRCode.d.ts +4 -4
- package/dist/useSearchState.d.cts +8 -8
- package/dist/useSearchState.d.ts +8 -8
- package/dist/useSignatureHistory.d.cts +3 -3
- package/dist/useSignatureHistory.d.ts +3 -3
- package/dist/useSplitResize.d.cts +4 -4
- package/dist/useSplitResize.d.ts +4 -4
- package/dist/useTableQuery.d.cts +1 -1
- package/dist/useTableQuery.d.ts +1 -1
- package/dist/useTimeSelection.d.cts +1 -1
- package/dist/useTimeSelection.d.ts +1 -1
- package/dist/useTreeOperations.d.cts +5 -5
- package/dist/useTreeOperations.d.ts +5 -5
- package/dist/useWorkflowValidation.d.cts +4 -4
- package/dist/useWorkflowValidation.d.ts +4 -4
- package/dist/verification.d.cts +4 -4
- package/dist/verification.d.ts +4 -4
- package/package.json +1 -1
- package/dist/C_FormulaEditor2.cjs +0 -2
- package/dist/C_FormulaEditor2.js +0 -2
package/dist/constants.d.cts
CHANGED
|
@@ -3,9 +3,9 @@ import { Ref } from "vue";
|
|
|
3
3
|
|
|
4
4
|
//#region src/components/C_Cron/types.d.ts
|
|
5
5
|
/** Cron 字段类型 */
|
|
6
|
-
type CronFieldType =
|
|
6
|
+
type CronFieldType = 'second' | 'minute' | 'hour' | 'day' | 'month' | 'week';
|
|
7
7
|
/** 单字段编辑模式 */
|
|
8
|
-
type CronFieldMode =
|
|
8
|
+
type CronFieldMode = 'every' | 'range' | 'step' | 'specific' | 'none';
|
|
9
9
|
/** 单字段值 */
|
|
10
10
|
interface CronFieldValue {
|
|
11
11
|
/** 编辑模式 */
|
|
@@ -64,9 +64,7 @@ interface CronValidation {
|
|
|
64
64
|
field?: CronFieldType;
|
|
65
65
|
}
|
|
66
66
|
/** 组件 Props */
|
|
67
|
-
interface
|
|
68
|
-
/** 当前 Cron 表达式 (v-model) */
|
|
69
|
-
modelValue?: string;
|
|
67
|
+
interface CronConfig {
|
|
70
68
|
/** 是否禁用 */
|
|
71
69
|
disabled?: boolean;
|
|
72
70
|
/** 预览未来执行次数 */
|
|
@@ -79,6 +77,13 @@ interface CronProps {
|
|
|
79
77
|
showSecond?: boolean;
|
|
80
78
|
/** 容器高度 */
|
|
81
79
|
height?: string | number;
|
|
80
|
+
/** 常用计划;省略时使用组件内置模板 */
|
|
81
|
+
templates?: CronTemplate[];
|
|
82
|
+
}
|
|
83
|
+
/** 推荐使用 v-model + 扁平 config;独立配置属性继续兼容。 */
|
|
84
|
+
interface CronProps extends CronConfig {
|
|
85
|
+
modelValue?: string;
|
|
86
|
+
config?: CronConfig;
|
|
82
87
|
}
|
|
83
88
|
/** 组件暴露方法 */
|
|
84
89
|
interface CronExpose {
|
|
@@ -94,22 +99,15 @@ interface CronExpose {
|
|
|
94
99
|
/** 组件事件 */
|
|
95
100
|
interface CronEmits {
|
|
96
101
|
/** 表达式变更 */
|
|
97
|
-
|
|
102
|
+
'update:modelValue': [value: string];
|
|
98
103
|
/** 值变更 */
|
|
99
104
|
change: [value: string];
|
|
100
105
|
/** 校验状态变更 */
|
|
101
|
-
|
|
106
|
+
'validation-change': [result: CronValidation];
|
|
102
107
|
}
|
|
103
108
|
//#endregion
|
|
104
109
|
//#region src/components/C_Cron/index.vue.d.ts
|
|
105
|
-
|
|
106
|
-
declare function handleReset(): void;
|
|
107
|
-
declare const __VLS_export: vue.DefineComponent<CronProps, {
|
|
108
|
-
getValue: () => string;
|
|
109
|
-
setValue: (expr: string) => void;
|
|
110
|
-
reset: typeof handleReset;
|
|
111
|
-
validate: () => CronValidation;
|
|
112
|
-
}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
110
|
+
declare const __VLS_export: vue.DefineComponent<CronProps, CronExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
113
111
|
"update:modelValue": (value: string) => any;
|
|
114
112
|
change: (value: string) => any;
|
|
115
113
|
"validation-change": (result: CronValidation) => any;
|
|
@@ -118,11 +116,8 @@ declare const __VLS_export: vue.DefineComponent<CronProps, {
|
|
|
118
116
|
onChange?: ((value: string) => any) | undefined;
|
|
119
117
|
"onValidation-change"?: ((result: CronValidation) => any) | undefined;
|
|
120
118
|
}>, {
|
|
121
|
-
modelValue: string;
|
|
122
119
|
disabled: boolean;
|
|
123
|
-
height: string | number;
|
|
124
120
|
showPreview: boolean;
|
|
125
|
-
previewCount: number;
|
|
126
121
|
showTemplates: boolean;
|
|
127
122
|
showSecond: boolean;
|
|
128
123
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
@@ -245,7 +240,7 @@ declare function useCronParser(): {
|
|
|
245
240
|
* 解析 Cron 表达式,预测未来 N 次执行时间
|
|
246
241
|
* 纯逻辑实现,不依赖外部库
|
|
247
242
|
*/
|
|
248
|
-
declare function useCronPreview(expression: Ref<string>, validation: Ref<CronValidation>, count: Ref<number>): {
|
|
243
|
+
declare function useCronPreview(expression: Ref<string>, validation: Ref<CronValidation>, count: Ref<number>, enabled?: Ref<boolean>): {
|
|
249
244
|
nextExecutions: Ref<Date[], Date[]>;
|
|
250
245
|
computing: Ref<boolean, boolean>;
|
|
251
246
|
formatDate: (date: Date) => string;
|
|
@@ -269,4 +264,4 @@ declare const CRON_TEMPLATES: CronTemplate[];
|
|
|
269
264
|
declare const MONTH_LABELS: Record<number, string>;
|
|
270
265
|
declare const WEEK_LABELS: Record<number, string>;
|
|
271
266
|
//#endregion
|
|
272
|
-
export {
|
|
267
|
+
export { CronValue as S, CronFieldType as _, DEFAULT_FIELD_VALUE as a, CronTemplate as b, useCronDescription as c, _default as d, CronConfig as f, CronFieldMode as g, CronFieldMeta as h, DEFAULT_CRON_VALUE as i, useCronPreview as l, CronExpose as m, CRON_TEMPLATES as n, MONTH_LABELS as o, CronEmits as p, DEFAULT_CRON_EXPRESSION as r, WEEK_LABELS as s, CRON_FIELD_META as t, useCronParser as u, CronFieldValue as v, CronValidation as x, CronProps as y };
|
package/dist/constants.d.ts
CHANGED
|
@@ -3,9 +3,9 @@ import { Ref } from "vue";
|
|
|
3
3
|
|
|
4
4
|
//#region src/components/C_Cron/types.d.ts
|
|
5
5
|
/** Cron 字段类型 */
|
|
6
|
-
type CronFieldType =
|
|
6
|
+
type CronFieldType = 'second' | 'minute' | 'hour' | 'day' | 'month' | 'week';
|
|
7
7
|
/** 单字段编辑模式 */
|
|
8
|
-
type CronFieldMode =
|
|
8
|
+
type CronFieldMode = 'every' | 'range' | 'step' | 'specific' | 'none';
|
|
9
9
|
/** 单字段值 */
|
|
10
10
|
interface CronFieldValue {
|
|
11
11
|
/** 编辑模式 */
|
|
@@ -64,9 +64,7 @@ interface CronValidation {
|
|
|
64
64
|
field?: CronFieldType;
|
|
65
65
|
}
|
|
66
66
|
/** 组件 Props */
|
|
67
|
-
interface
|
|
68
|
-
/** 当前 Cron 表达式 (v-model) */
|
|
69
|
-
modelValue?: string;
|
|
67
|
+
interface CronConfig {
|
|
70
68
|
/** 是否禁用 */
|
|
71
69
|
disabled?: boolean;
|
|
72
70
|
/** 预览未来执行次数 */
|
|
@@ -79,6 +77,13 @@ interface CronProps {
|
|
|
79
77
|
showSecond?: boolean;
|
|
80
78
|
/** 容器高度 */
|
|
81
79
|
height?: string | number;
|
|
80
|
+
/** 常用计划;省略时使用组件内置模板 */
|
|
81
|
+
templates?: CronTemplate[];
|
|
82
|
+
}
|
|
83
|
+
/** 推荐使用 v-model + 扁平 config;独立配置属性继续兼容。 */
|
|
84
|
+
interface CronProps extends CronConfig {
|
|
85
|
+
modelValue?: string;
|
|
86
|
+
config?: CronConfig;
|
|
82
87
|
}
|
|
83
88
|
/** 组件暴露方法 */
|
|
84
89
|
interface CronExpose {
|
|
@@ -94,22 +99,15 @@ interface CronExpose {
|
|
|
94
99
|
/** 组件事件 */
|
|
95
100
|
interface CronEmits {
|
|
96
101
|
/** 表达式变更 */
|
|
97
|
-
|
|
102
|
+
'update:modelValue': [value: string];
|
|
98
103
|
/** 值变更 */
|
|
99
104
|
change: [value: string];
|
|
100
105
|
/** 校验状态变更 */
|
|
101
|
-
|
|
106
|
+
'validation-change': [result: CronValidation];
|
|
102
107
|
}
|
|
103
108
|
//#endregion
|
|
104
109
|
//#region src/components/C_Cron/index.vue.d.ts
|
|
105
|
-
|
|
106
|
-
declare function handleReset(): void;
|
|
107
|
-
declare const __VLS_export: vue.DefineComponent<CronProps, {
|
|
108
|
-
getValue: () => string;
|
|
109
|
-
setValue: (expr: string) => void;
|
|
110
|
-
reset: typeof handleReset;
|
|
111
|
-
validate: () => CronValidation;
|
|
112
|
-
}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
110
|
+
declare const __VLS_export: vue.DefineComponent<CronProps, CronExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
113
111
|
"update:modelValue": (value: string) => any;
|
|
114
112
|
change: (value: string) => any;
|
|
115
113
|
"validation-change": (result: CronValidation) => any;
|
|
@@ -118,11 +116,8 @@ declare const __VLS_export: vue.DefineComponent<CronProps, {
|
|
|
118
116
|
onChange?: ((value: string) => any) | undefined;
|
|
119
117
|
"onValidation-change"?: ((result: CronValidation) => any) | undefined;
|
|
120
118
|
}>, {
|
|
121
|
-
modelValue: string;
|
|
122
119
|
disabled: boolean;
|
|
123
|
-
height: string | number;
|
|
124
120
|
showPreview: boolean;
|
|
125
|
-
previewCount: number;
|
|
126
121
|
showTemplates: boolean;
|
|
127
122
|
showSecond: boolean;
|
|
128
123
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
@@ -245,7 +240,7 @@ declare function useCronParser(): {
|
|
|
245
240
|
* 解析 Cron 表达式,预测未来 N 次执行时间
|
|
246
241
|
* 纯逻辑实现,不依赖外部库
|
|
247
242
|
*/
|
|
248
|
-
declare function useCronPreview(expression: Ref<string>, validation: Ref<CronValidation>, count: Ref<number>): {
|
|
243
|
+
declare function useCronPreview(expression: Ref<string>, validation: Ref<CronValidation>, count: Ref<number>, enabled?: Ref<boolean>): {
|
|
249
244
|
nextExecutions: Ref<Date[], Date[]>;
|
|
250
245
|
computing: Ref<boolean, boolean>;
|
|
251
246
|
formatDate: (date: Date) => string;
|
|
@@ -269,4 +264,4 @@ declare const CRON_TEMPLATES: CronTemplate[];
|
|
|
269
264
|
declare const MONTH_LABELS: Record<number, string>;
|
|
270
265
|
declare const WEEK_LABELS: Record<number, string>;
|
|
271
266
|
//#endregion
|
|
272
|
-
export {
|
|
267
|
+
export { CronValue as S, CronFieldType as _, DEFAULT_FIELD_VALUE as a, CronTemplate as b, useCronDescription as c, _default as d, CronConfig as f, CronFieldMode as g, CronFieldMeta as h, DEFAULT_CRON_VALUE as i, useCronPreview as l, CronExpose as m, CRON_TEMPLATES as n, MONTH_LABELS as o, CronEmits as p, DEFAULT_CRON_EXPRESSION as r, WEEK_LABELS as s, CRON_FIELD_META as t, useCronParser as u, CronFieldValue as v, CronValidation as x, CronProps as y };
|
package/dist/constants2.d.cts
CHANGED
|
@@ -3,7 +3,7 @@ import { Ref } from "vue";
|
|
|
3
3
|
|
|
4
4
|
//#region src/components/C_FormulaEditor/types.d.ts
|
|
5
5
|
/** 变量数据类型 */
|
|
6
|
-
type FormulaVariableType =
|
|
6
|
+
type FormulaVariableType = 'number' | 'text' | 'boolean';
|
|
7
7
|
/** 变量定义 */
|
|
8
8
|
interface FormulaVariable {
|
|
9
9
|
/** 显示名称(如「完成值」「目标额」) */
|
|
@@ -29,7 +29,7 @@ interface FormulaFunction {
|
|
|
29
29
|
category?: string;
|
|
30
30
|
}
|
|
31
31
|
/** Token 类型 */
|
|
32
|
-
type FormulaTokenType =
|
|
32
|
+
type FormulaTokenType = 'variable' | 'operator' | 'number' | 'function' | 'paren' | 'comma' | 'text' | 'space';
|
|
33
33
|
/** 公式中的单个 Token */
|
|
34
34
|
interface FormulaToken {
|
|
35
35
|
/** Token 类型 */
|
|
@@ -51,7 +51,7 @@ interface FormulaValidation {
|
|
|
51
51
|
position?: number;
|
|
52
52
|
}
|
|
53
53
|
/** 键盘按键类型 */
|
|
54
|
-
type FormulaKeyType =
|
|
54
|
+
type FormulaKeyType = 'operator' | 'number' | 'paren' | 'logic' | 'compare' | 'action';
|
|
55
55
|
/** 单个键盘按键定义 */
|
|
56
56
|
interface FormulaKeyboardKey {
|
|
57
57
|
/** 按键显示文本 */
|
|
@@ -61,14 +61,12 @@ interface FormulaKeyboardKey {
|
|
|
61
61
|
/** 按键类型 */
|
|
62
62
|
type: FormulaKeyType;
|
|
63
63
|
/** 高亮色(可选) */
|
|
64
|
-
color?:
|
|
64
|
+
color?: 'primary' | 'warning' | 'error' | 'info';
|
|
65
65
|
/** 是否是动作键(如退格、清空) */
|
|
66
66
|
isAction?: boolean;
|
|
67
67
|
}
|
|
68
68
|
/** 公式编辑器 Props */
|
|
69
|
-
interface
|
|
70
|
-
/** 公式字符串 (v-model) */
|
|
71
|
-
modelValue?: string;
|
|
69
|
+
interface FormulaEditorConfig {
|
|
72
70
|
/** 可选变量列表 */
|
|
73
71
|
variables?: FormulaVariable[];
|
|
74
72
|
/** 可用函数列表(为空则使用内置默认函数) */
|
|
@@ -87,12 +85,27 @@ interface FormulaEditorProps {
|
|
|
87
85
|
showKeyboard?: boolean;
|
|
88
86
|
/** 是否显示变量面板 */
|
|
89
87
|
showVariablePanel?: boolean;
|
|
88
|
+
/** 允许调整试算值;不会修改传入的 sampleData */
|
|
89
|
+
editableSampleData?: boolean;
|
|
90
|
+
/** 可直接应用的公式模板 */
|
|
91
|
+
templates?: FormulaTemplate[];
|
|
92
|
+
}
|
|
93
|
+
/** 模板仅包含展示信息与公式,不绑定项目业务。 */
|
|
94
|
+
interface FormulaTemplate {
|
|
95
|
+
label: string;
|
|
96
|
+
value: string;
|
|
97
|
+
description?: string;
|
|
98
|
+
}
|
|
99
|
+
/** 推荐使用 v-model + 扁平 config;独立配置属性继续兼容。 */
|
|
100
|
+
interface FormulaEditorProps extends FormulaEditorConfig {
|
|
101
|
+
modelValue?: string;
|
|
102
|
+
config?: FormulaEditorConfig;
|
|
90
103
|
}
|
|
91
104
|
/** 公式编辑器 Emits */
|
|
92
105
|
interface FormulaEditorEmits {
|
|
93
|
-
|
|
106
|
+
'update:modelValue': [value: string];
|
|
94
107
|
change: [value: string];
|
|
95
|
-
|
|
108
|
+
'validation-change': [result: FormulaValidation];
|
|
96
109
|
}
|
|
97
110
|
/** 公式编辑器暴露方法 */
|
|
98
111
|
interface FormulaEditorExpose {
|
|
@@ -120,25 +133,37 @@ declare const __VLS_export: vue.DefineComponent<FormulaEditorProps, FormulaEdito
|
|
|
120
133
|
onChange?: ((value: string) => any) | undefined;
|
|
121
134
|
"onValidation-change"?: ((result: FormulaValidation) => any) | undefined;
|
|
122
135
|
}>, {
|
|
123
|
-
modelValue: string;
|
|
124
|
-
placeholder: string;
|
|
125
136
|
disabled: boolean;
|
|
126
|
-
height: string | number;
|
|
127
|
-
variables: FormulaVariable[];
|
|
128
|
-
functions: FormulaFunction[];
|
|
129
|
-
sampleData: Record<string, number | string | boolean>;
|
|
130
137
|
showPreview: boolean;
|
|
131
138
|
showKeyboard: boolean;
|
|
132
139
|
showVariablePanel: boolean;
|
|
140
|
+
editableSampleData: boolean;
|
|
133
141
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
134
142
|
declare const _default: typeof __VLS_export;
|
|
135
143
|
//#endregion
|
|
144
|
+
//#region src/components/C_FormulaEditor/utils/safeExpression.d.ts
|
|
145
|
+
type Primitive = number | string | boolean;
|
|
146
|
+
type Token = {
|
|
147
|
+
type: 'number' | 'string' | 'variable' | 'identifier' | 'operator' | 'punctuation' | 'eof';
|
|
148
|
+
value: string;
|
|
149
|
+
position: number;
|
|
150
|
+
};
|
|
151
|
+
/** 编译一次后可对多组试算值复用,不执行 JavaScript。 */
|
|
152
|
+
declare function compileSafeExpression(expression: string): {
|
|
153
|
+
tokens: Token[];
|
|
154
|
+
evaluate(fields: ReadonlyMap<string, string>, values: Readonly<Record<string, Primitive>>): Primitive;
|
|
155
|
+
};
|
|
156
|
+
//#endregion
|
|
136
157
|
//#region src/components/C_FormulaEditor/composables/useFormulaParser.d.ts
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
158
|
+
interface FormulaAnalysis {
|
|
159
|
+
tokens: FormulaToken[];
|
|
160
|
+
validation: FormulaValidation;
|
|
161
|
+
compiled: ReturnType<typeof compileSafeExpression> | null;
|
|
162
|
+
}
|
|
163
|
+
/** 在不执行公式、不需要试算值的情况下完成完整语法检查。 */
|
|
140
164
|
declare function useFormulaParser(variables: Ref<FormulaVariable[]>, functions: Ref<FormulaFunction[]>): {
|
|
141
165
|
tokenize: (formula: string) => FormulaToken[];
|
|
166
|
+
analyze: (formula: string) => FormulaAnalysis;
|
|
142
167
|
validate: (formula: string) => FormulaValidation;
|
|
143
168
|
toEvalExpression: (formula: string, variableMap: Map<string, string>) => string;
|
|
144
169
|
variableNames: vue.ComputedRef<Set<string>>;
|
|
@@ -174,4 +199,4 @@ declare const OPERATORS: Set<string>;
|
|
|
174
199
|
/** 需要在两侧加空格的运算符 */
|
|
175
200
|
declare const SPACED_OPERATORS: Set<string>;
|
|
176
201
|
//#endregion
|
|
177
|
-
export {
|
|
202
|
+
export { FormulaVariableType as S, FormulaTemplate as _, OPERATOR_KEYS as a, FormulaValidation as b, useFormulaParser as c, FormulaEditorEmits as d, FormulaEditorExpose as f, FormulaKeyboardKey as g, FormulaKeyType as h, OPERATORS as i, _default as l, FormulaFunction as m, DEFAULT_FUNCTIONS as n, SPACED_OPERATORS as o, FormulaEditorProps as p, NUMBER_KEYS as r, useFormulaEvaluator as s, ACTION_KEYS as t, FormulaEditorConfig as u, FormulaToken as v, FormulaVariable as x, FormulaTokenType as y };
|
package/dist/constants2.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ import { Ref } from "vue";
|
|
|
3
3
|
|
|
4
4
|
//#region src/components/C_FormulaEditor/types.d.ts
|
|
5
5
|
/** 变量数据类型 */
|
|
6
|
-
type FormulaVariableType =
|
|
6
|
+
type FormulaVariableType = 'number' | 'text' | 'boolean';
|
|
7
7
|
/** 变量定义 */
|
|
8
8
|
interface FormulaVariable {
|
|
9
9
|
/** 显示名称(如「完成值」「目标额」) */
|
|
@@ -29,7 +29,7 @@ interface FormulaFunction {
|
|
|
29
29
|
category?: string;
|
|
30
30
|
}
|
|
31
31
|
/** Token 类型 */
|
|
32
|
-
type FormulaTokenType =
|
|
32
|
+
type FormulaTokenType = 'variable' | 'operator' | 'number' | 'function' | 'paren' | 'comma' | 'text' | 'space';
|
|
33
33
|
/** 公式中的单个 Token */
|
|
34
34
|
interface FormulaToken {
|
|
35
35
|
/** Token 类型 */
|
|
@@ -51,7 +51,7 @@ interface FormulaValidation {
|
|
|
51
51
|
position?: number;
|
|
52
52
|
}
|
|
53
53
|
/** 键盘按键类型 */
|
|
54
|
-
type FormulaKeyType =
|
|
54
|
+
type FormulaKeyType = 'operator' | 'number' | 'paren' | 'logic' | 'compare' | 'action';
|
|
55
55
|
/** 单个键盘按键定义 */
|
|
56
56
|
interface FormulaKeyboardKey {
|
|
57
57
|
/** 按键显示文本 */
|
|
@@ -61,14 +61,12 @@ interface FormulaKeyboardKey {
|
|
|
61
61
|
/** 按键类型 */
|
|
62
62
|
type: FormulaKeyType;
|
|
63
63
|
/** 高亮色(可选) */
|
|
64
|
-
color?:
|
|
64
|
+
color?: 'primary' | 'warning' | 'error' | 'info';
|
|
65
65
|
/** 是否是动作键(如退格、清空) */
|
|
66
66
|
isAction?: boolean;
|
|
67
67
|
}
|
|
68
68
|
/** 公式编辑器 Props */
|
|
69
|
-
interface
|
|
70
|
-
/** 公式字符串 (v-model) */
|
|
71
|
-
modelValue?: string;
|
|
69
|
+
interface FormulaEditorConfig {
|
|
72
70
|
/** 可选变量列表 */
|
|
73
71
|
variables?: FormulaVariable[];
|
|
74
72
|
/** 可用函数列表(为空则使用内置默认函数) */
|
|
@@ -87,12 +85,27 @@ interface FormulaEditorProps {
|
|
|
87
85
|
showKeyboard?: boolean;
|
|
88
86
|
/** 是否显示变量面板 */
|
|
89
87
|
showVariablePanel?: boolean;
|
|
88
|
+
/** 允许调整试算值;不会修改传入的 sampleData */
|
|
89
|
+
editableSampleData?: boolean;
|
|
90
|
+
/** 可直接应用的公式模板 */
|
|
91
|
+
templates?: FormulaTemplate[];
|
|
92
|
+
}
|
|
93
|
+
/** 模板仅包含展示信息与公式,不绑定项目业务。 */
|
|
94
|
+
interface FormulaTemplate {
|
|
95
|
+
label: string;
|
|
96
|
+
value: string;
|
|
97
|
+
description?: string;
|
|
98
|
+
}
|
|
99
|
+
/** 推荐使用 v-model + 扁平 config;独立配置属性继续兼容。 */
|
|
100
|
+
interface FormulaEditorProps extends FormulaEditorConfig {
|
|
101
|
+
modelValue?: string;
|
|
102
|
+
config?: FormulaEditorConfig;
|
|
90
103
|
}
|
|
91
104
|
/** 公式编辑器 Emits */
|
|
92
105
|
interface FormulaEditorEmits {
|
|
93
|
-
|
|
106
|
+
'update:modelValue': [value: string];
|
|
94
107
|
change: [value: string];
|
|
95
|
-
|
|
108
|
+
'validation-change': [result: FormulaValidation];
|
|
96
109
|
}
|
|
97
110
|
/** 公式编辑器暴露方法 */
|
|
98
111
|
interface FormulaEditorExpose {
|
|
@@ -120,25 +133,37 @@ declare const __VLS_export: vue.DefineComponent<FormulaEditorProps, FormulaEdito
|
|
|
120
133
|
onChange?: ((value: string) => any) | undefined;
|
|
121
134
|
"onValidation-change"?: ((result: FormulaValidation) => any) | undefined;
|
|
122
135
|
}>, {
|
|
123
|
-
modelValue: string;
|
|
124
|
-
placeholder: string;
|
|
125
136
|
disabled: boolean;
|
|
126
|
-
height: string | number;
|
|
127
|
-
variables: FormulaVariable[];
|
|
128
|
-
functions: FormulaFunction[];
|
|
129
|
-
sampleData: Record<string, number | string | boolean>;
|
|
130
137
|
showPreview: boolean;
|
|
131
138
|
showKeyboard: boolean;
|
|
132
139
|
showVariablePanel: boolean;
|
|
140
|
+
editableSampleData: boolean;
|
|
133
141
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
134
142
|
declare const _default: typeof __VLS_export;
|
|
135
143
|
//#endregion
|
|
144
|
+
//#region src/components/C_FormulaEditor/utils/safeExpression.d.ts
|
|
145
|
+
type Primitive = number | string | boolean;
|
|
146
|
+
type Token = {
|
|
147
|
+
type: 'number' | 'string' | 'variable' | 'identifier' | 'operator' | 'punctuation' | 'eof';
|
|
148
|
+
value: string;
|
|
149
|
+
position: number;
|
|
150
|
+
};
|
|
151
|
+
/** 编译一次后可对多组试算值复用,不执行 JavaScript。 */
|
|
152
|
+
declare function compileSafeExpression(expression: string): {
|
|
153
|
+
tokens: Token[];
|
|
154
|
+
evaluate(fields: ReadonlyMap<string, string>, values: Readonly<Record<string, Primitive>>): Primitive;
|
|
155
|
+
};
|
|
156
|
+
//#endregion
|
|
136
157
|
//#region src/components/C_FormulaEditor/composables/useFormulaParser.d.ts
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
158
|
+
interface FormulaAnalysis {
|
|
159
|
+
tokens: FormulaToken[];
|
|
160
|
+
validation: FormulaValidation;
|
|
161
|
+
compiled: ReturnType<typeof compileSafeExpression> | null;
|
|
162
|
+
}
|
|
163
|
+
/** 在不执行公式、不需要试算值的情况下完成完整语法检查。 */
|
|
140
164
|
declare function useFormulaParser(variables: Ref<FormulaVariable[]>, functions: Ref<FormulaFunction[]>): {
|
|
141
165
|
tokenize: (formula: string) => FormulaToken[];
|
|
166
|
+
analyze: (formula: string) => FormulaAnalysis;
|
|
142
167
|
validate: (formula: string) => FormulaValidation;
|
|
143
168
|
toEvalExpression: (formula: string, variableMap: Map<string, string>) => string;
|
|
144
169
|
variableNames: vue.ComputedRef<Set<string>>;
|
|
@@ -174,4 +199,4 @@ declare const OPERATORS: Set<string>;
|
|
|
174
199
|
/** 需要在两侧加空格的运算符 */
|
|
175
200
|
declare const SPACED_OPERATORS: Set<string>;
|
|
176
201
|
//#endregion
|
|
177
|
-
export {
|
|
202
|
+
export { FormulaVariableType as S, FormulaTemplate as _, OPERATOR_KEYS as a, FormulaValidation as b, useFormulaParser as c, FormulaEditorEmits as d, FormulaEditorExpose as f, FormulaKeyboardKey as g, FormulaKeyType as h, OPERATORS as i, _default as l, FormulaFunction as m, DEFAULT_FUNCTIONS as n, SPACED_OPERATORS as o, FormulaEditorProps as p, NUMBER_KEYS as r, useFormulaEvaluator as s, ACTION_KEYS as t, FormulaEditorConfig as u, FormulaToken as v, FormulaVariable as x, FormulaTokenType as y };
|
package/dist/constants3.d.cts
CHANGED
|
@@ -155,8 +155,8 @@ interface NotificationCenterExpose {
|
|
|
155
155
|
//#region src/components/C_NotificationCenter/index.vue.d.ts
|
|
156
156
|
declare const __VLS_export: vue.DefineComponent<NotificationCenterProps, NotificationCenterExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
157
157
|
delete: (ids: string[]) => any;
|
|
158
|
-
read: (ids: string[]) => any;
|
|
159
158
|
itemClick: (message: NotificationMessage) => any;
|
|
159
|
+
read: (ids: string[]) => any;
|
|
160
160
|
allRead: (category?: NotificationCategory | undefined) => any;
|
|
161
161
|
unreadChange: (count: number) => any;
|
|
162
162
|
wsStatusChange: (status: WSConnectionStatus) => any;
|
|
@@ -164,19 +164,19 @@ declare const __VLS_export: vue.DefineComponent<NotificationCenterProps, Notific
|
|
|
164
164
|
navigate: (url: string) => any;
|
|
165
165
|
}, string, vue.PublicProps, Readonly<NotificationCenterProps> & Readonly<{
|
|
166
166
|
onDelete?: ((ids: string[]) => any) | undefined;
|
|
167
|
-
onRead?: ((ids: string[]) => any) | undefined;
|
|
168
167
|
onItemClick?: ((message: NotificationMessage) => any) | undefined;
|
|
168
|
+
onRead?: ((ids: string[]) => any) | undefined;
|
|
169
169
|
onAllRead?: ((category?: NotificationCategory | undefined) => any) | undefined;
|
|
170
170
|
onUnreadChange?: ((count: number) => any) | undefined;
|
|
171
171
|
onWsStatusChange?: ((status: WSConnectionStatus) => any) | undefined;
|
|
172
172
|
onNewMessage?: ((message: NotificationMessage) => any) | undefined;
|
|
173
173
|
onNavigate?: ((url: string) => any) | undefined;
|
|
174
174
|
}>, {
|
|
175
|
+
storageKey: string;
|
|
176
|
+
pageSize: number;
|
|
175
177
|
desktopNotification: boolean;
|
|
176
178
|
maxBadgeCount: number;
|
|
177
179
|
pollingInterval: number;
|
|
178
|
-
pageSize: number;
|
|
179
|
-
storageKey: string;
|
|
180
180
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
181
181
|
declare const _default: typeof __VLS_export;
|
|
182
182
|
//#endregion
|
package/dist/constants3.d.ts
CHANGED
|
@@ -155,8 +155,8 @@ interface NotificationCenterExpose {
|
|
|
155
155
|
//#region src/components/C_NotificationCenter/index.vue.d.ts
|
|
156
156
|
declare const __VLS_export: vue.DefineComponent<NotificationCenterProps, NotificationCenterExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
157
157
|
delete: (ids: string[]) => any;
|
|
158
|
-
read: (ids: string[]) => any;
|
|
159
158
|
itemClick: (message: NotificationMessage) => any;
|
|
159
|
+
read: (ids: string[]) => any;
|
|
160
160
|
allRead: (category?: NotificationCategory | undefined) => any;
|
|
161
161
|
unreadChange: (count: number) => any;
|
|
162
162
|
wsStatusChange: (status: WSConnectionStatus) => any;
|
|
@@ -164,19 +164,19 @@ declare const __VLS_export: vue.DefineComponent<NotificationCenterProps, Notific
|
|
|
164
164
|
navigate: (url: string) => any;
|
|
165
165
|
}, string, vue.PublicProps, Readonly<NotificationCenterProps> & Readonly<{
|
|
166
166
|
onDelete?: ((ids: string[]) => any) | undefined;
|
|
167
|
-
onRead?: ((ids: string[]) => any) | undefined;
|
|
168
167
|
onItemClick?: ((message: NotificationMessage) => any) | undefined;
|
|
168
|
+
onRead?: ((ids: string[]) => any) | undefined;
|
|
169
169
|
onAllRead?: ((category?: NotificationCategory | undefined) => any) | undefined;
|
|
170
170
|
onUnreadChange?: ((count: number) => any) | undefined;
|
|
171
171
|
onWsStatusChange?: ((status: WSConnectionStatus) => any) | undefined;
|
|
172
172
|
onNewMessage?: ((message: NotificationMessage) => any) | undefined;
|
|
173
173
|
onNavigate?: ((url: string) => any) | undefined;
|
|
174
174
|
}>, {
|
|
175
|
+
storageKey: string;
|
|
176
|
+
pageSize: number;
|
|
175
177
|
desktopNotification: boolean;
|
|
176
178
|
maxBadgeCount: number;
|
|
177
179
|
pollingInterval: number;
|
|
178
|
-
pageSize: number;
|
|
179
|
-
storageKey: string;
|
|
180
180
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
181
181
|
declare const _default: typeof __VLS_export;
|
|
182
182
|
//#endregion
|
package/dist/constants4.d.cts
CHANGED
|
@@ -196,27 +196,27 @@ type __VLS_Slots = {} & {
|
|
|
196
196
|
area?: (props: typeof __VLS_11) => any;
|
|
197
197
|
};
|
|
198
198
|
declare const __VLS_base: vue.DefineComponent<UploadProps, UploadExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
199
|
-
error: (file: UploadFileItem, error: Error) => any;
|
|
200
|
-
change: (fileList: UploadFileItem[]) => any;
|
|
201
199
|
progress: (file: UploadFileItem, percent: number) => any;
|
|
202
200
|
success: (file: UploadFileItem, response: unknown) => any;
|
|
201
|
+
change: (fileList: UploadFileItem[]) => any;
|
|
202
|
+
error: (file: UploadFileItem, error: Error) => any;
|
|
203
203
|
remove: (file: UploadFileItem) => any;
|
|
204
204
|
finish: (fileList: UploadFileItem[]) => any;
|
|
205
205
|
exceed: (files: File[], fileList: UploadFileItem[]) => any;
|
|
206
206
|
}, string, vue.PublicProps, Readonly<UploadProps> & Readonly<{
|
|
207
|
-
onError?: ((file: UploadFileItem, error: Error) => any) | undefined;
|
|
208
|
-
onChange?: ((fileList: UploadFileItem[]) => any) | undefined;
|
|
209
207
|
onProgress?: ((file: UploadFileItem, percent: number) => any) | undefined;
|
|
210
208
|
onSuccess?: ((file: UploadFileItem, response: unknown) => any) | undefined;
|
|
209
|
+
onChange?: ((fileList: UploadFileItem[]) => any) | undefined;
|
|
210
|
+
onError?: ((file: UploadFileItem, error: Error) => any) | undefined;
|
|
211
211
|
onRemove?: ((file: UploadFileItem) => any) | undefined;
|
|
212
212
|
onFinish?: ((fileList: UploadFileItem[]) => any) | undefined;
|
|
213
213
|
onExceed?: ((files: File[], fileList: UploadFileItem[]) => any) | undefined;
|
|
214
214
|
}>, {
|
|
215
215
|
disabled: boolean;
|
|
216
|
-
data: Record<string, unknown>;
|
|
217
216
|
draggable: boolean;
|
|
218
|
-
multiple: boolean;
|
|
219
217
|
action: string;
|
|
218
|
+
data: Record<string, unknown>;
|
|
219
|
+
multiple: boolean;
|
|
220
220
|
headers: Record<string, string>;
|
|
221
221
|
directory: boolean;
|
|
222
222
|
accept: string;
|
package/dist/constants4.d.ts
CHANGED
|
@@ -196,27 +196,27 @@ type __VLS_Slots = {} & {
|
|
|
196
196
|
area?: (props: typeof __VLS_11) => any;
|
|
197
197
|
};
|
|
198
198
|
declare const __VLS_base: vue.DefineComponent<UploadProps, UploadExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
199
|
-
error: (file: UploadFileItem, error: Error) => any;
|
|
200
|
-
change: (fileList: UploadFileItem[]) => any;
|
|
201
199
|
progress: (file: UploadFileItem, percent: number) => any;
|
|
202
200
|
success: (file: UploadFileItem, response: unknown) => any;
|
|
201
|
+
change: (fileList: UploadFileItem[]) => any;
|
|
202
|
+
error: (file: UploadFileItem, error: Error) => any;
|
|
203
203
|
remove: (file: UploadFileItem) => any;
|
|
204
204
|
finish: (fileList: UploadFileItem[]) => any;
|
|
205
205
|
exceed: (files: File[], fileList: UploadFileItem[]) => any;
|
|
206
206
|
}, string, vue.PublicProps, Readonly<UploadProps> & Readonly<{
|
|
207
|
-
onError?: ((file: UploadFileItem, error: Error) => any) | undefined;
|
|
208
|
-
onChange?: ((fileList: UploadFileItem[]) => any) | undefined;
|
|
209
207
|
onProgress?: ((file: UploadFileItem, percent: number) => any) | undefined;
|
|
210
208
|
onSuccess?: ((file: UploadFileItem, response: unknown) => any) | undefined;
|
|
209
|
+
onChange?: ((fileList: UploadFileItem[]) => any) | undefined;
|
|
210
|
+
onError?: ((file: UploadFileItem, error: Error) => any) | undefined;
|
|
211
211
|
onRemove?: ((file: UploadFileItem) => any) | undefined;
|
|
212
212
|
onFinish?: ((fileList: UploadFileItem[]) => any) | undefined;
|
|
213
213
|
onExceed?: ((files: File[], fileList: UploadFileItem[]) => any) | undefined;
|
|
214
214
|
}>, {
|
|
215
215
|
disabled: boolean;
|
|
216
|
-
data: Record<string, unknown>;
|
|
217
216
|
draggable: boolean;
|
|
218
|
-
multiple: boolean;
|
|
219
217
|
action: string;
|
|
218
|
+
data: Record<string, unknown>;
|
|
219
|
+
multiple: boolean;
|
|
220
220
|
headers: Record<string, string>;
|
|
221
221
|
directory: boolean;
|
|
222
222
|
accept: string;
|
package/dist/constants5.d.cts
CHANGED
|
@@ -260,9 +260,9 @@ type PlayerInstance = InstanceType<typeof xgplayer.default>;
|
|
|
260
260
|
declare const __VLS_export: vue.DefineComponent<VideoPlayerProps, VideoPlayerExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
261
261
|
error: (error: Error) => any;
|
|
262
262
|
ready: () => any;
|
|
263
|
+
ended: () => any;
|
|
263
264
|
stateChange: (state: PlayerState) => any;
|
|
264
265
|
timeUpdate: (currentTime: number, duration: number) => any;
|
|
265
|
-
ended: () => any;
|
|
266
266
|
qualityChange: (quality: QualityLevel) => any;
|
|
267
267
|
rateChange: (rate: number) => any;
|
|
268
268
|
fullscreenChange: (isFullscreen: boolean) => any;
|
|
@@ -273,9 +273,9 @@ declare const __VLS_export: vue.DefineComponent<VideoPlayerProps, VideoPlayerExp
|
|
|
273
273
|
}, string, vue.PublicProps, Readonly<VideoPlayerProps> & Readonly<{
|
|
274
274
|
onError?: ((error: Error) => any) | undefined;
|
|
275
275
|
onReady?: (() => any) | undefined;
|
|
276
|
+
onEnded?: (() => any) | undefined;
|
|
276
277
|
onStateChange?: ((state: PlayerState) => any) | undefined;
|
|
277
278
|
onTimeUpdate?: ((currentTime: number, duration: number) => any) | undefined;
|
|
278
|
-
onEnded?: (() => any) | undefined;
|
|
279
279
|
onQualityChange?: ((quality: QualityLevel) => any) | undefined;
|
|
280
280
|
onRateChange?: ((rate: number) => any) | undefined;
|
|
281
281
|
onFullscreenChange?: ((isFullscreen: boolean) => any) | undefined;
|
package/dist/constants5.d.ts
CHANGED
|
@@ -260,9 +260,9 @@ type PlayerInstance = InstanceType<typeof xgplayer.default>;
|
|
|
260
260
|
declare const __VLS_export: vue.DefineComponent<VideoPlayerProps, VideoPlayerExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
261
261
|
error: (error: Error) => any;
|
|
262
262
|
ready: () => any;
|
|
263
|
+
ended: () => any;
|
|
263
264
|
stateChange: (state: PlayerState) => any;
|
|
264
265
|
timeUpdate: (currentTime: number, duration: number) => any;
|
|
265
|
-
ended: () => any;
|
|
266
266
|
qualityChange: (quality: QualityLevel) => any;
|
|
267
267
|
rateChange: (rate: number) => any;
|
|
268
268
|
fullscreenChange: (isFullscreen: boolean) => any;
|
|
@@ -273,9 +273,9 @@ declare const __VLS_export: vue.DefineComponent<VideoPlayerProps, VideoPlayerExp
|
|
|
273
273
|
}, string, vue.PublicProps, Readonly<VideoPlayerProps> & Readonly<{
|
|
274
274
|
onError?: ((error: Error) => any) | undefined;
|
|
275
275
|
onReady?: (() => any) | undefined;
|
|
276
|
+
onEnded?: (() => any) | undefined;
|
|
276
277
|
onStateChange?: ((state: PlayerState) => any) | undefined;
|
|
277
278
|
onTimeUpdate?: ((currentTime: number, duration: number) => any) | undefined;
|
|
278
|
-
onEnded?: (() => any) | undefined;
|
|
279
279
|
onQualityChange?: ((quality: QualityLevel) => any) | undefined;
|
|
280
280
|
onRateChange?: ((rate: number) => any) | undefined;
|
|
281
281
|
onFullscreenChange?: ((isFullscreen: boolean) => any) | undefined;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
require(`./chunk.cjs`);const e=require(`./config.cjs`),t=require(`./export-helper.cjs`);let n=require(`vue`),r=require(`naive-ui`);const i={class:`c-page-loading__card`,role:`status`,"aria-live":`polite`,"aria-atomic":`true`},a={class:`c-page-loading__label`},o={key:0,class:`c-page-loading__description`},s=(0,n.defineComponent)({name:`C_PageLoading`,__name:`index`,props:{show:{type:Boolean},label:{},description:{},color:{}},setup(t){let s=(0,r.useThemeVars)(),{t:c}=e.i();return(e,r)=>((0,n.openBlock)(),(0,n.createBlock)(n.Teleport,{to:`body`},[(0,n.createVNode)(n.Transition,{name:`c-page-loading-fade`},{default:(0,n.withCtx)(()=>[t.show?((0,n.openBlock)(),(0,n.createElementBlock)(`div`,{key:0,class:`c-page-loading`,style:(0,n.normalizeStyle)({"--c-page-loading-surface":(0,n.unref)(s).cardColor,"--c-page-loading-body":(0,n.unref)(s).bodyColor,"--c-page-loading-border":(0,n.unref)(s).dividerColor,"--c-page-loading-text":(0,n.unref)(s).textColor1,"--c-page-loading-muted":(0,n.unref)(s).textColor3,color:t.color||(0,n.unref)(s).primaryColor})},[(0,n.createElementVNode)(`div`,i,[r[0]||=(0,n.createElementVNode)(`svg`,{class:`c-page-loading__glyph`,viewBox:`0 0 80 80`,fill:`none`,"aria-hidden":`true`,focusable:`false`},[(0,n.createElementVNode)(`circle`,{cx:`40`,cy:`40`,r:`35`,stroke:`currentColor`,"stroke-opacity":`.08`}),(0,n.createElementVNode)(`circle`,{class:`c-page-loading__outer`,cx:`40`,cy:`40`,r:`35`,stroke:`currentColor`,"stroke-opacity":`.38`,"stroke-width":`2`,"stroke-dasharray":`64 156`,"stroke-linecap":`round`}),(0,n.createElementVNode)(`circle`,{class:`c-page-loading__inner`,cx:`40`,cy:`40`,r:`24`,stroke:`currentColor`,"stroke-opacity":`.24`,"stroke-width":`1.5`,"stroke-dasharray":`34 117`,"stroke-linecap":`round`}),(0,n.createElementVNode)(`circle`,{class:`c-page-loading__pulse`,cx:`40`,cy:`40`,r:`17`,fill:`currentColor`,"fill-opacity":`.06`}),(0,n.createElementVNode)(`path`,{class:`c-page-loading__wave`,d:`M11 40 Q20.5 27 30 40 Q39.5 53 49 40 Q58.5 27 68 40`,stroke:`currentColor`,"stroke-width":`2`,"stroke-linecap":`round`}),(0,n.createElementVNode)(`circle`,{cx:`40`,cy:`40`,r:`3`,fill:`currentColor`})],-1),(0,n.createElementVNode)(`span`,a,(0,n.toDisplayString)(t.label||(0,n.unref)(c)(`common.loading`)),1),t.description?((0,n.openBlock)(),(0,n.createElementBlock)(`span`,o,(0,n.toDisplayString)(t.description),1)):(0,n.createCommentVNode)(`v-if`,!0),r[1]||=(0,n.createElementVNode)(`span`,{class:`c-page-loading__track`,"aria-hidden":`true`},null,-1)])],4)):(0,n.createCommentVNode)(`v-if`,!0)]),_:1})]))}});var c=t.t(s,[[`__scopeId`,`data-v-aec6cc81`]]);function l(e={}){let t=(0,n.ref)(!1),r=e.delay??160,i=Number.isFinite(r)?Math.max(0,r):160,a=0,o,s=()=>{o!==void 0&&clearTimeout(o),o=void 0};return{visible:(0,n.readonly)(t),start:()=>{s();let e=++a;return t.value||(o=setTimeout(()=>{o=void 0,e===a&&(t.value=!0)},i)),e},finish:e=>{e===a&&(s(),t.value=!1)},reset:()=>{a++,s(),t.value=!1}}}Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return c}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return l}});
|