@plitzi/sdk-authoring 0.38.17 → 0.38.19
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/CHANGELOG.md +90 -0
- package/dist/index-src.js +969 -956
- package/dist/index.js +1 -1
- package/dist/node.d.ts +1 -1
- package/dist/node.js +12 -28
- package/package.json +7 -7
package/dist/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { $ as explainKindOf, $i as
|
|
1
|
+
import { $ as explainKindOf, $i as groupBindings, $n as removeState, $r as elementsFromManifest, $t as expandShorthandPatch, A as onScreen, Aa as elementTypeNames, Ai as reference, An as flagGateOf, Ar as on, At as createTw, B as catalogTemplateFiles, Ba as t$3, Bi as component, Bn as appendState, Br as onScroll, Bt as isStyleDeclaration, C as diffPictures, Ca as elementCatalog, Ci as listItem, Cn as digest, Cr as carouselPause, Ct as refusalOf, D as unrollPage, Da as elementSlots, Di as pagination, Dn as locate, Dr as closeModal, Dt as withNotificationsCss, E as loadImages, Ea as elementPartTypes, Ei as nodeHtml, En as instanceSelectorFor, Er as closeDialog, Et as notificationsCss, F as dataIssues, Fa as elementAttributeNames, Fi as tabContainerHeader, Fn as BUILTIN_UTILITIES, Fr as onInterval, Ft as className, G as darkScheme, Ga as c, Gi as inferredLinkMode, Gn as clearState, Gr as reloadApi, Gt as STYLE_STATES, H as toPortableSource, Ha as i$1, Hi as defaultLabel, Hn as authLogout, Hr as openDialog, Ht as splitClassList, I as answerAction, Ia as e, Ii as tabContainerItem, In as applyUtility, Ir as onKey, It as classNames, J as importProbe, Ja as s$1, Ji as activeOn, Jn as delay, Jr as scrollIntoView, Jt as sameBlocks, K as importSlug, Ka as n$1, Ki as COMPONENT_SOURCES, Kn as copyToClipboard, Kr as resetForm, Kt as css, L as CATALOG_TEMPLATE_IDENTITY, La as i$2, Li as text, Ln as getUtility, Lr as onLoad, Lt as classRefs, M as failedFlowText, Ma as typeTriggerDefinitions, Mi as svg, Mn as authoringCodesTable, Mr as onFlowEnd, Mt as column, N as readDevTools, Na as n$2, Ni as tabContainer, Nn as defineAction, Nr as onFlowError, Nt as grid, O as inspectDocument, Oa as elementSourceTypes, Oi as paragraph, On as pathForSlug, Or as declaredCallback, Ot as FIXABLE_CODES, P as readDevToolsInPage, Pa as t$1, Pi as tabContainerBody, Pn as taskAction, Pr as onFlowProgress, Pt as row, Q as explain, Qa as o$1, Qi as boundAttribute, Qn as navigate, Qr as updateElement, Qt as expandShorthand, R as blankSpace, Ra as n$3, Ri as themeToggle, Rn as SET_STATE_TYPES, Rr as onPageLoad, Rt as isClassModifier, S as comparePictures, Sa as elementCallbacks, Si as list, Sr as carouselNext, St as SpaceRefusedError, T as profilePictures, Ta as elementLeafTypes, Ti as modalContainer, Tn as buildHandles, Tr as carouselPrevious, Tt as pageFamily, U as space$1, Ua as o, Ui as defineElement, Un as authRefreshDetails, Ur as openModal, Ut as styles, V as emptyTemplateFiles, Va as a, Vi as defaultAttributes, Vn as authLogin, Vr as onSubmit, Vt as modifierClassName, W as space, Wa as s, Wi as element, Wn as cancelServerAction, Wr as publishOn, Wt as BREAKPOINTS, X as EXPLAIN_KINDS, Xa as a$2, Xi as authorBinding, Xn as invalidateQueries, Xr as setFieldValue, Xt as toResponsive, Y as BUILDER_NAMES, Ya as t, Yi as activeWhen, Yn as hostAction, Yr as scrollTo, Yt as toBlocks, Z as GLOBAL_CALLBACK_BUILDERS, Za as i$3, Zi as bindTemplate, Zn as moveState, Zr as toggleElement, Zt as cssShorthands, _ as summariseRenders, _a as AuthoringError, _i as form, _r as applyBuiltinCallback, _t as assertSpaceValid, a as locateClasses, aa as visibleWhen, ai as blockJsx, an as isCssProperty, ar as toggleState, at as SCHEMA_SETTINGS, b as pageTexts, ba as elementAncestorTypes, bi as image, br as cancelApi, bt as suggestClassOverrides, c as validateSnippet, ca as r, ci as carouselTrack, cr as authorFlow, ct as actionSpecFromEntry, d as singlePageSpace, da as actionSource, di as custom, dr as named, dt as BUILTIN_TRANSFORMERS, ea as hasVisibilityBinding, ei as withPluginCatalogs, en as expandShorthandTraced, er as runServerAction, et as explainList, f as withElement, fa as source, fi as dialogContainer, fr as when, ft as getTransformer, g as inspectRenders, ga as AUTHORING_CODES, gi as fontAwesome, gr as BUILTIN_GLOBAL_CALLBACKS, gt as PAGE_SPEC_FIELDS, h as openPage, ha as scope, hi as embed, hr as whileRunning, ht as assertSnippetValid, i as lintSpace, ia as variantFrom, ii as blockHtml, in as cssPropertyName, ir as toggleInState, it as specToSource, j as onScreenIfChosen, ja as typeCallbackDefinitions, ji as richText, jn as flagSpecOf, jr as onClick, jt as tw, k as inspectPage, ka as elementTriggers, ki as plitziSdk, kn as selectorFor, kr as declaredTrigger, kt as tokens, l as validateSpace, la as t$2, li as channel, lr as authorFlows, lt as actionToSource, m as shortcutKey, ma as closest, mi as dropdownPopup, mr as whenSucceeded, mt as transformerCatalog, n as authorSpace, na as resolveSource, ni as i, nn as cssNumberValue, nr as setState, nt as ELEMENT_FIELDS, o as locateElements, oa as withVisibility, oi as button, on as isCustomProperty, or as twigTemplate, ot as specFromSpace, p as pressShortcut, pa as twig, pi as dropdown, pr as whenFailed, pt as suggestTransformer, q as importedFiles, qa as r$3, qi as GLOBAL_SOURCES, qn as cycleState, qr as scrollBy, qt as isRuleSetSpec, r as fixSpace, ra as toBindingSpecs, ri as apiContainer, rn as cssProperties, rr as stepState, rt as SPACE_FIELDS, s as planFixes, sa as n, si as carousel, sn as suggestCssProperty, sr as webHook, st as compareSpaces, t as authorSnippet, ta as hiddenWhen, ti as d, tn as shorthandLonghands, tr as runServerActionOrNotify, tt as explanationText, u as compactSvg, ui as container, ur as flowStepIds, ut as withNamedIds, v as PAGE_TEXT_LIMIT, va as authoringCodeEntry, vi as formControl, vr as getGlobalCallback, vt as suggestSpace, w as pageRegions, wa as elementDefaultAttributes, wi as markdown, wn as slugify, wr as carouselPlay, wt as familyOf, x as alignPictures, xa as elementAttributeValues, xi as link, xr as carouselGoTo, xt as unusedDeclarations, y as compareTexts, ya as isSuggestionCode, yi as heading, yr as announceOn, yt as withoutQuieted, z as blankTemplateFiles, za as r$1, zi as video, zn as addNotification, zr as onPointerDown, zt as isClassRef } from "./index-src.js";
|
|
2
2
|
import { n as e$1, r as r$2, t as a$1 } from "./index-declare.js";
|
|
3
3
|
export { AUTHORING_CODES, AuthoringError, BREAKPOINTS, BUILDER_NAMES, a as BUILTIN_ELEMENT_CALLBACKS, BUILTIN_GLOBAL_CALLBACKS, t as BUILTIN_PARAM_TYPES, BUILTIN_TRANSFORMERS, BUILTIN_UTILITIES, CATALOG_TEMPLATE_IDENTITY, COMPONENT_SOURCES, t$1 as DOCUMENT_SCROLLS, ELEMENT_FIELDS, EXPLAIN_KINDS, FIXABLE_CODES, GLOBAL_CALLBACK_BUILDERS, GLOBAL_SOURCES, t$2 as MOTION_ENTERS, r as MOTION_LOOPS, n as MOTION_TRIGGERS, i as NOTIFICATIONS_FIELDS, t$3 as NOTIFICATION_APPEARANCES, r$1 as NOTIFICATION_DEFAULTS, e as NOTIFICATION_PLACEMENTS, PAGE_SPEC_FIELDS, PAGE_TEXT_LIMIT, SCHEMA_SETTINGS, i$1 as SCROLL_CALLBACKS, SET_STATE_TYPES, SPACE_FIELDS, STYLE_STATES, SpaceRefusedError, actionSource, actionSpecFromEntry, actionToSource, activeOn, activeWhen, addNotification, alignPictures, announceOn, answerAction, apiContainer, appendState, applyBuiltinCallback, s as applyElementCallback, applyUtility, assertSnippetValid, assertSpaceValid, authLogin, authLogout, authRefreshDetails, authorBinding, authorFlow, authorFlows, authorSnippet, authorSpace, authoringCodeEntry, authoringCodesTable, bindTemplate, blankSpace, space as blankSpaceSpec, blankTemplateFiles, blockHtml, blockJsx, boundAttribute, buildHandles, button, cancelApi, cancelServerAction, carousel, carouselGoTo, carouselNext, carouselPause, carouselPlay, carouselPrevious, carouselTrack, catalogTemplateFiles, channel, className, classNames, classRefs, clearState, closeDialog, closeModal, closest, column, compactSvg, comparePictures, compareSpaces, compareTexts, component, container, copyToClipboard, createTw, css, cssNumberValue, cssProperties, cssPropertyName, cssShorthands, custom, cycleState, darkScheme, dataIssues, declaredCallback, declaredTrigger, defaultAttributes, defaultLabel, defineAction, defineElement, a$1 as definePlugin, delay, dialogContainer, diffPictures, digest, dropdown, dropdownPopup, element, elementAncestorTypes, elementAttributeNames, elementAttributeValues, elementCallbacks, elementCatalog, r$2 as elementDeclaration, elementDefaultAttributes, elementLeafTypes, elementPartTypes, elementSlots, elementSourceTypes, elementTriggers, elementTypeNames, elementsFromManifest, embed, space$1 as emptySpaceSpec, emptyTemplateFiles, expandShorthand, expandShorthandPatch, expandShorthandTraced, explain, explainKindOf, explainList, explanationText, failedFlowText, familyOf, fixSpace, flagGateOf, flagSpecOf, flowStepIds, fontAwesome, form, formControl, o as getElementCallback, getGlobalCallback, getTransformer, getUtility, grid, groupBindings, hasVisibilityBinding, heading, n$1 as hiddenParams, hiddenWhen, hostAction, image, importProbe, importSlug, importedFiles, inferredLinkMode, inspectDocument, inspectPage, inspectRenders, instanceSelectorFor, s$1 as invalidParams, invalidateQueries, isClassModifier, isClassRef, isCssProperty, isCustomProperty, n$2 as isDocumentScroll, isRuleSetSpec, isStyleDeclaration, isSuggestionCode, link, lintSpace, list, listItem, loadImages, locate, locateClasses, locateElements, markdown, r$3 as missingRequiredParams, modalContainer, modifierClassName, moveState, named, navigate, nodeHtml, notificationsCss, on, onClick, onFlowEnd, onFlowError, onFlowProgress, onInterval, onKey, onLoad, onPageLoad, onPointerDown, onScreen, onScreenIfChosen, onScroll, onSubmit, openDialog, openModal, openPage, pageFamily, pageRegions, pageTexts, pagination, paragraph, pathForSlug, planFixes, plitziSdk, pressShortcut, profilePictures, publishOn, readDevTools, readDevToolsInPage, n$3 as readNotificationOptions, c as reconcileParams, reference, refusalOf, reloadApi, removeState, resetForm, resolveSource, richText, row, runServerAction, runServerActionOrNotify, sameBlocks, scope, scrollBy, scrollIntoView, scrollTo, selectorFor, setFieldValue, setState, shortcutKey, shorthandLonghands, singlePageSpace, slugify, source, i$2 as spaceCallbacks, specFromSpace, specToSource, splitClassList, d as splitNotificationsCss, stepState, styles, suggestClassOverrides, suggestCssProperty, suggestSpace, suggestTransformer, summariseRenders, svg, tabContainer, tabContainerBody, tabContainerHeader, tabContainerItem, taskAction, text, themeToggle, toBindingSpecs, toBlocks, i$3 as toBuilderParams, a$2 as toInteractionCallback, o$1 as toInteractionCallbacks, toPortableSource, toResponsive, toggleElement, toggleInState, toggleState, tokens, transformerCatalog, tw, twig, twigTemplate, typeCallbackDefinitions, typeTriggerDefinitions, unrollPage, unusedDeclarations, updateElement, validateSnippet, validateSpace, e$1 as valuesOf, variantFrom, video, visibleWhen, webHook, when, whenFailed, whenSucceeded, whileRunning, withElement, withNamedIds, withNotificationsCss, withPluginCatalogs, withVisibility, withoutQuieted };
|
package/dist/node.d.ts
CHANGED
|
@@ -1757,7 +1757,7 @@ export declare type IsolatedAuthoring = {
|
|
|
1757
1757
|
* native addon, no environment variable of this one. What it answers is checked again here (`validateSpace`), so a
|
|
1758
1758
|
* module that forges its own answer gains nothing by it.
|
|
1759
1759
|
*
|
|
1760
|
-
* Network access is not one Node's permission model takes away before Node 25: serve what it authors on
|
|
1760
|
+
* Network access is not one Node's permission model takes away before Node 25: serve what it authors on a host of
|
|
1761
1761
|
* its own (`createAuthoringHost` of `@plitzi/sdk-server`), never the app's, and do not run it where the network it
|
|
1762
1762
|
* reaches is one to keep it from.
|
|
1763
1763
|
*
|
package/dist/node.js
CHANGED
|
@@ -1,24 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Sn as y$1, Tn as buildHandles, _n as o$1, bn as s$1, cn as _, dn as d, fn as g, gn as m$1, hn as l$1, l as validateSpace, ln as a$1, mn as i$1, n as authorSpace, pn as h, u as compactSvg, ua as e, un as c$1, vn as p, xn as u, yn as r } from "./index-src.js";
|
|
2
2
|
import { existsSync, readFileSync, readdirSync, realpathSync, statSync } from "node:fs";
|
|
3
3
|
import m from "node:path";
|
|
4
4
|
import { fileURLToPath, pathToFileURL } from "node:url";
|
|
5
5
|
import { spawn } from "node:child_process";
|
|
6
|
-
var r = `plitzi/author.ts`;
|
|
7
|
-
var i$1 = "src/space";
|
|
8
|
-
var a$1 = `${i$1}/index.ts`;
|
|
9
|
-
var o$1 = "src/plugins";
|
|
10
|
-
var s$1 = ["index.ts", "index.tsx"];
|
|
11
|
-
var c$1 = "declaration.ts";
|
|
12
|
-
var l$1 = "functions";
|
|
13
|
-
var u = "vendor/plugins";
|
|
14
|
-
var d = "plugin-manifest.json";
|
|
15
|
-
var p = "public";
|
|
16
|
-
var m$1 = "src/data";
|
|
17
|
-
var h = "src/functions";
|
|
18
|
-
var g = "src/runtime";
|
|
19
|
-
`${g}`;
|
|
20
|
-
var v$1 = "dist";
|
|
21
|
-
//#endregion
|
|
22
6
|
//#region ../sdk-shared/dist/project/layout.mjs
|
|
23
7
|
var v = {
|
|
24
8
|
"plugin-entry-missing": {
|
|
@@ -319,13 +303,13 @@ var J = (e, { mode: a, space: o }) => [
|
|
|
319
303
|
holds: K(e)
|
|
320
304
|
},
|
|
321
305
|
{
|
|
322
|
-
at:
|
|
323
|
-
reads: `the project's functions are built from ${
|
|
306
|
+
at: g,
|
|
307
|
+
reads: `the project's functions are built from ${g}/ only`,
|
|
324
308
|
holds: q(e)
|
|
325
309
|
},
|
|
326
310
|
{
|
|
327
|
-
at:
|
|
328
|
-
reads: `the space's runtime is run from ${
|
|
311
|
+
at: _,
|
|
312
|
+
reads: `the space's runtime is run from ${_}/ only`,
|
|
329
313
|
holds: q(e)
|
|
330
314
|
},
|
|
331
315
|
...o === "local" ? [{
|
|
@@ -410,18 +394,18 @@ var Q = (e, t = {}) => {
|
|
|
410
394
|
let n = le(e, t), i = X(e, n), a = [
|
|
411
395
|
...W(e),
|
|
412
396
|
...R(e, {
|
|
413
|
-
folder:
|
|
397
|
+
folder: g,
|
|
414
398
|
accepted: ["index.ts"],
|
|
415
399
|
code: "functions-entry-missing",
|
|
416
400
|
lost: "none of the project’s functions runs",
|
|
417
|
-
write: `Write ${
|
|
401
|
+
write: `Write ${g}/index.ts exporting defineFunctions({ … }) by default.`
|
|
418
402
|
}),
|
|
419
403
|
...R(e, {
|
|
420
|
-
folder:
|
|
404
|
+
folder: _,
|
|
421
405
|
accepted: ["index.ts"],
|
|
422
406
|
code: "runtime-entry-missing",
|
|
423
407
|
lost: "the space’s runtime does not run",
|
|
424
|
-
write: `Write ${
|
|
408
|
+
write: `Write ${_}/index.ts exporting defineRuntime(…) by default — npx plitzi runtime add writes one.`
|
|
425
409
|
}),
|
|
426
410
|
...n.space === "local" ? re(e, i) : [],
|
|
427
411
|
...i,
|
|
@@ -470,8 +454,8 @@ var c = (e) => {
|
|
|
470
454
|
}
|
|
471
455
|
};
|
|
472
456
|
var l = (n, r, i) => {
|
|
473
|
-
let a = c(m.join(n,
|
|
474
|
-
return m.join(n, o ? m.join(
|
|
457
|
+
let a = c(m.join(n, y$1)), o = i !== void 0 && c(i).startsWith(`${a}${m.sep}`);
|
|
458
|
+
return m.join(n, o ? m.join(y$1, m.relative("src", r)).replace(/\.tsx?$/, ".js") : r);
|
|
475
459
|
};
|
|
476
460
|
//#endregion
|
|
477
461
|
//#region src/isolated.ts
|
|
@@ -743,7 +727,7 @@ var publicData = (folder) => fileReader(folder, "/");
|
|
|
743
727
|
* never serves (`dataDir`) — for `authorSpace`'s `serverData`: bindings are held to the file, and a provider reading
|
|
744
728
|
* one from the browser is refused.
|
|
745
729
|
*/
|
|
746
|
-
var projectData = (folder) => fileReader(folder,
|
|
730
|
+
var projectData = (folder) => fileReader(folder, h);
|
|
747
731
|
/**
|
|
748
732
|
* Every plugin under `folder` — `src/plugins/<Name>/declaration.ts`, its default export — with the folder it is in.
|
|
749
733
|
* Found by folder, as the server finds the plugins themselves, so a plugin is declared by being there and no list can
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@plitzi/sdk-authoring",
|
|
3
|
-
"version": "0.38.
|
|
3
|
+
"version": "0.38.19",
|
|
4
4
|
"license": "AGPL-3.0",
|
|
5
5
|
"files": [
|
|
6
6
|
"dist/index.js",
|
|
@@ -63,12 +63,12 @@
|
|
|
63
63
|
},
|
|
64
64
|
"devDependencies": {
|
|
65
65
|
"@microsoft/api-extractor": "^7.59.4",
|
|
66
|
-
"@plitzi/plitzi-ui": "^1.6.
|
|
67
|
-
"@plitzi/sdk-elements": "0.38.
|
|
68
|
-
"@plitzi/sdk-interactions": "0.38.
|
|
69
|
-
"@plitzi/sdk-schema": "0.38.
|
|
70
|
-
"@plitzi/sdk-shared": "0.38.
|
|
71
|
-
"@plitzi/sdk-style": "0.38.
|
|
66
|
+
"@plitzi/plitzi-ui": "^1.6.34",
|
|
67
|
+
"@plitzi/sdk-elements": "0.38.19",
|
|
68
|
+
"@plitzi/sdk-interactions": "0.38.19",
|
|
69
|
+
"@plitzi/sdk-schema": "0.38.19",
|
|
70
|
+
"@plitzi/sdk-shared": "0.38.19",
|
|
71
|
+
"@plitzi/sdk-style": "0.38.19",
|
|
72
72
|
"@types/react": "^19.3.0",
|
|
73
73
|
"eslint": "^9.39.5",
|
|
74
74
|
"prettier": "^3.9.10",
|