vueless 0.0.768 → 0.0.769

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vueless",
3
- "version": "0.0.768",
3
+ "version": "0.0.769",
4
4
  "license": "MIT",
5
5
  "description": "Vue Styleless UI Component Library, powered by Tailwind CSS.",
6
6
  "keywords": [
@@ -68,7 +68,7 @@ onMounted(() => {
68
68
  });
69
69
 
70
70
  function onKeyup(event: KeyboardEvent) {
71
- const numberValue = rawValue.value ? parseFloat(rawValue.value) : "";
71
+ const numberValue = !Number.isNaN(parseFloat(rawValue.value)) ? parseFloat(rawValue.value) : "";
72
72
 
73
73
  localValue.value = props.valueType === "number" ? numberValue : rawValue.value || "";
74
74
 
@@ -107,7 +107,9 @@ export default function useFormatCurrency(
107
107
 
108
108
  if (value === minus) {
109
109
  formattedValue.value = minus;
110
- rawValue.value = minus;
110
+ rawValue.value = "";
111
+
112
+ return;
111
113
  }
112
114
 
113
115
  if (!value || value.startsWith(`${options.value.decimalSeparator}0`)) {