toggle-components-library 1.25.24 → 1.25.26
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/toggle-components-library.common.js +80 -70
- package/dist/toggle-components-library.common.js.map +1 -1
- package/dist/toggle-components-library.css +1 -1
- package/dist/toggle-components-library.umd.js +80 -70
- package/dist/toggle-components-library.umd.js.map +1 -1
- package/dist/toggle-components-library.umd.min.js +1 -1
- package/dist/toggle-components-library.umd.min.js.map +1 -1
- package/package.json +1 -1
- package/src/components/forms/ToggleInputCheckbox.vue +2 -2
- package/src/components/forms/ToggleInputPercentage.vue +9 -1
- package/src/sass/includes/_as_inputs.scss +1 -1
package/package.json
CHANGED
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
<span class="toggle-input-checkbox-check-element "></span>
|
|
7
7
|
<span :class="[ 'toggle-input-checkbox-label', label_style ]" >{{label}}</span>
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
</div>
|
|
10
|
+
<img v-if="iconUrl" v-bind:src="iconUrl" :alt="iconAlt" class="toggle-input-checkbox-icon"/>
|
|
11
11
|
|
|
12
12
|
</label>
|
|
13
13
|
|
|
@@ -73,6 +73,10 @@ export default {
|
|
|
73
73
|
errorMessage: {
|
|
74
74
|
type: String,
|
|
75
75
|
required: false
|
|
76
|
+
},
|
|
77
|
+
allowFloat: {
|
|
78
|
+
type: Boolean,
|
|
79
|
+
default: false
|
|
76
80
|
}
|
|
77
81
|
},
|
|
78
82
|
|
|
@@ -108,7 +112,11 @@ export default {
|
|
|
108
112
|
// Recalculate value after ignoring "%" and "," in user input
|
|
109
113
|
let newValue = parseFloat(modifiedValue.replace(/[^\d.]/g, ""));
|
|
110
114
|
if(newValue)
|
|
111
|
-
|
|
115
|
+
if(this.allowFloat){
|
|
116
|
+
newValue = parseFloat(newValue);
|
|
117
|
+
} else {
|
|
118
|
+
newValue = parseInt(newValue);
|
|
119
|
+
}
|
|
112
120
|
else
|
|
113
121
|
newValue = 0;
|
|
114
122
|
|