@beeq/core 1.10.0-beta.2 → 1.10.0-beta.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/beeq/beeq.css +1 -1
- package/dist/beeq/beeq.esm.js +1 -1
- package/dist/beeq/beeq.esm.js.map +1 -1
- package/dist/beeq/bq-accordion-group.entry.esm.js.map +1 -1
- package/dist/beeq/bq-accordion.entry.esm.js.map +1 -1
- package/dist/beeq/bq-alert.entry.esm.js.map +1 -1
- package/dist/beeq/bq-avatar.entry.esm.js.map +1 -1
- package/dist/beeq/bq-badge.entry.esm.js.map +1 -1
- package/dist/beeq/bq-breadcrumb-item.entry.esm.js.map +1 -1
- package/dist/beeq/bq-breadcrumb.entry.esm.js.map +1 -1
- package/dist/beeq/bq-button.bq-icon.entry.esm.js.map +1 -1
- package/dist/beeq/bq-card.entry.esm.js.map +1 -1
- package/dist/beeq/bq-checkbox.entry.esm.js.map +1 -1
- package/dist/beeq/bq-date-picker.entry.esm.js.map +1 -1
- package/dist/beeq/bq-dialog.entry.esm.js.map +1 -1
- package/dist/beeq/bq-divider.entry.esm.js.map +1 -1
- package/dist/beeq/bq-drawer.entry.esm.js.map +1 -1
- package/dist/beeq/bq-dropdown.bq-panel.entry.esm.js.map +1 -1
- package/dist/beeq/bq-empty-state.entry.esm.js.map +1 -1
- package/dist/beeq/bq-input.entry.esm.js.map +1 -1
- package/dist/beeq/bq-notification.entry.esm.js.map +1 -1
- package/dist/beeq/bq-option-group.entry.esm.js.map +1 -1
- package/dist/beeq/bq-option-list.bq-tag.entry.esm.js.map +1 -1
- package/dist/beeq/bq-option.entry.esm.js.map +1 -1
- package/dist/beeq/bq-page-title.entry.esm.js.map +1 -1
- package/dist/beeq/bq-progress.entry.esm.js.map +1 -1
- package/dist/beeq/bq-radio-group.entry.esm.js.map +1 -1
- package/dist/beeq/bq-radio.entry.esm.js.map +1 -1
- package/dist/beeq/bq-select.entry.esm.js.map +1 -1
- package/dist/beeq/bq-side-menu-item.entry.esm.js.map +1 -1
- package/dist/beeq/bq-side-menu.entry.esm.js.map +1 -1
- package/dist/beeq/bq-slider.entry.esm.js.map +1 -1
- package/dist/beeq/bq-spinner.entry.esm.js.map +1 -1
- package/dist/beeq/bq-status.entry.esm.js.map +1 -1
- package/dist/beeq/bq-step-item.entry.esm.js.map +1 -1
- package/dist/beeq/bq-steps.entry.esm.js.map +1 -1
- package/dist/beeq/bq-switch.entry.esm.js.map +1 -1
- package/dist/beeq/bq-tab-group.entry.esm.js.map +1 -1
- package/dist/beeq/bq-tab.entry.esm.js.map +1 -1
- package/dist/beeq/bq-textarea.entry.esm.js.map +1 -1
- package/dist/beeq/bq-toast.entry.esm.js.map +1 -1
- package/dist/beeq/bq-tooltip.entry.esm.js.map +1 -1
- package/dist/beeq/index.esm.js +1 -1
- package/dist/beeq/p-00f6ab04.entry.js +6 -0
- package/dist/beeq/{p-e8435655.entry.js.map → p-00f6ab04.entry.js.map} +1 -1
- package/dist/beeq/p-01d832d0.entry.js +6 -0
- package/dist/beeq/{p-ed10c8bf.entry.js.map → p-01d832d0.entry.js.map} +1 -1
- package/dist/beeq/p-0bf9984d.entry.js +6 -0
- package/dist/beeq/{p-e91d1052.entry.js.map → p-0bf9984d.entry.js.map} +1 -1
- package/dist/beeq/p-12249759.entry.js +6 -0
- package/dist/beeq/{p-ab352f43.entry.js.map → p-12249759.entry.js.map} +1 -1
- package/dist/beeq/p-1a19b5fa.entry.js +6 -0
- package/dist/beeq/{p-3f7193fb.entry.js.map → p-1a19b5fa.entry.js.map} +1 -1
- package/dist/beeq/p-1cd5bf89.entry.js +6 -0
- package/dist/beeq/p-1cd5bf89.entry.js.map +1 -0
- package/dist/beeq/p-3464beb1.entry.js +6 -0
- package/dist/beeq/{p-4f24e77c.entry.js.map → p-3464beb1.entry.js.map} +1 -1
- package/dist/beeq/p-38b70ecf.entry.js +6 -0
- package/dist/beeq/{p-4c4201e1.entry.js.map → p-38b70ecf.entry.js.map} +1 -1
- package/dist/beeq/p-3bac8fc4.entry.js +6 -0
- package/dist/beeq/{p-f9734e66.entry.js.map → p-3bac8fc4.entry.js.map} +1 -1
- package/dist/beeq/p-4a29e2d0.entry.js +6 -0
- package/dist/beeq/{p-a6d2ceb4.entry.js.map → p-4a29e2d0.entry.js.map} +1 -1
- package/dist/beeq/p-4a3d974a.entry.js +6 -0
- package/dist/beeq/{p-078d8f91.entry.js.map → p-4a3d974a.entry.js.map} +1 -1
- package/dist/beeq/p-4aa72d5a.entry.js +6 -0
- package/dist/beeq/p-4aa72d5a.entry.js.map +1 -0
- package/dist/beeq/p-50b2fd06.entry.js +6 -0
- package/dist/beeq/{p-c3f20d0e.entry.js.map → p-50b2fd06.entry.js.map} +1 -1
- package/dist/beeq/p-55017e05.entry.js +6 -0
- package/dist/beeq/{p-20d9b09b.entry.js.map → p-55017e05.entry.js.map} +1 -1
- package/dist/beeq/p-58541f26.entry.js +6 -0
- package/dist/beeq/{p-2219f451.entry.js.map → p-58541f26.entry.js.map} +1 -1
- package/dist/beeq/p-5b5442ce.entry.js +6 -0
- package/dist/beeq/{p-6bcae73b.entry.js.map → p-5b5442ce.entry.js.map} +1 -1
- package/dist/beeq/p-622b9249.entry.js +6 -0
- package/dist/beeq/{p-80916524.entry.js.map → p-622b9249.entry.js.map} +1 -1
- package/dist/beeq/p-74daa290.entry.js +6 -0
- package/dist/beeq/{p-0949ff39.entry.js.map → p-74daa290.entry.js.map} +1 -1
- package/dist/beeq/p-7eb5259f.entry.js +6 -0
- package/dist/beeq/{p-189629c7.entry.js.map → p-7eb5259f.entry.js.map} +1 -1
- package/dist/beeq/p-9573c018.entry.js +6 -0
- package/dist/beeq/{p-49bda6bc.entry.js.map → p-9573c018.entry.js.map} +1 -1
- package/dist/beeq/p-968a4833.entry.js +6 -0
- package/dist/beeq/{p-bf7a0a2d.entry.js.map → p-968a4833.entry.js.map} +1 -1
- package/dist/beeq/{p-4iHDua0i.js → p-BsSDkLU5.js} +1 -1
- package/dist/beeq/p-BsSDkLU5.js.map +1 -0
- package/dist/beeq/p-BtpBVYE0.js +6 -0
- package/dist/beeq/p-BtpBVYE0.js.map +1 -0
- package/dist/beeq/p-C4jSqdYP.js +7 -0
- package/dist/beeq/p-C4jSqdYP.js.map +1 -0
- package/dist/beeq/p-a1ad0e09.entry.js +6 -0
- package/dist/beeq/{p-604a001b.entry.js.map → p-a1ad0e09.entry.js.map} +1 -1
- package/dist/beeq/p-a8c20aaf.entry.js +6 -0
- package/dist/beeq/p-a8c20aaf.entry.js.map +1 -0
- package/dist/beeq/p-a9070048.entry.js +6 -0
- package/dist/beeq/{p-98333265.entry.js.map → p-a9070048.entry.js.map} +1 -1
- package/dist/beeq/p-ad869f7e.entry.js +6 -0
- package/dist/beeq/p-ad869f7e.entry.js.map +1 -0
- package/dist/beeq/p-afb356b4.entry.js +6 -0
- package/dist/beeq/{p-90947d6b.entry.js.map → p-afb356b4.entry.js.map} +1 -1
- package/dist/beeq/p-b3f103da.entry.js +6 -0
- package/dist/beeq/{p-912955f0.entry.js.map → p-b3f103da.entry.js.map} +1 -1
- package/dist/beeq/p-bb038cc5.entry.js +6 -0
- package/dist/beeq/{p-af445f7e.entry.js.map → p-bb038cc5.entry.js.map} +1 -1
- package/dist/beeq/p-c00bcbe6.entry.js +6 -0
- package/dist/beeq/{p-a489f10f.entry.js.map → p-c00bcbe6.entry.js.map} +1 -1
- package/dist/beeq/p-c110a7ea.entry.js +6 -0
- package/dist/beeq/{p-f683e400.entry.js.map → p-c110a7ea.entry.js.map} +1 -1
- package/dist/beeq/p-c5b7bad2.entry.js +6 -0
- package/dist/beeq/{p-4623461e.entry.js.map → p-c5b7bad2.entry.js.map} +1 -1
- package/dist/beeq/p-cb1ec3ac.entry.js +6 -0
- package/dist/beeq/p-cb1ec3ac.entry.js.map +1 -0
- package/dist/beeq/p-d4b0dcda.entry.js +6 -0
- package/dist/beeq/{p-50f9e2c0.entry.js.map → p-d4b0dcda.entry.js.map} +1 -1
- package/dist/beeq/p-d58133b8.entry.js +6 -0
- package/dist/beeq/{p-3fa6805d.entry.js.map → p-d58133b8.entry.js.map} +1 -1
- package/dist/beeq/p-d88394b9.entry.js +6 -0
- package/dist/beeq/p-d88394b9.entry.js.map +1 -0
- package/dist/beeq/p-e2b24948.entry.js +6 -0
- package/dist/beeq/{p-d4b529aa.entry.js.map → p-e2b24948.entry.js.map} +1 -1
- package/dist/beeq/p-ea1244cc.entry.js +6 -0
- package/dist/beeq/p-ea1244cc.entry.js.map +1 -0
- package/dist/beeq/p-f738ef10.entry.js +6 -0
- package/dist/beeq/{p-6e7734bb.entry.js.map → p-f738ef10.entry.js.map} +1 -1
- package/dist/beeq/p-fc2f0022.entry.js +6 -0
- package/dist/beeq/p-fc2f0022.entry.js.map +1 -0
- package/dist/beeq.html-custom-data.json +397 -396
- package/dist/cjs/beeq.cjs.js +3 -3
- package/dist/cjs/beeq.cjs.js.map +1 -1
- package/dist/cjs/bq-accordion-group.cjs.entry.js +2 -2
- package/dist/cjs/bq-accordion-group.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-accordion-group.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-accordion.cjs.entry.js +8 -5
- package/dist/cjs/bq-accordion.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-accordion.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-alert.cjs.entry.js +3 -3
- package/dist/cjs/bq-alert.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-alert.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-avatar.cjs.entry.js +4 -4
- package/dist/cjs/bq-avatar.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-avatar.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-badge.cjs.entry.js +6 -6
- package/dist/cjs/bq-badge.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-badge.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-breadcrumb-item.cjs.entry.js +2 -2
- package/dist/cjs/bq-breadcrumb-item.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-breadcrumb-item.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-breadcrumb.cjs.entry.js +2 -2
- package/dist/cjs/bq-breadcrumb.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-breadcrumb.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-button.bq-icon.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-button_2.cjs.entry.js +26 -22
- package/dist/cjs/bq-button_2.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-card.cjs.entry.js +4 -4
- package/dist/cjs/bq-card.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-card.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-checkbox.cjs.entry.js +2 -2
- package/dist/cjs/bq-checkbox.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-checkbox.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-date-picker.cjs.entry.js +3 -3
- package/dist/cjs/bq-date-picker.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-date-picker.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-dialog.cjs.entry.js +2 -2
- package/dist/cjs/bq-dialog.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-dialog.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-divider.cjs.entry.js +2 -2
- package/dist/cjs/bq-divider.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-divider.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-drawer.cjs.entry.js +6 -6
- package/dist/cjs/bq-drawer.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-drawer.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-dropdown.bq-panel.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-dropdown_2.cjs.entry.js +4 -4
- package/dist/cjs/bq-dropdown_2.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-empty-state.cjs.entry.js +2 -2
- package/dist/cjs/bq-empty-state.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-empty-state.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-input.cjs.entry.js +2 -2
- package/dist/cjs/bq-input.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-input.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-notification.cjs.entry.js +2 -2
- package/dist/cjs/bq-notification.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-notification.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-option-group.cjs.entry.js +2 -2
- package/dist/cjs/bq-option-group.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-option-group.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-option-list.bq-tag.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-option-list_2.cjs.entry.js +6 -6
- package/dist/cjs/bq-option-list_2.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-option.cjs.entry.js +2 -2
- package/dist/cjs/bq-option.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-option.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-page-title.cjs.entry.js +4 -4
- package/dist/cjs/bq-page-title.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-page-title.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-progress.cjs.entry.js +5 -5
- package/dist/cjs/bq-progress.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-progress.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-radio-group.cjs.entry.js +209 -102
- package/dist/cjs/bq-radio-group.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-radio-group.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-radio.cjs.entry.js +24 -15
- package/dist/cjs/bq-radio.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-radio.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-select.cjs.entry.js +2 -2
- package/dist/cjs/bq-select.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-select.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-side-menu-item.cjs.entry.js +6 -6
- package/dist/cjs/bq-side-menu-item.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-side-menu-item.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-side-menu.cjs.entry.js +4 -4
- package/dist/cjs/bq-side-menu.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-side-menu.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-slider.cjs.entry.js +7 -5
- package/dist/cjs/bq-slider.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-slider.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-spinner.cjs.entry.js +6 -6
- package/dist/cjs/bq-spinner.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-spinner.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-status.cjs.entry.js +3 -3
- package/dist/cjs/bq-status.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-status.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-step-item.cjs.entry.js +39 -16
- package/dist/cjs/bq-step-item.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-step-item.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-steps.cjs.entry.js +18 -7
- package/dist/cjs/bq-steps.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-steps.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-switch.cjs.entry.js +4 -4
- package/dist/cjs/bq-switch.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-switch.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-tab-group.cjs.entry.js +6 -6
- package/dist/cjs/bq-tab-group.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-tab-group.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-tab.cjs.entry.js +4 -4
- package/dist/cjs/bq-tab.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-tab.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-textarea.cjs.entry.js +5 -5
- package/dist/cjs/bq-textarea.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-textarea.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-toast.cjs.entry.js +3 -3
- package/dist/cjs/bq-toast.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-toast.entry.cjs.js.map +1 -1
- package/dist/cjs/bq-tooltip.cjs.entry.js +4 -4
- package/dist/cjs/bq-tooltip.cjs.entry.js.map +1 -1
- package/dist/cjs/bq-tooltip.entry.cjs.js.map +1 -1
- package/dist/cjs/{getNextElement-B5h_gmRG.js → getNextElement-Bcdj4jIn.js} +4 -4
- package/dist/cjs/getNextElement-Bcdj4jIn.js.map +1 -0
- package/dist/cjs/{index-bEOoX8tm.js → index-BKXwzJHW.js} +545 -168
- package/dist/cjs/index-BKXwzJHW.js.map +1 -0
- package/dist/cjs/{index-CD2anR4A.js → index-BZ6JRHUg.js} +56 -32
- package/dist/cjs/index-BZ6JRHUg.js.map +1 -0
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/accordion/bq-accordion.js +6 -3
- package/dist/collection/components/accordion/bq-accordion.js.map +1 -1
- package/dist/collection/components/accordion/scss/bq-accordion.css +1 -1
- package/dist/collection/components/accordion-group/scss/bq-accordion-group.css +1 -1
- package/dist/collection/components/alert/bq-alert.js +1 -1
- package/dist/collection/components/alert/bq-alert.js.map +1 -1
- package/dist/collection/components/alert/scss/bq-alert.css +1 -1
- package/dist/collection/components/avatar/bq-avatar.js +2 -2
- package/dist/collection/components/avatar/bq-avatar.js.map +1 -1
- package/dist/collection/components/avatar/scss/bq-avatar.css +1 -1
- package/dist/collection/components/badge/bq-badge.js +6 -8
- package/dist/collection/components/badge/bq-badge.js.map +1 -1
- package/dist/collection/components/badge/scss/bq-badge.css +1 -1
- package/dist/collection/components/breadcrumb/scss/bq-breadcrumb.css +1 -1
- package/dist/collection/components/breadcrumb-item/scss/bq-breadcrumb-item.css +1 -1
- package/dist/collection/components/button/scss/bq-button.css +1 -1
- package/dist/collection/components/card/bq-card.js +2 -2
- package/dist/collection/components/card/bq-card.js.map +1 -1
- package/dist/collection/components/card/scss/bq-card.css +1 -1
- package/dist/collection/components/checkbox/scss/bq-checkbox.css +1 -1
- package/dist/collection/components/date-picker/bq-date-picker.js +1 -1
- package/dist/collection/components/date-picker/bq-date-picker.js.map +1 -1
- package/dist/collection/components/date-picker/scss/bq-date-picker.css +1 -1
- package/dist/collection/components/dialog/scss/bq-dialog.css +1 -1
- package/dist/collection/components/divider/scss/bq-divider.css +1 -1
- package/dist/collection/components/drawer/bq-drawer.js +4 -4
- package/dist/collection/components/drawer/bq-drawer.js.map +1 -1
- package/dist/collection/components/drawer/scss/bq-drawer.css +1 -1
- package/dist/collection/components/dropdown/scss/bq-dropdown.css +1 -1
- package/dist/collection/components/empty-state/scss/bq-empty-state.css +1 -1
- package/dist/collection/components/icon/bq-icon.js +14 -9
- package/dist/collection/components/icon/bq-icon.js.map +1 -1
- package/dist/collection/components/icon/helper/request.js +9 -10
- package/dist/collection/components/icon/helper/request.js.map +1 -1
- package/dist/collection/components/icon/scss/bq-icon.css +1 -1
- package/dist/collection/components/input/scss/bq-input.css +1 -1
- package/dist/collection/components/notification/scss/bq-notification.css +1 -1
- package/dist/collection/components/option/scss/bq-option.css +1 -1
- package/dist/collection/components/option-group/scss/bq-option-group.css +1 -1
- package/dist/collection/components/option-list/scss/bq-option-list.css +1 -1
- package/dist/collection/components/page-title/bq-page-title.js +2 -2
- package/dist/collection/components/page-title/bq-page-title.js.map +1 -1
- package/dist/collection/components/page-title/scss/bq-page-title.css +1 -1
- package/dist/collection/components/panel/scss/bq-panel.css +1 -1
- package/dist/collection/components/progress/bq-progress.js +3 -3
- package/dist/collection/components/progress/bq-progress.js.map +1 -1
- package/dist/collection/components/progress/scss/bq-progress.css +1 -1
- package/dist/collection/components/radio/bq-radio.js +61 -28
- package/dist/collection/components/radio/bq-radio.js.map +1 -1
- package/dist/collection/components/radio/scss/bq-radio.css +1 -1
- package/dist/collection/components/radio-group/bq-radio-group.js +220 -115
- package/dist/collection/components/radio-group/bq-radio-group.js.map +1 -1
- package/dist/collection/components/radio-group/scss/bq-radio-group.css +1 -1
- package/dist/collection/components/select/scss/bq-select.css +1 -1
- package/dist/collection/components/side-menu/bq-side-menu.js +2 -2
- package/dist/collection/components/side-menu/scss/bq-side-menu.css +1 -1
- package/dist/collection/components/side-menu-item/bq-side-menu-item.js +7 -10
- package/dist/collection/components/side-menu-item/bq-side-menu-item.js.map +1 -1
- package/dist/collection/components/side-menu-item/scss/bq-side-menu-item.css +1 -1
- package/dist/collection/components/slider/bq-slider.js +5 -3
- package/dist/collection/components/slider/bq-slider.js.map +1 -1
- package/dist/collection/components/slider/scss/bq-slider.css +1 -1
- package/dist/collection/components/spinner/bq-spinner.js +4 -4
- package/dist/collection/components/spinner/scss/bq-spinner.css +1 -1
- package/dist/collection/components/status/bq-status.js +1 -1
- package/dist/collection/components/status/scss/bq-status.css +1 -1
- package/dist/collection/components/step-item/bq-step-item.js +79 -18
- package/dist/collection/components/step-item/bq-step-item.js.map +1 -1
- package/dist/collection/components/step-item/scss/bq-step-item.css +1 -1
- package/dist/collection/components/steps/bq-steps.js +48 -5
- package/dist/collection/components/steps/bq-steps.js.map +1 -1
- package/dist/collection/components/steps/scss/bq-steps.css +1 -1
- package/dist/collection/components/switch/bq-switch.js +2 -2
- package/dist/collection/components/switch/scss/bq-switch.css +1 -1
- package/dist/collection/components/tab/bq-tab.js +2 -2
- package/dist/collection/components/tab/scss/bq-tab.css +1 -1
- package/dist/collection/components/tab-group/bq-tab-group.js +3 -3
- package/dist/collection/components/tab-group/scss/bq-tab-group.css +1 -1
- package/dist/collection/components/tag/bq-tag.js +3 -3
- package/dist/collection/components/tag/scss/bq-tag.css +1 -1
- package/dist/collection/components/textarea/bq-textarea.js +3 -3
- package/dist/collection/components/textarea/scss/bq-textarea.css +1 -1
- package/dist/collection/components/toast/bq-toast.js +1 -1
- package/dist/collection/components/toast/scss/bq-toast.css +1 -1
- package/dist/collection/components/tooltip/bq-tooltip.js +1 -1
- package/dist/collection/components/tooltip/scss/bq-tooltip.css +1 -1
- package/dist/collection/shared/test-utils/index.js +1 -0
- package/dist/collection/shared/test-utils/index.js.map +1 -1
- package/dist/collection/shared/test-utils/setProperties.js +10 -2
- package/dist/collection/shared/test-utils/setProperties.js.map +1 -1
- package/dist/collection/shared/test-utils/waitForSvgLoad.js +61 -0
- package/dist/collection/shared/test-utils/waitForSvgLoad.js.map +1 -0
- package/dist/collection/shared/utils/getNextElement.js +2 -2
- package/dist/collection/shared/utils/getNextElement.js.map +1 -1
- package/dist/components/bq-accordion-group.js +1 -1
- package/dist/components/bq-accordion-group.js.map +1 -1
- package/dist/components/bq-accordion.js +1 -1
- package/dist/components/bq-accordion.js.map +1 -1
- package/dist/components/bq-alert.js +1 -1
- package/dist/components/bq-alert.js.map +1 -1
- package/dist/components/bq-avatar.js +1 -1
- package/dist/components/bq-avatar.js.map +1 -1
- package/dist/components/bq-badge.js +1 -1
- package/dist/components/bq-breadcrumb-item.js +1 -1
- package/dist/components/bq-breadcrumb-item.js.map +1 -1
- package/dist/components/bq-breadcrumb.js +1 -1
- package/dist/components/bq-breadcrumb.js.map +1 -1
- package/dist/components/bq-button.js +1 -1
- package/dist/components/bq-card.js +1 -1
- package/dist/components/bq-card.js.map +1 -1
- package/dist/components/bq-checkbox.js +1 -1
- package/dist/components/bq-checkbox.js.map +1 -1
- package/dist/components/bq-date-picker.js +1 -1
- package/dist/components/bq-date-picker.js.map +1 -1
- package/dist/components/bq-dialog.js +1 -1
- package/dist/components/bq-dialog.js.map +1 -1
- package/dist/components/bq-divider.js +1 -1
- package/dist/components/bq-drawer.js +1 -1
- package/dist/components/bq-drawer.js.map +1 -1
- package/dist/components/bq-dropdown.js +1 -1
- package/dist/components/bq-empty-state.js +1 -1
- package/dist/components/bq-empty-state.js.map +1 -1
- package/dist/components/bq-icon.js +1 -1
- package/dist/components/bq-input.js +1 -1
- package/dist/components/bq-input.js.map +1 -1
- package/dist/components/bq-notification.js +1 -1
- package/dist/components/bq-notification.js.map +1 -1
- package/dist/components/bq-option-group.js +1 -1
- package/dist/components/bq-option-group.js.map +1 -1
- package/dist/components/bq-option-list.js +1 -1
- package/dist/components/bq-option.js +1 -1
- package/dist/components/bq-option.js.map +1 -1
- package/dist/components/bq-page-title.js +1 -1
- package/dist/components/bq-page-title.js.map +1 -1
- package/dist/components/bq-panel.js +1 -1
- package/dist/components/bq-progress.js +1 -1
- package/dist/components/bq-progress.js.map +1 -1
- package/dist/components/bq-radio-group.js +1 -1
- package/dist/components/bq-radio-group.js.map +1 -1
- package/dist/components/bq-radio.js +1 -1
- package/dist/components/bq-radio.js.map +1 -1
- package/dist/components/bq-select.js +1 -1
- package/dist/components/bq-select.js.map +1 -1
- package/dist/components/bq-side-menu-item.js +1 -1
- package/dist/components/bq-side-menu-item.js.map +1 -1
- package/dist/components/bq-side-menu.js +1 -1
- package/dist/components/bq-side-menu.js.map +1 -1
- package/dist/components/bq-slider.js +1 -1
- package/dist/components/bq-slider.js.map +1 -1
- package/dist/components/bq-spinner.js +1 -1
- package/dist/components/bq-spinner.js.map +1 -1
- package/dist/components/bq-status.js +1 -1
- package/dist/components/bq-status.js.map +1 -1
- package/dist/components/bq-step-item.js +1 -1
- package/dist/components/bq-step-item.js.map +1 -1
- package/dist/components/bq-steps.js +1 -1
- package/dist/components/bq-steps.js.map +1 -1
- package/dist/components/bq-switch.js +1 -1
- package/dist/components/bq-switch.js.map +1 -1
- package/dist/components/bq-tab-group.js +1 -1
- package/dist/components/bq-tab-group.js.map +1 -1
- package/dist/components/bq-tab.js +1 -1
- package/dist/components/bq-tab.js.map +1 -1
- package/dist/components/bq-tag.js +1 -1
- package/dist/components/bq-textarea.js +1 -1
- package/dist/components/bq-textarea.js.map +1 -1
- package/dist/components/bq-toast.js +1 -1
- package/dist/components/bq-toast.js.map +1 -1
- package/dist/components/bq-tooltip.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/index.js.map +1 -1
- package/dist/components/p-9gvSRSmi.js +6 -0
- package/dist/components/{p-Cggonv2n.js.map → p-9gvSRSmi.js.map} +1 -1
- package/dist/components/p-B8eXbMij.js +6 -0
- package/dist/components/{p-DLp7W9zW.js.map → p-B8eXbMij.js.map} +1 -1
- package/dist/components/p-BUpGMEPS.js +6 -0
- package/dist/components/{p-DkiBVsAp.js.map → p-BUpGMEPS.js.map} +1 -1
- package/dist/components/p-BmdGoExW.js +6 -0
- package/dist/components/{p-UjIYbgCH.js.map → p-BmdGoExW.js.map} +1 -1
- package/dist/components/p-BrcJUBET.js +6 -0
- package/dist/components/{p-NQu7tItb.js.map → p-BrcJUBET.js.map} +1 -1
- package/dist/components/p-BsSDkLU5.js +6 -0
- package/dist/components/p-BsSDkLU5.js.map +1 -0
- package/dist/components/p-BtpBVYE0.js +6 -0
- package/dist/components/p-BtpBVYE0.js.map +1 -0
- package/dist/components/p-C63H4SKY.js +6 -0
- package/dist/components/{p-BV-P7QQT.js.map → p-C63H4SKY.js.map} +1 -1
- package/dist/components/p-DSDQV9S1.js +6 -0
- package/dist/components/p-DSDQV9S1.js.map +1 -0
- package/dist/components/p-DWg_PDHj.js +6 -0
- package/dist/components/{p-CBNE-LlA.js.map → p-DWg_PDHj.js.map} +1 -1
- package/dist/components/p-DZoizZde.js +6 -0
- package/dist/components/p-DZoizZde.js.map +1 -0
- package/dist/components/p-DdRiQ0rm.js +6 -0
- package/dist/components/{p-CzunKNKG.js.map → p-DdRiQ0rm.js.map} +1 -1
- package/dist/custom-elements.json +4822 -4715
- package/dist/esm/beeq.js +4 -4
- package/dist/esm/beeq.js.map +1 -1
- package/dist/esm/bq-accordion-group.entry.js +2 -2
- package/dist/esm/bq-accordion-group.entry.js.map +1 -1
- package/dist/esm/bq-accordion.entry.js +8 -5
- package/dist/esm/bq-accordion.entry.js.map +1 -1
- package/dist/esm/bq-alert.entry.js +3 -3
- package/dist/esm/bq-alert.entry.js.map +1 -1
- package/dist/esm/bq-avatar.entry.js +4 -4
- package/dist/esm/bq-avatar.entry.js.map +1 -1
- package/dist/esm/bq-badge.entry.js +6 -6
- package/dist/esm/bq-badge.entry.js.map +1 -1
- package/dist/esm/bq-breadcrumb-item.entry.js +2 -2
- package/dist/esm/bq-breadcrumb-item.entry.js.map +1 -1
- package/dist/esm/bq-breadcrumb.entry.js +2 -2
- package/dist/esm/bq-breadcrumb.entry.js.map +1 -1
- package/dist/esm/bq-button.bq-icon.entry.js.map +1 -1
- package/dist/esm/bq-button_2.entry.js +26 -22
- package/dist/esm/bq-button_2.entry.js.map +1 -1
- package/dist/esm/bq-card.entry.js +4 -4
- package/dist/esm/bq-card.entry.js.map +1 -1
- package/dist/esm/bq-checkbox.entry.js +2 -2
- package/dist/esm/bq-checkbox.entry.js.map +1 -1
- package/dist/esm/bq-date-picker.entry.js +3 -3
- package/dist/esm/bq-date-picker.entry.js.map +1 -1
- package/dist/esm/bq-dialog.entry.js +2 -2
- package/dist/esm/bq-dialog.entry.js.map +1 -1
- package/dist/esm/bq-divider.entry.js +2 -2
- package/dist/esm/bq-divider.entry.js.map +1 -1
- package/dist/esm/bq-drawer.entry.js +6 -6
- package/dist/esm/bq-drawer.entry.js.map +1 -1
- package/dist/esm/bq-dropdown.bq-panel.entry.js.map +1 -1
- package/dist/esm/bq-dropdown_2.entry.js +4 -4
- package/dist/esm/bq-dropdown_2.entry.js.map +1 -1
- package/dist/esm/bq-empty-state.entry.js +2 -2
- package/dist/esm/bq-empty-state.entry.js.map +1 -1
- package/dist/esm/bq-input.entry.js +2 -2
- package/dist/esm/bq-input.entry.js.map +1 -1
- package/dist/esm/bq-notification.entry.js +2 -2
- package/dist/esm/bq-notification.entry.js.map +1 -1
- package/dist/esm/bq-option-group.entry.js +2 -2
- package/dist/esm/bq-option-group.entry.js.map +1 -1
- package/dist/esm/bq-option-list.bq-tag.entry.js.map +1 -1
- package/dist/esm/bq-option-list_2.entry.js +6 -6
- package/dist/esm/bq-option-list_2.entry.js.map +1 -1
- package/dist/esm/bq-option.entry.js +2 -2
- package/dist/esm/bq-option.entry.js.map +1 -1
- package/dist/esm/bq-page-title.entry.js +4 -4
- package/dist/esm/bq-page-title.entry.js.map +1 -1
- package/dist/esm/bq-progress.entry.js +5 -5
- package/dist/esm/bq-progress.entry.js.map +1 -1
- package/dist/esm/bq-radio-group.entry.js +206 -99
- package/dist/esm/bq-radio-group.entry.js.map +1 -1
- package/dist/esm/bq-radio.entry.js +24 -15
- package/dist/esm/bq-radio.entry.js.map +1 -1
- package/dist/esm/bq-select.entry.js +2 -2
- package/dist/esm/bq-select.entry.js.map +1 -1
- package/dist/esm/bq-side-menu-item.entry.js +6 -6
- package/dist/esm/bq-side-menu-item.entry.js.map +1 -1
- package/dist/esm/bq-side-menu.entry.js +4 -4
- package/dist/esm/bq-side-menu.entry.js.map +1 -1
- package/dist/esm/bq-slider.entry.js +7 -5
- package/dist/esm/bq-slider.entry.js.map +1 -1
- package/dist/esm/bq-spinner.entry.js +6 -6
- package/dist/esm/bq-spinner.entry.js.map +1 -1
- package/dist/esm/bq-status.entry.js +3 -3
- package/dist/esm/bq-status.entry.js.map +1 -1
- package/dist/esm/bq-step-item.entry.js +39 -16
- package/dist/esm/bq-step-item.entry.js.map +1 -1
- package/dist/esm/bq-steps.entry.js +18 -7
- package/dist/esm/bq-steps.entry.js.map +1 -1
- package/dist/esm/bq-switch.entry.js +4 -4
- package/dist/esm/bq-switch.entry.js.map +1 -1
- package/dist/esm/bq-tab-group.entry.js +6 -6
- package/dist/esm/bq-tab-group.entry.js.map +1 -1
- package/dist/esm/bq-tab.entry.js +4 -4
- package/dist/esm/bq-tab.entry.js.map +1 -1
- package/dist/esm/bq-textarea.entry.js +5 -5
- package/dist/esm/bq-textarea.entry.js.map +1 -1
- package/dist/esm/bq-toast.entry.js +3 -3
- package/dist/esm/bq-toast.entry.js.map +1 -1
- package/dist/esm/bq-tooltip.entry.js +4 -4
- package/dist/esm/bq-tooltip.entry.js.map +1 -1
- package/dist/esm/{getNextElement-4iHDua0i.js → getNextElement-BsSDkLU5.js} +4 -4
- package/dist/esm/getNextElement-BsSDkLU5.js.map +1 -0
- package/dist/esm/{index-DJ_hypV7.js → index-BtpBVYE0.js} +56 -32
- package/dist/esm/index-BtpBVYE0.js.map +1 -0
- package/dist/esm/{index-e5zjNNdI.js → index-C4jSqdYP.js} +546 -168
- package/dist/esm/index-C4jSqdYP.js.map +1 -0
- package/dist/esm/index.js +1 -1
- package/dist/esm/loader.js +3 -3
- package/dist/hydrate/index.js +815 -469
- package/dist/hydrate/index.mjs +815 -469
- package/dist/stencil.config.js +1 -0
- package/dist/stencil.config.js.map +1 -1
- package/dist/types/components/date-picker/bq-date-picker.d.ts +1 -1
- package/dist/types/components/icon/helper/request.d.ts +1 -1
- package/dist/types/components/radio/bq-radio.d.ts +15 -7
- package/dist/types/components/radio-group/bq-radio-group.d.ts +57 -16
- package/dist/types/components/side-menu-item/bq-side-menu-item.d.ts +2 -5
- package/dist/types/components/step-item/bq-step-item.d.ts +10 -6
- package/dist/types/components/steps/bq-steps.d.ts +5 -0
- package/dist/types/components.d.ts +42 -37
- package/dist/types/shared/test-utils/index.d.ts +1 -0
- package/dist/types/shared/test-utils/setProperties.d.ts +1 -1
- package/dist/types/shared/test-utils/waitForSvgLoad.d.ts +19 -0
- package/dist/types/shared/utils/getNextElement.d.ts +2 -2
- package/dist/types/stencil-public-runtime.d.ts +12 -5
- package/package.json +1 -1
- package/dist/beeq/p-078d8f91.entry.js +0 -6
- package/dist/beeq/p-0949ff39.entry.js +0 -6
- package/dist/beeq/p-189629c7.entry.js +0 -6
- package/dist/beeq/p-20d9b09b.entry.js +0 -6
- package/dist/beeq/p-2219f451.entry.js +0 -6
- package/dist/beeq/p-388876c1.entry.js +0 -6
- package/dist/beeq/p-388876c1.entry.js.map +0 -1
- package/dist/beeq/p-3c330710.entry.js +0 -6
- package/dist/beeq/p-3c330710.entry.js.map +0 -1
- package/dist/beeq/p-3f7193fb.entry.js +0 -6
- package/dist/beeq/p-3fa6805d.entry.js +0 -6
- package/dist/beeq/p-41744618.entry.js +0 -6
- package/dist/beeq/p-41744618.entry.js.map +0 -1
- package/dist/beeq/p-4623461e.entry.js +0 -6
- package/dist/beeq/p-49bda6bc.entry.js +0 -6
- package/dist/beeq/p-4c4201e1.entry.js +0 -6
- package/dist/beeq/p-4f24e77c.entry.js +0 -6
- package/dist/beeq/p-4iHDua0i.js.map +0 -1
- package/dist/beeq/p-50f9e2c0.entry.js +0 -6
- package/dist/beeq/p-5105d079.entry.js +0 -6
- package/dist/beeq/p-5105d079.entry.js.map +0 -1
- package/dist/beeq/p-604a001b.entry.js +0 -6
- package/dist/beeq/p-6bcae73b.entry.js +0 -6
- package/dist/beeq/p-6e7734bb.entry.js +0 -6
- package/dist/beeq/p-76ee57c6.entry.js +0 -6
- package/dist/beeq/p-76ee57c6.entry.js.map +0 -1
- package/dist/beeq/p-80916524.entry.js +0 -6
- package/dist/beeq/p-90947d6b.entry.js +0 -6
- package/dist/beeq/p-912955f0.entry.js +0 -6
- package/dist/beeq/p-98333265.entry.js +0 -6
- package/dist/beeq/p-987c0ab6.entry.js +0 -6
- package/dist/beeq/p-987c0ab6.entry.js.map +0 -1
- package/dist/beeq/p-DJ_hypV7.js +0 -6
- package/dist/beeq/p-DJ_hypV7.js.map +0 -1
- package/dist/beeq/p-a489f10f.entry.js +0 -6
- package/dist/beeq/p-a6d2ceb4.entry.js +0 -6
- package/dist/beeq/p-ab352f43.entry.js +0 -6
- package/dist/beeq/p-af445f7e.entry.js +0 -6
- package/dist/beeq/p-bf7a0a2d.entry.js +0 -6
- package/dist/beeq/p-c3f20d0e.entry.js +0 -6
- package/dist/beeq/p-c5fc822f.entry.js +0 -6
- package/dist/beeq/p-c5fc822f.entry.js.map +0 -1
- package/dist/beeq/p-d4b529aa.entry.js +0 -6
- package/dist/beeq/p-e5zjNNdI.js +0 -7
- package/dist/beeq/p-e5zjNNdI.js.map +0 -1
- package/dist/beeq/p-e8435655.entry.js +0 -6
- package/dist/beeq/p-e91d1052.entry.js +0 -6
- package/dist/beeq/p-ed10c8bf.entry.js +0 -6
- package/dist/beeq/p-ee31c3cb.entry.js +0 -6
- package/dist/beeq/p-ee31c3cb.entry.js.map +0 -1
- package/dist/beeq/p-f683e400.entry.js +0 -6
- package/dist/beeq/p-f9734e66.entry.js +0 -6
- package/dist/cjs/getNextElement-B5h_gmRG.js.map +0 -1
- package/dist/cjs/index-CD2anR4A.js.map +0 -1
- package/dist/cjs/index-bEOoX8tm.js.map +0 -1
- package/dist/components/p-9Z6M4Uap.js +0 -6
- package/dist/components/p-9Z6M4Uap.js.map +0 -1
- package/dist/components/p-BV-P7QQT.js +0 -6
- package/dist/components/p-CBNE-LlA.js +0 -6
- package/dist/components/p-Cggonv2n.js +0 -6
- package/dist/components/p-CzunKNKG.js +0 -6
- package/dist/components/p-DBkP6C_Q.js +0 -6
- package/dist/components/p-DBkP6C_Q.js.map +0 -1
- package/dist/components/p-DJ_hypV7.js +0 -6
- package/dist/components/p-DJ_hypV7.js.map +0 -1
- package/dist/components/p-DLp7W9zW.js +0 -6
- package/dist/components/p-DkiBVsAp.js +0 -6
- package/dist/components/p-NQu7tItb.js +0 -6
- package/dist/components/p-UjIYbgCH.js +0 -6
- package/dist/esm/getNextElement-4iHDua0i.js.map +0 -1
- package/dist/esm/index-DJ_hypV7.js.map +0 -1
- package/dist/esm/index-e5zjNNdI.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bq-textarea.entry.esm.js","sources":["../../packages/beeq/src/components/textarea/scss/bq-textarea.scss?tag=bq-textarea&encapsulation=shadow","../../packages/beeq/src/components/textarea/bq-textarea.tsx"],"sourcesContent":["/* -------------------------------------------------------------------------- */\n/* Textarea styles */\n/* -------------------------------------------------------------------------- */\n\n@import './bq-textarea.variables';\n\n:host {\n @apply block is-full;\n}\n\n/* -------------------------------------------------------------------------- */\n/* Label */\n/* -------------------------------------------------------------------------- */\n\n.bq-textarea__label {\n @apply text-[length:--bq-textarea--label-text-size] text-[color:--bq-textarea--label-text-color] m-be-[--bq-textarea--label-margin-bottom];\n}\n\n/* -------------------------------------------------------------------------- */\n/* Native HTML Textarea control */\n/* -------------------------------------------------------------------------- */\n\n.bq-textarea__input {\n @apply flex-auto resize-y bg-[--bq-textarea--background-color] bs-[inherit];\n // Border\n @apply rounded-[--bq-textarea--border-radius] border-[length:--bq-textarea--border-width] border-[color:--bq-textarea--border-color];\n // Padding\n @apply pe-[--bq-textarea--padding-end] ps-[--bq-textarea--padding-start] p-b-[--bq-textarea--paddingY];\n // Text\n @apply text-[length:--bq-textarea--text-size] text-[color:--bq-textarea--text-color] placeholder:text-[color:--bq-textarea--text-placeholder-color];\n // Transition\n @apply transition-colors ease-in-out;\n // Hover\n @apply [&:not([disabled]):not(:focus-within)]:hover:border-hover-brand;\n // Disabled\n @apply disabled:cursor-not-allowed disabled:opacity-60;\n // Focus\n &:not([disabled]):focus-within {\n --bq-ring-width: 1px;\n --bq-ring-offset-width: 0;\n --bq-ring-color-focus: var(--bq-textarea--border-color-focus);\n\n @apply focus border-[color:--bq-ring-color-focus];\n }\n}\n\n/* ------------------------------- Validations ------------------------------- */\n\n.bq-textarea__input.validation-error {\n @apply border-danger [&:not(.disabled):not(:focus-within)]:hover:border-hover-danger;\n\n &:not(.disabled):focus-within {\n --bq-ring-color-focus: theme(stroke.danger);\n\n @apply border-active-danger;\n }\n}\n\n.bq-textarea__input.validation-success {\n @apply border-success [&:not(.disabled):not(:focus-within)]:hover:border-hover-success;\n\n &:not(.disabled):focus-within {\n --bq-ring-color-focus: theme(stroke.success);\n\n @apply border-active-success;\n }\n}\n\n.bq-textarea__input.validation-warning {\n @apply border-warning [&:not(.disabled):not(:focus-within)]:hover:border-hover-warning;\n\n &:not(.disabled):focus-within {\n --bq-ring-color-focus: theme(stroke.warning);\n\n @apply border-active-warning;\n }\n}\n\n/* -------------------------------------------------------------------------- */\n/* Helper text */\n/* -------------------------------------------------------------------------- */\n\n.bq-textarea__helper {\n @apply text-[length:--bq-textarea--helper-text-size] text-[color:--bq-textarea--helper-text-color] m-bs-[--bq-textarea--helper-margin-top];\n}\n\n/* ------------------------------- Validations ------------------------------ */\n\n.bq-textarea__helper.validation-error {\n @apply text-danger;\n}\n\n.bq-textarea__helper.validation-success {\n @apply text-success;\n}\n\n.bq-textarea__helper.validation-warning {\n @apply text-warning;\n}\n\n/* ----------------------------- Helper counter ----------------------------- */\n\n/** Apply a disabled text color style to the textarea counter when the validation is none. */\n.bq-textarea__helper[class~='validation-none'] {\n .bq-textarea__helper--counter {\n @apply opacity-60;\n }\n}\n","import { AttachInternals, Component, Element, Event, h, Prop, State, Watch } from '@stencil/core';\nimport type { EventEmitter } from '@stencil/core';\n\nimport type { TTextareaAutoCapitalize, TTextareaWrap } from './bq-textarea.types';\nimport { debounce, hasSlotContent, isHTMLElement, isNil, TDebounce } from '../../shared/utils';\nimport type { TInputValidation } from '../input/bq-input.types';\n\n/**\n * The Textarea component is a multi-line text input control that is often used in a form to collect user inputs like comments or reviews.\n *\n * @example How to use it\n * ```html\n * <bq-textarea maxlength=\"0\" name=\"textarea\" placeholder=\"Placeholder...\" rows=\"5\">\n * <label slot=\"label\">Label</label>\n * <span class=\"flex items-center gap-xs\" slot=\"helper-text\">\n * <bq-icon name=\"star\"></bq-icon>\n * Helper text\n * </span>\n * </bq-textarea>\n * ```\n *\n * @documentation https://www.beeq.design/3d466e231/p/16792c-textarea\n * @status stable\n *\n * @attr {string} autocapitalize - Controls whether or not the textarea field should be capitalized and how.\n * @attr {string} autocomplete - Specifies whether or not the textarea field should have autocomplete enabled.\n * @attr {string} autocorrect - Controls whether or not the textarea field should have autocorrect enabled.\n * @attr {boolean} autofocus - If `true`, the textarea will be focused on component render.\n * @attr {boolean} auto-grow - If `true`, the textarea will automatically grow and shrink to fit its contents.\n * @attr {number} debounce-time - The amount of time, in milliseconds, to wait before emitting the `bqInput` event after the textarea value changes.\n * @attr {boolean} disabled - If `true`, the user cannot interact with the textarea.\n * @attr {boolean} disable-resize - If `true`, it will block the user's ability to resize the textarea.\n * @attr {string} form - The ID of the form that the textarea field belongs to.\n * @attr {string} form-validation-message - The native form validation message.\n * @attr {number} maxlength - The maximum number of characters that can be entered into the textarea (`0`: no limit).\n * @attr {string} name - The name of the textarea element.\n * @attr {string} placeholder - The placeholder text to show when there is no value.\n * @attr {boolean} readonly - If `true`, the textarea field cannot be modified.\n * @attr {boolean} required - Indicates whether or not the textarea field is required to be filled out before submitting the form.\n * @attr {number} rows - The number of visible text lines for the control. It must be a positive integer.\n * @attr {boolean} spellcheck - If `true`, the textarea content may be checked for spelling errors.\n * @attr {\"error\" | \"none\" | \"success\" | \"warning\"} validation-status - The validation status of the textarea.\n * @attr {string} value - The value of the textarea. It can be used to reset the textarea to a previous value.\n * @attr {\"soft\" | \"hard\"} wrap - Specifies how the text in a text area is to be wrapped when submitted in a form.\n *\n * @event bqBlur - Handler to be called when the textarea loses focus.\n * @event bqChange - Handler to be called when the textarea value has changed and the textarea loses focus.\n * @event bqClear - Handler to be called when the textarea value has been cleared.\n * @event bqFocus - Handler to be called when the textarea has received focus.\n * @event bqInput - Handler to be called when the textarea value changes.\n *\n * @slot label - The textarea label.\n * @slot helper-text - The helper text.\n *\n * @part base - The component's base wrapper.\n * @part input - The textarea element.\n * @part label - The textarea label.\n * @part helper-info - The helper info container.\n * @part helper-text - The helper text.\n * @part helper-counter - The helper counter.\n *\n * @cssprop --bq-textarea--background-color - Textarea background color\n * @cssprop --bq-textarea--border-color - Textarea border color\n * @cssprop --bq-textarea--border-color-focus - Textarea border color on focus\n * @cssprop --bq-textarea--border-radius - Textarea border radius\n * @cssprop --bq-textarea--border-width - Textarea border width\n * @cssprop --bq-textarea--border-style - Textarea border style\n * @cssprop --bq-textarea--helper-margin-top - Textarea helper text margin top\n * @cssprop --bq-textarea--helper-text-color - Textarea helper text color\n * @cssprop --bq-textarea--helper-text-size - Textarea helper text size\n * @cssprop --bq-textarea--label-margin-bottom - Textarea label margin bottom\n * @cssprop --bq-textarea--label-text-color - Textarea label text color\n * @cssprop --bq-textarea--label-text-size - Textarea label text size\n * @cssprop --bq-textarea--paddingY - Textarea padding top and bottom\n * @cssprop --bq-textarea--padding-start - Textarea padding start\n * @cssprop --bq-textarea--padding-end - Textarea padding end\n * @cssprop --bq-textarea--text-color - Textarea text color\n * @cssprop --bq-textarea--text-size - Textarea text size\n * @cssprop --bq-textarea--text-placeholder-color - Textarea placeholder text color\n */\n@Component({\n tag: 'bq-textarea',\n styleUrl: './scss/bq-textarea.scss',\n formAssociated: true,\n shadow: {\n delegatesFocus: true,\n },\n})\nexport class BqTextarea {\n // Own Properties\n // ====================\n\n private debounceBqInput: TDebounce<void>;\n private fallbackId = 'textarea';\n\n private helperTextElem?: HTMLElement;\n private labelElem?: HTMLLabelElement;\n private textarea: HTMLTextAreaElement;\n\n // Reference to host HTML element\n // ===================================\n\n @AttachInternals() internals!: ElementInternals;\n @Element() el!: HTMLBqTextareaElement;\n\n // State() variables\n // Inlined decorator, alphabetical order\n // =======================================\n\n @State() private hasHelperText = false;\n @State() private hasLabel = false;\n\n // Public Property API\n // ========================\n\n /**\n * Controls whether or not the textarea field should be capitalized and how.\n * Possible values are 'off', 'none', 'on', 'sentences', 'words', and 'characters'.\n * See: https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/autocapitalize\n */\n @Prop({ reflect: true }) autocapitalize: TTextareaAutoCapitalize = 'off';\n\n /**\n * Specifies whether or not the textarea field should have autocomplete enabled.\n * See: https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete#values\n */\n @Prop({ reflect: true }) autocomplete: string = 'off';\n\n /**\n * Controls whether or not the textarea field should have autocorrect enabled.\n * Possible values are 'on' and 'off'.\n */\n @Prop({ reflect: true }) autocorrect: 'on' | 'off' = 'off';\n\n /** If true, the textarea will be focused on component render */\n @Prop({ reflect: true }) autofocus: boolean;\n\n /**\n * If `true`, the textarea will automatically grow and shrink to fit its contents.\n * If `false`, the textarea will have a fixed height specified by the `rows` property.\n */\n @Prop({ reflect: true }) autoGrow: boolean = false;\n\n /**\n * The amount of time, in milliseconds, to wait before emitting the `bqInput` event after the textarea value changes.\n * A value of 0 means no debouncing will occur.\n */\n @Prop({ reflect: true, mutable: true }) debounceTime? = 0;\n\n /** If `true`, the user cannot interact with the textarea. */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /** If `true`, it will block the user's ability to resize the textarea. */\n @Prop({ reflect: true }) disableResize?: boolean = false;\n\n /** The ID of the form that the textarea field belongs to. */\n @Prop({ reflect: true }) form?: string;\n\n /** The native form validation message */\n @Prop({ mutable: true }) formValidationMessage?: string;\n\n /**\n * The maximum number of characters that can be entered into the textarea (`0`: no limit).\n * When enabled, a character counter will be shown underneath the textarea.\n */\n @Prop({ reflect: true }) maxlength: number;\n\n /** The name of the textarea element. */\n @Prop({ reflect: true }) name!: string;\n\n /** The placeholder text to show when there is no value. */\n @Prop({ reflect: true }) placeholder!: string;\n\n /** If true, the textarea field cannot be modified. */\n @Prop({ reflect: true }) readonly?: boolean = false;\n\n /** Indicates whether or not the textarea field is required to be filled out before submitting the form. */\n @Prop({ reflect: true }) required?: boolean = false;\n\n /** The number of visible text lines for the control. It must be a positive integer. */\n @Prop({ reflect: true }) rows: number = 5;\n\n /** If true, the textarea content may be checked for spelling errors. */\n @Prop({ reflect: true }) spellcheck: boolean = false;\n /**\n * The validation status of the textarea.\n *\n * @remarks\n * This property is used to indicate the validation status of the textarea. It can be set to one of the following values:\n * - `'none'`: No validation status is set.\n * - `'error'`: The textarea has a validation error.\n * - `'warning'`: The textarea has a validation warning.\n * - `'success'`: The textarea has passed validation.\n */\n @Prop({ reflect: true, mutable: true }) validationStatus: TInputValidation = 'none';\n\n /** The value of the textarea. It can be used to reset the textarea to a previous value. */\n @Prop({ mutable: true }) value: string;\n\n /** Specifies how the text in a text area is to be wrapped when submitted in a form */\n @Prop({ reflect: true }) wrap: TTextareaWrap = 'soft';\n\n // Prop lifecycle events\n // =======================\n\n @Watch('value')\n handleValueChange() {\n if (!this.textarea) return;\n if (!this.maxlength || this.value?.length < this.maxlength) return;\n // If the value is longer than the maxlength, we need to truncate it\n this.value = this.value?.substring(0, this.maxlength);\n this.textarea.value = this.value ?? '';\n }\n\n @Watch('required')\n handleRequiredPropChange() {\n this.updateFormValidity();\n }\n\n // Events section\n // Requires JSDocs for public API documentation\n // ==============================================\n\n /** Callback handler emitted when the textarea loses focus */\n @Event() bqBlur!: EventEmitter<HTMLBqTextareaElement>;\n\n /**\n * Callback handler emitted when the textarea value has changed and the textarea loses focus.\n * This handler is called whenever the user finishes typing or pasting text into the textarea field and then clicks outside of the textarea field.\n */\n @Event() bqChange!: EventEmitter<{ value: string; el: HTMLBqTextareaElement }>;\n\n /** Callback handler emitted when the textarea value has been cleared */\n @Event() bqClear!: EventEmitter<HTMLBqTextareaElement>;\n\n /** Callback handler emitted when the textarea has received focus */\n @Event() bqFocus!: EventEmitter<HTMLBqTextareaElement>;\n\n /**\n * Callback handler emitted when the textarea value changes.\n * This handler is called whenever the user types or pastes text into the textarea field.\n */\n @Event() bqInput!: EventEmitter<{ value: string; el: HTMLBqTextareaElement }>;\n\n // Component lifecycle events\n // Ordered by their natural call order\n // =====================================\n\n componentDidLoad() {\n this.handleSlotChange();\n this.handleValueChange();\n }\n\n formAssociatedCallback() {\n this.setFormValue(this.value);\n this.updateFormValidity();\n }\n\n formResetCallback() {\n this.clearSelection();\n // Reset the form validity state\n this.setFormValue();\n this.updateFormValidity();\n }\n\n // Listeners\n // ==============\n\n // Public methods API\n // These methods are exposed on the host element.\n // Always use two lines.\n // Public Methods must be async.\n // Requires JSDocs for public API documentation.\n // ===============================================\n\n // Local methods\n // Internal business logic.\n // These methods cannot be called from the host element.\n // =======================================================\n\n private get numberOfCharacters() {\n if (!this.maxlength || !this.textarea) return 0;\n\n return this.value?.length;\n }\n\n private handleBlur = () => {\n if (this.disabled) return;\n\n this.bqBlur.emit(this.el);\n };\n\n private handleFocus = () => {\n if (this.disabled) return;\n\n this.bqFocus.emit(this.el);\n };\n\n private handleChange = (ev: Event) => {\n if (this.disabled) return;\n\n if (!isHTMLElement(ev.target, 'textarea')) return;\n this.value = ev.target.value;\n this.setFormValue(this.value);\n this.updateFormValidity();\n\n this.bqChange.emit({ value: this.value, el: this.el });\n };\n\n private handleInput = (ev: Event) => {\n if (this.disabled) return;\n\n this.debounceBqInput?.cancel();\n\n if (!isHTMLElement(ev.target, 'textarea')) return;\n this.value = ev.target.value;\n\n this.debounceBqInput = debounce(() => {\n this.bqInput.emit({ value: this.value, el: this.el });\n }, this.debounceTime);\n this.debounceBqInput();\n\n this.autoResize();\n };\n\n private autoResize = () => {\n if (!this.autoGrow) return;\n\n const inputElem = this.textarea;\n if (!inputElem) return;\n\n inputElem.style.height = 'auto';\n inputElem.style.height = `${inputElem.scrollHeight}px`;\n };\n\n private handleSlotChange = () => {\n this.hasLabel = hasSlotContent(this.labelElem);\n this.hasHelperText = hasSlotContent(this.helperTextElem);\n };\n\n private setFormValue = (value?: string) => {\n this.internals.setFormValue(!isNil(value) ? `${value}` : undefined);\n };\n\n private updateFormValidity = () => {\n const { formValidationMessage, internals, required, value, textarea } = this;\n\n // Clear the validity state\n internals?.states.clear();\n\n if (required && (!value || value.trim() === '')) {\n // Set validity state to invalid\n internals?.states.add('invalid');\n internals?.setValidity({ valueMissing: true }, formValidationMessage, textarea);\n return;\n }\n\n // Set validity state to valid if textarea has value or is not required\n internals?.states.add('valid');\n internals?.setValidity({});\n };\n\n private clearSelection = () => {\n this.value = '';\n this.textarea.value = this.value;\n };\n\n // render() function\n // Always the last one in the class.\n // ===================================\n\n render() {\n return (\n <div class=\"bq-textarea flex flex-auto flex-col\" part=\"base\">\n <label\n class={{ 'bq-textarea__label': true, '!hidden': !this.hasLabel }}\n htmlFor={this.name ?? this.fallbackId}\n aria-label={this.name ?? this.fallbackId}\n ref={(label: HTMLLabelElement) => (this.labelElem = label)}\n part=\"label\"\n >\n <slot name=\"label\" onSlotchange={this.handleSlotChange} />\n </label>\n <textarea\n id={this.name ?? this.fallbackId}\n class={{\n 'bq-textarea__input': true,\n 'resize-none': this.disableResize,\n [`validation-${this.validationStatus}`]: true,\n }}\n autocapitalize={this.autocapitalize}\n autocomplete={this.autocomplete}\n autocorrect={this.autocorrect}\n autofocus={this.autofocus}\n disabled={this.disabled}\n form={this.form}\n maxLength={this.maxlength > 0 ? this.maxlength : undefined}\n name={this.name}\n placeholder={this.placeholder}\n readOnly={this.readonly}\n required={this.required}\n rows={this.rows}\n spellcheck={this.spellcheck}\n wrap={this.wrap}\n ref={(elem: HTMLTextAreaElement) => (this.textarea = elem)}\n onBlur={this.handleBlur}\n onChange={this.handleChange}\n onFocus={this.handleFocus}\n onInput={this.handleInput}\n part=\"input\"\n >\n {this.value}\n </textarea>\n <div\n class={{\n 'bq-textarea__helper flex items-center justify-between': true,\n [`validation-${this.validationStatus}`]: true,\n '!hidden': !this.hasHelperText && !this.maxlength,\n }}\n part=\"helper-info\"\n >\n <span\n class=\"bq-textarea__helper--text\"\n ref={(span: HTMLElement) => (this.helperTextElem = span)}\n part=\"helper-text\"\n >\n <slot name=\"helper-text\" onSlotchange={this.handleSlotChange} />\n </span>\n <span\n class={{ 'bq-textarea__helper--counter [fontVariant:tabular-nums]': true, '!hidden': !this.maxlength }}\n part=\"helper-counter\"\n >\n {this.numberOfCharacters ?? 0}/{this.maxlength}\n </span>\n </div>\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;AAAA,MAAM,aAAa,GAAG,45zBAA45zB;;MCwFr6zB,UAAU,GAAA,MAAA;;;;;;;;;;;;;;;;;;AAIb,IAAA,eAAe;IACf,UAAU,GAAG,UAAU;AAEvB,IAAA,cAAc;AACd,IAAA,SAAS;AACT,IAAA,QAAQ;;;AAKG,IAAA,SAAS;;;;;IAOX,aAAa,GAAG,KAAK;IACrB,QAAQ,GAAG,KAAK;;;AAKjC;;;;AAIG;IACsB,cAAc,GAA4B,KAAK;AAExE;;;AAGG;IACsB,YAAY,GAAW,KAAK;AAErD;;;AAGG;IACsB,W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,IAAI,CAAC,aAAa,IAAI,CAAC,IAAI,CAAC,SAAS;aAClD,EACD,IAAI,EAAC,aAAa,EAAA,EAElB,CACE,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,KAAK,EAAC,2BAA2B,EACjC,GAAG,EAAE,CAAC,IAAiB,MAAM,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,EACxD,IAAI,EAAC,aAAa,EAAA,EAElB,CAAM,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,IAAI,EAAC,aAAa,EAAC,YAAY,EAAE,IAAI,CAAC,gBAAgB,EAAA,CAAI,CAC3D,EACP,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,KAAK,EAAE,EAAE,yDAAyD,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC,IAAI,CAAC,SAAS,EAAE,EACtG,IAAI,EAAC,gBAAgB,EAAA,EAEpB,IAAI,CAAC,kBAAkB,IAAI,CAAC,OAAG,IAAI,CAAC,SAAS,CACzC,CACH,CACF;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"bq-textarea.entry.esm.js","sources":["../../packages/beeq/src/components/textarea/scss/bq-textarea.scss?tag=bq-textarea&encapsulation=shadow","../../packages/beeq/src/components/textarea/bq-textarea.tsx"],"sourcesContent":["/* -------------------------------------------------------------------------- */\n/* Textarea styles */\n/* -------------------------------------------------------------------------- */\n\n@import './bq-textarea.variables';\n\n:host {\n @apply block is-full;\n}\n\n/* -------------------------------------------------------------------------- */\n/* Label */\n/* -------------------------------------------------------------------------- */\n\n.bq-textarea__label {\n @apply text-[length:--bq-textarea--label-text-size] text-[color:--bq-textarea--label-text-color] m-be-[--bq-textarea--label-margin-bottom];\n}\n\n/* -------------------------------------------------------------------------- */\n/* Native HTML Textarea control */\n/* -------------------------------------------------------------------------- */\n\n.bq-textarea__input {\n @apply flex-auto resize-y bg-[--bq-textarea--background-color] bs-[inherit];\n // Border\n @apply rounded-[--bq-textarea--border-radius] border-[length:--bq-textarea--border-width] border-[color:--bq-textarea--border-color];\n // Padding\n @apply pe-[--bq-textarea--padding-end] ps-[--bq-textarea--padding-start] p-b-[--bq-textarea--paddingY];\n // Text\n @apply text-[length:--bq-textarea--text-size] text-[color:--bq-textarea--text-color] placeholder:text-[color:--bq-textarea--text-placeholder-color];\n // Transition\n @apply transition-colors ease-in-out;\n // Hover\n @apply [&:not([disabled]):not(:focus-within)]:hover:border-hover-brand;\n // Disabled\n @apply disabled:cursor-not-allowed disabled:opacity-60;\n // Focus\n &:not([disabled]):focus-within {\n --bq-ring-width: 1px;\n --bq-ring-offset-width: 0;\n --bq-ring-color-focus: var(--bq-textarea--border-color-focus);\n\n @apply focus border-[color:--bq-ring-color-focus];\n }\n}\n\n/* ------------------------------- Validations ------------------------------- */\n\n.bq-textarea__input.validation-error {\n @apply border-danger [&:not(.disabled):not(:focus-within)]:hover:border-hover-danger;\n\n &:not(.disabled):focus-within {\n --bq-ring-color-focus: theme(stroke.danger);\n\n @apply border-active-danger;\n }\n}\n\n.bq-textarea__input.validation-success {\n @apply border-success [&:not(.disabled):not(:focus-within)]:hover:border-hover-success;\n\n &:not(.disabled):focus-within {\n --bq-ring-color-focus: theme(stroke.success);\n\n @apply border-active-success;\n }\n}\n\n.bq-textarea__input.validation-warning {\n @apply border-warning [&:not(.disabled):not(:focus-within)]:hover:border-hover-warning;\n\n &:not(.disabled):focus-within {\n --bq-ring-color-focus: theme(stroke.warning);\n\n @apply border-active-warning;\n }\n}\n\n/* -------------------------------------------------------------------------- */\n/* Helper text */\n/* -------------------------------------------------------------------------- */\n\n.bq-textarea__helper {\n @apply text-[length:--bq-textarea--helper-text-size] text-[color:--bq-textarea--helper-text-color] m-bs-[--bq-textarea--helper-margin-top];\n}\n\n/* ------------------------------- Validations ------------------------------ */\n\n.bq-textarea__helper.validation-error {\n @apply text-danger;\n}\n\n.bq-textarea__helper.validation-success {\n @apply text-success;\n}\n\n.bq-textarea__helper.validation-warning {\n @apply text-warning;\n}\n\n/* ----------------------------- Helper counter ----------------------------- */\n\n/** Apply a disabled text color style to the textarea counter when the validation is none. */\n.bq-textarea__helper[class~='validation-none'] {\n .bq-textarea__helper--counter {\n @apply opacity-60;\n }\n}\n","import { AttachInternals, Component, Element, Event, h, Prop, State, Watch } from '@stencil/core';\nimport type { EventEmitter } from '@stencil/core';\n\nimport type { TTextareaAutoCapitalize, TTextareaWrap } from './bq-textarea.types';\nimport { debounce, hasSlotContent, isHTMLElement, isNil, TDebounce } from '../../shared/utils';\nimport type { TInputValidation } from '../input/bq-input.types';\n\n/**\n * The Textarea component is a multi-line text input control that is often used in a form to collect user inputs like comments or reviews.\n *\n * @example How to use it\n * ```html\n * <bq-textarea maxlength=\"0\" name=\"textarea\" placeholder=\"Placeholder...\" rows=\"5\">\n * <label slot=\"label\">Label</label>\n * <span class=\"flex items-center gap-xs\" slot=\"helper-text\">\n * <bq-icon name=\"star\"></bq-icon>\n * Helper text\n * </span>\n * </bq-textarea>\n * ```\n *\n * @documentation https://www.beeq.design/3d466e231/p/16792c-textarea\n * @status stable\n *\n * @attr {string} autocapitalize - Controls whether or not the textarea field should be capitalized and how.\n * @attr {string} autocomplete - Specifies whether or not the textarea field should have autocomplete enabled.\n * @attr {string} autocorrect - Controls whether or not the textarea field should have autocorrect enabled.\n * @attr {boolean} autofocus - If `true`, the textarea will be focused on component render.\n * @attr {boolean} auto-grow - If `true`, the textarea will automatically grow and shrink to fit its contents.\n * @attr {number} debounce-time - The amount of time, in milliseconds, to wait before emitting the `bqInput` event after the textarea value changes.\n * @attr {boolean} disabled - If `true`, the user cannot interact with the textarea.\n * @attr {boolean} disable-resize - If `true`, it will block the user's ability to resize the textarea.\n * @attr {string} form - The ID of the form that the textarea field belongs to.\n * @attr {string} form-validation-message - The native form validation message.\n * @attr {number} maxlength - The maximum number of characters that can be entered into the textarea (`0`: no limit).\n * @attr {string} name - The name of the textarea element.\n * @attr {string} placeholder - The placeholder text to show when there is no value.\n * @attr {boolean} readonly - If `true`, the textarea field cannot be modified.\n * @attr {boolean} required - Indicates whether or not the textarea field is required to be filled out before submitting the form.\n * @attr {number} rows - The number of visible text lines for the control. It must be a positive integer.\n * @attr {boolean} spellcheck - If `true`, the textarea content may be checked for spelling errors.\n * @attr {\"error\" | \"none\" | \"success\" | \"warning\"} validation-status - The validation status of the textarea.\n * @attr {string} value - The value of the textarea. It can be used to reset the textarea to a previous value.\n * @attr {\"soft\" | \"hard\"} wrap - Specifies how the text in a text area is to be wrapped when submitted in a form.\n *\n * @event bqBlur - Handler to be called when the textarea loses focus.\n * @event bqChange - Handler to be called when the textarea value has changed and the textarea loses focus.\n * @event bqClear - Handler to be called when the textarea value has been cleared.\n * @event bqFocus - Handler to be called when the textarea has received focus.\n * @event bqInput - Handler to be called when the textarea value changes.\n *\n * @slot label - The textarea label.\n * @slot helper-text - The helper text.\n *\n * @part base - The component's base wrapper.\n * @part input - The textarea element.\n * @part label - The textarea label.\n * @part helper-info - The helper info container.\n * @part helper-text - The helper text.\n * @part helper-counter - The helper counter.\n *\n * @cssprop --bq-textarea--background-color - Textarea background color\n * @cssprop --bq-textarea--border-color - Textarea border color\n * @cssprop --bq-textarea--border-color-focus - Textarea border color on focus\n * @cssprop --bq-textarea--border-radius - Textarea border radius\n * @cssprop --bq-textarea--border-width - Textarea border width\n * @cssprop --bq-textarea--border-style - Textarea border style\n * @cssprop --bq-textarea--helper-margin-top - Textarea helper text margin top\n * @cssprop --bq-textarea--helper-text-color - Textarea helper text color\n * @cssprop --bq-textarea--helper-text-size - Textarea helper text size\n * @cssprop --bq-textarea--label-margin-bottom - Textarea label margin bottom\n * @cssprop --bq-textarea--label-text-color - Textarea label text color\n * @cssprop --bq-textarea--label-text-size - Textarea label text size\n * @cssprop --bq-textarea--paddingY - Textarea padding top and bottom\n * @cssprop --bq-textarea--padding-start - Textarea padding start\n * @cssprop --bq-textarea--padding-end - Textarea padding end\n * @cssprop --bq-textarea--text-color - Textarea text color\n * @cssprop --bq-textarea--text-size - Textarea text size\n * @cssprop --bq-textarea--text-placeholder-color - Textarea placeholder text color\n */\n@Component({\n tag: 'bq-textarea',\n styleUrl: './scss/bq-textarea.scss',\n formAssociated: true,\n shadow: {\n delegatesFocus: true,\n },\n})\nexport class BqTextarea {\n // Own Properties\n // ====================\n\n private debounceBqInput: TDebounce<void>;\n private fallbackId = 'textarea';\n\n private helperTextElem?: HTMLElement;\n private labelElem?: HTMLLabelElement;\n private textarea: HTMLTextAreaElement;\n\n // Reference to host HTML element\n // ===================================\n\n @AttachInternals() internals!: ElementInternals;\n @Element() el!: HTMLBqTextareaElement;\n\n // State() variables\n // Inlined decorator, alphabetical order\n // =======================================\n\n @State() private hasHelperText = false;\n @State() private hasLabel = false;\n\n // Public Property API\n // ========================\n\n /**\n * Controls whether or not the textarea field should be capitalized and how.\n * Possible values are 'off', 'none', 'on', 'sentences', 'words', and 'characters'.\n * See: https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/autocapitalize\n */\n @Prop({ reflect: true }) autocapitalize: TTextareaAutoCapitalize = 'off';\n\n /**\n * Specifies whether or not the textarea field should have autocomplete enabled.\n * See: https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete#values\n */\n @Prop({ reflect: true }) autocomplete: string = 'off';\n\n /**\n * Controls whether or not the textarea field should have autocorrect enabled.\n * Possible values are 'on' and 'off'.\n */\n @Prop({ reflect: true }) autocorrect: 'on' | 'off' = 'off';\n\n /** If true, the textarea will be focused on component render */\n @Prop({ reflect: true }) autofocus: boolean;\n\n /**\n * If `true`, the textarea will automatically grow and shrink to fit its contents.\n * If `false`, the textarea will have a fixed height specified by the `rows` property.\n */\n @Prop({ reflect: true }) autoGrow: boolean = false;\n\n /**\n * The amount of time, in milliseconds, to wait before emitting the `bqInput` event after the textarea value changes.\n * A value of 0 means no debouncing will occur.\n */\n @Prop({ reflect: true, mutable: true }) debounceTime? = 0;\n\n /** If `true`, the user cannot interact with the textarea. */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /** If `true`, it will block the user's ability to resize the textarea. */\n @Prop({ reflect: true }) disableResize?: boolean = false;\n\n /** The ID of the form that the textarea field belongs to. */\n @Prop({ reflect: true }) form?: string;\n\n /** The native form validation message */\n @Prop({ mutable: true }) formValidationMessage?: string;\n\n /**\n * The maximum number of characters that can be entered into the textarea (`0`: no limit).\n * When enabled, a character counter will be shown underneath the textarea.\n */\n @Prop({ reflect: true }) maxlength: number;\n\n /** The name of the textarea element. */\n @Prop({ reflect: true }) name!: string;\n\n /** The placeholder text to show when there is no value. */\n @Prop({ reflect: true }) placeholder!: string;\n\n /** If true, the textarea field cannot be modified. */\n @Prop({ reflect: true }) readonly?: boolean = false;\n\n /** Indicates whether or not the textarea field is required to be filled out before submitting the form. */\n @Prop({ reflect: true }) required?: boolean = false;\n\n /** The number of visible text lines for the control. It must be a positive integer. */\n @Prop({ reflect: true }) rows: number = 5;\n\n /** If true, the textarea content may be checked for spelling errors. */\n @Prop({ reflect: true }) spellcheck: boolean = false;\n /**\n * The validation status of the textarea.\n *\n * @remarks\n * This property is used to indicate the validation status of the textarea. It can be set to one of the following values:\n * - `'none'`: No validation status is set.\n * - `'error'`: The textarea has a validation error.\n * - `'warning'`: The textarea has a validation warning.\n * - `'success'`: The textarea has passed validation.\n */\n @Prop({ reflect: true, mutable: true }) validationStatus: TInputValidation = 'none';\n\n /** The value of the textarea. It can be used to reset the textarea to a previous value. */\n @Prop({ mutable: true }) value: string;\n\n /** Specifies how the text in a text area is to be wrapped when submitted in a form */\n @Prop({ reflect: true }) wrap: TTextareaWrap = 'soft';\n\n // Prop lifecycle events\n // =======================\n\n @Watch('value')\n handleValueChange() {\n if (!this.textarea) return;\n if (!this.maxlength || this.value?.length < this.maxlength) return;\n // If the value is longer than the maxlength, we need to truncate it\n this.value = this.value?.substring(0, this.maxlength);\n this.textarea.value = this.value ?? '';\n }\n\n @Watch('required')\n handleRequiredPropChange() {\n this.updateFormValidity();\n }\n\n // Events section\n // Requires JSDocs for public API documentation\n // ==============================================\n\n /** Callback handler emitted when the textarea loses focus */\n @Event() bqBlur!: EventEmitter<HTMLBqTextareaElement>;\n\n /**\n * Callback handler emitted when the textarea value has changed and the textarea loses focus.\n * This handler is called whenever the user finishes typing or pasting text into the textarea field and then clicks outside of the textarea field.\n */\n @Event() bqChange!: EventEmitter<{ value: string; el: HTMLBqTextareaElement }>;\n\n /** Callback handler emitted when the textarea value has been cleared */\n @Event() bqClear!: EventEmitter<HTMLBqTextareaElement>;\n\n /** Callback handler emitted when the textarea has received focus */\n @Event() bqFocus!: EventEmitter<HTMLBqTextareaElement>;\n\n /**\n * Callback handler emitted when the textarea value changes.\n * This handler is called whenever the user types or pastes text into the textarea field.\n */\n @Event() bqInput!: EventEmitter<{ value: string; el: HTMLBqTextareaElement }>;\n\n // Component lifecycle events\n // Ordered by their natural call order\n // =====================================\n\n componentDidLoad() {\n this.handleSlotChange();\n this.handleValueChange();\n }\n\n formAssociatedCallback() {\n this.setFormValue(this.value);\n this.updateFormValidity();\n }\n\n formResetCallback() {\n this.clearSelection();\n // Reset the form validity state\n this.setFormValue();\n this.updateFormValidity();\n }\n\n // Listeners\n // ==============\n\n // Public methods API\n // These methods are exposed on the host element.\n // Always use two lines.\n // Public Methods must be async.\n // Requires JSDocs for public API documentation.\n // ===============================================\n\n // Local methods\n // Internal business logic.\n // These methods cannot be called from the host element.\n // =======================================================\n\n private get numberOfCharacters() {\n if (!this.maxlength || !this.textarea) return 0;\n\n return this.value?.length;\n }\n\n private handleBlur = () => {\n if (this.disabled) return;\n\n this.bqBlur.emit(this.el);\n };\n\n private handleFocus = () => {\n if (this.disabled) return;\n\n this.bqFocus.emit(this.el);\n };\n\n private handleChange = (ev: Event) => {\n if (this.disabled) return;\n\n if (!isHTMLElement(ev.target, 'textarea')) return;\n this.value = ev.target.value;\n this.setFormValue(this.value);\n this.updateFormValidity();\n\n this.bqChange.emit({ value: this.value, el: this.el });\n };\n\n private handleInput = (ev: Event) => {\n if (this.disabled) return;\n\n this.debounceBqInput?.cancel();\n\n if (!isHTMLElement(ev.target, 'textarea')) return;\n this.value = ev.target.value;\n\n this.debounceBqInput = debounce(() => {\n this.bqInput.emit({ value: this.value, el: this.el });\n }, this.debounceTime);\n this.debounceBqInput();\n\n this.autoResize();\n };\n\n private autoResize = () => {\n if (!this.autoGrow) return;\n\n const inputElem = this.textarea;\n if (!inputElem) return;\n\n inputElem.style.height = 'auto';\n inputElem.style.height = `${inputElem.scrollHeight}px`;\n };\n\n private handleSlotChange = () => {\n this.hasLabel = hasSlotContent(this.labelElem);\n this.hasHelperText = hasSlotContent(this.helperTextElem);\n };\n\n private setFormValue = (value?: string) => {\n this.internals.setFormValue(!isNil(value) ? `${value}` : undefined);\n };\n\n private updateFormValidity = () => {\n const { formValidationMessage, internals, required, value, textarea } = this;\n\n // Clear the validity state\n internals?.states.clear();\n\n if (required && (!value || value.trim() === '')) {\n // Set validity state to invalid\n internals?.states.add('invalid');\n internals?.setValidity({ valueMissing: true }, formValidationMessage, textarea);\n return;\n }\n\n // Set validity state to valid if textarea has value or is not required\n internals?.states.add('valid');\n internals?.setValidity({});\n };\n\n private clearSelection = () => {\n this.value = '';\n this.textarea.value = this.value;\n };\n\n // render() function\n // Always the last one in the class.\n // ===================================\n\n render() {\n return (\n <div class=\"bq-textarea flex flex-auto flex-col\" part=\"base\">\n <label\n class={{ 'bq-textarea__label': true, '!hidden': !this.hasLabel }}\n htmlFor={this.name ?? this.fallbackId}\n aria-label={this.name ?? this.fallbackId}\n ref={(label: HTMLLabelElement) => (this.labelElem = label)}\n part=\"label\"\n >\n <slot name=\"label\" onSlotchange={this.handleSlotChange} />\n </label>\n <textarea\n id={this.name ?? this.fallbackId}\n class={{\n 'bq-textarea__input': true,\n 'resize-none': this.disableResize,\n [`validation-${this.validationStatus}`]: true,\n }}\n autocapitalize={this.autocapitalize}\n autocomplete={this.autocomplete}\n autocorrect={this.autocorrect}\n autofocus={this.autofocus}\n disabled={this.disabled}\n form={this.form}\n maxLength={this.maxlength > 0 ? this.maxlength : undefined}\n name={this.name}\n placeholder={this.placeholder}\n readOnly={this.readonly}\n required={this.required}\n rows={this.rows}\n spellcheck={this.spellcheck}\n wrap={this.wrap}\n ref={(elem: HTMLTextAreaElement) => (this.textarea = elem)}\n onBlur={this.handleBlur}\n onChange={this.handleChange}\n onFocus={this.handleFocus}\n onInput={this.handleInput}\n part=\"input\"\n >\n {this.value}\n </textarea>\n <div\n class={{\n 'bq-textarea__helper flex items-center justify-between': true,\n [`validation-${this.validationStatus}`]: true,\n '!hidden': !this.hasHelperText && !this.maxlength,\n }}\n part=\"helper-info\"\n >\n <span\n class=\"bq-textarea__helper--text\"\n ref={(span: HTMLElement) => (this.helperTextElem = span)}\n part=\"helper-text\"\n >\n <slot name=\"helper-text\" onSlotchange={this.handleSlotChange} />\n </span>\n <span\n class={{ 'bq-textarea__helper--counter [fontVariant:tabular-nums]': true, '!hidden': !this.maxlength }}\n part=\"helper-counter\"\n >\n {this.numberOfCharacters ?? 0}/{this.maxlength}\n </span>\n </div>\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;AAAA,MAAM,aAAa,GAAG,2h0BAA2h0B;;MCwFpi0B,UAAU,GAAA,MAAA;;;;;;;;;;;;;;;;;;AAIb,IAAA,eAAe;IACf,UAAU,GAAG,UAAU;AAEvB,IAAA,cAAc;AACd,IAAA,SAAS;AACT,IAAA,QAAQ;;;AAKG,IAAA,SAAS;;;;;IAOX,aAAa,GAAG,KAAK;IACrB,QAAQ,GAAG,KAAK;;;AAKjC;;;;AAIG;IACsB,cAAc,GAA4B,KAAK;AAExE;;;AAGG;IACsB,YAAY,GAAW,KAAK;AAErD;;;AAGG;IACsB,WAAW,GAAiB,KAAK;;AAGjC,IAAA,SAAS;AAElC;;;AAGG;IACsB,QAAQ,GAAY,KAAK;AAElD;;;AAGG;IACqC,YAAY,GAAI,CAAC;;IAGhC,QAAQ,GAAY,KAAK;;IAGzB,aAAa,GAAa,KAAK;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GAAG,EAAE,CAAC,IAAiB,MAAM,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,EACxD,IAAI,EAAC,aAAa,EAAA,EAElB,CAAM,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,IAAI,EAAC,aAAa,EAAC,YAAY,EAAE,IAAI,CAAC,gBAAgB,EAAA,CAAI,CAC3D,EACP,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,KAAK,EAAE,EAAE,yDAAyD,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC,IAAI,CAAC,SAAS,EAAE,EACtG,IAAI,EAAC,gBAAgB,EAAA,EAEpB,IAAI,CAAC,kBAAkB,IAAI,CAAC,OAAG,IAAI,CAAC,SAAS,CACzC,CACH,CACF;;;;;;;;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bq-toast.entry.esm.js","sources":["../../packages/beeq/src/components/toast/bq-toast.types.ts","../../packages/beeq/src/components/toast/scss/bq-toast.scss?tag=bq-toast&encapsulation=shadow","../../packages/beeq/src/components/toast/bq-toast.tsx"],"sourcesContent":["export const TOAST_TYPE = ['info', 'success', 'alert', 'error', 'loading', 'custom'] as const;\nexport type TToastType = (typeof TOAST_TYPE)[number];\n\nexport const TOAST_PLACEMENT = [\n 'top-center',\n 'top-right',\n 'bottom-right',\n 'bottom-center',\n 'bottom-left',\n 'top-left',\n] as const;\nexport type TToastPlacement = (typeof TOAST_PLACEMENT)[number];\n\nexport const TOAST_BORDER_RADIUS = ['none', 'xs2', 'xs', 's', 'm', 'l', 'full'] as const;\nexport type TToastBorderRadius = (typeof TOAST_BORDER_RADIUS)[number];\n","/* -------------------------------------------------------------------------- */\n/* Toast styles */\n/* -------------------------------------------------------------------------- */\n\n@import './bq-toast.variables';\n\n:host {\n @apply inline-block;\n}\n\n:host(.is-hidden) {\n @apply hidden;\n}\n\n.bq-toast {\n @include animation-slide-in;\n @apply flex items-center gap-[--bq-toast--gap] p-b-[--bq-toast--padding-y] p-i-[--bq-toast--padding-x];\n @apply rounded-[--bq-toast--border-radius] bg-[--bq-toast--background] shadow-[shadow:--bq-toast--box-shadow];\n @apply border-[length:--bq-toast--border-width] border-[color:--bq-toast--border-color];\n\n border-style: var(--bq-toast--border-style);\n}\n\n.bq-toast--icon {\n @apply flex;\n\n &.info {\n @apply text-[--bq-toast--icon-color-info];\n }\n\n &.success {\n @apply text-[--bq-toast--icon-color-success];\n }\n\n &.alert {\n @apply text-[--bq-toast--icon-color-alert];\n }\n\n &.error {\n @apply text-[--bq-toast--icon-color-error];\n }\n\n &.loading {\n @include animation-spin;\n @apply text-[--bq-toast--icon-color-loading];\n }\n\n &.custom {\n @apply text-[--bq-toast--icon-color-custom];\n }\n}\n","import { Component, Element, Event, h, Host, Listen, Method, Prop, State, Watch } from '@stencil/core';\nimport type { EventEmitter } from '@stencil/core';\n\nimport { TOAST_PLACEMENT, TOAST_TYPE } from './bq-toast.types';\nimport type { TToastBorderRadius, TToastPlacement, TToastType } from './bq-toast.types';\nimport { debounce, isClient, TDebounce, validatePropValue } from '../../shared/utils';\n\nconst TOAST_PORTAL_SELECTOR = 'bq-toast-portal';\n\n/**\n * Toasts are time-based components used to display short messages.\n * Commonly used for errors, confirmations, or progress updates.\n *\n * @example How to use it\n * ```html\n * <bq-toast type=\"info\">\n * This is a message\n * </bq-toast>\n * ```\n *\n * @documentation https://www.beeq.design/3d466e231/p/83da51-toast\n * @status stable\n *\n * @dependency bq-icon\n *\n * @attr {\"s\" | \"none\" | \"xs2\" | \"xs\" | \"m\" | \"l\" | \"full\"} border - The corder radius of the toast component\n * @attr {\"success\" | \"error\" | \"loading\" | \"alert\" | \"info\"} type - Type of toast\n * @attr {\"top-left\" | \"top-center\" | \"top-right\" | \"bottom-left\" | \"bottom-center\" | \"bottom-right\"} placement - Placement of toast\n * @attr {boolean} hide-icon - If true will hide toast icon\n * @attr {boolean} open - If true, the toast will be shown\n * @attr {number} time - The length of time, in milliseconds, after which the toast will close itself\n *\n * @method show - Method to be called to show the toast component\n * @method hide - Method to be called to hide the toast component\n * @method toast - This method can be used to display toasts in a fixed-position element that allows for stacking multiple toasts vertically\n *\n * @event bqHide - Callback handler to be called when the notification is hidden\n * @event bqShow - Callback handler to be called when the notification is shown\n *\n * @slot - The content to be displayed in the toast component.\n * @slot icon - The icon to be displayed in the toast component.\n *\n * @part wrapper - The component's internal wrapper inside the shadow DOM.\n * @part icon-info - The `<div>` container that holds the icon component.\n * @part base - The `<div>` container of the internal bq-icon component.\n * @part svg - The `<svg>` element of the internal bq-icon component.\n *\n * @cssprop --bq-toast--background - Toast background color\n * @cssprop --bq-toast--box-shadow - Toast box shadow\n * @cssprop --bq-toast--padding-y - Toast vertical padding\n * @cssprop --bq-toast--padding-x - Toast horizontal padding\n * @cssprop --bq-toast--gap - Toast distance between icon and text\n * @cssprop --bq-toast--border-radius - Toast border radius\n * @cssprop --bq-toast--border-color - Toast border color\n * @cssprop --bq-toast--border-style - Toast border style\n * @cssprop --bq-toast--border-width - Toast border width\n * @cssprop --bq-toast--icon-color-info - Toast icon color when type is 'info'\n * @cssprop --bq-toast--icon-color-success - Toast icon color when type is 'success'\n * @cssprop --bq-toast--icon-color-alert - Toast icon color when type is 'alert'\n * @cssprop --bq-toast--icon-color-error - Toast icon color when type is 'error'\n * @cssprop --bq-toast--icon-color-loading - Toast icon color when type is 'loading'\n * @cssprop --bq-toast--icon-color-custom - Toast icon color when type is 'custom'\n */\n@Component({\n tag: 'bq-toast',\n styleUrl: './scss/bq-toast.scss',\n shadow: true,\n})\nexport class BqToast {\n // Own Properties\n // ====================\n\n private autoDismissDebounce: TDebounce<void>;\n\n // Reference to host HTML element\n // ===================================\n\n @Element() el!: HTMLBqToastElement;\n\n // State() variables\n // Inlined decorator, alphabetical order\n // =======================================\n\n @State() private toastPortal = isClient() ? document.querySelector(`.${TOAST_PORTAL_SELECTOR}`) : null;\n\n // Public Property API\n // ========================\n\n /** The corder radius of the toast component */\n @Prop({ reflect: true }) border: TToastBorderRadius = 's';\n\n /** Type of toast */\n @Prop({ reflect: true, mutable: true }) type: TToastType = 'info';\n\n /** Placement of toast */\n @Prop({ reflect: true, mutable: true }) placement: TToastPlacement = 'bottom-center';\n\n /** If true will hide toast icon */\n @Prop({ reflect: true, mutable: true }) hideIcon = false;\n\n /** If true, the toast will be shown */\n @Prop({ reflect: true, mutable: true }) open: boolean;\n\n /** The length of time, in milliseconds, after which the toast will close itself */\n @Prop({ reflect: true }) time: number = 3000;\n\n // Prop lifecycle events\n // =======================\n\n @Watch('type')\n @Watch('placement')\n checkPropValues() {\n validatePropValue(TOAST_TYPE, 'default', this.el, 'type');\n validatePropValue(TOAST_PLACEMENT, 'bottom-center', this.el, 'placement');\n\n const { toastPortal } = this;\n toastPortal?.classList.remove(...TOAST_PLACEMENT);\n toastPortal?.classList.add(this.placement);\n }\n\n @Watch('time')\n handleTimeChange() {\n this.autoDismissDebounce?.cancel();\n\n this.time = Math.max(0, this.time);\n\n this.autoDismissDebounce = debounce(() => {\n this.hide();\n }, this.time);\n }\n\n @Watch('open')\n handleOpenChange() {\n this.autoDismissDebounce?.cancel();\n\n if (this.open) {\n this.autoDismissDebounce?.();\n }\n }\n\n // Events section\n // Requires JSDocs for public API documentation\n // ==============================================\n\n /** Callback handler to be called when the notification is hidden */\n @Event() bqHide: EventEmitter<HTMLBqToastElement>;\n\n /** Callback handler to be called when the notification is shown */\n @Event() bqShow: EventEmitter<HTMLBqToastElement>;\n\n // Component lifecycle events\n // Ordered by their natural call order\n // =====================================\n\n connectedCallback() {\n if (!isClient()) return;\n\n const { toastPortal } = this;\n if (!toastPortal) {\n this.toastPortal = Object.assign(document.createElement('div'), { className: TOAST_PORTAL_SELECTOR });\n }\n }\n\n componentWillLoad() {\n this.checkPropValues();\n this.handleTimeChange();\n this.handleOpenChange();\n }\n\n disconnectedCallback() {\n this.autoDismissDebounce?.cancel();\n }\n\n // Listeners\n // ==============\n\n @Listen('bqHide')\n onNotificationHide() {\n try {\n const { toastPortal } = this;\n toastPortal?.removeChild(this.el);\n // Remove the toast portal from the DOM when there are no more toasts\n if (toastPortal?.querySelector(this.el.tagName.toLowerCase()) === null) {\n toastPortal?.remove();\n }\n } catch (error) {\n /**\n * Skip DOMException error since it could be possible that\n * in some situations the notification portal is missing\n */\n if (error instanceof DOMException) return;\n throw error;\n }\n }\n\n // Public methods API\n // These methods are exposed on the host element.\n // Always use two lines.\n // Public Methods must be async.\n // Requires JSDocs for public API documentation.\n // ===============================================\n\n /** Method to be called to show the toast component */\n @Method()\n async show(): Promise<void> {\n this.handleShow();\n }\n\n /** Method to be called to hide the toast component */\n @Method()\n async hide(): Promise<void> {\n this.handleHide();\n }\n\n /** This method can be used to display toasts in a fixed-position element that allows for stacking multiple toasts vertically */\n @Method()\n async toast() {\n if (!isClient()) return;\n\n const { toastPortal } = this;\n if (toastPortal?.parentElement === null) {\n document.body.append(toastPortal);\n }\n\n toastPortal?.appendChild(this.el);\n\n requestAnimationFrame(() => {\n this.show();\n });\n }\n\n // Local methods\n // Internal business logic.\n // These methods cannot be called from the host element.\n // =======================================================\n\n private handleShow = () => {\n const ev = this.bqShow.emit(this.el);\n if (!ev.defaultPrevented) {\n this.open = true;\n }\n };\n\n private handleHide = () => {\n const ev = this.bqHide.emit(this.el);\n if (!ev.defaultPrevented) {\n this.open = false;\n }\n };\n\n private get iconName() {\n const typeMap = {\n success: 'check-circle-bold',\n error: 'x-circle-bold',\n loading: 'spinner-gap-bold',\n alert: 'warning-bold',\n info: 'info-bold',\n };\n\n return typeMap[this.type] || 'info-bold';\n }\n\n // render() function\n // Always the last one in the class.\n // ===================================\n\n render() {\n const style = {\n ...(this.border && { '--bq-toast--border-radius': `var(--bq-radius--${this.border})` }),\n };\n\n return (\n <Host\n style={style}\n class={{ 'is-hidden': !this.open }}\n aria-hidden={!this.open ? 'true' : 'false'}\n hidden={!this.open ? 'true' : 'false'}\n role=\"status\"\n >\n <output class=\"bq-toast\" part=\"wrapper\">\n <div class={{ [`bq-toast--icon ${this.type}`]: true, '!hidden': this.hideIcon }} part=\"icon\">\n <slot name=\"icon\">\n <bq-icon name={this.iconName} size=\"24\" slot=\"icon\" exportparts=\"base,svg\" />\n </slot>\n </div>\n <slot />\n </output>\n </Host>\n );\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;AAAO,MAAM,UAAU,GAAG,CAAC,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,OAAO,EAAE,SAAS,EAAE,QAAQ,CAAU;AAGtF,MAAM,eAAe,GAAG;IAC7B,YAAY;IACZ,WAAW;IACX,cAAc;IACd,eAAe;IACf,aAAa;IACb,UAAU;CACF;;ACVV,MAAM,UAAU,GAAG,ylsBAAylsB;;ACO5msB,MAAM,qBAAqB,GAAG,iBAAiB;MA6DlC,OAAO,GAAA,MAAA;;;;;;;;AAIV,IAAA,mBAAmB;;;;;AAWV,IAAA,WAAW,GAAG,QAAQ,EAAE,GAAG,QAAQ,CAAC,aAAa,CAAC,CAAA,CAAA,EAAI,qBAAqB,CAAE,CAAA,CAAC,GAAG,IAAI;;;;IAM7E,MAAM,GAAuB,GAAG;;IAGjB,IAAI,GAAe,MAAM;;IAGzB,SAAS,GAAoB,eAAe;;IAG5C,QAAQ,GAAG,KAAK;;AAGhB,IAAA,IAAI;;IAGnB,IAAI,GAAW,IAAI;;;IAO5C,eAAe,GAAA;QACb,iBAAiB,CAAC,UAAU,EAAE,SAAS,EAAE,IAAI,CAAC,EAAE,EAAE,MAAM,CAAC;QACzD,iBAAiB,CAAC,eAAe,EAAE,eAAe,EAAE,IAAI,CAAC,EAAE,EAAE,WAAW,CAAC;AAEzE,QAAA,MAAM,EAAE,WAAW,EAAE,GAAG,IAAI;QAC5B,WAAW,EAAE,SAAS,CAAC,MAAM,CAAC,GAAG,eAAe,CAAC;QACjD,WAAW,EAAE,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,SAAS,CAAC;;IAI5C,gBAAgB,GAAA;AACd,QAAA,IAAI,CAAC,mB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,EAAA,0CAAA,EAAA,CAAA,CACD,CACJ;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"bq-toast.entry.esm.js","sources":["../../packages/beeq/src/components/toast/bq-toast.types.ts","../../packages/beeq/src/components/toast/scss/bq-toast.scss?tag=bq-toast&encapsulation=shadow","../../packages/beeq/src/components/toast/bq-toast.tsx"],"sourcesContent":["export const TOAST_TYPE = ['info', 'success', 'alert', 'error', 'loading', 'custom'] as const;\nexport type TToastType = (typeof TOAST_TYPE)[number];\n\nexport const TOAST_PLACEMENT = [\n 'top-center',\n 'top-right',\n 'bottom-right',\n 'bottom-center',\n 'bottom-left',\n 'top-left',\n] as const;\nexport type TToastPlacement = (typeof TOAST_PLACEMENT)[number];\n\nexport const TOAST_BORDER_RADIUS = ['none', 'xs2', 'xs', 's', 'm', 'l', 'full'] as const;\nexport type TToastBorderRadius = (typeof TOAST_BORDER_RADIUS)[number];\n","/* -------------------------------------------------------------------------- */\n/* Toast styles */\n/* -------------------------------------------------------------------------- */\n\n@import './bq-toast.variables';\n\n:host {\n @apply inline-block;\n}\n\n:host(.is-hidden) {\n @apply hidden;\n}\n\n.bq-toast {\n @include animation-slide-in;\n @apply flex items-center gap-[--bq-toast--gap] p-b-[--bq-toast--padding-y] p-i-[--bq-toast--padding-x];\n @apply rounded-[--bq-toast--border-radius] bg-[--bq-toast--background] shadow-[shadow:--bq-toast--box-shadow];\n @apply border-[length:--bq-toast--border-width] border-[color:--bq-toast--border-color];\n\n border-style: var(--bq-toast--border-style);\n}\n\n.bq-toast--icon {\n @apply flex;\n\n &.info {\n @apply text-[--bq-toast--icon-color-info];\n }\n\n &.success {\n @apply text-[--bq-toast--icon-color-success];\n }\n\n &.alert {\n @apply text-[--bq-toast--icon-color-alert];\n }\n\n &.error {\n @apply text-[--bq-toast--icon-color-error];\n }\n\n &.loading {\n @include animation-spin;\n @apply text-[--bq-toast--icon-color-loading];\n }\n\n &.custom {\n @apply text-[--bq-toast--icon-color-custom];\n }\n}\n","import { Component, Element, Event, h, Host, Listen, Method, Prop, State, Watch } from '@stencil/core';\nimport type { EventEmitter } from '@stencil/core';\n\nimport { TOAST_PLACEMENT, TOAST_TYPE } from './bq-toast.types';\nimport type { TToastBorderRadius, TToastPlacement, TToastType } from './bq-toast.types';\nimport { debounce, isClient, TDebounce, validatePropValue } from '../../shared/utils';\n\nconst TOAST_PORTAL_SELECTOR = 'bq-toast-portal';\n\n/**\n * Toasts are time-based components used to display short messages.\n * Commonly used for errors, confirmations, or progress updates.\n *\n * @example How to use it\n * ```html\n * <bq-toast type=\"info\">\n * This is a message\n * </bq-toast>\n * ```\n *\n * @documentation https://www.beeq.design/3d466e231/p/83da51-toast\n * @status stable\n *\n * @dependency bq-icon\n *\n * @attr {\"s\" | \"none\" | \"xs2\" | \"xs\" | \"m\" | \"l\" | \"full\"} border - The corder radius of the toast component\n * @attr {\"success\" | \"error\" | \"loading\" | \"alert\" | \"info\"} type - Type of toast\n * @attr {\"top-left\" | \"top-center\" | \"top-right\" | \"bottom-left\" | \"bottom-center\" | \"bottom-right\"} placement - Placement of toast\n * @attr {boolean} hide-icon - If true will hide toast icon\n * @attr {boolean} open - If true, the toast will be shown\n * @attr {number} time - The length of time, in milliseconds, after which the toast will close itself\n *\n * @method show - Method to be called to show the toast component\n * @method hide - Method to be called to hide the toast component\n * @method toast - This method can be used to display toasts in a fixed-position element that allows for stacking multiple toasts vertically\n *\n * @event bqHide - Callback handler to be called when the notification is hidden\n * @event bqShow - Callback handler to be called when the notification is shown\n *\n * @slot - The content to be displayed in the toast component.\n * @slot icon - The icon to be displayed in the toast component.\n *\n * @part wrapper - The component's internal wrapper inside the shadow DOM.\n * @part icon-info - The `<div>` container that holds the icon component.\n * @part base - The `<div>` container of the internal bq-icon component.\n * @part svg - The `<svg>` element of the internal bq-icon component.\n *\n * @cssprop --bq-toast--background - Toast background color\n * @cssprop --bq-toast--box-shadow - Toast box shadow\n * @cssprop --bq-toast--padding-y - Toast vertical padding\n * @cssprop --bq-toast--padding-x - Toast horizontal padding\n * @cssprop --bq-toast--gap - Toast distance between icon and text\n * @cssprop --bq-toast--border-radius - Toast border radius\n * @cssprop --bq-toast--border-color - Toast border color\n * @cssprop --bq-toast--border-style - Toast border style\n * @cssprop --bq-toast--border-width - Toast border width\n * @cssprop --bq-toast--icon-color-info - Toast icon color when type is 'info'\n * @cssprop --bq-toast--icon-color-success - Toast icon color when type is 'success'\n * @cssprop --bq-toast--icon-color-alert - Toast icon color when type is 'alert'\n * @cssprop --bq-toast--icon-color-error - Toast icon color when type is 'error'\n * @cssprop --bq-toast--icon-color-loading - Toast icon color when type is 'loading'\n * @cssprop --bq-toast--icon-color-custom - Toast icon color when type is 'custom'\n */\n@Component({\n tag: 'bq-toast',\n styleUrl: './scss/bq-toast.scss',\n shadow: true,\n})\nexport class BqToast {\n // Own Properties\n // ====================\n\n private autoDismissDebounce: TDebounce<void>;\n\n // Reference to host HTML element\n // ===================================\n\n @Element() el!: HTMLBqToastElement;\n\n // State() variables\n // Inlined decorator, alphabetical order\n // =======================================\n\n @State() private toastPortal = isClient() ? document.querySelector(`.${TOAST_PORTAL_SELECTOR}`) : null;\n\n // Public Property API\n // ========================\n\n /** The corder radius of the toast component */\n @Prop({ reflect: true }) border: TToastBorderRadius = 's';\n\n /** Type of toast */\n @Prop({ reflect: true, mutable: true }) type: TToastType = 'info';\n\n /** Placement of toast */\n @Prop({ reflect: true, mutable: true }) placement: TToastPlacement = 'bottom-center';\n\n /** If true will hide toast icon */\n @Prop({ reflect: true, mutable: true }) hideIcon = false;\n\n /** If true, the toast will be shown */\n @Prop({ reflect: true, mutable: true }) open: boolean;\n\n /** The length of time, in milliseconds, after which the toast will close itself */\n @Prop({ reflect: true }) time: number = 3000;\n\n // Prop lifecycle events\n // =======================\n\n @Watch('type')\n @Watch('placement')\n checkPropValues() {\n validatePropValue(TOAST_TYPE, 'default', this.el, 'type');\n validatePropValue(TOAST_PLACEMENT, 'bottom-center', this.el, 'placement');\n\n const { toastPortal } = this;\n toastPortal?.classList.remove(...TOAST_PLACEMENT);\n toastPortal?.classList.add(this.placement);\n }\n\n @Watch('time')\n handleTimeChange() {\n this.autoDismissDebounce?.cancel();\n\n this.time = Math.max(0, this.time);\n\n this.autoDismissDebounce = debounce(() => {\n this.hide();\n }, this.time);\n }\n\n @Watch('open')\n handleOpenChange() {\n this.autoDismissDebounce?.cancel();\n\n if (this.open) {\n this.autoDismissDebounce?.();\n }\n }\n\n // Events section\n // Requires JSDocs for public API documentation\n // ==============================================\n\n /** Callback handler to be called when the notification is hidden */\n @Event() bqHide: EventEmitter<HTMLBqToastElement>;\n\n /** Callback handler to be called when the notification is shown */\n @Event() bqShow: EventEmitter<HTMLBqToastElement>;\n\n // Component lifecycle events\n // Ordered by their natural call order\n // =====================================\n\n connectedCallback() {\n if (!isClient()) return;\n\n const { toastPortal } = this;\n if (!toastPortal) {\n this.toastPortal = Object.assign(document.createElement('div'), { className: TOAST_PORTAL_SELECTOR });\n }\n }\n\n componentWillLoad() {\n this.checkPropValues();\n this.handleTimeChange();\n this.handleOpenChange();\n }\n\n disconnectedCallback() {\n this.autoDismissDebounce?.cancel();\n }\n\n // Listeners\n // ==============\n\n @Listen('bqHide')\n onNotificationHide() {\n try {\n const { toastPortal } = this;\n toastPortal?.removeChild(this.el);\n // Remove the toast portal from the DOM when there are no more toasts\n if (toastPortal?.querySelector(this.el.tagName.toLowerCase()) === null) {\n toastPortal?.remove();\n }\n } catch (error) {\n /**\n * Skip DOMException error since it could be possible that\n * in some situations the notification portal is missing\n */\n if (error instanceof DOMException) return;\n throw error;\n }\n }\n\n // Public methods API\n // These methods are exposed on the host element.\n // Always use two lines.\n // Public Methods must be async.\n // Requires JSDocs for public API documentation.\n // ===============================================\n\n /** Method to be called to show the toast component */\n @Method()\n async show(): Promise<void> {\n this.handleShow();\n }\n\n /** Method to be called to hide the toast component */\n @Method()\n async hide(): Promise<void> {\n this.handleHide();\n }\n\n /** This method can be used to display toasts in a fixed-position element that allows for stacking multiple toasts vertically */\n @Method()\n async toast() {\n if (!isClient()) return;\n\n const { toastPortal } = this;\n if (toastPortal?.parentElement === null) {\n document.body.append(toastPortal);\n }\n\n toastPortal?.appendChild(this.el);\n\n requestAnimationFrame(() => {\n this.show();\n });\n }\n\n // Local methods\n // Internal business logic.\n // These methods cannot be called from the host element.\n // =======================================================\n\n private handleShow = () => {\n const ev = this.bqShow.emit(this.el);\n if (!ev.defaultPrevented) {\n this.open = true;\n }\n };\n\n private handleHide = () => {\n const ev = this.bqHide.emit(this.el);\n if (!ev.defaultPrevented) {\n this.open = false;\n }\n };\n\n private get iconName() {\n const typeMap = {\n success: 'check-circle-bold',\n error: 'x-circle-bold',\n loading: 'spinner-gap-bold',\n alert: 'warning-bold',\n info: 'info-bold',\n };\n\n return typeMap[this.type] || 'info-bold';\n }\n\n // render() function\n // Always the last one in the class.\n // ===================================\n\n render() {\n const style = {\n ...(this.border && { '--bq-toast--border-radius': `var(--bq-radius--${this.border})` }),\n };\n\n return (\n <Host\n style={style}\n class={{ 'is-hidden': !this.open }}\n aria-hidden={!this.open ? 'true' : 'false'}\n hidden={!this.open ? 'true' : 'false'}\n role=\"status\"\n >\n <output class=\"bq-toast\" part=\"wrapper\">\n <div class={{ [`bq-toast--icon ${this.type}`]: true, '!hidden': this.hideIcon }} part=\"icon\">\n <slot name=\"icon\">\n <bq-icon name={this.iconName} size=\"24\" slot=\"icon\" exportparts=\"base,svg\" />\n </slot>\n </div>\n <slot />\n </output>\n </Host>\n );\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;AAAO,MAAM,UAAU,GAAG,CAAC,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,OAAO,EAAE,SAAS,EAAE,QAAQ,CAAU;AAGtF,MAAM,eAAe,GAAG;IAC7B,YAAY;IACZ,WAAW;IACX,cAAc;IACd,eAAe;IACf,aAAa;IACb,UAAU;CACF;;ACVV,MAAM,UAAU,GAAG,wtsBAAwtsB;;ACO3usB,MAAM,qBAAqB,GAAG,iB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,GAAG,OAAO,EAC1C,MAAM,EAAE,CAAC,IAAI,CAAC,IAAI,GAAG,MAAM,GAAG,OAAO,EACrC,IAAI,EAAC,QAAQ,EAAA,EAEb,CAAA,CAAA,QAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAQ,KAAK,EAAC,UAAU,EAAC,IAAI,EAAC,SAAS,EAAA,EACrC,CAAK,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,KAAK,EAAE,EAAE,CAAC,CAAA,eAAA,EAAkB,IAAI,CAAC,IAAI,CAAE,CAAA,GAAG,IAAI,EAAE,SAAS,EAAE,IAAI,CAAC,QAAQ,EAAE,EAAE,IAAI,EAAC,MAAM,EAAA,EAC1F,CAAM,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,IAAI,EAAC,MAAM,EAAA,EACf,CAAA,CAAA,SAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAS,IAAI,EAAE,IAAI,CAAC,QAAQ,EAAE,IAAI,EAAC,IAAI,EAAC,IAAI,EAAC,MAAM,EAAC,WAAW,EAAC,UAAU,EAAA,CAAG,CACxE,CACH,EACN,CAAQ,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACD,CACJ;;;;;;;;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bq-tooltip.entry.esm.js","sources":["../../packages/beeq/src/components/tooltip/scss/bq-tooltip.scss?tag=bq-tooltip&encapsulation=shadow","../../packages/beeq/src/components/tooltip/bq-tooltip.tsx"],"sourcesContent":["/* -------------------------------------------------------------------------- */\n/* Tooltip styles */\n/* -------------------------------------------------------------------------- */\n\n@import './bq-tooltip.variables';\n\n.bq-tooltip--panel {\n @include animation-fade-in;\n @apply pointer-events-none fixed z-[--bq-tooltip--z-index] box-border bg-[--bq-tooltip--background-color];\n @apply is-[--bq-tooltip--width] max-is-[--bq-tooltip--max-width] p-b-[--bq-tooltip--paddingY] p-i-[--bq-tooltip--paddingX];\n @apply text-[length:--bq-tooltip--font-size] leading-[--bq-tooltip--line-height] text-[color:--bq-tooltip--text-color];\n @apply rounded-[--bq-tooltip--border-radius] border-[length:--bq-tooltip--border-width] border-[color:--bq-tooltip--border-color];\n @apply shadow-[shadow:--bq-tooltip--box-shadow];\n}\n\n.bq-tooltip--arrow {\n &,\n &::before {\n @apply absolute -z-[1] bs-2 is-2;\n }\n\n &::before {\n @apply start-0 rotate-45 bg-[--bq-tooltip--background-color] content-empty inset-bs-0;\n }\n}\n","import { Component, Element, h, Listen, Method, Prop, Watch } from '@stencil/core';\n\nimport type { Placement } from '../../services/interfaces';\nimport { FloatingUI } from '../../services/libraries';\nimport { isEventTargetChildOfElement } from '../../shared/utils';\n\n/**\n * The Tooltip component is a small pop-up box that appears when a user hovers over or clicks on an element, providing additional information or context.\n *\n * @example How to use it\n * ```html\n * <bq-tooltip visible>\n * Yuhu! I'm a tooltip 🙃\n * <bq-button slot=\"trigger\">Hover me!</bq-button>\n * </bq-tooltip>\n * ```\n *\n * @documentation https://www.beeq.design/3d466e231/p/64c562-tooltip\n * @status stable\n *\n * @attr {boolean} always-visible - If true, the tooltip will always be visible\n * @attr {number} distance - Distance between trigger element and tooltip\n * @attr {boolean} hide-arrow - If true, the arrow on the tooltip content won't be shown\n * @attr {\"top\" | \"right\" | \"bottom\" | \"left\"} placement - Defines the position of the tooltip\n * @attr {boolean} same-width - Whether the tooltip should have the same width as the trigger element (applicable only for content shorter than the trigger element)\n * @attr {\"click\" | \"hover\"} display-on - Set the action when the tooltip should be displayed, on hover (default) or click\n * @attr {boolean} visible - Indicates whether or not the tooltip is visible when the component is first rendered, and when interacting with the trigger\n *\n * @method show - Shows the tooltip\n * @method hide - Hides the tooltip\n *\n * @slot trigger - The element which displays tooltip on hover\n * @slot - The tooltip content\n *\n * @part base - The component wrapper container inside the shadow DOM\n * @part trigger - The `<div>` container that holds the element which displays tooltip on hover\n * @part panel - The `<div>` container that holds the tooltip content\n *\n * @cssprop --bq-tooltip--background-color - Tooltip background color\n * @cssprop --bq-tooltip--box-shadow - Tooltip box shadow\n * @cssprop --bq-tooltip--font-size - Tooltip font size\n * @cssprop --bq-tooltip--line-height - Tooltip line height\n * @cssprop --bq-tooltip--text-color - Tooltip text color\n * @cssprop --bq-tooltip--paddingX - Tooltip horizontal padding\n * @cssprop --bq-tooltip--paddingY - Tooltip vertical padding\n * @cssprop --bq-tooltip--border-color - Tooltip border color\n * @cssprop --bq-tooltip--border-radius - Tooltip border radius\n * @cssprop --bq-tooltip--border-style - Tooltip border style\n * @cssprop --bq-tooltip--border-width - Tooltip border width\n * @cssprop --bq-tooltip--z-index: Tooltip z-index\n */\n@Component({\n tag: 'bq-tooltip',\n styleUrl: './scss/bq-tooltip.scss',\n shadow: true,\n})\nexport class BqTooltip {\n // Own Properties\n // ====================\n private trigger: HTMLElement;\n private panel: HTMLElement;\n private arrow: HTMLElement;\n private floatingUI: FloatingUI;\n\n // Reference to host HTML element\n // ===================================\n @Element() el!: HTMLBqTooltipElement;\n\n // State() variables\n // Inlined decorator, alphabetical order\n // =======================================\n\n // Public Property API\n // ========================\n\n /** If true, the tooltip will always be visible */\n @Prop() alwaysVisible?: boolean = false;\n\n /** Distance between trigger element and tooltip */\n @Prop({ reflect: true }) distance?: number = 10;\n\n /** If true, the arrow on the tooltip content won't be shown */\n @Prop({ reflect: true }) hideArrow?: boolean = false;\n\n /* Defines the position of the tooltip */\n @Prop({ reflect: true }) placement?: Placement = 'top';\n\n /** Whether the tooltip should have the same width as the trigger element\n * (applicable only for content shorter than the trigger element) */\n @Prop({ reflect: true }) sameWidth?: boolean = false;\n\n /** Set the action when the tooltip should be displayed, on hover (default) or click */\n @Prop({ reflect: true }) displayOn: 'click' | 'hover' = 'hover';\n\n /**\n * Indicates whether or not the tooltip is visible when the component is first rendered,\n * and when interacting with the trigger\n */\n @Prop({ reflect: true, mutable: true }) visible? = false;\n\n // Prop lifecycle events\n // =======================\n\n @Watch('visible')\n async handleVisibleChange() {\n if (!this.visible && !this.alwaysVisible) {\n return await this.hide();\n }\n\n await this.show();\n }\n\n @Watch('distance')\n @Watch('hideArrow')\n @Watch('placement')\n @Watch('sameWidth')\n handleFloatingUIOptionsChange() {\n this.floatingUI.init({\n placement: this.placement,\n distance: this.distance,\n sameWidth: this.sameWidth,\n strategy: 'fixed',\n });\n }\n // Events section\n // Requires JSDocs for public API documentation\n // ==============================================\n\n // Component lifecycle events\n // Ordered by their natural call order\n // =====================================\n\n componentDidLoad() {\n this.floatingUI = new FloatingUI(this.trigger, this.panel, {\n ...(!this.hideArrow && { arrow: this.arrow }),\n placement: this.placement,\n distance: this.distance,\n sameWidth: this.sameWidth,\n strategy: 'fixed',\n skidding: 0,\n });\n }\n\n disconnectedCallback() {\n this.floatingUI?.destroy();\n }\n // Listeners\n // ==============\n\n @Listen('keydown', { target: 'document' })\n handleDocumentKeyDown(event: KeyboardEvent) {\n // Early returns for performance optimization\n if (this.alwaysVisible || !this.visible || this.displayOn !== 'click') return;\n // Hide tooltip when the user presses the escape key, but only if the displayOn is click and the tooltip is visible\n if (event.key !== 'Escape') return;\n\n this.hide();\n }\n\n @Listen('mousedown', { target: 'document' })\n handleDocumentMouseDown(event: MouseEvent) {\n // Early returns for performance optimization\n if (this.alwaysVisible || !this.visible) return;\n // Hide tooltip when the user clicks outside of the tooltip, but only if the displayOn is click and the tooltip is visible\n if (isEventTargetChildOfElement(event, this.el)) return;\n\n this.hide();\n }\n\n @Listen('scroll', { target: 'document', passive: true })\n handleDocumentScroll() {\n // Early returns for performance optimization\n if (this.alwaysVisible || !this.visible) return;\n // Hide tooltip when the user scrolls, but only if the the tooltip is visible\n this.hide();\n }\n\n // Public methods API\n // These methods are exposed on the host element.\n // Always use two lines.\n // Public Methods must be async.\n // Requires JSDocs for public API documentation.\n // ===============================================\n\n /** Shows the tooltip */\n @Method()\n async show() {\n this.visible = true;\n this.showTooltip();\n }\n\n /** Hides the tooltip */\n @Method()\n async hide() {\n if (this.alwaysVisible) return;\n\n this.visible = false;\n this.hideTooltip();\n }\n\n // Local methods\n // Internal business logic.\n // These methods cannot be called from the host element.\n // =======================================================\n\n private handleTriggerMouseOver = async () => {\n if (this.displayOn !== 'hover') return;\n await this.show();\n };\n\n private handleTriggerMouseLeave = async () => {\n if (this.displayOn !== 'hover') return;\n await this.hide();\n };\n\n private handleTriggerOnClick = async () => {\n if (this.displayOn !== 'click') return;\n await (this.visible ? this.hide() : this.show());\n };\n\n private handleTriggerFocusin = async () => {\n if (this.visible || this.displayOn === 'click') return;\n await this.show();\n };\n\n private handleTriggerFocusout = async () => {\n if (!this.visible || this.displayOn === 'click') return;\n await this.hide();\n };\n\n private showTooltip = () => {\n if (!this.panel) return;\n this.floatingUI?.update();\n };\n\n private hideTooltip = () => {\n if (!this.panel) return;\n this.visible = false;\n };\n\n private get isHidden() {\n return !this.visible && !this.alwaysVisible;\n }\n\n // render() function\n // Always the last one in the class.\n // ===================================\n\n render() {\n return (\n <div class=\"bq-tooltip relative\" part=\"base\">\n {/* TRIGGER */}\n <div\n class=\"bq-tooltip--trigger\"\n onMouseOver={this.handleTriggerMouseOver}\n onMouseLeave={this.handleTriggerMouseLeave}\n onClick={this.handleTriggerOnClick}\n onFocusinCapture={this.handleTriggerFocusin}\n onFocusoutCapture={this.handleTriggerFocusout}\n ref={(el) => (this.trigger = el)}\n part=\"trigger\"\n >\n <slot name=\"trigger\" />\n </div>\n {/* PANEL */}\n <div\n class=\"bq-tooltip--panel\"\n aria-hidden={this.isHidden}\n hidden={this.isHidden}\n role=\"tooltip\"\n ref={(el) => (this.panel = el)}\n part=\"panel\"\n >\n {!this.hideArrow && <div class=\"bq-tooltip--arrow\" ref={(el) => (this.arrow = el)} />}\n <slot />\n </div>\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;;;;;;AAAA,MAAM,YAAY,GAAG,86sBAA86sB;;MCwDt7sB,SAAS,GAAA,MAAA;;;;;;AAGZ,IAAA,OAAO;AACP,IAAA,KA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AAI,EAAC,SAAS,EAAA,CAAG,CACnB,EAEN,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,KAAK,EAAC,mBAAmB,EAAA,aAAA,EACZ,IAAI,CAAC,QAAQ,EAC1B,MAAM,EAAE,IAAI,CAAC,QAAQ,EACrB,IAAI,EAAC,SAAS,EACd,GAAG,EAAE,CAAC,EAAE,MAAM,IAAI,CAAC,KAAK,GAAG,EAAE,CAAC,EAC9B,IAAI,EAAC,OAAO,EAAA,EAEX,CAAC,IAAI,CAAC,SAAS,IAAI,4DAAK,KAAK,EAAC,mBAAmB,EAAC,GAAG,EAAE,CAAC,EAAE,MAAM,IAAI,CAAC,KAAK,GAAG,EAAE,CAAC,EAAI,CAAA,EACrF,CAAQ,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACJ,CACF;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"bq-tooltip.entry.esm.js","sources":["../../packages/beeq/src/components/tooltip/scss/bq-tooltip.scss?tag=bq-tooltip&encapsulation=shadow","../../packages/beeq/src/components/tooltip/bq-tooltip.tsx"],"sourcesContent":["/* -------------------------------------------------------------------------- */\n/* Tooltip styles */\n/* -------------------------------------------------------------------------- */\n\n@import './bq-tooltip.variables';\n\n.bq-tooltip--panel {\n @include animation-fade-in;\n @apply pointer-events-none fixed z-[--bq-tooltip--z-index] box-border bg-[--bq-tooltip--background-color];\n @apply is-[--bq-tooltip--width] max-is-[--bq-tooltip--max-width] p-b-[--bq-tooltip--paddingY] p-i-[--bq-tooltip--paddingX];\n @apply text-[length:--bq-tooltip--font-size] leading-[--bq-tooltip--line-height] text-[color:--bq-tooltip--text-color];\n @apply rounded-[--bq-tooltip--border-radius] border-[length:--bq-tooltip--border-width] border-[color:--bq-tooltip--border-color];\n @apply shadow-[shadow:--bq-tooltip--box-shadow];\n}\n\n.bq-tooltip--arrow {\n &,\n &::before {\n @apply absolute -z-[1] bs-2 is-2;\n }\n\n &::before {\n @apply start-0 rotate-45 bg-[--bq-tooltip--background-color] content-empty inset-bs-0;\n }\n}\n","import { Component, Element, h, Listen, Method, Prop, Watch } from '@stencil/core';\n\nimport type { Placement } from '../../services/interfaces';\nimport { FloatingUI } from '../../services/libraries';\nimport { isEventTargetChildOfElement } from '../../shared/utils';\n\n/**\n * The Tooltip component is a small pop-up box that appears when a user hovers over or clicks on an element, providing additional information or context.\n *\n * @example How to use it\n * ```html\n * <bq-tooltip visible>\n * Yuhu! I'm a tooltip 🙃\n * <bq-button slot=\"trigger\">Hover me!</bq-button>\n * </bq-tooltip>\n * ```\n *\n * @documentation https://www.beeq.design/3d466e231/p/64c562-tooltip\n * @status stable\n *\n * @attr {boolean} always-visible - If true, the tooltip will always be visible\n * @attr {number} distance - Distance between trigger element and tooltip\n * @attr {boolean} hide-arrow - If true, the arrow on the tooltip content won't be shown\n * @attr {\"top\" | \"right\" | \"bottom\" | \"left\"} placement - Defines the position of the tooltip\n * @attr {boolean} same-width - Whether the tooltip should have the same width as the trigger element (applicable only for content shorter than the trigger element)\n * @attr {\"click\" | \"hover\"} display-on - Set the action when the tooltip should be displayed, on hover (default) or click\n * @attr {boolean} visible - Indicates whether or not the tooltip is visible when the component is first rendered, and when interacting with the trigger\n *\n * @method show - Shows the tooltip\n * @method hide - Hides the tooltip\n *\n * @slot trigger - The element which displays tooltip on hover\n * @slot - The tooltip content\n *\n * @part base - The component wrapper container inside the shadow DOM\n * @part trigger - The `<div>` container that holds the element which displays tooltip on hover\n * @part panel - The `<div>` container that holds the tooltip content\n *\n * @cssprop --bq-tooltip--background-color - Tooltip background color\n * @cssprop --bq-tooltip--box-shadow - Tooltip box shadow\n * @cssprop --bq-tooltip--font-size - Tooltip font size\n * @cssprop --bq-tooltip--line-height - Tooltip line height\n * @cssprop --bq-tooltip--text-color - Tooltip text color\n * @cssprop --bq-tooltip--paddingX - Tooltip horizontal padding\n * @cssprop --bq-tooltip--paddingY - Tooltip vertical padding\n * @cssprop --bq-tooltip--border-color - Tooltip border color\n * @cssprop --bq-tooltip--border-radius - Tooltip border radius\n * @cssprop --bq-tooltip--border-style - Tooltip border style\n * @cssprop --bq-tooltip--border-width - Tooltip border width\n * @cssprop --bq-tooltip--z-index: Tooltip z-index\n */\n@Component({\n tag: 'bq-tooltip',\n styleUrl: './scss/bq-tooltip.scss',\n shadow: true,\n})\nexport class BqTooltip {\n // Own Properties\n // ====================\n private trigger: HTMLElement;\n private panel: HTMLElement;\n private arrow: HTMLElement;\n private floatingUI: FloatingUI;\n\n // Reference to host HTML element\n // ===================================\n @Element() el!: HTMLBqTooltipElement;\n\n // State() variables\n // Inlined decorator, alphabetical order\n // =======================================\n\n // Public Property API\n // ========================\n\n /** If true, the tooltip will always be visible */\n @Prop() alwaysVisible?: boolean = false;\n\n /** Distance between trigger element and tooltip */\n @Prop({ reflect: true }) distance?: number = 10;\n\n /** If true, the arrow on the tooltip content won't be shown */\n @Prop({ reflect: true }) hideArrow?: boolean = false;\n\n /* Defines the position of the tooltip */\n @Prop({ reflect: true }) placement?: Placement = 'top';\n\n /** Whether the tooltip should have the same width as the trigger element\n * (applicable only for content shorter than the trigger element) */\n @Prop({ reflect: true }) sameWidth?: boolean = false;\n\n /** Set the action when the tooltip should be displayed, on hover (default) or click */\n @Prop({ reflect: true }) displayOn: 'click' | 'hover' = 'hover';\n\n /**\n * Indicates whether or not the tooltip is visible when the component is first rendered,\n * and when interacting with the trigger\n */\n @Prop({ reflect: true, mutable: true }) visible? = false;\n\n // Prop lifecycle events\n // =======================\n\n @Watch('visible')\n async handleVisibleChange() {\n if (!this.visible && !this.alwaysVisible) {\n return await this.hide();\n }\n\n await this.show();\n }\n\n @Watch('distance')\n @Watch('hideArrow')\n @Watch('placement')\n @Watch('sameWidth')\n handleFloatingUIOptionsChange() {\n this.floatingUI.init({\n placement: this.placement,\n distance: this.distance,\n sameWidth: this.sameWidth,\n strategy: 'fixed',\n });\n }\n // Events section\n // Requires JSDocs for public API documentation\n // ==============================================\n\n // Component lifecycle events\n // Ordered by their natural call order\n // =====================================\n\n componentDidLoad() {\n this.floatingUI = new FloatingUI(this.trigger, this.panel, {\n ...(!this.hideArrow && { arrow: this.arrow }),\n placement: this.placement,\n distance: this.distance,\n sameWidth: this.sameWidth,\n strategy: 'fixed',\n skidding: 0,\n });\n }\n\n disconnectedCallback() {\n this.floatingUI?.destroy();\n }\n // Listeners\n // ==============\n\n @Listen('keydown', { target: 'document' })\n handleDocumentKeyDown(event: KeyboardEvent) {\n // Early returns for performance optimization\n if (this.alwaysVisible || !this.visible || this.displayOn !== 'click') return;\n // Hide tooltip when the user presses the escape key, but only if the displayOn is click and the tooltip is visible\n if (event.key !== 'Escape') return;\n\n this.hide();\n }\n\n @Listen('mousedown', { target: 'document' })\n handleDocumentMouseDown(event: MouseEvent) {\n // Early returns for performance optimization\n if (this.alwaysVisible || !this.visible) return;\n // Hide tooltip when the user clicks outside of the tooltip, but only if the displayOn is click and the tooltip is visible\n if (isEventTargetChildOfElement(event, this.el)) return;\n\n this.hide();\n }\n\n @Listen('scroll', { target: 'document', passive: true })\n handleDocumentScroll() {\n // Early returns for performance optimization\n if (this.alwaysVisible || !this.visible) return;\n // Hide tooltip when the user scrolls, but only if the the tooltip is visible\n this.hide();\n }\n\n // Public methods API\n // These methods are exposed on the host element.\n // Always use two lines.\n // Public Methods must be async.\n // Requires JSDocs for public API documentation.\n // ===============================================\n\n /** Shows the tooltip */\n @Method()\n async show() {\n this.visible = true;\n this.showTooltip();\n }\n\n /** Hides the tooltip */\n @Method()\n async hide() {\n if (this.alwaysVisible) return;\n\n this.visible = false;\n this.hideTooltip();\n }\n\n // Local methods\n // Internal business logic.\n // These methods cannot be called from the host element.\n // =======================================================\n\n private handleTriggerMouseOver = async () => {\n if (this.displayOn !== 'hover') return;\n await this.show();\n };\n\n private handleTriggerMouseLeave = async () => {\n if (this.displayOn !== 'hover') return;\n await this.hide();\n };\n\n private handleTriggerOnClick = async () => {\n if (this.displayOn !== 'click') return;\n await (this.visible ? this.hide() : this.show());\n };\n\n private handleTriggerFocusin = async () => {\n if (this.visible || this.displayOn === 'click') return;\n await this.show();\n };\n\n private handleTriggerFocusout = async () => {\n if (!this.visible || this.displayOn === 'click') return;\n await this.hide();\n };\n\n private showTooltip = () => {\n if (!this.panel) return;\n this.floatingUI?.update();\n };\n\n private hideTooltip = () => {\n if (!this.panel) return;\n this.visible = false;\n };\n\n private get isHidden() {\n return !this.visible && !this.alwaysVisible;\n }\n\n // render() function\n // Always the last one in the class.\n // ===================================\n\n render() {\n return (\n <div class=\"bq-tooltip relative\" part=\"base\">\n {/* TRIGGER */}\n <div\n class=\"bq-tooltip--trigger\"\n onMouseOver={this.handleTriggerMouseOver}\n onMouseLeave={this.handleTriggerMouseLeave}\n onClick={this.handleTriggerOnClick}\n onFocusinCapture={this.handleTriggerFocusin}\n onFocusoutCapture={this.handleTriggerFocusout}\n ref={(el) => (this.trigger = el)}\n part=\"trigger\"\n >\n <slot name=\"trigger\" />\n </div>\n {/* PANEL */}\n <div\n class=\"bq-tooltip--panel\"\n aria-hidden={this.isHidden}\n hidden={this.isHidden}\n role=\"tooltip\"\n ref={(el) => (this.panel = el)}\n part=\"panel\"\n >\n {!this.hideArrow && <div class=\"bq-tooltip--arrow\" ref={(el) => (this.arrow = el)} />}\n <slot />\n </div>\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;;;;;;AAAA,MAAM,YAAY,GAAG,k1tBAAk1tB;;MCwD11tB,SAAS,GAAA,MAAA;;;;;;AAGZ,IAAA,OAAO;AACP,IAAA,KAAK;AACL,IAAA,KAAK;AACL,IAAA,UAAU;;;;;;;;IAcV,aAAa,GAAa,KAAK;;IAGd,QAAQ,GAAY,EAAE;;IAGtB,SAAS,GAAa,KAAK;;IAG3B,SAAS,GAAe,KAAK;AAEtD;AACoE;IAC3C,SAAS,GAAa,KAAK;;IAG3B,SAAS,GAAsB,OAAO;AAE/D;;;AAGG;IACqC,OAAO,GAAI,KAAK;;;AAMxD,IAA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GAAG,EAAE,CAAC,EAC9B,IAAI,EAAC,OAAO,EAAA,EAEX,CAAC,IAAI,CAAC,SAAS,IAAI,4DAAK,KAAK,EAAC,mBAAmB,EAAC,GAAG,EAAE,CAAC,EAAE,MAAM,IAAI,CAAC,KAAK,GAAG,EAAE,CAAC,EAAI,CAAA,EACrF,CAAQ,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACJ,CACF;;;;;;;;;;;;;;"}
|
package/dist/beeq/index.esm.js
CHANGED
|
@@ -2,5 +2,5 @@
|
|
|
2
2
|
* Built by Endavans
|
|
3
3
|
* © https://beeq.design - Apache 2 License.
|
|
4
4
|
*/
|
|
5
|
-
export{g as getBasePath,s as setBasePath}from"./p-DG51kDIQ.js";export{c as clamp}from"./p-Cau9SvT4.js";export{a as getCSSVariableValue,g as getColorCSSVariable}from"./p-_RvVpeh2.js";export{d as debounce,s as setRafTimeout}from"./p-D9ofIraD.js";export{i as isEventTargetChildOfElement}from"./p-Dx-CEPSQ.js";export{g as getNextElement}from"./p-
|
|
5
|
+
export{g as getBasePath,s as setBasePath}from"./p-DG51kDIQ.js";export{c as clamp}from"./p-Cau9SvT4.js";export{a as getCSSVariableValue,g as getColorCSSVariable}from"./p-_RvVpeh2.js";export{d as debounce,s as setRafTimeout}from"./p-D9ofIraD.js";export{i as isEventTargetChildOfElement}from"./p-Dx-CEPSQ.js";export{g as getNextElement}from"./p-BsSDkLU5.js";export{i as isClient}from"./p-B4sM1t6Z.js";import{i as o}from"./p-Ci39rxuU.js";import{i as r}from"./p-BcPwGxIn.js";export{i as isHTMLElement}from"./p-BxgDLPzX.js";export{i as isString}from"./p-CVMdKx0v.js";export{v as validatePropValue}from"./p-zh4P02Kn.js";export{c as configureScrollLock,f as forceUnlockAllBodyScroll,g as getScrollLockCount,i as isBodyScrollLocked,l as lockBodyScroll,u as unlockBodyScroll}from"./p-CCNjsDdb.js";export{g as getInnerHTML,a as getTextContent,h as hasSlot,b as hasSlotContent}from"./p-uqkxeAeG.js";export{s as stringToArray}from"./p-BO2RoztC.js";export{e as enter,l as leave,t as toggle}from"./p-DdvbF5yL.js";const n=(e,o)=>{let r=e.length;const s=new Array(o);const t=new Array(r);if(o>r)throw new RangeError("getRandom: more elements taken than available");while(o--){const a=Date.now()%r;s[o]=e[a in t?t[a]:a];t[a]=--r in t?t[r]:r}return s};const p=e=>{if(r(e)){return true}else if("size"in e){return!o(e.size)}else{return!o(Object.values(e).length)}};export{n as getRandomFromArray,o as isDefined,p as isEmpty,r as isNil};
|
|
6
6
|
//# sourceMappingURL=index.esm.js.map
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Built by Endavans
|
|
3
|
+
* © https://beeq.design - Apache 2 License.
|
|
4
|
+
*/
|
|
5
|
+
import{r as a,c as r,a as e,h as b}from"./p-C4jSqdYP.js";import{v as t}from"./p-zh4P02Kn.js";import{b as i}from"./p-uqkxeAeG.js";import{l as n,e as o}from"./p-DdvbF5yL.js";const q=["small","medium","large"];const d=["standard","highlight"];const s='.transform{--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.bq-dialog,.shadow-\\[shadow\\:--bq-dialog--box-shadow\\]{--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000}::backdrop,:root{--bq-blue-100:#e7f0fd;--bq-blue-200:#d0e2fb;--bq-blue-300:#a1c5f7;--bq-blue-400:#73a8f3;--bq-blue-500:#448bef;--bq-blue-600:#156eeb;--bq-blue-700:#1158bc;--bq-blue-800:#0d428d;--bq-blue-900:#082c5e;--bq-blue-1000:#04162f;--bq-corai-100:#fff2f2;--bq-corai-200:#ffe6e6;--bq-corai-300:#ffccce;--bq-corai-400:#ffb3b5;--bq-corai-500:#ff999d;--bq-corai-600:#ff8084;--bq-corai-700:#cc666a;--bq-corai-800:#994d4f;--bq-corai-900:#663335;--bq-corai-1000:#331a1a;--bq-cyan-100:#e8f7fb;--bq-cyan-200:#d2f0f8;--bq-cyan-300:#a5e1f1;--bq-cyan-400:#78d1e9;--bq-cyan-500:#4bc2e2;--bq-cyan-600:#1eb3db;--bq-cyan-700:#188faf;--bq-cyan-800:#126b83;--bq-cyan-900:#0c4858;--bq-cyan-1000:#06242c;--bq-gold-100:#fbf4ec;--bq-gold-200:#f7e9da;--bq-gold-300:#f0d3b6;--bq-gold-400:#e8bc91;--bq-gold-500:#e1a66d;--bq-gold-600:#d99048;--bq-gold-700:#ae733a;--bq-gold-800:#82562b;--bq-gold-900:#573a1d;--bq-gold-1000:#2b1d0e;--bq-green-100:#e8f8ef;--bq-green-200:#d2f1e0;--bq-green-300:#a5e3c1;--bq-green-400:#78d5a1;--bq-green-500:#4bc782;--bq-green-600:#1eb963;--bq-green-700:#18944f;--bq-green-800:#126f3b;--bq-green-900:#0c4a28;--bq-green-1000:#062514;--bq-grey-100:#f1f2f4;--bq-grey-200:#e7e8eb;--bq-grey-300:#caccd2;--bq-grey-400:#a6aab3;--bq-grey-50:#f6f6f8;--bq-grey-500:#898e99;--bq-grey-600:#646a77;--bq-grey-700:#3f4350;--bq-grey-800:#2a2c35;--bq-grey-900:#1c1d23;--bq-grey-950:#15161a;--bq-grey-1000:#0d0e11;--bq-indigo-100:#edecfc;--bq-indigo-200:#dcdafa;--bq-indigo-300:#b9b5f5;--bq-indigo-400:#9590ef;--bq-indigo-500:#726bea;--bq-indigo-600:#4f46e5;--bq-indigo-700:#3f38b7;--bq-indigo-800:#2f2a89;--bq-indigo-900:#201c5c;--bq-indigo-1000:#100e2e;--bq-iris-100:#e9f0ff;--bq-iris-200:#d6e0ff;--bq-iris-300:#b2c0fe;--bq-iris-400:#8691f8;--bq-iris-500:#6061ee;--bq-iris-600:#4f46e5;--bq-iris-700:#413abd;--bq-iris-800:#332e95;--bq-iris-900:#26216d;--bq-iris-1000:#181545;--bq-lime-100:#f5fae8;--bq-lime-200:#ecf6d2;--bq-lime-300:#d9eda5;--bq-lime-400:#c5e379;--bq-lime-500:#b2da4c;--bq-lime-600:#9fd11f;--bq-lime-700:#7fa719;--bq-lime-800:#5f7d13;--bq-lime-900:#40540c;--bq-lime-1000:#202a06;--bq-magenta-100:#fce7f4;--bq-magenta-200:#f9cfea;--bq-magenta-300:#f39fd6;--bq-magenta-400:#ee6fbf;--bq-magenta-500:#e83fab;--bq-magenta-600:#de1395;--bq-magenta-700:#b20f77;--bq-magenta-800:#850c59;--bq-magenta-900:#58083c;--bq-magenta-1000:#2c041e;--bq-neutral-white:#fbfbfc;--bq-neutral-black:#060708;--bq-orange-100:#fbf0e9;--bq-orange-200:#f8e1d4;--bq-orange-300:#f1c2a8;--bq-orange-400:#eaa47d;--bq-orange-500:#e38551;--bq-orange-600:#dc6726;--bq-orange-700:#b0521e;--bq-orange-800:#843e17;--bq-orange-900:#58290f;--bq-orange-1000:#2c1508;--bq-purple-100:#efebf8;--bq-purple-200:#e0d7f2;--bq-purple-300:#c1afe5;--bq-purple-400:#a388d8;--bq-purple-500:#8460cb;--bq-purple-600:#6538be;--bq-purple-700:#512d98;--bq-purple-800:#3d2272;--bq-purple-900:#28164c;--bq-purple-1000:#140b26;--bq-red-100:#fce7ea;--bq-red-200:#f9d1d5;--bq-red-300:#f3a2ac;--bq-red-400:#ed7482;--bq-red-500:#e74559;--bq-red-600:#e1172f;--bq-red-700:#b41226;--bq-red-800:#870e1c;--bq-red-900:#5a0913;--bq-red-1000:#2d0509;--bq-sky-100:#eff4fb;--bq-sky-200:#dfeaf8;--bq-sky-300:#bfd5f1;--bq-sky-400:#9ec1e9;--bq-sky-500:#7eace2;--bq-sky-600:#5e97db;--bq-sky-700:#4b79af;--bq-sky-800:#385b83;--bq-sky-900:#263c58;--bq-sky-1000:#131e2c;--bq-teal-100:#e5f7f5;--bq-teal-200:#ccf0eb;--bq-teal-300:#99e1d8;--bq-teal-400:#66d2c4;--bq-teal-500:#33c3b1;--bq-teal-600:#00b49d;--bq-teal-700:#00907e;--bq-teal-800:#006c5e;--bq-teal-900:#00483f;--bq-teal-1000:#00241f;--bq-volcano-100:#feede7;--bq-volcano-200:#fddbd1;--bq-volcano-300:#fbb8a3;--bq-volcano-400:#fa9474;--bq-volcano-500:#f87146;--bq-volcano-600:#f64d18;--bq-volcano-700:#c53e13;--bq-volcano-800:#942e0e;--bq-volcano-900:#621f0a;--bq-volcano-1000:#310f05;--bq-yellow-100:#fefbe7;--bq-yellow-200:#fcf6d0;--bq-yellow-300:#faeea0;--bq-yellow-400:#f7e571;--bq-yellow-500:#f5dd41;--bq-yellow-600:#f2d412;--bq-yellow-700:#c2aa0e;--bq-yellow-800:#917f0b;--bq-yellow-900:#615507;--bq-yellow-1000:#302a04;--bq-endava-grey-50:#f7f7f8;--bq-endava-grey-100:#e4e6e7;--bq-endava-grey-200:#b5babe;--bq-endava-grey-300:#949ca1;--bq-endava-grey-400:#737d84;--bq-endava-grey-500:#525f67;--bq-endava-grey-600:#30404b;--bq-endava-grey-700:#2b3942;--bq-endava-grey-800:#263139;--bq-endava-grey-900:#192b37;--bq-endava-grey-950:#151b1e;--bq-endava-grey-1000:#0f1316;--bq-endava-neutral-white:#fafbfb;--bq-endava-neutral-black:#060708;--bq-endava-orange-100:#fef3f1;--bq-endava-orange-200:#fbd6d1;--bq-endava-orange-300:#fab7af;--bq-endava-orange-400:#fa988b;--bq-endava-orange-500:#fc7866;--bq-endava-orange-600:#ff5640;--bq-endava-orange-700:#ce4a39;--bq-endava-orange-800:#a03d30;--bq-endava-orange-900:#722e25;--bq-endava-orange-1000:#471e19}*,:after,:before{box-sizing:border-box}*{font:inherit;margin:0}ol[role=list],ul[role=list]{list-style-type:none}html{text-size-adjust:none;font-family:var(--bq-font-family);font-size:var(--bq-font-size--m)}html:focus-within{scroll-behavior:smooth}body{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;background-color:var(--bq-background--primary);color:var(--bq-text--primary);line-height:var(--bq-font-line-height--regular);min-height:100vb;text-rendering:optimizeSpeed}a:not([class]){text-decoration-skip-ink:auto}canvas,img,picture,svg,video{display:block;max-width:100%}button,input,select,textarea{font:inherit}h1,h2,h3,h4,h5,h6,p{overflow-wrap:break-word}@media (prefers-reduced-motion:reduce){html:focus-within{scroll-behavior:auto}*,:after,:before{animation-duration:.01ms!important;animation-iteration-count:1!important;scroll-behavior:auto;transition-duration:.01ms!important}}:where(:root){--bq-white:#fff;--bq-black:#060708;--bq-neutral-50:var(--bq-grey-50);--bq-neutral-100:var(--bq-grey-100);--bq-neutral-200:var(--bq-grey-200);--bq-neutral-300:var(--bq-grey-300);--bq-neutral-400:var(--bq-grey-400);--bq-neutral-500:var(--bq-grey-500);--bq-neutral-600:var(--bq-grey-600);--bq-neutral-700:var(--bq-grey-700);--bq-neutral-800:var(--bq-grey-800);--bq-neutral-900:var(--bq-grey-900);--bq-neutral-950:var(--bq-grey-950);--bq-neutral-1000:var(--bq-grey-1000);--bq-brand-light:var(--bq-iris-100);--bq-brand:var(--bq-iris-600);--bq-brand-dark:var(--bq-iris-1000);--bq-accent-light:var(--bq-purple-100);--bq-accent:var(--bq-purple-600);--bq-accent-dark:var(--bq-purple-1000);--bq-success-light:var(--bq-teal-100);--bq-success:var(--bq-teal-600);--bq-success-dark:var(--bq-teal-1000);--bq-danger-light:var(--bq-red-100);--bq-danger:var(--bq-red-600);--bq-danger-dark:var(--bq-red-1000);--bq-warning-light:var(--bq-gold-100);--bq-warning:var(--bq-gold-600);--bq-warning-dark:var(--bq-gold-1000);--bq-info-light:var(--bq-iris-100);--bq-info:var(--bq-iris-600);--bq-info-dark:var(--bq-iris-1000);--bq-focus:var(--bq-iris-600);--bq-data-01:var(--bq-brand);--bq-data-02:var(--bq-purple-600);--bq-data-03:var(--bq-magenta-600);--bq-data-04:var(--bq-cyan-600);--bq-data-05:var(--bq-teal-600);--bq-data-06:var(--bq-orange-600);--bq-data-07:var(--bq-yellow-600);--bq-data-08:var(--bq-red-600);--bq-data-09:var(--bq-blue-600);--bq-data-10:var(--bq-grey-600);--bq-data-11:var(--bq-black);--bq-data-12:var(--bq-white);--bq-radius--none:0;--bq-radius--xs2:0.125rem;--bq-radius--xs:0.25rem;--bq-radius--s:0.5rem;--bq-radius--m:0.75rem;--bq-radius--l:1.5rem;--bq-radius--full:9999px;--bq-box-shadow--xs:0 2px 0 rgba(0,0,0,.016);--bq-box-shadow--s:0 8px 24px rgba(0,0,0,.04);--bq-box-shadow--m:0 10px 48px -16px rgba(0,0,0,.12);--bq-box-shadow--l:0 20px 58px -16px rgba(0,0,0,.16);--bq-font-family:"Outfit",sans-serif;--bq-font-size--xs:0.75rem;--bq-font-size--s:0.875rem;--bq-font-size--m:1rem;--bq-font-size--l:1.125rem;--bq-font-size--xl:1.5rem;--bq-font-size--xxl:2rem;--bq-font-size--xxl2:2.5rem;--bq-font-size--xxl3:3rem;--bq-font-size--xxl4:3.5rem;--bq-font-size--xxl5:4rem;--bq-font-weight--thin:100;--bq-font-weight--light:300;--bq-font-weight--regular:400;--bq-font-weight--medium:500;--bq-font-weight--semibold:600;--bq-font-weight--bold:700;--bq-font-line-height--small:1.2;--bq-font-line-height--regular:1.5;--bq-font-line-height--large:1.5;--bq-spacing-xs3:0.125rem;--bq-spacing-xs2:0.25rem;--bq-spacing-xs:0.5rem;--bq-spacing-s:0.75rem;--bq-spacing-m:1rem;--bq-spacing-l:1.5rem;--bq-spacing-xl:2rem;--bq-spacing-xxl:2.5rem;--bq-spacing-xxl2:3.5rem;--bq-spacing-xxl3:4rem;--bq-spacing-xxl4:4.5rem;--bq-stroke-s:1px;--bq-stroke-m:2px;--bq-stroke-l:3px}.beeq:not([bq-mode]),.light,:root:not([bq-theme]):not([bq-mode]),:root[bq-theme=beeq]:not([bq-mode]),[bq-mode=light]{--bq-background--primary:var(--bq-white);--bq-background--secondary:var(--bq-neutral-100);--bq-background--tertiary:var(--bq-neutral-200);--bq-background--alt:var(--bq-neutral-300);--bq-background--inverse:var(--bq-neutral-900);--bq-background--brand:var(--bq-brand);--bq-background--overlay:var(--bq-neutral-900);--bq-icon--primary:var(--bq-neutral-800);--bq-icon--alt:var(--bq-white);--bq-icon--secondary:var(--bq-neutral-600);--bq-icon--inverse:var(--bq-neutral-50);--bq-icon--brand:var(--bq-brand);--bq-icon--info:var(--bq-brand);--bq-icon--success:var(--bq-success);--bq-icon--warning:var(--bq-warning);--bq-icon--danger:var(--bq-danger);--bq-stroke--primary:var(--bq-neutral-200);--bq-stroke--secondary:var(--bq-neutral-600);--bq-stroke--tertiary:var(--bq-neutral-900);--bq-stroke--inverse:var(--bq-white);--bq-stroke--brand:var(--bq-brand);--bq-stroke--alt:var(--bq-neutral-50);--bq-stroke--success:var(--bq-success);--bq-stroke--warning:var(--bq-warning);--bq-stroke--danger:var(--bq-danger);--bq-stroke--info:var(--bq-brand);--bq-text--primary:var(--bq-neutral-800);--bq-text--secondary:var(--bq-neutral-600);--bq-text--inverse:var(--bq-neutral-50);--bq-text--brand:var(--bq-brand);--bq-text--alt:var(--bq-white);--bq-text--info:var(--bq-brand);--bq-text--success:var(--bq-success);--bq-text--warning:var(--bq-warning);--bq-text--danger:var(--bq-danger);--bq-ui--primary:var(--bq-white);--bq-ui--secondary:var(--bq-neutral-100);--bq-ui--tertiary:var(--bq-neutral-500);--bq-ui--inverse:var(--bq-neutral-900);--bq-ui--brand:var(--bq-brand);--bq-ui--brand-alt:var(--bq-brand-light);--bq-ui--alt:var(--bq-neutral-50);--bq-ui--success:var(--bq-success);--bq-ui--success-alt:var(--bq-success-light);--bq-ui--warning:var(--bq-warning);--bq-ui--warning-alt:var(--bq-warning-light);--bq-ui--danger:var(--bq-danger);--bq-ui--danger-alt:var(--bq-danger-light);--bq-ui--info:var(--bq-brand);--bq-ui--info-alt:var(--bq-brand-light);--bq-hover:#bcbfc5;--bq-active:#444546}.dark,[bq-mode=dark]{--bq-background--primary:var(--bq-neutral-1000);--bq-background--secondary:var(--bq-neutral-950);--bq-background--tertiary:var(--bq-neutral-800);--bq-background--alt:var(--bq-neutral-700);--bq-background--inverse:var(--bq-neutral-600);--bq-background--brand:var(--bq-brand);--bq-background--overlay:var(--bq-neutral-900);--bq-icon--primary:var(--bq-neutral-100);--bq-icon--secondary:var(--bq-neutral-400);--bq-icon--inverse:var(--bq-neutral-800);--bq-icon--brand:var(--bq-brand);--bq-icon--alt:var(--bq-white);--bq-icon--info:var(--bq-brand);--bq-icon--success:var(--bq-success);--bq-icon--warning:var(--bq-warning);--bq-icon--danger:var(--bq-danger);--bq-stroke--primary:var(--bq-neutral-900);--bq-stroke--secondary:var(--bq-neutral-700);--bq-stroke--tertiary:var(--bq-neutral-400);--bq-stroke--inverse:var(--bq-neutral-950);--bq-stroke--brand:var(--bq-brand);--bq-stroke--alt:var(--bq-neutral-1000);--bq-stroke--success:var(--bq-success);--bq-stroke--warning:var(--bq-warning);--bq-stroke--danger:var(--bq-danger);--bq-stroke--info:var(--bq-brand);--bq-text--primary:var(--bq-neutral-100);--bq-text--secondary:var(--bq-neutral-400);--bq-text--inverse:var(--bq-neutral-800);--bq-text--brand:var(--bq-brand);--bq-text--alt:var(--bq-white);--bq-text--info:var(--bq-brand);--bq-text--success:var(--bq-success);--bq-text--warning:var(--bq-warning);--bq-text--danger:var(--bq-danger);--bq-ui--primary:var(--bq-neutral-900);--bq-ui--secondary:var(--bq-neutral-950);--bq-ui--tertiary:var(--bq-neutral-700);--bq-ui--inverse:var(--bq-neutral-100);--bq-ui--brand:var(--bq-brand);--bq-ui--brand-alt:var(--bq-brand-dark);--bq-ui--alt:var(--bq-neutral-950);--bq-ui--success:var(--bq-success);--bq-ui--success-alt:var(--bq-success-dark);--bq-ui--warning:var(--bq-warning);--bq-ui--warning-alt:var(--bq-warning-dark);--bq-ui--danger:var(--bq-danger);--bq-ui--danger-alt:var(--bq-danger-dark);--bq-ui--info:var(--bq-brand);--bq-ui--info-alt:var(--bq-brand-dark);--bq-hover:#444546;--bq-active:#1f2026}:where(.endava),:where([bq-theme=endava]){--bq-font-family:"Poppins",sans-serif;--bq-white:#fafbfb;--bq-black:#030406;--bq-neutral-50:var(--bq-endava-grey-50);--bq-neutral-100:var(--bq-endava-grey-100);--bq-neutral-200:var(--bq-endava-grey-200);--bq-neutral-300:var(--bq-endava-grey-300);--bq-neutral-400:var(--bq-endava-grey-400);--bq-neutral-500:var(--bq-endava-grey-500);--bq-neutral-600:var(--bq-endava-grey-600);--bq-neutral-700:var(--bq-endava-grey-700);--bq-neutral-800:var(--bq-endava-grey-800);--bq-neutral-900:var(--bq-endava-grey-900);--bq-neutral-950:var(--bq-endava-grey-950);--bq-neutral-1000:var(--bq-endava-grey-1000);--bq-brand-light:var(--bq-endava-orange-100);--bq-brand:var(--bq-endava-orange-600);--bq-brand-dark:var(--bq-endava-orange-1000);--bq-accent-light:var(--bq-endava-orange-100);--bq-accent:var(--bq-endava-orange-600);--bq-accent-dark:var(--bq-endava-orange-1000);--bq-success-light:var(--bq-green-100);--bq-success:var(--bq-green-600);--bq-success-dark:var(--bq-green-1000);--bq-danger-light:var(--bq-corai-100);--bq-danger:var(--bq-corai-600);--bq-danger-dark:var(--bq-corai-1000);--bq-warning-light:var(--bq-yellow-100);--bq-warning:var(--bq-yellow-600);--bq-warning-dark:var(--bq-yellow-1000);--bq-info-light:var(--bq-blue-100);--bq-info:var(--bq-blue-600);--bq-info-dark:var(--bq-blue-1000);--bq-focus:var(--bq-endava-orange-600);--bq-data-01:var(--bq-brand);--bq-data-02:#af0cd8;--bq-data-03:#0ca8d8;--bq-data-04:var(--bq-teal-600);--bq-data-05:var(--bq-yellow-600);--bq-data-06:var(--bq-orange-600);--bq-data-07:var(--bq-blue-600);--bq-data-08:var(--bq-red-600);--bq-data-09:var(--bq-purple-600);--bq-data-10:#394b56;--bq-data-11:var(--bq-black);--bq-data-12:var(--bq-white)}.endava.light,.endava:not([bq-mode]),[bq-theme=endava]:not([bq-mode]),[bq-theme=endava][bq-mode=light]{--bq-background--primary:var(--bq-white);--bq-background--secondary:var(--bq-neutral-100);--bq-background--tertiary:var(--bq-neutral-200);--bq-background--alt:var(--bq-neutral-300);--bq-background--inverse:var(--bq-neutral-900);--bq-background--brand:var(--bq-brand);--bq-background--overlay:var(--bq-neutral-900);--bq-icon--primary:var(--bq-neutral-800);--bq-icon--secondary:var(--bq-neutral-600);--bq-icon--inverse:var(--bq-neutral-50);--bq-icon--brand:var(--bq-brand);--bq-icon--alt:var(--bq-white);--bq-icon--info:var(--bq-info);--bq-icon--success:var(--bq-success);--bq-icon--warning:var(--bq-warning);--bq-icon--danger:var(--bq-danger);--bq-stroke--primary:var(--bq-neutral-200);--bq-stroke--secondary:var(--bq-neutral-600);--bq-stroke--tertiary:var(--bq-neutral-900);--bq-stroke--inverse:var(--bq-white);--bq-stroke--brand:var(--bq-brand);--bq-stroke--alt:var(--bq-neutral-50);--bq-stroke--brand-alt:var(--bq-brand-light);--bq-stroke--success:var(--bq-success);--bq-stroke--warning:var(--bq-warning);--bq-stroke--danger:var(--bq-danger);--bq-stroke--info:var(--bq-info);--bq-text--primary:var(--bq-neutral-800);--bq-text--secondary:var(--bq-neutral-600);--bq-text--inverse:var(--bq-neutral-50);--bq-text--brand:var(--bq-brand);--bq-text--alt:var(--bq-white);--bq-text--info:var(--bq-info);--bq-text--success:var(--bq-success);--bq-text--warning:var(--bq-warning);--bq-text--danger:var(--bq-danger);--bq-ui--primary:var(--bq-white);--bq-ui--secondary:var(--bq-neutral-100);--bq-ui--tertiary:var(--bq-neutral-500);--bq-ui--inverse:var(--bq-neutral-900);--bq-ui--alt:var(--bq-neutral-50);--bq-ui--brand-alt:var(--bq-brand-light);--bq-ui--brand:var(--bq-brand);--bq-ui--success:var(--bq-success);--bq-ui--success-alt:var(--bq-success-light);--bq-ui--warning:var(--bq-warning);--bq-ui--warning-alt:var(--bq-warning-light);--bq-ui--danger:var(--bq-danger);--bq-ui--danger-alt:var(--bq-danger-light);--bq-ui--info:var(--bq-info);--bq-ui--info-alt:var(--bq-info-light);--bq-hover:#444546;--bq-active:#1f2026}.endava.dark,[bq-theme=endava][bq-mode=dark]{--bq-background--primary:var(--bq-neutral-1000);--bq-background--secondary:var(--bq-neutral-900);--bq-background--tertiary:var(--bq-neutral-800);--bq-background--alt:var(--bq-neutral-700);--bq-background--inverse:var(--bq-neutral-600);--bq-background--brand:var(--bq-brand);--bq-background--overlay:var(--bq-neutral-900);--bq-icon--primary:var(--bq-neutral-100);--bq-icon--secondary:var(--bq-neutral-400);--bq-icon--inverse:var(--bq-neutral-800);--bq-icon--brand:var(--bq-brand);--bq-icon--alt:var(--bq-white);--bq-icon--info:var(--bq-info);--bq-icon--success:var(--bq-success);--bq-icon--warning:var(--bq-warning);--bq-icon--danger:var(--bq-danger);--bq-stroke--primary:var(--bq-neutral-900);--bq-stroke--secondary:var(--bq-neutral-700);--bq-stroke--tertiary:var(--bq-neutral-400);--bq-stroke--inverse:var(--bq-neutral-950);--bq-stroke--brand:var(--bq-brand);--bq-stroke--brand-alt:var(--bq-brand-dark);--bq-stroke--alt:var(--bq-neutral-1000);--bq-stroke--success:var(--bq-success);--bq-stroke--warning:var(--bq-warning);--bq-stroke--danger:var(--bq-danger);--bq-stroke--info:var(--bq-info);--bq-text--primary:var(--bq-neutral-100);--bq-text--secondary:var(--bq-neutral-400);--bq-text--inverse:var(--bq-neutral-800);--bq-text--brand:var(--bq-brand);--bq-text--alt:var(--bq-neutral-white);--bq-text--info:var(--bq-info);--bq-text--success:var(--bq-success);--bq-text--warning:var(--bq-warning);--bq-text--danger:var(--bq-danger);--bq-ui--primary:var(--bq-neutral-900);--bq-ui--secondary:var(--bq-neutral-950);--bq-ui--tertiary:var(--bq-neutral-700);--bq-ui--inverse:var(--bq-neutral-100);--bq-ui--brand:var(--bq-brand);--bq-ui--brand-alt:var(--bq-brand-dark);--bq-ui--alt:var(--bq-neutral-950);--bq-ui--success:var(--bq-success);--bq-ui--success-alt:var(--bq-success-dark);--bq-ui--warning:var(--bq-warning);--bq-ui--warning-alt:var(--bq-warning-dark);--bq-ui--danger:var(--bq-danger);--bq-ui--danger-alt:var(--bq-danger-dark);--bq-ui--info:var(--bq-info);--bq-ui--info-alt:var(--bq-info-dark);--bq-hover:#444546;--bq-active:#1f2026}.visible{visibility:visible}.invisible{visibility:hidden}.fixed{position:fixed}.sticky{position:sticky}.flex{display:flex}.flex-col{flex-direction:column}.items-center{align-items:center}.justify-end{justify-content:flex-end}.gap-\\[--bq-dialog--content-footer-gap\\]{gap:var(--bq-dialog--content-footer-gap)}.gap-m{gap:var(--bq-spacing-m)}.gap-xs{gap:var(--bq-spacing-xs)}.rounded-\\[--bq-dialog--border-radius\\]{border-radius:var(--bq-dialog--border-radius)}.border-\\[length\\:--bq-dialog--border-width\\]{border-width:var(--bq-dialog--border-width)}.border-none{border-style:none}.border-\\[color\\:--bq-dialog--border-color\\]{border-color:var(--bq-dialog--border-color)}.bg-\\[--bq-dialog--background-backdrop\\]{background-color:var(--bq-dialog--background-backdrop)}.bg-\\[--bq-dialog--background\\]{background-color:var(--bq-dialog--background)}.text-\\[--bq-dialog--text-color\\]{color:var(--bq-dialog--text-color)}.opacity-0{opacity:0}.opacity-60{opacity:.6}.shadow-\\[shadow\\:--bq-dialog--box-shadow\\]{--tw-shadow:var(--bq-dialog--box-shadow);--tw-shadow-colored:var(--bq-dialog--box-shadow);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.transition-\\[opacity\\]{transition-duration:.15s;transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-300{transition-duration:.3s}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.is-\\[90vw\\]{inline-size:90vw}.is-full{inline-size:100%}.p-b-0{padding-block:0}.p-b-\\[--bq-dialog--padding\\]{padding-block:var(--bq-dialog--padding)}.p-be-0{padding-block-end:0}.p-bs-0{padding-block-start:0}.p-i-\\[--bq-dialog--padding\\]{padding-inline:var(--bq-dialog--padding)}.inset-bs-0{inset-block-start:0}.inset-bs-\\[100\\%\\]{inset-block-start:100%}@-webkit-keyframes fade-in{0%{opacity:0}}@keyframes fade-in{0%{opacity:0}}@-webkit-keyframes slide-in{0%{-webkit-transform:translateY(10px);transform:translateY(10px)}}@keyframes slide-in{0%{-webkit-transform:translateY(10px);transform:translateY(10px)}}@-webkit-keyframes spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}@keyframes spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}::-ms-backdrop{--bq-dialog--background:var(--bq-ui--primary);--bq-dialog--background-backdrop:var(--bq-background--overlay);--bq-dialog--text-color:var(--bq-text--primary);--bq-dialog--box-shadow:var(--bq-box-shadow--l);--bq-dialog--border-color:transparent;--bq-dialog--border-radius:var(--bq-radius--m);--bq-dialog--border-style:none;--bq-dialog--border-width:unset;--bq-dialog--padding:var(--bq-spacing-l);--bq-dialog--content-footer-gap:var(--bq-spacing-l);--bq-dialog--title-body-gap:var(--bq-spacing-s);--bq-dialog--width-small:320px;--bq-dialog--width-medium:480px;--bq-dialog--width-large:640px;--bq-dialog-z-index:10}::backdrop,:host{--bq-dialog--background:var(--bq-ui--primary);--bq-dialog--background-backdrop:var(--bq-background--overlay);--bq-dialog--text-color:var(--bq-text--primary);--bq-dialog--box-shadow:var(--bq-box-shadow--l);--bq-dialog--border-color:transparent;--bq-dialog--border-radius:var(--bq-radius--m);--bq-dialog--border-style:none;--bq-dialog--border-width:unset;--bq-dialog--padding:var(--bq-spacing-l);--bq-dialog--content-footer-gap:var(--bq-spacing-l);--bq-dialog--title-body-gap:var(--bq-spacing-s);--bq-dialog--width-small:320px;--bq-dialog--width-medium:480px;--bq-dialog--width-large:640px;--bq-dialog-z-index:10}:host{visibility:hidden!important}:host(.bq-dialog--open){visibility:visible!important}.bq-dialog{--tw-shadow:var(--bq-dialog--box-shadow);--tw-shadow-colored:var(--bq-dialog--box-shadow);background-color:var(--bq-dialog--background);border-color:var(--bq-dialog--border-color);border-radius:var(--bq-dialog--border-radius);border-style:var(--bq-dialog--border-style);border-width:var(--bq-dialog--border-width);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:var(--bq-dialog--text-color);display:flex;flex-direction:column;gap:var(--bq-dialog--content-footer-gap);inline-size:90vw;padding-block:0;padding-inline:0;position:fixed}@media (min-width:640px){.bq-dialog.small{inline-size:var(--bq-dialog--width-small)}.bq-dialog.medium{inline-size:var(--bq-dialog--width-medium)}.bq-dialog.large{inline-size:var(--bq-dialog--width-large)}}.bq-dialog::-ms-backdrop{background-color:var(--bq-dialog--background-backdrop);opacity:0;transition-duration:.3s;transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1)}.bq-dialog::backdrop{background-color:var(--bq-dialog--background-backdrop);opacity:0;transition-duration:.3s;transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1)}.bq-dialog[open]::-ms-backdrop{opacity:.6}.bq-dialog[open]::backdrop{opacity:.6}.bq-dialog--header{gap:var(--bq-spacing-m);inset-block-start:0;padding-block:var(--bq-dialog--padding);padding-block-end:0;padding-inline:var(--bq-dialog--padding)}.bq-dialog--footer,.bq-dialog--header{align-items:center;display:flex;position:sticky}.bq-dialog--footer{gap:var(--bq-spacing-xs);inline-size:100%;inset-block-start:100%;justify-content:flex-end;padding-block:var(--bq-dialog--padding);padding-block-start:0;padding-inline:var(--bq-dialog--padding)}.bq-dialog--close{--bq-radius--m:var(--bq-radius--s);--bq-button--small-paddingX:var(--bq-spacing-xs2);--bq-button--small-paddingY:var(--bq-spacing-xs2)}.bq-dialog--close::part(button){border-style:none}@media (min-width:640px){.sm\\:is-\\[--bq-dialog--width-large\\]{inline-size:var(--bq-dialog--width-large)}.sm\\:is-\\[--bq-dialog--width-medium\\]{inline-size:var(--bq-dialog--width-medium)}.sm\\:is-\\[--bq-dialog--width-small\\]{inline-size:var(--bq-dialog--width-small)}}.scale-100,.scale-90{--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.static{position:static}.m-auto{margin:auto}.\\!hidden{display:none!important}.hidden{display:none}.flex-1{flex:1 1 0%}.scale-100{--tw-scale-x:1;--tw-scale-y:1}.scale-90{--tw-scale-x:.9;--tw-scale-y:.9}.cursor-pointer{cursor:pointer}.justify-between{justify-content:space-between}.gap-\\[--bq-dialog--title-body-gap\\]{gap:var(--bq-dialog--title-body-gap)}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.bg-ui-alt{background-color:var(--bq-ui--alt)}.opacity-100{opacity:1}.transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.\\!p-b-s{padding-block:var(--bq-spacing-s)!important}.\\!p-be-\\[--bq-dialog--padding\\]{padding-block-end:var(--bq-dialog--padding)!important}.inset-be-\\[50\\%\\]{inset-block-end:50%}.inset-bs-\\[50\\%\\]{inset-block-start:50%}.focus-visible\\:outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.block{display:block}.focus{outline:var(--bq-ring-width,2px) solid var(--bq-ring-color-focus,var(--bq-focus));outline-offset:var(--bq-ring-offset-width,1px)}.text-\\[--bq-icon--color\\]{color:var(--bq-icon--color)}.bs-\\[--bq-icon--size\\]{block-size:var(--bq-icon--size)}.is-\\[--bq-icon--size\\]{inline-size:var(--bq-icon--size)}';const l=class{constructor(e){a(this,e);this.bqCancel=r(this,"bqCancel");this.bqClose=r(this,"bqClose");this.bqOpen=r(this,"bqOpen");this.bqAfterOpen=r(this,"bqAfterOpen");this.bqAfterClose=r(this,"bqAfterClose")}dialogElem;contentElem;footerElem;closeSlotElem;OPEN_CSS_CLASS="bq-dialog--open";get el(){return e(this)}hasContent=false;hasFooter=false;border="m";disableBackdrop=false;disableCloseEscKeydown=false;disableCloseClickOutside=false;footerAppearance="standard";hideCloseButton=false;open=false;size="medium";checkPropValues(){t(q,"large",this.el,"size");t(d,"standard",this.el,"footerAppearance")}async handleOpenChange(){if(this.open){await this.handleOpen();return}await this.handleClose()}bqCancel;bqClose;bqOpen;bqAfterOpen;bqAfterClose;componentWillLoad(){this.checkPropValues()}componentDidLoad(){this.handleSlotChange();this.handleOpenChange();this.closeSlotElem=this.el.shadowRoot.querySelector('slot[name="button-close"]');this.closeSlotElem?.addEventListener("click",(()=>this.hide()))}disconnectedCallback(){this.closeSlotElem?.removeEventListener("click",(()=>this.hide()))}async handleMouseClick(a){if(!this.open)return;if(!this.dialogElem||this.disableCloseClickOutside)return;if(a.button!==0)return;const r=this.dialogElem.getBoundingClientRect();if(a.clientY<r.top||a.clientY>r.bottom||a.clientX<r.left||a.clientX>r.right){await this.cancel()}}async handleKeyDown(a){const r=a.key==="Escape"||a.key==="Esc";if(!this.open||!this.dialogElem||!r)return;if(this.disableCloseEscKeydown){a.preventDefault();return}await this.cancel()}async show(){const a=this.bqOpen.emit();if(a.defaultPrevented)return;this.open=true}async hide(){const a=this.bqClose.emit();if(a.defaultPrevented)return;this.open=false}async cancel(){const a=this.bqCancel.emit();if(a.defaultPrevented)return;this.open=false}handleClose=async()=>{if(!this.dialogElem)return;await n(this.dialogElem);this.dialogElem.close();this.handleTransitionEnd()};handleOpen=async()=>{if(!this.dialogElem)return;this.el.classList.add(this.OPEN_CSS_CLASS);if(this.disableBackdrop){this.dialogElem.show()}else{this.dialogElem.showModal()}await o(this.dialogElem);this.handleTransitionEnd()};handleTransitionEnd=()=>{if(this.open){this.bqAfterOpen.emit();return}this.bqAfterClose.emit();this.el.classList.remove(this.OPEN_CSS_CLASS)};handleSlotChange=()=>{this.hasContent=i(this.contentElem);this.hasFooter=i(this.footerElem,"footer")};render(){const a={...this.border&&{"--bq-dialog--border-radius":`var(--bq-radius--${this.border})`}};return b("dialog",{key:"9d8cf0b66af7dc40c3f0c9cf84cf703b9dd429a9",style:a,class:{[`bq-dialog hidden ${this.size} m-auto focus-visible:outline-none`]:true,"inset-be-[50%] inset-bs-[50%]":this.disableBackdrop},"data-transition-enter":"transition ease-in duration-300","data-transition-enter-start":"opacity-0 scale-90","data-transition-enter-end":"opacity-100 scale-100","data-transition-leave":"transition ease-out duration-300","data-transition-leave-start":"opacity-100 scale-100","data-transition-leave-end":"opacity-0 scale-90",inert:this.open?undefined:true,ref:a=>this.dialogElem=a,"aria-modal":"true","aria-labelledby":"bq-dialog--title",part:"dialog"},b("main",{key:"74f6c6e7f1a382642e62b17ab8e4547a1890e23c",class:"flex flex-col gap-[--bq-dialog--title-body-gap] overflow-hidden",part:"content"},b("header",{key:"043875e696ef22b93399c8fac575d5d8f284fa8d",class:"bq-dialog--header",part:"header"},b("div",{key:"8f0ba43a9538e7866f36c1363f581759fae78f5d",id:"bq-dialog--title",class:"bq-dialog--title flex flex-1 items-center justify-between",part:"title"},b("slot",{key:"d6af1faefd66f3471c147fcdac6c2fcd8aa3e1ad",name:"title"})),b("slot",{key:"116f4d6b1195236b8a0d8d45cbdb91775793135b",name:"button-close"},!this.hideCloseButton&&b("bq-button",{key:"f2254a4cdc7377da01a5c27bef09f53d4c0272d1",class:"bq-dialog--close",appearance:"text",size:"small"},b("bq-icon",{key:"e4643747cabfb44486f6f5fcceafada6a41182e6",class:"cursor-pointer",name:"x",role:"img",title:"Close"})))),b("div",{key:"0ddc1b342643e35b567d9eb905b8c9b43c878200",class:{"!hidden":!this.hasContent,"overflow-y-auto p-i-[--bq-dialog--padding]":this.hasContent,"!p-be-[--bq-dialog--padding]":!this.hasFooter},ref:a=>this.contentElem=a,part:"body"},b("slot",{key:"94a5cfb12a2187360e610ea9fa4505bc1efde198",onSlotchange:this.handleSlotChange}))),b("footer",{key:"208bdbacedc2ced119df2d3492dc0ec42d768da4",class:{"!hidden":!this.hasFooter,"bq-dialog--footer":this.hasFooter,"bg-ui-alt !p-b-s":this.footerAppearance==="highlight"},ref:a=>this.footerElem=a,part:"footer"},b("slot",{key:"f95a5e225d11b0013e3a7e365634f583f0aeb288",name:"footer",onSlotchange:this.handleSlotChange})))}static get watchers(){return{footerAppearance:["checkPropValues"],size:["checkPropValues"],open:["handleOpenChange"]}}};l.style=s;export{l as bq_dialog};
|
|
6
|
+
//# sourceMappingURL=p-00f6ab04.entry.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["DIALOG_SIZE","DIALOG_FOOTER_APPEARANCE","bqDialogCss","BqDialog","dialogElem","contentElem","footerElem","closeSlotElem","OPEN_CSS_CLASS","hasContent","hasFooter","border","disableBackdrop","disableCloseEscKeydown","disableCloseClickOutside","footerAppearance","hideCloseButton","open","size","checkPropValues","validatePropValue","this","el","handleOpenChange","handleOpen","handleClose","bqCancel","bqClose","bqOpen","bqAfterOpen","bqAfterClose","componentWillLoad","componentDidLoad","handleSlotChange","shadowRoot","querySelector","addEventListener","hide","disconnectedCallback","removeEventListener","handleMouseClick","event","button","rect","getBoundingClientRect","clientY","top","bottom","clientX","left","right","cancel","handleKeyDown","ev","isEscapeKey","key","preventDefault","show","emit","defaultPrevented","async","leave","close","handleTransitionEnd","classList","add","showModal","enter","remove","hasSlotContent","render","style","h","class","inert","undefined","ref","part","id","name","appearance","role","title","mainElem","onSlotchange"],"sources":["../../packages/beeq/src/components/dialog/bq-dialog.types.ts","../../packages/beeq/src/components/dialog/scss/bq-dialog.scss?tag=bq-dialog&encapsulation=shadow","../../packages/beeq/src/components/dialog/bq-dialog.tsx"],"sourcesContent":["export const DIALOG_SIZE = ['small', 'medium', 'large'] as const;\nexport type TDialogSize = (typeof DIALOG_SIZE)[number];\n\nexport const DIALOG_FOOTER_APPEARANCE = ['standard', 'highlight'] as const;\nexport type TDialogFooterAppearance = (typeof DIALOG_FOOTER_APPEARANCE)[number];\n\nexport const DIALOG_BORDER_RADIUS = ['none', 'xs2', 'xs', 's', 'm', 'l', 'full'] as const;\nexport type TDialogBorderRadius = (typeof DIALOG_BORDER_RADIUS)[number];\n","/* -------------------------------------------------------------------------- */\n/* Dialog styles */\n/* -------------------------------------------------------------------------- */\n\n@import './bq-dialog.variables';\n\n:host {\n @apply invisible #{!important};\n}\n\n:host(.bq-dialog--open) {\n @apply visible #{!important};\n}\n\n/* --------------------------------- Dialog --------------------------------- */\n\n.bq-dialog {\n @apply fixed flex flex-col gap-[--bq-dialog--content-footer-gap] p-b-0 p-i-0;\n @apply bg-[--bq-dialog--background] text-[--bq-dialog--text-color] shadow-[shadow:--bq-dialog--box-shadow];\n @apply rounded-[--bq-dialog--border-radius] border-[length:--bq-dialog--border-width] border-[color:--bq-dialog--border-color];\n // If mobile resolution, dialog will be full width\n @apply is-[90vw];\n\n border-style: var(--bq-dialog--border-style);\n\n &.small {\n @apply sm:is-[--bq-dialog--width-small];\n }\n\n &.medium {\n @apply sm:is-[--bq-dialog--width-medium];\n }\n\n &.large {\n @apply sm:is-[--bq-dialog--width-large];\n }\n}\n\n/* ----------------------------- Dialog backdrop ---------------------------- */\n\n.bq-dialog::backdrop {\n @apply bg-[--bq-dialog--background-backdrop] opacity-0 transition-[opacity] duration-300 ease-in-out;\n}\n\n.bq-dialog[open]::backdrop {\n @apply opacity-60;\n}\n\n/* ------------------------------ Dialog header ----------------------------- */\n\n.bq-dialog--header {\n @apply sticky flex items-center gap-m p-b-[--bq-dialog--padding] p-be-0 p-i-[--bq-dialog--padding] inset-bs-0;\n}\n\n/* ------------------------------ Dialog footer ----------------------------- */\n\n.bq-dialog--footer {\n @apply sticky flex items-center justify-end gap-xs is-full p-b-[--bq-dialog--padding] p-bs-0 p-i-[--bq-dialog--padding] inset-bs-[100%];\n}\n\n/* --------------------------- Dialog close button -------------------------- */\n\n.bq-dialog--close {\n --bq-radius--m: theme(borderRadius.s);\n --bq-button--small-paddingX: theme(spacing.xs2);\n --bq-button--small-paddingY: theme(spacing.xs2);\n\n &::part(button) {\n @apply border-none;\n }\n}\n","import { Component, Element, Event, h, Listen, Method, Prop, State, Watch } from '@stencil/core';\nimport type { EventEmitter } from '@stencil/core';\n\nimport { DIALOG_FOOTER_APPEARANCE, DIALOG_SIZE } from './bq-dialog.types';\nimport type { TDialogBorderRadius, TDialogFooterAppearance, TDialogSize } from './bq-dialog.types';\nimport { enter, hasSlotContent, leave, validatePropValue } from '../../shared/utils';\n\n/**\n * The Dialog component is used to display additional content or prompt a user for action.\n * It provides a way to display additional information, options, or controls in a separate, non-obstructive interface element.\n *\n * @example How to use it\n * ```html\n * <bq-dialog footer-appearance=\"standard\" border=\"m\" size=\"medium\">\n * <h5 class=\"bold flex items-center gap-s\" slot=\"title\">\n * <bq-icon name=\"info\" size=\"30\" color=\"text--accent\" role=\"img\" title=\"Info\"></bq-icon>\n * Title\n * </h5>\n * <p>\n * Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's\n * standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a\n * type specimen book.\n * </p>\n * <div class=\"flex gap-xs\" slot=\"footer\">\n * <bq-button appearance=\"link\">Button</bq-button>\n * <bq-button variant=\"ghost\">Button</bq-button>\n * <bq-button variant=\"standard\" slot=\"footer\">Button</bq-button>\n * </div>\n * </bq-dialog>\n * ```\n *\n * @documentation https://www.beeq.design/3d466e231/p/15b6fc-dialog\n * @status stable\n *\n * @dependency bq-button\n * @dependency bq-icon\n *\n * @attr {\"none\" | \"xs2\" | \"xs\" | \"s\" | \"m\" | \"l\" | \"full\"} border - Border radius of the dialog component.\n * @attr {boolean} disable-backdrop - If true, the backdrop overlay won't be shown when the dialog opens.\n * @attr {boolean} disable-close-esc-keydown - If true, the dialog will not close when the [Esc] key is pressed.\n * @attr {boolean} disable-close-click-outside - If true, the dialog will not close when clicking on the backdrop overlay.\n * @attr {\"standard\" | \"highlight\"} footer-appearance - The appearance of the footer.\n * @attr {boolean} hide-close-button - If true, it hides the close button.\n * @attr {boolean} open - If true, the dialog will be shown as open.\n * @attr {\"small\" | \"medium\" | \"large\"} size - The size of the dialog.\n *\n * @method show - Open the dialog.\n * @method hide - Closes the dialog.\n * @method cancel - Dismiss or cancel the dialog.\n *\n * @event bqCancel - Callback handler emitted when the dialog has been canceled or dismissed.\n * @event bqClose - Callback handler emitted when the dialog will close.\n * @event bqOpen - Callback handler emitted when the dialog will open.\n * @event bqAfterOpen - Callback handler emitted when the dialog finish opening.\n * @event bqAfterClose - Callback handler emitted when the dialog finish closing.\n *\n * @slot title - The title content of the dialog.\n * @slot - The body content of the dialog.\n * @slot footer - The footer content of the dialog.\n * @slot button-close - The close button content of the dialog.\n *\n * @part body - The `<main>` that holds the dialog body content.\n * @part button-close - The button that closes the dialog on click.\n * @part content - The `<div>` container that holds the dialog title and body content.\n * @part dialog - The `<dialog>` wrapper container inside the shadow DOM.\n * @part footer - The `<footer>` that holds footer content.\n * @part header - The `<header>` that holds the icon, title, description and close button.\n * @part title - The `<div>` that holds the title content.\n *\n * @cssprop --bq-dialog--background - Dialog background color\n * @cssprop --bq-dialog--background-backdrop - Dialog backdrop background color\n * @cssprop --bq-dialog--box-shadow - Dialog box shadow\n * @cssprop --bq-dialog--border-color - Dialog border color\n * @cssprop --bq-dialog--border-style - Dialog border style\n * @cssprop --bq-dialog--border-width - Dialog border width\n * @cssprop --bq-dialog--border-radius - Dialog border radius\n * @cssprop --bq-dialog--padding - Dialog padding\n * @cssprop --bq-dialog--content-footer-gap - Dialog gap distance between content and footer elements\n * @cssprop --bq-dialog--title-body-gap - Dialog gap distance between title and body elements\n * @cssprop --bq-dialog--width-small - Dialog small width\n * @cssprop --bq-dialog--width-medium - Dialog medium width\n * @cssprop --bq-dialog--width-large - Dialog large width\n * @cssprop --bq-dialog-z-index - Dialog z-index applied when opened\n */\n@Component({\n tag: 'bq-dialog',\n styleUrl: './scss/bq-dialog.scss',\n shadow: true,\n})\nexport class BqDialog {\n // Own Properties\n // ====================\n\n private dialogElem: HTMLDialogElement;\n private contentElem: HTMLElement;\n private footerElem: HTMLElement;\n private closeSlotElem: HTMLElement;\n private OPEN_CSS_CLASS = 'bq-dialog--open';\n\n // Reference to host HTML element\n // ===================================\n @Element() el!: HTMLBqDialogElement;\n\n // State() variables\n // Inlined decorator, alphabetical order\n // =======================================\n\n @State() private hasContent = false;\n @State() private hasFooter = false;\n\n // Public Property API\n // ========================\n\n /** Border radius of the dialog component */\n @Prop({ reflect: true }) border: TDialogBorderRadius = 'm';\n\n /** If true, the backdrop overlay won't be shown when the dialog opens */\n @Prop({ reflect: true }) disableBackdrop = false;\n\n /** If true, the dialog will not close when the [Esc] key is press */\n @Prop({ reflect: true }) disableCloseEscKeydown = false;\n\n /** If true, the dialog will not close when clicking on the backdrop overlay */\n @Prop({ reflect: true }) disableCloseClickOutside = false;\n\n /** The appearance of footer */\n @Prop({ reflect: true }) footerAppearance: TDialogFooterAppearance = 'standard';\n\n /** If true, it hides the close button */\n @Prop({ reflect: true }) hideCloseButton = false;\n\n /** If true, the dialog will be shown as open */\n @Prop({ reflect: true, mutable: true }) open: boolean = false;\n\n /** The size of the dialog */\n @Prop({ reflect: true, mutable: true }) size: TDialogSize = 'medium';\n\n // Prop lifecycle events\n // =======================\n @Watch('footerAppearance')\n @Watch('size')\n checkPropValues() {\n validatePropValue(DIALOG_SIZE, 'large', this.el, 'size');\n validatePropValue(DIALOG_FOOTER_APPEARANCE, 'standard', this.el, 'footerAppearance');\n }\n\n @Watch('open')\n async handleOpenChange() {\n if (this.open) {\n await this.handleOpen();\n return;\n }\n\n await this.handleClose();\n }\n\n // Events section\n // Requires JSDocs for public API documentation\n // ==============================================\n\n /** Callback handler emitted when the dialog has been canceled or dismissed */\n @Event() bqCancel!: EventEmitter<void>;\n\n /** Callback handler emitted when the dialog will close */\n @Event() bqClose!: EventEmitter<void>;\n\n /** Callback handler emitted when the dialog will open */\n @Event() bqOpen!: EventEmitter<void>;\n\n /** Callback handler emitted when the dialog finish opening */\n @Event() bqAfterOpen!: EventEmitter<void>;\n\n /** Callback handler emitted when the dialog finish closing */\n @Event() bqAfterClose!: EventEmitter<void>;\n\n // Component lifecycle events\n // Ordered by their natural call order\n // =====================================\n\n componentWillLoad() {\n this.checkPropValues();\n }\n\n componentDidLoad() {\n this.handleSlotChange();\n this.handleOpenChange();\n\n this.closeSlotElem = this.el.shadowRoot.querySelector('slot[name=\"button-close\"]');\n this.closeSlotElem?.addEventListener('click', () => this.hide());\n }\n\n disconnectedCallback() {\n this.closeSlotElem?.removeEventListener('click', () => this.hide());\n }\n\n // Listeners\n // ==============\n\n @Listen('mousedown', { target: 'window', capture: true })\n async handleMouseClick(event: MouseEvent) {\n if (!this.open) return;\n if (!this.dialogElem || this.disableCloseClickOutside) return;\n // Skip if the mouse button is not the main button\n if (event.button !== 0) return;\n\n const rect = this.dialogElem.getBoundingClientRect();\n if (\n event.clientY < rect.top ||\n event.clientY > rect.bottom ||\n event.clientX < rect.left ||\n event.clientX > rect.right\n ) {\n await this.cancel();\n }\n }\n\n @Listen('keydown', { target: 'window', capture: true })\n async handleKeyDown(ev: KeyboardEvent) {\n const isEscapeKey = ev.key === 'Escape' || ev.key === 'Esc';\n if (!this.open || !this.dialogElem || !isEscapeKey) return;\n\n if (this.disableCloseEscKeydown) {\n ev.preventDefault();\n return;\n }\n\n await this.cancel();\n }\n\n // Public methods API\n // These methods are exposed on the host element.\n // Always use two lines.\n // Public Methods must be async.\n // Requires JSDocs for public API documentation.\n // ===============================================\n\n /** Open the dialog */\n @Method()\n async show() {\n const ev = this.bqOpen.emit();\n if (ev.defaultPrevented) return;\n\n this.open = true;\n }\n\n /** Closes the dialog */\n @Method()\n async hide() {\n const ev = this.bqClose.emit();\n if (ev.defaultPrevented) return;\n\n this.open = false;\n }\n\n /** Dismiss or cancel the dialog */\n @Method()\n async cancel() {\n const ev = this.bqCancel.emit();\n if (ev.defaultPrevented) return;\n\n this.open = false;\n }\n\n // Local methods\n // Internal business logic.\n // These methods cannot be called from the host element.\n // =======================================================\n\n private handleClose = async () => {\n if (!this.dialogElem) return;\n\n await leave(this.dialogElem);\n this.dialogElem.close();\n // Emit bqAfterClose event after the dialog is closed\n this.handleTransitionEnd();\n };\n\n private handleOpen = async () => {\n if (!this.dialogElem) return;\n\n this.el.classList.add(this.OPEN_CSS_CLASS);\n // Show the dialog\n if (this.disableBackdrop) {\n this.dialogElem.show();\n } else {\n this.dialogElem.showModal();\n }\n await enter(this.dialogElem);\n // Emit bqAfterOpen event after the dialog is opened\n this.handleTransitionEnd();\n };\n\n private handleTransitionEnd = () => {\n if (this.open) {\n this.bqAfterOpen.emit();\n return;\n }\n\n this.bqAfterClose.emit();\n this.el.classList.remove(this.OPEN_CSS_CLASS);\n };\n\n private handleSlotChange = () => {\n this.hasContent = hasSlotContent(this.contentElem);\n this.hasFooter = hasSlotContent(this.footerElem, 'footer');\n };\n\n // render() function\n // Always the last one in the class.\n // ===================================\n\n render() {\n const style = {\n ...(this.border && { '--bq-dialog--border-radius': `var(--bq-radius--${this.border})` }),\n };\n\n return (\n <dialog\n style={style}\n class={{\n [`bq-dialog hidden ${this.size} m-auto focus-visible:outline-none`]: true,\n 'inset-be-[50%] inset-bs-[50%]': this.disableBackdrop,\n }}\n data-transition-enter=\"transition ease-in duration-300\"\n data-transition-enter-start=\"opacity-0 scale-90\"\n data-transition-enter-end=\"opacity-100 scale-100\"\n data-transition-leave=\"transition ease-out duration-300\"\n data-transition-leave-start=\"opacity-100 scale-100\"\n data-transition-leave-end=\"opacity-0 scale-90\"\n inert={this.open ? undefined : true}\n ref={(dialogElem) => (this.dialogElem = dialogElem)}\n aria-modal=\"true\"\n aria-labelledby=\"bq-dialog--title\"\n part=\"dialog\"\n >\n <main class=\"flex flex-col gap-[--bq-dialog--title-body-gap] overflow-hidden\" part=\"content\">\n <header class=\"bq-dialog--header\" part=\"header\">\n <div id=\"bq-dialog--title\" class=\"bq-dialog--title flex flex-1 items-center justify-between\" part=\"title\">\n <slot name=\"title\" />\n </div>\n <slot name=\"button-close\">\n {!this.hideCloseButton && (\n <bq-button class=\"bq-dialog--close\" appearance=\"text\" size=\"small\">\n <bq-icon class=\"cursor-pointer\" name=\"x\" role=\"img\" title=\"Close\" />\n </bq-button>\n )}\n </slot>\n </header>\n <div\n class={{\n '!hidden': !this.hasContent,\n 'overflow-y-auto p-i-[--bq-dialog--padding]': this.hasContent,\n '!p-be-[--bq-dialog--padding]': !this.hasFooter,\n }}\n ref={(mainElem) => (this.contentElem = mainElem)}\n part=\"body\"\n >\n <slot onSlotchange={this.handleSlotChange} />\n </div>\n </main>\n <footer\n class={{\n '!hidden': !this.hasFooter,\n 'bq-dialog--footer': this.hasFooter,\n 'bg-ui-alt !p-b-s': this.footerAppearance === 'highlight',\n }}\n ref={(footerElem) => (this.footerElem = footerElem)}\n part=\"footer\"\n >\n <slot name=\"footer\" onSlotchange={this.handleSlotChange} />\n </footer>\n </dialog>\n );\n }\n}\n"],"mappings":";;;;4KAAO,MAAMA,EAAc,CAAC,QAAS,SAAU,SAGxC,MAAMC,EAA2B,CAAC,WAAY,aCHrD,MAAMC,EAAc,61zB,MCyFPC,EAAQ,M,sMAIXC,WACAC,YACAC,WACAC,cACAC,eAAiB,kB,wBAURC,WAAa,MACbC,UAAY,MAMJC,OAA8B,IAG9BC,gBAAkB,MAGlBC,uBAAyB,MAGzBC,yBAA2B,MAG3BC,iBAA4C,WAG5CC,gBAAkB,MAGHC,KAAgB,MAGhBC,KAAoB,SAM5D,eAAAC,GACEC,EAAkBpB,EAAa,QAASqB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AAG,mBAAmBL,MAAM,4DAA4DI,KAAK,SAChGL,EAAA,QAAAjB,IAAA,2CAAMwB,KAAK,WAEbP,EAAM,QAAAjB,IAAA,2CAAAwB,KAAK,iBACP1D,KAAKL,iBACLwD,EAAA,aAAAjB,IAAA,2CAAWkB,MAAM,mBAAmBO,WAAW,OAAO9D,KAAK,SACzDsD,EAAA,WAAAjB,IAAA,2CAASkB,MAAM,iBAAiBM,KAAK,IAAIE,KAAK,MAAMC,MAAM,aAKlEV,EAAA,OAAAjB,IAAA,2CACEkB,MAAO,CACL,WAAYpD,KAAKZ,WACjB,6CAA8CY,KAAKZ,WACnD,gCAAiCY,KAAKX,WAExCkE,IAAMO,GAAc9D,KAAKhB,YAAc8E,EACvCN,KAAK,QAELL,EAAA,QAAAjB,IAAA,2CAAM6B,aAAc/D,KAAKY,qBAG7BuC,EAAA,UAAAjB,IAAA,2CACEkB,MAAO,CACL,WAAYpD,KAAKX,UACjB,oBAAqBW,KAAKX,UAC1B,mBAAoBW,KAAKN,mBAAqB,aAEhD6D,IAAMtE,GAAgBe,KAAKf,WAAaA,EACxCuE,KAAK,UAELL,EAAA,QAAAjB,IAAA,2CAAMwB,KAAK,SAASK,aAAc/D,KAAKY,oB","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["DIALOG_SIZE","DIALOG_FOOTER_APPEARANCE","bqDialogCss","BqDialog","dialogElem","contentElem","footerElem","closeSlotElem","OPEN_CSS_CLASS","hasContent","hasFooter","border","disableBackdrop","disableCloseEscKeydown","disableCloseClickOutside","footerAppearance","hideCloseButton","open","size","checkPropValues","validatePropValue","this","el","handleOpenChange","handleOpen","handleClose","bqCancel","bqClose","bqOpen","bqAfterOpen","bqAfterClose","componentWillLoad","componentDidLoad","handleSlotChange","shadowRoot","querySelector","addEventListener","hide","disconnectedCallback","removeEventListener","handleMouseClick","event","button","rect","getBoundingClientRect","clientY","top","bottom","clientX","left","right","cancel","handleKeyDown","ev","isEscapeKey","key","preventDefault","show","emit","defaultPrevented","async","leave","close","handleTransitionEnd","classList","add","showModal","enter","remove","hasSlotContent","render","style","h","class","inert","undefined","ref","part","id","name","appearance","role","title","mainElem","onSlotchange"],"sources":["../../packages/beeq/src/components/dialog/bq-dialog.types.ts","../../packages/beeq/src/components/dialog/scss/bq-dialog.scss?tag=bq-dialog&encapsulation=shadow","../../packages/beeq/src/components/dialog/bq-dialog.tsx"],"sourcesContent":["export const DIALOG_SIZE = ['small', 'medium', 'large'] as const;\nexport type TDialogSize = (typeof DIALOG_SIZE)[number];\n\nexport const DIALOG_FOOTER_APPEARANCE = ['standard', 'highlight'] as const;\nexport type TDialogFooterAppearance = (typeof DIALOG_FOOTER_APPEARANCE)[number];\n\nexport const DIALOG_BORDER_RADIUS = ['none', 'xs2', 'xs', 's', 'm', 'l', 'full'] as const;\nexport type TDialogBorderRadius = (typeof DIALOG_BORDER_RADIUS)[number];\n","/* -------------------------------------------------------------------------- */\n/* Dialog styles */\n/* -------------------------------------------------------------------------- */\n\n@import './bq-dialog.variables';\n\n:host {\n @apply invisible #{!important};\n}\n\n:host(.bq-dialog--open) {\n @apply visible #{!important};\n}\n\n/* --------------------------------- Dialog --------------------------------- */\n\n.bq-dialog {\n @apply fixed flex flex-col gap-[--bq-dialog--content-footer-gap] p-b-0 p-i-0;\n @apply bg-[--bq-dialog--background] text-[--bq-dialog--text-color] shadow-[shadow:--bq-dialog--box-shadow];\n @apply rounded-[--bq-dialog--border-radius] border-[length:--bq-dialog--border-width] border-[color:--bq-dialog--border-color];\n // If mobile resolution, dialog will be full width\n @apply is-[90vw];\n\n border-style: var(--bq-dialog--border-style);\n\n &.small {\n @apply sm:is-[--bq-dialog--width-small];\n }\n\n &.medium {\n @apply sm:is-[--bq-dialog--width-medium];\n }\n\n &.large {\n @apply sm:is-[--bq-dialog--width-large];\n }\n}\n\n/* ----------------------------- Dialog backdrop ---------------------------- */\n\n.bq-dialog::backdrop {\n @apply bg-[--bq-dialog--background-backdrop] opacity-0 transition-[opacity] duration-300 ease-in-out;\n}\n\n.bq-dialog[open]::backdrop {\n @apply opacity-60;\n}\n\n/* ------------------------------ Dialog header ----------------------------- */\n\n.bq-dialog--header {\n @apply sticky flex items-center gap-m p-b-[--bq-dialog--padding] p-be-0 p-i-[--bq-dialog--padding] inset-bs-0;\n}\n\n/* ------------------------------ Dialog footer ----------------------------- */\n\n.bq-dialog--footer {\n @apply sticky flex items-center justify-end gap-xs is-full p-b-[--bq-dialog--padding] p-bs-0 p-i-[--bq-dialog--padding] inset-bs-[100%];\n}\n\n/* --------------------------- Dialog close button -------------------------- */\n\n.bq-dialog--close {\n --bq-radius--m: theme(borderRadius.s);\n --bq-button--small-paddingX: theme(spacing.xs2);\n --bq-button--small-paddingY: theme(spacing.xs2);\n\n &::part(button) {\n @apply border-none;\n }\n}\n","import { Component, Element, Event, h, Listen, Method, Prop, State, Watch } from '@stencil/core';\nimport type { EventEmitter } from '@stencil/core';\n\nimport { DIALOG_FOOTER_APPEARANCE, DIALOG_SIZE } from './bq-dialog.types';\nimport type { TDialogBorderRadius, TDialogFooterAppearance, TDialogSize } from './bq-dialog.types';\nimport { enter, hasSlotContent, leave, validatePropValue } from '../../shared/utils';\n\n/**\n * The Dialog component is used to display additional content or prompt a user for action.\n * It provides a way to display additional information, options, or controls in a separate, non-obstructive interface element.\n *\n * @example How to use it\n * ```html\n * <bq-dialog footer-appearance=\"standard\" border=\"m\" size=\"medium\">\n * <h5 class=\"bold flex items-center gap-s\" slot=\"title\">\n * <bq-icon name=\"info\" size=\"30\" color=\"text--accent\" role=\"img\" title=\"Info\"></bq-icon>\n * Title\n * </h5>\n * <p>\n * Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's\n * standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a\n * type specimen book.\n * </p>\n * <div class=\"flex gap-xs\" slot=\"footer\">\n * <bq-button appearance=\"link\">Button</bq-button>\n * <bq-button variant=\"ghost\">Button</bq-button>\n * <bq-button variant=\"standard\" slot=\"footer\">Button</bq-button>\n * </div>\n * </bq-dialog>\n * ```\n *\n * @documentation https://www.beeq.design/3d466e231/p/15b6fc-dialog\n * @status stable\n *\n * @dependency bq-button\n * @dependency bq-icon\n *\n * @attr {\"none\" | \"xs2\" | \"xs\" | \"s\" | \"m\" | \"l\" | \"full\"} border - Border radius of the dialog component.\n * @attr {boolean} disable-backdrop - If true, the backdrop overlay won't be shown when the dialog opens.\n * @attr {boolean} disable-close-esc-keydown - If true, the dialog will not close when the [Esc] key is pressed.\n * @attr {boolean} disable-close-click-outside - If true, the dialog will not close when clicking on the backdrop overlay.\n * @attr {\"standard\" | \"highlight\"} footer-appearance - The appearance of the footer.\n * @attr {boolean} hide-close-button - If true, it hides the close button.\n * @attr {boolean} open - If true, the dialog will be shown as open.\n * @attr {\"small\" | \"medium\" | \"large\"} size - The size of the dialog.\n *\n * @method show - Open the dialog.\n * @method hide - Closes the dialog.\n * @method cancel - Dismiss or cancel the dialog.\n *\n * @event bqCancel - Callback handler emitted when the dialog has been canceled or dismissed.\n * @event bqClose - Callback handler emitted when the dialog will close.\n * @event bqOpen - Callback handler emitted when the dialog will open.\n * @event bqAfterOpen - Callback handler emitted when the dialog finish opening.\n * @event bqAfterClose - Callback handler emitted when the dialog finish closing.\n *\n * @slot title - The title content of the dialog.\n * @slot - The body content of the dialog.\n * @slot footer - The footer content of the dialog.\n * @slot button-close - The close button content of the dialog.\n *\n * @part body - The `<main>` that holds the dialog body content.\n * @part button-close - The button that closes the dialog on click.\n * @part content - The `<div>` container that holds the dialog title and body content.\n * @part dialog - The `<dialog>` wrapper container inside the shadow DOM.\n * @part footer - The `<footer>` that holds footer content.\n * @part header - The `<header>` that holds the icon, title, description and close button.\n * @part title - The `<div>` that holds the title content.\n *\n * @cssprop --bq-dialog--background - Dialog background color\n * @cssprop --bq-dialog--background-backdrop - Dialog backdrop background color\n * @cssprop --bq-dialog--box-shadow - Dialog box shadow\n * @cssprop --bq-dialog--border-color - Dialog border color\n * @cssprop --bq-dialog--border-style - Dialog border style\n * @cssprop --bq-dialog--border-width - Dialog border width\n * @cssprop --bq-dialog--border-radius - Dialog border radius\n * @cssprop --bq-dialog--padding - Dialog padding\n * @cssprop --bq-dialog--content-footer-gap - Dialog gap distance between content and footer elements\n * @cssprop --bq-dialog--title-body-gap - Dialog gap distance between title and body elements\n * @cssprop --bq-dialog--width-small - Dialog small width\n * @cssprop --bq-dialog--width-medium - Dialog medium width\n * @cssprop --bq-dialog--width-large - Dialog large width\n * @cssprop --bq-dialog-z-index - Dialog z-index applied when opened\n */\n@Component({\n tag: 'bq-dialog',\n styleUrl: './scss/bq-dialog.scss',\n shadow: true,\n})\nexport class BqDialog {\n // Own Properties\n // ====================\n\n private dialogElem: HTMLDialogElement;\n private contentElem: HTMLElement;\n private footerElem: HTMLElement;\n private closeSlotElem: HTMLElement;\n private OPEN_CSS_CLASS = 'bq-dialog--open';\n\n // Reference to host HTML element\n // ===================================\n @Element() el!: HTMLBqDialogElement;\n\n // State() variables\n // Inlined decorator, alphabetical order\n // =======================================\n\n @State() private hasContent = false;\n @State() private hasFooter = false;\n\n // Public Property API\n // ========================\n\n /** Border radius of the dialog component */\n @Prop({ reflect: true }) border: TDialogBorderRadius = 'm';\n\n /** If true, the backdrop overlay won't be shown when the dialog opens */\n @Prop({ reflect: true }) disableBackdrop = false;\n\n /** If true, the dialog will not close when the [Esc] key is press */\n @Prop({ reflect: true }) disableCloseEscKeydown = false;\n\n /** If true, the dialog will not close when clicking on the backdrop overlay */\n @Prop({ reflect: true }) disableCloseClickOutside = false;\n\n /** The appearance of footer */\n @Prop({ reflect: true }) footerAppearance: TDialogFooterAppearance = 'standard';\n\n /** If true, it hides the close button */\n @Prop({ reflect: true }) hideCloseButton = false;\n\n /** If true, the dialog will be shown as open */\n @Prop({ reflect: true, mutable: true }) open: boolean = false;\n\n /** The size of the dialog */\n @Prop({ reflect: true, mutable: true }) size: TDialogSize = 'medium';\n\n // Prop lifecycle events\n // =======================\n @Watch('footerAppearance')\n @Watch('size')\n checkPropValues() {\n validatePropValue(DIALOG_SIZE, 'large', this.el, 'size');\n validatePropValue(DIALOG_FOOTER_APPEARANCE, 'standard', this.el, 'footerAppearance');\n }\n\n @Watch('open')\n async handleOpenChange() {\n if (this.open) {\n await this.handleOpen();\n return;\n }\n\n await this.handleClose();\n }\n\n // Events section\n // Requires JSDocs for public API documentation\n // ==============================================\n\n /** Callback handler emitted when the dialog has been canceled or dismissed */\n @Event() bqCancel!: EventEmitter<void>;\n\n /** Callback handler emitted when the dialog will close */\n @Event() bqClose!: EventEmitter<void>;\n\n /** Callback handler emitted when the dialog will open */\n @Event() bqOpen!: EventEmitter<void>;\n\n /** Callback handler emitted when the dialog finish opening */\n @Event() bqAfterOpen!: EventEmitter<void>;\n\n /** Callback handler emitted when the dialog finish closing */\n @Event() bqAfterClose!: EventEmitter<void>;\n\n // Component lifecycle events\n // Ordered by their natural call order\n // =====================================\n\n componentWillLoad() {\n this.checkPropValues();\n }\n\n componentDidLoad() {\n this.handleSlotChange();\n this.handleOpenChange();\n\n this.closeSlotElem = this.el.shadowRoot.querySelector('slot[name=\"button-close\"]');\n this.closeSlotElem?.addEventListener('click', () => this.hide());\n }\n\n disconnectedCallback() {\n this.closeSlotElem?.removeEventListener('click', () => this.hide());\n }\n\n // Listeners\n // ==============\n\n @Listen('mousedown', { target: 'window', capture: true })\n async handleMouseClick(event: MouseEvent) {\n if (!this.open) return;\n if (!this.dialogElem || this.disableCloseClickOutside) return;\n // Skip if the mouse button is not the main button\n if (event.button !== 0) return;\n\n const rect = this.dialogElem.getBoundingClientRect();\n if (\n event.clientY < rect.top ||\n event.clientY > rect.bottom ||\n event.clientX < rect.left ||\n event.clientX > rect.right\n ) {\n await this.cancel();\n }\n }\n\n @Listen('keydown', { target: 'window', capture: true })\n async handleKeyDown(ev: KeyboardEvent) {\n const isEscapeKey = ev.key === 'Escape' || ev.key === 'Esc';\n if (!this.open || !this.dialogElem || !isEscapeKey) return;\n\n if (this.disableCloseEscKeydown) {\n ev.preventDefault();\n return;\n }\n\n await this.cancel();\n }\n\n // Public methods API\n // These methods are exposed on the host element.\n // Always use two lines.\n // Public Methods must be async.\n // Requires JSDocs for public API documentation.\n // ===============================================\n\n /** Open the dialog */\n @Method()\n async show() {\n const ev = this.bqOpen.emit();\n if (ev.defaultPrevented) return;\n\n this.open = true;\n }\n\n /** Closes the dialog */\n @Method()\n async hide() {\n const ev = this.bqClose.emit();\n if (ev.defaultPrevented) return;\n\n this.open = false;\n }\n\n /** Dismiss or cancel the dialog */\n @Method()\n async cancel() {\n const ev = this.bqCancel.emit();\n if (ev.defaultPrevented) return;\n\n this.open = false;\n }\n\n // Local methods\n // Internal business logic.\n // These methods cannot be called from the host element.\n // =======================================================\n\n private handleClose = async () => {\n if (!this.dialogElem) return;\n\n await leave(this.dialogElem);\n this.dialogElem.close();\n // Emit bqAfterClose event after the dialog is closed\n this.handleTransitionEnd();\n };\n\n private handleOpen = async () => {\n if (!this.dialogElem) return;\n\n this.el.classList.add(this.OPEN_CSS_CLASS);\n // Show the dialog\n if (this.disableBackdrop) {\n this.dialogElem.show();\n } else {\n this.dialogElem.showModal();\n }\n await enter(this.dialogElem);\n // Emit bqAfterOpen event after the dialog is opened\n this.handleTransitionEnd();\n };\n\n private handleTransitionEnd = () => {\n if (this.open) {\n this.bqAfterOpen.emit();\n return;\n }\n\n this.bqAfterClose.emit();\n this.el.classList.remove(this.OPEN_CSS_CLASS);\n };\n\n private handleSlotChange = () => {\n this.hasContent = hasSlotContent(this.contentElem);\n this.hasFooter = hasSlotContent(this.footerElem, 'footer');\n };\n\n // render() function\n // Always the last one in the class.\n // ===================================\n\n render() {\n const style = {\n ...(this.border && { '--bq-dialog--border-radius': `var(--bq-radius--${this.border})` }),\n };\n\n return (\n <dialog\n style={style}\n class={{\n [`bq-dialog hidden ${this.size} m-auto focus-visible:outline-none`]: true,\n 'inset-be-[50%] inset-bs-[50%]': this.disableBackdrop,\n }}\n data-transition-enter=\"transition ease-in duration-300\"\n data-transition-enter-start=\"opacity-0 scale-90\"\n data-transition-enter-end=\"opacity-100 scale-100\"\n data-transition-leave=\"transition ease-out duration-300\"\n data-transition-leave-start=\"opacity-100 scale-100\"\n data-transition-leave-end=\"opacity-0 scale-90\"\n inert={this.open ? undefined : true}\n ref={(dialogElem) => (this.dialogElem = dialogElem)}\n aria-modal=\"true\"\n aria-labelledby=\"bq-dialog--title\"\n part=\"dialog\"\n >\n <main class=\"flex flex-col gap-[--bq-dialog--title-body-gap] overflow-hidden\" part=\"content\">\n <header class=\"bq-dialog--header\" part=\"header\">\n <div id=\"bq-dialog--title\" class=\"bq-dialog--title flex flex-1 items-center justify-between\" part=\"title\">\n <slot name=\"title\" />\n </div>\n <slot name=\"button-close\">\n {!this.hideCloseButton && (\n <bq-button class=\"bq-dialog--close\" appearance=\"text\" size=\"small\">\n <bq-icon class=\"cursor-pointer\" name=\"x\" role=\"img\" title=\"Close\" />\n </bq-button>\n )}\n </slot>\n </header>\n <div\n class={{\n '!hidden': !this.hasContent,\n 'overflow-y-auto p-i-[--bq-dialog--padding]': this.hasContent,\n '!p-be-[--bq-dialog--padding]': !this.hasFooter,\n }}\n ref={(mainElem) => (this.contentElem = mainElem)}\n part=\"body\"\n >\n <slot onSlotchange={this.handleSlotChange} />\n </div>\n </main>\n <footer\n class={{\n '!hidden': !this.hasFooter,\n 'bq-dialog--footer': this.hasFooter,\n 'bg-ui-alt !p-b-s': this.footerAppearance === 'highlight',\n }}\n ref={(footerElem) => (this.footerElem = footerElem)}\n part=\"footer\"\n >\n <slot name=\"footer\" onSlotchange={this.handleSlotChange} />\n </footer>\n </dialog>\n );\n }\n}\n"],"mappings":";;;;4KAAO,MAAMA,EAAc,CAAC,QAAS,SAAU,SAGxC,MAAMC,EAA2B,CAAC,WAAY,aCHrD,MAAMC,EAAc,o9zB,MCyFPC,EAAQ,M,sMAIXC,WACAC,YACAC,WACAC,cACAC,eAAiB,kB,wBAURC,WAAa,MACbC,UAAY,MAMJC,OAA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AAK,UAELL,EAAA,QAAAjB,IAAA,2CAAMkB,MAAM,kEAAkEI,KAAK,WACjFL,EAAA,UAAAjB,IAAA,2CAAQkB,MAAM,oBAAoBI,KAAK,UACrCL,EAAK,OAAAjB,IAAA,2CAAAuB,GAAG,mBAAmBL,MAAM,4DAA4DI,KAAK,SAChGL,EAAA,QAAAjB,IAAA,2CAAMwB,KAAK,WAEbP,EAAM,QAAAjB,IAAA,2CAAAwB,KAAK,iBACP1D,KAAKL,iBACLwD,EAAA,aAAAjB,IAAA,2CAAWkB,MAAM,mBAAmBO,WAAW,OAAO9D,KAAK,SACzDsD,EAAA,WAAAjB,IAAA,2CAASkB,MAAM,iBAAiBM,KAAK,IAAIE,KAAK,MAAMC,MAAM,aAKlEV,EAAA,OAAAjB,IAAA,2CACEkB,MAAO,CACL,WAAYpD,KAAKZ,WACjB,6CAA8CY,KAAKZ,WACnD,gCAAiCY,KAAKX,WAExCkE,IAAMO,GAAc9D,KAAKhB,YAAc8E,EACvCN,KAAK,QAELL,EAAA,QAAAjB,IAAA,2CAAM6B,aAAc/D,KAAKY,qBAG7BuC,EAAA,UAAAjB,IAAA,2CACEkB,MAAO,CACL,WAAYpD,KAAKX,UACjB,oBAAqBW,KAAKX,UAC1B,mBAAoBW,KAAKN,mBAAqB,aAEhD6D,IAAMtE,GAAgBe,KAAKf,WAAaA,EACxCuE,KAAK,UAELL,EAAA,QAAAjB,IAAA,2CAAMwB,KAAK,SAASK,aAAc/D,KAAKY,oB","ignoreList":[]}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Built by Endavans
|
|
3
|
+
* © https://beeq.design - Apache 2 License.
|
|
4
|
+
*/
|
|
5
|
+
import{r,c as a,a as b,h as e}from"./p-C4jSqdYP.js";import{i as t}from"./p-Ci39rxuU.js";import"./p-CVMdKx0v.js";const q='.transform{--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.breadcrumb-item,.shadow-\\[shadow\\:--bq-breadcrumb-item--box-shadow\\]{--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000}::backdrop,:root{--bq-blue-100:#e7f0fd;--bq-blue-200:#d0e2fb;--bq-blue-300:#a1c5f7;--bq-blue-400:#73a8f3;--bq-blue-500:#448bef;--bq-blue-600:#156eeb;--bq-blue-700:#1158bc;--bq-blue-800:#0d428d;--bq-blue-900:#082c5e;--bq-blue-1000:#04162f;--bq-corai-100:#fff2f2;--bq-corai-200:#ffe6e6;--bq-corai-300:#ffccce;--bq-corai-400:#ffb3b5;--bq-corai-500:#ff999d;--bq-corai-600:#ff8084;--bq-corai-700:#cc666a;--bq-corai-800:#994d4f;--bq-corai-900:#663335;--bq-corai-1000:#331a1a;--bq-cyan-100:#e8f7fb;--bq-cyan-200:#d2f0f8;--bq-cyan-300:#a5e1f1;--bq-cyan-400:#78d1e9;--bq-cyan-500:#4bc2e2;--bq-cyan-600:#1eb3db;--bq-cyan-700:#188faf;--bq-cyan-800:#126b83;--bq-cyan-900:#0c4858;--bq-cyan-1000:#06242c;--bq-gold-100:#fbf4ec;--bq-gold-200:#f7e9da;--bq-gold-300:#f0d3b6;--bq-gold-400:#e8bc91;--bq-gold-500:#e1a66d;--bq-gold-600:#d99048;--bq-gold-700:#ae733a;--bq-gold-800:#82562b;--bq-gold-900:#573a1d;--bq-gold-1000:#2b1d0e;--bq-green-100:#e8f8ef;--bq-green-200:#d2f1e0;--bq-green-300:#a5e3c1;--bq-green-400:#78d5a1;--bq-green-500:#4bc782;--bq-green-600:#1eb963;--bq-green-700:#18944f;--bq-green-800:#126f3b;--bq-green-900:#0c4a28;--bq-green-1000:#062514;--bq-grey-100:#f1f2f4;--bq-grey-200:#e7e8eb;--bq-grey-300:#caccd2;--bq-grey-400:#a6aab3;--bq-grey-50:#f6f6f8;--bq-grey-500:#898e99;--bq-grey-600:#646a77;--bq-grey-700:#3f4350;--bq-grey-800:#2a2c35;--bq-grey-900:#1c1d23;--bq-grey-950:#15161a;--bq-grey-1000:#0d0e11;--bq-indigo-100:#edecfc;--bq-indigo-200:#dcdafa;--bq-indigo-300:#b9b5f5;--bq-indigo-400:#9590ef;--bq-indigo-500:#726bea;--bq-indigo-600:#4f46e5;--bq-indigo-700:#3f38b7;--bq-indigo-800:#2f2a89;--bq-indigo-900:#201c5c;--bq-indigo-1000:#100e2e;--bq-iris-100:#e9f0ff;--bq-iris-200:#d6e0ff;--bq-iris-300:#b2c0fe;--bq-iris-400:#8691f8;--bq-iris-500:#6061ee;--bq-iris-600:#4f46e5;--bq-iris-700:#413abd;--bq-iris-800:#332e95;--bq-iris-900:#26216d;--bq-iris-1000:#181545;--bq-lime-100:#f5fae8;--bq-lime-200:#ecf6d2;--bq-lime-300:#d9eda5;--bq-lime-400:#c5e379;--bq-lime-500:#b2da4c;--bq-lime-600:#9fd11f;--bq-lime-700:#7fa719;--bq-lime-800:#5f7d13;--bq-lime-900:#40540c;--bq-lime-1000:#202a06;--bq-magenta-100:#fce7f4;--bq-magenta-200:#f9cfea;--bq-magenta-300:#f39fd6;--bq-magenta-400:#ee6fbf;--bq-magenta-500:#e83fab;--bq-magenta-600:#de1395;--bq-magenta-700:#b20f77;--bq-magenta-800:#850c59;--bq-magenta-900:#58083c;--bq-magenta-1000:#2c041e;--bq-neutral-white:#fbfbfc;--bq-neutral-black:#060708;--bq-orange-100:#fbf0e9;--bq-orange-200:#f8e1d4;--bq-orange-300:#f1c2a8;--bq-orange-400:#eaa47d;--bq-orange-500:#e38551;--bq-orange-600:#dc6726;--bq-orange-700:#b0521e;--bq-orange-800:#843e17;--bq-orange-900:#58290f;--bq-orange-1000:#2c1508;--bq-purple-100:#efebf8;--bq-purple-200:#e0d7f2;--bq-purple-300:#c1afe5;--bq-purple-400:#a388d8;--bq-purple-500:#8460cb;--bq-purple-600:#6538be;--bq-purple-700:#512d98;--bq-purple-800:#3d2272;--bq-purple-900:#28164c;--bq-purple-1000:#140b26;--bq-red-100:#fce7ea;--bq-red-200:#f9d1d5;--bq-red-300:#f3a2ac;--bq-red-400:#ed7482;--bq-red-500:#e74559;--bq-red-600:#e1172f;--bq-red-700:#b41226;--bq-red-800:#870e1c;--bq-red-900:#5a0913;--bq-red-1000:#2d0509;--bq-sky-100:#eff4fb;--bq-sky-200:#dfeaf8;--bq-sky-300:#bfd5f1;--bq-sky-400:#9ec1e9;--bq-sky-500:#7eace2;--bq-sky-600:#5e97db;--bq-sky-700:#4b79af;--bq-sky-800:#385b83;--bq-sky-900:#263c58;--bq-sky-1000:#131e2c;--bq-teal-100:#e5f7f5;--bq-teal-200:#ccf0eb;--bq-teal-300:#99e1d8;--bq-teal-400:#66d2c4;--bq-teal-500:#33c3b1;--bq-teal-600:#00b49d;--bq-teal-700:#00907e;--bq-teal-800:#006c5e;--bq-teal-900:#00483f;--bq-teal-1000:#00241f;--bq-volcano-100:#feede7;--bq-volcano-200:#fddbd1;--bq-volcano-300:#fbb8a3;--bq-volcano-400:#fa9474;--bq-volcano-500:#f87146;--bq-volcano-600:#f64d18;--bq-volcano-700:#c53e13;--bq-volcano-800:#942e0e;--bq-volcano-900:#621f0a;--bq-volcano-1000:#310f05;--bq-yellow-100:#fefbe7;--bq-yellow-200:#fcf6d0;--bq-yellow-300:#faeea0;--bq-yellow-400:#f7e571;--bq-yellow-500:#f5dd41;--bq-yellow-600:#f2d412;--bq-yellow-700:#c2aa0e;--bq-yellow-800:#917f0b;--bq-yellow-900:#615507;--bq-yellow-1000:#302a04;--bq-endava-grey-50:#f7f7f8;--bq-endava-grey-100:#e4e6e7;--bq-endava-grey-200:#b5babe;--bq-endava-grey-300:#949ca1;--bq-endava-grey-400:#737d84;--bq-endava-grey-500:#525f67;--bq-endava-grey-600:#30404b;--bq-endava-grey-700:#2b3942;--bq-endava-grey-800:#263139;--bq-endava-grey-900:#192b37;--bq-endava-grey-950:#151b1e;--bq-endava-grey-1000:#0f1316;--bq-endava-neutral-white:#fafbfb;--bq-endava-neutral-black:#060708;--bq-endava-orange-100:#fef3f1;--bq-endava-orange-200:#fbd6d1;--bq-endava-orange-300:#fab7af;--bq-endava-orange-400:#fa988b;--bq-endava-orange-500:#fc7866;--bq-endava-orange-600:#ff5640;--bq-endava-orange-700:#ce4a39;--bq-endava-orange-800:#a03d30;--bq-endava-orange-900:#722e25;--bq-endava-orange-1000:#471e19}*,:after,:before{box-sizing:border-box}*{font:inherit;margin:0}ol[role=list],ul[role=list]{list-style-type:none}html{text-size-adjust:none;font-family:var(--bq-font-family);font-size:var(--bq-font-size--m)}html:focus-within{scroll-behavior:smooth}body{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;background-color:var(--bq-background--primary);color:var(--bq-text--primary);line-height:var(--bq-font-line-height--regular);min-height:100vb;text-rendering:optimizeSpeed}a:not([class]){text-decoration-skip-ink:auto}canvas,img,picture,svg,video{display:block;max-width:100%}button,input,select,textarea{font:inherit}h1,h2,h3,h4,h5,h6,p{overflow-wrap:break-word}@media (prefers-reduced-motion:reduce){html:focus-within{scroll-behavior:auto}*,:after,:before{animation-duration:.01ms!important;animation-iteration-count:1!important;scroll-behavior:auto;transition-duration:.01ms!important}}:where(:root){--bq-white:#fff;--bq-black:#060708;--bq-neutral-50:var(--bq-grey-50);--bq-neutral-100:var(--bq-grey-100);--bq-neutral-200:var(--bq-grey-200);--bq-neutral-300:var(--bq-grey-300);--bq-neutral-400:var(--bq-grey-400);--bq-neutral-500:var(--bq-grey-500);--bq-neutral-600:var(--bq-grey-600);--bq-neutral-700:var(--bq-grey-700);--bq-neutral-800:var(--bq-grey-800);--bq-neutral-900:var(--bq-grey-900);--bq-neutral-950:var(--bq-grey-950);--bq-neutral-1000:var(--bq-grey-1000);--bq-brand-light:var(--bq-iris-100);--bq-brand:var(--bq-iris-600);--bq-brand-dark:var(--bq-iris-1000);--bq-accent-light:var(--bq-purple-100);--bq-accent:var(--bq-purple-600);--bq-accent-dark:var(--bq-purple-1000);--bq-success-light:var(--bq-teal-100);--bq-success:var(--bq-teal-600);--bq-success-dark:var(--bq-teal-1000);--bq-danger-light:var(--bq-red-100);--bq-danger:var(--bq-red-600);--bq-danger-dark:var(--bq-red-1000);--bq-warning-light:var(--bq-gold-100);--bq-warning:var(--bq-gold-600);--bq-warning-dark:var(--bq-gold-1000);--bq-info-light:var(--bq-iris-100);--bq-info:var(--bq-iris-600);--bq-info-dark:var(--bq-iris-1000);--bq-focus:var(--bq-iris-600);--bq-data-01:var(--bq-brand);--bq-data-02:var(--bq-purple-600);--bq-data-03:var(--bq-magenta-600);--bq-data-04:var(--bq-cyan-600);--bq-data-05:var(--bq-teal-600);--bq-data-06:var(--bq-orange-600);--bq-data-07:var(--bq-yellow-600);--bq-data-08:var(--bq-red-600);--bq-data-09:var(--bq-blue-600);--bq-data-10:var(--bq-grey-600);--bq-data-11:var(--bq-black);--bq-data-12:var(--bq-white);--bq-radius--none:0;--bq-radius--xs2:0.125rem;--bq-radius--xs:0.25rem;--bq-radius--s:0.5rem;--bq-radius--m:0.75rem;--bq-radius--l:1.5rem;--bq-radius--full:9999px;--bq-box-shadow--xs:0 2px 0 rgba(0,0,0,.016);--bq-box-shadow--s:0 8px 24px rgba(0,0,0,.04);--bq-box-shadow--m:0 10px 48px -16px rgba(0,0,0,.12);--bq-box-shadow--l:0 20px 58px -16px rgba(0,0,0,.16);--bq-font-family:"Outfit",sans-serif;--bq-font-size--xs:0.75rem;--bq-font-size--s:0.875rem;--bq-font-size--m:1rem;--bq-font-size--l:1.125rem;--bq-font-size--xl:1.5rem;--bq-font-size--xxl:2rem;--bq-font-size--xxl2:2.5rem;--bq-font-size--xxl3:3rem;--bq-font-size--xxl4:3.5rem;--bq-font-size--xxl5:4rem;--bq-font-weight--thin:100;--bq-font-weight--light:300;--bq-font-weight--regular:400;--bq-font-weight--medium:500;--bq-font-weight--semibold:600;--bq-font-weight--bold:700;--bq-font-line-height--small:1.2;--bq-font-line-height--regular:1.5;--bq-font-line-height--large:1.5;--bq-spacing-xs3:0.125rem;--bq-spacing-xs2:0.25rem;--bq-spacing-xs:0.5rem;--bq-spacing-s:0.75rem;--bq-spacing-m:1rem;--bq-spacing-l:1.5rem;--bq-spacing-xl:2rem;--bq-spacing-xxl:2.5rem;--bq-spacing-xxl2:3.5rem;--bq-spacing-xxl3:4rem;--bq-spacing-xxl4:4.5rem;--bq-stroke-s:1px;--bq-stroke-m:2px;--bq-stroke-l:3px}.beeq:not([bq-mode]),.light,:root:not([bq-theme]):not([bq-mode]),:root[bq-theme=beeq]:not([bq-mode]),[bq-mode=light]{--bq-background--primary:var(--bq-white);--bq-background--secondary:var(--bq-neutral-100);--bq-background--tertiary:var(--bq-neutral-200);--bq-background--alt:var(--bq-neutral-300);--bq-background--inverse:var(--bq-neutral-900);--bq-background--brand:var(--bq-brand);--bq-background--overlay:var(--bq-neutral-900);--bq-icon--primary:var(--bq-neutral-800);--bq-icon--alt:var(--bq-white);--bq-icon--secondary:var(--bq-neutral-600);--bq-icon--inverse:var(--bq-neutral-50);--bq-icon--brand:var(--bq-brand);--bq-icon--info:var(--bq-brand);--bq-icon--success:var(--bq-success);--bq-icon--warning:var(--bq-warning);--bq-icon--danger:var(--bq-danger);--bq-stroke--primary:var(--bq-neutral-200);--bq-stroke--secondary:var(--bq-neutral-600);--bq-stroke--tertiary:var(--bq-neutral-900);--bq-stroke--inverse:var(--bq-white);--bq-stroke--brand:var(--bq-brand);--bq-stroke--alt:var(--bq-neutral-50);--bq-stroke--success:var(--bq-success);--bq-stroke--warning:var(--bq-warning);--bq-stroke--danger:var(--bq-danger);--bq-stroke--info:var(--bq-brand);--bq-text--primary:var(--bq-neutral-800);--bq-text--secondary:var(--bq-neutral-600);--bq-text--inverse:var(--bq-neutral-50);--bq-text--brand:var(--bq-brand);--bq-text--alt:var(--bq-white);--bq-text--info:var(--bq-brand);--bq-text--success:var(--bq-success);--bq-text--warning:var(--bq-warning);--bq-text--danger:var(--bq-danger);--bq-ui--primary:var(--bq-white);--bq-ui--secondary:var(--bq-neutral-100);--bq-ui--tertiary:var(--bq-neutral-500);--bq-ui--inverse:var(--bq-neutral-900);--bq-ui--brand:var(--bq-brand);--bq-ui--brand-alt:var(--bq-brand-light);--bq-ui--alt:var(--bq-neutral-50);--bq-ui--success:var(--bq-success);--bq-ui--success-alt:var(--bq-success-light);--bq-ui--warning:var(--bq-warning);--bq-ui--warning-alt:var(--bq-warning-light);--bq-ui--danger:var(--bq-danger);--bq-ui--danger-alt:var(--bq-danger-light);--bq-ui--info:var(--bq-brand);--bq-ui--info-alt:var(--bq-brand-light);--bq-hover:#bcbfc5;--bq-active:#444546}.dark,[bq-mode=dark]{--bq-background--primary:var(--bq-neutral-1000);--bq-background--secondary:var(--bq-neutral-950);--bq-background--tertiary:var(--bq-neutral-800);--bq-background--alt:var(--bq-neutral-700);--bq-background--inverse:var(--bq-neutral-600);--bq-background--brand:var(--bq-brand);--bq-background--overlay:var(--bq-neutral-900);--bq-icon--primary:var(--bq-neutral-100);--bq-icon--secondary:var(--bq-neutral-400);--bq-icon--inverse:var(--bq-neutral-800);--bq-icon--brand:var(--bq-brand);--bq-icon--alt:var(--bq-white);--bq-icon--info:var(--bq-brand);--bq-icon--success:var(--bq-success);--bq-icon--warning:var(--bq-warning);--bq-icon--danger:var(--bq-danger);--bq-stroke--primary:var(--bq-neutral-900);--bq-stroke--secondary:var(--bq-neutral-700);--bq-stroke--tertiary:var(--bq-neutral-400);--bq-stroke--inverse:var(--bq-neutral-950);--bq-stroke--brand:var(--bq-brand);--bq-stroke--alt:var(--bq-neutral-1000);--bq-stroke--success:var(--bq-success);--bq-stroke--warning:var(--bq-warning);--bq-stroke--danger:var(--bq-danger);--bq-stroke--info:var(--bq-brand);--bq-text--primary:var(--bq-neutral-100);--bq-text--secondary:var(--bq-neutral-400);--bq-text--inverse:var(--bq-neutral-800);--bq-text--brand:var(--bq-brand);--bq-text--alt:var(--bq-white);--bq-text--info:var(--bq-brand);--bq-text--success:var(--bq-success);--bq-text--warning:var(--bq-warning);--bq-text--danger:var(--bq-danger);--bq-ui--primary:var(--bq-neutral-900);--bq-ui--secondary:var(--bq-neutral-950);--bq-ui--tertiary:var(--bq-neutral-700);--bq-ui--inverse:var(--bq-neutral-100);--bq-ui--brand:var(--bq-brand);--bq-ui--brand-alt:var(--bq-brand-dark);--bq-ui--alt:var(--bq-neutral-950);--bq-ui--success:var(--bq-success);--bq-ui--success-alt:var(--bq-success-dark);--bq-ui--warning:var(--bq-warning);--bq-ui--warning-alt:var(--bq-warning-dark);--bq-ui--danger:var(--bq-danger);--bq-ui--danger-alt:var(--bq-danger-dark);--bq-ui--info:var(--bq-brand);--bq-ui--info-alt:var(--bq-brand-dark);--bq-hover:#444546;--bq-active:#1f2026}:where(.endava),:where([bq-theme=endava]){--bq-font-family:"Poppins",sans-serif;--bq-white:#fafbfb;--bq-black:#030406;--bq-neutral-50:var(--bq-endava-grey-50);--bq-neutral-100:var(--bq-endava-grey-100);--bq-neutral-200:var(--bq-endava-grey-200);--bq-neutral-300:var(--bq-endava-grey-300);--bq-neutral-400:var(--bq-endava-grey-400);--bq-neutral-500:var(--bq-endava-grey-500);--bq-neutral-600:var(--bq-endava-grey-600);--bq-neutral-700:var(--bq-endava-grey-700);--bq-neutral-800:var(--bq-endava-grey-800);--bq-neutral-900:var(--bq-endava-grey-900);--bq-neutral-950:var(--bq-endava-grey-950);--bq-neutral-1000:var(--bq-endava-grey-1000);--bq-brand-light:var(--bq-endava-orange-100);--bq-brand:var(--bq-endava-orange-600);--bq-brand-dark:var(--bq-endava-orange-1000);--bq-accent-light:var(--bq-endava-orange-100);--bq-accent:var(--bq-endava-orange-600);--bq-accent-dark:var(--bq-endava-orange-1000);--bq-success-light:var(--bq-green-100);--bq-success:var(--bq-green-600);--bq-success-dark:var(--bq-green-1000);--bq-danger-light:var(--bq-corai-100);--bq-danger:var(--bq-corai-600);--bq-danger-dark:var(--bq-corai-1000);--bq-warning-light:var(--bq-yellow-100);--bq-warning:var(--bq-yellow-600);--bq-warning-dark:var(--bq-yellow-1000);--bq-info-light:var(--bq-blue-100);--bq-info:var(--bq-blue-600);--bq-info-dark:var(--bq-blue-1000);--bq-focus:var(--bq-endava-orange-600);--bq-data-01:var(--bq-brand);--bq-data-02:#af0cd8;--bq-data-03:#0ca8d8;--bq-data-04:var(--bq-teal-600);--bq-data-05:var(--bq-yellow-600);--bq-data-06:var(--bq-orange-600);--bq-data-07:var(--bq-blue-600);--bq-data-08:var(--bq-red-600);--bq-data-09:var(--bq-purple-600);--bq-data-10:#394b56;--bq-data-11:var(--bq-black);--bq-data-12:var(--bq-white)}.endava.light,.endava:not([bq-mode]),[bq-theme=endava]:not([bq-mode]),[bq-theme=endava][bq-mode=light]{--bq-background--primary:var(--bq-white);--bq-background--secondary:var(--bq-neutral-100);--bq-background--tertiary:var(--bq-neutral-200);--bq-background--alt:var(--bq-neutral-300);--bq-background--inverse:var(--bq-neutral-900);--bq-background--brand:var(--bq-brand);--bq-background--overlay:var(--bq-neutral-900);--bq-icon--primary:var(--bq-neutral-800);--bq-icon--secondary:var(--bq-neutral-600);--bq-icon--inverse:var(--bq-neutral-50);--bq-icon--brand:var(--bq-brand);--bq-icon--alt:var(--bq-white);--bq-icon--info:var(--bq-info);--bq-icon--success:var(--bq-success);--bq-icon--warning:var(--bq-warning);--bq-icon--danger:var(--bq-danger);--bq-stroke--primary:var(--bq-neutral-200);--bq-stroke--secondary:var(--bq-neutral-600);--bq-stroke--tertiary:var(--bq-neutral-900);--bq-stroke--inverse:var(--bq-white);--bq-stroke--brand:var(--bq-brand);--bq-stroke--alt:var(--bq-neutral-50);--bq-stroke--brand-alt:var(--bq-brand-light);--bq-stroke--success:var(--bq-success);--bq-stroke--warning:var(--bq-warning);--bq-stroke--danger:var(--bq-danger);--bq-stroke--info:var(--bq-info);--bq-text--primary:var(--bq-neutral-800);--bq-text--secondary:var(--bq-neutral-600);--bq-text--inverse:var(--bq-neutral-50);--bq-text--brand:var(--bq-brand);--bq-text--alt:var(--bq-white);--bq-text--info:var(--bq-info);--bq-text--success:var(--bq-success);--bq-text--warning:var(--bq-warning);--bq-text--danger:var(--bq-danger);--bq-ui--primary:var(--bq-white);--bq-ui--secondary:var(--bq-neutral-100);--bq-ui--tertiary:var(--bq-neutral-500);--bq-ui--inverse:var(--bq-neutral-900);--bq-ui--alt:var(--bq-neutral-50);--bq-ui--brand-alt:var(--bq-brand-light);--bq-ui--brand:var(--bq-brand);--bq-ui--success:var(--bq-success);--bq-ui--success-alt:var(--bq-success-light);--bq-ui--warning:var(--bq-warning);--bq-ui--warning-alt:var(--bq-warning-light);--bq-ui--danger:var(--bq-danger);--bq-ui--danger-alt:var(--bq-danger-light);--bq-ui--info:var(--bq-info);--bq-ui--info-alt:var(--bq-info-light);--bq-hover:#444546;--bq-active:#1f2026}.endava.dark,[bq-theme=endava][bq-mode=dark]{--bq-background--primary:var(--bq-neutral-1000);--bq-background--secondary:var(--bq-neutral-900);--bq-background--tertiary:var(--bq-neutral-800);--bq-background--alt:var(--bq-neutral-700);--bq-background--inverse:var(--bq-neutral-600);--bq-background--brand:var(--bq-brand);--bq-background--overlay:var(--bq-neutral-900);--bq-icon--primary:var(--bq-neutral-100);--bq-icon--secondary:var(--bq-neutral-400);--bq-icon--inverse:var(--bq-neutral-800);--bq-icon--brand:var(--bq-brand);--bq-icon--alt:var(--bq-white);--bq-icon--info:var(--bq-info);--bq-icon--success:var(--bq-success);--bq-icon--warning:var(--bq-warning);--bq-icon--danger:var(--bq-danger);--bq-stroke--primary:var(--bq-neutral-900);--bq-stroke--secondary:var(--bq-neutral-700);--bq-stroke--tertiary:var(--bq-neutral-400);--bq-stroke--inverse:var(--bq-neutral-950);--bq-stroke--brand:var(--bq-brand);--bq-stroke--brand-alt:var(--bq-brand-dark);--bq-stroke--alt:var(--bq-neutral-1000);--bq-stroke--success:var(--bq-success);--bq-stroke--warning:var(--bq-warning);--bq-stroke--danger:var(--bq-danger);--bq-stroke--info:var(--bq-info);--bq-text--primary:var(--bq-neutral-100);--bq-text--secondary:var(--bq-neutral-400);--bq-text--inverse:var(--bq-neutral-800);--bq-text--brand:var(--bq-brand);--bq-text--alt:var(--bq-neutral-white);--bq-text--info:var(--bq-info);--bq-text--success:var(--bq-success);--bq-text--warning:var(--bq-warning);--bq-text--danger:var(--bq-danger);--bq-ui--primary:var(--bq-neutral-900);--bq-ui--secondary:var(--bq-neutral-950);--bq-ui--tertiary:var(--bq-neutral-700);--bq-ui--inverse:var(--bq-neutral-100);--bq-ui--brand:var(--bq-brand);--bq-ui--brand-alt:var(--bq-brand-dark);--bq-ui--alt:var(--bq-neutral-950);--bq-ui--success:var(--bq-success);--bq-ui--success-alt:var(--bq-success-dark);--bq-ui--warning:var(--bq-warning);--bq-ui--warning-alt:var(--bq-warning-dark);--bq-ui--danger:var(--bq-danger);--bq-ui--danger-alt:var(--bq-danger-dark);--bq-ui--info:var(--bq-info);--bq-ui--info-alt:var(--bq-info-dark);--bq-hover:#444546;--bq-active:#1f2026}.flex{display:flex}.cursor-pointer{cursor:pointer}.items-center{align-items:center}.rounded-\\[--bq-breadcrumb-item--border-radius\\]{border-radius:var(--bq-breadcrumb-item--border-radius)}.border-\\[length\\:--bq-breadcrumb-item--border-width\\]{border-width:var(--bq-breadcrumb-item--border-width)}.border-\\[color\\:--bq-breadcrumb-item--border-color\\]{border-color:var(--bq-breadcrumb-item--border-color)}.bg-\\[--bq-breadcrumb-item--background\\]{background-color:var(--bq-breadcrumb-item--background)}.pe-\\[--bq-breadcrumb-item--padding-end-separator\\]{padding-inline-end:var(--bq-breadcrumb-item--padding-end-separator)}.pe-\\[--bq-breadcrumb-item--padding-end\\]{padding-inline-end:var(--bq-breadcrumb-item--padding-end)}.ps-\\[--bq-breadcrumb-item--padding-start-separator\\]{padding-inline-start:var(--bq-breadcrumb-item--padding-start-separator)}.ps-\\[--bq-breadcrumb-item--padding-start\\]{padding-inline-start:var(--bq-breadcrumb-item--padding-start)}.text-\\[length\\:--bq-breadcrumb-item--text-size-separator\\]{font-size:var(--bq-breadcrumb-item--text-size-separator)}.text-\\[length\\:--bq-breadcrumb-item--text-size\\]{font-size:var(--bq-breadcrumb-item--text-size)}.font-regular{font-weight:var(--bq-font-weight--regular)}.leading-\\[--bq-breadcrumb-item--line-height\\]{line-height:var(--bq-breadcrumb-item--line-height)}.text-\\[color\\:--bq-breadcrumb-item--text-color-current\\]{color:var(--bq-breadcrumb-item--text-color-current)}.text-\\[color\\:--bq-breadcrumb-item--text-color\\]{color:var(--bq-breadcrumb-item--text-color)}.shadow-\\[shadow\\:--bq-breadcrumb-item--box-shadow\\]{--tw-shadow:var(--bq-breadcrumb-item--box-shadow);--tw-shadow-colored:var(--bq-breadcrumb-item--box-shadow);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-300{transition-duration:.3s}.p-b-\\[--bq-breadcrumb-item--paddingY\\]{padding-block:var(--bq-breadcrumb-item--paddingY)}@-webkit-keyframes fade-in{0%{opacity:0}}@keyframes fade-in{0%{opacity:0}}@-webkit-keyframes slide-in{0%{-webkit-transform:translateY(10px);transform:translateY(10px)}}@keyframes slide-in{0%{-webkit-transform:translateY(10px);transform:translateY(10px)}}@-webkit-keyframes spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}@keyframes spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}:host{--bq-breadcrumb-item--background:transparent;--bq-breadcrumb-item--box-shadow:none;--bq-breadcrumb-item--border-color:transparent;--bq-breadcrumb-item--border-style:none;--bq-breadcrumb-item--border-width:var(--bq-stroke-s);--bq-breadcrumb-item--border-radius:var(--bq-radius--s);--bq-breadcrumb-item--line-height:var(--bq-font-line-height--regular);--bq-breadcrumb-item--text-color:var(--bq-text--secondary);--bq-breadcrumb-item--text-color-current:var(--bq-text--brand);--bq-breadcrumb-item--text-size:var(--bq-font-size--s);--bq-breadcrumb-item--text-size-separator:var(--bq-font-size--xs);--bq-breadcrumb-item--padding-start:var(--bq-spacing-xs2);--bq-breadcrumb-item--padding-end:var(--bq-spacing-xs2);--bq-breadcrumb-item--paddingY:var(--bq-spacing-xs);--bq-breadcrumb-item--padding-start-separator:var(--bq-spacing-xs2);--bq-breadcrumb-item--padding-end-separator:var(--bq-spacing-xs2)}:host([aria-current=page]) .breadcrumb-item{color:var(--bq-breadcrumb-item--text-color-current)}.breadcrumb-item{--tw-shadow:var(--bq-breadcrumb-item--box-shadow);--tw-shadow-colored:var(--bq-breadcrumb-item--box-shadow);background-color:var(--bq-breadcrumb-item--background);border-color:var(--bq-breadcrumb-item--border-color);border-radius:var(--bq-breadcrumb-item--border-radius);border-style:var(--bq-avatar--border-style);border-width:var(--bq-breadcrumb-item--border-width);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:var(--bq-breadcrumb-item--text-color);cursor:pointer;font-size:var(--bq-breadcrumb-item--text-size);font-weight:var(--bq-font-weight--regular);line-height:var(--bq-breadcrumb-item--line-height);padding-block:var(--bq-breadcrumb-item--paddingY);padding-inline-end:var(--bq-breadcrumb-item--padding-end);padding-inline-start:var(--bq-breadcrumb-item--padding-start);text-decoration-line:none;transition-duration:.3s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}.breadcrumb-item:focus-visible{outline:var(--bq-ring-width,2px) solid var(--bq-ring-color-focus,var(--bq-focus));outline-offset:var(--bq-ring-offset-width,1px)}.breadcrumb-item:hover{color:color-mix(in srgb,var(--bq-text--brand),var(--bq-hover) 20%)}.breadcrumb-item:active{outline:2px solid transparent;outline-offset:2px}.breadcrumb-separator{align-items:center;display:flex;font-size:var(--bq-breadcrumb-item--text-size-separator);padding-inline-end:var(--bq-breadcrumb-item--padding-end-separator);padding-inline-start:var(--bq-breadcrumb-item--padding-start-separator)}.focus-visible\\:focus:focus-visible{outline:var(--bq-ring-width,2px) solid var(--bq-ring-color-focus,var(--bq-focus));outline-offset:var(--bq-ring-offset-width,1px)}.hover\\:text-hover-brand:hover{color:color-mix(in srgb,var(--bq-text--brand),var(--bq-hover) 20%)}.static{position:static}.gap-xs2{gap:var(--bq-spacing-xs2)}.focus{outline:var(--bq-ring-width,2px) solid var(--bq-ring-color-focus,var(--bq-focus));outline-offset:var(--bq-ring-offset-width,1px)}';const n=class{constructor(b){r(this,b);this.bqBlur=a(this,"bqBlur");this.bqFocus=a(this,"bqFocus");this.bqClick=a(this,"bqClick")}get el(){return b(this)}href;target;rel="noreferrer noopener";bqBlur;bqFocus;bqClick;onBlur=()=>{this.bqBlur.emit(this.el)};onFocus=()=>{this.bqFocus.emit(this.el)};onClick=()=>{this.bqClick.emit(this.el)};render(){const r=t(this.href);const a=r?"a":"button";return e("div",{key:"76b21263852564dd2819baa47f0ea6bd0cecaaba",class:"flex items-center",part:"base"},e(a,{key:"57fe9fc084c3b04eb3c64241987811b1f6f032da",class:"breadcrumb-item",href:r?this.href:undefined,rel:r&&this.target?"noreferrer noopener":undefined,target:r?this.target:undefined,onBlur:this.onBlur,onFocus:this.onFocus,onClick:this.onClick,part:"item"},e("span",{key:"fb853379089aa81a865557b9d76a4ee42a864e36",class:"flex items-center gap-xs2",part:"content"},e("slot",{key:"d447ccd4592702202a53cb9aecc6bcd0ce0eddf1"}))),e("span",{key:"eecbe1bca281af57f5fa604f9ab7282078ecefeb",class:"breadcrumb-separator",part:"separator"},e("slot",{key:"4c016aecf135483b32fb879bc0625e8955a9f4eb",name:"separator"})))}};n.style=q;export{n as bq_breadcrumb_item};
|
|
6
|
+
//# sourceMappingURL=p-01d832d0.entry.js.map
|