@brandsync/wc 0.0.11 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/custom-elements.json +5869 -1633
- package/dist/brandsync-wc/brandsync-wc.css +20 -0
- package/dist/brandsync-wc/brandsync-wc.esm.js +1 -1
- package/dist/brandsync-wc/p-00bb9bda.entry.js +1 -0
- package/dist/brandsync-wc/{p-8dff4f24.entry.js → p-0847f5c0.entry.js} +1 -1
- package/dist/brandsync-wc/p-0ba35c3b.entry.js +1 -0
- package/dist/brandsync-wc/{p-073e5fee.entry.js → p-0f3cb0c4.entry.js} +1 -1
- package/dist/brandsync-wc/p-10f6f3cd.entry.js +1 -0
- package/dist/brandsync-wc/{p-c6d330c3.entry.js → p-111974df.entry.js} +1 -1
- package/dist/brandsync-wc/p-11f3fceb.entry.js +1 -0
- package/dist/brandsync-wc/p-171fed0c.entry.js +1 -0
- package/dist/brandsync-wc/{p-dd224cb3.entry.js → p-18813680.entry.js} +1 -1
- package/dist/brandsync-wc/p-1b7c9928.entry.js +1 -0
- package/dist/brandsync-wc/p-1ce7dd64.entry.js +1 -0
- package/dist/brandsync-wc/p-2063a6d6.entry.js +1 -0
- package/dist/brandsync-wc/{p-4ca15322.entry.js → p-20c24179.entry.js} +1 -1
- package/dist/brandsync-wc/{p-b174403d.entry.js → p-321ed4d3.entry.js} +1 -1
- package/dist/brandsync-wc/p-38aad266.entry.js +1 -0
- package/dist/brandsync-wc/p-43e37883.entry.js +1 -0
- package/dist/brandsync-wc/p-55a8d4b5.entry.js +1 -0
- package/dist/brandsync-wc/p-59ac2495.entry.js +1 -0
- package/dist/brandsync-wc/p-5ae9e60e.entry.js +1 -0
- package/dist/brandsync-wc/p-6b469b2d.entry.js +1 -0
- package/dist/brandsync-wc/p-6d85fba4.entry.js +1 -0
- package/dist/brandsync-wc/p-6e95eb36.entry.js +1 -0
- package/dist/brandsync-wc/{p-84ae4420.entry.js → p-73217b90.entry.js} +1 -1
- package/dist/brandsync-wc/p-752c04c8.entry.js +1 -0
- package/dist/brandsync-wc/p-79af762c.entry.js +1 -0
- package/dist/brandsync-wc/p-81d49240.entry.js +1 -0
- package/dist/brandsync-wc/p-91551e7b.entry.js +1 -0
- package/dist/brandsync-wc/p-917a5bbc.entry.js +1 -0
- package/dist/brandsync-wc/{p-0b858120.entry.js → p-9876e83c.entry.js} +1 -1
- package/dist/brandsync-wc/p-9bcd99aa.entry.js +1 -0
- package/dist/brandsync-wc/{p-d1dc2ced.entry.js → p-9c4768aa.entry.js} +1 -1
- package/dist/brandsync-wc/{p-DP_bvuvB.js → p-Do3l4of3.js} +2 -2
- package/dist/brandsync-wc/p-aa43d478.entry.js +1 -0
- package/dist/brandsync-wc/p-c3079ad7.entry.js +1 -0
- package/dist/brandsync-wc/{p-74a4dd91.entry.js → p-c3c383dc.entry.js} +1 -1
- package/dist/brandsync-wc/p-cc79e75f.entry.js +1 -0
- package/dist/brandsync-wc/p-ce7fc368.entry.js +1 -0
- package/dist/brandsync-wc/{p-030a8ba7.entry.js → p-d3265e70.entry.js} +1 -1
- package/dist/brandsync-wc/p-d55bbcec.entry.js +1 -0
- package/dist/brandsync-wc/{p-1bf0b2d5.entry.js → p-e93e944b.entry.js} +1 -1
- package/dist/brandsync-wc/{p-7a605d98.entry.js → p-eb04c578.entry.js} +1 -1
- package/dist/brandsync-wc/{p-3c8fbaa8.entry.js → p-f0ae2740.entry.js} +1 -1
- package/dist/brandsync-wc/p-f4f22015.entry.js +1 -0
- package/dist/cjs/brandsync-wc.cjs.js +2 -2
- package/dist/cjs/bs-ai-disclaimer.cjs.entry.js +3 -2
- package/dist/cjs/bs-ai-greeting.cjs.entry.js +2 -2
- package/dist/cjs/bs-ai-thinking.cjs.entry.js +2 -2
- package/dist/cjs/bs-attachment-list.cjs.entry.js +2 -2
- package/dist/cjs/bs-attachment.cjs.entry.js +3 -3
- package/dist/cjs/bs-avatar.cjs.entry.js +60 -0
- package/dist/cjs/bs-badge.cjs.entry.js +1 -1
- package/dist/cjs/bs-breadcrumb-overflow.cjs.entry.js +56 -0
- package/dist/cjs/bs-breadcrumb.cjs.entry.js +33 -0
- package/dist/cjs/bs-breadcrumbs.cjs.entry.js +49 -0
- package/dist/cjs/bs-button-skeleton.cjs.entry.js +2 -2
- package/dist/cjs/bs-button.cjs.entry.js +3 -3
- package/dist/cjs/bs-card.cjs.entry.js +10 -3
- package/dist/cjs/bs-chatbot-feedback.cjs.entry.js +2 -2
- package/dist/cjs/bs-chatbot-header.cjs.entry.js +2 -2
- package/dist/cjs/bs-chatbot-response-action.cjs.entry.js +2 -2
- package/dist/cjs/bs-chatbot-sources-drawer.cjs.entry.js +2 -2
- package/dist/cjs/bs-chatbot-suggestion-button.cjs.entry.js +2 -2
- package/dist/cjs/bs-checkbox-skeleton.cjs.entry.js +20 -0
- package/dist/cjs/bs-checkbox.cjs.entry.js +14 -3
- package/dist/cjs/bs-composer-status-banner.cjs.entry.js +14 -2
- package/dist/cjs/bs-composer.cjs.entry.js +37 -4
- package/dist/cjs/bs-data-table.cjs.entry.js +3 -3
- package/dist/cjs/bs-dialog.cjs.entry.js +110 -0
- package/dist/cjs/bs-icon-button.cjs.entry.js +40 -0
- package/dist/cjs/bs-inline-tab.cjs.entry.js +69 -0
- package/dist/cjs/bs-input.cjs.entry.js +24 -12
- package/dist/cjs/bs-logo.cjs.entry.js +165 -0
- package/dist/cjs/{bs-menu_2.cjs.entry.js → bs-menu-item.cjs.entry.js} +2 -15
- package/dist/cjs/bs-menu.cjs.entry.js +17 -0
- package/dist/cjs/bs-navigation-drawer-item.cjs.entry.js +104 -0
- package/dist/cjs/bs-navigation-drawer.cjs.entry.js +87 -0
- package/dist/cjs/bs-navigation-header.cjs.entry.js +44 -0
- package/dist/cjs/bs-pagination.cjs.entry.js +85 -0
- package/dist/cjs/bs-radio.cjs.entry.js +49 -0
- package/dist/cjs/bs-slider.cjs.entry.js +191 -0
- package/dist/cjs/bs-snackbar.cjs.entry.js +41 -0
- package/dist/cjs/bs-source-link.cjs.entry.js +3 -3
- package/dist/cjs/bs-switch.cjs.entry.js +57 -0
- package/dist/cjs/bs-tab.cjs.entry.js +80 -0
- package/dist/cjs/bs-tabs.cjs.entry.js +39 -0
- package/dist/cjs/bs-tooltip.cjs.entry.js +2 -2
- package/dist/cjs/{index-CGrdFg95.js → index-DHVw-IPK.js} +2 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +21 -3
- package/dist/collection/components/bs-ai-chatbot/bs-ai-chatbot.stories.js +26 -11
- package/dist/collection/components/bs-ai-disclaimer/bs-ai-disclaimer.js +2 -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-attachment/bs-attachment.css +12 -33
- package/dist/collection/components/bs-attachment/bs-attachment.js +4 -10
- package/dist/collection/components/bs-attachment-list/bs-attachment-list.js +1 -1
- package/dist/collection/components/bs-avatar/bs-avatar.cmp.test.js +54 -0
- package/dist/collection/components/bs-avatar/bs-avatar.css +197 -0
- package/dist/collection/components/bs-avatar/bs-avatar.js +251 -0
- package/dist/collection/components/bs-avatar/bs-avatar.stories.js +67 -0
- package/dist/collection/components/bs-breadcrumb/bs-breadcrumb/bs-breadcrumb.cmp.test.js +62 -0
- package/dist/collection/components/bs-breadcrumb/bs-breadcrumb/bs-breadcrumb.css +93 -0
- package/dist/collection/components/bs-breadcrumb/bs-breadcrumb/bs-breadcrumb.js +130 -0
- package/dist/collection/components/bs-breadcrumb/bs-breadcrumb-overflow/bs-breadcrumb-overflow.cmp.test.js +118 -0
- package/dist/collection/components/bs-breadcrumb/bs-breadcrumb-overflow/bs-breadcrumb-overflow.css +125 -0
- package/dist/collection/components/bs-breadcrumb/bs-breadcrumb-overflow/bs-breadcrumb-overflow.js +192 -0
- package/dist/collection/components/bs-breadcrumb/bs-breadcrumbs/bs-breadcrumbs.cmp.test.js +58 -0
- package/dist/collection/components/bs-breadcrumb/bs-breadcrumbs/bs-breadcrumbs.css +18 -0
- package/dist/collection/components/bs-breadcrumb/bs-breadcrumbs/bs-breadcrumbs.js +129 -0
- package/dist/collection/components/bs-breadcrumb/bs-breadcrumbs/bs-breadcrumbs.stories.js +84 -0
- package/dist/collection/components/bs-button/{bs-button.cmp.test.js → bs-button/bs-button.cmp.test.js} +26 -0
- package/dist/collection/components/bs-button/{bs-button.css → bs-button/bs-button.css} +57 -6
- package/dist/collection/components/bs-button/{bs-button.js → bs-button/bs-button.js} +10 -5
- package/dist/collection/components/bs-button/{bs-button.stories.js → bs-button/bs-button.stories.js} +2 -27
- package/dist/collection/components/bs-button/bs-icon-button/bs-icon-button.cmp.test.js +83 -0
- package/dist/collection/components/bs-button/bs-icon-button/bs-icon-button.css +346 -0
- package/dist/collection/components/bs-button/bs-icon-button/bs-icon-button.js +185 -0
- package/dist/collection/components/bs-button/bs-icon-button/bs-icon-button.stories.js +74 -0
- package/dist/collection/components/bs-button-skeleton/bs-button-skeleton.js +3 -3
- package/dist/collection/components/bs-card/bs-card.cmp.test.js +19 -0
- package/dist/collection/components/bs-card/bs-card.css +37 -5
- package/dist/collection/components/bs-card/bs-card.js +18 -2
- package/dist/collection/components/bs-card/bs-card.stories.js +17 -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.css +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.cmp.test.js +23 -0
- package/dist/collection/components/bs-checkbox/bs-checkbox-skeleton/bs-checkbox-skeleton.css +64 -0
- package/dist/collection/components/bs-checkbox/bs-checkbox-skeleton/bs-checkbox-skeleton.js +81 -0
- package/dist/collection/components/bs-checkbox/bs-checkbox-skeleton/bs-checkbox-skeleton.stories.js +25 -0
- package/dist/collection/components/bs-checkbox/bs-checkbox.cmp.test.js +10 -0
- package/dist/collection/components/bs-checkbox/bs-checkbox.css +7 -1
- package/dist/collection/components/bs-checkbox/bs-checkbox.js +32 -1
- package/dist/collection/components/bs-checkbox/bs-checkbox.stories.js +12 -0
- package/dist/collection/components/bs-composer/bs-composer.cmp.test.js +48 -7
- package/dist/collection/components/bs-composer/bs-composer.css +15 -0
- package/dist/collection/components/bs-composer/bs-composer.js +38 -4
- package/dist/collection/components/bs-composer-status-banner/bs-composer-status-banner.cmp.test.js +47 -1
- package/dist/collection/components/bs-composer-status-banner/bs-composer-status-banner.js +20 -1
- package/dist/collection/components/bs-data-table/bs-data-table.js +2 -2
- package/dist/collection/components/{bs-modal/bs-modal.cmp.test.js → bs-dialog/bs-dialog.cmp.test.js} +63 -19
- package/dist/collection/components/bs-dialog/bs-dialog.css +130 -0
- package/dist/collection/components/bs-dialog/bs-dialog.js +273 -0
- package/dist/collection/components/bs-dialog/bs-dialog.stories.js +115 -0
- package/dist/collection/components/bs-input/bs-input.cmp.test.js +20 -0
- package/dist/collection/components/bs-input/bs-input.css +80 -2
- package/dist/collection/components/bs-input/bs-input.js +28 -10
- package/dist/collection/components/bs-input/bs-input.stories.js +14 -11
- package/dist/collection/components/bs-logo/brandsync-logo-full-dark.js +44 -0
- package/dist/collection/components/bs-logo/brandsync-logo-full-light.js +40 -0
- package/dist/collection/components/bs-logo/brandsync-logo-mark.js +17 -0
- package/dist/collection/components/bs-logo/bs-logo.cmp.test.js +113 -0
- package/dist/collection/components/bs-logo/bs-logo.css +79 -0
- package/dist/collection/components/bs-logo/bs-logo.js +193 -0
- package/dist/collection/components/bs-logo/bs-logo.stories.js +69 -0
- package/dist/collection/components/bs-menu/bs-menu.js +1 -1
- package/dist/collection/components/bs-menu-item/bs-menu-item.js +1 -1
- package/dist/collection/components/bs-pagination/bs-pagination.cmp.test.js +102 -0
- package/dist/collection/components/bs-pagination/bs-pagination.css +120 -0
- package/dist/collection/components/bs-pagination/bs-pagination.js +233 -0
- package/dist/collection/components/bs-pagination/bs-pagination.stories.js +43 -0
- package/dist/collection/components/bs-radio/bs-radio.cmp.test.js +76 -0
- package/dist/collection/components/bs-radio/bs-radio.css +164 -0
- package/dist/collection/components/bs-radio/bs-radio.js +170 -0
- package/dist/collection/components/bs-radio/bs-radio.stories.js +56 -0
- package/dist/collection/components/bs-slider/bs-slider.cmp.test.js +139 -0
- package/dist/collection/components/bs-slider/bs-slider.css +409 -0
- package/dist/collection/components/bs-slider/bs-slider.js +499 -0
- package/dist/collection/components/bs-slider/bs-slider.stories.js +70 -0
- package/dist/collection/components/bs-snackbar/bs-snackbar.cmp.test.js +77 -0
- package/dist/collection/components/bs-snackbar/bs-snackbar.css +321 -0
- package/dist/collection/components/bs-snackbar/bs-snackbar.js +172 -0
- package/dist/collection/components/bs-snackbar/bs-snackbar.stories.js +59 -0
- package/dist/collection/components/bs-source-link/bs-source-link.js +2 -2
- package/dist/collection/components/bs-switch/bs-switch.cmp.test.js +71 -0
- package/dist/collection/components/bs-switch/bs-switch.css +196 -0
- package/dist/collection/components/bs-switch/bs-switch.js +185 -0
- package/dist/collection/components/bs-switch/bs-switch.stories.js +60 -0
- package/dist/collection/components/bs-tab/bs-inline-tab/bs-inline-tab.cmp.test.js +104 -0
- package/dist/collection/components/bs-tab/bs-inline-tab/bs-inline-tab.css +163 -0
- package/dist/collection/components/bs-tab/bs-inline-tab/bs-inline-tab.js +192 -0
- package/dist/collection/components/bs-tab/bs-inline-tab/bs-inline-tab.stories.js +95 -0
- package/dist/collection/components/bs-tab/bs-tab/bs-tab.cmp.test.js +120 -0
- package/dist/collection/components/bs-tab/bs-tab/bs-tab.css +216 -0
- package/dist/collection/components/bs-tab/bs-tab/bs-tab.js +232 -0
- package/dist/collection/components/bs-tab/bs-tab/bs-tab.stories.js +138 -0
- package/dist/collection/components/bs-tab/bs-tabs/bs-tabs.cmp.test.js +61 -0
- package/dist/collection/components/bs-tab/bs-tabs/bs-tabs.css +39 -0
- package/dist/collection/components/bs-tab/bs-tabs/bs-tabs.js +133 -0
- package/dist/collection/components/bs-tab/bs-tabs/bs-tabs.stories.js +39 -0
- package/dist/collection/components/bs-tooltip/bs-tooltip.js +1 -1
- package/dist/collection/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer/bs-navigation-drawer.cmp.test.js +143 -0
- package/dist/collection/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer/bs-navigation-drawer.css +257 -0
- package/dist/collection/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer/bs-navigation-drawer.js +281 -0
- package/dist/collection/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer/bs-navigation-drawer.stories.js +274 -0
- package/dist/collection/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer-item/bs-navigation-drawer-item.cmp.test.js +172 -0
- package/dist/collection/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer-item/bs-navigation-drawer-item.css +325 -0
- package/dist/collection/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer-item/bs-navigation-drawer-item.js +314 -0
- package/dist/collection/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer-item/bs-navigation-drawer-item.stories.js +78 -0
- package/dist/collection/components/ui-shell/bs-navigation-header/bs-navigation-header/bs-navigation-header.cmp.test.js +77 -0
- package/dist/collection/components/ui-shell/bs-navigation-header/bs-navigation-header/bs-navigation-header.css +106 -0
- package/dist/collection/components/ui-shell/bs-navigation-header/bs-navigation-header/bs-navigation-header.js +188 -0
- package/dist/collection/components/ui-shell/bs-navigation-header/bs-navigation-header/bs-navigation-header.stories.js +446 -0
- 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-attachment-list.js +1 -1
- package/dist/components/bs-attachment.js +1 -1
- package/dist/components/bs-avatar.d.ts +11 -0
- package/dist/components/bs-avatar.js +1 -0
- package/dist/components/bs-badge.js +1 -1
- package/dist/components/bs-breadcrumb-overflow.d.ts +11 -0
- package/dist/components/bs-breadcrumb-overflow.js +1 -0
- package/dist/components/bs-breadcrumb.d.ts +11 -0
- package/dist/components/bs-breadcrumb.js +1 -0
- package/dist/components/bs-breadcrumbs.d.ts +11 -0
- package/dist/components/bs-breadcrumbs.js +1 -0
- package/dist/components/bs-button-skeleton.js +1 -1
- package/dist/components/bs-button.js +1 -1
- package/dist/components/bs-card.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.d.ts +11 -0
- package/dist/components/bs-checkbox-skeleton.js +1 -0
- package/dist/components/bs-checkbox.js +1 -1
- package/dist/components/bs-composer-status-banner.js +1 -1
- package/dist/components/bs-composer.js +1 -1
- package/dist/components/bs-data-table.js +1 -1
- package/dist/components/bs-dialog.d.ts +11 -0
- package/dist/components/bs-dialog.js +1 -0
- package/dist/components/bs-icon-button.d.ts +11 -0
- package/dist/components/bs-icon-button.js +1 -0
- package/dist/components/bs-inline-tab.d.ts +11 -0
- package/dist/components/bs-inline-tab.js +1 -0
- package/dist/components/bs-input.js +1 -1
- package/dist/components/{bs-modal.d.ts → bs-logo.d.ts} +4 -4
- package/dist/components/bs-logo.js +1 -0
- package/dist/components/bs-menu-item.js +1 -1
- package/dist/components/bs-menu.js +1 -1
- package/dist/components/bs-navigation-drawer-item.d.ts +11 -0
- package/dist/components/bs-navigation-drawer-item.js +1 -0
- package/dist/components/bs-navigation-drawer.d.ts +11 -0
- package/dist/components/bs-navigation-drawer.js +1 -0
- package/dist/components/bs-navigation-header.d.ts +11 -0
- package/dist/components/bs-navigation-header.js +1 -0
- package/dist/components/bs-pagination.d.ts +11 -0
- package/dist/components/bs-pagination.js +1 -0
- package/dist/components/bs-radio.d.ts +11 -0
- package/dist/components/bs-radio.js +1 -0
- package/dist/components/bs-slider.d.ts +11 -0
- package/dist/components/bs-slider.js +1 -0
- package/dist/components/bs-snackbar.d.ts +11 -0
- package/dist/components/bs-snackbar.js +1 -0
- package/dist/components/bs-source-link.js +1 -1
- package/dist/components/bs-switch.d.ts +11 -0
- package/dist/components/bs-switch.js +1 -0
- package/dist/components/bs-tab.d.ts +11 -0
- package/dist/components/bs-tab.js +1 -0
- package/dist/components/bs-tabs.d.ts +11 -0
- package/dist/components/bs-tabs.js +1 -0
- package/dist/components/bs-tooltip.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/p-BFcVSpES.js +1 -0
- package/dist/components/{p-D1cYtKyN.js → p-BJZYe7M4.js} +1 -1
- package/dist/components/p-BKaZWFE1.js +1 -0
- package/dist/components/{p-BUbGEXL7.js → p-BtX5URLk.js} +1 -1
- package/dist/components/{p-B9PrXIl_.js → p-CgaPcyEJ.js} +1 -1
- package/dist/components/{p-D2HDHZjz.js → p-qK1XlpTA.js} +1 -1
- package/dist/esm/brandsync-wc.js +3 -3
- package/dist/esm/bs-ai-disclaimer.entry.js +3 -2
- package/dist/esm/bs-ai-greeting.entry.js +2 -2
- package/dist/esm/bs-ai-thinking.entry.js +2 -2
- package/dist/esm/bs-attachment-list.entry.js +2 -2
- package/dist/esm/bs-attachment.entry.js +3 -3
- package/dist/esm/bs-avatar.entry.js +58 -0
- package/dist/esm/bs-badge.entry.js +1 -1
- package/dist/esm/bs-breadcrumb-overflow.entry.js +54 -0
- package/dist/esm/bs-breadcrumb.entry.js +31 -0
- package/dist/esm/bs-breadcrumbs.entry.js +47 -0
- package/dist/esm/bs-button-skeleton.entry.js +2 -2
- package/dist/esm/bs-button.entry.js +3 -3
- package/dist/esm/bs-card.entry.js +10 -3
- package/dist/esm/bs-chatbot-feedback.entry.js +2 -2
- package/dist/esm/bs-chatbot-header.entry.js +2 -2
- package/dist/esm/bs-chatbot-response-action.entry.js +2 -2
- package/dist/esm/bs-chatbot-sources-drawer.entry.js +2 -2
- package/dist/esm/bs-chatbot-suggestion-button.entry.js +2 -2
- package/dist/esm/bs-checkbox-skeleton.entry.js +18 -0
- package/dist/esm/bs-checkbox.entry.js +14 -3
- package/dist/esm/bs-composer-status-banner.entry.js +14 -2
- package/dist/esm/bs-composer.entry.js +37 -4
- package/dist/esm/bs-data-table.entry.js +3 -3
- package/dist/esm/bs-dialog.entry.js +108 -0
- package/dist/esm/bs-icon-button.entry.js +38 -0
- package/dist/esm/bs-inline-tab.entry.js +67 -0
- package/dist/esm/bs-input.entry.js +24 -12
- package/dist/esm/bs-logo.entry.js +163 -0
- package/dist/esm/{bs-menu_2.entry.js → bs-menu-item.entry.js} +3 -15
- package/dist/esm/bs-menu.entry.js +15 -0
- package/dist/esm/bs-navigation-drawer-item.entry.js +102 -0
- package/dist/esm/bs-navigation-drawer.entry.js +85 -0
- package/dist/esm/bs-navigation-header.entry.js +42 -0
- package/dist/esm/bs-pagination.entry.js +83 -0
- package/dist/esm/bs-radio.entry.js +47 -0
- package/dist/esm/bs-slider.entry.js +189 -0
- package/dist/esm/bs-snackbar.entry.js +39 -0
- package/dist/esm/bs-source-link.entry.js +3 -3
- package/dist/esm/bs-switch.entry.js +55 -0
- package/dist/esm/bs-tab.entry.js +78 -0
- package/dist/esm/bs-tabs.entry.js +37 -0
- package/dist/esm/bs-tooltip.entry.js +2 -2
- package/dist/esm/{index-DP_bvuvB.js → index-Do3l4of3.js} +2 -2
- package/dist/esm/loader.js +3 -3
- package/dist/types/components/bs-attachment/bs-attachment.d.ts +3 -9
- package/dist/types/components/bs-avatar/bs-avatar.d.ts +67 -0
- package/dist/types/components/bs-avatar/bs-avatar.stories.d.ts +20 -0
- package/dist/types/components/bs-breadcrumb/bs-breadcrumb/bs-breadcrumb.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-breadcrumb/bs-breadcrumb/bs-breadcrumb.d.ts +44 -0
- package/dist/types/components/bs-breadcrumb/bs-breadcrumb-overflow/bs-breadcrumb-overflow.d.ts +69 -0
- package/dist/types/components/bs-breadcrumb/bs-breadcrumbs/bs-breadcrumbs.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-breadcrumb/bs-breadcrumbs/bs-breadcrumbs.d.ts +45 -0
- package/dist/types/components/bs-breadcrumb/bs-breadcrumbs/bs-breadcrumbs.stories.d.ts +14 -0
- package/dist/types/components/bs-button/bs-button/bs-button.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-button/{bs-button.d.ts → bs-button/bs-button.d.ts} +5 -0
- package/dist/types/components/bs-button/{bs-button.stories.d.ts → bs-button/bs-button.stories.d.ts} +0 -2
- package/dist/types/components/bs-button/bs-icon-button/bs-icon-button.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-button/bs-icon-button/bs-icon-button.d.ts +51 -0
- package/dist/types/components/bs-button/bs-icon-button/bs-icon-button.stories.d.ts +16 -0
- package/dist/types/components/bs-button-skeleton/bs-button-skeleton.d.ts +1 -1
- package/dist/types/components/bs-button-skeleton/bs-button-skeleton.stories.d.ts +1 -1
- package/dist/types/components/bs-card/bs-card.d.ts +10 -1
- package/dist/types/components/bs-card/bs-card.stories.d.ts +1 -0
- package/dist/types/components/bs-checkbox/bs-checkbox-skeleton/bs-checkbox-skeleton.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-checkbox/bs-checkbox-skeleton/bs-checkbox-skeleton.d.ts +36 -0
- package/dist/types/components/bs-checkbox/bs-checkbox-skeleton/bs-checkbox-skeleton.stories.d.ts +10 -0
- package/dist/types/components/bs-checkbox/bs-checkbox.d.ts +11 -0
- package/dist/types/components/bs-checkbox/bs-checkbox.stories.d.ts +1 -0
- package/dist/types/components/bs-composer/bs-composer.d.ts +26 -2
- package/dist/types/components/bs-composer-status-banner/bs-composer-status-banner.d.ts +14 -0
- package/dist/types/components/bs-dialog/bs-dialog.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-dialog/bs-dialog.d.ts +74 -0
- package/dist/types/components/{bs-modal/bs-modal.stories.d.ts → bs-dialog/bs-dialog.stories.d.ts} +5 -3
- package/dist/types/components/bs-input/bs-input.d.ts +8 -1
- package/dist/types/components/bs-logo/brandsync-logo-full-dark.d.ts +1 -0
- package/dist/types/components/bs-logo/brandsync-logo-full-light.d.ts +1 -0
- package/dist/types/components/bs-logo/brandsync-logo-mark.d.ts +1 -0
- package/dist/types/components/bs-logo/bs-logo.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-logo/bs-logo.d.ts +73 -0
- package/dist/types/components/bs-logo/bs-logo.stories.d.ts +17 -0
- package/dist/types/components/bs-pagination/bs-pagination.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-pagination/bs-pagination.d.ts +51 -0
- package/dist/types/components/bs-pagination/bs-pagination.stories.d.ts +14 -0
- package/dist/types/components/bs-radio/bs-radio.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-radio/bs-radio.d.ts +45 -0
- package/dist/types/components/bs-radio/bs-radio.stories.d.ts +16 -0
- package/dist/types/components/bs-slider/bs-slider.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-slider/bs-slider.d.ts +109 -0
- package/dist/types/components/bs-slider/bs-slider.stories.d.ts +24 -0
- package/dist/types/components/bs-snackbar/bs-snackbar.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-snackbar/bs-snackbar.d.ts +51 -0
- package/dist/types/components/bs-snackbar/bs-snackbar.stories.d.ts +16 -0
- package/dist/types/components/bs-switch/bs-switch.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-switch/bs-switch.d.ts +45 -0
- package/dist/types/components/bs-switch/bs-switch.stories.d.ts +17 -0
- package/dist/types/components/bs-tab/bs-inline-tab/bs-inline-tab.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-tab/bs-inline-tab/bs-inline-tab.d.ts +65 -0
- package/dist/types/components/bs-tab/bs-inline-tab/bs-inline-tab.stories.d.ts +22 -0
- package/dist/types/components/bs-tab/bs-tab/bs-tab.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-tab/bs-tab/bs-tab.d.ts +74 -0
- package/dist/types/components/bs-tab/bs-tab/bs-tab.stories.d.ts +30 -0
- package/dist/types/components/bs-tab/bs-tabs/bs-tabs.cmp.test.d.ts +1 -0
- package/dist/types/components/bs-tab/bs-tabs/bs-tabs.d.ts +45 -0
- package/dist/types/components/bs-tab/bs-tabs/bs-tabs.stories.d.ts +13 -0
- package/dist/types/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer/bs-navigation-drawer.cmp.test.d.ts +1 -0
- package/dist/types/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer/bs-navigation-drawer.d.ts +104 -0
- package/dist/types/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer/bs-navigation-drawer.stories.d.ts +19 -0
- package/dist/types/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer-item/bs-navigation-drawer-item.cmp.test.d.ts +1 -0
- package/dist/types/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer-item/bs-navigation-drawer-item.d.ts +103 -0
- package/dist/types/components/ui-shell/bs-navigation-drawer/bs-navigation-drawer-item/bs-navigation-drawer-item.stories.d.ts +20 -0
- package/dist/types/components/ui-shell/bs-navigation-header/bs-navigation-header/bs-navigation-header.cmp.test.d.ts +1 -0
- package/dist/types/components/ui-shell/bs-navigation-header/bs-navigation-header/bs-navigation-header.d.ts +60 -0
- package/dist/types/components/ui-shell/bs-navigation-header/bs-navigation-header/bs-navigation-header.stories.d.ts +25 -0
- package/dist/types/components.d.ts +2908 -114
- package/package.json +1 -1
- package/dist/brandsync-wc/p-2598ca88.entry.js +0 -1
- package/dist/brandsync-wc/p-3dd9b814.entry.js +0 -1
- package/dist/brandsync-wc/p-41edb0a2.entry.js +0 -1
- package/dist/brandsync-wc/p-6254dcbe.entry.js +0 -1
- package/dist/brandsync-wc/p-7131d0a1.entry.js +0 -1
- package/dist/brandsync-wc/p-8c302968.entry.js +0 -1
- package/dist/brandsync-wc/p-8d78171b.entry.js +0 -1
- package/dist/brandsync-wc/p-93e44903.entry.js +0 -1
- package/dist/brandsync-wc/p-aa45d877.entry.js +0 -1
- package/dist/cjs/bs-modal.cjs.entry.js +0 -69
- package/dist/collection/components/bs-modal/bs-modal.css +0 -66
- package/dist/collection/components/bs-modal/bs-modal.js +0 -198
- package/dist/collection/components/bs-modal/bs-modal.stories.js +0 -38
- package/dist/components/bs-modal.js +0 -1
- package/dist/esm/bs-modal.entry.js +0 -67
- package/dist/types/components/bs-modal/bs-modal.d.ts +0 -45
- /package/dist/types/components/{bs-button/bs-button.cmp.test.d.ts → bs-avatar/bs-avatar.cmp.test.d.ts} +0 -0
- /package/dist/types/components/{bs-modal/bs-modal.cmp.test.d.ts → bs-breadcrumb/bs-breadcrumb-overflow/bs-breadcrumb-overflow.cmp.test.d.ts} +0 -0
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
import { componentDescription, propDescription } from "../../../stories-utils";
|
|
3
|
+
const sizes = ['sm', 'md'];
|
|
4
|
+
const meta = {
|
|
5
|
+
title: 'Components/bs-breadcrumbs',
|
|
6
|
+
parameters: { docs: { description: { component: componentDescription('bs-breadcrumbs') } } },
|
|
7
|
+
argTypes: {
|
|
8
|
+
label: { control: 'text', description: propDescription('bs-breadcrumbs', 'label') },
|
|
9
|
+
size: { control: { type: 'select' }, options: sizes, description: propDescription('bs-breadcrumbs', 'size') },
|
|
10
|
+
},
|
|
11
|
+
args: {
|
|
12
|
+
label: 'Breadcrumb',
|
|
13
|
+
size: 'md',
|
|
14
|
+
},
|
|
15
|
+
};
|
|
16
|
+
export default meta;
|
|
17
|
+
const overflowItems = [
|
|
18
|
+
{ label: 'Products', href: '/products' },
|
|
19
|
+
{ label: 'Category', href: '/products/category' },
|
|
20
|
+
];
|
|
21
|
+
// A short trail needs no overflow at all -- bs-breadcrumb-overflow is only placed by the consumer
|
|
22
|
+
// when there are actually hidden crumbs to disclose (there's no automatic maxItems collapsing).
|
|
23
|
+
export const Default = {
|
|
24
|
+
render: args => html `
|
|
25
|
+
<bs-breadcrumbs label=${args.label} size=${args.size}>
|
|
26
|
+
<bs-breadcrumb href="/">Home</bs-breadcrumb>
|
|
27
|
+
<bs-breadcrumb href="/settings">Settings</bs-breadcrumb>
|
|
28
|
+
<bs-breadcrumb current>Profile</bs-breadcrumb>
|
|
29
|
+
</bs-breadcrumbs>
|
|
30
|
+
`,
|
|
31
|
+
};
|
|
32
|
+
// size="sm" set once on the container, propagated as a JS property to every slotted crumb (and the
|
|
33
|
+
// overflow disclosure) -- see bs-breadcrumbs.tsx's propagateSize.
|
|
34
|
+
export const Small = {
|
|
35
|
+
args: { size: 'sm' },
|
|
36
|
+
render: args => html `
|
|
37
|
+
<bs-breadcrumbs label=${args.label} size=${args.size}>
|
|
38
|
+
<bs-breadcrumb href="/">Home</bs-breadcrumb>
|
|
39
|
+
<bs-breadcrumb-overflow .items=${overflowItems}></bs-breadcrumb-overflow>
|
|
40
|
+
<bs-breadcrumb href="/settings/profile">Profile</bs-breadcrumb>
|
|
41
|
+
<bs-breadcrumb current>Edit</bs-breadcrumb>
|
|
42
|
+
</bs-breadcrumbs>
|
|
43
|
+
`,
|
|
44
|
+
};
|
|
45
|
+
// A longer trail where the consumer has chosen to hide the middle crumbs behind a manually placed
|
|
46
|
+
// <bs-breadcrumb-overflow>, reachable via its ellipsis disclosure.
|
|
47
|
+
export const WithOverflow = {
|
|
48
|
+
name: 'With overflow',
|
|
49
|
+
render: args => html `
|
|
50
|
+
<bs-breadcrumbs label=${args.label}>
|
|
51
|
+
<bs-breadcrumb href="/">Home</bs-breadcrumb>
|
|
52
|
+
<bs-breadcrumb-overflow .items=${overflowItems}></bs-breadcrumb-overflow>
|
|
53
|
+
<bs-breadcrumb href="/settings/profile">Profile</bs-breadcrumb>
|
|
54
|
+
<bs-breadcrumb current>Edit</bs-breadcrumb>
|
|
55
|
+
</bs-breadcrumbs>
|
|
56
|
+
`,
|
|
57
|
+
};
|
|
58
|
+
// A crumb with neither `current` nor `href` -- not the current page, but also not navigable (e.g.
|
|
59
|
+
// an archived section heading). Renders as plain, non-interactive text with the same muted styling
|
|
60
|
+
// as a link.
|
|
61
|
+
export const NonLinkCrumb = {
|
|
62
|
+
args: {
|
|
63
|
+
size: 'md',
|
|
64
|
+
},
|
|
65
|
+
name: 'Non-link crumb',
|
|
66
|
+
render: args => html `
|
|
67
|
+
<bs-breadcrumbs label=${args.label}>
|
|
68
|
+
<bs-breadcrumb href="/">Home</bs-breadcrumb>
|
|
69
|
+
<bs-breadcrumb>Archived section</bs-breadcrumb>
|
|
70
|
+
<bs-breadcrumb current>Report</bs-breadcrumb>
|
|
71
|
+
</bs-breadcrumbs>
|
|
72
|
+
`,
|
|
73
|
+
};
|
|
74
|
+
// Sanity-checks the :host(:first-child) separator-hiding rule when a <bs-breadcrumb-overflow> --
|
|
75
|
+
// rather than a <bs-breadcrumb> -- is the visually first element in the trail.
|
|
76
|
+
export const OverflowFirst = {
|
|
77
|
+
name: 'Overflow first',
|
|
78
|
+
render: () => html `
|
|
79
|
+
<bs-breadcrumbs label="Breadcrumb">
|
|
80
|
+
<bs-breadcrumb-overflow .items=${overflowItems}></bs-breadcrumb-overflow>
|
|
81
|
+
<bs-breadcrumb current>Edit</bs-breadcrumb>
|
|
82
|
+
</bs-breadcrumbs>
|
|
83
|
+
`,
|
|
84
|
+
};
|
|
@@ -78,4 +78,30 @@ describe('bs-button', () => {
|
|
|
78
78
|
const button = root.shadowRoot.querySelector('button');
|
|
79
79
|
expect(button).toHaveClass('bs-button--icon-only');
|
|
80
80
|
});
|
|
81
|
+
describe('asymmetric padding for icon + label layouts', () => {
|
|
82
|
+
it('applies bs-button--has-icon (not bs-button--has-end-icon) with a leading icon and a label', async () => {
|
|
83
|
+
const { root } = await render(h("bs-button", null, h("svg", { slot: "icon", viewBox: "0 0 16 16" }), "Click me"));
|
|
84
|
+
const button = root.shadowRoot.querySelector('button');
|
|
85
|
+
expect(button).toHaveClass('bs-button--has-icon');
|
|
86
|
+
expect(button).not.toHaveClass('bs-button--has-end-icon');
|
|
87
|
+
});
|
|
88
|
+
it('applies bs-button--has-end-icon (not bs-button--has-icon) with a trailing icon and a label', async () => {
|
|
89
|
+
const { root } = await render(h("bs-button", null, "Next", h("svg", { slot: "end-icon", viewBox: "0 0 16 16" })));
|
|
90
|
+
const button = root.shadowRoot.querySelector('button');
|
|
91
|
+
expect(button).toHaveClass('bs-button--has-end-icon');
|
|
92
|
+
expect(button).not.toHaveClass('bs-button--has-icon');
|
|
93
|
+
});
|
|
94
|
+
it('applies neither class for an icon-only button (padding stays 0 via bs-button--icon-only)', async () => {
|
|
95
|
+
const { root } = await render(h("bs-button", { ariaLabel: "Delete" }, h("svg", { slot: "icon", viewBox: "0 0 16 16" })));
|
|
96
|
+
const button = root.shadowRoot.querySelector('button');
|
|
97
|
+
expect(button).not.toHaveClass('bs-button--has-icon');
|
|
98
|
+
expect(button).not.toHaveClass('bs-button--has-end-icon');
|
|
99
|
+
});
|
|
100
|
+
it('applies neither class for a plain text-only button', async () => {
|
|
101
|
+
const { root } = await render(h("bs-button", null, "Click me"));
|
|
102
|
+
const button = root.shadowRoot.querySelector('button');
|
|
103
|
+
expect(button).not.toHaveClass('bs-button--has-icon');
|
|
104
|
+
expect(button).not.toHaveClass('bs-button--has-end-icon');
|
|
105
|
+
});
|
|
106
|
+
});
|
|
81
107
|
});
|
|
@@ -4,7 +4,9 @@
|
|
|
4
4
|
--bs-button-height-md: var(--bs-spacing-600);
|
|
5
5
|
--bs-button-height-lg: var(--bs-spacing-700);
|
|
6
6
|
--bs-button-radius: var(--bs-border-radius-100);
|
|
7
|
-
|
|
7
|
+
--bs-button-padding-x-icon-side: var(--bs-spacing-150);
|
|
8
|
+
--bs-button-padding-x-label-side: var(--bs-spacing-250);
|
|
9
|
+
|
|
8
10
|
--bs-button-error-default: var(--bs-color-error-default);
|
|
9
11
|
--bs-button-error-hover: var(--bs-color-error-hover);
|
|
10
12
|
--bs-button-error-focus: var(--bs-border-error-focus);
|
|
@@ -30,6 +32,20 @@
|
|
|
30
32
|
--bs-button-subtle-hover: var(--bs-color-neutral-container);
|
|
31
33
|
--bs-button-subtle-pressed: var(--bs-color-neutral-container-pressed);
|
|
32
34
|
--bs-button-subtle-focus: var(--bs-border-primary-focus);
|
|
35
|
+
/* Verified against Figma node 2842:50178 ("Style=Neutral, States=Enabled"): the neutral variant
|
|
36
|
+
has its own 1px border, unlike every other filled variant here -- previously missing entirely. */
|
|
37
|
+
--bs-button-neutral-border: var(--bs-border-neutral-container);
|
|
38
|
+
--bs-button-neutral-border-hover: var(--bs-border-neutral-container-hover);
|
|
39
|
+
--bs-button-neutral-border-pressed: var(--bs-border-neutral-container-pressed);
|
|
40
|
+
/* Locally overriding the vendored --bs-button-neutral-hover/-pressed tokens (used directly
|
|
41
|
+
below elsewhere in this codebase) -- they alias to --bs-color-neutral-hover (a dark,
|
|
42
|
+
near-black scale meant for on-neutral text/icons, not a container background) and
|
|
43
|
+
--bs-color-primary-pressed (BLUE, not neutral at all) respectively. Verified visually: with
|
|
44
|
+
the vendored values, hover rendered near-black and pressed rendered blue, neither matching the
|
|
45
|
+
light-lavender-family redline. --bs-color-neutral-container-hover/-pressed are the correct
|
|
46
|
+
step family, matching --bs-button-neutral-container (--bs-color-neutral-container) itself. */
|
|
47
|
+
--bs-button-neutral-hover: var(--bs-color-neutral-container-hover);
|
|
48
|
+
--bs-button-neutral-pressed: var(--bs-color-neutral-container-pressed);
|
|
33
49
|
--bs-button-outlined-border: var(--bs-border-primary);
|
|
34
50
|
--bs-button-outlined-border-hover: var(--bs-border-primary-hover);
|
|
35
51
|
--bs-button-outlined-focus: var(--bs-border-primary-focus);
|
|
@@ -44,7 +60,9 @@
|
|
|
44
60
|
border: none;
|
|
45
61
|
border-radius: var(--bs-button-radius);
|
|
46
62
|
font-family: inherit;
|
|
47
|
-
|
|
63
|
+
/* Was semibold, then medium -- both wrong per direct comparison against the live Figma file.
|
|
64
|
+
Every variant's label actually uses the regular weight. */
|
|
65
|
+
font-weight: var(--bs-font-weight-regular);
|
|
48
66
|
cursor: pointer;
|
|
49
67
|
transition: background-color var(--bs-duration-fast, 120ms) var(--bs-easing-standard, ease);
|
|
50
68
|
}
|
|
@@ -66,7 +84,11 @@
|
|
|
66
84
|
|
|
67
85
|
.bs-button--md {
|
|
68
86
|
height: var(--bs-button-height-md);
|
|
69
|
-
|
|
87
|
+
/* Verified against Figma node 2842:50344 (71px-wide frame, 39px-wide "Label" text): horizontal
|
|
88
|
+
padding is spacing/200 (16px) each side, not spacing-400 (32px) -- the previous value was
|
|
89
|
+
roughly double what the redline specifies. sm/lg padding-x weren't independently re-verified
|
|
90
|
+
against their own redlines in this pass. */
|
|
91
|
+
padding: 0 var(--bs-spacing-200);
|
|
70
92
|
font-size: var(--bs-font-size-md);
|
|
71
93
|
}
|
|
72
94
|
|
|
@@ -94,16 +116,20 @@
|
|
|
94
116
|
.bs-button--neutral {
|
|
95
117
|
background: var(--bs-button-neutral-container);
|
|
96
118
|
color: var(--bs-text-default);
|
|
119
|
+
border: 1px solid var(--bs-button-neutral-border);
|
|
97
120
|
}
|
|
98
121
|
.bs-button--neutral:hover:not(:disabled) {
|
|
99
122
|
background: var(--bs-button-neutral-hover);
|
|
123
|
+
border-color: var(--bs-button-neutral-border-hover);
|
|
100
124
|
}
|
|
101
125
|
.bs-button--neutral:active:not(:disabled) {
|
|
102
126
|
background: var(--bs-button-neutral-pressed);
|
|
127
|
+
border-color: var(--bs-button-neutral-border-pressed);
|
|
103
128
|
}
|
|
104
129
|
.bs-button--neutral:disabled {
|
|
105
130
|
background: var(--bs-button-neutral-disabled);
|
|
106
131
|
color: var(--bs-text-on-disabled);
|
|
132
|
+
border-color: var(--bs-button-neutral-border);
|
|
107
133
|
}
|
|
108
134
|
|
|
109
135
|
.bs-button--error {
|
|
@@ -145,7 +171,11 @@
|
|
|
145
171
|
|
|
146
172
|
.bs-button--warning {
|
|
147
173
|
background: var(--bs-button-warning-default);
|
|
148
|
-
|
|
174
|
+
/* --bs-text-default (not --bs-text-on-action, unlike every other colored variant here) failed
|
|
175
|
+
WCAG AA contrast against this background in BOTH themes -- verified: light theme was black
|
|
176
|
+
text on rgb(128,93,0) at 3.49:1 (needs 4.5:1), dark theme was white text on rgb(177,129,0) at
|
|
177
|
+
3.51:1. --bs-text-on-action flips appropriately per theme and passes in both (6.02:1 / 5.99:1). */
|
|
178
|
+
color: var(--bs-text-on-action);
|
|
149
179
|
}
|
|
150
180
|
.bs-button--warning:hover:not(:disabled) {
|
|
151
181
|
background: var(--bs-button-warning-hover);
|
|
@@ -220,12 +250,14 @@
|
|
|
220
250
|
outline-color: var(--bs-button-outlined-focus);
|
|
221
251
|
}
|
|
222
252
|
|
|
253
|
+
/* Gap between icon and label: spacing/xs (4px) per Figma node 2842:50344's state-layer gap, not
|
|
254
|
+
spacing-100 (8px). */
|
|
223
255
|
.bs-button__icon--visible {
|
|
224
|
-
margin-right: var(--bs-spacing-
|
|
256
|
+
margin-right: var(--bs-spacing-50);
|
|
225
257
|
}
|
|
226
258
|
|
|
227
259
|
.bs-button__end-icon--visible {
|
|
228
|
-
margin-left: var(--bs-spacing-
|
|
260
|
+
margin-left: var(--bs-spacing-50);
|
|
229
261
|
}
|
|
230
262
|
|
|
231
263
|
.bs-button__icon ::slotted(*),
|
|
@@ -245,3 +277,22 @@
|
|
|
245
277
|
.bs-button--icon-only .bs-button__end-icon--visible {
|
|
246
278
|
margin-left: 0;
|
|
247
279
|
}
|
|
280
|
+
|
|
281
|
+
/* Verified against a Figma redline for the icon+label layout: the edge next to an icon is
|
|
282
|
+
tighter (spacing/150, 12px) than the plain text-only edge (16px), and the opposite edge -- next
|
|
283
|
+
to just the label, with an icon on the other side pulling the button off-balance -- compensates
|
|
284
|
+
with more padding (spacing/250, 20px), keeping the total horizontal padding budget the same as
|
|
285
|
+
the icon-less button (12+20 = 16+16 = 32px for size="md"). This is deliberately NOT
|
|
286
|
+
size-dependent, same as the icon/label gap above -- neither varies by size in the source spec. */
|
|
287
|
+
.bs-button--has-icon:not(.bs-button--has-end-icon) {
|
|
288
|
+
padding-left: var(--bs-button-padding-x-icon-side);
|
|
289
|
+
padding-right: var(--bs-button-padding-x-label-side);
|
|
290
|
+
}
|
|
291
|
+
.bs-button--has-end-icon:not(.bs-button--has-icon) {
|
|
292
|
+
padding-left: var(--bs-button-padding-x-label-side);
|
|
293
|
+
padding-right: var(--bs-button-padding-x-icon-side);
|
|
294
|
+
}
|
|
295
|
+
.bs-button--has-icon.bs-button--has-end-icon {
|
|
296
|
+
padding-left: var(--bs-button-padding-x-icon-side);
|
|
297
|
+
padding-right: var(--bs-button-padding-x-icon-side);
|
|
298
|
+
}
|
|
@@ -27,6 +27,11 @@ import { h } from "@stencil/core";
|
|
|
27
27
|
* @prop --bs-button-height-sm - Height at `size="sm"`. Aliased to `--bs-spacing-500`.
|
|
28
28
|
* @prop --bs-button-height-md - Height at `size="md"`. Aliased to `--bs-spacing-600`.
|
|
29
29
|
* @prop --bs-button-height-lg - Height at `size="lg"`. Aliased to `--bs-spacing-700`.
|
|
30
|
+
* @prop --bs-button-neutral-border - Border color, `variant="neutral"`, default/disabled. Aliased to `--bs-border-neutral-container`.
|
|
31
|
+
* @prop --bs-button-neutral-border-hover - Border color, `variant="neutral"`, hover. Aliased to `--bs-border-neutral-container-hover`.
|
|
32
|
+
* @prop --bs-button-neutral-border-pressed - Border color, `variant="neutral"`, pressed. Aliased to `--bs-border-neutral-container-pressed`.
|
|
33
|
+
* @prop --bs-button-padding-x-icon-side - Horizontal padding on an edge that's adjacent to a leading/trailing icon (tighter than the plain text-only edge). Aliased to `--bs-spacing-150`.
|
|
34
|
+
* @prop --bs-button-padding-x-label-side - Horizontal padding on the opposite edge, when an icon on the other side needs compensating extra space to keep the button optically balanced. Aliased to `--bs-spacing-250`.
|
|
30
35
|
*/
|
|
31
36
|
export class BsButton {
|
|
32
37
|
el;
|
|
@@ -100,7 +105,7 @@ export class BsButton {
|
|
|
100
105
|
};
|
|
101
106
|
render() {
|
|
102
107
|
const iconOnly = (this.hasIcon || this.hasEndIcon) && !this.hasLabel;
|
|
103
|
-
return (h("button", { key: '
|
|
108
|
+
return (h("button", { key: '3820c965cff86109613dac0d6ffaf5ee0a926f26', class: `bs-button bs-button--${this.variant} bs-button--${this.size} ${iconOnly ? 'bs-button--icon-only' : ''} ${this.hasIcon && !iconOnly ? 'bs-button--has-icon' : ''} ${this.hasEndIcon && !iconOnly ? 'bs-button--has-end-icon' : ''}`, type: this.type, disabled: this.disabled, "aria-label": this.ariaLabel }, h("span", { key: 'b8fb25e26d96168d6676acc0c3fa1b4f3429e974', part: "icon", class: `bs-button__icon ${this.hasIcon ? 'bs-button__icon--visible' : ''}` }, h("slot", { key: 'cd5e33cf19f19b89c2f87153d20d32bf0d3dabb9', name: "icon", onSlotchange: this.onIconSlotchange })), h("span", { key: '91c9fd334013c495d2ec836619b9aecebc3c8e20', part: "label", class: "bs-button__label" }, h("slot", { key: 'c363d5d5004d2b2e9e5a4e09fa6cbe2ab87d9fff', onSlotchange: this.onLabelSlotchange })), h("span", { key: '29c1b4457efcfb9c11b0095279b77f3e97fa9988', part: "end-icon", class: `bs-button__end-icon ${this.hasEndIcon ? 'bs-button__end-icon--visible' : ''}` }, h("slot", { key: '9a6d3c0fcc16d8b546e225d88ae4d6014e9b2e45', name: "end-icon", onSlotchange: this.onEndIconSlotchange }))));
|
|
104
109
|
}
|
|
105
110
|
static get is() { return "bs-button"; }
|
|
106
111
|
static get encapsulation() { return "shadow"; }
|
|
@@ -126,8 +131,8 @@ export class BsButton {
|
|
|
126
131
|
"references": {
|
|
127
132
|
"BsButtonVariant": {
|
|
128
133
|
"location": "local",
|
|
129
|
-
"path": "/Users/vivka/brandsync-web-components/src/components/bs-button/bs-button.tsx",
|
|
130
|
-
"id": "src/components/bs-button/bs-button.tsx::BsButtonVariant"
|
|
134
|
+
"path": "/Users/vivka/brandsync-web-components/src/components/bs-button/bs-button/bs-button.tsx",
|
|
135
|
+
"id": "src/components/bs-button/bs-button/bs-button.tsx::BsButtonVariant"
|
|
131
136
|
}
|
|
132
137
|
}
|
|
133
138
|
},
|
|
@@ -152,8 +157,8 @@ export class BsButton {
|
|
|
152
157
|
"references": {
|
|
153
158
|
"BsButtonSize": {
|
|
154
159
|
"location": "local",
|
|
155
|
-
"path": "/Users/vivka/brandsync-web-components/src/components/bs-button/bs-button.tsx",
|
|
156
|
-
"id": "src/components/bs-button/bs-button.tsx::BsButtonSize"
|
|
160
|
+
"path": "/Users/vivka/brandsync-web-components/src/components/bs-button/bs-button/bs-button.tsx",
|
|
161
|
+
"id": "src/components/bs-button/bs-button/bs-button.tsx::BsButtonSize"
|
|
157
162
|
}
|
|
158
163
|
}
|
|
159
164
|
},
|
package/dist/collection/components/bs-button/{bs-button.stories.js → bs-button/bs-button.stories.js}
RENAMED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { html } from "lit";
|
|
2
|
-
import { componentDescription, propDescription } from "
|
|
2
|
+
import { componentDescription, propDescription } from "../../../stories-utils";
|
|
3
3
|
const variants = ['primary', 'neutral', 'subtle', 'outlined', 'success', 'warning', 'info', 'error'];
|
|
4
4
|
const sizes = ['sm', 'md', 'lg'];
|
|
5
5
|
const meta = {
|
|
6
|
-
title: 'Components/bs-button',
|
|
6
|
+
title: 'Components/bs-button/bs-button',
|
|
7
7
|
parameters: { docs: { description: { component: componentDescription('bs-button') } } },
|
|
8
8
|
render: args => html `
|
|
9
9
|
<bs-button variant=${args.variant} size=${args.size} type=${args.type} ?disabled=${args.disabled}>
|
|
@@ -86,31 +86,6 @@ export const WithEndIcon = {
|
|
|
86
86
|
</bs-button>
|
|
87
87
|
`,
|
|
88
88
|
};
|
|
89
|
-
export const IconOnly = {
|
|
90
|
-
name: 'Icon-only',
|
|
91
|
-
render: args => html `
|
|
92
|
-
<bs-button variant=${args.variant} size=${args.size} ?disabled=${args.disabled} aria-label="Delete">
|
|
93
|
-
<svg slot="icon" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg" aria-hidden="true">
|
|
94
|
-
<path
|
|
95
|
-
d="M2 4H14M6 4V2.5C6 2.22386 6.22386 2 6.5 2H9.5C9.77614 2 10 2.22386 10 2.5V4M12.5 4L12 13.5C12 13.7761 11.7761 14 11.5 14H4.5C4.22386 14 4 13.7761 4 13.5L3.5 4"
|
|
96
|
-
stroke="currentColor"
|
|
97
|
-
stroke-width="1.3"
|
|
98
|
-
stroke-linecap="round"
|
|
99
|
-
stroke-linejoin="round"
|
|
100
|
-
/>
|
|
101
|
-
</svg>
|
|
102
|
-
</bs-button>
|
|
103
|
-
`,
|
|
104
|
-
};
|
|
105
|
-
export const LongLabel = {
|
|
106
|
-
name: 'Long label (edge case)',
|
|
107
|
-
args: { label: 'This button has a much longer label than the icon-and-text layout was designed for' },
|
|
108
|
-
render: args => html `
|
|
109
|
-
<div style="max-width: 220px;">
|
|
110
|
-
<bs-button variant=${args.variant} size=${args.size} ?disabled=${args.disabled}> ${args.label} </bs-button>
|
|
111
|
-
</div>
|
|
112
|
-
`,
|
|
113
|
-
};
|
|
114
89
|
export const AllCombinations = {
|
|
115
90
|
name: 'All variant × size × disabled combinations',
|
|
116
91
|
render: () => html `
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { render, h, describe, it, expect } from "@stencil/vitest";
|
|
2
|
+
describe('bs-icon-button', () => {
|
|
3
|
+
it('renders the default icon slot and variant/size classes', async () => {
|
|
4
|
+
const { root } = await render(h("bs-icon-button", { ariaLabel: "Confirm" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
5
|
+
const button = root.shadowRoot.querySelector('button');
|
|
6
|
+
expect(button).toHaveClass('bs-icon-button--primary');
|
|
7
|
+
expect(button).toHaveClass('bs-icon-button--md');
|
|
8
|
+
});
|
|
9
|
+
it('applies the disabled attribute to the native button', async () => {
|
|
10
|
+
const { root } = await render(h("bs-icon-button", { ariaLabel: "Confirm", disabled: true }, h("svg", { viewBox: "0 0 16 16" })));
|
|
11
|
+
const button = root.shadowRoot.querySelector('button');
|
|
12
|
+
expect(button).toHaveAttribute('disabled');
|
|
13
|
+
});
|
|
14
|
+
it('reflects the variant prop to the internal class', async () => {
|
|
15
|
+
const { root, setProps } = await render(h("bs-icon-button", { ariaLabel: "Confirm", variant: "neutral" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
16
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--neutral');
|
|
17
|
+
await setProps({ variant: 'primary' });
|
|
18
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--primary');
|
|
19
|
+
});
|
|
20
|
+
it('applies the error variant class and reflects on prop change', async () => {
|
|
21
|
+
const { root, setProps } = await render(h("bs-icon-button", { ariaLabel: "Delete", variant: "error" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
22
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--error');
|
|
23
|
+
await setProps({ variant: 'primary' });
|
|
24
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--primary');
|
|
25
|
+
expect(root.shadowRoot.querySelector('button')).not.toHaveClass('bs-icon-button--error');
|
|
26
|
+
});
|
|
27
|
+
it('applies the subtle variant class', async () => {
|
|
28
|
+
const { root } = await render(h("bs-icon-button", { ariaLabel: "Confirm", variant: "subtle" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
29
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--subtle');
|
|
30
|
+
});
|
|
31
|
+
it('applies the outlined variant class', async () => {
|
|
32
|
+
const { root } = await render(h("bs-icon-button", { ariaLabel: "Confirm", variant: "outlined" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
33
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--outlined');
|
|
34
|
+
});
|
|
35
|
+
it('applies the success variant class and reflects on prop change', async () => {
|
|
36
|
+
const { root, setProps } = await render(h("bs-icon-button", { ariaLabel: "Approve", variant: "success" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
37
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--success');
|
|
38
|
+
await setProps({ variant: 'primary' });
|
|
39
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--primary');
|
|
40
|
+
expect(root.shadowRoot.querySelector('button')).not.toHaveClass('bs-icon-button--success');
|
|
41
|
+
});
|
|
42
|
+
it('applies the warning variant class', async () => {
|
|
43
|
+
const { root } = await render(h("bs-icon-button", { ariaLabel: "Proceed anyway", variant: "warning" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
44
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--warning');
|
|
45
|
+
});
|
|
46
|
+
it('applies the info variant class', async () => {
|
|
47
|
+
const { root } = await render(h("bs-icon-button", { ariaLabel: "View details", variant: "info" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
48
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--info');
|
|
49
|
+
});
|
|
50
|
+
it('applies each size class', async () => {
|
|
51
|
+
const { root, setProps } = await render(h("bs-icon-button", { ariaLabel: "Confirm", size: "sm" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
52
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--sm');
|
|
53
|
+
await setProps({ size: 'lg' });
|
|
54
|
+
expect(root.shadowRoot.querySelector('button')).toHaveClass('bs-icon-button--lg');
|
|
55
|
+
});
|
|
56
|
+
it('renders size="xs" at 16px with an 8px icon and a smaller radius than sm/md/lg', async () => {
|
|
57
|
+
const { root } = await render(h("bs-icon-button", { ariaLabel: "Remove", size: "xs" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
58
|
+
const button = root.shadowRoot.querySelector('button');
|
|
59
|
+
expect(button).toHaveClass('bs-icon-button--xs');
|
|
60
|
+
expect(getComputedStyle(button).width).toBe('16px');
|
|
61
|
+
expect(getComputedStyle(button).height).toBe('16px');
|
|
62
|
+
const icon = root.shadowRoot.querySelector('[part="icon"]');
|
|
63
|
+
expect(getComputedStyle(icon).width).toBe('8px');
|
|
64
|
+
expect(getComputedStyle(icon).height).toBe('8px');
|
|
65
|
+
});
|
|
66
|
+
it('sets aria-label on the inner button from the ariaLabel prop', async () => {
|
|
67
|
+
const { root } = await render(h("bs-icon-button", { ariaLabel: "Delete" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
68
|
+
const button = root.shadowRoot.querySelector('button');
|
|
69
|
+
expect(button).toEqualAttribute('aria-label', 'Delete');
|
|
70
|
+
});
|
|
71
|
+
it('renders the native button type from the type prop', async () => {
|
|
72
|
+
const { root } = await render(h("bs-icon-button", { ariaLabel: "Submit", type: "submit" }, h("svg", { viewBox: "0 0 16 16" })));
|
|
73
|
+
const button = root.shadowRoot.querySelector('button');
|
|
74
|
+
expect(button).toEqualAttribute('type', 'submit');
|
|
75
|
+
});
|
|
76
|
+
it('renders the slotted icon content inside part="icon"', async () => {
|
|
77
|
+
const { root } = await render(h("bs-icon-button", { ariaLabel: "Confirm" }, h("svg", { class: "my-icon", viewBox: "0 0 16 16" })));
|
|
78
|
+
const iconWrapper = root.shadowRoot.querySelector('[part="icon"]');
|
|
79
|
+
expect(iconWrapper).not.toBeNull();
|
|
80
|
+
expect(iconWrapper.querySelector('slot')).not.toBeNull();
|
|
81
|
+
expect(root.querySelector('svg.my-icon')).not.toBeNull();
|
|
82
|
+
});
|
|
83
|
+
});
|