v-nuxt-ui 0.1.10 → 0.1.14
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/module.json +2 -2
- package/dist/module.mjs +1 -0
- package/dist/runtime/components/date-picker/index.d.vue.ts +2 -1
- package/dist/runtime/components/date-picker/index.vue +1 -1
- package/dist/runtime/components/date-picker/index.vue.d.ts +2 -1
- package/dist/runtime/components/form/create-modal-template/WithApi.d.vue.ts +2 -2
- package/dist/runtime/components/form/create-modal-template/WithApi.vue.d.ts +2 -2
- package/dist/runtime/components/form/create-modal-template/index.d.vue.ts +2 -2
- package/dist/runtime/components/form/create-modal-template/index.vue.d.ts +2 -2
- package/dist/runtime/components/simple-table/index.d.vue.ts +1 -1
- package/dist/runtime/components/simple-table/index.vue.d.ts +1 -1
- package/dist/runtime/components/table/header/settings/columns/DndList.d.vue.ts +5 -5
- package/dist/runtime/components/table/header/settings/columns/DndList.vue.d.ts +5 -5
- package/dist/runtime/components/table/header/settings/columns/Item.d.vue.ts +3 -3
- package/dist/runtime/components/table/header/settings/columns/Item.vue +1 -1
- package/dist/runtime/components/table/header/settings/columns/Item.vue.d.ts +3 -3
- package/dist/runtime/composables/api/index.d.ts +0 -1
- package/dist/runtime/composables/api/index.js +0 -1
- package/dist/runtime/composables/api/sys/useAuthApi.d.ts +4 -4
- package/dist/runtime/composables/api/sys/useCompanyApi.d.ts +2 -1
- package/dist/runtime/composables/api/sys/useDepartmentApi.d.ts +2 -2
- package/dist/runtime/composables/api/sys/useJobTitleApi.d.ts +2 -1
- package/dist/runtime/composables/api/sys/useLoginApi.d.ts +4 -4
- package/dist/runtime/composables/api/sys/useMenuApi.d.ts +2 -2
- package/dist/runtime/composables/api/sys/useRoleApi.d.ts +2 -2
- package/dist/runtime/composables/api/sys/useRowRecord.d.ts +4 -4
- package/dist/runtime/composables/api/sys/useUserApi.d.ts +3 -3
- package/dist/runtime/composables/api/useModel.d.ts +2 -1
- package/dist/runtime/composables/flow/index.d.ts +0 -2
- package/dist/runtime/composables/flow/index.js +0 -2
- package/dist/runtime/composables/table/useTableColumns.d.ts +3 -3
- package/dist/runtime/composables/table/useTablePagination.d.ts +2 -2
- package/dist/runtime/composables/table/useTableQuery.d.ts +3 -3
- package/dist/runtime/composables/useAuth.d.ts +112 -5
- package/dist/runtime/composables/useAuth.js +1 -1
- package/dist/runtime/composables/useDate.d.ts +2 -1
- package/dist/runtime/composables/useForm.d.ts +2 -2
- package/dist/runtime/composables/useForm.js +1 -1
- package/dist/runtime/composables/usePermission.d.ts +3 -2
- package/dist/runtime/composables/useSidebarMenu.d.ts +37 -19
- package/dist/runtime/constants/columns.d.ts +3 -3
- package/dist/runtime/constants/time.d.ts +1 -0
- package/dist/runtime/types/cmds/index.d.ts +3 -0
- package/dist/runtime/types/cmds/index.js +3 -0
- package/dist/runtime/types/cmds/login.d.ts +19 -23
- package/dist/runtime/types/cmds/login.js +0 -0
- package/dist/runtime/types/cmds/sys.d.ts +7 -10
- package/dist/runtime/types/cmds/sys.js +0 -0
- package/dist/runtime/types/cmds/user.d.ts +4 -8
- package/dist/runtime/types/cmds/user.js +0 -0
- package/dist/runtime/types/index.d.ts +3 -1
- package/dist/runtime/types/index.js +3 -1
- package/dist/runtime/types/models/base.d.ts +12 -15
- package/dist/runtime/types/models/base.js +0 -0
- package/dist/runtime/types/models/index.d.ts +2 -0
- package/dist/runtime/types/models/index.js +2 -0
- package/dist/runtime/types/models/sys.d.ts +84 -107
- package/dist/runtime/types/models/sys.js +0 -0
- package/dist/runtime/types/storage.d.ts +13 -0
- package/package.json +7 -1
- package/dist/runtime/composables/api/flow/index.d.ts +0 -3
- package/dist/runtime/composables/api/flow/index.js +0 -3
- package/dist/runtime/composables/api/flow/useFlowApi.d.ts +0 -1
- package/dist/runtime/composables/api/flow/useFlowApi.js +0 -3
- package/dist/runtime/composables/api/flow/useFlowNodeApi.d.ts +0 -1
- package/dist/runtime/composables/api/flow/useFlowNodeApi.js +0 -3
- package/dist/runtime/composables/api/flow/useFlowNodeLinkApi.d.ts +0 -1
- package/dist/runtime/composables/api/flow/useFlowNodeLinkApi.js +0 -3
- package/dist/runtime/composables/flow/useFlow.d.ts +0 -46
- package/dist/runtime/composables/flow/useFlow.js +0 -162
- package/dist/runtime/composables/flow/useFlowResize.d.ts +0 -56
- package/dist/runtime/composables/flow/useFlowResize.js +0 -148
- package/dist/runtime/types/constants/time.d.ts +0 -5
- package/dist/runtime/types/localStorage.d.ts +0 -15
- package/dist/runtime/types/models/flow.d.ts +0 -31
|
@@ -1,37 +1,55 @@
|
|
|
1
|
-
import type { BreadcrumbItem, NavigationMenuItem } from '@nuxt/ui';
|
|
2
1
|
import type { ComputedRef, Ref } from 'vue';
|
|
2
|
+
import type { Menu, Role } from '#v/types';
|
|
3
|
+
type ShallowNavigationMenuItem = {
|
|
4
|
+
to?: string;
|
|
5
|
+
triggerTo?: string;
|
|
6
|
+
children?: ShallowNavigationMenuItem[];
|
|
7
|
+
label?: string;
|
|
8
|
+
icon?: string;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
open?: boolean;
|
|
11
|
+
defaultOpen?: boolean;
|
|
12
|
+
staticRouteKeys?: string[];
|
|
13
|
+
};
|
|
14
|
+
type ShallowBreadcrumbItem = {
|
|
15
|
+
label?: string;
|
|
16
|
+
icon?: string;
|
|
17
|
+
to?: string;
|
|
18
|
+
children?: ShallowBreadcrumbItem[];
|
|
19
|
+
};
|
|
3
20
|
export declare function setGlobalSidebarMenus(opts: {
|
|
4
|
-
constantMenus?:
|
|
5
|
-
bizMenus?:
|
|
21
|
+
constantMenus?: ShallowNavigationMenuItem[];
|
|
22
|
+
bizMenus?: ShallowNavigationMenuItem[];
|
|
6
23
|
menuMode?: 'static' | 'dynamic';
|
|
7
24
|
}): void;
|
|
8
25
|
export declare const _useSidebarMenus: () => {
|
|
9
|
-
constantMenus: Ref<
|
|
26
|
+
constantMenus: Ref<ShallowNavigationMenuItem[]>;
|
|
10
27
|
constantMenuPathSet: ComputedRef<Set<string>>;
|
|
11
|
-
bizMenus: Ref<
|
|
12
|
-
flattenBizMenus: ComputedRef<
|
|
28
|
+
bizMenus: Ref<ShallowNavigationMenuItem[]>;
|
|
29
|
+
flattenBizMenus: ComputedRef<ShallowNavigationMenuItem[]>;
|
|
13
30
|
bizMenuPathSet: ComputedRef<Set<string>>;
|
|
14
|
-
menusFromUser: Ref<
|
|
15
|
-
sidebarMenus: Ref<
|
|
31
|
+
menusFromUser: Ref<Menu[]>;
|
|
32
|
+
sidebarMenus: Ref<ShallowNavigationMenuItem[]>;
|
|
16
33
|
sidebarMenuPathSet: Ref<Set<string>>;
|
|
17
34
|
expandSidebarMenu: (path: string) => void;
|
|
18
|
-
setUserDynamicMenus: (newRolesFromUser:
|
|
35
|
+
setUserDynamicMenus: (newRolesFromUser: Role[], newMenusFromUser: Menu[]) => void;
|
|
19
36
|
disabledMenuPathSet: ComputedRef<Set<string>>;
|
|
20
|
-
breadcrumbs: Ref<
|
|
21
|
-
getBreadcrumbs: (current: string, menus?:
|
|
37
|
+
breadcrumbs: Ref<ShallowBreadcrumbItem[]>;
|
|
38
|
+
getBreadcrumbs: (current: string, menus?: ShallowNavigationMenuItem[]) => ShallowBreadcrumbItem[];
|
|
22
39
|
};
|
|
23
40
|
export declare const useSidebarMenus: () => {
|
|
24
|
-
constantMenus: Ref<
|
|
41
|
+
constantMenus: Ref<ShallowNavigationMenuItem[]>;
|
|
25
42
|
constantMenuPathSet: ComputedRef<Set<string>>;
|
|
26
|
-
bizMenus: Ref<
|
|
27
|
-
flattenBizMenus: ComputedRef<
|
|
43
|
+
bizMenus: Ref<ShallowNavigationMenuItem[]>;
|
|
44
|
+
flattenBizMenus: ComputedRef<ShallowNavigationMenuItem[]>;
|
|
28
45
|
bizMenuPathSet: ComputedRef<Set<string>>;
|
|
29
|
-
menusFromUser: Ref<
|
|
30
|
-
sidebarMenus: Ref<
|
|
46
|
+
menusFromUser: Ref<Menu[]>;
|
|
47
|
+
sidebarMenus: Ref<ShallowNavigationMenuItem[]>;
|
|
31
48
|
sidebarMenuPathSet: Ref<Set<string>>;
|
|
32
49
|
expandSidebarMenu: (path: string) => void;
|
|
33
|
-
setUserDynamicMenus: (newRolesFromUser:
|
|
50
|
+
setUserDynamicMenus: (newRolesFromUser: Role[], newMenusFromUser: Menu[]) => void;
|
|
34
51
|
disabledMenuPathSet: ComputedRef<Set<string>>;
|
|
35
|
-
breadcrumbs: Ref<
|
|
36
|
-
getBreadcrumbs: (current: string, menus?:
|
|
52
|
+
breadcrumbs: Ref<ShallowBreadcrumbItem[]>;
|
|
53
|
+
getBreadcrumbs: (current: string, menus?: ShallowNavigationMenuItem[]) => ShallowBreadcrumbItem[];
|
|
37
54
|
};
|
|
55
|
+
export {};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { OrderQueryOpr, VColumn } from '#v/types';
|
|
2
|
-
export declare const getCreateAtColumn: <T extends
|
|
3
|
-
export declare const getOprColumns: <T extends
|
|
1
|
+
import type { BaseModel, OrderQueryOpr, VColumn } from '#v/types';
|
|
2
|
+
export declare const getCreateAtColumn: <T extends BaseModel>(createdAtSortOpr?: OrderQueryOpr) => VColumn<T>;
|
|
3
|
+
export declare const getOprColumns: <T extends BaseModel>(createdAtSortOpr?: OrderQueryOpr) => VColumn<T>[];
|
|
@@ -5,3 +5,4 @@ export declare const weekEnLabels: string[];
|
|
|
5
5
|
export declare const weekCnLabels: string[];
|
|
6
6
|
export declare const dateFormat = "YYYY-MM-DD";
|
|
7
7
|
export declare const dateTimeFormat = "YYYY-MM-DD HH:mm:ss";
|
|
8
|
+
export type TimeUnit = 'day' | 'week' | 'month' | 'quarter' | 'year';
|
|
@@ -1,23 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
username?: string
|
|
4
|
-
password?: string
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
dupLogin?: boolean
|
|
21
|
-
user?: Model.User
|
|
22
|
-
}
|
|
23
|
-
}
|
|
1
|
+
import type { User } from '../models/index.js';
|
|
2
|
+
export type UsernamePasswordLoginPayload = {
|
|
3
|
+
username?: string;
|
|
4
|
+
password?: string;
|
|
5
|
+
};
|
|
6
|
+
export type RefreshTokensPayload = {
|
|
7
|
+
refreshToken: string;
|
|
8
|
+
};
|
|
9
|
+
export type ChangeUserPwdCmd = {
|
|
10
|
+
userId: number;
|
|
11
|
+
oldPwd: string;
|
|
12
|
+
newPwd: string;
|
|
13
|
+
};
|
|
14
|
+
export type LoginResult = {
|
|
15
|
+
refreshToken?: string;
|
|
16
|
+
accessToken?: string;
|
|
17
|
+
dupLogin?: boolean;
|
|
18
|
+
user?: User;
|
|
19
|
+
};
|
|
File without changes
|
|
@@ -1,10 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
id: number
|
|
9
|
-
}
|
|
10
|
-
}
|
|
1
|
+
export type RowRecordPayload = {
|
|
2
|
+
tableName?: string;
|
|
3
|
+
rowId?: number;
|
|
4
|
+
};
|
|
5
|
+
export type IdPayload = {
|
|
6
|
+
id: number;
|
|
7
|
+
};
|
|
File without changes
|
|
File without changes
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import type { BadgeProps } from '@nuxt/ui';
|
|
2
|
+
export * from './cmds/index.js';
|
|
3
|
+
export * from './models/index.js';
|
|
4
|
+
export * from './components/index.js';
|
|
2
5
|
export * from './app.js';
|
|
3
6
|
export * from './locale.js';
|
|
4
7
|
export * from './request.js';
|
|
5
|
-
export * from './components/index.js';
|
|
6
8
|
export * from './query.js';
|
|
7
9
|
export * from './storage.js';
|
|
8
10
|
export type Size = import('@nuxt/ui').ButtonProps['size'];
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
export * from "./cmds/index.js";
|
|
2
|
+
export * from "./models/index.js";
|
|
3
|
+
export * from "./components/index.js";
|
|
1
4
|
export * from "./app.js";
|
|
2
5
|
export * from "./locale.js";
|
|
3
6
|
export * from "./request.js";
|
|
4
|
-
export * from "./components/index.js";
|
|
5
7
|
export * from "./query.js";
|
|
6
8
|
export * from "./storage.js";
|
|
@@ -1,16 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
updater?: any
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
type UniqueKey = {
|
|
14
|
-
key?: string
|
|
15
|
-
}
|
|
1
|
+
export interface BaseModel {
|
|
2
|
+
id: number;
|
|
3
|
+
createdAt?: string;
|
|
4
|
+
updatedAt?: string;
|
|
5
|
+
version?: number;
|
|
6
|
+
createdBy?: number;
|
|
7
|
+
creator?: any;
|
|
8
|
+
updatedBy?: number;
|
|
9
|
+
updater?: any;
|
|
16
10
|
}
|
|
11
|
+
export type UniqueKey = {
|
|
12
|
+
key?: string;
|
|
13
|
+
};
|
|
File without changes
|
|
@@ -1,107 +1,84 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
isAdmin?: boolean
|
|
4
|
-
type?: string
|
|
5
|
-
parentId?: number
|
|
6
|
-
parent?: Menu
|
|
7
|
-
name?: string
|
|
8
|
-
i18nKey?: string
|
|
9
|
-
staticRouteKeys?: string[]
|
|
10
|
-
permission?: string
|
|
11
|
-
order?: string
|
|
12
|
-
disabled?: boolean
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
roles?: Role[] // 角色
|
|
87
|
-
menus?: Menu[] // 菜单权限
|
|
88
|
-
|
|
89
|
-
needChangePwd?: boolean // 是否需要修改密码
|
|
90
|
-
|
|
91
|
-
needFillWh?: boolean // 是否需要填写工时
|
|
92
|
-
|
|
93
|
-
isAdmin?: boolean
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
type RowRecord = {
|
|
97
|
-
rowId?: number
|
|
98
|
-
rowVersion?: number
|
|
99
|
-
key?: string
|
|
100
|
-
oldValue?: string
|
|
101
|
-
newValue?: string
|
|
102
|
-
} & BaseModel
|
|
103
|
-
|
|
104
|
-
type UniqueKey = {
|
|
105
|
-
key?: string
|
|
106
|
-
}
|
|
107
|
-
}
|
|
1
|
+
import type { BaseModel } from './base.js';
|
|
2
|
+
export type Menu = {
|
|
3
|
+
isAdmin?: boolean;
|
|
4
|
+
type?: string;
|
|
5
|
+
parentId?: number;
|
|
6
|
+
parent?: Menu;
|
|
7
|
+
name?: string;
|
|
8
|
+
i18nKey?: string;
|
|
9
|
+
staticRouteKeys?: string[];
|
|
10
|
+
permission?: string;
|
|
11
|
+
order?: string;
|
|
12
|
+
disabled?: boolean;
|
|
13
|
+
} & BaseModel;
|
|
14
|
+
export type Role = {
|
|
15
|
+
isAdmin?: boolean;
|
|
16
|
+
name?: string;
|
|
17
|
+
permission?: string;
|
|
18
|
+
disabled?: boolean;
|
|
19
|
+
remark?: string;
|
|
20
|
+
menus?: Menu[];
|
|
21
|
+
} & BaseModel;
|
|
22
|
+
export type Company = {
|
|
23
|
+
fullname?: string;
|
|
24
|
+
nickname?: string;
|
|
25
|
+
} & BaseModel;
|
|
26
|
+
export type Department = {
|
|
27
|
+
name?: string;
|
|
28
|
+
companyId?: number;
|
|
29
|
+
company?: Company;
|
|
30
|
+
leaderId?: number;
|
|
31
|
+
leader?: User;
|
|
32
|
+
parentId?: number;
|
|
33
|
+
parent?: Department;
|
|
34
|
+
} & BaseModel;
|
|
35
|
+
export type JobTitle = {
|
|
36
|
+
name?: string;
|
|
37
|
+
description?: string;
|
|
38
|
+
disabled?: boolean;
|
|
39
|
+
remark?: string;
|
|
40
|
+
} & BaseModel;
|
|
41
|
+
export type JobGrade = {
|
|
42
|
+
name?: string;
|
|
43
|
+
description?: string;
|
|
44
|
+
disabled?: boolean;
|
|
45
|
+
remark?: string;
|
|
46
|
+
} & BaseModel;
|
|
47
|
+
export type User = {
|
|
48
|
+
id: number;
|
|
49
|
+
createdAt?: string;
|
|
50
|
+
updatedAt?: string;
|
|
51
|
+
version?: number;
|
|
52
|
+
userCreatedBy?: number;
|
|
53
|
+
creator?: User;
|
|
54
|
+
userUpdatedBy?: number;
|
|
55
|
+
updater?: User;
|
|
56
|
+
nickname?: string;
|
|
57
|
+
jobTitleId?: number;
|
|
58
|
+
jobTitle?: JobTitle;
|
|
59
|
+
jobGradeId?: number;
|
|
60
|
+
jobGrade?: JobGrade;
|
|
61
|
+
departmentId?: number;
|
|
62
|
+
department?: Department;
|
|
63
|
+
supervisorId?: number;
|
|
64
|
+
supervisor?: User;
|
|
65
|
+
entryDate?: string;
|
|
66
|
+
resignDate?: string;
|
|
67
|
+
gender?: number;
|
|
68
|
+
username?: string;
|
|
69
|
+
email?: string;
|
|
70
|
+
telNo?: string;
|
|
71
|
+
loginType?: string;
|
|
72
|
+
roles?: Role[];
|
|
73
|
+
menus?: Menu[];
|
|
74
|
+
needChangePwd?: boolean;
|
|
75
|
+
needFillWh?: boolean;
|
|
76
|
+
isAdmin?: boolean;
|
|
77
|
+
};
|
|
78
|
+
export type RowRecord = {
|
|
79
|
+
rowId?: number;
|
|
80
|
+
rowVersion?: number;
|
|
81
|
+
key?: string;
|
|
82
|
+
oldValue?: string;
|
|
83
|
+
newValue?: string;
|
|
84
|
+
} & BaseModel;
|
|
File without changes
|
|
@@ -8,3 +8,16 @@ export declare enum StorageKey {
|
|
|
8
8
|
FLOW_EDGE_MARKER_END = "flow_edge_marker_end",
|
|
9
9
|
FLOW_NODE_BORDER_WIDTH = "flow_node_border_width"
|
|
10
10
|
}
|
|
11
|
+
export type Column = {
|
|
12
|
+
accessorKey: string;
|
|
13
|
+
checked?: boolean;
|
|
14
|
+
width?: string | number;
|
|
15
|
+
fixed: 'left' | 'right' | 'unfixed';
|
|
16
|
+
};
|
|
17
|
+
export type TableSettings<T> = {
|
|
18
|
+
columns?: Column[];
|
|
19
|
+
pageSize?: number;
|
|
20
|
+
whereQuery?: import('./query').WhereQuery<T>;
|
|
21
|
+
whereQueryOpen?: boolean;
|
|
22
|
+
orderQuery?: import('./query').OrderQuery<T>;
|
|
23
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "v-nuxt-ui",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.14",
|
|
4
4
|
"description": "Veken UI Component Library - Reusable Nuxt UI components, composables, and utilities for enterprise applications",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"style": "./dist/runtime/index.css",
|
|
@@ -84,14 +84,19 @@
|
|
|
84
84
|
"echarts": "^6.0.0",
|
|
85
85
|
"eslint": "^9.39.3",
|
|
86
86
|
"exceljs": "^4.4.0",
|
|
87
|
+
"fflate": "^0.8.2",
|
|
88
|
+
"json5": "^2.2.3",
|
|
87
89
|
"monaco-editor": "^0.55.1",
|
|
88
90
|
"nuxt": "^4.3.1",
|
|
91
|
+
"ohash": "^2.0.11",
|
|
89
92
|
"reka-ui": "^2.9.2",
|
|
93
|
+
"scule": "^1.3.0",
|
|
90
94
|
"shiki": "^3.23.0",
|
|
91
95
|
"sql-formatter": "^15.7.2",
|
|
92
96
|
"sortablejs": "^1.15.7",
|
|
93
97
|
"tailwindcss": "^4.2.2",
|
|
94
98
|
"typescript": "^5.9.3",
|
|
99
|
+
"unbuild": "^3.6.1",
|
|
95
100
|
"vue": "^3.5.0",
|
|
96
101
|
"vue-draggable-plus": "^0.6.1",
|
|
97
102
|
"vue-echarts": "^8.0.1",
|
|
@@ -102,6 +107,7 @@
|
|
|
102
107
|
"pnpm": {
|
|
103
108
|
"onlyBuiltDependencies": [
|
|
104
109
|
"@parcel/watcher",
|
|
110
|
+
"better-sqlite3",
|
|
105
111
|
"esbuild",
|
|
106
112
|
"unrs-resolver",
|
|
107
113
|
"vue-demi"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const useFlowApi: () => import("../../../types/index.js").ApiGroup<Model.Flow>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const useFlowNodeApi: () => import("../../../types/index.js").ApiGroup<Model.FlowNode>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const useFlowNodeLinkApi: () => import("../../../types/index.js").ApiGroup<Model.FlowNodeLink>;
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import { type Node } from '@vue-flow/core';
|
|
2
|
-
import type { Ref } from 'vue';
|
|
3
|
-
export interface UseFlowOptions {
|
|
4
|
-
flow?: Ref<Model.Flow | undefined>;
|
|
5
|
-
onUpdateModel?: Ref<((model: Model.Flow) => void) | undefined>;
|
|
6
|
-
}
|
|
7
|
-
export interface UseFlowReturn {
|
|
8
|
-
nodes: Ref<any[]>;
|
|
9
|
-
edges: Ref<any[]>;
|
|
10
|
-
GRID_SIZE: number;
|
|
11
|
-
syncNodes: (nodeHandlers?: (nodeId: string) => any) => void;
|
|
12
|
-
syncEdges: (styleOptions?: {
|
|
13
|
-
strokeWidth?: number;
|
|
14
|
-
markerStart?: boolean;
|
|
15
|
-
markerEnd?: boolean;
|
|
16
|
-
}) => void;
|
|
17
|
-
applyEdgeStyles: (styleOptions: {
|
|
18
|
-
strokeWidth: number;
|
|
19
|
-
markerStart: boolean;
|
|
20
|
-
markerEnd: boolean;
|
|
21
|
-
}) => void;
|
|
22
|
-
transformNode: (node: Model.FlowNode, handlers?: any) => Node;
|
|
23
|
-
refreshFlow: () => Promise<void>;
|
|
24
|
-
updateNode: (updatedNode: Model.FlowNode) => Promise<void>;
|
|
25
|
-
updateNodePosition: (nodeId: string, x: number, y: number) => Promise<void>;
|
|
26
|
-
updateNodeDimensions: (nodeId: string, dimensions: {
|
|
27
|
-
width: number;
|
|
28
|
-
height: number;
|
|
29
|
-
positionX: number;
|
|
30
|
-
positionY: number;
|
|
31
|
-
}) => Promise<void>;
|
|
32
|
-
createNode: () => Promise<void>;
|
|
33
|
-
deleteNode: (nodeId: string) => Promise<void>;
|
|
34
|
-
deleteEdge: (edgeId: string) => Promise<void>;
|
|
35
|
-
createEdge: (params: {
|
|
36
|
-
source: string;
|
|
37
|
-
target: string;
|
|
38
|
-
sourceHandle?: string | null;
|
|
39
|
-
targetHandle?: string | null;
|
|
40
|
-
}) => Promise<void>;
|
|
41
|
-
}
|
|
42
|
-
/**
|
|
43
|
-
* Flow 业务逻辑 Composable
|
|
44
|
-
* 处理节点和边的 CRUD 操作、数据转换等
|
|
45
|
-
*/
|
|
46
|
-
export declare function useFlow(options: UseFlowOptions): UseFlowReturn;
|