trepur_components 0.4.7 → 1.0.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/dist/components/Accordion/Accordion.stories.tsx +88 -0
- package/dist/components/Accordion/index.tsx +31 -0
- package/dist/components/AlertBar/AlertBar.stories.tsx +105 -0
- package/dist/components/AlertBar/index.tsx +127 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.stories.tsx +60 -0
- package/dist/components/Breadcrumbs/index.tsx +55 -0
- package/dist/components/BreadcrumbsBordered/BreadcrumbsBordered.stories.tsx +52 -0
- package/dist/components/BreadcrumbsBordered/index.tsx +44 -0
- package/dist/components/BreadcrumbsItem/BreadcrumbsItem.stories.tsx +54 -0
- package/dist/components/BreadcrumbsItem/index.tsx +151 -0
- package/dist/components/Button/button.stories.tsx +148 -0
- package/dist/components/Button/index.tsx +91 -0
- package/dist/components/Card/Card.stories.tsx +150 -0
- package/dist/components/Card/index.tsx +162 -0
- package/dist/components/CardWithTopImage/CardWithTopImage.stories.tsx +48 -0
- package/dist/components/CardWithTopImage/index.tsx +40 -0
- package/dist/components/Carousel/Carousel.stories.tsx +369 -0
- package/dist/components/Carousel/index.tsx +267 -0
- package/dist/components/ChevronCard/ChevronCard.stories.tsx +21 -0
- package/dist/components/ChevronCard/index.tsx +39 -0
- package/dist/components/Collapsible/Collapsible.stories.tsx +70 -0
- package/dist/components/Collapsible/index.tsx +124 -0
- package/dist/components/Column/Column.stories.tsx +82 -0
- package/dist/components/Column/index.tsx +114 -0
- package/dist/components/Container/Container.stories.tsx +38 -0
- package/dist/components/Container/index.tsx +30 -0
- package/dist/components/FooterBar/footerBar.stories.tsx +57 -0
- package/dist/components/FooterBar/index.tsx +44 -0
- package/dist/components/Form/Form.stories.tsx +93 -0
- package/dist/components/Form/index.tsx +58 -0
- package/dist/components/FyreCard/FyreCard.stories.tsx +29 -0
- package/dist/components/FyreCard/index.tsx +46 -0
- package/dist/components/Greeting/Greeting.stories.tsx +42 -0
- package/dist/components/Greeting/index.tsx +46 -0
- package/dist/components/HamburgerIcon/HamburgerIcon.stories.tsx +50 -0
- package/dist/components/HamburgerIcon/index.tsx +65 -0
- package/dist/components/Icon/Icon.stories.tsx +102 -0
- package/dist/components/Icon/index.tsx +112 -0
- package/dist/components/Image/Image.stories.tsx +88 -0
- package/dist/components/Image/index.tsx +113 -0
- package/dist/components/ImageLink/ImageLink.stories.tsx +60 -0
- package/dist/components/ImageLink/index.tsx +62 -0
- package/dist/components/ImageLinkList/ImageLinkList.stories.tsx +32 -0
- package/dist/components/ImageLinkList/index.tsx +33 -0
- package/dist/components/InformationIcon/InformationIcon.stories.tsx +86 -0
- package/dist/components/InformationIcon/index.tsx +84 -0
- package/dist/components/Input/Input.stories.tsx +99 -0
- package/dist/components/Input/index.tsx +126 -0
- package/dist/components/Jumbotron/Jumbotron.stories.tsx +22 -0
- package/dist/components/Jumbotron/index.tsx +25 -0
- package/dist/components/Nav/Nav.stories.tsx +155 -0
- package/dist/components/Nav/index.tsx +180 -0
- package/dist/components/NavItem/NavItem.stories.tsx +89 -0
- package/dist/components/NavItem/index.tsx +65 -0
- package/dist/components/NewsCard/NewsCard.stories.tsx +71 -0
- package/dist/components/NewsCard/index.tsx +48 -0
- package/dist/components/Profile/Profile.stories.tsx +50 -0
- package/dist/components/Profile/index.tsx +87 -0
- package/dist/components/Row/Row.stories.tsx +51 -0
- package/dist/components/Row/index.tsx +24 -0
- package/dist/components/Search/Search.stories.tsx +58 -0
- package/dist/components/Search/index.tsx +58 -0
- package/dist/components/SocialBlock/SocialBlock.stories.tsx +114 -0
- package/dist/components/SocialBlock/index.tsx +161 -0
- package/dist/components/StarRating/StarRating.stories.tsx +23 -0
- package/dist/components/StarRating/index.tsx +71 -0
- package/dist/components/Testimonial/Testimonial.stories.tsx +110 -0
- package/dist/components/Testimonial/index.tsx +50 -0
- package/dist/components/TextAndTitle/TextAndTitle.stories.tsx +65 -0
- package/dist/components/TextAndTitle/index.tsx +257 -0
- package/dist/components/TextArea/TextArea.stories.tsx +67 -0
- package/dist/components/TextArea/index.tsx +97 -0
- package/dist/components/Timeline/Timeline.stories.tsx +100 -0
- package/dist/components/Timeline/index.tsx +315 -0
- package/dist/components/Tubestops/Tubestops.stories.tsx +66 -0
- package/dist/components/Tubestops/index.tsx +77 -0
- package/dist/components/UserIcon/UserIcon.stories.tsx +67 -0
- package/dist/components/UserIcon/index.tsx +42 -0
- package/dist/components/Video/Video.stories.tsx +23 -0
- package/dist/components/Video/index.tsx +49 -0
- package/dist/index.js +0 -39
- package/dist/src/lib/components/Accordion/Accordion.stories.d.ts +6 -0
- package/dist/src/lib/components/Accordion/Accordion.stories.js +72 -0
- package/dist/src/lib/components/Accordion/Accordion.stories.js.map +1 -0
- package/dist/src/lib/components/Accordion/index.d.ts +9 -0
- package/dist/src/lib/components/Accordion/index.js +9 -0
- package/dist/src/lib/components/Accordion/index.js.map +1 -0
- package/dist/src/lib/components/AlertBar/AlertBar.stories.d.ts +6 -0
- package/dist/src/lib/components/AlertBar/AlertBar.stories.js +91 -0
- package/dist/src/lib/components/AlertBar/AlertBar.stories.js.map +1 -0
- package/dist/src/lib/components/AlertBar/index.d.ts +16 -0
- package/dist/src/lib/components/AlertBar/index.js +62 -0
- package/dist/src/lib/components/AlertBar/index.js.map +1 -0
- package/dist/src/lib/components/Breadcrumbs/Breadcrumbs.stories.d.ts +6 -0
- package/dist/src/lib/components/Breadcrumbs/Breadcrumbs.stories.js +56 -0
- package/dist/src/lib/components/Breadcrumbs/Breadcrumbs.stories.js.map +1 -0
- package/dist/src/lib/components/Breadcrumbs/index.d.ts +11 -0
- package/dist/src/lib/components/Breadcrumbs/index.js +22 -0
- package/dist/src/lib/components/Breadcrumbs/index.js.map +1 -0
- package/dist/src/lib/components/BreadcrumbsBordered/BreadcrumbsBordered.stories.d.ts +6 -0
- package/dist/src/lib/components/BreadcrumbsBordered/BreadcrumbsBordered.stories.js +45 -0
- package/dist/src/lib/components/BreadcrumbsBordered/BreadcrumbsBordered.stories.js.map +1 -0
- package/dist/src/lib/components/BreadcrumbsBordered/index.d.ts +9 -0
- package/dist/src/lib/components/BreadcrumbsBordered/index.js +18 -0
- package/dist/src/lib/components/BreadcrumbsBordered/index.js.map +1 -0
- package/dist/src/lib/components/BreadcrumbsItem/BreadcrumbsItem.stories.d.ts +6 -0
- package/dist/src/lib/components/BreadcrumbsItem/BreadcrumbsItem.stories.js +50 -0
- package/dist/src/lib/components/BreadcrumbsItem/BreadcrumbsItem.stories.js.map +1 -0
- package/dist/src/lib/components/BreadcrumbsItem/index.d.ts +12 -0
- package/dist/src/lib/components/BreadcrumbsItem/index.js +59 -0
- package/dist/src/lib/components/BreadcrumbsItem/index.js.map +1 -0
- package/dist/src/lib/components/Button/button.stories.d.ts +6 -0
- package/dist/src/lib/components/Button/button.stories.js +87 -0
- package/dist/src/lib/components/Button/button.stories.js.map +1 -0
- package/dist/src/lib/components/Button/index.d.ts +17 -0
- package/dist/src/lib/components/Button/index.js +32 -0
- package/dist/src/lib/components/Button/index.js.map +1 -0
- package/dist/src/lib/components/Card/Card.stories.d.ts +5 -0
- package/dist/src/lib/components/Card/Card.stories.js +124 -0
- package/dist/src/lib/components/Card/Card.stories.js.map +1 -0
- package/dist/src/lib/components/Card/index.d.ts +31 -0
- package/dist/src/lib/components/Card/index.js +63 -0
- package/dist/src/lib/components/Card/index.js.map +1 -0
- package/dist/src/lib/components/CardWithTopImage/CardWithTopImage.stories.d.ts +6 -0
- package/dist/src/lib/components/CardWithTopImage/CardWithTopImage.stories.js +40 -0
- package/dist/src/lib/components/CardWithTopImage/CardWithTopImage.stories.js.map +1 -0
- package/dist/src/lib/components/CardWithTopImage/index.d.ts +10 -0
- package/dist/src/lib/components/CardWithTopImage/index.js +15 -0
- package/dist/src/lib/components/CardWithTopImage/index.js.map +1 -0
- package/dist/src/lib/components/Carousel/Carousel.stories.d.ts +6 -0
- package/dist/src/lib/components/Carousel/Carousel.stories.js +297 -0
- package/dist/src/lib/components/Carousel/Carousel.stories.js.map +1 -0
- package/dist/src/lib/components/Carousel/index.d.ts +61 -0
- package/dist/src/lib/components/Carousel/index.js +81 -0
- package/dist/src/lib/components/Carousel/index.js.map +1 -0
- package/dist/src/lib/components/ChevronCard/ChevronCard.stories.d.ts +6 -0
- package/dist/src/lib/components/ChevronCard/ChevronCard.stories.js +14 -0
- package/dist/src/lib/components/ChevronCard/ChevronCard.stories.js.map +1 -0
- package/dist/src/lib/components/ChevronCard/index.d.ts +7 -0
- package/dist/src/lib/components/ChevronCard/index.js +20 -0
- package/dist/src/lib/components/ChevronCard/index.js.map +1 -0
- package/dist/src/lib/components/Collapsible/Collapsible.stories.d.ts +6 -0
- package/dist/src/lib/components/Collapsible/Collapsible.stories.js +64 -0
- package/dist/src/lib/components/Collapsible/Collapsible.stories.js.map +1 -0
- package/dist/src/lib/components/Collapsible/index.d.ts +16 -0
- package/dist/src/lib/components/Collapsible/index.js +67 -0
- package/dist/src/lib/components/Collapsible/index.js.map +1 -0
- package/dist/src/lib/components/Column/Column.stories.d.ts +6 -0
- package/dist/src/lib/components/Column/Column.stories.js +30 -0
- package/dist/src/lib/components/Column/Column.stories.js.map +1 -0
- package/dist/src/lib/components/Column/index.d.ts +12 -0
- package/dist/src/lib/components/Column/index.js +83 -0
- package/dist/src/lib/components/Column/index.js.map +1 -0
- package/dist/src/lib/components/Container/Container.stories.d.ts +6 -0
- package/dist/src/lib/components/Container/Container.stories.js +30 -0
- package/dist/src/lib/components/Container/Container.stories.js.map +1 -0
- package/dist/src/lib/components/Container/index.d.ts +9 -0
- package/dist/src/lib/components/Container/index.js +8 -0
- package/dist/src/lib/components/Container/index.js.map +1 -0
- package/dist/src/lib/components/FooterBar/footerBar.stories.d.ts +6 -0
- package/dist/src/lib/components/FooterBar/footerBar.stories.js +48 -0
- package/dist/src/lib/components/FooterBar/footerBar.stories.js.map +1 -0
- package/dist/src/lib/components/FooterBar/index.d.ts +11 -0
- package/dist/src/lib/components/FooterBar/index.js +15 -0
- package/dist/src/lib/components/FooterBar/index.js.map +1 -0
- package/dist/src/lib/components/Form/Form.stories.d.ts +6 -0
- package/dist/src/lib/components/Form/Form.stories.js +82 -0
- package/dist/src/lib/components/Form/Form.stories.js.map +1 -0
- package/dist/src/lib/components/Form/index.d.ts +16 -0
- package/dist/src/lib/components/Form/index.js +19 -0
- package/dist/src/lib/components/Form/index.js.map +1 -0
- package/dist/src/lib/components/FyreCard/FyreCard.stories.d.ts +6 -0
- package/dist/src/lib/components/FyreCard/FyreCard.stories.js +22 -0
- package/dist/src/lib/components/FyreCard/FyreCard.stories.js.map +1 -0
- package/dist/src/lib/components/FyreCard/index.d.ts +13 -0
- package/dist/src/lib/components/FyreCard/index.js +18 -0
- package/dist/src/lib/components/FyreCard/index.js.map +1 -0
- package/dist/src/lib/components/Greeting/Greeting.stories.d.ts +6 -0
- package/dist/src/lib/components/Greeting/Greeting.stories.js +33 -0
- package/dist/src/lib/components/Greeting/Greeting.stories.js.map +1 -0
- package/dist/src/lib/components/Greeting/index.d.ts +10 -0
- package/dist/src/lib/components/Greeting/index.js +23 -0
- package/dist/src/lib/components/Greeting/index.js.map +1 -0
- package/dist/src/lib/components/Icon/Icon.stories.d.ts +6 -0
- package/dist/src/lib/components/Icon/Icon.stories.js +85 -0
- package/dist/src/lib/components/Icon/Icon.stories.js.map +1 -0
- package/dist/src/lib/components/Icon/index.d.ts +17 -0
- package/dist/src/lib/components/Icon/index.js +42 -0
- package/dist/src/lib/components/Icon/index.js.map +1 -0
- package/dist/src/lib/components/Image/Image.stories.d.ts +6 -0
- package/dist/src/lib/components/Image/Image.stories.js +73 -0
- package/dist/src/lib/components/Image/Image.stories.js.map +1 -0
- package/dist/src/lib/components/Image/index.d.ts +16 -0
- package/dist/src/lib/components/Image/index.js +54 -0
- package/dist/src/lib/components/Image/index.js.map +1 -0
- package/dist/src/lib/components/ImageLink/ImageLink.stories.d.ts +6 -0
- package/dist/src/lib/components/ImageLink/ImageLink.stories.js +49 -0
- package/dist/src/lib/components/ImageLink/ImageLink.stories.js.map +1 -0
- package/dist/src/lib/components/ImageLink/index.d.ts +15 -0
- package/dist/src/lib/components/ImageLink/index.js +18 -0
- package/dist/src/lib/components/ImageLink/index.js.map +1 -0
- package/dist/src/lib/components/ImageLinkList/ImageLinkList.stories.d.ts +6 -0
- package/dist/src/lib/components/ImageLinkList/ImageLinkList.stories.js +25 -0
- package/dist/src/lib/components/ImageLinkList/ImageLinkList.stories.js.map +1 -0
- package/dist/src/lib/components/ImageLinkList/index.d.ts +9 -0
- package/dist/src/lib/components/ImageLinkList/index.js +11 -0
- package/dist/src/lib/components/ImageLinkList/index.js.map +1 -0
- package/dist/src/lib/components/InformationIcon/InformationIcon.stories.d.ts +6 -0
- package/dist/src/lib/components/InformationIcon/InformationIcon.stories.js +71 -0
- package/dist/src/lib/components/InformationIcon/InformationIcon.stories.js.map +1 -0
- package/dist/src/lib/components/InformationIcon/index.d.ts +15 -0
- package/dist/src/lib/components/InformationIcon/index.js +46 -0
- package/dist/src/lib/components/InformationIcon/index.js.map +1 -0
- package/dist/src/lib/components/Input/Input.stories.d.ts +6 -0
- package/dist/src/lib/components/Input/Input.stories.js +95 -0
- package/dist/src/lib/components/Input/Input.stories.js.map +1 -0
- package/dist/src/lib/components/Input/index.d.ts +31 -0
- package/dist/src/lib/components/Input/index.js +25 -0
- package/dist/src/lib/components/Input/index.js.map +1 -0
- package/dist/src/lib/components/Jumbotron/Jumbotron.stories.d.ts +6 -0
- package/dist/src/lib/components/Jumbotron/Jumbotron.stories.js +16 -0
- package/dist/src/lib/components/Jumbotron/Jumbotron.stories.js.map +1 -0
- package/dist/src/lib/components/Jumbotron/index.d.ts +9 -0
- package/dist/src/lib/components/Jumbotron/index.js +9 -0
- package/dist/src/lib/components/Jumbotron/index.js.map +1 -0
- package/dist/src/lib/components/Nav/Nav.stories.js +134 -0
- package/dist/src/lib/components/Nav/Nav.stories.js.map +1 -0
- package/dist/src/lib/components/Nav/index.d.ts +22 -0
- package/dist/src/lib/components/Nav/index.js +75 -0
- package/dist/src/lib/components/Nav/index.js.map +1 -0
- package/dist/src/lib/components/NavItem/NavItem.stories.d.ts +6 -0
- package/dist/src/lib/components/NavItem/NavItem.stories.js +75 -0
- package/dist/src/lib/components/NavItem/NavItem.stories.js.map +1 -0
- package/dist/src/lib/components/NavItem/index.d.ts +15 -0
- package/dist/src/lib/components/NavItem/index.js +24 -0
- package/dist/src/lib/components/NavItem/index.js.map +1 -0
- package/dist/src/lib/components/NewsCard/NewsCard.stories.d.ts +6 -0
- package/dist/src/lib/components/NewsCard/NewsCard.stories.js +60 -0
- package/dist/src/lib/components/NewsCard/NewsCard.stories.js.map +1 -0
- package/dist/src/lib/components/NewsCard/index.d.ts +14 -0
- package/dist/src/lib/components/NewsCard/index.js +20 -0
- package/dist/src/lib/components/NewsCard/index.js.map +1 -0
- package/dist/src/lib/components/Profile/Profile.stories.d.ts +6 -0
- package/dist/src/lib/components/Profile/Profile.stories.js +41 -0
- package/dist/src/lib/components/Profile/Profile.stories.js.map +1 -0
- package/dist/src/lib/components/Profile/index.d.ts +18 -0
- package/dist/src/lib/components/Profile/index.js +38 -0
- package/dist/src/lib/components/Profile/index.js.map +1 -0
- package/dist/src/lib/components/Row/Row.stories.d.ts +6 -0
- package/dist/src/lib/components/Row/Row.stories.js +37 -0
- package/dist/src/lib/components/Row/Row.stories.js.map +1 -0
- package/dist/src/lib/components/Row/index.d.ts +8 -0
- package/dist/src/lib/components/Row/index.js +8 -0
- package/dist/src/lib/components/Row/index.js.map +1 -0
- package/dist/src/lib/components/Search/Search.stories.d.ts +6 -0
- package/dist/src/lib/components/Search/Search.stories.js +48 -0
- package/dist/src/lib/components/Search/Search.stories.js.map +1 -0
- package/dist/src/lib/components/Search/index.d.ts +13 -0
- package/dist/src/lib/components/Search/index.js +23 -0
- package/dist/src/lib/components/Search/index.js.map +1 -0
- package/dist/src/lib/components/SocialBlock/SocialBlock.stories.d.ts +6 -0
- package/dist/src/lib/components/SocialBlock/SocialBlock.stories.js +58 -0
- package/dist/src/lib/components/SocialBlock/SocialBlock.stories.js.map +1 -0
- package/dist/src/lib/components/SocialBlock/index.d.ts +21 -0
- package/dist/src/lib/components/SocialBlock/index.js +66 -0
- package/dist/src/lib/components/SocialBlock/index.js.map +1 -0
- package/dist/src/lib/components/StarRating/StarRating.stories.d.ts +6 -0
- package/dist/src/lib/components/StarRating/StarRating.stories.js +17 -0
- package/dist/src/lib/components/StarRating/StarRating.stories.js.map +1 -0
- package/dist/src/lib/components/StarRating/index.d.ts +9 -0
- package/dist/src/lib/components/StarRating/index.js +27 -0
- package/dist/src/lib/components/StarRating/index.js.map +1 -0
- package/dist/src/lib/components/Testimonial/Testimonial.stories.d.ts +6 -0
- package/dist/src/lib/components/Testimonial/Testimonial.stories.js +95 -0
- package/dist/src/lib/components/Testimonial/Testimonial.stories.js.map +1 -0
- package/dist/src/lib/components/Testimonial/index.d.ts +17 -0
- package/dist/src/lib/components/Testimonial/index.js +27 -0
- package/dist/src/lib/components/Testimonial/index.js.map +1 -0
- package/dist/src/lib/components/TextAndTitle/TextAndTitle.stories.d.ts +6 -0
- package/dist/src/lib/components/TextAndTitle/TextAndTitle.stories.js +63 -0
- package/dist/src/lib/components/TextAndTitle/TextAndTitle.stories.js.map +1 -0
- package/dist/src/lib/components/TextAndTitle/index.d.ts +26 -0
- package/dist/src/lib/components/TextAndTitle/index.js +113 -0
- package/dist/src/lib/components/TextAndTitle/index.js.map +1 -0
- package/dist/src/lib/components/TextArea/TextArea.stories.d.ts +6 -0
- package/dist/src/lib/components/TextArea/TextArea.stories.js +63 -0
- package/dist/src/lib/components/TextArea/TextArea.stories.js.map +1 -0
- package/dist/src/lib/components/TextArea/index.d.ts +27 -0
- package/dist/src/lib/components/TextArea/index.js +18 -0
- package/dist/src/lib/components/TextArea/index.js.map +1 -0
- package/dist/src/lib/components/Timeline/Timeline.stories.d.ts +6 -0
- package/dist/src/lib/components/Timeline/Timeline.stories.js +88 -0
- package/dist/src/lib/components/Timeline/Timeline.stories.js.map +1 -0
- package/dist/src/lib/components/Timeline/index.d.ts +14 -0
- package/dist/src/lib/components/Timeline/index.js +186 -0
- package/dist/src/lib/components/Timeline/index.js.map +1 -0
- package/dist/src/lib/components/Tubestops/Tubestops.stories.d.ts +6 -0
- package/dist/src/lib/components/Tubestops/Tubestops.stories.js +62 -0
- package/dist/src/lib/components/Tubestops/Tubestops.stories.js.map +1 -0
- package/dist/src/lib/components/Tubestops/index.d.ts +13 -0
- package/dist/src/lib/components/Tubestops/index.js +44 -0
- package/dist/src/lib/components/Tubestops/index.js.map +1 -0
- package/dist/src/lib/components/UserIcon/UserIcon.stories.d.ts +6 -0
- package/dist/src/lib/components/UserIcon/UserIcon.stories.js +63 -0
- package/dist/src/lib/components/UserIcon/UserIcon.stories.js.map +1 -0
- package/dist/src/lib/components/UserIcon/index.d.ts +11 -0
- package/dist/src/lib/components/UserIcon/index.js +17 -0
- package/dist/src/lib/components/UserIcon/index.js.map +1 -0
- package/dist/src/lib/components/Video/Video.stories.d.ts +6 -0
- package/dist/src/lib/components/Video/Video.stories.js +17 -0
- package/dist/src/lib/components/Video/Video.stories.js.map +1 -0
- package/dist/src/lib/components/Video/index.d.ts +17 -0
- package/dist/src/lib/components/Video/index.js +9 -0
- package/dist/src/lib/components/Video/index.js.map +1 -0
- package/dist/src/lib/index.d.ts +39 -0
- package/dist/src/lib/index.js +43 -0
- package/dist/src/lib/index.js.map +1 -0
- package/dist/src/lib/typography/Fonts.stories.d.ts +6 -0
- package/dist/src/lib/typography/Fonts.stories.js +42 -0
- package/dist/src/lib/typography/Fonts.stories.js.map +1 -0
- package/dist/src/lib/typography/index.d.ts +4 -0
- package/dist/src/lib/typography/index.js +23 -0
- package/dist/src/lib/typography/index.js.map +1 -0
- package/dist/src/lib/utils/controls.d.ts +35 -0
- package/dist/src/lib/utils/controls.js +21 -0
- package/dist/src/lib/utils/controls.js.map +1 -0
- package/dist/src/lib/utils/theme.d.ts +2 -0
- package/dist/src/lib/utils/theme.js +8 -0
- package/dist/src/lib/utils/theme.js.map +1 -0
- package/dist/tailwind.config.d.ts +64 -0
- package/dist/tailwind.config.js +80 -0
- package/dist/tailwind.config.js.map +1 -0
- package/package.json +18 -5
- package/dist/components/Accordion/index.js +0 -37
- package/dist/components/AlertBar/index.js +0 -129
- package/dist/components/Breadcrumbs/index.js +0 -66
- package/dist/components/BreadcrumbsBordered/index.js +0 -66
- package/dist/components/BreadcrumbsItem/index.js +0 -160
- package/dist/components/Button/index.js +0 -141
- package/dist/components/Card/index.js +0 -151
- package/dist/components/CardWithTopImage/index.js +0 -64
- package/dist/components/Carousel/index.css +0 -4
- package/dist/components/Carousel/index.css.map +0 -1
- package/dist/components/Carousel/index.js +0 -185
- package/dist/components/ChevronCard/index.js +0 -65
- package/dist/components/Collapsible/index.js +0 -158
- package/dist/components/Column/index.js +0 -137
- package/dist/components/Container/index.js +0 -55
- package/dist/components/FooterBar/index.js +0 -60
- package/dist/components/Form/index.js +0 -78
- package/dist/components/FyreCard/index.js +0 -54
- package/dist/components/Greeting/index.js +0 -69
- package/dist/components/Icon/index.js +0 -91
- package/dist/components/Image/index.js +0 -142
- package/dist/components/ImageLink/index.js +0 -61
- package/dist/components/ImageLinkList/index.js +0 -45
- package/dist/components/InformationIcon/index.js +0 -120
- package/dist/components/Input/index.js +0 -112
- package/dist/components/Jumbotron/index.js +0 -39
- package/dist/components/Nav/index.js +0 -302
- package/dist/components/NavItem/index.js +0 -129
- package/dist/components/NewsCard/index.js +0 -62
- package/dist/components/Profile/index.js +0 -86
- package/dist/components/Row/index.js +0 -55
- package/dist/components/Search/index.js +0 -60
- package/dist/components/SocialBlock/index.js +0 -184
- package/dist/components/StarRating/index.js +0 -110
- package/dist/components/Testimonial/index.js +0 -70
- package/dist/components/TextAndTitle/index.js +0 -283
- package/dist/components/TextArea/index.js +0 -97
- package/dist/components/Timeline/index.css.map +0 -1
- package/dist/components/Timeline/index.js +0 -254
- package/dist/components/Tubestops/index.css.map +0 -1
- package/dist/components/Tubestops/index.js +0 -95
- package/dist/components/UserIcon/index.js +0 -50
- package/dist/components/Users/rupertb/Documents/apps/trepur_components/src/lib/styles/base.css +0 -1831
- package/dist/components/Users/rupertb/Documents/apps/trepur_components/src/lib/styles/base.css.map +0 -1
- package/dist/components/Video/index.js +0 -67
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import classNames from 'classnames'
|
|
3
|
+
|
|
4
|
+
export interface Props {
|
|
5
|
+
id?: string
|
|
6
|
+
className?: string
|
|
7
|
+
sm?: number
|
|
8
|
+
md?: number
|
|
9
|
+
lg?: number
|
|
10
|
+
xl?: number
|
|
11
|
+
children?: any
|
|
12
|
+
}
|
|
13
|
+
const Column: React.FC<Props> = ({
|
|
14
|
+
id,
|
|
15
|
+
className,
|
|
16
|
+
sm = 1,
|
|
17
|
+
md = 1,
|
|
18
|
+
lg = 1,
|
|
19
|
+
xl = 1,
|
|
20
|
+
children
|
|
21
|
+
}: Props): JSX.Element => {
|
|
22
|
+
const widthOptions = [
|
|
23
|
+
{ 1: 'w-1/12' },
|
|
24
|
+
{ 2: 'w-2/12' },
|
|
25
|
+
{ 3: 'w-3/12' },
|
|
26
|
+
{ 4: 'w-4/12' },
|
|
27
|
+
{ 5: 'w-5/12' },
|
|
28
|
+
{ 6: 'w-6/12' },
|
|
29
|
+
{ 7: 'w-7/12' },
|
|
30
|
+
{ 8: 'w-8/12' },
|
|
31
|
+
{ 9: 'w-9/12' },
|
|
32
|
+
{ 10: 'w-10/12' },
|
|
33
|
+
{ 11: 'w-11/12' },
|
|
34
|
+
{ 12: 'w-full' }
|
|
35
|
+
]
|
|
36
|
+
|
|
37
|
+
const mdWidthOptions = [
|
|
38
|
+
{ 1: 'md:w-1/12' },
|
|
39
|
+
{ 2: 'md:w-2/12' },
|
|
40
|
+
{ 3: 'md:w-3/12' },
|
|
41
|
+
{ 4: 'md:w-4/12' },
|
|
42
|
+
{ 5: 'md:w-5/12' },
|
|
43
|
+
{ 6: 'md:w-6/12' },
|
|
44
|
+
{ 7: 'md:w-7/12' },
|
|
45
|
+
{ 8: 'md:w-8/12' },
|
|
46
|
+
{ 9: 'md:w-9/12' },
|
|
47
|
+
{ 10: 'md:w-10/12' },
|
|
48
|
+
{ 11: 'md:w-11/12' },
|
|
49
|
+
{ 12: 'md:w-full' }
|
|
50
|
+
]
|
|
51
|
+
|
|
52
|
+
const lgWidthOptions = [
|
|
53
|
+
{ 1: 'lg:w-1/12' },
|
|
54
|
+
{ 2: 'lg:w-2/12' },
|
|
55
|
+
{ 3: 'lg:w-3/12' },
|
|
56
|
+
{ 4: 'lg:w-4/12' },
|
|
57
|
+
{ 5: 'lg:w-5/12' },
|
|
58
|
+
{ 6: 'lg:w-6/12' },
|
|
59
|
+
{ 7: 'lg:w-7/12' },
|
|
60
|
+
{ 8: 'lg:w-8/12' },
|
|
61
|
+
{ 9: 'lg:w-9/12' },
|
|
62
|
+
{ 10: 'lg:w-10/12' },
|
|
63
|
+
{ 11: 'lg:w-11/12' },
|
|
64
|
+
{ 12: 'lg:w-full' }
|
|
65
|
+
]
|
|
66
|
+
|
|
67
|
+
const xlWidthOptions = [
|
|
68
|
+
{ 1: 'xl:w-1/12' },
|
|
69
|
+
{ 2: 'xl:w-2/12' },
|
|
70
|
+
{ 3: 'xl:w-3/12' },
|
|
71
|
+
{ 4: 'xl:w-4/12' },
|
|
72
|
+
{ 5: 'xl:w-5/12' },
|
|
73
|
+
{ 6: 'xl:w-6/12' },
|
|
74
|
+
{ 7: 'xl:w-7/12' },
|
|
75
|
+
{ 8: 'xl:w-8/12' },
|
|
76
|
+
{ 9: 'xl:w-9/12' },
|
|
77
|
+
{ 10: 'xl:w-10/12' },
|
|
78
|
+
{ 11: 'xl:w-11/12' },
|
|
79
|
+
{ 12: 'xl:w-full' }
|
|
80
|
+
]
|
|
81
|
+
|
|
82
|
+
const calculateWidth = (screen: any, size: number): string => {
|
|
83
|
+
switch (screen) {
|
|
84
|
+
case 'sm':
|
|
85
|
+
return Object.values(widthOptions[size - 1]).toString()
|
|
86
|
+
case 'md':
|
|
87
|
+
return Object.values(mdWidthOptions[size - 1]).toString()
|
|
88
|
+
case 'lg':
|
|
89
|
+
return Object.values(lgWidthOptions[size - 1]).toString()
|
|
90
|
+
case 'xl':
|
|
91
|
+
return Object.values(xlWidthOptions[size - 1]).toString()
|
|
92
|
+
default:
|
|
93
|
+
return Object.values(widthOptions[size - 1]).toString()
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
const classList = classNames({
|
|
98
|
+
[calculateWidth('sm', sm)]: sm,
|
|
99
|
+
[calculateWidth('md', md)]: md,
|
|
100
|
+
[calculateWidth('lg', lg)]: lg,
|
|
101
|
+
[calculateWidth('xl', xl)]: xl
|
|
102
|
+
}, className, 'h-full')
|
|
103
|
+
|
|
104
|
+
return (
|
|
105
|
+
<div
|
|
106
|
+
id={id}
|
|
107
|
+
className={classList}
|
|
108
|
+
>
|
|
109
|
+
{children}
|
|
110
|
+
</div>
|
|
111
|
+
)
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
export default Column
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import Container from './index'
|
|
3
|
+
import { idAndClassName } from '@utils/controls'
|
|
4
|
+
import { ComponentStory, ComponentMeta } from '@storybook/react'
|
|
5
|
+
|
|
6
|
+
const componentMeta: ComponentMeta<typeof Container> = {
|
|
7
|
+
title: 'Trepur Components/Rupert Bennett/Atoms/Container',
|
|
8
|
+
component: Container,
|
|
9
|
+
argTypes: {
|
|
10
|
+
...idAndClassName,
|
|
11
|
+
maxWidth: {
|
|
12
|
+
type: { name: 'number', required: false },
|
|
13
|
+
description: 'The number of pixles for the component to span',
|
|
14
|
+
control: { type: 'number', min: 1, step: 1 },
|
|
15
|
+
defaultValue: '1200'
|
|
16
|
+
},
|
|
17
|
+
children: {
|
|
18
|
+
type: { name: 'other', value: 'string | React.ReactNode' },
|
|
19
|
+
description: 'The child elements to show in the component',
|
|
20
|
+
table: {
|
|
21
|
+
type: {
|
|
22
|
+
summary: 'Array'
|
|
23
|
+
},
|
|
24
|
+
defaultValue: { summary: 'undefined' }
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
args: {
|
|
29
|
+
className: 'border',
|
|
30
|
+
children: <p>This is a centered container with a max width</p>
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
const Template: ComponentStory<typeof Container> = (args) => <Container {...args} />
|
|
35
|
+
|
|
36
|
+
export const _Container = Template.bind({})
|
|
37
|
+
|
|
38
|
+
export default componentMeta
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import classNames from 'classnames'
|
|
3
|
+
|
|
4
|
+
export interface Props {
|
|
5
|
+
id?: string
|
|
6
|
+
className?: string
|
|
7
|
+
maxWidth?: number
|
|
8
|
+
children?: any
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
const Container = ({
|
|
12
|
+
id,
|
|
13
|
+
className,
|
|
14
|
+
maxWidth = 1200,
|
|
15
|
+
children
|
|
16
|
+
}: Props): JSX.Element => {
|
|
17
|
+
const classList = classNames(className, 'mx-auto')
|
|
18
|
+
|
|
19
|
+
return (
|
|
20
|
+
<div
|
|
21
|
+
id={id}
|
|
22
|
+
className={classList}
|
|
23
|
+
style={{ maxWidth: `${maxWidth}px` }}
|
|
24
|
+
>
|
|
25
|
+
{children}
|
|
26
|
+
</div>
|
|
27
|
+
)
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export default Container
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import FooterBar from './index'
|
|
3
|
+
import { idAndClassName } from '@utils/controls'
|
|
4
|
+
import { ComponentStory, ComponentMeta } from '@storybook/react'
|
|
5
|
+
import { action } from '@storybook/addon-actions'
|
|
6
|
+
|
|
7
|
+
const componentMeta: ComponentMeta<typeof FooterBar> = {
|
|
8
|
+
title: 'Trepur Components/Rupert Bennett/Organisms/Footer Bar',
|
|
9
|
+
component: FooterBar,
|
|
10
|
+
parameters: {},
|
|
11
|
+
argTypes: {
|
|
12
|
+
...idAndClassName,
|
|
13
|
+
text: {
|
|
14
|
+
type: { name: 'string', required: false },
|
|
15
|
+
description: 'The text to show on the component',
|
|
16
|
+
table: {
|
|
17
|
+
type: { summary: 'default' }
|
|
18
|
+
},
|
|
19
|
+
defaultValue: { summary: 'undefined' }
|
|
20
|
+
},
|
|
21
|
+
buttonProps: {
|
|
22
|
+
type: { name: 'other', value: 'object' },
|
|
23
|
+
description: 'The props to pass to the button to display on the component',
|
|
24
|
+
table: {
|
|
25
|
+
type: {
|
|
26
|
+
summary: 'object'
|
|
27
|
+
},
|
|
28
|
+
defaultValue: { summary: 'undefined' }
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
theme: {
|
|
32
|
+
type: { name: 'string', required: false },
|
|
33
|
+
options: ['dark', 'light'],
|
|
34
|
+
description: 'The variant of button to render',
|
|
35
|
+
table: {
|
|
36
|
+
type: { summary: 'light' },
|
|
37
|
+
defaultValue: { summary: 'light' }
|
|
38
|
+
},
|
|
39
|
+
defaultValue: 'light',
|
|
40
|
+
control: { type: 'radio' }
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
args: {
|
|
44
|
+
text: 'RupertBennett.com Copyright 2022 All rights reserved',
|
|
45
|
+
theme: 'dark',
|
|
46
|
+
buttonProps: {
|
|
47
|
+
children: 'Admin Panel',
|
|
48
|
+
onClick: action('button clicked')
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
const Template: ComponentStory<typeof FooterBar> = (args) => <FooterBar {...args} />
|
|
54
|
+
|
|
55
|
+
export const _FooterBar = Template.bind({})
|
|
56
|
+
|
|
57
|
+
export default componentMeta
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import classNames from 'classnames'
|
|
3
|
+
import Button, { Props as buttonProps } from '@components/Button'
|
|
4
|
+
|
|
5
|
+
export interface Props {
|
|
6
|
+
id?: string
|
|
7
|
+
className?: string
|
|
8
|
+
buttonProps?: buttonProps
|
|
9
|
+
text?: string
|
|
10
|
+
theme?: 'light' | 'dark'
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
const Nav = ({
|
|
14
|
+
id,
|
|
15
|
+
className,
|
|
16
|
+
text,
|
|
17
|
+
buttonProps,
|
|
18
|
+
theme
|
|
19
|
+
}: Props): JSX.Element => {
|
|
20
|
+
const colours = theme === 'dark' ? 'bg-primary text-white' : 'bg-white text-primary'
|
|
21
|
+
const classList = classNames(className, colours, 'block md:flex flex-wrap justify-between items-center h-auto')
|
|
22
|
+
const textClasses = 'text-center pt-8 pb-4 md:pb-0 md:my-8 md:pt-0 md:pl-16'
|
|
23
|
+
const buttonClasses = 'text-center pb-8 pt-4 md:pb-0 md:pt-0 md:pr-16'
|
|
24
|
+
|
|
25
|
+
return (
|
|
26
|
+
<div id={id} className={classList}>
|
|
27
|
+
<div className={textClasses}>
|
|
28
|
+
{text}
|
|
29
|
+
</div>
|
|
30
|
+
<div className={buttonClasses}>
|
|
31
|
+
<Button
|
|
32
|
+
variant={theme === 'dark' ? 'primary' : 'secondary'}
|
|
33
|
+
rounded
|
|
34
|
+
href={buttonProps?.href}
|
|
35
|
+
onClick={buttonProps?.onClick}
|
|
36
|
+
>
|
|
37
|
+
{buttonProps?.children}
|
|
38
|
+
</Button>
|
|
39
|
+
</div>
|
|
40
|
+
</div>
|
|
41
|
+
)
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export default Nav
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import { idAndClassName } from '@utils/controls'
|
|
3
|
+
import Form from './index'
|
|
4
|
+
import { ComponentStory, ComponentMeta } from '@storybook/react'
|
|
5
|
+
|
|
6
|
+
const componentMeta: ComponentMeta<typeof Form> = {
|
|
7
|
+
title: 'Trepur Components/Rupert Bennett/Organisms/Form',
|
|
8
|
+
component: Form,
|
|
9
|
+
parameters: {},
|
|
10
|
+
argTypes: {
|
|
11
|
+
...idAndClassName,
|
|
12
|
+
title: {
|
|
13
|
+
type: { name: 'string', required: false },
|
|
14
|
+
description: 'The title to display on the component',
|
|
15
|
+
table: {
|
|
16
|
+
type: { summary: 'string' },
|
|
17
|
+
defaultValue: { summary: 'undefined' }
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
titleClasses: {
|
|
21
|
+
type: { name: 'string', required: false },
|
|
22
|
+
description: 'The class names to pass to the title of the component',
|
|
23
|
+
table: {
|
|
24
|
+
type: { summary: 'string' },
|
|
25
|
+
defaultValue: { summary: 'undefined' }
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
onSubmit: {
|
|
29
|
+
type: { name: 'function', required: false },
|
|
30
|
+
description: 'The action to perform when submitting the component',
|
|
31
|
+
action: 'onClick',
|
|
32
|
+
table: {
|
|
33
|
+
type: {
|
|
34
|
+
summary: 'function'
|
|
35
|
+
},
|
|
36
|
+
defaultValue: { summary: 'undefined' }
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
ref: {
|
|
40
|
+
type: { name: 'other', value: 'RefObject<TouchableOpacity>' },
|
|
41
|
+
description: 'An ref for highlighting the current element',
|
|
42
|
+
table: {
|
|
43
|
+
type: {
|
|
44
|
+
summary: 'object'
|
|
45
|
+
},
|
|
46
|
+
defaultValue: { summary: 'undefined' }
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
components: {
|
|
50
|
+
description: 'An array of component objects to pass to the component',
|
|
51
|
+
control: 'array',
|
|
52
|
+
table: {
|
|
53
|
+
type: {
|
|
54
|
+
summary: 'array'
|
|
55
|
+
},
|
|
56
|
+
defaultValue: { summary: 'undefined' }
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
args: {
|
|
61
|
+
title: 'This is a title',
|
|
62
|
+
components: [
|
|
63
|
+
{
|
|
64
|
+
htmlType: 'Input',
|
|
65
|
+
label: 'This is a label',
|
|
66
|
+
placeholder: 'This is a placeholder',
|
|
67
|
+
children: 'Submit'
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
htmlType: 'Input',
|
|
71
|
+
label: 'This is a label',
|
|
72
|
+
placeholder: 'This is a placeholder',
|
|
73
|
+
children: 'Submit'
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
htmlType: 'Input',
|
|
77
|
+
label: 'This is a label',
|
|
78
|
+
placeholder: 'This is a placeholder',
|
|
79
|
+
children: 'Submit'
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
htmlType: 'Button',
|
|
83
|
+
children: 'Submit'
|
|
84
|
+
}
|
|
85
|
+
]
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
const Template: ComponentStory<typeof Form> = (args) => <Form {...args} />
|
|
90
|
+
|
|
91
|
+
export const _Form = Template.bind({})
|
|
92
|
+
|
|
93
|
+
export default componentMeta
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import Button, { Props as buttonProps } from '@components/Button'
|
|
3
|
+
import Input, { Props as inputProps } from '@components/Input'
|
|
4
|
+
|
|
5
|
+
export interface Props {
|
|
6
|
+
id?: string
|
|
7
|
+
className?: string
|
|
8
|
+
title?: string
|
|
9
|
+
titleClasses?: string
|
|
10
|
+
onSubmit?: () => void
|
|
11
|
+
ref?: string
|
|
12
|
+
components?: Array<inputProps & buttonProps & { htmlType: string }>
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
const Form = ({
|
|
16
|
+
id,
|
|
17
|
+
className,
|
|
18
|
+
title,
|
|
19
|
+
titleClasses,
|
|
20
|
+
onSubmit,
|
|
21
|
+
ref,
|
|
22
|
+
components
|
|
23
|
+
}: Props): JSX.Element => {
|
|
24
|
+
return (
|
|
25
|
+
<>
|
|
26
|
+
<h1 className={titleClasses}>{title}</h1>
|
|
27
|
+
<form id={id} ref={ref} className={className} onSubmit={onSubmit}>
|
|
28
|
+
{components?.map((component, i) => {
|
|
29
|
+
if (component?.htmlType === 'Input') {
|
|
30
|
+
return (
|
|
31
|
+
<Input
|
|
32
|
+
key={`input_${i + 0}`}
|
|
33
|
+
className={component?.className}
|
|
34
|
+
label={component?.label}
|
|
35
|
+
placeholder={component?.placeholder}
|
|
36
|
+
type={component?.type}
|
|
37
|
+
name={component?.name}
|
|
38
|
+
/>
|
|
39
|
+
)
|
|
40
|
+
} else if (component.htmlType === 'Button') {
|
|
41
|
+
return (
|
|
42
|
+
<Button
|
|
43
|
+
key={`button_${i + 0}`}
|
|
44
|
+
type={component?.type}
|
|
45
|
+
onClick={component?.onClick}
|
|
46
|
+
className={component?.className}
|
|
47
|
+
>
|
|
48
|
+
{component?.children}
|
|
49
|
+
</Button>
|
|
50
|
+
)
|
|
51
|
+
} else return <></>
|
|
52
|
+
})}
|
|
53
|
+
</form>
|
|
54
|
+
</>
|
|
55
|
+
)
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export default Form
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import FyreCard from './index'
|
|
3
|
+
import { idAndClassName } from '@utils/controls'
|
|
4
|
+
import { ComponentStory, ComponentMeta } from '@storybook/react'
|
|
5
|
+
|
|
6
|
+
const componentMeta: ComponentMeta<typeof FyreCard> = {
|
|
7
|
+
title: 'Trepur Components/Other/Organisms/Fyre Card',
|
|
8
|
+
component: FyreCard,
|
|
9
|
+
parameters: {},
|
|
10
|
+
argTypes: {
|
|
11
|
+
...idAndClassName,
|
|
12
|
+
image: {
|
|
13
|
+
description: '',
|
|
14
|
+
control: 'text',
|
|
15
|
+
table: {
|
|
16
|
+
category: ''
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
args: {
|
|
21
|
+
image: 'https://picsum.photos/500/300'
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
const Template: ComponentStory<typeof FyreCard> = (args) => <FyreCard {...args} />
|
|
26
|
+
|
|
27
|
+
export const _FyreCard = Template.bind({})
|
|
28
|
+
|
|
29
|
+
export default componentMeta
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import Button, { Props as buttonProps } from '@components/Button'
|
|
3
|
+
import classNames from 'classnames'
|
|
4
|
+
|
|
5
|
+
export interface Props {
|
|
6
|
+
id?: string
|
|
7
|
+
className?: string
|
|
8
|
+
image?: string
|
|
9
|
+
imageClass?: string
|
|
10
|
+
altText?: string
|
|
11
|
+
bordered?: string
|
|
12
|
+
buttonProps?: buttonProps
|
|
13
|
+
}
|
|
14
|
+
const FyreCard = ({
|
|
15
|
+
id,
|
|
16
|
+
className,
|
|
17
|
+
image,
|
|
18
|
+
imageClass,
|
|
19
|
+
altText,
|
|
20
|
+
bordered,
|
|
21
|
+
buttonProps
|
|
22
|
+
}: Props): JSX.Element => {
|
|
23
|
+
const classList = classNames({
|
|
24
|
+
'border border-grey border-opacity-100': bordered
|
|
25
|
+
}, className, 'flex flex-col')
|
|
26
|
+
const imageClassList = classNames(imageClass, 'w-full')
|
|
27
|
+
|
|
28
|
+
return (
|
|
29
|
+
<div
|
|
30
|
+
key={id}
|
|
31
|
+
id={id}
|
|
32
|
+
className={classList}
|
|
33
|
+
>
|
|
34
|
+
<div className='card-content flex flex-1 flex-col'>
|
|
35
|
+
<div>
|
|
36
|
+
<img className={imageClassList} src={image} alt={altText} />
|
|
37
|
+
</div>
|
|
38
|
+
<div className='flex justify-end'>
|
|
39
|
+
<Button {...buttonProps}>{buttonProps?.children}</Button>
|
|
40
|
+
</div>
|
|
41
|
+
</div>
|
|
42
|
+
</div>
|
|
43
|
+
)
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export default FyreCard
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import Greeting from './index'
|
|
3
|
+
import { ComponentStory, ComponentMeta } from '@storybook/react'
|
|
4
|
+
import { idAndClassName } from '@utils/controls'
|
|
5
|
+
|
|
6
|
+
const componentMeta: ComponentMeta<typeof Greeting> = {
|
|
7
|
+
title: 'Trepur Components/Rupert Bennett/Atoms/Greeting',
|
|
8
|
+
component: Greeting,
|
|
9
|
+
argTypes: {
|
|
10
|
+
...idAndClassName,
|
|
11
|
+
morningMessage: {
|
|
12
|
+
type: { name: 'string', required: false },
|
|
13
|
+
description: 'Defines the morning message for the greeting component',
|
|
14
|
+
table: {
|
|
15
|
+
type: { summary: 'string' }
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
afternoonMessage: {
|
|
19
|
+
type: { name: 'string', required: false },
|
|
20
|
+
description: 'Defines the afternoon message for the greeting component',
|
|
21
|
+
table: {
|
|
22
|
+
type: { summary: 'string' }
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
eveningMessage: {
|
|
26
|
+
type: { name: 'string', required: false },
|
|
27
|
+
description: 'Defines the evening message for the greeting component',
|
|
28
|
+
table: {
|
|
29
|
+
type: { summary: 'string' }
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
args: {
|
|
34
|
+
morningMessage: 'What a beautiful morning it is today'
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
const Template: ComponentStory<typeof Greeting> = (args) => <Greeting {...args} />
|
|
39
|
+
|
|
40
|
+
export const _Greeting = Template.bind({})
|
|
41
|
+
|
|
42
|
+
export default componentMeta
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import classNames from 'classnames'
|
|
3
|
+
|
|
4
|
+
export interface Props {
|
|
5
|
+
id?: string
|
|
6
|
+
className?: string
|
|
7
|
+
morningMessage?: string
|
|
8
|
+
afternoonMessage?: string
|
|
9
|
+
eveningMessage?: string
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
const Greeting = ({
|
|
13
|
+
id,
|
|
14
|
+
className,
|
|
15
|
+
morningMessage = 'Good morning',
|
|
16
|
+
afternoonMessage = 'Good afternoon',
|
|
17
|
+
eveningMessage = 'Good evening'
|
|
18
|
+
}: Props): JSX.Element => {
|
|
19
|
+
const today = new Date()
|
|
20
|
+
const hours = `0${today.getHours().toString()}`.slice(-2)
|
|
21
|
+
const minutes = `0${today.getMinutes().toString()}`.slice(-2)
|
|
22
|
+
const seconds = `0${today.getSeconds().toString()}`.slice(-2)
|
|
23
|
+
const time = parseInt(`${hours}${minutes}${seconds}`)
|
|
24
|
+
|
|
25
|
+
let message
|
|
26
|
+
if (time < 120000) {
|
|
27
|
+
message = morningMessage
|
|
28
|
+
} else if (time > 115959 && time < 170000) {
|
|
29
|
+
message = afternoonMessage
|
|
30
|
+
} else if (time > 165959) {
|
|
31
|
+
message = eveningMessage
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
const classList = classNames(className)
|
|
35
|
+
|
|
36
|
+
return (
|
|
37
|
+
<p
|
|
38
|
+
id={id}
|
|
39
|
+
className={classList}
|
|
40
|
+
>
|
|
41
|
+
{message}
|
|
42
|
+
</p>
|
|
43
|
+
)
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export default Greeting
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import { ComponentStory, ComponentMeta } from '@storybook/react'
|
|
3
|
+
import HamburgerIcon from './index'
|
|
4
|
+
|
|
5
|
+
const componentMeta: ComponentMeta<typeof HamburgerIcon> = {
|
|
6
|
+
title: 'Trepur Components/Rupert Bennett/Atoms/Hamburger Icon',
|
|
7
|
+
component: HamburgerIcon,
|
|
8
|
+
parameters: {
|
|
9
|
+
docs: {
|
|
10
|
+
description: {
|
|
11
|
+
component: 'An icon component'
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
layout: 'padded'
|
|
15
|
+
},
|
|
16
|
+
argTypes: {
|
|
17
|
+
id: {
|
|
18
|
+
type: { name: 'string', required: false },
|
|
19
|
+
description: 'HTML id attribute',
|
|
20
|
+
table: { type: { summary: 'string' } }
|
|
21
|
+
},
|
|
22
|
+
className: {
|
|
23
|
+
type: { name: 'string', required: false },
|
|
24
|
+
description: 'Used to pass any additional classes to the component',
|
|
25
|
+
table: { type: { summary: 'string' } }
|
|
26
|
+
},
|
|
27
|
+
opened: {
|
|
28
|
+
type: { name: 'boolean', required: false },
|
|
29
|
+
description: 'If this component is disabled and can not be interacted',
|
|
30
|
+
table: {
|
|
31
|
+
type: { summary: 'boolean' },
|
|
32
|
+
defaultValue: { summary: 'boolean' }
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
onClick: {
|
|
36
|
+
type: { name: 'function', required: false },
|
|
37
|
+
description: 'Function to be called when the button is clicked',
|
|
38
|
+
table: { type: { summary: 'function' } }
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
args: {
|
|
42
|
+
opened: false
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
const Template: ComponentStory<typeof HamburgerIcon> = (args) => <HamburgerIcon {...args} />
|
|
47
|
+
|
|
48
|
+
export const _HamburgerIcon = Template.bind({})
|
|
49
|
+
|
|
50
|
+
export default componentMeta
|