cat-qw-lib 0.14.2 → 0.14.3
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/fesm2022/cat-qw-lib.mjs +50 -13
- package/fesm2022/cat-qw-lib.mjs.map +1 -1
- package/lib/shared/constant/SHARED.d.ts +1 -0
- package/lib/widget/components/widget-container/widget-container.component.d.ts +6 -2
- package/lib/widget/components/widget-footer/widget-footer.component.d.ts +4 -3
- package/lib/widget/state/widget.query.d.ts +15 -0
- package/lib/widget/state/widget.store.d.ts +3 -0
- package/package.json +1 -1
package/fesm2022/cat-qw-lib.mjs
CHANGED
|
@@ -11,7 +11,7 @@ import { DropdownModule } from 'primeng/dropdown';
|
|
|
11
11
|
import { InputGroupModule } from 'primeng/inputgroup';
|
|
12
12
|
import * as i2$1 from 'primeng/button';
|
|
13
13
|
import { ButtonModule } from 'primeng/button';
|
|
14
|
-
import * as
|
|
14
|
+
import * as i7 from 'primeng/card';
|
|
15
15
|
import { CardModule } from 'primeng/card';
|
|
16
16
|
import * as i3 from 'primeng/sidebar';
|
|
17
17
|
import { SidebarModule } from 'primeng/sidebar';
|
|
@@ -137,6 +137,7 @@ class SHARED {
|
|
|
137
137
|
static RECORDID = "recordId";
|
|
138
138
|
static MISSING_QUEUE_ID = "Missing queueId";
|
|
139
139
|
static MISSING_RECORD_ID = "Missing recordId";
|
|
140
|
+
static EMPTY_STRING = " ";
|
|
140
141
|
}
|
|
141
142
|
const MESSAGE_TYPES = ['SMS', 'WhatsApp', 'Email'];
|
|
142
143
|
const delimiters = ['|', '/', '-'];
|
|
@@ -2958,8 +2959,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.1", ngImpor
|
|
|
2958
2959
|
* Widget Admin Store
|
|
2959
2960
|
*/
|
|
2960
2961
|
let WidgetStore = class WidgetStore extends BaseStore {
|
|
2962
|
+
onViewAllDetails$;
|
|
2961
2963
|
constructor() {
|
|
2962
2964
|
super();
|
|
2965
|
+
this.onViewAllDetails$ = new BehaviorSubject(SHARED.EMPTY_STRING);
|
|
2966
|
+
}
|
|
2967
|
+
setOnViewAllDetails(value) {
|
|
2968
|
+
this.onViewAllDetails$.next(value);
|
|
2963
2969
|
}
|
|
2964
2970
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetStore, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2965
2971
|
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetStore, providedIn: 'root' });
|
|
@@ -2996,6 +3002,28 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.1", ngImpor
|
|
|
2996
3002
|
args: [{ providedIn: 'root' }]
|
|
2997
3003
|
}], ctorParameters: () => [{ type: i1$1.HttpClient }, { type: WidgetStore }, { type: AppConfigService }, { type: ListService }] });
|
|
2998
3004
|
|
|
3005
|
+
/**
|
|
3006
|
+
* Widget Admin Query
|
|
3007
|
+
*/
|
|
3008
|
+
class WidgetQuery extends BaseQuery {
|
|
3009
|
+
store;
|
|
3010
|
+
widgetStore;
|
|
3011
|
+
constructor(store, widgetStore) {
|
|
3012
|
+
super(store);
|
|
3013
|
+
this.store = store;
|
|
3014
|
+
this.widgetStore = widgetStore;
|
|
3015
|
+
}
|
|
3016
|
+
getOnViewAllDetails() {
|
|
3017
|
+
return this.widgetStore.onViewAllDetails$.asObservable();
|
|
3018
|
+
}
|
|
3019
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetQuery, deps: [{ token: WidgetStore }, { token: WidgetStore }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
3020
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetQuery, providedIn: 'root' });
|
|
3021
|
+
}
|
|
3022
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetQuery, decorators: [{
|
|
3023
|
+
type: Injectable,
|
|
3024
|
+
args: [{ providedIn: 'root' }]
|
|
3025
|
+
}], ctorParameters: () => [{ type: WidgetStore }, { type: WidgetStore }] });
|
|
3026
|
+
|
|
2999
3027
|
class WidgetHeaderComponent {
|
|
3000
3028
|
widget;
|
|
3001
3029
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -3009,21 +3037,22 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.1", ngImpor
|
|
|
3009
3037
|
}] } });
|
|
3010
3038
|
|
|
3011
3039
|
class WidgetFooterComponent {
|
|
3040
|
+
widgetStore;
|
|
3012
3041
|
widget;
|
|
3013
|
-
|
|
3042
|
+
constructor(widgetStore) {
|
|
3043
|
+
this.widgetStore = widgetStore;
|
|
3044
|
+
}
|
|
3014
3045
|
viewAllDetails() {
|
|
3015
|
-
this.
|
|
3046
|
+
this.widgetStore.setOnViewAllDetails(this.widget?._id);
|
|
3016
3047
|
}
|
|
3017
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetFooterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
3018
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.1.1", type: WidgetFooterComponent, isStandalone: false, selector: "lib-widget-footer", inputs: { widget: "widget" },
|
|
3048
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetFooterComponent, deps: [{ token: WidgetStore }], target: i0.ɵɵFactoryTarget.Component });
|
|
3049
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.1.1", type: WidgetFooterComponent, isStandalone: false, selector: "lib-widget-footer", inputs: { widget: "widget" }, ngImport: i0, template: "<div\r\n class=\"col-12 p-0 mt-3 flex justify-content-center\"\r\n >\r\n <a\r\n class=\"p-button p-button-link text-primary-500\"\r\n >\r\n <span class=\"underline font-semibold\" (click)=\"viewAllDetails()\">View All Details</span>\r\n <i class=\"pi pi-arrow-up-right arrow-up-icon ml-2\"></i>\r\n </a>\r\n</div>", styles: [""] });
|
|
3019
3050
|
}
|
|
3020
3051
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetFooterComponent, decorators: [{
|
|
3021
3052
|
type: Component,
|
|
3022
3053
|
args: [{ selector: 'lib-widget-footer', standalone: false, template: "<div\r\n class=\"col-12 p-0 mt-3 flex justify-content-center\"\r\n >\r\n <a\r\n class=\"p-button p-button-link text-primary-500\"\r\n >\r\n <span class=\"underline font-semibold\" (click)=\"viewAllDetails()\">View All Details</span>\r\n <i class=\"pi pi-arrow-up-right arrow-up-icon ml-2\"></i>\r\n </a>\r\n</div>" }]
|
|
3023
|
-
}], propDecorators: { widget: [{
|
|
3054
|
+
}], ctorParameters: () => [{ type: WidgetStore }], propDecorators: { widget: [{
|
|
3024
3055
|
type: Input
|
|
3025
|
-
}], onViewAllDetails: [{
|
|
3026
|
-
type: Output
|
|
3027
3056
|
}] } });
|
|
3028
3057
|
|
|
3029
3058
|
class WidgetItemComponent {
|
|
@@ -3053,12 +3082,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.1", ngImpor
|
|
|
3053
3082
|
class WidgetContainerComponent {
|
|
3054
3083
|
widgetService;
|
|
3055
3084
|
activatedRoute;
|
|
3056
|
-
|
|
3085
|
+
widgetQuery;
|
|
3086
|
+
constructor(widgetService, activatedRoute, widgetQuery) {
|
|
3057
3087
|
this.widgetService = widgetService;
|
|
3058
3088
|
this.activatedRoute = activatedRoute;
|
|
3089
|
+
this.widgetQuery = widgetQuery;
|
|
3059
3090
|
}
|
|
3060
3091
|
widgets = [];
|
|
3092
|
+
onViewAllDetails = new EventEmitter();
|
|
3061
3093
|
ngOnInit() {
|
|
3094
|
+
this.widgetQuery.getOnViewAllDetails().subscribe((res) => {
|
|
3095
|
+
this.onViewAllDetails.emit(res);
|
|
3096
|
+
});
|
|
3062
3097
|
const queueId = localStorage.getItem(SHARED.selectedQueue);
|
|
3063
3098
|
const recordId = this.activatedRoute.snapshot.params[SHARED.ID];
|
|
3064
3099
|
if (!queueId || !recordId) {
|
|
@@ -3075,13 +3110,15 @@ class WidgetContainerComponent {
|
|
|
3075
3110
|
console.error(ERROR.ERROR_FETCHING_WIDGET_DATA, error);
|
|
3076
3111
|
});
|
|
3077
3112
|
}
|
|
3078
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetContainerComponent, deps: [{ token: WidgetService }, { token: i3$3.ActivatedRoute }], target: i0.ɵɵFactoryTarget.Component });
|
|
3079
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.1.1", type: WidgetContainerComponent, isStandalone: false, selector: "lib-widget-container", ngImport: i0, template: "<p-card class=\"widget-block-wrapper
|
|
3113
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetContainerComponent, deps: [{ token: WidgetService }, { token: i3$3.ActivatedRoute }, { token: WidgetQuery }], target: i0.ɵɵFactoryTarget.Component });
|
|
3114
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.1.1", type: WidgetContainerComponent, isStandalone: false, selector: "lib-widget-container", outputs: { onViewAllDetails: "onViewAllDetails" }, ngImport: i0, template: "<p-card class=\"widget-block-wrapper block\">\r\n <div class=\"flex align-items-center justify-content-end pb-0 px-3\">\r\n <p-button\r\n class=\"p-0 refresh-btn-wrapper\"\r\n [text]=\"true\"\r\n aria-label=\"Refresh\"\r\n >\r\n <i class=\"pi pi-sync pr-2\" style=\"font-size: 16px\"></i>\r\n <span class=\"text-lg font-semibold\">Refresh</span>\r\n </p-button>\r\n </div>\r\n <p-divider />\r\n \r\n <div class=\"widget-section-wrapper p-3\">\r\n <ng-container *ngFor=\"let widget of widgets\">\r\n <ng-container>\r\n <lib-widget-header [widget]=\"widget\"></lib-widget-header>\r\n <div class=\"widget-content-wrapper mt-4 p-3\">\r\n <lib-widget-body [widget]=\"widget\"></lib-widget-body>\r\n <lib-widget-footer [widget]=\"widget\"></lib-widget-footer>\r\n </div>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n</p-card>", styles: ["::ng-deep .badge-wrapper .p-button{padding:4px 8px}::ng-deep .refresh-btn-wrapper .p-button{padding:0}::ng-deep .valuation-timeline-wrapper .p-timeline-event-opposite{display:none}::ng-deep .rating-badge-wrapper .p-button{display:flex;align-items:center}::ng-deep .widget-block-wrapper{height:100%}::ng-deep .widget-block-wrapper .p-card{height:100%}::ng-deep .widget-block-wrapper .p-card-body{padding:0;height:100%}::ng-deep .widget-block-wrapper .p-card-content{padding-bottom:0;height:100%}.application-title-wrapper{font-size:20px;font-weight:400}.application-section-wrapper{background-color:#4c629208;border:1px solid rgba(76,98,146,.1);border-radius:10px}.widget-section-wrapper{height:calc(100% - 55px);overflow-y:auto}.widget-content-wrapper{border-radius:10px;border:1px solid rgba(76,98,146,.1);background:linear-gradient(0deg,#4c629208 0% 100%),#fff}:host ::-webkit-scrollbar{width:10px}:host ::-webkit-scrollbar-track{background:transparent}:host ::-webkit-scrollbar-thumb{background-color:var(--gray-500);border-radius:20px}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: i2$1.Button, selector: "p-button", inputs: ["type", "iconPos", "icon", "badge", "label", "disabled", "loading", "loadingIcon", "raised", "rounded", "text", "plain", "severity", "outlined", "link", "tabindex", "size", "style", "styleClass", "badgeClass", "ariaLabel", "autofocus"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: i4.Divider, selector: "p-divider", inputs: ["style", "styleClass", "layout", "type", "align"] }, { kind: "component", type: i7.Card, selector: "p-card", inputs: ["header", "subheader", "style", "styleClass"] }, { kind: "component", type: WidgetHeaderComponent, selector: "lib-widget-header", inputs: ["widget"] }, { kind: "component", type: WidgetFooterComponent, selector: "lib-widget-footer", inputs: ["widget"] }, { kind: "component", type: WidgetBodyComponent, selector: "lib-widget-body", inputs: ["widget"] }] });
|
|
3080
3115
|
}
|
|
3081
3116
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetContainerComponent, decorators: [{
|
|
3082
3117
|
type: Component,
|
|
3083
|
-
args: [{ selector: 'lib-widget-container', standalone: false, template: "<p-card class=\"widget-block-wrapper
|
|
3084
|
-
}], ctorParameters: () => [{ type: WidgetService }, { type: i3$3.ActivatedRoute }]
|
|
3118
|
+
args: [{ selector: 'lib-widget-container', standalone: false, template: "<p-card class=\"widget-block-wrapper block\">\r\n <div class=\"flex align-items-center justify-content-end pb-0 px-3\">\r\n <p-button\r\n class=\"p-0 refresh-btn-wrapper\"\r\n [text]=\"true\"\r\n aria-label=\"Refresh\"\r\n >\r\n <i class=\"pi pi-sync pr-2\" style=\"font-size: 16px\"></i>\r\n <span class=\"text-lg font-semibold\">Refresh</span>\r\n </p-button>\r\n </div>\r\n <p-divider />\r\n \r\n <div class=\"widget-section-wrapper p-3\">\r\n <ng-container *ngFor=\"let widget of widgets\">\r\n <ng-container>\r\n <lib-widget-header [widget]=\"widget\"></lib-widget-header>\r\n <div class=\"widget-content-wrapper mt-4 p-3\">\r\n <lib-widget-body [widget]=\"widget\"></lib-widget-body>\r\n <lib-widget-footer [widget]=\"widget\"></lib-widget-footer>\r\n </div>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n</p-card>", styles: ["::ng-deep .badge-wrapper .p-button{padding:4px 8px}::ng-deep .refresh-btn-wrapper .p-button{padding:0}::ng-deep .valuation-timeline-wrapper .p-timeline-event-opposite{display:none}::ng-deep .rating-badge-wrapper .p-button{display:flex;align-items:center}::ng-deep .widget-block-wrapper{height:100%}::ng-deep .widget-block-wrapper .p-card{height:100%}::ng-deep .widget-block-wrapper .p-card-body{padding:0;height:100%}::ng-deep .widget-block-wrapper .p-card-content{padding-bottom:0;height:100%}.application-title-wrapper{font-size:20px;font-weight:400}.application-section-wrapper{background-color:#4c629208;border:1px solid rgba(76,98,146,.1);border-radius:10px}.widget-section-wrapper{height:calc(100% - 55px);overflow-y:auto}.widget-content-wrapper{border-radius:10px;border:1px solid rgba(76,98,146,.1);background:linear-gradient(0deg,#4c629208 0% 100%),#fff}:host ::-webkit-scrollbar{width:10px}:host ::-webkit-scrollbar-track{background:transparent}:host ::-webkit-scrollbar-thumb{background-color:var(--gray-500);border-radius:20px}\n"] }]
|
|
3119
|
+
}], ctorParameters: () => [{ type: WidgetService }, { type: i3$3.ActivatedRoute }, { type: WidgetQuery }], propDecorators: { onViewAllDetails: [{
|
|
3120
|
+
type: Output
|
|
3121
|
+
}] } });
|
|
3085
3122
|
|
|
3086
3123
|
class WidgetModule {
|
|
3087
3124
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.1", ngImport: i0, type: WidgetModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|