autoql-fe-utils 1.10.7 → 1.10.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +5 -1
- package/dist/index.d.ts +5 -1
- package/dist/index.global.js +238 -242
- package/dist/index.global.js.map +1 -1
- package/dist/index.js +240 -242
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +239 -242
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1268,6 +1268,10 @@ declare const formatTableParams: (params: any, columns: Column[]) => {
|
|
|
1268
1268
|
page: any;
|
|
1269
1269
|
};
|
|
1270
1270
|
declare const formatSortersForAPI: (params: any, columns: Column[]) => any;
|
|
1271
|
+
declare const extractOperatorFromValue: (value: any) => {
|
|
1272
|
+
operator: string;
|
|
1273
|
+
cleanValue: string;
|
|
1274
|
+
} | null;
|
|
1271
1275
|
declare const formatNumberFilterValue: (headerValue?: string) => {
|
|
1272
1276
|
value: string;
|
|
1273
1277
|
operator: string;
|
|
@@ -2835,4 +2839,4 @@ declare function color(): {
|
|
|
2835
2839
|
on(): any;
|
|
2836
2840
|
};
|
|
2837
2841
|
|
|
2838
|
-
export { AGG_TYPES, AXIS_TITLE_BORDER_PADDING_LEFT, AXIS_TITLE_BORDER_PADDING_TOP, AXIS_TITLE_PADDING_BOTTOM, AXIS_TITLE_PADDING_TOP, type AdditionalSelect, AggType, type AggTypeParams, AggTypes, type ApiFilter, type ApiSorter, type Authentication, type AutoQLJWT, type AvailableSelect, type AxiosResponse, BUTTON_PADDING, CHARTS_WITHOUT_AGGREGATED_DATA, CHARTS_WITHOUT_AXES, CHARTS_WITHOUT_LEGENDS, CHART_PADDING, CHART_TYPES, COLUMN_TYPES, COMPARE_TYPE, CONTINUOUS_TYPE, CUSTOM_TYPE, type Column, Column$1 as ColumnObj, type ColumnSelect, ColumnType, ColumnTypes, CustomColumnRowRangeTypes, CustomColumnTypes, CustomColumnValues, DATA_ALERT_CONDITION_TYPES, DATA_ALERT_ENABLED_STATUSES, DATA_ALERT_FREQUENCY_TYPE_OPTIONS, DATA_ALERT_OPERATORS, DATA_ALERT_STATUSES, DATE_ONLY_CHART_TYPES, DAYJS_PRECISION_FORMATS, DEFAULT_AGG_TYPE, DEFAULT_CHART_CONFIG, DEFAULT_COLUMN_NAME, DEFAULT_CSS_PREFIX, DEFAULT_DATA_PAGE_SIZE, DEFAULT_EVALUATION_FREQUENCY, DEFAULT_LEGEND_PADDING_BOTTOM, DEFAULT_LEGEND_PADDING_LEFT, DEFAULT_LEGEND_PADDING_RIGHT, DEFAULT_LEGEND_PADDING_TOP, DEFAULT_MAX_LEGEND_WIDTH, DEFAULT_SOURCE, DISABLED_CLASS, DISPLAY_TYPES, DOUBLE_AXIS_CHART_TYPES, DOW_STYLES, DataExplorerSubject, type DataExplorerSubjectFilter, type DataExplorerSubjectGroups, type DataExplorerSubjectInterface, type DataExplorerSuggestion, DataExplorerTypes, type DataFormatting, DateStringPrecisionTypes, DateUTC, type DisplayOverride, DisplayTypes, EVALUATION_FREQUENCY_OPTIONS, EXISTS_TYPE, FORMULA_CLASS, FUNCTION_OPERATORS, type FilterLock, type FrontendReq, GENERAL_ERROR, GENERAL_HTML_ERROR, GENERAL_QUERY_ERROR, GLOBAL_OPERATORS, GROUP_TERM_TYPE, GeneralErrorTypes, HIGHLIGHTED_CLASS, HORIZONTAL_LEGEND_SPACING, LABEL_FONT_SIZE, LEGEND_BORDER_PADDING, LEGEND_BORDER_THICKNESS, LEGEND_SHAPE_SIZE, LEGEND_TOP_ADJUSTMENT, LOAD_MORE_DROPDOWN_PADDING_BOTTOM, MAX_CHART_ELEMENTS, MAX_DATA_PAGE_SIZE, MAX_LEGEND_LABELS, MAX_RECENT_SEARCHES, MAX_ROWS_FOR_PIE_CHART, MINIMUM_INNER_HEIGHT, MINIMUM_INNER_WIDTH, MINIMUM_TITLE_LENGTH, MIN_HISTOGRAM_SAMPLE, MONTH_DAY_SELECT_OPTIONS, MONTH_NAMES, NUMBER_TERM_TYPE, OPERATORS, ORDERBY_DIRECTIONS, Operators, PATH_SMOOTHING, PERIODIC_TYPE, PROJECT_TYPE, type ParsedInterpretation, type ParsedInterpretationChunk, PrecisionTypes, QUERY_TERM_TYPE, QUERY_TIMEOUT_ERROR, type QueryData, QueryErrorTypes, type QueryResponse, REQUEST_CANCELLED_ERROR, RESET_PERIOD_OPTIONS, ROWS_RANGE, ROWS_RANGE_OPTIONS, type RawColumn, type Rows, SCHEDULED_TYPE, SCHEDULE_FREQUENCY_OPTIONS, SCHEDULE_INTERVAL_OPTIONS, SEASON_NAMES, SampleQueryReplacementTypes, type Scale, type SubjectSuggestion, TABLE_TYPES, TITLE_FONT_SIZE, type TableConfig, type TabulatorFilter, type TabulatorSorter, type Theme, ThemeType, type TransformedAxiosResponse, type TransformedQueryResponse, TranslationTypes, UNAUTHENTICATED_ERROR, VERTICAL_LEGEND_SPACING, type ValueLabel, type ValueLabelSuggestion, WEEKDAY_NAMES_MON, WEEKDAY_NAMES_SUN, WINDOW_FUNCTIONS, addSubjectToRecentSearches, addUserToProjectRule, adjustBottomTitleToFit, adjustMinAndMaxForScaleRatio, adjustTitleToFit, adjustTopTitleToFit, adjustVerticalTitleToFit, aggregateData, aggregateOtherCategory, animateInputText, applyLegendTitleStyles, applyPrecisionToDate, applyStylesForHiddenSeries, areAllColumnsHidden, areSomeColumnsHidden, assignLabelToManagementDataAlert, authenticationDefault, autoQLConfigDefault, bezierCommand, buildPlainColumnArrayFn, calculateMinAndMaxSums, capitalizeFirstChar, cloneObject, configureTheme, constructFilter, constructRTArray, convertToFunctionStr, convertToNumber, countDecimals, createDataAlert, createFilterFunction, createManagementDataAlert, createMutatorFn, createNotificationChannel, createSVGPath, currentEventLoopEnd, dataConfigDefault, dataFormattingDefault, dataStructureChanged, dateSortFn, dateStringSortFn, deepEqual, deleteAllNotifications, deleteDataAlert, deleteMultipleNotifications, deleteNotification, difference, dismissAllNotifications, dismissNotification, distributeListsEvenly, doesElementOverflowContainer, exportCSV, fetchAutocomplete, fetchDataAlerts, fetchDataExplorerAutocomplete, fetchDataExplorerSampleQueries, fetchDataExplorerSuggestions, fetchDataPreview, fetchExploreQueries, fetchFilters, fetchNotification, fetchNotificationChannels, fetchNotificationCount, fetchNotificationData, fetchNotificationFeed, fetchRule, fetchSubjectList, fetchSubjectListV2, fetchSubscribedDataAlerts, fetchSuggestions, fetchTopics, fetchTopicsForVL, fetchVLAutocomplete, filterDataByColumn, findNetworkColumns, formatAdditionalSelectColumn, formatChartLabel, formatDatePivotMonth, formatDatePivotYear, formatDateStringType, formatDateType, formatElement, formatEpochDate, formatFiltersForAPI, formatFiltersForTabulator, formatISODateWithPrecision, formatNextScheduleDate, formatNumberFilterValue, formatQueryColumns, formatResetDate, formatSortersForAPI, formatSortersForTabulator, formatStringDate, formatStringDateWithPrecision, formatTableParams, functionsEqual, generateDatePivotData, generateFilterDrilldownResponse, generatePivotData, generatePivotTableData, getAggConfig, getAllDataAlertsLabels, getAllDataAlertsLabelsByProject, getAuthentication, getAutoQLConfig, getAxis, getAxisLabelsBbox, getBBoxFromRef, getBandScale, getBarRectObj, getBinData, getBinLinearScale, getBubbleObj, getChartColorVars, getChartScaleRatio, getCleanColumnName, getColorScale, getColorScales, getColumnDateRanges, getColumnFieldCompat, getColumnIdentifierCompat, getColumnIndexCompat, getColumnIndexConfig, getColumnNameForDateRange, getColumnOriginalIndexCompat, getColumnPositionCompat, getColumnRectObj, getColumnTypeAmounts, getCombinedFilters, getCurrencySymbol, getCurrentTimezone, getDashboardRefreshInterval, getDataAlertsByLabel, getDataConfig, getDataFormatting, getDateColumnIndex, getDateColumns, getDateNoQuotes, getDateRangeIntersection, getDateRangesFromInterpretation, getDatesFromRT, getDayJSObj, getDayLocalStartDate, getDayOfTheMonthFromTimestamp, getDayOfTheMonthSuffix, getDayjsObjForStringType, getDefaultBucketConfig, getDefaultDisplayType, getDefaultJoinColumnAndDisplayNameAndJoinColumnsIndices, getDefaultJoinColumns, getDrilldownData, getDrilldownGroupby, getEpochFromDate, getFilterDrilldown, getFilterPrecision, getFirstChartDisplayType, getFnSummary, getFormattedTimestamp, getGroupBys, getGroupBysFromPivotTable, getGroupBysFromTable, getGroupableColumns, getHeatmapRectObj, getHiddenColumns, getHistogramColumnObj, getHistogramScale, getInitialBucketSize, getInitialSelections, getKey, getKeyByValue, getLabelsBBox, getLegendLabels, getLegendLabelsForGroupbyQuery, getLegendLabelsForMultiSeries, getLegendLabelsForSingleColumn, getLegendLocation, getLegendScale, getLegendTitleFromColumns, getLineVertexObj, getLinearAxisTitle, getLinearScale, getLinearScales, getMaxLegendHeight, getMaxLegendSectionWidth, getMaxTickLabelWidth, getMaxValueFromKeyValueObj, getMinAndMaxValues, getMinValueFromKeyValueObj, getMonthLocalStartDate, getMultiSeriesColumnIndex, getNiceDateTickValues, getNiceTickValues, getNotLabeledDataAlerts, getNumberAxisUnits, getNumberColumnIndices, getNumberFormatConfig, getNumberOfGroupables, getNumberOfSeries, getNumericalColumns, getObjSize, getOpacityScale, getOperators, getPadding, getPieChartData, getPivotColumnIndexConfig, getPlainTextList, getPointObj, getPotentialDisplayTypes, getPrecisionForDayJS, getQueryFn, getQueryParams, getQueryRequestParams, getQuerySelectableJoinColumns, getQueryValidationQueryText, getRadiusScale, getRangeForAxis, getRecentSearchesFromLocalStorage, getRecentSelectionID, getRowNumberListForPopover, getSVGBase64, getSampleQueryRegex, getSampleQueryText, getScheduleFrequencyObject, getSelectableColumns, getSortColumnIndex, getSortDirection, getStartAndEndDateFromDateStrs, getStringColumnIndices, getStringColumns, getStringFromSource, getSuggestionLists, getSupportedConditionTypes, getSupportedDisplayTypes, getThemeType, getThemeValue, getTickSizeFromNumTicks, getTickValues, getTimeFrameTextFromChunk, getTimeObjFromTimeStamp, getTimeRangeFromDateArray, getTimeRangeFromRT, getTimeScale, getTitleCase, getTodaysDayOfTheMonth, getTooltipContent, getTotalBottomPadding, getTotalHorizontalPadding, getTotalLeftPadding, getTotalPossibleLegendSections, getTotalRightPadding, getTotalTopPadding, getTotalVerticalPadding, getUniqueYearsForColumn, getUnitSymbol, getUnitsForColumn, getVisibleColumns, getWeekLocalStartDate, getWeekdayFromTimeStamp, getlegendLabelSections, handleTooltipBoundaryCollision, hasColumnIndex, hasData, hasDateColumn, hasMoreData, hasNumberColumn, hasStringColumn, initializeAlert, initializeQueryValidationOptions, isAggSeed, isAggregation, isChartType, isColumnDateType, isColumnIndexConfigValid, isColumnIndexValid, isColumnIndicesValid, isColumnNumberType, isColumnStringType, isColumnSummable, isDataLimited, isDisplayTypeValid, isDrilldown, isError500Type, isExpressionQueryValid, isISODate, isInitialSelectionValid, isListQuery, isNumber, isObject, isOperatorJs, isSelectableNumberColumn, isSelectableStringColumn, isSingleValueResponse, isTableType, isTabulatorColumnComponent, isValueEmpty, color as legendColor, lineCommand, makeEmptyArray, markNotificationAsUnread, mergeBboxes, mergeBoundingClientRects, mergeSources, nameValueObject, normalizeString, numberIndicesArraysOverlap, numberSortFn, onTableCellClick, onlySeriesVisibilityChanged, onlyUnique, parseJwt, parseList, potentiallySupportsDatePivot, potentiallySupportsPivot, previewDataAlert, previewManagementDataAlert, removeDashboardRefreshInterval, removeElementAtIndex, removeFromDOM, removeHiddenLegendLabels, removeNotificationChannel, removeUserFromProjectRule, reportProblem, resetDateIsFuture, resetNotificationCount, rotateArray, roundDownToNearestMultiple, roundToNearestLog10, roundToNearestMultiple, roundUpToNearestMultiple, runCachedDashboardQuery, runDrilldown, runQuery, runQueryNewPage, runQueryOnly, runQueryValidation, scaleZero, sendDataToChannel, sendSuggestion, sendTrainingData, setCaretPosition, setColumnVisibility, setDashboardRefreshInterval, setFilters, setHeaderFilterPlaceholder, setRecentSearchesInLocalStorage, setSorterFunction, setTickSize, setTickValues, shouldDisableChartScale, shouldLabelsRotate, shouldPlotMultiSeries, showEvaluationFrequencySetting, sortDataByAlphabet, sortDataByColumn, sortDataByDate, supportsDatePivotTable, supportsNetworkGraph, supportsPieChart, supportsRegularPivotTable, svgPathD, svgToPng, type tableFilterParams, titlelizeString, toggleCustomDataAlertStatus, toggleProjectDataAlertStatus, transformLabels, transformQueryResponse, transformQueryResponseColumns, unsetFilterFromAPI, updateDataAlert, updateDataAlertStatus, updateManagementDataAlert, updateStartAndEndIndexes, usePivotDataForChart, uuidv4, validateExpression };
|
|
2842
|
+
export { AGG_TYPES, AXIS_TITLE_BORDER_PADDING_LEFT, AXIS_TITLE_BORDER_PADDING_TOP, AXIS_TITLE_PADDING_BOTTOM, AXIS_TITLE_PADDING_TOP, type AdditionalSelect, AggType, type AggTypeParams, AggTypes, type ApiFilter, type ApiSorter, type Authentication, type AutoQLJWT, type AvailableSelect, type AxiosResponse, BUTTON_PADDING, CHARTS_WITHOUT_AGGREGATED_DATA, CHARTS_WITHOUT_AXES, CHARTS_WITHOUT_LEGENDS, CHART_PADDING, CHART_TYPES, COLUMN_TYPES, COMPARE_TYPE, CONTINUOUS_TYPE, CUSTOM_TYPE, type Column, Column$1 as ColumnObj, type ColumnSelect, ColumnType, ColumnTypes, CustomColumnRowRangeTypes, CustomColumnTypes, CustomColumnValues, DATA_ALERT_CONDITION_TYPES, DATA_ALERT_ENABLED_STATUSES, DATA_ALERT_FREQUENCY_TYPE_OPTIONS, DATA_ALERT_OPERATORS, DATA_ALERT_STATUSES, DATE_ONLY_CHART_TYPES, DAYJS_PRECISION_FORMATS, DEFAULT_AGG_TYPE, DEFAULT_CHART_CONFIG, DEFAULT_COLUMN_NAME, DEFAULT_CSS_PREFIX, DEFAULT_DATA_PAGE_SIZE, DEFAULT_EVALUATION_FREQUENCY, DEFAULT_LEGEND_PADDING_BOTTOM, DEFAULT_LEGEND_PADDING_LEFT, DEFAULT_LEGEND_PADDING_RIGHT, DEFAULT_LEGEND_PADDING_TOP, DEFAULT_MAX_LEGEND_WIDTH, DEFAULT_SOURCE, DISABLED_CLASS, DISPLAY_TYPES, DOUBLE_AXIS_CHART_TYPES, DOW_STYLES, DataExplorerSubject, type DataExplorerSubjectFilter, type DataExplorerSubjectGroups, type DataExplorerSubjectInterface, type DataExplorerSuggestion, DataExplorerTypes, type DataFormatting, DateStringPrecisionTypes, DateUTC, type DisplayOverride, DisplayTypes, EVALUATION_FREQUENCY_OPTIONS, EXISTS_TYPE, FORMULA_CLASS, FUNCTION_OPERATORS, type FilterLock, type FrontendReq, GENERAL_ERROR, GENERAL_HTML_ERROR, GENERAL_QUERY_ERROR, GLOBAL_OPERATORS, GROUP_TERM_TYPE, GeneralErrorTypes, HIGHLIGHTED_CLASS, HORIZONTAL_LEGEND_SPACING, LABEL_FONT_SIZE, LEGEND_BORDER_PADDING, LEGEND_BORDER_THICKNESS, LEGEND_SHAPE_SIZE, LEGEND_TOP_ADJUSTMENT, LOAD_MORE_DROPDOWN_PADDING_BOTTOM, MAX_CHART_ELEMENTS, MAX_DATA_PAGE_SIZE, MAX_LEGEND_LABELS, MAX_RECENT_SEARCHES, MAX_ROWS_FOR_PIE_CHART, MINIMUM_INNER_HEIGHT, MINIMUM_INNER_WIDTH, MINIMUM_TITLE_LENGTH, MIN_HISTOGRAM_SAMPLE, MONTH_DAY_SELECT_OPTIONS, MONTH_NAMES, NUMBER_TERM_TYPE, OPERATORS, ORDERBY_DIRECTIONS, Operators, PATH_SMOOTHING, PERIODIC_TYPE, PROJECT_TYPE, type ParsedInterpretation, type ParsedInterpretationChunk, PrecisionTypes, QUERY_TERM_TYPE, QUERY_TIMEOUT_ERROR, type QueryData, QueryErrorTypes, type QueryResponse, REQUEST_CANCELLED_ERROR, RESET_PERIOD_OPTIONS, ROWS_RANGE, ROWS_RANGE_OPTIONS, type RawColumn, type Rows, SCHEDULED_TYPE, SCHEDULE_FREQUENCY_OPTIONS, SCHEDULE_INTERVAL_OPTIONS, SEASON_NAMES, SampleQueryReplacementTypes, type Scale, type SubjectSuggestion, TABLE_TYPES, TITLE_FONT_SIZE, type TableConfig, type TabulatorFilter, type TabulatorSorter, type Theme, ThemeType, type TransformedAxiosResponse, type TransformedQueryResponse, TranslationTypes, UNAUTHENTICATED_ERROR, VERTICAL_LEGEND_SPACING, type ValueLabel, type ValueLabelSuggestion, WEEKDAY_NAMES_MON, WEEKDAY_NAMES_SUN, WINDOW_FUNCTIONS, addSubjectToRecentSearches, addUserToProjectRule, adjustBottomTitleToFit, adjustMinAndMaxForScaleRatio, adjustTitleToFit, adjustTopTitleToFit, adjustVerticalTitleToFit, aggregateData, aggregateOtherCategory, animateInputText, applyLegendTitleStyles, applyPrecisionToDate, applyStylesForHiddenSeries, areAllColumnsHidden, areSomeColumnsHidden, assignLabelToManagementDataAlert, authenticationDefault, autoQLConfigDefault, bezierCommand, buildPlainColumnArrayFn, calculateMinAndMaxSums, capitalizeFirstChar, cloneObject, configureTheme, constructFilter, constructRTArray, convertToFunctionStr, convertToNumber, countDecimals, createDataAlert, createFilterFunction, createManagementDataAlert, createMutatorFn, createNotificationChannel, createSVGPath, currentEventLoopEnd, dataConfigDefault, dataFormattingDefault, dataStructureChanged, dateSortFn, dateStringSortFn, deepEqual, deleteAllNotifications, deleteDataAlert, deleteMultipleNotifications, deleteNotification, difference, dismissAllNotifications, dismissNotification, distributeListsEvenly, doesElementOverflowContainer, exportCSV, extractOperatorFromValue, fetchAutocomplete, fetchDataAlerts, fetchDataExplorerAutocomplete, fetchDataExplorerSampleQueries, fetchDataExplorerSuggestions, fetchDataPreview, fetchExploreQueries, fetchFilters, fetchNotification, fetchNotificationChannels, fetchNotificationCount, fetchNotificationData, fetchNotificationFeed, fetchRule, fetchSubjectList, fetchSubjectListV2, fetchSubscribedDataAlerts, fetchSuggestions, fetchTopics, fetchTopicsForVL, fetchVLAutocomplete, filterDataByColumn, findNetworkColumns, formatAdditionalSelectColumn, formatChartLabel, formatDatePivotMonth, formatDatePivotYear, formatDateStringType, formatDateType, formatElement, formatEpochDate, formatFiltersForAPI, formatFiltersForTabulator, formatISODateWithPrecision, formatNextScheduleDate, formatNumberFilterValue, formatQueryColumns, formatResetDate, formatSortersForAPI, formatSortersForTabulator, formatStringDate, formatStringDateWithPrecision, formatTableParams, functionsEqual, generateDatePivotData, generateFilterDrilldownResponse, generatePivotData, generatePivotTableData, getAggConfig, getAllDataAlertsLabels, getAllDataAlertsLabelsByProject, getAuthentication, getAutoQLConfig, getAxis, getAxisLabelsBbox, getBBoxFromRef, getBandScale, getBarRectObj, getBinData, getBinLinearScale, getBubbleObj, getChartColorVars, getChartScaleRatio, getCleanColumnName, getColorScale, getColorScales, getColumnDateRanges, getColumnFieldCompat, getColumnIdentifierCompat, getColumnIndexCompat, getColumnIndexConfig, getColumnNameForDateRange, getColumnOriginalIndexCompat, getColumnPositionCompat, getColumnRectObj, getColumnTypeAmounts, getCombinedFilters, getCurrencySymbol, getCurrentTimezone, getDashboardRefreshInterval, getDataAlertsByLabel, getDataConfig, getDataFormatting, getDateColumnIndex, getDateColumns, getDateNoQuotes, getDateRangeIntersection, getDateRangesFromInterpretation, getDatesFromRT, getDayJSObj, getDayLocalStartDate, getDayOfTheMonthFromTimestamp, getDayOfTheMonthSuffix, getDayjsObjForStringType, getDefaultBucketConfig, getDefaultDisplayType, getDefaultJoinColumnAndDisplayNameAndJoinColumnsIndices, getDefaultJoinColumns, getDrilldownData, getDrilldownGroupby, getEpochFromDate, getFilterDrilldown, getFilterPrecision, getFirstChartDisplayType, getFnSummary, getFormattedTimestamp, getGroupBys, getGroupBysFromPivotTable, getGroupBysFromTable, getGroupableColumns, getHeatmapRectObj, getHiddenColumns, getHistogramColumnObj, getHistogramScale, getInitialBucketSize, getInitialSelections, getKey, getKeyByValue, getLabelsBBox, getLegendLabels, getLegendLabelsForGroupbyQuery, getLegendLabelsForMultiSeries, getLegendLabelsForSingleColumn, getLegendLocation, getLegendScale, getLegendTitleFromColumns, getLineVertexObj, getLinearAxisTitle, getLinearScale, getLinearScales, getMaxLegendHeight, getMaxLegendSectionWidth, getMaxTickLabelWidth, getMaxValueFromKeyValueObj, getMinAndMaxValues, getMinValueFromKeyValueObj, getMonthLocalStartDate, getMultiSeriesColumnIndex, getNiceDateTickValues, getNiceTickValues, getNotLabeledDataAlerts, getNumberAxisUnits, getNumberColumnIndices, getNumberFormatConfig, getNumberOfGroupables, getNumberOfSeries, getNumericalColumns, getObjSize, getOpacityScale, getOperators, getPadding, getPieChartData, getPivotColumnIndexConfig, getPlainTextList, getPointObj, getPotentialDisplayTypes, getPrecisionForDayJS, getQueryFn, getQueryParams, getQueryRequestParams, getQuerySelectableJoinColumns, getQueryValidationQueryText, getRadiusScale, getRangeForAxis, getRecentSearchesFromLocalStorage, getRecentSelectionID, getRowNumberListForPopover, getSVGBase64, getSampleQueryRegex, getSampleQueryText, getScheduleFrequencyObject, getSelectableColumns, getSortColumnIndex, getSortDirection, getStartAndEndDateFromDateStrs, getStringColumnIndices, getStringColumns, getStringFromSource, getSuggestionLists, getSupportedConditionTypes, getSupportedDisplayTypes, getThemeType, getThemeValue, getTickSizeFromNumTicks, getTickValues, getTimeFrameTextFromChunk, getTimeObjFromTimeStamp, getTimeRangeFromDateArray, getTimeRangeFromRT, getTimeScale, getTitleCase, getTodaysDayOfTheMonth, getTooltipContent, getTotalBottomPadding, getTotalHorizontalPadding, getTotalLeftPadding, getTotalPossibleLegendSections, getTotalRightPadding, getTotalTopPadding, getTotalVerticalPadding, getUniqueYearsForColumn, getUnitSymbol, getUnitsForColumn, getVisibleColumns, getWeekLocalStartDate, getWeekdayFromTimeStamp, getlegendLabelSections, handleTooltipBoundaryCollision, hasColumnIndex, hasData, hasDateColumn, hasMoreData, hasNumberColumn, hasStringColumn, initializeAlert, initializeQueryValidationOptions, isAggSeed, isAggregation, isChartType, isColumnDateType, isColumnIndexConfigValid, isColumnIndexValid, isColumnIndicesValid, isColumnNumberType, isColumnStringType, isColumnSummable, isDataLimited, isDisplayTypeValid, isDrilldown, isError500Type, isExpressionQueryValid, isISODate, isInitialSelectionValid, isListQuery, isNumber, isObject, isOperatorJs, isSelectableNumberColumn, isSelectableStringColumn, isSingleValueResponse, isTableType, isTabulatorColumnComponent, isValueEmpty, color as legendColor, lineCommand, makeEmptyArray, markNotificationAsUnread, mergeBboxes, mergeBoundingClientRects, mergeSources, nameValueObject, normalizeString, numberIndicesArraysOverlap, numberSortFn, onTableCellClick, onlySeriesVisibilityChanged, onlyUnique, parseJwt, parseList, potentiallySupportsDatePivot, potentiallySupportsPivot, previewDataAlert, previewManagementDataAlert, removeDashboardRefreshInterval, removeElementAtIndex, removeFromDOM, removeHiddenLegendLabels, removeNotificationChannel, removeUserFromProjectRule, reportProblem, resetDateIsFuture, resetNotificationCount, rotateArray, roundDownToNearestMultiple, roundToNearestLog10, roundToNearestMultiple, roundUpToNearestMultiple, runCachedDashboardQuery, runDrilldown, runQuery, runQueryNewPage, runQueryOnly, runQueryValidation, scaleZero, sendDataToChannel, sendSuggestion, sendTrainingData, setCaretPosition, setColumnVisibility, setDashboardRefreshInterval, setFilters, setHeaderFilterPlaceholder, setRecentSearchesInLocalStorage, setSorterFunction, setTickSize, setTickValues, shouldDisableChartScale, shouldLabelsRotate, shouldPlotMultiSeries, showEvaluationFrequencySetting, sortDataByAlphabet, sortDataByColumn, sortDataByDate, supportsDatePivotTable, supportsNetworkGraph, supportsPieChart, supportsRegularPivotTable, svgPathD, svgToPng, type tableFilterParams, titlelizeString, toggleCustomDataAlertStatus, toggleProjectDataAlertStatus, transformLabels, transformQueryResponse, transformQueryResponseColumns, unsetFilterFromAPI, updateDataAlert, updateDataAlertStatus, updateManagementDataAlert, updateStartAndEndIndexes, usePivotDataForChart, uuidv4, validateExpression };
|
package/dist/index.d.ts
CHANGED
|
@@ -1268,6 +1268,10 @@ declare const formatTableParams: (params: any, columns: Column[]) => {
|
|
|
1268
1268
|
page: any;
|
|
1269
1269
|
};
|
|
1270
1270
|
declare const formatSortersForAPI: (params: any, columns: Column[]) => any;
|
|
1271
|
+
declare const extractOperatorFromValue: (value: any) => {
|
|
1272
|
+
operator: string;
|
|
1273
|
+
cleanValue: string;
|
|
1274
|
+
} | null;
|
|
1271
1275
|
declare const formatNumberFilterValue: (headerValue?: string) => {
|
|
1272
1276
|
value: string;
|
|
1273
1277
|
operator: string;
|
|
@@ -2835,4 +2839,4 @@ declare function color(): {
|
|
|
2835
2839
|
on(): any;
|
|
2836
2840
|
};
|
|
2837
2841
|
|
|
2838
|
-
export { AGG_TYPES, AXIS_TITLE_BORDER_PADDING_LEFT, AXIS_TITLE_BORDER_PADDING_TOP, AXIS_TITLE_PADDING_BOTTOM, AXIS_TITLE_PADDING_TOP, type AdditionalSelect, AggType, type AggTypeParams, AggTypes, type ApiFilter, type ApiSorter, type Authentication, type AutoQLJWT, type AvailableSelect, type AxiosResponse, BUTTON_PADDING, CHARTS_WITHOUT_AGGREGATED_DATA, CHARTS_WITHOUT_AXES, CHARTS_WITHOUT_LEGENDS, CHART_PADDING, CHART_TYPES, COLUMN_TYPES, COMPARE_TYPE, CONTINUOUS_TYPE, CUSTOM_TYPE, type Column, Column$1 as ColumnObj, type ColumnSelect, ColumnType, ColumnTypes, CustomColumnRowRangeTypes, CustomColumnTypes, CustomColumnValues, DATA_ALERT_CONDITION_TYPES, DATA_ALERT_ENABLED_STATUSES, DATA_ALERT_FREQUENCY_TYPE_OPTIONS, DATA_ALERT_OPERATORS, DATA_ALERT_STATUSES, DATE_ONLY_CHART_TYPES, DAYJS_PRECISION_FORMATS, DEFAULT_AGG_TYPE, DEFAULT_CHART_CONFIG, DEFAULT_COLUMN_NAME, DEFAULT_CSS_PREFIX, DEFAULT_DATA_PAGE_SIZE, DEFAULT_EVALUATION_FREQUENCY, DEFAULT_LEGEND_PADDING_BOTTOM, DEFAULT_LEGEND_PADDING_LEFT, DEFAULT_LEGEND_PADDING_RIGHT, DEFAULT_LEGEND_PADDING_TOP, DEFAULT_MAX_LEGEND_WIDTH, DEFAULT_SOURCE, DISABLED_CLASS, DISPLAY_TYPES, DOUBLE_AXIS_CHART_TYPES, DOW_STYLES, DataExplorerSubject, type DataExplorerSubjectFilter, type DataExplorerSubjectGroups, type DataExplorerSubjectInterface, type DataExplorerSuggestion, DataExplorerTypes, type DataFormatting, DateStringPrecisionTypes, DateUTC, type DisplayOverride, DisplayTypes, EVALUATION_FREQUENCY_OPTIONS, EXISTS_TYPE, FORMULA_CLASS, FUNCTION_OPERATORS, type FilterLock, type FrontendReq, GENERAL_ERROR, GENERAL_HTML_ERROR, GENERAL_QUERY_ERROR, GLOBAL_OPERATORS, GROUP_TERM_TYPE, GeneralErrorTypes, HIGHLIGHTED_CLASS, HORIZONTAL_LEGEND_SPACING, LABEL_FONT_SIZE, LEGEND_BORDER_PADDING, LEGEND_BORDER_THICKNESS, LEGEND_SHAPE_SIZE, LEGEND_TOP_ADJUSTMENT, LOAD_MORE_DROPDOWN_PADDING_BOTTOM, MAX_CHART_ELEMENTS, MAX_DATA_PAGE_SIZE, MAX_LEGEND_LABELS, MAX_RECENT_SEARCHES, MAX_ROWS_FOR_PIE_CHART, MINIMUM_INNER_HEIGHT, MINIMUM_INNER_WIDTH, MINIMUM_TITLE_LENGTH, MIN_HISTOGRAM_SAMPLE, MONTH_DAY_SELECT_OPTIONS, MONTH_NAMES, NUMBER_TERM_TYPE, OPERATORS, ORDERBY_DIRECTIONS, Operators, PATH_SMOOTHING, PERIODIC_TYPE, PROJECT_TYPE, type ParsedInterpretation, type ParsedInterpretationChunk, PrecisionTypes, QUERY_TERM_TYPE, QUERY_TIMEOUT_ERROR, type QueryData, QueryErrorTypes, type QueryResponse, REQUEST_CANCELLED_ERROR, RESET_PERIOD_OPTIONS, ROWS_RANGE, ROWS_RANGE_OPTIONS, type RawColumn, type Rows, SCHEDULED_TYPE, SCHEDULE_FREQUENCY_OPTIONS, SCHEDULE_INTERVAL_OPTIONS, SEASON_NAMES, SampleQueryReplacementTypes, type Scale, type SubjectSuggestion, TABLE_TYPES, TITLE_FONT_SIZE, type TableConfig, type TabulatorFilter, type TabulatorSorter, type Theme, ThemeType, type TransformedAxiosResponse, type TransformedQueryResponse, TranslationTypes, UNAUTHENTICATED_ERROR, VERTICAL_LEGEND_SPACING, type ValueLabel, type ValueLabelSuggestion, WEEKDAY_NAMES_MON, WEEKDAY_NAMES_SUN, WINDOW_FUNCTIONS, addSubjectToRecentSearches, addUserToProjectRule, adjustBottomTitleToFit, adjustMinAndMaxForScaleRatio, adjustTitleToFit, adjustTopTitleToFit, adjustVerticalTitleToFit, aggregateData, aggregateOtherCategory, animateInputText, applyLegendTitleStyles, applyPrecisionToDate, applyStylesForHiddenSeries, areAllColumnsHidden, areSomeColumnsHidden, assignLabelToManagementDataAlert, authenticationDefault, autoQLConfigDefault, bezierCommand, buildPlainColumnArrayFn, calculateMinAndMaxSums, capitalizeFirstChar, cloneObject, configureTheme, constructFilter, constructRTArray, convertToFunctionStr, convertToNumber, countDecimals, createDataAlert, createFilterFunction, createManagementDataAlert, createMutatorFn, createNotificationChannel, createSVGPath, currentEventLoopEnd, dataConfigDefault, dataFormattingDefault, dataStructureChanged, dateSortFn, dateStringSortFn, deepEqual, deleteAllNotifications, deleteDataAlert, deleteMultipleNotifications, deleteNotification, difference, dismissAllNotifications, dismissNotification, distributeListsEvenly, doesElementOverflowContainer, exportCSV, fetchAutocomplete, fetchDataAlerts, fetchDataExplorerAutocomplete, fetchDataExplorerSampleQueries, fetchDataExplorerSuggestions, fetchDataPreview, fetchExploreQueries, fetchFilters, fetchNotification, fetchNotificationChannels, fetchNotificationCount, fetchNotificationData, fetchNotificationFeed, fetchRule, fetchSubjectList, fetchSubjectListV2, fetchSubscribedDataAlerts, fetchSuggestions, fetchTopics, fetchTopicsForVL, fetchVLAutocomplete, filterDataByColumn, findNetworkColumns, formatAdditionalSelectColumn, formatChartLabel, formatDatePivotMonth, formatDatePivotYear, formatDateStringType, formatDateType, formatElement, formatEpochDate, formatFiltersForAPI, formatFiltersForTabulator, formatISODateWithPrecision, formatNextScheduleDate, formatNumberFilterValue, formatQueryColumns, formatResetDate, formatSortersForAPI, formatSortersForTabulator, formatStringDate, formatStringDateWithPrecision, formatTableParams, functionsEqual, generateDatePivotData, generateFilterDrilldownResponse, generatePivotData, generatePivotTableData, getAggConfig, getAllDataAlertsLabels, getAllDataAlertsLabelsByProject, getAuthentication, getAutoQLConfig, getAxis, getAxisLabelsBbox, getBBoxFromRef, getBandScale, getBarRectObj, getBinData, getBinLinearScale, getBubbleObj, getChartColorVars, getChartScaleRatio, getCleanColumnName, getColorScale, getColorScales, getColumnDateRanges, getColumnFieldCompat, getColumnIdentifierCompat, getColumnIndexCompat, getColumnIndexConfig, getColumnNameForDateRange, getColumnOriginalIndexCompat, getColumnPositionCompat, getColumnRectObj, getColumnTypeAmounts, getCombinedFilters, getCurrencySymbol, getCurrentTimezone, getDashboardRefreshInterval, getDataAlertsByLabel, getDataConfig, getDataFormatting, getDateColumnIndex, getDateColumns, getDateNoQuotes, getDateRangeIntersection, getDateRangesFromInterpretation, getDatesFromRT, getDayJSObj, getDayLocalStartDate, getDayOfTheMonthFromTimestamp, getDayOfTheMonthSuffix, getDayjsObjForStringType, getDefaultBucketConfig, getDefaultDisplayType, getDefaultJoinColumnAndDisplayNameAndJoinColumnsIndices, getDefaultJoinColumns, getDrilldownData, getDrilldownGroupby, getEpochFromDate, getFilterDrilldown, getFilterPrecision, getFirstChartDisplayType, getFnSummary, getFormattedTimestamp, getGroupBys, getGroupBysFromPivotTable, getGroupBysFromTable, getGroupableColumns, getHeatmapRectObj, getHiddenColumns, getHistogramColumnObj, getHistogramScale, getInitialBucketSize, getInitialSelections, getKey, getKeyByValue, getLabelsBBox, getLegendLabels, getLegendLabelsForGroupbyQuery, getLegendLabelsForMultiSeries, getLegendLabelsForSingleColumn, getLegendLocation, getLegendScale, getLegendTitleFromColumns, getLineVertexObj, getLinearAxisTitle, getLinearScale, getLinearScales, getMaxLegendHeight, getMaxLegendSectionWidth, getMaxTickLabelWidth, getMaxValueFromKeyValueObj, getMinAndMaxValues, getMinValueFromKeyValueObj, getMonthLocalStartDate, getMultiSeriesColumnIndex, getNiceDateTickValues, getNiceTickValues, getNotLabeledDataAlerts, getNumberAxisUnits, getNumberColumnIndices, getNumberFormatConfig, getNumberOfGroupables, getNumberOfSeries, getNumericalColumns, getObjSize, getOpacityScale, getOperators, getPadding, getPieChartData, getPivotColumnIndexConfig, getPlainTextList, getPointObj, getPotentialDisplayTypes, getPrecisionForDayJS, getQueryFn, getQueryParams, getQueryRequestParams, getQuerySelectableJoinColumns, getQueryValidationQueryText, getRadiusScale, getRangeForAxis, getRecentSearchesFromLocalStorage, getRecentSelectionID, getRowNumberListForPopover, getSVGBase64, getSampleQueryRegex, getSampleQueryText, getScheduleFrequencyObject, getSelectableColumns, getSortColumnIndex, getSortDirection, getStartAndEndDateFromDateStrs, getStringColumnIndices, getStringColumns, getStringFromSource, getSuggestionLists, getSupportedConditionTypes, getSupportedDisplayTypes, getThemeType, getThemeValue, getTickSizeFromNumTicks, getTickValues, getTimeFrameTextFromChunk, getTimeObjFromTimeStamp, getTimeRangeFromDateArray, getTimeRangeFromRT, getTimeScale, getTitleCase, getTodaysDayOfTheMonth, getTooltipContent, getTotalBottomPadding, getTotalHorizontalPadding, getTotalLeftPadding, getTotalPossibleLegendSections, getTotalRightPadding, getTotalTopPadding, getTotalVerticalPadding, getUniqueYearsForColumn, getUnitSymbol, getUnitsForColumn, getVisibleColumns, getWeekLocalStartDate, getWeekdayFromTimeStamp, getlegendLabelSections, handleTooltipBoundaryCollision, hasColumnIndex, hasData, hasDateColumn, hasMoreData, hasNumberColumn, hasStringColumn, initializeAlert, initializeQueryValidationOptions, isAggSeed, isAggregation, isChartType, isColumnDateType, isColumnIndexConfigValid, isColumnIndexValid, isColumnIndicesValid, isColumnNumberType, isColumnStringType, isColumnSummable, isDataLimited, isDisplayTypeValid, isDrilldown, isError500Type, isExpressionQueryValid, isISODate, isInitialSelectionValid, isListQuery, isNumber, isObject, isOperatorJs, isSelectableNumberColumn, isSelectableStringColumn, isSingleValueResponse, isTableType, isTabulatorColumnComponent, isValueEmpty, color as legendColor, lineCommand, makeEmptyArray, markNotificationAsUnread, mergeBboxes, mergeBoundingClientRects, mergeSources, nameValueObject, normalizeString, numberIndicesArraysOverlap, numberSortFn, onTableCellClick, onlySeriesVisibilityChanged, onlyUnique, parseJwt, parseList, potentiallySupportsDatePivot, potentiallySupportsPivot, previewDataAlert, previewManagementDataAlert, removeDashboardRefreshInterval, removeElementAtIndex, removeFromDOM, removeHiddenLegendLabels, removeNotificationChannel, removeUserFromProjectRule, reportProblem, resetDateIsFuture, resetNotificationCount, rotateArray, roundDownToNearestMultiple, roundToNearestLog10, roundToNearestMultiple, roundUpToNearestMultiple, runCachedDashboardQuery, runDrilldown, runQuery, runQueryNewPage, runQueryOnly, runQueryValidation, scaleZero, sendDataToChannel, sendSuggestion, sendTrainingData, setCaretPosition, setColumnVisibility, setDashboardRefreshInterval, setFilters, setHeaderFilterPlaceholder, setRecentSearchesInLocalStorage, setSorterFunction, setTickSize, setTickValues, shouldDisableChartScale, shouldLabelsRotate, shouldPlotMultiSeries, showEvaluationFrequencySetting, sortDataByAlphabet, sortDataByColumn, sortDataByDate, supportsDatePivotTable, supportsNetworkGraph, supportsPieChart, supportsRegularPivotTable, svgPathD, svgToPng, type tableFilterParams, titlelizeString, toggleCustomDataAlertStatus, toggleProjectDataAlertStatus, transformLabels, transformQueryResponse, transformQueryResponseColumns, unsetFilterFromAPI, updateDataAlert, updateDataAlertStatus, updateManagementDataAlert, updateStartAndEndIndexes, usePivotDataForChart, uuidv4, validateExpression };
|
|
2842
|
+
export { AGG_TYPES, AXIS_TITLE_BORDER_PADDING_LEFT, AXIS_TITLE_BORDER_PADDING_TOP, AXIS_TITLE_PADDING_BOTTOM, AXIS_TITLE_PADDING_TOP, type AdditionalSelect, AggType, type AggTypeParams, AggTypes, type ApiFilter, type ApiSorter, type Authentication, type AutoQLJWT, type AvailableSelect, type AxiosResponse, BUTTON_PADDING, CHARTS_WITHOUT_AGGREGATED_DATA, CHARTS_WITHOUT_AXES, CHARTS_WITHOUT_LEGENDS, CHART_PADDING, CHART_TYPES, COLUMN_TYPES, COMPARE_TYPE, CONTINUOUS_TYPE, CUSTOM_TYPE, type Column, Column$1 as ColumnObj, type ColumnSelect, ColumnType, ColumnTypes, CustomColumnRowRangeTypes, CustomColumnTypes, CustomColumnValues, DATA_ALERT_CONDITION_TYPES, DATA_ALERT_ENABLED_STATUSES, DATA_ALERT_FREQUENCY_TYPE_OPTIONS, DATA_ALERT_OPERATORS, DATA_ALERT_STATUSES, DATE_ONLY_CHART_TYPES, DAYJS_PRECISION_FORMATS, DEFAULT_AGG_TYPE, DEFAULT_CHART_CONFIG, DEFAULT_COLUMN_NAME, DEFAULT_CSS_PREFIX, DEFAULT_DATA_PAGE_SIZE, DEFAULT_EVALUATION_FREQUENCY, DEFAULT_LEGEND_PADDING_BOTTOM, DEFAULT_LEGEND_PADDING_LEFT, DEFAULT_LEGEND_PADDING_RIGHT, DEFAULT_LEGEND_PADDING_TOP, DEFAULT_MAX_LEGEND_WIDTH, DEFAULT_SOURCE, DISABLED_CLASS, DISPLAY_TYPES, DOUBLE_AXIS_CHART_TYPES, DOW_STYLES, DataExplorerSubject, type DataExplorerSubjectFilter, type DataExplorerSubjectGroups, type DataExplorerSubjectInterface, type DataExplorerSuggestion, DataExplorerTypes, type DataFormatting, DateStringPrecisionTypes, DateUTC, type DisplayOverride, DisplayTypes, EVALUATION_FREQUENCY_OPTIONS, EXISTS_TYPE, FORMULA_CLASS, FUNCTION_OPERATORS, type FilterLock, type FrontendReq, GENERAL_ERROR, GENERAL_HTML_ERROR, GENERAL_QUERY_ERROR, GLOBAL_OPERATORS, GROUP_TERM_TYPE, GeneralErrorTypes, HIGHLIGHTED_CLASS, HORIZONTAL_LEGEND_SPACING, LABEL_FONT_SIZE, LEGEND_BORDER_PADDING, LEGEND_BORDER_THICKNESS, LEGEND_SHAPE_SIZE, LEGEND_TOP_ADJUSTMENT, LOAD_MORE_DROPDOWN_PADDING_BOTTOM, MAX_CHART_ELEMENTS, MAX_DATA_PAGE_SIZE, MAX_LEGEND_LABELS, MAX_RECENT_SEARCHES, MAX_ROWS_FOR_PIE_CHART, MINIMUM_INNER_HEIGHT, MINIMUM_INNER_WIDTH, MINIMUM_TITLE_LENGTH, MIN_HISTOGRAM_SAMPLE, MONTH_DAY_SELECT_OPTIONS, MONTH_NAMES, NUMBER_TERM_TYPE, OPERATORS, ORDERBY_DIRECTIONS, Operators, PATH_SMOOTHING, PERIODIC_TYPE, PROJECT_TYPE, type ParsedInterpretation, type ParsedInterpretationChunk, PrecisionTypes, QUERY_TERM_TYPE, QUERY_TIMEOUT_ERROR, type QueryData, QueryErrorTypes, type QueryResponse, REQUEST_CANCELLED_ERROR, RESET_PERIOD_OPTIONS, ROWS_RANGE, ROWS_RANGE_OPTIONS, type RawColumn, type Rows, SCHEDULED_TYPE, SCHEDULE_FREQUENCY_OPTIONS, SCHEDULE_INTERVAL_OPTIONS, SEASON_NAMES, SampleQueryReplacementTypes, type Scale, type SubjectSuggestion, TABLE_TYPES, TITLE_FONT_SIZE, type TableConfig, type TabulatorFilter, type TabulatorSorter, type Theme, ThemeType, type TransformedAxiosResponse, type TransformedQueryResponse, TranslationTypes, UNAUTHENTICATED_ERROR, VERTICAL_LEGEND_SPACING, type ValueLabel, type ValueLabelSuggestion, WEEKDAY_NAMES_MON, WEEKDAY_NAMES_SUN, WINDOW_FUNCTIONS, addSubjectToRecentSearches, addUserToProjectRule, adjustBottomTitleToFit, adjustMinAndMaxForScaleRatio, adjustTitleToFit, adjustTopTitleToFit, adjustVerticalTitleToFit, aggregateData, aggregateOtherCategory, animateInputText, applyLegendTitleStyles, applyPrecisionToDate, applyStylesForHiddenSeries, areAllColumnsHidden, areSomeColumnsHidden, assignLabelToManagementDataAlert, authenticationDefault, autoQLConfigDefault, bezierCommand, buildPlainColumnArrayFn, calculateMinAndMaxSums, capitalizeFirstChar, cloneObject, configureTheme, constructFilter, constructRTArray, convertToFunctionStr, convertToNumber, countDecimals, createDataAlert, createFilterFunction, createManagementDataAlert, createMutatorFn, createNotificationChannel, createSVGPath, currentEventLoopEnd, dataConfigDefault, dataFormattingDefault, dataStructureChanged, dateSortFn, dateStringSortFn, deepEqual, deleteAllNotifications, deleteDataAlert, deleteMultipleNotifications, deleteNotification, difference, dismissAllNotifications, dismissNotification, distributeListsEvenly, doesElementOverflowContainer, exportCSV, extractOperatorFromValue, fetchAutocomplete, fetchDataAlerts, fetchDataExplorerAutocomplete, fetchDataExplorerSampleQueries, fetchDataExplorerSuggestions, fetchDataPreview, fetchExploreQueries, fetchFilters, fetchNotification, fetchNotificationChannels, fetchNotificationCount, fetchNotificationData, fetchNotificationFeed, fetchRule, fetchSubjectList, fetchSubjectListV2, fetchSubscribedDataAlerts, fetchSuggestions, fetchTopics, fetchTopicsForVL, fetchVLAutocomplete, filterDataByColumn, findNetworkColumns, formatAdditionalSelectColumn, formatChartLabel, formatDatePivotMonth, formatDatePivotYear, formatDateStringType, formatDateType, formatElement, formatEpochDate, formatFiltersForAPI, formatFiltersForTabulator, formatISODateWithPrecision, formatNextScheduleDate, formatNumberFilterValue, formatQueryColumns, formatResetDate, formatSortersForAPI, formatSortersForTabulator, formatStringDate, formatStringDateWithPrecision, formatTableParams, functionsEqual, generateDatePivotData, generateFilterDrilldownResponse, generatePivotData, generatePivotTableData, getAggConfig, getAllDataAlertsLabels, getAllDataAlertsLabelsByProject, getAuthentication, getAutoQLConfig, getAxis, getAxisLabelsBbox, getBBoxFromRef, getBandScale, getBarRectObj, getBinData, getBinLinearScale, getBubbleObj, getChartColorVars, getChartScaleRatio, getCleanColumnName, getColorScale, getColorScales, getColumnDateRanges, getColumnFieldCompat, getColumnIdentifierCompat, getColumnIndexCompat, getColumnIndexConfig, getColumnNameForDateRange, getColumnOriginalIndexCompat, getColumnPositionCompat, getColumnRectObj, getColumnTypeAmounts, getCombinedFilters, getCurrencySymbol, getCurrentTimezone, getDashboardRefreshInterval, getDataAlertsByLabel, getDataConfig, getDataFormatting, getDateColumnIndex, getDateColumns, getDateNoQuotes, getDateRangeIntersection, getDateRangesFromInterpretation, getDatesFromRT, getDayJSObj, getDayLocalStartDate, getDayOfTheMonthFromTimestamp, getDayOfTheMonthSuffix, getDayjsObjForStringType, getDefaultBucketConfig, getDefaultDisplayType, getDefaultJoinColumnAndDisplayNameAndJoinColumnsIndices, getDefaultJoinColumns, getDrilldownData, getDrilldownGroupby, getEpochFromDate, getFilterDrilldown, getFilterPrecision, getFirstChartDisplayType, getFnSummary, getFormattedTimestamp, getGroupBys, getGroupBysFromPivotTable, getGroupBysFromTable, getGroupableColumns, getHeatmapRectObj, getHiddenColumns, getHistogramColumnObj, getHistogramScale, getInitialBucketSize, getInitialSelections, getKey, getKeyByValue, getLabelsBBox, getLegendLabels, getLegendLabelsForGroupbyQuery, getLegendLabelsForMultiSeries, getLegendLabelsForSingleColumn, getLegendLocation, getLegendScale, getLegendTitleFromColumns, getLineVertexObj, getLinearAxisTitle, getLinearScale, getLinearScales, getMaxLegendHeight, getMaxLegendSectionWidth, getMaxTickLabelWidth, getMaxValueFromKeyValueObj, getMinAndMaxValues, getMinValueFromKeyValueObj, getMonthLocalStartDate, getMultiSeriesColumnIndex, getNiceDateTickValues, getNiceTickValues, getNotLabeledDataAlerts, getNumberAxisUnits, getNumberColumnIndices, getNumberFormatConfig, getNumberOfGroupables, getNumberOfSeries, getNumericalColumns, getObjSize, getOpacityScale, getOperators, getPadding, getPieChartData, getPivotColumnIndexConfig, getPlainTextList, getPointObj, getPotentialDisplayTypes, getPrecisionForDayJS, getQueryFn, getQueryParams, getQueryRequestParams, getQuerySelectableJoinColumns, getQueryValidationQueryText, getRadiusScale, getRangeForAxis, getRecentSearchesFromLocalStorage, getRecentSelectionID, getRowNumberListForPopover, getSVGBase64, getSampleQueryRegex, getSampleQueryText, getScheduleFrequencyObject, getSelectableColumns, getSortColumnIndex, getSortDirection, getStartAndEndDateFromDateStrs, getStringColumnIndices, getStringColumns, getStringFromSource, getSuggestionLists, getSupportedConditionTypes, getSupportedDisplayTypes, getThemeType, getThemeValue, getTickSizeFromNumTicks, getTickValues, getTimeFrameTextFromChunk, getTimeObjFromTimeStamp, getTimeRangeFromDateArray, getTimeRangeFromRT, getTimeScale, getTitleCase, getTodaysDayOfTheMonth, getTooltipContent, getTotalBottomPadding, getTotalHorizontalPadding, getTotalLeftPadding, getTotalPossibleLegendSections, getTotalRightPadding, getTotalTopPadding, getTotalVerticalPadding, getUniqueYearsForColumn, getUnitSymbol, getUnitsForColumn, getVisibleColumns, getWeekLocalStartDate, getWeekdayFromTimeStamp, getlegendLabelSections, handleTooltipBoundaryCollision, hasColumnIndex, hasData, hasDateColumn, hasMoreData, hasNumberColumn, hasStringColumn, initializeAlert, initializeQueryValidationOptions, isAggSeed, isAggregation, isChartType, isColumnDateType, isColumnIndexConfigValid, isColumnIndexValid, isColumnIndicesValid, isColumnNumberType, isColumnStringType, isColumnSummable, isDataLimited, isDisplayTypeValid, isDrilldown, isError500Type, isExpressionQueryValid, isISODate, isInitialSelectionValid, isListQuery, isNumber, isObject, isOperatorJs, isSelectableNumberColumn, isSelectableStringColumn, isSingleValueResponse, isTableType, isTabulatorColumnComponent, isValueEmpty, color as legendColor, lineCommand, makeEmptyArray, markNotificationAsUnread, mergeBboxes, mergeBoundingClientRects, mergeSources, nameValueObject, normalizeString, numberIndicesArraysOverlap, numberSortFn, onTableCellClick, onlySeriesVisibilityChanged, onlyUnique, parseJwt, parseList, potentiallySupportsDatePivot, potentiallySupportsPivot, previewDataAlert, previewManagementDataAlert, removeDashboardRefreshInterval, removeElementAtIndex, removeFromDOM, removeHiddenLegendLabels, removeNotificationChannel, removeUserFromProjectRule, reportProblem, resetDateIsFuture, resetNotificationCount, rotateArray, roundDownToNearestMultiple, roundToNearestLog10, roundToNearestMultiple, roundUpToNearestMultiple, runCachedDashboardQuery, runDrilldown, runQuery, runQueryNewPage, runQueryOnly, runQueryValidation, scaleZero, sendDataToChannel, sendSuggestion, sendTrainingData, setCaretPosition, setColumnVisibility, setDashboardRefreshInterval, setFilters, setHeaderFilterPlaceholder, setRecentSearchesInLocalStorage, setSorterFunction, setTickSize, setTickValues, shouldDisableChartScale, shouldLabelsRotate, shouldPlotMultiSeries, showEvaluationFrequencySetting, sortDataByAlphabet, sortDataByColumn, sortDataByDate, supportsDatePivotTable, supportsNetworkGraph, supportsPieChart, supportsRegularPivotTable, svgPathD, svgToPng, type tableFilterParams, titlelizeString, toggleCustomDataAlertStatus, toggleProjectDataAlertStatus, transformLabels, transformQueryResponse, transformQueryResponseColumns, unsetFilterFromAPI, updateDataAlert, updateDataAlertStatus, updateManagementDataAlert, updateStartAndEndIndexes, usePivotDataForChart, uuidv4, validateExpression };
|
package/dist/index.global.js
CHANGED
|
@@ -17014,6 +17014,240 @@
|
|
|
17014
17014
|
return array3.slice(0, index).concat(array3.slice(index + 1));
|
|
17015
17015
|
};
|
|
17016
17016
|
|
|
17017
|
+
// src/HelperFns/tableHelpers.ts
|
|
17018
|
+
function getColumnIdentifierCompat(col) {
|
|
17019
|
+
var _a;
|
|
17020
|
+
if (!col) return void 0;
|
|
17021
|
+
if (isTabulatorColumnComponent(col)) {
|
|
17022
|
+
if (typeof col.id === "string" && col.id) return col.id;
|
|
17023
|
+
if (typeof col.getField === "function") return col.getField();
|
|
17024
|
+
const def = (_a = col.getDefinition) == null ? void 0 : _a.call(col);
|
|
17025
|
+
if (def && typeof def.field === "string") return def.field;
|
|
17026
|
+
return void 0;
|
|
17027
|
+
}
|
|
17028
|
+
if (typeof col.id === "string" && col.id) return col.id;
|
|
17029
|
+
return getColumnFieldCompat(col);
|
|
17030
|
+
}
|
|
17031
|
+
function getColumnOriginalIndexCompat(col, originalColumns) {
|
|
17032
|
+
var _a;
|
|
17033
|
+
if (!col || !Array.isArray(originalColumns)) return void 0;
|
|
17034
|
+
const identifier = getColumnIdentifierCompat(col);
|
|
17035
|
+
const idx = originalColumns.findIndex((orig) => getColumnIdentifierCompat(orig) === identifier);
|
|
17036
|
+
if (idx !== -1) return idx;
|
|
17037
|
+
const def = (_a = col.getDefinition) == null ? void 0 : _a.call(col);
|
|
17038
|
+
if (def && typeof def.index === "number") return def.index;
|
|
17039
|
+
return void 0;
|
|
17040
|
+
}
|
|
17041
|
+
function getColumnPositionCompat(col, visibleColumns) {
|
|
17042
|
+
if (!col || !Array.isArray(visibleColumns)) return void 0;
|
|
17043
|
+
if (isTabulatorColumnComponent(col)) {
|
|
17044
|
+
const idx2 = visibleColumns.indexOf(col);
|
|
17045
|
+
return idx2 >= 0 ? idx2 : void 0;
|
|
17046
|
+
}
|
|
17047
|
+
const identifier = getColumnIdentifierCompat(col);
|
|
17048
|
+
const idx = visibleColumns.findIndex((vis) => getColumnIdentifierCompat(vis) === identifier);
|
|
17049
|
+
return idx >= 0 ? idx : void 0;
|
|
17050
|
+
}
|
|
17051
|
+
function isTabulatorColumnComponent(x) {
|
|
17052
|
+
return !!x && typeof x.getField === "function" && typeof x.getDefinition === "function";
|
|
17053
|
+
}
|
|
17054
|
+
function getColumnIndexCompat(col, visibleColumns) {
|
|
17055
|
+
if (!col) return void 0;
|
|
17056
|
+
if (typeof col.getIndex === "function") return col.getIndex();
|
|
17057
|
+
if (typeof col.getPosition === "function") {
|
|
17058
|
+
const pos = col.getPosition(true);
|
|
17059
|
+
return typeof pos === "number" ? pos - 1 : void 0;
|
|
17060
|
+
}
|
|
17061
|
+
if (Array.isArray(visibleColumns)) {
|
|
17062
|
+
const idx = visibleColumns.indexOf(col);
|
|
17063
|
+
return idx >= 0 ? idx : void 0;
|
|
17064
|
+
}
|
|
17065
|
+
return void 0;
|
|
17066
|
+
}
|
|
17067
|
+
function getColumnFieldCompat(col) {
|
|
17068
|
+
var _a;
|
|
17069
|
+
if (!col) return void 0;
|
|
17070
|
+
if (typeof col.getField === "function") return col.getField();
|
|
17071
|
+
if (typeof col.getDefinition === "function") return (_a = col.getDefinition()) == null ? void 0 : _a.field;
|
|
17072
|
+
return col.field;
|
|
17073
|
+
}
|
|
17074
|
+
var formatTableParams = (params, columns) => {
|
|
17075
|
+
const formattedSorters = formatSortersForAPI(params, columns);
|
|
17076
|
+
const formattedFilters = formatFiltersForAPI(params, columns);
|
|
17077
|
+
const configState = {
|
|
17078
|
+
sorters: formattedSorters,
|
|
17079
|
+
filters: formattedFilters,
|
|
17080
|
+
page: params == null ? void 0 : params.page
|
|
17081
|
+
};
|
|
17082
|
+
return configState;
|
|
17083
|
+
};
|
|
17084
|
+
var formatSortersForAPI = (params, columns) => {
|
|
17085
|
+
var _a;
|
|
17086
|
+
const sorters = [];
|
|
17087
|
+
if (((_a = params == null ? void 0 : params.sort) == null ? void 0 : _a.length) > 0) {
|
|
17088
|
+
params.sort.forEach((sorter) => {
|
|
17089
|
+
try {
|
|
17090
|
+
const column = columns.find((col) => col.field == sorter.field);
|
|
17091
|
+
if (column) {
|
|
17092
|
+
const name = column.name;
|
|
17093
|
+
const sort = sorter.dir.toUpperCase();
|
|
17094
|
+
const id = column.id;
|
|
17095
|
+
if (name && sort) {
|
|
17096
|
+
sorters.push({ name, sort, id });
|
|
17097
|
+
}
|
|
17098
|
+
}
|
|
17099
|
+
} catch (error) {
|
|
17100
|
+
console.error(error);
|
|
17101
|
+
}
|
|
17102
|
+
});
|
|
17103
|
+
}
|
|
17104
|
+
return sorters;
|
|
17105
|
+
};
|
|
17106
|
+
var extractOperatorFromValue = (value) => {
|
|
17107
|
+
if (typeof value !== "string") return null;
|
|
17108
|
+
const m = value.trim().match(/^([<>=!]=?)\s*(.*)$/);
|
|
17109
|
+
return m ? { operator: m[1], cleanValue: m[2] } : null;
|
|
17110
|
+
};
|
|
17111
|
+
var formatNumberFilterValue = (headerValue = "") => {
|
|
17112
|
+
var _a, _b;
|
|
17113
|
+
const trimmed = String(headerValue != null ? headerValue : "").trim();
|
|
17114
|
+
const extracted = extractOperatorFromValue(trimmed);
|
|
17115
|
+
const operator = (_a = extracted == null ? void 0 : extracted.operator) != null ? _a : "=";
|
|
17116
|
+
const rest = (_b = extracted == null ? void 0 : extracted.cleanValue) != null ? _b : trimmed;
|
|
17117
|
+
const matched = rest.replace(/,/g, "").match(/^([+-]?\d+(?:\.\d+)?)$/);
|
|
17118
|
+
return matched ? { value: matched[1], operator } : { value: "", operator };
|
|
17119
|
+
};
|
|
17120
|
+
var formatFiltersForAPI = (params, columns) => {
|
|
17121
|
+
var _a;
|
|
17122
|
+
const filters = [];
|
|
17123
|
+
if (((_a = params == null ? void 0 : params.filter) == null ? void 0 : _a.length) > 0) {
|
|
17124
|
+
params.filter.forEach((filter3) => {
|
|
17125
|
+
var _a2, _b, _c;
|
|
17126
|
+
try {
|
|
17127
|
+
const column = columns.find((col) => col.field == filter3.field);
|
|
17128
|
+
if (column) {
|
|
17129
|
+
const rawValue = filter3.value;
|
|
17130
|
+
const stringValue = typeof rawValue === "string" ? rawValue.trim() : rawValue;
|
|
17131
|
+
let operator = "like";
|
|
17132
|
+
let value = rawValue;
|
|
17133
|
+
if (typeof stringValue === "string") {
|
|
17134
|
+
const extracted = extractOperatorFromValue(stringValue);
|
|
17135
|
+
if (extracted) {
|
|
17136
|
+
value = extracted.cleanValue;
|
|
17137
|
+
operator = extracted.operator;
|
|
17138
|
+
}
|
|
17139
|
+
}
|
|
17140
|
+
if (value === void 0 || value === null || typeof value === "string" && value === "") {
|
|
17141
|
+
return;
|
|
17142
|
+
}
|
|
17143
|
+
const filterObj = {
|
|
17144
|
+
name: (_a2 = column.name) != null ? _a2 : "",
|
|
17145
|
+
columnName: (_b = column.title) != null ? _b : "",
|
|
17146
|
+
value,
|
|
17147
|
+
operator,
|
|
17148
|
+
id: column.id
|
|
17149
|
+
};
|
|
17150
|
+
if (isColumnNumberType(column)) {
|
|
17151
|
+
const formatted = formatNumberFilterValue(filter3.value);
|
|
17152
|
+
filterObj.operator = formatted.operator;
|
|
17153
|
+
filterObj.value = formatted.value;
|
|
17154
|
+
} else if ((column == null ? void 0 : column.type) === "DATE" /* DATE */) {
|
|
17155
|
+
const dates = filter3.value.split(" to ");
|
|
17156
|
+
const precision = getPrecisionForDayJS(column.precision);
|
|
17157
|
+
const startDate = dayjsWithPlugins_default.utc(dates[0]).startOf(precision).toISOString();
|
|
17158
|
+
const endDate = dayjsWithPlugins_default.utc((_c = dates[1]) != null ? _c : dates[0]).endOf(precision).toISOString();
|
|
17159
|
+
filterObj.value = `${startDate},${endDate}`;
|
|
17160
|
+
filterObj.operator = "between";
|
|
17161
|
+
filterObj.displayValue = filter3.value.replaceAll(" to ", " and ");
|
|
17162
|
+
}
|
|
17163
|
+
filters.push(filterObj);
|
|
17164
|
+
}
|
|
17165
|
+
} catch (error) {
|
|
17166
|
+
console.warn(error);
|
|
17167
|
+
}
|
|
17168
|
+
});
|
|
17169
|
+
}
|
|
17170
|
+
return filters;
|
|
17171
|
+
};
|
|
17172
|
+
var formatSortersForTabulator = (apiSorters, columns) => {
|
|
17173
|
+
if (!apiSorters || !columns) {
|
|
17174
|
+
return [];
|
|
17175
|
+
}
|
|
17176
|
+
return apiSorters.map((sorter) => {
|
|
17177
|
+
const column = columns.find((col) => col.name === sorter.name);
|
|
17178
|
+
const field = (column == null ? void 0 : column.field) || sorter.name;
|
|
17179
|
+
return {
|
|
17180
|
+
field,
|
|
17181
|
+
dir: sorter.sort.toLowerCase()
|
|
17182
|
+
};
|
|
17183
|
+
});
|
|
17184
|
+
};
|
|
17185
|
+
var formatFiltersForTabulator = (apiFilters, columns) => {
|
|
17186
|
+
if (!apiFilters || !columns) {
|
|
17187
|
+
return [];
|
|
17188
|
+
}
|
|
17189
|
+
return apiFilters.map((filter3) => {
|
|
17190
|
+
const column = columns.find((col) => col.name === filter3.name);
|
|
17191
|
+
const field = (column == null ? void 0 : column.field) || filter3.name;
|
|
17192
|
+
let formattedValue = filter3.value;
|
|
17193
|
+
if (filter3.operator === "between" && filter3.value.includes(",")) {
|
|
17194
|
+
const [start, end] = filter3.value.split(",");
|
|
17195
|
+
formattedValue = `${dayjsWithPlugins_default(start).format("YYYY-MM-DD")} to ${dayjsWithPlugins_default(end).format("YYYY-MM-DD")}`;
|
|
17196
|
+
} else if (["=", "<", ">", "<=", ">=", "!="].includes(filter3.operator)) {
|
|
17197
|
+
formattedValue = `${filter3.operator} ${filter3.value}`;
|
|
17198
|
+
}
|
|
17199
|
+
return {
|
|
17200
|
+
field,
|
|
17201
|
+
type: "function",
|
|
17202
|
+
value: formattedValue
|
|
17203
|
+
};
|
|
17204
|
+
});
|
|
17205
|
+
};
|
|
17206
|
+
var onTableCellClick = ({ cell, columns, tableConfig, pivotData }) => {
|
|
17207
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j;
|
|
17208
|
+
try {
|
|
17209
|
+
if ((_b = (_a = cell == null ? void 0 : cell.getColumn()) == null ? void 0 : _a.getDefinition()) == null ? void 0 : _b.pivot) {
|
|
17210
|
+
return;
|
|
17211
|
+
}
|
|
17212
|
+
if (!columns) {
|
|
17213
|
+
return;
|
|
17214
|
+
}
|
|
17215
|
+
let groupBys = {};
|
|
17216
|
+
if (pivotData) {
|
|
17217
|
+
const cellValue = typeof (cell == null ? void 0 : cell.getValue) === "function" ? cell.getValue() : void 0;
|
|
17218
|
+
if (cellValue === void 0 || cellValue === null) {
|
|
17219
|
+
return;
|
|
17220
|
+
}
|
|
17221
|
+
if (pivotData.isDatePivot) {
|
|
17222
|
+
const dateColumnIndex = getDateColumnIndex(columns);
|
|
17223
|
+
const year = (_d = (_c = cell.getColumn()) == null ? void 0 : _c.getDefinition()) == null ? void 0 : _d.title;
|
|
17224
|
+
const month = (_e = cell.getData()) == null ? void 0 : _e[0];
|
|
17225
|
+
const value = (_g = (_f = pivotData.pivotOriginalColumnData) == null ? void 0 : _f[year]) == null ? void 0 : _g[month];
|
|
17226
|
+
groupBys = [
|
|
17227
|
+
{
|
|
17228
|
+
name: (_j = (_h = columns[dateColumnIndex]) == null ? void 0 : _h.drill_down) != null ? _j : (_i = columns[dateColumnIndex]) == null ? void 0 : _i.name,
|
|
17229
|
+
value
|
|
17230
|
+
}
|
|
17231
|
+
];
|
|
17232
|
+
} else {
|
|
17233
|
+
const columnHeaderDefinition = columns[tableConfig.legendColumnIndex];
|
|
17234
|
+
const rowHeaderDefinition = columns[tableConfig.stringColumnIndex];
|
|
17235
|
+
groupBys = getGroupBysFromPivotTable({
|
|
17236
|
+
cell,
|
|
17237
|
+
rowHeaderDefinition,
|
|
17238
|
+
columnHeaderDefinition
|
|
17239
|
+
});
|
|
17240
|
+
}
|
|
17241
|
+
} else {
|
|
17242
|
+
groupBys = getGroupBysFromTable(cell, columns);
|
|
17243
|
+
}
|
|
17244
|
+
return { groupBys, supportedByAPI: !!groupBys };
|
|
17245
|
+
} catch (error) {
|
|
17246
|
+
console.error(error);
|
|
17247
|
+
return;
|
|
17248
|
+
}
|
|
17249
|
+
};
|
|
17250
|
+
|
|
17017
17251
|
// src/HelperFns/columnHelpers.ts
|
|
17018
17252
|
var isColumnSummable = (col) => {
|
|
17019
17253
|
const type = col == null ? void 0 : col.type;
|
|
@@ -17256,10 +17490,10 @@
|
|
|
17256
17490
|
const m = String(s != null ? s : "").replace(/,/g, "").match(/[+-]?\d+(?:\.\d+)?/);
|
|
17257
17491
|
return m ? Number(m[0]) : NaN;
|
|
17258
17492
|
};
|
|
17259
|
-
const
|
|
17260
|
-
if (
|
|
17261
|
-
const op =
|
|
17262
|
-
const rest =
|
|
17493
|
+
const extracted = extractOperatorFromValue(raw);
|
|
17494
|
+
if (extracted) {
|
|
17495
|
+
const op = extracted.operator;
|
|
17496
|
+
const rest = extracted.cleanValue;
|
|
17263
17497
|
if (op === "!") {
|
|
17264
17498
|
return rest.length === 0 || !String(rowValue).toLowerCase().includes(rest.toLowerCase());
|
|
17265
17499
|
}
|
|
@@ -21206,244 +21440,6 @@
|
|
|
21206
21440
|
return JSON.parse(jsonPayload);
|
|
21207
21441
|
};
|
|
21208
21442
|
|
|
21209
|
-
// src/HelperFns/tableHelpers.ts
|
|
21210
|
-
function getColumnIdentifierCompat(col) {
|
|
21211
|
-
var _a;
|
|
21212
|
-
if (!col) return void 0;
|
|
21213
|
-
if (isTabulatorColumnComponent(col)) {
|
|
21214
|
-
if (typeof col.id === "string" && col.id) return col.id;
|
|
21215
|
-
if (typeof col.getField === "function") return col.getField();
|
|
21216
|
-
const def = (_a = col.getDefinition) == null ? void 0 : _a.call(col);
|
|
21217
|
-
if (def && typeof def.field === "string") return def.field;
|
|
21218
|
-
return void 0;
|
|
21219
|
-
}
|
|
21220
|
-
if (typeof col.id === "string" && col.id) return col.id;
|
|
21221
|
-
return getColumnFieldCompat(col);
|
|
21222
|
-
}
|
|
21223
|
-
function getColumnOriginalIndexCompat(col, originalColumns) {
|
|
21224
|
-
var _a;
|
|
21225
|
-
if (!col || !Array.isArray(originalColumns)) return void 0;
|
|
21226
|
-
const identifier = getColumnIdentifierCompat(col);
|
|
21227
|
-
const idx = originalColumns.findIndex((orig) => getColumnIdentifierCompat(orig) === identifier);
|
|
21228
|
-
if (idx !== -1) return idx;
|
|
21229
|
-
const def = (_a = col.getDefinition) == null ? void 0 : _a.call(col);
|
|
21230
|
-
if (def && typeof def.index === "number") return def.index;
|
|
21231
|
-
return void 0;
|
|
21232
|
-
}
|
|
21233
|
-
function getColumnPositionCompat(col, visibleColumns) {
|
|
21234
|
-
if (!col || !Array.isArray(visibleColumns)) return void 0;
|
|
21235
|
-
if (isTabulatorColumnComponent(col)) {
|
|
21236
|
-
const idx2 = visibleColumns.indexOf(col);
|
|
21237
|
-
return idx2 >= 0 ? idx2 : void 0;
|
|
21238
|
-
}
|
|
21239
|
-
const identifier = getColumnIdentifierCompat(col);
|
|
21240
|
-
const idx = visibleColumns.findIndex((vis) => getColumnIdentifierCompat(vis) === identifier);
|
|
21241
|
-
return idx >= 0 ? idx : void 0;
|
|
21242
|
-
}
|
|
21243
|
-
function isTabulatorColumnComponent(x) {
|
|
21244
|
-
return !!x && typeof x.getField === "function" && typeof x.getDefinition === "function";
|
|
21245
|
-
}
|
|
21246
|
-
function getColumnIndexCompat(col, visibleColumns) {
|
|
21247
|
-
if (!col) return void 0;
|
|
21248
|
-
if (typeof col.getIndex === "function") return col.getIndex();
|
|
21249
|
-
if (typeof col.getPosition === "function") {
|
|
21250
|
-
const pos = col.getPosition(true);
|
|
21251
|
-
return typeof pos === "number" ? pos - 1 : void 0;
|
|
21252
|
-
}
|
|
21253
|
-
if (Array.isArray(visibleColumns)) {
|
|
21254
|
-
const idx = visibleColumns.indexOf(col);
|
|
21255
|
-
return idx >= 0 ? idx : void 0;
|
|
21256
|
-
}
|
|
21257
|
-
return void 0;
|
|
21258
|
-
}
|
|
21259
|
-
function getColumnFieldCompat(col) {
|
|
21260
|
-
var _a;
|
|
21261
|
-
if (!col) return void 0;
|
|
21262
|
-
if (typeof col.getField === "function") return col.getField();
|
|
21263
|
-
if (typeof col.getDefinition === "function") return (_a = col.getDefinition()) == null ? void 0 : _a.field;
|
|
21264
|
-
return col.field;
|
|
21265
|
-
}
|
|
21266
|
-
var formatTableParams = (params, columns) => {
|
|
21267
|
-
const formattedSorters = formatSortersForAPI(params, columns);
|
|
21268
|
-
const formattedFilters = formatFiltersForAPI(params, columns);
|
|
21269
|
-
const configState = {
|
|
21270
|
-
sorters: formattedSorters,
|
|
21271
|
-
filters: formattedFilters,
|
|
21272
|
-
page: params == null ? void 0 : params.page
|
|
21273
|
-
};
|
|
21274
|
-
return configState;
|
|
21275
|
-
};
|
|
21276
|
-
var formatSortersForAPI = (params, columns) => {
|
|
21277
|
-
var _a;
|
|
21278
|
-
const sorters = [];
|
|
21279
|
-
if (((_a = params == null ? void 0 : params.sort) == null ? void 0 : _a.length) > 0) {
|
|
21280
|
-
params.sort.forEach((sorter) => {
|
|
21281
|
-
try {
|
|
21282
|
-
const column = columns.find((col) => col.field == sorter.field);
|
|
21283
|
-
if (column) {
|
|
21284
|
-
const name = column.name;
|
|
21285
|
-
const sort = sorter.dir.toUpperCase();
|
|
21286
|
-
const id = column.id;
|
|
21287
|
-
if (name && sort) {
|
|
21288
|
-
sorters.push({ name, sort, id });
|
|
21289
|
-
}
|
|
21290
|
-
}
|
|
21291
|
-
} catch (error) {
|
|
21292
|
-
console.error(error);
|
|
21293
|
-
}
|
|
21294
|
-
});
|
|
21295
|
-
}
|
|
21296
|
-
return sorters;
|
|
21297
|
-
};
|
|
21298
|
-
var formatNumberFilterValue = (headerValue = "") => {
|
|
21299
|
-
const trimmed = String(headerValue != null ? headerValue : "").trim();
|
|
21300
|
-
const opMatch = trimmed.match(/^(<=|>=|!=|!|=|<|>)/);
|
|
21301
|
-
const operator = opMatch ? opMatch[1] : "=";
|
|
21302
|
-
const rest = opMatch ? trimmed.slice(opMatch[1].length).trim() : trimmed;
|
|
21303
|
-
const matched = rest.replace(/,/g, "").match(/^([+-]?\d+(?:\.\d+)?)$/);
|
|
21304
|
-
return matched ? { value: matched[1], operator } : { value: "", operator };
|
|
21305
|
-
};
|
|
21306
|
-
var formatFiltersForAPI = (params, columns) => {
|
|
21307
|
-
var _a;
|
|
21308
|
-
const filters = [];
|
|
21309
|
-
if (((_a = params == null ? void 0 : params.filter) == null ? void 0 : _a.length) > 0) {
|
|
21310
|
-
params.filter.forEach((filter3) => {
|
|
21311
|
-
var _a2, _b, _c;
|
|
21312
|
-
try {
|
|
21313
|
-
const column = columns.find((col) => col.field == filter3.field);
|
|
21314
|
-
if (column) {
|
|
21315
|
-
const rawValue = filter3.value;
|
|
21316
|
-
const stringValue = typeof rawValue === "string" ? rawValue.trim() : rawValue;
|
|
21317
|
-
let operator = "like";
|
|
21318
|
-
let value = rawValue;
|
|
21319
|
-
if (typeof stringValue === "string") {
|
|
21320
|
-
const operatorMatch = stringValue.match(/^(!=|!|=|<=|>=|<|>)\s*(.*)$/);
|
|
21321
|
-
if (operatorMatch) {
|
|
21322
|
-
const opPrefix = operatorMatch[1];
|
|
21323
|
-
const cleanValue = operatorMatch[2];
|
|
21324
|
-
value = cleanValue;
|
|
21325
|
-
if (opPrefix === "!") {
|
|
21326
|
-
operator = "!";
|
|
21327
|
-
} else if (opPrefix === "!=") {
|
|
21328
|
-
operator = "!=";
|
|
21329
|
-
} else if (opPrefix === "=") {
|
|
21330
|
-
operator = "=";
|
|
21331
|
-
} else if (["<", ">", "<=", ">="].includes(opPrefix)) {
|
|
21332
|
-
operator = opPrefix;
|
|
21333
|
-
}
|
|
21334
|
-
}
|
|
21335
|
-
}
|
|
21336
|
-
if (value === void 0 || value === null || typeof value === "string" && value === "") {
|
|
21337
|
-
return;
|
|
21338
|
-
}
|
|
21339
|
-
const filterObj = {
|
|
21340
|
-
name: (_a2 = column.name) != null ? _a2 : "",
|
|
21341
|
-
columnName: (_b = column.title) != null ? _b : "",
|
|
21342
|
-
value,
|
|
21343
|
-
operator,
|
|
21344
|
-
id: column.id
|
|
21345
|
-
};
|
|
21346
|
-
if (isColumnNumberType(column)) {
|
|
21347
|
-
const formatted = formatNumberFilterValue(filter3.value);
|
|
21348
|
-
filterObj.operator = formatted.operator;
|
|
21349
|
-
filterObj.value = formatted.value;
|
|
21350
|
-
} else if ((column == null ? void 0 : column.type) === "DATE" /* DATE */) {
|
|
21351
|
-
const dates = filter3.value.split(" to ");
|
|
21352
|
-
const precision = getPrecisionForDayJS(column.precision);
|
|
21353
|
-
const startDate = dayjsWithPlugins_default.utc(dates[0]).startOf(precision).toISOString();
|
|
21354
|
-
const endDate = dayjsWithPlugins_default.utc((_c = dates[1]) != null ? _c : dates[0]).endOf(precision).toISOString();
|
|
21355
|
-
filterObj.value = `${startDate},${endDate}`;
|
|
21356
|
-
filterObj.operator = "between";
|
|
21357
|
-
filterObj.displayValue = filter3.value.replaceAll(" to ", " and ");
|
|
21358
|
-
}
|
|
21359
|
-
filters.push(filterObj);
|
|
21360
|
-
}
|
|
21361
|
-
} catch (error) {
|
|
21362
|
-
console.warn(error);
|
|
21363
|
-
}
|
|
21364
|
-
});
|
|
21365
|
-
}
|
|
21366
|
-
return filters;
|
|
21367
|
-
};
|
|
21368
|
-
var formatSortersForTabulator = (apiSorters, columns) => {
|
|
21369
|
-
if (!apiSorters || !columns) {
|
|
21370
|
-
return [];
|
|
21371
|
-
}
|
|
21372
|
-
return apiSorters.map((sorter) => {
|
|
21373
|
-
const column = columns.find((col) => col.name === sorter.name);
|
|
21374
|
-
const field = (column == null ? void 0 : column.field) || sorter.name;
|
|
21375
|
-
return {
|
|
21376
|
-
field,
|
|
21377
|
-
dir: sorter.sort.toLowerCase()
|
|
21378
|
-
};
|
|
21379
|
-
});
|
|
21380
|
-
};
|
|
21381
|
-
var formatFiltersForTabulator = (apiFilters, columns) => {
|
|
21382
|
-
if (!apiFilters || !columns) {
|
|
21383
|
-
return [];
|
|
21384
|
-
}
|
|
21385
|
-
return apiFilters.map((filter3) => {
|
|
21386
|
-
const column = columns.find((col) => col.name === filter3.name);
|
|
21387
|
-
const field = (column == null ? void 0 : column.field) || filter3.name;
|
|
21388
|
-
let formattedValue = filter3.value;
|
|
21389
|
-
if (filter3.operator === "between" && filter3.value.includes(",")) {
|
|
21390
|
-
const [start, end] = filter3.value.split(",");
|
|
21391
|
-
formattedValue = `${dayjsWithPlugins_default(start).format("YYYY-MM-DD")} to ${dayjsWithPlugins_default(end).format("YYYY-MM-DD")}`;
|
|
21392
|
-
} else if (["=", "<", ">", "<=", ">=", "!="].includes(filter3.operator)) {
|
|
21393
|
-
formattedValue = `${filter3.operator} ${filter3.value}`;
|
|
21394
|
-
}
|
|
21395
|
-
return {
|
|
21396
|
-
field,
|
|
21397
|
-
type: "function",
|
|
21398
|
-
value: formattedValue
|
|
21399
|
-
};
|
|
21400
|
-
});
|
|
21401
|
-
};
|
|
21402
|
-
var onTableCellClick = ({ cell, columns, tableConfig, pivotData }) => {
|
|
21403
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j;
|
|
21404
|
-
try {
|
|
21405
|
-
if ((_b = (_a = cell == null ? void 0 : cell.getColumn()) == null ? void 0 : _a.getDefinition()) == null ? void 0 : _b.pivot) {
|
|
21406
|
-
return;
|
|
21407
|
-
}
|
|
21408
|
-
if (!columns) {
|
|
21409
|
-
return;
|
|
21410
|
-
}
|
|
21411
|
-
let groupBys = {};
|
|
21412
|
-
if (pivotData) {
|
|
21413
|
-
const cellValue = typeof (cell == null ? void 0 : cell.getValue) === "function" ? cell.getValue() : void 0;
|
|
21414
|
-
if (cellValue === void 0 || cellValue === null) {
|
|
21415
|
-
return;
|
|
21416
|
-
}
|
|
21417
|
-
if (pivotData.isDatePivot) {
|
|
21418
|
-
const dateColumnIndex = getDateColumnIndex(columns);
|
|
21419
|
-
const year = (_d = (_c = cell.getColumn()) == null ? void 0 : _c.getDefinition()) == null ? void 0 : _d.title;
|
|
21420
|
-
const month = (_e = cell.getData()) == null ? void 0 : _e[0];
|
|
21421
|
-
const value = (_g = (_f = pivotData.pivotOriginalColumnData) == null ? void 0 : _f[year]) == null ? void 0 : _g[month];
|
|
21422
|
-
groupBys = [
|
|
21423
|
-
{
|
|
21424
|
-
name: (_j = (_h = columns[dateColumnIndex]) == null ? void 0 : _h.drill_down) != null ? _j : (_i = columns[dateColumnIndex]) == null ? void 0 : _i.name,
|
|
21425
|
-
value
|
|
21426
|
-
}
|
|
21427
|
-
];
|
|
21428
|
-
} else {
|
|
21429
|
-
const columnHeaderDefinition = columns[tableConfig.legendColumnIndex];
|
|
21430
|
-
const rowHeaderDefinition = columns[tableConfig.stringColumnIndex];
|
|
21431
|
-
groupBys = getGroupBysFromPivotTable({
|
|
21432
|
-
cell,
|
|
21433
|
-
rowHeaderDefinition,
|
|
21434
|
-
columnHeaderDefinition
|
|
21435
|
-
});
|
|
21436
|
-
}
|
|
21437
|
-
} else {
|
|
21438
|
-
groupBys = getGroupBysFromTable(cell, columns);
|
|
21439
|
-
}
|
|
21440
|
-
return { groupBys, supportedByAPI: !!groupBys };
|
|
21441
|
-
} catch (error) {
|
|
21442
|
-
console.error(error);
|
|
21443
|
-
return;
|
|
21444
|
-
}
|
|
21445
|
-
};
|
|
21446
|
-
|
|
21447
21443
|
// src/HelperFns/dataExplorerHelpers.ts
|
|
21448
21444
|
var MAX_RECENT_SEARCHES = 3;
|
|
21449
21445
|
var getRecentSelectionID = (authentication) => {
|