@brandsync/wc 1.14.0 → 1.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -0
- package/REFERENCE.md +159 -0
- package/custom-elements.json +1739 -196
- package/dist/brandsync-wc/brandsync-wc.esm.js +1 -1
- package/dist/brandsync-wc/{p-e0927a9a.entry.js → p-0159f0da.entry.js} +1 -1
- package/dist/brandsync-wc/p-0228a584.entry.js +1 -0
- package/dist/brandsync-wc/{p-9d660c03.entry.js → p-0f97fe35.entry.js} +1 -1
- package/dist/brandsync-wc/{p-31cd66e0.entry.js → p-15f4c343.entry.js} +1 -1
- package/dist/brandsync-wc/{p-b6ac1b50.entry.js → p-1ca8b01e.entry.js} +1 -1
- package/dist/brandsync-wc/{p-47cd19aa.entry.js → p-23379d7c.entry.js} +1 -1
- package/dist/brandsync-wc/{p-16c78ff6.entry.js → p-298158da.entry.js} +1 -1
- package/dist/brandsync-wc/{p-b793a0d6.entry.js → p-2e285364.entry.js} +1 -1
- package/dist/brandsync-wc/{p-204cc690.entry.js → p-3488c4fc.entry.js} +1 -1
- package/dist/brandsync-wc/{p-e1b7bea7.entry.js → p-34b0c048.entry.js} +1 -1
- package/dist/brandsync-wc/p-36fe783a.entry.js +1 -0
- package/dist/brandsync-wc/{p-8184d7de.entry.js → p-38ac9aad.entry.js} +1 -1
- package/dist/brandsync-wc/{p-c488cc8b.entry.js → p-38fe9d07.entry.js} +1 -1
- package/dist/brandsync-wc/{p-6e923ebc.entry.js → p-401b3d3d.entry.js} +1 -1
- package/dist/brandsync-wc/{p-2c1efaa1.entry.js → p-42b79d95.entry.js} +1 -1
- package/dist/brandsync-wc/p-45986ad4.entry.js +1 -0
- package/dist/brandsync-wc/{p-227a5182.entry.js → p-4ca40386.entry.js} +1 -1
- package/dist/brandsync-wc/{p-9125632c.entry.js → p-4ed00786.entry.js} +1 -1
- package/dist/brandsync-wc/{p-80700878.entry.js → p-521d0fc2.entry.js} +1 -1
- package/dist/brandsync-wc/{p-bee30626.entry.js → p-538d5b58.entry.js} +1 -1
- package/dist/brandsync-wc/{p-9fa67924.entry.js → p-54f9529f.entry.js} +1 -1
- package/dist/brandsync-wc/{p-1b5cc9b8.entry.js → p-5a45ef51.entry.js} +1 -1
- package/dist/brandsync-wc/{p-ce16f038.entry.js → p-5ed1f45e.entry.js} +1 -1
- package/dist/brandsync-wc/{p-10290c41.entry.js → p-65fa1b21.entry.js} +1 -1
- package/dist/brandsync-wc/{p-df3e7973.entry.js → p-67629178.entry.js} +1 -1
- package/dist/brandsync-wc/{p-e6fc2cd4.entry.js → p-6cb21302.entry.js} +1 -1
- package/dist/brandsync-wc/{p-3477539c.entry.js → p-76748795.entry.js} +1 -1
- package/dist/brandsync-wc/p-769c5b4a.entry.js +1 -0
- package/dist/brandsync-wc/p-7b3518b8.entry.js +1 -0
- package/dist/brandsync-wc/p-7dc59e0b.entry.js +1 -0
- package/dist/brandsync-wc/{p-658532b7.entry.js → p-86774165.entry.js} +1 -1
- package/dist/brandsync-wc/{p-cc1055e6.entry.js → p-89ea6366.entry.js} +1 -1
- package/dist/brandsync-wc/{p-4b40a596.entry.js → p-912629c6.entry.js} +1 -1
- package/dist/brandsync-wc/p-949a4270.entry.js +1 -0
- package/dist/brandsync-wc/{p-c67bc817.entry.js → p-9beeb30c.entry.js} +1 -1
- package/dist/brandsync-wc/{p-d892277f.entry.js → p-a12691d8.entry.js} +1 -1
- package/dist/brandsync-wc/{p-315b510c.entry.js → p-a56bc608.entry.js} +1 -1
- package/dist/brandsync-wc/{p-2967240d.entry.js → p-abfa43f5.entry.js} +1 -1
- package/dist/brandsync-wc/{p-686297f1.entry.js → p-b6081bba.entry.js} +1 -1
- package/dist/brandsync-wc/{p-833f9dc4.entry.js → p-b663ee67.entry.js} +1 -1
- package/dist/brandsync-wc/{p-dd52209a.entry.js → p-b67a0c8f.entry.js} +1 -1
- package/dist/brandsync-wc/{p-fa6b9750.entry.js → p-b9c9bcba.entry.js} +1 -1
- package/dist/brandsync-wc/{p-617bd76d.entry.js → p-baa3d37a.entry.js} +1 -1
- package/dist/brandsync-wc/p-c25553bc.entry.js +1 -0
- package/dist/brandsync-wc/{p-45cb3e6d.entry.js → p-c85fe37b.entry.js} +1 -1
- package/dist/brandsync-wc/{p-2e68b76e.entry.js → p-cc4c8c1d.entry.js} +1 -1
- package/dist/brandsync-wc/{p-056608f0.entry.js → p-cf287ff1.entry.js} +1 -1
- package/dist/brandsync-wc/{p-cc25ee67.entry.js → p-d165a742.entry.js} +1 -1
- package/dist/brandsync-wc/{p-51f40972.entry.js → p-d81c4f58.entry.js} +1 -1
- package/dist/brandsync-wc/{p-94d435a2.entry.js → p-dcacee29.entry.js} +1 -1
- package/dist/brandsync-wc/{p-3dabf202.entry.js → p-e5f50e93.entry.js} +1 -1
- package/dist/brandsync-wc/{p-221244a9.entry.js → p-e72dd05e.entry.js} +1 -1
- package/dist/brandsync-wc/p-e9afb553.entry.js +1 -0
- package/dist/brandsync-wc/{p-0cb6fc39.entry.js → p-e9b6b30f.entry.js} +1 -1
- package/dist/brandsync-wc/{p-a2e59aca.entry.js → p-ed71eb02.entry.js} +1 -1
- package/dist/brandsync-wc/{p-e65d286c.entry.js → p-f0be9125.entry.js} +1 -1
- package/dist/brandsync-wc/p-f3cc961b.entry.js +1 -0
- package/dist/brandsync-wc/{p-6ca1e51b.entry.js → p-f4d1d56e.entry.js} +1 -1
- package/dist/cjs/brandsync-wc.cjs.js +1 -1
- package/dist/cjs/bs-accordion-group.cjs.entry.js +1 -1
- package/dist/cjs/bs-ai-disclaimer.cjs.entry.js +1 -1
- package/dist/cjs/bs-ai-greeting.cjs.entry.js +1 -1
- package/dist/cjs/bs-ai-thinking.cjs.entry.js +1 -1
- package/dist/cjs/bs-app-shell.cjs.entry.js +19 -0
- package/dist/cjs/bs-attachment-list.cjs.entry.js +1 -1
- package/dist/cjs/bs-breadcrumbs.cjs.entry.js +1 -1
- package/dist/cjs/bs-button-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/bs-chatbot-feedback.cjs.entry.js +1 -1
- package/dist/cjs/bs-chatbot-header.cjs.entry.js +1 -1
- package/dist/cjs/bs-chatbot-response-action.cjs.entry.js +1 -1
- package/dist/cjs/bs-chatbot-sources-drawer.cjs.entry.js +1 -1
- package/dist/cjs/bs-chatbot-suggestion-button.cjs.entry.js +1 -1
- package/dist/cjs/bs-checkbox-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/bs-citation-preview.cjs.entry.js +1 -1
- package/dist/cjs/bs-container.cjs.entry.js +23 -0
- package/dist/cjs/bs-data-table.cjs.entry.js +2 -2
- package/dist/cjs/bs-datepicker.cjs.entry.js +1 -1
- package/dist/cjs/bs-divider.cjs.entry.js +29 -0
- package/dist/cjs/bs-error-page.cjs.entry.js +1 -1
- package/dist/cjs/bs-file-upload-item.cjs.entry.js +1 -1
- package/dist/cjs/bs-file-upload.cjs.entry.js +1 -1
- package/dist/cjs/bs-grid.cjs.entry.js +55 -0
- package/dist/cjs/bs-icon-button.cjs.entry.js +1 -1
- package/dist/cjs/bs-icon-tile.cjs.entry.js +2 -2
- package/dist/cjs/bs-inline-tab.cjs.entry.js +1 -1
- package/dist/cjs/bs-input_3.cjs.entry.js +4 -4
- package/dist/cjs/bs-list-item.cjs.entry.js +66 -0
- package/dist/cjs/bs-list.cjs.entry.js +103 -0
- package/dist/cjs/bs-message-list.cjs.entry.js +1 -1
- package/dist/cjs/bs-message.cjs.entry.js +1 -1
- package/dist/cjs/bs-navigation-drawer-item.cjs.entry.js +1 -1
- package/dist/cjs/bs-navigation-drawer.cjs.entry.js +2 -2
- package/dist/cjs/bs-navigation-header.cjs.entry.js +1 -1
- package/dist/cjs/bs-pagination.cjs.entry.js +1 -1
- package/dist/cjs/bs-popover.cjs.entry.js +1 -1
- package/dist/cjs/bs-progress-linear.cjs.entry.js +2 -2
- package/dist/cjs/bs-progress.cjs.entry.js +2 -2
- package/dist/cjs/bs-qr-code.cjs.entry.js +1 -1
- package/dist/cjs/bs-radio.cjs.entry.js +1 -1
- package/dist/cjs/bs-session-timeout.cjs.entry.js +1 -1
- package/dist/cjs/bs-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/bs-slider.cjs.entry.js +1 -1
- package/dist/cjs/bs-snackbar.cjs.entry.js +1 -1
- package/dist/cjs/bs-source-link.cjs.entry.js +2 -2
- package/dist/cjs/bs-spinner.cjs.entry.js +1 -1
- package/dist/cjs/bs-split-pane.cjs.entry.js +1 -1
- package/dist/cjs/bs-stack.cjs.entry.js +81 -0
- package/dist/cjs/bs-stepper-step.cjs.entry.js +1 -1
- package/dist/cjs/bs-stepper.cjs.entry.js +1 -1
- package/dist/cjs/bs-switch.cjs.entry.js +1 -1
- package/dist/cjs/bs-tab_3.cjs.entry.js +3 -3
- package/dist/cjs/bs-timepicker.cjs.entry.js +2 -2
- package/dist/cjs/bs-toast.cjs.entry.js +1 -1
- package/dist/cjs/bs-tooltip-trigger.cjs.entry.js +1 -1
- package/dist/cjs/bs-tooltip.cjs.entry.js +1 -1
- package/dist/cjs/bs-tree-item.cjs.entry.js +94 -0
- package/dist/cjs/bs-tree.cjs.entry.js +197 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +9 -0
- package/dist/collection/components/bs-accordion-group/bs-accordion-group.js +1 -1
- package/dist/collection/components/bs-ai-disclaimer/bs-ai-disclaimer.js +1 -1
- package/dist/collection/components/bs-ai-greeting/bs-ai-greeting.js +1 -1
- package/dist/collection/components/bs-ai-thinking/bs-ai-thinking.js +1 -1
- package/dist/collection/components/bs-app-shell/bs-app-shell.cmp.test.js +71 -0
- package/dist/collection/components/bs-app-shell/bs-app-shell.css +58 -0
- package/dist/collection/components/bs-app-shell/bs-app-shell.js +79 -0
- package/dist/collection/components/bs-app-shell/bs-app-shell.stories.js +34 -0
- package/dist/collection/components/bs-attachment-list/bs-attachment-list.js +1 -1
- package/dist/collection/components/bs-breadcrumb/bs-breadcrumbs/bs-breadcrumbs.js +1 -1
- package/dist/collection/components/bs-button/bs-icon-button/bs-icon-button.js +1 -1
- package/dist/collection/components/bs-button-skeleton/bs-button-skeleton.js +1 -1
- package/dist/collection/components/bs-chatbot-feedback/bs-chatbot-feedback.js +1 -1
- package/dist/collection/components/bs-chatbot-header/bs-chatbot-header.js +1 -1
- package/dist/collection/components/bs-chatbot-response-action/bs-chatbot-response-action.js +1 -1
- package/dist/collection/components/bs-chatbot-sources-drawer/bs-chatbot-sources-drawer.js +1 -1
- package/dist/collection/components/bs-chatbot-suggestion-button/bs-chatbot-suggestion-button.js +1 -1
- package/dist/collection/components/bs-checkbox/bs-checkbox-skeleton/bs-checkbox-skeleton.js +1 -1
- package/dist/collection/components/bs-citation-preview/bs-citation-preview.js +1 -1
- package/dist/collection/components/bs-container/bs-container.cmp.test.js +59 -0
- package/dist/collection/components/bs-container/bs-container.css +16 -0
- package/dist/collection/components/bs-container/bs-container.js +88 -0
- package/dist/collection/components/bs-container/bs-container.stories.js +24 -0
- package/dist/collection/components/bs-data-table/bs-data-table.js +2 -2
- package/dist/collection/components/bs-datepicker/bs-datepicker.js +1 -1
- package/dist/collection/components/bs-divider/bs-divider.cmp.test.js +47 -0
- package/dist/collection/components/bs-divider/bs-divider.css +47 -0
- package/dist/collection/components/bs-divider/bs-divider.js +147 -0
- package/dist/collection/components/bs-divider/bs-divider.stories.js +32 -0
- package/dist/collection/components/bs-error-page/bs-error-page.js +1 -1
- package/dist/collection/components/bs-file-upload/bs-file-upload.js +1 -1
- package/dist/collection/components/bs-file-upload-item/bs-file-upload-item.js +1 -1
- package/dist/collection/components/bs-grid/bs-grid.cmp.test.js +58 -0
- package/dist/collection/components/bs-grid/bs-grid.css +10 -0
- package/dist/collection/components/bs-grid/bs-grid.js +208 -0
- package/dist/collection/components/bs-grid/bs-grid.stories.js +38 -0
- package/dist/collection/components/bs-icon-tile/bs-icon-tile.js +2 -2
- package/dist/collection/components/bs-input/bs-input.js +2 -2
- package/dist/collection/components/bs-list/bs-list.cmp.test.js +99 -0
- package/dist/collection/components/bs-list/bs-list.css +15 -0
- package/dist/collection/components/bs-list/bs-list.js +241 -0
- package/dist/collection/components/bs-list/bs-list.stories.js +43 -0
- package/dist/collection/components/bs-list-item/bs-list-item.cmp.test.js +137 -0
- package/dist/collection/components/bs-list-item/bs-list-item.css +139 -0
- package/dist/collection/components/bs-list-item/bs-list-item.js +343 -0
- package/dist/collection/components/bs-list-item/bs-list-item.stories.js +86 -0
- package/dist/collection/components/bs-menu/bs-menu.js +1 -1
- package/dist/collection/components/bs-menu-item/bs-menu-item.cmp.test.js +6 -0
- package/dist/collection/components/bs-menu-item/bs-menu-item.js +1 -1
- package/dist/collection/components/bs-message/bs-message.js +1 -1
- package/dist/collection/components/bs-message-list/bs-message-list.js +1 -1
- package/dist/collection/components/bs-pagination/bs-pagination.js +1 -1
- package/dist/collection/components/bs-popover/bs-popover.js +1 -1
- package/dist/collection/components/bs-progress/bs-progress.js +2 -2
- package/dist/collection/components/bs-progress-linear/bs-progress-linear.js +2 -2
- package/dist/collection/components/bs-qr-code/bs-qr-code.js +1 -1
- package/dist/collection/components/bs-radio/bs-radio.js +1 -1
- package/dist/collection/components/bs-session-timeout/bs-session-timeout.js +1 -1
- package/dist/collection/components/bs-skeleton/bs-skeleton.js +1 -1
- package/dist/collection/components/bs-slider/bs-slider.js +1 -1
- package/dist/collection/components/bs-snackbar/bs-snackbar.js +1 -1
- package/dist/collection/components/bs-source-link/bs-source-link.js +2 -2
- package/dist/collection/components/bs-spinner/bs-spinner.js +1 -1
- package/dist/collection/components/bs-split-pane/bs-split-pane.js +1 -1
- package/dist/collection/components/bs-stack/bs-stack.cmp.test.js +113 -0
- package/dist/collection/components/bs-stack/bs-stack.css +22 -0
- package/dist/collection/components/bs-stack/bs-stack.js +252 -0
- package/dist/collection/components/bs-stack/bs-stack.stories.js +36 -0
- package/dist/collection/components/bs-stepper/bs-stepper/bs-stepper.js +1 -1
- package/dist/collection/components/bs-stepper/bs-stepper-step/bs-stepper-step.js +1 -1
- package/dist/collection/components/bs-switch/bs-switch.js +1 -1
- package/dist/collection/components/bs-tab/bs-inline-tab/bs-inline-tab.js +1 -1
- package/dist/collection/components/bs-tab/bs-tab/bs-tab.js +1 -1
- package/dist/collection/components/bs-tab/bs-tabs/bs-tabs.js +1 -1
- package/dist/collection/components/bs-timepicker/bs-timepicker.js +2 -2
- package/dist/collection/components/bs-toast/bs-toast.js +1 -1
- package/dist/collection/components/bs-tooltip/bs-tooltip.js +1 -1
- package/dist/collection/components/bs-tooltip-trigger/bs-tooltip-trigger.js +1 -1
- package/dist/collection/components/bs-tree/bs-tree.cmp.test.js +166 -0
- package/dist/collection/components/bs-tree/bs-tree.css +8 -0
- package/dist/collection/components/bs-tree/bs-tree.js +354 -0
- package/dist/collection/components/bs-tree/bs-tree.stories.js +34 -0
- package/dist/collection/components/bs-tree-item/bs-tree-item.cmp.test.js +187 -0
- package/dist/collection/components/bs-tree-item/bs-tree-item.css +161 -0
- package/dist/collection/components/bs-tree-item/bs-tree-item.js +305 -0
- package/dist/collection/components/bs-tree-item/bs-tree-item.stories.js +54 -0
- package/dist/collection/components/bs-whats-new-entry/bs-whats-new-entry.js +1 -1
- package/dist/collection/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer/bs-navigation-drawer.js +2 -2
- package/dist/collection/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer-item/bs-navigation-drawer-item.js +1 -1
- package/dist/collection/components/ui-shell/bs-navigation-header/bs-navigation-header/bs-navigation-header.js +1 -1
- package/dist/components/bs-accordion-group.js +1 -1
- package/dist/components/bs-ai-disclaimer.js +1 -1
- package/dist/components/bs-ai-greeting.js +1 -1
- package/dist/components/bs-ai-thinking.js +1 -1
- package/dist/components/bs-app-shell.d.ts +11 -0
- package/dist/components/bs-app-shell.js +1 -0
- package/dist/components/bs-attachment-list.js +1 -1
- package/dist/components/bs-attachment.js +1 -1
- package/dist/components/bs-breadcrumb-overflow.js +1 -1
- package/dist/components/bs-breadcrumbs.js +1 -1
- package/dist/components/bs-button-skeleton.js +1 -1
- package/dist/components/bs-carousel.js +1 -1
- package/dist/components/bs-chatbot-feedback.js +1 -1
- package/dist/components/bs-chatbot-header.js +1 -1
- package/dist/components/bs-chatbot-response-action.js +1 -1
- package/dist/components/bs-chatbot-sources-drawer.js +1 -1
- package/dist/components/bs-chatbot-suggestion-button.js +1 -1
- package/dist/components/bs-checkbox-skeleton.js +1 -1
- package/dist/components/bs-citation-preview.js +1 -1
- package/dist/components/bs-container.d.ts +11 -0
- package/dist/components/bs-container.js +1 -0
- package/dist/components/bs-cookie-consent.js +1 -1
- package/dist/components/bs-data-table.js +1 -1
- package/dist/components/bs-datepicker.js +1 -1
- package/dist/components/bs-dialog.js +1 -1
- package/dist/components/bs-divider.d.ts +11 -0
- package/dist/components/bs-divider.js +1 -0
- package/dist/components/bs-error-page.js +1 -1
- package/dist/components/bs-file-upload-item.js +1 -1
- package/dist/components/bs-file-upload.js +1 -1
- package/dist/components/bs-grid.d.ts +11 -0
- package/dist/components/bs-grid.js +1 -0
- package/dist/components/bs-icon-button.js +1 -1
- package/dist/components/bs-icon-tile.js +1 -1
- package/dist/components/bs-inline-tab.js +1 -1
- package/dist/components/bs-input.js +1 -1
- package/dist/components/bs-list-item.d.ts +11 -0
- package/dist/components/bs-list-item.js +1 -0
- package/dist/components/bs-list.d.ts +11 -0
- package/dist/components/bs-list.js +1 -0
- package/dist/components/bs-menu-item.js +1 -1
- package/dist/components/bs-menu.js +1 -1
- package/dist/components/bs-message-list.js +1 -1
- package/dist/components/bs-message.js +1 -1
- package/dist/components/bs-navigation-drawer-item.js +1 -1
- package/dist/components/bs-navigation-drawer.js +1 -1
- package/dist/components/bs-navigation-header.js +1 -1
- package/dist/components/bs-onboarding-checklist.js +1 -1
- package/dist/components/bs-pagination.js +1 -1
- package/dist/components/bs-popover.js +1 -1
- package/dist/components/bs-product-tour.js +1 -1
- package/dist/components/bs-progress-linear.js +1 -1
- package/dist/components/bs-progress.js +1 -1
- package/dist/components/bs-qr-code.js +1 -1
- package/dist/components/bs-radio.js +1 -1
- package/dist/components/bs-session-timeout.js +1 -1
- package/dist/components/bs-side-panel.js +1 -1
- package/dist/components/bs-skeleton.js +1 -1
- package/dist/components/bs-slider.js +1 -1
- package/dist/components/bs-snackbar.js +1 -1
- package/dist/components/bs-source-link.js +1 -1
- package/dist/components/bs-spinner.js +1 -1
- package/dist/components/bs-split-pane.js +1 -1
- package/dist/components/bs-stack.d.ts +11 -0
- package/dist/components/bs-stack.js +1 -0
- package/dist/components/bs-stepper-step.js +1 -1
- package/dist/components/bs-stepper.js +1 -1
- package/dist/components/bs-switch.js +1 -1
- package/dist/components/bs-tab.js +1 -1
- package/dist/components/bs-tabs.js +1 -1
- package/dist/components/bs-timepicker.js +1 -1
- package/dist/components/bs-toast.js +1 -1
- package/dist/components/bs-tooltip-trigger.js +1 -1
- package/dist/components/bs-tooltip.js +1 -1
- package/dist/components/bs-tree-item.d.ts +11 -0
- package/dist/components/bs-tree-item.js +1 -0
- package/dist/components/bs-tree.d.ts +11 -0
- package/dist/components/bs-tree.js +1 -0
- package/dist/components/bs-whats-new-entry.js +1 -1
- package/dist/components/bs-whats-new.js +1 -1
- package/dist/components/{p-CrmEXUwm.js → p-B128GX8H.js} +1 -1
- package/dist/components/{p-Rx4bpeYN.js → p-B80vOwH6.js} +1 -1
- package/dist/components/p-BaJEv6rL.js +1 -0
- package/dist/components/{p-BESyTlfT.js → p-Bb1-2M8K.js} +1 -1
- package/dist/components/{p-nC2VxRNo.js → p-BdkE4auv.js} +1 -1
- package/dist/components/{p-BIW9eUic.js → p-BsbtyRJV.js} +1 -1
- package/dist/components/{p-BJR8KVFc.js → p-ByLUtXxO.js} +1 -1
- package/dist/components/p-C7RZ6qZC.js +1 -0
- package/dist/components/{p-HzaOqQ0U.js → p-C93ymWm7.js} +1 -1
- package/dist/components/{p-DpVeeIko.js → p-CK7fiES5.js} +1 -1
- package/dist/components/{p-QnTjSed5.js → p-CQjSDdH7.js} +1 -1
- package/dist/components/{p-HAmR4gM2.js → p-D0KM1R2i.js} +1 -1
- package/dist/components/{p-CDYw4Eyj.js → p-DFKc3lLA.js} +1 -1
- package/dist/components/{p-DAwSBMeM.js → p-GTDI4Ibw.js} +1 -1
- package/dist/components/{p-Dm3TqgV_.js → p-J9cxcDhY.js} +1 -1
- package/dist/components/{p-CiSEDtbE.js → p-kDJsWjTN.js} +1 -1
- package/dist/esm/brandsync-wc.js +1 -1
- package/dist/esm/bs-accordion-group.entry.js +1 -1
- package/dist/esm/bs-ai-disclaimer.entry.js +1 -1
- package/dist/esm/bs-ai-greeting.entry.js +1 -1
- package/dist/esm/bs-ai-thinking.entry.js +1 -1
- package/dist/esm/bs-app-shell.entry.js +17 -0
- package/dist/esm/bs-attachment-list.entry.js +1 -1
- package/dist/esm/bs-breadcrumbs.entry.js +1 -1
- package/dist/esm/bs-button-skeleton.entry.js +1 -1
- package/dist/esm/bs-chatbot-feedback.entry.js +1 -1
- package/dist/esm/bs-chatbot-header.entry.js +1 -1
- package/dist/esm/bs-chatbot-response-action.entry.js +1 -1
- package/dist/esm/bs-chatbot-sources-drawer.entry.js +1 -1
- package/dist/esm/bs-chatbot-suggestion-button.entry.js +1 -1
- package/dist/esm/bs-checkbox-skeleton.entry.js +1 -1
- package/dist/esm/bs-citation-preview.entry.js +1 -1
- package/dist/esm/bs-container.entry.js +21 -0
- package/dist/esm/bs-data-table.entry.js +2 -2
- package/dist/esm/bs-datepicker.entry.js +1 -1
- package/dist/esm/bs-divider.entry.js +27 -0
- package/dist/esm/bs-error-page.entry.js +1 -1
- package/dist/esm/bs-file-upload-item.entry.js +1 -1
- package/dist/esm/bs-file-upload.entry.js +1 -1
- package/dist/esm/bs-grid.entry.js +53 -0
- package/dist/esm/bs-icon-button.entry.js +1 -1
- package/dist/esm/bs-icon-tile.entry.js +2 -2
- package/dist/esm/bs-inline-tab.entry.js +1 -1
- package/dist/esm/bs-input_3.entry.js +4 -4
- package/dist/esm/bs-list-item.entry.js +64 -0
- package/dist/esm/bs-list.entry.js +101 -0
- package/dist/esm/bs-message-list.entry.js +1 -1
- package/dist/esm/bs-message.entry.js +1 -1
- package/dist/esm/bs-navigation-drawer-item.entry.js +1 -1
- package/dist/esm/bs-navigation-drawer.entry.js +2 -2
- package/dist/esm/bs-navigation-header.entry.js +1 -1
- package/dist/esm/bs-pagination.entry.js +1 -1
- package/dist/esm/bs-popover.entry.js +1 -1
- package/dist/esm/bs-progress-linear.entry.js +2 -2
- package/dist/esm/bs-progress.entry.js +2 -2
- package/dist/esm/bs-qr-code.entry.js +1 -1
- package/dist/esm/bs-radio.entry.js +1 -1
- package/dist/esm/bs-session-timeout.entry.js +1 -1
- package/dist/esm/bs-skeleton.entry.js +1 -1
- package/dist/esm/bs-slider.entry.js +1 -1
- package/dist/esm/bs-snackbar.entry.js +1 -1
- package/dist/esm/bs-source-link.entry.js +2 -2
- package/dist/esm/bs-spinner.entry.js +1 -1
- package/dist/esm/bs-split-pane.entry.js +1 -1
- package/dist/esm/bs-stack.entry.js +79 -0
- package/dist/esm/bs-stepper-step.entry.js +1 -1
- package/dist/esm/bs-stepper.entry.js +1 -1
- package/dist/esm/bs-switch.entry.js +1 -1
- package/dist/esm/bs-tab_3.entry.js +3 -3
- package/dist/esm/bs-timepicker.entry.js +2 -2
- package/dist/esm/bs-toast.entry.js +1 -1
- package/dist/esm/bs-tooltip-trigger.entry.js +1 -1
- package/dist/esm/bs-tooltip.entry.js +1 -1
- package/dist/esm/bs-tree-item.entry.js +92 -0
- package/dist/esm/bs-tree.entry.js +195 -0
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/bs-app-shell/bs-app-shell.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-app-shell/bs-app-shell.d.ts +40 -0
- package/dist/types/components/bs-app-shell/bs-app-shell.stories.d.ts +11 -0
- package/dist/types/components/bs-container/bs-container.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-container/bs-container.d.ts +22 -0
- package/dist/types/components/bs-container/bs-container.stories.d.ts +15 -0
- package/dist/types/components/bs-divider/bs-divider.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-divider/bs-divider.d.ts +29 -0
- package/dist/types/components/bs-divider/bs-divider.stories.d.ts +16 -0
- package/dist/types/components/bs-grid/bs-grid.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-grid/bs-grid.d.ts +43 -0
- package/dist/types/components/bs-grid/bs-grid.stories.d.ts +18 -0
- package/dist/types/components/bs-list/bs-list.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-list/bs-list.d.ts +42 -0
- package/dist/types/components/bs-list/bs-list.stories.d.ts +13 -0
- package/dist/types/components/bs-list-item/bs-list-item.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-list-item/bs-list-item.d.ts +85 -0
- package/dist/types/components/bs-list-item/bs-list-item.stories.d.ts +22 -0
- package/dist/types/components/bs-stack/bs-stack.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-stack/bs-stack.d.ts +46 -0
- package/dist/types/components/bs-stack/bs-stack.stories.d.ts +18 -0
- package/dist/types/components/bs-tree/bs-tree.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-tree/bs-tree.d.ts +53 -0
- package/dist/types/components/bs-tree/bs-tree.stories.d.ts +11 -0
- package/dist/types/components/bs-tree-item/bs-tree-item.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-tree-item/bs-tree-item.d.ts +60 -0
- package/dist/types/components/bs-tree-item/bs-tree-item.stories.d.ts +19 -0
- package/dist/types/components.d.ts +1257 -0
- package/package.json +1 -1
- package/reference.d.ts +27 -0
- package/reference.json +428 -0
- package/dist/brandsync-wc/p-0e738622.entry.js +0 -1
- package/dist/components/p-zscW5LNR.js +0 -1
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { h } from "@stencil/core";
|
|
2
|
+
/**
|
|
3
|
+
* The page frame: a header across the top, and below it a navigation | main | aside row, laid out
|
|
4
|
+
* with CSS grid. The main column scrolls independently of the header and the side columns.
|
|
5
|
+
*
|
|
6
|
+
* Layout only. Compose it from the existing shell components: put a `bs-navigation-header`
|
|
7
|
+
* (usually `alignment="with-navigation-drawer"`) in `header` and a `bs-navigation-drawer` in
|
|
8
|
+
* `navigation`. The drawer sizes itself (expanded or collapsed rail); the shell reserves an `auto`
|
|
9
|
+
* track for it, so there is no `navigationWidth` prop. `bs-navigation-header` has no `collapsed`
|
|
10
|
+
* prop, so there is no collapse state to mirror and the shell does not listen to `bsCollapse`: the
|
|
11
|
+
* auto track follows the drawer's width on its own.
|
|
12
|
+
*
|
|
13
|
+
* The shell creates no landmarks besides `<main>`; the slotted header and drawer bring their own
|
|
14
|
+
* `banner` and `navigation` roles.
|
|
15
|
+
*
|
|
16
|
+
* ## When to use
|
|
17
|
+
* - The outer frame of an application page with a header and side navigation.
|
|
18
|
+
*
|
|
19
|
+
* ## When not to use
|
|
20
|
+
* - Content layout inside the page (use `bs-grid`) or resizable panes (use `bs-split-pane`).
|
|
21
|
+
* - Pages that already have their own `<main>`; the shell would add a duplicate landmark.
|
|
22
|
+
*
|
|
23
|
+
* @slot header - A `bs-navigation-header`, spanning the full width.
|
|
24
|
+
* @slot navigation - A `bs-navigation-drawer`.
|
|
25
|
+
* @slot - The main content, rendered inside `<main>`; scrolls independently.
|
|
26
|
+
* @slot aside - Optional right column.
|
|
27
|
+
* @part container - The grid element.
|
|
28
|
+
* @part header - Wrapper around the header slot.
|
|
29
|
+
* @part navigation - Wrapper around the navigation slot.
|
|
30
|
+
* @part main - The `<main>` element.
|
|
31
|
+
* @part aside - Wrapper around the aside slot.
|
|
32
|
+
* @prop --bs-app-shell-bg - Shell background. Aliased to `--bs-surface-base`.
|
|
33
|
+
* @prop --bs-app-shell-color - Text colour. Aliased to `--bs-text-default`.
|
|
34
|
+
* @prop --bs-app-shell-main-padding - Padding of the main area. Aliased to `--bs-spacing-400`.
|
|
35
|
+
* @prop --bs-app-shell-aside-width - Width of the aside column. Defaults to `auto` (zero when empty).
|
|
36
|
+
*/
|
|
37
|
+
export class BsAppShell {
|
|
38
|
+
/** When true the host is `height: 100%`; when false it is content-sized with `min-height: 100vh`. */
|
|
39
|
+
fullHeight = true;
|
|
40
|
+
render() {
|
|
41
|
+
return (h("div", { key: '4ae586c70cc00e4eb8d498176c2e1a0ae442ce08', class: "bs-app-shell", part: "container" }, h("div", { key: '63976f08557ba9bcffa6502aa9d84c0369b8794c', class: "bs-app-shell__header", part: "header" }, h("slot", { key: '20582e1a41e6135ea8723f6b70fd992c82bff546', name: "header" })), h("div", { key: '394e505bf3e223f1898f200366a990165f57cbd2', class: "bs-app-shell__navigation", part: "navigation" }, h("slot", { key: '03d93ce4aff4606cf07e0279923ac55ee4572a30', name: "navigation" })), h("main", { key: 'b86613dccbb96fe6dffd0cc98969b9d6bfe75229', class: "bs-app-shell__main", part: "main" }, h("slot", { key: '90c2ec9781341722978c416a1e835cc0d8045a49' })), h("div", { key: 'dc94b2704168de28ea7fa686a58a18d0408e491b', class: "bs-app-shell__aside", part: "aside" }, h("slot", { key: 'fc5e9a0646144edd2461c2b49f5256e9b5937df5', name: "aside" }))));
|
|
42
|
+
}
|
|
43
|
+
static get is() { return "bs-app-shell"; }
|
|
44
|
+
static get encapsulation() { return "shadow"; }
|
|
45
|
+
static get originalStyleUrls() {
|
|
46
|
+
return {
|
|
47
|
+
"$": ["bs-app-shell.css"]
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
static get styleUrls() {
|
|
51
|
+
return {
|
|
52
|
+
"$": ["bs-app-shell.css"]
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
static get properties() {
|
|
56
|
+
return {
|
|
57
|
+
"fullHeight": {
|
|
58
|
+
"type": "boolean",
|
|
59
|
+
"mutable": false,
|
|
60
|
+
"complexType": {
|
|
61
|
+
"original": "boolean",
|
|
62
|
+
"resolved": "boolean",
|
|
63
|
+
"references": {}
|
|
64
|
+
},
|
|
65
|
+
"required": false,
|
|
66
|
+
"optional": false,
|
|
67
|
+
"docs": {
|
|
68
|
+
"tags": [],
|
|
69
|
+
"text": "When true the host is `height: 100%`; when false it is content-sized with `min-height: 100vh`."
|
|
70
|
+
},
|
|
71
|
+
"getter": false,
|
|
72
|
+
"setter": false,
|
|
73
|
+
"reflect": true,
|
|
74
|
+
"attribute": "full-height",
|
|
75
|
+
"defaultValue": "true"
|
|
76
|
+
}
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
import { componentDescription } from "../../stories-utils";
|
|
3
|
+
const page = html `
|
|
4
|
+
<bs-grid min-column-width="240px" gap="200">
|
|
5
|
+
${[1, 2, 3, 4].map(n => html `<div style="background: var(--bs-surface-container); padding: var(--bs-spacing-300); height: 120px">Card ${n}</div>`)}
|
|
6
|
+
</bs-grid>
|
|
7
|
+
<div style="height: 800px"></div>
|
|
8
|
+
`;
|
|
9
|
+
const meta = {
|
|
10
|
+
title: 'Components/bs-app-shell',
|
|
11
|
+
parameters: { layout: 'fullscreen', docs: { description: { component: componentDescription('bs-app-shell') } } },
|
|
12
|
+
render: args => html `
|
|
13
|
+
<div style="height: 100vh">
|
|
14
|
+
<bs-app-shell ?full-height=${args.fullHeight}>
|
|
15
|
+
<bs-navigation-header slot="header" alignment="with-navigation-drawer"></bs-navigation-header>
|
|
16
|
+
<bs-navigation-drawer slot="navigation" heading="Main Menu">
|
|
17
|
+
<bs-navigation-drawer-item selected>Dashboard</bs-navigation-drawer-item>
|
|
18
|
+
<bs-navigation-drawer-item>Reports</bs-navigation-drawer-item>
|
|
19
|
+
<bs-navigation-drawer-item>Settings</bs-navigation-drawer-item>
|
|
20
|
+
</bs-navigation-drawer>
|
|
21
|
+
${page}
|
|
22
|
+
${args.aside
|
|
23
|
+
? html `<div slot="aside" style="width: 280px; padding: var(--bs-spacing-300)">Aside content</div>`
|
|
24
|
+
: ''}
|
|
25
|
+
</bs-app-shell>
|
|
26
|
+
</div>
|
|
27
|
+
`,
|
|
28
|
+
argTypes: { fullHeight: { control: 'boolean' }, aside: { control: 'boolean' } },
|
|
29
|
+
args: { fullHeight: true, aside: false },
|
|
30
|
+
};
|
|
31
|
+
export default meta;
|
|
32
|
+
export const Default = {};
|
|
33
|
+
export const WithAside = { args: { aside: true } };
|
|
34
|
+
export const MinHeightViewport = { args: { fullHeight: false } };
|
|
@@ -58,7 +58,7 @@ export class BsAttachmentList {
|
|
|
58
58
|
this.canScrollRight = row.scrollWidth - row.clientWidth - row.scrollLeft > 1;
|
|
59
59
|
};
|
|
60
60
|
render() {
|
|
61
|
-
return (h("div", { key: '
|
|
61
|
+
return (h("div", { key: '21ad2c7adedce7817859deacd348b5c79465bc4d', class: "bs-attachment-list" }, h("div", { key: '928518998d8a3c613d0cbf8c9527d575aad1af9b', part: "row", class: "bs-attachment-list__row", ref: el => (this.row = el), onScroll: this.onScroll, role: "group", "aria-label": this.ariaLabel, tabIndex: 0 }, h("slot", { key: '7016f855534d7be13806a43bc7220b5db3895f6b', onSlotchange: this.onSlotchange })), this.canScrollRight && h("div", { key: '426f5a159ffb85e5c2c5eeb55d230751397fd09e', part: "fade", class: "bs-attachment-list__fade", "aria-hidden": "true" })));
|
|
62
62
|
}
|
|
63
63
|
static get is() { return "bs-attachment-list"; }
|
|
64
64
|
static get encapsulation() { return "shadow"; }
|
|
@@ -54,7 +54,7 @@ export class BsBreadcrumbs {
|
|
|
54
54
|
});
|
|
55
55
|
}
|
|
56
56
|
render() {
|
|
57
|
-
return (h("nav", { key: '
|
|
57
|
+
return (h("nav", { key: '13f218ab2558e3b5bc11b393c3150b6070c21f72', "aria-label": this.label }, h("ol", { key: '222784839ee0b6693604800ad01e78e0f65ebb13', part: "list", class: "bs-breadcrumbs__list" }, h("slot", { key: '2b588f42ed80e2758236e65572b1cfc14380f027', onSlotchange: this.onSlotChange }))));
|
|
58
58
|
}
|
|
59
59
|
static get is() { return "bs-breadcrumbs"; }
|
|
60
60
|
static get encapsulation() { return "shadow"; }
|
|
@@ -62,7 +62,7 @@ export class BsIconButton {
|
|
|
62
62
|
form.reset();
|
|
63
63
|
};
|
|
64
64
|
render() {
|
|
65
|
-
return (h("button", { key: '
|
|
65
|
+
return (h("button", { key: '285e98b32bc33089125e07f14c84b8c72cdc853b', class: `bs-icon-button bs-icon-button--${this.variant} bs-icon-button--${this.size}`, type: this.type, disabled: this.disabled, "aria-label": this.ariaLabel, onClick: this.onClick }, h("span", { key: 'd91ec40e2d3e99ee3894e5c5c58f5b209b2ef545', part: "icon", class: "bs-icon-button__icon" }, h("slot", { key: '6718a31a0f5f20bed9a5c682ddf0e6d1b703748b' }))));
|
|
66
66
|
}
|
|
67
67
|
static get is() { return "bs-icon-button"; }
|
|
68
68
|
static get encapsulation() { return "shadow"; }
|
|
@@ -27,7 +27,7 @@ export class BsButtonSkeleton {
|
|
|
27
27
|
/** Accessible name announced for the loading placeholder. */
|
|
28
28
|
loadingLabel = 'Loading';
|
|
29
29
|
render() {
|
|
30
|
-
return h("span", { key: '
|
|
30
|
+
return h("span", { key: 'a3122d410d69635b4a4d2aacdd9d7adc6e304289', part: "container", class: `bs-button-skeleton bs-button-skeleton--${this.size}`, role: "status", "aria-label": this.loadingLabel });
|
|
31
31
|
}
|
|
32
32
|
static get is() { return "bs-button-skeleton"; }
|
|
33
33
|
static get encapsulation() { return "shadow"; }
|
|
@@ -139,7 +139,7 @@ export class BsChatbotFeedback {
|
|
|
139
139
|
}
|
|
140
140
|
render() {
|
|
141
141
|
const stars = [1, 2, 3, 4, 5];
|
|
142
|
-
return (h("div", { key: '
|
|
142
|
+
return (h("div", { key: 'b5ecff5747f951bbd12737ae3b228c4ebe5e3c1a', class: "bs-chatbot-feedback", role: "region", "aria-label": this.computedHeading() }, h("button", { key: 'c2f7229ed44ef138176e729ab1bc75a3caeb86f9', type: "button", part: "close", class: "bs-chatbot-feedback__close", "aria-label": this.closeLabel, onClick: this.onCloseClick }, h(CloseIcon, { key: '45cbc05895d53bd52111af0e6c604bd33e8d4fe2' })), h("div", { key: 'b390a7523806a89f30f8e53e9be8514b4dfa68aa', class: "bs-chatbot-feedback__top" }, h("div", { key: '90c8eb690bed06bdf5cc9cd0337379a50240af7a', class: "bs-chatbot-feedback__text" }, h("p", { key: '36017d422b64a1c3b5e2d8f282730328b9d9099d', part: "heading", class: "bs-chatbot-feedback__heading" }, this.computedHeading()), h("p", { key: 'bf7bc4f57de5c72abf271696c06447a9698274b3', part: "subtitle", class: "bs-chatbot-feedback__subtitle" }, this.computedSubtitle())), h("div", { key: '5456d1ad9a761d8b5bdfb6b3e1d4a73d1f15beb9', class: "bs-chatbot-feedback__stars", role: "radiogroup", "aria-label": this.ratingLabel }, stars.map(value => (h("button", { type: "button", part: "star", class: "bs-chatbot-feedback__star", role: "radio", "aria-checked": (this.rating >= value).toString(), "aria-label": `${value} ${value > 1 ? this.starsLabel : this.starLabel}`, disabled: this.submitted, onClick: () => this.onStarClick(value) }, h(StarIcon, { filled: this.rating >= value }))))), !this.submitted && (h("div", { key: 'b4ac38b78a0c219ff4f5f9526242ad69141ca8bc', class: "bs-chatbot-feedback__field" }, h("label", { key: '26d7f278507bc567bfa926f01adf99115a10ef86', part: "label", class: "bs-chatbot-feedback__label", htmlFor: "bs-chatbot-feedback-comment" }, this.commentLabel), h("textarea", { key: 'dc6e76aca6288e38f282460b9dc1ebf29923ecaf', part: "textarea", id: "bs-chatbot-feedback-comment", class: "bs-chatbot-feedback__textarea", placeholder: this.commentPlaceholder, value: this.comment, onInput: this.onCommentInput }))), this.submitted && this.comment && (h("p", { key: '681069b3738f6839f47295398695a9ec7d453970', part: "comment", class: "bs-chatbot-feedback__comment" }, this.comment))), h("div", { key: '1f2cc57d14a95bd4ffca6d2bef8c438f22be24ee', class: "bs-chatbot-feedback__actions" }, !this.submitted && (h("button", { key: '3ec8c2ca290271dab663deb3bc043836097cff7f', type: "button", part: "submit", class: "bs-chatbot-feedback__submit", disabled: this.rating === 0, onClick: this.onSubmitClick }, h(SendIcon, { key: 'b33754c134ea3b53b01f31abf5242f4d6e4d6c50' }), this.submitLabel)), h("button", { key: '87d2a12e10211553f84d90c390739b69a340bd65', type: "button", part: "new-chat", class: `bs-chatbot-feedback__new-chat ${this.submitted ? 'bs-chatbot-feedback__new-chat--primary' : 'bs-chatbot-feedback__new-chat--outlined'}`, onClick: this.onNewChatClick }, h(EditIcon, { key: '438a73c14ea12d59a89d18afc3a200fa457f900f' }), this.newChatLabel))));
|
|
143
143
|
}
|
|
144
144
|
static get is() { return "bs-chatbot-feedback"; }
|
|
145
145
|
static get encapsulation() { return "shadow"; }
|
|
@@ -93,7 +93,7 @@ export class BsChatbotHeader {
|
|
|
93
93
|
this.bsClose.emit();
|
|
94
94
|
};
|
|
95
95
|
render() {
|
|
96
|
-
return (h("div", { key: '
|
|
96
|
+
return (h("div", { key: '1e82711dbca1c2c7f545269154707743d3c39bc2', class: "bs-chatbot-header", role: "banner", "aria-label": this.heading }, h("div", { key: '67ac0df20f227710987066ba897c593c6728d8bd', part: "logo", class: "bs-chatbot-header__logo", role: "img", "aria-label": this.heading, innerHTML: GENIE_LOGO_SVG }), h("div", { key: 'da9b259095c349802c07ef133970482d5d27f7c1', class: "bs-chatbot-header__actions" }, h("slot", { key: 'f8eae11a4ec06a0f0ce1b73ea36deb4276fc447e', name: "actions" }), !this.hideNewChat && (h("span", { key: '72e65dd88d7be443db68d229ed1b33c333c5d2cd', class: "bs-chatbot-header__tooltip-wrapper" }, h("button", { key: 'f2dcdf530a7f4ebb591a6431c11414f5df9ed40e', type: "button", part: "new-chat", class: "bs-chatbot-header__button", "aria-label": this.newChatLabel, onClick: this.onNewChatClick }, h("slot", { key: 'f993c37591df27c604f771b65f11c015bd5cfa29', name: "new-chat-icon" }, h(NewChatIcon, { key: '001e9ab9fefc81499e457102ebb03ab10121f89f' }))), h("bs-tooltip", { key: 'd2c0a848bd204cf1a374d3a3f60162f52c8f3fb1', class: "bs-chatbot-header__tooltip", placement: "top", "aria-hidden": "true" }, this.newChatLabel))), !this.hideHistory && (h("span", { key: 'bd7111e541b03d7c2ab9214457708e3ecdb6120d', class: "bs-chatbot-header__tooltip-wrapper" }, h("button", { key: 'b80ffb1d4c9f55fb5faceb138b56af4cd4bbcc25', type: "button", part: "history", class: "bs-chatbot-header__button", "aria-label": this.historyLabel, onClick: this.onHistoryClick }, h("slot", { key: 'b80e223143dbdc67d08ac2bdba79a25e19e1c92b', name: "history-icon" }, h(HistoryIcon, { key: '30dfe6c3925be30cb3ae32d9415bed6283e289c5' }))), h("bs-tooltip", { key: 'e3f63c2a31fb7aa2ef8baa7fd69a9b491d31e5e9', class: "bs-chatbot-header__tooltip", placement: "top", "aria-hidden": "true" }, this.historyLabel))), !this.hideExpand && (h("span", { key: 'a4a8eec0d3e79c843747714a5e1ac4916107eb6e', class: "bs-chatbot-header__tooltip-wrapper" }, h("button", { key: 'c5b6b5766f829f8b09c205ef9ee2b22db86757d6', type: "button", part: "expand", class: "bs-chatbot-header__button", "aria-label": this.expanded ? this.collapseLabel : this.expandLabel, "aria-pressed": this.expanded ? 'true' : 'false', onClick: this.onExpandClick }, h("slot", { key: 'a4e94ff355a6a059e19d834e31e8e82e2a444847', name: "expand-icon" }, h(ExpandIcon, { key: '8c7e91c88e9b0e6f763ccd01ba1fcfbb6c7310c7' }))), h("bs-tooltip", { key: '5e6594e602dff820748ff4b87edebba43ee45ff6', class: "bs-chatbot-header__tooltip", placement: "top", "aria-hidden": "true" }, this.expanded ? this.collapseLabel : this.expandLabel))), !this.hideClose && (h("span", { key: '2a34f85167c05fbcc0cb367d4717076c9ac6fa4b', class: "bs-chatbot-header__tooltip-wrapper" }, h("button", { key: 'a7ceffef02d0dd8aaf4e5fd88fdecea5c784db44', type: "button", part: "close", class: "bs-chatbot-header__button", "aria-label": this.closeLabel, onClick: this.onCloseClick }, h("slot", { key: 'fa8c5ad4b665f406bd8431eb859ccc665e9e4b1f', name: "close-icon" }, h(CloseIcon, { key: 'bdc09f3721c0b0e46589245f44a8e84625ca4012' }))), h("bs-tooltip", { key: '73d7debb7de3e57425c8af1c01f57d2a1b66c237', class: "bs-chatbot-header__tooltip", placement: "top", "aria-hidden": "true" }, this.closeLabel))))));
|
|
97
97
|
}
|
|
98
98
|
static get is() { return "bs-chatbot-header"; }
|
|
99
99
|
static get encapsulation() { return "shadow"; }
|
|
@@ -127,7 +127,7 @@ export class BsChatbotResponseAction {
|
|
|
127
127
|
};
|
|
128
128
|
render() {
|
|
129
129
|
const hasSources = !!this.sourcesCount && this.sourcesCount > 0;
|
|
130
|
-
return (h("div", { key: '
|
|
130
|
+
return (h("div", { key: '7a3c8e560657192aa3981af225500f1b5012df99', class: "bs-chatbot-response-action" }, h("button", { key: '4f7376d5cc1d9a43fc87b8aaef743709d73a4845', type: "button", part: "like", class: "bs-chatbot-response-action__button", "aria-label": this.likeLabel, "aria-pressed": this.liked ? 'true' : 'false', onClick: this.onLikeClick }, h("slot", { key: 'eb9673716d469f1e3ab0ebb70f850bdf2699f38f', name: "like-icon" }, h(ThumbsUpIcon, { key: 'bb1295906269d4fc9e1f5b7fc611cb4730c39dbf' }))), h("button", { key: 'f4c17bde7dd7729e0b22adc3323b916855192ddf', type: "button", part: "dislike", class: "bs-chatbot-response-action__button", "aria-label": this.dislikeLabel, "aria-pressed": this.disliked ? 'true' : 'false', onClick: this.onDislikeClick }, h("slot", { key: '50f786a78edb25f454087365b29d7f68507fe16c', name: "dislike-icon" }, h(ThumbsDownIcon, { key: 'a0ee507eb51b6d5b1bd91d4c44847ab1655cf59a' }))), h("button", { key: 'd484d6ff7f91eefd84ebd9c9a7752ab44ec04989', type: "button", part: "copy", class: "bs-chatbot-response-action__button", "aria-label": this.copyLabel, onClick: this.onCopyClick }, h("slot", { key: 'df62c8aabf9e05261c79da6900c10c42ffd9695d', name: "copy-icon" }, h(CopyIcon, { key: '11184b8ec93fbe5bced51597d9a42a197562ede0' }))), !this.hideRegenerate && (h("button", { key: 'a96709842dbfde9cc6d68db20b489f540ebb589b', type: "button", part: "regenerate", class: "bs-chatbot-response-action__button", "aria-label": this.regenerateLabel, onClick: this.onRegenerateClick }, h("slot", { key: '7a6f1c7c9ea89c1856a3e3488345455e5aab0d1d', name: "regenerate-icon" }, h(RegenerateIcon, { key: 'eb3179faa96df184c488954c809666b7b0b78ecf' })))), h("div", { key: 'f11dd91afcaf4611999ff0858cdc7f1fd8848f9a', class: "bs-chatbot-response-action__menu-wrapper" }, h("button", { key: 'd2bfd06a3c625cfc8677b505bb10828dbb60a924', type: "button", part: "menu", class: "bs-chatbot-response-action__button", "aria-label": this.menuLabel, "aria-haspopup": "menu", "aria-expanded": this.menuOpen ? 'true' : 'false', onClick: this.onMenuClick }, h("slot", { key: '5caeafa6c2b1ec6f74b91da7f0e96e59d26792c2', name: "menu-icon" }, h(MenuIcon, { key: '9e8d9764fa30764f8db04efce6f119971b8c33b2' }))), this.menuOpen && (h("div", { key: '0af7a8b59c9f3b2ec2e5e44be2966281c0ec54d6', class: "bs-chatbot-response-action__menu-popup" }, h("slot", { key: '521382ac34c12811097eb3295b05bae34e3cb912', name: "menu" })))), hasSources && (h("button", { key: '38f5d0ea3ea28fb1bdfdd71f9176e82900f1c372', type: "button", part: "sources", class: "bs-chatbot-response-action__sources", onClick: this.onSourcesClick }, h("slot", { key: '7187d6bc56c1d75974ed7a1a0a8a3857a3c7608f', name: "sources-icon" }, h(SourcesIcon, { key: 'd3c96a09a399efc1c3a5b2b96b7ac0cc025fc23f' })), h("span", { key: '34cfb2ad8385edecd59a76b0d26268498f236363', class: "bs-chatbot-response-action__sources-label" }, this.sourcesCount, " ", this.sourcesCount === 1 ? this.sourceLabel : this.sourcesLabel)))));
|
|
131
131
|
}
|
|
132
132
|
static get is() { return "bs-chatbot-response-action"; }
|
|
133
133
|
static get encapsulation() { return "shadow"; }
|
|
@@ -59,7 +59,7 @@ export class BsChatbotSourcesDrawer {
|
|
|
59
59
|
};
|
|
60
60
|
render() {
|
|
61
61
|
const displayCount = this.count ?? this.slottedCount;
|
|
62
|
-
return (h("div", { key: '
|
|
62
|
+
return (h("div", { key: '6309d2770d544e58e3e4e99a16ae6a5e16c2545d', class: "bs-chatbot-sources-drawer", role: "region", "aria-label": this.heading }, h("div", { key: '8a3bf1faf5d91a5f833d8de442a5b15a09b2a339', class: "bs-chatbot-sources-drawer__header" }, h("div", { key: 'dfb8ff476939e3f723895de97991b14f9806e8fd', class: "bs-chatbot-sources-drawer__title-group" }, h("h2", { key: 'c817cb00b439026a8ea142441382cf090ddb0a37', part: "heading", class: "bs-chatbot-sources-drawer__heading" }, this.heading), displayCount > 0 && (h("span", { key: '016eb007b496e1355404145a9e294e66d6b8e0f0', part: "count", class: "bs-chatbot-sources-drawer__count" }, displayCount))), h("button", { key: '03bb83d11d15d24d0246d98ee6510201fa33f8b7', type: "button", part: "collapse", class: "bs-chatbot-sources-drawer__collapse", "aria-label": this.collapseLabel, onClick: this.onCollapseClick }, h("slot", { key: '5cae68793cfb35f532f552f154a3badf5e19a1a4', name: "collapse-icon" }, h(CaretRightIcon, { key: '9352aa0f35b8b756a4363b19e57a2cfff37a938e' })))), h("div", { key: 'd9891a9d984f1dfaaba988a4297919888a74a209', part: "list", class: "bs-chatbot-sources-drawer__list" }, h("slot", { key: '03dcd69d2aefb0a3db9b461baa4751ae6925ddef', onSlotchange: this.onSlotchange }))));
|
|
63
63
|
}
|
|
64
64
|
static get is() { return "bs-chatbot-sources-drawer"; }
|
|
65
65
|
static get encapsulation() { return "shadow"; }
|
package/dist/collection/components/bs-chatbot-suggestion-button/bs-chatbot-suggestion-button.js
CHANGED
|
@@ -42,7 +42,7 @@ export class BsChatbotSuggestionButton {
|
|
|
42
42
|
this.bsSelect.emit();
|
|
43
43
|
};
|
|
44
44
|
render() {
|
|
45
|
-
return (h("button", { key: '
|
|
45
|
+
return (h("button", { key: '5d7d706b1cbe7e4e99bfe16db3482979387e7a6a', type: "button", part: "button", class: "bs-chatbot-suggestion-button", disabled: this.disabled, onClick: this.onClick }, h("slot", { key: 'ba5bf8860c3f93c5391f0dbd6742cb4adb978304' })));
|
|
46
46
|
}
|
|
47
47
|
static get is() { return "bs-chatbot-suggestion-button"; }
|
|
48
48
|
static get encapsulation() { return "shadow"; }
|
|
@@ -35,7 +35,7 @@ export class BsCheckboxSkeleton {
|
|
|
35
35
|
/** Accessible name announced for the loading placeholder. */
|
|
36
36
|
loadingLabel = 'Loading';
|
|
37
37
|
render() {
|
|
38
|
-
return (h("span", { key: '
|
|
38
|
+
return (h("span", { key: '5a5e8fb0a06e52c522228d5f3ee461ecfb4124b5', part: "container", class: "bs-checkbox-skeleton", role: "status", "aria-label": this.loadingLabel }, h("span", { key: '64b0151623c813be1a752e042bbb0f616c256c64', part: "box", class: `bs-checkbox-skeleton__box bs-checkbox-skeleton__box--${this.size}` }), h("span", { key: '7045443cd3fa14efbf0be76163ffe499b2a4bf24', part: "label", class: "bs-checkbox-skeleton__label" })));
|
|
39
39
|
}
|
|
40
40
|
static get is() { return "bs-checkbox-skeleton"; }
|
|
41
41
|
static get encapsulation() { return "shadow"; }
|
|
@@ -38,7 +38,7 @@ export class BsCitationPreview {
|
|
|
38
38
|
bsOpen;
|
|
39
39
|
render() {
|
|
40
40
|
const hasPage = this.page !== undefined && this.page !== null && this.page !== '';
|
|
41
|
-
return (h("bs-card", { key: '
|
|
41
|
+
return (h("bs-card", { key: '1295f42db1fb35c289d6cc1477b8430cedf7cbd1', part: "container", class: "bs-citation-preview", surface: "base" }, h("div", { key: '84d861992e3491b5acdba5c828942104080115ae', class: "bs-citation-preview__body" }, h("bs-source-link", { key: 'b84d4965c3f6c4dc0b6c2ffb5c5d2e3ebad1e9c4', part: "header", fileName: this.fileName, sourceName: this.sourceName, href: this.href, onBsOpen: () => this.bsOpen.emit() }), h("div", { key: 'de597e072c72c67600f1b3e8d73681cded0624e6', part: "snippet", class: "bs-citation-preview__snippet" }, h("slot", { key: '5513cf9dcb44ed5ced270437118584a229971de0' })), h("div", { key: '1b6a5620ed09d8690908daa17065fb901c0bdfb1', class: "bs-citation-preview__footer" }, h("slot", { key: 'feabf442256e6d3b26e1f6d309a35c9f96899ab5', name: "footer" }, hasPage && (h("span", { key: '925008ee116c57ea9ab6940054ee42b33883c577', part: "page", class: "bs-citation-preview__page" }, "Page ", this.page)))))));
|
|
42
42
|
}
|
|
43
43
|
static get is() { return "bs-citation-preview"; }
|
|
44
44
|
static get encapsulation() { return "shadow"; }
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { render, h, describe, it, expect } from "@stencil/vitest";
|
|
2
|
+
const mount = (props = {}) => render(h("div", { style: { width: '2000px' } }, h("bs-container", { ...props }, h("div", null, "content"))));
|
|
3
|
+
const tokenPx = (name) => {
|
|
4
|
+
const probe = document.createElement('div');
|
|
5
|
+
probe.style.width = `var(${name})`;
|
|
6
|
+
document.body.appendChild(probe);
|
|
7
|
+
const w = getComputedStyle(probe).width;
|
|
8
|
+
probe.remove();
|
|
9
|
+
return parseFloat(w);
|
|
10
|
+
};
|
|
11
|
+
describe('bs-container', () => {
|
|
12
|
+
it('defaults to xl and is centred', async () => {
|
|
13
|
+
const { root } = await mount();
|
|
14
|
+
const el = root.querySelector('bs-container');
|
|
15
|
+
expect(el).toEqualAttribute('size', 'xl');
|
|
16
|
+
const r = el.getBoundingClientRect();
|
|
17
|
+
const parent = el.parentElement.getBoundingClientRect();
|
|
18
|
+
expect(Math.round(r.width)).toBe(tokenPx('--bs-breakpoint-xl') || 1280);
|
|
19
|
+
expect(Math.round(r.left - parent.left)).toBe(Math.round(parent.right - r.right));
|
|
20
|
+
});
|
|
21
|
+
it('applies each size from the breakpoint tokens', async () => {
|
|
22
|
+
const expected = { sm: 640, md: 768, lg: 1024, xl: 1280, '2xl': 1536 };
|
|
23
|
+
for (const size of Object.keys(expected)) {
|
|
24
|
+
const { root } = await mount({ size });
|
|
25
|
+
const w = root.querySelector('bs-container').getBoundingClientRect().width;
|
|
26
|
+
expect(Math.round(w)).toBe(expected[size]);
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
it('fluid has no max width', async () => {
|
|
30
|
+
const { root } = await mount({ size: 'fluid' });
|
|
31
|
+
expect(Math.round(root.querySelector('bs-container').getBoundingClientRect().width)).toBe(2000);
|
|
32
|
+
});
|
|
33
|
+
it('padding prop sets horizontal padding, falling back for invalid names', async () => {
|
|
34
|
+
const { root, waitForChanges } = await mount({ padding: '500' });
|
|
35
|
+
const el = root.querySelector('bs-container');
|
|
36
|
+
const pad = () => parseFloat(getComputedStyle(el).paddingLeft);
|
|
37
|
+
const p500 = pad();
|
|
38
|
+
expect(p500).toBeGreaterThan(0);
|
|
39
|
+
el.setAttribute('padding', '300');
|
|
40
|
+
await waitForChanges();
|
|
41
|
+
const p300 = pad();
|
|
42
|
+
expect(p300).toBeLessThan(p500);
|
|
43
|
+
el.setAttribute('padding', 'bogus');
|
|
44
|
+
await waitForChanges();
|
|
45
|
+
expect(pad()).toBe(p300);
|
|
46
|
+
});
|
|
47
|
+
it('box-sizing is border-box and width never exceeds the parent', async () => {
|
|
48
|
+
const { root } = await render(h("div", { style: { width: '500px' } }, h("bs-container", { size: "2xl" })));
|
|
49
|
+
const el = root.querySelector('bs-container');
|
|
50
|
+
expect(getComputedStyle(el).boxSizing).toBe('border-box');
|
|
51
|
+
expect(Math.round(el.getBoundingClientRect().width)).toBe(500);
|
|
52
|
+
});
|
|
53
|
+
it('--bs-container-max-width / --bs-container-padding can be overridden', async () => {
|
|
54
|
+
const { root } = await render(h("div", { style: { width: '2000px' } }, h("bs-container", { style: { '--bs-container-max-width': '400px', '--bs-container-padding': '10px' } })));
|
|
55
|
+
const el = root.querySelector('bs-container');
|
|
56
|
+
expect(Math.round(el.getBoundingClientRect().width)).toBe(400);
|
|
57
|
+
expect(getComputedStyle(el).paddingLeft).toBe('10px');
|
|
58
|
+
});
|
|
59
|
+
});
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/* --bs-container-max-width / --bs-container-padding are public overrides; the -token / -size
|
|
2
|
+
variants below are the defaults set from the props (host-scoped, so a consumer rule wins). */
|
|
3
|
+
:host {
|
|
4
|
+
display: block;
|
|
5
|
+
box-sizing: border-box;
|
|
6
|
+
width: 100%;
|
|
7
|
+
margin-inline: auto;
|
|
8
|
+
max-width: var(--bs-container-max-width, var(--bs-container-size, var(--bs-breakpoint-xl)));
|
|
9
|
+
padding-inline: var(--bs-container-padding, var(--bs-container-padding-token, var(--bs-spacing-300)));
|
|
10
|
+
}
|
|
11
|
+
:host([size='sm']) { --bs-container-size: var(--bs-breakpoint-sm); }
|
|
12
|
+
:host([size='md']) { --bs-container-size: var(--bs-breakpoint-md); }
|
|
13
|
+
:host([size='lg']) { --bs-container-size: var(--bs-breakpoint-lg); }
|
|
14
|
+
:host([size='xl']) { --bs-container-size: var(--bs-breakpoint-xl); }
|
|
15
|
+
:host([size='2xl']) { --bs-container-size: var(--bs-breakpoint-2xl); }
|
|
16
|
+
:host([size='fluid']) { --bs-container-size: none; }
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import { Host, h } from "@stencil/core";
|
|
2
|
+
const SPACING_TOKENS = ['0', '25', '50', '75', '100', '150', '200', '250', '300', '350', '400', '500', '550', '600', '700', '800', '1000', '1200', '1500'];
|
|
3
|
+
/**
|
|
4
|
+
* A centred wrapper that limits content width to a breakpoint and adds horizontal padding.
|
|
5
|
+
*
|
|
6
|
+
* ## When to use
|
|
7
|
+
* - Constraining page or section content to a readable, consistent maximum width.
|
|
8
|
+
*
|
|
9
|
+
* ## When not to use
|
|
10
|
+
* - Arranging children relative to each other (use `bs-stack`).
|
|
11
|
+
* - Full-bleed regions such as hero backgrounds (use `size="fluid"` or no container).
|
|
12
|
+
*
|
|
13
|
+
* @slot - Content to constrain.
|
|
14
|
+
* @prop --bs-container-max-width - Maximum width. Aliased to the `--bs-breakpoint-*` token for `size`; `none` for `fluid`.
|
|
15
|
+
* @prop --bs-container-padding - Horizontal padding. Aliased to the `padding` spacing token (default `--bs-spacing-300`).
|
|
16
|
+
*/
|
|
17
|
+
export class BsContainer {
|
|
18
|
+
/** Maximum width, taken from the breakpoint tokens. `fluid` removes the limit. */
|
|
19
|
+
size = 'xl';
|
|
20
|
+
/** Spacing token name for horizontal padding (e.g. `300` => `--bs-spacing-300`). Invalid values fall back to `300`. */
|
|
21
|
+
padding = '300';
|
|
22
|
+
render() {
|
|
23
|
+
const pad = SPACING_TOKENS.includes(String(this.padding)) ? String(this.padding) : '300';
|
|
24
|
+
return (h(Host, { key: '001d2089d9e69657dad10a4d95c550900bdb5252', style: { '--bs-container-padding-token': `var(--bs-spacing-${pad})` } }, h("slot", { key: '8f983ed8ad608a386d84468682296d9318089d28' })));
|
|
25
|
+
}
|
|
26
|
+
static get is() { return "bs-container"; }
|
|
27
|
+
static get encapsulation() { return "shadow"; }
|
|
28
|
+
static get originalStyleUrls() {
|
|
29
|
+
return {
|
|
30
|
+
"$": ["bs-container.css"]
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
static get styleUrls() {
|
|
34
|
+
return {
|
|
35
|
+
"$": ["bs-container.css"]
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
static get properties() {
|
|
39
|
+
return {
|
|
40
|
+
"size": {
|
|
41
|
+
"type": "string",
|
|
42
|
+
"mutable": false,
|
|
43
|
+
"complexType": {
|
|
44
|
+
"original": "BsContainerSize",
|
|
45
|
+
"resolved": "\"2xl\" | \"fluid\" | \"lg\" | \"md\" | \"sm\" | \"xl\"",
|
|
46
|
+
"references": {
|
|
47
|
+
"BsContainerSize": {
|
|
48
|
+
"location": "local",
|
|
49
|
+
"path": "/home/runner/work/eg-brandsync-storybook/eg-brandsync-storybook/packages/wc/src/components/bs-container/bs-container.tsx",
|
|
50
|
+
"id": "src/components/bs-container/bs-container.tsx::BsContainerSize"
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
"required": false,
|
|
55
|
+
"optional": false,
|
|
56
|
+
"docs": {
|
|
57
|
+
"tags": [],
|
|
58
|
+
"text": "Maximum width, taken from the breakpoint tokens. `fluid` removes the limit."
|
|
59
|
+
},
|
|
60
|
+
"getter": false,
|
|
61
|
+
"setter": false,
|
|
62
|
+
"reflect": true,
|
|
63
|
+
"attribute": "size",
|
|
64
|
+
"defaultValue": "'xl'"
|
|
65
|
+
},
|
|
66
|
+
"padding": {
|
|
67
|
+
"type": "string",
|
|
68
|
+
"mutable": false,
|
|
69
|
+
"complexType": {
|
|
70
|
+
"original": "string",
|
|
71
|
+
"resolved": "string",
|
|
72
|
+
"references": {}
|
|
73
|
+
},
|
|
74
|
+
"required": false,
|
|
75
|
+
"optional": false,
|
|
76
|
+
"docs": {
|
|
77
|
+
"tags": [],
|
|
78
|
+
"text": "Spacing token name for horizontal padding (e.g. `300` => `--bs-spacing-300`). Invalid values fall back to `300`."
|
|
79
|
+
},
|
|
80
|
+
"getter": false,
|
|
81
|
+
"setter": false,
|
|
82
|
+
"reflect": false,
|
|
83
|
+
"attribute": "padding",
|
|
84
|
+
"defaultValue": "'300'"
|
|
85
|
+
}
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
import { componentDescription } from "../../stories-utils";
|
|
3
|
+
const meta = {
|
|
4
|
+
title: 'Components/bs-container',
|
|
5
|
+
parameters: { docs: { description: { component: componentDescription('bs-container') } } },
|
|
6
|
+
render: args => html `
|
|
7
|
+
<bs-container size=${args.size} padding=${args.padding}>
|
|
8
|
+
<div style="background: var(--bs-surface-container); padding: var(--bs-spacing-200)">Container content (${args.size})</div>
|
|
9
|
+
</bs-container>
|
|
10
|
+
`,
|
|
11
|
+
argTypes: {
|
|
12
|
+
size: { control: 'select', options: ['sm', 'md', 'lg', 'xl', '2xl', 'fluid'] },
|
|
13
|
+
padding: { control: 'select', options: ['0', '25', '50', '75', '100', '150', '200', '250', '300', '350', '400', '500', '550', '600', '700', '800', '1000', '1200', '1500'] },
|
|
14
|
+
},
|
|
15
|
+
args: { size: 'xl', padding: '300' },
|
|
16
|
+
};
|
|
17
|
+
export default meta;
|
|
18
|
+
export const Default = {};
|
|
19
|
+
export const Small = { args: { size: 'sm' } };
|
|
20
|
+
export const Medium = { args: { size: 'md' } };
|
|
21
|
+
export const Large = { args: { size: 'lg' } };
|
|
22
|
+
export const ExtraLarge2x = { args: { size: '2xl' } };
|
|
23
|
+
export const Fluid = { args: { size: 'fluid' } };
|
|
24
|
+
export const WidePadding = { args: { size: 'md', padding: '600' } };
|
|
@@ -87,11 +87,11 @@ export class BsDataTable {
|
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
89
|
render() {
|
|
90
|
-
return (h("table", { key: '
|
|
90
|
+
return (h("table", { key: '5b61e4f581c2ab0da069cabf9a612285f98b0865', part: "table", class: "bs-data-table" }, h("thead", { key: 'c3bed54d42e2e2c3d54cfa9754251ab0d34c55fd', part: "head" }, h("tr", { key: '8f0aaa90b06650719423de98e05f39ffce407a67' }, this.selectable && (h("th", { key: 'ed065c125b50493c621c8922cdd3d7ca26222b8e', class: "bs-data-table__select-col" }, this.rows.length > 0 && (h("input", { key: '0e4f29de07f7818e7024714281f5faadcd288c88', type: "checkbox", "aria-label": this.selectAllLabel, checked: this.selectedIds.size > 0 && this.selectedIds.size === this.rows.length, indeterminate: this.selectedIds.size > 0 && this.selectedIds.size < this.rows.length, onChange: this.onSelectAllChange })))), this.columns.map(column => {
|
|
91
91
|
const isSorted = this.sortColumn === column.key;
|
|
92
92
|
const ariaSort = column.sortable ? (isSorted ? (this.sortDirection === 'asc' ? 'ascending' : 'descending') : 'none') : undefined;
|
|
93
93
|
return (h("th", { part: "header-cell", class: "bs-data-table__header-cell", "aria-sort": ariaSort }, column.sortable ? (h("button", { type: "button", class: "bs-data-table__sort-button", onClick: () => this.onHeaderClick(column) }, column.label, isSorted && h("span", { class: "bs-data-table__sort-indicator" }, this.sortDirection === 'asc' ? ' ▲' : ' ▼'))) : (column.label)));
|
|
94
|
-
}))), h("tbody", { key: '
|
|
94
|
+
}))), h("tbody", { key: 'b993a2e1c22d094936c49ad33486b2ecc02861c8', part: "body" }, this.rows.map(row => (h("tr", { part: "row", class: "bs-data-table__row" }, this.selectable && (h("td", { class: "bs-data-table__select-col" }, h("input", { type: "checkbox", checked: this.selectedIds.has(row.id), onChange: ev => this.onRowCheckboxChange(row, ev) }))), this.columns.map(column => this.cellRenderer ? (
|
|
95
95
|
// cellRenderer is a developer-supplied, trusted function (JS-property-only, never
|
|
96
96
|
// derived from untrusted input) -- its HTML output is intentionally not escaped,
|
|
97
97
|
// same trust model as React's dangerouslySetInnerHTML.
|
|
@@ -340,7 +340,7 @@ export class BsDatepicker {
|
|
|
340
340
|
: this.defaultTabbable(days);
|
|
341
341
|
const isInRange = (iso) => !!selectedStart && !!previewEnd && iso > selectedStart && iso < previewEnd;
|
|
342
342
|
const weekdays = this.weekdays();
|
|
343
|
-
return (h("bs-card", { key: '
|
|
343
|
+
return (h("bs-card", { key: 'd2794a112b72b3dc871360b1e57273c9ef097fc4', part: "container", class: "bs-datepicker", surface: "raised" }, h("div", { key: 'bee55a1cd06aa44171f40babae77b1f2f742d160', class: "bs-datepicker__body" }, this.renderHeader(), h("div", { key: 'd4ab1cfd76fcea8b64daeb951da7b36300c036f0', part: "nav", class: "bs-datepicker__nav" }, h("button", { key: '5fcbb3f928db51049fd034beb3519400afe4f128', part: "prev", type: "button", class: "bs-datepicker__nav-button", "aria-label": this.previousLabel, onClick: () => this.moveView(-1) }, h("svg", { key: '18889f8f9dd9364bd73595635b72515b91d35ade', viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true" }, h("path", { key: '3d648cd4be611ef4de37cc08f9017809388d36e3', d: "M15 18L9 12L15 6", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round", "stroke-linejoin": "round" }))), h("div", { key: 'c0647871f1c140472807ae51e04604c6d87ccaa4', part: "title", class: "bs-datepicker__title", "aria-live": "polite" }, this.titleText()), h("button", { key: 'ec3d33aeea146534d6640ac336905a002d0e7dc2', part: "next", type: "button", class: "bs-datepicker__nav-button", "aria-label": this.nextLabel, onClick: () => this.moveView(1) }, h("svg", { key: '5cbac8630a30064d940e5f03ce767b525c09dd7c', viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true" }, h("path", { key: '2c47ca0911b8b42cd3590ff053905df327363e9f', d: "M9 18L15 12L9 6", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round", "stroke-linejoin": "round" })))), h("div", { key: '91a6942792287f3044962fd278e36ed04ec03878', part: "grid", class: "bs-datepicker__grid", role: "grid", "aria-label": this.titleText() }, h("div", { key: '445e0548f0913426fe2eb730f291423d9165f839', class: "bs-datepicker__row", role: "row" }, weekdays.map(w => (h("div", { part: "weekday", class: "bs-datepicker__weekday", role: "columnheader" }, w)))), Array.from({ length: 6 }, (_, r) => {
|
|
344
344
|
const row = days.slice(r * 7, r * 7 + 7);
|
|
345
345
|
return (h("div", { class: "bs-datepicker__row", role: "row" }, row.map((d, c) => {
|
|
346
346
|
const iso = toIso(d);
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { render, h, describe, it, expect } from "@stencil/vitest";
|
|
2
|
+
describe('bs-divider', () => {
|
|
3
|
+
it('defaults to a horizontal separator with ARIA', async () => {
|
|
4
|
+
const { root } = await render(h("div", null, h("bs-divider", null)));
|
|
5
|
+
const el = root.querySelector('bs-divider');
|
|
6
|
+
expect(el).toEqualAttribute('orientation', 'horizontal');
|
|
7
|
+
expect(el).toEqualAttribute('variant', 'default');
|
|
8
|
+
expect(el).toEqualAttribute('role', 'separator');
|
|
9
|
+
expect(el).toEqualAttribute('aria-orientation', 'horizontal');
|
|
10
|
+
});
|
|
11
|
+
it('decorative removes separator semantics', async () => {
|
|
12
|
+
const { root } = await render(h("div", null, h("bs-divider", { decorative: true })));
|
|
13
|
+
const el = root.querySelector('bs-divider');
|
|
14
|
+
expect(el).toEqualAttribute('role', 'none');
|
|
15
|
+
expect(el).toEqualAttribute('aria-hidden', 'true');
|
|
16
|
+
expect(el.hasAttribute('aria-orientation')).toBe(false);
|
|
17
|
+
});
|
|
18
|
+
it('vertical orientation sets aria-orientation and stretches to container height', async () => {
|
|
19
|
+
const { root } = await render(h("div", { style: { display: 'flex', height: '80px', width: '200px' } }, h("bs-divider", { orientation: "vertical" })));
|
|
20
|
+
const el = root.querySelector('bs-divider');
|
|
21
|
+
expect(el).toEqualAttribute('aria-orientation', 'vertical');
|
|
22
|
+
const r = el.getBoundingClientRect();
|
|
23
|
+
expect(Math.round(r.height)).toBe(80);
|
|
24
|
+
expect(Math.round(r.width)).toBe(1);
|
|
25
|
+
});
|
|
26
|
+
it('horizontal divider is full width and 1px thick', async () => {
|
|
27
|
+
const { root } = await render(h("div", { style: { width: '300px' } }, h("bs-divider", null)));
|
|
28
|
+
const r = root.querySelector('bs-divider').getBoundingClientRect();
|
|
29
|
+
expect(Math.round(r.width)).toBe(300);
|
|
30
|
+
expect(Math.round(r.height)).toBe(1);
|
|
31
|
+
});
|
|
32
|
+
it('inset indents the line', async () => {
|
|
33
|
+
const { root } = await render(h("div", { style: { width: '300px' } }, h("bs-divider", { id: "s", inset: "start" }), h("bs-divider", { id: "b", inset: "both" }), h("bs-divider", { id: "n" })));
|
|
34
|
+
const line = (id) => root.querySelector(`#${id}`).shadowRoot.querySelector('.line').getBoundingClientRect();
|
|
35
|
+
expect(Math.round(line('n').width)).toBe(300);
|
|
36
|
+
const start = line('s');
|
|
37
|
+
const both = line('b');
|
|
38
|
+
expect(start.width).toBeLessThan(300);
|
|
39
|
+
expect(both.width).toBeLessThan(start.width);
|
|
40
|
+
expect(Math.round(start.left - line('n').left)).toBeGreaterThan(0);
|
|
41
|
+
});
|
|
42
|
+
it('subtle variant uses a different colour than default', async () => {
|
|
43
|
+
const { root } = await render(h("div", null, h("bs-divider", { id: "d" }), h("bs-divider", { id: "s", variant: "subtle" })));
|
|
44
|
+
const bg = (id) => getComputedStyle(root.querySelector(`#${id}`).shadowRoot.querySelector('.line')).backgroundColor;
|
|
45
|
+
expect(bg('s')).not.toBe(bg('d'));
|
|
46
|
+
});
|
|
47
|
+
});
|