@popcraft/cli 0.53.10 → 0.53.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/popcraft.mjs +54 -5
- package/package.json +2 -2
package/dist/popcraft.mjs
CHANGED
|
@@ -1198,7 +1198,7 @@ function operations(spec = openapi) {
|
|
|
1198
1198
|
}
|
|
1199
1199
|
async function call(target2, method, path, opts = {}) {
|
|
1200
1200
|
const qs = new URLSearchParams(opts.query ?? {}).toString();
|
|
1201
|
-
const headers = { "user-agent": `popcraft-cli/${"0.53.
|
|
1201
|
+
const headers = { "user-agent": `popcraft-cli/${"0.53.11"}`, ...opts.headers };
|
|
1202
1202
|
if (target2.token) headers.authorization = `Bearer ${target2.token}`;
|
|
1203
1203
|
if (opts.contentType) headers["content-type"] = opts.contentType;
|
|
1204
1204
|
try {
|
|
@@ -32454,6 +32454,7 @@ var init_en2 = __esm({
|
|
|
32454
32454
|
"canvas.comment": "Comment",
|
|
32455
32455
|
"canvas.dismiss": "Dismiss",
|
|
32456
32456
|
"canvas.dragToLassoLayers": "Drag to lasso layers",
|
|
32457
|
+
"canvas.figmaCopyCantBePasted": "Figma's Copy can't be pasted here. In Figma, use Copy as SVG or Copy as PNG.",
|
|
32457
32458
|
"canvas.forStraightEdges": "for straight edges",
|
|
32458
32459
|
"canvas.hold": "hold",
|
|
32459
32460
|
"canvas.linkSchemeNotAllowed": "Only http, https, mailto and tel links are allowed.",
|
|
@@ -97581,6 +97582,7 @@ function relinkCopies(doc2, copies) {
|
|
|
97581
97582
|
var TEXT_PATH_SOURCE_TYPES, isPathSource;
|
|
97582
97583
|
var init_text_links = __esm({
|
|
97583
97584
|
"lib/document/text-links.ts"() {
|
|
97585
|
+
"use strict";
|
|
97584
97586
|
init_transform();
|
|
97585
97587
|
TEXT_PATH_SOURCE_TYPES = ["VECTOR", "ELLIPSE", "RECTANGLE", "POLYGON", "STAR", "LINE", "ARROW", "FRAME"];
|
|
97586
97588
|
isPathSource = (n) => !!n && TEXT_PATH_SOURCE_TYPES.includes(n.type);
|
|
@@ -247048,6 +247050,7 @@ function rescaleTextEffect(node2) {
|
|
|
247048
247050
|
var DEFAULTS, BLACK5, WHITE5, fillPaint, fillColor, shadow, round, OUTLINED;
|
|
247049
247051
|
var init_effect_presets = __esm({
|
|
247050
247052
|
"lib/text/effect-presets.ts"() {
|
|
247053
|
+
"use strict";
|
|
247051
247054
|
init_effects();
|
|
247052
247055
|
DEFAULTS = {
|
|
247053
247056
|
SHADOW: { distance: 17.68, angle: 45, blur: 12.5, thickness: 0, intensity: 45 },
|
|
@@ -248125,6 +248128,7 @@ function resyncText(doc2, ids2) {
|
|
|
248125
248128
|
var isVirtualId;
|
|
248126
248129
|
var init_invariants2 = __esm({
|
|
248127
248130
|
"lib/document/invariants.ts"() {
|
|
248131
|
+
"use strict";
|
|
248128
248132
|
init_auto_layout();
|
|
248129
248133
|
init_scene_graph();
|
|
248130
248134
|
init_text_bounds();
|
|
@@ -249006,6 +249010,7 @@ function fillPhotoFrame(doc2, groupId, imageUrl, size6, name2 = "Photo", credit)
|
|
|
249006
249010
|
var isPhotoFrame;
|
|
249007
249011
|
var init_photo_frames = __esm({
|
|
249008
249012
|
"lib/document/photo-frames.ts"() {
|
|
249013
|
+
"use strict";
|
|
249009
249014
|
init_dist_node();
|
|
249010
249015
|
init_scene_graph();
|
|
249011
249016
|
init_types();
|
|
@@ -249150,6 +249155,7 @@ function beforeWrite() {
|
|
|
249150
249155
|
var leave;
|
|
249151
249156
|
var init_read_only = __esm({
|
|
249152
249157
|
"lib/editor/modes/read-only.ts"() {
|
|
249158
|
+
"use strict";
|
|
249153
249159
|
leave = null;
|
|
249154
249160
|
}
|
|
249155
249161
|
});
|
|
@@ -252662,6 +252668,7 @@ function resizeWindow(doc2, target2, rect) {
|
|
|
252662
252668
|
}
|
|
252663
252669
|
var init_crop = __esm({
|
|
252664
252670
|
"lib/editor/crop.ts"() {
|
|
252671
|
+
"use strict";
|
|
252665
252672
|
init_dist_node();
|
|
252666
252673
|
init_scene_graph();
|
|
252667
252674
|
init_photo_frames();
|
|
@@ -253125,6 +253132,7 @@ function getActiveRenderer() {
|
|
|
253125
253132
|
var active;
|
|
253126
253133
|
var init_renderer_registry = __esm({
|
|
253127
253134
|
"lib/engine/renderer-registry.ts"() {
|
|
253135
|
+
"use strict";
|
|
253128
253136
|
active = null;
|
|
253129
253137
|
}
|
|
253130
253138
|
});
|
|
@@ -256193,6 +256201,7 @@ fn shade(uv: vec2<f32>, res: vec2<f32>, tm: f32) -> vec4<f32> {
|
|
|
256193
256201
|
var SHADER_PRESETS, shaderPreset, legacyPresetOf, DEFAULT_SHADER_PRESET, DEFAULT_TEXTURE_PARAMS, f, vec4, NOISE_LIB;
|
|
256194
256202
|
var init_shader_presets = __esm({
|
|
256195
256203
|
"lib/engine/shader-presets.ts"() {
|
|
256204
|
+
"use strict";
|
|
256196
256205
|
init_shader_graph();
|
|
256197
256206
|
init_shader_graph_presets();
|
|
256198
256207
|
init_shader_presets_legacy();
|
|
@@ -256889,6 +256898,7 @@ var init_apply2 = __esm({
|
|
|
256889
256898
|
var HYPERY_CLIENT_ID, HYPERY_GATEWAY_URL, HYPERY_AI_SCOPES, plansEnabled, HYPERY_BILLING_SCOPES, HYPERY_AUDIO_SCOPES, HYPERY_SCOPES, cloudEnabled;
|
|
256890
256899
|
var init_config2 = __esm({
|
|
256891
256900
|
"lib/client/cloud/config.ts"() {
|
|
256901
|
+
"use strict";
|
|
256892
256902
|
HYPERY_CLIENT_ID = process.env.NEXT_PUBLIC_HYPERY_CLIENT_ID ?? "";
|
|
256893
256903
|
HYPERY_GATEWAY_URL = process.env.NEXT_PUBLIC_HYPERY_GATEWAY_URL ?? "https://hypery.ai";
|
|
256894
256904
|
HYPERY_AI_SCOPES = ["ai:chat", "ai:completions", "ai:models", "ai:images"];
|
|
@@ -257155,6 +257165,7 @@ function followPeers(peers) {
|
|
|
257155
257165
|
var PALETTE, usePresence, awareness, CURSOR_SEND_MS, VIEWPORT_SEND_MS, cursorTimer, pendingCursor, sentCursor, EMOTE_MS, lastFollowCamera;
|
|
257156
257166
|
var init_presence = __esm({
|
|
257157
257167
|
"lib/collab/presence.ts"() {
|
|
257168
|
+
"use strict";
|
|
257158
257169
|
init_esm();
|
|
257159
257170
|
init_editor_store();
|
|
257160
257171
|
init_status_announcements();
|
|
@@ -257995,6 +258006,7 @@ async function docExists(id3) {
|
|
|
257995
258006
|
var INDEX_KEY, docKey, thumbKey, THUMB_MAX_BYTES, THUMB_TYPES, LEGACY_DATA_URL, migrating, SPLIT_LAYOUT, nodeKey, WRITER, persisted, saving, deletedHere, keyval, keyvalStore;
|
|
257996
258007
|
var init_document_library = __esm({
|
|
257997
258008
|
"lib/storage/document-library.ts"() {
|
|
258009
|
+
"use strict";
|
|
257998
258010
|
init_idb();
|
|
257999
258011
|
init_media_types();
|
|
258000
258012
|
init_collapse_duplicates();
|
|
@@ -258066,6 +258078,7 @@ function onTabMessage(fn) {
|
|
|
258066
258078
|
var EDITOR_HOME, localDocPath, cloudFilePath, CHANNEL2, channel2;
|
|
258067
258079
|
var init_tab_mode = __esm({
|
|
258068
258080
|
"lib/desktop/tab-mode.ts"() {
|
|
258081
|
+
"use strict";
|
|
258069
258082
|
EDITOR_HOME = "/home";
|
|
258070
258083
|
localDocPath = (docId) => `${EDITOR_HOME}?doc=${encodeURIComponent(docId)}`;
|
|
258071
258084
|
cloudFilePath = (key5) => `/pop/${encodeURIComponent(key5)}`;
|
|
@@ -260746,6 +260759,7 @@ function retuneShaderAudio(node2, fillId) {
|
|
|
260746
260759
|
}
|
|
260747
260760
|
var init_shader_audio = __esm({
|
|
260748
260761
|
"lib/motion/shader-audio.ts"() {
|
|
260762
|
+
"use strict";
|
|
260749
260763
|
init_shader_params();
|
|
260750
260764
|
init_modifier_edit();
|
|
260751
260765
|
init_keys();
|
|
@@ -261510,6 +261524,7 @@ function breakpointView(state, doc2 = state.document) {
|
|
|
261510
261524
|
var storedDocument;
|
|
261511
261525
|
var init_view = __esm({
|
|
261512
261526
|
"lib/motion/view.ts"() {
|
|
261527
|
+
"use strict";
|
|
261513
261528
|
init_motion_slice();
|
|
261514
261529
|
init_transport_clock();
|
|
261515
261530
|
init_autokey();
|
|
@@ -262778,6 +262793,7 @@ function formatLimit(key5, max3) {
|
|
|
262778
262793
|
var formatBytes;
|
|
262779
262794
|
var init_limits2 = __esm({
|
|
262780
262795
|
"lib/billing/limits.ts"() {
|
|
262796
|
+
"use strict";
|
|
262781
262797
|
init_format();
|
|
262782
262798
|
init_plans();
|
|
262783
262799
|
formatBytes = formatFileSize;
|
|
@@ -273492,6 +273508,7 @@ async function prepareTemplate(t3) {
|
|
|
273492
273508
|
var templateMediaSources, MEDIA_FETCH_TIMEOUT_MS2, PREPARE_BUDGET_MS, MEDIA_CONCURRENCY, timeoutOf;
|
|
273493
273509
|
var init_use = __esm({
|
|
273494
273510
|
"lib/templates/use.ts"() {
|
|
273511
|
+
"use strict";
|
|
273495
273512
|
init_capture();
|
|
273496
273513
|
templateMediaSources = (t3, hash3) => [
|
|
273497
273514
|
`/templates/media/${hash3}`,
|
|
@@ -306993,6 +307010,7 @@ function decodeSource(key5, label3) {
|
|
|
306993
307010
|
var DECODE_CACHE_BYTES, cache7, pending4, held, sizeOf, lengths, decodedLengths, DECODE_TIMEOUT_MS, decodedAudio, decodedSource, pcmOf;
|
|
306994
307011
|
var init_audio_decode = __esm({
|
|
306995
307012
|
"lib/motion/audio-decode.ts"() {
|
|
307013
|
+
"use strict";
|
|
306996
307014
|
init_media_store();
|
|
306997
307015
|
init_audio_plan();
|
|
306998
307016
|
init_time_stretch();
|
|
@@ -311773,7 +311791,6 @@ function startCloudSync() {
|
|
|
311773
311791
|
var status, readOnlyDoc, activeLink, statusListeners, notice, urlArmed, opening, syncStatus, canEdit, uploaded, MEDIA_UPLOAD_PARALLEL, pushTimer, pushing, dirty, pendingMedia, collab, collabSession, collabAnonymous, uploadedThumbs, thumbCheckedAt, THUMB_EVERY_MS, THUMB_MIN_GAP_MS, putThumbnail, openingFiles, mediaHealed, started2;
|
|
311774
311792
|
var init_sync2 = __esm({
|
|
311775
311793
|
"lib/client/cloud/sync.ts"() {
|
|
311776
|
-
"use strict";
|
|
311777
311794
|
init_paint_repair();
|
|
311778
311795
|
init_migrate();
|
|
311779
311796
|
init_view();
|
|
@@ -312382,6 +312399,7 @@ function creditLine(c2) {
|
|
|
312382
312399
|
var MAX_PHOTO_PAGE, MAX_PHOTO_QUERY, UUID, isPhotoId, photoImagePath;
|
|
312383
312400
|
var init_stock = __esm({
|
|
312384
312401
|
"lib/photos/stock.ts"() {
|
|
312402
|
+
"use strict";
|
|
312385
312403
|
MAX_PHOTO_PAGE = 12;
|
|
312386
312404
|
MAX_PHOTO_QUERY = 200;
|
|
312387
312405
|
UUID = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
|
|
@@ -313043,6 +313061,7 @@ function applyTextPath(layout2, path, tp, rebase = true) {
|
|
|
313043
313061
|
var defaultCircleRadius, ownsPath, mapPoint;
|
|
313044
313062
|
var init_text_path = __esm({
|
|
313045
313063
|
"lib/engine/text/text-path.ts"() {
|
|
313064
|
+
"use strict";
|
|
313046
313065
|
init_scene_graph();
|
|
313047
313066
|
init_transform();
|
|
313048
313067
|
init_shape_to_path();
|
|
@@ -313160,6 +313179,7 @@ function areaBounds(rings) {
|
|
|
313160
313179
|
}
|
|
313161
313180
|
var init_text_area = __esm({
|
|
313162
313181
|
"lib/engine/text/text-area.ts"() {
|
|
313182
|
+
"use strict";
|
|
313163
313183
|
}
|
|
313164
313184
|
});
|
|
313165
313185
|
|
|
@@ -317504,6 +317524,7 @@ async function exportSettingFile(renderer, node2, setting, doc2, styles) {
|
|
|
317504
317524
|
var MIME, DEFAULT_EXPORT, exportSettingsOf;
|
|
317505
317525
|
var init_export = __esm({
|
|
317506
317526
|
"lib/io/export.ts"() {
|
|
317527
|
+
"use strict";
|
|
317507
317528
|
init_download();
|
|
317508
317529
|
init_scene_graph();
|
|
317509
317530
|
init_codecs();
|
|
@@ -318437,7 +318458,6 @@ function agentToolList() {
|
|
|
318437
318458
|
var AGENT_CAPABILITIES, legacyCommandId, legacyTools, blobToDataUrl3, provided, legacyTool, legacyToolList;
|
|
318438
318459
|
var init_agent = __esm({
|
|
318439
318460
|
"lib/commands/agent.ts"() {
|
|
318440
|
-
"use strict";
|
|
318441
318461
|
init_types5();
|
|
318442
318462
|
init_registry();
|
|
318443
318463
|
init_errors();
|
|
@@ -319235,6 +319255,8 @@ var init_ui = __esm({
|
|
|
319235
319255
|
var svg_place_exports = {};
|
|
319236
319256
|
__export(svg_place_exports, {
|
|
319237
319257
|
MAX_SVG_LAYER_BYTES: () => MAX_SVG_LAYER_BYTES,
|
|
319258
|
+
extractSvgMarkup: () => extractSvgMarkup,
|
|
319259
|
+
isFigmaClipboardHtml: () => isFigmaClipboardHtml,
|
|
319238
319260
|
isSvgMarkup: () => isSvgMarkup,
|
|
319239
319261
|
placeSvgLayers: () => placeSvgLayers
|
|
319240
319262
|
});
|
|
@@ -319245,6 +319267,26 @@ function isSvgMarkup(text) {
|
|
|
319245
319267
|
const tail = text.trimEnd();
|
|
319246
319268
|
return /<\/svg\s*>$/i.test(tail) || /^<svg[^>]*\/>$/i.test(head2.trimEnd());
|
|
319247
319269
|
}
|
|
319270
|
+
function isFigmaClipboardHtml(html) {
|
|
319271
|
+
return !!html && /\(fig(?:meta|ma)\)/.test(html);
|
|
319272
|
+
}
|
|
319273
|
+
function extractSvgMarkup(text) {
|
|
319274
|
+
if (!text) return null;
|
|
319275
|
+
if (isSvgMarkup(text)) return text;
|
|
319276
|
+
const find2 = (s) => {
|
|
319277
|
+
const start2 = s.search(/<svg[\s>/]/i);
|
|
319278
|
+
if (start2 < 0) return null;
|
|
319279
|
+
const end = s.toLowerCase().lastIndexOf("</svg>");
|
|
319280
|
+
if (end < start2) return null;
|
|
319281
|
+
const svg = s.slice(start2, end + 6);
|
|
319282
|
+
return isSvgMarkup(svg) ? svg : null;
|
|
319283
|
+
};
|
|
319284
|
+
const direct = find2(text);
|
|
319285
|
+
if (direct) return direct;
|
|
319286
|
+
if (!/<svg/i.test(text)) return null;
|
|
319287
|
+
const decoded = text.replace(/</g, "<").replace(/>/g, ">").replace(/"/g, '"').replace(/'|'/g, "'").replace(/ /g, " ").replace(/&/g, "&");
|
|
319288
|
+
return find2(decoded);
|
|
319289
|
+
}
|
|
319248
319290
|
function placeSvgLayers(doc2, parentId, svg, place4) {
|
|
319249
319291
|
if (!doc2.nodes[parentId] || svg.length > MAX_SVG_LAYER_BYTES) return null;
|
|
319250
319292
|
const frame3 = createFrame({ name: place4.name, x: place4.cx, y: place4.cy, width: 1, height: 1, fills: [], backgroundColor: { r: 1, g: 1, b: 1, a: 0 }, clipsContent: false });
|
|
@@ -328790,7 +328832,7 @@ var init_package = __esm({
|
|
|
328790
328832
|
"packages/runtime/package.json"() {
|
|
328791
328833
|
package_default = {
|
|
328792
328834
|
name: "@popcraft/runtime",
|
|
328793
|
-
version: "0.53.
|
|
328835
|
+
version: "0.53.11",
|
|
328794
328836
|
description: "What code exported from PopCraft shares: the meaning of expressions (operators and functions) and, as it grows, the parts of a design's behaviour that are common code rather than generated React.",
|
|
328795
328837
|
license: "MIT",
|
|
328796
328838
|
homepage: "https://popcraft.app/docs/exporting/nextjs",
|
|
@@ -353456,6 +353498,7 @@ function exportsOf(source3) {
|
|
|
353456
353498
|
var CODE_LIMITS, packageOf;
|
|
353457
353499
|
var init_source2 = __esm({
|
|
353458
353500
|
"lib/code/source.ts"() {
|
|
353501
|
+
"use strict";
|
|
353459
353502
|
CODE_LIMITS = { modules: 100, sourceLength: 2e5, packages: 12 };
|
|
353460
353503
|
packageOf = (spec) => spec.split("/").slice(0, spec.startsWith("@") ? 2 : 1).join("/");
|
|
353461
353504
|
}
|
|
@@ -353498,6 +353541,7 @@ function compileModule(module2) {
|
|
|
353498
353541
|
var import_sucrase, BUILT_IN, memo4;
|
|
353499
353542
|
var init_compile2 = __esm({
|
|
353500
353543
|
"lib/code/compile.ts"() {
|
|
353544
|
+
"use strict";
|
|
353501
353545
|
import_sucrase = __toESM(require_dist2());
|
|
353502
353546
|
init_source2();
|
|
353503
353547
|
init_source2();
|
|
@@ -368157,6 +368201,7 @@ var init_doc2 = __esm({
|
|
|
368157
368201
|
var POSTER_KEY, MAX_PREVIEW_BYTES2, PREVIEW_STILL_TYPE, previewPath;
|
|
368158
368202
|
var init_motion3 = __esm({
|
|
368159
368203
|
"lib/marketplace/motion.ts"() {
|
|
368204
|
+
"use strict";
|
|
368160
368205
|
init_instances2();
|
|
368161
368206
|
POSTER_KEY = "poster";
|
|
368162
368207
|
MAX_PREVIEW_BYTES2 = 4 * 1024 * 1024;
|
|
@@ -401365,6 +401410,7 @@ function record(source, namespaces, globals, limits) {
|
|
|
401365
401410
|
var HELPER_NAMES;
|
|
401366
401411
|
var init_helper_names = __esm({
|
|
401367
401412
|
"lib/agent/design-script/helper-names.ts"() {
|
|
401413
|
+
"use strict";
|
|
401368
401414
|
HELPER_NAMES = ["draw", "marks", "fit", "motion", "captions", "overlays", "texture", "pointer", "windows", "devices", "type", "beat", "web", "social", "video", "site", "effects"];
|
|
401369
401415
|
}
|
|
401370
401416
|
});
|
|
@@ -401604,6 +401650,7 @@ function placeDesign(doc2, built, source3, size6, name2, at4) {
|
|
|
401604
401650
|
var DESIGN_NAMESPACES, DERIVED2, templateOfBuild;
|
|
401605
401651
|
var init_build3 = __esm({
|
|
401606
401652
|
"lib/agent/design-script/build.ts"() {
|
|
401653
|
+
"use strict";
|
|
401607
401654
|
init_hash();
|
|
401608
401655
|
init_scene_graph();
|
|
401609
401656
|
init_libraries();
|
|
@@ -401633,6 +401680,7 @@ function designFrameOf(doc2, id3) {
|
|
|
401633
401680
|
}
|
|
401634
401681
|
var init_locate = __esm({
|
|
401635
401682
|
"lib/agent/design-script/locate.ts"() {
|
|
401683
|
+
"use strict";
|
|
401636
401684
|
}
|
|
401637
401685
|
});
|
|
401638
401686
|
|
|
@@ -401745,6 +401793,7 @@ function designRecorder() {
|
|
|
401745
401793
|
var installed2;
|
|
401746
401794
|
var init_recorders = __esm({
|
|
401747
401795
|
"lib/agent/design-script/recorders.ts"() {
|
|
401796
|
+
"use strict";
|
|
401748
401797
|
installed2 = null;
|
|
401749
401798
|
}
|
|
401750
401799
|
});
|
|
@@ -414380,7 +414429,7 @@ init_resources();
|
|
|
414380
414429
|
init_desktop();
|
|
414381
414430
|
init_hypery();
|
|
414382
414431
|
import { createInterface } from "node:readline";
|
|
414383
|
-
var VERSION2 = "0.53.
|
|
414432
|
+
var VERSION2 = "0.53.11";
|
|
414384
414433
|
var HELP = `popcraft ${VERSION2} \u2014 the PopCraft command line
|
|
414385
414434
|
|
|
414386
414435
|
Files (headless, on .popcraft files):
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@popcraft/cli",
|
|
3
|
-
"version": "0.53.
|
|
3
|
+
"version": "0.53.11",
|
|
4
4
|
"description": "The PopCraft command line: edit .popcraft files headlessly, call the REST API, publish to the marketplace and manage the desktop app's local plugins, themes, fonts, skills and agents.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"homepage": "https://popcraft.app/docs/api/cli",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"esbuild": "0.28.2"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@popcraft/kit": "0.53.
|
|
37
|
+
"@popcraft/kit": "0.53.11"
|
|
38
38
|
},
|
|
39
39
|
"scripts": {
|
|
40
40
|
"build": "node build.mjs",
|