@ahoo-wang/wow-view-engine 10.0.0-alpha.6 → 10.0.0-alpha.7
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 +60 -16
- package/README.zh-CN.md +55 -16
- package/dist/{actions-CgaL6eEe.js → actions-BWlediub.js} +3992 -3957
- package/dist/actions-BWlediub.js.map +1 -0
- package/dist/analysis/additive.d.ts +2 -2
- package/dist/analysis/additive.d.ts.map +1 -1
- package/dist/analysis/boxplot.d.ts.map +1 -1
- package/dist/analysis/bucketChange.d.ts +1 -1
- package/dist/analysis/buckets.d.ts +5 -5
- package/dist/analysis/buckets.d.ts.map +1 -1
- package/dist/analysis/budget.d.ts.map +1 -1
- package/dist/analysis/candidates.d.ts +2 -1
- package/dist/analysis/candidates.d.ts.map +1 -1
- package/dist/analysis/candlestick.d.ts.map +1 -1
- package/dist/analysis/capability.d.ts.map +1 -1
- package/dist/analysis/cartesian.d.ts.map +1 -1
- package/dist/analysis/chartFamilies.d.ts +1 -1
- package/dist/analysis/chartOptions.d.ts +13 -2
- package/dist/analysis/chartOptions.d.ts.map +1 -1
- package/dist/analysis/chartSlots.d.ts.map +1 -1
- package/dist/analysis/compile.d.ts +1 -1
- package/dist/analysis/compile.d.ts.map +1 -1
- package/dist/analysis/currency.d.ts.map +1 -1
- package/dist/analysis/dangling.d.ts +2 -1
- package/dist/analysis/dangling.d.ts.map +1 -1
- package/dist/analysis/defaults.d.ts +10 -9
- package/dist/analysis/defaults.d.ts.map +1 -1
- package/dist/analysis/derived.d.ts +2 -2
- package/dist/analysis/derived.d.ts.map +1 -1
- package/dist/analysis/drill.d.ts +12 -6
- package/dist/analysis/drill.d.ts.map +1 -1
- package/dist/analysis/drillFilter.d.ts.map +1 -1
- package/dist/analysis/expand.d.ts +1 -1
- package/dist/analysis/expand.d.ts.map +1 -1
- package/dist/analysis/expressions.d.ts.map +1 -1
- package/dist/analysis/familyRules.d.ts +2 -2
- package/dist/analysis/familyRules.d.ts.map +1 -1
- package/dist/analysis/familySlots.d.ts +4 -4
- package/dist/analysis/fitCharts.d.ts +2 -2
- package/dist/analysis/fitCharts.d.ts.map +1 -1
- package/dist/analysis/formula.d.ts +10 -9
- package/dist/analysis/formula.d.ts.map +1 -1
- package/dist/analysis/granularity.d.ts +2 -2
- package/dist/analysis/granularity.d.ts.map +1 -1
- package/dist/analysis/having.d.ts +2 -1
- package/dist/analysis/having.d.ts.map +1 -1
- package/dist/analysis/logScale.d.ts +1 -1
- package/dist/analysis/metricCard.d.ts +2 -2
- package/dist/analysis/metricCard.d.ts.map +1 -1
- package/dist/analysis/metricCondition.d.ts +1 -1
- package/dist/analysis/metricCondition.d.ts.map +1 -1
- package/dist/analysis/metricFormat.d.ts +3 -2
- package/dist/analysis/metricFormat.d.ts.map +1 -1
- package/dist/analysis/metricOrder.d.ts +2 -2
- package/dist/analysis/metricOrder.d.ts.map +1 -1
- package/dist/analysis/metricWindow.d.ts.map +1 -1
- package/dist/analysis/project.d.ts +8 -3
- package/dist/analysis/project.d.ts.map +1 -1
- package/dist/analysis/serverLines.d.ts +5 -5
- package/dist/analysis/serverLines.d.ts.map +1 -1
- package/dist/analysis/splitOther.d.ts +1 -1
- package/dist/analysis/timeAxis.d.ts +3 -2
- package/dist/analysis/timeAxis.d.ts.map +1 -1
- package/dist/analysis/top.d.ts +1 -1
- package/dist/analysis/top.d.ts.map +1 -1
- package/dist/analysis/validateFamilies.d.ts.map +1 -1
- package/dist/analysis/validateGroups.d.ts.map +1 -1
- package/dist/analysis/validateLevels.d.ts.map +1 -1
- package/dist/analysis/validateMetrics.d.ts.map +1 -1
- package/dist/analysis/validateOffers.d.ts.map +1 -1
- package/dist/analysis/validateReferences.d.ts +2 -2
- package/dist/analysis/validateTop.d.ts +1 -1
- package/dist/analysis/validateTop.d.ts.map +1 -1
- package/dist/capabilities/aliases.d.ts.map +1 -1
- package/dist/capabilities/analysis.d.ts.map +1 -1
- package/dist/capabilities/cache.d.ts +3 -20
- package/dist/capabilities/cache.d.ts.map +1 -1
- package/dist/capabilities/fields.d.ts +2 -2
- package/dist/capabilities/fields.d.ts.map +1 -1
- package/dist/capabilities/match.d.ts +15 -5
- package/dist/capabilities/match.d.ts.map +1 -1
- package/dist/capabilities/narrow.d.ts.map +1 -1
- package/dist/capabilities/open.d.ts.map +1 -1
- package/dist/capabilities/record.d.ts.map +1 -1
- package/dist/{cartesianBrush-HLU12ig5.js → cartesianBrush-bgRuE6Ks.js} +3 -5
- package/dist/cartesianBrush-bgRuE6Ks.js.map +1 -0
- package/dist/dashboard/click.d.ts +9 -9
- package/dist/dashboard/click.d.ts.map +1 -1
- package/dist/dashboard/clickDraft.d.ts +1 -1
- package/dist/dashboard/edit.d.ts +6 -6
- package/dist/dashboard/filterEdit.d.ts +5 -6
- package/dist/dashboard/filterEdit.d.ts.map +1 -1
- package/dist/dashboard/filters.d.ts +9 -10
- package/dist/dashboard/filters.d.ts.map +1 -1
- package/dist/dashboard/index.d.ts +0 -1
- package/dist/dashboard/index.d.ts.map +1 -1
- package/dist/dashboard/layout.d.ts +2 -2
- package/dist/dashboard/merge.d.ts +2 -2
- package/dist/dashboard/panelLook.d.ts +1 -1
- package/dist/dashboard/panels.d.ts +1 -1
- package/dist/dashboard/timeBindings.d.ts +2 -12
- package/dist/dashboard/timeBindings.d.ts.map +1 -1
- package/dist/dashboard/validate.d.ts.map +1 -1
- package/dist/dashboard/validateFilters.d.ts +2 -2
- package/dist/dashboard/wiring.d.ts +5 -5
- package/dist/{echarts-HUGzxow7.js → echarts-rjTKpBsf.js} +3 -4
- package/dist/{echarts-HUGzxow7.js.map → echarts-rjTKpBsf.js.map} +1 -1
- package/dist/{echartsGeo-BWbXo9ef.js → echartsGeo-qZv2ZF9e.js} +2 -3
- package/dist/{echartsGeo-BWbXo9ef.js.map → echartsGeo-qZv2ZF9e.js.map} +1 -1
- package/dist/{echartsHierarchy-Cm-9-LN9.js → echartsHierarchy-DHNP9W4v.js} +2 -3
- package/dist/{echartsHierarchy-Cm-9-LN9.js.map → echartsHierarchy-DHNP9W4v.js.map} +1 -1
- package/dist/{echartsStatistics-Lq-BjHez.js → echartsStatistics-DCDWqvde.js} +2 -3
- package/dist/{echartsStatistics-Lq-BjHez.js.map → echartsStatistics-DCDWqvde.js.map} +1 -1
- package/dist/{echartsTime-gMH0oF0x.js → echartsTime-DIRSRMnr.js} +2 -3
- package/dist/{echartsTime-gMH0oF0x.js.map → echartsTime-DIRSRMnr.js.map} +1 -1
- package/dist/export-BCADqfu6.js +29 -0
- package/dist/export-BCADqfu6.js.map +1 -0
- package/dist/filter/describe.d.ts +6 -6
- package/dist/filter/describe.d.ts.map +1 -1
- package/dist/filter/kinds/array.d.ts.map +1 -1
- package/dist/filter/kinds/boolean.d.ts.map +1 -1
- package/dist/filter/kinds/dateTime.d.ts.map +1 -1
- package/dist/filter/kinds/deletion.d.ts +2 -2
- package/dist/filter/kinds/deletion.d.ts.map +1 -1
- package/dist/filter/kinds/duration.d.ts.map +1 -1
- package/dist/filter/kinds/elementMatch.d.ts.map +1 -1
- package/dist/filter/kinds/entries.d.ts.map +1 -1
- package/dist/filter/kinds/enum.d.ts.map +1 -1
- package/dist/filter/kinds/metadata.d.ts.map +1 -1
- package/dist/filter/kinds/number.d.ts.map +1 -1
- package/dist/filter/kinds/presence.d.ts +1 -0
- package/dist/filter/kinds/presence.d.ts.map +1 -1
- package/dist/filter/kinds/reference.d.ts +5 -0
- package/dist/filter/kinds/reference.d.ts.map +1 -1
- package/dist/filter/kinds/string.d.ts.map +1 -1
- package/dist/filter/operatorWords.d.ts +21 -0
- package/dist/filter/operatorWords.d.ts.map +1 -0
- package/dist/filter/search.d.ts.map +1 -1
- package/dist/filter/time.d.ts +2 -2
- package/dist/filter/time.d.ts.map +1 -1
- package/dist/filter/tree.d.ts.map +1 -1
- package/dist/filter/validate.d.ts.map +1 -1
- package/dist/filter/values.d.ts +6 -5
- package/dist/filter/values.d.ts.map +1 -1
- package/dist/index.d.ts +53 -89
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +224 -223
- package/dist/index.js.map +1 -1
- package/dist/model/analysis.d.ts +61 -59
- package/dist/model/analysis.d.ts.map +1 -1
- package/dist/model/chart.d.ts +16 -6
- package/dist/model/chart.d.ts.map +1 -1
- package/dist/model/config.d.ts +2 -2
- package/dist/model/dashboard.d.ts +28 -48
- package/dist/model/dashboard.d.ts.map +1 -1
- package/dist/model/definition.d.ts +17 -17
- package/dist/model/definition.d.ts.map +1 -1
- package/dist/model/field.d.ts +35 -5
- package/dist/model/field.d.ts.map +1 -1
- package/dist/model/filter.d.ts +5 -5
- package/dist/model/filter.d.ts.map +1 -1
- package/dist/model/index.d.ts +2 -0
- package/dist/model/index.d.ts.map +1 -1
- package/dist/model/limits.d.ts +29 -0
- package/dist/model/limits.d.ts.map +1 -1
- package/dist/model/record.d.ts +7 -6
- package/dist/model/record.d.ts.map +1 -1
- package/dist/model/text.d.ts +1 -1
- package/dist/model/values.d.ts +8 -0
- package/dist/model/values.d.ts.map +1 -0
- package/dist/model/wire.d.ts +32 -0
- package/dist/model/wire.d.ts.map +1 -0
- package/dist/react/actionRunner.d.ts +8 -1
- package/dist/react/actionRunner.d.ts.map +1 -1
- package/dist/react/analysisEditing.d.ts +79 -46
- package/dist/react/analysisEditing.d.ts.map +1 -1
- package/dist/react/analysisFields.d.ts +5 -5
- package/dist/react/analysisFields.d.ts.map +1 -1
- package/dist/react/engineContext.d.ts +17 -0
- package/dist/react/engineContext.d.ts.map +1 -0
- package/dist/react/index.d.ts +17 -15
- package/dist/react/index.d.ts.map +1 -1
- package/dist/react/issues.d.ts +0 -1
- package/dist/react/issues.d.ts.map +1 -1
- package/dist/react/manager/wording.d.ts +1 -1
- package/dist/react/manager/wording.d.ts.map +1 -1
- package/dist/react/recordColumns.d.ts +1 -1
- package/dist/react/recordColumns.d.ts.map +1 -1
- package/dist/react/recordDraft.d.ts.map +1 -1
- package/dist/react/recordEdits.d.ts.map +1 -1
- package/dist/react/referenceNames.d.ts +20 -0
- package/dist/react/referenceNames.d.ts.map +1 -0
- package/dist/react/useAnalysisEditor.d.ts +10 -9
- package/dist/react/useAnalysisEditor.d.ts.map +1 -1
- package/dist/react/useAnalysisResult.d.ts +17 -3
- package/dist/react/useAnalysisResult.d.ts.map +1 -1
- package/dist/react/useAutoRefresh.d.ts +8 -6
- package/dist/react/useAutoRefresh.d.ts.map +1 -1
- package/dist/react/useCreateViewEngine.d.ts +11 -0
- package/dist/react/useCreateViewEngine.d.ts.map +1 -0
- package/dist/react/useDashboard.d.ts +12 -5
- package/dist/react/useDashboard.d.ts.map +1 -1
- package/dist/react/useDatasets.d.ts +33 -21
- package/dist/react/useDatasets.d.ts.map +1 -1
- package/dist/react/useFilterEditor.d.ts.map +1 -1
- package/dist/react/{useViewEngine.d.ts → useOpenView.d.ts} +22 -36
- package/dist/react/useOpenView.d.ts.map +1 -0
- package/dist/react/usePanelFollowUps.d.ts +11 -2
- package/dist/react/usePanelFollowUps.d.ts.map +1 -1
- package/dist/react/useRecordActions.d.ts +14 -3
- package/dist/react/useRecordActions.d.ts.map +1 -1
- package/dist/react/useRecordDetail.d.ts +9 -6
- package/dist/react/useRecordDetail.d.ts.map +1 -1
- package/dist/react/useRecordExport.d.ts +5 -1
- package/dist/react/useRecordExport.d.ts.map +1 -1
- package/dist/react/useRecordKanban.d.ts +1 -1
- package/dist/react/useRecordTable.d.ts +2 -4
- package/dist/react/useRecordTable.d.ts.map +1 -1
- package/dist/react/useReferenceLabels.d.ts +9 -0
- package/dist/react/useReferenceLabels.d.ts.map +1 -0
- package/dist/react/useReshape.d.ts +2 -2
- package/dist/react/useSaveCommands.d.ts +3 -7
- package/dist/react/useSaveCommands.d.ts.map +1 -1
- package/dist/react/useValueCandidates.d.ts +17 -6
- package/dist/react/useValueCandidates.d.ts.map +1 -1
- package/dist/react/useViewList.d.ts +23 -11
- package/dist/react/useViewList.d.ts.map +1 -1
- package/dist/react/useViewManager.d.ts +6 -1
- package/dist/react/useViewManager.d.ts.map +1 -1
- package/dist/react/useViewRuntime.d.ts +23 -0
- package/dist/react/useViewRuntime.d.ts.map +1 -0
- package/dist/react/useWorkbench.d.ts +1 -1
- package/dist/react/useWorkbench.d.ts.map +1 -1
- package/dist/react/workbench/handOver.d.ts +10 -3
- package/dist/react/workbench/handOver.d.ts.map +1 -1
- package/dist/react/workbench/releaseDeleted.d.ts +13 -6
- package/dist/react/workbench/releaseDeleted.d.ts.map +1 -1
- package/dist/react-D1wSQhlr.js +4196 -0
- package/dist/react-D1wSQhlr.js.map +1 -0
- package/dist/react-router/index.d.ts +1 -0
- package/dist/react-router/index.d.ts.map +1 -1
- package/dist/react-router.js +1 -2
- package/dist/react-router.js.map +1 -1
- package/dist/react.js +1 -3
- package/dist/record/compile.d.ts.map +1 -1
- package/dist/record/kanban.d.ts +2 -2
- package/dist/record/kanban.d.ts.map +1 -1
- package/dist/record/paging.d.ts +11 -2
- package/dist/record/paging.d.ts.map +1 -1
- package/dist/record/project.d.ts +17 -1
- package/dist/record/project.d.ts.map +1 -1
- package/dist/record/summaryCurrency.d.ts.map +1 -1
- package/dist/record/validate.d.ts.map +1 -1
- package/dist/{routes-DvPNPlQP.js → routes-CMXKbAo2.js} +2 -3
- package/dist/{routes-DvPNPlQP.js.map → routes-CMXKbAo2.js.map} +1 -1
- package/dist/runtime/actions.d.ts +19 -7
- package/dist/runtime/actions.d.ts.map +1 -1
- package/dist/runtime/autoApply.d.ts +1 -1
- package/dist/runtime/capabilities.d.ts +2 -2
- package/dist/runtime/capabilities.d.ts.map +1 -1
- package/dist/runtime/dashboard/anchor.d.ts +2 -2
- package/dist/runtime/dashboard/anchor.d.ts.map +1 -1
- package/dist/runtime/dashboard/canonical.d.ts +2 -2
- package/dist/runtime/dashboard/commands.d.ts +2 -2
- package/dist/runtime/dashboard/commands.d.ts.map +1 -1
- package/dist/runtime/dashboard/contract.d.ts +6 -6
- package/dist/runtime/dashboard/contract.d.ts.map +1 -1
- package/dist/runtime/dashboard/editing.d.ts +2 -2
- package/dist/runtime/dashboard/filterCandidates.d.ts +1 -1
- package/dist/runtime/dashboard/filterValues.d.ts +16 -4
- package/dist/runtime/dashboard/filterValues.d.ts.map +1 -1
- package/dist/runtime/dashboard/grouping.d.ts +4 -4
- package/dist/runtime/dashboard/grouping.d.ts.map +1 -1
- package/dist/runtime/dashboard/panelRun.d.ts +2 -2
- package/dist/runtime/dashboard/panels.d.ts +1 -1
- package/dist/runtime/dashboard/press.d.ts +1 -1
- package/dist/runtime/dashboard/press.d.ts.map +1 -1
- package/dist/runtime/dashboard/references.d.ts +1 -1
- package/dist/runtime/dashboard/references.d.ts.map +1 -1
- package/dist/runtime/dashboardRuntime.d.ts +5 -2
- package/dist/runtime/dashboardRuntime.d.ts.map +1 -1
- package/dist/runtime/datasetResources.d.ts +57 -70
- package/dist/runtime/datasetResources.d.ts.map +1 -1
- package/dist/runtime/define/defineDataset.d.ts +1 -1
- package/dist/runtime/define/defineView.d.ts +1 -1
- package/dist/runtime/define/defineView.d.ts.map +1 -1
- package/dist/runtime/define/fields.d.ts +2 -2
- package/dist/runtime/define/fields.d.ts.map +1 -1
- package/dist/runtime/define/spec.d.ts +5 -1
- package/dist/runtime/define/spec.d.ts.map +1 -1
- package/dist/runtime/deprecated.d.ts.map +1 -1
- package/dist/runtime/environment.d.ts +95 -47
- package/dist/runtime/environment.d.ts.map +1 -1
- package/dist/runtime/execute.d.ts +2 -2
- package/dist/runtime/execute.d.ts.map +1 -1
- package/dist/runtime/exportRows.d.ts +10 -0
- package/dist/runtime/exportRows.d.ts.map +1 -1
- package/dist/runtime/failure/failures.d.ts +23 -11
- package/dist/runtime/failure/failures.d.ts.map +1 -1
- package/dist/runtime/failure/queryFailure.d.ts +1 -1
- package/dist/runtime/failure/queryFailure.d.ts.map +1 -1
- package/dist/runtime/failure/unavailable.d.ts +1 -1
- package/dist/runtime/fetchRecord.d.ts.map +1 -1
- package/dist/runtime/index.d.ts +5 -3
- package/dist/runtime/index.d.ts.map +1 -1
- package/dist/runtime/instanceWrites.d.ts +15 -9
- package/dist/runtime/instanceWrites.d.ts.map +1 -1
- package/dist/runtime/kanban.d.ts +1 -1
- package/dist/runtime/labelIds.d.ts +56 -0
- package/dist/runtime/labelIds.d.ts.map +1 -0
- package/dist/runtime/navigation.d.ts +6 -6
- package/dist/runtime/panelViews.d.ts +3 -5
- package/dist/runtime/panelViews.d.ts.map +1 -1
- package/dist/runtime/pending.d.ts +2 -2
- package/dist/runtime/permissions.d.ts +2 -2
- package/dist/runtime/preferences.d.ts +2 -2
- package/dist/runtime/preferences.d.ts.map +1 -1
- package/dist/runtime/queryWeight.d.ts.map +1 -1
- package/dist/runtime/recordRuntime.d.ts +10 -1
- package/dist/runtime/recordRuntime.d.ts.map +1 -1
- package/dist/runtime/referenceLabels.d.ts +170 -0
- package/dist/runtime/referenceLabels.d.ts.map +1 -0
- package/dist/runtime/resources.d.ts +31 -93
- package/dist/runtime/resources.d.ts.map +1 -1
- package/dist/runtime/restyle.d.ts +1 -1
- package/dist/runtime/runtimeFactory.d.ts +5 -4
- package/dist/runtime/runtimeFactory.d.ts.map +1 -1
- package/dist/runtime/source.d.ts +55 -48
- package/dist/runtime/source.d.ts.map +1 -1
- package/dist/runtime/summaries.d.ts +9 -1
- package/dist/runtime/summaries.d.ts.map +1 -1
- package/dist/runtime/tabMemory.d.ts +1 -1
- package/dist/runtime/validateFields.d.ts.map +1 -1
- package/dist/runtime/valueCandidates.d.ts.map +1 -1
- package/dist/runtime/viewEngine.d.ts +97 -105
- package/dist/runtime/viewEngine.d.ts.map +1 -1
- package/dist/runtime/viewEngineOptions.d.ts +79 -0
- package/dist/runtime/viewEngineOptions.d.ts.map +1 -0
- package/dist/runtime/viewRuntime.d.ts +6 -9
- package/dist/runtime/viewRuntime.d.ts.map +1 -1
- package/dist/runtime/viewRuntimeTypes.d.ts +39 -8
- package/dist/runtime/viewRuntimeTypes.d.ts.map +1 -1
- package/dist/store/MemoryViewStore.d.ts +16 -16
- package/dist/store/MemoryViewStore.d.ts.map +1 -1
- package/dist/store/ViewStore.d.ts +31 -19
- package/dist/store/ViewStore.d.ts.map +1 -1
- package/dist/testing/actions.d.ts +6 -4
- package/dist/testing/actions.d.ts.map +1 -1
- package/dist/testing/aggregate.d.ts +4 -2
- package/dist/testing/aggregate.d.ts.map +1 -1
- package/dist/testing/filter.d.ts +3 -3
- package/dist/testing/filter.d.ts.map +1 -1
- package/dist/testing/index.d.ts +2 -2
- package/dist/testing/index.d.ts.map +1 -1
- package/dist/testing/source.d.ts +4 -4
- package/dist/testing/source.d.ts.map +1 -1
- package/dist/testing.js +99 -96
- package/dist/testing.js.map +1 -1
- package/dist/theme-check.mjs +102 -127
- package/dist/ui/DashboardWorkbench.d.ts +2 -2
- package/dist/ui/DashboardWorkbench.d.ts.map +1 -1
- package/dist/ui/DataWorkbench.d.ts +2 -2
- package/dist/ui/DataWorkbench.d.ts.map +1 -1
- package/dist/ui/DatasetWorkbench.d.ts +11 -21
- package/dist/ui/DatasetWorkbench.d.ts.map +1 -1
- package/dist/ui/EmbeddedDashboard.d.ts +1 -1
- package/dist/ui/EmbeddedDashboard.d.ts.map +1 -1
- package/dist/ui/EmbeddedView.d.ts +1 -1
- package/dist/ui/ViewHost.d.ts +6 -6
- package/dist/ui/ViewHost.d.ts.map +1 -1
- package/dist/ui/actions/ActionSurface.d.ts.map +1 -1
- package/dist/ui/actions/BulkStatus.d.ts.map +1 -1
- package/dist/ui/actions/kanbanMove.d.ts +1 -1
- package/dist/ui/analysis/AnalysisTable.d.ts.map +1 -1
- package/dist/ui/analysis/AnalysisToolbar.d.ts +1 -1
- package/dist/ui/analysis/AnalysisToolbar.d.ts.map +1 -1
- package/dist/ui/analysis/AxesTab.d.ts +1 -1
- package/dist/ui/analysis/CardMenu.d.ts +1 -1
- package/dist/ui/analysis/ChartOptions.d.ts +1 -1
- package/dist/ui/analysis/ChartOptions.d.ts.map +1 -1
- package/dist/ui/analysis/ChartPicker.d.ts +1 -1
- package/dist/ui/analysis/CompositionOptions.d.ts +1 -1
- package/dist/ui/analysis/CurrencyStrip.d.ts.map +1 -1
- package/dist/ui/analysis/DataTab.d.ts +1 -1
- package/dist/ui/analysis/DimensionCard.d.ts.map +1 -1
- package/dist/ui/analysis/DisplayTab.d.ts +1 -1
- package/dist/ui/analysis/DisplayTab.d.ts.map +1 -1
- package/dist/ui/analysis/DrillMenu.d.ts +1 -1
- package/dist/ui/analysis/DroppedNotice.d.ts +1 -1
- package/dist/ui/analysis/ElementsSlot.d.ts +1 -1
- package/dist/ui/analysis/ExportMenu.d.ts +3 -3
- package/dist/ui/analysis/ExportMenu.d.ts.map +1 -1
- package/dist/ui/analysis/FormulaCard.d.ts.map +1 -1
- package/dist/ui/analysis/HavingRows.d.ts +1 -1
- package/dist/ui/analysis/HavingRows.d.ts.map +1 -1
- package/dist/ui/analysis/LevelOptions.d.ts +1 -1
- package/dist/ui/analysis/MapOptions.d.ts +1 -1
- package/dist/ui/analysis/MetricCard.d.ts +1 -1
- package/dist/ui/analysis/MetricCard.d.ts.map +1 -1
- package/dist/ui/analysis/MetricCondition.d.ts +1 -1
- package/dist/ui/analysis/MetricCondition.d.ts.map +1 -1
- package/dist/ui/analysis/MetricSlot.d.ts +1 -1
- package/dist/ui/analysis/MetricSlot.d.ts.map +1 -1
- package/dist/ui/analysis/RangeSlot.d.ts +1 -1
- package/dist/ui/analysis/ReferenceOptions.d.ts +1 -1
- package/dist/ui/analysis/TermTip.d.ts +1 -1
- package/dist/ui/analysis/TopRow.d.ts +1 -1
- package/dist/ui/analysis/TopRow.d.ts.map +1 -1
- package/dist/ui/analysis/Tray.d.ts +1 -1
- package/dist/ui/analysis/Tray.d.ts.map +1 -1
- package/dist/ui/analysis/VisualizationPanel.d.ts +2 -2
- package/dist/ui/analysis/VisualizationPanel.d.ts.map +1 -1
- package/dist/ui/analysis/editing.d.ts +2 -2
- package/dist/ui/analysis/editing.d.ts.map +1 -1
- package/dist/ui/analysis/exportOffer.d.ts +3 -3
- package/dist/ui/analysis/headerSort.d.ts.map +1 -1
- package/dist/ui/analysis/imageExport.d.ts +3 -3
- package/dist/ui/analysis/imageExport.d.ts.map +1 -1
- package/dist/ui/charts/EChart.d.ts +2 -2
- package/dist/ui/charts/GeoMap.d.ts +1 -1
- package/dist/ui/charts/Heatmap.d.ts +1 -1
- package/dist/ui/charts/MetricCard.d.ts.map +1 -1
- package/dist/ui/charts/PieSlices.d.ts +1 -1
- package/dist/ui/charts/ScatterPoints.d.ts +1 -1
- package/dist/ui/charts/ScatterPoints.d.ts.map +1 -1
- package/dist/ui/charts/axis.d.ts +2 -2
- package/dist/ui/charts/cartesianTooltip.d.ts +2 -2
- package/dist/ui/charts/dateTicks.d.ts +2 -2
- package/dist/ui/charts/dateTicks.d.ts.map +1 -1
- package/dist/ui/charts/family.d.ts +1 -1
- package/dist/ui/charts/family.d.ts.map +1 -1
- package/dist/ui/charts/familyViews.d.ts +1 -1
- package/dist/ui/charts/frameClass.d.ts +2 -2
- package/dist/ui/charts/highlight.d.ts +2 -2
- package/dist/ui/charts/image.d.ts +22 -6
- package/dist/ui/charts/image.d.ts.map +1 -1
- package/dist/ui/charts/maps.d.ts +1 -1
- package/dist/ui/charts/waterfallOption.d.ts +2 -2
- package/dist/ui/colorMode.d.ts +1 -2
- package/dist/ui/colorMode.d.ts.map +1 -1
- package/dist/ui/columns/ColumnSettings.d.ts +6 -1
- package/dist/ui/columns/ColumnSettings.d.ts.map +1 -1
- package/dist/ui/dashboard/AddMenu.d.ts +2 -2
- package/dist/ui/dashboard/Board.d.ts +1 -1
- package/dist/ui/dashboard/BoardDestination.d.ts +2 -2
- package/dist/ui/dashboard/BoardFilters.d.ts +1 -1
- package/dist/ui/dashboard/BoardWidth.d.ts +1 -1
- package/dist/ui/dashboard/ClickSettings.d.ts +4 -4
- package/dist/ui/dashboard/ContentEditor.d.ts +1 -1
- package/dist/ui/dashboard/DashboardArrange.d.ts +1 -1
- package/dist/ui/dashboard/DashboardGrid.d.ts +3 -3
- package/dist/ui/dashboard/DashboardGrid.d.ts.map +1 -1
- package/dist/ui/dashboard/{DashboardPanel.d.ts → DashboardPanelCard.d.ts} +3 -3
- package/dist/ui/dashboard/DashboardPanelCard.d.ts.map +1 -0
- package/dist/ui/dashboard/DashboardPanels.d.ts +4 -4
- package/dist/ui/dashboard/DashboardPanels.d.ts.map +1 -1
- package/dist/ui/dashboard/DashboardTabs.d.ts +1 -1
- package/dist/ui/dashboard/EditBar.d.ts +1 -1
- package/dist/ui/dashboard/FilterBar.d.ts +1 -1
- package/dist/ui/dashboard/FilterOrder.d.ts +1 -1
- package/dist/ui/dashboard/FilterReadings.d.ts +1 -1
- package/dist/ui/dashboard/FilterReadings.d.ts.map +1 -1
- package/dist/ui/dashboard/FilterSettings.d.ts +2 -2
- package/dist/ui/dashboard/FilterSettings.d.ts.map +1 -1
- package/dist/ui/dashboard/FilterSheet.d.ts +1 -1
- package/dist/ui/dashboard/FilterWiring.d.ts +2 -2
- package/dist/ui/dashboard/GridBlocksLayer.d.ts +1 -1
- package/dist/ui/dashboard/GroupingControl.d.ts +4 -4
- package/dist/ui/dashboard/GroupingControl.d.ts.map +1 -1
- package/dist/ui/dashboard/NewAnalysisDialog.d.ts +1 -1
- package/dist/ui/dashboard/NewAnalysisDialog.d.ts.map +1 -1
- package/dist/ui/dashboard/PanelBodies.d.ts +9 -8
- package/dist/ui/dashboard/PanelBodies.d.ts.map +1 -1
- package/dist/ui/dashboard/PanelExport.d.ts +3 -3
- package/dist/ui/dashboard/PanelMenu.d.ts +1 -1
- package/dist/ui/dashboard/PresentationDialog.d.ts +1 -1
- package/dist/ui/dashboard/PresentationDialog.d.ts.map +1 -1
- package/dist/ui/dashboard/ScrollCue.d.ts +1 -1
- package/dist/ui/dashboard/ViewPicker.d.ts +1 -1
- package/dist/ui/dashboard/ViewPicker.d.ts.map +1 -1
- package/dist/ui/dashboard/buildShell.d.ts +2 -2
- package/dist/ui/dashboard/building.d.ts +1 -1
- package/dist/ui/dashboard/building.d.ts.map +1 -1
- package/dist/ui/dashboard/commands.d.ts +4 -4
- package/dist/ui/dashboard/commands.d.ts.map +1 -1
- package/dist/ui/dashboard/extensions.d.ts +1 -1
- package/dist/ui/dashboard/filterModes.d.ts +3 -3
- package/dist/ui/dashboard/filterOutcome.d.ts.map +1 -1
- package/dist/ui/dashboard/findings.d.ts +1 -1
- package/dist/ui/dashboard/gridBlocks.d.ts +1 -1
- package/dist/ui/dashboard/panelFit.d.ts +2 -2
- package/dist/ui/dashboard/press.d.ts +2 -2
- package/dist/ui/dashboard/press.d.ts.map +1 -1
- package/dist/ui/dashboard/reveal.d.ts +1 -1
- package/dist/ui/dashboard/scrollMore.d.ts +1 -1
- package/dist/ui/datasetBindings.d.ts +3 -11
- package/dist/ui/datasetBindings.d.ts.map +1 -1
- package/dist/ui/embed/EmbedFrame.d.ts +1 -1
- package/dist/ui/embed/EmbedFrame.d.ts.map +1 -1
- package/dist/ui/embed/EmbedHead.d.ts +5 -5
- package/dist/ui/embed/EmbedHead.d.ts.map +1 -1
- package/dist/ui/embed/EmbeddedAnalysis.d.ts +4 -4
- package/dist/ui/embed/EmbeddedAnalysis.d.ts.map +1 -1
- package/dist/ui/embed/EmbeddedRecord.d.ts +1 -1
- package/dist/ui/embed/options.d.ts +4 -4
- package/dist/ui/embed/options.d.ts.map +1 -1
- package/dist/ui/filter/inputs/duration.d.ts.map +1 -1
- package/dist/ui/filter/inputs/remote.d.ts +3 -1
- package/dist/ui/filter/inputs/remote.d.ts.map +1 -1
- package/dist/ui/index.d.ts +6 -7
- package/dist/ui/index.d.ts.map +1 -1
- package/dist/ui/kit/ExportDialog.d.ts +2 -2
- package/dist/ui/kit/ExportDialog.d.ts.map +1 -1
- package/dist/ui/kit/IconButton.d.ts +1 -1
- package/dist/ui/kit/MessagesProvider.d.ts +3 -3
- package/dist/ui/kit/RenameInput.d.ts +2 -2
- package/dist/ui/kit/RenderBoundary.d.ts.map +1 -1
- package/dist/ui/kit/RowItem.d.ts +1 -1
- package/dist/ui/kit/ViewSurface.d.ts +16 -6
- package/dist/ui/kit/ViewSurface.d.ts.map +1 -1
- package/dist/ui/kit/alerts.d.ts +2 -2
- package/dist/ui/kit/alerts.d.ts.map +1 -1
- package/dist/ui/kit/chartFailure.d.ts +1 -3
- package/dist/ui/kit/chartFailure.d.ts.map +1 -1
- package/dist/ui/kit/datePart.d.ts +2 -2
- package/dist/ui/kit/datePart.d.ts.map +1 -1
- package/dist/ui/kit/display.d.ts +25 -6
- package/dist/ui/kit/display.d.ts.map +1 -1
- package/dist/ui/kit/dragPlugins.d.ts +3 -3
- package/dist/ui/kit/failureSink.d.ts +1 -1
- package/dist/ui/kit/failureSink.d.ts.map +1 -1
- package/dist/ui/kit/features.d.ts +2 -2
- package/dist/ui/kit/features.d.ts.map +1 -1
- package/dist/ui/kit/icon.d.ts +9 -0
- package/dist/ui/kit/icon.d.ts.map +1 -0
- package/dist/ui/kit/kinds.d.ts +4 -4
- package/dist/ui/kit/kinds.d.ts.map +1 -1
- package/dist/ui/kit/layout.d.ts +2 -2
- package/dist/ui/kit/messages.d.ts.map +1 -1
- package/dist/ui/kit/presets.d.ts +2 -2
- package/dist/ui/kit/summary.d.ts +8 -10
- package/dist/ui/kit/summary.d.ts.map +1 -1
- package/dist/ui/kit/surfaceContext.d.ts +4 -3
- package/dist/ui/kit/surfaceContext.d.ts.map +1 -1
- package/dist/ui/kit/surfaceKeys.d.ts +1 -1
- package/dist/ui/kit/toolbar.d.ts +21 -4
- package/dist/ui/kit/toolbar.d.ts.map +1 -1
- package/dist/ui/kit/variants.d.ts +5 -5
- package/dist/ui/manage/DatasetWordingForm.d.ts +2 -2
- package/dist/ui/messages/analysis.d.ts +61 -57
- package/dist/ui/messages/analysis.d.ts.map +1 -1
- package/dist/ui/messages/building.d.ts +1 -1
- package/dist/ui/messages/capabilities.d.ts +5 -1
- package/dist/ui/messages/capabilities.d.ts.map +1 -1
- package/dist/ui/messages/clicks.d.ts +1 -1
- package/dist/ui/messages/datasets.d.ts +3 -2
- package/dist/ui/messages/datasets.d.ts.map +1 -1
- package/dist/ui/messages/definition.d.ts +2 -1
- package/dist/ui/messages/definition.d.ts.map +1 -1
- package/dist/ui/messages/embed.d.ts +1 -1
- package/dist/ui/messages/en.d.ts +238 -221
- package/dist/ui/messages/en.d.ts.map +1 -1
- package/dist/ui/messages/export.d.ts +1 -1
- package/dist/ui/messages/filter.d.ts +98 -98
- package/dist/ui/messages/filter.d.ts.map +1 -1
- package/dist/ui/messages/filters.d.ts +1 -1
- package/dist/ui/messages/record.d.ts +20 -15
- package/dist/ui/messages/record.d.ts.map +1 -1
- package/dist/ui/messages/view.d.ts +51 -49
- package/dist/ui/messages/view.d.ts.map +1 -1
- package/dist/ui/messages/wireKey.d.ts +17 -0
- package/dist/ui/messages/wireKey.d.ts.map +1 -0
- package/dist/ui/messages/zh-CN.d.ts.map +1 -1
- package/dist/ui/record/CardSettings.d.ts.map +1 -1
- package/dist/ui/record/CardSummaries.d.ts +1 -1
- package/dist/ui/record/OffscreenSummary.d.ts +1 -1
- package/dist/ui/record/RecordDetail.d.ts +1 -2
- package/dist/ui/record/RecordDetail.d.ts.map +1 -1
- package/dist/ui/record/RecordKanban.d.ts +1 -1
- package/dist/ui/record/RecordPagination.d.ts +3 -1
- package/dist/ui/record/RecordPagination.d.ts.map +1 -1
- package/dist/ui/record/SelectionBar.d.ts +2 -2
- package/dist/ui/record/SortableHeader.d.ts.map +1 -1
- package/dist/ui/record/cells.d.ts.map +1 -1
- package/dist/ui/record/exportOffer.d.ts +1 -1
- package/dist/ui/record/exportOffer.d.ts.map +1 -1
- package/dist/ui/record/kanbanDrag.d.ts +2 -2
- package/dist/ui/record/offscreenSummaries.d.ts +2 -2
- package/dist/ui/record/overflow.d.ts +1 -1
- package/dist/ui/record/queryAnnouncement.d.ts.map +1 -1
- package/dist/ui/record/resultCount.d.ts +10 -0
- package/dist/ui/record/resultCount.d.ts.map +1 -0
- package/dist/ui/record/sticky.d.ts +1 -1
- package/dist/ui/record/useOffscreenColumns.d.ts +1 -1
- package/dist/ui/record/useSummaries.d.ts.map +1 -1
- package/dist/ui/sort/SortSettings.d.ts.map +1 -1
- package/dist/ui/theme/tokens.d.ts +1 -1
- package/dist/ui/viewNavigation.d.ts.map +1 -1
- package/dist/ui/workbench/AddToDashboardDialog.d.ts +1 -1
- package/dist/ui/workbench/AnalysisParts.d.ts +1 -1
- package/dist/ui/workbench/MoreViewActions.d.ts +1 -1
- package/dist/ui/workbench/OriginBar.d.ts +1 -1
- package/dist/ui/workbench/ResultBlock.d.ts +1 -1
- package/dist/ui/workbench/Sidebar.d.ts +2 -2
- package/dist/ui/workbench/StatusLine.d.ts +1 -1
- package/dist/ui/workbench/ViewEngineProvider.d.ts +0 -9
- package/dist/ui/workbench/ViewEngineProvider.d.ts.map +1 -1
- package/dist/ui/workbench/WorkbenchShell.d.ts +3 -3
- package/dist/ui/workbench/WorkbenchShell.d.ts.map +1 -1
- package/dist/ui/workbench/address.d.ts.map +1 -1
- package/dist/ui.js +13764 -13812
- package/dist/ui.js.map +1 -1
- package/dist/{viewRuntimeTypes-B3B6hbXr.js → viewRuntimeTypes-BCdG5xRp.js} +1950 -2122
- package/dist/viewRuntimeTypes-BCdG5xRp.js.map +1 -0
- package/package.json +13 -13
- package/dist/actions-CgaL6eEe.js.map +0 -1
- package/dist/cartesianBrush-HLU12ig5.js.map +0 -1
- package/dist/clickDraft-CdUtkL4y.js +0 -184
- package/dist/clickDraft-CdUtkL4y.js.map +0 -1
- package/dist/dashboard/migrate.d.ts +0 -33
- package/dist/dashboard/migrate.d.ts.map +0 -1
- package/dist/react/useViewEngine.d.ts.map +0 -1
- package/dist/react-BuHt29n6.js +0 -3855
- package/dist/react-BuHt29n6.js.map +0 -1
- package/dist/runtime/storedViews.d.ts +0 -10
- package/dist/runtime/storedViews.d.ts.map +0 -1
- package/dist/ui/dashboard/DashboardPanel.d.ts.map +0 -1
- package/dist/viewRuntimeTypes-B3B6hbXr.js.map +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cartesianBrush-HLU12ig5.js","names":["EChartsCoreOption","FADED_OPACITY","Lit","series","datum","faded","option","lit","Array","isArray","marks","flatMap","entry","Record","position","index","markIndex","data","count","length","any","some","from","_","at","map","fade","ONE_SERIES","Set","type","has","id","exec","Number","style","itemStyle","opacity","value","useSyncExternalStore","CartesianPlan","FADED_OPACITY","ChartTheme","brushes","plan","horizontal","context","pickable","data","points","length","BRUSH_ID","brushOption","theme","undefined","id","xAxisIndex","brushLink","brushType","brushMode","transformable","removeOnClick","toolbox","brushStyle","color","muted","borderColor","borderWidth","opacity","inBrush","outOfBrush","colorAlpha","withoutBrushToolbox","option","Record","toolboxRegistered","brush","list","Array","isArray","some","entry","BRUSH_CURSOR","type","key","const","BRUSH_CLEAR","areas","BrushedSpan","from","to","brushedSpan","said","count","area","range","coordRange","a","b","Number","isFinite","low","Math","max","round","min","high","useCoarsePointer","subscribe","coarse","_temp","COARSE","media","MediaQueryList","window","matchMedia","matches","change","addEventListener","removeEventListener","FADED_OPACITY","faded","series","option","lit","index","markIndex","entry","position","count","at","datum","fade","ONE_SERIES","id","style","brushes","plan","BRUSH_ID","brushOption","theme","withoutBrushToolbox","toolboxRegistered","BRUSH_CURSOR","BRUSH_CLEAR","brushedSpan","areas","said","range","a","b","low","high","useCoarsePointer","useSyncExternalStore","subscribe","coarse","_temp","COARSE","media","list","change"],"sources":["../src/ui/charts/highlight.ts","../src/ui/charts/cartesianBrush.ts"],"sourcesContent":["/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { EChartsCoreOption } from 'echarts/core';\n\n/**\n * How faint a mark that is not the group pressed is drawn: a dashboard panel\n * that set the board's filter keeps every group and marks the one pressed\n * (D22 I). Faded rather than hidden — the others are still the panel's\n * answer — and by opacity alone, so the palette and the marks' own colours\n * stay the theme's.\n */\nexport const FADED_OPACITY = 0.5;\n\n/**\n * Which of a series' data are the group pressed: `lit(series, datum)` is\n * asked for each drawn datum, `series` the index the family's option names\n * its marks by (`s{index}`, or the one series of a pie, a scatter or a\n * heatmap).\n */\nexport type Lit = (series: number, datum: number) => boolean;\n\n/**\n * The option with every datum that is not lit faded. Only the family's own\n * marks are touched — a series whose id is `s{n}` (the cartesian marks), or\n * the one series of a pie, a scatter or a heatmap — never a stack's totals or a reference line, which\n * stand for no group. Without `lit`, or with no datum it lights, the option\n * is handed back as it is, so a chart nothing was pressed on draws exactly\n * what it drew before.\n */\nexport function faded(\n option: EChartsCoreOption,\n lit: Lit | undefined,\n): EChartsCoreOption {\n const series = option.series;\n if (!lit || !Array.isArray(series)) return option;\n const marks = series.flatMap((entry: Record<string, unknown>, position) => {\n const index = markIndex(entry, position);\n return index === null || !Array.isArray(entry.data)\n ? []\n : [{ index, count: entry.data.length }];\n });\n // Nothing pressed on this chart — the value came from elsewhere, or its\n // group is not among the ones drawn — marks nothing, and fades nothing.\n const any = marks.some(({ index, count }) =>\n Array.from({ length: count }, (_, at) => at).some(at => lit(index, at)),\n );\n if (!any) return option;\n return {\n ...option,\n series: series.map((entry: Record<string, unknown>, position) => {\n const index = markIndex(entry, position);\n if (index === null || !Array.isArray(entry.data)) return entry;\n return {\n ...entry,\n data: entry.data.map((datum: unknown, at: number) =>\n lit(index, at) ? datum : fade(datum),\n ),\n };\n }),\n };\n}\n\n/** The families drawn as one series whose every datum is a group. */\nconst ONE_SERIES = new Set(['pie', 'scatter', 'heatmap']);\n\n/** The index a series stands for among the marks, or `null` for none. */\nfunction markIndex(entry: Record<string, unknown>, position: number) {\n if (typeof entry.type === 'string' && ONE_SERIES.has(entry.type))\n return position;\n const id = typeof entry.id === 'string' ? /^s(\\d+)$/.exec(entry.id) : null;\n return id ? Number(id[1]) : null;\n}\n\nfunction fade(datum: unknown): unknown {\n if (typeof datum === 'object' && datum !== null && 'value' in datum) {\n const style = (datum as { itemStyle?: object }).itemStyle ?? {};\n return {\n ...datum,\n itemStyle: { ...style, opacity: FADED_OPACITY },\n };\n }\n return { value: datum, itemStyle: { opacity: FADED_OPACITY } };\n}\n","/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { useSyncExternalStore } from 'react';\nimport type { CartesianPlan } from './cartesianPlan.js';\nimport { FADED_OPACITY } from './highlight.js';\nimport type { ChartTheme } from './theme.js';\n\n/**\n * Brushing a stretch of a time axis (D33 batch C, Q52): a drag along the\n * plot selects the buckets under it, and the follow-up menu a press on one\n * group opens is asked about all of them at once — 「这几天怎么了」. The\n * brush only chooses; what the stretch means as a condition is the\n * kernel's (`drillSpan`), and nothing here edits the view.\n *\n * Only along the axis (`lineX`), only one stretch at a time, and never\n * saved: the cover goes when the menu over it closes.\n */\n\n/** Whether a chart of this plan is brushed: upright, over time, pressable. */\nexport function brushes(plan: CartesianPlan): boolean {\n return (\n !plan.horizontal &&\n plan.context.brushes === true &&\n plan.context.pickable &&\n plan.data.points.length > 1\n );\n}\n\n/**\n * The id the brush component of this package's charts wears, by which the\n * toolbox the library injects for it is recognised (`withoutBrushToolbox`).\n */\nexport const BRUSH_ID = 'fve-brush';\n\n/**\n * The brush component a brushed chart carries, or nothing.\n *\n * Its cover is a quiet band in the muted ink, and the marks outside it fade as a pressed\n * group's neighbours do on a board (`FADED_OPACITY`), so what the stretch\n * holds reads while the drag is under way. No toolbox: the drag is always\n * on (`BRUSH_CURSOR`), and a press still presses — a drag shorter than the\n * library's threshold draws no cover, and a click is only a click when the\n * pointer barely moved.\n */\nexport function brushOption(\n plan: CartesianPlan,\n theme: ChartTheme,\n): object | undefined {\n if (!brushes(plan)) return undefined;\n return {\n id: BRUSH_ID,\n xAxisIndex: 0,\n brushLink: 'none',\n brushType: 'lineX',\n brushMode: 'single',\n transformable: false,\n removeOnClick: true,\n toolbox: [],\n brushStyle: {\n color: theme.muted,\n borderColor: theme.muted,\n borderWidth: 1,\n opacity: 0.18,\n },\n inBrush: {},\n outOfBrush: { colorAlpha: FADED_OPACITY },\n };\n}\n\n/**\n * The option without the toolbox the library's brush preprocessor put into\n * it for this package's brush — an option preprocessor, registered after the\n * brush (`echarts.ts`), so it runs before the library checks what the option\n * uses. The preprocessor adds a `toolbox` for the buttons it would draw; the\n * toolbox is not registered (analysis-echarts.md 2.4: +15.1KB for buttons\n * this package draws itself), so nothing was drawn, but a development build\n * logged 「Component toolbox is used but not imported」 in every host's\n * console. Only an option carrying this package's brush (`BRUSH_ID`) is\n * touched, and only while no toolbox is registered: a host drawing its own\n * charts with the same library, toolbox and all, keeps its toolbox.\n */\nexport function withoutBrushToolbox(\n option: Record<string, unknown> | undefined,\n toolboxRegistered: boolean,\n): void {\n if (!option || toolboxRegistered || !('toolbox' in option)) return;\n const brushes = option.brush;\n const list: unknown[] = Array.isArray(brushes) ? brushes : [brushes];\n if (list.some(entry => (entry as { id?: unknown } | null)?.id === BRUSH_ID))\n delete option.toolbox;\n}\n\n/**\n * What turns the brush on without a toolbox button: taken when a mouse or a\n * pen goes down on the plot, before the library sees the press, and again\n * after a whole new option has reset the component (`EChart`).\n */\nexport const BRUSH_CURSOR = {\n type: 'takeGlobalCursor',\n key: 'brush',\n brushOption: { brushType: 'lineX', brushMode: 'single' },\n} as const;\n\n/** What clears the cover once the menu over it has gone. */\nexport const BRUSH_CLEAR = { type: 'brush', areas: [] } as const;\n\n/** The first and the last category a brush covers, by index. */\ninterface BrushedSpan {\n from: number;\n to: number;\n}\n\n/**\n * The categories a finished brush covers, read off the library's `brushEnd`\n * event — its one area's range along the category axis, which it gives in\n * category indexes — clamped to the `count` there are; `null` for a brush\n * that covers none (one taken away by a click, or dragged off the plot).\n */\nexport function brushedSpan(said: unknown, count: number): BrushedSpan | null {\n const areas = (said as { areas?: unknown } | null)?.areas;\n const area: unknown = Array.isArray(areas) ? areas[0] : undefined;\n const range = (area as { coordRange?: unknown } | undefined)?.coordRange;\n if (!Array.isArray(range) || range.length !== 2 || count === 0) return null;\n const [a, b] = range as unknown[];\n if (typeof a !== 'number' || typeof b !== 'number') return null;\n if (!Number.isFinite(a) || !Number.isFinite(b)) return null;\n // The library gives whole indexes on a category axis; were one to come\n // between two, it belongs to the nearer category.\n const low = Math.max(0, Math.round(Math.min(a, b)));\n const high = Math.min(count - 1, Math.round(Math.max(a, b)));\n return low <= high ? { from: low, to: high } : null;\n}\n\n/**\n * Whether the reader's main pointer is a finger (`pointer: coarse`): a\n * phone or a tablet, where a chart is brushed not at all. The library takes\n * a touch on the plot as the start of a drag and holds the page still under\n * it, so a finger that landed on a chart to scroll past it would brush it\n * instead; there the first tap reads a mark and the second opens its menu\n * (`EChart`), and the table layout picks a span with Shift where a keyboard\n * is. Read live; where the platform cannot say, a desktop is assumed.\n */\nexport function useCoarsePointer(): boolean {\n return useSyncExternalStore(subscribe, coarse, () => false);\n}\n\nconst COARSE = '(pointer: coarse)';\n\nfunction media(): MediaQueryList | null {\n return typeof window !== 'undefined' &&\n typeof window.matchMedia === 'function'\n ? window.matchMedia(COARSE)\n : null;\n}\n\nfunction coarse(): boolean {\n return media()?.matches ?? false;\n}\n\nfunction subscribe(change: () => void): () => void {\n const list = media();\n list?.addEventListener('change', change);\n return () => list?.removeEventListener('change', change);\n}\n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B,MAAMC,QAAQQ,CAAK,IAAIA,EAAM,KAAKjC,KAAAA,EAAAA,EACM0C;CAC9D,IAAI,CAAClB,MAAMC,QAAQgB,CAAK,KAAKA,EAAM7C,WAAW,KAAK2C,MAAU,GAAG,OAAO;CACvE,IAAM,CAACI,GAAGC,KAAKH;CAEf,IADI,OAAOE,KAAM,YAAY,OAAOC,KAAM,YACtC,CAACC,OAAOC,SAASH,CAAC,KAAK,CAACE,OAAOC,SAASF,CAAC,GAAG,OAAO;CAGvD,IAAMG,IAAMC,KAAKC,IAAI,GAAGD,KAAKE,MAAMF,KAAKG,IAAIR,GAAGC,CAAC,CAAC,CAAC,GAC5CQ,IAAOJ,KAAKG,IAAIZ,IAAQ,GAAGS,KAAKE,MAAMF,KAAKC,IAAIN,GAAGC,CAAC,CAAC,CAAC;CAC3D,OAAOG,KAAOK,IAAO;EAAEjB,MAAMY;EAAKX,IAAIgB;CAAK,IAAI;AACjD;AAWA,SAAOC,IAAA;CAAA,OACEpE,EAAqBqE,GAAWC,GAAQC,CAAW;AAAC;AADtD,SAAAA,IAAA;CAAA,OACgD;AAAK;AAG5D,IAAMC,IAAS;AAEf,SAASC,IAA+B;CACtC,OAAO,OAAOE,SAAW,OACvB,OAAOA,OAAOC,cAAe,aAC3BD,OAAOC,WAAWJ,CAAM,IACxB;AACN;AAEA,SAASF,IAAkB;CACzB,OAAOG,EAAM,CAAC,EAAEI,WAAW;AAC7B;AAEA,SAASR,EAAUS,GAAgC;CACjD,IAAMxC,IAAOmC,EAAM;CAEnB,OADAnC,GAAMyC,iBAAiB,UAAUD,CAAM,SAC1BxC,GAAM0C,oBAAoB,UAAUF,CAAM;AACzD"}
|
|
@@ -1,184 +0,0 @@
|
|
|
1
|
-
import { Dt as e, Gt as t, Tt as n, cn as r, hi as i, jt as a, qi as o, wt as s } from "./actions-CgaL6eEe.js";
|
|
2
|
-
//#region src/filter/fieldGroups.ts
|
|
3
|
-
function c(e, t, n) {
|
|
4
|
-
let r = /* @__PURE__ */ new Map();
|
|
5
|
-
for (let e of t) for (let t of e.fields) r.has(t) || r.set(t, e);
|
|
6
|
-
let i = /* @__PURE__ */ new Map(), a = [];
|
|
7
|
-
for (let t of e) {
|
|
8
|
-
let e = n(t);
|
|
9
|
-
r.has(e) ? i.set(e, t) : a.push(t);
|
|
10
|
-
}
|
|
11
|
-
let o = [];
|
|
12
|
-
a.length > 0 && o.push({
|
|
13
|
-
group: void 0,
|
|
14
|
-
items: a
|
|
15
|
-
});
|
|
16
|
-
for (let e of t) {
|
|
17
|
-
let t = [];
|
|
18
|
-
for (let n of e.fields) {
|
|
19
|
-
let a = i.get(n);
|
|
20
|
-
a !== void 0 && r.get(n) === e && (t.push(a), i.delete(n));
|
|
21
|
-
}
|
|
22
|
-
t.length > 0 && o.push({
|
|
23
|
-
group: e,
|
|
24
|
-
items: t
|
|
25
|
-
});
|
|
26
|
-
}
|
|
27
|
-
return o;
|
|
28
|
-
}
|
|
29
|
-
//#endregion
|
|
30
|
-
//#region src/record/export.ts
|
|
31
|
-
var l = "", u = "\r\n", d = /["\r\n,]/, f = /^[=+\-@\t\r]/, p = /^[+-]?(?:\d+\.?\d*|\.\d+)(?:[eE][+-]?\d+)?$/;
|
|
32
|
-
function m(e, t, n, r = {}) {
|
|
33
|
-
return h(t.map((e) => e.label), e.map((e) => t.map((t) => {
|
|
34
|
-
let r = i(e, t.field);
|
|
35
|
-
return {
|
|
36
|
-
value: r,
|
|
37
|
-
text: n(r, t)
|
|
38
|
-
};
|
|
39
|
-
})), r);
|
|
40
|
-
}
|
|
41
|
-
function h(e, t, n = {}) {
|
|
42
|
-
let r = n.neutralizeFormulas !== !1, i = (e) => g(e, r), a = [e.map((e) => i({
|
|
43
|
-
value: e,
|
|
44
|
-
text: e
|
|
45
|
-
}))];
|
|
46
|
-
for (let e of t) a.push(e.map(i));
|
|
47
|
-
return `${a.map((e) => e.join(",")).join(u)}${u}`;
|
|
48
|
-
}
|
|
49
|
-
function g({ value: e, text: t }, n) {
|
|
50
|
-
let r = typeof t == "string" ? t : String(t ?? "");
|
|
51
|
-
return n && _(e, r) && (r = `'${r}`), d.test(r) ? `"${r.split("\"").join("\"\"")}"` : r;
|
|
52
|
-
}
|
|
53
|
-
function _(e, t) {
|
|
54
|
-
return typeof e == "number" || typeof e == "bigint" ? !1 : f.test(t) && !p.test(t);
|
|
55
|
-
}
|
|
56
|
-
//#endregion
|
|
57
|
-
//#region src/analysis/bucketChange.ts
|
|
58
|
-
function v(e, t, n) {
|
|
59
|
-
if (e.timeline !== !0 || n < 1) return;
|
|
60
|
-
let r = e.points[n], i = e.points[n - 1];
|
|
61
|
-
if (!r || !i || !o(r.x) || !o(i.x)) return;
|
|
62
|
-
let a = r.values[t], s = i.values[t];
|
|
63
|
-
if (typeof a != "number" || typeof s != "number") return;
|
|
64
|
-
let c = a - s;
|
|
65
|
-
return {
|
|
66
|
-
delta: c,
|
|
67
|
-
ratio: s === 0 ? null : c / Math.abs(s)
|
|
68
|
-
};
|
|
69
|
-
}
|
|
70
|
-
//#endregion
|
|
71
|
-
//#region src/dashboard/clickDraft.ts
|
|
72
|
-
var y = [
|
|
73
|
-
"view",
|
|
74
|
-
"dashboard",
|
|
75
|
-
"url"
|
|
76
|
-
];
|
|
77
|
-
function b(e, t) {
|
|
78
|
-
let n = {
|
|
79
|
-
choice: "go",
|
|
80
|
-
filter: t[0] ?? "",
|
|
81
|
-
goKind: "view",
|
|
82
|
-
view: "",
|
|
83
|
-
url: "",
|
|
84
|
-
board: "",
|
|
85
|
-
values: {},
|
|
86
|
-
tab: ""
|
|
87
|
-
};
|
|
88
|
-
if (e === null) return {
|
|
89
|
-
...n,
|
|
90
|
-
choice: "menu"
|
|
91
|
-
};
|
|
92
|
-
switch (e.kind) {
|
|
93
|
-
case "filter": return t.includes(e.filter) ? {
|
|
94
|
-
...n,
|
|
95
|
-
choice: "filter",
|
|
96
|
-
filter: e.filter
|
|
97
|
-
} : {
|
|
98
|
-
...n,
|
|
99
|
-
choice: "filter"
|
|
100
|
-
};
|
|
101
|
-
case "view": return {
|
|
102
|
-
...n,
|
|
103
|
-
view: e.instanceId
|
|
104
|
-
};
|
|
105
|
-
case "url": return {
|
|
106
|
-
...n,
|
|
107
|
-
goKind: "url",
|
|
108
|
-
url: e.url
|
|
109
|
-
};
|
|
110
|
-
case "dashboard": return {
|
|
111
|
-
...n,
|
|
112
|
-
goKind: "dashboard",
|
|
113
|
-
board: e.instanceId,
|
|
114
|
-
values: e.values,
|
|
115
|
-
tab: e.tab ?? ""
|
|
116
|
-
};
|
|
117
|
-
}
|
|
118
|
-
}
|
|
119
|
-
function x(e, t) {
|
|
120
|
-
return t === e.board ? e : {
|
|
121
|
-
...e,
|
|
122
|
-
board: t,
|
|
123
|
-
values: {},
|
|
124
|
-
tab: ""
|
|
125
|
-
};
|
|
126
|
-
}
|
|
127
|
-
function S(t) {
|
|
128
|
-
return e(t, Object.fromEntries(a(t).map((e) => [e, "x"]))) !== null;
|
|
129
|
-
}
|
|
130
|
-
function C(e, { groups: t, fields: r, own: i }) {
|
|
131
|
-
return [...n(e, t, r).map((e) => ({ dimension: e.field })), ...s(e, i).map((e) => ({ filter: e.name }))];
|
|
132
|
-
}
|
|
133
|
-
function w(e) {
|
|
134
|
-
return "dimension" in e ? `dimension:${e.dimension}` : `filter:${e.filter}`;
|
|
135
|
-
}
|
|
136
|
-
function T(e, n, r) {
|
|
137
|
-
let i = new Map(t(e).map((e) => [e.name, e])), a = {}, o = [];
|
|
138
|
-
for (let [e, t] of Object.entries(n)) {
|
|
139
|
-
let n = i.get(e);
|
|
140
|
-
n && C(n, r).some((e) => w(e) === w(t)) ? a[e] = t : o.push(n?.label ?? e);
|
|
141
|
-
}
|
|
142
|
-
return {
|
|
143
|
-
kept: a,
|
|
144
|
-
stale: o
|
|
145
|
-
};
|
|
146
|
-
}
|
|
147
|
-
function E(e, t, n) {
|
|
148
|
-
if (e.choice === "menu") return null;
|
|
149
|
-
if (e.choice === "filter") return e.filter ? {
|
|
150
|
-
kind: "filter",
|
|
151
|
-
filter: e.filter
|
|
152
|
-
} : void 0;
|
|
153
|
-
switch (e.goKind) {
|
|
154
|
-
case "view": return e.view ? {
|
|
155
|
-
kind: "view",
|
|
156
|
-
instanceId: e.view
|
|
157
|
-
} : void 0;
|
|
158
|
-
case "dashboard": return t ? {
|
|
159
|
-
kind: "dashboard",
|
|
160
|
-
instanceId: e.board,
|
|
161
|
-
values: T(t, e.values, n).kept,
|
|
162
|
-
...O(t, e.tab) ? { tab: e.tab } : {}
|
|
163
|
-
} : void 0;
|
|
164
|
-
case "url": return S(e.url) ? {
|
|
165
|
-
kind: "url",
|
|
166
|
-
url: e.url.trim()
|
|
167
|
-
} : void 0;
|
|
168
|
-
}
|
|
169
|
-
}
|
|
170
|
-
function D(e) {
|
|
171
|
-
let t = e.choice === "go";
|
|
172
|
-
return {
|
|
173
|
-
view: t && e.goKind === "view" && !e.view,
|
|
174
|
-
url: t && e.goKind === "url" && !S(e.url),
|
|
175
|
-
board: t && e.goKind === "dashboard" && !e.board
|
|
176
|
-
};
|
|
177
|
-
}
|
|
178
|
-
function O(e, t) {
|
|
179
|
-
return !!t && r(e).some((e) => e.id === t);
|
|
180
|
-
}
|
|
181
|
-
//#endregion
|
|
182
|
-
export { E as a, w as c, l as d, m as f, b as i, x as l, c as m, C as n, T as o, h as p, D as r, S as s, y as t, v as u };
|
|
183
|
-
|
|
184
|
-
//# sourceMappingURL=clickDraft-CdUtkL4y.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"clickDraft-CdUtkL4y.js","names":["FieldGroupDefinition","FieldGroup","group","items","T","fieldGroups","groups","key","item","groupOf","Map","field","fields","has","set","grouped","ungrouped","name","push","listed","length","undefined","own","get","delete","RecordData","recordValue","ExportColumn","field","label","ExportFormat","value","column","C","CSV_BOM","CRLF","MUST_QUOTE","FORMULA_START","PLAIN_NUMBER","CsvOptions","neutralizeFormulas","CsvCell","text","serializeCsv","rows","columns","format","options","writeCsv","map","row","header","neutralize","cell","csvField","lines","push","line","join","written","String","evaluable","test","split","readInstant","CartesianData","BucketChange","delta","ratio","bucketChange","data","key","index","timeline","undefined","at","points","before","x","value","values","was","Math","abs","BoardValueSource","DashboardField","DashboardViewConfig","FieldDefinition","PanelClick","boardFilterChoices","boardValueChoices","fillUrl","urlPlaceholders","PressableGroup","filtersOf","tabsOf","ClickChoice","ClickGoKind","CLICK_GO_KINDS","ClickDraft","choice","filter","goKind","view","url","board","values","Record","tab","clickDraftOf","stored","filters","blank","kind","includes","instanceId","withBoard","draft","urlFillable","template","Object","fromEntries","map","key","MappingSources","groups","fields","own","boardValueSources","group","dimension","field","name","valueSourceKey","source","mappedValues","Readonly","sources","kept","stale","byName","Map","entries","get","usable","some","push","label","draftedClick","undefined","boardTab","trim","clickDraftGaps","going","Pick","entry","id","fillUrl","filtersOf","boardValueChoices","tabsOf","recordValue","urlPlaceholders","readInstant","boardFilterChoices","fieldGroups","groupOf","group","groups","field","grouped","ungrouped","item","items","name","key","listed","own","CSV_BOM","CRLF","MUST_QUOTE","FORMULA_START","PLAIN_NUMBER","serializeCsv","writeCsv","columns","column","rows","value","row","format","options","neutralize","csvField","cell","lines","header","label","line","written","text","evaluable","bucketChange","data","index","at","before","was","delta","CLICK_GO_KINDS","clickDraftOf","blank","filters","stored","withBoard","board","draft","urlFillable","template","boardValueSources","filter","fields","valueSourceKey","source","mappedValues","byName","kept","stale","values","sources","choice","draftedClick","boardTab","clickDraftGaps","going","tab","entry"],"sources":["../src/filter/fieldGroups.ts","../src/record/export.ts","../src/analysis/bucketChange.ts","../src/dashboard/clickDraft.ts"],"sourcesContent":["/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { FieldGroupDefinition } from '../model/index.js';\n\n/** One group of a picker: its label, or none for the fields outside any. */\nexport interface FieldGroup<T> {\n group: FieldGroupDefinition | undefined;\n items: T[];\n}\n\n/**\n * Fields as a picker lists them: the ones no group lists first, in the\n * field list's order, then each declared group in the definition's order,\n * each in its own `fields` order. A picker often lists a subset — the fields\n * not yet a condition, the ones a column can show — so a group none of the\n * items belong to is not shown. A field two groups list, or one group lists\n * twice, is kept where it was listed first; admission reports that as a\n * definition error, so it is never the picker's to guess.\n */\nexport function fieldGroups<T>(\n items: readonly T[],\n groups: readonly FieldGroupDefinition[],\n key: (item: T) => string,\n): FieldGroup<T>[] {\n const groupOf = new Map<string, FieldGroupDefinition>();\n for (const group of groups)\n for (const field of group.fields)\n if (!groupOf.has(field)) groupOf.set(field, group);\n\n const grouped = new Map<string, T>();\n const ungrouped: T[] = [];\n for (const item of items) {\n const name = key(item);\n if (groupOf.has(name)) grouped.set(name, item);\n else ungrouped.push(item);\n }\n\n const listed: FieldGroup<T>[] = [];\n if (ungrouped.length > 0) listed.push({ group: undefined, items: ungrouped });\n for (const group of groups) {\n const own: T[] = [];\n for (const field of group.fields) {\n const item = grouped.get(field);\n if (item !== undefined && groupOf.get(field) === group) {\n own.push(item);\n grouped.delete(field);\n }\n }\n if (own.length > 0) listed.push({ group, items: own });\n }\n return listed;\n}\n","/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { RecordData } from '../model/index.js';\nimport { recordValue } from './project.js';\n\n/** The least an export needs of a column: where to read it, what to call it. */\nexport interface ExportColumn {\n /** A Wow query path, read the way a cell reads it. */\n field: string;\n /** What the header row calls this column. */\n label: string;\n}\n\n/**\n * How one value is written.\n *\n * It is injected rather than decided here, because how a value *reads* is the\n * UI's answer — an enum by its label, a time in the surface's zone, a number\n * in its field's format — and this layer has no catalogue, no locale and no\n * renderers. The column rides along with the value, so one formatter serves\n * every column of the table.\n */\nexport type ExportFormat<C extends ExportColumn = ExportColumn> = (\n value: unknown,\n column: C,\n) => string;\n\n/**\n * The byte order mark Excel needs to read a UTF-8 CSV as UTF-8.\n *\n * Without it Excel on Windows reads the file in the machine's ANSI code page\n * and every Chinese name in it arrives as mojibake — which is most of what\n * these exports carry.\n */\nexport const CSV_BOM = '';\n\n/** RFC 4180 ends every record with CRLF, the last one included. */\nconst CRLF = '\\r\\n';\n\n/** The characters that oblige a field to be quoted, the quote included. */\nconst MUST_QUOTE = /[\"\\r\\n,]/;\n\n/**\n * What a spreadsheet may read a cell as a formula by: its first character\n * (OWASP, CSV Injection). `=`, `+`, `-` and `@` start a formula or a\n * function; a tab or a carriage return in front hides one from a reader who\n * trims.\n */\nconst FORMULA_START = /^[=+\\-@\\t\\r]/;\n\n/**\n * A text that is a number and nothing else: a sign, digits, one decimal\n * point, an exponent. No separators, no currency, no spaces — nothing a\n * spreadsheet could read as more than one number.\n */\nconst PLAIN_NUMBER = /^[+-]?(?:\\d+\\.?\\d*|\\.\\d+)(?:[eE][+-]?\\d+)?$/;\n\n/** How a CSV is written. */\nexport interface CsvOptions {\n /**\n * Whether a cell a spreadsheet could evaluate is written with an\n * apostrophe in front, so it opens as the text it is. On unless set to\n * `false`.\n *\n * A file leaves the page: it is opened in Excel, often by someone other\n * than whoever exported it, and a value somebody typed into a text field\n * — `=HYPERLINK(…)`, `=cmd|' /C calc'!A0` — would run there as a formula\n * (OWASP, CSV Injection). So every cell whose text starts with `=`, `+`,\n * `-`, `@`, a tab or a carriage return gets a leading `'`, the header's\n * labels included, since a definition names them.\n *\n * Two kinds of cell are left alone, because a spreadsheet reads them as a\n * number and never as a formula: one whose value was a number (a negative\n * amount, however its field formats it — `-1,204.50`, `-$12.00`), and one\n * whose text is a plain number (`-12.5` held by a text field). Prefixing\n * either would only make the file differ from the screen.\n *\n * Turn it off only where the file never reaches a spreadsheet — a\n * pipeline that reads the CSV back as data and wants the text as stored.\n */\n neutralizeFormulas?: boolean;\n}\n\n/** One cell of a file: the value it was read from, and the text it reads as. */\nexport interface CsvCell {\n /** What the row held; only its type is looked at: a number is never a formula. */\n value: unknown;\n /** The text written, before any escaping. */\n text: string;\n}\n\n/**\n * The rows as a CSV, RFC 4180 with a BOM in front.\n *\n * The header is the labels of the columns handed over, in the order they are\n * handed over — which is the projected order of the visible columns, so the\n * file carries the table's columns rather than the definition's fields.\n *\n * Nothing here looks at what a value *means*: `format` has already decided\n * that, and what is left is writing it (`writeCsv`) — the escaping, and the\n * formulas neutralized unless `options` says otherwise (`CsvOptions`).\n */\nexport function serializeCsv<C extends ExportColumn>(\n rows: readonly RecordData[],\n columns: readonly C[],\n format: ExportFormat<C>,\n options: CsvOptions = {},\n): string {\n return writeCsv(\n columns.map(column => column.label),\n rows.map(row =>\n columns.map(column => {\n const value = recordValue(row, column.field);\n return { value, text: format(value, column) };\n }),\n ),\n options,\n );\n}\n\n/**\n * Cells already read, as a CSV: the one writer every export goes through —\n * a record view's rows (`serializeCsv`) and an analysis's groups alike — so\n * the escaping and the formula rule (`CsvOptions.neutralizeFormulas`) are\n * one rule rather than one per export.\n */\nexport function writeCsv(\n header: readonly string[],\n rows: readonly (readonly CsvCell[])[],\n options: CsvOptions = {},\n): string {\n const neutralize = options.neutralizeFormulas !== false;\n const field = (cell: CsvCell) => csvField(cell, neutralize);\n const lines = [header.map(label => field({ value: label, text: label }))];\n for (const row of rows) lines.push(row.map(field));\n return `${CSV_BOM}${lines.map(line => line.join(',')).join(CRLF)}${CRLF}`;\n}\n\n/**\n * One field: neutralized where a spreadsheet could evaluate it, then quoted\n * where it has to be.\n *\n * The text is typed as a string, but it comes from a function a host may\n * have written, so it is coerced rather than trusted: `null` written into\n * the file as the word `null` is a value the table never showed.\n */\nfunction csvField({ value, text }: CsvCell, neutralize: boolean): string {\n let written = typeof text === 'string' ? text : String(text ?? '');\n if (neutralize && evaluable(value, written)) written = `'${written}`;\n return MUST_QUOTE.test(written)\n ? `\"${written.split('\"').join('\"\"')}\"`\n : written;\n}\n\n/** Whether a spreadsheet opening this cell could evaluate it (`CsvOptions`). */\nfunction evaluable(value: unknown, text: string): boolean {\n if (typeof value === 'number' || typeof value === 'bigint') return false;\n return FORMULA_START.test(text) && !PLAIN_NUMBER.test(text);\n}\n","/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { readInstant } from '../filter/index.js';\nimport type { CartesianData } from './chart.js';\n\n/**\n * How one bucket's number moved from the bucket right before it: the\n * difference, and that difference as a share of the earlier number — `null`\n * where the earlier number is 0, which no share can be taken of.\n */\nexport interface BucketChange {\n delta: number;\n ratio: number | null;\n}\n\n/**\n * The change of series `key` at point `index` from the point before it, on\n * a time axis whose points are consecutive buckets (`CartesianData.timeline`)\n * — the tooltip's 「较上一期」 (docs/design/decisions.md D33, Q59).\n *\n * It asks for nothing the rows do not hold: both numbers are the chart's own,\n * so there is no second query. And it says nothing it cannot know: not on a\n * category axis, where the point before is no earlier period; not on a time\n * axis with a bucket skipped; not for the first bucket, nor for the missing\n * value's bucket or the one after it; and not where either number is missing\n * — a hole the kernel could not tell was empty, or `missing: 'gap'`. A 0 the\n * kernel filled in is a known 0 (`absenceReader`), and is compared like any.\n */\nexport function bucketChange(\n data: CartesianData,\n key: string,\n index: number,\n): BucketChange | undefined {\n if (data.timeline !== true || index < 1) return undefined;\n const at = data.points[index];\n const before = data.points[index - 1];\n if (!at || !before || !readInstant(at.x) || !readInstant(before.x))\n return undefined;\n const value = at.values[key];\n const was = before.values[key];\n if (typeof value !== 'number' || typeof was !== 'number') return undefined;\n const delta = value - was;\n return { delta, ratio: was === 0 ? null : delta / Math.abs(was) };\n}\n","/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * 「点击时…」 as the author fills it in (D22 I, D23 Q17): every choice the\n * form holds at once — the ones not picked kept, so switching back finds\n * what was typed — and the click they make, or why they make none yet.\n * Pure: the form holds a `ClickDraft` and asks here what it says.\n */\n\nimport type {\n BoardValueSource,\n DashboardField,\n DashboardViewConfig,\n FieldDefinition,\n PanelClick,\n} from '../model/index.js';\nimport {\n boardFilterChoices,\n boardValueChoices,\n fillUrl,\n urlPlaceholders,\n type PressableGroup,\n} from './click.js';\nimport { filtersOf } from './filters.js';\nimport { tabsOf } from './panels.js';\n\n/** The three things a press can do: the follow-up menu, a filter, a destination. */\nexport type ClickChoice = 'menu' | 'filter' | 'go';\n\n/** Where a destination goes: a saved view, another board, a page. */\nexport type ClickGoKind = 'view' | 'dashboard' | 'url';\n\nexport const CLICK_GO_KINDS: readonly ClickGoKind[] = [\n 'view',\n 'dashboard',\n 'url',\n];\n\n/** Everything 「点击时…」 holds, each choice's own part kept while another is picked. */\nexport interface ClickDraft {\n choice: ClickChoice;\n /** The board filter a press sets, by name. */\n filter: string;\n goKind: ClickGoKind;\n /** The saved view a press opens; `''` while none is picked. */\n view: string;\n /** The page a press opens, as typed. */\n url: string;\n /** The board a press opens; `''` while none is picked. */\n board: string;\n /** What each of that board's filters takes. */\n values: Record<string, BoardValueSource>;\n /** The tab it opens on (D39); `''` for where its reader last read it. */\n tab: string;\n}\n\n/**\n * The form as it opens on a panel's stored click. `filters` are the names\n * of the board filters a press on this panel can set: a stored filter no\n * longer among them starts at the first that is.\n */\nexport function clickDraftOf(\n stored: PanelClick | null,\n filters: readonly string[],\n): ClickDraft {\n const blank: ClickDraft = {\n choice: 'go',\n filter: filters[0] ?? '',\n goKind: 'view',\n view: '',\n url: '',\n board: '',\n values: {},\n tab: '',\n };\n if (stored === null) return { ...blank, choice: 'menu' };\n switch (stored.kind) {\n case 'filter':\n return filters.includes(stored.filter)\n ? { ...blank, choice: 'filter', filter: stored.filter }\n : { ...blank, choice: 'filter' };\n case 'view':\n return { ...blank, view: stored.instanceId };\n case 'url':\n return { ...blank, goKind: 'url', url: stored.url };\n case 'dashboard':\n return {\n ...blank,\n goKind: 'dashboard',\n board: stored.instanceId,\n values: stored.values,\n tab: stored.tab ?? '',\n };\n }\n}\n\n/**\n * Another board picked for the destination: nothing mapped for the board\n * it replaces carries over by name, since its filters are other filters.\n */\nexport function withBoard(draft: ClickDraft, board: string): ClickDraft {\n return board === draft.board\n ? draft\n : { ...draft, board, values: {}, tab: '' };\n}\n\n/**\n * Whether a URL template fills into a URL a board may open whatever its\n * placeholders hold (`fillUrl`).\n */\nexport function urlFillable(template: string): boolean {\n return (\n fillUrl(\n template,\n Object.fromEntries(urlPlaceholders(template).map(key => [key, 'x'])),\n ) !== null\n );\n}\n\n/** What a mapping can draw on: the panel's dimensions and this board's filters. */\nexport interface MappingSources {\n groups: readonly PressableGroup[];\n fields: readonly FieldDefinition[] | null;\n own: readonly DashboardField[];\n}\n\n/**\n * Every source one of another board's filters can take its value from,\n * this panel's dimensions first (`boardValueChoices`), then this board's\n * filters (`boardFilterChoices`).\n */\nexport function boardValueSources(\n filter: DashboardField,\n { groups, fields, own }: MappingSources,\n): BoardValueSource[] {\n return [\n ...boardValueChoices(filter, groups, fields).map(group => ({\n dimension: group.field,\n })),\n ...boardFilterChoices(filter, own).map(field => ({ filter: field.name })),\n ];\n}\n\n/** One source as a key: `dimension:<field>` or `filter:<name>`. */\nexport function valueSourceKey(source: BoardValueSource): string {\n return 'dimension' in source\n ? `dimension:${source.dimension}`\n : `filter:${source.filter}`;\n}\n\n/**\n * What a press takes to the board (D23 Q17), from what the author chose:\n * each of the board's filters mapped to a source that can still give it a\n * value — a dimension of this panel, or a filter of this board's, of a type\n * it takes. Whatever else was stored (a filter gone on either board, a\n * dimension gone) is left out, and named in `stale` by the filter's label.\n * Never guessed by name: a filter the author did not map is not carried.\n */\nexport function mappedValues(\n board: DashboardViewConfig,\n values: Readonly<Record<string, BoardValueSource>>,\n sources: MappingSources,\n): { kept: Record<string, BoardValueSource>; stale: string[] } {\n const byName = new Map(filtersOf(board).map(filter => [filter.name, filter]));\n const kept: Record<string, BoardValueSource> = {};\n const stale: string[] = [];\n for (const [name, source] of Object.entries(values)) {\n const filter = byName.get(name);\n const usable =\n filter &&\n boardValueSources(filter, sources).some(\n choice => valueSourceKey(choice) === valueSourceKey(source),\n );\n if (usable) kept[name] = source;\n else stale.push(filter?.label ?? name);\n }\n return { kept, stale };\n}\n\n/**\n * The click a draft makes: `null` for the follow-up menu, `undefined`\n * while the choice picked still lacks what it needs — no filter, no view,\n * no board read yet (`board` is the destination board's config once read),\n * or a URL no board may open. A board's mapping is kept only where it still\n * holds (`mappedValues`).\n */\nexport function draftedClick(\n draft: ClickDraft,\n board: DashboardViewConfig | undefined,\n sources: MappingSources,\n): PanelClick | null | undefined {\n if (draft.choice === 'menu') return null;\n if (draft.choice === 'filter')\n return draft.filter ? { kind: 'filter', filter: draft.filter } : undefined;\n switch (draft.goKind) {\n case 'view':\n return draft.view ? { kind: 'view', instanceId: draft.view } : undefined;\n case 'dashboard':\n return board\n ? {\n kind: 'dashboard',\n instanceId: draft.board,\n values: mappedValues(board, draft.values, sources).kept,\n // Only a tab the board still has (D39): one gone since the\n // click was set is dropped here, as a stale mapping is.\n ...(boardTab(board, draft.tab) ? { tab: draft.tab } : {}),\n }\n : undefined;\n case 'url':\n return urlFillable(draft.url)\n ? { kind: 'url', url: draft.url.trim() }\n : undefined;\n }\n}\n\n/**\n * What a destination still lacks, said at its field once 完成 was pressed\n * without it: no view picked, a URL no board may open, no board picked.\n */\nexport function clickDraftGaps(draft: ClickDraft): {\n view: boolean;\n url: boolean;\n board: boolean;\n} {\n const going = draft.choice === 'go';\n return {\n view: going && draft.goKind === 'view' && !draft.view,\n url: going && draft.goKind === 'url' && !urlFillable(draft.url),\n board: going && draft.goKind === 'dashboard' && !draft.board,\n };\n}\n\n/**\n * Whether `tab` names one of the board's tabs — the one a press opens it on\n * (D39); `''` names none.\n */\nfunction boardTab(\n board: Pick<DashboardViewConfig, 'tabs'>,\n tab: string | undefined,\n): boolean {\n return !!tab && tabsOf(board).some(entry => entry.id === tab);\n}\n"],"mappings":";;AA8BA,SAAgBK,EACdF,GACAG,GACAC,GACiB;CACjB,IAAME,oBAAU,IAAIC,IAAkC;CACtD,KAAK,IAAMR,KAASI,GAClB,KAAK,IAAMK,KAAST,EAAMU,QACxB,AAAKH,EAAQI,IAAIF,CAAK,KAAGF,EAAQK,IAAIH,GAAOT,CAAK;CAErD,IAAMa,oBAAU,IAAIL,IAAe,GAC7BM,IAAiB,CAAA;CACvB,KAAK,IAAMR,KAAQL,GAAO;EACxB,IAAMc,IAAOV,EAAIC,CAAI;EACrB,AAAIC,EAAQI,IAAII,CAAI,IAAGF,EAAQD,IAAIG,GAAMT,CAAI,IACxCQ,EAAUE,KAAKV,CAAI;CAC1B;CAEA,IAAMW,IAA0B,C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BG,EAAenC,GAI7B;CACA,IAAMoC,IAAQpC,EAAMjB,WAAW;CAC/B,OAAO;EACLG,MAAMkD,KAASpC,EAAMf,WAAW,UAAU,CAACe,EAAMd;EACjDC,KAAKiD,KAASpC,EAAMf,WAAW,SAAS,CAACgB,EAAYD,EAAMb,GAAG;EAC9DC,OAAOgD,KAASpC,EAAMf,WAAW,eAAe,CAACe,EAAMZ;CACzD;AACF;AAMA,SAAS6C,EACP7C,GACAG,GACS;CACT,OAAO,CAAC,CAACA,KAAOb,EAAOU,CAAK,CAAC,CAACwC,MAAKU,MAASA,EAAMC,OAAOhD,CAAG;AAC9D"}
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { DashboardViewConfig } from '../model/index.js';
|
|
2
|
-
/**
|
|
3
|
-
* A stored config read into the form this engine writes: onto the 24-column
|
|
4
|
-
* grid (D22 E), a pre-C board condition into its filters' defaults and the
|
|
5
|
-
* board's fixed scope (D23 Q16, D26 Q31; `intoDefaults` below), and the
|
|
6
|
-
* board's own condition, which a board no longer has, out of the config
|
|
7
|
-
* (D27; `withoutOwnCondition` below), and a board stored before its time
|
|
8
|
-
* wires were derived read with its unwired panels reading whole (D1;
|
|
9
|
-
* `withTimeIgnored`, `timeBindings.ts`). Each step is marked by the config
|
|
10
|
-
* itself — `columns`, `fixed`, the `filter` member, `derivesTime` — so it
|
|
11
|
-
* happens once: a second read, or a read after any edit, leaves the config
|
|
12
|
-
* alone.
|
|
13
|
-
*
|
|
14
|
-
* A config that does not say which grid it is in (`columns`) was written for
|
|
15
|
-
* the twelve-column grid: every `x` and `w` is doubled and every `y` and `h`
|
|
16
|
-
* kept, which puts each panel on exactly the pixels it had — a column of the
|
|
17
|
-
* new grid and the gap after it are half of one of the old, so a panel
|
|
18
|
-
* twice as many columns wide spans the same width. It gains `columns` and an
|
|
19
|
-
* empty `tabs`, so a save writes the new form and the next read leaves it
|
|
20
|
-
* alone.
|
|
21
|
-
*
|
|
22
|
-
* A config that says anything about `columns` is not guessed at: one naming
|
|
23
|
-
* another grid is left for admission to refuse (`dashboard.grid.unsupported`).
|
|
24
|
-
* A config already in this form comes back as it is (the same object, so
|
|
25
|
-
* nothing downstream sees a change). Nothing here throws on a malformed
|
|
26
|
-
* config either — whatever is not a panel with numbers, or a tree, is
|
|
27
|
-
* carried over untouched and reported where admission reports it.
|
|
28
|
-
*
|
|
29
|
-
* It is called at one place, the engine's read boundary (`readStored`,
|
|
30
|
-
* `runtime/storedViews.ts`), so everything else reads the new form only.
|
|
31
|
-
*/
|
|
32
|
-
export declare function migrateDashboardConfig(config: DashboardViewConfig): DashboardViewConfig;
|
|
33
|
-
//# sourceMappingURL=migrate.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"migrate.d.ts","sourceRoot":"","sources":["../../src/dashboard/migrate.ts"],"names":[],"mappings":"AAcA,OAAO,EAKL,KAAK,mBAAmB,EAGzB,MAAM,mBAAmB,CAAC;AAW3B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,wBAAgB,sBAAsB,CACpC,MAAM,EAAE,mBAAmB,GAC1B,mBAAmB,CAIrB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"useViewEngine.d.ts","sourceRoot":"","sources":["../../src/react/useViewEngine.ts"],"names":[],"mappings":"AAqBA,OAAO,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC3D,OAAO,EACL,UAAU,EACV,KAAK,cAAc,EACnB,KAAK,WAAW,EAChB,KAAK,iBAAiB,EACvB,MAAM,qBAAqB,CAAC;AAM7B;;;;;;;GAOG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE,iBAAiB,GAAG,UAAU,CAYpE;AAED;;;;;;;;GAQG;AACH,wBAAgB,cAAc,CAAC,CAAC,SAAS,gBAAgB,CAAC,OAAO,CAAC,EAChE,OAAO,EAAE,CAAC,GAAG,IAAI,GAChB,UAAU,CAAC,CAAC,CAA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