@memberjunction/ng-credentials 0.0.1 → 3.4.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.
Files changed (30) hide show
  1. package/dist/lib/credentials.module.d.ts +21 -0
  2. package/dist/lib/credentials.module.d.ts.map +1 -0
  3. package/dist/lib/credentials.module.js +86 -0
  4. package/dist/lib/credentials.module.js.map +1 -0
  5. package/dist/lib/dialogs/credential-dialog.component.d.ts +68 -0
  6. package/dist/lib/dialogs/credential-dialog.component.d.ts.map +1 -0
  7. package/dist/lib/dialogs/credential-dialog.component.js +188 -0
  8. package/dist/lib/dialogs/credential-dialog.component.js.map +1 -0
  9. package/dist/lib/panels/credential-category-edit-panel/credential-category-edit-panel.component.d.ts +44 -0
  10. package/dist/lib/panels/credential-category-edit-panel/credential-category-edit-panel.component.d.ts.map +1 -0
  11. package/dist/lib/panels/credential-category-edit-panel/credential-category-edit-panel.component.js +237 -0
  12. package/dist/lib/panels/credential-category-edit-panel/credential-category-edit-panel.component.js.map +1 -0
  13. package/dist/lib/panels/credential-edit-panel/credential-edit-panel.component.d.ts +96 -0
  14. package/dist/lib/panels/credential-edit-panel/credential-edit-panel.component.d.ts.map +1 -0
  15. package/dist/lib/panels/credential-edit-panel/credential-edit-panel.component.js +533 -0
  16. package/dist/lib/panels/credential-edit-panel/credential-edit-panel.component.js.map +1 -0
  17. package/dist/lib/panels/credential-type-edit-panel/credential-type-edit-panel.component.d.ts +56 -0
  18. package/dist/lib/panels/credential-type-edit-panel/credential-type-edit-panel.component.d.ts.map +1 -0
  19. package/dist/lib/panels/credential-type-edit-panel/credential-type-edit-panel.component.js +278 -0
  20. package/dist/lib/panels/credential-type-edit-panel/credential-type-edit-panel.component.js.map +1 -0
  21. package/dist/lib/services/credential-dialog.service.d.ts +89 -0
  22. package/dist/lib/services/credential-dialog.service.d.ts.map +1 -0
  23. package/dist/lib/services/credential-dialog.service.js +166 -0
  24. package/dist/lib/services/credential-dialog.service.js.map +1 -0
  25. package/dist/public-api.d.ts +15 -0
  26. package/dist/public-api.d.ts.map +1 -0
  27. package/dist/public-api.js +19 -0
  28. package/dist/public-api.js.map +1 -0
  29. package/package.json +43 -6
  30. package/README.md +0 -45
@@ -0,0 +1 @@
1
+ {"version":3,"file":"credential-edit-panel.component.js","sourceRoot":"","sources":["../../../../src/lib/panels/credential-edit-panel/credential-edit-panel.component.ts","../../../../src/lib/panels/credential-edit-panel/credential-edit-panel.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,EAAE,YAAY,EAAqB,uBAAuB,EAAqB,YAAY,EAAE,MAAM,eAAe,CAAC;AAEpJ,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,EAAE,qBAAqB,EAAE,MAAM,kCAAkC,CAAC;;;;;AAEzE,MAAM,UAAU,uBAAuB;IACnC,wBAAwB;AAC5B,CAAC;AAgCD,MAAM,OAAO,4BAA4B;IA8BjB;IA7BX,UAAU,GAA4B,IAAI,CAAC;IAC3C,eAAe,GAA2B,EAAE,CAAC;IAC7C,MAAM,GAAG,KAAK,CAAC;IAEd,KAAK,GAAG,IAAI,YAAY,EAAQ,CAAC;IACjC,KAAK,GAAG,IAAI,YAAY,EAAoB,CAAC;IAC7C,OAAO,GAAG,IAAI,YAAY,EAAU,CAAC;IAExC,SAAS,GAAG,KAAK,CAAC;IAClB,QAAQ,GAAG,KAAK,CAAC;IACjB,KAAK,GAAG,KAAK,CAAC;IACd,UAAU,GAA+B,EAAE,CAAC;IAEnD,cAAc;IACP,IAAI,GAAG,EAAE,CAAC;IACV,WAAW,GAAG,EAAE,CAAC;IACjB,cAAc,GAAG,EAAE,CAAC;IACpB,kBAAkB,GAAG,EAAE,CAAC;IACxB,QAAQ,GAAG,IAAI,CAAC;IAChB,SAAS,GAAG,KAAK,CAAC;IAClB,SAAS,GAAgB,IAAI,CAAC;IAErC,iDAAiD;IAC1C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CAAC;YAED,0FAA0F;YAC1F,IAAI,KAAK,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC;gBAClC,SAAS;YACb,CAAC;YAED,wBAAwB;YACxB,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,KAAK,CAAC;QAChC,CAAC;QAED,OAAO,OAAO,CAAC;IACnB,CAAC;wGAtkBQ,4BAA4B;4FAA5B,4BAA4B,wSCvCzC,6ocAuRA;;4FDhPa,4BAA4B;kBANxC,SAAS;+BACI,0BAA0B,mBAGnB,uBAAuB,CAAC,MAAM;sFAGtC,UAAU;sBAAlB,KAAK;gBACG,eAAe;sBAAvB,KAAK;gBACG,MAAM;sBAAd,KAAK;gBAEI,KAAK;sBAAd,MAAM;gBACG,KAAK;sBAAd,MAAM;gBACG,OAAO;sBAAhB,MAAM;gBAkXA,WAAW;sBADjB,YAAY;uBAAC,yBAAyB,EAAE,CAAC,QAAQ,CAAC"}
@@ -0,0 +1,56 @@
1
+ import { EventEmitter, ChangeDetectorRef, OnInit } from '@angular/core';
2
+ import { CredentialTypeEntity } from '@memberjunction/core-entities';
3
+ import * as i0 from "@angular/core";
4
+ export declare function LoadCredentialTypeEditPanel(): void;
5
+ type CategoryType = 'AI' | 'Authentication' | 'Communication' | 'Database' | 'Integration' | 'Storage';
6
+ interface SchemaField {
7
+ name: string;
8
+ type: string;
9
+ title: string;
10
+ description: string;
11
+ isSecret: boolean;
12
+ required: boolean;
13
+ order: number;
14
+ }
15
+ export declare class CredentialTypeEditPanelComponent implements OnInit {
16
+ private cdr;
17
+ credentialType: CredentialTypeEntity | null;
18
+ isOpen: boolean;
19
+ close: EventEmitter<void>;
20
+ saved: EventEmitter<CredentialTypeEntity>;
21
+ deleted: EventEmitter<string>;
22
+ isLoading: boolean;
23
+ isSaving: boolean;
24
+ isNew: boolean;
25
+ name: string;
26
+ description: string;
27
+ category: CategoryType;
28
+ iconClass: string;
29
+ validationEndpoint: string;
30
+ schemaFields: SchemaField[];
31
+ categories: CategoryType[];
32
+ private _metadata;
33
+ constructor(cdr: ChangeDetectorRef);
34
+ ngOnInit(): void;
35
+ get panelTitle(): string;
36
+ get canSave(): boolean;
37
+ open(credentialType: CredentialTypeEntity | null): Promise<void>;
38
+ private resetForm;
39
+ private populateFromType;
40
+ private parseFieldSchema;
41
+ private buildFieldSchema;
42
+ addSchemaField(): void;
43
+ removeSchemaField(index: number): void;
44
+ moveFieldUp(index: number): void;
45
+ moveFieldDown(index: number): void;
46
+ save(): Promise<void>;
47
+ deleteType(): Promise<void>;
48
+ closePanel(): void;
49
+ onBackdropClick(event: MouseEvent): void;
50
+ getCategoryIcon(category: string): string;
51
+ getCategoryColor(category: string): string;
52
+ static ɵfac: i0.ɵɵFactoryDeclaration<CredentialTypeEditPanelComponent, never>;
53
+ static ɵcmp: i0.ɵɵComponentDeclaration<CredentialTypeEditPanelComponent, "mj-credential-type-edit-panel", never, { "credentialType": { "alias": "credentialType"; "required": false; }; "isOpen": { "alias": "isOpen"; "required": false; }; }, { "close": "close"; "saved": "saved"; "deleted": "deleted"; }, never, never, false, never>;
54
+ }
55
+ export {};
56
+ //# sourceMappingURL=credential-type-edit-panel.component.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"credential-type-edit-panel.component.d.ts","sourceRoot":"","sources":["../../../../src/lib/panels/credential-type-edit-panel/credential-type-edit-panel.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAA4B,YAAY,EAAE,iBAAiB,EAA2B,MAAM,EAAE,MAAM,eAAe,CAAC;AAC3H,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;;AAIrE,wBAAgB,2BAA2B,SAE1C;AAED,KAAK,YAAY,GAAG,IAAI,GAAG,gBAAgB,GAAG,eAAe,GAAG,UAAU,GAAG,aAAa,GAAG,SAAS,CAAC;AAEvG,UAAU,WAAW;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE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UAAU,GAAG,IAAI;IAMxC,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM;IAYzC,gBAAgB,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM;yCAvSxC,gCAAgC;2CAAhC,gCAAgC;CAkT5C"}
@@ -0,0 +1,278 @@
1
+ import { Component, Input, Output, EventEmitter, ChangeDetectionStrategy } from '@angular/core';
2
+ import { Metadata } from '@memberjunction/core';
3
+ import { MJNotificationService } from '@memberjunction/ng-notifications';
4
+ import * as i0 from "@angular/core";
5
+ import * as i1 from "@angular/common";
6
+ import * as i2 from "@angular/forms";
7
+ import * as i3 from "@memberjunction/ng-shared-generic";
8
+ export function LoadCredentialTypeEditPanel() {
9
+ // Prevents tree-shaking
10
+ }
11
+ export class CredentialTypeEditPanelComponent {
12
+ cdr;
13
+ credentialType = null;
14
+ isOpen = false;
15
+ close = new EventEmitter();
16
+ saved = new EventEmitter();
17
+ deleted = new EventEmitter();
18
+ isLoading = false;
19
+ isSaving = false;
20
+ isNew = false;
21
+ // Form fields
22
+ name = '';
23
+ description = '';
24
+ category = 'Integration';
25
+ iconClass = '';
26
+ validationEndpoint = '';
27
+ schemaFields = [];
28
+ // Available categories
29
+ categories = ['AI', 'Authentication', 'Communication', 'Database', 'Integration', 'Storage'];
30
+ _metadata = new Metadata();
31
+ constructor(cdr) {
32
+ this.cdr = cdr;
33
+ }
34
+ ngOnInit() { }
35
+ get panelTitle() {
36
+ return this.isNew ? 'Create Credential Type' : 'Edit Credential Type';
37
+ }
38
+ get canSave() {
39
+ return this.name.trim().length > 0 && this.category.length > 0;
40
+ }
41
+ async open(credentialType) {
42
+ this.isLoading = true;
43
+ this.isOpen = true;
44
+ this.credentialType = credentialType;
45
+ this.isNew = !credentialType || !credentialType.ID;
46
+ this.cdr.markForCheck();
47
+ this.resetForm();
48
+ if (credentialType && credentialType.ID) {
49
+ this.populateFromType(credentialType);
50
+ }
51
+ this.isLoading = false;
52
+ this.cdr.markForCheck();
53
+ }
54
+ resetForm() {
55
+ this.name = '';
56
+ this.description = '';
57
+ this.category = 'Integration';
58
+ this.iconClass = '';
59
+ this.validationEndpoint = '';
60
+ this.schemaFields = [];
61
+ }
62
+ populateFromType(credentialType) {
63
+ this.name = credentialType.Name || '';
64
+ this.description = credentialType.Description || '';
65
+ this.category = credentialType.Category || 'Integration';
66
+ this.iconClass = credentialType.IconClass || '';
67
+ this.validationEndpoint = credentialType.ValidationEndpoint || '';
68
+ // Parse field schema
69
+ this.parseFieldSchema(credentialType.FieldSchema);
70
+ }
71
+ parseFieldSchema(schemaJson) {
72
+ try {
73
+ if (!schemaJson) {
74
+ this.schemaFields = [];
75
+ return;
76
+ }
77
+ const schema = JSON.parse(schemaJson);
78
+ const properties = schema.properties || {};
79
+ const required = schema.required || [];
80
+ this.schemaFields = Object.entries(properties).map(([name, prop]) => ({
81
+ name,
82
+ type: prop.type || 'string',
83
+ title: prop.title || name,
84
+ description: prop.description || '',
85
+ isSecret: prop.isSecret === true,
86
+ required: required.includes(name),
87
+ order: typeof prop.order === 'number' ? prop.order : 999
88
+ }));
89
+ this.schemaFields.sort((a, b) => a.order - b.order);
90
+ }
91
+ catch (e) {
92
+ console.error('Error parsing field schema:', e);
93
+ this.schemaFields = [];
94
+ }
95
+ }
96
+ buildFieldSchema() {
97
+ if (this.schemaFields.length === 0) {
98
+ return JSON.stringify({ type: 'object', properties: {}, required: [] });
99
+ }
100
+ const properties = {};
101
+ const required = [];
102
+ for (let i = 0; i < this.schemaFields.length; i++) {
103
+ const field = this.schemaFields[i];
104
+ properties[field.name] = {
105
+ type: field.type,
106
+ title: field.title,
107
+ description: field.description,
108
+ isSecret: field.isSecret,
109
+ order: i
110
+ };
111
+ if (field.required) {
112
+ required.push(field.name);
113
+ }
114
+ }
115
+ return JSON.stringify({
116
+ $schema: 'http://json-schema.org/draft-07/schema#',
117
+ type: 'object',
118
+ properties,
119
+ required
120
+ }, null, 2);
121
+ }
122
+ // Schema field management
123
+ addSchemaField() {
124
+ this.schemaFields.push({
125
+ name: '',
126
+ type: 'string',
127
+ title: '',
128
+ description: '',
129
+ isSecret: false,
130
+ required: false,
131
+ order: this.schemaFields.length
132
+ });
133
+ this.cdr.markForCheck();
134
+ }
135
+ removeSchemaField(index) {
136
+ this.schemaFields.splice(index, 1);
137
+ this.cdr.markForCheck();
138
+ }
139
+ moveFieldUp(index) {
140
+ if (index > 0) {
141
+ const temp = this.schemaFields[index];
142
+ this.schemaFields[index] = this.schemaFields[index - 1];
143
+ this.schemaFields[index - 1] = temp;
144
+ this.cdr.markForCheck();
145
+ }
146
+ }
147
+ moveFieldDown(index) {
148
+ if (index < this.schemaFields.length - 1) {
149
+ const temp = this.schemaFields[index];
150
+ this.schemaFields[index] = this.schemaFields[index + 1];
151
+ this.schemaFields[index + 1] = temp;
152
+ this.cdr.markForCheck();
153
+ }
154
+ }
155
+ async save() {
156
+ if (!this.canSave) {
157
+ MJNotificationService.Instance.CreateSimpleNotification('Please fill in all required fields', 'warning', 3000);
158
+ return;
159
+ }
160
+ this.isSaving = true;
161
+ this.cdr.markForCheck();
162
+ try {
163
+ let entity;
164
+ if (this.isNew) {
165
+ entity = await this._metadata.GetEntityObject('MJ: Credential Types');
166
+ }
167
+ else {
168
+ entity = this.credentialType;
169
+ }
170
+ entity.Name = this.name.trim();
171
+ entity.Description = this.description.trim() || null;
172
+ entity.Category = this.category;
173
+ entity.IconClass = this.iconClass.trim() || null;
174
+ entity.ValidationEndpoint = this.validationEndpoint.trim() || null;
175
+ entity.FieldSchema = this.buildFieldSchema();
176
+ const success = await entity.Save();
177
+ if (success) {
178
+ const action = this.isNew ? 'created' : 'updated';
179
+ MJNotificationService.Instance.CreateSimpleNotification(`Credential type "${entity.Name}" ${action} successfully`, 'success', 3000);
180
+ this.saved.emit(entity);
181
+ this.closePanel();
182
+ }
183
+ else {
184
+ const errorMessage = entity.LatestResult?.Message || 'Unknown error';
185
+ console.error('Save failed:', errorMessage);
186
+ MJNotificationService.Instance.CreateSimpleNotification(`Failed to save credential type: ${errorMessage}`, 'error', 5000);
187
+ }
188
+ }
189
+ catch (error) {
190
+ console.error('Error saving credential type:', error);
191
+ MJNotificationService.Instance.CreateSimpleNotification('Error saving credential type', 'error', 3000);
192
+ }
193
+ finally {
194
+ this.isSaving = false;
195
+ this.cdr.markForCheck();
196
+ }
197
+ }
198
+ async deleteType() {
199
+ if (this.isNew || !this.credentialType)
200
+ return;
201
+ const confirmed = confirm(`Are you sure you want to delete "${this.credentialType.Name}"? This action cannot be undone.`);
202
+ if (!confirmed)
203
+ return;
204
+ this.isSaving = true;
205
+ this.cdr.markForCheck();
206
+ try {
207
+ const success = await this.credentialType.Delete();
208
+ if (success) {
209
+ MJNotificationService.Instance.CreateSimpleNotification(`Credential type "${this.credentialType.Name}" deleted successfully`, 'success', 3000);
210
+ this.deleted.emit(this.credentialType.ID);
211
+ this.closePanel();
212
+ }
213
+ else {
214
+ const errorMessage = this.credentialType.LatestResult?.Message || 'Unknown error';
215
+ MJNotificationService.Instance.CreateSimpleNotification(`Failed to delete credential type: ${errorMessage}`, 'error', 5000);
216
+ }
217
+ }
218
+ catch (error) {
219
+ console.error('Error deleting credential type:', error);
220
+ MJNotificationService.Instance.CreateSimpleNotification('Error deleting credential type', 'error', 3000);
221
+ }
222
+ finally {
223
+ this.isSaving = false;
224
+ this.cdr.markForCheck();
225
+ }
226
+ }
227
+ closePanel() {
228
+ this.isOpen = false;
229
+ this.credentialType = null;
230
+ this.resetForm();
231
+ this.close.emit();
232
+ this.cdr.markForCheck();
233
+ }
234
+ onBackdropClick(event) {
235
+ if (event.target.classList.contains('panel-backdrop')) {
236
+ this.closePanel();
237
+ }
238
+ }
239
+ getCategoryIcon(category) {
240
+ const iconMap = {
241
+ 'AI': 'fa-solid fa-brain',
242
+ 'Communication': 'fa-solid fa-envelope',
243
+ 'Storage': 'fa-solid fa-cloud',
244
+ 'Database': 'fa-solid fa-database',
245
+ 'Authentication': 'fa-solid fa-shield-halved',
246
+ 'Integration': 'fa-solid fa-plug'
247
+ };
248
+ return iconMap[category] || 'fa-solid fa-key';
249
+ }
250
+ getCategoryColor(category) {
251
+ const colorMap = {
252
+ 'AI': '#8b5cf6',
253
+ 'Communication': '#3b82f6',
254
+ 'Storage': '#06b6d4',
255
+ 'Database': '#f59e0b',
256
+ 'Authentication': '#10b981',
257
+ 'Integration': '#ec4899'
258
+ };
259
+ return colorMap[category] || '#6366f1';
260
+ }
261
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: CredentialTypeEditPanelComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
262
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.14", type: CredentialTypeEditPanelComponent, selector: "mj-credential-type-edit-panel", inputs: { credentialType: "credentialType", isOpen: "isOpen" }, outputs: { close: "close", saved: "saved", deleted: "deleted" }, ngImport: i0, template: "<div class=\"panel-backdrop\" *ngIf=\"isOpen\" (click)=\"onBackdropClick($event)\">\n <div class=\"edit-panel\" [class.open]=\"isOpen\">\n <!-- Panel Header -->\n <div class=\"panel-header\">\n <div class=\"header-content\">\n <div class=\"header-icon\" [style.backgroundColor]=\"getCategoryColor(category) + '15'\" [style.color]=\"getCategoryColor(category)\">\n <i [class]=\"iconClass || getCategoryIcon(category)\"></i>\n </div>\n <div class=\"header-text\">\n <h2>{{panelTitle}}</h2>\n <span class=\"header-subtitle\">{{category}} credential type</span>\n </div>\n </div>\n <button class=\"close-btn\" (click)=\"closePanel()\" [disabled]=\"isSaving\">\n <i class=\"fa-solid fa-times\"></i>\n </button>\n </div>\n\n <!-- Panel Body -->\n <div class=\"panel-body\">\n <mj-loading *ngIf=\"isLoading\" text=\"Loading...\"></mj-loading>\n\n <form *ngIf=\"!isLoading\" class=\"type-form\" (submit)=\"$event.preventDefault(); save()\">\n <!-- Basic Info Section -->\n <div class=\"form-section\">\n <h3 class=\"section-title\">\n <i class=\"fa-solid fa-info-circle\"></i>\n Basic Information\n </h3>\n\n <div class=\"form-group\">\n <label for=\"typeName\" class=\"required\">Name</label>\n <input\n type=\"text\"\n id=\"typeName\"\n name=\"typeName\"\n [(ngModel)]=\"name\"\n placeholder=\"e.g., OpenAI, SendGrid, AWS S3\"\n [disabled]=\"isSaving\"\n required\n />\n </div>\n\n <div class=\"form-group\">\n <label for=\"typeCategory\" class=\"required\">Category</label>\n <div class=\"category-selector\">\n <button\n type=\"button\"\n *ngFor=\"let cat of categories\"\n class=\"category-btn\"\n [class.selected]=\"category === cat\"\n [style.--cat-color]=\"getCategoryColor(cat)\"\n (click)=\"category = cat\"\n [disabled]=\"isSaving\"\n >\n <i [class]=\"getCategoryIcon(cat)\"></i>\n <span>{{cat}}</span>\n </button>\n </div>\n </div>\n\n <div class=\"form-group\">\n <label for=\"typeDescription\">Description</label>\n <textarea\n id=\"typeDescription\"\n name=\"typeDescription\"\n [(ngModel)]=\"description\"\n placeholder=\"Optional description of this credential type...\"\n rows=\"3\"\n [disabled]=\"isSaving\"\n ></textarea>\n </div>\n\n <div class=\"form-row\">\n <div class=\"form-group\">\n <label for=\"typeIcon\">Icon Class</label>\n <input\n type=\"text\"\n id=\"typeIcon\"\n name=\"typeIcon\"\n [(ngModel)]=\"iconClass\"\n placeholder=\"e.g., fa-brands fa-openai\"\n [disabled]=\"isSaving\"\n />\n <span class=\"field-hint\">Font Awesome icon class</span>\n </div>\n\n <div class=\"form-group\">\n <label for=\"validationEndpoint\">Validation Endpoint</label>\n <input\n type=\"text\"\n id=\"validationEndpoint\"\n name=\"validationEndpoint\"\n [(ngModel)]=\"validationEndpoint\"\n placeholder=\"https://api.example.com/validate\"\n [disabled]=\"isSaving\"\n />\n <span class=\"field-hint\">Optional API endpoint to validate credentials</span>\n </div>\n </div>\n </div>\n\n <!-- Field Schema Section -->\n <div class=\"form-section\">\n <div class=\"section-header-row\">\n <h3 class=\"section-title\">\n <i class=\"fa-solid fa-list-check\"></i>\n Field Schema\n </h3>\n <button\n type=\"button\"\n class=\"btn-add-field\"\n (click)=\"addSchemaField()\"\n [disabled]=\"isSaving\"\n >\n <i class=\"fa-solid fa-plus\"></i>\n Add Field\n </button>\n </div>\n\n <div class=\"schema-fields\" *ngIf=\"schemaFields.length > 0\">\n <div class=\"schema-field\" *ngFor=\"let field of schemaFields; let i = index\">\n <div class=\"field-drag-handle\">\n <button type=\"button\" class=\"move-btn\" (click)=\"moveFieldUp(i)\" [disabled]=\"i === 0 || isSaving\">\n <i class=\"fa-solid fa-chevron-up\"></i>\n </button>\n <button type=\"button\" class=\"move-btn\" (click)=\"moveFieldDown(i)\" [disabled]=\"i === schemaFields.length - 1 || isSaving\">\n <i class=\"fa-solid fa-chevron-down\"></i>\n </button>\n </div>\n\n <div class=\"field-content\">\n <div class=\"field-row\">\n <input\n type=\"text\"\n [name]=\"'fieldName_' + i\"\n [(ngModel)]=\"field.name\"\n placeholder=\"Field name (e.g., apiKey)\"\n class=\"field-name-input\"\n [disabled]=\"isSaving\"\n />\n <input\n type=\"text\"\n [name]=\"'fieldTitle_' + i\"\n [(ngModel)]=\"field.title\"\n placeholder=\"Display title\"\n class=\"field-title-input\"\n [disabled]=\"isSaving\"\n />\n <select [name]=\"'fieldType_' + i\" [(ngModel)]=\"field.type\" class=\"field-type-select\" [disabled]=\"isSaving\">\n <option value=\"string\">String</option>\n <option value=\"number\">Number</option>\n <option value=\"boolean\">Boolean</option>\n </select>\n </div>\n\n <div class=\"field-row\">\n <input\n type=\"text\"\n [name]=\"'fieldDesc_' + i\"\n [(ngModel)]=\"field.description\"\n placeholder=\"Field description (optional)\"\n class=\"field-desc-input\"\n [disabled]=\"isSaving\"\n />\n </div>\n\n <div class=\"field-options\">\n <label class=\"checkbox-label\">\n <input type=\"checkbox\" [name]=\"'fieldRequired_' + i\" [(ngModel)]=\"field.required\" [disabled]=\"isSaving\" />\n <span>Required</span>\n </label>\n <label class=\"checkbox-label\">\n <input type=\"checkbox\" [name]=\"'fieldSecret_' + i\" [(ngModel)]=\"field.isSecret\" [disabled]=\"isSaving\" />\n <span><i class=\"fa-solid fa-lock\"></i> Secret</span>\n </label>\n </div>\n </div>\n\n <button\n type=\"button\"\n class=\"remove-field-btn\"\n (click)=\"removeSchemaField(i)\"\n [disabled]=\"isSaving\"\n title=\"Remove field\"\n >\n <i class=\"fa-solid fa-trash\"></i>\n </button>\n </div>\n </div>\n\n <div class=\"no-fields-message\" *ngIf=\"schemaFields.length === 0\">\n <i class=\"fa-solid fa-info-circle\"></i>\n <span>No fields defined. Add fields that credentials of this type will need to store.</span>\n </div>\n </div>\n </form>\n </div>\n\n <!-- Panel Footer -->\n <div class=\"panel-footer\">\n <div class=\"footer-left\">\n <button\n class=\"btn-delete\"\n *ngIf=\"!isNew\"\n (click)=\"deleteType()\"\n [disabled]=\"isSaving\"\n >\n <i class=\"fa-solid fa-trash\"></i>\n <span>Delete</span>\n </button>\n </div>\n <div class=\"footer-right\">\n <button\n class=\"btn-secondary\"\n (click)=\"closePanel()\"\n [disabled]=\"isSaving\"\n >\n Cancel\n </button>\n <button\n class=\"btn-primary\"\n (click)=\"save()\"\n [disabled]=\"isSaving || !canSave\"\n >\n <i class=\"fa-solid fa-spinner fa-spin\" *ngIf=\"isSaving\"></i>\n <i class=\"fa-solid fa-check\" *ngIf=\"!isSaving\"></i>\n <span>{{isNew ? 'Create' : 'Save'}}</span>\n </button>\n </div>\n </div>\n </div>\n</div>\n", styles: ["/* Panel Backdrop */\n.panel-backdrop {\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(0, 0, 0, 0.5);\n z-index: 1000;\n display: flex;\n justify-content: flex-end;\n animation: fadeIn 0.2s ease-out;\n}\n\n@keyframes fadeIn {\n from { opacity: 0; }\n to { opacity: 1; }\n}\n\n/* Slide-in Panel */\n.edit-panel {\n width: 100%;\n max-width: 600px;\n height: 100%;\n background: #ffffff;\n display: flex;\n flex-direction: column;\n box-shadow: -4px 0 24px rgba(0, 0, 0, 0.15);\n transform: translateX(100%);\n animation: slideIn 0.3s ease-out forwards;\n}\n\n@keyframes slideIn {\n from { transform: translateX(100%); }\n to { transform: translateX(0); }\n}\n\n/* Panel Header */\n.panel-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 20px 24px;\n border-bottom: 1px solid #e5e7eb;\n background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);\n}\n\n.header-content {\n display: flex;\n align-items: center;\n gap: 16px;\n}\n\n.header-icon {\n width: 48px;\n height: 48px;\n border-radius: 12px;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 20px;\n flex-shrink: 0;\n}\n\n.header-text h2 {\n font-size: 18px;\n font-weight: 600;\n color: #1e293b;\n margin: 0 0 4px 0;\n}\n\n.header-subtitle {\n font-size: 13px;\n color: #64748b;\n}\n\n.close-btn {\n width: 36px;\n height: 36px;\n border: none;\n background: #f1f5f9;\n border-radius: 8px;\n cursor: pointer;\n color: #64748b;\n font-size: 16px;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.15s ease;\n}\n\n.close-btn:hover:not(:disabled) {\n background: #e2e8f0;\n color: #334155;\n}\n\n.close-btn:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n/* Panel Body */\n.panel-body {\n flex: 1;\n overflow-y: auto;\n padding: 24px;\n scroll-behavior: smooth;\n -webkit-overflow-scrolling: touch;\n}\n\n/* Form Sections */\n.form-section {\n margin-bottom: 28px;\n}\n\n.form-section:last-child {\n margin-bottom: 0;\n}\n\n.section-title {\n display: flex;\n align-items: center;\n gap: 10px;\n font-size: 14px;\n font-weight: 600;\n color: #334155;\n margin: 0 0 16px 0;\n padding-bottom: 10px;\n border-bottom: 1px solid #f1f5f9;\n}\n\n.section-title i {\n color: #6366f1;\n font-size: 14px;\n}\n\n.section-header-row {\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-bottom: 16px;\n}\n\n.section-header-row .section-title {\n margin: 0;\n padding: 0;\n border: none;\n}\n\n.btn-add-field {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 6px 12px;\n background: #6366f1;\n color: white;\n border: none;\n border-radius: 6px;\n font-size: 12px;\n font-weight: 500;\n cursor: pointer;\n transition: all 0.15s ease;\n}\n\n.btn-add-field:hover:not(:disabled) {\n background: #4f46e5;\n}\n\n.btn-add-field:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n/* Form Groups */\n.form-group {\n margin-bottom: 18px;\n}\n\n.form-group:last-child {\n margin-bottom: 0;\n}\n\n.form-group label {\n display: block;\n font-size: 13px;\n font-weight: 500;\n color: #475569;\n margin-bottom: 6px;\n}\n\n.form-group label.required::after {\n content: '*';\n color: #ef4444;\n margin-left: 4px;\n}\n\n.form-group input[type=\"text\"],\n.form-group input[type=\"number\"],\n.form-group select,\n.form-group textarea {\n width: 100%;\n padding: 10px 14px;\n border: 1px solid #d1d5db;\n border-radius: 8px;\n font-size: 14px;\n color: #1e293b;\n background: #ffffff;\n transition: all 0.15s ease;\n box-sizing: border-box;\n}\n\n.form-group input:focus,\n.form-group select:focus,\n.form-group textarea:focus {\n outline: none;\n border-color: #6366f1;\n box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);\n}\n\n.form-group input:disabled,\n.form-group select:disabled,\n.form-group textarea:disabled {\n background: #f8fafc;\n color: #94a3b8;\n cursor: not-allowed;\n}\n\n.form-group textarea {\n resize: vertical;\n min-height: 80px;\n}\n\n.field-hint {\n display: block;\n font-size: 12px;\n color: #94a3b8;\n margin-top: 5px;\n}\n\n.form-row {\n display: grid;\n grid-template-columns: 1fr 1fr;\n gap: 16px;\n}\n\n/* Category Selector */\n.category-selector {\n display: grid;\n grid-template-columns: repeat(3, 1fr);\n gap: 10px;\n}\n\n.category-btn {\n display: flex;\n flex-direction: column;\n align-items: center;\n gap: 6px;\n padding: 12px 8px;\n border: 2px solid #e5e7eb;\n border-radius: 10px;\n background: #ffffff;\n cursor: pointer;\n transition: all 0.2s ease;\n color: #64748b;\n}\n\n.category-btn i {\n font-size: 18px;\n}\n\n.category-btn span {\n font-size: 11px;\n font-weight: 500;\n}\n\n.category-btn:hover:not(:disabled) {\n border-color: var(--cat-color);\n background: color-mix(in srgb, var(--cat-color) 5%, white);\n}\n\n.category-btn.selected {\n border-color: var(--cat-color);\n background: color-mix(in srgb, var(--cat-color) 10%, white);\n color: var(--cat-color);\n}\n\n.category-btn:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n/* Schema Fields */\n.schema-fields {\n display: flex;\n flex-direction: column;\n gap: 12px;\n}\n\n.schema-field {\n display: flex;\n gap: 12px;\n padding: 14px;\n background: #f8fafc;\n border: 1px solid #e5e7eb;\n border-radius: 10px;\n}\n\n.field-drag-handle {\n display: flex;\n flex-direction: column;\n gap: 4px;\n}\n\n.move-btn {\n width: 24px;\n height: 24px;\n border: none;\n background: #e2e8f0;\n border-radius: 4px;\n cursor: pointer;\n color: #64748b;\n font-size: 10px;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.15s ease;\n}\n\n.move-btn:hover:not(:disabled) {\n background: #cbd5e1;\n color: #334155;\n}\n\n.move-btn:disabled {\n opacity: 0.3;\n cursor: not-allowed;\n}\n\n.field-content {\n flex: 1;\n display: flex;\n flex-direction: column;\n gap: 10px;\n}\n\n.field-row {\n display: flex;\n gap: 10px;\n}\n\n.field-name-input {\n flex: 1;\n padding: 8px 12px;\n border: 1px solid #d1d5db;\n border-radius: 6px;\n font-size: 13px;\n font-family: monospace;\n}\n\n.field-title-input {\n flex: 1;\n padding: 8px 12px;\n border: 1px solid #d1d5db;\n border-radius: 6px;\n font-size: 13px;\n}\n\n.field-type-select {\n width: 100px;\n padding: 8px 10px;\n border: 1px solid #d1d5db;\n border-radius: 6px;\n font-size: 13px;\n cursor: pointer;\n}\n\n.field-desc-input {\n flex: 1;\n padding: 8px 12px;\n border: 1px solid #d1d5db;\n border-radius: 6px;\n font-size: 13px;\n}\n\n.field-options {\n display: flex;\n gap: 16px;\n}\n\n.checkbox-label {\n display: flex;\n align-items: center;\n gap: 6px;\n font-size: 12px;\n color: #64748b;\n cursor: pointer;\n}\n\n.checkbox-label input[type=\"checkbox\"] {\n width: 14px;\n height: 14px;\n accent-color: #6366f1;\n}\n\n.checkbox-label i {\n font-size: 10px;\n color: #f59e0b;\n}\n\n.remove-field-btn {\n width: 32px;\n height: 32px;\n border: none;\n background: transparent;\n color: #94a3b8;\n cursor: pointer;\n border-radius: 6px;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.15s ease;\n align-self: flex-start;\n}\n\n.remove-field-btn:hover:not(:disabled) {\n background: #fef2f2;\n color: #dc2626;\n}\n\n.remove-field-btn:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n.no-fields-message {\n display: flex;\n align-items: center;\n gap: 10px;\n padding: 16px;\n background: #f8fafc;\n border: 2px dashed #e2e8f0;\n border-radius: 10px;\n color: #64748b;\n font-size: 13px;\n}\n\n.no-fields-message i {\n color: #94a3b8;\n}\n\n/* Panel Footer */\n.panel-footer {\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 16px 24px;\n border-top: 1px solid #e5e7eb;\n background: #f8fafc;\n}\n\n.footer-left,\n.footer-right {\n display: flex;\n align-items: center;\n gap: 12px;\n}\n\n.btn-primary,\n.btn-secondary,\n.btn-delete {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 10px 20px;\n border: none;\n border-radius: 8px;\n font-size: 14px;\n font-weight: 500;\n cursor: pointer;\n transition: all 0.15s ease;\n}\n\n.btn-primary {\n background: #6366f1;\n color: #ffffff;\n}\n\n.btn-primary:hover:not(:disabled) {\n background: #4f46e5;\n}\n\n.btn-primary:disabled {\n background: #c7d2fe;\n cursor: not-allowed;\n}\n\n.btn-secondary {\n background: #ffffff;\n color: #475569;\n border: 1px solid #d1d5db;\n}\n\n.btn-secondary:hover:not(:disabled) {\n background: #f1f5f9;\n border-color: #94a3b8;\n}\n\n.btn-secondary:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n.btn-delete {\n background: transparent;\n color: #dc2626;\n padding: 10px 16px;\n}\n\n.btn-delete:hover:not(:disabled) {\n background: #fef2f2;\n}\n\n.btn-delete:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n/* Mobile Responsiveness */\n@media (max-width: 768px) {\n .edit-panel {\n max-width: 100%;\n }\n\n .panel-header {\n padding: 16px 20px;\n }\n\n .header-icon {\n width: 40px;\n height: 40px;\n font-size: 18px;\n }\n\n .header-text h2 {\n font-size: 16px;\n }\n\n .panel-body {\n padding: 20px;\n }\n\n .form-row {\n grid-template-columns: 1fr;\n }\n\n .category-selector {\n grid-template-columns: repeat(2, 1fr);\n }\n\n .schema-field {\n flex-direction: column;\n }\n\n .field-drag-handle {\n flex-direction: row;\n justify-content: flex-end;\n order: 1;\n }\n\n .field-content {\n order: 0;\n }\n\n .remove-field-btn {\n order: 2;\n align-self: flex-end;\n }\n\n .field-row {\n flex-direction: column;\n }\n\n .field-type-select {\n width: 100%;\n }\n\n .panel-footer {\n padding: 14px 20px;\n flex-direction: column-reverse;\n gap: 12px;\n }\n\n .footer-left,\n .footer-right {\n width: 100%;\n }\n\n .footer-right {\n flex-direction: row;\n }\n\n .footer-right .btn-primary,\n .footer-right .btn-secondary {\n flex: 1;\n justify-content: center;\n }\n\n .btn-delete {\n width: 100%;\n justify-content: center;\n background: #fef2f2;\n }\n}\n\n@media (max-width: 480px) {\n .panel-header {\n padding: 14px 16px;\n }\n\n .header-content {\n gap: 12px;\n }\n\n .header-icon {\n width: 36px;\n height: 36px;\n font-size: 16px;\n border-radius: 10px;\n }\n\n .header-text h2 {\n font-size: 15px;\n }\n\n .header-subtitle {\n font-size: 12px;\n }\n\n .panel-body {\n padding: 16px;\n }\n\n .category-selector {\n grid-template-columns: repeat(3, 1fr);\n }\n\n .category-btn {\n padding: 10px 6px;\n }\n\n .category-btn i {\n font-size: 16px;\n }\n\n .category-btn span {\n font-size: 10px;\n }\n\n .schema-field {\n padding: 12px;\n }\n\n .field-name-input,\n .field-title-input,\n .field-desc-input,\n .field-type-select {\n font-size: 14px;\n padding: 10px 12px;\n }\n\n .panel-footer {\n padding: 12px 16px;\n }\n\n .btn-primary,\n .btn-secondary {\n padding: 10px 16px;\n font-size: 13px;\n }\n}\n\n/* Custom scrollbar */\n.panel-body::-webkit-scrollbar {\n width: 6px;\n}\n\n.panel-body::-webkit-scrollbar-track {\n background: transparent;\n}\n\n.panel-body::-webkit-scrollbar-thumb {\n background: #d1d5db;\n border-radius: 3px;\n}\n\n.panel-body::-webkit-scrollbar-thumb:hover {\n background: #94a3b8;\n}\n\n/* Animations */\n@keyframes spin {\n from { transform: rotate(0deg); }\n to { transform: rotate(360deg); }\n}\n\n.fa-spin {\n animation: spin 1s linear infinite;\n}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i2.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i3.LoadingComponent, selector: "mj-loading", inputs: ["text", "showText", "animationDuration", "size", "textColor", "logoColor", "logoGradient", "animation"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
263
+ }
264
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: CredentialTypeEditPanelComponent, decorators: [{
265
+ type: Component,
266
+ args: [{ selector: 'mj-credential-type-edit-panel', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"panel-backdrop\" *ngIf=\"isOpen\" (click)=\"onBackdropClick($event)\">\n <div class=\"edit-panel\" [class.open]=\"isOpen\">\n <!-- Panel Header -->\n <div class=\"panel-header\">\n <div class=\"header-content\">\n <div class=\"header-icon\" [style.backgroundColor]=\"getCategoryColor(category) + '15'\" [style.color]=\"getCategoryColor(category)\">\n <i [class]=\"iconClass || getCategoryIcon(category)\"></i>\n </div>\n <div class=\"header-text\">\n <h2>{{panelTitle}}</h2>\n <span class=\"header-subtitle\">{{category}} credential type</span>\n </div>\n </div>\n <button class=\"close-btn\" (click)=\"closePanel()\" [disabled]=\"isSaving\">\n <i class=\"fa-solid fa-times\"></i>\n </button>\n </div>\n\n <!-- Panel Body -->\n <div class=\"panel-body\">\n <mj-loading *ngIf=\"isLoading\" text=\"Loading...\"></mj-loading>\n\n <form *ngIf=\"!isLoading\" class=\"type-form\" (submit)=\"$event.preventDefault(); save()\">\n <!-- Basic Info Section -->\n <div class=\"form-section\">\n <h3 class=\"section-title\">\n <i class=\"fa-solid fa-info-circle\"></i>\n Basic Information\n </h3>\n\n <div class=\"form-group\">\n <label for=\"typeName\" class=\"required\">Name</label>\n <input\n type=\"text\"\n id=\"typeName\"\n name=\"typeName\"\n [(ngModel)]=\"name\"\n placeholder=\"e.g., OpenAI, SendGrid, AWS S3\"\n [disabled]=\"isSaving\"\n required\n />\n </div>\n\n <div class=\"form-group\">\n <label for=\"typeCategory\" class=\"required\">Category</label>\n <div class=\"category-selector\">\n <button\n type=\"button\"\n *ngFor=\"let cat of categories\"\n class=\"category-btn\"\n [class.selected]=\"category === cat\"\n [style.--cat-color]=\"getCategoryColor(cat)\"\n (click)=\"category = cat\"\n [disabled]=\"isSaving\"\n >\n <i [class]=\"getCategoryIcon(cat)\"></i>\n <span>{{cat}}</span>\n </button>\n </div>\n </div>\n\n <div class=\"form-group\">\n <label for=\"typeDescription\">Description</label>\n <textarea\n id=\"typeDescription\"\n name=\"typeDescription\"\n [(ngModel)]=\"description\"\n placeholder=\"Optional description of this credential type...\"\n rows=\"3\"\n [disabled]=\"isSaving\"\n ></textarea>\n </div>\n\n <div class=\"form-row\">\n <div class=\"form-group\">\n <label for=\"typeIcon\">Icon Class</label>\n <input\n type=\"text\"\n id=\"typeIcon\"\n name=\"typeIcon\"\n [(ngModel)]=\"iconClass\"\n placeholder=\"e.g., fa-brands fa-openai\"\n [disabled]=\"isSaving\"\n />\n <span class=\"field-hint\">Font Awesome icon class</span>\n </div>\n\n <div class=\"form-group\">\n <label for=\"validationEndpoint\">Validation Endpoint</label>\n <input\n type=\"text\"\n id=\"validationEndpoint\"\n name=\"validationEndpoint\"\n [(ngModel)]=\"validationEndpoint\"\n placeholder=\"https://api.example.com/validate\"\n [disabled]=\"isSaving\"\n />\n <span class=\"field-hint\">Optional API endpoint to validate credentials</span>\n </div>\n </div>\n </div>\n\n <!-- Field Schema Section -->\n <div class=\"form-section\">\n <div class=\"section-header-row\">\n <h3 class=\"section-title\">\n <i class=\"fa-solid fa-list-check\"></i>\n Field Schema\n </h3>\n <button\n type=\"button\"\n class=\"btn-add-field\"\n (click)=\"addSchemaField()\"\n [disabled]=\"isSaving\"\n >\n <i class=\"fa-solid fa-plus\"></i>\n Add Field\n </button>\n </div>\n\n <div class=\"schema-fields\" *ngIf=\"schemaFields.length > 0\">\n <div class=\"schema-field\" *ngFor=\"let field of schemaFields; let i = index\">\n <div class=\"field-drag-handle\">\n <button type=\"button\" class=\"move-btn\" (click)=\"moveFieldUp(i)\" [disabled]=\"i === 0 || isSaving\">\n <i class=\"fa-solid fa-chevron-up\"></i>\n </button>\n <button type=\"button\" class=\"move-btn\" (click)=\"moveFieldDown(i)\" [disabled]=\"i === schemaFields.length - 1 || isSaving\">\n <i class=\"fa-solid fa-chevron-down\"></i>\n </button>\n </div>\n\n <div class=\"field-content\">\n <div class=\"field-row\">\n <input\n type=\"text\"\n [name]=\"'fieldName_' + i\"\n [(ngModel)]=\"field.name\"\n placeholder=\"Field name (e.g., apiKey)\"\n class=\"field-name-input\"\n [disabled]=\"isSaving\"\n />\n <input\n type=\"text\"\n [name]=\"'fieldTitle_' + i\"\n [(ngModel)]=\"field.title\"\n placeholder=\"Display title\"\n class=\"field-title-input\"\n [disabled]=\"isSaving\"\n />\n <select [name]=\"'fieldType_' + i\" [(ngModel)]=\"field.type\" class=\"field-type-select\" [disabled]=\"isSaving\">\n <option value=\"string\">String</option>\n <option value=\"number\">Number</option>\n <option value=\"boolean\">Boolean</option>\n </select>\n </div>\n\n <div class=\"field-row\">\n <input\n type=\"text\"\n [name]=\"'fieldDesc_' + i\"\n [(ngModel)]=\"field.description\"\n placeholder=\"Field description (optional)\"\n class=\"field-desc-input\"\n [disabled]=\"isSaving\"\n />\n </div>\n\n <div class=\"field-options\">\n <label class=\"checkbox-label\">\n <input type=\"checkbox\" [name]=\"'fieldRequired_' + i\" [(ngModel)]=\"field.required\" [disabled]=\"isSaving\" />\n <span>Required</span>\n </label>\n <label class=\"checkbox-label\">\n <input type=\"checkbox\" [name]=\"'fieldSecret_' + i\" [(ngModel)]=\"field.isSecret\" [disabled]=\"isSaving\" />\n <span><i class=\"fa-solid fa-lock\"></i> Secret</span>\n </label>\n </div>\n </div>\n\n <button\n type=\"button\"\n class=\"remove-field-btn\"\n (click)=\"removeSchemaField(i)\"\n [disabled]=\"isSaving\"\n title=\"Remove field\"\n >\n <i class=\"fa-solid fa-trash\"></i>\n </button>\n </div>\n </div>\n\n <div class=\"no-fields-message\" *ngIf=\"schemaFields.length === 0\">\n <i class=\"fa-solid fa-info-circle\"></i>\n <span>No fields defined. Add fields that credentials of this type will need to store.</span>\n </div>\n </div>\n </form>\n </div>\n\n <!-- Panel Footer -->\n <div class=\"panel-footer\">\n <div class=\"footer-left\">\n <button\n class=\"btn-delete\"\n *ngIf=\"!isNew\"\n (click)=\"deleteType()\"\n [disabled]=\"isSaving\"\n >\n <i class=\"fa-solid fa-trash\"></i>\n <span>Delete</span>\n </button>\n </div>\n <div class=\"footer-right\">\n <button\n class=\"btn-secondary\"\n (click)=\"closePanel()\"\n [disabled]=\"isSaving\"\n >\n Cancel\n </button>\n <button\n class=\"btn-primary\"\n (click)=\"save()\"\n [disabled]=\"isSaving || !canSave\"\n >\n <i class=\"fa-solid fa-spinner fa-spin\" *ngIf=\"isSaving\"></i>\n <i class=\"fa-solid fa-check\" *ngIf=\"!isSaving\"></i>\n <span>{{isNew ? 'Create' : 'Save'}}</span>\n </button>\n </div>\n </div>\n </div>\n</div>\n", styles: ["/* Panel Backdrop */\n.panel-backdrop {\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(0, 0, 0, 0.5);\n z-index: 1000;\n display: flex;\n justify-content: flex-end;\n animation: fadeIn 0.2s ease-out;\n}\n\n@keyframes fadeIn {\n from { opacity: 0; }\n to { opacity: 1; }\n}\n\n/* Slide-in Panel */\n.edit-panel {\n width: 100%;\n max-width: 600px;\n height: 100%;\n background: #ffffff;\n display: flex;\n flex-direction: column;\n box-shadow: -4px 0 24px rgba(0, 0, 0, 0.15);\n transform: translateX(100%);\n animation: slideIn 0.3s ease-out forwards;\n}\n\n@keyframes slideIn {\n from { transform: translateX(100%); }\n to { transform: translateX(0); }\n}\n\n/* Panel Header */\n.panel-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 20px 24px;\n border-bottom: 1px solid #e5e7eb;\n background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);\n}\n\n.header-content {\n display: flex;\n align-items: center;\n gap: 16px;\n}\n\n.header-icon {\n width: 48px;\n height: 48px;\n border-radius: 12px;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 20px;\n flex-shrink: 0;\n}\n\n.header-text h2 {\n font-size: 18px;\n font-weight: 600;\n color: #1e293b;\n margin: 0 0 4px 0;\n}\n\n.header-subtitle {\n font-size: 13px;\n color: #64748b;\n}\n\n.close-btn {\n width: 36px;\n height: 36px;\n border: none;\n background: #f1f5f9;\n border-radius: 8px;\n cursor: pointer;\n color: #64748b;\n font-size: 16px;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.15s ease;\n}\n\n.close-btn:hover:not(:disabled) {\n background: #e2e8f0;\n color: #334155;\n}\n\n.close-btn:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n/* Panel Body */\n.panel-body {\n flex: 1;\n overflow-y: auto;\n padding: 24px;\n scroll-behavior: smooth;\n -webkit-overflow-scrolling: touch;\n}\n\n/* Form Sections */\n.form-section {\n margin-bottom: 28px;\n}\n\n.form-section:last-child {\n margin-bottom: 0;\n}\n\n.section-title {\n display: flex;\n align-items: center;\n gap: 10px;\n font-size: 14px;\n font-weight: 600;\n color: #334155;\n margin: 0 0 16px 0;\n padding-bottom: 10px;\n border-bottom: 1px solid #f1f5f9;\n}\n\n.section-title i {\n color: #6366f1;\n font-size: 14px;\n}\n\n.section-header-row {\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-bottom: 16px;\n}\n\n.section-header-row .section-title {\n margin: 0;\n padding: 0;\n border: none;\n}\n\n.btn-add-field {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 6px 12px;\n background: #6366f1;\n color: white;\n border: none;\n border-radius: 6px;\n font-size: 12px;\n font-weight: 500;\n cursor: pointer;\n transition: all 0.15s ease;\n}\n\n.btn-add-field:hover:not(:disabled) {\n background: #4f46e5;\n}\n\n.btn-add-field:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n/* Form Groups */\n.form-group {\n margin-bottom: 18px;\n}\n\n.form-group:last-child {\n margin-bottom: 0;\n}\n\n.form-group label {\n display: block;\n font-size: 13px;\n font-weight: 500;\n color: #475569;\n margin-bottom: 6px;\n}\n\n.form-group label.required::after {\n content: '*';\n color: #ef4444;\n margin-left: 4px;\n}\n\n.form-group input[type=\"text\"],\n.form-group input[type=\"number\"],\n.form-group select,\n.form-group textarea {\n width: 100%;\n padding: 10px 14px;\n border: 1px solid #d1d5db;\n border-radius: 8px;\n font-size: 14px;\n color: #1e293b;\n background: #ffffff;\n transition: all 0.15s ease;\n box-sizing: border-box;\n}\n\n.form-group input:focus,\n.form-group select:focus,\n.form-group textarea:focus {\n outline: none;\n border-color: #6366f1;\n box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);\n}\n\n.form-group input:disabled,\n.form-group select:disabled,\n.form-group textarea:disabled {\n background: #f8fafc;\n color: #94a3b8;\n cursor: not-allowed;\n}\n\n.form-group textarea {\n resize: vertical;\n min-height: 80px;\n}\n\n.field-hint {\n display: block;\n font-size: 12px;\n color: #94a3b8;\n margin-top: 5px;\n}\n\n.form-row {\n display: grid;\n grid-template-columns: 1fr 1fr;\n gap: 16px;\n}\n\n/* Category Selector */\n.category-selector {\n display: grid;\n grid-template-columns: repeat(3, 1fr);\n gap: 10px;\n}\n\n.category-btn {\n display: flex;\n flex-direction: column;\n align-items: center;\n gap: 6px;\n padding: 12px 8px;\n border: 2px solid #e5e7eb;\n border-radius: 10px;\n background: #ffffff;\n cursor: pointer;\n transition: all 0.2s ease;\n color: #64748b;\n}\n\n.category-btn i {\n font-size: 18px;\n}\n\n.category-btn span {\n font-size: 11px;\n font-weight: 500;\n}\n\n.category-btn:hover:not(:disabled) {\n border-color: var(--cat-color);\n background: color-mix(in srgb, var(--cat-color) 5%, white);\n}\n\n.category-btn.selected {\n border-color: var(--cat-color);\n background: color-mix(in srgb, var(--cat-color) 10%, white);\n color: var(--cat-color);\n}\n\n.category-btn:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n/* Schema Fields */\n.schema-fields {\n display: flex;\n flex-direction: column;\n gap: 12px;\n}\n\n.schema-field {\n display: flex;\n gap: 12px;\n padding: 14px;\n background: #f8fafc;\n border: 1px solid #e5e7eb;\n border-radius: 10px;\n}\n\n.field-drag-handle {\n display: flex;\n flex-direction: column;\n gap: 4px;\n}\n\n.move-btn {\n width: 24px;\n height: 24px;\n border: none;\n background: #e2e8f0;\n border-radius: 4px;\n cursor: pointer;\n color: #64748b;\n font-size: 10px;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.15s ease;\n}\n\n.move-btn:hover:not(:disabled) {\n background: #cbd5e1;\n color: #334155;\n}\n\n.move-btn:disabled {\n opacity: 0.3;\n cursor: not-allowed;\n}\n\n.field-content {\n flex: 1;\n display: flex;\n flex-direction: column;\n gap: 10px;\n}\n\n.field-row {\n display: flex;\n gap: 10px;\n}\n\n.field-name-input {\n flex: 1;\n padding: 8px 12px;\n border: 1px solid #d1d5db;\n border-radius: 6px;\n font-size: 13px;\n font-family: monospace;\n}\n\n.field-title-input {\n flex: 1;\n padding: 8px 12px;\n border: 1px solid #d1d5db;\n border-radius: 6px;\n font-size: 13px;\n}\n\n.field-type-select {\n width: 100px;\n padding: 8px 10px;\n border: 1px solid #d1d5db;\n border-radius: 6px;\n font-size: 13px;\n cursor: pointer;\n}\n\n.field-desc-input {\n flex: 1;\n padding: 8px 12px;\n border: 1px solid #d1d5db;\n border-radius: 6px;\n font-size: 13px;\n}\n\n.field-options {\n display: flex;\n gap: 16px;\n}\n\n.checkbox-label {\n display: flex;\n align-items: center;\n gap: 6px;\n font-size: 12px;\n color: #64748b;\n cursor: pointer;\n}\n\n.checkbox-label input[type=\"checkbox\"] {\n width: 14px;\n height: 14px;\n accent-color: #6366f1;\n}\n\n.checkbox-label i {\n font-size: 10px;\n color: #f59e0b;\n}\n\n.remove-field-btn {\n width: 32px;\n height: 32px;\n border: none;\n background: transparent;\n color: #94a3b8;\n cursor: pointer;\n border-radius: 6px;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.15s ease;\n align-self: flex-start;\n}\n\n.remove-field-btn:hover:not(:disabled) {\n background: #fef2f2;\n color: #dc2626;\n}\n\n.remove-field-btn:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n.no-fields-message {\n display: flex;\n align-items: center;\n gap: 10px;\n padding: 16px;\n background: #f8fafc;\n border: 2px dashed #e2e8f0;\n border-radius: 10px;\n color: #64748b;\n font-size: 13px;\n}\n\n.no-fields-message i {\n color: #94a3b8;\n}\n\n/* Panel Footer */\n.panel-footer {\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 16px 24px;\n border-top: 1px solid #e5e7eb;\n background: #f8fafc;\n}\n\n.footer-left,\n.footer-right {\n display: flex;\n align-items: center;\n gap: 12px;\n}\n\n.btn-primary,\n.btn-secondary,\n.btn-delete {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 10px 20px;\n border: none;\n border-radius: 8px;\n font-size: 14px;\n font-weight: 500;\n cursor: pointer;\n transition: all 0.15s ease;\n}\n\n.btn-primary {\n background: #6366f1;\n color: #ffffff;\n}\n\n.btn-primary:hover:not(:disabled) {\n background: #4f46e5;\n}\n\n.btn-primary:disabled {\n background: #c7d2fe;\n cursor: not-allowed;\n}\n\n.btn-secondary {\n background: #ffffff;\n color: #475569;\n border: 1px solid #d1d5db;\n}\n\n.btn-secondary:hover:not(:disabled) {\n background: #f1f5f9;\n border-color: #94a3b8;\n}\n\n.btn-secondary:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n.btn-delete {\n background: transparent;\n color: #dc2626;\n padding: 10px 16px;\n}\n\n.btn-delete:hover:not(:disabled) {\n background: #fef2f2;\n}\n\n.btn-delete:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n/* Mobile Responsiveness */\n@media (max-width: 768px) {\n .edit-panel {\n max-width: 100%;\n }\n\n .panel-header {\n padding: 16px 20px;\n }\n\n .header-icon {\n width: 40px;\n height: 40px;\n font-size: 18px;\n }\n\n .header-text h2 {\n font-size: 16px;\n }\n\n .panel-body {\n padding: 20px;\n }\n\n .form-row {\n grid-template-columns: 1fr;\n }\n\n .category-selector {\n grid-template-columns: repeat(2, 1fr);\n }\n\n .schema-field {\n flex-direction: column;\n }\n\n .field-drag-handle {\n flex-direction: row;\n justify-content: flex-end;\n order: 1;\n }\n\n .field-content {\n order: 0;\n }\n\n .remove-field-btn {\n order: 2;\n align-self: flex-end;\n }\n\n .field-row {\n flex-direction: column;\n }\n\n .field-type-select {\n width: 100%;\n }\n\n .panel-footer {\n padding: 14px 20px;\n flex-direction: column-reverse;\n gap: 12px;\n }\n\n .footer-left,\n .footer-right {\n width: 100%;\n }\n\n .footer-right {\n flex-direction: row;\n }\n\n .footer-right .btn-primary,\n .footer-right .btn-secondary {\n flex: 1;\n justify-content: center;\n }\n\n .btn-delete {\n width: 100%;\n justify-content: center;\n background: #fef2f2;\n }\n}\n\n@media (max-width: 480px) {\n .panel-header {\n padding: 14px 16px;\n }\n\n .header-content {\n gap: 12px;\n }\n\n .header-icon {\n width: 36px;\n height: 36px;\n font-size: 16px;\n border-radius: 10px;\n }\n\n .header-text h2 {\n font-size: 15px;\n }\n\n .header-subtitle {\n font-size: 12px;\n }\n\n .panel-body {\n padding: 16px;\n }\n\n .category-selector {\n grid-template-columns: repeat(3, 1fr);\n }\n\n .category-btn {\n padding: 10px 6px;\n }\n\n .category-btn i {\n font-size: 16px;\n }\n\n .category-btn span {\n font-size: 10px;\n }\n\n .schema-field {\n padding: 12px;\n }\n\n .field-name-input,\n .field-title-input,\n .field-desc-input,\n .field-type-select {\n font-size: 14px;\n padding: 10px 12px;\n }\n\n .panel-footer {\n padding: 12px 16px;\n }\n\n .btn-primary,\n .btn-secondary {\n padding: 10px 16px;\n font-size: 13px;\n }\n}\n\n/* Custom scrollbar */\n.panel-body::-webkit-scrollbar {\n width: 6px;\n}\n\n.panel-body::-webkit-scrollbar-track {\n background: transparent;\n}\n\n.panel-body::-webkit-scrollbar-thumb {\n background: #d1d5db;\n border-radius: 3px;\n}\n\n.panel-body::-webkit-scrollbar-thumb:hover {\n background: #94a3b8;\n}\n\n/* Animations */\n@keyframes spin {\n from { transform: rotate(0deg); }\n to { transform: rotate(360deg); }\n}\n\n.fa-spin {\n animation: spin 1s linear infinite;\n}\n"] }]
267
+ }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { credentialType: [{
268
+ type: Input
269
+ }], isOpen: [{
270
+ type: Input
271
+ }], close: [{
272
+ type: Output
273
+ }], saved: [{
274
+ type: Output
275
+ }], deleted: [{
276
+ type: Output
277
+ }] } });
278
+ //# sourceMappingURL=credential-type-edit-panel.component.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"credential-type-edit-panel.component.js","sourceRoot":"","sources":["../../../../src/lib/panels/credential-type-edit-panel/credential-type-edit-panel.component.ts","../../../../src/lib/panels/credential-type-edit-panel/credential-type-edit-panel.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,EAAE,YAAY,EAAqB,uBAAuB,EAAU,MAAM,eAAe,CAAC;AAE3H,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAAE,qBAAqB,EAAE,MAAM,kCAAkC,CAAC;;;;;AAEzE,MAAM,UAAU,2BAA2B;IAC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M,QAAQ,GAA2B;YACrC,IAAI,EAAE,SAAS;YACf,eAAe,EAAE,SAAS;YAC1B,SAAS,EAAE,SAAS;YACpB,UAAU,EAAE,SAAS;YACrB,gBAAgB,EAAE,SAAS;YAC3B,aAAa,EAAE,SAAS;SAC3B,CAAC;QACF,OAAO,QAAQ,CAAC,QAAQ,CAAC,IAAI,SAAS,CAAC;IAC3C,CAAC;wGAjTQ,gCAAgC;4FAAhC,gCAAgC,sMC3B7C,8gXAyOA;;4FD9Ma,gCAAgC;kBAN5C,SAAS;+BACI,+BAA+B,mBAGxB,uBAAuB,CAAC,MAAM;sFAGtC,cAAc;sBAAtB,KAAK;gBACG,MAAM;sBAAd,KAAK;gBAEI,KAAK;sBAAd,MAAM;gBACG,KAAK;sBAAd,MAAM;gBACG,OAAO;sBAAhB,MAAM"}
@@ -0,0 +1,89 @@
1
+ /**
2
+ * @fileoverview Credential Dialog Service
3
+ *
4
+ * A service that provides easy programmatic access to credential dialogs.
5
+ * Use this service to open credential creation/editing dialogs from anywhere
6
+ * in your application without needing to include the component in your template.
7
+ */
8
+ import { ViewContainerRef } from '@angular/core';
9
+ import { CredentialEntity, CredentialTypeEntity } from '@memberjunction/core-entities';
10
+ import { CredentialDialogOptions, CredentialDialogResult } from '../dialogs/credential-dialog.component';
11
+ import * as i0 from "@angular/core";
12
+ /**
13
+ * Service for programmatically opening credential dialogs.
14
+ *
15
+ * @example
16
+ * ```typescript
17
+ * // Inject the service
18
+ * constructor(private credentialDialog: CredentialDialogService) {}
19
+ *
20
+ * // Open dialog to create a new credential
21
+ * async createCredential() {
22
+ * const result = await this.credentialDialog.openDialog(this.viewContainerRef);
23
+ * if (result.success && result.credential) {
24
+ * console.log('Created credential:', result.credential.Name);
25
+ * }
26
+ * }
27
+ *
28
+ * // Open dialog with pre-selected type
29
+ * async createApiKey() {
30
+ * const result = await this.credentialDialog.openDialog(this.viewContainerRef, {
31
+ * preselectedTypeId: 'api-key-type-id'
32
+ * });
33
+ * }
34
+ *
35
+ * // Edit an existing credential
36
+ * async editCredential(credential: CredentialEntity) {
37
+ * const result = await this.credentialDialog.openDialog(this.viewContainerRef, {
38
+ * credential
39
+ * });
40
+ * }
41
+ * ```
42
+ */
43
+ export declare class CredentialDialogService {
44
+ private _credentialTypes;
45
+ private _credentialTypesLoading;
46
+ private _credentialTypesLoadPromise;
47
+ /**
48
+ * Opens a credential dialog and returns a promise that resolves when the dialog closes.
49
+ *
50
+ * @param viewContainerRef - The ViewContainerRef to attach the dialog to
51
+ * @param options - Optional configuration for the dialog
52
+ * @returns Promise resolving to the dialog result
53
+ */
54
+ openDialog(viewContainerRef: ViewContainerRef, options?: CredentialDialogOptions): Promise<CredentialDialogResult>;
55
+ /**
56
+ * Opens a dialog to create a new credential with optional pre-selections.
57
+ * Convenience method that wraps openDialog with create-specific defaults.
58
+ *
59
+ * @param viewContainerRef - The ViewContainerRef to attach the dialog to
60
+ * @param preselectedTypeId - Optional credential type to pre-select
61
+ * @param preselectedCategoryId - Optional category to pre-select
62
+ * @returns Promise resolving to the dialog result
63
+ */
64
+ createCredential(viewContainerRef: ViewContainerRef, preselectedTypeId?: string, preselectedCategoryId?: string): Promise<CredentialDialogResult>;
65
+ /**
66
+ * Opens a dialog to edit an existing credential.
67
+ * Convenience method that wraps openDialog with edit-specific defaults.
68
+ *
69
+ * @param viewContainerRef - The ViewContainerRef to attach the dialog to
70
+ * @param credential - The credential to edit
71
+ * @returns Promise resolving to the dialog result
72
+ */
73
+ editCredential(viewContainerRef: ViewContainerRef, credential: CredentialEntity): Promise<CredentialDialogResult>;
74
+ /**
75
+ * Gets cached credential types or loads them if not cached.
76
+ * Types are cached to avoid repeated database calls.
77
+ */
78
+ getCredentialTypes(): Promise<CredentialTypeEntity[]>;
79
+ /**
80
+ * Clears the cached credential types.
81
+ * Call this if you need to refresh the list after adding new types.
82
+ */
83
+ clearCache(): void;
84
+ private loadCredentialTypes;
85
+ private doLoadCredentialTypes;
86
+ static ɵfac: i0.ɵɵFactoryDeclaration<CredentialDialogService, never>;
87
+ static ɵprov: i0.ɵɵInjectableDeclaration<CredentialDialogService>;
88
+ }
89
+ //# sourceMappingURL=credential-dialog.service.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"credential-dialog.service.d.ts","sourceRoot":"","sources":["../../../src/lib/services/credential-dialog.service.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAA4B,gBAAgB,EAAQ,MAAM,eAAe,CAAC;AACjF,OAAO,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AAGvF,OAAO,EAA6B,uBAAuB,EAAE,sBAAsB,EAAE,MAAM,wCAAwC,CAAC;;AAEpI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,qBAGa,uBAAuB;IAChC,OAAO,CAAC,gBAAgB,CAAuC;IAC/D,OAAO,CAAC,uBAAuB,CAAS;IACxC,OAAO,CAAC,2BAA2B,CAAgD;IAEnF;;;;;;OAMG;IACU,UAAU,CACnB,gBAAgB,EAAE,gBAAgB,EAClC,OAAO,CAAC,EAAE,uBAAuB,GAClC,OAAO,CAAC,sBAAsB,CAAC;IAwBlC;;;;;;;;OAQG;IACU,gBAAgB,CACzB,gBAAgB,EAAE,gBAAgB,EAClC,iBAAiB,CAAC,EAAE,MAAM,EAC1B,qBAAqB,CAAC,EAAE,MAAM,GAC/B,OAAO,CAAC,sBAAsB,CAAC;IASlC;;;;;;;OAOG;IACU,cAAc,CACvB,gBAAgB,EAAE,gBAAgB,EAClC,UAAU,EAAE,gBAAgB,GAC7B,OAAO,CAAC,sBAAsB,CAAC;IAOlC;;;OAGG;IACU,kBAAkB,IAAI,OAAO,CAAC,oBAAoB,EAAE,CAAC;IAIlE;;;OAGG;IACI,UAAU,IAAI,IAAI;YAKX,mBAAmB;YAsBnB,qBAAqB;yCAtH1B,uBAAuB;6CAAvB,uBAAuB;CA0InC"}