@antify/ui-module 1.7.1 → 1.7.2

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/dist/module.d.mts +1 -6
  2. package/dist/module.d.ts +1 -6
  3. package/dist/module.json +1 -1
  4. package/dist/module.mjs +1 -7
  5. package/dist/runtime/components/AntTooltip.vue +72 -66
  6. package/dist/runtime/components/__stories/AntTooltip.stories.d.ts +5 -0
  7. package/dist/runtime/components/__stories/AntTooltip.stories.mjs +24 -0
  8. package/dist/runtime/components/buttons/AntActionButton.vue +22 -19
  9. package/dist/runtime/components/buttons/AntSaveAndNewButton.vue +12 -11
  10. package/dist/runtime/components/buttons/AntSaveButton.vue +11 -10
  11. package/dist/runtime/components/buttons/__stories/AntActionButton.stories.mjs +9 -5
  12. package/dist/runtime/components/crud/AntCrudDetailActions.vue +1 -1
  13. package/dist/runtime/components/crud/AntCrudDetailNav.vue +8 -1
  14. package/dist/runtime/components/forms/AntField.vue +16 -2
  15. package/dist/runtime/components/inputs/AntSwitch.vue +30 -18
  16. package/dist/runtime/components/inputs/Elements/AntInputLabel.vue +10 -3
  17. package/dist/runtime/components/inputs/Elements/__stories/AntInputLabel.stories.mjs +1 -1
  18. package/dist/runtime/components/inputs/__stories/AntSwitch.stories.mjs +55 -7
  19. package/dist/runtime/components/inputs/__types/index.d.ts +0 -1
  20. package/dist/runtime/components/inputs/__types/index.mjs +0 -1
  21. package/dist/types.d.mts +1 -1
  22. package/dist/types.d.ts +1 -1
  23. package/package.json +1 -1
  24. package/src/runtime/components/AntTooltip.vue +72 -66
  25. package/src/runtime/components/buttons/AntActionButton.vue +22 -19
  26. package/src/runtime/components/buttons/AntSaveAndNewButton.vue +12 -11
  27. package/src/runtime/components/buttons/AntSaveButton.vue +11 -10
  28. package/src/runtime/components/crud/AntCrudDetailActions.vue +1 -1
  29. package/src/runtime/components/crud/AntCrudDetailNav.vue +8 -1
  30. package/src/runtime/components/forms/AntField.vue +16 -2
  31. package/src/runtime/components/inputs/AntSwitch.vue +30 -18
  32. package/src/runtime/components/inputs/Elements/AntInputLabel.vue +10 -3
  33. package/dist/runtime/components/inputs/__types/AntSwitch.types.d.ts +0 -4
  34. package/dist/runtime/components/inputs/__types/AntSwitch.types.mjs +0 -5
@@ -15,7 +15,7 @@ const props = withDefaults(defineProps<{
15
15
  size: Size.md,
16
16
  });
17
17
 
18
- const classes = computed(() => ({
18
+ const fontClasses = computed(() => ({
19
19
  'relative font-medium w-fit text-for-white-bg-font': true,
20
20
  'text-2xs': props.size === Size.xs2,
21
21
  'text-xs': props.size === Size.xs,
@@ -23,6 +23,12 @@ const classes = computed(() => ({
23
23
  'text-md': props.size === Size.md,
24
24
  'text-lg': props.size === Size.lg
25
25
  }));
26
+ const gapSize = computed(() => ({
27
+ 'gap-2.5': props.size === Size.lg,
28
+ 'gap-2': props.size === Size.md,
29
+ 'gap-1.5': props.size === Size.sm || props.size === Size.xs,
30
+ 'gap-1': props.size === Size.xs2,
31
+ }));
26
32
 
27
33
  onMounted(() => {
28
34
  handleEnumValidation(props.size, Size, 'size');
@@ -31,11 +37,12 @@ onMounted(() => {
31
37
 
32
38
  <template>
33
39
  <label
34
- class="flex flex-col gap-1.5 w-full"
40
+ class="flex flex-col w-full"
41
+ :class="gapSize"
35
42
  >
36
43
  <span
37
44
  v-if="label"
38
- :class="classes"
45
+ :class="fontClasses"
39
46
  >
40
47
  <span
41
48
  :class="{'invisible': skeleton}"
@@ -1,4 +0,0 @@
1
- export declare enum AntSwitchSize {
2
- md = "md",
3
- sm = "sm"
4
- }
@@ -1,5 +0,0 @@
1
- export var AntSwitchSize = /* @__PURE__ */ ((AntSwitchSize2) => {
2
- AntSwitchSize2["md"] = "md";
3
- AntSwitchSize2["sm"] = "sm";
4
- return AntSwitchSize2;
5
- })(AntSwitchSize || {});