@datarailsshared/datarailsshared 1.5.570 → 1.5.574

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.
@@ -10,7 +10,7 @@ import * as i1$2 from '@angular/forms';
10
10
  import { NG_VALUE_ACCESSOR, FormBuilder, FormGroup, FormControl, FormsModule, ReactiveFormsModule } from '@angular/forms';
11
11
  import { Observable, BehaviorSubject, distinctUntilChanged, Subject, startWith, takeUntil, combineLatest, noop as noop$3, from, merge as merge$1, fromEvent, filter as filter$1, switchMap as switchMap$1, map as map$2, observeOn, asyncScheduler, withLatestFrom, first as first$1, interval, throwError, finalize as finalize$1, tap as tap$1, defer } from 'rxjs';
12
12
  import * as _ from 'lodash';
13
- import { cloneDeep, find, indexOf, reduce, isObject, isNil, map as map$1, isNumber, merge, forEach, some, orderBy, filter as filter$2, includes, pull, concat, isString, isBoolean } from 'lodash';
13
+ import { isNil, isObject, cloneDeep, find, indexOf, reduce, map as map$1, isNumber, merge, forEach, some, orderBy, filter as filter$2, includes, pull, concat, isString, isBoolean } from 'lodash';
14
14
  import { skip, takeUntil as takeUntil$1, startWith as startWith$1, distinctUntilChanged as distinctUntilChanged$1, map, tap, shareReplay, filter, debounceTime, switchMap, first, catchError, finalize, take } from 'rxjs/operators';
15
15
  import * as i5 from '@angular/material/datepicker';
16
16
  import { MatCalendar, DateRange, MAT_DATE_RANGE_SELECTION_STRATEGY, MatDatepickerModule } from '@angular/material/datepicker';
@@ -206,6 +206,32 @@ class DrSharedUtils {
206
206
  static { this.normalizeLineEndings = (str) => {
207
207
  return str ? str.replace(/\r\n|\r/g, '\n') : str;
208
208
  }; }
209
+ static { this.isLocalhost = () => window.location.hostname === 'localhost' || window.location.hostname === '127.0.0.1'; }
210
+ static { this.getRouteDataAttributeValue = (activatedRoute, attribute, defaultValue) => {
211
+ if (activatedRoute.snapshot.data.hasOwnProperty(attribute)) {
212
+ defaultValue = activatedRoute.snapshot.data[attribute];
213
+ }
214
+ if (activatedRoute?.children?.length) {
215
+ activatedRoute.children.forEach((child) => {
216
+ defaultValue = DrSharedUtils.getRouteDataAttributeValue(child, attribute, defaultValue);
217
+ });
218
+ }
219
+ return defaultValue;
220
+ }; }
221
+ static { this.getProperty = (value, key) => {
222
+ if (isNil(value) || !isObject(value)) {
223
+ return undefined;
224
+ }
225
+ const keys = key.split('.');
226
+ let result = value[keys.shift()];
227
+ for (const k of keys) {
228
+ if (isNil(result) || !isObject(result)) {
229
+ return undefined;
230
+ }
231
+ result = result[k];
232
+ }
233
+ return result;
234
+ }; }
209
235
  }
210
236
 
211
237
  class DrDatePickerService {
@@ -10208,15 +10234,11 @@ function DialogModalWrapperComponent_i_5_Template(rf, ctx) { if (rf & 1) {
10208
10234
  } }
10209
10235
  function DialogModalWrapperComponent_div_6_Template(rf, ctx) { if (rf & 1) {
10210
10236
  i0.ɵɵelementStart(0, "div", 11);
10211
- i0.ɵɵelementContainerStart(1);
10212
- i0.ɵɵtext(2);
10213
- i0.ɵɵelementContainerEnd();
10214
- i0.ɵɵelement(3, "span", 12, 13);
10237
+ i0.ɵɵelement(1, "span", 12, 13);
10215
10238
  i0.ɵɵelementEnd();
10216
10239
  } if (rf & 2) {
10217
10240
  const ctx_r2 = i0.ɵɵnextContext();
10218
- i0.ɵɵadvance(2);
10219
- i0.ɵɵtextInterpolate(ctx_r2.dialogData.content);
10241
+ i0.ɵɵproperty("innerHTML", ctx_r2.dialogData.content, i0.ɵɵsanitizeHtml);
10220
10242
  } }
10221
10243
  function DialogModalWrapperComponent_form_7_div_2_label_1_Template(rf, ctx) { if (rf & 1) {
10222
10244
  i0.ɵɵelementStart(0, "label", 25);
@@ -10480,7 +10502,7 @@ class DialogModalWrapperComponent {
10480
10502
  /** @nocollapse */ static { this.ɵfac = function DialogModalWrapperComponent_Factory(t) { return new (t || DialogModalWrapperComponent)(i0.ɵɵdirectiveInject(i1$6.MatLegacyDialogRef), i0.ɵɵdirectiveInject(MAT_LEGACY_DIALOG_DATA)); }; }
10481
10503
  /** @nocollapse */ static { this.ɵcmp = /** @pureOrBreakMyCode */ i0.ɵɵdefineComponent({ type: DialogModalWrapperComponent, selectors: [["dr-dialog-modal-wrapper"]], hostVars: 2, hostBindings: function DialogModalWrapperComponent_HostBindings(rf, ctx) { if (rf & 2) {
10482
10504
  i0.ɵɵclassMap(ctx.class);
10483
- } }, decls: 10, vars: 6, consts: [["header", "", 1, "header-dialog"], ["data-test", "modalTitle", 1, "title-dialog"], ["class", "title-dialog__icon", "data-test", "dialogTitleIcon", 3, "class", "click", 4, "ngIf"], [1, "title-dialog__text"], ["class", "dr-icon-exit icon-close", "data-test", "xBtn", 3, "click", 4, "ngIf"], ["class", "content-dialog", 4, "ngIf"], ["class", "dr-smart-from", 3, "formGroup", 4, "ngIf"], ["footer", "", 1, "footer-dialog"], ["class", "buttons-wrapper", 4, "ngIf"], ["data-test", "dialogTitleIcon", 1, "title-dialog__icon", 3, "click"], ["data-test", "xBtn", 1, "dr-icon-exit", "icon-close", 3, "click"], [1, "content-dialog"], [1, "content-anchor"], ["content", ""], [1, "dr-smart-from", 3, "formGroup"], ["class", "dr-smart-form_group", 3, "class", "ngStyle", 4, "ngFor", "ngForOf"], [1, "dr-smart-form_group", 3, "ngStyle"], ["class", "label p-0 d-flex align-items-center", 3, "ngClass", 4, "ngIf"], [1, "input-group", "p-0", 3, "ngClass"], [3, "searchable", "clearable", "formControlName", "bindLabel", "bindValue", "selectedItem", "items", "loading", "required", "placeholder", 4, "ngIf"], ["data-test", "modalInput", "class", "form-control", 3, "formControlName", "placeholder", 4, "ngIf"], [3, "formControlName", "format", "placeholder", 4, "ngIf"], [3, "formControlName", 4, "ngIf"], ["class", "form-field-error-alert", 4, "ngIf"], ["class", "form-error-alert", 4, "ngIf"], [1, "label", "p-0", "d-flex", "align-items-center", 3, "ngClass"], [3, "searchable", "clearable", "formControlName", "bindLabel", "bindValue", "selectedItem", "items", "loading", "required", "placeholder"], [4, "ngIf"], ["optionFooterTemplate", ""], [1, "dr-select-footer__btn", 3, "click"], [3, "class", 4, "ngIf"], ["data-test", "modalInput", 1, "form-control", 3, "formControlName", "placeholder"], [3, "formControlName", "format", "placeholder"], [3, "formControlName"], [1, "form-field-error-alert"], [1, "form-error-alert"], [1, "buttons-wrapper"], ["class", "buttons-wrapper--custom-btn", "data-test", "declineBtn", 3, "theme", "click", 4, "ngIf"], ["data-test", "modalCloseBtn", 3, "theme", "click", 4, "ngIf"], ["data-test", "modalAddBtn", 3, "theme", "isLoading", "disabled", "click", 4, "ngIf"], ["data-test", "declineBtn", 1, "buttons-wrapper--custom-btn", 3, "theme", "click"], ["data-test", "modalCloseBtn", 3, "theme", "click"], ["data-test", "modalAddBtn", 3, "theme", "isLoading", "disabled", "click"]], template: function DialogModalWrapperComponent_Template(rf, ctx) { if (rf & 1) {
10505
+ } }, decls: 10, vars: 6, consts: [["header", "", 1, "header-dialog"], ["data-test", "modalTitle", 1, "title-dialog"], ["class", "title-dialog__icon", "data-test", "dialogTitleIcon", 3, "class", "click", 4, "ngIf"], [1, "title-dialog__text"], ["class", "dr-icon-exit icon-close", "data-test", "xBtn", 3, "click", 4, "ngIf"], ["class", "content-dialog", 3, "innerHTML", 4, "ngIf"], ["class", "dr-smart-from", 3, "formGroup", 4, "ngIf"], ["footer", "", 1, "footer-dialog"], ["class", "buttons-wrapper", 4, "ngIf"], ["data-test", "dialogTitleIcon", 1, "title-dialog__icon", 3, "click"], ["data-test", "xBtn", 1, "dr-icon-exit", "icon-close", 3, "click"], [1, "content-dialog", 3, "innerHTML"], [1, "content-anchor"], ["content", ""], [1, "dr-smart-from", 3, "formGroup"], ["class", "dr-smart-form_group", 3, "class", "ngStyle", 4, "ngFor", "ngForOf"], [1, "dr-smart-form_group", 3, "ngStyle"], ["class", "label p-0 d-flex align-items-center", 3, "ngClass", 4, "ngIf"], [1, "input-group", "p-0", 3, "ngClass"], [3, "searchable", "clearable", "formControlName", "bindLabel", "bindValue", "selectedItem", "items", "loading", "required", "placeholder", 4, "ngIf"], ["data-test", "modalInput", "class", "form-control", 3, "formControlName", "placeholder", 4, "ngIf"], [3, "formControlName", "format", "placeholder", 4, "ngIf"], [3, "formControlName", 4, "ngIf"], ["class", "form-field-error-alert", 4, "ngIf"], ["class", "form-error-alert", 4, "ngIf"], [1, "label", "p-0", "d-flex", "align-items-center", 3, "ngClass"], [3, "searchable", "clearable", "formControlName", "bindLabel", "bindValue", "selectedItem", "items", "loading", "required", "placeholder"], [4, "ngIf"], ["optionFooterTemplate", ""], [1, "dr-select-footer__btn", 3, "click"], [3, "class", 4, "ngIf"], ["data-test", "modalInput", 1, "form-control", 3, "formControlName", "placeholder"], [3, "formControlName", "format", "placeholder"], [3, "formControlName"], [1, "form-field-error-alert"], [1, "form-error-alert"], [1, "buttons-wrapper"], ["class", "buttons-wrapper--custom-btn", "data-test", "declineBtn", 3, "theme", "click", 4, "ngIf"], ["data-test", "modalCloseBtn", 3, "theme", "click", 4, "ngIf"], ["data-test", "modalAddBtn", 3, "theme", "isLoading", "disabled", "click", 4, "ngIf"], ["data-test", "declineBtn", 1, "buttons-wrapper--custom-btn", 3, "theme", "click"], ["data-test", "modalCloseBtn", 3, "theme", "click"], ["data-test", "modalAddBtn", 3, "theme", "isLoading", "disabled", "click"]], template: function DialogModalWrapperComponent_Template(rf, ctx) { if (rf & 1) {
10484
10506
  i0.ɵɵelementStart(0, "div", 0)(1, "h1", 1);
10485
10507
  i0.ɵɵtemplate(2, DialogModalWrapperComponent_i_2_Template, 1, 2, "i", 2);
10486
10508
  i0.ɵɵelementStart(3, "span", 3);
@@ -10488,7 +10510,7 @@ class DialogModalWrapperComponent {
10488
10510
  i0.ɵɵelementEnd()();
10489
10511
  i0.ɵɵtemplate(5, DialogModalWrapperComponent_i_5_Template, 1, 0, "i", 4);
10490
10512
  i0.ɵɵelementEnd();
10491
- i0.ɵɵtemplate(6, DialogModalWrapperComponent_div_6_Template, 5, 1, "div", 5);
10513
+ i0.ɵɵtemplate(6, DialogModalWrapperComponent_div_6_Template, 3, 1, "div", 5);
10492
10514
  i0.ɵɵtemplate(7, DialogModalWrapperComponent_form_7_Template, 3, 4, "form", 6);
10493
10515
  i0.ɵɵelementStart(8, "div", 7);
10494
10516
  i0.ɵɵtemplate(9, DialogModalWrapperComponent_div_9_Template, 4, 3, "div", 8);
@@ -10510,7 +10532,7 @@ class DialogModalWrapperComponent {
10510
10532
  }
10511
10533
  (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(DialogModalWrapperComponent, [{
10512
10534
  type: Component,
10513
- args: [{ selector: 'dr-dialog-modal-wrapper', template: "<div header class=\"header-dialog\">\n <h1 class=\"title-dialog\" data-test=\"modalTitle\">\n <i\n *ngIf=\"dialogData.headerIconClass\"\n (click)=\"closeDialog()\"\n class=\"title-dialog__icon\"\n [class]=\"dialogData.headerIconClass\"\n data-test=\"dialogTitleIcon\"></i>\n <span class=\"title-dialog__text\">{{ dialogData.title }}</span>\n </h1>\n <i *ngIf=\"!dialogData.hideCloseBtn\" (click)=\"closeDialog()\" class=\"dr-icon-exit icon-close\" data-test=\"xBtn\"></i>\n</div>\n<div *ngIf=\"dialogData.content\" class=\"content-dialog\">\n <ng-container>{{ dialogData.content }}</ng-container>\n <span #content class=\"content-anchor\"></span>\n</div>\n<form *ngIf=\"dialogData.fields\" [formGroup]=\"form\" class=\"dr-smart-from\">\n <div [class]=\"dialogData.formWrapperClass || 'dr-smart-form_wrapper'\">\n <div\n *ngFor=\"let field of dialogData.fields\"\n class=\"dr-smart-form_group\"\n [class]=\"field.formGroupClass\"\n [ngStyle]=\"{ display: field.isLabelFullWidth ? 'block' : 'flex' }\">\n <label\n *ngIf=\"field.label && field.type !== dialogFieldType.CHECKBOX\"\n [ngClass]=\"field.isLabelFullWidth ? 'col-md-12 mb-2' : 'col-md-2'\"\n class=\"label p-0 d-flex align-items-center\"\n >{{ field.label }}</label\n >\n <div\n class=\"input-group p-0\"\n [ngClass]=\"{\n 'col-md-10': field.label && !field.isLabelFullWidth,\n 'col-md-12': !field.label || field.isLabelFullWidth\n }\">\n <dr-select\n *ngIf=\"field.type === dialogFieldType.SELECT\"\n [searchable]=\"dialogData.searchable\"\n [clearable]=\"dialogData.clearable\"\n [formControlName]=\"field.name\"\n [bindLabel]=\"field.bindLabel || null\"\n [bindValue]=\"field.bindValue || null\"\n [selectedItem]=\"field.default\"\n [items]=\"field.items || (field.items$ | async)\"\n [loading]=\"fieldsItemsLoading[field.name] | async\"\n [required]=\"true\"\n [placeholder]=\"field.placeholder\">\n <ng-template *ngIf=\"dialogData?.footerTemplateData\" #optionFooterTemplate let-item=\"item\" let-close=\"close\">\n <button (click)=\"footerAction(); close()\" class=\"dr-select-footer__btn\">\n <i *ngIf=\"dialogData.footerTemplateData.icon\" class=\"{{ dialogData.footerTemplateData.icon }}\"></i>\n {{ dialogData.footerTemplateData.label }}\n </button>\n </ng-template>\n </dr-select>\n <dr-input\n *ngIf=\"field.type === dialogFieldType.INPUT\"\n data-test=\"modalInput\"\n class=\"form-control\"\n [formControlName]=\"field.name\"\n [placeholder]=\"field.placeholder\"></dr-input>\n <dr-date-picker\n *ngIf=\"field.type === dialogFieldType.DATE_PICKER\"\n [formControlName]=\"field.name\"\n [format]=\"field.datePickerFormat\"\n [placeholder]=\"field.placeholder\"></dr-date-picker>\n <dr-checkbox *ngIf=\"field.type === dialogFieldType.CHECKBOX\" [formControlName]=\"field.name\">\n {{ field.label }}\n </dr-checkbox>\n <label\n class=\"form-field-error-alert\"\n *ngIf=\"form.invalid && form.controls[field.name]?.dirty && form.controls[field.name]?.errors\">\n {{ form.controls[field.name].errors.errorString }}\n </label>\n <label class=\"form-error-alert\" *ngIf=\"dialogData.errorMessage && !form.pristine && form.invalid\">\n {{ dialogData.errorMessage }}\n </label>\n <label class=\"form-error-alert\" *ngIf=\"form.valid && showServerErrorMessage && dialogData.serverErrorMessage\">\n {{ dialogData.serverErrorMessage }}\n </label>\n </div>\n </div>\n </div>\n</form>\n\n<div footer class=\"footer-dialog\">\n <div class=\"buttons-wrapper\" *ngIf=\"dialogData.cancelButton || dialogData.acceptButton\">\n <dr-button\n (click)=\"onDecline()\"\n *ngIf=\"dialogData.customButton\"\n [theme]=\"dialogData.customButton?.theme || 'secondary'\"\n class=\"buttons-wrapper--custom-btn\"\n data-test=\"declineBtn\"\n >{{ dialogData.customButton.label }}</dr-button\n >\n <dr-button *ngIf=\"dialogData.cancelButton\" data-test=\"modalCloseBtn\" (click)=\"closeDialog()\" [theme]=\"'secondary'\">{{\n dialogData.cancelButton.label\n }}</dr-button>\n <dr-button\n *ngIf=\"dialogData.acceptButton\"\n data-test=\"modalAddBtn\"\n (click)=\"onAccept()\"\n [theme]=\"'primary'\"\n [isLoading]=\"isLoading\"\n [disabled]=\"form.invalid\"\n >{{ dialogData.acceptButton.label }}</dr-button\n >\n </div>\n</div>\n", styles: [":host{display:flex;justify-content:space-between;flex-direction:column}:host.small-modal,:host.small-modal-max-height{min-height:188px;max-height:467px;min-width:400px;max-width:400px}:host.medium-modal,:host.medium-modal-max-height{min-height:188px;max-height:467px;min-width:632px;max-width:632px}:host.medium-small-modal{min-height:188px;max-height:345px;min-width:460px;max-width:460px}:host.medium-modal-max-height,:host.small-modal-max-height{max-height:80vh}.header-dialog{position:relative;display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding:16px 56px 16px 32px;border-bottom:1px solid #dfe0e3}.header-dialog>.icon-close{position:absolute;right:32px;top:16px;cursor:pointer}.title-dialog{display:flex;color:#333;position:static;font-weight:600;font-size:16px;line-height:24px;margin-top:0;margin-bottom:0}.title-dialog__icon{font-size:32px;margin-right:8px;line-height:24px;color:#6d6e6f}.content-dialog{font-weight:400;font-size:14px;padding:16px 32px 5px;white-space:pre-line}.icon-close{color:#6d6e6f;cursor:pointer}.dr-smart-from{font-size:14px;font-weight:400;line-height:22px;padding:8px 32px 24px}.dr-smart-from dr-checkbox{font-weight:400}.content-dialog{padding:16px 32px 0;font-weight:400;font-size:14px;line-height:22px}.content-anchor{display:none}.footer-dialog{border-top:1px solid #dfe0e3}.buttons-wrapper{display:flex;justify-content:flex-end;padding:10px 32px 11px}.buttons-wrapper dr-button:nth-of-type(n+2){margin-left:12px}.buttons-wrapper--custom-btn{margin-right:auto}.form-field-error-alert{font-size:12px;color:#bf1d30;line-height:20px}.form-error-alert{position:absolute;margin-top:5px;font-size:12px;color:#bf1d30}.dr-select-footer__btn{background-color:transparent;display:flex;align-items:center;justify-content:flex-start;cursor:pointer;min-width:15rem;font-style:normal;font-weight:400;font-size:14px;line-height:24px;clear:both;width:100%;white-space:nowrap;padding:0 12px;height:36px;flex-shrink:0}\n"] }]
10535
+ args: [{ selector: 'dr-dialog-modal-wrapper', template: "<div header class=\"header-dialog\">\n <h1 class=\"title-dialog\" data-test=\"modalTitle\">\n <i\n *ngIf=\"dialogData.headerIconClass\"\n (click)=\"closeDialog()\"\n class=\"title-dialog__icon\"\n [class]=\"dialogData.headerIconClass\"\n data-test=\"dialogTitleIcon\"></i>\n <span class=\"title-dialog__text\">{{ dialogData.title }}</span>\n </h1>\n <i *ngIf=\"!dialogData.hideCloseBtn\" (click)=\"closeDialog()\" class=\"dr-icon-exit icon-close\" data-test=\"xBtn\"></i>\n</div>\n<div *ngIf=\"dialogData.content\" class=\"content-dialog\" [innerHTML]=\"dialogData.content\">\n <span #content class=\"content-anchor\"></span>\n</div>\n<form *ngIf=\"dialogData.fields\" [formGroup]=\"form\" class=\"dr-smart-from\">\n <div [class]=\"dialogData.formWrapperClass || 'dr-smart-form_wrapper'\">\n <div\n *ngFor=\"let field of dialogData.fields\"\n class=\"dr-smart-form_group\"\n [class]=\"field.formGroupClass\"\n [ngStyle]=\"{ display: field.isLabelFullWidth ? 'block' : 'flex' }\">\n <label\n *ngIf=\"field.label && field.type !== dialogFieldType.CHECKBOX\"\n [ngClass]=\"field.isLabelFullWidth ? 'col-md-12 mb-2' : 'col-md-2'\"\n class=\"label p-0 d-flex align-items-center\"\n >{{ field.label }}</label\n >\n <div\n class=\"input-group p-0\"\n [ngClass]=\"{\n 'col-md-10': field.label && !field.isLabelFullWidth,\n 'col-md-12': !field.label || field.isLabelFullWidth,\n }\">\n <dr-select\n *ngIf=\"field.type === dialogFieldType.SELECT\"\n [searchable]=\"dialogData.searchable\"\n [clearable]=\"dialogData.clearable\"\n [formControlName]=\"field.name\"\n [bindLabel]=\"field.bindLabel || null\"\n [bindValue]=\"field.bindValue || null\"\n [selectedItem]=\"field.default\"\n [items]=\"field.items || (field.items$ | async)\"\n [loading]=\"fieldsItemsLoading[field.name] | async\"\n [required]=\"true\"\n [placeholder]=\"field.placeholder\">\n <ng-template *ngIf=\"dialogData?.footerTemplateData\" #optionFooterTemplate let-item=\"item\" let-close=\"close\">\n <button (click)=\"footerAction(); close()\" class=\"dr-select-footer__btn\">\n <i *ngIf=\"dialogData.footerTemplateData.icon\" class=\"{{ dialogData.footerTemplateData.icon }}\"></i>\n {{ dialogData.footerTemplateData.label }}\n </button>\n </ng-template>\n </dr-select>\n <dr-input\n *ngIf=\"field.type === dialogFieldType.INPUT\"\n data-test=\"modalInput\"\n class=\"form-control\"\n [formControlName]=\"field.name\"\n [placeholder]=\"field.placeholder\"></dr-input>\n <dr-date-picker\n *ngIf=\"field.type === dialogFieldType.DATE_PICKER\"\n [formControlName]=\"field.name\"\n [format]=\"field.datePickerFormat\"\n [placeholder]=\"field.placeholder\"></dr-date-picker>\n <dr-checkbox *ngIf=\"field.type === dialogFieldType.CHECKBOX\" [formControlName]=\"field.name\">\n {{ field.label }}\n </dr-checkbox>\n <label\n class=\"form-field-error-alert\"\n *ngIf=\"form.invalid && form.controls[field.name]?.dirty && form.controls[field.name]?.errors\">\n {{ form.controls[field.name].errors.errorString }}\n </label>\n <label class=\"form-error-alert\" *ngIf=\"dialogData.errorMessage && !form.pristine && form.invalid\">\n {{ dialogData.errorMessage }}\n </label>\n <label class=\"form-error-alert\" *ngIf=\"form.valid && showServerErrorMessage && dialogData.serverErrorMessage\">\n {{ dialogData.serverErrorMessage }}\n </label>\n </div>\n </div>\n </div>\n</form>\n\n<div footer class=\"footer-dialog\">\n <div class=\"buttons-wrapper\" *ngIf=\"dialogData.cancelButton || dialogData.acceptButton\">\n <dr-button\n (click)=\"onDecline()\"\n *ngIf=\"dialogData.customButton\"\n [theme]=\"dialogData.customButton?.theme || 'secondary'\"\n class=\"buttons-wrapper--custom-btn\"\n data-test=\"declineBtn\"\n >{{ dialogData.customButton.label }}</dr-button\n >\n <dr-button *ngIf=\"dialogData.cancelButton\" data-test=\"modalCloseBtn\" (click)=\"closeDialog()\" [theme]=\"'secondary'\">{{\n dialogData.cancelButton.label\n }}</dr-button>\n <dr-button\n *ngIf=\"dialogData.acceptButton\"\n data-test=\"modalAddBtn\"\n (click)=\"onAccept()\"\n [theme]=\"'primary'\"\n [isLoading]=\"isLoading\"\n [disabled]=\"form.invalid\"\n >{{ dialogData.acceptButton.label }}</dr-button\n >\n </div>\n</div>\n", styles: [":host{display:flex;justify-content:space-between;flex-direction:column}:host.small-modal,:host.small-modal-max-height{min-height:188px;max-height:467px;min-width:400px;max-width:400px}:host.medium-modal,:host.medium-modal-max-height{min-height:188px;max-height:467px;min-width:632px;max-width:632px}:host.medium-small-modal{min-height:188px;max-height:345px;min-width:460px;max-width:460px}:host.medium-modal-max-height,:host.small-modal-max-height{max-height:80vh}.header-dialog{position:relative;display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding:16px 56px 16px 32px;border-bottom:1px solid #dfe0e3}.header-dialog>.icon-close{position:absolute;right:32px;top:16px;cursor:pointer}.title-dialog{display:flex;color:#333;position:static;font-weight:600;font-size:16px;line-height:24px;margin-top:0;margin-bottom:0}.title-dialog__icon{font-size:32px;margin-right:8px;line-height:24px;color:#6d6e6f}.content-dialog{font-weight:400;font-size:14px;padding:16px 32px 5px;white-space:pre-line}.icon-close{color:#6d6e6f;cursor:pointer}.dr-smart-from{font-size:14px;font-weight:400;line-height:22px;padding:8px 32px 24px}.dr-smart-from dr-checkbox{font-weight:400}.content-dialog{padding:16px 32px 0;font-weight:400;font-size:14px;line-height:22px}.content-anchor{display:none}.footer-dialog{border-top:1px solid #dfe0e3}.buttons-wrapper{display:flex;justify-content:flex-end;padding:10px 32px 11px}.buttons-wrapper dr-button:nth-of-type(n+2){margin-left:12px}.buttons-wrapper--custom-btn{margin-right:auto}.form-field-error-alert{font-size:12px;color:#bf1d30;line-height:20px}.form-error-alert{position:absolute;margin-top:5px;font-size:12px;color:#bf1d30}.dr-select-footer__btn{background-color:transparent;display:flex;align-items:center;justify-content:flex-start;cursor:pointer;min-width:15rem;font-style:normal;font-weight:400;font-size:14px;line-height:24px;clear:both;width:100%;white-space:nowrap;padding:0 12px;height:36px;flex-shrink:0}\n"] }]
10514
10536
  }], function () { return [{ type: i1$6.MatLegacyDialogRef }, { type: undefined, decorators: [{
10515
10537
  type: Inject,
10516
10538
  args: [MAT_LEGACY_DIALOG_DATA]
@@ -11761,6 +11783,119 @@ class DrShineAnimationDirective {
11761
11783
  type: Input
11762
11784
  }] }); })();
11763
11785
 
11786
+ class LetContext {
11787
+ constructor(dir) {
11788
+ this.dir = dir;
11789
+ }
11790
+ get ngLet() {
11791
+ return this.dir.ngLet;
11792
+ }
11793
+ }
11794
+ /**
11795
+ * Works like *ngIf but does not have a condition
11796
+ * Use it to declare the result of pipes calculation
11797
+ * (i.e. async pipe)
11798
+ */
11799
+ class LetDirective {
11800
+ constructor(viewContainer, templateRef) {
11801
+ viewContainer.createEmbeddedView(templateRef, new LetContext(this));
11802
+ }
11803
+ static ngTemplateContextGuard(dir, ctx) {
11804
+ return true;
11805
+ }
11806
+ /** @nocollapse */ static { this.ɵfac = function LetDirective_Factory(t) { return new (t || LetDirective)(i0.ɵɵdirectiveInject(i0.ViewContainerRef), i0.ɵɵdirectiveInject(i0.TemplateRef)); }; }
11807
+ /** @nocollapse */ static { this.ɵdir = /** @pureOrBreakMyCode */ i0.ɵɵdefineDirective({ type: LetDirective, selectors: [["", "ngLet", ""]], inputs: { ngLet: "ngLet" }, standalone: true }); }
11808
+ }
11809
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LetDirective, [{
11810
+ type: Directive,
11811
+ args: [{
11812
+ selector: '[ngLet]',
11813
+ standalone: true,
11814
+ }]
11815
+ }], function () { return [{ type: i0.ViewContainerRef }, { type: i0.TemplateRef }]; }, { ngLet: [{
11816
+ type: Input
11817
+ }] }); })();
11818
+
11819
+ class TrackByPropertyDirective {
11820
+ constructor(ngForOfDir) {
11821
+ ngForOfDir.ngForTrackBy = (_, item) => item[this.ngForTrackByProperty];
11822
+ }
11823
+ /** @nocollapse */ static { this.ɵfac = function TrackByPropertyDirective_Factory(t) { return new (t || TrackByPropertyDirective)(i0.ɵɵdirectiveInject(i1.NgForOf, 1)); }; }
11824
+ /** @nocollapse */ static { this.ɵdir = /** @pureOrBreakMyCode */ i0.ɵɵdefineDirective({ type: TrackByPropertyDirective, selectors: [["", "ngForTrackByProperty", ""]], inputs: { ngForTrackByProperty: "ngForTrackByProperty" }, standalone: true }); }
11825
+ }
11826
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TrackByPropertyDirective, [{
11827
+ type: Directive,
11828
+ args: [{
11829
+ selector: '[ngForTrackByProperty]',
11830
+ standalone: true,
11831
+ }]
11832
+ }], function () { return [{ type: i1.NgForOf, decorators: [{
11833
+ type: Host
11834
+ }] }]; }, { ngForTrackByProperty: [{
11835
+ type: Input
11836
+ }] }); })();
11837
+
11838
+ class ImgPipe {
11839
+ transform(value, ...args) {
11840
+ const isLocalHost = STATIC_URL.indexOf('localhost') >= 0 || STATIC_URL.indexOf('127.0.0.1') >= 0;
11841
+ const path = value.startsWith('./') ? value.replace('./', '/') : value.startsWith('/') ? value : '/' + value;
11842
+ return isLocalHost ? value : document.staticFunc(path);
11843
+ }
11844
+ /** @nocollapse */ static { this.ɵfac = function ImgPipe_Factory(t) { return new (t || ImgPipe)(); }; }
11845
+ /** @nocollapse */ static { this.ɵpipe = /** @pureOrBreakMyCode */ i0.ɵɵdefinePipe({ name: "img", type: ImgPipe, pure: true, standalone: true }); }
11846
+ }
11847
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ImgPipe, [{
11848
+ type: Pipe,
11849
+ args: [{
11850
+ name: 'img',
11851
+ standalone: true,
11852
+ }]
11853
+ }], null, null); })();
11854
+
11855
+ class FilterPipe {
11856
+ transform(arr, fn, type, refresh) {
11857
+ if (!fn) {
11858
+ return arr;
11859
+ }
11860
+ if (!_.isArray(arr)) {
11861
+ return arr;
11862
+ }
11863
+ if (_.isFunction(fn)) {
11864
+ return arr.filter(fn);
11865
+ }
11866
+ else if (_.isArray(fn)) {
11867
+ const [key, value] = fn;
11868
+ if (_.isUndefined(value)) {
11869
+ return arr;
11870
+ }
11871
+ if (type === 'text') {
11872
+ if (key) {
11873
+ return arr.filter((item) => item[key].toLowerCase().includes(value.toLowerCase()));
11874
+ }
11875
+ else {
11876
+ return arr.filter((item) => item.toString().toLowerCase().includes(value.toLowerCase()));
11877
+ }
11878
+ }
11879
+ return arr.filter((item) => DrSharedUtils.getProperty(item, key) === value || item.system === 1);
11880
+ }
11881
+ else if (fn) {
11882
+ return arr.filter((item) => item === fn);
11883
+ }
11884
+ else {
11885
+ return arr;
11886
+ }
11887
+ }
11888
+ /** @nocollapse */ static { this.ɵfac = function FilterPipe_Factory(t) { return new (t || FilterPipe)(); }; }
11889
+ /** @nocollapse */ static { this.ɵpipe = /** @pureOrBreakMyCode */ i0.ɵɵdefinePipe({ name: "filter", type: FilterPipe, pure: true, standalone: true }); }
11890
+ }
11891
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(FilterPipe, [{
11892
+ type: Pipe,
11893
+ args: [{
11894
+ name: 'filter',
11895
+ standalone: true,
11896
+ }]
11897
+ }], null, null); })();
11898
+
11764
11899
  var FeedbackSentiment;
11765
11900
  (function (FeedbackSentiment) {
11766
11901
  FeedbackSentiment["POSITIVE"] = "positive";
@@ -13184,5 +13319,5 @@ class DrawerModule {
13184
13319
  * Generated bundle index. Do not edit.
13185
13320
  */
13186
13321
 
13187
- export { AnyTagComponent, BadgeStatus, CHAT_MESSAGE_TYPE, CROP_IMAGE_MODES, CalendarView, ChatMessage, ChatRole, CheckboxComponent, ClickOutsideDirective, ClickOutsideModule, CodeEditorHintWrapperComponent, CustomDateAdapter, CustomDateFormat, DEFAULT_LINK_FONT_SIZE, DEFAULT_LINK_FONT_WEIGHT, DIALOG_BUTTON_LABEL, DIALOG_FIELD_TYPE, DIALOG_SIZE, DR_DRAWER_DATA, DR_DRAWER_DEFAULT_OPTIONS, DR_SHINE_ANIMATION_CLASS, DataAnalyticsService, DateFromats, DatePickerPeriodPosition, DateTagComponent, DateTagModule, DateTags, DayTagComponent, DefaultToastrComponent, DefaultTreeviewEventParser, DefaultTreeviewI18n, DialogModalWrapperComponent, DialogService, DialogWrapperComponent, DownlineTreeviewEventParser, DrAccordionComponent, DrAccordionItemBodyComponent, DrAccordionItemComponent, DrAccordionItemHeaderComponent, DrAccordionModule, DrAlertComponent, DrAlertModule, DrAlertTheme, DrAvatarComponent, DrAvatarModule, DrAvatarPipe, DrAvatarService, DrBadgeStatusComponent, DrBadgeStatusModule, DrButtonComponent, DrChatAlertComponent, DrChatComponent, DrChatCustomMessageDirective, DrChatFormComponent, DrChatMessageComponent, DrChatMessageFileComponent, DrChatMessageTextComponent, DrChatModule, DrChatSuggestionsComponent, DrChipComponent, DrCodeEditorComponent, DrCodeEditorModule, DrCodemirrorComponent, DrDatePickerComponent, DrDatePickerCustomHeaderComponent, DrDatePickerFormatDirective, DrDatePickerRangeComponent, DrDatePickerWithTimeframeComponent, DrDetailsListComponent, DrDetailsListModule, DrDialogModule, DrDotFlashingComponent, DrDropdownChildDirective, DrDropdownComponent, DrDropdownDirective, DrDropdownItemComponent, DrDropdownItemShowPipe, DrDropdownModule, DrDropdownService, DrErrorComponent, DrErrorModule, DrImageCropperComponent, DrInputComponent, DrInputsModule, DrLayoutBodyComponent, DrLayoutComponent, DrLayoutHeaderComponent, DrLayoutModule, DrLinkComponent, DrModelDebounceChangeDirective, DrPopoverAlignmentDimension, DrPopoverComponent, DrPopoverDirective, DrPopoverModule, DrPopoverRef, DrPopoverService, DrScenarioConfigurationComponent, DrScenarioModule, DrScenarioTagConfigurationComponent, DrSelectAddItemComponent, DrSelectComponent, DrSharedUtils, DrShineAnimationDirective, DrShowTimeframePipe, DrSliderComponent, DrSpinnerComponent, DrSpinnerDirective, DrSpinnerModule, DrStepperModule, DrTabComponent, DrTabsComponent, DrTabsModule, DrTagComponent, DrTagModule, DrTagsConstructorComponent, DrTagsConstructorModule, DrToastrModule, DrToastrService, DrToggleButtonComponent, DrToggleComponent, DrTooltipDirective, DrTooltipModule, Drawer, DrawerConfig, DrawerContainer, DrawerModule, DrawerRef, DropdownInstanceService, FeedbackSentiment, ForecastTagComponent, ForecastTagService, ICodeEditorHintIcon, IMAGE_TYPES, LinkTheme, ListTagComponent, ListTagModule, MonthTagComponent, OrderDownlineTreeviewEventParser, QuarterTagComponent, RadioButtonComponent, RadioGroupComponent, Scenario, ScenarioService, StepperComponent, TagTypes, TagsConfigSubType, TagsConstructorService, TimeframeOption, ToastrStatus, ToastrStatusIcon, ToggleButtonMode, TooltipComponent, TooltipDefaultComponent, TooltipInfoComponent, TooltipInfoIconTheme, TooltipInfoWidth, TooltipPosition, TooltipTheme, TreeviewComponent, TreeviewConfig, TreeviewEventParser, TreeviewHelper, TreeviewI18n, TreeviewItem, TreeviewModule, TreeviewPipe, WeekTagComponent, YearTagComponent };
13322
+ export { AnyTagComponent, BadgeStatus, CHAT_MESSAGE_TYPE, CROP_IMAGE_MODES, CalendarView, ChatMessage, ChatRole, CheckboxComponent, ClickOutsideDirective, ClickOutsideModule, CodeEditorHintWrapperComponent, CustomDateAdapter, CustomDateFormat, DEFAULT_LINK_FONT_SIZE, DEFAULT_LINK_FONT_WEIGHT, DIALOG_BUTTON_LABEL, DIALOG_FIELD_TYPE, DIALOG_SIZE, DR_DRAWER_DATA, DR_DRAWER_DEFAULT_OPTIONS, DR_SHINE_ANIMATION_CLASS, DataAnalyticsService, DateFromats, DatePickerPeriodPosition, DateTagComponent, DateTagModule, DateTags, DayTagComponent, DefaultToastrComponent, DefaultTreeviewEventParser, DefaultTreeviewI18n, DialogModalWrapperComponent, DialogService, DialogWrapperComponent, DownlineTreeviewEventParser, DrAccordionComponent, DrAccordionItemBodyComponent, DrAccordionItemComponent, DrAccordionItemHeaderComponent, DrAccordionModule, DrAlertComponent, DrAlertModule, DrAlertTheme, DrAvatarComponent, DrAvatarModule, DrAvatarPipe, DrAvatarService, DrBadgeStatusComponent, DrBadgeStatusModule, DrButtonComponent, DrChatAlertComponent, DrChatComponent, DrChatCustomMessageDirective, DrChatFormComponent, DrChatMessageComponent, DrChatMessageFileComponent, DrChatMessageTextComponent, DrChatModule, DrChatSuggestionsComponent, DrChipComponent, DrCodeEditorComponent, DrCodeEditorModule, DrCodemirrorComponent, DrDatePickerComponent, DrDatePickerCustomHeaderComponent, DrDatePickerFormatDirective, DrDatePickerRangeComponent, DrDatePickerWithTimeframeComponent, DrDetailsListComponent, DrDetailsListModule, DrDialogModule, DrDotFlashingComponent, DrDropdownChildDirective, DrDropdownComponent, DrDropdownDirective, DrDropdownItemComponent, DrDropdownItemShowPipe, DrDropdownModule, DrDropdownService, DrErrorComponent, DrErrorModule, DrImageCropperComponent, DrInputComponent, DrInputsModule, DrLayoutBodyComponent, DrLayoutComponent, DrLayoutHeaderComponent, DrLayoutModule, DrLinkComponent, DrModelDebounceChangeDirective, DrPopoverAlignmentDimension, DrPopoverComponent, DrPopoverDirective, DrPopoverModule, DrPopoverRef, DrPopoverService, DrScenarioConfigurationComponent, DrScenarioModule, DrScenarioTagConfigurationComponent, DrSelectAddItemComponent, DrSelectComponent, DrSharedUtils, DrShineAnimationDirective, DrShowTimeframePipe, DrSliderComponent, DrSpinnerComponent, DrSpinnerDirective, DrSpinnerModule, DrStepperModule, DrTabComponent, DrTabsComponent, DrTabsModule, DrTagComponent, DrTagModule, DrTagsConstructorComponent, DrTagsConstructorModule, DrToastrModule, DrToastrService, DrToggleButtonComponent, DrToggleComponent, DrTooltipDirective, DrTooltipModule, Drawer, DrawerConfig, DrawerContainer, DrawerModule, DrawerRef, DropdownInstanceService, FeedbackSentiment, FilterPipe, ForecastTagComponent, ForecastTagService, ICodeEditorHintIcon, IMAGE_TYPES, ImgPipe, LetContext, LetDirective, LinkTheme, ListTagComponent, ListTagModule, MonthTagComponent, OrderDownlineTreeviewEventParser, QuarterTagComponent, RadioButtonComponent, RadioGroupComponent, Scenario, ScenarioService, StepperComponent, TagTypes, TagsConfigSubType, TagsConstructorService, TimeframeOption, ToastrStatus, ToastrStatusIcon, ToggleButtonMode, TooltipComponent, TooltipDefaultComponent, TooltipInfoComponent, TooltipInfoIconTheme, TooltipInfoWidth, TooltipPosition, TooltipTheme, TrackByPropertyDirective, TreeviewComponent, TreeviewConfig, TreeviewEventParser, TreeviewHelper, TreeviewI18n, TreeviewItem, TreeviewModule, TreeviewPipe, WeekTagComponent, YearTagComponent };
13188
13323
  //# sourceMappingURL=datarailsshared-datarailsshared.mjs.map