@makeswift/runtime 0.0.0-a500663 → 0.0.0-afbfa6b
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/api.js +1 -0
- package/builder.js +1 -0
- package/dist/actions.cjs.js +175 -0
- package/dist/actions.cjs.js.map +1 -0
- package/dist/actions.es.js +154 -0
- package/dist/actions.es.js.map +1 -0
- package/dist/api.cjs.js +5 -0
- package/dist/api.cjs.js.map +1 -0
- package/dist/api.es.js +2 -0
- package/dist/api.es.js.map +1 -0
- package/dist/box-model.cjs.js +9 -0
- package/dist/box-model.cjs.js.map +1 -0
- package/dist/box-model.es.js +4 -0
- package/dist/box-model.es.js.map +1 -0
- package/dist/box-models.cjs.js +106 -0
- package/dist/box-models.cjs.js.map +1 -0
- package/dist/box-models.es.js +97 -0
- package/dist/box-models.es.js.map +1 -0
- package/dist/builder.cjs.js +9 -0
- package/dist/builder.cjs.js.map +1 -0
- package/dist/builder.es.js +3 -0
- package/dist/builder.es.js.map +1 -0
- package/dist/components.cjs.js +59 -0
- package/dist/components.cjs.js.map +1 -0
- package/dist/components.es.js +28 -0
- package/dist/components.es.js.map +1 -0
- package/dist/constants.cjs.js +146 -0
- package/dist/constants.cjs.js.map +1 -0
- package/dist/constants.es.js +145 -0
- package/dist/constants.es.js.map +1 -0
- package/dist/control-serialization.cjs.js +91 -0
- package/dist/control-serialization.cjs.js.map +1 -0
- package/dist/control-serialization.es.js +87 -0
- package/dist/control-serialization.es.js.map +1 -0
- package/dist/descriptors.cjs.js +215 -0
- package/dist/descriptors.cjs.js.map +1 -0
- package/dist/descriptors.es.js +183 -0
- package/dist/descriptors.es.js.map +1 -0
- package/dist/instances.cjs.js +89 -0
- package/dist/instances.cjs.js.map +1 -0
- package/dist/instances.es.js +87 -0
- package/dist/instances.es.js.map +1 -0
- package/dist/main.cjs.js +11 -0
- package/dist/main.cjs.js.map +1 -0
- package/dist/main.es.js +2 -0
- package/dist/main.es.js.map +1 -0
- package/dist/next.cjs.js +169 -0
- package/dist/next.cjs.js.map +1 -0
- package/dist/next.es.js +159 -0
- package/dist/next.es.js.map +1 -0
- package/dist/prop-controllers.cjs.js +7 -0
- package/dist/prop-controllers.cjs.js.map +1 -0
- package/dist/prop-controllers.es.js +3 -0
- package/dist/prop-controllers.es.js.map +1 -0
- package/dist/react-builder-preview.cjs.js +459 -0
- package/dist/react-builder-preview.cjs.js.map +1 -0
- package/dist/react-builder-preview.es.js +448 -0
- package/dist/react-builder-preview.es.js.map +1 -0
- package/dist/react.cjs.js +39 -0
- package/dist/react.cjs.js.map +1 -0
- package/dist/react.cjs2.js +6080 -0
- package/dist/react.cjs2.js.map +1 -0
- package/dist/react.es.js +28 -0
- package/dist/react.es.js.map +1 -0
- package/dist/react.es2.js +5999 -0
- package/dist/react.es2.js.map +1 -0
- package/dist/types/api/constants.d.ts +4 -0
- package/dist/types/api/constants.d.ts.map +1 -0
- package/dist/types/api/generated/graphql.d.ts +61 -0
- package/dist/types/api/generated/graphql.d.ts.map +1 -0
- package/dist/types/api/index.d.ts +3 -0
- package/dist/types/api/index.d.ts.map +1 -0
- package/dist/types/api/react.d.ts +6 -0
- package/dist/types/api/react.d.ts.map +1 -0
- package/dist/types/api/types.d.ts +4 -0
- package/dist/types/api/types.d.ts.map +1 -0
- package/{src/box-model.ts → dist/types/box-model.d.ts} +3 -2
- package/dist/types/box-model.d.ts.map +1 -0
- package/dist/types/builder/index.d.ts +2 -0
- package/dist/types/builder/index.d.ts.map +1 -0
- package/dist/types/builder/serialization/control-serialization.d.ts +30 -0
- package/dist/types/builder/serialization/control-serialization.d.ts.map +1 -0
- package/dist/types/builder/serialization/function-serialization.d.ts +11 -0
- package/dist/types/builder/serialization/function-serialization.d.ts.map +1 -0
- package/dist/types/builder/serialization/index.d.ts +3 -0
- package/dist/types/builder/serialization/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Box/Box.d.ts +33 -0
- package/dist/types/components/builtin/Box/Box.d.ts.map +1 -0
- package/dist/types/components/builtin/Box/animations.d.ts +69 -0
- package/dist/types/components/builtin/Box/animations.d.ts.map +1 -0
- package/dist/types/components/builtin/Box/components/Placeholder/index.d.ts +7 -0
- package/dist/types/components/builtin/Box/components/Placeholder/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Box/index.d.ts +3 -0
- package/dist/types/components/builtin/Box/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Button/Button.d.ts +118 -0
- package/dist/types/components/builtin/Button/Button.d.ts.map +1 -0
- package/dist/types/components/builtin/Button/index.d.ts +2 -0
- package/dist/types/components/builtin/Button/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Carousel/Carousel.d.ts +28 -0
- package/dist/types/components/builtin/Carousel/Carousel.d.ts.map +1 -0
- package/dist/types/components/builtin/Carousel/index.d.ts +2 -0
- package/dist/types/components/builtin/Carousel/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Countdown/Countdown.d.ts +27 -0
- package/dist/types/components/builtin/Countdown/Countdown.d.ts.map +1 -0
- package/dist/types/components/builtin/Countdown/index.d.ts +2 -0
- package/dist/types/components/builtin/Countdown/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Divider/Divider.d.ts +17 -0
- package/dist/types/components/builtin/Divider/Divider.d.ts.map +1 -0
- package/dist/types/components/builtin/Divider/index.d.ts +2 -0
- package/dist/types/components/builtin/Divider/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Embed/Embed.d.ts +14 -0
- package/dist/types/components/builtin/Embed/Embed.d.ts.map +1 -0
- package/dist/types/components/builtin/Embed/index.d.ts +2 -0
- package/dist/types/components/builtin/Embed/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Image/Image.d.ts +29 -0
- package/dist/types/components/builtin/Image/Image.d.ts.map +1 -0
- package/dist/types/components/builtin/Image/index.d.ts +2 -0
- package/dist/types/components/builtin/Image/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Navigation/Navigation.d.ts +26 -0
- package/dist/types/components/builtin/Navigation/Navigation.d.ts.map +1 -0
- package/dist/types/components/builtin/Navigation/components/DropDownButton/index.d.ts +100 -0
- package/dist/types/components/builtin/Navigation/components/DropDownButton/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Navigation/components/LinksPlaceholder/index.d.ts +8 -0
- package/dist/types/components/builtin/Navigation/components/LinksPlaceholder/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Navigation/components/MobileMenu/components/MobileDropDownButton/index.d.ts +101 -0
- package/dist/types/components/builtin/Navigation/components/MobileMenu/components/MobileDropDownButton/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Navigation/components/MobileMenu/index.d.ts +13 -0
- package/dist/types/components/builtin/Navigation/components/MobileMenu/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Navigation/index.d.ts +2 -0
- package/dist/types/components/builtin/Navigation/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Root/Root.d.ts +14 -0
- package/dist/types/components/builtin/Root/Root.d.ts.map +1 -0
- package/dist/types/components/builtin/Root/components/Placeholder/index.d.ts +5 -0
- package/dist/types/components/builtin/Root/components/Placeholder/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Root/index.d.ts +2 -0
- package/dist/types/components/builtin/Root/index.d.ts.map +1 -0
- package/dist/types/components/builtin/SocialLinks/SocialLinks.d.ts +21 -0
- package/dist/types/components/builtin/SocialLinks/SocialLinks.d.ts.map +1 -0
- package/dist/types/components/builtin/SocialLinks/components/SocialLinksPlaceholder/index.d.ts +8 -0
- package/dist/types/components/builtin/SocialLinks/components/SocialLinksPlaceholder/index.d.ts.map +1 -0
- package/dist/types/components/builtin/SocialLinks/index.d.ts +2 -0
- package/dist/types/components/builtin/SocialLinks/index.d.ts.map +1 -0
- package/dist/types/components/builtin/SocialLinks/options.d.ts +113 -0
- package/dist/types/components/builtin/SocialLinks/options.d.ts.map +1 -0
- package/dist/types/components/builtin/Text/Text.d.ts +19 -0
- package/dist/types/components/builtin/Text/Text.d.ts.map +1 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/components/Block/index.d.ts +24 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/components/Block/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/components/Mark/hooks/useTypographyMark.d.ts +25 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/components/Mark/hooks/useTypographyMark.d.ts.map +1 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/components/Mark/index.d.ts +13 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/components/Mark/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/index.d.ts +5 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/index.d.ts.map +1 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/plugins/DeviceOverridesBlocks.d.ts +3 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/plugins/DeviceOverridesBlocks.d.ts.map +1 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/plugins/DeviceOverridesMarks.d.ts +3 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/plugins/DeviceOverridesMarks.d.ts.map +1 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/plugins/Inlines.d.ts +3 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/plugins/Inlines.d.ts.map +1 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/plugins/Link.d.ts +3 -0
- package/dist/types/components/builtin/Text/components/RichTextEditor/plugins/Link.d.ts.map +1 -0
- package/dist/types/components/builtin/Text/index.d.ts +2 -0
- package/dist/types/components/builtin/Text/index.d.ts.map +1 -0
- package/dist/types/components/builtin/index.d.ts +15 -0
- package/dist/types/components/builtin/index.d.ts.map +1 -0
- package/dist/types/components/hooks/index.d.ts +8 -0
- package/dist/types/components/hooks/index.d.ts.map +1 -0
- package/dist/types/components/hooks/useBackgrounds.d.ts +59 -0
- package/dist/types/components/hooks/useBackgrounds.d.ts.map +1 -0
- package/dist/types/components/hooks/useBorder.d.ts +19 -0
- package/dist/types/components/hooks/useBorder.d.ts.map +1 -0
- package/dist/types/components/hooks/useBoxShadow.d.ts +19 -0
- package/dist/types/components/hooks/useBoxShadow.d.ts.map +1 -0
- package/dist/types/components/hooks/useColor.d.ts +7 -0
- package/dist/types/components/hooks/useColor.d.ts.map +1 -0
- package/dist/types/components/hooks/useFile.d.ts +13 -0
- package/dist/types/components/hooks/useFile.d.ts.map +1 -0
- package/dist/types/components/hooks/useMediaQuery.d.ts +3 -0
- package/dist/types/components/hooks/useMediaQuery.d.ts.map +1 -0
- package/dist/types/components/hooks/usePage.d.ts +7 -0
- package/dist/types/components/hooks/usePage.d.ts.map +1 -0
- package/dist/types/components/hooks/useTypography.d.ts +24 -0
- package/dist/types/components/hooks/useTypography.d.ts.map +1 -0
- package/dist/types/components/index.d.ts +3 -0
- package/dist/types/components/index.d.ts.map +1 -0
- package/dist/types/components/shared/BackgroundsContainer/components/BackgroundVideo/index.d.ts +11 -0
- package/dist/types/components/shared/BackgroundsContainer/components/BackgroundVideo/index.d.ts.map +1 -0
- package/dist/types/components/shared/BackgroundsContainer/components/Backgrounds/index.d.ts +8 -0
- package/dist/types/components/shared/BackgroundsContainer/components/Backgrounds/index.d.ts.map +1 -0
- package/dist/types/components/shared/BackgroundsContainer/components/Parallax/index.d.ts +11 -0
- package/dist/types/components/shared/BackgroundsContainer/components/Parallax/index.d.ts.map +1 -0
- package/dist/types/components/shared/BackgroundsContainer/index.d.ts +11 -0
- package/dist/types/components/shared/BackgroundsContainer/index.d.ts.map +1 -0
- package/dist/types/components/shared/GutterContainer/index.d.ts +8 -0
- package/dist/types/components/shared/GutterContainer/index.d.ts.map +1 -0
- package/dist/types/components/shared/Link/index.d.ts +9 -0
- package/dist/types/components/shared/Link/index.d.ts.map +1 -0
- package/dist/types/components/utils/colorToString.d.ts +3 -0
- package/dist/types/components/utils/colorToString.d.ts.map +1 -0
- package/dist/types/components/utils/columns.d.ts +2 -0
- package/dist/types/components/utils/columns.d.ts.map +1 -0
- package/dist/types/components/utils/cssMediaRules.d.ts +69 -0
- package/dist/types/components/utils/cssMediaRules.d.ts.map +1 -0
- package/dist/types/components/utils/devices.d.ts +17 -0
- package/dist/types/components/utils/devices.d.ts.map +1 -0
- package/dist/types/components/utils/isNonNullable.d.ts +2 -0
- package/dist/types/components/utils/isNonNullable.d.ts.map +1 -0
- package/dist/types/components/utils/placeholders.d.ts +10 -0
- package/dist/types/components/utils/placeholders.d.ts.map +1 -0
- package/dist/types/components/utils/queries.d.ts +7 -0
- package/dist/types/components/utils/queries.d.ts.map +1 -0
- package/dist/types/components/utils/types.d.ts +11 -0
- package/dist/types/components/utils/types.d.ts.map +1 -0
- package/dist/types/index.d.ts +7 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/next.d.ts +21 -0
- package/dist/types/next.d.ts.map +1 -0
- package/dist/types/prop-controllers/descriptors.d.ts +693 -0
- package/dist/types/prop-controllers/descriptors.d.ts.map +1 -0
- package/dist/types/prop-controllers/index.d.ts +5 -0
- package/dist/types/prop-controllers/index.d.ts.map +1 -0
- package/dist/types/prop-controllers/instances.d.ts +69 -0
- package/dist/types/prop-controllers/instances.d.ts.map +1 -0
- package/dist/types/prop-controllers/introspection.d.ts +5 -0
- package/dist/types/prop-controllers/introspection.d.ts.map +1 -0
- package/dist/types/react.d.ts +4 -0
- package/dist/types/react.d.ts.map +1 -0
- package/dist/types/runtimes/react.d.ts +43 -0
- package/dist/types/runtimes/react.d.ts.map +1 -0
- package/dist/types/state/actions.d.ts +237 -0
- package/dist/types/state/actions.d.ts.map +1 -0
- package/dist/types/state/modules/box-models.d.ts +22 -0
- package/dist/types/state/modules/box-models.d.ts.map +1 -0
- package/dist/types/state/modules/components-meta.d.ts +14 -0
- package/dist/types/state/modules/components-meta.d.ts.map +1 -0
- package/dist/types/state/modules/prop-controller-handles.d.ts +16 -0
- package/dist/types/state/modules/prop-controller-handles.d.ts.map +1 -0
- package/dist/types/state/modules/prop-controllers.d.ts +11 -0
- package/dist/types/state/modules/prop-controllers.d.ts.map +1 -0
- package/dist/types/state/modules/react-components.d.ts +10 -0
- package/dist/types/state/modules/react-components.d.ts.map +1 -0
- package/dist/types/state/modules/read-only-documents.d.ts +28 -0
- package/dist/types/state/modules/read-only-documents.d.ts.map +1 -0
- package/dist/types/state/modules/read-write-documents.d.ts +13 -0
- package/dist/types/state/modules/read-write-documents.d.ts.map +1 -0
- package/dist/types/state/react-builder-preview.d.ts +44 -0
- package/dist/types/state/react-builder-preview.d.ts.map +1 -0
- package/dist/types/state/react-page.d.ts +33 -0
- package/dist/types/state/react-page.d.ts.map +1 -0
- package/dist/types/utils/clamp.d.ts +3 -0
- package/dist/types/utils/clamp.d.ts.map +1 -0
- package/dist/types/utils/coalesce.d.ts +3 -0
- package/dist/types/utils/coalesce.d.ts.map +1 -0
- package/dist/types/utils/constants.d.ts +6 -0
- package/dist/types/utils/constants.d.ts.map +1 -0
- package/dist/types/utils/deepEqual.d.ts +3 -0
- package/dist/types/utils/deepEqual.d.ts.map +1 -0
- package/dist/types/utils/intersection.d.ts +4 -0
- package/dist/types/utils/intersection.d.ts.map +1 -0
- package/dist/types/utils/is.d.ts +2 -0
- package/dist/types/utils/is.d.ts.map +1 -0
- package/dist/types/utils/keys.d.ts +5 -0
- package/dist/types/utils/keys.d.ts.map +1 -0
- package/dist/types/utils/shallowEqual.d.ts +3 -0
- package/dist/types/utils/shallowEqual.d.ts.map +1 -0
- package/dist/types/utils/shallowMerge.d.ts +2 -0
- package/dist/types/utils/shallowMerge.d.ts.map +1 -0
- package/next.js +1 -0
- package/package.json +80 -37
- package/favicon.svg +0 -15
- package/index.html +0 -13
- package/src/components/Root/Root.tsx +0 -72
- package/src/components/Root/components/Placeholder/index.tsx +0 -37
- package/src/components/Root/index.tsx +0 -1
- package/src/components/index.ts +0 -1
- package/src/components/utils/columns.ts +0 -15
- package/src/components/utils/cssMediaRules.ts +0 -91
- package/src/components/utils/devices.ts +0 -86
- package/src/index.ts +0 -8
- package/src/prop-controllers/descriptors.ts +0 -821
- package/src/prop-controllers/index.ts +0 -10
- package/src/react.ts +0 -3
- package/src/runtimes/react.tsx +0 -223
- package/src/state/actions.ts +0 -239
- package/src/state/modules/box-models.ts +0 -112
- package/src/state/modules/components-meta.ts +0 -44
- package/src/state/modules/prop-controllers.ts +0 -45
- package/src/state/modules/react-components.tsx +0 -47
- package/src/state/modules/read-only-documents.ts +0 -51
- package/src/state/modules/read-write-documents.ts +0 -75
- package/src/state/react-builder-preview.ts +0 -271
- package/src/state/react-page.ts +0 -73
- package/src/style.css +0 -8
- package/src/utils/deepEqual.ts +0 -33
- package/src/utils/is.ts +0 -5
- package/src/utils/shallowEqual.ts +0 -30
- package/src/vite-env.d.ts +0 -1
- package/tsconfig.json +0 -23
- package/types/ot-json0.d.ts +0 -35
- package/vite.config.ts +0 -28
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
+
var __spreadValues = (a, b) => {
|
|
9
|
+
for (var prop in b || (b = {}))
|
|
10
|
+
if (__hasOwnProp.call(b, prop))
|
|
11
|
+
__defNormalProp(a, prop, b[prop]);
|
|
12
|
+
if (__getOwnPropSymbols)
|
|
13
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
+
if (__propIsEnum.call(b, prop))
|
|
15
|
+
__defNormalProp(a, prop, b[prop]);
|
|
16
|
+
}
|
|
17
|
+
return a;
|
|
18
|
+
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
+
import { withScroll, createBox as createBox$1, getBox as getBox$1 } from "css-box-model";
|
|
21
|
+
import { A as ActionTypes } from "./actions.es.js";
|
|
22
|
+
function parse(rawString) {
|
|
23
|
+
const value = Number(rawString.replace(/px$/, ""));
|
|
24
|
+
return Number.isFinite(value) ? value : 0;
|
|
25
|
+
}
|
|
26
|
+
function createBox(boxArgs) {
|
|
27
|
+
return withScroll(createBox$1(boxArgs));
|
|
28
|
+
}
|
|
29
|
+
function getBox(element) {
|
|
30
|
+
return withScroll(getBox$1(element));
|
|
31
|
+
}
|
|
32
|
+
function isMeasurable(value) {
|
|
33
|
+
if (value instanceof Element)
|
|
34
|
+
return true;
|
|
35
|
+
if (typeof value === "object" && value !== null && "getBoxModel" in value && typeof value.getBoxModel === "function") {
|
|
36
|
+
return true;
|
|
37
|
+
}
|
|
38
|
+
return false;
|
|
39
|
+
}
|
|
40
|
+
function measure(measurable) {
|
|
41
|
+
if (measurable instanceof Element)
|
|
42
|
+
return getBox(measurable);
|
|
43
|
+
return measurable.getBoxModel();
|
|
44
|
+
}
|
|
45
|
+
function getInitialState() {
|
|
46
|
+
return { measurables: /* @__PURE__ */ new Map(), boxModels: /* @__PURE__ */ new Map() };
|
|
47
|
+
}
|
|
48
|
+
function getMeasurables(state) {
|
|
49
|
+
return state.measurables;
|
|
50
|
+
}
|
|
51
|
+
function getBoxModels(state) {
|
|
52
|
+
return state.boxModels;
|
|
53
|
+
}
|
|
54
|
+
function getBoxModel(state, documentKey, elementKey) {
|
|
55
|
+
var _a, _b;
|
|
56
|
+
return (_b = (_a = getBoxModels(state).get(documentKey)) == null ? void 0 : _a.get(elementKey)) != null ? _b : null;
|
|
57
|
+
}
|
|
58
|
+
function reducer(state = getInitialState(), action) {
|
|
59
|
+
var _a, _b;
|
|
60
|
+
switch (action.type) {
|
|
61
|
+
case ActionTypes.REGISTER_MEASURABLE: {
|
|
62
|
+
const { documentKey, elementKey, measurable } = action.payload;
|
|
63
|
+
return __spreadProps(__spreadValues({}, state), {
|
|
64
|
+
measurables: new Map(state.measurables).set(documentKey, new Map((_a = state.measurables.get(documentKey)) != null ? _a : []).set(elementKey, measurable))
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
case ActionTypes.UNREGISTER_MEASURABLE: {
|
|
68
|
+
const { documentKey, elementKey } = action.payload;
|
|
69
|
+
const nextMeasurables = new Map((_b = state.measurables.get(documentKey)) != null ? _b : []);
|
|
70
|
+
const deleted = nextMeasurables.delete(elementKey);
|
|
71
|
+
return deleted ? __spreadProps(__spreadValues({}, state), { measurables: new Map(state.measurables).set(documentKey, nextMeasurables) }) : state;
|
|
72
|
+
}
|
|
73
|
+
case ActionTypes.CHANGE_ELEMENT_BOX_MODELS: {
|
|
74
|
+
const { changedElementBoxModels } = action.payload;
|
|
75
|
+
if (changedElementBoxModels.size === 0)
|
|
76
|
+
return state;
|
|
77
|
+
const nextBoxModels = new Map(state.boxModels);
|
|
78
|
+
changedElementBoxModels.forEach((changedBoxModels, documentKey) => {
|
|
79
|
+
var _a2;
|
|
80
|
+
const nextDocumentBoxModels = new Map((_a2 = nextBoxModels.get(documentKey)) != null ? _a2 : []);
|
|
81
|
+
changedBoxModels.forEach((changedBoxModel, elementKey) => {
|
|
82
|
+
if (changedBoxModel == null)
|
|
83
|
+
nextDocumentBoxModels.delete(elementKey);
|
|
84
|
+
else
|
|
85
|
+
nextDocumentBoxModels.set(elementKey, changedBoxModel);
|
|
86
|
+
});
|
|
87
|
+
if (nextDocumentBoxModels.size > 0)
|
|
88
|
+
nextBoxModels.set(documentKey, nextDocumentBoxModels);
|
|
89
|
+
});
|
|
90
|
+
return __spreadProps(__spreadValues({}, state), { boxModels: nextBoxModels });
|
|
91
|
+
}
|
|
92
|
+
default:
|
|
93
|
+
return state;
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
export { getMeasurables as a, getBoxModels as b, createBox as c, getBoxModel as d, getBox as g, isMeasurable as i, measure as m, parse as p, reducer as r };
|
|
97
|
+
//# sourceMappingURL=box-models.es.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"box-models.es.js","sources":["../src/state/modules/box-models.ts"],"sourcesContent":["import {\n BoxModel,\n createBox as createBoxWithoutScroll,\n CreateBoxArgs,\n getBox as getBoxWithoutScroll,\n withScroll,\n} from 'css-box-model'\n\nimport { Action, ActionTypes } from '../actions'\n\nexport type { BoxModel }\n\nexport function parse(rawString: string): number {\n const value = Number(rawString.replace(/px$/, ''))\n\n return Number.isFinite(value) ? value : 0\n}\n\nexport function createBox(boxArgs: CreateBoxArgs): BoxModel {\n return withScroll(createBoxWithoutScroll(boxArgs))\n}\n\nexport function getBox(element: Element): BoxModel {\n return withScroll(getBoxWithoutScroll(element))\n}\n\nexport interface BoxModelHandle {\n getBoxModel(): BoxModel | null\n}\n\nexport type Measurable = Element | BoxModelHandle\n\nexport function isMeasurable(value: unknown): value is Measurable {\n if (value instanceof Element) return true\n\n if (\n typeof value === 'object' &&\n value !== null &&\n 'getBoxModel' in value &&\n typeof (value as { getBoxModel: unknown }).getBoxModel === 'function'\n ) {\n return true\n }\n\n return false\n}\n\nexport function measure(measurable: Measurable): BoxModel | null {\n if (measurable instanceof Element) return getBox(measurable)\n\n return measurable.getBoxModel()\n}\n\nexport type State = {\n measurables: Map<string, Map<string, Measurable>>\n boxModels: Map<string, Map<string, BoxModel>>\n}\n\nexport function getInitialState(): State {\n return { measurables: new Map(), boxModels: new Map() }\n}\n\nexport function getMeasurables(state: State): Map<string, Map<string, Measurable>> {\n return state.measurables\n}\n\nexport function getBoxModels(state: State): Map<string, Map<string, BoxModel>> {\n return state.boxModels\n}\n\nexport function getBoxModel(\n state: State,\n documentKey: string,\n elementKey: string,\n): BoxModel | null {\n return getBoxModels(state).get(documentKey)?.get(elementKey) ?? null\n}\n\nexport function reducer(state: State = getInitialState(), action: Action) {\n switch (action.type) {\n case ActionTypes.REGISTER_MEASURABLE: {\n const { documentKey, elementKey, measurable } = action.payload\n\n return {\n ...state,\n measurables: new Map(state.measurables).set(\n documentKey,\n new Map(state.measurables.get(documentKey) ?? []).set(elementKey, measurable),\n ),\n }\n }\n\n case ActionTypes.UNREGISTER_MEASURABLE: {\n const { documentKey, elementKey } = action.payload\n const nextMeasurables = new Map(state.measurables.get(documentKey) ?? [])\n\n const deleted = nextMeasurables.delete(elementKey)\n\n return deleted\n ? { ...state, measurables: new Map(state.measurables).set(documentKey, nextMeasurables) }\n : state\n }\n\n case ActionTypes.CHANGE_ELEMENT_BOX_MODELS: {\n const { changedElementBoxModels } = action.payload\n\n if (changedElementBoxModels.size === 0) return state\n\n const nextBoxModels = new Map(state.boxModels)\n\n changedElementBoxModels.forEach((changedBoxModels, documentKey) => {\n const nextDocumentBoxModels = new Map(nextBoxModels.get(documentKey) ?? [])\n\n changedBoxModels.forEach((changedBoxModel, elementKey) => {\n if (changedBoxModel == null) nextDocumentBoxModels.delete(elementKey)\n else nextDocumentBoxModels.set(elementKey, changedBoxModel)\n })\n\n if (nextDocumentBoxModels.size > 0) nextBoxModels.set(documentKey, nextDocumentBoxModels)\n })\n\n return { ...state, boxModels: nextBoxModels }\n }\n\n default:\n return state\n }\n}\n"],"names":["createBoxWithoutScroll","getBoxWithoutScroll"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAYO,eAAe,WAA2B;AAC/C,QAAM,QAAQ,OAAO,UAAU,QAAQ,OAAO,EAAE,CAAC;AAEjD,SAAO,OAAO,SAAS,KAAK,IAAI,QAAQ;AAC1C;AAEO,mBAAmB,SAAkC;AACnD,SAAA,WAAWA,YAAuB,OAAO,CAAC;AACnD;AAEO,gBAAgB,SAA4B;AAC1C,SAAA,WAAWC,SAAoB,OAAO,CAAC;AAChD;AAQO,sBAAsB,OAAqC;AAChE,MAAI,iBAAiB;AAAgB,WAAA;AAGnC,MAAA,OAAO,UAAU,YACjB,UAAU,QACV,iBAAiB,SACjB,OAAQ,MAAmC,gBAAgB,YAC3D;AACO,WAAA;AAAA,EACT;AAEO,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I,qBAAc,IAAI,WAAW,MAA7B,aAAkC,CAAA,CAAE;AAEzD,yBAAA,QAAQ,CAAC,iBAAiB,eAAe;AACxD,cAAI,mBAAmB;AAAM,kCAAsB,OAAO,UAAU;AAAA;AACzC,kCAAA,IAAI,YAAY,eAAe;AAAA,QAAA,CAC3D;AAED,YAAI,sBAAsB,OAAO;AAAiB,wBAAA,IAAI,aAAa,qBAAqB;AAAA,MAAA,CACzF;AAEM,aAAA,iCAAK,QAAL,EAAY,WAAW,cAAc;AAAA,IAC9C;AAAA;AAGS,aAAA;AAAA;AAEb;;"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
+
var controlSerialization = require("./control-serialization.cjs.js");
|
|
4
|
+
require("./descriptors.cjs.js");
|
|
5
|
+
exports.deserializeControls = controlSerialization.deserializeControls;
|
|
6
|
+
exports.deserializeFunction = controlSerialization.deserializeFunction;
|
|
7
|
+
exports.serializeControls = controlSerialization.serializeControls;
|
|
8
|
+
exports.serializeFunction = controlSerialization.serializeFunction;
|
|
9
|
+
//# sourceMappingURL=builder.cjs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"builder.cjs.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"builder.es.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;"}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
+
var react = require("./react.cjs2.js");
|
|
4
|
+
require("react");
|
|
5
|
+
require("use-sync-external-store/shim/with-selector");
|
|
6
|
+
require("@apollo/client");
|
|
7
|
+
require("redux");
|
|
8
|
+
require("redux-thunk");
|
|
9
|
+
require("./actions.cjs.js");
|
|
10
|
+
require("./descriptors.cjs.js");
|
|
11
|
+
require("styled-components");
|
|
12
|
+
require("framer-motion");
|
|
13
|
+
require("react/jsx-runtime");
|
|
14
|
+
require("./box-models.cjs.js");
|
|
15
|
+
require("css-box-model");
|
|
16
|
+
require("next/image");
|
|
17
|
+
require("react-player");
|
|
18
|
+
require("color");
|
|
19
|
+
require("scroll-into-view-if-needed");
|
|
20
|
+
require("next/link");
|
|
21
|
+
require("react-use-gesture");
|
|
22
|
+
require("@popmotion/popcorn");
|
|
23
|
+
require("uuid/v4");
|
|
24
|
+
require("polished");
|
|
25
|
+
require("slate");
|
|
26
|
+
require("slate-hotkeys");
|
|
27
|
+
require("corporate-ipsum");
|
|
28
|
+
require("slate-react");
|
|
29
|
+
require("@convertkit/slate-lists");
|
|
30
|
+
exports.Box = react.Box;
|
|
31
|
+
exports.Button = react.Button;
|
|
32
|
+
exports.Carousel = react.Carousel;
|
|
33
|
+
exports.Countdown = react.Countdown;
|
|
34
|
+
exports.DEFAULT_BOX_ANIMATE_DELAY = react.DEFAULT_BOX_ANIMATE_DELAY;
|
|
35
|
+
exports.DEFAULT_BOX_ANIMATE_DURATION = react.DEFAULT_BOX_ANIMATE_DURATION;
|
|
36
|
+
exports.DEFAULT_BOX_ANIMATE_TYPE = react.DEFAULT_BOX_ANIMATE_TYPE;
|
|
37
|
+
exports.DEFAULT_ITEM_ANIMATE_DELAY = react.DEFAULT_ITEM_ANIMATE_DELAY;
|
|
38
|
+
exports.DEFAULT_ITEM_ANIMATE_DURATION = react.DEFAULT_ITEM_ANIMATE_DURATION;
|
|
39
|
+
exports.DEFAULT_ITEM_ANIMATE_TYPE = react.DEFAULT_ITEM_ANIMATE_TYPE;
|
|
40
|
+
exports.DEFAULT_ITEM_STAGGER_DURATION = react.DEFAULT_ITEM_STAGGER_DURATION;
|
|
41
|
+
exports.Divider = react.Divider;
|
|
42
|
+
exports.Embed = react.Embed;
|
|
43
|
+
exports.Image = react.ImageComponent;
|
|
44
|
+
exports.Navigation = react.Navigation;
|
|
45
|
+
exports.Root = react.Root;
|
|
46
|
+
exports.SocialLinks = react.SocialLinks;
|
|
47
|
+
exports.Text = react.Text;
|
|
48
|
+
exports.cssBorder = react.cssBorder;
|
|
49
|
+
exports.cssBorderRadius = react.cssBorderRadius;
|
|
50
|
+
exports.cssBoxShadow = react.cssBoxShadow;
|
|
51
|
+
exports.cssGridItem = react.cssGridItem;
|
|
52
|
+
exports.cssMargin = react.cssMargin;
|
|
53
|
+
exports.cssMediaRules = react.cssMediaRules;
|
|
54
|
+
exports.cssPadding = react.cssPadding;
|
|
55
|
+
exports.cssTextStyle = react.cssTextStyle;
|
|
56
|
+
exports.cssWidth = react.cssWidth;
|
|
57
|
+
exports.registerBuiltinComponents = react.registerBuiltinComponents;
|
|
58
|
+
exports.registerComponent = react.registerComponent;
|
|
59
|
+
//# sourceMappingURL=components.cjs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"components.cjs.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export { B as Box, c as Button, C as Carousel, d as Countdown, j as DEFAULT_BOX_ANIMATE_DELAY, k as DEFAULT_BOX_ANIMATE_DURATION, i as DEFAULT_BOX_ANIMATE_TYPE, m as DEFAULT_ITEM_ANIMATE_DELAY, n as DEFAULT_ITEM_ANIMATE_DURATION, l as DEFAULT_ITEM_ANIMATE_TYPE, o as DEFAULT_ITEM_STAGGER_DURATION, e as Divider, f as Embed, I as Image, N as Navigation, g as Root, S as SocialLinks, T as Text, v as cssBorder, w as cssBorderRadius, x as cssBoxShadow, y as cssGridItem, s as cssMargin, p as cssMediaRules, t as cssPadding, z as cssTextStyle, q as cssWidth, r as registerBuiltinComponents, h as registerComponent } from "./react.es2.js";
|
|
2
|
+
import "react";
|
|
3
|
+
import "use-sync-external-store/shim/with-selector";
|
|
4
|
+
import "@apollo/client";
|
|
5
|
+
import "redux";
|
|
6
|
+
import "redux-thunk";
|
|
7
|
+
import "./actions.es.js";
|
|
8
|
+
import "./descriptors.es.js";
|
|
9
|
+
import "styled-components";
|
|
10
|
+
import "framer-motion";
|
|
11
|
+
import "react/jsx-runtime";
|
|
12
|
+
import "./box-models.es.js";
|
|
13
|
+
import "css-box-model";
|
|
14
|
+
import "next/image";
|
|
15
|
+
import "react-player";
|
|
16
|
+
import "color";
|
|
17
|
+
import "scroll-into-view-if-needed";
|
|
18
|
+
import "next/link";
|
|
19
|
+
import "react-use-gesture";
|
|
20
|
+
import "@popmotion/popcorn";
|
|
21
|
+
import "uuid/v4";
|
|
22
|
+
import "polished";
|
|
23
|
+
import "slate";
|
|
24
|
+
import "slate-hotkeys";
|
|
25
|
+
import "corporate-ipsum";
|
|
26
|
+
import "slate-react";
|
|
27
|
+
import "@convertkit/slate-lists";
|
|
28
|
+
//# sourceMappingURL=components.es.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"components.es.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
const SwatchFragmentDoc = {
|
|
3
|
+
kind: "Document",
|
|
4
|
+
definitions: [
|
|
5
|
+
{
|
|
6
|
+
kind: "FragmentDefinition",
|
|
7
|
+
name: { kind: "Name", value: "Swatch" },
|
|
8
|
+
typeCondition: { kind: "NamedType", name: { kind: "Name", value: "Swatch" } },
|
|
9
|
+
selectionSet: {
|
|
10
|
+
kind: "SelectionSet",
|
|
11
|
+
selections: [
|
|
12
|
+
{ kind: "Field", name: { kind: "Name", value: "__typename" } },
|
|
13
|
+
{ kind: "Field", name: { kind: "Name", value: "id" } },
|
|
14
|
+
{ kind: "Field", name: { kind: "Name", value: "hue" } },
|
|
15
|
+
{ kind: "Field", name: { kind: "Name", value: "saturation" } },
|
|
16
|
+
{ kind: "Field", name: { kind: "Name", value: "lightness" } }
|
|
17
|
+
]
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
]
|
|
21
|
+
};
|
|
22
|
+
const FileFragmentDoc = {
|
|
23
|
+
kind: "Document",
|
|
24
|
+
definitions: [
|
|
25
|
+
{
|
|
26
|
+
kind: "FragmentDefinition",
|
|
27
|
+
name: { kind: "Name", value: "File" },
|
|
28
|
+
typeCondition: { kind: "NamedType", name: { kind: "Name", value: "File" } },
|
|
29
|
+
selectionSet: {
|
|
30
|
+
kind: "SelectionSet",
|
|
31
|
+
selections: [
|
|
32
|
+
{ kind: "Field", name: { kind: "Name", value: "__typename" } },
|
|
33
|
+
{ kind: "Field", name: { kind: "Name", value: "id" } },
|
|
34
|
+
{ kind: "Field", name: { kind: "Name", value: "name" } },
|
|
35
|
+
{ kind: "Field", name: { kind: "Name", value: "publicUrl" } },
|
|
36
|
+
{ kind: "Field", name: { kind: "Name", value: "extension" } },
|
|
37
|
+
{
|
|
38
|
+
kind: "Field",
|
|
39
|
+
name: { kind: "Name", value: "dimensions" },
|
|
40
|
+
selectionSet: {
|
|
41
|
+
kind: "SelectionSet",
|
|
42
|
+
selections: [
|
|
43
|
+
{ kind: "Field", name: { kind: "Name", value: "width" } },
|
|
44
|
+
{ kind: "Field", name: { kind: "Name", value: "height" } }
|
|
45
|
+
]
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
]
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
]
|
|
52
|
+
};
|
|
53
|
+
const TypographyFragmentDoc = {
|
|
54
|
+
kind: "Document",
|
|
55
|
+
definitions: [
|
|
56
|
+
{
|
|
57
|
+
kind: "FragmentDefinition",
|
|
58
|
+
name: { kind: "Name", value: "Typography" },
|
|
59
|
+
typeCondition: { kind: "NamedType", name: { kind: "Name", value: "Typography" } },
|
|
60
|
+
selectionSet: {
|
|
61
|
+
kind: "SelectionSet",
|
|
62
|
+
selections: [
|
|
63
|
+
{ kind: "Field", name: { kind: "Name", value: "__typename" } },
|
|
64
|
+
{ kind: "Field", name: { kind: "Name", value: "id" } },
|
|
65
|
+
{ kind: "Field", name: { kind: "Name", value: "name" } },
|
|
66
|
+
{
|
|
67
|
+
kind: "Field",
|
|
68
|
+
name: { kind: "Name", value: "style" },
|
|
69
|
+
selectionSet: {
|
|
70
|
+
kind: "SelectionSet",
|
|
71
|
+
selections: [
|
|
72
|
+
{ kind: "Field", name: { kind: "Name", value: "deviceId" } },
|
|
73
|
+
{
|
|
74
|
+
kind: "Field",
|
|
75
|
+
name: { kind: "Name", value: "value" },
|
|
76
|
+
selectionSet: {
|
|
77
|
+
kind: "SelectionSet",
|
|
78
|
+
selections: [
|
|
79
|
+
{ kind: "Field", name: { kind: "Name", value: "fontFamily" } },
|
|
80
|
+
{
|
|
81
|
+
kind: "Field",
|
|
82
|
+
name: { kind: "Name", value: "fontSize" },
|
|
83
|
+
selectionSet: {
|
|
84
|
+
kind: "SelectionSet",
|
|
85
|
+
selections: [
|
|
86
|
+
{ kind: "Field", name: { kind: "Name", value: "value" } },
|
|
87
|
+
{ kind: "Field", name: { kind: "Name", value: "unit" } }
|
|
88
|
+
]
|
|
89
|
+
}
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
kind: "Field",
|
|
93
|
+
name: { kind: "Name", value: "color" },
|
|
94
|
+
selectionSet: {
|
|
95
|
+
kind: "SelectionSet",
|
|
96
|
+
selections: [
|
|
97
|
+
{ kind: "Field", name: { kind: "Name", value: "swatchId" } },
|
|
98
|
+
{ kind: "Field", name: { kind: "Name", value: "alpha" } }
|
|
99
|
+
]
|
|
100
|
+
}
|
|
101
|
+
},
|
|
102
|
+
{ kind: "Field", name: { kind: "Name", value: "lineHeight" } },
|
|
103
|
+
{ kind: "Field", name: { kind: "Name", value: "letterSpacing" } },
|
|
104
|
+
{ kind: "Field", name: { kind: "Name", value: "fontWeight" } },
|
|
105
|
+
{ kind: "Field", name: { kind: "Name", value: "textAlign" } },
|
|
106
|
+
{ kind: "Field", name: { kind: "Name", value: "uppercase" } },
|
|
107
|
+
{ kind: "Field", name: { kind: "Name", value: "underline" } },
|
|
108
|
+
{ kind: "Field", name: { kind: "Name", value: "strikethrough" } },
|
|
109
|
+
{ kind: "Field", name: { kind: "Name", value: "italic" } }
|
|
110
|
+
]
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
]
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
]
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
]
|
|
120
|
+
};
|
|
121
|
+
const PagePathnameSliceFragmentDoc = {
|
|
122
|
+
kind: "Document",
|
|
123
|
+
definitions: [
|
|
124
|
+
{
|
|
125
|
+
kind: "FragmentDefinition",
|
|
126
|
+
name: { kind: "Name", value: "PagePathnameSlice" },
|
|
127
|
+
typeCondition: { kind: "NamedType", name: { kind: "Name", value: "PagePathnameSlice" } },
|
|
128
|
+
selectionSet: {
|
|
129
|
+
kind: "SelectionSet",
|
|
130
|
+
selections: [
|
|
131
|
+
{ kind: "Field", name: { kind: "Name", value: "__typename" } },
|
|
132
|
+
{ kind: "Field", name: { kind: "Name", value: "id" } },
|
|
133
|
+
{ kind: "Field", name: { kind: "Name", value: "pathname" } }
|
|
134
|
+
]
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
]
|
|
138
|
+
};
|
|
139
|
+
const Fragments = {
|
|
140
|
+
Swatch: SwatchFragmentDoc,
|
|
141
|
+
File: FileFragmentDoc,
|
|
142
|
+
Typography: TypographyFragmentDoc,
|
|
143
|
+
PagePathnameSlice: PagePathnameSliceFragmentDoc
|
|
144
|
+
};
|
|
145
|
+
exports.Fragments = Fragments;
|
|
146
|
+
//# sourceMappingURL=constants.cjs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.cjs.js","sources":["../src/api/generated/graphql.ts","../src/api/constants.ts"],"sourcesContent":["import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/core'\nexport type SwatchFragment = {\n __typename: 'Swatch'\n id: string\n hue: number\n saturation: number\n lightness: number\n}\n\nexport type FileFragment = {\n __typename: 'File'\n id: string\n name: string\n publicUrl: any\n extension?: string | null\n dimensions?: { __typename?: 'ImageDimensions'; width: number; height: number } | null\n}\n\nexport type TypographyFragment = {\n __typename: 'Typography'\n id: string\n name: string\n style: Array<{\n __typename?: 'TypographyStyle'\n deviceId: string\n value: {\n __typename?: 'TypographyStyleValue'\n fontFamily?: string | null\n lineHeight?: number | null\n letterSpacing?: number | null\n fontWeight?: number | null\n textAlign?: string | null\n uppercase?: boolean | null\n underline?: boolean | null\n strikethrough?: boolean | null\n italic?: boolean | null\n fontSize?: { __typename?: 'Length'; value?: number | null; unit?: string | null } | null\n color?: { __typename?: 'Color'; swatchId?: string | null; alpha?: number | null } | null\n }\n }>\n}\n\nexport type PagePathnameSliceFragment = {\n __typename: 'PagePathnameSlice'\n id: string\n pathname: any\n}\n\nexport const SwatchFragmentDoc = {\n kind: 'Document',\n definitions: [\n {\n kind: 'FragmentDefinition',\n name: { kind: 'Name', value: 'Swatch' },\n typeCondition: { kind: 'NamedType', name: { kind: 'Name', value: 'Swatch' } },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: '__typename' } },\n { kind: 'Field', name: { kind: 'Name', value: 'id' } },\n { kind: 'Field', name: { kind: 'Name', value: 'hue' } },\n { kind: 'Field', name: { kind: 'Name', value: 'saturation' } },\n { kind: 'Field', name: { kind: 'Name', value: 'lightness' } },\n ],\n },\n },\n ],\n} as unknown as DocumentNode<SwatchFragment, unknown>\nexport const FileFragmentDoc = {\n kind: 'Document',\n definitions: [\n {\n kind: 'FragmentDefinition',\n name: { kind: 'Name', value: 'File' },\n typeCondition: { kind: 'NamedType', name: { kind: 'Name', value: 'File' } },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: '__typename' } },\n { kind: 'Field', name: { kind: 'Name', value: 'id' } },\n { kind: 'Field', name: { kind: 'Name', value: 'name' } },\n { kind: 'Field', name: { kind: 'Name', value: 'publicUrl' } },\n { kind: 'Field', name: { kind: 'Name', value: 'extension' } },\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'dimensions' },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'width' } },\n { kind: 'Field', name: { kind: 'Name', value: 'height' } },\n ],\n },\n },\n ],\n },\n },\n ],\n} as unknown as DocumentNode<FileFragment, unknown>\nexport const TypographyFragmentDoc = {\n kind: 'Document',\n definitions: [\n {\n kind: 'FragmentDefinition',\n name: { kind: 'Name', value: 'Typography' },\n typeCondition: { kind: 'NamedType', name: { kind: 'Name', value: 'Typography' } },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: '__typename' } },\n { kind: 'Field', name: { kind: 'Name', value: 'id' } },\n { kind: 'Field', name: { kind: 'Name', value: 'name' } },\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'style' },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'deviceId' } },\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'value' },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'fontFamily' } },\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'fontSize' },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'value' } },\n { kind: 'Field', name: { kind: 'Name', value: 'unit' } },\n ],\n },\n },\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'color' },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'swatchId' } },\n { kind: 'Field', name: { kind: 'Name', value: 'alpha' } },\n ],\n },\n },\n { kind: 'Field', name: { kind: 'Name', value: 'lineHeight' } },\n { kind: 'Field', name: { kind: 'Name', value: 'letterSpacing' } },\n { kind: 'Field', name: { kind: 'Name', value: 'fontWeight' } },\n { kind: 'Field', name: { kind: 'Name', value: 'textAlign' } },\n { kind: 'Field', name: { kind: 'Name', value: 'uppercase' } },\n { kind: 'Field', name: { kind: 'Name', value: 'underline' } },\n { kind: 'Field', name: { kind: 'Name', value: 'strikethrough' } },\n { kind: 'Field', name: { kind: 'Name', value: 'italic' } },\n ],\n },\n },\n ],\n },\n },\n ],\n },\n },\n ],\n} as unknown as DocumentNode<TypographyFragment, unknown>\nexport const PagePathnameSliceFragmentDoc = {\n kind: 'Document',\n definitions: [\n {\n kind: 'FragmentDefinition',\n name: { kind: 'Name', value: 'PagePathnameSlice' },\n typeCondition: { kind: 'NamedType', name: { kind: 'Name', value: 'PagePathnameSlice' } },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: '__typename' } },\n { kind: 'Field', name: { kind: 'Name', value: 'id' } },\n { kind: 'Field', name: { kind: 'Name', value: 'pathname' } },\n ],\n },\n },\n ],\n} as unknown as DocumentNode<PagePathnameSliceFragment, unknown>\n","import type { DocumentNode } from 'graphql'\n\nimport {\n SwatchFragmentDoc,\n FileFragmentDoc,\n TypographyFragmentDoc,\n PagePathnameSliceFragmentDoc,\n} from './generated/graphql'\nimport type { APIResourceType } from './types'\n\nexport const Fragments: Record<APIResourceType, DocumentNode> = {\n Swatch: SwatchFragmentDoc,\n File: FileFragmentDoc,\n Typography: TypographyFragmentDoc,\n PagePathnameSlice: PagePathnameSliceFragmentDoc,\n}\n"],"names":[],"mappings":";AAgDO,MAAM,oBAAoB;AAAA,EAC/B,MAAM;AAAA,EACN,aAAa;AAAA,IACX;AAAA,MACE,MAAM;AAAA,MACN,MAAM,EAAE,MAAM,QAAQ,OAAO,SAAS;AAAA,MACtC,eAAe,EAAE,MAAM,aAAa,MAAM,EAAE,MAAM,QAAQ,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oBAAoB;AAAA,MACjD,eAAe,EAAE,MAAM,aAAa,MAAM,EAAE,MAAM,QAAQ,OAAO,sBAAsB;AAAA,MACvF,cAAc;AAAA,QACZ,MAAM;AAAA,QACN,YAAY;AAAA,UACV,EAAE,MAAM,SAAS,MAAM,EAAE,MAAM,QAAQ,OAAO,eAAe;AAAA,UAC7D,EAAE,MAAM,SAAS,MAAM,EAAE,MAAM,QAAQ,OAAO,OAAO;AAAA,UACrD,EAAE,MAAM,SAAS,MAAM,EAAE,MAAM,QAAQ,OAAO,aAAa;AAAA,QAC7D;AAAA,MACF;AAAA,IACF;AAAA,EACF;AACF;AC9KO,MAAM,YAAmD;AAAA,EAC9D,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,YAAY;AAAA,EACZ,mBAAmB;AACrB;;"}
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
const SwatchFragmentDoc = {
|
|
2
|
+
kind: "Document",
|
|
3
|
+
definitions: [
|
|
4
|
+
{
|
|
5
|
+
kind: "FragmentDefinition",
|
|
6
|
+
name: { kind: "Name", value: "Swatch" },
|
|
7
|
+
typeCondition: { kind: "NamedType", name: { kind: "Name", value: "Swatch" } },
|
|
8
|
+
selectionSet: {
|
|
9
|
+
kind: "SelectionSet",
|
|
10
|
+
selections: [
|
|
11
|
+
{ kind: "Field", name: { kind: "Name", value: "__typename" } },
|
|
12
|
+
{ kind: "Field", name: { kind: "Name", value: "id" } },
|
|
13
|
+
{ kind: "Field", name: { kind: "Name", value: "hue" } },
|
|
14
|
+
{ kind: "Field", name: { kind: "Name", value: "saturation" } },
|
|
15
|
+
{ kind: "Field", name: { kind: "Name", value: "lightness" } }
|
|
16
|
+
]
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
]
|
|
20
|
+
};
|
|
21
|
+
const FileFragmentDoc = {
|
|
22
|
+
kind: "Document",
|
|
23
|
+
definitions: [
|
|
24
|
+
{
|
|
25
|
+
kind: "FragmentDefinition",
|
|
26
|
+
name: { kind: "Name", value: "File" },
|
|
27
|
+
typeCondition: { kind: "NamedType", name: { kind: "Name", value: "File" } },
|
|
28
|
+
selectionSet: {
|
|
29
|
+
kind: "SelectionSet",
|
|
30
|
+
selections: [
|
|
31
|
+
{ kind: "Field", name: { kind: "Name", value: "__typename" } },
|
|
32
|
+
{ kind: "Field", name: { kind: "Name", value: "id" } },
|
|
33
|
+
{ kind: "Field", name: { kind: "Name", value: "name" } },
|
|
34
|
+
{ kind: "Field", name: { kind: "Name", value: "publicUrl" } },
|
|
35
|
+
{ kind: "Field", name: { kind: "Name", value: "extension" } },
|
|
36
|
+
{
|
|
37
|
+
kind: "Field",
|
|
38
|
+
name: { kind: "Name", value: "dimensions" },
|
|
39
|
+
selectionSet: {
|
|
40
|
+
kind: "SelectionSet",
|
|
41
|
+
selections: [
|
|
42
|
+
{ kind: "Field", name: { kind: "Name", value: "width" } },
|
|
43
|
+
{ kind: "Field", name: { kind: "Name", value: "height" } }
|
|
44
|
+
]
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
]
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
]
|
|
51
|
+
};
|
|
52
|
+
const TypographyFragmentDoc = {
|
|
53
|
+
kind: "Document",
|
|
54
|
+
definitions: [
|
|
55
|
+
{
|
|
56
|
+
kind: "FragmentDefinition",
|
|
57
|
+
name: { kind: "Name", value: "Typography" },
|
|
58
|
+
typeCondition: { kind: "NamedType", name: { kind: "Name", value: "Typography" } },
|
|
59
|
+
selectionSet: {
|
|
60
|
+
kind: "SelectionSet",
|
|
61
|
+
selections: [
|
|
62
|
+
{ kind: "Field", name: { kind: "Name", value: "__typename" } },
|
|
63
|
+
{ kind: "Field", name: { kind: "Name", value: "id" } },
|
|
64
|
+
{ kind: "Field", name: { kind: "Name", value: "name" } },
|
|
65
|
+
{
|
|
66
|
+
kind: "Field",
|
|
67
|
+
name: { kind: "Name", value: "style" },
|
|
68
|
+
selectionSet: {
|
|
69
|
+
kind: "SelectionSet",
|
|
70
|
+
selections: [
|
|
71
|
+
{ kind: "Field", name: { kind: "Name", value: "deviceId" } },
|
|
72
|
+
{
|
|
73
|
+
kind: "Field",
|
|
74
|
+
name: { kind: "Name", value: "value" },
|
|
75
|
+
selectionSet: {
|
|
76
|
+
kind: "SelectionSet",
|
|
77
|
+
selections: [
|
|
78
|
+
{ kind: "Field", name: { kind: "Name", value: "fontFamily" } },
|
|
79
|
+
{
|
|
80
|
+
kind: "Field",
|
|
81
|
+
name: { kind: "Name", value: "fontSize" },
|
|
82
|
+
selectionSet: {
|
|
83
|
+
kind: "SelectionSet",
|
|
84
|
+
selections: [
|
|
85
|
+
{ kind: "Field", name: { kind: "Name", value: "value" } },
|
|
86
|
+
{ kind: "Field", name: { kind: "Name", value: "unit" } }
|
|
87
|
+
]
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
kind: "Field",
|
|
92
|
+
name: { kind: "Name", value: "color" },
|
|
93
|
+
selectionSet: {
|
|
94
|
+
kind: "SelectionSet",
|
|
95
|
+
selections: [
|
|
96
|
+
{ kind: "Field", name: { kind: "Name", value: "swatchId" } },
|
|
97
|
+
{ kind: "Field", name: { kind: "Name", value: "alpha" } }
|
|
98
|
+
]
|
|
99
|
+
}
|
|
100
|
+
},
|
|
101
|
+
{ kind: "Field", name: { kind: "Name", value: "lineHeight" } },
|
|
102
|
+
{ kind: "Field", name: { kind: "Name", value: "letterSpacing" } },
|
|
103
|
+
{ kind: "Field", name: { kind: "Name", value: "fontWeight" } },
|
|
104
|
+
{ kind: "Field", name: { kind: "Name", value: "textAlign" } },
|
|
105
|
+
{ kind: "Field", name: { kind: "Name", value: "uppercase" } },
|
|
106
|
+
{ kind: "Field", name: { kind: "Name", value: "underline" } },
|
|
107
|
+
{ kind: "Field", name: { kind: "Name", value: "strikethrough" } },
|
|
108
|
+
{ kind: "Field", name: { kind: "Name", value: "italic" } }
|
|
109
|
+
]
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
]
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
]
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
]
|
|
119
|
+
};
|
|
120
|
+
const PagePathnameSliceFragmentDoc = {
|
|
121
|
+
kind: "Document",
|
|
122
|
+
definitions: [
|
|
123
|
+
{
|
|
124
|
+
kind: "FragmentDefinition",
|
|
125
|
+
name: { kind: "Name", value: "PagePathnameSlice" },
|
|
126
|
+
typeCondition: { kind: "NamedType", name: { kind: "Name", value: "PagePathnameSlice" } },
|
|
127
|
+
selectionSet: {
|
|
128
|
+
kind: "SelectionSet",
|
|
129
|
+
selections: [
|
|
130
|
+
{ kind: "Field", name: { kind: "Name", value: "__typename" } },
|
|
131
|
+
{ kind: "Field", name: { kind: "Name", value: "id" } },
|
|
132
|
+
{ kind: "Field", name: { kind: "Name", value: "pathname" } }
|
|
133
|
+
]
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
]
|
|
137
|
+
};
|
|
138
|
+
const Fragments = {
|
|
139
|
+
Swatch: SwatchFragmentDoc,
|
|
140
|
+
File: FileFragmentDoc,
|
|
141
|
+
Typography: TypographyFragmentDoc,
|
|
142
|
+
PagePathnameSlice: PagePathnameSliceFragmentDoc
|
|
143
|
+
};
|
|
144
|
+
export { Fragments as F };
|
|
145
|
+
//# sourceMappingURL=constants.es.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.es.js","sources":["../src/api/generated/graphql.ts","../src/api/constants.ts"],"sourcesContent":["import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/core'\nexport type SwatchFragment = {\n __typename: 'Swatch'\n id: string\n hue: number\n saturation: number\n lightness: number\n}\n\nexport type FileFragment = {\n __typename: 'File'\n id: string\n name: string\n publicUrl: any\n extension?: string | null\n dimensions?: { __typename?: 'ImageDimensions'; width: number; height: number } | null\n}\n\nexport type TypographyFragment = {\n __typename: 'Typography'\n id: string\n name: string\n style: Array<{\n __typename?: 'TypographyStyle'\n deviceId: string\n value: {\n __typename?: 'TypographyStyleValue'\n fontFamily?: string | null\n lineHeight?: number | null\n letterSpacing?: number | null\n fontWeight?: number | null\n textAlign?: string | null\n uppercase?: boolean | null\n underline?: boolean | null\n strikethrough?: boolean | null\n italic?: boolean | null\n fontSize?: { __typename?: 'Length'; value?: number | null; unit?: string | null } | null\n color?: { __typename?: 'Color'; swatchId?: string | null; alpha?: number | null } | null\n }\n }>\n}\n\nexport type PagePathnameSliceFragment = {\n __typename: 'PagePathnameSlice'\n id: string\n pathname: any\n}\n\nexport const SwatchFragmentDoc = {\n kind: 'Document',\n definitions: [\n {\n kind: 'FragmentDefinition',\n name: { kind: 'Name', value: 'Swatch' },\n typeCondition: { kind: 'NamedType', name: { kind: 'Name', value: 'Swatch' } },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: '__typename' } },\n { kind: 'Field', name: { kind: 'Name', value: 'id' } },\n { kind: 'Field', name: { kind: 'Name', value: 'hue' } },\n { kind: 'Field', name: { kind: 'Name', value: 'saturation' } },\n { kind: 'Field', name: { kind: 'Name', value: 'lightness' } },\n ],\n },\n },\n ],\n} as unknown as DocumentNode<SwatchFragment, unknown>\nexport const FileFragmentDoc = {\n kind: 'Document',\n definitions: [\n {\n kind: 'FragmentDefinition',\n name: { kind: 'Name', value: 'File' },\n typeCondition: { kind: 'NamedType', name: { kind: 'Name', value: 'File' } },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: '__typename' } },\n { kind: 'Field', name: { kind: 'Name', value: 'id' } },\n { kind: 'Field', name: { kind: 'Name', value: 'name' } },\n { kind: 'Field', name: { kind: 'Name', value: 'publicUrl' } },\n { kind: 'Field', name: { kind: 'Name', value: 'extension' } },\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'dimensions' },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'width' } },\n { kind: 'Field', name: { kind: 'Name', value: 'height' } },\n ],\n },\n },\n ],\n },\n },\n ],\n} as unknown as DocumentNode<FileFragment, unknown>\nexport const TypographyFragmentDoc = {\n kind: 'Document',\n definitions: [\n {\n kind: 'FragmentDefinition',\n name: { kind: 'Name', value: 'Typography' },\n typeCondition: { kind: 'NamedType', name: { kind: 'Name', value: 'Typography' } },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: '__typename' } },\n { kind: 'Field', name: { kind: 'Name', value: 'id' } },\n { kind: 'Field', name: { kind: 'Name', value: 'name' } },\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'style' },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'deviceId' } },\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'value' },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'fontFamily' } },\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'fontSize' },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'value' } },\n { kind: 'Field', name: { kind: 'Name', value: 'unit' } },\n ],\n },\n },\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'color' },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'swatchId' } },\n { kind: 'Field', name: { kind: 'Name', value: 'alpha' } },\n ],\n },\n },\n { kind: 'Field', name: { kind: 'Name', value: 'lineHeight' } },\n { kind: 'Field', name: { kind: 'Name', value: 'letterSpacing' } },\n { kind: 'Field', name: { kind: 'Name', value: 'fontWeight' } },\n { kind: 'Field', name: { kind: 'Name', value: 'textAlign' } },\n { kind: 'Field', name: { kind: 'Name', value: 'uppercase' } },\n { kind: 'Field', name: { kind: 'Name', value: 'underline' } },\n { kind: 'Field', name: { kind: 'Name', value: 'strikethrough' } },\n { kind: 'Field', name: { kind: 'Name', value: 'italic' } },\n ],\n },\n },\n ],\n },\n },\n ],\n },\n },\n ],\n} as unknown as DocumentNode<TypographyFragment, unknown>\nexport const PagePathnameSliceFragmentDoc = {\n kind: 'Document',\n definitions: [\n {\n kind: 'FragmentDefinition',\n name: { kind: 'Name', value: 'PagePathnameSlice' },\n typeCondition: { kind: 'NamedType', name: { kind: 'Name', value: 'PagePathnameSlice' } },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: '__typename' } },\n { kind: 'Field', name: { kind: 'Name', value: 'id' } },\n { kind: 'Field', name: { kind: 'Name', value: 'pathname' } },\n ],\n },\n },\n ],\n} as unknown as DocumentNode<PagePathnameSliceFragment, unknown>\n","import type { DocumentNode } from 'graphql'\n\nimport {\n SwatchFragmentDoc,\n FileFragmentDoc,\n TypographyFragmentDoc,\n PagePathnameSliceFragmentDoc,\n} from './generated/graphql'\nimport type { APIResourceType } from './types'\n\nexport const Fragments: Record<APIResourceType, DocumentNode> = {\n Swatch: SwatchFragmentDoc,\n File: FileFragmentDoc,\n Typography: TypographyFragmentDoc,\n PagePathnameSlice: PagePathnameSliceFragmentDoc,\n}\n"],"names":[],"mappings":"AAgDO,MAAM,oBAAoB;AAAA,EAC/B,MAAM;AAAA,EACN,aAAa;AAAA,IACX;AAAA,MACE,MAAM;AAAA,MACN,MAAM,EAAE,MAAM,QAAQ,OAAO,SAAS;AAAA,MACtC,eAAe,EAAE,MAAM,aAAa,MAAM,EAAE,MAAM,QAAQ,OAAO,WAAW;AAAA,MAC5E,cAAc;AAAA,QACZ,MAAM;AAAA,QACN,YAAY;AAAA,UACV,EAAE,MAAM,SAAS,MAAM,EAAE,MAAM,QAAQ,OAAO,eAAe;AAAA,UAC7D,EAAE,MAAM,SAAS,MAAM,EAAE,MAAM,QAAQ,OAAO,OAAO;AAAA,UACrD,EAAE,MAAM,SAAS,MAAM,EAAE,MAAM,QAAQ,OAAO,QAAQ;AAAA,UACtD,EAAE,M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