@malloy-publisher/sdk 0.9.1 → 0.9.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{RenderedResult-BRgIgxWh.es.js → RenderedResult-DwB0-9Yx.es.js} +219 -210
- package/dist/RenderedResult-hKjFEqaN.cjs.js +141 -0
- package/dist/{ServerProvider-Boxrv6Ym.es.js → ServerProvider-CcSrGaRN.es.js} +1473 -1326
- package/dist/ServerProvider-Gbf1YPOP.cjs.js +1 -0
- package/dist/builder/index.cjs.js +143 -58
- package/dist/builder/index.es.js +12179 -9318
- package/dist/builder-entry.d.ts +5 -1
- package/dist/client/api.d.ts +247 -56
- package/dist/client/configuration.d.ts +1 -1
- package/dist/client/index.cjs.js +1 -1
- package/dist/client/index.d.ts +1 -1
- package/dist/client/index.es.js +94 -88
- package/dist/client-entry.d.ts +2 -0
- package/dist/components/ApiErrorDisplay.d.ts +11 -0
- package/dist/components/AppDialog.d.ts +6 -6
- package/dist/components/Dashboard/Dashboard.d.ts +8 -15
- package/dist/components/Dashboard/DashboardGrid.d.ts +38 -6
- package/dist/components/Dashboard/DashboardTile.d.ts +21 -2
- package/dist/components/Dashboard/DashboardView.d.ts +71 -0
- package/dist/components/Dashboard/TileCard.d.ts +30 -5
- package/dist/components/Dashboard/TileFilterTag.d.ts +12 -0
- package/dist/components/Dashboard/dropValueUrlTags.d.ts +6 -0
- package/dist/components/Dashboard/index.d.ts +5 -1
- package/dist/components/Dashboard/telemetry.d.ts +16 -3
- package/dist/components/Dashboard/textSource.d.ts +19 -0
- package/dist/components/DashboardBuilder/AddTileDialog.d.ts +15 -9
- package/dist/components/DashboardBuilder/BuilderDialogs.d.ts +25 -0
- package/dist/components/DashboardBuilder/BuilderGrid.d.ts +31 -0
- package/dist/components/DashboardBuilder/BuilderHeader.d.ts +17 -0
- package/dist/components/DashboardBuilder/BuilderToolbar.d.ts +23 -15
- package/dist/components/DashboardBuilder/ChartPicker.d.ts +31 -0
- package/dist/components/DashboardBuilder/DashboardBuilder.d.ts +56 -21
- package/dist/components/DashboardBuilder/DashboardEditor.d.ts +44 -5
- package/dist/components/DashboardBuilder/EditorSurface.d.ts +33 -0
- package/dist/components/DashboardBuilder/FilterDialog.d.ts +2 -2
- package/dist/components/DashboardBuilder/FilterStrip.d.ts +8 -4
- package/dist/components/DashboardBuilder/InlineMarkdown.d.ts +18 -0
- package/dist/components/DashboardBuilder/InlineText.d.ts +19 -0
- package/dist/components/DashboardBuilder/NotebookEditor.d.ts +15 -0
- package/dist/components/DashboardBuilder/SourceViewPicker.d.ts +9 -0
- package/dist/components/DashboardBuilder/TextTileBody.d.ts +10 -0
- package/dist/components/DashboardBuilder/TileFrame.d.ts +51 -12
- package/dist/components/DashboardBuilder/TileMenu.d.ts +12 -6
- package/dist/components/DashboardBuilder/annotationText.d.ts +4 -0
- package/dist/components/DashboardBuilder/builderReport.d.ts +13 -0
- package/dist/components/DashboardBuilder/catalog.d.ts +4 -18
- package/dist/components/DashboardBuilder/changedTile.d.ts +7 -0
- package/dist/components/DashboardBuilder/chartLine.d.ts +33 -0
- package/dist/components/DashboardBuilder/controls.d.ts +2 -2
- package/dist/components/DashboardBuilder/document.d.ts +42 -26
- package/dist/components/DashboardBuilder/documentSession.d.ts +100 -0
- package/dist/components/DashboardBuilder/imports.d.ts +19 -0
- package/dist/components/DashboardBuilder/inlineEdit.d.ts +18 -0
- package/dist/components/DashboardBuilder/legacyNotebook.d.ts +73 -0
- package/dist/components/DashboardBuilder/loadMalloy.d.ts +15 -0
- package/dist/components/DashboardBuilder/malloyTree.d.ts +119 -0
- package/dist/components/DashboardBuilder/newDashboard.d.ts +3 -1
- package/dist/components/DashboardBuilder/openDraft.d.ts +10 -0
- package/dist/components/DashboardBuilder/preview.d.ts +24 -4
- package/dist/components/DashboardBuilder/readDocument.d.ts +6 -1
- package/dist/components/DashboardBuilder/readForEditor.d.ts +16 -0
- package/dist/components/DashboardBuilder/sortable.d.ts +16 -0
- package/dist/components/DashboardBuilder/spliceDocument.d.ts +15 -13
- package/dist/components/DashboardBuilder/spliceResult.d.ts +11 -0
- package/dist/components/DashboardBuilder/tagParse.d.ts +24 -0
- package/dist/components/DashboardBuilder/telemetry.d.ts +43 -0
- package/dist/components/DashboardBuilder/testing/fixtures.d.ts +3 -1
- package/dist/components/DashboardBuilder/testing/inline.d.ts +4 -0
- package/dist/components/DashboardBuilder/testing/resize.d.ts +7 -0
- package/dist/components/DashboardBuilder/tileDisplayTitle.d.ts +7 -0
- package/dist/components/DashboardBuilder/useBuilderSelection.d.ts +53 -0
- package/dist/components/DashboardBuilder/useBuilderSession.d.ts +86 -0
- package/dist/components/DashboardBuilder/useBuilderShortcuts.d.ts +9 -6
- package/dist/components/DashboardBuilder/useControlBindings.d.ts +30 -0
- package/dist/components/DashboardBuilder/useConversionConfirm.d.ts +20 -0
- package/dist/components/DashboardBuilder/useDashboardEditor.d.ts +19 -55
- package/dist/components/DashboardBuilder/useDocumentEditor.d.ts +105 -0
- package/dist/components/DashboardBuilder/useDraft.d.ts +3 -1
- package/dist/components/DashboardBuilder/useExitGuard.d.ts +19 -0
- package/dist/components/DashboardBuilder/useFilterForm.d.ts +3 -3
- package/dist/components/DashboardBuilder/useHostCopy.d.ts +26 -0
- package/dist/components/DashboardBuilder/useOpenDraftCommit.d.ts +17 -0
- package/dist/components/DashboardBuilder/useOpenedDocument.d.ts +71 -0
- package/dist/components/DashboardBuilder/useSaveChannel.d.ts +50 -0
- package/dist/components/DashboardBuilder/useTileEditing.d.ts +33 -0
- package/dist/components/DashboardBuilder/useTileResize.d.ts +6 -3
- package/dist/components/DocumentCreate/canRetry.d.ts +6 -0
- package/dist/components/DocumentCreate/createDocument.d.ts +58 -0
- package/dist/components/DocumentCreate/documentPath.d.ts +10 -0
- package/dist/components/DocumentCreate/events.d.ts +10 -0
- package/dist/components/DocumentCreate/exportedSources.d.ts +7 -0
- package/dist/components/DocumentCreate/guards.d.ts +12 -0
- package/dist/components/DocumentCreate/index.d.ts +6 -0
- package/dist/components/DocumentCreate/newNotebook.d.ts +9 -0
- package/dist/components/DocumentCreate/useDocumentChoices.d.ts +32 -0
- package/dist/components/DocumentStorage/DocumentStorage.d.ts +2 -1
- package/dist/components/Loading.d.ts +13 -0
- package/dist/components/NarrowEditGate.d.ts +8 -0
- package/dist/components/Notebook/Notebook.d.ts +1 -1
- package/dist/components/Notebook/NotebookCell.d.ts +1 -5
- package/dist/components/Package/NewDocumentDialog.d.ts +33 -0
- package/dist/components/Package/Package.d.ts +17 -1
- package/dist/components/Package/documentLocation.d.ts +28 -0
- package/dist/components/Package/index.d.ts +5 -1
- package/dist/components/Package/useDocumentLocation.d.ts +12 -0
- package/dist/components/PackageSection.d.ts +2 -2
- package/dist/components/Prose.d.ts +1 -1
- package/dist/components/RenderedResult/RenderedResult.d.ts +2 -0
- package/dist/components/RenderedResult/ResultContainer.d.ts +8 -1
- package/dist/components/RenderedResult/ResultPanel.d.ts +3 -1
- package/dist/components/RenderedResult/loadRenderer.d.ts +7 -0
- package/dist/components/RenderedResult/resultSizing.d.ts +9 -1
- package/dist/components/ServerProvider.d.ts +2 -1
- package/dist/components/UnsavedChangesDialog.d.ts +9 -0
- package/dist/components/given/GivensPanel.d.ts +2 -2
- package/dist/components/given/paramCodec.d.ts +8 -1
- package/dist/components/index.d.ts +3 -2
- package/dist/components/styles.d.ts +4 -4
- package/dist/hooks/givenValue.d.ts +6 -0
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/useCompiledDocument.d.ts +23 -0
- package/dist/hooks/useDocumentControls.d.ts +6 -1
- package/dist/hooks/useNarrowScreen.d.ts +4 -0
- package/dist/hooks/useNearViewport.d.ts +16 -0
- package/dist/hooks/useQueryResult.d.ts +2 -0
- package/dist/hooks/useQueryWithApiError.d.ts +7 -2
- package/dist/hooks/useSettled.d.ts +14 -0
- package/dist/hooks/useSuggestOptions.d.ts +9 -2
- package/dist/index.cjs.js +23 -24
- package/dist/index.es.js +9041 -7002
- package/dist/text/index.cjs.js +1 -0
- package/dist/text/index.d.ts +2 -0
- package/dist/text/index.es.js +6 -0
- package/dist/text-entry-BJwltZiy.cjs.js +7 -0
- package/dist/text-entry-CA0LZ1xL.es.js +196 -0
- package/dist/text-entry.d.ts +2 -0
- package/dist/theme/accent.d.ts +29 -0
- package/dist/theme/buildVegaThemeOverride.d.ts +3 -3
- package/dist/theme/index.d.ts +3 -0
- package/dist/theme/keys.d.ts +1 -1
- package/dist/theme/motion.d.ts +31 -0
- package/dist/theme/readChartAnnotations.d.ts +1 -1
- package/dist/theme/resolveTheme.d.ts +4 -4
- package/dist/theme/types.d.ts +33 -5
- package/dist/{Dashboard-H1kJlDFo.es.js → useCompiledDocument-BU6d8FPp.es.js} +17904 -19057
- package/dist/useCompiledDocument-pOg2W-Yt.cjs.js +142 -0
- package/dist/utils/clock.d.ts +2 -0
- package/dist/utils/malloyText.d.ts +104 -0
- package/package.json +20 -11
- package/src/builder-entry.ts +36 -0
- package/src/client-entry.ts +8 -0
- package/src/clientEntry.spec.ts +17 -0
- package/src/components/ApiErrorDisplay.tsx +37 -18
- package/src/components/AppDialog.tsx +8 -7
- package/src/components/Dashboard/Dashboard.spec.tsx +3 -32
- package/src/components/Dashboard/Dashboard.tsx +29 -280
- package/src/components/Dashboard/DashboardGrid.tsx +87 -8
- package/src/components/Dashboard/DashboardTile.spec.tsx +121 -2
- package/src/components/Dashboard/DashboardTile.tsx +121 -30
- package/src/components/Dashboard/DashboardView.spec.tsx +368 -0
- package/src/components/Dashboard/DashboardView.tsx +428 -0
- package/src/components/Dashboard/RowsDialog.tsx +4 -3
- package/src/components/Dashboard/TileCard.tsx +60 -11
- package/src/components/Dashboard/TileFilterTag.spec.tsx +73 -0
- package/src/components/Dashboard/TileFilterTag.tsx +78 -0
- package/src/components/Dashboard/defaultTileSpan.spec.ts +32 -0
- package/src/components/Dashboard/dropValueUrlTags.spec.ts +177 -0
- package/src/components/Dashboard/dropValueUrlTags.ts +108 -0
- package/src/components/Dashboard/index.ts +13 -1
- package/src/components/Dashboard/telemetry.ts +17 -5
- package/src/components/Dashboard/textSource.spec.ts +36 -0
- package/src/components/Dashboard/textSource.ts +39 -0
- package/src/components/DashboardBuilder/AddTileDialog.spec.tsx +88 -0
- package/src/components/DashboardBuilder/AddTileDialog.tsx +124 -138
- package/src/components/DashboardBuilder/BuilderDialogs.tsx +162 -0
- package/src/components/DashboardBuilder/BuilderGrid.tsx +245 -0
- package/src/components/DashboardBuilder/BuilderHeader.tsx +107 -0
- package/src/components/DashboardBuilder/BuilderToolbar.tsx +111 -80
- package/src/components/DashboardBuilder/ChartPicker.render.spec.tsx +25 -0
- package/src/components/DashboardBuilder/ChartPicker.spec.ts +77 -0
- package/src/components/DashboardBuilder/ChartPicker.tsx +156 -0
- package/src/components/DashboardBuilder/DashboardBuilder.charts.spec.tsx +205 -0
- package/src/components/DashboardBuilder/DashboardBuilder.exit.spec.tsx +183 -0
- package/src/components/DashboardBuilder/DashboardBuilder.inline.spec.tsx +373 -0
- package/src/components/DashboardBuilder/DashboardBuilder.notebook.spec.tsx +310 -0
- package/src/components/DashboardBuilder/DashboardBuilder.openDraft.spec.tsx +105 -0
- package/src/components/DashboardBuilder/DashboardBuilder.sources.spec.tsx +117 -0
- package/src/components/DashboardBuilder/DashboardBuilder.spec.tsx +146 -108
- package/src/components/DashboardBuilder/DashboardBuilder.textTiles.spec.tsx +179 -0
- package/src/components/DashboardBuilder/DashboardBuilder.tsx +330 -512
- package/src/components/DashboardBuilder/DashboardEditor.authoritative.spec.tsx +55 -25
- package/src/components/DashboardBuilder/DashboardEditor.emptyStart.spec.tsx +142 -0
- package/src/components/DashboardBuilder/DashboardEditor.filterTag.spec.tsx +162 -0
- package/src/components/DashboardBuilder/DashboardEditor.notebook.spec.tsx +310 -0
- package/src/components/DashboardBuilder/DashboardEditor.package.spec.tsx +39 -13
- package/src/components/DashboardBuilder/DashboardEditor.resourceUri.spec.tsx +9 -26
- package/src/components/DashboardBuilder/DashboardEditor.spec.tsx +102 -25
- package/src/components/DashboardBuilder/DashboardEditor.textSource.spec.tsx +317 -0
- package/src/components/DashboardBuilder/DashboardEditor.tsx +252 -780
- package/src/components/DashboardBuilder/DrillDialog.tsx +2 -2
- package/src/components/DashboardBuilder/EditorSurface.tsx +471 -0
- package/src/components/DashboardBuilder/FilterDialog.tsx +23 -11
- package/src/components/DashboardBuilder/FilterStrip.tsx +130 -70
- package/src/components/DashboardBuilder/InlineMarkdown.tsx +182 -0
- package/src/components/DashboardBuilder/InlineText.tsx +112 -0
- package/src/components/DashboardBuilder/NotebookEditor.tsx +44 -0
- package/src/components/DashboardBuilder/SourceViewPicker.tsx +122 -0
- package/src/components/DashboardBuilder/TextTileBody.tsx +31 -0
- package/src/components/DashboardBuilder/TileFrame.tsx +302 -163
- package/src/components/DashboardBuilder/TileMenu.tsx +125 -97
- package/src/components/DashboardBuilder/annotationText.spec.ts +33 -0
- package/src/components/DashboardBuilder/annotationText.ts +17 -0
- package/src/components/DashboardBuilder/artifactBlock.spec.ts +248 -0
- package/src/components/DashboardBuilder/artifactTagParity.spec.ts +46 -0
- package/src/components/DashboardBuilder/builderReport.ts +74 -0
- package/src/components/DashboardBuilder/catalog.aggregate.spec.ts +49 -0
- package/src/components/DashboardBuilder/catalog.spec.ts +2 -44
- package/src/components/DashboardBuilder/catalog.ts +61 -57
- package/src/components/DashboardBuilder/changedTile.spec.ts +46 -0
- package/src/components/DashboardBuilder/changedTile.ts +28 -0
- package/src/components/DashboardBuilder/chartLine.spec.ts +180 -0
- package/src/components/DashboardBuilder/chartLine.ts +121 -0
- package/src/components/DashboardBuilder/controls.spec.ts +21 -10
- package/src/components/DashboardBuilder/controls.ts +22 -8
- package/src/components/DashboardBuilder/document.ts +53 -5
- package/src/components/DashboardBuilder/documentSession.spec.ts +209 -0
- package/src/components/DashboardBuilder/documentSession.ts +258 -0
- package/src/components/DashboardBuilder/emptyStart.spec.ts +131 -0
- package/src/components/DashboardBuilder/imports.spec.ts +61 -0
- package/src/components/DashboardBuilder/imports.ts +93 -0
- package/src/components/DashboardBuilder/inlineEdit.tsx +78 -0
- package/src/components/DashboardBuilder/invariants.spec.ts +6 -2
- package/src/components/DashboardBuilder/legacyNotebook.chart.spec.ts +77 -0
- package/src/components/DashboardBuilder/legacyNotebook.convert.spec.ts +630 -0
- package/src/components/DashboardBuilder/legacyNotebook.read.spec.ts +338 -0
- package/src/components/DashboardBuilder/legacyNotebook.ts +1117 -0
- package/src/components/DashboardBuilder/loadMalloy.spec.ts +80 -0
- package/src/components/DashboardBuilder/loadMalloy.ts +39 -0
- package/src/components/DashboardBuilder/malloyTree.ts +159 -7
- package/src/components/DashboardBuilder/newDashboard.spec.ts +46 -2
- package/src/components/DashboardBuilder/newDashboard.ts +30 -3
- package/src/components/DashboardBuilder/openDraft.ts +52 -0
- package/src/components/DashboardBuilder/preview.shapes.spec.ts +75 -0
- package/src/components/DashboardBuilder/preview.spec.ts +159 -12
- package/src/components/DashboardBuilder/preview.ts +83 -9
- package/src/components/DashboardBuilder/readDocument.spec.ts +174 -26
- package/src/components/DashboardBuilder/readDocument.ts +137 -45
- package/src/components/DashboardBuilder/readForEditor.spec.ts +80 -0
- package/src/components/DashboardBuilder/readForEditor.ts +52 -0
- package/src/components/DashboardBuilder/scannerShapes.spec.ts +14 -13
- package/src/components/DashboardBuilder/sortable.spec.ts +89 -0
- package/src/components/DashboardBuilder/sortable.tsx +11 -10
- package/src/components/DashboardBuilder/spliceDocument.chart.spec.ts +340 -0
- package/src/components/DashboardBuilder/spliceDocument.imports.spec.ts +167 -0
- package/src/components/DashboardBuilder/spliceDocument.spec.ts +229 -94
- package/src/components/DashboardBuilder/spliceDocument.ts +768 -131
- package/src/components/DashboardBuilder/spliceResult.ts +15 -0
- package/src/components/DashboardBuilder/statementExtent.spec.ts +33 -30
- package/src/components/DashboardBuilder/tagParse.spec.ts +149 -0
- package/src/components/DashboardBuilder/tagParse.ts +103 -0
- package/src/components/DashboardBuilder/telemetry.ts +47 -0
- package/src/components/DashboardBuilder/testing/artifactTagParity.json +253 -0
- package/src/components/DashboardBuilder/testing/documentKindRule.json +40 -0
- package/src/components/DashboardBuilder/testing/fixtures.ts +16 -1
- package/src/components/DashboardBuilder/testing/inline.ts +25 -0
- package/src/components/DashboardBuilder/testing/resize.ts +48 -0
- package/src/components/DashboardBuilder/testing/urlRenderTags.json +62 -0
- package/src/components/DashboardBuilder/textTiles.spec.ts +760 -0
- package/src/components/DashboardBuilder/tileDisplayTitle.ts +13 -0
- package/src/components/DashboardBuilder/useBuilderSelection.ts +121 -0
- package/src/components/DashboardBuilder/useBuilderSession.spec.ts +250 -0
- package/src/components/DashboardBuilder/useBuilderSession.ts +255 -0
- package/src/components/DashboardBuilder/useBuilderShortcuts.overlay.spec.tsx +97 -0
- package/src/components/DashboardBuilder/useBuilderShortcuts.spec.tsx +60 -0
- package/src/components/DashboardBuilder/useBuilderShortcuts.ts +45 -9
- package/src/components/DashboardBuilder/useControlBindings.ts +152 -0
- package/src/components/DashboardBuilder/useConversionConfirm.ts +55 -0
- package/src/components/DashboardBuilder/useDashboardEditor.spec.ts +16 -13
- package/src/components/DashboardBuilder/useDashboardEditor.ts +57 -181
- package/src/components/DashboardBuilder/useDocumentEditor.spec.ts +565 -0
- package/src/components/DashboardBuilder/useDocumentEditor.ts +399 -0
- package/src/components/DashboardBuilder/useDraft.ts +15 -2
- package/src/components/DashboardBuilder/useExitGuard.spec.ts +159 -0
- package/src/components/DashboardBuilder/useExitGuard.ts +89 -0
- package/src/components/DashboardBuilder/useFilterForm.existing.spec.tsx +41 -0
- package/src/components/DashboardBuilder/useFilterForm.spec.tsx +24 -2
- package/src/components/DashboardBuilder/useFilterForm.ts +41 -13
- package/src/components/DashboardBuilder/useHostCopy.ts +104 -0
- package/src/components/DashboardBuilder/useOpenDraftCommit.ts +47 -0
- package/src/components/DashboardBuilder/useOpenedDocument.ts +314 -0
- package/src/components/DashboardBuilder/useSaveChannel.ts +275 -0
- package/src/components/DashboardBuilder/useTileEditing.ts +141 -0
- package/src/components/DashboardBuilder/useTileReorder.spec.tsx +28 -5
- package/src/components/DashboardBuilder/useTileReorder.ts +5 -7
- package/src/components/DashboardBuilder/useTileResize.spec.tsx +30 -5
- package/src/components/DashboardBuilder/useTileResize.ts +31 -8
- package/src/components/DataAppViewer/DataAppViewer.tsx +7 -4
- package/src/components/DocumentCreate/canRetry.spec.ts +32 -0
- package/src/components/DocumentCreate/canRetry.ts +19 -0
- package/src/components/DocumentCreate/createDocument.spec.ts +310 -0
- package/src/components/DocumentCreate/createDocument.ts +159 -0
- package/src/components/DocumentCreate/documentPath.ts +40 -0
- package/src/components/DocumentCreate/events.ts +15 -0
- package/src/components/DocumentCreate/exportedSources.ts +25 -0
- package/src/components/DocumentCreate/guards.ts +45 -0
- package/src/components/DocumentCreate/index.ts +27 -0
- package/src/components/DocumentCreate/newNotebook.spec.ts +156 -0
- package/src/components/DocumentCreate/newNotebook.ts +44 -0
- package/src/components/DocumentCreate/useDocumentChoices.spec.tsx +138 -0
- package/src/components/DocumentCreate/useDocumentChoices.ts +113 -0
- package/src/components/DocumentStorage/DocumentStorage.ts +2 -1
- package/src/components/Environment/Environment.tsx +0 -10
- package/src/components/Loading.tsx +14 -0
- package/src/components/Model/Model.tsx +16 -9
- package/src/components/Model/ModelExplorer.spec.tsx +2 -2
- package/src/components/Model/ModelExplorer.tsx +2 -2
- package/src/components/Model/SourcesExplorer.tsx +2 -4
- package/src/components/NarrowEditGate.spec.tsx +73 -0
- package/src/components/NarrowEditGate.tsx +29 -0
- package/src/components/Notebook/Notebook.layout.spec.tsx +94 -0
- package/src/components/Notebook/Notebook.tsx +72 -29
- package/src/components/Notebook/NotebookCell.tsx +90 -215
- package/src/components/Package/NewDocumentDialog.spec.tsx +749 -0
- package/src/components/Package/NewDocumentDialog.tsx +401 -0
- package/src/components/Package/Package.artifacts.spec.tsx +186 -0
- package/src/components/Package/Package.create.spec.tsx +401 -0
- package/src/components/Package/Package.notebooks.spec.tsx +18 -0
- package/src/components/Package/Package.tsx +396 -177
- package/src/components/Package/documentLocation.spec.ts +81 -0
- package/src/components/Package/documentLocation.ts +55 -0
- package/src/components/Package/index.ts +14 -1
- package/src/components/Package/useDocumentLocation.ts +59 -0
- package/src/components/PackageSection.tsx +2 -2
- package/src/components/Prose.spec.tsx +37 -0
- package/src/components/Prose.tsx +35 -5
- package/src/components/RenderedResult/RenderedResult.tsx +23 -8
- package/src/components/RenderedResult/ResultContainer.tsx +51 -13
- package/src/components/RenderedResult/ResultPanel.tsx +24 -5
- package/src/components/RenderedResult/loadRenderer.ts +42 -0
- package/src/components/RenderedResult/resultSizing.spec.ts +68 -0
- package/src/components/RenderedResult/resultSizing.ts +14 -3
- package/src/components/ServerProvider.tsx +2 -1
- package/src/components/UnsavedChangesDialog.spec.tsx +70 -0
- package/src/components/UnsavedChangesDialog.tsx +49 -0
- package/src/components/given/GivenInput.spec.tsx +5 -5
- package/src/components/given/GivenInput.tsx +46 -38
- package/src/components/given/GivensPanel.spec.tsx +6 -6
- package/src/components/given/GivensPanel.tsx +5 -11
- package/src/components/given/paramCodec.ts +27 -1
- package/src/components/index.ts +3 -2
- package/src/components/styles.ts +4 -5
- package/src/hooks/givenValue.ts +9 -0
- package/src/hooks/index.ts +7 -0
- package/src/hooks/useCompiledDocument.spec.tsx +86 -0
- package/src/hooks/useCompiledDocument.ts +59 -0
- package/src/hooks/useDimensionalFilterRangeData.ts +3 -1
- package/src/hooks/useDocumentControls.ts +13 -1
- package/src/hooks/useNarrowScreen.ts +21 -0
- package/src/hooks/useNearViewport.spec.tsx +150 -0
- package/src/hooks/useNearViewport.ts +102 -0
- package/src/hooks/useQueryResult.ts +23 -1
- package/src/hooks/useQueryWithApiError.ts +10 -3
- package/src/hooks/useRawQueryData.ts +3 -1
- package/src/hooks/useSettled.spec.ts +41 -0
- package/src/hooks/useSettled.ts +27 -0
- package/src/hooks/useSuggestOptions.dom.spec.ts +40 -1
- package/src/hooks/useSuggestOptions.ts +42 -10
- package/src/mainEntry.spec.ts +145 -0
- package/src/text-entry.ts +12 -0
- package/src/textEntry.spec.ts +112 -0
- package/src/theme/accent.spec.ts +116 -0
- package/src/theme/accent.ts +148 -0
- package/src/theme/buildTableCssVars.spec.ts +24 -0
- package/src/theme/buildTableCssVars.ts +1 -2
- package/src/theme/buildVegaThemeOverride.spec.ts +38 -2
- package/src/theme/buildVegaThemeOverride.ts +5 -5
- package/src/theme/defaults.ts +34 -0
- package/src/theme/index.ts +9 -0
- package/src/theme/keys.ts +6 -0
- package/src/theme/motion.ts +44 -0
- package/src/theme/readChartAnnotations.spec.ts +18 -0
- package/src/theme/readChartAnnotations.ts +1 -1
- package/src/theme/resolveTheme.spec.ts +73 -0
- package/src/theme/resolveTheme.ts +61 -20
- package/src/theme/types.ts +30 -5
- package/src/utils/clock.spec.ts +12 -0
- package/src/utils/clock.ts +6 -0
- package/src/{components/DashboardBuilder → utils}/malloyText.spec.ts +48 -0
- package/src/utils/malloyText.ts +368 -0
- package/src/utils/queryClient.ts +8 -0
- package/vite.config.ts +4 -0
- package/dist/Dashboard-ChyylkTD.cjs.js +0 -136
- package/dist/RenderedResult-AJPMUkAD.cjs.js +0 -135
- package/dist/ServerProvider-CXrOKD6g.cjs.js +0 -1
- package/dist/components/Dashboard/DashboardBar.d.ts +0 -21
- package/dist/components/Dashboard/ExploreDialog.d.ts +0 -20
- package/dist/components/DashboardBuilder/DiffDialog.d.ts +0 -15
- package/dist/components/DashboardBuilder/SettingsPopover.d.ts +0 -20
- package/dist/components/DashboardBuilder/diff.d.ts +0 -35
- package/dist/components/DashboardBuilder/malloyText.d.ts +0 -64
- package/dist/components/Package/NewDashboardDialog.d.ts +0 -18
- package/src/components/Dashboard/DashboardBar.tsx +0 -88
- package/src/components/Dashboard/ExploreDialog.tsx +0 -89
- package/src/components/DashboardBuilder/DiffDialog.tsx +0 -122
- package/src/components/DashboardBuilder/SettingsPopover.tsx +0 -168
- package/src/components/DashboardBuilder/diff.spec.ts +0 -44
- package/src/components/DashboardBuilder/diff.ts +0 -93
- package/src/components/DashboardBuilder/malloyText.ts +0 -214
- package/src/components/Package/NewDashboardDialog.spec.tsx +0 -129
- package/src/components/Package/NewDashboardDialog.tsx +0 -265
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Malloy Publisher - Semantic Model Serving API
|
|
3
|
-
* The Malloy Publisher - Semantic Model Serving API provides access to Malloy packages and everything they contain. A Malloy package is a directory with a `publisher.json` manifest at its root, holding Malloy models (`.malloy` files), notebooks (`.malloynb` files and `.malloy` files
|
|
3
|
+
* The Malloy Publisher - Semantic Model Serving API provides access to Malloy packages and everything they contain. A Malloy package is a directory with a `publisher.json` manifest at its root, holding Malloy models (`.malloy` files), notebooks (`.malloynb` files and tagged `.malloy` files that are notebooks), embedded data (`.parquet`, `.csv`, and `.xlsx` files), and optionally an HTML data app under `public/`. ## Key Features - **Discovery**: List environments, packages, and the models, notebooks, data apps, and data a package contains - **Query Execution**: Run queries against models, execute notebooks a cell at a time, and compile-check Malloy without running it - **Data Apps**: In-package HTML data apps served from a package\'s `public/` directory - **Materializations**: Persist Malloy sources as tables, on a schedule or on demand - **Connection Management**: Configure and test warehouse connections, and browse their schemas and tables - **Watch Mode**: File watching, and a change-event stream for development workflows ## Resource Hierarchy The API follows a hierarchical resource structure: ``` Server ├── /status, /theme server state, and the UI theme ├── /connections/test validate a connection config ├── /watch-mode/… development file watching └── Environments ├── Connections schemas, tables, and ad-hoc SQL └── Packages ├── Models query and compile ├── Notebooks execute a cell at a time ├── Data Apps static HTML data apps from public/ ├── Databases embedded data files ├── Materializations persisted sources ├── Connections package-scoped connection access └── Events SSE stream of file changes ``` For worked examples, see the packages this server bundles (https://github.com/malloydata/publisher/tree/main/examples); the package format is documented in docs/packages.md (https://github.com/malloydata/publisher/blob/main/docs/packages.md).
|
|
4
4
|
*
|
|
5
5
|
* The version of the OpenAPI document: v0
|
|
6
6
|
*
|
package/dist/client/index.cjs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../ServerProvider-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../ServerProvider-Gbf1YPOP.cjs.js");exports.AttachedDatabaseTypeEnum=e.AttachedDatabaseTypeEnum;exports.AzureConnectionAuthTypeEnum=e.AzureConnectionAuthTypeEnum;exports.CompileProblemSeverityEnum=e.CompileProblemSeverityEnum;exports.CompileRequestScopeEnum=e.CompileRequestScopeEnum;exports.CompileResultStatusEnum=e.CompileResultStatusEnum;exports.CompiledDocumentKindEnum=e.CompiledDocumentKindEnum;exports.Configuration=e.Configuration;exports.ConnectionProxyTypeEnum=e.ConnectionProxyTypeEnum;exports.ConnectionStatusStatusEnum=e.ConnectionStatusStatusEnum;exports.ConnectionTypeEnum=e.ConnectionTypeEnum;exports.ConnectionsApi=e.ConnectionsApi;exports.ConnectionsApiAxiosParamCreator=e.ConnectionsApiAxiosParamCreator;exports.ConnectionsApiFactory=e.ConnectionsApiFactory;exports.ConnectionsApiFp=e.ConnectionsApiFp;exports.ConnectionsTestApi=e.ConnectionsTestApi;exports.ConnectionsTestApiAxiosParamCreator=e.ConnectionsTestApiAxiosParamCreator;exports.ConnectionsTestApiFactory=e.ConnectionsTestApiFactory;exports.ConnectionsTestApiFp=e.ConnectionsTestApiFp;exports.DashboardManifestKindEnum=e.DashboardManifestKindEnum;exports.DashboardTileKindEnum=e.DashboardTileKindEnum;exports.DashboardsApi=e.DashboardsApi;exports.DashboardsApiAxiosParamCreator=e.DashboardsApiAxiosParamCreator;exports.DashboardsApiFactory=e.DashboardsApiFactory;exports.DashboardsApiFp=e.DashboardsApiFp;exports.DataAppFitEnum=e.DataAppFitEnum;exports.DataAppsApi=e.DataAppsApi;exports.DataAppsApiAxiosParamCreator=e.DataAppsApiAxiosParamCreator;exports.DataAppsApiFactory=e.DataAppsApiFactory;exports.DataAppsApiFp=e.DataAppsApiFp;exports.DatabaseTypeEnum=e.DatabaseTypeEnum;exports.DatabasesApi=e.DatabasesApi;exports.DatabasesApiAxiosParamCreator=e.DatabasesApiAxiosParamCreator;exports.DatabasesApiFactory=e.DatabasesApiFactory;exports.DatabasesApiFp=e.DatabasesApiFp;exports.EnvironmentsApi=e.EnvironmentsApi;exports.EnvironmentsApiAxiosParamCreator=e.EnvironmentsApiAxiosParamCreator;exports.EnvironmentsApiFactory=e.EnvironmentsApiFactory;exports.EnvironmentsApiFp=e.EnvironmentsApiFp;exports.ExecuteNotebookCellBypassFiltersEnum=e.ExecuteNotebookCellBypassFiltersEnum;exports.FilterTypeEnum=e.FilterTypeEnum;exports.FreshnessFallbackEnum=e.FreshnessFallbackEnum;exports.GivenControlEnum=e.GivenControlEnum;exports.LedgerEntryStrategyEnum=e.LedgerEntryStrategyEnum;exports.LogMessageSeverityEnum=e.LogMessageSeverityEnum;exports.ManifestEntryFreshnessFallbackEnum=e.ManifestEntryFreshnessFallbackEnum;exports.ManifestEntryOriginEnum=e.ManifestEntryOriginEnum;exports.ManifestEntryRefreshEnum=e.ManifestEntryRefreshEnum;exports.MaterializationActionActionEnum=e.MaterializationActionActionEnum;exports.MaterializationStatus=e.MaterializationStatus;exports.MaterializationsApi=e.MaterializationsApi;exports.MaterializationsApiAxiosParamCreator=e.MaterializationsApiAxiosParamCreator;exports.MaterializationsApiFactory=e.MaterializationsApiFactory;exports.MaterializationsApiFp=e.MaterializationsApiFp;exports.ModelsApi=e.ModelsApi;exports.ModelsApiAxiosParamCreator=e.ModelsApiAxiosParamCreator;exports.ModelsApiFactory=e.ModelsApiFactory;exports.ModelsApiFp=e.ModelsApiFp;exports.NotebookCellKindEnum=e.NotebookCellKindEnum;exports.NotebookCellResultKindEnum=e.NotebookCellResultKindEnum;exports.NotebookCellResultTypeEnum=e.NotebookCellResultTypeEnum;exports.NotebookCellTypeEnum=e.NotebookCellTypeEnum;exports.NotebooksApi=e.NotebooksApi;exports.NotebooksApiAxiosParamCreator=e.NotebooksApiAxiosParamCreator;exports.NotebooksApiFactory=e.NotebooksApiFactory;exports.NotebooksApiFp=e.NotebooksApiFp;exports.PackageEmbeddingIndexReasonEnum=e.PackageEmbeddingIndexReasonEnum;exports.PackageEmbeddingIndexStageEnum=e.PackageEmbeddingIndexStageEnum;exports.PackageEmbeddingIndexStatusEnum=e.PackageEmbeddingIndexStatusEnum;exports.PackageManifestBindingStatusEnum=e.PackageManifestBindingStatusEnum;exports.PackageQueryableSourcesEnum=e.PackageQueryableSourcesEnum;exports.PackageScopeEnum=e.PackageScopeEnum;exports.PackageStorageServeBindingsInnerOriginEnum=e.PackageStorageServeBindingsInnerOriginEnum;exports.PackageWarningsInnerSeverityEnum=e.PackageWarningsInnerSeverityEnum;exports.PackagesApi=e.PackagesApi;exports.PackagesApiAxiosParamCreator=e.PackagesApiAxiosParamCreator;exports.PackagesApiFactory=e.PackagesApiFactory;exports.PackagesApiFp=e.PackagesApiFp;exports.PersistSourcePlanOriginEnum=e.PersistSourcePlanOriginEnum;exports.PostgresConnectionSslmodeEnum=e.PostgresConnectionSslmodeEnum;exports.PublisherApi=e.PublisherApi;exports.PublisherApiAxiosParamCreator=e.PublisherApiAxiosParamCreator;exports.PublisherApiFactory=e.PublisherApiFactory;exports.PublisherApiFp=e.PublisherApiFp;exports.QueryClass=e.QueryClass;exports.QueryResultQueryRowLimitSourceEnum=e.QueryResultQueryRowLimitSourceEnum;exports.QueryResultServedFromEnum=e.QueryResultServedFromEnum;exports.RawNotebookFormatEnum=e.RawNotebookFormatEnum;exports.Realization=e.Realization;exports.RefusedSourceReasonEnum=e.RefusedSourceReasonEnum;exports.RefusedSourceTierEnum=e.RefusedSourceTierEnum;exports.RunContextTriggerEnum=e.RunContextTriggerEnum;exports.S3ConnectionProviderEnum=e.S3ConnectionProviderEnum;exports.ServerProvider=e.ServerProvider;exports.ServerStatusOperationalStateEnum=e.ServerStatusOperationalStateEnum;exports.ThemeDefaultModeEnum=e.ThemeDefaultModeEnum;exports.WatchModeApi=e.WatchModeApi;exports.WatchModeApiAxiosParamCreator=e.WatchModeApiAxiosParamCreator;exports.WatchModeApiFactory=e.WatchModeApiFactory;exports.WatchModeApiFp=e.WatchModeApiFp;exports.globalQueryClient=e.globalQueryClient;exports.usePublisherTheme=e.usePublisherTheme;exports.useServer=e.useServer;
|
package/dist/client/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Malloy Publisher - Semantic Model Serving API
|
|
3
|
-
* The Malloy Publisher - Semantic Model Serving API provides access to Malloy packages and everything they contain. A Malloy package is a directory with a `publisher.json` manifest at its root, holding Malloy models (`.malloy` files), notebooks (`.malloynb` files and `.malloy` files
|
|
3
|
+
* The Malloy Publisher - Semantic Model Serving API provides access to Malloy packages and everything they contain. A Malloy package is a directory with a `publisher.json` manifest at its root, holding Malloy models (`.malloy` files), notebooks (`.malloynb` files and tagged `.malloy` files that are notebooks), embedded data (`.parquet`, `.csv`, and `.xlsx` files), and optionally an HTML data app under `public/`. ## Key Features - **Discovery**: List environments, packages, and the models, notebooks, data apps, and data a package contains - **Query Execution**: Run queries against models, execute notebooks a cell at a time, and compile-check Malloy without running it - **Data Apps**: In-package HTML data apps served from a package\'s `public/` directory - **Materializations**: Persist Malloy sources as tables, on a schedule or on demand - **Connection Management**: Configure and test warehouse connections, and browse their schemas and tables - **Watch Mode**: File watching, and a change-event stream for development workflows ## Resource Hierarchy The API follows a hierarchical resource structure: ``` Server ├── /status, /theme server state, and the UI theme ├── /connections/test validate a connection config ├── /watch-mode/… development file watching └── Environments ├── Connections schemas, tables, and ad-hoc SQL └── Packages ├── Models query and compile ├── Notebooks execute a cell at a time ├── Data Apps static HTML data apps from public/ ├── Databases embedded data files ├── Materializations persisted sources ├── Connections package-scoped connection access └── Events SSE stream of file changes ``` For worked examples, see the packages this server bundles (https://github.com/malloydata/publisher/tree/main/examples); the package format is documented in docs/packages.md (https://github.com/malloydata/publisher/blob/main/docs/packages.md).
|
|
4
4
|
*
|
|
5
5
|
* The version of the OpenAPI document: v0
|
|
6
6
|
*
|
package/dist/client/index.es.js
CHANGED
|
@@ -1,99 +1,105 @@
|
|
|
1
|
-
import { A as e, a as
|
|
1
|
+
import { A as e, a as n, C as o, b as i, c as t, d as r, e as p, f as u, g as m, h as A, i as E, j as c, k as l, l as d, m as C, n as y, o as b, p as P, D as F, q as g, r as S, s as k, t as h, u as M, v as x, w as D, x as T, y as v, z as R, B as f, E as N, F as z, G as I, H as K, I as Q, J as W, K as B, L, M as O, N as w, O as q, P as G, Q as j, R as H, S as J, T as U, U as V, V as X, W as Y, X as Z, Y as _, Z as $, _ as aa, $ as sa, a0 as ea, a1 as na, a2 as oa, a3 as ia, a4 as ta, a5 as ra, a6 as pa, a7 as ua, a8 as ma, a9 as Aa, aa as Ea, ab as ca, ac as la, ad as da, ae as Ca, af as ya, ag as ba, ah as Pa, ai as Fa, aj as ga, ak as Sa, al as ka, am as ha, an as Ma, ao as xa, ap as Da, aq as Ta, ar as va, as as Ra, at as fa, au as Na, av as za, aw as Ia, ax as Ka, ay as Qa, az as Wa, aA as Ba, aB as La, aC as Oa, aD as wa, aE as qa, aF as Ga, aG as ja, aH as Ha, aI as Ja, aJ as Ua, aK as Va, aL as Xa } from "../ServerProvider-CcSrGaRN.es.js";
|
|
2
2
|
export {
|
|
3
3
|
e as AttachedDatabaseTypeEnum,
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
n as AzureConnectionAuthTypeEnum,
|
|
5
|
+
o as CompileProblemSeverityEnum,
|
|
6
|
+
i as CompileRequestScopeEnum,
|
|
7
7
|
t as CompileResultStatusEnum,
|
|
8
|
-
r as
|
|
9
|
-
p as
|
|
10
|
-
u as
|
|
8
|
+
r as CompiledDocumentKindEnum,
|
|
9
|
+
p as Configuration,
|
|
10
|
+
u as ConnectionProxyTypeEnum,
|
|
11
|
+
m as ConnectionStatusStatusEnum,
|
|
11
12
|
A as ConnectionTypeEnum,
|
|
12
|
-
|
|
13
|
+
E as ConnectionsApi,
|
|
13
14
|
c as ConnectionsApiAxiosParamCreator,
|
|
14
|
-
|
|
15
|
-
|
|
15
|
+
l as ConnectionsApiFactory,
|
|
16
|
+
d as ConnectionsApiFp,
|
|
16
17
|
C as ConnectionsTestApi,
|
|
17
18
|
y as ConnectionsTestApiAxiosParamCreator,
|
|
18
|
-
|
|
19
|
+
b as ConnectionsTestApiFactory,
|
|
19
20
|
P as ConnectionsTestApiFp,
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
M as
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
v as
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
21
|
+
F as DashboardManifestKindEnum,
|
|
22
|
+
g as DashboardTileKindEnum,
|
|
23
|
+
S as DashboardsApi,
|
|
24
|
+
k as DashboardsApiAxiosParamCreator,
|
|
25
|
+
h as DashboardsApiFactory,
|
|
26
|
+
M as DashboardsApiFp,
|
|
27
|
+
x as DataAppFitEnum,
|
|
28
|
+
D as DataAppsApi,
|
|
29
|
+
T as DataAppsApiAxiosParamCreator,
|
|
30
|
+
v as DataAppsApiFactory,
|
|
31
|
+
R as DataAppsApiFp,
|
|
32
|
+
f as DatabaseTypeEnum,
|
|
33
|
+
N as DatabasesApi,
|
|
34
|
+
z as DatabasesApiAxiosParamCreator,
|
|
35
|
+
I as DatabasesApiFactory,
|
|
36
|
+
K as DatabasesApiFp,
|
|
37
|
+
Q as EnvironmentsApi,
|
|
38
|
+
W as EnvironmentsApiAxiosParamCreator,
|
|
39
|
+
B as EnvironmentsApiFactory,
|
|
40
|
+
L as EnvironmentsApiFp,
|
|
38
41
|
O as ExecuteNotebookCellBypassFiltersEnum,
|
|
39
42
|
w as FilterTypeEnum,
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
Fa as
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
Oa as
|
|
93
|
-
wa as
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
43
|
+
q as FreshnessFallbackEnum,
|
|
44
|
+
G as GivenControlEnum,
|
|
45
|
+
j as LedgerEntryStrategyEnum,
|
|
46
|
+
H as LogMessageSeverityEnum,
|
|
47
|
+
J as ManifestEntryFreshnessFallbackEnum,
|
|
48
|
+
U as ManifestEntryOriginEnum,
|
|
49
|
+
V as ManifestEntryRefreshEnum,
|
|
50
|
+
X as MaterializationActionActionEnum,
|
|
51
|
+
Y as MaterializationStatus,
|
|
52
|
+
Z as MaterializationsApi,
|
|
53
|
+
_ as MaterializationsApiAxiosParamCreator,
|
|
54
|
+
$ as MaterializationsApiFactory,
|
|
55
|
+
aa as MaterializationsApiFp,
|
|
56
|
+
sa as ModelsApi,
|
|
57
|
+
ea as ModelsApiAxiosParamCreator,
|
|
58
|
+
na as ModelsApiFactory,
|
|
59
|
+
oa as ModelsApiFp,
|
|
60
|
+
ia as NotebookCellKindEnum,
|
|
61
|
+
ta as NotebookCellResultKindEnum,
|
|
62
|
+
ra as NotebookCellResultTypeEnum,
|
|
63
|
+
pa as NotebookCellTypeEnum,
|
|
64
|
+
ua as NotebooksApi,
|
|
65
|
+
ma as NotebooksApiAxiosParamCreator,
|
|
66
|
+
Aa as NotebooksApiFactory,
|
|
67
|
+
Ea as NotebooksApiFp,
|
|
68
|
+
ca as PackageEmbeddingIndexReasonEnum,
|
|
69
|
+
la as PackageEmbeddingIndexStageEnum,
|
|
70
|
+
da as PackageEmbeddingIndexStatusEnum,
|
|
71
|
+
Ca as PackageManifestBindingStatusEnum,
|
|
72
|
+
ya as PackageQueryableSourcesEnum,
|
|
73
|
+
ba as PackageScopeEnum,
|
|
74
|
+
Pa as PackageStorageServeBindingsInnerOriginEnum,
|
|
75
|
+
Fa as PackageWarningsInnerSeverityEnum,
|
|
76
|
+
ga as PackagesApi,
|
|
77
|
+
Sa as PackagesApiAxiosParamCreator,
|
|
78
|
+
ka as PackagesApiFactory,
|
|
79
|
+
ha as PackagesApiFp,
|
|
80
|
+
Ma as PersistSourcePlanOriginEnum,
|
|
81
|
+
xa as PostgresConnectionSslmodeEnum,
|
|
82
|
+
Da as PublisherApi,
|
|
83
|
+
Ta as PublisherApiAxiosParamCreator,
|
|
84
|
+
va as PublisherApiFactory,
|
|
85
|
+
Ra as PublisherApiFp,
|
|
86
|
+
fa as QueryClass,
|
|
87
|
+
Na as QueryResultQueryRowLimitSourceEnum,
|
|
88
|
+
za as QueryResultServedFromEnum,
|
|
89
|
+
Ia as RawNotebookFormatEnum,
|
|
90
|
+
Ka as Realization,
|
|
91
|
+
Qa as RefusedSourceReasonEnum,
|
|
92
|
+
Wa as RefusedSourceTierEnum,
|
|
93
|
+
Ba as RunContextTriggerEnum,
|
|
94
|
+
La as S3ConnectionProviderEnum,
|
|
95
|
+
Oa as ServerProvider,
|
|
96
|
+
wa as ServerStatusOperationalStateEnum,
|
|
97
|
+
qa as ThemeDefaultModeEnum,
|
|
98
|
+
Ga as WatchModeApi,
|
|
99
|
+
ja as WatchModeApiAxiosParamCreator,
|
|
100
|
+
Ha as WatchModeApiFactory,
|
|
101
|
+
Ja as WatchModeApiFp,
|
|
102
|
+
Ua as globalQueryClient,
|
|
103
|
+
Va as usePublisherTheme,
|
|
104
|
+
Xa as useServer
|
|
99
105
|
};
|
package/dist/client-entry.d.ts
CHANGED
|
@@ -3,3 +3,5 @@ export * from './client/configuration';
|
|
|
3
3
|
export { ServerProvider, useServer } from './components/ServerProvider';
|
|
4
4
|
export type { ApiClients, ServerContextValue, ServerProviderProps, } from './components/ServerProvider';
|
|
5
5
|
export { globalQueryClient } from './utils/queryClient';
|
|
6
|
+
export { usePublisherTheme } from './theme/ThemeContext';
|
|
7
|
+
export type { ResolvedTheme, Theme, ThemeMode } from './theme/types';
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
1
2
|
export interface ApiError extends Error {
|
|
2
3
|
status?: number;
|
|
3
4
|
data?: {
|
|
@@ -9,4 +10,14 @@ export interface ApiErrorDisplayProps {
|
|
|
9
10
|
error: ApiError;
|
|
10
11
|
context?: string;
|
|
11
12
|
}
|
|
13
|
+
/**
|
|
14
|
+
* An error as an MUI `Alert`: a one-line summary, and the server's own words
|
|
15
|
+
* under it in a monospace block that keeps their line breaks. Themed, so it
|
|
16
|
+
* reads in dark mode as well as light. Shared with a notebook cell that could
|
|
17
|
+
* not run, so every request failure in a document looks the same.
|
|
18
|
+
*/
|
|
19
|
+
export declare function ErrorDetailAlert({ summary, detail, }: {
|
|
20
|
+
summary?: ReactNode;
|
|
21
|
+
detail: ReactNode;
|
|
22
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
12
23
|
export declare function ApiErrorDisplay({ error, context }: ApiErrorDisplayProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -9,16 +9,16 @@ import * as React from "react";
|
|
|
9
9
|
* with the same padding every time — a text Cancel and a filled confirm, the
|
|
10
10
|
* two roles `buttons.tsx` names.
|
|
11
11
|
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
* but a fourth exception is a reason to widen it, not to hand-roll a fourth.
|
|
12
|
+
* `ModelExplorerDialog` stays off it deliberately: it is `fullScreen`. The
|
|
13
|
+
* title takes a node as well as a string, so a dialog that titles itself with
|
|
14
|
+
* more than text (`RowsDialog`, `MaterializationDetailDialog`) can move onto
|
|
15
|
+
* this rather than hand-roll its own close button and type.
|
|
17
16
|
*/
|
|
18
17
|
export declare function AppDialog({ open, onClose, title, description, maxWidth, showClose, actions, children, }: {
|
|
19
18
|
open: boolean;
|
|
20
19
|
onClose: () => void;
|
|
21
|
-
|
|
20
|
+
/** The heading. A string in the common case; a node when it needs more. */
|
|
21
|
+
title: React.ReactNode;
|
|
22
22
|
/** What the dialog is for, in a line. The page's description, in a box. */
|
|
23
23
|
description?: React.ReactNode;
|
|
24
24
|
maxWidth?: "xs" | "sm" | "md" | "lg" | false;
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { DrillNavigation } from '../drill';
|
|
2
2
|
import { DashboardEventHandler } from './telemetry';
|
|
3
|
+
import { TileChrome } from './TileCard';
|
|
3
4
|
export { DEFAULT_COLUMNS, tileGridColumn } from './DashboardGrid';
|
|
5
|
+
export { DashboardProse } from './DashboardView';
|
|
4
6
|
export interface DashboardProps {
|
|
5
7
|
/** `publisher://environments/{env}/packages/{pkg}`, optionally `?versionId=`. */
|
|
6
8
|
resourceUri: string;
|
|
@@ -41,6 +43,11 @@ export interface DashboardProps {
|
|
|
41
43
|
maxResultSize?: number;
|
|
42
44
|
/** The rows shown and tiles explored, for the host to log or count. */
|
|
43
45
|
onEvent?: DashboardEventHandler;
|
|
46
|
+
/**
|
|
47
|
+
* `card` (default) draws each tile as a panel; `none` draws them bare, a
|
|
48
|
+
* document that reads top to bottom.
|
|
49
|
+
*/
|
|
50
|
+
chrome?: TileChrome;
|
|
44
51
|
}
|
|
45
52
|
/**
|
|
46
53
|
* A Malloyyo-style dashboard: a control row over one or more query results,
|
|
@@ -51,19 +58,5 @@ export interface DashboardProps {
|
|
|
51
58
|
* Console and an external React app render the same component and differ only
|
|
52
59
|
* in what they do with `onNavigate` and `onGivensChange`.
|
|
53
60
|
*/
|
|
54
|
-
export declare function Dashboard({ resourceUri, dashboard, givens, onGivensChange, onNavigate, height, maxResultSize, onEvent, }: DashboardProps): import("react/jsx-runtime").JSX.Element;
|
|
55
|
-
/**
|
|
56
|
-
* The prose header itself, over the two fields it actually needs.
|
|
57
|
-
*
|
|
58
|
-
* Separate from {@link DashboardHeader} so the BUILDER can render the same
|
|
59
|
-
* header over a `DashboardDocument` — which carries `title` and `description`
|
|
60
|
-
* but is not a manifest. Same argument as {@link tileGridColumn}: what the
|
|
61
|
-
* builder shows a author is the thing a reader will see, and one component is
|
|
62
|
-
* what stops the two drifting. A builder that restated this markdown block
|
|
63
|
-
* would be one edit away from showing a different header than it writes.
|
|
64
|
-
*/
|
|
65
|
-
export declare function DashboardProse({ title, description, }: {
|
|
66
|
-
title: string;
|
|
67
|
-
description?: string;
|
|
68
|
-
}): import("react/jsx-runtime").JSX.Element;
|
|
61
|
+
export declare function Dashboard({ resourceUri, dashboard, givens, onGivensChange, onNavigate, height, maxResultSize, onEvent, chrome, }: DashboardProps): import("react/jsx-runtime").JSX.Element;
|
|
69
62
|
export default Dashboard;
|
|
@@ -1,16 +1,33 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
/** Grid width when the dashboard declares no `# dashboard { columns=N }`. */
|
|
3
3
|
export declare const DEFAULT_COLUMNS = 2;
|
|
4
|
+
/** The widest grid the builder offers; the server lints wider ones and the reader still renders them. */
|
|
5
|
+
export declare const MAX_COLUMNS = 24;
|
|
6
|
+
/** A tile's width after an arrow nudge, held to the grid and to what the builder offers. */
|
|
7
|
+
export declare const nudgedSpan: (current: number, delta: 1 | -1, columns: number) => number;
|
|
4
8
|
/**
|
|
5
9
|
* The gutter between tiles, in px.
|
|
6
10
|
*
|
|
7
|
-
* A number rather than a `gap: 2` spacing unit because
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
* `getBoundingClientRect`. Exported so the value the grid paints and the value
|
|
11
|
-
* the drag solves with cannot drift apart.
|
|
11
|
+
* A number rather than a `gap: 2` spacing unit because a tile's default span is
|
|
12
|
+
* solved for the track width in px. Exported so the builder's column guides sit
|
|
13
|
+
* on the same gutters the grid paints.
|
|
12
14
|
*/
|
|
13
15
|
export declare const GRID_GAP_PX = 16;
|
|
16
|
+
/**
|
|
17
|
+
* The space between a notebook's tiles, which stack in one column with no card
|
|
18
|
+
* around them: wider than a dashboard's gap so the reading flow breathes, and
|
|
19
|
+
* so the builder's selection ring, drawn {@link BARE_RING_OFFSET_PX} clear of
|
|
20
|
+
* a bare tile, never meets the next tile's.
|
|
21
|
+
*/
|
|
22
|
+
export declare const NOTEBOOK_GAP_PX = 40;
|
|
23
|
+
/** How far a bare (uncarded) tile's selection ring sits from its content. */
|
|
24
|
+
export declare const BARE_RING_OFFSET_PX = 12;
|
|
25
|
+
/**
|
|
26
|
+
* The space above and below a notebook's description, in both modes: a bare
|
|
27
|
+
* description's ring in the builder is {@link BARE_RING_OFFSET_PX} clear of
|
|
28
|
+
* its text, and needs the room to stay clear of the title and the filters.
|
|
29
|
+
*/
|
|
30
|
+
export declare const BARE_DESCRIPTION_MARGIN_PX: number;
|
|
14
31
|
/**
|
|
15
32
|
* The `grid-column` one tile occupies: its `# colspan`, and a `# break` forcing
|
|
16
33
|
* it to start a fresh row.
|
|
@@ -24,6 +41,14 @@ export declare function tileGridColumn(tile: {
|
|
|
24
41
|
colspan?: number;
|
|
25
42
|
break?: boolean;
|
|
26
43
|
}, columns: number): string;
|
|
44
|
+
/**
|
|
45
|
+
* Columns a tile with no `# colspan` spans so it is at least `minTilePx` wide.
|
|
46
|
+
*
|
|
47
|
+
* In a 12 or 16 column grid a one-column tile is a sliver a few dozen px wide.
|
|
48
|
+
* Only tiles that never asked for a width are widened, so an explicit
|
|
49
|
+
* `colspan=1` stays the author's call. An unmeasured width changes nothing.
|
|
50
|
+
*/
|
|
51
|
+
export declare function defaultTileSpan(columns: number, containerPx: number, minTilePx: number): number;
|
|
27
52
|
/** The layout a tile carries, whatever else its own shape holds. */
|
|
28
53
|
export interface GridTile {
|
|
29
54
|
colspan?: number;
|
|
@@ -52,7 +77,7 @@ export interface GridTile {
|
|
|
52
77
|
* builder wraps one in its selection outline. Anything this component rendered
|
|
53
78
|
* on their behalf would be a third opinion about what a tile looks like.
|
|
54
79
|
*/
|
|
55
|
-
export declare function DashboardGrid<T extends GridTile>({ tiles, columns, keyOf, renderTile, }: {
|
|
80
|
+
export declare function DashboardGrid<T extends GridTile>({ tiles, columns, keyOf, renderTile, minTilePx, rowGapPx, }: {
|
|
56
81
|
tiles: readonly T[];
|
|
57
82
|
/** Track count — `# dashboard { columns=N }`, or {@link DEFAULT_COLUMNS}. */
|
|
58
83
|
columns: number;
|
|
@@ -64,4 +89,11 @@ export declare function DashboardGrid<T extends GridTile>({ tiles, columns, keyO
|
|
|
64
89
|
*/
|
|
65
90
|
keyOf: (tile: T, index: number) => string;
|
|
66
91
|
renderTile: (tile: T, index: number) => ReactNode;
|
|
92
|
+
/**
|
|
93
|
+
* Floor on the width of a tile that sets no `colspan`. Off by default: the
|
|
94
|
+
* builder assumes an unset colspan is one column.
|
|
95
|
+
*/
|
|
96
|
+
minTilePx?: number;
|
|
97
|
+
/** The space between rows; a notebook's is {@link NOTEBOOK_GAP_PX}. */
|
|
98
|
+
rowGapPx?: number;
|
|
67
99
|
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { GivenValue } from '../../hooks/givenValue';
|
|
1
|
+
import { GivenValue, HostGivenValue } from '../../hooks/givenValue';
|
|
2
2
|
import { DrillBinding } from '../drill';
|
|
3
|
+
import { TileChrome, TileHeadingSlots } from './TileCard';
|
|
3
4
|
export interface DashboardTileProps {
|
|
4
5
|
environmentName: string;
|
|
5
6
|
packageName: string;
|
|
@@ -10,10 +11,14 @@ export interface DashboardTileProps {
|
|
|
10
11
|
queryName?: string;
|
|
11
12
|
/** A run expression (a composite tile). */
|
|
12
13
|
tile?: string;
|
|
14
|
+
/** Annotation lines placed above the tile's `run:`, which stack on the view's own. */
|
|
15
|
+
annotation?: string;
|
|
13
16
|
/** `# label` on the view the tile names, when it has one. */
|
|
14
17
|
label?: string;
|
|
15
18
|
/** `# subtitle` on it: a second line under the heading. */
|
|
16
19
|
subtitle?: string;
|
|
20
|
+
/** The heading's text as nodes, which replace `label` and `subtitle` where a surface edits them in place. */
|
|
21
|
+
heading?: TileHeadingSlots;
|
|
17
22
|
/** `# borderless` on it: no card around the result. */
|
|
18
23
|
borderless?: boolean;
|
|
19
24
|
/**
|
|
@@ -23,6 +28,8 @@ export interface DashboardTileProps {
|
|
|
23
28
|
* does.
|
|
24
29
|
*/
|
|
25
30
|
givens: Map<string, GivenValue>;
|
|
31
|
+
/** Givens the host sets with no control, which may be lists; narrowed by `givenNames` like `givens`. */
|
|
32
|
+
hostGivens?: Readonly<Record<string, HostGivenValue>>;
|
|
26
33
|
/** Declared type per given name, which decides how a value is encoded. */
|
|
27
34
|
declaredTypes: ReadonlyMap<string, string | undefined>;
|
|
28
35
|
/**
|
|
@@ -40,6 +47,18 @@ export interface DashboardTileProps {
|
|
|
40
47
|
* the heading, on hover; absent, the heading has no button.
|
|
41
48
|
*/
|
|
42
49
|
onExplore?: () => void;
|
|
50
|
+
/** `none` draws the result bare, its label a quiet caption above it. */
|
|
51
|
+
chrome?: TileChrome;
|
|
52
|
+
/** Labels of the page's filters this tile ignores, shown as a warning chip. */
|
|
53
|
+
ignoredFilters?: readonly string[];
|
|
54
|
+
/**
|
|
55
|
+
* Text-source mode: the document's definitions, sent ahead of the tile's
|
|
56
|
+
* `run:` so the tile runs as the viewer's own text. Absent, the tile runs
|
|
57
|
+
* the model's view by expression as it always has.
|
|
58
|
+
*/
|
|
59
|
+
preamble?: string;
|
|
60
|
+
/** The server marked this tile unreadable for the viewer: nothing is run. */
|
|
61
|
+
restricted?: boolean;
|
|
43
62
|
}
|
|
44
63
|
/**
|
|
45
64
|
* A composite tile's heading when the view it names carries no `# label`: the
|
|
@@ -59,4 +78,4 @@ export declare function tileTitle(tile: string): string;
|
|
|
59
78
|
* tile: the broken one shows its error in place and the rest of the grid still
|
|
60
79
|
* renders, rather than one failure blanking the page.
|
|
61
80
|
*/
|
|
62
|
-
export declare function DashboardTile({ environmentName, packageName, versionId, modelPath, queryName, tile, label, subtitle, borderless, givens, declaredTypes, givenNames, height, maxResultSize, drill, onExplore, }: DashboardTileProps): import("react/jsx-runtime").JSX.Element;
|
|
81
|
+
export declare function DashboardTile({ environmentName, packageName, versionId, modelPath, queryName, tile, annotation, label, subtitle, heading, borderless, givens, hostGivens, declaredTypes, givenNames, height, maxResultSize, drill, onExplore, chrome, ignoredFilters, preamble, restricted, }: DashboardTileProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { DashboardManifest } from '../../client';
|
|
2
|
+
import { HostGivenValue } from '../../hooks/givenValue';
|
|
3
|
+
import { DrillNavigation } from '../drill';
|
|
4
|
+
import { GivensLayout } from '../given';
|
|
5
|
+
import { DashboardEventHandler } from './telemetry';
|
|
6
|
+
import { TileChrome } from './TileCard';
|
|
7
|
+
/**
|
|
8
|
+
* The sticky control row's stacking level: above anything a tile raises
|
|
9
|
+
* inside itself as it scrolls under (a result's floating buttons sit at 1–2),
|
|
10
|
+
* and below MUI's app bar, popovers and dialogs. Shared so the builder's
|
|
11
|
+
* control row sits at the same level as the reader's.
|
|
12
|
+
*/
|
|
13
|
+
export declare const STICKY_CONTROLS_Z = 4;
|
|
14
|
+
export interface DashboardViewProps {
|
|
15
|
+
/** The dashboard, or the tile layout a layout notebook carries. */
|
|
16
|
+
manifest: DashboardManifest;
|
|
17
|
+
environmentName: string;
|
|
18
|
+
packageName: string;
|
|
19
|
+
versionId?: string;
|
|
20
|
+
/** The slug or path the manifest was fetched under, which keys its control edits. */
|
|
21
|
+
documentName: string;
|
|
22
|
+
/**
|
|
23
|
+
* The host's values, typically its URL query parameters. A string drives a
|
|
24
|
+
* control; a value no control declares is sent as given to the tiles that
|
|
25
|
+
* read it, and only there may it be a list.
|
|
26
|
+
*/
|
|
27
|
+
givens?: Record<string, HostGivenValue>;
|
|
28
|
+
onGivensChange?: (givens: Record<string, string>, managed: readonly string[]) => void;
|
|
29
|
+
onNavigate?: (target: DrillNavigation, event?: MouseEvent) => void;
|
|
30
|
+
height?: number;
|
|
31
|
+
maxResultSize?: number;
|
|
32
|
+
onEvent?: DashboardEventHandler;
|
|
33
|
+
/** `none` renders tiles as a document, with no cards or title block. */
|
|
34
|
+
chrome?: TileChrome;
|
|
35
|
+
/**
|
|
36
|
+
* How the control row is drawn: `bar` for a dashboard, `panel` for a
|
|
37
|
+
* notebook, so a layout notebook's controls match a cell notebook's.
|
|
38
|
+
*/
|
|
39
|
+
controlsLayout?: GivensLayout;
|
|
40
|
+
/**
|
|
41
|
+
* Text-source mode: the document's definitions (see `documentPreamble`),
|
|
42
|
+
* sent ahead of each tile's `run:` so every query runs as the viewer's own
|
|
43
|
+
* text. Rows, which reopens a tile by name, is off in this mode.
|
|
44
|
+
*/
|
|
45
|
+
preamble?: string;
|
|
46
|
+
/** Text-source mode: the model the text runs on top of, in place of `manifest.path`. */
|
|
47
|
+
runModelPath?: string;
|
|
48
|
+
/** Givens the host sets itself: no control is shown for them. */
|
|
49
|
+
hiddenGivens?: readonly string[];
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* A loaded dashboard manifest, drawn: the control row and the tile grid.
|
|
53
|
+
*
|
|
54
|
+
* Split from the manifest fetch so a notebook written as a tile layout, whose
|
|
55
|
+
* manifest arrives inside the notebook response, renders through the same code.
|
|
56
|
+
*/
|
|
57
|
+
export declare function DashboardView({ manifest, environmentName, packageName, versionId, documentName, givens, onGivensChange, onNavigate, height, maxResultSize, onEvent, chrome, controlsLayout, preamble, runModelPath, hiddenGivens, }: DashboardViewProps): import("react/jsx-runtime").JSX.Element;
|
|
58
|
+
/**
|
|
59
|
+
* The prose header over just the two fields it needs, so the BUILDER can draw
|
|
60
|
+
* the same header over a `DashboardDocument`, which is not a manifest.
|
|
61
|
+
*
|
|
62
|
+
* The description is drawn as a text tile is, in the document's own tile
|
|
63
|
+
* chrome: the same box and the same type as the markdown between the tiles,
|
|
64
|
+
* so the page's prose reads as one kind of thing wherever it sits.
|
|
65
|
+
*/
|
|
66
|
+
export declare function DashboardProse({ title, description, chrome, }: {
|
|
67
|
+
title: string;
|
|
68
|
+
description?: string;
|
|
69
|
+
/** The chrome the document's tiles take, which the description matches. */
|
|
70
|
+
chrome?: TileChrome;
|
|
71
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
import { SxProps, Theme } from '@mui/material';
|
|
2
|
-
import { ReactNode } from 'react';
|
|
2
|
+
import { ReactNode, Ref } from 'react';
|
|
3
|
+
/** `card` is a dashboard tile's panel; `none` is a notebook's bare flow. */
|
|
4
|
+
export type TileChrome = "card" | "none";
|
|
5
|
+
/**
|
|
6
|
+
* The least a carded tile is drawn at, by kind: a query tile holds a spinner
|
|
7
|
+
* and then a result, so it keeps room for one; a text tile holds a line or two
|
|
8
|
+
* of prose and is no taller than its text needs, past a floor that keeps a
|
|
9
|
+
* one-word tile from reading as a sliver. A bare (`none`) tile has no floor.
|
|
10
|
+
*/
|
|
11
|
+
export declare const TILE_MIN_HEIGHT: {
|
|
12
|
+
readonly query: 120;
|
|
13
|
+
readonly text: 72;
|
|
14
|
+
};
|
|
3
15
|
/**
|
|
4
16
|
* The card a dashboard tile sits in, and nothing else — so the builder, which
|
|
5
17
|
* draws a stand-in tile when it has no server to run one, draws the same card
|
|
@@ -28,19 +40,32 @@ import { ReactNode } from 'react';
|
|
|
28
40
|
* narrow below the chart it holds so the renderer redraws the chart to fit.
|
|
29
41
|
* See the `minWidth: 0` note in `DashboardGrid` for the rest of that chain.
|
|
30
42
|
*/
|
|
31
|
-
export declare function TileCard({ borderless, sx, children, }: {
|
|
43
|
+
export declare function TileCard({ borderless, chrome, kind, sx, cardRef, children, }: {
|
|
32
44
|
borderless?: boolean;
|
|
45
|
+
/** What the tile holds, which sets its {@link TILE_MIN_HEIGHT}. */
|
|
46
|
+
kind?: keyof typeof TILE_MIN_HEIGHT;
|
|
47
|
+
/** `none` drops the card entirely, for a document that reads top to bottom. */
|
|
48
|
+
chrome?: TileChrome;
|
|
33
49
|
sx?: SxProps<Theme>;
|
|
50
|
+
/** The card's element, for a caller that watches where it is on the page. */
|
|
51
|
+
cardRef?: Ref<HTMLDivElement>;
|
|
34
52
|
children: ReactNode;
|
|
35
53
|
}): import("react/jsx-runtime").JSX.Element;
|
|
54
|
+
/** The heading's text as nodes, for a surface that makes it editable in place. */
|
|
55
|
+
export interface TileHeadingSlots {
|
|
56
|
+
title: ReactNode;
|
|
57
|
+
subtitle: ReactNode;
|
|
58
|
+
}
|
|
36
59
|
/**
|
|
37
60
|
* A tile's heading: its `# label`, and its `# subtitle` under it. In the
|
|
38
61
|
* instance theme's title colour and face, so a tile is titled the same
|
|
39
62
|
* whichever surface draws it.
|
|
40
63
|
*/
|
|
41
|
-
export declare function TileHeading({ title, subtitle, tooltip, action, }: {
|
|
42
|
-
|
|
43
|
-
|
|
64
|
+
export declare function TileHeading({ title, subtitle, tooltip, action, quiet, }: {
|
|
65
|
+
/** A small caption instead of a heading, for a tile with no card around it. */
|
|
66
|
+
quiet?: boolean;
|
|
67
|
+
title: ReactNode;
|
|
68
|
+
subtitle?: ReactNode;
|
|
44
69
|
/** What actually ran, kept reachable without being the heading. */
|
|
45
70
|
tooltip?: string;
|
|
46
71
|
/** A control on the heading's row, hard right — the tile's Explore button. */
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Given } from '../../client';
|
|
2
|
+
/**
|
|
3
|
+
* Display labels of the controls on the page that a tile does NOT read.
|
|
4
|
+
*
|
|
5
|
+
* `givenNames` undefined means discovery could not resolve the tile, so the
|
|
6
|
+
* whole control row applies, as it does when the tile runs: nothing to warn of.
|
|
7
|
+
*/
|
|
8
|
+
export declare function tileIgnoredFilterLabels(givenNames: readonly string[] | undefined, declared: readonly Given[]): string[];
|
|
9
|
+
/** A small amber chip naming the page's filters a tile ignores; nothing when it reads them all. */
|
|
10
|
+
export declare function TileFilterTag({ ignored }: {
|
|
11
|
+
ignored: readonly string[];
|
|
12
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The result with every `# image`, `# link` and HTML-bearing `# label` removed
|
|
3
|
+
* from its annotations; the input string untouched when there is none or it is
|
|
4
|
+
* not JSON, for the renderer to report.
|
|
5
|
+
*/
|
|
6
|
+
export declare function dropValueUrlTags(result: string): string;
|