@gooddata/sdk-ui-dashboard 11.51.0-alpha.3 → 11.51.0-alpha.4
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/esm/__version.d.ts +1 -1
- package/esm/__version.js +1 -1
- package/esm/presentation/automations/alerting/DefaultAlertingDialog/hooks/useAlertFilters.d.ts.map +1 -1
- package/esm/presentation/automations/alerting/DefaultAlertingDialog/hooks/useAlertFilters.js +1 -1
- package/esm/presentation/automations/alerting/DefaultAlertingDialog/hooks/useAlertFormState.js +1 -1
- package/esm/presentation/automations/connectors/ScheduledEmailConnector.js +1 -1
- package/esm/presentation/automations/connectors/ScheduledEmailConnector.test.js +1 -1
- package/esm/presentation/automations/scheduledEmail/DefaultScheduledEmailDialog/hooks/useScheduledEmailEffectiveFilters.js +1 -1
- package/esm/presentation/automations/scheduledEmail/DefaultScheduledEmailDialog/hooks/useScheduledEmailFilters.js +1 -1
- package/esm/presentation/automations/shared/automationFilters/hooks/useDefaultSelectedFiltersForExistingAutomation.js +1 -1
- package/esm/presentation/automations/shared/automationFilters/hooks/useValidateExistingAutomationFilters.d.ts.map +1 -1
- package/esm/presentation/automations/shared/automationFilters/hooks/useValidateExistingAutomationFilters.js +2 -1
- package/esm/presentation/automations/shared/automationFilters/utils.d.ts +1 -32
- package/esm/presentation/automations/shared/automationFilters/utils.d.ts.map +1 -1
- package/esm/presentation/automations/shared/automationFilters/utils.js +2 -177
- package/esm/presentation/automations/shared/filters/conversions.d.ts +36 -0
- package/esm/presentation/automations/shared/filters/conversions.d.ts.map +1 -0
- package/esm/presentation/automations/shared/filters/conversions.js +242 -0
- package/esm/presentation/automations/shared/filters/index.d.ts +2 -0
- package/esm/presentation/automations/shared/filters/index.d.ts.map +1 -0
- package/esm/presentation/automations/shared/filters/index.js +3 -0
- package/esm/presentation/drill/DrillSelect/DrillSelectDropdownMenuItem.js +2 -2
- package/package.json +21 -21
- package/styles/css/filterBar.css +1 -0
- package/styles/css/filterBar.css.map +1 -1
- package/styles/css/main.css +1 -0
- package/styles/css/main.css.map +1 -1
- package/styles/scss/filterBar.scss +7 -0
- package/esm/presentation/automations/scheduledEmail/utils/filters.d.ts +0 -3
- package/esm/presentation/automations/scheduledEmail/utils/filters.d.ts.map +0 -1
- package/esm/presentation/automations/scheduledEmail/utils/filters.js +0 -5
- package/esm/presentation/automations/shared/utils/filterContextUtils.d.ts +0 -4
- package/esm/presentation/automations/shared/utils/filterContextUtils.d.ts.map +0 -1
- package/esm/presentation/automations/shared/utils/filterContextUtils.js +0 -67
package/esm/__version.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const LIB_VERSION = "11.51.0-alpha.
|
|
1
|
+
export declare const LIB_VERSION = "11.51.0-alpha.4";
|
|
2
2
|
export declare const LIB_DESCRIPTION = "GoodData SDK - Dashboard Component";
|
|
3
3
|
export declare const LIB_NAME = "@gooddata/sdk-ui-dashboard";
|
|
4
4
|
//# sourceMappingURL=__version.d.ts.map
|
package/esm/__version.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// (C) 2021 GoodData Corporation
|
|
2
2
|
// DO NOT CHANGE THIS FILE, IT IS RE-GENERATED ON EVERY BUILD
|
|
3
|
-
export const LIB_VERSION = "11.51.0-alpha.
|
|
3
|
+
export const LIB_VERSION = "11.51.0-alpha.4";
|
|
4
4
|
export const LIB_DESCRIPTION = "GoodData SDK - Dashboard Component";
|
|
5
5
|
export const LIB_NAME = "@gooddata/sdk-ui-dashboard";
|
package/esm/presentation/automations/alerting/DefaultAlertingDialog/hooks/useAlertFilters.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useAlertFilters.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/automations/alerting/DefaultAlertingDialog/hooks/useAlertFilters.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,QAAQ,EAAE,KAAK,cAAc,EAAe,MAAM,OAAO,CAAC;AAExE,OAAO,EACH,KAAK,iBAAiB,EAEtB,KAAK,mCAAmC,EACxC,KAAK,wBAAwB,EAC7B,KAAK,QAAQ,EACb,KAAK,OAAO,EACZ,KAAK,SAAS,EACjB,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"useAlertFilters.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/automations/alerting/DefaultAlertingDialog/hooks/useAlertFilters.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,QAAQ,EAAE,KAAK,cAAc,EAAe,MAAM,OAAO,CAAC;AAExE,OAAO,EACH,KAAK,iBAAiB,EAEtB,KAAK,mCAAmC,EACxC,KAAK,wBAAwB,EAC7B,KAAK,QAAQ,EACb,KAAK,OAAO,EACZ,KAAK,SAAS,EACjB,MAAM,qBAAqB,CAAC;AAG7B,OAAO,EAAE,KAAK,cAAc,EAAE,KAAK,WAAW,EAAE,MAAM,gBAAgB,CAAC;AACvE,OAAO,EAAE,KAAK,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAG7D;;;GAGG;AACH,MAAM,WAAW,qBAAqB;IAClC,mBAAmB,EAAE,QAAQ,CAAC,cAAc,CAAC,mCAAmC,GAAG,SAAS,CAAC,CAAC,CAAC;IAC/F,0BAA0B,EAAE,CAAC,OAAO,EAAE,iBAAiB,EAAE,KAAK,IAAI,CAAC;IACnE,uBAAuB,EAAE,iBAAiB,EAAE,CAAC;IAC7C,gCAAgC,CAAC,EAAE,wBAAwB,EAAE,GAAG,SAAS,CAAC;IAC1E,sBAAsB,EAAE,iBAAiB,EAAE,CAAC;IAC5C,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,OAAO,CAAC,EAAE,QAAQ,CAAC;IACnB,iBAAiB,EAAE,WAAW,EAAE,CAAC;IACjC,mBAAmB,EAAE,cAAc,EAAE,CAAC;IACtC,gBAAgB,EAAE,iBAAiB,CAAC;IACpC,eAAe,EAAE,WAAW,GAAG,SAAS,CAAC;IACzC,iBAAiB,EAAE,cAAc,GAAG,SAAS,CAAC;IAC9C,aAAa,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IACzC,SAAS,EAAE,SAAS,CAAC;IACrB,QAAQ,EAAE,MAAM,GAAG,SAAS,CAAC;CAChC;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,eAAe,CAAC,EAC5B,mBAAmB,EACnB,0BAA0B,EAC1B,uBAAuB,EACvB,gCAAgC,EAChC,sBAAsB,EACtB,kBAAkB,EAClB,MAAM,EACN,OAAO,EACP,iBAAiB,EACjB,mBAAmB,EACnB,gBAAgB,EAChB,eAAe,EACf,iBAAiB,EACjB,aAAa,EACb,SAAS,EACT,QAAQ,EACX,EAAE,qBAAqB,GAAG;IACvB,eAAe,EAAE,CAAC,OAAO,EAAE,iBAAiB,EAAE,KAAK,IAAI,CAAC;IACxD,qBAAqB,EAAE,MAAM,IAAI,CAAC;CACrC,CA4FA"}
|
package/esm/presentation/automations/alerting/DefaultAlertingDialog/hooks/useAlertFilters.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// (C) 2026 GoodData Corporation
|
|
2
2
|
import { useCallback } from "react";
|
|
3
|
-
import { getAppliedWidgetFilters, getVisibleFiltersByFilters
|
|
3
|
+
import { getAppliedWidgetFilters, getVisibleFiltersByFilters } from "../../../shared/filters/index.js";
|
|
4
4
|
import { transformAlertByAttribute, transformAlertByMetric } from "../utils/transformation.js";
|
|
5
5
|
/**
|
|
6
6
|
* Owns the alerting dialog's filter changes: `onFiltersChange` and `onApplyCurrentFilters` update the
|
package/esm/presentation/automations/alerting/DefaultAlertingDialog/hooks/useAlertFormState.js
CHANGED
|
@@ -5,7 +5,7 @@ import { useAlertingDialogContext } from "../../../contexts/AlertingDialogContex
|
|
|
5
5
|
import { useAutomationsContext } from "../../../contexts/AutomationsContext.js";
|
|
6
6
|
import { setAlertExecutionParameters } from "../../../shared/automationFilters/automationParameters.js";
|
|
7
7
|
import { useAutomationAlertParameters } from "../../../shared/automationFilters/useAutomationAlertParameters.js";
|
|
8
|
-
import { getAppliedWidgetFilters, getVisibleFiltersByFilters, resolveMvfDimensionalityLocalRefs, } from "../../../shared/
|
|
8
|
+
import { getAppliedWidgetFilters, getVisibleFiltersByFilters, resolveMvfDimensionalityLocalRefs, } from "../../../shared/filters/index.js";
|
|
9
9
|
import { convertCurrentUserToAutomationRecipient, convertCurrentUserToWorkspaceUser, convertExternalRecipientToAutomationRecipient, } from "../../../shared/utils/automationUtils.js";
|
|
10
10
|
import { createDefaultAlert } from "../utils/convertors.js";
|
|
11
11
|
import { transformAlertByAnomalyDetection, transformAlertByAttribute, transformAlertByComparisonOperator, transformAlertByDestination, transformAlertByGranularity, transformAlertByMetric, transformAlertByRelativeOperator, transformAlertBySensitivity, } from "../utils/transformation.js";
|
|
@@ -12,7 +12,7 @@ import { ScheduledEmailDialogContextProvider } from "../contexts/ScheduledEmailD
|
|
|
12
12
|
import { ScheduledEmailManagementDialogContextProvider } from "../contexts/ScheduledEmailManagementDialogContext.js";
|
|
13
13
|
import { ScheduledEmailDialog } from "../scheduledEmail/ScheduledEmailDialog.js";
|
|
14
14
|
import { ScheduledEmailManagementDialog } from "../scheduledEmail/ScheduledEmailManagementDialog.js";
|
|
15
|
-
import { getAppliedDashboardFilters } from "../
|
|
15
|
+
import { getAppliedDashboardFilters } from "../shared/filters/index.js";
|
|
16
16
|
import { useAutomationManagementEditRouting } from "./hooks/useAutomationManagementEditRouting.js";
|
|
17
17
|
import { useBuildAutomationsContext } from "./hooks/useBuildAutomationsContext.js";
|
|
18
18
|
import { useBuildScheduledEmailDialogContext } from "./hooks/useBuildScheduledEmailDialogContext.js";
|
|
@@ -151,7 +151,7 @@ vi.mock("../../../_staging/automation/index.js", () => ({
|
|
|
151
151
|
getAutomationDashboardFilters: () => undefined,
|
|
152
152
|
getAutomationVisualizationFilters: () => ({ executionFilters: [] }),
|
|
153
153
|
}));
|
|
154
|
-
vi.mock("../
|
|
154
|
+
vi.mock("../shared/filters/index.js", () => ({
|
|
155
155
|
getAppliedDashboardFilters: () => [],
|
|
156
156
|
}));
|
|
157
157
|
import { ScheduledEmailConnector } from "./ScheduledEmailConnector.js";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { useMemo } from "react";
|
|
3
3
|
import { useScheduledEmailDialogContext } from "../../../contexts/ScheduledEmailDialogContext.js";
|
|
4
4
|
import { shouldStoreExportParameters } from "../../../shared/automationFilters/automationParameters.js";
|
|
5
|
-
import { getAppliedDashboardFilters, getAppliedWidgetFilters, getVisibleFiltersByFilters, getVisibleFiltersByFiltersByTab, } from "../../../shared/
|
|
5
|
+
import { getAppliedDashboardFilters, getAppliedWidgetFilters, getVisibleFiltersByFilters, getVisibleFiltersByFiltersByTab, } from "../../../shared/filters/index.js";
|
|
6
6
|
/**
|
|
7
7
|
* Derives the filter sets a scheduled export actually runs with: the widget and dashboard filters left
|
|
8
8
|
* after hidden filters are removed, their visible-filter counterparts for display, and the per-tab
|
|
@@ -3,7 +3,7 @@ import { useCallback } from "react";
|
|
|
3
3
|
import { isExportDefinitionDashboardRequestPayload, isExportDefinitionVisualizationObjectRequestPayload, isInsightWidget, } from "@gooddata/sdk-model";
|
|
4
4
|
import { useScheduledEmailDialogContext } from "../../../contexts/ScheduledEmailDialogContext.js";
|
|
5
5
|
import { getDefaultSelectedFiltersFromFiltersByTab } from "../../../shared/automationFilters/useAutomationFiltersSelect.js";
|
|
6
|
-
import { getAppliedDashboardFilters, getAppliedWidgetFilters, getVisibleFiltersByFilters, getVisibleFiltersByFiltersByTab, } from "../../../shared/
|
|
6
|
+
import { getAppliedDashboardFilters, getAppliedWidgetFilters, getVisibleFiltersByFilters, getVisibleFiltersByFiltersByTab, } from "../../../shared/filters/index.js";
|
|
7
7
|
/**
|
|
8
8
|
* Owns the scheduled-email dialog's filter changes. Each handler updates the edited filter state and
|
|
9
9
|
* mirrors the result into the draft — rewriting the filters on its export definitions along with the
|
|
@@ -4,8 +4,8 @@ import { dashboardFilterLocalIdentifier, filterLocalIdentifier, isDashboardArbit
|
|
|
4
4
|
import { removeIgnoredWidgetFilters } from "../../../../../model/utils/widgetFilters.js";
|
|
5
5
|
import { isDashboardFilter } from "../../../../../types.js";
|
|
6
6
|
import { useAutomationsContext } from "../../../contexts/AutomationsContext.js";
|
|
7
|
+
import { dashboardFilterToFilterContextItem } from "../../filters/index.js";
|
|
7
8
|
import { getAutomationAlertFilters, getAutomationDashboardFilters, getAutomationDashboardFiltersByTab, getAutomationVisualizationFilters, } from "../../utils/automationUtils.js";
|
|
8
|
-
import { dashboardFilterToFilterContextItem } from "../../utils/filterContextUtils.js";
|
|
9
9
|
export function useDefaultSelectedFiltersForExistingAutomation(automationToEdit, availableVisibleFilters, widget) {
|
|
10
10
|
const { automationAvailableFilters: availableDashboardFilters, commonDateFilterId } = useAutomationsContext();
|
|
11
11
|
const savedWidgetAlertFilters = getAutomationAlertFilters(automationToEdit);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useValidateExistingAutomationFilters.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/automations/shared/automationFilters/hooks/useValidateExistingAutomationFilters.ts"],"names":[],"mappings":"AAIA,OAAO,EACH,KAAK,qCAAqC,EAE1C,KAAK,iBAAiB,EAEtB,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,EAC7B,KAAK,yBAAyB,EAC9B,KAAK,mBAAmB,EACxB,KAAK,OAAO,EAEZ,KAAK,QAAQ,EACb,KAAK,wBAAwB,EAmBhC,MAAM,qBAAqB,CAAC;AAiB7B,OAAO,EAAE,KAAK,uBAAuB,EAAE,MAAM,2CAA2C,CAAC;
|
|
1
|
+
{"version":3,"file":"useValidateExistingAutomationFilters.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/automations/shared/automationFilters/hooks/useValidateExistingAutomationFilters.ts"],"names":[],"mappings":"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"}
|
|
@@ -11,9 +11,10 @@ import { selectWidgetLocalIdToTabIdMap } from "../../../../../model/store/tabs/l
|
|
|
11
11
|
import { selectSmartPersistedTabsParameters } from "../../../../../model/store/tabs/parameters/parametersSelectors.js";
|
|
12
12
|
import { selectTabs } from "../../../../../model/store/tabs/tabsSelectors.js";
|
|
13
13
|
import { useAutomationsContext } from "../../../contexts/AutomationsContext.js";
|
|
14
|
+
import { isNoopAllTimeDateFilterFixed } from "../../filters/index.js";
|
|
14
15
|
import { getAutomationAlertFilters, getAutomationDashboardFilters, getAutomationDashboardFiltersByTab, getAutomationVisualizationFilters, } from "../../utils/automationUtils.js";
|
|
15
16
|
import { hasStaleAlertParameters } from "../automationParameters.js";
|
|
16
|
-
import { areFiltersEqual, isFilterIgnoredByWidget, isFilterMatch
|
|
17
|
+
import { areFiltersEqual, isFilterIgnoredByWidget, isFilterMatch } from "../utils.js";
|
|
17
18
|
function sanitizeCommonDateFilter(filter, commonDateFilterId) {
|
|
18
19
|
// Sanitize common date filters by removing date dataSet
|
|
19
20
|
if (isDateFilter(filter) && filterLocalIdentifier(filter) === commonDateFilterId) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type IntlShape } from "react-intl";
|
|
2
|
-
import { type FilterContextItem, type
|
|
2
|
+
import { type FilterContextItem, type ICatalogAttribute, type ICatalogDateDataset, type ICatalogMeasure, type IDashboardAttributeFilterConfig, type IDashboardDateFilterConfigItem, type IDashboardMeasureValueFilterConfig, type IDateFilter, type IFilter, type ObjRef } from "@gooddata/sdk-model";
|
|
3
3
|
import { type ExtendedDashboardWidget } from "../../../../model/types/layoutTypes.js";
|
|
4
4
|
export declare const getFilterLocalIdentifier: (filter: FilterContextItem) => string | undefined;
|
|
5
5
|
export declare const validateAllFilterLocalIdentifiers: (filters: FilterContextItem[]) => boolean;
|
|
@@ -9,29 +9,6 @@ export declare const getCatalogAttributesByFilters: (filters: FilterContextItem[
|
|
|
9
9
|
export declare const getCatalogMeasuresByFilters: (filters: FilterContextItem[], measures: ICatalogMeasure[], mvfConfigs: IDashboardMeasureValueFilterConfig[]) => ICatalogMeasure[];
|
|
10
10
|
export declare const getCatalogDateDatasetsByFilters: (filters: FilterContextItem[], dateDataset: ICatalogDateDataset[], dateConfigs: IDashboardDateFilterConfigItem[]) => ICatalogDateDataset[];
|
|
11
11
|
export declare const getFilterByCatalogItemRef: (ref: ObjRef, filters: FilterContextItem[]) => FilterContextItem | undefined;
|
|
12
|
-
export declare const getVisibleFiltersByFilters: (selectedFilters: FilterContextItem[] | undefined, visibleFiltersMetadata: IAutomationVisibleFilter[] | undefined, storeFilters?: boolean | undefined) => IAutomationVisibleFilter[] | undefined;
|
|
13
|
-
/**
|
|
14
|
-
* Get visible filters metadata structured by tab.
|
|
15
|
-
* Applies the same logic as getVisibleFiltersByFilters to each tab's filters.
|
|
16
|
-
*/
|
|
17
|
-
export declare const getVisibleFiltersByFiltersByTab: (filtersByTab: Record<string, FilterContextItem[]> | undefined, visibleFiltersMetadata: Record<string, IAutomationVisibleFilter[]> | undefined, storeFilters?: boolean | undefined) => Record<string, IAutomationVisibleFilter[]> | undefined;
|
|
18
|
-
/**
|
|
19
|
-
* Resolve MVF dimensionality localIdRefs to stable identifierRefs using the insight's attributes.
|
|
20
|
-
*
|
|
21
|
-
* Measure value filters may reference attributes in their dimensionality via localIdRef,
|
|
22
|
-
* which is only meaningful within the insight's own execution context. When these filters
|
|
23
|
-
* are used in an alert execution (which may not include the original attributes), the
|
|
24
|
-
* localIdRefs become dangling. This function resolves them to display form identifierRefs.
|
|
25
|
-
*/
|
|
26
|
-
export declare function resolveMvfDimensionalityLocalRefs(filters: IFilter[], insight: IInsight | undefined): IFilter[];
|
|
27
|
-
/**
|
|
28
|
-
* Get final execution filters for the widget alert or scheduled export.
|
|
29
|
-
*/
|
|
30
|
-
export declare const getAppliedWidgetFilters: (selectedAutomationFilters: FilterContextItem[], dashboardHiddenFilters: FilterContextItem[], widget: ExtendedDashboardWidget | undefined, insight: IInsight | undefined, commonDateFilterId: string | undefined, mergeInsightFilters?: boolean, withoutWidget?: boolean) => IFilter[];
|
|
31
|
-
/**
|
|
32
|
-
* Get final filters for the dashboard scheduled export.
|
|
33
|
-
*/
|
|
34
|
-
export declare const getAppliedDashboardFilters: (selectedAutomationFilters: FilterContextItem[], dashboardHiddenFilters: FilterContextItem[], storeFilters?: boolean | undefined) => FilterContextItem[] | undefined;
|
|
35
12
|
export declare const getNonHiddenFilters: (filters: FilterContextItem[] | undefined, attributeConfigs: IDashboardAttributeFilterConfig[], dateConfigs: IDashboardDateFilterConfigItem[], isCommonDateFilterHidden: boolean, disableDateFilters: boolean) => FilterContextItem[];
|
|
36
13
|
export declare const getFilterByLocalIdentifier: (localIdentifier: string | undefined, filters: FilterContextItem[]) => FilterContextItem | undefined;
|
|
37
14
|
/**
|
|
@@ -40,14 +17,6 @@ export declare const getFilterByLocalIdentifier: (localIdentifier: string | unde
|
|
|
40
17
|
* This function is used to fix this inconsistency.
|
|
41
18
|
*/
|
|
42
19
|
export declare function isAllTimeDateFilterFixed(f: IFilter): boolean;
|
|
43
|
-
/**
|
|
44
|
-
* Similar to {@link isAllTimeDateFilterFixed}, but only matches *noop* all-time filters.
|
|
45
|
-
*
|
|
46
|
-
* @remarks
|
|
47
|
-
* Noop all-time filters are implicit defaults and have no effect on execution. All-time filters with `emptyValueHandling`
|
|
48
|
-
* are considered meaningful (they carry extra configuration) and should not be treated as no-op.
|
|
49
|
-
*/
|
|
50
|
-
export declare function isNoopAllTimeDateFilterFixed(f: IFilter): boolean;
|
|
51
20
|
export declare function areFiltersEqual(filter1: IFilter, filter2: IFilter): boolean;
|
|
52
21
|
export declare function dateFilterValues(filter: IDateFilter): import("@gooddata/sdk-model").IAbsoluteDateFilterValues | import("@gooddata/sdk-model").IRelativeDateFilterValues;
|
|
53
22
|
export declare function isFilterIgnoredByWidget(filter: FilterContextItem, widget: ExtendedDashboardWidget): boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/automations/shared/automationFilters/utils.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,YAAY,CAAC;AAE5C,OAAO,EACH,KAAK,iBAAiB,EACtB,KAAK,
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/automations/shared/automationFilters/utils.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,YAAY,CAAC;AAE5C,OAAO,EACH,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,EACtB,KAAK,mBAAmB,EACxB,KAAK,eAAe,EACpB,KAAK,+BAA+B,EACpC,KAAK,8BAA8B,EACnC,KAAK,kCAAkC,EACvC,KAAK,WAAW,EAChB,KAAK,OAAO,EACZ,KAAK,MAAM,EA6Bd,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EAAE,KAAK,uBAAuB,EAAE,MAAM,wCAAwC,CAAC;AAEtF,eAAO,MAAM,wBAAwB,mDAEpC,CAAC;AAEF,eAAO,MAAM,iCAAiC,2CAE7C,CAAC;AAEF,eAAO,MAAM,6BAA6B,qEAKzC,CAAC;AAEF,eAAO,MAAM,qBAAqB,gGASjC,CAAC;AAEF,eAAO,MAAM,6BAA6B,6IA0BzC,CAAC;AAEF,eAAO,MAAM,2BAA2B,oIAqBvC,CAAC;AAEF,eAAO,MAAM,+BAA+B,4IAwB3C,CAAC;AAEF,eAAO,MAAM,yBAAyB,8EAcrC,CAAC;AAEF,eAAO,MAAM,mBAAmB,uOA0B/B,CAAC;AAEF,eAAO,MAAM,0BAA0B,sGAYtC,CAAC;AAEF;;;;GAIG;AACH,wBAAgB,wBAAwB,CAAC,CAAC,EAAE,OAAO,GAAG,OAAO,CAuB5D;AAED,wBAAgB,eAAe,CAAC,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,GAAG,OAAO,CA+C3E;AAED,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,WAAW,qHAMnD;AAED,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,iBAAiB,EAAE,MAAM,EAAE,uBAAuB,GAAG,OAAO,CA+B3G;AAED,wBAAgB,aAAa,CAAC,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,GAAG,OAAO,CAazE;AAED,eAAO,MAAM,cAAc,oIA8C1B,CAAC"}
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
// (C) 2025-2026 GoodData Corporation
|
|
2
|
-
import {
|
|
3
|
-
import { absoluteDateFilterValues, areObjRefsEqual,
|
|
4
|
-
import { filterContextItemsToDashboardFiltersByWidget } from "../../../../converters/filterConverters.js";
|
|
5
|
-
import { removeIgnoredWidgetFilters } from "../../../../model/utils/widgetFilters.js";
|
|
2
|
+
import { isEqual } from "lodash-es";
|
|
3
|
+
import { absoluteDateFilterValues, areObjRefsEqual, dashboardAttributeFilterItemDisplayForm, dashboardAttributeFilterItemLocalIdentifier, dashboardFilterLocalIdentifier, dashboardFilterObjRef, filterAttributeElements, filterLocalIdentifier, filterObjRef, getAttributeElementsItems, isAbsoluteDateFilter, isAllTimeDateFilter, isArbitraryAttributeFilter, isAttributeFilter, isDashboardArbitraryAttributeFilter, isDashboardAttributeFilter, isDashboardAttributeFilterItem, isDashboardCommonDateFilter, isDashboardDateFilter, isDashboardMatchAttributeFilter, isDashboardMeasureValueFilter, isDateFilter, isInsightWidget, isMatchAttributeFilter, isNegativeAttributeFilter, isPositiveAttributeFilter, isRelativeDateFilter, relativeDateFilterValues, } from "@gooddata/sdk-model";
|
|
6
4
|
export const getFilterLocalIdentifier = (filter) => {
|
|
7
5
|
return dashboardFilterLocalIdentifier(filter);
|
|
8
6
|
};
|
|
@@ -82,152 +80,6 @@ export const getFilterByCatalogItemRef = (ref, filters) => {
|
|
|
82
80
|
return false;
|
|
83
81
|
});
|
|
84
82
|
};
|
|
85
|
-
export const getVisibleFiltersByFilters = (selectedFilters, visibleFiltersMetadata, storeFilters) => {
|
|
86
|
-
if (!storeFilters) {
|
|
87
|
-
return undefined;
|
|
88
|
-
}
|
|
89
|
-
const filters = (selectedFilters ?? [])
|
|
90
|
-
// Strip noop "All values" attribute filters and "All" measure value filters —
|
|
91
|
-
// they have no effect on execution and should not be stored in visible filters metadata.
|
|
92
|
-
.filter((filter) => !isAllValuesDashboardAttributeFilter(filter) && !isAllDashboardMeasureValueFilter(filter))
|
|
93
|
-
.map((selectedFilter) => {
|
|
94
|
-
const selectedLocalIdentifier = getFilterLocalIdentifier(selectedFilter);
|
|
95
|
-
const targetFilter = (visibleFiltersMetadata ?? []).find((visibleFilter) => {
|
|
96
|
-
return selectedLocalIdentifier === visibleFilter.localIdentifier;
|
|
97
|
-
});
|
|
98
|
-
if (targetFilter && isDashboardDateFilter(selectedFilter)) {
|
|
99
|
-
return {
|
|
100
|
-
...targetFilter,
|
|
101
|
-
// NOTE: despite the name, this flag is used to mark *noop* "All time" filters (implicit default)
|
|
102
|
-
// that are intentionally not stored in automation execution filters.
|
|
103
|
-
isAllTimeDateFilter: isNoopAllTimeDashboardDateFilter(selectedFilter),
|
|
104
|
-
};
|
|
105
|
-
}
|
|
106
|
-
return targetFilter;
|
|
107
|
-
});
|
|
108
|
-
return compact(filters);
|
|
109
|
-
};
|
|
110
|
-
/**
|
|
111
|
-
* Get visible filters metadata structured by tab.
|
|
112
|
-
* Applies the same logic as getVisibleFiltersByFilters to each tab's filters.
|
|
113
|
-
*/
|
|
114
|
-
export const getVisibleFiltersByFiltersByTab = (filtersByTab, visibleFiltersMetadata, storeFilters) => {
|
|
115
|
-
if (!storeFilters || !filtersByTab) {
|
|
116
|
-
return undefined;
|
|
117
|
-
}
|
|
118
|
-
return Object.entries(filtersByTab).reduce((acc, [tabId, tabFilters]) => {
|
|
119
|
-
const visibleFilters = getVisibleFiltersByFilters(tabFilters, visibleFiltersMetadata?.[tabId], true);
|
|
120
|
-
if (visibleFilters && visibleFilters.length > 0) {
|
|
121
|
-
acc[tabId] = visibleFilters;
|
|
122
|
-
}
|
|
123
|
-
return acc;
|
|
124
|
-
}, {});
|
|
125
|
-
};
|
|
126
|
-
/**
|
|
127
|
-
* Resolve MVF dimensionality localIdRefs to stable identifierRefs using the insight's attributes.
|
|
128
|
-
*
|
|
129
|
-
* Measure value filters may reference attributes in their dimensionality via localIdRef,
|
|
130
|
-
* which is only meaningful within the insight's own execution context. When these filters
|
|
131
|
-
* are used in an alert execution (which may not include the original attributes), the
|
|
132
|
-
* localIdRefs become dangling. This function resolves them to display form identifierRefs.
|
|
133
|
-
*/
|
|
134
|
-
export function resolveMvfDimensionalityLocalRefs(filters, insight) {
|
|
135
|
-
if (!insight) {
|
|
136
|
-
return filters;
|
|
137
|
-
}
|
|
138
|
-
const attributeLocalIdToDisplayForm = new Map();
|
|
139
|
-
insightAttributes(insight).forEach((attribute) => {
|
|
140
|
-
attributeLocalIdToDisplayForm.set(attributeLocalId(attribute), attribute.attribute.displayForm);
|
|
141
|
-
});
|
|
142
|
-
if (attributeLocalIdToDisplayForm.size === 0) {
|
|
143
|
-
return filters;
|
|
144
|
-
}
|
|
145
|
-
return filters.map((filter) => {
|
|
146
|
-
if (!isMeasureValueFilter(filter)) {
|
|
147
|
-
return filter;
|
|
148
|
-
}
|
|
149
|
-
const dimensionality = filter.measureValueFilter.dimensionality;
|
|
150
|
-
if (!dimensionality?.length) {
|
|
151
|
-
return filter;
|
|
152
|
-
}
|
|
153
|
-
const resolvedDimensionality = dimensionality.map((item) => {
|
|
154
|
-
if (!isLocalIdRef(item)) {
|
|
155
|
-
return item;
|
|
156
|
-
}
|
|
157
|
-
return attributeLocalIdToDisplayForm.get(item.localIdentifier) ?? item;
|
|
158
|
-
});
|
|
159
|
-
const changed = dimensionality.some((item, i) => item !== resolvedDimensionality[i]);
|
|
160
|
-
if (!changed) {
|
|
161
|
-
return filter;
|
|
162
|
-
}
|
|
163
|
-
return {
|
|
164
|
-
...filter,
|
|
165
|
-
measureValueFilter: {
|
|
166
|
-
...filter.measureValueFilter,
|
|
167
|
-
dimensionality: resolvedDimensionality,
|
|
168
|
-
},
|
|
169
|
-
};
|
|
170
|
-
});
|
|
171
|
-
}
|
|
172
|
-
/**
|
|
173
|
-
* Get final execution filters for the widget alert or scheduled export.
|
|
174
|
-
*/
|
|
175
|
-
export const getAppliedWidgetFilters = (selectedAutomationFilters, dashboardHiddenFilters, widget, insight, commonDateFilterId, mergeInsightFilters = false, withoutWidget = false) => {
|
|
176
|
-
// Hidden filters are never included in selectedAutomationFilters,
|
|
177
|
-
// but we need them to construct proper execution filters, so merge them.
|
|
178
|
-
const selectedFiltersWithHiddenFilters = [...selectedAutomationFilters, ...dashboardHiddenFilters];
|
|
179
|
-
// Now, remove ignored filters (some of the hidden filters might be ignored).
|
|
180
|
-
const selectedFiltersWithoutIgnoredFilters = removeIgnoredWidgetFilters(selectedFiltersWithHiddenFilters, widget);
|
|
181
|
-
// Now, convert sanitized selected filters to execution filters shape.
|
|
182
|
-
const selectedExecutionFilters = isInsightWidget(widget)
|
|
183
|
-
? filterContextItemsToDashboardFiltersByWidget(selectedFiltersWithoutIgnoredFilters, widget)
|
|
184
|
-
: withoutWidget
|
|
185
|
-
? filterContextItemsToDashboardFiltersByWidget(selectedFiltersWithoutIgnoredFilters, undefined)
|
|
186
|
-
: [];
|
|
187
|
-
const filtersToUse = mergeInsightFilters
|
|
188
|
-
? mergeFilters(insight?.insight?.filters ?? [], selectedExecutionFilters, commonDateFilterId)
|
|
189
|
-
: selectedExecutionFilters;
|
|
190
|
-
// Resolve MVF dimensionality localIdRefs to stable identifierRefs so that
|
|
191
|
-
// alert executions (which have empty attributes) don't contain dangling refs.
|
|
192
|
-
const resolvedFilters = resolveMvfDimensionalityLocalRefs(filtersToUse, insight);
|
|
193
|
-
// Strip noop filters - they have no effect on execution.
|
|
194
|
-
return resolvedFilters.filter((filter) => {
|
|
195
|
-
// Strip noop "All time" date filters (implicit default with no extra configuration).
|
|
196
|
-
if (isDateFilter(filter)) {
|
|
197
|
-
return !isNoopAllTimeDateFilterFixed(filter);
|
|
198
|
-
}
|
|
199
|
-
// Strip noop "All" measure value filters (no conditions).
|
|
200
|
-
if (isMeasureValueFilter(filter)) {
|
|
201
|
-
return hasMeasureValueFilterConditions(filter);
|
|
202
|
-
}
|
|
203
|
-
// Strip noop "All values" attribute filters (negative filter with empty exclusion list).
|
|
204
|
-
return !isAllValuesAttributeFilter(filter);
|
|
205
|
-
});
|
|
206
|
-
};
|
|
207
|
-
/**
|
|
208
|
-
* Get final filters for the dashboard scheduled export.
|
|
209
|
-
*/
|
|
210
|
-
export const getAppliedDashboardFilters = (selectedAutomationFilters, dashboardHiddenFilters, storeFilters) => {
|
|
211
|
-
if (!storeFilters) {
|
|
212
|
-
return undefined;
|
|
213
|
-
}
|
|
214
|
-
// Hidden filters are never included in selectedAutomationFilters,
|
|
215
|
-
// but we need them to construct proper execution filters, so merge them.
|
|
216
|
-
const selectedFiltersWithHiddenFilters = [...selectedAutomationFilters, ...dashboardHiddenFilters];
|
|
217
|
-
// Strip noop filters - they have no effect on execution.
|
|
218
|
-
return selectedFiltersWithHiddenFilters.filter((filter) => {
|
|
219
|
-
// Strip noop "All time" date filters (implicit default with no extra configuration).
|
|
220
|
-
if (isDashboardDateFilter(filter)) {
|
|
221
|
-
return !isNoopAllTimeDashboardDateFilter(filter);
|
|
222
|
-
}
|
|
223
|
-
// Strip noop "All" measure value filters (no/empty conditions).
|
|
224
|
-
if (isDashboardMeasureValueFilter(filter)) {
|
|
225
|
-
return !isAllDashboardMeasureValueFilter(filter);
|
|
226
|
-
}
|
|
227
|
-
// Strip noop "All values" attribute filters.
|
|
228
|
-
return !isAllValuesDashboardAttributeFilter(filter);
|
|
229
|
-
});
|
|
230
|
-
};
|
|
231
83
|
export const getNonHiddenFilters = (filters, attributeConfigs, dateConfigs, isCommonDateFilterHidden, disableDateFilters) => {
|
|
232
84
|
return (filters ?? []).filter((filter) => {
|
|
233
85
|
if (isDashboardAttributeFilterItem(filter)) {
|
|
@@ -279,33 +131,6 @@ export function isAllTimeDateFilterFixed(f) {
|
|
|
279
131
|
}
|
|
280
132
|
return false;
|
|
281
133
|
}
|
|
282
|
-
/**
|
|
283
|
-
* Similar to {@link isAllTimeDateFilterFixed}, but only matches *noop* all-time filters.
|
|
284
|
-
*
|
|
285
|
-
* @remarks
|
|
286
|
-
* Noop all-time filters are implicit defaults and have no effect on execution. All-time filters with `emptyValueHandling`
|
|
287
|
-
* are considered meaningful (they carry extra configuration) and should not be treated as no-op.
|
|
288
|
-
*/
|
|
289
|
-
export function isNoopAllTimeDateFilterFixed(f) {
|
|
290
|
-
// Standard check for noop all-time date filter.
|
|
291
|
-
if (isAllTimeDateFilter(f)) {
|
|
292
|
-
return f.relativeDateFilter.emptyValueHandling === undefined;
|
|
293
|
-
}
|
|
294
|
-
// Analytical Designer may store "all-time" as a relative date filter without from/to.
|
|
295
|
-
// Treat it as no-op only when it does NOT carry extra configuration (e.g. emptyValueHandling).
|
|
296
|
-
if (isRelativeDateFilter(f)) {
|
|
297
|
-
return ((f.relativeDateFilter.from === null || f.relativeDateFilter.from === undefined) &&
|
|
298
|
-
(f.relativeDateFilter.to === null || f.relativeDateFilter.to === undefined) &&
|
|
299
|
-
f.relativeDateFilter.emptyValueHandling === undefined);
|
|
300
|
-
}
|
|
301
|
-
// Not expected, but keep the symmetric safety behavior for absolute filters.
|
|
302
|
-
if (isAbsoluteDateFilter(f)) {
|
|
303
|
-
return ((f.absoluteDateFilter.from === null || f.absoluteDateFilter.from === undefined) &&
|
|
304
|
-
(f.absoluteDateFilter.to === null || f.absoluteDateFilter.to === undefined) &&
|
|
305
|
-
f.absoluteDateFilter.emptyValueHandling === undefined);
|
|
306
|
-
}
|
|
307
|
-
return false;
|
|
308
|
-
}
|
|
309
134
|
export function areFiltersEqual(filter1, filter2) {
|
|
310
135
|
if (isAttributeFilter(filter1) && isAttributeFilter(filter2)) {
|
|
311
136
|
const filter1Ref = filterObjRef(filter1);
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { type FilterContextItem, type IAutomationVisibleFilter, type IFilter, type IInsight } from "@gooddata/sdk-model";
|
|
2
|
+
import { type ExtendedDashboardWidget } from "../../../../model/types/layoutTypes.js";
|
|
3
|
+
import { type IDashboardFilter } from "../../../../types.js";
|
|
4
|
+
export declare const getVisibleFiltersByFilters: (selectedFilters: FilterContextItem[] | undefined, visibleFiltersMetadata: IAutomationVisibleFilter[] | undefined, storeFilters?: boolean | undefined) => IAutomationVisibleFilter[] | undefined;
|
|
5
|
+
/**
|
|
6
|
+
* Get visible filters metadata structured by tab.
|
|
7
|
+
* Applies the same logic as getVisibleFiltersByFilters to each tab's filters.
|
|
8
|
+
*/
|
|
9
|
+
export declare const getVisibleFiltersByFiltersByTab: (filtersByTab: Record<string, FilterContextItem[]> | undefined, visibleFiltersMetadata: Record<string, IAutomationVisibleFilter[]> | undefined, storeFilters?: boolean | undefined) => Record<string, IAutomationVisibleFilter[]> | undefined;
|
|
10
|
+
/**
|
|
11
|
+
* Get final execution filters for the widget alert or scheduled export.
|
|
12
|
+
*/
|
|
13
|
+
export declare const getAppliedWidgetFilters: (selectedAutomationFilters: FilterContextItem[], dashboardHiddenFilters: FilterContextItem[], widget: ExtendedDashboardWidget | undefined, insight: IInsight | undefined, commonDateFilterId: string | undefined, mergeInsightFilters?: boolean, withoutWidget?: boolean) => IFilter[];
|
|
14
|
+
/**
|
|
15
|
+
* Get final filters for the dashboard scheduled export.
|
|
16
|
+
*/
|
|
17
|
+
export declare const getAppliedDashboardFilters: (selectedAutomationFilters: FilterContextItem[], dashboardHiddenFilters: FilterContextItem[], storeFilters?: boolean | undefined) => FilterContextItem[] | undefined;
|
|
18
|
+
export declare function dashboardFilterToFilterContextItem(filter: IDashboardFilter, keepDatasets: boolean): FilterContextItem | undefined;
|
|
19
|
+
/**
|
|
20
|
+
* Resolve MVF dimensionality localIdRefs to stable identifierRefs using the insight's attributes.
|
|
21
|
+
*
|
|
22
|
+
* Measure value filters may reference attributes in their dimensionality via localIdRef,
|
|
23
|
+
* which is only meaningful within the insight's own execution context. When these filters
|
|
24
|
+
* are used in an alert execution (which may not include the original attributes), the
|
|
25
|
+
* localIdRefs become dangling. This function resolves them to display form identifierRefs.
|
|
26
|
+
*/
|
|
27
|
+
export declare function resolveMvfDimensionalityLocalRefs(filters: IFilter[], insight: IInsight | undefined): IFilter[];
|
|
28
|
+
/**
|
|
29
|
+
* Similar to {@link isAllTimeDateFilterFixed}, but only matches *noop* all-time filters.
|
|
30
|
+
*
|
|
31
|
+
* @remarks
|
|
32
|
+
* Noop all-time filters are implicit defaults and have no effect on execution. All-time filters with `emptyValueHandling`
|
|
33
|
+
* are considered meaningful (they carry extra configuration) and should not be treated as no-op.
|
|
34
|
+
*/
|
|
35
|
+
export declare function isNoopAllTimeDateFilterFixed(f: IFilter): boolean;
|
|
36
|
+
//# sourceMappingURL=conversions.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"conversions.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/automations/shared/filters/conversions.ts"],"names":[],"mappings":"AAKA,OAAO,EAEH,KAAK,iBAAiB,EACtB,KAAK,wBAAwB,EAC7B,KAAK,OAAO,EACZ,KAAK,QAAQ,EAkChB,MAAM,qBAAqB,CAAC;AAG7B,OAAO,EAAE,KAAK,uBAAuB,EAAE,MAAM,wCAAwC,CAAC;AAEtF,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAE7D,eAAO,MAAM,0BAA0B,kMAmCtC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,+BAA+B,+OAuB3C,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,uBAAuB,wRA+CnC,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,0BAA0B,sKAyBtC,CAAC;AAEF,wBAAgB,kCAAkC,CAC9C,MAAM,EAAE,gBAAgB,EACxB,YAAY,EAAE,OAAO,GACtB,iBAAiB,GAAG,SAAS,CA8E/B;AAED;;;;;;;GAOG;AACH,wBAAgB,iCAAiC,CAC7C,OAAO,EAAE,OAAO,EAAE,EAClB,OAAO,EAAE,QAAQ,GAAG,SAAS,GAC9B,OAAO,EAAE,CA4CX;AAED;;;;;;GAMG;AACH,wBAAgB,4BAA4B,CAAC,CAAC,EAAE,OAAO,GAAG,OAAO,CA0BhE"}
|