@sk-web-gui/core 0.1.42 → 0.1.44
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -21
- package/README.md +5 -5
- package/dist/cjs/colors.js +140 -0
- package/dist/cjs/colors.js.map +1 -0
- package/dist/cjs/components/accordion.js +86 -0
- package/dist/cjs/components/accordion.js.map +1 -0
- package/dist/cjs/components/alert.js +71 -0
- package/dist/cjs/components/alert.js.map +1 -0
- package/dist/cjs/components/avatar.js +78 -0
- package/dist/cjs/components/avatar.js.map +1 -0
- package/dist/cjs/components/badge.js +53 -0
- package/dist/cjs/components/badge.js.map +1 -0
- package/dist/cjs/components/breadcrumb.js +23 -0
- package/dist/cjs/components/breadcrumb.js.map +1 -0
- package/dist/cjs/components/button-group.js +50 -0
- package/dist/cjs/components/button-group.js.map +1 -0
- package/dist/cjs/components/button.js +154 -0
- package/dist/cjs/components/button.js.map +1 -0
- package/dist/cjs/components/calendar.js +76 -0
- package/dist/cjs/components/calendar.js.map +1 -0
- package/dist/cjs/components/card.js +59 -0
- package/dist/cjs/components/card.js.map +1 -0
- package/dist/cjs/components/checkbox.js +92 -0
- package/dist/cjs/components/checkbox.js.map +1 -0
- package/dist/cjs/components/code.js +21 -0
- package/dist/cjs/components/code.js.map +1 -0
- package/dist/cjs/components/cookie-consent.js +35 -0
- package/dist/cjs/components/cookie-consent.js.map +1 -0
- package/dist/cjs/components/divider.js +24 -0
- package/dist/cjs/components/divider.js.map +1 -0
- package/dist/cjs/components/dot.js +70 -0
- package/dist/cjs/components/dot.js.map +1 -0
- package/dist/cjs/components/footer.js +39 -0
- package/dist/cjs/components/footer.js.map +1 -0
- package/dist/cjs/components/forms.js +225 -0
- package/dist/cjs/components/forms.js.map +1 -0
- package/dist/cjs/components/header.js +34 -0
- package/dist/cjs/components/header.js.map +1 -0
- package/dist/cjs/components/icon-button.js +17 -0
- package/dist/cjs/components/icon-button.js.map +1 -0
- package/dist/cjs/components/icon.js +20 -0
- package/dist/cjs/components/icon.js.map +1 -0
- package/dist/cjs/components/kbd.js +21 -0
- package/dist/cjs/components/kbd.js.map +1 -0
- package/dist/cjs/components/link.js +29 -0
- package/dist/cjs/components/link.js.map +1 -0
- package/dist/cjs/components/message.js +63 -0
- package/dist/cjs/components/message.js.map +1 -0
- package/dist/cjs/components/modal.js +35 -0
- package/dist/cjs/components/modal.js.map +1 -0
- package/dist/cjs/components/notification.js +58 -0
- package/dist/cjs/components/notification.js.map +1 -0
- package/dist/cjs/components/pagination.js +66 -0
- package/dist/cjs/components/pagination.js.map +1 -0
- package/dist/cjs/components/radio.js +95 -0
- package/dist/cjs/components/radio.js.map +1 -0
- package/dist/cjs/components/switch.js +107 -0
- package/dist/cjs/components/switch.js.map +1 -0
- package/dist/cjs/components/table.js +23 -0
- package/dist/cjs/components/table.js.map +1 -0
- package/dist/cjs/components/tag.js +88 -0
- package/dist/cjs/components/tag.js.map +1 -0
- package/dist/cjs/components/types.js +10 -0
- package/dist/cjs/components/types.js.map +1 -0
- package/dist/cjs/components/user-menu.js +33 -0
- package/dist/cjs/components/user-menu.js.map +1 -0
- package/dist/cjs/components/zebratable.js +70 -0
- package/dist/cjs/components/zebratable.js.map +1 -0
- package/dist/cjs/index.js +282 -0
- package/dist/cjs/index.js.map +1 -0
- package/dist/cjs/with-opacity.js +15 -0
- package/dist/cjs/with-opacity.js.map +1 -0
- package/dist/esm/colors.js +137 -0
- package/dist/esm/colors.js.map +1 -0
- package/dist/esm/components/accordion.js +76 -0
- package/dist/esm/components/accordion.js.map +1 -0
- package/dist/esm/components/alert.js +67 -0
- package/dist/esm/components/alert.js.map +1 -0
- package/dist/esm/components/avatar.js +68 -0
- package/dist/esm/components/avatar.js.map +1 -0
- package/dist/esm/components/badge.js +48 -0
- package/dist/esm/components/badge.js.map +1 -0
- package/dist/esm/components/breadcrumb.js +13 -0
- package/dist/esm/components/breadcrumb.js.map +1 -0
- package/dist/esm/components/button-group.js +40 -0
- package/dist/esm/components/button-group.js.map +1 -0
- package/dist/esm/components/button.js +197 -0
- package/dist/esm/components/button.js.map +1 -0
- package/dist/esm/components/calendar.js +66 -0
- package/dist/esm/components/calendar.js.map +1 -0
- package/dist/esm/components/card.js +49 -0
- package/dist/esm/components/card.js.map +1 -0
- package/dist/esm/components/checkbox.js +110 -0
- package/dist/esm/components/checkbox.js.map +1 -0
- package/dist/esm/components/code.js +11 -0
- package/dist/esm/components/code.js.map +1 -0
- package/dist/esm/components/cookie-consent.js +25 -0
- package/dist/esm/components/cookie-consent.js.map +1 -0
- package/dist/esm/components/divider.js +14 -0
- package/dist/esm/components/divider.js.map +1 -0
- package/dist/esm/components/dot.js +61 -0
- package/dist/esm/components/dot.js.map +1 -0
- package/dist/esm/components/footer.js +29 -0
- package/dist/esm/components/footer.js.map +1 -0
- package/dist/esm/components/forms.js +217 -0
- package/dist/esm/components/forms.js.map +1 -0
- package/dist/esm/components/header.js +29 -0
- package/dist/esm/components/header.js.map +1 -0
- package/dist/esm/components/icon-button.js +7 -0
- package/dist/esm/components/icon-button.js.map +1 -0
- package/dist/esm/components/icon.js +10 -0
- package/dist/esm/components/icon.js.map +1 -0
- package/dist/esm/components/kbd.js +11 -0
- package/dist/esm/components/kbd.js.map +1 -0
- package/dist/esm/components/link.js +19 -0
- package/dist/esm/components/link.js.map +1 -0
- package/dist/esm/components/message.js +53 -0
- package/dist/esm/components/message.js.map +1 -0
- package/dist/esm/components/modal.js +25 -0
- package/dist/esm/components/modal.js.map +1 -0
- package/dist/esm/components/notification.js +48 -0
- package/dist/esm/components/notification.js.map +1 -0
- package/dist/esm/components/pagination.js +56 -0
- package/dist/esm/components/pagination.js.map +1 -0
- package/dist/esm/components/radio.js +88 -0
- package/dist/esm/components/radio.js.map +1 -0
- package/dist/esm/components/switch.js +98 -0
- package/dist/esm/components/switch.js.map +1 -0
- package/dist/esm/components/table.js +13 -0
- package/dist/esm/components/table.js.map +1 -0
- package/dist/esm/components/tag.js +84 -0
- package/dist/esm/components/tag.js.map +1 -0
- package/dist/esm/components/types.js +3 -0
- package/dist/esm/components/types.js.map +1 -0
- package/dist/esm/components/user-menu.js +23 -0
- package/dist/esm/components/user-menu.js.map +1 -0
- package/dist/esm/components/zebratable.js +60 -0
- package/dist/esm/components/zebratable.js.map +1 -0
- package/dist/esm/index.js +327 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/with-opacity.js +10 -0
- package/dist/esm/with-opacity.js.map +1 -0
- package/dist/types/accordion/index.d.ts +1 -0
- package/dist/types/accordion/src/accordion.d.ts +17 -0
- package/dist/types/accordion/src/index.d.ts +1 -0
- package/dist/types/accordion/src/styles.d.ts +1 -0
- package/dist/types/accordion/stories/accordion.stories.d.ts +40 -0
- package/dist/types/alert/index.d.ts +1 -0
- package/dist/types/alert/src/alert.d.ts +15 -0
- package/dist/types/alert/src/index.d.ts +8 -0
- package/dist/types/alert/src/styles.d.ts +2 -0
- package/dist/types/breadcrumb/index.d.ts +1 -0
- package/dist/types/breadcrumb/src/breadcrumb.d.ts +34 -0
- package/dist/types/breadcrumb/src/index.d.ts +10 -0
- package/dist/types/breadcrumb/stories/breadcrumb.stories.d.ts +28 -0
- package/dist/types/button/index.d.ts +1 -0
- package/dist/types/button/src/button-group.d.ts +20 -0
- package/dist/types/button/src/button.d.ts +21 -0
- package/dist/types/button/src/icon-button.d.ts +17 -0
- package/dist/types/button/src/index.d.ts +10 -0
- package/dist/types/button/src/styles.d.ts +1 -0
- package/dist/types/button/stories/announcement.d.ts +6 -0
- package/dist/types/button/stories/button-group.stories.d.ts +14 -0
- package/dist/types/button/stories/button.stories.d.ts +127 -0
- package/dist/types/button/stories/icon-button.stories.d.ts +16 -0
- package/dist/types/card/index.d.ts +1 -0
- package/dist/types/card/src/card.d.ts +38 -0
- package/dist/types/card/src/index.d.ts +1 -0
- package/dist/types/card/src/styles.d.ts +1 -0
- package/dist/types/card/stories/card.stories.d.ts +56 -0
- package/dist/types/checkbox/index.d.ts +1 -0
- package/dist/types/checkbox/src/checkbox-group.d.ts +36 -0
- package/dist/types/checkbox/src/checkbox.d.ts +46 -0
- package/dist/types/checkbox/src/index.d.ts +9 -0
- package/dist/types/checkbox/src/styles.d.ts +2 -0
- package/dist/types/checkbox/stories/checkbox.stories.d.ts +103 -0
- package/dist/types/cookie-consent/index.d.ts +1 -0
- package/dist/types/cookie-consent/src/cookie-consent.d.ts +37 -0
- package/dist/types/cookie-consent/src/index.d.ts +1 -0
- package/dist/types/cookie-consent/src/styles.d.ts +1 -0
- package/dist/types/core/src/colors.d.ts +1 -0
- package/dist/types/core/src/components/accordion.d.ts +3 -0
- package/dist/types/core/src/components/alert.d.ts +3 -0
- package/dist/types/core/src/components/avatar.d.ts +3 -0
- package/dist/types/core/src/components/badge.d.ts +3 -0
- package/dist/types/core/src/components/breadcrumb.d.ts +3 -0
- package/dist/types/core/src/components/button-group.d.ts +3 -0
- package/dist/types/core/src/components/button.d.ts +3 -0
- package/dist/types/core/src/components/calendar.d.ts +3 -0
- package/dist/types/core/src/components/card.d.ts +3 -0
- package/dist/types/core/src/components/checkbox.d.ts +3 -0
- package/dist/types/core/src/components/code.d.ts +3 -0
- package/dist/types/core/src/components/cookie-consent.d.ts +3 -0
- package/dist/types/core/src/components/divider.d.ts +3 -0
- package/dist/types/core/src/components/dot.d.ts +3 -0
- package/dist/types/core/src/components/footer.d.ts +3 -0
- package/dist/types/core/src/components/forms.d.ts +3 -0
- package/dist/types/core/src/components/header.d.ts +3 -0
- package/dist/types/core/src/components/icon-button.d.ts +3 -0
- package/dist/types/core/src/components/icon.d.ts +3 -0
- package/dist/types/core/src/components/kbd.d.ts +3 -0
- package/dist/types/core/src/components/link.d.ts +3 -0
- package/dist/types/core/src/components/message.d.ts +3 -0
- package/dist/types/core/src/components/modal.d.ts +3 -0
- package/dist/types/core/src/components/notification.d.ts +3 -0
- package/dist/types/core/src/components/pagination.d.ts +3 -0
- package/dist/types/core/src/components/radio.d.ts +3 -0
- package/dist/types/core/src/components/switch.d.ts +3 -0
- package/dist/types/core/src/components/table.d.ts +3 -0
- package/dist/types/core/src/components/tag.d.ts +3 -0
- package/dist/types/core/src/components/types.d.ts +5 -0
- package/dist/types/core/src/components/user-menu.d.ts +3 -0
- package/dist/types/core/src/components/zebratable.d.ts +3 -0
- package/dist/types/core/src/index.d.ts +1 -0
- package/dist/types/core/src/with-opacity.d.ts +3 -0
- package/dist/types/divider/index.d.ts +1 -0
- package/dist/types/divider/src/divider.d.ts +9 -0
- package/dist/types/divider/src/index.d.ts +1 -0
- package/dist/types/divider/stories/divider.stories.d.ts +33 -0
- package/dist/types/dot/index.d.ts +1 -0
- package/dist/types/dot/src/dot.d.ts +12 -0
- package/dist/types/dot/src/index.d.ts +1 -0
- package/dist/types/dot/src/styles.d.ts +1 -0
- package/dist/types/dot/stories/dot.stories.d.ts +15 -0
- package/dist/types/footer/index.d.ts +1 -0
- package/dist/types/footer/src/footer.d.ts +11 -0
- package/dist/types/footer/src/index.d.ts +1 -0
- package/dist/types/footer/stories/footer.stories.d.ts +95 -0
- package/dist/types/forms/index.d.ts +1 -0
- package/dist/types/forms/src/calendar/index.d.ts +12 -0
- package/dist/types/forms/src/calendar/styles.d.ts +1 -0
- package/dist/types/forms/src/form-control/index.d.ts +27 -0
- package/dist/types/forms/src/form-error-message/index.d.ts +9 -0
- package/dist/types/forms/src/form-helper-text/index.d.ts +9 -0
- package/dist/types/forms/src/form-label/index.d.ts +13 -0
- package/dist/types/forms/src/index.d.ts +8 -0
- package/dist/types/forms/src/input/index.d.ts +15 -0
- package/dist/types/forms/src/input/input.d.ts +30 -0
- package/dist/types/forms/src/input/styles.d.ts +1 -0
- package/dist/types/forms/src/input-addon/index.d.ts +13 -0
- package/dist/types/forms/src/input-element/index.d.ts +15 -0
- package/dist/types/forms/src/input-group/index.d.ts +11 -0
- package/dist/types/forms/src/select/index.d.ts +6 -0
- package/dist/types/forms/src/select/styles.d.ts +1 -0
- package/dist/types/forms/src/textarea/index.d.ts +13 -0
- package/dist/types/forms/stories/calendar.stories.d.ts +58 -0
- package/dist/types/forms/stories/check.d.ts +6 -0
- package/dist/types/forms/stories/form-control.stories.d.ts +16 -0
- package/dist/types/forms/stories/input.stories.d.ts +32 -0
- package/dist/types/forms/stories/select.stories.d.ts +118 -0
- package/dist/types/forms/stories/textarea.stories.d.ts +23 -0
- package/dist/types/header/index.d.ts +1 -0
- package/dist/types/header/src/header.d.ts +13 -0
- package/dist/types/header/src/index.d.ts +1 -0
- package/dist/types/header/stories/header.stories.d.ts +118 -0
- package/dist/types/icon/index.d.ts +1 -0
- package/dist/types/icon/src/core.d.ts +10 -0
- package/dist/types/icon/src/icon.d.ts +14 -0
- package/dist/types/icon/src/index.d.ts +2 -0
- package/dist/types/icon/stories/icon.stories.d.ts +12 -0
- package/dist/types/image/index.d.ts +1 -0
- package/dist/types/image/src/image.d.ts +28 -0
- package/dist/types/image/src/index.d.ts +2 -0
- package/dist/types/image/src/use-image.d.ts +52 -0
- package/dist/types/image/stories/image.stories.d.ts +12 -0
- package/dist/types/link/index.d.ts +1 -0
- package/dist/types/link/src/index.d.ts +1 -0
- package/dist/types/link/src/link.d.ts +12 -0
- package/dist/types/link/stories/link.stories.d.ts +46 -0
- package/dist/types/message/index.d.ts +1 -0
- package/dist/types/message/src/index.d.ts +1 -0
- package/dist/types/message/src/message.d.ts +2 -0
- package/dist/types/message/stories/message.stories.d.ts +11 -0
- package/dist/types/notification/index.d.ts +1 -0
- package/dist/types/notification/src/index.d.ts +1 -0
- package/dist/types/notification/src/notification.d.ts +5 -0
- package/dist/types/notification/stories/notification.stories.d.ts +11 -0
- package/dist/types/pagination/index.d.ts +1 -0
- package/dist/types/pagination/src/index.d.ts +1 -0
- package/dist/types/pagination/src/pagination.d.ts +11 -0
- package/dist/types/pagination/src/styles.d.ts +1 -0
- package/dist/types/pagination/stories/pagination.stories.d.ts +75 -0
- package/dist/types/radio/index.d.ts +1 -0
- package/dist/types/radio/src/index.d.ts +9 -0
- package/dist/types/radio/src/radio-group.d.ts +41 -0
- package/dist/types/radio/src/radio.d.ts +45 -0
- package/dist/types/radio/src/styles.d.ts +2 -0
- package/dist/types/radio/stories/radio-group.stories.d.ts +75 -0
- package/dist/types/radio/stories/radio.stories.d.ts +104 -0
- package/dist/types/react/index.d.ts +1 -0
- package/dist/types/react/src/index.d.ts +26 -0
- package/dist/types/spinner/index.d.ts +1 -0
- package/dist/types/spinner/src/index.d.ts +1 -0
- package/dist/types/spinner/src/spinner.d.ts +8 -0
- package/dist/types/spinner/src/styles.d.ts +2 -0
- package/dist/types/spinner/stories/spinner.stories.d.ts +13 -0
- package/dist/types/switch/index.d.ts +1 -0
- package/dist/types/switch/src/index.d.ts +1 -0
- package/dist/types/switch/src/styles.d.ts +2 -0
- package/dist/types/switch/src/switch.d.ts +42 -0
- package/dist/types/switch/stories/switch.stories.d.ts +76 -0
- package/dist/types/table/index.d.ts +1 -0
- package/dist/types/table/src/index.d.ts +1 -0
- package/dist/types/table/src/styles.d.ts +1 -0
- package/dist/types/table/src/zebratable.d.ts +33 -0
- package/dist/types/table/stories/zebratable.stories.d.ts +69 -0
- package/dist/types/tag/index.d.ts +1 -0
- package/dist/types/tag/src/index.d.ts +1 -0
- package/dist/types/tag/src/styles.d.ts +1 -0
- package/dist/types/tag/src/tag.d.ts +13 -0
- package/dist/types/tag/stories/tag.stories.d.ts +86 -0
- package/dist/types/theme/index.d.ts +1 -0
- package/dist/types/theme/src/colors.d.ts +272 -0
- package/dist/types/theme/src/create-memo-class.d.ts +1 -0
- package/dist/types/theme/src/create-theme-vars/calc.d.ts +19 -0
- package/dist/types/theme/src/create-theme-vars/create-theme-vars.d.ts +9 -0
- package/dist/types/theme/src/create-theme-vars/css-var.d.ts +7 -0
- package/dist/types/theme/src/create-theme-vars/index.d.ts +4 -0
- package/dist/types/theme/src/create-theme-vars/theme-tokens.d.ts +10 -0
- package/dist/types/theme/src/create-theme-vars/to-css-var.d.ts +2 -0
- package/dist/types/theme/src/default-theme.d.ts +4 -0
- package/dist/types/theme/src/gui-provider.d.ts +16 -0
- package/dist/types/theme/src/index.d.ts +6 -0
- package/dist/types/theme/src/types.d.ts +56 -0
- package/dist/types/theme/src/use-safe-effect.d.ts +2 -0
- package/dist/types/theme/src/utils.d.ts +1 -0
- package/dist/types/toast/index.d.ts +1 -0
- package/dist/types/toast/src/index.d.ts +1 -0
- package/dist/types/toast/src/toast.d.ts +62 -0
- package/dist/types/toasted-notes/index.d.ts +1 -0
- package/dist/types/toasted-notes/src/Alert.d.ts +8 -0
- package/dist/types/toasted-notes/src/Message.d.ts +26 -0
- package/dist/types/toasted-notes/src/Positions.d.ts +9 -0
- package/dist/types/toasted-notes/src/Toast.d.ts +13 -0
- package/dist/types/toasted-notes/src/ToastManager.d.ts +45 -0
- package/dist/types/toasted-notes/src/index.d.ts +4 -0
- package/dist/types/toasted-notes/src/useTimeout.d.ts +3 -0
- package/dist/types/user-menu/index.d.ts +1 -0
- package/dist/types/user-menu/src/index.d.ts +6 -0
- package/dist/types/user-menu/src/styles.d.ts +1 -0
- package/dist/types/user-menu/src/user-menu.d.ts +21 -0
- package/dist/types/user-menu/stories/announcement.d.ts +6 -0
- package/dist/types/user-menu/stories/user-menu.stories.d.ts +5 -0
- package/dist/types/utils/index.d.ts +1 -0
- package/dist/types/utils/src/assertion.d.ts +4 -0
- package/dist/types/utils/src/children.d.ts +8 -0
- package/dist/types/utils/src/color.d.ts +9 -0
- package/dist/types/utils/src/index.d.ts +10 -0
- package/dist/types/utils/src/object.d.ts +6 -0
- package/dist/types/utils/src/refs.d.ts +5 -0
- package/dist/types/utils/src/slug.d.ts +1 -0
- package/dist/types/utils/src/types.d.ts +13 -0
- package/dist/types/utils/src/walk-object.d.ts +5 -0
- package/dist/types/visually-hidden/index.d.ts +1 -0
- package/dist/types/visually-hidden/src/index.d.ts +32 -0
- package/package.json +2 -2
- package/src/colors.js +145 -145
- package/src/components/accordion.js +89 -89
- package/src/components/alert.js +98 -98
- package/src/components/avatar.js +85 -85
- package/src/components/badge.js +60 -60
- package/src/components/breadcrumb.js +13 -13
- package/src/components/button-group.js +46 -46
- package/src/components/button.js +304 -304
- package/src/components/calendar.js +82 -82
- package/src/components/card.js +54 -54
- package/src/components/checkbox.js +127 -127
- package/src/components/code.js +9 -9
- package/src/components/cookie-consent.js +30 -30
- package/src/components/divider.js +12 -12
- package/src/components/dot.js +84 -84
- package/src/components/dropdown-filter.js +72 -72
- package/src/components/footer.js +42 -42
- package/src/components/forms.js +256 -256
- package/src/components/header.js +35 -35
- package/src/components/icon-button.js +5 -5
- package/src/components/icon.js +9 -9
- package/src/components/kbd.js +9 -9
- package/src/components/link.js +20 -20
- package/src/components/message.js +62 -62
- package/src/components/modal.js +30 -30
- package/src/components/notification.js +56 -56
- package/src/components/pagination.js +69 -69
- package/src/components/radio.js +104 -104
- package/src/components/search-bar.js +45 -45
- package/src/components/side-menu.js +167 -185
- package/src/components/switch.js +119 -119
- package/src/components/tab-menu.js +44 -44
- package/src/components/table.js +13 -13
- package/src/components/tag.js +97 -97
- package/src/components/user-menu.js +23 -23
- package/src/components/zebratable.js +77 -77
- package/src/index.js +272 -272
- package/src/with-opacity.js +6 -6
|
@@ -1,89 +1,89 @@
|
|
|
1
|
-
module.exports = Accordion = (colors) => ({
|
|
2
|
-
'.accordion': {
|
|
3
|
-
'&-header': {
|
|
4
|
-
'@apply flex flex-col text-left': {},
|
|
5
|
-
|
|
6
|
-
'[aria-expanded="true"] &': {
|
|
7
|
-
'@apply bg-hover': {},
|
|
8
|
-
},
|
|
9
|
-
|
|
10
|
-
'&-icon': {
|
|
11
|
-
'@apply ml-auto !text-2xl': {},
|
|
12
|
-
},
|
|
13
|
-
},
|
|
14
|
-
|
|
15
|
-
'&-is-open &-header': {
|
|
16
|
-
'@apply bg-hover': {},
|
|
17
|
-
},
|
|
18
|
-
|
|
19
|
-
'&-toggle': {
|
|
20
|
-
'@apply flex items-center inline-block text-lg leading-lg text-left text-lg mx-md sm:mx-lg my-md': {},
|
|
21
|
-
fontWeight: 'bold',
|
|
22
|
-
//"@apply focus-visible:shadow shadow-lg": {},
|
|
23
|
-
'&:focus-visible': {
|
|
24
|
-
boxShadow: '0 0 0 0.4rem #fff!important',
|
|
25
|
-
outline: '0',
|
|
26
|
-
//"@apply border-4": {},
|
|
27
|
-
},
|
|
28
|
-
'.accordion-title': {
|
|
29
|
-
'@apply mr-md text-base leading-base md:text-lg md:leading-lg': {},
|
|
30
|
-
},
|
|
31
|
-
'.accordion-subtitle': {
|
|
32
|
-
'@apply m-0 mr-md text-sm font-normal': {},
|
|
33
|
-
},
|
|
34
|
-
},
|
|
35
|
-
|
|
36
|
-
'&-body': {
|
|
37
|
-
'@apply h-0 overflow-hidden m-lg': {},
|
|
38
|
-
transitionProperty: 'visibility, height, padding, margin',
|
|
39
|
-
transitionTimingFunction: 'cubic-bezier(0.4, 0, 0.2, 1)',
|
|
40
|
-
transitionDuration: '180ms',
|
|
41
|
-
|
|
42
|
-
'&[aria-hidden="true"], &[data-hidden="true"]': {
|
|
43
|
-
'@apply my-0 invisible': {},
|
|
44
|
-
},
|
|
45
|
-
|
|
46
|
-
'&[aria-hidden="false"], &[data-hidden="false"]': {
|
|
47
|
-
'@apply block h-auto visible': {},
|
|
48
|
-
},
|
|
49
|
-
},
|
|
50
|
-
|
|
51
|
-
'&-solid': {
|
|
52
|
-
'@apply border border-primary': {},
|
|
53
|
-
'.accordion-header': {
|
|
54
|
-
'@apply bg-primary text-white': {},
|
|
55
|
-
|
|
56
|
-
'[aria-expanded="true"] &': {
|
|
57
|
-
'@apply bg-hover': {},
|
|
58
|
-
},
|
|
59
|
-
},
|
|
60
|
-
},
|
|
61
|
-
|
|
62
|
-
'&-is-open': {
|
|
63
|
-
'@apply border border-gray-stroke': {},
|
|
64
|
-
'& .accordion-header': {
|
|
65
|
-
'@apply bg-hover text-white': {},
|
|
66
|
-
},
|
|
67
|
-
},
|
|
68
|
-
|
|
69
|
-
'&-outline': {
|
|
70
|
-
'@apply border border-gray-stroke': {},
|
|
71
|
-
'.accordion-body': {
|
|
72
|
-
'@apply mt-0': {},
|
|
73
|
-
},
|
|
74
|
-
'.accordion-toggle': {
|
|
75
|
-
'&:focus-visible': {
|
|
76
|
-
boxShadow: '0 0 0 0.4rem #4b4b4b!important',
|
|
77
|
-
outline: '0',
|
|
78
|
-
},
|
|
79
|
-
},
|
|
80
|
-
'.accordion-header': {
|
|
81
|
-
'@apply bg-transparent text-body': {},
|
|
82
|
-
|
|
83
|
-
'[aria-expanded="true"] &': {
|
|
84
|
-
'@apply bg-hover': {},
|
|
85
|
-
},
|
|
86
|
-
},
|
|
87
|
-
},
|
|
88
|
-
},
|
|
89
|
-
});
|
|
1
|
+
module.exports = Accordion = (colors) => ({
|
|
2
|
+
'.accordion': {
|
|
3
|
+
'&-header': {
|
|
4
|
+
'@apply flex flex-col text-left': {},
|
|
5
|
+
|
|
6
|
+
'[aria-expanded="true"] &': {
|
|
7
|
+
'@apply bg-hover': {},
|
|
8
|
+
},
|
|
9
|
+
|
|
10
|
+
'&-icon': {
|
|
11
|
+
'@apply ml-auto !text-2xl': {},
|
|
12
|
+
},
|
|
13
|
+
},
|
|
14
|
+
|
|
15
|
+
'&-is-open &-header': {
|
|
16
|
+
'@apply bg-hover': {},
|
|
17
|
+
},
|
|
18
|
+
|
|
19
|
+
'&-toggle': {
|
|
20
|
+
'@apply flex items-center inline-block text-lg leading-lg text-left text-lg mx-md sm:mx-lg my-md': {},
|
|
21
|
+
fontWeight: 'bold',
|
|
22
|
+
//"@apply focus-visible:shadow shadow-lg": {},
|
|
23
|
+
'&:focus-visible': {
|
|
24
|
+
boxShadow: '0 0 0 0.4rem #fff!important',
|
|
25
|
+
outline: '0',
|
|
26
|
+
//"@apply border-4": {},
|
|
27
|
+
},
|
|
28
|
+
'.accordion-title': {
|
|
29
|
+
'@apply mr-md text-base leading-base md:text-lg md:leading-lg': {},
|
|
30
|
+
},
|
|
31
|
+
'.accordion-subtitle': {
|
|
32
|
+
'@apply m-0 mr-md text-sm font-normal': {},
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
|
|
36
|
+
'&-body': {
|
|
37
|
+
'@apply h-0 overflow-hidden m-lg': {},
|
|
38
|
+
transitionProperty: 'visibility, height, padding, margin',
|
|
39
|
+
transitionTimingFunction: 'cubic-bezier(0.4, 0, 0.2, 1)',
|
|
40
|
+
transitionDuration: '180ms',
|
|
41
|
+
|
|
42
|
+
'&[aria-hidden="true"], &[data-hidden="true"]': {
|
|
43
|
+
'@apply my-0 invisible': {},
|
|
44
|
+
},
|
|
45
|
+
|
|
46
|
+
'&[aria-hidden="false"], &[data-hidden="false"]': {
|
|
47
|
+
'@apply block h-auto visible': {},
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
|
|
51
|
+
'&-solid': {
|
|
52
|
+
'@apply border border-primary': {},
|
|
53
|
+
'.accordion-header': {
|
|
54
|
+
'@apply bg-primary text-white': {},
|
|
55
|
+
|
|
56
|
+
'[aria-expanded="true"] &': {
|
|
57
|
+
'@apply bg-hover': {},
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
},
|
|
61
|
+
|
|
62
|
+
'&-is-open': {
|
|
63
|
+
'@apply border border-gray-stroke': {},
|
|
64
|
+
'& .accordion-header': {
|
|
65
|
+
'@apply bg-hover text-white': {},
|
|
66
|
+
},
|
|
67
|
+
},
|
|
68
|
+
|
|
69
|
+
'&-outline': {
|
|
70
|
+
'@apply border border-gray-stroke': {},
|
|
71
|
+
'.accordion-body': {
|
|
72
|
+
'@apply mt-0': {},
|
|
73
|
+
},
|
|
74
|
+
'.accordion-toggle': {
|
|
75
|
+
'&:focus-visible': {
|
|
76
|
+
boxShadow: '0 0 0 0.4rem #4b4b4b!important',
|
|
77
|
+
outline: '0',
|
|
78
|
+
},
|
|
79
|
+
},
|
|
80
|
+
'.accordion-header': {
|
|
81
|
+
'@apply bg-transparent text-body': {},
|
|
82
|
+
|
|
83
|
+
'[aria-expanded="true"] &': {
|
|
84
|
+
'@apply bg-hover': {},
|
|
85
|
+
},
|
|
86
|
+
},
|
|
87
|
+
},
|
|
88
|
+
},
|
|
89
|
+
});
|
package/src/components/alert.js
CHANGED
|
@@ -1,98 +1,98 @@
|
|
|
1
|
-
function alertSubtle(colors) {
|
|
2
|
-
return {
|
|
3
|
-
'.alert-subtle': {
|
|
4
|
-
'@apply border rounded-base': {},
|
|
5
|
-
'@apply text-body': {},
|
|
6
|
-
|
|
7
|
-
...colors.reduce(
|
|
8
|
-
(styles, color) => ({
|
|
9
|
-
...styles,
|
|
10
|
-
[`&[data-color="${color}"]`]: {
|
|
11
|
-
[`@apply bg-${color}-50 border-${color}-500`]: {},
|
|
12
|
-
|
|
13
|
-
[`@apply dark:text-${color}-300 dark:bg-${color}-500`]: {},
|
|
14
|
-
'@apply dark:bg-opacity-15': {},
|
|
15
|
-
'@apply dark:border-opacity-40': {},
|
|
16
|
-
},
|
|
17
|
-
}),
|
|
18
|
-
{}
|
|
19
|
-
),
|
|
20
|
-
},
|
|
21
|
-
};
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
function alertSolid(colors) {
|
|
25
|
-
return {
|
|
26
|
-
'.alert-solid': {
|
|
27
|
-
'@apply border rounded-base': {},
|
|
28
|
-
'@apply text-white': {},
|
|
29
|
-
|
|
30
|
-
...colors.reduce(
|
|
31
|
-
(styles, color) => ({
|
|
32
|
-
...styles,
|
|
33
|
-
[`&[data-color="${color}"]`]: {
|
|
34
|
-
[`@apply bg-${color}-500 border-${color}-700 border-opacity-20`]: {},
|
|
35
|
-
|
|
36
|
-
[`@apply dark:bg-${color}-600 dark:border-${color}-500`]: {},
|
|
37
|
-
'@apply dark:border-opacity-40': {},
|
|
38
|
-
},
|
|
39
|
-
}),
|
|
40
|
-
{}
|
|
41
|
-
),
|
|
42
|
-
},
|
|
43
|
-
};
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
function alertLeftAccent(colors) {
|
|
47
|
-
return {
|
|
48
|
-
'.alert-left-accent': {
|
|
49
|
-
'@apply border-l-2 rounded-none': {},
|
|
50
|
-
'@apply text-body': {},
|
|
51
|
-
|
|
52
|
-
...colors.reduce(
|
|
53
|
-
(styles, color) => ({
|
|
54
|
-
...styles,
|
|
55
|
-
[`&[data-color="${color}"]`]: {
|
|
56
|
-
[`@apply bg-transparent border-${color}-500`]: {},
|
|
57
|
-
|
|
58
|
-
[`@apply dark:text-${color}-300`]: {},
|
|
59
|
-
},
|
|
60
|
-
}),
|
|
61
|
-
{}
|
|
62
|
-
),
|
|
63
|
-
},
|
|
64
|
-
};
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
function alertCloseButton(colors) {
|
|
68
|
-
return {
|
|
69
|
-
'.alert-close-button': {
|
|
70
|
-
'@apply absolute right-4 cursor-base focus-visible:outline-none': {},
|
|
71
|
-
'@apply text-neutral-600 hover:text-neutral-700': {},
|
|
72
|
-
|
|
73
|
-
...colors.reduce(
|
|
74
|
-
(styles, color) => ({
|
|
75
|
-
...styles,
|
|
76
|
-
[`&[data-color="${color}"]`]: {
|
|
77
|
-
[`@apply dark:text-${color}-300 dark:hover:text-${color}-400`]: {},
|
|
78
|
-
},
|
|
79
|
-
}),
|
|
80
|
-
{}
|
|
81
|
-
),
|
|
82
|
-
},
|
|
83
|
-
};
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
module.exports = Alert = (colors) => ({
|
|
87
|
-
'.alert': {
|
|
88
|
-
'@apply w-full flex items-center px-4 py-3 relative overflow-hidden text-sm': {},
|
|
89
|
-
},
|
|
90
|
-
|
|
91
|
-
// variants
|
|
92
|
-
...alertSubtle(colors),
|
|
93
|
-
...alertSolid(colors),
|
|
94
|
-
...alertLeftAccent(colors),
|
|
95
|
-
|
|
96
|
-
// close button
|
|
97
|
-
...alertCloseButton(colors),
|
|
98
|
-
});
|
|
1
|
+
function alertSubtle(colors) {
|
|
2
|
+
return {
|
|
3
|
+
'.alert-subtle': {
|
|
4
|
+
'@apply border rounded-base': {},
|
|
5
|
+
'@apply text-body': {},
|
|
6
|
+
|
|
7
|
+
...colors.reduce(
|
|
8
|
+
(styles, color) => ({
|
|
9
|
+
...styles,
|
|
10
|
+
[`&[data-color="${color}"]`]: {
|
|
11
|
+
[`@apply bg-${color}-50 border-${color}-500`]: {},
|
|
12
|
+
|
|
13
|
+
[`@apply dark:text-${color}-300 dark:bg-${color}-500`]: {},
|
|
14
|
+
'@apply dark:bg-opacity-15': {},
|
|
15
|
+
'@apply dark:border-opacity-40': {},
|
|
16
|
+
},
|
|
17
|
+
}),
|
|
18
|
+
{}
|
|
19
|
+
),
|
|
20
|
+
},
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
function alertSolid(colors) {
|
|
25
|
+
return {
|
|
26
|
+
'.alert-solid': {
|
|
27
|
+
'@apply border rounded-base': {},
|
|
28
|
+
'@apply text-white': {},
|
|
29
|
+
|
|
30
|
+
...colors.reduce(
|
|
31
|
+
(styles, color) => ({
|
|
32
|
+
...styles,
|
|
33
|
+
[`&[data-color="${color}"]`]: {
|
|
34
|
+
[`@apply bg-${color}-500 border-${color}-700 border-opacity-20`]: {},
|
|
35
|
+
|
|
36
|
+
[`@apply dark:bg-${color}-600 dark:border-${color}-500`]: {},
|
|
37
|
+
'@apply dark:border-opacity-40': {},
|
|
38
|
+
},
|
|
39
|
+
}),
|
|
40
|
+
{}
|
|
41
|
+
),
|
|
42
|
+
},
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
function alertLeftAccent(colors) {
|
|
47
|
+
return {
|
|
48
|
+
'.alert-left-accent': {
|
|
49
|
+
'@apply border-l-2 rounded-none': {},
|
|
50
|
+
'@apply text-body': {},
|
|
51
|
+
|
|
52
|
+
...colors.reduce(
|
|
53
|
+
(styles, color) => ({
|
|
54
|
+
...styles,
|
|
55
|
+
[`&[data-color="${color}"]`]: {
|
|
56
|
+
[`@apply bg-transparent border-${color}-500`]: {},
|
|
57
|
+
|
|
58
|
+
[`@apply dark:text-${color}-300`]: {},
|
|
59
|
+
},
|
|
60
|
+
}),
|
|
61
|
+
{}
|
|
62
|
+
),
|
|
63
|
+
},
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
function alertCloseButton(colors) {
|
|
68
|
+
return {
|
|
69
|
+
'.alert-close-button': {
|
|
70
|
+
'@apply absolute right-4 cursor-base focus-visible:outline-none': {},
|
|
71
|
+
'@apply text-neutral-600 hover:text-neutral-700': {},
|
|
72
|
+
|
|
73
|
+
...colors.reduce(
|
|
74
|
+
(styles, color) => ({
|
|
75
|
+
...styles,
|
|
76
|
+
[`&[data-color="${color}"]`]: {
|
|
77
|
+
[`@apply dark:text-${color}-300 dark:hover:text-${color}-400`]: {},
|
|
78
|
+
},
|
|
79
|
+
}),
|
|
80
|
+
{}
|
|
81
|
+
),
|
|
82
|
+
},
|
|
83
|
+
};
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
module.exports = Alert = (colors) => ({
|
|
87
|
+
'.alert': {
|
|
88
|
+
'@apply w-full flex items-center px-4 py-3 relative overflow-hidden text-sm': {},
|
|
89
|
+
},
|
|
90
|
+
|
|
91
|
+
// variants
|
|
92
|
+
...alertSubtle(colors),
|
|
93
|
+
...alertSolid(colors),
|
|
94
|
+
...alertLeftAccent(colors),
|
|
95
|
+
|
|
96
|
+
// close button
|
|
97
|
+
...alertCloseButton(colors),
|
|
98
|
+
});
|
package/src/components/avatar.js
CHANGED
|
@@ -1,85 +1,85 @@
|
|
|
1
|
-
module.exports = Avatar = () => ({
|
|
2
|
-
'.avatar': {
|
|
3
|
-
'@apply relative inline-flex items-center justify-center flex-shrink-0 align-top rounded-full': {},
|
|
4
|
-
'@apply bg-neutral-300 text-neutral-800': {},
|
|
5
|
-
// dark colors
|
|
6
|
-
'@apply dark:bg-neutral-600 dark:text-neutral-100': {},
|
|
7
|
-
|
|
8
|
-
'&-2xs': {
|
|
9
|
-
'@apply w-4 h-4': {},
|
|
10
|
-
},
|
|
11
|
-
|
|
12
|
-
'&-xs': {
|
|
13
|
-
'@apply w-5 h-5': {},
|
|
14
|
-
},
|
|
15
|
-
|
|
16
|
-
'&-sm': {
|
|
17
|
-
'@apply w-6 h-6': {},
|
|
18
|
-
},
|
|
19
|
-
|
|
20
|
-
'&-md': {
|
|
21
|
-
'@apply w-7 h-7': {},
|
|
22
|
-
},
|
|
23
|
-
|
|
24
|
-
'&-lg': {
|
|
25
|
-
'@apply w-8 h-8': {},
|
|
26
|
-
},
|
|
27
|
-
|
|
28
|
-
'&-xl': {
|
|
29
|
-
'@apply w-10 h-10': {},
|
|
30
|
-
},
|
|
31
|
-
|
|
32
|
-
'&-2xl': {
|
|
33
|
-
'@apply w-12 h-12': {},
|
|
34
|
-
},
|
|
35
|
-
|
|
36
|
-
'&-3xl': {
|
|
37
|
-
'@apply w-16 h-16': {},
|
|
38
|
-
},
|
|
39
|
-
},
|
|
40
|
-
|
|
41
|
-
'.avatar-bordered': {
|
|
42
|
-
'@apply border-2 border-white': {},
|
|
43
|
-
'@apply dark:border-neutral-800': {},
|
|
44
|
-
},
|
|
45
|
-
|
|
46
|
-
'.avatar-name': {
|
|
47
|
-
'@apply font-medium text-center uppercase': {},
|
|
48
|
-
|
|
49
|
-
'&-2xs': {
|
|
50
|
-
'@apply w-4 h-4': {},
|
|
51
|
-
},
|
|
52
|
-
|
|
53
|
-
'&-xs': {
|
|
54
|
-
'@apply w-5 h-5': {},
|
|
55
|
-
},
|
|
56
|
-
|
|
57
|
-
'&-sm': {
|
|
58
|
-
'@apply w-6 h-6': {},
|
|
59
|
-
},
|
|
60
|
-
|
|
61
|
-
'&-md': {
|
|
62
|
-
'@apply w-7 h-7': {},
|
|
63
|
-
},
|
|
64
|
-
|
|
65
|
-
'&-lg': {
|
|
66
|
-
'@apply w-8 h-8': {},
|
|
67
|
-
},
|
|
68
|
-
|
|
69
|
-
'&-xl': {
|
|
70
|
-
'@apply w-10 h-10': {},
|
|
71
|
-
},
|
|
72
|
-
|
|
73
|
-
'&-2xl': {
|
|
74
|
-
'@apply w-12 h-12': {},
|
|
75
|
-
},
|
|
76
|
-
|
|
77
|
-
'&-3xl': {
|
|
78
|
-
'@apply w-16 h-16': {},
|
|
79
|
-
},
|
|
80
|
-
},
|
|
81
|
-
|
|
82
|
-
'.avatar-group': {
|
|
83
|
-
'@apply flex items-center justify-end flex-row-reverse': {},
|
|
84
|
-
},
|
|
85
|
-
});
|
|
1
|
+
module.exports = Avatar = () => ({
|
|
2
|
+
'.avatar': {
|
|
3
|
+
'@apply relative inline-flex items-center justify-center flex-shrink-0 align-top rounded-full': {},
|
|
4
|
+
'@apply bg-neutral-300 text-neutral-800': {},
|
|
5
|
+
// dark colors
|
|
6
|
+
'@apply dark:bg-neutral-600 dark:text-neutral-100': {},
|
|
7
|
+
|
|
8
|
+
'&-2xs': {
|
|
9
|
+
'@apply w-4 h-4': {},
|
|
10
|
+
},
|
|
11
|
+
|
|
12
|
+
'&-xs': {
|
|
13
|
+
'@apply w-5 h-5': {},
|
|
14
|
+
},
|
|
15
|
+
|
|
16
|
+
'&-sm': {
|
|
17
|
+
'@apply w-6 h-6': {},
|
|
18
|
+
},
|
|
19
|
+
|
|
20
|
+
'&-md': {
|
|
21
|
+
'@apply w-7 h-7': {},
|
|
22
|
+
},
|
|
23
|
+
|
|
24
|
+
'&-lg': {
|
|
25
|
+
'@apply w-8 h-8': {},
|
|
26
|
+
},
|
|
27
|
+
|
|
28
|
+
'&-xl': {
|
|
29
|
+
'@apply w-10 h-10': {},
|
|
30
|
+
},
|
|
31
|
+
|
|
32
|
+
'&-2xl': {
|
|
33
|
+
'@apply w-12 h-12': {},
|
|
34
|
+
},
|
|
35
|
+
|
|
36
|
+
'&-3xl': {
|
|
37
|
+
'@apply w-16 h-16': {},
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
|
|
41
|
+
'.avatar-bordered': {
|
|
42
|
+
'@apply border-2 border-white': {},
|
|
43
|
+
'@apply dark:border-neutral-800': {},
|
|
44
|
+
},
|
|
45
|
+
|
|
46
|
+
'.avatar-name': {
|
|
47
|
+
'@apply font-medium text-center uppercase': {},
|
|
48
|
+
|
|
49
|
+
'&-2xs': {
|
|
50
|
+
'@apply w-4 h-4': {},
|
|
51
|
+
},
|
|
52
|
+
|
|
53
|
+
'&-xs': {
|
|
54
|
+
'@apply w-5 h-5': {},
|
|
55
|
+
},
|
|
56
|
+
|
|
57
|
+
'&-sm': {
|
|
58
|
+
'@apply w-6 h-6': {},
|
|
59
|
+
},
|
|
60
|
+
|
|
61
|
+
'&-md': {
|
|
62
|
+
'@apply w-7 h-7': {},
|
|
63
|
+
},
|
|
64
|
+
|
|
65
|
+
'&-lg': {
|
|
66
|
+
'@apply w-8 h-8': {},
|
|
67
|
+
},
|
|
68
|
+
|
|
69
|
+
'&-xl': {
|
|
70
|
+
'@apply w-10 h-10': {},
|
|
71
|
+
},
|
|
72
|
+
|
|
73
|
+
'&-2xl': {
|
|
74
|
+
'@apply w-12 h-12': {},
|
|
75
|
+
},
|
|
76
|
+
|
|
77
|
+
'&-3xl': {
|
|
78
|
+
'@apply w-16 h-16': {},
|
|
79
|
+
},
|
|
80
|
+
},
|
|
81
|
+
|
|
82
|
+
'.avatar-group': {
|
|
83
|
+
'@apply flex items-center justify-end flex-row-reverse': {},
|
|
84
|
+
},
|
|
85
|
+
});
|
package/src/components/badge.js
CHANGED
|
@@ -1,60 +1,60 @@
|
|
|
1
|
-
module.exports = Badge = (colors) => ({
|
|
2
|
-
'.badge': {
|
|
3
|
-
'@apply inline-block text-xs font-medium leading-4 text-center whitespace-nowrap': {},
|
|
4
|
-
|
|
5
|
-
'&-light': {
|
|
6
|
-
'@apply text-body bg-neutral-200 border border-transparent': {},
|
|
7
|
-
'@apply dark:text-neutral-100 dark:bg-neutral-700': {},
|
|
8
|
-
|
|
9
|
-
...colors.reduce(
|
|
10
|
-
(styles, color) => ({
|
|
11
|
-
...styles,
|
|
12
|
-
[`&[data-color="${color}"]`]: {
|
|
13
|
-
[`@apply text-${color}-800 bg-${color}-100`]: {},
|
|
14
|
-
[`@apply dark:text-${color}-400 dark:bg-${color}-500`]: {},
|
|
15
|
-
'@apply dark:bg-opacity-15': {},
|
|
16
|
-
},
|
|
17
|
-
}),
|
|
18
|
-
{}
|
|
19
|
-
),
|
|
20
|
-
},
|
|
21
|
-
|
|
22
|
-
'&-solid': {
|
|
23
|
-
'@apply text-white bg-neutral-500 border border-transparent': {},
|
|
24
|
-
'@apply dark:border-neutral-600 dark:text-neutral-100 dark:bg-neutral-700': {},
|
|
25
|
-
...colors.reduce(
|
|
26
|
-
(styles, color) => ({
|
|
27
|
-
...styles,
|
|
28
|
-
[`&[data-color="${color}"]`]: {
|
|
29
|
-
[`@apply bg-${color}-500`]: {},
|
|
30
|
-
[`@apply dark:text-${color}-400 dark:border-${color}-500 dark:bg-${color}-500`]: {},
|
|
31
|
-
'@apply dark:bg-opacity-15': {},
|
|
32
|
-
'@apply dark:border-opacity-40': {},
|
|
33
|
-
},
|
|
34
|
-
}),
|
|
35
|
-
{}
|
|
36
|
-
),
|
|
37
|
-
},
|
|
38
|
-
|
|
39
|
-
'&-sm': {
|
|
40
|
-
minWidth: '14px',
|
|
41
|
-
height: '14px',
|
|
42
|
-
padding: 0,
|
|
43
|
-
lineHeight: '12px',
|
|
44
|
-
borderRadius: '2em',
|
|
45
|
-
},
|
|
46
|
-
|
|
47
|
-
'&-md': {
|
|
48
|
-
'@apply px-1.5 py-0': {},
|
|
49
|
-
minWidth: '20px',
|
|
50
|
-
height: '20px',
|
|
51
|
-
lineHeight: '18px',
|
|
52
|
-
borderRadius: '2em',
|
|
53
|
-
},
|
|
54
|
-
|
|
55
|
-
'&-shadow': {
|
|
56
|
-
'@apply ring-1 ring-white': {},
|
|
57
|
-
'@apply dark:ring-black': {},
|
|
58
|
-
},
|
|
59
|
-
},
|
|
60
|
-
});
|
|
1
|
+
module.exports = Badge = (colors) => ({
|
|
2
|
+
'.badge': {
|
|
3
|
+
'@apply inline-block text-xs font-medium leading-4 text-center whitespace-nowrap': {},
|
|
4
|
+
|
|
5
|
+
'&-light': {
|
|
6
|
+
'@apply text-body bg-neutral-200 border border-transparent': {},
|
|
7
|
+
'@apply dark:text-neutral-100 dark:bg-neutral-700': {},
|
|
8
|
+
|
|
9
|
+
...colors.reduce(
|
|
10
|
+
(styles, color) => ({
|
|
11
|
+
...styles,
|
|
12
|
+
[`&[data-color="${color}"]`]: {
|
|
13
|
+
[`@apply text-${color}-800 bg-${color}-100`]: {},
|
|
14
|
+
[`@apply dark:text-${color}-400 dark:bg-${color}-500`]: {},
|
|
15
|
+
'@apply dark:bg-opacity-15': {},
|
|
16
|
+
},
|
|
17
|
+
}),
|
|
18
|
+
{}
|
|
19
|
+
),
|
|
20
|
+
},
|
|
21
|
+
|
|
22
|
+
'&-solid': {
|
|
23
|
+
'@apply text-white bg-neutral-500 border border-transparent': {},
|
|
24
|
+
'@apply dark:border-neutral-600 dark:text-neutral-100 dark:bg-neutral-700': {},
|
|
25
|
+
...colors.reduce(
|
|
26
|
+
(styles, color) => ({
|
|
27
|
+
...styles,
|
|
28
|
+
[`&[data-color="${color}"]`]: {
|
|
29
|
+
[`@apply bg-${color}-500`]: {},
|
|
30
|
+
[`@apply dark:text-${color}-400 dark:border-${color}-500 dark:bg-${color}-500`]: {},
|
|
31
|
+
'@apply dark:bg-opacity-15': {},
|
|
32
|
+
'@apply dark:border-opacity-40': {},
|
|
33
|
+
},
|
|
34
|
+
}),
|
|
35
|
+
{}
|
|
36
|
+
),
|
|
37
|
+
},
|
|
38
|
+
|
|
39
|
+
'&-sm': {
|
|
40
|
+
minWidth: '14px',
|
|
41
|
+
height: '14px',
|
|
42
|
+
padding: 0,
|
|
43
|
+
lineHeight: '12px',
|
|
44
|
+
borderRadius: '2em',
|
|
45
|
+
},
|
|
46
|
+
|
|
47
|
+
'&-md': {
|
|
48
|
+
'@apply px-1.5 py-0': {},
|
|
49
|
+
minWidth: '20px',
|
|
50
|
+
height: '20px',
|
|
51
|
+
lineHeight: '18px',
|
|
52
|
+
borderRadius: '2em',
|
|
53
|
+
},
|
|
54
|
+
|
|
55
|
+
'&-shadow': {
|
|
56
|
+
'@apply ring-1 ring-white': {},
|
|
57
|
+
'@apply dark:ring-black': {},
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
});
|