@ohos-ports/superset-ui-core 0.20.4-beta.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/README.md +42 -0
- package/esm/api/index.js +1 -0
- package/esm/api/types/core.js +0 -0
- package/esm/api/types/core.js.map +1 -0
- package/esm/chart/clients/ChartClient.js +201 -0
- package/esm/chart/clients/ChartClient.js.map +1 -0
- package/esm/chart/components/ChartDataProvider.js +171 -0
- package/esm/chart/components/ChartDataProvider.js.map +1 -0
- package/esm/chart/components/FallbackComponent.js +61 -0
- package/esm/chart/components/FallbackComponent.js.map +1 -0
- package/esm/chart/components/NoResultsComponent.js +88 -0
- package/esm/chart/components/NoResultsComponent.js.map +1 -0
- package/esm/chart/components/SuperChart.js +267 -0
- package/esm/chart/components/SuperChart.js.map +1 -0
- package/esm/chart/components/SuperChartCore.js +235 -0
- package/esm/chart/components/SuperChartCore.js.map +1 -0
- package/esm/chart/components/createLoadableRenderer.js +75 -0
- package/esm/chart/components/createLoadableRenderer.js.map +1 -0
- package/esm/chart/components/reactify.js +115 -0
- package/esm/chart/components/reactify.js.map +1 -0
- package/esm/chart/index.js +49 -0
- package/esm/chart/index.js.map +1 -0
- package/esm/chart/models/ChartControlPanel.js +1 -0
- package/esm/chart/models/ChartControlPanel.js.map +1 -0
- package/esm/chart/models/ChartMetadata.js +160 -0
- package/esm/chart/models/ChartMetadata.js.map +1 -0
- package/esm/chart/models/ChartPlugin.js +162 -0
- package/esm/chart/models/ChartPlugin.js.map +1 -0
- package/esm/chart/models/ChartProps.js +270 -0
- package/esm/chart/models/ChartProps.js.map +1 -0
- package/esm/chart/registries/ChartBuildQueryRegistrySingleton.js +53 -0
- package/esm/chart/registries/ChartBuildQueryRegistrySingleton.js.map +1 -0
- package/esm/chart/registries/ChartComponentRegistrySingleton.js +32 -0
- package/esm/chart/registries/ChartComponentRegistrySingleton.js.map +1 -0
- package/esm/chart/registries/ChartControlPanelRegistrySingleton.js +35 -0
- package/esm/chart/registries/ChartControlPanelRegistrySingleton.js.map +1 -0
- package/esm/chart/registries/ChartMetadataRegistrySingleton.js +32 -0
- package/esm/chart/registries/ChartMetadataRegistrySingleton.js.map +1 -0
- package/esm/chart/registries/ChartTransformPropsRegistrySingleton.js +35 -0
- package/esm/chart/registries/ChartTransformPropsRegistrySingleton.js.map +1 -0
- package/esm/chart/types/Annotation.js +1 -0
- package/esm/chart/types/Annotation.js.map +1 -0
- package/esm/chart/types/Base.js +108 -0
- package/esm/chart/types/Base.js.map +1 -0
- package/esm/chart/types/QueryResponse.js +53 -0
- package/esm/chart/types/QueryResponse.js.map +1 -0
- package/esm/chart/types/TransformFunction.js +55 -0
- package/esm/chart/types/TransformFunction.js.map +1 -0
- package/esm/chart/types/VizType.js +20 -0
- package/esm/chart/types/VizType.js.map +1 -0
- package/esm/chart-composition/ChartFrame.js +75 -0
- package/esm/chart-composition/ChartFrame.js.map +1 -0
- package/esm/chart-composition/index.js +24 -0
- package/esm/chart-composition/index.js.map +1 -0
- package/esm/chart-composition/legend/WithLegend.js +147 -0
- package/esm/chart-composition/legend/WithLegend.js.map +1 -0
- package/esm/chart-composition/tooltip/TooltipFrame.js +48 -0
- package/esm/chart-composition/tooltip/TooltipFrame.js.map +1 -0
- package/esm/chart-composition/tooltip/TooltipTable.js +70 -0
- package/esm/chart-composition/tooltip/TooltipTable.js.map +1 -0
- package/esm/color/CategoricalColorNamespace.js +122 -0
- package/esm/color/CategoricalColorNamespace.js.map +1 -0
- package/esm/color/CategoricalColorScale.js +375 -0
- package/esm/color/CategoricalColorScale.js.map +1 -0
- package/esm/color/CategoricalScheme.js +23 -0
- package/esm/color/CategoricalScheme.js.map +1 -0
- package/esm/color/CategoricalSchemeRegistrySingleton.js +36 -0
- package/esm/color/CategoricalSchemeRegistrySingleton.js.map +1 -0
- package/esm/color/ColorScheme.js +60 -0
- package/esm/color/ColorScheme.js.map +1 -0
- package/esm/color/ColorSchemeRegistry.js +44 -0
- package/esm/color/ColorSchemeRegistry.js.map +1 -0
- package/esm/color/LabelsColorMapSingleton.js +177 -0
- package/esm/color/LabelsColorMapSingleton.js.map +1 -0
- package/esm/color/SequentialScheme.js +97 -0
- package/esm/color/SequentialScheme.js.map +1 -0
- package/esm/color/SequentialSchemeRegistrySingleton.js +36 -0
- package/esm/color/SequentialSchemeRegistrySingleton.js.map +1 -0
- package/esm/color/colorSchemes/categorical/airbnb.js +46 -0
- package/esm/color/colorSchemes/categorical/airbnb.js.map +1 -0
- package/esm/color/colorSchemes/categorical/blueToGreen.js +45 -0
- package/esm/color/colorSchemes/categorical/blueToGreen.js.map +1 -0
- package/esm/color/colorSchemes/categorical/colorsOfRainbow.js +47 -0
- package/esm/color/colorSchemes/categorical/colorsOfRainbow.js.map +1 -0
- package/esm/color/colorSchemes/categorical/d3.js +121 -0
- package/esm/color/colorSchemes/categorical/d3.js.map +1 -0
- package/esm/color/colorSchemes/categorical/echarts.js +59 -0
- package/esm/color/colorSchemes/categorical/echarts.js.map +1 -0
- package/esm/color/colorSchemes/categorical/google.js +69 -0
- package/esm/color/colorSchemes/categorical/google.js.map +1 -0
- package/esm/color/colorSchemes/categorical/index.js +33 -0
- package/esm/color/colorSchemes/categorical/index.js.map +1 -0
- package/esm/color/colorSchemes/categorical/lyft.js +43 -0
- package/esm/color/colorSchemes/categorical/lyft.js.map +1 -0
- package/esm/color/colorSchemes/categorical/modernSunset.js +47 -0
- package/esm/color/colorSchemes/categorical/modernSunset.js.map +1 -0
- package/esm/color/colorSchemes/categorical/preset.js +57 -0
- package/esm/color/colorSchemes/categorical/preset.js.map +1 -0
- package/esm/color/colorSchemes/categorical/presetAndSuperset.js +47 -0
- package/esm/color/colorSchemes/categorical/presetAndSuperset.js.map +1 -0
- package/esm/color/colorSchemes/categorical/redToYellow.js +45 -0
- package/esm/color/colorSchemes/categorical/redToYellow.js.map +1 -0
- package/esm/color/colorSchemes/categorical/superset.js +57 -0
- package/esm/color/colorSchemes/categorical/superset.js.map +1 -0
- package/esm/color/colorSchemes/categorical/wavesOfBlue.js +45 -0
- package/esm/color/colorSchemes/categorical/wavesOfBlue.js.map +1 -0
- package/esm/color/colorSchemes/index.js +22 -0
- package/esm/color/colorSchemes/index.js.map +1 -0
- package/esm/color/colorSchemes/sequential/common.js +229 -0
- package/esm/color/colorSchemes/sequential/common.js.map +1 -0
- package/esm/color/colorSchemes/sequential/d3.js +530 -0
- package/esm/color/colorSchemes/sequential/d3.js.map +1 -0
- package/esm/color/colorSchemes/sequential/index.js +22 -0
- package/esm/color/colorSchemes/sequential/index.js.map +1 -0
- package/esm/color/index.js +43 -0
- package/esm/color/index.js.map +1 -0
- package/esm/color/stringifyAndTrim.js +27 -0
- package/esm/color/stringifyAndTrim.js.map +1 -0
- package/esm/color/types.js +36 -0
- package/esm/color/types.js.map +1 -0
- package/esm/color/utils.js +123 -0
- package/esm/color/utils.js.map +1 -0
- package/esm/components/SafeMarkdown.js +90 -0
- package/esm/components/SafeMarkdown.js.map +1 -0
- package/esm/components/constants.js +29 -0
- package/esm/components/constants.js.map +1 -0
- package/esm/components/index.js +22 -0
- package/esm/components/index.js.map +1 -0
- package/esm/connection/README.md +106 -0
- package/esm/connection/SupersetClient.js +56 -0
- package/esm/connection/SupersetClient.js.map +1 -0
- package/esm/connection/SupersetClientClass.js +279 -0
- package/esm/connection/SupersetClientClass.js.map +1 -0
- package/esm/connection/callApi/callApi.js +182 -0
- package/esm/connection/callApi/callApi.js.map +1 -0
- package/esm/connection/callApi/callApiAndParseWithTimeout.js +40 -0
- package/esm/connection/callApi/callApiAndParseWithTimeout.js.map +1 -0
- package/esm/connection/callApi/index.js +21 -0
- package/esm/connection/callApi/index.js.map +1 -0
- package/esm/connection/callApi/parseResponse.js +81 -0
- package/esm/connection/callApi/parseResponse.js.map +1 -0
- package/esm/connection/callApi/rejectAfterTimeout.js +35 -0
- package/esm/connection/callApi/rejectAfterTimeout.js.map +1 -0
- package/esm/connection/constants.js +42 -0
- package/esm/connection/constants.js.map +1 -0
- package/esm/connection/index.js +27 -0
- package/esm/connection/index.js.map +1 -0
- package/esm/connection/types.js +170 -0
- package/esm/connection/types.js.map +1 -0
- package/esm/currency-format/CurrencyFormatter.js +80 -0
- package/esm/currency-format/CurrencyFormatter.js.map +1 -0
- package/esm/currency-format/index.js +23 -0
- package/esm/currency-format/index.js.map +1 -0
- package/esm/currency-format/utils.js +100 -0
- package/esm/currency-format/utils.js.map +1 -0
- package/esm/dimension/computeMaxFontSize.js +95 -0
- package/esm/dimension/computeMaxFontSize.js.map +1 -0
- package/esm/dimension/getMultipleTextDimensions.js +85 -0
- package/esm/dimension/getMultipleTextDimensions.js.map +1 -0
- package/esm/dimension/getTextDimension.js +62 -0
- package/esm/dimension/getTextDimension.js.map +1 -0
- package/esm/dimension/index.js +28 -0
- package/esm/dimension/index.js.map +1 -0
- package/esm/dimension/mergeMargin.js +48 -0
- package/esm/dimension/mergeMargin.js.map +1 -0
- package/esm/dimension/parseLength.js +42 -0
- package/esm/dimension/parseLength.js.map +1 -0
- package/esm/dimension/svg/LazyFactory.js +61 -0
- package/esm/dimension/svg/LazyFactory.js.map +1 -0
- package/esm/dimension/svg/constants.js +22 -0
- package/esm/dimension/svg/constants.js.map +1 -0
- package/esm/dimension/svg/createHiddenSvgNode.js +34 -0
- package/esm/dimension/svg/createHiddenSvgNode.js.map +1 -0
- package/esm/dimension/svg/createTextNode.js +25 -0
- package/esm/dimension/svg/createTextNode.js.map +1 -0
- package/esm/dimension/svg/factories.js +26 -0
- package/esm/dimension/svg/factories.js.map +1 -0
- package/esm/dimension/svg/getBBoxCeil.js +35 -0
- package/esm/dimension/svg/getBBoxCeil.js.map +1 -0
- package/esm/dimension/svg/updateTextNode.js +72 -0
- package/esm/dimension/svg/updateTextNode.js.map +1 -0
- package/esm/dimension/types.js +42 -0
- package/esm/dimension/types.js.map +1 -0
- package/esm/dynamic-plugins/index.js +21 -0
- package/esm/dynamic-plugins/index.js.map +1 -0
- package/esm/dynamic-plugins/shared-modules.js +98 -0
- package/esm/dynamic-plugins/shared-modules.js.map +1 -0
- package/esm/hooks/index.js +26 -0
- package/esm/hooks/index.js.map +1 -0
- package/esm/hooks/useChangeEffect/index.js +21 -0
- package/esm/hooks/useChangeEffect/index.js.map +1 -0
- package/esm/hooks/useChangeEffect/useChangeEffect.js +39 -0
- package/esm/hooks/useChangeEffect/useChangeEffect.js.map +1 -0
- package/esm/hooks/useChangeEffect/useChangeEffect.test.js +55 -0
- package/esm/hooks/useChangeEffect/useChangeEffect.test.js.map +1 -0
- package/esm/hooks/useComponentDidMount/index.js +21 -0
- package/esm/hooks/useComponentDidMount/index.js.map +1 -0
- package/esm/hooks/useComponentDidMount/useComponentDidMount.js +25 -0
- package/esm/hooks/useComponentDidMount/useComponentDidMount.js.map +1 -0
- package/esm/hooks/useComponentDidMount/useComponentDidMount.test.js +29 -0
- package/esm/hooks/useComponentDidMount/useComponentDidMount.test.js.map +1 -0
- package/esm/hooks/useComponentDidUpdate/index.js +21 -0
- package/esm/hooks/useComponentDidUpdate/index.js.map +1 -0
- package/esm/hooks/useComponentDidUpdate/useComponentDidUpdate.js +36 -0
- package/esm/hooks/useComponentDidUpdate/useComponentDidUpdate.js.map +1 -0
- package/esm/hooks/useComponentDidUpdate/useComponentDidUpdate.test.js +32 -0
- package/esm/hooks/useComponentDidUpdate/useComponentDidUpdate.test.js.map +1 -0
- package/esm/hooks/useElementOnScreen/index.js +21 -0
- package/esm/hooks/useElementOnScreen/index.js.map +1 -0
- package/esm/hooks/useElementOnScreen/useElementOnScreen.js +47 -0
- package/esm/hooks/useElementOnScreen/useElementOnScreen.js.map +1 -0
- package/esm/hooks/useElementOnScreen/useElementOnScreen.test.js +111 -0
- package/esm/hooks/useElementOnScreen/useElementOnScreen.test.js.map +1 -0
- package/esm/hooks/usePrevious/index.js +21 -0
- package/esm/hooks/usePrevious/index.js.map +1 -0
- package/esm/hooks/usePrevious/usePrevious.js +37 -0
- package/esm/hooks/usePrevious/usePrevious.js.map +1 -0
- package/esm/hooks/usePrevious/usePrevious.test.js +44 -0
- package/esm/hooks/usePrevious/usePrevious.test.js.map +1 -0
- package/esm/hooks/useTruncation/index.js +24 -0
- package/esm/hooks/useTruncation/index.js.map +1 -0
- package/esm/hooks/useTruncation/useCSSTextTruncation.js +62 -0
- package/esm/hooks/useTruncation/useCSSTextTruncation.js.map +1 -0
- package/esm/hooks/useTruncation/useCSSTextTruncation.test.js +62 -0
- package/esm/hooks/useTruncation/useCSSTextTruncation.test.js.map +1 -0
- package/esm/hooks/useTruncation/useChildElementTruncation.js +95 -0
- package/esm/hooks/useTruncation/useChildElementTruncation.js.map +1 -0
- package/esm/hooks/useTruncation/useChildElementTruncation.test.js +223 -0
- package/esm/hooks/useTruncation/useChildElementTruncation.test.js.map +1 -0
- package/esm/index.js +41 -0
- package/esm/index.js.map +1 -0
- package/esm/math-expression/index.js +122 -0
- package/esm/math-expression/index.js.map +1 -0
- package/esm/models/ExtensibleFunction.js +31 -0
- package/esm/models/ExtensibleFunction.js.map +1 -0
- package/esm/models/Plugin.js +54 -0
- package/esm/models/Plugin.js.map +1 -0
- package/esm/models/Preset.js +57 -0
- package/esm/models/Preset.js.map +1 -0
- package/esm/models/Registry.js +286 -0
- package/esm/models/Registry.js.map +1 -0
- package/esm/models/RegistryWithDefaultKey.js +95 -0
- package/esm/models/RegistryWithDefaultKey.js.map +1 -0
- package/esm/models/TypedRegistry.js +61 -0
- package/esm/models/TypedRegistry.js.map +1 -0
- package/esm/models/index.js +25 -0
- package/esm/models/index.js.map +1 -0
- package/esm/number-format/D3FormatConfig.js +27 -0
- package/esm/number-format/D3FormatConfig.js.map +1 -0
- package/esm/number-format/NumberFormats.js +90 -0
- package/esm/number-format/NumberFormats.js.map +1 -0
- package/esm/number-format/NumberFormatter.js +87 -0
- package/esm/number-format/NumberFormatter.js.map +1 -0
- package/esm/number-format/NumberFormatterRegistry.js +86 -0
- package/esm/number-format/NumberFormatterRegistry.js.map +1 -0
- package/esm/number-format/NumberFormatterRegistrySingleton.js +41 -0
- package/esm/number-format/NumberFormatterRegistrySingleton.js.map +1 -0
- package/esm/number-format/README.md +82 -0
- package/esm/number-format/factories/createD3NumberFormatter.js +58 -0
- package/esm/number-format/factories/createD3NumberFormatter.js.map +1 -0
- package/esm/number-format/factories/createDurationFormatter.js +41 -0
- package/esm/number-format/factories/createDurationFormatter.js.map +1 -0
- package/esm/number-format/factories/createMemoryFormatter.js +56 -0
- package/esm/number-format/factories/createMemoryFormatter.js.map +1 -0
- package/esm/number-format/factories/createSiAtMostNDigitFormatter.js +46 -0
- package/esm/number-format/factories/createSiAtMostNDigitFormatter.js.map +1 -0
- package/esm/number-format/factories/createSmartNumberFormatter.js +71 -0
- package/esm/number-format/factories/createSmartNumberFormatter.js.map +1 -0
- package/esm/number-format/index.js +37 -0
- package/esm/number-format/index.js.map +1 -0
- package/esm/number-format/types.js +1 -0
- package/esm/number-format/types.js.map +1 -0
- package/esm/query/DatasourceKey.js +45 -0
- package/esm/query/DatasourceKey.js.map +1 -0
- package/esm/query/README.md +30 -0
- package/esm/query/api/legacy/getDatasourceMetadata.js +40 -0
- package/esm/query/api/legacy/getDatasourceMetadata.js.map +1 -0
- package/esm/query/api/legacy/getFormData.js +46 -0
- package/esm/query/api/legacy/getFormData.js.map +1 -0
- package/esm/query/api/legacy/index.js +25 -0
- package/esm/query/api/legacy/index.js.map +1 -0
- package/esm/query/api/legacy/types.js +27 -0
- package/esm/query/api/legacy/types.js.map +1 -0
- package/esm/query/api/types.js +1 -0
- package/esm/query/api/types.js.map +1 -0
- package/esm/query/api/v1/handleError.js +107 -0
- package/esm/query/api/v1/handleError.js.map +1 -0
- package/esm/query/api/v1/index.js +33 -0
- package/esm/query/api/v1/index.js.map +1 -0
- package/esm/query/api/v1/makeApi.js +159 -0
- package/esm/query/api/v1/makeApi.js.map +1 -0
- package/esm/query/api/v1/types.js +142 -0
- package/esm/query/api/v1/types.js.map +1 -0
- package/esm/query/buildQueryContext.js +72 -0
- package/esm/query/buildQueryContext.js.map +1 -0
- package/esm/query/buildQueryObject.js +141 -0
- package/esm/query/buildQueryObject.js.map +1 -0
- package/esm/query/constants.js +60 -0
- package/esm/query/constants.js.map +1 -0
- package/esm/query/convertFilter.js +57 -0
- package/esm/query/convertFilter.js.map +1 -0
- package/esm/query/extractExtras.js +84 -0
- package/esm/query/extractExtras.js.map +1 -0
- package/esm/query/extractQueryFields.js +129 -0
- package/esm/query/extractQueryFields.js.map +1 -0
- package/esm/query/extractTimegrain.js +39 -0
- package/esm/query/extractTimegrain.js.map +1 -0
- package/esm/query/getClientErrorObject.js +304 -0
- package/esm/query/getClientErrorObject.js.map +1 -0
- package/esm/query/getColumnLabel.js +31 -0
- package/esm/query/getColumnLabel.js.map +1 -0
- package/esm/query/getMetricLabel.js +36 -0
- package/esm/query/getMetricLabel.js.map +1 -0
- package/esm/query/getXAxis.js +52 -0
- package/esm/query/getXAxis.js.map +1 -0
- package/esm/query/index.js +48 -0
- package/esm/query/index.js.map +1 -0
- package/esm/query/normalizeOrderBy.js +80 -0
- package/esm/query/normalizeOrderBy.js.map +1 -0
- package/esm/query/normalizeTimeColumn.js +82 -0
- package/esm/query/normalizeTimeColumn.js.map +1 -0
- package/esm/query/processExtraFormData.js +50 -0
- package/esm/query/processExtraFormData.js.map +1 -0
- package/esm/query/processFilters.js +76 -0
- package/esm/query/processFilters.js.map +1 -0
- package/esm/query/types/AdvancedAnalytics.js +44 -0
- package/esm/query/types/AdvancedAnalytics.js.map +1 -0
- package/esm/query/types/AnnotationLayer.js +185 -0
- package/esm/query/types/AnnotationLayer.js.map +1 -0
- package/esm/query/types/Column.js +82 -0
- package/esm/query/types/Column.js.map +1 -0
- package/esm/query/types/Dashboard.js +171 -0
- package/esm/query/types/Dashboard.js.map +1 -0
- package/esm/query/types/Datasource.js +65 -0
- package/esm/query/types/Datasource.js.map +1 -0
- package/esm/query/types/Filter.js +100 -0
- package/esm/query/types/Filter.js.map +1 -0
- package/esm/query/types/Metric.js +98 -0
- package/esm/query/types/Metric.js.map +1 -0
- package/esm/query/types/Operator.js +75 -0
- package/esm/query/types/Operator.js.map +1 -0
- package/esm/query/types/PostProcessing.js +360 -0
- package/esm/query/types/PostProcessing.js.map +1 -0
- package/esm/query/types/Query.js +486 -0
- package/esm/query/types/Query.js.map +1 -0
- package/esm/query/types/QueryFormData.js +212 -0
- package/esm/query/types/QueryFormData.js.map +1 -0
- package/esm/query/types/QueryResponse.js +98 -0
- package/esm/query/types/QueryResponse.js.map +1 -0
- package/esm/query/types/Time.js +40 -0
- package/esm/query/types/Time.js.map +1 -0
- package/esm/query/types/index.js +43 -0
- package/esm/query/types/index.js.map +1 -0
- package/esm/style/index.js +174 -0
- package/esm/style/index.js.map +1 -0
- package/esm/time-comparison/README.md +47 -0
- package/esm/time-comparison/customTimeRangeDecode.js +174 -0
- package/esm/time-comparison/customTimeRangeDecode.js.map +1 -0
- package/esm/time-comparison/fetchTimeRange.js +113 -0
- package/esm/time-comparison/fetchTimeRange.js.map +1 -0
- package/esm/time-comparison/getComparisonFilters.js +68 -0
- package/esm/time-comparison/getComparisonFilters.js.map +1 -0
- package/esm/time-comparison/getComparisonInfo.js +66 -0
- package/esm/time-comparison/getComparisonInfo.js.map +1 -0
- package/esm/time-comparison/getTimeOffset.js +319 -0
- package/esm/time-comparison/getTimeOffset.js.map +1 -0
- package/esm/time-comparison/index.js +31 -0
- package/esm/time-comparison/index.js.map +1 -0
- package/esm/time-comparison/types.js +25 -0
- package/esm/time-comparison/types.js.map +1 -0
- package/esm/time-format/D3FormatConfig.js +66 -0
- package/esm/time-format/D3FormatConfig.js.map +1 -0
- package/esm/time-format/README.md +68 -0
- package/esm/time-format/TimeFormats.js +39 -0
- package/esm/time-format/TimeFormats.js.map +1 -0
- package/esm/time-format/TimeFormatsForGranularity.js +50 -0
- package/esm/time-format/TimeFormatsForGranularity.js.map +1 -0
- package/esm/time-format/TimeFormatter.js +77 -0
- package/esm/time-format/TimeFormatter.js.map +1 -0
- package/esm/time-format/TimeFormatterRegistry.js +78 -0
- package/esm/time-format/TimeFormatterRegistry.js.map +1 -0
- package/esm/time-format/TimeFormatterRegistrySingleton.js +92 -0
- package/esm/time-format/TimeFormatterRegistrySingleton.js.map +1 -0
- package/esm/time-format/TimeRangeFormatter.js +69 -0
- package/esm/time-format/TimeRangeFormatter.js.map +1 -0
- package/esm/time-format/factories/createD3TimeFormatter.js +65 -0
- package/esm/time-format/factories/createD3TimeFormatter.js.map +1 -0
- package/esm/time-format/factories/createMultiFormatter.js +124 -0
- package/esm/time-format/factories/createMultiFormatter.js.map +1 -0
- package/esm/time-format/formatters/finestTemporalGrain.js +81 -0
- package/esm/time-format/formatters/finestTemporalGrain.js.map +1 -0
- package/esm/time-format/formatters/finestTemporalGrain.test.js +64 -0
- package/esm/time-format/formatters/finestTemporalGrain.test.js.map +1 -0
- package/esm/time-format/formatters/smartDate.js +42 -0
- package/esm/time-format/formatters/smartDate.js.map +1 -0
- package/esm/time-format/formatters/smartDateDetailed.js +44 -0
- package/esm/time-format/formatters/smartDateDetailed.js.map +1 -0
- package/esm/time-format/formatters/smartDateVerbose.js +42 -0
- package/esm/time-format/formatters/smartDateVerbose.js.map +1 -0
- package/esm/time-format/index.js +54 -0
- package/esm/time-format/index.js.map +1 -0
- package/esm/time-format/types.js +48 -0
- package/esm/time-format/types.js.map +1 -0
- package/esm/time-format/utils/createTime.js +41 -0
- package/esm/time-format/utils/createTime.js.map +1 -0
- package/esm/time-format/utils/createTimeRangeFromGranularity.js +112 -0
- package/esm/time-format/utils/createTimeRangeFromGranularity.js.map +1 -0
- package/esm/time-format/utils/d3Time.js +142 -0
- package/esm/time-format/utils/d3Time.js.map +1 -0
- package/esm/time-format/utils/denormalizeTimestamp.js +29 -0
- package/esm/time-format/utils/denormalizeTimestamp.js.map +1 -0
- package/esm/time-format/utils/normalizeTimestamp.js +29 -0
- package/esm/time-format/utils/normalizeTimestamp.js.map +1 -0
- package/esm/time-format/utils/stringifyTimeInput.js +30 -0
- package/esm/time-format/utils/stringifyTimeInput.js.map +1 -0
- package/esm/translation/README.md +71 -0
- package/esm/translation/Translator.js +106 -0
- package/esm/translation/Translator.js.map +1 -0
- package/esm/translation/TranslatorSingleton.js +82 -0
- package/esm/translation/TranslatorSingleton.js.map +1 -0
- package/esm/translation/index.js +26 -0
- package/esm/translation/index.js.map +1 -0
- package/esm/translation/types/index.js +74 -0
- package/esm/translation/types/index.js.map +1 -0
- package/esm/translation/types/jed.js +57 -0
- package/esm/translation/types/jed.js.map +1 -0
- package/esm/types/index.js +23 -0
- package/esm/types/index.js.map +1 -0
- package/esm/ui-overrides/ExtensionsRegistry.js +32 -0
- package/esm/ui-overrides/ExtensionsRegistry.js.map +1 -0
- package/esm/ui-overrides/index.js +21 -0
- package/esm/ui-overrides/index.js.map +1 -0
- package/esm/ui-overrides/types.js +1 -0
- package/esm/ui-overrides/types.js.map +1 -0
- package/esm/utils/convertKeysToCamelCase.js +34 -0
- package/esm/utils/convertKeysToCamelCase.js.map +1 -0
- package/esm/utils/ensureIsArray.js +30 -0
- package/esm/utils/ensureIsArray.js.map +1 -0
- package/esm/utils/ensureIsInt.js +28 -0
- package/esm/utils/ensureIsInt.js.map +1 -0
- package/esm/utils/featureFlags.js +105 -0
- package/esm/utils/featureFlags.js.map +1 -0
- package/esm/utils/getSelectedText.js +20 -0
- package/esm/utils/getSelectedText.js.map +1 -0
- package/esm/utils/html.js +122 -0
- package/esm/utils/html.js.map +1 -0
- package/esm/utils/html.test.js +192 -0
- package/esm/utils/html.test.js.map +1 -0
- package/esm/utils/index.js +36 -0
- package/esm/utils/index.js.map +1 -0
- package/esm/utils/isDefined.js +23 -0
- package/esm/utils/isDefined.js.map +1 -0
- package/esm/utils/isEqualArray.js +34 -0
- package/esm/utils/isEqualArray.js.map +1 -0
- package/esm/utils/isEqualArray.test.js +32 -0
- package/esm/utils/isEqualArray.test.js.map +1 -0
- package/esm/utils/isRequired.js +23 -0
- package/esm/utils/isRequired.js.map +1 -0
- package/esm/utils/logging.js +39 -0
- package/esm/utils/logging.js.map +1 -0
- package/esm/utils/lruCache.js +75 -0
- package/esm/utils/lruCache.js.map +1 -0
- package/esm/utils/makeSingleton.js +38 -0
- package/esm/utils/makeSingleton.js.map +1 -0
- package/esm/utils/promiseTimeout.js +33 -0
- package/esm/utils/promiseTimeout.js.map +1 -0
- package/esm/utils/random.js +28 -0
- package/esm/utils/random.js.map +1 -0
- package/esm/utils/removeDuplicates.js +39 -0
- package/esm/utils/removeDuplicates.js.map +1 -0
- package/esm/utils/tooltip.js +58 -0
- package/esm/utils/tooltip.js.map +1 -0
- package/esm/utils/typedMemo.js +22 -0
- package/esm/utils/typedMemo.js.map +1 -0
- package/esm/validator/index.js +28 -0
- package/esm/validator/index.js.map +1 -0
- package/esm/validator/legacyValidateInteger.js +35 -0
- package/esm/validator/legacyValidateInteger.js.map +1 -0
- package/esm/validator/legacyValidateNumber.js +32 -0
- package/esm/validator/legacyValidateNumber.js.map +1 -0
- package/esm/validator/validateInteger.js +34 -0
- package/esm/validator/validateInteger.js.map +1 -0
- package/esm/validator/validateMapboxStylesUrl.js +37 -0
- package/esm/validator/validateMapboxStylesUrl.js.map +1 -0
- package/esm/validator/validateMaxValue.js +27 -0
- package/esm/validator/validateMaxValue.js.map +1 -0
- package/esm/validator/validateNonEmpty.js +33 -0
- package/esm/validator/validateNonEmpty.js.map +1 -0
- package/esm/validator/validateNumber.js +34 -0
- package/esm/validator/validateNumber.js.map +1 -0
- package/esm/validator/validateTimeComparisonRangeValues.js +38 -0
- package/esm/validator/validateTimeComparisonRangeValues.js.map +1 -0
- package/lib/api/index.js +1 -0
- package/lib/api/types/core.d.ts +30 -0
- package/lib/api/types/core.d.ts.map +1 -0
- package/lib/api/types/core.js +19 -0
- package/lib/api/types/core.js.map +1 -0
- package/lib/chart/clients/ChartClient.d.ts +34 -0
- package/lib/chart/clients/ChartClient.d.ts.map +1 -0
- package/lib/chart/clients/ChartClient.js +119 -0
- package/lib/chart/clients/ChartClient.js.map +1 -0
- package/lib/chart/components/ChartDataProvider.d.ts +52 -0
- package/lib/chart/components/ChartDataProvider.d.ts.map +1 -0
- package/lib/chart/components/ChartDataProvider.js +171 -0
- package/lib/chart/components/ChartDataProvider.js.map +1 -0
- package/lib/chart/components/ChartDataProvider.jsx +97 -0
- package/lib/chart/components/ChartDataProvider.jsx.map +1 -0
- package/lib/chart/components/FallbackComponent.d.ts +5 -0
- package/lib/chart/components/FallbackComponent.d.ts.map +1 -0
- package/lib/chart/components/FallbackComponent.js +61 -0
- package/lib/chart/components/FallbackComponent.js.map +1 -0
- package/lib/chart/components/FallbackComponent.jsx +41 -0
- package/lib/chart/components/FallbackComponent.jsx.map +1 -0
- package/lib/chart/components/NoResultsComponent.d.ts +9 -0
- package/lib/chart/components/NoResultsComponent.d.ts.map +1 -0
- package/lib/chart/components/NoResultsComponent.js +88 -0
- package/lib/chart/components/NoResultsComponent.js.map +1 -0
- package/lib/chart/components/NoResultsComponent.jsx +57 -0
- package/lib/chart/components/NoResultsComponent.jsx.map +1 -0
- package/lib/chart/components/SuperChart.d.ts +108 -0
- package/lib/chart/components/SuperChart.d.ts.map +1 -0
- package/lib/chart/components/SuperChart.js +267 -0
- package/lib/chart/components/SuperChart.js.map +1 -0
- package/lib/chart/components/SuperChart.jsx +121 -0
- package/lib/chart/components/SuperChart.jsx.map +1 -0
- package/lib/chart/components/SuperChartCore.d.ts +59 -0
- package/lib/chart/components/SuperChartCore.d.ts.map +1 -0
- package/lib/chart/components/SuperChartCore.js +236 -0
- package/lib/chart/components/SuperChartCore.js.map +1 -0
- package/lib/chart/components/SuperChartCore.jsx +139 -0
- package/lib/chart/components/SuperChartCore.jsx.map +1 -0
- package/lib/chart/components/createLoadableRenderer.d.ts +12 -0
- package/lib/chart/components/createLoadableRenderer.d.ts.map +1 -0
- package/lib/chart/components/createLoadableRenderer.js +52 -0
- package/lib/chart/components/createLoadableRenderer.js.map +1 -0
- package/lib/chart/components/reactify.d.ts +16 -0
- package/lib/chart/components/reactify.d.ts.map +1 -0
- package/lib/chart/components/reactify.js +115 -0
- package/lib/chart/components/reactify.js.map +1 -0
- package/lib/chart/components/reactify.jsx +69 -0
- package/lib/chart/components/reactify.jsx.map +1 -0
- package/lib/chart/index.d.ts +24 -0
- package/lib/chart/index.d.ts.map +1 -0
- package/lib/chart/index.js +40 -0
- package/lib/chart/index.js.map +1 -0
- package/lib/chart/models/ChartControlPanel.d.ts +4 -0
- package/lib/chart/models/ChartControlPanel.d.ts.map +1 -0
- package/lib/chart/models/ChartControlPanel.js +20 -0
- package/lib/chart/models/ChartControlPanel.js.map +1 -0
- package/lib/chart/models/ChartMetadata.d.ts +57 -0
- package/lib/chart/models/ChartMetadata.d.ts.map +1 -0
- package/lib/chart/models/ChartMetadata.js +74 -0
- package/lib/chart/models/ChartMetadata.js.map +1 -0
- package/lib/chart/models/ChartPlugin.d.ts +44 -0
- package/lib/chart/models/ChartPlugin.d.ts.map +1 -0
- package/lib/chart/models/ChartPlugin.js +92 -0
- package/lib/chart/models/ChartPlugin.js.map +1 -0
- package/lib/chart/models/ChartProps.d.ts +99 -0
- package/lib/chart/models/ChartProps.d.ts.map +1 -0
- package/lib/chart/models/ChartProps.js +95 -0
- package/lib/chart/models/ChartProps.js.map +1 -0
- package/lib/chart/registries/ChartBuildQueryRegistrySingleton.d.ts +17 -0
- package/lib/chart/registries/ChartBuildQueryRegistrySingleton.d.ts.map +1 -0
- package/lib/chart/registries/ChartBuildQueryRegistrySingleton.js +27 -0
- package/lib/chart/registries/ChartBuildQueryRegistrySingleton.js.map +1 -0
- package/lib/chart/registries/ChartComponentRegistrySingleton.d.ts +8 -0
- package/lib/chart/registries/ChartComponentRegistrySingleton.d.ts.map +1 -0
- package/lib/chart/registries/ChartComponentRegistrySingleton.js +27 -0
- package/lib/chart/registries/ChartComponentRegistrySingleton.js.map +1 -0
- package/lib/chart/registries/ChartControlPanelRegistrySingleton.d.ts +8 -0
- package/lib/chart/registries/ChartControlPanelRegistrySingleton.d.ts.map +1 -0
- package/lib/chart/registries/ChartControlPanelRegistrySingleton.js +27 -0
- package/lib/chart/registries/ChartControlPanelRegistrySingleton.js.map +1 -0
- package/lib/chart/registries/ChartMetadataRegistrySingleton.d.ts +8 -0
- package/lib/chart/registries/ChartMetadataRegistrySingleton.d.ts.map +1 -0
- package/lib/chart/registries/ChartMetadataRegistrySingleton.js +27 -0
- package/lib/chart/registries/ChartMetadataRegistrySingleton.js.map +1 -0
- package/lib/chart/registries/ChartTransformPropsRegistrySingleton.d.ts +8 -0
- package/lib/chart/registries/ChartTransformPropsRegistrySingleton.d.ts.map +1 -0
- package/lib/chart/registries/ChartTransformPropsRegistrySingleton.js +30 -0
- package/lib/chart/registries/ChartTransformPropsRegistrySingleton.js.map +1 -0
- package/lib/chart/types/Annotation.d.ts +5 -0
- package/lib/chart/types/Annotation.d.ts.map +1 -0
- package/lib/chart/types/Annotation.js +20 -0
- package/lib/chart/types/Annotation.js.map +1 -0
- package/lib/chart/types/Base.d.ts +67 -0
- package/lib/chart/types/Base.d.ts.map +1 -0
- package/lib/chart/types/Base.js +63 -0
- package/lib/chart/types/Base.js.map +1 -0
- package/lib/chart/types/QueryResponse.d.ts +25 -0
- package/lib/chart/types/QueryResponse.d.ts.map +1 -0
- package/lib/chart/types/QueryResponse.js +20 -0
- package/lib/chart/types/QueryResponse.js.map +1 -0
- package/lib/chart/types/TransformFunction.d.ts +21 -0
- package/lib/chart/types/TransformFunction.d.ts.map +1 -0
- package/lib/chart/types/TransformFunction.js +20 -0
- package/lib/chart/types/TransformFunction.js.map +1 -0
- package/lib/chart/types/VizType.d.ts +55 -0
- package/lib/chart/types/VizType.d.ts.map +1 -0
- package/lib/chart/types/VizType.js +74 -0
- package/lib/chart/types/VizType.js.map +1 -0
- package/lib/chart-composition/ChartFrame.d.ts +19 -0
- package/lib/chart-composition/ChartFrame.d.ts.map +1 -0
- package/lib/chart-composition/ChartFrame.js +76 -0
- package/lib/chart-composition/ChartFrame.js.map +1 -0
- package/lib/chart-composition/ChartFrame.jsx +48 -0
- package/lib/chart-composition/ChartFrame.jsx.map +1 -0
- package/lib/chart-composition/index.d.ts +5 -0
- package/lib/chart-composition/index.d.ts.map +1 -0
- package/lib/chart-composition/index.js +23 -0
- package/lib/chart-composition/index.js.map +1 -0
- package/lib/chart-composition/legend/WithLegend.d.ts +35 -0
- package/lib/chart-composition/legend/WithLegend.d.ts.map +1 -0
- package/lib/chart-composition/legend/WithLegend.js +147 -0
- package/lib/chart-composition/legend/WithLegend.js.map +1 -0
- package/lib/chart-composition/legend/WithLegend.jsx +105 -0
- package/lib/chart-composition/legend/WithLegend.jsx.map +1 -0
- package/lib/chart-composition/tooltip/TooltipFrame.d.ts +16 -0
- package/lib/chart-composition/tooltip/TooltipFrame.d.ts.map +1 -0
- package/lib/chart-composition/tooltip/TooltipFrame.js +48 -0
- package/lib/chart-composition/tooltip/TooltipFrame.js.map +1 -0
- package/lib/chart-composition/tooltip/TooltipFrame.jsx +34 -0
- package/lib/chart-composition/tooltip/TooltipFrame.jsx.map +1 -0
- package/lib/chart-composition/tooltip/TooltipTable.d.ts +25 -0
- package/lib/chart-composition/tooltip/TooltipTable.d.ts.map +1 -0
- package/lib/chart-composition/tooltip/TooltipTable.js +71 -0
- package/lib/chart-composition/tooltip/TooltipTable.js.map +1 -0
- package/lib/chart-composition/tooltip/TooltipTable.jsx +43 -0
- package/lib/chart-composition/tooltip/TooltipTable.jsx.map +1 -0
- package/lib/color/CategoricalColorNamespace.d.ts +32 -0
- package/lib/color/CategoricalColorNamespace.d.ts.map +1 -0
- package/lib/color/CategoricalColorNamespace.js +91 -0
- package/lib/color/CategoricalColorNamespace.js.map +1 -0
- package/lib/color/CategoricalColorScale.d.ts +132 -0
- package/lib/color/CategoricalColorScale.d.ts.map +1 -0
- package/lib/color/CategoricalColorScale.js +255 -0
- package/lib/color/CategoricalColorScale.js.map +1 -0
- package/lib/color/CategoricalScheme.d.ts +4 -0
- package/lib/color/CategoricalScheme.d.ts.map +1 -0
- package/lib/color/CategoricalScheme.js +22 -0
- package/lib/color/CategoricalScheme.js.map +1 -0
- package/lib/color/CategoricalSchemeRegistrySingleton.d.ts +8 -0
- package/lib/color/CategoricalSchemeRegistrySingleton.d.ts.map +1 -0
- package/lib/color/CategoricalSchemeRegistrySingleton.js +30 -0
- package/lib/color/CategoricalSchemeRegistrySingleton.js.map +1 -0
- package/lib/color/ColorScheme.d.ts +19 -0
- package/lib/color/ColorScheme.d.ts.map +1 -0
- package/lib/color/ColorScheme.js +35 -0
- package/lib/color/ColorScheme.js.map +1 -0
- package/lib/color/ColorSchemeRegistry.d.ts +6 -0
- package/lib/color/ColorSchemeRegistry.d.ts.map +1 -0
- package/lib/color/ColorSchemeRegistry.js +40 -0
- package/lib/color/ColorSchemeRegistry.js.map +1 -0
- package/lib/color/LabelsColorMapSingleton.d.ts +58 -0
- package/lib/color/LabelsColorMapSingleton.d.ts.map +1 -0
- package/lib/color/LabelsColorMapSingleton.js +141 -0
- package/lib/color/LabelsColorMapSingleton.js.map +1 -0
- package/lib/color/SequentialScheme.d.ts +30 -0
- package/lib/color/SequentialScheme.d.ts.map +1 -0
- package/lib/color/SequentialScheme.js +67 -0
- package/lib/color/SequentialScheme.js.map +1 -0
- package/lib/color/SequentialSchemeRegistrySingleton.d.ts +8 -0
- package/lib/color/SequentialSchemeRegistrySingleton.d.ts.map +1 -0
- package/lib/color/SequentialSchemeRegistrySingleton.js +30 -0
- package/lib/color/SequentialSchemeRegistrySingleton.js.map +1 -0
- package/lib/color/colorSchemes/categorical/airbnb.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/airbnb.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/airbnb.js +43 -0
- package/lib/color/colorSchemes/categorical/airbnb.js.map +1 -0
- package/lib/color/colorSchemes/categorical/blueToGreen.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/blueToGreen.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/blueToGreen.js +42 -0
- package/lib/color/colorSchemes/categorical/blueToGreen.js.map +1 -0
- package/lib/color/colorSchemes/categorical/colorsOfRainbow.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/colorsOfRainbow.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/colorsOfRainbow.js +44 -0
- package/lib/color/colorSchemes/categorical/colorsOfRainbow.js.map +1 -0
- package/lib/color/colorSchemes/categorical/d3.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/d3.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/d3.js +118 -0
- package/lib/color/colorSchemes/categorical/d3.js.map +1 -0
- package/lib/color/colorSchemes/categorical/echarts.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/echarts.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/echarts.js +56 -0
- package/lib/color/colorSchemes/categorical/echarts.js.map +1 -0
- package/lib/color/colorSchemes/categorical/google.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/google.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/google.js +66 -0
- package/lib/color/colorSchemes/categorical/google.js.map +1 -0
- package/lib/color/colorSchemes/categorical/index.d.ts +14 -0
- package/lib/color/colorSchemes/categorical/index.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/index.js +32 -0
- package/lib/color/colorSchemes/categorical/index.js.map +1 -0
- package/lib/color/colorSchemes/categorical/lyft.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/lyft.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/lyft.js +40 -0
- package/lib/color/colorSchemes/categorical/lyft.js.map +1 -0
- package/lib/color/colorSchemes/categorical/modernSunset.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/modernSunset.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/modernSunset.js +44 -0
- package/lib/color/colorSchemes/categorical/modernSunset.js.map +1 -0
- package/lib/color/colorSchemes/categorical/preset.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/preset.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/preset.js +54 -0
- package/lib/color/colorSchemes/categorical/preset.js.map +1 -0
- package/lib/color/colorSchemes/categorical/presetAndSuperset.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/presetAndSuperset.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/presetAndSuperset.js +44 -0
- package/lib/color/colorSchemes/categorical/presetAndSuperset.js.map +1 -0
- package/lib/color/colorSchemes/categorical/redToYellow.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/redToYellow.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/redToYellow.js +42 -0
- package/lib/color/colorSchemes/categorical/redToYellow.js.map +1 -0
- package/lib/color/colorSchemes/categorical/superset.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/superset.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/superset.js +54 -0
- package/lib/color/colorSchemes/categorical/superset.js.map +1 -0
- package/lib/color/colorSchemes/categorical/wavesOfBlue.d.ts +4 -0
- package/lib/color/colorSchemes/categorical/wavesOfBlue.d.ts.map +1 -0
- package/lib/color/colorSchemes/categorical/wavesOfBlue.js +42 -0
- package/lib/color/colorSchemes/categorical/wavesOfBlue.js.map +1 -0
- package/lib/color/colorSchemes/index.d.ts +3 -0
- package/lib/color/colorSchemes/index.d.ts.map +1 -0
- package/lib/color/colorSchemes/index.js +21 -0
- package/lib/color/colorSchemes/index.js.map +1 -0
- package/lib/color/colorSchemes/sequential/common.d.ts +4 -0
- package/lib/color/colorSchemes/sequential/common.d.ts.map +1 -0
- package/lib/color/colorSchemes/sequential/common.js +226 -0
- package/lib/color/colorSchemes/sequential/common.js.map +1 -0
- package/lib/color/colorSchemes/sequential/d3.d.ts +4 -0
- package/lib/color/colorSchemes/sequential/d3.d.ts.map +1 -0
- package/lib/color/colorSchemes/sequential/d3.js +527 -0
- package/lib/color/colorSchemes/sequential/d3.js.map +1 -0
- package/lib/color/colorSchemes/sequential/index.d.ts +3 -0
- package/lib/color/colorSchemes/sequential/index.d.ts.map +1 -0
- package/lib/color/colorSchemes/sequential/index.js +21 -0
- package/lib/color/colorSchemes/sequential/index.js.map +1 -0
- package/lib/color/index.d.ts +18 -0
- package/lib/color/index.d.ts.map +1 -0
- package/lib/color/index.js +36 -0
- package/lib/color/index.js.map +1 -0
- package/lib/color/stringifyAndTrim.d.ts +6 -0
- package/lib/color/stringifyAndTrim.d.ts.map +1 -0
- package/lib/color/stringifyAndTrim.js +26 -0
- package/lib/color/stringifyAndTrim.js.map +1 -0
- package/lib/color/types.d.ts +18 -0
- package/lib/color/types.d.ts.map +1 -0
- package/lib/color/types.js +25 -0
- package/lib/color/types.js.map +1 -0
- package/lib/color/utils.d.ts +6 -0
- package/lib/color/utils.d.ts.map +1 -0
- package/lib/color/utils.js +113 -0
- package/lib/color/utils.js.map +1 -0
- package/lib/components/SafeMarkdown.d.ts +11 -0
- package/lib/components/SafeMarkdown.d.ts.map +1 -0
- package/lib/components/SafeMarkdown.js +90 -0
- package/lib/components/SafeMarkdown.js.map +1 -0
- package/lib/components/SafeMarkdown.jsx +57 -0
- package/lib/components/SafeMarkdown.jsx.map +1 -0
- package/lib/components/constants.d.ts +27 -0
- package/lib/components/constants.d.ts.map +1 -0
- package/lib/components/constants.js +27 -0
- package/lib/components/constants.js.map +1 -0
- package/lib/components/index.d.ts +3 -0
- package/lib/components/index.d.ts.map +1 -0
- package/lib/components/index.js +21 -0
- package/lib/components/index.js.map +1 -0
- package/lib/connection/README.md +106 -0
- package/lib/connection/SupersetClient.d.ts +4 -0
- package/lib/connection/SupersetClient.d.ts.map +1 -0
- package/lib/connection/SupersetClient.js +48 -0
- package/lib/connection/SupersetClient.js.map +1 -0
- package/lib/connection/SupersetClientClass.d.ts +45 -0
- package/lib/connection/SupersetClientClass.d.ts.map +1 -0
- package/lib/connection/SupersetClientClass.js +187 -0
- package/lib/connection/SupersetClientClass.js.map +1 -0
- package/lib/connection/callApi/callApi.d.ts +11 -0
- package/lib/connection/callApi/callApi.d.ts.map +1 -0
- package/lib/connection/callApi/callApi.js +145 -0
- package/lib/connection/callApi/callApi.js.map +1 -0
- package/lib/connection/callApi/callApiAndParseWithTimeout.d.ts +6 -0
- package/lib/connection/callApi/callApiAndParseWithTimeout.d.ts.map +1 -0
- package/lib/connection/callApi/callApiAndParseWithTimeout.js +29 -0
- package/lib/connection/callApi/callApiAndParseWithTimeout.js.map +1 -0
- package/lib/connection/callApi/index.d.ts +2 -0
- package/lib/connection/callApi/index.d.ts.map +1 -0
- package/lib/connection/callApi/index.js +20 -0
- package/lib/connection/callApi/index.js.map +1 -0
- package/lib/connection/callApi/parseResponse.d.ts +3 -0
- package/lib/connection/callApi/parseResponse.d.ts.map +1 -0
- package/lib/connection/callApi/parseResponse.js +63 -0
- package/lib/connection/callApi/parseResponse.js.map +1 -0
- package/lib/connection/callApi/rejectAfterTimeout.d.ts +2 -0
- package/lib/connection/callApi/rejectAfterTimeout.d.ts.map +1 -0
- package/lib/connection/callApi/rejectAfterTimeout.js +31 -0
- package/lib/connection/callApi/rejectAfterTimeout.js.map +1 -0
- package/lib/connection/constants.d.ts +11 -0
- package/lib/connection/constants.d.ts.map +1 -0
- package/lib/connection/constants.js +34 -0
- package/lib/connection/constants.js.map +1 -0
- package/lib/connection/index.d.ts +7 -0
- package/lib/connection/index.d.ts.map +1 -0
- package/lib/connection/index.js +25 -0
- package/lib/connection/index.js.map +1 -0
- package/lib/connection/types.d.ts +132 -0
- package/lib/connection/types.d.ts.map +1 -0
- package/lib/connection/types.js +2 -0
- package/lib/connection/types.js.map +1 -0
- package/lib/currency-format/CurrencyFormatter.d.ts +40 -0
- package/lib/currency-format/CurrencyFormatter.d.ts.map +1 -0
- package/lib/currency-format/CurrencyFormatter.js +55 -0
- package/lib/currency-format/CurrencyFormatter.js.map +1 -0
- package/lib/currency-format/index.d.ts +4 -0
- package/lib/currency-format/index.d.ts.map +1 -0
- package/lib/currency-format/index.js +22 -0
- package/lib/currency-format/index.js.map +1 -0
- package/lib/currency-format/utils.d.ts +23 -0
- package/lib/currency-format/utils.d.ts.map +1 -0
- package/lib/currency-format/utils.js +61 -0
- package/lib/currency-format/utils.js.map +1 -0
- package/lib/dimension/computeMaxFontSize.d.ts +7 -0
- package/lib/dimension/computeMaxFontSize.d.ts.map +1 -0
- package/lib/dimension/computeMaxFontSize.js +64 -0
- package/lib/dimension/computeMaxFontSize.js.map +1 -0
- package/lib/dimension/getMultipleTextDimensions.d.ts +13 -0
- package/lib/dimension/getMultipleTextDimensions.d.ts.map +1 -0
- package/lib/dimension/getMultipleTextDimensions.js +67 -0
- package/lib/dimension/getMultipleTextDimensions.js.map +1 -0
- package/lib/dimension/getTextDimension.d.ts +9 -0
- package/lib/dimension/getTextDimension.d.ts.map +1 -0
- package/lib/dimension/getTextDimension.js +45 -0
- package/lib/dimension/getTextDimension.js.map +1 -0
- package/lib/dimension/index.d.ts +8 -0
- package/lib/dimension/index.d.ts.map +1 -0
- package/lib/dimension/index.js +26 -0
- package/lib/dimension/index.js.map +1 -0
- package/lib/dimension/mergeMargin.d.ts +8 -0
- package/lib/dimension/mergeMargin.d.ts.map +1 -0
- package/lib/dimension/mergeMargin.js +36 -0
- package/lib/dimension/mergeMargin.js.map +1 -0
- package/lib/dimension/parseLength.d.ts +8 -0
- package/lib/dimension/parseLength.d.ts.map +1 -0
- package/lib/dimension/parseLength.js +32 -0
- package/lib/dimension/parseLength.js.map +1 -0
- package/lib/dimension/svg/LazyFactory.d.ts +8 -0
- package/lib/dimension/svg/LazyFactory.d.ts.map +1 -0
- package/lib/dimension/svg/LazyFactory.js +47 -0
- package/lib/dimension/svg/LazyFactory.js.map +1 -0
- package/lib/dimension/svg/constants.d.ts +2 -0
- package/lib/dimension/svg/constants.d.ts.map +1 -0
- package/lib/dimension/svg/constants.js +21 -0
- package/lib/dimension/svg/constants.js.map +1 -0
- package/lib/dimension/svg/createHiddenSvgNode.d.ts +2 -0
- package/lib/dimension/svg/createHiddenSvgNode.d.ts.map +1 -0
- package/lib/dimension/svg/createHiddenSvgNode.js +31 -0
- package/lib/dimension/svg/createHiddenSvgNode.js.map +1 -0
- package/lib/dimension/svg/createTextNode.d.ts +2 -0
- package/lib/dimension/svg/createTextNode.d.ts.map +1 -0
- package/lib/dimension/svg/createTextNode.js +23 -0
- package/lib/dimension/svg/createTextNode.js.map +1 -0
- package/lib/dimension/svg/factories.d.ts +4 -0
- package/lib/dimension/svg/factories.d.ts.map +1 -0
- package/lib/dimension/svg/factories.js +24 -0
- package/lib/dimension/svg/factories.js.map +1 -0
- package/lib/dimension/svg/getBBoxCeil.d.ts +6 -0
- package/lib/dimension/svg/getBBoxCeil.d.ts.map +1 -0
- package/lib/dimension/svg/getBBoxCeil.js +27 -0
- package/lib/dimension/svg/getBBoxCeil.js.map +1 -0
- package/lib/dimension/svg/updateTextNode.d.ts +7 -0
- package/lib/dimension/svg/updateTextNode.d.ts.map +1 -0
- package/lib/dimension/svg/updateTextNode.js +50 -0
- package/lib/dimension/svg/updateTextNode.js.map +1 -0
- package/lib/dimension/types.d.ts +21 -0
- package/lib/dimension/types.d.ts.map +1 -0
- package/lib/dimension/types.js +20 -0
- package/lib/dimension/types.js.map +1 -0
- package/lib/dynamic-plugins/index.d.ts +20 -0
- package/lib/dynamic-plugins/index.d.ts.map +1 -0
- package/lib/dynamic-plugins/index.js +20 -0
- package/lib/dynamic-plugins/index.js.map +1 -0
- package/lib/dynamic-plugins/shared-modules.d.ts +46 -0
- package/lib/dynamic-plugins/shared-modules.d.ts.map +1 -0
- package/lib/dynamic-plugins/shared-modules.js +68 -0
- package/lib/dynamic-plugins/shared-modules.js.map +1 -0
- package/lib/hooks/index.d.ts +25 -0
- package/lib/hooks/index.d.ts.map +1 -0
- package/lib/hooks/index.js +25 -0
- package/lib/hooks/index.js.map +1 -0
- package/lib/hooks/useChangeEffect/index.d.ts +20 -0
- package/lib/hooks/useChangeEffect/index.d.ts.map +1 -0
- package/lib/hooks/useChangeEffect/index.js +20 -0
- package/lib/hooks/useChangeEffect/index.js.map +1 -0
- package/lib/hooks/useChangeEffect/useChangeEffect.d.ts +25 -0
- package/lib/hooks/useChangeEffect/useChangeEffect.d.ts.map +1 -0
- package/lib/hooks/useChangeEffect/useChangeEffect.js +34 -0
- package/lib/hooks/useChangeEffect/useChangeEffect.js.map +1 -0
- package/lib/hooks/useChangeEffect/useChangeEffect.test.d.ts +2 -0
- package/lib/hooks/useChangeEffect/useChangeEffect.test.d.ts.map +1 -0
- package/lib/hooks/useChangeEffect/useChangeEffect.test.js +46 -0
- package/lib/hooks/useChangeEffect/useChangeEffect.test.js.map +1 -0
- package/lib/hooks/useComponentDidMount/index.d.ts +20 -0
- package/lib/hooks/useComponentDidMount/index.d.ts.map +1 -0
- package/lib/hooks/useComponentDidMount/index.js +20 -0
- package/lib/hooks/useComponentDidMount/index.js.map +1 -0
- package/lib/hooks/useComponentDidMount/useComponentDidMount.d.ts +21 -0
- package/lib/hooks/useComponentDidMount/useComponentDidMount.d.ts.map +1 -0
- package/lib/hooks/useComponentDidMount/useComponentDidMount.js +24 -0
- package/lib/hooks/useComponentDidMount/useComponentDidMount.js.map +1 -0
- package/lib/hooks/useComponentDidMount/useComponentDidMount.test.d.ts +2 -0
- package/lib/hooks/useComponentDidMount/useComponentDidMount.test.d.ts.map +1 -0
- package/lib/hooks/useComponentDidMount/useComponentDidMount.test.js +28 -0
- package/lib/hooks/useComponentDidMount/useComponentDidMount.test.js.map +1 -0
- package/lib/hooks/useComponentDidUpdate/index.d.ts +20 -0
- package/lib/hooks/useComponentDidUpdate/index.d.ts.map +1 -0
- package/lib/hooks/useComponentDidUpdate/index.js +20 -0
- package/lib/hooks/useComponentDidUpdate/index.js.map +1 -0
- package/lib/hooks/useComponentDidUpdate/useComponentDidUpdate.d.ts +21 -0
- package/lib/hooks/useComponentDidUpdate/useComponentDidUpdate.d.ts.map +1 -0
- package/lib/hooks/useComponentDidUpdate/useComponentDidUpdate.js +32 -0
- package/lib/hooks/useComponentDidUpdate/useComponentDidUpdate.js.map +1 -0
- package/lib/hooks/useComponentDidUpdate/useComponentDidUpdate.test.d.ts +2 -0
- package/lib/hooks/useComponentDidUpdate/useComponentDidUpdate.test.d.ts.map +1 -0
- package/lib/hooks/useComponentDidUpdate/useComponentDidUpdate.test.js +31 -0
- package/lib/hooks/useComponentDidUpdate/useComponentDidUpdate.test.js.map +1 -0
- package/lib/hooks/useElementOnScreen/index.d.ts +20 -0
- package/lib/hooks/useElementOnScreen/index.d.ts.map +1 -0
- package/lib/hooks/useElementOnScreen/index.js +20 -0
- package/lib/hooks/useElementOnScreen/index.js.map +1 -0
- package/lib/hooks/useElementOnScreen/useElementOnScreen.d.ts +21 -0
- package/lib/hooks/useElementOnScreen/useElementOnScreen.d.ts.map +1 -0
- package/lib/hooks/useElementOnScreen/useElementOnScreen.js +41 -0
- package/lib/hooks/useElementOnScreen/useElementOnScreen.js.map +1 -0
- package/lib/hooks/useElementOnScreen/useElementOnScreen.test.d.ts +2 -0
- package/lib/hooks/useElementOnScreen/useElementOnScreen.test.d.ts.map +1 -0
- package/lib/hooks/useElementOnScreen/useElementOnScreen.test.js +85 -0
- package/lib/hooks/useElementOnScreen/useElementOnScreen.test.js.map +1 -0
- package/lib/hooks/usePrevious/index.d.ts +20 -0
- package/lib/hooks/usePrevious/index.d.ts.map +1 -0
- package/lib/hooks/usePrevious/index.js +20 -0
- package/lib/hooks/usePrevious/index.js.map +1 -0
- package/lib/hooks/usePrevious/usePrevious.d.ts +26 -0
- package/lib/hooks/usePrevious/usePrevious.d.ts.map +1 -0
- package/lib/hooks/usePrevious/usePrevious.js +28 -0
- package/lib/hooks/usePrevious/usePrevious.js.map +1 -0
- package/lib/hooks/usePrevious/usePrevious.test.d.ts +2 -0
- package/lib/hooks/usePrevious/usePrevious.test.d.ts.map +1 -0
- package/lib/hooks/usePrevious/usePrevious.test.js +40 -0
- package/lib/hooks/usePrevious/usePrevious.test.js.map +1 -0
- package/lib/hooks/useTruncation/index.d.ts +22 -0
- package/lib/hooks/useTruncation/index.d.ts.map +1 -0
- package/lib/hooks/useTruncation/index.js +22 -0
- package/lib/hooks/useTruncation/index.js.map +1 -0
- package/lib/hooks/useTruncation/useCSSTextTruncation.d.ts +33 -0
- package/lib/hooks/useTruncation/useCSSTextTruncation.d.ts.map +1 -0
- package/lib/hooks/useTruncation/useCSSTextTruncation.js +52 -0
- package/lib/hooks/useTruncation/useCSSTextTruncation.js.map +1 -0
- package/lib/hooks/useTruncation/useCSSTextTruncation.test.d.ts +2 -0
- package/lib/hooks/useTruncation/useCSSTextTruncation.test.d.ts.map +1 -0
- package/lib/hooks/useTruncation/useCSSTextTruncation.test.js +62 -0
- package/lib/hooks/useTruncation/useCSSTextTruncation.test.js.map +1 -0
- package/lib/hooks/useTruncation/useCSSTextTruncation.test.jsx +48 -0
- package/lib/hooks/useTruncation/useCSSTextTruncation.test.jsx.map +1 -0
- package/lib/hooks/useTruncation/useChildElementTruncation.d.ts +12 -0
- package/lib/hooks/useTruncation/useChildElementTruncation.d.ts.map +1 -0
- package/lib/hooks/useTruncation/useChildElementTruncation.js +86 -0
- package/lib/hooks/useTruncation/useChildElementTruncation.js.map +1 -0
- package/lib/hooks/useTruncation/useChildElementTruncation.test.d.ts +2 -0
- package/lib/hooks/useTruncation/useChildElementTruncation.test.d.ts.map +1 -0
- package/lib/hooks/useTruncation/useChildElementTruncation.test.js +161 -0
- package/lib/hooks/useTruncation/useChildElementTruncation.test.js.map +1 -0
- package/lib/index.d.ts +40 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +40 -0
- package/lib/index.js.map +1 -0
- package/lib/math-expression/index.d.ts +3 -0
- package/lib/math-expression/index.d.ts.map +1 -0
- package/lib/math-expression/index.js +118 -0
- package/lib/math-expression/index.js.map +1 -0
- package/lib/models/ExtensibleFunction.d.ts +7 -0
- package/lib/models/ExtensibleFunction.d.ts.map +1 -0
- package/lib/models/ExtensibleFunction.js +29 -0
- package/lib/models/ExtensibleFunction.js.map +1 -0
- package/lib/models/Plugin.d.ts +13 -0
- package/lib/models/Plugin.d.ts.map +1 -0
- package/lib/models/Plugin.js +41 -0
- package/lib/models/Plugin.js.map +1 -0
- package/lib/models/Preset.d.ts +15 -0
- package/lib/models/Preset.d.ts.map +1 -0
- package/lib/models/Preset.js +41 -0
- package/lib/models/Preset.js.map +1 -0
- package/lib/models/Registry.d.ts +99 -0
- package/lib/models/Registry.d.ts.map +1 -0
- package/lib/models/Registry.js +191 -0
- package/lib/models/Registry.js.map +1 -0
- package/lib/models/RegistryWithDefaultKey.d.ts +20 -0
- package/lib/models/RegistryWithDefaultKey.d.ts.map +1 -0
- package/lib/models/RegistryWithDefaultKey.js +68 -0
- package/lib/models/RegistryWithDefaultKey.js.map +1 -0
- package/lib/models/TypedRegistry.d.ts +47 -0
- package/lib/models/TypedRegistry.d.ts.map +1 -0
- package/lib/models/TypedRegistry.js +55 -0
- package/lib/models/TypedRegistry.js.map +1 -0
- package/lib/models/index.d.ts +25 -0
- package/lib/models/index.d.ts.map +1 -0
- package/lib/models/index.js +25 -0
- package/lib/models/index.js.map +1 -0
- package/lib/number-format/D3FormatConfig.d.ts +21 -0
- package/lib/number-format/D3FormatConfig.d.ts.map +1 -0
- package/lib/number-format/D3FormatConfig.js +7 -0
- package/lib/number-format/D3FormatConfig.js.map +1 -0
- package/lib/number-format/NumberFormats.d.ts +33 -0
- package/lib/number-format/NumberFormats.d.ts.map +1 -0
- package/lib/number-format/NumberFormats.js +80 -0
- package/lib/number-format/NumberFormats.js.map +1 -0
- package/lib/number-format/NumberFormatter.d.ts +43 -0
- package/lib/number-format/NumberFormatter.d.ts.map +1 -0
- package/lib/number-format/NumberFormatter.js +54 -0
- package/lib/number-format/NumberFormatter.js.map +1 -0
- package/lib/number-format/NumberFormatterRegistry.d.ts +29 -0
- package/lib/number-format/NumberFormatterRegistry.d.ts.map +1 -0
- package/lib/number-format/NumberFormatterRegistry.js +43 -0
- package/lib/number-format/NumberFormatterRegistry.js.map +1 -0
- package/lib/number-format/NumberFormatterRegistrySingleton.d.ts +26 -0
- package/lib/number-format/NumberFormatterRegistrySingleton.d.ts.map +1 -0
- package/lib/number-format/NumberFormatterRegistrySingleton.js +14 -0
- package/lib/number-format/NumberFormatterRegistrySingleton.js.map +1 -0
- package/lib/number-format/README.md +82 -0
- package/lib/number-format/factories/createD3NumberFormatter.d.ts +27 -0
- package/lib/number-format/factories/createD3NumberFormatter.d.ts.map +1 -0
- package/lib/number-format/factories/createD3NumberFormatter.js +44 -0
- package/lib/number-format/factories/createD3NumberFormatter.js.map +1 -0
- package/lib/number-format/factories/createDurationFormatter.d.ts +9 -0
- package/lib/number-format/factories/createDurationFormatter.d.ts.map +1 -0
- package/lib/number-format/factories/createDurationFormatter.js +30 -0
- package/lib/number-format/factories/createDurationFormatter.js.map +1 -0
- package/lib/number-format/factories/createMemoryFormatter.d.ts +9 -0
- package/lib/number-format/factories/createMemoryFormatter.d.ts.map +1 -0
- package/lib/number-format/factories/createMemoryFormatter.js +40 -0
- package/lib/number-format/factories/createMemoryFormatter.js.map +1 -0
- package/lib/number-format/factories/createSiAtMostNDigitFormatter.d.ts +8 -0
- package/lib/number-format/factories/createSiAtMostNDigitFormatter.d.ts.map +1 -0
- package/lib/number-format/factories/createSiAtMostNDigitFormatter.js +35 -0
- package/lib/number-format/factories/createSiAtMostNDigitFormatter.js.map +1 -0
- package/lib/number-format/factories/createSmartNumberFormatter.d.ts +8 -0
- package/lib/number-format/factories/createSmartNumberFormatter.d.ts.map +1 -0
- package/lib/number-format/factories/createSmartNumberFormatter.js +58 -0
- package/lib/number-format/factories/createSmartNumberFormatter.js.map +1 -0
- package/lib/number-format/index.d.ts +11 -0
- package/lib/number-format/index.d.ts.map +1 -0
- package/lib/number-format/index.js +29 -0
- package/lib/number-format/index.js.map +1 -0
- package/lib/number-format/types.d.ts +2 -0
- package/lib/number-format/types.d.ts.map +1 -0
- package/lib/number-format/types.js +20 -0
- package/lib/number-format/types.js.map +1 -0
- package/lib/query/DatasourceKey.d.ts +12 -0
- package/lib/query/DatasourceKey.d.ts.map +1 -0
- package/lib/query/DatasourceKey.js +39 -0
- package/lib/query/DatasourceKey.js.map +1 -0
- package/lib/query/README.md +30 -0
- package/lib/query/api/legacy/getDatasourceMetadata.d.ts +7 -0
- package/lib/query/api/legacy/getDatasourceMetadata.d.ts.map +1 -0
- package/lib/query/api/legacy/getDatasourceMetadata.js +28 -0
- package/lib/query/api/legacy/getDatasourceMetadata.js.map +1 -0
- package/lib/query/api/legacy/getFormData.d.ts +8 -0
- package/lib/query/api/legacy/getFormData.d.ts.map +1 -0
- package/lib/query/api/legacy/getFormData.js +31 -0
- package/lib/query/api/legacy/getFormData.js.map +1 -0
- package/lib/query/api/legacy/index.d.ts +5 -0
- package/lib/query/api/legacy/index.d.ts.map +1 -0
- package/lib/query/api/legacy/index.js +23 -0
- package/lib/query/api/legacy/index.js.map +1 -0
- package/lib/query/api/legacy/types.d.ts +25 -0
- package/lib/query/api/legacy/types.d.ts.map +1 -0
- package/lib/query/api/legacy/types.js +2 -0
- package/lib/query/api/legacy/types.js.map +1 -0
- package/lib/query/api/types.d.ts +24 -0
- package/lib/query/api/types.d.ts.map +1 -0
- package/lib/query/api/types.js +2 -0
- package/lib/query/api/types.js.map +1 -0
- package/lib/query/api/v1/handleError.d.ts +26 -0
- package/lib/query/api/v1/handleError.d.ts.map +1 -0
- package/lib/query/api/v1/handleError.js +97 -0
- package/lib/query/api/v1/handleError.js.map +1 -0
- package/lib/query/api/v1/index.d.ts +20 -0
- package/lib/query/api/v1/index.d.ts.map +1 -0
- package/lib/query/api/v1/index.js +30 -0
- package/lib/query/api/v1/index.js.map +1 -0
- package/lib/query/api/v1/makeApi.d.ts +40 -0
- package/lib/query/api/v1/makeApi.d.ts.map +1 -0
- package/lib/query/api/v1/makeApi.js +91 -0
- package/lib/query/api/v1/makeApi.js.map +1 -0
- package/lib/query/api/v1/types.d.ts +80 -0
- package/lib/query/api/v1/types.d.ts.map +1 -0
- package/lib/query/api/v1/types.js +54 -0
- package/lib/query/api/v1/types.js.map +1 -0
- package/lib/query/buildQueryContext.d.ts +14 -0
- package/lib/query/buildQueryContext.d.ts.map +1 -0
- package/lib/query/buildQueryContext.js +50 -0
- package/lib/query/buildQueryContext.js.map +1 -0
- package/lib/query/buildQueryObject.d.ts +11 -0
- package/lib/query/buildQueryObject.d.ts.map +1 -0
- package/lib/query/buildQueryObject.js +89 -0
- package/lib/query/buildQueryObject.js.map +1 -0
- package/lib/query/constants.d.ts +27 -0
- package/lib/query/constants.d.ts.map +1 -0
- package/lib/query/constants.js +24 -0
- package/lib/query/constants.js.map +1 -0
- package/lib/query/convertFilter.d.ts +4 -0
- package/lib/query/convertFilter.d.ts.map +1 -0
- package/lib/query/convertFilter.js +44 -0
- package/lib/query/convertFilter.js.map +1 -0
- package/lib/query/extractExtras.d.ts +16 -0
- package/lib/query/extractExtras.d.ts.map +1 -0
- package/lib/query/extractExtras.js +55 -0
- package/lib/query/extractExtras.js.map +1 -0
- package/lib/query/extractQueryFields.d.ts +11 -0
- package/lib/query/extractQueryFields.d.ts.map +1 -0
- package/lib/query/extractQueryFields.js +105 -0
- package/lib/query/extractQueryFields.js.map +1 -0
- package/lib/query/extractTimegrain.d.ts +22 -0
- package/lib/query/extractTimegrain.d.ts.map +1 -0
- package/lib/query/extractTimegrain.js +31 -0
- package/lib/query/extractTimegrain.js.map +1 -0
- package/lib/query/getClientErrorObject.d.ts +48 -0
- package/lib/query/getClientErrorObject.d.ts.map +1 -0
- package/lib/query/getClientErrorObject.js +226 -0
- package/lib/query/getClientErrorObject.js.map +1 -0
- package/lib/query/getColumnLabel.d.ts +21 -0
- package/lib/query/getColumnLabel.d.ts.map +1 -0
- package/lib/query/getColumnLabel.js +29 -0
- package/lib/query/getColumnLabel.js.map +1 -0
- package/lib/query/getMetricLabel.d.ts +3 -0
- package/lib/query/getMetricLabel.d.ts.map +1 -0
- package/lib/query/getMetricLabel.js +32 -0
- package/lib/query/getMetricLabel.js.map +1 -0
- package/lib/query/getXAxis.d.ts +23 -0
- package/lib/query/getXAxis.d.ts.map +1 -0
- package/lib/query/getXAxis.js +38 -0
- package/lib/query/getXAxis.js.map +1 -0
- package/lib/query/index.d.ts +43 -0
- package/lib/query/index.d.ts.map +1 -0
- package/lib/query/index.js +44 -0
- package/lib/query/index.js.map +1 -0
- package/lib/query/normalizeOrderBy.d.ts +3 -0
- package/lib/query/normalizeOrderBy.d.ts.map +1 -0
- package/lib/query/normalizeOrderBy.js +64 -0
- package/lib/query/normalizeOrderBy.js.map +1 -0
- package/lib/query/normalizeTimeColumn.d.ts +3 -0
- package/lib/query/normalizeTimeColumn.d.ts.map +1 -0
- package/lib/query/normalizeTimeColumn.js +62 -0
- package/lib/query/normalizeTimeColumn.js.map +1 -0
- package/lib/query/processExtraFormData.d.ts +21 -0
- package/lib/query/processExtraFormData.d.ts.map +1 -0
- package/lib/query/processExtraFormData.js +22 -0
- package/lib/query/processExtraFormData.js.map +1 -0
- package/lib/query/processFilters.d.ts +4 -0
- package/lib/query/processFilters.d.ts.map +1 -0
- package/lib/query/processFilters.js +67 -0
- package/lib/query/processFilters.js.map +1 -0
- package/lib/query/types/AdvancedAnalytics.d.ts +42 -0
- package/lib/query/types/AdvancedAnalytics.d.ts.map +1 -0
- package/lib/query/types/AdvancedAnalytics.js +35 -0
- package/lib/query/types/AdvancedAnalytics.js.map +1 -0
- package/lib/query/types/AnnotationLayer.d.ts +110 -0
- package/lib/query/types/AnnotationLayer.d.ts.map +1 -0
- package/lib/query/types/AnnotationLayer.js +68 -0
- package/lib/query/types/AnnotationLayer.js.map +1 -0
- package/lib/query/types/Column.d.ts +61 -0
- package/lib/query/types/Column.d.ts.map +1 -0
- package/lib/query/types/Column.js +33 -0
- package/lib/query/types/Column.js.map +1 -0
- package/lib/query/types/Dashboard.d.ts +120 -0
- package/lib/query/types/Dashboard.d.ts.map +1 -0
- package/lib/query/types/Dashboard.js +48 -0
- package/lib/query/types/Dashboard.js.map +1 -0
- package/lib/query/types/Datasource.d.ts +55 -0
- package/lib/query/types/Datasource.d.ts.map +1 -0
- package/lib/query/types/Datasource.js +16 -0
- package/lib/query/types/Datasource.js.map +1 -0
- package/lib/query/types/Filter.d.ts +35 -0
- package/lib/query/types/Filter.d.ts.map +1 -0
- package/lib/query/types/Filter.js +38 -0
- package/lib/query/types/Filter.js.map +1 -0
- package/lib/query/types/Metric.d.ts +68 -0
- package/lib/query/types/Metric.d.ts.map +1 -0
- package/lib/query/types/Metric.js +16 -0
- package/lib/query/types/Metric.js.map +1 -0
- package/lib/query/types/Operator.d.ts +17 -0
- package/lib/query/types/Operator.d.ts.map +1 -0
- package/lib/query/types/Operator.js +52 -0
- package/lib/query/types/Operator.js.map +1 -0
- package/lib/query/types/PostProcessing.d.ts +208 -0
- package/lib/query/types/PostProcessing.d.ts.map +1 -0
- package/lib/query/types/PostProcessing.js +51 -0
- package/lib/query/types/PostProcessing.js.map +1 -0
- package/lib/query/types/Query.d.ts +384 -0
- package/lib/query/types/Query.d.ts.map +1 -0
- package/lib/query/types/Query.js +233 -0
- package/lib/query/types/Query.js.map +1 -0
- package/lib/query/types/QueryFormData.d.ts +168 -0
- package/lib/query/types/QueryFormData.d.ts.map +1 -0
- package/lib/query/types/QueryFormData.js +29 -0
- package/lib/query/types/QueryFormData.js.map +1 -0
- package/lib/query/types/QueryResponse.d.ts +83 -0
- package/lib/query/types/QueryResponse.d.ts.map +1 -0
- package/lib/query/types/QueryResponse.js +30 -0
- package/lib/query/types/QueryResponse.js.map +1 -0
- package/lib/query/types/Time.d.ts +12 -0
- package/lib/query/types/Time.d.ts.map +1 -0
- package/lib/query/types/Time.js +20 -0
- package/lib/query/types/Time.js.map +1 -0
- package/lib/query/types/index.d.ts +42 -0
- package/lib/query/types/index.d.ts.map +1 -0
- package/lib/query/types/index.js +41 -0
- package/lib/query/types/index.js.map +1 -0
- package/lib/style/index.d.ts +236 -0
- package/lib/style/index.d.ts.map +1 -0
- package/lib/style/index.js +174 -0
- package/lib/style/index.js.map +1 -0
- package/lib/style/index.jsx +148 -0
- package/lib/style/index.jsx.map +1 -0
- package/lib/time-comparison/README.md +47 -0
- package/lib/time-comparison/customTimeRangeDecode.d.ts +22 -0
- package/lib/time-comparison/customTimeRangeDecode.d.ts.map +1 -0
- package/lib/time-comparison/customTimeRangeDecode.js +135 -0
- package/lib/time-comparison/customTimeRangeDecode.js.map +1 -0
- package/lib/time-comparison/fetchTimeRange.d.ts +12 -0
- package/lib/time-comparison/fetchTimeRange.d.ts.map +1 -0
- package/lib/time-comparison/fetchTimeRange.js +74 -0
- package/lib/time-comparison/fetchTimeRange.js.map +1 -0
- package/lib/time-comparison/getComparisonFilters.d.ts +31 -0
- package/lib/time-comparison/getComparisonFilters.d.ts.map +1 -0
- package/lib/time-comparison/getComparisonFilters.js +47 -0
- package/lib/time-comparison/getComparisonFilters.js.map +1 -0
- package/lib/time-comparison/getComparisonInfo.d.ts +31 -0
- package/lib/time-comparison/getComparisonInfo.d.ts.map +1 -0
- package/lib/time-comparison/getComparisonInfo.js +56 -0
- package/lib/time-comparison/getComparisonInfo.js.map +1 -0
- package/lib/time-comparison/getTimeOffset.d.ts +11 -0
- package/lib/time-comparison/getTimeOffset.d.ts.map +1 -0
- package/lib/time-comparison/getTimeOffset.js +266 -0
- package/lib/time-comparison/getTimeOffset.js.map +1 -0
- package/lib/time-comparison/index.d.ts +7 -0
- package/lib/time-comparison/index.d.ts.map +1 -0
- package/lib/time-comparison/index.js +25 -0
- package/lib/time-comparison/index.js.map +1 -0
- package/lib/time-comparison/types.d.ts +30 -0
- package/lib/time-comparison/types.d.ts.map +1 -0
- package/lib/time-comparison/types.js +30 -0
- package/lib/time-comparison/types.js.map +1 -0
- package/lib/time-format/D3FormatConfig.d.ts +21 -0
- package/lib/time-format/D3FormatConfig.d.ts.map +1 -0
- package/lib/time-format/D3FormatConfig.js +63 -0
- package/lib/time-format/D3FormatConfig.js.map +1 -0
- package/lib/time-format/README.md +68 -0
- package/lib/time-format/TimeFormats.d.ts +11 -0
- package/lib/time-format/TimeFormats.d.ts.map +1 -0
- package/lib/time-format/TimeFormats.js +35 -0
- package/lib/time-format/TimeFormats.js.map +1 -0
- package/lib/time-format/TimeFormatsForGranularity.d.ts +7 -0
- package/lib/time-format/TimeFormatsForGranularity.d.ts.map +1 -0
- package/lib/time-format/TimeFormatsForGranularity.js +46 -0
- package/lib/time-format/TimeFormatsForGranularity.js.map +1 -0
- package/lib/time-format/TimeFormatter.d.ts +42 -0
- package/lib/time-format/TimeFormatter.d.ts.map +1 -0
- package/lib/time-format/TimeFormatter.js +46 -0
- package/lib/time-format/TimeFormatter.js.map +1 -0
- package/lib/time-format/TimeFormatterRegistry.d.ts +29 -0
- package/lib/time-format/TimeFormatterRegistry.d.ts.map +1 -0
- package/lib/time-format/TimeFormatterRegistry.js +60 -0
- package/lib/time-format/TimeFormatterRegistry.js.map +1 -0
- package/lib/time-format/TimeFormatterRegistrySingleton.d.ts +17 -0
- package/lib/time-format/TimeFormatterRegistrySingleton.d.ts.map +1 -0
- package/lib/time-format/TimeFormatterRegistrySingleton.js +65 -0
- package/lib/time-format/TimeFormatterRegistrySingleton.js.map +1 -0
- package/lib/time-format/TimeRangeFormatter.d.ts +40 -0
- package/lib/time-format/TimeRangeFormatter.d.ts.map +1 -0
- package/lib/time-format/TimeRangeFormatter.js +40 -0
- package/lib/time-format/TimeRangeFormatter.js.map +1 -0
- package/lib/time-format/factories/createD3TimeFormatter.d.ts +28 -0
- package/lib/time-format/factories/createD3TimeFormatter.d.ts.map +1 -0
- package/lib/time-format/factories/createD3TimeFormatter.js +45 -0
- package/lib/time-format/factories/createD3TimeFormatter.js.map +1 -0
- package/lib/time-format/factories/createMultiFormatter.d.ts +22 -0
- package/lib/time-format/factories/createMultiFormatter.d.ts.map +1 -0
- package/lib/time-format/factories/createMultiFormatter.js +70 -0
- package/lib/time-format/factories/createMultiFormatter.js.map +1 -0
- package/lib/time-format/formatters/finestTemporalGrain.d.ts +3 -0
- package/lib/time-format/formatters/finestTemporalGrain.d.ts.map +1 -0
- package/lib/time-format/formatters/finestTemporalGrain.js +64 -0
- package/lib/time-format/formatters/finestTemporalGrain.js.map +1 -0
- package/lib/time-format/formatters/finestTemporalGrain.test.d.ts +2 -0
- package/lib/time-format/formatters/finestTemporalGrain.test.d.ts.map +1 -0
- package/lib/time-format/formatters/finestTemporalGrain.test.js +44 -0
- package/lib/time-format/formatters/finestTemporalGrain.test.js.map +1 -0
- package/lib/time-format/formatters/smartDate.d.ts +4 -0
- package/lib/time-format/formatters/smartDate.d.ts.map +1 -0
- package/lib/time-format/formatters/smartDate.js +38 -0
- package/lib/time-format/formatters/smartDate.js.map +1 -0
- package/lib/time-format/formatters/smartDateDetailed.d.ts +4 -0
- package/lib/time-format/formatters/smartDateDetailed.d.ts.map +1 -0
- package/lib/time-format/formatters/smartDateDetailed.js +38 -0
- package/lib/time-format/formatters/smartDateDetailed.js.map +1 -0
- package/lib/time-format/formatters/smartDateVerbose.d.ts +4 -0
- package/lib/time-format/formatters/smartDateVerbose.d.ts.map +1 -0
- package/lib/time-format/formatters/smartDateVerbose.js +38 -0
- package/lib/time-format/formatters/smartDateVerbose.js.map +1 -0
- package/lib/time-format/index.d.ts +14 -0
- package/lib/time-format/index.d.ts.map +1 -0
- package/lib/time-format/index.js +32 -0
- package/lib/time-format/index.js.map +1 -0
- package/lib/time-format/types.d.ts +28 -0
- package/lib/time-format/types.d.ts.map +1 -0
- package/lib/time-format/types.js +41 -0
- package/lib/time-format/types.js.map +1 -0
- package/lib/time-format/utils/createTime.d.ts +2 -0
- package/lib/time-format/utils/createTime.d.ts.map +1 -0
- package/lib/time-format/utils/createTime.js +31 -0
- package/lib/time-format/utils/createTime.js.map +1 -0
- package/lib/time-format/utils/createTimeRangeFromGranularity.d.ts +3 -0
- package/lib/time-format/utils/createTimeRangeFromGranularity.d.ts.map +1 -0
- package/lib/time-format/utils/createTimeRangeFromGranularity.js +83 -0
- package/lib/time-format/utils/createTimeRangeFromGranularity.js.map +1 -0
- package/lib/time-format/utils/d3Time.d.ts +63 -0
- package/lib/time-format/utils/d3Time.d.ts.map +1 -0
- package/lib/time-format/utils/d3Time.js +101 -0
- package/lib/time-format/utils/d3Time.js.map +1 -0
- package/lib/time-format/utils/denormalizeTimestamp.d.ts +2 -0
- package/lib/time-format/utils/denormalizeTimestamp.d.ts.map +1 -0
- package/lib/time-format/utils/denormalizeTimestamp.js +27 -0
- package/lib/time-format/utils/denormalizeTimestamp.js.map +1 -0
- package/lib/time-format/utils/normalizeTimestamp.d.ts +3 -0
- package/lib/time-format/utils/normalizeTimestamp.d.ts.map +1 -0
- package/lib/time-format/utils/normalizeTimestamp.js +27 -0
- package/lib/time-format/utils/normalizeTimestamp.js.map +1 -0
- package/lib/time-format/utils/stringifyTimeInput.d.ts +2 -0
- package/lib/time-format/utils/stringifyTimeInput.d.ts.map +1 -0
- package/lib/time-format/utils/stringifyTimeInput.js +25 -0
- package/lib/time-format/utils/stringifyTimeInput.js.map +1 -0
- package/lib/translation/README.md +71 -0
- package/lib/translation/Translator.d.ts +18 -0
- package/lib/translation/Translator.d.ts.map +1 -0
- package/lib/translation/Translator.js +89 -0
- package/lib/translation/Translator.js.map +1 -0
- package/lib/translation/TranslatorSingleton.d.ts +11 -0
- package/lib/translation/TranslatorSingleton.d.ts.map +1 -0
- package/lib/translation/TranslatorSingleton.js +59 -0
- package/lib/translation/TranslatorSingleton.js.map +1 -0
- package/lib/translation/index.d.ts +6 -0
- package/lib/translation/index.d.ts.map +1 -0
- package/lib/translation/index.js +23 -0
- package/lib/translation/index.js.map +1 -0
- package/lib/translation/types/index.d.ts +55 -0
- package/lib/translation/types/index.d.ts.map +1 -0
- package/lib/translation/types/index.js +4 -0
- package/lib/translation/types/index.js.map +1 -0
- package/lib/translation/types/jed.d.ts +31 -0
- package/lib/translation/types/jed.d.ts.map +1 -0
- package/lib/translation/types/jed.js +20 -0
- package/lib/translation/types/jed.js.map +1 -0
- package/lib/types/index.d.ts +26 -0
- package/lib/types/index.d.ts.map +1 -0
- package/lib/types/index.js +2 -0
- package/lib/types/index.js.map +1 -0
- package/lib/ui-overrides/ExtensionsRegistry.d.ts +30 -0
- package/lib/ui-overrides/ExtensionsRegistry.d.ts.map +1 -0
- package/lib/ui-overrides/ExtensionsRegistry.js +29 -0
- package/lib/ui-overrides/ExtensionsRegistry.js.map +1 -0
- package/lib/ui-overrides/index.d.ts +21 -0
- package/lib/ui-overrides/index.d.ts.map +1 -0
- package/lib/ui-overrides/index.js +21 -0
- package/lib/ui-overrides/index.js.map +1 -0
- package/lib/ui-overrides/index.jsx +21 -0
- package/lib/ui-overrides/index.jsx.map +1 -0
- package/lib/ui-overrides/types.d.ts +192 -0
- package/lib/ui-overrides/types.d.ts.map +1 -0
- package/lib/ui-overrides/types.js +2 -0
- package/lib/ui-overrides/types.js.map +1 -0
- package/lib/utils/convertKeysToCamelCase.d.ts +2 -0
- package/lib/utils/convertKeysToCamelCase.d.ts.map +1 -0
- package/lib/utils/convertKeysToCamelCase.js +30 -0
- package/lib/utils/convertKeysToCamelCase.js.map +1 -0
- package/lib/utils/ensureIsArray.d.ts +24 -0
- package/lib/utils/ensureIsArray.d.ts.map +1 -0
- package/lib/utils/ensureIsArray.js +29 -0
- package/lib/utils/ensureIsArray.js.map +1 -0
- package/lib/utils/ensureIsInt.d.ts +20 -0
- package/lib/utils/ensureIsInt.d.ts.map +1 -0
- package/lib/utils/ensureIsInt.js +24 -0
- package/lib/utils/ensureIsInt.js.map +1 -0
- package/lib/utils/featureFlags.d.ts +66 -0
- package/lib/utils/featureFlags.d.ts.map +1 -0
- package/lib/utils/featureFlags.js +80 -0
- package/lib/utils/featureFlags.js.map +1 -0
- package/lib/utils/getSelectedText.d.ts +20 -0
- package/lib/utils/getSelectedText.d.ts.map +1 -0
- package/lib/utils/getSelectedText.js +20 -0
- package/lib/utils/getSelectedText.js.map +1 -0
- package/lib/utils/html.d.ts +12 -0
- package/lib/utils/html.d.ts.map +1 -0
- package/lib/utils/html.js +122 -0
- package/lib/utils/html.js.map +1 -0
- package/lib/utils/html.jsx +96 -0
- package/lib/utils/html.jsx.map +1 -0
- package/lib/utils/html.test.d.ts +2 -0
- package/lib/utils/html.test.d.ts.map +1 -0
- package/lib/utils/html.test.js +192 -0
- package/lib/utils/html.test.js.map +1 -0
- package/lib/utils/html.test.jsx +152 -0
- package/lib/utils/html.test.jsx.map +1 -0
- package/lib/utils/index.d.ts +36 -0
- package/lib/utils/index.d.ts.map +1 -0
- package/lib/utils/index.js +36 -0
- package/lib/utils/index.js.map +1 -0
- package/lib/utils/isDefined.d.ts +2 -0
- package/lib/utils/isDefined.d.ts.map +1 -0
- package/lib/utils/isDefined.js +22 -0
- package/lib/utils/isDefined.js.map +1 -0
- package/lib/utils/isEqualArray.d.ts +20 -0
- package/lib/utils/isEqualArray.d.ts.map +1 -0
- package/lib/utils/isEqualArray.js +27 -0
- package/lib/utils/isEqualArray.js.map +1 -0
- package/lib/utils/isEqualArray.test.d.ts +2 -0
- package/lib/utils/isEqualArray.test.d.ts.map +1 -0
- package/lib/utils/isEqualArray.test.js +31 -0
- package/lib/utils/isEqualArray.test.js.map +1 -0
- package/lib/utils/isRequired.d.ts +2 -0
- package/lib/utils/isRequired.d.ts.map +1 -0
- package/lib/utils/isRequired.js +22 -0
- package/lib/utils/isRequired.js.map +1 -0
- package/lib/utils/logging.d.ts +55 -0
- package/lib/utils/logging.d.ts.map +1 -0
- package/lib/utils/logging.js +36 -0
- package/lib/utils/logging.js.map +1 -0
- package/lib/utils/lruCache.d.ts +31 -0
- package/lib/utils/lruCache.d.ts.map +1 -0
- package/lib/utils/lruCache.js +65 -0
- package/lib/utils/lruCache.js.map +1 -0
- package/lib/utils/makeSingleton.d.ts +6 -0
- package/lib/utils/makeSingleton.d.ts.map +1 -0
- package/lib/utils/makeSingleton.js +28 -0
- package/lib/utils/makeSingleton.js.map +1 -0
- package/lib/utils/promiseTimeout.d.ts +7 -0
- package/lib/utils/promiseTimeout.d.ts.map +1 -0
- package/lib/utils/promiseTimeout.js +31 -0
- package/lib/utils/promiseTimeout.js.map +1 -0
- package/lib/utils/random.d.ts +22 -0
- package/lib/utils/random.d.ts.map +1 -0
- package/lib/utils/random.js +26 -0
- package/lib/utils/random.js.map +1 -0
- package/lib/utils/removeDuplicates.d.ts +24 -0
- package/lib/utils/removeDuplicates.d.ts.map +1 -0
- package/lib/utils/removeDuplicates.js +36 -0
- package/lib/utils/removeDuplicates.js.map +1 -0
- package/lib/utils/tooltip.d.ts +2 -0
- package/lib/utils/tooltip.d.ts.map +1 -0
- package/lib/utils/tooltip.js +51 -0
- package/lib/utils/tooltip.js.map +1 -0
- package/lib/utils/typedMemo.d.ts +2 -0
- package/lib/utils/typedMemo.d.ts.map +1 -0
- package/lib/utils/typedMemo.js +21 -0
- package/lib/utils/typedMemo.js.map +1 -0
- package/lib/validator/index.d.ts +9 -0
- package/lib/validator/index.d.ts.map +1 -0
- package/lib/validator/index.js +27 -0
- package/lib/validator/index.js.map +1 -0
- package/lib/validator/legacyValidateInteger.d.ts +6 -0
- package/lib/validator/legacyValidateInteger.d.ts.map +1 -0
- package/lib/validator/legacyValidateInteger.js +31 -0
- package/lib/validator/legacyValidateInteger.js.map +1 -0
- package/lib/validator/legacyValidateNumber.d.ts +6 -0
- package/lib/validator/legacyValidateNumber.d.ts.map +1 -0
- package/lib/validator/legacyValidateNumber.js +30 -0
- package/lib/validator/legacyValidateNumber.js.map +1 -0
- package/lib/validator/validateInteger.d.ts +2 -0
- package/lib/validator/validateInteger.d.ts.map +1 -0
- package/lib/validator/validateInteger.js +29 -0
- package/lib/validator/validateInteger.js.map +1 -0
- package/lib/validator/validateMapboxStylesUrl.d.ts +6 -0
- package/lib/validator/validateMapboxStylesUrl.d.ts.map +1 -0
- package/lib/validator/validateMapboxStylesUrl.js +32 -0
- package/lib/validator/validateMapboxStylesUrl.js.map +1 -0
- package/lib/validator/validateMaxValue.d.ts +2 -0
- package/lib/validator/validateMaxValue.d.ts.map +1 -0
- package/lib/validator/validateMaxValue.js +26 -0
- package/lib/validator/validateMaxValue.js.map +1 -0
- package/lib/validator/validateNonEmpty.d.ts +2 -0
- package/lib/validator/validateNonEmpty.d.ts.map +1 -0
- package/lib/validator/validateNonEmpty.js +29 -0
- package/lib/validator/validateNonEmpty.js.map +1 -0
- package/lib/validator/validateNumber.d.ts +2 -0
- package/lib/validator/validateNumber.d.ts.map +1 -0
- package/lib/validator/validateNumber.js +29 -0
- package/lib/validator/validateNumber.js.map +1 -0
- package/lib/validator/validateTimeComparisonRangeValues.d.ts +3 -0
- package/lib/validator/validateTimeComparisonRangeValues.d.ts.map +1 -0
- package/lib/validator/validateTimeComparisonRangeValues.js +30 -0
- package/lib/validator/validateTimeComparisonRangeValues.js.map +1 -0
- package/package.json +101 -0
|
@@ -0,0 +1,319 @@
|
|
|
1
|
+
import _isEmpty from "lodash/isEmpty.js"; /**
|
|
2
|
+
* Licensed to the Apache Software Foundation (ASF) under one
|
|
3
|
+
* or more contributor license agreements. See the NOTICE file
|
|
4
|
+
* distributed with this work for additional information
|
|
5
|
+
* regarding copyright ownership. The ASF licenses this file
|
|
6
|
+
* to you under the Apache License, Version 2.0 (the
|
|
7
|
+
* "License"); you may not use this file except in compliance
|
|
8
|
+
* with the License. You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing,
|
|
13
|
+
* software distributed under the License is distributed on an
|
|
14
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
15
|
+
* KIND, either express or implied. See the License for the
|
|
16
|
+
* specific language governing permissions and limitations
|
|
17
|
+
* under the License.
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
import { ensureIsArray } from '../utils/index.js';
|
|
21
|
+
import { customTimeRangeDecode } from './customTimeRangeDecode.js';
|
|
22
|
+
|
|
23
|
+
const DAY_IN_MS = 24 * 60 * 60 * 1000;
|
|
24
|
+
|
|
25
|
+
export const parseDttmToDate = (
|
|
26
|
+
dttm,
|
|
27
|
+
isEndDate = false,
|
|
28
|
+
computingShifts = false) =>
|
|
29
|
+
{
|
|
30
|
+
const now = new Date();
|
|
31
|
+
if (dttm === 'now' || dttm === 'No filter' || dttm === '') {
|
|
32
|
+
return now;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
if (dttm === 'today') {
|
|
36
|
+
now.setHours(0, 0, 0, 0);
|
|
37
|
+
return now;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
if (computingShifts) {
|
|
41
|
+
now.setHours(-now.getTimezoneOffset() / 60, 0, 0, 0);
|
|
42
|
+
} else {
|
|
43
|
+
now.setHours(0, 0, 0, 0);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
if (isEndDate && dttm != null && dttm.includes('Last')) {
|
|
47
|
+
return now;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
switch (dttm) {
|
|
51
|
+
case 'Last day':
|
|
52
|
+
now.setUTCDate(now.getUTCDate() - 1);
|
|
53
|
+
return now;
|
|
54
|
+
case 'Last week':
|
|
55
|
+
now.setUTCDate(now.getUTCDate() - 7);
|
|
56
|
+
return now;
|
|
57
|
+
case 'Last month':
|
|
58
|
+
now.setUTCMonth(now.getUTCMonth() - 1);
|
|
59
|
+
return now;
|
|
60
|
+
case 'Last quarter':
|
|
61
|
+
now.setUTCMonth(now.getUTCMonth() - 3);
|
|
62
|
+
return now;
|
|
63
|
+
case 'Last year':
|
|
64
|
+
now.setUTCFullYear(now.getUTCFullYear() - 1);
|
|
65
|
+
return now;
|
|
66
|
+
case 'previous calendar week':
|
|
67
|
+
if (isEndDate) {
|
|
68
|
+
now.setDate(now.getDate() - now.getDay() + 1); // end date is the last day of the previous week (Sunday)
|
|
69
|
+
} else {
|
|
70
|
+
now.setDate(now.getDate() - now.getDay() - 6); // start date is the first day of the previous week (Monday)
|
|
71
|
+
}
|
|
72
|
+
return now;
|
|
73
|
+
case 'previous calendar month':
|
|
74
|
+
if (isEndDate) {
|
|
75
|
+
now.setDate(1); // end date is the last day of the previous month
|
|
76
|
+
} else {
|
|
77
|
+
now.setDate(1); // start date is the first day of the previous month
|
|
78
|
+
now.setMonth(now.getMonth() - 1);
|
|
79
|
+
}
|
|
80
|
+
return now;
|
|
81
|
+
case 'previous calendar year':
|
|
82
|
+
if (isEndDate) {
|
|
83
|
+
now.setFullYear(now.getFullYear(), 0, 1); // end date is the last day of the previous year
|
|
84
|
+
} else {
|
|
85
|
+
now.setFullYear(now.getFullYear() - 1, 0, 1); // start date is the first day of the previous year
|
|
86
|
+
}
|
|
87
|
+
return now;
|
|
88
|
+
default:
|
|
89
|
+
break;
|
|
90
|
+
}
|
|
91
|
+
if (dttm != null && dttm.includes('ago')) {
|
|
92
|
+
const parts = dttm.split(' ');
|
|
93
|
+
const amount = parseInt(parts[0], 10);
|
|
94
|
+
const unit = parts[1];
|
|
95
|
+
switch (unit) {
|
|
96
|
+
case 'day':
|
|
97
|
+
case 'days':
|
|
98
|
+
now.setUTCDate(now.getUTCDate() - amount);
|
|
99
|
+
break;
|
|
100
|
+
case 'week':
|
|
101
|
+
case 'weeks':
|
|
102
|
+
now.setUTCDate(now.getUTCDate() - amount * 7);
|
|
103
|
+
break;
|
|
104
|
+
case 'month':
|
|
105
|
+
case 'months':
|
|
106
|
+
now.setUTCMonth(now.getUTCMonth() - amount);
|
|
107
|
+
break;
|
|
108
|
+
case 'year':
|
|
109
|
+
case 'years':
|
|
110
|
+
now.setUTCFullYear(now.getUTCFullYear() - amount);
|
|
111
|
+
break;
|
|
112
|
+
default:
|
|
113
|
+
break;
|
|
114
|
+
}
|
|
115
|
+
return now;
|
|
116
|
+
}
|
|
117
|
+
const parts = dttm == null ? void 0 : dttm.split('-');
|
|
118
|
+
let parsed = null;
|
|
119
|
+
if (parts && !_isEmpty(parts)) {
|
|
120
|
+
if (parts.length === 1) {
|
|
121
|
+
parsed = new Date(Date.UTC(parseInt(parts[0], 10), 0));
|
|
122
|
+
} else if (parts.length === 2) {
|
|
123
|
+
parsed = new Date(
|
|
124
|
+
Date.UTC(parseInt(parts[0], 10), parseInt(parts[1], 10) - 1)
|
|
125
|
+
);
|
|
126
|
+
} else if (parts.length === 3) {
|
|
127
|
+
parsed = new Date(
|
|
128
|
+
parseInt(parts[0], 10),
|
|
129
|
+
parseInt(parts[1], 10) - 1,
|
|
130
|
+
parseInt(parts[2], 10)
|
|
131
|
+
);
|
|
132
|
+
} else {
|
|
133
|
+
parsed = new Date(dttm);
|
|
134
|
+
}
|
|
135
|
+
} else {
|
|
136
|
+
parsed = new Date(dttm);
|
|
137
|
+
}
|
|
138
|
+
if (parsed && !Number.isNaN(parsed.getTime())) {
|
|
139
|
+
if (computingShifts) {
|
|
140
|
+
parsed.setHours(-parsed.getTimezoneOffset() / 60, 0, 0, 0);
|
|
141
|
+
} else {
|
|
142
|
+
parsed.setHours(0, 0, 0, 0);
|
|
143
|
+
}
|
|
144
|
+
return parsed;
|
|
145
|
+
}
|
|
146
|
+
// Return null if the string cannot be parsed into a date
|
|
147
|
+
return null;
|
|
148
|
+
};
|
|
149
|
+
|
|
150
|
+
export const computeCustomDateTime = (
|
|
151
|
+
dttm,
|
|
152
|
+
grain,
|
|
153
|
+
grainValue) =>
|
|
154
|
+
{
|
|
155
|
+
let parsed;
|
|
156
|
+
if (dttm === 'now' || dttm === 'today') {
|
|
157
|
+
parsed = new Date();
|
|
158
|
+
} else {
|
|
159
|
+
parsed = new Date(dttm);
|
|
160
|
+
}
|
|
161
|
+
if (!Number.isNaN(parsed.getTime())) {
|
|
162
|
+
switch (grain) {
|
|
163
|
+
case 'second':
|
|
164
|
+
parsed.setSeconds(parsed.getSeconds() + grainValue);
|
|
165
|
+
break;
|
|
166
|
+
case 'minute':
|
|
167
|
+
parsed.setMinutes(parsed.getMinutes() + grainValue);
|
|
168
|
+
break;
|
|
169
|
+
case 'hour':
|
|
170
|
+
parsed.setHours(parsed.getHours() + grainValue);
|
|
171
|
+
break;
|
|
172
|
+
case 'day':
|
|
173
|
+
parsed.setDate(parsed.getDate() + grainValue);
|
|
174
|
+
break;
|
|
175
|
+
case 'week':
|
|
176
|
+
parsed.setDate(parsed.getDate() + grainValue * 7);
|
|
177
|
+
break;
|
|
178
|
+
case 'month':
|
|
179
|
+
parsed.setMonth(parsed.getMonth() + grainValue);
|
|
180
|
+
break;
|
|
181
|
+
case 'quarter':
|
|
182
|
+
parsed.setMonth(parsed.getMonth() + grainValue * 3);
|
|
183
|
+
break;
|
|
184
|
+
case 'year':
|
|
185
|
+
parsed.setFullYear(parsed.getFullYear() + grainValue);
|
|
186
|
+
break;
|
|
187
|
+
default:
|
|
188
|
+
break;
|
|
189
|
+
}
|
|
190
|
+
return parsed;
|
|
191
|
+
}
|
|
192
|
+
return null;
|
|
193
|
+
};
|
|
194
|
+
|
|
195
|
+
|
|
196
|
+
|
|
197
|
+
|
|
198
|
+
|
|
199
|
+
|
|
200
|
+
|
|
201
|
+
|
|
202
|
+
export const getTimeOffset = ({
|
|
203
|
+
timeRangeFilter,
|
|
204
|
+
shifts,
|
|
205
|
+
startDate,
|
|
206
|
+
includeFutureOffsets = true
|
|
207
|
+
}) => {var _timeRangeFilter$comp, _timeRangeFilter$comp2, _ref, _customStartDate2, _ref2, _customEndDate2;
|
|
208
|
+
const { customRange, matchedFlag } = customTimeRangeDecode((_timeRangeFilter$comp =
|
|
209
|
+
timeRangeFilter == null ? void 0 : timeRangeFilter.comparator) != null ? _timeRangeFilter$comp : ''
|
|
210
|
+
);
|
|
211
|
+
let customStartDate = null;
|
|
212
|
+
let customEndDate = null;
|
|
213
|
+
if (matchedFlag) {var _customStartDate, _customEndDate;
|
|
214
|
+
// Compute the start date and end date using the custom range information
|
|
215
|
+
const {
|
|
216
|
+
sinceDatetime,
|
|
217
|
+
sinceMode,
|
|
218
|
+
sinceGrain,
|
|
219
|
+
sinceGrainValue,
|
|
220
|
+
untilDatetime,
|
|
221
|
+
untilMode,
|
|
222
|
+
untilGrain,
|
|
223
|
+
untilGrainValue
|
|
224
|
+
} = { ...customRange };
|
|
225
|
+
if (sinceMode !== 'relative') {
|
|
226
|
+
if (sinceMode === 'specific') {
|
|
227
|
+
customStartDate = new Date(sinceDatetime);
|
|
228
|
+
} else {
|
|
229
|
+
customStartDate = parseDttmToDate(sinceDatetime, false, true);
|
|
230
|
+
}
|
|
231
|
+
} else {
|
|
232
|
+
customStartDate = computeCustomDateTime(
|
|
233
|
+
sinceDatetime,
|
|
234
|
+
sinceGrain,
|
|
235
|
+
sinceGrainValue
|
|
236
|
+
);
|
|
237
|
+
}
|
|
238
|
+
(_customStartDate = customStartDate) == null ? void 0 : _customStartDate.setHours(0, 0, 0, 0);
|
|
239
|
+
if (untilMode !== 'relative') {
|
|
240
|
+
if (untilMode === 'specific') {
|
|
241
|
+
customEndDate = new Date(untilDatetime);
|
|
242
|
+
} else {
|
|
243
|
+
customEndDate = parseDttmToDate(untilDatetime, false, true);
|
|
244
|
+
}
|
|
245
|
+
} else {
|
|
246
|
+
customEndDate = computeCustomDateTime(
|
|
247
|
+
untilDatetime,
|
|
248
|
+
untilGrain,
|
|
249
|
+
untilGrainValue
|
|
250
|
+
);
|
|
251
|
+
}
|
|
252
|
+
(_customEndDate = customEndDate) == null ? void 0 : _customEndDate.setHours(0, 0, 0, 0);
|
|
253
|
+
}
|
|
254
|
+
const isCustom = shifts == null ? void 0 : shifts.includes('custom');
|
|
255
|
+
const isInherit = shifts == null ? void 0 : shifts.includes('inherit');
|
|
256
|
+
let customStartDateTime;
|
|
257
|
+
if (isCustom) {
|
|
258
|
+
if (matchedFlag) {
|
|
259
|
+
customStartDateTime = new Date(
|
|
260
|
+
new Date(startDate).setUTCHours(
|
|
261
|
+
new Date(startDate).getTimezoneOffset() / 60,
|
|
262
|
+
0,
|
|
263
|
+
0,
|
|
264
|
+
0
|
|
265
|
+
)
|
|
266
|
+
).getTime();
|
|
267
|
+
} else {var _parseDttmToDate;
|
|
268
|
+
customStartDateTime = (_parseDttmToDate = parseDttmToDate(startDate)) == null ? void 0 : _parseDttmToDate.getTime();
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
const [startStr, endStr] = ((_timeRangeFilter$comp2 = timeRangeFilter == null ? void 0 : timeRangeFilter.comparator) != null ? _timeRangeFilter$comp2 : '').
|
|
272
|
+
split(' : ').
|
|
273
|
+
map((date) => date.trim());
|
|
274
|
+
const filterStartDateTime =
|
|
275
|
+
((_ref = (_customStartDate2 = customStartDate) != null ? _customStartDate2 : parseDttmToDate(startStr, false, false)) == null ? void 0 : _ref.getTime()) ||
|
|
276
|
+
0;
|
|
277
|
+
const filterEndDateTime =
|
|
278
|
+
((_ref2 = (_customEndDate2 =
|
|
279
|
+
customEndDate) != null ? _customEndDate2 : parseDttmToDate(endStr || startStr, true, false)) == null ? void 0 : _ref2.
|
|
280
|
+
getTime()) || 0;
|
|
281
|
+
|
|
282
|
+
const customShift =
|
|
283
|
+
customStartDateTime &&
|
|
284
|
+
filterStartDateTime &&
|
|
285
|
+
Math.round((filterStartDateTime - customStartDateTime) / DAY_IN_MS);
|
|
286
|
+
const inInheritShift =
|
|
287
|
+
isInherit &&
|
|
288
|
+
filterEndDateTime &&
|
|
289
|
+
filterStartDateTime &&
|
|
290
|
+
Math.round((filterEndDateTime - filterStartDateTime) / DAY_IN_MS);
|
|
291
|
+
|
|
292
|
+
const newShifts = ensureIsArray(shifts).
|
|
293
|
+
map((shift) => {
|
|
294
|
+
if (shift === 'custom') {
|
|
295
|
+
if (customShift !== undefined && !Number.isNaN(customShift)) {
|
|
296
|
+
if (includeFutureOffsets && customShift < 0) {
|
|
297
|
+
return `${customShift * -1} days after`;
|
|
298
|
+
}
|
|
299
|
+
if (customShift >= 0 && filterStartDateTime) {
|
|
300
|
+
return `${customShift} days ago`;
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
if (shift === 'inherit') {
|
|
305
|
+
if (inInheritShift && !Number.isNaN(inInheritShift)) {
|
|
306
|
+
if (includeFutureOffsets && inInheritShift < 0) {
|
|
307
|
+
return `${inInheritShift * -1} days after`;
|
|
308
|
+
}
|
|
309
|
+
if (inInheritShift > 0) {
|
|
310
|
+
return `${inInheritShift} days ago`;
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
return shift;
|
|
315
|
+
}).
|
|
316
|
+
filter((shift) => shift !== 'custom' && shift !== 'inherit');
|
|
317
|
+
return ensureIsArray(newShifts);
|
|
318
|
+
};
|
|
319
|
+
//# sourceMappingURL=getTimeOffset.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getTimeOffset.js","names":["ensureIsArray","customTimeRangeDecode","DAY_IN_MS","parseDttmToDate","dttm","isEndDate","computingShifts","now","Date","setHours","getTimezoneOffset","includes","setUTCDate","getUTCDate","setUTCMonth","getUTCMonth","setUTCFullYear","getUTCFullYear","setDate","getDate","getDay","setMonth","getMonth","setFullYear","getFullYear","parts","split","amount","parseInt","unit","parsed","_isEmpty","length","UTC","Number","isNaN","getTime","computeCustomDateTime","grain","grainValue","setSeconds","getSeconds","setMinutes","getMinutes","getHours","getTimeOffset","timeRangeFilter","shifts","startDate","includeFutureOffsets","_timeRangeFilter$comp","_timeRangeFilter$comp2","_ref","_customStartDate2","_ref2","_customEndDate2","customRange","matchedFlag","comparator","customStartDate","customEndDate","_customStartDate","_customEndDate","sinceDatetime","sinceMode","sinceGrain","sinceGrainValue","untilDatetime","untilMode","untilGrain","untilGrainValue","isCustom","isInherit","customStartDateTime","setUTCHours","_parseDttmToDate","startStr","endStr","map","date","trim","filterStartDateTime","filterEndDateTime","customShift","Math","round","inInheritShift","newShifts","shift","undefined","filter"],"sources":["../../src/time-comparison/getTimeOffset.ts"],"sourcesContent":["/**\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOTICE file\n * distributed with this work for additional information\n * regarding copyright ownership. The ASF licenses this file\n * to you under the Apache License, Version 2.0 (the\n * \"License\"); you may not use this file except in compliance\n * with the License. You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing,\n * software distributed under the License is distributed on an\n * \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n * KIND, either express or implied. See the License for the\n * specific language governing permissions and limitations\n * under the License.\n */\nimport { isEmpty } from 'lodash';\nimport { ensureIsArray } from '../utils';\nimport { customTimeRangeDecode } from './customTimeRangeDecode';\n\nconst DAY_IN_MS = 24 * 60 * 60 * 1000;\n\nexport const parseDttmToDate = (\n dttm: string,\n isEndDate = false,\n computingShifts = false,\n) => {\n const now = new Date();\n if (dttm === 'now' || dttm === 'No filter' || dttm === '') {\n return now;\n }\n\n if (dttm === 'today') {\n now.setHours(0, 0, 0, 0);\n return now;\n }\n\n if (computingShifts) {\n now.setHours(-now.getTimezoneOffset() / 60, 0, 0, 0);\n } else {\n now.setHours(0, 0, 0, 0);\n }\n\n if (isEndDate && dttm?.includes('Last')) {\n return now;\n }\n\n switch (dttm) {\n case 'Last day':\n now.setUTCDate(now.getUTCDate() - 1);\n return now;\n case 'Last week':\n now.setUTCDate(now.getUTCDate() - 7);\n return now;\n case 'Last month':\n now.setUTCMonth(now.getUTCMonth() - 1);\n return now;\n case 'Last quarter':\n now.setUTCMonth(now.getUTCMonth() - 3);\n return now;\n case 'Last year':\n now.setUTCFullYear(now.getUTCFullYear() - 1);\n return now;\n case 'previous calendar week':\n if (isEndDate) {\n now.setDate(now.getDate() - now.getDay() + 1); // end date is the last day of the previous week (Sunday)\n } else {\n now.setDate(now.getDate() - now.getDay() - 6); // start date is the first day of the previous week (Monday)\n }\n return now;\n case 'previous calendar month':\n if (isEndDate) {\n now.setDate(1); // end date is the last day of the previous month\n } else {\n now.setDate(1); // start date is the first day of the previous month\n now.setMonth(now.getMonth() - 1);\n }\n return now;\n case 'previous calendar year':\n if (isEndDate) {\n now.setFullYear(now.getFullYear(), 0, 1); // end date is the last day of the previous year\n } else {\n now.setFullYear(now.getFullYear() - 1, 0, 1); // start date is the first day of the previous year\n }\n return now;\n default:\n break;\n }\n if (dttm?.includes('ago')) {\n const parts = dttm.split(' ');\n const amount = parseInt(parts[0], 10);\n const unit = parts[1];\n switch (unit) {\n case 'day':\n case 'days':\n now.setUTCDate(now.getUTCDate() - amount);\n break;\n case 'week':\n case 'weeks':\n now.setUTCDate(now.getUTCDate() - amount * 7);\n break;\n case 'month':\n case 'months':\n now.setUTCMonth(now.getUTCMonth() - amount);\n break;\n case 'year':\n case 'years':\n now.setUTCFullYear(now.getUTCFullYear() - amount);\n break;\n default:\n break;\n }\n return now;\n }\n const parts = dttm?.split('-');\n let parsed: Date | null = null;\n if (parts && !isEmpty(parts)) {\n if (parts.length === 1) {\n parsed = new Date(Date.UTC(parseInt(parts[0], 10), 0));\n } else if (parts.length === 2) {\n parsed = new Date(\n Date.UTC(parseInt(parts[0], 10), parseInt(parts[1], 10) - 1),\n );\n } else if (parts.length === 3) {\n parsed = new Date(\n parseInt(parts[0], 10),\n parseInt(parts[1], 10) - 1,\n parseInt(parts[2], 10),\n );\n } else {\n parsed = new Date(dttm);\n }\n } else {\n parsed = new Date(dttm);\n }\n if (parsed && !Number.isNaN(parsed.getTime())) {\n if (computingShifts) {\n parsed.setHours(-parsed.getTimezoneOffset() / 60, 0, 0, 0);\n } else {\n parsed.setHours(0, 0, 0, 0);\n }\n return parsed;\n }\n // Return null if the string cannot be parsed into a date\n return null;\n};\n\nexport const computeCustomDateTime = (\n dttm: string,\n grain: string,\n grainValue: number,\n) => {\n let parsed: Date;\n if (dttm === 'now' || dttm === 'today') {\n parsed = new Date();\n } else {\n parsed = new Date(dttm);\n }\n if (!Number.isNaN(parsed.getTime())) {\n switch (grain) {\n case 'second':\n parsed.setSeconds(parsed.getSeconds() + grainValue);\n break;\n case 'minute':\n parsed.setMinutes(parsed.getMinutes() + grainValue);\n break;\n case 'hour':\n parsed.setHours(parsed.getHours() + grainValue);\n break;\n case 'day':\n parsed.setDate(parsed.getDate() + grainValue);\n break;\n case 'week':\n parsed.setDate(parsed.getDate() + grainValue * 7);\n break;\n case 'month':\n parsed.setMonth(parsed.getMonth() + grainValue);\n break;\n case 'quarter':\n parsed.setMonth(parsed.getMonth() + grainValue * 3);\n break;\n case 'year':\n parsed.setFullYear(parsed.getFullYear() + grainValue);\n break;\n default:\n break;\n }\n return parsed;\n }\n return null;\n};\n\ntype TimeOffsetArgs = {\n timeRangeFilter: any;\n shifts: string[];\n startDate: string;\n includeFutureOffsets?: boolean;\n};\n\nexport const getTimeOffset = ({\n timeRangeFilter,\n shifts,\n startDate,\n includeFutureOffsets = true,\n}: TimeOffsetArgs): string[] => {\n const { customRange, matchedFlag } = customTimeRangeDecode(\n timeRangeFilter?.comparator ?? '',\n );\n let customStartDate: Date | null = null;\n let customEndDate: Date | null = null;\n if (matchedFlag) {\n // Compute the start date and end date using the custom range information\n const {\n sinceDatetime,\n sinceMode,\n sinceGrain,\n sinceGrainValue,\n untilDatetime,\n untilMode,\n untilGrain,\n untilGrainValue,\n } = { ...customRange };\n if (sinceMode !== 'relative') {\n if (sinceMode === 'specific') {\n customStartDate = new Date(sinceDatetime);\n } else {\n customStartDate = parseDttmToDate(sinceDatetime, false, true);\n }\n } else {\n customStartDate = computeCustomDateTime(\n sinceDatetime,\n sinceGrain,\n sinceGrainValue,\n );\n }\n customStartDate?.setHours(0, 0, 0, 0);\n if (untilMode !== 'relative') {\n if (untilMode === 'specific') {\n customEndDate = new Date(untilDatetime);\n } else {\n customEndDate = parseDttmToDate(untilDatetime, false, true);\n }\n } else {\n customEndDate = computeCustomDateTime(\n untilDatetime,\n untilGrain,\n untilGrainValue,\n );\n }\n customEndDate?.setHours(0, 0, 0, 0);\n }\n const isCustom = shifts?.includes('custom');\n const isInherit = shifts?.includes('inherit');\n let customStartDateTime: number | undefined;\n if (isCustom) {\n if (matchedFlag) {\n customStartDateTime = new Date(\n new Date(startDate).setUTCHours(\n new Date(startDate).getTimezoneOffset() / 60,\n 0,\n 0,\n 0,\n ),\n ).getTime();\n } else {\n customStartDateTime = parseDttmToDate(startDate)?.getTime();\n }\n }\n const [startStr, endStr] = (timeRangeFilter?.comparator ?? '')\n .split(' : ')\n .map((date: string) => date.trim());\n const filterStartDateTime =\n (customStartDate ?? parseDttmToDate(startStr, false, false))?.getTime() ||\n 0;\n const filterEndDateTime =\n (\n customEndDate ?? parseDttmToDate(endStr || startStr, true, false)\n )?.getTime() || 0;\n\n const customShift =\n customStartDateTime &&\n filterStartDateTime &&\n Math.round((filterStartDateTime - customStartDateTime) / DAY_IN_MS);\n const inInheritShift =\n isInherit &&\n filterEndDateTime &&\n filterStartDateTime &&\n Math.round((filterEndDateTime - filterStartDateTime) / DAY_IN_MS);\n\n const newShifts = ensureIsArray(shifts)\n .map(shift => {\n if (shift === 'custom') {\n if (customShift !== undefined && !Number.isNaN(customShift)) {\n if (includeFutureOffsets && customShift < 0) {\n return `${customShift * -1} days after`;\n }\n if (customShift >= 0 && filterStartDateTime) {\n return `${customShift} days ago`;\n }\n }\n }\n if (shift === 'inherit') {\n if (inInheritShift && !Number.isNaN(inInheritShift)) {\n if (includeFutureOffsets && inInheritShift < 0) {\n return `${inInheritShift * -1} days after`;\n }\n if (inInheritShift > 0) {\n return `${inInheritShift} days ago`;\n }\n }\n }\n return shift;\n })\n .filter(shift => shift !== 'custom' && shift !== 'inherit');\n return ensureIsArray(newShifts);\n};\n"],"mappings":"uCAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,aAAa,QAAQ,UAAU;AACxC,SAASC,qBAAqB,QAAQ,yBAAyB;;AAE/D,MAAMC,SAAS,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI;;AAErC,OAAO,MAAMC,eAAe,GAAGA;AAC7BC,IAAY;AACZC,SAAS,GAAG,KAAK;AACjBC,eAAe,GAAG,KAAK;AACpB;EACH,MAAMC,GAAG,GAAG,IAAIC,IAAI,CAAC,CAAC;EACtB,IAAIJ,IAAI,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0 +1,31 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Licensed to the Apache Software Foundation (ASF) under one
|
|
3
|
+
* or more contributor license agreements. See the NOTICE file
|
|
4
|
+
* distributed with this work for additional information
|
|
5
|
+
* regarding copyright ownership. The ASF licenses this file
|
|
6
|
+
* to you under the Apache License, Version 2.0 (the
|
|
7
|
+
* "License"); you may not use this file except in compliance
|
|
8
|
+
* with the License. You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing,
|
|
13
|
+
* software distributed under the License is distributed on an
|
|
14
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
15
|
+
* KIND, either express or implied. See the License for the
|
|
16
|
+
* specific language governing permissions and limitations
|
|
17
|
+
* under the License.
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
export * from './types.js';
|
|
21
|
+
|
|
22
|
+
export { default as getComparisonInfo } from './getComparisonInfo.js';
|
|
23
|
+
export { default as getComparisonFilters } from './getComparisonFilters.js';
|
|
24
|
+
export {
|
|
25
|
+
parseDttmToDate,
|
|
26
|
+
getTimeOffset,
|
|
27
|
+
computeCustomDateTime } from
|
|
28
|
+
'./getTimeOffset.js';
|
|
29
|
+
export { SEPARATOR, fetchTimeRange } from './fetchTimeRange.js';
|
|
30
|
+
export { customTimeRangeDecode } from './customTimeRangeDecode.js';
|
|
31
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":["default","getComparisonInfo","getComparisonFilters","parseDttmToDate","getTimeOffset","computeCustomDateTime","SEPARATOR","fetchTimeRange","customTimeRangeDecode"],"sources":["../../src/time-comparison/index.ts"],"sourcesContent":["/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOTICE file\n * distributed with this work for additional information\n * regarding copyright ownership. The ASF licenses this file\n * to you under the Apache License, Version 2.0 (the\n * \"License\"); you may not use this file except in compliance\n * with the License. You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing,\n * software distributed under the License is distributed on an\n * \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n * KIND, either express or implied. See the License for the\n * specific language governing permissions and limitations\n * under the License.\n */\n\nexport * from './types';\n\nexport { default as getComparisonInfo } from './getComparisonInfo';\nexport { default as getComparisonFilters } from './getComparisonFilters';\nexport {\n parseDttmToDate,\n getTimeOffset,\n computeCustomDateTime,\n} from './getTimeOffset';\nexport { SEPARATOR, fetchTimeRange } from './fetchTimeRange';\nexport { customTimeRangeDecode } from './customTimeRangeDecode';\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,cAAc,SAAS;;AAEvB,SAASA,OAAO,IAAIC,iBAAiB,QAAQ,qBAAqB;AAClE,SAASD,OAAO,IAAIE,oBAAoB,QAAQ,wBAAwB;AACxE;EACEC,eAAe;EACfC,aAAa;EACbC,qBAAqB;AAChB,iBAAiB;AACxB,SAASC,SAAS,EAAEC,cAAc,QAAQ,kBAAkB;AAC5D,SAASC,qBAAqB,QAAQ,yBAAyB","ignoreList":[]}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Licensed to the Apache Software Foundation (ASF) under one
|
|
3
|
+
* or more contributor license agreements. See the NOTICE file
|
|
4
|
+
* distributed with this work for additional information
|
|
5
|
+
* regarding copyright ownership. The ASF licenses this file
|
|
6
|
+
* to you under the Apache License, Version 2.0 (the
|
|
7
|
+
* "License"); you may not use this file except in compliance
|
|
8
|
+
* with the License. You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing,
|
|
13
|
+
* software distributed under the License is distributed on an
|
|
14
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
15
|
+
* KIND, either express or implied. See the License for the
|
|
16
|
+
* specific language governing permissions and limitations
|
|
17
|
+
* under the License.
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Supported comparison time ranges
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
export let ComparisonTimeRangeType = /*#__PURE__*/function (ComparisonTimeRangeType) {ComparisonTimeRangeType["Custom"] = "c";ComparisonTimeRangeType["InheritedRange"] = "r";ComparisonTimeRangeType["Month"] = "m";ComparisonTimeRangeType["Week"] = "w";ComparisonTimeRangeType["Year"] = "y";return ComparisonTimeRangeType;}({});
|
|
25
|
+
//# sourceMappingURL=types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","names":["ComparisonTimeRangeType"],"sources":["../../src/time-comparison/types.ts"],"sourcesContent":["/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOTICE file\n * distributed with this work for additional information\n * regarding copyright ownership. The ASF licenses this file\n * to you under the Apache License, Version 2.0 (the\n * \"License\"); you may not use this file except in compliance\n * with the License. You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing,\n * software distributed under the License is distributed on an\n * \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n * KIND, either express or implied. See the License for the\n * specific language governing permissions and limitations\n * under the License.\n */\n\n/**\n * Supported comparison time ranges\n */\n\nexport enum ComparisonTimeRangeType {\n Custom = 'c',\n InheritedRange = 'r',\n Month = 'm',\n Week = 'w',\n Year = 'y',\n}\n\nexport type DateTimeGrainType =\n | 'second'\n | 'minute'\n | 'hour'\n | 'day'\n | 'week'\n | 'month'\n | 'quarter'\n | 'year';\n\nexport type CustomRangeKey =\n | 'sinceMode'\n | 'sinceDatetime'\n | 'sinceGrain'\n | 'sinceGrainValue'\n | 'untilMode'\n | 'untilDatetime'\n | 'untilGrain'\n | 'untilGrainValue'\n | 'anchorMode'\n | 'anchorValue';\n\nexport type DateTimeModeType = 'specific' | 'relative' | 'now' | 'today';\n\nexport type CustomRangeType = {\n sinceMode: DateTimeModeType;\n sinceDatetime: string;\n sinceGrain: DateTimeGrainType;\n sinceGrainValue: number;\n untilMode: DateTimeModeType;\n untilDatetime: string;\n untilGrain: DateTimeGrainType;\n untilGrainValue: number;\n anchorMode: 'now' | 'specific';\n anchorValue: string;\n};\n\nexport type CustomRangeDecodeType = {\n customRange: CustomRangeType;\n matchedFlag: boolean;\n};\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA,WAAYA,uBAAuB,0BAAvBA,uBAAuB,GAAvBA,uBAAuB,iBAAvBA,uBAAuB,yBAAvBA,uBAAuB,gBAAvBA,uBAAuB,eAAvBA,uBAAuB,sBAAvBA,uBAAuB","ignoreList":[]}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Licensed to the Apache Software Foundation (ASF) under one
|
|
3
|
+
* or more contributor license agreements. See the NOTICE file
|
|
4
|
+
* distributed with this work for additional information
|
|
5
|
+
* regarding copyright ownership. The ASF licenses this file
|
|
6
|
+
* to you under the Apache License, Version 2.0 (the
|
|
7
|
+
* 'License'); you may not use this file except in compliance
|
|
8
|
+
* with the License. You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing,
|
|
13
|
+
* software distributed under the License is distributed on an
|
|
14
|
+
* 'AS IS' BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
15
|
+
* KIND, either express or implied. See the License for the
|
|
16
|
+
* specific language governing permissions and limitations
|
|
17
|
+
* under the License.
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
export const DEFAULT_D3_TIME_FORMAT = {
|
|
23
|
+
dateTime: '%x, %X',
|
|
24
|
+
date: '%-m/%-d/%Y',
|
|
25
|
+
time: '%-I:%M:%S %p',
|
|
26
|
+
periods: ['AM', 'PM'],
|
|
27
|
+
days: [
|
|
28
|
+
'Sunday',
|
|
29
|
+
'Monday',
|
|
30
|
+
'Tuesday',
|
|
31
|
+
'Wednesday',
|
|
32
|
+
'Thursday',
|
|
33
|
+
'Friday',
|
|
34
|
+
'Saturday'],
|
|
35
|
+
|
|
36
|
+
shortDays: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],
|
|
37
|
+
months: [
|
|
38
|
+
'January',
|
|
39
|
+
'February',
|
|
40
|
+
'March',
|
|
41
|
+
'April',
|
|
42
|
+
'May',
|
|
43
|
+
'June',
|
|
44
|
+
'July',
|
|
45
|
+
'August',
|
|
46
|
+
'September',
|
|
47
|
+
'October',
|
|
48
|
+
'November',
|
|
49
|
+
'December'],
|
|
50
|
+
|
|
51
|
+
shortMonths: [
|
|
52
|
+
'Jan',
|
|
53
|
+
'Feb',
|
|
54
|
+
'Mar',
|
|
55
|
+
'Apr',
|
|
56
|
+
'May',
|
|
57
|
+
'Jun',
|
|
58
|
+
'Jul',
|
|
59
|
+
'Aug',
|
|
60
|
+
'Sep',
|
|
61
|
+
'Oct',
|
|
62
|
+
'Nov',
|
|
63
|
+
'Dec']
|
|
64
|
+
|
|
65
|
+
};
|
|
66
|
+
//# sourceMappingURL=D3FormatConfig.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"D3FormatConfig.js","names":["DEFAULT_D3_TIME_FORMAT","dateTime","date","time","periods","days","shortDays","months","shortMonths"],"sources":["../../src/time-format/D3FormatConfig.ts"],"sourcesContent":["/**\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOTICE file\n * distributed with this work for additional information\n * regarding copyright ownership. The ASF licenses this file\n * to you under the Apache License, Version 2.0 (the\n * 'License'); you may not use this file except in compliance\n * with the License. You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing,\n * software distributed under the License is distributed on an\n * 'AS IS' BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n * KIND, either express or implied. See the License for the\n * specific language governing permissions and limitations\n * under the License.\n */\n\nimport { TimeLocaleDefinition } from 'd3-time-format';\n\nexport const DEFAULT_D3_TIME_FORMAT: TimeLocaleDefinition = {\n dateTime: '%x, %X',\n date: '%-m/%-d/%Y',\n time: '%-I:%M:%S %p',\n periods: ['AM', 'PM'],\n days: [\n 'Sunday',\n 'Monday',\n 'Tuesday',\n 'Wednesday',\n 'Thursday',\n 'Friday',\n 'Saturday',\n ],\n shortDays: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],\n months: [\n 'January',\n 'February',\n 'March',\n 'April',\n 'May',\n 'June',\n 'July',\n 'August',\n 'September',\n 'October',\n 'November',\n 'December',\n ],\n shortMonths: [\n 'Jan',\n 'Feb',\n 'Mar',\n 'Apr',\n 'May',\n 'Jun',\n 'Jul',\n 'Aug',\n 'Sep',\n 'Oct',\n 'Nov',\n 'Dec',\n ],\n};\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;AAIA,OAAO,MAAMA,sBAA4C,GAAG;EAC1DC,QAAQ,EAAE,QAAQ;EAClBC,IAAI,EAAE,YAAY;EAClBC,IAAI,EAAE,cAAc;EACpBC,OAAO,EAAE,CAAC,IAAI,EAAE,IAAI,CAAC;EACrBC,IAAI,EAAE;EACJ,QAAQ;EACR,QAAQ;EACR,SAAS;EACT,WAAW;EACX,UAAU;EACV,QAAQ;EACR,UAAU,CACX;;EACDC,SAAS,EAAE,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;EAC5DC,MAAM,EAAE;EACN,SAAS;EACT,UAAU;EACV,OAAO;EACP,OAAO;EACP,KAAK;EACL,MAAM;EACN,MAAM;EACN,QAAQ;EACR,WAAW;EACX,SAAS;EACT,UAAU;EACV,UAAU,CACX;;EACDC,WAAW,EAAE;EACX,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;;AAET,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
Licensed to the Apache Software Foundation (ASF) under one
|
|
3
|
+
or more contributor license agreements. See the NOTICE file
|
|
4
|
+
distributed with this work for additional information
|
|
5
|
+
regarding copyright ownership. The ASF licenses this file
|
|
6
|
+
to you under the Apache License, Version 2.0 (the
|
|
7
|
+
"License"); you may not use this file except in compliance
|
|
8
|
+
with the License. You may obtain a copy of the License at
|
|
9
|
+
|
|
10
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
|
|
12
|
+
Unless required by applicable law or agreed to in writing,
|
|
13
|
+
software distributed under the License is distributed on an
|
|
14
|
+
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
15
|
+
KIND, either express or implied. See the License for the
|
|
16
|
+
specific language governing permissions and limitations
|
|
17
|
+
under the License.
|
|
18
|
+
-->
|
|
19
|
+
|
|
20
|
+
## @superset-ui/core/time-format
|
|
21
|
+
|
|
22
|
+
Description
|
|
23
|
+
|
|
24
|
+
#### Example usage
|
|
25
|
+
|
|
26
|
+
```js
|
|
27
|
+
import { getTimeFormatter } from '@ohos-ports/superset-ui-core';
|
|
28
|
+
const formatter = getTimeFormatter('%Y-%m-d');
|
|
29
|
+
console.log(formatter(new Date()));
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
or
|
|
33
|
+
|
|
34
|
+
```js
|
|
35
|
+
import { formatTime } from '@ohos-ports/superset-ui-core';
|
|
36
|
+
console.log(formatTime('%Y-%m-d', new Date()));
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
It is powered by a registry to support registration of custom formatting, with fallback to
|
|
40
|
+
`d3.utcFormat` or `d3.timeFormat` (if the formatId starts with `local!`)
|
|
41
|
+
|
|
42
|
+
```js
|
|
43
|
+
import { getTimeFormatterRegistry, formatTime, TimeFormatter } from '@ohos-ports/superset-ui-core';
|
|
44
|
+
|
|
45
|
+
getTimeFormatterRegistry().registerValue('my_format', new TimeFormatter({
|
|
46
|
+
id: 'my_format',
|
|
47
|
+
formatFunc: v => `my special format of ${utcFormat('%Y')(v)}`
|
|
48
|
+
});
|
|
49
|
+
|
|
50
|
+
console.log(formatTime('my_format', new Date(2018)));
|
|
51
|
+
// prints 'my special format of 2018'
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
It also define constants for common d3 time formats. See
|
|
55
|
+
[TimeFormats.js](https://github.com/apache/superset/blob/master/superset-frontend/packages/superset-ui-core/src/time-format/TimeFormats.ts).
|
|
56
|
+
|
|
57
|
+
```js
|
|
58
|
+
import { TimeFormats } from '@ohos-ports/superset-ui-core';
|
|
59
|
+
|
|
60
|
+
TimeFormats.DATABASE_DATETIME; // '%Y-%m-%d %H:%M:%S'
|
|
61
|
+
TimeFormats.US_DATE; // '%m/%d/%Y'
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
#### API
|
|
65
|
+
|
|
66
|
+
`fn(args)`
|
|
67
|
+
|
|
68
|
+
- Do something
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Licensed to the Apache Software Foundation (ASF) under one
|
|
3
|
+
* or more contributor license agreements. See the NOTICE file
|
|
4
|
+
* distributed with this work for additional information
|
|
5
|
+
* regarding copyright ownership. The ASF licenses this file
|
|
6
|
+
* to you under the Apache License, Version 2.0 (the
|
|
7
|
+
* "License"); you may not use this file except in compliance
|
|
8
|
+
* with the License. You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing,
|
|
13
|
+
* software distributed under the License is distributed on an
|
|
14
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
15
|
+
* KIND, either express or implied. See the License for the
|
|
16
|
+
* specific language governing permissions and limitations
|
|
17
|
+
* under the License.
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
export const LOCAL_PREFIX = 'local!';
|
|
21
|
+
|
|
22
|
+
const DATABASE_DATETIME = '%Y-%m-%d %H:%M:%S';
|
|
23
|
+
const DATABASE_DATETIME_REVERSE = '%d-%m-%Y %H:%M:%S';
|
|
24
|
+
const US_DATE = '%m/%d/%Y';
|
|
25
|
+
const INTERNATIONAL_DATE = '%d/%m/%Y';
|
|
26
|
+
const DATABASE_DATE = '%Y-%m-%d';
|
|
27
|
+
const TIME = '%H:%M:%S';
|
|
28
|
+
|
|
29
|
+
const TimeFormats = {
|
|
30
|
+
DATABASE_DATE,
|
|
31
|
+
DATABASE_DATETIME,
|
|
32
|
+
DATABASE_DATETIME_REVERSE,
|
|
33
|
+
INTERNATIONAL_DATE,
|
|
34
|
+
TIME,
|
|
35
|
+
US_DATE
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
export default TimeFormats;
|
|
39
|
+
//# sourceMappingURL=TimeFormats.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TimeFormats.js","names":["LOCAL_PREFIX","DATABASE_DATETIME","DATABASE_DATETIME_REVERSE","US_DATE","INTERNATIONAL_DATE","DATABASE_DATE","TIME","TimeFormats"],"sources":["../../src/time-format/TimeFormats.ts"],"sourcesContent":["/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOTICE file\n * distributed with this work for additional information\n * regarding copyright ownership. The ASF licenses this file\n * to you under the Apache License, Version 2.0 (the\n * \"License\"); you may not use this file except in compliance\n * with the License. You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing,\n * software distributed under the License is distributed on an\n * \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n * KIND, either express or implied. See the License for the\n * specific language governing permissions and limitations\n * under the License.\n */\n\nexport const LOCAL_PREFIX = 'local!';\n\nconst DATABASE_DATETIME = '%Y-%m-%d %H:%M:%S';\nconst DATABASE_DATETIME_REVERSE = '%d-%m-%Y %H:%M:%S';\nconst US_DATE = '%m/%d/%Y';\nconst INTERNATIONAL_DATE = '%d/%m/%Y';\nconst DATABASE_DATE = '%Y-%m-%d';\nconst TIME = '%H:%M:%S';\n\nconst TimeFormats = {\n DATABASE_DATE,\n DATABASE_DATETIME,\n DATABASE_DATETIME_REVERSE,\n INTERNATIONAL_DATE,\n TIME,\n US_DATE,\n};\n\nexport default TimeFormats;\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAO,MAAMA,YAAY,GAAG,QAAQ;;AAEpC,MAAMC,iBAAiB,GAAG,mBAAmB;AAC7C,MAAMC,yBAAyB,GAAG,mBAAmB;AACrD,MAAMC,OAAO,GAAG,UAAU;AAC1B,MAAMC,kBAAkB,GAAG,UAAU;AACrC,MAAMC,aAAa,GAAG,UAAU;AAChC,MAAMC,IAAI,GAAG,UAAU;;AAEvB,MAAMC,WAAW,GAAG;EAClBF,aAAa;EACbJ,iBAAiB;EACjBC,yBAAyB;EACzBE,kBAAkB;EAClBE,IAAI;EACJH;AACF,CAAC;;AAED,eAAeI,WAAW","ignoreList":[]}
|