tiddy 2.0.7 → 2.0.8

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 vue32 from "vue";
1
+ import * as vue27 from "vue";
2
2
  import { AllowedComponentProps, CSSProperties, Component, DefineComponent, ExtractPublicPropTypes, PropType, Raw, Slot } from "vue";
3
3
  import * as element_plus0 from "element-plus";
4
4
  import { DialogInstance, DialogProps, FormInstance, FormItemProp, FormItemProps, FormItemRule, FormProps, TableColumnInstance, TableInstance } from "element-plus";
@@ -252,7 +252,7 @@ declare function isValidateError(prop: string): boolean;
252
252
  declare const expose$1: {
253
253
  reValidateErrorFields: typeof reValidateErrorFields;
254
254
  isValidateError: typeof isValidateError;
255
- model: vue32.ComputedRef<unknown>;
255
+ model: vue27.ComputedRef<unknown>;
256
256
  };
257
257
  type __TdFormExpose = typeof expose$1 & FormInstance;
258
258
  declare var __VLS_11$1: {}, __VLS_13$1: {}, __VLS_19$1: {};
@@ -263,24 +263,24 @@ type __VLS_Slots$3 = {} & {
263
263
  } & {
264
264
  suffix?: (props: typeof __VLS_19$1) => any;
265
265
  };
266
- declare const __VLS_base$3: vue32.DefineComponent<vue32.ExtractPropTypes<{
266
+ declare const __VLS_base$3: vue27.DefineComponent<vue27.ExtractPropTypes<{
267
267
  fields: {
268
- type: vue32.PropType<TdFormFieldProps[]>;
268
+ type: vue27.PropType<TdFormFieldProps[]>;
269
269
  default: () => never[];
270
270
  };
271
271
  item: {
272
- type: vue32.PropType<element_plus0.FormItemProps>;
272
+ type: vue27.PropType<element_plus0.FormItemProps>;
273
273
  default: () => {};
274
274
  };
275
- }>, __TdFormExpose, {}, {}, {}, vue32.ComponentOptionsMixin, vue32.ComponentOptionsMixin, {
275
+ }>, __TdFormExpose, {}, {}, {}, vue27.ComponentOptionsMixin, vue27.ComponentOptionsMixin, {
276
276
  submit: (data: any) => any;
277
- }, string, vue32.PublicProps, Readonly<vue32.ExtractPropTypes<{
277
+ }, string, vue27.PublicProps, Readonly<vue27.ExtractPropTypes<{
278
278
  fields: {
279
- type: vue32.PropType<TdFormFieldProps[]>;
279
+ type: vue27.PropType<TdFormFieldProps[]>;
280
280
  default: () => never[];
281
281
  };
282
282
  item: {
283
- type: vue32.PropType<element_plus0.FormItemProps>;
283
+ type: vue27.PropType<element_plus0.FormItemProps>;
284
284
  default: () => {};
285
285
  };
286
286
  }>> & Readonly<{
@@ -288,7 +288,7 @@ declare const __VLS_base$3: vue32.DefineComponent<vue32.ExtractPropTypes<{
288
288
  }>, {
289
289
  fields: TdFormFieldProps[];
290
290
  item: element_plus0.FormItemProps;
291
- }, {}, {}, {}, string, vue32.ComponentProvideOptions, true, {}, any>;
291
+ }, {}, {}, {}, string, vue27.ComponentProvideOptions, true, {}, any>;
292
292
  declare const __VLS_export$5: __VLS_WithSlots$3<typeof __VLS_base$3, __VLS_Slots$3>;
293
293
  declare const _default$1: typeof __VLS_export$5;
294
294
  type __VLS_WithSlots$3<T, S> = T & {
@@ -300,37 +300,37 @@ type __VLS_WithSlots$3<T, S> = T & {
300
300
  //#region src/form/form-item.vue.d.ts
301
301
  declare var __VLS_10: string | number, __VLS_11: any;
302
302
  type __VLS_Slots$2 = {} & { [K in NonNullable<typeof __VLS_10>]?: (props: typeof __VLS_11) => any };
303
- declare const __VLS_base$2: vue32.DefineComponent<vue32.ExtractPropTypes<{
303
+ declare const __VLS_base$2: vue27.DefineComponent<vue27.ExtractPropTypes<{
304
304
  messageLabel: {
305
- type: vue32.PropType<OrRef<string>>;
305
+ type: vue27.PropType<OrRef<string>>;
306
306
  default: string;
307
307
  };
308
308
  formatMessage: {
309
- type: vue32.PropType<AnyFunction>;
309
+ type: vue27.PropType<AnyFunction>;
310
310
  default: null;
311
311
  };
312
312
  hideRequiredAsterisk: {
313
- type: vue32.PropType<boolean>;
313
+ type: vue27.PropType<boolean>;
314
314
  default: boolean;
315
315
  };
316
- }>, {}, {}, {}, {}, vue32.ComponentOptionsMixin, vue32.ComponentOptionsMixin, {}, string, vue32.PublicProps, Readonly<vue32.ExtractPropTypes<{
316
+ }>, {}, {}, {}, {}, vue27.ComponentOptionsMixin, vue27.ComponentOptionsMixin, {}, string, vue27.PublicProps, Readonly<vue27.ExtractPropTypes<{
317
317
  messageLabel: {
318
- type: vue32.PropType<OrRef<string>>;
318
+ type: vue27.PropType<OrRef<string>>;
319
319
  default: string;
320
320
  };
321
321
  formatMessage: {
322
- type: vue32.PropType<AnyFunction>;
322
+ type: vue27.PropType<AnyFunction>;
323
323
  default: null;
324
324
  };
325
325
  hideRequiredAsterisk: {
326
- type: vue32.PropType<boolean>;
326
+ type: vue27.PropType<boolean>;
327
327
  default: boolean;
328
328
  };
329
329
  }>> & Readonly<{}>, {
330
330
  messageLabel: any;
331
331
  formatMessage: AnyFunction;
332
332
  hideRequiredAsterisk: boolean;
333
- }, {}, {}, {}, string, vue32.ComponentProvideOptions, true, {}, any>;
333
+ }, {}, {}, {}, string, vue27.ComponentProvideOptions, true, {}, any>;
334
334
  declare const __VLS_export$4: __VLS_WithSlots$2<typeof __VLS_base$2, __VLS_Slots$2>;
335
335
  declare const _default$3: typeof __VLS_export$4;
336
336
  type __VLS_WithSlots$2<T, S> = T & {
@@ -340,7 +340,7 @@ type __VLS_WithSlots$2<T, S> = T & {
340
340
  };
341
341
  //#endregion
342
342
  //#region src/form/form-field.vue.d.ts
343
- declare const __VLS_export$3: vue32.DefineComponent<{}, {}, {}, {}, {}, vue32.ComponentOptionsMixin, vue32.ComponentOptionsMixin, {}, string, vue32.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue32.ComponentProvideOptions, true, {}, any>;
343
+ declare const __VLS_export$3: vue27.DefineComponent<{}, {}, {}, {}, {}, vue27.ComponentOptionsMixin, vue27.ComponentOptionsMixin, {}, string, vue27.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue27.ComponentProvideOptions, true, {}, any>;
344
344
  declare const _default$2: typeof __VLS_export$3;
345
345
  //#endregion
346
346
  //#region src/form/index.d.ts
@@ -380,19 +380,19 @@ type __VLS_Slots$1 = {} & { [K in NonNullable<typeof __VLS_16>]?: (props: typeof
380
380
  } & {
381
381
  after?: (props: typeof __VLS_19) => any;
382
382
  };
383
- declare const __VLS_base$1: vue32.DefineComponent<vue32.ExtractPropTypes<{
383
+ declare const __VLS_base$1: vue27.DefineComponent<vue27.ExtractPropTypes<{
384
384
  columns: {
385
- type: vue32.PropType<TdTableColumnProps[]>;
385
+ type: vue27.PropType<TdTableColumnProps[]>;
386
386
  default: () => never[];
387
387
  };
388
- }>, TableInstance, {}, {}, {}, vue32.ComponentOptionsMixin, vue32.ComponentOptionsMixin, {}, string, vue32.PublicProps, Readonly<vue32.ExtractPropTypes<{
388
+ }>, TableInstance, {}, {}, {}, vue27.ComponentOptionsMixin, vue27.ComponentOptionsMixin, {}, string, vue27.PublicProps, Readonly<vue27.ExtractPropTypes<{
389
389
  columns: {
390
- type: vue32.PropType<TdTableColumnProps[]>;
390
+ type: vue27.PropType<TdTableColumnProps[]>;
391
391
  default: () => never[];
392
392
  };
393
393
  }>> & Readonly<{}>, {
394
394
  columns: TdTableColumnProps[];
395
- }, {}, {}, {}, string, vue32.ComponentProvideOptions, true, {}, any>;
395
+ }, {}, {}, {}, string, vue27.ComponentProvideOptions, true, {}, any>;
396
396
  declare const __VLS_export$2: __VLS_WithSlots$1<typeof __VLS_base$1, __VLS_Slots$1>;
397
397
  declare const _default$4: typeof __VLS_export$2;
398
398
  type __VLS_WithSlots$1<T, S> = T & {
@@ -402,37 +402,37 @@ type __VLS_WithSlots$1<T, S> = T & {
402
402
  };
403
403
  //#endregion
404
404
  //#region src/table/table-col.vue.d.ts
405
- declare const __VLS_export$1: vue32.DefineComponent<vue32.ExtractPropTypes<{
405
+ declare const __VLS_export$1: vue27.DefineComponent<vue27.ExtractPropTypes<{
406
406
  slots: {
407
- type: vue32.PropType<OrArray<SlotDef>>;
407
+ type: vue27.PropType<OrArray<SlotDef>>;
408
408
  default: () => null;
409
409
  };
410
410
  columns: {
411
- type: vue32.PropType<any[]>;
411
+ type: vue27.PropType<any[]>;
412
412
  default: () => never[];
413
413
  };
414
414
  transform: {
415
- type: vue32.PropType<AnyFunction[]>;
415
+ type: vue27.PropType<AnyFunction[]>;
416
416
  default: () => never[];
417
417
  };
418
- }>, {}, {}, {}, {}, vue32.ComponentOptionsMixin, vue32.ComponentOptionsMixin, {}, string, vue32.PublicProps, Readonly<vue32.ExtractPropTypes<{
418
+ }>, {}, {}, {}, {}, vue27.ComponentOptionsMixin, vue27.ComponentOptionsMixin, {}, string, vue27.PublicProps, Readonly<vue27.ExtractPropTypes<{
419
419
  slots: {
420
- type: vue32.PropType<OrArray<SlotDef>>;
420
+ type: vue27.PropType<OrArray<SlotDef>>;
421
421
  default: () => null;
422
422
  };
423
423
  columns: {
424
- type: vue32.PropType<any[]>;
424
+ type: vue27.PropType<any[]>;
425
425
  default: () => never[];
426
426
  };
427
427
  transform: {
428
- type: vue32.PropType<AnyFunction[]>;
428
+ type: vue27.PropType<AnyFunction[]>;
429
429
  default: () => never[];
430
430
  };
431
431
  }>> & Readonly<{}>, {
432
432
  slots: OrArray<SlotDef>;
433
433
  columns: any[];
434
434
  transform: AnyFunction[];
435
- }, {}, {}, {}, string, vue32.ComponentProvideOptions, true, {}, any>;
435
+ }, {}, {}, {}, string, vue27.ComponentProvideOptions, true, {}, any>;
436
436
  declare const _default$5: typeof __VLS_export$1;
437
437
  //#endregion
438
438
  //#region src/table/index.d.ts
@@ -465,7 +465,7 @@ declare var __VLS_13: "default" | "title" | "header" | "footer", __VLS_14: {
465
465
  titleClass?: string | undefined;
466
466
  };
467
467
  type __VLS_Slots = {} & { [K in NonNullable<typeof __VLS_13>]?: (props: typeof __VLS_14) => any };
468
- declare const __VLS_base: vue32.DefineComponent<{}, __TdDialogExpose, {}, {}, {}, vue32.ComponentOptionsMixin, vue32.ComponentOptionsMixin, {}, string, vue32.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue32.ComponentProvideOptions, true, {}, any>;
468
+ declare const __VLS_base: vue27.DefineComponent<{}, __TdDialogExpose, {}, {}, {}, vue27.ComponentOptionsMixin, vue27.ComponentOptionsMixin, {}, string, vue27.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue27.ComponentProvideOptions, true, {}, any>;
469
469
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
470
470
  declare const _default: typeof __VLS_export;
471
471
  type __VLS_WithSlots<T, S> = T & {
@@ -479,10 +479,10 @@ type Instance = InstanceType<typeof _default>;
479
479
  type TdDialogInstance = Instance & Omit<DialogInstance, keyof Instance & string>;
480
480
  //#endregion
481
481
  //#region src/hooks/use-reuse.d.ts
482
- declare function useReuse(): (vue32.DefineComponent<{}, () => null, {}, {}, {}, vue32.ComponentOptionsMixin, vue32.ComponentOptionsMixin, {}, string, vue32.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue32.ComponentProvideOptions, true, {}, any> | vue32.DefineComponent<{}, () => vue32.VNode<vue32.RendererNode, vue32.RendererElement, {
482
+ declare function useReuse(): (vue27.DefineComponent<{}, () => null, {}, {}, {}, vue27.ComponentOptionsMixin, vue27.ComponentOptionsMixin, {}, string, vue27.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue27.ComponentProvideOptions, true, {}, any> | vue27.DefineComponent<{}, () => vue27.VNode<vue27.RendererNode, vue27.RendererElement, {
483
483
  [key: string]: any;
484
- }>[] | undefined, {}, {}, {}, vue32.ComponentOptionsMixin, vue32.ComponentOptionsMixin, {}, string, vue32.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue32.ComponentProvideOptions, true, {}, any> | vue32.ComputedRef<Readonly<{
485
- [name: string]: vue32.Slot<any> | undefined;
484
+ }>[] | undefined, {}, {}, {}, vue27.ComponentOptionsMixin, vue27.ComponentOptionsMixin, {}, string, vue27.PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, vue27.ComponentProvideOptions, true, {}, any> | vue27.ComputedRef<Readonly<{
485
+ [name: string]: vue27.Slot<any> | undefined;
486
486
  }>>)[];
487
487
  //#endregion
488
488
  //#region src/utils/index.d.ts
package/dist/index.js CHANGED
@@ -435,9 +435,8 @@ var widget_field_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ d
435
435
  ...pick(props, ["rules", /^label/])
436
436
  };
437
437
  });
438
- function onModelChange(...args) {
438
+ function onModelChange() {
439
439
  if (props.modifiers.includes("lazy")) updateModelValue(tempValue.value);
440
- props.on.blur?.(...args);
441
440
  }
442
441
  function updateModelValue(v) {
443
442
  const parsed = props.parser(v);
@@ -468,11 +467,10 @@ var widget_field_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ d
468
467
  "ctx-key": unref(formCtxKey)
469
468
  }), null, 16, ["scope", "ctx-key"]);
470
469
  }), 128)),
471
- !!unref(Widget) ? (openBlock(), createBlock(unref(Widget), mergeProps({ key: 0 }, widgetAttrs.value, toHandlers(_ctx.on), {
470
+ !!unref(Widget) ? (openBlock(), createBlock(unref(Widget), mergeProps({ key: 0 }, widgetAttrs.value, { onBlur: onModelChange }, toHandlers(_ctx.on), {
472
471
  modelValue: widgetModel.value,
473
472
  "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => widgetModel.value = $event),
474
- class: "widget-component",
475
- onBlur: onModelChange
473
+ class: "widget-component"
476
474
  }), createSlots({ _: 2 }, [renderList(unref(widgetSlots), (sc) => {
477
475
  return {
478
476
  name: sc.name,
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "tiddy",
3
- "version": "2.0.7",
3
+ "version": "2.0.8",
4
+ "packageManager": "pnpm@10.11.0",
4
5
  "description": "A set of Vue 3 components based on element-plus",
5
6
  "type": "module",
6
7
  "license": "MIT",
@@ -13,9 +14,7 @@
13
14
  "url": "git+https://github.com/leemotive/tiddy.git"
14
15
  },
15
16
  "author": "leemotive <wstation@163.com>",
16
- "files": [
17
- "dist"
18
- ],
17
+ "files": ["dist"],
19
18
  "main": "./dist/index.js",
20
19
  "module": "./dist/index.js",
21
20
  "types": "./dist/index.d.ts",
@@ -24,6 +23,19 @@
24
23
  "./package.json": "./package.json",
25
24
  "./*": "./dist/*"
26
25
  },
26
+ "scripts": {
27
+ "lint": "biome lint .",
28
+ "build": "tsdown",
29
+ "dev": "tsdown --watch",
30
+ "play": "vite",
31
+ "test": "vitest",
32
+ "type": "vue-tsc --noEmit",
33
+ "format": "biome format --write .",
34
+ "prepublishOnly": "pnpm run build",
35
+ "docs:dev": "vitepress dev docs",
36
+ "docs:build": "vitepress build docs",
37
+ "docs:preview": "vitepress preview docs"
38
+ },
27
39
  "peerDependencies": {
28
40
  "element-plus": "^2.11.7",
29
41
  "vue": "^3.0.0"
@@ -51,17 +63,5 @@
51
63
  },
52
64
  "dependencies": {
53
65
  "yatter": "^3.0.0"
54
- },
55
- "scripts": {
56
- "lint": "biome lint .",
57
- "build": "tsdown",
58
- "dev": "tsdown --watch",
59
- "play": "vite",
60
- "test": "vitest",
61
- "type": "vue-tsc --noEmit",
62
- "format": "biome format --write .",
63
- "docs:dev": "vitepress dev docs",
64
- "docs:build": "vitepress build docs",
65
- "docs:preview": "vitepress preview docs"
66
66
  }
67
- }
67
+ }