ywana-core8 0.0.980 → 0.0.982
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.cjs +6 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.modern.js +6 -2
- package/dist/index.modern.js.map +1 -1
- package/dist/index.umd.js +6 -2
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/html/tokenfield.js +9 -2
package/dist/index.modern.js
CHANGED
@@ -2653,8 +2653,12 @@ var TokenField = function TokenField(_ref) {
|
|
2653
2653
|
setValue(value);
|
2654
2654
|
}
|
2655
2655
|
function changeDropDown(fid, value) {
|
2656
|
-
var
|
2657
|
-
|
2656
|
+
var isNumericValue = !isNaN(value);
|
2657
|
+
var valueIsNotEmpty = value && value.length > 0 || isNumericValue;
|
2658
|
+
if (valueIsNotEmpty) {
|
2659
|
+
var next = Array.isArray(tokens) ? tokens.concat(value) : [value];
|
2660
|
+
if (onChange) onChange(id, next);
|
2661
|
+
}
|
2658
2662
|
setValue('');
|
2659
2663
|
}
|
2660
2664
|
function onEnter(event) {
|