@makeswift/runtime 0.12.1 → 0.12.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.
- package/dist/Carousel.cjs.js +1 -1
- package/dist/Carousel.es.js +1 -1
- package/dist/Navigation.cjs.js +1 -1
- package/dist/Navigation.es.js +1 -1
- package/dist/PreviewProvider.es.js +1 -1
- package/dist/ReadOnlyText.cjs.js +1 -1
- package/dist/ReadOnlyText.es.js +2 -2
- package/dist/ReadOnlyTextV2.cjs.js +1 -1
- package/dist/ReadOnlyTextV2.es.js +2 -2
- package/dist/builder.cjs.js +1 -1
- package/dist/builder.es.js +1 -1
- package/dist/control-serialization.cjs.js +1 -1
- package/dist/control-serialization.es.js +1 -1
- package/dist/controls.cjs.js +3 -0
- package/dist/controls.cjs.js.map +1 -1
- package/dist/controls.es.js +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.cjs2.js +1 -1
- package/dist/index.cjs8.js +1 -1
- package/dist/index.cjs9.js +1 -1
- package/dist/index.es.js +1 -1
- package/dist/index.es2.js +1 -1
- package/dist/index.es5.js +1 -1
- package/dist/index.es6.js +1 -1
- package/dist/index.es8.js +1 -1
- package/dist/index.es9.js +1 -1
- package/dist/react-page.cjs.js +17 -4
- package/dist/react-page.cjs.js.map +1 -1
- package/dist/react-page.es.js +15 -5
- package/dist/react-page.es.js.map +1 -1
- package/dist/slate.es.js +1 -1
- package/dist/toText.cjs.js +1 -1
- package/dist/toText.es.js +2 -2
- package/dist/types/src/controls/color.d.ts +12 -4
- package/dist/types/src/controls/color.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/Carousel.cjs.js
CHANGED
|
@@ -38,8 +38,8 @@ var popcorn = require("@popmotion/popcorn");
|
|
|
38
38
|
var next = require("./index.cjs.js");
|
|
39
39
|
require("use-sync-external-store/shim");
|
|
40
40
|
var reactPage = require("./react-page.cjs.js");
|
|
41
|
-
require("./actions.cjs.js");
|
|
42
41
|
require("ts-pattern");
|
|
42
|
+
require("./actions.cjs.js");
|
|
43
43
|
require("uuid");
|
|
44
44
|
require("slate");
|
|
45
45
|
require("escape-html");
|
package/dist/Carousel.es.js
CHANGED
|
@@ -36,8 +36,8 @@ import { wrap } from "@popmotion/popcorn";
|
|
|
36
36
|
import { r as useBreakpoints, n as useResponsiveStyle, q as colorToString } from "./index.es.js";
|
|
37
37
|
import "use-sync-external-store/shim";
|
|
38
38
|
import { _ as useStyle } from "./react-page.es.js";
|
|
39
|
-
import "./actions.es.js";
|
|
40
39
|
import "ts-pattern";
|
|
40
|
+
import "./actions.es.js";
|
|
41
41
|
import "uuid";
|
|
42
42
|
import "slate";
|
|
43
43
|
import "escape-html";
|
package/dist/Navigation.cjs.js
CHANGED
|
@@ -39,8 +39,8 @@ var reactPage = require("./react-page.cjs.js");
|
|
|
39
39
|
var jsxRuntime = require("react/jsx-runtime");
|
|
40
40
|
var next = require("./index.cjs.js");
|
|
41
41
|
require("use-sync-external-store/shim");
|
|
42
|
-
require("./actions.cjs.js");
|
|
43
42
|
require("ts-pattern");
|
|
43
|
+
require("./actions.cjs.js");
|
|
44
44
|
require("uuid");
|
|
45
45
|
require("slate");
|
|
46
46
|
require("escape-html");
|
package/dist/Navigation.es.js
CHANGED
|
@@ -38,8 +38,8 @@ import { _ as useStyle } from "./react-page.es.js";
|
|
|
38
38
|
import { jsx, Fragment, jsxs } from "react/jsx-runtime";
|
|
39
39
|
import { l as useResponsiveColor, p as useResponsiveTextStyle, n as useResponsiveStyle, q as colorToString } from "./index.es.js";
|
|
40
40
|
import "use-sync-external-store/shim";
|
|
41
|
-
import "./actions.es.js";
|
|
42
41
|
import "ts-pattern";
|
|
42
|
+
import "./actions.es.js";
|
|
43
43
|
import "uuid";
|
|
44
44
|
import "slate";
|
|
45
45
|
import "escape-html";
|
|
@@ -23,7 +23,7 @@ import { J as ElementImperativeHandle, a as ReactRuntime, K as StoreContext, M a
|
|
|
23
23
|
import { createStore, applyMiddleware, combineReducers } from "redux";
|
|
24
24
|
import thunk from "redux-thunk";
|
|
25
25
|
import Router from "next/router";
|
|
26
|
-
import {
|
|
26
|
+
import { ca as getInitialState$3, cb as reducer$4, cc as getDocument$1, c as createDocument, cd as getComponentsMeta$1, ce as getComponentPropControllerDescriptors$1, ax as getBreakpoints, f as deepEqual, aE as getBuilderEditMode, cf as BuilderEditMode, cg as getDocumentKeysSortedByDepth, ch as getPropController, ci as getPropControllersHandle, cj as getElement, ck as getElementPropControllerDescriptors, cl as createPropController, j as isElementReference, a4 as isPropControllersHandle, cm as reducer$5, cn as reducer$7, co as reducer$8, cp as reducer$9, cq as reducer$a, cr as reducer$b, cs as reducer$c, ct as getInitialState$4 } from "./react-page.es.js";
|
|
27
27
|
import { removeIn, setIn } from "immutable";
|
|
28
28
|
import { A as ActionTypes, v as unregisterMeasurable, w as registerMeasurable, x as registerBuilderComponent, j as setBreakpoints, k as setLocale, y as changePathnameStart, z as changePathnameComplete, B as changeElementBoxModels, C as changeDocumentElementSize, D as handleWheel, E as handlePointerMove, F as elementFromPointChange, G as setIsInBuilder, H as unregisterBuilderComponent, I as unregisterPropControllers, J as registerPropControllers, K as registerPropControllersHandle, r as registerDocument, L as registerComponentHandle, M as messageBuilderPropController, N as registerDocumentEffect } from "./actions.es.js";
|
|
29
29
|
import { i as isMeasurable, a as getMeasurables$1, b as getBoxModels$1, m as measure, d as getBoxModel$1, r as reducer$6 } from "./box-models.es.js";
|
package/dist/ReadOnlyText.cjs.js
CHANGED
|
@@ -3,10 +3,10 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
|
3
3
|
var css = require("@emotion/css");
|
|
4
4
|
var React = require("react");
|
|
5
5
|
var next = require("./index.cjs.js");
|
|
6
|
+
require("ts-pattern");
|
|
6
7
|
var reactPage = require("./react-page.cjs.js");
|
|
7
8
|
require("./actions.cjs.js");
|
|
8
9
|
require("slate");
|
|
9
|
-
require("ts-pattern");
|
|
10
10
|
require("uuid");
|
|
11
11
|
require("escape-html");
|
|
12
12
|
require("slate-hyperscript");
|
package/dist/ReadOnlyText.es.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { cx } from "@emotion/css";
|
|
2
2
|
import { forwardRef } from "react";
|
|
3
3
|
import { L as useEnhancedTypography, N as useTypographyClassName, n as useResponsiveStyle } from "./index.es.js";
|
|
4
|
-
import
|
|
4
|
+
import "ts-pattern";
|
|
5
|
+
import { bD as richTextDTOtoDAO, _ as useStyle, c1 as BlockType, c2 as InlineType } from "./react-page.es.js";
|
|
5
6
|
import "./actions.es.js";
|
|
6
7
|
import "slate";
|
|
7
|
-
import "ts-pattern";
|
|
8
8
|
import "uuid";
|
|
9
9
|
import "escape-html";
|
|
10
10
|
import "slate-hyperscript";
|
|
@@ -16,10 +16,10 @@ var __objRest = (source, exclude) => {
|
|
|
16
16
|
};
|
|
17
17
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
18
18
|
var React = require("react");
|
|
19
|
+
require("ts-pattern");
|
|
19
20
|
var reactPage = require("./react-page.cjs.js");
|
|
20
21
|
require("./actions.cjs.js");
|
|
21
22
|
require("slate");
|
|
22
|
-
require("ts-pattern");
|
|
23
23
|
require("uuid");
|
|
24
24
|
require("escape-html");
|
|
25
25
|
require("slate-hyperscript");
|
|
@@ -14,10 +14,10 @@ var __objRest = (source, exclude) => {
|
|
|
14
14
|
return target;
|
|
15
15
|
};
|
|
16
16
|
import { forwardRef } from "react";
|
|
17
|
-
import
|
|
17
|
+
import "ts-pattern";
|
|
18
|
+
import { bG as RichTextV2Mode, bZ as InlineModePlugin, bX as BlockPlugin, bS as TypographyPlugin, b$ as TextAlignPlugin, c5 as InlinePlugin, _ as useStyle } from "./react-page.es.js";
|
|
18
19
|
import "./actions.es.js";
|
|
19
20
|
import "slate";
|
|
20
|
-
import "ts-pattern";
|
|
21
21
|
import "uuid";
|
|
22
22
|
import "escape-html";
|
|
23
23
|
import "slate-hyperscript";
|
package/dist/builder.cjs.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
3
|
var controlSerialization = require("./control-serialization.cjs.js");
|
|
4
|
+
require("ts-pattern");
|
|
4
5
|
require("./combobox.cjs.js");
|
|
5
6
|
require("./react-page.cjs.js");
|
|
6
7
|
require("redux");
|
|
@@ -8,7 +9,6 @@ require("redux-thunk");
|
|
|
8
9
|
require("./actions.cjs.js");
|
|
9
10
|
require("zod");
|
|
10
11
|
require("./breakpoints.cjs.js");
|
|
11
|
-
require("ts-pattern");
|
|
12
12
|
require("corporate-ipsum");
|
|
13
13
|
require("slate");
|
|
14
14
|
require("uuid");
|
package/dist/builder.es.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export { d as deserializeControl, b as deserializeControls, e as deserializeFunction, i as isSerializedFunction, s as serializeControl, a as serializeControls, c as serializeFunction } from "./control-serialization.es.js";
|
|
2
|
+
import "ts-pattern";
|
|
2
3
|
import "./combobox.es.js";
|
|
3
4
|
import "./react-page.es.js";
|
|
4
5
|
import "redux";
|
|
@@ -6,7 +7,6 @@ import "redux-thunk";
|
|
|
6
7
|
import "./actions.es.js";
|
|
7
8
|
import "zod";
|
|
8
9
|
import "./breakpoints.es.js";
|
|
9
|
-
import "ts-pattern";
|
|
10
10
|
import "corporate-ipsum";
|
|
11
11
|
import "slate";
|
|
12
12
|
import "uuid";
|
|
@@ -30,9 +30,9 @@ var __objRest = (source, exclude) => {
|
|
|
30
30
|
}
|
|
31
31
|
return target;
|
|
32
32
|
};
|
|
33
|
+
require("ts-pattern");
|
|
33
34
|
var combobox = require("./combobox.cjs.js");
|
|
34
35
|
var reactPage = require("./react-page.cjs.js");
|
|
35
|
-
require("ts-pattern");
|
|
36
36
|
require("./actions.cjs.js");
|
|
37
37
|
require("uuid");
|
|
38
38
|
require("slate");
|
|
@@ -30,9 +30,9 @@ var __objRest = (source, exclude) => {
|
|
|
30
30
|
return target;
|
|
31
31
|
};
|
|
32
32
|
const import_meta = {};
|
|
33
|
+
import "ts-pattern";
|
|
33
34
|
import { C as ComboboxControlType } from "./combobox.es.js";
|
|
34
35
|
import { ad as ListControlType, ae as ShapeControlType, ac as StyleV2ControlType, a9 as RichTextV2ControlType, ao as Types } from "./react-page.es.js";
|
|
35
|
-
import "ts-pattern";
|
|
36
36
|
import "./actions.es.js";
|
|
37
37
|
import "uuid";
|
|
38
38
|
import "slate";
|
package/dist/controls.cjs.js
CHANGED
|
@@ -26,7 +26,10 @@ exports.CheckboxControlType = number.CheckboxControlType;
|
|
|
26
26
|
exports.Number = number.Number;
|
|
27
27
|
exports.NumberControlType = number.NumberControlType;
|
|
28
28
|
exports.Color = reactPage.Color;
|
|
29
|
+
exports.ColorControlDataTypeKey = reactPage.ColorControlDataTypeKey;
|
|
30
|
+
exports.ColorControlDataTypeValueV1 = reactPage.ColorControlDataTypeValueV1;
|
|
29
31
|
exports.ColorControlType = reactPage.ColorControlType;
|
|
32
|
+
exports.ControlDataTypeKey = reactPage.ControlDataTypeKey;
|
|
30
33
|
exports.IconRadioGroupControlType = reactPage.IconRadioGroupControlType;
|
|
31
34
|
exports.Image = reactPage.Image$1;
|
|
32
35
|
exports.ImageControlType = reactPage.ImageControlType;
|
package/dist/controls.cjs.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"controls.cjs.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"controls.cjs.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/controls.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { a as Checkbox, C as CheckboxControlType, b as Number, N as NumberControlType } from "./number.es.js";
|
|
2
|
-
export {
|
|
2
|
+
export { aL as Color, aJ as ColorControlDataTypeKey, aK as ColorControlDataTypeValueV1, ai as ColorControlType, aI as ControlDataTypeKey, ah as IconRadioGroupControlType, aT as Image, ag as ImageControlType, a3 as ImageControlValueFormat, aV as Link, af as LinkControlType, aX as List, aZ as ListControl, aY as ListControlMessageType, ad as ListControlType, bz as ObjectType, Y as RichText, bB as RichTextControl, bA as RichTextControlMessageType, aa as RichTextControlType, bI as RichTextV2Control, bH as RichTextV2ControlMessageType, a9 as RichTextV2ControlType, bG as RichTextV2Mode, b6 as Select, aj as SelectControlType, b7 as Shape, b9 as ShapeControl, b8 as ShapeControlMessageType, ae as ShapeControlType, bi as Slot, bk as SlotControl, bj as SlotControlMessageType, ab as SlotControlType, bo as Style, bq as StyleControl, bp as StyleControlMessageType, a2 as StyleControlProperty, a8 as StyleControlType, bv as StyleV2Control, bu as StyleV2ControlMessageType, ac as StyleV2ControlType, bw as TextArea, ak as TextAreaControlType, bx as TextInput, al as TextInputControlType, a7 as TypographyControlType, aN as copy, aM as copyColorData, aU as copyImageData, aW as copyLinkData, a_ as copyListData, by as copyRichTextData, ba as copyShapeData, bl as copySlotData, br as copyStyleData, bL as createRichTextV2Plugin, a$ as getListElementChildren, b1 as getListFileIds, b3 as getListPageIds, b0 as getListSwatchIds, b4 as getListTranslatableData, b2 as getListTypographyIds, bb as getShapeElementChildren, bf as getShapeFileIds, be as getShapePageIds, bc as getShapeSwatchIds, bg as getShapeTranslatableData, bd as getShapeTypographyIds, aP as getTranslatableData, bN as getTypographySwatchIds, bO as getTypographyTypographyIds, a5 as isRichTextV1Data, aO as merge, b5 as mergeListTranslatedData, bh as mergeShapeTranslatedData, bn as mergeSlotControlTranslatedData, bm as mergeSlotData, aQ as mergeTranslatedData, bF as richTextDAOToDTO, bD as richTextDTOtoDAO, bC as richTextDTOtoSelection, bJ as richTextV2DataToDescendents, bK as richTextV2DescendentsToData, bE as toSelectionDTO, aS as unstable_IconRadioGroup, aR as unstable_IconRadioGroupIcon, bt as unstable_StyleV2, bM as unstable_Typography, bs as unstable_useStyleV2ClassName } from "./react-page.es.js";
|
|
3
3
|
export { a as Combobox, C as ComboboxControlType } from "./combobox.es.js";
|
|
4
4
|
import "redux";
|
|
5
5
|
import "redux-thunk";
|
package/dist/index.cjs.js
CHANGED
|
@@ -1251,7 +1251,7 @@ async function fonts(_req, res, { getFonts } = {}) {
|
|
|
1251
1251
|
const fonts2 = (_a = await (getFonts == null ? void 0 : getFonts())) != null ? _a : [];
|
|
1252
1252
|
return res.json(fonts2);
|
|
1253
1253
|
}
|
|
1254
|
-
const version = "0.12.
|
|
1254
|
+
const version = "0.12.2";
|
|
1255
1255
|
async function handler(req, res, { apiKey, siteVersions }) {
|
|
1256
1256
|
if (req.query.secret !== apiKey) {
|
|
1257
1257
|
return res.status(401).json({ message: "Unauthorized" });
|
package/dist/index.cjs2.js
CHANGED
|
@@ -34,8 +34,8 @@ var React = require("react");
|
|
|
34
34
|
var reactPage = require("./react-page.cjs.js");
|
|
35
35
|
require("use-sync-external-store/shim");
|
|
36
36
|
var next = require("./index.cjs.js");
|
|
37
|
-
require("./actions.cjs.js");
|
|
38
37
|
var tsPattern = require("ts-pattern");
|
|
38
|
+
require("./actions.cjs.js");
|
|
39
39
|
require("uuid");
|
|
40
40
|
require("slate");
|
|
41
41
|
require("escape-html");
|
package/dist/index.cjs8.js
CHANGED
|
@@ -38,8 +38,8 @@ var React = require("react");
|
|
|
38
38
|
var slate = require("slate");
|
|
39
39
|
var slateReact = require("slate-react");
|
|
40
40
|
var next = require("./index.cjs.js");
|
|
41
|
-
var reactPage = require("./react-page.cjs.js");
|
|
42
41
|
require("ts-pattern");
|
|
42
|
+
var reactPage = require("./react-page.cjs.js");
|
|
43
43
|
require("uuid");
|
|
44
44
|
require("escape-html");
|
|
45
45
|
require("slate-hyperscript");
|
package/dist/index.cjs9.js
CHANGED
|
@@ -35,8 +35,8 @@ var React = require("react");
|
|
|
35
35
|
var slate = require("slate");
|
|
36
36
|
var isHotkey = require("is-hotkey");
|
|
37
37
|
var slateReact = require("slate-react");
|
|
38
|
-
var reactPage = require("./react-page.cjs.js");
|
|
39
38
|
require("ts-pattern");
|
|
39
|
+
var reactPage = require("./react-page.cjs.js");
|
|
40
40
|
require("escape-html");
|
|
41
41
|
require("slate-hyperscript");
|
|
42
42
|
require("parse5");
|
package/dist/index.es.js
CHANGED
|
@@ -1218,7 +1218,7 @@ async function fonts(_req, res, { getFonts } = {}) {
|
|
|
1218
1218
|
const fonts2 = (_a = await (getFonts == null ? void 0 : getFonts())) != null ? _a : [];
|
|
1219
1219
|
return res.json(fonts2);
|
|
1220
1220
|
}
|
|
1221
|
-
const version = "0.12.
|
|
1221
|
+
const version = "0.12.2";
|
|
1222
1222
|
async function handler(req, res, { apiKey, siteVersions }) {
|
|
1223
1223
|
if (req.query.secret !== apiKey) {
|
|
1224
1224
|
return res.status(401).json({ message: "Unauthorized" });
|
package/dist/index.es2.js
CHANGED
|
@@ -33,8 +33,8 @@ import { useMemo, useState, useEffect, useCallback, useRef, forwardRef, createEl
|
|
|
33
33
|
import { aG as getBackgroundsFileIds, aH as getBackgroundsSwatchIds, _ as useStyle } from "./react-page.es.js";
|
|
34
34
|
import "use-sync-external-store/shim";
|
|
35
35
|
import { B as isNonNullable, F as useFiles, G as useSwatches, v as useResponsiveGridItem, c as DEFAULT_BOX_ANIMATE_TYPE, f as DEFAULT_ITEM_ANIMATE_TYPE, e as DEFAULT_BOX_ANIMATE_DURATION, d as DEFAULT_BOX_ANIMATE_DELAY, i as DEFAULT_ITEM_STAGGER_DURATION, n as useResponsiveStyle, q as colorToString } from "./index.es.js";
|
|
36
|
-
import "./actions.es.js";
|
|
37
36
|
import { match, P } from "ts-pattern";
|
|
37
|
+
import "./actions.es.js";
|
|
38
38
|
import "uuid";
|
|
39
39
|
import "slate";
|
|
40
40
|
import "escape-html";
|
package/dist/index.es5.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Node, Transforms, Text, Editor } from "slate";
|
|
2
2
|
import { ReactEditor } from "slate-react";
|
|
3
|
-
import {
|
|
3
|
+
import { c6 as ElementUtils } from "./react-page.es.js";
|
|
4
4
|
function withBuilder(editor) {
|
|
5
5
|
editor.resetValue = function(value) {
|
|
6
6
|
var _a;
|
package/dist/index.es6.js
CHANGED
|
@@ -17,7 +17,7 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
-
import {
|
|
20
|
+
import { c6 as ElementUtils, bL as createRichTextV2Plugin, aV as Link, c7 as onChange, c8 as getValue, c9 as isLinkElement, _ as useStyle, c2 as InlineType } from "./react-page.es.js";
|
|
21
21
|
import { L as Link$1 } from "./index.es3.js";
|
|
22
22
|
import { cx } from "@emotion/css";
|
|
23
23
|
import { jsx, Fragment } from "react/jsx-runtime";
|
package/dist/index.es8.js
CHANGED
|
@@ -36,8 +36,8 @@ import { useCallback, useState, useEffect, forwardRef, useImperativeHandle, useM
|
|
|
36
36
|
import { Range, createEditor } from "slate";
|
|
37
37
|
import { ReactEditor, withReact, Slate, Editable } from "slate-react";
|
|
38
38
|
import { n as useResponsiveStyle, L as useEnhancedTypography, N as useTypographyClassName, u as useIsInBuilder, O as useBuilderEditMode, Q as pollBoxModel } from "./index.es.js";
|
|
39
|
-
import { _ as useStyle, b_ as BlockType, b$ as InlineType, bA as richTextDTOtoDAO, bz as richTextDTOtoSelection, f as deepEqual, bT as withBlock, bO as withTypography, bS as onKeyDown, cc as BuilderEditMode } from "./react-page.es.js";
|
|
40
39
|
import "ts-pattern";
|
|
40
|
+
import { _ as useStyle, c1 as BlockType, c2 as InlineType, bD as richTextDTOtoDAO, bC as richTextDTOtoSelection, f as deepEqual, bW as withBlock, bR as withTypography, bV as onKeyDown, cf as BuilderEditMode } from "./react-page.es.js";
|
|
41
41
|
import "uuid";
|
|
42
42
|
import "escape-html";
|
|
43
43
|
import "slate-hyperscript";
|
package/dist/index.es9.js
CHANGED
|
@@ -33,8 +33,8 @@ import { useEffect, useMemo, useState, useRef, useCallback } from "react";
|
|
|
33
33
|
import { Range, createEditor } from "slate";
|
|
34
34
|
import isHotkey from "is-hotkey";
|
|
35
35
|
import { ReactEditor, withReact, Slate, Editable } from "slate-react";
|
|
36
|
-
import { bG as richTextV2DataToDescendents, b_ as BlockType, bD as RichTextV2Mode, bW as InlineModePlugin, bU as BlockPlugin, bP as TypographyPlugin, bY as TextAlignPlugin, c2 as InlinePlugin, cc as BuilderEditMode } from "./react-page.es.js";
|
|
37
36
|
import "ts-pattern";
|
|
37
|
+
import { bJ as richTextV2DataToDescendents, c1 as BlockType, bG as RichTextV2Mode, bZ as InlineModePlugin, bX as BlockPlugin, bS as TypographyPlugin, b$ as TextAlignPlugin, c5 as InlinePlugin, cf as BuilderEditMode } from "./react-page.es.js";
|
|
38
38
|
import "escape-html";
|
|
39
39
|
import "slate-hyperscript";
|
|
40
40
|
import "parse5";
|
package/dist/react-page.cjs.js
CHANGED
|
@@ -284,16 +284,26 @@ function reducer$1(state = getInitialState(), action) {
|
|
|
284
284
|
return state;
|
|
285
285
|
}
|
|
286
286
|
}
|
|
287
|
+
const ControlDataTypeKey = "@@makeswift/type";
|
|
288
|
+
const ColorControlDataTypeKey = ControlDataTypeKey;
|
|
289
|
+
const ColorControlDataTypeValueV1 = "color::v1";
|
|
287
290
|
const ColorControlType = "makeswift::controls::color";
|
|
288
291
|
function Color(config = {}) {
|
|
289
|
-
return { type: ColorControlType, config };
|
|
292
|
+
return { type: ColorControlType, config, version: 1 };
|
|
290
293
|
}
|
|
291
294
|
function copyColorData(value, context) {
|
|
292
|
-
var _a;
|
|
293
295
|
if (value == null)
|
|
294
296
|
return value;
|
|
295
|
-
return
|
|
296
|
-
|
|
297
|
+
return tsPattern.match(value).with({ [ControlDataTypeKey]: ColorControlDataTypeValueV1 }, (val) => {
|
|
298
|
+
var _a;
|
|
299
|
+
return __spreadProps(__spreadValues({}, val), {
|
|
300
|
+
swatchId: (_a = context.replacementContext.swatchIds.get(val.swatchId)) != null ? _a : val.swatchId
|
|
301
|
+
});
|
|
302
|
+
}).otherwise((val) => {
|
|
303
|
+
var _a;
|
|
304
|
+
return __spreadProps(__spreadValues({}, val), {
|
|
305
|
+
swatchId: (_a = context.replacementContext.swatchIds.get(val.swatchId)) != null ? _a : val.swatchId
|
|
306
|
+
});
|
|
297
307
|
});
|
|
298
308
|
}
|
|
299
309
|
class PropController {
|
|
@@ -5130,8 +5140,11 @@ exports.BorderRadiusPropControllerFormat = BorderRadiusPropControllerFormat;
|
|
|
5130
5140
|
exports.BuilderEditMode = BuilderEditMode;
|
|
5131
5141
|
exports.Checkbox = Checkbox;
|
|
5132
5142
|
exports.Color = Color;
|
|
5143
|
+
exports.ColorControlDataTypeKey = ColorControlDataTypeKey;
|
|
5144
|
+
exports.ColorControlDataTypeValueV1 = ColorControlDataTypeValueV1;
|
|
5133
5145
|
exports.ColorControlType = ColorControlType;
|
|
5134
5146
|
exports.ComponentIcon = ComponentIcon;
|
|
5147
|
+
exports.ControlDataTypeKey = ControlDataTypeKey;
|
|
5135
5148
|
exports.Date = Date;
|
|
5136
5149
|
exports.ElementID = ElementID;
|
|
5137
5150
|
exports.ElementUtils = ElementUtils;
|