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.
Files changed (378) hide show
  1. package/dist/components/Accordion/Accordion.stories.tsx +88 -0
  2. package/dist/components/Accordion/index.tsx +31 -0
  3. package/dist/components/AlertBar/AlertBar.stories.tsx +105 -0
  4. package/dist/components/AlertBar/index.tsx +127 -0
  5. package/dist/components/Breadcrumbs/Breadcrumbs.stories.tsx +60 -0
  6. package/dist/components/Breadcrumbs/index.tsx +55 -0
  7. package/dist/components/BreadcrumbsBordered/BreadcrumbsBordered.stories.tsx +52 -0
  8. package/dist/components/BreadcrumbsBordered/index.tsx +44 -0
  9. package/dist/components/BreadcrumbsItem/BreadcrumbsItem.stories.tsx +54 -0
  10. package/dist/components/BreadcrumbsItem/index.tsx +151 -0
  11. package/dist/components/Button/button.stories.tsx +148 -0
  12. package/dist/components/Button/index.tsx +91 -0
  13. package/dist/components/Card/Card.stories.tsx +150 -0
  14. package/dist/components/Card/index.tsx +162 -0
  15. package/dist/components/CardWithTopImage/CardWithTopImage.stories.tsx +48 -0
  16. package/dist/components/CardWithTopImage/index.tsx +40 -0
  17. package/dist/components/Carousel/Carousel.stories.tsx +369 -0
  18. package/dist/components/Carousel/index.tsx +267 -0
  19. package/dist/components/ChevronCard/ChevronCard.stories.tsx +21 -0
  20. package/dist/components/ChevronCard/index.tsx +39 -0
  21. package/dist/components/Collapsible/Collapsible.stories.tsx +70 -0
  22. package/dist/components/Collapsible/index.tsx +124 -0
  23. package/dist/components/Column/Column.stories.tsx +82 -0
  24. package/dist/components/Column/index.tsx +114 -0
  25. package/dist/components/Container/Container.stories.tsx +38 -0
  26. package/dist/components/Container/index.tsx +30 -0
  27. package/dist/components/FooterBar/footerBar.stories.tsx +57 -0
  28. package/dist/components/FooterBar/index.tsx +44 -0
  29. package/dist/components/Form/Form.stories.tsx +93 -0
  30. package/dist/components/Form/index.tsx +58 -0
  31. package/dist/components/FyreCard/FyreCard.stories.tsx +29 -0
  32. package/dist/components/FyreCard/index.tsx +46 -0
  33. package/dist/components/Greeting/Greeting.stories.tsx +42 -0
  34. package/dist/components/Greeting/index.tsx +46 -0
  35. package/dist/components/HamburgerIcon/HamburgerIcon.stories.tsx +50 -0
  36. package/dist/components/HamburgerIcon/index.tsx +65 -0
  37. package/dist/components/Icon/Icon.stories.tsx +102 -0
  38. package/dist/components/Icon/index.tsx +112 -0
  39. package/dist/components/Image/Image.stories.tsx +88 -0
  40. package/dist/components/Image/index.tsx +113 -0
  41. package/dist/components/ImageLink/ImageLink.stories.tsx +60 -0
  42. package/dist/components/ImageLink/index.tsx +62 -0
  43. package/dist/components/ImageLinkList/ImageLinkList.stories.tsx +32 -0
  44. package/dist/components/ImageLinkList/index.tsx +33 -0
  45. package/dist/components/InformationIcon/InformationIcon.stories.tsx +86 -0
  46. package/dist/components/InformationIcon/index.tsx +84 -0
  47. package/dist/components/Input/Input.stories.tsx +99 -0
  48. package/dist/components/Input/index.tsx +126 -0
  49. package/dist/components/Jumbotron/Jumbotron.stories.tsx +22 -0
  50. package/dist/components/Jumbotron/index.tsx +25 -0
  51. package/dist/components/Nav/Nav.stories.tsx +155 -0
  52. package/dist/components/Nav/index.tsx +180 -0
  53. package/dist/components/NavItem/NavItem.stories.tsx +89 -0
  54. package/dist/components/NavItem/index.tsx +65 -0
  55. package/dist/components/NewsCard/NewsCard.stories.tsx +71 -0
  56. package/dist/components/NewsCard/index.tsx +48 -0
  57. package/dist/components/Profile/Profile.stories.tsx +50 -0
  58. package/dist/components/Profile/index.tsx +87 -0
  59. package/dist/components/Row/Row.stories.tsx +51 -0
  60. package/dist/components/Row/index.tsx +24 -0
  61. package/dist/components/Search/Search.stories.tsx +58 -0
  62. package/dist/components/Search/index.tsx +58 -0
  63. package/dist/components/SocialBlock/SocialBlock.stories.tsx +114 -0
  64. package/dist/components/SocialBlock/index.tsx +161 -0
  65. package/dist/components/StarRating/StarRating.stories.tsx +23 -0
  66. package/dist/components/StarRating/index.tsx +71 -0
  67. package/dist/components/Testimonial/Testimonial.stories.tsx +110 -0
  68. package/dist/components/Testimonial/index.tsx +50 -0
  69. package/dist/components/TextAndTitle/TextAndTitle.stories.tsx +65 -0
  70. package/dist/components/TextAndTitle/index.tsx +257 -0
  71. package/dist/components/TextArea/TextArea.stories.tsx +67 -0
  72. package/dist/components/TextArea/index.tsx +97 -0
  73. package/dist/components/Timeline/Timeline.stories.tsx +100 -0
  74. package/dist/components/Timeline/index.tsx +315 -0
  75. package/dist/components/Tubestops/Tubestops.stories.tsx +66 -0
  76. package/dist/components/Tubestops/index.tsx +77 -0
  77. package/dist/components/UserIcon/UserIcon.stories.tsx +67 -0
  78. package/dist/components/UserIcon/index.tsx +42 -0
  79. package/dist/components/Video/Video.stories.tsx +23 -0
  80. package/dist/components/Video/index.tsx +49 -0
  81. package/dist/index.js +0 -39
  82. package/dist/src/lib/components/Accordion/Accordion.stories.d.ts +6 -0
  83. package/dist/src/lib/components/Accordion/Accordion.stories.js +72 -0
  84. package/dist/src/lib/components/Accordion/Accordion.stories.js.map +1 -0
  85. package/dist/src/lib/components/Accordion/index.d.ts +9 -0
  86. package/dist/src/lib/components/Accordion/index.js +9 -0
  87. package/dist/src/lib/components/Accordion/index.js.map +1 -0
  88. package/dist/src/lib/components/AlertBar/AlertBar.stories.d.ts +6 -0
  89. package/dist/src/lib/components/AlertBar/AlertBar.stories.js +91 -0
  90. package/dist/src/lib/components/AlertBar/AlertBar.stories.js.map +1 -0
  91. package/dist/src/lib/components/AlertBar/index.d.ts +16 -0
  92. package/dist/src/lib/components/AlertBar/index.js +62 -0
  93. package/dist/src/lib/components/AlertBar/index.js.map +1 -0
  94. package/dist/src/lib/components/Breadcrumbs/Breadcrumbs.stories.d.ts +6 -0
  95. package/dist/src/lib/components/Breadcrumbs/Breadcrumbs.stories.js +56 -0
  96. package/dist/src/lib/components/Breadcrumbs/Breadcrumbs.stories.js.map +1 -0
  97. package/dist/src/lib/components/Breadcrumbs/index.d.ts +11 -0
  98. package/dist/src/lib/components/Breadcrumbs/index.js +22 -0
  99. package/dist/src/lib/components/Breadcrumbs/index.js.map +1 -0
  100. package/dist/src/lib/components/BreadcrumbsBordered/BreadcrumbsBordered.stories.d.ts +6 -0
  101. package/dist/src/lib/components/BreadcrumbsBordered/BreadcrumbsBordered.stories.js +45 -0
  102. package/dist/src/lib/components/BreadcrumbsBordered/BreadcrumbsBordered.stories.js.map +1 -0
  103. package/dist/src/lib/components/BreadcrumbsBordered/index.d.ts +9 -0
  104. package/dist/src/lib/components/BreadcrumbsBordered/index.js +18 -0
  105. package/dist/src/lib/components/BreadcrumbsBordered/index.js.map +1 -0
  106. package/dist/src/lib/components/BreadcrumbsItem/BreadcrumbsItem.stories.d.ts +6 -0
  107. package/dist/src/lib/components/BreadcrumbsItem/BreadcrumbsItem.stories.js +50 -0
  108. package/dist/src/lib/components/BreadcrumbsItem/BreadcrumbsItem.stories.js.map +1 -0
  109. package/dist/src/lib/components/BreadcrumbsItem/index.d.ts +12 -0
  110. package/dist/src/lib/components/BreadcrumbsItem/index.js +59 -0
  111. package/dist/src/lib/components/BreadcrumbsItem/index.js.map +1 -0
  112. package/dist/src/lib/components/Button/button.stories.d.ts +6 -0
  113. package/dist/src/lib/components/Button/button.stories.js +87 -0
  114. package/dist/src/lib/components/Button/button.stories.js.map +1 -0
  115. package/dist/src/lib/components/Button/index.d.ts +17 -0
  116. package/dist/src/lib/components/Button/index.js +32 -0
  117. package/dist/src/lib/components/Button/index.js.map +1 -0
  118. package/dist/src/lib/components/Card/Card.stories.d.ts +5 -0
  119. package/dist/src/lib/components/Card/Card.stories.js +124 -0
  120. package/dist/src/lib/components/Card/Card.stories.js.map +1 -0
  121. package/dist/src/lib/components/Card/index.d.ts +31 -0
  122. package/dist/src/lib/components/Card/index.js +63 -0
  123. package/dist/src/lib/components/Card/index.js.map +1 -0
  124. package/dist/src/lib/components/CardWithTopImage/CardWithTopImage.stories.d.ts +6 -0
  125. package/dist/src/lib/components/CardWithTopImage/CardWithTopImage.stories.js +40 -0
  126. package/dist/src/lib/components/CardWithTopImage/CardWithTopImage.stories.js.map +1 -0
  127. package/dist/src/lib/components/CardWithTopImage/index.d.ts +10 -0
  128. package/dist/src/lib/components/CardWithTopImage/index.js +15 -0
  129. package/dist/src/lib/components/CardWithTopImage/index.js.map +1 -0
  130. package/dist/src/lib/components/Carousel/Carousel.stories.d.ts +6 -0
  131. package/dist/src/lib/components/Carousel/Carousel.stories.js +297 -0
  132. package/dist/src/lib/components/Carousel/Carousel.stories.js.map +1 -0
  133. package/dist/src/lib/components/Carousel/index.d.ts +61 -0
  134. package/dist/src/lib/components/Carousel/index.js +81 -0
  135. package/dist/src/lib/components/Carousel/index.js.map +1 -0
  136. package/dist/src/lib/components/ChevronCard/ChevronCard.stories.d.ts +6 -0
  137. package/dist/src/lib/components/ChevronCard/ChevronCard.stories.js +14 -0
  138. package/dist/src/lib/components/ChevronCard/ChevronCard.stories.js.map +1 -0
  139. package/dist/src/lib/components/ChevronCard/index.d.ts +7 -0
  140. package/dist/src/lib/components/ChevronCard/index.js +20 -0
  141. package/dist/src/lib/components/ChevronCard/index.js.map +1 -0
  142. package/dist/src/lib/components/Collapsible/Collapsible.stories.d.ts +6 -0
  143. package/dist/src/lib/components/Collapsible/Collapsible.stories.js +64 -0
  144. package/dist/src/lib/components/Collapsible/Collapsible.stories.js.map +1 -0
  145. package/dist/src/lib/components/Collapsible/index.d.ts +16 -0
  146. package/dist/src/lib/components/Collapsible/index.js +67 -0
  147. package/dist/src/lib/components/Collapsible/index.js.map +1 -0
  148. package/dist/src/lib/components/Column/Column.stories.d.ts +6 -0
  149. package/dist/src/lib/components/Column/Column.stories.js +30 -0
  150. package/dist/src/lib/components/Column/Column.stories.js.map +1 -0
  151. package/dist/src/lib/components/Column/index.d.ts +12 -0
  152. package/dist/src/lib/components/Column/index.js +83 -0
  153. package/dist/src/lib/components/Column/index.js.map +1 -0
  154. package/dist/src/lib/components/Container/Container.stories.d.ts +6 -0
  155. package/dist/src/lib/components/Container/Container.stories.js +30 -0
  156. package/dist/src/lib/components/Container/Container.stories.js.map +1 -0
  157. package/dist/src/lib/components/Container/index.d.ts +9 -0
  158. package/dist/src/lib/components/Container/index.js +8 -0
  159. package/dist/src/lib/components/Container/index.js.map +1 -0
  160. package/dist/src/lib/components/FooterBar/footerBar.stories.d.ts +6 -0
  161. package/dist/src/lib/components/FooterBar/footerBar.stories.js +48 -0
  162. package/dist/src/lib/components/FooterBar/footerBar.stories.js.map +1 -0
  163. package/dist/src/lib/components/FooterBar/index.d.ts +11 -0
  164. package/dist/src/lib/components/FooterBar/index.js +15 -0
  165. package/dist/src/lib/components/FooterBar/index.js.map +1 -0
  166. package/dist/src/lib/components/Form/Form.stories.d.ts +6 -0
  167. package/dist/src/lib/components/Form/Form.stories.js +82 -0
  168. package/dist/src/lib/components/Form/Form.stories.js.map +1 -0
  169. package/dist/src/lib/components/Form/index.d.ts +16 -0
  170. package/dist/src/lib/components/Form/index.js +19 -0
  171. package/dist/src/lib/components/Form/index.js.map +1 -0
  172. package/dist/src/lib/components/FyreCard/FyreCard.stories.d.ts +6 -0
  173. package/dist/src/lib/components/FyreCard/FyreCard.stories.js +22 -0
  174. package/dist/src/lib/components/FyreCard/FyreCard.stories.js.map +1 -0
  175. package/dist/src/lib/components/FyreCard/index.d.ts +13 -0
  176. package/dist/src/lib/components/FyreCard/index.js +18 -0
  177. package/dist/src/lib/components/FyreCard/index.js.map +1 -0
  178. package/dist/src/lib/components/Greeting/Greeting.stories.d.ts +6 -0
  179. package/dist/src/lib/components/Greeting/Greeting.stories.js +33 -0
  180. package/dist/src/lib/components/Greeting/Greeting.stories.js.map +1 -0
  181. package/dist/src/lib/components/Greeting/index.d.ts +10 -0
  182. package/dist/src/lib/components/Greeting/index.js +23 -0
  183. package/dist/src/lib/components/Greeting/index.js.map +1 -0
  184. package/dist/src/lib/components/Icon/Icon.stories.d.ts +6 -0
  185. package/dist/src/lib/components/Icon/Icon.stories.js +85 -0
  186. package/dist/src/lib/components/Icon/Icon.stories.js.map +1 -0
  187. package/dist/src/lib/components/Icon/index.d.ts +17 -0
  188. package/dist/src/lib/components/Icon/index.js +42 -0
  189. package/dist/src/lib/components/Icon/index.js.map +1 -0
  190. package/dist/src/lib/components/Image/Image.stories.d.ts +6 -0
  191. package/dist/src/lib/components/Image/Image.stories.js +73 -0
  192. package/dist/src/lib/components/Image/Image.stories.js.map +1 -0
  193. package/dist/src/lib/components/Image/index.d.ts +16 -0
  194. package/dist/src/lib/components/Image/index.js +54 -0
  195. package/dist/src/lib/components/Image/index.js.map +1 -0
  196. package/dist/src/lib/components/ImageLink/ImageLink.stories.d.ts +6 -0
  197. package/dist/src/lib/components/ImageLink/ImageLink.stories.js +49 -0
  198. package/dist/src/lib/components/ImageLink/ImageLink.stories.js.map +1 -0
  199. package/dist/src/lib/components/ImageLink/index.d.ts +15 -0
  200. package/dist/src/lib/components/ImageLink/index.js +18 -0
  201. package/dist/src/lib/components/ImageLink/index.js.map +1 -0
  202. package/dist/src/lib/components/ImageLinkList/ImageLinkList.stories.d.ts +6 -0
  203. package/dist/src/lib/components/ImageLinkList/ImageLinkList.stories.js +25 -0
  204. package/dist/src/lib/components/ImageLinkList/ImageLinkList.stories.js.map +1 -0
  205. package/dist/src/lib/components/ImageLinkList/index.d.ts +9 -0
  206. package/dist/src/lib/components/ImageLinkList/index.js +11 -0
  207. package/dist/src/lib/components/ImageLinkList/index.js.map +1 -0
  208. package/dist/src/lib/components/InformationIcon/InformationIcon.stories.d.ts +6 -0
  209. package/dist/src/lib/components/InformationIcon/InformationIcon.stories.js +71 -0
  210. package/dist/src/lib/components/InformationIcon/InformationIcon.stories.js.map +1 -0
  211. package/dist/src/lib/components/InformationIcon/index.d.ts +15 -0
  212. package/dist/src/lib/components/InformationIcon/index.js +46 -0
  213. package/dist/src/lib/components/InformationIcon/index.js.map +1 -0
  214. package/dist/src/lib/components/Input/Input.stories.d.ts +6 -0
  215. package/dist/src/lib/components/Input/Input.stories.js +95 -0
  216. package/dist/src/lib/components/Input/Input.stories.js.map +1 -0
  217. package/dist/src/lib/components/Input/index.d.ts +31 -0
  218. package/dist/src/lib/components/Input/index.js +25 -0
  219. package/dist/src/lib/components/Input/index.js.map +1 -0
  220. package/dist/src/lib/components/Jumbotron/Jumbotron.stories.d.ts +6 -0
  221. package/dist/src/lib/components/Jumbotron/Jumbotron.stories.js +16 -0
  222. package/dist/src/lib/components/Jumbotron/Jumbotron.stories.js.map +1 -0
  223. package/dist/src/lib/components/Jumbotron/index.d.ts +9 -0
  224. package/dist/src/lib/components/Jumbotron/index.js +9 -0
  225. package/dist/src/lib/components/Jumbotron/index.js.map +1 -0
  226. package/dist/src/lib/components/Nav/Nav.stories.js +134 -0
  227. package/dist/src/lib/components/Nav/Nav.stories.js.map +1 -0
  228. package/dist/src/lib/components/Nav/index.d.ts +22 -0
  229. package/dist/src/lib/components/Nav/index.js +75 -0
  230. package/dist/src/lib/components/Nav/index.js.map +1 -0
  231. package/dist/src/lib/components/NavItem/NavItem.stories.d.ts +6 -0
  232. package/dist/src/lib/components/NavItem/NavItem.stories.js +75 -0
  233. package/dist/src/lib/components/NavItem/NavItem.stories.js.map +1 -0
  234. package/dist/src/lib/components/NavItem/index.d.ts +15 -0
  235. package/dist/src/lib/components/NavItem/index.js +24 -0
  236. package/dist/src/lib/components/NavItem/index.js.map +1 -0
  237. package/dist/src/lib/components/NewsCard/NewsCard.stories.d.ts +6 -0
  238. package/dist/src/lib/components/NewsCard/NewsCard.stories.js +60 -0
  239. package/dist/src/lib/components/NewsCard/NewsCard.stories.js.map +1 -0
  240. package/dist/src/lib/components/NewsCard/index.d.ts +14 -0
  241. package/dist/src/lib/components/NewsCard/index.js +20 -0
  242. package/dist/src/lib/components/NewsCard/index.js.map +1 -0
  243. package/dist/src/lib/components/Profile/Profile.stories.d.ts +6 -0
  244. package/dist/src/lib/components/Profile/Profile.stories.js +41 -0
  245. package/dist/src/lib/components/Profile/Profile.stories.js.map +1 -0
  246. package/dist/src/lib/components/Profile/index.d.ts +18 -0
  247. package/dist/src/lib/components/Profile/index.js +38 -0
  248. package/dist/src/lib/components/Profile/index.js.map +1 -0
  249. package/dist/src/lib/components/Row/Row.stories.d.ts +6 -0
  250. package/dist/src/lib/components/Row/Row.stories.js +37 -0
  251. package/dist/src/lib/components/Row/Row.stories.js.map +1 -0
  252. package/dist/src/lib/components/Row/index.d.ts +8 -0
  253. package/dist/src/lib/components/Row/index.js +8 -0
  254. package/dist/src/lib/components/Row/index.js.map +1 -0
  255. package/dist/src/lib/components/Search/Search.stories.d.ts +6 -0
  256. package/dist/src/lib/components/Search/Search.stories.js +48 -0
  257. package/dist/src/lib/components/Search/Search.stories.js.map +1 -0
  258. package/dist/src/lib/components/Search/index.d.ts +13 -0
  259. package/dist/src/lib/components/Search/index.js +23 -0
  260. package/dist/src/lib/components/Search/index.js.map +1 -0
  261. package/dist/src/lib/components/SocialBlock/SocialBlock.stories.d.ts +6 -0
  262. package/dist/src/lib/components/SocialBlock/SocialBlock.stories.js +58 -0
  263. package/dist/src/lib/components/SocialBlock/SocialBlock.stories.js.map +1 -0
  264. package/dist/src/lib/components/SocialBlock/index.d.ts +21 -0
  265. package/dist/src/lib/components/SocialBlock/index.js +66 -0
  266. package/dist/src/lib/components/SocialBlock/index.js.map +1 -0
  267. package/dist/src/lib/components/StarRating/StarRating.stories.d.ts +6 -0
  268. package/dist/src/lib/components/StarRating/StarRating.stories.js +17 -0
  269. package/dist/src/lib/components/StarRating/StarRating.stories.js.map +1 -0
  270. package/dist/src/lib/components/StarRating/index.d.ts +9 -0
  271. package/dist/src/lib/components/StarRating/index.js +27 -0
  272. package/dist/src/lib/components/StarRating/index.js.map +1 -0
  273. package/dist/src/lib/components/Testimonial/Testimonial.stories.d.ts +6 -0
  274. package/dist/src/lib/components/Testimonial/Testimonial.stories.js +95 -0
  275. package/dist/src/lib/components/Testimonial/Testimonial.stories.js.map +1 -0
  276. package/dist/src/lib/components/Testimonial/index.d.ts +17 -0
  277. package/dist/src/lib/components/Testimonial/index.js +27 -0
  278. package/dist/src/lib/components/Testimonial/index.js.map +1 -0
  279. package/dist/src/lib/components/TextAndTitle/TextAndTitle.stories.d.ts +6 -0
  280. package/dist/src/lib/components/TextAndTitle/TextAndTitle.stories.js +63 -0
  281. package/dist/src/lib/components/TextAndTitle/TextAndTitle.stories.js.map +1 -0
  282. package/dist/src/lib/components/TextAndTitle/index.d.ts +26 -0
  283. package/dist/src/lib/components/TextAndTitle/index.js +113 -0
  284. package/dist/src/lib/components/TextAndTitle/index.js.map +1 -0
  285. package/dist/src/lib/components/TextArea/TextArea.stories.d.ts +6 -0
  286. package/dist/src/lib/components/TextArea/TextArea.stories.js +63 -0
  287. package/dist/src/lib/components/TextArea/TextArea.stories.js.map +1 -0
  288. package/dist/src/lib/components/TextArea/index.d.ts +27 -0
  289. package/dist/src/lib/components/TextArea/index.js +18 -0
  290. package/dist/src/lib/components/TextArea/index.js.map +1 -0
  291. package/dist/src/lib/components/Timeline/Timeline.stories.d.ts +6 -0
  292. package/dist/src/lib/components/Timeline/Timeline.stories.js +88 -0
  293. package/dist/src/lib/components/Timeline/Timeline.stories.js.map +1 -0
  294. package/dist/src/lib/components/Timeline/index.d.ts +14 -0
  295. package/dist/src/lib/components/Timeline/index.js +186 -0
  296. package/dist/src/lib/components/Timeline/index.js.map +1 -0
  297. package/dist/src/lib/components/Tubestops/Tubestops.stories.d.ts +6 -0
  298. package/dist/src/lib/components/Tubestops/Tubestops.stories.js +62 -0
  299. package/dist/src/lib/components/Tubestops/Tubestops.stories.js.map +1 -0
  300. package/dist/src/lib/components/Tubestops/index.d.ts +13 -0
  301. package/dist/src/lib/components/Tubestops/index.js +44 -0
  302. package/dist/src/lib/components/Tubestops/index.js.map +1 -0
  303. package/dist/src/lib/components/UserIcon/UserIcon.stories.d.ts +6 -0
  304. package/dist/src/lib/components/UserIcon/UserIcon.stories.js +63 -0
  305. package/dist/src/lib/components/UserIcon/UserIcon.stories.js.map +1 -0
  306. package/dist/src/lib/components/UserIcon/index.d.ts +11 -0
  307. package/dist/src/lib/components/UserIcon/index.js +17 -0
  308. package/dist/src/lib/components/UserIcon/index.js.map +1 -0
  309. package/dist/src/lib/components/Video/Video.stories.d.ts +6 -0
  310. package/dist/src/lib/components/Video/Video.stories.js +17 -0
  311. package/dist/src/lib/components/Video/Video.stories.js.map +1 -0
  312. package/dist/src/lib/components/Video/index.d.ts +17 -0
  313. package/dist/src/lib/components/Video/index.js +9 -0
  314. package/dist/src/lib/components/Video/index.js.map +1 -0
  315. package/dist/src/lib/index.d.ts +39 -0
  316. package/dist/src/lib/index.js +43 -0
  317. package/dist/src/lib/index.js.map +1 -0
  318. package/dist/src/lib/typography/Fonts.stories.d.ts +6 -0
  319. package/dist/src/lib/typography/Fonts.stories.js +42 -0
  320. package/dist/src/lib/typography/Fonts.stories.js.map +1 -0
  321. package/dist/src/lib/typography/index.d.ts +4 -0
  322. package/dist/src/lib/typography/index.js +23 -0
  323. package/dist/src/lib/typography/index.js.map +1 -0
  324. package/dist/src/lib/utils/controls.d.ts +35 -0
  325. package/dist/src/lib/utils/controls.js +21 -0
  326. package/dist/src/lib/utils/controls.js.map +1 -0
  327. package/dist/src/lib/utils/theme.d.ts +2 -0
  328. package/dist/src/lib/utils/theme.js +8 -0
  329. package/dist/src/lib/utils/theme.js.map +1 -0
  330. package/dist/tailwind.config.d.ts +64 -0
  331. package/dist/tailwind.config.js +80 -0
  332. package/dist/tailwind.config.js.map +1 -0
  333. package/package.json +18 -5
  334. package/dist/components/Accordion/index.js +0 -37
  335. package/dist/components/AlertBar/index.js +0 -129
  336. package/dist/components/Breadcrumbs/index.js +0 -66
  337. package/dist/components/BreadcrumbsBordered/index.js +0 -66
  338. package/dist/components/BreadcrumbsItem/index.js +0 -160
  339. package/dist/components/Button/index.js +0 -141
  340. package/dist/components/Card/index.js +0 -151
  341. package/dist/components/CardWithTopImage/index.js +0 -64
  342. package/dist/components/Carousel/index.css +0 -4
  343. package/dist/components/Carousel/index.css.map +0 -1
  344. package/dist/components/Carousel/index.js +0 -185
  345. package/dist/components/ChevronCard/index.js +0 -65
  346. package/dist/components/Collapsible/index.js +0 -158
  347. package/dist/components/Column/index.js +0 -137
  348. package/dist/components/Container/index.js +0 -55
  349. package/dist/components/FooterBar/index.js +0 -60
  350. package/dist/components/Form/index.js +0 -78
  351. package/dist/components/FyreCard/index.js +0 -54
  352. package/dist/components/Greeting/index.js +0 -69
  353. package/dist/components/Icon/index.js +0 -91
  354. package/dist/components/Image/index.js +0 -142
  355. package/dist/components/ImageLink/index.js +0 -61
  356. package/dist/components/ImageLinkList/index.js +0 -45
  357. package/dist/components/InformationIcon/index.js +0 -120
  358. package/dist/components/Input/index.js +0 -112
  359. package/dist/components/Jumbotron/index.js +0 -39
  360. package/dist/components/Nav/index.js +0 -302
  361. package/dist/components/NavItem/index.js +0 -129
  362. package/dist/components/NewsCard/index.js +0 -62
  363. package/dist/components/Profile/index.js +0 -86
  364. package/dist/components/Row/index.js +0 -55
  365. package/dist/components/Search/index.js +0 -60
  366. package/dist/components/SocialBlock/index.js +0 -184
  367. package/dist/components/StarRating/index.js +0 -110
  368. package/dist/components/Testimonial/index.js +0 -70
  369. package/dist/components/TextAndTitle/index.js +0 -283
  370. package/dist/components/TextArea/index.js +0 -97
  371. package/dist/components/Timeline/index.css.map +0 -1
  372. package/dist/components/Timeline/index.js +0 -254
  373. package/dist/components/Tubestops/index.css.map +0 -1
  374. package/dist/components/Tubestops/index.js +0 -95
  375. package/dist/components/UserIcon/index.js +0 -50
  376. package/dist/components/Users/rupertb/Documents/apps/trepur_components/src/lib/styles/base.css +0 -1831
  377. package/dist/components/Users/rupertb/Documents/apps/trepur_components/src/lib/styles/base.css.map +0 -1
  378. package/dist/components/Video/index.js +0 -67
@@ -0,0 +1,71 @@
1
+ import React from 'react';
2
+ import InformationIcon from './index';
3
+ import { idAndClassName } from '@utils/controls';
4
+ const componentMeta = {
5
+ title: 'Trepur Components/Rupert Bennett/Atoms/Information Icon',
6
+ component: InformationIcon,
7
+ argTypes: Object.assign(Object.assign({}, idAndClassName), { text: {
8
+ type: { name: 'string', required: false },
9
+ description: 'The text to display on the component',
10
+ table: {
11
+ type: { summary: 'string' }
12
+ }
13
+ }, number: {
14
+ type: { name: 'number', required: false },
15
+ description: 'The number to display on the component',
16
+ table: {
17
+ type: { summary: 'number' }
18
+ }
19
+ }, bordered: {
20
+ type: { name: 'boolean', required: false },
21
+ description: 'Applies a border to the component',
22
+ table: {
23
+ type: { summary: 'boolean' }
24
+ },
25
+ defaultValue: 'false'
26
+ }, rounded: {
27
+ type: { name: 'boolean', required: false },
28
+ description: 'Enabled rounded corners on the component',
29
+ table: {
30
+ type: { summary: 'boolean' }
31
+ },
32
+ defaultValue: 'false'
33
+ }, withAnimation: {
34
+ type: { name: 'boolean', required: false },
35
+ description: 'Enabled the counter animation on the component',
36
+ table: {
37
+ type: { summary: 'boolean' }
38
+ },
39
+ defaultValue: 'false'
40
+ }, iconProps: {
41
+ type: { name: 'string', required: false },
42
+ description: 'The props to pass to the icon to display on the component',
43
+ table: {
44
+ type: { summary: 'string' }
45
+ }
46
+ }, theme: {
47
+ type: { name: 'string', required: false },
48
+ options: ['dark', 'light'],
49
+ description: 'The variant of component to render',
50
+ table: { type: { summary: 'light' }, defaultValue: { summary: 'light' } },
51
+ defaultValue: 'light',
52
+ control: { type: 'radio' }
53
+ } }),
54
+ args: {
55
+ text: 'Projects Completed',
56
+ number: 21,
57
+ bordered: true,
58
+ rounded: true,
59
+ withAnimation: true,
60
+ theme: 'dark',
61
+ iconProps: {
62
+ type: 'heart',
63
+ size: 3,
64
+ className: 'mr-4 mb-8'
65
+ }
66
+ }
67
+ };
68
+ const Template = (args) => React.createElement(InformationIcon, Object.assign({}, args));
69
+ export const _InformationIcon = Template.bind({});
70
+ export default componentMeta;
71
+ //# sourceMappingURL=InformationIcon.stories.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InformationIcon.stories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3
+ export interface Props {
4
+ id?: string;
5
+ className?: string;
6
+ text?: string;
7
+ number: number;
8
+ bordered?: boolean;
9
+ rounded?: boolean;
10
+ withAnimation?: boolean;
11
+ iconProps?: iconProps;
12
+ theme?: 'dark' | 'light';
13
+ }
14
+ declare const InformationIcon: ({ id, className, text, number, bordered, rounded, withAnimation, iconProps, theme }: Props) => JSX.Element;
15
+ export default InformationIcon;
@@ -0,0 +1,46 @@
1
+ import React, { useEffect, useRef } from 'react';
2
+ import Icon from '../Icon';
3
+ import classNames from 'classnames';
4
+ const InformationIcon = ({ id, className, text, number, bordered = false, rounded = false, withAnimation = false, iconProps, theme = 'light' }) => {
5
+ const colours = theme === 'dark' ? 'placeholder-white bg-primary text-white' : 'placeholder-primary bg-white text-primary';
6
+ let loaded = useRef(false);
7
+ useEffect(() => {
8
+ const element = document.getElementById(id + '_number');
9
+ let observer = new IntersectionObserver((entries, observer) => {
10
+ entries.forEach(entry => {
11
+ if (entry.intersectionRatio >= 0.1 && loaded.current == false) {
12
+ loaded.current = true;
13
+ counterAnimation(document.getElementById(id + '_number'), 0, number, 3000);
14
+ }
15
+ });
16
+ }, { threshold: 1 });
17
+ element && withAnimation && observer.observe(element);
18
+ }, []);
19
+ const wrapperClasses = 'h-96 flex items-center text-center ease-out duration-300';
20
+ const classList = classNames({
21
+ 'border': bordered,
22
+ 'rounded-2xl': rounded,
23
+ }, className, colours, 'flex flex-col justify-center w-full h-full items-center ease-out duration-300 text-md lg:text-md hover:text-lg');
24
+ const counterAnimation = (obj, start, end, duration) => {
25
+ let startTimestamp = undefined;
26
+ const step = (timestamp) => {
27
+ if (!startTimestamp)
28
+ startTimestamp = timestamp;
29
+ const progress = Math.min((timestamp - startTimestamp) / duration, 1);
30
+ obj.innerHTML = Math.floor(progress * (end - start) + start);
31
+ if (progress < 1) {
32
+ window.requestAnimationFrame(step);
33
+ }
34
+ };
35
+ window.requestAnimationFrame(step);
36
+ };
37
+ return (React.createElement("div", { id: id, className: wrapperClasses },
38
+ React.createElement("div", { className: classList },
39
+ iconProps &&
40
+ React.createElement(Icon, Object.assign({}, iconProps)),
41
+ number &&
42
+ React.createElement("p", null, number),
43
+ React.createElement("p", null, text))));
44
+ };
45
+ export default InformationIcon;
46
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/lib/components/InformationIcon/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAA;AAChD,OAAO,IAA2B,MAAM,SAAS,CAAA;AACjD,OAAO,UAAU,MAAM,YAAY,CAAA;AAcnC,MAAM,eAAe,GAAG,CAAC,EACrB,EAAE,EACF,SAAS,EACT,IAAI,EACJ,MAAM,EACN,QAAQ,GAAG,KAAK,EAChB,OAAO,GAAG,KAAK,EACf,aAAa,GAAG,KAAK,EACrB,SAAS,EACT,KAAK,GAAG,OAAO,EACZ,EAAE,EAAE;IACP,MAAM,OAAO,GAAG,KAAK,KAAK,MAAM,CAAC,CAAC,CAAC,yCAAyC,CAAC,CAAC,CAAC,2CAA2C,CAAA;IAC1H,IAAI,MAAM,GAAG,MAAM,CAAC,KAAK,CAAC,CAAA;IAE1B,SAAS,CAAC,GAAG,EAAE;QACX,MAAM,OAAO,GAAG,QAAQ,CAAC,cAAc,CAAC,EAAE,GAAG,SAAS,CAAC,CAAA;QACvD,IAAI,QAAQ,GAAG,IAAI,oBAAoB,CAAC,CAAC,OAAO,EAAE,QAAQ,EAAE,EAAE;YAC1D,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE;gBACtB,IAAG,KAAK,CAAC,iBAAiB,IAAI,GAAG,IAAI,MAAM,CAAC,OAAO,IAAI,KAAK,EAAC;oBAC3D,MAAM,CAAC,OAAO,GAAG,IAAI,CAAA;oBACrB,gBAAgB,CACZ,QAAQ,CAAC,cAAc,CACnB,EAAE,GAAG,SAAS,CACjB,EAAE,CAAC,EA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AAI,MAAM,CAAK;YAEnB,+BAAI,IAAI,CAAK,CACX,CACJ,CACT,CAAA;AACL,CAAC,CAAA;AAED,eAAe,eAAe,CAAA"}
@@ -0,0 +1,6 @@
1
+ /// <reference types="react" />
2
+ import Input from './index';
3
+ import { ComponentStory, ComponentMeta } from '@storybook/react';
4
+ declare const componentMeta: ComponentMeta<typeof Input>;
5
+ export declare const _Input: ComponentStory<({ id, className, labelClasses, inputClasses, autoComplete, disabled, formId, height, maxLength, minLength, pattern, required, readOnly, autoFocus, label, type, name, placeholder, bold, onChange, onBlur, onFocus, hasValidation, errors, value, theme }: import("./index").Props) => JSX.Element>;
6
+ export default componentMeta;
@@ -0,0 +1,95 @@
1
+ import React from 'react';
2
+ import Input from './index';
3
+ const componentMeta = {
4
+ title: 'Trepur Components/Rupert Bennett/Atoms/Input',
5
+ component: Input,
6
+ parameters: {},
7
+ argTypes: {
8
+ id: {
9
+ description: 'Defines the id of the component',
10
+ table: {
11
+ category: '',
12
+ type: { summary: 'string' },
13
+ defaultValue: { summary: 'undefined' }
14
+ }
15
+ },
16
+ className: {
17
+ description: 'Defines any additional classes for the components',
18
+ table: {
19
+ category: '',
20
+ type: { summary: 'string' },
21
+ defaultValue: { summary: 'undefined' }
22
+ }
23
+ },
24
+ label: {
25
+ description: '',
26
+ control: 'text',
27
+ table: {
28
+ category: '',
29
+ }
30
+ },
31
+ placeholder: {
32
+ description: '',
33
+ control: 'text',
34
+ table: {
35
+ category: '',
36
+ }
37
+ },
38
+ bold: {
39
+ description: '',
40
+ control: 'boolean',
41
+ table: {
42
+ category: '',
43
+ }
44
+ },
45
+ required: {
46
+ description: '',
47
+ control: 'boolean',
48
+ table: {
49
+ category: '',
50
+ }
51
+ },
52
+ hasValidation: {
53
+ description: '',
54
+ control: 'boolean',
55
+ table: {
56
+ category: '',
57
+ }
58
+ },
59
+ errors: {
60
+ description: '',
61
+ control: 'array',
62
+ table: {
63
+ category: '',
64
+ }
65
+ },
66
+ value: {
67
+ description: 'The default value of the input',
68
+ control: 'text',
69
+ table: {
70
+ category: '',
71
+ }
72
+ },
73
+ theme: {
74
+ type: { name: 'string', required: false },
75
+ options: ['dark', 'light'],
76
+ description: 'The variant of button to render',
77
+ table: { type: { summary: 'dark' }, defaultValue: { summary: 'dark' } },
78
+ defaultValue: 'dark',
79
+ control: { type: 'radio' }
80
+ }
81
+ },
82
+ args: {
83
+ label: 'This is a label',
84
+ placeholder: 'This is a placeholder',
85
+ errors: [
86
+ "This is an error",
87
+ "This is another error",
88
+ "This is a third error"
89
+ ]
90
+ }
91
+ };
92
+ const Template = (args) => React.createElement(Input, Object.assign({}, args));
93
+ export const _Input = Template.bind({});
94
+ export default componentMeta;
95
+ //# sourceMappingURL=Input.stories.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Input.stories.js","sourceRoot":"","sources":["../../../../../src/lib/components/Input/Input.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,KAAK,MAAM,SAAS,CAAA;AAG3B,MAAM,aAAa,GAAgC;IAC/C,KAAK,EAAE,8CAA8C;IACrD,SAAS,EAAE,KAAK;IAChB,UAAU,EAAE,EAAE;IACd,QAAQ,EAAE;QACN,EAAE,EAAE;YACA,WAAW,EAAE,iCAAiC;YAC9C,KAAK,EAAE;gBACH,QAAQ,EAAE,EAAE;gBACZ,IAAI,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE;gBAC3B,YAAY,EAAE,EAAE,OAAO,EAAE,WAAW,EAAE;aACzC;SACJ;QACD,SAAS,EAAE;YACP,WAAW,EAAE,mDAAmD;YAChE,KAAK,EAAE;gBACH,QAAQ,EAAE,EAAE;gBACZ,IAAI,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE;gBAC3B,YAAY,EAAE,EAAE,OAAO,EAAE,WAAW,EAAE;aACzC;SACJ;QACD,KAAK,EAAE;YACH,WAAW,EAAE,EAAE;YACf,OAAO,EAAE,MAAM;YACf,KAAK,EAA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YACvB,uBAAuB;SAC1B;KACJ;CACJ,CAAA;AAED,MAAM,QAAQ,GAAiC,CAAC,IAAI,EAAE,EAAE,CAAC,oBAAC,KAAK,oBAAK,IAAI,EAAI,CAAA;AAE5E,MAAM,CAAC,MAAM,MAAM,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAEvC,eAAe,aAAa,CAAA"}
@@ -0,0 +1,31 @@
1
+ /// <reference types="react" />
2
+ export interface Props {
3
+ id?: string;
4
+ className?: string;
5
+ labelClasses?: string;
6
+ inputClasses?: string;
7
+ autoComplete?: string;
8
+ disabled?: boolean;
9
+ formId?: string;
10
+ height?: string;
11
+ maxLength?: number;
12
+ minLength?: number;
13
+ pattern?: string;
14
+ required?: boolean;
15
+ readOnly?: boolean;
16
+ label?: string;
17
+ type?: string;
18
+ name?: string;
19
+ placeholder?: string;
20
+ hasValidation?: boolean;
21
+ bold?: boolean;
22
+ autoFocus?: boolean;
23
+ onChange?: (e: any) => void;
24
+ onBlur?: () => void;
25
+ onFocus?: () => void;
26
+ errors?: Array<string>;
27
+ value?: string;
28
+ theme?: 'dark' | 'light';
29
+ }
30
+ declare const Input: ({ id, className, labelClasses, inputClasses, autoComplete, disabled, formId, height, maxLength, minLength, pattern, required, readOnly, autoFocus, label, type, name, placeholder, bold, onChange, onBlur, onFocus, hasValidation, errors, value, theme }: Props) => JSX.Element;
31
+ export default Input;
@@ -0,0 +1,25 @@
1
+ import React from 'react';
2
+ import classNames from 'classnames';
3
+ const Input = ({ id, className, labelClasses, inputClasses, autoComplete, disabled, formId, height, maxLength, minLength, pattern, required, readOnly, autoFocus, label, type, name, placeholder, bold, onChange, onBlur, onFocus, hasValidation, errors, value, theme }) => {
4
+ const colours = theme === 'dark' ? 'placeholder-white bg-primary text-white' : 'placeholder-primary bg-white text-primary';
5
+ const classList = classNames({}, `${className} ${colours} flex flex-col`);
6
+ const labelClassList = classNames({
7
+ 'font-bold': bold,
8
+ }, `${labelClasses} w-auto pb-2`);
9
+ const inputClassList = classNames({}, `${inputClasses} ${colours} border px-2 py-2 mb-2 rounded-md`);
10
+ return (React.createElement("div", Object.assign({}, (id && { id: id }), { className: classList }),
11
+ label &&
12
+ React.createElement("label", { id: `label-${id}`, className: labelClassList, htmlFor: `input-${id}` },
13
+ React.createElement("p", null,
14
+ label,
15
+ required &&
16
+ React.createElement("span", { className: 'text-red' }, "*"))),
17
+ React.createElement("input", { id: `input-${id}`, className: inputClassList, autoComplete: autoComplete, disabled: disabled, form: formId, height: height, maxLength: maxLength, minLength: minLength, pattern: pattern, required: required, readOnly: readOnly, type: type, name: name, value: value, placeholder: placeholder, onChange: onChange, onBlur: onBlur, onFocus: onFocus }),
18
+ hasValidation &&
19
+ React.createElement("div", { id: `${id}-errors` }, errors &&
20
+ errors.map((error, i) => {
21
+ return (React.createElement("p", { key: `error_msg_${i + 0}`, className: 'text-red text-sm' }, error));
22
+ }))));
23
+ };
24
+ export default Input;
25
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/lib/components/Input/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,UAAU,MAAM,YAAY,CAAA;AA+BnC,MAAM,KAAK,GAAG,CAAC,EACX,EAAE,EACF,SAAS,EACT,YAAY,EACZ,YAAY,EACZ,YAAY,EACZ,QAAQ,EACR,MAAM,EACN,MAAM,EACN,SAAS,EACT,SAAS,EACT,OAAO,EACP,QAAQ,EACR,QAAQ,EACR,SAAS,EACT,KAAK,EACL,IAAI,EACJ,IAAI,EACJ,WAAW,EACX,IAAI,EACJ,QAAQ,EACR,MAAM,EACN,OAAO,EACP,aAAa,EACb,MAAM,EACN,KAAK,EACL,KAAK,EACD,EAAE,EAAE;IACR,MAAM,OAAO,GAAG,KAAK,KAAK,MAAM,CAAC,CAAC,CAAC,yCAAyC,CAAC,CAAC,CAAC,2CAA2C,CAAA;IAC1H,MAA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AAC,EAAE,EACvB,SAAS,EAAC,kBAAkB,IAE3B,KAAK,CACN,CACP,CAAA;gBACL,CAAC,CAAC,CAEJ,CAER,CACT,CAAA;AACL,CAAC,CAAA;AAED,eAAe,KAAK,CAAA"}
@@ -0,0 +1,6 @@
1
+ /// <reference types="react" />
2
+ import Jumbotron from './index';
3
+ import { ComponentStory, ComponentMeta } from '@storybook/react';
4
+ declare const componentMeta: ComponentMeta<typeof Jumbotron>;
5
+ export declare const _Jumbotron: ComponentStory<({ id, className, image, altText }: import("./index").Props) => JSX.Element>;
6
+ export default componentMeta;
@@ -0,0 +1,16 @@
1
+ import React from 'react';
2
+ import { idAndClassName } from '@utils/controls';
3
+ import Jumbotron from './index';
4
+ const componentMeta = {
5
+ title: 'Trepur Components/Rupert Bennett/Organisms/Jumbotron',
6
+ component: Jumbotron,
7
+ parameters: {},
8
+ argTypes: Object.assign({}, idAndClassName),
9
+ args: {
10
+ image: 'https://picsum.photos/1500/400'
11
+ }
12
+ };
13
+ const Template = (args) => React.createElement(Jumbotron, Object.assign({}, args));
14
+ export const _Jumbotron = Template.bind({});
15
+ export default componentMeta;
16
+ //# sourceMappingURL=Jumbotron.stories.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Jumbotron.stories.js","sourceRoot":"","sources":["../../../../../src/lib/components/Jumbotron/Jumbotron.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAA;AAChD,OAAO,SAAS,MAAM,SAAS,CAAA;AAG/B,MAAM,aAAa,GAAoC;IACnD,KAAK,EAAE,sDAAsD;IAC7D,SAAS,EAAE,SAAS;IACpB,UAAU,EAAE,EAAE;IACd,QAAQ,oBACD,cAAc,CACpB;IACD,IAAI,EAAE;QACF,KAAK,EAAE,gCAAgC;KAC1C;CACJ,CAAA;AAED,MAAM,QAAQ,GAAqC,CAAC,IAAI,EAAE,EAAE,CAAC,oBAAC,SAAS,oBAAK,IAAI,EAAI,CAAA;AAEpF,MAAM,CAAC,MAAM,UAAU,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAE3C,eAAe,aAAa,CAAA"}
@@ -0,0 +1,9 @@
1
+ /// <reference types="react" />
2
+ export interface Props {
3
+ id?: string;
4
+ className?: string;
5
+ image?: string;
6
+ altText?: string;
7
+ }
8
+ declare const Jumbotron: ({ id, className, image, altText }: Props) => JSX.Element;
9
+ export default Jumbotron;
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ import classNames from 'classnames';
3
+ const Jumbotron = ({ id, className, image, altText }) => {
4
+ const classList = classNames(className);
5
+ return (React.createElement("div", Object.assign({}, (id && { id: id }), { className: classList }),
6
+ React.createElement("img", { className: 'w-full object-cover', src: image, alt: altText })));
7
+ };
8
+ export default Jumbotron;
9
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/lib/components/Jumbotron/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,UAAU,MAAM,YAAY,CAAA;AAQnC,MAAM,SAAS,GAAG,CAAC,EACf,EAAE,EACF,SAAS,EACT,KAAK,EACL,OAAO,EACH,EAAE,EAAE;IACR,MAAM,SAAS,GAAG,UAAU,CAAC,SAAS,CAAC,CAAA;IAEvC,OAAO,CACH,6CAAS,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC,IAAE,SAAS,EAAE,SAAS;QAC7C,6BAAK,SAAS,EAAC,qBAAqB,EAAC,GAAG,EAAE,KAAK,EAAE,GAAG,EAAE,OAAO,GAAG,CAC9D,CACT,CAAA;AACL,CAAC,CAAA;AAED,eAAe,SAAS,CAAA"}
@@ -0,0 +1,134 @@
1
+ import React from 'react';
2
+ import Nav from './index';
3
+ import { idAndClassName } from '@utils/controls';
4
+ import logoDarkTheme from '../../assets/images/primary-logo-bold.png';
5
+ import logo from '../../assets/images/secondary-logo-bold.png';
6
+ const navLinks = [
7
+ { title: 'Home', href: '/', isActive: true },
8
+ { title: 'Resume', href: '/', isActive: false },
9
+ { title: 'Contact Me', href: '/', isActive: false }
10
+ ];
11
+ const componentMeta = {
12
+ title: 'Trepur Components/Rupert Bennett/Organisms/Nav',
13
+ component: Nav,
14
+ parameters: {
15
+ backgrounds: {
16
+ default: 'grey',
17
+ values: [
18
+ {
19
+ name: 'grey',
20
+ value: '#f3f3f3'
21
+ }
22
+ ]
23
+ }
24
+ },
25
+ argTypes: Object.assign(Object.assign({}, idAndClassName), { navLinks: {
26
+ description: 'An array of nav links to display in the component',
27
+ table: {
28
+ type: { summary: 'array' }
29
+ }
30
+ }, asSideBar: {
31
+ type: { name: 'boolean', required: false },
32
+ description: 'Sets the expanding mechanism to work as a side bar on mobile',
33
+ table: {
34
+ type: { summary: 'boolean' }
35
+ }
36
+ }, dropdownNavHeight: {
37
+ type: { name: 'string', required: false },
38
+ description: 'The distance in which the dropdown should come on mobile',
39
+ table: {
40
+ type: { summary: 'string' }
41
+ }
42
+ }, logo: {
43
+ type: { name: 'string', required: false },
44
+ description: 'The logo to display on the component',
45
+ table: {
46
+ type: { summary: 'string' }
47
+ }
48
+ }, logoDarkTheme: {
49
+ type: { name: 'string', required: false },
50
+ description: 'An optional dark them logo for dark mode',
51
+ table: {
52
+ type: { summary: 'string' }
53
+ }
54
+ }, mobileLogo: {
55
+ type: { name: 'string', required: false },
56
+ description: 'An optional mobile logo for mobile devices',
57
+ table: {
58
+ type: { summary: 'string' }
59
+ }
60
+ }, mobileLogoDarkTheme: {
61
+ type: { name: 'string', required: false },
62
+ description: 'An optional dark them mobile logo for mobile dark mode',
63
+ table: {
64
+ type: { summary: 'string' }
65
+ }
66
+ }, logoLink: {
67
+ type: { name: 'string', required: false },
68
+ description: 'The link to navigate to when clicking on the logo',
69
+ table: {
70
+ type: { summary: 'string' }
71
+ }
72
+ }, mobileClasses: {
73
+ type: { name: 'string', required: false },
74
+ description: '',
75
+ table: {
76
+ type: { summary: 'string' }
77
+ }
78
+ }, fixedTop: {
79
+ type: { name: 'boolean', required: false },
80
+ description: 'Sets the header to fix at the top when true',
81
+ table: {
82
+ type: { summary: 'boolean' }
83
+ }
84
+ }, getNavStatus: {
85
+ type: { name: 'boolean', required: false },
86
+ description: 'Returns the status of the header, opened or closed in mobile',
87
+ table: {
88
+ type: { summary: 'function' }
89
+ }
90
+ }, theme: {
91
+ type: { name: 'string', required: false },
92
+ options: ['dark', 'light'],
93
+ description: 'The them to render the component in',
94
+ table: {
95
+ type: { summary: 'dark' },
96
+ defaultValue: { summary: 'dark' }
97
+ },
98
+ defaultValue: 'dark',
99
+ control: { type: 'radio' }
100
+ }, text: {
101
+ type: { name: 'string', required: false },
102
+ description: 'Text to display on the component',
103
+ table: {
104
+ type: { summary: 'string' }
105
+ }
106
+ }, textLink: {
107
+ type: { name: 'string', required: false },
108
+ description: 'A link to navigate to when clicking on the text in the component',
109
+ control: 'string',
110
+ table: {
111
+ category: '',
112
+ }
113
+ } }),
114
+ args: {
115
+ logoLink: '/',
116
+ navLinks: navLinks,
117
+ asSideBar: true,
118
+ dropdownNavHeight: '80',
119
+ logo: logo,
120
+ logoDarkTheme: logoDarkTheme,
121
+ mobileLogo: logo,
122
+ mobileLogoDarkTheme: logoDarkTheme,
123
+ fixedTop: true,
124
+ theme: 'dark',
125
+ text: 'rupertbennett.com',
126
+ // getNavStatus: (status) => {
127
+ // console.log({ status })
128
+ // }
129
+ },
130
+ };
131
+ const Template = (args) => React.createElement(Nav, Object.assign({}, args));
132
+ export const _Nav = Template.bind({});
133
+ export default componentMeta;
134
+ //# sourceMappingURL=Nav.stories.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Nav.stories.js","sourceRoot":"","sources":["../../../../../src/lib/components/Nav/Nav.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,GAAG,MAAM,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IAAI;QACV,aAAa,EAAE,aAAa;QAC5B,UAAU,EAAE,IAAI;QAChB,mBAAmB,EAAE,aAAa;QAClC,QAAQ,EAAE,IAAI;QACd,KAAK,EAAE,MAAM;QACb,IAAI,EAAE,mBAAmB;QACzB,8BAA8B;QAC9B,8BAA8B;QAC9B,IAAI;KACP;CACJ,CAAA;AAED,MAAM,QAAQ,GAA+B,CAAC,IAAI,EAAE,EAAE,CAAC,oBAAC,GAAG,oBAAK,IAAI,EAAI,CAAA;AAExE,MAAM,CAAC,MAAM,IAAI,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAErC,eAAe,aAAa,CAAA"}
@@ -0,0 +1,22 @@
1
+ /// <reference types="react" />
2
+ import { Props as navItemProps } from '../NavItem';
3
+ interface Props {
4
+ id: string;
5
+ className: string;
6
+ navLinks: Array<navItemProps>;
7
+ asSideBar: boolean;
8
+ dropdownNavHeight: string;
9
+ logo: string;
10
+ logoDarkTheme: string;
11
+ mobileLogo: string;
12
+ mobileLogoDarkTheme: string;
13
+ logoLink: string;
14
+ mobileClasses: string;
15
+ fixedTop: boolean;
16
+ getNavStatus: ({}: object) => {};
17
+ theme: 'light' | 'dark';
18
+ text?: string;
19
+ textLink?: string;
20
+ }
21
+ declare const Nav: ({ id, className, navLinks, asSideBar, dropdownNavHeight, logo, logoDarkTheme, mobileLogo, mobileLogoDarkTheme, logoLink, fixedTop, mobileClasses, getNavStatus, theme, text, textLink }: Props) => JSX.Element;
22
+ export default Nav;
@@ -0,0 +1,75 @@
1
+ import React, { useState } from 'react';
2
+ import Icon from '../Icon';
3
+ import classNames from 'classnames';
4
+ import Button from '../Button';
5
+ import NavItem from '../NavItem';
6
+ const Nav = ({ id, className, navLinks, asSideBar, dropdownNavHeight, logo, logoDarkTheme, mobileLogo, mobileLogoDarkTheme, logoLink, fixedTop, mobileClasses, getNavStatus, theme = 'dark', text, textLink }) => {
7
+ const [showSideNav, setShowSideNav] = useState(false);
8
+ const [showDropdownNav, setShowDropdownNav] = useState(false);
9
+ const colours = theme === 'dark' ? 'text-white bg-primary' : 'text-primary bg-white';
10
+ const textColour = theme === 'dark' ? 'text-white' : 'text-primary';
11
+ const navItemsClassList = 'flex justify-center my-auto px-4 lg:px-8';
12
+ const logoClassList = 'flex justify-center my-auto pl-16 lg:pl-24';
13
+ const emailClassList = 'flex justify-center my-auto pr-24';
14
+ const classList = classNames(className, colours, 'h-16');
15
+ const sideNavClasses = classNames({
16
+ 'w-0': !showSideNav,
17
+ [`w-full sm:w-1/3`]: showSideNav
18
+ }, colours, 'z-50 shadow-inner shaddow-lg md:hidden pt-20 fixed top-0 left-0 z-1 overflow-hidden h-full duration-700');
19
+ const dropdownNavClasses = classNames({
20
+ 'h-0': !showDropdownNav,
21
+ [`h-${dropdownNavHeight}`]: showDropdownNav
22
+ }, colours, 'z-50 md:hidden overflow-hidden pt-20');
23
+ const logoImageClassList = classNames('h-16 w-auto');
24
+ const mobileClassList = classNames({
25
+ 'fixed w-full z-50 top-0 mt-0': fixedTop
26
+ }, colours, mobileClasses, 'flex items-center md:hidden py-2');
27
+ const desktopClassList = classNames({
28
+ 'fixed w-full z-50 top-0 mt-0': fixedTop,
29
+ }, `w-full justify-between hidden md:flex items-center justify-between sm:items-stretch text-center`);
30
+ const openMenu = () => {
31
+ getNavStatus && getNavStatus({ asSideBar: asSideBar, open: true });
32
+ if (asSideBar) {
33
+ setShowSideNav(true);
34
+ }
35
+ else {
36
+ setShowDropdownNav(!showDropdownNav);
37
+ }
38
+ };
39
+ const closeMenu = () => {
40
+ getNavStatus && getNavStatus({ asSideBar: asSideBar, open: false });
41
+ setShowSideNav(false);
42
+ };
43
+ return (React.createElement("header", { id: id, className: classList },
44
+ React.createElement("div", { id: 'mobile-nav', className: `${mobileClassList}` },
45
+ React.createElement("div", { id: 'nav-collapse-btn-wrapper', className: "absolute inset-y-0 left-8 top-5" },
46
+ React.createElement(Button, { onClick: openMenu, variant: 'primary', type: 'icon' },
47
+ React.createElement(Icon, { type: 'bars', size: 1, colour: 'white', bgColour: 'primary' }))),
48
+ React.createElement("a", { id: 'logo-link', className: 'mx-auto', href: logoLink },
49
+ React.createElement("img", { className: logoImageClassList, src: theme === 'dark' ? mobileLogoDarkTheme : mobileLogo, alt: "Logo" }))),
50
+ React.createElement("div", { id: 'destop-nav', className: `${desktopClassList} flex` },
51
+ React.createElement("div", { className: logoClassList },
52
+ React.createElement("a", { id: 'logo-link', className: 'mx-auto', href: logoLink },
53
+ React.createElement("img", { className: logoImageClassList, src: theme === 'dark' ? logoDarkTheme : logo, alt: "Logo" }))),
54
+ React.createElement("div", { className: navItemsClassList }, navLinks && navLinks.map((navLink, i) => {
55
+ return (React.createElement(NavItem, Object.assign({}, navLink, { className: i !== 0 ? 'pl-8' : '', bordered: false, rounded: false, underlineOnHover: true, variant: theme === 'dark' ? 'secondary' : 'primary' })));
56
+ })),
57
+ React.createElement("div", { className: emailClassList },
58
+ React.createElement("a", { className: `hidden lg:inline-block ${textColour}`, href: textLink }, text))),
59
+ asSideBar ?
60
+ React.createElement("div", { className: sideNavClasses },
61
+ React.createElement("div", { className: 'absolute inset-y-0 left-8 top-5' },
62
+ React.createElement(Button, { onClick: closeMenu, variant: 'primary', type: 'icon' },
63
+ React.createElement(Icon, { type: 'multiply', size: 1, colour: 'white', bgColour: 'primary' }))),
64
+ navLinks && navLinks.map((navLink, i) => {
65
+ return (React.createElement(NavItem, Object.assign({}, navLink, { className: 'pl-8 pt-2', bordered: false, rounded: false, underlineOnHover: true, variant: theme === 'dark' ? 'secondary' : 'primary' })));
66
+ }))
67
+ :
68
+ /* dropdown */
69
+ React.createElement("div", { className: dropdownNavClasses, id: "mobile-menu" },
70
+ React.createElement("div", { className: "pt-2 pb-3 space-y-1" }, navLinks && navLinks.map((navLink, i) => {
71
+ return (React.createElement(NavItem, Object.assign({}, navLink, { className: 'pl-8 pt-2', bordered: false, rounded: false, underlineOnHover: true, variant: theme === 'dark' ? 'secondary' : 'primary' })));
72
+ })))));
73
+ };
74
+ export default Nav;
75
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/lib/components/Nav/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AACvC,OAAO,IAAI,MAAM,SAAS,CAAA;AAC1B,OAAO,UAAU,MAAM,YAAY,CAAA;AACnC,OAAO,MAAM,MAAM,WAAW,CAAA;AAC9B,OAAO,OAAiC,MAAM,YAAY,CAAA;AAqB1D,MAAM,GAAG,GAAG,CAAC,EACT,EAAE,EACF,SAAS,EACT,QAAQ,EACR,SAAS,EACT,iBAAiB,EACjB,IAAI,EACJ,aAAa,EACb,UAAU,EACV,mBAAmB,EACnB,QAAQ,EACR,QAAQ,EACR,aAAa,EACb,YAAY,EACZ,KAAK,GAAG,MAAM,EACd,IAAI,EACJ,QAAQ,EACJ,EAAE,EAAE;IACR,MAAM,CAAC,WAAW,EAAE,cAAc,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAA;IACrD,MAAM,CAAC,eAAe,EAAE,kBAAkB,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAA;IAE7D,MAAM,OAAO,GAAG,KAAK,KAAK,MAAM,CAAC,CAAC,CAAC,uBAAuB,CAAC,CAAC,CAAC,uBAAuB,CAAA;IACpF,MAAM,UAAU,GAAG,KAAK,KAAK,MAAM,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,cAAc,CAAA;IACnE,MAAM,iBAAiB,GAAG,0CAA0C,CAAA;IACpE,MAAM,aAAa,GAAG,4CAA4C,CAAA;IAClE,MAAM,cAAc,GAAG,mCAAmC,CAAA;IAC1D,MAAM,SAAS,GAAG,UAAU,CAAC,SAAS,EAAE,OAAO,EAAE,MAAM,CAAC,CAAA;IAExD,MAAM,cAAc,GAAG,UAAU,CAAC;QAC9B,KAAK,EAAE,CAAC,WAAW;QACnB,C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L,CAAC,CAAA;AAED,eAAe,GAAG,CAAA"}
@@ -0,0 +1,6 @@
1
+ /// <reference types="react" />
2
+ import NavItem from './index';
3
+ import { ComponentStory, ComponentMeta } from '@storybook/react';
4
+ declare const componentMeta: ComponentMeta<typeof NavItem>;
5
+ export declare const _NavItem: ComponentStory<({ id, className, title, href, onClick, bordered, rounded, underlineOnHover, isActive, variant }: import("./index").Props) => JSX.Element>;
6
+ export default componentMeta;