@popcraft/kit 0.55.1 → 0.55.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 (58) hide show
  1. package/dist/chunks/{agent-3SWN7CLH.js → agent-FKHU27BN.js} +1 -1
  2. package/dist/chunks/{builtin-RDJAI4FI.js → builtin-J6ZGZ4XA.js} +3 -3
  3. package/dist/chunks/{buy-credits-3WPVXN2P.js → buy-credits-SONV2G3Z.js} +2 -2
  4. package/dist/chunks/{check-template-NPY6LFLW.js → check-template-UAH7O2PK.js} +2 -2
  5. package/dist/chunks/{chunk-PBJDQMGR.js → chunk-4PUI3V2J.js} +2 -2
  6. package/dist/chunks/{chunk-SOZWVEJZ.js → chunk-5ESKXIOI.js} +5 -5
  7. package/dist/chunks/{chunk-TSV3MONK.js → chunk-7AINVVFW.js} +3 -3
  8. package/dist/chunks/{chunk-QZLGWKVF.js → chunk-7EWR3ZPW.js} +1 -1
  9. package/dist/chunks/{chunk-U6NU64E4.js → chunk-CUKVNWIW.js} +1 -1
  10. package/dist/chunks/{chunk-WUSCPLCG.js → chunk-DCULKNUV.js} +4 -4
  11. package/dist/chunks/{chunk-J73NEKWD.js → chunk-EYUFOLVB.js} +1 -1
  12. package/dist/chunks/{chunk-4R3325VV.js → chunk-HZPZGSPI.js} +4 -4
  13. package/dist/chunks/{chunk-VYHDWPID.js → chunk-IWE3TYKJ.js} +42 -42
  14. package/dist/chunks/{chunk-YLMGR2KM.js → chunk-K37ABRNF.js} +4 -4
  15. package/dist/chunks/{chunk-JTUB7ZXJ.js → chunk-KKEUJBVB.js} +2 -2
  16. package/dist/chunks/{chunk-TGGSDM5U.js → chunk-KZOHHKMB.js} +1 -1
  17. package/dist/chunks/{chunk-4PU7VLMY.js → chunk-LPZSNJ6C.js} +2 -2
  18. package/dist/chunks/{chunk-GTEHIYBH.js → chunk-SYTXPXKM.js} +3 -3
  19. package/dist/chunks/{chunk-ND6IXMEG.js → chunk-UUVHJ4E7.js} +2 -2
  20. package/dist/chunks/{chunk-BIYBAIZL.js → chunk-VCRMIT3U.js} +1 -1
  21. package/dist/chunks/{chunk-ZXFHVN4I.js → chunk-WFAZNRI3.js} +5 -5
  22. package/dist/chunks/{chunk-JDV2TC33.js → chunk-YNOGVTNE.js} +11 -11
  23. package/dist/chunks/{chunk-KBBEMWET.js → chunk-ZHANJ25S.js} +9 -9
  24. package/dist/chunks/{client-NNVZF7GK.js → client-7TCGFXUH.js} +1 -1
  25. package/dist/chunks/{client-OCMV3YKC.js → client-ODU66HFR.js} +2 -2
  26. package/dist/chunks/{client-5QVKHXP4.js → client-W4KDKXJP.js} +3 -3
  27. package/dist/chunks/{client-actions-TEZBI3ZP.js → client-actions-G23VP2LO.js} +5 -5
  28. package/dist/chunks/{dangerous-ZSQE55RH.js → dangerous-QHXUBTSH.js} +3 -3
  29. package/dist/chunks/{delete-current-file-VB6DJJCL.js → delete-current-file-AC3H7FEO.js} +5 -5
  30. package/dist/chunks/{editor-seams-XVWQTLYB.js → editor-seams-FWGHLGM7.js} +10 -10
  31. package/dist/chunks/{editor-store-QX5XOMQC.js → editor-store-EMCLHKBR.js} +1 -1
  32. package/dist/chunks/{export-watermark-KLNATVJL.js → export-watermark-JXMRE46M.js} +5 -5
  33. package/dist/chunks/{eyedropper-4DCXQCV3.js → eyedropper-BC35FTWT.js} +1 -1
  34. package/dist/chunks/{generate-media-LZ7KJDL7.js → generate-media-4ZBFI25S.js} +3 -3
  35. package/dist/chunks/{host-QBPGSRA7.js → host-6B2GGGNE.js} +6 -6
  36. package/dist/chunks/{integrations-UXGAEZGV.js → integrations-U6UENGFR.js} +1 -1
  37. package/dist/chunks/{libraries-DJMCIJFH.js → libraries-GFVTGUTZ.js} +5 -5
  38. package/dist/chunks/{live-RDJGBHTV.js → live-5D6BV5X3.js} +1 -1
  39. package/dist/chunks/{media-tool-4VQL5LNA.js → media-tool-4ETLAS2Q.js} +1 -1
  40. package/dist/chunks/{new-file-JPOEOQ4R.js → new-file-WLMSKM3H.js} +3 -3
  41. package/dist/chunks/{plugin-6HAQ73KV.js → plugin-COICIQPS.js} +2 -2
  42. package/dist/chunks/{plugin-import-XRUYCZI2.js → plugin-import-NWEKZ7AJ.js} +14 -14
  43. package/dist/chunks/{presence-NQDR7LOG.js → presence-X6DTRNUD.js} +2 -2
  44. package/dist/chunks/{project-FDH7VUZL.js → project-CQWH7QSM.js} +1 -1
  45. package/dist/chunks/{publish-site-PNOQM6F4.js → publish-site-R3ZTK4OM.js} +6 -6
  46. package/dist/chunks/{publish-store-CVNVPTBR.js → publish-store-GCNH64OY.js} +4 -4
  47. package/dist/chunks/{raster-actions-RQNBT6GP.js → raster-actions-Y4ULMM53.js} +1 -1
  48. package/dist/chunks/{runner-WIEDFEGN.js → runner-GXJMECWH.js} +17 -17
  49. package/dist/chunks/{store-T7TEBUHI.js → store-4ZBTALMW.js} +6 -6
  50. package/dist/chunks/{sync-5N3AZSON.js → sync-VOJYNDQI.js} +5 -5
  51. package/dist/chunks/{tabs-3AHWTEVJ.js → tabs-K4MZRWKN.js} +8 -8
  52. package/dist/chunks/{team-UTX47SR7.js → team-2XBCMJUW.js} +1 -1
  53. package/dist/chunks/{team-client-3FJFYETL.js → team-client-KLTF3WFW.js} +1 -1
  54. package/dist/chunks/{tools-4IIQXQBP.js → tools-EBEDL7N6.js} +2 -2
  55. package/dist/chunks/{ui-commands-6RV3U5WA.js → ui-commands-TJI7WUQ6.js} +12 -12
  56. package/dist/chunks/{versions-MWHQU7S4.js → versions-ZEEBP3V3.js} +5 -5
  57. package/dist/index.js +1 -1
  58. package/package.json +1 -1
@@ -18,7 +18,7 @@ import {
18
18
  renderDocument,
19
19
  toolView,
20
20
  underReviewKit
21
- } from "./chunk-GTEHIYBH.js";
21
+ } from "./chunk-SYTXPXKM.js";
22
22
  import "./chunk-E62GNCKF.js";
23
23
  import "./chunk-5P2BZH2E.js";
24
24
  import "./chunk-S4NW2VYA.js";
@@ -7,8 +7,8 @@ const __dirname = __popcraftDirname(__filename);
7
7
  import {
8
8
  builtinTools,
9
9
  registerBuiltinTools
10
- } from "./chunk-4PU7VLMY.js";
11
- import "./chunk-VYHDWPID.js";
10
+ } from "./chunk-LPZSNJ6C.js";
11
+ import "./chunk-IWE3TYKJ.js";
12
12
  import "./chunk-IF7VGA4A.js";
13
13
  import "./chunk-NP5GZ7KX.js";
14
14
  import "./chunk-FWV6QEQB.js";
@@ -20,7 +20,7 @@ import "./chunk-FOIVUBMA.js";
20
20
  import "./chunk-MM5A2JXD.js";
21
21
  import "./chunk-BYK4UKFZ.js";
22
22
  import "./chunk-QYE5ZBKF.js";
23
- import "./chunk-GTEHIYBH.js";
23
+ import "./chunk-SYTXPXKM.js";
24
24
  import "./chunk-E62GNCKF.js";
25
25
  import "./chunk-ABPJ2NHG.js";
26
26
  import "./chunk-OIDJ7NKJ.js";
@@ -7,14 +7,14 @@ const __dirname = __popcraftDirname(__filename);
7
7
  import {
8
8
  HYPERY_TEAM_HEADER,
9
9
  hyperyRequestHeaders
10
- } from "./chunk-QZLGWKVF.js";
10
+ } from "./chunk-7EWR3ZPW.js";
11
11
  import "./chunk-GUFAKFYN.js";
12
12
  import {
13
13
  openLink
14
14
  } from "./chunk-VUEGRBOY.js";
15
15
  import {
16
16
  useHyperyTeam
17
- } from "./chunk-J73NEKWD.js";
17
+ } from "./chunk-EYUFOLVB.js";
18
18
  import {
19
19
  ApiError,
20
20
  inAppPurchases,
@@ -6,10 +6,10 @@ const __filename = __popcraftPath(import.meta.url);
6
6
  const __dirname = __popcraftDirname(__filename);
7
7
  import {
8
8
  appCommands
9
- } from "./chunk-KBBEMWET.js";
9
+ } from "./chunk-ZHANJ25S.js";
10
10
  import {
11
11
  builtinCommands
12
- } from "./chunk-VYHDWPID.js";
12
+ } from "./chunk-IWE3TYKJ.js";
13
13
  import "./chunk-IF7VGA4A.js";
14
14
  import "./chunk-NP5GZ7KX.js";
15
15
  import "./chunk-FWV6QEQB.js";
@@ -12,7 +12,7 @@ import {
12
12
  } from "./chunk-JFK2HKMU.js";
13
13
  import {
14
14
  markLibraryDocument
15
- } from "./chunk-ZXFHVN4I.js";
15
+ } from "./chunk-WFAZNRI3.js";
16
16
  import {
17
17
  listDocMetas,
18
18
  saveDocSnapshot
@@ -23,7 +23,7 @@ import {
23
23
  } from "./chunk-UGGTR6OM.js";
24
24
  import {
25
25
  activeTeamWorkspaceId
26
- } from "./chunk-J73NEKWD.js";
26
+ } from "./chunk-EYUFOLVB.js";
27
27
  import {
28
28
  ApiError,
29
29
  GUEST_FILE_LIMIT,
@@ -15,7 +15,7 @@ import {
15
15
  } from "./chunk-E62GNCKF.js";
16
16
  import {
17
17
  syncStatus
18
- } from "./chunk-WUSCPLCG.js";
18
+ } from "./chunk-DCULKNUV.js";
19
19
  import {
20
20
  exportNodeToSVG
21
21
  } from "./chunk-3EYF2YPU.js";
@@ -25,7 +25,7 @@ import {
25
25
  import {
26
26
  setPluginTabs,
27
27
  useEditorStore
28
- } from "./chunk-ZXFHVN4I.js";
28
+ } from "./chunk-WFAZNRI3.js";
29
29
  import {
30
30
  openBeside
31
31
  } from "./chunk-VUEGRBOY.js";
@@ -69,7 +69,7 @@ init_define_POPCRAFT_COMPONENT_IDS();
69
69
  // lib/plugins/api.ts
70
70
  init_define_POPCRAFT_COMPONENT_IDS();
71
71
  async function handlePluginCall(env, method, params = {}) {
72
- const { dispatchPluginCall } = await import("./plugin-6HAQ73KV.js");
72
+ const { dispatchPluginCall } = await import("./plugin-COICIQPS.js");
73
73
  return dispatchPluginCall(env, method, params);
74
74
  }
75
75
 
@@ -579,7 +579,7 @@ async function runPlugin(pluginId, commandId, opts = {}) {
579
579
  if (!openBeside(url)) throw new Error("The browser blocked the new tab");
580
580
  },
581
581
  createDocument: async (opts2) => {
582
- const { createFreshFileOrExplain } = await import("./new-file-JPOEOQ4R.js");
582
+ const { createFreshFileOrExplain } = await import("./new-file-WLMSKM3H.js");
583
583
  const created = await createFreshFileOrExplain({}, { name: opts2?.name });
584
584
  if (!created.ok) throw new Error(created.reason === "plan" ? "Plan limit reached" : created.reason === "guest-limit" ? "Sign in to create another file" : `Could not create file (${created.reason})`);
585
585
  await useEditorStore.getState().openDocument(created.docId);
@@ -769,7 +769,7 @@ if (typeof window !== "undefined") {
769
769
  const name = d.name || "Imported";
770
770
  void (async () => {
771
771
  try {
772
- const { importViaPlugin, applyPluginLayoutIr } = await import("./plugin-import-XRUYCZI2.js");
772
+ const { importViaPlugin, applyPluginLayoutIr } = await import("./plugin-import-NWEKZ7AJ.js");
773
773
  if (d.ir && typeof d.ir === "object") {
774
774
  await applyPluginLayoutIr(d.ir, { mode, name });
775
775
  return;
@@ -9,7 +9,7 @@ import {
9
9
  hostEnv,
10
10
  plain,
11
11
  registerBuiltinCommands
12
- } from "./chunk-VYHDWPID.js";
12
+ } from "./chunk-IWE3TYKJ.js";
13
13
  import {
14
14
  storeOpsSeam
15
15
  } from "./chunk-VCY5ZYCK.js";
@@ -618,7 +618,7 @@ var commands = [
618
618
  const [{ storefrontInputs }, { STOREFRONT_TARGETS }, { bytesOf }, { zipFiles }, { EXPORT_NODE_CAP }] = await Promise.all([
619
619
  import("./storefront-prepare-ORDEDJJG.js"),
620
620
  import("./storefront-4Y7ZBJW5.js"),
621
- import("./project-FDH7VUZL.js"),
621
+ import("./project-CQWH7QSM.js"),
622
622
  import("./zip-export-MY5KVTJH.js"),
623
623
  import("./tree-C66L6YYD.js")
624
624
  ]);
@@ -815,7 +815,7 @@ var pluginRun = defineCommand({
815
815
  }
816
816
  },
817
817
  run: async (p, ctx) => {
818
- const { runPlugin } = await import("./host-QBPGSRA7.js");
818
+ const { runPlugin } = await import("./host-6B2GGGNE.js");
819
819
  await runPlugin(p.pluginId, p.commandId);
820
820
  ctx.notice(`Started ${p.pluginId}.`);
821
821
  return {
@@ -11,7 +11,7 @@ import {
11
11
  activeHyperyTeamId,
12
12
  activeTeamWorkspaceId,
13
13
  useHyperyTeam
14
- } from "./chunk-J73NEKWD.js";
14
+ } from "./chunk-EYUFOLVB.js";
15
15
  import {
16
16
  inAppPurchases
17
17
  } from "./chunk-6RTOG3SA.js";
@@ -13,7 +13,7 @@ import {
13
13
  agentTool,
14
14
  agentToolList,
15
15
  registerCommands
16
- } from "./chunk-GTEHIYBH.js";
16
+ } from "./chunk-SYTXPXKM.js";
17
17
  import {
18
18
  dispatch
19
19
  } from "./chunk-5P2BZH2E.js";
@@ -13,14 +13,14 @@ import {
13
13
  reportOpenStage,
14
14
  setCloudLink,
15
15
  trackOpen
16
- } from "./chunk-PBJDQMGR.js";
16
+ } from "./chunk-4PUI3V2J.js";
17
17
  import {
18
18
  parseDeepLink,
19
19
  withDeepLink
20
20
  } from "./chunk-IEGXDV67.js";
21
21
  import {
22
22
  attachPresence
23
- } from "./chunk-TGGSDM5U.js";
23
+ } from "./chunk-KZOHHKMB.js";
24
24
  import {
25
25
  fileOpeningMode,
26
26
  isAppleMobile,
@@ -33,7 +33,7 @@ import {
33
33
  setCollabHistory,
34
34
  storedDocument,
35
35
  useEditorStore
36
- } from "./chunk-ZXFHVN4I.js";
36
+ } from "./chunk-WFAZNRI3.js";
37
37
  import {
38
38
  currentHistoryGroup
39
39
  } from "./chunk-AWH6VFF3.js";
@@ -52,7 +52,7 @@ import {
52
52
  } from "./chunk-UGGTR6OM.js";
53
53
  import {
54
54
  activeTeamWorkspaceId
55
- } from "./chunk-J73NEKWD.js";
55
+ } from "./chunk-EYUFOLVB.js";
56
56
  import {
57
57
  ApiError,
58
58
  api,
@@ -150,7 +150,7 @@ function startHyperyTeams() {
150
150
  maybePromptForTeam();
151
151
  void followFileTeam(linkedKey);
152
152
  });
153
- void import("./sync-5N3AZSON.js").then(({ onSyncStatus, syncStatus }) => {
153
+ void import("./sync-VOJYNDQI.js").then(({ onSyncStatus, syncStatus }) => {
154
154
  linkedKey = syncStatus().link?.key ?? null;
155
155
  void followFileTeam(linkedKey);
156
156
  onSyncStatus((_s, link) => {
@@ -9,7 +9,7 @@ import {
9
9
  } from "./chunk-THSYXT6D.js";
10
10
  import {
11
11
  notice
12
- } from "./chunk-JTUB7ZXJ.js";
12
+ } from "./chunk-KKEUJBVB.js";
13
13
  import {
14
14
  effectiveChatModel,
15
15
  setModelPref,
@@ -17,7 +17,7 @@ import {
17
17
  } from "./chunk-QW3TASQN.js";
18
18
  import {
19
19
  useEditorStore
20
- } from "./chunk-ZXFHVN4I.js";
20
+ } from "./chunk-WFAZNRI3.js";
21
21
  import {
22
22
  create
23
23
  } from "./chunk-6WXASC7R.js";
@@ -1797,7 +1797,7 @@ async function sendMessage(text) {
1797
1797
  if (!useAgentStore.getState().activeThreadId) newThread();
1798
1798
  const mentions = pruneMentions(body, useAgentStore.getState().draftMentions);
1799
1799
  useAgentStore.setState({ draft: "", draftMentions: [], error: null });
1800
- const { runTurn } = await import("./runner-WIEDFEGN.js");
1800
+ const { runTurn } = await import("./runner-GXJMECWH.js");
1801
1801
  await runTurn(body, mentions);
1802
1802
  }
1803
1803
  function stop() {
@@ -1900,7 +1900,7 @@ var clearTaskChildren = () => useAgentStore.setState({ taskChildren: {} });
1900
1900
  function subscribeChildTools() {
1901
1901
  let dispose;
1902
1902
  let cancelled = false;
1903
- void import("./runner-WIEDFEGN.js").then(({ onChildTool }) => {
1903
+ void import("./runner-GXJMECWH.js").then(({ onChildTool }) => {
1904
1904
  const off = onChildTool((report) => {
1905
1905
  if (report?.status !== "running" || report.jobId) return;
1906
1906
  recordChildTool(report.toolCallId ?? "", report.name);
@@ -904,7 +904,7 @@ init_scene_graph();
904
904
  var licence = external_exports.enum(["commercial", "any"]).optional().describe("commercial (default): only licences that allow commercial use and edits (CC0, public domain, CC BY, CC BY-SA). any: every Creative Commons licence, including NC and ND.");
905
905
  var brief2 = (p) => ({ id: p.id, title: p.title, creator: p.credit.creator, licence: licenceLabel(p.credit), width: p.width, height: p.height, source: p.credit.sourceUrl });
906
906
  async function placeImportedPicture(ctx, imported, at2, what, extra = {}) {
907
- const client = await import("./client-NNVZF7GK.js");
907
+ const client = await import("./client-7TCGFXUH.js");
908
908
  if (at2.fillLayerId) {
909
909
  const doc2 = ctx.doc();
910
910
  const target = nodeOrThrow(doc2, at2.fillLayerId);
@@ -950,7 +950,7 @@ var photoSearch = defineCommand({
950
950
  }
951
951
  },
952
952
  run: async (args) => {
953
- const { searchStockPhotos } = await import("./client-NNVZF7GK.js");
953
+ const { searchStockPhotos } = await import("./client-7TCGFXUH.js");
954
954
  const page = await searchStockPhotos(args.query, args.page ?? 1, { licence: args.licence });
955
955
  return {
956
956
  summary: `${page.results.length} photo${page.results.length === 1 ? "" : "s"} for \u201C${page.query}\u201D (page ${page.page} of ${page.pageCount || 1})`,
@@ -984,7 +984,7 @@ var photoInsert = defineCommand({
984
984
  run: async (args, ctx) => {
985
985
  if (!args.id && !args.query) throw new ToolError("Pass an id from search_photos, or a query.");
986
986
  if (args.id && !isPhotoId(args.id)) throw new ToolError(`"${args.id}" is not a photo id from search_photos.`);
987
- const client = await import("./client-NNVZF7GK.js");
987
+ const client = await import("./client-7TCGFXUH.js");
988
988
  let photo;
989
989
  if (args.id) photo = await client.stockPhotoInfo(args.id);
990
990
  else {
@@ -1022,10 +1022,10 @@ var mediaList = defineCommand({
1022
1022
  }
1023
1023
  },
1024
1024
  run: async (args) => {
1025
- const { listLibraryMedia } = await import("./client-OCMV3YKC.js");
1025
+ const { listLibraryMedia } = await import("./client-ODU66HFR.js");
1026
1026
  const q = { ...args };
1027
1027
  if (!q.workspace) {
1028
- const { syncStatus } = await import("./sync-5N3AZSON.js");
1028
+ const { syncStatus } = await import("./sync-VOJYNDQI.js");
1029
1029
  const link2 = syncStatus().link;
1030
1030
  if (!link2) throw new ToolError("This document is not saved to the cloud, so it has no team media library. Pass workspace.");
1031
1031
  q.workspace = (await listLibraryMedia({ file: link2.key, limit: 1 })).workspaceId;
@@ -1060,7 +1060,7 @@ var mediaInsert = defineCommand({
1060
1060
  run: async (args, ctx) => {
1061
1061
  const contentType = args.contentType ?? "image/*";
1062
1062
  if (!contentType.startsWith("image/")) throw new ToolError("insert_media places pictures; this item is not one.");
1063
- const { importLibraryPicture } = await import("./client-OCMV3YKC.js");
1063
+ const { importLibraryPicture } = await import("./client-ODU66HFR.js");
1064
1064
  const item = { hash: args.hash, fileKey: args.fileKey, fileName: args.name ?? "Media", contentType, size: 0, createdAt: "", fileCount: 1, source: null };
1065
1065
  const imported = await importLibraryPicture(item);
1066
1066
  return placeImportedPicture(ctx, imported, args, `\u201C${imported.name}\u201D`, { hash: imported.hash });
@@ -1081,7 +1081,7 @@ var mediaDownload = defineCommand({
1081
1081
  // The Library's right-click menu: saves the item's file to the computer.
1082
1082
  expose: { ui: { label: "Download", palette: false } },
1083
1083
  run: async (args) => {
1084
- const { libraryBlob, libraryFileName } = await import("./client-OCMV3YKC.js");
1084
+ const { libraryBlob, libraryFileName } = await import("./client-ODU66HFR.js");
1085
1085
  const { downloadBlob } = await import("./download-IAHP32Q5.js");
1086
1086
  const item = { hash: args.hash, fileKey: args.fileKey, fileName: args.name ?? "media", contentType: args.contentType ?? "", size: 0, createdAt: "", fileCount: 1, source: null };
1087
1087
  const blob = await libraryBlob(item);
@@ -1112,7 +1112,7 @@ var mediaDelete = defineCommand({
1112
1112
  }
1113
1113
  },
1114
1114
  run: async (args) => {
1115
- const { deleteLibraryMedia } = await import("./client-OCMV3YKC.js");
1115
+ const { deleteLibraryMedia } = await import("./client-ODU66HFR.js");
1116
1116
  const out = await deleteLibraryMedia(args.workspace, args.hash);
1117
1117
  return { summary: `Deleted it from the library (it was in ${out.files} file${out.files === 1 ? "" : "s"})`, data: out };
1118
1118
  }
@@ -1126,13 +1126,13 @@ async function signedIn() {
1126
1126
  }
1127
1127
  async function publishedFile() {
1128
1128
  await signedIn();
1129
- const { openFileKey } = await import("./publish-site-PNOQM6F4.js");
1129
+ const { openFileKey } = await import("./publish-site-R3ZTK4OM.js");
1130
1130
  const key = openFileKey();
1131
1131
  if (!key) throw new CommandError("This file is not saved to the cloud yet, so it has no site. Publish it first.", "failed");
1132
1132
  return key;
1133
1133
  }
1134
1134
  async function formsWithoutDatabase(key) {
1135
- const [{ useEditorStore }, { usesForms, formsGoNowhere }, { siteBackend }] = await Promise.all([import("./editor-store-QX5XOMQC.js"), import("./backend-MZBOFSI2.js"), import("./integrations-UXGAEZGV.js")]);
1135
+ const [{ useEditorStore }, { usesForms, formsGoNowhere }, { siteBackend }] = await Promise.all([import("./editor-store-EMCLHKBR.js"), import("./backend-MZBOFSI2.js"), import("./integrations-U6UENGFR.js")]);
1136
1136
  const doc2 = useEditorStore.getState().document;
1137
1137
  if (!usesForms(doc2)) return false;
1138
1138
  return formsGoNowhere(doc2, await siteBackend(key).catch(() => void 0));
@@ -1168,7 +1168,7 @@ var publishSite = defineCommand({
1168
1168
  const { cleanSlug } = await import("./rules-VD5T72ZS.js");
1169
1169
  const address = p.address === void 0 ? void 0 : cleanSlug(p.address);
1170
1170
  if (address === null) throw new CommandError("That cannot be a site address: use 3 to 40 letters, digits and dashes.", "invalid_params");
1171
- const { publishOpenFile, NoScreens } = await import("./publish-site-PNOQM6F4.js");
1171
+ const { publishOpenFile, NoScreens } = await import("./publish-site-R3ZTK4OM.js");
1172
1172
  try {
1173
1173
  const done = await publishOpenFile(address);
1174
1174
  ctx.notice(`Published version ${done.version}: ${done.url}`);
@@ -1223,7 +1223,7 @@ var publishListSites = defineCommand({
1223
1223
  },
1224
1224
  run: async (p) => {
1225
1225
  await signedIn();
1226
- const [{ workspaceSites }, { activeTeamWorkspaceId, useHyperyTeam }] = await Promise.all([import("./sites-D6IA7WTP.js"), import("./team-UTX47SR7.js")]);
1226
+ const [{ workspaceSites }, { activeTeamWorkspaceId, useHyperyTeam }] = await Promise.all([import("./sites-D6IA7WTP.js"), import("./team-2XBCMJUW.js")]);
1227
1227
  const workspaceId = p.workspaceId ?? activeTeamWorkspaceId() ?? useHyperyTeam.getState().personalWorkspaceId;
1228
1228
  if (!workspaceId) throw new CommandError("Your workspaces have not loaded yet. Try again in a moment.", "failed");
1229
1229
  const out = await workspaceSites(workspaceId);
@@ -1272,12 +1272,12 @@ var publishStatus = defineCommand({
1272
1272
  },
1273
1273
  run: async () => {
1274
1274
  await signedIn();
1275
- const [{ openFileKey }, { siteStatus }] = await Promise.all([import("./publish-site-PNOQM6F4.js"), import("./sites-D6IA7WTP.js")]);
1275
+ const [{ openFileKey }, { siteStatus }] = await Promise.all([import("./publish-site-R3ZTK4OM.js"), import("./sites-D6IA7WTP.js")]);
1276
1276
  const key = openFileKey();
1277
1277
  const status = await siteStatus(key);
1278
1278
  const site = status.site;
1279
- const backend = key ? await (await import("./integrations-UXGAEZGV.js")).siteBackend(key).catch(() => null) : null;
1280
- const destinations = key ? await (await import("./integrations-UXGAEZGV.js")).listDestinations(key).catch(() => []) : [];
1279
+ const backend = key ? await (await import("./integrations-U6UENGFR.js")).siteBackend(key).catch(() => null) : null;
1280
+ const destinations = key ? await (await import("./integrations-U6UENGFR.js")).listDestinations(key).catch(() => []) : [];
1281
1281
  return {
1282
1282
  summary: !status.configured ? "This server does not publish websites" : !site ? "Not published yet" : site.currentVersion === null ? `Offline (${site.versions.length} versions kept) \u2014 ${site.url}` : `Version ${site.currentVersion} is online at ${site.url}`,
1283
1283
  data: { ...statusData(status), database: backend?.database ? { provider: backend.database.connection.provider, account: backend.database.connection.account, target: backend.database.target.map((t) => t.name), visitorsCanSignIn: backend.database.signIn } : null, destinations: destinations.map((d) => ({ destinationId: d.id, provider: d.connection.provider, account: d.connection.account, kind: d.capability, target: d.target.map((t) => t.name), lastSent: d.lastDeploy })) }
@@ -1308,7 +1308,7 @@ var publishStore = defineCommand({
1308
1308
  },
1309
1309
  run: async (p, ctx) => {
1310
1310
  await signedIn();
1311
- const { deployOpenStore } = await import("./publish-store-CVNVPTBR.js");
1311
+ const { deployOpenStore } = await import("./publish-store-GCNH64OY.js");
1312
1312
  const done = await deployOpenStore(ctx.doc(), ctx.pageId(), { destinationId: p.destinationId }).catch((e) => {
1313
1313
  throw new CommandError(e instanceof Error ? e.message : String(e), "failed");
1314
1314
  });
@@ -1337,7 +1337,7 @@ var integrationList = defineCommand({
1337
1337
  }
1338
1338
  },
1339
1339
  run: async ({ capability }) => {
1340
- const [{ cloudUser }, { integrationsWorkspaceId, listWorkspaceIntegrations }] = await Promise.all([import("./session-ZTCZUSBI.js"), import("./integrations-UXGAEZGV.js")]);
1340
+ const [{ cloudUser }, { integrationsWorkspaceId, listWorkspaceIntegrations }] = await Promise.all([import("./session-ZTCZUSBI.js"), import("./integrations-U6UENGFR.js")]);
1341
1341
  if (!cloudUser()) throw new CommandError("You are not signed in: integrations belong to your account's workspace.", "denied");
1342
1342
  const workspaceId = integrationsWorkspaceId();
1343
1343
  if (!workspaceId) throw new CommandError("Your workspaces have not loaded yet. Try again in a moment.", "failed");
@@ -1378,7 +1378,7 @@ var integrationOpen = defineCommand({
1378
1378
  }
1379
1379
  });
1380
1380
  async function openFile() {
1381
- const [{ cloudUser }, { openFileKey }] = await Promise.all([import("./session-ZTCZUSBI.js"), import("./publish-site-PNOQM6F4.js")]);
1381
+ const [{ cloudUser }, { openFileKey }] = await Promise.all([import("./session-ZTCZUSBI.js"), import("./publish-site-R3ZTK4OM.js")]);
1382
1382
  if (!cloudUser()) throw new CommandError("You are not signed in.", "denied");
1383
1383
  const key = openFileKey();
1384
1384
  if (!key) throw new CommandError("This file is not saved to the cloud yet. Publish it first (publish_site).", "failed");
@@ -1404,7 +1404,7 @@ var integrationListResources = defineCommand({
1404
1404
  }
1405
1405
  },
1406
1406
  run: async ({ connectionId, capability, path }) => {
1407
- const { listResources } = await import("./integrations-UXGAEZGV.js");
1407
+ const { listResources } = await import("./integrations-U6UENGFR.js");
1408
1408
  const list = await listResources(connectionId, capability, asPath2(path));
1409
1409
  return {
1410
1410
  summary: list.level ? `${list.resources.length} at the ${list.level.label.toLowerCase()} level${list.canCreate ? " (a new one can be made)" : ""}` : "Nothing further to pick: the path is complete",
@@ -1439,7 +1439,7 @@ var integrationAddDestination = defineCommand({
1439
1439
  },
1440
1440
  run: async (p, ctx) => {
1441
1441
  const key = await openFile();
1442
- const { addDestination, createDestination, createResource } = await import("./integrations-UXGAEZGV.js");
1442
+ const { addDestination, createDestination, createResource } = await import("./integrations-U6UENGFR.js");
1443
1443
  let made;
1444
1444
  if (p.create) made = await createDestination(key, p.capability, void 0, p.connectionId);
1445
1445
  else {
@@ -1476,7 +1476,7 @@ var integrationDeploy = defineCommand({
1476
1476
  },
1477
1477
  run: async (p, ctx) => {
1478
1478
  const key = await openFile();
1479
- const { deployDestination, listDestinations } = await import("./integrations-UXGAEZGV.js");
1479
+ const { deployDestination, listDestinations } = await import("./integrations-U6UENGFR.js");
1480
1480
  const all = await listDestinations(key);
1481
1481
  const dest = p.destinationId ? all.find((d) => d.id === p.destinationId) : all.length === 1 ? all[0] : void 0;
1482
1482
  if (!dest) throw new CommandError(all.length ? `Say which destination: ${all.map((d) => `${d.id} (${d.target.map((t) => t.name).join(" / ")})`).join(", ")}.` : "This file has no destination yet. Add one first (add_site_destination).", "invalid_params");
@@ -1510,7 +1510,7 @@ var integrationAttachDatabase = defineCommand({
1510
1510
  },
1511
1511
  run: async (p, ctx) => {
1512
1512
  const key = await openFile();
1513
- const { attachDatabase, createDatabase, createResource, listResources } = await import("./integrations-UXGAEZGV.js");
1513
+ const { attachDatabase, createDatabase, createResource, listResources } = await import("./integrations-U6UENGFR.js");
1514
1514
  if (p.create) return attached(await createDatabase(key, void 0, p.connectionId), ctx);
1515
1515
  if (!p.connectionId || !p.target) throw new CommandError("Say connectionId and target, or create: true.", "invalid_params");
1516
1516
  let target = asPath2(p.target);
@@ -1549,7 +1549,7 @@ var integrationSubmissions = defineCommand({
1549
1549
  },
1550
1550
  run: async ({ form, limit }) => {
1551
1551
  const key = await openFile();
1552
- const { listSubmissions } = await import("./integrations-UXGAEZGV.js");
1552
+ const { listSubmissions } = await import("./integrations-U6UENGFR.js");
1553
1553
  const rows = await listSubmissions(key, { form, limit: limit ?? 20 });
1554
1554
  return { summary: rows.length ? `${rows.length} ${rows.length === 1 ? "submission" : "submissions"}, the newest ${new Date(rows[0].createdAt).toISOString()}` : "Nothing has been sent yet", data: { submissions: rows } };
1555
1555
  }
@@ -1574,7 +1574,7 @@ var integrationSetSignIn = defineCommand({
1574
1574
  },
1575
1575
  run: async ({ on }, ctx) => {
1576
1576
  const key = await openFile();
1577
- const { setSignIn } = await import("./integrations-UXGAEZGV.js");
1577
+ const { setSignIn } = await import("./integrations-U6UENGFR.js");
1578
1578
  const done = await setSignIn(key, on);
1579
1579
  ctx.notice(on ? "Visitors can sign in." : "Sign-in is off.");
1580
1580
  return { summary: on ? "Visitors can now create accounts and sign in on the published site" : "Sign-in is off for the published site", data: { signIn: !!done.database?.signIn } };
@@ -1792,7 +1792,7 @@ var fontTeamList = defineCommand({
1792
1792
  agent: { name: "list_team_fonts", readOnly: true, description: "The team's fonts: faces uploaded once that every file of the team can use (family, weight, style)." }
1793
1793
  },
1794
1794
  run: async (args) => {
1795
- const { refreshTeamFonts } = await import("./team-client-3FJFYETL.js");
1795
+ const { refreshTeamFonts } = await import("./team-client-KLTF3WFW.js");
1796
1796
  const fonts = await refreshTeamFonts(args.workspace);
1797
1797
  return { summary: plural(fonts.length, "team font"), data: { fonts: fonts.map((f) => ({ id: f.id, family: f.family, weight: f.weight, style: f.style, face: f.face, fileName: f.fileName })) } };
1798
1798
  }
@@ -1819,7 +1819,7 @@ var fontTeamAdd = defineCommand({
1819
1819
  run: async (args, ctx) => {
1820
1820
  const { bytes, fileName: fileName2 } = await fontBytes(args, ctx);
1821
1821
  const { face, family, weight, style } = await resolveFace(bytes, args);
1822
- const { uploadTeamFont } = await import("./team-client-3FJFYETL.js");
1822
+ const { uploadTeamFont } = await import("./team-client-KLTF3WFW.js");
1823
1823
  const font = await uploadTeamFont(bytes, { family, weight, style, face: face.index, fileName: fileName2 }, args.workspace);
1824
1824
  return { summary: `Added ${family} ${weight}${style === "italic" ? " italic" : ""} to the team`, data: { font } };
1825
1825
  }
@@ -1841,7 +1841,7 @@ var fontTeamRemove = defineCommand({
1841
1841
  agent: { name: "remove_team_font", description: "Remove a font from the team (list_team_fonts). Files that use it fall back to another font unless they carry it themselves. The user approves every call." }
1842
1842
  },
1843
1843
  run: async (args) => {
1844
- const { removeTeamFont } = await import("./team-client-3FJFYETL.js");
1844
+ const { removeTeamFont } = await import("./team-client-KLTF3WFW.js");
1845
1845
  const out = await removeTeamFont(args.id, args.workspace);
1846
1846
  return { summary: `Removed the team font${out.freed ? " and freed its storage" : ""}`, data: out };
1847
1847
  }
@@ -1852,7 +1852,7 @@ var fontTeamCommands = [fontTeamList, fontTeamAdd];
1852
1852
  init_define_POPCRAFT_COMPONENT_IDS();
1853
1853
  async function cloudFile() {
1854
1854
  const [{ syncStatus }, { cloudUser }] = await Promise.all([
1855
- import("./sync-5N3AZSON.js"),
1855
+ import("./sync-VOJYNDQI.js"),
1856
1856
  import("./session-ZTCZUSBI.js")
1857
1857
  ]);
1858
1858
  const link2 = syncStatus().link;
@@ -1914,7 +1914,7 @@ var fileTrash = defineCommand({
1914
1914
  agent: { name: "trash_file", description: "Delete the open file: a cloud file goes to the Trash (restorable), a signed-out local file is deleted for good. Then the editor goes back to Home. The user approves every call." }
1915
1915
  },
1916
1916
  run: async () => {
1917
- const { deleteCurrentFile, leaveDeletedFile } = await import("./delete-current-file-VB6DJJCL.js");
1917
+ const { deleteCurrentFile, leaveDeletedFile } = await import("./delete-current-file-AC3H7FEO.js");
1918
1918
  const { name: name2, kind } = await deleteCurrentFile();
1919
1919
  leaveDeletedFile();
1920
1920
  return { summary: kind === "cloud" ? `Moved \u201C${name2}\u201D to the Trash` : `Deleted \u201C${name2}\u201D` };
@@ -2027,11 +2027,11 @@ var fileDuplicate = defineCommand({
2027
2027
  },
2028
2028
  run: async (_p, ctx) => {
2029
2029
  const [{ syncStatus }, { cloudApi }, { isDesktopTabs }, { createFileInTab }, { openNewCloudFile }, { v4: uuid }] = await Promise.all([
2030
- import("./sync-5N3AZSON.js"),
2030
+ import("./sync-VOJYNDQI.js"),
2031
2031
  import("./api-JUPUFV5S.js"),
2032
2032
  import("./tab-mode-JUO37HWE.js"),
2033
- import("./tabs-3AHWTEVJ.js"),
2034
- import("./sync-5N3AZSON.js"),
2033
+ import("./tabs-K4MZRWKN.js"),
2034
+ import("./sync-VOJYNDQI.js"),
2035
2035
  import("./dist-node-RBXA53XX.js")
2036
2036
  ]);
2037
2037
  const doc2 = ctx.doc();
@@ -4849,7 +4849,7 @@ var viewCopyLink = defineCommand({
4849
4849
  },
4850
4850
  run: async (args, ctx) => {
4851
4851
  const [{ syncStatus }, { fileUrl }, { withDeepLink }] = await Promise.all([
4852
- import("./sync-5N3AZSON.js"),
4852
+ import("./sync-VOJYNDQI.js"),
4853
4853
  import("./api-JUPUFV5S.js"),
4854
4854
  import("./deep-link-AZSCPLVZ.js")
4855
4855
  ]);
@@ -5174,7 +5174,7 @@ var pageGo = defineCommand({
5174
5174
  ] }
5175
5175
  },
5176
5176
  run: async ({ to }) => {
5177
- const { useEditorStore } = await import("./editor-store-QX5XOMQC.js");
5177
+ const { useEditorStore } = await import("./editor-store-EMCLHKBR.js");
5178
5178
  useEditorStore.getState().goToPrintPage(to);
5179
5179
  return { summary: typeof to === "number" ? `Page ${to + 1}` : `${to} page` };
5180
5180
  }
@@ -5208,7 +5208,7 @@ var pageSetup = defineCommand({
5208
5208
  }
5209
5209
  },
5210
5210
  run: async (args) => {
5211
- const { useEditorStore } = await import("./editor-store-QX5XOMQC.js");
5211
+ const { useEditorStore } = await import("./editor-store-EMCLHKBR.js");
5212
5212
  useEditorStore.getState().applyPageSetup(args);
5213
5213
  return { summary: `Page setup updated${args.kind ? ` (${args.kind.toLowerCase()})` : ""}` };
5214
5214
  }
@@ -5646,7 +5646,7 @@ async function docAtTime(doc2, ids, time2) {
5646
5646
  let frameId;
5647
5647
  if (time2 === void 0) {
5648
5648
  try {
5649
- const { useEditorStore } = await import("./editor-store-QX5XOMQC.js");
5649
+ const { useEditorStore } = await import("./editor-store-EMCLHKBR.js");
5650
5650
  const st = useEditorStore.getState();
5651
5651
  const target = st.transport?.target;
5652
5652
  if (st.mode !== "ANIMATE" || target?.kind !== "frame") return doc2;
@@ -6040,7 +6040,7 @@ async function runAnimationExport(format, args, ctx) {
6040
6040
  const filename = exportFileName(args.filename || targetName(doc2, target), format);
6041
6041
  const [{ exportAnimation }, { memoryDestination }] = await Promise.all([import("./video-6GJVQW4X.js"), import("./destination-RF2ZSTLU.js")]);
6042
6042
  if (format === "lottie" || format === "dotlottie") return runLottieExport(renderer, doc2, spec, filename, ctx, memoryDestination, args.stateMachine);
6043
- const planWatermark = format !== "png" && await (await import("./export-watermark-KLNATVJL.js")).exportWatermark();
6043
+ const planWatermark = format !== "png" && await (await import("./export-watermark-JXMRE46M.js")).exportWatermark();
6044
6044
  if (format !== "png") spec = { ...spec, watermark: planWatermark || args.watermark !== false };
6045
6045
  const dest = ctx.destination ? await ctx.destination(filename, FORMAT_MIME[format]) : memoryDestination(filename, FORMAT_MIME[format]);
6046
6046
  let stats;
@@ -6126,7 +6126,7 @@ var exportLottie = animationCommand((args) => args.container === "lottie" ? "dot
6126
6126
  });
6127
6127
  async function exportSite(doc2, pageId2, packaging, styling = "css", siteUrl) {
6128
6128
  const [{ completeSite, nextFilesOf, shareImageFiles, staticFilesOf, NoSiteRuntime, bytesOf }, { fileBase }, { zipFiles }, { downloadBlob }] = await Promise.all([
6129
- import("./project-FDH7VUZL.js"),
6129
+ import("./project-CQWH7QSM.js"),
6130
6130
  import("./web-RD2LMTBT.js"),
6131
6131
  import("./zip-export-MY5KVTJH.js"),
6132
6132
  import("./download-IAHP32Q5.js")
@@ -6220,7 +6220,7 @@ var exportStorefront = defineCommand({
6220
6220
  const [{ storefrontInputs }, { STOREFRONT_TARGETS }, { bytesOf }, { fileBase, flatten }, { zipFiles }, { downloadBlob }] = await Promise.all([
6221
6221
  import("./storefront-prepare-ORDEDJJG.js"),
6222
6222
  import("./storefront-4Y7ZBJW5.js"),
6223
- import("./project-FDH7VUZL.js"),
6223
+ import("./project-CQWH7QSM.js"),
6224
6224
  import("./web-RD2LMTBT.js"),
6225
6225
  import("./zip-export-MY5KVTJH.js"),
6226
6226
  import("./download-IAHP32Q5.js")
@@ -6615,7 +6615,7 @@ var visionRegenerateImage = defineCommand({
6615
6615
  const id = args.id ?? ctx.selection()[0];
6616
6616
  if (!id) throw new ToolError("Select a generated image to regenerate.");
6617
6617
  nodeOrThrow(ctx.doc(), id);
6618
- const { regenerateImage } = await import("./client-actions-TEZBI3ZP.js");
6618
+ const { regenerateImage } = await import("./client-actions-G23VP2LO.js");
6619
6619
  regenerateImage(id, args.count);
6620
6620
  return { summary: args.count > 1 ? `Regenerating ${args.count} variants` : "Regenerating the image", data: { id, count: args.count } };
6621
6621
  }
@@ -10150,7 +10150,7 @@ var scriptRun = defineCommand({
10150
10150
  // A script is not the turn the user is watching: confirm-tier tools are refused inside it (dispatch, `nested`).
10151
10151
  actor: { ...ctx.actor, nested: true, label: "Script" },
10152
10152
  // A look_at inside the script sees the document as the script has left it so far, not as it was before.
10153
- use: ((name2) => name2 === "render" && ctx.can("render") ? (async (ids, options) => (await import("./agent-3SWN7CLH.js")).renderDocument(staged, ids, options)) : ctx.use(name2))
10153
+ use: ((name2) => name2 === "render" && ctx.can("render") ? (async (ids, options) => (await import("./agent-FKHU27BN.js")).renderDocument(staged, ids, options)) : ctx.use(name2))
10154
10154
  };
10155
10155
  let calls = 0;
10156
10156
  const images = [];
@@ -10970,7 +10970,7 @@ var docImportFile = defineCommand({
10970
10970
  const file = new File([body], args.name);
10971
10971
  if (file.size > MAX_BYTES) throw new ToolError(`"${args.name}" is larger than ${MAX_BYTES / 1024 / 1024} MB.`);
10972
10972
  const [{ buildImportedDocument }, { mergeImportedDocument }] = await Promise.all([
10973
- import("./plugin-import-XRUYCZI2.js"),
10973
+ import("./plugin-import-NWEKZ7AJ.js"),
10974
10974
  import("./import-merge-PBWSDPTK.js")
10975
10975
  ]);
10976
10976
  const built = await buildImportedDocument(file);
@@ -20,21 +20,21 @@ import {
20
20
  } from "./chunk-F7FHTESQ.js";
21
21
  import {
22
22
  notice
23
- } from "./chunk-JTUB7ZXJ.js";
23
+ } from "./chunk-KKEUJBVB.js";
24
24
  import {
25
25
  agentContext
26
- } from "./chunk-GTEHIYBH.js";
26
+ } from "./chunk-SYTXPXKM.js";
27
27
  import {
28
28
  collabSession,
29
29
  syncStatus
30
- } from "./chunk-WUSCPLCG.js";
30
+ } from "./chunk-DCULKNUV.js";
31
31
  import {
32
32
  loadEntitlements
33
33
  } from "./chunk-GUFAKFYN.js";
34
34
  import {
35
35
  persist,
36
36
  useEditorStore
37
- } from "./chunk-ZXFHVN4I.js";
37
+ } from "./chunk-WFAZNRI3.js";
38
38
  import {
39
39
  cloudApi
40
40
  } from "./chunk-6RTOG3SA.js";
@@ -22,7 +22,7 @@ import {
22
22
  requestImageAction,
23
23
  sizeForAspect,
24
24
  vectorSupport
25
- } from "./chunk-BIYBAIZL.js";
25
+ } from "./chunk-VCRMIT3U.js";
26
26
  import {
27
27
  external_exports
28
28
  } from "./chunk-QYE5ZBKF.js";
@@ -31,7 +31,7 @@ import {
31
31
  } from "./chunk-3EYF2YPU.js";
32
32
  import {
33
33
  useEditorStore
34
- } from "./chunk-ZXFHVN4I.js";
34
+ } from "./chunk-WFAZNRI3.js";
35
35
  import {
36
36
  withHistoryGroup
37
37
  } from "./chunk-AWH6VFF3.js";
@@ -6,7 +6,7 @@ const __filename = __popcraftPath(import.meta.url);
6
6
  const __dirname = __popcraftDirname(__filename);
7
7
  import {
8
8
  useEditorStore
9
- } from "./chunk-ZXFHVN4I.js";
9
+ } from "./chunk-WFAZNRI3.js";
10
10
  import {
11
11
  announce
12
12
  } from "./chunk-67FJ4W6N.js";