@bitblit/ngx-acute-common 5.1.646-alpha → 5.1.649-alpha
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/lib/acute-common-type-guards.d.ts +4 -0
- package/lib/acute-common-type-guards.js +9 -0
- package/lib/acute-common-type-guards.js.map +1 -0
- package/lib/components/process-monitor/process-monitor.component.js +63 -54
- package/lib/components/process-monitor/process-monitor.component.js.map +1 -1
- package/lib/index.d.ts +4 -1
- package/lib/index.js +4 -1
- package/lib/index.js.map +1 -1
- package/lib/services/css-theme.service.d.ts +1 -1
- package/lib/services/css-theme.service.js +3 -2
- package/lib/services/css-theme.service.js.map +1 -1
- package/lib/services/process-monitor/grouped-process-list.d.ts +4 -0
- package/lib/services/process-monitor/grouped-process-list.js +2 -0
- package/lib/services/process-monitor/grouped-process-list.js.map +1 -0
- package/lib/services/process-monitor/grouped-processes.d.ts +5 -0
- package/lib/services/process-monitor/grouped-processes.js +2 -0
- package/lib/services/process-monitor/grouped-processes.js.map +1 -0
- package/lib/services/process-monitor/process-holder.d.ts +2 -2
- package/lib/services/process-monitor/process-monitor-service.d.ts +9 -9
- package/lib/services/process-monitor/process-monitor-service.js +33 -59
- package/lib/services/process-monitor/process-monitor-service.js.map +1 -1
- package/package.json +6 -6
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export class AcuteCommonTypeGuards {
|
|
2
|
+
static isProcessMonitorState(item) {
|
|
3
|
+
return item && item.label && typeof item.label === 'string'
|
|
4
|
+
&& !item.detail || typeof item.detail === 'string'
|
|
5
|
+
&& !item.group || typeof item.group === 'string'
|
|
6
|
+
&& !item.percentComplete || typeof item.percentComplete === 'number';
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=acute-common-type-guards.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"acute-common-type-guards.js","sourceRoot":"","sources":["../src/acute-common-type-guards.ts"],"names":[],"mappings":"AAIA,MAAM,OAAO,qBAAqB;IACzB,MAAM,CAAC,qBAAqB,CAAC,IAAS;QAC3C,OAAO,IAAI,IAAI,IAAI,CAAC,KAAK,IAAI,OAAO,IAAI,CAAC,KAAK,KAAK,QAAQ;eACtD,CAAC,IAAI,CAAC,MAAM,IAAI,OAAO,IAAI,CAAC,MAAM,KAAK,QAAQ;eAC/C,CAAC,IAAI,CAAC,KAAK,IAAI,OAAO,IAAI,CAAC,KAAK,KAAK,QAAQ;eAC7C,CAAC,IAAI,CAAC,eAAe,IAAI,OAAO,IAAI,CAAC,eAAe,KAAK,QAAQ,CAAC;IACzE,CAAC;CACF"}
|
|
@@ -9,83 +9,94 @@ import { SidebarModule } from "primeng/sidebar";
|
|
|
9
9
|
import { InputGroupAddonModule } from "primeng/inputgroupaddon";
|
|
10
10
|
import { InputGroupModule } from "primeng/inputgroup";
|
|
11
11
|
import { InputSwitchModule } from "primeng/inputswitch";
|
|
12
|
-
import {
|
|
12
|
+
import { NgForOf, NgIf } from "@angular/common";
|
|
13
13
|
import { ProgressBar } from "primeng/progressbar";
|
|
14
14
|
import { Dialog } from "primeng/dialog";
|
|
15
15
|
import { ProcessMonitorService } from "../../services/process-monitor/process-monitor-service";
|
|
16
16
|
import * as i0 from "@angular/core";
|
|
17
17
|
import * as i1 from "../../services/process-monitor/process-monitor-service";
|
|
18
18
|
const _c0 = () => ({ width: "90rem" });
|
|
19
|
-
function
|
|
20
|
-
i0.ɵɵelementStart(0, "div",
|
|
21
|
-
i0.ɵɵelement(1, "p-progress-bar",
|
|
22
|
-
i0.ɵɵpipe(2, "async");
|
|
19
|
+
function ProcessMonitorComponent_div_1_ng_container_1_div_6_Template(rf, ctx) { if (rf & 1) {
|
|
20
|
+
i0.ɵɵelementStart(0, "div", 9);
|
|
21
|
+
i0.ɵɵelement(1, "p-progress-bar", 10);
|
|
23
22
|
i0.ɵɵelementEnd();
|
|
24
23
|
} if (rf & 2) {
|
|
25
24
|
const pm_r1 = i0.ɵɵnextContext().$implicit;
|
|
26
25
|
i0.ɵɵadvance();
|
|
27
|
-
i0.ɵɵproperty("value",
|
|
26
|
+
i0.ɵɵproperty("value", pm_r1.input().percentComplete);
|
|
28
27
|
} }
|
|
29
|
-
function
|
|
30
|
-
i0.ɵɵ
|
|
28
|
+
function ProcessMonitorComponent_div_1_ng_container_1_Template(rf, ctx) { if (rf & 1) {
|
|
29
|
+
i0.ɵɵelementContainerStart(0);
|
|
30
|
+
i0.ɵɵelementStart(1, "div", 5)(2, "div", 6);
|
|
31
31
|
i0.ɵɵtext(3);
|
|
32
|
-
i0.ɵɵpipe(4, "async");
|
|
33
32
|
i0.ɵɵelementEnd();
|
|
34
|
-
i0.ɵɵelementStart(
|
|
35
|
-
i0.ɵɵtext(
|
|
36
|
-
i0.ɵɵpipe(7, "async");
|
|
33
|
+
i0.ɵɵelementStart(4, "div", 7);
|
|
34
|
+
i0.ɵɵtext(5);
|
|
37
35
|
i0.ɵɵelementEnd()();
|
|
38
|
-
i0.ɵɵtemplate(
|
|
39
|
-
i0.ɵɵ
|
|
40
|
-
i0.ɵɵelementEnd();
|
|
36
|
+
i0.ɵɵtemplate(6, ProcessMonitorComponent_div_1_ng_container_1_div_6_Template, 2, 1, "div", 8);
|
|
37
|
+
i0.ɵɵelementContainerEnd();
|
|
41
38
|
} if (rf & 2) {
|
|
42
39
|
const pm_r1 = ctx.$implicit;
|
|
43
40
|
i0.ɵɵadvance(3);
|
|
44
|
-
i0.ɵɵtextInterpolate(
|
|
45
|
-
i0.ɵɵadvance(3);
|
|
46
|
-
i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(7, 5, pm_r1).detail);
|
|
41
|
+
i0.ɵɵtextInterpolate(pm_r1.input().label);
|
|
47
42
|
i0.ɵɵadvance(2);
|
|
48
|
-
i0.ɵɵ
|
|
43
|
+
i0.ɵɵtextInterpolate(pm_r1.input().detail);
|
|
44
|
+
i0.ɵɵadvance();
|
|
45
|
+
i0.ɵɵproperty("ngIf", pm_r1.input().percentComplete);
|
|
46
|
+
} }
|
|
47
|
+
function ProcessMonitorComponent_div_1_Template(rf, ctx) { if (rf & 1) {
|
|
48
|
+
i0.ɵɵelementStart(0, "div", 3);
|
|
49
|
+
i0.ɵɵtemplate(1, ProcessMonitorComponent_div_1_ng_container_1_Template, 7, 3, "ng-container", 4);
|
|
50
|
+
i0.ɵɵelementEnd();
|
|
51
|
+
} if (rf & 2) {
|
|
52
|
+
const gp_r2 = ctx.$implicit;
|
|
53
|
+
i0.ɵɵadvance();
|
|
54
|
+
i0.ɵɵproperty("ngForOf", gp_r2.processes);
|
|
49
55
|
} }
|
|
50
|
-
function
|
|
51
|
-
i0.ɵɵelementStart(0, "div",
|
|
56
|
+
function ProcessMonitorComponent_div_3_ng_container_1_div_4_Template(rf, ctx) { if (rf & 1) {
|
|
57
|
+
i0.ɵɵelementStart(0, "div", 7);
|
|
52
58
|
i0.ɵɵtext(1);
|
|
53
|
-
i0.ɵɵpipe(2, "async");
|
|
54
59
|
i0.ɵɵelementEnd();
|
|
55
60
|
} if (rf & 2) {
|
|
56
|
-
const
|
|
61
|
+
const pm_r3 = i0.ɵɵnextContext().$implicit;
|
|
57
62
|
i0.ɵɵadvance();
|
|
58
|
-
i0.ɵɵtextInterpolate(
|
|
63
|
+
i0.ɵɵtextInterpolate(pm_r3.input().detail);
|
|
59
64
|
} }
|
|
60
|
-
function
|
|
61
|
-
i0.ɵɵelementStart(0, "div",
|
|
62
|
-
i0.ɵɵelement(1, "p-progress-bar",
|
|
63
|
-
i0.ɵɵpipe(2, "async");
|
|
65
|
+
function ProcessMonitorComponent_div_3_ng_container_1_div_5_Template(rf, ctx) { if (rf & 1) {
|
|
66
|
+
i0.ɵɵelementStart(0, "div", 9);
|
|
67
|
+
i0.ɵɵelement(1, "p-progress-bar", 10);
|
|
64
68
|
i0.ɵɵelementEnd();
|
|
65
69
|
} if (rf & 2) {
|
|
66
|
-
const
|
|
70
|
+
const pm_r3 = i0.ɵɵnextContext().$implicit;
|
|
67
71
|
i0.ɵɵadvance();
|
|
68
|
-
i0.ɵɵproperty("value",
|
|
72
|
+
i0.ɵɵproperty("value", pm_r3.input().percentComplete);
|
|
69
73
|
} }
|
|
70
|
-
function
|
|
71
|
-
i0.ɵɵ
|
|
74
|
+
function ProcessMonitorComponent_div_3_ng_container_1_Template(rf, ctx) { if (rf & 1) {
|
|
75
|
+
i0.ɵɵelementContainerStart(0);
|
|
76
|
+
i0.ɵɵelementStart(1, "div", 5)(2, "div", 6);
|
|
72
77
|
i0.ɵɵtext(3);
|
|
73
|
-
i0.ɵɵpipe(4, "async");
|
|
74
78
|
i0.ɵɵelementEnd();
|
|
75
|
-
i0.ɵɵtemplate(
|
|
76
|
-
i0.ɵɵpipe(6, "async");
|
|
77
|
-
i0.ɵɵelementEnd();
|
|
78
|
-
i0.ɵɵtemplate(7, ProcessMonitorComponent_div_3_div_7_Template, 3, 3, "div", 7);
|
|
79
|
-
i0.ɵɵpipe(8, "async");
|
|
79
|
+
i0.ɵɵtemplate(4, ProcessMonitorComponent_div_3_ng_container_1_div_4_Template, 2, 1, "div", 11);
|
|
80
80
|
i0.ɵɵelementEnd();
|
|
81
|
+
i0.ɵɵtemplate(5, ProcessMonitorComponent_div_3_ng_container_1_div_5_Template, 2, 1, "div", 8);
|
|
82
|
+
i0.ɵɵelementContainerEnd();
|
|
81
83
|
} if (rf & 2) {
|
|
82
|
-
const
|
|
84
|
+
const pm_r3 = ctx.$implicit;
|
|
83
85
|
i0.ɵɵadvance(3);
|
|
84
|
-
i0.ɵɵtextInterpolate(
|
|
85
|
-
i0.ɵɵadvance(
|
|
86
|
-
i0.ɵɵproperty("ngIf",
|
|
87
|
-
i0.ɵɵadvance(
|
|
88
|
-
i0.ɵɵproperty("ngIf",
|
|
86
|
+
i0.ɵɵtextInterpolate(pm_r3.input().label);
|
|
87
|
+
i0.ɵɵadvance();
|
|
88
|
+
i0.ɵɵproperty("ngIf", pm_r3.input().detail);
|
|
89
|
+
i0.ɵɵadvance();
|
|
90
|
+
i0.ɵɵproperty("ngIf", pm_r3.input().percentComplete);
|
|
91
|
+
} }
|
|
92
|
+
function ProcessMonitorComponent_div_3_Template(rf, ctx) { if (rf & 1) {
|
|
93
|
+
i0.ɵɵelementStart(0, "div", 3);
|
|
94
|
+
i0.ɵɵtemplate(1, ProcessMonitorComponent_div_3_ng_container_1_Template, 6, 3, "ng-container", 4);
|
|
95
|
+
i0.ɵɵelementEnd();
|
|
96
|
+
} if (rf & 2) {
|
|
97
|
+
const gp_r4 = ctx.$implicit;
|
|
98
|
+
i0.ɵɵadvance();
|
|
99
|
+
i0.ɵɵproperty("ngForOf", gp_r4.processes);
|
|
89
100
|
} }
|
|
90
101
|
export class ProcessMonitorComponent {
|
|
91
102
|
processMonitorService;
|
|
@@ -95,23 +106,23 @@ export class ProcessMonitorComponent {
|
|
|
95
106
|
this.processMonitorService = processMonitorService;
|
|
96
107
|
}
|
|
97
108
|
static ɵfac = function ProcessMonitorComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || ProcessMonitorComponent)(i0.ɵɵdirectiveInject(i1.ProcessMonitorService)); };
|
|
98
|
-
static ɵcmp = i0.ɵɵdefineComponent({ type: ProcessMonitorComponent, selectors: [["ngx-acute-common-process-monitor"]], inputs: { modalHeader: "modalHeader", normalHeader: "normalHeader" }, decls: 4, vars: 16, consts: [["position", "bottom", 3, "header", "closable", "modal", "visible"], ["style", "display: flex; flex-direction: row; width: 100%", 4, "ngFor", "ngForOf"], ["position", "center", 3, "header", "modal", "closable", "visible"], [2, "display", "flex", "flex-direction", "row", "width", "100%"], [2, "display", "flex", "flex-direction", "column", "width", "50%", "gap", "2px"], [2, "font-weight", "bolder"], [2, "font-style", "italic", "margin-left", "15px"], ["style", "min-width: 50vw", 4, "ngIf"], [2, "min-width", "50vw"], [3, "value"], ["style", "font-style: italic; margin-left: 15px", 4, "ngIf"]], template: function ProcessMonitorComponent_Template(rf, ctx) { if (rf & 1) {
|
|
109
|
+
static ɵcmp = i0.ɵɵdefineComponent({ type: ProcessMonitorComponent, selectors: [["ngx-acute-common-process-monitor"]], inputs: { modalHeader: "modalHeader", normalHeader: "normalHeader" }, decls: 4, vars: 16, consts: [["position", "bottom", 3, "header", "closable", "modal", "visible"], ["style", "display: flex; flex-direction: row; width: 100%", 4, "ngFor", "ngForOf"], ["position", "center", 3, "header", "modal", "closable", "visible"], [2, "display", "flex", "flex-direction", "row", "width", "100%"], [4, "ngFor", "ngForOf"], [2, "display", "flex", "flex-direction", "column", "width", "50%", "gap", "2px"], [2, "font-weight", "bolder"], [2, "font-style", "italic", "margin-left", "15px"], ["style", "min-width: 50vw", 4, "ngIf"], [2, "min-width", "50vw"], [3, "value"], ["style", "font-style: italic; margin-left: 15px", 4, "ngIf"]], template: function ProcessMonitorComponent_Template(rf, ctx) { if (rf & 1) {
|
|
99
110
|
i0.ɵɵelementStart(0, "p-dialog", 0);
|
|
100
|
-
i0.ɵɵtemplate(1, ProcessMonitorComponent_div_1_Template,
|
|
111
|
+
i0.ɵɵtemplate(1, ProcessMonitorComponent_div_1_Template, 2, 1, "div", 1);
|
|
101
112
|
i0.ɵɵelementEnd();
|
|
102
113
|
i0.ɵɵelementStart(2, "p-dialog", 2);
|
|
103
|
-
i0.ɵɵtemplate(3, ProcessMonitorComponent_div_3_Template,
|
|
114
|
+
i0.ɵɵtemplate(3, ProcessMonitorComponent_div_3_Template, 2, 1, "div", 1);
|
|
104
115
|
i0.ɵɵelementEnd();
|
|
105
116
|
} if (rf & 2) {
|
|
106
117
|
i0.ɵɵstyleMap(i0.ɵɵpureFunction0(14, _c0));
|
|
107
118
|
i0.ɵɵproperty("header", ctx.normalHeader)("closable", false)("modal", false)("visible", ctx.processMonitorService.showDisplay);
|
|
108
119
|
i0.ɵɵadvance();
|
|
109
|
-
i0.ɵɵproperty("ngForOf", ctx.processMonitorService.processes);
|
|
120
|
+
i0.ɵɵproperty("ngForOf", ctx.processMonitorService.processes().groups);
|
|
110
121
|
i0.ɵɵadvance();
|
|
111
122
|
i0.ɵɵstyleMap(i0.ɵɵpureFunction0(15, _c0));
|
|
112
|
-
i0.ɵɵproperty("header", ctx.modalHeader)("modal", true)("closable", false)("visible", ctx.processMonitorService.
|
|
123
|
+
i0.ɵɵproperty("header", ctx.modalHeader)("modal", true)("closable", false)("visible", ctx.processMonitorService.showModalDisplay);
|
|
113
124
|
i0.ɵɵadvance();
|
|
114
|
-
i0.ɵɵproperty("ngForOf", ctx.processMonitorService.modalProcesses);
|
|
125
|
+
i0.ɵɵproperty("ngForOf", ctx.processMonitorService.modalProcesses().groups);
|
|
115
126
|
} }, dependencies: [CardModule,
|
|
116
127
|
MultiSelectModule,
|
|
117
128
|
ContextMenuModule,
|
|
@@ -124,7 +135,6 @@ export class ProcessMonitorComponent {
|
|
|
124
135
|
InputSwitchModule,
|
|
125
136
|
FormsModule,
|
|
126
137
|
NgForOf,
|
|
127
|
-
AsyncPipe,
|
|
128
138
|
ProgressBar,
|
|
129
139
|
NgIf,
|
|
130
140
|
Dialog], encapsulation: 2 });
|
|
@@ -144,15 +154,14 @@ export class ProcessMonitorComponent {
|
|
|
144
154
|
InputSwitchModule,
|
|
145
155
|
FormsModule,
|
|
146
156
|
NgForOf,
|
|
147
|
-
AsyncPipe,
|
|
148
157
|
ProgressBar,
|
|
149
158
|
NgIf,
|
|
150
159
|
Dialog
|
|
151
|
-
], standalone: true, template: "\n
|
|
160
|
+
], standalone: true, template: "\n<p-dialog [header]=\"normalHeader\" [closable]=\"false\"\n [modal]=\"false\" [visible]=\"processMonitorService.showDisplay\" position=\"bottom\" [style]=\"{ width: '90rem' }\">\n\n <div style=\"display: flex; flex-direction: row; width: 100%\" *ngFor=\"let gp of processMonitorService.processes().groups\">\n <ng-container *ngFor=\"let pm of gp.processes\">\n <div style=\"display: flex; flex-direction: column; width: 50%; gap: 2px\">\n <div style=\"font-weight: bolder\">{{pm.input().label}}</div>\n <div style=\"font-style: italic; margin-left: 15px\">{{pm.input().detail}}</div>\n </div>\n <div *ngIf=\"pm.input().percentComplete\" style=\"min-width: 50vw\">\n <p-progress-bar [value]=\"pm.input().percentComplete\" />\n </div>\n </ng-container>\n </div>\n\n</p-dialog>\n\n<p-dialog [header]=\"modalHeader\" [modal]=\"true\"\n [closable]=\"false\"\n [visible]=\"processMonitorService.showModalDisplay\" position=\"center\" [style]=\"{ width: '90rem' }\">\n <div style=\"display: flex; flex-direction: row; width: 100%\" *ngFor=\"let gp of processMonitorService.modalProcesses().groups\">\n <ng-container *ngFor=\"let pm of gp.processes\">\n\n <div style=\"display: flex; flex-direction: column; width: 50%; gap: 2px\">\n <div style=\"font-weight: bolder\">{{pm.input().label}}</div>\n <div style=\"font-style: italic; margin-left: 15px\" *ngIf=\"pm.input().detail\">{{pm.input().detail}}</div>\n </div>\n <div *ngIf=\"pm.input().percentComplete\" style=\"min-width: 50vw\">\n <p-progress-bar [value]=\"pm.input().percentComplete\" />\n </div>\n </ng-container>\n </div>\n</p-dialog>\n" }]
|
|
152
161
|
}], () => [{ type: i1.ProcessMonitorService }], { modalHeader: [{
|
|
153
162
|
type: Input
|
|
154
163
|
}], normalHeader: [{
|
|
155
164
|
type: Input
|
|
156
165
|
}] }); })();
|
|
157
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ProcessMonitorComponent, { className: "ProcessMonitorComponent", filePath: "components/process-monitor/process-monitor.component.ts", lineNumber:
|
|
166
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ProcessMonitorComponent, { className: "ProcessMonitorComponent", filePath: "components/process-monitor/process-monitor.component.ts", lineNumber: 40 }); })();
|
|
158
167
|
//# sourceMappingURL=process-monitor.component.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"process-monitor.component.js","sourceRoot":"","sources":["../../../src/components/process-monitor/process-monitor.component.ts","../../../src/components/process-monitor/process-monitor.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AAClE,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"process-monitor.component.js","sourceRoot":"","sources":["../../../src/components/process-monitor/process-monitor.component.ts","../../../src/components/process-monitor/process-monitor.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AAClE,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,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B;IAErD,CAAC;iHAPU,uBAAuB;+CAAvB,uBAAuB;YCtCpC,mCACuH;YAErH,wEAAyH;YAY3H,iBAAW;YAEX,mCAE4G;YAC1G,wEAA8H;YAYhI,iBAAW;;YA/B+E,0CAA4B;YAA5F,AAAhB,AADwB,AAAxB,yCAAuB,mBAAmB,gBAC3B,kDAA8C;YAEO,cAA2C;YAA3C,sEAA2C;YAgB1C,cAA4B;YAA5B,0CAA4B;YAAjG,AADA,AADuB,AAAvB,wCAAsB,eAAe,mBACnB,uDACgC;YACkB,cAAgD;YAAhD,2EAAgD;4BDA1H,UAAU;YACV,iBAAiB;YACjB,iBAAiB;YACjB,WAAW;YACX,mBAAmB;YACnB,WAAW;YACX,aAAa;YACb,qBAAqB;YACrB,gBAAgB;YAChB,iBAAiB;YACjB,WAAW;YACX,OAAO;YACP,WAAW;YACX,IAAI;YACJ,MAAM;;iFAIG,uBAAuB;cAtBnC,SAAS;2BACE,kCAAkC,WAEnC;oBACP,UAAU;oBACV,iBAAiB;oBACjB,iBAAiB;oBACjB,WAAW;oBACX,mBAAmB;oBACnB,WAAW;oBACX,aAAa;oBACb,qBAAqB;oBACrB,gBAAgB;oBAChB,iBAAiB;oBACjB,WAAW;oBACX,OAAO;oBACP,WAAW;oBACX,IAAI;oBACJ,MAAM;iBACP,cACW,IAAI;sDAGA,WAAW;kBAA1B,KAAK;YACU,YAAY;kBAA3B,KAAK;;kFAFK,uBAAuB"}
|
package/lib/index.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ export * from './components/log-display/log-display.component';
|
|
|
3
3
|
export * from './components/dialogs/alert/alert.component';
|
|
4
4
|
export * from './components/process-monitor/process-monitor.component';
|
|
5
5
|
export * from './constants';
|
|
6
|
+
export * from './acute-common-type-guards';
|
|
6
7
|
export * from './model/google-analytics-config';
|
|
7
8
|
export * from './pipes/capitalize.pipe';
|
|
8
9
|
export * from './pipes/dollar-formatted.pipe';
|
|
@@ -19,6 +20,8 @@ export * from './services/graphql-query.service';
|
|
|
19
20
|
export * from './services/local-storage.service';
|
|
20
21
|
export * from './services/css-theme.service.ts';
|
|
21
22
|
export * from './services/window-ref.service';
|
|
22
|
-
export * from './services/process-monitor/process-
|
|
23
|
+
export * from './services/process-monitor/grouped-process-list';
|
|
24
|
+
export * from './services/process-monitor/grouped-processes';
|
|
23
25
|
export * from './services/process-monitor/process-holder';
|
|
26
|
+
export * from './services/process-monitor/process-monitor-service';
|
|
24
27
|
export * from './services/process-monitor/process-monitor-state';
|
package/lib/index.js
CHANGED
|
@@ -3,6 +3,7 @@ export * from './components/log-display/log-display.component';
|
|
|
3
3
|
export * from './components/dialogs/alert/alert.component';
|
|
4
4
|
export * from './components/process-monitor/process-monitor.component';
|
|
5
5
|
export * from './constants';
|
|
6
|
+
export * from './acute-common-type-guards';
|
|
6
7
|
export * from './model/google-analytics-config';
|
|
7
8
|
export * from './pipes/capitalize.pipe';
|
|
8
9
|
export * from './pipes/dollar-formatted.pipe';
|
|
@@ -19,7 +20,9 @@ export * from './services/graphql-query.service';
|
|
|
19
20
|
export * from './services/local-storage.service';
|
|
20
21
|
export * from "./services/css-theme.service.js";
|
|
21
22
|
export * from './services/window-ref.service';
|
|
22
|
-
export * from './services/process-monitor/process-
|
|
23
|
+
export * from './services/process-monitor/grouped-process-list';
|
|
24
|
+
export * from './services/process-monitor/grouped-processes';
|
|
23
25
|
export * from './services/process-monitor/process-holder';
|
|
26
|
+
export * from './services/process-monitor/process-monitor-service';
|
|
24
27
|
export * from './services/process-monitor/process-monitor-state';
|
|
25
28
|
//# sourceMappingURL=index.js.map
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,+BAA+B,CAAC;AAE9C,cAAc,gDAAgD,CAAC;AAE/D,cAAc,4CAA4C,CAAC;AAE3D,cAAc,wDAAwD,CAAC;AAEvE,cAAc,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,+BAA+B,CAAC;AAE9C,cAAc,gDAAgD,CAAC;AAE/D,cAAc,4CAA4C,CAAC;AAE3D,cAAc,wDAAwD,CAAC;AAEvE,cAAc,aAAa,CAAC;AAC5B,cAAc,4BAA4B,CAAC;AAE3C,cAAc,iCAAiC,CAAC;AAEhD,cAAc,yBAAyB,CAAC;AACxC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,yBAAyB,CAAC;AACxC,cAAc,iCAAiC,CAAC;AAChD,cAAc,uBAAuB,CAAC;AACtC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AACnC,cAAc,iCAAiC,CAAC;AAChD,cAAc,qBAAqB,CAAC;AAEpC,cAAc,qCAAqC,CAAC;AACpD,cAAc,kCAAkC,CAAC;AACjD,cAAc,kCAAkC,CAAC;AACjD,cAAc,iCAAiC,CAAC;AAChD,cAAc,+BAA+B,CAAC;AAE9C,cAAc,iDAAiD,CAAC;AAChE,cAAc,8CAA8C,CAAC;AAC7D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,oDAAoD,CAAC;AACnE,cAAc,kDAAkD,CAAC"}
|
|
@@ -2,7 +2,7 @@ import * as i0 from "@angular/core";
|
|
|
2
2
|
export declare class CssThemeService<ThemeObject> {
|
|
3
3
|
setCssVariable(name: string, value: string, scope?: HTMLElement, prefix?: string): void;
|
|
4
4
|
getCssVariable(name: string, scope?: HTMLElement, prefix?: string): string | null;
|
|
5
|
-
applyTheme(rec: ThemeObject, prefix?: string): void;
|
|
5
|
+
applyTheme(rec: ThemeObject, scope?: HTMLElement, prefix?: string): void;
|
|
6
6
|
setNumericVariable(name: string, value: number, suffix: string, scope?: HTMLElement, prefix?: string): void;
|
|
7
7
|
setNumericVariableBetweenBounds(name: string, value: number, minInclusive: number, maxExclusive: number, suffix: string, scope?: HTMLElement, prefix?: string): boolean;
|
|
8
8
|
modifyNumericVariableBetweenBounds(name: string, delta: number, min: number, max: number, suffix: string, scope?: HTMLElement, prefix?: string): boolean;
|
|
@@ -4,14 +4,15 @@ import { StringRatchet } from "@bitblit/ratchet-common/lang/string-ratchet";
|
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
export class CssThemeService {
|
|
6
6
|
setCssVariable(name, value, scope = document.documentElement, prefix = '--') {
|
|
7
|
+
Logger.debug('Setting %s to %s', prefix + name, value);
|
|
7
8
|
scope.style.setProperty(prefix + name, value);
|
|
8
9
|
}
|
|
9
10
|
getCssVariable(name, scope = document.documentElement, prefix = '--') {
|
|
10
11
|
return StringRatchet.trimToNull(getComputedStyle(scope).getPropertyValue(prefix + name));
|
|
11
12
|
}
|
|
12
|
-
applyTheme(rec, prefix = '--') {
|
|
13
|
+
applyTheme(rec, scope = document.documentElement, prefix = '--') {
|
|
13
14
|
Object.keys(rec).forEach(k => {
|
|
14
|
-
this.setCssVariable(
|
|
15
|
+
this.setCssVariable(k, rec[k], scope, prefix);
|
|
15
16
|
});
|
|
16
17
|
}
|
|
17
18
|
setNumericVariable(name, value, suffix, scope = document.documentElement, prefix = '--') {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"css-theme.service.js","sourceRoot":"","sources":["../../src/services/css-theme.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,MAAM,EAAE,MAAM,uCAAuC,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAE,MAAM,6CAA6C,CAAC;;AAmC5E,MAAM,OAAO,eAAe;IAEnB,cAAc,CAAC,IAAY,EAAE,KAAa,EAAE,QAAqB,QAAQ,CAAC,eAAe,EAAE,SAAe,IAAI;QACnH,KAAK,CAAC,KAAK,CAAC,WAAW,CAAC,MAAM,GAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC9C,CAAC;IAEM,cAAc,CAAC,IAAY,EAAE,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,CAAC;QAC7F,CAAC;aAAM,CAAC;YACN,MAAM,CAAC,IAAI,CAAC,yBAAyB,EAAE,IAAI,CAAC,CAAC;YAC7C,OAAO,KAAK,CAAC;QACf,CAAC;IAEH,CAAC;yGA3CU,eAAe;kDAAf,eAAe,WAAf,eAAe,mBADH,MAAM;;iFAClB,eAAe;cAD3B,UAAU;eAAC,EAAC,UAAU,EAAE,MAAM,EAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grouped-process-list.js","sourceRoot":"","sources":["../../../src/services/process-monitor/grouped-process-list.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grouped-processes.js","sourceRoot":"","sources":["../../../src/services/process-monitor/grouped-processes.ts"],"names":[],"mappings":""}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { BehaviorSubject } from "rxjs";
|
|
2
1
|
import { ProcessMonitorState } from "./process-monitor-state";
|
|
2
|
+
import { WritableSignal } from "@angular/core";
|
|
3
3
|
export interface ProcessHolder<T> {
|
|
4
4
|
guid: string;
|
|
5
5
|
proc: Promise<T>;
|
|
6
|
-
input:
|
|
6
|
+
input: WritableSignal<ProcessMonitorState>;
|
|
7
7
|
}
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
+
import { WritableSignal } from "@angular/core";
|
|
1
2
|
import { ProcessMonitorState } from './process-monitor-state';
|
|
2
|
-
import {
|
|
3
|
+
import { GroupedProcessList } from "./grouped-process-list.ts";
|
|
3
4
|
import * as i0 from "@angular/core";
|
|
4
5
|
export declare class ProcessMonitorService {
|
|
5
6
|
static readonly DEFAULT_GROUP: string;
|
|
6
7
|
private processMap;
|
|
7
8
|
private modalProcessMap;
|
|
8
9
|
get showDisplay(): boolean;
|
|
9
|
-
get
|
|
10
|
+
get showModalDisplay(): boolean;
|
|
11
|
+
processes: WritableSignal<GroupedProcessList>;
|
|
12
|
+
modalProcesses: WritableSignal<GroupedProcessList>;
|
|
10
13
|
fafMonitorProcessDefaultLabel<T>(promise: Promise<T>, modal?: boolean): void;
|
|
11
|
-
fafMonitorProcessSimple<T>(promise: Promise<T>, label: string
|
|
12
|
-
fafMonitorProcess<T>(promise: Promise<T>, descriptor: ProcessMonitorState |
|
|
14
|
+
fafMonitorProcessSimple<T>(promise: Promise<T>, label: string, modal?: boolean): void;
|
|
15
|
+
fafMonitorProcess<T>(promise: Promise<T>, descriptor: ProcessMonitorState | WritableSignal<ProcessMonitorState>, modal?: boolean): void;
|
|
13
16
|
monitorProcessDefaultLabel<T>(promise: Promise<T>, modal?: boolean): Promise<T>;
|
|
14
|
-
monitorProcessSimple<T>(promise: Promise<T>, label: string
|
|
15
|
-
monitorProcess<T>(promise: Promise<T>, descriptor: ProcessMonitorState |
|
|
17
|
+
monitorProcessSimple<T>(promise: Promise<T>, label: string, modal?: boolean): Promise<T>;
|
|
18
|
+
monitorProcess<T>(promise: Promise<T>, descriptor: ProcessMonitorState | WritableSignal<ProcessMonitorState>, modal?: boolean): Promise<T>;
|
|
16
19
|
private innerMonitorProcess;
|
|
17
20
|
private mapToGroupedProcessList;
|
|
18
|
-
get processes(): BehaviorSubject<ProcessMonitorState>[];
|
|
19
|
-
get modalProcesses(): BehaviorSubject<ProcessMonitorState>[];
|
|
20
21
|
static labelToProcessInput(label: string): ProcessMonitorState;
|
|
21
|
-
static labelSubjectToProcessInput(label: BehaviorSubject<string>): BehaviorSubject<ProcessMonitorState>;
|
|
22
22
|
private defaultInput;
|
|
23
23
|
static ɵfac: i0.ɵɵFactoryDeclaration<ProcessMonitorService, never>;
|
|
24
24
|
static ɵprov: i0.ɵɵInjectableDeclaration<ProcessMonitorService>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { Injectable } from
|
|
1
|
+
import { Injectable, signal } from "@angular/core";
|
|
2
2
|
import { RequireRatchet } from "@bitblit/ratchet-common/lang/require-ratchet";
|
|
3
|
-
import { BehaviorSubject } from "rxjs";
|
|
4
3
|
import { StringRatchet } from "@bitblit/ratchet-common/lang/string-ratchet";
|
|
5
4
|
import { No } from "@bitblit/ratchet-common/lang/no";
|
|
5
|
+
import { AcuteCommonTypeGuards } from "../../acute-common-type-guards.js";
|
|
6
6
|
import * as i0 from "@angular/core";
|
|
7
7
|
export class ProcessMonitorService {
|
|
8
8
|
static DEFAULT_GROUP = 'Long-Running Process';
|
|
@@ -11,48 +11,38 @@ export class ProcessMonitorService {
|
|
|
11
11
|
get showDisplay() {
|
|
12
12
|
return this.processMap.size > 0;
|
|
13
13
|
}
|
|
14
|
-
get
|
|
14
|
+
get showModalDisplay() {
|
|
15
15
|
return this.modalProcessMap.size > 0;
|
|
16
16
|
}
|
|
17
|
+
processes = signal({ groups: [] });
|
|
18
|
+
modalProcesses = signal({ groups: [] });
|
|
17
19
|
fafMonitorProcessDefaultLabel(promise, modal) {
|
|
18
20
|
this.monitorProcessSimple(promise, 'Processing...', modal).then(No.op);
|
|
19
21
|
}
|
|
20
22
|
fafMonitorProcessSimple(promise, label, modal) {
|
|
21
|
-
|
|
22
|
-
ProcessMonitorService.labelSubjectToProcessInput(label) :
|
|
23
|
-
new BehaviorSubject(ProcessMonitorService.labelToProcessInput(label));
|
|
24
|
-
this.monitorProcess(promise, descriptor, modal).then(No.op);
|
|
23
|
+
this.monitorProcessSimple(promise, label, modal).then(No.op);
|
|
25
24
|
}
|
|
26
25
|
fafMonitorProcess(promise, descriptor, modal) {
|
|
27
26
|
const map = modal ? this.modalProcessMap : this.processMap;
|
|
28
|
-
this.
|
|
27
|
+
const sig = modal ? this.modalProcesses : this.processes;
|
|
28
|
+
this.innerMonitorProcess(promise, descriptor, map, sig).then(No.op);
|
|
29
29
|
}
|
|
30
30
|
async monitorProcessDefaultLabel(promise, modal) {
|
|
31
31
|
return this.monitorProcessSimple(promise, 'Processing...', modal);
|
|
32
32
|
}
|
|
33
33
|
async monitorProcessSimple(promise, label, modal) {
|
|
34
|
-
const descriptor = label
|
|
35
|
-
ProcessMonitorService.labelSubjectToProcessInput(label) :
|
|
36
|
-
new BehaviorSubject(ProcessMonitorService.labelToProcessInput(label));
|
|
34
|
+
const descriptor = signal(ProcessMonitorService.labelToProcessInput(label));
|
|
37
35
|
return this.monitorProcess(promise, descriptor, modal);
|
|
38
36
|
}
|
|
39
37
|
async monitorProcess(promise, descriptor, modal) {
|
|
40
38
|
const map = modal ? this.modalProcessMap : this.processMap;
|
|
41
|
-
|
|
39
|
+
const sig = modal ? this.modalProcesses : this.processes;
|
|
40
|
+
return this.innerMonitorProcess(promise, descriptor, map, sig);
|
|
42
41
|
}
|
|
43
|
-
async innerMonitorProcess(promise, descriptor, map) {
|
|
42
|
+
async innerMonitorProcess(promise, descriptor, map, sigOut) {
|
|
44
43
|
RequireRatchet.notNullOrUndefined(promise, 'promise');
|
|
45
44
|
RequireRatchet.notNullOrUndefined(descriptor, 'descriptor');
|
|
46
|
-
|
|
47
|
-
if (descriptor instanceof BehaviorSubject) {
|
|
48
|
-
const init = Object.assign({}, this.defaultInput(), descriptor.value);
|
|
49
|
-
bh = descriptor;
|
|
50
|
-
bh.next(init);
|
|
51
|
-
}
|
|
52
|
-
else {
|
|
53
|
-
const init = Object.assign({}, this.defaultInput(), descriptor);
|
|
54
|
-
bh = new BehaviorSubject(init);
|
|
55
|
-
}
|
|
45
|
+
const bh = AcuteCommonTypeGuards.isProcessMonitorState(descriptor) ? signal(descriptor) : descriptor;
|
|
56
46
|
const holder = {
|
|
57
47
|
guid: StringRatchet.createRandomHexString(10),
|
|
58
48
|
proc: promise,
|
|
@@ -62,44 +52,34 @@ export class ProcessMonitorService {
|
|
|
62
52
|
const finished = holder.proc.finally(() => {
|
|
63
53
|
map.delete(holder.guid);
|
|
64
54
|
});
|
|
55
|
+
const newList = this.mapToGroupedProcessList(map);
|
|
56
|
+
sigOut.set(newList);
|
|
65
57
|
return finished;
|
|
66
58
|
}
|
|
67
59
|
mapToGroupedProcessList(map) {
|
|
68
60
|
if (map.size > 0) {
|
|
69
61
|
}
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
rval.push(tmp[0]);
|
|
89
|
-
}
|
|
90
|
-
tmp.splice(0, lastIdx);
|
|
91
|
-
}
|
|
92
|
-
if (tmp.length) {
|
|
93
|
-
rval.push(tmp[0]);
|
|
62
|
+
const rval = {
|
|
63
|
+
groups: []
|
|
64
|
+
};
|
|
65
|
+
if (map) {
|
|
66
|
+
map.keys().forEach((key) => {
|
|
67
|
+
const v = map.get(key);
|
|
68
|
+
const group = StringRatchet.trimToEmpty(v.input().group);
|
|
69
|
+
let out = rval.groups.find(s => s.group === group);
|
|
70
|
+
if (!out) {
|
|
71
|
+
out = {
|
|
72
|
+
group: group,
|
|
73
|
+
processes: []
|
|
74
|
+
};
|
|
75
|
+
rval.groups.push(out);
|
|
76
|
+
}
|
|
77
|
+
;
|
|
78
|
+
out.processes.push(v);
|
|
79
|
+
});
|
|
94
80
|
}
|
|
95
81
|
return rval;
|
|
96
82
|
}
|
|
97
|
-
get processes() {
|
|
98
|
-
return this.mapToGroupedProcessList(this.processMap);
|
|
99
|
-
}
|
|
100
|
-
get modalProcesses() {
|
|
101
|
-
return this.mapToGroupedProcessList(this.modalProcessMap);
|
|
102
|
-
}
|
|
103
83
|
static labelToProcessInput(label) {
|
|
104
84
|
return {
|
|
105
85
|
label: label,
|
|
@@ -108,12 +88,6 @@ export class ProcessMonitorService {
|
|
|
108
88
|
percentComplete: null
|
|
109
89
|
};
|
|
110
90
|
}
|
|
111
|
-
static labelSubjectToProcessInput(label) {
|
|
112
|
-
const val = ProcessMonitorService.labelToProcessInput(label.value);
|
|
113
|
-
const rval = new BehaviorSubject(val);
|
|
114
|
-
label.subscribe((val) => rval.next(ProcessMonitorService.labelToProcessInput(val)));
|
|
115
|
-
return rval;
|
|
116
|
-
}
|
|
117
91
|
defaultInput() {
|
|
118
92
|
return {
|
|
119
93
|
label: 'Process',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"process-monitor-service.js","sourceRoot":"","sources":["../../../src/services/process-monitor/process-monitor-service.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"process-monitor-service.js","sourceRoot":"","sources":["../../../src/services/process-monitor/process-monitor-service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,EAAkB,MAAM,eAAe,CAAC;AACnE,OAAO,EAAC,cAAc,EAAC,MAAM,8CAA8C,CAAC;AAE5E,OAAO,EAAC,aAAa,EAAC,MAAM,6CAA6C,CAAC;AAC1E,OAAO,EAAC,EAAE,EAAC,MAAM,iCAAiC,CAAC;AAEnD,OAAO,EAAE,qBAAqB,EAAE,MAAM,mCAAmC,CAAC;;AAM1E,MAAM,OAAO,qBAAqB;IACzB,MAAM,CAAU,aAAa,GAAW,sBAAsB,CAAC;IAE9D,UAAU,GAAmC,IAAI,GAAG,EAA6B,CAAC;IAClF,eAAe,GAAmC,IAAI,GAAG,EAA6B,CAAC;IAE/F,IAAW,WAAW;QACpB,OAAO,IAAI,CAAC,UAAU,CAAC,IAAI,GAAC,CAAC,CAAC;IAChC,CAAC;IAED,IAAW,gBAAgB;QACzB,OAAO,IAAI,CAAC,eAAe,CAAC,IAAI,GAAC,CAAC,CAAC;IACrC,CAAC;IAEM,SAAS,GAAuC,MAAM,CAAC,EAAC,MAAM,EAAC,EAAE,EAAC,CAAC,CAAC;IACpE,cAAc,GAAuC,MAAM,CAAC,EAAC,MAAM,EAAC,EAAE,EAAC,CAAC,CAAC;IAGzE,6BAA6B,CAAI,OAAmB,EAAE,KAAe;QAC1E,IAAI,CAAC,oBAAoB,CAAC,OAAO,EAAE,eAAe,EAAE,KAAK,CAAC,CAAC,IAAI,CAAC,E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
|
{
|
|
2
2
|
"name": "@bitblit/ngx-acute-common",
|
|
3
|
-
"version": "5.1.
|
|
3
|
+
"version": "5.1.649-alpha",
|
|
4
4
|
"description": "Library for using angular",
|
|
5
5
|
"module": "lib/index.js",
|
|
6
6
|
"types": "lib/index.d.ts",
|
|
@@ -44,8 +44,8 @@
|
|
|
44
44
|
"@angular/platform-browser": "19.2.9",
|
|
45
45
|
"@angular/platform-browser-dynamic": "19.2.9",
|
|
46
46
|
"@angular/router": "19.2.9",
|
|
47
|
-
"@bitblit/ratchet-common": "5.1.
|
|
48
|
-
"@bitblit/ratchet-graphql": "5.1.
|
|
47
|
+
"@bitblit/ratchet-common": "5.1.649-alpha",
|
|
48
|
+
"@bitblit/ratchet-graphql": "5.1.649-alpha",
|
|
49
49
|
"primeflex": "4.0.0",
|
|
50
50
|
"primeicons": "7.0.0",
|
|
51
51
|
"primeng": "19.1.2",
|
|
@@ -62,8 +62,8 @@
|
|
|
62
62
|
"@angular/platform-browser": "^19.2.9",
|
|
63
63
|
"@angular/platform-browser-dynamic": "^19.2.9",
|
|
64
64
|
"@angular/router": "^19.2.9",
|
|
65
|
-
"@bitblit/ratchet-common": "5.1.
|
|
66
|
-
"@bitblit/ratchet-graphql": "5.1.
|
|
65
|
+
"@bitblit/ratchet-common": "5.1.649-alpha",
|
|
66
|
+
"@bitblit/ratchet-graphql": "5.1.649-alpha",
|
|
67
67
|
"primeflex": "4.0.0",
|
|
68
68
|
"primeicons": "7.0.0",
|
|
69
69
|
"primeng": "19.1.2",
|
|
@@ -72,6 +72,6 @@
|
|
|
72
72
|
},
|
|
73
73
|
"devDependencies": {
|
|
74
74
|
"@angular/compiler-cli": "19.2.9",
|
|
75
|
-
"@bitblit/ratchet-node-only": "5.1.
|
|
75
|
+
"@bitblit/ratchet-node-only": "5.1.649-alpha"
|
|
76
76
|
}
|
|
77
77
|
}
|