@vonage/vivid 3.0.0-next.6 → 3.0.0-next.7
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/.babelrc +3 -0
- package/.eslintrc.json +70 -0
- package/.stylelintrc.json +8 -0
- package/CHANGELOG.json +343 -0
- package/CHANGELOG.md +45 -0
- package/jest.config.cjs +20 -0
- package/package.json +4 -13
- package/playwright.config.dev.ts +21 -0
- package/playwright.config.ts +34 -0
- package/project.json +122 -0
- package/rollup.config.prod.ts +50 -0
- package/setupJestTests.js +17 -0
- package/{index.d.ts → src/index.ts} +2 -2
- package/src/lib/accordion/README.md +55 -0
- package/src/lib/accordion/accordion.scss +10 -0
- package/src/lib/accordion/accordion.spec.ts +91 -0
- package/src/lib/accordion/accordion.template.ts +23 -0
- package/src/lib/accordion/accordion.ts +49 -0
- package/src/lib/accordion/index.ts +14 -0
- package/src/lib/accordion/ui.test.ts +37 -0
- package/src/lib/accordion/ui.test.ts-snapshots/snapshots-accordion-Chrome-Stable-darwin.png +0 -0
- package/src/lib/accordion/ui.test.ts-snapshots/snapshots-accordion-Chrome-Stable-linux.png +0 -0
- package/src/lib/accordion/ui.test.ts-snapshots/snapshots-accordion-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/accordion/ui.test.ts-snapshots/snapshots-accordion-Desktop-Firefox-linux.png +0 -0
- package/src/lib/accordion/ui.test.ts-snapshots/snapshots-accordion-Desktop-Safari-darwin.png +0 -0
- package/src/lib/accordion/ui.test.ts-snapshots/snapshots-accordion-Desktop-Safari-linux.png +0 -0
- package/src/lib/accordion-item/README.md +113 -0
- package/src/lib/accordion-item/accordion-item.scss +91 -0
- package/src/lib/accordion-item/accordion-item.spec.ts +103 -0
- package/src/lib/accordion-item/accordion-item.template.ts +62 -0
- package/src/lib/accordion-item/accordion-item.ts +67 -0
- package/src/lib/accordion-item/index.ts +14 -0
- package/src/lib/accordion-item/partials/variables.scss +1 -0
- package/src/lib/accordion-item/ui.test.ts +37 -0
- package/src/lib/accordion-item/ui.test.ts-snapshots/snapshots-accordion-item-Chrome-Stable-darwin.png +0 -0
- package/src/lib/accordion-item/ui.test.ts-snapshots/snapshots-accordion-item-Chrome-Stable-linux.png +0 -0
- package/src/lib/accordion-item/ui.test.ts-snapshots/snapshots-accordion-item-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/accordion-item/ui.test.ts-snapshots/snapshots-accordion-item-Desktop-Firefox-linux.png +0 -0
- package/src/lib/accordion-item/ui.test.ts-snapshots/snapshots-accordion-item-Desktop-Safari-darwin.png +0 -0
- package/src/lib/accordion-item/ui.test.ts-snapshots/snapshots-accordion-item-Desktop-Safari-linux.png +0 -0
- package/src/lib/badge/README.md +112 -0
- package/src/lib/badge/badge.scss +64 -0
- package/src/lib/badge/badge.spec.ts +114 -0
- package/src/lib/badge/badge.template.ts +36 -0
- package/src/lib/badge/badge.ts +97 -0
- package/src/lib/badge/index.ts +23 -0
- package/src/lib/badge/ui.test.ts +28 -0
- package/src/lib/badge/ui.test.ts-snapshots/snapshots-badge-Chrome-Stable-darwin.png +0 -0
- package/src/lib/badge/ui.test.ts-snapshots/snapshots-badge-Chrome-Stable-linux.png +0 -0
- package/src/lib/badge/ui.test.ts-snapshots/snapshots-badge-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/badge/ui.test.ts-snapshots/snapshots-badge-Desktop-Firefox-linux.png +0 -0
- package/src/lib/badge/ui.test.ts-snapshots/snapshots-badge-Desktop-Safari-darwin.png +0 -0
- package/src/lib/badge/ui.test.ts-snapshots/snapshots-badge-Desktop-Safari-linux.png +0 -0
- package/src/lib/banner/README.md +117 -0
- package/src/lib/banner/banner.scss +71 -0
- package/src/lib/banner/banner.spec.ts +355 -0
- package/src/lib/banner/banner.template.ts +61 -0
- package/src/lib/banner/banner.ts +77 -0
- package/src/lib/banner/index.ts +14 -0
- package/src/lib/banner/ui.test.ts +64 -0
- package/src/lib/banner/ui.test.ts-snapshots/snapshots-banner-Chrome-Stable-darwin.png +0 -0
- package/src/lib/banner/ui.test.ts-snapshots/snapshots-banner-Chrome-Stable-linux.png +0 -0
- package/src/lib/banner/ui.test.ts-snapshots/snapshots-banner-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/banner/ui.test.ts-snapshots/snapshots-banner-Desktop-Firefox-linux.png +0 -0
- package/src/lib/banner/ui.test.ts-snapshots/snapshots-banner-Desktop-Safari-darwin.png +0 -0
- package/src/lib/banner/ui.test.ts-snapshots/snapshots-banner-Desktop-Safari-linux.png +0 -0
- package/src/lib/breadcrumb/README.md +25 -0
- package/src/lib/breadcrumb/breadcrumb.scss +3 -0
- package/src/lib/breadcrumb/breadcrumb.spec.ts +78 -0
- package/src/lib/breadcrumb/breadcrumb.ts +10 -0
- package/src/lib/breadcrumb/index.ts +13 -0
- package/src/lib/breadcrumb/ui.test.ts +36 -0
- package/src/lib/breadcrumb/ui.test.ts-snapshots/snapshots-breadcrumb-Chrome-Stable-darwin.png +0 -0
- package/src/lib/breadcrumb/ui.test.ts-snapshots/snapshots-breadcrumb-Chrome-Stable-linux.png +0 -0
- package/src/lib/breadcrumb/ui.test.ts-snapshots/snapshots-breadcrumb-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/breadcrumb/ui.test.ts-snapshots/snapshots-breadcrumb-Desktop-Firefox-linux.png +0 -0
- package/src/lib/breadcrumb/ui.test.ts-snapshots/snapshots-breadcrumb-Desktop-Safari-darwin.png +0 -0
- package/src/lib/breadcrumb/ui.test.ts-snapshots/snapshots-breadcrumb-Desktop-Safari-linux.png +0 -0
- package/src/lib/breadcrumb-item/README.md +40 -0
- package/src/lib/breadcrumb-item/breadcrumb-item.scss +28 -0
- package/src/lib/breadcrumb-item/breadcrumb-item.spec.ts +192 -0
- package/src/lib/breadcrumb-item/breadcrumb-item.template.ts +37 -0
- package/src/lib/breadcrumb-item/breadcrumb-item.ts +15 -0
- package/src/lib/breadcrumb-item/index.ts +16 -0
- package/src/lib/breadcrumb-item/ui.test.ts +38 -0
- package/src/lib/breadcrumb-item/ui.test.ts-snapshots/snapshots-breadcrumb-item-Chrome-Stable-darwin.png +0 -0
- package/src/lib/breadcrumb-item/ui.test.ts-snapshots/snapshots-breadcrumb-item-Chrome-Stable-linux.png +0 -0
- package/src/lib/breadcrumb-item/ui.test.ts-snapshots/snapshots-breadcrumb-item-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/breadcrumb-item/ui.test.ts-snapshots/snapshots-breadcrumb-item-Desktop-Firefox-linux.png +0 -0
- package/src/lib/breadcrumb-item/ui.test.ts-snapshots/snapshots-breadcrumb-item-Desktop-Safari-darwin.png +0 -0
- package/src/lib/breadcrumb-item/ui.test.ts-snapshots/snapshots-breadcrumb-item-Desktop-Safari-linux.png +0 -0
- package/src/lib/button/README.md +120 -0
- package/src/lib/button/button.scss +142 -0
- package/src/lib/button/button.spec.ts +131 -0
- package/src/lib/button/button.template.ts +89 -0
- package/src/lib/button/button.ts +95 -0
- package/src/lib/button/index.ts +25 -0
- package/src/lib/button/partials/variables.scss +2 -0
- package/src/lib/button/ui.test.ts +32 -0
- package/src/lib/button/ui.test.ts-snapshots/snapshots-button-Chrome-Stable-darwin.png +0 -0
- package/src/lib/button/ui.test.ts-snapshots/snapshots-button-Chrome-Stable-linux.png +0 -0
- package/src/lib/button/ui.test.ts-snapshots/snapshots-button-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/button/ui.test.ts-snapshots/snapshots-button-Desktop-Firefox-linux.png +0 -0
- package/src/lib/button/ui.test.ts-snapshots/snapshots-button-Desktop-Safari-darwin.png +0 -0
- package/src/lib/button/ui.test.ts-snapshots/snapshots-button-Desktop-Safari-linux.png +0 -0
- package/src/lib/calendar/README.md +70 -0
- package/src/lib/calendar/calendar.scss +176 -0
- package/src/lib/calendar/calendar.spec.ts +341 -0
- package/src/lib/calendar/calendar.template.ts +93 -0
- package/src/lib/calendar/calendar.ts +139 -0
- package/src/lib/calendar/helpers/calendar.date-functions.ts +31 -0
- package/src/lib/calendar/helpers/calendar.event-context.ts +72 -0
- package/src/lib/calendar/helpers/calendar.keyboard-interactions.ts +65 -0
- package/src/lib/calendar/index.ts +16 -0
- package/src/lib/calendar/partials/_variables.scss +15 -0
- package/src/lib/calendar/ui.test.ts +32 -0
- package/src/lib/calendar/ui.test.ts-snapshots/snapshots-calendar-Chrome-Stable-darwin.png +0 -0
- package/src/lib/calendar/ui.test.ts-snapshots/snapshots-calendar-Chrome-Stable-linux.png +0 -0
- package/src/lib/calendar/ui.test.ts-snapshots/snapshots-calendar-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/calendar/ui.test.ts-snapshots/snapshots-calendar-Desktop-Firefox-linux.png +0 -0
- package/src/lib/calendar/ui.test.ts-snapshots/snapshots-calendar-Desktop-Safari-darwin.png +0 -0
- package/src/lib/calendar/ui.test.ts-snapshots/snapshots-calendar-Desktop-Safari-linux.png +0 -0
- package/src/lib/components.spec.ts +7 -0
- package/{lib/components.d.ts → src/lib/components.ts} +16 -16
- package/src/lib/elevation/README.md +99 -0
- package/src/lib/elevation/elevation.scss +15 -0
- package/src/lib/elevation/elevation.spec.ts +55 -0
- package/src/lib/elevation/elevation.template.ts +26 -0
- package/src/lib/elevation/elevation.ts +17 -0
- package/src/lib/elevation/index.ts +17 -0
- package/src/lib/elevation/partials/_elevation.mixin.scss +4 -0
- package/src/lib/elevation/ui.test.ts +32 -0
- package/src/lib/elevation/ui.test.ts-snapshots/snapshots-elevation-Chrome-Stable-darwin.png +0 -0
- package/src/lib/elevation/ui.test.ts-snapshots/snapshots-elevation-Chrome-Stable-linux.png +0 -0
- package/src/lib/elevation/ui.test.ts-snapshots/snapshots-elevation-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/elevation/ui.test.ts-snapshots/snapshots-elevation-Desktop-Firefox-linux.png +0 -0
- package/src/lib/elevation/ui.test.ts-snapshots/snapshots-elevation-Desktop-Safari-darwin.png +0 -0
- package/src/lib/elevation/ui.test.ts-snapshots/snapshots-elevation-Desktop-Safari-linux.png +0 -0
- package/src/lib/enums.ts +55 -0
- package/src/lib/focus/README.md +1 -0
- package/src/lib/focus/focus.scss +17 -0
- package/src/lib/focus/focus.template.ts +16 -0
- package/src/lib/focus/focus.ts +10 -0
- package/src/lib/focus/index.ts +21 -0
- package/src/lib/focus/partials/variables.scss +2 -0
- package/src/lib/icon/README.md +70 -0
- package/src/lib/icon/__snapshots__/icon.spec.ts.snap +16 -0
- package/src/lib/icon/icon.placeholder.ts +12 -0
- package/src/lib/icon/icon.scss +52 -0
- package/src/lib/icon/icon.spec.ts +106 -0
- package/src/lib/icon/icon.template.ts +23 -0
- package/src/lib/icon/icon.ts +93 -0
- package/src/lib/icon/index.ts +14 -0
- package/src/lib/layout/README.md +154 -0
- package/src/lib/layout/index.ts +18 -0
- package/src/lib/layout/layout.scss +40 -0
- package/src/lib/layout/layout.spec.ts +73 -0
- package/src/lib/layout/layout.template.ts +29 -0
- package/src/lib/layout/layout.ts +46 -0
- package/src/lib/layout/partials/_functions.scss +15 -0
- package/src/lib/layout/partials/_mixins.scss +5 -0
- package/src/lib/layout/partials/_variables.scss +23 -0
- package/src/lib/layout/ui.test.ts +32 -0
- package/src/lib/layout/ui.test.ts-snapshots/snapshots-layout-Chrome-Stable-darwin.png +0 -0
- package/src/lib/layout/ui.test.ts-snapshots/snapshots-layout-Chrome-Stable-linux.png +0 -0
- package/src/lib/layout/ui.test.ts-snapshots/snapshots-layout-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/layout/ui.test.ts-snapshots/snapshots-layout-Desktop-Firefox-linux.png +0 -0
- package/src/lib/layout/ui.test.ts-snapshots/snapshots-layout-Desktop-Safari-darwin.png +0 -0
- package/src/lib/layout/ui.test.ts-snapshots/snapshots-layout-Desktop-Safari-linux.png +0 -0
- package/src/lib/popup/README.md +261 -0
- package/src/lib/popup/index.ts +21 -0
- package/src/lib/popup/popup.scss +43 -0
- package/src/lib/popup/popup.spec.ts +265 -0
- package/src/lib/popup/popup.template.ts +41 -0
- package/src/lib/popup/popup.ts +158 -0
- package/src/lib/popup/ui.test.ts +111 -0
- package/src/lib/popup/ui.test.ts-snapshots/snapshots-popup-Chrome-Stable-darwin.png +0 -0
- package/src/lib/popup/ui.test.ts-snapshots/snapshots-popup-Chrome-Stable-linux.png +0 -0
- package/src/lib/popup/ui.test.ts-snapshots/snapshots-popup-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/popup/ui.test.ts-snapshots/snapshots-popup-Desktop-Firefox-linux.png +0 -0
- package/src/lib/popup/ui.test.ts-snapshots/snapshots-popup-Desktop-Safari-darwin.png +0 -0
- package/src/lib/popup/ui.test.ts-snapshots/snapshots-popup-Desktop-Safari-linux.png +0 -0
- package/src/lib/progress/README.md +107 -0
- package/src/lib/progress/index.ts +14 -0
- package/src/lib/progress/progress.scss +133 -0
- package/src/lib/progress/progress.spec.ts +173 -0
- package/src/lib/progress/progress.template.ts +62 -0
- package/src/lib/progress/progress.ts +25 -0
- package/src/lib/progress/ui.test.ts +70 -0
- package/src/lib/progress/ui.test.ts-snapshots/snapshots-progress-Chrome-Stable-darwin.png +0 -0
- package/src/lib/progress/ui.test.ts-snapshots/snapshots-progress-Chrome-Stable-linux.png +0 -0
- package/src/lib/progress/ui.test.ts-snapshots/snapshots-progress-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/progress/ui.test.ts-snapshots/snapshots-progress-Desktop-Firefox-linux.png +0 -0
- package/src/lib/progress/ui.test.ts-snapshots/snapshots-progress-Desktop-Safari-darwin.png +0 -0
- package/src/lib/progress/ui.test.ts-snapshots/snapshots-progress-Desktop-Safari-linux.png +0 -0
- package/src/lib/progress-ring/README.md +90 -0
- package/src/lib/progress-ring/index.ts +15 -0
- package/src/lib/progress-ring/progress-ring.scss +75 -0
- package/src/lib/progress-ring/progress-ring.spec.ts +139 -0
- package/src/lib/progress-ring/progress-ring.template.ts +82 -0
- package/src/lib/progress-ring/progress-ring.ts +18 -0
- package/src/lib/progress-ring/ui.test.ts +35 -0
- package/src/lib/progress-ring/ui.test.ts-snapshots/snapshots-progress-ring-Chrome-Stable-darwin.png +0 -0
- package/src/lib/progress-ring/ui.test.ts-snapshots/snapshots-progress-ring-Chrome-Stable-linux.png +0 -0
- package/src/lib/progress-ring/ui.test.ts-snapshots/snapshots-progress-ring-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/progress-ring/ui.test.ts-snapshots/snapshots-progress-ring-Desktop-Firefox-linux.png +0 -0
- package/src/lib/progress-ring/ui.test.ts-snapshots/snapshots-progress-ring-Desktop-Safari-darwin.png +0 -0
- package/src/lib/progress-ring/ui.test.ts-snapshots/snapshots-progress-ring-Desktop-Safari-linux.png +0 -0
- package/src/lib/side-drawer/README.md +304 -0
- package/src/lib/side-drawer/index.ts +16 -0
- package/src/lib/side-drawer/partials/variables.scss +6 -0
- package/src/lib/side-drawer/side-drawer.scss +109 -0
- package/src/lib/side-drawer/side-drawer.spec.ts +118 -0
- package/src/lib/side-drawer/side-drawer.template.ts +51 -0
- package/src/lib/side-drawer/side-drawer.ts +58 -0
- package/src/lib/side-drawer/ui.test.ts +102 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-Chrome-Stable-darwin.png +0 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-Chrome-Stable-linux.png +0 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-Desktop-Firefox-linux.png +0 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-Desktop-Safari-darwin.png +0 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-Desktop-Safari-linux.png +0 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-modal-Chrome-Stable-darwin.png +0 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-modal-Chrome-Stable-linux.png +0 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-modal-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-modal-Desktop-Firefox-linux.png +0 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-modal-Desktop-Safari-darwin.png +0 -0
- package/src/lib/side-drawer/ui.test.ts-snapshots/snapshots-side-drawer-modal-Desktop-Safari-linux.png +0 -0
- package/src/lib/sidenav-item/README.md +41 -0
- package/src/lib/sidenav-item/index.ts +20 -0
- package/src/lib/sidenav-item/sidenav-item.scss +51 -0
- package/src/lib/sidenav-item/sidenav-item.spec.ts +64 -0
- package/src/lib/sidenav-item/sidenav-item.template.ts +25 -0
- package/src/lib/sidenav-item/sidenav-item.ts +15 -0
- package/src/lib/sidenav-item/ui.test.ts +32 -0
- package/src/lib/sidenav-item/ui.test.ts-snapshots/snapshots-sidenav-item-Chrome-Stable-darwin.png +0 -0
- package/src/lib/sidenav-item/ui.test.ts-snapshots/snapshots-sidenav-item-Chrome-Stable-linux.png +0 -0
- package/src/lib/sidenav-item/ui.test.ts-snapshots/snapshots-sidenav-item-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/sidenav-item/ui.test.ts-snapshots/snapshots-sidenav-item-Desktop-Firefox-linux.png +0 -0
- package/src/lib/sidenav-item/ui.test.ts-snapshots/snapshots-sidenav-item-Desktop-Safari-darwin.png +0 -0
- package/src/lib/sidenav-item/ui.test.ts-snapshots/snapshots-sidenav-item-Desktop-Safari-linux.png +0 -0
- package/src/lib/text/README.md +119 -0
- package/src/lib/text/index.ts +14 -0
- package/src/lib/text/text.scss +92 -0
- package/src/lib/text/text.spec.ts +54 -0
- package/src/lib/text/text.template.ts +28 -0
- package/src/lib/text/text.ts +55 -0
- package/src/lib/text/ui.test.ts +39 -0
- package/src/lib/text/ui.test.ts-snapshots/snapshots-text-Chrome-Stable-darwin.png +0 -0
- package/src/lib/text/ui.test.ts-snapshots/snapshots-text-Chrome-Stable-linux.png +0 -0
- package/src/lib/text/ui.test.ts-snapshots/snapshots-text-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/text/ui.test.ts-snapshots/snapshots-text-Desktop-Firefox-linux.png +0 -0
- package/src/lib/text/ui.test.ts-snapshots/snapshots-text-Desktop-Safari-darwin.png +0 -0
- package/src/lib/text/ui.test.ts-snapshots/snapshots-text-Desktop-Safari-linux.png +0 -0
- package/src/lib/text-anchor/README.md +5 -0
- package/src/lib/text-anchor/index.ts +12 -0
- package/src/lib/text-anchor/text-anchor.spec.ts +153 -0
- package/src/lib/text-anchor/text-anchor.template.ts +66 -0
- package/src/lib/text-anchor/text-anchor.ts +22 -0
- package/src/lib/tooltip/README.md +132 -0
- package/src/lib/tooltip/index.ts +16 -0
- package/src/lib/tooltip/partials/variables.scss +1 -0
- package/src/lib/tooltip/tooltip.scss +18 -0
- package/src/lib/tooltip/tooltip.spec.ts +70 -0
- package/src/lib/tooltip/tooltip.template.ts +30 -0
- package/src/lib/tooltip/tooltip.ts +44 -0
- package/src/lib/tooltip/ui.test.ts +53 -0
- package/src/lib/tooltip/ui.test.ts-snapshots/snapshots-tooltip-Chrome-Stable-darwin.png +0 -0
- package/src/lib/tooltip/ui.test.ts-snapshots/snapshots-tooltip-Chrome-Stable-linux.png +0 -0
- package/src/lib/tooltip/ui.test.ts-snapshots/snapshots-tooltip-Desktop-Firefox-darwin.png +0 -0
- package/src/lib/tooltip/ui.test.ts-snapshots/snapshots-tooltip-Desktop-Firefox-linux.png +0 -0
- package/src/lib/tooltip/ui.test.ts-snapshots/snapshots-tooltip-Desktop-Safari-darwin.png +0 -0
- package/src/lib/tooltip/ui.test.ts-snapshots/snapshots-tooltip-Desktop-Safari-linux.png +0 -0
- package/src/shared/design-system/index.ts +12 -0
- package/src/shared/patterns/affix.ts +56 -0
- package/{shared/patterns/index.d.ts → src/shared/patterns/index.ts} +1 -1
- package/src/types/extract-gfm.d.ts +5 -0
- package/src/types/style.d.ts +4 -0
- package/src/visual-tests/visual-tests-utils.ts +76 -0
- package/tsconfig.json +36 -0
- package/tsconfig.lib.json +11 -0
- package/tsconfig.spec.json +16 -0
- package/accordion/index.js +0 -61
- package/accordion-item/index.js +0 -125
- package/badge/index.js +0 -64
- package/banner/index.js +0 -212
- package/breadcrumb/index.js +0 -100
- package/breadcrumb-item/index.js +0 -55
- package/button/index.js +0 -761
- package/calendar/index.js +0 -1521
- package/elevation/index.js +0 -31
- package/focus/index.js +0 -3
- package/icon/index.js +0 -34
- package/index.js +0 -32
- package/layout/index.js +0 -53
- package/lib/accordion/accordion.d.ts +0 -9
- package/lib/accordion/accordion.template.d.ts +0 -4
- package/lib/accordion/index.d.ts +0 -2
- package/lib/accordion-item/accordion-item.d.ts +0 -13
- package/lib/accordion-item/accordion-item.template.d.ts +0 -4
- package/lib/accordion-item/index.d.ts +0 -3
- package/lib/badge/badge.d.ts +0 -17
- package/lib/badge/badge.template.d.ts +0 -4
- package/lib/badge/index.d.ts +0 -3
- package/lib/banner/banner.d.ts +0 -20
- package/lib/banner/banner.template.d.ts +0 -6
- package/lib/banner/index.d.ts +0 -2
- package/lib/breadcrumb/breadcrumb.d.ts +0 -3
- package/lib/breadcrumb/index.d.ts +0 -2
- package/lib/breadcrumb-item/breadcrumb-item.d.ts +0 -5
- package/lib/breadcrumb-item/breadcrumb-item.template.d.ts +0 -4
- package/lib/breadcrumb-item/index.d.ts +0 -3
- package/lib/button/button.d.ts +0 -17
- package/lib/button/button.template.d.ts +0 -4
- package/lib/button/index.d.ts +0 -21
- package/lib/calendar/calendar.d.ts +0 -11
- package/lib/calendar/calendar.template.d.ts +0 -4
- package/lib/calendar/helpers/calendar.date-functions.d.ts +0 -2
- package/lib/calendar/helpers/calendar.event-context.d.ts +0 -6
- package/lib/calendar/helpers/calendar.keyboard-interactions.d.ts +0 -9
- package/lib/calendar/index.d.ts +0 -3
- package/lib/elevation/elevation.d.ts +0 -4
- package/lib/elevation/elevation.template.d.ts +0 -4
- package/lib/elevation/index.d.ts +0 -2
- package/lib/enums.d.ts +0 -45
- package/lib/focus/focus.d.ts +0 -3
- package/lib/focus/focus.template.d.ts +0 -4
- package/lib/focus/index.d.ts +0 -2
- package/lib/icon/icon.d.ts +0 -11
- package/lib/icon/icon.placeholder.d.ts +0 -1
- package/lib/icon/icon.template.d.ts +0 -4
- package/lib/icon/index.d.ts +0 -2
- package/lib/layout/index.d.ts +0 -2
- package/lib/layout/layout.d.ts +0 -16
- package/lib/layout/layout.template.d.ts +0 -4
- package/lib/popup/index.d.ts +0 -4
- package/lib/popup/popup.d.ts +0 -29
- package/lib/popup/popup.template.d.ts +0 -4
- package/lib/progress/index.d.ts +0 -2
- package/lib/progress/progress.d.ts +0 -9
- package/lib/progress/progress.template.d.ts +0 -5
- package/lib/progress-ring/index.d.ts +0 -2
- package/lib/progress-ring/progress-ring.d.ts +0 -6
- package/lib/progress-ring/progress-ring.template.d.ts +0 -4
- package/lib/side-drawer/index.d.ts +0 -2
- package/lib/side-drawer/side-drawer.d.ts +0 -12
- package/lib/side-drawer/side-drawer.template.d.ts +0 -4
- package/lib/sidenav-item/index.d.ts +0 -3
- package/lib/sidenav-item/sidenav-item.d.ts +0 -6
- package/lib/sidenav-item/sidenav-item.template.d.ts +0 -4
- package/lib/text/index.d.ts +0 -2
- package/lib/text/text.d.ts +0 -10
- package/lib/text/text.template.d.ts +0 -4
- package/lib/text-anchor/index.d.ts +0 -2
- package/lib/text-anchor/text-anchor.d.ts +0 -7
- package/lib/text-anchor/text-anchor.template.d.ts +0 -4
- package/lib/tooltip/index.d.ts +0 -3
- package/lib/tooltip/tooltip.d.ts +0 -10
- package/lib/tooltip/tooltip.template.d.ts +0 -4
- package/popup/index.js +0 -2087
- package/progress/index.js +0 -98
- package/progress-ring/index.js +0 -76
- package/shared/_has.js +0 -58
- package/shared/affix.js +0 -29
- package/shared/anchor.js +0 -78
- package/shared/apply-mixins.js +0 -22
- package/shared/aria-global.js +0 -156
- package/shared/base-progress.js +0 -65
- package/shared/breadcrumb-item.js +0 -25
- package/shared/class-names.js +0 -15
- package/shared/design-system/index.d.ts +0 -3
- package/shared/es.object.assign.js +0 -68
- package/shared/icon.js +0 -1393
- package/shared/index.js +0 -4991
- package/shared/index2.js +0 -21
- package/shared/patterns/affix.d.ts +0 -9
- package/shared/slotted.js +0 -119
- package/shared/style-inject.es.js +0 -28
- package/shared/text-anchor.js +0 -21
- package/shared/text-anchor.template.js +0 -54
- package/shared/web.dom-collections.iterator.js +0 -1479
- package/shared/when.js +0 -15
- package/side-drawer/index.js +0 -103
- package/sidenav-item/index.js +0 -38
- package/styles/fonts/spezia.css +0 -23
- package/styles/themes/dark.css +0 -193
- package/styles/themes/light.css +0 -193
- package/text/index.js +0 -45
- package/text-anchor/index.js +0 -19
- package/tooltip/index.js +0 -73
package/accordion-item/index.js
DELETED
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
import { F as FoundationElement, _ as __decorate, a as attr, b as __metadata, h as html, d as designSystem } from '../shared/index.js';
|
|
2
|
-
import { s as styleInject } from '../shared/style-inject.es.js';
|
|
3
|
-
import '../shared/web.dom-collections.iterator.js';
|
|
4
|
-
import { A as AffixIconWithTrailing, a as affixIconTemplateFactory } from '../shared/affix.js';
|
|
5
|
-
import { a as applyMixins } from '../shared/apply-mixins.js';
|
|
6
|
-
import { w as when } from '../shared/when.js';
|
|
7
|
-
import { c as classNames } from '../shared/class-names.js';
|
|
8
|
-
import '../icon/index.js';
|
|
9
|
-
import '../shared/icon.js';
|
|
10
|
-
import '../shared/_has.js';
|
|
11
|
-
|
|
12
|
-
var css_248z = "/*\n Do not edit directly\n Generated on Sun, 23 Jan 2022 11:15:05 GMT\n*/\n.body {\n font: 400 ultra-condensed 14px / 20px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n padding: 8px 32px 24px 16px;\n}\n.icon:not(.icon-trailing) .body {\n padding-left: 48px;\n}\n\n.control {\n display: flex;\n flex-direction: column;\n}\n.control:not(.open) .toggle-close,\n.control:not(.open) .body {\n display: none;\n}\n.control.open .toggle-open {\n display: none;\n}\n.control.open .toggle-close {\n display: initial;\n}\n\n.header {\n padding: 0;\n margin: 0;\n}\n\n.button {\n font: 500 condensed 20px / 28px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n position: relative;\n display: flex;\n width: 100%;\n align-items: center;\n padding: 16px;\n border: 0 none;\n background: transparent;\n cursor: pointer;\n}\n.button:hover {\n background: var(--vvd-color-neutral-10);\n}\n.button .heading-text {\n flex-grow: 1;\n margin-inline-end: auto;\n text-align: left;\n}\n.button .meta {\n font: 600 ultra-condensed 14px / 20px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n overflow: hidden;\n max-width: 20%;\n flex-shrink: 0;\n color: var(--vvd-color-neutral-70);\n margin-inline-start: 1rem;\n text-align: end;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.button .indicator {\n display: flex;\n}\n.button .indicator vwc-icon,\n.button .indicator slot[name=indicator i]::slotted(vwc-icon) {\n margin-inline-start: 16px;\n}\n.button .icon {\n margin-inline-end: 16px;\n}\n\n/* Icon */\n.icon-trailing .icon {\n order: 1;\n}";
|
|
13
|
-
styleInject(css_248z);
|
|
14
|
-
|
|
15
|
-
class AccordionItem extends FoundationElement {
|
|
16
|
-
constructor() {
|
|
17
|
-
super(...arguments);
|
|
18
|
-
this.heading = '';
|
|
19
|
-
this.noIndicator = false;
|
|
20
|
-
this.meta = '';
|
|
21
|
-
this.open = false;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
attributeChangedCallback(name, oldValue, newValue) {
|
|
25
|
-
super.attributeChangedCallback(name, oldValue, newValue);
|
|
26
|
-
|
|
27
|
-
if (name === 'open') {
|
|
28
|
-
newValue === null ? this.emitEvent('closed') : this.emitEvent('opened');
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
emitEvent(name) {
|
|
33
|
-
const init = {
|
|
34
|
-
bubbles: true,
|
|
35
|
-
composed: true
|
|
36
|
-
};
|
|
37
|
-
const ev = new CustomEvent(name, init);
|
|
38
|
-
this.dispatchEvent(ev);
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
__decorate([attr({
|
|
44
|
-
mode: 'fromView'
|
|
45
|
-
}), __metadata("design:type", Object)], AccordionItem.prototype, "heading", void 0);
|
|
46
|
-
|
|
47
|
-
__decorate([attr({
|
|
48
|
-
attribute: 'heading-level'
|
|
49
|
-
}), __metadata("design:type", Number)], AccordionItem.prototype, "headingLevel", void 0);
|
|
50
|
-
|
|
51
|
-
__decorate([attr({
|
|
52
|
-
mode: 'boolean',
|
|
53
|
-
attribute: 'no-indicator'
|
|
54
|
-
}), __metadata("design:type", Object)], AccordionItem.prototype, "noIndicator", void 0);
|
|
55
|
-
|
|
56
|
-
__decorate([attr({
|
|
57
|
-
mode: 'fromView'
|
|
58
|
-
}), __metadata("design:type", Object)], AccordionItem.prototype, "meta", void 0);
|
|
59
|
-
|
|
60
|
-
__decorate([attr({
|
|
61
|
-
mode: 'boolean'
|
|
62
|
-
}), __metadata("design:type", Object)], AccordionItem.prototype, "open", void 0);
|
|
63
|
-
|
|
64
|
-
applyMixins(AccordionItem, AffixIconWithTrailing);
|
|
65
|
-
|
|
66
|
-
let _ = t => t,
|
|
67
|
-
_t,
|
|
68
|
-
_t2,
|
|
69
|
-
_t3,
|
|
70
|
-
_t4,
|
|
71
|
-
_t5;
|
|
72
|
-
const PANEL = 'panel';
|
|
73
|
-
|
|
74
|
-
const getClasses = ({
|
|
75
|
-
open,
|
|
76
|
-
iconTrailing,
|
|
77
|
-
icon,
|
|
78
|
-
noIndicator
|
|
79
|
-
}) => classNames('control', ['open', open], ['icon', Boolean(icon)], ['icon-trailing', iconTrailing], ['no-indicator', noIndicator]);
|
|
80
|
-
|
|
81
|
-
const AccordionItemTemplate = context => html(_t || (_t = _`
|
|
82
|
-
<div class="${0}">
|
|
83
|
-
${0}
|
|
84
|
-
<div class="body" id="${0}" role="region" aria-labelledby="header">
|
|
85
|
-
<slot></slot>
|
|
86
|
-
</div>
|
|
87
|
-
</div>
|
|
88
|
-
`), getClasses, x => renderPanelHeader(context, x.headingLevel), PANEL);
|
|
89
|
-
|
|
90
|
-
const renderPanelHeader = (context, headingLevel) => {
|
|
91
|
-
const header = headingLevel ? 'h' + headingLevel : 'h3';
|
|
92
|
-
return html(_t2 || (_t2 = _`
|
|
93
|
-
<${0} class="header">
|
|
94
|
-
${0}
|
|
95
|
-
</${0}>
|
|
96
|
-
`), header, renderHeaderButton(context), header);
|
|
97
|
-
};
|
|
98
|
-
|
|
99
|
-
const renderHeaderButton = context => {
|
|
100
|
-
const affixIconTemplate = affixIconTemplateFactory(context);
|
|
101
|
-
return html(_t3 || (_t3 = _`
|
|
102
|
-
<button class="button" id="header" @click=${0}
|
|
103
|
-
?aria-expanded=${0}
|
|
104
|
-
aria-controls="${0}">
|
|
105
|
-
${0}
|
|
106
|
-
<span class="heading-text">${0}</span>
|
|
107
|
-
${0}
|
|
108
|
-
<span class="indicator">
|
|
109
|
-
${0}
|
|
110
|
-
</span>
|
|
111
|
-
</button>
|
|
112
|
-
`), x => x.open = !x.open, x => x.open, PANEL, x => affixIconTemplate(x.icon), x => x.heading, when(x => x.meta, html(_t4 || (_t4 = _`<span class="meta">${0}</span>`), x => x.meta)), when(x => !x.noIndicator && !x.iconTrailing, html(_t5 || (_t5 = _`
|
|
113
|
-
<vwc-icon class="toggle-open" type='chevron-down-solid'></vwc-icon>
|
|
114
|
-
<vwc-icon class="toggle-close" type='chevron-up-solid'></vwc-icon>
|
|
115
|
-
`))));
|
|
116
|
-
};
|
|
117
|
-
|
|
118
|
-
const vividAccordionItem = AccordionItem.compose({
|
|
119
|
-
baseName: 'accordion-item',
|
|
120
|
-
template: AccordionItemTemplate,
|
|
121
|
-
styles: css_248z
|
|
122
|
-
});
|
|
123
|
-
designSystem.register(vividAccordionItem());
|
|
124
|
-
|
|
125
|
-
export { vividAccordionItem };
|
package/badge/index.js
DELETED
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
import '../icon/index.js';
|
|
2
|
-
import { F as FoundationElement, _ as __decorate, a as attr, b as __metadata, h as html, d as designSystem } from '../shared/index.js';
|
|
3
|
-
import '../shared/web.dom-collections.iterator.js';
|
|
4
|
-
import { A as AffixIconWithTrailing, a as affixIconTemplateFactory } from '../shared/affix.js';
|
|
5
|
-
import { a as applyMixins } from '../shared/apply-mixins.js';
|
|
6
|
-
import { s as styleInject } from '../shared/style-inject.es.js';
|
|
7
|
-
import { c as classNames } from '../shared/class-names.js';
|
|
8
|
-
import '../shared/icon.js';
|
|
9
|
-
import '../shared/_has.js';
|
|
10
|
-
import '../shared/when.js';
|
|
11
|
-
|
|
12
|
-
class Badge extends FoundationElement {
|
|
13
|
-
constructor() {
|
|
14
|
-
super(...arguments);
|
|
15
|
-
this.text = '';
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
__decorate([attr, __metadata("design:type", String)], Badge.prototype, "connotation", void 0);
|
|
21
|
-
|
|
22
|
-
__decorate([attr, __metadata("design:type", String)], Badge.prototype, "shape", void 0);
|
|
23
|
-
|
|
24
|
-
__decorate([attr, __metadata("design:type", String)], Badge.prototype, "appearance", void 0);
|
|
25
|
-
|
|
26
|
-
__decorate([attr, __metadata("design:type", String)], Badge.prototype, "size", void 0);
|
|
27
|
-
|
|
28
|
-
__decorate([attr({
|
|
29
|
-
mode: 'fromView'
|
|
30
|
-
}), __metadata("design:type", Object)], Badge.prototype, "text", void 0);
|
|
31
|
-
|
|
32
|
-
applyMixins(Badge, AffixIconWithTrailing);
|
|
33
|
-
|
|
34
|
-
var css_248z = "/*\n Do not edit directly\n Generated on Sun, 23 Jan 2022 11:15:05 GMT\n*/\n.control {\n font: 600 ultra-condensed 12px / 16px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n display: inline-flex;\n box-sizing: border-box;\n align-items: center;\n background-color: var(--_appearance-color-fill);\n box-shadow: inset 0 0 0 1px var(--_appearance-color-outline);\n color: var(--_appearance-color-text);\n column-gap: 8px;\n vertical-align: middle;\n}\n.control:not(.connotation-cta):not(.connotation-success):not(.connotation-alert):not(.connotation-warning):not(.connotation-info) {\n --connotation: var(--vvd-color-primary);\n --on-connotation: var(--vvd-color-on-primary);\n --connotation-soft: var(--vvd-color-neutral-20);\n --connotation-contrast: var(--vvd-color-neutral-90);\n}\n\n.control.connotation-cta {\n --connotation: var(--vvd-color-cta);\n --on-connotation: var(--vvd-color-on-cta);\n --connotation-soft: var(--vvd-color-cta-20);\n --connotation-contrast: var(--vvd-color-cta-90);\n}\n\n.control.connotation-success {\n --connotation: var(--vvd-color-success);\n --on-connotation: var(--vvd-color-on-success);\n --connotation-soft: var(--vvd-color-success-20);\n --connotation-contrast: var(--vvd-color-success-90);\n}\n\n.control.connotation-alert {\n --connotation: var(--vvd-color-alert);\n --on-connotation: var(--vvd-color-on-alert);\n --connotation-soft: var(--vvd-color-alert-20);\n --connotation-contrast: var(--vvd-color-alert-90);\n}\n\n.control.connotation-warning {\n --connotation: var(--vvd-color-warning);\n --on-connotation: var(--vvd-color-on-warning);\n --connotation-soft: var(--vvd-color-warning-20);\n --connotation-contrast: var(--vvd-color-warning-90);\n}\n\n.control.connotation-info {\n --connotation: var(--vvd-color-info);\n --on-connotation: var(--vvd-color-on-info);\n --connotation-soft: var(--vvd-color-info-20);\n --connotation-contrast: var(--vvd-color-info-90);\n}\n\n.control {\n --_appearance-color-text: var(--on-connotation);\n --_appearance-color-fill: var(--connotation);\n --_appearance-color-outline: transaprent;\n}\n.control.appearance-outlined {\n --_appearance-color-text: var(--connotation);\n --_appearance-color-fill: transaprent;\n --_appearance-color-outline: var(--connotation);\n}\n.control.appearance-subtle {\n --_appearance-color-text: var(--connotation-contrast);\n --_appearance-color-fill: var(--connotation-soft);\n --_appearance-color-outline: transaprent;\n}\n\n/* Size */\n.control:not(.size-base-small):not(.size-base-large) {\n block-size: 24px;\n padding-inline: 10px;\n}\n\n.control.size-base-small {\n block-size: 20px;\n padding-inline: 8px;\n}\n\n.control.size-base-large {\n block-size: 28px;\n padding-inline: 12px;\n}\n\n/* Shape */\n.control:not(.shape-pill) {\n border-radius: 4px;\n}\n\n.control.shape-pill {\n border-radius: 14px;\n}\n\n/* Icon */\n.icon-trailing .icon {\n order: 1;\n}";
|
|
35
|
-
styleInject(css_248z);
|
|
36
|
-
|
|
37
|
-
let _ = t => t,
|
|
38
|
-
_t;
|
|
39
|
-
|
|
40
|
-
const getClasses = ({
|
|
41
|
-
connotation,
|
|
42
|
-
appearance,
|
|
43
|
-
shape,
|
|
44
|
-
size,
|
|
45
|
-
iconTrailing
|
|
46
|
-
}) => classNames('control', [`connotation-${connotation}`, Boolean(connotation)], [`appearance-${appearance}`, Boolean(appearance)], [`shape-${shape}`, Boolean(shape)], [`size-${size}`, Boolean(size)], ['icon-trailing', iconTrailing]);
|
|
47
|
-
|
|
48
|
-
const badgeTemplate = context => {
|
|
49
|
-
const affixIconTemplate = affixIconTemplateFactory(context);
|
|
50
|
-
return html(_t || (_t = _`
|
|
51
|
-
<span class="${0}">
|
|
52
|
-
${0}
|
|
53
|
-
${0}
|
|
54
|
-
</span>`), getClasses, x => affixIconTemplate(x.icon), x => x.text);
|
|
55
|
-
};
|
|
56
|
-
|
|
57
|
-
const VIVIDBadge = Badge.compose({
|
|
58
|
-
baseName: 'badge',
|
|
59
|
-
template: badgeTemplate,
|
|
60
|
-
styles: css_248z
|
|
61
|
-
});
|
|
62
|
-
designSystem.register(VIVIDBadge());
|
|
63
|
-
|
|
64
|
-
export { VIVIDBadge };
|
package/banner/index.js
DELETED
|
@@ -1,212 +0,0 @@
|
|
|
1
|
-
import { F as FoundationElement, c as __classPrivateFieldGet, _ as __decorate, a as attr, b as __metadata, h as html, d as designSystem } from '../shared/index.js';
|
|
2
|
-
import { s as styleInject } from '../shared/style-inject.es.js';
|
|
3
|
-
import '../shared/web.dom-collections.iterator.js';
|
|
4
|
-
import { b as AffixIcon, a as affixIconTemplateFactory } from '../shared/affix.js';
|
|
5
|
-
import { a as applyMixins } from '../shared/apply-mixins.js';
|
|
6
|
-
import '../button/index.js';
|
|
7
|
-
import '../text-anchor/index.js';
|
|
8
|
-
import { w as when } from '../shared/when.js';
|
|
9
|
-
import { c as classNames } from '../shared/class-names.js';
|
|
10
|
-
import '../shared/icon.js';
|
|
11
|
-
import '../shared/_has.js';
|
|
12
|
-
import '../icon/index.js';
|
|
13
|
-
import '../shared/index2.js';
|
|
14
|
-
import '../shared/aria-global.js';
|
|
15
|
-
import '../shared/text-anchor.js';
|
|
16
|
-
import '../shared/anchor.js';
|
|
17
|
-
import '../shared/text-anchor.template.js';
|
|
18
|
-
|
|
19
|
-
var css_248z = "/*\n Do not edit directly\n Generated on Sun, 23 Jan 2022 11:15:05 GMT\n*/\n.control {\n overflow: hidden;\n max-height: 10rem;\n background-color: var(--_appearance-color-fill);\n color: var(--_appearance-color-text);\n transition: max-height var(--transition-delay, 200ms);\n}\n.control.connotation-success {\n --connotation: var(--vvd-color-success);\n --on-connotation: var(--vvd-color-on-success);\n --connotation-diverse: var(--vvd-color-success-70);\n}\n\n.control:not(.connotation-success):not(.connotation-alert):not(.connotation-announcement):not(.connotation-warning) {\n --connotation: var(--vvd-color-info);\n --on-connotation: var(--vvd-color-on-info);\n --connotation-diverse: var(--vvd-color-info-70);\n}\n\n.control.connotation-alert {\n --connotation: var(--vvd-color-alert);\n --on-connotation: var(--vvd-color-on-alert);\n --connotation-diverse: var(--vvd-color-alert-70);\n}\n\n.control.connotation-announcement {\n --connotation: var(--vvd-color-announcement);\n --on-connotation: var(--vvd-color-on-announcement);\n --connotation-diverse: var(--vvd-color-announcement-70);\n}\n\n.control.connotation-warning {\n --connotation: var(--vvd-color-warning);\n --on-connotation: var(--vvd-color-on-warning);\n --connotation-diverse: var(--vvd-color-warning-70);\n}\n\n.control {\n --_appearance-color-text: var(--on-connotation);\n --_appearance-color-fill: var(--connotation);\n --_appearance-color-outline: transaprent;\n}\n.control.removing {\n max-height: 0;\n}\n.control > .header {\n font: 600 ultra-condensed 14px / 20px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n display: flex;\n min-height: 60px;\n align-items: center;\n justify-content: flex-start;\n}\n.control > .header > .user-content {\n display: flex;\n flex: 1 0;\n align-items: center;\n justify-content: center;\n padding-inline: 16px;\n}\n.control > .header > .user-content > .icon {\n flex: 0 0 auto;\n font-size: 20px;\n margin-inline-end: 15px;\n}\n.control > .header > .user-content > .action-items {\n display: inline-block;\n flex: 0 0 auto;\n padding-inline-start: 15px;\n}\n.control > .header > .user-content > .message {\n padding: 20px 0;\n}\n.control > .header > .dismiss-button {\n --vvd-icon-button-color: inherit;\n flex: 0 0 auto;\n margin-inline-end: 8px;\n}";
|
|
20
|
-
styleInject(css_248z);
|
|
21
|
-
|
|
22
|
-
var Connotation;
|
|
23
|
-
|
|
24
|
-
(function (Connotation) {
|
|
25
|
-
Connotation["Primary"] = "primary";
|
|
26
|
-
Connotation["CTA"] = "cta";
|
|
27
|
-
Connotation["Success"] = "success";
|
|
28
|
-
Connotation["Alert"] = "alert";
|
|
29
|
-
Connotation["Warning"] = "warning";
|
|
30
|
-
Connotation["Info"] = "info";
|
|
31
|
-
Connotation["Announcement"] = "announcement";
|
|
32
|
-
})(Connotation || (Connotation = {}));
|
|
33
|
-
|
|
34
|
-
var ConnotationDecorative;
|
|
35
|
-
|
|
36
|
-
(function (ConnotationDecorative) {
|
|
37
|
-
ConnotationDecorative["Pacific"] = "pacific";
|
|
38
|
-
})(ConnotationDecorative || (ConnotationDecorative = {}));
|
|
39
|
-
|
|
40
|
-
var Shape;
|
|
41
|
-
|
|
42
|
-
(function (Shape) {
|
|
43
|
-
Shape["Rounded"] = "rounded";
|
|
44
|
-
Shape["Pill"] = "pill";
|
|
45
|
-
Shape["Circled"] = "circled";
|
|
46
|
-
Shape["Sharp"] = "sharp";
|
|
47
|
-
})(Shape || (Shape = {}));
|
|
48
|
-
|
|
49
|
-
var Appearance;
|
|
50
|
-
|
|
51
|
-
(function (Appearance) {
|
|
52
|
-
Appearance["Text"] = "text";
|
|
53
|
-
Appearance["Filled"] = "filled";
|
|
54
|
-
Appearance["Outlined"] = "outlined";
|
|
55
|
-
Appearance["Subtle"] = "subtle";
|
|
56
|
-
Appearance["Ghost"] = "ghost";
|
|
57
|
-
})(Appearance || (Appearance = {}));
|
|
58
|
-
|
|
59
|
-
var Size;
|
|
60
|
-
|
|
61
|
-
(function (Size) {
|
|
62
|
-
Size["BaseSmall"] = "base-small";
|
|
63
|
-
Size["Base"] = "base";
|
|
64
|
-
Size["BaseLarge"] = "base-large";
|
|
65
|
-
})(Size || (Size = {}));
|
|
66
|
-
|
|
67
|
-
var Position;
|
|
68
|
-
|
|
69
|
-
(function (Position) {
|
|
70
|
-
Position["Top"] = "TOP";
|
|
71
|
-
Position["Bottom"] = "BOTTOM";
|
|
72
|
-
Position["Start"] = "START";
|
|
73
|
-
Position["Center"] = "CENTER";
|
|
74
|
-
Position["End"] = "END";
|
|
75
|
-
})(Position || (Position = {}));
|
|
76
|
-
|
|
77
|
-
var Role;
|
|
78
|
-
|
|
79
|
-
(function (Role) {
|
|
80
|
-
Role["Status"] = "status";
|
|
81
|
-
Role["Alert"] = "alert";
|
|
82
|
-
})(Role || (Role = {}));
|
|
83
|
-
|
|
84
|
-
var AriaLive;
|
|
85
|
-
|
|
86
|
-
(function (AriaLive) {
|
|
87
|
-
AriaLive["Polite"] = "polite";
|
|
88
|
-
AriaLive["Assertive"] = "assertive";
|
|
89
|
-
})(AriaLive || (AriaLive = {}));
|
|
90
|
-
|
|
91
|
-
var _Banner_handleRemoveEnd, _Banner_closeOnKeyDown;
|
|
92
|
-
const connotationIconMap = new Map([[Connotation.Info, 'info-solid'], [Connotation.Announcement, 'megaphone-solid'], [Connotation.Success, 'check-circle-solid'], [Connotation.Warning, 'warning-solid'], [Connotation.Alert, 'error-solid']]);
|
|
93
|
-
|
|
94
|
-
const defaultConnotation = (connotation = Connotation.Info) => connotationIconMap.get(connotation);
|
|
95
|
-
|
|
96
|
-
class Banner extends FoundationElement {
|
|
97
|
-
constructor() {
|
|
98
|
-
super(...arguments);
|
|
99
|
-
this.removable = false;
|
|
100
|
-
|
|
101
|
-
_Banner_handleRemoveEnd.set(this, () => {
|
|
102
|
-
this.$emit('vwc-banner:removed');
|
|
103
|
-
this.parentElement && this.parentElement.removeChild(this);
|
|
104
|
-
});
|
|
105
|
-
|
|
106
|
-
_Banner_closeOnKeyDown.set(this, e => {
|
|
107
|
-
if (e.key !== 'Escape' || !this.removable) {
|
|
108
|
-
return;
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
this.remove();
|
|
112
|
-
});
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
get conditionedIcon() {
|
|
116
|
-
var _a;
|
|
117
|
-
|
|
118
|
-
return (_a = this.icon) !== null && _a !== void 0 ? _a : defaultConnotation(this.connotation);
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
connectedCallback() {
|
|
122
|
-
super.connectedCallback();
|
|
123
|
-
this.addEventListener('keydown', __classPrivateFieldGet(this, _Banner_closeOnKeyDown, "f"));
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
disconnectedCallback() {
|
|
127
|
-
super.disconnectedCallback();
|
|
128
|
-
this.removeEventListener('keydown', __classPrivateFieldGet(this, _Banner_closeOnKeyDown, "f"));
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
remove() {
|
|
132
|
-
this.$emit('vwc-banner:removing');
|
|
133
|
-
const banner = this.shadowRoot && this.shadowRoot.querySelector('.banner');
|
|
134
|
-
|
|
135
|
-
if (banner) {
|
|
136
|
-
banner.classList.add('removing');
|
|
137
|
-
banner.addEventListener('transitionend', __classPrivateFieldGet(this, _Banner_handleRemoveEnd, "f"));
|
|
138
|
-
}
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
}
|
|
142
|
-
_Banner_handleRemoveEnd = new WeakMap(), _Banner_closeOnKeyDown = new WeakMap();
|
|
143
|
-
|
|
144
|
-
__decorate([attr({
|
|
145
|
-
attribute: 'action-href'
|
|
146
|
-
}), __metadata("design:type", Object)], Banner.prototype, "actionHref", void 0);
|
|
147
|
-
|
|
148
|
-
__decorate([attr({
|
|
149
|
-
attribute: 'action-text'
|
|
150
|
-
}), __metadata("design:type", Object)], Banner.prototype, "actionText", void 0);
|
|
151
|
-
|
|
152
|
-
__decorate([attr({
|
|
153
|
-
mode: 'boolean'
|
|
154
|
-
}), __metadata("design:type", Object)], Banner.prototype, "removable", void 0);
|
|
155
|
-
|
|
156
|
-
__decorate([attr({
|
|
157
|
-
attribute: 'aria-live'
|
|
158
|
-
}), __metadata("design:type", Object)], Banner.prototype, "ariaLive", void 0);
|
|
159
|
-
|
|
160
|
-
__decorate([attr(), __metadata("design:type", Object)], Banner.prototype, "role", void 0);
|
|
161
|
-
|
|
162
|
-
__decorate([attr(), __metadata("design:type", Object)], Banner.prototype, "text", void 0);
|
|
163
|
-
|
|
164
|
-
__decorate([attr(), __metadata("design:type", Object)], Banner.prototype, "connotation", void 0);
|
|
165
|
-
|
|
166
|
-
applyMixins(Banner, AffixIcon);
|
|
167
|
-
|
|
168
|
-
let _2 = t => t,
|
|
169
|
-
_t,
|
|
170
|
-
_t2;
|
|
171
|
-
|
|
172
|
-
const getClasses = _ => classNames('control', [`connotation-${_.connotation}`, !!_.connotation]);
|
|
173
|
-
|
|
174
|
-
function renderDismissButton() {
|
|
175
|
-
return html(_t || (_t = _2`
|
|
176
|
-
<vwc-button
|
|
177
|
-
size="base-small"
|
|
178
|
-
class="dismiss-button"
|
|
179
|
-
icon="close-line"
|
|
180
|
-
@click="${0}">
|
|
181
|
-
</vwc-button>`), x => x.remove());
|
|
182
|
-
}
|
|
183
|
-
|
|
184
|
-
const BannerTemplate = context => {
|
|
185
|
-
const affixIconTemplate = affixIconTemplateFactory(context);
|
|
186
|
-
return html(_t2 || (_t2 = _2`
|
|
187
|
-
<div class="banner ${0}" tabindex="0">
|
|
188
|
-
<header class="header">
|
|
189
|
-
<div class="user-content">
|
|
190
|
-
${0}
|
|
191
|
-
<div class="banner--message"
|
|
192
|
-
role="${0}"
|
|
193
|
-
aria-live="${0}">
|
|
194
|
-
${0}
|
|
195
|
-
</div>
|
|
196
|
-
<slot class="action-items" name="actionItems"></slot>
|
|
197
|
-
</div>
|
|
198
|
-
|
|
199
|
-
${0}
|
|
200
|
-
</header>
|
|
201
|
-
</div>
|
|
202
|
-
`), getClasses, x => affixIconTemplate(x.conditionedIcon), x => x.role ? x.role : 'status', x => x.ariaLive ? x.ariaLive : 'polite', x => x.text, when(x => x.removable, renderDismissButton()));
|
|
203
|
-
};
|
|
204
|
-
|
|
205
|
-
const vividBanner = Banner.compose({
|
|
206
|
-
baseName: 'banner',
|
|
207
|
-
template: BannerTemplate,
|
|
208
|
-
styles: css_248z
|
|
209
|
-
});
|
|
210
|
-
designSystem.register(vividBanner());
|
|
211
|
-
|
|
212
|
-
export { vividBanner };
|
package/breadcrumb/index.js
DELETED
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
import { h as html, F as FoundationElement, _ as __decorate, o as observable, d as designSystem } from '../shared/index.js';
|
|
2
|
-
import { s as styleInject } from '../shared/style-inject.es.js';
|
|
3
|
-
import { B as BreadcrumbItem } from '../shared/breadcrumb-item.js';
|
|
4
|
-
import { s as slotted, e as elements } from '../shared/slotted.js';
|
|
5
|
-
import '../shared/anchor.js';
|
|
6
|
-
import '../shared/apply-mixins.js';
|
|
7
|
-
import '../shared/aria-global.js';
|
|
8
|
-
|
|
9
|
-
/**
|
|
10
|
-
* The template for the {@link @microsoft/fast-foundation#Breadcrumb} component.
|
|
11
|
-
* @public
|
|
12
|
-
*/
|
|
13
|
-
const breadcrumbTemplate = (context, definition) => html `
|
|
14
|
-
<template role="navigation">
|
|
15
|
-
<div role="list" class="list" part="list">
|
|
16
|
-
<slot
|
|
17
|
-
${slotted({ property: "slottedBreadcrumbItems", filter: elements() })}
|
|
18
|
-
></slot>
|
|
19
|
-
</div>
|
|
20
|
-
</template>
|
|
21
|
-
`;
|
|
22
|
-
|
|
23
|
-
/**
|
|
24
|
-
* A Breadcrumb Custom HTML Element.
|
|
25
|
-
*
|
|
26
|
-
* @public
|
|
27
|
-
*/
|
|
28
|
-
class Breadcrumb$1 extends FoundationElement {
|
|
29
|
-
slottedBreadcrumbItemsChanged() {
|
|
30
|
-
if (this.$fastController.isConnected) {
|
|
31
|
-
if (this.slottedBreadcrumbItems === undefined ||
|
|
32
|
-
this.slottedBreadcrumbItems.length === 0) {
|
|
33
|
-
return;
|
|
34
|
-
}
|
|
35
|
-
const lastNode = this.slottedBreadcrumbItems[this.slottedBreadcrumbItems.length - 1];
|
|
36
|
-
this.slottedBreadcrumbItems.forEach((item) => {
|
|
37
|
-
const itemIsLastNode = item === lastNode;
|
|
38
|
-
this.setItemSeparator(item, itemIsLastNode);
|
|
39
|
-
this.setAriaCurrent(item, itemIsLastNode);
|
|
40
|
-
});
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
setItemSeparator(item, isLastNode) {
|
|
44
|
-
if (item instanceof BreadcrumbItem) {
|
|
45
|
-
item.separator = !isLastNode;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
/**
|
|
49
|
-
* Finds href on childnodes in the light DOM or shadow DOM.
|
|
50
|
-
* We look in the shadow DOM because we insert an anchor when breadcrumb-item has an href.
|
|
51
|
-
*/
|
|
52
|
-
findChildWithHref(node) {
|
|
53
|
-
var _a, _b;
|
|
54
|
-
if (node.childElementCount > 0) {
|
|
55
|
-
return node.querySelector("a[href]");
|
|
56
|
-
}
|
|
57
|
-
else if ((_a = node.shadowRoot) === null || _a === void 0 ? void 0 : _a.childElementCount) {
|
|
58
|
-
return (_b = node.shadowRoot) === null || _b === void 0 ? void 0 : _b.querySelector("a[href]");
|
|
59
|
-
}
|
|
60
|
-
else
|
|
61
|
-
return null;
|
|
62
|
-
}
|
|
63
|
-
/**
|
|
64
|
-
* Sets ARIA Current for the current node
|
|
65
|
-
* If child node with an anchor tag and with href is found then set aria-current to correct value for the child node,
|
|
66
|
-
* otherwise apply aria-current to the host element, with an href
|
|
67
|
-
*/
|
|
68
|
-
setAriaCurrent(item, isLastNode) {
|
|
69
|
-
const childNodeWithHref = this.findChildWithHref(item);
|
|
70
|
-
if (childNodeWithHref === null &&
|
|
71
|
-
item.hasAttribute("href") &&
|
|
72
|
-
item instanceof BreadcrumbItem) {
|
|
73
|
-
isLastNode
|
|
74
|
-
? item.setAttribute("aria-current", "page")
|
|
75
|
-
: item.removeAttribute("aria-current");
|
|
76
|
-
}
|
|
77
|
-
else if (childNodeWithHref !== null) {
|
|
78
|
-
isLastNode
|
|
79
|
-
? childNodeWithHref.setAttribute("aria-current", "page")
|
|
80
|
-
: childNodeWithHref.removeAttribute("aria-current");
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
__decorate([
|
|
85
|
-
observable
|
|
86
|
-
], Breadcrumb$1.prototype, "slottedBreadcrumbItems", void 0);
|
|
87
|
-
|
|
88
|
-
var css_248z = ".list {\n display: flex;\n}";
|
|
89
|
-
styleInject(css_248z);
|
|
90
|
-
|
|
91
|
-
class Breadcrumb extends Breadcrumb$1 {}
|
|
92
|
-
|
|
93
|
-
const vividBreadcrumb = Breadcrumb.compose({
|
|
94
|
-
baseName: 'breadcrumb',
|
|
95
|
-
template: breadcrumbTemplate,
|
|
96
|
-
styles: css_248z
|
|
97
|
-
});
|
|
98
|
-
designSystem.register(vividBreadcrumb());
|
|
99
|
-
|
|
100
|
-
export { vividBreadcrumb };
|
package/breadcrumb-item/index.js
DELETED
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import '../icon/index.js';
|
|
2
|
-
import { _ as __decorate, a as attr, b as __metadata, h as html, d as designSystem } from '../shared/index.js';
|
|
3
|
-
import { s as styleInject } from '../shared/style-inject.es.js';
|
|
4
|
-
import { B as BreadcrumbItem$1 } from '../shared/breadcrumb-item.js';
|
|
5
|
-
import { t as textAnchorTemplate } from '../shared/text-anchor.template.js';
|
|
6
|
-
import { w as when } from '../shared/when.js';
|
|
7
|
-
import { c as classNames } from '../shared/class-names.js';
|
|
8
|
-
import '../shared/icon.js';
|
|
9
|
-
import '../shared/web.dom-collections.iterator.js';
|
|
10
|
-
import '../shared/_has.js';
|
|
11
|
-
import '../shared/anchor.js';
|
|
12
|
-
import '../shared/apply-mixins.js';
|
|
13
|
-
import '../shared/aria-global.js';
|
|
14
|
-
import '../shared/affix.js';
|
|
15
|
-
|
|
16
|
-
var css_248z = "/*\n Do not edit directly\n Generated on Sun, 23 Jan 2022 11:15:05 GMT\n*/\n.breadcrumb-item {\n font: 400 ultra-condensed 14px / 20px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n display: flex;\n align-items: center;\n color: var(--vvd-color-neutral-70);\n}\n.breadcrumb-item a {\n color: var(--vvd-color-cta-70);\n font: inherit;\n text-decoration: none;\n}\n.breadcrumb-item a:hover {\n text-decoration: underline;\n}\n.breadcrumb-item vwc-icon {\n margin: 0 16px;\n color: var(--vvd-color-on-canvas);\n}";
|
|
17
|
-
styleInject(css_248z);
|
|
18
|
-
|
|
19
|
-
class BreadcrumbItem extends BreadcrumbItem$1 {
|
|
20
|
-
constructor() {
|
|
21
|
-
super();
|
|
22
|
-
this.text = '';
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
__decorate([attr({
|
|
28
|
-
mode: 'fromView'
|
|
29
|
-
}), __metadata("design:type", String)], BreadcrumbItem.prototype, "text", void 0);
|
|
30
|
-
|
|
31
|
-
let _2 = t => t,
|
|
32
|
-
_t,
|
|
33
|
-
_t2,
|
|
34
|
-
_t3,
|
|
35
|
-
_t4;
|
|
36
|
-
|
|
37
|
-
const getClasses = _ => classNames('control', 'breadcrumb-item');
|
|
38
|
-
|
|
39
|
-
const BreadcrumbItemTemplate = (context, definition) => html(_t || (_t = _2`
|
|
40
|
-
<div roll="listitem" part="listitem" class="${0}">
|
|
41
|
-
${0}
|
|
42
|
-
|
|
43
|
-
${0}
|
|
44
|
-
|
|
45
|
-
${0}
|
|
46
|
-
</div>`), getClasses, when(x => x.text && !x.href, html(_t2 || (_t2 = _2`${0}`), x => x.text)), when(x => x.text && x.href && x.href.length > 0, html(_t3 || (_t3 = _2`${0}`), textAnchorTemplate(context))), when(x => x.separator, html(_t4 || (_t4 = _2`<vwc-icon type="chevron-right-line"></vwc-icon>`))));
|
|
47
|
-
|
|
48
|
-
const vividBreadcrumbItem = BreadcrumbItem.compose({
|
|
49
|
-
baseName: 'breadcrumb-item',
|
|
50
|
-
template: BreadcrumbItemTemplate,
|
|
51
|
-
styles: css_248z
|
|
52
|
-
});
|
|
53
|
-
designSystem.register(vividBreadcrumbItem());
|
|
54
|
-
|
|
55
|
-
export { vividBreadcrumbItem };
|