@memberjunction/ng-dashboards 2.85.0 → 2.86.0
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/dist/ComponentStudio/component-studio-dashboard.component.d.ts +81 -0
- package/dist/ComponentStudio/component-studio-dashboard.component.d.ts.map +1 -0
- package/dist/ComponentStudio/component-studio-dashboard.component.js +751 -0
- package/dist/ComponentStudio/component-studio-dashboard.component.js.map +1 -0
- package/dist/ComponentStudio/components/component-dependencies.component.d.ts +19 -0
- package/dist/ComponentStudio/components/component-dependencies.component.d.ts.map +1 -0
- package/dist/ComponentStudio/components/component-dependencies.component.js +138 -0
- package/dist/ComponentStudio/components/component-dependencies.component.js.map +1 -0
- package/dist/ComponentStudio/components/component-preview.component.d.ts +18 -0
- package/dist/ComponentStudio/components/component-preview.component.d.ts.map +1 -0
- package/dist/ComponentStudio/components/component-preview.component.js +86 -0
- package/dist/ComponentStudio/components/component-preview.component.js.map +1 -0
- package/dist/ComponentStudio/components/component-studio-settings.component.d.ts +29 -0
- package/dist/ComponentStudio/components/component-studio-settings.component.d.ts.map +1 -0
- package/dist/ComponentStudio/components/component-studio-settings.component.js +212 -0
- package/dist/ComponentStudio/components/component-studio-settings.component.js.map +1 -0
- package/dist/ComponentStudio/index.d.ts +5 -0
- package/dist/ComponentStudio/index.d.ts.map +1 -0
- package/dist/ComponentStudio/index.js +5 -0
- package/dist/ComponentStudio/index.js.map +1 -0
- package/dist/module.d.ts +22 -16
- package/dist/module.d.ts.map +1 -1
- package/dist/module.js +32 -7
- package/dist/module.js.map +1 -1
- package/dist/public-api.d.ts +1 -0
- package/dist/public-api.d.ts.map +1 -1
- package/dist/public-api.js +3 -0
- package/dist/public-api.js.map +1 -1
- package/package.json +10 -10
|
@@ -0,0 +1,751 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
import { Component, ChangeDetectionStrategy } from '@angular/core';
|
|
8
|
+
import { BaseDashboard } from '../generic/base-dashboard';
|
|
9
|
+
import { RegisterClass } from '@memberjunction/global';
|
|
10
|
+
import { RunView } from '@memberjunction/core';
|
|
11
|
+
import { Subject, BehaviorSubject, combineLatest } from 'rxjs';
|
|
12
|
+
import { debounceTime, distinctUntilChanged, takeUntil } from 'rxjs/operators';
|
|
13
|
+
import { SharedService } from '@memberjunction/ng-shared';
|
|
14
|
+
import * as i0 from "@angular/core";
|
|
15
|
+
import * as i1 from "@angular/common";
|
|
16
|
+
import * as i2 from "@progress/kendo-angular-inputs";
|
|
17
|
+
import * as i3 from "@progress/kendo-angular-dialog";
|
|
18
|
+
import * as i4 from "@progress/kendo-angular-buttons";
|
|
19
|
+
import * as i5 from "@progress/kendo-angular-grid";
|
|
20
|
+
import * as i6 from "./components/component-preview.component";
|
|
21
|
+
import * as i7 from "./components/component-dependencies.component";
|
|
22
|
+
import * as i8 from "./components/component-studio-settings.component";
|
|
23
|
+
const _forTrack0 = ($index, $item) => $item.ID;
|
|
24
|
+
function ComponentStudioDashboardComponent_Conditional_2_Template(rf, ctx) { if (rf & 1) {
|
|
25
|
+
i0.ɵɵelementStart(0, "div", 2)(1, "div", 4)(2, "div", 5);
|
|
26
|
+
i0.ɵɵelement(3, "i", 6);
|
|
27
|
+
i0.ɵɵelementEnd();
|
|
28
|
+
i0.ɵɵelementStart(4, "div", 7);
|
|
29
|
+
i0.ɵɵtext(5, "Loading Component Studio...");
|
|
30
|
+
i0.ɵɵelementEnd()()();
|
|
31
|
+
} }
|
|
32
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_14_ng_template_10_Template(rf, ctx) { if (rf & 1) {
|
|
33
|
+
i0.ɵɵelement(0, "i", 38);
|
|
34
|
+
} }
|
|
35
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_14_For_16_Template(rf, ctx) { if (rf & 1) {
|
|
36
|
+
const _r4 = i0.ɵɵgetCurrentView();
|
|
37
|
+
i0.ɵɵelementStart(0, "label", 34)(1, "input", 35);
|
|
38
|
+
i0.ɵɵlistener("change", function ComponentStudioDashboardComponent_Conditional_3_Conditional_14_For_16_Template_input_change_1_listener($event) { const type_r5 = i0.ɵɵrestoreView(_r4).$implicit; const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.onTypeFilterChange(type_r5, $event.target.checked)); });
|
|
39
|
+
i0.ɵɵelementEnd();
|
|
40
|
+
i0.ɵɵelement(2, "span", 39);
|
|
41
|
+
i0.ɵɵtext(3);
|
|
42
|
+
i0.ɵɵelementEnd();
|
|
43
|
+
} if (rf & 2) {
|
|
44
|
+
const type_r5 = ctx.$implicit;
|
|
45
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
46
|
+
i0.ɵɵadvance();
|
|
47
|
+
i0.ɵɵproperty("checked", ctx_r1.selectedTypes$.value.has(type_r5));
|
|
48
|
+
i0.ɵɵadvance();
|
|
49
|
+
i0.ɵɵstyleProp("background-color", ctx_r1.getComponentTypeColor(type_r5));
|
|
50
|
+
i0.ɵɵadvance();
|
|
51
|
+
i0.ɵɵtextInterpolate1(" ", type_r5, " ");
|
|
52
|
+
} }
|
|
53
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_14_For_22_Template(rf, ctx) { if (rf & 1) {
|
|
54
|
+
const _r6 = i0.ɵɵgetCurrentView();
|
|
55
|
+
i0.ɵɵelementStart(0, "label", 34)(1, "input", 35);
|
|
56
|
+
i0.ɵɵlistener("change", function ComponentStudioDashboardComponent_Conditional_3_Conditional_14_For_22_Template_input_change_1_listener($event) { const status_r7 = i0.ɵɵrestoreView(_r6).$implicit; const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.onStatusFilterChange(status_r7, $event.target.checked)); });
|
|
57
|
+
i0.ɵɵelementEnd();
|
|
58
|
+
i0.ɵɵelementStart(2, "span", 40);
|
|
59
|
+
i0.ɵɵtext(3);
|
|
60
|
+
i0.ɵɵelementEnd()();
|
|
61
|
+
} if (rf & 2) {
|
|
62
|
+
const status_r7 = ctx.$implicit;
|
|
63
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
64
|
+
i0.ɵɵadvance();
|
|
65
|
+
i0.ɵɵproperty("checked", ctx_r1.selectedStatuses$.value.has(status_r7));
|
|
66
|
+
i0.ɵɵadvance();
|
|
67
|
+
i0.ɵɵproperty("ngClass", ctx_r1.getStatusBadgeClass(status_r7));
|
|
68
|
+
i0.ɵɵadvance();
|
|
69
|
+
i0.ɵɵtextInterpolate(status_r7);
|
|
70
|
+
} }
|
|
71
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_14_Template(rf, ctx) { if (rf & 1) {
|
|
72
|
+
const _r3 = i0.ɵɵgetCurrentView();
|
|
73
|
+
i0.ɵɵelementStart(0, "div", 19)(1, "div", 27)(2, "h3");
|
|
74
|
+
i0.ɵɵtext(3, "Filters");
|
|
75
|
+
i0.ɵɵelementEnd();
|
|
76
|
+
i0.ɵɵelementStart(4, "button", 28);
|
|
77
|
+
i0.ɵɵlistener("click", function ComponentStudioDashboardComponent_Conditional_3_Conditional_14_Template_button_click_4_listener() { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.clearFilters()); });
|
|
78
|
+
i0.ɵɵtext(5, " Clear All ");
|
|
79
|
+
i0.ɵɵelementEnd()();
|
|
80
|
+
i0.ɵɵelementStart(6, "div", 29)(7, "label", 30);
|
|
81
|
+
i0.ɵɵtext(8, "Search");
|
|
82
|
+
i0.ɵɵelementEnd();
|
|
83
|
+
i0.ɵɵelementStart(9, "kendo-textbox", 31);
|
|
84
|
+
i0.ɵɵlistener("valueChange", function ComponentStudioDashboardComponent_Conditional_3_Conditional_14_Template_kendo_textbox_valueChange_9_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.onSearchChange($event)); });
|
|
85
|
+
i0.ɵɵtemplate(10, ComponentStudioDashboardComponent_Conditional_3_Conditional_14_ng_template_10_Template, 1, 0, "ng-template", 32);
|
|
86
|
+
i0.ɵɵelementEnd()();
|
|
87
|
+
i0.ɵɵelementStart(11, "div", 29)(12, "label", 30);
|
|
88
|
+
i0.ɵɵtext(13, "Component Type");
|
|
89
|
+
i0.ɵɵelementEnd();
|
|
90
|
+
i0.ɵɵelementStart(14, "div", 33);
|
|
91
|
+
i0.ɵɵrepeaterCreate(15, ComponentStudioDashboardComponent_Conditional_3_Conditional_14_For_16_Template, 4, 4, "label", 34, i0.ɵɵrepeaterTrackByIdentity);
|
|
92
|
+
i0.ɵɵelementEnd()();
|
|
93
|
+
i0.ɵɵelementStart(17, "div", 29)(18, "label", 30);
|
|
94
|
+
i0.ɵɵtext(19, "Status");
|
|
95
|
+
i0.ɵɵelementEnd();
|
|
96
|
+
i0.ɵɵelementStart(20, "div", 33);
|
|
97
|
+
i0.ɵɵrepeaterCreate(21, ComponentStudioDashboardComponent_Conditional_3_Conditional_14_For_22_Template, 4, 3, "label", 34, i0.ɵɵrepeaterTrackByIdentity);
|
|
98
|
+
i0.ɵɵelementEnd()();
|
|
99
|
+
i0.ɵɵelementStart(23, "div", 29)(24, "label", 30);
|
|
100
|
+
i0.ɵɵtext(25, "Source");
|
|
101
|
+
i0.ɵɵelementEnd();
|
|
102
|
+
i0.ɵɵelementStart(26, "div", 33)(27, "label", 34)(28, "input", 35);
|
|
103
|
+
i0.ɵɵlistener("change", function ComponentStudioDashboardComponent_Conditional_3_Conditional_14_Template_input_change_28_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.onSourceFilterChange("Local", $event.target.checked)); });
|
|
104
|
+
i0.ɵɵelementEnd();
|
|
105
|
+
i0.ɵɵelement(29, "i", 36);
|
|
106
|
+
i0.ɵɵtext(30, " Local ");
|
|
107
|
+
i0.ɵɵelementEnd();
|
|
108
|
+
i0.ɵɵelementStart(31, "label", 34)(32, "input", 35);
|
|
109
|
+
i0.ɵɵlistener("change", function ComponentStudioDashboardComponent_Conditional_3_Conditional_14_Template_input_change_32_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.onSourceFilterChange("Registry", $event.target.checked)); });
|
|
110
|
+
i0.ɵɵelementEnd();
|
|
111
|
+
i0.ɵɵelement(33, "i", 37);
|
|
112
|
+
i0.ɵɵtext(34, " Registry ");
|
|
113
|
+
i0.ɵɵelementEnd()()()();
|
|
114
|
+
} if (rf & 2) {
|
|
115
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
116
|
+
i0.ɵɵadvance(4);
|
|
117
|
+
i0.ɵɵproperty("fillMode", "flat")("size", "small");
|
|
118
|
+
i0.ɵɵadvance(5);
|
|
119
|
+
i0.ɵɵproperty("value", ctx_r1.searchQuery$.value)("clearButton", true);
|
|
120
|
+
i0.ɵɵadvance(6);
|
|
121
|
+
i0.ɵɵrepeater(ctx_r1.componentTypes);
|
|
122
|
+
i0.ɵɵadvance(6);
|
|
123
|
+
i0.ɵɵrepeater(ctx_r1.componentStatuses);
|
|
124
|
+
i0.ɵɵadvance(7);
|
|
125
|
+
i0.ɵɵproperty("checked", ctx_r1.selectedSources$.value.has("Local"));
|
|
126
|
+
i0.ɵɵadvance(4);
|
|
127
|
+
i0.ɵɵproperty("checked", ctx_r1.selectedSources$.value.has("Registry"));
|
|
128
|
+
} }
|
|
129
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_4_For_2_Conditional_21_Template(rf, ctx) { if (rf & 1) {
|
|
130
|
+
i0.ɵɵelement(0, "i", 60);
|
|
131
|
+
} }
|
|
132
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_4_For_2_Conditional_22_Template(rf, ctx) { if (rf & 1) {
|
|
133
|
+
i0.ɵɵelement(0, "i", 61);
|
|
134
|
+
} }
|
|
135
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_4_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
136
|
+
const _r8 = i0.ɵɵgetCurrentView();
|
|
137
|
+
i0.ɵɵelementStart(0, "div", 46);
|
|
138
|
+
i0.ɵɵlistener("click", function ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_4_For_2_Template_div_click_0_listener() { const component_r9 = i0.ɵɵrestoreView(_r8).$implicit; const ctx_r1 = i0.ɵɵnextContext(4); return i0.ɵɵresetView(ctx_r1.selectComponent(component_r9)); });
|
|
139
|
+
i0.ɵɵelementStart(1, "div", 47)(2, "div", 48);
|
|
140
|
+
i0.ɵɵtext(3);
|
|
141
|
+
i0.ɵɵelementEnd();
|
|
142
|
+
i0.ɵɵelementStart(4, "div", 49);
|
|
143
|
+
i0.ɵɵtext(5);
|
|
144
|
+
i0.ɵɵelementEnd()();
|
|
145
|
+
i0.ɵɵelementStart(6, "div", 50)(7, "h4", 51);
|
|
146
|
+
i0.ɵɵtext(8);
|
|
147
|
+
i0.ɵɵelementEnd();
|
|
148
|
+
i0.ɵɵelementStart(9, "div", 52);
|
|
149
|
+
i0.ɵɵtext(10);
|
|
150
|
+
i0.ɵɵelementEnd();
|
|
151
|
+
i0.ɵɵelementStart(11, "p", 53);
|
|
152
|
+
i0.ɵɵtext(12);
|
|
153
|
+
i0.ɵɵelementEnd();
|
|
154
|
+
i0.ɵɵelementStart(13, "div", 54);
|
|
155
|
+
i0.ɵɵelement(14, "i", 55);
|
|
156
|
+
i0.ɵɵtext(15);
|
|
157
|
+
i0.ɵɵelementEnd()();
|
|
158
|
+
i0.ɵɵelementStart(16, "div", 56)(17, "div", 57);
|
|
159
|
+
i0.ɵɵelement(18, "i", 58);
|
|
160
|
+
i0.ɵɵtext(19);
|
|
161
|
+
i0.ɵɵelementEnd();
|
|
162
|
+
i0.ɵɵelementStart(20, "div", 59);
|
|
163
|
+
i0.ɵɵtemplate(21, ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_4_For_2_Conditional_21_Template, 1, 0, "i", 60)(22, ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_4_For_2_Conditional_22_Template, 1, 0, "i", 61);
|
|
164
|
+
i0.ɵɵelementEnd()()();
|
|
165
|
+
} if (rf & 2) {
|
|
166
|
+
const component_r9 = ctx.$implicit;
|
|
167
|
+
const ctx_r1 = i0.ɵɵnextContext(4);
|
|
168
|
+
i0.ɵɵclassProp("selected", ctx_r1.selectedComponentId === component_r9.ID);
|
|
169
|
+
i0.ɵɵadvance(2);
|
|
170
|
+
i0.ɵɵstyleProp("background-color", ctx_r1.getComponentTypeColor(component_r9.Type || "Other"));
|
|
171
|
+
i0.ɵɵadvance();
|
|
172
|
+
i0.ɵɵtextInterpolate1(" ", component_r9.Type || "Other", " ");
|
|
173
|
+
i0.ɵɵadvance();
|
|
174
|
+
i0.ɵɵproperty("ngClass", ctx_r1.getStatusBadgeClass(component_r9.Status || "Draft"));
|
|
175
|
+
i0.ɵɵadvance();
|
|
176
|
+
i0.ɵɵtextInterpolate1(" ", component_r9.Status, " ");
|
|
177
|
+
i0.ɵɵadvance(3);
|
|
178
|
+
i0.ɵɵtextInterpolate(component_r9.Name);
|
|
179
|
+
i0.ɵɵadvance(2);
|
|
180
|
+
i0.ɵɵtextInterpolate1("v", component_r9.Version, "");
|
|
181
|
+
i0.ɵɵadvance(2);
|
|
182
|
+
i0.ɵɵtextInterpolate(component_r9.Description || "No description available");
|
|
183
|
+
i0.ɵɵadvance(3);
|
|
184
|
+
i0.ɵɵtextInterpolate1(" ", component_r9.Namespace || "root", " ");
|
|
185
|
+
i0.ɵɵadvance(4);
|
|
186
|
+
i0.ɵɵtextInterpolate1(" ", component_r9.DeveloperOrganization || component_r9.DeveloperName || "Unknown", " ");
|
|
187
|
+
i0.ɵɵadvance(2);
|
|
188
|
+
i0.ɵɵconditional(!component_r9.SourceRegistryID ? 21 : 22);
|
|
189
|
+
} }
|
|
190
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_4_Template(rf, ctx) { if (rf & 1) {
|
|
191
|
+
i0.ɵɵelementStart(0, "div", 43);
|
|
192
|
+
i0.ɵɵrepeaterCreate(1, ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_4_For_2_Template, 23, 13, "div", 45, _forTrack0);
|
|
193
|
+
i0.ɵɵelementEnd();
|
|
194
|
+
} if (rf & 2) {
|
|
195
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
196
|
+
i0.ɵɵadvance();
|
|
197
|
+
i0.ɵɵrepeater(ctx_r1.filteredComponents$.value);
|
|
198
|
+
} }
|
|
199
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_5_ng_template_2_Template(rf, ctx) { if (rf & 1) {
|
|
200
|
+
i0.ɵɵelementStart(0, "div", 71);
|
|
201
|
+
i0.ɵɵelement(1, "span", 72);
|
|
202
|
+
i0.ɵɵtext(2);
|
|
203
|
+
i0.ɵɵelementEnd();
|
|
204
|
+
} if (rf & 2) {
|
|
205
|
+
const dataItem_r11 = ctx.$implicit;
|
|
206
|
+
const ctx_r1 = i0.ɵɵnextContext(4);
|
|
207
|
+
i0.ɵɵadvance();
|
|
208
|
+
i0.ɵɵstyleProp("background-color", ctx_r1.getComponentTypeColor(dataItem_r11.Type || "Other"));
|
|
209
|
+
i0.ɵɵadvance();
|
|
210
|
+
i0.ɵɵtextInterpolate1(" ", dataItem_r11.Name, " ");
|
|
211
|
+
} }
|
|
212
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_5_ng_template_6_Template(rf, ctx) { if (rf & 1) {
|
|
213
|
+
i0.ɵɵelementStart(0, "span", 40);
|
|
214
|
+
i0.ɵɵtext(1);
|
|
215
|
+
i0.ɵɵelementEnd();
|
|
216
|
+
} if (rf & 2) {
|
|
217
|
+
const dataItem_r12 = ctx.$implicit;
|
|
218
|
+
const ctx_r1 = i0.ɵɵnextContext(4);
|
|
219
|
+
i0.ɵɵproperty("ngClass", ctx_r1.getStatusBadgeClass(dataItem_r12.Status || "Draft"));
|
|
220
|
+
i0.ɵɵadvance();
|
|
221
|
+
i0.ɵɵtextInterpolate1(" ", dataItem_r12.Status, " ");
|
|
222
|
+
} }
|
|
223
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_5_Template(rf, ctx) { if (rf & 1) {
|
|
224
|
+
const _r10 = i0.ɵɵgetCurrentView();
|
|
225
|
+
i0.ɵɵelementStart(0, "kendo-grid", 62);
|
|
226
|
+
i0.ɵɵlistener("selectionChange", function ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_5_Template_kendo_grid_selectionChange_0_listener($event) { i0.ɵɵrestoreView(_r10); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.selectComponent($event.selectedRows && $event.selectedRows[0] ? $event.selectedRows[0].dataItem : null)); });
|
|
227
|
+
i0.ɵɵelementStart(1, "kendo-grid-column", 63);
|
|
228
|
+
i0.ɵɵtemplate(2, ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_5_ng_template_2_Template, 3, 3, "ng-template", 64);
|
|
229
|
+
i0.ɵɵelementEnd();
|
|
230
|
+
i0.ɵɵelement(3, "kendo-grid-column", 65)(4, "kendo-grid-column", 66);
|
|
231
|
+
i0.ɵɵelementStart(5, "kendo-grid-column", 67);
|
|
232
|
+
i0.ɵɵtemplate(6, ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_5_ng_template_6_Template, 2, 2, "ng-template", 64);
|
|
233
|
+
i0.ɵɵelementEnd();
|
|
234
|
+
i0.ɵɵelement(7, "kendo-grid-column", 68)(8, "kendo-grid-column", 69)(9, "kendo-grid-column", 70);
|
|
235
|
+
i0.ɵɵelementEnd();
|
|
236
|
+
} if (rf & 2) {
|
|
237
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
238
|
+
i0.ɵɵproperty("data", ctx_r1.filteredComponents$.value)("pageSize", 20)("pageable", true)("sortable", true)("filterable", false)("resizable", true)("selectable", true);
|
|
239
|
+
i0.ɵɵadvance();
|
|
240
|
+
i0.ɵɵproperty("width", 250);
|
|
241
|
+
i0.ɵɵadvance(2);
|
|
242
|
+
i0.ɵɵproperty("width", 80);
|
|
243
|
+
i0.ɵɵadvance();
|
|
244
|
+
i0.ɵɵproperty("width", 100);
|
|
245
|
+
i0.ɵɵadvance();
|
|
246
|
+
i0.ɵɵproperty("width", 100);
|
|
247
|
+
i0.ɵɵadvance(2);
|
|
248
|
+
i0.ɵɵproperty("width", 200);
|
|
249
|
+
i0.ɵɵadvance();
|
|
250
|
+
i0.ɵɵproperty("width", 150);
|
|
251
|
+
} }
|
|
252
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Template(rf, ctx) { if (rf & 1) {
|
|
253
|
+
i0.ɵɵelementStart(0, "div", 21)(1, "div", 41)(2, "span", 42);
|
|
254
|
+
i0.ɵɵtext(3);
|
|
255
|
+
i0.ɵɵelementEnd()();
|
|
256
|
+
i0.ɵɵtemplate(4, ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_4_Template, 3, 0, "div", 43)(5, ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Conditional_5_Template, 10, 13, "kendo-grid", 44);
|
|
257
|
+
i0.ɵɵelementEnd();
|
|
258
|
+
} if (rf & 2) {
|
|
259
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
260
|
+
i0.ɵɵadvance(3);
|
|
261
|
+
i0.ɵɵtextInterpolate1(" ", ctx_r1.filteredComponents$.value.length, " components found ");
|
|
262
|
+
i0.ɵɵadvance();
|
|
263
|
+
i0.ɵɵconditional(ctx_r1.viewMode === "grid" ? 4 : 5);
|
|
264
|
+
} }
|
|
265
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_17_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
266
|
+
const _r13 = i0.ɵɵgetCurrentView();
|
|
267
|
+
i0.ɵɵelementStart(0, "mj-component-preview", 75);
|
|
268
|
+
i0.ɵɵlistener("openEntityRecord", function ComponentStudioDashboardComponent_Conditional_3_Conditional_17_Conditional_1_Template_mj_component_preview_openEntityRecord_0_listener($event) { i0.ɵɵrestoreView(_r13); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.onOpenEntityRecord($event)); });
|
|
269
|
+
i0.ɵɵelementEnd();
|
|
270
|
+
} if (rf & 2) {
|
|
271
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
272
|
+
i0.ɵɵproperty("component", ctx_r1.selectedComponent)("componentSpec", ctx_r1.componentSpec);
|
|
273
|
+
} }
|
|
274
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_17_Conditional_2_Template(rf, ctx) { if (rf & 1) {
|
|
275
|
+
i0.ɵɵelementStart(0, "div", 74);
|
|
276
|
+
i0.ɵɵelement(1, "i", 76);
|
|
277
|
+
i0.ɵɵelementStart(2, "h3");
|
|
278
|
+
i0.ɵɵtext(3, "No Component Selected");
|
|
279
|
+
i0.ɵɵelementEnd();
|
|
280
|
+
i0.ɵɵelementStart(4, "p");
|
|
281
|
+
i0.ɵɵtext(5, "Select a component from the Browse tab to preview it");
|
|
282
|
+
i0.ɵɵelementEnd()();
|
|
283
|
+
} }
|
|
284
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_17_Template(rf, ctx) { if (rf & 1) {
|
|
285
|
+
i0.ɵɵelementStart(0, "div", 22);
|
|
286
|
+
i0.ɵɵtemplate(1, ComponentStudioDashboardComponent_Conditional_3_Conditional_17_Conditional_1_Template, 1, 2, "mj-component-preview", 73)(2, ComponentStudioDashboardComponent_Conditional_3_Conditional_17_Conditional_2_Template, 6, 0, "div", 74);
|
|
287
|
+
i0.ɵɵelementEnd();
|
|
288
|
+
} if (rf & 2) {
|
|
289
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
290
|
+
i0.ɵɵadvance();
|
|
291
|
+
i0.ɵɵconditional(ctx_r1.selectedComponent ? 1 : 2);
|
|
292
|
+
} }
|
|
293
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_18_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
294
|
+
const _r14 = i0.ɵɵgetCurrentView();
|
|
295
|
+
i0.ɵɵelementStart(0, "mj-component-dependencies", 78);
|
|
296
|
+
i0.ɵɵlistener("openEntityRecord", function ComponentStudioDashboardComponent_Conditional_3_Conditional_18_Conditional_1_Template_mj_component_dependencies_openEntityRecord_0_listener($event) { i0.ɵɵrestoreView(_r14); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.onOpenEntityRecord($event)); });
|
|
297
|
+
i0.ɵɵelementEnd();
|
|
298
|
+
} if (rf & 2) {
|
|
299
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
300
|
+
i0.ɵɵproperty("component", ctx_r1.selectedComponent);
|
|
301
|
+
} }
|
|
302
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_18_Conditional_2_Template(rf, ctx) { if (rf & 1) {
|
|
303
|
+
i0.ɵɵelementStart(0, "div", 74);
|
|
304
|
+
i0.ɵɵelement(1, "i", 79);
|
|
305
|
+
i0.ɵɵelementStart(2, "h3");
|
|
306
|
+
i0.ɵɵtext(3, "No Component Selected");
|
|
307
|
+
i0.ɵɵelementEnd();
|
|
308
|
+
i0.ɵɵelementStart(4, "p");
|
|
309
|
+
i0.ɵɵtext(5, "Select a component to view its dependencies");
|
|
310
|
+
i0.ɵɵelementEnd()();
|
|
311
|
+
} }
|
|
312
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_18_Template(rf, ctx) { if (rf & 1) {
|
|
313
|
+
i0.ɵɵelementStart(0, "div", 23);
|
|
314
|
+
i0.ɵɵtemplate(1, ComponentStudioDashboardComponent_Conditional_3_Conditional_18_Conditional_1_Template, 1, 1, "mj-component-dependencies", 77)(2, ComponentStudioDashboardComponent_Conditional_3_Conditional_18_Conditional_2_Template, 6, 0, "div", 74);
|
|
315
|
+
i0.ɵɵelementEnd();
|
|
316
|
+
} if (rf & 2) {
|
|
317
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
318
|
+
i0.ɵɵadvance();
|
|
319
|
+
i0.ɵɵconditional(ctx_r1.selectedComponent ? 1 : 2);
|
|
320
|
+
} }
|
|
321
|
+
function ComponentStudioDashboardComponent_Conditional_3_Conditional_19_Template(rf, ctx) { if (rf & 1) {
|
|
322
|
+
const _r15 = i0.ɵɵgetCurrentView();
|
|
323
|
+
i0.ɵɵelementStart(0, "div", 24)(1, "mj-component-studio-settings", 80);
|
|
324
|
+
i0.ɵɵlistener("openEntityRecord", function ComponentStudioDashboardComponent_Conditional_3_Conditional_19_Template_mj_component_studio_settings_openEntityRecord_1_listener($event) { i0.ɵɵrestoreView(_r15); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.onOpenEntityRecord($event)); });
|
|
325
|
+
i0.ɵɵelementEnd()();
|
|
326
|
+
} }
|
|
327
|
+
function ComponentStudioDashboardComponent_Conditional_3_For_22_Template(rf, ctx) { if (rf & 1) {
|
|
328
|
+
const _r16 = i0.ɵɵgetCurrentView();
|
|
329
|
+
i0.ɵɵelementStart(0, "div", 81);
|
|
330
|
+
i0.ɵɵlistener("click", function ComponentStudioDashboardComponent_Conditional_3_For_22_Template_div_click_0_listener() { const $index_r17 = i0.ɵɵrestoreView(_r16).$index; const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.onTabChange(ctx_r1.navigationItems[$index_r17])); });
|
|
331
|
+
i0.ɵɵelement(1, "i");
|
|
332
|
+
i0.ɵɵelementStart(2, "span");
|
|
333
|
+
i0.ɵɵtext(3);
|
|
334
|
+
i0.ɵɵelementEnd()();
|
|
335
|
+
} if (rf & 2) {
|
|
336
|
+
const navItem_r18 = ctx.$implicit;
|
|
337
|
+
i0.ɵɵclassProp("active", navItem_r18.selected);
|
|
338
|
+
i0.ɵɵadvance();
|
|
339
|
+
i0.ɵɵclassMap(navItem_r18.icon);
|
|
340
|
+
i0.ɵɵadvance(2);
|
|
341
|
+
i0.ɵɵtextInterpolate(navItem_r18.text);
|
|
342
|
+
} }
|
|
343
|
+
function ComponentStudioDashboardComponent_Conditional_3_Template(rf, ctx) { if (rf & 1) {
|
|
344
|
+
const _r1 = i0.ɵɵgetCurrentView();
|
|
345
|
+
i0.ɵɵelementStart(0, "div", 3)(1, "div", 8)(2, "div", 9)(3, "h1", 10);
|
|
346
|
+
i0.ɵɵelement(4, "i", 11);
|
|
347
|
+
i0.ɵɵtext(5, " Component Studio ");
|
|
348
|
+
i0.ɵɵelementEnd();
|
|
349
|
+
i0.ɵɵelementStart(6, "div", 12);
|
|
350
|
+
i0.ɵɵtext(7, " Discover, preview, and test reusable components ");
|
|
351
|
+
i0.ɵɵelementEnd()();
|
|
352
|
+
i0.ɵɵelementStart(8, "div", 13)(9, "div", 14)(10, "button", 15);
|
|
353
|
+
i0.ɵɵlistener("click", function ComponentStudioDashboardComponent_Conditional_3_Template_button_click_10_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.toggleViewMode()); });
|
|
354
|
+
i0.ɵɵelementEnd();
|
|
355
|
+
i0.ɵɵelementStart(11, "button", 16);
|
|
356
|
+
i0.ɵɵlistener("click", function ComponentStudioDashboardComponent_Conditional_3_Template_button_click_11_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.toggleFilterPanel()); });
|
|
357
|
+
i0.ɵɵelementEnd();
|
|
358
|
+
i0.ɵɵelementStart(12, "button", 17);
|
|
359
|
+
i0.ɵɵlistener("click", function ComponentStudioDashboardComponent_Conditional_3_Template_button_click_12_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.refreshData()); });
|
|
360
|
+
i0.ɵɵelementEnd()()()();
|
|
361
|
+
i0.ɵɵelementStart(13, "div", 18);
|
|
362
|
+
i0.ɵɵtemplate(14, ComponentStudioDashboardComponent_Conditional_3_Conditional_14_Template, 35, 6, "div", 19);
|
|
363
|
+
i0.ɵɵelementStart(15, "div", 20);
|
|
364
|
+
i0.ɵɵtemplate(16, ComponentStudioDashboardComponent_Conditional_3_Conditional_16_Template, 6, 2, "div", 21)(17, ComponentStudioDashboardComponent_Conditional_3_Conditional_17_Template, 3, 1, "div", 22)(18, ComponentStudioDashboardComponent_Conditional_3_Conditional_18_Template, 3, 1, "div", 23)(19, ComponentStudioDashboardComponent_Conditional_3_Conditional_19_Template, 2, 0, "div", 24);
|
|
365
|
+
i0.ɵɵelementEnd()();
|
|
366
|
+
i0.ɵɵelementStart(20, "div", 25);
|
|
367
|
+
i0.ɵɵrepeaterCreate(21, ComponentStudioDashboardComponent_Conditional_3_For_22_Template, 4, 5, "div", 26, i0.ɵɵrepeaterTrackByIndex);
|
|
368
|
+
i0.ɵɵelementEnd()();
|
|
369
|
+
} if (rf & 2) {
|
|
370
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
371
|
+
i0.ɵɵadvance(10);
|
|
372
|
+
i0.ɵɵproperty("icon", ctx_r1.viewMode === "grid" ? "fa-solid fa-list" : "fa-solid fa-th")("fillMode", "flat");
|
|
373
|
+
i0.ɵɵadvance();
|
|
374
|
+
i0.ɵɵproperty("icon", ctx_r1.showFilterPanel ? "fa-solid fa-filter-circle-xmark" : "fa-solid fa-filter")("fillMode", "flat");
|
|
375
|
+
i0.ɵɵadvance();
|
|
376
|
+
i0.ɵɵproperty("icon", "fa-solid fa-sync")("fillMode", "flat");
|
|
377
|
+
i0.ɵɵadvance(2);
|
|
378
|
+
i0.ɵɵconditional(ctx_r1.showFilterPanel && ctx_r1.activeTab === "browse" ? 14 : -1);
|
|
379
|
+
i0.ɵɵadvance(2);
|
|
380
|
+
i0.ɵɵconditional(ctx_r1.activeTab === "browse" ? 16 : -1);
|
|
381
|
+
i0.ɵɵadvance();
|
|
382
|
+
i0.ɵɵconditional(ctx_r1.activeTab === "preview" ? 17 : -1);
|
|
383
|
+
i0.ɵɵadvance();
|
|
384
|
+
i0.ɵɵconditional(ctx_r1.activeTab === "dependencies" ? 18 : -1);
|
|
385
|
+
i0.ɵɵadvance();
|
|
386
|
+
i0.ɵɵconditional(ctx_r1.activeTab === "settings" ? 19 : -1);
|
|
387
|
+
i0.ɵɵadvance(2);
|
|
388
|
+
i0.ɵɵrepeater(ctx_r1.navigationConfig);
|
|
389
|
+
} }
|
|
390
|
+
let ComponentStudioDashboardComponent = class ComponentStudioDashboardComponent extends BaseDashboard {
|
|
391
|
+
cdr;
|
|
392
|
+
// State management
|
|
393
|
+
isLoading = false;
|
|
394
|
+
activeTab = 'browse'; // Default tab
|
|
395
|
+
viewMode = 'grid';
|
|
396
|
+
selectedComponentId = null;
|
|
397
|
+
showFilterPanel = true;
|
|
398
|
+
showPreviewPanel = false;
|
|
399
|
+
// Data
|
|
400
|
+
components$ = new BehaviorSubject([]);
|
|
401
|
+
filteredComponents$ = new BehaviorSubject([]);
|
|
402
|
+
registries$ = new BehaviorSubject([]);
|
|
403
|
+
libraries$ = new BehaviorSubject([]);
|
|
404
|
+
// Filters
|
|
405
|
+
searchQuery$ = new BehaviorSubject('');
|
|
406
|
+
selectedTypes$ = new BehaviorSubject(new Set());
|
|
407
|
+
selectedStatuses$ = new BehaviorSubject(new Set(['Published'])); // Default to published
|
|
408
|
+
selectedSources$ = new BehaviorSubject(new Set());
|
|
409
|
+
selectedNamespaces$ = new BehaviorSubject(new Set());
|
|
410
|
+
// Component types for filtering
|
|
411
|
+
componentTypes = ['Report', 'Dashboard', 'Form', 'Table', 'Chart', 'Navigation', 'Search', 'Widget', 'Utility', 'Other'];
|
|
412
|
+
componentStatuses = ['Draft', 'Published', 'Deprecated'];
|
|
413
|
+
// Preview
|
|
414
|
+
selectedComponent = null;
|
|
415
|
+
componentSpec = null;
|
|
416
|
+
previewError = null;
|
|
417
|
+
// Navigation items for bottom navigation
|
|
418
|
+
navigationItems = ['browse', 'preview', 'dependencies', 'settings'];
|
|
419
|
+
navigationConfig = [
|
|
420
|
+
{ text: 'Browse', icon: 'fa-solid fa-th', selected: true },
|
|
421
|
+
{ text: 'Preview', icon: 'fa-solid fa-eye', selected: false },
|
|
422
|
+
{ text: 'Dependencies', icon: 'fa-solid fa-sitemap', selected: false },
|
|
423
|
+
{ text: 'Settings', icon: 'fa-solid fa-cog', selected: false }
|
|
424
|
+
];
|
|
425
|
+
destroy$ = new Subject();
|
|
426
|
+
stateChangeSubject = new Subject();
|
|
427
|
+
constructor(cdr) {
|
|
428
|
+
super();
|
|
429
|
+
this.cdr = cdr;
|
|
430
|
+
}
|
|
431
|
+
ngAfterViewInit() {
|
|
432
|
+
this.initDashboard();
|
|
433
|
+
this.loadData();
|
|
434
|
+
this.emitStateChange();
|
|
435
|
+
this.updateNavigationSelection();
|
|
436
|
+
// Force change detection
|
|
437
|
+
this.cdr.detectChanges();
|
|
438
|
+
}
|
|
439
|
+
initDashboard() {
|
|
440
|
+
// Initialize dashboard - called once when dashboard is created
|
|
441
|
+
this.setupStateManagement();
|
|
442
|
+
this.setupFilterSubscriptions();
|
|
443
|
+
}
|
|
444
|
+
ngOnDestroy() {
|
|
445
|
+
this.destroy$.next();
|
|
446
|
+
this.destroy$.complete();
|
|
447
|
+
this.stateChangeSubject.complete();
|
|
448
|
+
}
|
|
449
|
+
async loadData() {
|
|
450
|
+
this.isLoading = true;
|
|
451
|
+
this.cdr.markForCheck();
|
|
452
|
+
try {
|
|
453
|
+
const rv = new RunView();
|
|
454
|
+
// Load all data in parallel using RunViews
|
|
455
|
+
const [componentsResult, registriesResult, librariesResult] = await rv.RunViews([
|
|
456
|
+
{
|
|
457
|
+
EntityName: 'Components',
|
|
458
|
+
ExtraFilter: '',
|
|
459
|
+
OrderBy: 'Name',
|
|
460
|
+
MaxRows: 1000,
|
|
461
|
+
ResultType: 'entity_object'
|
|
462
|
+
},
|
|
463
|
+
{
|
|
464
|
+
EntityName: 'Component Registries',
|
|
465
|
+
ExtraFilter: '',
|
|
466
|
+
OrderBy: 'Name',
|
|
467
|
+
MaxRows: 100,
|
|
468
|
+
ResultType: 'entity_object'
|
|
469
|
+
},
|
|
470
|
+
{
|
|
471
|
+
EntityName: 'Component Libraries',
|
|
472
|
+
ExtraFilter: '',
|
|
473
|
+
OrderBy: 'Name',
|
|
474
|
+
MaxRows: 500,
|
|
475
|
+
ResultType: 'entity_object'
|
|
476
|
+
}
|
|
477
|
+
]);
|
|
478
|
+
if (componentsResult.Success) {
|
|
479
|
+
const components = componentsResult.Results;
|
|
480
|
+
// Load dependencies for each component if needed
|
|
481
|
+
// For now, just set the basic data
|
|
482
|
+
this.components$.next(components);
|
|
483
|
+
this.applyFilters();
|
|
484
|
+
}
|
|
485
|
+
if (registriesResult.Success) {
|
|
486
|
+
this.registries$.next(registriesResult.Results);
|
|
487
|
+
}
|
|
488
|
+
if (librariesResult.Success) {
|
|
489
|
+
this.libraries$.next(librariesResult.Results);
|
|
490
|
+
}
|
|
491
|
+
}
|
|
492
|
+
catch (error) {
|
|
493
|
+
console.error('Failed to load component data:', error);
|
|
494
|
+
}
|
|
495
|
+
finally {
|
|
496
|
+
this.isLoading = false;
|
|
497
|
+
this.cdr.markForCheck();
|
|
498
|
+
}
|
|
499
|
+
}
|
|
500
|
+
setupFilterSubscriptions() {
|
|
501
|
+
// Combine all filter observables and apply filters when any change
|
|
502
|
+
combineLatest([
|
|
503
|
+
this.searchQuery$.pipe(debounceTime(300), distinctUntilChanged()),
|
|
504
|
+
this.selectedTypes$,
|
|
505
|
+
this.selectedStatuses$,
|
|
506
|
+
this.selectedSources$,
|
|
507
|
+
this.selectedNamespaces$,
|
|
508
|
+
this.components$
|
|
509
|
+
])
|
|
510
|
+
.pipe(takeUntil(this.destroy$))
|
|
511
|
+
.subscribe(([search, types, statuses, sources, namespaces, components]) => {
|
|
512
|
+
this.applyFiltersWithCriteria(search, types, statuses, sources, namespaces, components);
|
|
513
|
+
});
|
|
514
|
+
}
|
|
515
|
+
applyFilters() {
|
|
516
|
+
const search = this.searchQuery$.value;
|
|
517
|
+
const types = this.selectedTypes$.value;
|
|
518
|
+
const statuses = this.selectedStatuses$.value;
|
|
519
|
+
const sources = this.selectedSources$.value;
|
|
520
|
+
const namespaces = this.selectedNamespaces$.value;
|
|
521
|
+
const components = this.components$.value;
|
|
522
|
+
this.applyFiltersWithCriteria(search, types, statuses, sources, namespaces, components);
|
|
523
|
+
}
|
|
524
|
+
applyFiltersWithCriteria(search, types, statuses, sources, namespaces, components) {
|
|
525
|
+
let filtered = [...components];
|
|
526
|
+
// Search filter
|
|
527
|
+
if (search) {
|
|
528
|
+
const query = search.toLowerCase();
|
|
529
|
+
filtered = filtered.filter(c => c.Name?.toLowerCase().includes(query) ||
|
|
530
|
+
c.Description?.toLowerCase().includes(query) ||
|
|
531
|
+
c.Namespace?.toLowerCase().includes(query) ||
|
|
532
|
+
c.DeveloperName?.toLowerCase().includes(query) ||
|
|
533
|
+
c.DeveloperOrganization?.toLowerCase().includes(query));
|
|
534
|
+
}
|
|
535
|
+
// Type filter
|
|
536
|
+
if (types.size > 0) {
|
|
537
|
+
filtered = filtered.filter(c => c.Type && types.has(c.Type));
|
|
538
|
+
}
|
|
539
|
+
// Status filter
|
|
540
|
+
if (statuses.size > 0) {
|
|
541
|
+
filtered = filtered.filter(c => c.Status && statuses.has(c.Status));
|
|
542
|
+
}
|
|
543
|
+
// Source filter (Local vs Registry)
|
|
544
|
+
if (sources.size > 0) {
|
|
545
|
+
filtered = filtered.filter(c => {
|
|
546
|
+
const isLocal = !c.SourceRegistryID;
|
|
547
|
+
return (sources.has('Local') && isLocal) || (sources.has('Registry') && !isLocal);
|
|
548
|
+
});
|
|
549
|
+
}
|
|
550
|
+
// Namespace filter
|
|
551
|
+
if (namespaces.size > 0) {
|
|
552
|
+
filtered = filtered.filter(c => {
|
|
553
|
+
if (!c.Namespace)
|
|
554
|
+
return false;
|
|
555
|
+
// Check if namespace starts with any selected namespace
|
|
556
|
+
return Array.from(namespaces).some(ns => c.Namespace?.startsWith(ns));
|
|
557
|
+
});
|
|
558
|
+
}
|
|
559
|
+
this.filteredComponents$.next(filtered);
|
|
560
|
+
this.cdr.markForCheck();
|
|
561
|
+
}
|
|
562
|
+
onTabChange(tabId) {
|
|
563
|
+
this.activeTab = tabId;
|
|
564
|
+
this.updateNavigationSelection();
|
|
565
|
+
// Trigger resize for rendering issues
|
|
566
|
+
setTimeout(() => {
|
|
567
|
+
SharedService.Instance.InvokeManualResize();
|
|
568
|
+
}, 100);
|
|
569
|
+
this.emitStateChange();
|
|
570
|
+
this.cdr.markForCheck();
|
|
571
|
+
}
|
|
572
|
+
onNavigationChange(event) {
|
|
573
|
+
const index = event.index;
|
|
574
|
+
if (index >= 0 && index < this.navigationItems.length) {
|
|
575
|
+
this.activeTab = this.navigationItems[index];
|
|
576
|
+
this.updateNavigationSelection();
|
|
577
|
+
this.emitStateChange();
|
|
578
|
+
setTimeout(() => {
|
|
579
|
+
SharedService.Instance.InvokeManualResize();
|
|
580
|
+
}, 100);
|
|
581
|
+
this.cdr.markForCheck();
|
|
582
|
+
}
|
|
583
|
+
}
|
|
584
|
+
updateNavigationSelection() {
|
|
585
|
+
this.navigationConfig.forEach((item, index) => {
|
|
586
|
+
item.selected = this.navigationItems[index] === this.activeTab;
|
|
587
|
+
});
|
|
588
|
+
}
|
|
589
|
+
toggleViewMode() {
|
|
590
|
+
this.viewMode = this.viewMode === 'grid' ? 'list' : 'grid';
|
|
591
|
+
this.emitStateChange();
|
|
592
|
+
this.cdr.markForCheck();
|
|
593
|
+
}
|
|
594
|
+
toggleFilterPanel() {
|
|
595
|
+
this.showFilterPanel = !this.showFilterPanel;
|
|
596
|
+
this.cdr.markForCheck();
|
|
597
|
+
}
|
|
598
|
+
async selectComponent(component) {
|
|
599
|
+
if (!component)
|
|
600
|
+
return;
|
|
601
|
+
this.selectedComponent = component;
|
|
602
|
+
this.selectedComponentId = component.ID;
|
|
603
|
+
// Load component details if in preview mode
|
|
604
|
+
if (this.activeTab === 'preview') {
|
|
605
|
+
await this.loadComponentDetails(component);
|
|
606
|
+
}
|
|
607
|
+
this.emitStateChange();
|
|
608
|
+
this.cdr.markForCheck();
|
|
609
|
+
}
|
|
610
|
+
async loadComponentDetails(component) {
|
|
611
|
+
try {
|
|
612
|
+
// TODO: Load component spec from storage
|
|
613
|
+
// For now, we'll need to implement storage of ComponentSpec
|
|
614
|
+
this.componentSpec = null;
|
|
615
|
+
this.previewError = null;
|
|
616
|
+
}
|
|
617
|
+
catch (error) {
|
|
618
|
+
this.previewError = 'Failed to load component details';
|
|
619
|
+
console.error('Error loading component details:', error);
|
|
620
|
+
}
|
|
621
|
+
}
|
|
622
|
+
onSearchChange(query) {
|
|
623
|
+
this.searchQuery$.next(query);
|
|
624
|
+
}
|
|
625
|
+
onTypeFilterChange(type, checked) {
|
|
626
|
+
const types = new Set(this.selectedTypes$.value);
|
|
627
|
+
if (checked) {
|
|
628
|
+
types.add(type);
|
|
629
|
+
}
|
|
630
|
+
else {
|
|
631
|
+
types.delete(type);
|
|
632
|
+
}
|
|
633
|
+
this.selectedTypes$.next(types);
|
|
634
|
+
}
|
|
635
|
+
onStatusFilterChange(status, checked) {
|
|
636
|
+
const statuses = new Set(this.selectedStatuses$.value);
|
|
637
|
+
if (checked) {
|
|
638
|
+
statuses.add(status);
|
|
639
|
+
}
|
|
640
|
+
else {
|
|
641
|
+
statuses.delete(status);
|
|
642
|
+
}
|
|
643
|
+
this.selectedStatuses$.next(statuses);
|
|
644
|
+
}
|
|
645
|
+
onSourceFilterChange(source, checked) {
|
|
646
|
+
const sources = new Set(this.selectedSources$.value);
|
|
647
|
+
if (checked) {
|
|
648
|
+
sources.add(source);
|
|
649
|
+
}
|
|
650
|
+
else {
|
|
651
|
+
sources.delete(source);
|
|
652
|
+
}
|
|
653
|
+
this.selectedSources$.next(sources);
|
|
654
|
+
}
|
|
655
|
+
clearFilters() {
|
|
656
|
+
this.searchQuery$.next('');
|
|
657
|
+
this.selectedTypes$.next(new Set());
|
|
658
|
+
this.selectedStatuses$.next(new Set(['Published']));
|
|
659
|
+
this.selectedSources$.next(new Set());
|
|
660
|
+
this.selectedNamespaces$.next(new Set());
|
|
661
|
+
}
|
|
662
|
+
onOpenEntityRecord(event) {
|
|
663
|
+
this.OpenEntityRecord.emit({
|
|
664
|
+
EntityName: event.entityName,
|
|
665
|
+
RecordPKey: event.key
|
|
666
|
+
});
|
|
667
|
+
}
|
|
668
|
+
async refreshData() {
|
|
669
|
+
await this.loadData();
|
|
670
|
+
}
|
|
671
|
+
setupStateManagement() {
|
|
672
|
+
this.stateChangeSubject.pipe(debounceTime(50), takeUntil(this.destroy$)).subscribe(state => {
|
|
673
|
+
this.UserStateChanged.emit(state);
|
|
674
|
+
});
|
|
675
|
+
}
|
|
676
|
+
emitStateChange() {
|
|
677
|
+
const state = {
|
|
678
|
+
activeTab: this.activeTab,
|
|
679
|
+
selectedComponentId: this.selectedComponentId,
|
|
680
|
+
filterState: {
|
|
681
|
+
types: Array.from(this.selectedTypes$.value),
|
|
682
|
+
statuses: Array.from(this.selectedStatuses$.value),
|
|
683
|
+
sources: Array.from(this.selectedSources$.value),
|
|
684
|
+
namespaces: Array.from(this.selectedNamespaces$.value)
|
|
685
|
+
},
|
|
686
|
+
searchQuery: this.searchQuery$.value,
|
|
687
|
+
viewMode: this.viewMode,
|
|
688
|
+
previewState: {
|
|
689
|
+
componentId: this.selectedComponentId,
|
|
690
|
+
isLoading: false,
|
|
691
|
+
error: this.previewError,
|
|
692
|
+
testData: null
|
|
693
|
+
}
|
|
694
|
+
};
|
|
695
|
+
this.stateChangeSubject.next(state);
|
|
696
|
+
}
|
|
697
|
+
// Helper methods for template
|
|
698
|
+
getComponentTypeColor(type) {
|
|
699
|
+
const colors = {
|
|
700
|
+
'Report': '#3B82F6', // Blue
|
|
701
|
+
'Dashboard': '#8B5CF6', // Purple
|
|
702
|
+
'Form': '#10B981', // Green
|
|
703
|
+
'Chart': '#F97316', // Orange
|
|
704
|
+
'Table': '#06B6D4', // Cyan
|
|
705
|
+
'Widget': '#EC4899', // Pink
|
|
706
|
+
'Navigation': '#6366F1', // Indigo
|
|
707
|
+
'Search': '#14B8A6', // Teal
|
|
708
|
+
'Utility': '#64748B', // Slate
|
|
709
|
+
'Other': '#9CA3AF' // Gray
|
|
710
|
+
};
|
|
711
|
+
return colors[type] || colors['Other'];
|
|
712
|
+
}
|
|
713
|
+
getStatusBadgeClass(status) {
|
|
714
|
+
const classes = {
|
|
715
|
+
'Draft': 'badge-draft',
|
|
716
|
+
'Published': 'badge-published',
|
|
717
|
+
'Deprecated': 'badge-deprecated'
|
|
718
|
+
};
|
|
719
|
+
return classes[status] || 'badge-default';
|
|
720
|
+
}
|
|
721
|
+
static ɵfac = function ComponentStudioDashboardComponent_Factory(t) { return new (t || ComponentStudioDashboardComponent)(i0.ɵɵdirectiveInject(i0.ChangeDetectorRef)); };
|
|
722
|
+
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ComponentStudioDashboardComponent, selectors: [["mj-component-studio-dashboard"]], features: [i0.ɵɵInheritDefinitionFeature], decls: 4, vars: 2, consts: [[1, "component-studio-dashboard"], ["kendoDialogContainer", ""], [1, "loading-container"], [1, "dashboard-wrapper"], [1, "loading-content"], [1, "loading-spinner"], [1, "fa-solid", "fa-spinner", "fa-spin", "fa-3x"], [1, "loading-text"], [1, "dashboard-header"], [1, "header-left"], [1, "dashboard-title"], [1, "fa-solid", "fa-puzzle-piece"], [1, "dashboard-subtitle"], [1, "header-right"], [1, "header-actions"], ["kendoButton", "", "title", "Toggle view mode", 3, "click", "icon", "fillMode"], ["kendoButton", "", "title", "Toggle filters", 3, "click", "icon", "fillMode"], ["kendoButton", "", "title", "Refresh", 3, "click", "icon", "fillMode"], [1, "dashboard-content"], [1, "filter-panel"], [1, "content-area"], [1, "browse-content"], [1, "preview-content"], [1, "dependencies-content"], [1, "settings-content"], [1, "dashboard-navigation"], [1, "nav-item", 3, "active"], [1, "filter-header"], ["kendoButton", "", 3, "click", "fillMode", "size"], [1, "filter-section"], [1, "filter-label"], ["placeholder", "Search components...", 3, "valueChange", "value", "clearButton"], ["kendoTextBoxPrefixTemplate", ""], [1, "filter-options"], [1, "checkbox-label"], ["type", "checkbox", 3, "change", "checked"], [1, "fa-solid", "fa-house"], [1, "fa-solid", "fa-cloud"], [1, "fa-solid", "fa-search"], [1, "type-indicator"], [1, "status-badge", 3, "ngClass"], [1, "results-summary"], [1, "result-count"], [1, "component-grid"], [3, "data", "pageSize", "pageable", "sortable", "filterable", "resizable", "selectable"], [1, "component-card", 3, "selected"], [1, "component-card", 3, "click"], [1, "card-header"], [1, "card-type"], [1, "card-status", 3, "ngClass"], [1, "card-body"], [1, "card-title"], [1, "card-version"], [1, "card-description"], [1, "card-namespace"], [1, "fa-solid", "fa-folder-tree"], [1, "card-footer"], [1, "card-developer"], [1, "fa-solid", "fa-user"], [1, "card-source"], ["title", "Local", 1, "fa-solid", "fa-house"], ["title", "Registry", 1, "fa-solid", "fa-cloud"], [3, "selectionChange", "data", "pageSize", "pageable", "sortable", "filterable", "resizable", "selectable"], ["field", "Name", "title", "Component", 3, "width"], ["kendoGridCellTemplate", ""], ["field", "Version", "title", "Version", 3, "width"], ["field", "Type", "title", "Type", 3, "width"], ["field", "Status", "title", "Status", 3, "width"], ["field", "Namespace", "title", "Namespace", 3, "width"], ["field", "DeveloperOrganization", "title", "Developer", 3, "width"], ["field", "Description", "title", "Description"], [1, "component-name"], [1, "type-dot"], [3, "component", "componentSpec"], [1, "empty-state"], [3, "openEntityRecord", "component", "componentSpec"], [1, "fa-solid", "fa-eye", "fa-4x"], [3, "component"], [3, "openEntityRecord", "component"], [1, "fa-solid", "fa-sitemap", "fa-4x"], [3, "openEntityRecord"], [1, "nav-item", 3, "click"]], template: function ComponentStudioDashboardComponent_Template(rf, ctx) { if (rf & 1) {
|
|
723
|
+
i0.ɵɵelementStart(0, "div", 0);
|
|
724
|
+
i0.ɵɵelement(1, "div", 1);
|
|
725
|
+
i0.ɵɵtemplate(2, ComponentStudioDashboardComponent_Conditional_2_Template, 6, 0, "div", 2)(3, ComponentStudioDashboardComponent_Conditional_3_Template, 23, 11, "div", 3);
|
|
726
|
+
i0.ɵɵelementEnd();
|
|
727
|
+
} if (rf & 2) {
|
|
728
|
+
i0.ɵɵadvance(2);
|
|
729
|
+
i0.ɵɵconditional(ctx.isLoading ? 2 : -1);
|
|
730
|
+
i0.ɵɵadvance();
|
|
731
|
+
i0.ɵɵconditional(!ctx.isLoading ? 3 : -1);
|
|
732
|
+
} }, dependencies: [i1.NgClass, i2.TextBoxComponent, i2.TextBoxPrefixTemplateDirective, i3.DialogContainerDirective, i4.ButtonComponent, i5.GridComponent, i5.ColumnComponent, i5.CellTemplateDirective, i6.ComponentPreviewComponent, i7.ComponentDependenciesComponent, i8.ComponentStudioSettingsComponent], styles: ["[_nghost-%COMP%] {\n display: block;\n width: 100%;\n height: 100%;\n position: relative;\n}\n\n.component-studio-dashboard[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n height: 100%;\n background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);\n position: relative;\n overflow: hidden;\n\n &::before {\n content: '';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(255, 255, 255, 0.03);\n backdrop-filter: blur(10px);\n z-index: 0;\n }\n\n .loading-container {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n position: relative;\n z-index: 1;\n \n .loading-content {\n text-align: center;\n color: white;\n \n .loading-spinner {\n margin-bottom: 20px;\n animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;\n }\n \n .loading-text {\n font-size: 18px;\n font-weight: 500;\n opacity: 0.9;\n }\n }\n }\n\n .dashboard-wrapper {\n display: flex;\n flex-direction: column;\n height: 100%;\n position: relative;\n z-index: 1;\n }\n\n // Header\n .dashboard-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 20px 30px;\n background: rgba(255, 255, 255, 0.1);\n backdrop-filter: blur(20px);\n border-bottom: 1px solid rgba(255, 255, 255, 0.2);\n position: relative;\n z-index: 2;\n \n .header-left {\n .dashboard-title {\n display: flex;\n align-items: center;\n gap: 12px;\n font-size: 28px;\n font-weight: 700;\n color: white;\n margin: 0;\n \n i {\n font-size: 32px;\n }\n }\n \n .dashboard-subtitle {\n color: rgba(255, 255, 255, 0.8);\n font-size: 14px;\n margin-top: 4px;\n margin-left: 44px;\n }\n }\n \n .header-right {\n .header-actions {\n display: flex;\n gap: 8px;\n \n button {\n background: rgba(255, 255, 255, 0.2);\n border: 1px solid rgba(255, 255, 255, 0.3);\n color: white;\n \n &:hover {\n background: rgba(255, 255, 255, 0.3);\n }\n }\n }\n }\n }\n\n // Main Content\n .dashboard-content {\n flex: 1;\n display: flex;\n overflow: hidden;\n background: rgba(255, 255, 255, 0.95);\n margin: 20px;\n border-radius: 12px;\n box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);\n position: relative;\n z-index: 1;\n }\n\n // Filter Panel\n .filter-panel {\n width: 280px;\n background: white;\n border-right: 1px solid #e5e7eb;\n padding: 20px;\n overflow-y: auto;\n \n .filter-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n margin-bottom: 20px;\n \n h3 {\n font-size: 16px;\n font-weight: 600;\n color: #1f2937;\n margin: 0;\n }\n \n button {\n padding: 4px 8px;\n font-size: 12px;\n }\n }\n \n .filter-section {\n margin-bottom: 24px;\n \n .filter-label {\n display: block;\n font-size: 13px;\n font-weight: 600;\n color: #6b7280;\n text-transform: uppercase;\n letter-spacing: 0.05em;\n margin-bottom: 8px;\n }\n \n kendo-textbox {\n width: 100%;\n }\n \n .filter-options {\n display: flex;\n flex-direction: column;\n gap: 8px;\n \n .checkbox-label {\n display: flex;\n align-items: center;\n gap: 8px;\n cursor: pointer;\n font-size: 14px;\n color: #374151;\n \n &:hover {\n color: #111827;\n }\n \n input[type=\"checkbox\"] {\n cursor: pointer;\n }\n \n .type-indicator {\n width: 12px;\n height: 12px;\n border-radius: 3px;\n flex-shrink: 0;\n }\n \n .status-badge {\n padding: 2px 8px;\n border-radius: 12px;\n font-size: 11px;\n font-weight: 600;\n \n &.badge-draft {\n background: #fef3c7;\n color: #92400e;\n }\n \n &.badge-published {\n background: #d1fae5;\n color: #065f46;\n }\n \n &.badge-deprecated {\n background: #fee2e2;\n color: #991b1b;\n }\n }\n }\n }\n }\n }\n\n // Content Area\n .content-area {\n flex: 1;\n display: flex;\n flex-direction: column;\n overflow: hidden;\n \n .browse-content {\n display: flex;\n flex-direction: column;\n height: 100%;\n padding: 20px;\n \n .results-summary {\n display: flex;\n justify-content: space-between;\n align-items: center;\n margin-bottom: 20px;\n \n .result-count {\n font-size: 14px;\n color: #6b7280;\n }\n }\n \n // Component Grid\n .component-grid {\n display: grid;\n grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));\n gap: 20px;\n overflow-y: auto;\n padding: 4px;\n \n .component-card {\n background: white;\n border: 2px solid #e5e7eb;\n border-radius: 12px;\n padding: 16px;\n cursor: pointer;\n transition: all 0.2s ease;\n position: relative;\n overflow: hidden;\n height: fit-content;\n \n &:hover {\n border-color: #9ca3af;\n transform: translateY(-2px);\n box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);\n }\n \n &.selected {\n border-color: #6366f1;\n background: linear-gradient(135deg, rgba(99, 102, 241, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);\n }\n \n .card-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n margin-bottom: 12px;\n \n .card-type {\n padding: 4px 10px;\n border-radius: 6px;\n color: white;\n font-size: 11px;\n font-weight: 600;\n text-transform: uppercase;\n letter-spacing: 0.05em;\n }\n \n .card-status {\n padding: 3px 8px;\n border-radius: 12px;\n font-size: 11px;\n font-weight: 600;\n \n &.badge-draft {\n background: #fef3c7;\n color: #92400e;\n }\n \n &.badge-published {\n background: #d1fae5;\n color: #065f46;\n }\n \n &.badge-deprecated {\n background: #fee2e2;\n color: #991b1b;\n }\n }\n }\n \n .card-body {\n margin-bottom: 12px;\n \n .card-title {\n font-size: 16px;\n font-weight: 600;\n color: #111827;\n margin: 0 0 4px 0;\n }\n \n .card-version {\n font-size: 12px;\n color: #6b7280;\n margin-bottom: 8px;\n }\n \n .card-description {\n font-size: 13px;\n color: #6b7280;\n line-height: 1.5;\n margin: 8px 0;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n }\n \n .card-namespace {\n font-size: 12px;\n color: #9ca3af;\n display: flex;\n align-items: center;\n gap: 6px;\n \n i {\n font-size: 11px;\n }\n }\n }\n \n .card-footer {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding-top: 12px;\n border-top: 1px solid #f3f4f6;\n \n .card-developer {\n font-size: 12px;\n color: #6b7280;\n display: flex;\n align-items: center;\n gap: 6px;\n \n i {\n font-size: 11px;\n }\n }\n \n .card-source {\n font-size: 14px;\n color: #9ca3af;\n }\n }\n }\n }\n \n // List View (Kendo Grid styling)\n kendo-grid {\n height: 100%;\n \n .component-name {\n display: flex;\n align-items: center;\n gap: 8px;\n \n .type-dot {\n width: 8px;\n height: 8px;\n border-radius: 50%;\n }\n }\n \n .status-badge {\n padding: 2px 8px;\n border-radius: 12px;\n font-size: 11px;\n font-weight: 600;\n display: inline-block;\n \n &.badge-draft {\n background: #fef3c7;\n color: #92400e;\n }\n \n &.badge-published {\n background: #d1fae5;\n color: #065f46;\n }\n \n &.badge-deprecated {\n background: #fee2e2;\n color: #991b1b;\n }\n }\n }\n }\n \n .preview-content,\n .dependencies-content,\n .settings-content {\n height: 100%;\n padding: 20px;\n overflow-y: auto;\n }\n \n .empty-state {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n height: 100%;\n color: #9ca3af;\n \n i {\n margin-bottom: 20px;\n opacity: 0.5;\n }\n \n h3 {\n font-size: 20px;\n font-weight: 600;\n color: #6b7280;\n margin: 0 0 8px 0;\n }\n \n p {\n font-size: 14px;\n color: #9ca3af;\n margin: 0;\n }\n }\n }\n\n // Bottom Navigation\n .dashboard-navigation {\n display: flex;\n justify-content: center;\n gap: 4px;\n padding: 12px 20px;\n background: rgba(255, 255, 255, 0.1);\n backdrop-filter: blur(20px);\n border-top: 1px solid rgba(255, 255, 255, 0.2);\n position: relative;\n z-index: 2;\n \n .nav-item {\n display: flex;\n flex-direction: column;\n align-items: center;\n gap: 4px;\n padding: 8px 24px;\n border-radius: 8px;\n cursor: pointer;\n transition: all 0.2s ease;\n color: rgba(255, 255, 255, 0.7);\n \n i {\n font-size: 20px;\n }\n \n span {\n font-size: 12px;\n font-weight: 500;\n }\n \n &:hover {\n background: rgba(255, 255, 255, 0.15);\n color: white;\n }\n \n &.active {\n background: rgba(255, 255, 255, 0.25);\n color: white;\n }\n }\n }\n}\n\n//[_ngcontent-%COMP%] Animations\n@keyframes[_ngcontent-%COMP%] pulse[_ngcontent-%COMP%] {\n 0%, 100% {\n opacity: 1;\n }\n 50% {\n opacity: 0.5;\n }\n}"], changeDetection: 0 });
|
|
733
|
+
};
|
|
734
|
+
ComponentStudioDashboardComponent = __decorate([
|
|
735
|
+
RegisterClass(BaseDashboard, 'ComponentStudioDashboard')
|
|
736
|
+
], ComponentStudioDashboardComponent);
|
|
737
|
+
export { ComponentStudioDashboardComponent };
|
|
738
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ComponentStudioDashboardComponent, [{
|
|
739
|
+
type: Component,
|
|
740
|
+
args: [{ selector: 'mj-component-studio-dashboard', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"component-studio-dashboard\">\n <!-- Dialog container for Kendo dialogs -->\n <div kendoDialogContainer></div>\n \n @if (isLoading) {\n <div class=\"loading-container\">\n <div class=\"loading-content\">\n <div class=\"loading-spinner\">\n <i class=\"fa-solid fa-spinner fa-spin fa-3x\"></i>\n </div>\n <div class=\"loading-text\">Loading Component Studio...</div>\n </div>\n </div>\n }\n \n @if (!isLoading) {\n <div class=\"dashboard-wrapper\">\n <!-- Header -->\n <div class=\"dashboard-header\">\n <div class=\"header-left\">\n <h1 class=\"dashboard-title\">\n <i class=\"fa-solid fa-puzzle-piece\"></i>\n Component Studio\n </h1>\n <div class=\"dashboard-subtitle\">\n Discover, preview, and test reusable components\n </div>\n </div>\n <div class=\"header-right\">\n <div class=\"header-actions\">\n <button kendoButton \n [icon]=\"viewMode === 'grid' ? 'fa-solid fa-list' : 'fa-solid fa-th'\"\n [fillMode]=\"'flat'\"\n (click)=\"toggleViewMode()\"\n title=\"Toggle view mode\">\n </button>\n <button kendoButton \n [icon]=\"showFilterPanel ? 'fa-solid fa-filter-circle-xmark' : 'fa-solid fa-filter'\"\n [fillMode]=\"'flat'\"\n (click)=\"toggleFilterPanel()\"\n title=\"Toggle filters\">\n </button>\n <button kendoButton \n [icon]=\"'fa-solid fa-sync'\"\n [fillMode]=\"'flat'\"\n (click)=\"refreshData()\"\n title=\"Refresh\">\n </button>\n </div>\n </div>\n </div>\n\n <!-- Main Content Area -->\n <div class=\"dashboard-content\">\n <!-- Left Filter Panel -->\n @if (showFilterPanel && activeTab === 'browse') {\n <div class=\"filter-panel\">\n <div class=\"filter-header\">\n <h3>Filters</h3>\n <button kendoButton \n [fillMode]=\"'flat'\"\n [size]=\"'small'\"\n (click)=\"clearFilters()\">\n Clear All\n </button>\n </div>\n \n <!-- Search -->\n <div class=\"filter-section\">\n <label class=\"filter-label\">Search</label>\n <kendo-textbox \n [value]=\"searchQuery$.value\"\n (valueChange)=\"onSearchChange($event)\"\n placeholder=\"Search components...\"\n [clearButton]=\"true\">\n <ng-template kendoTextBoxPrefixTemplate>\n <i class=\"fa-solid fa-search\"></i>\n </ng-template>\n </kendo-textbox>\n </div>\n\n <!-- Type Filter -->\n <div class=\"filter-section\">\n <label class=\"filter-label\">Component Type</label>\n <div class=\"filter-options\">\n @for (type of componentTypes; track type) {\n <label class=\"checkbox-label\">\n <input type=\"checkbox\" \n [checked]=\"selectedTypes$.value.has(type)\"\n (change)=\"onTypeFilterChange(type, $any($event.target).checked)\">\n <span class=\"type-indicator\" [style.background-color]=\"getComponentTypeColor(type)\"></span>\n {{ type }}\n </label>\n }\n </div>\n </div>\n\n <!-- Status Filter -->\n <div class=\"filter-section\">\n <label class=\"filter-label\">Status</label>\n <div class=\"filter-options\">\n @for (status of componentStatuses; track status) {\n <label class=\"checkbox-label\">\n <input type=\"checkbox\" \n [checked]=\"selectedStatuses$.value.has(status)\"\n (change)=\"onStatusFilterChange(status, $any($event.target).checked)\">\n <span class=\"status-badge\" [ngClass]=\"getStatusBadgeClass(status)\">{{ status }}</span>\n </label>\n }\n </div>\n </div>\n\n <!-- Source Filter -->\n <div class=\"filter-section\">\n <label class=\"filter-label\">Source</label>\n <div class=\"filter-options\">\n <label class=\"checkbox-label\">\n <input type=\"checkbox\" \n [checked]=\"selectedSources$.value.has('Local')\"\n (change)=\"onSourceFilterChange('Local', $any($event.target).checked)\">\n <i class=\"fa-solid fa-house\"></i> Local\n </label>\n <label class=\"checkbox-label\">\n <input type=\"checkbox\" \n [checked]=\"selectedSources$.value.has('Registry')\"\n (change)=\"onSourceFilterChange('Registry', $any($event.target).checked)\">\n <i class=\"fa-solid fa-cloud\"></i> Registry\n </label>\n </div>\n </div>\n </div>\n }\n\n <!-- Center Content Area -->\n <div class=\"content-area\">\n <!-- Tab Content -->\n @if (activeTab === 'browse') {\n <div class=\"browse-content\">\n <!-- Results Summary -->\n <div class=\"results-summary\">\n <span class=\"result-count\">\n {{ filteredComponents$.value.length }} components found\n </span>\n </div>\n\n <!-- Component Grid/List -->\n @if (viewMode === 'grid') {\n <div class=\"component-grid\">\n @for (component of filteredComponents$.value; track component.ID) {\n <div class=\"component-card\" \n [class.selected]=\"selectedComponentId === component.ID\"\n (click)=\"selectComponent(component)\">\n <div class=\"card-header\">\n <div class=\"card-type\" [style.background-color]=\"getComponentTypeColor(component.Type || 'Other')\">\n {{ component.Type || 'Other' }}\n </div>\n <div class=\"card-status\" [ngClass]=\"getStatusBadgeClass(component.Status || 'Draft')\">\n {{ component.Status }}\n </div>\n </div>\n <div class=\"card-body\">\n <h4 class=\"card-title\">{{ component.Name }}</h4>\n <div class=\"card-version\">v{{ component.Version }}</div>\n <p class=\"card-description\">{{ component.Description || 'No description available' }}</p>\n <div class=\"card-namespace\">\n <i class=\"fa-solid fa-folder-tree\"></i>\n {{ component.Namespace || 'root' }}\n </div>\n </div>\n <div class=\"card-footer\">\n <div class=\"card-developer\">\n <i class=\"fa-solid fa-user\"></i>\n {{ component.DeveloperOrganization || component.DeveloperName || 'Unknown' }}\n </div>\n <div class=\"card-source\">\n @if (!component.SourceRegistryID) {\n <i class=\"fa-solid fa-house\" title=\"Local\"></i>\n } @else {\n <i class=\"fa-solid fa-cloud\" title=\"Registry\"></i>\n }\n </div>\n </div>\n </div>\n }\n </div>\n } @else {\n <!-- List View -->\n <kendo-grid \n [data]=\"filteredComponents$.value\"\n [pageSize]=\"20\"\n [pageable]=\"true\"\n [sortable]=\"true\"\n [filterable]=\"false\"\n [resizable]=\"true\"\n [selectable]=\"true\"\n (selectionChange)=\"selectComponent($event.selectedRows && $event.selectedRows[0] ? $event.selectedRows[0].dataItem : null)\">\n <kendo-grid-column field=\"Name\" title=\"Component\" [width]=\"250\">\n <ng-template kendoGridCellTemplate let-dataItem>\n <div class=\"component-name\">\n <span class=\"type-dot\" [style.background-color]=\"getComponentTypeColor(dataItem.Type || 'Other')\"></span>\n {{ dataItem.Name }}\n </div>\n </ng-template>\n </kendo-grid-column>\n <kendo-grid-column field=\"Version\" title=\"Version\" [width]=\"80\"></kendo-grid-column>\n <kendo-grid-column field=\"Type\" title=\"Type\" [width]=\"100\"></kendo-grid-column>\n <kendo-grid-column field=\"Status\" title=\"Status\" [width]=\"100\">\n <ng-template kendoGridCellTemplate let-dataItem>\n <span class=\"status-badge\" [ngClass]=\"getStatusBadgeClass(dataItem.Status || 'Draft')\">\n {{ dataItem.Status }}\n </span>\n </ng-template>\n </kendo-grid-column>\n <kendo-grid-column field=\"Namespace\" title=\"Namespace\" [width]=\"200\"></kendo-grid-column>\n <kendo-grid-column field=\"DeveloperOrganization\" title=\"Developer\" [width]=\"150\"></kendo-grid-column>\n <kendo-grid-column field=\"Description\" title=\"Description\"></kendo-grid-column>\n </kendo-grid>\n }\n </div>\n }\n\n @if (activeTab === 'preview') {\n <div class=\"preview-content\">\n @if (selectedComponent) {\n <mj-component-preview \n [component]=\"selectedComponent\"\n [componentSpec]=\"componentSpec\"\n (openEntityRecord)=\"onOpenEntityRecord($event)\">\n </mj-component-preview>\n } @else {\n <div class=\"empty-state\">\n <i class=\"fa-solid fa-eye fa-4x\"></i>\n <h3>No Component Selected</h3>\n <p>Select a component from the Browse tab to preview it</p>\n </div>\n }\n </div>\n }\n\n @if (activeTab === 'dependencies') {\n <div class=\"dependencies-content\">\n @if (selectedComponent) {\n <mj-component-dependencies\n [component]=\"selectedComponent\"\n (openEntityRecord)=\"onOpenEntityRecord($event)\">\n </mj-component-dependencies>\n } @else {\n <div class=\"empty-state\">\n <i class=\"fa-solid fa-sitemap fa-4x\"></i>\n <h3>No Component Selected</h3>\n <p>Select a component to view its dependencies</p>\n </div>\n }\n </div>\n }\n\n @if (activeTab === 'settings') {\n <div class=\"settings-content\">\n <mj-component-studio-settings\n (openEntityRecord)=\"onOpenEntityRecord($event)\">\n </mj-component-studio-settings>\n </div>\n }\n </div>\n </div>\n\n <!-- Bottom Navigation -->\n <div class=\"dashboard-navigation\">\n @for (navItem of navigationConfig; track $index) {\n <div \n class=\"nav-item\"\n [class.active]=\"navItem.selected\"\n (click)=\"onTabChange(navigationItems[$index])\">\n <i [class]=\"navItem.icon\"></i>\n <span>{{ navItem.text }}</span>\n </div>\n }\n </div>\n </div>\n }\n</div>", styles: [":host {\n display: block;\n width: 100%;\n height: 100%;\n position: relative;\n}\n\n.component-studio-dashboard {\n display: flex;\n flex-direction: column;\n height: 100%;\n background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);\n position: relative;\n overflow: hidden;\n\n &::before {\n content: '';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(255, 255, 255, 0.03);\n backdrop-filter: blur(10px);\n z-index: 0;\n }\n\n .loading-container {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n position: relative;\n z-index: 1;\n \n .loading-content {\n text-align: center;\n color: white;\n \n .loading-spinner {\n margin-bottom: 20px;\n animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;\n }\n \n .loading-text {\n font-size: 18px;\n font-weight: 500;\n opacity: 0.9;\n }\n }\n }\n\n .dashboard-wrapper {\n display: flex;\n flex-direction: column;\n height: 100%;\n position: relative;\n z-index: 1;\n }\n\n // Header\n .dashboard-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 20px 30px;\n background: rgba(255, 255, 255, 0.1);\n backdrop-filter: blur(20px);\n border-bottom: 1px solid rgba(255, 255, 255, 0.2);\n position: relative;\n z-index: 2;\n \n .header-left {\n .dashboard-title {\n display: flex;\n align-items: center;\n gap: 12px;\n font-size: 28px;\n font-weight: 700;\n color: white;\n margin: 0;\n \n i {\n font-size: 32px;\n }\n }\n \n .dashboard-subtitle {\n color: rgba(255, 255, 255, 0.8);\n font-size: 14px;\n margin-top: 4px;\n margin-left: 44px;\n }\n }\n \n .header-right {\n .header-actions {\n display: flex;\n gap: 8px;\n \n button {\n background: rgba(255, 255, 255, 0.2);\n border: 1px solid rgba(255, 255, 255, 0.3);\n color: white;\n \n &:hover {\n background: rgba(255, 255, 255, 0.3);\n }\n }\n }\n }\n }\n\n // Main Content\n .dashboard-content {\n flex: 1;\n display: flex;\n overflow: hidden;\n background: rgba(255, 255, 255, 0.95);\n margin: 20px;\n border-radius: 12px;\n box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);\n position: relative;\n z-index: 1;\n }\n\n // Filter Panel\n .filter-panel {\n width: 280px;\n background: white;\n border-right: 1px solid #e5e7eb;\n padding: 20px;\n overflow-y: auto;\n \n .filter-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n margin-bottom: 20px;\n \n h3 {\n font-size: 16px;\n font-weight: 600;\n color: #1f2937;\n margin: 0;\n }\n \n button {\n padding: 4px 8px;\n font-size: 12px;\n }\n }\n \n .filter-section {\n margin-bottom: 24px;\n \n .filter-label {\n display: block;\n font-size: 13px;\n font-weight: 600;\n color: #6b7280;\n text-transform: uppercase;\n letter-spacing: 0.05em;\n margin-bottom: 8px;\n }\n \n kendo-textbox {\n width: 100%;\n }\n \n .filter-options {\n display: flex;\n flex-direction: column;\n gap: 8px;\n \n .checkbox-label {\n display: flex;\n align-items: center;\n gap: 8px;\n cursor: pointer;\n font-size: 14px;\n color: #374151;\n \n &:hover {\n color: #111827;\n }\n \n input[type=\"checkbox\"] {\n cursor: pointer;\n }\n \n .type-indicator {\n width: 12px;\n height: 12px;\n border-radius: 3px;\n flex-shrink: 0;\n }\n \n .status-badge {\n padding: 2px 8px;\n border-radius: 12px;\n font-size: 11px;\n font-weight: 600;\n \n &.badge-draft {\n background: #fef3c7;\n color: #92400e;\n }\n \n &.badge-published {\n background: #d1fae5;\n color: #065f46;\n }\n \n &.badge-deprecated {\n background: #fee2e2;\n color: #991b1b;\n }\n }\n }\n }\n }\n }\n\n // Content Area\n .content-area {\n flex: 1;\n display: flex;\n flex-direction: column;\n overflow: hidden;\n \n .browse-content {\n display: flex;\n flex-direction: column;\n height: 100%;\n padding: 20px;\n \n .results-summary {\n display: flex;\n justify-content: space-between;\n align-items: center;\n margin-bottom: 20px;\n \n .result-count {\n font-size: 14px;\n color: #6b7280;\n }\n }\n \n // Component Grid\n .component-grid {\n display: grid;\n grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));\n gap: 20px;\n overflow-y: auto;\n padding: 4px;\n \n .component-card {\n background: white;\n border: 2px solid #e5e7eb;\n border-radius: 12px;\n padding: 16px;\n cursor: pointer;\n transition: all 0.2s ease;\n position: relative;\n overflow: hidden;\n height: fit-content;\n \n &:hover {\n border-color: #9ca3af;\n transform: translateY(-2px);\n box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);\n }\n \n &.selected {\n border-color: #6366f1;\n background: linear-gradient(135deg, rgba(99, 102, 241, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);\n }\n \n .card-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n margin-bottom: 12px;\n \n .card-type {\n padding: 4px 10px;\n border-radius: 6px;\n color: white;\n font-size: 11px;\n font-weight: 600;\n text-transform: uppercase;\n letter-spacing: 0.05em;\n }\n \n .card-status {\n padding: 3px 8px;\n border-radius: 12px;\n font-size: 11px;\n font-weight: 600;\n \n &.badge-draft {\n background: #fef3c7;\n color: #92400e;\n }\n \n &.badge-published {\n background: #d1fae5;\n color: #065f46;\n }\n \n &.badge-deprecated {\n background: #fee2e2;\n color: #991b1b;\n }\n }\n }\n \n .card-body {\n margin-bottom: 12px;\n \n .card-title {\n font-size: 16px;\n font-weight: 600;\n color: #111827;\n margin: 0 0 4px 0;\n }\n \n .card-version {\n font-size: 12px;\n color: #6b7280;\n margin-bottom: 8px;\n }\n \n .card-description {\n font-size: 13px;\n color: #6b7280;\n line-height: 1.5;\n margin: 8px 0;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n }\n \n .card-namespace {\n font-size: 12px;\n color: #9ca3af;\n display: flex;\n align-items: center;\n gap: 6px;\n \n i {\n font-size: 11px;\n }\n }\n }\n \n .card-footer {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding-top: 12px;\n border-top: 1px solid #f3f4f6;\n \n .card-developer {\n font-size: 12px;\n color: #6b7280;\n display: flex;\n align-items: center;\n gap: 6px;\n \n i {\n font-size: 11px;\n }\n }\n \n .card-source {\n font-size: 14px;\n color: #9ca3af;\n }\n }\n }\n }\n \n // List View (Kendo Grid styling)\n kendo-grid {\n height: 100%;\n \n .component-name {\n display: flex;\n align-items: center;\n gap: 8px;\n \n .type-dot {\n width: 8px;\n height: 8px;\n border-radius: 50%;\n }\n }\n \n .status-badge {\n padding: 2px 8px;\n border-radius: 12px;\n font-size: 11px;\n font-weight: 600;\n display: inline-block;\n \n &.badge-draft {\n background: #fef3c7;\n color: #92400e;\n }\n \n &.badge-published {\n background: #d1fae5;\n color: #065f46;\n }\n \n &.badge-deprecated {\n background: #fee2e2;\n color: #991b1b;\n }\n }\n }\n }\n \n .preview-content,\n .dependencies-content,\n .settings-content {\n height: 100%;\n padding: 20px;\n overflow-y: auto;\n }\n \n .empty-state {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n height: 100%;\n color: #9ca3af;\n \n i {\n margin-bottom: 20px;\n opacity: 0.5;\n }\n \n h3 {\n font-size: 20px;\n font-weight: 600;\n color: #6b7280;\n margin: 0 0 8px 0;\n }\n \n p {\n font-size: 14px;\n color: #9ca3af;\n margin: 0;\n }\n }\n }\n\n // Bottom Navigation\n .dashboard-navigation {\n display: flex;\n justify-content: center;\n gap: 4px;\n padding: 12px 20px;\n background: rgba(255, 255, 255, 0.1);\n backdrop-filter: blur(20px);\n border-top: 1px solid rgba(255, 255, 255, 0.2);\n position: relative;\n z-index: 2;\n \n .nav-item {\n display: flex;\n flex-direction: column;\n align-items: center;\n gap: 4px;\n padding: 8px 24px;\n border-radius: 8px;\n cursor: pointer;\n transition: all 0.2s ease;\n color: rgba(255, 255, 255, 0.7);\n \n i {\n font-size: 20px;\n }\n \n span {\n font-size: 12px;\n font-weight: 500;\n }\n \n &:hover {\n background: rgba(255, 255, 255, 0.15);\n color: white;\n }\n \n &.active {\n background: rgba(255, 255, 255, 0.25);\n color: white;\n }\n }\n }\n}\n\n// Animations\n@keyframes pulse {\n 0%, 100% {\n opacity: 1;\n }\n 50% {\n opacity: 0.5;\n }\n}"] }]
|
|
741
|
+
}], () => [{ type: i0.ChangeDetectorRef }], null); })();
|
|
742
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ComponentStudioDashboardComponent, { className: "ComponentStudioDashboardComponent", filePath: "src/ComponentStudio/component-studio-dashboard.component.ts", lineNumber: 53 }); })();
|
|
743
|
+
/**
|
|
744
|
+
* Function to prevent tree shaking of the ComponentStudioDashboardComponent.
|
|
745
|
+
* This is called in public-api.ts to ensure the component is included in the build.
|
|
746
|
+
*/
|
|
747
|
+
export function LoadComponentStudioDashboard() {
|
|
748
|
+
// This function doesn't need to do anything, it just needs to exist
|
|
749
|
+
// to create a reference to the component that prevents tree shaking
|
|
750
|
+
}
|
|
751
|
+
//# sourceMappingURL=component-studio-dashboard.component.js.map
|