@apform-ui/core 1.1.0 → 1.3.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/dist/__tests__/components.spec.d.ts +1 -0
- package/dist/apform-ui.css +1 -1
- package/dist/apform-ui.js +3659 -2487
- package/dist/apform-ui.umd.cjs +55 -54
- package/dist/components/AppDialog/AppDialog.vue.d.ts +48 -0
- package/dist/components/AppDialog/index.d.ts +1 -0
- package/dist/components/AppIcon/AppIcon.vue.d.ts +11 -0
- package/dist/components/AppIcon/index.d.ts +1 -0
- package/dist/components/AppPagination/AppPagination.vue.d.ts +26 -0
- package/dist/components/AppPagination/index.d.ts +1 -0
- package/dist/components/CardGridSkeleton/CardGridSkeleton.vue.d.ts +34 -0
- package/dist/components/CardGridSkeleton/index.d.ts +1 -0
- package/dist/components/CardTable/CardTable.vue.d.ts +28 -0
- package/dist/components/CardTable/index.d.ts +1 -0
- package/dist/components/Chat/ApprovalCard/ApprovalCard.vue.d.ts +12 -0
- package/dist/components/Chat/ApprovalCard/index.d.ts +1 -0
- package/dist/components/Chat/Composer/Composer.vue.d.ts +32 -0
- package/dist/components/Chat/Composer/index.d.ts +1 -0
- package/dist/components/Chat/ConversationHeader/ConversationHeader.vue.d.ts +21 -0
- package/dist/components/Chat/ConversationHeader/index.d.ts +1 -0
- package/dist/components/Chat/MessageBubble/MessageBubble.vue.d.ts +23 -0
- package/dist/components/Chat/MessageBubble/index.d.ts +1 -0
- package/dist/components/Chat/MessageList/MessageList.vue.d.ts +24 -0
- package/dist/components/Chat/MessageList/index.d.ts +1 -0
- package/dist/components/Chat/ProcessingDrawer/ProcessingDrawer.vue.d.ts +32 -0
- package/dist/components/Chat/ProcessingDrawer/index.d.ts +1 -0
- package/dist/components/Chat/RunStatusBar/RunStatusBar.vue.d.ts +12 -0
- package/dist/components/Chat/RunStatusBar/index.d.ts +1 -0
- package/dist/components/Chat/SessionSidebar/SessionSidebar.vue.d.ts +18 -0
- package/dist/components/Chat/SessionSidebar/index.d.ts +1 -0
- package/dist/components/Chat/message/AttachmentPreviewModal.vue.d.ts +18 -0
- package/dist/components/Chat/message/DocumentSummaryList.vue.d.ts +12 -0
- package/dist/components/Chat/message/MessageAttachmentList.vue.d.ts +11 -0
- package/dist/components/Chat/message/MessageParts.vue.d.ts +6 -0
- package/dist/components/Chat/message/index.d.ts +4 -0
- package/dist/components/ConfirmDialog/ConfirmDialog.vue.d.ts +26 -0
- package/dist/components/ConfirmDialog/index.d.ts +1 -0
- package/dist/components/ContentPanel/ContentPanel.vue.d.ts +31 -0
- package/dist/components/ContentPanel/index.d.ts +1 -0
- package/dist/components/EmptyState/EmptyState.vue.d.ts +23 -0
- package/dist/components/EmptyState/index.d.ts +1 -0
- package/dist/components/ErrorBoundary/ErrorBoundary.vue.d.ts +39 -0
- package/dist/components/ErrorBoundary/index.d.ts +1 -0
- package/dist/components/FieldRow/FieldRow.vue.d.ts +23 -0
- package/dist/components/FieldRow/index.d.ts +1 -0
- package/dist/components/FilterBar/FilterBar.vue.d.ts +30 -0
- package/dist/components/FilterBar/index.d.ts +1 -0
- package/dist/components/FilterTabs/FilterTabs.vue.d.ts +21 -0
- package/dist/components/FilterTabs/index.d.ts +1 -0
- package/dist/components/FormDialog/FormDialog.vue.d.ts +44 -0
- package/dist/components/FormDialog/index.d.ts +1 -0
- package/dist/components/HintText/HintText.vue.d.ts +19 -0
- package/dist/components/HintText/index.d.ts +1 -0
- package/dist/components/JsonCard/JsonCard.vue.d.ts +20 -0
- package/dist/components/JsonCard/index.d.ts +1 -0
- package/dist/components/JsonDetailDialog/JsonDetailDialog.vue.d.ts +13 -0
- package/dist/components/JsonDetailDialog/index.d.ts +1 -0
- package/dist/components/LoadingDots/LoadingDots.vue.d.ts +10 -0
- package/dist/components/LoadingDots/index.d.ts +1 -0
- package/dist/components/PageHeader/PageHeader.vue.d.ts +28 -0
- package/dist/components/PageHeader/index.d.ts +1 -0
- package/dist/components/PageShell/PageShell.vue.d.ts +25 -0
- package/dist/components/PageShell/index.d.ts +1 -0
- package/dist/components/SchemaLitePreview/SchemaLitePreview.vue.d.ts +30 -0
- package/dist/components/SchemaLitePreview/index.d.ts +2 -0
- package/dist/components/SearchForm/SearchForm.vue.d.ts +39 -0
- package/dist/components/SearchForm/index.d.ts +2 -0
- package/dist/components/SectionToggle/SectionToggle.vue.d.ts +20 -0
- package/dist/components/SectionToggle/index.d.ts +1 -0
- package/dist/components/Skeleton/Skeleton.vue.d.ts +29 -0
- package/dist/components/Skeleton/index.d.ts +1 -0
- package/dist/components/StatusTag/StatusTag.vue.d.ts +21 -0
- package/dist/components/StatusTag/index.d.ts +2 -0
- package/dist/components/TableRowActions/TableRowActions.vue.d.ts +23 -0
- package/dist/components/TableRowActions/index.d.ts +2 -0
- package/dist/components/Toast/Toast.vue.d.ts +12 -0
- package/dist/components/Toast/index.d.ts +2 -0
- package/dist/components/TruncatedTooltipText/TruncatedTooltipText.vue.d.ts +22 -0
- package/dist/components/TruncatedTooltipText/index.d.ts +1 -0
- package/dist/components/UserAvatar/UserAvatar.vue.d.ts +26 -0
- package/dist/components/UserAvatar/index.d.ts +1 -0
- package/dist/composables/index.d.ts +7 -0
- package/dist/composables/useClientPagination.d.ts +15 -0
- package/dist/composables/useConfirm.d.ts +15 -0
- package/dist/composables/useDebounceFn.d.ts +1 -0
- package/dist/composables/useMessage.d.ts +8 -0
- package/dist/composables/useToast.d.ts +17 -0
- package/dist/index.d.ts +69 -0
- package/dist/stories/AppDialog.stories.d.ts +9 -0
- package/dist/stories/AppIcon.stories.d.ts +9 -0
- package/dist/stories/ApprovalCard.stories.d.ts +8 -0
- package/dist/stories/Composer.stories.d.ts +9 -0
- package/dist/stories/MessageBubble.stories.d.ts +10 -0
- package/dist/stories/RunStatusBar.stories.d.ts +8 -0
- package/dist/stories/StatusTag.stories.d.ts +8 -0
- package/dist/stories/useConfirm.stories.d.ts +5 -0
- package/dist/stories/useMessage.stories.d.ts +5 -0
- package/dist/tokens/index.d.ts +139 -0
- package/dist/types/chat.d.ts +121 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/utils/attachmentKind.d.ts +7 -0
- package/dist/utils/iconRegistry.d.ts +7 -0
- package/dist/utils/index.d.ts +6 -0
- package/dist/utils/pagination.d.ts +8 -0
- package/dist/utils/resolveApiErrorMessage.d.ts +22 -0
- package/dist/utils/textParser.d.ts +20 -0
- package/package.json +2 -1
- package/src/tokens/index.ts +78 -0
- package/src/tokens/tokens.css +74 -5
- package/styles/element-override.css +155 -0
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* FilterTabs — 通用筛选标签栏
|
|
3
|
+
*
|
|
4
|
+
* 按钮组样式的筛选 tabs,用于列表页筛选。
|
|
5
|
+
*/
|
|
6
|
+
type __VLS_Props = {
|
|
7
|
+
/** 选项;可选 count 显示计数 */
|
|
8
|
+
options: {
|
|
9
|
+
label: string;
|
|
10
|
+
value: string;
|
|
11
|
+
count?: number;
|
|
12
|
+
}[];
|
|
13
|
+
modelValue: string;
|
|
14
|
+
};
|
|
15
|
+
declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
16
|
+
"update:modelValue": (value: string) => any;
|
|
17
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
18
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
19
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
20
|
+
declare const _default: typeof __VLS_export;
|
|
21
|
+
export default _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as FilterTabs } from './FilterTabs.vue';
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { FormRules } from 'element-plus';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
modelValue: boolean;
|
|
4
|
+
title: string;
|
|
5
|
+
width?: string;
|
|
6
|
+
loading?: boolean;
|
|
7
|
+
labelWidth?: string;
|
|
8
|
+
formData: Record<string, unknown>;
|
|
9
|
+
rules?: FormRules;
|
|
10
|
+
showFullscreenBtn?: boolean;
|
|
11
|
+
cancelText?: string;
|
|
12
|
+
confirmText?: string;
|
|
13
|
+
};
|
|
14
|
+
declare var __VLS_20: {
|
|
15
|
+
form: Record<string, unknown>;
|
|
16
|
+
};
|
|
17
|
+
type __VLS_Slots = {} & {
|
|
18
|
+
default?: (props: typeof __VLS_20) => any;
|
|
19
|
+
};
|
|
20
|
+
declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
21
|
+
"update:modelValue": (value: boolean) => any;
|
|
22
|
+
cancel: () => any;
|
|
23
|
+
submit: (data: Record<string, unknown>) => any;
|
|
24
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
25
|
+
"onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
|
|
26
|
+
onCancel?: (() => any) | undefined;
|
|
27
|
+
onSubmit?: ((data: Record<string, unknown>) => any) | undefined;
|
|
28
|
+
}>, {
|
|
29
|
+
width: string;
|
|
30
|
+
loading: boolean;
|
|
31
|
+
showFullscreenBtn: boolean;
|
|
32
|
+
cancelText: string;
|
|
33
|
+
confirmText: string;
|
|
34
|
+
labelWidth: string;
|
|
35
|
+
rules: FormRules;
|
|
36
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
37
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
38
|
+
declare const _default: typeof __VLS_export;
|
|
39
|
+
export default _default;
|
|
40
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
41
|
+
new (): {
|
|
42
|
+
$slots: S;
|
|
43
|
+
};
|
|
44
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as FormDialog } from './FormDialog.vue';
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
/** popover 宽度 */
|
|
3
|
+
width?: number | string;
|
|
4
|
+
};
|
|
5
|
+
declare var __VLS_14: {};
|
|
6
|
+
type __VLS_Slots = {} & {
|
|
7
|
+
default?: (props: typeof __VLS_14) => any;
|
|
8
|
+
};
|
|
9
|
+
declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
10
|
+
width: number | string;
|
|
11
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
12
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
13
|
+
declare const _default: typeof __VLS_export;
|
|
14
|
+
export default _default;
|
|
15
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
16
|
+
new (): {
|
|
17
|
+
$slots: S;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as HintText } from './HintText.vue';
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
/** 卡片标题 */
|
|
3
|
+
title: string;
|
|
4
|
+
/** JSON 字符串或已解析对象 */
|
|
5
|
+
data?: unknown;
|
|
6
|
+
/** 兼容旧 API:JSON 字符串 */
|
|
7
|
+
content?: string;
|
|
8
|
+
type?: 'json' | 'schema' | 'flow';
|
|
9
|
+
};
|
|
10
|
+
declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
11
|
+
click: () => any;
|
|
12
|
+
openDetail: () => any;
|
|
13
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
14
|
+
onClick?: (() => any) | undefined;
|
|
15
|
+
onOpenDetail?: (() => any) | undefined;
|
|
16
|
+
}>, {
|
|
17
|
+
type: "json" | "schema" | "flow";
|
|
18
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
19
|
+
declare const _default: typeof __VLS_export;
|
|
20
|
+
export default _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as JsonCard } from './JsonCard.vue';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
modelValue: boolean;
|
|
3
|
+
title?: string;
|
|
4
|
+
data?: unknown;
|
|
5
|
+
content?: string;
|
|
6
|
+
};
|
|
7
|
+
declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
8
|
+
"update:modelValue": (args_0: boolean) => any;
|
|
9
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
10
|
+
"onUpdate:modelValue"?: ((args_0: boolean) => any) | undefined;
|
|
11
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
12
|
+
declare const _default: typeof __VLS_export;
|
|
13
|
+
export default _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as JsonDetailDialog } from './JsonDetailDialog.vue';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* LoadingDots — 三点跳动加载指示
|
|
3
|
+
*/
|
|
4
|
+
type __VLS_Props = {
|
|
5
|
+
/** 圆点尺寸(px) */
|
|
6
|
+
size?: number;
|
|
7
|
+
};
|
|
8
|
+
declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
9
|
+
declare const _default: typeof __VLS_export;
|
|
10
|
+
export default _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as LoadingDots } from './LoadingDots.vue';
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* PageHeader — 统一页面标题栏
|
|
3
|
+
*
|
|
4
|
+
* 标题 + 副标题 + 右侧操作区(slot: actions;兼容 slot: extra)。
|
|
5
|
+
*/
|
|
6
|
+
type __VLS_Props = {
|
|
7
|
+
/** 页面标题 */
|
|
8
|
+
title: string;
|
|
9
|
+
/** 副标题 */
|
|
10
|
+
subtitle?: string;
|
|
11
|
+
};
|
|
12
|
+
declare var __VLS_1: {}, __VLS_3: {}, __VLS_5: {};
|
|
13
|
+
type __VLS_Slots = {} & {
|
|
14
|
+
default?: (props: typeof __VLS_1) => any;
|
|
15
|
+
} & {
|
|
16
|
+
actions?: (props: typeof __VLS_3) => any;
|
|
17
|
+
} & {
|
|
18
|
+
extra?: (props: typeof __VLS_5) => any;
|
|
19
|
+
};
|
|
20
|
+
declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
21
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
22
|
+
declare const _default: typeof __VLS_export;
|
|
23
|
+
export default _default;
|
|
24
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
25
|
+
new (): {
|
|
26
|
+
$slots: S;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as PageHeader } from './PageHeader.vue';
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* PageShell — 路由页统一外沿容器
|
|
3
|
+
*
|
|
4
|
+
* 为列表 / 设置页提供内边距、滚动与页面背景。
|
|
5
|
+
* 全幅页(对话、设计器)不要使用本组件。
|
|
6
|
+
*/
|
|
7
|
+
type __VLS_Props = {
|
|
8
|
+
/** 一屏填满:overflow hidden,末子 flex:1 可内滚 */
|
|
9
|
+
fill?: boolean;
|
|
10
|
+
};
|
|
11
|
+
declare var __VLS_1: {};
|
|
12
|
+
type __VLS_Slots = {} & {
|
|
13
|
+
default?: (props: typeof __VLS_1) => any;
|
|
14
|
+
};
|
|
15
|
+
declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
16
|
+
fill: boolean;
|
|
17
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
18
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
19
|
+
declare const _default: typeof __VLS_export;
|
|
20
|
+
export default _default;
|
|
21
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
22
|
+
new (): {
|
|
23
|
+
$slots: S;
|
|
24
|
+
};
|
|
25
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as PageShell } from './PageShell.vue';
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/** 轻量字段定义 */
|
|
2
|
+
export type SchemaLiteField = {
|
|
3
|
+
key: string;
|
|
4
|
+
label: string;
|
|
5
|
+
type: 'input' | 'textarea' | 'number' | 'select' | 'switch' | 'date';
|
|
6
|
+
placeholder?: string;
|
|
7
|
+
options?: Array<{
|
|
8
|
+
label: string;
|
|
9
|
+
value: string | number;
|
|
10
|
+
}>;
|
|
11
|
+
disabled?: boolean;
|
|
12
|
+
};
|
|
13
|
+
type __VLS_Props = {
|
|
14
|
+
/** 字段列表 */
|
|
15
|
+
fields: SchemaLiteField[];
|
|
16
|
+
/** 受控表单值 */
|
|
17
|
+
modelValue?: Record<string, unknown>;
|
|
18
|
+
/** 标签宽度 */
|
|
19
|
+
labelWidth?: string;
|
|
20
|
+
};
|
|
21
|
+
declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
22
|
+
"update:modelValue": (args_0: Record<string, unknown>) => any;
|
|
23
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
24
|
+
"onUpdate:modelValue"?: ((args_0: Record<string, unknown>) => any) | undefined;
|
|
25
|
+
}>, {
|
|
26
|
+
modelValue: Record<string, unknown>;
|
|
27
|
+
labelWidth: string;
|
|
28
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
29
|
+
declare const _default: typeof __VLS_export;
|
|
30
|
+
export default _default;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/** 搜索字段配置 */
|
|
2
|
+
export type SearchFieldConfig = {
|
|
3
|
+
key: string;
|
|
4
|
+
label: string;
|
|
5
|
+
type: 'input' | 'select' | 'date' | 'daterange';
|
|
6
|
+
options?: Array<{
|
|
7
|
+
label: string;
|
|
8
|
+
value: string | number;
|
|
9
|
+
}>;
|
|
10
|
+
placeholder?: string;
|
|
11
|
+
};
|
|
12
|
+
type __VLS_Props = {
|
|
13
|
+
fields: SearchFieldConfig[];
|
|
14
|
+
modelValue?: Record<string, unknown>;
|
|
15
|
+
collapsible?: boolean;
|
|
16
|
+
defaultCollapsed?: boolean;
|
|
17
|
+
defaultVisibleCount?: number;
|
|
18
|
+
};
|
|
19
|
+
declare function snapshot(): Record<string, unknown>;
|
|
20
|
+
declare function handleReset(): void;
|
|
21
|
+
declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {
|
|
22
|
+
getValues: typeof snapshot;
|
|
23
|
+
reset: typeof handleReset;
|
|
24
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
25
|
+
"update:modelValue": (args_0: Record<string, unknown>) => any;
|
|
26
|
+
search: (args_0: Record<string, unknown>) => any;
|
|
27
|
+
reset: () => any;
|
|
28
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
29
|
+
"onUpdate:modelValue"?: ((args_0: Record<string, unknown>) => any) | undefined;
|
|
30
|
+
onSearch?: ((args_0: Record<string, unknown>) => any) | undefined;
|
|
31
|
+
onReset?: (() => any) | undefined;
|
|
32
|
+
}>, {
|
|
33
|
+
modelValue: Record<string, unknown>;
|
|
34
|
+
collapsible: boolean;
|
|
35
|
+
defaultCollapsed: boolean;
|
|
36
|
+
defaultVisibleCount: number;
|
|
37
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
38
|
+
declare const _default: typeof __VLS_export;
|
|
39
|
+
export default _default;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
title: string;
|
|
3
|
+
count?: number;
|
|
4
|
+
defaultOpen?: boolean;
|
|
5
|
+
};
|
|
6
|
+
declare var __VLS_6: {};
|
|
7
|
+
type __VLS_Slots = {} & {
|
|
8
|
+
default?: (props: typeof __VLS_6) => any;
|
|
9
|
+
};
|
|
10
|
+
declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
11
|
+
defaultOpen: boolean;
|
|
12
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
13
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
14
|
+
declare const _default: typeof __VLS_export;
|
|
15
|
+
export default _default;
|
|
16
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
17
|
+
new (): {
|
|
18
|
+
$slots: S;
|
|
19
|
+
};
|
|
20
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as SectionToggle } from './SectionToggle.vue';
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Skeleton — 骨架屏
|
|
3
|
+
*
|
|
4
|
+
* 用于列表/卡片加载时的占位展示。
|
|
5
|
+
* 支持 card(卡片)、list(列表)、table(表格)三种预设。
|
|
6
|
+
*
|
|
7
|
+
* 用法:
|
|
8
|
+
* <Skeleton variant="card" :count="3" />
|
|
9
|
+
* <Skeleton variant="list" :rows="5" />
|
|
10
|
+
* <Skeleton variant="table" :rows="8" />
|
|
11
|
+
*/
|
|
12
|
+
type __VLS_Props = {
|
|
13
|
+
/** 骨架类型 */
|
|
14
|
+
variant?: 'card' | 'list' | 'table';
|
|
15
|
+
/** 数量(card/list 模式下的卡片/列表项数量) */
|
|
16
|
+
count?: number;
|
|
17
|
+
/** 行数(table 模式下的行数) */
|
|
18
|
+
rows?: number;
|
|
19
|
+
/** 是否开启动画(默认 true) */
|
|
20
|
+
animated?: boolean;
|
|
21
|
+
};
|
|
22
|
+
declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
23
|
+
count: number;
|
|
24
|
+
variant: "card" | "list" | "table";
|
|
25
|
+
rows: number;
|
|
26
|
+
animated: boolean;
|
|
27
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
28
|
+
declare const _default: typeof __VLS_export;
|
|
29
|
+
export default _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Skeleton } from './Skeleton.vue';
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export interface StatusConfig {
|
|
2
|
+
label: string;
|
|
3
|
+
type: 'success' | 'warning' | 'danger' | 'info' | 'primary' | '';
|
|
4
|
+
effect?: 'dark' | 'light' | 'plain';
|
|
5
|
+
}
|
|
6
|
+
type __VLS_Props = {
|
|
7
|
+
/** 状态值 */
|
|
8
|
+
status: string;
|
|
9
|
+
/** 自定义状态映射(合并到默认映射) */
|
|
10
|
+
statusMap?: Record<string, StatusConfig>;
|
|
11
|
+
/** 是否使用圆角样式(默认 true) */
|
|
12
|
+
round?: boolean;
|
|
13
|
+
/** 尺寸 */
|
|
14
|
+
size?: 'large' | 'default' | 'small';
|
|
15
|
+
};
|
|
16
|
+
declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
17
|
+
size: "large" | "default" | "small";
|
|
18
|
+
round: boolean;
|
|
19
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
20
|
+
declare const _default: typeof __VLS_export;
|
|
21
|
+
export default _default;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/** 行操作项 */
|
|
2
|
+
export interface TableRowAction {
|
|
3
|
+
key: string;
|
|
4
|
+
label: string;
|
|
5
|
+
/** AppIcon name(仅下拉菜单项) */
|
|
6
|
+
icon?: string;
|
|
7
|
+
type?: 'primary' | 'success' | 'warning' | 'danger' | 'info';
|
|
8
|
+
loading?: boolean;
|
|
9
|
+
onClick: () => void;
|
|
10
|
+
}
|
|
11
|
+
type __VLS_Props = {
|
|
12
|
+
actions: TableRowAction[];
|
|
13
|
+
/** 达到该数量时折叠 */
|
|
14
|
+
collapseAt?: number;
|
|
15
|
+
/** 折叠时直接展示的按钮数 */
|
|
16
|
+
visibleCount?: number;
|
|
17
|
+
};
|
|
18
|
+
declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
19
|
+
collapseAt: number;
|
|
20
|
+
visibleCount: number;
|
|
21
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
22
|
+
declare const _default: typeof __VLS_export;
|
|
23
|
+
export default _default;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export interface ToastItem {
|
|
2
|
+
id: number;
|
|
3
|
+
message: string;
|
|
4
|
+
type: 'info' | 'success' | 'error' | 'warning';
|
|
5
|
+
removing?: boolean;
|
|
6
|
+
}
|
|
7
|
+
declare function showToast(message: string, type?: ToastItem['type'], duration?: number): void;
|
|
8
|
+
declare const __VLS_export: import('vue').DefineComponent<{}, {
|
|
9
|
+
show: typeof showToast;
|
|
10
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
11
|
+
declare const _default: typeof __VLS_export;
|
|
12
|
+
export default _default;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
/** tooltip 完整内容 */
|
|
3
|
+
content: string;
|
|
4
|
+
placement?: 'top' | 'bottom' | 'left' | 'right';
|
|
5
|
+
maxWidth?: number;
|
|
6
|
+
};
|
|
7
|
+
declare var __VLS_8: {};
|
|
8
|
+
type __VLS_Slots = {} & {
|
|
9
|
+
default?: (props: typeof __VLS_8) => any;
|
|
10
|
+
};
|
|
11
|
+
declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
12
|
+
placement: "top" | "bottom" | "left" | "right";
|
|
13
|
+
maxWidth: number;
|
|
14
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
15
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
16
|
+
declare const _default: typeof __VLS_export;
|
|
17
|
+
export default _default;
|
|
18
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
19
|
+
new (): {
|
|
20
|
+
$slots: S;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as TruncatedTooltipText } from './TruncatedTooltipText.vue';
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
declare const _default: typeof __VLS_export;
|
|
2
|
+
export default _default;
|
|
3
|
+
declare const __VLS_export: import('vue').DefineComponent<{
|
|
4
|
+
/** 用户名(取首字母作为 fallback) */
|
|
5
|
+
name?: string;
|
|
6
|
+
/** 头像图片 URL */
|
|
7
|
+
src?: string;
|
|
8
|
+
/** 尺寸(px,默认 32 = `--avatar-size-md`) */
|
|
9
|
+
size?: number;
|
|
10
|
+
/** 形状(默认 'circle') */
|
|
11
|
+
shape?: "circle" | "square";
|
|
12
|
+
}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{
|
|
13
|
+
/** 用户名(取首字母作为 fallback) */
|
|
14
|
+
name?: string;
|
|
15
|
+
/** 头像图片 URL */
|
|
16
|
+
src?: string;
|
|
17
|
+
/** 尺寸(px,默认 32 = `--avatar-size-md`) */
|
|
18
|
+
size?: number;
|
|
19
|
+
/** 形状(默认 'circle') */
|
|
20
|
+
shape?: "circle" | "square";
|
|
21
|
+
}> & Readonly<{}>, {
|
|
22
|
+
name: string;
|
|
23
|
+
size: number;
|
|
24
|
+
src: string;
|
|
25
|
+
shape: "circle" | "square";
|
|
26
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as UserAvatar } from './UserAvatar.vue';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export { useToast, provideToast } from './useToast';
|
|
2
|
+
export { useConfirm } from './useConfirm';
|
|
3
|
+
export type { ConfirmOptions } from './useConfirm';
|
|
4
|
+
export { useMessage } from './useMessage';
|
|
5
|
+
export type { MessageApi } from './useMessage';
|
|
6
|
+
export { useDebounceFn } from './useDebounceFn';
|
|
7
|
+
export { useClientPagination } from './useClientPagination';
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { Ref, ComputedRef } from 'vue';
|
|
2
|
+
/**
|
|
3
|
+
* @param source - 完整列表(可为 computed)
|
|
4
|
+
* @param options - initialPageSize / resetOn 依赖变化时重置到第 1 页
|
|
5
|
+
*/
|
|
6
|
+
export declare function useClientPagination<T>(source: Ref<T[]> | ComputedRef<T[]>, options?: {
|
|
7
|
+
initialPageSize?: number;
|
|
8
|
+
resetOn?: Array<Ref<unknown> | ComputedRef<unknown>>;
|
|
9
|
+
}): {
|
|
10
|
+
currentPage: Ref<number, number>;
|
|
11
|
+
pageSize: Ref<number, number>;
|
|
12
|
+
pagedItems: ComputedRef<T[]>;
|
|
13
|
+
total: ComputedRef<number>;
|
|
14
|
+
resetPage: () => void;
|
|
15
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export interface ConfirmOptions {
|
|
2
|
+
/** 标题(默认 '确认操作') */
|
|
3
|
+
title?: string;
|
|
4
|
+
/** 类型(默认 'warning') */
|
|
5
|
+
type?: 'info' | 'warning' | 'danger' | 'success';
|
|
6
|
+
/** 确认按钮文案(默认 '确定') */
|
|
7
|
+
confirmButtonText?: string;
|
|
8
|
+
/** 取消按钮文案(默认 '取消') */
|
|
9
|
+
cancelButtonText?: string;
|
|
10
|
+
}
|
|
11
|
+
export declare function useConfirm(): {
|
|
12
|
+
confirm: (message: string, options?: ConfirmOptions) => Promise<boolean>;
|
|
13
|
+
confirmDelete: (target: string, options?: Omit<ConfirmOptions, "type">) => Promise<boolean>;
|
|
14
|
+
confirmDanger: (message: string, options?: Omit<ConfirmOptions, "type">) => Promise<boolean>;
|
|
15
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function useDebounceFn<T extends (...args: unknown[]) => unknown>(fn: T, delay?: number): (...args: Parameters<T>) => void;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { MessageOptions } from 'element-plus';
|
|
2
|
+
export interface MessageApi {
|
|
3
|
+
success(message: string, options?: Partial<MessageOptions>): void;
|
|
4
|
+
error(message: string, options?: Partial<MessageOptions>): void;
|
|
5
|
+
warning(message: string, options?: Partial<MessageOptions>): void;
|
|
6
|
+
info(message: string, options?: Partial<MessageOptions>): void;
|
|
7
|
+
}
|
|
8
|
+
export declare function useMessage(): MessageApi;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
import { ToastItem } from '../components/Toast/Toast.vue';
|
|
3
|
+
interface ToastExpose {
|
|
4
|
+
show: (message: string, type?: ToastItem['type'], duration?: number) => void;
|
|
5
|
+
}
|
|
6
|
+
declare const TOAST_KEY: unique symbol;
|
|
7
|
+
export declare function provideToast(ref: Ref<ToastExpose | undefined>): {
|
|
8
|
+
[TOAST_KEY]: Ref<ToastExpose | undefined, ToastExpose | undefined>;
|
|
9
|
+
};
|
|
10
|
+
export declare function useToast(): {
|
|
11
|
+
show(message: string, type?: ToastItem["type"], duration?: number): void;
|
|
12
|
+
info(message: string, duration?: number): void;
|
|
13
|
+
success(message: string, duration?: number): void;
|
|
14
|
+
warning(message: string, duration?: number): void;
|
|
15
|
+
error(message: string, duration?: number): void;
|
|
16
|
+
};
|
|
17
|
+
export {};
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @apform-ui/core — Apform UI 企业级 Vue 3 UI 组件库(基于 Element Plus 2.14.2 fork)
|
|
3
|
+
*
|
|
4
|
+
* Fork 基准版本:Element Plus 2.14.2
|
|
5
|
+
* Fork 日期:2026-08-27
|
|
6
|
+
*/
|
|
7
|
+
export * from './types';
|
|
8
|
+
export { AppDialog } from './components/AppDialog';
|
|
9
|
+
export { AppIcon } from './components/AppIcon';
|
|
10
|
+
export { AppPagination } from './components/AppPagination';
|
|
11
|
+
export { ConfirmDialog } from './components/ConfirmDialog';
|
|
12
|
+
export { FormDialog } from './components/FormDialog';
|
|
13
|
+
export { FilterTabs } from './components/FilterTabs';
|
|
14
|
+
export { Toast } from './components/Toast';
|
|
15
|
+
export type { ToastItem } from './components/Toast';
|
|
16
|
+
export { EmptyState } from './components/EmptyState';
|
|
17
|
+
export { ErrorBoundary } from './components/ErrorBoundary';
|
|
18
|
+
export { StatusTag } from './components/StatusTag';
|
|
19
|
+
export type { StatusConfig } from './components/StatusTag';
|
|
20
|
+
export { Skeleton } from './components/Skeleton';
|
|
21
|
+
export { CardGridSkeleton } from './components/CardGridSkeleton';
|
|
22
|
+
export { UserAvatar } from './components/UserAvatar';
|
|
23
|
+
export { PageShell } from './components/PageShell';
|
|
24
|
+
export { PageHeader } from './components/PageHeader';
|
|
25
|
+
export { ContentPanel } from './components/ContentPanel';
|
|
26
|
+
export { FilterBar } from './components/FilterBar';
|
|
27
|
+
export { CardTable } from './components/CardTable';
|
|
28
|
+
export { TableRowActions } from './components/TableRowActions';
|
|
29
|
+
export type { TableRowAction } from './components/TableRowActions';
|
|
30
|
+
export { SearchForm } from './components/SearchForm';
|
|
31
|
+
export type { SearchFieldConfig } from './components/SearchForm';
|
|
32
|
+
export { FieldRow } from './components/FieldRow';
|
|
33
|
+
export { HintText } from './components/HintText';
|
|
34
|
+
export { SectionToggle } from './components/SectionToggle';
|
|
35
|
+
export { TruncatedTooltipText } from './components/TruncatedTooltipText';
|
|
36
|
+
export { LoadingDots } from './components/LoadingDots';
|
|
37
|
+
export { JsonCard } from './components/JsonCard';
|
|
38
|
+
export { JsonDetailDialog } from './components/JsonDetailDialog';
|
|
39
|
+
export { SchemaLitePreview } from './components/SchemaLitePreview';
|
|
40
|
+
export type { SchemaLiteField } from './components/SchemaLitePreview';
|
|
41
|
+
export { MessageBubble } from './components/Chat/MessageBubble';
|
|
42
|
+
export { MessageList } from './components/Chat/MessageList';
|
|
43
|
+
export { Composer } from './components/Chat/Composer';
|
|
44
|
+
export { RunStatusBar } from './components/Chat/RunStatusBar';
|
|
45
|
+
export { ApprovalCard } from './components/Chat/ApprovalCard';
|
|
46
|
+
export { MessageParts, MessageAttachmentList, DocumentSummaryList, AttachmentPreviewModal, } from './components/Chat/message';
|
|
47
|
+
export { SessionSidebar } from './components/Chat/SessionSidebar';
|
|
48
|
+
export { ProcessingDrawer } from './components/Chat/ProcessingDrawer';
|
|
49
|
+
export { ConversationHeader } from './components/Chat/ConversationHeader';
|
|
50
|
+
export { useToast, provideToast } from './composables';
|
|
51
|
+
export { useConfirm } from './composables';
|
|
52
|
+
export type { ConfirmOptions } from './composables';
|
|
53
|
+
export { useMessage } from './composables';
|
|
54
|
+
export type { MessageApi } from './composables';
|
|
55
|
+
export { useDebounceFn } from './composables';
|
|
56
|
+
export { useClientPagination } from './composables';
|
|
57
|
+
export { ICON_MAP, APP_ICON_NAMES, isRegisteredAppIcon } from './utils';
|
|
58
|
+
export type { AppIconName } from './utils';
|
|
59
|
+
export { DEFAULT_PAGE_SIZE, PAGE_SIZE_OPTIONS, PAGINATION_LAYOUT } from './utils';
|
|
60
|
+
export type { PageSizeOption } from './utils';
|
|
61
|
+
export { resolveApiErrorMessage } from './utils';
|
|
62
|
+
export type { ApiError } from './utils';
|
|
63
|
+
export { renderMarkdown, splitTextAndCodeBlocks } from './utils/textParser';
|
|
64
|
+
export type { TextPart } from './utils/textParser';
|
|
65
|
+
export { isImage, isPdf, isOffice, isPreviewable, fileKind, formatSize } from './utils/attachmentKind';
|
|
66
|
+
export { COLORS, TEXT_COLORS, SPACING, BORDER_RADIUS, SHADOWS, DURATION, Z_INDEX, FONT_SIZE, CONTROL_HEIGHT, LAYOUT_HEIGHT, ICON_SIZE, PAGE, FORM, AVATAR_SIZE, } from './tokens';
|
|
67
|
+
export declare const SCHEMA_UI_VERSION = "1.2.0";
|
|
68
|
+
export declare const EP_FORK_BASE = "2.14.2";
|
|
69
|
+
export declare const EP_FORK_DATE = "2026-08-27";
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/vue3';
|
|
2
|
+
import { default as AppDialog } from '../components/AppDialog/AppDialog.vue';
|
|
3
|
+
declare const meta: Meta<typeof AppDialog>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof AppDialog>;
|
|
6
|
+
export declare const Basic: Story;
|
|
7
|
+
export declare const Fullscreen: Story;
|
|
8
|
+
export declare const CustomButtons: Story;
|
|
9
|
+
export declare const Loading: Story;
|