@malloy-publisher/sdk 0.8.0 → 0.8.2

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.
Files changed (40) hide show
  1. package/dist/{DocumentStorage-D7yF4_T3.cjs.js → DocumentStorage-B0_YgSzt.cjs.js} +32 -32
  2. package/dist/{DocumentStorage-BypSIWDg.es.js → DocumentStorage-BZqn0x5r.es.js} +3826 -3741
  3. package/dist/{RenderedResult-ChkvK7b2.cjs.js → RenderedResult-Bu25oAAr.cjs.js} +1 -1
  4. package/dist/{RenderedResult-CYyhQekT.es.js → RenderedResult-DKOl0FQ8.es.js} +2 -2
  5. package/dist/{ServerProvider-AsUiy22k.es.js → ServerProvider-CfUFleYe.es.js} +24 -24
  6. package/dist/builder/index.cjs.js +31 -31
  7. package/dist/builder/index.es.js +1167 -1142
  8. package/dist/client/api.d.ts +36 -30
  9. package/dist/client/index.es.js +1 -1
  10. package/dist/components/Dashboard/ExploreDialog.d.ts +3 -1
  11. package/dist/components/DashboardBuilder/catalog.d.ts +18 -0
  12. package/dist/components/Model/Model.d.ts +10 -3
  13. package/dist/components/Model/ModelExplorer.d.ts +21 -1
  14. package/dist/components/Model/ModelExplorerDialog.d.ts +4 -1
  15. package/dist/components/Model/SourcesExplorer.d.ts +8 -1
  16. package/dist/components/Model/index.d.ts +1 -0
  17. package/dist/components/Model/runGate.d.ts +19 -0
  18. package/dist/components/Notebook/NotebookCell.d.ts +10 -1
  19. package/dist/index.cjs.js +13 -13
  20. package/dist/index.es.js +3754 -3732
  21. package/package.json +1 -1
  22. package/src/components/Dashboard/Dashboard.spec.tsx +58 -2
  23. package/src/components/Dashboard/Dashboard.tsx +8 -1
  24. package/src/components/Dashboard/ExploreDialog.tsx +5 -0
  25. package/src/components/DashboardBuilder/DashboardEditor.resourceUri.spec.tsx +6 -1
  26. package/src/components/DashboardBuilder/DashboardEditor.spec.tsx +60 -30
  27. package/src/components/DashboardBuilder/DashboardEditor.tsx +35 -16
  28. package/src/components/DashboardBuilder/catalog.spec.ts +44 -0
  29. package/src/components/DashboardBuilder/catalog.ts +36 -0
  30. package/src/components/Model/Model.tsx +28 -1
  31. package/src/components/Model/ModelExplorer.spec.tsx +404 -0
  32. package/src/components/Model/ModelExplorer.tsx +65 -2
  33. package/src/components/Model/ModelExplorerDialog.tsx +12 -0
  34. package/src/components/Model/SourcesExplorer.tsx +70 -15
  35. package/src/components/Model/index.ts +1 -0
  36. package/src/components/Model/runGate.spec.ts +102 -0
  37. package/src/components/Model/runGate.ts +67 -0
  38. package/src/components/Notebook/Notebook.spec.tsx +67 -3
  39. package/src/components/Notebook/Notebook.tsx +12 -2
  40. package/src/components/Notebook/NotebookCell.tsx +26 -7
@@ -567,7 +567,7 @@ export interface CompiledModel {
567
567
  */
568
568
  'givens'?: Array<Given>;
569
569
  /**
570
- * The model file\'s Malloy text, verbatim, so a client can show the code beside the compiled view of the same file without a second, differently-shaped fetch. Named `sourceText`, not `source`, because `sources` on this same object are the model\'s Malloy sources. Optional twice over: absent from servers that predate it, and omitted (with a server-side warning) when the file cannot be read, so a compiled model is never withheld for want of its text.
570
+ * The model file\'s Malloy text, verbatim, so a client can show the code beside the compiled view of the same file without a second, differently-shaped fetch. Named `sourceText`, not `source`, because `sources` on this same object are the model\'s Malloy sources. Optional: absent from servers that predate it; omitted (with a server-side warning) when the file cannot be read, so a compiled model is never withheld for want of its text; and omitted when the file text names a source it does not publish, on a package with a surface. A dashboard\'s text is always returned.
571
571
  * @type {string}
572
572
  * @memberof CompiledModel
573
573
  */
@@ -1982,6 +1982,12 @@ export interface ModelError {
1982
1982
  * @memberof ModelError
1983
1983
  */
1984
1984
  'reason'?: string;
1985
+ /**
1986
+ * Present on the 400 answering ad-hoc query text that does not compile: the compiler\'s problems, in the shape `/compile` returns. Each `at.range` is located in the submitted `query` text, with 0-based lines and characters; `at.url` is omitted, since the text has no document of its own. A problem produced by something the server added to the text (an injected source filter) carries no location.
1987
+ * @type {Array<CompileProblem>}
1988
+ * @memberof ModelError
1989
+ */
1990
+ 'problems'?: Array<CompileProblem>;
1985
1991
  }
1986
1992
  /**
1987
1993
  * The text to write into a dashboard file
@@ -2157,7 +2163,7 @@ export interface NotebookCell {
2157
2163
  */
2158
2164
  'newSources'?: Array<string>;
2159
2165
  /**
2160
- * JSON string containing QueryInfo object for the query in this cell (if the cell contains a query)
2166
+ * JSON string containing QueryInfo object for the query in this cell (if the cell contains a query). On a package with a surface, left out for a cell whose query reads a source the notebook may not read.
2161
2167
  * @type {string}
2162
2168
  * @memberof NotebookCell
2163
2169
  */
@@ -2241,7 +2247,7 @@ export interface Package {
2241
2247
  */
2242
2248
  'scope'?: PackageScopeEnum;
2243
2249
  /**
2244
- * The package\'s discovery surface and query boundary: model file paths relative to the package root. Only these models are listed via `listModels()`, and within-file discovery is filtered to each model\'s `export {}` closure. Every other .malloy file still compiles for import/join resolution but is hidden. Notebooks are always listed regardless of this field. DEPRECATED for a one-file surface, still honored: a root `index.malloy` is the surface when this key is absent, and gives the same listing and the same boundary with no manifest field. A surface spanning several files is what the convention cannot express, so that use stays supported, with no replacement and no deprecation warning at load. This value MAY have been derived by the server from a root `index.malloy` rather than written by the package author, and the response does not distinguish the two — deliberately, because nothing downstream treats them differently. An explicit key always wins over the convention, and an explicit empty array means \"do not curate\" and suppresses it. A package is uncurated only when it has neither this key nor a root `index.malloy`.
2250
+ * The package\'s discovery surface and query boundary: model file paths relative to the package root. Only these models are listed via `listModels()`, and the surface is the union of their `export {}` closures. Every other .malloy file still compiles for import/join resolution but is hidden. Notebooks and dashboards are always listed regardless of this field, and a dashboard entry needs no listing: a tagged dashboard listed here reads the surface and adds nothing to it. An untagged file under `dashboards/` that is listed is an ordinary surface file. DEPRECATED, still honored. Every non-empty value gets a load warning naming the replacement: a root `index.malloy` that imports the listed files and exports what they publish. `[]` is deprecated too: beside an `index.malloy` it stops that file from limiting what the package publishes (the fix is to rename `index.malloy` and delete this key), and without one it does nothing. A value that is not a list of strings refuses the package load (424). This value MAY have been derived by the server from a root `index.malloy` rather than written by the package author, and the response does not distinguish the two — deliberately, because nothing downstream treats them differently. An explicit key always wins over `index.malloy`. A package is uncurated only when it has neither this key nor a root `index.malloy`.
2245
2251
  * @type {Array<string>}
2246
2252
  * @memberof Package
2247
2253
  */
@@ -2253,13 +2259,13 @@ export interface Package {
2253
2259
  */
2254
2260
  'exploresWarnings'?: Array<string>;
2255
2261
  /**
2256
- * Non-fatal findings collected when the package loaded, none of which stop the model compiling or the package loading. Render-tag findings: a render annotation (e.g. `# big_value`, `# currency` or `# colspan`) the renderer cannot apply as written, either malformed for the field it sits on, so it renders as \"[object Object]\" or an inline error at query time, or inert where it sits and silently ignored. Materialization findings: a `storage=` source not served from storage, a `#@ persist` source that was not recognized as materializable, a `#@ persist` REFUSED by the compile-time eligibility gate (one entry per `BuildPlan.refusedSources` member, carrying that gate\'s own message), a persist-target collision, and materialization-config problems that degrade attribution. A refusal is the one materialization finding the build plan cannot also be read for: a refused `storage`/`colocated` source is ABSENT from `BuildPlan.sources`, so nothing there records that the annotation was written at all. Discovery findings: a model on the package\'s surface whose export closure surfaces no sources or named queries, so it lists as empty and renders a blank page; a surface whose every model failed to compile, so every model in the package answers 404 by name; and, on the reload that caused it, a package that had a surface and now has none, so every source that surface withheld is listed and queryable by name again. Dashboard findings: a `dashboards/` file whose `# artifact` tag does not parse or does not describe a dashboard, a tile or suggest query that does not resolve, a `# drill` naming a destination that is not a dashboard, and a dashboard held back from the listing because its entry file is not on the package\'s surface. Two dashboard findings are about Publisher rather than about the package: one when a file carrying an artifact tag could not be read and so is not served at all, and one when the lint stops early, in which case the list must be read as incomplete rather than as a clean package. Server-computed and read-only: ignored on create/update requests and only returned in responses. Present only when there are such findings. **Almost every `#@ preaggregate` that cannot be honored REJECTS A PUBLISH — a 400 at publish or PATCH — and fails a load thereafter.** The two access-modifier violations are the exception: they warn at BOTH gates and appear in this array. See the split below. Rejected are a `#@ preaggregate` anywhere but on a measure; a `#@ preaggregate` with no `grain=`; a grain naming anything but a dimension the base source itself declares, which rules out an inline time truncation such as `order_time.day`; a measure that cannot be correctly re-aggregated to a coarser grain, whether because its aggregate has no exact merge function (`count(distinct)`, `median`, percentiles, `mode`, and `avg` until it is decomposed) or because it carries its own filter, an ungrouping (`all`, `exclude`), or a required group-by; a measure whose expression cannot be POSITIVELY classified as re-aggregatable, which fails closed rather than being guessed at; a base source with a FAN-OUT join (`join_many` or `join_cross`), which can multiply rows, while a `join_one` is permitted and a measure aggregating through one is served normally; a base source that already fails persist eligibility (unbound parameters, `given` references, authorize gates); `sharing=` or `schedule=` at the resource level; and a synthesized rollup name that collides with an existing model object. WARNED rather than rejected, at publish and at load alike, is a `#@ preaggregate` on a measure the source does not publicly expose, or a grain naming a hidden dimension — a rollup STORES its grain and each measure\'s partial, and the stored table is served under the base\'s name without the source\'s field visibility applying to it. Each names the measure and the fix. Refusing rather than silently dropping the measure is the deliberate choice. A dropped measure is not served from the rollup at ANY grain, so the declaration would have no effect whatsoever while still reading as applied — and the build cost of the rollup would still be paid. An author who writes `#@ preaggregate` on a measure that cannot be rolled up has made a modeling mistake, and an error is where a mistake belongs. The same verdict is enforced at LOAD for every violation EXCEPT the two access-modifier ones, so a package whose declarations stopped being honorable does not load at all: it is absent from its environment and reported in `ServerStatus.loadErrors`. Worth knowing because whether a measure can be re-aggregated is derived from the compiled model, so a Malloy version change can in principle reclassify a measure that published cleanly long before. That surfaces as a package that stops loading rather than as a package quietly serving without its rollups — louder, and deliberately so, since the alternative is paying for rollups that answer nothing. The two access-modifier violations are the deliberate exception, and for two reasons rather than a lesser severity. They WARN at publish and at load alike and appear in this array. First, a package annotating a hidden field published and loaded before this rule existed — refusing it would stop an already-published package from doing either because a new validation was added, which is not a thing a server upgrade may do. Second, the refusal was unfollowable: an annotation INHERITED onto a source that then hides the measure raises it, while that source produces no plan at all and nothing is exposed, so the advice to make the field public or drop the annotation asks an author to give up either the hiding or the rollup over a model that was already safe. Warning is safe here and would not be for the others: what keeps a hidden field out of a rollup is that the planner refuses to plan one at all, so no table is built and nothing can be served whether or not anyone reads the message. For the other violations the refusal IS the enforcement, which is why they stay fatal.
2262
+ * Non-fatal findings collected when the package loaded, none of which stop the model compiling or the package loading. Render-tag findings: a render annotation (e.g. `# big_value`, `# currency` or `# colspan`) the renderer cannot apply as written, either malformed for the field it sits on, so it renders as \"[object Object]\" or an inline error at query time, or inert where it sits and silently ignored. Materialization findings: a `storage=` source not served from storage, a `#@ persist` source that was not recognized as materializable, a `#@ persist` REFUSED by the compile-time eligibility gate (one entry per `BuildPlan.refusedSources` member, carrying that gate\'s own message), a persist-target collision, and materialization-config problems that degrade attribution. A refusal is the one materialization finding the build plan cannot also be read for: a refused `storage`/`colocated` source is ABSENT from `BuildPlan.sources`, so nothing there records that the annotation was written at all. Discovery findings: a model on the package\'s surface whose export closure surfaces no sources or named queries, so it lists as empty and renders a blank page; a surface whose every model failed to compile, so every model in the package answers 404 by name; and, on the reload that caused it, a package that had a surface and now has none, so every source that surface hid is listed and queryable by name again. Manifest findings: each deprecated use of `explores` or of `queryableSources: \"declared\"`, and a root file such as `Index.malloy` that differs from `index.malloy` only in case and so is ignored. A root `index.malloy` with no manifest keys gets no warning. Dashboard findings: a `dashboards/` file whose `# artifact` tag does not parse or does not describe a dashboard, a tile or suggest query that does not resolve, a `# drill` naming a destination that is not a dashboard, and a tile, single query or filter suggest that reads a source the surface does not export, so it won\'t load. Two dashboard findings are about Publisher rather than about the package: one when a file carrying an artifact tag could not be read and so is not served at all, and one when the lint stops early, in which case the list must be read as incomplete rather than as a clean package. Server-computed and read-only: ignored on create/update requests and only returned in responses. Present only when there are such findings. **Almost every `#@ preaggregate` that cannot be honored REJECTS A PUBLISH — a 400 at publish or PATCH — and fails a load thereafter.** The two access-modifier violations are the exception: they warn at BOTH gates and appear in this array. See the split below. Rejected are a `#@ preaggregate` anywhere but on a measure; a `#@ preaggregate` with no `grain=`; a grain naming anything but a dimension the base source itself declares, which rules out an inline time truncation such as `order_time.day`; a measure that cannot be correctly re-aggregated to a coarser grain, whether because its aggregate has no exact merge function (`count(distinct)`, `median`, percentiles, `mode`, and `avg` until it is decomposed) or because it carries its own filter, an ungrouping (`all`, `exclude`), or a required group-by; a measure whose expression cannot be POSITIVELY classified as re-aggregatable, which fails closed rather than being guessed at; a base source with a FAN-OUT join (`join_many` or `join_cross`), which can multiply rows, while a `join_one` is permitted and a measure aggregating through one is served normally; a base source that already fails persist eligibility (unbound parameters, `given` references, authorize gates); `sharing=` or `schedule=` at the resource level; and a synthesized rollup name that collides with an existing model object. WARNED rather than rejected, at publish and at load alike, is a `#@ preaggregate` on a measure the source does not publicly expose, or a grain naming a hidden dimension — a rollup STORES its grain and each measure\'s partial, and the stored table is served under the base\'s name without the source\'s field visibility applying to it. Each names the measure and the fix. Refusing rather than silently dropping the measure is the deliberate choice. A dropped measure is not served from the rollup at ANY grain, so the declaration would have no effect whatsoever while still reading as applied — and the build cost of the rollup would still be paid. An author who writes `#@ preaggregate` on a measure that cannot be rolled up has made a modeling mistake, and an error is where a mistake belongs. The same verdict is enforced at LOAD for every violation EXCEPT the two access-modifier ones, so a package whose declarations stopped being honorable does not load at all: it is absent from its environment and reported in `ServerStatus.loadErrors`. Worth knowing because whether a measure can be re-aggregated is derived from the compiled model, so a Malloy version change can in principle reclassify a measure that published cleanly long before. That surfaces as a package that stops loading rather than as a package quietly serving without its rollups — louder, and deliberately so, since the alternative is paying for rollups that answer nothing. The two access-modifier violations are the deliberate exception, and for two reasons rather than a lesser severity. They WARN at publish and at load alike and appear in this array. First, a package annotating a hidden field published and loaded before this rule existed — refusing it would stop an already-published package from doing either because a new validation was added, which is not a thing a server upgrade may do. Second, the refusal was unfollowable: an annotation INHERITED onto a source that then hides the measure raises it, while that source produces no plan at all and nothing is exposed, so the advice to make the field public or drop the annotation asks an author to give up either the hiding or the rollup over a model that was already safe. Warning is safe here and would not be for the others: what keeps a hidden field out of a rollup is that the planner refuses to plan one at all, so no table is built and nothing can be served whether or not anyone reads the message. For the other violations the refusal IS the enforcement, which is why they stay fatal.
2257
2263
  * @type {Array<PackageWarningsInner>}
2258
2264
  * @memberof Package
2259
2265
  */
2260
2266
  'warnings'?: Array<PackageWarningsInner>;
2261
2267
  /**
2262
- * Controls whether the discovery surface is also a query boundary. `\"declared\"` (the default) makes queryable == discoverable: when `explores` is declared, only `explores` model files are valid query entry points, and the queryable sources are the union of those files\' `export {}` closures — so a source exported by any listed file stays queryable whichever listed model path the request addresses it through. Admission is by declaration, not by name: a request clears only when the model it names resolves the name to the very source a listed file exported, so a same-named source declared in a hidden file is not admitted by the coincidence. Every other source still compiles, imports, joins, and extends but is not directly queryable (denied with 404). The `/compile` endpoint is exempt (compile is the authoring loop; the boundary is discovery curation, not access control — for confidentiality use `#(authorize)`, which gates compile too). A source that is both hidden and authorize-gated still answers `/compile` with the generic 404, so the exemption cannot be used to enumerate gated names. `\"all\"` decouples the axes: `explores`/`export {}` gate discovery only and every compiled source stays directly queryable. The two modes are equivalent (everything queryable) only where there is no curated surface at all, which now means no `explores` AND no root `index.malloy` — a package with that file has a surface whether or not the key is present. Invalid values fall back to `\"declared\"`. Identity-based access is a separate concern — see `#(authorize)` and `#(access_filter)`. DEPRECATED, still honored. `\"declared\"` is already the default, so the key changes nothing and a root `index.malloy` gives the same curated-and-enforced surface with no manifest field. `\"all\"` is the exception: `index.malloy` does NOT replace it, because a surface derived from one always enforces the boundary. It stays supported with no deprecation warning at load. To curate listings without refusing queries, keep both this key and an explicit `explores`.
2268
+ * Controls whether the discovery surface is also a query boundary. `\"declared\"` (the default) makes queryable == discoverable: when the package has a surface (a root `index.malloy`, or `explores`), only the surface\'s model files are valid query entry points, and the queryable sources are the union of those files\' `export {}` closures — so a source exported by any listed file stays queryable whichever listed model path the request addresses it through. Admission is by declaration, not by name: a request clears only when the model it names resolves the name to the very source a listed file exported, so a same-named source declared in a hidden file is not admitted by the coincidence. Every other source still compiles, imports, joins, and extends but is not directly queryable (denied with 404). The `/compile` endpoint is exempt (compile is the authoring loop; the boundary is discovery curation, not access control — for confidentiality use `#(authorize)`, which gates compile too). A source that is both hidden and authorize-gated still answers `/compile` with the generic 404, so the exemption cannot be used to enumerate gated names. `\"all\"` decouples the axes: the surface gates discovery only, every compiled source stays directly queryable, and model files off the surface are returned by path. The two modes are equivalent (everything queryable) only where there is no curated surface at all, which means no `explores` AND no root `index.malloy` — a package with that file has a surface whether or not the key is present. Invalid values fall back to `\"declared\"`. Identity-based access is a separate concern — see `#(authorize)` and `#(access_filter)`. `\"declared\"` is DEPRECATED: it is already the default, so the key changes nothing, and writing it gets a load warning saying to delete it. `\"all\"` is supported, with no warning, and works beside a root `index.malloy`. It is the one way to hide an `#(authorize)`-gated source from listings while authorized callers can still query it by name.
2263
2269
  * @type {string}
2264
2270
  * @memberof Package
2265
2271
  * @deprecated
@@ -2470,7 +2476,7 @@ export interface PackageWarningsInner {
2470
2476
  */
2471
2477
  'message'?: string;
2472
2478
  /**
2473
- * Finding severity. Render-tag findings use both: `error` for a tag malformed for the field it sits on, which renders as \"[object Object]\" or an inline error at query time, and `warn` for one that is well-formed but inert where it sits and so is silently ignored (e.g. `# colspan` outside `# dashboard { columns=N }`), where nothing looks broken at query time and the layout simply is not what was written. Those are the only two severities the renderer emits, so no render finding is withheld. Materialization and dashboard findings use both: `error` for something that cannot work as written, such as a tile naming a view the source does not have, and `warn` for something that works but not as the author probably intended, such as a dashboard held back by curation. The two findings about Publisher rather than about the package split across both: a file that carries an artifact tag and could not be read is `error`, because the dashboard it should have produced does not exist, and a lint that stopped early is `warn`, because the lint failing is not itself a defect in the package. That `warn` does NOT mean the package is free of `error`-severity findings, since the ones the lint never reached are exactly what it cannot report.
2479
+ * Finding severity. Render-tag findings use both: `error` for a tag malformed for the field it sits on, which renders as \"[object Object]\" or an inline error at query time, and `warn` for one that is well-formed but inert where it sits and so is silently ignored (e.g. `# colspan` outside `# dashboard { columns=N }`), where nothing looks broken at query time and the layout simply is not what was written. Those are the only two severities the renderer emits, so no render finding is withheld. Materialization and dashboard findings use both: `error` for something that cannot work as written, such as a tile naming a view the source does not have, and `warn` for something that works but not as the author probably intended, such as a dashboard name outside the conventional shape. The two findings about Publisher rather than about the package split across both: a file that carries an artifact tag and could not be read is `error`, because the dashboard it should have produced does not exist, and a lint that stopped early is `warn`, because the lint failing is not itself a defect in the package. That `warn` does NOT mean the package is free of `error`-severity findings, since the ones the lint never reached are exactly what it cannot report.
2474
2480
  * @type {string}
2475
2481
  * @memberof PackageWarningsInner
2476
2482
  */
@@ -4859,14 +4865,14 @@ export declare const DashboardsApiAxiosParamCreator: (configuration?: Configurat
4859
4865
  * @summary Get a dashboard manifest
4860
4866
  * @param {string} environmentName Name of the environment
4861
4867
  * @param {string} packageName Name of the package
4862
- * @param {string} dashboardName The dashboard\&#39;s name: its filename basename. Conventionally letters, digits, \&quot;-\&quot; and \&quot;_\&quot;, and a package is warned when one of its SERVED dashboards falls outside that. A dashboard withheld by curation gets no naming finding, because the naming check runs after the curation gate and a withheld dashboard is already reported as withheld. It is NOT constrained to it, because the name comes from a filename rather than being chosen: a file such as &#x60;dashboards/v1.2.malloy&#x60; is served, and its published &#x60;resource&#x60; carries the name percent-encoded. Send it percent-encoded.
4868
+ * @param {string} dashboardName The dashboard\&#39;s name: its filename basename. Conventionally letters, digits, \&quot;-\&quot; and \&quot;_\&quot;, and a package is warned when one of its dashboards falls outside that. It is NOT constrained to it, because the name comes from a filename rather than being chosen: a file such as &#x60;dashboards/v1.2.malloy&#x60; is served, and its published &#x60;resource&#x60; carries the name percent-encoded. Send it percent-encoded.
4863
4869
  * @param {string} [versionId] Version identifier for the package
4864
4870
  * @param {*} [options] Override http request option.
4865
4871
  * @throws {RequiredError}
4866
4872
  */
4867
4873
  getDashboard: (environmentName: string, packageName: string, dashboardName: string, versionId?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
4868
4874
  /**
4869
- * Lists the dashboards in the specified package — every `.malloy` file in the package\'s `dashboards/` directory that carries an `# artifact` (or model-level `## artifact`) annotation. A file in that directory with no artifact tag is a shared include and is not listed, whether or not it compiles. A tagged dashboard that failed to compile is listed carrying its `error` where that state can arise at all, so a broken dashboard is visibly broken rather than silently absent. In practice it rarely does: a package whose model fails to compile is not loaded, and a reload that would break one is refused and leaves the previously loaded package serving, so `error` is only reachable on the paths that keep per-model placeholders. Treat it as present-but-uncommon rather than the normal way a broken dashboard surfaces. When the package curates its query surface (a surface from `explores` or from a root `index.malloy`, with `queryableSources` left at `\"declared\"`), a dashboard whose entry file is not on that surface is omitted, because its query and given names would not be runnable. A root `index.malloy` cannot export a dashboard file, so a package curated only by that file omits every dashboard; the omission is reported in the package\'s `warnings` as of the last load. A metadata `PATCH` that TIGHTENS curation takes effect on this listing immediately; one that relaxes it takes effect on the next package reload, because the withheld dashboards were never built into the cached set. Either way the matching warning is computed at load, so after a `PATCH` it appears only once the package reloads. Where the boundary is active at all, which needs a surface (`explores` declared, or a root `index.malloy`) AND `queryableSources` left at `\"declared\"`, being listed does not by itself guarantee the dashboard runs: the queryable sources are the union of every listed file\'s `export {}` closure, so a dashboard whose tiles read a source that only an UNLISTED file exports is still served while those queries are refused. The fix is to list that file too, or to re-export the source from one already listed. It is served rather than withheld because withholding on a guess would hide dashboards that do work. Each such tile is reported in the package\'s `warnings` with severity `error`, as of the last load, naming the tile. The check reads the tile\'s source from its text, so a tile written in a form it cannot read is not reported. Under `\"all\"` nothing is refused, so the situation does not arise.
4875
+ * Lists the dashboards in the specified package — every `.malloy` file in the package\'s `dashboards/` directory that carries an `# artifact` (or model-level `## artifact`) annotation. A file in that directory with no artifact tag is a shared include and is not listed, whether or not it compiles. A tagged dashboard that failed to compile is listed carrying its `error` where that state can arise at all, so a broken dashboard is visibly broken rather than silently absent. In practice it rarely does: a package whose model fails to compile is not loaded, and a reload that would break one is refused and leaves the previously loaded package serving, so `error` is only reachable on the paths that keep per-model placeholders. Treat it as present-but-uncommon rather than the normal way a broken dashboard surfaces. Every tagged dashboard is listed, whatever the package\'s surface. To hide one, remove its `# artifact` tag. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a dashboard\'s tiles, its single query and its filter `suggest` queries may read only sources the surface exports. A source the dashboard declares on top of a surface source may be read; one over a hidden source may not. The dashboard file\'s own `export {}` and named queries add nothing to the surface. A tile over a hidden source answers 404 when it runs, and the package\'s `warnings` report each such tile, single query and suggest, with severity `error`, as of the last load, naming the source and the fix. Under `\"all\"` nothing is refused, so the situation does not arise.
4870
4876
  * @summary List package dashboards
4871
4877
  * @param {string} environmentName Name of the environment
4872
4878
  * @param {string} packageName Name of the package
@@ -4886,14 +4892,14 @@ export declare const DashboardsApiFp: (configuration?: Configuration) => {
4886
4892
  * @summary Get a dashboard manifest
4887
4893
  * @param {string} environmentName Name of the environment
4888
4894
  * @param {string} packageName Name of the package
4889
- * @param {string} dashboardName The dashboard\&#39;s name: its filename basename. Conventionally letters, digits, \&quot;-\&quot; and \&quot;_\&quot;, and a package is warned when one of its SERVED dashboards falls outside that. A dashboard withheld by curation gets no naming finding, because the naming check runs after the curation gate and a withheld dashboard is already reported as withheld. It is NOT constrained to it, because the name comes from a filename rather than being chosen: a file such as &#x60;dashboards/v1.2.malloy&#x60; is served, and its published &#x60;resource&#x60; carries the name percent-encoded. Send it percent-encoded.
4895
+ * @param {string} dashboardName The dashboard\&#39;s name: its filename basename. Conventionally letters, digits, \&quot;-\&quot; and \&quot;_\&quot;, and a package is warned when one of its dashboards falls outside that. It is NOT constrained to it, because the name comes from a filename rather than being chosen: a file such as &#x60;dashboards/v1.2.malloy&#x60; is served, and its published &#x60;resource&#x60; carries the name percent-encoded. Send it percent-encoded.
4890
4896
  * @param {string} [versionId] Version identifier for the package
4891
4897
  * @param {*} [options] Override http request option.
4892
4898
  * @throws {RequiredError}
4893
4899
  */
4894
4900
  getDashboard(environmentName: string, packageName: string, dashboardName: string, versionId?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<DashboardManifest>>;
4895
4901
  /**
4896
- * Lists the dashboards in the specified package — every `.malloy` file in the package\'s `dashboards/` directory that carries an `# artifact` (or model-level `## artifact`) annotation. A file in that directory with no artifact tag is a shared include and is not listed, whether or not it compiles. A tagged dashboard that failed to compile is listed carrying its `error` where that state can arise at all, so a broken dashboard is visibly broken rather than silently absent. In practice it rarely does: a package whose model fails to compile is not loaded, and a reload that would break one is refused and leaves the previously loaded package serving, so `error` is only reachable on the paths that keep per-model placeholders. Treat it as present-but-uncommon rather than the normal way a broken dashboard surfaces. When the package curates its query surface (a surface from `explores` or from a root `index.malloy`, with `queryableSources` left at `\"declared\"`), a dashboard whose entry file is not on that surface is omitted, because its query and given names would not be runnable. A root `index.malloy` cannot export a dashboard file, so a package curated only by that file omits every dashboard; the omission is reported in the package\'s `warnings` as of the last load. A metadata `PATCH` that TIGHTENS curation takes effect on this listing immediately; one that relaxes it takes effect on the next package reload, because the withheld dashboards were never built into the cached set. Either way the matching warning is computed at load, so after a `PATCH` it appears only once the package reloads. Where the boundary is active at all, which needs a surface (`explores` declared, or a root `index.malloy`) AND `queryableSources` left at `\"declared\"`, being listed does not by itself guarantee the dashboard runs: the queryable sources are the union of every listed file\'s `export {}` closure, so a dashboard whose tiles read a source that only an UNLISTED file exports is still served while those queries are refused. The fix is to list that file too, or to re-export the source from one already listed. It is served rather than withheld because withholding on a guess would hide dashboards that do work. Each such tile is reported in the package\'s `warnings` with severity `error`, as of the last load, naming the tile. The check reads the tile\'s source from its text, so a tile written in a form it cannot read is not reported. Under `\"all\"` nothing is refused, so the situation does not arise.
4902
+ * Lists the dashboards in the specified package — every `.malloy` file in the package\'s `dashboards/` directory that carries an `# artifact` (or model-level `## artifact`) annotation. A file in that directory with no artifact tag is a shared include and is not listed, whether or not it compiles. A tagged dashboard that failed to compile is listed carrying its `error` where that state can arise at all, so a broken dashboard is visibly broken rather than silently absent. In practice it rarely does: a package whose model fails to compile is not loaded, and a reload that would break one is refused and leaves the previously loaded package serving, so `error` is only reachable on the paths that keep per-model placeholders. Treat it as present-but-uncommon rather than the normal way a broken dashboard surfaces. Every tagged dashboard is listed, whatever the package\'s surface. To hide one, remove its `# artifact` tag. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a dashboard\'s tiles, its single query and its filter `suggest` queries may read only sources the surface exports. A source the dashboard declares on top of a surface source may be read; one over a hidden source may not. The dashboard file\'s own `export {}` and named queries add nothing to the surface. A tile over a hidden source answers 404 when it runs, and the package\'s `warnings` report each such tile, single query and suggest, with severity `error`, as of the last load, naming the source and the fix. Under `\"all\"` nothing is refused, so the situation does not arise.
4897
4903
  * @summary List package dashboards
4898
4904
  * @param {string} environmentName Name of the environment
4899
4905
  * @param {string} packageName Name of the package
@@ -4913,14 +4919,14 @@ export declare const DashboardsApiFactory: (configuration?: Configuration, baseP
4913
4919
  * @summary Get a dashboard manifest
4914
4920
  * @param {string} environmentName Name of the environment
4915
4921
  * @param {string} packageName Name of the package
4916
- * @param {string} dashboardName The dashboard\&#39;s name: its filename basename. Conventionally letters, digits, \&quot;-\&quot; and \&quot;_\&quot;, and a package is warned when one of its SERVED dashboards falls outside that. A dashboard withheld by curation gets no naming finding, because the naming check runs after the curation gate and a withheld dashboard is already reported as withheld. It is NOT constrained to it, because the name comes from a filename rather than being chosen: a file such as &#x60;dashboards/v1.2.malloy&#x60; is served, and its published &#x60;resource&#x60; carries the name percent-encoded. Send it percent-encoded.
4922
+ * @param {string} dashboardName The dashboard\&#39;s name: its filename basename. Conventionally letters, digits, \&quot;-\&quot; and \&quot;_\&quot;, and a package is warned when one of its dashboards falls outside that. It is NOT constrained to it, because the name comes from a filename rather than being chosen: a file such as &#x60;dashboards/v1.2.malloy&#x60; is served, and its published &#x60;resource&#x60; carries the name percent-encoded. Send it percent-encoded.
4917
4923
  * @param {string} [versionId] Version identifier for the package
4918
4924
  * @param {*} [options] Override http request option.
4919
4925
  * @throws {RequiredError}
4920
4926
  */
4921
4927
  getDashboard(environmentName: string, packageName: string, dashboardName: string, versionId?: string, options?: RawAxiosRequestConfig): AxiosPromise<DashboardManifest>;
4922
4928
  /**
4923
- * Lists the dashboards in the specified package — every `.malloy` file in the package\'s `dashboards/` directory that carries an `# artifact` (or model-level `## artifact`) annotation. A file in that directory with no artifact tag is a shared include and is not listed, whether or not it compiles. A tagged dashboard that failed to compile is listed carrying its `error` where that state can arise at all, so a broken dashboard is visibly broken rather than silently absent. In practice it rarely does: a package whose model fails to compile is not loaded, and a reload that would break one is refused and leaves the previously loaded package serving, so `error` is only reachable on the paths that keep per-model placeholders. Treat it as present-but-uncommon rather than the normal way a broken dashboard surfaces. When the package curates its query surface (a surface from `explores` or from a root `index.malloy`, with `queryableSources` left at `\"declared\"`), a dashboard whose entry file is not on that surface is omitted, because its query and given names would not be runnable. A root `index.malloy` cannot export a dashboard file, so a package curated only by that file omits every dashboard; the omission is reported in the package\'s `warnings` as of the last load. A metadata `PATCH` that TIGHTENS curation takes effect on this listing immediately; one that relaxes it takes effect on the next package reload, because the withheld dashboards were never built into the cached set. Either way the matching warning is computed at load, so after a `PATCH` it appears only once the package reloads. Where the boundary is active at all, which needs a surface (`explores` declared, or a root `index.malloy`) AND `queryableSources` left at `\"declared\"`, being listed does not by itself guarantee the dashboard runs: the queryable sources are the union of every listed file\'s `export {}` closure, so a dashboard whose tiles read a source that only an UNLISTED file exports is still served while those queries are refused. The fix is to list that file too, or to re-export the source from one already listed. It is served rather than withheld because withholding on a guess would hide dashboards that do work. Each such tile is reported in the package\'s `warnings` with severity `error`, as of the last load, naming the tile. The check reads the tile\'s source from its text, so a tile written in a form it cannot read is not reported. Under `\"all\"` nothing is refused, so the situation does not arise.
4929
+ * Lists the dashboards in the specified package — every `.malloy` file in the package\'s `dashboards/` directory that carries an `# artifact` (or model-level `## artifact`) annotation. A file in that directory with no artifact tag is a shared include and is not listed, whether or not it compiles. A tagged dashboard that failed to compile is listed carrying its `error` where that state can arise at all, so a broken dashboard is visibly broken rather than silently absent. In practice it rarely does: a package whose model fails to compile is not loaded, and a reload that would break one is refused and leaves the previously loaded package serving, so `error` is only reachable on the paths that keep per-model placeholders. Treat it as present-but-uncommon rather than the normal way a broken dashboard surfaces. Every tagged dashboard is listed, whatever the package\'s surface. To hide one, remove its `# artifact` tag. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a dashboard\'s tiles, its single query and its filter `suggest` queries may read only sources the surface exports. A source the dashboard declares on top of a surface source may be read; one over a hidden source may not. The dashboard file\'s own `export {}` and named queries add nothing to the surface. A tile over a hidden source answers 404 when it runs, and the package\'s `warnings` report each such tile, single query and suggest, with severity `error`, as of the last load, naming the source and the fix. Under `\"all\"` nothing is refused, so the situation does not arise.
4924
4930
  * @summary List package dashboards
4925
4931
  * @param {string} environmentName Name of the environment
4926
4932
  * @param {string} packageName Name of the package
@@ -4942,7 +4948,7 @@ export declare class DashboardsApi extends BaseAPI {
4942
4948
  * @summary Get a dashboard manifest
4943
4949
  * @param {string} environmentName Name of the environment
4944
4950
  * @param {string} packageName Name of the package
4945
- * @param {string} dashboardName The dashboard\&#39;s name: its filename basename. Conventionally letters, digits, \&quot;-\&quot; and \&quot;_\&quot;, and a package is warned when one of its SERVED dashboards falls outside that. A dashboard withheld by curation gets no naming finding, because the naming check runs after the curation gate and a withheld dashboard is already reported as withheld. It is NOT constrained to it, because the name comes from a filename rather than being chosen: a file such as &#x60;dashboards/v1.2.malloy&#x60; is served, and its published &#x60;resource&#x60; carries the name percent-encoded. Send it percent-encoded.
4951
+ * @param {string} dashboardName The dashboard\&#39;s name: its filename basename. Conventionally letters, digits, \&quot;-\&quot; and \&quot;_\&quot;, and a package is warned when one of its dashboards falls outside that. It is NOT constrained to it, because the name comes from a filename rather than being chosen: a file such as &#x60;dashboards/v1.2.malloy&#x60; is served, and its published &#x60;resource&#x60; carries the name percent-encoded. Send it percent-encoded.
4946
4952
  * @param {string} [versionId] Version identifier for the package
4947
4953
  * @param {*} [options] Override http request option.
4948
4954
  * @throws {RequiredError}
@@ -4950,7 +4956,7 @@ export declare class DashboardsApi extends BaseAPI {
4950
4956
  */
4951
4957
  getDashboard(environmentName: string, packageName: string, dashboardName: string, versionId?: string, options?: RawAxiosRequestConfig): Promise< AxiosResponse<DashboardManifest, any, {}>>;
4952
4958
  /**
4953
- * Lists the dashboards in the specified package — every `.malloy` file in the package\'s `dashboards/` directory that carries an `# artifact` (or model-level `## artifact`) annotation. A file in that directory with no artifact tag is a shared include and is not listed, whether or not it compiles. A tagged dashboard that failed to compile is listed carrying its `error` where that state can arise at all, so a broken dashboard is visibly broken rather than silently absent. In practice it rarely does: a package whose model fails to compile is not loaded, and a reload that would break one is refused and leaves the previously loaded package serving, so `error` is only reachable on the paths that keep per-model placeholders. Treat it as present-but-uncommon rather than the normal way a broken dashboard surfaces. When the package curates its query surface (a surface from `explores` or from a root `index.malloy`, with `queryableSources` left at `\"declared\"`), a dashboard whose entry file is not on that surface is omitted, because its query and given names would not be runnable. A root `index.malloy` cannot export a dashboard file, so a package curated only by that file omits every dashboard; the omission is reported in the package\'s `warnings` as of the last load. A metadata `PATCH` that TIGHTENS curation takes effect on this listing immediately; one that relaxes it takes effect on the next package reload, because the withheld dashboards were never built into the cached set. Either way the matching warning is computed at load, so after a `PATCH` it appears only once the package reloads. Where the boundary is active at all, which needs a surface (`explores` declared, or a root `index.malloy`) AND `queryableSources` left at `\"declared\"`, being listed does not by itself guarantee the dashboard runs: the queryable sources are the union of every listed file\'s `export {}` closure, so a dashboard whose tiles read a source that only an UNLISTED file exports is still served while those queries are refused. The fix is to list that file too, or to re-export the source from one already listed. It is served rather than withheld because withholding on a guess would hide dashboards that do work. Each such tile is reported in the package\'s `warnings` with severity `error`, as of the last load, naming the tile. The check reads the tile\'s source from its text, so a tile written in a form it cannot read is not reported. Under `\"all\"` nothing is refused, so the situation does not arise.
4959
+ * Lists the dashboards in the specified package — every `.malloy` file in the package\'s `dashboards/` directory that carries an `# artifact` (or model-level `## artifact`) annotation. A file in that directory with no artifact tag is a shared include and is not listed, whether or not it compiles. A tagged dashboard that failed to compile is listed carrying its `error` where that state can arise at all, so a broken dashboard is visibly broken rather than silently absent. In practice it rarely does: a package whose model fails to compile is not loaded, and a reload that would break one is refused and leaves the previously loaded package serving, so `error` is only reachable on the paths that keep per-model placeholders. Treat it as present-but-uncommon rather than the normal way a broken dashboard surfaces. Every tagged dashboard is listed, whatever the package\'s surface. To hide one, remove its `# artifact` tag. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a dashboard\'s tiles, its single query and its filter `suggest` queries may read only sources the surface exports. A source the dashboard declares on top of a surface source may be read; one over a hidden source may not. The dashboard file\'s own `export {}` and named queries add nothing to the surface. A tile over a hidden source answers 404 when it runs, and the package\'s `warnings` report each such tile, single query and suggest, with severity `error`, as of the last load, naming the source and the fix. Under `\"all\"` nothing is refused, so the situation does not arise.
4954
4960
  * @summary List package dashboards
4955
4961
  * @param {string} environmentName Name of the environment
4956
4962
  * @param {string} packageName Name of the package
@@ -5553,7 +5559,7 @@ export declare const ModelsApiAxiosParamCreator: (configuration?: Configuration)
5553
5559
  */
5554
5560
  compileModelSource: (environmentName: string, packageName: string, path: string, compileRequest: CompileRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
5555
5561
  /**
5556
- * Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration.
5562
+ * Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets.
5557
5563
  * @summary Execute Malloy query
5558
5564
  * @param {string} environmentName Name of the environment
5559
5565
  * @param {string} packageName Name of the package
@@ -5564,7 +5570,7 @@ export declare const ModelsApiAxiosParamCreator: (configuration?: Configuration)
5564
5570
  */
5565
5571
  executeQueryModel: (environmentName: string, packageName: string, path: string, queryRequest: QueryRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
5566
5572
  /**
5567
- * Retrieves a compiled Malloy model with its source information, queries, and metadata. The model is compiled using the specified version of the Malloy compiler. This endpoint provides access to the model\'s structure, sources, and named queries for use in applications.
5573
+ * Retrieves a compiled Malloy model with its source information, queries, and metadata. The model is compiled using the specified version of the Malloy compiler. This endpoint provides access to the model\'s structure, sources, and named queries for use in applications. On a package with a surface (a root `index.malloy`, or a legacy `explores`), a file off that surface answers 404 with the same message a query to it gets. Dashboard files are always returned. A package with no surface, or with `queryableSources: \"all\"`, returns every file. For a file it returns, `modelDef.contents` and `modelDef.exports`, `modelInfo`, `sources` and `sourceInfos` are limited to the names the file publishes, so the surface file does not carry the hidden sources it imports. A join to a hidden source keeps only its name and the names and types of its fields. `sourceText` is left out when the text names a source the file does not publish; a dashboard\'s text is always returned.
5568
5574
  * @summary Get compiled Malloy model
5569
5575
  * @param {string} environmentName Name of the environment
5570
5576
  * @param {string} packageName Name of the package
@@ -5614,7 +5620,7 @@ export declare const ModelsApiFp: (configuration?: Configuration) => {
5614
5620
  */
5615
5621
  compileModelSource(environmentName: string, packageName: string, path: string, compileRequest: CompileRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CompileResult>>;
5616
5622
  /**
5617
- * Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration.
5623
+ * Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets.
5618
5624
  * @summary Execute Malloy query
5619
5625
  * @param {string} environmentName Name of the environment
5620
5626
  * @param {string} packageName Name of the package
@@ -5625,7 +5631,7 @@ export declare const ModelsApiFp: (configuration?: Configuration) => {
5625
5631
  */
5626
5632
  executeQueryModel(environmentName: string, packageName: string, path: string, queryRequest: QueryRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<QueryResult>>;
5627
5633
  /**
5628
- * Retrieves a compiled Malloy model with its source information, queries, and metadata. The model is compiled using the specified version of the Malloy compiler. This endpoint provides access to the model\'s structure, sources, and named queries for use in applications.
5634
+ * Retrieves a compiled Malloy model with its source information, queries, and metadata. The model is compiled using the specified version of the Malloy compiler. This endpoint provides access to the model\'s structure, sources, and named queries for use in applications. On a package with a surface (a root `index.malloy`, or a legacy `explores`), a file off that surface answers 404 with the same message a query to it gets. Dashboard files are always returned. A package with no surface, or with `queryableSources: \"all\"`, returns every file. For a file it returns, `modelDef.contents` and `modelDef.exports`, `modelInfo`, `sources` and `sourceInfos` are limited to the names the file publishes, so the surface file does not carry the hidden sources it imports. A join to a hidden source keeps only its name and the names and types of its fields. `sourceText` is left out when the text names a source the file does not publish; a dashboard\'s text is always returned.
5629
5635
  * @summary Get compiled Malloy model
5630
5636
  * @param {string} environmentName Name of the environment
5631
5637
  * @param {string} packageName Name of the package
@@ -5675,7 +5681,7 @@ export declare const ModelsApiFactory: (configuration?: Configuration, basePath?
5675
5681
  */
5676
5682
  compileModelSource(environmentName: string, packageName: string, path: string, compileRequest: CompileRequest, options?: RawAxiosRequestConfig): AxiosPromise<CompileResult>;
5677
5683
  /**
5678
- * Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration.
5684
+ * Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets.
5679
5685
  * @summary Execute Malloy query
5680
5686
  * @param {string} environmentName Name of the environment
5681
5687
  * @param {string} packageName Name of the package
@@ -5686,7 +5692,7 @@ export declare const ModelsApiFactory: (configuration?: Configuration, basePath?
5686
5692
  */
5687
5693
  executeQueryModel(environmentName: string, packageName: string, path: string, queryRequest: QueryRequest, options?: RawAxiosRequestConfig): AxiosPromise<QueryResult>;
5688
5694
  /**
5689
- * Retrieves a compiled Malloy model with its source information, queries, and metadata. The model is compiled using the specified version of the Malloy compiler. This endpoint provides access to the model\'s structure, sources, and named queries for use in applications.
5695
+ * Retrieves a compiled Malloy model with its source information, queries, and metadata. The model is compiled using the specified version of the Malloy compiler. This endpoint provides access to the model\'s structure, sources, and named queries for use in applications. On a package with a surface (a root `index.malloy`, or a legacy `explores`), a file off that surface answers 404 with the same message a query to it gets. Dashboard files are always returned. A package with no surface, or with `queryableSources: \"all\"`, returns every file. For a file it returns, `modelDef.contents` and `modelDef.exports`, `modelInfo`, `sources` and `sourceInfos` are limited to the names the file publishes, so the surface file does not carry the hidden sources it imports. A join to a hidden source keeps only its name and the names and types of its fields. `sourceText` is left out when the text names a source the file does not publish; a dashboard\'s text is always returned.
5690
5696
  * @summary Get compiled Malloy model
5691
5697
  * @param {string} environmentName Name of the environment
5692
5698
  * @param {string} packageName Name of the package
@@ -5739,7 +5745,7 @@ export declare class ModelsApi extends BaseAPI {
5739
5745
  */
5740
5746
  compileModelSource(environmentName: string, packageName: string, path: string, compileRequest: CompileRequest, options?: RawAxiosRequestConfig): Promise< AxiosResponse<CompileResult, any, {}>>;
5741
5747
  /**
5742
- * Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration.
5748
+ * Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets.
5743
5749
  * @summary Execute Malloy query
5744
5750
  * @param {string} environmentName Name of the environment
5745
5751
  * @param {string} packageName Name of the package
@@ -5751,7 +5757,7 @@ export declare class ModelsApi extends BaseAPI {
5751
5757
  */
5752
5758
  executeQueryModel(environmentName: string, packageName: string, path: string, queryRequest: QueryRequest, options?: RawAxiosRequestConfig): Promise< AxiosResponse<QueryResult, any, {}>>;
5753
5759
  /**
5754
- * Retrieves a compiled Malloy model with its source information, queries, and metadata. The model is compiled using the specified version of the Malloy compiler. This endpoint provides access to the model\'s structure, sources, and named queries for use in applications.
5760
+ * Retrieves a compiled Malloy model with its source information, queries, and metadata. The model is compiled using the specified version of the Malloy compiler. This endpoint provides access to the model\'s structure, sources, and named queries for use in applications. On a package with a surface (a root `index.malloy`, or a legacy `explores`), a file off that surface answers 404 with the same message a query to it gets. Dashboard files are always returned. A package with no surface, or with `queryableSources: \"all\"`, returns every file. For a file it returns, `modelDef.contents` and `modelDef.exports`, `modelInfo`, `sources` and `sourceInfos` are limited to the names the file publishes, so the surface file does not carry the hidden sources it imports. A join to a hidden source keeps only its name and the names and types of its fields. `sourceText` is left out when the text names a source the file does not publish; a dashboard\'s text is always returned.
5755
5761
  * @summary Get compiled Malloy model
5756
5762
  * @param {string} environmentName Name of the environment
5757
5763
  * @param {string} packageName Name of the package
@@ -5793,7 +5799,7 @@ export declare class ModelsApi extends BaseAPI {
5793
5799
  */
5794
5800
  export declare const NotebooksApiAxiosParamCreator: (configuration?: Configuration) => {
5795
5801
  /**
5796
- * Executes a specific cell in a Malloy notebook by index. For code cells, this compiles and runs the Malloy code, returning query results and any new sources defined. For markdown cells, this simply returns the cell content.
5802
+ * Executes a specific cell in a Malloy notebook by index. For code cells, this compiles and runs the Malloy code, returning query results and any new sources defined. For markdown cells, this simply returns the cell content. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a code cell may read only sources the surface exports. A cell over a hidden source answers 404, and 404 rather than 403 even when the source is also `#(authorize)`-gated. A source an earlier cell declares on top of a published source still works. A cell\'s own source over a raw table (`duckdb.table(...)` or `.sql(...)`) has no published source under it, so it is refused. The response shows only the sources the notebook may read.
5797
5803
  * @summary Execute a specific notebook cell
5798
5804
  * @param {string} environmentName Name of the environment
5799
5805
  * @param {string} packageName Name of the package
@@ -5808,7 +5814,7 @@ export declare const NotebooksApiAxiosParamCreator: (configuration?: Configurati
5808
5814
  */
5809
5815
  executeNotebookCell: (environmentName: string, packageName: string, path: string, cellIndex: number, versionId?: string, filterParams?: string, bypassFilters?: ExecuteNotebookCellBypassFiltersEnum, givens?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
5810
5816
  /**
5811
- * Retrieves a Malloy notebook with its raw cell contents (markdown and code). Cell execution should be done separately via the execute-notebook-cell endpoint.
5817
+ * Retrieves a Malloy notebook with its raw cell contents (markdown and code). Cell execution should be done separately via the execute-notebook-cell endpoint. On a package with a surface, the response shows only the sources the notebook may read.
5812
5818
  * @summary Get Malloy notebook cells
5813
5819
  * @param {string} environmentName Name of the environment
5814
5820
  * @param {string} packageName Name of the package
@@ -5835,7 +5841,7 @@ export declare const NotebooksApiAxiosParamCreator: (configuration?: Configurati
5835
5841
  */
5836
5842
  export declare const NotebooksApiFp: (configuration?: Configuration) => {
5837
5843
  /**
5838
- * Executes a specific cell in a Malloy notebook by index. For code cells, this compiles and runs the Malloy code, returning query results and any new sources defined. For markdown cells, this simply returns the cell content.
5844
+ * Executes a specific cell in a Malloy notebook by index. For code cells, this compiles and runs the Malloy code, returning query results and any new sources defined. For markdown cells, this simply returns the cell content. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a code cell may read only sources the surface exports. A cell over a hidden source answers 404, and 404 rather than 403 even when the source is also `#(authorize)`-gated. A source an earlier cell declares on top of a published source still works. A cell\'s own source over a raw table (`duckdb.table(...)` or `.sql(...)`) has no published source under it, so it is refused. The response shows only the sources the notebook may read.
5839
5845
  * @summary Execute a specific notebook cell
5840
5846
  * @param {string} environmentName Name of the environment
5841
5847
  * @param {string} packageName Name of the package
@@ -5850,7 +5856,7 @@ export declare const NotebooksApiFp: (configuration?: Configuration) => {
5850
5856
  */
5851
5857
  executeNotebookCell(environmentName: string, packageName: string, path: string, cellIndex: number, versionId?: string, filterParams?: string, bypassFilters?: ExecuteNotebookCellBypassFiltersEnum, givens?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<NotebookCellResult>>;
5852
5858
  /**
5853
- * Retrieves a Malloy notebook with its raw cell contents (markdown and code). Cell execution should be done separately via the execute-notebook-cell endpoint.
5859
+ * Retrieves a Malloy notebook with its raw cell contents (markdown and code). Cell execution should be done separately via the execute-notebook-cell endpoint. On a package with a surface, the response shows only the sources the notebook may read.
5854
5860
  * @summary Get Malloy notebook cells
5855
5861
  * @param {string} environmentName Name of the environment
5856
5862
  * @param {string} packageName Name of the package
@@ -5877,7 +5883,7 @@ export declare const NotebooksApiFp: (configuration?: Configuration) => {
5877
5883
  */
5878
5884
  export declare const NotebooksApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
5879
5885
  /**
5880
- * Executes a specific cell in a Malloy notebook by index. For code cells, this compiles and runs the Malloy code, returning query results and any new sources defined. For markdown cells, this simply returns the cell content.
5886
+ * Executes a specific cell in a Malloy notebook by index. For code cells, this compiles and runs the Malloy code, returning query results and any new sources defined. For markdown cells, this simply returns the cell content. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a code cell may read only sources the surface exports. A cell over a hidden source answers 404, and 404 rather than 403 even when the source is also `#(authorize)`-gated. A source an earlier cell declares on top of a published source still works. A cell\'s own source over a raw table (`duckdb.table(...)` or `.sql(...)`) has no published source under it, so it is refused. The response shows only the sources the notebook may read.
5881
5887
  * @summary Execute a specific notebook cell
5882
5888
  * @param {string} environmentName Name of the environment
5883
5889
  * @param {string} packageName Name of the package
@@ -5892,7 +5898,7 @@ export declare const NotebooksApiFactory: (configuration?: Configuration, basePa
5892
5898
  */
5893
5899
  executeNotebookCell(environmentName: string, packageName: string, path: string, cellIndex: number, versionId?: string, filterParams?: string, bypassFilters?: ExecuteNotebookCellBypassFiltersEnum, givens?: string, options?: RawAxiosRequestConfig): AxiosPromise<NotebookCellResult>;
5894
5900
  /**
5895
- * Retrieves a Malloy notebook with its raw cell contents (markdown and code). Cell execution should be done separately via the execute-notebook-cell endpoint.
5901
+ * Retrieves a Malloy notebook with its raw cell contents (markdown and code). Cell execution should be done separately via the execute-notebook-cell endpoint. On a package with a surface, the response shows only the sources the notebook may read.
5896
5902
  * @summary Get Malloy notebook cells
5897
5903
  * @param {string} environmentName Name of the environment
5898
5904
  * @param {string} packageName Name of the package
@@ -5921,7 +5927,7 @@ export declare const NotebooksApiFactory: (configuration?: Configuration, basePa
5921
5927
  */
5922
5928
  export declare class NotebooksApi extends BaseAPI {
5923
5929
  /**
5924
- * Executes a specific cell in a Malloy notebook by index. For code cells, this compiles and runs the Malloy code, returning query results and any new sources defined. For markdown cells, this simply returns the cell content.
5930
+ * Executes a specific cell in a Malloy notebook by index. For code cells, this compiles and runs the Malloy code, returning query results and any new sources defined. For markdown cells, this simply returns the cell content. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a code cell may read only sources the surface exports. A cell over a hidden source answers 404, and 404 rather than 403 even when the source is also `#(authorize)`-gated. A source an earlier cell declares on top of a published source still works. A cell\'s own source over a raw table (`duckdb.table(...)` or `.sql(...)`) has no published source under it, so it is refused. The response shows only the sources the notebook may read.
5925
5931
  * @summary Execute a specific notebook cell
5926
5932
  * @param {string} environmentName Name of the environment
5927
5933
  * @param {string} packageName Name of the package
@@ -5937,7 +5943,7 @@ export declare class NotebooksApi extends BaseAPI {
5937
5943
  */
5938
5944
  executeNotebookCell(environmentName: string, packageName: string, path: string, cellIndex: number, versionId?: string, filterParams?: string, bypassFilters?: ExecuteNotebookCellBypassFiltersEnum, givens?: string, options?: RawAxiosRequestConfig): Promise< AxiosResponse<NotebookCellResult, any, {}>>;
5939
5945
  /**
5940
- * Retrieves a Malloy notebook with its raw cell contents (markdown and code). Cell execution should be done separately via the execute-notebook-cell endpoint.
5946
+ * Retrieves a Malloy notebook with its raw cell contents (markdown and code). Cell execution should be done separately via the execute-notebook-cell endpoint. On a package with a surface, the response shows only the sources the notebook may read.
5941
5947
  * @summary Get Malloy notebook cells
5942
5948
  * @param {string} environmentName Name of the environment
5943
5949
  * @param {string} packageName Name of the package
@@ -1,4 +1,4 @@
1
- import { A as e, a as i, C as o, b as n, c as t, aC as r, e as p, f as u, d as A, O as m, I as c, K as E, J as l, X as C, U as y, W as P, V as F, $ as b, Y as g, _ as d, Z as S, D as k, a3 as M, a0 as h, a2 as x, a1 as v, h as D, a7 as T, a4 as R, a6 as f, a5 as z, ab as N, a8 as Q, aa as W, a9 as B, ap as O, F as I, i as L, G as q, L as w, j, k as G, M as H, l as J, ag as K, m as U, af as V, ac as X, ae as Y, ad as Z, ak as _, ah as $, aj as aa, ai as sa, n as ea, N as ia, ao as oa, al as na, an as ta, am as ra, q as pa, p as ua, o as Aa, P as ma, r as ca, s as Ea, at as la, aq as Ca, as as ya, ar as Pa, t as Fa, v as ba, ax as ga, au as da, aw as Sa, av as ka, Q as Ma, w as ha, x as xa, R as va, z as Da, y as Ta, B as Ra, E as fa, S as za, H as Na, T as Qa, aB as Wa, ay as Ba, aA as Oa, az as Ia, g as La, u as qa } from "../ServerProvider-AsUiy22k.es.js";
1
+ import { A as e, a as i, C as o, b as n, c as t, aC as r, e as p, f as u, d as A, O as m, I as c, K as E, J as l, X as C, U as y, W as P, V as F, $ as b, Y as g, _ as d, Z as S, D as k, a3 as M, a0 as h, a2 as x, a1 as v, h as D, a7 as T, a4 as R, a6 as f, a5 as z, ab as N, a8 as Q, aa as W, a9 as B, ap as O, F as I, i as L, G as q, L as w, j, k as G, M as H, l as J, ag as K, m as U, af as V, ac as X, ae as Y, ad as Z, ak as _, ah as $, aj as aa, ai as sa, n as ea, N as ia, ao as oa, al as na, an as ta, am as ra, q as pa, p as ua, o as Aa, P as ma, r as ca, s as Ea, at as la, aq as Ca, as as ya, ar as Pa, t as Fa, v as ba, ax as ga, au as da, aw as Sa, av as ka, Q as Ma, w as ha, x as xa, R as va, z as Da, y as Ta, B as Ra, E as fa, S as za, H as Na, T as Qa, aB as Wa, ay as Ba, aA as Oa, az as Ia, g as La, u as qa } from "../ServerProvider-CfUFleYe.es.js";
2
2
  export {
3
3
  e as AttachedDatabaseTypeEnum,
4
4
  i as AzureConnectionAuthTypeEnum,
@@ -7,12 +7,14 @@
7
7
  * as written. The model is fetched here rather than inside the explorer so
8
8
  * the tile's source can be selected before it renders.
9
9
  */
10
- export declare function ExploreDialog({ tile, environmentName, packageName, versionId, modelPath, onClose, }: {
10
+ export declare function ExploreDialog({ tile, environmentName, packageName, versionId, modelPath, givens, onClose, }: {
11
11
  /** The tile expression to open, or undefined when closed. */
12
12
  tile: string | undefined;
13
13
  environmentName: string;
14
14
  packageName: string;
15
15
  versionId?: string;
16
16
  modelPath: string;
17
+ /** The dashboard's current control values, to seed the explorer's own. */
18
+ givens?: Record<string, string>;
17
19
  onClose: () => void;
18
20
  }): import("react/jsx-runtime").JSX.Element;
@@ -60,3 +60,21 @@ export declare function filterableFields(catalog: PackageCatalog | undefined, so
60
60
  */
61
61
  export declare const isDashboardModel: (path: string | undefined) => boolean;
62
62
  export declare function buildCatalog(models: CompiledModel[]): PackageCatalog;
63
+ /**
64
+ * The part of the package catalog a dashboard file can actually use.
65
+ *
66
+ * The builder never writes an import, so a source the file cannot see would
67
+ * produce a tile that does not compile. A named import says exactly which
68
+ * names it brings. A whole-file import of a published model brings that
69
+ * model's sources. A whole-file import of a file off the surface cannot be
70
+ * read, so then every published source is offered and a wrong pick is caught
71
+ * by the compile check the editor already runs.
72
+ */
73
+ export declare function visibleToDashboard(catalog: PackageCatalog, imports: ReadonlyArray<{
74
+ kind: "all";
75
+ path: string;
76
+ } | {
77
+ kind: "names";
78
+ names: string[];
79
+ path: string;
80
+ }>, published: CompiledModel[]): PackageCatalog;
@@ -1,9 +1,16 @@
1
1
  import { QueryExplorerResult } from './SourcesExplorer';
2
- interface ModelProps {
2
+ export interface ModelProps {
3
3
  onChange?: (query: QueryExplorerResult) => void;
4
4
  resourceUri: string;
5
5
  runOnDemand?: boolean;
6
6
  maxResultSize?: number;
7
+ /**
8
+ * Control values from the host, typically its URL query parameters. When
9
+ * omitted, `Model` holds them itself, so the embedded explorer and the
10
+ * maximized dialog still agree with each other.
11
+ */
12
+ givens?: Record<string, string>;
13
+ /** Applied control values, for a host that wants them in its URL. */
14
+ onGivensChange?: (givens: Record<string, string>, managed: readonly string[]) => void;
7
15
  }
8
- export default function Model({ onChange, resourceUri, runOnDemand, maxResultSize, }: ModelProps): import("react/jsx-runtime").JSX.Element;
9
- export {};
16
+ export default function Model({ onChange, resourceUri, runOnDemand, maxResultSize, givens, onGivensChange, }: ModelProps): import("react/jsx-runtime").JSX.Element;
@@ -11,6 +11,26 @@ export interface ModelExplorerProps {
11
11
  /** Callback when source selection changes */
12
12
  onSourceChange?: (index: number) => void;
13
13
  resourceUri: string;
14
+ /**
15
+ * Control values from the host, typically its URL query parameters. These
16
+ * beat the model's own starting values, so a shared link shows what the
17
+ * sender was looking at.
18
+ */
19
+ givens?: Record<string, string>;
20
+ /**
21
+ * Applied control values, for a host that wants them in its URL.
22
+ *
23
+ * `managed` is every given this model declares, whether or not it currently
24
+ * holds a value, and a host writing to a shared query string needs it.
25
+ * `givens` alone says which parameters to write but not which to REMOVE, so
26
+ * a host that guesses by deleting everything it did not just receive
27
+ * deletes the unrelated parameters it has no business touching. Same
28
+ * contract as `Dashboard` and `Notebook`, so a host can treat every surface
29
+ * alike.
30
+ */
31
+ onGivensChange?: (givens: Record<string, string>, managed: readonly string[]) => void;
32
+ /** Where the controls start, from the host, e.g. a dashboard tile's values. */
33
+ startingGivens?: Record<string, string>;
14
34
  }
15
35
  /**
16
36
  * ModelExplorer renders the main explorer UI for a Malloy model. It shows the
@@ -18,4 +38,4 @@ export interface ModelExplorerProps {
18
38
  * queries for that model. This logic was originally embedded inside `Model.tsx`
19
39
  * but has been extracted for easier reuse.
20
40
  */
21
- export declare function ModelExplorer({ data, onChange, existingQuery, initialSelectedSourceIndex, onSourceChange, resourceUri, }: ModelExplorerProps): import("react/jsx-runtime").JSX.Element;
41
+ export declare function ModelExplorer({ data, onChange, existingQuery, initialSelectedSourceIndex, onSourceChange, resourceUri, givens, onGivensChange, startingGivens, }: ModelExplorerProps): import("react/jsx-runtime").JSX.Element;
@@ -11,6 +11,9 @@ interface ModelExplorerDialogProps {
11
11
  initialSelectedSourceIndex?: number;
12
12
  onChange?: (query: QueryExplorerResult) => void;
13
13
  onSourceChange?: (index: number) => void;
14
+ givens?: Record<string, string>;
15
+ onGivensChange?: (givens: Record<string, string>, managed: readonly string[]) => void;
16
+ startingGivens?: Record<string, string>;
14
17
  }
15
- export declare function ModelExplorerDialog({ open, onClose, resourceUri, data, title, hasValidImport, existingQuery, initialSelectedSourceIndex, onChange, onSourceChange, }: ModelExplorerDialogProps): import("react/jsx-runtime").JSX.Element;
18
+ export declare function ModelExplorerDialog({ open, onClose, resourceUri, data, title, hasValidImport, existingQuery, initialSelectedSourceIndex, onChange, onSourceChange, givens, onGivensChange, startingGivens, }: ModelExplorerDialogProps): import("react/jsx-runtime").JSX.Element;
16
19
  export {};
@@ -1,3 +1,4 @@
1
+ import { RunGate } from './runGate';
1
2
  import * as Malloy from "@malloydata/malloy-interfaces";
2
3
  export interface SourceAndPath {
3
4
  modelPath: string;
@@ -10,6 +11,10 @@ export interface SourceExplorerProps {
10
11
  onQueryChange?: (query: QueryExplorerResult) => void;
11
12
  onSourceChange?: (index: number) => void;
12
13
  resourceUri: string;
14
+ /** The control row's current values, sent with every Run. */
15
+ givens?: Record<string, unknown>;
16
+ /** What the control row leaves unset, for the words around a result or a refusal. */
17
+ gate?: RunGate;
13
18
  }
14
19
  /**
15
20
  * Component for Exploring a set of sources.
@@ -18,12 +23,14 @@ export interface SourceExplorerProps {
18
23
  * It is expected that multiple sourceInfo entries will correspond to the same
19
24
  * model path.
20
25
  */
21
- export declare function SourcesExplorer({ sourceAndPaths, selectedSourceIndex, existingQuery, onQueryChange, onSourceChange, resourceUri, }: SourceExplorerProps): import("react/jsx-runtime").JSX.Element;
26
+ export declare function SourcesExplorer({ sourceAndPaths, selectedSourceIndex, existingQuery, onQueryChange, onSourceChange, resourceUri, givens, gate, }: SourceExplorerProps): import("react/jsx-runtime").JSX.Element;
22
27
  interface SourceExplorerComponentProps {
23
28
  sourceAndPath: SourceAndPath;
24
29
  existingQuery?: QueryExplorerResult;
25
30
  onChange?: (query: QueryExplorerResult) => void;
26
31
  resourceUri: string;
32
+ givens?: Record<string, unknown>;
33
+ gate?: RunGate;
27
34
  }
28
35
  export interface QueryExplorerResult {
29
36
  query: string | undefined;
@@ -1,4 +1,5 @@
1
1
  export { default as Model } from './Model';
2
+ export type { ModelProps } from './Model';
2
3
  export { ModelExplorer } from './ModelExplorer';
3
4
  export { ModelExplorerDialog } from './ModelExplorerDialog';
4
5
  export { SourcesExplorer } from './SourcesExplorer';
@@ -0,0 +1,19 @@
1
+ import { Given } from '../../client';
2
+ import { GivenValue } from '../../hooks/givenValue';
3
+ /**
4
+ * What a Run is about to send, measured against the model's declared givens.
5
+ *
6
+ * Nothing here refuses a Run. Givens are declared model-wide but read per
7
+ * source, and nothing on the client says which source reads which, so a blank
8
+ * given with no default may be exactly right for the source being explored.
9
+ * The server decides; this only supplies the words around its answer.
10
+ */
11
+ export interface RunGate {
12
+ /** Unset givens with no default: named in a hint when the server refuses. */
13
+ missing: string[];
14
+ /** Set when an unset given fell back to a non-empty default. */
15
+ defaultsNote?: string;
16
+ }
17
+ export declare function runGate(givens: readonly Given[], values: ReadonlyMap<string, GivenValue>): RunGate;
18
+ /** The hint shown under a refusal when the reader left no-default givens blank. */
19
+ export declare function missingGivensHint(missing: readonly string[]): string;
@@ -1,3 +1,4 @@
1
+ import { Given } from '../../client';
1
2
  import { NavigationClick } from '../click_helper';
2
3
  import { DrillNavigation } from '../drill';
3
4
  import { EnhancedNotebookCell } from './types';
@@ -45,6 +46,14 @@ interface NotebookCellProps {
45
46
  * drill inert rather than dead-ended, and removes the affordance with it.
46
47
  */
47
48
  onDrillNavigate?: (target: DrillNavigation, event?: MouseEvent) => void;
49
+ /**
50
+ * The notebook's current control values, to seed the "Data Sources"
51
+ * dialog's own so exploring from a cell starts from what the reader is
52
+ * looking at rather than the model's bare defaults.
53
+ */
54
+ givens?: Record<string, string>;
55
+ /** The notebook's declared givens, so that dialog renders their controls. */
56
+ givenSpecs?: Given[];
48
57
  }
49
- export declare function NotebookCell({ cell, hideCodeCellIcon, hideEmbeddingIcon, resourceUri, index, maxResultSize, isExecuting, pendingRerun, onNavigate, onDrillSelf, canDrillSelf, onDrillNavigate, }: NotebookCellProps): import("react/jsx-runtime").JSX.Element;
58
+ export declare function NotebookCell({ cell, hideCodeCellIcon, hideEmbeddingIcon, resourceUri, index, maxResultSize, isExecuting, pendingRerun, onNavigate, onDrillSelf, canDrillSelf, onDrillNavigate, givens, givenSpecs, }: NotebookCellProps): import("react/jsx-runtime").JSX.Element;
50
59
  export {};