@memberjunction/ng-base-forms 6.1.4 → 6.2.0-edge.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/base-form-component.d.ts.map +1 -1
- package/dist/lib/base-form-component.js +43 -40
- package/dist/lib/base-form-component.js.map +1 -1
- package/dist/lib/base-form-section-info.js +5 -5
- package/dist/lib/base-form-section-info.js.map +1 -1
- package/dist/lib/chrome/resolve-form-chrome.d.ts.map +1 -1
- package/dist/lib/chrome/resolve-form-chrome.js +22 -12
- package/dist/lib/chrome/resolve-form-chrome.js.map +1 -1
- package/dist/lib/container/record-form-container.component.d.ts +24 -13
- package/dist/lib/container/record-form-container.component.d.ts.map +1 -1
- package/dist/lib/container/record-form-container.component.js +233 -182
- package/dist/lib/container/record-form-container.component.js.map +1 -1
- package/dist/lib/explorer-entity-data-grid.component.d.ts +32 -2
- package/dist/lib/explorer-entity-data-grid.component.d.ts.map +1 -1
- package/dist/lib/explorer-entity-data-grid.component.js +54 -13
- package/dist/lib/explorer-entity-data-grid.component.js.map +1 -1
- package/dist/lib/field/default-fk-lookup-strategy.d.ts +60 -0
- package/dist/lib/field/default-fk-lookup-strategy.d.ts.map +1 -0
- package/dist/lib/field/default-fk-lookup-strategy.js +173 -0
- package/dist/lib/field/default-fk-lookup-strategy.js.map +1 -0
- package/dist/lib/field/fk-lookup-strategy.d.ts +124 -0
- package/dist/lib/field/fk-lookup-strategy.d.ts.map +1 -0
- package/dist/lib/field/fk-lookup-strategy.js +97 -0
- package/dist/lib/field/fk-lookup-strategy.js.map +1 -0
- package/dist/lib/field/fk-search-utils.d.ts +33 -2
- package/dist/lib/field/fk-search-utils.d.ts.map +1 -1
- package/dist/lib/field/fk-search-utils.js +56 -3
- package/dist/lib/field/fk-search-utils.js.map +1 -1
- package/dist/lib/field/form-field.component.d.ts +166 -11
- package/dist/lib/field/form-field.component.d.ts.map +1 -1
- package/dist/lib/field/form-field.component.js +742 -338
- package/dist/lib/field/form-field.component.js.map +1 -1
- package/dist/lib/field/linked-field-options.d.ts +16 -0
- package/dist/lib/field/linked-field-options.d.ts.map +1 -1
- package/dist/lib/field/linked-field-options.js +17 -0
- package/dist/lib/field/linked-field-options.js.map +1 -1
- package/dist/lib/form-state.service.d.ts +58 -0
- package/dist/lib/form-state.service.d.ts.map +1 -1
- package/dist/lib/form-state.service.js +156 -40
- package/dist/lib/form-state.service.js.map +1 -1
- package/dist/lib/host/entity-form-host.component.d.ts +10 -2
- package/dist/lib/host/entity-form-host.component.d.ts.map +1 -1
- package/dist/lib/host/entity-form-host.component.js +24 -8
- package/dist/lib/host/entity-form-host.component.js.map +1 -1
- package/dist/lib/interactive-form/interactive-form.component.d.ts +16 -4
- package/dist/lib/interactive-form/interactive-form.component.d.ts.map +1 -1
- package/dist/lib/interactive-form/interactive-form.component.js +38 -12
- package/dist/lib/interactive-form/interactive-form.component.js.map +1 -1
- package/dist/lib/isa-related-panel/isa-related-card.component.d.ts +3 -3
- package/dist/lib/isa-related-panel/isa-related-card.component.d.ts.map +1 -1
- package/dist/lib/isa-related-panel/isa-related-card.component.js +12 -8
- package/dist/lib/isa-related-panel/isa-related-card.component.js.map +1 -1
- package/dist/lib/isa-related-panel/isa-related-panel.component.d.ts +3 -3
- 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 +24 -7
- package/dist/lib/isa-related-panel/isa-related-panel.component.js.map +1 -1
- package/dist/lib/overlays/form-slide-in.component.d.ts +2 -0
- package/dist/lib/overlays/form-slide-in.component.d.ts.map +1 -1
- package/dist/lib/overlays/form-slide-in.component.js +5 -1
- package/dist/lib/overlays/form-slide-in.component.js.map +1 -1
- package/dist/lib/panel/collapsible-panel.component.d.ts +72 -9
- package/dist/lib/panel/collapsible-panel.component.d.ts.map +1 -1
- package/dist/lib/panel/collapsible-panel.component.js +185 -43
- package/dist/lib/panel/collapsible-panel.component.js.map +1 -1
- package/dist/lib/panel-slot/base-form-panel.d.ts +2 -0
- package/dist/lib/panel-slot/base-form-panel.d.ts.map +1 -1
- package/dist/lib/panel-slot/base-form-panel.js +5 -1
- package/dist/lib/panel-slot/base-form-panel.js.map +1 -1
- package/dist/lib/panel-slot/form-contribution.d.ts +12 -0
- package/dist/lib/panel-slot/form-contribution.d.ts.map +1 -1
- package/dist/lib/panel-slot/form-contribution.js +43 -10
- package/dist/lib/panel-slot/form-contribution.js.map +1 -1
- package/dist/lib/panel-slot/form-slot-coordinator.service.d.ts +10 -0
- package/dist/lib/panel-slot/form-slot-coordinator.service.d.ts.map +1 -1
- package/dist/lib/panel-slot/form-slot-coordinator.service.js +25 -5
- package/dist/lib/panel-slot/form-slot-coordinator.service.js.map +1 -1
- package/dist/lib/panel-slot/related-entity-grid-panel.component.d.ts +2 -0
- package/dist/lib/panel-slot/related-entity-grid-panel.component.d.ts.map +1 -1
- package/dist/lib/panel-slot/related-entity-grid-panel.component.js +5 -1
- package/dist/lib/panel-slot/related-entity-grid-panel.component.js.map +1 -1
- package/dist/lib/section-indicators/form-section-field-host.d.ts +53 -0
- package/dist/lib/section-indicators/form-section-field-host.d.ts.map +1 -0
- package/dist/lib/section-indicators/form-section-field-host.js +23 -0
- package/dist/lib/section-indicators/form-section-field-host.js.map +1 -0
- package/dist/lib/section-loader-component.d.ts +5 -1
- package/dist/lib/section-loader-component.d.ts.map +1 -1
- package/dist/lib/section-loader-component.js +13 -5
- package/dist/lib/section-loader-component.js.map +1 -1
- package/dist/lib/section-manager/section-manager.component.d.ts +2 -2
- package/dist/lib/section-manager/section-manager.component.js +6 -6
- package/dist/lib/section-manager/section-manager.component.js.map +1 -1
- package/dist/lib/toolbar/form-toolbar.component.d.ts +5 -5
- package/dist/lib/toolbar/form-toolbar.component.js +22 -22
- package/dist/lib/toolbar/form-toolbar.component.js.map +1 -1
- package/dist/lib/types/form-types.d.ts +2 -0
- package/dist/lib/types/form-types.d.ts.map +1 -1
- package/dist/lib/types/form-types.js +5 -1
- package/dist/lib/types/form-types.js.map +1 -1
- package/dist/public-api.d.ts +3 -0
- package/dist/public-api.d.ts.map +1 -1
- package/dist/public-api.js +3 -0
- package/dist/public-api.js.map +1 -1
- package/package.json +18 -18
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"section-manager.component.js","sourceRoot":"","sources":["../../../src/lib/section-manager/section-manager.component.ts","../../../src/lib/section-manager/section-manager.component.html"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EAAE,KAAK,EAAE,MAAM,EAAE,YAAY,EACtC,uBAAuB,EAAE,iBAAiB,EAAE,MAAM,EAEnD,MAAM,eAAe,CAAC;;;;;ICkBT,AADF,+BAAuB,cACO;IAC1B,wBAAqD;IACrD,gCAA6B;IAAA,YAAyB;IAAA,iBAAO;IAC7D,4BAAqE;IACnE,YACF;IACF,AADE,iBAAO,EACH;IAEJ,AADF,+BAA+B,iBAIL;IADhB,+OAAS,8DAAoC,KAAC;IAEpD,wBAAsC;IACxC,iBAAS;IACT,mCAG0B;IADlB,gPAAS,gEAAsC,KAAC;IAEtD,yBAAwC;IAC1C,iBAAS;IACT,mCAE6B;IADrB,gPAAS,+BAAqB,KAAC;IAErC,yBAAuC;IAG7C,AADE,AADE,iBAAS,EACL,EACF;;;;;IAzBC,eAAsB;IAAtB,8BAAsB;IACI,eAAyB;IAAzB,4CAAyB;IAChD,cAA8D;IAA9D,cAAA,0EAA8D,CAAA;IAClE,cACF;IADE,2EACF;IAIQ,eAAoB;IAApB,8CAAoB;IAMpB,eAAgD;IAAhD,iFAAgD;;;IAc5D,+BAAyB;IAAA,wCAAwB;IAAA,iBAAM;;;;IAMrD,AADF,+BAA+B,cACD;IAC1B,wBAAqD;IACrD,gCAA6B;IAAA,YAAyB;IAAA,iBAAO;IAC7D,gCAAoD;IAAA,oBAAI;IAC1D,AAD0D,iBAAO,EAC3D;IAEJ,AADF,+BAA+B,iBAIL;IADhB,+OAAS,wDAA8B,KAAC;IAE9C,wBAAsC;IAC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AAU,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;aAC/B,MAAM,CAAC,CAAC,CAAC,EAA2B,EAAE,CAAC,CAAC,KAAK,SAAS,CAAC,CAAC;QAC3D,MAAM,OAAO,GAAG,IAAI,GAAG,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;QAC9C,IAAI,CAAC,kBAAkB,GAAG,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC;QACzF,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC;QAClF,IAAI,CAAC,GAAG,CAAC,YAAY,EAAE,CAAC;IAC1B,CAAC;mHAxLU,yBAAyB;6DAAzB,yBAAyB;YC9CtC,4FAAe;;YAAf,sCA4HC;;;iFD9EY,yBAAyB;cAPrC,SAAS;6BACI,KAAK,YACP,oBAAoB,mBACb,uBAAuB,CAAC,MAAM;;kBAQ9C,KAAK;;kBAGL,KAAK;;kBAGL,KAAK;;kBAGL,KAAK;;kBAGL,KAAK;;kBAGL,MAAM;;kBAGN,MAAM;;kBAGN,MAAM;;kBAGN,MAAM;;kFA5BI,yBAAyB","sourcesContent":["import {\n Component, Input, Output, EventEmitter,\n ChangeDetectionStrategy, ChangeDetectorRef, inject,\n OnChanges, SimpleChanges\n} from '@angular/core';\nimport { PanelVariant } from '../types/form-types';\n\n/**\n * Info about a section, passed from the container to the Section Manager drawer.\n */\nexport interface SectionManagerItem {\n SectionKey: string;\n SectionName: string;\n Variant: PanelVariant;\n Icon: string;\n}\n\nexport interface ChromeMembershipChange {\n moreSectionKeys: string[];\n firstClassSectionKeys: string[];\n}\n\n/**\n * Slide-in drawer for managing section order.\n *\n * Provides an accessible, keyboard-friendly alternative to drag-and-drop\n * for reordering form sections. Each section is displayed as a row with\n * up/down arrow buttons to change position.\n *\n * @example\n * ```html\n * <mj-section-manager\n * [Sections]=\"sectionList\"\n * [SectionOrder]=\"currentOrder\"\n * [Visible]=\"showDrawer\"\n * (SectionOrderChange)=\"onOrderChange($event)\"\n * (Closed)=\"showDrawer = false\">\n * </mj-section-manager>\n * ```\n */\n@Component({\n standalone: false,\n selector: 'mj-section-manager',\n changeDetection: ChangeDetectionStrategy.OnPush,\n templateUrl: './section-manager.component.html',\n styleUrls: ['./section-manager.component.css']\n})\nexport class MjSectionManagerComponent implements OnChanges {\n private cdr = inject(ChangeDetectorRef);\n\n /** All available sections (unordered) */\n @Input() Sections: SectionManagerItem[] = [];\n\n /** Current section order (array of section keys) */\n @Input() SectionOrder: string[] = [];\n\n /** Section keys currently in More. Empty keeps a single list. */\n @Input() MoreSectionKeys: string[] = [];\n\n /** Keys that cannot leave More (System Metadata). */\n @Input() LockedMoreKeys: string[] = [];\n\n /** Whether the drawer is visible */\n @Input() Visible = false;\n\n /** Emits the new section order when the user reorders */\n @Output() SectionOrderChange = new EventEmitter<string[]>();\n\n /** Emits when the user moves a section in or out of More. */\n @Output() MembershipChange = new EventEmitter<ChromeMembershipChange>();\n\n /** Emits when the drawer is closed */\n @Output() Closed = new EventEmitter<void>();\n\n /** Emits when the user resets to default order */\n @Output() ResetRequested = new EventEmitter<void>();\n\n /** Ordered list of sections for display */\n OrderedSections: SectionManagerItem[] = [];\n FirstClassSections: SectionManagerItem[] = [];\n MoreSections: SectionManagerItem[] = [];\n\n ngOnChanges(changes: SimpleChanges): void {\n if (changes['Sections'] || changes['SectionOrder'] || changes['MoreSectionKeys'] || changes['LockedMoreKeys']) {\n this.RebuildOrderedSections();\n }\n }\n\n get HasMoreGroup(): boolean {\n return this.MoreSections.length > 0 || this.MoreSectionKeys.length > 0;\n }\n\n IsLockedInMore(section: SectionManagerItem): boolean {\n return this.LockedMoreKeys.includes(section.SectionKey);\n }\n\n OnClose(): void {\n this.Closed.emit();\n }\n\n OnOverlayClick(event: MouseEvent): void {\n // Only close if clicking the overlay itself, not the drawer\n if (event.target === event.currentTarget) {\n this.OnClose();\n }\n }\n\n OnMoveUp(index: number): void {\n if (index <= 0) return;\n const newOrder = this.OrderedSections.map(s => s.SectionKey);\n [newOrder[index - 1], newOrder[index]] = [newOrder[index], newOrder[index - 1]];\n this.SectionOrderChange.emit(newOrder);\n this.ApplyOrder(newOrder);\n }\n\n OnMoveDown(index: number): void {\n if (index >= this.OrderedSections.length - 1) return;\n const newOrder = this.OrderedSections.map(s => s.SectionKey);\n [newOrder[index], newOrder[index + 1]] = [newOrder[index + 1], newOrder[index]];\n this.SectionOrderChange.emit(newOrder);\n this.ApplyOrder(newOrder);\n }\n\n OnMoveGroupUp(list: SectionManagerItem[], index: number): void {\n if (index <= 0) return;\n this.emitReorderedGroup(list, index, index - 1);\n }\n\n OnMoveGroupDown(list: SectionManagerItem[], index: number): void {\n if (index >= list.length - 1) return;\n this.emitReorderedGroup(list, index, index + 1);\n }\n\n OnMoveToMore(section: SectionManagerItem): void {\n if (this.MoreSectionKeys.includes(section.SectionKey)) return;\n const more = [...this.MoreSectionKeys, section.SectionKey];\n const firstClass = this.FirstClassSections\n .map((s) => s.SectionKey)\n .filter((key) => key !== section.SectionKey);\n this.MembershipChange.emit({ moreSectionKeys: more, firstClassSectionKeys: firstClass });\n }\n\n OnMoveToForm(section: SectionManagerItem): void {\n if (this.IsLockedInMore(section)) return;\n const more = this.MoreSectionKeys.filter((key) => key !== section.SectionKey);\n const firstClass = [\n ...this.FirstClassSections.map((s) => s.SectionKey),\n section.SectionKey,\n ];\n this.MembershipChange.emit({ moreSectionKeys: more, firstClassSectionKeys: firstClass });\n }\n\n private emitReorderedGroup(list: SectionManagerItem[], from: number, to: number): void {\n const keys = list.map((s) => s.SectionKey);\n [keys[from], keys[to]] = [keys[to], keys[from]];\n const other = list === this.FirstClassSections ? this.MoreSections : this.FirstClassSections;\n const combined = list === this.FirstClassSections\n ? [...keys, ...other.map((s) => s.SectionKey)]\n : [...other.map((s) => s.SectionKey), ...keys];\n this.SectionOrderChange.emit(combined);\n this.ApplyOrder(combined);\n }\n\n OnReset(): void {\n this.ResetRequested.emit();\n }\n\n GetVariantIcon(variant: PanelVariant): string {\n switch (variant) {\n case 'related-entity': return 'fa-solid fa-link';\n case 'inherited': return 'fa-solid fa-arrow-up';\n default: return 'fa-solid fa-table-cells';\n }\n }\n\n GetVariantLabel(variant: PanelVariant): string {\n switch (variant) {\n case 'related-entity': return 'Related';\n case 'inherited': return 'Inherited';\n default: return 'Fields';\n }\n }\n\n private RebuildOrderedSections(): void {\n if (!this.Sections || this.Sections.length === 0) {\n this.OrderedSections = [];\n return;\n }\n\n const sectionMap = new Map<string, SectionManagerItem>();\n for (const s of this.Sections) {\n sectionMap.set(s.SectionKey, s);\n }\n\n const ordered: SectionManagerItem[] = [];\n\n // Add sections in persisted order first\n if (this.SectionOrder && this.SectionOrder.length > 0) {\n for (const key of this.SectionOrder) {\n const section = sectionMap.get(key);\n if (section) {\n ordered.push(section);\n sectionMap.delete(key);\n }\n }\n }\n\n // Append any sections not in the persisted order (new sections)\n for (const section of sectionMap.values()) {\n ordered.push(section);\n }\n\n this.OrderedSections = ordered;\n const moreSet = new Set(this.MoreSectionKeys);\n this.FirstClassSections = ordered.filter((s) => !moreSet.has(s.SectionKey));\n this.MoreSections = ordered.filter((s) => moreSet.has(s.SectionKey));\n this.cdr.markForCheck();\n }\n\n private ApplyOrder(newOrder: string[]): void {\n const sectionMap = new Map<string, SectionManagerItem>();\n for (const s of this.OrderedSections) {\n sectionMap.set(s.SectionKey, s);\n }\n this.OrderedSections = newOrder\n .map(key => sectionMap.get(key))\n .filter((s): s is SectionManagerItem => s !== undefined);\n const moreSet = new Set(this.MoreSectionKeys);\n this.FirstClassSections = this.OrderedSections.filter((s) => !moreSet.has(s.SectionKey));\n this.MoreSections = this.OrderedSections.filter((s) => moreSet.has(s.SectionKey));\n this.cdr.markForCheck();\n }\n}\n","<!-- Overlay backdrop -->\n@if (Visible) {\n <div class=\"mj-sm-overlay\" (click)=\"OnOverlayClick($event)\">\n <!-- Drawer panel -->\n <div class=\"mj-sm-drawer\" (click)=\"$event.stopPropagation()\">\n <!-- Header -->\n <div class=\"mj-sm-header\">\n <h3 class=\"mj-sm-title\">\n <i class=\"fa-solid fa-bars-staggered\"></i>\n Manage Sections\n </h3>\n <button class=\"mj-sm-close\" (click)=\"OnClose()\" title=\"Close\">\n <i class=\"fa-solid fa-xmark\"></i>\n </button>\n </div>\n\n <!-- Section list -->\n <div class=\"mj-sm-list\">\n @if (HasMoreGroup) {\n <div class=\"mj-sm-group-label\">On the form</div>\n @for (section of FirstClassSections; track section.SectionKey; let i = $index) {\n <div class=\"mj-sm-row\">\n <div class=\"mj-sm-row-info\">\n <i [class]=\"section.Icon\" class=\"mj-sm-row-icon\"></i>\n <span class=\"mj-sm-row-name\">{{ section.SectionName }}</span>\n <span class=\"mj-sm-row-badge mj-sm-row-badge--{{ section.Variant }}\">\n {{ GetVariantLabel(section.Variant) }}\n </span>\n </div>\n <div class=\"mj-sm-row-actions\">\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === 0\"\n (click)=\"OnMoveGroupUp(FirstClassSections, i)\"\n title=\"Move up\">\n <i class=\"fa-solid fa-chevron-up\"></i>\n </button>\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === FirstClassSections.length - 1\"\n (click)=\"OnMoveGroupDown(FirstClassSections, i)\"\n title=\"Move down\">\n <i class=\"fa-solid fa-chevron-down\"></i>\n </button>\n <button class=\"mj-sm-arrow mj-sm-move\"\n (click)=\"OnMoveToMore(section)\"\n title=\"Move to More\">\n <i class=\"fa-solid fa-folder-plus\"></i>\n </button>\n </div>\n </div>\n }\n @if (FirstClassSections.length === 0) {\n <div class=\"mj-sm-empty\">Nothing on the form yet.</div>\n }\n\n <div class=\"mj-sm-group-label\">More</div>\n @for (section of MoreSections; track section.SectionKey; let i = $index) {\n <div class=\"mj-sm-row is-more\">\n <div class=\"mj-sm-row-info\">\n <i [class]=\"section.Icon\" class=\"mj-sm-row-icon\"></i>\n <span class=\"mj-sm-row-name\">{{ section.SectionName }}</span>\n <span class=\"mj-sm-row-badge mj-sm-row-badge--more\">More</span>\n </div>\n <div class=\"mj-sm-row-actions\">\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === 0\"\n (click)=\"OnMoveGroupUp(MoreSections, i)\"\n title=\"Move up\">\n <i class=\"fa-solid fa-chevron-up\"></i>\n </button>\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === MoreSections.length - 1\"\n (click)=\"OnMoveGroupDown(MoreSections, i)\"\n title=\"Move down\">\n <i class=\"fa-solid fa-chevron-down\"></i>\n </button>\n <button class=\"mj-sm-arrow mj-sm-move\"\n [disabled]=\"IsLockedInMore(section)\"\n (click)=\"OnMoveToForm(section)\"\n [title]=\"IsLockedInMore(section) ? 'Always in More' : 'Move to form'\">\n <i class=\"fa-solid fa-arrow-up-from-bracket\"></i>\n </button>\n </div>\n </div>\n }\n @if (MoreSections.length === 0) {\n <div class=\"mj-sm-empty\">Nothing in More.</div>\n }\n } @else {\n @for (section of OrderedSections; track section.SectionKey; let i = $index) {\n <div class=\"mj-sm-row\">\n <div class=\"mj-sm-row-info\">\n <i [class]=\"section.Icon\" class=\"mj-sm-row-icon\"></i>\n <span class=\"mj-sm-row-name\">{{ section.SectionName }}</span>\n <span class=\"mj-sm-row-badge mj-sm-row-badge--{{ section.Variant }}\">\n {{ GetVariantLabel(section.Variant) }}\n </span>\n </div>\n <div class=\"mj-sm-row-actions\">\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === 0\"\n (click)=\"OnMoveUp(i)\"\n title=\"Move up\">\n <i class=\"fa-solid fa-chevron-up\"></i>\n </button>\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === OrderedSections.length - 1\"\n (click)=\"OnMoveDown(i)\"\n title=\"Move down\">\n <i class=\"fa-solid fa-chevron-down\"></i>\n </button>\n </div>\n </div>\n }\n }\n </div>\n\n <!-- Footer -->\n <div class=\"mj-sm-footer\">\n <button class=\"mj-sm-reset\" (click)=\"OnReset()\">\n <i class=\"fa-solid fa-arrow-rotate-left\"></i>\n Reset to defaults\n </button>\n </div>\n </div>\n </div>\n}\n"]}
|
|
1
|
+
{"version":3,"file":"section-manager.component.js","sourceRoot":"","sources":["../../../src/lib/section-manager/section-manager.component.ts","../../../src/lib/section-manager/section-manager.component.html"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EAAE,KAAK,EAAE,MAAM,EAAE,YAAY,EACtC,uBAAuB,EAAE,iBAAiB,EAAE,MAAM,EAEnD,MAAM,eAAe,CAAC;;;;;ICkBT,AADF,+BAAuB,cACO;IAC1B,wBAAqD;IACrD,gCAA6B;IAAA,YAAyB;IAAA,iBAAO;IAC7D,4BAAqE;IACnE,YACF;IACF,AADE,iBAAO,EACH;IAEJ,AADF,+BAA+B,iBAIL;IADhB,+OAAS,8DAAoC,KAAC;IAEpD,wBAAsC;IACxC,iBAAS;IACT,mCAG0B;IADlB,gPAAS,gEAAsC,KAAC;IAEtD,yBAAwC;IAC1C,iBAAS;IACT,mCAE6B;IADrB,gPAAS,+BAAqB,KAAC;IAErC,yBAAuC;IAG7C,AADE,AADE,iBAAS,EACL,EACF;;;;;IAzBC,eAAsB;IAAtB,8BAAsB;IACI,eAAyB;IAAzB,4CAAyB;IAChD,cAA8D;IAA9D,cAAA,0EAA8D,CAAA;IAClE,cACF;IADE,2EACF;IAIQ,eAAoB;IAApB,8CAAoB;IAMpB,eAAgD;IAAhD,iFAAgD;;;IAc5D,+BAAyB;IAAA,wCAAwB;IAAA,iBAAM;;;;IAMrD,AADF,+BAA+B,cACD;IAC1B,wBAAqD;IACrD,gCAA6B;IAAA,YAAyB;IAAA,iBAAO;IAC7D,gCAAoD;IAAA,oBAAI;IAC1D,AAD0D,iBAAO,EAC3D;IAEJ,AADF,+BAA+B,iBAIL;IADhB,+OAAS,wDAA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C,GAAG,CAAC,EAAE,CAAC,UAAU,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;aAC/B,MAAM,CAAC,CAAC,CAAC,EAA2B,EAAE,CAAC,CAAC,KAAK,SAAS,CAAC,CAAC;QAC3D,MAAM,OAAO,GAAG,IAAI,GAAG,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;QAC9C,IAAI,CAAC,kBAAkB,GAAG,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC;QACzF,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC;QAClF,IAAI,CAAC,GAAG,CAAC,YAAY,EAAE,CAAC;IAC1B,CAAC;mHAxLU,yBAAyB;6DAAzB,yBAAyB;YC9CtC,4FAAe;;YAAf,sCA4HC;;;iFD9EY,yBAAyB;cAPrC,SAAS;6BACI,KAAK,YACP,oBAAoB,mBACb,uBAAuB,CAAC,MAAM;;kBAQ9C,KAAK;;kBAGL,KAAK;;kBAGL,KAAK;;kBAGL,KAAK;;kBAGL,KAAK;;kBAGL,MAAM;;kBAGN,MAAM;;kBAGN,MAAM;;kBAGN,MAAM;;kFA5BI,yBAAyB","sourcesContent":["import {\n Component, Input, Output, EventEmitter,\n ChangeDetectionStrategy, ChangeDetectorRef, inject,\n OnChanges, SimpleChanges\n} from '@angular/core';\nimport { PanelVariant } from '../types/form-types';\n\n/**\n * Info about a section, passed from the container to the Section Manager drawer.\n */\nexport interface SectionManagerItem {\n SectionKey: string;\n SectionName: string;\n Variant: PanelVariant;\n Icon: string;\n}\n\nexport interface ChromeMembershipChange {\n moreSectionKeys: string[];\n firstClassSectionKeys: string[];\n}\n\n/**\n * Slide-in drawer for managing section order.\n *\n * Provides an accessible, keyboard-friendly alternative to drag-and-drop\n * for reordering form sections. Each section is displayed as a row with\n * up/down arrow buttons to change position.\n *\n * @example\n * ```html\n * <mj-section-manager\n * [Sections]=\"sectionList\"\n * [SectionOrder]=\"currentOrder\"\n * [Visible]=\"showDrawer\"\n * (SectionOrderChange)=\"onOrderChange($event)\"\n * (Closed)=\"showDrawer = false\">\n * </mj-section-manager>\n * ```\n */\n@Component({\n standalone: false,\n selector: 'mj-section-manager',\n changeDetection: ChangeDetectionStrategy.OnPush,\n templateUrl: './section-manager.component.html',\n styleUrls: ['./section-manager.component.css']\n})\nexport class MjSectionManagerComponent implements OnChanges {\n private cdr = inject(ChangeDetectorRef);\n\n /** All available sections (unordered) */\n @Input() Sections: SectionManagerItem[] = [];\n\n /** Current section order (array of section keys) */\n @Input() SectionOrder: string[] = [];\n\n /** Section keys currently in More. Empty keeps a single list. */\n @Input() MoreSectionKeys: string[] = [];\n\n /** Keys that cannot leave More (System Metadata). */\n @Input() LockedMoreKeys: string[] = [];\n\n /** Whether the drawer is visible */\n @Input() Visible = false;\n\n /** Emits the new section order when the user reorders */\n @Output() SectionOrderChange = new EventEmitter<string[]>();\n\n /** Emits when the user moves a section in or out of More. */\n @Output() MembershipChange = new EventEmitter<ChromeMembershipChange>();\n\n /** Emits when the drawer is closed */\n @Output() Closed = new EventEmitter<void>();\n\n /** Emits when the user resets to default order */\n @Output() ResetRequested = new EventEmitter<void>();\n\n /** Ordered list of sections for display */\n OrderedSections: SectionManagerItem[] = [];\n FirstClassSections: SectionManagerItem[] = [];\n MoreSections: SectionManagerItem[] = [];\n\n ngOnChanges(changes: SimpleChanges): void {\n if (changes['Sections'] || changes['SectionOrder'] || changes['MoreSectionKeys'] || changes['LockedMoreKeys']) {\n this.rebuildOrderedSections();\n }\n }\n\n get HasMoreGroup(): boolean {\n return this.MoreSections.length > 0 || this.MoreSectionKeys.length > 0;\n }\n\n IsLockedInMore(section: SectionManagerItem): boolean {\n return this.LockedMoreKeys.includes(section.SectionKey);\n }\n\n OnClose(): void {\n this.Closed.emit();\n }\n\n OnOverlayClick(event: MouseEvent): void {\n // Only close if clicking the overlay itself, not the drawer\n if (event.target === event.currentTarget) {\n this.OnClose();\n }\n }\n\n OnMoveUp(index: number): void {\n if (index <= 0) return;\n const newOrder = this.OrderedSections.map(s => s.SectionKey);\n [newOrder[index - 1], newOrder[index]] = [newOrder[index], newOrder[index - 1]];\n this.SectionOrderChange.emit(newOrder);\n this.applyOrder(newOrder);\n }\n\n OnMoveDown(index: number): void {\n if (index >= this.OrderedSections.length - 1) return;\n const newOrder = this.OrderedSections.map(s => s.SectionKey);\n [newOrder[index], newOrder[index + 1]] = [newOrder[index + 1], newOrder[index]];\n this.SectionOrderChange.emit(newOrder);\n this.applyOrder(newOrder);\n }\n\n OnMoveGroupUp(list: SectionManagerItem[], index: number): void {\n if (index <= 0) return;\n this.emitReorderedGroup(list, index, index - 1);\n }\n\n OnMoveGroupDown(list: SectionManagerItem[], index: number): void {\n if (index >= list.length - 1) return;\n this.emitReorderedGroup(list, index, index + 1);\n }\n\n OnMoveToMore(section: SectionManagerItem): void {\n if (this.MoreSectionKeys.includes(section.SectionKey)) return;\n const more = [...this.MoreSectionKeys, section.SectionKey];\n const firstClass = this.FirstClassSections\n .map((s) => s.SectionKey)\n .filter((key) => key !== section.SectionKey);\n this.MembershipChange.emit({ moreSectionKeys: more, firstClassSectionKeys: firstClass });\n }\n\n OnMoveToForm(section: SectionManagerItem): void {\n if (this.IsLockedInMore(section)) return;\n const more = this.MoreSectionKeys.filter((key) => key !== section.SectionKey);\n const firstClass = [\n ...this.FirstClassSections.map((s) => s.SectionKey),\n section.SectionKey,\n ];\n this.MembershipChange.emit({ moreSectionKeys: more, firstClassSectionKeys: firstClass });\n }\n\n private emitReorderedGroup(list: SectionManagerItem[], from: number, to: number): void {\n const keys = list.map((s) => s.SectionKey);\n [keys[from], keys[to]] = [keys[to], keys[from]];\n const other = list === this.FirstClassSections ? this.MoreSections : this.FirstClassSections;\n const combined = list === this.FirstClassSections\n ? [...keys, ...other.map((s) => s.SectionKey)]\n : [...other.map((s) => s.SectionKey), ...keys];\n this.SectionOrderChange.emit(combined);\n this.applyOrder(combined);\n }\n\n OnReset(): void {\n this.ResetRequested.emit();\n }\n\n GetVariantIcon(variant: PanelVariant): string {\n switch (variant) {\n case 'related-entity': return 'fa-solid fa-link';\n case 'inherited': return 'fa-solid fa-arrow-up';\n default: return 'fa-solid fa-table-cells';\n }\n }\n\n GetVariantLabel(variant: PanelVariant): string {\n switch (variant) {\n case 'related-entity': return 'Related';\n case 'inherited': return 'Inherited';\n default: return 'Fields';\n }\n }\n\n private rebuildOrderedSections(): void {\n if (!this.Sections || this.Sections.length === 0) {\n this.OrderedSections = [];\n return;\n }\n\n const sectionMap = new Map<string, SectionManagerItem>();\n for (const s of this.Sections) {\n sectionMap.set(s.SectionKey, s);\n }\n\n const ordered: SectionManagerItem[] = [];\n\n // Add sections in persisted order first\n if (this.SectionOrder && this.SectionOrder.length > 0) {\n for (const key of this.SectionOrder) {\n const section = sectionMap.get(key);\n if (section) {\n ordered.push(section);\n sectionMap.delete(key);\n }\n }\n }\n\n // Append any sections not in the persisted order (new sections)\n for (const section of sectionMap.values()) {\n ordered.push(section);\n }\n\n this.OrderedSections = ordered;\n const moreSet = new Set(this.MoreSectionKeys);\n this.FirstClassSections = ordered.filter((s) => !moreSet.has(s.SectionKey));\n this.MoreSections = ordered.filter((s) => moreSet.has(s.SectionKey));\n this.cdr.markForCheck();\n }\n\n private applyOrder(newOrder: string[]): void {\n const sectionMap = new Map<string, SectionManagerItem>();\n for (const s of this.OrderedSections) {\n sectionMap.set(s.SectionKey, s);\n }\n this.OrderedSections = newOrder\n .map(key => sectionMap.get(key))\n .filter((s): s is SectionManagerItem => s !== undefined);\n const moreSet = new Set(this.MoreSectionKeys);\n this.FirstClassSections = this.OrderedSections.filter((s) => !moreSet.has(s.SectionKey));\n this.MoreSections = this.OrderedSections.filter((s) => moreSet.has(s.SectionKey));\n this.cdr.markForCheck();\n }\n}\n","<!-- Overlay backdrop -->\n@if (Visible) {\n <div class=\"mj-sm-overlay\" (click)=\"OnOverlayClick($event)\">\n <!-- Drawer panel -->\n <div class=\"mj-sm-drawer\" (click)=\"$event.stopPropagation()\">\n <!-- Header -->\n <div class=\"mj-sm-header\">\n <h3 class=\"mj-sm-title\">\n <i class=\"fa-solid fa-bars-staggered\"></i>\n Manage Sections\n </h3>\n <button class=\"mj-sm-close\" (click)=\"OnClose()\" title=\"Close\">\n <i class=\"fa-solid fa-xmark\"></i>\n </button>\n </div>\n\n <!-- Section list -->\n <div class=\"mj-sm-list\">\n @if (HasMoreGroup) {\n <div class=\"mj-sm-group-label\">On the form</div>\n @for (section of FirstClassSections; track section.SectionKey; let i = $index) {\n <div class=\"mj-sm-row\">\n <div class=\"mj-sm-row-info\">\n <i [class]=\"section.Icon\" class=\"mj-sm-row-icon\"></i>\n <span class=\"mj-sm-row-name\">{{ section.SectionName }}</span>\n <span class=\"mj-sm-row-badge mj-sm-row-badge--{{ section.Variant }}\">\n {{ GetVariantLabel(section.Variant) }}\n </span>\n </div>\n <div class=\"mj-sm-row-actions\">\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === 0\"\n (click)=\"OnMoveGroupUp(FirstClassSections, i)\"\n title=\"Move up\">\n <i class=\"fa-solid fa-chevron-up\"></i>\n </button>\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === FirstClassSections.length - 1\"\n (click)=\"OnMoveGroupDown(FirstClassSections, i)\"\n title=\"Move down\">\n <i class=\"fa-solid fa-chevron-down\"></i>\n </button>\n <button class=\"mj-sm-arrow mj-sm-move\"\n (click)=\"OnMoveToMore(section)\"\n title=\"Move to More\">\n <i class=\"fa-solid fa-folder-plus\"></i>\n </button>\n </div>\n </div>\n }\n @if (FirstClassSections.length === 0) {\n <div class=\"mj-sm-empty\">Nothing on the form yet.</div>\n }\n\n <div class=\"mj-sm-group-label\">More</div>\n @for (section of MoreSections; track section.SectionKey; let i = $index) {\n <div class=\"mj-sm-row is-more\">\n <div class=\"mj-sm-row-info\">\n <i [class]=\"section.Icon\" class=\"mj-sm-row-icon\"></i>\n <span class=\"mj-sm-row-name\">{{ section.SectionName }}</span>\n <span class=\"mj-sm-row-badge mj-sm-row-badge--more\">More</span>\n </div>\n <div class=\"mj-sm-row-actions\">\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === 0\"\n (click)=\"OnMoveGroupUp(MoreSections, i)\"\n title=\"Move up\">\n <i class=\"fa-solid fa-chevron-up\"></i>\n </button>\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === MoreSections.length - 1\"\n (click)=\"OnMoveGroupDown(MoreSections, i)\"\n title=\"Move down\">\n <i class=\"fa-solid fa-chevron-down\"></i>\n </button>\n <button class=\"mj-sm-arrow mj-sm-move\"\n [disabled]=\"IsLockedInMore(section)\"\n (click)=\"OnMoveToForm(section)\"\n [title]=\"IsLockedInMore(section) ? 'Always in More' : 'Move to form'\">\n <i class=\"fa-solid fa-arrow-up-from-bracket\"></i>\n </button>\n </div>\n </div>\n }\n @if (MoreSections.length === 0) {\n <div class=\"mj-sm-empty\">Nothing in More.</div>\n }\n } @else {\n @for (section of OrderedSections; track section.SectionKey; let i = $index) {\n <div class=\"mj-sm-row\">\n <div class=\"mj-sm-row-info\">\n <i [class]=\"section.Icon\" class=\"mj-sm-row-icon\"></i>\n <span class=\"mj-sm-row-name\">{{ section.SectionName }}</span>\n <span class=\"mj-sm-row-badge mj-sm-row-badge--{{ section.Variant }}\">\n {{ GetVariantLabel(section.Variant) }}\n </span>\n </div>\n <div class=\"mj-sm-row-actions\">\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === 0\"\n (click)=\"OnMoveUp(i)\"\n title=\"Move up\">\n <i class=\"fa-solid fa-chevron-up\"></i>\n </button>\n <button class=\"mj-sm-arrow\"\n [disabled]=\"i === OrderedSections.length - 1\"\n (click)=\"OnMoveDown(i)\"\n title=\"Move down\">\n <i class=\"fa-solid fa-chevron-down\"></i>\n </button>\n </div>\n </div>\n }\n }\n </div>\n\n <!-- Footer -->\n <div class=\"mj-sm-footer\">\n <button class=\"mj-sm-reset\" (click)=\"OnReset()\">\n <i class=\"fa-solid fa-arrow-rotate-left\"></i>\n Reset to defaults\n </button>\n </div>\n </div>\n </div>\n}\n"]}
|
|
@@ -188,7 +188,7 @@ export declare class MjFormToolbarComponent extends BaseAngularComponent impleme
|
|
|
188
188
|
* Sync toolbar state from the legacy form reference.
|
|
189
189
|
* Only active when [Form] is set (backward-compat mode).
|
|
190
190
|
*/
|
|
191
|
-
private
|
|
191
|
+
private syncFromFormRef;
|
|
192
192
|
/** Whether entity tracks record changes (for history button) */
|
|
193
193
|
get TracksChanges(): boolean;
|
|
194
194
|
/** IS-A parent chain for breadcrumb display */
|
|
@@ -245,12 +245,12 @@ export declare class MjFormToolbarComponent extends BaseAngularComponent impleme
|
|
|
245
245
|
* Check if descendant chains need recomputation (called from DoCheck).
|
|
246
246
|
* Only triggers async computation when the record identity changes.
|
|
247
247
|
*/
|
|
248
|
-
private
|
|
248
|
+
private checkDescendantChains;
|
|
249
249
|
/**
|
|
250
250
|
* Asynchronously discover all IS-A descendants and convert to chains
|
|
251
251
|
* for breadcrumb display. Each chain is a root-to-leaf path of entity names.
|
|
252
252
|
*/
|
|
253
|
-
private
|
|
253
|
+
private computeDescendantChains;
|
|
254
254
|
/**
|
|
255
255
|
* Navigate to a descendant entity record in the IS-A hierarchy.
|
|
256
256
|
*/
|
|
@@ -260,7 +260,7 @@ export declare class MjFormToolbarComponent extends BaseAngularComponent impleme
|
|
|
260
260
|
OnCancel(): void;
|
|
261
261
|
OnDiscardConfirm(): void;
|
|
262
262
|
OnDiscardCancel(): void;
|
|
263
|
-
private
|
|
263
|
+
private emitCancel;
|
|
264
264
|
OnDeleteClick(): void;
|
|
265
265
|
OnDeleteConfirm(): void;
|
|
266
266
|
OnDeleteCancel(): void;
|
|
@@ -316,7 +316,7 @@ export declare class MjFormToolbarComponent extends BaseAngularComponent impleme
|
|
|
316
316
|
* Try to call a method on the legacy form reference.
|
|
317
317
|
* Returns true if the method was found and called, false otherwise.
|
|
318
318
|
*/
|
|
319
|
-
private
|
|
319
|
+
private dispatchToFormRef;
|
|
320
320
|
/**
|
|
321
321
|
* Navigate to a parent entity record in the IS-A hierarchy.
|
|
322
322
|
*/
|
|
@@ -777,15 +777,15 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
777
777
|
}
|
|
778
778
|
ngDoCheck() {
|
|
779
779
|
if (this._formRef) {
|
|
780
|
-
this.
|
|
780
|
+
this.syncFromFormRef();
|
|
781
781
|
}
|
|
782
|
-
this.
|
|
782
|
+
this.checkDescendantChains();
|
|
783
783
|
}
|
|
784
784
|
/**
|
|
785
785
|
* Sync toolbar state from the legacy form reference.
|
|
786
786
|
* Only active when [Form] is set (backward-compat mode).
|
|
787
787
|
*/
|
|
788
|
-
|
|
788
|
+
syncFromFormRef() {
|
|
789
789
|
const ref = this._formRef;
|
|
790
790
|
const rec = ref['record'];
|
|
791
791
|
let changed = false;
|
|
@@ -936,14 +936,14 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
936
936
|
*/
|
|
937
937
|
InvalidateHierarchy() {
|
|
938
938
|
this._lastRecordForChains = null;
|
|
939
|
-
this.
|
|
939
|
+
this.computeDescendantChains();
|
|
940
940
|
this.cdr.markForCheck();
|
|
941
941
|
}
|
|
942
942
|
/**
|
|
943
943
|
* Check if descendant chains need recomputation (called from DoCheck).
|
|
944
944
|
* Only triggers async computation when the record identity changes.
|
|
945
945
|
*/
|
|
946
|
-
|
|
946
|
+
checkDescendantChains() {
|
|
947
947
|
if (!this.Record) {
|
|
948
948
|
if (this.DescendantTree.length > 0) {
|
|
949
949
|
this.DescendantTree = [];
|
|
@@ -953,14 +953,14 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
953
953
|
return;
|
|
954
954
|
}
|
|
955
955
|
if (this.Record !== this._lastRecordForChains && !this._chainsLoading) {
|
|
956
|
-
this.
|
|
956
|
+
this.computeDescendantChains();
|
|
957
957
|
}
|
|
958
958
|
}
|
|
959
959
|
/**
|
|
960
960
|
* Asynchronously discover all IS-A descendants and convert to chains
|
|
961
961
|
* for breadcrumb display. Each chain is a root-to-leaf path of entity names.
|
|
962
962
|
*/
|
|
963
|
-
|
|
963
|
+
computeDescendantChains() {
|
|
964
964
|
this._lastRecordForChains = this.Record;
|
|
965
965
|
if (!this.Record?.EntityInfo?.IsParentType) {
|
|
966
966
|
this.DescendantTree = [];
|
|
@@ -992,7 +992,7 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
992
992
|
}
|
|
993
993
|
// ---- Actions ----
|
|
994
994
|
OnEdit() {
|
|
995
|
-
if (this.
|
|
995
|
+
if (this.dispatchToFormRef('StartEditMode'))
|
|
996
996
|
return;
|
|
997
997
|
this.EditModeChange.emit(true);
|
|
998
998
|
}
|
|
@@ -1004,7 +1004,7 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
1004
1004
|
this.BeforeSave.emit(beforeEvent);
|
|
1005
1005
|
if (beforeEvent.Cancel)
|
|
1006
1006
|
return;
|
|
1007
|
-
if (this.
|
|
1007
|
+
if (this.dispatchToFormRef('SaveRecord', true))
|
|
1008
1008
|
return;
|
|
1009
1009
|
this.SaveRequested.emit();
|
|
1010
1010
|
});
|
|
@@ -1017,24 +1017,24 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
1017
1017
|
return;
|
|
1018
1018
|
}
|
|
1019
1019
|
// No changes - cancel immediately
|
|
1020
|
-
this.
|
|
1020
|
+
this.emitCancel();
|
|
1021
1021
|
}
|
|
1022
1022
|
OnDiscardConfirm() {
|
|
1023
1023
|
this.ShowDiscardDialog = false;
|
|
1024
|
-
this.
|
|
1024
|
+
this.emitCancel();
|
|
1025
1025
|
this.cdr.markForCheck();
|
|
1026
1026
|
}
|
|
1027
1027
|
OnDiscardCancel() {
|
|
1028
1028
|
this.ShowDiscardDialog = false;
|
|
1029
1029
|
this.cdr.markForCheck();
|
|
1030
1030
|
}
|
|
1031
|
-
|
|
1031
|
+
emitCancel() {
|
|
1032
1032
|
// Emit Before event - handler can cancel by setting event.Cancel = true
|
|
1033
1033
|
const beforeEvent = new BeforeCancelEventArgs();
|
|
1034
1034
|
this.BeforeCancel.emit(beforeEvent);
|
|
1035
1035
|
if (beforeEvent.Cancel)
|
|
1036
1036
|
return;
|
|
1037
|
-
if (this.
|
|
1037
|
+
if (this.dispatchToFormRef('CancelEdit'))
|
|
1038
1038
|
return;
|
|
1039
1039
|
this.CancelRequested.emit();
|
|
1040
1040
|
}
|
|
@@ -1051,7 +1051,7 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
1051
1051
|
this.cdr.markForCheck();
|
|
1052
1052
|
return;
|
|
1053
1053
|
}
|
|
1054
|
-
if (this.
|
|
1054
|
+
if (this.dispatchToFormRef('OnDeleteRequested')) {
|
|
1055
1055
|
this.cdr.markForCheck();
|
|
1056
1056
|
return;
|
|
1057
1057
|
}
|
|
@@ -1070,12 +1070,12 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
1070
1070
|
this.BeforeRefresh.emit(beforeEvent);
|
|
1071
1071
|
if (beforeEvent.Cancel)
|
|
1072
1072
|
return;
|
|
1073
|
-
if (this.
|
|
1073
|
+
if (this.dispatchToFormRef('RefreshRecord'))
|
|
1074
1074
|
return;
|
|
1075
1075
|
this.RefreshRequested.emit();
|
|
1076
1076
|
}
|
|
1077
1077
|
OnFavoriteToggle() {
|
|
1078
|
-
if (this.
|
|
1078
|
+
if (this.dispatchToFormRef('OnFavoriteToggled'))
|
|
1079
1079
|
return;
|
|
1080
1080
|
this.FavoriteToggled.emit();
|
|
1081
1081
|
}
|
|
@@ -1085,7 +1085,7 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
1085
1085
|
this.BeforeHistoryView.emit(beforeEvent);
|
|
1086
1086
|
if (beforeEvent.Cancel)
|
|
1087
1087
|
return;
|
|
1088
|
-
if (this.
|
|
1088
|
+
if (this.dispatchToFormRef('OnHistoryRequested'))
|
|
1089
1089
|
return;
|
|
1090
1090
|
this.HistoryRequested.emit();
|
|
1091
1091
|
}
|
|
@@ -1095,17 +1095,17 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
1095
1095
|
this.BeforeListManagement.emit(beforeEvent);
|
|
1096
1096
|
if (beforeEvent.Cancel)
|
|
1097
1097
|
return;
|
|
1098
|
-
if (this.
|
|
1098
|
+
if (this.dispatchToFormRef('OnListManagementRequested'))
|
|
1099
1099
|
return;
|
|
1100
1100
|
this.ListManagementRequested.emit();
|
|
1101
1101
|
}
|
|
1102
1102
|
OnTagsPanel() {
|
|
1103
|
-
if (this.
|
|
1103
|
+
if (this.dispatchToFormRef('HandleTagsPanel'))
|
|
1104
1104
|
return;
|
|
1105
1105
|
this.TagsPanelToggled.emit();
|
|
1106
1106
|
}
|
|
1107
1107
|
OnAttachmentsPanel() {
|
|
1108
|
-
if (this.
|
|
1108
|
+
if (this.dispatchToFormRef('HandleAttachmentsPanel'))
|
|
1109
1109
|
return;
|
|
1110
1110
|
this.AttachmentsPanelToggled.emit();
|
|
1111
1111
|
}
|
|
@@ -1427,7 +1427,7 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
1427
1427
|
}
|
|
1428
1428
|
}
|
|
1429
1429
|
OnShowChanges() {
|
|
1430
|
-
if (this.
|
|
1430
|
+
if (this.dispatchToFormRef('ShowChanges'))
|
|
1431
1431
|
return;
|
|
1432
1432
|
this.ShowChangesRequested.emit();
|
|
1433
1433
|
}
|
|
@@ -1485,7 +1485,7 @@ export class MjFormToolbarComponent extends BaseAngularComponent {
|
|
|
1485
1485
|
* Try to call a method on the legacy form reference.
|
|
1486
1486
|
* Returns true if the method was found and called, false otherwise.
|
|
1487
1487
|
*/
|
|
1488
|
-
|
|
1488
|
+
dispatchToFormRef(methodName, ...args) {
|
|
1489
1489
|
if (!this._formRef)
|
|
1490
1490
|
return false;
|
|
1491
1491
|
const ref = this._formRef;
|