@nuraly/lumenui 0.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/LICENSE +28 -0
- package/README.md +248 -0
- package/dist/nuralyui.bundle.js +29209 -0
- package/dist/nuralyui.bundle.js.gz +0 -0
- package/dist/src/components/alert/alert.component.d.ts +103 -0
- package/dist/src/components/alert/alert.component.js +225 -0
- package/dist/src/components/alert/alert.style.d.ts +14 -0
- package/dist/src/components/alert/alert.style.js +191 -0
- package/dist/src/components/alert/alert.types.d.ts +46 -0
- package/dist/src/components/alert/alert.types.js +7 -0
- package/dist/src/components/alert/bundle.js +231 -0
- package/dist/src/components/alert/bundle.js.gz +0 -0
- package/dist/src/components/alert/index.d.ts +8 -0
- package/dist/src/components/alert/index.js +8 -0
- package/dist/src/components/alert/react.d.ts +5 -0
- package/dist/src/components/alert/react.js +17 -0
- package/dist/src/components/badge/badge.component.d.ts +148 -0
- package/dist/src/components/badge/badge.component.js +270 -0
- package/dist/src/components/badge/badge.style.d.ts +14 -0
- package/dist/src/components/badge/badge.style.js +250 -0
- package/dist/src/components/badge/badge.types.d.ts +84 -0
- package/dist/src/components/badge/badge.types.js +7 -0
- package/dist/src/components/badge/bundle.js +277 -0
- package/dist/src/components/badge/bundle.js.gz +0 -0
- package/dist/src/components/badge/index.d.ts +2 -0
- package/dist/src/components/badge/index.js +2 -0
- package/dist/src/components/badge/react.d.ts +3 -0
- package/dist/src/components/badge/react.js +10 -0
- package/dist/src/components/breadcrumb/breadcrumb.component.d.ts +121 -0
- package/dist/src/components/breadcrumb/breadcrumb.component.js +257 -0
- package/dist/src/components/breadcrumb/breadcrumb.style.d.ts +14 -0
- package/dist/src/components/breadcrumb/breadcrumb.style.js +153 -0
- package/dist/src/components/breadcrumb/breadcrumb.types.d.ts +63 -0
- package/dist/src/components/breadcrumb/breadcrumb.types.js +7 -0
- package/dist/src/components/breadcrumb/bundle.js +213 -0
- package/dist/src/components/breadcrumb/bundle.js.gz +0 -0
- package/dist/src/components/breadcrumb/index.d.ts +2 -0
- package/dist/src/components/breadcrumb/index.js +2 -0
- package/dist/src/components/breadcrumb/react.d.ts +5 -0
- package/dist/src/components/breadcrumb/react.js +12 -0
- package/dist/src/components/button/bundle.js +606 -0
- package/dist/src/components/button/bundle.js.gz +0 -0
- package/dist/src/components/button/button.component.d.ts +96 -0
- package/dist/src/components/button/button.component.js +312 -0
- package/dist/src/components/button/button.style.d.ts +10 -0
- package/dist/src/components/button/button.style.js +535 -0
- package/dist/src/components/button/button.types.d.ts +57 -0
- package/dist/src/components/button/button.types.js +2 -0
- package/dist/src/components/button/index.d.ts +2 -0
- package/dist/src/components/button/index.js +2 -0
- package/dist/src/components/button/react.d.ts +5 -0
- package/dist/src/components/button/react.js +12 -0
- package/dist/src/components/canvas/base-canvas.component.d.ts +177 -0
- package/dist/src/components/canvas/base-canvas.component.js +865 -0
- package/dist/src/components/canvas/bundle.js +16664 -0
- package/dist/src/components/canvas/bundle.js.gz +0 -0
- package/dist/src/components/canvas/canvas.component.d.ts +2 -0
- package/dist/src/components/canvas/canvas.component.js +295 -0
- package/dist/src/components/canvas/canvas.constants.d.ts +66 -0
- package/dist/src/components/canvas/canvas.constants.js +61 -0
- package/dist/src/components/canvas/chatbot-panel.style.d.ts +11 -0
- package/dist/src/components/canvas/chatbot-panel.style.js +189 -0
- package/dist/src/components/canvas/index.d.ts +13 -0
- package/dist/src/components/canvas/index.js +21 -0
- package/dist/src/components/canvas/react.d.ts +354 -0
- package/dist/src/components/canvas/react.js +41 -0
- package/dist/src/components/canvas/whiteboard-canvas.component.d.ts +63 -0
- package/dist/src/components/canvas/whiteboard-canvas.component.js +356 -0
- package/dist/src/components/canvas/whiteboard-canvas.style.d.ts +7 -0
- package/dist/src/components/canvas/whiteboard-canvas.style.js +1011 -0
- package/dist/src/components/canvas/whiteboard-node.component.d.ts +87 -0
- package/dist/src/components/canvas/whiteboard-node.component.js +809 -0
- package/dist/src/components/canvas/whiteboard-node.style.d.ts +7 -0
- package/dist/src/components/canvas/whiteboard-node.style.js +775 -0
- package/dist/src/components/canvas/workflow-canvas.component.d.ts +150 -0
- package/dist/src/components/canvas/workflow-canvas.component.js +1468 -0
- package/dist/src/components/canvas/workflow-canvas.style.d.ts +8 -0
- package/dist/src/components/canvas/workflow-canvas.style.js +2903 -0
- package/dist/src/components/canvas/workflow-canvas.types.d.ts +710 -0
- package/dist/src/components/canvas/workflow-canvas.types.js +2305 -0
- package/dist/src/components/canvas/workflow-node.component.d.ts +96 -0
- package/dist/src/components/canvas/workflow-node.component.js +752 -0
- package/dist/src/components/canvas/workflow-node.style.d.ts +8 -0
- package/dist/src/components/canvas/workflow-node.style.js +1053 -0
- package/dist/src/components/card/bundle.js +69 -0
- package/dist/src/components/card/bundle.js.gz +0 -0
- package/dist/src/components/card/card.component.d.ts +30 -0
- package/dist/src/components/card/card.component.js +64 -0
- package/dist/src/components/card/card.style.d.ts +2 -0
- package/dist/src/components/card/card.style.js +62 -0
- package/dist/src/components/card/card.types.d.ts +17 -0
- package/dist/src/components/card/card.types.js +2 -0
- package/dist/src/components/card/index.d.ts +3 -0
- package/dist/src/components/card/index.js +3 -0
- package/dist/src/components/card/react.d.ts +5 -0
- package/dist/src/components/card/react.js +12 -0
- package/dist/src/components/carousel/bundle.js +96 -0
- package/dist/src/components/carousel/bundle.js.gz +0 -0
- package/dist/src/components/carousel/carousel.component.d.ts +19 -0
- package/dist/src/components/carousel/carousel.component.js +128 -0
- package/dist/src/components/carousel/carousel.style.d.ts +2 -0
- package/dist/src/components/carousel/carousel.style.js +68 -0
- package/dist/src/components/carousel/index.d.ts +2 -0
- package/dist/src/components/carousel/index.js +2 -0
- package/dist/src/components/carousel/react.d.ts +5 -0
- package/dist/src/components/carousel/react.js +12 -0
- package/dist/src/components/chatbot/bundle.js +2527 -0
- package/dist/src/components/chatbot/bundle.js.gz +0 -0
- package/dist/src/components/chatbot/chatbot.component.d.ts +215 -0
- package/dist/src/components/chatbot/chatbot.component.js +1097 -0
- package/dist/src/components/chatbot/chatbot.style.d.ts +3 -0
- package/dist/src/components/chatbot/chatbot.style.js +1638 -0
- package/dist/src/components/chatbot/chatbot.types.d.ts +246 -0
- package/dist/src/components/chatbot/chatbot.types.js +124 -0
- package/dist/src/components/chatbot/index.d.ts +13 -0
- package/dist/src/components/chatbot/index.js +20 -0
- package/dist/src/components/chatbot/react.d.ts +54 -0
- package/dist/src/components/chatbot/react.js +55 -0
- package/dist/src/components/checkbox/bundle.js +352 -0
- package/dist/src/components/checkbox/bundle.js.gz +0 -0
- package/dist/src/components/checkbox/checkbox.component.d.ts +62 -0
- package/dist/src/components/checkbox/checkbox.component.js +178 -0
- package/dist/src/components/checkbox/checkbox.style.d.ts +2 -0
- package/dist/src/components/checkbox/checkbox.style.js +323 -0
- package/dist/src/components/checkbox/checkbox.types.d.ts +6 -0
- package/dist/src/components/checkbox/checkbox.types.js +2 -0
- package/dist/src/components/checkbox/index.d.ts +2 -0
- package/dist/src/components/checkbox/index.js +2 -0
- package/dist/src/components/checkbox/react.d.ts +5 -0
- package/dist/src/components/checkbox/react.js +12 -0
- package/dist/src/components/code-editor/bundle.js +55 -0
- package/dist/src/components/code-editor/bundle.js.gz +0 -0
- package/dist/src/components/code-editor/code-editor.component.d.ts +119 -0
- package/dist/src/components/code-editor/code-editor.component.js +532 -0
- package/dist/src/components/code-editor/code-editor.style.d.ts +7 -0
- package/dist/src/components/code-editor/code-editor.style.js +39 -0
- package/dist/src/components/code-editor/code-editor.types.d.ts +39 -0
- package/dist/src/components/code-editor/code-editor.types.js +22 -0
- package/dist/src/components/code-editor/index.d.ts +9 -0
- package/dist/src/components/code-editor/index.js +9 -0
- package/dist/src/components/collapse/bundle.js +308 -0
- package/dist/src/components/collapse/bundle.js.gz +0 -0
- package/dist/src/components/collapse/collapse.component.d.ts +93 -0
- package/dist/src/components/collapse/collapse.component.js +322 -0
- package/dist/src/components/collapse/collapse.style.d.ts +11 -0
- package/dist/src/components/collapse/collapse.style.js +234 -0
- package/dist/src/components/collapse/collapse.type.d.ts +79 -0
- package/dist/src/components/collapse/collapse.type.js +11 -0
- package/dist/src/components/collapse/index.d.ts +2 -0
- package/dist/src/components/collapse/index.js +2 -0
- package/dist/src/components/collapse/react.d.ts +6 -0
- package/dist/src/components/collapse/react.js +13 -0
- package/dist/src/components/colorpicker/bundle.js +242 -0
- package/dist/src/components/colorpicker/bundle.js.gz +0 -0
- package/dist/src/components/colorpicker/color-holder.component.d.ts +50 -0
- package/dist/src/components/colorpicker/color-holder.component.js +116 -0
- package/dist/src/components/colorpicker/color-holder.style.d.ts +2 -0
- package/dist/src/components/colorpicker/color-holder.style.js +45 -0
- package/dist/src/components/colorpicker/color-picker.component.d.ts +178 -0
- package/dist/src/components/colorpicker/color-picker.component.js +374 -0
- package/dist/src/components/colorpicker/color-picker.style.d.ts +10 -0
- package/dist/src/components/colorpicker/color-picker.style.js +86 -0
- package/dist/src/components/colorpicker/color-picker.types.d.ts +60 -0
- package/dist/src/components/colorpicker/color-picker.types.js +2 -0
- package/dist/src/components/colorpicker/default-color-sets.component.d.ts +45 -0
- package/dist/src/components/colorpicker/default-color-sets.component.js +121 -0
- package/dist/src/components/colorpicker/default-color-sets.style.d.ts +2 -0
- package/dist/src/components/colorpicker/default-color-sets.style.js +34 -0
- package/dist/src/components/colorpicker/index.d.ts +3 -0
- package/dist/src/components/colorpicker/index.js +3 -0
- package/dist/src/components/colorpicker/react.d.ts +6 -0
- package/dist/src/components/colorpicker/react.js +13 -0
- package/dist/src/components/console/react.d.ts +340 -0
- package/dist/src/components/console/react.js +13 -0
- package/dist/src/components/container/bundle.js +161 -0
- package/dist/src/components/container/bundle.js.gz +0 -0
- package/dist/src/components/container/container.component.d.ts +85 -0
- package/dist/src/components/container/container.component.js +223 -0
- package/dist/src/components/container/container.style.d.ts +6 -0
- package/dist/src/components/container/container.style.js +146 -0
- package/dist/src/components/container/container.types.d.ts +67 -0
- package/dist/src/components/container/container.types.js +5 -0
- package/dist/src/components/container/index.d.ts +3 -0
- package/dist/src/components/container/index.js +3 -0
- package/dist/src/components/container/react.d.ts +3 -0
- package/dist/src/components/container/react.js +10 -0
- package/dist/src/components/datepicker/bundle.js +706 -0
- package/dist/src/components/datepicker/bundle.js.gz +0 -0
- package/dist/src/components/datepicker/datepicker.component.d.ts +190 -0
- package/dist/src/components/datepicker/datepicker.component.js +673 -0
- package/dist/src/components/datepicker/datepicker.constant.d.ts +60 -0
- package/dist/src/components/datepicker/datepicker.constant.js +60 -0
- package/dist/src/components/datepicker/datepicker.style.d.ts +17 -0
- package/dist/src/components/datepicker/datepicker.style.js +453 -0
- package/dist/src/components/datepicker/datepicker.style.variables.d.ts +2 -0
- package/dist/src/components/datepicker/datepicker.style.variables.js +119 -0
- package/dist/src/components/datepicker/datepicker.types.d.ts +142 -0
- package/dist/src/components/datepicker/datepicker.types.js +75 -0
- package/dist/src/components/datepicker/index.d.ts +4 -0
- package/dist/src/components/datepicker/index.js +4 -0
- package/dist/src/components/datepicker/react.d.ts +16 -0
- package/dist/src/components/datepicker/react.js +23 -0
- package/dist/src/components/db-connection-select/bundle.js +308 -0
- package/dist/src/components/db-connection-select/bundle.js.gz +0 -0
- package/dist/src/components/db-connection-select/db-connection-select.component.d.ts +105 -0
- package/dist/src/components/db-connection-select/db-connection-select.component.js +573 -0
- package/dist/src/components/db-connection-select/index.d.ts +7 -0
- package/dist/src/components/db-connection-select/index.js +7 -0
- package/dist/src/components/divider/bundle.js +143 -0
- package/dist/src/components/divider/bundle.js.gz +0 -0
- package/dist/src/components/divider/divider.component.d.ts +90 -0
- package/dist/src/components/divider/divider.component.js +168 -0
- package/dist/src/components/divider/divider.style.d.ts +3 -0
- package/dist/src/components/divider/divider.style.js +139 -0
- package/dist/src/components/divider/divider.types.d.ts +55 -0
- package/dist/src/components/divider/divider.types.js +6 -0
- package/dist/src/components/divider/index.d.ts +3 -0
- package/dist/src/components/divider/index.js +3 -0
- package/dist/src/components/divider/react.d.ts +3 -0
- package/dist/src/components/divider/react.js +10 -0
- package/dist/src/components/document/bundle.js +242 -0
- package/dist/src/components/document/bundle.js.gz +0 -0
- package/dist/src/components/document/document.component.d.ts +27 -0
- package/dist/src/components/document/document.component.js +136 -0
- package/dist/src/components/document/document.style.d.ts +3 -0
- package/dist/src/components/document/document.style.js +210 -0
- package/dist/src/components/document/document.types.d.ts +68 -0
- package/dist/src/components/document/document.types.js +7 -0
- package/dist/src/components/document/index.d.ts +3 -0
- package/dist/src/components/document/index.js +3 -0
- package/dist/src/components/document/react.d.ts +8 -0
- package/dist/src/components/document/react.js +15 -0
- package/dist/src/components/dropdown/bundle.js +528 -0
- package/dist/src/components/dropdown/bundle.js.gz +0 -0
- package/dist/src/components/dropdown/dropdown.component.d.ts +120 -0
- package/dist/src/components/dropdown/dropdown.component.js +390 -0
- package/dist/src/components/dropdown/dropdown.style.d.ts +2 -0
- package/dist/src/components/dropdown/dropdown.style.js +460 -0
- package/dist/src/components/dropdown/dropdown.types.d.ts +99 -0
- package/dist/src/components/dropdown/dropdown.types.js +2 -0
- package/dist/src/components/dropdown/index.d.ts +3 -0
- package/dist/src/components/dropdown/index.js +3 -0
- package/dist/src/components/dropdown/react.d.ts +7 -0
- package/dist/src/components/dropdown/react.js +14 -0
- package/dist/src/components/file-upload/bundle.js +472 -0
- package/dist/src/components/file-upload/bundle.js.gz +0 -0
- package/dist/src/components/file-upload/file-upload.component.d.ts +43 -0
- package/dist/src/components/file-upload/file-upload.component.js +398 -0
- package/dist/src/components/file-upload/index.d.ts +2 -0
- package/dist/src/components/file-upload/index.js +2 -0
- package/dist/src/components/file-upload/react.d.ts +7 -0
- package/dist/src/components/file-upload/react.js +14 -0
- package/dist/src/components/file-upload/styles.d.ts +2 -0
- package/dist/src/components/file-upload/styles.js +373 -0
- package/dist/src/components/file-upload/types.d.ts +11 -0
- package/dist/src/components/file-upload/types.js +2 -0
- package/dist/src/components/file-upload/utils.d.ts +6 -0
- package/dist/src/components/file-upload/utils.js +24 -0
- package/dist/src/components/flex/bundle.js +114 -0
- package/dist/src/components/flex/bundle.js.gz +0 -0
- package/dist/src/components/flex/flex.component.d.ts +89 -0
- package/dist/src/components/flex/flex.component.js +178 -0
- package/dist/src/components/flex/flex.style.d.ts +6 -0
- package/dist/src/components/flex/flex.style.js +101 -0
- package/dist/src/components/flex/flex.types.d.ts +63 -0
- package/dist/src/components/flex/flex.types.js +5 -0
- package/dist/src/components/flex/index.d.ts +3 -0
- package/dist/src/components/flex/index.js +3 -0
- package/dist/src/components/flex/react.d.ts +3 -0
- package/dist/src/components/flex/react.js +10 -0
- package/dist/src/components/form/bundle.js +98 -0
- package/dist/src/components/form/bundle.js.gz +0 -0
- package/dist/src/components/form/form.component.d.ts +279 -0
- package/dist/src/components/form/form.component.js +644 -0
- package/dist/src/components/form/form.style.d.ts +7 -0
- package/dist/src/components/form/form.style.js +68 -0
- package/dist/src/components/form/form.types.d.ts +92 -0
- package/dist/src/components/form/form.types.js +38 -0
- package/dist/src/components/form/index.d.ts +10 -0
- package/dist/src/components/form/index.js +13 -0
- package/dist/src/components/grid/bundle.js +202 -0
- package/dist/src/components/grid/bundle.js.gz +0 -0
- package/dist/src/components/grid/col.component.d.ts +103 -0
- package/dist/src/components/grid/col.component.js +253 -0
- package/dist/src/components/grid/col.style.d.ts +6 -0
- package/dist/src/components/grid/col.style.js +117 -0
- package/dist/src/components/grid/grid.types.d.ts +80 -0
- package/dist/src/components/grid/grid.types.js +16 -0
- package/dist/src/components/grid/index.d.ts +4 -0
- package/dist/src/components/grid/index.js +4 -0
- package/dist/src/components/grid/react.d.ts +5 -0
- package/dist/src/components/grid/react.js +17 -0
- package/dist/src/components/grid/row.component.d.ts +83 -0
- package/dist/src/components/grid/row.component.js +197 -0
- package/dist/src/components/grid/row.style.d.ts +6 -0
- package/dist/src/components/grid/row.style.js +68 -0
- package/dist/src/components/icon/bundle.js +340 -0
- package/dist/src/components/icon/bundle.js.gz +0 -0
- package/dist/src/components/icon/icon.component.d.ts +64 -0
- package/dist/src/components/icon/icon.component.js +207 -0
- package/dist/src/components/icon/icon.style.d.ts +2 -0
- package/dist/src/components/icon/icon.style.js +211 -0
- package/dist/src/components/icon/icon.types.d.ts +5 -0
- package/dist/src/components/icon/icon.types.js +2 -0
- package/dist/src/components/icon/icon.variables.d.ts +17 -0
- package/dist/src/components/icon/icon.variables.js +132 -0
- package/dist/src/components/icon/index.d.ts +2 -0
- package/dist/src/components/icon/index.js +2 -0
- package/dist/src/components/icon/react.d.ts +3 -0
- package/dist/src/components/icon/react.js +9 -0
- package/dist/src/components/iconpicker/bundle.js +2811 -0
- package/dist/src/components/iconpicker/bundle.js.gz +0 -0
- package/dist/src/components/iconpicker/icon-picker.component.d.ts +119 -0
- package/dist/src/components/iconpicker/icon-picker.component.js +337 -0
- package/dist/src/components/iconpicker/icon-picker.constant.d.ts +15 -0
- package/dist/src/components/iconpicker/icon-picker.constant.js +31 -0
- package/dist/src/components/iconpicker/icon-picker.style.d.ts +8 -0
- package/dist/src/components/iconpicker/icon-picker.style.js +216 -0
- package/dist/src/components/iconpicker/icon-picker.types.d.ts +49 -0
- package/dist/src/components/iconpicker/icon-picker.types.js +7 -0
- package/dist/src/components/iconpicker/index.d.ts +9 -0
- package/dist/src/components/iconpicker/index.js +9 -0
- package/dist/src/components/iconpicker/react.d.ts +14 -0
- package/dist/src/components/iconpicker/react.js +21 -0
- package/dist/src/components/image/bundle.js +98 -0
- package/dist/src/components/image/bundle.js.gz +0 -0
- package/dist/src/components/image/image.component.d.ts +31 -0
- package/dist/src/components/image/image.component.js +143 -0
- package/dist/src/components/image/image.style.d.ts +3 -0
- package/dist/src/components/image/image.style.js +83 -0
- package/dist/src/components/image/image.types.d.ts +68 -0
- package/dist/src/components/image/image.types.js +7 -0
- package/dist/src/components/image/index.d.ts +3 -0
- package/dist/src/components/image/index.js +3 -0
- package/dist/src/components/image/react.d.ts +8 -0
- package/dist/src/components/image/react.js +15 -0
- package/dist/src/components/input/bundle.js +930 -0
- package/dist/src/components/input/bundle.js.gz +0 -0
- package/dist/src/components/input/index.d.ts +3 -0
- package/dist/src/components/input/index.js +3 -0
- package/dist/src/components/input/input.component.d.ts +174 -0
- package/dist/src/components/input/input.component.js +490 -0
- package/dist/src/components/input/input.style.d.ts +2 -0
- package/dist/src/components/input/input.style.js +810 -0
- package/dist/src/components/input/input.types.d.ts +127 -0
- package/dist/src/components/input/input.types.js +75 -0
- package/dist/src/components/input/react.d.ts +9 -0
- package/dist/src/components/input/react.js +16 -0
- package/dist/src/components/input/validation.d.ts +3 -0
- package/dist/src/components/input/validation.js +3 -0
- package/dist/src/components/kv-secret-select/bundle.js +183 -0
- package/dist/src/components/kv-secret-select/bundle.js.gz +0 -0
- package/dist/src/components/kv-secret-select/index.d.ts +2 -0
- package/dist/src/components/kv-secret-select/index.js +2 -0
- package/dist/src/components/kv-secret-select/kv-secret-select.component.d.ts +83 -0
- package/dist/src/components/kv-secret-select/kv-secret-select.component.js +360 -0
- package/dist/src/components/label/bundle.js +104 -0
- package/dist/src/components/label/bundle.js.gz +0 -0
- package/dist/src/components/label/index.d.ts +2 -0
- package/dist/src/components/label/index.js +2 -0
- package/dist/src/components/label/label.component.d.ts +18 -0
- package/dist/src/components/label/label.component.js +64 -0
- package/dist/src/components/label/label.style.d.ts +3 -0
- package/dist/src/components/label/label.style.js +70 -0
- package/dist/src/components/label/label.style.variables.d.ts +2 -0
- package/dist/src/components/label/label.style.variables.js +35 -0
- package/dist/src/components/label/label.types.d.ts +42 -0
- package/dist/src/components/label/label.types.js +2 -0
- package/dist/src/components/label/react.d.ts +339 -0
- package/dist/src/components/label/react.js +12 -0
- package/dist/src/components/layout/bundle.js +220 -0
- package/dist/src/components/layout/bundle.js.gz +0 -0
- package/dist/src/components/layout/content.component.d.ts +35 -0
- package/dist/src/components/layout/content.component.js +47 -0
- package/dist/src/components/layout/content.style.d.ts +2 -0
- package/dist/src/components/layout/content.style.js +17 -0
- package/dist/src/components/layout/footer.component.d.ts +38 -0
- package/dist/src/components/layout/footer.component.js +60 -0
- package/dist/src/components/layout/footer.style.d.ts +2 -0
- package/dist/src/components/layout/footer.style.js +17 -0
- package/dist/src/components/layout/header.component.d.ts +39 -0
- package/dist/src/components/layout/header.component.js +61 -0
- package/dist/src/components/layout/header.style.d.ts +2 -0
- package/dist/src/components/layout/header.style.js +19 -0
- package/dist/src/components/layout/index.d.ts +8 -0
- package/dist/src/components/layout/index.js +7 -0
- package/dist/src/components/layout/layout.component.d.ts +50 -0
- package/dist/src/components/layout/layout.component.js +89 -0
- package/dist/src/components/layout/layout.style.d.ts +2 -0
- package/dist/src/components/layout/layout.style.js +23 -0
- package/dist/src/components/layout/layout.types.d.ts +75 -0
- package/dist/src/components/layout/layout.types.js +12 -0
- package/dist/src/components/layout/react.d.ts +14 -0
- package/dist/src/components/layout/react.js +37 -0
- package/dist/src/components/layout/sider.component.d.ts +116 -0
- package/dist/src/components/layout/sider.component.js +273 -0
- package/dist/src/components/layout/sider.style.d.ts +2 -0
- package/dist/src/components/layout/sider.style.js +104 -0
- package/dist/src/components/menu/bundle.js +520 -0
- package/dist/src/components/menu/bundle.js.gz +0 -0
- package/dist/src/components/menu/index.d.ts +4 -0
- package/dist/src/components/menu/index.js +2 -0
- package/dist/src/components/menu/menu.component.d.ts +87 -0
- package/dist/src/components/menu/menu.component.js +596 -0
- package/dist/src/components/menu/menu.constants.d.ts +12 -0
- package/dist/src/components/menu/menu.constants.js +14 -0
- package/dist/src/components/menu/menu.style.d.ts +2 -0
- package/dist/src/components/menu/menu.style.js +372 -0
- package/dist/src/components/menu/menu.types.d.ts +66 -0
- package/dist/src/components/menu/menu.types.js +7 -0
- package/dist/src/components/menu/react.d.ts +5 -0
- package/dist/src/components/menu/react.js +12 -0
- package/dist/src/components/modal/bundle.js +442 -0
- package/dist/src/components/modal/bundle.js.gz +0 -0
- package/dist/src/components/modal/index.d.ts +10 -0
- package/dist/src/components/modal/index.js +10 -0
- package/dist/src/components/modal/modal-manager.d.ts +72 -0
- package/dist/src/components/modal/modal-manager.js +170 -0
- package/dist/src/components/modal/modal.component.d.ts +121 -0
- package/dist/src/components/modal/modal.component.js +461 -0
- package/dist/src/components/modal/modal.style.d.ts +9 -0
- package/dist/src/components/modal/modal.style.js +369 -0
- package/dist/src/components/modal/modal.types.d.ts +105 -0
- package/dist/src/components/modal/modal.types.js +93 -0
- package/dist/src/components/modal/react.d.ts +9 -0
- package/dist/src/components/modal/react.js +16 -0
- package/dist/src/components/panel/bundle.js +1075 -0
- package/dist/src/components/panel/bundle.js.gz +0 -0
- package/dist/src/components/panel/index.d.ts +9 -0
- package/dist/src/components/panel/index.js +9 -0
- package/dist/src/components/panel/panel.component.d.ts +199 -0
- package/dist/src/components/panel/panel.component.js +720 -0
- package/dist/src/components/panel/panel.style.d.ts +7 -0
- package/dist/src/components/panel/panel.style.js +497 -0
- package/dist/src/components/panel/panel.types.d.ts +94 -0
- package/dist/src/components/panel/panel.types.js +50 -0
- package/dist/src/components/panel/react.d.ts +11 -0
- package/dist/src/components/panel/react.js +18 -0
- package/dist/src/components/popconfirm/bundle.js +438 -0
- package/dist/src/components/popconfirm/bundle.js.gz +0 -0
- package/dist/src/components/popconfirm/index.d.ts +4 -0
- package/dist/src/components/popconfirm/index.js +4 -0
- package/dist/src/components/popconfirm/popconfirm-manager.component.d.ts +129 -0
- package/dist/src/components/popconfirm/popconfirm-manager.component.js +372 -0
- package/dist/src/components/popconfirm/popconfirm-manager.style.d.ts +2 -0
- package/dist/src/components/popconfirm/popconfirm-manager.style.js +137 -0
- package/dist/src/components/popconfirm/popconfirm.component.d.ts +179 -0
- package/dist/src/components/popconfirm/popconfirm.component.js +409 -0
- package/dist/src/components/popconfirm/popconfirm.style.d.ts +2 -0
- package/dist/src/components/popconfirm/popconfirm.style.js +207 -0
- package/dist/src/components/popconfirm/popconfirm.types.d.ts +104 -0
- package/dist/src/components/popconfirm/popconfirm.types.js +2 -0
- package/dist/src/components/popconfirm/react.d.ts +7 -0
- package/dist/src/components/popconfirm/react.js +14 -0
- package/dist/src/components/radio/bundle.js +180 -0
- package/dist/src/components/radio/bundle.js.gz +0 -0
- package/dist/src/components/radio/index.d.ts +3 -0
- package/dist/src/components/radio/index.js +3 -0
- package/dist/src/components/radio/radio.component.d.ts +70 -0
- package/dist/src/components/radio/radio.component.js +187 -0
- package/dist/src/components/radio/radio.style.d.ts +7 -0
- package/dist/src/components/radio/radio.style.js +149 -0
- package/dist/src/components/radio/radio.types.d.ts +14 -0
- package/dist/src/components/radio/radio.types.js +15 -0
- package/dist/src/components/radio/react.d.ts +12 -0
- package/dist/src/components/radio/react.js +19 -0
- package/dist/src/components/radio-group/bundle.js +430 -0
- package/dist/src/components/radio-group/bundle.js.gz +0 -0
- package/dist/src/components/radio-group/index.d.ts +3 -0
- package/dist/src/components/radio-group/index.js +3 -0
- package/dist/src/components/radio-group/radio-group.component.d.ts +165 -0
- package/dist/src/components/radio-group/radio-group.component.js +437 -0
- package/dist/src/components/radio-group/radio-group.style.d.ts +7 -0
- package/dist/src/components/radio-group/radio-group.style.js +270 -0
- package/dist/src/components/radio-group/radio-group.types.d.ts +39 -0
- package/dist/src/components/radio-group/radio-group.types.js +29 -0
- package/dist/src/components/radio-group/radio.constant.d.ts +2 -0
- package/dist/src/components/radio-group/radio.constant.js +2 -0
- package/dist/src/components/radio-group/react.d.ts +10 -0
- package/dist/src/components/radio-group/react.js +17 -0
- package/dist/src/components/select/bundle.js +721 -0
- package/dist/src/components/select/bundle.js.gz +0 -0
- package/dist/src/components/select/index.d.ts +17 -0
- package/dist/src/components/select/index.js +20 -0
- package/dist/src/components/select/react.d.ts +19 -0
- package/dist/src/components/select/react.js +26 -0
- package/dist/src/components/select/select.component.d.ts +359 -0
- package/dist/src/components/select/select.component.js +775 -0
- package/dist/src/components/select/select.constant.d.ts +133 -0
- package/dist/src/components/select/select.constant.js +136 -0
- package/dist/src/components/select/select.style.d.ts +2 -0
- package/dist/src/components/select/select.style.js +533 -0
- package/dist/src/components/select/select.types.d.ts +100 -0
- package/dist/src/components/select/select.types.js +73 -0
- package/dist/src/components/skeleton/bundle.js +293 -0
- package/dist/src/components/skeleton/bundle.js.gz +0 -0
- package/dist/src/components/skeleton/index.d.ts +3 -0
- package/dist/src/components/skeleton/index.js +3 -0
- package/dist/src/components/skeleton/react.d.ts +3 -0
- package/dist/src/components/skeleton/react.js +10 -0
- package/dist/src/components/skeleton/skeleton.component.d.ts +165 -0
- package/dist/src/components/skeleton/skeleton.component.js +387 -0
- package/dist/src/components/skeleton/skeleton.style.d.ts +2 -0
- package/dist/src/components/skeleton/skeleton.style.js +224 -0
- package/dist/src/components/skeleton/skeleton.types.d.ts +82 -0
- package/dist/src/components/skeleton/skeleton.types.js +2 -0
- package/dist/src/components/slider-input/bundle.js +241 -0
- package/dist/src/components/slider-input/bundle.js.gz +0 -0
- package/dist/src/components/slider-input/index.d.ts +3 -0
- package/dist/src/components/slider-input/index.js +3 -0
- package/dist/src/components/slider-input/react.d.ts +340 -0
- package/dist/src/components/slider-input/react.js +13 -0
- package/dist/src/components/slider-input/slider-input.component.d.ts +38 -0
- package/dist/src/components/slider-input/slider-input.component.js +191 -0
- package/dist/src/components/slider-input/slider-input.style.d.ts +3 -0
- package/dist/src/components/slider-input/slider-input.style.js +171 -0
- package/dist/src/components/slider-input/slider-input.style.variables.d.ts +2 -0
- package/dist/src/components/slider-input/slider-input.style.variables.js +59 -0
- package/dist/src/components/slider-input/slider-input.types.d.ts +21 -0
- package/dist/src/components/slider-input/slider-input.types.js +6 -0
- package/dist/src/components/table/bundle.js +987 -0
- package/dist/src/components/table/bundle.js.gz +0 -0
- package/dist/src/components/table/index.d.ts +2 -0
- package/dist/src/components/table/index.js +2 -0
- package/dist/src/components/table/react.d.ts +7 -0
- package/dist/src/components/table/react.js +14 -0
- package/dist/src/components/table/table.component.d.ts +140 -0
- package/dist/src/components/table/table.component.js +433 -0
- package/dist/src/components/table/table.style.d.ts +3 -0
- package/dist/src/components/table/table.style.js +702 -0
- package/dist/src/components/table/table.types.d.ts +103 -0
- package/dist/src/components/table/table.types.js +2 -0
- package/dist/src/components/tabs/bundle.js +1782 -0
- package/dist/src/components/tabs/bundle.js.gz +0 -0
- package/dist/src/components/tabs/index.d.ts +9 -0
- package/dist/src/components/tabs/index.js +10 -0
- package/dist/src/components/tabs/react.d.ts +50 -0
- package/dist/src/components/tabs/react.js +50 -0
- package/dist/src/components/tabs/tabs.component.d.ts +100 -0
- package/dist/src/components/tabs/tabs.component.js +461 -0
- package/dist/src/components/tabs/tabs.constant.d.ts +20 -0
- package/dist/src/components/tabs/tabs.constant.js +21 -0
- package/dist/src/components/tabs/tabs.style.d.ts +9 -0
- package/dist/src/components/tabs/tabs.style.js +577 -0
- package/dist/src/components/tabs/tabs.types.d.ts +241 -0
- package/dist/src/components/tabs/tabs.types.js +13 -0
- package/dist/src/components/tag/bundle.js +108 -0
- package/dist/src/components/tag/bundle.js.gz +0 -0
- package/dist/src/components/tag/index.d.ts +2 -0
- package/dist/src/components/tag/index.js +2 -0
- package/dist/src/components/tag/react.d.ts +6 -0
- package/dist/src/components/tag/react.js +13 -0
- package/dist/src/components/tag/tag.component.d.ts +57 -0
- package/dist/src/components/tag/tag.component.js +157 -0
- package/dist/src/components/tag/tag.style.d.ts +7 -0
- package/dist/src/components/tag/tag.style.js +88 -0
- package/dist/src/components/tag/tag.types.d.ts +28 -0
- package/dist/src/components/tag/tag.types.js +7 -0
- package/dist/src/components/textarea/bundle.js +404 -0
- package/dist/src/components/textarea/bundle.js.gz +0 -0
- package/dist/src/components/textarea/index.d.ts +8 -0
- package/dist/src/components/textarea/index.js +7 -0
- package/dist/src/components/textarea/react.d.ts +9 -0
- package/dist/src/components/textarea/react.js +16 -0
- package/dist/src/components/textarea/textarea.component.d.ts +203 -0
- package/dist/src/components/textarea/textarea.component.js +657 -0
- package/dist/src/components/textarea/textarea.style.d.ts +59 -0
- package/dist/src/components/textarea/textarea.style.js +386 -0
- package/dist/src/components/textarea/textarea.types.d.ts +102 -0
- package/dist/src/components/textarea/textarea.types.js +14 -0
- package/dist/src/components/timeline/bundle.js +261 -0
- package/dist/src/components/timeline/bundle.js.gz +0 -0
- package/dist/src/components/timeline/index.d.ts +2 -0
- package/dist/src/components/timeline/index.js +2 -0
- package/dist/src/components/timeline/react.d.ts +3 -0
- package/dist/src/components/timeline/react.js +10 -0
- package/dist/src/components/timeline/timeline.component.d.ts +109 -0
- package/dist/src/components/timeline/timeline.component.js +214 -0
- package/dist/src/components/timeline/timeline.style.d.ts +14 -0
- package/dist/src/components/timeline/timeline.style.js +234 -0
- package/dist/src/components/timeline/timeline.types.d.ts +62 -0
- package/dist/src/components/timeline/timeline.types.js +7 -0
- package/dist/src/components/timepicker/bundle.js +810 -0
- package/dist/src/components/timepicker/bundle.js.gz +0 -0
- package/dist/src/components/timepicker/index.d.ts +12 -0
- package/dist/src/components/timepicker/index.js +12 -0
- package/dist/src/components/timepicker/timepicker.component.d.ts +115 -0
- package/dist/src/components/timepicker/timepicker.component.js +743 -0
- package/dist/src/components/timepicker/timepicker.constants.d.ts +85 -0
- package/dist/src/components/timepicker/timepicker.constants.js +85 -0
- package/dist/src/components/timepicker/timepicker.style.d.ts +7 -0
- package/dist/src/components/timepicker/timepicker.style.js +568 -0
- package/dist/src/components/timepicker/timepicker.style.variables.d.ts +2 -0
- package/dist/src/components/timepicker/timepicker.style.variables.js +122 -0
- package/dist/src/components/timepicker/timepicker.types.d.ts +161 -0
- package/dist/src/components/timepicker/timepicker.types.js +125 -0
- package/dist/src/components/toast/bundle.js +393 -0
- package/dist/src/components/toast/bundle.js.gz +0 -0
- package/dist/src/components/toast/index.d.ts +9 -0
- package/dist/src/components/toast/index.js +9 -0
- package/dist/src/components/toast/react.d.ts +7 -0
- package/dist/src/components/toast/react.js +19 -0
- package/dist/src/components/toast/toast.component.d.ts +152 -0
- package/dist/src/components/toast/toast.component.js +368 -0
- package/dist/src/components/toast/toast.style.d.ts +14 -0
- package/dist/src/components/toast/toast.style.js +338 -0
- package/dist/src/components/toast/toast.types.d.ts +124 -0
- package/dist/src/components/toast/toast.types.js +9 -0
- package/dist/src/components/tooltips/bundle.js +123 -0
- package/dist/src/components/tooltips/bundle.js.gz +0 -0
- package/dist/src/components/tooltips/index.d.ts +2 -0
- package/dist/src/components/tooltips/index.js +2 -0
- package/dist/src/components/tooltips/react.d.ts +1 -0
- package/dist/src/components/tooltips/react.js +2 -0
- package/dist/src/components/tooltips/tooltips.component.d.ts +33 -0
- package/dist/src/components/tooltips/tooltips.component.js +313 -0
- package/dist/src/components/tooltips/tooltips.constant.d.ts +13 -0
- package/dist/src/components/tooltips/tooltips.constant.js +15 -0
- package/dist/src/components/tooltips/tooltips.style.d.ts +2 -0
- package/dist/src/components/tooltips/tooltips.style.js +103 -0
- package/dist/src/components/tooltips/tooltips.variables.d.ts +2 -0
- package/dist/src/components/tooltips/tooltips.variables.js +14 -0
- package/dist/src/components/video/bundle.js +171 -0
- package/dist/src/components/video/bundle.js.gz +0 -0
- package/dist/src/components/video/index.d.ts +3 -0
- package/dist/src/components/video/index.js +3 -0
- package/dist/src/components/video/react.d.ts +10 -0
- package/dist/src/components/video/react.js +17 -0
- package/dist/src/components/video/video.component.d.ts +34 -0
- package/dist/src/components/video/video.component.js +184 -0
- package/dist/src/components/video/video.style.d.ts +3 -0
- package/dist/src/components/video/video.style.js +124 -0
- package/dist/src/components/video/video.types.d.ts +80 -0
- package/dist/src/components/video/video.types.js +7 -0
- package/package.json +215 -0
- package/packages/common/README.md +137 -0
- package/packages/common/dist/LICENSE +28 -0
- package/packages/common/dist/README.md +137 -0
- package/packages/common/dist/VERSIONS.md +4 -0
- package/packages/common/dist/constants/index.d.ts +2 -0
- package/packages/common/dist/constants/index.d.ts.map +1 -0
- package/packages/common/dist/constants/index.js +2 -0
- package/packages/common/dist/constants/index.js.map +1 -0
- package/packages/common/dist/constants.d.ts +17 -0
- package/packages/common/dist/constants.d.ts.map +1 -0
- package/packages/common/dist/constants.js +7 -0
- package/packages/common/dist/constants.js.map +1 -0
- package/packages/common/dist/controllers/index.d.ts +2 -0
- package/packages/common/dist/controllers/index.d.ts.map +1 -0
- package/packages/common/dist/controllers/index.js +2 -0
- package/packages/common/dist/controllers/index.js.map +1 -0
- package/packages/common/dist/controllers.d.ts +21 -0
- package/packages/common/dist/controllers.d.ts.map +1 -0
- package/packages/common/dist/controllers.js +22 -0
- package/packages/common/dist/controllers.js.map +1 -0
- package/packages/common/dist/index.d.ts +25 -0
- package/packages/common/dist/index.d.ts.map +1 -0
- package/packages/common/dist/index.js +27 -0
- package/packages/common/dist/index.js.map +1 -0
- package/packages/common/dist/mixins/index.d.ts +2 -0
- package/packages/common/dist/mixins/index.d.ts.map +1 -0
- package/packages/common/dist/mixins/index.js +3 -0
- package/packages/common/dist/mixins/index.js.map +1 -0
- package/packages/common/dist/mixins.d.ts +26 -0
- package/packages/common/dist/mixins.d.ts.map +1 -0
- package/packages/common/dist/mixins.js +29 -0
- package/packages/common/dist/mixins.js.map +1 -0
- package/packages/common/dist/shared/base-mixin.d.ts +42 -0
- package/packages/common/dist/shared/base-mixin.d.ts.map +1 -0
- package/packages/common/dist/shared/base-mixin.js +38 -0
- package/packages/common/dist/shared/base-mixin.js.map +1 -0
- package/packages/common/dist/shared/constants.d.ts +1 -0
- package/packages/common/dist/shared/constants.d.ts.map +1 -0
- package/packages/common/dist/shared/constants.js +2 -0
- package/packages/common/dist/shared/constants.js.map +1 -0
- package/packages/common/dist/shared/controllers/base-validation.controller.d.ts +81 -0
- package/packages/common/dist/shared/controllers/base-validation.controller.d.ts.map +1 -0
- package/packages/common/dist/shared/controllers/base-validation.controller.js +104 -0
- package/packages/common/dist/shared/controllers/base-validation.controller.js.map +1 -0
- package/packages/common/dist/shared/controllers/base.controller.d.ts +76 -0
- package/packages/common/dist/shared/controllers/base.controller.d.ts.map +1 -0
- package/packages/common/dist/shared/controllers/base.controller.js +129 -0
- package/packages/common/dist/shared/controllers/base.controller.js.map +1 -0
- package/packages/common/dist/shared/controllers/dropdown.controller.d.ts +77 -0
- package/packages/common/dist/shared/controllers/dropdown.controller.d.ts.map +1 -0
- package/packages/common/dist/shared/controllers/dropdown.controller.js +341 -0
- package/packages/common/dist/shared/controllers/dropdown.controller.js.map +1 -0
- package/packages/common/dist/shared/controllers/dropdown.interface.d.ts +37 -0
- package/packages/common/dist/shared/controllers/dropdown.interface.d.ts.map +1 -0
- package/packages/common/dist/shared/controllers/dropdown.interface.js +2 -0
- package/packages/common/dist/shared/controllers/dropdown.interface.js.map +1 -0
- package/packages/common/dist/shared/controllers/index.d.ts +6 -0
- package/packages/common/dist/shared/controllers/index.d.ts.map +1 -0
- package/packages/common/dist/shared/controllers/index.js +6 -0
- package/packages/common/dist/shared/controllers/index.js.map +1 -0
- package/packages/common/dist/shared/controllers/theme.controller.d.ts +48 -0
- package/packages/common/dist/shared/controllers/theme.controller.d.ts.map +1 -0
- package/packages/common/dist/shared/controllers/theme.controller.js +133 -0
- package/packages/common/dist/shared/controllers/theme.controller.js.map +1 -0
- package/packages/common/dist/shared/dependency-mixin.d.ts +37 -0
- package/packages/common/dist/shared/dependency-mixin.d.ts.map +1 -0
- package/packages/common/dist/shared/dependency-mixin.js +141 -0
- package/packages/common/dist/shared/dependency-mixin.js.map +1 -0
- package/packages/common/dist/shared/event-handler-mixin.d.ts +64 -0
- package/packages/common/dist/shared/event-handler-mixin.d.ts.map +1 -0
- package/packages/common/dist/shared/event-handler-mixin.js +95 -0
- package/packages/common/dist/shared/event-handler-mixin.js.map +1 -0
- package/packages/common/dist/shared/index.d.ts +13 -0
- package/packages/common/dist/shared/index.d.ts.map +1 -0
- package/packages/common/dist/shared/index.js +17 -0
- package/packages/common/dist/shared/index.js.map +1 -0
- package/packages/common/dist/shared/render-utils.d.ts +103 -0
- package/packages/common/dist/shared/render-utils.d.ts.map +1 -0
- package/packages/common/dist/shared/render-utils.js +132 -0
- package/packages/common/dist/shared/render-utils.js.map +1 -0
- package/packages/common/dist/shared/theme-mixin.d.ts +78 -0
- package/packages/common/dist/shared/theme-mixin.d.ts.map +1 -0
- package/packages/common/dist/shared/theme-mixin.js +194 -0
- package/packages/common/dist/shared/theme-mixin.js.map +1 -0
- package/packages/common/dist/shared/themes.d.ts +44 -0
- package/packages/common/dist/shared/themes.d.ts.map +1 -0
- package/packages/common/dist/shared/themes.js +85 -0
- package/packages/common/dist/shared/themes.js.map +1 -0
- package/packages/common/dist/shared/utils.d.ts +60 -0
- package/packages/common/dist/shared/utils.d.ts.map +1 -0
- package/packages/common/dist/shared/utils.js +85 -0
- package/packages/common/dist/shared/utils.js.map +1 -0
- package/packages/common/dist/shared/validation.types.d.ts +108 -0
- package/packages/common/dist/shared/validation.types.d.ts.map +1 -0
- package/packages/common/dist/shared/validation.types.js +17 -0
- package/packages/common/dist/shared/validation.types.js.map +1 -0
- package/packages/common/dist/themes/index.d.ts +2 -0
- package/packages/common/dist/themes/index.d.ts.map +1 -0
- package/packages/common/dist/themes/index.js +2 -0
- package/packages/common/dist/themes/index.js.map +1 -0
- package/packages/common/dist/themes.d.ts +22 -0
- package/packages/common/dist/themes.d.ts.map +1 -0
- package/packages/common/dist/themes.js +23 -0
- package/packages/common/dist/themes.js.map +1 -0
- package/packages/common/dist/utils/index.d.ts +2 -0
- package/packages/common/dist/utils/index.d.ts.map +1 -0
- package/packages/common/dist/utils/index.js +2 -0
- package/packages/common/dist/utils/index.js.map +1 -0
- package/packages/common/dist/utils.d.ts +22 -0
- package/packages/common/dist/utils.d.ts.map +1 -0
- package/packages/common/dist/utils.js +24 -0
- package/packages/common/dist/utils.js.map +1 -0
- package/packages/themes/README.md +146 -0
- package/packages/themes/dist/README.md +146 -0
- package/packages/themes/dist/carbon.css +2987 -0
- package/packages/themes/dist/default.css +2757 -0
- package/packages/themes/dist/editor.css +1063 -0
- package/packages/themes/dist/index.cjs +46 -0
- package/packages/themes/dist/index.js +46 -0
- package/packages/themes/dist/package.json +59 -0
|
@@ -0,0 +1,438 @@
|
|
|
1
|
+
import{css as o,LitElement as r,html as n,nothing as t}from"lit";import{property as i,state as e,customElement as a}from"lit/decorators.js";import{NuralyUIBaseMixin as c}from"@nuralyui/common/mixins";import{styleMap as l}from"lit/directives/style-map.js";const s=o`
|
|
2
|
+
:host {
|
|
3
|
+
display: inline-block;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
.popconfirm-content {
|
|
7
|
+
display: flex;
|
|
8
|
+
flex-direction: column;
|
|
9
|
+
gap: 12px;
|
|
10
|
+
padding: 12px 16px;
|
|
11
|
+
min-width: 200px;
|
|
12
|
+
max-width: 400px;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.popconfirm-message {
|
|
16
|
+
display: flex;
|
|
17
|
+
gap: 8px;
|
|
18
|
+
align-items: flex-start;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.popconfirm-icon {
|
|
22
|
+
flex-shrink: 0;
|
|
23
|
+
font-size: 16px;
|
|
24
|
+
line-height: 1.5;
|
|
25
|
+
margin-top: 2px;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.popconfirm-icon--warning {
|
|
29
|
+
color: var(--nuraly-color-warning);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.popconfirm-icon--question {
|
|
33
|
+
color: var(--nuraly-color-info);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.popconfirm-icon--info {
|
|
37
|
+
color: var(--nuraly-color-info);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.popconfirm-icon--error {
|
|
41
|
+
color: var(--nuraly-color-error);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.popconfirm-icon--success {
|
|
45
|
+
color: var(--nuraly-color-success);
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.popconfirm-icon--custom {
|
|
49
|
+
color: var(--nuraly-popconfirm-icon-color, var(--nuraly-color-text));
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.popconfirm-text {
|
|
53
|
+
flex: 1;
|
|
54
|
+
display: flex;
|
|
55
|
+
flex-direction: column;
|
|
56
|
+
gap: 4px;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.popconfirm-title {
|
|
60
|
+
color: var(--nuraly-color-text);
|
|
61
|
+
font-size: var(--nuraly-font-size-base);
|
|
62
|
+
font-weight: 600;
|
|
63
|
+
line-height: 1.5;
|
|
64
|
+
margin: 0;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
.popconfirm-description {
|
|
68
|
+
color: var(--nuraly-color-text-secondary);
|
|
69
|
+
font-size: var(--nuraly-font-size-sm);
|
|
70
|
+
line-height: 1.5;
|
|
71
|
+
margin: 0;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.popconfirm-buttons {
|
|
75
|
+
display: flex;
|
|
76
|
+
gap: 8px;
|
|
77
|
+
justify-content: flex-end;
|
|
78
|
+
align-items: center;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
.popconfirm-button {
|
|
82
|
+
padding: 4px 15px;
|
|
83
|
+
font-size: var(--nuraly-font-size-sm);
|
|
84
|
+
border-radius: var(--nuraly-border-radius);
|
|
85
|
+
border: 1px solid transparent;
|
|
86
|
+
cursor: pointer;
|
|
87
|
+
transition: all 0.2s;
|
|
88
|
+
font-weight: 400;
|
|
89
|
+
line-height: 1.5;
|
|
90
|
+
white-space: nowrap;
|
|
91
|
+
user-select: none;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.popconfirm-button:focus-visible {
|
|
95
|
+
outline: 2px solid var(--nuraly-color-primary);
|
|
96
|
+
outline-offset: 2px;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.popconfirm-button--cancel {
|
|
100
|
+
background: var(--nuraly-button-default-background);
|
|
101
|
+
color: var(--nuraly-button-default-text-color);
|
|
102
|
+
border-color: var(--nuraly-button-default-border-color);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.popconfirm-button--cancel:hover:not(:disabled) {
|
|
106
|
+
background: var(--nuraly-button-default-hover-background);
|
|
107
|
+
color: var(--nuraly-button-default-hover-text-color);
|
|
108
|
+
border-color: var(--nuraly-button-default-hover-border-color);
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.popconfirm-button--ok-primary {
|
|
112
|
+
background: var(--nuraly-button-primary-background);
|
|
113
|
+
color: var(--nuraly-button-primary-text-color);
|
|
114
|
+
border-color: var(--nuraly-button-primary-border-color);
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.popconfirm-button--ok-primary:hover:not(:disabled) {
|
|
118
|
+
background: var(--nuraly-button-primary-hover-background);
|
|
119
|
+
color: var(--nuraly-button-primary-hover-text-color);
|
|
120
|
+
border-color: var(--nuraly-button-primary-hover-border-color);
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.popconfirm-button--ok-danger {
|
|
124
|
+
background: var(--nuraly-button-danger-background);
|
|
125
|
+
color: var(--nuraly-button-danger-text-color);
|
|
126
|
+
border-color: var(--nuraly-button-danger-border-color);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
.popconfirm-button--ok-danger:hover:not(:disabled) {
|
|
130
|
+
background: var(--nuraly-button-danger-hover-background);
|
|
131
|
+
color: var(--nuraly-button-danger-hover-text-color);
|
|
132
|
+
border-color: var(--nuraly-button-danger-hover-border-color);
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
.popconfirm-button--ok-secondary {
|
|
136
|
+
background: var(--nuraly-button-secondary-background);
|
|
137
|
+
color: var(--nuraly-button-secondary-text-color);
|
|
138
|
+
border-color: var(--nuraly-button-secondary-border-color);
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.popconfirm-button--ok-secondary:hover:not(:disabled) {
|
|
142
|
+
background: var(--nuraly-button-secondary-hover-background);
|
|
143
|
+
color: var(--nuraly-button-secondary-hover-text-color);
|
|
144
|
+
border-color: var(--nuraly-button-secondary-hover-border-color);
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
.popconfirm-button--ok-default {
|
|
148
|
+
background: var(--nuraly-button-default-background);
|
|
149
|
+
color: var(--nuraly-button-default-text-color);
|
|
150
|
+
border-color: var(--nuraly-button-default-border-color);
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
.popconfirm-button--ok-default:hover:not(:disabled) {
|
|
154
|
+
background: var(--nuraly-button-default-hover-background);
|
|
155
|
+
color: var(--nuraly-button-default-hover-text-color);
|
|
156
|
+
border-color: var(--nuraly-button-default-hover-border-color);
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
.popconfirm-button:disabled {
|
|
160
|
+
opacity: 0.5;
|
|
161
|
+
cursor: not-allowed;
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
.popconfirm-button--loading {
|
|
165
|
+
position: relative;
|
|
166
|
+
pointer-events: none;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
.popconfirm-button--loading::before {
|
|
170
|
+
content: '';
|
|
171
|
+
position: absolute;
|
|
172
|
+
left: 50%;
|
|
173
|
+
top: 50%;
|
|
174
|
+
width: 14px;
|
|
175
|
+
height: 14px;
|
|
176
|
+
margin-left: -7px;
|
|
177
|
+
margin-top: -7px;
|
|
178
|
+
border: 2px solid currentColor;
|
|
179
|
+
border-right-color: transparent;
|
|
180
|
+
border-radius: 50%;
|
|
181
|
+
animation: popconfirm-spin 0.6s linear infinite;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
.popconfirm-button--loading > * {
|
|
185
|
+
visibility: hidden;
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
@keyframes popconfirm-spin {
|
|
189
|
+
0% {
|
|
190
|
+
transform: rotate(0deg);
|
|
191
|
+
}
|
|
192
|
+
100% {
|
|
193
|
+
transform: rotate(360deg);
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
/* RTL Support */
|
|
198
|
+
:host([dir='rtl']) .popconfirm-message {
|
|
199
|
+
direction: rtl;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
:host([dir='rtl']) .popconfirm-buttons {
|
|
203
|
+
flex-direction: row-reverse;
|
|
204
|
+
}
|
|
205
|
+
`
|
|
206
|
+
/**
|
|
207
|
+
* @license
|
|
208
|
+
* Copyright 2023 Nuraly, Laabidi Aymen
|
|
209
|
+
* SPDX-License-Identifier: MIT
|
|
210
|
+
*/;var p=function(o,r,n,t){for(var i,e=arguments.length,a=e<3?r:null===t?t=Object.getOwnPropertyDescriptor(r,n):t,c=o.length-1;c>=0;c--)(i=o[c])&&(a=(e<3?i(a):e>3?i(r,n,a):i(r,n))||a);return e>3&&a&&Object.defineProperty(r,n,a),a},d=function(o,r,n,t){return new(n||(n=Promise))(function(i,e){function a(o){try{l(t.next(o))}catch(o){e(o)}}function c(o){try{l(t.throw(o))}catch(o){e(o)}}function l(o){var r;o.done?i(o.value):(r=o.value,r instanceof n?r:new n(function(o){o(r)})).then(a,c)}l((t=t.apply(o,r||[])).next())})};let u=class extends(c(r)){constructor(){super(...arguments),this.requiredComponents=["nr-dropdown","nr-icon","nr-button","nr-label"],this.title="",this.description="",this.okText="OK",this.cancelText="Cancel",this.okType="primary",this.showCancel=!0,this.icon="exclamation-circle",this.iconColor="",this.placement="top",this.trigger="click",this.disabled=!1,this.arrow=!0,this.open=!1,this.okLoading=!1,this._boundHandleOutsideClick=null,this._boundHandleKeydown=null,this.handleTriggerClick=o=>{this.disabled||(o.stopPropagation(),this.open?this.closePopconfirm():this.openPopconfirm())},this.handleConfirm=o=>d(this,void 0,void 0,function*(){o.stopPropagation();const r=new CustomEvent("nr-confirm",{bubbles:!0,composed:!0,cancelable:!0,detail:{originalEvent:o}});if(this.dispatchEvent(r)&&!r.defaultPrevented){const r=this.onConfirm;if(r&&"function"==typeof r){const n=r(o);if(n&&"function"==typeof n.then){this.okLoading=!0;try{yield n,this.closePopconfirm()}catch(o){console.error("Confirmation failed:",o)}finally{this.okLoading=!1}return}}this.closePopconfirm()}}),this.handleCancel=o=>{o.stopPropagation(),this.dispatchEvent(new CustomEvent("nr-cancel",{bubbles:!0,composed:!0,detail:{originalEvent:o}})),this.closePopconfirm()}}get dropdownElement(){var o;return null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelector("nr-dropdown")}connectedCallback(){super.connectedCallback(),this._boundHandleOutsideClick=this.handleOutsideClick.bind(this),this._boundHandleKeydown=this.handleKeydown.bind(this),document.addEventListener("click",this._boundHandleOutsideClick,!0),document.addEventListener("keydown",this._boundHandleKeydown)}disconnectedCallback(){super.disconnectedCallback(),this._boundHandleOutsideClick&&document.removeEventListener("click",this._boundHandleOutsideClick,!0),this._boundHandleKeydown&&document.removeEventListener("keydown",this._boundHandleKeydown)}openPopconfirm(){this.open=!0,this.dropdownElement&&this.dropdownElement.show(),this.dispatchEvent(new CustomEvent("nr-open-change",{bubbles:!0,composed:!0,detail:{open:!0}}))}handleOutsideClick(o){if(!this.open)return;o.composedPath().includes(this)||this.closePopconfirm()}handleKeydown(o){"Escape"===o.key&&this.open&&this.closePopconfirm()}closePopconfirm(){this.open=!1,this.dropdownElement&&this.dropdownElement.hide(),this.dispatchEvent(new CustomEvent("nr-open-change",{bubbles:!0,composed:!0,detail:{open:!1}}))}getIconColor(){return this.iconColor?this.iconColor:""}getIconClass(){const o={"exclamation-circle":"warning","question-circle":"question","info-circle":"info","close-circle":"error","check-circle":"success"};return this.iconColor?"custom":o[this.icon]||"warning"}renderContent(){const o=this.getIconClass(),r=this.getIconColor();return n`
|
|
211
|
+
<div class="popconfirm-content">
|
|
212
|
+
<div class="popconfirm-message">
|
|
213
|
+
<div
|
|
214
|
+
class="popconfirm-icon popconfirm-icon--${o}"
|
|
215
|
+
style=${r?`color: ${r}`:""}>
|
|
216
|
+
<nr-icon name=${this.icon}></nr-icon>
|
|
217
|
+
</div>
|
|
218
|
+
<div class="popconfirm-text">
|
|
219
|
+
${this.title?n`<nr-label class="popconfirm-title" size="medium">${this.title}</nr-label>`:""}
|
|
220
|
+
${this.description?n`<nr-label class="popconfirm-description" size="small" variant="secondary">${this.description}</nr-label>`:""}
|
|
221
|
+
</div>
|
|
222
|
+
</div>
|
|
223
|
+
<div class="popconfirm-buttons">
|
|
224
|
+
${this.showCancel?n`
|
|
225
|
+
<nr-button
|
|
226
|
+
size="small"
|
|
227
|
+
@click=${this.handleCancel}>
|
|
228
|
+
${this.cancelText}
|
|
229
|
+
</nr-button>
|
|
230
|
+
`:""}
|
|
231
|
+
<nr-button
|
|
232
|
+
size="small"
|
|
233
|
+
type=${"danger"===this.okType?"danger":"primary"===this.okType?"primary":"default"}
|
|
234
|
+
?loading=${this.okLoading}
|
|
235
|
+
?disabled=${this.okLoading}
|
|
236
|
+
@click=${this.handleConfirm}>
|
|
237
|
+
${this.okText}
|
|
238
|
+
</nr-button>
|
|
239
|
+
</div>
|
|
240
|
+
</div>
|
|
241
|
+
`}render(){return n`
|
|
242
|
+
<nr-dropdown
|
|
243
|
+
.open=${this.open}
|
|
244
|
+
.placement=${this.placement}
|
|
245
|
+
trigger="manual"
|
|
246
|
+
?disabled=${this.disabled}
|
|
247
|
+
?arrow=${this.arrow}
|
|
248
|
+
.closeOnOutsideClick=${!1}
|
|
249
|
+
.closeOnEscape=${!1}>
|
|
250
|
+
<div slot="trigger" @click=${this.handleTriggerClick}>
|
|
251
|
+
<slot name="trigger"></slot>
|
|
252
|
+
</div>
|
|
253
|
+
<div slot="content">${this.renderContent()}</div>
|
|
254
|
+
</nr-dropdown>
|
|
255
|
+
`}};u.styles=s,p([i({type:String})],u.prototype,"title",void 0),p([i({type:String})],u.prototype,"description",void 0),p([i({type:String,attribute:"ok-text"})],u.prototype,"okText",void 0),p([i({type:String,attribute:"cancel-text"})],u.prototype,"cancelText",void 0),p([i({type:String,attribute:"ok-type"})],u.prototype,"okType",void 0),p([i({type:Boolean,attribute:"show-cancel"})],u.prototype,"showCancel",void 0),p([i({type:String})],u.prototype,"icon",void 0),p([i({type:String,attribute:"icon-color"})],u.prototype,"iconColor",void 0),p([i({type:String})],u.prototype,"placement",void 0),p([i({type:String})],u.prototype,"trigger",void 0),p([i({type:Boolean})],u.prototype,"disabled",void 0),p([i({type:Boolean})],u.prototype,"arrow",void 0),p([i({type:Boolean,reflect:!0})],u.prototype,"open",void 0),p([e()],u.prototype,"okLoading",void 0),u=p([a("nr-popconfirm")],u);const f=o`
|
|
256
|
+
:host {
|
|
257
|
+
display: block;
|
|
258
|
+
}
|
|
259
|
+
|
|
260
|
+
.popconfirm-manager {
|
|
261
|
+
position: fixed;
|
|
262
|
+
top: 0;
|
|
263
|
+
left: 0;
|
|
264
|
+
width: 100%;
|
|
265
|
+
height: 100%;
|
|
266
|
+
pointer-events: none;
|
|
267
|
+
z-index: var(--nuraly-z-index-popconfirm, 10000);
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
.popconfirm-manager__item {
|
|
271
|
+
position: fixed;
|
|
272
|
+
pointer-events: auto;
|
|
273
|
+
background: var(--nuraly-color-dropdown-background, #ffffff);
|
|
274
|
+
border: 1px solid var(--nuraly-color-dropdown-border, #e0e0e0);
|
|
275
|
+
border-radius: var(--nuraly-border-radius-lg, 8px);
|
|
276
|
+
box-shadow: var(--nuraly-shadow-lg, 0 4px 16px rgba(0, 0, 0, 0.15));
|
|
277
|
+
min-width: 240px;
|
|
278
|
+
max-width: 320px;
|
|
279
|
+
animation: popconfirm-manager-fade-in 0.15s ease-out;
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
@keyframes popconfirm-manager-fade-in {
|
|
283
|
+
from {
|
|
284
|
+
opacity: 0;
|
|
285
|
+
transform: scale(0.95) translateY(-4px);
|
|
286
|
+
}
|
|
287
|
+
to {
|
|
288
|
+
opacity: 1;
|
|
289
|
+
transform: scale(1) translateY(0);
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
.popconfirm-manager__content {
|
|
294
|
+
display: flex;
|
|
295
|
+
flex-direction: column;
|
|
296
|
+
gap: 12px;
|
|
297
|
+
padding: 12px 16px;
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
.popconfirm-manager__message {
|
|
301
|
+
display: flex;
|
|
302
|
+
gap: 8px;
|
|
303
|
+
align-items: flex-start;
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
.popconfirm-manager__icon {
|
|
307
|
+
flex-shrink: 0;
|
|
308
|
+
font-size: 16px;
|
|
309
|
+
line-height: 1.5;
|
|
310
|
+
margin-top: 2px;
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
.popconfirm-manager__icon--warning {
|
|
314
|
+
color: var(--nuraly-color-warning, #faad14);
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
.popconfirm-manager__icon--question {
|
|
318
|
+
color: var(--nuraly-color-info, #1890ff);
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
.popconfirm-manager__icon--info {
|
|
322
|
+
color: var(--nuraly-color-info, #1890ff);
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
.popconfirm-manager__icon--error {
|
|
326
|
+
color: var(--nuraly-color-error, #ff4d4f);
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
.popconfirm-manager__icon--success {
|
|
330
|
+
color: var(--nuraly-color-success, #52c41a);
|
|
331
|
+
}
|
|
332
|
+
|
|
333
|
+
.popconfirm-manager__icon--custom {
|
|
334
|
+
color: inherit;
|
|
335
|
+
}
|
|
336
|
+
|
|
337
|
+
.popconfirm-manager__text {
|
|
338
|
+
flex: 1;
|
|
339
|
+
display: flex;
|
|
340
|
+
flex-direction: column;
|
|
341
|
+
gap: 4px;
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
.popconfirm-manager__title {
|
|
345
|
+
color: var(--nuraly-color-text, #262626);
|
|
346
|
+
font-size: var(--nuraly-font-size-base, 14px);
|
|
347
|
+
font-weight: 600;
|
|
348
|
+
line-height: 1.5;
|
|
349
|
+
margin: 0;
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
.popconfirm-manager__description {
|
|
353
|
+
color: var(--nuraly-color-text-secondary, #666666);
|
|
354
|
+
font-size: var(--nuraly-font-size-sm, 12px);
|
|
355
|
+
line-height: 1.5;
|
|
356
|
+
margin: 0;
|
|
357
|
+
}
|
|
358
|
+
|
|
359
|
+
.popconfirm-manager__buttons {
|
|
360
|
+
display: flex;
|
|
361
|
+
gap: 8px;
|
|
362
|
+
justify-content: flex-end;
|
|
363
|
+
align-items: center;
|
|
364
|
+
}
|
|
365
|
+
|
|
366
|
+
/* Arrow pointer towards cursor */
|
|
367
|
+
.popconfirm-manager__item::before {
|
|
368
|
+
content: '';
|
|
369
|
+
position: absolute;
|
|
370
|
+
left: 16px;
|
|
371
|
+
top: -6px;
|
|
372
|
+
width: 12px;
|
|
373
|
+
height: 12px;
|
|
374
|
+
background: var(--nuraly-color-dropdown-background, #ffffff);
|
|
375
|
+
border: 1px solid var(--nuraly-color-dropdown-border, #e0e0e0);
|
|
376
|
+
border-right: none;
|
|
377
|
+
border-bottom: none;
|
|
378
|
+
transform: rotate(45deg);
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
/* RTL Support */
|
|
382
|
+
:host([dir='rtl']) .popconfirm-manager__message {
|
|
383
|
+
direction: rtl;
|
|
384
|
+
}
|
|
385
|
+
|
|
386
|
+
:host([dir='rtl']) .popconfirm-manager__buttons {
|
|
387
|
+
flex-direction: row-reverse;
|
|
388
|
+
}
|
|
389
|
+
`
|
|
390
|
+
/**
|
|
391
|
+
* @license
|
|
392
|
+
* Copyright 2023 Nuraly, Laabidi Aymen
|
|
393
|
+
* SPDX-License-Identifier: MIT
|
|
394
|
+
*/;var m,h=function(o,r,n,t){for(var i,e=arguments.length,a=e<3?r:null===t?t=Object.getOwnPropertyDescriptor(r,n):t,c=o.length-1;c>=0;c--)(i=o[c])&&(a=(e<3?i(a):e>3?i(r,n,a):i(r,n))||a);return e>3&&a&&Object.defineProperty(r,n,a),a},b=function(o,r,n,t){return new(n||(n=Promise))(function(i,e){function a(o){try{l(t.next(o))}catch(o){e(o)}}function c(o){try{l(t.throw(o))}catch(o){e(o)}}function l(o){var r;o.done?i(o.value):(r=o.value,r instanceof n?r:new n(function(o){o(r)})).then(a,c)}l((t=t.apply(o,r||[])).next())})};let v=m=class extends(c(r)){constructor(){super(...arguments),this.requiredComponents=["nr-icon","nr-button","nr-label"],this.items=[],this._boundHandleOutsideClick=null,this._boundHandleKeydown=null,this._showTimestamp=0}connectedCallback(){super.connectedCallback(),m._instance=this,this._boundHandleOutsideClick=this.handleOutsideClick.bind(this),this._boundHandleKeydown=this.handleKeydown.bind(this),document.addEventListener("click",this._boundHandleOutsideClick,!0),document.addEventListener("keydown",this._boundHandleKeydown)}disconnectedCallback(){super.disconnectedCallback(),m._instance=null,this._boundHandleOutsideClick&&document.removeEventListener("click",this._boundHandleOutsideClick,!0),this._boundHandleKeydown&&document.removeEventListener("keydown",this._boundHandleKeydown)}static getInstance(){return m._instance}static confirm(o,r){return b(this,void 0,void 0,function*(){const n=m.getInstance();return n?new Promise(t=>{n.show(Object.assign(Object.assign({},o),{onConfirm:()=>b(this,void 0,void 0,function*(){var r;yield null===(r=o.onConfirm)||void 0===r?void 0:r.call(o),t(!0)}),onCancel:()=>{var r;null===(r=o.onCancel)||void 0===r||r.call(o),t(!1)}}),r)}):(console.warn("NrPopconfirmManager: No instance found. Add <nr-popconfirm-manager> to your app."),!1)})}show(o,r){const n=this.generateId(),t={id:n,config:o,position:this.adjustPosition(r),loading:!1};return this._showTimestamp=Date.now(),this.items=[t],console.log("[nr-popconfirm-manager] show() called, items:",this.items),this.requestUpdate(),n}close(o){this.items=this.items.filter(r=>r.id!==o)}closeAll(){this.items=[]}handleConfirm(o,r){return b(this,void 0,void 0,function*(){r.stopPropagation();const n=new CustomEvent("nr-popconfirm-confirm",{bubbles:!0,composed:!0,detail:{id:o.id,config:o.config}});if(this.dispatchEvent(n),o.config.onConfirm){const r=o.config.onConfirm();if(r&&"function"==typeof r.then){o.loading=!0,this.requestUpdate();try{yield r}catch(o){console.error("Popconfirm confirmation failed:",o)}finally{o.loading=!1}}}this.close(o.id)})}handleCancel(o,r){var n,t;r.stopPropagation();const i=new CustomEvent("nr-popconfirm-cancel",{bubbles:!0,composed:!0,detail:{id:o.id,config:o.config}});this.dispatchEvent(i),null===(t=(n=o.config).onCancel)||void 0===t||t.call(n),this.close(o.id)}handleOutsideClick(o){var r;if(0===this.items.length)return;if(Date.now()-this._showTimestamp<100)return;const n=o.composedPath(),t=null===(r=this.shadowRoot)||void 0===r?void 0:r.querySelector(".popconfirm-manager__item");t&&!n.includes(t)&&(this.items.forEach(o=>{var r,n;null===(n=(r=o.config).onCancel)||void 0===n||n.call(r)}),this.closeAll())}handleKeydown(o){"Escape"===o.key&&this.items.length>0&&(this.items.forEach(o=>{var r,n;null===(n=(r=o.config).onCancel)||void 0===n||n.call(r)}),this.closeAll())}adjustPosition(o){const r=16,n=window.innerWidth,t=window.innerHeight;let i=o.x,e=o.y;return i+280>n-r&&(i=n-280-r),i<r&&(i=r),e+120>t-r&&(e=o.y-120-8),e<r&&(e=r),{x:i,y:e}}generateId(){return`popconfirm-${crypto.randomUUID()}`}getIconClass(o){return{"exclamation-circle":"warning","question-circle":"question","info-circle":"info","close-circle":"error","check-circle":"success"}[o||""]||"warning"}renderItem(o){const{config:r,position:i}=o,e=r.icon||"exclamation-circle",a=r.iconColor?"custom":this.getIconClass(e),c=!1!==r.showCancel,s={left:`${i.x}px`,top:`${i.y}px`},p=r.iconColor?{color:r.iconColor}:{};return n`
|
|
395
|
+
<div
|
|
396
|
+
class="popconfirm-manager__item"
|
|
397
|
+
style=${l(s)}
|
|
398
|
+
@click=${o=>o.stopPropagation()}
|
|
399
|
+
>
|
|
400
|
+
<div class="popconfirm-manager__content">
|
|
401
|
+
<div class="popconfirm-manager__message">
|
|
402
|
+
<div
|
|
403
|
+
class="popconfirm-manager__icon popconfirm-manager__icon--${a}"
|
|
404
|
+
style=${l(p)}
|
|
405
|
+
>
|
|
406
|
+
<nr-icon name=${e}></nr-icon>
|
|
407
|
+
</div>
|
|
408
|
+
<div class="popconfirm-manager__text">
|
|
409
|
+
${r.title?n`<nr-label class="popconfirm-manager__title" size="medium">${r.title}</nr-label>`:t}
|
|
410
|
+
${r.description?n`<nr-label class="popconfirm-manager__description" size="small" variant="secondary">${r.description}</nr-label>`:t}
|
|
411
|
+
</div>
|
|
412
|
+
</div>
|
|
413
|
+
<div class="popconfirm-manager__buttons">
|
|
414
|
+
${c?n`
|
|
415
|
+
<nr-button
|
|
416
|
+
size="small"
|
|
417
|
+
@click=${r=>this.handleCancel(o,r)}
|
|
418
|
+
>
|
|
419
|
+
${r.cancelText||"Cancel"}
|
|
420
|
+
</nr-button>
|
|
421
|
+
`:t}
|
|
422
|
+
<nr-button
|
|
423
|
+
size="small"
|
|
424
|
+
type=${"danger"===r.okType?"danger":"primary"===r.okType?"primary":"default"}
|
|
425
|
+
?loading=${o.loading}
|
|
426
|
+
?disabled=${o.loading}
|
|
427
|
+
@click=${r=>this.handleConfirm(o,r)}
|
|
428
|
+
>
|
|
429
|
+
${r.okText||"OK"}
|
|
430
|
+
</nr-button>
|
|
431
|
+
</div>
|
|
432
|
+
</div>
|
|
433
|
+
</div>
|
|
434
|
+
`}render(){return 0===this.items.length?t:n`
|
|
435
|
+
<div class="popconfirm-manager">
|
|
436
|
+
${this.items.map(o=>this.renderItem(o))}
|
|
437
|
+
</div>
|
|
438
|
+
`}};v.styles=f,v._instance=null,h([e()],v.prototype,"items",void 0),v=m=h([a("nr-popconfirm-manager")],v);export{u as NrPopconfirmElement,v as NrPopconfirmManagerElement};
|
|
Binary file
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2023 Nuraly, Laabidi Aymen
|
|
4
|
+
* SPDX-License-Identifier: MIT
|
|
5
|
+
*/
|
|
6
|
+
import { LitElement, nothing } from 'lit';
|
|
7
|
+
import { PopconfirmShowConfig, PopconfirmPosition } from './popconfirm.types.js';
|
|
8
|
+
declare const NrPopconfirmManagerElement_base: (new (...args: any[]) => import("@nuralyui/common/mixins").DependencyAware) & (new (...args: any[]) => import("@nuralyui/common/mixins").ThemeAware) & (new (...args: any[]) => import("@nuralyui/common/mixins").EventHandlerCapable) & typeof LitElement;
|
|
9
|
+
/**
|
|
10
|
+
* # PopconfirmManager Component
|
|
11
|
+
*
|
|
12
|
+
* A container component that manages popconfirm instances displayed at cursor position.
|
|
13
|
+
* Similar to toast notifications but for confirmation dialogs.
|
|
14
|
+
*
|
|
15
|
+
* ## Features
|
|
16
|
+
* - Show popconfirm at cursor/mouse position
|
|
17
|
+
* - Programmatic API for creating confirmations
|
|
18
|
+
* - Async confirmation support with loading state
|
|
19
|
+
* - Auto-dismiss on outside click or escape
|
|
20
|
+
* - Customizable appearance and callbacks
|
|
21
|
+
*
|
|
22
|
+
* ## Usage
|
|
23
|
+
* ```html
|
|
24
|
+
* <!-- Add once to your app -->
|
|
25
|
+
* <nr-popconfirm-manager></nr-popconfirm-manager>
|
|
26
|
+
*
|
|
27
|
+
* <!-- Programmatic usage -->
|
|
28
|
+
* <script>
|
|
29
|
+
* const manager = document.querySelector('nr-popconfirm-manager');
|
|
30
|
+
*
|
|
31
|
+
* // Show at cursor position (from click event)
|
|
32
|
+
* element.addEventListener('click', (e) => {
|
|
33
|
+
* manager.show({
|
|
34
|
+
* title: 'Delete item?',
|
|
35
|
+
* description: 'This action cannot be undone.',
|
|
36
|
+
* okType: 'danger',
|
|
37
|
+
* onConfirm: () => {
|
|
38
|
+
* console.log('Deleted!');
|
|
39
|
+
* }
|
|
40
|
+
* }, { x: e.clientX, y: e.clientY });
|
|
41
|
+
* });
|
|
42
|
+
*
|
|
43
|
+
* // Or use the static confirm helper
|
|
44
|
+
* const confirmed = await NrPopconfirmManager.confirm({
|
|
45
|
+
* title: 'Are you sure?',
|
|
46
|
+
* }, { x: event.clientX, y: event.clientY });
|
|
47
|
+
* </script>
|
|
48
|
+
* ```
|
|
49
|
+
*
|
|
50
|
+
* @element nr-popconfirm-manager
|
|
51
|
+
* @fires nr-popconfirm-confirm - Fired when user confirms
|
|
52
|
+
* @fires nr-popconfirm-cancel - Fired when user cancels
|
|
53
|
+
*/
|
|
54
|
+
export declare class NrPopconfirmManagerElement extends NrPopconfirmManagerElement_base {
|
|
55
|
+
static styles: import("lit").CSSResult;
|
|
56
|
+
requiredComponents: string[];
|
|
57
|
+
/** Active popconfirm items */
|
|
58
|
+
private items;
|
|
59
|
+
/** Bound event handlers */
|
|
60
|
+
private _boundHandleOutsideClick;
|
|
61
|
+
private _boundHandleKeydown;
|
|
62
|
+
/** Timestamp when popconfirm was shown (to prevent immediate close from same click) */
|
|
63
|
+
private _showTimestamp;
|
|
64
|
+
/** Static instance for global access */
|
|
65
|
+
private static _instance;
|
|
66
|
+
connectedCallback(): void;
|
|
67
|
+
disconnectedCallback(): void;
|
|
68
|
+
/**
|
|
69
|
+
* Get the global instance
|
|
70
|
+
*/
|
|
71
|
+
static getInstance(): NrPopconfirmManagerElement | null;
|
|
72
|
+
/**
|
|
73
|
+
* Static helper to show a confirmation dialog
|
|
74
|
+
* Returns a promise that resolves to true if confirmed, false if cancelled
|
|
75
|
+
*/
|
|
76
|
+
static confirm(config: PopconfirmShowConfig, position: PopconfirmPosition): Promise<boolean>;
|
|
77
|
+
/**
|
|
78
|
+
* Show a popconfirm at the specified position
|
|
79
|
+
*/
|
|
80
|
+
show(config: PopconfirmShowConfig, position: PopconfirmPosition): string;
|
|
81
|
+
/**
|
|
82
|
+
* Close a specific popconfirm
|
|
83
|
+
*/
|
|
84
|
+
close(id: string): void;
|
|
85
|
+
/**
|
|
86
|
+
* Close all popconfirms
|
|
87
|
+
*/
|
|
88
|
+
closeAll(): void;
|
|
89
|
+
/**
|
|
90
|
+
* Handle confirm button click
|
|
91
|
+
*/
|
|
92
|
+
private handleConfirm;
|
|
93
|
+
/**
|
|
94
|
+
* Handle cancel button click
|
|
95
|
+
*/
|
|
96
|
+
private handleCancel;
|
|
97
|
+
/**
|
|
98
|
+
* Handle clicks outside the popconfirm
|
|
99
|
+
*/
|
|
100
|
+
private handleOutsideClick;
|
|
101
|
+
/**
|
|
102
|
+
* Handle escape key
|
|
103
|
+
*/
|
|
104
|
+
private handleKeydown;
|
|
105
|
+
/**
|
|
106
|
+
* Adjust position to keep popconfirm within viewport
|
|
107
|
+
*/
|
|
108
|
+
private adjustPosition;
|
|
109
|
+
/**
|
|
110
|
+
* Generate unique ID
|
|
111
|
+
*/
|
|
112
|
+
private generateId;
|
|
113
|
+
/**
|
|
114
|
+
* Get icon color based on icon type
|
|
115
|
+
*/
|
|
116
|
+
private getIconClass;
|
|
117
|
+
/**
|
|
118
|
+
* Render a single popconfirm item
|
|
119
|
+
*/
|
|
120
|
+
private renderItem;
|
|
121
|
+
render(): typeof nothing | import("lit-html").TemplateResult<1>;
|
|
122
|
+
}
|
|
123
|
+
declare global {
|
|
124
|
+
interface HTMLElementTagNameMap {
|
|
125
|
+
'nr-popconfirm-manager': NrPopconfirmManagerElement;
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
export {};
|
|
129
|
+
//# sourceMappingURL=popconfirm-manager.component.d.ts.map
|