@chamn/engine 0.0.9 → 0.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/component/CSSEditor/index.d.ts +16 -0
- package/dist/component/CSSPropertiesEditor/cssProperties.d.ts +898 -0
- package/dist/component/CSSPropertiesEditor/index.d.ts +43 -0
- package/dist/component/CSSPropertiesEditor/util.d.ts +1 -0
- package/dist/component/CSSPropertiesVariableBindEditor/cssProperties.d.ts +898 -0
- package/dist/component/CSSPropertiesVariableBindEditor/index.d.ts +37 -0
- package/dist/component/CSSPropertiesVariableBindEditor/util.d.ts +1 -0
- package/dist/component/ClassNameEditor/index.d.ts +16 -0
- package/dist/component/CustomSchemaForm/components/Form/Field/index.d.ts +11 -0
- package/dist/component/CustomSchemaForm/components/Form/context.d.ts +12 -0
- package/dist/component/CustomSchemaForm/components/Form/index.d.ts +18 -0
- package/dist/component/CustomSchemaForm/components/SetterSwitcher/index.d.ts +14 -0
- package/dist/component/CustomSchemaForm/components/Setters/ArraySetter/ArrayItem.d.ts +11 -0
- package/dist/component/CustomSchemaForm/components/Setters/ArraySetter/SortItemOrderModal.d.ts +10 -0
- package/dist/component/CustomSchemaForm/components/Setters/ArraySetter/index.d.ts +14 -0
- package/dist/component/CustomSchemaForm/components/Setters/BooleanSetter/index.d.ts +5 -0
- package/dist/component/CustomSchemaForm/components/Setters/CSSValueSetter/index.d.ts +6 -0
- package/dist/component/CustomSchemaForm/components/Setters/ExpressionSetter/index.d.ts +8 -0
- package/dist/component/CustomSchemaForm/components/Setters/FunctionSetter/defaultDts.d.ts +1 -0
- package/dist/component/CustomSchemaForm/components/Setters/FunctionSetter/index.d.ts +2 -0
- package/dist/component/CustomSchemaForm/components/Setters/JSONSetter/index.d.ts +2 -0
- package/dist/component/CustomSchemaForm/components/Setters/NumberSetter/index.d.ts +3 -0
- package/dist/component/CustomSchemaForm/components/Setters/SelectSetter/index.d.ts +3 -0
- package/dist/component/CustomSchemaForm/components/Setters/ShapeSetter/index.d.ts +8 -0
- package/dist/component/CustomSchemaForm/components/Setters/StringSetter/index.d.ts +3 -0
- package/dist/component/CustomSchemaForm/components/Setters/TextAreaSetter/index.d.ts +3 -0
- package/dist/component/CustomSchemaForm/components/Setters/index.d.ts +3 -0
- package/dist/component/CustomSchemaForm/components/Setters/type.d.ts +19 -0
- package/dist/component/CustomSchemaForm/context.d.ts +15 -0
- package/dist/component/CustomSchemaForm/index.d.ts +20 -0
- package/dist/component/CustomSchemaForm/utils.d.ts +2 -0
- package/dist/component/MonacoEditor/index.d.ts +15 -0
- package/dist/component/Workbench/index.d.ts +61 -0
- package/dist/core/pluginManager.d.ts +61 -0
- package/dist/i18n/en_US/index.d.ts +5 -0
- package/dist/i18n/index.d.ts +6 -0
- package/dist/i18n/zh_CN/index.d.ts +5 -0
- package/dist/index.d.ts +44 -0
- package/dist/index.js +197 -0
- package/dist/index.js.map +1 -0
- package/dist/{index.es.js → index.mjs} +6867 -6541
- package/dist/index.mjs.map +1 -0
- package/dist/material/innerMaterial.d.ts +2 -0
- package/dist/plugins/AdvancePanel/index.d.ts +10 -0
- package/dist/plugins/ComponentLibrary/components/DragItem/index.d.ts +12 -0
- package/dist/plugins/ComponentLibrary/components/ListView/index.d.ts +9 -0
- package/dist/plugins/ComponentLibrary/index.d.ts +3 -0
- package/dist/plugins/ComponentLibrary/localize/en_US/index.d.ts +1 -0
- package/dist/plugins/ComponentLibrary/localize/index.d.ts +2 -0
- package/dist/plugins/ComponentLibrary/localize/zh_CN/index.d.ts +1 -0
- package/dist/plugins/ComponentLibrary/util.d.ts +1 -0
- package/dist/plugins/ComponentStatePanel/index.d.ts +10 -0
- package/dist/plugins/Designer/components/DefaultSelectToolBar/index.d.ts +10 -0
- package/dist/plugins/Designer/components/GhostView/index.d.ts +5 -0
- package/dist/plugins/Designer/config.d.ts +1 -0
- package/dist/plugins/Designer/index.d.ts +15 -0
- package/dist/plugins/Designer/localize/en_US/index.d.ts +1 -0
- package/dist/plugins/Designer/localize/index.d.ts +2 -0
- package/dist/plugins/Designer/localize/zh_CN/index.d.ts +1 -0
- package/dist/plugins/Designer/util.d.ts +2 -0
- package/dist/plugins/Designer/view.d.ts +30 -0
- package/dist/plugins/DisplaySourceSchema/index.d.ts +9 -0
- package/dist/plugins/GlobalStatePanel/index.d.ts +3 -0
- package/dist/plugins/GlobalStatePanel/localize/en_US/index.d.ts +1 -0
- package/dist/plugins/GlobalStatePanel/localize/index.d.ts +2 -0
- package/dist/plugins/GlobalStatePanel/localize/zh_CN/index.d.ts +1 -0
- package/dist/plugins/History/index.d.ts +2 -0
- package/dist/plugins/OutlineTree/components/TreeView/context.d.ts +30 -0
- package/dist/plugins/OutlineTree/components/TreeView/dataStruct.d.ts +21 -0
- package/dist/plugins/OutlineTree/components/TreeView/index.d.ts +34 -0
- package/dist/plugins/OutlineTree/components/TreeView/treeNode.d.ts +9 -0
- package/dist/plugins/OutlineTree/index.d.ts +3 -0
- package/dist/plugins/OutlineTree/localize/en_US/index.d.ts +1 -0
- package/dist/plugins/OutlineTree/localize/index.d.ts +2 -0
- package/dist/plugins/OutlineTree/localize/zh_CN/index.d.ts +1 -0
- package/dist/plugins/OutlineTree/util.d.ts +15 -0
- package/dist/plugins/PropertyPanel/index.d.ts +9 -0
- package/dist/plugins/RightPanel/index.d.ts +2 -0
- package/dist/plugins/RightPanel/view.d.ts +38 -0
- package/dist/plugins/VisualPanelPlus/index.d.ts +9 -0
- package/dist/plugins/index.d.ts +9 -0
- package/dist/utils/css.d.ts +19 -0
- package/dist/utils/defaultEngineConfig.d.ts +5 -0
- package/dist/utils/index.d.ts +6 -0
- package/dist/utils/logger.d.ts +1 -0
- package/package.json +12 -9
- package/.eslintignore +0 -1
- package/.eslintrc.js +0 -36
- package/.prettierrc.json +0 -7
- package/.storybook/main.js +0 -24
- package/.storybook/preview.js +0 -9
- package/CHANGELOG.md +0 -50
- package/__tests__/demo.test.ts +0 -3
- package/build.config.js +0 -88
- package/dist/index.cjs.js +0 -197
- package/dist/index.cjs.js.map +0 -1
- package/dist/index.es.js.map +0 -1
- package/index.html +0 -16
- package/jest.config.js +0 -196
- package/public/_dev_/render.d.ts +0 -2
- package/public/render.umd.js +0 -42
- package/public/render.umd.js.map +0 -1
- package/src/Engine.module.scss +0 -10
- package/src/Engine.module.scss.d.ts +0 -5
- package/src/_dev_/index.css +0 -22
- package/src/_dev_/index.tsx +0 -5
- package/src/_dev_/page/Editor/index.tsx +0 -198
- package/src/_dev_/page/Editor/indexCustom.tsx +0 -274
- package/src/_dev_/page/Preview/index.tsx +0 -56
- package/src/_dev_/render.ts +0 -3
- package/src/_dev_/router.tsx +0 -14
- package/src/assets/react.svg +0 -4
- package/src/assets/styles/mixin.scss +0 -15
- package/src/component/CSSEditor/index.tsx +0 -247
- package/src/component/CSSEditor/style.module.scss +0 -22
- package/src/component/CSSEditor/style.module.scss.d.ts +0 -6
- package/src/component/CSSPropertiesEditor/cssProperties.ts +0 -1062
- package/src/component/CSSPropertiesEditor/index.tsx +0 -389
- package/src/component/CSSPropertiesEditor/style.module.scss +0 -46
- package/src/component/CSSPropertiesEditor/style.module.scss.d.ts +0 -15
- package/src/component/CSSPropertiesEditor/util.ts +0 -19
- package/src/component/CSSPropertiesVariableBindEditor/cssProperties.ts +0 -782
- package/src/component/CSSPropertiesVariableBindEditor/index.tsx +0 -366
- package/src/component/CSSPropertiesVariableBindEditor/style.module.scss +0 -48
- package/src/component/CSSPropertiesVariableBindEditor/style.module.scss.d.ts +0 -15
- package/src/component/CSSPropertiesVariableBindEditor/util.ts +0 -19
- package/src/component/ClassNameEditor/index.tsx +0 -91
- package/src/component/ClassNameEditor/style.module.scss +0 -0
- package/src/component/CustomSchemaForm/components/Form/Field/index.tsx +0 -81
- package/src/component/CustomSchemaForm/components/Form/Field/style.module.scss +0 -32
- package/src/component/CustomSchemaForm/components/Form/Field/style.module.scss.d.ts +0 -8
- package/src/component/CustomSchemaForm/components/Form/context.ts +0 -23
- package/src/component/CustomSchemaForm/components/Form/index.tsx +0 -71
- package/src/component/CustomSchemaForm/components/SetterSwitcher/index.tsx +0 -273
- package/src/component/CustomSchemaForm/components/SetterSwitcher/style.module.scss +0 -16
- package/src/component/CustomSchemaForm/components/SetterSwitcher/style.module.scss.d.ts +0 -7
- package/src/component/CustomSchemaForm/components/Setters/ArraySetter/ArrayItem.tsx +0 -55
- package/src/component/CustomSchemaForm/components/Setters/ArraySetter/SortItemOrderModal.tsx +0 -160
- package/src/component/CustomSchemaForm/components/Setters/ArraySetter/index.tsx +0 -129
- package/src/component/CustomSchemaForm/components/Setters/ArraySetter/style.module.scss +0 -22
- package/src/component/CustomSchemaForm/components/Setters/ArraySetter/style.module.scss.d.ts +0 -7
- package/src/component/CustomSchemaForm/components/Setters/BooleanSetter/index.tsx +0 -32
- package/src/component/CustomSchemaForm/components/Setters/CSSValueSetter/index.tsx +0 -78
- package/src/component/CustomSchemaForm/components/Setters/CSSValueSetter/style.module.scss +0 -7
- package/src/component/CustomSchemaForm/components/Setters/CSSValueSetter/style.module.scss.d.ts +0 -6
- package/src/component/CustomSchemaForm/components/Setters/ExpressionSetter/index.tsx +0 -47
- package/src/component/CustomSchemaForm/components/Setters/FunctionSetter/defaultDts.ts +0 -28
- package/src/component/CustomSchemaForm/components/Setters/FunctionSetter/index.tsx +0 -93
- package/src/component/CustomSchemaForm/components/Setters/JSONSetter/index.tsx +0 -80
- package/src/component/CustomSchemaForm/components/Setters/NumberSetter/index.tsx +0 -34
- package/src/component/CustomSchemaForm/components/Setters/SelectSetter/index.tsx +0 -35
- package/src/component/CustomSchemaForm/components/Setters/ShapeSetter/index.tsx +0 -65
- package/src/component/CustomSchemaForm/components/Setters/StringSetter/index.tsx +0 -30
- package/src/component/CustomSchemaForm/components/Setters/TextAreaSetter/index.tsx +0 -31
- package/src/component/CustomSchemaForm/components/Setters/index.ts +0 -26
- package/src/component/CustomSchemaForm/components/Setters/type.ts +0 -18
- package/src/component/CustomSchemaForm/context.ts +0 -20
- package/src/component/CustomSchemaForm/index.tsx +0 -93
- package/src/component/CustomSchemaForm/style.module.scss +0 -15
- package/src/component/CustomSchemaForm/style.module.scss.d.ts +0 -11
- package/src/component/CustomSchemaForm/utils.ts +0 -13
- package/src/component/MonacoEditor/index.tsx +0 -81
- package/src/component/Workbench/index.tsx +0 -329
- package/src/component/Workbench/style.module.scss +0 -159
- package/src/component/Workbench/style.module.scss.d.ts +0 -25
- package/src/core/pluginManager.ts +0 -151
- package/src/i18n/en_US/index.ts +0 -5
- package/src/i18n/index.ts +0 -39
- package/src/i18n/zh_CN/index.ts +0 -5
- package/src/index.tsx +0 -150
- package/src/material/innerMaterial.ts +0 -343
- package/src/plugins/AdvancePanel/index.tsx +0 -191
- package/src/plugins/AdvancePanel/style.module.scss +0 -8
- package/src/plugins/AdvancePanel/style.module.scss.d.ts +0 -7
- package/src/plugins/ComponentLibrary/components/DragItem/index.tsx +0 -65
- package/src/plugins/ComponentLibrary/components/DragItem/style.module.scss +0 -58
- package/src/plugins/ComponentLibrary/components/DragItem/style.module.scss.d.ts +0 -9
- package/src/plugins/ComponentLibrary/components/ListView/index.tsx +0 -50
- package/src/plugins/ComponentLibrary/components/ListView/style.module.scss +0 -27
- package/src/plugins/ComponentLibrary/components/ListView/style.module.scss.d.ts +0 -12
- package/src/plugins/ComponentLibrary/index.tsx +0 -184
- package/src/plugins/ComponentLibrary/localize/en_US/index.ts +0 -3
- package/src/plugins/ComponentLibrary/localize/index.ts +0 -3
- package/src/plugins/ComponentLibrary/localize/zh_CN/index.ts +0 -3
- package/src/plugins/ComponentLibrary/style.module.scss +0 -31
- package/src/plugins/ComponentLibrary/style.module.scss.d.ts +0 -11
- package/src/plugins/ComponentLibrary/util.ts +0 -14
- package/src/plugins/ComponentStatePanel/index.tsx +0 -59
- package/src/plugins/Designer/components/DefaultSelectToolBar/index.tsx +0 -94
- package/src/plugins/Designer/components/DefaultSelectToolBar/style.module.scss +0 -59
- package/src/plugins/Designer/components/DefaultSelectToolBar/style.module.scss.d.ts +0 -11
- package/src/plugins/Designer/components/GhostView/index.tsx +0 -18
- package/src/plugins/Designer/config.ts +0 -1
- package/src/plugins/Designer/index.tsx +0 -61
- package/src/plugins/Designer/localize/en_US/index.ts +0 -3
- package/src/plugins/Designer/localize/index.ts +0 -3
- package/src/plugins/Designer/localize/zh_CN/index.ts +0 -3
- package/src/plugins/Designer/style.module.scss +0 -10
- package/src/plugins/Designer/style.module.scss.d.ts +0 -5
- package/src/plugins/Designer/util.ts +0 -18
- package/src/plugins/Designer/view.tsx +0 -225
- package/src/plugins/DisplaySourceSchema/index.tsx +0 -76
- package/src/plugins/GlobalStatePanel/index.tsx +0 -96
- package/src/plugins/GlobalStatePanel/localize/en_US/index.ts +0 -3
- package/src/plugins/GlobalStatePanel/localize/index.ts +0 -3
- package/src/plugins/GlobalStatePanel/localize/zh_CN/index.ts +0 -3
- package/src/plugins/GlobalStatePanel/style.module.scss +0 -8
- package/src/plugins/GlobalStatePanel/style.module.scss.d.ts +0 -5
- package/src/plugins/History/index.tsx +0 -110
- package/src/plugins/OutlineTree/components/TreeView/context.ts +0 -43
- package/src/plugins/OutlineTree/components/TreeView/dataStruct.ts +0 -58
- package/src/plugins/OutlineTree/components/TreeView/index.tsx +0 -376
- package/src/plugins/OutlineTree/components/TreeView/style.module.scss +0 -93
- package/src/plugins/OutlineTree/components/TreeView/style.module.scss.d.ts +0 -16
- package/src/plugins/OutlineTree/components/TreeView/treeNode.tsx +0 -271
- package/src/plugins/OutlineTree/index.tsx +0 -39
- package/src/plugins/OutlineTree/localize/en_US/index.ts +0 -3
- package/src/plugins/OutlineTree/localize/index.ts +0 -3
- package/src/plugins/OutlineTree/localize/zh_CN/index.ts +0 -3
- package/src/plugins/OutlineTree/util.tsx +0 -302
- package/src/plugins/PropertyPanel/index.tsx +0 -63
- package/src/plugins/PropertyPanel/style.module.scss +0 -12
- package/src/plugins/PropertyPanel/style.module.scss.d.ts +0 -10
- package/src/plugins/PropertyPanel/utils.ts +0 -13
- package/src/plugins/RightPanel/index.tsx +0 -30
- package/src/plugins/RightPanel/style.module.scss +0 -16
- package/src/plugins/RightPanel/style.module.scss.d.ts +0 -10
- package/src/plugins/RightPanel/view.tsx +0 -177
- package/src/plugins/VisualPanel/index.tsx +0 -185
- package/src/plugins/VisualPanel/style.module.scss +0 -17
- package/src/plugins/VisualPanelPlus/index.tsx +0 -103
- package/src/plugins/VisualPanelPlus/style.module.scss +0 -20
- package/src/plugins/VisualPanelPlus/style.module.scss.d.ts +0 -10
- package/src/plugins/index.tsx +0 -26
- package/src/stories/Button.jsx +0 -50
- package/src/stories/Button.stories.jsx +0 -40
- package/src/stories/Introduction.stories.mdx +0 -194
- package/src/stories/assets/code-brackets.svg +0 -1
- package/src/stories/assets/colors.svg +0 -1
- package/src/stories/assets/comments.svg +0 -1
- package/src/stories/assets/direction.svg +0 -1
- package/src/stories/assets/flow.svg +0 -1
- package/src/stories/assets/plugin.svg +0 -1
- package/src/stories/assets/repo.svg +0 -1
- package/src/stories/assets/stackalt.svg +0 -1
- package/src/stories/button.css +0 -30
- package/src/stories/plugins/CSSEditor.stories.tsx +0 -75
- package/src/stories/plugins/VisualPanelPlus.stories.tsx +0 -74
- package/src/style.d.ts +0 -2
- package/src/typing.d.ts +0 -9
- package/src/utils/css.ts +0 -88
- package/src/utils/defaultEngineConfig.tsx +0 -55
- package/src/utils/index.ts +0 -12
- package/src/utils/logger.ts +0 -4
- package/src/vite-env.d.ts +0 -1
- package/tsconfig.json +0 -32
- /package/{public → dist}/Engine.module.scss.d.ts +0 -0
- /package/{public → dist}/component/CSSEditor/style.module.scss.d.ts +0 -0
- /package/{public → dist}/component/CSSPropertiesEditor/style.module.scss.d.ts +0 -0
- /package/{public → dist}/component/CSSPropertiesVariableBindEditor/style.module.scss.d.ts +0 -0
- /package/{public → dist}/component/CustomSchemaForm/components/Form/Field/style.module.scss.d.ts +0 -0
- /package/{public → dist}/component/CustomSchemaForm/components/SetterSwitcher/style.module.scss.d.ts +0 -0
- /package/{public → dist}/component/CustomSchemaForm/components/Setters/ArraySetter/style.module.scss.d.ts +0 -0
- /package/{public → dist}/component/CustomSchemaForm/components/Setters/CSSValueSetter/style.module.scss.d.ts +0 -0
- /package/{public → dist}/component/CustomSchemaForm/style.module.scss.d.ts +0 -0
- /package/{public → dist}/component/Workbench/style.module.scss.d.ts +0 -0
- /package/{public → dist}/plugins/AdvancePanel/style.module.scss.d.ts +0 -0
- /package/{public → dist}/plugins/ComponentLibrary/components/DragItem/style.module.scss.d.ts +0 -0
- /package/{public → dist}/plugins/ComponentLibrary/components/ListView/style.module.scss.d.ts +0 -0
- /package/{public → dist}/plugins/ComponentLibrary/style.module.scss.d.ts +0 -0
- /package/{public → dist}/plugins/Designer/components/DefaultSelectToolBar/style.module.scss.d.ts +0 -0
- /package/{public → dist}/plugins/Designer/style.module.scss.d.ts +0 -0
- /package/{public → dist}/plugins/GlobalStatePanel/style.module.scss.d.ts +0 -0
- /package/{public → dist}/plugins/OutlineTree/components/TreeView/style.module.scss.d.ts +0 -0
- /package/{public → dist}/plugins/PropertyPanel/style.module.scss.d.ts +0 -0
- /package/{public → dist}/plugins/RightPanel/style.module.scss.d.ts +0 -0
- /package/{public → dist}/plugins/VisualPanelPlus/style.module.scss.d.ts +0 -0
package/index.html
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
<!DOCTYPE html>
|
|
2
|
-
<html lang="en">
|
|
3
|
-
|
|
4
|
-
<head>
|
|
5
|
-
<meta charset="UTF-8" />
|
|
6
|
-
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
|
|
7
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
8
|
-
<title>Chameleon Low-Code Engine</title>
|
|
9
|
-
</head>
|
|
10
|
-
|
|
11
|
-
<body>
|
|
12
|
-
<div id="root"></div>
|
|
13
|
-
<script type="module" src="/src/_dev_/index.tsx"></script>
|
|
14
|
-
</body>
|
|
15
|
-
|
|
16
|
-
</html>
|
package/jest.config.js
DELETED
|
@@ -1,196 +0,0 @@
|
|
|
1
|
-
/* eslint-disable no-undef */
|
|
2
|
-
/*
|
|
3
|
-
* For a detailed explanation regarding each configuration property, visit:
|
|
4
|
-
* https://jestjs.io/docs/configuration
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
module.exports = {
|
|
8
|
-
// All imported modules in your tests should be mocked automatically
|
|
9
|
-
// automock: false,
|
|
10
|
-
|
|
11
|
-
// Stop running tests after `n` failures
|
|
12
|
-
// bail: 0,
|
|
13
|
-
|
|
14
|
-
// The directory where Jest should store its cached dependency information
|
|
15
|
-
// cacheDirectory: "/private/var/folders/l9/th_r5d_12wxdj16859_mctjw0000gn/T/jest_dx",
|
|
16
|
-
|
|
17
|
-
// Automatically clear mock calls, instances, contexts and results before every test
|
|
18
|
-
// clearMocks: false,
|
|
19
|
-
|
|
20
|
-
// Indicates whether the coverage information should be collected while executing the test
|
|
21
|
-
// collectCoverage: false,
|
|
22
|
-
|
|
23
|
-
// An array of glob patterns indicating a set of files for which coverage information should be collected
|
|
24
|
-
// collectCoverageFrom: undefined,
|
|
25
|
-
|
|
26
|
-
// The directory where Jest should output its coverage files
|
|
27
|
-
// coverageDirectory: undefined,
|
|
28
|
-
|
|
29
|
-
// An array of regexp pattern strings used to skip coverage collection
|
|
30
|
-
// coveragePathIgnorePatterns: [
|
|
31
|
-
// "/node_modules/"
|
|
32
|
-
// ],
|
|
33
|
-
|
|
34
|
-
// Indicates which provider should be used to instrument code for coverage
|
|
35
|
-
// coverageProvider: "babel",
|
|
36
|
-
|
|
37
|
-
// A list of reporter names that Jest uses when writing coverage reports
|
|
38
|
-
// coverageReporters: [
|
|
39
|
-
// "json",
|
|
40
|
-
// "text",
|
|
41
|
-
// "lcov",
|
|
42
|
-
// "clover"
|
|
43
|
-
// ],
|
|
44
|
-
|
|
45
|
-
// An object that configures minimum threshold enforcement for coverage results
|
|
46
|
-
// coverageThreshold: undefined,
|
|
47
|
-
|
|
48
|
-
// A path to a custom dependency extractor
|
|
49
|
-
// dependencyExtractor: undefined,
|
|
50
|
-
|
|
51
|
-
// Make calling deprecated APIs throw helpful error messages
|
|
52
|
-
// errorOnDeprecated: false,
|
|
53
|
-
|
|
54
|
-
// The default configuration for fake timers
|
|
55
|
-
// fakeTimers: {
|
|
56
|
-
// "enableGlobally": false
|
|
57
|
-
// },
|
|
58
|
-
|
|
59
|
-
// Force coverage collection from ignored files using an array of glob patterns
|
|
60
|
-
// forceCoverageMatch: [],
|
|
61
|
-
|
|
62
|
-
// A path to a module which exports an async function that is triggered once before all test suites
|
|
63
|
-
// globalSetup: undefined,
|
|
64
|
-
|
|
65
|
-
// A path to a module which exports an async function that is triggered once after all test suites
|
|
66
|
-
// globalTeardown: undefined,
|
|
67
|
-
|
|
68
|
-
// A set of global variables that need to be available in all test environments
|
|
69
|
-
// globals: {},
|
|
70
|
-
|
|
71
|
-
// The maximum amount of workers used to run your tests. Can be specified as % or a number. E.g. maxWorkers: 10% will use 10% of your CPU amount + 1 as the maximum worker number. maxWorkers: 2 will use a maximum of 2 workers.
|
|
72
|
-
// maxWorkers: "50%",
|
|
73
|
-
|
|
74
|
-
// An array of directory names to be searched recursively up from the requiring module's location
|
|
75
|
-
// moduleDirectories: [
|
|
76
|
-
// "node_modules"
|
|
77
|
-
// ],
|
|
78
|
-
|
|
79
|
-
// An array of file extensions your modules use
|
|
80
|
-
// moduleFileExtensions: [
|
|
81
|
-
// "js",
|
|
82
|
-
// "mjs",
|
|
83
|
-
// "cjs",
|
|
84
|
-
// "jsx",
|
|
85
|
-
// "ts",
|
|
86
|
-
// "tsx",
|
|
87
|
-
// "json",
|
|
88
|
-
// "node"
|
|
89
|
-
// ],
|
|
90
|
-
|
|
91
|
-
// A map from regular expressions to module names or to arrays of module names that allow to stub out resources with a single module
|
|
92
|
-
// moduleNameMapper: {},
|
|
93
|
-
|
|
94
|
-
// An array of regexp pattern strings, matched against all module paths before considered 'visible' to the module loader
|
|
95
|
-
// modulePathIgnorePatterns: [],
|
|
96
|
-
|
|
97
|
-
// Activates notifications for test results
|
|
98
|
-
// notify: false,
|
|
99
|
-
|
|
100
|
-
// An enum that specifies notification mode. Requires { notify: true }
|
|
101
|
-
// notifyMode: "failure-change",
|
|
102
|
-
|
|
103
|
-
// A preset that is used as a base for Jest's configuration
|
|
104
|
-
preset: 'ts-jest',
|
|
105
|
-
|
|
106
|
-
// Run tests from one or more projects
|
|
107
|
-
// projects: undefined,
|
|
108
|
-
|
|
109
|
-
// Use this configuration option to add custom reporters to Jest
|
|
110
|
-
// reporters: undefined,
|
|
111
|
-
|
|
112
|
-
// Automatically reset mock state before every test
|
|
113
|
-
// resetMocks: false,
|
|
114
|
-
|
|
115
|
-
// Reset the module registry before running each individual test
|
|
116
|
-
// resetModules: false,
|
|
117
|
-
|
|
118
|
-
// A path to a custom resolver
|
|
119
|
-
// resolver: undefined,
|
|
120
|
-
|
|
121
|
-
// Automatically restore mock state and implementation before every test
|
|
122
|
-
// restoreMocks: false,
|
|
123
|
-
|
|
124
|
-
// The root directory that Jest should scan for tests and modules within
|
|
125
|
-
// rootDir: undefined,
|
|
126
|
-
|
|
127
|
-
// A list of paths to directories that Jest should use to search for files in
|
|
128
|
-
// roots: [
|
|
129
|
-
// "<rootDir>"
|
|
130
|
-
// ],
|
|
131
|
-
|
|
132
|
-
// Allows you to use a custom runner instead of Jest's default test runner
|
|
133
|
-
// runner: "jest-runner",
|
|
134
|
-
|
|
135
|
-
// The paths to modules that run some code to configure or set up the testing environment before each test
|
|
136
|
-
// setupFiles: [],
|
|
137
|
-
|
|
138
|
-
// A list of paths to modules that run some code to configure or set up the testing framework before each test
|
|
139
|
-
// setupFilesAfterEnv: [],
|
|
140
|
-
|
|
141
|
-
// The number of seconds after which a test is considered as slow and reported as such in the results.
|
|
142
|
-
// slowTestThreshold: 5,
|
|
143
|
-
|
|
144
|
-
// A list of paths to snapshot serializer modules Jest should use for snapshot testing
|
|
145
|
-
// snapshotSerializers: [],
|
|
146
|
-
|
|
147
|
-
// The test environment that will be used for testing
|
|
148
|
-
testEnvironment: 'jsdom',
|
|
149
|
-
|
|
150
|
-
// Options that will be passed to the testEnvironment
|
|
151
|
-
// testEnvironmentOptions: {},
|
|
152
|
-
|
|
153
|
-
// Adds a location field to test results
|
|
154
|
-
// testLocationInResults: false,
|
|
155
|
-
|
|
156
|
-
// The glob patterns Jest uses to detect test files
|
|
157
|
-
// testMatch: [
|
|
158
|
-
// "**/__tests__/**/*.[jt]s?(x)",
|
|
159
|
-
// "**/?(*.)+(spec|test).[tj]s?(x)"
|
|
160
|
-
// ],
|
|
161
|
-
|
|
162
|
-
// An array of regexp pattern strings that are matched against all test paths, matched tests are skipped
|
|
163
|
-
// testPathIgnorePatterns: [
|
|
164
|
-
// "/node_modules/"
|
|
165
|
-
// ],
|
|
166
|
-
|
|
167
|
-
// The regexp pattern or array of patterns that Jest uses to detect test files
|
|
168
|
-
// testRegex: [],
|
|
169
|
-
|
|
170
|
-
// This option allows the use of a custom results processor
|
|
171
|
-
// testResultsProcessor: undefined,
|
|
172
|
-
|
|
173
|
-
// This option allows use of a custom test runner
|
|
174
|
-
// testRunner: "jest-circus/runner",
|
|
175
|
-
|
|
176
|
-
// A map from regular expressions to paths to transformers
|
|
177
|
-
// transform: undefined,
|
|
178
|
-
|
|
179
|
-
// An array of regexp pattern strings that are matched against all source file paths, matched files will skip transformation
|
|
180
|
-
// transformIgnorePatterns: [
|
|
181
|
-
// "/node_modules/",
|
|
182
|
-
// "\\.pnp\\.[^\\/]+$"
|
|
183
|
-
// ],
|
|
184
|
-
|
|
185
|
-
// An array of regexp pattern strings that are matched against all modules before the module loader will automatically return a mock for them
|
|
186
|
-
// unmockedModulePathPatterns: undefined,
|
|
187
|
-
|
|
188
|
-
// Indicates whether each individual test should be reported during the run
|
|
189
|
-
// verbose: undefined,
|
|
190
|
-
|
|
191
|
-
// An array of regexp patterns that are matched against all source file paths before re-running tests in watch mode
|
|
192
|
-
// watchPathIgnorePatterns: [],
|
|
193
|
-
|
|
194
|
-
// Whether to use watchman for file crawling
|
|
195
|
-
// watchman: true,
|
|
196
|
-
};
|
package/public/_dev_/render.d.ts
DELETED
package/public/render.umd.js
DELETED
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
(function(x,ot){typeof exports=="object"&&typeof module<"u"?module.exports=ot(require("react"),require("react-dom")):typeof define=="function"&&define.amd?define(["react","react-dom"],ot):(x=typeof globalThis<"u"?globalThis:x||self,x.CRender=ot(x.React,x.ReactDOM))})(this,function(x,ot){"use strict";function Qa(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const Xa=Qa(ot);var xt={},Ka={get exports(){return xt},set exports(e){xt=e}},at={};/**
|
|
2
|
-
* @license React
|
|
3
|
-
* react-jsx-runtime.production.min.js
|
|
4
|
-
*
|
|
5
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
6
|
-
*
|
|
7
|
-
* This source code is licensed under the MIT license found in the
|
|
8
|
-
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var hn;function Za(){if(hn)return at;hn=1;var e=x,t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function i(s,u,l){var f,d={},p=null,v=null;l!==void 0&&(p=""+l),u.key!==void 0&&(p=""+u.key),u.ref!==void 0&&(v=u.ref);for(f in u)n.call(u,f)&&!a.hasOwnProperty(f)&&(d[f]=u[f]);if(s&&s.defaultProps)for(f in u=s.defaultProps,u)d[f]===void 0&&(d[f]=u[f]);return{$$typeof:t,type:s,key:p,ref:v,props:d,_owner:o.current}}return at.Fragment=r,at.jsx=i,at.jsxs=i,at}var it={};/**
|
|
10
|
-
* @license React
|
|
11
|
-
* react-jsx-runtime.development.js
|
|
12
|
-
*
|
|
13
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
14
|
-
*
|
|
15
|
-
* This source code is licensed under the MIT license found in the
|
|
16
|
-
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var vn;function ei(){return vn||(vn=1,{}.NODE_ENV!=="production"&&function(){var e=x,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),s=Symbol.for("react.context"),u=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),v=Symbol.for("react.offscreen"),b=Symbol.iterator,_="@@iterator";function E(c){if(c===null||typeof c!="object")return null;var h=b&&c[b]||c[_];return typeof h=="function"?h:null}var w=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function S(c){{for(var h=arguments.length,y=new Array(h>1?h-1:0),O=1;O<h;O++)y[O-1]=arguments[O];W("error",c,y)}}function W(c,h,y){{var O=w.ReactDebugCurrentFrame,A=O.getStackAddendum();A!==""&&(h+="%s",y=y.concat([A]));var $=y.map(function(T){return String(T)});$.unshift("Warning: "+h),Function.prototype.apply.call(console[c],console,$)}}var D=!1,U=!1,Z=!1,J=!1,N=!1,ae;ae=Symbol.for("react.module.reference");function le(c){return!!(typeof c=="string"||typeof c=="function"||c===n||c===a||N||c===o||c===l||c===f||J||c===v||D||U||Z||typeof c=="object"&&c!==null&&(c.$$typeof===p||c.$$typeof===d||c.$$typeof===i||c.$$typeof===s||c.$$typeof===u||c.$$typeof===ae||c.getModuleId!==void 0))}function Ct(c,h,y){var O=c.displayName;if(O)return O;var A=h.displayName||h.name||"";return A!==""?y+"("+A+")":y}function Ht(c){return c.displayName||"Context"}function ee(c){if(c==null)return null;if(typeof c.tag=="number"&&S("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof c=="function")return c.displayName||c.name||null;if(typeof c=="string")return c;switch(c){case n:return"Fragment";case r:return"Portal";case a:return"Profiler";case o:return"StrictMode";case l:return"Suspense";case f:return"SuspenseList"}if(typeof c=="object")switch(c.$$typeof){case s:var h=c;return Ht(h)+".Consumer";case i:var y=c;return Ht(y._context)+".Provider";case u:return Ct(c,c.render,"ForwardRef");case d:var O=c.displayName||null;return O!==null?O:ee(c.type)||"Memo";case p:{var A=c,$=A._payload,T=A._init;try{return ee(T($))}catch{return null}}}return null}var te=Object.assign,H=0,Yt,Ze,Jt,$e,et,re,_e;function tt(){}tt.__reactDisabledLog=!0;function on(){{if(H===0){Yt=console.log,Ze=console.info,Jt=console.warn,$e=console.error,et=console.group,re=console.groupCollapsed,_e=console.groupEnd;var c={configurable:!0,enumerable:!0,value:tt,writable:!0};Object.defineProperties(console,{info:c,log:c,warn:c,error:c,group:c,groupCollapsed:c,groupEnd:c})}H++}}function Ny(){{if(H--,H===0){var c={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:te({},c,{value:Yt}),info:te({},c,{value:Ze}),warn:te({},c,{value:Jt}),error:te({},c,{value:$e}),group:te({},c,{value:et}),groupCollapsed:te({},c,{value:re}),groupEnd:te({},c,{value:_e})})}H<0&&S("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var an=w.ReactCurrentDispatcher,sn;function qt(c,h,y){{if(sn===void 0)try{throw Error()}catch(A){var O=A.stack.trim().match(/\n( *(at )?)/);sn=O&&O[1]||""}return`
|
|
18
|
-
`+sn+c}}var cn=!1,Qt;{var Ty=typeof WeakMap=="function"?WeakMap:Map;Qt=new Ty}function ka(c,h){if(!c||cn)return"";{var y=Qt.get(c);if(y!==void 0)return y}var O;cn=!0;var A=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var $;$=an.current,an.current=null,on();try{if(h){var T=function(){throw Error()};if(Object.defineProperty(T.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(T,[])}catch(je){O=je}Reflect.construct(c,[],T)}else{try{T.call()}catch(je){O=je}c.call(T.prototype)}}else{try{throw Error()}catch(je){O=je}c()}}catch(je){if(je&&O&&typeof je.stack=="string"){for(var R=je.stack.split(`
|
|
19
|
-
`),q=O.stack.split(`
|
|
20
|
-
`),z=R.length-1,V=q.length-1;z>=1&&V>=0&&R[z]!==q[V];)V--;for(;z>=1&&V>=0;z--,V--)if(R[z]!==q[V]){if(z!==1||V!==1)do if(z--,V--,V<0||R[z]!==q[V]){var ie=`
|
|
21
|
-
`+R[z].replace(" at new "," at ");return c.displayName&&ie.includes("<anonymous>")&&(ie=ie.replace("<anonymous>",c.displayName)),typeof c=="function"&&Qt.set(c,ie),ie}while(z>=1&&V>=0);break}}}finally{cn=!1,an.current=$,Ny(),Error.prepareStackTrace=A}var nt=c?c.displayName||c.name:"",qa=nt?qt(nt):"";return typeof c=="function"&&Qt.set(c,qa),qa}function Ay(c,h,y){return ka(c,!1)}function My(c){var h=c.prototype;return!!(h&&h.isReactComponent)}function Xt(c,h,y){if(c==null)return"";if(typeof c=="function")return ka(c,My(c));if(typeof c=="string")return qt(c);switch(c){case l:return qt("Suspense");case f:return qt("SuspenseList")}if(typeof c=="object")switch(c.$$typeof){case u:return Ay(c.render);case d:return Xt(c.type,h,y);case p:{var O=c,A=O._payload,$=O._init;try{return Xt($(A),h,y)}catch{}}}return""}var Kt=Object.prototype.hasOwnProperty,Ia={},Fa=w.ReactDebugCurrentFrame;function Zt(c){if(c){var h=c._owner,y=Xt(c.type,c._source,h?h.type:null);Fa.setExtraStackFrame(y)}else Fa.setExtraStackFrame(null)}function $y(c,h,y,O,A){{var $=Function.call.bind(Kt);for(var T in c)if($(c,T)){var R=void 0;try{if(typeof c[T]!="function"){var q=Error((O||"React class")+": "+y+" type `"+T+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof c[T]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw q.name="Invariant Violation",q}R=c[T](h,T,O,y,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(z){R=z}R&&!(R instanceof Error)&&(Zt(A),S("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",O||"React class",y,T,typeof R),Zt(null)),R instanceof Error&&!(R.message in Ia)&&(Ia[R.message]=!0,Zt(A),S("Failed %s type: %s",y,R.message),Zt(null))}}}var Py=Array.isArray;function un(c){return Py(c)}function Dy(c){{var h=typeof Symbol=="function"&&Symbol.toStringTag,y=h&&c[Symbol.toStringTag]||c.constructor.name||"Object";return y}}function ky(c){try{return La(c),!1}catch{return!0}}function La(c){return""+c}function Ba(c){if(ky(c))return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Dy(c)),La(c)}var wt=w.ReactCurrentOwner,Iy={key:!0,ref:!0,__self:!0,__source:!0},Ua,za,ln;ln={};function Fy(c){if(Kt.call(c,"ref")){var h=Object.getOwnPropertyDescriptor(c,"ref").get;if(h&&h.isReactWarning)return!1}return c.ref!==void 0}function Ly(c){if(Kt.call(c,"key")){var h=Object.getOwnPropertyDescriptor(c,"key").get;if(h&&h.isReactWarning)return!1}return c.key!==void 0}function By(c,h){if(typeof c.ref=="string"&&wt.current&&h&&wt.current.stateNode!==h){var y=ee(wt.current.type);ln[y]||(S('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',ee(wt.current.type),c.ref),ln[y]=!0)}}function Uy(c,h){{var y=function(){Ua||(Ua=!0,S("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",h))};y.isReactWarning=!0,Object.defineProperty(c,"key",{get:y,configurable:!0})}}function zy(c,h){{var y=function(){za||(za=!0,S("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",h))};y.isReactWarning=!0,Object.defineProperty(c,"ref",{get:y,configurable:!0})}}var Vy=function(c,h,y,O,A,$,T){var R={$$typeof:t,type:c,key:h,ref:y,props:T,_owner:$};return R._store={},Object.defineProperty(R._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(R,"_self",{configurable:!1,enumerable:!1,writable:!1,value:O}),Object.defineProperty(R,"_source",{configurable:!1,enumerable:!1,writable:!1,value:A}),Object.freeze&&(Object.freeze(R.props),Object.freeze(R)),R};function Gy(c,h,y,O,A){{var $,T={},R=null,q=null;y!==void 0&&(Ba(y),R=""+y),Ly(h)&&(Ba(h.key),R=""+h.key),Fy(h)&&(q=h.ref,By(h,A));for($ in h)Kt.call(h,$)&&!Iy.hasOwnProperty($)&&(T[$]=h[$]);if(c&&c.defaultProps){var z=c.defaultProps;for($ in z)T[$]===void 0&&(T[$]=z[$])}if(R||q){var V=typeof c=="function"?c.displayName||c.name||"Unknown":c;R&&Uy(T,V),q&&zy(T,V)}return Vy(c,R,q,A,O,wt.current,T)}}var fn=w.ReactCurrentOwner,Va=w.ReactDebugCurrentFrame;function rt(c){if(c){var h=c._owner,y=Xt(c.type,c._source,h?h.type:null);Va.setExtraStackFrame(y)}else Va.setExtraStackFrame(null)}var dn;dn=!1;function pn(c){return typeof c=="object"&&c!==null&&c.$$typeof===t}function Ga(){{if(fn.current){var c=ee(fn.current.type);if(c)return`
|
|
22
|
-
|
|
23
|
-
Check the render method of \``+c+"`."}return""}}function Wy(c){{if(c!==void 0){var h=c.fileName.replace(/^.*[\\\/]/,""),y=c.lineNumber;return`
|
|
24
|
-
|
|
25
|
-
Check your code at `+h+":"+y+"."}return""}}var Wa={};function Hy(c){{var h=Ga();if(!h){var y=typeof c=="string"?c:c.displayName||c.name;y&&(h=`
|
|
26
|
-
|
|
27
|
-
Check the top-level render call using <`+y+">.")}return h}}function Ha(c,h){{if(!c._store||c._store.validated||c.key!=null)return;c._store.validated=!0;var y=Hy(h);if(Wa[y])return;Wa[y]=!0;var O="";c&&c._owner&&c._owner!==fn.current&&(O=" It was passed a child from "+ee(c._owner.type)+"."),rt(c),S('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',y,O),rt(null)}}function Ya(c,h){{if(typeof c!="object")return;if(un(c))for(var y=0;y<c.length;y++){var O=c[y];pn(O)&&Ha(O,h)}else if(pn(c))c._store&&(c._store.validated=!0);else if(c){var A=E(c);if(typeof A=="function"&&A!==c.entries)for(var $=A.call(c),T;!(T=$.next()).done;)pn(T.value)&&Ha(T.value,h)}}}function Yy(c){{var h=c.type;if(h==null||typeof h=="string")return;var y;if(typeof h=="function")y=h.propTypes;else if(typeof h=="object"&&(h.$$typeof===u||h.$$typeof===d))y=h.propTypes;else return;if(y){var O=ee(h);$y(y,c.props,"prop",O,c)}else if(h.PropTypes!==void 0&&!dn){dn=!0;var A=ee(h);S("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",A||"Unknown")}typeof h.getDefaultProps=="function"&&!h.getDefaultProps.isReactClassApproved&&S("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Jy(c){{for(var h=Object.keys(c.props),y=0;y<h.length;y++){var O=h[y];if(O!=="children"&&O!=="key"){rt(c),S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",O),rt(null);break}}c.ref!==null&&(rt(c),S("Invalid attribute `ref` supplied to `React.Fragment`."),rt(null))}}function Ja(c,h,y,O,A,$){{var T=le(c);if(!T){var R="";(c===void 0||typeof c=="object"&&c!==null&&Object.keys(c).length===0)&&(R+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var q=Wy(A);q?R+=q:R+=Ga();var z;c===null?z="null":un(c)?z="array":c!==void 0&&c.$$typeof===t?(z="<"+(ee(c.type)||"Unknown")+" />",R=" Did you accidentally export a JSX literal instead of a component?"):z=typeof c,S("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",z,R)}var V=Gy(c,h,y,A,$);if(V==null)return V;if(T){var ie=h.children;if(ie!==void 0)if(O)if(un(ie)){for(var nt=0;nt<ie.length;nt++)Ya(ie[nt],c);Object.freeze&&Object.freeze(ie)}else S("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Ya(ie,c)}return c===n?Jy(V):Yy(V),V}}function qy(c,h,y){return Ja(c,h,y,!0)}function Qy(c,h,y){return Ja(c,h,y,!1)}var Xy=Qy,Ky=qy;it.Fragment=n,it.jsx=Xy,it.jsxs=Ky}()),it}(function(e){({}).NODE_ENV==="production"?e.exports=Za():e.exports=ei()})(Ka);const Pe=xt.jsx,yn=xt.jsxs;var ti=Object.defineProperty,ri=(e,t,r)=>t in e?ti(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,j=(e,t,r)=>(ri(e,typeof t!="symbol"?t+"":t,r),r);const ni=e=>()=>{console.warn(`${e} need to be implement getComponent`)},oi=["customPageRootRender"],mn=["pageRender","render","convertModelToComponent","getComponent","getContext","getUtils","getDataLink","createDataLink","transformProps","transformData","transformGlobalData","errorCatch","clear"],gn=e=>[...mn,...oi].reduce((t,r)=>{var n;return e!=null&&e[r]?t[r]=(n=e[r])==null?void 0:n.bind(e):mn.includes(r)&&(t[r]=ni),t},{});var ai=Object.defineProperty,ii=(e,t,r)=>t in e?ai(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,C=(e,t,r)=>(ii(e,typeof t!="symbol"?t+"":t,r),r),si=typeof global=="object"&&global&&global.Object===Object&&global;const bn=si;var ci=typeof self=="object"&&self&&self.Object===Object&&self,ui=bn||ci||Function("return this")();const fe=ui;var li=fe.Symbol;const ne=li;var _n=Object.prototype,fi=_n.hasOwnProperty,di=_n.toString,st=ne?ne.toStringTag:void 0;function pi(e){var t=fi.call(e,st),r=e[st];try{e[st]=void 0;var n=!0}catch{}var o=di.call(e);return n&&(t?e[st]=r:delete e[st]),o}var hi=Object.prototype,vi=hi.toString;function yi(e){return vi.call(e)}var mi="[object Null]",gi="[object Undefined]",jn=ne?ne.toStringTag:void 0;function Se(e){return e==null?e===void 0?gi:mi:jn&&jn in Object(e)?pi(e):yi(e)}function de(e){return e!=null&&typeof e=="object"}var bi="[object Symbol]";function er(e){return typeof e=="symbol"||de(e)&&Se(e)==bi}function tr(e,t){for(var r=-1,n=e==null?0:e.length,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}var _i=Array.isArray;const L=_i;var ji=1/0,En=ne?ne.prototype:void 0,On=En?En.toString:void 0;function Sn(e){if(typeof e=="string")return e;if(L(e))return tr(e,Sn)+"";if(er(e))return On?On.call(e):"";var t=e+"";return t=="0"&&1/e==-ji?"-0":t}function se(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}function rr(e){return e}var Ei="[object AsyncFunction]",Oi="[object Function]",Si="[object GeneratorFunction]",Ci="[object Proxy]";function nr(e){if(!se(e))return!1;var t=Se(e);return t==Oi||t==Si||t==Ei||t==Ci}var wi=fe["__core-js_shared__"];const or=wi;var Cn=function(){var e=/[^.]+$/.exec(or&&or.keys&&or.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function xi(e){return!!Cn&&Cn in e}var Ri=Function.prototype,Ni=Ri.toString;function Ce(e){if(e!=null){try{return Ni.call(e)}catch{}try{return e+""}catch{}}return""}var Ti=/[\\^$.*+?()[\]{}|]/g,Ai=/^\[object .+?Constructor\]$/,Mi=Function.prototype,$i=Object.prototype,Pi=Mi.toString,Di=$i.hasOwnProperty,ki=RegExp("^"+Pi.call(Di).replace(Ti,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Ii(e){if(!se(e)||xi(e))return!1;var t=nr(e)?ki:Ai;return t.test(Ce(e))}function Fi(e,t){return e==null?void 0:e[t]}function we(e,t){var r=Fi(e,t);return Ii(r)?r:void 0}var Li=we(fe,"WeakMap");const ar=Li;var wn=Object.create,Bi=function(){function e(){}return function(t){if(!se(t))return{};if(wn)return wn(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();const Ui=Bi;function zi(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function Vi(){}function xn(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var Gi=800,Wi=16,Hi=Date.now;function Yi(e){var t=0,r=0;return function(){var n=Hi(),o=Wi-(n-r);if(r=n,o>0){if(++t>=Gi)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function Ji(e){return function(){return e}}var qi=function(){try{var e=we(Object,"defineProperty");return e({},"",{}),e}catch{}}();const Rt=qi;var Qi=Rt?function(e,t){return Rt(e,"toString",{configurable:!0,enumerable:!1,value:Ji(t),writable:!0})}:rr,Xi=Yi(Qi);const Rn=Xi;function Ki(e,t){for(var r=-1,n=e==null?0:e.length;++r<n&&t(e[r],r,e)!==!1;);return e}function Zi(e,t,r,n){for(var o=e.length,a=r+(n?1:-1);n?a--:++a<o;)if(t(e[a],a,e))return a;return-1}function es(e){return e!==e}function ts(e,t,r){for(var n=r-1,o=e.length;++n<o;)if(e[n]===t)return n;return-1}function rs(e,t,r){return t===t?ts(e,t,r):Zi(e,es,r)}function ns(e,t){var r=e==null?0:e.length;return!!r&&rs(e,t,0)>-1}var os=9007199254740991,as=/^(?:0|[1-9]\d*)$/;function Nt(e,t){var r=typeof e;return t=t??os,!!t&&(r=="number"||r!="symbol"&&as.test(e))&&e>-1&&e%1==0&&e<t}function ir(e,t,r){t=="__proto__"&&Rt?Rt(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function ct(e,t){return e===t||e!==e&&t!==t}var is=Object.prototype,ss=is.hasOwnProperty;function sr(e,t,r){var n=e[t];(!(ss.call(e,t)&&ct(n,r))||r===void 0&&!(t in e))&&ir(e,t,r)}function De(e,t,r,n){var o=!r;r||(r={});for(var a=-1,i=t.length;++a<i;){var s=t[a],u=n?n(r[s],e[s],s,r,e):void 0;u===void 0&&(u=e[s]),o?ir(r,s,u):sr(r,s,u)}return r}var Nn=Math.max;function Tn(e,t,r){return t=Nn(t===void 0?e.length-1:t,0),function(){for(var n=arguments,o=-1,a=Nn(n.length-t,0),i=Array(a);++o<a;)i[o]=n[t+o];o=-1;for(var s=Array(t+1);++o<t;)s[o]=n[o];return s[t]=r(i),zi(e,this,s)}}function An(e,t){return Rn(Tn(e,t,rr),e+"")}var cs=9007199254740991;function cr(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=cs}function Tt(e){return e!=null&&cr(e.length)&&!nr(e)}function us(e,t,r){if(!se(r))return!1;var n=typeof t;return(n=="number"?Tt(r)&&Nt(t,r.length):n=="string"&&t in r)?ct(r[t],e):!1}function ls(e){return An(function(t,r){var n=-1,o=r.length,a=o>1?r[o-1]:void 0,i=o>2?r[2]:void 0;for(a=e.length>3&&typeof a=="function"?(o--,a):void 0,i&&us(r[0],r[1],i)&&(a=o<3?void 0:a,o=1),t=Object(t);++n<o;){var s=r[n];s&&e(t,s,n,a)}return t})}var fs=Object.prototype;function ur(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||fs;return e===r}function ds(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var ps="[object Arguments]";function Mn(e){return de(e)&&Se(e)==ps}var $n=Object.prototype,hs=$n.hasOwnProperty,vs=$n.propertyIsEnumerable,ys=Mn(function(){return arguments}())?Mn:function(e){return de(e)&&hs.call(e,"callee")&&!vs.call(e,"callee")};const ut=ys;function ms(){return!1}var Pn=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Dn=Pn&&typeof module=="object"&&module&&!module.nodeType&&module,gs=Dn&&Dn.exports===Pn,kn=gs?fe.Buffer:void 0,bs=kn?kn.isBuffer:void 0,_s=bs||ms;const lt=_s;var js="[object Arguments]",Es="[object Array]",Os="[object Boolean]",Ss="[object Date]",Cs="[object Error]",ws="[object Function]",xs="[object Map]",Rs="[object Number]",Ns="[object Object]",Ts="[object RegExp]",As="[object Set]",Ms="[object String]",$s="[object WeakMap]",Ps="[object ArrayBuffer]",Ds="[object DataView]",ks="[object Float32Array]",Is="[object Float64Array]",Fs="[object Int8Array]",Ls="[object Int16Array]",Bs="[object Int32Array]",Us="[object Uint8Array]",zs="[object Uint8ClampedArray]",Vs="[object Uint16Array]",Gs="[object Uint32Array]",k={};k[ks]=k[Is]=k[Fs]=k[Ls]=k[Bs]=k[Us]=k[zs]=k[Vs]=k[Gs]=!0,k[js]=k[Es]=k[Ps]=k[Os]=k[Ds]=k[Ss]=k[Cs]=k[ws]=k[xs]=k[Rs]=k[Ns]=k[Ts]=k[As]=k[Ms]=k[$s]=!1;function Ws(e){return de(e)&&cr(e.length)&&!!k[Se(e)]}function lr(e){return function(t){return e(t)}}var In=typeof exports=="object"&&exports&&!exports.nodeType&&exports,ft=In&&typeof module=="object"&&module&&!module.nodeType&&module,Hs=ft&&ft.exports===In,fr=Hs&&bn.process,Ys=function(){try{var e=ft&&ft.require&&ft.require("util").types;return e||fr&&fr.binding&&fr.binding("util")}catch{}}();const ke=Ys;var Fn=ke&&ke.isTypedArray,Js=Fn?lr(Fn):Ws;const dr=Js;var qs=Object.prototype,Qs=qs.hasOwnProperty;function Ln(e,t){var r=L(e),n=!r&&ut(e),o=!r&&!n&<(e),a=!r&&!n&&!o&&dr(e),i=r||n||o||a,s=i?ds(e.length,String):[],u=s.length;for(var l in e)(t||Qs.call(e,l))&&!(i&&(l=="length"||o&&(l=="offset"||l=="parent")||a&&(l=="buffer"||l=="byteLength"||l=="byteOffset")||Nt(l,u)))&&s.push(l);return s}function Bn(e,t){return function(r){return e(t(r))}}var Xs=Bn(Object.keys,Object);const Ks=Xs;var Zs=Object.prototype,ec=Zs.hasOwnProperty;function tc(e){if(!ur(e))return Ks(e);var t=[];for(var r in Object(e))ec.call(e,r)&&r!="constructor"&&t.push(r);return t}function At(e){return Tt(e)?Ln(e):tc(e)}function rc(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var nc=Object.prototype,oc=nc.hasOwnProperty;function ac(e){if(!se(e))return rc(e);var t=ur(e),r=[];for(var n in e)n=="constructor"&&(t||!oc.call(e,n))||r.push(n);return r}function dt(e){return Tt(e)?Ln(e,!0):ac(e)}var ic=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,sc=/^\w*$/;function pr(e,t){if(L(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||er(e)?!0:sc.test(e)||!ic.test(e)||t!=null&&e in Object(t)}var cc=we(Object,"create");const pt=cc;function uc(){this.__data__=pt?pt(null):{},this.size=0}function lc(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var fc="__lodash_hash_undefined__",dc=Object.prototype,pc=dc.hasOwnProperty;function hc(e){var t=this.__data__;if(pt){var r=t[e];return r===fc?void 0:r}return pc.call(t,e)?t[e]:void 0}var vc=Object.prototype,yc=vc.hasOwnProperty;function mc(e){var t=this.__data__;return pt?t[e]!==void 0:yc.call(t,e)}var gc="__lodash_hash_undefined__";function bc(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=pt&&t===void 0?gc:t,this}function xe(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}xe.prototype.clear=uc,xe.prototype.delete=lc,xe.prototype.get=hc,xe.prototype.has=mc,xe.prototype.set=bc;function _c(){this.__data__=[],this.size=0}function Mt(e,t){for(var r=e.length;r--;)if(ct(e[r][0],t))return r;return-1}var jc=Array.prototype,Ec=jc.splice;function Oc(e){var t=this.__data__,r=Mt(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():Ec.call(t,r,1),--this.size,!0}function Sc(e){var t=this.__data__,r=Mt(t,e);return r<0?void 0:t[r][1]}function Cc(e){return Mt(this.__data__,e)>-1}function wc(e,t){var r=this.__data__,n=Mt(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}function ve(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}ve.prototype.clear=_c,ve.prototype.delete=Oc,ve.prototype.get=Sc,ve.prototype.has=Cc,ve.prototype.set=wc;var xc=we(fe,"Map");const ht=xc;function Rc(){this.size=0,this.__data__={hash:new xe,map:new(ht||ve),string:new xe}}function Nc(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function $t(e,t){var r=e.__data__;return Nc(t)?r[typeof t=="string"?"string":"hash"]:r.map}function Tc(e){var t=$t(this,e).delete(e);return this.size-=t?1:0,t}function Ac(e){return $t(this,e).get(e)}function Mc(e){return $t(this,e).has(e)}function $c(e,t){var r=$t(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}function ye(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}ye.prototype.clear=Rc,ye.prototype.delete=Tc,ye.prototype.get=Ac,ye.prototype.has=Mc,ye.prototype.set=$c;var Pc="Expected a function";function hr(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(Pc);var r=function(){var n=arguments,o=t?t.apply(this,n):n[0],a=r.cache;if(a.has(o))return a.get(o);var i=e.apply(this,n);return r.cache=a.set(o,i)||a,i};return r.cache=new(hr.Cache||ye),r}hr.Cache=ye;var Dc=500;function kc(e){var t=hr(e,function(n){return r.size===Dc&&r.clear(),n}),r=t.cache;return t}var Ic=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Fc=/\\(\\)?/g,Lc=kc(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(Ic,function(r,n,o,a){t.push(o?a.replace(Fc,"$1"):n||r)}),t});const Bc=Lc;function Uc(e){return e==null?"":Sn(e)}function Ie(e,t){return L(e)?e:pr(e,t)?[e]:Bc(Uc(e))}var zc=1/0;function Fe(e){if(typeof e=="string"||er(e))return e;var t=e+"";return t=="0"&&1/e==-zc?"-0":t}function Pt(e,t){t=Ie(t,e);for(var r=0,n=t.length;e!=null&&r<n;)e=e[Fe(t[r++])];return r&&r==n?e:void 0}function Un(e,t,r){var n=e==null?void 0:Pt(e,t);return n===void 0?r:n}function vr(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}var zn=ne?ne.isConcatSpreadable:void 0;function Vc(e){return L(e)||ut(e)||!!(zn&&e&&e[zn])}function yr(e,t,r,n,o){var a=-1,i=e.length;for(r||(r=Vc),o||(o=[]);++a<i;){var s=e[a];t>0&&r(s)?t>1?yr(s,t-1,r,n,o):vr(o,s):n||(o[o.length]=s)}return o}function Gc(e){var t=e==null?0:e.length;return t?yr(e,1):[]}function Wc(e){return Rn(Tn(e,void 0,Gc),e+"")}var Hc=Bn(Object.getPrototypeOf,Object);const mr=Hc;var Yc="[object Object]",Jc=Function.prototype,qc=Object.prototype,Vn=Jc.toString,Qc=qc.hasOwnProperty,Xc=Vn.call(Object);function Q(e){if(!de(e)||Se(e)!=Yc)return!1;var t=mr(e);if(t===null)return!0;var r=Qc.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&Vn.call(r)==Xc}function Kc(e,t,r){var n=-1,o=e.length;t<0&&(t=-t>o?0:o+t),r=r>o?o:r,r<0&&(r+=o),o=t>r?0:r-t>>>0,t>>>=0;for(var a=Array(o);++n<o;)a[n]=e[n+t];return a}function Zc(){this.__data__=new ve,this.size=0}function eu(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function tu(e){return this.__data__.get(e)}function ru(e){return this.__data__.has(e)}var nu=200;function ou(e,t){var r=this.__data__;if(r instanceof ve){var n=r.__data__;if(!ht||n.length<nu-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new ye(n)}return r.set(e,t),this.size=r.size,this}function ce(e){var t=this.__data__=new ve(e);this.size=t.size}ce.prototype.clear=Zc,ce.prototype.delete=eu,ce.prototype.get=tu,ce.prototype.has=ru,ce.prototype.set=ou;function au(e,t){return e&&De(t,At(t),e)}function iu(e,t){return e&&De(t,dt(t),e)}var Gn=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Wn=Gn&&typeof module=="object"&&module&&!module.nodeType&&module,su=Wn&&Wn.exports===Gn,Hn=su?fe.Buffer:void 0,Yn=Hn?Hn.allocUnsafe:void 0;function Jn(e,t){if(t)return e.slice();var r=e.length,n=Yn?Yn(r):new e.constructor(r);return e.copy(n),n}function cu(e,t){for(var r=-1,n=e==null?0:e.length,o=0,a=[];++r<n;){var i=e[r];t(i,r,e)&&(a[o++]=i)}return a}function qn(){return[]}var uu=Object.prototype,lu=uu.propertyIsEnumerable,Qn=Object.getOwnPropertySymbols,fu=Qn?function(e){return e==null?[]:(e=Object(e),cu(Qn(e),function(t){return lu.call(e,t)}))}:qn;const gr=fu;function du(e,t){return De(e,gr(e),t)}var pu=Object.getOwnPropertySymbols,hu=pu?function(e){for(var t=[];e;)vr(t,gr(e)),e=mr(e);return t}:qn;const Xn=hu;function vu(e,t){return De(e,Xn(e),t)}function Kn(e,t,r){var n=t(e);return L(e)?n:vr(n,r(e))}function br(e){return Kn(e,At,gr)}function _r(e){return Kn(e,dt,Xn)}var yu=we(fe,"DataView");const jr=yu;var mu=we(fe,"Promise");const Er=mu;var gu=we(fe,"Set");const Le=gu;var Zn="[object Map]",bu="[object Object]",eo="[object Promise]",to="[object Set]",ro="[object WeakMap]",no="[object DataView]",_u=Ce(jr),ju=Ce(ht),Eu=Ce(Er),Ou=Ce(Le),Su=Ce(ar),Re=Se;(jr&&Re(new jr(new ArrayBuffer(1)))!=no||ht&&Re(new ht)!=Zn||Er&&Re(Er.resolve())!=eo||Le&&Re(new Le)!=to||ar&&Re(new ar)!=ro)&&(Re=function(e){var t=Se(e),r=t==bu?e.constructor:void 0,n=r?Ce(r):"";if(n)switch(n){case _u:return no;case ju:return Zn;case Eu:return eo;case Ou:return to;case Su:return ro}return t});const vt=Re;var Cu=Object.prototype,wu=Cu.hasOwnProperty;function xu(e){var t=e.length,r=new e.constructor(t);return t&&typeof e[0]=="string"&&wu.call(e,"index")&&(r.index=e.index,r.input=e.input),r}var Ru=fe.Uint8Array;const Dt=Ru;function Or(e){var t=new e.constructor(e.byteLength);return new Dt(t).set(new Dt(e)),t}function Nu(e,t){var r=t?Or(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}var Tu=/\w*$/;function Au(e){var t=new e.constructor(e.source,Tu.exec(e));return t.lastIndex=e.lastIndex,t}var oo=ne?ne.prototype:void 0,ao=oo?oo.valueOf:void 0;function Mu(e){return ao?Object(ao.call(e)):{}}function io(e,t){var r=t?Or(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}var $u="[object Boolean]",Pu="[object Date]",Du="[object Map]",ku="[object Number]",Iu="[object RegExp]",Fu="[object Set]",Lu="[object String]",Bu="[object Symbol]",Uu="[object ArrayBuffer]",zu="[object DataView]",Vu="[object Float32Array]",Gu="[object Float64Array]",Wu="[object Int8Array]",Hu="[object Int16Array]",Yu="[object Int32Array]",Ju="[object Uint8Array]",qu="[object Uint8ClampedArray]",Qu="[object Uint16Array]",Xu="[object Uint32Array]";function Ku(e,t,r){var n=e.constructor;switch(t){case Uu:return Or(e);case $u:case Pu:return new n(+e);case zu:return Nu(e,r);case Vu:case Gu:case Wu:case Hu:case Yu:case Ju:case qu:case Qu:case Xu:return io(e,r);case Du:return new n;case ku:case Lu:return new n(e);case Iu:return Au(e);case Fu:return new n;case Bu:return Mu(e)}}function so(e){return typeof e.constructor=="function"&&!ur(e)?Ui(mr(e)):{}}var Zu="[object Map]";function el(e){return de(e)&&vt(e)==Zu}var co=ke&&ke.isMap,tl=co?lr(co):el;const rl=tl;var nl="[object Set]";function ol(e){return de(e)&&vt(e)==nl}var uo=ke&&ke.isSet,al=uo?lr(uo):ol;const il=al;var sl=1,cl=2,ul=4,lo="[object Arguments]",ll="[object Array]",fl="[object Boolean]",dl="[object Date]",pl="[object Error]",fo="[object Function]",hl="[object GeneratorFunction]",vl="[object Map]",yl="[object Number]",po="[object Object]",ml="[object RegExp]",gl="[object Set]",bl="[object String]",_l="[object Symbol]",jl="[object WeakMap]",El="[object ArrayBuffer]",Ol="[object DataView]",Sl="[object Float32Array]",Cl="[object Float64Array]",wl="[object Int8Array]",xl="[object Int16Array]",Rl="[object Int32Array]",Nl="[object Uint8Array]",Tl="[object Uint8ClampedArray]",Al="[object Uint16Array]",Ml="[object Uint32Array]",P={};P[lo]=P[ll]=P[El]=P[Ol]=P[fl]=P[dl]=P[Sl]=P[Cl]=P[wl]=P[xl]=P[Rl]=P[vl]=P[yl]=P[po]=P[ml]=P[gl]=P[bl]=P[_l]=P[Nl]=P[Tl]=P[Al]=P[Ml]=!0,P[pl]=P[fo]=P[jl]=!1;function yt(e,t,r,n,o,a){var i,s=t&sl,u=t&cl,l=t&ul;if(r&&(i=o?r(e,n,o,a):r(e)),i!==void 0)return i;if(!se(e))return e;var f=L(e);if(f){if(i=xu(e),!s)return xn(e,i)}else{var d=vt(e),p=d==fo||d==hl;if(lt(e))return Jn(e,s);if(d==po||d==lo||p&&!o){if(i=u||p?{}:so(e),!s)return u?vu(e,iu(i,e)):du(e,au(i,e))}else{if(!P[d])return o?e:{};i=Ku(e,d,s)}}a||(a=new ce);var v=a.get(e);if(v)return v;a.set(e,i),il(e)?e.forEach(function(E){i.add(yt(E,t,r,E,e,a))}):rl(e)&&e.forEach(function(E,w){i.set(w,yt(E,t,r,w,e,a))});var b=l?u?_r:br:u?dt:At,_=f?void 0:b(e);return Ki(_||e,function(E,w){_&&(w=E,E=e[w]),sr(i,w,yt(E,t,r,w,e,a))}),i}var $l=1,Pl=4;function ho(e){return yt(e,$l|Pl)}var Dl="__lodash_hash_undefined__";function kl(e){return this.__data__.set(e,Dl),this}function Il(e){return this.__data__.has(e)}function mt(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new ye;++t<r;)this.add(e[t])}mt.prototype.add=mt.prototype.push=kl,mt.prototype.has=Il;function Fl(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}function vo(e,t){return e.has(t)}var Ll=1,Bl=2;function yo(e,t,r,n,o,a){var i=r&Ll,s=e.length,u=t.length;if(s!=u&&!(i&&u>s))return!1;var l=a.get(e),f=a.get(t);if(l&&f)return l==t&&f==e;var d=-1,p=!0,v=r&Bl?new mt:void 0;for(a.set(e,t),a.set(t,e);++d<s;){var b=e[d],_=t[d];if(n)var E=i?n(_,b,d,t,e,a):n(b,_,d,e,t,a);if(E!==void 0){if(E)continue;p=!1;break}if(v){if(!Fl(t,function(w,S){if(!vo(v,S)&&(b===w||o(b,w,r,n,a)))return v.push(S)})){p=!1;break}}else if(!(b===_||o(b,_,r,n,a))){p=!1;break}}return a.delete(e),a.delete(t),p}function Ul(e){var t=-1,r=Array(e.size);return e.forEach(function(n,o){r[++t]=[o,n]}),r}function Sr(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var zl=1,Vl=2,Gl="[object Boolean]",Wl="[object Date]",Hl="[object Error]",Yl="[object Map]",Jl="[object Number]",ql="[object RegExp]",Ql="[object Set]",Xl="[object String]",Kl="[object Symbol]",Zl="[object ArrayBuffer]",ef="[object DataView]",mo=ne?ne.prototype:void 0,Cr=mo?mo.valueOf:void 0;function tf(e,t,r,n,o,a,i){switch(r){case ef:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case Zl:return!(e.byteLength!=t.byteLength||!a(new Dt(e),new Dt(t)));case Gl:case Wl:case Jl:return ct(+e,+t);case Hl:return e.name==t.name&&e.message==t.message;case ql:case Xl:return e==t+"";case Yl:var s=Ul;case Ql:var u=n&zl;if(s||(s=Sr),e.size!=t.size&&!u)return!1;var l=i.get(e);if(l)return l==t;n|=Vl,i.set(e,t);var f=yo(s(e),s(t),n,o,a,i);return i.delete(e),f;case Kl:if(Cr)return Cr.call(e)==Cr.call(t)}return!1}var rf=1,nf=Object.prototype,of=nf.hasOwnProperty;function af(e,t,r,n,o,a){var i=r&rf,s=br(e),u=s.length,l=br(t),f=l.length;if(u!=f&&!i)return!1;for(var d=u;d--;){var p=s[d];if(!(i?p in t:of.call(t,p)))return!1}var v=a.get(e),b=a.get(t);if(v&&b)return v==t&&b==e;var _=!0;a.set(e,t),a.set(t,e);for(var E=i;++d<u;){p=s[d];var w=e[p],S=t[p];if(n)var W=i?n(S,w,p,t,e,a):n(w,S,p,e,t,a);if(!(W===void 0?w===S||o(w,S,r,n,a):W)){_=!1;break}E||(E=p=="constructor")}if(_&&!E){var D=e.constructor,U=t.constructor;D!=U&&"constructor"in e&&"constructor"in t&&!(typeof D=="function"&&D instanceof D&&typeof U=="function"&&U instanceof U)&&(_=!1)}return a.delete(e),a.delete(t),_}var sf=1,go="[object Arguments]",bo="[object Array]",kt="[object Object]",cf=Object.prototype,_o=cf.hasOwnProperty;function uf(e,t,r,n,o,a){var i=L(e),s=L(t),u=i?bo:vt(e),l=s?bo:vt(t);u=u==go?kt:u,l=l==go?kt:l;var f=u==kt,d=l==kt,p=u==l;if(p&<(e)){if(!lt(t))return!1;i=!0,f=!1}if(p&&!f)return a||(a=new ce),i||dr(e)?yo(e,t,r,n,o,a):tf(e,t,u,r,n,o,a);if(!(r&sf)){var v=f&&_o.call(e,"__wrapped__"),b=d&&_o.call(t,"__wrapped__");if(v||b){var _=v?e.value():e,E=b?t.value():t;return a||(a=new ce),o(_,E,r,n,a)}}return p?(a||(a=new ce),af(e,t,r,n,o,a)):!1}function wr(e,t,r,n,o){return e===t?!0:e==null||t==null||!de(e)&&!de(t)?e!==e&&t!==t:uf(e,t,r,n,wr,o)}var lf=1,ff=2;function df(e,t,r,n){var o=r.length,a=o,i=!n;if(e==null)return!a;for(e=Object(e);o--;){var s=r[o];if(i&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++o<a;){s=r[o];var u=s[0],l=e[u],f=s[1];if(i&&s[2]){if(l===void 0&&!(u in e))return!1}else{var d=new ce;if(n)var p=n(l,f,u,e,t,d);if(!(p===void 0?wr(f,l,lf|ff,n,d):p))return!1}}return!0}function jo(e){return e===e&&!se(e)}function pf(e){for(var t=At(e),r=t.length;r--;){var n=t[r],o=e[n];t[r]=[n,o,jo(o)]}return t}function Eo(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}function hf(e){var t=pf(e);return t.length==1&&t[0][2]?Eo(t[0][0],t[0][1]):function(r){return r===e||df(r,e,t)}}function vf(e,t){return e!=null&&t in Object(e)}function yf(e,t,r){t=Ie(t,e);for(var n=-1,o=t.length,a=!1;++n<o;){var i=Fe(t[n]);if(!(a=e!=null&&r(e,i)))break;e=e[i]}return a||++n!=o?a:(o=e==null?0:e.length,!!o&&cr(o)&&Nt(i,o)&&(L(e)||ut(e)))}function mf(e,t){return e!=null&&yf(e,t,vf)}var gf=1,bf=2;function _f(e,t){return pr(e)&&jo(t)?Eo(Fe(e),t):function(r){var n=Un(r,e);return n===void 0&&n===t?mf(r,e):wr(t,n,gf|bf)}}function jf(e){return function(t){return t==null?void 0:t[e]}}function Ef(e){return function(t){return Pt(t,e)}}function Of(e){return pr(e)?jf(Fe(e)):Ef(e)}function xr(e){return typeof e=="function"?e:e==null?rr:typeof e=="object"?L(e)?_f(e[0],e[1]):hf(e):Of(e)}function Sf(e){return function(t,r,n){for(var o=-1,a=Object(t),i=n(t),s=i.length;s--;){var u=i[e?s:++o];if(r(a[u],u,a)===!1)break}return t}}var Cf=Sf();const wf=Cf;function Rr(e,t,r){(r!==void 0&&!ct(e[t],r)||r===void 0&&!(t in e))&&ir(e,t,r)}function Nr(e){return de(e)&&Tt(e)}function Tr(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function xf(e){return De(e,dt(e))}function Rf(e,t,r,n,o,a,i){var s=Tr(e,r),u=Tr(t,r),l=i.get(u);if(l){Rr(e,r,l);return}var f=a?a(s,u,r+"",e,t,i):void 0,d=f===void 0;if(d){var p=L(u),v=!p&<(u),b=!p&&!v&&dr(u);f=u,p||v||b?L(s)?f=s:Nr(s)?f=xn(s):v?(d=!1,f=Jn(u,!0)):b?(d=!1,f=io(u,!0)):f=[]:Q(u)||ut(u)?(f=s,ut(s)?f=xf(s):(!se(s)||nr(s))&&(f=so(u))):d=!1}d&&(i.set(u,f),o(f,u,n,a,i),i.delete(u)),Rr(e,r,f)}function Oo(e,t,r,n,o){e!==t&&wf(t,function(a,i){if(o||(o=new ce),se(a))Rf(e,t,i,r,Oo,n,o);else{var s=n?n(Tr(e,i),a,i+"",e,t,o):void 0;s===void 0&&(s=a),Rr(e,i,s)}},dt)}function Nf(e,t,r){for(var n=-1,o=e==null?0:e.length;++n<o;)if(r(t,e[n]))return!0;return!1}function So(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}function Tf(e,t){return t.length<2?e:Pt(e,Kc(t,0,-1))}var Af=ls(function(e,t,r){Oo(e,t,r)});const Co=Af;var Mf="Expected a function";function $f(e){if(typeof e!="function")throw new TypeError(Mf);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}function Pf(e,t){return t=Ie(t,e),e=Tf(e,t),e==null||delete e[Fe(So(t))]}function Df(e){return Q(e)?void 0:e}var kf=1,If=2,Ff=4,Lf=Wc(function(e,t){var r={};if(e==null)return r;var n=!1;t=tr(t,function(a){return a=Ie(a,e),n||(n=a.length>1),a}),De(e,_r(e),r),n&&(r=yt(r,kf|If|Ff,Df));for(var o=t.length;o--;)Pf(r,t[o]);return r});const wo=Lf;function Bf(e,t,r,n){if(!se(e))return e;t=Ie(t,e);for(var o=-1,a=t.length,i=a-1,s=e;s!=null&&++o<a;){var u=Fe(t[o]),l=r;if(u==="__proto__"||u==="constructor"||u==="prototype")return e;if(o!=i){var f=s[u];l=n?n(f,u,s):void 0,l===void 0&&(l=se(f)?f:Nt(t[o+1])?[]:{})}sr(s,u,l),s=s[u]}return e}function Uf(e,t,r){for(var n=-1,o=t.length,a={};++n<o;){var i=t[n],s=Pt(e,i);r(s,i)&&Bf(a,Ie(i,e),s)}return a}function zf(e,t){if(e==null)return{};var r=tr(_r(e),function(n){return[n]});return t=xr(t),Uf(e,r,function(n,o){return t(n,o[0])})}function Vf(e,t){return zf(e,$f(xr(t)))}var Gf=1/0,Wf=Le&&1/Sr(new Le([,-0]))[1]==Gf?function(e){return new Le(e)}:Vi;const Hf=Wf;var Yf=200;function Jf(e,t,r){var n=-1,o=ns,a=e.length,i=!0,s=[],u=s;if(r)i=!1,o=Nf;else if(a>=Yf){var l=t?null:Hf(e);if(l)return Sr(l);i=!1,o=vo,u=new mt}else u=t?[]:s;e:for(;++n<a;){var f=e[n],d=t?t(f):f;if(f=r||f!==0?f:0,i&&d===d){for(var p=u.length;p--;)if(u[p]===d)continue e;t&&u.push(d),s.push(f)}else o(u,d,r)||(u!==s&&u.push(d),s.push(f))}return s}var qf=An(function(e){var t=So(e);return Nr(t)&&(t=void 0),Jf(yr(e,1,Nr,!0),xr(t))});const Qf=qf;class xo extends TypeError{constructor(t,r){let n;const{message:o,...a}=t,{path:i}=t,s=i.length===0?o:`At path: ${i.join(".")} -- ${o}`;super(s),this.value=void 0,this.key=void 0,this.type=void 0,this.refinement=void 0,this.path=void 0,this.branch=void 0,this.failures=void 0,Object.assign(this,a),this.name=this.constructor.name,this.failures=()=>n??(n=[t,...r()])}}function Xf(e){return ue(e)&&typeof e[Symbol.iterator]=="function"}function ue(e){return typeof e=="object"&&e!=null}function K(e){return typeof e=="symbol"?e.toString():typeof e=="string"?JSON.stringify(e):`${e}`}function Kf(e){const{done:t,value:r}=e.next();return t?void 0:r}function Zf(e,t,r,n){if(e===!0)return;e===!1?e={}:typeof e=="string"&&(e={message:e});const{path:o,branch:a}=t,{type:i}=r,{refinement:s,message:u=`Expected a value of type \`${i}\`${s?` with refinement \`${s}\``:""}, but received: \`${K(n)}\``}=e;return{value:n,type:i,refinement:s,key:o[o.length-1],path:o,branch:a,...e,message:u}}function*Ro(e,t,r,n){Xf(e)||(e=[e]);for(const o of e){const a=Zf(o,t,r,n);a&&(yield a)}}function*Ar(e,t,r){r===void 0&&(r={});const{path:n=[],branch:o=[e],coerce:a=!1,mask:i=!1}=r,s={path:n,branch:o};if(a&&(e=t.coercer(e,s),i&&t.type!=="type"&&ue(t.schema)&&ue(e)&&!Array.isArray(e)))for(const l in e)t.schema[l]===void 0&&delete e[l];let u="valid";for(const l of t.validator(e,s))u="not_valid",yield[l,void 0];for(let[l,f,d]of t.entries(e,s)){const p=Ar(f,d,{path:l===void 0?n:[...n,l],branch:l===void 0?o:[...o,f],coerce:a,mask:i});for(const v of p)v[0]?(u=v[0].refinement!=null?"not_refined":"not_valid",yield[v[0],void 0]):a&&(f=v[1],l===void 0?e=f:e instanceof Map?e.set(l,f):e instanceof Set?e.add(f):ue(e)&&(f!==void 0||l in e)&&(e[l]=f))}if(u!=="not_valid")for(const l of t.refiner(e,s))u="not_refined",yield[l,void 0];u==="valid"&&(yield[void 0,e])}class pe{constructor(t){this.TYPE=void 0,this.type=void 0,this.schema=void 0,this.coercer=void 0,this.validator=void 0,this.refiner=void 0,this.entries=void 0;const{type:r,schema:n,validator:o,refiner:a,coercer:i=u=>u,entries:s=function*(){}}=t;this.type=r,this.schema=n,this.entries=s,this.coercer=i,o?this.validator=(u,l)=>{const f=o(u,l);return Ro(f,l,this,u)}:this.validator=()=>[],a?this.refiner=(u,l)=>{const f=a(u,l);return Ro(f,l,this,u)}:this.refiner=()=>[]}assert(t){return No(t,this)}create(t){return ed(t,this)}is(t){return rd(t,this)}mask(t){return td(t,this)}validate(t,r){return r===void 0&&(r={}),Be(t,this,r)}}function No(e,t){const r=Be(e,t);if(r[0])throw r[0]}function ed(e,t){const r=Be(e,t,{coerce:!0});if(r[0])throw r[0];return r[1]}function td(e,t){const r=Be(e,t,{coerce:!0,mask:!0});if(r[0])throw r[0];return r[1]}function rd(e,t){return!Be(e,t)[0]}function Be(e,t,r){r===void 0&&(r={});const n=Ar(e,t,r),o=Kf(n);return o[0]?[new xo(o[0],function*(){for(const a of n)a[0]&&(yield a[0])}),void 0]:[void 0,o[1]]}function Mr(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];const n=t[0].type==="type",o=t.map(i=>i.schema),a=Object.assign({},...o);return n?$o(a):M(a)}function Ee(e,t){return new pe({type:e,schema:null,validator:t})}function Ue(e){return new pe({type:"dynamic",schema:null,*entries(t,r){yield*e(t,r).entries(t,r)},validator(t,r){return e(t,r).validator(t,r)},coercer(t,r){return e(t,r).coercer(t,r)},refiner(t,r){return e(t,r).refiner(t,r)}})}function To(e,t){const{schema:r}=e,n={...r};for(const o of t)delete n[o];switch(e.type){case"type":return $o(n);default:return M(n)}}function G(){return Ee("any",()=>!0)}function B(e){return new pe({type:"array",schema:e,*entries(t){if(e&&Array.isArray(t))for(const[r,n]of t.entries())yield[r,n,e]},coercer(t){return Array.isArray(t)?t.slice():t},validator(t){return Array.isArray(t)||`Expected an array value, but received: ${K(t)}`}})}function me(){return Ee("boolean",e=>typeof e=="boolean")}function $r(e){const t={},r=e.map(n=>K(n)).join();for(const n of e)t[n]=n;return new pe({type:"enums",schema:t,validator(n){return e.includes(n)||`Expected one of \`${r}\`, but received: ${K(n)}`}})}function Ao(){return Ee("func",e=>typeof e=="function"||`Expected a function, but received: ${K(e)}`)}function X(e){const t=K(e),r=typeof e;return new pe({type:"literal",schema:r==="string"||r==="number"||r==="boolean"?e:null,validator(n){return n===e||`Expected the literal \`${t}\`, but received: ${K(n)}`}})}function nd(){return Ee("never",()=>!1)}function Mo(){return Ee("number",e=>typeof e=="number"&&!isNaN(e)||`Expected a number, but received: ${K(e)}`)}function M(e){const t=e?Object.keys(e):[],r=nd();return new pe({type:"object",schema:e||null,*entries(n){if(e&&ue(n)){const o=new Set(Object.keys(n));for(const a of t)o.delete(a),yield[a,n[a],e[a]];for(const a of o)yield[a,n[a],r]}},validator(n){return ue(n)||`Expected an object, but received: ${K(n)}`},coercer(n){return ue(n)?{...n}:n}})}function g(e){return new pe({...e,validator:(t,r)=>t===void 0||e.validator(t,r),refiner:(t,r)=>t===void 0||e.refiner(t,r)})}function gt(e,t){return new pe({type:"record",schema:null,*entries(r){if(ue(r))for(const n in r){const o=r[n];yield[n,n,e],yield[n,o,t]}},validator(r){return ue(r)||`Expected an object, but received: ${K(r)}`}})}function m(){return Ee("string",e=>typeof e=="string"||`Expected a string, but received: ${K(e)}`)}function $o(e){const t=Object.keys(e);return new pe({type:"type",schema:e,*entries(r){if(ue(r))for(const n of t)yield[n,r[n],e[n]]},validator(r){return ue(r)||`Expected an object, but received: ${K(r)}`}})}function Y(e){const t=e.map(r=>r.type).join(" | ");return new pe({type:"union",schema:null,coercer(r,n){return(e.find(o=>{const[a]=o.validate(r,{coerce:!0});return!a})||od()).coercer(r,n)},validator(r,n){const o=[];for(const a of e){const[...i]=Ar(r,a,n),[s]=i;if(s[0])for(const[u]of i)u&&o.push(u);else return[]}return[`Expected the value to satisfy a union of \`${t}\`, but received: ${K(r)}`,...o]}})}function od(){return Ee("unknown",()=>!0)}const Pr=M({package:m(),version:m(),exportName:m(),destructuring:g(me()),subName:g(m()),main:g(m())}),ad=B(Pr),id=["CBlock","CContainer","CImage","CCanvas","CVideo","CAudio","CText","CNativeTag"];var oe=(e=>(e.SLOT="SLOT",e.FUNCTION="FUNCTION",e.EXPRESSION="EXPRESSION",e))(oe||{}),Dr=(e=>(e.DESIGN="design",e.SAVE="save",e))(Dr||{}),kr=(e=>(e.FUNC="FUNC",e.COMP="COMP",e))(kr||{});const sd=()=>Ee("normalObj",e=>!Q(e)||[oe.SLOT,oe.EXPRESSION,oe.FUNCTION].includes(e==null?void 0:e.type)?!1:(Be(e,gt(m(),Ir)),!0)),Ir=Y([m(),Mo(),me(),M({type:X(oe.SLOT),renderType:$r([kr.FUNC,kr.COMP]),params:g(B(m())),value:Ue(()=>Y([ze,B(ze)]))}),M({type:X(oe.EXPRESSION),value:m()}),M({type:X(oe.FUNCTION),value:m()}),sd(),B(Ue(()=>Ir))]),Po=M({type:X(oe.EXPRESSION),value:m()}),ze=M({id:g(m()),title:g(m()),componentName:m(),props:g(gt(m(),Ir)),stateName:g(m()),state:g(gt(m(),G())),children:Ue(()=>g(B(Y([m(),ze])))),configure:g(G()),css:g(G()),style:g(G()),classNames:g(B(G())),refId:g(m()),extra:g(gt(G(),G())),condition:g(Y([me(),Po])),tempDevConfig:g(G()),loop:g(M({open:me(),data:Y([B(G()),Po]),args:g(B(m())),forName:g(m()),forIndex:g(m()),key:g(G()),name:g(m())}))}),It=Y([m(),M({label:m(),tip:g(m())})]),cd=M({type:X("shape"),value:B(M({name:m(),title:It,valueType:Ue(()=>Ft)}))}),ud=M({type:X("enums"),value:B(m())});M({type:X("array"),value:Ue(()=>Ft)});const ld=M({type:X("array"),value:Ue(()=>B(Ft))}),Ft=Y([$r(["array","boolean","number","object","string"]),$r(["component","expression","function"]),cd,ud,ld]),fd=Y([m(),M({componentName:m(),props:g(G()),initialValue:g(G()),component:g(G())})]),Fr=M({name:m(),title:It,valueType:Ft,description:g(m()),defaultValue:G(),setters:g(B(fd)),condition:g(Ao())}),dd=Y([m(),Ao()]);var Lr=(e=>(e.SINGLE="single",e.GROUP="group",e))(Lr||{});Y([m(),M({name:m(),describe:g(m()),params:g(M({name:m(),description:m()})),template:m()})]);const pd=M({id:g(m()),title:m(),snapshot:Y([m(),G()]),snapshotText:g(m()),description:g(m()),tags:g(B(m())),groupName:g(m()),category:g(m()),schema:Mr(To(ze,["id"]),M({componentName:g(m())}))}),hd=M({componentName:m(),title:m(),screenshot:g(m()),icon:g(m()),tags:g(B(m())),groupName:g(m()),category:g(m()),priority:g(Mo()),npm:g(Pr),snippets:B(pd),props:B(Y([Fr,M({title:g(It),type:X("single"),content:Fr}),M({title:g(It),type:X("group"),content:B(Fr)})])),fixedProps:g(G()),isContainer:g(Y([me(),M({placeholder:m(),width:m(),height:m()})])),isModal:g(Y([me(),M({visibleKey:m()})])),isSupportStyle:g(me()),isSupportDispatchNativeEvent:g(me()),isLayout:g(me()),rootSelector:g(m()),selectionToolBars:g(B(dd)),extra:g(gt(G(),G()))}),vd=e=>({data:t,message:r,throwError:n})=>{const o=e({data:t,message:r,throwError:n});if(o.isValidate)return o;if(n)throw o.message||r?new Error(`${o.message||r}
|
|
28
|
-
originData: ${JSON.stringify(t)}`):new Error(`${JSON.stringify(t)}
|
|
29
|
-
data struct format is invalidate`);return o},Br=e=>{const{data:t,message:r,throwError:n,dataStruct:o}=e;return vd(({data:a})=>{try{return No(a,o),{isValidate:!0}}catch(i){let s=i;return i instanceof xo&&(s=i.failures().map(u=>`【${u.path.join(".")}】: ${u.message}
|
|
30
|
-
`)),{isValidate:!1,message:s,error:i}}})({data:t,message:r,throwError:n})};var Ve=(e=>(e.ROOT_CONTAINER="RootContainer",e))(Ve||{});const yd=M({type:X(oe.FUNCTION),value:m()}),md=Mr(To(ze,["componentName"]),M({componentName:X("RootContainer")}));function gd(e){return{all:e=e||new Map,on:function(t,r){var n=e.get(t);n?n.push(r):e.set(t,[r])},off:function(t,r){var n=e.get(t);n&&(r?n.splice(n.indexOf(r)>>>0,1):e.set(t,[]))},emit:function(t,r){var n=e.get(t);n&&n.slice().map(function(o){o(r)}),(n=e.get("*"))&&n.slice().map(function(o){o(t,r)})}}}const bt=gd(),bd=(e,t)=>{const r={...e,value:[]},n=e.value;let o=new Te([]);return t&&(o=t.materialsMode||new Te([])),n&&(L(n)?r.value=n.map(a=>new F(a,{parent:t,materials:o})):Q(n)&&r.value.push(new F(n,{parent:t,materials:o}))),r};class Ge{constructor(t,r){C(this,"nodeType","SLOT"),C(this,"rawData"),C(this,"parent"),C(this,"emitter",bt),C(this,"data"),C(this,"id"),C(this,"materialsMode"),this.parent=(r==null?void 0:r.parent)||null,this.rawData=t;const n=(r==null?void 0:r.materials)||new Te([]);this.materialsMode=n,this.id=he(),this.data=bd(t,this)}get value(){return this.data}export(t){const r=this.data,n=o=>{if(o instanceof F)return o.export(t);if(Q(o)){const a={};return Object.keys(o||{}).forEach(i=>{a[i]=n(o[i])}),a}return L(o)?o.map(a=>n(a)):(t==="design"&&delete o.id,o)};return n(r)}}const Do=e=>{let t=[];return e.forEach(r=>{const n=r;n.type?n.type===Lr.SINGLE?t.push(n.content):n.type===Lr.GROUP&&(t=[...t,...Do(n.content)]):t.push(r)}),t},Ur=(e,t,r)=>{if(e.type)return e.type===oe.SLOT?new Ge(e,{parent:t,materials:r}):e;if(Q(e)){const n={};return Object.keys(e).forEach(o=>{n[o]=zr(e[o],t,r)}),n}else return Array.isArray(e)?e.map(n=>Ur(n,t,r)):e},zr=(e,t,r)=>Q(e)?Ur(e,t,r):L(e)?e.map(n=>Ur(n,t,r)):e;class Oe{constructor(t,r,n){C(this,"nodeType","PROP"),C(this,"rawData"),C(this,"parent"),C(this,"emitter",bt),C(this,"data"),C(this,"name"),C(this,"materialsMode");const o=(n==null?void 0:n.materials)||new Te([]);this.materialsMode=o,this.parent=n==null?void 0:n.parent,this.rawData=r,this.name=t,this.data=zr(r,this,o)}isIncludeSlot(){return!1}isIncludeExpression(){return!1}get value(){return this.data}updateValue(t){const r=this.data;this.data=zr(t??r,this,this.materialsMode),this.emitter.emit("onPropChange",{value:this.data,preValue:r,node:this}),this.parent&&!(this.parent instanceof Ge)&&this.emitter.emit("onNodeChange",{value:this.parent.value,preValue:this.parent.value,node:this.parent})}get material(){const t=this.parent;if(t instanceof F){const r=t.material;return Do((r==null?void 0:r.value.props)||[]).find(n=>n.name===this.name)}else return null}export(t){const r=this.data,n=o=>{if(o instanceof Oe||o instanceof Ge||o instanceof F)return o.export(t);if(L(o))return o.map(a=>n(a));if(Q(o)){const a={};return Object.keys(o||{}).forEach(i=>{a[i]=n(o[i])}),a}return o};return n(r)}}const _d=e=>{if(typeof e=="string")return!0;Br({data:e,dataStruct:ze,throwError:!0})},ko=(e,t,r=new Te([]))=>{if(typeof e=="string")return e;const n={...e,id:e.id??he(),children:[],props:{},configure:Co(e.configure||{},{propsSetter:{},advanceSetter:{}})},o=Object.keys(e.props||{});return o.length&&o.forEach(a=>{var i;const s=(i=e.props)==null?void 0:i[a];if(s instanceof Oe){n.props[a]=s;return}n.props[a]=new Oe(a,s||"",{parent:t,materials:r})}),e.children&&(Array.isArray(e.children)?n.children=e.children.map(a=>{if(a instanceof F)return a;if(Q(a)){const i=a;return new F(i,{parent:t,materials:r})}else return a}):(e.children instanceof F&&(n.children=[e.children]),n.children=[new F(e.children,{parent:t,materials:r})])),n};class F{constructor(t,r){C(this,"nodeType","NODE"),C(this,"rawData"),C(this,"data"),C(this,"emitter",bt),C(this,"parent"),C(this,"materialsModel"),C(this,"listenerHandle"),C(this,"onChangeCbQueue"),this.rawData=JSON.parse(JSON.stringify(t)),_d(t);const n=(r==null?void 0:r.materials)||new Te([]);this.parent=(r==null?void 0:r.parent)||null,this.materialsModel=n,this.data=ko(t,this,n),this.listenerHandle=[],this.onChangeCbQueue=[],this.registerListener()}registerListener(){const t=r=>{const{node:n}=r;n===this&&n.id===this.id&&this.onChangeCbQueue.forEach(o=>o(r))};this.emitter.on("onNodeChange",t),this.listenerHandle.push(()=>{this.emitter.off("onNodeChange",t)})}onChange(t){return this.onChangeCbQueue.push(t),()=>{this.onChangeCbQueue=this.onChangeCbQueue.filter(r=>r!==t)}}destroy(){this.listenerHandle.forEach(t=>t())}get id(){return this.data.id}get value(){return this.data}clone(t){const r={...this.export("design"),id:t||he()};return new F(r,{materials:this.materialsModel})}updateValue(t){const r=this.data,n={...this.data,...t};this.data=ko(n,this),this.emitter.emit("onNodeChange",{value:n,preValue:r,node:this})}contains(t){return Wr(this,t)}get props(){return this.data.props}get material(){const t=this.materialsModel;return t==null?void 0:t.findByComponentName(this.data.componentName)}getPlainProps(){const t=this.data,r={};return Object.keys(t.props||{}).forEach(n=>{r[n]=t.props[n].export("design")}),r}export(t){var r;const n=this.data;if(typeof n=="string")return n;const o={};Object.keys(n.props||{}).forEach(f=>{o[f]=n.props[f].export(t)});const a=(r=n.children)==null?void 0:r.map(f=>f instanceof F?f.export(t):f),i=n.configure||{},s=i.propsSetter||{},u={};Object.keys(s).forEach(f=>{const d=Un(s,f,!1);d&&(u[f]=d)}),i.propsSetter=u,this.material&&this.materialsModel.usedMaterials.push(this.material);let l={...n,configure:i,props:o,children:a};return t==="design"&&delete l.id,l=Gr(l),l}}const Io=(e,t,r)=>{const n={...e,id:he(),props:{},componentName:Ve.ROOT_CONTAINER,children:[],configure:Co(e.configure||{},{propsSetter:{},advanceSetter:{}})};let o=[];L(e.children)?o=e.children.map(i=>i instanceof F?i:Q(i)?new F(i,{parent:t,materials:r}):i):e.children instanceof F?o.push(e.children):e.children&&Q(e.children)&&o.push(new F(e.children,{parent:t,materials:r}));const a=Object.keys(e.props||{});return a.length&&a.forEach(i=>{var s;const u=(s=e.props)==null?void 0:s[i];u instanceof Oe?n.props[i]=u:n.props[i]=new Oe(i,u||"",{parent:t,materials:r})}),n.children=o,n};class _t{constructor(t,{parent:r,materials:n}){C(this,"rawData"),C(this,"data"),C(this,"nodeType",Ve.ROOT_CONTAINER),C(this,"emitter",bt),C(this,"materialsModel"),C(this,"listenerHandle"),C(this,"onChangeCbQueue"),C(this,"parent"),this.materialsModel=n,this.rawData=JSON.parse(JSON.stringify(t)),this.data=Io(t,this,n),this.listenerHandle=[],this.onChangeCbQueue=[],this.registerListener(),this.parent=r}registerListener(){const t=r=>{const{node:n}=r;n===this&&n.id===this.id&&this.onChangeCbQueue.forEach(o=>o(r))};this.emitter.on("onNodeChange",t),this.listenerHandle.push(()=>{this.emitter.off("onNodeChange",t)})}onChange(t){return this.onChangeCbQueue.push(t),()=>{this.onChangeCbQueue=this.onChangeCbQueue.filter(r=>r!==t)}}get id(){return this.data.id}get value(){return this.data}get props(){return this.data.props}get material(){const t=this.materialsModel;return t==null?void 0:t.findByComponentName(this.data.componentName)}updateValue(t){const r=this.data,n={...this.data,...t};this.data=Io(n,this,this.materialsModel),this.emitter.emit("onNodeChange",{value:this.data,preValue:r,node:this})}contains(t){return Wr(this,t)}export(t=Dr.SAVE){var r;const n=this.data,o={};Object.keys(n.props||{}).forEach(u=>{o[u]=n.props[u].export(t)});const a=((r=n.children)==null?void 0:r.map(u=>{var l;return(l=u==null?void 0:u.export)==null?void 0:l.call(u,t)}))||[],i={...n,props:o,children:a.filter(u=>u)};let s=wo(i,["id"]);return s=Gr(s),s}getPlainProps(){const t=this.data,r={};return Object.keys(t.props||{}).forEach(n=>{r[n]=t.props[n].export("design")}),r}destroy(){this.listenerHandle.forEach(t=>t())}clone(t){const r={...this.export("design"),id:t||he()};return new _t(r,{materials:this.materialsModel,parent:null})}}const Ne=e=>(e==null?void 0:e.type)===oe.EXPRESSION,jd=e=>(e==null?void 0:e.type)==oe.FUNCTION,he=()=>Math.random().toString(32).slice(3,9),Ed=e=>(e==null?void 0:e.nodeType)==="NODE",Vr=e=>(e==null?void 0:e.nodeType)==="PROP",Od=e=>(e==null?void 0:e.nodeType)==="SLOT",Gr=e=>Vf(e,t=>Q(t)?!Object.keys(t).length:L(t)?!t.length:!t);function Wr(e,t){const r=[e];for(;r.length;){const n=r.shift();if((n==null?void 0:n.id)===t)return n;const o=(n==null?void 0:n.props)||{},a=s=>{if(s instanceof F){r.push(s);return}if(s instanceof Ge&&a(s.value.value),s instanceof Oe){a(s.value);return}if(Q(s)){const u=s;Object.keys(u).map(l=>{a(u[l])});return}if(L(s)){s.forEach(u=>{a(u)});return}};a(o);const i=(n==null?void 0:n.value.children.filter(s=>s instanceof F))||[];r.push(...i)}return null}const Sd=e=>{const t=ho(e),r=t.snippets;return delete t.snippets,t.snippets=r.map(n=>({...t,...n,id:n.id||`${e.componentName}-${he()}`,title:n.title||e.title,category:n.category||e.category,tags:[...n.tags||[],...e.tags||[]],groupName:n.groupName||e.groupName,snapshot:n.snapshot||e.icon,snapshotText:n.snapshotText,schema:{...n.schema,componentName:n.schema.componentName||e.componentName}})),t};class Cd{constructor(t){C(this,"rawData"),C(this,"data"),this.rawData=t,this.data=Sd(t)}get value(){return this.data}get rawValue(){return this.rawData}get componentName(){return this.data.componentName}get snippets(){return this.data.snippets}getSnippetById(t){return this.data.snippets.find(r=>r.id===t)}}const wd=e=>{if(!L(e))throw new Error("Materials must be a array");return e.map(t=>new Cd(t))},xd=e=>{e==null||e.forEach(t=>{Br({data:t,dataStruct:hd,throwError:!0})})};class Te{constructor(t){C(this,"rawData"),C(this,"data"),C(this,"usedMaterials",[]),this.rawData=t,xd(t),this.data=wd(t)}findByComponentName(t){return this.data.find(r=>r.componentName===t)}findSnippetById(t){const r=[...this.data];let n=null;for(;!n&&r.length;){const o=r.pop();n=o==null?void 0:o.getSnippetById(t)}return n}getAllSnippets(){let t=this.data.reduce((a,i)=>(a.push(...i.snippets),a),[]);const r=[],n={default:[]};t=t.sort((a,i)=>(a.category||"")>(i.category||"")?1:-1),t.forEach(a=>{const i=a.groupName||"default";r.includes(i)||(r.push(i),n[i]=[]),n[i].push(a)});const o=[];return r.forEach(a=>{const i=["default"],s={default:[]},u=n[a];if(u.length!==0){u.forEach(d=>{const p=d.category||"default";i.includes(p)||(i.push(p),s[p]=[]),s[p].push(d)});const l=[];i.forEach(d=>{s[d].length&&l.push({name:d,list:s[d]})});const f={name:a,list:l};o.push(f)}}),o}get value(){return this.data}get rawValue(){return this.rawData}}const Rd=M({version:m(),name:m(),css:g(m()),renderType:g(Y([X("COMPONENT"),X("PAGE")])),methods:g(B(yd)),componentsMeta:B(Mr(M({componentName:m()}),Pr)),thirdLibs:g(ad),componentsTree:md,assets:g(B(G()))}),Fo=e=>(Br({data:e,dataStruct:Rd,throwError:!0}),e),Hr=(e,t,r)=>({...e,componentsTree:new _t(e.componentsTree,{parent:t,materials:r})});class Lt{constructor(t,r){C(this,"nodeType","PAGE"),C(this,"rawData"),C(this,"emitter",bt),C(this,"data"),C(this,"parent"),C(this,"materialsModel"),C(this,"assetPackagesList"),Fo(t),this.assetPackagesList=(r==null?void 0:r.assetPackagesList)||[],this.rawData=JSON.parse(JSON.stringify(t)),this.materialsModel=new Te((r==null?void 0:r.materials)||[]),this.data=Hr(t,this,this.materialsModel)}updatePage(t){const r=this.data;this.rawData=JSON.parse(JSON.stringify(t)),this.data=Hr(t,this,this.materialsModel),this.emitter.emit("onPageChange",{value:this.data,preValue:r,node:this})}reloadPage(t){const r=this.data;this.rawData=JSON.parse(JSON.stringify(t)),this.data=Hr(t,this,this.materialsModel),this.emitter.emit("onReloadPage",{value:this.data,preValue:r,node:this})}get value(){return this.data}getNode(t){const r=this.data.componentsTree;return Wr(r,t)}addNode(t,r,n="AFTER"){var o;if(n==="AFTER"||n==="BEFORE"){const a=r.parent;if(a===null&&r instanceof _t)return console.warn("Not found parent node"),!1;if(a instanceof Oe)return console.warn("CProp can not add node"),!1;if(a instanceof Ge){const s=a.value.value,u=s.findIndex(l=>l===r)??-1;return u>=0?(n==="BEFORE"?s.splice(u,0,t):s.splice(u+1,0,t),t.parent=a,(o=a.parent)==null||o.updateValue(),!0):!1}if(a instanceof Lt)return!1;const i=(a==null?void 0:a.value.children.findIndex(s=>s===r))??-1;return i>=0?(n==="BEFORE"?a==null||a.value.children.splice(i,0,t):a==null||a.value.children.splice(i+1,0,t),t.parent=a,a==null||a.updateValue(),!0):(console.warn("Not found target node"),!1)}if(n==="CHILD_START")return r.value.children.unshift(t),t.parent=r,r.updateValue(),!0;if(n==="CHILD_END")return r.value.children.push(t),t.parent=r,r.updateValue(),!0;if(Q(n)){const a=n;if(a.type==="CHILD"){const i=a.pos,s=a.index||0;return i==="BEFORE"?r==null||r.value.children.splice(s,0,t):r==null||r.value.children.splice(s+1,0,t),t.parent=r,r.updateValue(),!0}else console.warn("Can not parse pos obj")}return!1}createNode(t){return delete t.id,new F(t,{parent:null,materials:this.materialsModel})}addNodeById(t,r,n="AFTER"){const o=this.getNode(r);return o?this.addNode(t,o,n):(console.warn(`Not find a node by ${r}, pls check it`),!1)}copyNode(t){const r=t.export("design");r.id=he();const n=new F(r,{parent:t.parent,materials:this.materialsModel});return this.addNode(n,t,"AFTER"),n}copyNodeById(t){const r=this.getNode(t);return r&&r instanceof F?this.copyNode(r):!1}moveNode(t,r,n){this.deleteNode(t);let o=r;return["AFTER","BEFORE"].includes(n)&&(o=r.parent),t.parent=o,this.addNode(t,r,n)}moveNodeById(t,r,n){const o=this.getNode(t),a=this.getNode(r);return o&&a&&o instanceof F&&a instanceof F?this.moveNode(o,a,n):!1}deleteNode(t){var r;const n=t.parent;if(!n)throw new Error("parent node is null or undefined, pls check it");if(n instanceof Ge){const o=n.value.value,a=o.findIndex(s=>s===t),i=o[a];return o.splice(a,1),(r=n.parent)==null||r.updateValue(),i}if(n instanceof F||n instanceof _t){const o=n.value.children,a=o.findIndex(s=>s===t),i=o[a];return o.splice(a,1),n.updateValue(),i}}deleteNodeById(t){const r=this.getNode(t);if(r)return this.deleteNode(r)}export(t=Dr.SAVE){var r;const n=this.data.componentsTree.export(t),o=this.assetPackagesList,a=[],i=this.materialsModel.usedMaterials.map(u=>{const l=o.find(f=>{var d;return f.package===((d=u.value.npm)==null?void 0:d.package)});return l&&a.push(l),{componentName:u.componentName,...ho(u.value.npm||{})}}).filter(u=>{if(u.componentName&&u.package&&u.version)return!0});this.materialsModel.usedMaterials=[];let s={...this.data,componentsTree:Gr(n),componentsMeta:i,thirdLibs:this.data.thirdLibs,assets:[]};return(r=this.data.thirdLibs)==null||r.forEach(u=>{const l=o.find(f=>{f.package,f.package});l&&a.push(l)}),s.assets=Qf(a,u=>u.package),s=wo(s,["id"]),JSON.parse(JSON.stringify(s))}}Ve.ROOT_CONTAINER;var Nd=typeof global=="object"&&global&&global.Object===Object&&global;const Lo=Nd;var Td=typeof self=="object"&&self&&self.Object===Object&&self,Ad=Lo||Td||Function("return this")();const We=Ad;var Md=We.Symbol;const He=Md;var Bo=Object.prototype,$d=Bo.hasOwnProperty,Pd=Bo.toString,jt=He?He.toStringTag:void 0;function Dd(e){var t=$d.call(e,jt),r=e[jt];try{e[jt]=void 0;var n=!0}catch{}var o=Pd.call(e);return n&&(t?e[jt]=r:delete e[jt]),o}var kd=Object.prototype,Id=kd.toString;function Fd(e){return Id.call(e)}var Ld="[object Null]",Bd="[object Undefined]",Uo=He?He.toStringTag:void 0;function Et(e){return e==null?e===void 0?Bd:Ld:Uo&&Uo in Object(e)?Dd(e):Fd(e)}function Ye(e){return e!=null&&typeof e=="object"}var Ud="[object Symbol]";function zd(e){return typeof e=="symbol"||Ye(e)&&Et(e)==Ud}function Vd(e,t){for(var r=-1,n=e==null?0:e.length,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}var Gd=Array.isArray;const Je=Gd;var Wd=1/0,zo=He?He.prototype:void 0,Vo=zo?zo.toString:void 0;function Go(e){if(typeof e=="string")return e;if(Je(e))return Vd(e,Go)+"";if(zd(e))return Vo?Vo.call(e):"";var t=e+"";return t=="0"&&1/e==-Wd?"-0":t}function Ae(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}function Wo(e){return e}var Hd="[object AsyncFunction]",Yd="[object Function]",Jd="[object GeneratorFunction]",qd="[object Proxy]";function Yr(e){if(!Ae(e))return!1;var t=Et(e);return t==Yd||t==Jd||t==Hd||t==qd}var Qd=We["__core-js_shared__"];const Jr=Qd;var Ho=function(){var e=/[^.]+$/.exec(Jr&&Jr.keys&&Jr.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function Xd(e){return!!Ho&&Ho in e}var Kd=Function.prototype,Zd=Kd.toString;function ep(e){if(e!=null){try{return Zd.call(e)}catch{}try{return e+""}catch{}}return""}var tp=/[\\^$.*+?()[\]{}|]/g,rp=/^\[object .+?Constructor\]$/,np=Function.prototype,op=Object.prototype,ap=np.toString,ip=op.hasOwnProperty,sp=RegExp("^"+ap.call(ip).replace(tp,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function cp(e){if(!Ae(e)||Xd(e))return!1;var t=Yr(e)?sp:rp;return t.test(ep(e))}function up(e,t){return e==null?void 0:e[t]}function qr(e,t){var r=up(e,t);return cp(r)?r:void 0}var Yo=Object.create,lp=function(){function e(){}return function(t){if(!Ae(t))return{};if(Yo)return Yo(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();const fp=lp;function dp(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function pp(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var hp=800,vp=16,yp=Date.now;function mp(e){var t=0,r=0;return function(){var n=yp(),o=vp-(n-r);if(r=n,o>0){if(++t>=hp)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function gp(e){return function(){return e}}var bp=function(){try{var e=qr(Object,"defineProperty");return e({},"",{}),e}catch{}}();const Bt=bp;var _p=Bt?function(e,t){return Bt(e,"toString",{configurable:!0,enumerable:!1,value:gp(t),writable:!0})}:Wo,jp=mp(_p);const Ep=jp;var Op=9007199254740991,Sp=/^(?:0|[1-9]\d*)$/;function Jo(e,t){var r=typeof e;return t=t??Op,!!t&&(r=="number"||r!="symbol"&&Sp.test(e))&&e>-1&&e%1==0&&e<t}function Qr(e,t,r){t=="__proto__"&&Bt?Bt(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function Ut(e,t){return e===t||e!==e&&t!==t}var Cp=Object.prototype,wp=Cp.hasOwnProperty;function xp(e,t,r){var n=e[t];(!(wp.call(e,t)&&Ut(n,r))||r===void 0&&!(t in e))&&Qr(e,t,r)}function Rp(e,t,r,n){var o=!r;r||(r={});for(var a=-1,i=t.length;++a<i;){var s=t[a],u=n?n(r[s],e[s],s,r,e):void 0;u===void 0&&(u=e[s]),o?Qr(r,s,u):xp(r,s,u)}return r}var qo=Math.max;function Np(e,t,r){return t=qo(t===void 0?e.length-1:t,0),function(){for(var n=arguments,o=-1,a=qo(n.length-t,0),i=Array(a);++o<a;)i[o]=n[t+o];o=-1;for(var s=Array(t+1);++o<t;)s[o]=n[o];return s[t]=r(i),dp(e,this,s)}}function Tp(e,t){return Ep(Np(e,t,Wo),e+"")}var Ap=9007199254740991;function Qo(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Ap}function Xr(e){return e!=null&&Qo(e.length)&&!Yr(e)}function Mp(e,t,r){if(!Ae(r))return!1;var n=typeof t;return(n=="number"?Xr(r)&&Jo(t,r.length):n=="string"&&t in r)?Ut(r[t],e):!1}function $p(e){return Tp(function(t,r){var n=-1,o=r.length,a=o>1?r[o-1]:void 0,i=o>2?r[2]:void 0;for(a=e.length>3&&typeof a=="function"?(o--,a):void 0,i&&Mp(r[0],r[1],i)&&(a=o<3?void 0:a,o=1),t=Object(t);++n<o;){var s=r[n];s&&e(t,s,n,a)}return t})}var Pp=Object.prototype;function Xo(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||Pp;return e===r}function Dp(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var kp="[object Arguments]";function Ko(e){return Ye(e)&&Et(e)==kp}var Zo=Object.prototype,Ip=Zo.hasOwnProperty,Fp=Zo.propertyIsEnumerable,Lp=Ko(function(){return arguments}())?Ko:function(e){return Ye(e)&&Ip.call(e,"callee")&&!Fp.call(e,"callee")};const Kr=Lp;function Bp(){return!1}var ea=typeof exports=="object"&&exports&&!exports.nodeType&&exports,ta=ea&&typeof module=="object"&&module&&!module.nodeType&&module,Up=ta&&ta.exports===ea,ra=Up?We.Buffer:void 0,zp=ra?ra.isBuffer:void 0,Vp=zp||Bp;const na=Vp;var Gp="[object Arguments]",Wp="[object Array]",Hp="[object Boolean]",Yp="[object Date]",Jp="[object Error]",qp="[object Function]",Qp="[object Map]",Xp="[object Number]",Kp="[object Object]",Zp="[object RegExp]",eh="[object Set]",th="[object String]",rh="[object WeakMap]",nh="[object ArrayBuffer]",oh="[object DataView]",ah="[object Float32Array]",ih="[object Float64Array]",sh="[object Int8Array]",ch="[object Int16Array]",uh="[object Int32Array]",lh="[object Uint8Array]",fh="[object Uint8ClampedArray]",dh="[object Uint16Array]",ph="[object Uint32Array]",I={};I[ah]=I[ih]=I[sh]=I[ch]=I[uh]=I[lh]=I[fh]=I[dh]=I[ph]=!0,I[Gp]=I[Wp]=I[nh]=I[Hp]=I[oh]=I[Yp]=I[Jp]=I[qp]=I[Qp]=I[Xp]=I[Kp]=I[Zp]=I[eh]=I[th]=I[rh]=!1;function hh(e){return Ye(e)&&Qo(e.length)&&!!I[Et(e)]}function vh(e){return function(t){return e(t)}}var oa=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Ot=oa&&typeof module=="object"&&module&&!module.nodeType&&module,yh=Ot&&Ot.exports===oa,Zr=yh&&Lo.process,mh=function(){try{var e=Ot&&Ot.require&&Ot.require("util").types;return e||Zr&&Zr.binding&&Zr.binding("util")}catch{}}();const aa=mh;var ia=aa&&aa.isTypedArray,gh=ia?vh(ia):hh;const sa=gh;var bh=Object.prototype,_h=bh.hasOwnProperty;function jh(e,t){var r=Je(e),n=!r&&Kr(e),o=!r&&!n&&na(e),a=!r&&!n&&!o&&sa(e),i=r||n||o||a,s=i?Dp(e.length,String):[],u=s.length;for(var l in e)(t||_h.call(e,l))&&!(i&&(l=="length"||o&&(l=="offset"||l=="parent")||a&&(l=="buffer"||l=="byteLength"||l=="byteOffset")||Jo(l,u)))&&s.push(l);return s}function Eh(e,t){return function(r){return e(t(r))}}function Oh(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var Sh=Object.prototype,Ch=Sh.hasOwnProperty;function wh(e){if(!Ae(e))return Oh(e);var t=Xo(e),r=[];for(var n in e)n=="constructor"&&(t||!Ch.call(e,n))||r.push(n);return r}function ca(e){return Xr(e)?jh(e,!0):wh(e)}var xh=qr(Object,"create");const St=xh;function Rh(){this.__data__=St?St(null):{},this.size=0}function Nh(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var Th="__lodash_hash_undefined__",Ah=Object.prototype,Mh=Ah.hasOwnProperty;function $h(e){var t=this.__data__;if(St){var r=t[e];return r===Th?void 0:r}return Mh.call(t,e)?t[e]:void 0}var Ph=Object.prototype,Dh=Ph.hasOwnProperty;function kh(e){var t=this.__data__;return St?t[e]!==void 0:Dh.call(t,e)}var Ih="__lodash_hash_undefined__";function Fh(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=St&&t===void 0?Ih:t,this}function Me(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Me.prototype.clear=Rh,Me.prototype.delete=Nh,Me.prototype.get=$h,Me.prototype.has=kh,Me.prototype.set=Fh;function Lh(){this.__data__=[],this.size=0}function zt(e,t){for(var r=e.length;r--;)if(Ut(e[r][0],t))return r;return-1}var Bh=Array.prototype,Uh=Bh.splice;function zh(e){var t=this.__data__,r=zt(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():Uh.call(t,r,1),--this.size,!0}function Vh(e){var t=this.__data__,r=zt(t,e);return r<0?void 0:t[r][1]}function Gh(e){return zt(this.__data__,e)>-1}function Wh(e,t){var r=this.__data__,n=zt(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}function ge(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}ge.prototype.clear=Lh,ge.prototype.delete=zh,ge.prototype.get=Vh,ge.prototype.has=Gh,ge.prototype.set=Wh;var Hh=qr(We,"Map");const ua=Hh;function Yh(){this.size=0,this.__data__={hash:new Me,map:new(ua||ge),string:new Me}}function Jh(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Vt(e,t){var r=e.__data__;return Jh(t)?r[typeof t=="string"?"string":"hash"]:r.map}function qh(e){var t=Vt(this,e).delete(e);return this.size-=t?1:0,t}function Qh(e){return Vt(this,e).get(e)}function Xh(e){return Vt(this,e).has(e)}function Kh(e,t){var r=Vt(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}function qe(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}qe.prototype.clear=Yh,qe.prototype.delete=qh,qe.prototype.get=Qh,qe.prototype.has=Xh,qe.prototype.set=Kh;function la(e){return e==null?"":Go(e)}var Zh=Eh(Object.getPrototypeOf,Object);const fa=Zh;var ev="[object Object]",tv=Function.prototype,rv=Object.prototype,da=tv.toString,nv=rv.hasOwnProperty,ov=da.call(Object);function Qe(e){if(!Ye(e)||Et(e)!=ev)return!1;var t=fa(e);if(t===null)return!0;var r=nv.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&da.call(r)==ov}function av(e,t,r){var n=-1,o=e.length;t<0&&(t=-t>o?0:o+t),r=r>o?o:r,r<0&&(r+=o),o=t>r?0:r-t>>>0,t>>>=0;for(var a=Array(o);++n<o;)a[n]=e[n+t];return a}function iv(e,t,r){var n=e.length;return r=r===void 0?n:r,!t&&r>=n?e:av(e,t,r)}var sv="\\ud800-\\udfff",cv="\\u0300-\\u036f",uv="\\ufe20-\\ufe2f",lv="\\u20d0-\\u20ff",fv=cv+uv+lv,dv="\\ufe0e\\ufe0f",pv="\\u200d",hv=RegExp("["+pv+sv+fv+dv+"]");function pa(e){return hv.test(e)}function vv(e){return e.split("")}var ha="\\ud800-\\udfff",yv="\\u0300-\\u036f",mv="\\ufe20-\\ufe2f",gv="\\u20d0-\\u20ff",bv=yv+mv+gv,_v="\\ufe0e\\ufe0f",jv="["+ha+"]",en="["+bv+"]",tn="\\ud83c[\\udffb-\\udfff]",Ev="(?:"+en+"|"+tn+")",va="[^"+ha+"]",ya="(?:\\ud83c[\\udde6-\\uddff]){2}",ma="[\\ud800-\\udbff][\\udc00-\\udfff]",Ov="\\u200d",ga=Ev+"?",ba="["+_v+"]?",Sv="(?:"+Ov+"(?:"+[va,ya,ma].join("|")+")"+ba+ga+")*",Cv=ba+ga+Sv,wv="(?:"+[va+en+"?",en,ya,ma,jv].join("|")+")",xv=RegExp(tn+"(?="+tn+")|"+wv+Cv,"g");function Rv(e){return e.match(xv)||[]}function Nv(e){return pa(e)?Rv(e):vv(e)}function Tv(e){return function(t){t=la(t);var r=pa(t)?Nv(t):void 0,n=r?r[0]:t.charAt(0),o=r?iv(r,1).join(""):t.slice(1);return n[e]()+o}}var Av=Tv("toUpperCase");const Mv=Av;function $v(e){return Mv(la(e).toLowerCase())}function Pv(){this.__data__=new ge,this.size=0}function Dv(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function kv(e){return this.__data__.get(e)}function Iv(e){return this.__data__.has(e)}var Fv=200;function Lv(e,t){var r=this.__data__;if(r instanceof ge){var n=r.__data__;if(!ua||n.length<Fv-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new qe(n)}return r.set(e,t),this.size=r.size,this}function Xe(e){var t=this.__data__=new ge(e);this.size=t.size}Xe.prototype.clear=Pv,Xe.prototype.delete=Dv,Xe.prototype.get=kv,Xe.prototype.has=Iv,Xe.prototype.set=Lv;var _a=typeof exports=="object"&&exports&&!exports.nodeType&&exports,ja=_a&&typeof module=="object"&&module&&!module.nodeType&&module,Bv=ja&&ja.exports===_a,Ea=Bv?We.Buffer:void 0,Oa=Ea?Ea.allocUnsafe:void 0;function Uv(e,t){if(t)return e.slice();var r=e.length,n=Oa?Oa(r):new e.constructor(r);return e.copy(n),n}var zv=We.Uint8Array;const Sa=zv;function Vv(e){var t=new e.constructor(e.byteLength);return new Sa(t).set(new Sa(e)),t}function Gv(e,t){var r=t?Vv(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}function Wv(e){return typeof e.constructor=="function"&&!Xo(e)?fp(fa(e)):{}}function Hv(e){return function(t,r,n){for(var o=-1,a=Object(t),i=n(t),s=i.length;s--;){var u=i[e?s:++o];if(r(a[u],u,a)===!1)break}return t}}var Yv=Hv();const Jv=Yv;function rn(e,t,r){(r!==void 0&&!Ut(e[t],r)||r===void 0&&!(t in e))&&Qr(e,t,r)}function qv(e){return Ye(e)&&Xr(e)}function nn(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function Qv(e){return Rp(e,ca(e))}function Xv(e,t,r,n,o,a,i){var s=nn(e,r),u=nn(t,r),l=i.get(u);if(l){rn(e,r,l);return}var f=a?a(s,u,r+"",e,t,i):void 0,d=f===void 0;if(d){var p=Je(u),v=!p&&na(u),b=!p&&!v&&sa(u);f=u,p||v||b?Je(s)?f=s:qv(s)?f=pp(s):v?(d=!1,f=Uv(u,!0)):b?(d=!1,f=Gv(u,!0)):f=[]:Qe(u)||Kr(u)?(f=s,Kr(s)?f=Qv(s):(!Ae(s)||Yr(s))&&(f=Wv(u))):d=!1}d&&(i.set(u,f),o(f,u,n,a,i),i.delete(u)),rn(e,r,f)}function Ca(e,t,r,n,o){e!==t&&Jv(t,function(a,i){if(o||(o=new Xe),Ae(a))Xv(e,t,i,r,Ca,n,o);else{var s=n?n(nn(e,i),a,i+"",e,t,o):void 0;s===void 0&&(s=a),rn(e,i,s)}},ca)}var Kv=$p(function(e,t,r){Ca(e,t,r)});const Zv=Kv;function ey(e){const t=e.prototype;return!!(t&&t.isReactComponent)}function ty(e){var t,r;const n=typeof Symbol=="function"&&Symbol.for?Symbol.for("react.forward_ref"):60112;return(e==null?void 0:e.$$typeof)===n||((t=e==null?void 0:e.prototype)==null?void 0:t.isReactComponent)||((r=e==null?void 0:e.prototype)==null?void 0:r.setState)||e._forwardRef}function ry(e){class t extends x.Component{render(){return x.createElement(e,this.props)}}return t.displayName=e.displayName,t}const Ke=(e,t)=>{const r=n=>{const o=`
|
|
31
|
-
${Object.keys(t).map(a=>`const ${a} = $$context['${a}'];`).join(`
|
|
32
|
-
`)}
|
|
33
|
-
return ${n};
|
|
34
|
-
`;return new Function("$$context",o)(t)};try{return r(e)}catch(n){console.warn(n);const o=`[${e}] expression run failed`;return console.warn(o),null}},ny=(e,t,r)=>function(...n){try{const o=`
|
|
35
|
-
var f = ${e};
|
|
36
|
-
var args = Array.from(arguments);
|
|
37
|
-
var __$$storeManager__ = args.pop();
|
|
38
|
-
var $$context = args.pop();
|
|
39
|
-
$$context.stateManager = __$$storeManager__.getStateSnapshot();
|
|
40
|
-
return f.apply(f, args)
|
|
41
|
-
`;new Function(o)(...n,t,r)}catch(o){console.warn(o)}},wa=(e,t)=>{const r={};return t.forEach((n,o)=>{r[n]=e[o]}),r},xa=e=>{const t={};return Object.keys(e).forEach(r=>{let n=r.replace("-webkit","Webkit");n=n.replace("-ms","ms"),n=n.replace("-moz","Moz"),n=n.replace("-o","O");let o=n.split("-");o.length>=2&&(o=o.map((a,i)=>i!==0?$v(a):a)),t[o.join("")]=e[r]}),t},Ra=e=>{let t="";return Object.keys(e).forEach(r=>{t+=`${r}:${e[r]};`}),t},Gt="DYNAMIC",oy=["$$context","$$nodeModel"],Na=e=>{let t;const r=new Set,n=(i,s)=>{const u=typeof i=="function"?i(t):i;if(!Object.is(u,t)){const l=t;t=s??typeof u!="object"?u:Object.assign({},t,u),r.forEach(f=>f(t,l))}},o=()=>t,a={setState:n,getState:o,subscribe:i=>(r.add(i),()=>r.delete(i)),destroy:()=>{({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),r.clear()}};return t=e(n,o,a),a},ay=e=>e?Na(e):Na;var iy=e=>(({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&console.warn("[DEPRECATED] Default export is deprecated. Instead use import { createStore } from 'zustand/vanilla'."),ay(e));class sy{constructor(){j(this,"storeMap",new Map)}addStore(t,r){const n=iy(r);return this.storeMap.set(t,n),n.name=t,n}setStore(t,r){this.storeMap.set(t,r)}removeStore(t){this.storeMap.delete(t)}getStore(t){return this.storeMap.get(t)}connect(t,r){const n=this.storeMap.get(t);return n?n.subscribe(r):(console.warn("store not exits"),()=>{})}getStateSnapshot(){const t={};return this.storeMap.forEach((r,n)=>{t[n]={state:r.getState(),updateState:o=>{r.setState(o)}}}),t}destroy(){this.storeMap.forEach(t=>{t.destroy()}),this.storeMap=new Map}}class Ta{constructor(){j(this,"renderMode","normal"),j(this,"components",{}),j(this,"storeManager",new sy),j(this,"runtimeComponentCache",new Map),j(this,"onGetRef"),j(this,"onGetComponent"),j(this,"onComponentMount"),j(this,"onComponentDestroy"),j(this,"processNodeConfigHook")}getComponent(t){var r;const n=t.value.componentName;let o=this.components[n]||(()=>`Component [${n}] not found`);return ty(o)||(o=ry(o),this.components[n]=o),this.onGetComponent&&(o=(r=this.onGetComponent)==null?void 0:r.call(this,o,t)),o}getContext(t={},r){let n=t;return r&&(n={...t},n.__proto__=r||null),n}pageRender(t,{components:r,onGetRef:n,$$context:o={},onGetComponent:a,onComponentMount:i,onComponentDestroy:s,renderMode:u,processNodeConfigHook:l}){this.renderMode=u,this.components=r,this.onGetRef=n,this.onGetComponent=a,this.onComponentMount=i,this.onComponentDestroy=s,this.processNodeConfigHook=l;const f=t.value.componentsTree,d=this.getComponent(f),p=this.convertModelToComponent(d,t.value.componentsTree),v={},b=f.props;return Object.keys(b).forEach(_=>{v[_]=b[_].value}),v.$$context=o,this.render(p,v)}transformProps(t={},{$$context:r}){const n=t,o=i=>{if(Array.isArray(i))return i.map(s=>o(s));if(Vr(i))return o(i.value);if(Od(i)){const s=i.value,u=s.value;if(!u)return console.warn("slot value is null, this maybe cause some error, pls check it",t),()=>{};const l=f=>{const d=`${f.id}-${Gt}`;if(this.runtimeComponentCache.get(f.id))return{key:d,component:this.runtimeComponentCache.get(f.id)};const p=this.getComponent(f),v=this.convertModelToComponent(p,f),b=s.params||[];return{component:(..._)=>{const E=wa(_,b),w=this.getContext({params:E},r);return this.render(v,{$$context:w,key:d})},key:d}};if(Array.isArray(u)){const f=u==null?void 0:u.map(d=>l(d));return(...d)=>f.map(p=>ey(p.component)?x.createElement(p.component,{$$context:r,key:p.key}):p.component(...d))}else return l(u).component}else{if(Ne(i))return Ke(i.value,r||{});if(jd(i))return ny(i.value,r,this.storeManager);if(Qe(i)){let s=i;Vr(i)&&(s=i.value);const u=s,l={};return Object.keys(s).forEach(f=>{l[f]=o(u[f])}),l}else return i}},a={};return Object.keys(n).forEach(i=>{const s=n[i];a[i]=o(s)}),a}collectSpecialProps(t={},r){const n=[],o=(a,i)=>{let s=i;Vr(i)&&(s=i.value),r(s)?n.push({keyPath:a,val:s}):Je(s)?s.forEach((u,l)=>{o([...a,String(l)],u)}):Qe(s)&&Object.keys(s).forEach(u=>{o([...a,u],s[u])})};return o(["$root"],t),n}convertModelToComponent(t,r){const n=this;class o extends x.Component{constructor(i){super(i),j(this,"_CONDITION",!0),j(this,"_DESIGN_BOX",!1),j(this,"_NODE_MODEL",r),j(this,"_NODE_ID",r.id),j(this,"UNIQUE_ID",`${r.id}_${he()}`),j(this,"targetComponentRef"),j(this,"listenerHandle",[]),j(this,"storeState"),j(this,"staticState",{}),j(this,"storeListenDisposeLint",[]),j(this,"domHeader"),j(this,"mediaStyleDomMap",{}),j(this,"updateState",l=>{this.storeState.setState(l),this.forceUpdate()}),j(this,"getStyleDomById",l=>{const f=this.mediaStyleDomMap;let d=f[l];return d||(d=document.createElement("style"),d.type="text/css",f[l]=d),d.id=l,d}),j(this,"addMediaCSS",()=>{var l;let f=this.domHeader;if(f||(f=(l=document.getElementsByTagName("head"))==null?void 0:l[0],this.domHeader=f),!this.domHeader)return;const d=this._NODE_MODEL.value.css;d&&d.value.forEach(p=>{var v;const b=`${this.UNIQUE_ID}_${p.state}`;let _=`.${d.class}`;if(p.state!=="normal"&&(_=`${_}:${p.state}`),Object.keys(p.style).length!==0){const E=this.getStyleDomById(b);E.innerText=`${_} { ${Ra(p.style)} }`,f==null||f.appendChild(E)}(v=p.media)!=null&&v.length&&p.media.forEach(E=>{const w=`${b}_${E.type}_${E.value}`,S=this.getStyleDomById(w);S.media=`screen and (${E.type}:${E.value}px)`,S.innerHTML=`${_} { ${Ra(E.style)} }`,f==null||f.appendChild(S)})})}),j(this,"removeMediaCSS",()=>{const l=this.mediaStyleDomMap;Object.keys(l).forEach(f=>{var d;(d=this.domHeader)==null||d.removeChild(l[f])})}),j(this,"rebuildNode",()=>{this.storeListenDisposeLint.forEach(l=>l()),this.removeMediaCSS(),this.connectStore(),this.addMediaCSS(),this.forceUpdate()}),this.targetComponentRef=x.createRef(),this.state=r.value.state||{};const s=r.value.stateName||r.id,u=n.storeManager.getStore(s);u?(this.storeState=u,u.setState({...r.value.state||{}})):this.storeState=n.storeManager.addStore(s,()=>({...r.value.state||{}})),this.storeState.subscribe(l=>{this.setState({...l})}),this.connectStore()}connectStore(){const i=n.collectSpecialProps(r.props,d=>!!Ne(d)),s=n.collectSpecialProps({css:r.value.css,class:r.value.classNames},d=>!!Ne(d)),u=[...i,...s].map(d=>{const p=d.val,v=/\$\$context.stateManager\.(.+?)\./gim.exec(p.value);return v!=null&&v.length?v[1]:""}).filter(Boolean),l=Array.from(new Set(u)),f=[];l.length&&l.forEach(d=>{n.storeManager.getStore(d)||(n.storeManager.addStore(d,()=>({})),console.log(n.storeManager,d,"not exits"));const p=n.storeManager.connect(d,()=>{this.forceUpdate()});f.push(p)}),this.storeListenDisposeLint=f}componentDidMount(){var i;this.addMediaCSS(),n.onGetRef&&n.onGetRef(this.targetComponentRef,r,this),(i=n.onComponentMount)==null||i.call(n,this,r);const s=()=>{n.storeManager.setStore(r.value.stateName||r.id,this.storeState),this.storeState.setState({...this.state,...r.value.state||{}}),this.rebuildNode()};r.onChange(s)}componentWillUnmount(){var i;this.storeListenDisposeLint.forEach(s=>s()),this.removeMediaCSS(),(i=n.onComponentDestroy)==null||i.call(n,this,r)}render(){var i;const{$$context:s,...u}=this.props,l={key:r.id,...r.props,...u},f={state:this.state||{},updateState:this.updateState,staticState:this.staticState};r.value.componentName===Ve.ROOT_CONTAINER&&(f.globalState=this.state,f.updateGlobalState=this.updateState),f.stateManager=n.storeManager.getStateSnapshot();const d=n.getContext(f,s),p=r.value.loop;let v=[];if(p&&p.open){this.targetComponentRef.current=[];let J=p.data||[];if(Ne(p.data)){const N=p.data;J=Ke(N.value,d||{})}return v=J.map((...N)=>{var ae;const le=N[1],Ct=[p.forName||"item",p.forIndex||"index"],Ht=wa(N,Ct);let ee="loopData";p.name&&(ee=`${ee}${p.name}`);const te=n.getContext({[ee]:Ht,staticState:this.staticState},d),H=n.transformProps(l,{$$context:te}),Yt=((ae=r.value.classNames)==null?void 0:ae.map(re=>{var _e;const tt=re.name;return Ne(re.status)&&Ke(String(((_e=re.status)==null?void 0:_e.value)||""),te)?tt:""}))||[];let Ze=`${H.className??""} ${Yt.join(" ")}`.trim();r.value.css&&(Ze=`${r.value.css.class} ${Ze}`.trim()),H.className=Ze;const Jt=n.transformProps(r.value.style,{$$context:te});r.value.style&&(H.style=xa(Jt||{}));const{children:$e}=H;let et=[];if($e!==void 0)delete H.children,et=Array.isArray($e)?$e:[$e];else{const re=[];r.value.children.forEach((_e,tt)=>{const on=n.buildComponent(_e,{$$context:te,idx:tt});re.push(on)}),et=re}if(H.key=`${H.key}-${le}`,Ne(p.key)){const re=p.key,_e=Ke(re.value,te||{});H.key+=`-${_e}`}return H.ref=re=>{this.targetComponentRef.current=this.targetComponentRef.current||[],this.targetComponentRef.current[le]=re},n.render(t,H,...et)}),v}const b=n.transformProps(l,{$$context:d}),{children:_}=b;let E=[];if(_!==void 0)delete b.children,E=Array.isArray(_)?_:[_];else{const J=[];r.value.children.forEach((N,ae)=>{const le=n.buildComponent(N,{$$context:d,idx:ae});J.push(le)}),E=J}b.ref=this.targetComponentRef;const w=((i=r.value.classNames)==null?void 0:i.map(J=>{var N;const ae=J.name;return Ne(J.status)&&Ke(((N=J.status)==null?void 0:N.value)||"",d)?ae:""}))||[];let S=`${b.className??""} ${w.join(" ")}`.trim();r.value.css&&(S=`${r.value.css.class} ${S}`.trim()),b.className=S;const W=n.transformProps(r.value.style,{$$context:d});r.value.style&&(b.style=xa(W||{}));let D=r.value.condition??!0;typeof D!="boolean"&&(D=Ke(D.value,d||{}));let U={condition:D,props:b};n.processNodeConfigHook&&(U=n.processNodeConfigHook(U,r));const Z=n.render(t,U.props,...E);return this._CONDITION=U.condition,U.condition?Z:Pe("div",{style:{display:"none"},children:Z})}}return j(o,"__CP_TYPE__",Gt),o.displayName=`${r.value.componentName}Dynamic`,o}buildComponent(t,{$$context:r={}}){const n=this.runtimeComponentCache;return typeof t=="string"?this.render(t):Ed(t)?(({currentNode:o})=>{const a=o.value.id;let i=null;if(n.get(a))i=n.get(a);else{const l=this.getComponent(o);i=this.convertModelToComponent(l,o)}!n.get(a)&&this.renderMode!=="design"&&n.set(a,i);const s=`${a}-${Gt}`,u={$$context:r,$$nodeModel:t,key:s};return this.render(i,u)})({currentNode:t}):void 0}render(t,r={},...n){return typeof t=="string"||typeof t=="number"?String(t):(oy.forEach(o=>{o in r&&t.__CP_TYPE__!==Gt&&delete r[o]}),x.createElement(t,r,...n))}clear(){this.runtimeComponentCache.clear(),this.storeManager.destroy()}}const cy=gn(new Ta),uy=["a","abbr","acronym","address","applet","area","article","aside","audio","b","base","basefont","bdi","bdo","bgsound","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","command","content","data","datalist","dd","del","details","dfn","dialog","dir","div","dl","dt","element","em","embed","fieldset","figcaption","figure","font","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","image","img","input","ins","isindex","kbd","keygen","label","legend","li","link","listing","main","map","mark","marquee","math","menu","menuitem","meta","meter","multicol","nav","nextid","nobr","noembed","noframes","noscript","object","ol","optgroup","option","output","p","param","picture","plaintext","pre","progress","q","rb","rbc","rp","rt","rtc","ruby","s","samp","script","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","svg","table","tbody","td","template","textarea","tfoot","th","thead","time","title","tr","track","tt","u","ul","var","video","wbr","xmp"],be=e=>{const t={};return e.forEach(r=>{t[r.key]=r.value}),t},ly=[...uy,...id],fy=ly.reduce((e,t)=>(e[t]=({children:r,$$attributes:n=[],...o})=>{let a=r;return Array.isArray(r)||(a=[r]),x.createElement(t,{...o,...be(n)},...a)},e),{}),dy=({children:e,width:t,height:r,$$attributes:n=[],...o})=>{let a=e;Array.isArray(e)||(a=[e]),a=a.filter(l=>l!==void 0);const{style:i={},...s}=be(n),u={height:r,width:t,...i,...o.style||{}};return x.createElement("div",{...o,...s,style:u},...a)},py=({children:e,$$attributes:t=[],...r})=>{let n=e;return Array.isArray(e)||(n=[e]),x.createElement("canvas",{...r,...be(t)},...n)},hy=({children:e,$$attributes:t=[],...r})=>{let n=e;return Array.isArray(e)||(n=[e]),x.createElement("img",{...r,...be(t)},...n)},vy=({children:e,$$attributes:t=[],...r})=>{let n=e;return Array.isArray(e)||(n=[e]),x.createElement("video",{...r,...be(t)},...n)},yy=({children:e,$$attributes:t=[],...r})=>{let n=e;return Array.isArray(e)||(n=[e]),x.createElement("video",{...r,...be(t)},...n)},my=({children:e,$$attributes:t=[],content:r,...n})=>Pe("span",{...n,...be(t),children:r}),gy=({children:e,$$attributes:t=[],afterMount:r,beforeDestroy:n,...o})=>{let a=e;return Array.isArray(e)||(a=[e]),x.useEffect(()=>(r==null||r(o),()=>{n==null||n(o)}),[]),x.createElement("div",{...o,...be(t)},...a)},by=({children:e,$$attributes:t=[],htmlTag:r="div",...n})=>{let o=e;return Array.isArray(e)||(o=[e]),x.createElement(r,{...n,...be(t)},...o)},_y={RootContainer:({children:e})=>e,...fy,CContainer:gy,CVideo:vy,CAudio:yy,CBlock:dy,CImage:hy,CText:my,CCanvas:py,CNativeTag:by};class jy{constructor(){j(this,"refMap",new Map)}get(t){return this.refMap.get(t)}add(t,r){this.refMap.set(t,r)}remove(t){this.refMap.delete(t)}destroy(){this.refMap.clear()}}class Aa extends x.Component{constructor(t){super(t),j(this,"refManager"),j(this,"dynamicComponentInstanceMap",new Map),j(this,"onGetRef",(r,n,o)=>{var a,i;(i=(a=this.props).onGetRef)==null||i.call(a,r,n,o),this.dynamicComponentInstanceMap.set(n.id,o),this.refManager.add(n.value.refId||n.id,r)}),j(this,"rerender",r=>{if(this.props.adapter.clear(),(r==null?void 0:r.nodeType)==="PAGE"&&r)this.setState({pageModel:r});else if(Qe(r)&&Fo(r)){const n=r;this.setState({pageModel:new Lt(n,{materials:this.state.pageModel.materialsModel.rawValue})})}}),this.state={pageModel:t.pageModel||new Lt(t.page)},this.refManager=new jy}getPageModel(){return this.state.pageModel}componentDidMount(){const{render:t}=this.props;t&&(t.ref.current=this)}componentWillUnmount(){this.refManager.destroy()}render(){const{props:t}=this,{adapter:r,onGetComponent:n,onComponentDestroy:o,onComponentMount:a}=t,{pageModel:i}=this.state;if(!i)return console.warn("pageModel is null"),null;const s={..._y,...t.components};return r.pageRender(i,{libs:{},components:s,onGetRef:this.onGetRef,onGetComponent:n,onComponentMount:a,onComponentDestroy:o,$$context:{refs:this.refManager},renderMode:t.renderMode,processNodeConfigHook:t.processNodeConfigHook})}}const Ey=()=>{const e=x.useRef(null);return{ref:e,rerender:function(...t){e.current&&e.current.rerender(...t)}}};class Oy extends x.Component{constructor(t){super(t),j(this,"onDoubleClick",()=>{this.setState({hasError:!1,error:null})}),this.state={hasError:!1,error:""}}static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,r){var n,o;(o=(n=this.props).onError)==null||o.call(n,r)}render(){if(this.state.hasError){const{onDoubleClick:t}=this,r=this.props.node.value;console.error(this.props.node,this.props.children);const n=yn("div",{style:{backgroundColor:"rgb(255 206 215 / 13%)",padding:"5px",color:"#ff0000b0",textAlign:"center",fontSize:"12px"},children:["Render error, node id: ",r.id,", node name:",r.title," component name:",r.title||r.componentName,yn("p",{children:["msg: ",String(this.state.error)]}),Pe("button",{onDoubleClick:t,style:{border:"1px solid rgba(100,100,100,0.1)",backgroundColor:"#fff",padding:"5px 10px",borderRadius:"2px",color:"gray",cursor:"pointer",marginTop:"5px"},children:"double click to refresh"}),Pe("div",{style:{display:"none"}})]});return x.createElement(this.props.targetComponent,{onlyRenderChild:!0},n)}return this.props.children}}class Ma{constructor(){j(this,"instanceMap",new Map)}get(t){return this.instanceMap.get(t)}add(t,r){const n=this.instanceMap.get(t);n?n.push(r):this.instanceMap.set(t,[r])}remove(t,r){const n=this.instanceMap.get(t);if(r!==void 0&&Array.isArray(n)){const o=n.filter(a=>a!==r);this.instanceMap.set(t,o)}else this.instanceMap.delete(t)}destroy(){this.instanceMap.clear()}}const $a=e=>{const{node:t}=e,r=x.useMemo(()=>{var s,u;const l=(u=(s=t.material)==null?void 0:s.value)==null?void 0:u.isContainer;return Qe(l)?l:{placeholder:"Drag the component to place it",width:"100%",height:"100%",style:{}}},[e.node]),{placeholder:n,height:o,width:a,style:i}=r;return Pe("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"rgba(200,200,200,0.1)",border:"1px solid rgba(0,0,0,0.1)",borderRadius:"2px",fontSize:"14px",color:"gray",cursor:"default",minWidth:"300px",minHeight:"50px",width:a,height:o,...i},children:n})};class Sy extends x.Component{constructor(t){super(t),j(this,"instanceManager",new Ma),j(this,"renderRef"),j(this,"dropPlaceholder",$a),j(this,"onGetComponent",(r,n)=>{const o=this;class a extends x.Component{constructor(){super(...arguments),j(this,"_DESIGN_BOX",!0),j(this,"_NODE_MODEL",n),j(this,"_NODE_ID",n.id),j(this,"_UNIQUE_ID",`${n.id}_${he()}`),j(this,"_STATUS")}componentDidMount(){o.instanceManager.add(n.id,this)}componentWillUnmount(){this._STATUS="DESTROY",o.instanceManager.remove(n.id,this)}render(){var s;const{children:u=[],onlyRenderChild:l,...f}=this.props;let d=u;return Je(u)||(d=[u]),!d.filter(Boolean).length&&((s=n.material)!=null&&s.value.isContainer||n.value.componentName===Ve.ROOT_CONTAINER)&&d.push(x.createElement(o.dropPlaceholder,{node:n})),l?d:x.createElement(r,f,...d)}}return x.forwardRef(function(i,s){return x.createElement(Oy,{node:n,targetComponent:a},x.createElement(a,{ref:s,...i}))})}),this.renderRef=x.createRef(),t.dropPlaceholder&&(this.dropPlaceholder=t.dropPlaceholder)}componentDidMount(){var t,r;(r=(t=this.props).onMount)==null||r.call(t,this)}getPageModel(){var t;return(t=this.renderRef.current)==null?void 0:t.state.pageModel}rerender(t){var r;return(r=this.renderRef.current)==null?void 0:r.rerender(t)}getInstancesById(t,r){let n=[...this.instanceManager.get(t)||[]];return r!==void 0&&(n=n.filter(o=>r===(o==null?void 0:o._UNIQUE_ID))),n}getInstanceByDom(t){const r=Pa(t);if(!r)return null;const n=Da(r);return(n==null?void 0:n.stateNode)||null}getDomsById(t,r){const n=this.getInstancesById(t),o=[];return n==null||n.forEach(a=>{if((a==null?void 0:a._STATUS)==="DESTROY")return;const i=Xa.findDOMNode(a);if(i&&!(i instanceof Text))if(r){const s=Array.from(i.querySelectorAll(r));o.push(...s)}else o.push(i)}),o}getDomRectById(t,r){return this.getDomsById(t,r).map(n=>n==null?void 0:n.getBoundingClientRect()).filter(Boolean)}render(){const{props:t,onGetComponent:r}=this,{render:n,...o}=t;return n&&(n.ref.current=this),Pe(Aa,{onGetComponent:r,...o,processNodeConfigHook:(a,i)=>{var s,u;if(i.nodeType!=="NODE")return a;const{props:l,condition:f}=a;let d={...l};const p=((s=i.value.configure)==null?void 0:s.devState)||{},v=(u=i.material)==null?void 0:u.value.fixedProps;if(v!==void 0){if(Qe(v))d={...d,...v};else if(typeof v=="function"){const _=v(d);d={...d,..._}}}let b=f;return p.condition===!1&&(b=p.condition),{props:Zv(d,p.props||{}),condition:b}},ref:this.renderRef})}}const Pa=e=>{if(!e)return null;const t=Object.keys(e).find(r=>r.startsWith("__reactInternalInstance$")||r.startsWith("__reactFiber$"))||"";return t?e[t]:Pa(e.parentElement)},Da=e=>{var t;return e?(t=e==null?void 0:e.stateNode)!=null&&t._DESIGN_BOX?e:Da(e.return):null},Cy=()=>{const e=x.useRef(null);return{ref:e,rerender:function(...t){e.current&&e.current.rerender(...t)},getInstancesById(t,r){var n;return((n=e.current)==null?void 0:n.getInstancesById(t,r))||[]},getInstanceByDom(t){var r;return((r=e.current)==null?void 0:r.getInstanceByDom(t))||null},getDomsById(t,r){var n;return((n=e.current)==null?void 0:n.getDomsById(t,r))||[]},getDomRectById(t,r){var n;return((n=e.current)==null?void 0:n.getDomRectById(t,r))||[]}}};var wy=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},Wt={},xy={get exports(){return Wt},set exports(e){Wt=e}};(function(e,t){(function(r,n){e.exports=n()})(wy,function(){var r=function(){},n={},o={},a={};function i(p,v){p=p.push?p:[p];var b=[],_=p.length,E=_,w,S,W,D;for(w=function(U,Z){Z.length&&b.push(U),E--,E||v(b)};_--;){if(S=p[_],W=o[S],W){w(S,W);continue}D=a[S]=a[S]||[],D.push(w)}}function s(p,v){if(p){var b=a[p];if(o[p]=v,!!b)for(;b.length;)b[0](p,v),b.splice(0,1)}}function u(p,v){p.call&&(p={success:p}),v.length?(p.error||r)(v):(p.success||r)(p)}function l(p,v,b,_){var E=document,w=b.async,S=(b.numRetries||0)+1,W=b.before||r,D=p.replace(/[\?|#].*$/,""),U=p.replace(/^(css|img|module|nomodule)!/,""),Z,J,N;if(_=_||0,/(^css!|\.css$)/.test(D))N=E.createElement("link"),N.rel="stylesheet",N.href=U,Z="hideFocus"in N,Z&&N.relList&&(Z=0,N.rel="preload",N.as="style");else if(/(^img!|\.(png|gif|jpg|svg|webp)$)/.test(D))N=E.createElement("img"),N.src=U;else if(N=E.createElement("script"),N.src=U,N.async=w===void 0?!0:w,J="noModule"in N,/^module!/.test(D)){if(!J)return v(p,"l");N.type="module"}else if(/^nomodule!/.test(D)&&J)return v(p,"l");N.onload=N.onerror=N.onbeforeload=function(ae){var le=ae.type[0];if(Z)try{N.sheet.cssText.length||(le="e")}catch(Ct){Ct.code!=18&&(le="e")}if(le=="e"){if(_+=1,_<S)return l(p,v,b,_)}else if(N.rel=="preload"&&N.as=="style")return N.rel="stylesheet";v(p,le,ae.defaultPrevented)},W(p,N)!==!1&&E.head.appendChild(N)}function f(p,v,b){p=p.push?p:[p];var _=p.length,E=_,w=[],S,W;for(S=function(D,U,Z){if(U=="e"&&w.push(D),U=="b")if(Z)w.push(D);else return;_--,_||v(w)},W=0;W<E;W++)l(p[W],S,b)}function d(p,v,b){var _,E;if(v&&v.trim&&(_=v),E=(_?b:v)||{},_){if(_ in n)throw"LoadJS";n[_]=!0}function w(S,W){f(p,function(D){u(E,D),S&&u({success:S,error:W},D),s(_,D)},E)}if(E.returnPromise)return new Promise(w);w()}return d.ready=function(p,v){return i(p,function(b){u(v,b)}),d},d.done=function(p){s(p,[])},d.reset=function(){n={},o={},a={}},d.isDefined=function(p){return p in n},d})})(xy);class Ry{constructor(t,r){j(this,"assets"),j(this,"loadStatus"),j(this,"win",window),j(this,"_onSuccessList",[]),j(this,"_onErrorList",[]),this.assets=t,this.loadStatus="INIT",r!=null&&r.window&&(this.win=r.window)}load(){const t=this.assets||[],r=[];for(let n=0;n<t.length;n++){const o=t[n];o.id||(o.id=he()),r.push(o.id);const a=o.resources.map(i=>i.src);Wt(a,o.id,{async:!1,before:(i,s)=>(this.win.document.body.appendChild(s),!1)})}if(t.length===0){this._onSuccessList.forEach(n=>n());return}return setTimeout(()=>{Wt.ready(r,{success:()=>{this._onSuccessList.forEach(n=>n())},error:n=>{this._onErrorList.forEach(o=>o(n))}})},0),this}onSuccess(t){return this._onSuccessList.push(t),this}onError(t){return this._onErrorList.push(t),this}}return Object.freeze(Object.defineProperty({__proto__:null,AssetLoader:Ry,ComponentInstanceManager:Ma,DefaultDropPlaceholder:$a,DefineReactAdapter:Ta,DesignRender:Sy,ReactAdapter:cy,Render:Aa,getAdapter:gn,useDesignRender:Cy,useRender:Ey},Symbol.toStringTag,{value:"Module"}))});
|
|
42
|
-
//# sourceMappingURL=render.umd.js.map
|