tiddy 2.0.3 → 2.0.4

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/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import * as vue14 from "vue";
1
+ import * as vue41 from "vue";
2
2
  import { AllowedComponentProps, CSSProperties, Component, ComputedRef, DefineComponent, ExtractPublicPropTypes, PropType, Raw, Slot } from "vue";
3
3
  import * as element_plus0 from "element-plus";
4
4
  import { DialogInstance, DialogProps, FormInstance, FormItemProps, FormItemRule, FormProps, TableColumnInstance, TableInstance } from "element-plus";
@@ -249,7 +249,7 @@ declare function widget<T>(c: T, props?: PropsOf<T>): {
249
249
  declare function reValidateErrorFields(): void;
250
250
  declare const expose$1: {
251
251
  reValidateErrorFields: typeof reValidateErrorFields;
252
- model: vue14.ComputedRef<unknown>;
252
+ model: vue41.ComputedRef<unknown>;
253
253
  };
254
254
  type __TdFormExpose = typeof expose$1 & FormInstance;
255
255
  declare var __VLS_11$1: {}, __VLS_13$1: {}, __VLS_19$1: {};
@@ -260,24 +260,24 @@ type __VLS_Slots$3 = {} & {
260
260
  } & {
261
261
  suffix?: (props: typeof __VLS_19$1) => any;
262
262
  };
263
- declare const __VLS_base$3: vue14.DefineComponent<vue14.ExtractPropTypes<{
263
+ declare const __VLS_base$3: vue41.DefineComponent<vue41.ExtractPropTypes<{
264
264
  fields: {
265
- type: vue14.PropType<TdFormFieldProps[]>;
265
+ type: vue41.PropType<TdFormFieldProps[]>;
266
266
  default: () => never[];
267
267
  };
268
268
  item: {
269
- type: vue14.PropType<element_plus0.FormItemProps>;
269
+ type: vue41.PropType<element_plus0.FormItemProps>;
270
270
  default: () => {};
271
271
  };
272
- }>, __TdFormExpose, {}, {}, {}, vue14.ComponentOptionsMixin, vue14.ComponentOptionsMixin, {
272
+ }>, __TdFormExpose, {}, {}, {}, vue41.ComponentOptionsMixin, vue41.ComponentOptionsMixin, {
273
273
  submit: (data: any) => any;
274
- }, string, vue14.PublicProps, Readonly<vue14.ExtractPropTypes<{
274
+ }, string, vue41.PublicProps, Readonly<vue41.ExtractPropTypes<{
275
275
  fields: {
276
- type: vue14.PropType<TdFormFieldProps[]>;
276
+ type: vue41.PropType<TdFormFieldProps[]>;
277
277
  default: () => never[];
278
278
  };
279
279
  item: {
280
- type: vue14.PropType<element_plus0.FormItemProps>;
280
+ type: vue41.PropType<element_plus0.FormItemProps>;
281
281
  default: () => {};
282
282
  };
283
283
  }>> & Readonly<{
@@ -285,7 +285,7 @@ declare const __VLS_base$3: vue14.DefineComponent<vue14.ExtractPropTypes<{
285
285
  }>, {
286
286
  fields: TdFormFieldProps[];
287
287
  item: element_plus0.FormItemProps;
288
- }, {}, {}, {}, string, vue14.ComponentProvideOptions, true, {}, any>;
288
+ }, {}, {}, {}, string, vue41.ComponentProvideOptions, true, {}, any>;
289
289
  declare const __VLS_export$5: __VLS_WithSlots$3<typeof __VLS_base$3, __VLS_Slots$3>;
290
290
  declare const _default$1: typeof __VLS_export$5;
291
291
  type __VLS_WithSlots$3<T, S> = T & {
@@ -297,37 +297,37 @@ type __VLS_WithSlots$3<T, S> = T & {
297
297
  //#region src/form/form-item.vue.d.ts
298
298
  declare var __VLS_10: string | number, __VLS_11: any;
299
299
  type __VLS_Slots$2 = {} & { [K in NonNullable<typeof __VLS_10>]?: (props: typeof __VLS_11) => any };
300
- declare const __VLS_base$2: vue14.DefineComponent<vue14.ExtractPropTypes<{
300
+ declare const __VLS_base$2: vue41.DefineComponent<vue41.ExtractPropTypes<{
301
301
  messageLabel: {
302
- type: vue14.PropType<string | vue14.ComputedRef<string>>;
302
+ type: vue41.PropType<string | vue41.ComputedRef<string>>;
303
303
  default: string;
304
304
  };
305
305
  formatMessage: {
306
- type: vue14.PropType<AnyFunction>;
306
+ type: vue41.PropType<AnyFunction>;
307
307
  default: null;
308
308
  };
309
309
  hideRequiredAsterisk: {
310
- type: vue14.PropType<boolean>;
310
+ type: vue41.PropType<boolean>;
311
311
  default: boolean;
312
312
  };
313
- }>, {}, {}, {}, {}, vue14.ComponentOptionsMixin, vue14.ComponentOptionsMixin, {}, string, vue14.PublicProps, Readonly<vue14.ExtractPropTypes<{
313
+ }>, {}, {}, {}, {}, vue41.ComponentOptionsMixin, vue41.ComponentOptionsMixin, {}, string, vue41.PublicProps, Readonly<vue41.ExtractPropTypes<{
314
314
  messageLabel: {
315
- type: vue14.PropType<string | vue14.ComputedRef<string>>;
315
+ type: vue41.PropType<string | vue41.ComputedRef<string>>;
316
316
  default: string;
317
317
  };
318
318
  formatMessage: {
319
- type: vue14.PropType<AnyFunction>;
319
+ type: vue41.PropType<AnyFunction>;
320
320
  default: null;
321
321
  };
322
322
  hideRequiredAsterisk: {
323
- type: vue14.PropType<boolean>;
323
+ type: vue41.PropType<boolean>;
324
324
  default: boolean;
325
325
  };
326
326
  }>> & Readonly<{}>, {
327
- messageLabel: string | vue14.ComputedRef<string>;
327
+ messageLabel: string | vue41.ComputedRef<string>;
328
328
  formatMessage: AnyFunction;
329
329
  hideRequiredAsterisk: boolean;
330
- }, {}, {}, {}, string, vue14.ComponentProvideOptions, true, {}, any>;
330
+ }, {}, {}, {}, string, vue41.ComponentProvideOptions, true, {}, any>;
331
331
  declare const __VLS_export$4: __VLS_WithSlots$2<typeof __VLS_base$2, __VLS_Slots$2>;
332
332
  declare const _default$3: typeof __VLS_export$4;
333
333
  type __VLS_WithSlots$2<T, S> = T & {
@@ -337,7 +337,7 @@ type __VLS_WithSlots$2<T, S> = T & {
337
337
  };
338
338
  //#endregion
339
339
  //#region src/form/form-field.vue.d.ts
340
- declare const __VLS_export$3: vue14.DefineComponent<{}, {}, {}, {}, {}, vue14.ComponentOptionsMixin, vue14.ComponentOptionsMixin, {}, string, vue14.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue14.ComponentProvideOptions, true, {}, any>;
340
+ declare const __VLS_export$3: vue41.DefineComponent<{}, {}, {}, {}, {}, vue41.ComponentOptionsMixin, vue41.ComponentOptionsMixin, {}, string, vue41.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue41.ComponentProvideOptions, true, {}, any>;
341
341
  declare const _default$2: typeof __VLS_export$3;
342
342
  //#endregion
343
343
  //#region src/form/index.d.ts
@@ -377,19 +377,19 @@ type __VLS_Slots$1 = {} & { [K in NonNullable<typeof __VLS_16>]?: (props: typeof
377
377
  } & {
378
378
  after?: (props: typeof __VLS_19) => any;
379
379
  };
380
- declare const __VLS_base$1: vue14.DefineComponent<vue14.ExtractPropTypes<{
380
+ declare const __VLS_base$1: vue41.DefineComponent<vue41.ExtractPropTypes<{
381
381
  columns: {
382
- type: vue14.PropType<TdTableColumnProps[]>;
382
+ type: vue41.PropType<TdTableColumnProps[]>;
383
383
  default: () => never[];
384
384
  };
385
- }>, TableInstance, {}, {}, {}, vue14.ComponentOptionsMixin, vue14.ComponentOptionsMixin, {}, string, vue14.PublicProps, Readonly<vue14.ExtractPropTypes<{
385
+ }>, TableInstance, {}, {}, {}, vue41.ComponentOptionsMixin, vue41.ComponentOptionsMixin, {}, string, vue41.PublicProps, Readonly<vue41.ExtractPropTypes<{
386
386
  columns: {
387
- type: vue14.PropType<TdTableColumnProps[]>;
387
+ type: vue41.PropType<TdTableColumnProps[]>;
388
388
  default: () => never[];
389
389
  };
390
390
  }>> & Readonly<{}>, {
391
391
  columns: TdTableColumnProps[];
392
- }, {}, {}, {}, string, vue14.ComponentProvideOptions, true, {}, any>;
392
+ }, {}, {}, {}, string, vue41.ComponentProvideOptions, true, {}, any>;
393
393
  declare const __VLS_export$2: __VLS_WithSlots$1<typeof __VLS_base$1, __VLS_Slots$1>;
394
394
  declare const _default$4: typeof __VLS_export$2;
395
395
  type __VLS_WithSlots$1<T, S> = T & {
@@ -399,37 +399,37 @@ type __VLS_WithSlots$1<T, S> = T & {
399
399
  };
400
400
  //#endregion
401
401
  //#region src/table/table-col.vue.d.ts
402
- declare const __VLS_export$1: vue14.DefineComponent<vue14.ExtractPropTypes<{
402
+ declare const __VLS_export$1: vue41.DefineComponent<vue41.ExtractPropTypes<{
403
403
  slots: {
404
- type: vue14.PropType<OrArray<SlotDef>>;
404
+ type: vue41.PropType<OrArray<SlotDef>>;
405
405
  default: () => null;
406
406
  };
407
407
  columns: {
408
- type: vue14.PropType<any[]>;
408
+ type: vue41.PropType<any[]>;
409
409
  default: () => never[];
410
410
  };
411
411
  transform: {
412
- type: vue14.PropType<AnyFunction[]>;
412
+ type: vue41.PropType<AnyFunction[]>;
413
413
  default: () => never[];
414
414
  };
415
- }>, {}, {}, {}, {}, vue14.ComponentOptionsMixin, vue14.ComponentOptionsMixin, {}, string, vue14.PublicProps, Readonly<vue14.ExtractPropTypes<{
415
+ }>, {}, {}, {}, {}, vue41.ComponentOptionsMixin, vue41.ComponentOptionsMixin, {}, string, vue41.PublicProps, Readonly<vue41.ExtractPropTypes<{
416
416
  slots: {
417
- type: vue14.PropType<OrArray<SlotDef>>;
417
+ type: vue41.PropType<OrArray<SlotDef>>;
418
418
  default: () => null;
419
419
  };
420
420
  columns: {
421
- type: vue14.PropType<any[]>;
421
+ type: vue41.PropType<any[]>;
422
422
  default: () => never[];
423
423
  };
424
424
  transform: {
425
- type: vue14.PropType<AnyFunction[]>;
425
+ type: vue41.PropType<AnyFunction[]>;
426
426
  default: () => never[];
427
427
  };
428
428
  }>> & Readonly<{}>, {
429
429
  slots: OrArray<SlotDef>;
430
430
  columns: any[];
431
431
  transform: AnyFunction[];
432
- }, {}, {}, {}, string, vue14.ComponentProvideOptions, true, {}, any>;
432
+ }, {}, {}, {}, string, vue41.ComponentProvideOptions, true, {}, any>;
433
433
  declare const _default$5: typeof __VLS_export$1;
434
434
  //#endregion
435
435
  //#region src/table/index.d.ts
@@ -462,7 +462,7 @@ declare var __VLS_13: "default" | "title" | "header" | "footer", __VLS_14: {
462
462
  titleClass?: string | undefined;
463
463
  };
464
464
  type __VLS_Slots = {} & { [K in NonNullable<typeof __VLS_13>]?: (props: typeof __VLS_14) => any };
465
- declare const __VLS_base: vue14.DefineComponent<{}, __TdDialogExpose, {}, {}, {}, vue14.ComponentOptionsMixin, vue14.ComponentOptionsMixin, {}, string, vue14.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue14.ComponentProvideOptions, true, {}, any>;
465
+ declare const __VLS_base: vue41.DefineComponent<{}, __TdDialogExpose, {}, {}, {}, vue41.ComponentOptionsMixin, vue41.ComponentOptionsMixin, {}, string, vue41.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue41.ComponentProvideOptions, true, {}, any>;
466
466
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
467
467
  declare const _default: typeof __VLS_export;
468
468
  type __VLS_WithSlots<T, S> = T & {
@@ -476,10 +476,10 @@ type Instance = InstanceType<typeof _default>;
476
476
  type TdDialogInstance = Instance & Omit<DialogInstance, keyof Instance & string>;
477
477
  //#endregion
478
478
  //#region src/hooks/use-reuse.d.ts
479
- declare function useReuse(): (vue14.DefineComponent<{}, () => null, {}, {}, {}, vue14.ComponentOptionsMixin, vue14.ComponentOptionsMixin, {}, string, vue14.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue14.ComponentProvideOptions, true, {}, any> | vue14.DefineComponent<{}, () => vue14.VNode<vue14.RendererNode, vue14.RendererElement, {
479
+ declare function useReuse(): (vue41.DefineComponent<{}, () => null, {}, {}, {}, vue41.ComponentOptionsMixin, vue41.ComponentOptionsMixin, {}, string, vue41.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue41.ComponentProvideOptions, true, {}, any> | vue41.DefineComponent<{}, () => vue41.VNode<vue41.RendererNode, vue41.RendererElement, {
480
480
  [key: string]: any;
481
- }>[] | undefined, {}, {}, {}, vue14.ComponentOptionsMixin, vue14.ComponentOptionsMixin, {}, string, vue14.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue14.ComponentProvideOptions, true, {}, any> | vue14.ComputedRef<Readonly<{
482
- [name: string]: vue14.Slot<any> | undefined;
481
+ }>[] | undefined, {}, {}, {}, vue41.ComponentOptionsMixin, vue41.ComponentOptionsMixin, {}, string, vue41.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue41.ComponentProvideOptions, true, {}, any> | vue41.ComputedRef<Readonly<{
482
+ [name: string]: vue41.Slot<any> | undefined;
483
483
  }>>)[];
484
484
  //#endregion
485
485
  //#region src/utils/index.d.ts
package/dist/index.js CHANGED
@@ -118,19 +118,35 @@ const widgetFieldPropsDef = {
118
118
  default: () => []
119
119
  },
120
120
  slots: {
121
- type: [Array, Object],
121
+ type: [
122
+ Array,
123
+ Object,
124
+ String
125
+ ],
122
126
  default: () => null
123
127
  },
124
128
  prependSlots: {
125
- type: [Array, Object],
129
+ type: [
130
+ Array,
131
+ Object,
132
+ String
133
+ ],
126
134
  default: () => null
127
135
  },
128
136
  appendSlots: {
129
- type: [Array, Object],
137
+ type: [
138
+ Array,
139
+ Object,
140
+ String
141
+ ],
130
142
  default: () => null
131
143
  },
132
144
  itemSlots: {
133
- type: [Array, Object],
145
+ type: [
146
+ Array,
147
+ Object,
148
+ String
149
+ ],
134
150
  default: () => null
135
151
  },
136
152
  default: {
@@ -182,7 +198,11 @@ const layoutFieldPropsDef = {
182
198
  required: true
183
199
  },
184
200
  slots: {
185
- type: [Array, Object],
201
+ type: [
202
+ Array,
203
+ Object,
204
+ String
205
+ ],
186
206
  default: () => []
187
207
  },
188
208
  ...fieldsPropsDef,
@@ -757,7 +777,11 @@ var form_default = form_vue_vue_type_script_setup_true_lang_default;
757
777
  const tableCtxKey = Symbol("tableCtxKey");
758
778
  const tableColumnPropsDef = {
759
779
  slots: {
760
- type: [Array, Object],
780
+ type: [
781
+ Array,
782
+ Object,
783
+ String
784
+ ],
761
785
  default: () => null
762
786
  },
763
787
  columns: {
@@ -826,7 +850,7 @@ var table_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineCo
826
850
  props: tablePropsDef,
827
851
  setup(__props, { expose: __expose }) {
828
852
  const slots = useSlots();
829
- const tableRef = useTemplateRef("tableRef");
853
+ const tableRef = ref(null);
830
854
  const slotNames = computed(() => Object.keys(slots));
831
855
  provide(tableCtxKey, { getParentSlots: getSlotsFactory(slots) });
832
856
  __expose(new Proxy({}, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tiddy",
3
- "version": "2.0.3",
3
+ "version": "2.0.4",
4
4
  "packageManager": "pnpm@10.11.0",
5
5
  "description": "A set of Vue 3 components based on element-plus",
6
6
  "type": "module",