@malloy-publisher/sdk 0.0.239 → 0.0.241

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 (43) hide show
  1. package/bunfig.toml +4 -0
  2. package/dist/ServerProvider-D40U1tBk.cjs.js +1 -0
  3. package/dist/{ServerProvider-kzoOMXNx.es.js → ServerProvider-FQ4I4dKu.es.js} +250 -241
  4. package/dist/client/api.d.ts +181 -109
  5. package/dist/client/configuration.d.ts +1 -1
  6. package/dist/client/index.cjs.js +1 -1
  7. package/dist/client/index.d.ts +1 -1
  8. package/dist/client/index.es.js +70 -68
  9. package/dist/components/{PageViewer/PageViewer.d.ts → DataAppViewer/DataAppViewer.d.ts} +6 -6
  10. package/dist/components/DataAppViewer/index.d.ts +1 -0
  11. package/dist/components/Package/ContentTypeIcon.d.ts +1 -1
  12. package/dist/components/ServerProvider.d.ts +2 -2
  13. package/dist/components/index.d.ts +1 -1
  14. package/dist/{core-DtPGM_JB.cjs.js → core-2tUy-45C.cjs.js} +1 -1
  15. package/dist/{core-BGHaIj_q.es.js → core-KFsKleo0.es.js} +1 -1
  16. package/dist/hooks/useGivensForm.d.ts +8 -4
  17. package/dist/{index-B2gBd2gP.cjs.js → index-C0EfXZ-k.cjs.js} +31 -31
  18. package/dist/{index-CEteIhTc.es.js → index-D2sq6csh.es.js} +1825 -1829
  19. package/dist/index.cjs.js +1 -1
  20. package/dist/index.d.ts +1 -1
  21. package/dist/index.es.js +34 -34
  22. package/dist/utils/{pageEmbed.d.ts → dataAppEmbed.d.ts} +7 -7
  23. package/package.json +7 -4
  24. package/src/components/{PageViewer/PageViewer.tsx → DataAppViewer/DataAppViewer.tsx} +41 -36
  25. package/src/components/DataAppViewer/index.ts +1 -0
  26. package/src/components/Package/ContentTypeIcon.tsx +2 -2
  27. package/src/components/Package/Package.tsx +28 -30
  28. package/src/components/ServerProvider.tsx +2 -2
  29. package/src/components/given/GivenInput.spec.tsx +206 -0
  30. package/src/components/given/GivenInput.tsx +6 -1
  31. package/src/components/index.ts +1 -1
  32. package/src/hooks/useGivensForm.spec.ts +99 -0
  33. package/src/hooks/useGivensForm.ts +14 -5
  34. package/src/index.ts +1 -1
  35. package/src/utils/{pageEmbed.spec.ts → dataAppEmbed.spec.ts} +1 -1
  36. package/src/utils/{pageEmbed.ts → dataAppEmbed.ts} +9 -9
  37. package/test/README.md +130 -0
  38. package/test/setup.ts +26 -0
  39. package/tsconfig.json +12 -1
  40. package/tsconfig.spec.json +22 -0
  41. package/dist/ServerProvider-nJNqhxy6.cjs.js +0 -1
  42. package/dist/components/PageViewer/index.d.ts +0 -1
  43. package/src/components/PageViewer/index.ts +0 -1
@@ -1,7 +1,7 @@
1
1
  import { jsx as F } from "react/jsx-runtime";
2
2
  import { QueryClient as le, QueryClientProvider as ce, useQuery as ie } from "@tanstack/react-query";
3
3
  import h from "axios";
4
- import { useMemo as f, createContext as _, useContext as G, useState as D, useEffect as de, useCallback as pe } from "react";
4
+ import { useMemo as f, createContext as _, useContext as G, useState as H, useEffect as de, useCallback as pe } from "react";
5
5
  import { styled as k, Card as Y, CardContent as J, CardMedia as me } from "@mui/material";
6
6
  const u = "http://localhost/api/v0".replace(/\/+$/, "");
7
7
  class I {
@@ -71,83 +71,90 @@ const b = function(l, ...n) {
71
71
  Ok: "ok",
72
72
  Failed: "failed"
73
73
  }, oa = {
74
+ Viewport: "viewport"
75
+ }, sa = {
74
76
  Embedded: "embedded",
75
77
  Materialized: "materialized"
76
- }, sa = {
78
+ }, la = {
77
79
  Equal: "equal",
78
80
  In: "in",
79
81
  Like: "like",
80
82
  GreaterThan: "greater_than",
81
83
  LessThan: "less_than"
82
- }, la = {
84
+ }, ca = {
83
85
  Live: "live",
84
86
  StaleOk: "stale_ok",
85
87
  Fail: "fail"
86
- }, ca = {
88
+ }, ia = {
87
89
  Select: "select",
88
90
  Multiselect: "multiselect"
89
- }, ia = {
91
+ }, da = {
92
+ Merge: "merge",
93
+ RangeReplace: "range_replace"
94
+ }, pa = {
90
95
  Debug: "debug",
91
96
  Info: "info",
92
97
  Warn: "warn",
93
98
  Error: "error"
94
- }, da = {
99
+ }, ma = {
95
100
  Live: "live",
96
101
  StaleOk: "stale_ok",
97
102
  Fail: "fail"
98
- }, pa = {
103
+ }, ha = {
104
+ Delta: "delta",
105
+ Full: "full",
106
+ None: "none"
107
+ }, ua = {
99
108
  Pending: "PENDING",
100
109
  ManifestRowsReady: "MANIFEST_ROWS_READY",
101
110
  ManifestFileReady: "MANIFEST_FILE_READY",
102
111
  Failed: "FAILED",
103
112
  Cancelled: "CANCELLED"
104
- }, ma = {
113
+ }, ga = {
105
114
  Markdown: "markdown",
106
115
  Code: "code"
107
- }, ha = {
116
+ }, Pa = {
108
117
  Markdown: "markdown",
109
118
  Code: "code"
110
- }, ua = {
119
+ }, ba = {
111
120
  Version: "version",
112
121
  Package: "package"
113
- }, ga = {
122
+ }, va = {
114
123
  Declared: "declared",
115
124
  All: "all"
116
- }, Pa = {
125
+ }, Va = {
117
126
  Unbound: "unbound",
118
127
  Bound: "bound",
119
128
  LiveFallback: "live_fallback"
120
- }, ba = {
129
+ }, Oa = {
121
130
  Error: "error",
122
131
  Warn: "warn"
123
- }, va = {
124
- Viewport: "viewport"
125
- }, Va = {
132
+ }, Sa = {
126
133
  Disable: "disable",
127
134
  NoVerify: "no-verify",
128
135
  VerifyCa: "verify-ca",
129
136
  VerifyFull: "verify-full"
130
- }, Oa = {
137
+ }, ya = {
131
138
  Interactive: "interactive",
132
139
  Materialize: "materialize",
133
140
  Index: "index",
134
141
  Ops: "ops"
135
- }, Sa = {
142
+ }, ka = {
136
143
  Query: "query",
137
144
  ServerDefault: "server_default"
138
- }, ya = {
145
+ }, Ca = {
139
146
  Snapshot: "SNAPSHOT",
140
147
  Copy: "COPY"
141
- }, ka = {
148
+ }, Ia = {
142
149
  Publish: "publish",
143
150
  OnDemand: "on_demand",
144
151
  Scheduler: "scheduler"
145
- }, Ca = {
152
+ }, xa = {
146
153
  Initializing: "initializing",
147
154
  Serving: "serving",
148
155
  Draining: "draining",
149
156
  Throttled: "throttled"
150
- }, Ia = {
157
+ }, Aa = {
151
158
  Light: "light",
152
159
  Dark: "dark",
153
160
  Auto: "auto"
@@ -761,7 +768,7 @@ const b = function(l, ...n) {
761
768
  return (i, d) => V(o, h, u, l)(i, c || d);
762
769
  }
763
770
  };
764
- }, xa = function(l, n, e) {
771
+ }, Ra = function(l, n, e) {
765
772
  const r = S(l);
766
773
  return {
767
774
  /**
@@ -1239,7 +1246,7 @@ const Pe = function(l) {
1239
1246
  return (s, c) => V(a, h, u, l)(s, o || c);
1240
1247
  }
1241
1248
  };
1242
- }, Aa = function(l, n, e) {
1249
+ }, Na = function(l, n, e) {
1243
1250
  const r = K(l);
1244
1251
  return {
1245
1252
  /**
@@ -1254,7 +1261,7 @@ const Pe = function(l) {
1254
1261
  }
1255
1262
  };
1256
1263
  };
1257
- class Ra extends I {
1264
+ class Ta extends I {
1258
1265
  /**
1259
1266
  * Validates a database connection configuration without adding it to any environment. This endpoint allows you to test connection parameters, credentials, and network connectivity before committing the connection to an environment. Useful for troubleshooting connection issues and validating configurations during setup.
1260
1267
  * @summary Test database connection configuration
@@ -1268,6 +1275,76 @@ class Ra extends I {
1268
1275
  }
1269
1276
  }
1270
1277
  const be = function(l) {
1278
+ return {
1279
+ /**
1280
+ * Retrieves a list of all in-package HTML data apps (static pages served from the package\'s public/ directory) within the specified package. Each entry includes the relative path, the package name, a canonical resource URL, and the title (extracted from the file\'s <title> tag, falling back to the path). Used by the Publisher SPA to surface a clickable \"Data Apps\" section on the package detail view, and by anyone who wants to discover a package\'s data apps programmatically without scraping the directory. Recursive depth is capped server-side to keep this cheap on large packages.
1281
+ * @summary List package data apps
1282
+ * @param {string} environmentName Name of the environment
1283
+ * @param {string} packageName Name of the package
1284
+ * @param {*} [options] Override http request option.
1285
+ * @throws {RequiredError}
1286
+ */
1287
+ listDataApps: async (n, e, r = {}) => {
1288
+ m("listDataApps", "environmentName", n), m("listDataApps", "packageName", e);
1289
+ const a = "/environments/{environmentName}/packages/{packageName}/data-apps".replace("{environmentName}", encodeURIComponent(String(n))).replace("{packageName}", encodeURIComponent(String(e))), t = new URL(a, P);
1290
+ let o;
1291
+ l && (o = l.baseOptions);
1292
+ const s = { method: "GET", ...o, ...r }, c = {};
1293
+ b(t, {});
1294
+ let d = o && o.headers ? o.headers : {};
1295
+ return s.headers = { ...c, ...d, ...r.headers }, {
1296
+ url: v(t),
1297
+ options: s
1298
+ };
1299
+ }
1300
+ };
1301
+ }, X = function(l) {
1302
+ const n = be(l);
1303
+ return {
1304
+ /**
1305
+ * Retrieves a list of all in-package HTML data apps (static pages served from the package\'s public/ directory) within the specified package. Each entry includes the relative path, the package name, a canonical resource URL, and the title (extracted from the file\'s <title> tag, falling back to the path). Used by the Publisher SPA to surface a clickable \"Data Apps\" section on the package detail view, and by anyone who wants to discover a package\'s data apps programmatically without scraping the directory. Recursive depth is capped server-side to keep this cheap on large packages.
1306
+ * @summary List package data apps
1307
+ * @param {string} environmentName Name of the environment
1308
+ * @param {string} packageName Name of the package
1309
+ * @param {*} [options] Override http request option.
1310
+ * @throws {RequiredError}
1311
+ */
1312
+ async listDataApps(e, r, a) {
1313
+ const t = await n.listDataApps(e, r, a), o = l?.serverIndex ?? 0, s = g["DataAppsApi.listDataApps"]?.[o]?.url;
1314
+ return (c, i) => V(t, h, u, l)(c, s || i);
1315
+ }
1316
+ };
1317
+ }, Ua = function(l, n, e) {
1318
+ const r = X(l);
1319
+ return {
1320
+ /**
1321
+ * Retrieves a list of all in-package HTML data apps (static pages served from the package\'s public/ directory) within the specified package. Each entry includes the relative path, the package name, a canonical resource URL, and the title (extracted from the file\'s <title> tag, falling back to the path). Used by the Publisher SPA to surface a clickable \"Data Apps\" section on the package detail view, and by anyone who wants to discover a package\'s data apps programmatically without scraping the directory. Recursive depth is capped server-side to keep this cheap on large packages.
1322
+ * @summary List package data apps
1323
+ * @param {string} environmentName Name of the environment
1324
+ * @param {string} packageName Name of the package
1325
+ * @param {*} [options] Override http request option.
1326
+ * @throws {RequiredError}
1327
+ */
1328
+ listDataApps(a, t, o) {
1329
+ return r.listDataApps(a, t, o).then((s) => s(e, n));
1330
+ }
1331
+ };
1332
+ };
1333
+ class ve extends I {
1334
+ /**
1335
+ * Retrieves a list of all in-package HTML data apps (static pages served from the package\'s public/ directory) within the specified package. Each entry includes the relative path, the package name, a canonical resource URL, and the title (extracted from the file\'s <title> tag, falling back to the path). Used by the Publisher SPA to surface a clickable \"Data Apps\" section on the package detail view, and by anyone who wants to discover a package\'s data apps programmatically without scraping the directory. Recursive depth is capped server-side to keep this cheap on large packages.
1336
+ * @summary List package data apps
1337
+ * @param {string} environmentName Name of the environment
1338
+ * @param {string} packageName Name of the package
1339
+ * @param {*} [options] Override http request option.
1340
+ * @throws {RequiredError}
1341
+ * @memberof DataAppsApi
1342
+ */
1343
+ listDataApps(n, e, r) {
1344
+ return X(this.configuration).listDataApps(n, e, r).then((a) => a(this.axios, this.basePath));
1345
+ }
1346
+ }
1347
+ const Ve = function(l) {
1271
1348
  return {
1272
1349
  /**
1273
1350
  * Retrieves a list of all embedded databases within the specified package. These are typically local data files read by DuckDB in place (.parquet, .csv, and .xlsx) that provide local data storage for the package. Each database entry includes metadata about the database structure and content.
@@ -1292,8 +1369,8 @@ const be = function(l) {
1292
1369
  };
1293
1370
  }
1294
1371
  };
1295
- }, X = function(l) {
1296
- const n = be(l);
1372
+ }, Z = function(l) {
1373
+ const n = Ve(l);
1297
1374
  return {
1298
1375
  /**
1299
1376
  * Retrieves a list of all embedded databases within the specified package. These are typically local data files read by DuckDB in place (.parquet, .csv, and .xlsx) that provide local data storage for the package. Each database entry includes metadata about the database structure and content.
@@ -1309,8 +1386,8 @@ const be = function(l) {
1309
1386
  return (i, d) => V(o, h, u, l)(i, c || d);
1310
1387
  }
1311
1388
  };
1312
- }, Na = function(l, n, e) {
1313
- const r = X(l);
1389
+ }, wa = function(l, n, e) {
1390
+ const r = Z(l);
1314
1391
  return {
1315
1392
  /**
1316
1393
  * Retrieves a list of all embedded databases within the specified package. These are typically local data files read by DuckDB in place (.parquet, .csv, and .xlsx) that provide local data storage for the package. Each database entry includes metadata about the database structure and content.
@@ -1326,7 +1403,7 @@ const be = function(l) {
1326
1403
  }
1327
1404
  };
1328
1405
  };
1329
- class ve extends I {
1406
+ class Oe extends I {
1330
1407
  /**
1331
1408
  * Retrieves a list of all embedded databases within the specified package. These are typically local data files read by DuckDB in place (.parquet, .csv, and .xlsx) that provide local data storage for the package. Each database entry includes metadata about the database structure and content.
1332
1409
  * @summary List embedded databases
@@ -1338,10 +1415,10 @@ class ve extends I {
1338
1415
  * @memberof DatabasesApi
1339
1416
  */
1340
1417
  listDatabases(n, e, r, a) {
1341
- return X(this.configuration).listDatabases(n, e, r, a).then((t) => t(this.axios, this.basePath));
1418
+ return Z(this.configuration).listDatabases(n, e, r, a).then((t) => t(this.axios, this.basePath));
1342
1419
  }
1343
1420
  }
1344
- const Ve = function(l) {
1421
+ const Se = function(l) {
1345
1422
  return {
1346
1423
  /**
1347
1424
  * Creates a new Malloy environment with the specified configuration. An environment serves as a container for packages, connections, and other resources. The environment will be initialized with the provided metadata and can immediately accept packages and connections.
@@ -1445,7 +1522,7 @@ const Ve = function(l) {
1445
1522
  }
1446
1523
  };
1447
1524
  }, N = function(l) {
1448
- const n = Ve(l);
1525
+ const n = Se(l);
1449
1526
  return {
1450
1527
  /**
1451
1528
  * Creates a new Malloy environment with the specified configuration. An environment serves as a container for packages, connections, and other resources. The environment will be initialized with the provided metadata and can immediately accept packages and connections.
@@ -1504,7 +1581,7 @@ const Ve = function(l) {
1504
1581
  return (c, i) => V(t, h, u, l)(c, s || i);
1505
1582
  }
1506
1583
  };
1507
- }, Ta = function(l, n, e) {
1584
+ }, Ea = function(l, n, e) {
1508
1585
  const r = N(l);
1509
1586
  return {
1510
1587
  /**
@@ -1560,7 +1637,7 @@ const Ve = function(l) {
1560
1637
  }
1561
1638
  };
1562
1639
  };
1563
- class Oe extends I {
1640
+ class ye extends I {
1564
1641
  /**
1565
1642
  * Creates a new Malloy environment with the specified configuration. An environment serves as a container for packages, connections, and other resources. The environment will be initialized with the provided metadata and can immediately accept packages and connections.
1566
1643
  * @summary Create a new environment
@@ -1618,7 +1695,7 @@ class Oe extends I {
1618
1695
  return N(this.configuration).updateEnvironment(n, e, r).then((a) => a(this.axios, this.basePath));
1619
1696
  }
1620
1697
  }
1621
- const Se = function(l) {
1698
+ const ke = function(l) {
1622
1699
  return {
1623
1700
  /**
1624
1701
  * Creates a materialization and starts building. Behavior depends on the request body (see CreateMaterializationRequest): * Orchestrated build — supply `buildInstructions`. The publisher builds directly into the caller-assigned names derived from the package\'s already-compiled build plan (read off `Package.buildPlan`). Returns the materialization already building. * Auto-run (standalone, default) — omit `buildInstructions`; the publisher self-assigns names and runs all phases in one pass.
@@ -1757,7 +1834,7 @@ const Se = function(l) {
1757
1834
  }
1758
1835
  };
1759
1836
  }, A = function(l) {
1760
- const n = Se(l);
1837
+ const n = ke(l);
1761
1838
  return {
1762
1839
  /**
1763
1840
  * Creates a materialization and starts building. Behavior depends on the request body (see CreateMaterializationRequest): * Orchestrated build — supply `buildInstructions`. The publisher builds directly into the caller-assigned names derived from the package\'s already-compiled build plan (read off `Package.buildPlan`). Returns the materialization already building. * Auto-run (standalone, default) — omit `buildInstructions`; the publisher self-assigns names and runs all phases in one pass.
@@ -1841,7 +1918,7 @@ const Se = function(l) {
1841
1918
  return (d, p) => V(s, h, u, l)(d, i || p);
1842
1919
  }
1843
1920
  };
1844
- }, Ua = function(l, n, e) {
1921
+ }, Ma = function(l, n, e) {
1845
1922
  const r = A(l);
1846
1923
  return {
1847
1924
  /**
@@ -1921,7 +1998,7 @@ const Se = function(l) {
1921
1998
  }
1922
1999
  };
1923
2000
  };
1924
- class ye extends I {
2001
+ class Ce extends I {
1925
2002
  /**
1926
2003
  * Creates a materialization and starts building. Behavior depends on the request body (see CreateMaterializationRequest): * Orchestrated build — supply `buildInstructions`. The publisher builds directly into the caller-assigned names derived from the package\'s already-compiled build plan (read off `Package.buildPlan`). Returns the materialization already building. * Auto-run (standalone, default) — omit `buildInstructions`; the publisher self-assigns names and runs all phases in one pass.
1927
2004
  * @summary Create a materialization
@@ -2004,9 +2081,9 @@ class ye extends I {
2004
2081
  return A(this.configuration).materializationAction(n, e, r, a, t).then((o) => o(this.axios, this.basePath));
2005
2082
  }
2006
2083
  }
2007
- const wa = {
2084
+ const fa = {
2008
2085
  Stop: "stop"
2009
- }, ke = function(l) {
2086
+ }, Ie = function(l) {
2010
2087
  return {
2011
2088
  /**
2012
2089
  * Compiles Malloy source code in the context of a specific model file. The submitted source is appended to the full model content, giving it access to all sources, imports, and queries defined in the model. Relative imports resolve correctly against sibling model files. Returns compilation status and any problems (errors or warnings) found.
@@ -2101,7 +2178,7 @@ const wa = {
2101
2178
  }
2102
2179
  };
2103
2180
  }, w = function(l) {
2104
- const n = ke(l);
2181
+ const n = Ie(l);
2105
2182
  return {
2106
2183
  /**
2107
2184
  * Compiles Malloy source code in the context of a specific model file. The submitted source is appended to the full model content, giving it access to all sources, imports, and queries defined in the model. Relative imports resolve correctly against sibling model files. Returns compilation status and any problems (errors or warnings) found.
@@ -2159,7 +2236,7 @@ const wa = {
2159
2236
  return (i, d) => V(o, h, u, l)(i, c || d);
2160
2237
  }
2161
2238
  };
2162
- }, Ea = function(l, n, e) {
2239
+ }, Ba = function(l, n, e) {
2163
2240
  const r = w(l);
2164
2241
  return {
2165
2242
  /**
@@ -2215,7 +2292,7 @@ const wa = {
2215
2292
  }
2216
2293
  };
2217
2294
  };
2218
- class Ce extends I {
2295
+ class xe extends I {
2219
2296
  /**
2220
2297
  * Compiles Malloy source code in the context of a specific model file. The submitted source is appended to the full model content, giving it access to all sources, imports, and queries defined in the model. Relative imports resolve correctly against sibling model files. Returns compilation status and any problems (errors or warnings) found.
2221
2298
  * @summary Compile Malloy source code
@@ -2272,7 +2349,7 @@ class Ce extends I {
2272
2349
  return w(this.configuration).listModels(n, e, r, a).then((t) => t(this.axios, this.basePath));
2273
2350
  }
2274
2351
  }
2275
- const Ie = function(l) {
2352
+ const Ae = function(l) {
2276
2353
  return {
2277
2354
  /**
2278
2355
  * 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.
@@ -2348,7 +2425,7 @@ const Ie = function(l) {
2348
2425
  }
2349
2426
  };
2350
2427
  }, Q = function(l) {
2351
- const n = Ie(l);
2428
+ const n = Ae(l);
2352
2429
  return {
2353
2430
  /**
2354
2431
  * 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.
@@ -2396,7 +2473,7 @@ const Ie = function(l) {
2396
2473
  return (i, d) => V(o, h, u, l)(i, c || d);
2397
2474
  }
2398
2475
  };
2399
- }, Ma = function(l, n, e) {
2476
+ }, Fa = function(l, n, e) {
2400
2477
  const r = Q(l);
2401
2478
  return {
2402
2479
  /**
@@ -2443,7 +2520,7 @@ const Ie = function(l) {
2443
2520
  }
2444
2521
  };
2445
2522
  };
2446
- class xe extends I {
2523
+ class Re extends I {
2447
2524
  /**
2448
2525
  * 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.
2449
2526
  * @summary Execute a specific notebook cell
@@ -2490,10 +2567,10 @@ class xe extends I {
2490
2567
  return Q(this.configuration).listNotebooks(n, e, r, a).then((t) => t(this.axios, this.basePath));
2491
2568
  }
2492
2569
  }
2493
- const fa = {
2570
+ const Qa = {
2494
2571
  True: "true",
2495
2572
  False: "false"
2496
- }, Ae = function(l) {
2573
+ }, Ne = function(l) {
2497
2574
  return {
2498
2575
  /**
2499
2576
  * Creates a new Malloy package within the specified environment. A package serves as a container for models, notebooks, embedded databases, and other resources. The package will be initialized with the provided metadata and can immediately accept content.
@@ -2604,7 +2681,7 @@ const fa = {
2604
2681
  }
2605
2682
  };
2606
2683
  }, T = function(l) {
2607
- const n = Ae(l);
2684
+ const n = Ne(l);
2608
2685
  return {
2609
2686
  /**
2610
2687
  * Creates a new Malloy package within the specified environment. A package serves as a container for models, notebooks, embedded databases, and other resources. The package will be initialized with the provided metadata and can immediately accept content.
@@ -2669,7 +2746,7 @@ const fa = {
2669
2746
  return (i, d) => V(o, h, u, l)(i, c || d);
2670
2747
  }
2671
2748
  };
2672
- }, Ba = function(l, n, e) {
2749
+ }, za = function(l, n, e) {
2673
2750
  const r = T(l);
2674
2751
  return {
2675
2752
  /**
@@ -2731,7 +2808,7 @@ const fa = {
2731
2808
  }
2732
2809
  };
2733
2810
  };
2734
- class Re extends I {
2811
+ class Te extends I {
2735
2812
  /**
2736
2813
  * Creates a new Malloy package within the specified environment. A package serves as a container for models, notebooks, embedded databases, and other resources. The package will be initialized with the provided metadata and can immediately accept content.
2737
2814
  * @summary Create a new package
@@ -2795,76 +2872,6 @@ class Re extends I {
2795
2872
  return T(this.configuration).updatePackage(n, e, r, a).then((t) => t(this.axios, this.basePath));
2796
2873
  }
2797
2874
  }
2798
- const Ne = function(l) {
2799
- return {
2800
- /**
2801
- * Retrieves a list of all static HTML pages (in-package data apps) within the specified package. Each page entry includes the relative path, the package name, a canonical resource URL, and the page title (extracted from the file\'s <title> tag, falling back to the path). Used by the Publisher SPA to surface a clickable \"Pages\" section on the package detail view, and by anyone who wants to discover in-package data apps programmatically without scraping the directory. Recursive depth is capped server-side to keep this cheap on large packages.
2802
- * @summary List package pages
2803
- * @param {string} environmentName Name of the environment
2804
- * @param {string} packageName Name of the package
2805
- * @param {*} [options] Override http request option.
2806
- * @throws {RequiredError}
2807
- */
2808
- listPages: async (n, e, r = {}) => {
2809
- m("listPages", "environmentName", n), m("listPages", "packageName", e);
2810
- const a = "/environments/{environmentName}/packages/{packageName}/pages".replace("{environmentName}", encodeURIComponent(String(n))).replace("{packageName}", encodeURIComponent(String(e))), t = new URL(a, P);
2811
- let o;
2812
- l && (o = l.baseOptions);
2813
- const s = { method: "GET", ...o, ...r }, c = {};
2814
- b(t, {});
2815
- let d = o && o.headers ? o.headers : {};
2816
- return s.headers = { ...c, ...d, ...r.headers }, {
2817
- url: v(t),
2818
- options: s
2819
- };
2820
- }
2821
- };
2822
- }, Z = function(l) {
2823
- const n = Ne(l);
2824
- return {
2825
- /**
2826
- * Retrieves a list of all static HTML pages (in-package data apps) within the specified package. Each page entry includes the relative path, the package name, a canonical resource URL, and the page title (extracted from the file\'s <title> tag, falling back to the path). Used by the Publisher SPA to surface a clickable \"Pages\" section on the package detail view, and by anyone who wants to discover in-package data apps programmatically without scraping the directory. Recursive depth is capped server-side to keep this cheap on large packages.
2827
- * @summary List package pages
2828
- * @param {string} environmentName Name of the environment
2829
- * @param {string} packageName Name of the package
2830
- * @param {*} [options] Override http request option.
2831
- * @throws {RequiredError}
2832
- */
2833
- async listPages(e, r, a) {
2834
- const t = await n.listPages(e, r, a), o = l?.serverIndex ?? 0, s = g["PagesApi.listPages"]?.[o]?.url;
2835
- return (c, i) => V(t, h, u, l)(c, s || i);
2836
- }
2837
- };
2838
- }, Fa = function(l, n, e) {
2839
- const r = Z(l);
2840
- return {
2841
- /**
2842
- * Retrieves a list of all static HTML pages (in-package data apps) within the specified package. Each page entry includes the relative path, the package name, a canonical resource URL, and the page title (extracted from the file\'s <title> tag, falling back to the path). Used by the Publisher SPA to surface a clickable \"Pages\" section on the package detail view, and by anyone who wants to discover in-package data apps programmatically without scraping the directory. Recursive depth is capped server-side to keep this cheap on large packages.
2843
- * @summary List package pages
2844
- * @param {string} environmentName Name of the environment
2845
- * @param {string} packageName Name of the package
2846
- * @param {*} [options] Override http request option.
2847
- * @throws {RequiredError}
2848
- */
2849
- listPages(a, t, o) {
2850
- return r.listPages(a, t, o).then((s) => s(e, n));
2851
- }
2852
- };
2853
- };
2854
- class Te extends I {
2855
- /**
2856
- * Retrieves a list of all static HTML pages (in-package data apps) within the specified package. Each page entry includes the relative path, the package name, a canonical resource URL, and the page title (extracted from the file\'s <title> tag, falling back to the path). Used by the Publisher SPA to surface a clickable \"Pages\" section on the package detail view, and by anyone who wants to discover in-package data apps programmatically without scraping the directory. Recursive depth is capped server-side to keep this cheap on large packages.
2857
- * @summary List package pages
2858
- * @param {string} environmentName Name of the environment
2859
- * @param {string} packageName Name of the package
2860
- * @param {*} [options] Override http request option.
2861
- * @throws {RequiredError}
2862
- * @memberof PagesApi
2863
- */
2864
- listPages(n, e, r) {
2865
- return Z(this.configuration).listPages(n, e, r).then((a) => a(this.axios, this.basePath));
2866
- }
2867
- }
2868
2875
  const Ue = function(l) {
2869
2876
  return {
2870
2877
  /**
@@ -2987,7 +2994,7 @@ const Ue = function(l) {
2987
2994
  return (s, c) => V(a, h, u, l)(s, o || c);
2988
2995
  }
2989
2996
  };
2990
- }, Qa = function(l, n, e) {
2997
+ }, $a = function(l, n, e) {
2991
2998
  const r = E(l);
2992
2999
  return {
2993
3000
  /**
@@ -3199,7 +3206,7 @@ const Ee = function(l) {
3199
3206
  return (c, i) => V(t, h, u, l)(c, s || i);
3200
3207
  }
3201
3208
  };
3202
- }, za = function(l, n, e) {
3209
+ }, qa = function(l, n, e) {
3203
3210
  const r = M(l);
3204
3211
  return {
3205
3212
  /**
@@ -3375,21 +3382,21 @@ const B = {
3375
3382
  // right wing of the M (semantic models)
3376
3383
  darkBlue: "#1474a4"
3377
3384
  // deep shadow of the M (package data)
3378
- }, $a = '"JetBrains Mono", "ui-monospace", "SFMono-Regular", "Menlo", monospace', qa = k(Y)({
3385
+ }, La = '"JetBrains Mono", "ui-monospace", "SFMono-Regular", "Menlo", monospace', ja = k(Y)({
3379
3386
  display: "flex",
3380
3387
  flexDirection: "column",
3381
3388
  height: "100%",
3382
3389
  boxShadow: "none",
3383
3390
  border: "none",
3384
3391
  backgroundColor: "transparent"
3385
- }), La = k(J)({
3392
+ }), Da = k(J)({
3386
3393
  display: "flex",
3387
3394
  flexDirection: "column",
3388
3395
  padding: "0",
3389
3396
  flexGrow: 1
3390
- }), ja = k(me)({
3397
+ }), Ha = k(me)({
3391
3398
  padding: "0"
3392
- }), Ha = k("div")(({ theme: l }) => ({
3399
+ }), Wa = k("div")(({ theme: l }) => ({
3393
3400
  backgroundColor: l.palette.background.default,
3394
3401
  padding: "0 8px 0px 8px",
3395
3402
  borderRadius: "12px",
@@ -3403,19 +3410,19 @@ k("div")(({ theme: l }) => ({
3403
3410
  paddingBottom: "24px",
3404
3411
  borderBottom: `1px solid ${l.palette.divider}`
3405
3412
  }));
3406
- const Da = k("div")({
3413
+ const _a = k("div")({
3407
3414
  marginBottom: "48px",
3408
3415
  padding: "0",
3409
3416
  backgroundColor: "transparent",
3410
3417
  border: "none",
3411
3418
  boxShadow: "none"
3412
- }), Wa = k("div")({
3419
+ }), Ga = k("div")({
3413
3420
  marginBottom: "0",
3414
3421
  padding: "0",
3415
3422
  backgroundColor: "transparent",
3416
3423
  border: "none",
3417
3424
  boxShadow: "none"
3418
- }), _a = k("div")({
3425
+ }), Ya = k("div")({
3419
3426
  backgroundColor: "transparent",
3420
3427
  paddingTop: "12px",
3421
3428
  paddingBottom: "2px",
@@ -3445,7 +3452,7 @@ k("div")(({ theme: l }) => ({
3445
3452
  justifyContent: "space-between",
3446
3453
  alignItems: "center"
3447
3454
  }));
3448
- const Ga = k("div")({
3455
+ const Ja = k("div")({
3449
3456
  height: "100%"
3450
3457
  });
3451
3458
  k("div")({
@@ -3455,7 +3462,7 @@ k("div")({
3455
3462
  padding: "4px",
3456
3463
  alignItems: "center"
3457
3464
  });
3458
- const Ya = k("div")({
3465
+ const Ka = k("div")({
3459
3466
  height: "75vh",
3460
3467
  width: "100%",
3461
3468
  overflowY: "auto"
@@ -3465,7 +3472,7 @@ k("div")({
3465
3472
  height: "100%",
3466
3473
  flex: "0 0 auto"
3467
3474
  });
3468
- const Ja = k(Y)(({ theme: l }) => ({
3475
+ const Xa = k(Y)(({ theme: l }) => ({
3469
3476
  backgroundColor: l.palette.background.paper,
3470
3477
  padding: "24px",
3471
3478
  borderRadius: "8px",
@@ -3476,12 +3483,12 @@ const Ja = k(Y)(({ theme: l }) => ({
3476
3483
  "&:hover": {
3477
3484
  boxShadow: "0 2px 6px rgba(0, 0, 0, 0.08)"
3478
3485
  }
3479
- })), Ka = k(J)({
3486
+ })), Za = k(J)({
3480
3487
  padding: "0",
3481
3488
  "&:last-child": {
3482
3489
  paddingBottom: "0"
3483
3490
  }
3484
- }), Xa = k("div")(({ theme: l }) => ({
3491
+ }), et = k("div")(({ theme: l }) => ({
3485
3492
  fontSize: "0.875rem",
3486
3493
  fontWeight: 500,
3487
3494
  color: l.palette.text.secondary,
@@ -3643,7 +3650,7 @@ function $e({
3643
3650
  );
3644
3651
  return /* @__PURE__ */ F(ae.Provider, { value: s, children: t });
3645
3652
  }
3646
- function Za() {
3653
+ function at() {
3647
3654
  const l = G(ae);
3648
3655
  return l || {
3649
3656
  theme: ee([], "light"),
@@ -3666,7 +3673,7 @@ const qe = new le({
3666
3673
  throwOnError: !1
3667
3674
  }
3668
3675
  }
3669
- }), et = {
3676
+ }), tt = {
3670
3677
  staleTime: 300 * 1e3,
3671
3678
  refetchOnWindowFocus: !1,
3672
3679
  refetchOnReconnect: !1
@@ -3686,11 +3693,11 @@ function je(l) {
3686
3693
  } catch {
3687
3694
  }
3688
3695
  }
3689
- function He() {
3696
+ function De() {
3690
3697
  return typeof window > "u" || !window.matchMedia ? !1 : window.matchMedia("(prefers-color-scheme: dark)").matches;
3691
3698
  }
3692
3699
  h.defaults.baseURL || (h.defaults.baseURL = "IfYouAreSeeingThis_baseURL_IsNotSet");
3693
- const te = _(void 0), De = (l, n) => {
3700
+ const te = _(void 0), He = (l, n) => {
3694
3701
  const e = `${window.location.protocol}//${window.location.host}/api/v0`, r = h.create({
3695
3702
  baseURL: l || e,
3696
3703
  withCredentials: !0,
@@ -3702,22 +3709,22 @@ const te = _(void 0), De = (l, n) => {
3702
3709
  });
3703
3710
  const a = new fe({ basePath: e });
3704
3711
  return {
3705
- models: new Ce(a, e, r),
3712
+ models: new xe(a, e, r),
3706
3713
  publisher: new we(a, e, r),
3707
- environments: new Oe(a, e, r),
3708
- packages: new Re(a, e, r),
3709
- pages: new Te(a, e, r),
3710
- notebooks: new xe(a, e, r),
3714
+ environments: new ye(a, e, r),
3715
+ packages: new Te(a, e, r),
3716
+ dataApps: new ve(a, e, r),
3717
+ notebooks: new Re(a, e, r),
3711
3718
  connections: new ge(a, e, r),
3712
- databases: new ve(a, e, r),
3713
- materializations: new ye(
3719
+ databases: new Oe(a, e, r),
3720
+ materializations: new Ce(
3714
3721
  a,
3715
3722
  e,
3716
3723
  r
3717
3724
  ),
3718
3725
  watchMode: new Me(a, e, r)
3719
3726
  };
3720
- }, at = (l) => /* @__PURE__ */ F(ce, { client: qe, children: /* @__PURE__ */ F(We, { ...l }) }), We = ({
3727
+ }, nt = (l) => /* @__PURE__ */ F(ce, { client: qe, children: /* @__PURE__ */ F(We, { ...l }) }), We = ({
3721
3728
  children: l,
3722
3729
  getAccessToken: n,
3723
3730
  baseURL: e,
@@ -3725,7 +3732,7 @@ const te = _(void 0), De = (l, n) => {
3725
3732
  theme: a
3726
3733
  }) => {
3727
3734
  const t = f(
3728
- () => De(e, n),
3735
+ () => He(e, n),
3729
3736
  [e, n]
3730
3737
  ), o = e || `${window.location.protocol}//${window.location.host}/api/v0`, s = ie({
3731
3738
  queryKey: ["status"],
@@ -3738,13 +3745,13 @@ const te = _(void 0), De = (l, n) => {
3738
3745
  const O = f(
3739
3746
  () => [i, a],
3740
3747
  [i, a]
3741
- ), [C, U] = D(
3748
+ ), [C, U] = H(
3742
3749
  Le
3743
- ), [x, z] = D(He);
3750
+ ), [x, z] = H(De);
3744
3751
  de(() => {
3745
3752
  if (typeof window > "u" || !window.matchMedia) return;
3746
- const R = window.matchMedia("(prefers-color-scheme: dark)"), H = (se) => z(se.matches);
3747
- return R.addEventListener("change", H), () => R.removeEventListener("change", H);
3753
+ const R = window.matchMedia("(prefers-color-scheme: dark)"), D = (se) => z(se.matches);
3754
+ return R.addEventListener("change", D), () => R.removeEventListener("change", D);
3748
3755
  }, []);
3749
3756
  const ne = pe((R) => {
3750
3757
  U(R), je(R);
@@ -3774,110 +3781,112 @@ const te = _(void 0), De = (l, n) => {
3774
3781
  children: l
3775
3782
  }
3776
3783
  ) });
3777
- }, tt = () => {
3784
+ }, rt = () => {
3778
3785
  const l = G(te);
3779
3786
  if (l === void 0)
3780
3787
  throw new Error("useServer must be used within a ServerProvider");
3781
3788
  return l;
3782
3789
  };
3783
3790
  export {
3784
- w as $,
3791
+ ke as $,
3785
3792
  Xe as A,
3786
- be as B,
3793
+ Na as B,
3787
3794
  ea as C,
3788
3795
  oa as D,
3789
- X as E,
3790
- sa as F,
3791
- ca as G,
3792
- Na as H,
3793
- ve as I,
3794
- Ve as J,
3795
- N as K,
3796
- ia as L,
3797
- da as M,
3798
- ma as N,
3799
- Ta as O,
3800
- ua as P,
3801
- Oa as Q,
3802
- ya as R,
3803
- at as S,
3804
- Ia as T,
3805
- Oe as U,
3806
- Se as V,
3807
- A as W,
3808
- Ua as X,
3809
- ye as Y,
3810
- wa as Z,
3811
- ke as _,
3796
+ Ta as E,
3797
+ la as F,
3798
+ ia as G,
3799
+ be as H,
3800
+ X as I,
3801
+ Ua as J,
3802
+ ve as K,
3803
+ da as L,
3804
+ ma as M,
3805
+ ga as N,
3806
+ Ve as O,
3807
+ ba as P,
3808
+ ya as Q,
3809
+ Ca as R,
3810
+ nt as S,
3811
+ Aa as T,
3812
+ Z as U,
3813
+ wa as V,
3814
+ Oe as W,
3815
+ Se as X,
3816
+ N as Y,
3817
+ Ea as Z,
3818
+ ye as _,
3812
3819
  Ze as a,
3813
- Ea as a0,
3814
- Ce as a1,
3815
- Ie as a2,
3816
- Q as a3,
3817
- Ma as a4,
3818
- xe as a5,
3819
- fa as a6,
3820
- Ae as a7,
3821
- T as a8,
3822
- Ba as a9,
3823
- Wa as aA,
3824
- _a as aB,
3825
- Ha as aC,
3826
- Da as aD,
3827
- Qe as aE,
3828
- ee as aF,
3829
- W as aG,
3830
- ze as aH,
3831
- $e as aI,
3832
- Re as aa,
3833
- Ne as ab,
3834
- Z as ac,
3835
- Fa as ad,
3836
- Te as ae,
3837
- Ue as af,
3838
- E as ag,
3839
- Qa as ah,
3840
- we as ai,
3841
- Ee as aj,
3842
- M as ak,
3843
- za as al,
3844
- Me as am,
3845
- fe as an,
3846
- ja as ao,
3847
- Ga as ap,
3848
- Ya as aq,
3849
- Za as ar,
3850
- qa as as,
3851
- La as at,
3852
- $a as au,
3853
- Ja as av,
3854
- Ka as aw,
3820
+ A as a0,
3821
+ Ma as a1,
3822
+ Ce as a2,
3823
+ fa as a3,
3824
+ Ie as a4,
3825
+ w as a5,
3826
+ Ba as a6,
3827
+ xe as a7,
3828
+ Ae as a8,
3829
+ Q as a9,
3830
+ B as aA,
3831
+ tt as aB,
3832
+ Ga as aC,
3833
+ Ya as aD,
3834
+ Wa as aE,
3835
+ _a as aF,
3836
+ Qe as aG,
3837
+ ee as aH,
3838
+ W as aI,
3839
+ ze as aJ,
3840
+ $e as aK,
3841
+ Fa as aa,
3842
+ Re as ab,
3843
+ Qa as ac,
3844
+ Ne as ad,
3845
+ T as ae,
3846
+ za as af,
3847
+ Te as ag,
3848
+ Ue as ah,
3849
+ E as ai,
3850
+ $a as aj,
3851
+ we as ak,
3852
+ Ee as al,
3853
+ M as am,
3854
+ qa as an,
3855
+ Me as ao,
3856
+ fe as ap,
3857
+ Ha as aq,
3858
+ Ja as ar,
3859
+ Ka as as,
3860
+ at,
3861
+ ja as au,
3862
+ Da as av,
3863
+ La as aw,
3855
3864
  Xa as ax,
3856
- B as ay,
3865
+ Za as ay,
3857
3866
  et as az,
3858
3867
  aa as b,
3859
3868
  ta as c,
3860
3869
  na as d,
3861
3870
  ra as e,
3862
- la as f,
3871
+ sa as f,
3863
3872
  qe as g,
3864
- pa as h,
3865
- ha as i,
3866
- ga as j,
3867
- Pa as k,
3868
- ba as l,
3873
+ ca as h,
3874
+ pa as i,
3875
+ ha as j,
3876
+ ua as k,
3877
+ Pa as l,
3869
3878
  va as m,
3870
3879
  Va as n,
3871
- Sa as o,
3872
- ka as p,
3873
- Ca as q,
3874
- ue as r,
3875
- S as s,
3876
- xa as t,
3877
- tt as u,
3878
- ge as v,
3879
- Pe as w,
3880
- K as x,
3881
- Aa as y,
3882
- Ra as z
3880
+ Oa as o,
3881
+ Sa as p,
3882
+ ka as q,
3883
+ Ia as r,
3884
+ xa as s,
3885
+ ue as t,
3886
+ rt as u,
3887
+ S as v,
3888
+ Ra as w,
3889
+ ge as x,
3890
+ Pe as y,
3891
+ K as z
3883
3892
  };