nuxeo-development-framework 4.0.0 → 4.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/nuxeo-development-framework.umd.js +54 -27
- package/bundles/nuxeo-development-framework.umd.js.map +1 -1
- package/esm2015/lib/components/dynamic-form/components/dynamic-form-department/services/department-api.service.js +25 -2
- package/esm2015/lib/components/notifications/components/notification-item/notification-item.component.js +1 -1
- package/esm2015/lib/components/notifications/components/notifications-button/notifications-button.component.js +23 -21
- package/esm2015/lib/components/notifications/components/notifications-settings/check-if-subscribed.pipe.js +4 -3
- package/esm2015/lib/components/notifications/components/notifications-settings/notifications-settings.adapter.js +2 -2
- package/esm2015/lib/components/notifications/models/notification-setting.presenter.js +1 -1
- package/esm2015/lib/components/notifications/services/notifications.service.js +3 -3
- package/fesm2015/nuxeo-development-framework.js +53 -27
- package/fesm2015/nuxeo-development-framework.js.map +1 -1
- package/lib/components/dynamic-form/components/dynamic-form-department/services/department-api.service.d.ts +1 -0
- package/lib/components/notifications/components/notifications-button/notifications-button.component.d.ts +1 -0
- package/lib/components/notifications/models/notification-setting.presenter.d.ts +1 -1
- package/package.json +1 -1
|
@@ -7011,6 +7011,23 @@ class DepartmentApiService {
|
|
|
7011
7011
|
return treeItem;
|
|
7012
7012
|
});
|
|
7013
7013
|
}
|
|
7014
|
+
getFullDepartmentTree(customPageProvider, customParams) {
|
|
7015
|
+
let obj = customParams ? customParams : {};
|
|
7016
|
+
let params = Object.assign({ pageProvider: customPageProvider ? customPageProvider : 'PP_Department', currentPageIndex: 0, offset: 0, pageSize: 40, quickFilters: 'Parent Dept' }, obj);
|
|
7017
|
+
if (this.globalAdminService.isGlobalAdmin) {
|
|
7018
|
+
params['queryParams'] = this.globalAdminService.activeTenant;
|
|
7019
|
+
}
|
|
7020
|
+
else if (!this.globalAdminService.isGlobalAdmin && this.nuxeoService.nuxeoClient.user.properties.tenantId) {
|
|
7021
|
+
params['queryParams'] = this.nuxeoService.nuxeoClient.user.properties.tenantId;
|
|
7022
|
+
}
|
|
7023
|
+
return this.CallApiService.query(Object.assign({}, params), {
|
|
7024
|
+
headers: {
|
|
7025
|
+
'X-NXproperties': '*',
|
|
7026
|
+
'enrichers-document': 'children',
|
|
7027
|
+
depth: 'max',
|
|
7028
|
+
},
|
|
7029
|
+
});
|
|
7030
|
+
}
|
|
7014
7031
|
}
|
|
7015
7032
|
DepartmentApiService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: DepartmentApiService, deps: [{ token: CallApiService }, { token: TranslationService }, { token: NuxeoService }, { token: AdapterService }, { token: GlobalAdminService }, { token: 'environment' }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
7016
7033
|
DepartmentApiService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: DepartmentApiService, providedIn: 'root' });
|
|
@@ -7052,6 +7069,12 @@ __decorate([
|
|
|
7052
7069
|
cacheBusterNotifier: departmentCacheBuster$,
|
|
7053
7070
|
})
|
|
7054
7071
|
], DepartmentApiService.prototype, "updateDepartment", null);
|
|
7072
|
+
__decorate([
|
|
7073
|
+
Cacheable({
|
|
7074
|
+
cacheBusterObserver: departmentCacheBuster$,
|
|
7075
|
+
storageStrategy: LocalStorageStrategy
|
|
7076
|
+
})
|
|
7077
|
+
], DepartmentApiService.prototype, "getFullDepartmentTree", null);
|
|
7055
7078
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: DepartmentApiService, decorators: [{
|
|
7056
7079
|
type: Injectable,
|
|
7057
7080
|
args: [{
|
|
@@ -7060,7 +7083,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImpo
|
|
|
7060
7083
|
}], ctorParameters: function () { return [{ type: CallApiService }, { type: TranslationService }, { type: NuxeoService }, { type: AdapterService }, { type: GlobalAdminService }, { type: undefined, decorators: [{
|
|
7061
7084
|
type: Inject,
|
|
7062
7085
|
args: ['environment']
|
|
7063
|
-
}] }]; }, propDecorators: { getDepartmentTree: [], getDepartmentDetails: [], getDepartmentNestedTree: [], createDepartment: [], createDepartmentInRoot: [], updateDepartment: [] } });
|
|
7086
|
+
}] }]; }, propDecorators: { getDepartmentTree: [], getDepartmentDetails: [], getDepartmentNestedTree: [], createDepartment: [], createDepartmentInRoot: [], updateDepartment: [], getFullDepartmentTree: [] } });
|
|
7064
7087
|
|
|
7065
7088
|
var _DropdownTreeviewSelectI18n_defaultSelection;
|
|
7066
7089
|
/** @ignore */
|
|
@@ -27393,7 +27416,7 @@ class NotificationsService extends SocketService {
|
|
|
27393
27416
|
}
|
|
27394
27417
|
getDefinitions(payload = {}) {
|
|
27395
27418
|
return this._callApi
|
|
27396
|
-
.query(Object.assign({ pageProvider: NotificationsService.providers.definition, notfnotificationdef_applicationKey: this._appKey, pageSize:
|
|
27419
|
+
.query(Object.assign({ pageProvider: NotificationsService.providers.definition, notfnotificationdef_applicationKey: this._appKey, pageSize: Number.MAX_SAFE_INTEGER, notfnotificationdef_isActive: true }, payload), {
|
|
27397
27420
|
headers: {
|
|
27398
27421
|
properties: '*',
|
|
27399
27422
|
},
|
|
@@ -27402,7 +27425,7 @@ class NotificationsService extends SocketService {
|
|
|
27402
27425
|
}
|
|
27403
27426
|
getSubscriptions(payload = {}) {
|
|
27404
27427
|
return this._callApi
|
|
27405
|
-
.query(Object.assign({ pageProvider: NotificationsService.providers.subscription, notfsubscription_companyName: this._tenantId, notfsubscription_applicationKey: this._appKey, pageSize:
|
|
27428
|
+
.query(Object.assign({ pageProvider: NotificationsService.providers.subscription, notfsubscription_companyName: this._tenantId, notfsubscription_applicationKey: this._appKey, pageSize: Number.MAX_SAFE_INTEGER }, payload), {
|
|
27406
27429
|
headers: {
|
|
27407
27430
|
properties: '*',
|
|
27408
27431
|
},
|
|
@@ -27555,7 +27578,7 @@ class NotificationItemComponent extends DestroySubject {
|
|
|
27555
27578
|
}
|
|
27556
27579
|
}
|
|
27557
27580
|
NotificationItemComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: NotificationItemComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
27558
|
-
NotificationItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: NotificationItemComponent, selector: "app-notification-item", inputs: { iconOptions: "iconOptions", currentLang: "currentLang", notification: "notification" }, outputs: { markAsUnread: "markAsUnread", markAsRead: "markAsRead", markAsDeleted: "markAsDeleted" }, usesInheritance: true, ngImport: i0, template: "<div\r\n *ngIf=\"notification?.properties as properties\"\r\n class=\"notification-item\"\r\n [class.new-item]=\"properties['notif_cnt:status'] == status.new\"\r\n [class.unread-item]=\"properties['notif_cnt:status'] == status.unRead\"\r\n>\r\n <div class=\"notification-item__icon\">\r\n <div class=\"notification-item__icon__wrapper\" *ngIf=\"iconOptions?.active\">\r\n <i [class]=\"notification | getIcon : iconOptions\"></i>\r\n </div>\r\n </div>\r\n <div class=\"notification-item__content\">\r\n <p class=\"notification-item__message line-clamp-2\">\r\n {{\r\n currentLang === 'ar-AR'\r\n ? properties['notif_cnt:arMessage']\r\n : properties['notif_cnt:enMessage']\r\n }}\r\n </p>\r\n <button\r\n class=\"mat-icon-button\"\r\n [matMenuTriggerFor]=\"appMenu\"\r\n mat-icon-button\r\n (click)=\"$event.stopPropagation()\"\r\n >\r\n <mat-icon class=\"mat-24\">more_horiz</mat-icon>\r\n </button>\r\n <span class=\"notification-item__date\">{{\r\n properties['dc:created'] | timeAgo : currentLang\r\n }}</span>\r\n </div>\r\n\r\n <mat-menu class=\"notification-item__actions\" #appMenu=\"matMenu\">\r\n <span (click)=\"closeMenu($event, appMenu)\">\r\n <button\r\n *ngIf=\"properties['notif_cnt:status'] == status.read\"\r\n mat-menu-item\r\n class=\"notification-item__actions__item\"\r\n (click)=\"markAsUnread.emit(notification)\"\r\n >\r\n <span class=\"mx-1\">{{ 'notifications.markAsUnread' | translate }}</span>\r\n </button>\r\n\r\n <button\r\n *ngIf=\"\r\n properties['notif_cnt:status'] == status.new ||\r\n properties['notif_cnt:status'] == status.unRead\r\n \"\r\n mat-menu-item\r\n class=\"notification-item__actions__item\"\r\n (click)=\"markAsRead.emit(notification)\"\r\n >\r\n <span class=\"mx-1\">{{ 'notifications.markAsRead' | translate }}</span>\r\n </button>\r\n\r\n <button\r\n mat-menu-item\r\n (click)=\"markAsDeleted.emit(notification)\"\r\n class=\"notification-item__actions__item\"\r\n >\r\n <span>{{ 'notifications.delete' | translate }}</span>\r\n </button>\r\n </span>\r\n </mat-menu>\r\n</div>\r\n", styles: [".notification-item{display:var(--n-item-display, grid);grid-template-columns:var(--n-item-columns, auto 1fr);grid-gap:var(--n-item-gap, .5rem);gap:var(--n-item-gap, .5rem);padding:var(--n-items-padding, .5rem 1rem);border:var(--n-item-border, solid #eee);border-width:var(--n-item-border-width, 0 0 1px 0);background:var(--n-item-background, transparent);min-height:var(--n-item-height, 85px)}.notification-item.new-item{--n-item-background: var(--n-status-new-color, #
|
|
27581
|
+
NotificationItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: NotificationItemComponent, selector: "app-notification-item", inputs: { iconOptions: "iconOptions", currentLang: "currentLang", notification: "notification" }, outputs: { markAsUnread: "markAsUnread", markAsRead: "markAsRead", markAsDeleted: "markAsDeleted" }, usesInheritance: true, ngImport: i0, template: "<div\r\n *ngIf=\"notification?.properties as properties\"\r\n class=\"notification-item\"\r\n [class.new-item]=\"properties['notif_cnt:status'] == status.new\"\r\n [class.unread-item]=\"properties['notif_cnt:status'] == status.unRead\"\r\n>\r\n <div class=\"notification-item__icon\">\r\n <div class=\"notification-item__icon__wrapper\" *ngIf=\"iconOptions?.active\">\r\n <i [class]=\"notification | getIcon : iconOptions\"></i>\r\n </div>\r\n </div>\r\n <div class=\"notification-item__content\">\r\n <p class=\"notification-item__message line-clamp-2\">\r\n {{\r\n currentLang === 'ar-AR'\r\n ? properties['notif_cnt:arMessage']\r\n : properties['notif_cnt:enMessage']\r\n }}\r\n </p>\r\n <button\r\n class=\"mat-icon-button\"\r\n [matMenuTriggerFor]=\"appMenu\"\r\n mat-icon-button\r\n (click)=\"$event.stopPropagation()\"\r\n >\r\n <mat-icon class=\"mat-24\">more_horiz</mat-icon>\r\n </button>\r\n <span class=\"notification-item__date\">{{\r\n properties['dc:created'] | timeAgo : currentLang\r\n }}</span>\r\n </div>\r\n\r\n <mat-menu class=\"notification-item__actions\" #appMenu=\"matMenu\">\r\n <span (click)=\"closeMenu($event, appMenu)\">\r\n <button\r\n *ngIf=\"properties['notif_cnt:status'] == status.read\"\r\n mat-menu-item\r\n class=\"notification-item__actions__item\"\r\n (click)=\"markAsUnread.emit(notification)\"\r\n >\r\n <span class=\"mx-1\">{{ 'notifications.markAsUnread' | translate }}</span>\r\n </button>\r\n\r\n <button\r\n *ngIf=\"\r\n properties['notif_cnt:status'] == status.new ||\r\n properties['notif_cnt:status'] == status.unRead\r\n \"\r\n mat-menu-item\r\n class=\"notification-item__actions__item\"\r\n (click)=\"markAsRead.emit(notification)\"\r\n >\r\n <span class=\"mx-1\">{{ 'notifications.markAsRead' | translate }}</span>\r\n </button>\r\n\r\n <button\r\n mat-menu-item\r\n (click)=\"markAsDeleted.emit(notification)\"\r\n class=\"notification-item__actions__item\"\r\n >\r\n <span>{{ 'notifications.delete' | translate }}</span>\r\n </button>\r\n </span>\r\n </mat-menu>\r\n</div>\r\n", styles: [".notification-item{display:var(--n-item-display, grid);grid-template-columns:var(--n-item-columns, auto 1fr);grid-gap:var(--n-item-gap, .5rem);gap:var(--n-item-gap, .5rem);padding:var(--n-items-padding, .5rem 1rem);border:var(--n-item-border, solid #eee);border-width:var(--n-item-border-width, 0 0 1px 0);background:var(--n-item-background, transparent);min-height:var(--n-item-height, 85px);position:relative}.notification-item.new-item{--n-item-background: var(--n-status-new-color, #ecf8fe)}.notification-item.unread-item{--n-item-background: var(--n-status-unread-color, #ecf8fe)}.notification-item.unread-item:before{content:\"\";position:absolute;inset-inline-start:var(--n-item-unread-inline, 6px);inset-block-start:var(--n-item-unread-block, 6px);width:var(--n-item-unread-width, 8px);height:var(--n-item-unread-height, 8px);background:var(--n-item-unread-background, #39559d);border-radius:50%}.notification-item__icon{display:var(--n-item-icon-display, flex);align-items:var(--n-item-icon-align-items, center)}.notification-item__icon__wrapper{width:var(--n-item-icon-width, 56px);height:var(--n-item-icon-height, 56px);background:var(--n-item-icon-background, rgba(0, 0, 0, .025));color:var(--n-item-icon-color, #636363);font-size:var(--n-item-icon-size, 1.5rem);border-radius:var(--n-item-icon-radius, 50%);display:grid;place-items:center}.notification-item__content{display:var(--n-item-content-display, grid);grid-template-columns:var(--n-item-content-columns, 1fr auto);grid-gap:var(--n-item-gap, .2rem);gap:var(--n-item-gap, .2rem)}.notification-item__message{margin-bottom:0;font-size:var(--n-item-font-size, .9rem);color:var(--n-item-message-color)}.notification-item__date{font-size:var(--n-item-date-size, .8rem);text-align:var(--n-item-date-align, end);grid-column:var(--n-item-date-column, span 2);padding:var(--n-item-date-padding, 0 11px);color:var(--n-item-date-color)}.notification-item__actions{border-radius:var(--n-actions-radius, 4px);background:var(--n-actions-background, #fff);box-shadow:var(--n-actions-shadow, 0px 1px 4px -1px rgba(28, 52, 84, .26))}.notification-item__actions .mat-menu-content:not(:empty){padding:var(--n-actions--menu-padding, .5rem)}.notification-item__actions__item{text-align:var(--action-item-align, start)!important;background:var(--action-item-background, transparent)!important;color:var(--action-item-color, #28282d);padding:var(--action-item-padding, .4rem);height:var(--action-item-height, 38px);line-height:var(--action-item-line, 38px);border-radius:var(--action-item-radius, 4px);font-size:var(--action-item-size, 14px)}.notification-item__actions__item:hover{--action-item-background: var(--action-hover-background, #e6f7ff);--action-item-color: var(--action-hover-color, #005fdb)}\n"], components: [{ type: i1$8.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i2$3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i3$1.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i3$1.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }], directives: [{ type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$1.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["matMenuTriggerRestoreFocus", "mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }], pipes: { "getIcon": GetIconPipe, "timeAgo": TimeAgoPipe, "translate": i1$1.TranslatePipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
27559
27582
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: NotificationItemComponent, decorators: [{
|
|
27560
27583
|
type: Component,
|
|
27561
27584
|
args: [{
|
|
@@ -28296,31 +28319,14 @@ class NotificationsButtonComponent extends BaseNotification {
|
|
|
28296
28319
|
this.openSettings = new EventEmitter();
|
|
28297
28320
|
this.openNotifications = new EventEmitter();
|
|
28298
28321
|
this.onNotification = new EventEmitter();
|
|
28299
|
-
this.newNotificationCount$ = this._getCountSub
|
|
28300
|
-
.asObservable()
|
|
28301
|
-
.pipe(map((count) => (count >= 100 ? '99+' : count)));
|
|
28322
|
+
this.newNotificationCount$ = this._getCountSub.asObservable();
|
|
28302
28323
|
this.panelMode = PANEL_MODE.sidebar;
|
|
28303
28324
|
this.panelModeEnum = PANEL_MODE;
|
|
28304
28325
|
if (_options === null || _options === void 0 ? void 0 : _options.panelMode) {
|
|
28305
28326
|
this.panelMode = _options.panelMode;
|
|
28306
28327
|
}
|
|
28307
|
-
this.
|
|
28308
|
-
|
|
28309
|
-
const isAr = this._translationService.isArabic.getValue();
|
|
28310
|
-
return this._toasterService
|
|
28311
|
-
.showToast({
|
|
28312
|
-
type: 'info',
|
|
28313
|
-
title: 'notifications.newNotification',
|
|
28314
|
-
customContent: isAr ? res.arabicMessage : res.englishMessage,
|
|
28315
|
-
})
|
|
28316
|
-
.onTap.pipe(map(() => res));
|
|
28317
|
-
}), takeUntil(this.destroy$))
|
|
28318
|
-
.subscribe((res) => {
|
|
28319
|
-
this.refreshUnreadCount();
|
|
28320
|
-
if (res === null || res === void 0 ? void 0 : res.clickable) {
|
|
28321
|
-
this.onNotification.emit(res);
|
|
28322
|
-
}
|
|
28323
|
-
});
|
|
28328
|
+
this._socketListener();
|
|
28329
|
+
this.refreshUnreadCount();
|
|
28324
28330
|
}
|
|
28325
28331
|
hideBadgeCount() {
|
|
28326
28332
|
this._showBadgeSub.next(false);
|
|
@@ -28346,6 +28352,25 @@ class NotificationsButtonComponent extends BaseNotification {
|
|
|
28346
28352
|
this._cdr.detectChanges();
|
|
28347
28353
|
});
|
|
28348
28354
|
}
|
|
28355
|
+
_socketListener() {
|
|
28356
|
+
this.notificationsService.listenerObserver
|
|
28357
|
+
.pipe(switchMap((res) => {
|
|
28358
|
+
const isAr = this._translationService.isArabic.getValue();
|
|
28359
|
+
return this._toasterService
|
|
28360
|
+
.showToast({
|
|
28361
|
+
type: 'info',
|
|
28362
|
+
title: 'notifications.newNotification',
|
|
28363
|
+
customContent: isAr ? res.arabicMessage : res.englishMessage,
|
|
28364
|
+
})
|
|
28365
|
+
.onTap.pipe(map(() => res));
|
|
28366
|
+
}), takeUntil(this.destroy$))
|
|
28367
|
+
.subscribe((res) => {
|
|
28368
|
+
this.refreshUnreadCount();
|
|
28369
|
+
if (res === null || res === void 0 ? void 0 : res.clickable) {
|
|
28370
|
+
this.onNotification.emit(res);
|
|
28371
|
+
}
|
|
28372
|
+
});
|
|
28373
|
+
}
|
|
28349
28374
|
}
|
|
28350
28375
|
NotificationsButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: NotificationsButtonComponent, deps: [{ token: i0.Injector }, { token: TranslationService }, { token: CustomToastrService }, { token: i0.ChangeDetectorRef }, { token: NOTIFICATIONS_LIST_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
28351
28376
|
NotificationsButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: NotificationsButtonComponent, selector: "app-notifications-button", inputs: { styleClass: "styleClass", badgeOptions: "badgeOptions" }, outputs: { listItemClick: "listItemClick", openSettings: "openSettings", openNotifications: "openNotifications", onNotification: "onNotification" }, host: { classAttribute: "inline-flex justify-center items-center notification-button" }, queries: [{ propertyName: "customIconTemplate", first: true, predicate: NOTIFICATION_ICON, descendants: true, read: TemplateRef, static: true }], usesInheritance: true, ngImport: i0, template: "<button\r\n *ngIf=\"panelMode === panelModeEnum.panel\"\r\n [matMenuTriggerFor]=\"notifications\"\r\n [matBadge]=\"newNotificationCount$ | async\"\r\n [matBadgeHidden]=\"!(showBadge$ | async)\"\r\n [matBadgeSize]=\"badgeOptions.size\"\r\n [matBadgeColor]=\"badgeOptions.color\"\r\n [matBadgePosition]=\"badgeOptions.position\"\r\n [class]=\"styleClass\"\r\n (menuOpened)=\"markAllAsUnread()\"\r\n>\r\n <ng-container [ngTemplateOutlet]=\"customIconTemplate || defaultIconTemplate\">\r\n </ng-container>\r\n</button>\r\n\r\n<mat-menu #notifications=\"matMenu\" class=\"notification-list-panel\">\r\n <ng-template matMenuContent>\r\n <app-notifications-list\r\n (itemClicked)=\"listItemClick.emit($event); notifications.closed.emit()\"\r\n (openSettings)=\"openSettings.emit($event); notifications.closed.emit()\"\r\n (openNotifications)=\"openNotifications.emit($event); notifications.closed.emit()\"\r\n (markAllRead)=\"refreshUnreadCount()\"\r\n ></app-notifications-list>\r\n </ng-template>\r\n <div class=\"notification-list-panel__footer flex justify-center\">\r\n <ng-content select=\"[notifications-footer]\"></ng-content>\r\n </div>\r\n</mat-menu>\r\n\r\n<ng-container *ngIf=\"panelMode === panelModeEnum.sidebar\">\r\n <button\r\n [matBadge]=\"newNotificationCount$ | async\"\r\n [matBadgeHidden]=\"!(showBadge$ | async)\"\r\n [matBadgeSize]=\"badgeOptions.size\"\r\n [matBadgeColor]=\"badgeOptions.color\"\r\n [matBadgePosition]=\"badgeOptions.position\"\r\n [class]=\"styleClass\"\r\n (click)=\"toggleSideBar(); markAllAsUnread()\"\r\n >\r\n <ng-container [ngTemplateOutlet]=\"customIconTemplate || defaultIconTemplate\">\r\n </ng-container>\r\n </button>\r\n <app-notifications-sidebar\r\n [(visible)]=\"isSidebarOpened\"\r\n (visibleChange)=\"refreshUnreadCount()\"\r\n [position]=\"sidebarPosition$ | async\"\r\n >\r\n <ng-template appNotificationSidebarContent>\r\n <app-notifications-list\r\n class=\"notifications-sidebar\"\r\n (itemClicked)=\"\r\n listItemClick.emit($event); toggleSideBar(false); refreshUnreadCount()\r\n \"\r\n (openSettings)=\"openSettings.emit($event); toggleSideBar(false)\"\r\n (openNotifications)=\"openNotifications.emit($event); toggleSideBar(false)\"\r\n (markAllRead)=\"refreshUnreadCount()\"\r\n ></app-notifications-list>\r\n </ng-template>\r\n </app-notifications-sidebar>\r\n</ng-container>\r\n\r\n<ng-template #defaultIconTemplate>\r\n <i class=\"bi bi-bell bell\"></i>\r\n</ng-template>\r\n", styles: [".notification-button{font-size:var(--not-btn-font-size, 1.5rem);width:var(--not-btn-width, 40px)}.notification-list-panel{--width: var(--nos-panel-width, min(80vw, 450px));width:var(--width);border-radius:var(--nos-panel-radius, 5px);overflow:hidden;-webkit-overflow-scrolling:touch;outline:0;background:var(--nos-panel-background, #fff)}.notification-list-panel.mat-menu-panel{max-width:var(--width);max-height:var(--nos-panel-max-height, var(--height))}.notification-list-panel__navigate-btn{background:var(--not-btn-background, transparent);border-radius:var(--not-btn-radius, 5px);padding:var(--not-btn-padding, .5rem 1rem);margin:var(--not-btn-margin, .5rem 0);color:var(--not-btn-color, currentColor);width:var(--not-btn-width, 90%)}.notification-list-panel__navigate-btn:hover{--not-btn-background: var(--not-btn-hover-background, #f0f0f0);--not-btn-color: var(--not-btn-hover-color);-webkit-text-decoration:var(--not-btn-decoration, none);text-decoration:var(--not-btn-decoration, none)}.notification-list-panel__navigate-btn:active{--not-btn-background: var(--not-btn-active-background, #e2e2e2);--not-btn-color: var(--not-btn-active-color)}.notifications-sidebar{--nto-list-header-padding: var(--sidebar-list-header-padding , 1rem);--nto-list-height: var(--sidebar-list-height , calc(100vh - 100px))}\n"], components: [{ type: i3$1.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: NotificationsListComponent, selector: "app-notifications-list", outputs: ["openSettings", "openNotifications"] }, { type: NotificationsSidebarComponent, selector: "app-notifications-sidebar", inputs: ["appendToBody", "clearOnCLose", "visible", "position"], outputs: ["visibleChange", "onShow", "onHide"] }], directives: [{ type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$1.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["matMenuTriggerRestoreFocus", "mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { type: i7$3.MatBadge, selector: "[matBadge]", inputs: ["matBadgeDisabled", "matBadgePosition", "matBadgeSize", "matBadgeColor", "matBadgeOverlap", "matBadgeDescription", "matBadgeHidden", "matBadge"] }, { type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i3$1.MatMenuContent, selector: "ng-template[matMenuContent]" }, { type: NotificationSidebarContentDirective, selector: "[appNotificationSidebarContent]" }], pipes: { "async": i4.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
@@ -28485,7 +28510,7 @@ const mapDefinitionToPresenter = (definition) => {
|
|
|
28485
28510
|
sourceType: _properties['notf_nt:sourceTypee'],
|
|
28486
28511
|
isActive: _properties['notif_def:isActive'],
|
|
28487
28512
|
autoSubscription: _properties['notif_def:autoSubscription'],
|
|
28488
|
-
|
|
28513
|
+
sentByDefault: _properties['notif_def:sentByDefault'],
|
|
28489
28514
|
applicationKey: _properties['notif_def:applicationKey'],
|
|
28490
28515
|
channel: _properties['notif_def:channel'],
|
|
28491
28516
|
title: definition.title,
|
|
@@ -28518,10 +28543,11 @@ class CheckIfSubscribedPipe {
|
|
|
28518
28543
|
sub.applicationKey == definition.applicationKey &&
|
|
28519
28544
|
sub.notificationKey == definition.notificationKey);
|
|
28520
28545
|
});
|
|
28521
|
-
if (_subscription
|
|
28546
|
+
if (_subscription &&
|
|
28547
|
+
Object.values(SUBSCRIPTION_STATE).includes(_subscription === null || _subscription === void 0 ? void 0 : _subscription.state)) {
|
|
28522
28548
|
return _subscription.state === SUBSCRIPTION_STATE.subscribed;
|
|
28523
28549
|
}
|
|
28524
|
-
return
|
|
28550
|
+
return !!(definition === null || definition === void 0 ? void 0 : definition.sentByDefault);
|
|
28525
28551
|
}
|
|
28526
28552
|
}
|
|
28527
28553
|
CheckIfSubscribedPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: CheckIfSubscribedPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|