@tagplus/components 5.3.7 → 5.3.11

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 (111) hide show
  1. package/dist/es/components.css +132 -132
  2. package/dist/es/node_modules/@element-plus/icons-vue/dist/index.mjs +20 -29
  3. package/dist/es/node_modules/@popperjs/core/dist/index.mjs +586 -0
  4. package/dist/es/node_modules/@vue/shared/dist/shared.esm-bundler.mjs +0 -5
  5. package/dist/es/node_modules/@vueuse/core/index.mjs +58 -103
  6. package/dist/es/node_modules/@vueuse/shared/index.mjs +16 -47
  7. package/dist/es/node_modules/element-plus/es/constants/size.mjs +6 -1
  8. package/dist/es/node_modules/element-plus/es/hooks/use-focus-controller/index.mjs +17 -36
  9. package/dist/es/node_modules/element-plus/es/hooks/use-id/index.mjs +5 -8
  10. package/dist/es/node_modules/element-plus/es/hooks/use-locale/index.mjs +7 -12
  11. package/dist/es/node_modules/element-plus/es/hooks/use-namespace/index.mjs +7 -22
  12. package/dist/es/node_modules/element-plus/es/hooks/use-prop/index.mjs +1 -4
  13. package/dist/es/node_modules/element-plus/es/hooks/use-size/index.mjs +3 -3
  14. package/dist/es/node_modules/element-plus/es/locale/lang/en.mjs +28 -31
  15. package/dist/es/node_modules/element-plus/es/utils/dom/aria.mjs +19 -0
  16. package/dist/es/node_modules/element-plus/es/utils/error.mjs +4 -3
  17. package/dist/es/node_modules/element-plus/es/utils/vue/props/runtime.mjs +19 -25
  18. package/dist/es/src/components/Autosuggest/Autosuggest.vue.mjs +264 -267
  19. package/dist/es/src/components/Autosuggest/Multisuggest.vue.mjs +5 -3
  20. package/dist/es/src/components/Autosuggest/autosuggest-props.mjs +2 -2
  21. package/dist/es/src/components/Autosuggest/core.mjs +4 -4
  22. package/dist/es/src/components/Autosuggest/option.vue.mjs +2 -2
  23. package/dist/es/src/components/Autosuggest/select-dropdown.vue.mjs +3 -4
  24. package/dist/es/src/components/Autosuggest/useOption.mjs +2 -2
  25. package/dist/es/src/components/Autosuggest/useSelect.mjs +16 -22
  26. package/dist/es/src/components/Inline/Inline.vue.mjs +2 -2
  27. package/dist/es/src/components/InputNumber/InputNumber.vue.mjs +36 -26
  28. package/dist/es/src/components/InputNumber/input-number.mjs +11 -3
  29. package/dist/es/src/components/Loader/Loader.vue.mjs +3 -3
  30. package/dist/es/src/components/Money/Money.vue.mjs +2 -2
  31. package/dist/es/src/components/OptionsList/OptionsList.vue.mjs +2 -2
  32. package/dist/es/src/components/OptionsListItem/OptionsListItem.vue.mjs +2 -2
  33. package/dist/es/src/components/Percent/Percent.vue.mjs +4 -4
  34. package/dist/es/src/components/Skeleton/Skeleton.vue.mjs +2 -2
  35. package/dist/es/src/components/Step/Step.vue.mjs +2 -2
  36. package/dist/es/src/components/Steps/Steps.vue.mjs +1 -1
  37. package/dist/es/src/components/Tip/Tip.vue.mjs +6 -6
  38. package/dist/es/src/locale/i18nCreator.mjs +1 -1
  39. package/dist/es/src/plugins/currency.mjs +4 -6
  40. package/dist/es/src/utils/constants.mjs +2 -2
  41. package/dist/es/src/utils/runtime.mjs +3 -3
  42. package/dist/es/src/utils/use-derived-namespace.mjs +1 -1
  43. package/dist/es/src/utils/use-form-common-props.mjs +3 -3
  44. package/dist/es/src/utils/use-form-item.mjs +5 -6
  45. package/dist/es/src/utils/use-id.mjs +2 -2
  46. package/dist/es/src/utils/use-input.mjs +2 -2
  47. package/dist/lib/components.css +132 -132
  48. package/dist/lib/node_modules/@element-plus/icons-vue/dist/index.js +19 -28
  49. package/dist/lib/node_modules/@popperjs/core/dist/index.js +586 -0
  50. package/dist/lib/node_modules/@vue/shared/dist/shared.esm-bundler.js +0 -5
  51. package/dist/lib/node_modules/@vueuse/core/index.js +56 -100
  52. package/dist/lib/node_modules/@vueuse/shared/index.js +15 -46
  53. package/dist/lib/node_modules/element-plus/es/constants/size.js +6 -1
  54. package/dist/lib/node_modules/element-plus/es/hooks/use-focus-controller/index.js +17 -36
  55. package/dist/lib/node_modules/element-plus/es/hooks/use-id/index.js +5 -8
  56. package/dist/lib/node_modules/element-plus/es/hooks/use-locale/index.js +6 -11
  57. package/dist/lib/node_modules/element-plus/es/hooks/use-namespace/index.js +7 -22
  58. package/dist/lib/node_modules/element-plus/es/hooks/use-prop/index.js +1 -4
  59. package/dist/lib/node_modules/element-plus/es/hooks/use-size/index.js +3 -3
  60. package/dist/lib/node_modules/element-plus/es/locale/lang/en.js +28 -31
  61. package/dist/lib/node_modules/element-plus/es/utils/dom/aria.js +19 -0
  62. package/dist/lib/node_modules/element-plus/es/utils/error.js +4 -3
  63. package/dist/lib/node_modules/element-plus/es/utils/vue/props/runtime.js +19 -25
  64. package/dist/lib/src/components/Autosuggest/Autosuggest.vue.js +264 -267
  65. package/dist/lib/src/components/Autosuggest/Multisuggest.vue.js +5 -3
  66. package/dist/lib/src/components/Autosuggest/autosuggest-props.js +2 -2
  67. package/dist/lib/src/components/Autosuggest/core.js +4 -4
  68. package/dist/lib/src/components/Autosuggest/option.vue.js +2 -2
  69. package/dist/lib/src/components/Autosuggest/select-dropdown.vue.js +3 -4
  70. package/dist/lib/src/components/Autosuggest/useOption.js +2 -2
  71. package/dist/lib/src/components/Autosuggest/useSelect.js +16 -22
  72. package/dist/lib/src/components/Inline/Inline.vue.js +2 -2
  73. package/dist/lib/src/components/InputNumber/InputNumber.vue.js +35 -25
  74. package/dist/lib/src/components/InputNumber/input-number.js +11 -3
  75. package/dist/lib/src/components/Loader/Loader.vue.js +2 -2
  76. package/dist/lib/src/components/Money/Money.vue.js +2 -2
  77. package/dist/lib/src/components/OptionsList/OptionsList.vue.js +1 -1
  78. package/dist/lib/src/components/OptionsListItem/OptionsListItem.vue.js +1 -1
  79. package/dist/lib/src/components/Percent/Percent.vue.js +4 -4
  80. package/dist/lib/src/components/Skeleton/Skeleton.vue.js +1 -1
  81. package/dist/lib/src/components/Step/Step.vue.js +1 -1
  82. package/dist/lib/src/components/Steps/Steps.vue.js +1 -1
  83. package/dist/lib/src/components/Tip/Tip.vue.js +5 -5
  84. package/dist/lib/src/locale/i18nCreator.js +1 -1
  85. package/dist/lib/src/plugins/currency.js +4 -6
  86. package/dist/lib/src/utils/constants.js +2 -2
  87. package/dist/lib/src/utils/runtime.js +3 -3
  88. package/dist/lib/src/utils/use-derived-namespace.js +1 -1
  89. package/dist/lib/src/utils/use-form-common-props.js +3 -3
  90. package/dist/lib/src/utils/use-form-item.js +5 -6
  91. package/dist/lib/src/utils/use-id.js +2 -2
  92. package/dist/lib/src/utils/use-input.js +2 -2
  93. package/package.json +24 -32
  94. package/dist/demo.html +0 -1
  95. package/dist/es/node_modules/@popperjs/core/lib/enums.mjs +0 -22
  96. package/dist/es/node_modules/element-plus/es/utils/types.mjs +0 -9
  97. package/dist/fonts/bevi-bold.7e4dcd11.woff +0 -0
  98. package/dist/fonts/bevi-bold.873def84.woff2 +0 -0
  99. package/dist/fonts/bevi-medium.6187e050.woff2 +0 -0
  100. package/dist/fonts/bevi-medium.65b3056d.woff +0 -0
  101. package/dist/fonts/bevi-regular.c89f126e.woff +0 -0
  102. package/dist/fonts/bevi-regular.f81e4b8f.woff2 +0 -0
  103. package/dist/lib/node_modules/@popperjs/core/lib/enums.js +0 -22
  104. package/dist/lib/node_modules/element-plus/es/utils/types.js +0 -9
  105. package/dist/tp.common.js +0 -2
  106. package/dist/tp.common.js.map +0 -1
  107. package/dist/tp.css +0 -167
  108. package/dist/tp.umd.js +0 -2
  109. package/dist/tp.umd.js.map +0 -1
  110. package/dist/tp.umd.min.js +0 -2
  111. package/dist/tp.umd.min.js.map +0 -1
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
- const enums = require("../../../node_modules/@popperjs/core/lib/enums.js");
3
+ const index = require("../../../node_modules/@popperjs/core/dist/index.js");
4
4
  const autosuggestProps = {
5
5
  /**
6
6
  * @deprecated
@@ -140,7 +140,7 @@ const autosuggestProps = {
140
140
  */
141
141
  placement: {
142
142
  type: String,
143
- values: enums.placements,
143
+ values: index.placements,
144
144
  default: "bottom-start"
145
145
  },
146
146
  /**
@@ -1,11 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
- const vue = require("vue");
4
- const elementPlus = require("element-plus");
5
- const index = require("../../../node_modules/@element-plus/icons-vue/dist/index.js");
6
- const selectDropdown = require("./select-dropdown.vue.js");
7
3
  const option = require("./option.vue.js");
4
+ const selectDropdown = require("./select-dropdown.vue.js");
8
5
  const useSelect = require("./useSelect.js");
6
+ const index = require("../../../node_modules/@element-plus/icons-vue/dist/index.js");
7
+ const elementPlus = require("element-plus");
8
+ const vue = require("vue");
9
9
  function autosuggestCore(component_name, propsDefinition) {
10
10
  return {
11
11
  name: component_name,
@@ -1,10 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
- const vue = require("vue");
4
3
  const useOption = require("./useOption.js");
5
- const _pluginVue_exportHelper = require("../../../_virtual/_plugin-vue_export-helper.js");
6
4
  const index = require("../../../node_modules/element-plus/es/hooks/use-namespace/index.js");
7
5
  const index$1 = require("../../../node_modules/element-plus/es/hooks/use-id/index.js");
6
+ const vue = require("vue");
7
+ const _pluginVue_exportHelper = require("../../../_virtual/_plugin-vue_export-helper.js");
8
8
  const _sfc_main = vue.defineComponent({
9
9
  name: "ElOption",
10
10
  componentName: "ElOption",
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
- const vue = require("vue");
4
3
  const index = require("../../../node_modules/@vueuse/core/index.js");
5
- const _pluginVue_exportHelper = require("../../../_virtual/_plugin-vue_export-helper.js");
6
4
  const index$1 = require("../../../node_modules/element-plus/es/hooks/use-namespace/index.js");
5
+ const vue = require("vue");
6
+ const _pluginVue_exportHelper = require("../../../_virtual/_plugin-vue_export-helper.js");
7
7
  const _sfc_main = vue.defineComponent({
8
8
  name: "ElSelectDropdown",
9
9
  componentName: "ElSelectDropdown",
@@ -33,8 +33,7 @@ const _sfc_main = vue.defineComponent({
33
33
  },
34
34
  methods: {
35
35
  updateMinWidth() {
36
- var _a;
37
- this.minWidth = `${(_a = this.select.selectRef) == null ? void 0 : _a.offsetWidth}px`;
36
+ this.minWidth = `${this.select.selectRef?.offsetWidth}px`;
38
37
  }
39
38
  }
40
39
  });
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const vue = require("vue");
4
- const lodashEs = require("lodash-es");
5
3
  const strings = require("../../utils/strings.js");
4
+ const lodashEs = require("lodash-es");
5
+ const vue = require("vue");
6
6
  const shared_esmBundler = require("../../../node_modules/@vue/shared/dist/shared.esm-bundler.js");
7
7
  function useOption(props, states) {
8
8
  const select = vue.inject("select");
@@ -1,19 +1,19 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const vue = require("vue");
4
3
  const shared_esmBundler = require("../../../node_modules/@vue/shared/dist/shared.esm-bundler.js");
5
- const lodashEs = require("lodash-es");
6
4
  const index$5 = require("../../../node_modules/@vueuse/core/index.js");
7
- const types = require("../../utils/types.js");
5
+ const lodashEs = require("lodash-es");
6
+ const vue = require("vue");
8
7
  const error = require("../../utils/error.js");
8
+ const types = require("../../utils/types.js");
9
9
  const icon = require("../../utils/icon.js");
10
10
  const scroll = require("../../utils/scroll.js");
11
- const useInput = require("../../utils/use-input.js");
12
- const useFormItem = require("../../utils/use-form-item.js");
13
11
  const useFormCommonProps = require("../../utils/use-form-common-props.js");
12
+ const useFormItem = require("../../utils/use-form-item.js");
13
+ const useInput = require("../../utils/use-input.js");
14
14
  const index = require("../../../node_modules/element-plus/es/hooks/use-locale/index.js");
15
- const index$1 = require("../../../node_modules/element-plus/es/hooks/use-id/index.js");
16
15
  const index$2 = require("../../../node_modules/element-plus/es/hooks/use-namespace/index.js");
16
+ const index$1 = require("../../../node_modules/element-plus/es/hooks/use-id/index.js");
17
17
  const index$3 = require("../../../node_modules/element-plus/es/hooks/use-focus-controller/index.js");
18
18
  const index$4 = require("../../../node_modules/@vueuse/shared/index.js");
19
19
  const UPDATE_MODEL_EVENT = "update:modelValue";
@@ -64,8 +64,7 @@ const useSelect = (props, { emit }) => {
64
64
  }
65
65
  },
66
66
  beforeBlur(event) {
67
- var _a;
68
- return (_a = tooltipRef.value) == null ? void 0 : _a.isFocusInsideContent(event);
67
+ return tooltipRef.value?.isFocusInsideContent(event);
69
68
  },
70
69
  afterBlur() {
71
70
  expanded.value = false;
@@ -79,7 +78,7 @@ const useSelect = (props, { emit }) => {
79
78
  const { inputId } = useFormItem.useFormItemInputId(props, {
80
79
  formItemContext: formItem
81
80
  });
82
- const selectDisabled = vue.computed(() => props.disabled || (form == null ? void 0 : form.disabled));
81
+ const selectDisabled = vue.computed(() => props.disabled || form?.disabled);
83
82
  const hasModelValue = vue.computed(() => {
84
83
  return props.multiple ? shared_esmBundler.isArray(props.modelValue) && props.modelValue.length > 0 : props.modelValue !== void 0 && props.modelValue !== null && props.modelValue !== "";
85
84
  });
@@ -111,7 +110,7 @@ const useSelect = (props, { emit }) => {
111
110
  }
112
111
  return newVal;
113
112
  });
114
- const validateState = vue.computed(() => (formItem == null ? void 0 : formItem.validateState) || "");
113
+ const validateState = vue.computed(() => formItem?.validateState || "");
115
114
  const validateIcon = vue.computed(
116
115
  () => icon.ValidateComponentsMap[validateState.value]
117
116
  );
@@ -224,7 +223,7 @@ const useSelect = (props, { emit }) => {
224
223
  }
225
224
  setSelected();
226
225
  if (!lodashEs.isEqual(val, oldVal) && props.validateEvent) {
227
- formItem == null ? void 0 : formItem.validate("change").catch((err) => error.debugWarn(err));
226
+ formItem?.validate("change").catch((err) => error.debugWarn(err));
228
227
  }
229
228
  },
230
229
  {
@@ -435,8 +434,7 @@ const useSelect = (props, { emit }) => {
435
434
  states.collapseItemWidth = collapseItemRef.value.getBoundingClientRect().width;
436
435
  };
437
436
  const updateTooltip = () => {
438
- var _a, _b;
439
- (_b = (_a = tooltipRef.value) == null ? void 0 : _a.updatePopper) == null ? void 0 : _b.call(_a);
437
+ tooltipRef.value?.updatePopper?.();
440
438
  };
441
439
  const onInputChange = () => {
442
440
  if (states.inputValue.length > 0 && !expanded.value) {
@@ -556,10 +554,9 @@ const useSelect = (props, { emit }) => {
556
554
  return -1;
557
555
  };
558
556
  const scrollToOption = (option) => {
559
- var _a, _b, _c, _d, _e;
560
557
  const targetOption = shared_esmBundler.isArray(option) ? option[0] : option;
561
558
  let target = null;
562
- if (targetOption == null ? void 0 : targetOption.value) {
559
+ if (targetOption?.value) {
563
560
  const options = optionsArray.value.filter(
564
561
  (item) => item.value === targetOption.value
565
562
  );
@@ -568,15 +565,14 @@ const useSelect = (props, { emit }) => {
568
565
  }
569
566
  }
570
567
  if (tooltipRef.value && target) {
571
- const menu = (_d = (_c = (_b = (_a = tooltipRef.value) == null ? void 0 : _a.popperRef) == null ? void 0 : _b.contentRef) == null ? void 0 : _c.querySelector) == null ? void 0 : _d.call(
572
- _c,
568
+ const menu = tooltipRef.value?.popperRef?.contentRef?.querySelector?.(
573
569
  `.${nsSelect.be("dropdown", "wrap")}`
574
570
  );
575
571
  if (menu) {
576
572
  scroll.scrollIntoView(menu, target);
577
573
  }
578
574
  }
579
- (_e = scrollbarRef.value) == null ? void 0 : _e.handleScroll();
575
+ scrollbarRef.value?.handleScroll();
580
576
  };
581
577
  const onOptionCreate = (vm) => {
582
578
  states.options.set(vm.value, vm);
@@ -594,15 +590,13 @@ const useSelect = (props, { emit }) => {
594
590
  handleCompositionEnd
595
591
  } = useInput.useInput((e) => onInput(e));
596
592
  const popperRef = vue.computed(() => {
597
- var _a, _b;
598
- return (_b = (_a = tooltipRef.value) == null ? void 0 : _a.popperRef) == null ? void 0 : _b.contentRef;
593
+ return tooltipRef.value?.popperRef?.contentRef;
599
594
  });
600
595
  const handleMenuEnter = () => {
601
596
  vue.nextTick(() => scrollToOption(states.selected));
602
597
  };
603
598
  const focus = () => {
604
- var _a;
605
- (_a = inputRef.value) == null ? void 0 : _a.focus();
599
+ inputRef.value?.focus();
606
600
  };
607
601
  const blur = () => {
608
602
  handleClickOutside();
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
- const vue = require("vue");
4
3
  const index = require("../../../node_modules/@element-plus/icons-vue/dist/index.js");
5
4
  const elementPlus = require("element-plus");
5
+ const vue = require("vue");
6
6
  ;/* empty css */
7
7
  const _pluginVue_exportHelper = require("../../../_virtual/_plugin-vue_export-helper.js");
8
8
  const _sfc_main = vue.defineComponent({
@@ -126,5 +126,5 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
126
126
  }, 8, ["id", "model-value", "onInput", "onBlur", "onKeypress"]))
127
127
  ], 8, _hoisted_1);
128
128
  }
129
- const Inline = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-e30c0e2a"]]);
129
+ const Inline = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-8cf574fc"]]);
130
130
  exports.default = Inline;
@@ -1,16 +1,16 @@
1
1
  "use strict";
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
3
  const vue = require("vue");
4
- const lodashEs = require("lodash-es");
5
- const types = require("../../utils/types.js");
4
+ const inputNumber = require("./input-number.js");
5
+ const index$2 = require("../../../node_modules/@element-plus/icons-vue/dist/index.js");
6
6
  const error = require("../../utils/error.js");
7
- const useFormItem = require("../../utils/use-form-item.js");
7
+ const types = require("../../utils/types.js");
8
8
  const useFormCommonProps = require("../../utils/use-form-common-props.js");
9
+ const useFormItem = require("../../utils/use-form-item.js");
9
10
  const elementPlus = require("element-plus");
10
- const index$2 = require("../../../node_modules/@element-plus/icons-vue/dist/index.js");
11
- const inputNumber = require("./input-number.js");
12
11
  const index = require("../../../node_modules/element-plus/es/hooks/use-locale/index.js");
13
12
  const index$1 = require("../../../node_modules/element-plus/es/hooks/use-namespace/index.js");
13
+ const lodashEs = require("lodash-es");
14
14
  const shared_esmBundler = require("../../../node_modules/@vue/shared/dist/shared.esm-bundler.js");
15
15
  const _hoisted_1 = ["aria-label"];
16
16
  const _hoisted_2 = ["aria-label"];
@@ -61,6 +61,13 @@ const _sfc_main = /* @__PURE__ */ Object.assign({
61
61
  });
62
62
  const inputNumberSize = useFormCommonProps.useFormSize();
63
63
  const inputNumberDisabled = useFormCommonProps.useFormDisabled();
64
+ const escapeRegExp = (value) => value.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
65
+ const toNumberValue = (value) => {
66
+ if (value === "") return null;
67
+ const normalizedValue = String(value).replace(",", ".");
68
+ const parsedValue = Number(normalizedValue);
69
+ return Number.isNaN(parsedValue) ? null : parsedValue;
70
+ };
64
71
  const displayValue = vue.computed(() => {
65
72
  if (data.userInput !== null) {
66
73
  return data.userInput;
@@ -82,18 +89,26 @@ const _sfc_main = /* @__PURE__ */ Object.assign({
82
89
  const decimalChar = vm.$t("locale.number.decimal");
83
90
  const thousandsChar = vm.$t("locale.number.thousands");
84
91
  return (value) => {
85
- const noLetters = value.replaceAll(/[a-zA-Z]/g, "");
86
- const res = noLetters.replace(".", decimalChar).replace(/\B(?=(\d{3})+(?!\d))/g, thousandsChar);
87
- return res;
92
+ if (value === null || value === void 0) return value;
93
+ const noLetters = String(value).replaceAll(/[a-zA-Z]/g, "");
94
+ if (!props.usarVirgula) {
95
+ return noLetters;
96
+ }
97
+ return noLetters.replace(".", decimalChar).replace(/\B(?=(\d{3})+(?!\d))/g, thousandsChar);
88
98
  };
89
99
  });
90
100
  const inputParser = vue.computed(() => {
91
101
  const decimalChar = vm.$t("locale.number.decimal");
92
102
  const thousandsChar = vm.$t("locale.number.thousands");
93
103
  return (value) => {
94
- const regexThou = `/$s?|(${thousandsChar}*)/g`;
95
- const res = value.replace(regexThou, "").replace(decimalChar, ".");
96
- return res;
104
+ if (!value) return value;
105
+ const inputValue = String(value).replaceAll(/[a-zA-Z]/g, "");
106
+ if (props.usarVirgula) {
107
+ const thousandsRegex = new RegExp(escapeRegExp(thousandsChar), "g");
108
+ const withoutThousands = inputValue.replace(thousandsRegex, "");
109
+ return withoutThousands.replace(decimalChar, ".");
110
+ }
111
+ return inputValue.replaceAll(",", "");
97
112
  };
98
113
  });
99
114
  const toPrecision = (num, pre) => {
@@ -169,7 +184,6 @@ const _sfc_main = /* @__PURE__ */ Object.assign({
169
184
  return newVal;
170
185
  };
171
186
  const setCurrentValue = (value, emitChange = true) => {
172
- var _a;
173
187
  const oldVal = data.currentValue;
174
188
  const newVal = verifyValue(value);
175
189
  if (!emitChange) {
@@ -181,14 +195,15 @@ const _sfc_main = /* @__PURE__ */ Object.assign({
181
195
  emit(UPDATE_MODEL_EVENT, newVal);
182
196
  emit(CHANGE_EVENT, newVal, oldVal);
183
197
  if (props.validateEvent) {
184
- (_a = formItem == null ? void 0 : formItem.validate) == null ? void 0 : _a.call(formItem, "change").catch((err) => error.debugWarn(err));
198
+ formItem?.validate?.("change").catch((err) => error.debugWarn(err));
185
199
  }
186
200
  data.currentValue = newVal;
187
201
  };
188
202
  const handleInput = (value) => {
189
203
  data.userInput = value;
190
- const newVal = value === "" ? null : Number(value);
204
+ const newVal = toNumberValue(value);
191
205
  emit(INPUT_EVENT, newVal);
206
+ emit(CHANGE_EVENT, newVal, data.currentValue);
192
207
  setCurrentValue(newVal, false);
193
208
  };
194
209
  const handleInputChange = (value) => {
@@ -200,22 +215,19 @@ const _sfc_main = /* @__PURE__ */ Object.assign({
200
215
  data.userInput = null;
201
216
  };
202
217
  const focus = () => {
203
- var _a, _b;
204
- (_b = (_a = input.value) == null ? void 0 : _a.focus) == null ? void 0 : _b.call(_a);
218
+ input.value?.focus?.();
205
219
  };
206
220
  const blur = () => {
207
- var _a, _b;
208
- (_b = (_a = input.value) == null ? void 0 : _a.blur) == null ? void 0 : _b.call(_a);
221
+ input.value?.blur?.();
209
222
  };
210
223
  const handleFocus = (event) => {
211
224
  emit("focus", event);
212
225
  };
213
226
  const handleBlur = (event) => {
214
- var _a;
215
227
  data.userInput = null;
216
228
  emit("blur", event);
217
229
  if (props.validateEvent) {
218
- (_a = formItem == null ? void 0 : formItem.validate) == null ? void 0 : _a.call(formItem, "blur").catch((err) => error.debugWarn(err));
230
+ formItem?.validate?.("blur").catch((err) => error.debugWarn(err));
219
231
  }
220
232
  };
221
233
  const setCurrentValueToModelValue = () => {
@@ -240,9 +252,8 @@ const _sfc_main = /* @__PURE__ */ Object.assign({
240
252
  }
241
253
  );
242
254
  vue.onMounted(() => {
243
- var _a;
244
255
  const { min, max, modelValue } = props;
245
- const innerInput = (_a = input.value) == null ? void 0 : _a.input;
256
+ const innerInput = input.value?.input;
246
257
  innerInput.setAttribute("role", "spinbutton");
247
258
  if (Number.isFinite(max)) {
248
259
  innerInput.setAttribute("aria-valuemax", String(max));
@@ -268,9 +279,8 @@ const _sfc_main = /* @__PURE__ */ Object.assign({
268
279
  }
269
280
  });
270
281
  vue.onUpdated(() => {
271
- var _a;
272
- const innerInput = (_a = input.value) == null ? void 0 : _a.input;
273
- innerInput == null ? void 0 : innerInput.setAttribute("aria-valuenow", `${data.currentValue ?? ""}`);
282
+ const innerInput = input.value?.input;
283
+ innerInput?.setAttribute("aria-valuenow", `${data.currentValue ?? ""}`);
274
284
  });
275
285
  __expose({
276
286
  /** @description get focus the input component */
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const lodashEs = require("lodash-es");
4
3
  const index = require("../../utils/index.js");
5
- const runtime = require("../../utils/runtime.js");
6
4
  const index$1 = require("../../../node_modules/element-plus/es/hooks/use-size/index.js");
5
+ const lodashEs = require("lodash-es");
6
+ const runtime = require("../../utils/runtime.js");
7
7
  const types = require("../../utils/types.js");
8
8
  const inputNumberProps = runtime.buildProps({
9
9
  /**
@@ -115,10 +115,18 @@ const inputNumberProps = runtime.buildProps({
115
115
  stringDefaultsZero: {
116
116
  type: Boolean,
117
117
  default: true
118
+ },
119
+ /**
120
+ * @tagplus
121
+ * Permite usar virgula como separador decimal na digitacao
122
+ **/
123
+ usarVirgula: {
124
+ type: Boolean,
125
+ default: true
118
126
  }
119
127
  });
120
128
  const inputNumberEmits = {
121
- [index.CHANGE_EVENT]: (cur, prev) => prev !== cur,
129
+ [index.CHANGE_EVENT]: (cur, prev) => (types.isNumber(cur) || lodashEs.isNil(cur) || cur === "") && (types.isNumber(prev) || lodashEs.isNil(prev) || prev === ""),
122
130
  blur: (e) => e instanceof FocusEvent,
123
131
  focus: (e) => e instanceof FocusEvent,
124
132
  [index.INPUT_EVENT]: (val) => types.isNumber(val) || lodashEs.isNil(val),
@@ -38,7 +38,7 @@ const _hoisted_4 = { class: "texto" };
38
38
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
39
39
  return vue.openBlock(), vue.createElementBlock("div", _hoisted_1, [
40
40
  vue.createElementVNode("div", _hoisted_2, [
41
- _cache[0] || (_cache[0] = vue.createStaticVNode('<svg xmlns="http://www.w3.org/2000/svg" width="150px" height="150px" data-v-719fb911><mask id="mascara" data-v-719fb911><rect x="0" y="0" width="100%" height="100%" fill="white" data-v-719fb911></rect><circle id="circulo-interno" class="circulo" cx="45" cy="50" r="40" fill="black" data-v-719fb911></circle></mask><g id="bola" fill="none" fill-rule="evenodd" transform="translate(30 30)" data-v-719fb911><circle id="circulo" class="circulo" cx="45" cy="50" r="40" fill="#1F7DE7" mask="url(#mascara)" data-v-719fb911></circle><g fill="none" fill-rule="evenodd" data-v-719fb911><circle class="residuo top center" cx="45" cy="9" r="15" fill="#FFCB05" data-v-719fb911></circle><circle class="residuo top right" cx="72" cy="21" r="8.5" fill="#1F7DE7" data-v-719fb911></circle><circle class="residuo middle right" cx="81" cy="45" r="12" fill="#1F7DE7" data-v-719fb911></circle><circle class="residuo bottom right" cx="71" cy="70" r="8.5" fill="none" stroke="#FFCB05" stroke-width="3" data-v-719fb911></circle><circle class="residuo bottom center" cx="45" cy="81" r="8.5" fill="none" stroke="#1F7DE7" stroke-width="3" data-v-719fb911></circle><circle class="residuo bottom left" cx="19" cy="70" r="8.5" fill="#1F7DE7" data-v-719fb911></circle><circle class="residuo middle left" cx="9" cy="45" r="10" fill="#FFCB05" data-v-719fb911></circle><circle class="residuo top left" cx="18" cy="21" r="8.5" fill="none" stroke="#1F7DE7" stroke-width="3" data-v-719fb911></circle></g></g></svg>', 1)),
41
+ _cache[0] || (_cache[0] = vue.createStaticVNode('<svg xmlns="http://www.w3.org/2000/svg" width="150px" height="150px" data-v-fdf492f2><mask id="mascara" data-v-fdf492f2><rect x="0" y="0" width="100%" height="100%" fill="white" data-v-fdf492f2></rect><circle id="circulo-interno" class="circulo" cx="45" cy="50" r="40" fill="black" data-v-fdf492f2></circle></mask><g id="bola" fill="none" fill-rule="evenodd" transform="translate(30 30)" data-v-fdf492f2><circle id="circulo" class="circulo" cx="45" cy="50" r="40" fill="#1F7DE7" mask="url(#mascara)" data-v-fdf492f2></circle><g fill="none" fill-rule="evenodd" data-v-fdf492f2><circle class="residuo top center" cx="45" cy="9" r="15" fill="#FFCB05" data-v-fdf492f2></circle><circle class="residuo top right" cx="72" cy="21" r="8.5" fill="#1F7DE7" data-v-fdf492f2></circle><circle class="residuo middle right" cx="81" cy="45" r="12" fill="#1F7DE7" data-v-fdf492f2></circle><circle class="residuo bottom right" cx="71" cy="70" r="8.5" fill="none" stroke="#FFCB05" stroke-width="3" data-v-fdf492f2></circle><circle class="residuo bottom center" cx="45" cy="81" r="8.5" fill="none" stroke="#1F7DE7" stroke-width="3" data-v-fdf492f2></circle><circle class="residuo bottom left" cx="19" cy="70" r="8.5" fill="#1F7DE7" data-v-fdf492f2></circle><circle class="residuo middle left" cx="9" cy="45" r="10" fill="#FFCB05" data-v-fdf492f2></circle><circle class="residuo top left" cx="18" cy="21" r="8.5" fill="none" stroke="#1F7DE7" stroke-width="3" data-v-fdf492f2></circle></g></g></svg>', 1)),
42
42
  vue.createElementVNode("div", _hoisted_3, [
43
43
  (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.icons, (icon, k) => {
44
44
  return vue.openBlock(), vue.createElementBlock("i", {
@@ -55,5 +55,5 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
55
55
  _cache[1] || (_cache[1] = vue.createElementVNode("div", { class: "overlay" }, null, -1))
56
56
  ]);
57
57
  }
58
- const Loader = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-719fb911"]]);
58
+ const Loader = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-fdf492f2"]]);
59
59
  exports.default = Loader;
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
- const vue = require("vue");
4
3
  const floatFormatter = require("../../mixins/floatFormatter.js");
5
4
  const elementPlus = require("element-plus");
5
+ const vue = require("vue");
6
6
  ;/* empty css */
7
7
  const _pluginVue_exportHelper = require("../../../_virtual/_plugin-vue_export-helper.js");
8
8
  const _sfc_main = vue.defineComponent({
@@ -72,5 +72,5 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
72
72
  })
73
73
  ]), 1040, ["id", "model-value", "maxlength", "onInput", "onChange"]);
74
74
  }
75
- const Money = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-3f676031"]]);
75
+ const Money = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-4afe98f3"]]);
76
76
  exports.default = Money;
@@ -24,5 +24,5 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
24
24
  vue.renderSlot(_ctx.$slots, "default", {}, void 0, true)
25
25
  ], 2);
26
26
  }
27
- const OptionsList = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-c8c0f83e"]]);
27
+ const OptionsList = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-b6878c99"]]);
28
28
  exports.default = OptionsList;
@@ -92,5 +92,5 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
92
92
  _ctx.badge ? (vue.openBlock(), vue.createElementBlock("sup", _hoisted_3)) : vue.createCommentVNode("", true)
93
93
  ], 42, _hoisted_1);
94
94
  }
95
- const OptionsListItem = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-ace81497"]]);
95
+ const OptionsListItem = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-e3f033e2"]]);
96
96
  exports.default = OptionsListItem;
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
- const vue = require("vue");
4
3
  const floatFormatter = require("../../mixins/floatFormatter.js");
5
4
  const elementPlus = require("element-plus");
5
+ const vue = require("vue");
6
6
  ;/* empty css */
7
7
  const _pluginVue_exportHelper = require("../../../_virtual/_plugin-vue_export-helper.js");
8
8
  const _sfc_main = vue.defineComponent({
@@ -60,18 +60,18 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
60
60
  !_ctx.removePrepend ? {
61
61
  name: "prepend",
62
62
  fn: vue.withCtx(() => [
63
- _cache[1] || (_cache[1] = vue.createTextVNode(" % "))
63
+ _cache[1] || (_cache[1] = vue.createTextVNode(" % ", -1))
64
64
  ]),
65
65
  key: "0"
66
66
  } : void 0,
67
67
  _ctx.showAppend ? {
68
68
  name: "append",
69
69
  fn: vue.withCtx(() => [
70
- _cache[2] || (_cache[2] = vue.createTextVNode(" % "))
70
+ _cache[2] || (_cache[2] = vue.createTextVNode(" % ", -1))
71
71
  ]),
72
72
  key: "1"
73
73
  } : void 0
74
74
  ]), 1040, ["id", "model-value", "maxlength", "onInput", "onChange"]);
75
75
  }
76
- const Percent = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-9d797852"]]);
76
+ const Percent = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-3ffa1372"]]);
77
77
  exports.default = Percent;
@@ -75,5 +75,5 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
75
75
  }), 128))
76
76
  ]);
77
77
  }
78
- const Skeleton = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-3fc0709e"]]);
78
+ const Skeleton = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-e17e8c84"]]);
79
79
  exports.default = Skeleton;
@@ -202,5 +202,5 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
202
202
  ])
203
203
  ], 6);
204
204
  }
205
- const Step = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-3c497fa9"]]);
205
+ const Step = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-903c296d"]]);
206
206
  exports.default = Step;
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
- const vue = require("vue");
4
3
  const elementPlus = require("element-plus");
4
+ const vue = require("vue");
5
5
  const _sfc_main = vue.defineComponent({
6
6
  name: "TpSteps",
7
7
  extends: elementPlus.ElSteps,
@@ -72,9 +72,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
72
72
  sm: 1,
73
73
  class: "icone"
74
74
  }, {
75
- default: vue.withCtx(() => _cache[2] || (_cache[2] = [
75
+ default: vue.withCtx(() => [..._cache[2] || (_cache[2] = [
76
76
  vue.createElementVNode("em", { class: "far fa-lightbulb-on" }, null, -1)
77
- ])),
77
+ ])]),
78
78
  _: 1
79
79
  }),
80
80
  vue.createVNode(_component_el_col, {
@@ -105,9 +105,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
105
105
  }, {
106
106
  default: vue.withCtx(() => [
107
107
  vue.createVNode(_component_el_row, { justify: "start" }, {
108
- default: vue.withCtx(() => _cache[3] || (_cache[3] = [
108
+ default: vue.withCtx(() => [..._cache[3] || (_cache[3] = [
109
109
  vue.createElementVNode("em", { class: "far fa-lightbulb-on" }, null, -1)
110
- ])),
110
+ ])]),
111
111
  _: 1
112
112
  })
113
113
  ]),
@@ -161,5 +161,5 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
161
161
  _: 1
162
162
  }, 8, ["id", "class"]));
163
163
  }
164
- const Tip = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-042c88f6"]]);
164
+ const Tip = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-0fd7bc4b"]]);
165
165
  exports.default = Tip;
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
- const vueI18n = require("vue-i18n");
4
3
  const vue = require("vue");
4
+ const vueI18n = require("vue-i18n");
5
5
  let i18n;
6
6
  const loadedLanguages = [];
7
7
  const i18nHelper = {
@@ -6,7 +6,6 @@ function setDefaults(app) {
6
6
  defaults = app.$i18n ? app.$i18n.t("locale.number") : ptBr.default.locale;
7
7
  }
8
8
  function formatMoney(input, toString = false, locale = defaults, customPrecision = false) {
9
- var _a, _b;
10
9
  let inputString = `${input}`;
11
10
  if (inputString.slice(-1).match(/[.,]/)) {
12
11
  inputString = inputString.substring(0, inputString.length - 1);
@@ -20,8 +19,8 @@ function formatMoney(input, toString = false, locale = defaults, customPrecision
20
19
  const currency = numbersToCurrency(numbers, precision);
21
20
  if (toString) {
22
21
  let num = negative === -1 ? `-${currency}` : `${currency}`;
23
- if ((_a = locale == null ? void 0 : locale.number) == null ? void 0 : _a.decimal) {
24
- const decimalChar = (_b = locale == null ? void 0 : locale.number) == null ? void 0 : _b.decimal;
22
+ if (locale?.number?.decimal) {
23
+ const decimalChar = locale?.number?.decimal;
25
24
  num = num.replaceAll(",", decimalChar).replaceAll(".", decimalChar);
26
25
  }
27
26
  return num;
@@ -29,9 +28,8 @@ function formatMoney(input, toString = false, locale = defaults, customPrecision
29
28
  return currency * negative;
30
29
  }
31
30
  function completeZeros(customPrecision, input, locale) {
32
- var _a, _b;
33
- const precision = customPrecision || ((_a = locale == null ? void 0 : locale.number) == null ? void 0 : _a.precision) || defaults.precision;
34
- const decimal = ((_b = locale == null ? void 0 : locale.number) == null ? void 0 : _b.decimal) || defaults.decimal;
31
+ const precision = customPrecision || locale?.number?.precision || defaults.precision;
32
+ const decimal = locale?.number?.decimal || defaults.decimal;
35
33
  let i = input.lastIndexOf(".");
36
34
  const j = input.lastIndexOf(",");
37
35
  i = i > j ? i : j;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const formContextKey = Symbol("formContextKey");
4
- const formItemContextKey = Symbol("formItemContextKey");
3
+ const formContextKey = /* @__PURE__ */ Symbol("formContextKey");
4
+ const formItemContextKey = /* @__PURE__ */ Symbol("formItemContextKey");
5
5
  exports.formContextKey = formContextKey;
6
6
  exports.formItemContextKey = formItemContextKey;
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const vue = require("vue");
4
3
  const lodashEs = require("lodash-es");
4
+ const vue = require("vue");
5
5
  const shared_esmBundler = require("../../node_modules/@vue/shared/dist/shared.esm-bundler.js");
6
6
  const epPropKey = "__epPropKey";
7
7
  const isEpProp = (val) => shared_esmBundler.isObject(val) && !!val[epPropKey];
@@ -16,9 +16,9 @@ const buildProp = (prop, key) => {
16
16
  if (shared_esmBundler.hasOwn(prop, "default")) {
17
17
  allowedValues.push(defaultValue);
18
18
  }
19
- valid || (valid = allowedValues.includes(val));
19
+ valid ||= allowedValues.includes(val);
20
20
  }
21
- if (validator) valid || (valid = validator(val));
21
+ if (validator) valid ||= validator(val);
22
22
  if (!valid && allowedValues.length > 0) {
23
23
  const allowValuesText = [...new Set(allowedValues)].map((value) => JSON.stringify(value)).join(", ");
24
24
  vue.warn(
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const vue = require("vue");
4
4
  const defaultNamespace = "el";
5
- const namespaceContextKey = Symbol("namespaceContextKey");
5
+ const namespaceContextKey = /* @__PURE__ */ Symbol("namespaceContextKey");
6
6
  const useGetDerivedNamespace = (namespaceOverrides) => {
7
7
  const derivedNamespace = vue.getCurrentInstance() ? vue.inject(namespaceContextKey, vue.ref(defaultNamespace)) : vue.ref(defaultNamespace);
8
8
  const namespace = vue.computed(() => {