@fluid-app/fluid-cli-portal 0.1.58 → 0.1.60

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.
@@ -1,11 +1,11 @@
1
- import { D as fluidOsV0UpdateFluidOsscreen, E as fluidOsV0UpdateFluidOsprofile, O as fluidOsV0UpdateFluidOstheme, S as fluidOsV0ListFluidOsversions, T as fluidOsV0UpdateFluidOsnavigationItem, _ as fluidOsV0ListFluidOsnavigationItems, a as fluidOsV0CreateFluidOsscreen, b as fluidOsV0ListFluidOsscreens, d as fluidOsV0DeleteFluidOsnavigationItem, f as fluidOsV0DeleteFluidOsprofile, g as fluidOsV0ListFluidOsdefinitions, h as fluidOsV0GetFluidOsscreen, i as fluidOsV0CreateFluidOsprofile, k as fluidOsV0UpdateFluidOsversion, m as fluidOsV0DeleteFluidOstheme, n as fluidOsV0CreateFluidOsnavigation, o as fluidOsV0CreateFluidOstheme, p as fluidOsV0DeleteFluidOsscreen, r as fluidOsV0CreateFluidOsnavigationItem, s as fluidOsV0CreateFluidOsversion, u as fluidOsV0DeleteFluidOsnavigation, v as fluidOsV0ListFluidOsnavigations, w as fluidOsV0UpdateFluidOsnavigation, x as fluidOsV0ListFluidOsthemes, y as fluidOsV0ListFluidOsprofiles } from "./sdk.gen-VRGYiLVJ.mjs";
1
+ import { C as fluidOsV0ListWidgetPackages, D as fluidOsV0UpdateFluidOsscreen, E as fluidOsV0UpdateFluidOsprofile, O as fluidOsV0UpdateFluidOstheme, S as fluidOsV0ListFluidOsversions, T as fluidOsV0UpdateFluidOsnavigationItem, _ as fluidOsV0ListFluidOsnavigationItems, a as fluidOsV0CreateFluidOsscreen, b as fluidOsV0ListFluidOsscreens, d as fluidOsV0DeleteFluidOsnavigationItem, f as fluidOsV0DeleteFluidOsprofile, g as fluidOsV0ListFluidOsdefinitions, h as fluidOsV0GetFluidOsscreen, i as fluidOsV0CreateFluidOsprofile, k as fluidOsV0UpdateFluidOsversion, m as fluidOsV0DeleteFluidOstheme, n as fluidOsV0CreateFluidOsnavigation, o as fluidOsV0CreateFluidOstheme, p as fluidOsV0DeleteFluidOsscreen, r as fluidOsV0CreateFluidOsnavigationItem, s as fluidOsV0CreateFluidOsversion, u as fluidOsV0DeleteFluidOsnavigation, v as fluidOsV0ListFluidOsnavigations, w as fluidOsV0UpdateFluidOsnavigation, x as fluidOsV0ListFluidOsthemes, y as fluidOsV0ListFluidOsprofiles } from "./sdk.gen-VRGYiLVJ.mjs";
2
2
  import "node:module";
3
3
  import { Command } from "commander";
4
4
  import chalk from "chalk";
5
5
  import ora from "ora";
6
6
  import { dirname, join, relative, sep } from "node:path";
7
7
  import { existsSync } from "node:fs";
8
- import { lstat, mkdir, readFile, readdir, rename, rm, stat, unlink, writeFile } from "node:fs/promises";
8
+ import { mkdir, readFile, readdir, rename, rm, stat, unlink, writeFile } from "node:fs/promises";
9
9
  import { getActiveProfile, getAuthToken } from "@fluid-app/fluid-cli";
10
10
  import prompts from "prompts";
11
11
  import { createHash, randomBytes } from "node:crypto";
@@ -42,23 +42,6 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
42
42
  enumerable: true
43
43
  }) : target, mod));
44
44
  //#endregion
45
- //#region src/utils/standalone-portal.ts
46
- const STANDALONE_PORTAL_MARKER = ".fluid-portal.json";
47
- /**
48
- * Standalone portal definitions never synchronize with Fluid OS. Check only
49
- * for marker presence here: an unreadable or malformed marker must not turn a
50
- * local-only project into an accidental remote target.
51
- */
52
- async function assertStandalonePortalRemoteActionAllowed(projectDirectory, action) {
53
- try {
54
- await lstat(join(projectDirectory, STANDALONE_PORTAL_MARKER));
55
- } catch (error) {
56
- if (typeof error === "object" && error !== null && "code" in error && error.code === "ENOENT") return;
57
- throw error;
58
- }
59
- throw new Error(`This is a standalone Portal SDK project. It is local-only in Fluid; portal/ is the source of truth, and Fluid portal pull, push, version, and publish commands do not apply. Local SDK portal publishing will be added with Vercel hosting. ${action} was refused.`);
60
- }
61
- //#endregion
62
45
  //#region src/commands/pull-definition.ts
63
46
  /** Pick a definition by explicit id, else by name.
64
47
  *
@@ -841,6 +824,7 @@ function createFluidOsClient(options) {
841
824
  });
842
825
  }
843
826
  const fluidOsApi = {
827
+ listWidgetPackages: (client) => fluidOsV0ListWidgetPackages({ client }),
844
828
  listDefinitions: (client, query) => fluidOsV0ListFluidOsdefinitions({
845
829
  client,
846
830
  query
@@ -1249,19 +1233,57 @@ async function diffAgainstSnapshot(portalDir, snapshot) {
1249
1233
  * and records the definition metadata.
1250
1234
  */
1251
1235
  async function buildSnapshot(portalDir, definitionName, definitionId) {
1252
- const hashEntries = await mapWithLimit(await collectFiles(portalDir), MAX_CONCURRENCY, async (filePath) => {
1236
+ const files = await collectFiles(portalDir);
1237
+ const hashEntries = await mapWithLimit(files, MAX_CONCURRENCY, async (filePath) => {
1253
1238
  return [filePath, await computeFileHash(join(portalDir, filePath))];
1254
1239
  });
1255
1240
  hashEntries.sort(([a], [b]) => a.localeCompare(b));
1256
1241
  const fileHashes = {};
1257
1242
  for (const [path, hash] of hashEntries) fileHashes[path] = hash;
1243
+ const networkWidgetGrants = await collectSnapshotNetworkWidgetGrants(portalDir, files);
1258
1244
  return {
1259
1245
  definition: definitionName,
1260
1246
  definition_id: definitionId,
1261
1247
  pulled_at: (/* @__PURE__ */ new Date()).toISOString(),
1262
- files: fileHashes
1248
+ files: fileHashes,
1249
+ network_widget_grants: networkWidgetGrants
1263
1250
  };
1264
1251
  }
1252
+ async function collectSnapshotNetworkWidgetGrants(portalDir, files) {
1253
+ const entries = await mapWithLimit(files.filter((file) => file.startsWith("screens/") && file.endsWith(".json")), MAX_CONCURRENCY, async (file) => {
1254
+ try {
1255
+ return [file, collectNetworkWidgetGrants(JSON.parse(await readFile(join(portalDir, file), "utf8")))];
1256
+ } catch {
1257
+ return [file, []];
1258
+ }
1259
+ });
1260
+ return Object.fromEntries(entries.filter(([, grants]) => grants.length > 0));
1261
+ }
1262
+ function collectNetworkWidgetGrants(value) {
1263
+ const grants = [];
1264
+ const visit = (candidate) => {
1265
+ if (!candidate || typeof candidate !== "object") return;
1266
+ if (Array.isArray(candidate)) {
1267
+ for (const item of candidate) visit(item);
1268
+ return;
1269
+ }
1270
+ const record = candidate;
1271
+ const networkAccess = asRecord(asRecord(record.capabilityGrants)?.networkAccess);
1272
+ if (typeof record.id === "string" && typeof record.type === "string" && typeof networkAccess?.packageId === "string" && typeof networkAccess.packageVersion === "string" && typeof networkAccess.capabilityVersion === "string") grants.push({
1273
+ widgetId: record.id,
1274
+ widgetType: record.type,
1275
+ packageId: networkAccess.packageId,
1276
+ packageVersion: networkAccess.packageVersion,
1277
+ capabilityVersion: networkAccess.capabilityVersion
1278
+ });
1279
+ for (const child of Object.values(record)) visit(child);
1280
+ };
1281
+ visit(value);
1282
+ return grants;
1283
+ }
1284
+ function asRecord(value) {
1285
+ return value !== null && typeof value === "object" && !Array.isArray(value) ? value : void 0;
1286
+ }
1265
1287
  //#endregion
1266
1288
  //#region ../../../node_modules/.pnpm/colorjs.io@0.5.2/node_modules/colorjs.io/dist/color.js
1267
1289
  function multiplyMatrices(A, B) {
@@ -6692,7 +6714,7 @@ function transformProfile(profile, navIdToSlug, themeIdToSlug) {
6692
6714
  }
6693
6715
  };
6694
6716
  }
6695
- const PORTAL_SCHEMA_BASE_URL = `https://assets.fluid.app/docs/schema/portal/1.0.0`;
6717
+ const PORTAL_SCHEMA_BASE_URL = `https://assets.fluid.app/docs/schema/portal/1.1.0`;
6696
6718
  const PORTAL_RESOURCE_KINDS = [
6697
6719
  "definition",
6698
6720
  "screen",
@@ -12967,7 +12989,7 @@ var require__2020 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
12967
12989
  const generatedSchemas = {
12968
12990
  "data-source": {
12969
12991
  $schema: "https://json-schema.org/draft/2020-12/schema",
12970
- $id: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json",
12992
+ $id: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json",
12971
12993
  title: "Fluid Portal Data Source",
12972
12994
  type: "object",
12973
12995
  properties: {
@@ -13148,7 +13170,7 @@ const generatedSchemas = {
13148
13170
  },
13149
13171
  "theme-config": {
13150
13172
  $schema: "https://json-schema.org/draft/2020-12/schema",
13151
- $id: "https://assets.fluid.app/docs/schema/portal/1.0.0/theme-config.schema.json",
13173
+ $id: "https://assets.fluid.app/docs/schema/portal/1.1.0/theme-config.schema.json",
13152
13174
  title: "Fluid Portal Structured Theme Configuration",
13153
13175
  type: "object",
13154
13176
  properties: {
@@ -13720,7 +13742,7 @@ const generatedSchemas = {
13720
13742
  },
13721
13743
  widget: {
13722
13744
  $schema: "https://json-schema.org/draft/2020-12/schema",
13723
- $id: "https://assets.fluid.app/docs/schema/portal/1.0.0/widget.schema.json",
13745
+ $id: "https://assets.fluid.app/docs/schema/portal/1.1.0/widget.schema.json",
13724
13746
  title: "Fluid Portal Widget Node",
13725
13747
  $ref: "#/$defs/widgetNode",
13726
13748
  $defs: {
@@ -13901,7 +13923,7 @@ const generatedSchemas = {
13901
13923
  },
13902
13924
  additionalProperties: false
13903
13925
  },
13904
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
13926
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
13905
13927
  columnIndex: {
13906
13928
  type: "integer",
13907
13929
  minimum: 0
@@ -14024,7 +14046,7 @@ const generatedSchemas = {
14024
14046
  },
14025
14047
  additionalProperties: false
14026
14048
  },
14027
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
14049
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
14028
14050
  columnIndex: {
14029
14051
  type: "integer",
14030
14052
  minimum: 0
@@ -14141,7 +14163,7 @@ const generatedSchemas = {
14141
14163
  },
14142
14164
  additionalProperties: false
14143
14165
  },
14144
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
14166
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
14145
14167
  columnIndex: {
14146
14168
  type: "integer",
14147
14169
  minimum: 0
@@ -14279,7 +14301,7 @@ const generatedSchemas = {
14279
14301
  },
14280
14302
  additionalProperties: false
14281
14303
  },
14282
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
14304
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
14283
14305
  columnIndex: {
14284
14306
  type: "integer",
14285
14307
  minimum: 0
@@ -14447,7 +14469,7 @@ const generatedSchemas = {
14447
14469
  },
14448
14470
  additionalProperties: false
14449
14471
  },
14450
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
14472
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
14451
14473
  columnIndex: {
14452
14474
  type: "integer",
14453
14475
  minimum: 0
@@ -14565,7 +14587,7 @@ const generatedSchemas = {
14565
14587
  },
14566
14588
  additionalProperties: false
14567
14589
  },
14568
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
14590
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
14569
14591
  columnIndex: {
14570
14592
  type: "integer",
14571
14593
  minimum: 0
@@ -14694,7 +14716,7 @@ const generatedSchemas = {
14694
14716
  },
14695
14717
  additionalProperties: false
14696
14718
  },
14697
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
14719
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
14698
14720
  columnIndex: {
14699
14721
  type: "integer",
14700
14722
  minimum: 0
@@ -14751,7 +14773,7 @@ const generatedSchemas = {
14751
14773
  },
14752
14774
  additionalProperties: false
14753
14775
  },
14754
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
14776
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
14755
14777
  columnIndex: {
14756
14778
  type: "integer",
14757
14779
  minimum: 0
@@ -14851,7 +14873,7 @@ const generatedSchemas = {
14851
14873
  },
14852
14874
  additionalProperties: false
14853
14875
  },
14854
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
14876
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
14855
14877
  columnIndex: {
14856
14878
  type: "integer",
14857
14879
  minimum: 0
@@ -14925,7 +14947,7 @@ const generatedSchemas = {
14925
14947
  },
14926
14948
  additionalProperties: false
14927
14949
  },
14928
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
14950
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
14929
14951
  columnIndex: {
14930
14952
  type: "integer",
14931
14953
  minimum: 0
@@ -15017,7 +15039,7 @@ const generatedSchemas = {
15017
15039
  },
15018
15040
  additionalProperties: false
15019
15041
  },
15020
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
15042
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
15021
15043
  columnIndex: {
15022
15044
  type: "integer",
15023
15045
  minimum: 0
@@ -15141,7 +15163,7 @@ const generatedSchemas = {
15141
15163
  },
15142
15164
  additionalProperties: false
15143
15165
  },
15144
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
15166
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
15145
15167
  columnIndex: {
15146
15168
  type: "integer",
15147
15169
  minimum: 0
@@ -15393,7 +15415,7 @@ const generatedSchemas = {
15393
15415
  },
15394
15416
  additionalProperties: false
15395
15417
  },
15396
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
15418
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
15397
15419
  columnIndex: {
15398
15420
  type: "integer",
15399
15421
  minimum: 0
@@ -15464,7 +15486,7 @@ const generatedSchemas = {
15464
15486
  },
15465
15487
  additionalProperties: false
15466
15488
  },
15467
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
15489
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
15468
15490
  columnIndex: {
15469
15491
  type: "integer",
15470
15492
  minimum: 0
@@ -15604,7 +15626,7 @@ const generatedSchemas = {
15604
15626
  },
15605
15627
  additionalProperties: false
15606
15628
  },
15607
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
15629
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
15608
15630
  columnIndex: {
15609
15631
  type: "integer",
15610
15632
  minimum: 0
@@ -15730,7 +15752,7 @@ const generatedSchemas = {
15730
15752
  },
15731
15753
  additionalProperties: false
15732
15754
  },
15733
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
15755
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
15734
15756
  columnIndex: {
15735
15757
  type: "integer",
15736
15758
  minimum: 0
@@ -16146,7 +16168,7 @@ const generatedSchemas = {
16146
16168
  },
16147
16169
  additionalProperties: false
16148
16170
  },
16149
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
16171
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
16150
16172
  columnIndex: {
16151
16173
  type: "integer",
16152
16174
  minimum: 0
@@ -16262,7 +16284,7 @@ const generatedSchemas = {
16262
16284
  },
16263
16285
  additionalProperties: false
16264
16286
  },
16265
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
16287
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
16266
16288
  columnIndex: {
16267
16289
  type: "integer",
16268
16290
  minimum: 0
@@ -16384,7 +16406,7 @@ const generatedSchemas = {
16384
16406
  },
16385
16407
  additionalProperties: false
16386
16408
  },
16387
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
16409
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
16388
16410
  columnIndex: {
16389
16411
  type: "integer",
16390
16412
  minimum: 0
@@ -16447,7 +16469,7 @@ const generatedSchemas = {
16447
16469
  },
16448
16470
  additionalProperties: false
16449
16471
  },
16450
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
16472
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
16451
16473
  columnIndex: {
16452
16474
  type: "integer",
16453
16475
  minimum: 0
@@ -16547,7 +16569,7 @@ const generatedSchemas = {
16547
16569
  },
16548
16570
  additionalProperties: false
16549
16571
  },
16550
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
16572
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
16551
16573
  columnIndex: {
16552
16574
  type: "integer",
16553
16575
  minimum: 0
@@ -16576,7 +16598,7 @@ const generatedSchemas = {
16576
16598
  } },
16577
16599
  additionalProperties: false
16578
16600
  },
16579
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
16601
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
16580
16602
  columnIndex: {
16581
16603
  type: "integer",
16582
16604
  minimum: 0
@@ -16712,7 +16734,7 @@ const generatedSchemas = {
16712
16734
  },
16713
16735
  additionalProperties: false
16714
16736
  },
16715
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
16737
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
16716
16738
  columnIndex: {
16717
16739
  type: "integer",
16718
16740
  minimum: 0
@@ -16845,7 +16867,7 @@ const generatedSchemas = {
16845
16867
  },
16846
16868
  additionalProperties: false
16847
16869
  },
16848
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
16870
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
16849
16871
  columnIndex: {
16850
16872
  type: "integer",
16851
16873
  minimum: 0
@@ -16964,7 +16986,7 @@ const generatedSchemas = {
16964
16986
  },
16965
16987
  additionalProperties: false
16966
16988
  },
16967
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
16989
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
16968
16990
  columnIndex: {
16969
16991
  type: "integer",
16970
16992
  minimum: 0
@@ -17056,7 +17078,7 @@ const generatedSchemas = {
17056
17078
  },
17057
17079
  additionalProperties: false
17058
17080
  },
17059
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
17081
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
17060
17082
  columnIndex: {
17061
17083
  type: "integer",
17062
17084
  minimum: 0
@@ -17084,10 +17106,37 @@ const generatedSchemas = {
17084
17106
  type: "object",
17085
17107
  additionalProperties: { $ref: "#/$defs/jsonValue" }
17086
17108
  },
17087
- dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/data-source.schema.json" },
17109
+ dataSource: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/data-source.schema.json" },
17088
17110
  columnIndex: {
17089
17111
  type: "integer",
17090
17112
  minimum: 0
17113
+ },
17114
+ capabilityGrants: {
17115
+ type: "object",
17116
+ properties: { networkAccess: {
17117
+ type: "object",
17118
+ properties: {
17119
+ packageId: {
17120
+ type: "string",
17121
+ pattern: "\\S"
17122
+ },
17123
+ packageVersion: {
17124
+ type: "string",
17125
+ pattern: "\\S"
17126
+ },
17127
+ capabilityVersion: {
17128
+ type: "string",
17129
+ pattern: "\\S"
17130
+ }
17131
+ },
17132
+ required: [
17133
+ "packageId",
17134
+ "packageVersion",
17135
+ "capabilityVersion"
17136
+ ],
17137
+ additionalProperties: false
17138
+ } },
17139
+ additionalProperties: false
17091
17140
  }
17092
17141
  },
17093
17142
  required: [
@@ -17102,7 +17151,7 @@ const generatedSchemas = {
17102
17151
  },
17103
17152
  definition: {
17104
17153
  $schema: "https://json-schema.org/draft/2020-12/schema",
17105
- $id: "https://assets.fluid.app/docs/schema/portal/1.0.0/definition.schema.json",
17154
+ $id: "https://assets.fluid.app/docs/schema/portal/1.1.0/definition.schema.json",
17106
17155
  title: "Fluid Portal Definition",
17107
17156
  type: "object",
17108
17157
  properties: {
@@ -17117,7 +17166,7 @@ const generatedSchemas = {
17117
17166
  },
17118
17167
  screen: {
17119
17168
  $schema: "https://json-schema.org/draft/2020-12/schema",
17120
- $id: "https://assets.fluid.app/docs/schema/portal/1.0.0/screen.schema.json",
17169
+ $id: "https://assets.fluid.app/docs/schema/portal/1.1.0/screen.schema.json",
17121
17170
  title: "Fluid Portal Screen",
17122
17171
  type: "object",
17123
17172
  properties: {
@@ -17129,7 +17178,7 @@ const generatedSchemas = {
17129
17178
  component_tree: {
17130
17179
  type: "array",
17131
17180
  maxItems: 1,
17132
- items: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/widget.schema.json" }
17181
+ items: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/widget.schema.json" }
17133
17182
  }
17134
17183
  },
17135
17184
  required: ["name", "component_tree"],
@@ -17137,7 +17186,7 @@ const generatedSchemas = {
17137
17186
  },
17138
17187
  theme: {
17139
17188
  $schema: "https://json-schema.org/draft/2020-12/schema",
17140
- $id: "https://assets.fluid.app/docs/schema/portal/1.0.0/theme.schema.json",
17189
+ $id: "https://assets.fluid.app/docs/schema/portal/1.1.0/theme.schema.json",
17141
17190
  title: "Fluid Portal Theme",
17142
17191
  type: "object",
17143
17192
  properties: {
@@ -17146,7 +17195,7 @@ const generatedSchemas = {
17146
17195
  pattern: "^https://assets\\.fluid\\.app/docs/schema/portal/(?:0|[1-9]\\d*)\\.(?:0|[1-9]\\d*)\\.(?:0|[1-9]\\d*)(?:-[0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*)?(?:\\+[0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*)?/theme\\.schema\\.json$"
17147
17196
  },
17148
17197
  name: { type: "string" },
17149
- config: { $ref: "https://assets.fluid.app/docs/schema/portal/1.0.0/theme-config.schema.json" },
17198
+ config: { $ref: "https://assets.fluid.app/docs/schema/portal/1.1.0/theme-config.schema.json" },
17150
17199
  active: { type: "boolean" }
17151
17200
  },
17152
17201
  required: [
@@ -17158,7 +17207,7 @@ const generatedSchemas = {
17158
17207
  },
17159
17208
  navigation: {
17160
17209
  $schema: "https://json-schema.org/draft/2020-12/schema",
17161
- $id: "https://assets.fluid.app/docs/schema/portal/1.0.0/navigation.schema.json",
17210
+ $id: "https://assets.fluid.app/docs/schema/portal/1.1.0/navigation.schema.json",
17162
17211
  title: "Fluid Portal Navigation",
17163
17212
  type: "object",
17164
17213
  properties: {
@@ -17210,7 +17259,7 @@ const generatedSchemas = {
17210
17259
  },
17211
17260
  profile: {
17212
17261
  $schema: "https://json-schema.org/draft/2020-12/schema",
17213
- $id: "https://assets.fluid.app/docs/schema/portal/1.0.0/profile.schema.json",
17262
+ $id: "https://assets.fluid.app/docs/schema/portal/1.1.0/profile.schema.json",
17214
17263
  title: "Fluid Portal Profile",
17215
17264
  type: "object",
17216
17265
  properties: {
@@ -17454,7 +17503,6 @@ async function writePortalFile(portalDir, resourceKind, relativePath, data) {
17454
17503
  }
17455
17504
  const pullCommand = new Command("pull").description("Pull a Fluid OS definition's resources to the local portal/ directory").option("--app <name>", "Definition name (skips interactive selector)").option("--id <id>", "Definition id (avoids ambiguity when names repeat)").option("--force", "Overwrite local changes when switching definitions").action(async (options) => {
17456
17505
  const cwd = process.cwd();
17457
- await assertStandalonePortalRemoteActionAllowed(cwd, "portal pull");
17458
17506
  console.log();
17459
17507
  console.log(chalk.blue.bold("Fluid Portal Pull"));
17460
17508
  console.log();
@@ -17644,6 +17692,6 @@ const pullCommand = new Command("pull").description("Pull a Fluid OS definition'
17644
17692
  console.log();
17645
17693
  });
17646
17694
  //#endregion
17647
- export { ApiError as A, updateMapping as C, fluidOsApi as D, createFluidOsClient as E, assertStandalonePortalRemoteActionAllowed as M, __exportAll as N, toFluidOsDynamicObject as O, resolveSlugToId as S, atomicWriteFile as T, writeSnapshot as _, buildNavigationIdToSlugMap as a, removeMapping as b, transformNavigation as c, transformScreen as d, transformTheme as f, readSnapshot as g, diffAgainstSnapshot as h, buildIdToSlugMap as i, STANDALONE_PORTAL_MARKER as j, createFluidOsHeyApiClient as k, transformNavigationItems as l, computeFileHash as m, pull_exports as n, buildThemeIdToSlugMap as o, buildSnapshot as p, validatePortalResource as r, deriveScreenSlug as s, pullCommand as t, transformProfile as u, deriveSlug as v, writeMappings as w, resolveIdToSlug as x, readMappings as y };
17695
+ export { toFluidOsDynamicObject as A, resolveIdToSlug as C, atomicWriteFile as D, writeMappings as E, ApiError as M, __exportAll as N, createFluidOsClient as O, removeMapping as S, updateMapping as T, diffAgainstSnapshot as _, buildNavigationIdToSlugMap as a, deriveSlug as b, transformNavigation as c, transformScreen as d, transformTheme as f, computeFileHash as g, collectSnapshotNetworkWidgetGrants as h, buildIdToSlugMap as i, createFluidOsHeyApiClient as j, fluidOsApi as k, transformNavigationItems as l, collectNetworkWidgetGrants as m, pull_exports as n, buildThemeIdToSlugMap as o, buildSnapshot as p, validatePortalResource as r, deriveScreenSlug as s, pullCommand as t, transformProfile as u, readSnapshot as v, resolveSlugToId as w, readMappings as x, writeSnapshot as y };
17648
17696
 
17649
- //# sourceMappingURL=pull-BZqZAiSF.mjs.map
17697
+ //# sourceMappingURL=pull-BlG6pMwC.mjs.map