bways-report 0.2.3 → 0.2.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/README.md +9 -2
  2. package/esm2022/lib/core/config/bways-report-config.mjs +10 -1
  3. package/esm2022/lib/core/models/index.mjs +2 -2
  4. package/esm2022/lib/core/models/report-menu.model.mjs +2 -0
  5. package/esm2022/lib/core/services/designer-form-context.service.mjs +21 -1
  6. package/esm2022/lib/core/services/dynamic-form-builder.service.mjs +52 -3
  7. package/esm2022/lib/core/tokens/reporting-config.token.mjs +1 -1
  8. package/esm2022/lib/core/utils/identifier-humanizer.mjs +5 -1
  9. package/esm2022/lib/core/utils/report-menu.util.mjs +41 -0
  10. package/esm2022/lib/data-access/adapters/endpoint-schema-discovery.adapter.mjs +8 -4
  11. package/esm2022/lib/data-access/contracts/schema-discovery.contract.mjs +3 -1
  12. package/esm2022/lib/features/designer/components/dialogs/report-saved-dialog.component.mjs +44 -13
  13. package/esm2022/lib/features/designer/components/menu-selector/report-menu-selector.component.mjs +246 -0
  14. package/esm2022/lib/features/designer/components/property-editor/parameter-binding-editor.component.mjs +12 -4
  15. package/esm2022/lib/features/designer/components/property-editor/property-editor-datasource.component.mjs +3 -3
  16. package/esm2022/lib/features/designer/components/property-editor/property-editor-general.component.mjs +239 -5
  17. package/esm2022/lib/features/designer/components/property-editor/property-editor-grid.component.mjs +11 -7
  18. package/esm2022/lib/features/designer/components/property-editor/property-editor.component.mjs +40 -5
  19. package/esm2022/lib/features/designer/components/toolbar/designer-toolbar.component.mjs +50 -17
  20. package/esm2022/lib/features/designer/designer.component.mjs +15 -4
  21. package/esm2022/lib/features/designer/rpt-report-designer.component.mjs +12 -3
  22. package/esm2022/lib/features/designer/services/designer-config.service.mjs +3 -1
  23. package/esm2022/lib/features/designer/services/designer-endpoints.service.mjs +4 -2
  24. package/esm2022/lib/features/embed/bways-report-builder.component.mjs +2 -2
  25. package/esm2022/lib/features/routing/components/routed-report-designer.component.mjs +2 -2
  26. package/esm2022/lib/features/runtime/dynamic-renderer.component.mjs +15 -2
  27. package/esm2022/lib/features/runtime/report-runtime.component.mjs +21 -13
  28. package/esm2022/lib/primitives/components/dropdown/rpt-dropdown.component.mjs +77 -1
  29. package/esm2022/lib/provide-reporting.mjs +4 -1
  30. package/fesm2022/bways-report.mjs +900 -71
  31. package/fesm2022/bways-report.mjs.map +1 -1
  32. package/lib/core/config/bways-report-config.d.ts +4 -0
  33. package/lib/core/models/index.d.ts +1 -0
  34. package/lib/core/models/report-menu.model.d.ts +29 -0
  35. package/lib/core/services/designer-form-context.service.d.ts +9 -0
  36. package/lib/core/services/dynamic-form-builder.service.d.ts +6 -0
  37. package/lib/core/tokens/reporting-config.token.d.ts +2 -0
  38. package/lib/core/utils/report-menu.util.d.ts +10 -0
  39. package/lib/data-access/adapters/endpoint-schema-discovery.adapter.d.ts +1 -0
  40. package/lib/data-access/contracts/schema-discovery.contract.d.ts +2 -0
  41. package/lib/features/designer/components/dialogs/report-saved-dialog.component.d.ts +12 -0
  42. package/lib/features/designer/components/menu-selector/report-menu-selector.component.d.ts +49 -0
  43. package/lib/features/designer/components/property-editor/property-editor-general.component.d.ts +15 -0
  44. package/lib/features/designer/components/property-editor/property-editor-grid.component.d.ts +7 -3
  45. package/lib/features/designer/components/property-editor/property-editor.component.d.ts +6 -0
  46. package/lib/features/designer/components/toolbar/designer-toolbar.component.d.ts +5 -1
  47. package/lib/features/designer/designer.component.d.ts +7 -1
  48. package/lib/features/designer/rpt-report-designer.component.d.ts +5 -1
  49. package/lib/features/runtime/dynamic-renderer.component.d.ts +3 -0
  50. package/lib/primitives/components/dropdown/rpt-dropdown.component.d.ts +1 -0
  51. package/package.json +1 -1
@@ -1,3 +1,4 @@
1
+ import { BwaysReportMenuConfig } from '../models/report-menu.model';
1
2
  /**
2
3
  * Simplified configuration for bways-report.
3
4
  *
@@ -43,6 +44,8 @@ export declare const PALETTE_CATEGORY_MAP: Record<PaletteCategory, string>;
43
44
  * ```
44
45
  */
45
46
  export interface BwaysReportConfig {
47
+ /** Optional menu destination review. null disables an inherited loader. */
48
+ menu?: BwaysReportMenuConfig | null;
46
49
  /**
47
50
  * GET endpoint returning the list of stored procedures with their parameters.
48
51
  * Response: `[{ name, schema, parameters: [{ name, sqlType, required, defaultValue? }] }]`
@@ -149,6 +152,7 @@ export interface BwaysReportConfig {
149
152
  * Result of normalizing a `BwaysReportConfig` for internal use.
150
153
  */
151
154
  export interface NormalizedBwaysConfig {
155
+ menu: BwaysReportMenuConfig | null;
152
156
  /** Endpoint URLs */
153
157
  spEndpoint: string;
154
158
  tablesEndpoint: string;
@@ -10,3 +10,4 @@ export type { ReportGridDefinition, GridColumnDefinition, GridOptionsDefinition,
10
10
  export type { ReportLayoutDefinition, ComponentLayoutDefinition, } from './report-layout.model';
11
11
  export type { ValidationDefinition, } from './validation.model';
12
12
  export type { ComponentEventDefinition, ComponentActionDefinition, } from './component-event.model';
13
+ export * from './report-menu.model';
@@ -0,0 +1,29 @@
1
+ import { Observable } from 'rxjs';
2
+ /** Host-normalized menu tree. IDs must be unique and stable within the menu context. */
3
+ export interface BwaysReportMenuNode {
4
+ id: string;
5
+ caption: string;
6
+ moduleNo?: string;
7
+ menuKey?: string;
8
+ parentKey?: string;
9
+ selectable: boolean;
10
+ children?: readonly BwaysReportMenuNode[];
11
+ }
12
+ /** Review-only menu destination; phase one does not persist or activate it. */
13
+ export interface BwaysReportMenuSelection {
14
+ targetId: string;
15
+ moduleNo?: string;
16
+ menuKey: string;
17
+ menuCaption: string;
18
+ parentKey?: string;
19
+ path: string[];
20
+ }
21
+ export interface BwaysReportMenuConfig {
22
+ /** Return a fresh complete tree, not a Subscription or only expanded rows. */
23
+ load: () => Observable<readonly BwaysReportMenuNode[]>;
24
+ required?: boolean;
25
+ /** Read reactive company/user/module signals here to invalidate an open review on context changes. */
26
+ contextKey?: () => string;
27
+ /** Defaults to 30 seconds. */
28
+ timeoutMs?: number;
29
+ }
@@ -5,10 +5,19 @@ export declare class DesignerFormContextService {
5
5
  private readonly form;
6
6
  private readonly revision;
7
7
  readonly dropdownColumns: import("@angular/core").WritableSignal<Record<string, string[]>>;
8
+ readonly dropdownOptions: import("@angular/core").WritableSignal<Record<string, {
9
+ key: string | number;
10
+ label: string;
11
+ }[]>>;
8
12
  readonly values: import("@angular/core").Signal<Record<string, unknown>>;
9
13
  bind(form: FormGroup): void;
10
14
  refresh(): void;
11
15
  setColumns(key: string, columns: string[]): void;
16
+ setOptions(keyOrId: string, options: {
17
+ key: string | number;
18
+ label: string;
19
+ }[]): void;
20
+ setControlValue(key: string, value: unknown): void;
12
21
  static ɵfac: i0.ɵɵFactoryDeclaration<DesignerFormContextService, never>;
13
22
  static ɵprov: i0.ɵɵInjectableDeclaration<DesignerFormContextService>;
14
23
  }
@@ -18,6 +18,12 @@ export declare class DynamicFormBuilder {
18
18
  * @returns Configured Angular FormGroup.
19
19
  */
20
20
  toFormGroup(components: ReportComponentDefinition[], initialValues?: Record<string, unknown>): FormGroup;
21
+ /**
22
+ * Resolves the effective initial default value for a component definition.
23
+ */
24
+ resolveComponentDefaultValue(comp: ReportComponentDefinition): unknown;
25
+ /** Reconcile metadata without replacing controls that hold user selections. */
26
+ reconcileFormGroup(form: FormGroup, components: ReportComponentDefinition[], initialValues?: Record<string, unknown>): FormGroup;
21
27
  /**
22
28
  * Extracts raw values from a FormGroup, including disabled controls.
23
29
  *
@@ -4,11 +4,13 @@
4
4
  * Core configuration models and injection tokens.
5
5
  * Decoupled from UI primitives and data-access adapters.
6
6
  */
7
+ import { BwaysReportMenuConfig } from '../models/report-menu.model';
7
8
  import { InjectionToken, Type } from '@angular/core';
8
9
  /**
9
10
  * Library configuration options.
10
11
  */
11
12
  export interface ReportingConfig {
13
+ menu?: BwaysReportMenuConfig | null;
12
14
  /** Default page size for grids. */
13
15
  defaultPageSize: number;
14
16
  /** Date format string used across the library. */
@@ -0,0 +1,10 @@
1
+ import { BwaysReportMenuNode, BwaysReportMenuSelection } from '../models/report-menu.model';
2
+ export interface ReportMenuRow {
3
+ node: BwaysReportMenuNode;
4
+ depth: number;
5
+ parentId?: string;
6
+ path: string[];
7
+ }
8
+ /** Validate host data once per load; never mutate the host tree or silently omit bad branches. */
9
+ export declare function indexReportMenus(nodes: readonly BwaysReportMenuNode[]): ReportMenuRow[];
10
+ export declare function reportMenuSelection(row: ReportMenuRow): BwaysReportMenuSelection;
@@ -8,6 +8,7 @@ export declare class EndpointSchemaDiscoveryAdapter extends ReportSchemaDiscover
8
8
  private spCache$;
9
9
  private tableCache$;
10
10
  private readonly session;
11
+ clearCache(): void;
11
12
  private spCacheKey;
12
13
  private tableCacheKey;
13
14
  private context;
@@ -37,6 +37,8 @@ export interface ProcedureParameterMetadata {
37
37
  * Enables the Visual Designer to discover tables and procedures without tight coupling.
38
38
  */
39
39
  export declare abstract class ReportSchemaDiscoveryAdapter {
40
+ /** Invalidate cached catalogs before an explicit metadata refresh. */
41
+ clearCache?(): void;
40
42
  /**
41
43
  * Retrieves list of database tables, views, or stored procedures.
42
44
  */
@@ -1,16 +1,23 @@
1
+ import { BwaysReportMenuConfig, BwaysReportMenuSelection } from '../../../../core/models/report-menu.model';
1
2
  import { ReportDefinition } from '../../../../core/models/report-definition.model';
2
3
  import * as i0 from "@angular/core";
3
4
  export interface ReportSavedDialogData {
5
+ menuSelection?: BwaysReportMenuSelection | null;
4
6
  report: ReportDefinition;
5
7
  routeBase?: string;
6
8
  }
7
9
  export interface ReportSavedDialogResult {
10
+ /** Review-only: returned separately from report JSON, never persisted by phase one. */
11
+ menuSelection?: BwaysReportMenuSelection | null;
8
12
  action: 'back_to_designer' | 'open_live_page';
9
13
  report: ReportDefinition;
10
14
  }
11
15
  interface UpdateConfirmation {
12
16
  report: ReportDefinition;
13
17
  action: ReportSavedDialogResult['action'];
18
+ menuSelection?: BwaysReportMenuSelection | null;
19
+ menuContext: string;
20
+ menuConfig: BwaysReportMenuConfig | null;
14
21
  expectedVersion: number;
15
22
  existingName: string;
16
23
  contextKey: string;
@@ -23,6 +30,11 @@ export declare class ReportSavedDialogComponent {
23
30
  private readonly reportingConfig;
24
31
  private idCheck?;
25
32
  private customSlug;
33
+ private readonly menuSelector;
34
+ readonly menuConfig: import("@angular/core").Signal<BwaysReportMenuConfig | null>;
35
+ readonly menuSelection: import("@angular/core").WritableSignal<BwaysReportMenuSelection | null>;
36
+ readonly menuValid: import("@angular/core").WritableSignal<boolean>;
37
+ private menuContext;
26
38
  readonly report: ReportDefinition;
27
39
  readonly baseRoute: import("@angular/core").WritableSignal<string>;
28
40
  readonly reportId: import("@angular/core").WritableSignal<string>;
@@ -0,0 +1,49 @@
1
+ import { ElementRef } from '@angular/core';
2
+ import { ConnectedPosition } from '@angular/cdk/overlay';
3
+ import { BwaysReportMenuConfig, BwaysReportMenuSelection } from '../../../../core/models/report-menu.model';
4
+ import { ReportMenuRow } from '../../../../core/utils/report-menu.util';
5
+ import * as i0 from "@angular/core";
6
+ export declare class ReportMenuSelectorComponent {
7
+ readonly config: import("@angular/core").InputSignal<BwaysReportMenuConfig>;
8
+ readonly value: import("@angular/core").InputSignal<BwaysReportMenuSelection | null>;
9
+ readonly disabled: import("@angular/core").InputSignal<boolean>;
10
+ readonly selectionChange: import("@angular/core").OutputEmitterRef<BwaysReportMenuSelection | null>;
11
+ readonly validityChange: import("@angular/core").OutputEmitterRef<boolean>;
12
+ readonly selection: import("@angular/core").WritableSignal<BwaysReportMenuSelection | null>;
13
+ readonly open: import("@angular/core").WritableSignal<boolean>;
14
+ readonly loading: import("@angular/core").WritableSignal<boolean>;
15
+ readonly loaded: import("@angular/core").WritableSignal<boolean>;
16
+ readonly error: import("@angular/core").WritableSignal<string>;
17
+ readonly query: import("@angular/core").WritableSignal<string>;
18
+ readonly rows: import("@angular/core").WritableSignal<ReportMenuRow[]>;
19
+ readonly expanded: import("@angular/core").WritableSignal<Set<string>>;
20
+ readonly active: import("@angular/core").WritableSignal<number>;
21
+ readonly panelId: string;
22
+ readonly trigger: import("@angular/core").Signal<ElementRef<HTMLButtonElement> | undefined>;
23
+ readonly search: import("@angular/core").Signal<ElementRef<HTMLInputElement> | undefined>;
24
+ readonly list: import("@angular/core").Signal<ElementRef<HTMLElement> | undefined>;
25
+ private readonly element;
26
+ readonly scrollStrategy: import("@angular/cdk/overlay").ScrollStrategy;
27
+ readonly width: import("@angular/core").WritableSignal<number>;
28
+ readonly positions: ConnectedPosition[];
29
+ private request?;
30
+ private generation;
31
+ private context?;
32
+ readonly valid: import("@angular/core").Signal<boolean>;
33
+ readonly unavailable: import("@angular/core").Signal<boolean>;
34
+ readonly visible: import("@angular/core").Signal<ReportMenuRow[]>;
35
+ constructor();
36
+ toggle(): void;
37
+ attached(): void;
38
+ close(focus?: boolean): void;
39
+ reload(): void;
40
+ choose(row: ReportMenuRow): void;
41
+ clear(): void;
42
+ isExpanded(row: ReportMenuRow): boolean;
43
+ expand(row: ReportMenuRow): void;
44
+ onQuery(value: string): void;
45
+ triggerKey(event: KeyboardEvent): void;
46
+ key(event: KeyboardEvent): void;
47
+ static ɵfac: i0.ɵɵFactoryDeclaration<ReportMenuSelectorComponent, never>;
48
+ static ɵcmp: i0.ɵɵComponentDeclaration<ReportMenuSelectorComponent, "rpt-report-menu-selector", never, { "config": { "alias": "config"; "required": true; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; }, { "selectionChange": "selectionChange"; "validityChange": "validityChange"; }, never, never, true, never>;
49
+ }
@@ -1,7 +1,9 @@
1
1
  import { ReportComponentDefinition } from '../../../../core/models/report-component.model';
2
2
  import { PropertyDefinition } from '../../../../core/registry/property-definition.model';
3
+ import { SearchableSelectOption } from '../../../../primitives/components';
3
4
  import * as i0 from "@angular/core";
4
5
  export declare class PropertyEditorGeneralComponent {
6
+ private readonly formContext;
5
7
  readonly comp: import("@angular/core").InputSignal<ReportComponentDefinition>;
6
8
  readonly propertySchema: import("@angular/core").InputSignal<PropertyDefinition[]>;
7
9
  readonly filteredPropertySchema: import("@angular/core").Signal<PropertyDefinition[]>;
@@ -14,6 +16,19 @@ export declare class PropertyEditorGeneralComponent {
14
16
  value: unknown;
15
17
  }>;
16
18
  readonly deselect: import("@angular/core").OutputEmitterRef<void>;
19
+ /**
20
+ * Resolves the available options for the dropdown from either the live canvas dropdown
21
+ * (including dynamic Table / Stored Procedure / REST API options) or static options.
22
+ */
23
+ readonly dropdownOptionItems: import("@angular/core").Signal<{
24
+ key: string | number;
25
+ label: string;
26
+ }[]>;
27
+ readonly isDefaultOptionEnabled: import("@angular/core").Signal<boolean>;
28
+ readonly selectedDefaultOptionValue: import("@angular/core").Signal<string>;
29
+ readonly defaultSelectOptions: import("@angular/core").Signal<SearchableSelectOption<any>[]>;
30
+ onToggleDefaultOption(enabled: boolean): void;
31
+ onDefaultOptionChanged(selectedVal: string): void;
17
32
  getPropValue(key: string): unknown;
18
33
  static ɵfac: i0.ɵɵFactoryDeclaration<PropertyEditorGeneralComponent, never>;
19
34
  static ɵcmp: i0.ɵɵComponentDeclaration<PropertyEditorGeneralComponent, "rpt-property-editor-general", never, { "comp": { "alias": "comp"; "required": true; "isSignal": true; }; "propertySchema": { "alias": "propertySchema"; "required": false; "isSignal": true; }; }, { "update": "update"; "updateProperty": "updateProperty"; "deselect": "deselect"; }, never, never, true, never>;
@@ -10,9 +10,12 @@ export declare class PropertyEditorGridComponent {
10
10
  private readonly endpoints;
11
11
  readonly grid: import("@angular/core").InputSignal<ReportGridDefinition | undefined>;
12
12
  readonly dataSource: import("@angular/core").InputSignal<ReportDataSourceDefinition | undefined>;
13
- readonly availableEntities: import("@angular/core").InputSignal<DatabaseEntityMetadata[]>;
14
- readonly procedureParameters: import("@angular/core").InputSignal<ProcedureParameterMetadata[]>;
13
+ readonly availableEntities: import("@angular/core").InputSignal<DatabaseEntityMetadata[] | undefined>;
14
+ readonly procedureParameters: import("@angular/core").InputSignal<ProcedureParameterMetadata[] | undefined>;
15
15
  readonly allComponents: import("@angular/core").InputSignal<ReportComponentDefinition[]>;
16
+ readonly isRefreshingMetadata: import("@angular/core").InputSignal<boolean>;
17
+ readonly metadataRefreshError: import("@angular/core").InputSignal<string | null>;
18
+ readonly refreshMetadata: import("@angular/core").OutputEmitterRef<void>;
16
19
  readonly isDetecting: import("@angular/core").InputSignal<boolean>;
17
20
  readonly statusMessage: import("@angular/core").InputSignal<string | null>;
18
21
  readonly statusKind: import("@angular/core").InputSignal<"error" | "success" | "info" | null>;
@@ -43,6 +46,7 @@ export declare class PropertyEditorGridComponent {
43
46
  readonly allEntities: import("@angular/core").Signal<DatabaseEntityMetadata[]>;
44
47
  readonly activeSourceType: import("@angular/core").WritableSignal<"table" | "api" | "stored_procedure">;
45
48
  readonly currentSourceType: import("@angular/core").Signal<"table" | "api" | "stored_procedure">;
49
+ readonly navigateUrlPlaceholder = "/orders/{{row.orderId}} or https://...";
46
50
  readonly activeEntityName: import("@angular/core").Signal<string>;
47
51
  readonly apiEndpoint: import("@angular/core").Signal<string>;
48
52
  readonly apiMethod: import("@angular/core").Signal<"GET" | "POST">;
@@ -85,5 +89,5 @@ export declare class PropertyEditorGridComponent {
85
89
  updateMappingValue(index: number, newValue: string): void;
86
90
  removeMapping(index: number): void;
87
91
  static ɵfac: i0.ɵɵFactoryDeclaration<PropertyEditorGridComponent, never>;
88
- static ɵcmp: i0.ɵɵComponentDeclaration<PropertyEditorGridComponent, "rpt-property-editor-grid", never, { "grid": { "alias": "grid"; "required": false; "isSignal": true; }; "dataSource": { "alias": "dataSource"; "required": false; "isSignal": true; }; "availableEntities": { "alias": "availableEntities"; "required": false; "isSignal": true; }; "procedureParameters": { "alias": "procedureParameters"; "required": false; "isSignal": true; }; "allComponents": { "alias": "allComponents"; "required": false; "isSignal": true; }; "isDetecting": { "alias": "isDetecting"; "required": false; "isSignal": true; }; "statusMessage": { "alias": "statusMessage"; "required": false; "isSignal": true; }; "statusKind": { "alias": "statusKind"; "required": false; "isSignal": true; }; }, { "addGrid": "addGrid"; "removeGrid": "removeGrid"; "addColumn": "addColumn"; "autoDetectColumns": "autoDetectColumns"; "removeColumn": "removeColumn"; "updateColumn": "updateColumn"; "updateOption": "updateOption"; "updateRowClickAction": "updateRowClickAction"; "setDataSource": "setDataSource"; "updateDataSourceParameters": "updateDataSourceParameters"; "entityChanged": "entityChanged"; }, never, never, true, never>;
92
+ static ɵcmp: i0.ɵɵComponentDeclaration<PropertyEditorGridComponent, "rpt-property-editor-grid", never, { "grid": { "alias": "grid"; "required": false; "isSignal": true; }; "dataSource": { "alias": "dataSource"; "required": false; "isSignal": true; }; "availableEntities": { "alias": "availableEntities"; "required": false; "isSignal": true; }; "procedureParameters": { "alias": "procedureParameters"; "required": false; "isSignal": true; }; "allComponents": { "alias": "allComponents"; "required": false; "isSignal": true; }; "isRefreshingMetadata": { "alias": "isRefreshingMetadata"; "required": false; "isSignal": true; }; "metadataRefreshError": { "alias": "metadataRefreshError"; "required": false; "isSignal": true; }; "isDetecting": { "alias": "isDetecting"; "required": false; "isSignal": true; }; "statusMessage": { "alias": "statusMessage"; "required": false; "isSignal": true; }; "statusKind": { "alias": "statusKind"; "required": false; "isSignal": true; }; }, { "refreshMetadata": "refreshMetadata"; "addGrid": "addGrid"; "removeGrid": "removeGrid"; "addColumn": "addColumn"; "autoDetectColumns": "autoDetectColumns"; "removeColumn": "removeColumn"; "updateColumn": "updateColumn"; "updateOption": "updateOption"; "updateRowClickAction": "updateRowClickAction"; "setDataSource": "setDataSource"; "updateDataSourceParameters": "updateDataSourceParameters"; "entityChanged": "entityChanged"; }, never, never, true, never>;
89
93
  }
@@ -13,6 +13,10 @@ import * as i0 from "@angular/core";
13
13
  * and Rule 32 (Avoid God Components).
14
14
  */
15
15
  export declare class PropertyEditorComponent {
16
+ private readonly metadataRequests;
17
+ private gridMetadataVersion;
18
+ readonly isRefreshingGridMetadata: import("@angular/core").WritableSignal<boolean>;
19
+ readonly gridMetadataRefreshError: import("@angular/core").WritableSignal<string | null>;
16
20
  private readonly formContext;
17
21
  private readonly designerState;
18
22
  private readonly registry;
@@ -62,6 +66,8 @@ export declare class PropertyEditorComponent {
62
66
  type: 'stored_procedure' | 'table' | 'api';
63
67
  }): void;
64
68
  onGridDataSourceParametersChanged(mappings: Record<string, unknown>): void;
69
+ private isProcedureSource;
70
+ refreshGridMetadata(): void;
65
71
  autoDetectGridColumns(): void;
66
72
  readonly expandedSections: import("@angular/core").WritableSignal<Record<string, boolean>>;
67
73
  toggleSection(section: string): void;
@@ -4,6 +4,9 @@ import { ReportDefinition } from '../../../../core/models/report-definition.mode
4
4
  import * as i0 from "@angular/core";
5
5
  export declare class DesignerToolbarComponent {
6
6
  private readonly requests;
7
+ private readonly initialSelectionHandled;
8
+ readonly loadSavedReportOnInit: import("@angular/core").InputSignal<boolean>;
9
+ readonly selectRecentReportOnInit: import("@angular/core").InputSignal<boolean>;
7
10
  readonly catalogLoading: import("@angular/core").WritableSignal<boolean>;
8
11
  readonly catalogError: import("@angular/core").WritableSignal<string | null>;
9
12
  readonly isSwitchingReport: import("@angular/core").WritableSignal<boolean>;
@@ -33,6 +36,7 @@ export declare class DesignerToolbarComponent {
33
36
  createNewReport(): void;
34
37
  refreshReports(): void;
35
38
  onSwitchReport(reportId: string, select?: HTMLSelectElement): void;
39
+ private openReport;
36
40
  private toSlug;
37
41
  setMode(mode: DesignerViewMode): void;
38
42
  undo(): void;
@@ -45,5 +49,5 @@ export declare class DesignerToolbarComponent {
45
49
  selectGridSettings(): void;
46
50
  exportJson(): void;
47
51
  static ɵfac: i0.ɵɵFactoryDeclaration<DesignerToolbarComponent, never>;
48
- static ɵcmp: i0.ɵɵComponentDeclaration<DesignerToolbarComponent, "rpt-designer-toolbar", never, { "isLeftPanelCollapsed": { "alias": "isLeftPanelCollapsed"; "required": false; "isSignal": true; }; "isRightPanelCollapsed": { "alias": "isRightPanelCollapsed"; "required": false; "isSignal": true; }; }, { "toggleLeftPanel": "toggleLeftPanel"; "toggleRightPanel": "toggleRightPanel"; "saveRequested": "saveRequested"; }, never, never, true, never>;
52
+ static ɵcmp: i0.ɵɵComponentDeclaration<DesignerToolbarComponent, "rpt-designer-toolbar", never, { "loadSavedReportOnInit": { "alias": "loadSavedReportOnInit"; "required": false; "isSignal": true; }; "selectRecentReportOnInit": { "alias": "selectRecentReportOnInit"; "required": false; "isSignal": true; }; "isLeftPanelCollapsed": { "alias": "isLeftPanelCollapsed"; "required": false; "isSignal": true; }; "isRightPanelCollapsed": { "alias": "isRightPanelCollapsed"; "required": false; "isSignal": true; }; }, { "toggleLeftPanel": "toggleLeftPanel"; "toggleRightPanel": "toggleRightPanel"; "saveRequested": "saveRequested"; }, never, never, true, never>;
49
53
  }
@@ -1,3 +1,4 @@
1
+ import { BwaysReportMenuSelection } from '../../core/models/report-menu.model';
1
2
  import { BwaysReportConfig } from '../../core/config/bways-report-config';
2
3
  import { OnInit } from '@angular/core';
3
4
  import { ReportDefinition } from '../../core/models/report-definition.model';
@@ -27,10 +28,15 @@ export declare class DesignerComponent implements OnInit {
27
28
  private readonly reportingConfig;
28
29
  /** Optional reportId to load from persistence adapter */
29
30
  readonly reportId: import("@angular/core").InputSignal<string | undefined>;
31
+ /** Rehydrate a catalog-matched initial selection from persistence on each designer entry. */
32
+ readonly loadSavedReportOnInit: import("@angular/core").InputSignal<boolean>;
30
33
  /** Optional definition to load directly */
31
34
  readonly definition: import("@angular/core").InputSignal<ReportDefinition | null | undefined>;
32
35
  /** Emitted when the user saves the report */
33
36
  readonly reportSaved: import("@angular/core").OutputEmitterRef<ReportDefinition>;
37
+ /** Review-only menu selection, independently supplied and returned by the host. */
38
+ readonly menuSelection: import("@angular/core").InputSignal<BwaysReportMenuSelection | null>;
39
+ readonly menuSelectionChange: import("@angular/core").OutputEmitterRef<BwaysReportMenuSelection | null>;
34
40
  /** Emitted whenever the report definition changes in the visual designer */
35
41
  readonly definitionChanged: import("@angular/core").OutputEmitterRef<ReportDefinition>;
36
42
  readonly currentDefinition: import("@angular/core").WritableSignal<ReportDefinition>;
@@ -73,5 +79,5 @@ export declare class DesignerComponent implements OnInit {
73
79
  private syntaxHighlightJson;
74
80
  private showToast;
75
81
  static ɵfac: i0.ɵɵFactoryDeclaration<DesignerComponent, never>;
76
- static ɵcmp: i0.ɵɵComponentDeclaration<DesignerComponent, "rpt-designer", never, { "config": { "alias": "config"; "required": false; }; "apiUrl": { "alias": "apiUrl"; "required": false; }; "reportId": { "alias": "reportId"; "required": false; "isSignal": true; }; "definition": { "alias": "initialReport"; "required": false; "isSignal": true; }; }, { "reportSaved": "save"; "definitionChanged": "definitionChange"; }, never, never, true, never>;
82
+ static ɵcmp: i0.ɵɵComponentDeclaration<DesignerComponent, "rpt-designer", never, { "config": { "alias": "config"; "required": false; }; "apiUrl": { "alias": "apiUrl"; "required": false; }; "reportId": { "alias": "reportId"; "required": false; "isSignal": true; }; "loadSavedReportOnInit": { "alias": "loadSavedReportOnInit"; "required": false; "isSignal": true; }; "definition": { "alias": "initialReport"; "required": false; "isSignal": true; }; "menuSelection": { "alias": "menuSelection"; "required": false; "isSignal": true; }; }, { "reportSaved": "save"; "menuSelectionChange": "menuSelectionChange"; "definitionChanged": "definitionChange"; }, never, never, true, never>;
77
83
  }
@@ -1,3 +1,4 @@
1
+ import { BwaysReportMenuSelection } from '../../core/models/report-menu.model';
1
2
  import { BwaysReportConfig } from '../../core/config/bways-report-config';
2
3
  import { BwaysReportApiUrls } from '../../data-access/adapters/endpoint-tokens';
3
4
  import { ReportDefinition } from '../../core/models/report-definition.model';
@@ -22,6 +23,7 @@ export declare class RptReportDesignerComponent {
22
23
  readonly apiUrl: import("@angular/core").InputSignal<BwaysReportApiUrls | null>;
23
24
  /** Report ID to automatically load via configured ReportPersistenceAdapter */
24
25
  readonly id: import("@angular/core").InputSignal<string | undefined>;
26
+ readonly loadSavedReportOnInit: import("@angular/core").InputSignal<boolean>;
25
27
  /** Report definition to load directly in memory */
26
28
  readonly report: import("@angular/core").InputSignal<ReportDefinition | null>;
27
29
  /** Whether to render a back/close button toolbar */
@@ -30,6 +32,8 @@ export declare class RptReportDesignerComponent {
30
32
  readonly closeLabel: import("@angular/core").InputSignal<string>;
31
33
  /** Emitted when user saves the report */
32
34
  readonly saved: import("@angular/core").OutputEmitterRef<ReportDefinition>;
35
+ readonly menuSelection: import("@angular/core").InputSignal<BwaysReportMenuSelection | null>;
36
+ readonly menuSelectionChange: import("@angular/core").OutputEmitterRef<BwaysReportMenuSelection | null>;
33
37
  /** Emitted when user clicks the close button */
34
38
  readonly closed: import("@angular/core").OutputEmitterRef<void>;
35
39
  /** Emitted whenever the designer definition changes */
@@ -38,5 +42,5 @@ export declare class RptReportDesignerComponent {
38
42
  onDefinitionChange(definition: ReportDefinition): void;
39
43
  onClose(): void;
40
44
  static ɵfac: i0.ɵɵFactoryDeclaration<RptReportDesignerComponent, never>;
41
- static ɵcmp: i0.ɵɵComponentDeclaration<RptReportDesignerComponent, "rpt-report-designer, rpt-designer-view", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "apiUrl": { "alias": "apiUrl"; "required": false; "isSignal": true; }; "id": { "alias": "id"; "required": false; "isSignal": true; }; "report": { "alias": "report"; "required": false; "isSignal": true; }; "showCloseButton": { "alias": "showCloseButton"; "required": false; "isSignal": true; }; "closeLabel": { "alias": "closeLabel"; "required": false; "isSignal": true; }; }, { "saved": "saved"; "closed": "closed"; "definitionChange": "definitionChange"; }, never, never, true, never>;
45
+ static ɵcmp: i0.ɵɵComponentDeclaration<RptReportDesignerComponent, "rpt-report-designer, rpt-designer-view", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "apiUrl": { "alias": "apiUrl"; "required": false; "isSignal": true; }; "id": { "alias": "id"; "required": false; "isSignal": true; }; "loadSavedReportOnInit": { "alias": "loadSavedReportOnInit"; "required": false; "isSignal": true; }; "report": { "alias": "report"; "required": false; "isSignal": true; }; "showCloseButton": { "alias": "showCloseButton"; "required": false; "isSignal": true; }; "closeLabel": { "alias": "closeLabel"; "required": false; "isSignal": true; }; "menuSelection": { "alias": "menuSelection"; "required": false; "isSignal": true; }; }, { "saved": "saved"; "menuSelectionChange": "menuSelectionChange"; "closed": "closed"; "definitionChange": "definitionChange"; }, never, never, true, never>;
42
46
  }
@@ -46,6 +46,9 @@ export declare class DynamicRendererComponent {
46
46
  row: Record<string, unknown>;
47
47
  parameters: Record<string, unknown>;
48
48
  }>;
49
+ private activeForm?;
50
+ private formReportId?;
51
+ private formInitialValues?;
49
52
  readonly form: import("@angular/core").Signal<FormGroup<any>>;
50
53
  readonly sortedComponents: import("@angular/core").Signal<ReportComponentDefinition[]>;
51
54
  readonly totalGridColumns: import("@angular/core").Signal<number>;
@@ -88,6 +88,7 @@ export declare class RptDropdownComponent implements OnDestroy {
88
88
  onTriggerKeydown(event: KeyboardEvent): void;
89
89
  onSearchKeydown(event: KeyboardEvent): void;
90
90
  private scrollFocusedIntoView;
91
+ private lastConfiguredDefaultSig;
91
92
  constructor();
92
93
  ngOnDestroy(): void;
93
94
  private scheduleReload;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bways-report",
3
- "version": "0.2.3",
3
+ "version": "0.2.5",
4
4
  "description": "Enterprise-grade, metadata-driven reporting engine and visual page builder for Angular 18+ ERP applications.",
5
5
  "keywords": [
6
6
  "angular",