@vev/silke 1.0.18 → 1.0.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/dist/{chunk-SOFGXMET.js → chunk-FIPWO3IB.js} +3 -3
- package/dist/{chunk-SOFGXMET.js.map → chunk-FIPWO3IB.js.map} +1 -1
- package/dist/index.js +21 -22
- package/dist/index.js.LEGAL.txt +7 -7
- package/dist/index.js.map +4 -4
- package/dist/silke/src/components/index.d.ts +54 -0
- package/dist/silke/src/components/silke-autocomplete-field/autocomplete-item.d.ts +19 -0
- package/dist/silke/src/components/silke-autocomplete-field/autocomplete-tags.d.ts +9 -0
- package/dist/silke/src/components/silke-autocomplete-field/autocomplete-types.d.ts +55 -0
- package/dist/silke/src/components/silke-autocomplete-field/index.d.ts +5 -0
- package/dist/silke/src/components/silke-autocomplete-field/silke-autocomplete-field.d.ts +50 -0
- package/dist/silke/src/components/silke-box/index.d.ts +1 -0
- package/dist/silke/src/components/silke-box/silke-box.d.ts +121 -0
- package/dist/silke/src/components/silke-breadcrumbs/index.d.ts +2 -0
- package/dist/silke/src/components/silke-breadcrumbs/silke-breadcrumb.d.ts +10 -0
- package/dist/silke/src/components/silke-breadcrumbs/silke-breadcrumbs.d.ts +7 -0
- package/dist/silke/src/components/silke-button/context.d.ts +14 -0
- package/dist/silke/src/components/silke-button/index.d.ts +7 -0
- package/dist/silke/src/components/silke-button/silke-big-button.d.ts +13 -0
- package/dist/silke/src/components/silke-button/silke-button-set.d.ts +11 -0
- package/dist/silke/src/components/silke-button/silke-button.d.ts +39 -0
- package/dist/silke/src/components/silke-button/silke-confirmation-button.d.ts +8 -0
- package/dist/silke/src/components/silke-button/silke-file-select-button.d.ts +9 -0
- package/dist/silke/src/components/silke-card/index.d.ts +2 -0
- package/dist/silke/src/components/silke-card/silke-card-grid.d.ts +10 -0
- package/dist/silke/src/components/silke-card/silke-card.d.ts +24 -0
- package/dist/silke/src/components/silke-checkbox/index.d.ts +1 -0
- package/dist/silke/src/components/silke-checkbox/silke-checkbox.d.ts +11 -0
- package/dist/silke/src/components/silke-code-editor/index.d.ts +3 -0
- package/dist/silke/src/components/silke-code-editor/silke-code-editor.d.ts +8 -0
- package/dist/silke/src/components/silke-code-snippet/index.d.ts +1 -0
- package/dist/silke/src/components/silke-code-snippet/silke-code-snippet.d.ts +17 -0
- package/dist/silke/src/components/silke-color-palettes/index.d.ts +2 -0
- package/dist/silke/src/components/silke-color-palettes/silke-color-palette.d.ts +12 -0
- package/dist/silke/src/components/silke-color-palettes/silke-color-palettes.d.ts +8 -0
- package/dist/silke/src/components/silke-color-picker/color.d.ts +31 -0
- package/dist/silke/src/components/silke-color-picker/hue.d.ts +7 -0
- package/dist/silke/src/components/silke-color-picker/index.d.ts +4 -0
- package/dist/silke/src/components/silke-color-picker/silke-color-info.d.ts +9 -0
- package/dist/silke/src/components/silke-color-picker/silke-color-picker-button.d.ts +11 -0
- package/dist/silke/src/components/silke-color-picker/silke-color-picker.d.ts +17 -0
- package/dist/silke/src/components/silke-color-picker/silke-color-space.d.ts +11 -0
- package/dist/silke/src/components/silke-color-picker/silke-hue-slider.d.ts +7 -0
- package/dist/silke/src/components/silke-color-picker/silke-opacity-slider.d.ts +8 -0
- package/dist/silke/src/components/silke-color-swatches/index.d.ts +2 -0
- package/dist/silke/src/components/silke-color-swatches/silke-color-swatch-button.d.ts +6 -0
- package/dist/silke/src/components/silke-color-swatches/silke-swatches.d.ts +25 -0
- package/dist/silke/src/components/silke-color-swatches/utils.d.ts +12 -0
- package/dist/silke/src/components/silke-content-column/index.d.ts +1 -0
- package/dist/silke/src/components/silke-content-column/silke-content-column.d.ts +7 -0
- package/dist/silke/src/components/silke-context-menu/index.d.ts +2 -0
- package/dist/silke/src/components/silke-context-menu/silke-contect-menu-hooks.d.ts +0 -0
- package/dist/silke/src/components/silke-context-menu/silke-context-menu-item.d.ts +12 -0
- package/dist/silke/src/components/silke-context-menu/silke-context-menu.d.ts +15 -0
- package/dist/silke/src/components/silke-css-number-field/index.d.ts +2 -0
- package/dist/silke/src/components/silke-css-number-field/silke-css-context.d.ts +29 -0
- package/dist/silke/src/components/silke-css-number-field/silke-css-number-field.d.ts +15 -0
- package/dist/silke/src/components/silke-css-number-field/utils.d.ts +32 -0
- package/dist/silke/src/components/silke-divider/index.d.ts +1 -0
- package/dist/silke/src/components/silke-divider/silke-divider.d.ts +13 -0
- package/dist/silke/src/components/silke-drawer/index.d.ts +1 -0
- package/dist/silke/src/components/silke-drawer/silke-drawer.d.ts +12 -0
- package/dist/silke/src/components/silke-form/form-context.d.ts +26 -0
- package/dist/silke/src/components/silke-form/form-types.d.ts +44 -0
- package/dist/silke/src/components/silke-form/index.d.ts +2 -0
- package/dist/silke/src/components/silke-form/silke-form.d.ts +22 -0
- package/dist/silke/src/components/silke-form-schema/fields/array-field-inline.d.ts +12 -0
- package/dist/silke/src/components/silke-form-schema/fields/array-field-modal.d.ts +13 -0
- package/dist/silke/src/components/silke-form-schema/fields/array-field.d.ts +4 -0
- package/dist/silke/src/components/silke-form-schema/fields/event-field.d.ts +4 -0
- package/dist/silke/src/components/silke-form-schema/fields/icon-field.d.ts +4 -0
- package/dist/silke/src/components/silke-form-schema/fields/image-field.d.ts +4 -0
- package/dist/silke/src/components/silke-form-schema/fields/layout-field.d.ts +3 -0
- package/dist/silke/src/components/silke-form-schema/fields/link-field.d.ts +4 -0
- package/dist/silke/src/components/silke-form-schema/fields/number-field.d.ts +4 -0
- package/dist/silke/src/components/silke-form-schema/fields/object-field.d.ts +3 -0
- package/dist/silke/src/components/silke-form-schema/fields/select-field.d.ts +4 -0
- package/dist/silke/src/components/silke-form-schema/fields/string-field.d.ts +4 -0
- package/dist/silke/src/components/silke-form-schema/fields/toggle-field.d.ts +4 -0
- package/dist/silke/src/components/silke-form-schema/fields/upload-field.d.ts +4 -0
- package/dist/silke/src/components/silke-form-schema/fields/utils/generate-image.d.ts +3 -0
- package/dist/silke/src/components/silke-form-schema/fields/utils/generate-title.d.ts +7 -0
- package/dist/silke/src/components/silke-form-schema/fields/utils/index.d.ts +2 -0
- package/dist/silke/src/components/silke-form-schema/fields/utils/schema-util.d.ts +2 -0
- package/dist/silke/src/components/silke-form-schema/index.d.ts +4 -0
- package/dist/silke/src/components/silke-form-schema/safe-eval/iframe-handler.d.ts +17 -0
- package/dist/silke/src/components/silke-form-schema/safe-eval/index.d.ts +1 -0
- package/dist/silke/src/components/silke-form-schema/safe-eval/safe-eval.d.ts +1 -0
- package/dist/silke/src/components/silke-form-schema/schema-utils.d.ts +11 -0
- package/dist/silke/src/components/silke-form-schema/silke-extended-fields-context.d.ts +13 -0
- package/dist/silke/src/components/silke-form-schema/silke-form-schema.d.ts +13 -0
- package/dist/silke/src/components/silke-form-schema/silke-schema-context.d.ts +9 -0
- package/dist/silke/src/components/silke-form-schema/silke-schema-field.d.ts +10 -0
- package/dist/silke/src/components/silke-form-schema/silke-schema-fields.d.ts +14 -0
- package/dist/silke/src/components/silke-gradient-picker/index.d.ts +1 -0
- package/dist/silke/src/components/silke-gradient-picker/silke-gradient-picker.d.ts +5 -0
- package/dist/silke/src/components/silke-gradient-picker/silke-gradient-position.d.ts +8 -0
- package/dist/silke/src/components/silke-gradient-picker/silke-gradient-slider.d.ts +10 -0
- package/dist/silke/src/components/silke-gradient-picker/silke-gradient-utils.d.ts +14 -0
- package/dist/silke/src/components/silke-icon/index.d.ts +2 -0
- package/dist/silke/src/components/silke-icon/silke-icon.d.ts +11 -0
- package/dist/silke/src/components/silke-icon/silke-shape.d.ts +8 -0
- package/dist/silke/src/components/silke-icon/silke-stacked-icon.d.ts +8 -0
- package/dist/silke/src/components/silke-icon-picker/emoji-tab.d.ts +3 -0
- package/dist/silke/src/components/silke-icon-picker/icons-tab.d.ts +3 -0
- package/dist/silke/src/components/silke-icon-picker/index.d.ts +1 -0
- package/dist/silke/src/components/silke-icon-picker/silke-icon-picker.d.ts +12 -0
- package/dist/silke/src/components/silke-icon-picker/upload-tab.d.ts +3 -0
- package/dist/silke/src/components/silke-icon-picker/utils.d.ts +5 -0
- package/dist/silke/src/components/silke-iframe-portal/index.d.ts +4 -0
- package/dist/silke/src/components/silke-iframe-portal/silke-iframe-context.d.ts +7 -0
- package/dist/silke/src/components/silke-iframe-portal/silke-iframe-css-link.d.ts +5 -0
- package/dist/silke/src/components/silke-iframe-portal/silke-iframe-portal.d.ts +10 -0
- package/dist/silke/src/components/silke-iframe-portal/silke-iframe-script.d.ts +6 -0
- package/dist/silke/src/components/silke-image/index.d.ts +2 -0
- package/dist/silke/src/components/silke-image/silke-image-color-backdrop.d.ts +7 -0
- package/dist/silke/src/components/silke-image/silke-image.d.ts +11 -0
- package/dist/silke/src/components/silke-link/index.d.ts +1 -0
- package/dist/silke/src/components/silke-link/silke-link.d.ts +23 -0
- package/dist/silke/src/components/silke-list/index.d.ts +2 -0
- package/dist/silke/src/components/silke-list/silke-list-item.d.ts +7 -0
- package/dist/silke/src/components/silke-list/silke-list.d.ts +10 -0
- package/dist/silke/src/components/silke-list-card/index.d.ts +1 -0
- package/dist/silke/src/components/silke-list-card/silke-list-card.d.ts +14 -0
- package/dist/silke/src/components/silke-loader/index.d.ts +2 -0
- package/dist/silke/src/components/silke-loader/silke-loader-overlay.d.ts +18 -0
- package/dist/silke/src/components/silke-loader/silke-loader.d.ts +18 -0
- package/dist/silke/src/components/silke-modal/index.d.ts +2 -0
- package/dist/silke/src/components/silke-modal/silke-confirmation-modal.d.ts +31 -0
- package/dist/silke/src/components/silke-modal/silke-modal.d.ts +18 -0
- package/dist/silke/src/components/silke-navigation-link/index.d.ts +1 -0
- package/dist/silke/src/components/silke-navigation-link/silke-navigation-link.d.ts +22 -0
- package/dist/silke/src/components/silke-notification/confetti.d.ts +2 -0
- package/dist/silke/src/components/silke-notification/index.d.ts +1 -0
- package/dist/silke/src/components/silke-notification/silke-notification.d.ts +22 -0
- package/dist/silke/src/components/silke-object-field/index.d.ts +1 -0
- package/dist/silke/src/components/silke-object-field/silke-object-field.d.ts +17 -0
- package/dist/silke/src/components/silke-overflow-menu/index.d.ts +1 -0
- package/dist/silke/src/components/silke-overflow-menu/silke-overflow-menu.d.ts +21 -0
- package/dist/silke/src/components/silke-popover/index.d.ts +1 -0
- package/dist/silke/src/components/silke-popover/popover-context.d.ts +8 -0
- package/dist/silke/src/components/silke-popover/silke-popover.d.ts +48 -0
- package/dist/silke/src/components/silke-progress-indicator/index.d.ts +2 -0
- package/dist/silke/src/components/silke-progress-indicator/silke-progress-indicator.d.ts +7 -0
- package/dist/silke/src/components/silke-progress-indicator/silke-progress-step.d.ts +11 -0
- package/dist/silke/src/components/silke-radio-button/index.d.ts +2 -0
- package/dist/silke/src/components/silke-radio-button/silke-radio-button-group.d.ts +15 -0
- package/dist/silke/src/components/silke-radio-button/silke-radio-button.d.ts +10 -0
- package/dist/silke/src/components/silke-search-field/index.d.ts +1 -0
- package/dist/silke/src/components/silke-search-field/silke-search-field.d.ts +8 -0
- package/dist/silke/src/components/silke-select-field/index.d.ts +1 -0
- package/dist/silke/src/components/silke-select-field/silke-select-field.d.ts +5 -0
- package/dist/silke/src/components/silke-skeleton/index.d.ts +1 -0
- package/dist/silke/src/components/silke-skeleton/silke-skeleton.d.ts +8 -0
- package/dist/silke/src/components/silke-slider/index.d.ts +1 -0
- package/dist/silke/src/components/silke-slider/silke-slider-point.d.ts +14 -0
- package/dist/silke/src/components/silke-slider/silke-slider-utils.d.ts +2 -0
- package/dist/silke/src/components/silke-slider/silke-slider.d.ts +20 -0
- package/dist/silke/src/components/silke-slider/slider-track.d.ts +9 -0
- package/dist/silke/src/components/silke-sortable-list/index.d.ts +2 -0
- package/dist/silke/src/components/silke-sortable-list/silke-nested-sortable-item.d.ts +16 -0
- package/dist/silke/src/components/silke-sortable-list/silke-nested-sortable-list.d.ts +25 -0
- package/dist/silke/src/components/silke-sortable-list/silke-nested-sortable-utils.d.ts +57 -0
- package/dist/silke/src/components/silke-sortable-list/silke-sortable-item-wrapper.d.ts +12 -0
- package/dist/silke/src/components/silke-sortable-list/silke-sortable-list.d.ts +15 -0
- package/dist/silke/src/components/silke-steps/index.d.ts +1 -0
- package/dist/silke/src/components/silke-steps/silke-steps.d.ts +12 -0
- package/dist/silke/src/components/silke-table/index.d.ts +2 -0
- package/dist/silke/src/components/silke-table/silke-table.d.ts +27 -0
- package/dist/silke/src/components/silke-table/table-row.d.ts +13 -0
- package/dist/silke/src/components/silke-table/table-types.d.ts +13 -0
- package/dist/silke/src/components/silke-tabs/index.d.ts +2 -0
- package/dist/silke/src/components/silke-tabs/silke-tab.d.ts +12 -0
- package/dist/silke/src/components/silke-tabs/silke-tabs.d.ts +10 -0
- package/dist/silke/src/components/silke-tag/index.d.ts +1 -0
- package/dist/silke/src/components/silke-tag/silke-tag.d.ts +40 -0
- package/dist/silke/src/components/silke-text/index.d.ts +3 -0
- package/dist/silke/src/components/silke-text/silke-text-types.d.ts +28 -0
- package/dist/silke/src/components/silke-text/silke-text.d.ts +275 -0
- package/dist/silke/src/components/silke-text/silke-title.d.ts +3 -0
- package/dist/silke/src/components/silke-text-field/index.d.ts +3 -0
- package/dist/silke/src/components/silke-text-field/silke-text-field-item.d.ts +8 -0
- package/dist/silke/src/components/silke-text-field/silke-text-field-outline.d.ts +39 -0
- package/dist/silke/src/components/silke-text-field/silke-text-field.d.ts +27 -0
- package/dist/silke/src/components/silke-text-field/text-field-context.d.ts +9 -0
- package/dist/silke/src/components/silke-theme-editor/index.d.ts +1 -0
- package/dist/silke/src/components/silke-theme-editor/silke-theme-editor.d.ts +9 -0
- package/dist/silke/src/components/silke-tile/index.d.ts +2 -0
- package/dist/silke/src/components/silke-tile/silke-tile-select.d.ts +26 -0
- package/dist/silke/src/components/silke-tile/silke-tile.d.ts +38 -0
- package/dist/silke/src/components/silke-toggle/index.d.ts +1 -0
- package/dist/silke/src/components/silke-toggle/silke-toggle.d.ts +12 -0
- package/dist/silke/src/components/silke-toolbar/index.d.ts +1 -0
- package/dist/silke/src/components/silke-toolbar/silke-toolbar.d.ts +7 -0
- package/dist/silke/src/components/silke-tooltip/index.d.ts +5 -0
- package/dist/silke/src/components/silke-tooltip/silke-definition-tooltip.d.ts +16 -0
- package/dist/silke/src/components/silke-tooltip/silke-icon-tooltip.d.ts +17 -0
- package/dist/silke/src/components/silke-tooltip/silke-interactive-tooltip.d.ts +24 -0
- package/dist/silke/src/components/silke-tooltip/silke-shortcuts.d.ts +37 -0
- package/dist/silke/src/components/silke-tooltip/silke-tooltip.d.ts +25 -0
- package/dist/silke/src/components/silke-tooltip/utils.d.ts +1 -0
- package/dist/silke/src/components/silke-upload-field/index.d.ts +1 -0
- package/dist/silke/src/components/silke-upload-field/silke-upload-field.d.ts +32 -0
- package/dist/silke/src/components/silke-virtual/index.d.ts +2 -0
- package/dist/silke/src/components/silke-virtual/silke-virtual-grid.d.ts +9 -0
- package/dist/silke/src/components/silke-virtual/silke-virtual-row.d.ts +10 -0
- package/dist/silke/src/docs/app.d.ts +4 -0
- package/dist/silke/src/docs/components/code-block/code-block.d.ts +6 -0
- package/dist/silke/src/docs/components/code-block/index.d.ts +1 -0
- package/dist/silke/src/docs/components/state-table/index.d.ts +1 -0
- package/dist/silke/src/docs/components/state-table/state-table.d.ts +14 -0
- package/dist/silke/src/docs/data/app/actions.d.ts +1 -0
- package/dist/silke/src/docs/data/app/constants.d.ts +6 -0
- package/dist/silke/src/docs/data/app/index.d.ts +3 -0
- package/dist/silke/src/docs/data/app/store.d.ts +8 -0
- package/dist/silke/src/docs/data/flux/action-decorator.d.ts +5 -0
- package/dist/silke/src/docs/data/flux/action-utils.d.ts +7 -0
- package/dist/silke/src/docs/data/flux/controller.d.ts +24 -0
- package/dist/silke/src/docs/data/flux/dispatcher.d.ts +7 -0
- package/dist/silke/src/docs/data/flux/index.d.ts +6 -0
- package/dist/silke/src/docs/data/flux/store.d.ts +15 -0
- package/dist/silke/src/docs/data/flux/use-store.d.ts +2 -0
- package/dist/silke/src/docs/docs-provider.d.ts +6 -0
- package/dist/silke/src/docs/index.d.ts +2 -0
- package/dist/silke/src/docs/ipsum-generator.d.ts +7 -0
- package/dist/silke/src/helpers/copy-to-clipboard.d.ts +5 -0
- package/dist/silke/src/helpers/key-code.d.ts +9 -0
- package/dist/silke/src/hooks/drag-and-drop/index.d.ts +2 -0
- package/dist/silke/src/hooks/drag-and-drop/use-drag.d.ts +10 -0
- package/dist/silke/src/hooks/drag-and-drop/use-drop.d.ts +8 -0
- package/dist/silke/src/hooks/form/index.d.ts +1 -0
- package/dist/silke/src/hooks/form/use-form-field.d.ts +5 -0
- package/dist/silke/src/hooks/image-colors/use-image-colors.d.ts +10 -0
- package/dist/silke/src/hooks/index.d.ts +13 -0
- package/dist/silke/src/hooks/use-callback-ref.d.ts +2 -0
- package/dist/silke/src/hooks/use-dragging.d.ts +1 -0
- package/dist/silke/src/hooks/use-drop-zone.d.ts +2 -0
- package/dist/silke/src/hooks/use-html-element.d.ts +2 -0
- package/dist/silke/src/hooks/use-interval.d.ts +6 -0
- package/dist/silke/src/hooks/use-mouse.d.ts +40 -0
- package/dist/silke/src/hooks/use-parent-scroll.d.ts +2 -0
- package/dist/silke/src/hooks/use-scroll.d.ts +1 -0
- package/dist/silke/src/hooks/use-size.d.ts +4 -0
- package/dist/silke/src/hooks/use-uniq-id.d.ts +1 -0
- package/dist/silke/src/hooks/use-window-resize.d.ts +1 -0
- package/dist/silke/src/icons.d.ts +353 -0
- package/dist/silke/src/index.d.ts +5 -0
- package/dist/silke/src/main.d.ts +1 -0
- package/dist/silke/src/silke-theme-provider.d.ts +16 -0
- package/dist/silke-code-editor-HB2Z4Q5W.js +25 -0
- package/dist/silke-code-editor-HB2Z4Q5W.js.map +7 -0
- package/dist/styles.css +622 -661
- package/dist/utils/src/color/hex.d.ts +2 -0
- package/dist/utils/src/color/index.d.ts +1 -0
- package/dist/utils/src/constants.d.ts +2 -0
- package/dist/utils/src/css/computed-to-css.d.ts +8 -0
- package/dist/utils/src/css/computed.d.ts +5 -0
- package/dist/utils/src/css/index.d.ts +4 -0
- package/dist/utils/src/css/number-format.d.ts +1 -0
- package/dist/utils/src/css/utils.d.ts +14 -0
- package/dist/utils/src/events/condition-parser/evaluate-condition-expression.d.ts +2 -0
- package/dist/utils/src/events/condition-parser/index.d.ts +1 -0
- package/dist/utils/src/events/condition-parser/lexer.d.ts +36 -0
- package/dist/utils/src/events/condition-parser/parser.d.ts +11 -0
- package/dist/utils/src/index.d.ts +10 -0
- package/dist/utils/src/interactions/get-node-type.d.ts +2 -0
- package/dist/utils/src/interactions/has-link.d.ts +5 -0
- package/dist/utils/src/interactions/has-pointer-event.d.ts +5 -0
- package/dist/utils/src/interactions/index.d.ts +5 -0
- package/dist/utils/src/interactions/is-target-global.d.ts +2 -0
- package/dist/utils/src/interactions/is-trigger-global.d.ts +2 -0
- package/dist/utils/src/keyboard/hooks.d.ts +8 -0
- package/dist/utils/src/keyboard/index.d.ts +4 -0
- package/dist/utils/src/keyboard/key-list.d.ts +4 -0
- package/dist/utils/src/keyboard/keyboard.d.ts +70 -0
- package/dist/utils/src/keyboard/keys.d.ts +4 -0
- package/dist/utils/src/math/index.d.ts +9 -0
- package/dist/utils/src/mouse/index.d.ts +3 -0
- package/dist/utils/src/mouse/mouse-manager.d.ts +52 -0
- package/dist/utils/src/types/content.d.ts +11 -0
- package/dist/utils/src/types/context.d.ts +74 -0
- package/dist/utils/src/types/css.d.ts +131 -0
- package/dist/utils/src/types/editable-css.d.ts +7 -0
- package/dist/utils/src/types/emoji.d.ts +28 -0
- package/dist/utils/src/types/event.d.ts +7 -0
- package/dist/utils/src/types/icon.d.ts +10 -0
- package/dist/utils/src/types/index.d.ts +17 -0
- package/dist/utils/src/types/interaction.d.ts +77 -0
- package/dist/utils/src/types/link.d.ts +47 -0
- package/dist/utils/src/types/manifest.d.ts +54 -0
- package/dist/utils/src/types/project.d.ts +23 -0
- package/dist/utils/src/types/shape.d.ts +20 -0
- package/dist/utils/src/types/transition.d.ts +15 -0
- package/dist/utils/src/types/vev-plugin.d.ts +30 -0
- package/dist/utils/src/types/vev-props.d.ts +154 -0
- package/dist/utils/src/types/widget-manifest.d.ts +69 -0
- package/dist/utils/src/types/widget.d.ts +36 -0
- package/dist/utils/src/utils/generate-guid.d.ts +1 -0
- package/dist/utils/src/utils/index.d.ts +7 -0
- package/dist/utils/src/utils/internals/asciiToArray.d.ts +9 -0
- package/dist/utils/src/utils/internals/castSlice.d.ts +11 -0
- package/dist/utils/src/utils/internals/createCaseFirst.d.ts +9 -0
- package/dist/utils/src/utils/internals/getTag.d.ts +9 -0
- package/dist/utils/src/utils/internals/hasUnicode.d.ts +9 -0
- package/dist/utils/src/utils/internals/stringToArray.d.ts +9 -0
- package/dist/utils/src/utils/internals/unicodeToArray.d.ts +9 -0
- package/dist/utils/src/utils/internals/unicodeWords.d.ts +9 -0
- package/dist/utils/src/utils/internals/upperFirst.d.ts +18 -0
- package/dist/utils/src/utils/is-array.d.ts +25 -0
- package/dist/utils/src/utils/is-length.d.ts +26 -0
- package/dist/utils/src/utils/is-string.d.ts +17 -0
- package/dist/utils/src/utils/slice.d.ts +22 -0
- package/dist/utils/src/utils/start-case.d.ts +22 -0
- package/dist/utils/src/utils/string.d.ts +5 -0
- package/dist/utils/src/utils/words.d.ts +18 -0
- package/package.json +7 -7
- package/src/components/index.ts +1 -0
- package/src/components/silke-autocomplete-field/autocomplete-tags.tsx +1 -1
- package/src/components/silke-autocomplete-field/index.ts +4 -0
- package/src/components/silke-autocomplete-field/silke-autocomplete-field.tsx +4 -1
- package/src/components/silke-card/silke-card-grid.tsx +18 -15
- package/src/components/silke-card/silke-card.mdx +56 -23
- package/src/components/silke-card/silke-card.scss +150 -115
- package/src/components/silke-card/silke-card.tsx +173 -112
- package/src/components/silke-color-picker/color-picker.scss +29 -24
- package/src/components/silke-color-picker/hue.ts +72 -0
- package/src/components/silke-color-picker/index.ts +2 -1
- package/src/components/silke-color-picker/silke-color-picker.mdx +18 -0
- package/src/components/silke-color-picker/silke-color-picker.tsx +5 -5
- package/src/components/silke-color-picker/silke-color-space.tsx +0 -2
- package/src/components/silke-color-picker/silke-hue-slider.tsx +23 -8
- package/src/components/silke-color-picker/silke-opacity-slider.tsx +10 -12
- package/src/components/silke-content-column/silke-content-column.scss +2 -37
- package/src/components/silke-context-menu/silke-context-menu.tsx +1 -2
- package/src/components/silke-form/form-context.tsx +5 -5
- package/src/components/silke-form/form-types.ts +1 -0
- package/src/components/silke-form/silke-form.tsx +1 -1
- package/src/components/silke-form-schema/fields/array-field.tsx +2 -2
- package/src/components/silke-form-schema/fields/number-field.tsx +40 -27
- package/src/components/silke-form-schema/fields/select-field.tsx +3 -8
- package/src/components/silke-form-schema/fields/string-field.tsx +29 -15
- package/src/components/silke-form-schema/fields/styles.scss +3 -1
- package/src/components/silke-form-schema/fields/toggle-field.tsx +2 -3
- package/src/components/silke-form-schema/fields/upload-field.tsx +2 -4
- package/src/components/silke-form-schema/fields/utils/generate-title.ts +3 -3
- package/src/components/silke-form-schema/silke-form-schema.tsx +7 -2
- package/src/components/silke-form-schema/silke-schema-context.tsx +5 -2
- package/src/components/silke-form-schema/silke-schema-field.tsx +36 -40
- package/src/components/silke-form-schema/silke-schema-fields.tsx +39 -14
- package/src/components/silke-gradient-picker/index.ts +1 -0
- package/src/components/silke-gradient-picker/silke-gradient-picker.mdx +13 -0
- package/src/components/silke-gradient-picker/silke-gradient-picker.module.scss +71 -0
- package/src/components/silke-gradient-picker/silke-gradient-picker.tsx +71 -0
- package/src/components/silke-gradient-picker/silke-gradient-position.tsx +160 -0
- package/src/components/silke-gradient-picker/silke-gradient-slider.tsx +57 -0
- package/src/components/silke-gradient-picker/silke-gradient-utils.ts +132 -0
- package/src/components/silke-image/index.ts +1 -0
- package/src/components/silke-image/silke-image-color-backdrop.scss +10 -0
- package/src/components/silke-image/silke-image-color-backdrop.tsx +32 -0
- package/src/components/silke-image/silke-image.tsx +6 -2
- package/src/components/silke-modal/silke-confirmation-modal.tsx +33 -11
- package/src/components/silke-modal/silke-modal.mdx +24 -0
- package/src/components/silke-navigation-link/silke-navigation-link.tsx +83 -76
- package/src/components/silke-object-field/silke-object-field.tsx +1 -1
- package/src/components/silke-overflow-menu/silke-overflow-menu.tsx +1 -0
- package/src/components/silke-radio-button/silke-radio-button-group.tsx +6 -23
- package/src/components/silke-slider/index.ts +0 -1
- package/src/components/silke-slider/silke-slider-point.tsx +43 -0
- package/src/components/silke-slider/silke-slider-utils.ts +32 -0
- package/src/components/silke-slider/silke-slider.mdx +45 -0
- package/src/components/silke-slider/silke-slider.module.scss +71 -0
- package/src/components/silke-slider/silke-slider.tsx +160 -66
- package/src/components/silke-slider/slider-track.tsx +26 -0
- package/src/components/silke-sortable-list/silke-sortable-item-wrapper.tsx +3 -0
- package/src/components/silke-sortable-list/silke-sortable-list.scss +8 -8
- package/src/components/silke-sortable-list/silke-sortable-list.tsx +24 -7
- package/src/components/silke-table/silke-table.tsx +5 -5
- package/src/components/silke-tag/silke-tag.scss +107 -118
- package/src/components/silke-tag/silke-tag.tsx +8 -4
- package/src/components/silke-text/silke-text-types.ts +5 -6
- package/src/components/silke-text/silke-text.mdx +45 -11
- package/src/components/silke-text/silke-text.scss +40 -19
- package/src/components/silke-text/silke-text.tsx +10 -16
- package/src/components/silke-text/silke-title.scss +36 -57
- package/src/components/silke-text/silke-title.tsx +27 -17
- package/src/components/silke-text-field/silke-text-field.scss +0 -1
- package/src/components/silke-text-field/silke-text-field.tsx +6 -3
- package/src/components/silke-tooltip/silke-tooltip.tsx +3 -0
- package/src/components/silke-upload-field/silke-upload-field.tsx +16 -9
- package/src/docs/data/flux/action-decorator.ts +4 -4
- package/src/docs/data/flux/store.ts +4 -2
- package/src/hooks/drag-and-drop/use-drag.tsx +5 -3
- package/src/hooks/form/use-form-field.ts +4 -0
- package/src/hooks/image-colors/use-image-colors.ts +83 -0
- package/src/hooks/index.ts +1 -0
- package/src/hooks/use-dragging.ts +24 -0
- package/src/icons.tsx +3 -16
- package/src/styles/core.scss +0 -48
- package/tsconfig.json +1 -0
- package/dist/silke-code-editor-LBP2WDX3.js +0 -25
- package/dist/silke-code-editor-LBP2WDX3.js.map +0 -7
- package/src/components/silke-slider/range-slider.scss +0 -52
- package/src/components/silke-slider/silke-range-slider.tsx +0 -108
- package/src/components/silke-text/silke-text-utils.ts +0 -8
- /package/dist/{chunk-SOFGXMET.js.LEGAL.txt → chunk-FIPWO3IB.js.LEGAL.txt} +0 -0
- /package/dist/{silke-code-editor-LBP2WDX3.js.LEGAL.txt → silke-code-editor-HB2Z4Q5W.js.LEGAL.txt} +0 -0
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { VevProps } from '.';
|
|
2
|
+
export type VevCondition = string;
|
|
3
|
+
export declare enum TRIGGER_SCOPE {
|
|
4
|
+
POINTER_EVENT = "pointer-event",
|
|
5
|
+
SCROLL = "scroll",
|
|
6
|
+
GLOBAL = "global",
|
|
7
|
+
KEYBOARD = "keyboard"
|
|
8
|
+
}
|
|
9
|
+
export declare enum EVENT_SCOPE {
|
|
10
|
+
ELEMENT = "element",
|
|
11
|
+
PAGE = "page",
|
|
12
|
+
EXTERNAL = "external"
|
|
13
|
+
}
|
|
14
|
+
export type VevDispatchEvent = {
|
|
15
|
+
type?: string;
|
|
16
|
+
contentKey?: string;
|
|
17
|
+
args?: VevProps[];
|
|
18
|
+
};
|
|
19
|
+
export type TriggerItem = {
|
|
20
|
+
label: string;
|
|
21
|
+
value: VevTriggerType;
|
|
22
|
+
icon?: string;
|
|
23
|
+
scope?: EVENT_SCOPE | TRIGGER_SCOPE;
|
|
24
|
+
};
|
|
25
|
+
export declare enum NATIVE_TRIGGER_TYPES {
|
|
26
|
+
ON_CLICK = "onClick",
|
|
27
|
+
ON_MOUSE_ENTER = "onMouseEnter",
|
|
28
|
+
ON_MOUSE_LEAVE = "onMouseLeave",
|
|
29
|
+
ON_MOUSE_DOWN = "onMouseDown",
|
|
30
|
+
ON_MOUSE_UP = "onMouseUp",
|
|
31
|
+
ON_DOUBLE_CLICK = "onDoubleClick"
|
|
32
|
+
}
|
|
33
|
+
export declare const NATIVE_TRIGGERS: TriggerItem[];
|
|
34
|
+
export declare enum CUSTOM_TRIGGER_TYPES {
|
|
35
|
+
ON_VISIBLE = "onVisible",
|
|
36
|
+
ON_LEAVE = "onLeave"
|
|
37
|
+
}
|
|
38
|
+
export declare const CUSTOM_TRIGGERS: TriggerItem[];
|
|
39
|
+
export declare enum GLOBAL_TRIGGER_TYPES {
|
|
40
|
+
ON_SCROLL = "onScroll",
|
|
41
|
+
ON_TIMER = "onTimer",
|
|
42
|
+
ON_KEY_DOWN = "onKeyDown",
|
|
43
|
+
ON_KEY_UP = "onKeyUp"
|
|
44
|
+
}
|
|
45
|
+
export declare const GLOBAL_TRIGGERS: TriggerItem[];
|
|
46
|
+
export declare const GLOBAL_TRIGGER_ARGS: Record<GLOBAL_TRIGGER_TYPES, VevProps[]>;
|
|
47
|
+
export declare enum GLOBAL_EVENT_TYPES {
|
|
48
|
+
SHOW = "SHOW",
|
|
49
|
+
HIDE = "HIDE",
|
|
50
|
+
STICK = "STICK",
|
|
51
|
+
UNSTICK = "UNSTICK",
|
|
52
|
+
TOGGLE = "TOGGLE_VISIBILITY",
|
|
53
|
+
SCROLL_TO_ELEMENT = "SCROLL_TO_ELEMENT",
|
|
54
|
+
OPEN_PAGE = "OPEN_PAGE",
|
|
55
|
+
OPEN_URL = "OPEN_URL",
|
|
56
|
+
DOWNLOAD_FILE = "DOWNLOAD_FILE",
|
|
57
|
+
SEND_EMAIL = "SEND_EMAIL",
|
|
58
|
+
CALL_PHONE = "CALL_PHONE",
|
|
59
|
+
SEND_SMS = "SEND_SMS"
|
|
60
|
+
}
|
|
61
|
+
export declare const GLOBAL_EVENTS: TriggerItem[];
|
|
62
|
+
export declare const GLOBAL_EVENTS_ARGS: Record<GLOBAL_EVENT_TYPES, VevProps[]>;
|
|
63
|
+
export type VevTriggerType = NATIVE_TRIGGER_TYPES | CUSTOM_TRIGGER_TYPES | string;
|
|
64
|
+
export type VevTrigger = {
|
|
65
|
+
type: VevTriggerType;
|
|
66
|
+
contentKey?: string;
|
|
67
|
+
name?: string;
|
|
68
|
+
condition?: VevCondition;
|
|
69
|
+
args?: VevProps[];
|
|
70
|
+
};
|
|
71
|
+
export type ProjectInteraction = {
|
|
72
|
+
key: string;
|
|
73
|
+
event?: VevDispatchEvent;
|
|
74
|
+
trigger?: VevTrigger;
|
|
75
|
+
updated?: number;
|
|
76
|
+
deleted?: number;
|
|
77
|
+
};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { ITransition } from './transition';
|
|
2
|
+
import { WidgetModel } from './widget';
|
|
3
|
+
export declare enum LinkMode {
|
|
4
|
+
PAGE = 0,
|
|
5
|
+
WIDGET = 1,
|
|
6
|
+
EXTERNAL = 2,
|
|
7
|
+
EMAIL = 3,
|
|
8
|
+
PHONE = 4,
|
|
9
|
+
FILE = 5
|
|
10
|
+
}
|
|
11
|
+
export type LinkPageValue = {
|
|
12
|
+
mode: LinkMode.PAGE;
|
|
13
|
+
page?: string;
|
|
14
|
+
target?: boolean;
|
|
15
|
+
} & ITransition;
|
|
16
|
+
export type LinkElementValue = {
|
|
17
|
+
mode: LinkMode.WIDGET;
|
|
18
|
+
widget?: WidgetModel;
|
|
19
|
+
};
|
|
20
|
+
export type LinkExternalValue = {
|
|
21
|
+
mode: LinkMode.EXTERNAL;
|
|
22
|
+
href?: string;
|
|
23
|
+
nofollow?: boolean;
|
|
24
|
+
sponsored?: boolean;
|
|
25
|
+
target?: boolean;
|
|
26
|
+
};
|
|
27
|
+
export type LinkEmailValue = {
|
|
28
|
+
mode: LinkMode.EMAIL;
|
|
29
|
+
email?: string;
|
|
30
|
+
subject?: string;
|
|
31
|
+
};
|
|
32
|
+
export type LinkPhoneValue = {
|
|
33
|
+
mode: LinkMode.PHONE;
|
|
34
|
+
phone?: string;
|
|
35
|
+
};
|
|
36
|
+
export type LinkFileValue = {
|
|
37
|
+
mode: LinkMode.FILE;
|
|
38
|
+
download?: string;
|
|
39
|
+
title?: string;
|
|
40
|
+
file?: {
|
|
41
|
+
name: string;
|
|
42
|
+
size: number;
|
|
43
|
+
type: string;
|
|
44
|
+
url: string;
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
export type LinkFieldValue = LinkPageValue | LinkElementValue | LinkExternalValue | LinkEmailValue | LinkPhoneValue | LinkFileValue;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { FSWidgetPkgManifest } from './widget-manifest';
|
|
3
|
+
import { EditableCSS } from './editable-css';
|
|
4
|
+
import { VevProps } from './vev-props';
|
|
5
|
+
import { SchemaContextModel } from './context';
|
|
6
|
+
import { VevEvent } from './event';
|
|
7
|
+
export type VevManifest = Partial<Omit<FSWidgetPkgManifest, 'type' | 'size' | 'icon'>> & {
|
|
8
|
+
name: string;
|
|
9
|
+
type?: 'standard' | 'section' | 'both' | 'action';
|
|
10
|
+
children?: {
|
|
11
|
+
name: string;
|
|
12
|
+
icon?: string;
|
|
13
|
+
};
|
|
14
|
+
props?: VevProps[];
|
|
15
|
+
editableCSS?: EditableCSS[];
|
|
16
|
+
interactions?: VevEvent[];
|
|
17
|
+
events?: VevEvent[];
|
|
18
|
+
size?: Size;
|
|
19
|
+
panelType?: 'inline';
|
|
20
|
+
description?: string;
|
|
21
|
+
widgetFuncName?: string;
|
|
22
|
+
shareWithAccount?: boolean;
|
|
23
|
+
icon?: string;
|
|
24
|
+
emptyState?: ManifestEmptyState;
|
|
25
|
+
component?: (props: {
|
|
26
|
+
context: SchemaContextModel;
|
|
27
|
+
value: any;
|
|
28
|
+
onChange: (value: any) => void;
|
|
29
|
+
}) => ReactNode;
|
|
30
|
+
};
|
|
31
|
+
export type ManifestEmptyState = {
|
|
32
|
+
linkText?: string;
|
|
33
|
+
description?: string;
|
|
34
|
+
action?: 'OPEN_CONTENT_CHILDREN' | 'OPEN_PROPERTIES' | 'OPEN_INTERACTIONS';
|
|
35
|
+
checkProperty: string;
|
|
36
|
+
};
|
|
37
|
+
export type VevManifests = {
|
|
38
|
+
key: string;
|
|
39
|
+
public?: boolean | number;
|
|
40
|
+
admin?: boolean;
|
|
41
|
+
shareWithAccount: boolean;
|
|
42
|
+
children: FSWidgetPkgManifest[];
|
|
43
|
+
};
|
|
44
|
+
type SizeValue = number | 'auto';
|
|
45
|
+
export type WidthHeight = SizeValue | {
|
|
46
|
+
value: SizeValue;
|
|
47
|
+
autoOnly?: boolean;
|
|
48
|
+
valueOnly?: boolean;
|
|
49
|
+
};
|
|
50
|
+
type Size = {
|
|
51
|
+
width: WidthHeight;
|
|
52
|
+
height: WidthHeight;
|
|
53
|
+
};
|
|
54
|
+
export {};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { LinkFieldValue } from './link';
|
|
2
|
+
export type IProjectMenu = {
|
|
3
|
+
/**
|
|
4
|
+
* Items in this menu
|
|
5
|
+
*/
|
|
6
|
+
children: IMenuItem[];
|
|
7
|
+
/**
|
|
8
|
+
* Name of the menu
|
|
9
|
+
*/
|
|
10
|
+
title: string;
|
|
11
|
+
key: string;
|
|
12
|
+
};
|
|
13
|
+
export type IMenuItem = {
|
|
14
|
+
key: string;
|
|
15
|
+
title: string;
|
|
16
|
+
settings?: {
|
|
17
|
+
hidden: boolean;
|
|
18
|
+
};
|
|
19
|
+
link?: {
|
|
20
|
+
mode: number;
|
|
21
|
+
} & LinkFieldValue;
|
|
22
|
+
children?: IMenuItem[];
|
|
23
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export type IPoint = {
|
|
2
|
+
x: number;
|
|
3
|
+
y: number;
|
|
4
|
+
h: [IBezierPoint, IBezierPoint];
|
|
5
|
+
};
|
|
6
|
+
export type IBezierPoint = [number, number];
|
|
7
|
+
export type IShape = {
|
|
8
|
+
key: string;
|
|
9
|
+
name?: string;
|
|
10
|
+
type: number;
|
|
11
|
+
original: string;
|
|
12
|
+
updated: number;
|
|
13
|
+
path: IShapePath;
|
|
14
|
+
tags?: string[];
|
|
15
|
+
};
|
|
16
|
+
export type IShapePath = [number, number, string];
|
|
17
|
+
export type SvgDimensions = {
|
|
18
|
+
width: number;
|
|
19
|
+
height: number;
|
|
20
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export type ITweenAttr = [number, string, number, number];
|
|
2
|
+
export type ITween = {
|
|
3
|
+
opacity?: ITweenAttr;
|
|
4
|
+
scale?: ITweenAttr;
|
|
5
|
+
time?: number;
|
|
6
|
+
x?: ITweenAttr;
|
|
7
|
+
y?: ITweenAttr;
|
|
8
|
+
};
|
|
9
|
+
export type ITransition = {
|
|
10
|
+
timer?: number;
|
|
11
|
+
inFront?: boolean;
|
|
12
|
+
tweenIn?: ITween;
|
|
13
|
+
tweenOut?: ITween;
|
|
14
|
+
preset?: string;
|
|
15
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { VevProps } from './vev-props';
|
|
2
|
+
export interface AssetSourceResult {
|
|
3
|
+
images?: {
|
|
4
|
+
name: string;
|
|
5
|
+
url: string;
|
|
6
|
+
thumb: string;
|
|
7
|
+
type: string;
|
|
8
|
+
}[];
|
|
9
|
+
videos?: {
|
|
10
|
+
name: string;
|
|
11
|
+
url: string;
|
|
12
|
+
thumb: string;
|
|
13
|
+
type: string;
|
|
14
|
+
}[];
|
|
15
|
+
shapes?: {
|
|
16
|
+
name: string;
|
|
17
|
+
url: string;
|
|
18
|
+
thumb: string;
|
|
19
|
+
type: string;
|
|
20
|
+
}[];
|
|
21
|
+
}
|
|
22
|
+
export interface AssetSource {
|
|
23
|
+
type: 'asset-source';
|
|
24
|
+
id: string;
|
|
25
|
+
name: string;
|
|
26
|
+
form: VevProps[];
|
|
27
|
+
handler: (request: Request, env: Record<string, string>) => AssetSourceResult;
|
|
28
|
+
icon?: string;
|
|
29
|
+
}
|
|
30
|
+
export type VevPluginType = AssetSource;
|
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { SchemaContextModel } from './context';
|
|
3
|
+
export type EvalCallback = {
|
|
4
|
+
type: '__eval__';
|
|
5
|
+
value: string;
|
|
6
|
+
};
|
|
7
|
+
export type ImageType = {
|
|
8
|
+
url: string;
|
|
9
|
+
key: string;
|
|
10
|
+
};
|
|
11
|
+
export type ShapeType = {
|
|
12
|
+
key: string;
|
|
13
|
+
name: string;
|
|
14
|
+
path: [number, number, string];
|
|
15
|
+
};
|
|
16
|
+
export type UploadType = {
|
|
17
|
+
size?: number;
|
|
18
|
+
name?: string;
|
|
19
|
+
url: string;
|
|
20
|
+
type?: string;
|
|
21
|
+
} | string;
|
|
22
|
+
type FieldComponent<T extends NativeTypes> = (props: SchemaFieldProps<SchemaFieldTypes[T]>) => ReactNode | null;
|
|
23
|
+
export type BaseField<Type extends NativeTypes, TsType> = {
|
|
24
|
+
type: Type;
|
|
25
|
+
valueType?: TsType;
|
|
26
|
+
name: string;
|
|
27
|
+
title?: string;
|
|
28
|
+
description?: string;
|
|
29
|
+
storage?: 'project' | 'workspace' | 'account';
|
|
30
|
+
initialValue?: TsType | EvalCallback | ((context: Omit<SchemaContextModel, 'actions'>) => TsType | Promise<TsType>);
|
|
31
|
+
onChange?: (value: TsType, context: SchemaContextModel) => void | TsType | Promise<void | TsType> | EvalCallback;
|
|
32
|
+
validate?: (value: TsType, context: SchemaContextModel) => boolean | Promise<boolean>;
|
|
33
|
+
hidden?: boolean | ((context: SchemaContextModel) => boolean | Promise<boolean>);
|
|
34
|
+
component?: FieldComponent<Type>;
|
|
35
|
+
preview?: PreviewType | ((value: {
|
|
36
|
+
[key: string]: any;
|
|
37
|
+
}) => PreviewType);
|
|
38
|
+
};
|
|
39
|
+
type PreviewType = {
|
|
40
|
+
title?: string;
|
|
41
|
+
image?: string | ReactNode;
|
|
42
|
+
};
|
|
43
|
+
export type SelectItem<T = any> = {
|
|
44
|
+
label: string;
|
|
45
|
+
value: T;
|
|
46
|
+
};
|
|
47
|
+
export type StringField = BaseField<'string', string> & {
|
|
48
|
+
options?: {
|
|
49
|
+
type: 'text' | 'date' | 'email' | 'url' | 'password';
|
|
50
|
+
multiline?: boolean | number;
|
|
51
|
+
minLength?: number;
|
|
52
|
+
maxLength?: number;
|
|
53
|
+
placeholder?: string;
|
|
54
|
+
};
|
|
55
|
+
};
|
|
56
|
+
export type NumberField = BaseField<'number', number> & {
|
|
57
|
+
options?: {
|
|
58
|
+
min?: number;
|
|
59
|
+
max?: number;
|
|
60
|
+
/**
|
|
61
|
+
* The number visible is scaled by factor,
|
|
62
|
+
* @example if you want percent 0-1 set scale = 100
|
|
63
|
+
* */
|
|
64
|
+
scale?: number;
|
|
65
|
+
format?: '%' | 'px' | 'deg';
|
|
66
|
+
display?: 'input' | 'slider';
|
|
67
|
+
placeholder?: string;
|
|
68
|
+
};
|
|
69
|
+
};
|
|
70
|
+
export type BooleanField = BaseField<'boolean', boolean>;
|
|
71
|
+
export type ImageField = BaseField<'image', ImageType>;
|
|
72
|
+
export type IconField = BaseField<'icon', ShapeType>;
|
|
73
|
+
export type SelectFieldItem = {
|
|
74
|
+
label: string;
|
|
75
|
+
value: any;
|
|
76
|
+
};
|
|
77
|
+
export type SelectField = BaseField<'select', any | any[]> & {
|
|
78
|
+
options: {
|
|
79
|
+
items: SelectFieldItem[] | ((context: SchemaContextModel) => SelectFieldItem[] | Promise<SelectFieldItem[]>);
|
|
80
|
+
multiselect?: boolean;
|
|
81
|
+
display?: 'checkbox' | 'radio' | 'dropdown' | 'autocomplete';
|
|
82
|
+
};
|
|
83
|
+
};
|
|
84
|
+
export type ObjectField = BaseField<'object', {
|
|
85
|
+
[key: string]: any;
|
|
86
|
+
}> & {
|
|
87
|
+
fields: VevProps[];
|
|
88
|
+
};
|
|
89
|
+
export type ArrayField = BaseField<'array', any[]> & {
|
|
90
|
+
of: VevProps[] | 'string' | 'number';
|
|
91
|
+
};
|
|
92
|
+
export type LinkField = BaseField<'link', {
|
|
93
|
+
/**
|
|
94
|
+
* Preset for what linkType the field should be.
|
|
95
|
+
* 0: Page, 1: Element, 2: External link, 3: Email, 4: Phone.
|
|
96
|
+
*/
|
|
97
|
+
mode: 0 | 2 | 3 | 4;
|
|
98
|
+
href?: string;
|
|
99
|
+
page?: string;
|
|
100
|
+
target?: boolean;
|
|
101
|
+
phone?: string;
|
|
102
|
+
email?: string;
|
|
103
|
+
}>;
|
|
104
|
+
export type LayoutField = Omit<BaseField<'layout', {
|
|
105
|
+
[key: string]: any;
|
|
106
|
+
}>, 'name'> & {
|
|
107
|
+
fields: VevProps[];
|
|
108
|
+
name?: string;
|
|
109
|
+
options?: {
|
|
110
|
+
display: 'row' | 'column';
|
|
111
|
+
};
|
|
112
|
+
};
|
|
113
|
+
export type EventField = BaseField<'event', {
|
|
114
|
+
key: string;
|
|
115
|
+
args?: any;
|
|
116
|
+
}[]>;
|
|
117
|
+
export type UploadField = BaseField<'upload', UploadType> & {
|
|
118
|
+
accept?: string;
|
|
119
|
+
maxSize?: number;
|
|
120
|
+
};
|
|
121
|
+
export type WidgetSelectField = BaseField<'widgetSelect', string>;
|
|
122
|
+
export type MenuField = BaseField<'menu', string>;
|
|
123
|
+
export type SchemaFieldTypes = {
|
|
124
|
+
string: StringField;
|
|
125
|
+
array: ArrayField;
|
|
126
|
+
object: ObjectField;
|
|
127
|
+
number: NumberField;
|
|
128
|
+
image: ImageField;
|
|
129
|
+
icon: IconField;
|
|
130
|
+
boolean: BooleanField;
|
|
131
|
+
select: SelectField;
|
|
132
|
+
link: LinkField;
|
|
133
|
+
layout: LayoutField;
|
|
134
|
+
event: EventField;
|
|
135
|
+
upload: UploadField;
|
|
136
|
+
widgetSelect: WidgetSelectField;
|
|
137
|
+
menu: MenuField;
|
|
138
|
+
};
|
|
139
|
+
export type NativeTypes = keyof SchemaFieldTypes;
|
|
140
|
+
export type VevProps = SchemaFieldTypes[NativeTypes];
|
|
141
|
+
export type Schema = VevProps[];
|
|
142
|
+
export type SchemaFieldProps<T extends VevProps> = {
|
|
143
|
+
label: string;
|
|
144
|
+
value: T['valueType'];
|
|
145
|
+
schema: T;
|
|
146
|
+
help?: string;
|
|
147
|
+
onChange: (value: NonNullable<T['valueType']> | null) => void;
|
|
148
|
+
context: SchemaContextModel;
|
|
149
|
+
};
|
|
150
|
+
export type SchemaFieldComponents = {
|
|
151
|
+
[P in keyof Partial<SchemaFieldTypes>]: FieldComponent<P>;
|
|
152
|
+
};
|
|
153
|
+
export declare function isPropsObject(vevProp: VevProps): vevProp is ObjectField;
|
|
154
|
+
export {};
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { IEmojiIcon, IWidgetIcon, IWidgetMetaData, IWidgetRule, IWidgetType, WidgetDimensions, VevProps, ManifestEmptyState } from '.';
|
|
2
|
+
import { VevEvent } from './event';
|
|
3
|
+
export interface FSWidgetCore {
|
|
4
|
+
updated: number;
|
|
5
|
+
created: number;
|
|
6
|
+
deleted?: number;
|
|
7
|
+
key: string;
|
|
8
|
+
name: string;
|
|
9
|
+
}
|
|
10
|
+
export interface FSWidgetPkgManifest extends FSWidgetPkgFile {
|
|
11
|
+
admin?: boolean;
|
|
12
|
+
categories?: string[];
|
|
13
|
+
/** File key of widgets form */
|
|
14
|
+
form?: string;
|
|
15
|
+
pkg?: string;
|
|
16
|
+
/**
|
|
17
|
+
* Shared with account key
|
|
18
|
+
*/
|
|
19
|
+
account?: string;
|
|
20
|
+
/**
|
|
21
|
+
* Shared with team key
|
|
22
|
+
*/
|
|
23
|
+
team?: string;
|
|
24
|
+
/**
|
|
25
|
+
* Shared with workspace key
|
|
26
|
+
*/
|
|
27
|
+
workspace?: string;
|
|
28
|
+
widgetId: string;
|
|
29
|
+
widgetName?: string;
|
|
30
|
+
project?: string;
|
|
31
|
+
/** File key of widgets react component */
|
|
32
|
+
ts?: string;
|
|
33
|
+
type: IWidgetType[keyof IWidgetType];
|
|
34
|
+
public?: boolean | number;
|
|
35
|
+
inspector?: string;
|
|
36
|
+
transform?: Record<string, any>;
|
|
37
|
+
/** File key of widgets styles */
|
|
38
|
+
sass?: string;
|
|
39
|
+
/**
|
|
40
|
+
* Tells if this widget is allowed to be edited in content editor
|
|
41
|
+
*/
|
|
42
|
+
inContent?: boolean;
|
|
43
|
+
static?: boolean;
|
|
44
|
+
settings?: any;
|
|
45
|
+
icons?: IWidgetIcon[];
|
|
46
|
+
icon?: IEmojiIcon;
|
|
47
|
+
/** Sizing for widgets. [width, height] */
|
|
48
|
+
size: WidgetDimensions;
|
|
49
|
+
metaData?: IWidgetMetaData[];
|
|
50
|
+
ruleList?: IWidgetRule[];
|
|
51
|
+
description?: string;
|
|
52
|
+
widgetFuncName?: string;
|
|
53
|
+
panelType?: 'inline';
|
|
54
|
+
shareWithAccount?: boolean;
|
|
55
|
+
formSchema?: VevProps[];
|
|
56
|
+
events?: VevEvent[];
|
|
57
|
+
interactions?: VevEvent[];
|
|
58
|
+
contentChildren?: ContentChildren;
|
|
59
|
+
emptyState?: ManifestEmptyState;
|
|
60
|
+
}
|
|
61
|
+
export type ContentChildren = {
|
|
62
|
+
name: string;
|
|
63
|
+
icon?: IEmojiIcon;
|
|
64
|
+
};
|
|
65
|
+
export interface FSWidgetPkgFile extends FSWidgetCore {
|
|
66
|
+
content: string;
|
|
67
|
+
dir?: boolean;
|
|
68
|
+
parent?: string;
|
|
69
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { IEmojiIcon, IDesktopProps } from '.';
|
|
2
|
+
export type IWidgetType = {
|
|
3
|
+
standard: 0;
|
|
4
|
+
section: 1;
|
|
5
|
+
action: 2;
|
|
6
|
+
both: 3;
|
|
7
|
+
};
|
|
8
|
+
export declare enum WidgetSize {
|
|
9
|
+
auto = 0,
|
|
10
|
+
value = 1,
|
|
11
|
+
preferAuto = 2,
|
|
12
|
+
preferValue = 3
|
|
13
|
+
}
|
|
14
|
+
export type WidgetDimensions = [width: WidgetSize, height: WidgetSize];
|
|
15
|
+
export type IWidgetRule = {
|
|
16
|
+
key: string;
|
|
17
|
+
name?: string;
|
|
18
|
+
icon?: IEmojiIcon;
|
|
19
|
+
props: IDesktopProps;
|
|
20
|
+
inherits?: IWidgetRule;
|
|
21
|
+
isMainBg?: boolean;
|
|
22
|
+
};
|
|
23
|
+
export type IWidgetMetaData = {
|
|
24
|
+
selector: string;
|
|
25
|
+
name?: string;
|
|
26
|
+
icon?: IEmojiIcon;
|
|
27
|
+
inherits?: IWidgetMetaData;
|
|
28
|
+
isMainBg?: boolean;
|
|
29
|
+
};
|
|
30
|
+
export type WidgetModel = {
|
|
31
|
+
image?: IEmojiIcon | string;
|
|
32
|
+
key: string;
|
|
33
|
+
name: string;
|
|
34
|
+
page: string;
|
|
35
|
+
pageName?: string;
|
|
36
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function generateGuid(): string;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * from './generate-guid';
|
|
2
|
+
export * from './string';
|
|
3
|
+
export { default as isString } from './is-string';
|
|
4
|
+
export { default as isArray } from './is-array';
|
|
5
|
+
export { default as isLength } from './is-length';
|
|
6
|
+
export { default as slice } from './slice';
|
|
7
|
+
export { default as startCase } from './start-case';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Casts `array` to a slice if it's needed.
|
|
3
|
+
*
|
|
4
|
+
* @private
|
|
5
|
+
* @param {Array} array The array to inspect.
|
|
6
|
+
* @param {number} start The start position.
|
|
7
|
+
* @param {number} [end=array.length] The end position.
|
|
8
|
+
* @returns {Array} Returns the cast slice.
|
|
9
|
+
*/
|
|
10
|
+
declare function castSlice(array: any[], start: number, end?: number): any[];
|
|
11
|
+
export default castSlice;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Creates a function like `lowerFirst`.
|
|
3
|
+
*
|
|
4
|
+
* @private
|
|
5
|
+
* @param {string} methodName The name of the `String` case method to use.
|
|
6
|
+
* @returns {Function} Returns the new case function.
|
|
7
|
+
*/
|
|
8
|
+
declare function createCaseFirst(methodName: any): (string: string) => string;
|
|
9
|
+
export default createCaseFirst;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Checks if `string` contains Unicode symbols.
|
|
3
|
+
*
|
|
4
|
+
* @private
|
|
5
|
+
* @param {string} string The string to inspect.
|
|
6
|
+
* @returns {boolean} Returns `true` if a symbol is found, else `false`.
|
|
7
|
+
*/
|
|
8
|
+
declare function hasUnicode(string: string): boolean;
|
|
9
|
+
export default hasUnicode;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Converts a Unicode `string` to an array.
|
|
3
|
+
*
|
|
4
|
+
* @private
|
|
5
|
+
* @param {string} string The string to convert.
|
|
6
|
+
* @returns {Array} Returns the converted array.
|
|
7
|
+
*/
|
|
8
|
+
declare function unicodeToArray(string: string): [] | RegExpMatchArray;
|
|
9
|
+
export default unicodeToArray;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Splits a Unicode `string` into an array of its words.
|
|
3
|
+
*
|
|
4
|
+
* @private
|
|
5
|
+
* @param {string} The string to inspect.
|
|
6
|
+
* @returns {Array} Returns the words of `string`.
|
|
7
|
+
*/
|
|
8
|
+
declare function unicodeWords(string: string): RegExpMatchArray | null;
|
|
9
|
+
export default unicodeWords;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Converts the first character of `string` to upper case.
|
|
3
|
+
*
|
|
4
|
+
* @since 4.0.0
|
|
5
|
+
* @category String
|
|
6
|
+
* @param {string} [string=''] The string to convert.
|
|
7
|
+
* @returns {string} Returns the converted string.
|
|
8
|
+
* @see camelCase, kebabCase, lowerCase, snakeCase, startCase, upperCase
|
|
9
|
+
* @example
|
|
10
|
+
*
|
|
11
|
+
* upperFirst('fred')
|
|
12
|
+
* // => 'Fred'
|
|
13
|
+
*
|
|
14
|
+
* upperFirst('FRED')
|
|
15
|
+
* // => 'FRED'
|
|
16
|
+
*/
|
|
17
|
+
declare const upperFirst: (string: string) => string;
|
|
18
|
+
export default upperFirst;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Checks if `value` is array-like. A value is considered array-like if it's
|
|
3
|
+
* not a function and has a `value.length` that's an integer greater than or
|
|
4
|
+
* equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.
|
|
5
|
+
*
|
|
6
|
+
* @since 4.0.0
|
|
7
|
+
* @category Lang
|
|
8
|
+
* @param {*} value The value to check.
|
|
9
|
+
* @returns {boolean} Returns `true` if `value` is array-like, else `false`.
|
|
10
|
+
* @example
|
|
11
|
+
*
|
|
12
|
+
* isArrayLike([1, 2, 3])
|
|
13
|
+
* // => true
|
|
14
|
+
*
|
|
15
|
+
* isArrayLike(document.body.children)
|
|
16
|
+
* // => true
|
|
17
|
+
*
|
|
18
|
+
* isArrayLike('abc')
|
|
19
|
+
* // => true
|
|
20
|
+
*
|
|
21
|
+
* isArrayLike(Function)
|
|
22
|
+
* // => false
|
|
23
|
+
*/
|
|
24
|
+
declare function isArrayLike(value: any): value is ArrayLike<any>;
|
|
25
|
+
export default isArrayLike;
|