ps-toolkit-ui 1.6.48 → 1.6.53

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.
@@ -9,6 +9,7 @@ export { ChartComponent as ɵn } from './lib/components/chart/chart.component';
9
9
  export { ClockComponent as ɵm } from './lib/components/clock/clock.component';
10
10
  export { FormHiddenComponent as ɵk } from './lib/components/form/hidden/form.hidden.component';
11
11
  export { FormSelectItemComponent as ɵa } from './lib/components/form/select/item/form.select.item.component';
12
+ export { FormTagComponent as ɵp } from './lib/components/form/tag/form.tag.component';
12
13
  export { FormTreeItemComponent as ɵf } from './lib/components/form/tree/item/form.tree.item.component';
13
14
  export { LoginComponent as ɵi } from './lib/components/login/login.component';
14
15
  export { NotificationComponent as ɵj } from './lib/components/notification/notification.component';
@@ -17,4 +18,4 @@ export { TableLoadingComponent as ɵe } from './lib/components/table/loading/tab
17
18
  export { TablePaginationComponent as ɵb } from './lib/components/table/pagination/table.pagination.component';
18
19
  export { TableRowComponent as ɵg } from './lib/components/table/row/table.row.component';
19
20
  export { PsToolkitUiConfigService as ɵd } from './lib/services/config.service';
20
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHMtdG9vbGtpdC11aS5qcyIsInNvdXJjZVJvb3QiOiJEOi9Qcm9qZWN0cy9Qc1Rvb2xraXQvVUkvcHJvamVjdHMvcHMtdG9vbGtpdC11aS9zcmMvIiwic291cmNlcyI6WyJwcy10b29sa2l0LXVpLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYyxjQUFjLENBQUM7QUFFN0IsT0FBTyxFQUFDLFlBQVksSUFBSSxFQUFFLEVBQUMsTUFBTSw4QkFBOEIsQ0FBQztBQUNoRSxPQUFPLEVBQUMsYUFBYSxJQUFJLEVBQUUsRUFBQyxNQUFNLCtCQUErQixDQUFDO0FBQ2xFLE9BQU8sRUFBQyxpQkFBaUI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rm9ybVRyZWVJdGVtQ29tcG9uZW50IGFzIMm1Zn0gZnJvbSAnLi9saWIvY29tcG9uZW50cy9mb3JtL3RyZWUvaXRlbS9mb3JtLnRyZWUuaXRlbS5jb21wb25lbnQnO1xuZXhwb3J0IHtMb2dpbkNvbXBvbmVudCBhcyDJtWl9IGZyb20gJy4vbGliL2NvbXBvbmVudHMvbG9naW4vbG9naW4uY29tcG9uZW50JztcbmV4cG9ydCB7Tm90aWZpY2F0aW9uQ29tcG9uZW50IGFzIMm1an0gZnJvbSAnLi9saWIvY29tcG9uZW50cy9ub3RpZmljYXRpb24vbm90aWZpY2F0aW9uLmNvbXBvbmVudCc7XG5leHBvcnQge1NpZGViYXJJdGVtQ29tcG9uZW50IGFzIMm1Y30gZnJvbSAnLi9saWIvY29tcG9uZW50cy9zaWRlYmFyL2l0ZW0vc2lkZWJhci5pdGVtLmNvbXBvbmVudCc7XG5leHBvcnQge1RhYmxlTG9hZGluZ0NvbXBvbmVudCBhcyDJtWV9IGZyb20gJy4vbGliL2NvbXBvbmVudHMvdGFibGUvbG9hZGluZy90YWJsZS5sb2FkaW5nLmNvbXBvbmVudCc7XG5leHBvcnQge1RhYmxlUGFnaW5hdGlvbkNvbXBvbmVudCBhcyDJtWJ9IGZyb20gJy4vbGliL2NvbXBvbmVudHMvdGFibGUvcGFnaW5hdGlvbi90YWJsZS5wYWdpbmF0aW9uLmNvbXBvbmVudCc7XG5leHBvcnQge1RhYmxlUm93Q29tcG9uZW50IGFzIMm1Z30gZnJvbSAnLi9saWIvY29tcG9uZW50cy90YWJsZS9yb3cvdGFibGUucm93LmNvbXBvbmVudCc7XG5leHBvcnQge1BzVG9vbGtpdFVpQ29uZmlnU2VydmljZSBhcyDJtWR9IGZyb20gJy4vbGliL3NlcnZpY2VzL2NvbmZpZy5zZXJ2aWNlJzsiXX0=
@@ -424,12 +424,13 @@ var InputType;
424
424
  InputType[InputType["Constant"] = 34] = "Constant";
425
425
  InputType[InputType["Hidden"] = 35] = "Hidden";
426
426
  InputType[InputType["Table"] = 36] = "Table";
427
- InputType[InputType["CarSearch"] = 37] = "CarSearch";
428
- InputType[InputType["Car"] = 38] = "Car";
429
- InputType[InputType["Finger"] = 39] = "Finger";
430
- InputType[InputType["Color"] = 40] = "Color";
431
- InputType[InputType["Star"] = 41] = "Star";
432
- InputType[InputType["BillNumber"] = 42] = "BillNumber";
427
+ InputType[InputType["Tag"] = 37] = "Tag";
428
+ InputType[InputType["CarSearch"] = 38] = "CarSearch";
429
+ InputType[InputType["Car"] = 39] = "Car";
430
+ InputType[InputType["Finger"] = 40] = "Finger";
431
+ InputType[InputType["Color"] = 41] = "Color";
432
+ InputType[InputType["Star"] = 42] = "Star";
433
+ InputType[InputType["BillNumber"] = 43] = "BillNumber";
433
434
  })(InputType || (InputType = {}));
434
435
  var OperationEnum;
435
436
  (function (OperationEnum) {
@@ -1425,7 +1426,7 @@ class InputClass {
1425
1426
  InputType.NationalCode, InputType.Sheba, InputType.PostalCode, InputType.Date, InputType.Time, InputType.BillNumber].includes(type) ? ' ltr' : '');
1426
1427
  this.type = type;
1427
1428
  this.value = value;
1428
- this.default = value == null ? null : (typeof value === 'number' ? cloneDeep(value) : HelperClass.clone(value));
1429
+ this.default = value == null ? null : (typeof value === 'number' || typeof value === 'string' ? cloneDeep(value) : HelperClass.clone(value));
1429
1430
  this.baseRequired = required;
1430
1431
  this.required = required;
1431
1432
  this.inEditRequired = required;
@@ -3577,7 +3578,7 @@ class FormComponent {
3577
3578
  FormComponent.decorators = [
3578
3579
  { type: Component, args: [{
3579
3580
  selector: 'lib-form',
3580
- template: "<form [style]=\"form.style\" *ngIf=\"form\" [id]=\"form.id + 'Form'\" [className]=\"'form' + (form.class ? ' ' + form.class : '')\">\r\n <div *ngIf=\"form.displayLabel\" [className]=\"(form.subName ? '' : 'underline ') + 'title'\">{{this.form.l(this.form.name)}}</div>\r\n <div *ngIf=\"form.displayLabel && form.subName\" class=\"sub-title underline\">{{this.form.l(this.form.subName)}}</div>\r\n <div *ngIf=\"form.loading\" class=\"loading\">\r\n <div class=\"text\" [innerHTML]=\"form.l('LoadingTable', 'Processing')\"></div>\r\n </div>\r\n <div *ngIf=\"!form.permission\" class=\"loading\">\r\n <div class=\"text\"><i class=\"fas fa-shield-alt icon\"></i>{{ form.l(\"PermissionDenied\") }}</div>\r\n </div>\r\n <div class=\"inputs\">\r\n <span *ngFor=\"let inp of form.inputs; let i = index\">\r\n <lib-form-textbox (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.Text || inp.type == type.Password || inp.type == type.Mobile || inp.type == type.Phone || inp.type == type.Email || inp.type == type.NationalCode || inp.type == type.Number || inp.type == type.Url || inp.type == type.PostalCode || inp.type == type.Price || inp.type == type.Sheba || inp.type == type.Color || inp.type == type.BillNumber)\" [inp]=\"inp\"></lib-form-textbox>\r\n <lib-form-textarea (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.TextArea\" [inp]=\"inp\"></lib-form-textarea>\r\n <lib-form-checkbox (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Check\" [inp]=\"inp\"></lib-form-checkbox>\r\n <lib-form-select [inForm]=\"true\" (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.Select || inp.type == type.SelectSearch || inp.type == type.SelectAutoComplete)\" [inp]=\"inp\"></lib-form-select>\r\n <lib-form-date [inForm]=\"true\" (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Date\" [inp]=\"inp\"></lib-form-date>\r\n <lib-form-time [inForm]=\"true\" (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Time\" [inp]=\"inp\"></lib-form-time>\r\n <lib-form-datetime [inForm]=\"true\" (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.DateTime\" [inp]=\"inp\"></lib-form-datetime>\r\n <lib-form-label *ngIf=\"inp.visible && inp.type == type.Label\" [inp]=\"inp\"></lib-form-label>\r\n <lib-form-file (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.File\" [inp]=\"inp\"></lib-form-file>\r\n <lib-form-button (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.Button || inp.type == type.Submit)\" [inp]=\"inp\"></lib-form-button>\r\n <lib-form-icon (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Icon\" [inp]=\"inp\"></lib-form-icon>\r\n <lib-form-radio (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Radio\" [inp]=\"inp\"></lib-form-radio>\r\n <lib-form-tree (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.Tree || inp.type == type.TreeRadio)\" [inp]=\"inp\"></lib-form-tree>\r\n <lib-form-plaque (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.Plaque || inp.type == type.PlaqueM || inp.type == type.PlaqueF)\" [inp]=\"inp\"></lib-form-plaque>\r\n <lib-form-plaque-select (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.SelectAutoCompletePlaque || inp.type == type.SelectAutoCompletePlaqueM || inp.type == type.SelectAutoCompletePlaqueF)\" [inp]=\"inp\"></lib-form-plaque-select>\r\n <lib-form-bank-card (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.BankCard\" [inp]=\"inp\"></lib-form-bank-card>\r\n <lib-form-car-search (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.CarSearch\" [inp]=\"inp\"></lib-form-car-search>\r\n <lib-form-car (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Car\" [inp]=\"inp\"></lib-form-car>\r\n <lib-form-finger (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Finger\" [inp]=\"inp\"></lib-form-finger>\r\n <lib-form-star (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Star\" [inp]=\"inp\"></lib-form-star>\r\n <lib-form-table *ngIf=\"inp.visible && inp.type == type.Table\" [inp]=\"inp\"></lib-form-table>\r\n <lib-form-hidden *ngIf=\"inp.type == type.Hidden\" [inp]=\"inp\"></lib-form-hidden>\r\n </span>\r\n </div>\r\n</form>\r\n",
3581
+ template: "<form [style]=\"form.style\" *ngIf=\"form\" [id]=\"form.id + 'Form'\" [className]=\"'form' + (form.class ? ' ' + form.class : '')\">\r\n <div *ngIf=\"form.displayLabel\" [className]=\"(form.subName ? '' : 'underline ') + 'title'\">{{this.form.l(this.form.name)}}</div>\r\n <div *ngIf=\"form.displayLabel && form.subName\" class=\"sub-title underline\">{{this.form.l(this.form.subName)}}</div>\r\n <div *ngIf=\"form.loading\" class=\"loading\">\r\n <div class=\"text\" [innerHTML]=\"form.l('LoadingTable', 'Processing')\"></div>\r\n </div>\r\n <div *ngIf=\"!form.permission\" class=\"loading\">\r\n <div class=\"text\"><i class=\"fas fa-shield-alt icon\"></i>{{ form.l(\"PermissionDenied\") }}</div>\r\n </div>\r\n <div class=\"inputs\">\r\n <span *ngFor=\"let inp of form.inputs; let i = index\">\r\n <lib-form-textbox (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.Text || inp.type == type.Password || inp.type == type.Mobile || inp.type == type.Phone || inp.type == type.Email || inp.type == type.NationalCode || inp.type == type.Number || inp.type == type.Url || inp.type == type.PostalCode || inp.type == type.Price || inp.type == type.Sheba || inp.type == type.Color || inp.type == type.BillNumber)\" [inp]=\"inp\"></lib-form-textbox>\r\n <lib-form-textarea (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.TextArea\" [inp]=\"inp\"></lib-form-textarea>\r\n <lib-form-checkbox (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Check\" [inp]=\"inp\"></lib-form-checkbox>\r\n <lib-form-select [inForm]=\"true\" (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.Select || inp.type == type.SelectSearch || inp.type == type.SelectAutoComplete)\" [inp]=\"inp\"></lib-form-select>\r\n <lib-form-date [inForm]=\"true\" (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Date\" [inp]=\"inp\"></lib-form-date>\r\n <lib-form-time [inForm]=\"true\" (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Time\" [inp]=\"inp\"></lib-form-time>\r\n <lib-form-datetime [inForm]=\"true\" (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.DateTime\" [inp]=\"inp\"></lib-form-datetime>\r\n <lib-form-label *ngIf=\"inp.visible && inp.type == type.Label\" [inp]=\"inp\"></lib-form-label>\r\n <lib-form-file (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.File\" [inp]=\"inp\"></lib-form-file>\r\n <lib-form-button (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.Button || inp.type == type.Submit)\" [inp]=\"inp\"></lib-form-button>\r\n <lib-form-icon (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Icon\" [inp]=\"inp\"></lib-form-icon>\r\n <lib-form-radio (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Radio\" [inp]=\"inp\"></lib-form-radio>\r\n <lib-form-tree (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.Tree || inp.type == type.TreeRadio)\" [inp]=\"inp\"></lib-form-tree>\r\n <lib-form-plaque (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.Plaque || inp.type == type.PlaqueM || inp.type == type.PlaqueF)\" [inp]=\"inp\"></lib-form-plaque>\r\n <lib-form-plaque-select (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && (inp.type == type.SelectAutoCompletePlaque || inp.type == type.SelectAutoCompletePlaqueM || inp.type == type.SelectAutoCompletePlaqueF)\" [inp]=\"inp\"></lib-form-plaque-select>\r\n <lib-form-bank-card (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.BankCard\" [inp]=\"inp\"></lib-form-bank-card>\r\n <lib-form-car-search (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.CarSearch\" [inp]=\"inp\"></lib-form-car-search>\r\n <lib-form-car (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Car\" [inp]=\"inp\"></lib-form-car>\r\n <lib-form-finger (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Finger\" [inp]=\"inp\"></lib-form-finger>\r\n <lib-form-star (changeIndex)=\"changeIndex(i, $event)\" *ngIf=\"inp.visible && inp.type == type.Star\" [inp]=\"inp\"></lib-form-star>\r\n <lib-form-table *ngIf=\"inp.visible && inp.type == type.Table\" [inp]=\"inp\"></lib-form-table>\r\n <lib-form-tag *ngIf=\"inp.visible && inp.type == type.Tag\" [inp]=\"inp\"></lib-form-tag>\r\n <lib-form-hidden *ngIf=\"inp.type == type.Hidden\" [inp]=\"inp\"></lib-form-hidden>\r\n </span>\r\n </div>\r\n</form>\r\n",
3581
3582
  styles: [".form{border-radius:var(--border-radius-base);float:right;padding:20px;position:relative;width:100%}.form>.title{font-family:VazirBold;font-size:16px;height:40px}.form>.sub-title,.form>.title{float:right;line-height:30px;margin-bottom:10px;position:relative;text-align:right;width:100%}.form>.sub-title{color:var(--black-light);font-family:VazirLight;font-size:12px;height:30px}.form .loading{background-color:#fff;border-radius:var(--border-radius-base);height:100%;right:0;top:0;z-index:4}.form .loading,.form .loading .text{position:absolute;text-align:center;width:100%}.form .loading .text{font-family:VazirBold;height:35px;line-height:35px;top:calc(50% - 20px)}::ng-deep .form .loading .icon{font-size:20px!important;line-height:30px;margin-left:5px;position:relative;top:5px}.form-buttons,.form-error{float:right;width:100%}.form-error{color:var(--red-light);font-size:11px;height:15px;line-height:8px;margin-top:10px;padding:0 10px;position:relative;text-align:center}.form-error .message{float:left;width:calc(100% - 40px)}.form-error .icon{float:right;height:20px;line-height:6px;right:0;top:0;width:40px}.form .inputs{margin:0 -15px}"]
3582
3583
  },] }
3583
3584
  ];
@@ -6488,6 +6489,90 @@ FormStarComponent.propDecorators = {
6488
6489
  inputBase: [{ type: ViewChild, args: ['inputBase',] }]
6489
6490
  };
6490
6491
 
6492
+ class FormTagComponent {
6493
+ constructor() {
6494
+ this.cValue = '';
6495
+ this.changeIndex = new EventEmitter();
6496
+ }
6497
+ ngOnInit() {
6498
+ this.inp.setValue = (v) => {
6499
+ this.inp.value = v != null ? v instanceof Array ? v : v.toString().split(/[, ]/).filter(x => x !== '') : [];
6500
+ };
6501
+ this.inp.focus = (changeIndex = false) => {
6502
+ this.onFocusIn(changeIndex);
6503
+ };
6504
+ this.inp.isValid = () => {
6505
+ this.inp.error = null;
6506
+ if (this.inp.required && this.inp.value.length === 0) {
6507
+ this.inp.error = InputError.Required;
6508
+ return false;
6509
+ }
6510
+ if (!this.inp.required && this.inp.value.length === 0) {
6511
+ return true;
6512
+ }
6513
+ if (this.inp.allowed !== null && this.inp.value.map(x => RegExp(this.inp.allowed === InputType.BillNumber ? /^\d+(\/\d+)*$/ : '').test(x)).some(x => x === false)) {
6514
+ this.inp.error = InputError.Invalid;
6515
+ return false;
6516
+ }
6517
+ return true;
6518
+ };
6519
+ this.inp.clear = () => {
6520
+ this.inp.error = null;
6521
+ this.inp.setValue(this.inp.default, false);
6522
+ };
6523
+ this.inp.data = () => {
6524
+ return this.inp.value;
6525
+ };
6526
+ this.inp.setValue(this.inp.default, false);
6527
+ }
6528
+ onFocusIn(changeIndex = false) {
6529
+ if (changeIndex) {
6530
+ this.inputBase.nativeElement.select();
6531
+ }
6532
+ else {
6533
+ this.inputBase.nativeElement.focus();
6534
+ }
6535
+ }
6536
+ onKeyDown(e) {
6537
+ if (this.inp.onKeyDown) {
6538
+ this.inp.onKeyDown(e);
6539
+ }
6540
+ const code = e.keyCode || e.which;
6541
+ if (code === 9) {
6542
+ e.preventDefault();
6543
+ this.changeIndex.emit(code === 9 ? e.shiftKey ? 'ShiftTab' : 'Tab' : e.shiftKey ? 'ShiftEnter' : 'Enter');
6544
+ }
6545
+ else if (code === 13) {
6546
+ const v = $$1(this.inputBase.nativeElement);
6547
+ if (v.val() !== '') {
6548
+ this.inp.value = this.inp.value.concat(v.val().toString().split(/[, ]/).filter(x => x !== '' && !this.inp.value.includes(x)));
6549
+ }
6550
+ v.val('');
6551
+ }
6552
+ else if (code === 8) {
6553
+ this.inp.value.pop();
6554
+ }
6555
+ this.inp.error = null;
6556
+ }
6557
+ removeTag(t) {
6558
+ this.inp.value = this.inp.value.filter(x => x !== t);
6559
+ }
6560
+ }
6561
+ FormTagComponent.decorators = [
6562
+ { type: Component, args: [{
6563
+ selector: 'lib-form-tag',
6564
+ template: "<div #inputDiv [id]=\"inp.id + 'TextInput'\" [style]=\"inp.style\" [className]=\"'form-input-con tag w-100' + (inp.error == null ? '' : ' error') + (inp.disabled || inp.loading ? ' disabled' : '') + (inp.icon == null ? ' without-icon' : '') + ' ' + inp.class\">\r\n <div class=\"form-input\" (click)=\"onFocusIn()\">\r\n <div *ngIf=\"inp.displayLabel\" class=\"label\"><i *ngIf=\"inp.required\" class=\"fas fa-star-of-life required-icon\"></i>{{inp.getLabel()}}</div>\r\n <div class=\"control\">\r\n <div class=\"tag\" *ngFor=\"let t of inp.value\"><i (click)=\"removeTag(t)\" class=\"fas fa-times\"></i><span>{{t}}</span></div>\r\n <input (keydown)=\"onKeyDown($event)\" [disabled]=\"inp.disabled || inp.loading\" [placeholder]=\"inp.placeholder ? inp.l(inp.placeholder) : ''\" #inputBase type=\"text\" autocomplete=\"off\">\r\n </div>\r\n <i *ngIf=\"inp.icon != null || inp.loading\" #inputIcon [className]=\"(inp.loading ? 'fa-duotone fa-spin fa-spinner' : inp.icon) + ' icon'\"></i>\r\n </div>\r\n</div>\r\n",
6565
+ styles: [".form-input-con.tag{padding:0 15px;position:relative}.form-input-con.tag .form-input{float:right;position:relative;width:100%}.form-input-con.tag .form-input .label{-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;-webkit-user-select:none;cursor:default;direction:rtl;float:right;font-size:12px;height:20px;line-height:20px;margin-bottom:3px;padding:0 10px;text-align:right;width:100%}.form-input-con.tag.error .form-input .label{color:var(--red);font-size:10px}.form-input-con.tag .form-input .label .required-icon{color:var(--red);font-size:9px;height:20px;line-height:20px;text-align:center;width:20px}.form-input-con.tag .form-input .control{align-items:center;background-color:#fff;border:var(--border-input);border-radius:var(--border-radius-base);cursor:text;display:flex;flex-flow:wrap;float:right;justify-content:center;min-height:35px;position:relative;width:100%;z-index:2}.form-input-con.tag .form-input .control input{background-image:none;border:unset;color:var(--black);float:right;font-family:Vazir;font-size:11px;height:25px;margin:5px;outline:none;padding:5px;position:relative;text-align:center;width:100px}.form-input-con.tag .form-input .control .tag{background-color:var(--primary);border-radius:var(--border-radius-base);color:var(--white);cursor:default;float:right;margin:5px;overflow:hidden}.form-input-con.tag .form-input .control .tag span{float:right;font-size:12px;height:25px;line-height:25px;padding:0 5px}.form-input-con.tag .form-input .control .tag i{cursor:pointer;float:right;height:25px;line-height:25px;text-align:center;width:20px}.form-input-con.tag .form-input .control .tag i:hover{background-color:var(--blue-dark)}.form-input-con.tag .form-input .control:focus,.form-input-con.tag .form-input:hover .control{border:var(--border-input-dark);outline:none}.form-input-con.tag.error .form-input .control{border:var(--border-input-red)}.form-input-con.tag.error .form-input .control,.form-input-con.tag.error .form-input i.icon{color:var(--red)}.form-input-con.tag.error .form-input .control:focus,.form-input-con.tag.error .form-input:hover .control{border:var(--border-input-red-dark)}.form-input-con.tag .form-input i.icon{color:var(--primary);cursor:text;left:0}.form-input-con.tag .form-input i.icon,.form-input-con.tag .form-input span.clear-icon{bottom:0;font-size:14px;height:35px;line-height:38px;position:absolute;text-align:center;transition:all .35s ease-in-out;width:35px;z-index:2}.form-input-con.tag .form-input span.clear-icon{color:var(--red);cursor:pointer;right:0}.form-input-con.tag.disabled .form-input .control,.form-input-con.tag.disabled .form-input .label,.form-input-con.tag.disabled .form-input i.icon{-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;-webkit-user-select:none;box-shadow:unset;cursor:default;filter:blur(.5px);opacity:.7}.form-input-con.tag .form-input .progress{background-color:var(--primary);border-radius:var(--border-radius-base);bottom:-3px;height:10px;line-height:10px;margin-right:0;position:absolute;right:0;transition:width .5s ease-in-out;width:100%}.form-input-con.tag.h-50 .form-input .control{height:50px}.form-input-con.tag.h-50 .form-input i.icon{height:50px;line-height:50px}.form-input-con.tag.h-45 .form-input .control{font-size:17px;height:45px}.form-input-con.tag.h-45 .form-input .control::-moz-placeholder,.form-input-con.tag.h-45 .form-input .control::-webkit-input-placeholder{font-size:12px}.form-input-con.tag.h-45 .form-input i.icon{font-size:15px;height:45px;line-height:50px}.form-input-con.tag.h-30 .form-input .control{font-size:10px;height:30px;padding:0}.form-input-con.tag.h-30 .form-input i.icon{font-size:11px;height:30px;line-height:33px;width:30px}.form-input-con.tag.h-35{height:35px}.form-input-con.tag.h-35 .form-input .control{height:35px;padding:0 35px}.form-input-con.tag.h-35 .form-input i.icon{height:35px;line-height:35px}.form-input-con.tag.h-25 .form-input .control{height:25px;padding:0}.form-input-con.tag.h-25 .form-input i.icon{height:25px;line-height:25px}.form-input-con.tag.h-25 .form-input .control::-moz-placeholder,.form-input-con.tag.h-25 .form-input .control::-webkit-input-placeholder{font-family:VazirLight;font-size:10px}"]
6566
+ },] }
6567
+ ];
6568
+ FormTagComponent.propDecorators = {
6569
+ inp: [{ type: Input }],
6570
+ changeIndex: [{ type: Output }],
6571
+ inputBase: [{ type: ViewChild, args: ['inputBase',] }],
6572
+ inputDiv: [{ type: ViewChild, args: ['inputDiv',] }],
6573
+ inputLabel: [{ type: ViewChild, args: ['inputLabel',] }]
6574
+ };
6575
+
6491
6576
  class PsToolkitUiModule {
6492
6577
  static forRoot(config) {
6493
6578
  return {
@@ -6508,7 +6593,7 @@ PsToolkitUiModule.decorators = [
6508
6593
  TooltipComponent, ConfirmComponent, TableComponent, ModalComponent, FormComponent, TableRowComponent, FormTreeComponent, AlertComponent,
6509
6594
  FormTimeComponent, NotfoundComponent, FormFingerComponent, FormCarSearchComponent, FormCarComponent, FormStarComponent,
6510
6595
  SafeStylePipe, LoginComponent, LoadingComponent, NotificationComponent, LayoutComponent, FormHiddenComponent, CalendarComponent,
6511
- ClockComponent, ChartComponent, SafeHtmlPipe
6596
+ ClockComponent, ChartComponent, SafeHtmlPipe, FormTagComponent
6512
6597
  ],
6513
6598
  imports: [
6514
6599
  CommonModule,
@@ -6524,7 +6609,7 @@ PsToolkitUiModule.decorators = [
6524
6609
  TooltipComponent, ConfirmComponent, TableComponent, ModalComponent, FormComponent, TableRowComponent, FormTreeComponent, AlertComponent,
6525
6610
  FormTimeComponent, NotfoundComponent, FormFingerComponent, FormCarSearchComponent, FormCarComponent, FormStarComponent,
6526
6611
  LoginComponent, LoadingComponent, NotificationComponent, LayoutComponent, FormHiddenComponent, CalendarComponent,
6527
- ClockComponent, ChartComponent
6612
+ ClockComponent, ChartComponent, FormTagComponent
6528
6613
  ]
6529
6614
  },] }
6530
6615
  ];
@@ -6971,5 +7056,5 @@ class CurrentDataClass {
6971
7056
  * Generated bundle index. Do not edit.
6972
7057
  */
6973
7058
 
6974
- export { AccordionClass, AccordionComponent, AccordionRowClass, AlertComponent, BaseComponent, ChartClass, ConfirmComponent, CurrentDataClass, DayClass, EnumUtils, FooterComponent, FormBankCardComponent, FormButtonComponent, FormCarComponent, FormCarSearchComponent, FormCheckboxComponent, FormClass, FormComponent, FormDateComponent, FormDatetimeComponent, FormFileComponent, FormFingerComponent, FormIconComponent, FormLabelComponent, FormPlaqueComponent, FormPlaqueSelectComponent, FormRadioComponent, FormSelectComponent, FormStarComponent, FormTableComponent, FormTextareaComponent, FormTextboxComponent, FormTimeComponent, FormTreeComponent, HeaderComponent, HelperClass, InputClass, InputError, InputType, LangClass, LayoutComponent, LoadingComponent, LoginClass, LoginStepClass, Method, ModalClass, ModalComponent, NotfoundComponent, OperationEnum, OptionClass, PaymentStatusEnum, PermissionAccessTypeEnum, PermissionClass, PermissionInputActionEnum, PermissionInputTypeEnum, PermissionTypeEnum, Progress, PsToolkitUiModule, RequestClass, ResultStatusEnum, SidebarClass, SidebarComponent, StatusEnum, StepsClass, StepsComponent, StepsItemClass, SubHeaderComponent, TableClass, TableCollClass, TableCollType, TableComponent, TableOptionType, TableRowClass, TooltipComponent, TreeRowClass, UserType, VehicleType, FormSelectItemComponent as ɵa, TablePaginationComponent as ɵb, SidebarItemComponent as ɵc, PsToolkitUiConfigService as ɵd, TableLoadingComponent as ɵe, FormTreeItemComponent as ɵf, TableRowComponent as ɵg, SafeStylePipe as ɵh, LoginComponent as ɵi, NotificationComponent as ɵj, FormHiddenComponent as ɵk, CalendarComponent as ɵl, ClockComponent as ɵm, ChartComponent as ɵn, SafeHtmlPipe as ɵo };
7059
+ export { AccordionClass, AccordionComponent, AccordionRowClass, AlertComponent, BaseComponent, ChartClass, ConfirmComponent, CurrentDataClass, DayClass, EnumUtils, FooterComponent, FormBankCardComponent, FormButtonComponent, FormCarComponent, FormCarSearchComponent, FormCheckboxComponent, FormClass, FormComponent, FormDateComponent, FormDatetimeComponent, FormFileComponent, FormFingerComponent, FormIconComponent, FormLabelComponent, FormPlaqueComponent, FormPlaqueSelectComponent, FormRadioComponent, FormSelectComponent, FormStarComponent, FormTableComponent, FormTextareaComponent, FormTextboxComponent, FormTimeComponent, FormTreeComponent, HeaderComponent, HelperClass, InputClass, InputError, InputType, LangClass, LayoutComponent, LoadingComponent, LoginClass, LoginStepClass, Method, ModalClass, ModalComponent, NotfoundComponent, OperationEnum, OptionClass, PaymentStatusEnum, PermissionAccessTypeEnum, PermissionClass, PermissionInputActionEnum, PermissionInputTypeEnum, PermissionTypeEnum, Progress, PsToolkitUiModule, RequestClass, ResultStatusEnum, SidebarClass, SidebarComponent, StatusEnum, StepsClass, StepsComponent, StepsItemClass, SubHeaderComponent, TableClass, TableCollClass, TableCollType, TableComponent, TableOptionType, TableRowClass, TooltipComponent, TreeRowClass, UserType, VehicleType, FormSelectItemComponent as ɵa, TablePaginationComponent as ɵb, SidebarItemComponent as ɵc, PsToolkitUiConfigService as ɵd, TableLoadingComponent as ɵe, FormTreeItemComponent as ɵf, TableRowComponent as ɵg, SafeStylePipe as ɵh, LoginComponent as ɵi, NotificationComponent as ɵj, FormHiddenComponent as ɵk, CalendarComponent as ɵl, ClockComponent as ɵm, ChartComponent as ɵn, SafeHtmlPipe as ɵo, FormTagComponent as ɵp };
6975
7060
  //# sourceMappingURL=ps-toolkit-ui.js.map