@vev/silke 1.0.29 → 1.1.0
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 +23 -0
- package/dist/index.js +38 -74
- package/dist/index.js.LEGAL.txt +15 -34
- package/dist/styles.css +679 -499
- package/dist/{silke/src → types}/components/index.d.ts +3 -1
- package/dist/types/components/silke-action-box/index.d.ts +1 -0
- package/dist/types/components/silke-action-box/silke-action-box.d.ts +18 -0
- package/dist/types/components/silke-alert-banner/index.d.ts +1 -0
- package/dist/{silke/src/components/silke-notification/silke-notification.d.ts → types/components/silke-alert-banner/silke-alert-banner.d.ts} +4 -5
- package/dist/{silke/src → types}/components/silke-autocomplete-field/autocomplete-item.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-autocomplete-field/autocomplete-tags.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-autocomplete-field/silke-autocomplete-field.d.ts +1 -1
- package/dist/types/components/silke-autocomplete-field/silke-autocomplete-field.spec.d.ts +1 -0
- package/dist/{silke/src → types}/components/silke-autocomplete-field/silke-autocomplete-popup.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-box/silke-box.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-breadcrumbs/silke-breadcrumb.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-breadcrumbs/silke-breadcrumbs.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-button/context.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-button/silke-big-button.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-button/silke-button-set.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-button/silke-button.d.ts +2 -2
- package/dist/{silke/src → types}/components/silke-button/silke-confirmation-button.d.ts +3 -2
- package/dist/{silke/src → types}/components/silke-button/silke-dropdown-button.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-button/silke-file-select-button.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-card/silke-card-grid.d.ts +2 -2
- package/dist/{silke/src → types}/components/silke-checkbox/silke-checkbox.d.ts +1 -1
- package/dist/types/components/silke-code-editor/index.d.ts +2 -0
- package/dist/{silke/src → types}/components/silke-code-editor/silke-code-editor.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-code-snippet/silke-code-snippet.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-color-palettes/silke-color-palette.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-color-palettes/silke-color-palettes.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-color-picker/color.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-color-picker/silke-color-info.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-color-picker/silke-color-picker-button.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-color-picker/silke-color-picker.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-color-picker/silke-color-space.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-color-picker/silke-hue-slider.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-color-picker/silke-opacity-slider.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-color-swatches/silke-swatches.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-conditions-input/silke-conditions-input-options.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-conditions-input/silke-conditions-input.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-conditions-input/silke-conditions-tag.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-conditions-input/utils.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-content-column/silke-content-column.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-context-menu/silke-context-menu-item.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-context-menu/silke-context-menu.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-css-number-field/index.d.ts +1 -0
- package/dist/{silke/src → types}/components/silke-css-number-field/silke-css-context.d.ts +6 -4
- package/dist/{silke/src → types}/components/silke-css-number-field/silke-css-number-field.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-divider/silke-divider.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-drawer/silke-drawer.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-form/form-context.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-form/silke-form.d.ts +2 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/array-field-inline.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/array-field-modal.d.ts +2 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/array-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/event-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/icon-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/image-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/layout-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/link-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/number-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/object-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/select-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/string-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/toggle-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/upload-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/fields/video-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/silke-extended-fields-context.d.ts +2 -2
- package/dist/{silke/src → types}/components/silke-form-schema/silke-form-schema.d.ts +2 -4
- package/dist/{silke/src → types}/components/silke-form-schema/silke-schema-context.d.ts +2 -2
- package/dist/{silke/src → types}/components/silke-form-schema/silke-schema-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-form-schema/silke-schema-fields.d.ts +1 -2
- package/dist/types/components/silke-gradient-picker/silke-gradient-picker.d.ts +7 -0
- package/dist/{silke/src → types}/components/silke-gradient-picker/silke-gradient-position.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-gradient-picker/silke-gradient-slider.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-icon/silke-shape.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-icon/silke-stacked-icon.d.ts +1 -2
- package/dist/types/components/silke-icon-picker/emoji-tab.d.ts +2 -0
- package/dist/types/components/silke-icon-picker/icons-tab.d.ts +2 -0
- package/dist/{silke/src → types}/components/silke-icon-picker/silke-icon-picker.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-icon-picker/upload-tab.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-iframe-portal/silke-iframe-portal.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-image/silke-image-color-backdrop.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-image/silke-image.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-link/silke-link.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-list/silke-list-item.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-list/silke-list.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-list-card/silke-list-card.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-loader/silke-loader-overlay.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-loader/silke-loader.d.ts +2 -2
- package/dist/{silke/src → types}/components/silke-modal/silke-confirmation-modal.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-modal/silke-modal.d.ts +5 -4
- package/dist/{silke/src → types}/components/silke-object-field/silke-object-field.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-overflow-menu/silke-overflow-menu.d.ts +2 -2
- package/dist/{silke/src → types}/components/silke-popover/popover-context.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-popover/silke-popover.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-progress-indicator/silke-progress-indicator.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-progress-indicator/silke-progress-step.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-radio-button/silke-radio-button-group.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-radio-button/silke-radio-button.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-search-field/silke-search-field.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-select-field/silke-select-field.d.ts +1 -2
- package/dist/types/components/silke-select-field/silke-select-field.spec.d.ts +1 -0
- package/dist/{silke/src → types}/components/silke-skeleton/silke-skeleton.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-slider/silke-slider-point.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-slider/silke-slider.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-slider/slider-track.d.ts +1 -1
- package/dist/types/components/silke-sortable-list/index.d.ts +3 -0
- package/dist/{silke/src → types}/components/silke-sortable-list/silke-nested-sortable-item.d.ts +3 -2
- package/dist/{silke/src → types}/components/silke-sortable-list/silke-nested-sortable-list.d.ts +3 -2
- package/dist/{silke/src → types}/components/silke-sortable-list/silke-nested-sortable-utils.d.ts +10 -1
- package/dist/types/components/silke-sortable-list/silke-nested-sortable-utils.spec.d.ts +1 -0
- package/dist/{silke/src → types}/components/silke-sortable-list/silke-sortable-item-wrapper.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-sortable-list/silke-sortable-list.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-table/silke-table.d.ts +3 -1
- package/dist/{silke/src → types}/components/silke-table/table-row.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-table/table-types.d.ts +1 -0
- package/dist/types/components/silke-tabs/silke-tab.d.ts +13 -0
- package/dist/{silke/src → types}/components/silke-tabs/silke-tabs.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-tag/silke-tag.d.ts +8 -8
- package/dist/{silke/src → types}/components/silke-text/silke-text.d.ts +7 -6
- package/dist/{silke/src → types}/components/silke-text/silke-title.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-text-field/silke-text-field-outline.d.ts +3 -5
- package/dist/{silke/src → types}/components/silke-text-field/silke-text-field.d.ts +1 -0
- package/dist/{silke/src → types}/components/silke-text-field/text-field-context.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-theme-editor/silke-theme-editor.d.ts +1 -2
- package/dist/{silke/src → types}/components/silke-tile/silke-tile.d.ts +2 -2
- package/dist/types/components/silke-toast-notification/index.d.ts +1 -0
- package/dist/types/components/silke-toast-notification/silke-toast-notification.d.ts +21 -0
- package/dist/{silke/src → types}/components/silke-toggle/silke-toggle.d.ts +1 -1
- package/dist/types/components/silke-toolbar/silke-toolbar.d.ts +7 -0
- package/dist/{silke/src → types}/components/silke-tooltip/silke-definition-tooltip.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-tooltip/silke-icon-tooltip.d.ts +2 -1
- package/dist/{silke/src → types}/components/silke-tooltip/silke-interactive-tooltip.d.ts +1 -1
- package/dist/types/components/silke-tooltip/silke-shortcuts.d.ts +5 -0
- package/dist/{silke/src → types}/components/silke-tooltip/silke-tooltip.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-upload-field/silke-upload-field.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-variables-wrapper/silke-variables-wrapper-form.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-variables-wrapper/silke-variables-wrapper.d.ts +2 -11
- package/dist/{silke/src → types}/components/silke-virtual/silke-virtual-grid.d.ts +1 -1
- package/dist/{silke/src → types}/components/silke-virtual/silke-virtual-row.d.ts +1 -1
- package/dist/types/docs/app.d.ts +3 -0
- package/dist/{silke/src → types}/docs/components/code-block/code-block.d.ts +1 -2
- package/dist/{silke/src → types}/docs/components/state-table/state-table.d.ts +1 -2
- package/dist/{silke/src → types}/docs/docs-provider.d.ts +1 -1
- package/dist/types/docs/parser.d.ts +0 -0
- package/dist/{silke/src → types}/hooks/drag-and-drop/use-drag.d.ts +3 -2
- package/dist/{silke/src → types}/icons.d.ts +43 -25
- package/dist/types/jest/keys.d.ts +6 -0
- package/dist/{silke/src → types}/silke-theme-provider.d.ts +1 -1
- package/esbuild-sass-modules.mjs +1 -1
- package/jest.config.js +0 -2
- package/package.json +19 -17
- package/public/index.html +1 -1
- package/src/components/index.ts +3 -1
- package/src/components/silke-action-box/index.ts +1 -0
- package/src/components/silke-action-box/silke-action-box.mdx +152 -0
- package/src/components/silke-action-box/silke-action-box.scss +116 -0
- package/src/components/silke-action-box/silke-action-box.tsx +67 -0
- package/src/components/silke-alert-banner/index.ts +1 -0
- package/src/components/{silke-notification/silke-notification.mdx → silke-alert-banner/silke-alert-banner.mdx} +21 -42
- package/src/components/{silke-notification/silke-notification.scss → silke-alert-banner/silke-alert-banner.scss} +18 -53
- package/src/components/silke-alert-banner/silke-alert-banner.tsx +92 -0
- package/src/components/silke-autocomplete-field/silke-autocomplete-field.mdx +2 -2
- package/src/components/silke-autocomplete-field/silke-autocomplete-field.spec.tsx +1 -1
- package/src/components/silke-autocomplete-field/silke-autocomplete-field.tsx +11 -12
- package/src/components/silke-autocomplete-field/silke-autocomplete-popup.tsx +52 -51
- package/src/components/silke-button/silke-big-button.scss +0 -8
- package/src/components/silke-button/silke-big-button.tsx +0 -3
- package/src/components/silke-button/silke-button.mdx +2 -9
- package/src/components/silke-button/silke-button.scss +18 -25
- package/src/components/silke-button/silke-button.tsx +5 -5
- package/src/components/silke-button/silke-confirmation-button.tsx +4 -1
- package/src/components/silke-button/silke-file-select-button.tsx +2 -2
- package/src/components/silke-card/silke-card.scss +6 -0
- package/src/components/silke-card/silke-card.tsx +1 -0
- package/src/components/silke-checkbox/silke-checkbox.scss +2 -2
- package/src/components/silke-code-snippet/silke-code-snippet.tsx +5 -7
- package/src/components/silke-color-picker/color.ts +1 -1
- package/src/components/silke-color-picker/silke-color-info.tsx +12 -10
- package/src/components/silke-color-picker/silke-color-picker-button.tsx +1 -1
- package/src/components/silke-color-picker/silke-color-picker.tsx +2 -2
- package/src/components/silke-color-swatches/silke-color-swatch-button.tsx +1 -1
- package/src/components/silke-color-swatches/silke-swatches.tsx +19 -15
- package/src/components/silke-conditions-input/silke-conditions-input.tsx +4 -1
- package/src/components/silke-conditions-input/utils.ts +1 -6
- package/src/components/silke-context-menu/silke-context-menu.tsx +1 -1
- package/src/components/silke-css-number-field/index.ts +1 -0
- package/src/components/silke-css-number-field/silke-css-context.tsx +8 -3
- package/src/components/silke-css-number-field/silke-css-number-field.mdx +3 -3
- package/src/components/silke-css-number-field/silke-css-number-field.tsx +2 -2
- package/src/components/silke-form-schema/fields/array-field-inline.tsx +2 -2
- package/src/components/silke-form-schema/fields/array-field-modal.tsx +2 -2
- package/src/components/silke-form-schema/fields/event-field.tsx +3 -3
- package/src/components/silke-form-schema/fields/icon-field.tsx +0 -2
- package/src/components/silke-form-schema/fields/image-field.tsx +11 -7
- package/src/components/silke-form-schema/fields/link-field.tsx +1 -1
- package/src/components/silke-form-schema/fields/number-field.tsx +4 -4
- package/src/components/silke-form-schema/fields/select-field.tsx +6 -4
- package/src/components/silke-form-schema/fields/string-field.tsx +2 -2
- package/src/components/silke-form-schema/fields/styles.scss +35 -36
- package/src/components/silke-form-schema/fields/upload-field.tsx +1 -1
- package/src/components/silke-form-schema/fields/video-field.tsx +5 -4
- package/src/components/silke-form-schema/silke-form-schema.tsx +2 -3
- package/src/components/silke-form-schema/silke-schema-field.tsx +11 -5
- package/src/components/silke-gradient-picker/silke-gradient-picker.tsx +37 -7
- package/src/components/silke-gradient-picker/silke-gradient-position.tsx +1 -1
- package/src/components/silke-icon/silke-icon.scss +1 -1
- package/src/components/silke-icon-picker/emoji-tab.tsx +2 -2
- package/src/components/silke-iframe-portal/silke-iframe-portal.mdx +1 -1
- package/src/components/silke-modal/silke-confirmation-modal.tsx +3 -1
- package/src/components/silke-modal/silke-modal.mdx +41 -1
- package/src/components/silke-modal/silke-modal.scss +30 -20
- package/src/components/silke-modal/silke-modal.tsx +13 -9
- package/src/components/silke-navigation-link/silke-navigation-link.scss +1 -4
- package/src/components/silke-overflow-menu/silke-overflow-menu.mdx +33 -0
- package/src/components/silke-overflow-menu/silke-overflow-menu.tsx +1 -1
- package/src/components/silke-search-field/silke-search-field.tsx +2 -2
- package/src/components/silke-select-field/silke-select-field.mdx +4 -4
- package/src/components/silke-select-field/silke-select-field.spec.tsx +1 -1
- package/src/components/silke-sortable-list/index.ts +1 -0
- package/src/components/silke-sortable-list/silke-nested-sortable-item.tsx +56 -35
- package/src/components/silke-sortable-list/silke-nested-sortable-list.scss +2 -6
- package/src/components/silke-sortable-list/silke-nested-sortable-list.tsx +4 -0
- package/src/components/silke-sortable-list/silke-nested-sortable-utils.ts +17 -4
- package/src/components/silke-sortable-list/silke-sortable-item-wrapper.tsx +1 -1
- package/src/components/silke-sortable-list/silke-sortable-list.mdx +18 -26
- package/src/components/silke-table/silke-table.mdx +23 -0
- package/src/components/silke-table/silke-table.tsx +14 -5
- package/src/components/silke-table/table-types.ts +1 -0
- package/src/components/silke-tabs/silke-tab.tsx +20 -2
- package/src/components/silke-tabs/silke-tabs.mdx +71 -0
- package/src/components/silke-tabs/silke-tabs.scss +37 -0
- package/src/components/silke-tabs/silke-tabs.tsx +1 -1
- package/src/components/silke-tag/silke-tag.mdx +28 -55
- package/src/components/silke-tag/silke-tag.scss +50 -41
- package/src/components/silke-tag/silke-tag.tsx +4 -13
- package/src/components/silke-text-field/silke-text-field-outline.tsx +10 -27
- package/src/components/silke-text-field/silke-text-field.mdx +2 -2
- package/src/components/silke-text-field/silke-text-field.scss +7 -17
- package/src/components/silke-text-field/silke-text-field.tsx +2 -0
- package/src/components/silke-theme-editor/silke-theme-editor.tsx +0 -1
- package/src/components/silke-tile/silke-tile.tsx +24 -29
- package/src/components/silke-toast-notification/index.ts +1 -0
- package/src/components/silke-toast-notification/silke-toast-notification.mdx +201 -0
- package/src/components/silke-toast-notification/silke-toast-notification.scss +110 -0
- package/src/components/{silke-notification/silke-notification.tsx → silke-toast-notification/silke-toast-notification.tsx} +27 -16
- package/src/components/silke-toolbar/silke-toolbar.tsx +5 -4
- package/src/components/silke-tooltip/silke-icon-tooltip.tsx +5 -3
- package/src/components/silke-tooltip/silke-shortcuts.tsx +8 -3
- package/src/components/silke-upload-field/silke-upload-field.tsx +20 -3
- package/src/components/silke-variables-wrapper/silke-variables-wrapper-form.tsx +2 -2
- package/src/components/silke-variables-wrapper/silke-variables-wrapper.mdx +84 -12
- package/src/components/silke-variables-wrapper/silke-variables-wrapper.scss +2 -2
- package/src/components/silke-variables-wrapper/silke-variables-wrapper.tsx +42 -61
- package/src/docs/app.tsx +16 -13
- package/src/docs/components/code-block/code-block.scss +4 -1
- package/src/docs/components/code-block/code-block.tsx +10 -9
- package/src/hooks/drag-and-drop/use-drag.tsx +6 -1
- package/src/hooks/drag-and-drop/use-drop.tsx +2 -2
- package/src/icons.tsx +53 -27
- package/src/styles/core.scss +4 -0
- package/tsconfig.build.json +26 -4
- package/tsconfig.build.tsbuildinfo +1 -0
- package/tsconfig.json +25 -11
- package/webpack.docs.ts +1 -1
- package/dist/silke/src/components/silke-code-editor/index.d.ts +0 -3
- package/dist/silke/src/components/silke-gradient-picker/silke-gradient-picker.d.ts +0 -5
- package/dist/silke/src/components/silke-icon-picker/emoji-tab.d.ts +0 -3
- package/dist/silke/src/components/silke-icon-picker/icons-tab.d.ts +0 -3
- package/dist/silke/src/components/silke-notification/index.d.ts +0 -1
- package/dist/silke/src/components/silke-sortable-list/index.d.ts +0 -2
- package/dist/silke/src/components/silke-tabs/silke-tab.d.ts +0 -9
- package/dist/silke/src/components/silke-toolbar/silke-toolbar.d.ts +0 -7
- package/dist/silke/src/components/silke-tooltip/silke-shortcuts.d.ts +0 -6
- package/dist/silke/src/docs/app.d.ts +0 -4
- package/dist/utils/src/color/hex.d.ts +0 -2
- package/dist/utils/src/color/index.d.ts +0 -1
- package/dist/utils/src/constants.d.ts +0 -2
- package/dist/utils/src/css/computed-to-css.d.ts +0 -8
- package/dist/utils/src/css/computed.d.ts +0 -5
- package/dist/utils/src/css/index.d.ts +0 -4
- package/dist/utils/src/css/number-format.d.ts +0 -1
- package/dist/utils/src/css/utils.d.ts +0 -14
- package/dist/utils/src/index.d.ts +0 -8
- package/dist/utils/src/keyboard/hooks.d.ts +0 -7
- package/dist/utils/src/keyboard/index.d.ts +0 -4
- package/dist/utils/src/keyboard/keyboard.d.ts +0 -70
- package/dist/utils/src/keyboard/keys.d.ts +0 -4
- package/dist/utils/src/math/index.d.ts +0 -9
- package/dist/utils/src/mouse/index.d.ts +0 -3
- package/dist/utils/src/mouse/mouse-manager.d.ts +0 -51
- package/dist/utils/src/types/content.d.ts +0 -11
- package/dist/utils/src/types/context.d.ts +0 -77
- package/dist/utils/src/types/css.d.ts +0 -131
- package/dist/utils/src/types/editable-css.d.ts +0 -7
- package/dist/utils/src/types/emoji.d.ts +0 -28
- package/dist/utils/src/types/event.d.ts +0 -6
- package/dist/utils/src/types/icon.d.ts +0 -10
- package/dist/utils/src/types/index.d.ts +0 -18
- package/dist/utils/src/types/link.d.ts +0 -47
- package/dist/utils/src/types/manifest.d.ts +0 -56
- package/dist/utils/src/types/oauth.d.ts +0 -13
- package/dist/utils/src/types/project.d.ts +0 -23
- package/dist/utils/src/types/qwiker.d.ts +0 -46
- package/dist/utils/src/types/shape.d.ts +0 -20
- package/dist/utils/src/types/transition.d.ts +0 -15
- package/dist/utils/src/types/vev-plugin.d.ts +0 -90
- package/dist/utils/src/types/vev-props.d.ts +0 -181
- package/dist/utils/src/types/widget-manifest.d.ts +0 -70
- package/dist/utils/src/types/widget.d.ts +0 -36
- package/dist/utils/src/utils/generate-guid.d.ts +0 -1
- package/dist/utils/src/utils/index.d.ts +0 -9
- package/dist/utils/src/utils/internals/asciiToArray.d.ts +0 -9
- package/dist/utils/src/utils/internals/castSlice.d.ts +0 -11
- package/dist/utils/src/utils/internals/createCaseFirst.d.ts +0 -9
- package/dist/utils/src/utils/internals/getTag.d.ts +0 -9
- package/dist/utils/src/utils/internals/hasUnicode.d.ts +0 -9
- package/dist/utils/src/utils/internals/stringToArray.d.ts +0 -9
- package/dist/utils/src/utils/internals/unicodeToArray.d.ts +0 -9
- package/dist/utils/src/utils/internals/unicodeWords.d.ts +0 -9
- package/dist/utils/src/utils/internals/upperFirst.d.ts +0 -18
- package/dist/utils/src/utils/is-array.d.ts +0 -25
- package/dist/utils/src/utils/is-length.d.ts +0 -26
- package/dist/utils/src/utils/is-string.d.ts +0 -17
- package/dist/utils/src/utils/main-components.d.ts +0 -7
- package/dist/utils/src/utils/slice.d.ts +0 -22
- package/dist/utils/src/utils/start-case.d.ts +0 -22
- package/dist/utils/src/utils/string.d.ts +0 -5
- package/dist/utils/src/utils/variable.d.ts +0 -3
- package/dist/utils/src/utils/words.d.ts +0 -18
- package/src/components/silke-notification/index.ts +0 -1
- package/tsconfig.types.json +0 -19
- /package/dist/{silke/src → types}/components/silke-autocomplete-field/autocomplete-types.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-autocomplete-field/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-box/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-breadcrumbs/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-button/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-card/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-card/silke-card.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-checkbox/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-code-snippet/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-color-palettes/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-color-picker/hue.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-color-picker/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-color-swatches/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-color-swatches/silke-color-swatch-button.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-color-swatches/utils.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-conditions-input/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-conditions-input/types.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-content-column/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-context-menu/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-context-menu/silke-contect-menu-hooks.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-css-number-field/utils.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-divider/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-drawer/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-form/form-types.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-form/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-form-schema/fields/utils/generate-image.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-form-schema/fields/utils/generate-title.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-form-schema/fields/utils/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-form-schema/fields/utils/schema-util.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-form-schema/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-form-schema/safe-eval/iframe-handler.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-form-schema/safe-eval/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-form-schema/safe-eval/safe-eval.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-form-schema/schema-utils.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-gradient-picker/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-gradient-picker/silke-gradient-utils.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-icon/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-icon/silke-icon.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-icon-picker/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-icon-picker/utils.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-iframe-portal/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-iframe-portal/silke-iframe-context.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-iframe-portal/silke-iframe-css-link.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-iframe-portal/silke-iframe-script.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-image/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-link/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-list/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-list-card/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-loader/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-modal/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-navigation-link/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-navigation-link/silke-navigation-link.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-object-field/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-overflow-menu/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-popover/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-progress-indicator/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-radio-button/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-search-field/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-select-field/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-skeleton/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-slider/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-slider/silke-slider-utils.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-table/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-tabs/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-tag/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-text/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-text/silke-text-types.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-text-field/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-text-field/silke-text-field-item.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-theme-editor/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-tile/index.d.ts +0 -0
- /package/dist/{silke/src/components/silke-notification → types/components/silke-toast-notification}/confetti.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-toggle/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-toolbar/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-tooltip/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-tooltip/utils.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-upload-field/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-variables-wrapper/index.d.ts +0 -0
- /package/dist/{silke/src → types}/components/silke-virtual/index.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/components/code-block/index.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/components/state-table/index.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/data/app/actions.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/data/app/constants.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/data/app/index.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/data/app/store.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/data/flux/action-decorator.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/data/flux/action-utils.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/data/flux/controller.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/data/flux/dispatcher.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/data/flux/index.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/data/flux/store.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/data/flux/use-store.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/index.d.ts +0 -0
- /package/dist/{silke/src → types}/docs/ipsum-generator.d.ts +0 -0
- /package/dist/{silke/src → types}/helpers/copy-to-clipboard.d.ts +0 -0
- /package/dist/{silke/src → types}/helpers/key-code.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/drag-and-drop/index.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/drag-and-drop/use-drop.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/form/index.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/form/use-form-field.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/image-colors/use-image-colors.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/index.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/use-callback-ref.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/use-dragging.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/use-drop-zone.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/use-html-element.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/use-interval.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/use-mouse.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/use-parent-scroll.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/use-scroll.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/use-size.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/use-uniq-id.d.ts +0 -0
- /package/dist/{silke/src → types}/hooks/use-window-resize.d.ts +0 -0
- /package/dist/{silke/src → types}/index.d.ts +0 -0
- /package/dist/{silke/src → types}/main.d.ts +0 -0
- /package/src/components/{silke-notification → silke-toast-notification}/confetti.tsx +0 -0
- /package/{jest → src/jest}/keys.ts +0 -0
package/package.json
CHANGED
|
@@ -1,36 +1,36 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vev/silke",
|
|
3
|
-
"version": "1.0
|
|
3
|
+
"version": "1.1.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
|
-
"types": "dist/
|
|
6
|
+
"types": "dist/types/index.d.ts",
|
|
7
7
|
"scripts": {
|
|
8
8
|
"start": "yarn start:docs",
|
|
9
|
-
"start:docs": "cross-env TS_NODE_PROJECT=\"../../tsconfig.
|
|
10
|
-
"build": "yarn clean &&
|
|
9
|
+
"start:docs": "cross-env TS_NODE_PROJECT=\"../../tsconfig.json\" webpack serve --env development --config ./webpack.docs.ts",
|
|
10
|
+
"build": "yarn clean && yarn build:types && yarn build:code",
|
|
11
11
|
"build:code": "node ./esbuild.config.mjs",
|
|
12
|
-
"build:docs": "yarn clean && cross-env TS_NODE_PROJECT=\"../../tsconfig.
|
|
13
|
-
"build:types": "tsc --project tsconfig.
|
|
12
|
+
"build:docs": "yarn clean && cross-env TS_NODE_PROJECT=\"../../tsconfig.json\" webpack --env production --config ./webpack.docs.ts",
|
|
13
|
+
"build:types": "tsc --project tsconfig.build.json",
|
|
14
14
|
"clean": "del-cli dist",
|
|
15
15
|
"test": "jest --silent --forceExit --runInBand --passWithNoTests",
|
|
16
16
|
"test:ci": "jest --runInBand --forceExit --reporters='github-actions' --passWithNoTests",
|
|
17
17
|
"tsc": "tsc --project ./tsconfig.json --emitDeclarationOnly --outDir ./dist",
|
|
18
|
-
"watch": "run-
|
|
18
|
+
"watch": "run -T concurrently \"yarn watch:tsc\" \"yarn watch:code\"",
|
|
19
19
|
"watch:code": "node esbuild.config.mjs --watch",
|
|
20
|
-
"watch:tsc": "tsc --project ./tsconfig.json --emitDeclarationOnly --watch"
|
|
20
|
+
"watch:tsc": "tsc --project ./tsconfig.build.json --emitDeclarationOnly --watch"
|
|
21
21
|
},
|
|
22
22
|
"peerDependencies": {
|
|
23
23
|
"react": ">=16.0.0",
|
|
24
24
|
"react-dom": ">=16.0.0",
|
|
25
|
-
"react-router-dom": "
|
|
25
|
+
"react-router-dom": "^7.6.3"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"@codemirror/lang-css": "^6.0.0",
|
|
29
29
|
"@codemirror/lang-javascript": "^6.1.0",
|
|
30
30
|
"@codemirror/lang-json": "^6.0.0",
|
|
31
|
-
"@mdx-js/loader": "^
|
|
32
|
-
"@mdx-js/mdx": "^
|
|
33
|
-
"@mdx-js/react": "^
|
|
31
|
+
"@mdx-js/loader": "^3.1.0",
|
|
32
|
+
"@mdx-js/mdx": "^3.1.0",
|
|
33
|
+
"@mdx-js/react": "^3.1.0",
|
|
34
34
|
"@pmmmwh/react-refresh-webpack-plugin": "^0.5.10",
|
|
35
35
|
"@uiw/codemirror-theme-dracula": "^4.12.3",
|
|
36
36
|
"@uiw/react-codemirror": "^4.12.3",
|
|
@@ -38,19 +38,21 @@
|
|
|
38
38
|
"@vev/react": "*",
|
|
39
39
|
"@vev/utils": "*",
|
|
40
40
|
"classnames": ">=2.2.0",
|
|
41
|
+
"dompurify": "^3.2.6",
|
|
41
42
|
"flux": "^4.0.4",
|
|
42
43
|
"lodash": "^4.17.21",
|
|
43
44
|
"prismjs": "^1.27.0",
|
|
44
45
|
"project-name-generator": "^2.1.9",
|
|
45
|
-
"react-
|
|
46
|
-
"react-live": "^2.4.1"
|
|
46
|
+
"react-live": "^4.1.8"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
49
|
"@types/project-name-generator": "^2",
|
|
50
|
-
"cross-env": "^
|
|
50
|
+
"cross-env": "^10.0.0",
|
|
51
51
|
"del-cli": "*",
|
|
52
52
|
"jest": "*",
|
|
53
|
-
"
|
|
54
|
-
"
|
|
53
|
+
"typescript": "5.7.3",
|
|
54
|
+
"webpack": "^5.99.9",
|
|
55
|
+
"webpack-cli": "^6.0.1",
|
|
56
|
+
"webpack-dev-server": "^5.2.2"
|
|
55
57
|
}
|
|
56
58
|
}
|
package/public/index.html
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
rel="stylesheet"
|
|
16
16
|
/>
|
|
17
17
|
<!-- <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet" /> -->
|
|
18
|
-
<link rel="stylesheet" href="https://cdn.vev.design/fontawesome/
|
|
18
|
+
<link rel="stylesheet" href="https://cdn.vev.design/fontawesome/7.0.0-v2/css/all.min.css" >
|
|
19
19
|
</head>
|
|
20
20
|
<body>
|
|
21
21
|
<div id="root" style="width: 100%;height:100%;"></div>
|
package/src/components/index.ts
CHANGED
|
@@ -23,7 +23,8 @@ export * from './silke-list-card';
|
|
|
23
23
|
export * from './silke-loader';
|
|
24
24
|
export * from './silke-modal';
|
|
25
25
|
export * from './silke-navigation-link';
|
|
26
|
-
export * from './silke-notification';
|
|
26
|
+
export * from './silke-toast-notification';
|
|
27
|
+
export * from './silke-alert-banner';
|
|
27
28
|
export * from './silke-overflow-menu';
|
|
28
29
|
export * from './silke-popover';
|
|
29
30
|
export * from './silke-progress-indicator';
|
|
@@ -39,6 +40,7 @@ export * from './silke-theme-editor';
|
|
|
39
40
|
export * from './silke-tile';
|
|
40
41
|
export * from './silke-toolbar';
|
|
41
42
|
export * from './silke-tooltip';
|
|
43
|
+
export * from './silke-action-box';
|
|
42
44
|
|
|
43
45
|
// Form fields
|
|
44
46
|
export * from './silke-autocomplete-field';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './silke-action-box';
|
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
# Action Box
|
|
2
|
+
|
|
3
|
+
## With button
|
|
4
|
+
|
|
5
|
+
```js
|
|
6
|
+
const title = 'Warning';
|
|
7
|
+
const subtitle = 'Some subitle text here';
|
|
8
|
+
|
|
9
|
+
const types = ['inline', 'stacked', 'centered'];
|
|
10
|
+
|
|
11
|
+
<SilkeBox gap>
|
|
12
|
+
<SilkeBox column gap>
|
|
13
|
+
{types.map((type, i) => (
|
|
14
|
+
<SilkeActionBox
|
|
15
|
+
key={i}
|
|
16
|
+
kind={type}
|
|
17
|
+
title="The content has been updated"
|
|
18
|
+
icon="widget"
|
|
19
|
+
buttons={[{ label: 'View', kind: 'secondary' }]}
|
|
20
|
+
/>
|
|
21
|
+
))}
|
|
22
|
+
</SilkeBox>
|
|
23
|
+
</SilkeBox>;
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
## With link
|
|
27
|
+
|
|
28
|
+
```js
|
|
29
|
+
const title = 'Warning';
|
|
30
|
+
const subtitle = 'Some subitle text here';
|
|
31
|
+
|
|
32
|
+
const types = ['inline', 'stacked', 'centered'];
|
|
33
|
+
|
|
34
|
+
<SilkeBox gap>
|
|
35
|
+
<SilkeBox column gap>
|
|
36
|
+
{types.map((type, i) => (
|
|
37
|
+
<SilkeActionBox
|
|
38
|
+
key={i}
|
|
39
|
+
kind={type}
|
|
40
|
+
title="The content has been updated"
|
|
41
|
+
icon="widget"
|
|
42
|
+
link={{ label: 'View', href: '#' }}
|
|
43
|
+
/>
|
|
44
|
+
))}
|
|
45
|
+
</SilkeBox>
|
|
46
|
+
</SilkeBox>;
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
## With multiple buttons
|
|
50
|
+
|
|
51
|
+
```js
|
|
52
|
+
const title = 'Warning';
|
|
53
|
+
const subtitle = 'Some subitle text here';
|
|
54
|
+
|
|
55
|
+
const types = ['inline', 'stacked', 'centered'];
|
|
56
|
+
|
|
57
|
+
<SilkeBox gap>
|
|
58
|
+
<SilkeBox column gap>
|
|
59
|
+
{types.map((type, i) => (
|
|
60
|
+
<SilkeActionBox
|
|
61
|
+
key={i}
|
|
62
|
+
kind={type}
|
|
63
|
+
title="The content has been updated"
|
|
64
|
+
icon="widget"
|
|
65
|
+
buttons={[
|
|
66
|
+
{ label: 'Confirm', kind: 'primary' },
|
|
67
|
+
{ label: 'Cancel', kind: 'secondary' },
|
|
68
|
+
]}
|
|
69
|
+
/>
|
|
70
|
+
))}
|
|
71
|
+
</SilkeBox>
|
|
72
|
+
</SilkeBox>;
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
## Without icon
|
|
76
|
+
|
|
77
|
+
```js
|
|
78
|
+
const title = 'Warning';
|
|
79
|
+
const subtitle = 'Some subitle text here';
|
|
80
|
+
|
|
81
|
+
const types = ['inline', 'stacked', 'centered'];
|
|
82
|
+
|
|
83
|
+
<SilkeBox gap>
|
|
84
|
+
<SilkeBox column gap>
|
|
85
|
+
{types.map((type, i) => (
|
|
86
|
+
<SilkeActionBox
|
|
87
|
+
key={i}
|
|
88
|
+
kind={type}
|
|
89
|
+
title="The content has been updated"
|
|
90
|
+
buttons={[{ label: 'View', kind: 'secondary' }]}
|
|
91
|
+
/>
|
|
92
|
+
))}
|
|
93
|
+
</SilkeBox>
|
|
94
|
+
</SilkeBox>;
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
## With custom contents
|
|
98
|
+
|
|
99
|
+
```js
|
|
100
|
+
<SilkeBox column gap>
|
|
101
|
+
<SilkeBox style={{ width: '250px' }}>
|
|
102
|
+
<SilkeActionBox kind="inline" icon="refresh" buttons={[{ label: 'Review', kind: 'secondary' }]}>
|
|
103
|
+
<div
|
|
104
|
+
style={{
|
|
105
|
+
display: '-webkit-box',
|
|
106
|
+
'-webkit-line-clamp': '2',
|
|
107
|
+
'-webkit-box-orient': 'vertical',
|
|
108
|
+
overflow: 'hidden',
|
|
109
|
+
}}
|
|
110
|
+
>
|
|
111
|
+
<SilkeText size="small">
|
|
112
|
+
Update available for{' '}
|
|
113
|
+
<SilkeText weight="strong" size="small">
|
|
114
|
+
6 components
|
|
115
|
+
</SilkeText>
|
|
116
|
+
</SilkeText>
|
|
117
|
+
</div>
|
|
118
|
+
</SilkeActionBox>
|
|
119
|
+
</SilkeBox>
|
|
120
|
+
|
|
121
|
+
<SilkeBox style={{ width: '200px' }}>
|
|
122
|
+
<SilkeActionBox
|
|
123
|
+
kind="centered"
|
|
124
|
+
link={{
|
|
125
|
+
label: 'Learn more',
|
|
126
|
+
href: 'https://help.vev.design/en/articles/6237869-main-components',
|
|
127
|
+
external: true,
|
|
128
|
+
}}
|
|
129
|
+
>
|
|
130
|
+
<SilkeBox column gap="xs">
|
|
131
|
+
<SilkeText weight="strong" size="small">
|
|
132
|
+
Create a Main component
|
|
133
|
+
</SilkeText>
|
|
134
|
+
<SilkeText size="small" color="neutral-70">
|
|
135
|
+
Ensure design consistency across your project by using Main components.
|
|
136
|
+
</SilkeText>
|
|
137
|
+
</SilkeBox>
|
|
138
|
+
</SilkeActionBox>
|
|
139
|
+
</SilkeBox>
|
|
140
|
+
|
|
141
|
+
<SilkeBox>
|
|
142
|
+
<SilkeActionBox
|
|
143
|
+
kind="centered"
|
|
144
|
+
buttons={[{ label: 'Create with AI', kind: 'secondary', icon: 'ai' }]}
|
|
145
|
+
>
|
|
146
|
+
<SilkeText weight="strong" size="small">
|
|
147
|
+
Build a custom layout with AI
|
|
148
|
+
</SilkeText>
|
|
149
|
+
</SilkeActionBox>
|
|
150
|
+
</SilkeBox>
|
|
151
|
+
</SilkeBox>
|
|
152
|
+
```
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
@use "../../variables" as *;
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
.wrapper {
|
|
5
|
+
border: 1px solid var(--color-surface-3);
|
|
6
|
+
background-color: var(--color-surface-1);
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.content {
|
|
10
|
+
display: flex;
|
|
11
|
+
width: 100%;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.title {
|
|
15
|
+
display: flex;
|
|
16
|
+
align-items: center;
|
|
17
|
+
font-size: $font-small;
|
|
18
|
+
line-height: 16px;
|
|
19
|
+
padding: var(--space-s) var(--space-s) var(--space-s) 0;
|
|
20
|
+
min-height: $size-m;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.body {
|
|
24
|
+
display: flex;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.link {
|
|
28
|
+
display: flex;
|
|
29
|
+
align-items: center;
|
|
30
|
+
font-size: $font-small;
|
|
31
|
+
text-decoration: none;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.buttons {
|
|
35
|
+
display: flex;
|
|
36
|
+
gap: var(--space-s);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
// Variants
|
|
40
|
+
|
|
41
|
+
.inline {
|
|
42
|
+
.content {
|
|
43
|
+
align-items: center;
|
|
44
|
+
flex-direction: row;
|
|
45
|
+
}
|
|
46
|
+
.body {
|
|
47
|
+
align-items: center;
|
|
48
|
+
gap: var(--space-s);
|
|
49
|
+
}
|
|
50
|
+
.buttons {
|
|
51
|
+
padding: var(--space-s);
|
|
52
|
+
}
|
|
53
|
+
.link {
|
|
54
|
+
padding-right: var(--space-m);
|
|
55
|
+
min-height: $size-m;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.stacked {
|
|
60
|
+
.body {
|
|
61
|
+
flex-direction: column;
|
|
62
|
+
}
|
|
63
|
+
.title {
|
|
64
|
+
padding-right: var(--space-m);
|
|
65
|
+
}
|
|
66
|
+
.buttons {
|
|
67
|
+
padding-bottom: var(--space-m);
|
|
68
|
+
}
|
|
69
|
+
.link {
|
|
70
|
+
padding-bottom: var(--space-s);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.centered {
|
|
75
|
+
.content {
|
|
76
|
+
flex-direction: column;
|
|
77
|
+
align-items: center;
|
|
78
|
+
}
|
|
79
|
+
.title {
|
|
80
|
+
padding: 0 var(--space-m);
|
|
81
|
+
min-height: initial;
|
|
82
|
+
justify-content: center;
|
|
83
|
+
}
|
|
84
|
+
.body {
|
|
85
|
+
flex-direction: column;
|
|
86
|
+
text-align: center;
|
|
87
|
+
width: 100%;
|
|
88
|
+
}
|
|
89
|
+
.buttons {
|
|
90
|
+
flex: 1;
|
|
91
|
+
padding: var(--space-m) var(--space-m) var(--space-m) var(--space-m);
|
|
92
|
+
}
|
|
93
|
+
.link {
|
|
94
|
+
justify-content: center;
|
|
95
|
+
text-align: center;
|
|
96
|
+
padding: var(--space-xs) var(--space-s) var(--space-s) var(--space-m);
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.inline.noIcon {
|
|
101
|
+
.title {
|
|
102
|
+
padding-left: var(--space-s);
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
.stacked.noIcon {
|
|
107
|
+
.content {
|
|
108
|
+
padding-left: var(--space-m);
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.centered.noIcon {
|
|
113
|
+
.content {
|
|
114
|
+
padding-top: var(--space-m);
|
|
115
|
+
}
|
|
116
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { BoxDivProps, SilkeBox } from '../silke-box';
|
|
3
|
+
import { SilkeButton, SilkeButtonProps } from '../silke-button';
|
|
4
|
+
import { SilkeIcon, SilkeIcons } from '../silke-icon';
|
|
5
|
+
import styles from './silke-action-box.scss';
|
|
6
|
+
import { SilkeLink } from '../silke-link';
|
|
7
|
+
|
|
8
|
+
export type ActionBoxKind = 'inline' | 'stacked' | 'centered';
|
|
9
|
+
|
|
10
|
+
export type SilkeActionBoxProps = {
|
|
11
|
+
kind: ActionBoxKind;
|
|
12
|
+
title?: string;
|
|
13
|
+
children?: React.ReactNode;
|
|
14
|
+
icon?: SilkeIcons;
|
|
15
|
+
link?: {
|
|
16
|
+
label: string;
|
|
17
|
+
href: string;
|
|
18
|
+
external?: boolean;
|
|
19
|
+
};
|
|
20
|
+
buttons?: SilkeButtonProps[];
|
|
21
|
+
} & Omit<BoxDivProps, 'height' | 'width' | 'tag'>;
|
|
22
|
+
|
|
23
|
+
export function SilkeActionBox({
|
|
24
|
+
className,
|
|
25
|
+
title,
|
|
26
|
+
children,
|
|
27
|
+
kind = 'inline',
|
|
28
|
+
icon,
|
|
29
|
+
link,
|
|
30
|
+
buttons,
|
|
31
|
+
...rest
|
|
32
|
+
}: SilkeActionBoxProps) {
|
|
33
|
+
const cl: string[] = [styles.wrapper];
|
|
34
|
+
|
|
35
|
+
if (className) cl.push(className);
|
|
36
|
+
if (kind) cl.push(styles[kind]);
|
|
37
|
+
if (!icon) cl.push(styles.noIcon);
|
|
38
|
+
|
|
39
|
+
return (
|
|
40
|
+
<SilkeBox rounded="small" className={cl.join(' ')} {...rest}>
|
|
41
|
+
<div className={styles.content}>
|
|
42
|
+
{icon && (
|
|
43
|
+
<SilkeBox size="m" align="center">
|
|
44
|
+
<SilkeIcon icon={icon} />
|
|
45
|
+
</SilkeBox>
|
|
46
|
+
)}
|
|
47
|
+
<div className={styles.body}>
|
|
48
|
+
<div className={styles.title}>{title || children}</div>
|
|
49
|
+
|
|
50
|
+
{link && (
|
|
51
|
+
<SilkeLink href={link.href} className={styles.link} external={link.external}>
|
|
52
|
+
{link.label}
|
|
53
|
+
</SilkeLink>
|
|
54
|
+
)}
|
|
55
|
+
|
|
56
|
+
{buttons && (
|
|
57
|
+
<div className={styles.buttons}>
|
|
58
|
+
{buttons.map((button, i) => (
|
|
59
|
+
<SilkeButton {...button} size="s" fill={kind === 'centered'} key={i} />
|
|
60
|
+
))}
|
|
61
|
+
</div>
|
|
62
|
+
)}
|
|
63
|
+
</div>
|
|
64
|
+
</div>
|
|
65
|
+
</SilkeBox>
|
|
66
|
+
);
|
|
67
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './silke-alert-banner';
|
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
#
|
|
2
|
-
|
|
3
|
-
## Line notification
|
|
1
|
+
# Alert Banner
|
|
4
2
|
|
|
5
3
|
## Types
|
|
6
4
|
|
|
@@ -13,19 +11,7 @@ const types = ['information', 'success', 'warning', 'error'];
|
|
|
13
11
|
<SilkeBox gap>
|
|
14
12
|
<SilkeBox column gap>
|
|
15
13
|
{types.map((type, i) => (
|
|
16
|
-
<
|
|
17
|
-
key={i}
|
|
18
|
-
inline
|
|
19
|
-
kind={type}
|
|
20
|
-
subtitle="Subtitle text here"
|
|
21
|
-
onRemove={() => {}}
|
|
22
|
-
dark
|
|
23
|
-
/>
|
|
24
|
-
))}
|
|
25
|
-
</SilkeBox>
|
|
26
|
-
<SilkeBox column gap>
|
|
27
|
-
{types.map((type, i) => (
|
|
28
|
-
<SilkeNotification
|
|
14
|
+
<SilkeAlertBanner
|
|
29
15
|
key={i}
|
|
30
16
|
inline
|
|
31
17
|
kind={type}
|
|
@@ -49,7 +35,7 @@ const addNotification = () => {
|
|
|
49
35
|
|
|
50
36
|
<>
|
|
51
37
|
<SilkeBox column gap>
|
|
52
|
-
<
|
|
38
|
+
<SilkeAlertBanner
|
|
53
39
|
inline
|
|
54
40
|
subtitle="Subtitle text here. Subtitle text here. Subtitle text here. Subtitle text here. Subtitle text here. Subtitle text here. Subtitle text here"
|
|
55
41
|
onRemove={() => {}}
|
|
@@ -67,16 +53,14 @@ const addNotification = () => {
|
|
|
67
53
|
value={type}
|
|
68
54
|
items={[
|
|
69
55
|
{ value: 'information' },
|
|
70
|
-
{ value: 'success' },
|
|
71
56
|
{ value: 'attention' },
|
|
72
57
|
{ value: 'error' },
|
|
73
58
|
{ value: 'warning' },
|
|
74
|
-
{ value: 'confetti' },
|
|
75
59
|
]}
|
|
76
60
|
/>
|
|
77
61
|
</SilkeBox>
|
|
78
62
|
{notifications.map((item) => (
|
|
79
|
-
<
|
|
63
|
+
<SilkeAlertBanner
|
|
80
64
|
key={item.id}
|
|
81
65
|
kind={item.kind || 'information'}
|
|
82
66
|
title="Warning title"
|
|
@@ -97,21 +81,16 @@ const addNotification = () => {
|
|
|
97
81
|
```jsx
|
|
98
82
|
() => (
|
|
99
83
|
<SilkeBox column gap>
|
|
100
|
-
<
|
|
84
|
+
<SilkeAlertBanner
|
|
101
85
|
inline
|
|
102
86
|
kind="success"
|
|
103
87
|
subtitle="Subtitle text here"
|
|
104
88
|
onAction={() => {}}
|
|
105
89
|
actionLabel="Click here"
|
|
106
90
|
/>
|
|
107
|
-
<
|
|
108
|
-
<
|
|
109
|
-
<
|
|
110
|
-
kind="information"
|
|
111
|
-
inline
|
|
112
|
-
subtitle="Subtitle text here"
|
|
113
|
-
onRemove={() => {}}
|
|
114
|
-
/>
|
|
91
|
+
<SilkeAlertBanner kind="error" inline subtitle="Subtitle text here" onRemove={() => {}} />
|
|
92
|
+
<SilkeAlertBanner kind="success" inline subtitle="Subtitle text here" onRemove={() => {}} />
|
|
93
|
+
<SilkeAlertBanner kind="information" inline subtitle="Subtitle text here" onRemove={() => {}} />
|
|
115
94
|
</SilkeBox>
|
|
116
95
|
);
|
|
117
96
|
```
|
|
@@ -121,11 +100,11 @@ const addNotification = () => {
|
|
|
121
100
|
```js
|
|
122
101
|
<>
|
|
123
102
|
<SilkeBox column gap>
|
|
124
|
-
<
|
|
125
|
-
<
|
|
126
|
-
<
|
|
127
|
-
<
|
|
128
|
-
<
|
|
103
|
+
<SilkeAlertBanner kind="success" subtitle="Subtitle text here" />
|
|
104
|
+
<SilkeAlertBanner kind="error" subtitle="Subtitle text here" onRemove={() => {}} />
|
|
105
|
+
<SilkeAlertBanner kind="success" subtitle="Subtitle text here" onRemove={() => {}} />
|
|
106
|
+
<SilkeAlertBanner kind="information" subtitle="Subtitle text here" onRemove={() => {}} />
|
|
107
|
+
<SilkeAlertBanner
|
|
129
108
|
kind="error"
|
|
130
109
|
subtitle="Subtitle text here"
|
|
131
110
|
actionLabel="Fix now"
|
|
@@ -141,25 +120,25 @@ const addNotification = () => {
|
|
|
141
120
|
```js
|
|
142
121
|
<>
|
|
143
122
|
<SilkeBox column gap>
|
|
144
|
-
<
|
|
123
|
+
<SilkeAlertBanner
|
|
145
124
|
kind="success"
|
|
146
125
|
title="With action"
|
|
147
126
|
actionLabel="Take action"
|
|
148
127
|
onAction={() => {}}
|
|
149
128
|
/>
|
|
150
|
-
<
|
|
129
|
+
<SilkeAlertBanner
|
|
151
130
|
kind="error"
|
|
152
131
|
title="With action"
|
|
153
132
|
actionLabel="Take action"
|
|
154
133
|
onAction={() => {}}
|
|
155
134
|
/>
|
|
156
|
-
<
|
|
135
|
+
<SilkeAlertBanner
|
|
157
136
|
kind="success"
|
|
158
137
|
title="With action"
|
|
159
138
|
actionLabel="Take action"
|
|
160
139
|
onAction={() => {}}
|
|
161
140
|
/>
|
|
162
|
-
<
|
|
141
|
+
<SilkeAlertBanner
|
|
163
142
|
kind="information"
|
|
164
143
|
title="With action"
|
|
165
144
|
actionLabel="Take action"
|
|
@@ -174,22 +153,22 @@ const addNotification = () => {
|
|
|
174
153
|
```js
|
|
175
154
|
<>
|
|
176
155
|
<SilkeBox column gap>
|
|
177
|
-
<
|
|
178
|
-
<
|
|
156
|
+
<SilkeAlertBanner fluid kind="success" title="Title text here" subtitle="Subtitle text here" />
|
|
157
|
+
<SilkeAlertBanner
|
|
179
158
|
fluid
|
|
180
159
|
kind="error"
|
|
181
160
|
title="Title text here"
|
|
182
161
|
subtitle="Subtitle text here"
|
|
183
162
|
onRemove={() => {}}
|
|
184
163
|
/>
|
|
185
|
-
<
|
|
164
|
+
<SilkeAlertBanner
|
|
186
165
|
fluid
|
|
187
166
|
kind="success"
|
|
188
167
|
title="Title text here"
|
|
189
168
|
subtitle="Subtitle text here"
|
|
190
169
|
onRemove={() => {}}
|
|
191
170
|
/>
|
|
192
|
-
<
|
|
171
|
+
<SilkeAlertBanner
|
|
193
172
|
fluid
|
|
194
173
|
kind="information"
|
|
195
174
|
title="Title text here"
|