@anker-in/headless-ui 0.0.25 → 0.0.27-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CONTRIBUTING.md +88 -27
- package/dist/cjs/biz-components/BrandEquity/BrandEquity.d.ts +19 -0
- package/dist/cjs/biz-components/BrandEquity/BrandEquity.js +2 -0
- package/dist/cjs/biz-components/BrandEquity/BrandEquity.js.map +7 -0
- package/dist/cjs/biz-components/BrandEquity/index.d.ts +1 -0
- package/dist/cjs/biz-components/BrandEquity/index.js +2 -0
- package/dist/cjs/biz-components/BrandEquity/index.js.map +7 -0
- package/dist/cjs/biz-components/Category/index.d.ts +16 -0
- package/dist/cjs/biz-components/Category/index.js +2 -0
- package/dist/cjs/biz-components/Category/index.js.map +7 -0
- package/dist/cjs/biz-components/Evaluate/index.d.ts +19 -0
- package/dist/cjs/biz-components/Evaluate/index.js +2 -0
- package/dist/cjs/biz-components/Evaluate/index.js.map +7 -0
- package/dist/cjs/biz-components/HeroBanner/HeroBanner.d.ts +7 -0
- package/dist/cjs/biz-components/HeroBanner/HeroBanner.js +2 -0
- package/dist/cjs/biz-components/HeroBanner/HeroBanner.js.map +7 -0
- package/dist/cjs/biz-components/HeroBanner/index.d.ts +1 -0
- package/dist/cjs/biz-components/HeroBanner/index.js +2 -0
- package/dist/cjs/biz-components/HeroBanner/index.js.map +7 -0
- package/dist/cjs/biz-components/HeroBanner/types.d.ts +26 -0
- package/dist/cjs/biz-components/HeroBanner/types.js +2 -0
- package/dist/cjs/biz-components/HeroBanner/types.js.map +7 -0
- package/dist/cjs/biz-components/Marquee/index.d.ts +23 -0
- package/dist/cjs/biz-components/Marquee/index.js +2 -0
- package/dist/cjs/biz-components/Marquee/index.js.map +7 -0
- package/dist/cjs/biz-components/MemberEquity/index.d.ts +6 -0
- package/dist/cjs/biz-components/MemberEquity/index.js +40 -0
- package/dist/cjs/biz-components/MemberEquity/index.js.map +7 -0
- package/dist/cjs/biz-components/MemberEquity/types.d.ts +25 -0
- package/dist/cjs/biz-components/MemberEquity/types.js +2 -0
- package/dist/cjs/biz-components/MemberEquity/types.js.map +7 -0
- package/dist/cjs/biz-components/Shelf/Shelf.d.ts +6 -0
- package/dist/cjs/biz-components/Shelf/Shelf.js +2 -0
- package/dist/cjs/biz-components/Shelf/Shelf.js.map +7 -0
- package/dist/cjs/biz-components/Shelf/index.d.ts +1 -0
- package/dist/cjs/biz-components/Shelf/index.js +2 -0
- package/dist/cjs/biz-components/Shelf/index.js.map +7 -0
- package/dist/cjs/biz-components/Shelf/types.d.ts +6 -0
- package/dist/cjs/biz-components/Shelf/types.js +2 -0
- package/dist/cjs/biz-components/Shelf/types.js.map +7 -0
- package/dist/cjs/biz-components/ShelfDisplay/index.d.ts +38 -0
- package/dist/cjs/biz-components/ShelfDisplay/index.js +10 -0
- package/dist/cjs/biz-components/ShelfDisplay/index.js.map +7 -0
- package/dist/cjs/biz-components/Slogan/index.d.ts +7 -0
- package/dist/cjs/biz-components/Slogan/index.js +2 -0
- package/dist/cjs/biz-components/Slogan/index.js.map +7 -0
- package/dist/cjs/biz-components/Slogan/types.d.ts +24 -0
- package/dist/cjs/biz-components/Slogan/types.js +2 -0
- package/dist/cjs/biz-components/Slogan/types.js.map +7 -0
- package/dist/cjs/biz-components/index.d.ts +9 -0
- package/dist/cjs/biz-components/index.js +2 -0
- package/dist/cjs/biz-components/index.js.map +7 -0
- package/dist/cjs/components/alert.d.ts +17 -0
- package/dist/cjs/components/alert.js +2 -0
- package/dist/cjs/components/alert.js.map +7 -0
- package/dist/cjs/components/avatar.d.ts +26 -0
- package/dist/cjs/components/avatar.js +2 -0
- package/dist/cjs/components/avatar.js.map +7 -0
- package/dist/cjs/components/badge.d.ts +2 -2
- package/dist/cjs/components/badge.js +1 -1
- package/dist/cjs/components/badge.js.map +3 -3
- package/dist/cjs/components/button.d.ts +2 -1
- package/dist/cjs/components/button.js +1 -1
- package/dist/cjs/components/button.js.map +3 -3
- package/dist/cjs/components/card.d.ts +8 -0
- package/dist/cjs/components/card.js +2 -0
- package/dist/cjs/components/card.js.map +7 -0
- package/dist/cjs/components/carousel.d.ts +28 -0
- package/dist/cjs/components/carousel.js +2 -0
- package/dist/cjs/components/carousel.js.map +7 -0
- package/dist/cjs/components/checkbox.js +1 -1
- package/dist/cjs/components/checkbox.js.map +2 -2
- package/dist/cjs/components/color.d.ts +13 -0
- package/dist/cjs/components/color.js +2 -0
- package/dist/cjs/components/color.js.map +7 -0
- package/dist/cjs/components/container.d.ts +13 -0
- package/dist/cjs/components/container.js +2 -0
- package/dist/cjs/components/container.js.map +7 -0
- package/dist/cjs/components/dialog.d.ts +2 -2
- package/dist/cjs/components/dialog.js +1 -1
- package/dist/cjs/components/dialog.js.map +2 -2
- package/dist/cjs/components/drawer.d.ts +13 -0
- package/dist/cjs/components/drawer.js +2 -0
- package/dist/cjs/components/drawer.js.map +7 -0
- package/dist/cjs/components/drop-down.d.ts +27 -0
- package/dist/cjs/components/drop-down.js +2 -0
- package/dist/cjs/components/drop-down.js.map +7 -0
- package/dist/cjs/components/gird.d.ts +17 -0
- package/dist/cjs/components/gird.js +2 -0
- package/dist/cjs/components/gird.js.map +7 -0
- package/dist/cjs/components/heading.d.ts +3 -3
- package/dist/cjs/components/heading.js +1 -1
- package/dist/cjs/components/heading.js.map +3 -3
- package/dist/cjs/components/index.d.ts +12 -1
- package/dist/cjs/components/index.js +1 -1
- package/dist/cjs/components/index.js.map +2 -2
- package/dist/cjs/components/input-number.d.ts +78 -0
- package/dist/cjs/components/input-number.js +2 -0
- package/dist/cjs/components/input-number.js.map +7 -0
- package/dist/cjs/components/input.js +1 -1
- package/dist/cjs/components/input.js.map +2 -2
- package/dist/cjs/components/link.d.ts +47 -0
- package/dist/cjs/components/link.js +2 -0
- package/dist/cjs/components/link.js.map +7 -0
- package/dist/cjs/components/picture.d.ts +1 -1
- package/dist/cjs/components/picture.js +1 -1
- package/dist/cjs/components/picture.js.map +3 -3
- package/dist/cjs/components/popover.js +1 -1
- package/dist/cjs/components/popover.js.map +2 -2
- package/dist/cjs/components/radio.js +1 -1
- package/dist/cjs/components/radio.js.map +2 -2
- package/dist/cjs/components/skeleton.js +4 -4
- package/dist/cjs/components/skeleton.js.map +1 -1
- package/dist/cjs/components/tabs.d.ts +9 -0
- package/dist/cjs/components/tabs.js +2 -0
- package/dist/cjs/components/tabs.js.map +7 -0
- package/dist/cjs/components/text.d.ts +3 -3
- package/dist/cjs/components/text.js +1 -1
- package/dist/cjs/components/text.js.map +3 -3
- package/dist/cjs/components/theme.d.ts +2 -3
- package/dist/cjs/components/theme.js +1 -1
- package/dist/cjs/components/theme.js.map +2 -2
- package/dist/cjs/helpers/constants.d.ts +0 -2
- package/dist/cjs/helpers/constants.js +1 -1
- package/dist/cjs/helpers/constants.js.map +4 -4
- package/dist/cjs/helpers/utils.js +1 -1
- package/dist/cjs/helpers/utils.js.map +3 -3
- package/dist/cjs/icons/spinner.d.ts +1 -1
- package/dist/cjs/icons/spinner.js +1 -1
- package/dist/cjs/icons/spinner.js.map +2 -2
- package/dist/cjs/shared/Styles.d.ts +33 -0
- package/dist/cjs/shared/Styles.js +2 -0
- package/dist/cjs/shared/Styles.js.map +7 -0
- package/dist/cjs/stories/HeroBanner.stories.d.ts +23 -0
- package/dist/cjs/stories/HeroBanner.stories.js +10 -0
- package/dist/cjs/stories/HeroBanner.stories.js.map +7 -0
- package/dist/cjs/stories/MemberEquity.stories.d.ts +9 -0
- package/dist/cjs/stories/MemberEquity.stories.js +31 -0
- package/dist/cjs/stories/MemberEquity.stories.js.map +7 -0
- package/dist/cjs/stories/alert.stories.d.ts +27 -0
- package/dist/cjs/stories/alert.stories.js +2 -0
- package/dist/cjs/stories/alert.stories.js.map +7 -0
- package/dist/cjs/stories/avatar.stories.d.ts +40 -0
- package/dist/cjs/stories/avatar.stories.js +2 -0
- package/dist/cjs/stories/avatar.stories.js.map +7 -0
- package/dist/cjs/stories/badge.stories.d.ts +2 -12
- package/dist/cjs/stories/badge.stories.js +1 -1
- package/dist/cjs/stories/badge.stories.js.map +2 -2
- package/dist/cjs/stories/brandEquity.stories.d.ts +16 -0
- package/dist/cjs/stories/brandEquity.stories.js +2 -0
- package/dist/cjs/stories/brandEquity.stories.js.map +7 -0
- package/dist/cjs/stories/button.stories.d.ts +14 -0
- package/dist/cjs/stories/button.stories.js +1 -1
- package/dist/cjs/stories/button.stories.js.map +3 -3
- package/dist/cjs/stories/card.stories.d.ts +27 -0
- package/dist/cjs/stories/card.stories.js +2 -0
- package/dist/cjs/stories/card.stories.js.map +7 -0
- package/dist/cjs/stories/carousel.stories.d.ts +62 -0
- package/dist/cjs/stories/carousel.stories.js +2 -0
- package/dist/cjs/stories/carousel.stories.js.map +7 -0
- package/dist/cjs/stories/category.stories.d.ts +13 -0
- package/dist/cjs/stories/category.stories.js +2 -0
- package/dist/cjs/stories/category.stories.js.map +7 -0
- package/dist/cjs/stories/checkbox.stories.d.ts +2 -2
- package/dist/cjs/stories/checkbox.stories.js +1 -1
- package/dist/cjs/stories/checkbox.stories.js.map +2 -2
- package/dist/cjs/stories/container.stories.d.ts +23 -0
- package/dist/cjs/stories/container.stories.js +15 -0
- package/dist/cjs/stories/container.stories.js.map +7 -0
- package/dist/cjs/stories/dialog.stories.js +1 -1
- package/dist/cjs/stories/dialog.stories.js.map +2 -2
- package/dist/cjs/stories/drawer.stories.d.ts +20 -0
- package/dist/cjs/stories/drawer.stories.js +2 -0
- package/dist/cjs/stories/drawer.stories.js.map +7 -0
- package/dist/cjs/stories/drop-down.stories.d.ts +16 -0
- package/dist/cjs/stories/drop-down.stories.js +2 -0
- package/dist/cjs/stories/drop-down.stories.js.map +7 -0
- package/dist/cjs/stories/evaluate.stories.d.ts +13 -0
- package/dist/cjs/stories/evaluate.stories.js +2 -0
- package/dist/cjs/stories/evaluate.stories.js.map +7 -0
- package/dist/cjs/stories/grid.stories.d.ts +22 -0
- package/dist/cjs/stories/grid.stories.js +13 -0
- package/dist/cjs/stories/grid.stories.js.map +7 -0
- package/dist/cjs/stories/heading.stories.d.ts +4 -4
- package/dist/cjs/stories/heading.stories.js +1 -1
- package/dist/cjs/stories/heading.stories.js.map +2 -2
- package/dist/cjs/stories/input-number.stories.d.ts +39 -0
- package/dist/cjs/stories/input-number.stories.js +2 -0
- package/dist/cjs/stories/input-number.stories.js.map +7 -0
- package/dist/cjs/stories/input.stories.js +1 -1
- package/dist/cjs/stories/input.stories.js.map +2 -2
- package/dist/cjs/stories/link.stories.d.ts +82 -0
- package/dist/cjs/stories/link.stories.js +2 -0
- package/dist/cjs/stories/link.stories.js.map +7 -0
- package/dist/cjs/stories/marquee.stories.d.ts +49 -0
- package/dist/cjs/stories/marquee.stories.js +2 -0
- package/dist/cjs/stories/marquee.stories.js.map +7 -0
- package/dist/cjs/stories/picture.stories.d.ts +1 -1
- package/dist/cjs/stories/picture.stories.js +2 -2
- package/dist/cjs/stories/picture.stories.js.map +2 -2
- package/dist/cjs/stories/popover.stories.d.ts +1 -1
- package/dist/cjs/stories/popover.stories.js +1 -1
- package/dist/cjs/stories/popover.stories.js.map +2 -2
- package/dist/cjs/stories/radio.stories.js +1 -1
- package/dist/cjs/stories/radio.stories.js.map +2 -2
- package/dist/cjs/stories/shelf.stories.d.ts +15 -0
- package/dist/cjs/stories/shelf.stories.js +2 -0
- package/dist/cjs/stories/shelf.stories.js.map +7 -0
- package/dist/cjs/stories/shelfDisplay.stories.d.ts +13 -0
- package/dist/cjs/stories/shelfDisplay.stories.js +2 -0
- package/dist/cjs/stories/shelfDisplay.stories.js.map +7 -0
- package/dist/cjs/stories/skeleton.stories.js +1 -1
- package/dist/cjs/stories/skeleton.stories.js.map +2 -2
- package/dist/cjs/stories/slogan.stories.d.ts +21 -0
- package/dist/cjs/stories/slogan.stories.js +26 -0
- package/dist/cjs/stories/slogan.stories.js.map +7 -0
- package/dist/cjs/stories/tabs.stories.d.ts +360 -0
- package/dist/cjs/stories/tabs.stories.js +2 -0
- package/dist/cjs/stories/tabs.stories.js.map +7 -0
- package/dist/cjs/stories/text.stories.d.ts +5 -5
- package/dist/cjs/stories/text.stories.js +1 -1
- package/dist/cjs/stories/text.stories.js.map +3 -3
- package/dist/cjs/types/index.d.ts +0 -0
- package/dist/cjs/types/index.js +2 -0
- package/dist/cjs/types/index.js.map +7 -0
- package/dist/cjs/types/props.d.ts +5 -0
- package/dist/cjs/types/props.js +2 -0
- package/dist/cjs/types/props.js.map +7 -0
- package/dist/esm/biz-components/BrandEquity/BrandEquity.d.ts +19 -0
- package/dist/esm/biz-components/BrandEquity/BrandEquity.js +2 -0
- package/dist/esm/biz-components/BrandEquity/BrandEquity.js.map +7 -0
- package/dist/esm/biz-components/BrandEquity/index.d.ts +1 -0
- package/dist/esm/biz-components/BrandEquity/index.js +2 -0
- package/dist/esm/biz-components/BrandEquity/index.js.map +7 -0
- package/dist/esm/biz-components/Category/index.d.ts +16 -0
- package/dist/esm/biz-components/Category/index.js +2 -0
- package/dist/esm/biz-components/Category/index.js.map +7 -0
- package/dist/esm/biz-components/Evaluate/index.d.ts +19 -0
- package/dist/esm/biz-components/Evaluate/index.js +2 -0
- package/dist/esm/biz-components/Evaluate/index.js.map +7 -0
- package/dist/esm/biz-components/HeroBanner/HeroBanner.d.ts +7 -0
- package/dist/esm/biz-components/HeroBanner/HeroBanner.js +2 -0
- package/dist/esm/biz-components/HeroBanner/HeroBanner.js.map +7 -0
- package/dist/esm/biz-components/HeroBanner/index.d.ts +1 -0
- package/dist/esm/biz-components/HeroBanner/index.js +2 -0
- package/dist/esm/biz-components/HeroBanner/index.js.map +7 -0
- package/dist/esm/biz-components/HeroBanner/types.d.ts +26 -0
- package/dist/esm/biz-components/HeroBanner/types.js +1 -0
- package/dist/esm/biz-components/HeroBanner/types.js.map +7 -0
- package/dist/esm/biz-components/Marquee/index.d.ts +23 -0
- package/dist/esm/biz-components/Marquee/index.js +2 -0
- package/dist/esm/biz-components/Marquee/index.js.map +7 -0
- package/dist/esm/biz-components/MemberEquity/index.d.ts +6 -0
- package/dist/esm/biz-components/MemberEquity/index.js +40 -0
- package/dist/esm/biz-components/MemberEquity/index.js.map +7 -0
- package/dist/esm/biz-components/MemberEquity/types.d.ts +25 -0
- package/dist/esm/biz-components/MemberEquity/types.js +1 -0
- package/dist/esm/biz-components/MemberEquity/types.js.map +7 -0
- package/dist/esm/biz-components/Shelf/Shelf.d.ts +6 -0
- package/dist/esm/biz-components/Shelf/Shelf.js +2 -0
- package/dist/esm/biz-components/Shelf/Shelf.js.map +7 -0
- package/dist/esm/biz-components/Shelf/index.d.ts +1 -0
- package/dist/esm/biz-components/Shelf/index.js +2 -0
- package/dist/esm/biz-components/Shelf/index.js.map +7 -0
- package/dist/esm/biz-components/Shelf/types.d.ts +6 -0
- package/dist/esm/biz-components/Shelf/types.js +1 -0
- package/dist/esm/biz-components/Shelf/types.js.map +7 -0
- package/dist/esm/biz-components/ShelfDisplay/index.d.ts +38 -0
- package/dist/esm/biz-components/ShelfDisplay/index.js +10 -0
- package/dist/esm/biz-components/ShelfDisplay/index.js.map +7 -0
- package/dist/esm/biz-components/Slogan/index.d.ts +7 -0
- package/dist/esm/biz-components/Slogan/index.js +2 -0
- package/dist/esm/biz-components/Slogan/index.js.map +7 -0
- package/dist/esm/biz-components/Slogan/types.d.ts +24 -0
- package/dist/esm/biz-components/Slogan/types.js +1 -0
- package/dist/esm/biz-components/Slogan/types.js.map +7 -0
- package/dist/esm/biz-components/index.d.ts +9 -0
- package/dist/esm/biz-components/index.js +2 -0
- package/dist/esm/biz-components/index.js.map +7 -0
- package/dist/esm/components/alert.d.ts +17 -0
- package/dist/esm/components/alert.js +2 -0
- package/dist/esm/components/alert.js.map +7 -0
- package/dist/esm/components/avatar.d.ts +26 -0
- package/dist/esm/components/avatar.js +2 -0
- package/dist/esm/components/avatar.js.map +7 -0
- package/dist/esm/components/badge.d.ts +2 -2
- package/dist/esm/components/badge.js +1 -1
- package/dist/esm/components/badge.js.map +3 -3
- package/dist/esm/components/button.d.ts +2 -1
- package/dist/esm/components/button.js +1 -1
- package/dist/esm/components/button.js.map +3 -3
- package/dist/esm/components/card.d.ts +8 -0
- package/dist/esm/components/card.js +2 -0
- package/dist/esm/components/card.js.map +7 -0
- package/dist/esm/components/carousel.d.ts +28 -0
- package/dist/esm/components/carousel.js +2 -0
- package/dist/esm/components/carousel.js.map +7 -0
- package/dist/esm/components/checkbox.js +1 -1
- package/dist/esm/components/checkbox.js.map +2 -2
- package/dist/esm/components/color.d.ts +13 -0
- package/dist/esm/components/color.js +2 -0
- package/dist/esm/components/color.js.map +7 -0
- package/dist/esm/components/container.d.ts +13 -0
- package/dist/esm/components/container.js +2 -0
- package/dist/esm/components/container.js.map +7 -0
- package/dist/esm/components/dialog.d.ts +2 -2
- package/dist/esm/components/dialog.js +1 -1
- package/dist/esm/components/dialog.js.map +2 -2
- package/dist/esm/components/drawer.d.ts +13 -0
- package/dist/esm/components/drawer.js +2 -0
- package/dist/esm/components/drawer.js.map +7 -0
- package/dist/esm/components/drop-down.d.ts +27 -0
- package/dist/esm/components/drop-down.js +2 -0
- package/dist/esm/components/drop-down.js.map +7 -0
- package/dist/esm/components/gird.d.ts +17 -0
- package/dist/esm/components/gird.js +2 -0
- package/dist/esm/components/gird.js.map +7 -0
- package/dist/esm/components/heading.d.ts +3 -3
- package/dist/esm/components/heading.js +1 -1
- package/dist/esm/components/heading.js.map +3 -3
- package/dist/esm/components/index.d.ts +12 -1
- package/dist/esm/components/index.js +1 -1
- package/dist/esm/components/index.js.map +2 -2
- package/dist/esm/components/input-number.d.ts +78 -0
- package/dist/esm/components/input-number.js +2 -0
- package/dist/esm/components/input-number.js.map +7 -0
- package/dist/esm/components/input.js +1 -1
- package/dist/esm/components/input.js.map +2 -2
- package/dist/esm/components/link.d.ts +47 -0
- package/dist/esm/components/link.js +2 -0
- package/dist/esm/components/link.js.map +7 -0
- package/dist/esm/components/picture.d.ts +1 -1
- package/dist/esm/components/picture.js +1 -1
- package/dist/esm/components/picture.js.map +3 -3
- package/dist/esm/components/popover.js +1 -1
- package/dist/esm/components/popover.js.map +2 -2
- package/dist/esm/components/radio.js +1 -1
- package/dist/esm/components/radio.js.map +2 -2
- package/dist/esm/components/skeleton.js +4 -4
- package/dist/esm/components/skeleton.js.map +1 -1
- package/dist/esm/components/tabs.d.ts +9 -0
- package/dist/esm/components/tabs.js +2 -0
- package/dist/esm/components/tabs.js.map +7 -0
- package/dist/esm/components/text.d.ts +3 -3
- package/dist/esm/components/text.js +1 -1
- package/dist/esm/components/text.js.map +3 -3
- package/dist/esm/components/theme.d.ts +2 -3
- package/dist/esm/components/theme.js +1 -1
- package/dist/esm/components/theme.js.map +2 -2
- package/dist/esm/helpers/constants.d.ts +0 -2
- package/dist/esm/helpers/constants.js +1 -1
- package/dist/esm/helpers/constants.js.map +3 -3
- package/dist/esm/helpers/utils.js +1 -1
- package/dist/esm/helpers/utils.js.map +3 -3
- package/dist/esm/icons/spinner.d.ts +1 -1
- package/dist/esm/icons/spinner.js +1 -1
- package/dist/esm/icons/spinner.js.map +2 -2
- package/dist/esm/shared/Styles.d.ts +33 -0
- package/dist/esm/shared/Styles.js +2 -0
- package/dist/esm/shared/Styles.js.map +7 -0
- package/dist/esm/stories/HeroBanner.stories.d.ts +23 -0
- package/dist/esm/stories/HeroBanner.stories.js +10 -0
- package/dist/esm/stories/HeroBanner.stories.js.map +7 -0
- package/dist/esm/stories/MemberEquity.stories.d.ts +9 -0
- package/dist/esm/stories/MemberEquity.stories.js +31 -0
- package/dist/esm/stories/MemberEquity.stories.js.map +7 -0
- package/dist/esm/stories/alert.stories.d.ts +27 -0
- package/dist/esm/stories/alert.stories.js +2 -0
- package/dist/esm/stories/alert.stories.js.map +7 -0
- package/dist/esm/stories/avatar.stories.d.ts +40 -0
- package/dist/esm/stories/avatar.stories.js +2 -0
- package/dist/esm/stories/avatar.stories.js.map +7 -0
- package/dist/esm/stories/badge.stories.d.ts +2 -12
- package/dist/esm/stories/badge.stories.js +1 -1
- package/dist/esm/stories/badge.stories.js.map +2 -2
- package/dist/esm/stories/brandEquity.stories.d.ts +16 -0
- package/dist/esm/stories/brandEquity.stories.js +2 -0
- package/dist/esm/stories/brandEquity.stories.js.map +7 -0
- package/dist/esm/stories/button.stories.d.ts +14 -0
- package/dist/esm/stories/button.stories.js +1 -1
- package/dist/esm/stories/button.stories.js.map +3 -3
- package/dist/esm/stories/card.stories.d.ts +27 -0
- package/dist/esm/stories/card.stories.js +2 -0
- package/dist/esm/stories/card.stories.js.map +7 -0
- package/dist/esm/stories/carousel.stories.d.ts +62 -0
- package/dist/esm/stories/carousel.stories.js +2 -0
- package/dist/esm/stories/carousel.stories.js.map +7 -0
- package/dist/esm/stories/category.stories.d.ts +13 -0
- package/dist/esm/stories/category.stories.js +2 -0
- package/dist/esm/stories/category.stories.js.map +7 -0
- package/dist/esm/stories/checkbox.stories.d.ts +2 -2
- package/dist/esm/stories/checkbox.stories.js +1 -1
- package/dist/esm/stories/checkbox.stories.js.map +2 -2
- package/dist/esm/stories/container.stories.d.ts +23 -0
- package/dist/esm/stories/container.stories.js +15 -0
- package/dist/esm/stories/container.stories.js.map +7 -0
- package/dist/esm/stories/dialog.stories.js +1 -1
- package/dist/esm/stories/dialog.stories.js.map +2 -2
- package/dist/esm/stories/drawer.stories.d.ts +20 -0
- package/dist/esm/stories/drawer.stories.js +2 -0
- package/dist/esm/stories/drawer.stories.js.map +7 -0
- package/dist/esm/stories/drop-down.stories.d.ts +16 -0
- package/dist/esm/stories/drop-down.stories.js +2 -0
- package/dist/esm/stories/drop-down.stories.js.map +7 -0
- package/dist/esm/stories/evaluate.stories.d.ts +13 -0
- package/dist/esm/stories/evaluate.stories.js +2 -0
- package/dist/esm/stories/evaluate.stories.js.map +7 -0
- package/dist/esm/stories/grid.stories.d.ts +22 -0
- package/dist/esm/stories/grid.stories.js +13 -0
- package/dist/esm/stories/grid.stories.js.map +7 -0
- package/dist/esm/stories/heading.stories.d.ts +4 -4
- package/dist/esm/stories/heading.stories.js +1 -1
- package/dist/esm/stories/heading.stories.js.map +2 -2
- package/dist/esm/stories/input-number.stories.d.ts +39 -0
- package/dist/esm/stories/input-number.stories.js +2 -0
- package/dist/esm/stories/input-number.stories.js.map +7 -0
- package/dist/esm/stories/input.stories.js +1 -1
- package/dist/esm/stories/input.stories.js.map +2 -2
- package/dist/esm/stories/link.stories.d.ts +82 -0
- package/dist/esm/stories/link.stories.js +2 -0
- package/dist/esm/stories/link.stories.js.map +7 -0
- package/dist/esm/stories/marquee.stories.d.ts +49 -0
- package/dist/esm/stories/marquee.stories.js +2 -0
- package/dist/esm/stories/marquee.stories.js.map +7 -0
- package/dist/esm/stories/picture.stories.d.ts +1 -1
- package/dist/esm/stories/picture.stories.js +2 -2
- package/dist/esm/stories/picture.stories.js.map +2 -2
- package/dist/esm/stories/popover.stories.d.ts +1 -1
- package/dist/esm/stories/popover.stories.js +1 -1
- package/dist/esm/stories/popover.stories.js.map +2 -2
- package/dist/esm/stories/radio.stories.js +1 -1
- package/dist/esm/stories/radio.stories.js.map +2 -2
- package/dist/esm/stories/shelf.stories.d.ts +15 -0
- package/dist/esm/stories/shelf.stories.js +2 -0
- package/dist/esm/stories/shelf.stories.js.map +7 -0
- package/dist/esm/stories/shelfDisplay.stories.d.ts +13 -0
- package/dist/esm/stories/shelfDisplay.stories.js +2 -0
- package/dist/esm/stories/shelfDisplay.stories.js.map +7 -0
- package/dist/esm/stories/skeleton.stories.js +1 -1
- package/dist/esm/stories/skeleton.stories.js.map +2 -2
- package/dist/esm/stories/slogan.stories.d.ts +21 -0
- package/dist/esm/stories/slogan.stories.js +26 -0
- package/dist/esm/stories/slogan.stories.js.map +7 -0
- package/dist/esm/stories/tabs.stories.d.ts +360 -0
- package/dist/esm/stories/tabs.stories.js +2 -0
- package/dist/esm/stories/tabs.stories.js.map +7 -0
- package/dist/esm/stories/text.stories.d.ts +5 -5
- package/dist/esm/stories/text.stories.js +2 -2
- package/dist/esm/stories/text.stories.js.map +3 -3
- package/dist/esm/types/index.d.ts +0 -0
- package/dist/esm/types/index.js +2 -0
- package/dist/esm/types/index.js.map +7 -0
- package/dist/esm/types/props.d.ts +5 -0
- package/dist/esm/types/props.js +1 -0
- package/dist/esm/types/props.js.map +7 -0
- package/package.json +28 -3
- package/src/biz-components/BrandEquity/BrandEquity.tsx +77 -0
- package/src/biz-components/BrandEquity/index.ts +1 -0
- package/src/biz-components/Category/index.tsx +57 -0
- package/src/biz-components/Evaluate/index.tsx +85 -0
- package/src/biz-components/HeroBanner/HeroBanner.tsx +103 -0
- package/src/biz-components/HeroBanner/index.tsx +1 -0
- package/src/biz-components/HeroBanner/types.ts +28 -0
- package/src/biz-components/Marquee/index.tsx +79 -0
- package/src/biz-components/MemberEquity/index.tsx +114 -0
- package/src/biz-components/MemberEquity/types.ts +26 -0
- package/src/biz-components/Shelf/Shelf.tsx +22 -0
- package/src/biz-components/Shelf/index.ts +1 -0
- package/src/biz-components/Shelf/types.ts +6 -0
- package/src/biz-components/ShelfDisplay/index.tsx +142 -0
- package/src/biz-components/Slogan/index.tsx +53 -0
- package/src/biz-components/Slogan/types.ts +25 -0
- package/src/biz-components/index.ts +11 -0
- package/src/components/alert.tsx +124 -0
- package/src/components/avatar.tsx +126 -0
- package/src/components/badge.tsx +9 -11
- package/src/components/button.tsx +41 -25
- package/src/components/card.tsx +51 -0
- package/src/components/carousel.tsx +352 -0
- package/src/components/checkbox.tsx +5 -7
- package/src/components/color.tsx +77 -0
- package/src/components/container.tsx +28 -0
- package/src/components/dialog.tsx +9 -12
- package/src/components/drawer.tsx +115 -0
- package/src/components/drop-down.tsx +182 -0
- package/src/components/gird.tsx +90 -0
- package/src/components/heading.tsx +24 -29
- package/src/components/index.ts +12 -5
- package/src/components/input-number.tsx +216 -0
- package/src/components/input.tsx +9 -9
- package/src/components/link.tsx +99 -0
- package/src/components/picture.tsx +3 -2
- package/src/components/popover.tsx +1 -1
- package/src/components/radio.tsx +6 -6
- package/src/components/skeleton.tsx +3 -3
- package/src/components/tabs.tsx +78 -0
- package/src/components/text.tsx +24 -30
- package/src/components/theme.tsx +1 -2
- package/src/helpers/constants.ts +0 -3
- package/src/helpers/utils.ts +9 -1
- package/src/icons/spinner.tsx +1 -2
- package/src/shared/Styles.tsx +94 -0
- package/src/stories/HeroBanner.stories.tsx +86 -0
- package/src/stories/MemberEquity.stories.tsx +107 -0
- package/src/stories/alert.stories.tsx +41 -0
- package/src/stories/avatar.stories.tsx +83 -0
- package/src/stories/badge.stories.tsx +10 -14
- package/src/stories/brandEquity.stories.tsx +73 -0
- package/src/stories/button.stories.tsx +24 -3
- package/src/stories/card.stories.tsx +97 -0
- package/src/stories/carousel.stories.tsx +161 -0
- package/src/stories/category.stories.tsx +52 -0
- package/src/stories/checkbox.stories.tsx +9 -9
- package/src/stories/container.stories.tsx +97 -0
- package/src/stories/dialog.stories.tsx +8 -8
- package/src/stories/drawer.stories.tsx +88 -0
- package/src/stories/drop-down.stories.tsx +83 -0
- package/src/stories/evaluate.stories.tsx +53 -0
- package/src/stories/grid.stories.tsx +190 -0
- package/src/stories/heading.stories.tsx +6 -10
- package/src/stories/input-number.stories.tsx +52 -0
- package/src/stories/input.stories.tsx +2 -2
- package/src/stories/link.stories.tsx +142 -0
- package/src/stories/marquee.stories.tsx +102 -0
- package/src/stories/picture.stories.tsx +2 -2
- package/src/stories/popover.stories.tsx +2 -2
- package/src/stories/radio.stories.tsx +2 -2
- package/src/stories/shelf.stories.tsx +35 -0
- package/src/stories/shelfDisplay.stories.tsx +69 -0
- package/src/stories/skeleton.stories.tsx +7 -7
- package/src/stories/slogan.stories.tsx +99 -0
- package/src/stories/tabs.stories.tsx +179 -0
- package/src/stories/text.stories.tsx +18 -22
- package/src/styles/global.css +0 -199
- package/src/types/index.ts +0 -0
- package/src/types/props.ts +5 -0
- package/style.css +1092 -748
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/components/picture.tsx"],
|
|
4
|
-
"sourcesContent": ["'use client'\nimport React, { useCallback, useMemo } from 'react'\n\nconst APPEND_FILE_SUFFIX_MATCH_DOMAIN = ['cdn.shopify.com', 'cdn.shopifycdn.net', 'www.facebook.com']\n\nconst MAX_SIZE = 3960\nconst FIXED_MAX_SIZE = 3980\n\nexport interface PictureProps extends React.ImgHTMLAttributes<HTMLImageElement> {\n /** picture \u5185\u90E8img \u6807\u7B7E\u7684\u7C7B\u540D */\n imgClassName?: string\n /** \u56FE\u7247url , \u652F\u6301\u4F20\u5165\u4E0D\u540C\u5206\u8FA8\u7387\u4E0B\u7684\u56FE\u7247\uFF0C\u6BD4\u5982\uFF0C\u683C\u5F0F \"url1 1920\uFF0C url2 1080, url3 767\" */\n source?: string\n /** \u56FE\u7247\u8D28\u91CF */\n quality?: number\n /** \u54CD\u5E94\u5F0F\u56FE\u7247\uFF0C\u5BF9\u5E94picture \u4E0Bsource \u7684max-width */\n deviceSizes?: number[]\n}\n\nconst isMatchDomain = (srcDomain: string) => {\n return APPEND_FILE_SUFFIX_MATCH_DOMAIN.some(domain => srcDomain == domain)\n}\nconst idMatchFileExtensions = (fileName: string = '') => /\\.(png|apng|jpg|jpeg|gif|svg|webp|tif)/.test(fileName)\n\nconst Picture = ({\n imgClassName = '',\n source = '',\n quality = 2,\n deviceSizes = [375, 767, 1023, 1279, 1439, 1539, 1919],\n ...rest\n}: PictureProps) => {\n const imgSrcSetsize = useCallback(({ src, width }: { src: string; width: number }) => {\n const size = width\n try {\n const parsedUrl = new URL(src)\n if (!isMatchDomain(parsedUrl.hostname)) {\n return src\n }\n const fileName = parsedUrl.pathname.split('/').pop() || ''\n if (idMatchFileExtensions(fileName) && !/_[0-9]{2,4}x/.test(src)) {\n const [name, extension] = fileName.split('.')\n return `${parsedUrl.origin}${parsedUrl.pathname.replace(\n fileName,\n `${name}_${size < MAX_SIZE ? size : FIXED_MAX_SIZE}x.${extension}`\n )}`\n }\n } catch (error) {\n return src\n }\n }, [])\n\n const sourceSrcSet = useCallback(\n ({ srcArr, width }: { srcArr: string[][]; width: number }) => {\n const computedWidth = width * quality\n const def = imgSrcSetsize({ src: srcArr[0][0], width: computedWidth })\n let result\n srcArr.forEach(ele => {\n var img = ele[0]\n if (ele.length > 1 && parseInt(ele[1], 10) >= width) {\n result = imgSrcSetsize({ src: img, width: computedWidth })\n }\n })\n const srcset = result || def\n return <source key={width} srcSet={srcset} media={`(max-width: ${width}px)`} />\n },\n [imgSrcSetsize, quality]\n )\n\n const sourceList = useMemo(() => {\n if (typeof source !== 'string' || !source) return []\n let srcArr\n try {\n srcArr = source\n .replace(/[\\r\\n]/g, '')\n .replace(/\\s\\s+/g, ' ')\n .split(',')\n .map(item => item.split(' ').filter(Boolean))\n } catch (error) {\n console.log(error)\n return []\n }\n const sourceList = deviceSizes.map(width => {\n return sourceSrcSet({ srcArr, width })\n })\n\n const img = imgSrcSetsize({ src: srcArr[0][0], width: 1920 * quality })\n\n sourceList.push(<img key=\"default\" src={img} className={`
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": ["jsx", "jsxs", "useCallback", "useMemo", "APPEND_FILE_SUFFIX_MATCH_DOMAIN", "MAX_SIZE", "FIXED_MAX_SIZE", "isMatchDomain", "srcDomain", "domain", "idMatchFileExtensions", "fileName", "Picture", "imgClassName", "source", "quality", "deviceSizes", "rest", "imgSrcSetsize", "src", "width", "size", "parsedUrl", "name", "extension", "sourceSrcSet", "srcArr", "computedWidth", "def", "result", "ele", "img", "sourceList", "item", "error", "picture_default"]
|
|
4
|
+
"sourcesContent": ["'use client'\nimport React, { useCallback, useMemo } from 'react'\n\nconst APPEND_FILE_SUFFIX_MATCH_DOMAIN = ['cdn.shopify.com', 'cdn.shopifycdn.net', 'www.facebook.com']\n\nconst MAX_SIZE = 3960\nconst FIXED_MAX_SIZE = 3980\n\nexport interface PictureProps extends React.ImgHTMLAttributes<HTMLImageElement> {\n /** picture \u5185\u90E8img \u6807\u7B7E\u7684\u7C7B\u540D */\n imgClassName?: string\n /** \u56FE\u7247url , \u652F\u6301\u4F20\u5165\u4E0D\u540C\u5206\u8FA8\u7387\u4E0B\u7684\u56FE\u7247\uFF0C\u6BD4\u5982\uFF0C\u683C\u5F0F \"url1 1920\uFF0C url2 1080, url3 767\" */\n source?: string\n /** \u56FE\u7247\u8D28\u91CF */\n quality?: number\n /** \u54CD\u5E94\u5F0F\u56FE\u7247\uFF0C\u5BF9\u5E94picture \u4E0Bsource \u7684max-width */\n deviceSizes?: number[]\n}\n\nconst isMatchDomain = (srcDomain: string) => {\n return APPEND_FILE_SUFFIX_MATCH_DOMAIN.some(domain => srcDomain == domain)\n}\nconst idMatchFileExtensions = (fileName: string = '') => /\\.(png|apng|jpg|jpeg|gif|svg|webp|tif)/.test(fileName)\n\nconst Picture = ({\n imgClassName = '',\n source = '',\n quality = 2,\n deviceSizes = [375, 767, 1023, 1279, 1439, 1539, 1919],\n className,\n ...rest\n}: PictureProps) => {\n const imgSrcSetsize = useCallback(({ src, width }: { src: string; width: number }) => {\n const size = width\n try {\n const parsedUrl = new URL(src)\n if (!isMatchDomain(parsedUrl.hostname)) {\n return src\n }\n const fileName = parsedUrl.pathname.split('/').pop() || ''\n if (idMatchFileExtensions(fileName) && !/_[0-9]{2,4}x/.test(src)) {\n const [name, extension] = fileName.split('.')\n return `${parsedUrl.origin}${parsedUrl.pathname.replace(\n fileName,\n `${name}_${size < MAX_SIZE ? size : FIXED_MAX_SIZE}x.${extension}`\n )}`\n }\n } catch (error) {\n return src\n }\n }, [])\n\n const sourceSrcSet = useCallback(\n ({ srcArr, width }: { srcArr: string[][]; width: number }) => {\n const computedWidth = width * quality\n const def = imgSrcSetsize({ src: srcArr[0][0], width: computedWidth })\n let result\n srcArr.forEach(ele => {\n var img = ele[0]\n if (ele.length > 1 && parseInt(ele[1], 10) >= width) {\n result = imgSrcSetsize({ src: img, width: computedWidth })\n }\n })\n const srcset = result || def\n return <source key={width} srcSet={srcset} media={`(max-width: ${width}px)`} />\n },\n [imgSrcSetsize, quality]\n )\n\n const sourceList = useMemo(() => {\n if (typeof source !== 'string' || !source) return []\n let srcArr\n try {\n srcArr = source\n .replace(/[\\r\\n]/g, '')\n .replace(/\\s\\s+/g, ' ')\n .split(',')\n .map(item => item.split(' ').filter(Boolean))\n } catch (error) {\n console.log(error)\n return []\n }\n const sourceList = deviceSizes.map(width => {\n return sourceSrcSet({ srcArr, width })\n })\n\n const img = imgSrcSetsize({ src: srcArr[0][0], width: 1920 * quality })\n\n sourceList.push(<img key=\"default\" src={img} className={`w-full ${imgClassName}`} {...rest} />)\n return sourceList\n }, [deviceSizes, imgClassName, imgSrcSetsize, quality, rest, source, sourceSrcSet])\n\n return (\n <picture className={`block overflow-hidden ${className}`}>\n {sourceList}\n {rest.children}\n </picture>\n )\n}\nexport default Picture\n"],
|
|
5
|
+
"mappings": "aAgEa,cAAAA,EA6BT,QAAAC,MA7BS,oBA/Db,OAAgB,eAAAC,EAAa,WAAAC,MAAe,QAE5C,MAAMC,EAAkC,CAAC,kBAAmB,qBAAsB,kBAAkB,EAE9FC,EAAW,KACXC,EAAiB,KAajBC,EAAiBC,GACdJ,EAAgC,KAAKK,GAAUD,GAAaC,CAAM,EAErEC,EAAwB,CAACC,EAAmB,KAAO,yCAAyC,KAAKA,CAAQ,EAEzGC,EAAU,CAAC,CACf,aAAAC,EAAe,GACf,OAAAC,EAAS,GACT,QAAAC,EAAU,EACV,YAAAC,EAAc,CAAC,IAAK,IAAK,KAAM,KAAM,KAAM,KAAM,IAAI,EACrD,UAAAC,EACA,GAAGC,CACL,IAAoB,CAClB,MAAMC,EAAgBjB,EAAY,CAAC,CAAE,IAAAkB,EAAK,MAAAC,CAAM,IAAsC,CACpF,MAAMC,EAAOD,EACb,GAAI,CACF,MAAME,EAAY,IAAI,IAAIH,CAAG,EAC7B,GAAI,CAACb,EAAcgB,EAAU,QAAQ,EACnC,OAAOH,EAET,MAAMT,EAAWY,EAAU,SAAS,MAAM,GAAG,EAAE,IAAI,GAAK,GACxD,GAAIb,EAAsBC,CAAQ,GAAK,CAAC,eAAe,KAAKS,CAAG,EAAG,CAChE,KAAM,CAACI,EAAMC,CAAS,EAAId,EAAS,MAAM,GAAG,EAC5C,MAAO,GAAGY,EAAU,MAAM,GAAGA,EAAU,SAAS,QAC9CZ,EACA,GAAGa,CAAI,IAAIF,EAAOjB,EAAWiB,EAAOhB,CAAc,KAAKmB,CAAS,EAClE,CAAC,EACH,CACF,MAAgB,CACd,OAAOL,CACT,CACF,EAAG,CAAC,CAAC,EAECM,EAAexB,EACnB,CAAC,CAAE,OAAAyB,EAAQ,MAAAN,CAAM,IAA6C,CAC5D,MAAMO,EAAgBP,EAAQN,EACxBc,EAAMV,EAAc,CAAE,IAAKQ,EAAO,CAAC,EAAE,CAAC,EAAG,MAAOC,CAAc,CAAC,EACrE,IAAIE,EACJ,OAAAH,EAAO,QAAQI,GAAO,CACpB,IAAIC,EAAMD,EAAI,CAAC,EACXA,EAAI,OAAS,GAAK,SAASA,EAAI,CAAC,EAAG,EAAE,GAAKV,IAC5CS,EAASX,EAAc,CAAE,IAAKa,EAAK,MAAOJ,CAAc,CAAC,EAE7D,CAAC,EAEM5B,EAAC,UAAmB,OADZ8B,GAAUD,EACkB,MAAO,eAAeR,CAAK,OAAlDA,CAAyD,CAC/E,EACA,CAACF,EAAeJ,CAAO,CACzB,EAEMkB,EAAa9B,EAAQ,IAAM,CAC/B,GAAI,OAAOW,GAAW,UAAY,CAACA,EAAQ,MAAO,CAAC,EACnD,IAAIa,EACJ,GAAI,CACFA,EAASb,EACN,QAAQ,UAAW,EAAE,EACrB,QAAQ,SAAU,GAAG,EACrB,MAAM,GAAG,EACT,IAAIoB,GAAQA,EAAK,MAAM,GAAG,EAAE,OAAO,OAAO,CAAC,CAChD,OAASC,EAAO,CACd,eAAQ,IAAIA,CAAK,EACV,CAAC,CACV,CACA,MAAMF,EAAajB,EAAY,IAAIK,GAC1BK,EAAa,CAAE,OAAAC,EAAQ,MAAAN,CAAM,CAAC,CACtC,EAEKW,EAAMb,EAAc,CAAE,IAAKQ,EAAO,CAAC,EAAE,CAAC,EAAG,MAAO,KAAOZ,CAAQ,CAAC,EAEtE,OAAAkB,EAAW,KAAKjC,EAAC,OAAkB,IAAKgC,EAAK,UAAW,UAAUnB,CAAY,GAAK,GAAGK,GAA7D,SAAmE,CAAE,EACvFe,CACT,EAAG,CAACjB,EAAaH,EAAcM,EAAeJ,EAASG,EAAMJ,EAAQY,CAAY,CAAC,EAElF,OACEzB,EAAC,WAAQ,UAAW,yBAAyBgB,CAAS,GACnD,UAAAgB,EACAf,EAAK,UACR,CAEJ,EACA,IAAOkB,EAAQxB",
|
|
6
|
+
"names": ["jsx", "jsxs", "useCallback", "useMemo", "APPEND_FILE_SUFFIX_MATCH_DOMAIN", "MAX_SIZE", "FIXED_MAX_SIZE", "isMatchDomain", "srcDomain", "domain", "idMatchFileExtensions", "fileName", "Picture", "imgClassName", "source", "quality", "deviceSizes", "className", "rest", "imgSrcSetsize", "src", "width", "size", "parsedUrl", "name", "extension", "sourceSrcSet", "srcArr", "computedWidth", "def", "result", "ele", "img", "sourceList", "item", "error", "picture_default"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use client";import{jsx as e}from"react/jsx-runtime";import*as s from"react";import*as o from"@radix-ui/react-popover";import{cn as p}from"../helpers/utils.js";const m=o.Root,f=o.Trigger,t=s.forwardRef(({className:a,align:i="center",sideOffset:r=4,...n},d)=>e(o.Portal,{children:e(o.Content,{ref:d,align:i,sideOffset:r,className:p("
|
|
1
|
+
"use client";import{jsx as e}from"react/jsx-runtime";import*as s from"react";import*as o from"@radix-ui/react-popover";import{cn as p}from"../helpers/utils.js";const m=o.Root,f=o.Trigger,t=s.forwardRef(({className:a,align:i="center",sideOffset:r=4,...n},d)=>e(o.Portal,{children:e(o.Content,{ref:d,align:i,sideOffset:r,className:p("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-72 rounded-md border p-4 shadow-md outline-none",a),...n})}));t.displayName=o.Content.displayName;export{m as Popover,t as PopoverContent,f as PopoverTrigger};
|
|
2
2
|
//# sourceMappingURL=popover.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/components/popover.tsx"],
|
|
4
|
-
"sourcesContent": ["'use client'\n\nimport * as React from 'react'\nimport * as PopoverPrimitive from '@radix-ui/react-popover'\n\nimport { cn } from '../helpers/utils.js'\n\nconst Popover = PopoverPrimitive.Root\n\nconst PopoverTrigger = PopoverPrimitive.Trigger\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Content>,\n React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Content>\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n <PopoverPrimitive.Portal>\n <PopoverPrimitive.Content\n ref={ref}\n align={align}\n sideOffset={sideOffset}\n className={cn(\n '
|
|
5
|
-
"mappings": "aAgBI,cAAAA,MAAA,oBAdJ,UAAYC,MAAW,QACvB,UAAYC,MAAsB,0BAElC,OAAS,MAAAC,MAAU,sBAEnB,MAAMC,EAAUF,EAAiB,KAE3BG,EAAiBH,EAAiB,QAElCI,EAAiBL,EAAM,WAG3B,CAAC,CAAE,UAAAM,EAAW,MAAAC,EAAQ,SAAU,WAAAC,EAAa,EAAG,GAAGC,CAAM,EAAGC,IAC5DX,EAACE,EAAiB,OAAjB,CACC,SAAAF,EAACE,EAAiB,QAAjB,CACC,IAAKS,EACL,MAAOH,EACP,WAAYC,EACZ,UAAWN,EACT,
|
|
4
|
+
"sourcesContent": ["'use client'\n\nimport * as React from 'react'\nimport * as PopoverPrimitive from '@radix-ui/react-popover'\n\nimport { cn } from '../helpers/utils.js'\n\nconst Popover = PopoverPrimitive.Root\n\nconst PopoverTrigger = PopoverPrimitive.Trigger\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Content>,\n React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Content>\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n <PopoverPrimitive.Portal>\n <PopoverPrimitive.Content\n ref={ref}\n align={align}\n sideOffset={sideOffset}\n className={cn(\n 'bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-72 rounded-md border p-4 shadow-md outline-none',\n className\n )}\n {...props}\n />\n </PopoverPrimitive.Portal>\n))\nPopoverContent.displayName = PopoverPrimitive.Content.displayName\n\nexport { Popover, PopoverTrigger, PopoverContent }\n"],
|
|
5
|
+
"mappings": "aAgBI,cAAAA,MAAA,oBAdJ,UAAYC,MAAW,QACvB,UAAYC,MAAsB,0BAElC,OAAS,MAAAC,MAAU,sBAEnB,MAAMC,EAAUF,EAAiB,KAE3BG,EAAiBH,EAAiB,QAElCI,EAAiBL,EAAM,WAG3B,CAAC,CAAE,UAAAM,EAAW,MAAAC,EAAQ,SAAU,WAAAC,EAAa,EAAG,GAAGC,CAAM,EAAGC,IAC5DX,EAACE,EAAiB,OAAjB,CACC,SAAAF,EAACE,EAAiB,QAAjB,CACC,IAAKS,EACL,MAAOH,EACP,WAAYC,EACZ,UAAWN,EACT,6aACAI,CACF,EACC,GAAGG,EACN,EACF,CACD,EACDJ,EAAe,YAAcJ,EAAiB,QAAQ",
|
|
6
6
|
"names": ["jsx", "React", "PopoverPrimitive", "cn", "Popover", "PopoverTrigger", "PopoverContent", "className", "align", "sideOffset", "props", "ref"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use client";import{jsx as e,jsxs as v}from"react/jsx-runtime";import*as
|
|
1
|
+
"use client";import{jsx as e,jsxs as v}from"react/jsx-runtime";import*as t from"react";import*as p from"@radix-ui/react-radio-group";import{Text as R}from"./text.js";import{CheckIcon as l}from"@radix-ui/react-icons";import{cva as P}from"class-variance-authority";import{cn as d}from"../helpers/index.js";const m=t.createContext({size:"base"}),G=P("border-primary text-primary ring-offset-background focus-visible:ring-ring aspect-square rounded-full border focus:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",{variants:{size:{sm:"size-[14px]",base:"size-4",lg:"size-5"}},defaultVariants:{size:"base"}}),u=t.forwardRef(({className:o,children:i,size:r,...a},s)=>e(p.Root,{className:d("grid gap-2",o),...a,ref:s,children:e(m.Provider,{value:{size:r},children:i})}));u.displayName="RadioGroup";const f=t.forwardRef(({className:o,size:i,children:r,...a},s)=>{const{size:c}=t.useContext(m),n=e(p.Item,{ref:s,className:d(G({size:i??c}),o),...a,children:e(p.Indicator,{className:"flex items-center justify-center text-current w-full h-full",children:e(l,{})})});return r?v(R,{as:"label",className:d("flex items-center gap-1",o),children:[n,r]}):n});f.displayName="RadioGroupItem";export{u as RadioGroup,f as RadioGroupItem};
|
|
2
2
|
//# sourceMappingURL=radio.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/components/radio.tsx"],
|
|
4
|
-
"sourcesContent": ["'use client'\n\nimport * as React from 'react'\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group'\nimport { Text } from './text.js'\nimport { CheckIcon } from '@radix-ui/react-icons'\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport { cn } from '../helpers/index.js'\n\nconst RadioContext = React.createContext<{ size?: 'sm' | 'base' | 'lg' }>({\n size: 'base',\n})\n\nconst radioGroupVariants = cva(\n '
|
|
5
|
-
"mappings": "aAsCQ,cAAAA,EAkCA,QAAAC,MAlCA,oBApCR,UAAYC,MAAW,QACvB,UAAYC,MAAyB,8BACrC,OAAS,QAAAC,MAAY,YACrB,OAAS,aAAAC,MAAiB,wBAC1B,OAAS,OAAAC,MAA8B,2BACvC,OAAS,MAAAC,MAAU,sBAEnB,MAAMC,EAAeN,EAAM,cAA+C,CACxE,KAAM,MACR,CAAC,EAEKO,EAAqBH,EACzB,
|
|
4
|
+
"sourcesContent": ["'use client'\n\nimport * as React from 'react'\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group'\nimport { Text } from './text.js'\nimport { CheckIcon } from '@radix-ui/react-icons'\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport { cn } from '../helpers/index.js'\n\nconst RadioContext = React.createContext<{ size?: 'sm' | 'base' | 'lg' }>({\n size: 'base',\n})\n\nconst radioGroupVariants = cva(\n 'border-primary text-primary ring-offset-background focus-visible:ring-ring aspect-square rounded-full border focus:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground',\n {\n variants: {\n size: {\n sm: 'size-[14px]',\n base: 'size-4',\n lg: 'size-5',\n },\n },\n defaultVariants: {\n size: 'base',\n },\n }\n)\n\ninterface RadioGroupProps extends React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Root> {\n /** \u5C3A\u5BF8 */\n size?: 'sm' | 'base' | 'lg'\n}\n\nconst RadioGroup = React.forwardRef<React.ElementRef<typeof RadioGroupPrimitive.Root>, RadioGroupProps>(\n ({ className, children, size, ...props }, ref) => {\n return (\n <RadioGroupPrimitive.Root className={cn('grid gap-2', className)} {...props} ref={ref}>\n <RadioContext.Provider value={{ size }}>{children}</RadioContext.Provider>\n </RadioGroupPrimitive.Root>\n )\n }\n)\nRadioGroup.displayName = 'RadioGroup'\n\ninterface RadioGroupItemProps\n extends React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Item>,\n VariantProps<typeof radioGroupVariants> {}\n\nconst RadioGroupItem = React.forwardRef<React.ElementRef<typeof RadioGroupPrimitive.Item>, RadioGroupItemProps>(\n ({ className, size, children, ...props }, ref) => {\n const { size: sizeFromParent } = React.useContext(RadioContext)\n\n const ItemRadio = (\n <RadioGroupPrimitive.Item\n ref={ref}\n className={cn(\n radioGroupVariants({\n size: size ?? sizeFromParent,\n }),\n className\n )}\n {...props}\n >\n <RadioGroupPrimitive.Indicator className=\"flex items-center justify-center text-current w-full h-full\">\n <CheckIcon />\n </RadioGroupPrimitive.Indicator>\n </RadioGroupPrimitive.Item>\n )\n\n if (children) {\n return (\n <Text as=\"label\" className={cn('flex items-center gap-1', className)}>\n {ItemRadio}\n {children}\n </Text>\n )\n }\n return ItemRadio\n }\n)\nRadioGroupItem.displayName = 'RadioGroupItem'\n\nexport { RadioGroup, RadioGroupItem }\nexport type { RadioGroupProps, RadioGroupItemProps }\n"],
|
|
5
|
+
"mappings": "aAsCQ,cAAAA,EAkCA,QAAAC,MAlCA,oBApCR,UAAYC,MAAW,QACvB,UAAYC,MAAyB,8BACrC,OAAS,QAAAC,MAAY,YACrB,OAAS,aAAAC,MAAiB,wBAC1B,OAAS,OAAAC,MAA8B,2BACvC,OAAS,MAAAC,MAAU,sBAEnB,MAAMC,EAAeN,EAAM,cAA+C,CACxE,KAAM,MACR,CAAC,EAEKO,EAAqBH,EACzB,gTACA,CACE,SAAU,CACR,KAAM,CACJ,GAAI,cACJ,KAAM,SACN,GAAI,QACN,CACF,EACA,gBAAiB,CACf,KAAM,MACR,CACF,CACF,EAOMI,EAAaR,EAAM,WACvB,CAAC,CAAE,UAAAS,EAAW,SAAAC,EAAU,KAAAC,EAAM,GAAGC,CAAM,EAAGC,IAEtCf,EAACG,EAAoB,KAApB,CAAyB,UAAWI,EAAG,aAAcI,CAAS,EAAI,GAAGG,EAAO,IAAKC,EAChF,SAAAf,EAACQ,EAAa,SAAb,CAAsB,MAAO,CAAE,KAAAK,CAAK,EAAI,SAAAD,EAAS,EACpD,CAGN,EACAF,EAAW,YAAc,aAMzB,MAAMM,EAAiBd,EAAM,WAC3B,CAAC,CAAE,UAAAS,EAAW,KAAAE,EAAM,SAAAD,EAAU,GAAGE,CAAM,EAAGC,IAAQ,CAChD,KAAM,CAAE,KAAME,CAAe,EAAIf,EAAM,WAAWM,CAAY,EAExDU,EACJlB,EAACG,EAAoB,KAApB,CACC,IAAKY,EACL,UAAWR,EACTE,EAAmB,CACjB,KAAMI,GAAQI,CAChB,CAAC,EACDN,CACF,EACC,GAAGG,EAEJ,SAAAd,EAACG,EAAoB,UAApB,CAA8B,UAAU,8DACvC,SAAAH,EAACK,EAAA,EAAU,EACb,EACF,EAGF,OAAIO,EAEAX,EAACG,EAAA,CAAK,GAAG,QAAQ,UAAWG,EAAG,0BAA2BI,CAAS,EAChE,UAAAO,EACAN,GACH,EAGGM,CACT,CACF,EACAF,EAAe,YAAc",
|
|
6
6
|
"names": ["jsx", "jsxs", "React", "RadioGroupPrimitive", "Text", "CheckIcon", "cva", "cn", "RadioContext", "radioGroupVariants", "RadioGroup", "className", "children", "size", "props", "ref", "RadioGroupItem", "sizeFromParent", "ItemRadio"]
|
|
7
7
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import{jsx as m}from"react/jsx-runtime";import*as n from"react";import{cn as p}from"../helpers/index.js";import{Slot as d}from"@radix-ui/react-slot";const o=n.forwardRef((t,
|
|
2
|
-
!
|
|
3
|
-
after:!
|
|
4
|
-
`,
|
|
1
|
+
import{jsx as m}from"react/jsx-runtime";import*as n from"react";import{cn as p}from"../helpers/index.js";import{Slot as d}from"@radix-ui/react-slot";const o=n.forwardRef((t,r)=>{const{children:e,className:l,loading:s=!0,...a}=t;if(!s)return e;const i=n.isValidElement(e)?d:"span";return m(i,{ref:r,className:p(`bg-skeleton animate-pulse empty:block data-[inline-skeleton=true]:leading-[0] !bg-none !bg-clip-border !border-none !shadow-none
|
|
2
|
+
!text-transparent !outline-none !select-none !cursor-default !pointer-events-none !decoration-clone
|
|
3
|
+
after:!invisible before:!invisible [&>*]:!invisible
|
|
4
|
+
`,l),"data-inline-skeleton":n.isValidElement(e)?void 0:!0,tabIndex:-1,...a,children:e})});o.displayName="Skeleton";var b=o;export{b as default};
|
|
5
5
|
//# sourceMappingURL=skeleton.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/components/skeleton.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react'\nimport { cn } from '../helpers/index.js'\nimport { Slot } from '@radix-ui/react-slot'\nimport type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js'\n\ntype SkeletonElement = React.ElementRef<'span'>\n\ninterface SkeletonProps extends ComponentPropsWithout<'span', RemovedProps> {\n /** \u662F\u5426\u6B63\u5728\u52A0\u8F7D , \u9ED8\u8BA4\u662Ftrue*/\n loading?: boolean\n}\n\nconst Skeleton = React.forwardRef<SkeletonElement, SkeletonProps>((props, forwardedRef) => {\n const { children, className, loading = true, ...skeletonProps } = props\n\n if (!loading) return children\n const Tag = React.isValidElement(children) ? Slot : 'span'\n\n return (\n <Tag\n ref={forwardedRef}\n className={cn(\n `
|
|
4
|
+
"sourcesContent": ["import * as React from 'react'\nimport { cn } from '../helpers/index.js'\nimport { Slot } from '@radix-ui/react-slot'\nimport type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js'\n\ntype SkeletonElement = React.ElementRef<'span'>\n\ninterface SkeletonProps extends ComponentPropsWithout<'span', RemovedProps> {\n /** \u662F\u5426\u6B63\u5728\u52A0\u8F7D , \u9ED8\u8BA4\u662Ftrue*/\n loading?: boolean\n}\n\nconst Skeleton = React.forwardRef<SkeletonElement, SkeletonProps>((props, forwardedRef) => {\n const { children, className, loading = true, ...skeletonProps } = props\n\n if (!loading) return children\n const Tag = React.isValidElement(children) ? Slot : 'span'\n\n return (\n <Tag\n ref={forwardedRef}\n className={cn(\n `bg-skeleton animate-pulse empty:block data-[inline-skeleton=true]:leading-[0] !bg-none !bg-clip-border !border-none !shadow-none \n !text-transparent !outline-none !select-none !cursor-default !pointer-events-none !decoration-clone\n after:!invisible before:!invisible [&>*]:!invisible\n `,\n className\n )}\n data-inline-skeleton={React.isValidElement(children) ? undefined : true}\n tabIndex={-1}\n {...skeletonProps}\n >\n {children}\n </Tag>\n )\n})\n\nSkeleton.displayName = 'Skeleton'\n\nexport default Skeleton\nexport type { SkeletonProps }\n"],
|
|
5
5
|
"mappings": "AAmBI,cAAAA,MAAA,oBAnBJ,UAAYC,MAAW,QACvB,OAAS,MAAAC,MAAU,sBACnB,OAAS,QAAAC,MAAY,uBAUrB,MAAMC,EAAWH,EAAM,WAA2C,CAACI,EAAOC,IAAiB,CACzF,KAAM,CAAE,SAAAC,EAAU,UAAAC,EAAW,QAAAC,EAAU,GAAM,GAAGC,CAAc,EAAIL,EAElE,GAAI,CAACI,EAAS,OAAOF,EACrB,MAAMI,EAAMV,EAAM,eAAeM,CAAQ,EAAIJ,EAAO,OAEpD,OACEH,EAACW,EAAA,CACC,IAAKL,EACL,UAAWJ,EACT;AAAA;AAAA;AAAA,UAIAM,CACF,EACA,uBAAsBP,EAAM,eAAeM,CAAQ,EAAI,OAAY,GACnE,SAAU,GACT,GAAGG,EAEH,SAAAH,EACH,CAEJ,CAAC,EAEDH,EAAS,YAAc,WAEvB,IAAOQ,EAAQR",
|
|
6
6
|
"names": ["jsx", "React", "cn", "Slot", "Skeleton", "props", "forwardedRef", "children", "className", "loading", "skeletonProps", "Tag", "skeleton_default"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import * as TabsPrimitive from '@radix-ui/react-tabs';
|
|
3
|
+
declare const Tabs: React.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
4
|
+
algin?: "left" | "center" | "right";
|
|
5
|
+
} & React.RefAttributes<HTMLDivElement>>;
|
|
6
|
+
declare const TabsList: React.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsListProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
+
declare const TabsTrigger: React.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
8
|
+
declare const TabsContent: React.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
9
|
+
export { Tabs, TabsList, TabsTrigger, TabsContent };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use client";import{jsx as o}from"react/jsx-runtime";import*as r from"react";import{cn as n}from"../helpers/index.js";import*as i from"@radix-ui/react-tabs";import{cva as c}from"class-variance-authority";const f=r.createContext({algin:"left"}),l=r.forwardRef(({children:t,algin:e="left",...a},s)=>o(i.Root,{ref:s,...a,children:o(f.Provider,{value:{algin:e},children:t})}));l.displayName="Tabs";const d=c("",{variants:{algin:{left:"justify-left",center:"justify-center",right:"justify-end"}},defaultVariants:{algin:"left"}}),m=r.forwardRef(({className:t,...e},a)=>{const{algin:s}=r.useContext(f);return o(i.List,{ref:a,className:n("border-b-lines flex gap-[24px] overflow-x-auto border-b",d({algin:s}),t),...e})});m.displayName=i.List.displayName;const p=r.forwardRef(({className:t,...e},a)=>o(i.Trigger,{ref:a,className:n("border-b-brand-0 disabled:text-btn-secondary-disabled shrink-0 text-base font-bold data-[state=active]:border-b-[3px]",t),...e}));p.displayName=i.Trigger.displayName;const b=r.forwardRef(({className:t,...e},a)=>o(i.Content,{ref:a,className:n(t),...e}));b.displayName=i.Content.displayName;export{l as Tabs,b as TabsContent,m as TabsList,p as TabsTrigger};
|
|
2
|
+
//# sourceMappingURL=tabs.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/tabs.tsx"],
|
|
4
|
+
"sourcesContent": ["'use client'\n\nimport * as React from 'react'\nimport { cn } from '../helpers/index.js'\n\nimport * as TabsPrimitive from '@radix-ui/react-tabs'\nimport { cva, type VariantProps } from 'class-variance-authority'\n\nconst TabListContext = React.createContext<{ algin?: 'left' | 'center' | 'right' }>({\n algin: 'left',\n})\n\nconst Tabs = React.forwardRef<\n React.ElementRef<typeof TabsPrimitive.Root>,\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.Root> & { algin?: 'left' | 'center' | 'right' }\n>(({ children, algin = 'left', ...props }, ref) => (\n <TabsPrimitive.Root ref={ref} {...props}>\n <TabListContext.Provider value={{ algin }}>{children}</TabListContext.Provider>\n </TabsPrimitive.Root>\n))\nTabs.displayName = 'Tabs'\n\nconst tabsListVariants = cva('', {\n variants: {\n algin: {\n left: 'justify-left',\n center: 'justify-center',\n right: 'justify-end',\n },\n },\n defaultVariants: {\n algin: 'left',\n },\n})\n\nconst TabsList = React.forwardRef<\n React.ElementRef<typeof TabsPrimitive.List>,\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.List>\n>(({ className, ...props }, ref) => {\n const { algin: alginFromParent } = React.useContext(TabListContext)\n return (\n <TabsPrimitive.List\n ref={ref}\n className={cn(\n 'border-b-lines flex gap-[24px] overflow-x-auto border-b',\n tabsListVariants({\n algin: alginFromParent,\n }),\n className\n )}\n {...props}\n />\n )\n})\nTabsList.displayName = TabsPrimitive.List.displayName\n\nconst TabsTrigger = React.forwardRef<\n React.ElementRef<typeof TabsPrimitive.Trigger>,\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger>\n>(({ className, ...props }, ref) => (\n <TabsPrimitive.Trigger\n ref={ref}\n className={cn(\n 'border-b-brand-0 disabled:text-btn-secondary-disabled shrink-0 text-base font-bold data-[state=active]:border-b-[3px]',\n className\n )}\n {...props}\n />\n))\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName\n\nconst TabsContent = React.forwardRef<\n React.ElementRef<typeof TabsPrimitive.Content>,\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.Content>\n>(({ className, ...props }, ref) => <TabsPrimitive.Content ref={ref} className={cn(className)} {...props} />)\nTabsContent.displayName = TabsPrimitive.Content.displayName\n\nexport { Tabs, TabsList, TabsTrigger, TabsContent }\n"],
|
|
5
|
+
"mappings": "aAiBI,cAAAA,MAAA,oBAfJ,UAAYC,MAAW,QACvB,OAAS,MAAAC,MAAU,sBAEnB,UAAYC,MAAmB,uBAC/B,OAAS,OAAAC,MAA8B,2BAEvC,MAAMC,EAAiBJ,EAAM,cAAuD,CAClF,MAAO,MACT,CAAC,EAEKK,EAAOL,EAAM,WAGjB,CAAC,CAAE,SAAAM,EAAU,MAAAC,EAAQ,OAAQ,GAAGC,CAAM,EAAGC,IACzCV,EAACG,EAAc,KAAd,CAAmB,IAAKO,EAAM,GAAGD,EAChC,SAAAT,EAACK,EAAe,SAAf,CAAwB,MAAO,CAAE,MAAAG,CAAM,EAAI,SAAAD,EAAS,EACvD,CACD,EACDD,EAAK,YAAc,OAEnB,MAAMK,EAAmBP,EAAI,GAAI,CAC/B,SAAU,CACR,MAAO,CACL,KAAM,eACN,OAAQ,iBACR,MAAO,aACT,CACF,EACA,gBAAiB,CACf,MAAO,MACT,CACF,CAAC,EAEKQ,EAAWX,EAAM,WAGrB,CAAC,CAAE,UAAAY,EAAW,GAAGJ,CAAM,EAAGC,IAAQ,CAClC,KAAM,CAAE,MAAOI,CAAgB,EAAIb,EAAM,WAAWI,CAAc,EAClE,OACEL,EAACG,EAAc,KAAd,CACC,IAAKO,EACL,UAAWR,EACT,0DACAS,EAAiB,CACf,MAAOG,CACT,CAAC,EACDD,CACF,EACC,GAAGJ,EACN,CAEJ,CAAC,EACDG,EAAS,YAAcT,EAAc,KAAK,YAE1C,MAAMY,EAAcd,EAAM,WAGxB,CAAC,CAAE,UAAAY,EAAW,GAAGJ,CAAM,EAAGC,IAC1BV,EAACG,EAAc,QAAd,CACC,IAAKO,EACL,UAAWR,EACT,wHACAW,CACF,EACC,GAAGJ,EACN,CACD,EACDM,EAAY,YAAcZ,EAAc,QAAQ,YAEhD,MAAMa,EAAcf,EAAM,WAGxB,CAAC,CAAE,UAAAY,EAAW,GAAGJ,CAAM,EAAGC,IAAQV,EAACG,EAAc,QAAd,CAAsB,IAAKO,EAAK,UAAWR,EAAGW,CAAS,EAAI,GAAGJ,EAAO,CAAE,EAC5GO,EAAY,YAAcb,EAAc,QAAQ",
|
|
6
|
+
"names": ["jsx", "React", "cn", "TabsPrimitive", "cva", "TabListContext", "Tabs", "children", "algin", "props", "ref", "tabsListVariants", "TabsList", "className", "alginFromParent", "TabsTrigger", "TabsContent"]
|
|
7
|
+
}
|
|
@@ -2,9 +2,9 @@ import * as React from 'react';
|
|
|
2
2
|
import { type VariantProps } from 'class-variance-authority';
|
|
3
3
|
import type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js';
|
|
4
4
|
declare const textVariants: (props?: ({
|
|
5
|
-
size?:
|
|
6
|
-
|
|
7
|
-
align?: "
|
|
5
|
+
size?: 1 | 2 | 3 | null | undefined;
|
|
6
|
+
weight?: "bold" | "light" | "normal" | "medium" | "semibold" | null | undefined;
|
|
7
|
+
align?: "left" | "right" | "center" | null | undefined;
|
|
8
8
|
} & import("class-variance-authority/dist/types.js").ClassProp) | undefined) => string;
|
|
9
9
|
type TextSpanProps = {
|
|
10
10
|
as?: 'span';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as
|
|
1
|
+
import{jsx as p}from"react/jsx-runtime";import*as T from"react";import{Slot as c}from"@radix-ui/react-slot";import{cn as y}from"../helpers/index.js";import{cva as g}from"class-variance-authority";const u=g("tracking font-body",{variants:{size:{1:"text-text-1 text-info-primary",2:"text-text-2 text-info-primary",3:"text-text-3 text-info-primary"},weight:{light:"font-light",normal:"font-normal",medium:"font-medium",semibold:"font-semibold",bold:"font-bold"},align:{left:"text-left",center:"text-center",right:"text-right"}},defaultVariants:{size:3,weight:"normal"}}),s=T.forwardRef((n,a)=>{const{children:t,size:i=3,weight:l,align:m,className:x,asChild:P,as:d="span",color:e,html:o,...f}=n,r=o?{dangerouslySetInnerHTML:{__html:o}}:null,h=e?{style:{color:e}}:null;return p(c,{...f,ref:a,className:y(u({size:i,weight:l,align:m}),x),...r,...h,children:P?t:p(d,{children:r?null:t})})});s.displayName="Text";export{s as Text};
|
|
2
2
|
//# sourceMappingURL=text.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/components/text.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react'\nimport { Slot } from '@radix-ui/react-slot'\nimport { cn } from '../helpers/index.js'\nimport { type VariantProps, cva } from 'class-variance-authority'\nimport type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js'\n\nconst textVariants = cva('', {\n variants: {\n size: {\n
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": ["jsx", "React", "Slot", "cn", "cva", "textVariants", "Text", "props", "forwardedRef", "children", "size", "
|
|
4
|
+
"sourcesContent": ["import * as React from 'react'\nimport { Slot } from '@radix-ui/react-slot'\nimport { cn } from '../helpers/index.js'\nimport { type VariantProps, cva } from 'class-variance-authority'\nimport type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js'\n\nconst textVariants = cva('tracking font-body', {\n variants: {\n size: {\n 1: 'text-text-1 text-info-primary',\n 2: 'text-text-2 text-info-primary',\n 3: 'text-text-3 text-info-primary',\n },\n weight: {\n light: 'font-light',\n normal: 'font-normal',\n medium: 'font-medium',\n semibold: 'font-semibold',\n bold: 'font-bold',\n },\n align: {\n left: 'text-left',\n center: 'text-center',\n right: 'text-right',\n },\n },\n defaultVariants: {\n size: 3,\n weight: 'normal',\n },\n})\n\ntype TextElement = React.ElementRef<'span'>\ntype TextSpanProps = { as?: 'span' } & ComponentPropsWithout<'span', RemovedProps>\ntype TextDivProps = { as: 'div' } & ComponentPropsWithout<'div', RemovedProps>\ntype TextLabelProps = { as: 'label' } & ComponentPropsWithout<'label', RemovedProps>\ntype TextPProps = { as: 'p' } & ComponentPropsWithout<'p', RemovedProps>\n\ninterface CommonTextProps extends VariantProps<typeof textVariants> {\n as?: 'div' | 'label' | 'p' | 'span'\n asChild?: boolean\n color?: string\n /** \u76F8\u5F53\u4E8E dangerouslySetInnerHTML */\n html?: string\n}\n\ntype TextProps = CommonTextProps & (TextSpanProps | TextDivProps | TextLabelProps | TextPProps)\n\nconst Text = React.forwardRef<TextElement, TextProps>((props, forwardedRef) => {\n const {\n children,\n size = 3,\n weight,\n align,\n className,\n asChild,\n as: Tag = 'span',\n color,\n html,\n ...textProps\n } = props\n\n const htmlContentProps = html\n ? {\n dangerouslySetInnerHTML: { __html: html },\n }\n : null\n\n const styleProps = color\n ? {\n style: {\n color,\n },\n }\n : null\n\n return (\n <Slot\n {...textProps}\n ref={forwardedRef}\n className={cn(\n textVariants({\n size,\n weight,\n align,\n }),\n className\n )}\n {...htmlContentProps}\n {...styleProps}\n >\n {asChild ? children : <Tag>{htmlContentProps ? null : children}</Tag>}\n </Slot>\n )\n})\nText.displayName = 'Text'\n\nexport { Text }\nexport type { TextProps }\n"],
|
|
5
|
+
"mappings": "AA2F4B,cAAAA,MAAA,oBA3F5B,UAAYC,MAAW,QACvB,OAAS,QAAAC,MAAY,uBACrB,OAAS,MAAAC,MAAU,sBACnB,OAA4B,OAAAC,MAAW,2BAGvC,MAAMC,EAAeD,EAAI,qBAAsB,CAC7C,SAAU,CACR,KAAM,CACJ,EAAG,gCACH,EAAG,gCACH,EAAG,+BACL,EACA,OAAQ,CACN,MAAO,aACP,OAAQ,cACR,OAAQ,cACR,SAAU,gBACV,KAAM,WACR,EACA,MAAO,CACL,KAAM,YACN,OAAQ,cACR,MAAO,YACT,CACF,EACA,gBAAiB,CACf,KAAM,EACN,OAAQ,QACV,CACF,CAAC,EAkBKE,EAAOL,EAAM,WAAmC,CAACM,EAAOC,IAAiB,CAC7E,KAAM,CACJ,SAAAC,EACA,KAAAC,EAAO,EACP,OAAAC,EACA,MAAAC,EACA,UAAAC,EACA,QAAAC,EACA,GAAIC,EAAM,OACV,MAAAC,EACA,KAAAC,EACA,GAAGC,CACL,EAAIX,EAEEY,EAAmBF,EACrB,CACA,wBAAyB,CAAE,OAAQA,CAAK,CAC1C,EACE,KAEEG,EAAaJ,EACf,CACA,MAAO,CACL,MAAAA,CACF,CACF,EACE,KAEJ,OACEhB,EAACE,EAAA,CACE,GAAGgB,EACJ,IAAKV,EACL,UAAWL,EACTE,EAAa,CACX,KAAAK,EACA,OAAAC,EACA,MAAAC,CACF,CAAC,EACDC,CACF,EACC,GAAGM,EACH,GAAGC,EAEH,SAAAN,EAAUL,EAAWT,EAACe,EAAA,CAAK,SAAAI,EAAmB,KAAOV,EAAS,EACjE,CAEJ,CAAC,EACDH,EAAK,YAAc",
|
|
6
|
+
"names": ["jsx", "React", "Slot", "cn", "cva", "textVariants", "Text", "props", "forwardedRef", "children", "size", "weight", "align", "className", "asChild", "Tag", "color", "html", "textProps", "htmlContentProps", "styleProps"]
|
|
7
7
|
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import type { Brand } from '../helpers/constants.js';
|
|
3
2
|
interface ThemeProps {
|
|
4
|
-
brand:
|
|
3
|
+
brand: string;
|
|
5
4
|
children: React.ReactNode;
|
|
6
5
|
}
|
|
7
6
|
/**
|
|
@@ -9,5 +8,5 @@ interface ThemeProps {
|
|
|
9
8
|
* @param param
|
|
10
9
|
* @returns
|
|
11
10
|
*/
|
|
12
|
-
declare const Theme: ({ brand, children }: ThemeProps) => import("react/jsx-runtime
|
|
11
|
+
declare const Theme: ({ brand, children }: ThemeProps) => import("react/jsx-runtime").JSX.Element;
|
|
13
12
|
export default Theme;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use client";import{Fragment as o,jsx as
|
|
1
|
+
"use client";import{Fragment as o,jsx as c}from"react/jsx-runtime";import*as r from"react";const a=({brand:e,children:t})=>(r.useLayoutEffect(()=>{document.querySelector("html")?.setAttribute("data-brand-theme",e)},[]),c(o,{children:t}));var n=a;export{n as default};
|
|
2
2
|
//# sourceMappingURL=theme.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/components/theme.tsx"],
|
|
4
|
-
"sourcesContent": ["'use client'\nimport * as React from 'react'\
|
|
5
|
-
"mappings": "
|
|
4
|
+
"sourcesContent": ["'use client'\nimport * as React from 'react'\n\ninterface ThemeProps {\n brand: string\n children: React.ReactNode\n}\n/**\n *\n * @param param\n * @returns\n */\nconst Theme = ({ brand, children }: ThemeProps) => {\n React.useLayoutEffect(() => {\n document.querySelector('html')?.setAttribute('data-brand-theme', brand)\n }, [])\n return <>{children}</>\n}\n\nexport default Theme\n"],
|
|
5
|
+
"mappings": "aAgBS,mBAAAA,EAAA,OAAAC,MAAA,oBAfT,UAAYC,MAAW,QAWvB,MAAMC,EAAQ,CAAC,CAAE,MAAAC,EAAO,SAAAC,CAAS,KAC/BH,EAAM,gBAAgB,IAAM,CAC1B,SAAS,cAAc,MAAM,GAAG,aAAa,mBAAoBE,CAAK,CACxE,EAAG,CAAC,CAAC,EACEH,EAAAD,EAAA,CAAG,SAAAK,EAAS,GAGrB,IAAOC,EAAQH",
|
|
6
6
|
"names": ["Fragment", "jsx", "React", "Theme", "brand", "children", "theme_default"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
var c=(b,a)=>()=>(a||b((a={exports:{}}).exports,a),a.exports);var d=c(()=>{});export default d();
|
|
2
2
|
//# sourceMappingURL=constants.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/helpers/constants.ts"],
|
|
4
|
-
"sourcesContent": ["
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": ["
|
|
4
|
+
"sourcesContent": [""],
|
|
5
|
+
"mappings": "8DAAA,IAAAA,EAAAC,EAAA",
|
|
6
|
+
"names": ["require_constants", "__commonJSMin"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{clsx as
|
|
1
|
+
import{clsx as t}from"clsx";import{extendTailwindMerge as n}from"tailwind-merge";const o=n({extend:{theme:{borderRadius:["btn"]}}});function i(...e){return o(t(e))}function s(){}export{i as cn,s as noop};
|
|
2
2
|
//# sourceMappingURL=utils.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/helpers/utils.ts"],
|
|
4
|
-
"sourcesContent": ["import { clsx, type ClassValue } from 'clsx'\nimport {
|
|
5
|
-
"mappings": "AAAA,OAAS,QAAAA,MAA6B,OACtC,OAAS,
|
|
6
|
-
"names": ["clsx", "twMerge", "cn", "inputs", "noop"]
|
|
4
|
+
"sourcesContent": ["import { clsx, type ClassValue } from 'clsx'\nimport { extendTailwindMerge } from 'tailwind-merge'\n\nconst twMerge = extendTailwindMerge({\n extend: {\n theme: {\n borderRadius: ['btn'],\n },\n },\n})\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n\nexport function noop(): any {}\n"],
|
|
5
|
+
"mappings": "AAAA,OAAS,QAAAA,MAA6B,OACtC,OAAS,uBAAAC,MAA2B,iBAEpC,MAAMC,EAAUD,EAAoB,CAClC,OAAQ,CACJ,MAAO,CACH,aAAc,CAAC,KAAK,CACxB,CACJ,CACF,CAAC,EAEM,SAASE,KAAMC,EAAsB,CAC1C,OAAOF,EAAQF,EAAKI,CAAM,CAAC,CAC7B,CAEO,SAASC,GAAY,CAAC",
|
|
6
|
+
"names": ["clsx", "extendTailwindMerge", "twMerge", "cn", "inputs", "noop"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as e}from"react/jsx-runtime";import{cn as r}from"../helpers/index.js";const s=n=>e("svg",{fill:"none",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",width:"1rem",className:r("
|
|
1
|
+
import{jsx as e}from"react/jsx-runtime";import{cn as r}from"../helpers/index.js";const s=n=>e("svg",{fill:"none",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",width:"1rem",className:r("animate-spin",n.className),children:e("path",{d:"M1 10C1 14.9706 5.02944 19 10 19C14.9706 19 19 14.9706 19 10C19 5.02944 14.9706 1 10 1",strokeWidth:"2",strokeLinecap:"round"})});var o=s;export{o as default};
|
|
2
2
|
//# sourceMappingURL=spinner.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/icons/spinner.tsx"],
|
|
4
|
-
"sourcesContent": ["import { cn } from '../helpers/index.js'\n\nexport interface SpinnerProps {\n className?: string\n}\n\n// eslint-disable-next-line no-unused-vars\nconst Spinner = (props: SpinnerProps) => {\n return (\n <svg\n fill=\"none\"\n viewBox=\"0 0 20 20\"\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"1rem\"\n className={cn('
|
|
5
|
-
"mappings": "AAgBM,cAAAA,MAAA,oBAhBN,OAAS,MAAAC,MAAU,sBAOnB,MAAMC,EAAWC,GAEbH,EAAC,OACC,KAAK,OACL,QAAQ,YACR,MAAM,6BACN,MAAM,OACN,UAAWC,EAAG,
|
|
4
|
+
"sourcesContent": ["import { cn } from '../helpers/index.js'\n\nexport interface SpinnerProps {\n className?: string\n}\n\n// eslint-disable-next-line no-unused-vars\nconst Spinner = (props: SpinnerProps) => {\n return (\n <svg\n fill=\"none\"\n viewBox=\"0 0 20 20\"\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"1rem\"\n className={cn('animate-spin', props.className)}\n >\n <path\n d=\"M1 10C1 14.9706 5.02944 19 10 19C14.9706 19 19 14.9706 19 10C19 5.02944 14.9706 1 10 1\"\n strokeWidth=\"2\"\n strokeLinecap=\"round\"\n />\n </svg>\n )\n}\n\nexport default Spinner\n"],
|
|
5
|
+
"mappings": "AAgBM,cAAAA,MAAA,oBAhBN,OAAS,MAAAC,MAAU,sBAOnB,MAAMC,EAAWC,GAEbH,EAAC,OACC,KAAK,OACL,QAAQ,YACR,MAAM,6BACN,MAAM,OACN,UAAWC,EAAG,eAAgBE,EAAM,SAAS,EAE7C,SAAAH,EAAC,QACC,EAAE,yFACF,YAAY,IACZ,cAAc,QAChB,EACF,EAIJ,IAAOI,EAAQF",
|
|
6
6
|
"names": ["jsx", "cn", "Spinner", "props", "spinner_default"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface StylesProps {
|
|
3
|
+
/** 自定义样式字符串 */
|
|
4
|
+
style?: string;
|
|
5
|
+
/** 唯一标识符 */
|
|
6
|
+
uid?: string;
|
|
7
|
+
/** 是否禁用 */
|
|
8
|
+
disabled?: boolean;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* 从组件 props 中提取样式相关属性
|
|
12
|
+
*/
|
|
13
|
+
export declare const getStylesProps: <T extends Record<string, unknown>>(props: T & StylesProps) => StylesProps;
|
|
14
|
+
/**
|
|
15
|
+
* 样式 Hook,返回样式类名和样式组件
|
|
16
|
+
* @param styleProps - 样式属性
|
|
17
|
+
*/
|
|
18
|
+
export declare const useStyles: (styleProps?: Partial<StylesProps>) => {
|
|
19
|
+
readonly className: `block-${string}`;
|
|
20
|
+
readonly StyleComponent: import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
readonly uid: string;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* 样式高阶组件, 用于给组件用style 标签的形式追加样式
|
|
25
|
+
* @param WrappedComponent - 需要包装的组件
|
|
26
|
+
* @param defaultStyleProps - 默认样式属性
|
|
27
|
+
*/
|
|
28
|
+
export declare function withStyles<P extends object>(WrappedComponent: React.ComponentType<P>, defaultStyleProps?: Partial<StylesProps>): {
|
|
29
|
+
(props: Omit<P, keyof StylesProps> & Partial<StylesProps>): import("react/jsx-runtime").JSX.Element;
|
|
30
|
+
displayName: string;
|
|
31
|
+
};
|
|
32
|
+
declare const _default: React.NamedExoticComponent<StylesProps>;
|
|
33
|
+
export default _default;
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{Fragment as m,jsx as o,jsxs as P}from"react/jsx-runtime";import u,{useMemo as l}from"react";const r=()=>`style_${Math.random().toString(36).substring(2,9)}_${Date.now().toString(36)}`,S=t=>{const{style:e,uid:s,disabled:n}=t;return{style:e,uid:s,disabled:n}},a=({style:t,uid:e=r(),disabled:s=!1})=>!t||s?null:o("style",{"data-style-id":e,children:`.block-${e} { ${t} }`}),d=t=>{const e=l(()=>t?.uid||r(),[t?.uid]),s=l(()=>o(a,{...t,uid:e}),[t,e]);return{className:`block-${e}`,StyleComponent:s,uid:e}};function f(t,e){const s=function(n){const i={...e,...S(n)},{className:c,StyleComponent:y}=d(i);return P(m,{children:[y,o(t,{...n,className:c})]})};return s.displayName=t.displayName||t.name||"Component",s}var g=u.memo(a);export{g as default,S as getStylesProps,d as useStyles,f as withStyles};
|
|
2
|
+
//# sourceMappingURL=Styles.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/shared/Styles.tsx"],
|
|
4
|
+
"sourcesContent": ["import React, { useMemo } from 'react';\n\nexport interface StylesProps {\n /** \u81EA\u5B9A\u4E49\u6837\u5F0F\u5B57\u7B26\u4E32 */\n style?: string;\n /** \u552F\u4E00\u6807\u8BC6\u7B26 */\n uid?: string;\n /** \u662F\u5426\u7981\u7528 */\n disabled?: boolean;\n}\n\n/**\n * \u751F\u6210\u552F\u4E00\u6807\u8BC6\u7B26\n */\nconst generateUID = () => {\n return `style_${Math.random().toString(36).substring(2, 9)}_${Date.now().toString(36)}`;\n};\n\n/**\n * \u4ECE\u7EC4\u4EF6 props \u4E2D\u63D0\u53D6\u6837\u5F0F\u76F8\u5173\u5C5E\u6027\n */\nexport const getStylesProps = <T extends Record<string, unknown>>(props: T & StylesProps): StylesProps => {\n const { style, uid, disabled } = props;\n return { style, uid, disabled };\n};\n\n/**\n * \u6837\u5F0F\u6CE8\u5165\u7EC4\u4EF6\n */\nconst Styles: React.FC<StylesProps> = ({\n style,\n uid = generateUID(),\n disabled = false,\n}) => {\n if (!style || disabled) {\n return null;\n }\n\n return (\n <style data-style-id={uid}>\n {`.block-${uid} { ${style} }`}\n </style>\n );\n};\n\n/**\n * \u6837\u5F0F Hook\uFF0C\u8FD4\u56DE\u6837\u5F0F\u7C7B\u540D\u548C\u6837\u5F0F\u7EC4\u4EF6\n * @param styleProps - \u6837\u5F0F\u5C5E\u6027\n */\nexport const useStyles = (styleProps?: Partial<StylesProps>) => {\n const uid = useMemo(() => styleProps?.uid || generateUID(), [styleProps?.uid]);\n \n const StyleComponent = useMemo(() => (\n <Styles {...styleProps} uid={uid} />\n ), [styleProps, uid]);\n\n return {\n className: `block-${uid}`,\n StyleComponent,\n uid\n } as const;\n};\n\n/**\n * \u6837\u5F0F\u9AD8\u9636\u7EC4\u4EF6\uFF0C \u7528\u4E8E\u7ED9\u7EC4\u4EF6\u7528style \u6807\u7B7E\u7684\u5F62\u5F0F\u8FFD\u52A0\u6837\u5F0F\n * @param WrappedComponent - \u9700\u8981\u5305\u88C5\u7684\u7EC4\u4EF6\n * @param defaultStyleProps - \u9ED8\u8BA4\u6837\u5F0F\u5C5E\u6027\n */\nexport function withStyles<P extends object>(\n WrappedComponent: React.ComponentType<P>,\n defaultStyleProps?: Partial<StylesProps>\n) {\n const WithStyles = function(props: Omit<P, keyof StylesProps> & Partial<StylesProps>) {\n const finalStyleProps = {\n ...defaultStyleProps,\n ...getStylesProps(props)\n };\n\n const { className, StyleComponent } = useStyles(finalStyleProps);\n\n return (\n <>\n {StyleComponent}\n <WrappedComponent {...(props as P)} className={className} />\n </>\n );\n };\n\n // \u76F4\u63A5\u4F7F\u7528\u539F\u59CB\u7EC4\u4EF6\u7684\u540D\u79F0\n WithStyles.displayName = WrappedComponent.displayName || WrappedComponent.name || 'Component';\n return WithStyles;\n}\n\nexport default React.memo(Styles);"],
|
|
5
|
+
"mappings": "AAuCI,OA0CE,YAAAA,EA1CF,OAAAC,EA0CE,QAAAC,MA1CF,oBAvCJ,OAAOC,GAAS,WAAAC,MAAe,QAc/B,MAAMC,EAAc,IACX,SAAS,KAAK,OAAO,EAAE,SAAS,EAAE,EAAE,UAAU,EAAG,CAAC,CAAC,IAAI,KAAK,IAAI,EAAE,SAAS,EAAE,CAAC,GAM1EC,EAAqDC,GAAwC,CACxG,KAAM,CAAE,MAAAC,EAAO,IAAAC,EAAK,SAAAC,CAAS,EAAIH,EACjC,MAAO,CAAE,MAAAC,EAAO,IAAAC,EAAK,SAAAC,CAAS,CAChC,EAKMC,EAAgC,CAAC,CACrC,MAAAH,EACA,IAAAC,EAAMJ,EAAY,EAClB,SAAAK,EAAW,EACb,IACM,CAACF,GAASE,EACL,KAIPT,EAAC,SAAM,gBAAeQ,EACnB,mBAAUA,CAAG,MAAMD,CAAK,KAC3B,EAQSI,EAAaC,GAAsC,CAC9D,MAAMJ,EAAML,EAAQ,IAAMS,GAAY,KAAOR,EAAY,EAAG,CAACQ,GAAY,GAAG,CAAC,EAEvEC,EAAiBV,EAAQ,IAC7BH,EAACU,EAAA,CAAQ,GAAGE,EAAY,IAAKJ,EAAK,EACjC,CAACI,EAAYJ,CAAG,CAAC,EAEpB,MAAO,CACL,UAAW,SAASA,CAAG,GACvB,eAAAK,EACA,IAAAL,CACF,CACF,EAOO,SAASM,EACdC,EACAC,EACA,CACA,MAAMC,EAAa,SAASX,EAA0D,CACpF,MAAMY,EAAkB,CACtB,GAAGF,EACH,GAAGX,EAAeC,CAAK,CACzB,EAEM,CAAE,UAAAa,EAAW,eAAAN,CAAe,EAAIF,EAAUO,CAAe,EAE/D,OACEjB,EAAAF,EAAA,CACG,UAAAc,EACDb,EAACe,EAAA,CAAkB,GAAIT,EAAa,UAAWa,EAAW,GAC5D,CAEJ,EAGA,OAAAF,EAAW,YAAcF,EAAiB,aAAeA,EAAiB,MAAQ,YAC3EE,CACT,CAEA,IAAOG,EAAQlB,EAAM,KAAKQ,CAAM",
|
|
6
|
+
"names": ["Fragment", "jsx", "jsxs", "React", "useMemo", "generateUID", "getStylesProps", "props", "style", "uid", "disabled", "Styles", "useStyles", "styleProps", "StyleComponent", "withStyles", "WrappedComponent", "defaultStyleProps", "WithStyles", "finalStyleProps", "className", "Styles_default"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import HeroBanner from '../biz-components/HeroBanner/HeroBanner.js';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: {
|
|
6
|
+
(props: Omit<import("../biz-components/HeroBanner/types.js").HeroBannerProps & import("react").RefAttributes<HTMLDivElement>, keyof import("../shared/Styles.js").StylesProps> & Partial<import("../shared/Styles.js").StylesProps>): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
displayName: string;
|
|
8
|
+
};
|
|
9
|
+
parameters: {
|
|
10
|
+
layout: string;
|
|
11
|
+
docs: {
|
|
12
|
+
description: {
|
|
13
|
+
component: string;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
tags: string[];
|
|
18
|
+
};
|
|
19
|
+
export default meta;
|
|
20
|
+
type Story = StoryObj<typeof HeroBanner>;
|
|
21
|
+
export declare const LightTheme: Story;
|
|
22
|
+
export declare const DarkTheme: Story;
|
|
23
|
+
export declare const WithoutSecondaryButton: Story;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import t from"../biz-components/HeroBanner/HeroBanner.js";const o={title:"Biz-Components/HeroBanner",component:t,parameters:{layout:"fullscreen",docs:{description:{component:`
|
|
2
|
+
HeroBanner \u7EC4\u4EF6\u7528\u4E8E\u5C55\u793A\u7F51\u7AD9\u7684\u4E3B\u8981\u5185\u5BB9\u533A\u57DF\uFF0C\u901A\u5E38\u5305\u542B\u6807\u9898\u3001\u526F\u6807\u9898\u548C\u884C\u52A8\u6309\u94AE\u3002
|
|
3
|
+
|
|
4
|
+
### \u7279\u70B9
|
|
5
|
+
- \u652F\u6301\u4EAE\u8272\u548C\u6697\u8272\u4E3B\u9898
|
|
6
|
+
- \u4F7F\u7528 Mont For Anker \u5B57\u4F53\u4F5C\u4E3A\u6807\u9898
|
|
7
|
+
- \u53EF\u914D\u7F6E\u4E3B\u6309\u94AE\u548C\u6B21\u8981\u6309\u94AE
|
|
8
|
+
- \u652F\u6301\u5E95\u90E8\u4EA7\u54C1\u5217\u8868
|
|
9
|
+
`}}},tags:["autodocs"]};var n=o;const e="https://cdn.shopify.com/s/files/1/0521/9411/5753/files/aee13b30b2c77fc8d0a46e4f19fa48cb_6a25debf-f95e-4ca6-990b-babcad65216c.png?v=1745468206",a={args:{title:"Anker Laptop Power",subtitle:"Anker Prime 240W GaN Desktop Charger (4 Ports)",background:e,theme:"light",primaryButton:{text:"Shop Now",onClick:()=>console.log("Primary button clicked")},secondaryButton:{text:"Learn More",onClick:()=>console.log("Secondary button clicked")},products:[{title:"Anker Prime 240W GaN Desktop Charger (4 Ports)",active:!0},{title:"Anker Prime 27,650mAh Power Bank (250W)"},{title:"Anker Prime 240W GaN Desktop Charger (4 Ports)"}]}},i={args:{title:"Power Your Life",subtitle:"Experience the next generation of charging technology with our innovative solutions designed for modern life.",background:e,theme:"dark",primaryButton:{text:"Shop Now",onClick:()=>console.log("Primary button clicked")},secondaryButton:{text:"Learn More",onClick:()=>console.log("Secondary button clicked")}}},c={args:{title:"Future of Charging",subtitle:"Step into the future with our revolutionary charging solutions that redefine the way you power your devices.",background:e,theme:"dark",primaryButton:{text:"Shop Now",onClick:()=>console.log("Primary button clicked")},products:[{title:"Anker Prime 240W GaN Desktop Charger (4 Ports)"},{title:"Anker Prime 27,650mAh Power Bank (250W)"},{title:"Anker Prime 240W GaN Desktop Charger (4 Ports)"}]}};export{i as DarkTheme,a as LightTheme,c as WithoutSecondaryButton,n as default};
|
|
10
|
+
//# sourceMappingURL=HeroBanner.stories.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/stories/HeroBanner.stories.tsx"],
|
|
4
|
+
"sourcesContent": ["import type { Meta, StoryObj } from '@storybook/react'\nimport HeroBanner from '../biz-components/HeroBanner/HeroBanner.js'\n\nconst meta = {\n title: 'Biz-Components/HeroBanner',\n component: HeroBanner,\n parameters: {\n layout: 'fullscreen',\n docs: {\n description: {\n component: `\nHeroBanner \u7EC4\u4EF6\u7528\u4E8E\u5C55\u793A\u7F51\u7AD9\u7684\u4E3B\u8981\u5185\u5BB9\u533A\u57DF\uFF0C\u901A\u5E38\u5305\u542B\u6807\u9898\u3001\u526F\u6807\u9898\u548C\u884C\u52A8\u6309\u94AE\u3002\n\n### \u7279\u70B9\n- \u652F\u6301\u4EAE\u8272\u548C\u6697\u8272\u4E3B\u9898\n- \u4F7F\u7528 Mont For Anker \u5B57\u4F53\u4F5C\u4E3A\u6807\u9898\n- \u53EF\u914D\u7F6E\u4E3B\u6309\u94AE\u548C\u6B21\u8981\u6309\u94AE\n- \u652F\u6301\u5E95\u90E8\u4EA7\u54C1\u5217\u8868\n `,\n },\n },\n },\n tags: ['autodocs'],\n} satisfies Meta<typeof HeroBanner>\n\nexport default meta\ntype Story = StoryObj<typeof HeroBanner>\n\nconst defaultBackground = \"https://cdn.shopify.com/s/files/1/0521/9411/5753/files/aee13b30b2c77fc8d0a46e4f19fa48cb_6a25debf-f95e-4ca6-990b-babcad65216c.png?v=1745468206\"\n\nexport const LightTheme: Story = {\n args: {\n title: \"Anker Laptop Power\",\n subtitle: \"Anker Prime 240W GaN Desktop Charger (4 Ports)\",\n background: defaultBackground,\n theme: \"light\",\n primaryButton: {\n text: \"Shop Now\",\n onClick: () => console.log(\"Primary button clicked\")\n },\n secondaryButton: {\n text: \"Learn More\",\n onClick: () => console.log(\"Secondary button clicked\")\n },\n products: [\n { title: \"Anker Prime 240W GaN Desktop Charger (4 Ports)\", active: true },\n { title: \"Anker Prime 27,650mAh Power Bank (250W)\" },\n { title: \"Anker Prime 240W GaN Desktop Charger (4 Ports)\" }\n ]\n }\n}\n\nexport const DarkTheme: Story = {\n args: {\n title: \"Power Your Life\",\n subtitle: \"Experience the next generation of charging technology with our innovative solutions designed for modern life.\",\n background: defaultBackground,\n theme: \"dark\",\n primaryButton: {\n text: \"Shop Now\",\n onClick: () => console.log(\"Primary button clicked\")\n },\n secondaryButton: {\n text: \"Learn More\",\n onClick: () => console.log(\"Secondary button clicked\")\n }\n }\n}\n\nexport const WithoutSecondaryButton: Story = {\n args: {\n title: \"Future of Charging\",\n subtitle: \"Step into the future with our revolutionary charging solutions that redefine the way you power your devices.\",\n background: defaultBackground,\n theme: \"dark\",\n primaryButton: {\n text: \"Shop Now\",\n onClick: () => console.log(\"Primary button clicked\")\n },\n products: [\n { title: \"Anker Prime 240W GaN Desktop Charger (4 Ports)\" },\n { title: \"Anker Prime 27,650mAh Power Bank (250W)\" },\n { title: \"Anker Prime 240W GaN Desktop Charger (4 Ports)\" }\n ]\n }\n} "],
|
|
5
|
+
"mappings": "AACA,OAAOA,MAAgB,6CAEvB,MAAMC,EAAO,CACX,MAAO,4BACP,UAAWD,EACX,WAAY,CACV,OAAQ,aACR,KAAM,CACJ,YAAa,CACX,UAAW;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,SASb,CACF,CACF,EACA,KAAM,CAAC,UAAU,CACnB,EAEA,IAAOE,EAAQD,EAGf,MAAME,EAAoB,gJAEbC,EAAoB,CAC/B,KAAM,CACJ,MAAO,qBACP,SAAU,iDACV,WAAYD,EACZ,MAAO,QACP,cAAe,CACb,KAAM,WACN,QAAS,IAAM,QAAQ,IAAI,wBAAwB,CACrD,EACA,gBAAiB,CACf,KAAM,aACN,QAAS,IAAM,QAAQ,IAAI,0BAA0B,CACvD,EACA,SAAU,CACR,CAAE,MAAO,iDAAkD,OAAQ,EAAK,EACxE,CAAE,MAAO,yCAA0C,EACnD,CAAE,MAAO,gDAAiD,CAC5D,CACF,CACF,EAEaE,EAAmB,CAC9B,KAAM,CACJ,MAAO,kBACP,SAAU,gHACV,WAAYF,EACZ,MAAO,OACP,cAAe,CACb,KAAM,WACN,QAAS,IAAM,QAAQ,IAAI,wBAAwB,CACrD,EACA,gBAAiB,CACf,KAAM,aACN,QAAS,IAAM,QAAQ,IAAI,0BAA0B,CACvD,CACF,CACF,EAEaG,EAAgC,CAC3C,KAAM,CACJ,MAAO,qBACP,SAAU,+GACV,WAAYH,EACZ,MAAO,OACP,cAAe,CACb,KAAM,WACN,QAAS,IAAM,QAAQ,IAAI,wBAAwB,CACrD,EACA,SAAU,CACR,CAAE,MAAO,gDAAiD,EAC1D,CAAE,MAAO,yCAA0C,EACnD,CAAE,MAAO,gDAAiD,CAC5D,CACF,CACF",
|
|
6
|
+
"names": ["HeroBanner", "meta", "HeroBanner_stories_default", "defaultBackground", "LightTheme", "DarkTheme", "WithoutSecondaryButton"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import MemberEquity from '../biz-components/MemberEquity';
|
|
3
|
+
declare const meta: Meta<typeof MemberEquity>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof MemberEquity>;
|
|
6
|
+
export declare const Default: Story;
|
|
7
|
+
export declare const Round: Story;
|
|
8
|
+
export declare const CustomButtons: Story;
|
|
9
|
+
export declare const CustomStyles: Story;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import t from"../biz-components/MemberEquity";const o={title:"Biz-Components/MemberEquity",component:t,parameters:{layout:"fullscreen",docs:{description:{component:`
|
|
2
|
+
MemberEquity \u7EC4\u4EF6\u662F\u7528\u4E8E\u5C55\u793A\u4F1A\u5458\u6743\u76CA\u7684\u7EC4\u4EF6\u3002
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### \u81EA\u5B9A\u4E49style \u53EF\u7528class
|
|
6
|
+
.member-equity-title
|
|
7
|
+
.member-equity-description
|
|
8
|
+
.member-equity-button-primary
|
|
9
|
+
.member-equity-button-secondary
|
|
10
|
+
`}}},tags:["autodocs"]};var s=o;const e={args:{title:"Become a Member Today",description:"Gain early access to new products, exclusive deals, and opportunities to try our products for free.",backgroundImage:"https://images.unsplash.com/photo-1484807352052-23338990c6c6",primaryButton:{text:"Shop Now",href:"/shop"},secondaryButton:{text:"Learn More",href:"/learn"},shape:"square"}},n={args:{...e.args,title:"Join Our Family",description:"Get exclusive access to new products and special member-only discounts.",backgroundImage:"https://images.unsplash.com/photo-1558002038-1055907df827",shape:"round"}},a={args:{...e.args,title:"Premium Experience",description:"Join our community to get early access to new products and exclusive member benefits.",backgroundImage:"https://images.unsplash.com/photo-1505740420928-5e560c06d30e",primaryButton:{text:"Join Now",href:"/join"},secondaryButton:{text:"Explore Benefits",href:"/benefits"}}},i={args:{...e.args,title:"Become a Member Today and opportunities",style:`
|
|
11
|
+
.member-equity-title {
|
|
12
|
+
background: linear-gradient(
|
|
13
|
+
90deg,
|
|
14
|
+
#FFD700, /* \u91D1\u8272 (Gold) */
|
|
15
|
+
#FFC000, /* \u4EAE\u91D1\u8272 (Light Gold) */
|
|
16
|
+
#FFA500, /* \u6A59\u8272 (Orange) */
|
|
17
|
+
#FF8C00, /* \u6DF1\u6A59\u8272 (Dark Orange) */
|
|
18
|
+
#FF6B00 /* \u6A59\u7EA2\u8272 (Red-Orange) */
|
|
19
|
+
);
|
|
20
|
+
-webkit-background-clip: text; /* \u517C\u5BB9 WebKit \u6D4F\u89C8\u5668 */
|
|
21
|
+
background-clip: text;
|
|
22
|
+
color: transparent; /* \u9690\u85CF\u539F\u59CB\u6587\u5B57\u989C\u8272 */
|
|
23
|
+
}
|
|
24
|
+
.member-equity-description {
|
|
25
|
+
color: blue;
|
|
26
|
+
}
|
|
27
|
+
.member-equity-button-primary {
|
|
28
|
+
color: green;
|
|
29
|
+
}
|
|
30
|
+
`,event:{}}};export{a as CustomButtons,i as CustomStyles,e as Default,n as Round,s as default};
|
|
31
|
+
//# sourceMappingURL=MemberEquity.stories.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/stories/MemberEquity.stories.tsx"],
|
|
4
|
+
"sourcesContent": ["import type { Meta, StoryObj } from '@storybook/react';\nimport MemberEquity from '../biz-components/MemberEquity';\n\nconst meta: Meta<typeof MemberEquity> = {\n title: 'Biz-Components/MemberEquity',\n component: MemberEquity,\n parameters: {\n layout: 'fullscreen',\n docs: {\n description: {\n component: ` \nMemberEquity \u7EC4\u4EF6\u662F\u7528\u4E8E\u5C55\u793A\u4F1A\u5458\u6743\u76CA\u7684\u7EC4\u4EF6\u3002 \n\n\n### \u81EA\u5B9A\u4E49style \u53EF\u7528class \n.member-equity-title \n.member-equity-description \n.member-equity-button-primary \n.member-equity-button-secondary \n `,\n },\n },\n },\n tags: ['autodocs'],\n};\n\nexport default meta;\ntype Story = StoryObj<typeof MemberEquity>;\n\n// \u9ED8\u8BA4\u6837\u5F0F - \u65B9\u5F62\nexport const Default: Story = {\n args: {\n title: 'Become a Member Today',\n description: 'Gain early access to new products, exclusive deals, and opportunities to try our products for free.',\n backgroundImage: 'https://images.unsplash.com/photo-1484807352052-23338990c6c6',\n primaryButton: {\n text: 'Shop Now',\n href: '/shop',\n },\n secondaryButton: {\n text: 'Learn More',\n href: '/learn',\n },\n shape: 'square',\n },\n};\n\n// \u5706\u89D2\u98CE\u683C\nexport const Round: Story = {\n args: {\n ...Default.args,\n title: 'Join Our Family',\n description: 'Get exclusive access to new products and special member-only discounts.',\n backgroundImage: 'https://images.unsplash.com/photo-1558002038-1055907df827',\n shape: 'round',\n },\n};\n\n// \u81EA\u5B9A\u4E49\u6309\u94AE\nexport const CustomButtons: Story = {\n args: {\n ...Default.args,\n title: 'Premium Experience',\n description: 'Join our community to get early access to new products and exclusive member benefits.',\n backgroundImage: 'https://images.unsplash.com/photo-1505740420928-5e560c06d30e',\n primaryButton: {\n text: 'Join Now',\n href: '/join',\n },\n secondaryButton: {\n text: 'Explore Benefits',\n href: '/benefits',\n },\n },\n};\n\n// \u81EA\u5B9A\u4E49\u6837\u5F0F\nexport const CustomStyles: Story = {\n args: {\n ...Default.args,\n title: 'Become a Member Today and opportunities',\n style: `\n .member-equity-title {\n background: linear-gradient(\n 90deg,\n #FFD700, /* \u91D1\u8272 (Gold) */\n #FFC000, /* \u4EAE\u91D1\u8272 (Light Gold) */\n #FFA500, /* \u6A59\u8272 (Orange) */\n #FF8C00, /* \u6DF1\u6A59\u8272 (Dark Orange) */\n #FF6B00 /* \u6A59\u7EA2\u8272 (Red-Orange) */\n );\n -webkit-background-clip: text; /* \u517C\u5BB9 WebKit \u6D4F\u89C8\u5668 */\n background-clip: text;\n color: transparent; /* \u9690\u85CF\u539F\u59CB\u6587\u5B57\u989C\u8272 */\n }\n .member-equity-description {\n color: blue;\n }\n .member-equity-button-primary {\n color: green;\n }\n `,\n event: {\n\n }\n },\n}; "],
|
|
5
|
+
"mappings": "AACA,OAAOA,MAAkB,iCAEzB,MAAMC,EAAkC,CACtC,MAAO,8BACP,UAAWD,EACX,WAAY,CACV,OAAQ,aACR,KAAM,CACJ,YAAa,CACX,UAAW;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,OAUb,CACF,CACF,EACA,KAAM,CAAC,UAAU,CACnB,EAEA,IAAOE,EAAQD,EAIR,MAAME,EAAiB,CAC5B,KAAM,CACJ,MAAO,wBACP,YAAa,sGACb,gBAAiB,+DACjB,cAAe,CACb,KAAM,WACN,KAAM,OACR,EACA,gBAAiB,CACf,KAAM,aACN,KAAM,QACR,EACA,MAAO,QACT,CACF,EAGaC,EAAe,CAC1B,KAAM,CACJ,GAAGD,EAAQ,KACX,MAAO,kBACP,YAAa,0EACb,gBAAiB,4DACjB,MAAO,OACT,CACF,EAGaE,EAAuB,CAClC,KAAM,CACJ,GAAGF,EAAQ,KACX,MAAO,qBACP,YAAa,wFACb,gBAAiB,+DACjB,cAAe,CACb,KAAM,WACN,KAAM,OACR,EACA,gBAAiB,CACf,KAAM,mBACN,KAAM,WACR,CACF,CACF,EAGaG,EAAsB,CACjC,KAAM,CACJ,GAAGH,EAAQ,KACX,MAAO,0CACP,MAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,MAqBP,MAAO,CAEP,CACF,CACF",
|
|
6
|
+
"names": ["MemberEquity", "meta", "MemberEquity_stories_default", "Default", "Round", "CustomButtons", "CustomStyles"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & import("class-variance-authority").VariantProps<(props?: ({
|
|
6
|
+
variant?: "default" | "destructive" | null | undefined;
|
|
7
|
+
} & import("class-variance-authority/dist/types.js").ClassProp) | undefined) => string> & {
|
|
8
|
+
status?: "success" | "error" | "warning" | "info";
|
|
9
|
+
closable?: boolean;
|
|
10
|
+
} & React.RefAttributes<HTMLDivElement>>;
|
|
11
|
+
subcomponents: {
|
|
12
|
+
AlertTitle: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLHeadingElement> & React.RefAttributes<HTMLParagraphElement>>;
|
|
13
|
+
AlertDescription: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLParagraphElement> & React.RefAttributes<HTMLParagraphElement>>;
|
|
14
|
+
};
|
|
15
|
+
parameters: {
|
|
16
|
+
layout: string;
|
|
17
|
+
docs: {
|
|
18
|
+
description: {
|
|
19
|
+
component: string;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
tags: string[];
|
|
24
|
+
};
|
|
25
|
+
export default meta;
|
|
26
|
+
type Story = StoryObj<typeof meta>;
|
|
27
|
+
export declare const Default: Story;
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{Fragment as i,jsx as o,jsxs as c}from"react/jsx-runtime";import{Alert as r,AlertDescription as t,AlertTitle as e}from"../components/index.js";import"react";const s={title:"Components/Alert",component:r,subcomponents:{AlertTitle:e,AlertDescription:t},parameters:{layout:"centered",docs:{description:{component:"Alert component"}}},tags:["autodocs"]};var l=s;const m={args:{status:"success",closable:!0,children:c(i,{children:[o(e,{children:"Success"}),o(t,{children:"This is related to general message notifications with supporting text descriptions."})]})}};export{m as Default,l as default};
|
|
2
|
+
//# sourceMappingURL=alert.stories.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/stories/alert.stories.tsx"],
|
|
4
|
+
"sourcesContent": ["import type { Meta, StoryObj } from '@storybook/react'\n\nimport { Alert, AlertDescription, AlertTitle } from '../components/index.js'\nimport React from 'react'\n\nconst meta = {\n title: 'Components/Alert',\n component: Alert,\n subcomponents: {\n AlertTitle,\n AlertDescription,\n },\n parameters: {\n layout: 'centered',\n docs: {\n description: {\n component: 'Alert component',\n },\n },\n },\n tags: ['autodocs'],\n} satisfies Meta<typeof Alert>\n\nexport default meta\n\ntype Story = StoryObj<typeof meta>\n\nexport const Default: Story = {\n args: {\n status: 'success',\n closable: true,\n children: (\n <>\n <AlertTitle>Success</AlertTitle>\n <AlertDescription>\n This is related to general message notifications with supporting text descriptions.\n </AlertDescription>\n </>\n ),\n },\n}\n"],
|
|
5
|
+
"mappings": "AAgCM,mBAAAA,EACE,OAAAC,EADF,QAAAC,MAAA,oBA9BN,OAAS,SAAAC,EAAO,oBAAAC,EAAkB,cAAAC,MAAkB,yBACpD,MAAkB,QAElB,MAAMC,EAAO,CACX,MAAO,mBACP,UAAWH,EACX,cAAe,CACb,WAAAE,EACA,iBAAAD,CACF,EACA,WAAY,CACV,OAAQ,WACR,KAAM,CACJ,YAAa,CACX,UAAW,iBACb,CACF,CACF,EACA,KAAM,CAAC,UAAU,CACnB,EAEA,IAAOG,EAAQD,EAIR,MAAME,EAAiB,CAC5B,KAAM,CACJ,OAAQ,UACR,SAAU,GACV,SACEN,EAAAF,EAAA,CACE,UAAAC,EAACI,EAAA,CAAW,mBAAO,EACnBJ,EAACG,EAAA,CAAiB,+FAElB,GACF,CAEJ,CACF",
|
|
6
|
+
"names": ["Fragment", "jsx", "jsxs", "Alert", "AlertDescription", "AlertTitle", "meta", "alert_stories_default", "Default"]
|
|
7
|
+
}
|