x-runtime-lib 0.9.29 → 0.9.31
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/components/element/ui/card/v1/index.vue.d.ts +4 -4
- package/dist/components/element/ui/expansionPanel/v1/index.vue.d.ts +18 -0
- package/dist/components/element/ui/expansionPanels/v1/index.vue.d.ts +14 -0
- package/dist/components/element/ui/tooltip/v1/index.vue.d.ts +2 -2
- package/dist/{i18n-en.hv63466o.js → i18n-en.guhc0a0t.js} +6 -0
- package/dist/{i18n-zhHans.k3uetyc5.js → i18n-zhHans.gnwfze9y.js} +6 -0
- package/dist/index.d.ts +977 -6
- package/dist/index.js +2768 -2418
- package/dist/{vendor.iv3gta0j.js → vendor.nxcr0zfk.js} +20343 -20327
- package/package.json +3 -1
- package/dist/api/computebase/index.d.ts +0 -11
- package/dist/api/computebase/instance.d.ts +0 -3
- package/dist/components/editor/index.d.ts +0 -3
- package/dist/components/element/3d/camera/index.d.ts +0 -3
- package/dist/components/element/3d/controls/index.d.ts +0 -4
- package/dist/components/element/3d/geometry/index.d.ts +0 -7
- package/dist/components/element/3d/index.d.ts +0 -6
- package/dist/components/element/3d/light/index.d.ts +0 -5
- package/dist/components/element/3d/material/index.d.ts +0 -3
- package/dist/components/element/3d/object/index.d.ts +0 -3
- package/dist/components/element/chart/index.d.ts +0 -3
- package/dist/components/element/dynamic/index.d.ts +0 -7
- package/dist/components/element/dynamic/internal/scene/index.d.ts +0 -2
- package/dist/components/element/index.d.ts +0 -4
- package/dist/components/element/ui/index.d.ts +0 -65
- package/dist/composables/common/index.d.ts +0 -1
- package/dist/composables/common/syncRef/index.d.ts +0 -2
- package/dist/composables/element/core/activator.d.ts +0 -3
- package/dist/composables/element/core/breakpoint.d.ts +0 -3
- package/dist/composables/element/core/delayAttach.d.ts +0 -3
- package/dist/composables/element/core/elementBase.d.ts +0 -38
- package/dist/composables/element/core/elementDebug.d.ts +0 -5
- package/dist/composables/element/core/elementMethod.d.ts +0 -10
- package/dist/composables/element/core/elementProperty.d.ts +0 -5
- package/dist/composables/element/core/elementPropertyBreakpoint.d.ts +0 -5
- package/dist/composables/element/core/elementPropertyColor.d.ts +0 -5
- package/dist/composables/element/core/elementPropertyEager.d.ts +0 -5
- package/dist/composables/element/core/elementPropertyTransient.d.ts +0 -3
- package/dist/composables/element/core/elementSlotMethod.d.ts +0 -12
- package/dist/composables/element/core/elementSlotProperty.d.ts +0 -3
- package/dist/composables/element/core/elementSlotRender.d.ts +0 -7
- package/dist/composables/element/core/index.d.ts +0 -14
- package/dist/composables/element/index.d.ts +0 -2
- package/dist/composables/element/piece/3d/transform/v1/index.d.ts +0 -7
- package/dist/composables/element/piece/chart/legend/v1/index.d.ts +0 -8
- package/dist/composables/element/piece/chart/series/v1/index.d.ts +0 -7
- package/dist/composables/element/piece/chart/title/v1/index.d.ts +0 -9
- package/dist/composables/element/piece/chart/xAxis/v1/index.d.ts +0 -10
- package/dist/composables/element/piece/chart/yAxis/v1/index.d.ts +0 -10
- package/dist/composables/element/piece/index.d.ts +0 -10
- package/dist/composables/element/piece/ui/border/v1/index.d.ts +0 -5
- package/dist/composables/element/piece/ui/margin/v1/index.d.ts +0 -9
- package/dist/composables/element/piece/ui/padding/v1/index.d.ts +0 -9
- package/dist/composables/element/piece/ui/size/v1/index.d.ts +0 -11
- package/dist/composables/runtime/color.d.ts +0 -4
- package/dist/composables/runtime/depend.d.ts +0 -3
- package/dist/composables/runtime/index.d.ts +0 -5
- package/dist/composables/runtime/runtime.d.ts +0 -4
- package/dist/composables/runtime/sandbox.d.ts +0 -9
- package/dist/composables/runtime/theme.d.ts +0 -3
- package/dist/echarts/index.d.ts +0 -6
- package/dist/element/3d/camera/index.d.ts +0 -2
- package/dist/element/3d/camera/orthographicCamera/v1/index.d.ts +0 -1
- package/dist/element/3d/camera/orthographicCamera/v1/spawn.d.ts +0 -2
- package/dist/element/3d/camera/perspectiveCamera/v1/index.d.ts +0 -1
- package/dist/element/3d/camera/perspectiveCamera/v1/spawn.d.ts +0 -2
- package/dist/element/3d/controls/index.d.ts +0 -3
- package/dist/element/3d/controls/keyboardControls/v1/index.d.ts +0 -1
- package/dist/element/3d/controls/keyboardControls/v1/spawn.d.ts +0 -2
- package/dist/element/3d/controls/mapControls/v1/index.d.ts +0 -1
- package/dist/element/3d/controls/mapControls/v1/spawn.d.ts +0 -2
- package/dist/element/3d/controls/orbitControls/v1/index.d.ts +0 -1
- package/dist/element/3d/controls/orbitControls/v1/spawn.d.ts +0 -2
- package/dist/element/3d/geometry/boxGeometry/v1/index.d.ts +0 -1
- package/dist/element/3d/geometry/boxGeometry/v1/spawn.d.ts +0 -2
- package/dist/element/3d/geometry/index.d.ts +0 -2
- package/dist/element/3d/geometry/sphereGeometry/v1/index.d.ts +0 -1
- package/dist/element/3d/geometry/sphereGeometry/v1/spawn.d.ts +0 -2
- package/dist/element/3d/index.d.ts +0 -6
- package/dist/element/3d/light/ambientLight/v1/index.d.ts +0 -1
- package/dist/element/3d/light/ambientLight/v1/spawn.d.ts +0 -2
- package/dist/element/3d/light/directionalLight/v1/index.d.ts +0 -1
- package/dist/element/3d/light/directionalLight/v1/spawn.d.ts +0 -2
- package/dist/element/3d/light/index.d.ts +0 -4
- package/dist/element/3d/light/pointLight/v1/index.d.ts +0 -1
- package/dist/element/3d/light/pointLight/v1/spawn.d.ts +0 -2
- package/dist/element/3d/light/spotLight/v1/index.d.ts +0 -1
- package/dist/element/3d/light/spotLight/v1/spawn.d.ts +0 -2
- package/dist/element/3d/material/index.d.ts +0 -1
- package/dist/element/3d/material/meshBasicMaterial/v1/index.d.ts +0 -1
- package/dist/element/3d/object/group/v1/index.d.ts +0 -1
- package/dist/element/3d/object/group/v1/spawn.d.ts +0 -2
- package/dist/element/3d/object/index.d.ts +0 -2
- package/dist/element/3d/object/mesh/v1/index.d.ts +0 -1
- package/dist/element/3d/object/mesh/v1/spawn.d.ts +0 -2
- package/dist/element/_common/index.d.ts +0 -3
- package/dist/element/_common/items/alignTabsItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/axisTypeItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/borderStyleItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/densityItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/directionItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/fieldVariantItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/flexCrossAlignItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/flexDirectionItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/flexMainAlignItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/flexWrapItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/fontWeightItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/index.d.ts +0 -25
- package/dist/element/_common/items/positionItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/sheetVariantItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/showTicksItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/sizeItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/speedDialOpenWayItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/textAlignItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/textDecorationItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/textEmphasisItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/textSizeItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/thumbLabelItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/timelineAlignItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/timelineDirectionItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/timelineSideItems/v1/index.d.ts +0 -1
- package/dist/element/_common/items/timelineTruncateLineItems/v1/index.d.ts +0 -1
- package/dist/element/_common/props/basic/v1/index.d.ts +0 -2
- package/dist/element/_common/props/border/v1/index.d.ts +0 -2
- package/dist/element/_common/props/index.d.ts +0 -10
- package/dist/element/_common/props/legend/v1/index.d.ts +0 -2
- package/dist/element/_common/props/margin/v1/index.d.ts +0 -2
- package/dist/element/_common/props/padding/v1/index.d.ts +0 -2
- package/dist/element/_common/props/size/v1/index.d.ts +0 -2
- package/dist/element/_common/props/title/v1/index.d.ts +0 -2
- package/dist/element/_common/props/transform/v1/index.d.ts +0 -2
- package/dist/element/_common/props/xAxis/v1/index.d.ts +0 -2
- package/dist/element/_common/props/yAxis/v1/index.d.ts +0 -2
- package/dist/element/_common/types/borderRadiusTypes/v1/index.d.ts +0 -1
- package/dist/element/_common/types/borderWidthTypes/v1/index.d.ts +0 -1
- package/dist/element/_common/types/colorTypes/v1/index.d.ts +0 -1
- package/dist/element/_common/types/index.d.ts +0 -9
- package/dist/element/_common/types/leftRightTypes/v1/index.d.ts +0 -1
- package/dist/element/_common/types/marginTypes/v1/index.d.ts +0 -1
- package/dist/element/_common/types/paddingTypes/v1/index.d.ts +0 -1
- package/dist/element/_common/types/sizeTypes/v1/index.d.ts +0 -1
- package/dist/element/_common/types/tableColumnAlignTypes/v1/index.d.ts +0 -1
- package/dist/element/_common/types/topBottomTypes/v1/index.d.ts +0 -1
- package/dist/element/_pkgs/index.d.ts +0 -2
- package/dist/element/_pkgs/v1/groups/comp3d.d.ts +0 -2
- package/dist/element/_pkgs/v1/groups/compUi.d.ts +0 -2
- package/dist/element/_pkgs/v1/groups/index.d.ts +0 -4
- package/dist/element/_pkgs/v1/groups/page3d.d.ts +0 -2
- package/dist/element/_pkgs/v1/groups/pageUi.d.ts +0 -2
- package/dist/element/_pkgs/v1/index.d.ts +0 -3
- package/dist/element/_pkgs/v1/items.d.ts +0 -1
- package/dist/element/_pkgs/v1/types.d.ts +0 -1
- package/dist/element/chart/barChart/v1/index.d.ts +0 -1
- package/dist/element/chart/barChart/v1/spawn.d.ts +0 -2
- package/dist/element/chart/index.d.ts +0 -2
- package/dist/element/chart/lineChart/v1/index.d.ts +0 -1
- package/dist/element/chart/lineChart/v1/spawn.d.ts +0 -2
- package/dist/element/dynamic/index.d.ts +0 -6
- package/dist/element/dynamic/inlineSlot/v1/index.d.ts +0 -1
- package/dist/element/dynamic/inlineSlot/v1/spawn.d.ts +0 -2
- package/dist/element/dynamic/multipleRef/v1/index.d.ts +0 -1
- package/dist/element/dynamic/multipleRef/v1/spawn.d.ts +0 -2
- package/dist/element/dynamic/multipleSlot/v1/index.d.ts +0 -1
- package/dist/element/dynamic/multipleSlot/v1/spawn.d.ts +0 -2
- package/dist/element/dynamic/ref/v1/index.d.ts +0 -1
- package/dist/element/dynamic/ref/v1/spawn.d.ts +0 -2
- package/dist/element/dynamic/renderSwitch/v1/index.d.ts +0 -1
- package/dist/element/dynamic/renderSwitch/v1/spawn.d.ts +0 -2
- package/dist/element/dynamic/slot/v1/index.d.ts +0 -1
- package/dist/element/dynamic/slot/v1/spawn.d.ts +0 -2
- package/dist/element/finalProperties.d.ts +0 -13
- package/dist/element/index.d.ts +0 -8
- package/dist/element/misc/globality/v1/index.d.ts +0 -1
- package/dist/element/misc/index.d.ts +0 -1
- package/dist/element/ui/activator/v1/index.d.ts +0 -1
- package/dist/element/ui/badge/v1/index.d.ts +0 -1
- package/dist/element/ui/badge/v1/spawn.d.ts +0 -2
- package/dist/element/ui/breadcrumbs/v1/index.d.ts +0 -1
- package/dist/element/ui/breadcrumbs/v1/spawn.d.ts +0 -2
- package/dist/element/ui/btn/v1/index.d.ts +0 -1
- package/dist/element/ui/btn/v1/spawn.d.ts +0 -2
- package/dist/element/ui/btnToggle/v1/index.d.ts +0 -1
- package/dist/element/ui/btnToggle/v1/spawn.d.ts +0 -2
- package/dist/element/ui/card/v1/index.d.ts +0 -1
- package/dist/element/ui/card/v1/spawn.d.ts +0 -2
- package/dist/element/ui/checkbox/v1/index.d.ts +0 -1
- package/dist/element/ui/checkbox/v1/spawn.d.ts +0 -2
- package/dist/element/ui/chip/v1/index.d.ts +0 -1
- package/dist/element/ui/chip/v1/spawn.d.ts +0 -2
- package/dist/element/ui/chipGroup/v1/index.d.ts +0 -1
- package/dist/element/ui/chipGroup/v1/spawn.d.ts +0 -2
- package/dist/element/ui/colorPicker/v1/index.d.ts +0 -1
- package/dist/element/ui/combobox/v1/index.d.ts +0 -1
- package/dist/element/ui/combobox/v1/spawn.d.ts +0 -2
- package/dist/element/ui/container/v1/index.d.ts +0 -1
- package/dist/element/ui/container/v1/spawn.d.ts +0 -2
- package/dist/element/ui/dataTableClient/v1/index.d.ts +0 -1
- package/dist/element/ui/dataTableClient/v1/spawn.d.ts +0 -2
- package/dist/element/ui/dataTableServer/v1/index.d.ts +0 -1
- package/dist/element/ui/dataTableServer/v1/spawn.d.ts +0 -2
- package/dist/element/ui/datePicker/v1/index.d.ts +0 -1
- package/dist/element/ui/dialog/v1/index.d.ts +0 -1
- package/dist/element/ui/dialog/v1/spawn1.d.ts +0 -2
- package/dist/element/ui/dialog/v1/spawn2.d.ts +0 -2
- package/dist/element/ui/fab/v1/index.d.ts +0 -1
- package/dist/element/ui/fab/v1/spawn.d.ts +0 -2
- package/dist/element/ui/fileInput/v1/index.d.ts +0 -1
- package/dist/element/ui/fileInput/v1/spawn.d.ts +0 -2
- package/dist/element/ui/flexbox/v1/index.d.ts +0 -1
- package/dist/element/ui/flexbox/v1/spawn.d.ts +0 -2
- package/dist/element/ui/flexboxEntry/v1/index.d.ts +0 -1
- package/dist/element/ui/flexboxEntry/v1/meta.d.ts +0 -1
- package/dist/element/ui/form/v1/index.d.ts +0 -1
- package/dist/element/ui/form/v1/spawn.d.ts +0 -2
- package/dist/element/ui/hover/v1/index.d.ts +0 -1
- package/dist/element/ui/hover/v1/spawn.d.ts +0 -2
- package/dist/element/ui/icon/v1/index.d.ts +0 -1
- package/dist/element/ui/icon/v1/spawn.d.ts +0 -2
- package/dist/element/ui/index.d.ts +0 -64
- package/dist/element/ui/item/v1/index.d.ts +0 -1
- package/dist/element/ui/itemGroup/v1/index.d.ts +0 -1
- package/dist/element/ui/itemGroup/v1/spawn.d.ts +0 -2
- package/dist/element/ui/list/v1/index.d.ts +0 -1
- package/dist/element/ui/list/v1/spawn.d.ts +0 -2
- package/dist/element/ui/listItem/v1/index.d.ts +0 -1
- package/dist/element/ui/menu/v1/index.d.ts +0 -1
- package/dist/element/ui/menu/v1/spawn.d.ts +0 -2
- package/dist/element/ui/numberInput/v1/index.d.ts +0 -1
- package/dist/element/ui/numberInput/v1/spawn.d.ts +0 -2
- package/dist/element/ui/optInput/v1/index.d.ts +0 -1
- package/dist/element/ui/optInput/v1/spawn.d.ts +0 -2
- package/dist/element/ui/pagination/v1/index.d.ts +0 -1
- package/dist/element/ui/pagination/v1/spawn.d.ts +0 -2
- package/dist/element/ui/positioner/v1/index.d.ts +0 -1
- package/dist/element/ui/positioner/v1/spawn.d.ts +0 -2
- package/dist/element/ui/radio/v1/index.d.ts +0 -1
- package/dist/element/ui/radioGroup/v1/index.d.ts +0 -1
- package/dist/element/ui/radioGroup/v1/spawn.d.ts +0 -2
- package/dist/element/ui/rangeSlider/v1/index.d.ts +0 -1
- package/dist/element/ui/rangeSlider/v1/spawn.d.ts +0 -2
- package/dist/element/ui/rating/v1/index.d.ts +0 -1
- package/dist/element/ui/rating/v1/spawn.d.ts +0 -2
- package/dist/element/ui/select/v1/index.d.ts +0 -1
- package/dist/element/ui/select/v1/spawn.d.ts +0 -2
- package/dist/element/ui/sheet/v1/index.d.ts +0 -1
- package/dist/element/ui/sheet/v1/spawn.d.ts +0 -2
- package/dist/element/ui/slideGroup/v1/index.d.ts +0 -1
- package/dist/element/ui/slideGroup/v1/spawn.d.ts +0 -2
- package/dist/element/ui/slideGroupItem/v1/index.d.ts +0 -1
- package/dist/element/ui/slider/v1/index.d.ts +0 -1
- package/dist/element/ui/slider/v1/spawn.d.ts +0 -2
- package/dist/element/ui/speedDial/v1/index.d.ts +0 -1
- package/dist/element/ui/speedDial/v1/spawn.d.ts +0 -2
- package/dist/element/ui/stepper/v1/index.d.ts +0 -1
- package/dist/element/ui/stepper/v1/spawn.d.ts +0 -2
- package/dist/element/ui/stepperHeader/v1/index.d.ts +0 -1
- package/dist/element/ui/stepperItem/v1/index.d.ts +0 -1
- package/dist/element/ui/stepperWindow/v1/index.d.ts +0 -1
- package/dist/element/ui/stepperWindowItem/v1/index.d.ts +0 -1
- package/dist/element/ui/switch/v1/index.d.ts +0 -1
- package/dist/element/ui/switch/v1/spawn.d.ts +0 -2
- package/dist/element/ui/tab/v1/index.d.ts +0 -1
- package/dist/element/ui/table/v1/index.d.ts +0 -1
- package/dist/element/ui/table/v1/spawn.d.ts +0 -2
- package/dist/element/ui/tableBody/v1/index.d.ts +0 -1
- package/dist/element/ui/tableBodyCell/v1/index.d.ts +0 -1
- package/dist/element/ui/tableHead/v1/index.d.ts +0 -1
- package/dist/element/ui/tableHeadCell/v1/index.d.ts +0 -1
- package/dist/element/ui/tableRow/v1/index.d.ts +0 -1
- package/dist/element/ui/tabs/v1/index.d.ts +0 -1
- package/dist/element/ui/tabs/v1/spawn.d.ts +0 -2
- package/dist/element/ui/text/v1/index.d.ts +0 -1
- package/dist/element/ui/text/v1/spawn.d.ts +0 -2
- package/dist/element/ui/textField/v1/index.d.ts +0 -1
- package/dist/element/ui/textField/v1/spawn.d.ts +0 -2
- package/dist/element/ui/textarea/v1/index.d.ts +0 -1
- package/dist/element/ui/textarea/v1/spawn.d.ts +0 -2
- package/dist/element/ui/timeline/v1/index.d.ts +0 -1
- package/dist/element/ui/timeline/v1/spawn.d.ts +0 -2
- package/dist/element/ui/timelineItem/v1/index.d.ts +0 -1
- package/dist/element/ui/tooltip/v1/index.d.ts +0 -1
- package/dist/element/ui/tooltip/v1/spawn.d.ts +0 -2
- package/dist/element/ui/window/v1/index.d.ts +0 -1
- package/dist/element/ui/window/v1/spawn.d.ts +0 -2
- package/dist/element/ui/windowItem/v1/index.d.ts +0 -1
- package/dist/meta/base.d.ts +0 -6
- package/dist/meta/element.d.ts +0 -106
- package/dist/meta/index.d.ts +0 -6
- package/dist/meta/items.d.ts +0 -8
- package/dist/meta/pkg.d.ts +0 -21
- package/dist/meta/property.d.ts +0 -108
- package/dist/meta/types.d.ts +0 -39
- package/dist/sandbox/bind/base.d.ts +0 -2
- package/dist/sandbox/bind/compute.d.ts +0 -2
- package/dist/sandbox/bind/index.d.ts +0 -2
- package/dist/sandbox/bind/system.d.ts +0 -2
- package/dist/sandbox/bind/view.d.ts +0 -2
- package/dist/sandbox/common/index.d.ts +0 -31
- package/dist/sandbox/index.d.ts +0 -3
- package/dist/sandbox/reactivity/index.d.ts +0 -4
- package/dist/sandbox/sandbox/hooks.d.ts +0 -6
- package/dist/sandbox/sandbox/index.d.ts +0 -116
- package/dist/sandbox/sandbox/initCode.d.ts +0 -1
- package/dist/sandbox/sandbox/promiseManager.d.ts +0 -13
- package/dist/types/basic.d.ts +0 -13
- package/dist/types/block.d.ts +0 -30
- package/dist/types/data.d.ts +0 -62
- package/dist/types/depend.d.ts +0 -12
- package/dist/types/index.d.ts +0 -7
- package/dist/types/kind.d.ts +0 -6
- package/dist/types/meta.d.ts +0 -39
- package/dist/types/transient.d.ts +0 -5
- package/dist/utils/breakpoint.d.ts +0 -11
- package/dist/utils/index.d.ts +0 -9
- package/dist/utils/misc.d.ts +0 -17
- package/dist/utils/name.d.ts +0 -4
- package/dist/utils/node.d.ts +0 -10
- package/dist/utils/property.d.ts +0 -5
- package/dist/utils/provideInject.d.ts +0 -43
- package/dist/utils/render.d.ts +0 -11
- package/dist/utils/sandbox.d.ts +0 -2
- package/dist/utils/unifiedId.d.ts +0 -66
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,977 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import { ComputedRef } from 'vue';
|
|
2
|
+
import { Emitter } from 'mitt';
|
|
3
|
+
import { EventType } from 'mitt';
|
|
4
|
+
import { QuickJSContext } from 'quickjs-emscripten';
|
|
5
|
+
import { QuickJSDeferredPromise } from 'quickjs-emscripten';
|
|
6
|
+
import { QuickJSRuntime } from 'quickjs-emscripten';
|
|
7
|
+
import { Reactive } from 'vue';
|
|
8
|
+
import { Ref } from 'vue';
|
|
9
|
+
import { ShallowRef } from 'vue';
|
|
10
|
+
import { Type } from 'x-essential-lib';
|
|
11
|
+
import { WritableComputedRef } from 'vue';
|
|
12
|
+
|
|
13
|
+
export declare interface ActivatorContext {
|
|
14
|
+
props?: Record<string, any>;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export declare function addIndent(code: string, spaces?: number): string;
|
|
18
|
+
|
|
19
|
+
export declare interface BlockState {
|
|
20
|
+
type: string;
|
|
21
|
+
id?: string;
|
|
22
|
+
x?: number;
|
|
23
|
+
y?: number;
|
|
24
|
+
collapsed?: boolean;
|
|
25
|
+
deletable?: boolean;
|
|
26
|
+
movable?: boolean;
|
|
27
|
+
editable?: boolean;
|
|
28
|
+
enabled?: boolean;
|
|
29
|
+
disabledReasons?: string[];
|
|
30
|
+
inline?: boolean;
|
|
31
|
+
data?: string;
|
|
32
|
+
extraState?: any;
|
|
33
|
+
icons?: {
|
|
34
|
+
[key: string]: any;
|
|
35
|
+
};
|
|
36
|
+
fields?: {
|
|
37
|
+
[key: string]: any;
|
|
38
|
+
};
|
|
39
|
+
inputs?: {
|
|
40
|
+
[key: string]: ConnectionState;
|
|
41
|
+
};
|
|
42
|
+
next?: ConnectionState;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export declare type Breakpoint = (typeof breakpoints)[number];
|
|
46
|
+
|
|
47
|
+
export declare const breakpoints: string[];
|
|
48
|
+
|
|
49
|
+
export declare function calcBreakpoint(width: number): Breakpoint;
|
|
50
|
+
|
|
51
|
+
export declare interface Code {
|
|
52
|
+
blockly: object;
|
|
53
|
+
script: string;
|
|
54
|
+
reactivity?: Reactivity;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export declare type CompType = (typeof compTypes)[number];
|
|
58
|
+
|
|
59
|
+
export declare const compTypes: string[];
|
|
60
|
+
|
|
61
|
+
declare interface ConnectionState {
|
|
62
|
+
shadow?: BlockState;
|
|
63
|
+
block?: BlockState;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export declare function createBreakpointProperty(prototype: ZProperty): ZProperty;
|
|
67
|
+
|
|
68
|
+
export declare function createMakeNode(type: string, subtype: string): (key: ZElementKey, nodePairs?: NodePair[], props?: {
|
|
69
|
+
[keys: string]: any;
|
|
70
|
+
}) => NodePair;
|
|
71
|
+
|
|
72
|
+
export declare function createNode(type: string, subtype: string, key: ZElementKey): Node_2;
|
|
73
|
+
|
|
74
|
+
export declare interface Data {
|
|
75
|
+
type: string;
|
|
76
|
+
version: string;
|
|
77
|
+
view: View;
|
|
78
|
+
code: Code;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
export declare function dataStringify({ type, version, view, code }: Data): string;
|
|
82
|
+
|
|
83
|
+
export declare interface Depend {
|
|
84
|
+
name: string;
|
|
85
|
+
metaSeq: number;
|
|
86
|
+
meta: Meta;
|
|
87
|
+
dataSeq: number;
|
|
88
|
+
data: Data;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
export declare interface Depends {
|
|
92
|
+
[key: string]: Depend;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
export declare type Device = {
|
|
96
|
+
width: number;
|
|
97
|
+
height: number;
|
|
98
|
+
};
|
|
99
|
+
|
|
100
|
+
export declare function duplicateNodePair(src: NodePair): NodePair;
|
|
101
|
+
|
|
102
|
+
export declare function duplicateNodePairs(srcs: NodePair[]): NodePair[];
|
|
103
|
+
|
|
104
|
+
export declare const elementKeys: readonly ["globality_v1", "inline_slot_v1", "multiple_ref_v1", "multiple_slot_v1", "ref_v1", "render_switch_v1", "slot_v1", "ui_activator_v1", "ui_badge_v1", "ui_breadcrumbs_v1", "ui_bar_chart_v1", "ui_btn_v1", "ui_btn_toggle_v1", "ui_card_v1", "ui_checkbox_v1", "ui_chip_v1", "ui_chip_group_v1", "ui_color_picker_v1", "ui_combobox_v1", "ui_container_v1", "ui_data_table_client_v1", "ui_data_table_server_v1", "ui_date_picker_v1", "ui_dialog_v1", "ui_expansion_panel_v1", "ui_expansion_panels_v1", "ui_fab_v1", "ui_file_input_v1", "ui_flexbox_v1", "ui_flexbox_entry_v1", "ui_form_v1", "ui_hover_v1", "ui_icon_v1", "ui_item_v1", "ui_item_group_v1", "ui_line_chart_v1", "ui_list_v1", "ui_list_item_v1", "ui_menu_v1", "ui_number_input_v1", "ui_opt_input_v1", "ui_pagination_v1", "ui_positioner_v1", "ui_radio_v1", "ui_radio_group_v1", "ui_range_slider_v1", "ui_rating_v1", "ui_select_v1", "ui_sheet_v1", "ui_slider_v1", "ui_slide_group_v1", "ui_slide_group_item_v1", "ui_speed_dial_v1", "ui_stepper_v1", "ui_stepper_header_v1", "ui_stepper_item_v1", "ui_stepper_window_v1", "ui_stepper_window_item_v1", "ui_switch_v1", "ui_tab_v1", "ui_table_v1", "ui_table_body_v1", "ui_table_body_cell_v1", "ui_table_head_v1", "ui_table_head_cell_v1", "ui_table_row_v1", "ui_tabs_v1", "ui_text_v1", "ui_textarea_v1", "ui_text_field_v1", "ui_timeline_v1", "ui_timeline_item_v1", "ui_tooltip_v1", "ui_window_v1", "ui_window_item_v1", "3d_ambient_light_v1", "3d_box_geometry_v1", "3d_directional_light_v1", "3d_group_v1", "3d_keyboard_controls_v1", "3d_map_controls_v1", "3d_mesh_v1", "3d_mesh_basic_material_v1", "3d_orbit_controls_v1", "3d_orthographic_camera_v1", "3d_perspective_camera_v1", "3d_point_light_v1", "3d_sphere_geometry_v1", "3d_spot_light_v1"];
|
|
105
|
+
|
|
106
|
+
export declare interface ElementProps {
|
|
107
|
+
nodeId: string;
|
|
108
|
+
outer?: boolean;
|
|
109
|
+
refContext?: RefContext;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
export declare type Env = 'dev' | 'prod';
|
|
113
|
+
|
|
114
|
+
declare type Event_2 = {
|
|
115
|
+
id: string;
|
|
116
|
+
name: string;
|
|
117
|
+
params?: Field[];
|
|
118
|
+
desc?: string;
|
|
119
|
+
};
|
|
120
|
+
export { Event_2 as Event }
|
|
121
|
+
|
|
122
|
+
export declare type EventKind = 'elementEvent' | 'elementPropertyChangeEvent' | 'elementSlotEvent' | 'elementSlotPropertyChangeEvent' | 'multipleElementSlotEvent' | 'multipleElementSlotPropertyChangeEvent' | 'refEvent' | 'refPropertyChangeEvent' | 'multipleRefEvent' | 'multipleRefPropertyChangeEvent' | 'customSlotEvent' | 'customSlotPropertyChangeEvent' | 'multipleCustomSlotEvent' | 'multipleCustomSlotPropertyChangeEvent' | 'customEvent' | 'customPropertyChangeEvent' | 'elementAdaptSlotEvent' | 'elementAdaptSlotPropertyChangeEvent' | 'customAdaptSlotEvent' | 'customAdaptSlotPropertyChangeEvent' | 'stateChangeEvent';
|
|
123
|
+
|
|
124
|
+
export declare type Field = {
|
|
125
|
+
id: string;
|
|
126
|
+
name: string;
|
|
127
|
+
type: Type;
|
|
128
|
+
desc?: string;
|
|
129
|
+
};
|
|
130
|
+
|
|
131
|
+
export declare const finalProperties: Properties;
|
|
132
|
+
|
|
133
|
+
export declare function fromDotString(target: string | string[]): string[];
|
|
134
|
+
|
|
135
|
+
export declare function genId(len: number): string;
|
|
136
|
+
|
|
137
|
+
export declare function getAllElements(): {
|
|
138
|
+
[key: string]: ZElement;
|
|
139
|
+
};
|
|
140
|
+
|
|
141
|
+
export declare function getBreakpointName(breakpoint: Breakpoint): string;
|
|
142
|
+
|
|
143
|
+
export declare function getBreakpointProperty<T>(current: Breakpoint, props: {
|
|
144
|
+
[key: Breakpoint]: T;
|
|
145
|
+
}): T | undefined;
|
|
146
|
+
|
|
147
|
+
export declare function getElement(key: ZElementKey | string): ZElement | undefined;
|
|
148
|
+
|
|
149
|
+
export declare function getField(object: any, keys: string | string[]): any;
|
|
150
|
+
|
|
151
|
+
export declare function getImplementMethodName(kind: MethodKind, nodeId: string, methodKey: string): string;
|
|
152
|
+
|
|
153
|
+
export declare function getIndexOfBreakpoint(breakpoint: Breakpoint): number;
|
|
154
|
+
|
|
155
|
+
export declare function getItems(key: ZItemsKey | string): ZItem[] | undefined;
|
|
156
|
+
|
|
157
|
+
export declare function getNodeLite(nodeLites: NodeLite[], id: string): NodeLite | undefined;
|
|
158
|
+
|
|
159
|
+
export declare function getPropertyDefault(property: ZProperty): any;
|
|
160
|
+
|
|
161
|
+
export declare function getPropertyDefaultArray(property: ZProperty): any[] | string[] | number[] | boolean[];
|
|
162
|
+
|
|
163
|
+
export declare function getRadius(val: unknown): string | undefined;
|
|
164
|
+
|
|
165
|
+
export declare function getTag(type: string, subtype: string): Tag;
|
|
166
|
+
|
|
167
|
+
export declare function getTypes(key: ZTypesKey | string): ZType[] | undefined;
|
|
168
|
+
|
|
169
|
+
export declare function hasComp(key: string): boolean;
|
|
170
|
+
|
|
171
|
+
export declare function hasInlineSlot(element: ZElement): boolean | undefined;
|
|
172
|
+
|
|
173
|
+
export declare function hasSlot(key: string): boolean;
|
|
174
|
+
|
|
175
|
+
declare interface Hooks {
|
|
176
|
+
onReady: () => Promise<void>;
|
|
177
|
+
onDestroy: () => void;
|
|
178
|
+
onPropertyChange: (id: string, newValue: any, oldValue: any, instance?: string) => Promise<void>;
|
|
179
|
+
onStateChange: (id: string, newValue: any, oldValue: any) => Promise<void>;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
export declare function initProperties(node: Node_2, properties: ZProperty[]): void;
|
|
183
|
+
|
|
184
|
+
export declare function initQuickJS(): Promise<void>;
|
|
185
|
+
|
|
186
|
+
declare type InitValues = {
|
|
187
|
+
[key: string]: any;
|
|
188
|
+
};
|
|
189
|
+
|
|
190
|
+
export declare function injectDark(): Ref<boolean>;
|
|
191
|
+
|
|
192
|
+
export declare function injectData(): Ref<Data | undefined>;
|
|
193
|
+
|
|
194
|
+
export declare function injectDepends(): ShallowRef<Depends>;
|
|
195
|
+
|
|
196
|
+
export declare function injectDevice(): Ref<Device>;
|
|
197
|
+
|
|
198
|
+
export declare function injectEnv(): Env;
|
|
199
|
+
|
|
200
|
+
export declare function injectId(): string;
|
|
201
|
+
|
|
202
|
+
export declare function injectMeta(): Ref<Meta | undefined>;
|
|
203
|
+
|
|
204
|
+
export declare function injectMode(): Mode;
|
|
205
|
+
|
|
206
|
+
export declare function injectNode(): Ref<Node_2> | undefined;
|
|
207
|
+
|
|
208
|
+
export declare function injectNodeLite(): Ref<NodeLite> | undefined;
|
|
209
|
+
|
|
210
|
+
export declare function injectOrg(): string;
|
|
211
|
+
|
|
212
|
+
export declare function injectRuntime(): QuickJSRuntime;
|
|
213
|
+
|
|
214
|
+
export declare function injectSandbox(): Sandbox | undefined;
|
|
215
|
+
|
|
216
|
+
export declare function injectSlotProps(): Record<string, any> | undefined;
|
|
217
|
+
|
|
218
|
+
export declare function injectTransients(): Reactive<Transients>;
|
|
219
|
+
|
|
220
|
+
export declare function injectType(): "page" | "comp";
|
|
221
|
+
|
|
222
|
+
declare interface Inputs {
|
|
223
|
+
[key: string]: any;
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
export declare function isCircularReference(refContext: RefContext, id: string): boolean;
|
|
227
|
+
|
|
228
|
+
export declare function isExecutableMode(mode: Mode): mode is "runtime" | "preview";
|
|
229
|
+
|
|
230
|
+
export declare function isHexColor(v: unknown): boolean;
|
|
231
|
+
|
|
232
|
+
export declare function isInlineSlot(key: string): boolean;
|
|
233
|
+
|
|
234
|
+
export declare function isPercent(v: unknown): boolean;
|
|
235
|
+
|
|
236
|
+
export declare function isPixel(v: unknown): boolean;
|
|
237
|
+
|
|
238
|
+
export declare function isRenderSwitch(key: string): boolean;
|
|
239
|
+
|
|
240
|
+
export declare function isThemeColor(v: unknown): boolean;
|
|
241
|
+
|
|
242
|
+
export declare const itemsKeys: readonly ["alignTabsItemsV1", "axisTypeItemsV1", "borderStyleItemsV1", "densityItemsV1", "directionItemsV1", "expansionPanelVariantItemsV1", "fieldVariantItemsV1", "flexCrossAlignItemsV1", "flexDirectionItemsV1", "flexMainAlignItemsV1", "flexWrapItemsV1", "fontWeightItemsV1", "positionItemsV1", "sheetVariantItemsV1", "showTicksItemsV1", "sizeItemsV1", "speedDialOpenWayItemsV1", "textAlignItemsV1", "textDecorationItemsV1", "textEmphasisItemsV1", "textSizeItemsV1", "thumbLabelItemsV1", "timelineAlignItemsV1", "timelineDirectionItemsV1", "timelineSideItemsV1", "timelineTruncateLineItemsV1", "transitionItemsV1"];
|
|
243
|
+
|
|
244
|
+
export declare function loadLocaleMessageRuntime(locale: string): Promise<object>;
|
|
245
|
+
|
|
246
|
+
export declare function makeEventId(kind: EventKind, nodeId: string, eventKey: string): string;
|
|
247
|
+
|
|
248
|
+
export declare function makeEventKeyOfCustomSlot(compId: string, slotId: string, eventId: string): string;
|
|
249
|
+
|
|
250
|
+
export declare function makeEventKeyOfElementSlot(elementKey: string, slotKey: string, eventKey: string): string;
|
|
251
|
+
|
|
252
|
+
export declare function makeMethodId(kind: MethodKind, nodeId: string, methodKey: string): string;
|
|
253
|
+
|
|
254
|
+
export declare function makeMethodKeyOfCustomSlot(compId: string, slotId: string, methodId: string): string;
|
|
255
|
+
|
|
256
|
+
export declare function makeMethodKeyOfElementSlot(elementKey: string, slotKey: string, methodKey: string): string;
|
|
257
|
+
|
|
258
|
+
export declare function makeNodePair(node: Node_2, nodePairs?: NodePair[]): NodePair;
|
|
259
|
+
|
|
260
|
+
export declare function makePropertyId(kind: PropertyKind, nodeId: string, propertyKey: string): string;
|
|
261
|
+
|
|
262
|
+
export declare function makePropertyKeyOfCustomSlot(compId: string, slotId: string, propertyId: string): string;
|
|
263
|
+
|
|
264
|
+
export declare function makePropertyKeyOfElementSlot(elementKey: string, slotKey: string, propertyKey: string): string;
|
|
265
|
+
|
|
266
|
+
export declare function makeSlotId(kind: SlotKind, mainKey: string, slotKey: string): string;
|
|
267
|
+
|
|
268
|
+
export declare function makeTriggerId(kind: TriggerKind, triggerKey: string): string;
|
|
269
|
+
|
|
270
|
+
export declare type Meta = {
|
|
271
|
+
version: string;
|
|
272
|
+
states?: Field[];
|
|
273
|
+
arguments?: Field[];
|
|
274
|
+
properties?: Field[];
|
|
275
|
+
methods?: Method[];
|
|
276
|
+
events?: Event_2[];
|
|
277
|
+
slots?: Slot[];
|
|
278
|
+
};
|
|
279
|
+
|
|
280
|
+
export declare function metaStringify(meta: Meta): string;
|
|
281
|
+
|
|
282
|
+
export declare type Method = {
|
|
283
|
+
id: string;
|
|
284
|
+
name: string;
|
|
285
|
+
inputs?: Field[];
|
|
286
|
+
outputs?: Field[];
|
|
287
|
+
desc?: string;
|
|
288
|
+
};
|
|
289
|
+
|
|
290
|
+
export declare type MethodKind = 'elementMethod' | 'elementSlotMethod' | 'multipeElementSlotMethod' | 'refMethod' | 'multipleRefMethod' | 'customSlotMethod' | 'multipleCustomSlotMethod' | 'customMethod' | 'elementAdaptSlotMethod' | 'customAdaptSlotMethod';
|
|
291
|
+
|
|
292
|
+
export declare type Mode = 'runtime' | 'preview' | 'editor';
|
|
293
|
+
|
|
294
|
+
declare type Node_2 = {
|
|
295
|
+
basic: {
|
|
296
|
+
id: string;
|
|
297
|
+
key: string;
|
|
298
|
+
alias?: string;
|
|
299
|
+
};
|
|
300
|
+
[key: string]: any;
|
|
301
|
+
};
|
|
302
|
+
export { Node_2 as Node }
|
|
303
|
+
|
|
304
|
+
export declare type NodeLite = {
|
|
305
|
+
id: string;
|
|
306
|
+
key: string;
|
|
307
|
+
alias?: string;
|
|
308
|
+
group?: string;
|
|
309
|
+
render?: boolean;
|
|
310
|
+
slotId?: string;
|
|
311
|
+
compId?: string;
|
|
312
|
+
children?: NodeLite[];
|
|
313
|
+
};
|
|
314
|
+
|
|
315
|
+
export declare type NodePair = {
|
|
316
|
+
nodeLite: NodeLite;
|
|
317
|
+
nodes: {
|
|
318
|
+
[key: string]: Node_2;
|
|
319
|
+
};
|
|
320
|
+
};
|
|
321
|
+
|
|
322
|
+
export declare type PageType = (typeof pageTypes)[number];
|
|
323
|
+
|
|
324
|
+
export declare const pageTypes: string[];
|
|
325
|
+
|
|
326
|
+
export declare function parseData(str: string): Data;
|
|
327
|
+
|
|
328
|
+
export declare function parseMeta(str: string): Meta;
|
|
329
|
+
|
|
330
|
+
export declare function parsePercent(v: unknown): number;
|
|
331
|
+
|
|
332
|
+
export declare function parsePixel(v: unknown): number;
|
|
333
|
+
|
|
334
|
+
export declare const pkgs: ZPkgs;
|
|
335
|
+
|
|
336
|
+
declare class PromiseManager {
|
|
337
|
+
private vm;
|
|
338
|
+
private promises;
|
|
339
|
+
private currPromiseId;
|
|
340
|
+
constructor(vm: QuickJSContext);
|
|
341
|
+
dispose(): void;
|
|
342
|
+
create(): {
|
|
343
|
+
promise: QuickJSDeferredPromise;
|
|
344
|
+
resolve: (value: any) => void;
|
|
345
|
+
reject: (reason: any) => void;
|
|
346
|
+
};
|
|
347
|
+
}
|
|
348
|
+
|
|
349
|
+
declare type Properties = {
|
|
350
|
+
[key: string]: {
|
|
351
|
+
[tag: string]: Property[];
|
|
352
|
+
};
|
|
353
|
+
};
|
|
354
|
+
|
|
355
|
+
declare type Property = {
|
|
356
|
+
keys: string;
|
|
357
|
+
names: string[];
|
|
358
|
+
raw: ZProperty;
|
|
359
|
+
};
|
|
360
|
+
|
|
361
|
+
export declare type PropertyKind = 'elementProperty' | 'elementSlotProperty' | 'multipleElementSlotProperty' | 'refProperty' | 'multipleRefProperty' | 'customSlotProperty' | 'multipleCustomSlotProperty' | 'customProperty' | 'elementAdaptSlotProperty' | 'customAdaptSlotProperty';
|
|
362
|
+
|
|
363
|
+
export declare function provideDark(dark: Ref<boolean>): void;
|
|
364
|
+
|
|
365
|
+
export declare function provideData(data: Ref<Data | undefined>): void;
|
|
366
|
+
|
|
367
|
+
export declare function provideDepends(depends: ShallowRef<Depends>): void;
|
|
368
|
+
|
|
369
|
+
export declare function provideDevice(device: Ref<Device>): void;
|
|
370
|
+
|
|
371
|
+
export declare function provideEnv(env: Env): void;
|
|
372
|
+
|
|
373
|
+
export declare function provideId(id: string): void;
|
|
374
|
+
|
|
375
|
+
export declare function provideMeta(meta: Ref<Meta | undefined>): void;
|
|
376
|
+
|
|
377
|
+
export declare function provideMode(mode: Mode): void;
|
|
378
|
+
|
|
379
|
+
export declare function provideNode(node: Ref<Node_2>): void;
|
|
380
|
+
|
|
381
|
+
export declare function provideNodeLite(nodeLite: Ref<NodeLite>): void;
|
|
382
|
+
|
|
383
|
+
export declare function provideOrg(org: string): void;
|
|
384
|
+
|
|
385
|
+
export declare function provideRuntime(runtime: QuickJSRuntime): void;
|
|
386
|
+
|
|
387
|
+
export declare function provideSandbox(sandbox: Sandbox): void;
|
|
388
|
+
|
|
389
|
+
export declare function provideSlotProps(slotProps: Record<string, any>): void;
|
|
390
|
+
|
|
391
|
+
export declare function provideTransients(transients: Reactive<Transients>): void;
|
|
392
|
+
|
|
393
|
+
export declare function provideType(type: 'page' | 'comp'): void;
|
|
394
|
+
|
|
395
|
+
export declare interface Reactivity {
|
|
396
|
+
watchEffect: {
|
|
397
|
+
ids: string[];
|
|
398
|
+
triggers: {
|
|
399
|
+
[key: string]: string[];
|
|
400
|
+
};
|
|
401
|
+
};
|
|
402
|
+
bind: {
|
|
403
|
+
sets: {
|
|
404
|
+
[key: string]: string[];
|
|
405
|
+
};
|
|
406
|
+
triggers: {
|
|
407
|
+
[key: string]: string[];
|
|
408
|
+
};
|
|
409
|
+
};
|
|
410
|
+
}
|
|
411
|
+
|
|
412
|
+
export declare interface RefContext {
|
|
413
|
+
parent?: RefContext;
|
|
414
|
+
compId: string | undefined;
|
|
415
|
+
}
|
|
416
|
+
|
|
417
|
+
export declare function regElement(element: ZElement): void;
|
|
418
|
+
|
|
419
|
+
export declare function regItems(key: ZItemsKey, items: ZItem[]): void;
|
|
420
|
+
|
|
421
|
+
export declare function regTypes(key: ZTypesKey, types: ZType[]): void;
|
|
422
|
+
|
|
423
|
+
export declare const reverseBreakpoints: string[];
|
|
424
|
+
|
|
425
|
+
declare class Sandbox {
|
|
426
|
+
kind: SandboxKind;
|
|
427
|
+
nodeId: string;
|
|
428
|
+
slotId: string;
|
|
429
|
+
instance: string;
|
|
430
|
+
parent: Sandbox | undefined;
|
|
431
|
+
children: {
|
|
432
|
+
[key: string]: Sandbox;
|
|
433
|
+
};
|
|
434
|
+
org: string;
|
|
435
|
+
env: Env;
|
|
436
|
+
mode: Mode;
|
|
437
|
+
type: 'page' | 'comp';
|
|
438
|
+
eventBus: Emitter<Record<EventType, unknown>>;
|
|
439
|
+
hooks: Hooks;
|
|
440
|
+
vm: QuickJSContext | undefined;
|
|
441
|
+
promiseManager: PromiseManager | undefined;
|
|
442
|
+
constructor(kind: SandboxKind, nodeId: string, slotId: string, instance: string, parent: Sandbox | undefined, org: string, env: Env, mode: Mode, type: 'page' | 'comp', hooks: Hooks);
|
|
443
|
+
dispose(): void;
|
|
444
|
+
debugTrace(...data: any[]): void;
|
|
445
|
+
private addChild;
|
|
446
|
+
private removeChild;
|
|
447
|
+
private meta;
|
|
448
|
+
private data;
|
|
449
|
+
private transients;
|
|
450
|
+
private depends;
|
|
451
|
+
prepare(meta: Ref<Meta | undefined>, data: Ref<Data | undefined>, transients: Reactive<Transients>, depends: ShallowRef<Depends | undefined>, initValues?: InitValues): void;
|
|
452
|
+
createVm(runtime: QuickJSRuntime, code: string): Promise<void>;
|
|
453
|
+
destroyVm(): void;
|
|
454
|
+
setGlobalVariable(key: string, value: any): void;
|
|
455
|
+
getGlobalVariable(key: string): any;
|
|
456
|
+
evalCode(code: string): void;
|
|
457
|
+
callFunctionSync(funcName: string, ...params: any[]): any;
|
|
458
|
+
callFunctionAsync(funcName: string, ...params: any[]): Promise<any>;
|
|
459
|
+
getNode(nodeId: string): Node_2 | undefined;
|
|
460
|
+
isEqualOfElementSlot(elementKey: string, slotKey: string): boolean;
|
|
461
|
+
isEqualOfCustomSlot(compId: string, slotId: string): boolean;
|
|
462
|
+
customProperties: {
|
|
463
|
+
[key: string]: any;
|
|
464
|
+
};
|
|
465
|
+
customSlotProperties: {
|
|
466
|
+
[key: string]: any;
|
|
467
|
+
};
|
|
468
|
+
private resetCustomProperties;
|
|
469
|
+
private resetCustomSlotProperties;
|
|
470
|
+
private getMetaOfElementProperty;
|
|
471
|
+
private isValidOfElementProperty;
|
|
472
|
+
private isValidOfElementSlotProperty;
|
|
473
|
+
private isValidOfCustomProperty;
|
|
474
|
+
private isValidOfCustomSlotProperty;
|
|
475
|
+
getProperty(id: string, instance?: string): any;
|
|
476
|
+
private getElementProperty;
|
|
477
|
+
private getRefProperty;
|
|
478
|
+
private getMultipleRefProperty;
|
|
479
|
+
private getCustomSlotProperty;
|
|
480
|
+
private getMultipleCustomSlotProperty;
|
|
481
|
+
private getCustomProperty;
|
|
482
|
+
private getElementAdaptSlotProperty;
|
|
483
|
+
private getCustomAdaptSlotProperty;
|
|
484
|
+
setProperty(id: string, newValue: any, instance?: string): Promise<void>;
|
|
485
|
+
private setElementProperty;
|
|
486
|
+
private setRefProperty;
|
|
487
|
+
private setMultipleRefProperty;
|
|
488
|
+
private setCustomSlotProperty;
|
|
489
|
+
private setMultipleCustomSlotProperty;
|
|
490
|
+
private setCustomProperty;
|
|
491
|
+
private setElementAdaptSlotProperty;
|
|
492
|
+
private setCustomAdaptSlotProperty;
|
|
493
|
+
isValidOfElementMethod(elementKey: string, methodKey: string): boolean;
|
|
494
|
+
isValidOfElementSlotMethod(elementKey: string, slotKey: string, methodKey: string): boolean;
|
|
495
|
+
isValidOfCustomMethod(methodId: string): boolean;
|
|
496
|
+
isValidOfCustomSlotMethod(compId: string, slotId: string, methodId: string): boolean;
|
|
497
|
+
callMethod(id: string, instance: string, inputs: Inputs): Promise<any>;
|
|
498
|
+
private callElementMethod;
|
|
499
|
+
private callRefMethod;
|
|
500
|
+
private callMultipleRefMethod;
|
|
501
|
+
private callElementAdaptSlotMethod;
|
|
502
|
+
private callCustomAdaptSlotMethod;
|
|
503
|
+
isValidOfElementEvent(elementKey: string, eventKey: string): boolean;
|
|
504
|
+
isValidOfElementSlotEvent(elementKey: string, slotKey: string, eventKey: string): boolean;
|
|
505
|
+
isValidOfCustomEvent(eventId: string): boolean;
|
|
506
|
+
isValidOfCustomSlotEvent(compId: string, slotId: string, eventId: string): boolean;
|
|
507
|
+
triggerEvent(id: string, params: any[], instance?: string): Promise<void>;
|
|
508
|
+
private triggerElementEvent;
|
|
509
|
+
private triggerElementPropertyChangeEvent;
|
|
510
|
+
private triggerElementSlotEvent;
|
|
511
|
+
private triggerElementSlotPropertyChangeEvent;
|
|
512
|
+
private triggerMultipleElementSlotEvent;
|
|
513
|
+
private triggerMultipleElementSlotPropertyChangeEvent;
|
|
514
|
+
private triggerRefEvent;
|
|
515
|
+
private triggerRefPropertyChangeEvent;
|
|
516
|
+
private triggerMultipleRefEvent;
|
|
517
|
+
private triggerMultipleRefPropertyChangeEvent;
|
|
518
|
+
private triggerCustomSlotEvent;
|
|
519
|
+
private triggerCustomSlotPropertyChangeEvent;
|
|
520
|
+
private triggerMultipleCustomSlotEvent;
|
|
521
|
+
private triggerMultipleCustomSlotPropertyChangeEvent;
|
|
522
|
+
private triggerCustomEvent;
|
|
523
|
+
private triggerCustomPropertyChangeEvent;
|
|
524
|
+
private triggerElementAdaptSlotEvent;
|
|
525
|
+
private triggerElementAdaptSlotPropertyChangeEvent;
|
|
526
|
+
private triggerCustomAdaptSlotEvent;
|
|
527
|
+
private triggerCustomAdaptSlotPropertyChangeEvent;
|
|
528
|
+
private triggerStateChangeEvent;
|
|
529
|
+
private states;
|
|
530
|
+
private resetStates;
|
|
531
|
+
isValidOfState(id: string): boolean;
|
|
532
|
+
getState(id: string): Promise<any>;
|
|
533
|
+
setState(id: string, newValue: any): Promise<void>;
|
|
534
|
+
}
|
|
535
|
+
|
|
536
|
+
export declare type SandboxKind = 'root' | 'ref' | 'multipleRef' | 'elementSlot' | 'multipleElementSlot' | 'customSlot' | 'multipleCustomSlot';
|
|
537
|
+
|
|
538
|
+
export declare function setField(object: any, keys: string | string[], value: any): void;
|
|
539
|
+
|
|
540
|
+
export declare type Slot = {
|
|
541
|
+
id: string;
|
|
542
|
+
name: string;
|
|
543
|
+
properties?: Field[];
|
|
544
|
+
methods?: Method[];
|
|
545
|
+
events?: Event_2[];
|
|
546
|
+
desc?: string;
|
|
547
|
+
};
|
|
548
|
+
|
|
549
|
+
export declare type SlotKind = 'elementSlot' | 'multipleElementSlot' | 'customSlot' | 'multipleCustomSlot';
|
|
550
|
+
|
|
551
|
+
export declare function syncNodeLite(nodeLite: NodeLite, node: Node_2): void;
|
|
552
|
+
|
|
553
|
+
export declare type Tag = 'pageUi' | 'compUi' | 'page3d' | 'comp3d';
|
|
554
|
+
|
|
555
|
+
export declare const themeColors: {
|
|
556
|
+
value: string;
|
|
557
|
+
title: string;
|
|
558
|
+
}[];
|
|
559
|
+
|
|
560
|
+
export declare function toDotString(target: string | string[]): string;
|
|
561
|
+
|
|
562
|
+
export declare function toEventName(kind: EventKind, names: string[]): string;
|
|
563
|
+
|
|
564
|
+
export declare function toMethodName(kind: MethodKind, names: string[]): string;
|
|
565
|
+
|
|
566
|
+
export declare function toNodeLite(node: Node_2, children?: NodeLite[]): NodeLite;
|
|
567
|
+
|
|
568
|
+
export declare function toPropertyName(kind: PropertyKind, names: string[]): string;
|
|
569
|
+
|
|
570
|
+
export declare function toRenderDefault(children: NodeLite[] | undefined, renderNode: (n: NodeLite, ...params: any[]) => any, ...params: any[]): any[];
|
|
571
|
+
|
|
572
|
+
export declare function toRenderSlots(children: NodeLite[] | undefined, renderNode: (n: NodeLite, ...params: any[]) => any, ...params: any[]): {
|
|
573
|
+
[key: string]: any;
|
|
574
|
+
};
|
|
575
|
+
|
|
576
|
+
export declare interface Transients {
|
|
577
|
+
[nodeId: string]: {
|
|
578
|
+
[propertyKey: string]: any;
|
|
579
|
+
};
|
|
580
|
+
}
|
|
581
|
+
|
|
582
|
+
export declare type TriggerKind = 'propertyTrigger' | 'stateTrigger';
|
|
583
|
+
|
|
584
|
+
export declare const typesKeys: readonly ["borderRadiusTypesV1", "borderWidthTypesV1", "colorTypesV1", "leftRightTypesV1", "marginTypesV1", "paddingTypesV1", "sizeTypesV1", "tableColumnAlignTypesV1", "topBottomTypesV1"];
|
|
585
|
+
|
|
586
|
+
export declare function unwrapEventId(id: string): {
|
|
587
|
+
kind: EventKind;
|
|
588
|
+
nodeId: string;
|
|
589
|
+
eventKey: string;
|
|
590
|
+
};
|
|
591
|
+
|
|
592
|
+
export declare function unwrapEventKeyOfCustomSlot(key: string): {
|
|
593
|
+
compId: string;
|
|
594
|
+
slotId: string;
|
|
595
|
+
eventId: string;
|
|
596
|
+
};
|
|
597
|
+
|
|
598
|
+
export declare function unwrapEventKeyOfElementSlot(key: string): {
|
|
599
|
+
elementKey: string;
|
|
600
|
+
slotKey: string;
|
|
601
|
+
eventKey: string;
|
|
602
|
+
};
|
|
603
|
+
|
|
604
|
+
export declare function unwrapMethodId(id: string): {
|
|
605
|
+
kind: MethodKind;
|
|
606
|
+
nodeId: string;
|
|
607
|
+
methodKey: string;
|
|
608
|
+
};
|
|
609
|
+
|
|
610
|
+
export declare function unwrapMethodKeyOfCustomSlot(key: string): {
|
|
611
|
+
compId: string;
|
|
612
|
+
slotId: string;
|
|
613
|
+
methodId: string;
|
|
614
|
+
};
|
|
615
|
+
|
|
616
|
+
export declare function unwrapMethodKeyOfElementSlot(key: string): {
|
|
617
|
+
elementKey: string;
|
|
618
|
+
slotKey: string;
|
|
619
|
+
methodKey: string;
|
|
620
|
+
};
|
|
621
|
+
|
|
622
|
+
export declare function unwrapPropertyId(id: string): {
|
|
623
|
+
kind: PropertyKind;
|
|
624
|
+
nodeId: string;
|
|
625
|
+
propertyKey: string;
|
|
626
|
+
};
|
|
627
|
+
|
|
628
|
+
export declare function unwrapPropertyKeyOfCustomSlot(key: string): {
|
|
629
|
+
compId: string;
|
|
630
|
+
slotId: string;
|
|
631
|
+
propertyId: string;
|
|
632
|
+
};
|
|
633
|
+
|
|
634
|
+
export declare function unwrapPropertyKeyOfElementSlot(key: string): {
|
|
635
|
+
elementKey: string;
|
|
636
|
+
slotKey: string;
|
|
637
|
+
propertyKey: string;
|
|
638
|
+
};
|
|
639
|
+
|
|
640
|
+
export declare function unwrapSlotId(id: string): {
|
|
641
|
+
kind: SlotKind;
|
|
642
|
+
mainKey: string;
|
|
643
|
+
slotKey: string;
|
|
644
|
+
};
|
|
645
|
+
|
|
646
|
+
export declare function unwrapTriggerId(id: string): {
|
|
647
|
+
kind: TriggerKind;
|
|
648
|
+
triggerKey: string;
|
|
649
|
+
};
|
|
650
|
+
|
|
651
|
+
export declare function useColor(src: Readonly<Ref<string | undefined>>): {
|
|
652
|
+
color: ComputedRef<string | undefined>;
|
|
653
|
+
};
|
|
654
|
+
|
|
655
|
+
export declare function useDepend(compId: Ref<string | undefined>, meta: Ref<Meta | undefined>, data: Ref<Data | undefined>): void;
|
|
656
|
+
|
|
657
|
+
export declare function useGlobalTransient(sandbox: Sandbox, transients: Reactive<Transients>, propertyKey: string): {
|
|
658
|
+
property: WritableComputedRef<any, any>;
|
|
659
|
+
};
|
|
660
|
+
|
|
661
|
+
export declare function useRuntime(): void;
|
|
662
|
+
|
|
663
|
+
export declare function useSandbox(kind: SandboxKind, nodeId: string, slotId: string, instance: string, parent: Sandbox | undefined, meta: Ref<Meta | undefined>, data: Ref<Data | undefined>, transients: Reactive<Transients>, initValues?: InitValues): {
|
|
664
|
+
sandbox: Sandbox;
|
|
665
|
+
};
|
|
666
|
+
|
|
667
|
+
export declare function useTheme(): {
|
|
668
|
+
theme: ComputedRef<"light" | "dark">;
|
|
669
|
+
};
|
|
670
|
+
|
|
671
|
+
export declare interface View {
|
|
672
|
+
nodeLites: NodeLite[];
|
|
673
|
+
nodes: {
|
|
674
|
+
globality: Node_2;
|
|
675
|
+
[key: string]: Node_2;
|
|
676
|
+
};
|
|
677
|
+
}
|
|
678
|
+
|
|
679
|
+
declare type WithArray<T extends {
|
|
680
|
+
default: unknown;
|
|
681
|
+
}> = (T & {
|
|
682
|
+
array?: false;
|
|
683
|
+
}) | (T & {
|
|
684
|
+
array: true;
|
|
685
|
+
defaultArray: T['default'][];
|
|
686
|
+
});
|
|
687
|
+
|
|
688
|
+
export declare type ZElement = {
|
|
689
|
+
key: ZElementKey;
|
|
690
|
+
name: string;
|
|
691
|
+
comp: any;
|
|
692
|
+
properties: {
|
|
693
|
+
[key in Tag]?: ZProperty[];
|
|
694
|
+
};
|
|
695
|
+
methods?: ZMethod[];
|
|
696
|
+
events?: ZEvent[];
|
|
697
|
+
inlineSlots?: string[];
|
|
698
|
+
slots?: ZSlot[];
|
|
699
|
+
internal?: boolean;
|
|
700
|
+
teleport?: boolean;
|
|
701
|
+
spawn?: ZSpawnFunc | {
|
|
702
|
+
func: ZSpawnFunc;
|
|
703
|
+
desc?: string;
|
|
704
|
+
}[];
|
|
705
|
+
};
|
|
706
|
+
|
|
707
|
+
export declare type ZElementKey = (typeof elementKeys)[number];
|
|
708
|
+
|
|
709
|
+
export declare type ZEvent = {
|
|
710
|
+
key: string;
|
|
711
|
+
name: string;
|
|
712
|
+
params?: {
|
|
713
|
+
key: string;
|
|
714
|
+
name: string;
|
|
715
|
+
type: Type;
|
|
716
|
+
desc?: string;
|
|
717
|
+
}[];
|
|
718
|
+
desc?: string;
|
|
719
|
+
};
|
|
720
|
+
|
|
721
|
+
export declare type ZGroup = {
|
|
722
|
+
key: string;
|
|
723
|
+
name: string;
|
|
724
|
+
items: ZElementKey[];
|
|
725
|
+
};
|
|
726
|
+
|
|
727
|
+
export declare type ZItem = {
|
|
728
|
+
value: string;
|
|
729
|
+
title: string;
|
|
730
|
+
};
|
|
731
|
+
|
|
732
|
+
export declare type ZItemsKey = (typeof itemsKeys)[number];
|
|
733
|
+
|
|
734
|
+
export declare type ZMethod = {
|
|
735
|
+
key: string;
|
|
736
|
+
name: string;
|
|
737
|
+
inputs?: {
|
|
738
|
+
key: string;
|
|
739
|
+
name: string;
|
|
740
|
+
type: Type;
|
|
741
|
+
desc?: string;
|
|
742
|
+
}[];
|
|
743
|
+
outputs?: {
|
|
744
|
+
key: string;
|
|
745
|
+
name: string;
|
|
746
|
+
type: Type;
|
|
747
|
+
desc?: string;
|
|
748
|
+
}[];
|
|
749
|
+
desc?: string;
|
|
750
|
+
};
|
|
751
|
+
|
|
752
|
+
export declare type ZPkg = {
|
|
753
|
+
version: string;
|
|
754
|
+
globalityKey: ZElementKey;
|
|
755
|
+
refKey: ZElementKey;
|
|
756
|
+
items: Set<ZItemsKey>;
|
|
757
|
+
types: Set<ZTypesKey>;
|
|
758
|
+
groups: {
|
|
759
|
+
[tag: string]: ZGroup[];
|
|
760
|
+
};
|
|
761
|
+
};
|
|
762
|
+
|
|
763
|
+
export declare type ZPkgs = {
|
|
764
|
+
[key: string]: ZPkg;
|
|
765
|
+
};
|
|
766
|
+
|
|
767
|
+
export declare type ZProperty = ({
|
|
768
|
+
array?: false;
|
|
769
|
+
} & ZPropertyBranch) | ({
|
|
770
|
+
array: true;
|
|
771
|
+
defaultArray: any[];
|
|
772
|
+
} & ZPropertyBranch) | WithArray<ZPropertyDummy> | WithArray<ZPropertyStrInput> | WithArray<ZPropertyNumInput> | WithArray<ZPropertySwitch> | WithArray<ZPropertySelect> | WithArray<ZPropertyColorPicker> | WithArray<ZPropertyJsonEditor> | WithArray<ZPropertyMultiTypes> | WithArray<ZPropertySelectComp> | WithArray<ZPropertySelectSlot> | WithArray<ZPropertyStrInput> | WithArray<ZPropertySelectAdaptSlot> | WithArray<ZPropertySelectInlineSlot> | WithArray<ZPropertyTransient<Type>>;
|
|
773
|
+
|
|
774
|
+
declare type ZPropertyBase = {
|
|
775
|
+
key: string;
|
|
776
|
+
name: string;
|
|
777
|
+
readonly?: boolean;
|
|
778
|
+
static?: boolean;
|
|
779
|
+
value?: any;
|
|
780
|
+
};
|
|
781
|
+
|
|
782
|
+
declare type ZPropertyBranch = {
|
|
783
|
+
key: string;
|
|
784
|
+
name: string;
|
|
785
|
+
ui?: undefined;
|
|
786
|
+
children: ZProperty[];
|
|
787
|
+
};
|
|
788
|
+
|
|
789
|
+
declare type ZPropertyColorPicker = {
|
|
790
|
+
ui: 'colorPicker';
|
|
791
|
+
default: string;
|
|
792
|
+
} & ZPropertyBase;
|
|
793
|
+
|
|
794
|
+
declare type ZPropertyDummy = {
|
|
795
|
+
ui: 'dummy';
|
|
796
|
+
default: any;
|
|
797
|
+
} & ZPropertyBase;
|
|
798
|
+
|
|
799
|
+
declare type ZPropertyJsonEditor = {
|
|
800
|
+
ui: 'jsonEditor';
|
|
801
|
+
default: string;
|
|
802
|
+
} & ZPropertyBase;
|
|
803
|
+
|
|
804
|
+
declare type ZPropertyMultiTypes = {
|
|
805
|
+
ui: 'multiTypes';
|
|
806
|
+
types: ZTypesKey;
|
|
807
|
+
default: string;
|
|
808
|
+
} & ZPropertyBase;
|
|
809
|
+
|
|
810
|
+
declare type ZPropertyNumInput = {
|
|
811
|
+
ui: 'numInput';
|
|
812
|
+
precision?: number;
|
|
813
|
+
min?: number;
|
|
814
|
+
max?: number;
|
|
815
|
+
step?: number;
|
|
816
|
+
default: number;
|
|
817
|
+
} & ZPropertyBase;
|
|
818
|
+
|
|
819
|
+
declare type ZPropertySelect = {
|
|
820
|
+
ui: 'select';
|
|
821
|
+
items: ZItemsKey;
|
|
822
|
+
default: string;
|
|
823
|
+
} & ZPropertyBase;
|
|
824
|
+
|
|
825
|
+
declare type ZPropertySelectAdaptSlot = {
|
|
826
|
+
ui: 'selectAdaptSlot';
|
|
827
|
+
default: string;
|
|
828
|
+
} & ZPropertyBase;
|
|
829
|
+
|
|
830
|
+
declare type ZPropertySelectComp = {
|
|
831
|
+
ui: 'selectComp';
|
|
832
|
+
default: string;
|
|
833
|
+
} & ZPropertyBase;
|
|
834
|
+
|
|
835
|
+
declare type ZPropertySelectInlineSlot = {
|
|
836
|
+
ui: 'selectInlineSlot';
|
|
837
|
+
default: string;
|
|
838
|
+
} & ZPropertyBase;
|
|
839
|
+
|
|
840
|
+
declare type ZPropertySelectSlot = {
|
|
841
|
+
ui: 'selectSlot';
|
|
842
|
+
default: string;
|
|
843
|
+
} & ZPropertyBase;
|
|
844
|
+
|
|
845
|
+
declare type ZPropertyStrInput = {
|
|
846
|
+
ui: 'strInput';
|
|
847
|
+
default: string;
|
|
848
|
+
} & ZPropertyBase;
|
|
849
|
+
|
|
850
|
+
declare type ZPropertySwitch = {
|
|
851
|
+
ui: 'switch';
|
|
852
|
+
default: boolean;
|
|
853
|
+
} & ZPropertyBase;
|
|
854
|
+
|
|
855
|
+
declare type ZPropertyTransient<T extends Type> = {
|
|
856
|
+
ui: 'transient';
|
|
857
|
+
type: T;
|
|
858
|
+
} & ZPropertyBase & {
|
|
859
|
+
string: {
|
|
860
|
+
default: string;
|
|
861
|
+
};
|
|
862
|
+
number: {
|
|
863
|
+
default: number;
|
|
864
|
+
};
|
|
865
|
+
boolean: {
|
|
866
|
+
default: boolean;
|
|
867
|
+
};
|
|
868
|
+
object: {
|
|
869
|
+
default: object;
|
|
870
|
+
};
|
|
871
|
+
array: {
|
|
872
|
+
default: object;
|
|
873
|
+
};
|
|
874
|
+
any: {
|
|
875
|
+
default: any;
|
|
876
|
+
};
|
|
877
|
+
}[T];
|
|
878
|
+
|
|
879
|
+
export declare type ZSlot = {
|
|
880
|
+
key: string;
|
|
881
|
+
name: string;
|
|
882
|
+
multiple?: boolean;
|
|
883
|
+
properties?: ZSlotProperty[];
|
|
884
|
+
methods?: ZSlotMethod[];
|
|
885
|
+
events?: ZSlotEvent[];
|
|
886
|
+
desc?: string;
|
|
887
|
+
};
|
|
888
|
+
|
|
889
|
+
export declare type ZSlotEvent = {
|
|
890
|
+
key: string;
|
|
891
|
+
name: string;
|
|
892
|
+
params?: {
|
|
893
|
+
key: string;
|
|
894
|
+
name: string;
|
|
895
|
+
type: Type;
|
|
896
|
+
desc?: string;
|
|
897
|
+
}[];
|
|
898
|
+
desc?: string;
|
|
899
|
+
};
|
|
900
|
+
|
|
901
|
+
export declare type ZSlotMethod = {
|
|
902
|
+
key: string;
|
|
903
|
+
name: string;
|
|
904
|
+
inputs?: {
|
|
905
|
+
key: string;
|
|
906
|
+
name: string;
|
|
907
|
+
type: Type;
|
|
908
|
+
desc?: string;
|
|
909
|
+
}[];
|
|
910
|
+
outputs?: {
|
|
911
|
+
key: string;
|
|
912
|
+
name: string;
|
|
913
|
+
type: Type;
|
|
914
|
+
desc?: string;
|
|
915
|
+
}[];
|
|
916
|
+
desc?: string;
|
|
917
|
+
};
|
|
918
|
+
|
|
919
|
+
export declare type ZSlotProperty = {
|
|
920
|
+
key: string;
|
|
921
|
+
name: string;
|
|
922
|
+
type: Type;
|
|
923
|
+
readonly?: boolean;
|
|
924
|
+
desc?: string;
|
|
925
|
+
};
|
|
926
|
+
|
|
927
|
+
export declare type ZSpawnFunc = (type: string, subtype: string, ...params: any[]) => ZSpawnResult;
|
|
928
|
+
|
|
929
|
+
export declare interface ZSpawnResult {
|
|
930
|
+
nodePairs: NodePair[];
|
|
931
|
+
blockStates?: BlockState[];
|
|
932
|
+
}
|
|
933
|
+
|
|
934
|
+
export declare type ZType = ZTypeWord | ZTypePixel | ZTypePercent | ZTypeHexColor | ZTypeThemeColor;
|
|
935
|
+
|
|
936
|
+
declare type ZTypeBase = {
|
|
937
|
+
value: string;
|
|
938
|
+
title: string;
|
|
939
|
+
validator: (v: unknown) => boolean;
|
|
940
|
+
};
|
|
941
|
+
|
|
942
|
+
declare type ZTypeHexColor = {
|
|
943
|
+
trait: 'hexColor';
|
|
944
|
+
default: string;
|
|
945
|
+
} & ZTypeBase;
|
|
946
|
+
|
|
947
|
+
declare type ZTypePercent = {
|
|
948
|
+
trait: 'percent';
|
|
949
|
+
precision?: number;
|
|
950
|
+
min?: number;
|
|
951
|
+
max?: number;
|
|
952
|
+
step?: number;
|
|
953
|
+
default: string;
|
|
954
|
+
} & ZTypeBase;
|
|
955
|
+
|
|
956
|
+
declare type ZTypePixel = {
|
|
957
|
+
trait: 'pixel';
|
|
958
|
+
precision?: number;
|
|
959
|
+
min?: number;
|
|
960
|
+
max?: number;
|
|
961
|
+
step?: number;
|
|
962
|
+
default: string;
|
|
963
|
+
} & ZTypeBase;
|
|
964
|
+
|
|
965
|
+
export declare type ZTypesKey = (typeof typesKeys)[number];
|
|
966
|
+
|
|
967
|
+
declare type ZTypeThemeColor = {
|
|
968
|
+
trait: 'themeColor';
|
|
969
|
+
default: string;
|
|
970
|
+
} & ZTypeBase;
|
|
971
|
+
|
|
972
|
+
declare type ZTypeWord = {
|
|
973
|
+
trait: 'word';
|
|
974
|
+
default: string;
|
|
975
|
+
} & ZTypeBase;
|
|
976
|
+
|
|
977
|
+
export { }
|