@wyfex/ivue 0.21.0 → 0.22.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.
Files changed (34) hide show
  1. package/README.md +1 -1
  2. package/dist/index.es.js +1 -1
  3. package/dist/index.umd.cjs +10 -10
  4. package/dist/ivue.css +1 -1
  5. package/dist/types/UseCrud/hook.d.ts +2 -3
  6. package/dist/types/UseElDescriptions/hook.d.ts +2 -6
  7. package/dist/types/UseElDescriptions/types.d.ts +2 -2
  8. package/dist/types/UseElForm/components/QueryForm.vue.d.ts +2 -6
  9. package/dist/types/UseElForm/components/RowForm.vue.d.ts +2 -6
  10. package/dist/types/UseElForm/hooks/useElForm.d.ts +2 -6
  11. package/dist/types/UseElForm/index.vue.d.ts +20 -16
  12. package/dist/types/UseElForm/types.d.ts +6 -0
  13. package/dist/types/UseElInput/types.d.ts +2 -2
  14. package/dist/types/UseElSelect/types.d.ts +2 -2
  15. package/dist/types/UseElTable/hooks/useElTable.d.ts +2 -3
  16. package/dist/types/UseElTable/hooks/useSelection.d.ts +1 -0
  17. package/dist/types/UseElTable/index.vue.d.ts +1 -0
  18. package/dist/types/UseElUpload/types.d.ts +2 -2
  19. package/dist/types/UseProtocolInput/index.vue.d.ts +19 -0
  20. package/dist/types/index.d.ts +1 -0
  21. package/package.json +5 -5
  22. package/src/components/UseElDescriptions/props.ts +1 -1
  23. package/src/components/UseElDescriptions/types.ts +2 -2
  24. package/src/components/UseElDialog/props.ts +1 -1
  25. package/src/components/UseElDrawer/props.ts +1 -1
  26. package/src/components/UseElForm/props.ts +1 -1
  27. package/src/components/UseElForm/types.ts +48 -114
  28. package/src/components/UseElInput/types.ts +3 -5
  29. package/src/components/UseElSelect/types.ts +4 -8
  30. package/src/components/UseElTable/props.ts +1 -1
  31. package/src/components/UseElUpload/types.ts +2 -2
  32. package/src/components/UseLineTitle/defaultExtConfig.ts +3 -15
  33. package/src/components/UseLineTitle/types.ts +2 -0
  34. package/src/types/index.ts +38 -115
@@ -1,11 +1,10 @@
1
1
  import { ComputedRef, Slots } from 'vue';
2
- import { Emits, Props, UseCrudReturn } from './types';
2
+ import { Props, UseCrudReturn } from './types';
3
3
  import { GlobalConfig } from '../../types';
4
- export declare const useCrud: ({ mergedProps, globalConfig, slots, uefRef, modalRef, emits }: {
4
+ export declare const useCrud: ({ mergedProps, globalConfig, slots, uefRef, modalRef }: {
5
5
  mergedProps: ComputedRef<Props>;
6
6
  globalConfig: ComputedRef<GlobalConfig>;
7
7
  slots: Slots;
8
8
  uefRef: any;
9
9
  modalRef: any;
10
- emits: Emits;
11
10
  }) => UseCrudReturn;
@@ -1,11 +1,7 @@
1
1
  import { ComputedRef } from 'vue';
2
- import { ConfigColumn, Emits, Props } from './types';
2
+ import { ConfigColumn, Props } from './types';
3
3
  import { GlobalConfig, RenderConfig } from '../../types';
4
- export declare const useElDescriptions: ({ props, emits, globalConfig }: {
5
- props: Props;
6
- emits: Emits;
7
- globalConfig: ComputedRef<GlobalConfig>;
8
- }) => {
4
+ export declare const useElDescriptions: (props: Props, globalConfig: ComputedRef<GlobalConfig>) => {
9
5
  processRenderContent: (item: ConfigColumn) => any;
10
6
  processRenderStyle: (renderConfig: RenderConfig | boolean, item: ConfigColumn) => any;
11
7
  processPlaceholder: (item: ConfigColumn) => string;
@@ -2,9 +2,9 @@ import { Component, ExtractPropTypes } from 'vue';
2
2
  import { EditAttrs, RenderConfig, UseDict } from '../../types';
3
3
  import { default as componentProps } from './props';
4
4
  export type Props = ExtractPropTypes<typeof componentProps>;
5
- export interface Emits {
5
+ export type Emits = {
6
6
  (e: 'onDictKeys', value?: string[]): void;
7
- }
7
+ };
8
8
  export interface ComponentConfig {
9
9
  is: Component;
10
10
  attrs?: EditAttrs;
@@ -56,9 +56,7 @@ declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPro
56
56
  }>, {
57
57
  showQueryForm: import('vue').Ref<boolean, boolean>;
58
58
  handleDisplayQueryForm: () => void;
59
- }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
60
- onDictKeys: (value?: string[] | undefined) => any;
61
- }, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
59
+ }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
62
60
  formColumns: {
63
61
  type: import('vue').PropType<import('../types').FormColumn[]>;
64
62
  required: boolean;
@@ -113,9 +111,7 @@ declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPro
113
111
  type: import('vue').PropType<import('../types').QueryConfig>;
114
112
  default: () => {};
115
113
  };
116
- }>> & Readonly<{
117
- onOnDictKeys?: ((value?: string[] | undefined) => any) | undefined;
118
- }>, {
114
+ }>> & Readonly<{}>, {
119
115
  useRender: boolean | import('../../../types').RenderConfig;
120
116
  dictMap: import('../../../types').DictMap;
121
117
  dictProps: import('../../../types').DictProps;
@@ -55,9 +55,7 @@ declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPro
55
55
  };
56
56
  }>, {
57
57
  efRef: import('vue').Ref<null, null>;
58
- }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
59
- onDictKeys: (value?: string[] | undefined) => any;
60
- }, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
58
+ }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
61
59
  formColumns: {
62
60
  type: import('vue').PropType<import('../types').FormColumn[]>;
63
61
  required: boolean;
@@ -112,9 +110,7 @@ declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPro
112
110
  type: import('vue').PropType<import('../types').QueryConfig>;
113
111
  default: () => {};
114
112
  };
115
- }>> & Readonly<{
116
- onOnDictKeys?: ((value?: string[] | undefined) => any) | undefined;
117
- }>, {
113
+ }>> & Readonly<{}>, {
118
114
  useRender: boolean | import('../../../types').RenderConfig;
119
115
  dictMap: import('../../../types').DictMap;
120
116
  dictProps: import('../../../types').DictProps;
@@ -1,11 +1,7 @@
1
1
  import { ComputedRef } from 'vue';
2
- import { Emits, FormColumn, Props } from '../types';
2
+ import { FormColumn, Props } from '../types';
3
3
  import { GlobalConfig } from '../../../types';
4
- export declare const useElForm: ({ props, emits, globalConfig }: {
5
- props: Props;
6
- emits: Emits;
7
- globalConfig: ComputedRef<GlobalConfig>;
8
- }) => {
4
+ export declare const useElForm: (props: Props, globalConfig: ComputedRef<GlobalConfig>) => {
9
5
  formColumnsComputed: ComputedRef<FormColumn[]>;
10
6
  formRules: ComputedRef<Record<string, any>>;
11
7
  resolveQueryParams: (formColumns: FormColumn[], formModel: Record<string, any>) => Record<string, any>;
@@ -1,6 +1,6 @@
1
1
  declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
2
2
  formColumns: {
3
- type: import('vue').PropType<import('./types').FormColumn[]>;
3
+ type: import('vue').PropType<import('./types.ts').FormColumn[]>;
4
4
  required: boolean;
5
5
  };
6
6
  formModel: {
@@ -8,15 +8,15 @@ declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPro
8
8
  required: boolean;
9
9
  };
10
10
  useRender: {
11
- type: import('vue').PropType<boolean | import('../../types').RenderConfig>;
11
+ type: import('vue').PropType<boolean | import('../../types/index.ts').RenderConfig>;
12
12
  default: boolean;
13
13
  };
14
14
  dictMap: {
15
- type: import('vue').PropType<import('../../types').DictMap>;
15
+ type: import('vue').PropType<import('../../types/index.ts').DictMap>;
16
16
  default: () => {};
17
17
  };
18
18
  dictProps: {
19
- type: import('vue').PropType<import('../../types').DictProps>;
19
+ type: import('vue').PropType<import('../../types/index.ts').DictProps>;
20
20
  default: () => {};
21
21
  };
22
22
  formItemWidth: {
@@ -50,7 +50,7 @@ declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPro
50
50
  default: boolean;
51
51
  };
52
52
  queryConfig: {
53
- type: import('vue').PropType<import('./types').QueryConfig>;
53
+ type: import('vue').PropType<import('./types.ts').QueryConfig>;
54
54
  default: () => {};
55
55
  };
56
56
  }>, {
@@ -61,9 +61,11 @@ declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPro
61
61
  handleDisplayQueryForm: import('vue').ComputedRef<Function | undefined>;
62
62
  processApiData: (apiData: Record<string, any>) => Record<string, any>;
63
63
  getProcessedFormModel: () => Record<string, any>;
64
- }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
64
+ }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
65
+ onDictKeys: (value?: string[] | undefined) => any;
66
+ }, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
65
67
  formColumns: {
66
- type: import('vue').PropType<import('./types').FormColumn[]>;
68
+ type: import('vue').PropType<import('./types.ts').FormColumn[]>;
67
69
  required: boolean;
68
70
  };
69
71
  formModel: {
@@ -71,15 +73,15 @@ declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPro
71
73
  required: boolean;
72
74
  };
73
75
  useRender: {
74
- type: import('vue').PropType<boolean | import('../../types').RenderConfig>;
76
+ type: import('vue').PropType<boolean | import('../../types/index.ts').RenderConfig>;
75
77
  default: boolean;
76
78
  };
77
79
  dictMap: {
78
- type: import('vue').PropType<import('../../types').DictMap>;
80
+ type: import('vue').PropType<import('../../types/index.ts').DictMap>;
79
81
  default: () => {};
80
82
  };
81
83
  dictProps: {
82
- type: import('vue').PropType<import('../../types').DictProps>;
84
+ type: import('vue').PropType<import('../../types/index.ts').DictProps>;
83
85
  default: () => {};
84
86
  };
85
87
  formItemWidth: {
@@ -113,13 +115,15 @@ declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPro
113
115
  default: boolean;
114
116
  };
115
117
  queryConfig: {
116
- type: import('vue').PropType<import('./types').QueryConfig>;
118
+ type: import('vue').PropType<import('./types.ts').QueryConfig>;
117
119
  default: () => {};
118
120
  };
119
- }>> & Readonly<{}>, {
120
- useRender: boolean | import('../../types').RenderConfig;
121
- dictMap: import('../../types').DictMap;
122
- dictProps: import('../../types').DictProps;
121
+ }>> & Readonly<{
122
+ onOnDictKeys?: ((value?: string[] | undefined) => any) | undefined;
123
+ }>, {
124
+ useRender: boolean | import('../../types/index.ts').RenderConfig;
125
+ dictMap: import('../../types/index.ts').DictMap;
126
+ dictProps: import('../../types/index.ts').DictProps;
123
127
  formItemWidth: string;
124
128
  labelSuffix: string;
125
129
  labelWidth: string;
@@ -127,7 +131,7 @@ declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPro
127
131
  rowGutter: number;
128
132
  colSpan: number;
129
133
  disabled: boolean;
130
- queryConfig: import('./types').QueryConfig;
134
+ queryConfig: import('./types.ts').QueryConfig;
131
135
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
132
136
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
133
137
  declare const _default: typeof __VLS_export;
@@ -1,4 +1,5 @@
1
1
  import { ExtractPropTypes } from 'vue';
2
+ import { FormInstance } from 'element-plus';
2
3
  import { default as componentProps } from './props';
3
4
  import { RenderConfig, UseDict } from '../../types';
4
5
  export type Props = ExtractPropTypes<typeof componentProps>;
@@ -191,3 +192,8 @@ export interface FormColumn {
191
192
  switchConfig?: SwitchConfig;
192
193
  inputRangeConfig?: InputRangeConfig;
193
194
  }
195
+ export interface FormComponentInstance {
196
+ efRef: FormInstance;
197
+ showQueryForm: boolean;
198
+ handleDisplayQueryForm: Function;
199
+ }
@@ -1,6 +1,6 @@
1
1
  import { ExtractPropTypes } from 'vue';
2
2
  import { default as componentProps } from './props';
3
3
  export type Props = ExtractPropTypes<typeof componentProps>;
4
- export interface Emits {
4
+ export type Emits = {
5
5
  (e: 'update:modelValue', value: string): void;
6
- }
6
+ };
@@ -1,7 +1,7 @@
1
1
  import { ExtractPropTypes } from 'vue';
2
2
  import { default as componentProps } from './props';
3
3
  export type Props = ExtractPropTypes<typeof componentProps>;
4
- export interface Emits {
4
+ export type Emits = {
5
5
  (e: 'update:modelValue', value: string | number | (string | number)[]): void;
6
6
  (e: 'update:label', label: string | string[]): void;
7
- }
7
+ };
@@ -1,9 +1,8 @@
1
1
  import { Attrs, ComputedRef } from 'vue';
2
- import { Emits, Props, TableColumn } from '../types';
2
+ import { Props, TableColumn } from '../types';
3
3
  import { GlobalConfig } from '../../../types';
4
- export declare const useElTable: ({ mergedProps, emits, attrs, globalConfig }: {
4
+ export declare const useElTable: ({ mergedProps, attrs, globalConfig }: {
5
5
  mergedProps: ComputedRef<Props>;
6
- emits: Emits;
7
6
  attrs: Attrs;
8
7
  globalConfig: ComputedRef<GlobalConfig>;
9
8
  }) => {
@@ -9,6 +9,7 @@ export declare const useSelection: ({ mergedProps, emits, attrs, etRef }: {
9
9
  }) => {
10
10
  radioComputed: import('vue').WritableComputedRef<string, string>;
11
11
  selectionContent: ComputedRef<string>;
12
+ crossPageSelectedData: ComputedRef<unknown[]>;
12
13
  handleSelectAll: (selection: any) => void;
13
14
  handleSelect: (selection: any, row: any) => void;
14
15
  handleRowClick: (row: Record<string, any>) => void;
@@ -48,6 +48,7 @@ declare const __VLS_base: import('vue').DefineComponent<import('vue').ExtractPro
48
48
  default: () => {};
49
49
  };
50
50
  }>, {
51
+ crossPageSelectedData: import('vue').ComputedRef<unknown[]>;
51
52
  validateRequired: (row: Record<string, any>) => boolean;
52
53
  }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
53
54
  onDictKeys: (value?: string[] | undefined) => any;
@@ -1,9 +1,9 @@
1
1
  import { ExtractPropTypes } from 'vue';
2
2
  import { default as componentProps } from './props';
3
3
  export type Props = ExtractPropTypes<typeof componentProps>;
4
- export interface Emits {
4
+ export type Emits = {
5
5
  'update:fileId': [value: string | number];
6
6
  'update:linkUrl': [url: string];
7
7
  onFileObj: [file: Record<string, any>];
8
8
  onError: [error: Error | string];
9
- }
9
+ };
@@ -0,0 +1,19 @@
1
+ declare const __VLS_export: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
2
+ modelValue: {
3
+ type: StringConstructor;
4
+ default: string;
5
+ };
6
+ }>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
7
+ "update:modelValue": (...args: any[]) => void;
8
+ }, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
9
+ modelValue: {
10
+ type: StringConstructor;
11
+ default: string;
12
+ };
13
+ }>> & Readonly<{
14
+ "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
15
+ }>, {
16
+ modelValue: string;
17
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
18
+ declare const _default: typeof __VLS_export;
19
+ export default _default;
@@ -17,5 +17,6 @@ export { default as UseElTooltip } from './UseElTooltip/index.vue';
17
17
  export { default as UseElUpload } from './UseElUpload/index.vue';
18
18
  export { default as UseIconfont } from './UseIconfont/index.vue';
19
19
  export { default as UseLineTitle } from './UseLineTitle/index.vue';
20
+ export { default as UseProtocolInput } from './UseProtocolInput/index.vue';
20
21
  export { default as UseRender } from './UseRender/index.vue';
21
22
  export { default as UseSvgIcon } from './UseSvgIcon/index.vue';
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@wyfex/ivue",
3
- "version": "0.21.0",
4
- "description": "万有前端 X 体系下基于 Vite8 + Vue3 + Typescript6 + ElementPlus2 构建的高性能组件库",
3
+ "version": "0.22.0",
4
+ "description": "万有前端 X 体系下基于 Vite8 + Vue3 + Typescript6 + ElementPlus2 构建的以配置驱动视图组件库",
5
5
  "homepage": "https://wyfex.top/idocs/ivue",
6
6
  "type": "module",
7
7
  "main": "dist/index.umd.cjs",
@@ -50,7 +50,7 @@
50
50
  "vue": ">=3.2.0 <4.0.0"
51
51
  },
52
52
  "devDependencies": {
53
- "@types/node": "^26.3.0",
53
+ "@types/node": "^26.4.0",
54
54
  "@vitejs/plugin-vue": "^6.0.8",
55
55
  "@vue/tsconfig": "^0.9.1",
56
56
  "@wyfex/iutils": "^0.80.0",
@@ -62,8 +62,8 @@
62
62
  "unplugin-dts": "^1.0.3",
63
63
  "unplugin-vue-components": "^32.1.0",
64
64
  "vite": "^8.2.2",
65
- "vite-svg-loader": "^5.1.1",
66
- "vue": "^3.5.41",
65
+ "vite-svg-loader": "^5.1.2",
66
+ "vue": "^3.5.42",
67
67
  "vue-tsc": "^3.3.11"
68
68
  }
69
69
  }
@@ -29,7 +29,7 @@ export default {
29
29
  default: false
30
30
  },
31
31
  /**
32
- * 字典映射 数据结构为{ configs[][label | useDict | useDict.data]: Array<{ label: string, value: any }> }
32
+ * 字典映射 数据结构为{ configs[][label | useDict | useDict.key]: Array<{ label: string, value: any }> }
33
33
  */
34
34
  dictMap: {
35
35
  type: Object as PropType<DictMap>,
@@ -8,9 +8,9 @@ import componentProps from './props'
8
8
  export type Props = ExtractPropTypes<typeof componentProps>
9
9
 
10
10
  /**
11
- * emits接口
11
+ * emits类型
12
12
  */
13
- export interface Emits {
13
+ export type Emits = {
14
14
  // dictKeys事件
15
15
  (e: 'onDictKeys', value?: string[]): void
16
16
  }
@@ -7,7 +7,7 @@ export default {
7
7
  */
8
8
  title: {
9
9
  type: String,
10
- default: '欢迎使用wyfex-ivue对话框组件'
10
+ default: ''
11
11
  },
12
12
  /**
13
13
  * el-dialog自身是否插入至body元素上。嵌套的el-dialog必须指定该属性并赋值为 true 默认是
@@ -7,7 +7,7 @@ export default {
7
7
  */
8
8
  title: {
9
9
  type: String,
10
- default: '欢迎使用wyfex-ivue抽屉组件'
10
+ default: ''
11
11
  },
12
12
  /**
13
13
  * el-drawer的窗体的大小, 当使用number类型时, 以像素为单位, 当使用string类型时, 请传入'xx%'、'xxxpx'等,否则便会以number类型解释 默认1100px
@@ -28,7 +28,7 @@ export default {
28
28
  default: false
29
29
  },
30
30
  /**
31
- * 字典映射 数据结构为{ formColumns[][label | useDict | useDict.data]: Array<{ label: string, value: any }> }
31
+ * 字典映射 数据结构为{ formColumns[][label | useDict | useDict.key]: Array<{ label: string, value: any }> }
32
32
  */
33
33
  dictMap: {
34
34
  type: Object as PropType<DictMap>,