@memberjunction/ng-base-forms 5.22.0 → 5.24.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/__tests__/tag-count-badge.test.d.ts +2 -0
- package/dist/__tests__/tag-count-badge.test.d.ts.map +1 -0
- package/dist/__tests__/tag-count-badge.test.js +70 -0
- package/dist/__tests__/tag-count-badge.test.js.map +1 -0
- package/dist/lib/base-form-component.d.ts +21 -2
- package/dist/lib/base-form-component.d.ts.map +1 -1
- package/dist/lib/base-form-component.js +28 -1
- package/dist/lib/base-form-component.js.map +1 -1
- package/dist/lib/container/record-form-container.component.d.ts +43 -0
- package/dist/lib/container/record-form-container.component.d.ts.map +1 -1
- package/dist/lib/container/record-form-container.component.js +196 -24
- package/dist/lib/container/record-form-container.component.js.map +1 -1
- package/dist/lib/toolbar/form-toolbar.component.d.ts +10 -1
- package/dist/lib/toolbar/form-toolbar.component.d.ts.map +1 -1
- package/dist/lib/toolbar/form-toolbar.component.js +208 -147
- package/dist/lib/toolbar/form-toolbar.component.js.map +1 -1
- package/dist/lib/types/toolbar-config.d.ts +2 -0
- package/dist/lib/types/toolbar-config.d.ts.map +1 -1
- package/dist/lib/types/toolbar-config.js +2 -0
- package/dist/lib/types/toolbar-config.js.map +1 -1
- package/dist/module.d.ts +2 -1
- package/dist/module.d.ts.map +1 -1
- package/dist/module.js +7 -3
- package/dist/module.js.map +1 -1
- package/package.json +10 -8
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"record-form-container.component.d.ts","sourceRoot":"","sources":["../../../src/lib/container/record-form-container.component.ts"],"names":[],"mappings":"AAAA,OAAO,EACqB,YAAY,EAErB,SAAS,EAAE,gBAAgB,EAAE,SAAS,EAExD,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,UAAU,
|
|
1
|
+
{"version":3,"file":"record-form-container.component.d.ts","sourceRoot":"","sources":["../../../src/lib/container/record-form-container.component.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,28 +1,32 @@
|
|
|
1
1
|
import { Component, Input, Output, EventEmitter, ChangeDetectionStrategy, ChangeDetectorRef, inject, NgZone, ContentChildren, ViewEncapsulation } from '@angular/core';
|
|
2
|
+
import { CompositeKey, Metadata, RunView } from '@memberjunction/core';
|
|
3
|
+
import { UserInfoEngine } from '@memberjunction/core-entities';
|
|
2
4
|
import { Subject } from 'rxjs';
|
|
3
5
|
import { takeUntil } from 'rxjs/operators';
|
|
4
6
|
import { DEFAULT_TOOLBAR_CONFIG } from '../types/toolbar-config';
|
|
5
7
|
import { MjCollapsiblePanelComponent } from '../panel/collapsible-panel.component';
|
|
6
8
|
import { BeforeHistoryViewEventArgs, BeforeListManagementEventArgs } from '../types/form-events';
|
|
9
|
+
import { MJNotificationService } from '@memberjunction/ng-notifications';
|
|
7
10
|
import * as i0 from "@angular/core";
|
|
8
11
|
import * as i1 from "@memberjunction/ng-record-changes";
|
|
9
12
|
import * as i2 from "@memberjunction/ng-list-management";
|
|
10
|
-
import * as i3 from "
|
|
11
|
-
import * as i4 from "../
|
|
12
|
-
import * as i5 from "../
|
|
13
|
+
import * as i3 from "@memberjunction/ng-record-tags";
|
|
14
|
+
import * as i4 from "../toolbar/form-toolbar.component";
|
|
15
|
+
import * as i5 from "../section-manager/section-manager.component";
|
|
16
|
+
import * as i6 from "../isa-related-panel/isa-related-panel.component";
|
|
13
17
|
const _c0 = [[["", "before-toolbar", ""]], "*"];
|
|
14
18
|
const _c1 = ["[before-toolbar]", "*"];
|
|
15
19
|
const _c2 = a0 => [a0];
|
|
16
20
|
const _c3 = (a0, a1, a2) => ({ mode: "manage", entityId: a0, entityName: a1, recordIds: a2, allowCreate: true });
|
|
17
21
|
function MjRecordFormContainerComponent_Conditional_7_Template(rf, ctx) { if (rf & 1) {
|
|
18
22
|
const _r1 = i0.ɵɵgetCurrentView();
|
|
19
|
-
i0.ɵɵelementStart(0, "div", 5)(1, "div",
|
|
20
|
-
i0.ɵɵelement(2, "i",
|
|
23
|
+
i0.ɵɵelementStart(0, "div", 5)(1, "div", 11);
|
|
24
|
+
i0.ɵɵelement(2, "i", 12);
|
|
21
25
|
i0.ɵɵelementEnd();
|
|
22
|
-
i0.ɵɵelementStart(3, "h3",
|
|
26
|
+
i0.ɵɵelementStart(3, "h3", 13);
|
|
23
27
|
i0.ɵɵtext(4, "No sections found");
|
|
24
28
|
i0.ɵɵelementEnd();
|
|
25
|
-
i0.ɵɵelementStart(5, "p",
|
|
29
|
+
i0.ɵɵelementStart(5, "p", 14);
|
|
26
30
|
i0.ɵɵtext(6, " No sections match \"");
|
|
27
31
|
i0.ɵɵelementStart(7, "strong");
|
|
28
32
|
i0.ɵɵtext(8);
|
|
@@ -30,7 +34,7 @@ function MjRecordFormContainerComponent_Conditional_7_Template(rf, ctx) { if (rf
|
|
|
30
34
|
i0.ɵɵtext(9, "\". ");
|
|
31
35
|
i0.ɵɵelement(10, "br");
|
|
32
36
|
i0.ɵɵtext(11, "Try a different search term or ");
|
|
33
|
-
i0.ɵɵelementStart(12, "a",
|
|
37
|
+
i0.ɵɵelementStart(12, "a", 15);
|
|
34
38
|
i0.ɵɵlistener("click", function MjRecordFormContainerComponent_Conditional_7_Template_a_click_12_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); ctx_r1.OnFilterChange(""); return i0.ɵɵresetView($event.preventDefault()); });
|
|
35
39
|
i0.ɵɵtext(13, "clear the search");
|
|
36
40
|
i0.ɵɵelementEnd();
|
|
@@ -43,17 +47,26 @@ function MjRecordFormContainerComponent_Conditional_7_Template(rf, ctx) { if (rf
|
|
|
43
47
|
} }
|
|
44
48
|
function MjRecordFormContainerComponent_Conditional_9_Template(rf, ctx) { if (rf & 1) {
|
|
45
49
|
const _r3 = i0.ɵɵgetCurrentView();
|
|
46
|
-
i0.ɵɵelementStart(0, "mj-record-changes",
|
|
47
|
-
i0.ɵɵlistener("dialogClosed", function MjRecordFormContainerComponent_Conditional_9_Template_mj_record_changes_dialogClosed_0_listener() { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnRecordChangesClosed()); });
|
|
50
|
+
i0.ɵɵelementStart(0, "mj-record-changes", 16);
|
|
51
|
+
i0.ɵɵlistener("RestoreRequested", function MjRecordFormContainerComponent_Conditional_9_Template_mj_record_changes_RestoreRequested_0_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnRestoreRequested($event)); })("dialogClosed", function MjRecordFormContainerComponent_Conditional_9_Template_mj_record_changes_dialogClosed_0_listener() { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnRecordChangesClosed()); });
|
|
48
52
|
i0.ɵɵelementEnd();
|
|
49
53
|
} if (rf & 2) {
|
|
50
54
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
51
|
-
i0.ɵɵproperty("record", ctx_r1.EffectiveRecord);
|
|
55
|
+
i0.ɵɵproperty("record", ctx_r1.EffectiveRecord)("AllowRestore", ctx_r1.EffectiveUserCanEdit);
|
|
52
56
|
} }
|
|
53
57
|
function MjRecordFormContainerComponent_Conditional_10_Template(rf, ctx) { if (rf & 1) {
|
|
54
58
|
const _r4 = i0.ɵɵgetCurrentView();
|
|
55
|
-
i0.ɵɵelementStart(0, "mj-
|
|
56
|
-
i0.ɵɵlistener("
|
|
59
|
+
i0.ɵɵelementStart(0, "mj-record-tags", 17);
|
|
60
|
+
i0.ɵɵlistener("PanelClosed", function MjRecordFormContainerComponent_Conditional_10_Template_mj_record_tags_PanelClosed_0_listener() { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnTagsPanelClosed()); })("TagCountChanged", function MjRecordFormContainerComponent_Conditional_10_Template_mj_record_tags_TagCountChanged_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnTagCountChanged($event)); })("RecordNavigate", function MjRecordFormContainerComponent_Conditional_10_Template_mj_record_tags_RecordNavigate_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnTagsRecordNavigate($event)); })("WidthChanged", function MjRecordFormContainerComponent_Conditional_10_Template_mj_record_tags_WidthChanged_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnTagsPanelWidthChanged($event)); });
|
|
61
|
+
i0.ɵɵelementEnd();
|
|
62
|
+
} if (rf & 2) {
|
|
63
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
64
|
+
i0.ɵɵproperty("Record", ctx_r1.EffectiveRecord)("WidthPx", ctx_r1.TagsPanelWidth);
|
|
65
|
+
} }
|
|
66
|
+
function MjRecordFormContainerComponent_Conditional_11_Template(rf, ctx) { if (rf & 1) {
|
|
67
|
+
const _r5 = i0.ɵɵgetCurrentView();
|
|
68
|
+
i0.ɵɵelementStart(0, "mj-list-management-dialog", 18);
|
|
69
|
+
i0.ɵɵlistener("complete", function MjRecordFormContainerComponent_Conditional_11_Template_mj_list_management_dialog_complete_0_listener() { i0.ɵɵrestoreView(_r5); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnListManagementClosed()); })("cancel", function MjRecordFormContainerComponent_Conditional_11_Template_mj_list_management_dialog_cancel_0_listener() { i0.ɵɵrestoreView(_r5); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnListManagementClosed()); });
|
|
57
70
|
i0.ɵɵelementEnd();
|
|
58
71
|
} if (rf & 2) {
|
|
59
72
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
@@ -92,11 +105,21 @@ function MjRecordFormContainerComponent_Conditional_10_Template(rf, ctx) { if (r
|
|
|
92
105
|
export class MjRecordFormContainerComponent {
|
|
93
106
|
cdr = inject(ChangeDetectorRef);
|
|
94
107
|
ngZone = inject(NgZone);
|
|
108
|
+
notificationService = inject(MJNotificationService);
|
|
95
109
|
destroy$ = new Subject();
|
|
96
110
|
panelNavReset$ = new Subject();
|
|
97
111
|
// ---- Internal State ----
|
|
98
112
|
/** Controls visibility of record changes drawer */
|
|
99
113
|
ShowRecordChanges = false;
|
|
114
|
+
/** Controls visibility of tags panel */
|
|
115
|
+
ShowTagsPanel = false;
|
|
116
|
+
/** Persisted tags panel width */
|
|
117
|
+
TagsPanelWidth = 0;
|
|
118
|
+
static TAGS_WIDTH_KEY = 'MJ_TagsPanel_Width';
|
|
119
|
+
/** Number of tags on this record */
|
|
120
|
+
TagCount = 0;
|
|
121
|
+
/** Number of tracked record change versions for this record */
|
|
122
|
+
VersionCount = 0;
|
|
100
123
|
/** Controls visibility of list management dialog */
|
|
101
124
|
ShowListManagement = false;
|
|
102
125
|
/** Controls visibility of section manager drawer */
|
|
@@ -282,6 +305,10 @@ export class MjRecordFormContainerComponent {
|
|
|
282
305
|
}
|
|
283
306
|
// ---- Lifecycle ----
|
|
284
307
|
ngAfterContentInit() {
|
|
308
|
+
// Load saved tags panel width
|
|
309
|
+
const savedWidth = UserInfoEngine.Instance.GetSetting(MjRecordFormContainerComponent.TAGS_WIDTH_KEY);
|
|
310
|
+
if (savedWidth)
|
|
311
|
+
this.TagsPanelWidth = parseInt(savedWidth, 10) || 0;
|
|
285
312
|
// Subscribe to panel Navigate events and relay them
|
|
286
313
|
this.SubscribeToPanelNavigateEvents();
|
|
287
314
|
// Watch for panel changes to update counts and re-subscribe
|
|
@@ -291,6 +318,7 @@ export class MjRecordFormContainerComponent {
|
|
|
291
318
|
});
|
|
292
319
|
// Watch for changes to record dirty state
|
|
293
320
|
this.watchRecordChanges();
|
|
321
|
+
// Badge counts are loaded when the form emits RecordReady (see SubscribeToPanelNavigateEvents)
|
|
294
322
|
}
|
|
295
323
|
ngOnDestroy() {
|
|
296
324
|
this.panelNavReset$.next();
|
|
@@ -304,6 +332,12 @@ export class MjRecordFormContainerComponent {
|
|
|
304
332
|
*/
|
|
305
333
|
SubscribeToPanelNavigateEvents() {
|
|
306
334
|
this.panelNavReset$.next(); // tear down previous subscriptions
|
|
335
|
+
// Subscribe to RecordReady on the form component — fires once after record is fully initialized
|
|
336
|
+
if (this.fc) {
|
|
337
|
+
this.fc.RecordReady.pipe(takeUntil(this.panelNavReset$)).subscribe(() => {
|
|
338
|
+
this.LoadBadgeCounts();
|
|
339
|
+
});
|
|
340
|
+
}
|
|
307
341
|
this.Panels.forEach(panel => {
|
|
308
342
|
panel.Navigate.pipe(takeUntil(this.panelNavReset$)).subscribe((event) => {
|
|
309
343
|
this.Navigate.emit(event);
|
|
@@ -324,6 +358,70 @@ export class MjRecordFormContainerComponent {
|
|
|
324
358
|
// Cleanup on destroy
|
|
325
359
|
this.destroy$.subscribe(() => clearInterval(checkInterval));
|
|
326
360
|
}
|
|
361
|
+
// ---- Badge Count Loading ----
|
|
362
|
+
/**
|
|
363
|
+
* Loads tag count and record change version count for toolbar badges.
|
|
364
|
+
* Both queries run in parallel for performance.
|
|
365
|
+
*/
|
|
366
|
+
badgeCountsLoaded = false;
|
|
367
|
+
LoadBadgeCounts() {
|
|
368
|
+
if (this.badgeCountsLoaded)
|
|
369
|
+
return;
|
|
370
|
+
const record = this.EffectiveRecord;
|
|
371
|
+
if (!record?.EntityInfo)
|
|
372
|
+
return;
|
|
373
|
+
this.badgeCountsLoaded = true;
|
|
374
|
+
// Fire both queries in parallel — no await needed, they update state async
|
|
375
|
+
this.LoadTagCount(record);
|
|
376
|
+
this.LoadVersionCount(record);
|
|
377
|
+
}
|
|
378
|
+
/**
|
|
379
|
+
* Queries the count of tagged items for the current entity + record
|
|
380
|
+
* and updates the TagCount badge on the toolbar.
|
|
381
|
+
*/
|
|
382
|
+
async LoadTagCount(record) {
|
|
383
|
+
try {
|
|
384
|
+
const rv = new RunView();
|
|
385
|
+
// Don't narrow Fields — the server caches RunView results by entity+filter (ignoring Fields),
|
|
386
|
+
// so a narrow query here would poison the cache for the subsequent full-field load in the Tags panel.
|
|
387
|
+
const result = await rv.RunView({
|
|
388
|
+
EntityName: 'MJ: Tagged Items',
|
|
389
|
+
ExtraFilter: `EntityID='${record.EntityInfo.ID}' AND RecordID='${record.PrimaryKey.Values()}'`,
|
|
390
|
+
ResultType: 'simple'
|
|
391
|
+
});
|
|
392
|
+
if (result.Success) {
|
|
393
|
+
this.TagCount = result.Results.length;
|
|
394
|
+
this.cdr.detectChanges();
|
|
395
|
+
}
|
|
396
|
+
}
|
|
397
|
+
catch {
|
|
398
|
+
// Non-critical — badge just stays at 0
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
/**
|
|
402
|
+
* Queries the count of record change entries for the current entity + record
|
|
403
|
+
* and updates the VersionCount badge on the toolbar.
|
|
404
|
+
*/
|
|
405
|
+
async LoadVersionCount(record) {
|
|
406
|
+
if (!record.EntityInfo.TrackRecordChanges)
|
|
407
|
+
return;
|
|
408
|
+
try {
|
|
409
|
+
const rv = new RunView();
|
|
410
|
+
const result = await rv.RunView({
|
|
411
|
+
EntityName: 'MJ: Record Changes',
|
|
412
|
+
Fields: ['ID'],
|
|
413
|
+
ExtraFilter: `EntityID='${record.EntityInfo.ID}' AND RecordID='${record.PrimaryKey.ToConcatenatedString()}'`,
|
|
414
|
+
ResultType: 'simple'
|
|
415
|
+
});
|
|
416
|
+
if (result.Success) {
|
|
417
|
+
this.VersionCount = result.Results.length;
|
|
418
|
+
this.cdr.detectChanges();
|
|
419
|
+
}
|
|
420
|
+
}
|
|
421
|
+
catch {
|
|
422
|
+
// Non-critical — badge just stays at 0
|
|
423
|
+
}
|
|
424
|
+
}
|
|
327
425
|
// ---- Toolbar Event Handlers ----
|
|
328
426
|
/**
|
|
329
427
|
* Navigation events are always re-emitted for the host app to handle.
|
|
@@ -417,9 +515,80 @@ export class MjRecordFormContainerComponent {
|
|
|
417
515
|
// Also emit for backward compatibility
|
|
418
516
|
this.ListManagementRequested.emit();
|
|
419
517
|
}
|
|
518
|
+
OnTagsPanelToggled() {
|
|
519
|
+
this.ShowTagsPanel = !this.ShowTagsPanel;
|
|
520
|
+
this.cdr.detectChanges();
|
|
521
|
+
}
|
|
522
|
+
OnTagsPanelClosed() {
|
|
523
|
+
this.ShowTagsPanel = false;
|
|
524
|
+
this.cdr.detectChanges();
|
|
525
|
+
// Refresh tag count — tags may have been added/removed while panel was open
|
|
526
|
+
const record = this.EffectiveRecord;
|
|
527
|
+
if (record?.EntityInfo) {
|
|
528
|
+
this.LoadTagCount(record);
|
|
529
|
+
}
|
|
530
|
+
}
|
|
531
|
+
/**
|
|
532
|
+
* Handles live tag count updates from the tags panel component.
|
|
533
|
+
*/
|
|
534
|
+
OnTagCountChanged(count) {
|
|
535
|
+
this.TagCount = count;
|
|
536
|
+
this.cdr.markForCheck();
|
|
537
|
+
}
|
|
538
|
+
OnTagsPanelWidthChanged(width) {
|
|
539
|
+
this.TagsPanelWidth = width;
|
|
540
|
+
UserInfoEngine.Instance.SetSettingDebounced(MjRecordFormContainerComponent.TAGS_WIDTH_KEY, String(width));
|
|
541
|
+
}
|
|
542
|
+
OnTagsRecordNavigate(event) {
|
|
543
|
+
const md = new Metadata();
|
|
544
|
+
const entityInfo = md.Entities.find(e => e.Name === event.EntityName);
|
|
545
|
+
const pkey = new CompositeKey();
|
|
546
|
+
if (entityInfo) {
|
|
547
|
+
pkey.LoadFromURLSegment(entityInfo, event.RecordID);
|
|
548
|
+
}
|
|
549
|
+
else {
|
|
550
|
+
pkey.KeyValuePairs = [{ FieldName: 'ID', Value: event.RecordID }];
|
|
551
|
+
}
|
|
552
|
+
this.Navigate.emit({ Kind: 'record', EntityName: event.EntityName, PrimaryKey: pkey });
|
|
553
|
+
}
|
|
420
554
|
OnRecordChangesClosed() {
|
|
421
555
|
this.ShowRecordChanges = false;
|
|
422
556
|
this.cdr.markForCheck();
|
|
557
|
+
// Refresh version count — new changes may have occurred
|
|
558
|
+
const record = this.EffectiveRecord;
|
|
559
|
+
if (record?.EntityInfo) {
|
|
560
|
+
this.LoadVersionCount(record);
|
|
561
|
+
}
|
|
562
|
+
}
|
|
563
|
+
/**
|
|
564
|
+
* Handles a restore request from the record-changes panel.
|
|
565
|
+
* Applies the old field values to the current record, saves, then refreshes version count.
|
|
566
|
+
*/
|
|
567
|
+
async OnRestoreRequested(event) {
|
|
568
|
+
const record = this.EffectiveRecord;
|
|
569
|
+
if (!record)
|
|
570
|
+
return;
|
|
571
|
+
try {
|
|
572
|
+
// Apply old values from the version to the current record
|
|
573
|
+
for (const [fieldName, values] of Object.entries(event.FieldChanges)) {
|
|
574
|
+
record.Set(fieldName, values.OldValue);
|
|
575
|
+
}
|
|
576
|
+
// Save the record — this creates a new Record Change entry automatically
|
|
577
|
+
const saved = await record.Save();
|
|
578
|
+
if (saved) {
|
|
579
|
+
this.notificationService.CreateSimpleNotification(`Restored ${Object.keys(event.FieldChanges).length} field(s) from version dated ${new Date(event.ChangedAt).toLocaleDateString()}`, 'info', 3000);
|
|
580
|
+
// Refresh version count since a new change was created by the save
|
|
581
|
+
this.LoadVersionCount(record);
|
|
582
|
+
this.cdr.markForCheck();
|
|
583
|
+
}
|
|
584
|
+
else {
|
|
585
|
+
this.notificationService.CreateSimpleNotification('Failed to save restored values. Please try again.', 'error', 4000);
|
|
586
|
+
}
|
|
587
|
+
}
|
|
588
|
+
catch (err) {
|
|
589
|
+
const message = err instanceof Error ? err.message : 'Unknown error';
|
|
590
|
+
this.notificationService.CreateSimpleNotification(`Restore failed: ${message}`, 'error', 4000);
|
|
591
|
+
}
|
|
423
592
|
}
|
|
424
593
|
OnListManagementClosed() {
|
|
425
594
|
this.ShowListManagement = false;
|
|
@@ -498,11 +667,11 @@ export class MjRecordFormContainerComponent {
|
|
|
498
667
|
} if (rf & 2) {
|
|
499
668
|
let _t;
|
|
500
669
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.Panels = _t);
|
|
501
|
-
} }, inputs: { Record: "Record", FormComponent: "FormComponent", EntityInfo: "EntityInfo", EditMode: "EditMode", UserCanEdit: "UserCanEdit", UserCanDelete: "UserCanDelete", IsFavorite: "IsFavorite", FavoriteInitDone: "FavoriteInitDone", IsDirty: "IsDirty", DirtyFieldNames: "DirtyFieldNames", ListCount: "ListCount", IsSaving: "IsSaving", ToolbarConfig: "ToolbarConfig", WidthMode: "WidthMode" }, outputs: { Navigate: "Navigate", EditModeChange: "EditModeChange", BeforeSave: "BeforeSave", SaveRequested: "SaveRequested", BeforeCancel: "BeforeCancel", CancelRequested: "CancelRequested", BeforeDelete: "BeforeDelete", DeleteRequested: "DeleteRequested", FavoriteToggled: "FavoriteToggled", BeforeHistoryView: "BeforeHistoryView", HistoryRequested: "HistoryRequested", BeforeListManagement: "BeforeListManagement", ListManagementRequested: "ListManagementRequested", ShowChangesRequested: "ShowChangesRequested", CustomButtonClick: "CustomButtonClick" }, standalone: false, ngContentSelectors: _c1, decls:
|
|
670
|
+
} }, inputs: { Record: "Record", FormComponent: "FormComponent", EntityInfo: "EntityInfo", EditMode: "EditMode", UserCanEdit: "UserCanEdit", UserCanDelete: "UserCanDelete", IsFavorite: "IsFavorite", FavoriteInitDone: "FavoriteInitDone", IsDirty: "IsDirty", DirtyFieldNames: "DirtyFieldNames", ListCount: "ListCount", IsSaving: "IsSaving", ToolbarConfig: "ToolbarConfig", WidthMode: "WidthMode" }, outputs: { Navigate: "Navigate", EditModeChange: "EditModeChange", BeforeSave: "BeforeSave", SaveRequested: "SaveRequested", BeforeCancel: "BeforeCancel", CancelRequested: "CancelRequested", BeforeDelete: "BeforeDelete", DeleteRequested: "DeleteRequested", FavoriteToggled: "FavoriteToggled", BeforeHistoryView: "BeforeHistoryView", HistoryRequested: "HistoryRequested", BeforeListManagement: "BeforeListManagement", ListManagementRequested: "ListManagementRequested", ShowChangesRequested: "ShowChangesRequested", CustomButtonClick: "CustomButtonClick" }, standalone: false, ngContentSelectors: _c1, decls: 13, vars: 37, consts: [[3, "Navigate", "EditModeChange", "BeforeSave", "SaveRequested", "BeforeCancel", "CancelRequested", "BeforeDelete", "DeleteRequested", "FavoriteToggled", "BeforeHistoryView", "HistoryRequested", "BeforeListManagement", "ListManagementRequested", "ShowChangesRequested", "CustomButtonClick", "FilterChange", "ExpandAllRequested", "CollapseAllRequested", "ShowEmptyFieldsChange", "WidthModeChange", "ResetSectionOrderRequested", "ManageSectionsRequested", "TagsPanelToggled", "Record", "EditMode", "UserCanEdit", "UserCanDelete", "IsFavorite", "FavoriteInitDone", "IsDirty", "DirtyFieldNames", "ListCount", "TagCount", "VersionCount", "EntityInfo", "Config", "IsSaving", "VisibleSectionCount", "TotalSectionCount", "ExpandedSectionCount", "SearchFilter", "ShowEmptyFields", "WidthMode", "HasCustomSectionOrder"], [1, "mj-forms-scroll-area"], [1, "mj-forms-panels-container"], [1, "mj-forms-layout-row"], [1, "mj-forms-all-panels"], [1, "mj-forms-empty-search-state"], [3, "Navigate", "Record", "EditMode", "Collapsed"], [3, "record", "AllowRestore"], [3, "Record", "WidthPx"], [3, "visible", "config"], [3, "SectionOrderChange", "ResetRequested", "Closed", "Sections", "SectionOrder", "Visible"], [1, "mj-forms-empty-search-icon"], [1, "fa-solid", "fa-magnifying-glass"], [1, "mj-forms-empty-search-title"], [1, "mj-forms-empty-search-message"], ["href", "#", 1, "mj-forms-empty-search-link", 3, "click"], [3, "RestoreRequested", "dialogClosed", "record", "AllowRestore"], [3, "PanelClosed", "TagCountChanged", "RecordNavigate", "WidthChanged", "Record", "WidthPx"], [3, "complete", "cancel", "visible", "config"]], template: function MjRecordFormContainerComponent_Template(rf, ctx) { if (rf & 1) {
|
|
502
671
|
i0.ɵɵprojectionDef(_c0);
|
|
503
672
|
i0.ɵɵprojection(0);
|
|
504
673
|
i0.ɵɵelementStart(1, "mj-form-toolbar", 0);
|
|
505
|
-
i0.ɵɵlistener("Navigate", function MjRecordFormContainerComponent_Template_mj_form_toolbar_Navigate_1_listener($event) { return ctx.OnNavigate($event); })("EditModeChange", function MjRecordFormContainerComponent_Template_mj_form_toolbar_EditModeChange_1_listener($event) { return ctx.OnEditModeChange($event); })("BeforeSave", function MjRecordFormContainerComponent_Template_mj_form_toolbar_BeforeSave_1_listener($event) { return ctx.BeforeSave.emit($event); })("SaveRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_SaveRequested_1_listener() { return ctx.OnSaveRequested(); })("BeforeCancel", function MjRecordFormContainerComponent_Template_mj_form_toolbar_BeforeCancel_1_listener($event) { return ctx.BeforeCancel.emit($event); })("CancelRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_CancelRequested_1_listener() { return ctx.OnCancelRequested(); })("BeforeDelete", function MjRecordFormContainerComponent_Template_mj_form_toolbar_BeforeDelete_1_listener($event) { return ctx.BeforeDelete.emit($event); })("DeleteRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_DeleteRequested_1_listener() { return ctx.OnDeleteRequested(); })("FavoriteToggled", function MjRecordFormContainerComponent_Template_mj_form_toolbar_FavoriteToggled_1_listener() { return ctx.OnFavoriteToggled(); })("BeforeHistoryView", function MjRecordFormContainerComponent_Template_mj_form_toolbar_BeforeHistoryView_1_listener($event) { return ctx.BeforeHistoryView.emit($event); })("HistoryRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_HistoryRequested_1_listener() { return ctx.OnHistoryRequested(); })("BeforeListManagement", function MjRecordFormContainerComponent_Template_mj_form_toolbar_BeforeListManagement_1_listener($event) { return ctx.BeforeListManagement.emit($event); })("ListManagementRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ListManagementRequested_1_listener() { return ctx.OnListManagementRequested(); })("ShowChangesRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ShowChangesRequested_1_listener() { return ctx.OnShowChangesRequested(); })("CustomButtonClick", function MjRecordFormContainerComponent_Template_mj_form_toolbar_CustomButtonClick_1_listener($event) { return ctx.CustomButtonClick.emit($event); })("FilterChange", function MjRecordFormContainerComponent_Template_mj_form_toolbar_FilterChange_1_listener($event) { return ctx.OnFilterChange($event); })("ExpandAllRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ExpandAllRequested_1_listener() { return ctx.OnExpandAll(); })("CollapseAllRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_CollapseAllRequested_1_listener() { return ctx.OnCollapseAll(); })("ShowEmptyFieldsChange", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ShowEmptyFieldsChange_1_listener($event) { return ctx.OnShowEmptyFieldsChange($event); })("WidthModeChange", function MjRecordFormContainerComponent_Template_mj_form_toolbar_WidthModeChange_1_listener($event) { return ctx.OnWidthModeChange($event); })("ResetSectionOrderRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ResetSectionOrderRequested_1_listener() { return ctx.OnResetSectionOrder(); })("ManageSectionsRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ManageSectionsRequested_1_listener() { return ctx.OnManageSections(); });
|
|
674
|
+
i0.ɵɵlistener("Navigate", function MjRecordFormContainerComponent_Template_mj_form_toolbar_Navigate_1_listener($event) { return ctx.OnNavigate($event); })("EditModeChange", function MjRecordFormContainerComponent_Template_mj_form_toolbar_EditModeChange_1_listener($event) { return ctx.OnEditModeChange($event); })("BeforeSave", function MjRecordFormContainerComponent_Template_mj_form_toolbar_BeforeSave_1_listener($event) { return ctx.BeforeSave.emit($event); })("SaveRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_SaveRequested_1_listener() { return ctx.OnSaveRequested(); })("BeforeCancel", function MjRecordFormContainerComponent_Template_mj_form_toolbar_BeforeCancel_1_listener($event) { return ctx.BeforeCancel.emit($event); })("CancelRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_CancelRequested_1_listener() { return ctx.OnCancelRequested(); })("BeforeDelete", function MjRecordFormContainerComponent_Template_mj_form_toolbar_BeforeDelete_1_listener($event) { return ctx.BeforeDelete.emit($event); })("DeleteRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_DeleteRequested_1_listener() { return ctx.OnDeleteRequested(); })("FavoriteToggled", function MjRecordFormContainerComponent_Template_mj_form_toolbar_FavoriteToggled_1_listener() { return ctx.OnFavoriteToggled(); })("BeforeHistoryView", function MjRecordFormContainerComponent_Template_mj_form_toolbar_BeforeHistoryView_1_listener($event) { return ctx.BeforeHistoryView.emit($event); })("HistoryRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_HistoryRequested_1_listener() { return ctx.OnHistoryRequested(); })("BeforeListManagement", function MjRecordFormContainerComponent_Template_mj_form_toolbar_BeforeListManagement_1_listener($event) { return ctx.BeforeListManagement.emit($event); })("ListManagementRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ListManagementRequested_1_listener() { return ctx.OnListManagementRequested(); })("ShowChangesRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ShowChangesRequested_1_listener() { return ctx.OnShowChangesRequested(); })("CustomButtonClick", function MjRecordFormContainerComponent_Template_mj_form_toolbar_CustomButtonClick_1_listener($event) { return ctx.CustomButtonClick.emit($event); })("FilterChange", function MjRecordFormContainerComponent_Template_mj_form_toolbar_FilterChange_1_listener($event) { return ctx.OnFilterChange($event); })("ExpandAllRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ExpandAllRequested_1_listener() { return ctx.OnExpandAll(); })("CollapseAllRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_CollapseAllRequested_1_listener() { return ctx.OnCollapseAll(); })("ShowEmptyFieldsChange", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ShowEmptyFieldsChange_1_listener($event) { return ctx.OnShowEmptyFieldsChange($event); })("WidthModeChange", function MjRecordFormContainerComponent_Template_mj_form_toolbar_WidthModeChange_1_listener($event) { return ctx.OnWidthModeChange($event); })("ResetSectionOrderRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ResetSectionOrderRequested_1_listener() { return ctx.OnResetSectionOrder(); })("ManageSectionsRequested", function MjRecordFormContainerComponent_Template_mj_form_toolbar_ManageSectionsRequested_1_listener() { return ctx.OnManageSections(); })("TagsPanelToggled", function MjRecordFormContainerComponent_Template_mj_form_toolbar_TagsPanelToggled_1_listener() { return ctx.OnTagsPanelToggled(); });
|
|
506
675
|
i0.ɵɵelementEnd();
|
|
507
676
|
i0.ɵɵelementStart(2, "div", 1)(3, "div", 2)(4, "div", 3)(5, "div", 4);
|
|
508
677
|
i0.ɵɵprojection(6, 1);
|
|
@@ -511,14 +680,15 @@ export class MjRecordFormContainerComponent {
|
|
|
511
680
|
i0.ɵɵelementStart(8, "mj-isa-related-panel", 6);
|
|
512
681
|
i0.ɵɵlistener("Navigate", function MjRecordFormContainerComponent_Template_mj_isa_related_panel_Navigate_8_listener($event) { return ctx.OnNavigate($event); });
|
|
513
682
|
i0.ɵɵelementEnd()()()();
|
|
514
|
-
i0.ɵɵconditionalCreate(9, MjRecordFormContainerComponent_Conditional_9_Template, 1,
|
|
515
|
-
i0.ɵɵconditionalCreate(10, MjRecordFormContainerComponent_Conditional_10_Template, 1,
|
|
516
|
-
i0.ɵɵ
|
|
517
|
-
i0.ɵɵ
|
|
683
|
+
i0.ɵɵconditionalCreate(9, MjRecordFormContainerComponent_Conditional_9_Template, 1, 2, "mj-record-changes", 7);
|
|
684
|
+
i0.ɵɵconditionalCreate(10, MjRecordFormContainerComponent_Conditional_10_Template, 1, 2, "mj-record-tags", 8);
|
|
685
|
+
i0.ɵɵconditionalCreate(11, MjRecordFormContainerComponent_Conditional_11_Template, 1, 8, "mj-list-management-dialog", 9);
|
|
686
|
+
i0.ɵɵelementStart(12, "mj-section-manager", 10);
|
|
687
|
+
i0.ɵɵlistener("SectionOrderChange", function MjRecordFormContainerComponent_Template_mj_section_manager_SectionOrderChange_12_listener($event) { return ctx.OnSectionOrderChange($event); })("ResetRequested", function MjRecordFormContainerComponent_Template_mj_section_manager_ResetRequested_12_listener() { return ctx.OnSectionManagerReset(); })("Closed", function MjRecordFormContainerComponent_Template_mj_section_manager_Closed_12_listener() { return ctx.OnSectionManagerClosed(); });
|
|
518
688
|
i0.ɵɵelementEnd();
|
|
519
689
|
} if (rf & 2) {
|
|
520
690
|
i0.ɵɵadvance();
|
|
521
|
-
i0.ɵɵproperty("Record", ctx.EffectiveRecord)("EditMode", ctx.EffectiveEditMode)("UserCanEdit", ctx.EffectiveUserCanEdit)("UserCanDelete", ctx.EffectiveUserCanDelete)("IsFavorite", ctx.EffectiveIsFavorite)("FavoriteInitDone", ctx.EffectiveFavoriteInitDone)("IsDirty", ctx.EffectiveIsDirty)("DirtyFieldNames", ctx.EffectiveDirtyFieldNames)("ListCount", ctx.ListCount)("EntityInfo", ctx.EffectiveEntityInfo)("Config", ctx.ToolbarConfig)("IsSaving", ctx.EffectiveIsSaving)("VisibleSectionCount", ctx.VisibleSectionCount)("TotalSectionCount", ctx.TotalSectionCount)("ExpandedSectionCount", ctx.ExpandedSectionCount)("SearchFilter", ctx.EffectiveSearchFilter)("ShowEmptyFields", ctx.EffectiveShowEmptyFields)("WidthMode", ctx.EffectiveWidthMode)("HasCustomSectionOrder", ctx.EffectiveHasCustomSectionOrder);
|
|
691
|
+
i0.ɵɵproperty("Record", ctx.EffectiveRecord)("EditMode", ctx.EffectiveEditMode)("UserCanEdit", ctx.EffectiveUserCanEdit)("UserCanDelete", ctx.EffectiveUserCanDelete)("IsFavorite", ctx.EffectiveIsFavorite)("FavoriteInitDone", ctx.EffectiveFavoriteInitDone)("IsDirty", ctx.EffectiveIsDirty)("DirtyFieldNames", ctx.EffectiveDirtyFieldNames)("ListCount", ctx.ListCount)("TagCount", ctx.TagCount)("VersionCount", ctx.VersionCount)("EntityInfo", ctx.EffectiveEntityInfo)("Config", ctx.ToolbarConfig)("IsSaving", ctx.EffectiveIsSaving)("VisibleSectionCount", ctx.VisibleSectionCount)("TotalSectionCount", ctx.TotalSectionCount)("ExpandedSectionCount", ctx.ExpandedSectionCount)("SearchFilter", ctx.EffectiveSearchFilter)("ShowEmptyFields", ctx.EffectiveShowEmptyFields)("WidthMode", ctx.EffectiveWidthMode)("HasCustomSectionOrder", ctx.EffectiveHasCustomSectionOrder);
|
|
522
692
|
i0.ɵɵadvance(2);
|
|
523
693
|
i0.ɵɵclassProp("mj-forms-panels--full-width", ctx.EffectiveWidthMode === "full-width")("mj-forms-panels--edit-mode", ctx.EffectiveEditMode)("mj-forms-panels--has-isa-panel", ctx.HasIsaRelatedItems);
|
|
524
694
|
i0.ɵɵadvance(4);
|
|
@@ -528,14 +698,16 @@ export class MjRecordFormContainerComponent {
|
|
|
528
698
|
i0.ɵɵadvance();
|
|
529
699
|
i0.ɵɵconditional(ctx.ShowRecordChanges && ctx.EffectiveRecord ? 9 : -1);
|
|
530
700
|
i0.ɵɵadvance();
|
|
531
|
-
i0.ɵɵconditional(ctx.
|
|
701
|
+
i0.ɵɵconditional(ctx.ShowTagsPanel && ctx.EffectiveRecord ? 10 : -1);
|
|
702
|
+
i0.ɵɵadvance();
|
|
703
|
+
i0.ɵɵconditional(ctx.ShowListManagement && ctx.EffectiveRecord ? 11 : -1);
|
|
532
704
|
i0.ɵɵadvance();
|
|
533
705
|
i0.ɵɵproperty("Sections", ctx.SectionManagerItems)("SectionOrder", ctx.SectionManagerOrder)("Visible", ctx.ShowSectionManager);
|
|
534
|
-
} }, dependencies: [i1.RecordChangesComponent, i2.ListManagementDialogComponent, i3.
|
|
706
|
+
} }, dependencies: [i1.RecordChangesComponent, i2.ListManagementDialogComponent, i3.RecordTagsComponent, i4.MjFormToolbarComponent, i5.MjSectionManagerComponent, i6.MjIsaRelatedPanelComponent], styles: ["/* ============================================\n RECORD FORM CONTAINER \u2014 uses global --mj-* design tokens\n Top-level wrapper: toolbar + scrollable content\n ============================================ */\nmj-record-form-container {\n display: flex;\n flex-direction: column;\n height: 100%;\n min-height: 0;\n position: relative;\n overflow: hidden;\n}\n\n/* ViewEncapsulation.None fallback \u2014 ensure the element itself constrains overflow */\nmj-record-form-container {\n display: flex;\n flex-direction: column;\n height: 100%;\n min-height: 0;\n position: relative;\n overflow: hidden;\n}\n\n/* ============================================\n SCROLL AREA (full-width so mouse wheel works anywhere)\n ============================================ */\n.mj-forms-scroll-area {\n flex: 1;\n overflow-y: auto;\n overflow-x: hidden;\n background: var(--mj-bg-page);\n}\n\n/* ============================================\n PANELS CONTAINER (centered content within scroll area)\n ============================================ */\n.mj-forms-panels-container {\n padding: 24px 32px 48px;\n max-width: 920px;\n margin: 0 auto;\n width: 100%;\n box-sizing: border-box;\n}\n\n/* Widen max-width when ISA side panel is present */\n.mj-forms-panels--has-isa-panel {\n max-width: 1240px;\n}\n\n.mj-forms-panels--full-width {\n max-width: none;\n padding-left: 24px;\n padding-right: 24px;\n}\n\n/* Flex row layout: form panels + optional ISA side panel */\n.mj-forms-layout-row {\n display: flex;\n gap: 20px;\n align-items: flex-start;\n}\n\n/* All panels in a single flex container \u2014 CSS order drives sequencing */\n.mj-forms-all-panels {\n display: flex;\n flex-direction: column;\n gap: 16px;\n flex: 1;\n min-width: 0;\n}\n\n/* Hide related entity panels in edit mode (variant host class on mj-collapsible-panel) */\n.mj-forms-panels--edit-mode .mj-panel--related-entity {\n display: none;\n}\n\n/* ============================================\n EMPTY SEARCH STATE\n ============================================ */\n.mj-forms-empty-search-state {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n padding: 80px 24px;\n text-align: center;\n min-height: 400px;\n}\n\n.mj-forms-empty-search-icon {\n width: 80px;\n height: 80px;\n border-radius: var(--mj-radius-full);\n background: var(--mj-bg-surface-sunken);\n display: flex;\n align-items: center;\n justify-content: center;\n margin-bottom: 24px;\n}\n\n.mj-forms-empty-search-icon i {\n font-size: 32px;\n color: var(--mj-text-muted);\n}\n\n.mj-forms-empty-search-title {\n font-size: var(--mj-text-xl);\n font-weight: var(--mj-font-semibold);\n color: var(--mj-text-primary);\n margin: 0 0 12px 0;\n}\n\n.mj-forms-empty-search-message {\n font-size: var(--mj-text-sm);\n color: var(--mj-text-secondary);\n line-height: 1.6;\n max-width: 400px;\n margin: 0;\n}\n\n.mj-forms-empty-search-message strong {\n color: var(--mj-text-primary);\n font-weight: var(--mj-font-semibold);\n}\n\n.mj-forms-empty-search-link {\n color: var(--mj-brand-primary);\n text-decoration: none;\n font-weight: var(--mj-font-medium);\n}\n\n.mj-forms-empty-search-link:hover {\n text-decoration: underline;\n}\n\n/* ============================================\n RESPONSIVE\n ============================================ */\n@media (max-width: 768px) {\n .mj-forms-panels-container {\n padding: 16px 12px 32px;\n }\n}\n"], encapsulation: 2, changeDetection: 0 });
|
|
535
707
|
}
|
|
536
708
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(MjRecordFormContainerComponent, [{
|
|
537
709
|
type: Component,
|
|
538
|
-
args: [{ standalone: false, selector: 'mj-record-form-container', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<!-- ============================================\n BEFORE-TOOLBAR SLOT\n ============================================ -->\n<ng-content select=\"[before-toolbar]\"></ng-content>\n\n<!-- ============================================\n TOOLBAR (bridges FormComponent state \u2192 toolbar inputs)\n ============================================ -->\n<mj-form-toolbar\n [Record]=\"EffectiveRecord\"\n [EditMode]=\"EffectiveEditMode\"\n [UserCanEdit]=\"EffectiveUserCanEdit\"\n [UserCanDelete]=\"EffectiveUserCanDelete\"\n [IsFavorite]=\"EffectiveIsFavorite\"\n [FavoriteInitDone]=\"EffectiveFavoriteInitDone\"\n [IsDirty]=\"EffectiveIsDirty\"\n [DirtyFieldNames]=\"EffectiveDirtyFieldNames\"\n [ListCount]=\"ListCount\"\n [EntityInfo]=\"EffectiveEntityInfo\"\n [Config]=\"ToolbarConfig\"\n [IsSaving]=\"EffectiveIsSaving\"\n [VisibleSectionCount]=\"VisibleSectionCount\"\n [TotalSectionCount]=\"TotalSectionCount\"\n [ExpandedSectionCount]=\"ExpandedSectionCount\"\n [SearchFilter]=\"EffectiveSearchFilter\"\n [ShowEmptyFields]=\"EffectiveShowEmptyFields\"\n [WidthMode]=\"EffectiveWidthMode\"\n [HasCustomSectionOrder]=\"EffectiveHasCustomSectionOrder\"\n (Navigate)=\"OnNavigate($event)\"\n (EditModeChange)=\"OnEditModeChange($event)\"\n (BeforeSave)=\"BeforeSave.emit($event)\"\n (SaveRequested)=\"OnSaveRequested()\"\n (BeforeCancel)=\"BeforeCancel.emit($event)\"\n (CancelRequested)=\"OnCancelRequested()\"\n (BeforeDelete)=\"BeforeDelete.emit($event)\"\n (DeleteRequested)=\"OnDeleteRequested()\"\n (FavoriteToggled)=\"OnFavoriteToggled()\"\n (BeforeHistoryView)=\"BeforeHistoryView.emit($event)\"\n (HistoryRequested)=\"OnHistoryRequested()\"\n (BeforeListManagement)=\"BeforeListManagement.emit($event)\"\n (ListManagementRequested)=\"OnListManagementRequested()\"\n (ShowChangesRequested)=\"OnShowChangesRequested()\"\n (CustomButtonClick)=\"CustomButtonClick.emit($event)\"\n (FilterChange)=\"OnFilterChange($event)\"\n (ExpandAllRequested)=\"OnExpandAll()\"\n (CollapseAllRequested)=\"OnCollapseAll()\"\n (ShowEmptyFieldsChange)=\"OnShowEmptyFieldsChange($event)\"\n (WidthModeChange)=\"OnWidthModeChange($event)\"\n (ResetSectionOrderRequested)=\"OnResetSectionOrder()\"\n (ManageSectionsRequested)=\"OnManageSections()\">\n</mj-form-toolbar>\n\n<!-- ============================================\n SCROLL AREA (full-width so mouse wheel works anywhere)\n ============================================ -->\n<div class=\"mj-forms-scroll-area\">\n <div class=\"mj-forms-panels-container\"\n [class.mj-forms-panels--full-width]=\"EffectiveWidthMode === 'full-width'\"\n [class.mj-forms-panels--edit-mode]=\"EffectiveEditMode\"\n [class.mj-forms-panels--has-isa-panel]=\"HasIsaRelatedItems\">\n <!-- Flex row: form panels on left, ISA side panel on right -->\n <div class=\"mj-forms-layout-row\">\n <!-- All panels in a single flex container \u2014 CSS order drives sequencing -->\n <div class=\"mj-forms-all-panels\">\n <ng-content></ng-content>\n\n <!-- Empty state when no sections match search -->\n @if (EffectiveSearchFilter && VisibleSectionCount === 0) {\n <div class=\"mj-forms-empty-search-state\">\n <div class=\"mj-forms-empty-search-icon\">\n <i class=\"fa-solid fa-magnifying-glass\"></i>\n </div>\n <h3 class=\"mj-forms-empty-search-title\">No sections found</h3>\n <p class=\"mj-forms-empty-search-message\">\n No sections match \"<strong>{{ EffectiveSearchFilter }}</strong>\".\n <br>Try a different search term or <a href=\"#\" (click)=\"OnFilterChange(''); $event.preventDefault()\" class=\"mj-forms-empty-search-link\">clear the search</a>.\n </p>\n </div>\n }\n </div>\n\n <!-- IS-A Related Records Side Panel -->\n <mj-isa-related-panel\n [Record]=\"EffectiveRecord\"\n [EditMode]=\"EffectiveEditMode\"\n [Collapsed]=\"EffectiveWidthMode === 'full-width'\"\n (Navigate)=\"OnNavigate($event)\">\n </mj-isa-related-panel>\n </div>\n </div>\n</div>\n\n<!-- ============================================\n RECORD CHANGES DRAWER (shown when history button clicked)\n ============================================ -->\n@if (ShowRecordChanges && EffectiveRecord) {\n <mj-record-changes\n [record]=\"EffectiveRecord\"\n (dialogClosed)=\"OnRecordChangesClosed()\">\n </mj-record-changes>\n}\n\n<!-- ============================================\n LIST MANAGEMENT DIALOG (shown when lists button clicked)\n ============================================ -->\n@if (ShowListManagement && EffectiveRecord) {\n <mj-list-management-dialog\n [visible]=\"ShowListManagement\"\n [config]=\"{\n mode: 'manage',\n entityId: EffectiveRecord.EntityInfo.ID,\n entityName: EffectiveRecord.EntityInfo.Name,\n recordIds: [EffectiveRecord.PrimaryKey.Values()[0]],\n allowCreate: true\n }\"\n (complete)=\"OnListManagementClosed()\"\n (cancel)=\"OnListManagementClosed()\">\n </mj-list-management-dialog>\n}\n\n<!-- ============================================\n SECTION MANAGER DRAWER (shown when manage-sections button clicked)\n ============================================ -->\n<mj-section-manager\n [Sections]=\"SectionManagerItems\"\n [SectionOrder]=\"SectionManagerOrder\"\n [Visible]=\"ShowSectionManager\"\n (SectionOrderChange)=\"OnSectionOrderChange($event)\"\n (ResetRequested)=\"OnSectionManagerReset()\"\n (Closed)=\"OnSectionManagerClosed()\">\n</mj-section-manager>\n", styles: ["/* ============================================\n RECORD FORM CONTAINER \u2014 uses global --mj-* design tokens\n Top-level wrapper: toolbar + scrollable content\n ============================================ */\nmj-record-form-container {\n display: flex;\n flex-direction: column;\n height: 100%;\n min-height: 0;\n position: relative;\n overflow: hidden;\n}\n\n/* ViewEncapsulation.None fallback \u2014 ensure the element itself constrains overflow */\nmj-record-form-container {\n display: flex;\n flex-direction: column;\n height: 100%;\n min-height: 0;\n position: relative;\n overflow: hidden;\n}\n\n/* ============================================\n SCROLL AREA (full-width so mouse wheel works anywhere)\n ============================================ */\n.mj-forms-scroll-area {\n flex: 1;\n overflow-y: auto;\n overflow-x: hidden;\n background: var(--mj-bg-page);\n}\n\n/* ============================================\n PANELS CONTAINER (centered content within scroll area)\n ============================================ */\n.mj-forms-panels-container {\n padding: 24px 32px 48px;\n max-width: 920px;\n margin: 0 auto;\n width: 100%;\n box-sizing: border-box;\n}\n\n/* Widen max-width when ISA side panel is present */\n.mj-forms-panels--has-isa-panel {\n max-width: 1240px;\n}\n\n.mj-forms-panels--full-width {\n max-width: none;\n padding-left: 24px;\n padding-right: 24px;\n}\n\n/* Flex row layout: form panels + optional ISA side panel */\n.mj-forms-layout-row {\n display: flex;\n gap: 20px;\n align-items: flex-start;\n}\n\n/* All panels in a single flex container \u2014 CSS order drives sequencing */\n.mj-forms-all-panels {\n display: flex;\n flex-direction: column;\n gap: 16px;\n flex: 1;\n min-width: 0;\n}\n\n/* Hide related entity panels in edit mode (variant host class on mj-collapsible-panel) */\n.mj-forms-panels--edit-mode .mj-panel--related-entity {\n display: none;\n}\n\n/* ============================================\n EMPTY SEARCH STATE\n ============================================ */\n.mj-forms-empty-search-state {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n padding: 80px 24px;\n text-align: center;\n min-height: 400px;\n}\n\n.mj-forms-empty-search-icon {\n width: 80px;\n height: 80px;\n border-radius: var(--mj-radius-full);\n background: var(--mj-bg-surface-sunken);\n display: flex;\n align-items: center;\n justify-content: center;\n margin-bottom: 24px;\n}\n\n.mj-forms-empty-search-icon i {\n font-size: 32px;\n color: var(--mj-text-muted);\n}\n\n.mj-forms-empty-search-title {\n font-size: var(--mj-text-xl);\n font-weight: var(--mj-font-semibold);\n color: var(--mj-text-primary);\n margin: 0 0 12px 0;\n}\n\n.mj-forms-empty-search-message {\n font-size: var(--mj-text-sm);\n color: var(--mj-text-secondary);\n line-height: 1.6;\n max-width: 400px;\n margin: 0;\n}\n\n.mj-forms-empty-search-message strong {\n color: var(--mj-text-primary);\n font-weight: var(--mj-font-semibold);\n}\n\n.mj-forms-empty-search-link {\n color: var(--mj-brand-primary);\n text-decoration: none;\n font-weight: var(--mj-font-medium);\n}\n\n.mj-forms-empty-search-link:hover {\n text-decoration: underline;\n}\n\n/* ============================================\n RESPONSIVE\n ============================================ */\n@media (max-width: 768px) {\n .mj-forms-panels-container {\n padding: 16px 12px 32px;\n }\n}\n"] }]
|
|
710
|
+
args: [{ standalone: false, selector: 'mj-record-form-container', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<!-- ============================================\n BEFORE-TOOLBAR SLOT\n ============================================ -->\n<ng-content select=\"[before-toolbar]\"></ng-content>\n\n<!-- ============================================\n TOOLBAR (bridges FormComponent state \u2192 toolbar inputs)\n ============================================ -->\n<mj-form-toolbar\n [Record]=\"EffectiveRecord\"\n [EditMode]=\"EffectiveEditMode\"\n [UserCanEdit]=\"EffectiveUserCanEdit\"\n [UserCanDelete]=\"EffectiveUserCanDelete\"\n [IsFavorite]=\"EffectiveIsFavorite\"\n [FavoriteInitDone]=\"EffectiveFavoriteInitDone\"\n [IsDirty]=\"EffectiveIsDirty\"\n [DirtyFieldNames]=\"EffectiveDirtyFieldNames\"\n [ListCount]=\"ListCount\"\n [TagCount]=\"TagCount\"\n [VersionCount]=\"VersionCount\"\n [EntityInfo]=\"EffectiveEntityInfo\"\n [Config]=\"ToolbarConfig\"\n [IsSaving]=\"EffectiveIsSaving\"\n [VisibleSectionCount]=\"VisibleSectionCount\"\n [TotalSectionCount]=\"TotalSectionCount\"\n [ExpandedSectionCount]=\"ExpandedSectionCount\"\n [SearchFilter]=\"EffectiveSearchFilter\"\n [ShowEmptyFields]=\"EffectiveShowEmptyFields\"\n [WidthMode]=\"EffectiveWidthMode\"\n [HasCustomSectionOrder]=\"EffectiveHasCustomSectionOrder\"\n (Navigate)=\"OnNavigate($event)\"\n (EditModeChange)=\"OnEditModeChange($event)\"\n (BeforeSave)=\"BeforeSave.emit($event)\"\n (SaveRequested)=\"OnSaveRequested()\"\n (BeforeCancel)=\"BeforeCancel.emit($event)\"\n (CancelRequested)=\"OnCancelRequested()\"\n (BeforeDelete)=\"BeforeDelete.emit($event)\"\n (DeleteRequested)=\"OnDeleteRequested()\"\n (FavoriteToggled)=\"OnFavoriteToggled()\"\n (BeforeHistoryView)=\"BeforeHistoryView.emit($event)\"\n (HistoryRequested)=\"OnHistoryRequested()\"\n (BeforeListManagement)=\"BeforeListManagement.emit($event)\"\n (ListManagementRequested)=\"OnListManagementRequested()\"\n (ShowChangesRequested)=\"OnShowChangesRequested()\"\n (CustomButtonClick)=\"CustomButtonClick.emit($event)\"\n (FilterChange)=\"OnFilterChange($event)\"\n (ExpandAllRequested)=\"OnExpandAll()\"\n (CollapseAllRequested)=\"OnCollapseAll()\"\n (ShowEmptyFieldsChange)=\"OnShowEmptyFieldsChange($event)\"\n (WidthModeChange)=\"OnWidthModeChange($event)\"\n (ResetSectionOrderRequested)=\"OnResetSectionOrder()\"\n (ManageSectionsRequested)=\"OnManageSections()\"\n (TagsPanelToggled)=\"OnTagsPanelToggled()\">\n</mj-form-toolbar>\n\n<!-- ============================================\n SCROLL AREA (full-width so mouse wheel works anywhere)\n ============================================ -->\n<div class=\"mj-forms-scroll-area\">\n <div class=\"mj-forms-panels-container\"\n [class.mj-forms-panels--full-width]=\"EffectiveWidthMode === 'full-width'\"\n [class.mj-forms-panels--edit-mode]=\"EffectiveEditMode\"\n [class.mj-forms-panels--has-isa-panel]=\"HasIsaRelatedItems\">\n <!-- Flex row: form panels on left, ISA side panel on right -->\n <div class=\"mj-forms-layout-row\">\n <!-- All panels in a single flex container \u2014 CSS order drives sequencing -->\n <div class=\"mj-forms-all-panels\">\n <ng-content></ng-content>\n\n <!-- Empty state when no sections match search -->\n @if (EffectiveSearchFilter && VisibleSectionCount === 0) {\n <div class=\"mj-forms-empty-search-state\">\n <div class=\"mj-forms-empty-search-icon\">\n <i class=\"fa-solid fa-magnifying-glass\"></i>\n </div>\n <h3 class=\"mj-forms-empty-search-title\">No sections found</h3>\n <p class=\"mj-forms-empty-search-message\">\n No sections match \"<strong>{{ EffectiveSearchFilter }}</strong>\".\n <br>Try a different search term or <a href=\"#\" (click)=\"OnFilterChange(''); $event.preventDefault()\" class=\"mj-forms-empty-search-link\">clear the search</a>.\n </p>\n </div>\n }\n </div>\n\n <!-- IS-A Related Records Side Panel -->\n <mj-isa-related-panel\n [Record]=\"EffectiveRecord\"\n [EditMode]=\"EffectiveEditMode\"\n [Collapsed]=\"EffectiveWidthMode === 'full-width'\"\n (Navigate)=\"OnNavigate($event)\">\n </mj-isa-related-panel>\n </div>\n </div>\n</div>\n\n<!-- ============================================\n RECORD CHANGES DRAWER (shown when history button clicked)\n ============================================ -->\n@if (ShowRecordChanges && EffectiveRecord) {\n <mj-record-changes\n [record]=\"EffectiveRecord\"\n [AllowRestore]=\"EffectiveUserCanEdit\"\n (RestoreRequested)=\"OnRestoreRequested($event)\"\n (dialogClosed)=\"OnRecordChangesClosed()\">\n </mj-record-changes>\n}\n\n<!-- ============================================\n TAGS PANEL (shown when tags button clicked)\n ============================================ -->\n@if (ShowTagsPanel && EffectiveRecord) {\n <mj-record-tags\n [Record]=\"EffectiveRecord\"\n [WidthPx]=\"TagsPanelWidth\"\n (PanelClosed)=\"OnTagsPanelClosed()\"\n (TagCountChanged)=\"OnTagCountChanged($event)\"\n (RecordNavigate)=\"OnTagsRecordNavigate($event)\"\n (WidthChanged)=\"OnTagsPanelWidthChanged($event)\">\n </mj-record-tags>\n}\n\n<!-- ============================================\n LIST MANAGEMENT DIALOG (shown when lists button clicked)\n ============================================ -->\n@if (ShowListManagement && EffectiveRecord) {\n <mj-list-management-dialog\n [visible]=\"ShowListManagement\"\n [config]=\"{\n mode: 'manage',\n entityId: EffectiveRecord.EntityInfo.ID,\n entityName: EffectiveRecord.EntityInfo.Name,\n recordIds: [EffectiveRecord.PrimaryKey.Values()[0]],\n allowCreate: true\n }\"\n (complete)=\"OnListManagementClosed()\"\n (cancel)=\"OnListManagementClosed()\">\n </mj-list-management-dialog>\n}\n\n<!-- ============================================\n SECTION MANAGER DRAWER (shown when manage-sections button clicked)\n ============================================ -->\n<mj-section-manager\n [Sections]=\"SectionManagerItems\"\n [SectionOrder]=\"SectionManagerOrder\"\n [Visible]=\"ShowSectionManager\"\n (SectionOrderChange)=\"OnSectionOrderChange($event)\"\n (ResetRequested)=\"OnSectionManagerReset()\"\n (Closed)=\"OnSectionManagerClosed()\">\n</mj-section-manager>\n", styles: ["/* ============================================\n RECORD FORM CONTAINER \u2014 uses global --mj-* design tokens\n Top-level wrapper: toolbar + scrollable content\n ============================================ */\nmj-record-form-container {\n display: flex;\n flex-direction: column;\n height: 100%;\n min-height: 0;\n position: relative;\n overflow: hidden;\n}\n\n/* ViewEncapsulation.None fallback \u2014 ensure the element itself constrains overflow */\nmj-record-form-container {\n display: flex;\n flex-direction: column;\n height: 100%;\n min-height: 0;\n position: relative;\n overflow: hidden;\n}\n\n/* ============================================\n SCROLL AREA (full-width so mouse wheel works anywhere)\n ============================================ */\n.mj-forms-scroll-area {\n flex: 1;\n overflow-y: auto;\n overflow-x: hidden;\n background: var(--mj-bg-page);\n}\n\n/* ============================================\n PANELS CONTAINER (centered content within scroll area)\n ============================================ */\n.mj-forms-panels-container {\n padding: 24px 32px 48px;\n max-width: 920px;\n margin: 0 auto;\n width: 100%;\n box-sizing: border-box;\n}\n\n/* Widen max-width when ISA side panel is present */\n.mj-forms-panels--has-isa-panel {\n max-width: 1240px;\n}\n\n.mj-forms-panels--full-width {\n max-width: none;\n padding-left: 24px;\n padding-right: 24px;\n}\n\n/* Flex row layout: form panels + optional ISA side panel */\n.mj-forms-layout-row {\n display: flex;\n gap: 20px;\n align-items: flex-start;\n}\n\n/* All panels in a single flex container \u2014 CSS order drives sequencing */\n.mj-forms-all-panels {\n display: flex;\n flex-direction: column;\n gap: 16px;\n flex: 1;\n min-width: 0;\n}\n\n/* Hide related entity panels in edit mode (variant host class on mj-collapsible-panel) */\n.mj-forms-panels--edit-mode .mj-panel--related-entity {\n display: none;\n}\n\n/* ============================================\n EMPTY SEARCH STATE\n ============================================ */\n.mj-forms-empty-search-state {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n padding: 80px 24px;\n text-align: center;\n min-height: 400px;\n}\n\n.mj-forms-empty-search-icon {\n width: 80px;\n height: 80px;\n border-radius: var(--mj-radius-full);\n background: var(--mj-bg-surface-sunken);\n display: flex;\n align-items: center;\n justify-content: center;\n margin-bottom: 24px;\n}\n\n.mj-forms-empty-search-icon i {\n font-size: 32px;\n color: var(--mj-text-muted);\n}\n\n.mj-forms-empty-search-title {\n font-size: var(--mj-text-xl);\n font-weight: var(--mj-font-semibold);\n color: var(--mj-text-primary);\n margin: 0 0 12px 0;\n}\n\n.mj-forms-empty-search-message {\n font-size: var(--mj-text-sm);\n color: var(--mj-text-secondary);\n line-height: 1.6;\n max-width: 400px;\n margin: 0;\n}\n\n.mj-forms-empty-search-message strong {\n color: var(--mj-text-primary);\n font-weight: var(--mj-font-semibold);\n}\n\n.mj-forms-empty-search-link {\n color: var(--mj-brand-primary);\n text-decoration: none;\n font-weight: var(--mj-font-medium);\n}\n\n.mj-forms-empty-search-link:hover {\n text-decoration: underline;\n}\n\n/* ============================================\n RESPONSIVE\n ============================================ */\n@media (max-width: 768px) {\n .mj-forms-panels-container {\n padding: 16px 12px 32px;\n }\n}\n"] }]
|
|
539
711
|
}], null, { Record: [{
|
|
540
712
|
type: Input
|
|
541
713
|
}], FormComponent: [{
|
|
@@ -598,5 +770,5 @@ export class MjRecordFormContainerComponent {
|
|
|
598
770
|
type: ContentChildren,
|
|
599
771
|
args: [MjCollapsiblePanelComponent, { descendants: true }]
|
|
600
772
|
}] }); })();
|
|
601
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(MjRecordFormContainerComponent, { className: "MjRecordFormContainerComponent", filePath: "src/lib/container/record-form-container.component.ts", lineNumber:
|
|
773
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(MjRecordFormContainerComponent, { className: "MjRecordFormContainerComponent", filePath: "src/lib/container/record-form-container.component.ts", lineNumber: 66 }); })();
|
|
602
774
|
//# sourceMappingURL=record-form-container.component.js.map
|