autoql-fe-utils 1.6.33 → 1.7.1

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.ts CHANGED
@@ -5,6 +5,7 @@ import axios from 'axios';
5
5
  declare const capitalizeFirstChar: (string: any) => any;
6
6
  declare const isNumber: (str: any) => boolean;
7
7
  declare const getTitleCase: (str: any) => any;
8
+ declare function titlelizeString(str: any): any;
8
9
 
9
10
  declare enum PrecisionTypes {
10
11
  DAY = "DAY",
@@ -84,6 +85,26 @@ declare enum Operators {
84
85
  SUBTRACTION = "SUBTRACTION",
85
86
  DIVISION = "DIVISION"
86
87
  }
88
+ declare enum CustomColumnValues {
89
+ LEFT_BRACKET = "LEFT_BRACKET",
90
+ RIGHT_BRACKET = "RIGHT_BRACKET",
91
+ PERCENT_TOTAL = "PERCENT_TOTAL",
92
+ RANK = "RANK",
93
+ MOVING_AVG = "MOVING_AVG",
94
+ FUNCTION = "FUNCTION"
95
+ }
96
+ declare enum CustomColumnTypes {
97
+ COLUMN = "column",
98
+ NUMBER = "number",
99
+ OPERATOR = "operator",
100
+ CURRENCY = "currency",
101
+ FUNCTION = "function",
102
+ SUM = "sum"
103
+ }
104
+ declare enum CustomColumnRowRangeTypes {
105
+ PRECEEDING = "PRECEDING",
106
+ FOLLOWING = "FOLLOWING"
107
+ }
87
108
  declare enum GeneralErrorTypes {
88
109
  UNAUTHORIZED = "UNAUTHORIZED",
89
110
  NO_PROJECT_ID_SUPPLIED = "No project id supplied"
@@ -603,6 +624,9 @@ type ParsedInterpretationChunk = {
603
624
  dateArray?: string[];
604
625
  operator?: string;
605
626
  type?: string;
627
+ causes_gen2?: string[];
628
+ causes?: string[];
629
+ clean_causes?: string[];
606
630
  };
607
631
  type ParsedInterpretation = ParsedInterpretationChunk[];
608
632
  interface QueryData {
@@ -772,6 +796,7 @@ declare const autoQLConfigDefault: {
772
796
  enableReportProblem: boolean;
773
797
  projectId: string;
774
798
  enableProjectSelect: boolean;
799
+ enableEditReverseTranslation: boolean;
775
800
  };
776
801
  declare const dataConfigDefault: {
777
802
  stringColumnIndices: any[];
@@ -802,6 +827,7 @@ declare const getAutoQLConfig: (prop?: {}) => {
802
827
  enableReportProblem: boolean;
803
828
  projectId: string;
804
829
  enableProjectSelect: boolean;
830
+ enableEditReverseTranslation: boolean;
805
831
  };
806
832
  declare const getDataConfig: (prop?: {}) => {
807
833
  stringColumnIndices: any[];
@@ -2699,4 +2725,4 @@ declare function color(): {
2699
2725
  on(): any;
2700
2726
  };
2701
2727
 
2702
- export { AGG_TYPES, AXIS_TITLE_BORDER_PADDING_LEFT, AXIS_TITLE_BORDER_PADDING_TOP, AXIS_TITLE_PADDING_BOTTOM, AXIS_TITLE_PADDING_TOP, AdditionalSelect, AggType, AggTypeParams, AggTypes, Authentication, AutoQLJWT, AvailableSelect, 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, Column, Column$1 as ColumnObj, ColumnSelect, ColumnType, ColumnTypes, 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, DataExplorerSubjectFilter, DataExplorerSubjectGroups, DataExplorerSubjectInterface, DataExplorerSuggestion, DataExplorerTypes, DataFormatting, DateStringPrecisionTypes, DateUTC, DisplayOverride, DisplayTypes, EVALUATION_FREQUENCY_OPTIONS, EXISTS_TYPE, FORMULA_CLASS, FUNCTION_OPERATORS, FilterLock, 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, ParsedInterpretation, ParsedInterpretationChunk, PrecisionTypes, QUERY_TERM_TYPE, QUERY_TIMEOUT_ERROR, QueryData, QueryErrorTypes, QueryResponse, REQUEST_CANCELLED_ERROR, RESET_PERIOD_OPTIONS, ROWS_RANGE, ROWS_RANGE_OPTIONS, RawColumn, Rows, SCHEDULED_TYPE, SCHEDULE_FREQUENCY_OPTIONS, SCHEDULE_INTERVAL_OPTIONS, SEASON_NAMES, SampleQueryReplacementTypes, Scale, SubjectSuggestion, TABLE_TYPES, TITLE_FONT_SIZE, TableConfig, Theme, ThemeType, TransformedAxiosResponse, TransformedQueryResponse, TranslationTypes, UNAUTHENTICATED_ERROR, VERTICAL_LEGEND_SPACING, ValueLabel, 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, 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, formatAdditionalSelectColumn, formatChartLabel, formatDatePivotMonth, formatDatePivotYear, formatDateStringType, formatDateType, formatElement, formatEpochDate, formatFiltersForAPI, formatISODateWithPrecision, formatNextScheduleDate, formatNumberFilterValue, formatQueryColumns, formatResetDate, formatSortersForAPI, 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, getColumnIndexConfig, getColumnNameForDateRange, getColumnRectObj, getColumnTypeAmounts, getCombinedFilters, getCurrencySymbol, getCurrentTimezone, getDataAlertsByLabel, getDataConfig, getDataFormatting, getDateColumnIndex, 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, 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, isDataLimited, isDisplayTypeValid, isDrilldown, isError500Type, isExpressionQueryValid, isISODate, isInitialSelectionValid, isListQuery, isNumber, isObject, isOperatorJs, isSingleValueResponse, isTableType, isValueEmpty, color as legendColor, lineCommand, makeEmptyArray, markNotificationAsUnread, mergeBboxes, mergeBoundingClientRects, mergeSources, nameValueObject, numberIndicesArraysOverlap, numberSortFn, onTableCellClick, onlySeriesVisibilityChanged, onlyUnique, parseJwt, potentiallySupportsDatePivot, potentiallySupportsPivot, previewDataAlert, previewManagementDataAlert, removeElementAtIndex, removeFromDOM, removeHiddenLegendLabels, removeNotificationChannel, removeUserFromProjectRule, reportProblem, resetDateIsFuture, resetNotificationCount, rotateArray, roundDownToNearestMultiple, roundToNearestLog10, roundToNearestMultiple, roundUpToNearestMultiple, runDrilldown, runQuery, runQueryNewPage, runQueryOnly, runQueryValidation, scaleZero, sendDataToChannel, sendSuggestion, sendTrainingData, setCaretPosition, setColumnVisibility, setFilterFunction, setFilters, setHeaderFilterPlaceholder, setRecentSearchesInLocalStorage, setSorterFunction, setTickSize, setTickValues, shouldDisableChartScale, shouldLabelsRotate, shouldPlotMultiSeries, showEvaluationFrequencySetting, sortDataByAlphabet, sortDataByColumn, sortDataByDate, supportsDatePivotTable, supportsPieChart, supportsRegularPivotTable, svgPathD, svgToPng, tableFilterParams, toggleCustomDataAlertStatus, toggleProjectDataAlertStatus, transformLabels, transformQueryResponse, transformQueryResponseColumns, unsetFilterFromAPI, updateDataAlert, updateDataAlertStatus, updateManagementDataAlert, updateStartAndEndIndexes, usePivotDataForChart, uuidv4, validateExpression };
2728
+ export { AGG_TYPES, AXIS_TITLE_BORDER_PADDING_LEFT, AXIS_TITLE_BORDER_PADDING_TOP, AXIS_TITLE_PADDING_BOTTOM, AXIS_TITLE_PADDING_TOP, AdditionalSelect, AggType, AggTypeParams, AggTypes, Authentication, AutoQLJWT, AvailableSelect, 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, Column, Column$1 as ColumnObj, 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, DataExplorerSubjectFilter, DataExplorerSubjectGroups, DataExplorerSubjectInterface, DataExplorerSuggestion, DataExplorerTypes, DataFormatting, DateStringPrecisionTypes, DateUTC, DisplayOverride, DisplayTypes, EVALUATION_FREQUENCY_OPTIONS, EXISTS_TYPE, FORMULA_CLASS, FUNCTION_OPERATORS, FilterLock, 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, ParsedInterpretation, ParsedInterpretationChunk, PrecisionTypes, QUERY_TERM_TYPE, QUERY_TIMEOUT_ERROR, QueryData, QueryErrorTypes, QueryResponse, REQUEST_CANCELLED_ERROR, RESET_PERIOD_OPTIONS, ROWS_RANGE, ROWS_RANGE_OPTIONS, RawColumn, Rows, SCHEDULED_TYPE, SCHEDULE_FREQUENCY_OPTIONS, SCHEDULE_INTERVAL_OPTIONS, SEASON_NAMES, SampleQueryReplacementTypes, Scale, SubjectSuggestion, TABLE_TYPES, TITLE_FONT_SIZE, TableConfig, Theme, ThemeType, TransformedAxiosResponse, TransformedQueryResponse, TranslationTypes, UNAUTHENTICATED_ERROR, VERTICAL_LEGEND_SPACING, ValueLabel, 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, 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, formatAdditionalSelectColumn, formatChartLabel, formatDatePivotMonth, formatDatePivotYear, formatDateStringType, formatDateType, formatElement, formatEpochDate, formatFiltersForAPI, formatISODateWithPrecision, formatNextScheduleDate, formatNumberFilterValue, formatQueryColumns, formatResetDate, formatSortersForAPI, 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, getColumnIndexConfig, getColumnNameForDateRange, getColumnRectObj, getColumnTypeAmounts, getCombinedFilters, getCurrencySymbol, getCurrentTimezone, getDataAlertsByLabel, getDataConfig, getDataFormatting, getDateColumnIndex, 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, 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, isDataLimited, isDisplayTypeValid, isDrilldown, isError500Type, isExpressionQueryValid, isISODate, isInitialSelectionValid, isListQuery, isNumber, isObject, isOperatorJs, isSingleValueResponse, isTableType, isValueEmpty, color as legendColor, lineCommand, makeEmptyArray, markNotificationAsUnread, mergeBboxes, mergeBoundingClientRects, mergeSources, nameValueObject, numberIndicesArraysOverlap, numberSortFn, onTableCellClick, onlySeriesVisibilityChanged, onlyUnique, parseJwt, potentiallySupportsDatePivot, potentiallySupportsPivot, previewDataAlert, previewManagementDataAlert, removeElementAtIndex, removeFromDOM, removeHiddenLegendLabels, removeNotificationChannel, removeUserFromProjectRule, reportProblem, resetDateIsFuture, resetNotificationCount, rotateArray, roundDownToNearestMultiple, roundToNearestLog10, roundToNearestMultiple, roundUpToNearestMultiple, runDrilldown, runQuery, runQueryNewPage, runQueryOnly, runQueryValidation, scaleZero, sendDataToChannel, sendSuggestion, sendTrainingData, setCaretPosition, setColumnVisibility, setFilterFunction, setFilters, setHeaderFilterPlaceholder, setRecentSearchesInLocalStorage, setSorterFunction, setTickSize, setTickValues, shouldDisableChartScale, shouldLabelsRotate, shouldPlotMultiSeries, showEvaluationFrequencySetting, sortDataByAlphabet, sortDataByColumn, sortDataByDate, supportsDatePivotTable, supportsPieChart, supportsRegularPivotTable, svgPathD, svgToPng, tableFilterParams, titlelizeString, toggleCustomDataAlertStatus, toggleProjectDataAlertStatus, transformLabels, transformQueryResponse, transformQueryResponseColumns, unsetFilterFromAPI, updateDataAlert, updateDataAlertStatus, updateManagementDataAlert, updateStartAndEndIndexes, usePivotDataForChart, uuidv4, validateExpression };
@@ -13949,6 +13949,20 @@
13949
13949
  }
13950
13950
  return str[0].toUpperCase() + str.substring(1);
13951
13951
  };
13952
+ function titlelizeString(str) {
13953
+ try {
13954
+ if (typeof str !== "string") {
13955
+ throw new TypeError("Input must be a string");
13956
+ }
13957
+ if (!str.trim()) {
13958
+ return "";
13959
+ }
13960
+ return str.replace(/[^a-zA-Z\s]/g, " ").split(" ").map((word) => word.charAt(0).toUpperCase() + word.slice(1).toLowerCase()).join(" ");
13961
+ } catch (error) {
13962
+ console.error("Error in titlelizeString:", error);
13963
+ return str;
13964
+ }
13965
+ }
13952
13966
 
13953
13967
  // node_modules/uuid/dist/esm-node/rng.js
13954
13968
  var import_crypto = __toESM(__require("crypto"));
@@ -14675,6 +14689,29 @@
14675
14689
  Operators2["DIVISION"] = "DIVISION";
14676
14690
  return Operators2;
14677
14691
  })(Operators || {});
14692
+ var CustomColumnValues = /* @__PURE__ */ ((CustomColumnValues2) => {
14693
+ CustomColumnValues2["LEFT_BRACKET"] = "LEFT_BRACKET";
14694
+ CustomColumnValues2["RIGHT_BRACKET"] = "RIGHT_BRACKET";
14695
+ CustomColumnValues2["PERCENT_TOTAL"] = "PERCENT_TOTAL";
14696
+ CustomColumnValues2["RANK"] = "RANK";
14697
+ CustomColumnValues2["MOVING_AVG"] = "MOVING_AVG";
14698
+ CustomColumnValues2["FUNCTION"] = "FUNCTION";
14699
+ return CustomColumnValues2;
14700
+ })(CustomColumnValues || {});
14701
+ var CustomColumnTypes = /* @__PURE__ */ ((CustomColumnTypes2) => {
14702
+ CustomColumnTypes2["COLUMN"] = "column";
14703
+ CustomColumnTypes2["NUMBER"] = "number";
14704
+ CustomColumnTypes2["OPERATOR"] = "operator";
14705
+ CustomColumnTypes2["CURRENCY"] = "currency";
14706
+ CustomColumnTypes2["FUNCTION"] = "function";
14707
+ CustomColumnTypes2["SUM"] = "sum";
14708
+ return CustomColumnTypes2;
14709
+ })(CustomColumnTypes || {});
14710
+ var CustomColumnRowRangeTypes = /* @__PURE__ */ ((CustomColumnRowRangeTypes2) => {
14711
+ CustomColumnRowRangeTypes2["PRECEEDING"] = "PRECEDING";
14712
+ CustomColumnRowRangeTypes2["FOLLOWING"] = "FOLLOWING";
14713
+ return CustomColumnRowRangeTypes2;
14714
+ })(CustomColumnRowRangeTypes || {});
14678
14715
  var GeneralErrorTypes = /* @__PURE__ */ ((GeneralErrorTypes2) => {
14679
14716
  GeneralErrorTypes2["UNAUTHORIZED"] = "UNAUTHORIZED";
14680
14717
  GeneralErrorTypes2["NO_PROJECT_ID_SUPPLIED"] = "No project id supplied";
@@ -15488,7 +15525,8 @@
15488
15525
  enableCSVDownload: true,
15489
15526
  enableReportProblem: true,
15490
15527
  projectId: "",
15491
- enableProjectSelect: false
15528
+ enableProjectSelect: false,
15529
+ enableEditReverseTranslation: false
15492
15530
  };
15493
15531
  var dataConfigDefault = {
15494
15532
  stringColumnIndices: [],
@@ -17987,6 +18025,8 @@
17987
18025
  };
17988
18026
 
17989
18027
  // src/HelperFns/reverseTranslationHelpers.ts
18028
+ var bracketsRegex = /\((?:[^)(]+|\((?:[^)(]+|\([^)(]*\))*\))*\)/g;
18029
+ var singleQuoteRegex = /'(''|[^'])*'/g;
17990
18030
  var getRegexMatchArray = (str, reg) => {
17991
18031
  if (!str) {
17992
18032
  return [];
@@ -18101,11 +18141,29 @@
18101
18141
  }
18102
18142
  return strArray;
18103
18143
  };
18144
+ var extractQuotedContent = (inputs) => {
18145
+ return inputs.map((str) => {
18146
+ const match = str.match(/'\s*([^']+)\s*'/);
18147
+ return match ? match[1].trim() : null;
18148
+ }).filter(Boolean);
18149
+ };
18150
+ var parseChunkCauses = (chunk) => {
18151
+ var _a, _b;
18152
+ if (!((_a = chunk == null ? void 0 : chunk.causes) == null ? void 0 : _a.length) || !((_b = chunk.causes_gen2) == null ? void 0 : _b.length) || !chunk.eng) {
18153
+ return chunk;
18154
+ }
18155
+ const cleanCauses = extractQuotedContent([...chunk.causes, ...chunk.causes_gen2]);
18156
+ if (!(cleanCauses == null ? void 0 : cleanCauses.length)) {
18157
+ return chunk;
18158
+ }
18159
+ return {
18160
+ ...chunk,
18161
+ clean_causes: [...new Set(cleanCauses)]
18162
+ };
18163
+ };
18104
18164
  var parseFilterChunk = (chunk) => {
18105
18165
  var _a, _b, _c, _d, _e, _f, _g;
18106
18166
  try {
18107
- const bracketsRegex = /\((?:[^)(]+|\((?:[^)(]+|\([^)(]*\))*\))*\)/g;
18108
- const singleQuoteRegex = /'(''|[^'])*'/g;
18109
18167
  const input = chunk.eng;
18110
18168
  const textOutsideBrackets = input.split(bracketsRegex);
18111
18169
  let match;
@@ -18165,11 +18223,14 @@
18165
18223
  const reverseTranslationArray = [];
18166
18224
  if (interpretation == null ? void 0 : interpretation.length) {
18167
18225
  interpretation.forEach((chunk) => {
18168
- if (chunk.c_type === "FILTER" || chunk.c_type === "SEED") {
18226
+ if (chunk.c_type === "FILTER") {
18169
18227
  const chunkedFilterArray = parseFilterChunk(chunk);
18170
18228
  chunkedFilterArray.forEach((filterChunk) => {
18171
18229
  reverseTranslationArray.push(filterChunk);
18172
18230
  });
18231
+ } else if (chunk.c_type === "SEED" || chunk.c_type === "GROUPBY") {
18232
+ const cleanChunk = parseChunkCauses(chunk);
18233
+ reverseTranslationArray.push(cleanChunk);
18173
18234
  } else {
18174
18235
  reverseTranslationArray.push(chunk);
18175
18236
  }
@@ -20216,7 +20277,7 @@
20216
20277
  const formatted = formatNumberFilterValue(filter3.value);
20217
20278
  filterObj.operator = formatted.operator;
20218
20279
  filterObj.value = formatted.value;
20219
- } else if ((column == null ? void 0 : column.type) === "DATE") {
20280
+ } else if ((column == null ? void 0 : column.type) === "DATE" /* DATE */) {
20220
20281
  const dates = filter3.value.split(" to ");
20221
20282
  const precision = getPrecisionForDayJS(column.precision);
20222
20283
  const startDate = dayjsWithPlugins_default.utc(dates[0]).startOf(precision).toISOString();
@@ -20765,16 +20826,18 @@
20765
20826
  var _a, _b;
20766
20827
  try {
20767
20828
  let columnFnStr = "";
20768
- const numRightBrackets = (_a = origColumnFnArray.filter((chunk) => chunk.value === "RIGHT_BRACKET")) == null ? void 0 : _a.length;
20769
- const numLeftBrackets = (_b = origColumnFnArray.filter((chunk) => chunk.value === "LEFT_BRACKET")) == null ? void 0 : _b.length;
20829
+ const numRightBrackets = (_a = origColumnFnArray.filter(
20830
+ (chunk) => chunk.value === "RIGHT_BRACKET" /* RIGHT_BRACKET */
20831
+ )) == null ? void 0 : _a.length;
20832
+ const numLeftBrackets = (_b = origColumnFnArray.filter((chunk) => chunk.value === "LEFT_BRACKET" /* LEFT_BRACKET */)) == null ? void 0 : _b.length;
20770
20833
  if (numRightBrackets !== numLeftBrackets) {
20771
20834
  throw new ChataError("Syntax Error: Formula contains unclosed brackets");
20772
20835
  }
20773
20836
  origColumnFnArray.forEach((chunk, i) => {
20774
20837
  var _a2, _b2, _c;
20775
- if (chunk.type === "operator") {
20838
+ if (chunk.type === "operator" /* OPERATOR */) {
20776
20839
  if (i === origColumnFnArray.length - 1) {
20777
- if (chunk.value !== "RIGHT_BRACKET") {
20840
+ if (chunk.value !== "RIGHT_BRACKET" /* RIGHT_BRACKET */) {
20778
20841
  throw new ChataError("Syntax Error: Formula can't end with an operator");
20779
20842
  }
20780
20843
  }
@@ -20784,7 +20847,7 @@
20784
20847
  throw new ChataError("Syntax Error: Number input is empty");
20785
20848
  }
20786
20849
  columnFnStr = columnFnStr + " " + chunk.value;
20787
- } else if (chunk.type === "column" && (chunk == null ? void 0 : chunk.column)) {
20850
+ } else if (chunk.type === "column" /* COLUMN */ && (chunk == null ? void 0 : chunk.column)) {
20788
20851
  columnFnStr = columnFnStr + " row[" + ((_c = chunk == null ? void 0 : chunk.column) == null ? void 0 : _c.index) + "]";
20789
20852
  }
20790
20853
  });
@@ -20821,11 +20884,11 @@
20821
20884
  let fnSummary = "";
20822
20885
  columnFnArray.forEach((chunk, i) => {
20823
20886
  var _a, _b;
20824
- if (chunk.type === "operator") {
20887
+ if (chunk.type === "operator" /* OPERATOR */) {
20825
20888
  fnSummary = `${fnSummary} ${(_a = OPERATORS[chunk.value]) == null ? void 0 : _a.js}`;
20826
- } else if (chunk.type === "number") {
20889
+ } else if (chunk.type === "number" /* NUMBER */) {
20827
20890
  fnSummary = `${fnSummary} ${chunk.value}`;
20828
- } else if (chunk.type === "column" && (chunk == null ? void 0 : chunk.column)) {
20891
+ } else if (chunk.type === "column" /* COLUMN */ && (chunk == null ? void 0 : chunk.column)) {
20829
20892
  fnSummary = `${fnSummary} ${(_b = chunk.column) == null ? void 0 : _b.display_name}`;
20830
20893
  }
20831
20894
  });
@@ -23562,7 +23625,7 @@
23562
23625
  if (formattedValue === null) {
23563
23626
  formattedValue = "NULL";
23564
23627
  operator = "is";
23565
- } else if ((column == null ? void 0 : column.type) === "DATE") {
23628
+ } else if ((column == null ? void 0 : column.type) === "DATE" /* DATE */) {
23566
23629
  const isoDate = getDayJSObj({ value, column });
23567
23630
  const precision = getPrecisionForDayJS(column.precision);
23568
23631
  const isoDateStart = isoDate.startOf(precision).toISOString();