@memberjunction/ng-base-forms 6.1.0-edge.2 → 6.1.0-edge.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +180 -4
- package/README.md +4 -1
- package/dist/lib/base-form-component.d.ts +93 -3
- package/dist/lib/base-form-component.d.ts.map +1 -1
- package/dist/lib/base-form-component.js +240 -9
- package/dist/lib/base-form-component.js.map +1 -1
- package/dist/lib/chrome/base-form-policy.d.ts +26 -0
- package/dist/lib/chrome/base-form-policy.d.ts.map +1 -0
- package/dist/lib/chrome/base-form-policy.js +9 -0
- package/dist/lib/chrome/base-form-policy.js.map +1 -0
- package/dist/lib/chrome/clipped-title.d.ts +8 -0
- package/dist/lib/chrome/clipped-title.d.ts.map +1 -0
- package/dist/lib/chrome/clipped-title.js +18 -0
- package/dist/lib/chrome/clipped-title.js.map +1 -0
- package/dist/lib/chrome/form-chrome-coordinator.service.d.ts +35 -0
- package/dist/lib/chrome/form-chrome-coordinator.service.d.ts.map +1 -0
- package/dist/lib/chrome/form-chrome-coordinator.service.js +96 -0
- package/dist/lib/chrome/form-chrome-coordinator.service.js.map +1 -0
- package/dist/lib/chrome/form-chrome-rail-pref.d.ts +24 -0
- package/dist/lib/chrome/form-chrome-rail-pref.d.ts.map +1 -0
- package/dist/lib/chrome/form-chrome-rail-pref.js +52 -0
- package/dist/lib/chrome/form-chrome-rail-pref.js.map +1 -0
- package/dist/lib/chrome/form-chrome.d.ts +59 -0
- package/dist/lib/chrome/form-chrome.d.ts.map +1 -0
- package/dist/lib/chrome/form-chrome.js +37 -0
- package/dist/lib/chrome/form-chrome.js.map +1 -0
- package/dist/lib/chrome/load-form-chrome-rules.d.ts +8 -0
- package/dist/lib/chrome/load-form-chrome-rules.d.ts.map +1 -0
- package/dist/lib/chrome/load-form-chrome-rules.js +70 -0
- package/dist/lib/chrome/load-form-chrome-rules.js.map +1 -0
- package/dist/lib/chrome/resolve-form-chrome.d.ts +114 -0
- package/dist/lib/chrome/resolve-form-chrome.d.ts.map +1 -0
- package/dist/lib/chrome/resolve-form-chrome.js +713 -0
- package/dist/lib/chrome/resolve-form-chrome.js.map +1 -0
- package/dist/lib/container/record-form-container.component.d.ts +170 -6
- package/dist/lib/container/record-form-container.component.d.ts.map +1 -1
- package/dist/lib/container/record-form-container.component.js +1194 -62
- package/dist/lib/container/record-form-container.component.js.map +1 -1
- package/dist/lib/explorer-entity-data-grid.component.d.ts +54 -1
- package/dist/lib/explorer-entity-data-grid.component.d.ts.map +1 -1
- package/dist/lib/explorer-entity-data-grid.component.js +143 -7
- package/dist/lib/explorer-entity-data-grid.component.js.map +1 -1
- package/dist/lib/form-record-refresh.coordinator.d.ts +27 -0
- package/dist/lib/form-record-refresh.coordinator.d.ts.map +1 -0
- package/dist/lib/form-record-refresh.coordinator.js +33 -0
- package/dist/lib/form-record-refresh.coordinator.js.map +1 -0
- package/dist/lib/form-state.interface.d.ts +4 -0
- package/dist/lib/form-state.interface.d.ts.map +1 -1
- package/dist/lib/form-state.interface.js.map +1 -1
- package/dist/lib/form-state.service.d.ts +5 -0
- package/dist/lib/form-state.service.d.ts.map +1 -1
- package/dist/lib/form-state.service.js +23 -2
- package/dist/lib/form-state.service.js.map +1 -1
- package/dist/lib/host/entity-form-host.component.d.ts +5 -1
- package/dist/lib/host/entity-form-host.component.d.ts.map +1 -1
- package/dist/lib/host/entity-form-host.component.js +16 -2
- package/dist/lib/host/entity-form-host.component.js.map +1 -1
- package/dist/lib/isa-related-panel/isa-related-panel.component.d.ts +6 -2
- package/dist/lib/isa-related-panel/isa-related-panel.component.d.ts.map +1 -1
- package/dist/lib/isa-related-panel/isa-related-panel.component.js +15 -1
- package/dist/lib/isa-related-panel/isa-related-panel.component.js.map +1 -1
- package/dist/lib/panel/collapsible-panel.component.d.ts +24 -2
- package/dist/lib/panel/collapsible-panel.component.d.ts.map +1 -1
- package/dist/lib/panel/collapsible-panel.component.js +104 -10
- package/dist/lib/panel/collapsible-panel.component.js.map +1 -1
- package/dist/lib/panel-slot/base-form-panel.d.ts +85 -1
- package/dist/lib/panel-slot/base-form-panel.d.ts.map +1 -1
- package/dist/lib/panel-slot/base-form-panel.js +72 -3
- package/dist/lib/panel-slot/base-form-panel.js.map +1 -1
- package/dist/lib/panel-slot/collect-form-panel-registrations.d.ts +8 -0
- package/dist/lib/panel-slot/collect-form-panel-registrations.d.ts.map +1 -0
- package/dist/lib/panel-slot/collect-form-panel-registrations.js +19 -0
- package/dist/lib/panel-slot/collect-form-panel-registrations.js.map +1 -0
- package/dist/lib/panel-slot/form-contribution.d.ts +79 -0
- package/dist/lib/panel-slot/form-contribution.d.ts.map +1 -0
- package/dist/lib/panel-slot/form-contribution.js +253 -0
- package/dist/lib/panel-slot/form-contribution.js.map +1 -0
- package/dist/lib/panel-slot/form-contributions.component.d.ts +27 -0
- package/dist/lib/panel-slot/form-contributions.component.d.ts.map +1 -0
- package/dist/lib/panel-slot/form-contributions.component.js +83 -0
- package/dist/lib/panel-slot/form-contributions.component.js.map +1 -0
- package/dist/lib/panel-slot/form-panel-slot.component.d.ts +2 -0
- package/dist/lib/panel-slot/form-panel-slot.component.d.ts.map +1 -1
- package/dist/lib/panel-slot/form-panel-slot.component.js +35 -4
- package/dist/lib/panel-slot/form-panel-slot.component.js.map +1 -1
- package/dist/lib/panel-slot/related-entity-grid-panel.component.d.ts +22 -0
- package/dist/lib/panel-slot/related-entity-grid-panel.component.d.ts.map +1 -0
- package/dist/lib/panel-slot/related-entity-grid-panel.component.js +78 -0
- package/dist/lib/panel-slot/related-entity-grid-panel.component.js.map +1 -0
- package/dist/lib/related-grid-height.d.ts +20 -0
- package/dist/lib/related-grid-height.d.ts.map +1 -0
- package/dist/lib/related-grid-height.js +30 -0
- package/dist/lib/related-grid-height.js.map +1 -0
- package/dist/lib/section-manager/section-manager.component.d.ts +20 -1
- package/dist/lib/section-manager/section-manager.component.d.ts.map +1 -1
- package/dist/lib/section-manager/section-manager.component.js +204 -25
- package/dist/lib/section-manager/section-manager.component.js.map +1 -1
- package/dist/lib/toolbar/form-toolbar.component.d.ts +55 -4
- package/dist/lib/toolbar/form-toolbar.component.d.ts.map +1 -1
- package/dist/lib/toolbar/form-toolbar.component.js +734 -306
- package/dist/lib/toolbar/form-toolbar.component.js.map +1 -1
- package/dist/lib/types/form-events.d.ts +35 -0
- package/dist/lib/types/form-events.d.ts.map +1 -1
- package/dist/lib/types/form-events.js +45 -0
- package/dist/lib/types/form-events.js.map +1 -1
- package/dist/lib/types/form-toolbar-item.d.ts +145 -0
- package/dist/lib/types/form-toolbar-item.d.ts.map +1 -0
- package/dist/lib/types/form-toolbar-item.js +2 -0
- package/dist/lib/types/form-toolbar-item.js.map +1 -0
- package/dist/lib/types/form-types.d.ts +8 -0
- package/dist/lib/types/form-types.d.ts.map +1 -1
- package/dist/lib/types/form-types.js.map +1 -1
- package/dist/lib/types/toolbar-config.d.ts +7 -2
- package/dist/lib/types/toolbar-config.d.ts.map +1 -1
- package/dist/lib/types/toolbar-config.js +6 -0
- package/dist/lib/types/toolbar-config.js.map +1 -1
- package/dist/module.d.ts +17 -14
- package/dist/module.d.ts.map +1 -1
- package/dist/module.js +14 -0
- package/dist/module.js.map +1 -1
- package/dist/public-api.d.ts +13 -0
- package/dist/public-api.d.ts.map +1 -1
- package/dist/public-api.js +14 -0
- package/dist/public-api.js.map +1 -1
- package/package.json +19 -18
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Component, Input, Output, EventEmitter, ChangeDetectionStrategy, ChangeDetectorRef, inject, NgZone, ContentChildren, ViewChild, ViewEncapsulation } from '@angular/core';
|
|
1
|
+
import { Component, Input, Output, EventEmitter, ChangeDetectionStrategy, ChangeDetectorRef, inject, NgZone, ContentChildren, ViewChild, ViewEncapsulation, ElementRef } from '@angular/core';
|
|
2
2
|
import { CompositeKey, RunView } from '@memberjunction/core';
|
|
3
3
|
import { UUIDsEqual } from '@memberjunction/global';
|
|
4
4
|
import { BaseAngularComponent } from '@memberjunction/ng-base-types';
|
|
@@ -8,69 +8,314 @@ import { takeUntil } from 'rxjs/operators';
|
|
|
8
8
|
import { DEFAULT_TOOLBAR_CONFIG } from '../types/toolbar-config';
|
|
9
9
|
import { ResolveFormShowToolbar, ResolveFormToolbarConfig } from '../types/entity-form-config';
|
|
10
10
|
import { MjCollapsiblePanelComponent } from '../panel/collapsible-panel.component';
|
|
11
|
-
import { BeforeHistoryViewEventArgs, BeforeListManagementEventArgs } from '../types/form-events';
|
|
11
|
+
import { BeforeHistoryViewEventArgs, BeforeListManagementEventArgs, BeforeLayoutResolveEventArgs, AfterLayoutResolvedEventArgs, BeforeSectionActivateEventArgs, AfterSectionActivatedEventArgs, } from '../types/form-events';
|
|
12
12
|
import { RecordChangesComponent } from '@memberjunction/ng-record-changes';
|
|
13
13
|
import { MJNotificationService } from '@memberjunction/ng-notifications';
|
|
14
14
|
import { FormSlotCoordinator } from '../panel-slot/form-slot-coordinator.service';
|
|
15
|
+
import { FormChromeCoordinator } from '../chrome/form-chrome-coordinator.service';
|
|
16
|
+
import { ResolveFormChrome, OrderChromeGroups, OrderMoreSectionKeys, MoveChromeGroupInSectionOrder, OverlayChromeSectionOrder } from '../chrome/resolve-form-chrome';
|
|
17
|
+
import { LoadFormChromeRules } from '../chrome/load-form-chrome-rules';
|
|
18
|
+
import { MORE_SECTION_KEY, HumanizeEntityTitle, IsAlwaysMoreSection } from '../chrome/form-chrome';
|
|
19
|
+
import { ClampRailWidth, FORM_CHROME_RAIL_PINNED_DEFAULT, FORM_CHROME_RAIL_WIDTH_DEFAULT, FORM_CHROME_RAIL_WIDTH_MAX, FORM_CHROME_RAIL_WIDTH_MIN, ParseRailPinnedSetting, ParseRailWidthSetting, SerializeRailPinnedSetting, SerializeRailWidthSetting, ShouldPersistChromeActiveGroup, } from '../chrome/form-chrome-rail-pref';
|
|
20
|
+
import { ApplyClippedTitle } from '../chrome/clipped-title';
|
|
21
|
+
import { CollectFormPanelRegistrations } from '../panel-slot/collect-form-panel-registrations';
|
|
22
|
+
import { ContributionHiddenSectionKeys, ResolveFormContributions } from '../panel-slot/form-contribution';
|
|
23
|
+
import { IsFormSectionHidden } from '../types/entity-form-config';
|
|
24
|
+
import { FormRecordRefreshCoordinator } from '../form-record-refresh.coordinator';
|
|
15
25
|
import * as i0 from "@angular/core";
|
|
16
26
|
import * as i1 from "@memberjunction/ng-ui-components";
|
|
17
27
|
import * as i2 from "@memberjunction/ng-record-changes";
|
|
18
28
|
import * as i3 from "@memberjunction/ng-list-management";
|
|
19
29
|
import * as i4 from "@memberjunction/ng-record-tags";
|
|
20
|
-
import * as i5 from "
|
|
21
|
-
import * as i6 from "../
|
|
22
|
-
import * as i7 from "../
|
|
23
|
-
import * as i8 from "../panel
|
|
30
|
+
import * as i5 from "@memberjunction/ng-file-storage";
|
|
31
|
+
import * as i6 from "../toolbar/form-toolbar.component";
|
|
32
|
+
import * as i7 from "../section-manager/section-manager.component";
|
|
33
|
+
import * as i8 from "../isa-related-panel/isa-related-panel.component";
|
|
34
|
+
import * as i9 from "../panel-slot/form-panel-slot.component";
|
|
35
|
+
import * as i10 from "../panel-slot/form-contributions.component";
|
|
24
36
|
const _c0 = [[["", "before-toolbar", ""]], "*"];
|
|
25
37
|
const _c1 = ["[before-toolbar]", "*"];
|
|
26
38
|
const _c2 = a0 => [a0];
|
|
27
39
|
const _c3 = (a0, a1, a2) => ({ mode: "manage", entityId: a0, entityName: a1, recordIds: a2, allowCreate: true });
|
|
40
|
+
const _forTrack0 = ($index, $item) => $item.Key;
|
|
28
41
|
function MjRecordFormContainerComponent_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
29
42
|
const _r1 = i0.ɵɵgetCurrentView();
|
|
30
|
-
i0.ɵɵelementStart(0, "mj-form-toolbar",
|
|
31
|
-
i0.ɵɵlistener("Navigate", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_Navigate_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnNavigate($event)); })("EditModeChange", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_EditModeChange_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnEditModeChange($event)); })("BeforeSave", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_BeforeSave_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BeforeSave.emit($event)); })("SaveRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_SaveRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnSaveRequested()); })("BeforeCancel", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_BeforeCancel_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BeforeCancel.emit($event)); })("CancelRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_CancelRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnCancelRequested()); })("BeforeDelete", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_BeforeDelete_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BeforeDelete.emit($event)); })("DeleteRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_DeleteRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnDeleteRequested()); })("FavoriteToggled", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_FavoriteToggled_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnFavoriteToggled()); })("BeforeHistoryView", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_BeforeHistoryView_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BeforeHistoryView.emit($event)); })("HistoryRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_HistoryRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnHistoryRequested()); })("BeforeListManagement", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_BeforeListManagement_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BeforeListManagement.emit($event)); })("ListManagementRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ListManagementRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnListManagementRequested()); })("ShowChangesRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ShowChangesRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnShowChangesRequested()); })("CustomButtonClick", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_CustomButtonClick_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.CustomButtonClick.emit($event)); })("FilterChange", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_FilterChange_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnFilterChange($event)); })("ExpandAllRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ExpandAllRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnExpandAll()); })("CollapseAllRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_CollapseAllRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnCollapseAll()); })("ShowEmptyFieldsChange", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ShowEmptyFieldsChange_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnShowEmptyFieldsChange($event)); })("WidthModeChange", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_WidthModeChange_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnWidthModeChange($event)); })("ResetSectionOrderRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ResetSectionOrderRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnResetSectionOrder()); })("ManageSectionsRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ManageSectionsRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnManageSections()); })("TagsPanelToggled", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_TagsPanelToggled_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnTagsPanelToggled()); })("VariantPicked", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_VariantPicked_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnVariantPicked($event)); });
|
|
43
|
+
i0.ɵɵelementStart(0, "mj-form-toolbar", 16);
|
|
44
|
+
i0.ɵɵlistener("Navigate", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_Navigate_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnNavigate($event)); })("EditModeChange", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_EditModeChange_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnEditModeChange($event)); })("BeforeSave", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_BeforeSave_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BeforeSave.emit($event)); })("SaveRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_SaveRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnSaveRequested()); })("BeforeCancel", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_BeforeCancel_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BeforeCancel.emit($event)); })("CancelRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_CancelRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnCancelRequested()); })("BeforeDelete", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_BeforeDelete_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BeforeDelete.emit($event)); })("DeleteRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_DeleteRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnDeleteRequested()); })("BeforeRefresh", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_BeforeRefresh_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BeforeRefresh.emit($event)); })("RefreshRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_RefreshRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnRefreshRequested()); })("FavoriteToggled", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_FavoriteToggled_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnFavoriteToggled()); })("BeforeHistoryView", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_BeforeHistoryView_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BeforeHistoryView.emit($event)); })("HistoryRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_HistoryRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnHistoryRequested()); })("BeforeListManagement", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_BeforeListManagement_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BeforeListManagement.emit($event)); })("ListManagementRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ListManagementRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnListManagementRequested()); })("ShowChangesRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ShowChangesRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnShowChangesRequested()); })("CustomButtonClick", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_CustomButtonClick_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.CustomButtonClick.emit($event)); })("ToolbarItemClick", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ToolbarItemClick_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.ToolbarItemClick.emit($event)); })("FilterChange", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_FilterChange_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnFilterChange($event)); })("ExpandAllRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ExpandAllRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnExpandAll()); })("CollapseAllRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_CollapseAllRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnCollapseAll()); })("ShowEmptyFieldsChange", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ShowEmptyFieldsChange_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnShowEmptyFieldsChange($event)); })("WidthModeChange", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_WidthModeChange_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnWidthModeChange($event)); })("ResetSectionOrderRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ResetSectionOrderRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnResetSectionOrder()); })("ManageSectionsRequested", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_ManageSectionsRequested_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnManageSections()); })("TagsPanelToggled", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_TagsPanelToggled_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnTagsPanelToggled()); })("AttachmentsPanelToggled", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_AttachmentsPanelToggled_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnAttachmentsPanelToggled()); })("VariantPicked", function MjRecordFormContainerComponent_Conditional_1_Template_mj_form_toolbar_VariantPicked_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnVariantPicked($event)); });
|
|
32
45
|
i0.ɵɵelementEnd();
|
|
33
46
|
} if (rf & 2) {
|
|
34
47
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
35
|
-
i0.ɵɵproperty("Record", ctx_r1.EffectiveRecord)("EditMode", ctx_r1.EffectiveEditMode)("UserCanEdit", ctx_r1.EffectiveUserCanEdit)("UserCanDelete", ctx_r1.EffectiveUserCanDelete)("IsFavorite", ctx_r1.EffectiveIsFavorite)("FavoriteInitDone", ctx_r1.EffectiveFavoriteInitDone)("IsDirty", ctx_r1.EffectiveIsDirty)("DirtyFieldNames", ctx_r1.EffectiveDirtyFieldNames)("ListCount", ctx_r1.ListCount)("TagCount", ctx_r1.TagCount)("VersionCount", ctx_r1.VersionCount)("EntityInfo", ctx_r1.EffectiveEntityInfo)("Config", ctx_r1.EffectiveToolbarConfig)("IsSaving", ctx_r1.EffectiveIsSaving)("VisibleSectionCount", ctx_r1.VisibleSectionCount)("TotalSectionCount", ctx_r1.TotalSectionCount)("ExpandedSectionCount", ctx_r1.ExpandedSectionCount)("SearchFilter", ctx_r1.EffectiveSearchFilter)("ShowEmptyFields", ctx_r1.EffectiveShowEmptyFields)("WidthMode", ctx_r1.EffectiveWidthMode)("HasCustomSectionOrder", ctx_r1.EffectiveHasCustomSectionOrder)("Variants", ctx_r1.EffectiveVariants)("CurrentVariantID", ctx_r1.EffectiveCurrentVariantID);
|
|
48
|
+
i0.ɵɵproperty("Record", ctx_r1.EffectiveRecord)("EditMode", ctx_r1.EffectiveEditMode)("UserCanEdit", ctx_r1.EffectiveUserCanEdit)("UserCanDelete", ctx_r1.EffectiveUserCanDelete)("IsFavorite", ctx_r1.EffectiveIsFavorite)("FavoriteInitDone", ctx_r1.EffectiveFavoriteInitDone)("IsDirty", ctx_r1.EffectiveIsDirty)("DirtyFieldNames", ctx_r1.EffectiveDirtyFieldNames)("ListCount", ctx_r1.ListCount)("TagCount", ctx_r1.TagCount)("AttachmentCount", ctx_r1.AttachmentCount)("AttachmentsAvailable", ctx_r1.AttachmentsAvailable)("IsAttachmentsPanelOpen", ctx_r1.ShowAttachmentsPanel)("VersionCount", ctx_r1.VersionCount)("EntityInfo", ctx_r1.EffectiveEntityInfo)("Config", ctx_r1.EffectiveToolbarConfig)("IsSaving", ctx_r1.EffectiveIsSaving)("IsRefreshing", ctx_r1.EffectiveIsRefreshing)("VisibleSectionCount", ctx_r1.VisibleSectionCount)("TotalSectionCount", ctx_r1.TotalSectionCount)("ExpandedSectionCount", ctx_r1.ExpandedSectionCount)("SearchFilter", ctx_r1.EffectiveSearchFilter)("ShowEmptyFields", ctx_r1.EffectiveShowEmptyFields)("WidthMode", ctx_r1.EffectiveWidthMode)("HasCustomSectionOrder", ctx_r1.EffectiveHasCustomSectionOrder)("ChromeLayout", ctx_r1.ChromeLayout)("Variants", ctx_r1.EffectiveVariants)("CurrentVariantID", ctx_r1.EffectiveCurrentVariantID)("RegisteredItems", ctx_r1.EffectiveRegisteredToolbarItems)("ItemOverrides", ctx_r1.EffectiveToolbarItemOverrides)("FormComponent", ctx_r1.fc);
|
|
36
49
|
} }
|
|
37
|
-
function
|
|
38
|
-
i0.ɵɵ
|
|
50
|
+
function MjRecordFormContainerComponent_Conditional_5_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
51
|
+
const _r3 = i0.ɵɵgetCurrentView();
|
|
52
|
+
i0.ɵɵelementStart(0, "button", 19);
|
|
53
|
+
i0.ɵɵlistener("click", function MjRecordFormContainerComponent_Conditional_5_Conditional_1_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.OnChromeRailExpand()); });
|
|
54
|
+
i0.ɵɵelement(1, "i");
|
|
55
|
+
i0.ɵɵelementStart(2, "span", 20);
|
|
56
|
+
i0.ɵɵlistener("mouseenter", function MjRecordFormContainerComponent_Conditional_5_Conditional_1_Template_span_mouseenter_2_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.OnRailLabelHover($event, ctx_r1.ChromeActiveTitle)); });
|
|
57
|
+
i0.ɵɵtext(3);
|
|
58
|
+
i0.ɵɵelementEnd()();
|
|
59
|
+
} if (rf & 2) {
|
|
60
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
61
|
+
i0.ɵɵproperty("title", "Show sections \u2014 " + ctx_r1.ChromeActiveTitle);
|
|
62
|
+
i0.ɵɵattribute("aria-label", "Show form sections \u2014 " + ctx_r1.ChromeActiveTitle);
|
|
63
|
+
i0.ɵɵadvance();
|
|
64
|
+
i0.ɵɵclassMap(ctx_r1.ChromeActiveIcon);
|
|
65
|
+
i0.ɵɵadvance(2);
|
|
66
|
+
i0.ɵɵtextInterpolate(ctx_r1.ChromeActiveTitle);
|
|
67
|
+
} }
|
|
68
|
+
function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
69
|
+
const _r7 = i0.ɵɵgetCurrentView();
|
|
70
|
+
i0.ɵɵelementStart(0, "span", 32);
|
|
71
|
+
i0.ɵɵlistener("dragstart", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Conditional_1_Template_span_dragstart_0_listener($event) { i0.ɵɵrestoreView(_r7); const group_r6 = i0.ɵɵnextContext().$implicit; const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.OnRailDragStart($event, group_r6.Key)); })("dragend", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Conditional_1_Template_span_dragend_0_listener() { i0.ɵɵrestoreView(_r7); const ctx_r1 = i0.ɵɵnextContext(4); return i0.ɵɵresetView(ctx_r1.OnRailDragEnd()); })("click", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Conditional_1_Template_span_click_0_listener($event) { i0.ɵɵrestoreView(_r7); return i0.ɵɵresetView($event.stopPropagation()); });
|
|
72
|
+
i0.ɵɵelement(1, "i", 33);
|
|
73
|
+
i0.ɵɵelementEnd();
|
|
74
|
+
} }
|
|
75
|
+
function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Conditional_6_Template(rf, ctx) { if (rf & 1) {
|
|
76
|
+
i0.ɵɵelementStart(0, "span", 34);
|
|
77
|
+
i0.ɵɵtext(1);
|
|
78
|
+
i0.ɵɵelementEnd();
|
|
79
|
+
} if (rf & 2) {
|
|
80
|
+
i0.ɵɵnextContext();
|
|
81
|
+
const rowCount_r8 = i0.ɵɵreadContextLet(5);
|
|
82
|
+
i0.ɵɵclassProp("is-zero", rowCount_r8 === 0);
|
|
83
|
+
i0.ɵɵadvance();
|
|
84
|
+
i0.ɵɵtextInterpolate(rowCount_r8);
|
|
85
|
+
} }
|
|
86
|
+
function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Template(rf, ctx) { if (rf & 1) {
|
|
87
|
+
const _r5 = i0.ɵɵgetCurrentView();
|
|
88
|
+
i0.ɵɵelementStart(0, "div", 28);
|
|
89
|
+
i0.ɵɵlistener("click", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Template_div_click_0_listener() { const group_r6 = i0.ɵɵrestoreView(_r5).$implicit; const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.OnChromeGroupActivate(group_r6.Key)); })("keydown.enter", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Template_div_keydown_enter_0_listener() { const group_r6 = i0.ɵɵrestoreView(_r5).$implicit; const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.OnChromeGroupActivate(group_r6.Key)); })("keydown.space", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Template_div_keydown_space_0_listener($event) { const group_r6 = i0.ɵɵrestoreView(_r5).$implicit; const ctx_r1 = i0.ɵɵnextContext(3); $event.preventDefault(); return i0.ɵɵresetView(ctx_r1.OnChromeGroupActivate(group_r6.Key)); })("dragover", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Template_div_dragover_0_listener($event) { const group_r6 = i0.ɵɵrestoreView(_r5).$implicit; const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.OnRailDragOver($event, group_r6.Key)); })("dragleave", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Template_div_dragleave_0_listener($event) { const group_r6 = i0.ɵɵrestoreView(_r5).$implicit; const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.OnRailDragLeave($event, group_r6.Key)); })("drop", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Template_div_drop_0_listener($event) { const group_r6 = i0.ɵɵrestoreView(_r5).$implicit; const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.OnRailDrop($event, group_r6.Key)); });
|
|
90
|
+
i0.ɵɵconditionalCreate(1, MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Conditional_1_Template, 2, 0, "span", 29);
|
|
91
|
+
i0.ɵɵelement(2, "i");
|
|
92
|
+
i0.ɵɵelementStart(3, "span", 30);
|
|
93
|
+
i0.ɵɵlistener("mouseenter", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Template_span_mouseenter_3_listener($event) { const group_r6 = i0.ɵɵrestoreView(_r5).$implicit; const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.OnRailLabelHover($event, group_r6.Title)); });
|
|
94
|
+
i0.ɵɵtext(4);
|
|
95
|
+
i0.ɵɵelementEnd();
|
|
96
|
+
i0.ɵɵdeclareLet(5);
|
|
97
|
+
i0.ɵɵconditionalCreate(6, MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Conditional_6_Template, 2, 3, "span", 31);
|
|
98
|
+
i0.ɵɵelementEnd();
|
|
99
|
+
} if (rf & 2) {
|
|
100
|
+
const group_r6 = ctx.$implicit;
|
|
101
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
102
|
+
i0.ɵɵclassProp("is-active", ctx_r1.ChromeActiveGroupKey === group_r6.Key)("is-drag-over", ctx_r1.RailDragOverKey === group_r6.Key);
|
|
103
|
+
i0.ɵɵattribute("aria-current", ctx_r1.ChromeActiveGroupKey === group_r6.Key ? "page" : null);
|
|
104
|
+
i0.ɵɵadvance();
|
|
105
|
+
i0.ɵɵconditional(ctx_r1.ChromeReorderAllowed ? 1 : -1);
|
|
106
|
+
i0.ɵɵadvance();
|
|
107
|
+
i0.ɵɵclassMap(group_r6.Icon);
|
|
108
|
+
i0.ɵɵadvance(2);
|
|
109
|
+
i0.ɵɵtextInterpolate(group_r6.Title);
|
|
110
|
+
i0.ɵɵadvance();
|
|
111
|
+
const rowCount_r9 = i0.ɵɵstoreLet(ctx_r1.ChromeGroupRowCount(group_r6));
|
|
112
|
+
i0.ɵɵadvance();
|
|
113
|
+
i0.ɵɵconditional(rowCount_r9 != null ? 6 : -1);
|
|
114
|
+
} }
|
|
115
|
+
function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
116
|
+
const _r14 = i0.ɵɵgetCurrentView();
|
|
117
|
+
i0.ɵɵelementStart(0, "span", 32);
|
|
118
|
+
i0.ɵɵlistener("dragstart", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Conditional_1_Template_span_dragstart_0_listener($event) { i0.ɵɵrestoreView(_r14); const child_r13 = i0.ɵɵnextContext().$implicit; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.OnRailDragStart($event, child_r13.Key)); })("dragend", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Conditional_1_Template_span_dragend_0_listener() { i0.ɵɵrestoreView(_r14); const ctx_r1 = i0.ɵɵnextContext(6); return i0.ɵɵresetView(ctx_r1.OnRailDragEnd()); })("click", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Conditional_1_Template_span_click_0_listener($event) { i0.ɵɵrestoreView(_r14); return i0.ɵɵresetView($event.stopPropagation()); });
|
|
119
|
+
i0.ɵɵelement(1, "i", 33);
|
|
120
|
+
i0.ɵɵelementEnd();
|
|
121
|
+
} }
|
|
122
|
+
function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Conditional_6_Template(rf, ctx) { if (rf & 1) {
|
|
123
|
+
i0.ɵɵelementStart(0, "span", 34);
|
|
124
|
+
i0.ɵɵtext(1);
|
|
125
|
+
i0.ɵɵelementEnd();
|
|
126
|
+
} if (rf & 2) {
|
|
127
|
+
i0.ɵɵnextContext();
|
|
128
|
+
const childCount_r15 = i0.ɵɵreadContextLet(5);
|
|
129
|
+
i0.ɵɵclassProp("is-zero", childCount_r15 === 0);
|
|
130
|
+
i0.ɵɵadvance();
|
|
131
|
+
i0.ɵɵtextInterpolate(childCount_r15);
|
|
132
|
+
} }
|
|
133
|
+
function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
134
|
+
const _r12 = i0.ɵɵgetCurrentView();
|
|
135
|
+
i0.ɵɵelementStart(0, "div", 40);
|
|
136
|
+
i0.ɵɵlistener("click", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Template_div_click_0_listener() { const child_r13 = i0.ɵɵrestoreView(_r12).$implicit; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.OnChromeGroupActivate(child_r13.Key)); })("keydown.enter", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Template_div_keydown_enter_0_listener() { const child_r13 = i0.ɵɵrestoreView(_r12).$implicit; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.OnChromeGroupActivate(child_r13.Key)); })("keydown.space", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Template_div_keydown_space_0_listener($event) { const child_r13 = i0.ɵɵrestoreView(_r12).$implicit; const ctx_r1 = i0.ɵɵnextContext(5); $event.preventDefault(); return i0.ɵɵresetView(ctx_r1.OnChromeGroupActivate(child_r13.Key)); })("dragover", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Template_div_dragover_0_listener($event) { const child_r13 = i0.ɵɵrestoreView(_r12).$implicit; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.OnRailDragOver($event, child_r13.Key)); })("dragleave", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Template_div_dragleave_0_listener($event) { const child_r13 = i0.ɵɵrestoreView(_r12).$implicit; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.OnRailDragLeave($event, child_r13.Key)); })("drop", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Template_div_drop_0_listener($event) { const child_r13 = i0.ɵɵrestoreView(_r12).$implicit; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.OnRailDrop($event, child_r13.Key)); });
|
|
137
|
+
i0.ɵɵconditionalCreate(1, MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Conditional_1_Template, 2, 0, "span", 29);
|
|
138
|
+
i0.ɵɵelement(2, "i");
|
|
139
|
+
i0.ɵɵelementStart(3, "span", 30);
|
|
140
|
+
i0.ɵɵlistener("mouseenter", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Template_span_mouseenter_3_listener($event) { const child_r13 = i0.ɵɵrestoreView(_r12).$implicit; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.OnRailLabelHover($event, child_r13.Title)); });
|
|
141
|
+
i0.ɵɵtext(4);
|
|
142
|
+
i0.ɵɵelementEnd();
|
|
143
|
+
i0.ɵɵdeclareLet(5);
|
|
144
|
+
i0.ɵɵconditionalCreate(6, MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Conditional_6_Template, 2, 3, "span", 31);
|
|
145
|
+
i0.ɵɵelementEnd();
|
|
146
|
+
} if (rf & 2) {
|
|
147
|
+
const child_r13 = ctx.$implicit;
|
|
148
|
+
const ctx_r1 = i0.ɵɵnextContext(5);
|
|
149
|
+
i0.ɵɵclassProp("is-active", ctx_r1.ChromeActiveGroupKey === child_r13.Key)("is-drag-over", ctx_r1.RailDragOverKey === child_r13.Key);
|
|
150
|
+
i0.ɵɵattribute("aria-current", ctx_r1.ChromeActiveGroupKey === child_r13.Key ? "page" : null);
|
|
151
|
+
i0.ɵɵadvance();
|
|
152
|
+
i0.ɵɵconditional(ctx_r1.ChromeReorderAllowed ? 1 : -1);
|
|
153
|
+
i0.ɵɵadvance();
|
|
154
|
+
i0.ɵɵclassMap(child_r13.Icon);
|
|
155
|
+
i0.ɵɵadvance(2);
|
|
156
|
+
i0.ɵɵtextInterpolate(child_r13.Title);
|
|
157
|
+
i0.ɵɵadvance();
|
|
158
|
+
const childCount_r16 = i0.ɵɵstoreLet(ctx_r1.ChromeGroupRowCount(child_r13));
|
|
159
|
+
i0.ɵɵadvance();
|
|
160
|
+
i0.ɵɵconditional(childCount_r16 != null ? 6 : -1);
|
|
161
|
+
} }
|
|
162
|
+
function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_Template(rf, ctx) { if (rf & 1) {
|
|
163
|
+
i0.ɵɵelementStart(0, "div", 38);
|
|
164
|
+
i0.ɵɵrepeaterCreate(1, MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_For_2_Template, 7, 11, "div", 39, _forTrack0);
|
|
165
|
+
i0.ɵɵelementEnd();
|
|
166
|
+
} if (rf & 2) {
|
|
167
|
+
const ctx_r1 = i0.ɵɵnextContext(4);
|
|
168
|
+
i0.ɵɵadvance();
|
|
169
|
+
i0.ɵɵrepeater(ctx_r1.ChromeMoreItems);
|
|
170
|
+
} }
|
|
171
|
+
function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Template(rf, ctx) { if (rf & 1) {
|
|
172
|
+
const _r10 = i0.ɵɵgetCurrentView();
|
|
173
|
+
i0.ɵɵelementStart(0, "div", 35);
|
|
174
|
+
i0.ɵɵlistener("click", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Template_div_click_0_listener() { i0.ɵɵrestoreView(_r10); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.OnMoreFolderToggle()); })("keydown.enter", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Template_div_keydown_enter_0_listener() { i0.ɵɵrestoreView(_r10); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.OnMoreFolderToggle()); })("keydown.space", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Template_div_keydown_space_0_listener($event) { i0.ɵɵrestoreView(_r10); const ctx_r1 = i0.ɵɵnextContext(3); $event.preventDefault(); return i0.ɵɵresetView(ctx_r1.OnMoreFolderToggle()); });
|
|
175
|
+
i0.ɵɵelement(1, "span", 36)(2, "i");
|
|
176
|
+
i0.ɵɵelementStart(3, "span", 30);
|
|
177
|
+
i0.ɵɵlistener("mouseenter", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Template_span_mouseenter_3_listener($event) { const more_r11 = i0.ɵɵrestoreView(_r10); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.OnRailLabelHover($event, more_r11.Title)); });
|
|
178
|
+
i0.ɵɵtext(4);
|
|
179
|
+
i0.ɵɵelementEnd();
|
|
180
|
+
i0.ɵɵelement(5, "i", 37);
|
|
181
|
+
i0.ɵɵelementEnd();
|
|
182
|
+
i0.ɵɵconditionalCreate(6, MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Conditional_6_Template, 3, 0, "div", 38);
|
|
183
|
+
} if (rf & 2) {
|
|
184
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
185
|
+
i0.ɵɵclassProp("is-expanded", ctx_r1.MoreExpanded);
|
|
186
|
+
i0.ɵɵadvance(2);
|
|
187
|
+
i0.ɵɵclassMap(ctx_r1.MoreExpanded ? "fa-solid fa-folder-open" : "fa-solid fa-folder");
|
|
188
|
+
i0.ɵɵadvance(2);
|
|
189
|
+
i0.ɵɵtextInterpolate(ctx.Title);
|
|
190
|
+
i0.ɵɵadvance();
|
|
191
|
+
i0.ɵɵclassProp("fa-minus", ctx_r1.MoreExpanded)("fa-plus", !ctx_r1.MoreExpanded);
|
|
192
|
+
i0.ɵɵadvance();
|
|
193
|
+
i0.ɵɵconditional(ctx_r1.MoreExpanded ? 6 : -1);
|
|
194
|
+
} }
|
|
195
|
+
function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Template(rf, ctx) { if (rf & 1) {
|
|
196
|
+
const _r4 = i0.ɵɵgetCurrentView();
|
|
197
|
+
i0.ɵɵelementStart(0, "div", 21);
|
|
198
|
+
i0.ɵɵlistener("pointerdown", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Template_div_pointerdown_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.OnRailResizeStart($event)); })("pointermove", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Template_div_pointermove_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.OnRailResizeMove($event)); })("pointerup", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Template_div_pointerup_0_listener() { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.OnRailResizeEnd()); })("pointercancel", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Template_div_pointercancel_0_listener() { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.OnRailResizeEnd()); });
|
|
199
|
+
i0.ɵɵelementEnd();
|
|
200
|
+
i0.ɵɵelementStart(1, "div", 22)(2, "button", 23);
|
|
201
|
+
i0.ɵɵlistener("click", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Template_button_click_2_listener() { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.OnChromeRailPinToggle()); });
|
|
202
|
+
i0.ɵɵelement(3, "i", 24);
|
|
203
|
+
i0.ɵɵelementEnd();
|
|
204
|
+
i0.ɵɵelementStart(4, "button", 25);
|
|
205
|
+
i0.ɵɵlistener("click", function MjRecordFormContainerComponent_Conditional_5_Conditional_2_Template_button_click_4_listener() { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.OnChromeRailCollapse()); });
|
|
206
|
+
i0.ɵɵelement(5, "i", 26);
|
|
207
|
+
i0.ɵɵelementEnd()();
|
|
208
|
+
i0.ɵɵrepeaterCreate(6, MjRecordFormContainerComponent_Conditional_5_Conditional_2_For_7_Template, 7, 11, "div", 27, _forTrack0);
|
|
209
|
+
i0.ɵɵconditionalCreate(8, MjRecordFormContainerComponent_Conditional_5_Conditional_2_Conditional_8_Template, 7, 10);
|
|
210
|
+
} if (rf & 2) {
|
|
211
|
+
let tmp_9_0;
|
|
212
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
213
|
+
i0.ɵɵattribute("aria-valuenow", ctx_r1.ChromeRailWidthPx)("aria-valuemin", ctx_r1.RailWidthMin)("aria-valuemax", ctx_r1.RailWidthMax);
|
|
214
|
+
i0.ɵɵadvance(2);
|
|
215
|
+
i0.ɵɵclassProp("is-pinned", ctx_r1.ChromeRailPinned);
|
|
216
|
+
i0.ɵɵproperty("title", ctx_r1.ChromeRailPinned ? "Unpin sections \u2014 they hide after you switch" : "Pin sections open");
|
|
217
|
+
i0.ɵɵattribute("aria-pressed", ctx_r1.ChromeRailPinned);
|
|
218
|
+
i0.ɵɵadvance(4);
|
|
219
|
+
i0.ɵɵrepeater(ctx_r1.ChromeFirstClassGroups);
|
|
220
|
+
i0.ɵɵadvance(2);
|
|
221
|
+
i0.ɵɵconditional((tmp_9_0 = ctx_r1.ChromeMoreFolder) ? 8 : -1, tmp_9_0);
|
|
222
|
+
} }
|
|
223
|
+
function MjRecordFormContainerComponent_Conditional_5_Template(rf, ctx) { if (rf & 1) {
|
|
224
|
+
i0.ɵɵelementStart(0, "nav", 17);
|
|
225
|
+
i0.ɵɵconditionalCreate(1, MjRecordFormContainerComponent_Conditional_5_Conditional_1_Template, 4, 5, "button", 18)(2, MjRecordFormContainerComponent_Conditional_5_Conditional_2_Template, 9, 8);
|
|
226
|
+
i0.ɵɵelementEnd();
|
|
39
227
|
} if (rf & 2) {
|
|
40
228
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
41
|
-
i0.ɵɵ
|
|
229
|
+
i0.ɵɵstyleProp("width", ctx_r1.ChromeRailCollapsed ? null : ctx_r1.ChromeRailWidthPx, "px");
|
|
230
|
+
i0.ɵɵclassProp("is-collapsed", ctx_r1.ChromeRailCollapsed)("is-resizing", ctx_r1.RailResizing);
|
|
231
|
+
i0.ɵɵattribute("aria-expanded", !ctx_r1.ChromeRailCollapsed);
|
|
232
|
+
i0.ɵɵadvance();
|
|
233
|
+
i0.ɵɵconditional(ctx_r1.ChromeRailCollapsed ? 1 : 2);
|
|
42
234
|
} }
|
|
43
235
|
function MjRecordFormContainerComponent_Conditional_8_Template(rf, ctx) { if (rf & 1) {
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
236
|
+
i0.ɵɵelement(0, "mj-form-contributions", 6);
|
|
237
|
+
} if (rf & 2) {
|
|
238
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
239
|
+
i0.ɵɵproperty("Record", ctx_r1.Record)("FormComponent", ctx_r1.FormComponent)("FormContext", ctx_r1.FormComponent.formContext)("BakedSectionKeys", ctx_r1.BakedRelatedSectionKeys)("ShowRelatedEntities", ctx_r1.EffectiveShowRelatedEntities);
|
|
240
|
+
} }
|
|
241
|
+
function MjRecordFormContainerComponent_Conditional_9_Conditional_5_Template(rf, ctx) { if (rf & 1) {
|
|
242
|
+
i0.ɵɵelementStart(0, "span", 44);
|
|
243
|
+
i0.ɵɵtext(1);
|
|
47
244
|
i0.ɵɵelementEnd();
|
|
245
|
+
} if (rf & 2) {
|
|
246
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
247
|
+
i0.ɵɵadvance();
|
|
248
|
+
i0.ɵɵtextInterpolate(ctx_r1.MorePreview);
|
|
249
|
+
} }
|
|
250
|
+
function MjRecordFormContainerComponent_Conditional_9_Template(rf, ctx) { if (rf & 1) {
|
|
251
|
+
const _r17 = i0.ɵɵgetCurrentView();
|
|
252
|
+
i0.ɵɵelementStart(0, "div", 41)(1, "button", 42);
|
|
253
|
+
i0.ɵɵlistener("click", function MjRecordFormContainerComponent_Conditional_9_Template_button_click_1_listener() { i0.ɵɵrestoreView(_r17); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnMoreToggle()); });
|
|
254
|
+
i0.ɵɵelement(2, "i");
|
|
255
|
+
i0.ɵɵelementStart(3, "span", 43);
|
|
256
|
+
i0.ɵɵtext(4);
|
|
257
|
+
i0.ɵɵelementEnd();
|
|
258
|
+
i0.ɵɵconditionalCreate(5, MjRecordFormContainerComponent_Conditional_9_Conditional_5_Template, 2, 1, "span", 44);
|
|
259
|
+
i0.ɵɵelement(6, "i", 45);
|
|
260
|
+
i0.ɵɵelementEnd()();
|
|
48
261
|
} if (rf & 2) {
|
|
49
262
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
50
|
-
i0.ɵɵ
|
|
263
|
+
i0.ɵɵclassProp("is-expanded", ctx_r1.MoreExpanded);
|
|
264
|
+
i0.ɵɵadvance(2);
|
|
265
|
+
i0.ɵɵclassMap(ctx_r1.MoreExpanded ? "fa-solid fa-folder-open" : "fa-solid fa-folder");
|
|
266
|
+
i0.ɵɵadvance(2);
|
|
267
|
+
i0.ɵɵtextInterpolate(ctx_r1.MoreExpanded ? "Hide more" : "More");
|
|
268
|
+
i0.ɵɵadvance();
|
|
269
|
+
i0.ɵɵconditional(!ctx_r1.MoreExpanded && ctx_r1.MorePreview ? 5 : -1);
|
|
270
|
+
i0.ɵɵadvance();
|
|
271
|
+
i0.ɵɵclassProp("fa-chevron-down", ctx_r1.MoreExpanded)("fa-chevron-right", !ctx_r1.MoreExpanded);
|
|
51
272
|
} }
|
|
52
273
|
function MjRecordFormContainerComponent_Conditional_10_Template(rf, ctx) { if (rf & 1) {
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
274
|
+
i0.ɵɵelement(0, "mj-form-panel-slot", 8);
|
|
275
|
+
} if (rf & 2) {
|
|
276
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
277
|
+
i0.ɵɵproperty("Entity", ctx_r1.Record.EntityInfo.Name)("Record", ctx_r1.Record)("FormComponent", ctx_r1.FormComponent);
|
|
278
|
+
} }
|
|
279
|
+
function MjRecordFormContainerComponent_Conditional_11_Template(rf, ctx) { if (rf & 1) {
|
|
280
|
+
const _r18 = i0.ɵɵgetCurrentView();
|
|
281
|
+
i0.ɵɵelementStart(0, "mj-empty-state", 46);
|
|
282
|
+
i0.ɵɵlistener("Action", function MjRecordFormContainerComponent_Conditional_11_Template_mj_empty_state_Action_0_listener() { i0.ɵɵrestoreView(_r18); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnFilterChange("")); });
|
|
283
|
+
i0.ɵɵelementEnd();
|
|
284
|
+
} if (rf & 2) {
|
|
285
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
286
|
+
i0.ɵɵproperty("Message", "No sections match \"" + ctx_r1.EffectiveSearchFilter + "\". Try a different search term.");
|
|
287
|
+
} }
|
|
288
|
+
function MjRecordFormContainerComponent_Conditional_13_Template(rf, ctx) { if (rf & 1) {
|
|
289
|
+
const _r19 = i0.ɵɵgetCurrentView();
|
|
290
|
+
i0.ɵɵelementStart(0, "mj-record-changes", 47);
|
|
291
|
+
i0.ɵɵlistener("RestoreRequested", function MjRecordFormContainerComponent_Conditional_13_Template_mj_record_changes_RestoreRequested_0_listener($event) { i0.ɵɵrestoreView(_r19); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnRestoreRequested($event)); })("dialogClosed", function MjRecordFormContainerComponent_Conditional_13_Template_mj_record_changes_dialogClosed_0_listener() { i0.ɵɵrestoreView(_r19); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnRecordChangesClosed()); });
|
|
56
292
|
i0.ɵɵelementEnd();
|
|
57
293
|
} if (rf & 2) {
|
|
58
294
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
59
295
|
i0.ɵɵproperty("record", ctx_r1.EffectiveRecord)("AllowRestore", ctx_r1.EffectiveUserCanEdit);
|
|
60
296
|
} }
|
|
61
|
-
function
|
|
62
|
-
const
|
|
63
|
-
i0.ɵɵelementStart(0, "mj-record-tags",
|
|
64
|
-
i0.ɵɵlistener("PanelClosed", function
|
|
297
|
+
function MjRecordFormContainerComponent_Conditional_14_Template(rf, ctx) { if (rf & 1) {
|
|
298
|
+
const _r20 = i0.ɵɵgetCurrentView();
|
|
299
|
+
i0.ɵɵelementStart(0, "mj-record-tags", 48);
|
|
300
|
+
i0.ɵɵlistener("PanelClosed", function MjRecordFormContainerComponent_Conditional_14_Template_mj_record_tags_PanelClosed_0_listener() { i0.ɵɵrestoreView(_r20); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnTagsPanelClosed()); })("TagCountChanged", function MjRecordFormContainerComponent_Conditional_14_Template_mj_record_tags_TagCountChanged_0_listener($event) { i0.ɵɵrestoreView(_r20); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnTagCountChanged($event)); })("RecordNavigate", function MjRecordFormContainerComponent_Conditional_14_Template_mj_record_tags_RecordNavigate_0_listener($event) { i0.ɵɵrestoreView(_r20); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnTagsRecordNavigate($event)); })("WidthChanged", function MjRecordFormContainerComponent_Conditional_14_Template_mj_record_tags_WidthChanged_0_listener($event) { i0.ɵɵrestoreView(_r20); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnTagsPanelWidthChanged($event)); });
|
|
65
301
|
i0.ɵɵelementEnd();
|
|
66
302
|
} if (rf & 2) {
|
|
67
303
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
68
304
|
i0.ɵɵproperty("Record", ctx_r1.EffectiveRecord)("WidthPx", ctx_r1.TagsPanelWidth);
|
|
69
305
|
} }
|
|
70
|
-
function
|
|
71
|
-
const
|
|
72
|
-
i0.ɵɵelementStart(0, "mj-
|
|
73
|
-
i0.ɵɵlistener("
|
|
306
|
+
function MjRecordFormContainerComponent_Conditional_15_Template(rf, ctx) { if (rf & 1) {
|
|
307
|
+
const _r21 = i0.ɵɵgetCurrentView();
|
|
308
|
+
i0.ɵɵelementStart(0, "mj-record-attachments", 49);
|
|
309
|
+
i0.ɵɵlistener("PanelClosed", function MjRecordFormContainerComponent_Conditional_15_Template_mj_record_attachments_PanelClosed_0_listener() { i0.ɵɵrestoreView(_r21); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnAttachmentsPanelClosed()); })("AttachmentCountChanged", function MjRecordFormContainerComponent_Conditional_15_Template_mj_record_attachments_AttachmentCountChanged_0_listener($event) { i0.ɵɵrestoreView(_r21); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnAttachmentCountChanged($event)); });
|
|
310
|
+
i0.ɵɵelementEnd();
|
|
311
|
+
} if (rf & 2) {
|
|
312
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
313
|
+
i0.ɵɵproperty("Record", ctx_r1.EffectiveRecord)("Visible", true);
|
|
314
|
+
} }
|
|
315
|
+
function MjRecordFormContainerComponent_Conditional_16_Template(rf, ctx) { if (rf & 1) {
|
|
316
|
+
const _r22 = i0.ɵɵgetCurrentView();
|
|
317
|
+
i0.ɵɵelementStart(0, "mj-list-management-dialog", 50);
|
|
318
|
+
i0.ɵɵlistener("complete", function MjRecordFormContainerComponent_Conditional_16_Template_mj_list_management_dialog_complete_0_listener($event) { i0.ɵɵrestoreView(_r22); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnListManagementComplete($event)); })("cancel", function MjRecordFormContainerComponent_Conditional_16_Template_mj_list_management_dialog_cancel_0_listener() { i0.ɵɵrestoreView(_r22); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnListManagementClosed()); });
|
|
74
319
|
i0.ɵɵelementEnd();
|
|
75
320
|
} if (rf & 2) {
|
|
76
321
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
@@ -110,8 +355,15 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
110
355
|
cdr = inject(ChangeDetectorRef);
|
|
111
356
|
ngZone = inject(NgZone);
|
|
112
357
|
notificationService = inject(MJNotificationService);
|
|
358
|
+
chrome = inject(FormChromeCoordinator);
|
|
359
|
+
slots = inject(FormSlotCoordinator);
|
|
360
|
+
recordRefresh = inject(FormRecordRefreshCoordinator);
|
|
361
|
+
host = inject((ElementRef));
|
|
113
362
|
destroy$ = new Subject();
|
|
114
363
|
panelNavReset$ = new Subject();
|
|
364
|
+
chromeResolveTimer = null;
|
|
365
|
+
chromeRules = [];
|
|
366
|
+
chromeRulesForEntityId = null;
|
|
115
367
|
// ---- Internal State ----
|
|
116
368
|
/** Reference to the record changes drawer (when visible) for triggering refresh after save */
|
|
117
369
|
recordChangesDrawer;
|
|
@@ -124,12 +376,30 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
124
376
|
static TAGS_WIDTH_KEY = 'MJ_TagsPanel_Width';
|
|
125
377
|
/** Number of tags on this record */
|
|
126
378
|
TagCount = 0;
|
|
379
|
+
/** Controls visibility of attachments slide panel */
|
|
380
|
+
ShowAttachmentsPanel = false;
|
|
381
|
+
/** Number of attachments linked to this record */
|
|
382
|
+
AttachmentCount = 0;
|
|
127
383
|
/** Number of tracked record change versions for this record */
|
|
128
384
|
VersionCount = 0;
|
|
129
385
|
/** Controls visibility of list management dialog */
|
|
130
386
|
ShowListManagement = false;
|
|
131
387
|
/** Controls visibility of section manager drawer */
|
|
132
388
|
ShowSectionManager = false;
|
|
389
|
+
/**
|
|
390
|
+
* Persisted per entity. Pinned (default) keeps the left rail open.
|
|
391
|
+
* Unpinned auto-collapses after the user picks another section.
|
|
392
|
+
*/
|
|
393
|
+
ChromeRailPinned = FORM_CHROME_RAIL_PINNED_DEFAULT;
|
|
394
|
+
/** Session-only: the rail is showing its items. Follows pin on load. */
|
|
395
|
+
chromeRailExpanded = FORM_CHROME_RAIL_PINNED_DEFAULT;
|
|
396
|
+
/** Expanded rail width in px. Persisted per entity. */
|
|
397
|
+
ChromeRailWidthPx = FORM_CHROME_RAIL_WIDTH_DEFAULT;
|
|
398
|
+
RailWidthMin = FORM_CHROME_RAIL_WIDTH_MIN;
|
|
399
|
+
RailWidthMax = FORM_CHROME_RAIL_WIDTH_MAX;
|
|
400
|
+
RailResizing = false;
|
|
401
|
+
railResizeStartX = 0;
|
|
402
|
+
railResizeStartWidth = FORM_CHROME_RAIL_WIDTH_DEFAULT;
|
|
133
403
|
// ---- Primary Inputs ----
|
|
134
404
|
/** The entity record being displayed/edited */
|
|
135
405
|
Record;
|
|
@@ -150,7 +420,10 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
150
420
|
DirtyFieldNames = [];
|
|
151
421
|
ListCount = 0;
|
|
152
422
|
IsSaving = false;
|
|
423
|
+
IsRefreshing = false;
|
|
153
424
|
ToolbarConfig = DEFAULT_TOOLBAR_CONFIG;
|
|
425
|
+
RegisteredToolbarItems = [];
|
|
426
|
+
ToolbarItemOverrides = null;
|
|
154
427
|
WidthMode = 'centered';
|
|
155
428
|
/**
|
|
156
429
|
* Variants available for this entity record. When more than one variant is
|
|
@@ -187,6 +460,10 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
187
460
|
BeforeDelete = new EventEmitter();
|
|
188
461
|
/** Emitted when delete is confirmed (host app handles actual deletion) */
|
|
189
462
|
DeleteRequested = new EventEmitter();
|
|
463
|
+
/** Emitted BEFORE refresh - can be cancelled by setting event.Cancel = true */
|
|
464
|
+
BeforeRefresh = new EventEmitter();
|
|
465
|
+
/** Emitted when refresh is requested (only in standalone mode) */
|
|
466
|
+
RefreshRequested = new EventEmitter();
|
|
190
467
|
/** Emitted when favorite toggle is requested */
|
|
191
468
|
FavoriteToggled = new EventEmitter();
|
|
192
469
|
/** Emitted BEFORE history view - can be cancelled by setting event.Cancel = true */
|
|
@@ -201,6 +478,8 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
201
478
|
ShowChangesRequested = new EventEmitter();
|
|
202
479
|
/** Emitted when a custom toolbar button is clicked */
|
|
203
480
|
CustomButtonClick = new EventEmitter();
|
|
481
|
+
/** Emitted when any toolbar item (standard or custom) is clicked */
|
|
482
|
+
ToolbarItemClick = new EventEmitter();
|
|
204
483
|
/**
|
|
205
484
|
* Emitted when the user chooses a different form variant from the picker.
|
|
206
485
|
* Carries the selected variant's override ID, or null when the user picks
|
|
@@ -209,6 +488,10 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
209
488
|
* the new form mounts.
|
|
210
489
|
*/
|
|
211
490
|
VariantChange = new EventEmitter();
|
|
491
|
+
BeforeLayoutResolve = new EventEmitter();
|
|
492
|
+
AfterLayoutResolved = new EventEmitter();
|
|
493
|
+
BeforeSectionActivate = new EventEmitter();
|
|
494
|
+
AfterSectionActivated = new EventEmitter();
|
|
212
495
|
// ---- Content Children ----
|
|
213
496
|
Panels;
|
|
214
497
|
// ---- FormComponent accessor ----
|
|
@@ -256,6 +539,9 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
256
539
|
get EffectiveIsSaving() {
|
|
257
540
|
return this.IsSaving;
|
|
258
541
|
}
|
|
542
|
+
get EffectiveIsRefreshing() {
|
|
543
|
+
return this.fc?.IsRefreshing ?? this.IsRefreshing;
|
|
544
|
+
}
|
|
259
545
|
get EffectiveWidthMode() {
|
|
260
546
|
if (this.fc?.getFormWidthMode) {
|
|
261
547
|
return this.fc.getFormWidthMode();
|
|
@@ -280,6 +566,18 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
280
566
|
get EffectiveToolbarConfig() {
|
|
281
567
|
return ResolveFormToolbarConfig(this.ToolbarConfig ?? DEFAULT_TOOLBAR_CONFIG, this.fc?.Config);
|
|
282
568
|
}
|
|
569
|
+
get EffectiveRegisteredToolbarItems() {
|
|
570
|
+
if (this.fc?.RegisteredToolbarItems && this.fc.RegisteredToolbarItems.length > 0) {
|
|
571
|
+
return this.fc.RegisteredToolbarItems;
|
|
572
|
+
}
|
|
573
|
+
return this.RegisteredToolbarItems;
|
|
574
|
+
}
|
|
575
|
+
get EffectiveToolbarItemOverrides() {
|
|
576
|
+
if (this.fc?.ToolbarItemOverrides && this.fc.ToolbarItemOverrides.size > 0) {
|
|
577
|
+
return this.fc.ToolbarItemOverrides;
|
|
578
|
+
}
|
|
579
|
+
return this.ToolbarItemOverrides;
|
|
580
|
+
}
|
|
283
581
|
get EffectiveSearchFilter() {
|
|
284
582
|
return this.fc?.searchFilter ?? '';
|
|
285
583
|
}
|
|
@@ -300,12 +598,124 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
300
598
|
return this.Panels?.length ?? 0;
|
|
301
599
|
}
|
|
302
600
|
get VisibleSectionCount() {
|
|
601
|
+
const filter = this.EffectiveSearchFilter.toLowerCase().trim();
|
|
602
|
+
if (filter) {
|
|
603
|
+
const fromPanels = this.allChromePanels().filter((p) => p.MatchesSearch(filter)).length;
|
|
604
|
+
const fromRail = this.ChromeFirstClassGroups.length + this.ChromeMoreItems.length;
|
|
605
|
+
return Math.max(fromPanels, fromRail);
|
|
606
|
+
}
|
|
303
607
|
if (this.fc?.getVisibleSectionCount) {
|
|
304
608
|
return this.fc.getVisibleSectionCount();
|
|
305
609
|
}
|
|
610
|
+
return this.Panels?.filter((p) => p.IsVisible).length ?? 0;
|
|
611
|
+
}
|
|
612
|
+
/** True when the current section search matches nothing in this layout. */
|
|
613
|
+
get SearchHasNoMatches() {
|
|
614
|
+
const filter = this.EffectiveSearchFilter.toLowerCase().trim();
|
|
615
|
+
if (!filter)
|
|
616
|
+
return false;
|
|
617
|
+
return this.ChromeFirstClassGroups.length === 0 && this.ChromeMoreItems.length === 0
|
|
618
|
+
&& this.allChromePanels().every((p) => !p.MatchesSearch(filter));
|
|
619
|
+
}
|
|
620
|
+
/** Left-nav rail stays up while searching even if only one group matches. */
|
|
621
|
+
get ShowChromeRail() {
|
|
622
|
+
if (this.ChromeLayout !== 'left-nav')
|
|
623
|
+
return false;
|
|
624
|
+
if (this.EffectiveSearchFilter.trim()) {
|
|
625
|
+
return this.ChromeFirstClassGroups.length > 0 || this.ChromeMoreItems.length > 0;
|
|
626
|
+
}
|
|
627
|
+
return this.chrome.Spec.Groups.length > 1;
|
|
628
|
+
}
|
|
629
|
+
/**
|
|
630
|
+
* SectionKeys of related-entity panels projected into the container
|
|
631
|
+
* (CodeGen-baked or hand-written). View-children we mount as fill-ins are
|
|
632
|
+
* not in this ContentChildren list.
|
|
633
|
+
*/
|
|
634
|
+
get BakedRelatedSectionKeys() {
|
|
306
635
|
if (!this.Panels)
|
|
307
|
-
return
|
|
308
|
-
return this.Panels
|
|
636
|
+
return [];
|
|
637
|
+
return this.Panels
|
|
638
|
+
.filter((panel) => panel.Variant === 'related-entity' && !!panel.SectionKey)
|
|
639
|
+
.map((panel) => panel.SectionKey);
|
|
640
|
+
}
|
|
641
|
+
get EffectiveShowRelatedEntities() {
|
|
642
|
+
return this.fc?.Config?.ShowRelatedEntities !== false;
|
|
643
|
+
}
|
|
644
|
+
get ChromeLayout() {
|
|
645
|
+
return this.chrome.Spec.Layout;
|
|
646
|
+
}
|
|
647
|
+
get ChromeGroups() {
|
|
648
|
+
const ordered = OrderChromeGroups(this.chrome.Spec.Groups, this.chromeRailOrder);
|
|
649
|
+
const filter = this.EffectiveSearchFilter.toLowerCase().trim();
|
|
650
|
+
if (!filter)
|
|
651
|
+
return ordered;
|
|
652
|
+
return ordered.filter((group) => this.groupMatchesSearch(group, filter));
|
|
653
|
+
}
|
|
654
|
+
get ChromeFirstClassGroups() {
|
|
655
|
+
return this.ChromeGroups.filter((group) => !group.IsMore);
|
|
656
|
+
}
|
|
657
|
+
get ChromeMoreFolder() {
|
|
658
|
+
const folder = this.ChromeGroups.find((group) => group.IsMore) ?? null;
|
|
659
|
+
if (!folder || folder.SectionKeys.length === 0)
|
|
660
|
+
return null;
|
|
661
|
+
return folder;
|
|
662
|
+
}
|
|
663
|
+
get ChromeMoreItems() {
|
|
664
|
+
const folder = this.ChromeMoreFolder;
|
|
665
|
+
if (!folder)
|
|
666
|
+
return [];
|
|
667
|
+
const filter = this.EffectiveSearchFilter.toLowerCase().trim();
|
|
668
|
+
const orderedKeys = OrderMoreSectionKeys(folder.SectionKeys, this.chromeRailOrder);
|
|
669
|
+
const items = orderedKeys.map((key) => this.moreItemFromKey(key));
|
|
670
|
+
if (!filter)
|
|
671
|
+
return items;
|
|
672
|
+
return items.filter((item) => this.groupMatchesSearch(item, filter));
|
|
673
|
+
}
|
|
674
|
+
get ChromeActiveGroupKey() {
|
|
675
|
+
return this.chrome.ActiveGroupKey;
|
|
676
|
+
}
|
|
677
|
+
get ChromeActiveGroup() {
|
|
678
|
+
const key = this.ChromeActiveGroupKey;
|
|
679
|
+
if (!key) {
|
|
680
|
+
return null;
|
|
681
|
+
}
|
|
682
|
+
return this.ChromeFirstClassGroups.find((group) => group.Key === key)
|
|
683
|
+
?? this.ChromeMoreItems.find((item) => item.Key === key)
|
|
684
|
+
?? null;
|
|
685
|
+
}
|
|
686
|
+
get ChromeActiveTitle() {
|
|
687
|
+
return this.ChromeActiveGroup?.Title || 'Sections';
|
|
688
|
+
}
|
|
689
|
+
get ChromeActiveIcon() {
|
|
690
|
+
return this.ChromeActiveGroup?.Icon || 'fa-solid fa-list';
|
|
691
|
+
}
|
|
692
|
+
/**
|
|
693
|
+
* True when the rail is the thin rotated strip. Search keeps the full
|
|
694
|
+
* list visible so matches stay clickable.
|
|
695
|
+
*/
|
|
696
|
+
get ChromeRailCollapsed() {
|
|
697
|
+
if (!this.ShowChromeRail) {
|
|
698
|
+
return false;
|
|
699
|
+
}
|
|
700
|
+
if (this.EffectiveSearchFilter.trim()) {
|
|
701
|
+
return false;
|
|
702
|
+
}
|
|
703
|
+
return !this.chromeRailExpanded;
|
|
704
|
+
}
|
|
705
|
+
get IsChromeMoreActive() {
|
|
706
|
+
return this.chrome.IsMoreActive;
|
|
707
|
+
}
|
|
708
|
+
get ChromeReorderAllowed() {
|
|
709
|
+
return this.fc?.formContext?.allowSectionReorder !== false;
|
|
710
|
+
}
|
|
711
|
+
get ShowMoreToggle() {
|
|
712
|
+
return this.chrome.Spec.Layout === 'accordion' && this.ChromeMoreItems.length > 0;
|
|
713
|
+
}
|
|
714
|
+
get MoreExpanded() {
|
|
715
|
+
return this.chrome.MoreExpanded;
|
|
716
|
+
}
|
|
717
|
+
get MorePreview() {
|
|
718
|
+
return this.ChromeMoreItems.map((item) => item.Title).join(' · ');
|
|
309
719
|
}
|
|
310
720
|
get ExpandedSectionCount() {
|
|
311
721
|
if (this.fc?.getExpandedCount) {
|
|
@@ -340,15 +750,21 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
340
750
|
// ---- Section Manager ----
|
|
341
751
|
/** Builds section info array from projected panels for the section manager drawer */
|
|
342
752
|
get SectionManagerItems() {
|
|
343
|
-
|
|
344
|
-
return [];
|
|
345
|
-
return this.Panels.map(p => ({
|
|
753
|
+
return this.chromePanelSnapshots().map((p) => ({
|
|
346
754
|
SectionKey: p.SectionKey,
|
|
347
|
-
SectionName: p.SectionName,
|
|
348
|
-
Variant: p.Variant,
|
|
349
|
-
Icon: p.Icon
|
|
755
|
+
SectionName: HumanizeEntityTitle(p.SectionName),
|
|
756
|
+
Variant: (p.Variant || 'default'),
|
|
757
|
+
Icon: p.Icon || 'fa-solid fa-table',
|
|
350
758
|
}));
|
|
351
759
|
}
|
|
760
|
+
get SectionManagerMoreKeys() {
|
|
761
|
+
return this.chrome.Spec.MoreSectionKeys;
|
|
762
|
+
}
|
|
763
|
+
get SectionManagerLockedMoreKeys() {
|
|
764
|
+
return this.chromePanelSnapshots()
|
|
765
|
+
.filter((p) => IsAlwaysMoreSection(p.SectionKey, p.SectionName))
|
|
766
|
+
.map((p) => p.SectionKey);
|
|
767
|
+
}
|
|
352
768
|
/** Current section order from the form component */
|
|
353
769
|
get SectionManagerOrder() {
|
|
354
770
|
if (this.fc?.getSectionOrder) {
|
|
@@ -356,6 +772,15 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
356
772
|
}
|
|
357
773
|
return [];
|
|
358
774
|
}
|
|
775
|
+
/**
|
|
776
|
+
* Rail display order. `getSectionOrder()` falls back to generated
|
|
777
|
+
* `form.sections` — those keys match Details + baked related grids, not
|
|
778
|
+
* slot-mounted leads — so using that fallback parked Overview after
|
|
779
|
+
* Payments. Only a user-persisted custom order may override the resolver.
|
|
780
|
+
*/
|
|
781
|
+
get chromeRailOrder() {
|
|
782
|
+
return this.EffectiveHasCustomSectionOrder ? this.SectionManagerOrder : [];
|
|
783
|
+
}
|
|
359
784
|
// ---- Lifecycle ----
|
|
360
785
|
ngAfterContentInit() {
|
|
361
786
|
// Load saved tags panel width
|
|
@@ -367,18 +792,556 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
367
792
|
// Watch for panel changes to update counts and re-subscribe
|
|
368
793
|
this.Panels.changes.pipe(takeUntil(this.destroy$)).subscribe(() => {
|
|
369
794
|
this.SubscribeToPanelNavigateEvents();
|
|
795
|
+
this.scheduleChromeResolve();
|
|
370
796
|
this.cdr.markForCheck();
|
|
371
797
|
});
|
|
798
|
+
// Slot remounts land after content init and are not ContentChildren —
|
|
799
|
+
// rebuild the rail from the live DOM once they exist.
|
|
800
|
+
this.slots.changes.pipe(takeUntil(this.destroy$)).subscribe(() => {
|
|
801
|
+
this.scheduleChromeResolve();
|
|
802
|
+
});
|
|
803
|
+
this.RestoreChromePrefs();
|
|
804
|
+
this.scheduleChromeResolve();
|
|
372
805
|
// Watch for changes to record dirty state
|
|
373
806
|
this.watchRecordChanges();
|
|
374
|
-
// Badge counts are loaded when the form emits RecordReady (see SubscribeToPanelNavigateEvents)
|
|
375
807
|
}
|
|
376
808
|
ngOnDestroy() {
|
|
809
|
+
if (this.chromeResolveTimer) {
|
|
810
|
+
clearTimeout(this.chromeResolveTimer);
|
|
811
|
+
this.chromeResolveTimer = null;
|
|
812
|
+
}
|
|
377
813
|
this.panelNavReset$.next();
|
|
378
814
|
this.panelNavReset$.complete();
|
|
379
815
|
this.destroy$.next();
|
|
380
816
|
this.destroy$.complete();
|
|
381
817
|
}
|
|
818
|
+
OnMoreFolderToggle() {
|
|
819
|
+
this.chrome.ToggleMoreFolder();
|
|
820
|
+
this.PersistChromePrefs();
|
|
821
|
+
this.cdr.detectChanges();
|
|
822
|
+
}
|
|
823
|
+
ChromeGroupRowCount(group) {
|
|
824
|
+
if (!this.fc?.GetSectionRowCount)
|
|
825
|
+
return undefined;
|
|
826
|
+
let total = 0;
|
|
827
|
+
let any = false;
|
|
828
|
+
for (const key of group.SectionKeys) {
|
|
829
|
+
const count = this.fc.GetSectionRowCount(key);
|
|
830
|
+
if (count !== undefined) {
|
|
831
|
+
total += count;
|
|
832
|
+
any = true;
|
|
833
|
+
}
|
|
834
|
+
}
|
|
835
|
+
return any ? total : undefined;
|
|
836
|
+
}
|
|
837
|
+
OnChromeGroupActivate(groupKey) {
|
|
838
|
+
const before = new BeforeSectionActivateEventArgs(groupKey);
|
|
839
|
+
this.BeforeSectionActivate.emit(before);
|
|
840
|
+
if (before.Cancel)
|
|
841
|
+
return;
|
|
842
|
+
const previous = this.chrome.ActiveGroupKey;
|
|
843
|
+
this.chrome.SetActiveGroup(groupKey);
|
|
844
|
+
this.expandActiveGroupSections(groupKey);
|
|
845
|
+
this.applyChromeVisibility();
|
|
846
|
+
if (!this.ChromeRailPinned && previous !== groupKey) {
|
|
847
|
+
this.chromeRailExpanded = false;
|
|
848
|
+
}
|
|
849
|
+
this.PersistChromePrefs();
|
|
850
|
+
this.AfterSectionActivated.emit(new AfterSectionActivatedEventArgs(groupKey));
|
|
851
|
+
this.cdr.detectChanges();
|
|
852
|
+
}
|
|
853
|
+
OnChromeRailExpand() {
|
|
854
|
+
this.chromeRailExpanded = true;
|
|
855
|
+
this.cdr.detectChanges();
|
|
856
|
+
}
|
|
857
|
+
OnChromeRailCollapse() {
|
|
858
|
+
this.chromeRailExpanded = false;
|
|
859
|
+
this.cdr.detectChanges();
|
|
860
|
+
}
|
|
861
|
+
OnChromeRailPinToggle() {
|
|
862
|
+
this.ChromeRailPinned = !this.ChromeRailPinned;
|
|
863
|
+
if (this.ChromeRailPinned) {
|
|
864
|
+
this.chromeRailExpanded = true;
|
|
865
|
+
}
|
|
866
|
+
this.PersistChromePrefs();
|
|
867
|
+
this.cdr.detectChanges();
|
|
868
|
+
}
|
|
869
|
+
OnRailResizeStart(event) {
|
|
870
|
+
if (this.ChromeRailCollapsed)
|
|
871
|
+
return;
|
|
872
|
+
event.preventDefault();
|
|
873
|
+
event.stopPropagation();
|
|
874
|
+
this.RailResizing = true;
|
|
875
|
+
this.railResizeStartX = event.clientX;
|
|
876
|
+
this.railResizeStartWidth = this.ChromeRailWidthPx;
|
|
877
|
+
event.target.setPointerCapture(event.pointerId);
|
|
878
|
+
}
|
|
879
|
+
OnRailResizeMove(event) {
|
|
880
|
+
if (!this.RailResizing)
|
|
881
|
+
return;
|
|
882
|
+
const delta = event.clientX - this.railResizeStartX;
|
|
883
|
+
const signed = this.ChromeLayout === 'left-nav' ? delta : -delta;
|
|
884
|
+
this.ChromeRailWidthPx = ClampRailWidth(this.railResizeStartWidth + signed);
|
|
885
|
+
this.cdr.markForCheck();
|
|
886
|
+
}
|
|
887
|
+
OnRailResizeEnd() {
|
|
888
|
+
if (!this.RailResizing)
|
|
889
|
+
return;
|
|
890
|
+
this.RailResizing = false;
|
|
891
|
+
this.PersistChromePrefs();
|
|
892
|
+
this.cdr.detectChanges();
|
|
893
|
+
}
|
|
894
|
+
OnRailLabelHover(event, text) {
|
|
895
|
+
ApplyClippedTitle(event.currentTarget, text);
|
|
896
|
+
}
|
|
897
|
+
RailDragOverKey = null;
|
|
898
|
+
OnRailDragStart(event, groupKey) {
|
|
899
|
+
if (!this.ChromeReorderAllowed)
|
|
900
|
+
return;
|
|
901
|
+
event.stopPropagation();
|
|
902
|
+
event.dataTransfer?.setData('text/plain', groupKey);
|
|
903
|
+
if (event.dataTransfer)
|
|
904
|
+
event.dataTransfer.effectAllowed = 'move';
|
|
905
|
+
}
|
|
906
|
+
OnRailDragEnd() {
|
|
907
|
+
this.RailDragOverKey = null;
|
|
908
|
+
this.cdr.markForCheck();
|
|
909
|
+
}
|
|
910
|
+
OnRailDragOver(event, groupKey) {
|
|
911
|
+
if (!this.ChromeReorderAllowed)
|
|
912
|
+
return;
|
|
913
|
+
event.preventDefault();
|
|
914
|
+
if (event.dataTransfer)
|
|
915
|
+
event.dataTransfer.dropEffect = 'move';
|
|
916
|
+
if (this.RailDragOverKey !== groupKey) {
|
|
917
|
+
this.RailDragOverKey = groupKey;
|
|
918
|
+
this.cdr.markForCheck();
|
|
919
|
+
}
|
|
920
|
+
}
|
|
921
|
+
OnRailDragLeave(_event, groupKey) {
|
|
922
|
+
if (this.RailDragOverKey === groupKey) {
|
|
923
|
+
this.RailDragOverKey = null;
|
|
924
|
+
this.cdr.markForCheck();
|
|
925
|
+
}
|
|
926
|
+
}
|
|
927
|
+
OnRailDrop(event, targetKey) {
|
|
928
|
+
if (!this.ChromeReorderAllowed)
|
|
929
|
+
return;
|
|
930
|
+
event.preventDefault();
|
|
931
|
+
this.RailDragOverKey = null;
|
|
932
|
+
const draggedKey = event.dataTransfer?.getData('text/plain');
|
|
933
|
+
if (!draggedKey || draggedKey === targetKey)
|
|
934
|
+
return;
|
|
935
|
+
const groups = this.ChromeGroups;
|
|
936
|
+
const moreItems = this.ChromeMoreItems;
|
|
937
|
+
const draggedMore = moreItems.find((item) => item.Key === draggedKey);
|
|
938
|
+
const targetMore = moreItems.find((item) => item.Key === targetKey);
|
|
939
|
+
const dragged = draggedMore ?? groups.find((g) => g.Key === draggedKey);
|
|
940
|
+
const target = targetMore ?? groups.find((g) => g.Key === targetKey);
|
|
941
|
+
if (!dragged || !target)
|
|
942
|
+
return;
|
|
943
|
+
if (!draggedMore && (dragged.IsMore || target.IsMore))
|
|
944
|
+
return;
|
|
945
|
+
if (!!draggedMore !== !!targetMore)
|
|
946
|
+
return;
|
|
947
|
+
const defaultKeys = [
|
|
948
|
+
...groups.filter((g) => !g.IsMore).flatMap((g) => g.SectionKeys),
|
|
949
|
+
...moreItems.flatMap((g) => g.SectionKeys),
|
|
950
|
+
];
|
|
951
|
+
const current = OverlayChromeSectionOrder(defaultKeys, this.EffectiveHasCustomSectionOrder ? this.SectionManagerOrder : []);
|
|
952
|
+
const next = MoveChromeGroupInSectionOrder(current, dragged, target);
|
|
953
|
+
if (this.fc?.setSectionOrder) {
|
|
954
|
+
this.fc.setSectionOrder(next);
|
|
955
|
+
this.cdr.detectChanges();
|
|
956
|
+
}
|
|
957
|
+
}
|
|
958
|
+
OnMoreToggle() {
|
|
959
|
+
const next = !this.chrome.MoreExpanded;
|
|
960
|
+
const before = new BeforeSectionActivateEventArgs(MORE_SECTION_KEY);
|
|
961
|
+
this.BeforeSectionActivate.emit(before);
|
|
962
|
+
if (before.Cancel)
|
|
963
|
+
return;
|
|
964
|
+
this.chrome.ToggleMore(next);
|
|
965
|
+
this.applyChromeVisibility();
|
|
966
|
+
this.PersistChromePrefs();
|
|
967
|
+
this.AfterSectionActivated.emit(new AfterSectionActivatedEventArgs(MORE_SECTION_KEY));
|
|
968
|
+
this.cdr.detectChanges();
|
|
969
|
+
}
|
|
970
|
+
scheduleChromeResolve() {
|
|
971
|
+
if (this.chromeResolveTimer) {
|
|
972
|
+
clearTimeout(this.chromeResolveTimer);
|
|
973
|
+
}
|
|
974
|
+
this.chromeResolveTimer = setTimeout(() => {
|
|
975
|
+
this.chromeResolveTimer = null;
|
|
976
|
+
this.ResolveChrome();
|
|
977
|
+
this.applyChromeVisibility();
|
|
978
|
+
this.cdr.markForCheck();
|
|
979
|
+
}, 0);
|
|
980
|
+
}
|
|
981
|
+
loadChromeRulesIfNeeded() {
|
|
982
|
+
const entityId = this.EffectiveEntityInfo?.ID ?? null;
|
|
983
|
+
if (!entityId || this.chromeRulesForEntityId === entityId)
|
|
984
|
+
return;
|
|
985
|
+
this.chromeRulesForEntityId = entityId;
|
|
986
|
+
void this.loadChromeRules(entityId);
|
|
987
|
+
}
|
|
988
|
+
async loadChromeRules(entityId) {
|
|
989
|
+
const rules = await LoadFormChromeRules(entityId, this.ProviderToUse);
|
|
990
|
+
if (this.chromeRulesForEntityId !== entityId)
|
|
991
|
+
return;
|
|
992
|
+
this.chromeRules = rules;
|
|
993
|
+
this.scheduleChromeResolve();
|
|
994
|
+
}
|
|
995
|
+
ResolveChrome() {
|
|
996
|
+
const entity = this.EffectiveEntityInfo;
|
|
997
|
+
if (!entity)
|
|
998
|
+
return;
|
|
999
|
+
this.loadChromeRulesIfNeeded();
|
|
1000
|
+
const result = ResolveFormChrome({
|
|
1001
|
+
Entity: entity,
|
|
1002
|
+
Panels: this.chromePanelSnapshots(),
|
|
1003
|
+
RelatedSchemaByEntityId: this.buildRelatedSchemaMap(entity),
|
|
1004
|
+
InboundRelationshipCountByEntityId: this.buildInboundRelationshipCounts(),
|
|
1005
|
+
HiddenSectionKeys: [...this.contributionHiddenSectionKeys()],
|
|
1006
|
+
ContributionSectionKeys: this.contributionSectionKeys(),
|
|
1007
|
+
ContributionChromeGroupByKey: this.contributionChromeGroupByKey(),
|
|
1008
|
+
ContributionInclusionByKey: this.contributionInclusionByKey(),
|
|
1009
|
+
ContributionSortKeyByKey: this.contributionSortKeyByKey(),
|
|
1010
|
+
ChromeRules: this.chromeRules,
|
|
1011
|
+
IncludeUnbakedRelated: this.EffectiveShowRelatedEntities,
|
|
1012
|
+
Membership: {
|
|
1013
|
+
moreSectionKeys: this.fc?.getMoreSectionKeys?.() ?? [],
|
|
1014
|
+
firstClassSectionKeys: this.fc?.getFirstClassSectionKeys?.() ?? [],
|
|
1015
|
+
},
|
|
1016
|
+
});
|
|
1017
|
+
const before = new BeforeLayoutResolveEventArgs(result.Spec.Layout);
|
|
1018
|
+
this.BeforeLayoutResolve.emit(before);
|
|
1019
|
+
if (before.Cancel)
|
|
1020
|
+
return;
|
|
1021
|
+
this.chrome.Apply(result.Spec);
|
|
1022
|
+
this.ensureActiveGroupVisible();
|
|
1023
|
+
if (this.chrome.ActiveGroupKey) {
|
|
1024
|
+
this.expandActiveGroupSections(this.chrome.ActiveGroupKey);
|
|
1025
|
+
}
|
|
1026
|
+
this.AfterLayoutResolved.emit(new AfterLayoutResolvedEventArgs(result.Spec.Layout));
|
|
1027
|
+
}
|
|
1028
|
+
expandActiveGroupSections(groupKey) {
|
|
1029
|
+
if (groupKey === MORE_SECTION_KEY)
|
|
1030
|
+
return;
|
|
1031
|
+
const group = this.chrome.Spec.Groups.find((g) => g.Key === groupKey);
|
|
1032
|
+
const keys = group && !group.IsMore ? group.SectionKeys : [groupKey];
|
|
1033
|
+
const form = this.fc;
|
|
1034
|
+
if (!form?.SetSectionExpanded)
|
|
1035
|
+
return;
|
|
1036
|
+
for (const key of keys) {
|
|
1037
|
+
form.SetSectionExpanded(key, true);
|
|
1038
|
+
}
|
|
1039
|
+
}
|
|
1040
|
+
ensureActiveGroupVisible() {
|
|
1041
|
+
const firstClass = this.ChromeFirstClassGroups;
|
|
1042
|
+
const moreItems = this.ChromeMoreItems;
|
|
1043
|
+
const active = this.chrome.ActiveGroupKey;
|
|
1044
|
+
if (active && moreItems.some((item) => item.Key === active)) {
|
|
1045
|
+
this.chrome.MoreExpanded = true;
|
|
1046
|
+
return;
|
|
1047
|
+
}
|
|
1048
|
+
if (active && firstClass.some((g) => g.Key === active))
|
|
1049
|
+
return;
|
|
1050
|
+
const next = firstClass[0] ?? moreItems[0];
|
|
1051
|
+
if (next)
|
|
1052
|
+
this.chrome.SetActiveGroup(next.Key);
|
|
1053
|
+
}
|
|
1054
|
+
groupMatchesSearch(group, filter) {
|
|
1055
|
+
if (!filter)
|
|
1056
|
+
return true;
|
|
1057
|
+
if (group.Title.toLowerCase().includes(filter))
|
|
1058
|
+
return true;
|
|
1059
|
+
if (group.IsMore) {
|
|
1060
|
+
return group.SectionKeys.some((key) => {
|
|
1061
|
+
const item = this.moreItemFromKey(key);
|
|
1062
|
+
return this.groupMatchesSearch({ ...item, IsMore: false }, filter);
|
|
1063
|
+
});
|
|
1064
|
+
}
|
|
1065
|
+
return group.SectionKeys.some((key) => {
|
|
1066
|
+
const panel = this.allChromePanels().find((p) => p.SectionKey === key);
|
|
1067
|
+
if (panel)
|
|
1068
|
+
return panel.MatchesSearch(filter);
|
|
1069
|
+
const human = HumanizeEntityTitle(key).toLowerCase();
|
|
1070
|
+
return human.includes(filter) || key.toLowerCase().includes(filter);
|
|
1071
|
+
});
|
|
1072
|
+
}
|
|
1073
|
+
moreItemFromKey(key) {
|
|
1074
|
+
const panel = this.allChromePanels().find((p) => p.SectionKey === key);
|
|
1075
|
+
const override = this.chrome.Spec.TitleBySectionKey?.get(key);
|
|
1076
|
+
return {
|
|
1077
|
+
Key: key,
|
|
1078
|
+
Title: override || HumanizeEntityTitle(panel?.SectionName || key),
|
|
1079
|
+
Icon: panel?.Icon || 'fa-solid fa-table',
|
|
1080
|
+
SectionKeys: [key],
|
|
1081
|
+
IsMore: true,
|
|
1082
|
+
};
|
|
1083
|
+
}
|
|
1084
|
+
allChromePanels() {
|
|
1085
|
+
const seen = new Set();
|
|
1086
|
+
const out = [];
|
|
1087
|
+
const add = (list) => {
|
|
1088
|
+
list?.forEach((panel) => {
|
|
1089
|
+
if (!seen.has(panel)) {
|
|
1090
|
+
seen.add(panel);
|
|
1091
|
+
out.push(panel);
|
|
1092
|
+
}
|
|
1093
|
+
});
|
|
1094
|
+
};
|
|
1095
|
+
add(this.Panels);
|
|
1096
|
+
return out;
|
|
1097
|
+
}
|
|
1098
|
+
applyChromeVisibility() {
|
|
1099
|
+
const layout = this.chrome.Spec.Layout;
|
|
1100
|
+
const claimed = this.contributionHiddenSectionKeys();
|
|
1101
|
+
for (const panel of this.allChromePanels()) {
|
|
1102
|
+
if (panel.SectionName) {
|
|
1103
|
+
const human = HumanizeEntityTitle(panel.SectionName);
|
|
1104
|
+
if (human !== panel.SectionName) {
|
|
1105
|
+
panel.SectionName = human;
|
|
1106
|
+
}
|
|
1107
|
+
}
|
|
1108
|
+
const titled = this.chrome.Spec.Groups.find((g) => !g.IsMore && g.SectionKeys.length === 1 && g.SectionKeys[0] === panel.SectionKey);
|
|
1109
|
+
const override = this.chrome.Spec.TitleBySectionKey?.get(panel.SectionKey);
|
|
1110
|
+
if (override) {
|
|
1111
|
+
panel.SectionName = override;
|
|
1112
|
+
}
|
|
1113
|
+
else if (titled?.Title) {
|
|
1114
|
+
panel.SectionName = titled.Title;
|
|
1115
|
+
}
|
|
1116
|
+
if (claimed.has(panel.SectionKey)) {
|
|
1117
|
+
panel.Hidden = true;
|
|
1118
|
+
continue;
|
|
1119
|
+
}
|
|
1120
|
+
if (layout === 'left-nav') {
|
|
1121
|
+
if (panel.Variant === 'related-entity') {
|
|
1122
|
+
panel.Hidden = !this.chrome.IsRelatedSectionVisible(panel.SectionKey);
|
|
1123
|
+
}
|
|
1124
|
+
else {
|
|
1125
|
+
panel.Hidden = !this.chrome.IsFirstClassSectionVisible(panel.SectionKey);
|
|
1126
|
+
}
|
|
1127
|
+
}
|
|
1128
|
+
else {
|
|
1129
|
+
panel.Hidden = !this.chrome.IsAccordionSectionVisible(panel.SectionKey);
|
|
1130
|
+
}
|
|
1131
|
+
}
|
|
1132
|
+
this.applyChromeDomVisibility();
|
|
1133
|
+
}
|
|
1134
|
+
/**
|
|
1135
|
+
* Slot-mounted panels are view children of the slot, not ContentChildren
|
|
1136
|
+
* of this container, and they cannot inject the container-provided
|
|
1137
|
+
* coordinator. Toggle host classes on every `mj-collapsible-panel` in
|
|
1138
|
+
* the live DOM so left-nav hide/show still reaches them.
|
|
1139
|
+
*/
|
|
1140
|
+
applyChromeDomVisibility() {
|
|
1141
|
+
const host = this.host.nativeElement;
|
|
1142
|
+
if (!host)
|
|
1143
|
+
return;
|
|
1144
|
+
const layout = this.chrome.Spec.Layout;
|
|
1145
|
+
host.querySelectorAll('mj-collapsible-panel').forEach((node) => {
|
|
1146
|
+
const key = node.getAttribute('data-section-key') ?? '';
|
|
1147
|
+
const variant = node.getAttribute('data-variant') ?? 'default';
|
|
1148
|
+
const visible = this.isChromeKeyVisible(key, variant);
|
|
1149
|
+
const inMore = this.chrome.Spec.MoreSectionKeys.includes(key);
|
|
1150
|
+
node.classList.toggle('mj-chrome-show', layout === 'left-nav' && visible);
|
|
1151
|
+
node.classList.toggle('mj-chrome-hidden', !visible);
|
|
1152
|
+
node.classList.toggle('mj-form-role-more', inMore);
|
|
1153
|
+
});
|
|
1154
|
+
}
|
|
1155
|
+
isChromeKeyVisible(sectionKey, variant) {
|
|
1156
|
+
if (this.contributionHiddenSectionKeys().has(sectionKey))
|
|
1157
|
+
return false;
|
|
1158
|
+
if (this.chrome.Spec.Layout === 'accordion') {
|
|
1159
|
+
return this.chrome.IsAccordionSectionVisible(sectionKey);
|
|
1160
|
+
}
|
|
1161
|
+
if (variant === 'related-entity') {
|
|
1162
|
+
return this.chrome.IsRelatedSectionVisible(sectionKey);
|
|
1163
|
+
}
|
|
1164
|
+
return this.chrome.IsFirstClassSectionVisible(sectionKey);
|
|
1165
|
+
}
|
|
1166
|
+
contributionSectionKeys() {
|
|
1167
|
+
return this.contributionRegistrations().map((row) => row.Key);
|
|
1168
|
+
}
|
|
1169
|
+
contributionChromeGroupByKey() {
|
|
1170
|
+
const map = new Map();
|
|
1171
|
+
for (const row of this.contributionRegistrations()) {
|
|
1172
|
+
if (row.ChromeGroup)
|
|
1173
|
+
map.set(row.Key, row.ChromeGroup);
|
|
1174
|
+
}
|
|
1175
|
+
return map;
|
|
1176
|
+
}
|
|
1177
|
+
contributionInclusionByKey() {
|
|
1178
|
+
const map = new Map();
|
|
1179
|
+
for (const row of this.contributionRegistrations()) {
|
|
1180
|
+
if (row.Inclusion)
|
|
1181
|
+
map.set(row.Key, row.Inclusion);
|
|
1182
|
+
}
|
|
1183
|
+
return map;
|
|
1184
|
+
}
|
|
1185
|
+
contributionSortKeyByKey() {
|
|
1186
|
+
const map = new Map();
|
|
1187
|
+
for (const row of this.contributionRegistrations()) {
|
|
1188
|
+
if (row.SortKey != null)
|
|
1189
|
+
map.set(row.Key, row.SortKey);
|
|
1190
|
+
}
|
|
1191
|
+
return map;
|
|
1192
|
+
}
|
|
1193
|
+
/**
|
|
1194
|
+
* Winning registration per contribution key (highest ClassFactory Priority).
|
|
1195
|
+
* Headers are not rail sections.
|
|
1196
|
+
*/
|
|
1197
|
+
contributionRegistrations() {
|
|
1198
|
+
const entityName = this.EffectiveEntityInfo?.Name;
|
|
1199
|
+
if (!entityName)
|
|
1200
|
+
return [];
|
|
1201
|
+
const byKey = new Map();
|
|
1202
|
+
const regs = [...CollectFormPanelRegistrations()].sort((a, b) => (a.Priority ?? 0) - (b.Priority ?? 0));
|
|
1203
|
+
for (const reg of regs) {
|
|
1204
|
+
const meta = reg.Metadata;
|
|
1205
|
+
if (!meta || meta.entity !== entityName)
|
|
1206
|
+
continue;
|
|
1207
|
+
if (meta.contributionKey === 'header')
|
|
1208
|
+
continue;
|
|
1209
|
+
const key = contributionRailKey(meta);
|
|
1210
|
+
if (!key)
|
|
1211
|
+
continue;
|
|
1212
|
+
byKey.set(key, {
|
|
1213
|
+
Key: key,
|
|
1214
|
+
Inclusion: ReadRegisteredInclusion(meta.inclusion),
|
|
1215
|
+
SortKey: typeof meta.sortKey === 'number' && Number.isFinite(meta.sortKey) ? meta.sortKey : null,
|
|
1216
|
+
ChromeGroup: meta.chromeGroup === 'details' || meta.chromeGroup === 'more' ? meta.chromeGroup : null,
|
|
1217
|
+
Priority: reg.Priority ?? 0,
|
|
1218
|
+
});
|
|
1219
|
+
}
|
|
1220
|
+
return [...byKey.values()];
|
|
1221
|
+
}
|
|
1222
|
+
contributionHiddenSectionKeys() {
|
|
1223
|
+
const hidden = this.hiddenChromeSectionKeys();
|
|
1224
|
+
const entity = this.EffectiveEntityInfo;
|
|
1225
|
+
if (!entity)
|
|
1226
|
+
return hidden;
|
|
1227
|
+
const claimed = ContributionHiddenSectionKeys(entity.Name, entity.RelatedEntities ?? [], (entity.ChildEntities ?? []).map((child) => child.ID), CollectFormPanelRegistrations());
|
|
1228
|
+
for (const key of claimed)
|
|
1229
|
+
hidden.add(key);
|
|
1230
|
+
return hidden;
|
|
1231
|
+
}
|
|
1232
|
+
chromePanelSnapshots() {
|
|
1233
|
+
const skip = this.contributionHiddenSectionKeys();
|
|
1234
|
+
const ctx = this.fc?.formContext;
|
|
1235
|
+
const byKey = new Map();
|
|
1236
|
+
const add = (snapshot) => {
|
|
1237
|
+
if (!snapshot.SectionKey || skip.has(snapshot.SectionKey))
|
|
1238
|
+
return;
|
|
1239
|
+
if (IsFormSectionHidden(ctx, snapshot.SectionKey, snapshot.Variant))
|
|
1240
|
+
return;
|
|
1241
|
+
if (!byKey.has(snapshot.SectionKey)) {
|
|
1242
|
+
byKey.set(snapshot.SectionKey, snapshot);
|
|
1243
|
+
}
|
|
1244
|
+
};
|
|
1245
|
+
for (const panel of this.allChromePanels()) {
|
|
1246
|
+
// Include hidden field panels so Details still groups them. Left-nav
|
|
1247
|
+
// otherwise drops ungrouped leftovers and the Details rail looks empty.
|
|
1248
|
+
add({
|
|
1249
|
+
SectionKey: panel.SectionKey,
|
|
1250
|
+
SectionName: panel.SectionName,
|
|
1251
|
+
Variant: panel.Variant,
|
|
1252
|
+
Icon: panel.Icon,
|
|
1253
|
+
});
|
|
1254
|
+
}
|
|
1255
|
+
for (const snapshot of this.domPanelSnapshots()) {
|
|
1256
|
+
add(snapshot);
|
|
1257
|
+
}
|
|
1258
|
+
return [...byKey.values()];
|
|
1259
|
+
}
|
|
1260
|
+
domPanelSnapshots() {
|
|
1261
|
+
const host = this.host.nativeElement;
|
|
1262
|
+
if (!host)
|
|
1263
|
+
return [];
|
|
1264
|
+
const out = [];
|
|
1265
|
+
host.querySelectorAll('mj-collapsible-panel').forEach((node) => {
|
|
1266
|
+
const sectionKey = node.getAttribute('data-section-key') ?? '';
|
|
1267
|
+
if (!sectionKey)
|
|
1268
|
+
return;
|
|
1269
|
+
if (node.classList.contains('mj-panel-empty'))
|
|
1270
|
+
return;
|
|
1271
|
+
const title = node.querySelector('.mj-forms-panel-title span')?.textContent?.trim();
|
|
1272
|
+
out.push({
|
|
1273
|
+
SectionKey: sectionKey,
|
|
1274
|
+
SectionName: title || sectionKey,
|
|
1275
|
+
Variant: node.getAttribute('data-variant') || 'default',
|
|
1276
|
+
Icon: node.getAttribute('data-icon') || undefined,
|
|
1277
|
+
});
|
|
1278
|
+
});
|
|
1279
|
+
return out;
|
|
1280
|
+
}
|
|
1281
|
+
hiddenChromeSectionKeys() {
|
|
1282
|
+
const entity = this.EffectiveEntityInfo;
|
|
1283
|
+
if (!entity)
|
|
1284
|
+
return new Set();
|
|
1285
|
+
const resolved = ResolveFormContributions({
|
|
1286
|
+
EntityName: entity.Name,
|
|
1287
|
+
RelatedEntities: entity.RelatedEntities ?? [],
|
|
1288
|
+
IsaChildEntityIDs: (entity.ChildEntities ?? []).map((child) => child.ID),
|
|
1289
|
+
Registrations: CollectFormPanelRegistrations(),
|
|
1290
|
+
BakedSectionKeys: this.BakedRelatedSectionKeys,
|
|
1291
|
+
ShowRelatedEntities: this.EffectiveShowRelatedEntities,
|
|
1292
|
+
});
|
|
1293
|
+
return new Set(resolved.HiddenBakedSectionKeys);
|
|
1294
|
+
}
|
|
1295
|
+
buildRelatedSchemaMap(entity) {
|
|
1296
|
+
const map = new Map();
|
|
1297
|
+
const provider = this.ProviderToUse;
|
|
1298
|
+
for (const rel of entity.RelatedEntities) {
|
|
1299
|
+
const related = provider.EntityByID(rel.RelatedEntityID);
|
|
1300
|
+
if (related?.SchemaName) {
|
|
1301
|
+
map.set((rel.RelatedEntityID ?? '').toLowerCase(), related.SchemaName);
|
|
1302
|
+
}
|
|
1303
|
+
}
|
|
1304
|
+
return map;
|
|
1305
|
+
}
|
|
1306
|
+
buildInboundRelationshipCounts() {
|
|
1307
|
+
const counts = new Map();
|
|
1308
|
+
for (const entity of this.ProviderToUse.Entities ?? []) {
|
|
1309
|
+
for (const rel of entity.RelatedEntities ?? []) {
|
|
1310
|
+
const id = (rel.RelatedEntityID ?? '').toLowerCase();
|
|
1311
|
+
if (!id)
|
|
1312
|
+
continue;
|
|
1313
|
+
counts.set(id, (counts.get(id) ?? 0) + 1);
|
|
1314
|
+
}
|
|
1315
|
+
}
|
|
1316
|
+
return counts;
|
|
1317
|
+
}
|
|
1318
|
+
chromePrefKey(suffix) {
|
|
1319
|
+
const name = (this.EffectiveEntityInfo?.Name ?? 'entity').trim().toLowerCase();
|
|
1320
|
+
return `mj.formChrome.${name}.${suffix}`;
|
|
1321
|
+
}
|
|
1322
|
+
RestoreChromePrefs() {
|
|
1323
|
+
if (ShouldPersistChromeActiveGroup(this.EffectiveRecord?.IsSaved)) {
|
|
1324
|
+
const group = UserInfoEngine.Instance.GetSetting(this.chromePrefKey('activeGroup'));
|
|
1325
|
+
if (group)
|
|
1326
|
+
this.chrome.ActiveGroupKey = group;
|
|
1327
|
+
}
|
|
1328
|
+
const more = UserInfoEngine.Instance.GetSetting(this.chromePrefKey('moreExpanded'));
|
|
1329
|
+
if (more === '1')
|
|
1330
|
+
this.chrome.MoreExpanded = true;
|
|
1331
|
+
if (more === '0')
|
|
1332
|
+
this.chrome.MoreExpanded = false;
|
|
1333
|
+
this.ChromeRailPinned = ParseRailPinnedSetting(UserInfoEngine.Instance.GetSetting(this.chromePrefKey('railPinned')));
|
|
1334
|
+
this.ChromeRailWidthPx = ParseRailWidthSetting(UserInfoEngine.Instance.GetSetting(this.chromePrefKey('railWidth')));
|
|
1335
|
+
this.chromeRailExpanded = this.ChromeRailPinned;
|
|
1336
|
+
}
|
|
1337
|
+
PersistChromePrefs() {
|
|
1338
|
+
if (ShouldPersistChromeActiveGroup(this.EffectiveRecord?.IsSaved) && this.chrome.ActiveGroupKey) {
|
|
1339
|
+
UserInfoEngine.Instance.SetSettingDebounced(this.chromePrefKey('activeGroup'), this.chrome.ActiveGroupKey);
|
|
1340
|
+
}
|
|
1341
|
+
UserInfoEngine.Instance.SetSettingDebounced(this.chromePrefKey('moreExpanded'), this.chrome.MoreExpanded ? '1' : '0');
|
|
1342
|
+
UserInfoEngine.Instance.SetSettingDebounced(this.chromePrefKey('railPinned'), SerializeRailPinnedSetting(this.ChromeRailPinned));
|
|
1343
|
+
UserInfoEngine.Instance.SetSettingDebounced(this.chromePrefKey('railWidth'), SerializeRailWidthSetting(this.ChromeRailWidthPx));
|
|
1344
|
+
}
|
|
382
1345
|
/**
|
|
383
1346
|
* Subscribes to Navigate events from all child collapsible panels
|
|
384
1347
|
* and relays them through this container's Navigate output.
|
|
@@ -390,6 +1353,9 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
390
1353
|
this.fc.RecordReady.pipe(takeUntil(this.panelNavReset$)).subscribe(() => {
|
|
391
1354
|
this.LoadBadgeCounts();
|
|
392
1355
|
});
|
|
1356
|
+
this.fc.RecordRefreshed.pipe(takeUntil(this.panelNavReset$)).subscribe((e) => {
|
|
1357
|
+
this.OnFormRecordRefreshed(e.Record);
|
|
1358
|
+
});
|
|
393
1359
|
}
|
|
394
1360
|
this.Panels.forEach(panel => {
|
|
395
1361
|
panel.Navigate.pipe(takeUntil(this.panelNavReset$)).subscribe((event) => {
|
|
@@ -413,8 +1379,24 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
413
1379
|
}
|
|
414
1380
|
// ---- Badge Count Loading ----
|
|
415
1381
|
/**
|
|
416
|
-
*
|
|
417
|
-
*
|
|
1382
|
+
* Whether the attachments feature is available for the current record.
|
|
1383
|
+
* True when record is saved and entity allows attachments (default true).
|
|
1384
|
+
*/
|
|
1385
|
+
get AttachmentsAvailable() {
|
|
1386
|
+
const record = this.EffectiveRecord;
|
|
1387
|
+
if (!record || !record.IsSaved)
|
|
1388
|
+
return false;
|
|
1389
|
+
const entity = record.EntityInfo;
|
|
1390
|
+
if (!entity)
|
|
1391
|
+
return false;
|
|
1392
|
+
const config = entity.Configuration?.Attachments;
|
|
1393
|
+
if (config?.Enabled === false)
|
|
1394
|
+
return false;
|
|
1395
|
+
return true;
|
|
1396
|
+
}
|
|
1397
|
+
/**
|
|
1398
|
+
* Loads tag count, attachment count, and record change version count for toolbar badges.
|
|
1399
|
+
* All queries run in parallel for performance.
|
|
418
1400
|
*/
|
|
419
1401
|
badgeCountsLoaded = false;
|
|
420
1402
|
LoadBadgeCounts() {
|
|
@@ -424,9 +1406,34 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
424
1406
|
if (!record?.EntityInfo)
|
|
425
1407
|
return;
|
|
426
1408
|
this.badgeCountsLoaded = true;
|
|
427
|
-
// Fire
|
|
1409
|
+
// Fire queries in parallel — no await needed, they update state async
|
|
428
1410
|
this.LoadTagCount(record);
|
|
429
1411
|
this.LoadVersionCount(record);
|
|
1412
|
+
this.LoadAttachmentCount(record);
|
|
1413
|
+
}
|
|
1414
|
+
/**
|
|
1415
|
+
* Queries the count of linked attachments for the current entity + record
|
|
1416
|
+
* and updates the AttachmentCount badge on the toolbar.
|
|
1417
|
+
*/
|
|
1418
|
+
async LoadAttachmentCount(record) {
|
|
1419
|
+
if (!this.AttachmentsAvailable)
|
|
1420
|
+
return;
|
|
1421
|
+
try {
|
|
1422
|
+
const rv = RunView.FromMetadataProvider(this.ProviderToUse);
|
|
1423
|
+
const result = await rv.RunView({
|
|
1424
|
+
EntityName: 'MJ: File Entity Record Links',
|
|
1425
|
+
Fields: ['ID'],
|
|
1426
|
+
ExtraFilter: `EntityID='${record.EntityInfo.ID}' AND RecordID='${record.PrimaryKey.Values()}'`,
|
|
1427
|
+
ResultType: 'simple'
|
|
1428
|
+
});
|
|
1429
|
+
if (result.Success) {
|
|
1430
|
+
this.AttachmentCount = result.Results.length;
|
|
1431
|
+
this.cdr.detectChanges();
|
|
1432
|
+
}
|
|
1433
|
+
}
|
|
1434
|
+
catch {
|
|
1435
|
+
// Non-critical — badge just stays at 0
|
|
1436
|
+
}
|
|
430
1437
|
}
|
|
431
1438
|
/**
|
|
432
1439
|
* Queries the count of tagged items for the current entity + record
|
|
@@ -553,6 +1560,43 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
553
1560
|
this.CancelRequested.emit();
|
|
554
1561
|
}
|
|
555
1562
|
}
|
|
1563
|
+
/**
|
|
1564
|
+
* Refresh: delegate to FormComponent if available, otherwise re-emit.
|
|
1565
|
+
* Badge reload + related-grid fan-out happen on `RecordRefreshed` so
|
|
1566
|
+
* `host.Refresh()` (which calls `RefreshRecord()` directly) still notifies.
|
|
1567
|
+
*/
|
|
1568
|
+
async OnRefreshRequested() {
|
|
1569
|
+
if (this.fc?.RefreshRecord) {
|
|
1570
|
+
this.IsRefreshing = true;
|
|
1571
|
+
this.cdr.markForCheck();
|
|
1572
|
+
try {
|
|
1573
|
+
await this.fc.RefreshRecord();
|
|
1574
|
+
}
|
|
1575
|
+
finally {
|
|
1576
|
+
await Promise.resolve();
|
|
1577
|
+
this.ngZone.run(() => {
|
|
1578
|
+
this.IsRefreshing = false;
|
|
1579
|
+
this.cdr.markForCheck();
|
|
1580
|
+
});
|
|
1581
|
+
}
|
|
1582
|
+
}
|
|
1583
|
+
else {
|
|
1584
|
+
this.RefreshRequested.emit();
|
|
1585
|
+
}
|
|
1586
|
+
}
|
|
1587
|
+
/**
|
|
1588
|
+
* After the form reloads the parent record: refresh chrome that is not
|
|
1589
|
+
* the record itself (badges, open history drawer) and broadcast to
|
|
1590
|
+
* in-form listeners (related grids, IS-A panel, custom panels).
|
|
1591
|
+
*/
|
|
1592
|
+
OnFormRecordRefreshed(record) {
|
|
1593
|
+
this.badgeCountsLoaded = false;
|
|
1594
|
+
this.LoadBadgeCounts();
|
|
1595
|
+
if (this.ShowRecordChanges && this.recordChangesDrawer) {
|
|
1596
|
+
this.recordChangesDrawer.Refresh();
|
|
1597
|
+
}
|
|
1598
|
+
this.recordRefresh.Notify(record);
|
|
1599
|
+
}
|
|
556
1600
|
/**
|
|
557
1601
|
* Delete, Favorite, History, Lists, ShowChanges: always re-emit for host app.
|
|
558
1602
|
*/
|
|
@@ -610,6 +1654,26 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
610
1654
|
this.TagsPanelWidth = width;
|
|
611
1655
|
UserInfoEngine.Instance.SetSettingDebounced(MjRecordFormContainerComponent.TAGS_WIDTH_KEY, String(width));
|
|
612
1656
|
}
|
|
1657
|
+
OnAttachmentsPanelToggled() {
|
|
1658
|
+
this.ShowAttachmentsPanel = !this.ShowAttachmentsPanel;
|
|
1659
|
+
this.cdr.detectChanges();
|
|
1660
|
+
}
|
|
1661
|
+
OnAttachmentsPanelClosed() {
|
|
1662
|
+
this.ShowAttachmentsPanel = false;
|
|
1663
|
+
this.cdr.detectChanges();
|
|
1664
|
+
// Refresh attachment count — attachments may have been added/removed while panel was open
|
|
1665
|
+
const record = this.EffectiveRecord;
|
|
1666
|
+
if (record?.EntityInfo) {
|
|
1667
|
+
this.LoadAttachmentCount(record);
|
|
1668
|
+
}
|
|
1669
|
+
}
|
|
1670
|
+
/**
|
|
1671
|
+
* Handles live attachment count updates from the attachments panel component.
|
|
1672
|
+
*/
|
|
1673
|
+
OnAttachmentCountChanged(count) {
|
|
1674
|
+
this.AttachmentCount = count;
|
|
1675
|
+
this.cdr.markForCheck();
|
|
1676
|
+
}
|
|
613
1677
|
OnTagsRecordNavigate(event) {
|
|
614
1678
|
const md = this.ProviderToUse;
|
|
615
1679
|
const entityInfo = md.Entities.find(e => e.Name === event.EntityName);
|
|
@@ -715,6 +1779,11 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
715
1779
|
OnFilterChange(filter) {
|
|
716
1780
|
if (this.fc?.onFilterChange) {
|
|
717
1781
|
this.fc.onFilterChange(filter);
|
|
1782
|
+
if (filter.trim() && this.ChromeMoreItems.length > 0) {
|
|
1783
|
+
this.chrome.MoreExpanded = true;
|
|
1784
|
+
}
|
|
1785
|
+
this.ensureActiveGroupVisible();
|
|
1786
|
+
this.applyChromeVisibility();
|
|
718
1787
|
this.cdr.markForCheck();
|
|
719
1788
|
}
|
|
720
1789
|
}
|
|
@@ -749,6 +1818,7 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
749
1818
|
OnResetSectionOrder() {
|
|
750
1819
|
if (this.fc?.resetSectionOrder) {
|
|
751
1820
|
this.fc.resetSectionOrder();
|
|
1821
|
+
this.scheduleChromeResolve();
|
|
752
1822
|
this.cdr.markForCheck();
|
|
753
1823
|
}
|
|
754
1824
|
}
|
|
@@ -808,6 +1878,14 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
808
1878
|
OnSectionOrderChange(newOrder) {
|
|
809
1879
|
if (this.fc?.setSectionOrder) {
|
|
810
1880
|
this.fc.setSectionOrder(newOrder);
|
|
1881
|
+
this.scheduleChromeResolve();
|
|
1882
|
+
this.cdr.markForCheck();
|
|
1883
|
+
}
|
|
1884
|
+
}
|
|
1885
|
+
OnChromeMembershipChange(change) {
|
|
1886
|
+
if (this.fc?.setChromeMembership) {
|
|
1887
|
+
this.fc.setChromeMembership(change.moreSectionKeys, change.firstClassSectionKeys);
|
|
1888
|
+
this.scheduleChromeResolve();
|
|
811
1889
|
this.cdr.markForCheck();
|
|
812
1890
|
}
|
|
813
1891
|
}
|
|
@@ -829,48 +1907,63 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
829
1907
|
} if (rf & 2) {
|
|
830
1908
|
let _t;
|
|
831
1909
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.recordChangesDrawer = _t.first);
|
|
832
|
-
} }, 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", Variants: "Variants", CurrentVariantID: "CurrentVariantID" }, 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", VariantChange: "VariantChange" }, standalone: false, features: [i0.ɵɵProvidersFeature([FormSlotCoordinator]), i0.ɵɵInheritDefinitionFeature], ngContentSelectors: _c1, decls:
|
|
1910
|
+
} }, 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", IsRefreshing: "IsRefreshing", ToolbarConfig: "ToolbarConfig", RegisteredToolbarItems: "RegisteredToolbarItems", ToolbarItemOverrides: "ToolbarItemOverrides", WidthMode: "WidthMode", Variants: "Variants", CurrentVariantID: "CurrentVariantID" }, outputs: { Navigate: "Navigate", EditModeChange: "EditModeChange", BeforeSave: "BeforeSave", SaveRequested: "SaveRequested", BeforeCancel: "BeforeCancel", CancelRequested: "CancelRequested", BeforeDelete: "BeforeDelete", DeleteRequested: "DeleteRequested", BeforeRefresh: "BeforeRefresh", RefreshRequested: "RefreshRequested", FavoriteToggled: "FavoriteToggled", BeforeHistoryView: "BeforeHistoryView", HistoryRequested: "HistoryRequested", BeforeListManagement: "BeforeListManagement", ListManagementRequested: "ListManagementRequested", ShowChangesRequested: "ShowChangesRequested", CustomButtonClick: "CustomButtonClick", ToolbarItemClick: "ToolbarItemClick", VariantChange: "VariantChange", BeforeLayoutResolve: "BeforeLayoutResolve", AfterLayoutResolved: "AfterLayoutResolved", BeforeSectionActivate: "BeforeSectionActivate", AfterSectionActivated: "AfterSectionActivated" }, standalone: false, features: [i0.ɵɵProvidersFeature([FormSlotCoordinator, FormChromeCoordinator, FormRecordRefreshCoordinator]), i0.ɵɵInheritDefinitionFeature], ngContentSelectors: _c1, decls: 18, vars: 30, consts: [[3, "Record", "EditMode", "UserCanEdit", "UserCanDelete", "IsFavorite", "FavoriteInitDone", "IsDirty", "DirtyFieldNames", "ListCount", "TagCount", "AttachmentCount", "AttachmentsAvailable", "IsAttachmentsPanelOpen", "VersionCount", "EntityInfo", "Config", "IsSaving", "IsRefreshing", "VisibleSectionCount", "TotalSectionCount", "ExpandedSectionCount", "SearchFilter", "ShowEmptyFields", "WidthMode", "HasCustomSectionOrder", "ChromeLayout", "Variants", "CurrentVariantID", "RegisteredItems", "ItemOverrides", "FormComponent"], [1, "mj-forms-scroll-area"], [1, "mj-forms-panels-container"], [1, "mj-forms-layout-row"], ["aria-label", "Form sections", 1, "mj-forms-chrome-rail", 3, "is-collapsed", "is-resizing", "width"], [1, "mj-forms-all-panels"], [3, "Record", "FormComponent", "FormContext", "BakedSectionKeys", "ShowRelatedEntities"], [1, "mj-forms-more-overflow", 3, "is-expanded"], ["Slot", "after-everything", 3, "Entity", "Record", "FormComponent"], ["Variant", "no-results", "Title", "No sections found", "ActionText", "Clear search", "ActionIcon", "fa-solid fa-rotate-left", "ActionVariant", "flat", 1, "mj-forms-empty-search-state", 3, "Message"], [3, "Navigate", "Record", "EditMode", "Collapsed"], [3, "record", "AllowRestore"], [3, "Record", "WidthPx"], [3, "Record", "Visible"], [3, "visible", "config"], [3, "SectionOrderChange", "MembershipChange", "ResetRequested", "Closed", "Sections", "SectionOrder", "MoreSectionKeys", "LockedMoreKeys", "Visible"], [3, "Navigate", "EditModeChange", "BeforeSave", "SaveRequested", "BeforeCancel", "CancelRequested", "BeforeDelete", "DeleteRequested", "BeforeRefresh", "RefreshRequested", "FavoriteToggled", "BeforeHistoryView", "HistoryRequested", "BeforeListManagement", "ListManagementRequested", "ShowChangesRequested", "CustomButtonClick", "ToolbarItemClick", "FilterChange", "ExpandAllRequested", "CollapseAllRequested", "ShowEmptyFieldsChange", "WidthModeChange", "ResetSectionOrderRequested", "ManageSectionsRequested", "TagsPanelToggled", "AttachmentsPanelToggled", "VariantPicked", "Record", "EditMode", "UserCanEdit", "UserCanDelete", "IsFavorite", "FavoriteInitDone", "IsDirty", "DirtyFieldNames", "ListCount", "TagCount", "AttachmentCount", "AttachmentsAvailable", "IsAttachmentsPanelOpen", "VersionCount", "EntityInfo", "Config", "IsSaving", "IsRefreshing", "VisibleSectionCount", "TotalSectionCount", "ExpandedSectionCount", "SearchFilter", "ShowEmptyFields", "WidthMode", "HasCustomSectionOrder", "ChromeLayout", "Variants", "CurrentVariantID", "RegisteredItems", "ItemOverrides", "FormComponent"], ["aria-label", "Form sections", 1, "mj-forms-chrome-rail"], ["type", "button", 1, "mj-forms-chrome-rail-spine", 3, "title"], ["type", "button", 1, "mj-forms-chrome-rail-spine", 3, "click", "title"], [1, "mj-forms-chrome-rail-spine-label", 3, "mouseenter"], ["role", "separator", "aria-orientation", "vertical", "title", "Drag to resize sections", 1, "mj-forms-chrome-rail-resizer", 3, "pointerdown", "pointermove", "pointerup", "pointercancel"], [1, "mj-forms-chrome-rail-toolbar"], ["type", "button", 1, "mj-forms-chrome-rail-pin", 3, "click", "title"], [1, "fa-solid", "fa-thumbtack"], ["type", "button", "title", "Hide sections", "aria-label", "Hide form sections", 1, "mj-forms-chrome-rail-collapse", 3, "click"], [1, "fa-solid", "fa-angles-left"], ["role", "button", "tabindex", "0", 1, "mj-forms-chrome-rail-item", 3, "is-active", "is-drag-over"], ["role", "button", "tabindex", "0", 1, "mj-forms-chrome-rail-item", 3, "click", "keydown.enter", "keydown.space", "dragover", "dragleave", "drop"], ["title", "Drag to reorder", "draggable", "true", 1, "mj-forms-chrome-rail-handle"], [1, "mj-forms-chrome-rail-label", 3, "mouseenter"], [1, "mj-forms-chrome-rail-count", 3, "is-zero"], ["title", "Drag to reorder", "draggable", "true", 1, "mj-forms-chrome-rail-handle", 3, "dragstart", "dragend", "click"], [1, "fa-solid", "fa-grip-vertical"], [1, "mj-forms-chrome-rail-count"], ["role", "button", "tabindex", "0", 1, "mj-forms-chrome-rail-item", "is-more-folder", 3, "click", "keydown.enter", "keydown.space"], ["aria-hidden", "true", 1, "mj-forms-chrome-rail-handle", "is-spacer"], ["aria-hidden", "true", 1, "fa-solid", "mj-forms-chrome-rail-more-toggle"], [1, "mj-forms-chrome-rail-more-tree"], ["role", "button", "tabindex", "0", 1, "mj-forms-chrome-rail-item", "is-more-child", 3, "is-active", "is-drag-over"], ["role", "button", "tabindex", "0", 1, "mj-forms-chrome-rail-item", "is-more-child", 3, "click", "keydown.enter", "keydown.space", "dragover", "dragleave", "drop"], [1, "mj-forms-more-overflow"], ["type", "button", 1, "mj-forms-more-overflow-toggle", 3, "click"], [1, "mj-forms-more-overflow-label"], [1, "mj-forms-more-overflow-preview"], [1, "fa-solid"], ["Variant", "no-results", "Title", "No sections found", "ActionText", "Clear search", "ActionIcon", "fa-solid fa-rotate-left", "ActionVariant", "flat", 1, "mj-forms-empty-search-state", 3, "Action", "Message"], [3, "RestoreRequested", "dialogClosed", "record", "AllowRestore"], [3, "PanelClosed", "TagCountChanged", "RecordNavigate", "WidthChanged", "Record", "WidthPx"], [3, "PanelClosed", "AttachmentCountChanged", "Record", "Visible"], [3, "complete", "cancel", "visible", "config"]], template: function MjRecordFormContainerComponent_Template(rf, ctx) { if (rf & 1) {
|
|
833
1911
|
i0.ɵɵprojectionDef(_c0);
|
|
834
1912
|
i0.ɵɵprojection(0);
|
|
835
|
-
i0.ɵɵconditionalCreate(1, MjRecordFormContainerComponent_Conditional_1_Template, 1,
|
|
836
|
-
i0.ɵɵelementStart(2, "div", 1)(3, "div", 2)(4, "div", 3)
|
|
837
|
-
i0.ɵɵ
|
|
838
|
-
i0.ɵɵ
|
|
839
|
-
i0.ɵɵ
|
|
1913
|
+
i0.ɵɵconditionalCreate(1, MjRecordFormContainerComponent_Conditional_1_Template, 1, 31, "mj-form-toolbar", 0);
|
|
1914
|
+
i0.ɵɵelementStart(2, "div", 1)(3, "div", 2)(4, "div", 3);
|
|
1915
|
+
i0.ɵɵconditionalCreate(5, MjRecordFormContainerComponent_Conditional_5_Template, 3, 8, "nav", 4);
|
|
1916
|
+
i0.ɵɵelementStart(6, "div", 5);
|
|
1917
|
+
i0.ɵɵprojection(7, 1);
|
|
1918
|
+
i0.ɵɵconditionalCreate(8, MjRecordFormContainerComponent_Conditional_8_Template, 1, 5, "mj-form-contributions", 6);
|
|
1919
|
+
i0.ɵɵconditionalCreate(9, MjRecordFormContainerComponent_Conditional_9_Template, 7, 10, "div", 7);
|
|
1920
|
+
i0.ɵɵconditionalCreate(10, MjRecordFormContainerComponent_Conditional_10_Template, 1, 3, "mj-form-panel-slot", 8);
|
|
1921
|
+
i0.ɵɵconditionalCreate(11, MjRecordFormContainerComponent_Conditional_11_Template, 1, 1, "mj-empty-state", 9);
|
|
840
1922
|
i0.ɵɵelementEnd();
|
|
841
|
-
i0.ɵɵelementStart(
|
|
842
|
-
i0.ɵɵlistener("Navigate", function
|
|
1923
|
+
i0.ɵɵelementStart(12, "mj-isa-related-panel", 10);
|
|
1924
|
+
i0.ɵɵlistener("Navigate", function MjRecordFormContainerComponent_Template_mj_isa_related_panel_Navigate_12_listener($event) { return ctx.OnNavigate($event); });
|
|
843
1925
|
i0.ɵɵelementEnd()()()();
|
|
844
|
-
i0.ɵɵconditionalCreate(
|
|
845
|
-
i0.ɵɵconditionalCreate(
|
|
846
|
-
i0.ɵɵconditionalCreate(
|
|
847
|
-
i0.ɵɵ
|
|
848
|
-
i0.ɵɵ
|
|
1926
|
+
i0.ɵɵconditionalCreate(13, MjRecordFormContainerComponent_Conditional_13_Template, 1, 2, "mj-record-changes", 11);
|
|
1927
|
+
i0.ɵɵconditionalCreate(14, MjRecordFormContainerComponent_Conditional_14_Template, 1, 2, "mj-record-tags", 12);
|
|
1928
|
+
i0.ɵɵconditionalCreate(15, MjRecordFormContainerComponent_Conditional_15_Template, 1, 2, "mj-record-attachments", 13);
|
|
1929
|
+
i0.ɵɵconditionalCreate(16, MjRecordFormContainerComponent_Conditional_16_Template, 1, 8, "mj-list-management-dialog", 14);
|
|
1930
|
+
i0.ɵɵelementStart(17, "mj-section-manager", 15);
|
|
1931
|
+
i0.ɵɵlistener("SectionOrderChange", function MjRecordFormContainerComponent_Template_mj_section_manager_SectionOrderChange_17_listener($event) { return ctx.OnSectionOrderChange($event); })("MembershipChange", function MjRecordFormContainerComponent_Template_mj_section_manager_MembershipChange_17_listener($event) { return ctx.OnChromeMembershipChange($event); })("ResetRequested", function MjRecordFormContainerComponent_Template_mj_section_manager_ResetRequested_17_listener() { return ctx.OnSectionManagerReset(); })("Closed", function MjRecordFormContainerComponent_Template_mj_section_manager_Closed_17_listener() { return ctx.OnSectionManagerClosed(); });
|
|
849
1932
|
i0.ɵɵelementEnd();
|
|
850
1933
|
} if (rf & 2) {
|
|
851
1934
|
i0.ɵɵadvance();
|
|
852
1935
|
i0.ɵɵconditional(ctx.EffectiveShowToolbar ? 1 : -1);
|
|
853
1936
|
i0.ɵɵadvance(2);
|
|
854
1937
|
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);
|
|
855
|
-
i0.ɵɵadvance(4);
|
|
856
|
-
i0.ɵɵconditional(ctx.Record && ctx.FormComponent ? 7 : -1);
|
|
857
1938
|
i0.ɵɵadvance();
|
|
858
|
-
i0.ɵɵ
|
|
1939
|
+
i0.ɵɵclassProp("mj-forms-layout--left-nav", ctx.ChromeLayout === "left-nav")("mj-forms-layout--accordion", ctx.ChromeLayout === "accordion")("mj-forms-layout--more", ctx.IsChromeMoreActive);
|
|
1940
|
+
i0.ɵɵadvance();
|
|
1941
|
+
i0.ɵɵconditional(ctx.ShowChromeRail ? 5 : -1);
|
|
1942
|
+
i0.ɵɵadvance(3);
|
|
1943
|
+
i0.ɵɵconditional(ctx.Record && ctx.FormComponent ? 8 : -1);
|
|
1944
|
+
i0.ɵɵadvance();
|
|
1945
|
+
i0.ɵɵconditional(ctx.ShowMoreToggle ? 9 : -1);
|
|
1946
|
+
i0.ɵɵadvance();
|
|
1947
|
+
i0.ɵɵconditional(ctx.Record && ctx.FormComponent ? 10 : -1);
|
|
1948
|
+
i0.ɵɵadvance();
|
|
1949
|
+
i0.ɵɵconditional(ctx.EffectiveSearchFilter && ctx.SearchHasNoMatches ? 11 : -1);
|
|
859
1950
|
i0.ɵɵadvance();
|
|
860
1951
|
i0.ɵɵproperty("Record", ctx.EffectiveRecord)("EditMode", ctx.EffectiveEditMode)("Collapsed", ctx.EffectiveWidthMode === "full-width");
|
|
861
1952
|
i0.ɵɵadvance();
|
|
862
|
-
i0.ɵɵconditional(ctx.ShowRecordChanges && ctx.EffectiveRecord ?
|
|
1953
|
+
i0.ɵɵconditional(ctx.ShowRecordChanges && ctx.EffectiveRecord ? 13 : -1);
|
|
1954
|
+
i0.ɵɵadvance();
|
|
1955
|
+
i0.ɵɵconditional(ctx.ShowTagsPanel && ctx.EffectiveRecord ? 14 : -1);
|
|
863
1956
|
i0.ɵɵadvance();
|
|
864
|
-
i0.ɵɵconditional(ctx.
|
|
1957
|
+
i0.ɵɵconditional(ctx.ShowAttachmentsPanel && ctx.AttachmentsAvailable && ctx.EffectiveRecord ? 15 : -1);
|
|
865
1958
|
i0.ɵɵadvance();
|
|
866
|
-
i0.ɵɵconditional(ctx.ShowListManagement && ctx.EffectiveRecord ?
|
|
1959
|
+
i0.ɵɵconditional(ctx.ShowListManagement && ctx.EffectiveRecord ? 16 : -1);
|
|
867
1960
|
i0.ɵɵadvance();
|
|
868
|
-
i0.ɵɵproperty("Sections", ctx.SectionManagerItems)("SectionOrder", ctx.SectionManagerOrder)("Visible", ctx.ShowSectionManager);
|
|
869
|
-
} }, dependencies: [i1.MJEmptyStateComponent, i2.RecordChangesComponent, i3.ListManagementDialogComponent, i4.RecordTagsComponent, i5.MjFormToolbarComponent, i6.MjSectionManagerComponent, i7.MjIsaRelatedPanelComponent, i8.FormPanelSlotComponent], 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\n/* ====================================================================\n VARIANT PICKER \u2014 between toolbar and form body\n Compact \"Form: <name> \u25BE\" row that appears when more than one variant\n is applicable for the current entity record.\n ==================================================================== */\n\n.mj-form-variant-picker {\n display: flex;\n align-items: center;\n gap: 10px;\n padding: 6px 18px;\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n font-size: 12px;\n color: var(--mj-text-secondary);\n}\n.mj-form-variant-picker-icon {\n color: var(--mj-brand-primary);\n font-size: 12px;\n}\n.mj-form-variant-picker-label {\n font-weight: 600;\n color: var(--mj-text-secondary);\n}\n.mj-form-variant-picker-control {\n position: relative;\n display: inline-flex;\n align-items: center;\n gap: 6px;\n padding: 4px 10px;\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-md, 8px);\n background: var(--mj-bg-surface);\n color: var(--mj-text-primary);\n cursor: pointer;\n outline: none;\n user-select: none;\n min-width: 160px;\n}\n.mj-form-variant-picker-control:hover,\n.mj-form-variant-picker-control:focus,\n.mj-form-variant-picker-control.open {\n border-color: var(--mj-border-focus);\n box-shadow: 0 0 0 3px color-mix(in srgb, var(--mj-brand-primary) 15%, transparent);\n}\n.mj-form-variant-picker-current {\n font-weight: 600;\n flex: 1;\n}\n.mj-form-variant-picker-menu {\n position: absolute;\n top: calc(100% + 4px);\n left: 0;\n z-index: 50;\n min-width: 280px;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-md, 8px);\n box-shadow: var(--mj-shadow-md, 0 4px 12px rgba(15, 23, 42, 0.08));\n padding: 4px;\n max-height: 320px;\n overflow: auto;\n}\n.mj-form-variant-picker-row {\n display: flex;\n align-items: center;\n gap: 10px;\n padding: 8px 10px;\n border-radius: 6px;\n cursor: pointer;\n}\n.mj-form-variant-picker-row:hover {\n background: var(--mj-bg-surface-hover);\n}\n.mj-form-variant-picker-row.current {\n background: color-mix(in srgb, var(--mj-brand-primary) 8%, var(--mj-bg-surface));\n}\n.mj-form-variant-picker-row.inactive {\n opacity: 0.7;\n}\n.mj-form-variant-picker-row-main {\n display: flex;\n flex-direction: column;\n gap: 2px;\n flex: 1;\n min-width: 0;\n}\n.mj-form-variant-picker-row-title {\n font-size: 13px;\n font-weight: 600;\n color: var(--mj-text-primary);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.mj-form-variant-picker-row-sub {\n font-size: 11px;\n color: var(--mj-text-muted);\n}\n.mj-form-variant-picker-check {\n color: var(--mj-brand-primary);\n font-size: 11px;\n}\n\n/* Retrospective fix #8 \u2014 visually distinguish the Default row from variants. */\n.mj-form-variant-picker-row.mj-form-variant-picker-default {\n border-bottom: 1px dashed var(--mj-border-default);\n margin-bottom: 4px;\n padding-bottom: 10px;\n}\n.mj-form-variant-picker-default-tag {\n color: var(--mj-text-muted);\n font-weight: 400;\n font-size: 11px;\n margin-left: 4px;\n}\n"], encapsulation: 2, changeDetection: 0 });
|
|
1961
|
+
i0.ɵɵproperty("Sections", ctx.SectionManagerItems)("SectionOrder", ctx.SectionManagerOrder)("MoreSectionKeys", ctx.SectionManagerMoreKeys)("LockedMoreKeys", ctx.SectionManagerLockedMoreKeys)("Visible", ctx.ShowSectionManager);
|
|
1962
|
+
} }, dependencies: [i1.MJEmptyStateComponent, i2.RecordChangesComponent, i3.ListManagementDialogComponent, i4.RecordTagsComponent, i5.RecordAttachmentsComponent, i6.MjFormToolbarComponent, i7.MjSectionManagerComponent, i8.MjIsaRelatedPanelComponent, i9.FormPanelSlotComponent, i10.FormContributionsComponent], 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 display: flex;\n flex-direction: column;\n min-height: 0;\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 flex: 1;\n min-height: 0;\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.mj-forms-panels-container:has(.mj-forms-layout--left-nav) {\n padding: 16px 20px 24px;\n display: flex;\n flex-direction: column;\n /* Definite height = the scroll-area's client box. min-height: 100% alone\n lets the column grow with content and never gives related grids a\n containing-block height, so Height:auto (100%) on the grid collapses. */\n height: 100%;\n max-height: 100%;\n min-height: 0;\n overflow: hidden;\n box-sizing: border-box;\n}\n\n/* Centered left-nav keeps the form column at the same 920px as accordion,\n plus the rail. Full-width still uses .mj-forms-panels--full-width. */\n.mj-forms-panels-container:has(.mj-forms-layout--left-nav):not(.mj-forms-panels--full-width) {\n max-width: 1160px;\n}\n\n.mj-forms-layout-row.mj-forms-layout--left-nav {\n flex: 1;\n min-height: 0;\n /* Wins over .mj-forms-layout-row { align-items: flex-start } so the\n body column stretches to the rail / viewport instead of hugging content. */\n align-items: stretch;\n gap: 16px;\n}\n\n/* Left-nav: only the active rail item is in the body. Slot-mounted\n panels never inject the container coordinator, so host classes set\n from the container are the hide/show channel that always reaches them. */\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-chrome-hidden,\n.mj-forms-layout--accordion mj-collapsible-panel.mj-chrome-hidden {\n display: none;\n}\n\n/* Selected item: no accordion chrome \u2014 the rail is the header. */\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-chrome-show .mj-forms-panel-header {\n display: none;\n}\n\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-chrome-show .mj-forms-panel {\n box-shadow: none;\n border: 0;\n background: transparent;\n border-radius: 0;\n}\n\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-chrome-show .mj-forms-panel-body--collapsed {\n max-height: none;\n padding: 0;\n opacity: 1;\n}\n\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-chrome-show .mj-forms-panel-content {\n max-height: none;\n padding: 0;\n overflow: visible;\n}\n\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-panel--related-entity.mj-chrome-show {\n /* Content-sized (see RelatedGridHeightPx). Do not flex-fill leftover\n column space \u2014 a form header above the grid can collapse that to 0. */\n flex: 0 0 auto;\n min-height: 0;\n}\n\n/* Accordion related panels use a 400px resizable box. Left-nav grids\n set their own pixel height from row count (RelatedGridHeightPx). */\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-panel--related-entity.mj-chrome-show .mj-forms-panel-content {\n height: auto;\n max-height: none;\n overflow: hidden;\n resize: none;\n}\n\n.mj-forms-layout--left-nav .mj-forms-all-panels {\n gap: 0;\n min-height: 0;\n overflow-y: auto;\n}\n\n/* Details (field panels) can be taller than the viewport \u2014 scroll inside the\n column. Related grids scroll inside AG Grid instead. */\n.mj-forms-layout--left-nav .mj-forms-all-panels:has(mj-collapsible-panel.mj-chrome-show:not(.mj-panel--related-entity)) {\n overflow-y: auto;\n}\n\n.mj-forms-layout--left-nav .mj-forms-all-panels > *:not(mj-collapsible-panel.mj-panel--related-entity) {\n flex-shrink: 0;\n}\n\n.mj-forms-layout--left-nav .biz-hero {\n margin-bottom: 4px;\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.mj-forms-panels--edit-mode .mj-forms-more-overflow {\n display: none;\n}\n\n/* Detail / More panels sort after the overflow footer */\nmj-collapsible-panel.mj-form-role-detail,\nmj-collapsible-panel.mj-form-role-more {\n order: 8500;\n}\n\n.mj-forms-more-overflow {\n order: 8400;\n display: flex;\n flex-direction: column;\n margin-top: 4px;\n padding-top: 12px;\n border-top: 1px dashed var(--mj-border-subtle);\n}\n\n.mj-forms-more-overflow-toggle {\n display: flex;\n align-items: center;\n gap: 10px;\n width: 100%;\n padding: 6px 2px;\n border: 0;\n background: transparent;\n color: var(--mj-text-muted);\n font-size: var(--mj-text-sm);\n cursor: pointer;\n text-align: left;\n}\n\n.mj-forms-more-overflow-toggle:hover {\n color: var(--mj-text-secondary);\n}\n\n.mj-forms-more-overflow-label {\n font-weight: var(--mj-font-semibold);\n}\n\n.mj-forms-more-overflow-preview {\n flex: 1;\n min-width: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n color: var(--mj-text-disabled);\n font-weight: var(--mj-font-normal);\n}\n\n.mj-forms-more-overflow-toggle .fa-chevron-right,\n.mj-forms-more-overflow-toggle .fa-chevron-down {\n margin-left: auto;\n}\n\n.mj-forms-chrome-rail {\n flex: 0 0 auto;\n width: 200px;\n max-width: 360px;\n min-width: 160px;\n display: flex;\n flex-direction: column;\n gap: 4px;\n position: sticky;\n top: 0;\n align-self: stretch;\n min-height: 0;\n padding: 4px;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-subtle);\n border-radius: var(--mj-radius-md);\n}\n\n.mj-forms-chrome-rail.is-resizing {\n user-select: none;\n}\n\n.mj-forms-chrome-rail.is-collapsed {\n flex: 0 0 36px;\n width: 36px;\n min-width: 36px;\n max-width: 36px;\n padding: 8px 0;\n overflow: hidden;\n}\n\n.mj-forms-chrome-rail-resizer {\n position: absolute;\n top: 0;\n right: -4px;\n width: 8px;\n height: 100%;\n cursor: col-resize;\n z-index: 3;\n touch-action: none;\n}\n\n.mj-forms-chrome-rail-resizer::after {\n content: '';\n position: absolute;\n top: 12px;\n bottom: 12px;\n left: 3px;\n width: 2px;\n border-radius: 1px;\n background: transparent;\n}\n\n.mj-forms-chrome-rail:hover .mj-forms-chrome-rail-resizer::after,\n.mj-forms-chrome-rail.is-resizing .mj-forms-chrome-rail-resizer::after {\n background: var(--mj-border-strong);\n}\n\n.mj-forms-layout--right-nav .mj-forms-chrome-rail-resizer {\n right: auto;\n left: -4px;\n}\n\n.mj-forms-chrome-rail-spine {\n display: flex;\n flex-direction: column;\n align-items: center;\n gap: 10px;\n width: 100%;\n height: 100%;\n min-height: 0;\n padding: 8px 0;\n border: 0;\n background: transparent;\n color: var(--mj-brand-primary);\n cursor: pointer;\n}\n\n.mj-forms-chrome-rail-spine:hover {\n background: color-mix(in srgb, var(--mj-brand-primary) 10%, transparent);\n}\n\n.mj-forms-chrome-rail-spine > i {\n flex-shrink: 0;\n}\n\n.mj-forms-chrome-rail-spine-label {\n writing-mode: vertical-rl;\n transform: rotate(180deg);\n letter-spacing: 0.04em;\n font-size: var(--mj-text-sm);\n font-weight: var(--mj-font-semibold);\n color: var(--mj-text-primary);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n max-height: 100%;\n}\n\n.mj-forms-chrome-rail-toolbar {\n display: flex;\n align-items: center;\n justify-content: flex-end;\n gap: 2px;\n padding: 2px 4px 6px;\n}\n\n.mj-forms-chrome-rail-pin,\n.mj-forms-chrome-rail-collapse {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 26px;\n height: 26px;\n border: 0;\n border-radius: var(--mj-radius-sm);\n background: transparent;\n color: var(--mj-text-muted);\n cursor: pointer;\n}\n\n.mj-forms-chrome-rail-pin:hover,\n.mj-forms-chrome-rail-collapse:hover {\n background: var(--mj-bg-surface-hover);\n color: var(--mj-text-primary);\n}\n\n.mj-forms-chrome-rail-pin:not(.is-pinned) i {\n transform: rotate(45deg);\n}\n\n.mj-forms-chrome-rail-pin.is-pinned {\n color: var(--mj-brand-primary);\n}\n\n.mj-forms-chrome-rail-item {\n position: relative;\n display: flex;\n align-items: center;\n gap: 8px;\n width: 100%;\n padding: 10px 12px;\n border: 0;\n border-radius: var(--mj-radius-sm);\n background: transparent;\n color: var(--mj-text-muted);\n font-size: var(--mj-text-sm);\n text-align: left;\n cursor: pointer;\n}\n\n.mj-forms-chrome-rail-item > i {\n width: 1.15em;\n flex-shrink: 0;\n text-align: center;\n color: inherit;\n}\n\n.mj-forms-chrome-rail-item:hover {\n background: var(--mj-bg-surface-hover);\n color: var(--mj-text-primary);\n}\n\n.mj-forms-chrome-rail-item.is-active {\n background: color-mix(in srgb, var(--mj-brand-primary) 16%, var(--mj-bg-surface));\n color: var(--mj-brand-primary);\n font-weight: var(--mj-font-semibold);\n}\n\n.mj-forms-chrome-rail-item.is-active::before {\n content: '';\n position: absolute;\n left: 0;\n top: 6px;\n bottom: 6px;\n width: 3px;\n border-radius: 0 3px 3px 0;\n background: var(--mj-brand-primary);\n}\n\n.mj-forms-chrome-rail-item.is-active .mj-forms-chrome-rail-label {\n color: var(--mj-brand-primary);\n}\n\n.mj-forms-chrome-rail-item.is-drag-over {\n outline: 1px dashed var(--mj-border-focus);\n outline-offset: -1px;\n}\n\n.mj-forms-chrome-rail-handle {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 14px;\n height: 18px;\n margin-left: -4px;\n color: var(--mj-text-muted);\n cursor: grab;\n opacity: 0;\n overflow: hidden;\n flex-shrink: 0;\n transition: opacity var(--mj-transition-base, 0.15s) ease;\n}\n\n.mj-forms-chrome-rail-item:hover .mj-forms-chrome-rail-handle,\n.mj-forms-chrome-rail-item.is-active .mj-forms-chrome-rail-handle {\n opacity: 1;\n}\n\n.mj-forms-chrome-rail-handle.is-spacer {\n opacity: 0;\n pointer-events: none;\n cursor: default;\n}\n\n.mj-forms-chrome-rail-handle:hover {\n color: var(--mj-brand-primary);\n}\n\n.mj-forms-chrome-rail-handle:active {\n cursor: grabbing;\n}\n\n.mj-forms-chrome-rail-item.is-more-folder {\n position: relative;\n margin-top: 14px;\n padding-top: 14px;\n color: var(--mj-text-muted);\n border-radius: 0;\n}\n\n.mj-forms-chrome-rail-item.is-more-folder::before {\n content: '';\n position: absolute;\n top: 0;\n left: 8px;\n right: 8px;\n height: 1px;\n background: linear-gradient(\n 90deg,\n transparent 0%,\n var(--mj-border-strong) 18%,\n var(--mj-border-strong) 82%,\n transparent 100%\n );\n}\n\n.mj-forms-chrome-rail-item.is-more-folder:hover {\n background: transparent;\n color: var(--mj-text-secondary);\n}\n\n.mj-forms-chrome-rail-item.is-more-folder.is-expanded {\n color: var(--mj-text-secondary);\n}\n\n.mj-forms-chrome-rail-more-toggle {\n margin-left: auto;\n font-size: 10px;\n color: var(--mj-text-muted);\n}\n\n.mj-forms-chrome-rail-more-tree {\n margin-left: 22px;\n padding-left: 6px;\n border-left: 1px solid var(--mj-border-subtle);\n}\n\n.mj-forms-chrome-rail-item.is-more-child {\n padding-left: 8px;\n}\n\n.mj-forms-chrome-rail-count.is-zero {\n opacity: 0.55;\n}\n\n.mj-forms-chrome-rail-label {\n flex: 1;\n min-width: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.mj-forms-chrome-rail-count {\n min-width: 1.25rem;\n padding: 0 6px;\n border-radius: var(--mj-radius-full);\n background: var(--mj-bg-surface-sunken);\n color: var(--mj-text-muted);\n font-size: var(--mj-text-xs);\n text-align: center;\n}\n\n@media (max-width: 720px) {\n .mj-forms-layout--left-nav {\n flex-direction: column;\n }\n\n .mj-forms-chrome-rail {\n flex: 1 1 auto;\n width: 100%;\n position: static;\n flex-direction: row;\n flex-wrap: wrap;\n }\n\n .mj-forms-chrome-rail-resizer {\n display: none;\n }\n\n .mj-forms-chrome-rail.is-collapsed {\n flex: 0 0 auto;\n width: 100%;\n min-width: 0;\n max-width: none;\n height: 36px;\n padding: 0;\n }\n\n .mj-forms-chrome-rail-spine {\n flex-direction: row;\n padding: 0 12px;\n }\n\n .mj-forms-chrome-rail-spine-label {\n writing-mode: horizontal-tb;\n transform: none;\n max-height: none;\n }\n\n .mj-forms-chrome-rail-toolbar {\n width: 100%;\n }\n\n .mj-forms-chrome-rail-item {\n width: auto;\n }\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\n/* ====================================================================\n VARIANT PICKER \u2014 between toolbar and form body\n Compact \"Form: <name> \u25BE\" row that appears when more than one variant\n is applicable for the current entity record.\n ==================================================================== */\n\n.mj-form-variant-picker {\n display: flex;\n align-items: center;\n gap: 10px;\n padding: 6px 18px;\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n font-size: 12px;\n color: var(--mj-text-secondary);\n}\n.mj-form-variant-picker-icon {\n color: var(--mj-brand-primary);\n font-size: 12px;\n}\n.mj-form-variant-picker-label {\n font-weight: 600;\n color: var(--mj-text-secondary);\n}\n.mj-form-variant-picker-control {\n position: relative;\n display: inline-flex;\n align-items: center;\n gap: 6px;\n padding: 4px 10px;\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-md, 8px);\n background: var(--mj-bg-surface);\n color: var(--mj-text-primary);\n cursor: pointer;\n outline: none;\n user-select: none;\n min-width: 160px;\n}\n.mj-form-variant-picker-control:hover,\n.mj-form-variant-picker-control:focus,\n.mj-form-variant-picker-control.open {\n border-color: var(--mj-border-focus);\n box-shadow: 0 0 0 3px color-mix(in srgb, var(--mj-brand-primary) 15%, transparent);\n}\n.mj-form-variant-picker-current {\n font-weight: 600;\n flex: 1;\n}\n.mj-form-variant-picker-menu {\n position: absolute;\n top: calc(100% + 4px);\n left: 0;\n z-index: 50;\n min-width: 280px;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-md, 8px);\n box-shadow: var(--mj-shadow-md, 0 4px 12px rgba(15, 23, 42, 0.08));\n padding: 4px;\n max-height: 320px;\n overflow: auto;\n}\n.mj-form-variant-picker-row {\n display: flex;\n align-items: center;\n gap: 10px;\n padding: 8px 10px;\n border-radius: 6px;\n cursor: pointer;\n}\n.mj-form-variant-picker-row:hover {\n background: var(--mj-bg-surface-hover);\n}\n.mj-form-variant-picker-row.current {\n background: color-mix(in srgb, var(--mj-brand-primary) 8%, var(--mj-bg-surface));\n}\n.mj-form-variant-picker-row.inactive {\n opacity: 0.7;\n}\n.mj-form-variant-picker-row-main {\n display: flex;\n flex-direction: column;\n gap: 2px;\n flex: 1;\n min-width: 0;\n}\n.mj-form-variant-picker-row-title {\n font-size: 13px;\n font-weight: 600;\n color: var(--mj-text-primary);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.mj-form-variant-picker-row-sub {\n font-size: 11px;\n color: var(--mj-text-muted);\n}\n.mj-form-variant-picker-check {\n color: var(--mj-brand-primary);\n font-size: 11px;\n}\n\n/* Retrospective fix #8 \u2014 visually distinguish the Default row from variants. */\n.mj-form-variant-picker-row.mj-form-variant-picker-default {\n border-bottom: 1px dashed var(--mj-border-default);\n margin-bottom: 4px;\n padding-bottom: 10px;\n}\n.mj-form-variant-picker-default-tag {\n color: var(--mj-text-muted);\n font-weight: 400;\n font-size: 11px;\n margin-left: 4px;\n}\n"], encapsulation: 2, changeDetection: 0 });
|
|
870
1963
|
}
|
|
871
1964
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(MjRecordFormContainerComponent, [{
|
|
872
1965
|
type: Component,
|
|
873
|
-
args: [{ standalone: false, selector: 'mj-record-form-container', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, providers: [FormSlotCoordinator], 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 Hidden entirely when Config.Toolbar === null (dialog/slide-in surfaces).\n ============================================ -->\n@if (EffectiveShowToolbar) {\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]=\"EffectiveToolbarConfig\"\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 [Variants]=\"EffectiveVariants\"\n [CurrentVariantID]=\"EffectiveCurrentVariantID\"\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 (VariantPicked)=\"OnVariantPicked($event)\">\n</mj-form-toolbar>\n}\n\n<!-- ============================================\n SCROLL AREA (full-width so mouse wheel works anywhere)\n Variant picker is now embedded in <mj-form-toolbar> as a right-side\n button \u2014 see the [Variants]/[CurrentVariantID] inputs + (VariantPicked)\n output on the toolbar above. Inline strip was removed.\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 <!--\n Container-provided fallback slot. ALWAYS present \u2014 last in document\n order \u2014 so any panel whose registered slot isn't found in the current\n form falls through here via FormSlotCoordinator's chain. Downstream\n consumers that haven't rerun CodeGen against the slot-emitting\n template still see every panel; they just render at the bottom\n instead of at their preferred position.\n -->\n @if (Record && FormComponent) {\n <mj-form-panel-slot\n [Entity]=\"Record.EntityInfo.Name\"\n Slot=\"after-everything\"\n [Record]=\"Record\"\n [FormComponent]=\"FormComponent\">\n </mj-form-panel-slot>\n }\n\n <!-- Empty state when no sections match search -->\n @if (EffectiveSearchFilter && VisibleSectionCount === 0) {\n <mj-empty-state class=\"mj-forms-empty-search-state\"\n Variant=\"no-results\"\n Title=\"No sections found\"\n [Message]=\"'No sections match "' + EffectiveSearchFilter + '". Try a different search term.'\"\n ActionText=\"Clear search\"\n ActionIcon=\"fa-solid fa-rotate-left\"\n ActionVariant=\"flat\"\n (Action)=\"OnFilterChange('')\" />\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)=\"OnListManagementComplete($event)\"\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\n/* ====================================================================\n VARIANT PICKER \u2014 between toolbar and form body\n Compact \"Form: <name> \u25BE\" row that appears when more than one variant\n is applicable for the current entity record.\n ==================================================================== */\n\n.mj-form-variant-picker {\n display: flex;\n align-items: center;\n gap: 10px;\n padding: 6px 18px;\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n font-size: 12px;\n color: var(--mj-text-secondary);\n}\n.mj-form-variant-picker-icon {\n color: var(--mj-brand-primary);\n font-size: 12px;\n}\n.mj-form-variant-picker-label {\n font-weight: 600;\n color: var(--mj-text-secondary);\n}\n.mj-form-variant-picker-control {\n position: relative;\n display: inline-flex;\n align-items: center;\n gap: 6px;\n padding: 4px 10px;\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-md, 8px);\n background: var(--mj-bg-surface);\n color: var(--mj-text-primary);\n cursor: pointer;\n outline: none;\n user-select: none;\n min-width: 160px;\n}\n.mj-form-variant-picker-control:hover,\n.mj-form-variant-picker-control:focus,\n.mj-form-variant-picker-control.open {\n border-color: var(--mj-border-focus);\n box-shadow: 0 0 0 3px color-mix(in srgb, var(--mj-brand-primary) 15%, transparent);\n}\n.mj-form-variant-picker-current {\n font-weight: 600;\n flex: 1;\n}\n.mj-form-variant-picker-menu {\n position: absolute;\n top: calc(100% + 4px);\n left: 0;\n z-index: 50;\n min-width: 280px;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-md, 8px);\n box-shadow: var(--mj-shadow-md, 0 4px 12px rgba(15, 23, 42, 0.08));\n padding: 4px;\n max-height: 320px;\n overflow: auto;\n}\n.mj-form-variant-picker-row {\n display: flex;\n align-items: center;\n gap: 10px;\n padding: 8px 10px;\n border-radius: 6px;\n cursor: pointer;\n}\n.mj-form-variant-picker-row:hover {\n background: var(--mj-bg-surface-hover);\n}\n.mj-form-variant-picker-row.current {\n background: color-mix(in srgb, var(--mj-brand-primary) 8%, var(--mj-bg-surface));\n}\n.mj-form-variant-picker-row.inactive {\n opacity: 0.7;\n}\n.mj-form-variant-picker-row-main {\n display: flex;\n flex-direction: column;\n gap: 2px;\n flex: 1;\n min-width: 0;\n}\n.mj-form-variant-picker-row-title {\n font-size: 13px;\n font-weight: 600;\n color: var(--mj-text-primary);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.mj-form-variant-picker-row-sub {\n font-size: 11px;\n color: var(--mj-text-muted);\n}\n.mj-form-variant-picker-check {\n color: var(--mj-brand-primary);\n font-size: 11px;\n}\n\n/* Retrospective fix #8 \u2014 visually distinguish the Default row from variants. */\n.mj-form-variant-picker-row.mj-form-variant-picker-default {\n border-bottom: 1px dashed var(--mj-border-default);\n margin-bottom: 4px;\n padding-bottom: 10px;\n}\n.mj-form-variant-picker-default-tag {\n color: var(--mj-text-muted);\n font-weight: 400;\n font-size: 11px;\n margin-left: 4px;\n}\n"] }]
|
|
1966
|
+
args: [{ standalone: false, selector: 'mj-record-form-container', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, providers: [FormSlotCoordinator, FormChromeCoordinator, FormRecordRefreshCoordinator], 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 Hidden entirely when Config.Toolbar === null (dialog/slide-in surfaces).\n ============================================ -->\n@if (EffectiveShowToolbar) {\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 [AttachmentCount]=\"AttachmentCount\"\n [AttachmentsAvailable]=\"AttachmentsAvailable\"\n [IsAttachmentsPanelOpen]=\"ShowAttachmentsPanel\"\n [VersionCount]=\"VersionCount\"\n [EntityInfo]=\"EffectiveEntityInfo\"\n [Config]=\"EffectiveToolbarConfig\"\n [IsSaving]=\"EffectiveIsSaving\"\n [IsRefreshing]=\"EffectiveIsRefreshing\"\n [VisibleSectionCount]=\"VisibleSectionCount\"\n [TotalSectionCount]=\"TotalSectionCount\"\n [ExpandedSectionCount]=\"ExpandedSectionCount\"\n [SearchFilter]=\"EffectiveSearchFilter\"\n [ShowEmptyFields]=\"EffectiveShowEmptyFields\"\n [WidthMode]=\"EffectiveWidthMode\"\n [HasCustomSectionOrder]=\"EffectiveHasCustomSectionOrder\"\n [ChromeLayout]=\"ChromeLayout\"\n [Variants]=\"EffectiveVariants\"\n [CurrentVariantID]=\"EffectiveCurrentVariantID\"\n [RegisteredItems]=\"EffectiveRegisteredToolbarItems\"\n [ItemOverrides]=\"EffectiveToolbarItemOverrides\"\n [FormComponent]=\"fc\"\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 (BeforeRefresh)=\"BeforeRefresh.emit($event)\"\n (RefreshRequested)=\"OnRefreshRequested()\"\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 (ToolbarItemClick)=\"ToolbarItemClick.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 (AttachmentsPanelToggled)=\"OnAttachmentsPanelToggled()\"\n (VariantPicked)=\"OnVariantPicked($event)\">\n</mj-form-toolbar>\n}\n\n<!-- ============================================\n SCROLL AREA (full-width so mouse wheel works anywhere)\n Variant picker is now embedded in <mj-form-toolbar> as a right-side\n button \u2014 see the [Variants]/[CurrentVariantID] inputs + (VariantPicked)\n output on the toolbar above. Inline strip was removed.\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: optional left-nav + form panels + ISA side panel -->\n <div class=\"mj-forms-layout-row\"\n [class.mj-forms-layout--left-nav]=\"ChromeLayout === 'left-nav'\"\n [class.mj-forms-layout--accordion]=\"ChromeLayout === 'accordion'\"\n [class.mj-forms-layout--more]=\"IsChromeMoreActive\">\n @if (ShowChromeRail) {\n <nav class=\"mj-forms-chrome-rail\"\n [class.is-collapsed]=\"ChromeRailCollapsed\"\n [class.is-resizing]=\"RailResizing\"\n [style.width.px]=\"ChromeRailCollapsed ? null : ChromeRailWidthPx\"\n [attr.aria-expanded]=\"!ChromeRailCollapsed\"\n aria-label=\"Form sections\">\n @if (ChromeRailCollapsed) {\n <button type=\"button\"\n class=\"mj-forms-chrome-rail-spine\"\n (click)=\"OnChromeRailExpand()\"\n [attr.aria-label]=\"'Show form sections \u2014 ' + ChromeActiveTitle\"\n [title]=\"'Show sections \u2014 ' + ChromeActiveTitle\">\n <i [class]=\"ChromeActiveIcon\"></i>\n <span class=\"mj-forms-chrome-rail-spine-label\"\n (mouseenter)=\"OnRailLabelHover($event, ChromeActiveTitle)\">{{ ChromeActiveTitle }}</span>\n </button>\n } @else {\n <div class=\"mj-forms-chrome-rail-resizer\"\n role=\"separator\"\n aria-orientation=\"vertical\"\n [attr.aria-valuenow]=\"ChromeRailWidthPx\"\n [attr.aria-valuemin]=\"RailWidthMin\"\n [attr.aria-valuemax]=\"RailWidthMax\"\n title=\"Drag to resize sections\"\n (pointerdown)=\"OnRailResizeStart($event)\"\n (pointermove)=\"OnRailResizeMove($event)\"\n (pointerup)=\"OnRailResizeEnd()\"\n (pointercancel)=\"OnRailResizeEnd()\"></div>\n <div class=\"mj-forms-chrome-rail-toolbar\">\n <button type=\"button\"\n class=\"mj-forms-chrome-rail-pin\"\n [class.is-pinned]=\"ChromeRailPinned\"\n [attr.aria-pressed]=\"ChromeRailPinned\"\n [title]=\"ChromeRailPinned ? 'Unpin sections \u2014 they hide after you switch' : 'Pin sections open'\"\n (click)=\"OnChromeRailPinToggle()\">\n <i class=\"fa-solid fa-thumbtack\"></i>\n </button>\n <button type=\"button\"\n class=\"mj-forms-chrome-rail-collapse\"\n title=\"Hide sections\"\n aria-label=\"Hide form sections\"\n (click)=\"OnChromeRailCollapse()\">\n <i class=\"fa-solid fa-angles-left\"></i>\n </button>\n </div>\n @for (group of ChromeFirstClassGroups; track group.Key) {\n <div class=\"mj-forms-chrome-rail-item\"\n role=\"button\"\n tabindex=\"0\"\n [class.is-active]=\"ChromeActiveGroupKey === group.Key\"\n [attr.aria-current]=\"ChromeActiveGroupKey === group.Key ? 'page' : null\"\n [class.is-drag-over]=\"RailDragOverKey === group.Key\"\n (click)=\"OnChromeGroupActivate(group.Key)\"\n (keydown.enter)=\"OnChromeGroupActivate(group.Key)\"\n (keydown.space)=\"$event.preventDefault(); OnChromeGroupActivate(group.Key)\"\n (dragover)=\"OnRailDragOver($event, group.Key)\"\n (dragleave)=\"OnRailDragLeave($event, group.Key)\"\n (drop)=\"OnRailDrop($event, group.Key)\">\n @if (ChromeReorderAllowed) {\n <span class=\"mj-forms-chrome-rail-handle\"\n title=\"Drag to reorder\"\n draggable=\"true\"\n (dragstart)=\"OnRailDragStart($event, group.Key)\"\n (dragend)=\"OnRailDragEnd()\"\n (click)=\"$event.stopPropagation()\">\n <i class=\"fa-solid fa-grip-vertical\"></i>\n </span>\n }\n <i [class]=\"group.Icon\"></i>\n <span class=\"mj-forms-chrome-rail-label\"\n (mouseenter)=\"OnRailLabelHover($event, group.Title)\">{{ group.Title }}</span>\n @let rowCount = ChromeGroupRowCount(group);\n @if (rowCount != null) {\n <span class=\"mj-forms-chrome-rail-count\"\n [class.is-zero]=\"rowCount === 0\">{{ rowCount }}</span>\n }\n </div>\n }\n @if (ChromeMoreFolder; as more) {\n <div class=\"mj-forms-chrome-rail-item is-more-folder\"\n role=\"button\"\n tabindex=\"0\"\n [class.is-expanded]=\"MoreExpanded\"\n (click)=\"OnMoreFolderToggle()\"\n (keydown.enter)=\"OnMoreFolderToggle()\"\n (keydown.space)=\"$event.preventDefault(); OnMoreFolderToggle()\">\n <span class=\"mj-forms-chrome-rail-handle is-spacer\" aria-hidden=\"true\"></span>\n <i [class]=\"MoreExpanded ? 'fa-solid fa-folder-open' : 'fa-solid fa-folder'\"></i>\n <span class=\"mj-forms-chrome-rail-label\"\n (mouseenter)=\"OnRailLabelHover($event, more.Title)\">{{ more.Title }}</span>\n <i class=\"fa-solid mj-forms-chrome-rail-more-toggle\"\n [class.fa-minus]=\"MoreExpanded\"\n [class.fa-plus]=\"!MoreExpanded\"\n aria-hidden=\"true\"></i>\n </div>\n @if (MoreExpanded) {\n <div class=\"mj-forms-chrome-rail-more-tree\">\n @for (child of ChromeMoreItems; track child.Key) {\n <div class=\"mj-forms-chrome-rail-item is-more-child\"\n role=\"button\"\n tabindex=\"0\"\n [class.is-active]=\"ChromeActiveGroupKey === child.Key\"\n [attr.aria-current]=\"ChromeActiveGroupKey === child.Key ? 'page' : null\"\n [class.is-drag-over]=\"RailDragOverKey === child.Key\"\n (click)=\"OnChromeGroupActivate(child.Key)\"\n (keydown.enter)=\"OnChromeGroupActivate(child.Key)\"\n (keydown.space)=\"$event.preventDefault(); OnChromeGroupActivate(child.Key)\"\n (dragover)=\"OnRailDragOver($event, child.Key)\"\n (dragleave)=\"OnRailDragLeave($event, child.Key)\"\n (drop)=\"OnRailDrop($event, child.Key)\">\n @if (ChromeReorderAllowed) {\n <span class=\"mj-forms-chrome-rail-handle\"\n title=\"Drag to reorder\"\n draggable=\"true\"\n (dragstart)=\"OnRailDragStart($event, child.Key)\"\n (dragend)=\"OnRailDragEnd()\"\n (click)=\"$event.stopPropagation()\">\n <i class=\"fa-solid fa-grip-vertical\"></i>\n </span>\n }\n <i [class]=\"child.Icon\"></i>\n <span class=\"mj-forms-chrome-rail-label\"\n (mouseenter)=\"OnRailLabelHover($event, child.Title)\">{{ child.Title }}</span>\n @let childCount = ChromeGroupRowCount(child);\n @if (childCount != null) {\n <span class=\"mj-forms-chrome-rail-count\"\n [class.is-zero]=\"childCount === 0\">{{ childCount }}</span>\n }\n </div>\n }\n </div>\n }\n }\n }\n </nav>\n }\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 <!--\n Fill-in related grids for DisplayInForm relationships the template\n did not bake and no registered panel claimed. Claimed / extra panels\n still mount via mj-form-panel-slot. See plans/form-contributions.md.\n -->\n @if (Record && FormComponent) {\n <mj-form-contributions\n [Record]=\"Record\"\n [FormComponent]=\"FormComponent\"\n [FormContext]=\"FormComponent.formContext\"\n [BakedSectionKeys]=\"BakedRelatedSectionKeys\"\n [ShowRelatedEntities]=\"EffectiveShowRelatedEntities\">\n </mj-form-contributions>\n }\n\n <!--\n Container-provided fallback slot. ALWAYS present \u2014 last in document\n order \u2014 so any panel whose registered slot isn't found in the current\n form falls through here via FormSlotCoordinator's chain. Downstream\n consumers that haven't rerun CodeGen against the slot-emitting\n template still see every panel; they just render at the bottom\n instead of at their preferred position.\n -->\n @if (ShowMoreToggle) {\n <div class=\"mj-forms-more-overflow\" [class.is-expanded]=\"MoreExpanded\">\n <button type=\"button\"\n class=\"mj-forms-more-overflow-toggle\"\n (click)=\"OnMoreToggle()\">\n <i [class]=\"MoreExpanded ? 'fa-solid fa-folder-open' : 'fa-solid fa-folder'\"></i>\n <span class=\"mj-forms-more-overflow-label\">{{ MoreExpanded ? 'Hide more' : 'More' }}</span>\n @if (!MoreExpanded && MorePreview) {\n <span class=\"mj-forms-more-overflow-preview\">{{ MorePreview }}</span>\n }\n <i class=\"fa-solid\"\n [class.fa-chevron-down]=\"MoreExpanded\"\n [class.fa-chevron-right]=\"!MoreExpanded\"></i>\n </button>\n </div>\n }\n\n @if (Record && FormComponent) {\n <mj-form-panel-slot\n [Entity]=\"Record.EntityInfo.Name\"\n Slot=\"after-everything\"\n [Record]=\"Record\"\n [FormComponent]=\"FormComponent\">\n </mj-form-panel-slot>\n }\n\n <!-- Empty state when no sections match search -->\n @if (EffectiveSearchFilter && SearchHasNoMatches) {\n <mj-empty-state class=\"mj-forms-empty-search-state\"\n Variant=\"no-results\"\n Title=\"No sections found\"\n [Message]=\"'No sections match "' + EffectiveSearchFilter + '". Try a different search term.'\"\n ActionText=\"Clear search\"\n ActionIcon=\"fa-solid fa-rotate-left\"\n ActionVariant=\"flat\"\n (Action)=\"OnFilterChange('')\" />\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 ATTACHMENTS PANEL (shown when attachments button clicked)\n ============================================ -->\n@if (ShowAttachmentsPanel && AttachmentsAvailable && EffectiveRecord) {\n <mj-record-attachments\n [Record]=\"EffectiveRecord\"\n [Visible]=\"true\"\n (PanelClosed)=\"OnAttachmentsPanelClosed()\"\n (AttachmentCountChanged)=\"OnAttachmentCountChanged($event)\">\n </mj-record-attachments>\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)=\"OnListManagementComplete($event)\"\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 [MoreSectionKeys]=\"SectionManagerMoreKeys\"\n [LockedMoreKeys]=\"SectionManagerLockedMoreKeys\"\n [Visible]=\"ShowSectionManager\"\n (SectionOrderChange)=\"OnSectionOrderChange($event)\"\n (MembershipChange)=\"OnChromeMembershipChange($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 display: flex;\n flex-direction: column;\n min-height: 0;\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 flex: 1;\n min-height: 0;\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.mj-forms-panels-container:has(.mj-forms-layout--left-nav) {\n padding: 16px 20px 24px;\n display: flex;\n flex-direction: column;\n /* Definite height = the scroll-area's client box. min-height: 100% alone\n lets the column grow with content and never gives related grids a\n containing-block height, so Height:auto (100%) on the grid collapses. */\n height: 100%;\n max-height: 100%;\n min-height: 0;\n overflow: hidden;\n box-sizing: border-box;\n}\n\n/* Centered left-nav keeps the form column at the same 920px as accordion,\n plus the rail. Full-width still uses .mj-forms-panels--full-width. */\n.mj-forms-panels-container:has(.mj-forms-layout--left-nav):not(.mj-forms-panels--full-width) {\n max-width: 1160px;\n}\n\n.mj-forms-layout-row.mj-forms-layout--left-nav {\n flex: 1;\n min-height: 0;\n /* Wins over .mj-forms-layout-row { align-items: flex-start } so the\n body column stretches to the rail / viewport instead of hugging content. */\n align-items: stretch;\n gap: 16px;\n}\n\n/* Left-nav: only the active rail item is in the body. Slot-mounted\n panels never inject the container coordinator, so host classes set\n from the container are the hide/show channel that always reaches them. */\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-chrome-hidden,\n.mj-forms-layout--accordion mj-collapsible-panel.mj-chrome-hidden {\n display: none;\n}\n\n/* Selected item: no accordion chrome \u2014 the rail is the header. */\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-chrome-show .mj-forms-panel-header {\n display: none;\n}\n\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-chrome-show .mj-forms-panel {\n box-shadow: none;\n border: 0;\n background: transparent;\n border-radius: 0;\n}\n\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-chrome-show .mj-forms-panel-body--collapsed {\n max-height: none;\n padding: 0;\n opacity: 1;\n}\n\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-chrome-show .mj-forms-panel-content {\n max-height: none;\n padding: 0;\n overflow: visible;\n}\n\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-panel--related-entity.mj-chrome-show {\n /* Content-sized (see RelatedGridHeightPx). Do not flex-fill leftover\n column space \u2014 a form header above the grid can collapse that to 0. */\n flex: 0 0 auto;\n min-height: 0;\n}\n\n/* Accordion related panels use a 400px resizable box. Left-nav grids\n set their own pixel height from row count (RelatedGridHeightPx). */\n.mj-forms-layout--left-nav mj-collapsible-panel.mj-panel--related-entity.mj-chrome-show .mj-forms-panel-content {\n height: auto;\n max-height: none;\n overflow: hidden;\n resize: none;\n}\n\n.mj-forms-layout--left-nav .mj-forms-all-panels {\n gap: 0;\n min-height: 0;\n overflow-y: auto;\n}\n\n/* Details (field panels) can be taller than the viewport \u2014 scroll inside the\n column. Related grids scroll inside AG Grid instead. */\n.mj-forms-layout--left-nav .mj-forms-all-panels:has(mj-collapsible-panel.mj-chrome-show:not(.mj-panel--related-entity)) {\n overflow-y: auto;\n}\n\n.mj-forms-layout--left-nav .mj-forms-all-panels > *:not(mj-collapsible-panel.mj-panel--related-entity) {\n flex-shrink: 0;\n}\n\n.mj-forms-layout--left-nav .biz-hero {\n margin-bottom: 4px;\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.mj-forms-panels--edit-mode .mj-forms-more-overflow {\n display: none;\n}\n\n/* Detail / More panels sort after the overflow footer */\nmj-collapsible-panel.mj-form-role-detail,\nmj-collapsible-panel.mj-form-role-more {\n order: 8500;\n}\n\n.mj-forms-more-overflow {\n order: 8400;\n display: flex;\n flex-direction: column;\n margin-top: 4px;\n padding-top: 12px;\n border-top: 1px dashed var(--mj-border-subtle);\n}\n\n.mj-forms-more-overflow-toggle {\n display: flex;\n align-items: center;\n gap: 10px;\n width: 100%;\n padding: 6px 2px;\n border: 0;\n background: transparent;\n color: var(--mj-text-muted);\n font-size: var(--mj-text-sm);\n cursor: pointer;\n text-align: left;\n}\n\n.mj-forms-more-overflow-toggle:hover {\n color: var(--mj-text-secondary);\n}\n\n.mj-forms-more-overflow-label {\n font-weight: var(--mj-font-semibold);\n}\n\n.mj-forms-more-overflow-preview {\n flex: 1;\n min-width: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n color: var(--mj-text-disabled);\n font-weight: var(--mj-font-normal);\n}\n\n.mj-forms-more-overflow-toggle .fa-chevron-right,\n.mj-forms-more-overflow-toggle .fa-chevron-down {\n margin-left: auto;\n}\n\n.mj-forms-chrome-rail {\n flex: 0 0 auto;\n width: 200px;\n max-width: 360px;\n min-width: 160px;\n display: flex;\n flex-direction: column;\n gap: 4px;\n position: sticky;\n top: 0;\n align-self: stretch;\n min-height: 0;\n padding: 4px;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-subtle);\n border-radius: var(--mj-radius-md);\n}\n\n.mj-forms-chrome-rail.is-resizing {\n user-select: none;\n}\n\n.mj-forms-chrome-rail.is-collapsed {\n flex: 0 0 36px;\n width: 36px;\n min-width: 36px;\n max-width: 36px;\n padding: 8px 0;\n overflow: hidden;\n}\n\n.mj-forms-chrome-rail-resizer {\n position: absolute;\n top: 0;\n right: -4px;\n width: 8px;\n height: 100%;\n cursor: col-resize;\n z-index: 3;\n touch-action: none;\n}\n\n.mj-forms-chrome-rail-resizer::after {\n content: '';\n position: absolute;\n top: 12px;\n bottom: 12px;\n left: 3px;\n width: 2px;\n border-radius: 1px;\n background: transparent;\n}\n\n.mj-forms-chrome-rail:hover .mj-forms-chrome-rail-resizer::after,\n.mj-forms-chrome-rail.is-resizing .mj-forms-chrome-rail-resizer::after {\n background: var(--mj-border-strong);\n}\n\n.mj-forms-layout--right-nav .mj-forms-chrome-rail-resizer {\n right: auto;\n left: -4px;\n}\n\n.mj-forms-chrome-rail-spine {\n display: flex;\n flex-direction: column;\n align-items: center;\n gap: 10px;\n width: 100%;\n height: 100%;\n min-height: 0;\n padding: 8px 0;\n border: 0;\n background: transparent;\n color: var(--mj-brand-primary);\n cursor: pointer;\n}\n\n.mj-forms-chrome-rail-spine:hover {\n background: color-mix(in srgb, var(--mj-brand-primary) 10%, transparent);\n}\n\n.mj-forms-chrome-rail-spine > i {\n flex-shrink: 0;\n}\n\n.mj-forms-chrome-rail-spine-label {\n writing-mode: vertical-rl;\n transform: rotate(180deg);\n letter-spacing: 0.04em;\n font-size: var(--mj-text-sm);\n font-weight: var(--mj-font-semibold);\n color: var(--mj-text-primary);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n max-height: 100%;\n}\n\n.mj-forms-chrome-rail-toolbar {\n display: flex;\n align-items: center;\n justify-content: flex-end;\n gap: 2px;\n padding: 2px 4px 6px;\n}\n\n.mj-forms-chrome-rail-pin,\n.mj-forms-chrome-rail-collapse {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 26px;\n height: 26px;\n border: 0;\n border-radius: var(--mj-radius-sm);\n background: transparent;\n color: var(--mj-text-muted);\n cursor: pointer;\n}\n\n.mj-forms-chrome-rail-pin:hover,\n.mj-forms-chrome-rail-collapse:hover {\n background: var(--mj-bg-surface-hover);\n color: var(--mj-text-primary);\n}\n\n.mj-forms-chrome-rail-pin:not(.is-pinned) i {\n transform: rotate(45deg);\n}\n\n.mj-forms-chrome-rail-pin.is-pinned {\n color: var(--mj-brand-primary);\n}\n\n.mj-forms-chrome-rail-item {\n position: relative;\n display: flex;\n align-items: center;\n gap: 8px;\n width: 100%;\n padding: 10px 12px;\n border: 0;\n border-radius: var(--mj-radius-sm);\n background: transparent;\n color: var(--mj-text-muted);\n font-size: var(--mj-text-sm);\n text-align: left;\n cursor: pointer;\n}\n\n.mj-forms-chrome-rail-item > i {\n width: 1.15em;\n flex-shrink: 0;\n text-align: center;\n color: inherit;\n}\n\n.mj-forms-chrome-rail-item:hover {\n background: var(--mj-bg-surface-hover);\n color: var(--mj-text-primary);\n}\n\n.mj-forms-chrome-rail-item.is-active {\n background: color-mix(in srgb, var(--mj-brand-primary) 16%, var(--mj-bg-surface));\n color: var(--mj-brand-primary);\n font-weight: var(--mj-font-semibold);\n}\n\n.mj-forms-chrome-rail-item.is-active::before {\n content: '';\n position: absolute;\n left: 0;\n top: 6px;\n bottom: 6px;\n width: 3px;\n border-radius: 0 3px 3px 0;\n background: var(--mj-brand-primary);\n}\n\n.mj-forms-chrome-rail-item.is-active .mj-forms-chrome-rail-label {\n color: var(--mj-brand-primary);\n}\n\n.mj-forms-chrome-rail-item.is-drag-over {\n outline: 1px dashed var(--mj-border-focus);\n outline-offset: -1px;\n}\n\n.mj-forms-chrome-rail-handle {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 14px;\n height: 18px;\n margin-left: -4px;\n color: var(--mj-text-muted);\n cursor: grab;\n opacity: 0;\n overflow: hidden;\n flex-shrink: 0;\n transition: opacity var(--mj-transition-base, 0.15s) ease;\n}\n\n.mj-forms-chrome-rail-item:hover .mj-forms-chrome-rail-handle,\n.mj-forms-chrome-rail-item.is-active .mj-forms-chrome-rail-handle {\n opacity: 1;\n}\n\n.mj-forms-chrome-rail-handle.is-spacer {\n opacity: 0;\n pointer-events: none;\n cursor: default;\n}\n\n.mj-forms-chrome-rail-handle:hover {\n color: var(--mj-brand-primary);\n}\n\n.mj-forms-chrome-rail-handle:active {\n cursor: grabbing;\n}\n\n.mj-forms-chrome-rail-item.is-more-folder {\n position: relative;\n margin-top: 14px;\n padding-top: 14px;\n color: var(--mj-text-muted);\n border-radius: 0;\n}\n\n.mj-forms-chrome-rail-item.is-more-folder::before {\n content: '';\n position: absolute;\n top: 0;\n left: 8px;\n right: 8px;\n height: 1px;\n background: linear-gradient(\n 90deg,\n transparent 0%,\n var(--mj-border-strong) 18%,\n var(--mj-border-strong) 82%,\n transparent 100%\n );\n}\n\n.mj-forms-chrome-rail-item.is-more-folder:hover {\n background: transparent;\n color: var(--mj-text-secondary);\n}\n\n.mj-forms-chrome-rail-item.is-more-folder.is-expanded {\n color: var(--mj-text-secondary);\n}\n\n.mj-forms-chrome-rail-more-toggle {\n margin-left: auto;\n font-size: 10px;\n color: var(--mj-text-muted);\n}\n\n.mj-forms-chrome-rail-more-tree {\n margin-left: 22px;\n padding-left: 6px;\n border-left: 1px solid var(--mj-border-subtle);\n}\n\n.mj-forms-chrome-rail-item.is-more-child {\n padding-left: 8px;\n}\n\n.mj-forms-chrome-rail-count.is-zero {\n opacity: 0.55;\n}\n\n.mj-forms-chrome-rail-label {\n flex: 1;\n min-width: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.mj-forms-chrome-rail-count {\n min-width: 1.25rem;\n padding: 0 6px;\n border-radius: var(--mj-radius-full);\n background: var(--mj-bg-surface-sunken);\n color: var(--mj-text-muted);\n font-size: var(--mj-text-xs);\n text-align: center;\n}\n\n@media (max-width: 720px) {\n .mj-forms-layout--left-nav {\n flex-direction: column;\n }\n\n .mj-forms-chrome-rail {\n flex: 1 1 auto;\n width: 100%;\n position: static;\n flex-direction: row;\n flex-wrap: wrap;\n }\n\n .mj-forms-chrome-rail-resizer {\n display: none;\n }\n\n .mj-forms-chrome-rail.is-collapsed {\n flex: 0 0 auto;\n width: 100%;\n min-width: 0;\n max-width: none;\n height: 36px;\n padding: 0;\n }\n\n .mj-forms-chrome-rail-spine {\n flex-direction: row;\n padding: 0 12px;\n }\n\n .mj-forms-chrome-rail-spine-label {\n writing-mode: horizontal-tb;\n transform: none;\n max-height: none;\n }\n\n .mj-forms-chrome-rail-toolbar {\n width: 100%;\n }\n\n .mj-forms-chrome-rail-item {\n width: auto;\n }\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\n/* ====================================================================\n VARIANT PICKER \u2014 between toolbar and form body\n Compact \"Form: <name> \u25BE\" row that appears when more than one variant\n is applicable for the current entity record.\n ==================================================================== */\n\n.mj-form-variant-picker {\n display: flex;\n align-items: center;\n gap: 10px;\n padding: 6px 18px;\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n font-size: 12px;\n color: var(--mj-text-secondary);\n}\n.mj-form-variant-picker-icon {\n color: var(--mj-brand-primary);\n font-size: 12px;\n}\n.mj-form-variant-picker-label {\n font-weight: 600;\n color: var(--mj-text-secondary);\n}\n.mj-form-variant-picker-control {\n position: relative;\n display: inline-flex;\n align-items: center;\n gap: 6px;\n padding: 4px 10px;\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-md, 8px);\n background: var(--mj-bg-surface);\n color: var(--mj-text-primary);\n cursor: pointer;\n outline: none;\n user-select: none;\n min-width: 160px;\n}\n.mj-form-variant-picker-control:hover,\n.mj-form-variant-picker-control:focus,\n.mj-form-variant-picker-control.open {\n border-color: var(--mj-border-focus);\n box-shadow: 0 0 0 3px color-mix(in srgb, var(--mj-brand-primary) 15%, transparent);\n}\n.mj-form-variant-picker-current {\n font-weight: 600;\n flex: 1;\n}\n.mj-form-variant-picker-menu {\n position: absolute;\n top: calc(100% + 4px);\n left: 0;\n z-index: 50;\n min-width: 280px;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-md, 8px);\n box-shadow: var(--mj-shadow-md, 0 4px 12px rgba(15, 23, 42, 0.08));\n padding: 4px;\n max-height: 320px;\n overflow: auto;\n}\n.mj-form-variant-picker-row {\n display: flex;\n align-items: center;\n gap: 10px;\n padding: 8px 10px;\n border-radius: 6px;\n cursor: pointer;\n}\n.mj-form-variant-picker-row:hover {\n background: var(--mj-bg-surface-hover);\n}\n.mj-form-variant-picker-row.current {\n background: color-mix(in srgb, var(--mj-brand-primary) 8%, var(--mj-bg-surface));\n}\n.mj-form-variant-picker-row.inactive {\n opacity: 0.7;\n}\n.mj-form-variant-picker-row-main {\n display: flex;\n flex-direction: column;\n gap: 2px;\n flex: 1;\n min-width: 0;\n}\n.mj-form-variant-picker-row-title {\n font-size: 13px;\n font-weight: 600;\n color: var(--mj-text-primary);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.mj-form-variant-picker-row-sub {\n font-size: 11px;\n color: var(--mj-text-muted);\n}\n.mj-form-variant-picker-check {\n color: var(--mj-brand-primary);\n font-size: 11px;\n}\n\n/* Retrospective fix #8 \u2014 visually distinguish the Default row from variants. */\n.mj-form-variant-picker-row.mj-form-variant-picker-default {\n border-bottom: 1px dashed var(--mj-border-default);\n margin-bottom: 4px;\n padding-bottom: 10px;\n}\n.mj-form-variant-picker-default-tag {\n color: var(--mj-text-muted);\n font-weight: 400;\n font-size: 11px;\n margin-left: 4px;\n}\n"] }]
|
|
874
1967
|
}], null, { recordChangesDrawer: [{
|
|
875
1968
|
type: ViewChild,
|
|
876
1969
|
args: [RecordChangesComponent]
|
|
@@ -898,8 +1991,14 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
898
1991
|
type: Input
|
|
899
1992
|
}], IsSaving: [{
|
|
900
1993
|
type: Input
|
|
1994
|
+
}], IsRefreshing: [{
|
|
1995
|
+
type: Input
|
|
901
1996
|
}], ToolbarConfig: [{
|
|
902
1997
|
type: Input
|
|
1998
|
+
}], RegisteredToolbarItems: [{
|
|
1999
|
+
type: Input
|
|
2000
|
+
}], ToolbarItemOverrides: [{
|
|
2001
|
+
type: Input
|
|
903
2002
|
}], WidthMode: [{
|
|
904
2003
|
type: Input
|
|
905
2004
|
}], Variants: [{
|
|
@@ -922,6 +2021,10 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
922
2021
|
type: Output
|
|
923
2022
|
}], DeleteRequested: [{
|
|
924
2023
|
type: Output
|
|
2024
|
+
}], BeforeRefresh: [{
|
|
2025
|
+
type: Output
|
|
2026
|
+
}], RefreshRequested: [{
|
|
2027
|
+
type: Output
|
|
925
2028
|
}], FavoriteToggled: [{
|
|
926
2029
|
type: Output
|
|
927
2030
|
}], BeforeHistoryView: [{
|
|
@@ -936,11 +2039,40 @@ export class MjRecordFormContainerComponent extends BaseAngularComponent {
|
|
|
936
2039
|
type: Output
|
|
937
2040
|
}], CustomButtonClick: [{
|
|
938
2041
|
type: Output
|
|
2042
|
+
}], ToolbarItemClick: [{
|
|
2043
|
+
type: Output
|
|
939
2044
|
}], VariantChange: [{
|
|
940
2045
|
type: Output
|
|
2046
|
+
}], BeforeLayoutResolve: [{
|
|
2047
|
+
type: Output
|
|
2048
|
+
}], AfterLayoutResolved: [{
|
|
2049
|
+
type: Output
|
|
2050
|
+
}], BeforeSectionActivate: [{
|
|
2051
|
+
type: Output
|
|
2052
|
+
}], AfterSectionActivated: [{
|
|
2053
|
+
type: Output
|
|
941
2054
|
}], Panels: [{
|
|
942
2055
|
type: ContentChildren,
|
|
943
2056
|
args: [MjCollapsiblePanelComponent, { descendants: true }]
|
|
944
2057
|
}] }); })();
|
|
945
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(MjRecordFormContainerComponent, { className: "MjRecordFormContainerComponent", filePath: "src/lib/container/record-form-container.component.ts", lineNumber:
|
|
2058
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(MjRecordFormContainerComponent, { className: "MjRecordFormContainerComponent", filePath: "src/lib/container/record-form-container.component.ts", lineNumber: 116 }); })();
|
|
2059
|
+
function contributionRailKey(meta) {
|
|
2060
|
+
if (meta.contributionKey?.trim()) {
|
|
2061
|
+
return meta.contributionKey.trim();
|
|
2062
|
+
}
|
|
2063
|
+
if (!meta.relatedEntity) {
|
|
2064
|
+
return null;
|
|
2065
|
+
}
|
|
2066
|
+
const derived = meta.relatedEntity.split(':').pop()?.trim();
|
|
2067
|
+
if (!derived) {
|
|
2068
|
+
return null;
|
|
2069
|
+
}
|
|
2070
|
+
return derived.charAt(0).toLowerCase() + derived.slice(1).replace(/\s+/g, '');
|
|
2071
|
+
}
|
|
2072
|
+
function ReadRegisteredInclusion(raw) {
|
|
2073
|
+
if (raw === 'Primary' || raw === 'More' || raw === 'None') {
|
|
2074
|
+
return raw;
|
|
2075
|
+
}
|
|
2076
|
+
return null;
|
|
2077
|
+
}
|
|
946
2078
|
//# sourceMappingURL=record-form-container.component.js.map
|