// (C) 2021-2026 GoodData Corporation
import { createSelector } from "@reduxjs/toolkit";
import { invariant } from "ts-invariant";
const selectSelf = createSelector((state) => state, (state) => state.config);
/**
 * Returns dashboard's config.
 *
 * @remarks
 * It is expected that the selector is called only after the config state
 * is correctly initialized. Invocations before initialization lead to invariant errors.
 *
 * @public
 */
export const selectConfig = createSelector(selectSelf, (configState) => {
    invariant(configState.config, "attempting to access uninitialized config state");
    return configState.config;
});
/**
 * Returns workspace-level configuration for the of the date filter options and presets.
 *
 * @remarks
 * Note: this configuration SHOULD be further augmented by the dashboard-level overrides to obtain
 * the effective date filter configuration.
 *
 * @public
 */
export const selectDateFilterConfig = createSelector(selectConfig, (state) => {
    return state.dateFilterConfig ?? undefined;
});
/**
 * Returns settings that are in effect for the current dashboard.
 *
 * @public
 */
export const selectSettings = createSelector(selectConfig, (state) => {
    return state.settings ?? undefined;
});
/**
 * Returns locale to use for internationalization of the dashboard.
 *
 * @public
 */
export const selectLocale = createSelector(selectConfig, (state) => {
    return state.locale ?? undefined;
});
/**
 * Returns timezone
 *
 * @public
 */
export const selectTimezone = createSelector(selectConfig, (state) => {
    return state.settings.timezone ?? undefined;
});
/**
 * Returns number separators to use when rendering numeric values on charts or KPIs.
 *
 * @public
 */
export const selectSeparators = createSelector(selectConfig, (state) => {
    return state.separators ?? undefined;
});
/**
 * Returns the color palette for dashboard charts.
 *
 * @public
 */
export const selectColorPalette = createSelector(selectConfig, (state) => {
    return state.colorPalette ?? undefined;
});
/**
 * Returns the object availability configuration for this dashboard.
 *
 * @remarks
 * Only objects that match the availability criteria can appear in selections where user has pick
 * an object to use for some purpose (for instance metric for KPI or date dataset to filter by).
 *
 * @public
 */
export const selectObjectAvailabilityConfig = createSelector(selectConfig, (state) => {
    return state.objectAvailability ?? undefined;
});
/**
 * Returns Mapbox token.
 *
 * @internal
 */
export const selectMapboxToken = createSelector(selectConfig, (state) => {
    return state.mapboxToken ?? undefined;
});
/**
 * Returns AgGrid token.
 *
 * @internal
 */
export const selectAgGridToken = createSelector(selectConfig, (state) => {
    return state.agGridToken ?? undefined;
});
/**
 * Returns max zoom level for GeoChart map.
 *
 * @internal
 */
export const selectMaxZoomLevel = createSelector(selectConfig, (state) => {
    return state.maxZoomLevel;
});
/**
 * Returns week start day
 *
 * @internal
 */
export const selectWeekStart = createSelector(selectConfig, (state) => {
    if (state.settings == null) {
        return "Sunday";
    }
    if (state.settings["enableNewUIWeekStartChange"] && state.settings["weekStartOnMondayEnabled"]) {
        return "Monday";
    }
    return state.settings?.weekStart ?? "Sunday";
});
/**
 * Returns whether the Dashboard is executed in read-only mode.
 *
 * @remarks
 * Read-only mode disables any interactions that can alter the backend data.
 *
 * @public
 */
export const selectIsReadOnly = createSelector(selectConfig, (state) => {
    return state.isReadOnly ?? false;
});
/**
 * Returns whether the Dashboard is executed in embedded context.
 *
 * @remarks
 * In embedded mode, some interactions may be disabled.
 *
 * @public
 */
export const selectIsEmbedded = createSelector(selectConfig, (state) => {
    return state.isEmbedded ?? false;
});
/**
 * Returns whether the Dashboard is rendered in the export mode.
 * In export mode, some components can be hidden, or rendered differently.
 *
 * @public
 */
export const selectIsExport = createSelector(selectConfig, (state) => {
    return state.isExport ?? false;
});
/**
 * Returns custom export metadata.
 *
 * @beta
 */
export const selectExportMetadata = createSelector(selectConfig, (state) => {
    return state.exportMetadata;
});
/**
 * Returns whether the Dashboard is white labeled.
 *
 * @internal
 */
export const selectIsWhiteLabeled = createSelector(selectConfig, (state) => {
    return state.isWhiteLabeled ?? false;
});
/**
 * Returns whether the default drills configured on the widgets or implicit drills (eg. drill down) are disabled.
 * This option does not affect drilling enabled by drillableItems.
 *
 * @public
 */
export const selectDisableDefaultDrills = createSelector(selectConfig, (state) => {
    return state.disableDefaultDrills ?? false;
});
/**
 * Returns whether filter values in drill events should be resolved.
 *
 * @public
 */
export const selectEnableFilterValuesResolutionInDrillEvents = createSelector(selectConfig, (state) => {
    return state.enableFilterValuesResolutionInDrillEvents ?? false;
});
/**
 * Returns whether the save as new button is hidden.
 *
 * @internal
 */
export const selectIsSaveAsNewButtonHidden = createSelector(selectConfig, (state) => {
    return state.hideSaveAsNewButton ?? false;
});
//
// FEATURE FLAGS
//
/**
 * Returns date format.
 *
 * @public
 */
export const selectDateFormat = createSelector(selectConfig, (state) => {
    return state.settings?.responsiveUiDateFormat ?? undefined;
});
/**
 * Returns current platform edition.
 *
 * @public
 */
export const selectPlatformEdition = createSelector(selectConfig, (state) => {
    return state.settings?.platformEdition ?? "enterprise";
});
/**
 * Returns whether the export to pdf is enabled.
 *
 * @public
 */
export const selectEnableKPIDashboardExportPDF = createSelector(selectConfig, (state) => {
    return state.settings?.["enableKPIDashboardExportPDF"] ?? true;
});
/**
 * @alpha
 */
export const selectEnableScheduling = createSelector(selectConfig, (state) => {
    return state.settings?.enableScheduling ?? true;
});
/**
 * Returns whether dashboard-level parameter controls are enabled.
 *
 * @alpha
 */
export const selectEnableParameters = createSelector(selectConfig, (state) => {
    return state.settings?.enableParameters ?? false;
});
/**
 * @alpha
 */
export const selectEnableAlerting = createSelector(selectConfig, (state) => {
    return state.settings?.enableAlerting ?? true;
});
/**
 * @alpha
 */
export const selectEnableAlertAttributes = createSelector(selectConfig, (state) => {
    return state.settings?.enableAlertAttributes ?? true;
});
/**
 * @alpha
 */
export const selectEnableComparisonInAlerting = createSelector(selectConfig, (state) => {
    return state.settings?.enableComparisonInAlerting ?? true;
});
/**
 * @alpha
 */
export const selectEnableAutomations = createSelector(selectEnableScheduling, selectEnableAlerting, (enableScheduling, enableAlerting) => {
    return enableScheduling || enableAlerting;
});
/**
 * Returns whether we should disable the underline in KPIs when they are drillable.
 *
 * @internal
 */
export const selectDisableKpiDashboardHeadlineUnderline = createSelector(selectConfig, (state) => {
    return !!(state.settings?.disableKpiDashboardHeadlineUnderline ?? false);
});
/**
 * Returns whether unfinished features are allowed.
 *
 * @internal
 */
export const selectAllowUnfinishedFeatures = createSelector(selectConfig, (state) => state.allowUnfinishedFeatures || false);
/**
 * Returns whether creating new insight from dashboard is enabled.
 *
 * @internal
 */
export const selectAllowCreateInsightRequest = createSelector(selectConfig, (state) => {
    return state.allowCreateInsightRequest ?? false;
});
/**
 * Returns whether dependent filters are enabled.
 *
 * @internal
 */
export const selectIsKPIDashboardDependentFiltersEnabled = () => true;
/**
 * Returns whether new KD dependent filters are enabled.
 *
 * @internal
 */
export const selectEnableKDDependentFilters = () => true;
/**
 * Returns whether KD dependent filters are enabled.
 *
 * @internal
 */
export const selectIsKDDependentFiltersEnabled = createSelector(selectEnableKDDependentFilters, selectIsKPIDashboardDependentFiltersEnabled, (enableKDDependentFilters, isKPIDashboardDependentFiltersEnabled) => {
    return enableKDDependentFilters || isKPIDashboardDependentFiltersEnabled;
});
/**
 * Returns whether share button is hidden.
 *
 * @internal
 */
export const selectIsShareButtonHidden = createSelector(selectConfig, (state) => {
    return state.hideShareButton ?? false;
});
/**
 * Returns whether the add tab button should be hidden in edit mode.
 *
 * @alpha
 */
export const selectIsAddTabButtonHidden = createSelector(selectConfig, (state) => {
    return state.hideAddTabButton ?? false;
});
/**
 * Returns whether cross filtering is disabled by config
 *
 * @internal
 */
export const selectIsDisabledCrossFiltering = createSelector(selectConfig, (state) => {
    return state.disableCrossFiltering ?? false;
});
/**
 * Returns whether kda is disabled by config
 *
 * @internal
 */
export const selectIsDisabledKda = createSelector(selectConfig, () => {
    //TODO: SHA Connect to dashboard config
    return false;
});
/**
 * Returns whether user filter reset is disabled by config
 *
 * @internal
 */
export const selectIsDisableUserFilterReset = createSelector(selectConfig, (state) => {
    return state.disableUserFilterReset ?? false;
});
/**
 * Returns whether the unrelated data datasets are shown.
 *
 * @internal
 */
export const selectEnableUnavailableItemsVisibility = createSelector(selectConfig, (state) => {
    return state.settings?.showHiddenCatalogItems ?? false;
});
/**
 * Returns whether multiple date filters are enabled.
 *
 * @internal
 */
export const selectEnableMultipleDateFilters = createSelector(selectConfig, (state) => {
    return state.settings?.enableMultipleDateFilters ?? true;
});
/**
 * Returns whether rich text widgets are enabled.
 *
 * @internal
 */
export const selectEnableKDRichText = createSelector(selectConfig, (state) => {
    return state.settings?.enableKDRichText ?? true;
});
/**
 * Returns whether KD cross filtering is enabled.
 *
 * @internal
 */
export const selectEnableKDCrossFiltering = createSelector(selectConfig, (state) => {
    return state.settings?.enableKDCrossFiltering ?? false;
});
/**
 * Returns whether kda is enabled
 *
 * @internal
 */
export const selectEnableKda = createSelector(selectConfig, (state) => {
    return state.settings?.enableChangeAnalysis ?? false;
});
/**
 * Returns whether KD attribute filter by dates validation/filtering is enabled.
 *
 * @internal
 */
export const selectEnableKDAttributeFilterDatesValidation = createSelector(selectConfig, (state) => {
    return state.settings?.enableKDAttributeFilterDatesValidation ?? true;
});
/**
 * Returns whether attribute filter displays duplicated values when filter uses secondary label value.
 *
 * @internal
 */
export const selectEnableImmediateAttributeFilterDisplayAsLabelMigration = createSelector(selectConfig, (state) => {
    return state.settings?.enableImmediateAttributeFilterDisplayAsLabelMigration ?? false;
});
/**
 * Returns whether arbitrary text filter mode is enabled in dashboards.
 *
 * @alpha
 */
export const selectEnableArbitraryFilterKD = createSelector(selectConfig, (state) => {
    return state.settings?.enableArbitraryFilterKD ?? true;
});
/**
 * Returns whether match text filter mode is enabled in dashboards.
 *
 * @alpha
 */
export const selectEnableMatchFilterKD = createSelector(selectConfig, (state) => {
    return state.settings?.enableMatchFilterKD ?? true;
});
/**
 * Returns whether measure value (numeric) filter is enabled in dashboards.
 *
 * @alpha
 */
export const selectEnableMeasureValueFilterKD = createSelector(selectConfig, (state) => {
    return state.settings?.enableMeasureValueFilterKD ?? false;
});
/**
 * Returns available attribute filter modes based on feature flags.
 *
 * @remarks
 * Always includes "elements" mode. Adds "arbitrary" and/or "match" when
 * the corresponding feature flags are enabled.
 *
 * @alpha
 */
export const selectAvailableAttributeFilterSelectionTypes = createSelector(selectEnableArbitraryFilterKD, selectEnableMatchFilterKD, (arbitraryEnabled, matchEnabled) => {
    const modes = ["elements"];
    if (arbitraryEnabled) {
        modes.push("arbitrary");
    }
    if (matchEnabled) {
        modes.push("match");
    }
    return modes;
});
/**
 * Returns whether rich text in descriptions is enabled.
 *
 * @internal
 */
export const selectEnableRichTextDescriptions = createSelector(selectConfig, (state) => {
    return state.settings?.enableRichTextDescriptions ?? false;
});
/**
 * Returns whether filter views are enabled.
 *
 * @internal
 */
export const selectEnableFilterViews = createSelector(selectConfig, (state) => {
    return state.settings?.enableDashboardFilterViews ?? true;
});
/**
 * Returns whether customized dashboards without plugin overlay are enabled.
 * When enabled, the plugin overlay will not be displayed on dashboard items.
 *
 * @internal
 */
export const selectEnableCustomizedDashboardsWithoutPluginOverlay = createSelector(selectConfig, (state) => {
    return state.settings?.enableCustomizedDashboardsWithoutPluginOverlay ?? true;
});
/**
 * Returns whether filter views are enabled.
 *
 * @internal
 */
export const selectEnableAlertsEvaluationFrequencySetup = createSelector(selectConfig, (state) => {
    return state.settings?.enableAlertsEvaluationFrequencySetup ?? true;
});
/**
 * Returns whether rich text widgets are enabled.
 *
 * @internal
 */
export const selectEnableVisualizationSwitcher = createSelector(selectConfig, (state) => {
    return state.settings?.enableKDVisualizationSwitcher ?? true;
});
/**
 * Returns whether ignore cross-filtering enabled.
 *
 * @internal
 */
export const selectEnableIgnoreCrossFiltering = createSelector(selectConfig, (state) => {
    return state.settings?.enableIgnoreCrossFiltering ?? true;
});
/**
 * Returns whether cross filtering should use alias titles.
 *
 * @internal
 */
export const selectEnableCrossFilteringAliasTitles = createSelector(selectConfig, (state) => {
    return state.settings?.enableCrossFilteringAliasTitles ?? false;
});
/**
 * Returns whether in-platform notifications are enabled.
 *
 * @internal
 */
export const selectEnableInPlatformNotifications = createSelector(selectConfig, (state) => {
    return state.settings?.enableInPlatformNotifications ?? true;
});
/**
 * Returns dashboard focus object.
 *
 * @beta
 */
export const selectFocusObject = createSelector(selectConfig, (state) => {
    return state.focusObject ?? {};
});
/**
 * Returns whether open automation on load is enabled.
 *
 * @internal
 */
export const selectOpenAutomationOnLoad = createSelector(selectConfig, (state) => {
    return state.openAutomationOnLoad ?? false;
});
/**
 * Returns whether external recipients are enabled.
 *
 * @internal
 */
export const selectEnableExternalRecipients = createSelector(selectConfig, (state) => {
    return state.settings?.enableExternalRecipients ?? true;
});
/**
 * Returns whether anomaly detection alert is enabled.
 *
 * @internal
 */
export const selectEnableAnomalyDetectionAlert = createSelector(selectConfig, (state) => {
    return state.settings?.enableAnomalyDetectionAlert ?? false;
});
/**
 *
 *
 * @internal
 */
export const selectEnableDashboardTabularExport = createSelector(selectConfig, (state) => {
    return state.settings?.enableDashboardTabularExport ?? false;
});
/**
 *
 *
 * @internal
 */
export const selectEnableOrchestratedTabularExports = createSelector(selectConfig, (state) => {
    return state.settings?.enableOrchestratedTabularExports ?? false;
});
/**
 * Returns whether drill dialog tooltip is enabled.
 *
 * @internal
 */
export const selectEnableDrilledTooltip = createSelector(selectConfig, (state) => {
    return state.settings?.enableDrilledTooltip ?? true;
});
/**
 * Returns whether dynamic height of the dashboard section description fields in dashboard edit mode is enabled.
 *
 * @internal
 */
export const selectEnableDashboardDescriptionDynamicHeight = createSelector(selectConfig, (state) => {
    return state.settings?.enableDashboardDescriptionDynamicHeight ?? false;
});
/**
 * @internal
 */
export const selectEnableSlideshowExports = createSelector(selectConfig, (state) => {
    return (state.settings?.enableSlidesExport && state.settings?.enableSlideshowExports) ?? false;
});
/**
 * @internal
 */
export const selectEnableExportTemplateSelection = createSelector(selectConfig, (state) => {
    return state.settings?.enableExportTemplateSelection ?? false;
});
/**
 * @internal
 */
export const selectEnableRichTextDynamicReferences = createSelector(selectConfig, (state) => {
    return state.settings?.enableRichTextDynamicReferences ?? true;
});
/**
 * Returns whether rich text widget filter configuration is enabled.
 *
 * @alpha
 */
export const selectEnableRichTextWidgetFilterConfiguration = createSelector(selectConfig, (state) => {
    return state.settings?.enableRichTextWidgetFilterConfiguration ?? false;
});
/**
 * Returns whether dashboard-level date dataset configuration for section headers is enabled.
 *
 * @alpha
 */
export const selectEnableDashboardSectionHeadersDateDataSet = createSelector(selectConfig, (state) => {
    return state.settings?.enableDashboardSectionHeadersDateDataSet ?? false;
});
/**
 * Setting of dashboard filters apply mode. The value is resolved in the following order:
 * If set on workspace level, workspace setting is used.
 * If not set on workspace level, organization setting is used.
 * If none of them are set, INDIVIDIAL mode is default.
 * @alpha
 */
export const selectDashboardFiltersApplyMode = createSelector(selectConfig, (state) => {
    return state.settings?.dashboardFiltersApplyMode ?? { mode: "INDIVIDUAL" };
});
/**
 * Setting set to ALL_AT_ONCE
 * @internal
 */
export const selectIsApplyFiltersAllAtOnceEnabledAndSet = createSelector(selectDashboardFiltersApplyMode, (dashboardFiltersApplyMode) => {
    return dashboardFiltersApplyMode.mode === "ALL_AT_ONCE";
});
/**
 * @internal
 */
export const selectEnableExecutionCancelling = createSelector(selectConfig, (state) => {
    return state.settings?.enableExecutionCancelling ?? false;
});
/**
 * Selector for the dashboard share link feature flag
 *
 * @internal
 */
export const selectEnableDashboardShareLink = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableDashboardShareLink);
});
/**
 * Selector for the automation filter context feature flag
 *
 * @internal
 */
export const selectEnableAutomationFilterContext = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableAutomationFilterContext);
});
/**
 * Selector for the date filter local identifiers feature flag
 *
 * @internal
 */
export const selectEnableDateFilterIdentifiers = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableDateFilterIdentifiersRollout);
});
/**
 * Returns whether snapshot export accessibility is enabled.
 *
 * @internal
 */
export const selectEnableSnapshotExportAccessibility = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableSnapshotExportAccessibility);
});
/**
 * Selector for the widget export to PNG image feature flag
 *
 * @internal
 */
export const selectEnableWidgetExportPngImage = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableWidgetExportPngImage);
});
/**
 * Selector for the export to PDF tabular
 *
 * @internal
 */
export const selectEnableExportToPdfTabular = createSelector(selectConfig, (state) => {
    return state.settings?.enableNewPdfTabularExport ?? true;
});
/**
 * Selector for the export to document storage and send scheduled exports to notification channels feature flag
 *
 * @internal
 */
export const selectEnableExportToDocumentStorage = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableExportToDocumentStorage);
});
/**
 * Returns the external recipient from the dashboard config
 *
 * @internal
 */
export const selectExternalRecipient = createSelector(selectConfig, (state) => {
    return state.externalRecipient;
});
/**
 * Returns whether notification channel identifiers are enabled.
 *
 * @internal
 */
export const selectEnableNotificationChannelIdentifiers = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableNotificationChannelIdentifiers);
});
/**
 * Selector for the dashboard share link in the share dialog feature flag
 *
 * @internal
 */
export const selectEnableDashboardShareDialogLink = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableDashboardShareDialogLink);
});
/**
 * Selector for the new scheduled export feature flag
 *
 * @internal
 */
export const selectEnableNewScheduledExport = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableNewScheduledExport);
});
/**
 * Selector for the customizable CSV delimiter feature flag
 *
 * @internal
 */
export const selectEnableCustomizableCsvDelimiter = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableCustomizableCsvDelimiter);
});
/**
 * Selector for the centralized automation management feature flag
 *
 * @internal
 */
export const selectEnableAutomationManagement = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableAutomationManagement);
});
/**
 * Selector for the alert once per interval feature flag
 *
 * @internal
 */
export const selectEnableAlertOncePerInterval = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableAlertOncePerInterval);
});
/**
 * Selector for the automation evaluation mode feature flag
 *
 * @internal
 */
export const selectEnableAutomationEvaluationMode = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableAutomationEvaluationMode);
});
/**
 * Selector for the snapshot export feature flag
 *
 * @internal
 */
export const selectEnableSnapshotExport = createSelector(selectConfig, (state) => {
    return state.settings?.enableSnapshotExport ?? true;
});
/**
 * Selector for the accessible mode feature flag
 *
 * @internal
 */
export const selectEnableAccessibilityMode = createSelector(selectConfig, (state) => {
    return Boolean(state.settings?.enableAccessibilityMode);
});
/**
 * Returns whether implicit drill to url feature is enabled.
 *
 * @alpha
 */
export const selectEnableImplicitDrillToUrl = createSelector(selectConfig, (state) => {
    return state.settings?.enableImplicitDrillToUrl ?? true;
});
/**
 * Returns the timeout to use when polling for export results (in milliseconds).
 *
 * @alpha
 */
export const selectExportResultPollingTimeout = createSelector(selectConfig, (state) => {
    if (state.settings?.exportResultPollingTimeoutSeconds) {
        return state.settings.exportResultPollingTimeoutSeconds * 1000;
    }
    return undefined;
});
/**
 * Selects whether drill to URL is enabled by default.
 * Works with ENABLE_DRILL_TO_URL_BY_DEFAULT setting type.
 * Can be overridden by insight config.
 *
 * @alpha
 */
export const selectEnableDrillToUrlByDefault = createSelector(selectConfig, selectEnableImplicitDrillToUrl, (state, enableImplicitDrillToUrl) => {
    return enableImplicitDrillToUrl ? (state.settings?.enableDrillToUrlByDefault ?? false) : false;
});
/**
 * Returns whether fiscal calendars feature flag is enabled.
 *
 * @alpha
 */
export const selectEnableFiscalCalendars = createSelector(selectConfig, (state) => {
    return state.settings?.enableFiscalCalendars ?? true;
});
/**
 * Returns the active calendars configuration from workspace settings.
 * Controls which calendar types (standard/fiscal) are available.
 *
 * @alpha
 */
export const selectActiveCalendars = createSelector(selectConfig, selectEnableFiscalCalendars, (state, ffEnabled) => {
    const activeCalendars = state.settings?.activeCalendars;
    if (!ffEnabled) {
        return activeCalendars ? { ...activeCalendars, fiscal: false } : undefined;
    }
    if (!activeCalendars) {
        return undefined;
    }
    // If no calendar type is enabled, default to standard
    const hasAnyCalendarEnabled = Object.entries(activeCalendars).some(([_, value]) => value === true);
    if (!hasAnyCalendarEnabled) {
        return { ...activeCalendars, standard: true };
    }
    return activeCalendars;
});
/**
 * Returns whether dashboard filter group feature is enabled.
 *
 * @alpha
 */
export const selectEnableDashboardFilterGroups = createSelector(selectConfig, (state) => {
    return state.settings?.enableDashboardFilterGroups ?? false;
});
/**
 * Selector for enabling empty date values configuration in KPI Dashboards date filter.
 *
 * @alpha
 */
export const selectEnableKDEmptyDateValuesFilter = createSelector(selectConfig, (state) => {
    return state.settings?.enableKDEmptyDateValuesFilter ?? true;
});
/**
 * Returns whether visualization filtering by tags is enabled.
 *
 * @internal
 */
export const selectEnableVisualizationFilteringByTags = createSelector(selectConfig, (state) => {
    return state.settings?.enableVisualizationFilteringByTags ?? false;
});
/**
 * Returns whether the dashboard density setting is enabled.
 *
 * @internal
 */
export const selectEnableDashboardDensitySetting = createSelector(selectConfig, (state) => {
    return state.settings?.enableDashboardDensitySetting ?? false;
});
/**
 * Returns whether filter control in drilling configuration is enabled.
 *
 * @internal
 */
export const selectEnableFilterControlInDrillingConfiguration = createSelector(selectConfig, (state) => {
    return state.settings?.enableFilterControlInDrillingConfiguration ?? true;
});
//# sourceMappingURL=configSelectors.js.map