@bizdoc/core 3.8.1 → 3.8.5

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];
@@ -1136,6 +1138,35 @@ class SessionService {
1136
1138
  iconRegistry.addSvgIconLiteral('word', sanitizer.bypassSecurityTrustHtml(WORD_ICON));
1137
1139
  iconRegistry.addSvgIconLiteral('powerpoint', sanitizer.bypassSecurityTrustHtml(POWERPOINT_ICON));
1138
1140
  iconRegistry.addSvgIconLiteral('pdf', sanitizer.bypassSecurityTrustHtml(PDF_ICON));
1141
+ _hub.notify$.subscribe(n => {
1142
+ const { messages, messagesCount } = this.profile;
1143
+ messages.push(n.model);
1144
+ this.profile.messagesCount = !messagesCount ? 1 :
1145
+ messagesCount + 1;
1146
+ });
1147
+ //
1148
+ _hub.updateNotify$.subscribe(e => {
1149
+ const { originalRead, model: { id, sent, read } } = e, { messages, messagesCount } = this.profile;
1150
+ const item = messages.find(n => n.id === id);
1151
+ if (item)
1152
+ Object.assign(item, e.model);
1153
+ else
1154
+ messages.push(e.model);
1155
+ if (originalRead !== undefined && read !== originalRead &&
1156
+ this._isAboveWatermark(sent))
1157
+ this.profile.messagesCount = (messagesCount || 0) + (read ? -1 : 1);
1158
+ });
1159
+ //
1160
+ _hub.new$.subscribe(m => {
1161
+ const { userId, model: { folderId } } = m, { inboxCount, folders, userId: me } = this.profile;
1162
+ if (userId !== me)
1163
+ return;
1164
+ this.profile.inboxCount = !inboxCount ? 1 :
1165
+ inboxCount + 1;
1166
+ const folder = folders.find(f => f.name === folderId);
1167
+ folder.count = !folder.count ? 1 :
1168
+ folder.count + 1;
1169
+ });
1139
1170
  }
1140
1171
  /** */
1141
1172
  get tags() {
@@ -1151,10 +1182,11 @@ class SessionService {
1151
1182
  get accentPalette() {
1152
1183
  return this._accentpalette;
1153
1184
  }
1154
- isAboveWatermark(date) {
1185
+ _isAboveWatermark(date) {
1186
+ const { notificationsView } = this.profile.options;
1155
1187
  return !this.isImpersonating &&
1156
- this.profile.options.notificationsView !== undefined &&
1157
- this.profile.options.notificationsView < date;
1188
+ notificationsView !== undefined &&
1189
+ notificationsView < date;
1158
1190
  }
1159
1191
  get primeryPalette() {
1160
1192
  return this._primarypalette;
@@ -7153,7 +7185,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
7153
7185
 
7154
7186
  const DOCUMENT_MODEL = new InjectionToken('model');
7155
7187
  class MailboxService {
7156
- constructor(messaging, _session, _auth, _http) {
7188
+ constructor(_session, _auth, _http) {
7157
7189
  this._session = _session;
7158
7190
  this._auth = _auth;
7159
7191
  this._http = _http;
@@ -7171,18 +7203,6 @@ class MailboxService {
7171
7203
  this._change$.next(m);
7172
7204
  }));
7173
7205
  };
7174
- messaging.new$.
7175
- subscribe(m => {
7176
- if (m.userId !== _session.profile.userId)
7177
- return;
7178
- if (!_session.profile.inboxCount)
7179
- _session.profile.inboxCount = 0;
7180
- _session.profile.inboxCount++;
7181
- const folder = _session.profile.folders.find(f => f.name === m.model.folderId);
7182
- if (!folder.count)
7183
- folder.count = 0;
7184
- folder.count++;
7185
- });
7186
7206
  }
7187
7207
  async formatDownloadUrl(document, file) {
7188
7208
  let url = `/api/attachments/${document.documentId}/${file.id}`;
@@ -7208,12 +7228,12 @@ class MailboxService {
7208
7228
  return this._http.delete(`/api/attachments/${recipientId}/${fileId}`);
7209
7229
  }
7210
7230
  markAsRead(id, read, folderId, received) {
7211
- return this._http.put(`/api/mailbox/read/${id}`, undefined, { params: { read } }).pipe(tap(() => folderId && received && this._updateunreadcounter(received, folderId, read ? 1 : -1)));
7231
+ return this._http.put(`/api/mailbox/read/${id}`, undefined, { params: { read } }).pipe(tap(() => folderId && received && this._updateUnreadWatermark(received, folderId, read ? 1 : -1)));
7212
7232
  }
7213
7233
  listComments(id, before) {
7214
7234
  return this._http.get(`/api/comments/${id}`, { params: { before: new Date(before).toJSON() } });
7215
7235
  }
7216
- updateRecipientTags(id, tags) {
7236
+ updateTags(id, tags) {
7217
7237
  return this._http.put(`/api/mailbox/tag/${id}`, { tags }).pipe(tap(() => {
7218
7238
  this._change$.next({ id, tags });
7219
7239
  }));
@@ -7421,21 +7441,19 @@ class MailboxService {
7421
7441
  */
7422
7442
  get(id, read) {
7423
7443
  return this._http.get(`/api/mail/${id}`).pipe(tap((m) => read === false && m.read === true &&
7424
- this._updateunreadcounter(m.received, m.folderId, -1)));
7444
+ this._updateUnreadWatermark(m.received, m.folderId, -1)));
7425
7445
  }
7426
- _updateunreadcounter(date, folderId, val) {
7446
+ _updateUnreadWatermark(date, folderId, move) {
7447
+ const { inboxCount, folders, options: { inboxView } } = this._session.profile;
7427
7448
  if (
7428
7449
  // date is above watermark
7429
- this._session.profile.options.inboxView &&
7430
- this._session.profile.options.inboxView < date) {
7431
- if (!this._session.profile.inboxCount)
7432
- this._session.profile.inboxCount = 0;
7433
- this._session.profile.inboxCount += val;
7434
- }
7450
+ inboxView &&
7451
+ inboxView < date)
7452
+ this._session.profile.inboxCount = !inboxCount ? 0 :
7453
+ inboxCount + move;
7435
7454
  // decrease
7436
- const folder = this._session.profile.folders.
7437
- find(f => f.name === folderId);
7438
- folder.count = Math.max(0, (folder.count || 0) + val);
7455
+ const folder = folders.find(f => f.name === folderId);
7456
+ folder.count = Math.max(0, (folder.count || 0) + move);
7439
7457
  }
7440
7458
  save(id, form, version, model, files) {
7441
7459
  //const fd = new FormData();
@@ -7471,7 +7489,7 @@ class MailboxService {
7471
7489
  delete(id) {
7472
7490
  return this._http.delete(`/api/mail/${id}`).pipe(tap(() => this._delete$.next(id)));
7473
7491
  }
7474
- toggleRemoveComment(id, value) {
7492
+ toggleCommentHide(id, value) {
7475
7493
  return this._http.delete(`/api/comments/${id}?value=${value}`);
7476
7494
  }
7477
7495
  //post<T = any>(form: string, model?: T): Observable<RecipientModel<T>> {
@@ -7488,7 +7506,7 @@ class MailboxService {
7488
7506
  return this._geoLocation(form).pipe(switchMap(params => this._http.put(`/api/mail/${id}?version=${version}&go=true`, model, { params })), this._sync());
7489
7507
  }
7490
7508
  send(id, version, form, model, action, actionArgs, read, folderId, received) {
7491
- return this._geoLocation(form).pipe(switchMap(params => this._http.put(`/api/mail/${id}?version=${version}&action=${action}`, model, { params: { ...params, ...actionArgs } })), tap(() => read === false && received && folderId && this._updateunreadcounter(received, folderId, -1)), this._sync());
7509
+ return this._geoLocation(form).pipe(switchMap(params => this._http.put(`/api/mail/${id}?version=${version}&action=${action}`, model, { params: { ...params, ...actionArgs } })), tap(() => read === false && received && folderId && this._updateUnreadWatermark(received, folderId, -1)), this._sync());
7492
7510
  }
7493
7511
  listEvents(starting, ending, contains) {
7494
7512
  return this._http.get(`/api/events`, {
@@ -7532,13 +7550,13 @@ class MailboxService {
7532
7550
  }
7533
7551
  });
7534
7552
  }
7535
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: MailboxService, deps: [{ token: HubService }, { token: SessionService }, { token: AuthenticationImpl }, { token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
7553
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: MailboxService, deps: [{ token: SessionService }, { token: AuthenticationImpl }, { token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
7536
7554
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: MailboxService, providedIn: 'root' }); }
7537
7555
  }
7538
7556
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: MailboxService, decorators: [{
7539
7557
  type: Injectable,
7540
7558
  args: [{ providedIn: 'root' }]
7541
- }], ctorParameters: () => [{ type: HubService }, { type: SessionService }, { type: AuthenticationImpl }, { type: i1.HttpClient }] });
7559
+ }], ctorParameters: () => [{ type: SessionService }, { type: AuthenticationImpl }, { type: i1.HttpClient }] });
7542
7560
  function isHttpResponse(event) {
7543
7561
  return event.type === HttpEventType.Response;
7544
7562
  }
@@ -7878,8 +7896,8 @@ class MaterialModule {
7878
7896
  MatProgressSpinnerModule, MatListModule, MatSidenavModule,
7879
7897
  MatToolbarModule, MatAutocompleteModule, MatSelectModule,
7880
7898
  MatSlideToggleModule, MatSnackBarModule, MatButtonModule,
7881
- MatCheckboxModule, MatInputModule,
7882
- MatFormFieldModule, MatIconModule, MatMenuModule, LayoutModule], exports: [LayoutModule,
7899
+ MatCheckboxModule, MatInputModule, MatTimepickerModule,
7900
+ MatFormFieldModule, MatIconModule, MatMenuModule, LayoutModule], exports: [LayoutModule, MatTimepickerModule,
7883
7901
  CdkScrollableModule,
7884
7902
  OverlayModule, PortalModule,
7885
7903
  MatChipsModule, DragDropModule,
@@ -7925,8 +7943,8 @@ class MaterialModule {
7925
7943
  MatProgressSpinnerModule, MatListModule, MatSidenavModule,
7926
7944
  MatToolbarModule, MatAutocompleteModule, MatSelectModule,
7927
7945
  MatSlideToggleModule, MatSnackBarModule, MatButtonModule,
7928
- MatCheckboxModule, MatInputModule,
7929
- MatFormFieldModule, MatIconModule, MatMenuModule, LayoutModule, LayoutModule,
7946
+ MatCheckboxModule, MatInputModule, MatTimepickerModule,
7947
+ MatFormFieldModule, MatIconModule, MatMenuModule, LayoutModule, LayoutModule, MatTimepickerModule,
7930
7948
  CdkScrollableModule,
7931
7949
  OverlayModule, PortalModule,
7932
7950
  MatChipsModule, DragDropModule,
@@ -7957,10 +7975,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
7957
7975
  MatProgressSpinnerModule, MatListModule, MatSidenavModule,
7958
7976
  MatToolbarModule, MatAutocompleteModule, MatSelectModule,
7959
7977
  MatSlideToggleModule, MatSnackBarModule, MatButtonModule,
7960
- MatCheckboxModule, MatInputModule,
7978
+ MatCheckboxModule, MatInputModule, MatTimepickerModule,
7961
7979
  MatFormFieldModule, MatIconModule, MatMenuModule, LayoutModule
7962
7980
  ],
7963
- exports: [LayoutModule,
7981
+ exports: [LayoutModule, MatTimepickerModule,
7964
7982
  CdkScrollableModule,
7965
7983
  OverlayModule, PortalModule,
7966
7984
  MatChipsModule, DragDropModule,
@@ -8124,10 +8142,9 @@ const FILTER_DEBOUNCE = 250;
8124
8142
  /** browse-filter component*/
8125
8143
  class BrowseFilterComponent {
8126
8144
  /** browse-filter ctor */
8127
- constructor(_fb, _session, _cd, _mailbox, _accounts, _config) {
8145
+ constructor(_fb, _session, _mailbox, _accounts, _config) {
8128
8146
  this._fb = _fb;
8129
8147
  this._session = _session;
8130
- this._cd = _cd;
8131
8148
  this._mailbox = _mailbox;
8132
8149
  this._accounts = _accounts;
8133
8150
  this._config = _config;
@@ -8172,9 +8189,6 @@ class BrowseFilterComponent {
8172
8189
  ngAfterViewInit() {
8173
8190
  this.focus();
8174
8191
  }
8175
- displayName(val) {
8176
- return isObject(val) ? val.name : null;
8177
- }
8178
8192
  change(axis, evt) {
8179
8193
  this.form.get(axis).setValue(evt.option.value.key);
8180
8194
  }
@@ -8187,38 +8201,33 @@ class BrowseFilterComponent {
8187
8201
  cleanup(value);
8188
8202
  this.valuesChange.emit(value);
8189
8203
  }
8190
- toggleTag(evt) {
8191
- //const tag = (evt.value as Tag)?.name;
8192
- //this.form.controls.tags.setValue(this.form.controls.tags.value !== tag ? tag : null);
8193
- }
8194
- displayFn(item) {
8195
- return item ? item.name : undefined;
8204
+ displayFn(person) {
8205
+ return person ? person.name : undefined;
8196
8206
  }
8197
8207
  drop(evt) {
8198
8208
  evt.item.data;
8199
8209
  }
8200
8210
  senderSelected(e) {
8201
- const info = e.option.value;
8202
- this.form.patchValue({ senderId: info ? info.id : null });
8211
+ const person = e.option.value;
8212
+ this.form.patchValue({ senderId: person ? person.id : null });
8203
8213
  }
8204
8214
  focus() {
8205
8215
  if (this.containsEl)
8206
- this.containsEl.nativeElement.focus();
8207
- else if (this.senderEl)
8208
- this.senderEl.nativeElement.focus();
8209
- //this._cd.detectChanges();
8216
+ this.containsEl.focus();
8217
+ else
8218
+ this.senderEl.focus();
8210
8219
  }
8211
8220
  ngOnDestroy() {
8212
8221
  this._destroy.next();
8213
8222
  this._destroy.complete();
8214
8223
  }
8215
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: BrowseFilterComponent, deps: [{ token: i1$2.FormBuilder }, { token: SessionService }, { token: i0.ChangeDetectorRef }, { token: MailboxService }, { token: AccountService }, { token: BIZDOC_CONFIG }], target: i0.ɵɵFactoryTarget.Component }); }
8216
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.2", type: BrowseFilterComponent, isStandalone: false, selector: "bizdoc-browse-filter", inputs: { values: "values", folderId: "folderId", exclude: "exclude" }, outputs: { valuesChange: "valuesChange" }, viewQueries: [{ propertyName: "chips", first: true, predicate: MatChipListbox, descendants: true, static: true }, { propertyName: "containsEl", first: true, predicate: ["contains"], descendants: true, read: ElementRef, static: true }, { propertyName: "senderEl", first: true, predicate: ["sender"], descendants: true, read: ElementRef, static: true }], ngImport: i0, template: "<form [formGroup]=\"form\" class=\"column gap\" autocomplete=\"off\">\r\n <!--@if (!exclude || exclude.indexOf('contains') < 0) {\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <input matInput formControlName=\"contains\" [placeholder]=\"'Contains' | translate\" #contains>\r\n @if (form.value.contains) {\r\n <button matSuffix mat-icon-button aria-label=\"\" (click)=\"form.controls.contains.setValue(null)\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n }\r\n </mat-form-field>\r\n }-->\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <input matInput [matAutocomplete]=\"senders\" [placeholder]=\"'Sender' | translate\" [formControl]=\"sendername\" #sender />\r\n <mat-autocomplete #senders [displayWith]=\"displayName\" (optionSelected)=\"senderSelected($event)\">\r\n @for (u of senders$ | async; track u.id) {\r\n <mat-option [value]=\"u\">\r\n <span>{{u.name}}</span>\r\n </mat-option>\r\n }\r\n </mat-autocomplete>\r\n @if (sendername.value) {\r\n <button matSuffix mat-icon-button (click)=\"clearSender()\"><mat-icon>clear</mat-icon></button>\r\n }\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-select [placeholder]=\"'Status'|translate\" formControlName=\"stateId\" multiple>\r\n <mat-option>\r\n {{ 'All' | translate }}\r\n </mat-option>\r\n @for (s of states; track s.name) {\r\n <mat-option [value]=\"s.name\">\r\n {{s.title}}\r\n </mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-select [placeholder]=\"'Form' | translate\" formControlName=\"formId\">\r\n <mat-option>\r\n {{ 'All' | translate }}\r\n </mat-option>\r\n @for (f of forms; track f.name) {\r\n <mat-option [value]=\"f.name\">{{f.title}}</mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-label>{{'Received' | translate}}</mat-label>\r\n <mat-date-range-input [rangePicker]=\"datePicker\" [formGroup]=\"form\">\r\n <input matStartDate [placeholder]=\"'StartDate'| translate\" formControlName=\"fromDate\">\r\n <input matEndDate [placeholder]=\"'EndDate' | translate\" formControlName=\"toDate\">\r\n </mat-date-range-input>\r\n <mat-datepicker-toggle matIconSuffix [for]=\"datePicker\"></mat-datepicker-toggle>\r\n <mat-date-range-picker #datePicker></mat-date-range-picker>\r\n </mat-form-field>\r\n <mat-chip-listbox id=\"tags\" [multiple]=true formControlName=\"tags\">\r\n @for (tag of tags; track tag.name) {\r\n <mat-chip-option [value]=\"tag.name\" [highlighted]=false>\r\n @if(tag.icon) {\r\n <mat-icon matChipAvatar>{{tag.icon}}</mat-icon>\r\n }\r\n {{tag.title || tag.name}}\r\n </mat-chip-option>\r\n }\r\n </mat-chip-listbox>\r\n @if (filters) {\r\n <bizdoc-cube-filter class=\"cube-filter\"\r\n [cube]=\"filters.cube\"\r\n [include]=\"filters.axes\"\r\n [axes]=\"values\"\r\n [autofocus]=\"false\"\r\n (axesChange)=\"axesChange($event)\"></bizdoc-cube-filter>\r\n }\r\n</form>\r\n", styles: [".cube-filter ::ng-deep form{padding:0}\n"], dependencies: [{ kind: "directive", type: i1$2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { 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.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i4.MatChipAvatar, selector: "mat-chip-avatar, [matChipAvatar]" }, { kind: "component", type: i4.MatChipListbox, selector: "mat-chip-listbox", inputs: ["multiple", "aria-orientation", "selectable", "compareWith", "required", "hideSingleSelectionIndicator", "value"], outputs: ["change"] }, { kind: "component", type: i4.MatChipOption, selector: "mat-basic-chip-option, [mat-basic-chip-option], mat-chip-option, [mat-chip-option]", inputs: ["selectable", "selected"], outputs: ["selectionChange"] }, { kind: "component", type: i2$4.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { kind: "component", type: i2$4.MatDateRangeInput, selector: "mat-date-range-input", inputs: ["rangePicker", "required", "dateFilter", "min", "max", "disabled", "separator", "comparisonStart", "comparisonEnd"], exportAs: ["matDateRangeInput"] }, { kind: "directive", type: i2$4.MatStartDate, selector: "input[matStartDate]", outputs: ["dateChange", "dateInput"] }, { kind: "directive", type: i2$4.MatEndDate, selector: "input[matEndDate]", outputs: ["dateChange", "dateInput"] }, { kind: "component", type: i2$4.MatDateRangePicker, selector: "mat-date-range-picker", exportAs: ["matDateRangePicker"] }, { 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: "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.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "component", type: i3$1.MatSelect, selector: "mat-select", inputs: ["aria-describedby", "panelClass", "disabled", "disableRipple", "tabIndex", "hideSingleSelectionIndicator", "placeholder", "required", "multiple", "disableOptionCentering", "compareWith", "value", "aria-label", "aria-labelledby", "errorStateMatcher", "typeaheadDebounceInterval", "sortComparator", "id", "panelWidth", "canSelectNullableOptions"], outputs: ["openedChange", "opened", "closed", "selectionChange", "valueChange"], exportAs: ["matSelect"] }, { kind: "component", type: i8.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { 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: "component", type: i7.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: CubeFilterComponent, selector: "bizdoc-cube-filter", inputs: ["cube", "exclude", "include", "axes", "autofocus"], outputs: ["axesChange"] }, { kind: "pipe", type: i9.AsyncPipe, name: "async" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] }); }
8224
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: BrowseFilterComponent, deps: [{ token: i1$2.FormBuilder }, { token: SessionService }, { token: MailboxService }, { token: AccountService }, { token: BIZDOC_CONFIG }], target: i0.ɵɵFactoryTarget.Component }); }
8225
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.2", type: BrowseFilterComponent, isStandalone: false, selector: "bizdoc-browse-filter", inputs: { values: "values", folderId: "folderId", exclude: "exclude" }, outputs: { valuesChange: "valuesChange" }, viewQueries: [{ propertyName: "chips", first: true, predicate: MatChipListbox, descendants: true, static: true }, { propertyName: "containsEl", first: true, predicate: ["contains"], descendants: true, read: MatInput, static: true }, { propertyName: "senderEl", first: true, predicate: ["sender"], descendants: true, read: MatInput, static: true }], ngImport: i0, template: "<form [formGroup]=\"form\" class=\"column gap\" autocomplete=\"off\">\r\n <!--@if (!exclude || exclude.indexOf('contains') < 0) {\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <input matInput formControlName=\"contains\" [placeholder]=\"'Contains' | translate\" #contains>\r\n @if (form.value.contains) {\r\n <button matSuffix mat-icon-button aria-label=\"\" (click)=\"form.controls.contains.setValue(null)\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n }\r\n </mat-form-field>\r\n }-->\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <input matInput [matAutocomplete]=\"senders\" [placeholder]=\"'Sender' | translate\" [formControl]=\"sendername\" #sender />\r\n <mat-autocomplete #senders [displayWith]=\"displayFn\" (optionSelected)=\"senderSelected($event)\">\r\n @for (u of senders$ | async; track u.id) {\r\n <mat-option [value]=\"u\">\r\n <span>{{u.name}}</span>\r\n </mat-option>\r\n }\r\n </mat-autocomplete>\r\n @if (sendername.value) {\r\n <button matSuffix mat-icon-button (click)=\"clearSender()\"><mat-icon>clear</mat-icon></button>\r\n }\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-select [placeholder]=\"'Status'|translate\" formControlName=\"stateId\" multiple>\r\n <!--<mat-option>\r\n {{ 'All' | translate }}\r\n </mat-option>-->\r\n @for (s of states; track s.name) {\r\n <mat-option [value]=\"s.name\">\r\n {{s.title}}\r\n </mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-select [placeholder]=\"'Form' | translate\" formControlName=\"formId\">\r\n <mat-option>\r\n {{ 'All' | translate }}\r\n </mat-option>\r\n @for (f of forms; track f.name) {\r\n <mat-option [value]=\"f.name\">{{f.title}}</mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-label>{{'Received' | translate}}</mat-label>\r\n <mat-date-range-input [rangePicker]=\"datePicker\" [formGroup]=\"form\">\r\n <input matStartDate [placeholder]=\"'StartDate'| translate\" formControlName=\"fromDate\">\r\n <input matEndDate [placeholder]=\"'EndDate' | translate\" formControlName=\"toDate\">\r\n </mat-date-range-input>\r\n <mat-datepicker-toggle matIconSuffix [for]=\"datePicker\"></mat-datepicker-toggle>\r\n <mat-date-range-picker #datePicker></mat-date-range-picker>\r\n </mat-form-field>\r\n <mat-chip-listbox id=\"tags\" [multiple]=true formControlName=\"tags\">\r\n @for (tag of tags; track tag.name) {\r\n <mat-chip-option [value]=\"tag.name\" [highlighted]=false>\r\n @if(tag.icon) {\r\n <mat-icon matChipAvatar>{{tag.icon}}</mat-icon>\r\n }\r\n {{tag.title || tag.name}}\r\n </mat-chip-option>\r\n }\r\n </mat-chip-listbox>\r\n @if (filters) {\r\n <bizdoc-cube-filter class=\"cube-filter\"\r\n [cube]=\"filters.cube\"\r\n [include]=\"filters.axes\"\r\n [axes]=\"values\"\r\n [autofocus]=\"false\"\r\n (axesChange)=\"axesChange($event)\"></bizdoc-cube-filter>\r\n }\r\n</form>\r\n", styles: [".cube-filter ::ng-deep form{padding:0}\n"], dependencies: [{ kind: "directive", type: i1$2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { 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.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i4.MatChipAvatar, selector: "mat-chip-avatar, [matChipAvatar]" }, { kind: "component", type: i4.MatChipListbox, selector: "mat-chip-listbox", inputs: ["multiple", "aria-orientation", "selectable", "compareWith", "required", "hideSingleSelectionIndicator", "value"], outputs: ["change"] }, { kind: "component", type: i4.MatChipOption, selector: "mat-basic-chip-option, [mat-basic-chip-option], mat-chip-option, [mat-chip-option]", inputs: ["selectable", "selected"], outputs: ["selectionChange"] }, { kind: "component", type: i2$4.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { kind: "component", type: i2$4.MatDateRangeInput, selector: "mat-date-range-input", inputs: ["rangePicker", "required", "dateFilter", "min", "max", "disabled", "separator", "comparisonStart", "comparisonEnd"], exportAs: ["matDateRangeInput"] }, { kind: "directive", type: i2$4.MatStartDate, selector: "input[matStartDate]", outputs: ["dateChange", "dateInput"] }, { kind: "directive", type: i2$4.MatEndDate, selector: "input[matEndDate]", outputs: ["dateChange", "dateInput"] }, { kind: "component", type: i2$4.MatDateRangePicker, selector: "mat-date-range-picker", exportAs: ["matDateRangePicker"] }, { 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: "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.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "component", type: i3$1.MatSelect, selector: "mat-select", inputs: ["aria-describedby", "panelClass", "disabled", "disableRipple", "tabIndex", "hideSingleSelectionIndicator", "placeholder", "required", "multiple", "disableOptionCentering", "compareWith", "value", "aria-label", "aria-labelledby", "errorStateMatcher", "typeaheadDebounceInterval", "sortComparator", "id", "panelWidth", "canSelectNullableOptions"], outputs: ["openedChange", "opened", "closed", "selectionChange", "valueChange"], exportAs: ["matSelect"] }, { kind: "component", type: i8.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { 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: "component", type: i7.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: CubeFilterComponent, selector: "bizdoc-cube-filter", inputs: ["cube", "exclude", "include", "axes", "autofocus"], outputs: ["axesChange"] }, { kind: "pipe", type: i9.AsyncPipe, name: "async" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] }); }
8217
8226
  }
8218
8227
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: BrowseFilterComponent, decorators: [{
8219
8228
  type: Component,
8220
- args: [{ standalone: false, selector: 'bizdoc-browse-filter', template: "<form [formGroup]=\"form\" class=\"column gap\" autocomplete=\"off\">\r\n <!--@if (!exclude || exclude.indexOf('contains') < 0) {\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <input matInput formControlName=\"contains\" [placeholder]=\"'Contains' | translate\" #contains>\r\n @if (form.value.contains) {\r\n <button matSuffix mat-icon-button aria-label=\"\" (click)=\"form.controls.contains.setValue(null)\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n }\r\n </mat-form-field>\r\n }-->\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <input matInput [matAutocomplete]=\"senders\" [placeholder]=\"'Sender' | translate\" [formControl]=\"sendername\" #sender />\r\n <mat-autocomplete #senders [displayWith]=\"displayName\" (optionSelected)=\"senderSelected($event)\">\r\n @for (u of senders$ | async; track u.id) {\r\n <mat-option [value]=\"u\">\r\n <span>{{u.name}}</span>\r\n </mat-option>\r\n }\r\n </mat-autocomplete>\r\n @if (sendername.value) {\r\n <button matSuffix mat-icon-button (click)=\"clearSender()\"><mat-icon>clear</mat-icon></button>\r\n }\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-select [placeholder]=\"'Status'|translate\" formControlName=\"stateId\" multiple>\r\n <mat-option>\r\n {{ 'All' | translate }}\r\n </mat-option>\r\n @for (s of states; track s.name) {\r\n <mat-option [value]=\"s.name\">\r\n {{s.title}}\r\n </mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-select [placeholder]=\"'Form' | translate\" formControlName=\"formId\">\r\n <mat-option>\r\n {{ 'All' | translate }}\r\n </mat-option>\r\n @for (f of forms; track f.name) {\r\n <mat-option [value]=\"f.name\">{{f.title}}</mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-label>{{'Received' | translate}}</mat-label>\r\n <mat-date-range-input [rangePicker]=\"datePicker\" [formGroup]=\"form\">\r\n <input matStartDate [placeholder]=\"'StartDate'| translate\" formControlName=\"fromDate\">\r\n <input matEndDate [placeholder]=\"'EndDate' | translate\" formControlName=\"toDate\">\r\n </mat-date-range-input>\r\n <mat-datepicker-toggle matIconSuffix [for]=\"datePicker\"></mat-datepicker-toggle>\r\n <mat-date-range-picker #datePicker></mat-date-range-picker>\r\n </mat-form-field>\r\n <mat-chip-listbox id=\"tags\" [multiple]=true formControlName=\"tags\">\r\n @for (tag of tags; track tag.name) {\r\n <mat-chip-option [value]=\"tag.name\" [highlighted]=false>\r\n @if(tag.icon) {\r\n <mat-icon matChipAvatar>{{tag.icon}}</mat-icon>\r\n }\r\n {{tag.title || tag.name}}\r\n </mat-chip-option>\r\n }\r\n </mat-chip-listbox>\r\n @if (filters) {\r\n <bizdoc-cube-filter class=\"cube-filter\"\r\n [cube]=\"filters.cube\"\r\n [include]=\"filters.axes\"\r\n [axes]=\"values\"\r\n [autofocus]=\"false\"\r\n (axesChange)=\"axesChange($event)\"></bizdoc-cube-filter>\r\n }\r\n</form>\r\n", styles: [".cube-filter ::ng-deep form{padding:0}\n"] }]
8221
- }], ctorParameters: () => [{ type: i1$2.FormBuilder }, { type: SessionService }, { type: i0.ChangeDetectorRef }, { type: MailboxService }, { type: AccountService }, { type: undefined, decorators: [{
8229
+ args: [{ standalone: false, selector: 'bizdoc-browse-filter', template: "<form [formGroup]=\"form\" class=\"column gap\" autocomplete=\"off\">\r\n <!--@if (!exclude || exclude.indexOf('contains') < 0) {\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <input matInput formControlName=\"contains\" [placeholder]=\"'Contains' | translate\" #contains>\r\n @if (form.value.contains) {\r\n <button matSuffix mat-icon-button aria-label=\"\" (click)=\"form.controls.contains.setValue(null)\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n }\r\n </mat-form-field>\r\n }-->\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <input matInput [matAutocomplete]=\"senders\" [placeholder]=\"'Sender' | translate\" [formControl]=\"sendername\" #sender />\r\n <mat-autocomplete #senders [displayWith]=\"displayFn\" (optionSelected)=\"senderSelected($event)\">\r\n @for (u of senders$ | async; track u.id) {\r\n <mat-option [value]=\"u\">\r\n <span>{{u.name}}</span>\r\n </mat-option>\r\n }\r\n </mat-autocomplete>\r\n @if (sendername.value) {\r\n <button matSuffix mat-icon-button (click)=\"clearSender()\"><mat-icon>clear</mat-icon></button>\r\n }\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-select [placeholder]=\"'Status'|translate\" formControlName=\"stateId\" multiple>\r\n <!--<mat-option>\r\n {{ 'All' | translate }}\r\n </mat-option>-->\r\n @for (s of states; track s.name) {\r\n <mat-option [value]=\"s.name\">\r\n {{s.title}}\r\n </mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-select [placeholder]=\"'Form' | translate\" formControlName=\"formId\">\r\n <mat-option>\r\n {{ 'All' | translate }}\r\n </mat-option>\r\n @for (f of forms; track f.name) {\r\n <mat-option [value]=\"f.name\">{{f.title}}</mat-option>\r\n }\r\n </mat-select>\r\n </mat-form-field>\r\n <mat-form-field subscriptSizing=\"dynamic\">\r\n <mat-label>{{'Received' | translate}}</mat-label>\r\n <mat-date-range-input [rangePicker]=\"datePicker\" [formGroup]=\"form\">\r\n <input matStartDate [placeholder]=\"'StartDate'| translate\" formControlName=\"fromDate\">\r\n <input matEndDate [placeholder]=\"'EndDate' | translate\" formControlName=\"toDate\">\r\n </mat-date-range-input>\r\n <mat-datepicker-toggle matIconSuffix [for]=\"datePicker\"></mat-datepicker-toggle>\r\n <mat-date-range-picker #datePicker></mat-date-range-picker>\r\n </mat-form-field>\r\n <mat-chip-listbox id=\"tags\" [multiple]=true formControlName=\"tags\">\r\n @for (tag of tags; track tag.name) {\r\n <mat-chip-option [value]=\"tag.name\" [highlighted]=false>\r\n @if(tag.icon) {\r\n <mat-icon matChipAvatar>{{tag.icon}}</mat-icon>\r\n }\r\n {{tag.title || tag.name}}\r\n </mat-chip-option>\r\n }\r\n </mat-chip-listbox>\r\n @if (filters) {\r\n <bizdoc-cube-filter class=\"cube-filter\"\r\n [cube]=\"filters.cube\"\r\n [include]=\"filters.axes\"\r\n [axes]=\"values\"\r\n [autofocus]=\"false\"\r\n (axesChange)=\"axesChange($event)\"></bizdoc-cube-filter>\r\n }\r\n</form>\r\n", styles: [".cube-filter ::ng-deep form{padding:0}\n"] }]
8230
+ }], ctorParameters: () => [{ type: i1$2.FormBuilder }, { type: SessionService }, { type: MailboxService }, { type: AccountService }, { type: undefined, decorators: [{
8222
8231
  type: Inject,
8223
8232
  args: [BIZDOC_CONFIG]
8224
8233
  }] }], propDecorators: { values: [{
@@ -8234,10 +8243,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
8234
8243
  args: [MatChipListbox, { static: true }]
8235
8244
  }], containsEl: [{
8236
8245
  type: ViewChild,
8237
- args: ['contains', { static: true, read: ElementRef }]
8246
+ args: ['contains', { static: true, read: MatInput }]
8238
8247
  }], senderEl: [{
8239
8248
  type: ViewChild,
8240
- args: ['sender', { static: true, read: ElementRef }]
8249
+ args: ['sender', { static: true, read: MatInput }]
8241
8250
  }] } });
8242
8251
 
8243
8252
  /** */
@@ -8352,23 +8361,23 @@ class ChatInfo {
8352
8361
  this._nav(userId, contact, options);
8353
8362
  }
8354
8363
  _nav(userId, contact, options) {
8355
- if (this._config && this._config.app) {
8356
- const { app } = this._config;
8357
- if (isString(app)) {
8358
- 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}`;
8359
8368
  // const anchor = document.createElement('a');
8360
8369
  // anchor.href = app.formatArgs(userId);
8361
8370
  // anchor.style.display = 'none';
8362
8371
  // anchor.target = '_blank';
8363
8372
  // document.appendChild(anchor);
8364
8373
  // anchor.click();
8365
- window.open(url, '_blank');
8374
+ window.open(path, '_blank');
8366
8375
  }
8367
8376
  else
8368
8377
  this._account.get(userId).subscribe(p => {
8369
- const url = app(p);
8370
- isString(url) &&
8371
- window.open(url, '_blank');
8378
+ const path = url(p);
8379
+ isString(path) &&
8380
+ window.open(path, '_blank');
8372
8381
  });
8373
8382
  }
8374
8383
  else if (this._isMobile)
@@ -9348,7 +9357,7 @@ class BrowseItemsComponent {
9348
9357
  this._retrieve(mail).subscribe(item => {
9349
9358
  if (item.tags && item.tags.indexOf(tag) > -1)
9350
9359
  return;
9351
- this._mailbox.updateRecipientTags(mail.id, item.tags).subscribe(() => {
9360
+ this._mailbox.updateTags(mail.id, item.tags).subscribe(() => {
9352
9361
  if (!item.tags)
9353
9362
  item.tags = [tag];
9354
9363
  else
@@ -9745,7 +9754,7 @@ class TagsComponent {
9745
9754
  setTimeout(() => this.inputElement.nativeElement.focus());
9746
9755
  }
9747
9756
  _save() {
9748
- this._mailbox.updateRecipientTags(this._data.id, this._data.tags.map(t => t.name)).subscribe();
9757
+ this._mailbox.updateTags(this._data.id, this._data.tags.map(t => t.name)).subscribe();
9749
9758
  }
9750
9759
  add(event) {
9751
9760
  if (!this.auto.isOpen) {
@@ -13540,7 +13549,7 @@ class CommentComponent {
13540
13549
  return this._popup.open(component, this.bodyElement, { position: 'start', data });
13541
13550
  }
13542
13551
  delete(value) {
13543
- this._mailbox.toggleRemoveComment(this.item.id, value).subscribe({
13552
+ this._mailbox.toggleCommentHide(this.item.id, value).subscribe({
13544
13553
  next: () => {
13545
13554
  this.item.deleted = value;
13546
13555
  this.deleted.emit(value);
@@ -18271,7 +18280,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
18271
18280
  }], ctorParameters: () => [{ type: i0.ViewContainerRef }] });
18272
18281
 
18273
18282
  class NotificationsService {
18274
- constructor(_http, messaging, _session) {
18283
+ constructor(_http, _session) {
18275
18284
  this._http = _http;
18276
18285
  this._session = _session;
18277
18286
  }
@@ -18292,13 +18301,14 @@ class NotificationsService {
18292
18301
  params
18293
18302
  });
18294
18303
  }
18295
- read(id, date, read) {
18304
+ markAsRead(id, date, read) {
18296
18305
  return this._http.put(`/api/notifications/${id}?read=${read}`, {}, { headers: { 'no-progress': 'true' } }).pipe(tap(() => {
18297
- if (this._session.isAboveWatermark(date)) {
18298
- if (!this._session.profile.messagesCount)
18299
- this._session.profile.messagesCount = 0;
18300
- this._session.profile.messagesCount--;
18301
- }
18306
+ const { messagesCount, options: { notificationsView } } = this._session.profile;
18307
+ if (!this._session.isImpersonating &&
18308
+ notificationsView !== undefined &&
18309
+ notificationsView < date)
18310
+ this._session.profile.messagesCount = !messagesCount ? 0 :
18311
+ messagesCount - 1;
18302
18312
  }));
18303
18313
  }
18304
18314
  get(id) {
@@ -18310,13 +18320,13 @@ class NotificationsService {
18310
18320
  delete(id) {
18311
18321
  return this._http.delete(`/api/notifications/${id}`);
18312
18322
  }
18313
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: NotificationsService, deps: [{ token: i1.HttpClient }, { token: HubService }, { token: SessionService }], target: i0.ɵɵFactoryTarget.Injectable }); }
18323
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: NotificationsService, deps: [{ token: i1.HttpClient }, { token: SessionService }], target: i0.ɵɵFactoryTarget.Injectable }); }
18314
18324
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: NotificationsService, providedIn: 'root' }); }
18315
18325
  }
18316
18326
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: NotificationsService, decorators: [{
18317
18327
  type: Injectable,
18318
18328
  args: [{ providedIn: 'root' }]
18319
- }], ctorParameters: () => [{ type: i1.HttpClient }, { type: HubService }, { type: SessionService }] });
18329
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: SessionService }] });
18320
18330
 
18321
18331
  class NotificationsComponentBase {
18322
18332
  constructor() {
@@ -18419,7 +18429,7 @@ class NotificationsTableComponent extends NotificationsComponentBase {
18419
18429
  }
18420
18430
  read(item, read) {
18421
18431
  if (item.read !== read)
18422
- this._service.read(item.id, item.sent, read).subscribe(() => item.read = read);
18432
+ this._service.markAsRead(item.id, item.sent, read).subscribe(() => item.read = read);
18423
18433
  }
18424
18434
  isMuted(item) {
18425
18435
  return this._service.get(item.id).pipe(map(i => i.muted));
@@ -19450,7 +19460,7 @@ class HomeBase {
19450
19460
  this.profile = this._session.profile;
19451
19461
  this.schedulerEnabled = config.scheduler !== false;
19452
19462
  this.chatEnabled = config.chat !== false &&
19453
- (!config.chat || !config.chat.app);
19463
+ (!config.chat || !config.chat.url);
19454
19464
  if (config.appLogo) {
19455
19465
  this.appLogo = inject(DomSanitizer).bypassSecurityTrustResourceUrl(config.appLogo);
19456
19466
  }
@@ -19464,43 +19474,29 @@ class HomeBase {
19464
19474
  const { model: { formId: name, subject, number, pending } } = m;
19465
19475
  if (!pending)
19466
19476
  return;
19467
- const form = this._session.profile.forms.find(f => f.name === name), msg = this._translate.get('NewMail', form.title, number, subject || '');
19468
- this._snackBar.open(msg, m.userId === this._session.profile.userId ? this._translate.get('OpenNew') : undefined, {
19477
+ const { userId, forms, options: { notifications } } = this._session.profile;
19478
+ const form = forms.find(f => f.name === name), msg = this._translate.get('NewMail', form.title, number, subject || ''), action = m.userId === userId ? this._translate.get('OpenNew') : undefined;
19479
+ this._snackBar.open(msg, action, {
19469
19480
  duration: 5000,
19470
19481
  direction: this._session.direction,
19471
19482
  politeness: 'assertive'
19472
- }).onAction().subscribe(() => this.onNewMessage(m.model));
19473
- this._session.profile.options.notifications.sound &&
19483
+ }).onAction().subscribe(() => this.navToMessage(m.model));
19484
+ notifications.sound &&
19474
19485
  playAudio('notification_simple-01');
19475
19486
  });
19487
+ //
19476
19488
  this._messaging.notify$.subscribe(n => {
19477
- this._session.profile.options.notifications.sound &&
19478
- playAudio('notification_simple-01');
19479
- this._session.profile.messages.push(n.model);
19480
- if (!this._session.profile.messagesCount)
19481
- this._session.profile.messagesCount = 0;
19482
- this._session.profile.messagesCount++;
19483
- });
19484
- this._messaging.updateNotify$.subscribe(e => {
19485
- const item = this._session.profile.messages.find(n => n.id === e.model.id);
19486
- if (item)
19487
- Object.assign(item, e.model);
19488
- else
19489
- this._session.profile.messages.push(e.model);
19490
- if (e.originalRead !== undefined && e.model.read !== e.originalRead &&
19491
- this._session.isAboveWatermark(e.model.sent)) {
19492
- const val = e.model.read ? -1 : 1;
19493
- if (!this._session.profile.messagesCount)
19494
- this._session.profile.messagesCount = 0;
19495
- this._session.profile.messagesCount += val;
19496
- }
19489
+ const { options: { notifications }, messages, messagesCount } = this._session.profile;
19490
+ notifications.sound && playAudio('notification_simple-01');
19497
19491
  });
19492
+ //
19498
19493
  if (this._session.isImpersonating)
19499
19494
  this._snackBar.open(this._translate.get('Impersonating', this._session.profile.name), undefined, {
19500
19495
  duration: TOAST_DURATION,
19501
19496
  verticalPosition: 'top',
19502
19497
  direction: this._session.direction
19503
19498
  });
19499
+ //
19504
19500
  else if (this._session.isOutOfOffice) {
19505
19501
  const options = this._session.profile.options.outOfOffice;
19506
19502
  this._snackBar.openFromComponent(OutOfOfficeToast, {
@@ -19597,7 +19593,7 @@ class QuickNotificationsComponent extends NotificationsComponentBase {
19597
19593
  open(item, evt) {
19598
19594
  if (evt.target.tagName !== 'MAT-ICON') {
19599
19595
  if (!item.read)
19600
- this._service.read(item.id, item.sent, true).subscribe(() => item.read = true);
19596
+ this._service.markAsRead(item.id, item.sent, true).subscribe(() => item.read = true);
19601
19597
  this._popupRef.close();
19602
19598
  }
19603
19599
  }
@@ -21336,7 +21332,7 @@ class HomeComponent extends HomeBase {
21336
21332
  this.subMenu = null;
21337
21333
  this.collapseSubMenu();
21338
21334
  }
21339
- onNewMessage(model) {
21335
+ navToMessage(model) {
21340
21336
  this._router.navigate(['mailbox/i', model.id.encodeId()], {
21341
21337
  state: { item: model },
21342
21338
  policy: OpenPolicy.Clear
@@ -21638,7 +21634,7 @@ class HomeMobileComponent extends HomeBase {
21638
21634
  setTimeout(() => this.composeState = 'done', 500);
21639
21635
  });
21640
21636
  }
21641
- onNewMessage(model) {
21637
+ navToMessage(model) {
21642
21638
  this._router.navigate(['mailbox/i', model.id.encodeId()], {
21643
21639
  state: { item: model }
21644
21640
  });
@@ -27372,188 +27368,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
27372
27368
  type: Input
27373
27369
  }] } });
27374
27370
 
27375
- const TIME_FORMAT = /\d{1,2}:\d{1,2}/, DATE_FORMAT = /\d{4}-\d\d-\d\dT\d\d:\d{2}/;
27376
- function generateValues() {
27377
- const times = [];
27378
- let h = 0;
27379
- while (h < 24) {
27380
- let m = 0;
27381
- while (m < 60) {
27382
- times.push(`${h}:${m}`);
27383
- m += 15;
27384
- }
27385
- h++;
27386
- }
27387
- return times;
27388
- }
27389
- class TimePicker {
27390
- static { this.nextId = 0; }
27391
- get empty() {
27392
- const value = this.control.value;
27393
- return !value;
27394
- }
27395
- get shouldLabelFloat() { return this.focused || !this.empty; }
27396
- get placeholder() { return this._placeholder; }
27397
- set placeholder(value) {
27398
- this._placeholder = value;
27399
- this.stateChanges.next();
27400
- }
27401
- get required() { return this._required; }
27402
- set required(value) {
27403
- this._required = coerceBooleanProperty(value);
27404
- this.stateChanges.next();
27405
- }
27406
- get disabled() { return this._disabled; }
27407
- set disabled(value) {
27408
- this._disabled = coerceBooleanProperty(value);
27409
- this._disabled ? this.control.disable() : this.control.enable();
27410
- this.stateChanges.next();
27411
- }
27412
- get value() {
27413
- const value = this.control.value;
27414
- return value;
27415
- }
27416
- set value(val) {
27417
- this._setValue(val, true);
27418
- this.stateChanges.next();
27419
- }
27420
- _setValue(val, emitEvent) {
27421
- if (val) {
27422
- if (isDate(val) || DATE_FORMAT.test(val)) {
27423
- val = new Date(val);
27424
- this.control.setValue(val.getHours() + ':' + val.getMinutes(), { emitEvent });
27425
- }
27426
- else
27427
- this.control.setValue(TIME_FORMAT.exec(val)[0], { emitEvent });
27428
- }
27429
- else
27430
- this.control.reset();
27431
- }
27432
- constructor(_focusMonitor, _elementRef, ngControl) {
27433
- this._focusMonitor = _focusMonitor;
27434
- this._elementRef = _elementRef;
27435
- this.ngControl = ngControl;
27436
- this.controlType = 'time-picker';
27437
- this.id = `time-picker-${TimePicker.nextId++}`;
27438
- this.focused = false;
27439
- this.errorState = false;
27440
- this.describedBy = '';
27441
- this.onChange = (_) => { };
27442
- this.onTouched = () => { };
27443
- this._required = false;
27444
- this._disabled = false;
27445
- this.control = new FormControl(null);
27446
- this.stateChanges = new Subject();
27447
- this.options = generateValues();
27448
- this._destroy = new Subject();
27449
- _focusMonitor.monitor(_elementRef, true).subscribe(origin => {
27450
- if (this.focused && !origin) {
27451
- this.onTouched();
27452
- }
27453
- this.focused = !!origin;
27454
- this.stateChanges.next();
27455
- });
27456
- if (this.ngControl != null) {
27457
- this.ngControl.valueAccessor = this;
27458
- }
27459
- }
27460
- setDescribedByIds(ids) {
27461
- this.describedBy = ids.join(' ');
27462
- }
27463
- onContainerClick(event) {
27464
- if (event.target.tagName !== 'INPUT')
27465
- this._elementRef.nativeElement.querySelector('input').focus();
27466
- }
27467
- writeValue(val) {
27468
- this._setValue(val, false);
27469
- }
27470
- registerOnChange(fn) {
27471
- this.onChange = fn;
27472
- }
27473
- registerOnTouched(fn) {
27474
- this.onTouched = fn;
27475
- }
27476
- setDisabledState(isDisabled) {
27477
- this.disabled = isDisabled;
27478
- }
27479
- ngOnInit() {
27480
- this.control.valueChanges.pipe(takeUntil(this._destroy)).
27481
- subscribe(v => {
27482
- this.errorState = !this._validate(v);
27483
- if (v && !this.errorState && this.dateControlName) {
27484
- const date = this._dateControl?.value;
27485
- date && this._appendTime(date);
27486
- }
27487
- this.onChange(this.value);
27488
- });
27489
- if (this.dateControlName) {
27490
- this._dateControl = this.ngControl.control.parent.get(this.dateControlName);
27491
- if (!this._dateControl)
27492
- throw `${this.controlType} dateControlName ${this.dateControlName}`;
27493
- this._dateControl.valueChanges.pipe(takeUntil(this._destroy)).
27494
- subscribe((v) => {
27495
- v && this.value && this._appendTime(v);
27496
- });
27497
- }
27498
- }
27499
- _appendTime(val) {
27500
- if (!isDate(val))
27501
- val = new Date(val);
27502
- const parts = this.value.split(':');
27503
- val.setHours(parseInt(parts[0]), parseInt(parts[1]));
27504
- this._dateControl?.setValue(val.toISOString(), { emitEvent: false });
27505
- }
27506
- _validate(val) {
27507
- if (!val)
27508
- return !this._required;
27509
- const parts = val.split(':');
27510
- if (parts.length > 2)
27511
- return false;
27512
- for (let i = 0; i < parts.length; i++) {
27513
- if (!/\d{1,2}/.test(parts[i]))
27514
- return false;
27515
- const part = parseInt(parts[i]);
27516
- if (isNaN(part))
27517
- return false;
27518
- else if (i === 0 && (part < 0 || part > 23))
27519
- return false;
27520
- else if (i === 1 && (part < 0 || part > 59))
27521
- return false;
27522
- }
27523
- return true;
27524
- }
27525
- ngOnDestroy() {
27526
- this.stateChanges.complete();
27527
- this._focusMonitor.stopMonitoring(this._elementRef);
27528
- this._destroy.next();
27529
- this._destroy.complete();
27530
- }
27531
- 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 }); }
27532
- 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"] }] }); }
27533
- }
27534
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: TimePicker, decorators: [{
27535
- type: Component,
27536
- args: [{ standalone: false, selector: 'mat-time-picker', providers: [{ provide: MatFormFieldControl, useExisting: TimePicker }], host: {
27537
- '[class.floating]': 'shouldLabelFloat',
27538
- '[id]': 'id',
27539
- '[attr.aria-describedby]': 'describedBy'
27540
- }, 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" }]
27541
- }], ctorParameters: () => [{ type: i2$9.FocusMonitor }, { type: i0.ElementRef }, { type: i1$2.NgControl, decorators: [{
27542
- type: Optional
27543
- }, {
27544
- type: Self
27545
- }] }], propDecorators: { dateControlName: [{
27546
- type: Input
27547
- }], placeholder: [{
27548
- type: Input
27549
- }], required: [{
27550
- type: Input
27551
- }], disabled: [{
27552
- type: Input
27553
- }], value: [{
27554
- type: Input
27555
- }] } });
27556
-
27557
27371
  const COMBINATION_PICKER_BODY = new InjectionToken('combination_body');
27558
27372
  /** */
27559
27373
  class CombinationPickerBody {
@@ -30745,14 +30559,14 @@ let TimeField = class TimeField {
30745
30559
  this.max && this.control.addValidators(Validators.max(this.max));
30746
30560
  }
30747
30561
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: TimeField, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
30748
- 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" }] }); }
30749
30563
  };
30750
30564
  TimeField = __decorate([
30751
30565
  BizDoc({ selector: 'time-control' })
30752
30566
  ], TimeField);
30753
30567
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: TimeField, decorators: [{
30754
30568
  type: Component,
30755
- 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" }]
30756
30570
  }], propDecorators: { input: [{
30757
30571
  type: ViewChild,
30758
30572
  args: [MatInput]
@@ -31257,24 +31071,18 @@ const CONTROLS_COMPONENTS$1 = [SignatureField, AddressField, ChecklistField, Rad
31257
31071
  /** common BizDoc components */
31258
31072
  class SharedModule {
31259
31073
  static forChild(config) {
31260
- const { formats, routingEngine, routes } = config || {};
31261
- routes && PANES_CONFIG.push(...routes);
31262
- const providers = [{
31263
- provide: MAT_DATE_FORMATS, useValue: {
31264
- parse: {
31265
- dateInput: 'LL',
31266
- },
31267
- display: {
31268
- dateInput: (formats || {}).date || 'll',
31269
- monthYearLabel: 'MMM YYYY',
31270
- dateA11yLabel: 'LL',
31271
- monthYearA11yLabel: 'MMMM YYYY',
31272
- }
31273
- }
31274
- }];
31275
- if (routingEngine)
31074
+ const { components, formats, routingEngine } = config || {};
31075
+ components && registerComponents(components);
31076
+ const providers = [
31077
+ {
31078
+ provide: BIZDOC_CONFIG,
31079
+ useValue: config
31080
+ },
31081
+ materialFormatsProvider(formats)
31082
+ ];
31083
+ routingEngine &&
31276
31084
  providers.push({
31277
- provide: RouterImpl, useClass: routingEngine === 'ng' ? NgRouter : PaneRouter
31085
+ provide: RouterImpl, useClass: NgRouter
31278
31086
  });
31279
31087
  return {
31280
31088
  ngModule: SharedModule,
@@ -31304,7 +31112,6 @@ class SharedModule {
31304
31112
  TypeSelect, TypeAutocomplete, Signature,
31305
31113
  AceInput, TimespanInput, AddressInput,
31306
31114
  FileInput,
31307
- TimePicker,
31308
31115
  LayoutComponent, StickyToolbar, VirtualTabs, Tab,
31309
31116
  TimeField, SignatureField, AddressField, RadioButtonField, ChecklistField, AxesPickerField, YesNoField, HtmlField, FileField, NumericField, AutocompleteField, CheckboxField, DateField, DateRangeField, ExpressionField,
31310
31117
  InputField, SelectField, SwitchField, TextareaField, ChipsField, TimespanField,
@@ -31406,7 +31213,6 @@ class SharedModule {
31406
31213
  AceInput,
31407
31214
  CombinationPicker, CombinationPool,
31408
31215
  TypeSelect, TypeAutocomplete,
31409
- TimePicker,
31410
31216
  DurationFormatPipe,
31411
31217
  DateRangePipe,
31412
31218
  TypeValuePipe,
@@ -31497,7 +31303,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
31497
31303
  TypeSelect, TypeAutocomplete, Signature,
31498
31304
  AceInput, TimespanInput, AddressInput,
31499
31305
  FileInput,
31500
- TimePicker,
31501
31306
  LayoutComponent, StickyToolbar, VirtualTabs, Tab,
31502
31307
  TimeField, SignatureField, AddressField, RadioButtonField, ChecklistField, AxesPickerField, YesNoField, HtmlField, FileField, NumericField, AutocompleteField, CheckboxField, DateField, DateRangeField, ExpressionField,
31503
31308
  InputField, SelectField, SwitchField, TextareaField, ChipsField, TimespanField,
@@ -31620,7 +31425,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
31620
31425
  AceInput,
31621
31426
  CombinationPicker, CombinationPool,
31622
31427
  TypeSelect, TypeAutocomplete,
31623
- TimePicker,
31624
31428
  DurationFormatPipe,
31625
31429
  DateRangePipe,
31626
31430
  TypeValuePipe,
@@ -31649,6 +31453,21 @@ registerComponents(CORE_COMPONENTS);
31649
31453
  registerComponents(CONTROLS_COMPONENTS$1);
31650
31454
  /* Syncfusion 30.x */
31651
31455
  registerLicense('Ngo9BigBOggjHTQxAR8/V1JEaF5cXmRCf1FpRmJGdld5fUVHYVZUTXxaS00DNHVRdkdmWXhecXRdRmdYWUVyW0FWYEk=');
31456
+ function materialFormatsProvider(formats) {
31457
+ return {
31458
+ provide: MAT_DATE_FORMATS, useValue: {
31459
+ parse: {
31460
+ dateInput: 'LL',
31461
+ },
31462
+ display: {
31463
+ dateInput: (formats || {}).date || 'll',
31464
+ monthYearLabel: 'MMM YYYY',
31465
+ dateA11yLabel: 'LL',
31466
+ monthYearA11yLabel: 'MMMM YYYY',
31467
+ }
31468
+ }
31469
+ };
31470
+ }
31652
31471
 
31653
31472
  class MobileModule {
31654
31473
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: MobileModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
@@ -37885,50 +37704,30 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
37885
37704
 
37886
37705
  const DEFAULT_ROUTE = 'dashboard';
37887
37706
  class BizDocModule {
37888
- static forChild(config) {
37889
- const { components, routes } = config;
37890
- registerComponents(components);
37891
- routes && PANES_CONFIG.push(...routes);
37892
- return {
37893
- ngModule: BizDocModule,
37894
- providers: [
37895
- { provide: PANES_DATA, useValue: PANES_CONFIG }
37896
- ]
37897
- };
37898
- }
37899
37707
  static forRoot(config) {
37900
37708
  const { formats, routes, components, defaultRoute } = config;
37901
- registerComponents(components);
37709
+ components && registerComponents(components);
37902
37710
  const providers = [
37903
37711
  {
37904
37712
  provide: BIZDOC_CONFIG,
37905
37713
  useValue: config
37906
37714
  },
37907
- {
37908
- provide: MAT_DATE_FORMATS,
37909
- useValue: {
37910
- parse: {
37911
- dateInput: 'LL',
37912
- },
37913
- display: {
37914
- dateInput: (formats || {}).date || 'll',
37915
- monthYearLabel: 'MMM YYYY',
37916
- dateA11yLabel: 'LL',
37917
- monthYearA11yLabel: 'MMMM YYYY',
37918
- }
37919
- }
37920
- },
37715
+ materialFormatsProvider(formats),
37921
37716
  ];
37922
37717
  const redirectTo = defaultRoute ? isString(defaultRoute) ? defaultRoute : defaultRoute() : DEFAULT_ROUTE;
37923
37718
  if (isMobile()) {
37924
37719
  routes && MOBILE_CONFIG.push(...routes);
37925
37720
  MOBILE_CONFIG.push({ path: '', redirectTo, pathMatch: 'full' });
37926
- providers.push(provideRouter(MOBILE_CONFIG, withEnabledBlockingInitialNavigation()));
37721
+ providers.push(provideRouter(MOBILE_CONFIG, withEnabledBlockingInitialNavigation()), {
37722
+ provide: RouterImpl, useClass: NgRouter
37723
+ });
37927
37724
  }
37928
37725
  else {
37929
37726
  routes && PANES_CONFIG.push(...routes);
37930
37727
  PANES_CONFIG.push({ path: '', redirectTo });
37931
- providers.push({ provide: PANES_DATA, useValue: PANES_CONFIG });
37728
+ providers.push({ provide: PANES_DATA, useValue: PANES_CONFIG }, {
37729
+ provide: RouterImpl, useClass: PaneRouter
37730
+ });
37932
37731
  }
37933
37732
  return {
37934
37733
  ngModule: BizDocModule,
@@ -37947,7 +37746,7 @@ class BizDocModule {
37947
37746
  MobileModule,
37948
37747
  DesktopModule,
37949
37748
  SystemModule.forChild(),
37950
- SharedModule.forChild({ routingEngine: isMobile() ? 'ng' : 'pane' }), SharedModule,
37749
+ SharedModule, SharedModule,
37951
37750
  MaterialModule] }); }
37952
37751
  }
37953
37752
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImport: i0, type: BizDocModule, decorators: [{
@@ -37962,7 +37761,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
37962
37761
  MobileModule,
37963
37762
  DesktopModule,
37964
37763
  SystemModule.forChild(),
37965
- SharedModule.forChild({ routingEngine: isMobile() ? 'ng' : 'pane' })
37764
+ SharedModule
37966
37765
  ],
37967
37766
  providers: [],
37968
37767
  exports: [
@@ -37991,5 +37790,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.2", ngImpor
37991
37790
  * Generated bundle index. Do not edit.
37992
37791
  */
37993
37792
 
37994
- 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 };
37793
+ 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 };
37995
37794
  //# sourceMappingURL=bizdoc-core.mjs.map