@bizdoc/core 3.8.2 → 3.8.7

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.
@@ -106,6 +106,8 @@ import * as i8$1 from '@angular/material/toolbar';
106
106
  import { MatToolbarModule } from '@angular/material/toolbar';
107
107
  import * as i2$c from '@angular/material/radio';
108
108
  import { MatRadioModule, MatRadioButton } from '@angular/material/radio';
109
+ import * as i2$e from '@angular/material/timepicker';
110
+ import { MatTimepickerModule } from '@angular/material/timepicker';
109
111
  import * as i7$3 from '@angular/material/progress-spinner';
110
112
  import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
111
113
  import * as i4$3 from '@angular/cdk/scrolling';
@@ -520,7 +522,7 @@ function cleanup(params) {
520
522
  else if (typeof val === 'string' || typeof val === 'boolean')
521
523
  return;
522
524
  else if (val instanceof Date)
523
- params[k] = val.toLocaleDateString('en-US');
525
+ params[k] = val.toJSON();
524
526
  else if (Array.isArray(val)) {
525
527
  if (val.length === 0)
526
528
  delete params[k];
@@ -7894,8 +7896,8 @@ class MaterialModule {
7894
7896
  MatProgressSpinnerModule, MatListModule, MatSidenavModule,
7895
7897
  MatToolbarModule, MatAutocompleteModule, MatSelectModule,
7896
7898
  MatSlideToggleModule, MatSnackBarModule, MatButtonModule,
7897
- MatCheckboxModule, MatInputModule,
7898
- MatFormFieldModule, MatIconModule, MatMenuModule, LayoutModule], exports: [LayoutModule,
7899
+ MatCheckboxModule, MatInputModule, MatTimepickerModule,
7900
+ MatFormFieldModule, MatIconModule, MatMenuModule, LayoutModule], exports: [LayoutModule, MatTimepickerModule,
7899
7901
  CdkScrollableModule,
7900
7902
  OverlayModule, PortalModule,
7901
7903
  MatChipsModule, DragDropModule,
@@ -7941,8 +7943,8 @@ class MaterialModule {
7941
7943
  MatProgressSpinnerModule, MatListModule, MatSidenavModule,
7942
7944
  MatToolbarModule, MatAutocompleteModule, MatSelectModule,
7943
7945
  MatSlideToggleModule, MatSnackBarModule, MatButtonModule,
7944
- MatCheckboxModule, MatInputModule,
7945
- MatFormFieldModule, MatIconModule, MatMenuModule, LayoutModule, LayoutModule,
7946
+ MatCheckboxModule, MatInputModule, MatTimepickerModule,
7947
+ MatFormFieldModule, MatIconModule, MatMenuModule, LayoutModule, LayoutModule, MatTimepickerModule,
7946
7948
  CdkScrollableModule,
7947
7949
  OverlayModule, PortalModule,
7948
7950
  MatChipsModule, DragDropModule,
@@ -7973,10 +7975,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
7973
7975
  MatProgressSpinnerModule, MatListModule, MatSidenavModule,
7974
7976
  MatToolbarModule, MatAutocompleteModule, MatSelectModule,
7975
7977
  MatSlideToggleModule, MatSnackBarModule, MatButtonModule,
7976
- MatCheckboxModule, MatInputModule,
7978
+ MatCheckboxModule, MatInputModule, MatTimepickerModule,
7977
7979
  MatFormFieldModule, MatIconModule, MatMenuModule, LayoutModule
7978
7980
  ],
7979
- exports: [LayoutModule,
7981
+ exports: [LayoutModule, MatTimepickerModule,
7980
7982
  CdkScrollableModule,
7981
7983
  OverlayModule, PortalModule,
7982
7984
  MatChipsModule, DragDropModule,
@@ -8359,23 +8361,23 @@ class ChatInfo {
8359
8361
  this._nav(userId, contact, options);
8360
8362
  }
8361
8363
  _nav(userId, contact, options) {
8362
- if (this._config && this._config.app) {
8363
- const { app } = this._config;
8364
- if (isString(app)) {
8365
- const url = app.indexOf('{0}') > -1 ? app.formatArgs(userId) : `${app}${userId}`;
8364
+ if (this._config && this._config.url) {
8365
+ const { url } = this._config;
8366
+ if (isString(url)) {
8367
+ const path = url.indexOf('{0}') > -1 ? url.formatArgs(userId) : `${url}${userId}`;
8366
8368
  // const anchor = document.createElement('a');
8367
8369
  // anchor.href = app.formatArgs(userId);
8368
8370
  // anchor.style.display = 'none';
8369
8371
  // anchor.target = '_blank';
8370
8372
  // document.appendChild(anchor);
8371
8373
  // anchor.click();
8372
- window.open(url, '_blank');
8374
+ window.open(path, '_blank');
8373
8375
  }
8374
8376
  else
8375
8377
  this._account.get(userId).subscribe(p => {
8376
- const url = app(p);
8377
- isString(url) &&
8378
- window.open(url, '_blank');
8378
+ const path = url(p);
8379
+ isString(path) &&
8380
+ window.open(path, '_blank');
8379
8381
  });
8380
8382
  }
8381
8383
  else if (this._isMobile)
@@ -19458,7 +19460,7 @@ class HomeBase {
19458
19460
  this.profile = this._session.profile;
19459
19461
  this.schedulerEnabled = config.scheduler !== false;
19460
19462
  this.chatEnabled = config.chat !== false &&
19461
- (!config.chat || !config.chat.app);
19463
+ (!config.chat || !config.chat.url);
19462
19464
  if (config.appLogo) {
19463
19465
  this.appLogo = inject(DomSanitizer).bypassSecurityTrustResourceUrl(config.appLogo);
19464
19466
  }
@@ -27366,188 +27368,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
27366
27368
  type: Input
27367
27369
  }] } });
27368
27370
 
27369
- const TIME_FORMAT = /\d{1,2}:\d{1,2}/, DATE_FORMAT = /\d{4}-\d\d-\d\dT\d\d:\d{2}/;
27370
- function generateValues() {
27371
- const times = [];
27372
- let h = 0;
27373
- while (h < 24) {
27374
- let m = 0;
27375
- while (m < 60) {
27376
- times.push(`${h}:${m}`);
27377
- m += 15;
27378
- }
27379
- h++;
27380
- }
27381
- return times;
27382
- }
27383
- class TimePicker {
27384
- static { this.nextId = 0; }
27385
- get empty() {
27386
- const value = this.control.value;
27387
- return !value;
27388
- }
27389
- get shouldLabelFloat() { return this.focused || !this.empty; }
27390
- get placeholder() { return this._placeholder; }
27391
- set placeholder(value) {
27392
- this._placeholder = value;
27393
- this.stateChanges.next();
27394
- }
27395
- get required() { return this._required; }
27396
- set required(value) {
27397
- this._required = coerceBooleanProperty(value);
27398
- this.stateChanges.next();
27399
- }
27400
- get disabled() { return this._disabled; }
27401
- set disabled(value) {
27402
- this._disabled = coerceBooleanProperty(value);
27403
- this._disabled ? this.control.disable() : this.control.enable();
27404
- this.stateChanges.next();
27405
- }
27406
- get value() {
27407
- const value = this.control.value;
27408
- return value;
27409
- }
27410
- set value(val) {
27411
- this._setValue(val, true);
27412
- this.stateChanges.next();
27413
- }
27414
- _setValue(val, emitEvent) {
27415
- if (val) {
27416
- if (isDate(val) || DATE_FORMAT.test(val)) {
27417
- val = new Date(val);
27418
- this.control.setValue(val.getHours() + ':' + val.getMinutes(), { emitEvent });
27419
- }
27420
- else
27421
- this.control.setValue(TIME_FORMAT.exec(val)[0], { emitEvent });
27422
- }
27423
- else
27424
- this.control.reset();
27425
- }
27426
- constructor(_focusMonitor, _elementRef, ngControl) {
27427
- this._focusMonitor = _focusMonitor;
27428
- this._elementRef = _elementRef;
27429
- this.ngControl = ngControl;
27430
- this.controlType = 'time-picker';
27431
- this.id = `time-picker-${TimePicker.nextId++}`;
27432
- this.focused = false;
27433
- this.errorState = false;
27434
- this.describedBy = '';
27435
- this.onChange = (_) => { };
27436
- this.onTouched = () => { };
27437
- this._required = false;
27438
- this._disabled = false;
27439
- this.control = new FormControl(null);
27440
- this.stateChanges = new Subject();
27441
- this.options = generateValues();
27442
- this._destroy = new Subject();
27443
- _focusMonitor.monitor(_elementRef, true).subscribe(origin => {
27444
- if (this.focused && !origin) {
27445
- this.onTouched();
27446
- }
27447
- this.focused = !!origin;
27448
- this.stateChanges.next();
27449
- });
27450
- if (this.ngControl != null) {
27451
- this.ngControl.valueAccessor = this;
27452
- }
27453
- }
27454
- setDescribedByIds(ids) {
27455
- this.describedBy = ids.join(' ');
27456
- }
27457
- onContainerClick(event) {
27458
- if (event.target.tagName !== 'INPUT')
27459
- this._elementRef.nativeElement.querySelector('input').focus();
27460
- }
27461
- writeValue(val) {
27462
- this._setValue(val, false);
27463
- }
27464
- registerOnChange(fn) {
27465
- this.onChange = fn;
27466
- }
27467
- registerOnTouched(fn) {
27468
- this.onTouched = fn;
27469
- }
27470
- setDisabledState(isDisabled) {
27471
- this.disabled = isDisabled;
27472
- }
27473
- ngOnInit() {
27474
- this.control.valueChanges.pipe(takeUntil(this._destroy)).
27475
- subscribe(v => {
27476
- this.errorState = !this._validate(v);
27477
- if (v && !this.errorState && this.dateControlName) {
27478
- const date = this._dateControl?.value;
27479
- date && this._appendTime(date);
27480
- }
27481
- this.onChange(this.value);
27482
- });
27483
- if (this.dateControlName) {
27484
- this._dateControl = this.ngControl.control.parent.get(this.dateControlName);
27485
- if (!this._dateControl)
27486
- throw `${this.controlType} dateControlName ${this.dateControlName}`;
27487
- this._dateControl.valueChanges.pipe(takeUntil(this._destroy)).
27488
- subscribe((v) => {
27489
- v && this.value && this._appendTime(v);
27490
- });
27491
- }
27492
- }
27493
- _appendTime(val) {
27494
- if (!isDate(val))
27495
- val = new Date(val);
27496
- const parts = this.value.split(':');
27497
- val.setHours(parseInt(parts[0]), parseInt(parts[1]));
27498
- this._dateControl?.setValue(val.toISOString(), { emitEvent: false });
27499
- }
27500
- _validate(val) {
27501
- if (!val)
27502
- return !this._required;
27503
- const parts = val.split(':');
27504
- if (parts.length > 2)
27505
- return false;
27506
- for (let i = 0; i < parts.length; i++) {
27507
- if (!/\d{1,2}/.test(parts[i]))
27508
- return false;
27509
- const part = parseInt(parts[i]);
27510
- if (isNaN(part))
27511
- return false;
27512
- else if (i === 0 && (part < 0 || part > 23))
27513
- return false;
27514
- else if (i === 1 && (part < 0 || part > 59))
27515
- return false;
27516
- }
27517
- return true;
27518
- }
27519
- ngOnDestroy() {
27520
- this.stateChanges.complete();
27521
- this._focusMonitor.stopMonitoring(this._elementRef);
27522
- this._destroy.next();
27523
- this._destroy.complete();
27524
- }
27525
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: TimePicker, deps: [{ token: i2$9.FocusMonitor }, { token: i0.ElementRef }, { token: i1$2.NgControl, optional: true, self: true }], target: i0.ɵɵFactoryTarget.Component }); }
27526
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.2", type: TimePicker, isStandalone: false, selector: "mat-time-picker", inputs: { dateControlName: "dateControlName", placeholder: "placeholder", required: "required", disabled: "disabled", value: "value" }, host: { properties: { "class.floating": "shouldLabelFloat", "id": "id", "attr.aria-describedby": "describedBy" } }, providers: [{ provide: MatFormFieldControl, useExisting: TimePicker }], ngImport: i0, template: "<input matInput type=\"text\" [matAutocomplete]=\"auto\" [formControl]=\"control\" [placeholder]=\"placeholder\">\r\n<mat-autocomplete #auto>\r\n @for (o of options; track o) {\r\n <mat-option [value]=\"o\">{{o}}</mat-option>\r\n }\r\n</mat-autocomplete>\r\n", dependencies: [{ kind: "directive", type: i1$2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i2$6.MatAutocomplete, selector: "mat-autocomplete", inputs: ["aria-label", "aria-labelledby", "displayWith", "autoActiveFirstOption", "autoSelectActiveOption", "requireSelection", "panelWidth", "disableRipple", "class", "hideSingleSelectionIndicator"], outputs: ["optionSelected", "opened", "closed", "optionActivated"], exportAs: ["matAutocomplete"] }, { kind: "component", type: i2$6.MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "directive", type: i2$6.MatAutocompleteTrigger, selector: "input[matAutocomplete], textarea[matAutocomplete]", inputs: ["matAutocomplete", "matAutocompletePosition", "matAutocompleteConnectedTo", "autocomplete", "matAutocompleteDisabled"], exportAs: ["matAutocompleteTrigger"] }, { kind: "directive", type: i4$1.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }] }); }
27527
- }
27528
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: TimePicker, decorators: [{
27529
- type: Component,
27530
- args: [{ standalone: false, selector: 'mat-time-picker', providers: [{ provide: MatFormFieldControl, useExisting: TimePicker }], host: {
27531
- '[class.floating]': 'shouldLabelFloat',
27532
- '[id]': 'id',
27533
- '[attr.aria-describedby]': 'describedBy'
27534
- }, template: "<input matInput type=\"text\" [matAutocomplete]=\"auto\" [formControl]=\"control\" [placeholder]=\"placeholder\">\r\n<mat-autocomplete #auto>\r\n @for (o of options; track o) {\r\n <mat-option [value]=\"o\">{{o}}</mat-option>\r\n }\r\n</mat-autocomplete>\r\n" }]
27535
- }], ctorParameters: () => [{ type: i2$9.FocusMonitor }, { type: i0.ElementRef }, { type: i1$2.NgControl, decorators: [{
27536
- type: Optional
27537
- }, {
27538
- type: Self
27539
- }] }], propDecorators: { dateControlName: [{
27540
- type: Input
27541
- }], placeholder: [{
27542
- type: Input
27543
- }], required: [{
27544
- type: Input
27545
- }], disabled: [{
27546
- type: Input
27547
- }], value: [{
27548
- type: Input
27549
- }] } });
27550
-
27551
27371
  const COMBINATION_PICKER_BODY = new InjectionToken('combination_body');
27552
27372
  /** */
27553
27373
  class CombinationPickerBody {
@@ -30739,14 +30559,14 @@ let TimeField = class TimeField {
30739
30559
  this.max && this.control.addValidators(Validators.max(this.max));
30740
30560
  }
30741
30561
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: TimeField, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
30742
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.2", type: TimeField, isStandalone: false, selector: "ng-component", host: { classAttribute: "field" }, viewQueries: [{ propertyName: "input", first: true, predicate: MatInput, descendants: true }], ngImport: i0, template: "@if (mode==='compose') {\r\n <mat-form-field [appearance]=appearance [subscriptSizing]=\"subscriptSizing\">\r\n <mat-label>{{label|localizedString}}</mat-label>\r\n <mat-time-picker [placeholder]=\"placeholder|localizedString\" [formControl]=control\r\n [required]=\"required\">\r\n </mat-time-picker>\r\n @if (hint) {\r\n <mat-hint> {{ hint|localizedString }}</mat-hint>\r\n }\r\n @if (control.hasError('required')) {\r\n <mat-error [innerHTML]=\"'RequiredErr'|translate:(label|localizedString)\"></mat-error>\r\n }\r\n </mat-form-field>\r\n} @else {\r\n @if (control.value) {\r\n <span>{{control.value | amDateFormat: 'll'}}</span>\r\n }\r\n}\r\n", dependencies: [{ kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1$2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i3$1.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i3$1.MatLabel, selector: "mat-label" }, { kind: "directive", type: i3$1.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i3$1.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "component", type: TimePicker, selector: "mat-time-picker", inputs: ["dateControlName", "placeholder", "required", "disabled", "value"] }, { kind: "pipe", type: LocalizedStringPipe, name: "localizedString" }, { kind: "pipe", type: DateFormatPipe, name: "amDateFormat" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] }); }
30562
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.2", type: TimeField, isStandalone: false, selector: "ng-component", host: { classAttribute: "field" }, viewQueries: [{ propertyName: "input", first: true, predicate: MatInput, descendants: true }], ngImport: i0, template: "@if (mode==='compose') {\r\n<mat-form-field [appearance]=appearance [subscriptSizing]=\"subscriptSizing\">\r\n <mat-label>{{label|localizedString}}</mat-label>\r\n <input matInput [matTimepicker]=\"picker\" [placeholder]=\"placeholder|localizedString\" [formControl]=control>\r\n <mat-timepicker-toggle matIconSuffix [for]=\"picker\" />\r\n <mat-timepicker #picker />\r\n @if (hint) {\r\n <mat-hint> {{ hint|localizedString }}</mat-hint>\r\n }\r\n @if (control.hasError('required')) {\r\n <mat-error [innerHTML]=\"'RequiredErr'|translate:(label|localizedString)\"></mat-error>\r\n }\r\n</mat-form-field>\r\n} @else {\r\n @if (control.value) {\r\n <span>{{control.value | amDateFormat: 'll'}}</span>\r\n }\r\n}\r\n", dependencies: [{ kind: "directive", type: i1$2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i2$e.MatTimepicker, selector: "mat-timepicker", inputs: ["interval", "options", "disableRipple", "aria-label", "aria-labelledby"], outputs: ["selected", "opened", "closed"], exportAs: ["matTimepicker"] }, { kind: "directive", type: i2$e.MatTimepickerInput, selector: "input[matTimepicker]", inputs: ["value", "matTimepicker", "matTimepickerMin", "matTimepickerMax", "disabled"], outputs: ["valueChange"], exportAs: ["matTimepickerInput"] }, { kind: "component", type: i2$e.MatTimepickerToggle, selector: "mat-timepicker-toggle", inputs: ["for", "aria-label", "aria-labelledby", "disabled", "tabIndex", "disableRipple"], exportAs: ["matTimepickerToggle"] }, { kind: "component", type: i3$1.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i3$1.MatLabel, selector: "mat-label" }, { kind: "directive", type: i3$1.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i3$1.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i3$1.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "directive", type: i4$1.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "pipe", type: LocalizedStringPipe, name: "localizedString" }, { kind: "pipe", type: DateFormatPipe, name: "amDateFormat" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] }); }
30743
30563
  };
30744
30564
  TimeField = __decorate([
30745
30565
  BizDoc({ selector: 'time-control' })
30746
30566
  ], TimeField);
30747
30567
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: TimeField, decorators: [{
30748
30568
  type: Component,
30749
- args: [{ standalone: false, host: { class: 'field' }, template: "@if (mode==='compose') {\r\n <mat-form-field [appearance]=appearance [subscriptSizing]=\"subscriptSizing\">\r\n <mat-label>{{label|localizedString}}</mat-label>\r\n <mat-time-picker [placeholder]=\"placeholder|localizedString\" [formControl]=control\r\n [required]=\"required\">\r\n </mat-time-picker>\r\n @if (hint) {\r\n <mat-hint> {{ hint|localizedString }}</mat-hint>\r\n }\r\n @if (control.hasError('required')) {\r\n <mat-error [innerHTML]=\"'RequiredErr'|translate:(label|localizedString)\"></mat-error>\r\n }\r\n </mat-form-field>\r\n} @else {\r\n @if (control.value) {\r\n <span>{{control.value | amDateFormat: 'll'}}</span>\r\n }\r\n}\r\n" }]
30569
+ args: [{ standalone: false, host: { class: 'field' }, template: "@if (mode==='compose') {\r\n<mat-form-field [appearance]=appearance [subscriptSizing]=\"subscriptSizing\">\r\n <mat-label>{{label|localizedString}}</mat-label>\r\n <input matInput [matTimepicker]=\"picker\" [placeholder]=\"placeholder|localizedString\" [formControl]=control>\r\n <mat-timepicker-toggle matIconSuffix [for]=\"picker\" />\r\n <mat-timepicker #picker />\r\n @if (hint) {\r\n <mat-hint> {{ hint|localizedString }}</mat-hint>\r\n }\r\n @if (control.hasError('required')) {\r\n <mat-error [innerHTML]=\"'RequiredErr'|translate:(label|localizedString)\"></mat-error>\r\n }\r\n</mat-form-field>\r\n} @else {\r\n @if (control.value) {\r\n <span>{{control.value | amDateFormat: 'll'}}</span>\r\n }\r\n}\r\n" }]
30750
30570
  }], propDecorators: { input: [{
30751
30571
  type: ViewChild,
30752
30572
  args: [MatInput]
@@ -31251,24 +31071,27 @@ const CONTROLS_COMPONENTS$1 = [SignatureField, AddressField, ChecklistField, Rad
31251
31071
  /** common BizDoc components */
31252
31072
  class SharedModule {
31253
31073
  static forChild(config) {
31254
- const { formats, routingEngine, routes } = config || {};
31255
- routes && PANES_CONFIG.push(...routes);
31256
- const providers = [{
31257
- provide: MAT_DATE_FORMATS, useValue: {
31258
- parse: {
31259
- dateInput: 'LL',
31260
- },
31261
- display: {
31262
- dateInput: (formats || {}).date || 'll',
31263
- monthYearLabel: 'MMM YYYY',
31264
- dateA11yLabel: 'LL',
31265
- monthYearA11yLabel: 'MMMM YYYY',
31266
- }
31267
- }
31268
- }];
31269
- if (routingEngine)
31074
+ const { components, translations } = config || {};
31075
+ components && registerComponents(components);
31076
+ translations && TranslateService.set(translations);
31077
+ return {
31078
+ ngModule: SharedModule,
31079
+ providers: []
31080
+ };
31081
+ }
31082
+ static forRoot(config) {
31083
+ const { components, formats, routingEngine } = config || {};
31084
+ components && registerComponents(components);
31085
+ const providers = [
31086
+ {
31087
+ provide: BIZDOC_CONFIG,
31088
+ useValue: config
31089
+ },
31090
+ materialFormatsProvider(formats)
31091
+ ];
31092
+ routingEngine === 'ng' &&
31270
31093
  providers.push({
31271
- provide: RouterImpl, useClass: routingEngine === 'ng' ? NgRouter : PaneRouter
31094
+ provide: RouterImpl, useClass: NgRouter
31272
31095
  });
31273
31096
  return {
31274
31097
  ngModule: SharedModule,
@@ -31298,7 +31121,6 @@ class SharedModule {
31298
31121
  TypeSelect, TypeAutocomplete, Signature,
31299
31122
  AceInput, TimespanInput, AddressInput,
31300
31123
  FileInput,
31301
- TimePicker,
31302
31124
  LayoutComponent, StickyToolbar, VirtualTabs, Tab,
31303
31125
  TimeField, SignatureField, AddressField, RadioButtonField, ChecklistField, AxesPickerField, YesNoField, HtmlField, FileField, NumericField, AutocompleteField, CheckboxField, DateField, DateRangeField, ExpressionField,
31304
31126
  InputField, SelectField, SwitchField, TextareaField, ChipsField, TimespanField,
@@ -31400,7 +31222,6 @@ class SharedModule {
31400
31222
  AceInput,
31401
31223
  CombinationPicker, CombinationPool,
31402
31224
  TypeSelect, TypeAutocomplete,
31403
- TimePicker,
31404
31225
  DurationFormatPipe,
31405
31226
  DateRangePipe,
31406
31227
  TypeValuePipe,
@@ -31491,7 +31312,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
31491
31312
  TypeSelect, TypeAutocomplete, Signature,
31492
31313
  AceInput, TimespanInput, AddressInput,
31493
31314
  FileInput,
31494
- TimePicker,
31495
31315
  LayoutComponent, StickyToolbar, VirtualTabs, Tab,
31496
31316
  TimeField, SignatureField, AddressField, RadioButtonField, ChecklistField, AxesPickerField, YesNoField, HtmlField, FileField, NumericField, AutocompleteField, CheckboxField, DateField, DateRangeField, ExpressionField,
31497
31317
  InputField, SelectField, SwitchField, TextareaField, ChipsField, TimespanField,
@@ -31614,7 +31434,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
31614
31434
  AceInput,
31615
31435
  CombinationPicker, CombinationPool,
31616
31436
  TypeSelect, TypeAutocomplete,
31617
- TimePicker,
31618
31437
  DurationFormatPipe,
31619
31438
  DateRangePipe,
31620
31439
  TypeValuePipe,
@@ -31643,6 +31462,21 @@ registerComponents(CORE_COMPONENTS);
31643
31462
  registerComponents(CONTROLS_COMPONENTS$1);
31644
31463
  /* Syncfusion 30.x */
31645
31464
  registerLicense('Ngo9BigBOggjHTQxAR8/V1JEaF5cXmRCf1FpRmJGdld5fUVHYVZUTXxaS00DNHVRdkdmWXhecXRdRmdYWUVyW0FWYEk=');
31465
+ function materialFormatsProvider(formats) {
31466
+ return {
31467
+ provide: MAT_DATE_FORMATS, useValue: {
31468
+ parse: {
31469
+ dateInput: 'LL',
31470
+ },
31471
+ display: {
31472
+ dateInput: (formats || {}).date || 'll',
31473
+ monthYearLabel: 'MMM YYYY',
31474
+ dateA11yLabel: 'LL',
31475
+ monthYearA11yLabel: 'MMMM YYYY',
31476
+ }
31477
+ }
31478
+ };
31479
+ }
31646
31480
 
31647
31481
  class MobileModule {
31648
31482
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: MobileModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
@@ -37879,50 +37713,54 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
37879
37713
 
37880
37714
  const DEFAULT_ROUTE = 'dashboard';
37881
37715
  class BizDocModule {
37716
+ /**
37717
+ *
37718
+ * @param config
37719
+ * @returns
37720
+ */
37882
37721
  static forChild(config) {
37883
37722
  const { components, routes } = config;
37884
- registerComponents(components);
37885
- routes && PANES_CONFIG.push(...routes);
37723
+ components && registerComponents(components);
37724
+ if (routes) {
37725
+ if (isMobile())
37726
+ MOBILE_CONFIG.push(...routes);
37727
+ else
37728
+ PANES_CONFIG.push(...routes);
37729
+ }
37886
37730
  return {
37887
37731
  ngModule: BizDocModule,
37888
- providers: [
37889
- { provide: PANES_DATA, useValue: PANES_CONFIG }
37890
- ]
37732
+ providers: []
37891
37733
  };
37892
37734
  }
37735
+ /**
37736
+ *
37737
+ * @param config
37738
+ * @returns
37739
+ */
37893
37740
  static forRoot(config) {
37894
37741
  const { formats, routes, components, defaultRoute } = config;
37895
- registerComponents(components);
37742
+ components && registerComponents(components);
37896
37743
  const providers = [
37897
37744
  {
37898
37745
  provide: BIZDOC_CONFIG,
37899
37746
  useValue: config
37900
37747
  },
37901
- {
37902
- provide: MAT_DATE_FORMATS,
37903
- useValue: {
37904
- parse: {
37905
- dateInput: 'LL',
37906
- },
37907
- display: {
37908
- dateInput: (formats || {}).date || 'll',
37909
- monthYearLabel: 'MMM YYYY',
37910
- dateA11yLabel: 'LL',
37911
- monthYearA11yLabel: 'MMMM YYYY',
37912
- }
37913
- }
37914
- },
37748
+ materialFormatsProvider(formats),
37915
37749
  ];
37916
37750
  const redirectTo = defaultRoute ? isString(defaultRoute) ? defaultRoute : defaultRoute() : DEFAULT_ROUTE;
37917
37751
  if (isMobile()) {
37918
37752
  routes && MOBILE_CONFIG.push(...routes);
37919
37753
  MOBILE_CONFIG.push({ path: '', redirectTo, pathMatch: 'full' });
37920
- providers.push(provideRouter(MOBILE_CONFIG, withEnabledBlockingInitialNavigation()));
37754
+ providers.push(provideRouter(MOBILE_CONFIG, withEnabledBlockingInitialNavigation()), {
37755
+ provide: RouterImpl, useClass: NgRouter
37756
+ });
37921
37757
  }
37922
37758
  else {
37923
37759
  routes && PANES_CONFIG.push(...routes);
37924
37760
  PANES_CONFIG.push({ path: '', redirectTo });
37925
- providers.push({ provide: PANES_DATA, useValue: PANES_CONFIG });
37761
+ providers.push({ provide: PANES_DATA, useValue: PANES_CONFIG }, {
37762
+ provide: RouterImpl, useClass: PaneRouter
37763
+ });
37926
37764
  }
37927
37765
  return {
37928
37766
  ngModule: BizDocModule,
@@ -37941,7 +37779,7 @@ class BizDocModule {
37941
37779
  MobileModule,
37942
37780
  DesktopModule,
37943
37781
  SystemModule.forChild(),
37944
- SharedModule.forChild({ routingEngine: isMobile() ? 'ng' : 'pane' }), SharedModule,
37782
+ SharedModule, SharedModule,
37945
37783
  MaterialModule] }); }
37946
37784
  }
37947
37785
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: BizDocModule, decorators: [{
@@ -37956,7 +37794,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
37956
37794
  MobileModule,
37957
37795
  DesktopModule,
37958
37796
  SystemModule.forChild(),
37959
- SharedModule.forChild({ routingEngine: isMobile() ? 'ng' : 'pane' })
37797
+ SharedModule
37960
37798
  ],
37961
37799
  providers: [],
37962
37800
  exports: [
@@ -37985,5 +37823,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
37985
37823
  * Generated bundle index. Do not edit.
37986
37824
  */
37987
37825
 
37988
- export { AccountService, AceInput, ActionDialog, ActionPicker, ActionPipe, ActionRef, ActionsWidget, AddressControlDesigner, AddressInput, AgoPipe, ArraySortPipe, AssignActionComponent, AttachmentInfo, AttachmentPreview, AuthenticationImpl, AutocompleteControlDesigner, AvatarComponent, BIZDOC_CONFIG, BackNavigation, BizDoc, BizDocApp, BizDocComponentFactoryResolver, BizDocModule, BrokenPage, BrowseFilterComponent, BrowseItemsComponent, CalendarPipe, ChatInfo, CheckboxComponent, CheckboxControlDesigner, ChecklistControlDesigner, CollapseNavigation, ColorPicker, CombinationPicker, CombinationPickerBody, CombinationPool, CommentsComponent, CompareContextDirective, CompareGroupDirective, CompareGroupsWidget, CompareNameDirective, ComposeFormComponent, ContactsComponent, ConversationComponent, CubeAccumAnalysisWidget, CubeAccumulationChartComponent, CubeAnalysisWidget, CubeChartAnalysisWidget, CubeChartComponent, CubeDocumentsGridComponent, CubeDocumentsTableComponent, CubeDocumentsWidget, CubeFilterComponent, CubeGridComponent, CubeInfo, CubeItemResolveService, CubeMatrixComponent, CubeParallelComponent, CubePerformanceWidget, CubePivotComponent, CubeService, CubeSpreadsheetComponent, CubeSumComponent, CubeViewComponent, CubeWidgetFilterComponent, DEFAULT_POLICY, DRAFT, DashboardComponent, DatasourceService, DateControlDesigner, DateFormatPipe, DateRangeControlDesigner, DateRangePipe, DesignerCubeFilterComponent, DesignerModule, DesignerRef, DifferencePipe, DocumentFactory, DocumentInfo, DocumentInfoComponent, DocumentResolveService, DocumentViewRef, DocumentViewsComponent, DurationFormatPipe, DurationPipe, EnterExitLeft, EnterExitRight, EnterExitTop, ExploreDocumentComponent, ExploreItemImplComponent, ExploreItemsComponent, ExpressionFieldDesigner, FONT_FAMILY, FadeSlideInOut, FieldKind, FileControlDesigner, FileInput, FilterPipe, FilterTagsComponent, FlowViewComponent, FormPipe, FormRef, GuideRef, GuideService, HelpTipComponent, HtmlFieldDesigner, INBOX, IdentityName, InputFieldDesigner, JoinPipe, JsonPipe, L18nPipe, LayoutComponent, ListingRef, LocalizedStringComponent, LocalizedStringControlDesigner, LocalizedStringPipe, LottieAnimation, MailboxService, MapInfo, MatIconAnimate, MaterialModule, NavigationBase, NavigationClose, NavigationEnd, NavigationExpand, NavigationFocus, NavigationMode, NavigationPaneBase, NavigationResize, NavigationStart, NodeRef, NoneComponent, NotificationRef, NotificationsTableComponent, NumberControlDesigner, OpenPolicy, OptionsComponent, POPUP_DATA, PaneRef, PanesRouter, ParamNavigation, PeersPerformanceWidget, PendingResultsWidget, PersonalActivityWidget, PersonalScoreWidget, Popup, PopupRef, PrivilegeDisabledDirective, PrivilegeHiddenDirective, PulseAnimation, QueryParamNavigation, QuickCommentComponent, RadioButtonControlDesigner, RecentsWidget, RecipientResolveService, ReportArgumentsComponent, ReportRef, ReportViewerComponent, ReturnActionComponent, RolePipe, RouterImpl, SanitizeHtmlPipe, SaveChangesDialog, ScheduleViewComponent, SearchInput, SelectControlDesigner, SessionService, ShakeAnimation, SharedModule, SignatureControlDesigner, SlotRouterDirective, SpContainer, StateDirective, StatePipe, StickyToolbar, SubstitutionComponent, SwapAnimation, Tab, TagsComponent, TagsControlDesigner, TasksComponent, TextAreaFieldDesigner, TimeAgoPipe, TimeControlDesigner, TimePicker, TimespanControlDesigner, TimespanInput, ToNowPipe, TooltipDirective, TraceViewComponent, TranslatePipe, TranslateService, TypeAutocomplete, TypeSelect, TypeValuePipe, UsageChartComponent, UsagePivotComponent, UsageReportArgs, UserNamePipe, UtilityRef, VersionCompareComponent, VirtualTabs, WidgetItemComponent, WidgetRef, YesNoControlDesigner, cleanup, getMonthList, isArray, isBoolean, isDate, isFunction, isImage, isMobile, isObject, isPrimitive, isPromise, isString, modelize, playAudio, programName, registerComponents };
37826
+ export { AccountService, AceInput, ActionDialog, ActionPicker, ActionPipe, ActionRef, ActionsWidget, AddressControlDesigner, AddressInput, AgoPipe, ArraySortPipe, AssignActionComponent, AttachmentInfo, AttachmentPreview, AuthenticationImpl, AutocompleteControlDesigner, AvatarComponent, BIZDOC_CONFIG, BackNavigation, BizDoc, BizDocApp, BizDocComponentFactoryResolver, BizDocModule, BrokenPage, BrowseFilterComponent, BrowseItemsComponent, CalendarPipe, ChatInfo, CheckboxComponent, CheckboxControlDesigner, ChecklistControlDesigner, CollapseNavigation, ColorPicker, CombinationPicker, CombinationPickerBody, CombinationPool, CommentsComponent, CompareContextDirective, CompareGroupDirective, CompareGroupsWidget, CompareNameDirective, ComposeFormComponent, ContactsComponent, ConversationComponent, CubeAccumAnalysisWidget, CubeAccumulationChartComponent, CubeAnalysisWidget, CubeChartAnalysisWidget, CubeChartComponent, CubeDocumentsGridComponent, CubeDocumentsTableComponent, CubeDocumentsWidget, CubeFilterComponent, CubeGridComponent, CubeInfo, CubeItemResolveService, CubeMatrixComponent, CubeParallelComponent, CubePerformanceWidget, CubePivotComponent, CubeService, CubeSpreadsheetComponent, CubeSumComponent, CubeViewComponent, CubeWidgetFilterComponent, DEFAULT_POLICY, DRAFT, DashboardComponent, DatasourceService, DateControlDesigner, DateFormatPipe, DateRangeControlDesigner, DateRangePipe, DesignerCubeFilterComponent, DesignerModule, DesignerRef, DifferencePipe, DocumentFactory, DocumentInfo, DocumentInfoComponent, DocumentResolveService, DocumentViewRef, DocumentViewsComponent, DurationFormatPipe, DurationPipe, EnterExitLeft, EnterExitRight, EnterExitTop, ExploreDocumentComponent, ExploreItemImplComponent, ExploreItemsComponent, ExpressionFieldDesigner, FONT_FAMILY, FadeSlideInOut, FieldKind, FileControlDesigner, FileInput, FilterPipe, FilterTagsComponent, FlowViewComponent, FormPipe, FormRef, GuideRef, GuideService, HelpTipComponent, HtmlFieldDesigner, INBOX, IdentityName, InputFieldDesigner, JoinPipe, JsonPipe, L18nPipe, LayoutComponent, ListingRef, LocalizedStringComponent, LocalizedStringControlDesigner, LocalizedStringPipe, LottieAnimation, MailboxService, MapInfo, MatIconAnimate, MaterialModule, NavigationBase, NavigationClose, NavigationEnd, NavigationExpand, NavigationFocus, NavigationMode, NavigationPaneBase, NavigationResize, NavigationStart, NodeRef, NoneComponent, NotificationRef, NotificationsTableComponent, NumberControlDesigner, OpenPolicy, OptionsComponent, POPUP_DATA, PaneRef, PanesRouter, ParamNavigation, PeersPerformanceWidget, PendingResultsWidget, PersonalActivityWidget, PersonalScoreWidget, Popup, PopupRef, PrivilegeDisabledDirective, PrivilegeHiddenDirective, PulseAnimation, QueryParamNavigation, QuickCommentComponent, RadioButtonControlDesigner, RecentsWidget, RecipientResolveService, ReportArgumentsComponent, ReportRef, ReportViewerComponent, ReturnActionComponent, RolePipe, RouterImpl, SanitizeHtmlPipe, SaveChangesDialog, ScheduleViewComponent, SearchInput, SelectControlDesigner, SessionService, ShakeAnimation, SharedModule, SignatureControlDesigner, SlotRouterDirective, SpContainer, StateDirective, StatePipe, StickyToolbar, SubstitutionComponent, SwapAnimation, Tab, TagsComponent, TagsControlDesigner, TasksComponent, TextAreaFieldDesigner, TimeAgoPipe, TimeControlDesigner, TimespanControlDesigner, TimespanInput, ToNowPipe, TooltipDirective, TraceViewComponent, TranslatePipe, TranslateService, TypeAutocomplete, TypeSelect, TypeValuePipe, UsageChartComponent, UsagePivotComponent, UsageReportArgs, UserNamePipe, UtilityRef, VersionCompareComponent, VirtualTabs, WidgetItemComponent, WidgetRef, YesNoControlDesigner, cleanup, getMonthList, isArray, isBoolean, isDate, isFunction, isImage, isMobile, isObject, isPrimitive, isPromise, isString, modelize, playAudio, programName, registerComponents };
37989
37827
  //# sourceMappingURL=bizdoc-core.mjs.map