ps-toolkit-ui 1.15.20 → 1.15.21
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/bundles/ps-toolkit-ui.umd.js +4 -4
- package/bundles/ps-toolkit-ui.umd.js.map +1 -1
- package/bundles/ps-toolkit-ui.umd.min.js +1 -1
- package/bundles/ps-toolkit-ui.umd.min.js.map +1 -1
- package/esm2015/lib/components/form/tag/form.tag.component.js +5 -5
- package/fesm2015/ps-toolkit-ui.js +4 -4
- package/fesm2015/ps-toolkit-ui.js.map +1 -1
- package/package.json +1 -1
|
@@ -8212,7 +8212,7 @@
|
|
|
8212
8212
|
FormTagComponent.prototype.ngOnInit = function () {
|
|
8213
8213
|
var _this = this;
|
|
8214
8214
|
this.inp.setValue = function (v) {
|
|
8215
|
-
_this.inp.value = v != null ? v instanceof Array ? v : v.toString().split(/[,
|
|
8215
|
+
_this.inp.value = v != null ? v instanceof Array ? v : v.toString().split(/[,]/).filter(function (x) { return x !== ''; }) : [];
|
|
8216
8216
|
};
|
|
8217
8217
|
this.inp.focus = function (changeIndex) {
|
|
8218
8218
|
if (changeIndex === void 0) { changeIndex = false; }
|
|
@@ -8261,14 +8261,14 @@
|
|
|
8261
8261
|
if (code === 9) {
|
|
8262
8262
|
e.preventDefault();
|
|
8263
8263
|
if (v.val() !== '') {
|
|
8264
|
-
this.inp.value = this.inp.value.concat(v.val().toString().split(/[,
|
|
8264
|
+
this.inp.value = this.inp.value.concat(v.val().toString().split(/[,]/).filter(function (x) { return x !== '' && !_this.inp.value.includes(x); }));
|
|
8265
8265
|
v.val('');
|
|
8266
8266
|
}
|
|
8267
8267
|
this.changeIndex.emit(code === 9 ? e.shiftKey ? 'ShiftTab' : 'Tab' : e.shiftKey ? 'ShiftEnter' : 'Enter');
|
|
8268
8268
|
}
|
|
8269
8269
|
else if (code === 13) {
|
|
8270
8270
|
if (v.val() !== '') {
|
|
8271
|
-
this.inp.value = this.inp.value.concat(v.val().toString().split(/[,
|
|
8271
|
+
this.inp.value = this.inp.value.concat(v.val().toString().split(/[,]/).filter(function (x) { return x !== '' && !_this.inp.value.includes(x); }));
|
|
8272
8272
|
v.val('');
|
|
8273
8273
|
}
|
|
8274
8274
|
}
|
|
@@ -8283,7 +8283,7 @@
|
|
|
8283
8283
|
var _this = this;
|
|
8284
8284
|
var v = $__namespace(this.inputBase.nativeElement);
|
|
8285
8285
|
if (v.val() !== '') {
|
|
8286
|
-
this.inp.value = this.inp.value.concat(v.val().toString().split(/[,
|
|
8286
|
+
this.inp.value = this.inp.value.concat(v.val().toString().split(/[,]/).filter(function (x) { return x !== '' && !_this.inp.value.includes(x); }));
|
|
8287
8287
|
v.val('');
|
|
8288
8288
|
}
|
|
8289
8289
|
};
|