lew-ui 2.7.33 → 2.7.36

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/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- MIT License
2
-
3
- Copyright (c) 2023 lew
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ MIT License
2
+
3
+ Copyright (c) 2023 lew
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -1,5 +1,5 @@
1
1
  import { defineComponent, computed, shallowRef, onMounted, nextTick, onBeforeUnmount, createBlock, openBlock, unref, withCtx, createElementBlock, Fragment, renderList, normalizeClass, createElementVNode, normalizeStyle, createCommentVNode, createVNode, createApp, h, defineAsyncComponent } from "vue";
2
- import { c as contextMenuProps, g as getUniqueId, L as LewFlex, C as CommonIcon, _ as _sfc_main$1, a as LewEmpty, i as isFunction, b as initLewContextMenu, t as tippy, d as _export_sfc } from "./index-0Dikjcyf.js";
2
+ import { c as contextMenuProps, g as getUniqueId, L as LewFlex, C as CommonIcon, _ as _sfc_main$1, a as LewEmpty, i as isFunction, b as initLewContextMenu, t as tippy, d as _export_sfc } from "./index-CarELR6D.js";
3
3
  const contextMenuEmits = {
4
4
  change: (item) => item
5
5
  };
@@ -1,7 +1,7 @@
1
1
  import { LewFormItemAs } from '../../../../types';
2
- declare function setIgnoreValidate(value: boolean): void;
2
+ declare function setIgnoreValidate(val: boolean): void;
3
3
  declare function validate(): void;
4
- declare function setError(message: any): void;
4
+ declare function setError(msg: any): void;
5
5
  declare const _default: import('vue').DefineComponent<globalThis.ExtractPropTypes<{
6
6
  label: {
7
7
  type: StringConstructor;
@@ -13,6 +13,11 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
13
13
  default: string;
14
14
  validator: (value: any) => boolean;
15
15
  };
16
+ visible: {
17
+ type: PropType<boolean | ((formData: Record<string, any>) => boolean)>;
18
+ default: boolean;
19
+ validator: (value: any) => boolean;
20
+ };
16
21
  required: {
17
22
  type: BooleanConstructor;
18
23
  default: boolean;
@@ -47,12 +52,12 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
47
52
  validator: (value: any) => boolean;
48
53
  };
49
54
  disabled: {
50
- type: BooleanConstructor;
55
+ type: PropType<boolean | ((formData: Record<string, any>) => boolean)>;
51
56
  default: boolean;
52
57
  validator: (value: any) => boolean;
53
58
  };
54
59
  readonly: {
55
- type: BooleanConstructor;
60
+ type: PropType<boolean | ((formData: Record<string, any>) => boolean)>;
56
61
  default: boolean;
57
62
  validator: (value: any) => boolean;
58
63
  };
@@ -66,12 +71,8 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
66
71
  default: string;
67
72
  validator: (value: any) => boolean;
68
73
  };
69
- rule: {
70
- type: PropType<any | string>;
71
- validator: (value: unknown) => boolean;
72
- };
73
74
  props: {
74
- type: PropType<Record<string, any>>;
75
+ type: PropType<Record<string, any> | ((formData: Record<string, any>) => Record<string, any>)>;
75
76
  default: () => {};
76
77
  validator: (value: unknown) => boolean;
77
78
  };
@@ -109,13 +110,17 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
109
110
  }) => unknown;
110
111
  validator: (value: any) => boolean;
111
112
  };
113
+ dependencies: {
114
+ type: PropType<string[]>;
115
+ default: () => never[];
116
+ validator: (value: any[] | undefined) => boolean;
117
+ };
112
118
  modelValue: {
113
119
  type: globalThis.PropType<never>;
114
120
  };
115
121
  }>, {
116
122
  validate: typeof validate;
117
123
  setError: typeof setError;
118
- curRule: globalThis.ComputedRef<any>;
119
124
  setIgnoreValidate: typeof setIgnoreValidate;
120
125
  }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
121
126
  change: (value: any) => void;
@@ -131,6 +136,11 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
131
136
  default: string;
132
137
  validator: (value: any) => boolean;
133
138
  };
139
+ visible: {
140
+ type: PropType<boolean | ((formData: Record<string, any>) => boolean)>;
141
+ default: boolean;
142
+ validator: (value: any) => boolean;
143
+ };
134
144
  required: {
135
145
  type: BooleanConstructor;
136
146
  default: boolean;
@@ -165,12 +175,12 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
165
175
  validator: (value: any) => boolean;
166
176
  };
167
177
  disabled: {
168
- type: BooleanConstructor;
178
+ type: PropType<boolean | ((formData: Record<string, any>) => boolean)>;
169
179
  default: boolean;
170
180
  validator: (value: any) => boolean;
171
181
  };
172
182
  readonly: {
173
- type: BooleanConstructor;
183
+ type: PropType<boolean | ((formData: Record<string, any>) => boolean)>;
174
184
  default: boolean;
175
185
  validator: (value: any) => boolean;
176
186
  };
@@ -184,12 +194,8 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
184
194
  default: string;
185
195
  validator: (value: any) => boolean;
186
196
  };
187
- rule: {
188
- type: PropType<any | string>;
189
- validator: (value: unknown) => boolean;
190
- };
191
197
  props: {
192
- type: PropType<Record<string, any>>;
198
+ type: PropType<Record<string, any> | ((formData: Record<string, any>) => Record<string, any>)>;
193
199
  default: () => {};
194
200
  validator: (value: unknown) => boolean;
195
201
  };
@@ -227,6 +233,11 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
227
233
  }) => unknown;
228
234
  validator: (value: any) => boolean;
229
235
  };
236
+ dependencies: {
237
+ type: PropType<string[]>;
238
+ default: () => never[];
239
+ validator: (value: any[] | undefined) => boolean;
240
+ };
230
241
  modelValue: {
231
242
  type: globalThis.PropType<never>;
232
243
  };
@@ -235,9 +246,9 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
235
246
  "onUpdate:modelValue"?: ((value: undefined) => any) | undefined;
236
247
  }>, {
237
248
  size: import('../../../..').LewSize;
238
- disabled: boolean;
249
+ disabled: boolean | ((formData: Record<string, any>) => boolean);
239
250
  label: string;
240
- props: Record<string, any>;
251
+ props: Record<string, any> | ((formData: Record<string, any>) => Record<string, any>);
241
252
  direction: import('../../../..').LewDirection;
242
253
  tips: string;
243
254
  width: import("csstype").Property.Width<0 | (string & {})>;
@@ -245,9 +256,10 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
245
256
  required: boolean;
246
257
  between: boolean;
247
258
  labelWidth: import("csstype").Property.Width<0 | (string & {})>;
248
- readonly: boolean;
259
+ readonly: boolean | ((formData: Record<string, any>) => boolean);
249
260
  id: string;
250
261
  field: string;
262
+ visible: boolean | ((formData: Record<string, any>) => boolean);
251
263
  as: "" | LewFormItemAs;
252
264
  errMessage: string;
253
265
  outputFormat: (params: {
@@ -256,7 +268,8 @@ declare const _default: import('vue').DefineComponent<globalThis.ExtractPropType
256
268
  inputFormat: (params: {
257
269
  value: unknown;
258
270
  }) => unknown;
271
+ dependencies: string[];
259
272
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {
260
273
  formItemRef: HTMLDivElement;
261
- }, HTMLDivElement>;
274
+ }, any>;
262
275
  export default _default;
@@ -69,6 +69,11 @@ export declare const formItemProps: {
69
69
  default: string;
70
70
  validator: (value: any) => boolean;
71
71
  };
72
+ visible: {
73
+ type: PropType<boolean | ((formData: Record<string, any>) => boolean)>;
74
+ default: boolean;
75
+ validator: (value: any) => boolean;
76
+ };
72
77
  required: {
73
78
  type: BooleanConstructor;
74
79
  default: boolean;
@@ -103,12 +108,12 @@ export declare const formItemProps: {
103
108
  validator: (value: any) => boolean;
104
109
  };
105
110
  disabled: {
106
- type: BooleanConstructor;
111
+ type: PropType<boolean | ((formData: Record<string, any>) => boolean)>;
107
112
  default: boolean;
108
113
  validator: (value: any) => boolean;
109
114
  };
110
115
  readonly: {
111
- type: BooleanConstructor;
116
+ type: PropType<boolean | ((formData: Record<string, any>) => boolean)>;
112
117
  default: boolean;
113
118
  validator: (value: any) => boolean;
114
119
  };
@@ -122,12 +127,8 @@ export declare const formItemProps: {
122
127
  default: string;
123
128
  validator: (value: any) => boolean;
124
129
  };
125
- rule: {
126
- type: PropType<any | string>;
127
- validator: (value: unknown) => boolean;
128
- };
129
130
  props: {
130
- type: PropType<Record<string, any>>;
131
+ type: PropType<Record<string, any> | ((formData: Record<string, any>) => Record<string, any>)>;
131
132
  default: () => {};
132
133
  validator: (value: unknown) => boolean;
133
134
  };
@@ -165,6 +166,11 @@ export declare const formItemProps: {
165
166
  }) => unknown;
166
167
  validator: (value: any) => boolean;
167
168
  };
169
+ dependencies: {
170
+ type: PropType<string[]>;
171
+ default: () => never[];
172
+ validator: (value: any[] | undefined) => boolean;
173
+ };
168
174
  };
169
175
  export declare const requiredIconSizeMap: Record<LewSize, number>;
170
176
  export declare const tipsIconSizeMap: Record<LewSize, number>;