@masterteam/dashboard-builder 0.0.68 → 0.0.70
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/assets/i18n/ar.json +1596 -1596
- package/assets/i18n/en.json +1321 -1321
- package/fesm2022/{masterteam-dashboard-builder-dashboard-dialog.component-XUArffz3.mjs → masterteam-dashboard-builder-dashboard-dialog.component-BKYVka5Y.mjs} +2 -2
- package/fesm2022/{masterteam-dashboard-builder-dashboard-dialog.component-XUArffz3.mjs.map → masterteam-dashboard-builder-dashboard-dialog.component-BKYVka5Y.mjs.map} +1 -1
- package/fesm2022/{masterteam-dashboard-builder-masterteam-dashboard-builder-B2u_ZfFj.mjs → masterteam-dashboard-builder-masterteam-dashboard-builder-DTbSru5t.mjs} +247 -97
- package/fesm2022/masterteam-dashboard-builder-masterteam-dashboard-builder-DTbSru5t.mjs.map +1 -0
- package/fesm2022/masterteam-dashboard-builder.mjs +1 -1
- package/package.json +21 -21
- package/types/masterteam-dashboard-builder.d.ts +68 -15
- package/fesm2022/masterteam-dashboard-builder-masterteam-dashboard-builder-B2u_ZfFj.mjs.map +0 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { az as ActionsSettings, aH as ArrayBuilderField, I as BarChartHandler, as as BarControlUi, aV as CHART_CAPABILITIES, av as CHART_TYPES, b8 as CONFIG_DOMAINS, C as CardContentComponent, q as CardFilterComponent, t as CardInfoComponent, u as ChartCardComponent, G as ChartDataService, aL as ChartFilterDrawer, ao as ChartSettingsDrawer, aA as ChartViewer, aG as ColorListField, X as ComparisonChartHandler, b as DashboardBuilder, ah as DashboardBuilderService, a as DashboardItem, D as DashboardItemStoreService, af as DashboardList, ai as DashboardStoreService, d as DashboardViewer, ay as DataSourceSettings, aR as DatasourcePanelComponent, aq as DefaultControlUi, ap as DisplaySettings, r as DynamicFiltersComponent, an as DynamicFiltersConfig, E as EChartComponent, P as EntitiesPreviewCardComponent, v as EntityInfoComponent, x as EntityPreviewCardComponent, aQ as FilterBuilderComponent, aT as FilterByGroupPipe, aP as FilterChipsBarComponent, O as GaugeChartHandler, ax as GeneralSettings, aU as GetChartActionsPipe, aO as GuidedConfigDialogComponent, ag as HTTPMethod, H as HeaderCardComponent, bS as ITEM_GUIDANCE_REGISTRY, aK as ItemCardMenuComponent, aN as ItemConfigPopoverComponent, aM as ItemContextToolbarComponent, bU as ItemGuidanceService, aI as KeyValueMapField, L as LastHistoryLevelCardComponent, aJ as LegendOrderField, Z as LevelCardHandler, V as LineChartHandler, y as ListStatisticCardComponent, al as ManageBreadcrumb, am as ManageFilterOnPage, au as ManageItem, aw as ManageItemService, ak as ManagePages, _ as MapChartHandler, R as OverviewCardHandler, bb as POPOVER_TABS, bc as POPOVER_TAB_SPECS, a1 as PhaseGateStepperHandler, J as PieChartHandler, ar as PieControlUi, P as PropertiesCardComponent, $ as RingGaugeChartHandler, a0 as SPlusChartHandler, bt as STYLE_PRESETS, aS as SchemaControlRendererComponent, aF as SegmentedField, z as SkeletonCardComponent, W as SnapshotHandler, Y as SplitterChartHandler, K as StackBarChartHandler, at as StackBarControlUi, S as StaticFiltersComponent, A as StatisticCardComponent, aE as StyleField, aC as StyleSettingsRenderer, aB as StyleStudioDrawer, T as TableCardComponent, Q as TableViewHandler, U as TimelineHandler, B as TopbarCardComponent, m as addCommasToNumber, bp as applyBehaviorToPersisted, bE as applyControlPatchToPersisted, bF as applyControlPatchesToPersisted, bq as applyFilterChipsToPersisted, bn as applyLabelLegendFormatToPersisted, bl as applyLayoutToPersisted, bj as applyStyleToPersisted, be as applyTitleToPersisted, M as axisFormatters, bo as behaviorToUi, bN as bindingKey, bs as buildAssembly, bM as buildDisplayFieldPredicate, c as cloneDeep, a7 as createAxisFormatter, a8 as createTooltipFormatter, bf as datasourceToUi, bA as deepMerge, bT as describeGuidance, b9 as domainsForCapability, h as dynamicReorder, f as dynamicTextReplace, aD as expandResetPatches, bg as fieldsToUi, bh as filtersToUi, ba as findDomain, bv as findPreset, bK as flattenSchema, a9 as formatAxisLabel, a2 as formatCurrency, a6 as formatDate, bB as formatForEditor, a5 as formatNumber, a4 as formatPercentage, j as formatValue, aa as formatWordsUnderBar, ab as formatXAxis, i as generalConfiguration, bO as getBinding, aW as getCapabilityById, p as getColorFromConditions, bG as getControlSchema, a3 as getCurrencySuffix, bJ as getFallbackControlSchema, k as getLocalizedTitle, g as getNestedData, N as groupDatesByYearAndMonth, by as groupIssuesByDomain, ad as handleFilterForCard, ae as handleFilterForSnapshot, ac as handleFiltersForCustom, bx as hasBlockingIssues, aj as isManagePagesDeleteResult, o as isMobilePlatform, bm as labelLegendFormatToUi, bk as layoutToUi, bP as listBindings, bQ as listBindingsForChart, bH as listControlSchemaIds, bI as listControlSchemas, b2 as moduleIdFromSelector, a$ as normalizeAggregateFunction, b7 as normalizeBeforeRequest, b6 as normalizeBeforeSave, aZ as normalizeChartTypeForRequest, w as normalizeDashboardCardEntityValue, a_ as normalizeFilterOperation, b0 as normalizeFilters, b5 as normalizeOnLoad, bz as parseAdvancedJson, br as persistedToUi, bu as presetsForCapability, bR as readBoundValue, bC as readByPath, aX as resolveCapability, bL as resolveDisplayFields, b1 as selectorFromLegacy, bD as setByPath, l as sortChartData, n as sortDataTableView, bi as styleToUi, e as switchAllKeysSmall, s as switchAllKeysToLower, bd as titleToUi, aY as toBackendChartType, b3 as toBackendSourceLink, b4 as toFormSourceLink, bw as validate } from './masterteam-dashboard-builder-masterteam-dashboard-builder-
|
|
1
|
+
export { az as ActionsSettings, aH as ArrayBuilderField, I as BarChartHandler, as as BarControlUi, aV as CHART_CAPABILITIES, av as CHART_TYPES, b8 as CONFIG_DOMAINS, C as CardContentComponent, q as CardFilterComponent, t as CardInfoComponent, u as ChartCardComponent, G as ChartDataService, aL as ChartFilterDrawer, ao as ChartSettingsDrawer, aA as ChartViewer, aG as ColorListField, X as ComparisonChartHandler, b as DashboardBuilder, ah as DashboardBuilderService, a as DashboardItem, D as DashboardItemStoreService, af as DashboardList, ai as DashboardStoreService, d as DashboardViewer, ay as DataSourceSettings, aR as DatasourcePanelComponent, aq as DefaultControlUi, ap as DisplaySettings, r as DynamicFiltersComponent, an as DynamicFiltersConfig, E as EChartComponent, P as EntitiesPreviewCardComponent, v as EntityInfoComponent, x as EntityPreviewCardComponent, aQ as FilterBuilderComponent, aT as FilterByGroupPipe, aP as FilterChipsBarComponent, O as GaugeChartHandler, ax as GeneralSettings, aU as GetChartActionsPipe, aO as GuidedConfigDialogComponent, ag as HTTPMethod, H as HeaderCardComponent, bS as ITEM_GUIDANCE_REGISTRY, aK as ItemCardMenuComponent, aN as ItemConfigPopoverComponent, aM as ItemContextToolbarComponent, bU as ItemGuidanceService, aI as KeyValueMapField, L as LastHistoryLevelCardComponent, aJ as LegendOrderField, Z as LevelCardHandler, V as LineChartHandler, y as ListStatisticCardComponent, al as ManageBreadcrumb, am as ManageFilterOnPage, au as ManageItem, aw as ManageItemService, ak as ManagePages, _ as MapChartHandler, R as OverviewCardHandler, bb as POPOVER_TABS, bc as POPOVER_TAB_SPECS, a1 as PhaseGateStepperHandler, J as PieChartHandler, ar as PieControlUi, P as PropertiesCardComponent, $ as RingGaugeChartHandler, a0 as SPlusChartHandler, bt as STYLE_PRESETS, aS as SchemaControlRendererComponent, aF as SegmentedField, z as SkeletonCardComponent, W as SnapshotHandler, Y as SplitterChartHandler, K as StackBarChartHandler, at as StackBarControlUi, S as StaticFiltersComponent, A as StatisticCardComponent, aE as StyleField, aC as StyleSettingsRenderer, aB as StyleStudioDrawer, T as TableCardComponent, Q as TableViewHandler, U as TimelineHandler, B as TopbarCardComponent, m as addCommasToNumber, bp as applyBehaviorToPersisted, bE as applyControlPatchToPersisted, bF as applyControlPatchesToPersisted, bq as applyFilterChipsToPersisted, bn as applyLabelLegendFormatToPersisted, bl as applyLayoutToPersisted, bj as applyStyleToPersisted, be as applyTitleToPersisted, M as axisFormatters, bo as behaviorToUi, bN as bindingKey, bs as buildAssembly, bM as buildDisplayFieldPredicate, c as cloneDeep, a7 as createAxisFormatter, a8 as createTooltipFormatter, bf as datasourceToUi, bA as deepMerge, bT as describeGuidance, b9 as domainsForCapability, h as dynamicReorder, f as dynamicTextReplace, aD as expandResetPatches, bg as fieldsToUi, bh as filtersToUi, ba as findDomain, bv as findPreset, bK as flattenSchema, a9 as formatAxisLabel, a2 as formatCurrency, a6 as formatDate, bB as formatForEditor, a5 as formatNumber, a4 as formatPercentage, j as formatValue, aa as formatWordsUnderBar, ab as formatXAxis, i as generalConfiguration, bO as getBinding, aW as getCapabilityById, p as getColorFromConditions, bG as getControlSchema, a3 as getCurrencySuffix, bJ as getFallbackControlSchema, k as getLocalizedTitle, g as getNestedData, N as groupDatesByYearAndMonth, by as groupIssuesByDomain, ad as handleFilterForCard, ae as handleFilterForSnapshot, ac as handleFiltersForCustom, bx as hasBlockingIssues, aj as isManagePagesDeleteResult, o as isMobilePlatform, bm as labelLegendFormatToUi, bk as layoutToUi, bP as listBindings, bQ as listBindingsForChart, bH as listControlSchemaIds, bI as listControlSchemas, b2 as moduleIdFromSelector, a$ as normalizeAggregateFunction, b7 as normalizeBeforeRequest, b6 as normalizeBeforeSave, aZ as normalizeChartTypeForRequest, w as normalizeDashboardCardEntityValue, a_ as normalizeFilterOperation, b0 as normalizeFilters, b5 as normalizeOnLoad, bz as parseAdvancedJson, br as persistedToUi, bu as presetsForCapability, bR as readBoundValue, bC as readByPath, aX as resolveCapability, bL as resolveDisplayFields, b1 as selectorFromLegacy, bD as setByPath, l as sortChartData, n as sortDataTableView, bi as styleToUi, e as switchAllKeysSmall, s as switchAllKeysToLower, bd as titleToUi, aY as toBackendChartType, b3 as toBackendSourceLink, b4 as toFormSourceLink, bw as validate } from './masterteam-dashboard-builder-masterteam-dashboard-builder-DTbSru5t.mjs';
|
|
2
2
|
//# sourceMappingURL=masterteam-dashboard-builder.mjs.map
|
package/package.json
CHANGED
|
@@ -1,35 +1,35 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@masterteam/dashboard-builder",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.70",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"directory": "../../../dist/masterteam/dashboard-builder",
|
|
6
6
|
"linkDirectory": true,
|
|
7
7
|
"access": "public"
|
|
8
8
|
},
|
|
9
9
|
"peerDependencies": {
|
|
10
|
-
"@angular/common": "
|
|
11
|
-
"@angular/core": "
|
|
12
|
-
"@angular/forms": "
|
|
13
|
-
"@angular/cdk": "
|
|
14
|
-
"@angular/router": "
|
|
15
|
-
"@primeuix/themes": "
|
|
16
|
-
"@tailwindcss/postcss": "
|
|
17
|
-
"@jsverse/transloco": "
|
|
18
|
-
"
|
|
19
|
-
"echarts": "^5.5.0",
|
|
20
|
-
"ngx-quill": "^30.0.1",
|
|
21
|
-
"postcss": "^8.5.9",
|
|
22
|
-
"primeng": "21.1.5",
|
|
23
|
-
"quill": "^2.0.3",
|
|
24
|
-
"rxjs": "^7.8.2",
|
|
25
|
-
"tailwindcss": "^4.2.2",
|
|
26
|
-
"@masterteam/components": "^0.0.236",
|
|
10
|
+
"@angular/common": "catalog:angular21",
|
|
11
|
+
"@angular/core": "catalog:angular21",
|
|
12
|
+
"@angular/forms": "catalog:angular21",
|
|
13
|
+
"@angular/cdk": "catalog:angular21",
|
|
14
|
+
"@angular/router": "catalog:angular21",
|
|
15
|
+
"@primeuix/themes": "catalog:",
|
|
16
|
+
"@tailwindcss/postcss": "catalog:",
|
|
17
|
+
"@jsverse/transloco": "catalog:i18n",
|
|
18
|
+
"@masterteam/components": "^0.0.246",
|
|
27
19
|
"@masterteam/formula-builder": "^0.0.27",
|
|
28
20
|
"@masterteam/icons": "^0.0.17",
|
|
29
|
-
"@masterteam/timeline": "^0.0.20"
|
|
21
|
+
"@masterteam/timeline": "^0.0.20",
|
|
22
|
+
"angular-gridster2": "^18.0.1",
|
|
23
|
+
"echarts": "^5.5.0",
|
|
24
|
+
"ngx-quill": "catalog:",
|
|
25
|
+
"postcss": "catalog:",
|
|
26
|
+
"primeng": "catalog:",
|
|
27
|
+
"quill": "catalog:",
|
|
28
|
+
"rxjs": "catalog:angular21",
|
|
29
|
+
"tailwindcss": "catalog:"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"tslib": "
|
|
32
|
+
"tslib": "catalog:angular21",
|
|
33
33
|
"angular-gridster2": "^18.0.1"
|
|
34
34
|
},
|
|
35
35
|
"sideEffects": false,
|
|
@@ -45,4 +45,4 @@
|
|
|
45
45
|
}
|
|
46
46
|
},
|
|
47
47
|
"type": "module"
|
|
48
|
-
}
|
|
48
|
+
}
|
|
@@ -2356,6 +2356,7 @@ declare class DashboardBuilder implements OnInit, OnDestroy {
|
|
|
2356
2356
|
private transloco;
|
|
2357
2357
|
private modalService;
|
|
2358
2358
|
private confirmationService;
|
|
2359
|
+
private route;
|
|
2359
2360
|
/** Whether to wrap content in mt-page component */
|
|
2360
2361
|
readonly isPage: _angular_core.InputSignal<boolean>;
|
|
2361
2362
|
/** Page title when isPage is true */
|
|
@@ -2429,6 +2430,12 @@ declare class DashboardBuilder implements OnInit, OnDestroy {
|
|
|
2429
2430
|
private lastExtraFiltersSignature;
|
|
2430
2431
|
private lastLoadedPageKey;
|
|
2431
2432
|
private lastStandaloneDashboardSignature;
|
|
2433
|
+
/**
|
|
2434
|
+
* Last geometry published per chart id, keyed by `serviceConfig.dashboardId`.
|
|
2435
|
+
* Gridster mutates the bound chart object in place, so this is the only way
|
|
2436
|
+
* to tell that a drag/resize actually moved something (issue #1192).
|
|
2437
|
+
*/
|
|
2438
|
+
private readonly lastItemGeometry;
|
|
2432
2439
|
private readonly undoStack;
|
|
2433
2440
|
private readonly HISTORY_LIMIT;
|
|
2434
2441
|
private committedSnapshot;
|
|
@@ -2444,9 +2451,28 @@ declare class DashboardBuilder implements OnInit, OnDestroy {
|
|
|
2444
2451
|
private removeEventListeners;
|
|
2445
2452
|
private loadCurrentPageIfNeeded;
|
|
2446
2453
|
loadPage(id: string | number): void;
|
|
2454
|
+
/**
|
|
2455
|
+
* Persist the dashboard.
|
|
2456
|
+
*
|
|
2457
|
+
* An EXPLICIT save (the toolbar button — `silent` unset) is the commit point
|
|
2458
|
+
* for the undo history: once it succeeds the accumulated history is dropped
|
|
2459
|
+
* and Undo is disabled until the user edits again. Undo is a pre-save
|
|
2460
|
+
* operation, so it must never be able to reach across a deliberate save
|
|
2461
|
+
* (issue #1192). Internal auto-saves pass `silent: true` and deliberately
|
|
2462
|
+
* keep the history so an add/remove stays revertible.
|
|
2463
|
+
*/
|
|
2447
2464
|
saveDash(options?: {
|
|
2448
2465
|
silent?: boolean;
|
|
2449
2466
|
}): void;
|
|
2467
|
+
/**
|
|
2468
|
+
* Mark the current document as the saved baseline: drop the undo history so
|
|
2469
|
+
* Undo is disabled until the next edit (issue #1192 — undo is a *pre-save*
|
|
2470
|
+
* operation and must not reach back across a deliberate save).
|
|
2471
|
+
*
|
|
2472
|
+
* Runs after the link-id patch so the new baseline is captured from the
|
|
2473
|
+
* document the backend actually holds.
|
|
2474
|
+
*/
|
|
2475
|
+
private commitSavedState;
|
|
2450
2476
|
/**
|
|
2451
2477
|
* Persist the page-level filters through the dashboard (report) endpoint —
|
|
2452
2478
|
* the canonical carrier of `dashboardConfig.filters`. In API-backed mode
|
|
@@ -2459,7 +2485,31 @@ declare class DashboardBuilder implements OnInit, OnDestroy {
|
|
|
2459
2485
|
addOrEditPage(page?: DashboardPage): void;
|
|
2460
2486
|
deleteReport(): void;
|
|
2461
2487
|
onItemResize(item: GridsterItem, itemComponent: any): void;
|
|
2488
|
+
/**
|
|
2489
|
+
* Gridster drag/resize committed (issue #1192).
|
|
2490
|
+
*
|
|
2491
|
+
* The template binds `[item]="chart"`, so Gridster owns and MUTATES the very
|
|
2492
|
+
* object that lives inside the `charts` signal. By the time this callback
|
|
2493
|
+
* runs, `chart.x/y/cols/rows` already hold the new geometry — which is why
|
|
2494
|
+
* the previous "did anything change?" guard compared the chart against
|
|
2495
|
+
* itself, always matched, and returned the array untouched. The signal never
|
|
2496
|
+
* notified, so neither the undo-history effect nor the standalone
|
|
2497
|
+
* `dashboardData` emit ever saw a move or a resize.
|
|
2498
|
+
*
|
|
2499
|
+
* We therefore track the last geometry we published per chart and compare
|
|
2500
|
+
* against THAT. When it differs we publish a new array reference (same item
|
|
2501
|
+
* objects, so Gridster's own `[item]` binding is left alone) purely to wake
|
|
2502
|
+
* the signal's consumers.
|
|
2503
|
+
*/
|
|
2462
2504
|
onItemChange(item: GridsterItem, _itemComponent: any): void;
|
|
2505
|
+
private geometrySignature;
|
|
2506
|
+
/**
|
|
2507
|
+
* Forget recorded geometries. Required whenever a whole new document replaces
|
|
2508
|
+
* the current one (load / standalone apply / undo restore), otherwise a stale
|
|
2509
|
+
* entry could make a later drag back to those exact coordinates look like a
|
|
2510
|
+
* no-op and get swallowed.
|
|
2511
|
+
*/
|
|
2512
|
+
private resetItemGeometryTracking;
|
|
2463
2513
|
onContextMenu(event: MouseEvent, item: GridsterItem): void;
|
|
2464
2514
|
/** Handle dragover on gridster - must call preventDefault to allow drop */
|
|
2465
2515
|
onGridDragOver(event: DragEvent): void;
|
|
@@ -2640,25 +2690,28 @@ declare class DashboardBuilder implements OnInit, OnDestroy {
|
|
|
2640
2690
|
/** Drop all recorded history — called whenever a whole new document loads. */
|
|
2641
2691
|
private resetHistory;
|
|
2642
2692
|
/**
|
|
2643
|
-
* Revert the most recent action
|
|
2644
|
-
*
|
|
2645
|
-
*
|
|
2646
|
-
*
|
|
2647
|
-
*
|
|
2648
|
-
*
|
|
2693
|
+
* Revert the most recent UNSAVED action (issue #1192).
|
|
2694
|
+
*
|
|
2695
|
+
* Undo is a pre-save operation: it restores the previous local state and
|
|
2696
|
+
* never writes to the backend. Pressing Save is the commit point — a
|
|
2697
|
+
* successful explicit save clears the history, after which Undo is disabled
|
|
2698
|
+
* until the user edits again.
|
|
2699
|
+
*
|
|
2700
|
+
* Ghost-link cleanup is the one exception to "never writes": when the revert
|
|
2701
|
+
* drops an item that a background auto-save had already linked, that link is
|
|
2702
|
+
* removed. Leaving it behind would resurrect the item on the next reload,
|
|
2703
|
+
* which is a bug in its own right rather than part of the undone state.
|
|
2649
2704
|
*/
|
|
2650
2705
|
undo(): void;
|
|
2651
2706
|
/**
|
|
2652
|
-
*
|
|
2653
|
-
*
|
|
2654
|
-
*
|
|
2655
|
-
*
|
|
2707
|
+
* Remove backend links for items the revert dropped.
|
|
2708
|
+
*
|
|
2709
|
+
* `saveDash` only ever upserts, so an already-linked item that is no longer
|
|
2710
|
+
* in the document would otherwise survive as an orphan and reappear on the
|
|
2711
|
+
* next load. This does NOT restore any other saved state — it only prevents
|
|
2712
|
+
* an item the user just undid from coming back.
|
|
2656
2713
|
*/
|
|
2657
|
-
private
|
|
2658
|
-
/** Serialize page filters for change detection (normalized, order-stable). */
|
|
2659
|
-
private serializeFilters;
|
|
2660
|
-
/** Serialize items ignoring link ids so persistence metadata isn't compared. */
|
|
2661
|
-
private serializeItems;
|
|
2714
|
+
private unlinkItemsRemovedByUndo;
|
|
2662
2715
|
/**
|
|
2663
2716
|
* Content signature of the whole document with link ids stripped, so a save
|
|
2664
2717
|
* writing back `id` / `chartComponentId` is not seen as a user change.
|