luna-one 3.1.589 → 3.1.590

Sign up to get free protection for your applications and to get access to all the features.
Files changed (194) hide show
  1. package/README.md +2315 -2315
  2. package/dist/application/assets/images/carat-down.svg +3 -3
  3. package/dist/application/assets/images/carat-up.svg +3 -3
  4. package/dist/application/assets/images/close-blue.svg +4 -4
  5. package/dist/application/assets/images/close.svg +3 -3
  6. package/dist/application/assets/images/ellipses.svg +6 -6
  7. package/dist/application/assets/images/facebook.svg +13 -13
  8. package/dist/application/assets/images/instagram.svg +19 -19
  9. package/dist/application/assets/images/linkedin.svg +15 -15
  10. package/dist/application/assets/images/twitter.svg +17 -17
  11. package/dist/application/assets/images/youtube.svg +14 -14
  12. package/dist/application/components/Loading/Loading.scss +10 -10
  13. package/dist/global-styles/content/typography.scss +140 -140
  14. package/dist/global-styles/fonts/benton.scss +113 -113
  15. package/dist/global-styles/global-terra.scss +10 -10
  16. package/dist/global-styles/global-vars.scss +599 -599
  17. package/dist/global-styles/layout/_css-grid.scss +20 -20
  18. package/dist/global-styles/layout/_media-queries.scss +35 -35
  19. package/dist/global-styles/layout/_normalize.scss +340 -340
  20. package/dist/global-styles/layout/_reset.scss +13 -13
  21. package/dist/global-styles/mixins/_box-shadow.scss +6 -6
  22. package/dist/global-styles/mixins/_mixins.scss +5 -5
  23. package/dist/global-styles/mixins/_organism-padding-hack.scss +7 -7
  24. package/dist/global-styles/mixins/_typography.scss +102 -102
  25. package/dist/global-styles/mixins/_yiq.scss +50 -50
  26. package/dist/global-styles/mixins/_z-index.scss +3 -3
  27. package/dist/global-styles/terra.scss +15 -15
  28. package/dist/global-styles/utilities/_box-shadow.scss +8 -8
  29. package/dist/global-styles/utilities/_display.scss +48 -48
  30. package/dist/global-styles/utilities/_font-family.scss +15 -15
  31. package/dist/global-styles/utilities/_parallax.scss +23 -23
  32. package/dist/global-styles/utilities/_text-align.scss +24 -24
  33. package/dist/luna/components/2x2/2x2.scss +915 -915
  34. package/dist/luna/components/AdminCategoryData/AdminCategoryData.scss +81 -81
  35. package/dist/luna/components/AdminProductData/AdminProductData.scss +75 -75
  36. package/dist/luna/components/BlockListItems/BlockListItems.scss +285 -285
  37. package/dist/luna/components/BrowserSupportBanner/BrowserSupportBanner.scss +6 -6
  38. package/dist/luna/components/CTAButtons/CTAButtons.js +1 -1
  39. package/dist/luna/components/CTAButtons/CTAButtons.scss +19 -19
  40. package/dist/luna/components/ComparisonTable/ComparisonTable.scss +331 -331
  41. package/dist/luna/components/CtaWithHeader/CtaWithHeader.scss +324 -324
  42. package/dist/luna/components/DataPoint/DataPoint.scss +170 -170
  43. package/dist/luna/components/EventCard/EventCard.scss +134 -134
  44. package/dist/luna/components/FilterSection/FilterSection.scss +143 -143
  45. package/dist/luna/components/HTMLEmbed/HTMLEmbed.scss +51 -51
  46. package/dist/luna/components/Header/Header.scss +36 -36
  47. package/dist/luna/components/ImageGallery/ImageGallery.scss +442 -442
  48. package/dist/luna/components/InPageJumpNav/InPageJumpNav.scss +122 -122
  49. package/dist/luna/components/JobPosting/JobPosting.scss +171 -171
  50. package/dist/luna/components/LinkList/LinkList.scss +59 -59
  51. package/dist/luna/components/LinkList/LinkListMethods.js +3 -0
  52. package/dist/luna/components/LoadingSpinner/LoadingSpinner.scss +34 -34
  53. package/dist/luna/components/Login/Login.scss +180 -180
  54. package/dist/luna/components/MegaMenu/MegaMenu.js +2 -2
  55. package/dist/luna/components/MegaMenu/MegaMenu.scss +570 -570
  56. package/dist/luna/components/MegaMenu/menu-generators/AllSections.js +6 -6
  57. package/dist/luna/components/MegaMenu/menu-generators/FeatureSection.js +5 -4
  58. package/dist/luna/components/MegaMenu/menu-generators/FullSubMenu.js +4 -4
  59. package/dist/luna/components/MegaMenu/menu-generators/PartialSubMenu.js +4 -4
  60. package/dist/luna/components/MegaMenu/menu-generators/SubMenu.js +15 -15
  61. package/dist/luna/components/MegaMenu/menu-generators/TertiaryMenu.js +3 -3
  62. package/dist/luna/components/MegaMenu/menu-generators/UncollapsedLinks.js +14 -14
  63. package/dist/luna/components/MegaMenu/menu-generators/UncollapsedSubMenu.js +7 -7
  64. package/dist/luna/components/MiniFeatDropdown/MiniFeatDropdown.scss +107 -107
  65. package/dist/luna/components/MobileLogin/MobileLogin.scss +38 -38
  66. package/dist/luna/components/MobileMegaMenu/MobileMegaMenu.js +8 -8
  67. package/dist/luna/components/MobileMegaMenu/MobileMegaMenu.scss +289 -289
  68. package/dist/luna/components/MobileMegaMenu/MobileMegaMenuCategory.js +9 -9
  69. package/dist/luna/components/MobileMenu/MobileMenu.scss +70 -70
  70. package/dist/luna/components/MobileNav/MobileNav.scss +286 -286
  71. package/dist/luna/components/NavBarTop/NavBarTop.scss +403 -403
  72. package/dist/luna/components/NavSearch/NavSearch.scss +130 -130
  73. package/dist/luna/components/NonTimeBasedListEntries/NonTimeBasedListEntries.scss +339 -339
  74. package/dist/luna/components/OverlayNotice/OverlayNotice.scss +247 -247
  75. package/dist/luna/components/Pagination/Pagination.scss +27 -27
  76. package/dist/luna/components/ProductSummary/ProductSummary.scss +273 -273
  77. package/dist/luna/components/ProseLayout/ProseLayout.scss +384 -384
  78. package/dist/luna/components/RegionCard/RegionCard.scss +86 -86
  79. package/dist/luna/components/ResourceGrid/ResourceGrid.scss +34 -34
  80. package/dist/luna/components/ScrollInPlace/ScrollInPlace.scss +219 -219
  81. package/dist/luna/components/SketchUpPricingCard/SketchUpPricingCard.scss +142 -142
  82. package/dist/luna/components/SlideOutFeat/SlideOutFeat.scss +124 -124
  83. package/dist/luna/components/StoreFrontCard/StoreFrontCard.scss +434 -434
  84. package/dist/luna/components/SupportCard/SupportCard.scss +134 -134
  85. package/dist/luna/components/Tabs/Tabs.scss +871 -871
  86. package/dist/luna/components/TimeBasedList/TimeBasedList.scss +394 -394
  87. package/dist/luna/components/TrainerCard/TrainerCard.scss +51 -51
  88. package/dist/luna/components/TrialForm/TrialComponents/TrialSpecifics.scss +44 -44
  89. package/dist/luna/components/TrialForm/TrialComponents/TrialSummary.scss +57 -57
  90. package/dist/luna/components/TrialForm/TrialFormStart/TrialFormStart.scss +28 -28
  91. package/dist/luna/components/TrialForm/images/check.svg +3 -3
  92. package/dist/luna/components/TrialForm/images/form-border-bottom-dark.svg +4 -4
  93. package/dist/luna/components/TrialForm/images/form-border-bottom-light.svg +4 -4
  94. package/dist/luna/components/TrialForm/images/form-border-top-dark.svg +4 -4
  95. package/dist/luna/components/TrialForm/images/form-border-top-light.svg +4 -4
  96. package/dist/luna/components/UnboundedCard/UnboundedCard.scss +108 -108
  97. package/dist/luna/components/UnboundedCard/playIcon.svg +17 -17
  98. package/dist/luna/components/VariableContentCard/VariableContentCard.scss +253 -253
  99. package/dist/luna/components/Video/Video.scss +209 -209
  100. package/dist/luna/components/VidyardModal/VidyardModal.scss +34 -34
  101. package/dist/luna/components/WaffleMenu/WaffleMenu.scss +73 -73
  102. package/dist/luna/featurettes/Accordion/Accordion.scss +154 -154
  103. package/dist/luna/featurettes/CustomFeat/CustomFeat.scss +17 -17
  104. package/dist/luna/featurettes/Feat1/Feat1.scss +110 -110
  105. package/dist/luna/featurettes/Feat2A/Feat2A.scss +132 -132
  106. package/dist/luna/featurettes/Feat2B/Feat2B.scss +231 -231
  107. package/dist/luna/featurettes/Feat3/Feat3.scss +49 -49
  108. package/dist/luna/featurettes/Feat4/Feat4.scss +86 -86
  109. package/dist/luna/featurettes/Feat5/Feat5.scss +235 -235
  110. package/dist/luna/featurettes/Feat7/Feat7.scss +49 -49
  111. package/dist/luna/featurettes/Feat8/Feat8.scss +103 -103
  112. package/dist/luna/featurettes/IconTextList/IconTextList.scss +124 -124
  113. package/dist/luna/featurettes/ProductsPackage/ProductsPackage.scss +194 -194
  114. package/dist/luna/featurettes/PullQuote/PullQuote.scss +400 -400
  115. package/dist/luna/featurettes/PullQuote/ico-quote-white.svg +3 -3
  116. package/dist/luna/featurettes/PullQuote/ico-quote.svg +3 -3
  117. package/dist/luna/heroes/FilterHero/FilterHero.scss +80 -80
  118. package/dist/luna/heroes/FullBackgroundHero/FullBackgroundHero.scss +722 -722
  119. package/dist/luna/heroes/Hero1/Hero1.scss +223 -223
  120. package/dist/luna/heroes/Hero2/Hero2.scss +165 -165
  121. package/dist/luna/heroes/Hero3/Hero3.scss +250 -250
  122. package/dist/luna/heroes/Hero4/Hero4.scss +112 -112
  123. package/dist/luna/heroes/Hero6/Hero6.scss +127 -127
  124. package/dist/luna/heroes/Hero7/Hero7.scss +193 -193
  125. package/dist/luna/heroes/SuperHero/SuperHero.scss +804 -804
  126. package/dist/luna/images/arrow-diagonal-black.svg +13 -13
  127. package/dist/luna/images/arrow-diagonal-blue.svg +13 -13
  128. package/dist/luna/images/arrow-diagonal-white.svg +13 -13
  129. package/dist/luna/images/bulletpoint.svg +3 -3
  130. package/dist/luna/images/callout-icon.svg +3 -3
  131. package/dist/luna/images/check-blue.svg +4 -4
  132. package/dist/luna/images/circle-arrow-right-black.svg +3 -3
  133. package/dist/luna/images/circle-arrow-right-white.svg +3 -3
  134. package/dist/luna/images/circle-arrow.svg +3 -3
  135. package/dist/luna/images/close-button.svg +42 -42
  136. package/dist/luna/images/close-dark-navy.svg +3 -3
  137. package/dist/luna/images/close-icon.svg +3 -3
  138. package/dist/luna/images/collapse-close-blue.svg +5 -5
  139. package/dist/luna/images/collapse-close-gold.svg +5 -5
  140. package/dist/luna/images/collapse-open-blue.svg +4 -4
  141. package/dist/luna/images/collapse-open-gold.svg +4 -4
  142. package/dist/luna/images/cross-medium-blue.svg +4 -4
  143. package/dist/luna/images/cross-medium-white.svg +5 -5
  144. package/dist/luna/images/down-caret-dark-blue.svg +4 -4
  145. package/dist/luna/images/down-caret-dark-gray.svg +4 -4
  146. package/dist/luna/images/down-caret-light-gray.svg +4 -4
  147. package/dist/luna/images/downArrow.svg +36 -36
  148. package/dist/luna/images/external-arrow-blue.svg +11 -11
  149. package/dist/luna/images/external-arrow-white-theme.svg +12 -12
  150. package/dist/luna/images/external-arrow.svg +12 -12
  151. package/dist/luna/images/form-border-top-light.svg +4 -4
  152. package/dist/luna/images/frame-intersection.svg +3 -3
  153. package/dist/luna/images/gallery-image-corner-border.svg +3 -3
  154. package/dist/luna/images/green-tick.svg +3 -3
  155. package/dist/luna/images/internal-arrow-blue.svg +15 -15
  156. package/dist/luna/images/internal-arrow-white-theme.svg +15 -15
  157. package/dist/luna/images/internal-arrow.svg +15 -15
  158. package/dist/luna/images/logo-icon.svg +17 -17
  159. package/dist/luna/images/pdf-doc.svg +9 -9
  160. package/dist/luna/images/play.svg +17 -17
  161. package/dist/luna/images/right-caret-dark-blue.svg +3 -3
  162. package/dist/luna/images/right-caret-light-gray.svg +4 -4
  163. package/dist/luna/images/right-caret-light-yellow-stroke.svg +9 -9
  164. package/dist/luna/images/right-caret-light-yellow.svg +4 -4
  165. package/dist/luna/images/right-caret-medium-gray.svg +4 -4
  166. package/dist/luna/images/search.svg +9 -9
  167. package/dist/luna/images/skipicon.svg +154 -154
  168. package/dist/luna/images/text-doc.svg +9 -9
  169. package/dist/luna/images/text-lines.svg +22 -22
  170. package/dist/luna/images/tooltip-close-icon.svg +3 -3
  171. package/dist/luna/images/tooltip-icon.svg +3 -3
  172. package/dist/luna/images/up-arrow.svg +36 -36
  173. package/dist/luna/images/up-right-arrow.svg +9 -9
  174. package/dist/luna/images/user-profile.svg +37 -37
  175. package/dist/luna/images/user.svg +4 -4
  176. package/dist/luna/images/waffle.svg +11 -11
  177. package/dist/luna/images/worldwide.svg +19 -19
  178. package/dist/luna/list-feats/ListFeat/ListFeat.scss +112 -112
  179. package/dist/luna/list-feats/ListFeat1/ListFeat1.scss +94 -94
  180. package/dist/luna/list-feats/ListFeat2/ListFeat2.scss +19 -19
  181. package/dist/luna/list-feats/ListFeat4/ListFeat4.scss +32 -32
  182. package/dist/luna/list-feats/ListFeat5/ListFeat5.scss +26 -26
  183. package/dist/luna/list-feats/ListFeat6/ListFeat6.scss +34 -34
  184. package/dist/luna/list-feats/ListFeat7/ListFeat7.scss +13 -13
  185. package/dist/luna/list-feats/ListFeatCustom/ListFeatCustom.scss +7 -7
  186. package/dist/luna/other-organisms/Carousel/Carousel.scss +155 -155
  187. package/dist/luna/other-organisms/Flyout/Flyout.scss +367 -367
  188. package/dist/luna/other-organisms/Footer/Footer.scss +484 -484
  189. package/dist/luna/other-organisms/LanguageSelector/LanguageSelector.scss +318 -318
  190. package/dist/luna/other-organisms/MarketoForm/MarketoForm.scss +56 -56
  191. package/dist/luna/other-organisms/NavBar/NavBar.scss +628 -628
  192. package/dist/luna/other-organisms/SubNav/SubNav.scss +274 -274
  193. package/dist/luna/utils/generateLinks.js +3 -3
  194. package/package.json +91 -91
package/README.md CHANGED
@@ -1,2315 +1,2315 @@
1
- # Luna One React Component Library
2
-
3
- The Luna One React Component Library represents the organisms used by the Trimble Creative Strategies team in web development. It consists of a series of heros and featurettes. Examples of each with required an optional props can be found below. Additionally, Luna One provides our Luna Boilerplate with a series of important methods and structural components that allow us to manage fetching, data, state, and content formatting as well as provide components for handling things like `Footer`, `NavBar`, `Stack`, and more.
4
-
5
- Using this library requires that the Terra One React Component Library is also installed, which can be done with `npm i --save terra-one`.
6
-
7
- ## Branches and Versions
8
-
9
- #### Master
10
-
11
- - This branch contains the most up to date Luna components BEFORE updating component's compatibility with Gatsby. This includes the application directory inside src/lib/application that contains boilerplate JSON formatting for React Luna Boilerplate from Drupal api-v2 endpoints. Themes are handled in the updated way, but uses old theme colors. This branch is Luna version 3.2.x. Used by Tekla
12
-
13
- #### 3.x
14
-
15
- - This branch is for Luna 3.x versions which have components that are compatible with Gatsby. This contains the most up to date theme colors and styling. When building new components/updates for the future, this is the branch to use. Used by Gatsby Boilerplate.
16
-
17
- #### 2.x
18
-
19
- - This branch is for Luna 2.x versions, most up to date Luna version before the addition of the application directory. This contains the previous way of handling themes. Used by Construction and Careers
20
-
21
- #### 1.x
22
-
23
- - This branch is for Luna 1.x versions and used on Field Technology and Heavy Industry.
24
-
25
- ## External Libraries Used:
26
-
27
- - [React Helmet](https://www.npmjs.com/package/react-helmet) - for meta information in the document `<head>`
28
- - [React Player](https://www.npmjs.com/package/react-player) - for rendering YouTube and Vimeo videos
29
- - [React Reveal](https://www.npmjs.com/package/react-reveal) - for handling organism animation when they are scrolled into view
30
- - [React Scroll](https://www.npmjs.com/package/react-scroll) - for direct scrolling behavior from the navigation bar to specific organisms
31
- - [Vidyard](https://www.npmjs.com/package/@vidyard/embed-code) - for rendering Vidyard videos
32
- - [Node Sass v4.12.x](https://www.npmjs.com/package/node-sass) - for compiling SASS into CSS
33
- - [Axios](https://www.npmjs.com/package/axios) - for handling fetch logic
34
-
35
- ## Storybook Documentation
36
-
37
- - Technical documentation for Luna 3.x is in the process of being moved to [Storybook](https://mxp-storybook.netlify.app).
38
-
39
- ## Components, Hooks, and Methods
40
-
41
- ### Luna Organisms and Components
42
-
43
- #### Heroes
44
-
45
- - [Hero1](#hero1)
46
- - [Hero2](#hero2)
47
- - [Hero3](#hero3)
48
- - [Hero4](#hero4)
49
- - [Hero5](#hero5)
50
- - [Hero7](#hero7)
51
- - [FilterHero](#filterhero)
52
-
53
- #### Feats
54
-
55
- - [Feat1](#feat1)
56
- - [Feat2A](#feat2a)
57
- - [Feat2B](#feat2b)
58
- - [Feat3](#feat3)
59
- - [Feat4](#feat4)
60
- - [Feat5](#feat5)
61
- - [Feat7](#feat7)
62
- - [Feat8](#feat8)
63
-
64
- #### List Feats
65
-
66
- - [ListFeat1](#listfeat1)
67
- - [ListFeat2](#listfeat2)
68
- - [ListFeat4](#listfeat4)
69
- - [ListFeat5](#listfeat5)
70
- - [ListFeat6](#listfeat6)
71
- - [ListFeat7](#listfeat7)
72
-
73
- ### Boilerplate Components, Hooks, and Methods
74
-
75
- #### Components
76
-
77
- - [FooterHandler](#footerhandler)
78
- - [HelmetHandler](#helmethandler)
79
- - [NavBarHandler](#navbarhandler)
80
- - [Routing](#routing)
81
- - [Stack](#stack)
82
- - [Loading](#loading)
83
-
84
- #### Hooks
85
-
86
- - [useErrorPageData](#useerrorpagedata)
87
- - [useFetch](#usefetch)
88
- - [useFooterData](#usefooterdata)
89
- - [useFooterResponse](#usefooterresponse)
90
- - [useFooterURL](#usefooterurl)
91
- - [useInnerPageNav](#useinnerpagenav)
92
- - [useLanguage](#uselanguage)
93
- - [useLanguages](#uselanguages)
94
- - [useMetadata](#usemetadata)
95
- - [useNavData](#usenavdata)
96
- - [useNavResponse](#usenavresponse)
97
- - [useNavURL](#usenavurl)
98
- - [usePageFetch](#usepagefetch)
99
- - [useRegions](#useregions)
100
- - [useRoutes](#useroutes)
101
- - [useScrollTo](#usescrollto)
102
- - [useSiteData](#usesitedata)
103
-
104
- #### Methods
105
-
106
- - [formatContentSections](#formatcontentsections)
107
-
108
- ## Luna Organisms
109
-
110
- #### Important Theme information
111
-
112
- - ALL Organisms are able to take a theme. Themes can be customized.
113
- - Themes will default to `theme-1` if no theme object is passed in as a prop.
114
-
115
- ##### Standard Themes:
116
-
117
- - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
118
-
119
- - theme-1: `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
120
- - theme-2: `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
121
- - theme-3: `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
122
- - theme-4: `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
123
- - theme-5: `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
124
-
125
- * To customize themes, add your own hex values to `color`, and `backgroundColor`, and your own classes with custom styling to `ctaOne` and `ctaTwo`.
126
-
127
- Example of Theme Object:
128
-
129
- ```
130
- const theme = {
131
- color: "blue",
132
- backgroundColor: "pink",
133
- ctaOne: "primary--1",
134
- ctaTwo: "secondary--1"
135
- }
136
- ```
137
-
138
- - Some organisms have additional key value pairs that are necessary, like `Feat7`, these additions are documented below in each organism section.
139
-
140
- ---
141
-
142
- #### Hero1 -
143
-
144
- ###### Props -
145
-
146
- - `content` **(required)** - object containing `images`, `header`, `text`, `ctas`
147
-
148
- - images **(required)** - object consisting of `desktop`, `tablet`, and `mobile` image objects
149
-
150
- - `desktop` - object with `url` and `altText` strings for the desktop image view
151
- - `url` - string that indicates the source of the image
152
- - `altText` - string that generates accessibility text for images
153
- - `tablet` - object with `url` and `altText` strings for the tablet image view
154
- - `url` - string that indicates the source of the image
155
- - `altText` - string that generates accessibility text for images
156
- - `mobile` - object with `url` and `altText` strings for the mobile image view
157
- - `url` - string that indicates the source of the image
158
- - `altText` - string that generates accessibility text for images
159
- - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
160
- - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
161
-
162
- - `header` **(required)** - string for generating header text
163
- - `text` - string for generating body text
164
- - `ctas` - object used to populate a `<CTASection>`
165
- - `ctaOne`: object with `text` and `url` strings
166
- - `ctaTwo`: object with `text` and `url` strings
167
- - `subCTA`: object with `text` and `url` strings
168
- - `theme` - object with `backgroundColor` as strings to represent hex value for background color
169
- - theme-1 `backgroundColor` hex value `#F8F8FB`
170
- - theme-2 `backgroundColor` hex value `#F1F2F7`
171
- - theme-3 `backgroundColor` hex value `#E7E9EF`
172
- - theme-4 `backgroundColor` hex value `#0063A3`
173
- - theme-5 `backgroundColor` hex value `#004F83`
174
-
175
- - `contentSide` - string that indicates whether content is on the `right` or `left` side of the component. Defaults to `right`.
176
- - `id` - string used for generating the component's id attribute. Will default to the organism's header text or the organism type.
177
- - `motion` - boolean that indicates whether to use the animation to render the component.
178
- - `focalPointImage` - image object for focal point image. Consists of x & y coords along with image url.
179
-
180
- ###### Example -
181
-
182
- ```
183
- const ctas = {
184
- ctaOne: {
185
- text: "Button",
186
- url: "/#"
187
- },
188
- ctaTwo: {
189
- text: "Button",
190
- url: "/#"
191
- },
192
- subCTA: {
193
- text: "Button",
194
- url: "/#"
195
- }
196
- };
197
-
198
- const images = {
199
- desktop: {
200
- url: "https://fpoimg.com/1600x1200",
201
- altText: "placeholder image"
202
- },
203
- tablet: {
204
- url: "https://fpoimg.com/800x600",
205
- altText: "placeholder image" },
206
- mobile: {
207
- url: "https://fpoimg.com/400x400",
208
- altText: "placeholder image"
209
- }
210
- };
211
- const theme1 = {
212
- backgroundColor: "#ffffff",
213
- };
214
-
215
- const content = {
216
- images,
217
- ctas,
218
- header: 'Design',
219
- text: 'I am text',
220
- theme: theme1,
221
- focalPointImage: {
222
- x: 6000,
223
- y: 0,
224
- title: "union-station",
225
- height: 4000,
226
- width: 6000,
227
- url: "https://images.ctfassets.net/citn2sn5tdjr/4NzwDSDlGECGIiokKomsyI/f78a74130fc60ae9b4fb2e0da2f405db/city.jpg"
228
- },
229
- }
230
-
231
- return (
232
- <Hero1
233
- content={content}
234
- motion
235
- />
236
- );
237
- ```
238
-
239
- #### Hero2
240
-
241
- ###### Props -
242
-
243
- - `content` **(required)** - object containing images, ctas, headers, subheaders, button
244
-
245
- - `images` **(required)** - object that contains two objects, `desktop` and `mobile`. `desktop` is the 4x1 image object. `mobile` is the 2x1 image object. Each image object consists have `url` and `altText` strings.
246
- - `desktop` - object consisting of `url` and `altText` strings for generating the desktop-size image
247
- - `url` - string that points to the image source
248
- - `altText` - string that generates image accessibility text
249
- - `mobile` - object consisting of `url` and `altText` strings for generating the mobile-size image
250
- - `url` - string that points to the image source
251
- - `altText` - string that generates image accessibility text
252
- - `header` **(required)** - string used for generating header text
253
- - `subHeader` **(required)** - string used for generating sub-header text
254
-
255
- - `theme` - object with `backgroundColor` as strings to represent hex value for background color
256
- - theme-1 `backgroundColor` hex value `#F8F8FB`
257
- - theme-2 `backgroundColor` hex value `#F1F2F7`
258
- - theme-3 `backgroundColor` hex value `#E7E9EF`
259
- - theme-4 `backgroundColor` hex value `#0063A3`
260
- - theme-5 `backgroundColor` hex value `#004F83`
261
-
262
- - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
263
- - `motion` - object containing `motion`, `motionDistance`, and `motionDirection` keys. -`motion` value is a boolen to indicate if motion will be on this component -`motionDistance` - string indicating the direction that the component should travel from as it fades in -`motionDirection` - string indicating the distance that the component travels during motion. **Motion is currently not enabled in `Hero2`**
264
- - `focalPointImage` - image object for focal point image. Consists of x & y coords along with image url.
265
-
266
- ###### Example -
267
-
268
- ```
269
- const theme1 = {
270
- backgroundColor: "#ffffff",
271
- };
272
-
273
-
274
- const content = {
275
- header="Good Design is innovative",
276
- subHeader="Esse aliquip ad in et ut ipsum paEu elit consectetur aliquip excepteur fugiat ut qui dolor pariatur consectetur.riatur elit quis.",
277
- images: {
278
- desktop: {
279
- url: "http://fpoimg.com/1600x400?text=4:1",
280
- altText: "placeholder image"
281
- },
282
- mobile: {
283
- url: "http://fpoimg.com/1600x800?text=2:1",
284
- altText: "placeholder image"
285
- }
286
- },
287
- theme: theme1,
288
- focalPointImage: {
289
- x: 6000,
290
- y: 0,
291
- title: "union-station",
292
- height: 4000,
293
- width: 6000,
294
- url: "https://images.ctfassets.net/citn2sn5tdjr/4NzwDSDlGECGIiokKomsyI/f78a74130fc60ae9b4fb2e0da2f405db/city.jpg"
295
- },
296
- }
297
-
298
- return (
299
- <Hero2
300
- content={content}
301
- />
302
- );
303
- ```
304
-
305
- #### Hero3
306
-
307
- ###### Props -
308
-
309
- - `content` **(required)** - object containing `header`, `text`, `thumbnail`, and `video` data
310
-
311
- - `header` - string for the header content
312
- - `text` - string for the body text content
313
- - `thumbnail` - object for generating the thumbnail with `url` and `altText` strings
314
- - `url` **(required)** - string that points to the image source
315
- - `altText` - string for creating accessibility text
316
- - `video` - object for rendering the video embed
317
- - `url` - string that points to the video source on YouTube or Vimeo
318
- - `uuid` - string used for rendering Vidyard video embeds
319
- - `vidyard` - boolean for indicating that a Vidyard component should be rendered
320
- - `id` - string used for generating the component's id attribute. Will default to the organism's header text or the organism type.
321
- - `motion` - boolean that indicates whether to use the react-reveal library to render the component inside a `<Fade>` component.
322
- - `theme` - object with `backgroundColor` and `color` as strings to represent hex value for background color
323
- - `theme` - object with `backgroundColor` and `color` as strings to represent hex value for background color
324
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
325
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
326
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
327
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
328
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
329
- - `contentSide` string of either "left" or "right" which will dictate where the content will render.
330
-
331
- ###### Example -
332
-
333
- ```
334
- const content = {
335
- header: 'Video Header',
336
- text: 'This is descriptive text for the video',
337
- thumbnail: {
338
- url: 'www.youtube.com/123467890/thumbnail.jpg',
339
- altText: 'I am a thumbnail'
340
- },
341
- video: {
342
- url: 'www.youtube.com/123467890',
343
- allowFullScreen: true
344
- }
345
- }
346
-
347
-
348
- return (
349
- <Hero3
350
- content={content}
351
- theme={theme}
352
- motion
353
- />
354
- );
355
- ```
356
-
357
- ---
358
-
359
- #### Hero4/Hero5
360
-
361
- ###### Note -
362
-
363
- These two components are functionally the same from a React perspective but exist as separate entities in design. They are populated the same exact way and will always render a `Hero4` in your React tree.
364
-
365
- ###### Props -
366
-
367
- - `content` **(required)** - object containing header, subHeader, text, ctas, and image data
368
- - `header` **(required)** - string for generating header text
369
- - `subHeader` - string for generating sub-header text
370
- - `text` - string for generating body text
371
- - `ctas` - object for generating a `<CTASection>` component. Note that CTA should contain className for theme purposes.
372
- - previous theme-1, theme-2, and theme-3 has className `primary--1` for ctaOne and `secondary--1` for ctaTwo
373
- - previous theme-4 and theme-5 has className `primary--5` and `secondary--5`
374
- - `image` - object for generating <img> element with url and altText strings
375
- - `theme` - object with `backgroundColor` and `color` as strings to represent hex value for background color
376
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
377
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
378
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
379
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
380
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
381
- - `id` - string used for generating the component's id attribute. Will default to the organism's header text or the organism type.
382
- - `motion` - boolean that indicates whether to use the react-reveal library to render the component inside a `<Fade>` component.
383
- - `contentSide` - optional string of "left" or "right", which defaults to "left" - dictates what side of the screen the content renders.
384
- - `focalPointImage` - image object for focal point image. Consists of x & y coords along with image url.
385
-
386
- ###### Example -
387
-
388
- ```
389
- const mockCTALinks = {
390
- ctaOne: {
391
- text: "Button",
392
- url: "/#"
393
- },
394
- ctaTwo: {
395
- text: "Button",
396
- url: "/#"
397
- },
398
- subCTA: {
399
- text: "Button",
400
- url: "/#"
401
- }
402
- };
403
-
404
- const mockImage = {
405
- url: "./1-to-1.png",
406
- altText: "placeholder"
407
- };
408
-
409
- const content = {
410
- ctas: mockCTALinks,
411
- image: mockImage,
412
- header: 'Header',
413
- text: 'I am text',
414
- focalPointImage: {
415
- x: 6000,
416
- y: 0,
417
- title: "union-station",
418
- height: 4000,
419
- width: 6000,
420
- url: "https://images.ctfassets.net/citn2sn5tdjr/4NzwDSDlGECGIiokKomsyI/f78a74130fc60ae9b4fb2e0da2f405db/city.jpg"
421
- },
422
- }
423
-
424
- <Hero4
425
- content={content}
426
- motion
427
- theme='theme-1'
428
- />
429
- ```
430
-
431
- ---
432
-
433
- #### Hero7
434
-
435
- ###### Props -
436
-
437
- - `content` **(required)** - object containing images, header, text, ctas, and subHeader
438
-
439
- - `header` **(required)** - string for generating header text
440
- - `subHeader` - string for generating sub-header text
441
- - `ctas` - object for generating a `<CTASection>` component
442
- - `images` **(required)** - object consisting of three image objects, each with url and altText strings. The objects are `desktop`, `tablet`, and `mobile`.
443
-
444
- - `desktop` - object with `url` and `altText` strings for generating the desktop hero image
445
- - `url` - string that links to a 3x2 image source
446
- - `altText` - string for generating image accessibility text
447
- - `tablet` - object with `url` and `altText` strings for generating the desktop hero image
448
- - `url` - string that links to a 1x1 image source
449
- - `altText` - string for generating image accessibility text
450
- - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
451
- - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed - `mobile` - object with `url` and `altText` strings for generating the desktop hero image - `url` - string that links to a 4x3 image source - `altText` - string for generating image accessibility text
452
-
453
- -`theme` - string for hex value of color that will overlay on hero image. This defaults to `#000000`,
454
- - `focalPointImage` - image object for focal point image. Consists of x & y coords along with image url.
455
-
456
- ###### Example -
457
-
458
- ```
459
- const images = {
460
- desktop : {
461
- url: "http://fpoimg.com/2400x1600?text=3:2",
462
- altText: "placeholder image"
463
- },
464
- mobile: {
465
- url: "http://fpoimg.com/1600x1200?text=4:3",
466
- altText: "placeholder image"
467
- },
468
- tablet: {
469
- url: "http://fpoimg.com/1600x1600?text=1:1",
470
- altText: "placeholder image"
471
- }
472
- };
473
-
474
- const ctas = {
475
- ctaOne: {
476
- url: "/#",
477
- text: "Button"
478
- },
479
- ctaTwo: {
480
- url: "/#",
481
- text: "Button"
482
- }
483
- };
484
-
485
- const content {
486
- images,
487
- ctas,
488
- header: 'Header',
489
- subHeader: 'Text!',
490
- focalPointImage: {
491
- x: 6000,
492
- y: 0,
493
- title: "union-station",
494
- height: 4000,
495
- width: 6000,
496
- url: "https://images.ctfassets.net/citn2sn5tdjr/4NzwDSDlGECGIiokKomsyI/f78a74130fc60ae9b4fb2e0da2f405db/city.jpg"
497
- },
498
- }
499
-
500
- return (
501
- <Hero7
502
- content={content}
503
- theme='theme-1'
504
- />
505
- );
506
- ```
507
-
508
- #### FilterHero
509
-
510
- ###### Props -
511
-
512
- - `header` - string for generating header text
513
- - `text` - string for generating body text.
514
- - `dropdowns` - array used for generating Dropdown components - see example for structuring
515
- - `checkboxes` - array used for generating Checkbox components - see example for structuring
516
- - `handleDropdownChange` - function used for handling new dropdown selections - takes the new selection and the associated name of the dropdown from the event object arguments.
517
- - `handleCheckboxChange` - function used for handling checkbox toggling - takes a boolean for the status of the checkbox and the name of the checkbox from the event object as arguments.
518
- - `theme` - string indicating the theme that styles the organism. Options are `theme-1`, `theme-2`, `theme-3`, `theme-4`, `theme-5`.
519
- - `motion` - boolean that indicates whether to use the react-reveal library to render the component inside a `<Fade>` component.
520
- - `id` - string used for generating the component's id attribute. Will default to the organism's header text or the organism type.
521
-
522
- ###### Example -
523
-
524
- ```
525
- handleDropdownChange = (selection, name) => {
526
- this.setState({[name]: selection})
527
- }
528
-
529
- handleCheckboxChange = (bool, name) => {
530
- this.setState({[name]: bool})
531
- }
532
-
533
- const header = 'I am a header'
534
- const text = 'Tempor ex esse ipsum sit eiusmod dolor mollit cupidatat elit cupidatat pariatur commodo non est.'
535
-
536
- const dropdownOne = {
537
- options: ["trade one", "trade two", "trade three"],
538
- defaultText: "All",
539
- name: "Trade"
540
- };
541
- const dropdownTwo = {
542
- options: ["category one", "category two", "category three"],
543
- defaultText: "All",
544
- name: "Category"
545
- };
546
- const dropdowns = [dropdownOne, dropdownTwo]
547
-
548
- const checkboxOne = {
549
- name: "Checkbox One"
550
- };
551
- const checkboxTwo = { name: "Checkbox Two" };
552
- const checkboxes = [checkboxOne, checkboxTwo];
553
-
554
- return (
555
- <FilterHero
556
- header={header}
557
- text={text}
558
- dropdowns={dropdowns}
559
- checkboxes={checkboxes}
560
- handleDropdownChange={this.handleDropdownChange}
561
- handleCheckboxChange={this.handleCheckboxChange}
562
- backgroundColor='#5e5e5e'
563
- />
564
- )
565
- ```
566
-
567
- ---
568
-
569
- #### Feat1
570
-
571
- ###### Props -
572
-
573
- - `content` **(required)** - object containing the objects content (see example)
574
- - `header` **(required)** - string for generating header text
575
- - `subHeader` - string for generating sub-header text
576
- - `text` **(required)** - string for generating body text
577
- - `cta` - object for generating a `<ButtonLink>` component requiring `url` and `text` strings
578
- - `ctas` - array of objects for generating a `<CTASection>` component requiring `ctaOne` and/or `ctaTwo` objects with `url`, `text`, and `className` strings, takes precedence over the `cta` object
579
- - ctaClass names are important for themes. If no className is passed as a prop, the className will default to `primary--1` for ctaOne and `secondary--1` for ctaTwo. This is consistent for previous `theme-1`, `theme-2`, and `theme-3`. For `theme-4` and `theme-5`, use `className` of `primary--5` for ctaOne and `secondary--5` for ctaTwo
580
- - `image` **(required)** - object consisting of `url` and `altText` strings.
581
- - `Image` - optional Image component from gatsby-image to render images as gatsby-images instad of HTML `<img />`
582
- - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
583
- - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
584
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
585
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
586
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
587
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
588
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
589
- - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
590
- - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
591
- - `Link` - optional - either a react-router-dom or gatsby-link component
592
-
593
- - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
594
- - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
595
-
596
- ###### Example -
597
-
598
- ```
599
- const content = {
600
- header: 'Header',
601
- subHeader: 'Sub Header',
602
- text: '<p>Sunt elit officia id aute esse dolore elit Lorem officia.</p>'
603
- cta: {
604
- url: '/',
605
- text: 'link'
606
- },
607
- image: {
608
- url: '/',
609
- altText: 'Image'
610
- },
611
- theme: {
612
- backgroundColor: "blue",
613
- color: "green"
614
- }
615
- }
616
-
617
- return (
618
- <Feat1
619
- content={content}
620
- motion
621
- id={data.id}
622
- />
623
- );
624
- ```
625
-
626
- ---
627
-
628
- #### Feat2A
629
-
630
- ###### Props -
631
-
632
- - `image` **(required)** - object for generating the left-side image
633
- - `url` - string that points to the source of the image
634
- - `altText` - string for generating accessibility text
635
- - `Image` - optional Image component from gatsby-image to render images as gatsby-images instad of HTML `<img />`
636
-   - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
637
- - `<AccordionFold>` **(required)** - child component for rendering folds in the `<Accordion>` component with each fold taking a `header` string as a prop
638
- - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
639
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
640
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
641
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
642
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
643
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
644
- - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
645
- - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
646
-
647
- ###### Example -
648
-
649
- ```
650
- import { AccordionFold } from 'terra-component-lib'
651
-
652
- const mockImage = {
653
- url: "https://fpoimg.com/500x500",
654
- altText: "Placeholder image"
655
- };
656
-
657
- const content = {
658
- header: "I am a header!",
659
- subHeader: "This is a sub header. ",
660
- theme: {
661
- color: "#363545",
662
- backgroundColor: "#ffffff",
663
- };
664
- }
665
-
666
- return (
667
- <Feat2A
668
- image={mockImage}
669
- content={content}
670
- >
671
- <AccordionFold header="Test one">
672
- <p>
673
- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer
674
- lobortis augue ligula, eget gravida tellus lacinia id. Sed ultricies
675
- mi malesuada tincidunt dapibus. Donec porta ligula sagittis elit
676
- sollicitudin.
677
- </p>
678
- </AccordionFold>
679
- <AccordionFold header="Test two">
680
- <p>
681
- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer
682
- lobortis augue ligula, eget gravida tellus lacinia id. Sed ultricies
683
- mi malesuada tincidunt dapibus. Donec porta ligula sagittis elit
684
- sollicitudin.
685
- </p>
686
- </AccordionFold>
687
- <AccordionFold header="Test three">
688
- <p>
689
- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer
690
- lobortis augue ligula, eget gravida tellus lacinia id. Sed ultricies
691
- mi malesuada tincidunt dapibus. Donec porta ligula sagittis elit
692
- sollicitudin.
693
- </p>
694
- </AccordionFold>
695
- </Feat2>
696
- );
697
- ```
698
-
699
- ---
700
-
701
- #### Feat2B
702
-
703
- ###### Props -
704
-
705
- - `content` **(required)** - object containing images and cards
706
-
707
- - `images` **(required)** - object for generating images
708
- - `desktop` **(required)** - object for generating the desktop image
709
- - `url` - string that points to the image source
710
- - `altText` - string for generating image accessibility text
711
- - `mobile` **(required)** - object for generating the mobile image
712
- - `url` - string that points to the image source
713
- - `altText` - string for generating image accessibility text
714
- - `cards` **(required)** - array of objects for generating `IconListItem`
715
- - `header` - string for generating card header text
716
- - `text` - string for generating card descriptive text
717
- - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
718
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
719
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
720
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
721
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
722
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
723
-
724
- - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
725
- - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
726
-
727
- ###### Example -
728
-
729
- ```
730
- const content = {
731
- images: {
732
- desktop: {
733
- url: "http://fpoimg.com/1600x400?text=4:1",
734
- altText: "placeholder image"
735
- },
736
- mobile: {
737
- url: "http://fpoimg.com/1600x800?text=2:1",
738
- altText: "placeholder image"
739
- }
740
- },
741
- cards: [
742
- {
743
- header: "Header",
744
- text:
745
- "Anim aliquip aliqua aliqua id qui aute anim reprehenderit tempor velit est sint laborum."
746
- },
747
- {
748
- header: "Header",
749
- text:
750
- "Anim aliquip aliqua aliqua id qui aute anim reprehenderit tempor velit est sint laborum."
751
- },
752
- {
753
- header: "Header",
754
- text:
755
- "Anim aliquip aliqua aliqua id qui aute anim reprehenderit tempor velit est sint laborum."
756
- }
757
- ],
758
- theme: {
759
- color: "#363545",
760
- backgroundColor: "#ffffff",
761
- }
762
- }
763
-
764
- return (
765
- <Feat2B
766
- content={content}
767
- motion
768
- id={data.id}
769
- />
770
- );
771
- ```
772
-
773
- ---
774
-
775
- #### Feat3
776
-
777
- ###### Description -
778
-
779
- Featurette with a large image, header, and sub-header text
780
-
781
- ###### Props -
782
-
783
- - `content` **(required)** - object containing, images, header, and text
784
- - `header` - string used for generating the feat header
785
- - `subHeader` - string used for generating the feat sub-header
786
- - `images` - object containing mobile and desktop images
787
- - `mobile` - object containing the mobile image source and alt text
788
- - `src` - string pointing to the image source
789
- - `alt` - string used for assisted alternate text for screen readers
790
- - `desktop` - object containing the desktop image source and alt text
791
- - `src` - string pointing to the image source
792
- - `alt` - string used for assisted alternate text for screen readers
793
- - `motion` - boolean indicating if component animation is active
794
- - `id` - string used for generating the component's id, defaults to the header text (spaces removed)
795
- - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
796
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
797
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
798
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
799
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
800
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
801
-
802
- ###### Example -
803
-
804
- ```
805
- const content = {
806
- header: "Feat 3 Header",
807
- subHeader: "This is sub-header text",
808
- images: {
809
- mobile: {
810
- src: "www.image.com/mobile-image.jpg",
811
- alt: "image alt text
812
- },
813
- desktop: {
814
- src: "www.image.com/desktop-image.jpg",
815
- alt: "image alt text
816
- }
817
- },
818
- theme: {
819
- backgroundColor: "#f2f2f2",
820
- color: "#333333"
821
- },
822
- motion: true
823
- }
824
-
825
- return <Feat3 content={content} />
826
- ```
827
-
828
- ---
829
-
830
- #### Feat4
831
-
832
- ###### Props -
833
-
834
- - content **(required)** - object containing, ctas, headers, subheaders
835
-
836
- - `header` **(required)** - string used for generating header text
837
- - `subHeader` **(required)** - string used for generating sub-header text
838
-
839
- - `ctas` - objects for generating a `<CTASection>` component requiring `ctaOne` and/or `ctaTwo` objects with `url`, `text`, and `className` strings, takes precedence over the `cta` object
840
-
841
- - ctaClass names are important for themes. If no className is passed as a prop, the className will default to `primary--1` for ctaOne and `secondary--1` for ctaTwo. This is consistent for previous `theme-1`, `theme-2`, and `theme-3`. For `theme-4` and `theme-5`, use `className` of `primary--5` for ctaOne and `secondary--5` for ctaTwo
842
-
843
- - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
844
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
845
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
846
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
847
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
848
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
849
-
850
- - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
851
- - `motion` - object containing `motion`, `motionDistance`, and `motionDirection` keys. -`motion` value is a boolen to indicate if motion will be on this component -`motionDistance` - string indicating the direction that the component should travel from as it fades in -`motionDirection` - string indicating the distance that the component travels during motion.
852
- - `Link` - optional - either a react-router-dom or gatsby-link component
853
- - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
854
- - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
855
-
856
- ###### Example -
857
-
858
- ```
859
- const content = {
860
- header:"Good Design is innovative",
861
- subHeader:"Esse aliquip ad in et ut ipsum paEu elit consectetur aliquip excepteur fugiat ut qui dolor pariatur consectetur.riatur elit quis.",
862
- ctas:{
863
- ctaOne: {
864
- text: "Button",
865
- url: "/#"
866
- },
867
- ctaTwo: {
868
- text: "Button",
869
- url: "/#"
870
- }
871
- },
872
- theme: {
873
- color: "#363545",
874
- backgroundColor: "#ffffff",
875
- },
876
- }
877
-
878
- return (
879
- <Feat4
880
- content={content}
881
- />
882
- );
883
- ```
884
-
885
- ---
886
-
887
- #### Feat5
888
-
889
- ###### Props -
890
-
891
- - `content` **(required)** - object for generating organism content
892
-
893
- - `header` **(required)** - string used for generating header text
894
- - `subHeader` - string used for generating sub-header text
895
- - `thumbnail` - object for generating the thumbnail with `url` and `altText` strings - `url` **(required)** - string that points to the image source - `altText` - string for creating accessibility text - `Image` - optional Image component from gatsby-image to render images as gatsby-images instad of HTML `<img />`
896
-   - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
897
- - `video` - object for rendering the video embed
898
- - `url` - string that points to the video source on YouTube or Vimeo
899
- - `uuid` - string used for rendering Vidyard video embeds
900
- - `vidyard` - boolean for indicating that a Vidyard component should be rendered
901
- - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
902
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
903
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
904
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
905
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
906
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
907
-
908
- - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
909
- - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
910
- - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
911
-   - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
912
-
913
- ###### Example -
914
-
915
- ```
916
- const content = {
917
- header: 'Video Header',
918
- text: 'This is descriptive text for the video',
919
- thumbnail: {
920
- url: 'www.youtube.com/123467890/thumbnail.jpg',
921
- altText: 'I am a thumbnail'
922
- },
923
- video: {
924
- url: 'www.youtube.com/123467890',
925
- allowFullScreen: true
926
- },
927
- theme: {
928
- color: "#363545",
929
- backgroundColor: "#ffffff",
930
- },
931
- }
932
-
933
-
934
- return (
935
- <Feat5
936
- content={content}
937
- motion
938
- />
939
- );
940
- ```
941
-
942
- ---
943
-
944
- #### Feat7
945
-
946
- ###### Props -
947
-
948
- - `content` **(required)** - array of objects used for generating organism content
949
- - `header` - string used for generating header text
950
- - `subHeader`- string used for generating sub-header text
951
- - `theme` - object with `backgroundColor`, `color`, `activeTabBarColor`, `activeTabTextColor`, and `inactiveTabBarColor` as strings to represent hex value for background color
952
- - `Theme Colors:`
953
- - Props to pass into component for `theme-1`:
954
- - `color`: `#98A0AB`
955
- - `backgroundColor`: `#F8F8FB"`,
956
- - `activeTabBarColor`: `#0063A3`,
957
- - `ativeTabTextColor`: `#0063A3`,
958
- - `inactiveTabBarColor`: `#ffffff`,
959
- - `introTextColor`: `#242D2F`
960
- - Props to pass into component fot `theme-2`:
961
- - `color`: `#98A0AB`
962
- - `backgroundColor`: `#F1F2F7"`,
963
- - `activeTabBarColor`: `#0063A3`,
964
- - `ativeTabTextColor`: `#0063A3`,
965
- - `inactiveTabBarColor`: `#ffffff`,
966
- - `introTextColor`: `#242D2F`
967
- - Props to pass into component fot `theme-3`:
968
- - `color`: `#98A0AB`
969
- - `backgroundColor`: `#E7E9EF"`,
970
- - `activeTabBarColor`: `#0063A3`,
971
- - `ativeTabTextColor`: `#0063A3`,
972
- - `inactiveTabBarColor`: `#ffffff`,
973
- - `introTextColor`: `#242D2F`
974
- - Props to pass into component fot `theme-4`:
975
- - `color`: `#B6BCC5`
976
- - `backgroundColor`: `#0063A3"`,
977
- - `activeTabBarColor`: `#FFFFFF`,
978
- - `ativeTabTextColor`: `#FFFFFF`,
979
- - `inactiveTabBarColor`: `#217cbb`,
980
- - `introTextColor`: `#FFFFFF`
981
- - Props to pass into component fot `theme-5`:
982
- - `color`: `#98A0AB`
983
- - `backgroundColor`: `#004F83"`,
984
- - `activeTabBarColor`: `#FFFFFF`,
985
- - `ativeTabTextColor`: `#FFFFFF`,
986
- - `inactiveTabBarColor`: `#0063a3`,
987
- - `introTextColor`: `#FFFFFF`
988
- - `children` - React components used for generating a Terra Tabs component. The children should consist of `TabsPanel` components. See Terra One documentation for details.
989
-
990
- - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
991
- - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
992
-
993
- ###### Example -
994
-
995
- ```
996
- const content = {
997
- header: 'Tabs Header',
998
- subHeader: null,
999
- theme: {
1000
- color: "#363545",
1001
- backgroundColor: "#f9f9fb",
1002
- activeTabBarColor: "#0e6ba8",
1003
- activeTabTextColor: "#0e6ba8",
1004
- }
1005
- }
1006
-
1007
- return (
1008
- <Feat7 content={content} motion>
1009
- <TabsPanel name='Tab One'>
1010
- <p>Ea eiusmod non nulla incididunt officia do nostrud.</p>
1011
- <TabsPabel>
1012
- <TabsPanel name='Tab Two'>
1013
- <p>Tempor eiusmod nulla et dolore et magna veniam elit proident ullamco.</p>
1014
- <TabsPabel>
1015
- <TabsPanel name='Tab Three'>
1016
- <p>Id nostrud id ut elit excepteur sit incididunt Lorem aliquip.</p>
1017
- <TabsPabel>
1018
- </Feat7>
1019
- )
1020
- ```
1021
-
1022
- #### Feat8
1023
-
1024
- ###### Props -
1025
-
1026
- - `content` **(required)** - object containing the objects content (see example)
1027
- - `header` **(required)** - string for generating header text
1028
- - `subHeader` - string for generating sub-header text
1029
- - `text` **(required)** - string for generating body text
1030
- - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
1031
-
1032
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
1033
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
1034
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
1035
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
1036
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
1037
-
1038
- - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
1039
- - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
1040
- - `darkTheme` - boolean which indicates whether a dark theme is used - will toggle css class on body copy to use inverse colour as per global styles. Defaults to `false`.
1041
- - `headerAlignment` - boolean to control alignment of `header`. Default option is `left`, with `center` as alternative option.
1042
- - `subHeaderAlignment` - boolean to control alignment of `subHeader`. Default option is `left`, with `center` as alternative option.
1043
-
1044
- #### SlideOut Feat
1045
-
1046
- ###### Props -
1047
-
1048
- - `content` **(required)** - object containing header, text, ctas, and image
1049
- - `header` **(required)** - string for generating header text
1050
- - `text` **(required)** - string for generating body text either HTML or plain text
1051
- - `ctas` - objects for generating a `<CTASection>` component requiring `ctaOne` and/or `ctaTwo` objects with `url`, `text`, and `className` strings, takes precedence over the `cta` object
1052
- - `image` object with `url` as key.
1053
-
1054
- ###### Example -
1055
-
1056
- ```
1057
- const content = {
1058
- image: {
1059
- url: image,
1060
- },
1061
- header: "I am a header",
1062
- text:
1063
- "<p>Voluptate nisi sint nisi ullamco nulla aute ullamco eiusmod. Exercitation cillum anim aliqua nulla occaecat eiusmod.</p>",
1064
- ctas: {
1065
- ctaOne: {
1066
- url: "/",
1067
- text: "CTA",
1068
- },
1069
- ctaTwo: {
1070
- url: "/",
1071
- text: "CTA Two",
1072
- },
1073
- },
1074
- };
1075
-
1076
-
1077
- return (
1078
- SlideOutFeat content={content} />
1079
- );
1080
- ```
1081
-
1082
- ---
1083
-
1084
- #### ListFeat1
1085
-
1086
- ###### Props -
1087
-
1088
- - `content` **(required)** - object containing all organism content
1089
-
1090
- - `header` - string for generating organism header text
1091
- - `subHeader` - string for generating organism sub-header text
1092
- - `ctas` - object used to populate a `<CTASection>`
1093
- - `ctaOne`: object with `text`, `url` and `className` strings
1094
- - `ctaTwo`: object with `text`, `url` and `className` strings
1095
- - Important to note that `className` corresponds to theme.
1096
- - previous `theme-1`, `theme-2`, and `theme-3` take `classNames` of `primary--1` and `secondary--1` respectively
1097
- - previous `theme-4` and `theme-5` take `classNames` of `primary--2` and `secondary--2` respectively.
1098
- - `subCTA`: object with `text` and `url` strings
1099
- - `cardOne`, `cardTwo` - objects that contains `header` and `text` keys with values that are strings.
1100
- - `header` - string for card header text
1101
- - `text` - string for card body text
1102
- - `cta` - object for generating a cta on the card
1103
- - `url` - string to generates the cta's link href
1104
- - `text` - string for generating the cta's text
1105
- - `cards` - array of objects with structure matching `cardOne` or `cardTwo`
1106
- - `type` **(required)** - required to render the correct listFeat. ListFeat1 must be `list_feat_1`
1107
-
1108
- - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1109
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1110
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1111
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1112
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1113
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1114
-
1115
- * `motion` - boolean used to indicate whether or not motion should be used
1116
- * `Link` - optional - either a react-router-dom or gatsby-link component
1117
-
1118
- ###### Example -
1119
-
1120
- ```
1121
-
1122
- theme1 = {
1123
- color: "#363545",
1124
- backgroundColor: "#ffffff",
1125
- };
1126
-
1127
- const content = {
1128
- sort: true,
1129
- header: "Hello everyone! This is a header. Enjoy!",
1130
- subHeader: "This is truly wonderful.",
1131
- type: "list_feat_1",
1132
- image: { src: "https://fpoimg.com/500x500", alt: "placeholder" },
1133
- cardOne: {
1134
- header: "I am Card One Header",
1135
- text:
1136
- "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex",
1137
- cta: { url: "/#", text: "Click me!", className: "primary--1" }
1138
- },
1139
- cardTwo: {
1140
- header: "I am Card Two Header",
1141
- text:
1142
- "The purpose of lorem ipsum is to create a natural looking block of text (sentence, paragraph, page, etc.) that doesn't distract from the layout. A practice not without controversy, la",
1143
- cta: { url: "/#", text: "I am a button!", "secondary--1" }
1144
- },
1145
- theme: theme1
1146
- };
1147
-
1148
- return (
1149
- <ListFeat content={content} motion />
1150
- )
1151
- ```
1152
-
1153
- #### ListFeat2
1154
-
1155
- ###### Props -
1156
-
1157
- - `content` **(required)** - object containing text, headers, subheaders, headShotdumplings, and type
1158
-
1159
- - `header` - string for generating organism header text
1160
- - `subHeader` - string for generating organism sub-header text
1161
- - `headShotdumplings` **(required)** - array of objects for generating headshot dumplings
1162
- - `header` - string for generating dumpling header text
1163
- - `subHeader` - string for generating dumpling sub-header text
1164
- - `text` - string for generating dumpling body text
1165
- - `color` - string to indicate color of text in headshotDumpling
1166
- - `image` - object for generating dumpling image
1167
- - `url` - string for the image's source
1168
- - `altText` - string for the image's accessibility text
1169
- - `filter` - string for indicating whether or not to use a colored overlay for the image. Options are "blue" and "grey"
1170
- - `type` **(required)** - required to render the correct listFeat. ListFeat2 must be `list_feat_2`
1171
- - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1172
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1173
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1174
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1175
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1176
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1177
-
1178
- - `motion` - boolean used to indicate whether or not motion should be used
1179
- - `Link` - optional - either a react-router-dom or gatsby-link component
1180
-
1181
- ###### Example -
1182
-
1183
- ```
1184
- theme1 = {
1185
- color: "#363545",
1186
- backgroundColor: "#ffffff",
1187
- };
1188
-
1189
-
1190
- const content = {
1191
- header: "Hello everyone! This is a header. Enjoy!",
1192
- subheader: "This is truly wonderful.",
1193
- type: "list_feat_2",
1194
- headShotdumplings: [
1195
- {
1196
- content: {
1197
- header: "Lorem Ipsum",
1198
- image: { url: "https://fpoimg.com/150x150", altText: "FPO Image" },
1199
- color: "pink",
1200
- },
1201
- filter: "default"
1202
- },
1203
- {
1204
- content: {
1205
- header: "Nemo enim ipsam",
1206
- image: { url: "https://fpoimg.com/150x150", altText: "FPO Image" },
1207
- color: "pink"
1208
- },
1209
- filter: "default"
1210
- },
1211
- {
1212
- content: {
1213
- header: "Sed ut perspiciatis",
1214
- image: { url: "https://fpoimg.com/150x150", altText: "FPO Image" },
1215
- color: "pink"
1216
- },
1217
- filter: "default"
1218
- }
1219
- ],
1220
- theme: theme1
1221
- };
1222
-
1223
- return (
1224
- <ListFeat content={content} motion />
1225
- )
1226
- ```
1227
-
1228
- #### ListFeat4
1229
-
1230
- ###### Props -
1231
-
1232
- - `content` **(required)** - object containing header, subHeader, type, cards
1233
- - `header` - key that has a string as a value
1234
- - `subHeader` - key that has a string as a value
1235
- - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1236
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1237
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1238
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1239
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1240
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1241
- - `dumplings` - array containing objects for generating dumplings.
1242
- - `header` - string for generating dumpling header text
1243
- - `link` - object for generating dumpling link, is optional
1244
- - `url` - string for generating the link href/to
1245
- - `icon` - object for generating the dumpling's icon
1246
- - `size` - string with a number and 'px' for indicating the icon's size
1247
- - `type` - string for indicating the type of icon to render. See the Terra One icon options for reference
1248
- - `color` - string for inddicating the hex color for icon and text. This will default to #000000
1249
- - `type` **(required)** - required to render the correct listFeat. ListFeat4 must be `list_feat_4`
1250
- - `motion` - boolean used to indicate whether or not motion should be used
1251
- - `Link` - optional - either a react-router-dom or gatsby-link component
1252
-
1253
- ###### Example -
1254
-
1255
- ```
1256
- theme1 = {
1257
- color: "#363545",
1258
- backgroundColor: "#ffffff",
1259
- };
1260
-
1261
- const content = {
1262
- header: "Hello everyone! This is a header. Enjoy!",
1263
- subheader: "This is truly wonderful.",
1264
- type: "list_feat_4",
1265
- dumplings: [
1266
- {
1267
- header: "Lorem Ipsum",
1268
- link: { url: "/#" },
1269
- size: "small",
1270
- icon: { type: "enclosed-check-dark-48px", size: "48px" },
1271
- color: "blue"
1272
- },
1273
- {
1274
- header: "Nemo enim ipsam voluptatem",
1275
- link: { url: "/#" },
1276
- size: "small",
1277
- icon: { type: "enclosed-check-dark-48px", size: "48px" }
1278
- color: "blue"
1279
- },
1280
- {
1281
- header: "Sed ut perspiciatis, unde omnis",
1282
- link: { url: "/#" },
1283
- size: "small",
1284
- icon: { type: "enclosed-check-dark-48px", size: "48px" }
1285
- color: "blue"
1286
- }
1287
- ],
1288
- theme: theme1
1289
- };
1290
-
1291
-
1292
-
1293
- return (
1294
- <ListFeat content={content} motion/>
1295
- )
1296
- ```
1297
-
1298
- #### ListFeat5
1299
-
1300
- ###### Props -
1301
-
1302
- - `content` **(required)** - object containing header, subHeader, type, cards
1303
-
1304
- - `header` - key that has a string as a value
1305
- - `subHeader` - key that has a string as a value -`insertCardHTML` - key that is a boolean
1306
- - `iconListItems` - array of objects for generating `IconListItem`
1307
- - `header` - string for generating card header text
1308
- - `text` - string for generating card descriptive text
1309
- - `type` - string for indicating type of icon to render, see Terra One for options, defaults to a checkmark
1310
- - `color` - string for indicating hex value for color of icon.
1311
- - `type` **(required)** - required to render the correct listFeat. ListFeat5 must be `list_feat_5`
1312
- - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1313
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1314
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1315
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1316
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1317
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1318
-
1319
- - `motion` - boolean used to indicate whether or not motion should be used
1320
- - `Link` - optional - either a react-router-dom or gatsby-link component
1321
-
1322
- ###### Example -
1323
-
1324
- ```
1325
- theme1 = {
1326
- color: "#363545",
1327
- backgroundColor: "#ffffff",
1328
- };
1329
-
1330
- const content = {
1331
- header: "Hello everyone! This is a header. Enjoy!",
1332
- subheader: "This is truly wonderful.",
1333
- type: "list_feat_5",
1334
- insertCardHTML: true,
1335
- iconListItems: [
1336
- {
1337
- header: "Good design is innovative",
1338
- text:
1339
- "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>",
1340
- color: "pink"
1341
- },
1342
- {
1343
- header: "Good design is innovative",
1344
- text:
1345
- "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>"
1346
- color: "pink"
1347
- },
1348
- {
1349
- header: "Good design is innovative",
1350
- text:
1351
- "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>"
1352
- color: "pink"
1353
- },
1354
- {
1355
- header: "Good design is innovative",
1356
- text:
1357
- "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>"
1358
- color: "pink"
1359
- },
1360
- {
1361
- header: "Good design is innovative",
1362
- text:
1363
- "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>"
1364
- },
1365
- {
1366
- header: "Good design is innovative",
1367
- text:
1368
- "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>"
1369
- }
1370
- ],
1371
- theme: theme1
1372
- };
1373
-
1374
-
1375
- return (
1376
- <ListFeat content={content} motion />
1377
- )
1378
- ```
1379
-
1380
- #### ListFeat6
1381
-
1382
- ###### Props -
1383
-
1384
- - `content` **(required)** - object containing header, subHeader, type, cards
1385
-
1386
- - `header` - key that has a string as a value
1387
- - `subHeader` - key that has a string as a value
1388
- - `images` - key that has an object as a value. Object has `src` and `altText` keys which values are strings.
1389
- - `list` - array containing strings in each indice. The strings of each indice will be rendered onto the component as html tags
1390
- - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1391
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1392
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1393
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1394
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1395
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1396
-
1397
- - `motion` - boolean used to indicate whether or not motion should be used
1398
- - `Link` - optional - either a react-router-dom or gatsby-link component
1399
-
1400
- ###### Example -
1401
-
1402
- ```
1403
- theme1 = {
1404
- color: "#363545",
1405
- backgroundColor: "#ffffff",
1406
- };
1407
-
1408
- const content = {
1409
- header: "Hello everyone! This is a header. Enjoy!",
1410
- subheader: "This is truly wonderful.",
1411
- images: { src: "https://fpoimg.com/500x500", alt: "placeholder" },
1412
- type: "list_feat_6",
1413
- list: [
1414
- "<h4>Viewer Edition</h4><p>Lorem ipsum dolor sit amet consectetur adipiscing elit</p><p>Donec sit amet arcu nibh. Donec vitae dolor nunc.</p><p>Mauris ut feugiat mauris eu volutpat arcu. Integer mollis neque dui ac auctor dui tincidunt eget.</p>",
1415
- "<h4>Field Data Edition</h4>p>Lorem ipsum dolor sit amet consectetur adipiscing elit</p><p>Lorem ipsum dolor sit amet consectetur adipiscing elit</p>",
1416
- "<h4>A list of great ideas:</h4><ul><li>Lorem ipsum dolor sit amet consectetur adipiscing elit</li><li>Donec sit amet arcu nibh Donec vitae dolor nunc.</li><li>Cras vel pharetra augue at sollicitudin velit. Vivamus dapibus quis nisi et vestibulum.</li><li>Mauris ut feugiat mauris eu volutpat arcu. Integer mollis neque dui ac auctor dui tincidunt eget.</li><ul>",
1417
- "<h4>Here It Is: </h4><ul><li>Lorem ipsum dolor sit amet consectetur adipiscing elit</li><li>Donec sit amet arcu nibh Donec vitae dolor nunc.</li><li>Cras vel pharetra augue at sollicitudin velit. Vivamus dapibus quis nisi et vestibulum.</li><li>Mauris ut feugiat mauris eu volutpat arcu. Integer mollis neque dui ac auctor dui tincidunt eget.</li><li>It's not Latin, though it looks like it, and it actually says nothing,</li><ul>"
1418
- ],
1419
- theme: theme1
1420
- };
1421
-
1422
-
1423
-
1424
- return (
1425
- <ListFeat content={content} motion />
1426
- )
1427
- ```
1428
-
1429
- #### ListFeat7
1430
-
1431
- ###### Props -
1432
-
1433
- - `content` **(required)** - object containing header, subHeader, type, cards
1434
- - `header` **(required)** - string for generating header text
1435
- - `subHeader` - string for generating sub-header text
1436
- - `type` **(required)** - required to render the correct listFeat. ListFeat7 must be `list_feat_7`
1437
- - `content` **(required)** - object containing images, ctas, text, variant, headers, subheaders, button, link, videos
1438
- - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1439
- - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1440
- - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1441
- - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1442
- - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1443
- - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1444
- - `card` - an array containing the following objects:
1445
- - `text` - string for generating body text
1446
- - `ctas` - object for generating a `<CTASection>` component
1447
- - `images` - object with keys `url` and `altText` with values as strings
1448
- - `video` - object with keys `url` and `allowFullScreen`. `url` has a value as a string. `allowFullScreen` is a boolean
1449
- - `uuid` - string used for rendering Vidyard video embeds
1450
- - `vidyard` - boolean for indicating that a Vidyard component should be rendered
1451
- - `thumbnail` - object with keys `url` and `altText` with values as strings, used for a thumbnail image in place of a video, while video is not playing
1452
- - `link` - object with keys `url` and `text` with values as strings.
1453
- - `Image` - optional Image component from gatsby-image to render images as gatsby-images instad of HTML `<img />`
1454
- - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
1455
- - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
1456
- - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
1457
- - `motion` - boolean used to indicate whether or not motion should be used
1458
- - `Link` - optional - either a react-router-dom or gatsby-link component
1459
-
1460
- ###### Example -
1461
-
1462
- ```
1463
- const theme1 = {
1464
- color: "#363545",
1465
- backgroundColor: "#ffffff",
1466
- ctaOne: "primary--1",
1467
- };
1468
-
1469
- export const mockContent = {
1470
- header: "Hello everyone! This is a header. Enjoy!",
1471
- subheader: "This is truly wonderful.",
1472
- type: "list_feat_7",
1473
- cards: [
1474
- {
1475
- video: {
1476
- url: "https://www.youtube.com/embed/UY7r0juBF8Y",
1477
- allowFullScreen: "true"
1478
- },
1479
- thumbnail: {
1480
- url: "https://fpoimg.com/2880x1920",
1481
- altText: "fpo"
1482
- },
1483
- header: "Here is a title! Woooo",
1484
- link: {
1485
- url: "/#",
1486
- text: "Link"
1487
- },
1488
- text:
1489
- "Ut in amet id proident commodo officia cillum. Aliqua id ex culpa labore duis minim fugiat proident ad deserunt qui."
1490
- },
1491
- {
1492
- video: {
1493
- url: "https://www.youtube.com/watch?v=sBws8MSXN7A",
1494
- allowFullScreen: "true"
1495
- },
1496
- thumbnail: {
1497
- url: "https://fpoimg.com/2880x1920",
1498
- altText: "fpo"
1499
- },
1500
- header: "This is a React Tutorial. Enjoy!",
1501
- link: {
1502
- url: "/#",
1503
- text: "Link"
1504
- },
1505
- text:
1506
- "Watch this and you'll be able to make beautiful applications using the wonderful framework of React, built by Facebook"
1507
- },
1508
- {
1509
- image: { url: "https://fpoimg.com/400x225", altText: "FPO Image" },
1510
- header: "Here is a title! Woooo",
1511
- link: {
1512
- url: "/#",
1513
- text: "Link"
1514
- },
1515
- text:
1516
- "It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout. It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout."
1517
- },
1518
- {
1519
- header: "Here is a title! Woooo",
1520
- subheader: "sub header! ",
1521
- text:
1522
- "It's difficult to find examples of lorem ipsum in use before Letraset made it popular as a dummy text in the 1960s, although McClintock says he remembers coming across the lorem ipsum passage in a book of old metal type samples. So far he hasn't relocated where he once saw the passage, but the popularity of Cicero in the 15th century supports the theory that the filler text has been used for centuries"
1523
- },
1524
- {
1525
- image: { url: "https://fpoimg.com/400x225", altText: "FPO Image" },
1526
- header: "Here is a title! Woooo",
1527
- link: {
1528
- url: "/#",
1529
- text: "Link"
1530
- },
1531
- text:
1532
- "It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout."
1533
- }
1534
- ],
1535
- theme: theme1
1536
- };
1537
-
1538
- return (
1539
- <ListFeat content={content} motion />
1540
- )
1541
- ```
1542
-
1543
- ## Miscellaneous organisms
1544
-
1545
- #### AdminCategoryData
1546
-
1547
- ###### Props -
1548
-
1549
- - `content` **(required)** - object containing name, industry, translations, url, and languageOptions
1550
- - `name` - string for generating header
1551
- - `industry` - string for generating subheader
1552
- - `translations` - array of objects
1553
- - `language` - string for language
1554
- - `teaserImage` - object with key value pair of `url` to represent image path
1555
- - `name` - string for name of product
1556
- - `text` - string for text description
1557
- - `languageOptions` - object with language abbreviations as key and value is language
1558
-
1559
- ###### Example -
1560
-
1561
- ```
1562
- const translations = [
1563
- {
1564
- language: "en",
1565
- teaserImage: { url: "http://fpoimg.com/95x95" },
1566
- name: "Product name",
1567
- text: "Dolore velit irure velit duis ea."
1568
- },
1569
- {
1570
- language: "fr",
1571
- teaserImage: { url: "http://fpoimg.com/95x95" },
1572
- name: "Product name, but in French",
1573
- text: "Dolore velit irure velit duis ea."
1574
- },
1575
- {
1576
- language: "de",
1577
- teaserImage: { url: "http://fpoimg.com/95x95" },
1578
- name: "Product name, but in German",
1579
- text: "Dolore velit irure velit duis ea."
1580
- }
1581
- ];
1582
-
1583
- const content = {
1584
- name: "Category name",
1585
- industry: "Industry name",
1586
- translations,
1587
- url: "/products/industry_name/category_name",
1588
- languageOptions: {
1589
- de: "German",
1590
- fr: "French",
1591
- en: "English"
1592
- }
1593
- };
1594
-
1595
- return (
1596
- <AdminCategoryData content={content} currentLanguageURL="en" />
1597
- )
1598
-
1599
- ```
1600
-
1601
- #### AdminProductData
1602
-
1603
- ###### Props -
1604
-
1605
- - `content` **(required)** - object containing name, regions, translations, url, and languageOptions
1606
- - `regions` - array of regions as strings
1607
- - `translations` - array of objects
1608
- - `language` - string for language
1609
- - `teaserImage` - object with key value pair of `url` to represent image path
1610
- - `name` - string for name of product
1611
- - `text` - string for text description
1612
- - `languageOptions` - object with language abbreviations as key and value is language
1613
-
1614
- ###### Example -
1615
-
1616
- ```
1617
- const translations = [
1618
- {
1619
- language: "en",
1620
- teaserImage: {
1621
- url: "http://fpoimg.com/95x95"
1622
- },
1623
- teaserName: "Product name",
1624
- teaserText: "Dolore velit irure velit duis ea."
1625
- },
1626
- {
1627
- language: "fr",
1628
- teaserImage: {
1629
- url: "http://fpoimg.com/95x95"
1630
- },
1631
- teaserName: "Product name, but in French",
1632
- teaserText: "Dolore velit irure velit duis ea."
1633
- },
1634
- {
1635
- language: "de",
1636
- teaserImage: {
1637
- url: "http://fpoimg.com/95x95"
1638
- },
1639
- teaserName: "Product name, but in German",
1640
- teaserText: "Dolore velit irure velit duis ea."
1641
- }
1642
- ];
1643
-
1644
- const content = {
1645
- name: "Product name",
1646
- regions: ["Illinois", "Colorado", "Ohio"],
1647
- translations,
1648
- url: "/products/product-name",
1649
- languageOptions: {
1650
- de: "Germand",
1651
- fr: "French",
1652
- en: "English"
1653
- }
1654
- };
1655
-
1656
- return (
1657
- <AdminProductData content={content} currentLanguageURL="en" />
1658
- )
1659
-
1660
- ```
1661
-
1662
- #### MiniFeatDropdown
1663
-
1664
- ###### Props -
1665
-
1666
- - `content` - object containing header, text, and dropdowns
1667
- - `header` - string to represent header
1668
- - `text` - string to represent text. Can be either HTML or plain text
1669
- - `dropdowns` - array of single object
1670
- - `dropdownOne` - object with key options, defaultText, and name
1671
- - `options` - array of strings to represent dropdown options
1672
- - `defaultTetx` - string to represent dropdown default option
1673
- - `name` - string to represent dropdown label
1674
-
1675
- ###### Example
1676
-
1677
- ```
1678
- const header = "How can we help you?";
1679
- const text =
1680
- "<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.</p>";
1681
- const dropdownOne = {
1682
- options: [
1683
- "General Contractor",
1684
- "Software Engineer",
1685
- "Cyber Security Analyst",
1686
- "Graphic Designer",
1687
- ],
1688
- defaultText: "Choose Your Fighter",
1689
- name: "I am a ...",
1690
- };
1691
-
1692
- const content = {
1693
- header,
1694
- text,
1695
- };
1696
-
1697
- return (
1698
- <MiniFeatDropdown
1699
- content={content}
1700
- dropdowns={dropdowns}
1701
- handleDropdownSelect={action("Dropdown Selected")}
1702
- />
1703
- )
1704
-
1705
- ```
1706
-
1707
- #### BrowserSupportBanner
1708
-
1709
- ###### Props -
1710
-
1711
- - `content` - object containing text, type, and browser
1712
- - `text` - string to represent text
1713
- - `type` - string to represent banner type. Options include "warning", "danger", and "success"
1714
- - `browser` - represents type of browser the alert should render on
1715
-
1716
- ###### Example
1717
-
1718
- ```
1719
- const content = {
1720
- text:
1721
- "WARNING: Internet Explorer is not recommended for use of this site. Please switch your browser to Chrome, Firefox, or Safari.",
1722
- type: "danger",
1723
- browser: "chrome",
1724
- };
1725
- return (
1726
-
1727
- <BrowserSupportBanner content={content} />
1728
- )
1729
-
1730
- ```
1731
-
1732
- #### SketchUp Pricing Card
1733
-
1734
- ###### Props -
1735
-
1736
- - `content` - object containing header, boldHeader, text, price, subscript, cta, icons, iconText, listtems, bottomLink, prevPrice, featured, featuredText, featuredColor
1737
- - `header` - string for generating header text (example: SketchUp)
1738
- - `boldHeader` - string for generating header type (example: Pro - will read as SketchUp Pro with Pro bolded)
1739
- - `text` - string to represent text
1740
- - `price` - string to generate price
1741
- - `subscript` - string to represent cost frequency ("yr", "month", etc)
1742
- - `cta` - object with key value pairs `text` and `url`
1743
- - `text` - string to represent CTA text
1744
- - `url` - string to represent path of where CTA links
1745
- - `icons` - array of icon in strings
1746
- - `listItems` - array of objects with key value pairs `items`, `featured`
1747
- - `item` - string to generate bullet point items on card
1748
- - `featured` - boolean: `true` will render "new" on card
1749
- - `bottomLink` - object with key value pairs `text` and `url`
1750
- - `text` - string to generate text for bottom link
1751
- - `url` - string to represent path for link
1752
- - `prevPrice` - string to represent previous price
1753
- - `featured` - boolean - `true` will render featuredText
1754
- - `featuredText` - string to generate featured text if card is featured
1755
- - `featuredColor` - string to generate color of featuredText background
1756
-
1757
- ###### Example
1758
-
1759
- ```
1760
-
1761
- const header = "SketchUp";
1762
- const boldHeader = "Pro";
1763
- const text = "Model Personal Projects";
1764
- const price = "$199";
1765
- const subscript = "/yr";
1766
- const cta = {
1767
- text: "Subscribe",
1768
- url: "/",
1769
- };
1770
- const icons = ["enclosed-x-dark-16px", "enclosed-arrow-right-dark-32px"];
1771
- const iconText = "Web Only";
1772
- const listItems = [
1773
- { item: "Lorem ipsum dolor site amet.", featured: false },
1774
- { item: "Lorem ipsum dolor sit, adipisicing.", featured: false },
1775
- {
1776
- item: "Lorem ipsum dolor site amet Lorite amet.",
1777
- featured: true,
1778
- },
1779
- ];
1780
-
1781
- const bottomLink = {
1782
- text: "Learn more about SHOP",
1783
- url: "/",
1784
- };
1785
- const prevPrice = "$299";
1786
-
1787
- const featured = true;
1788
- const featuredText = "Most Popular";
1789
- const featuredColor = "#0d6aa8";
1790
-
1791
- const content = {
1792
- header,
1793
- boldHeader,
1794
- text,
1795
- price,
1796
- subscript,
1797
- cta,
1798
- icons,
1799
- iconText,
1800
- listItems,
1801
- bottomLink,
1802
- prevPrice,
1803
- featuredColor,
1804
- featured,
1805
- featuredText,
1806
- };
1807
-
1808
- return (
1809
- <SketchUpPricingCard content={content} />
1810
- )
1811
-
1812
- ```
1813
-
1814
- #### StoreFront Card
1815
-
1816
- ###### Props -
1817
-
1818
- - `content` - object containing title, header, text, link, image, priceTitle, quantityTitle, price, button, and deliveryEstimation
1819
- - `title` - string to generate main title of card
1820
- - `header` - string to generate header of card
1821
- - `text` - string to represent the description
1822
- - `link` - object with key value pairs `text` and `url`
1823
- - `url` - string to represent the path for link
1824
- - `text` - string to represent text on link
1825
- - `priceTitle` - string to represent price label
1826
- - `price` - string to represent price
1827
- - `button` - object with key value pairs `url` and `text`
1828
- - `text` - string to represent text of button
1829
- - `url` - string to generate link path
1830
- - `deliveryEstimation` - string to represent delivery time
1831
-
1832
- ###### Example
1833
-
1834
- ```
1835
-
1836
- const title = "Trimble XR10";
1837
- const header = "Desgined for the frontline worker";
1838
- const text =
1839
- "Additional information: Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et aliqua";
1840
- const link = {
1841
- url: "/",
1842
- text: "Learn More",
1843
- };
1844
- const image = { url: "http://fpoimg.com/95x95", altText: "image" };
1845
- const priceTitle = "Price";
1846
- const quantityTitle = "Quantity";
1847
- const price = "$4750.00";
1848
- const button = { url: "Added", text: "Added" };
1849
- const deliveryEstimation = "Delivery: 4-6 weeks";
1850
-
1851
- const content = {
1852
- title,
1853
- header,
1854
- text,
1855
- link,
1856
- image,
1857
- priceTitle,
1858
- price,
1859
- button,
1860
- quantityTitle,
1861
- deliveryEstimation,
1862
- };
1863
- return (
1864
- <StoreFrontCard content={content} />
1865
- )
1866
-
1867
- ```
1868
-
1869
- #### SupportCard
1870
-
1871
- ###### Props -
1872
-
1873
- - `content` - object containing header, headerLabel, subHeader, product, subHeaderLabel, and sections
1874
- - `header` - string for generating the header
1875
- - `headerLabel` - string for generating header label
1876
- - `subHeader` - string for generating the subheader
1877
- - `product` - string for generating a product
1878
- - sections - array of arrays of objects to represent sections
1879
- - array of objects include key value pairs `value` and `format`
1880
- - `value` - text or HTML for each section
1881
- - `format` - optional - string to represent wysiwyg_editor
1882
-
1883
- ###### Example
1884
-
1885
- ```
1886
-
1887
- const sectionOne = [
1888
- {
1889
- value:
1890
- "<h1>Header</h1><p>Non anim voluptate eu cillum sunt voluptate ipsum laboris ipsum do irure.</p><a href='/#'>Link</a>",
1891
- format: "wysiwyg_editor",
1892
- },
1893
- {
1894
- value:
1895
- "<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus sollicitudin lectus ligula, nec tempus eros viverra sed. Curabitur malesuada, leo ut porta pretium, turpis turpis dignissim neque, convallis vulputate nisl ante id sapien. Donec efficitur, turpis et blandit ornare, lorem sem aliquet ligula, euismod condimentum dui quam quis purus.</p>\r\n\r\n<p>adadasd</p>\r\n\r\n<ul>\r\n\t<li>asdasd</li>\r\n\t<li>sfdsdfsd</li>\r\n\t<li>sdfsdf</li>\r\n</ul>\r\n",
1896
- format: "wysiwyg_editor",
1897
- },
1898
- {
1899
- value: "<p>Non anim voluptate eu cillum sunt.</p>",
1900
- format: "wysiwyg_editor",
1901
- },
1902
- {
1903
- value: '<a href="mailto:jeff@biscuits.com">Email me</a>',
1904
- },
1905
- ];
1906
-
1907
- const sectionTwo = [
1908
- {
1909
- value:
1910
- "<p>Non anim voluptate eu cillum sunt voluptate ipsum laboris ipsum do irure.</p>",
1911
- format: "w/e",
1912
- },
1913
- {
1914
- value: "<p>Veniam labore sunt tempor nulla commodo ullamco tempor.</p>",
1915
- format: "w/e",
1916
- },
1917
- ];
1918
-
1919
- const sectionThree = [
1920
- {
1921
- value:
1922
- "Non anim voluptate eu cillum sunt voluptate ipsum laboris ipsum do irure.",
1923
- format: "w/e",
1924
- },
1925
- {
1926
- value: "Veniam labore sunt tempor nulla commodo ullamco tempor.",
1927
- format: "w/e",
1928
- },
1929
- {
1930
- value: "Non anim voluptate eu cillum sunt. Okay",
1931
- format: "w/e",
1932
- },
1933
- ];
1934
-
1935
- const content = {
1936
- header: "Construction",
1937
- headerLabel: "Industry",
1938
- subHeader: "Civil Engineering Software",
1939
- product: "Novapoint and Quandri",
1940
- subHeaderLabel: "Categories",
1941
- sections: [sectionOne, sectionTwo, sectionThree],
1942
- };
1943
-
1944
- return (
1945
- <SupportCard content={content} />
1946
- )
1947
-
1948
- ```
1949
-
1950
- #### Trainer Card
1951
-
1952
- ###### Props -
1953
-
1954
- - `content` - object containing header, name, country, region, and link
1955
- - `header` - string to generate header
1956
- - `name` - string to generate name
1957
- - `country` - string to represent country
1958
- - link - object with key value pairs `url` and `text`
1959
- - `text` - string to represent button text
1960
- - `url` - string to represent url path
1961
-
1962
- ###### Example
1963
-
1964
- ```
1965
- const content = {
1966
- header: "Trainer",
1967
- name: "Sketchy McSketcherson",
1968
- country: "United States",
1969
- region: "North America",
1970
- link: {
1971
- url: "/",
1972
- text: "Get in touch",
1973
- },
1974
- };
1975
-
1976
- return (
1977
- <TrainerCard content={content} />
1978
- )
1979
-
1980
- ```
1981
-
1982
- ---
1983
-
1984
- ## Boilerplate Components, Hooks, and Methods
1985
-
1986
- #### `FooterHandler`
1987
-
1988
- ##### Description -
1989
-
1990
- Takes the footer data from `App` and uses it to render `Footer`. Was broken out of Template to keep the component nice and lean.
1991
-
1992
- ##### Props -
1993
-
1994
- - `data` **(required)** - object containing all `Footer` data. See [Footer](#footer) for reference
1995
-
1996
- ---
1997
-
1998
- #### `HelmetHandler`
1999
-
2000
- ##### Description -
2001
-
2002
- Takes the helmet data from `Template` and uses it to render `Helmet`. Was broken out of Template to keep the component nice and lean.
2003
-
2004
- ##### Props -
2005
-
2006
- - `data` **(required)** - object containing all `Helmet` data.
2007
- - `title` - string
2008
- - `canonical_url` - string
2009
- - `description` - string
2010
- - `language` - string for the current active language code
2011
-
2012
- ---
2013
-
2014
- #### NavBarHandler
2015
-
2016
- ##### Description -
2017
-
2018
- Takes the navigation data from `App` and uses it to render `NavBar`. Was broken out of Template to keep the component nice and lean.
2019
-
2020
- ##### Props -
2021
-
2022
- - `data` **(required)** - object containing all `NavBar` data.
2023
- - `innerPageNavData` - object used for populating the utility nav
2024
- - `history`**(required)** - the React Router `history` object
2025
- - `regionData` - object with `region`, `regions`, and method for `setRegion` from `App`
2026
- - `applicationData` - object with the site data from `App`
2027
- - `languages` - array of available languages
2028
- - `language` - string with active language code
2029
- - `setLanguage` - method for setting the active language
2030
- - `navCTAOverride` - object used to override the utility nav CTA
2031
-
2032
- ---
2033
-
2034
- #### Routing
2035
-
2036
- ##### Description -
2037
-
2038
- Takes all the passed information from App and uses it to render the all routes.
2039
-
2040
- ##### Props -
2041
-
2042
- - `routes` - array of available route strings
2043
- - `languages` - array of available languages
2044
- - `language` - string with active language code
2045
- - `setMetaData` - method for setting active metadata in React Helmet
2046
- - `setInnerPageNavData` - method for setting active inner-page navigation
2047
- - `fiveHundreData` - object for populating the 500 page
2048
- - `fourZeroFourData` - object for populating the 404 page
2049
- - `languageEnabled` - boolean for indicating that site translations are active and to reference the language code in pathname strings
2050
- - `labels` - object used for passing various labels from site application data
2051
- - `setNavCTAOverride` - method for setting the CTA override in the utility nav.
2052
- - `Page` - the Page component from the React Boilerplate
2053
- - `children` - array of custom routes for the page.
2054
-
2055
- ---
2056
-
2057
- #### Stack
2058
-
2059
- ##### Description -
2060
-
2061
- Responsible for iterating over the content array passed down from Page and rendering corresponding organisms. Custom organisms can be added here by creating a new method and adding the new organism's type and method name to the methods array
2062
-
2063
- ##### Props -
2064
-
2065
- - `content` - array of all organism content used for rendering organism components
2066
- - `content` - object with content for the organism, structure varies
2067
- - `type` - string indicating organism type
2068
- - `theme` - object with organism theme data (`color`, `backgroundColor`)
2069
- - `customMethods` - object of custom organisms for the site where the `key` is the organism type and the value is the organism object (`content`, `type`, `theme`)
2070
-
2071
- ---
2072
-
2073
- #### Loading
2074
-
2075
- ##### Description -
2076
-
2077
- Responsible for rendering a loading gif when the site is in a loading state
2078
-
2079
- ##### Props -
2080
-
2081
- - `image` - points to the image source you'd like to use for the. Defaults to the standard dancing dots without it.
2082
-
2083
- ---
2084
-
2085
- ## Hooks
2086
-
2087
- #### useErrorPageData
2088
-
2089
- ##### Description -
2090
-
2091
- Takes the site application data and returns `errorPageData`
2092
-
2093
- ##### Arguments -
2094
-
2095
- - `data` - object containing site appplication data
2096
- - `fourOhFourHeader` - string
2097
- - `fourOhFourText` - string
2098
- - `fourOhFourFiveHundredImage` - string (image src)
2099
- - `homeButtonText` - string
2100
- - `fiveHundredHeader` - string
2101
- - `fiveHundredText` - string
2102
-
2103
- ---
2104
-
2105
- #### useFetch
2106
-
2107
- ##### Description -
2108
-
2109
- Makes a fetch call to the passed url and returns the `response` object, `status` string, and `setResponse` method
2110
-
2111
- ##### Arguments -
2112
-
2113
- - `url` - string
2114
-
2115
- ---
2116
-
2117
- #### useFooterData
2118
-
2119
- ##### Description -
2120
-
2121
- Formats the footer data returned from `useFooterResponse`
2122
-
2123
- ##### Arguments -
2124
-
2125
- - `language` - string
2126
- - `footerResponse` - object
2127
- - `setFooterURL` - method returned from `useFooterURL`
2128
- - `setFooterResponse` - method return from `useFooterResponse`
2129
-
2130
- ---
2131
-
2132
- #### useFooterResponse
2133
-
2134
- ##### Description -
2135
-
2136
- Makes a fetch call for footer data to the passed url and returns the `footerResponse` object and `setFooterResponse` method
2137
-
2138
- ##### Arguments -
2139
-
2140
- - `url` - string
2141
-
2142
- ---
2143
-
2144
- #### useFooterURL
2145
-
2146
- ##### Description -
2147
-
2148
- Returns the footer url string.
2149
-
2150
- ##### Arguments -
2151
-
2152
- - `language` - string
2153
- - `languageEnabled` - boolean
2154
- - `backendURL` - string
2155
-
2156
- ---
2157
-
2158
- #### useInnerPageNav
2159
-
2160
- ##### Description -
2161
-
2162
- Used to how the utility nav is populated. Returns and `innerPageNavData` and `setInnerPageNavData`, which takes an object like `{ pageTitle: "", links: [] }`
2163
-
2164
- ---
2165
-
2166
- #### useLanguage
2167
-
2168
- ##### Description -
2169
-
2170
- Takes the site `languages` array as an argument and returns the browser-preferred language or 'en' and `setLanguage` a method for manually setting to another language.
2171
-
2172
- ##### Arguments -
2173
-
2174
- - `languages` - array of objects -`id` - string that is two letters
2175
-
2176
- ---
2177
-
2178
- #### useLanguages
2179
-
2180
- ##### Description -
2181
-
2182
- Takes the site `backendURL` method as an argument and returns all available site languages.
2183
-
2184
- ##### Arguments -
2185
-
2186
- - `backendURL` - method that returns the string for the site backend url
2187
-
2188
- ---
2189
-
2190
- #### useMetadata
2191
-
2192
- ##### Description -
2193
-
2194
- Returns the site `metadata` object and the `setMetadata` method for updating it.
2195
-
2196
- ---
2197
-
2198
- #### useNavData
2199
-
2200
- ##### Description -
2201
-
2202
- Formats the `navData` object and returns it and the `setNavData` method
2203
-
2204
- ##### Arguments -
2205
-
2206
- - `mainNavResponse` - object
2207
- - `setMainNavResponse` - function
2208
- - `setNavURLs` - function
2209
- - `applicationData` - object
2210
- - `language` - string
2211
-
2212
- ---
2213
-
2214
- #### useNavResponse
2215
-
2216
- ##### Description -
2217
-
2218
- Returns the fetched `mainNavResponse` object and `setMainNavResponse` method
2219
-
2220
- ##### Arguments -
2221
-
2222
- - `urls` - object with `navURL` string
2223
-
2224
- ---
2225
-
2226
- #### useNavURL
2227
-
2228
- ##### Description -
2229
-
2230
- Returns the `navURLs` object and `setNavURLs` function
2231
-
2232
- ##### Arguments -
2233
-
2234
- - `language` - string
2235
- - `languageEnabled` - boolean
2236
- - `backendURL` - function that return backend URL string
2237
-
2238
- ---
2239
-
2240
- #### usePageFetch
2241
-
2242
- ##### Description -
2243
-
2244
- Returns the page `response` object, `setResponse` function, and `error` boolean
2245
-
2246
- ##### Arguments -
2247
-
2248
- - `url` - string
2249
- - `setStatus` - method that takes strings of `loading`, `success`, or `error`
2250
- - `setURL` - function
2251
-
2252
- ---
2253
-
2254
- #### useRegions
2255
-
2256
- ##### Description -
2257
-
2258
- Used to determine user's region based on browser data and to set it dynamically. Returns the active `region`, `regions` options array, `setRegion` and `setRegions` functions, `userLocation` country code string, `setUserLocation` function.
2259
-
2260
- ##### Arguments -
2261
-
2262
- - `backendURL` - function that return backend URL string
2263
-
2264
- ---
2265
-
2266
- #### useRoutes
2267
-
2268
- ##### Description -
2269
-
2270
- Fetches all data for routing, used for setting up custom routes. Returns the `routesData` object
2271
-
2272
- ##### Arguments -
2273
-
2274
- - `backendURL` - function that return backend URL string
2275
-
2276
- ---
2277
-
2278
- #### useScrollTo
2279
-
2280
- ##### Description -
2281
-
2282
- This tracks movement from react-scroll and determines whether or not to add an extra 100px of distance between the scrollY and the element we're scrolling to so that when the navbar expands during upward scrolling it doesn't cover up the top of the container we've sxrolled to. Returns nothing and takes no arguments.
2283
-
2284
- ---
2285
-
2286
- #### useSiteData
2287
-
2288
- ##### Description -
2289
-
2290
- Fetches and stores all site data from Drupal. Returns the `data` object
2291
-
2292
- ##### Arguments -
2293
-
2294
- - `language` - string
2295
- - `backendURL` - function that return backend URL string
2296
-
2297
- ---
2298
-
2299
- ## Methods
2300
-
2301
- #### formatContentSections
2302
-
2303
- ##### Description -
2304
-
2305
- Used to format all page data from a Drupal fetch call. Returns the `formattedSections` array for rendering Luna organisms and `links` array for populating the utility nav
2306
-
2307
- ##### Arguments -
2308
-
2309
- - `content_sections` - `object`
2310
- - `language` - string, defaults to 'en'
2311
- - `languageEnabled`
2312
- - `labels`
2313
- - - `customMethods` - `object` of custom organisms used for the site. The key is the organisms `type` that is referenced in Drupal and the value is the function that formats the data. They take the following arguments: `section` object, `languageCode` string, `languageEnabled` bool, `labels` object, `fpoBox` image src, `formatLinks` function, and `fpoSquare` image src.
2314
-
2315
- ---
1
+ # Luna One React Component Library
2
+
3
+ The Luna One React Component Library represents the organisms used by the Trimble Creative Strategies team in web development. It consists of a series of heros and featurettes. Examples of each with required an optional props can be found below. Additionally, Luna One provides our Luna Boilerplate with a series of important methods and structural components that allow us to manage fetching, data, state, and content formatting as well as provide components for handling things like `Footer`, `NavBar`, `Stack`, and more.
4
+
5
+ Using this library requires that the Terra One React Component Library is also installed, which can be done with `npm i --save terra-one`.
6
+
7
+ ## Branches and Versions
8
+
9
+ #### Master
10
+
11
+ - This branch contains the most up to date Luna components BEFORE updating component's compatibility with Gatsby. This includes the application directory inside src/lib/application that contains boilerplate JSON formatting for React Luna Boilerplate from Drupal api-v2 endpoints. Themes are handled in the updated way, but uses old theme colors. This branch is Luna version 3.2.x. Used by Tekla
12
+
13
+ #### 3.x
14
+
15
+ - This branch is for Luna 3.x versions which have components that are compatible with Gatsby. This contains the most up to date theme colors and styling. When building new components/updates for the future, this is the branch to use. Used by Gatsby Boilerplate.
16
+
17
+ #### 2.x
18
+
19
+ - This branch is for Luna 2.x versions, most up to date Luna version before the addition of the application directory. This contains the previous way of handling themes. Used by Construction and Careers
20
+
21
+ #### 1.x
22
+
23
+ - This branch is for Luna 1.x versions and used on Field Technology and Heavy Industry.
24
+
25
+ ## External Libraries Used:
26
+
27
+ - [React Helmet](https://www.npmjs.com/package/react-helmet) - for meta information in the document `<head>`
28
+ - [React Player](https://www.npmjs.com/package/react-player) - for rendering YouTube and Vimeo videos
29
+ - [React Reveal](https://www.npmjs.com/package/react-reveal) - for handling organism animation when they are scrolled into view
30
+ - [React Scroll](https://www.npmjs.com/package/react-scroll) - for direct scrolling behavior from the navigation bar to specific organisms
31
+ - [Vidyard](https://www.npmjs.com/package/@vidyard/embed-code) - for rendering Vidyard videos
32
+ - [Node Sass v4.12.x](https://www.npmjs.com/package/node-sass) - for compiling SASS into CSS
33
+ - [Axios](https://www.npmjs.com/package/axios) - for handling fetch logic
34
+
35
+ ## Storybook Documentation
36
+
37
+ - Technical documentation for Luna 3.x is in the process of being moved to [Storybook](https://mxp-storybook.netlify.app).
38
+
39
+ ## Components, Hooks, and Methods
40
+
41
+ ### Luna Organisms and Components
42
+
43
+ #### Heroes
44
+
45
+ - [Hero1](#hero1)
46
+ - [Hero2](#hero2)
47
+ - [Hero3](#hero3)
48
+ - [Hero4](#hero4)
49
+ - [Hero5](#hero5)
50
+ - [Hero7](#hero7)
51
+ - [FilterHero](#filterhero)
52
+
53
+ #### Feats
54
+
55
+ - [Feat1](#feat1)
56
+ - [Feat2A](#feat2a)
57
+ - [Feat2B](#feat2b)
58
+ - [Feat3](#feat3)
59
+ - [Feat4](#feat4)
60
+ - [Feat5](#feat5)
61
+ - [Feat7](#feat7)
62
+ - [Feat8](#feat8)
63
+
64
+ #### List Feats
65
+
66
+ - [ListFeat1](#listfeat1)
67
+ - [ListFeat2](#listfeat2)
68
+ - [ListFeat4](#listfeat4)
69
+ - [ListFeat5](#listfeat5)
70
+ - [ListFeat6](#listfeat6)
71
+ - [ListFeat7](#listfeat7)
72
+
73
+ ### Boilerplate Components, Hooks, and Methods
74
+
75
+ #### Components
76
+
77
+ - [FooterHandler](#footerhandler)
78
+ - [HelmetHandler](#helmethandler)
79
+ - [NavBarHandler](#navbarhandler)
80
+ - [Routing](#routing)
81
+ - [Stack](#stack)
82
+ - [Loading](#loading)
83
+
84
+ #### Hooks
85
+
86
+ - [useErrorPageData](#useerrorpagedata)
87
+ - [useFetch](#usefetch)
88
+ - [useFooterData](#usefooterdata)
89
+ - [useFooterResponse](#usefooterresponse)
90
+ - [useFooterURL](#usefooterurl)
91
+ - [useInnerPageNav](#useinnerpagenav)
92
+ - [useLanguage](#uselanguage)
93
+ - [useLanguages](#uselanguages)
94
+ - [useMetadata](#usemetadata)
95
+ - [useNavData](#usenavdata)
96
+ - [useNavResponse](#usenavresponse)
97
+ - [useNavURL](#usenavurl)
98
+ - [usePageFetch](#usepagefetch)
99
+ - [useRegions](#useregions)
100
+ - [useRoutes](#useroutes)
101
+ - [useScrollTo](#usescrollto)
102
+ - [useSiteData](#usesitedata)
103
+
104
+ #### Methods
105
+
106
+ - [formatContentSections](#formatcontentsections)
107
+
108
+ ## Luna Organisms
109
+
110
+ #### Important Theme information
111
+
112
+ - ALL Organisms are able to take a theme. Themes can be customized.
113
+ - Themes will default to `theme-1` if no theme object is passed in as a prop.
114
+
115
+ ##### Standard Themes:
116
+
117
+ - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
118
+
119
+ - theme-1: `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
120
+ - theme-2: `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
121
+ - theme-3: `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
122
+ - theme-4: `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
123
+ - theme-5: `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
124
+
125
+ * To customize themes, add your own hex values to `color`, and `backgroundColor`, and your own classes with custom styling to `ctaOne` and `ctaTwo`.
126
+
127
+ Example of Theme Object:
128
+
129
+ ```
130
+ const theme = {
131
+ color: "blue",
132
+ backgroundColor: "pink",
133
+ ctaOne: "primary--1",
134
+ ctaTwo: "secondary--1"
135
+ }
136
+ ```
137
+
138
+ - Some organisms have additional key value pairs that are necessary, like `Feat7`, these additions are documented below in each organism section.
139
+
140
+ ---
141
+
142
+ #### Hero1 -
143
+
144
+ ###### Props -
145
+
146
+ - `content` **(required)** - object containing `images`, `header`, `text`, `ctas`
147
+
148
+ - images **(required)** - object consisting of `desktop`, `tablet`, and `mobile` image objects
149
+
150
+ - `desktop` - object with `url` and `altText` strings for the desktop image view
151
+ - `url` - string that indicates the source of the image
152
+ - `altText` - string that generates accessibility text for images
153
+ - `tablet` - object with `url` and `altText` strings for the tablet image view
154
+ - `url` - string that indicates the source of the image
155
+ - `altText` - string that generates accessibility text for images
156
+ - `mobile` - object with `url` and `altText` strings for the mobile image view
157
+ - `url` - string that indicates the source of the image
158
+ - `altText` - string that generates accessibility text for images
159
+ - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
160
+ - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
161
+
162
+ - `header` **(required)** - string for generating header text
163
+ - `text` - string for generating body text
164
+ - `ctas` - object used to populate a `<CTASection>`
165
+ - `ctaOne`: object with `text` and `url` strings
166
+ - `ctaTwo`: object with `text` and `url` strings
167
+ - `subCTA`: object with `text` and `url` strings
168
+ - `theme` - object with `backgroundColor` as strings to represent hex value for background color
169
+ - theme-1 `backgroundColor` hex value `#F8F8FB`
170
+ - theme-2 `backgroundColor` hex value `#F1F2F7`
171
+ - theme-3 `backgroundColor` hex value `#E7E9EF`
172
+ - theme-4 `backgroundColor` hex value `#0063A3`
173
+ - theme-5 `backgroundColor` hex value `#004F83`
174
+
175
+ - `contentSide` - string that indicates whether content is on the `right` or `left` side of the component. Defaults to `right`.
176
+ - `id` - string used for generating the component's id attribute. Will default to the organism's header text or the organism type.
177
+ - `motion` - boolean that indicates whether to use the animation to render the component.
178
+ - `focalPointImage` - image object for focal point image. Consists of x & y coords along with image url.
179
+
180
+ ###### Example -
181
+
182
+ ```
183
+ const ctas = {
184
+ ctaOne: {
185
+ text: "Button",
186
+ url: "/#"
187
+ },
188
+ ctaTwo: {
189
+ text: "Button",
190
+ url: "/#"
191
+ },
192
+ subCTA: {
193
+ text: "Button",
194
+ url: "/#"
195
+ }
196
+ };
197
+
198
+ const images = {
199
+ desktop: {
200
+ url: "https://fpoimg.com/1600x1200",
201
+ altText: "placeholder image"
202
+ },
203
+ tablet: {
204
+ url: "https://fpoimg.com/800x600",
205
+ altText: "placeholder image" },
206
+ mobile: {
207
+ url: "https://fpoimg.com/400x400",
208
+ altText: "placeholder image"
209
+ }
210
+ };
211
+ const theme1 = {
212
+ backgroundColor: "#ffffff",
213
+ };
214
+
215
+ const content = {
216
+ images,
217
+ ctas,
218
+ header: 'Design',
219
+ text: 'I am text',
220
+ theme: theme1,
221
+ focalPointImage: {
222
+ x: 6000,
223
+ y: 0,
224
+ title: "union-station",
225
+ height: 4000,
226
+ width: 6000,
227
+ url: "https://images.ctfassets.net/citn2sn5tdjr/4NzwDSDlGECGIiokKomsyI/f78a74130fc60ae9b4fb2e0da2f405db/city.jpg"
228
+ },
229
+ }
230
+
231
+ return (
232
+ <Hero1
233
+ content={content}
234
+ motion
235
+ />
236
+ );
237
+ ```
238
+
239
+ #### Hero2
240
+
241
+ ###### Props -
242
+
243
+ - `content` **(required)** - object containing images, ctas, headers, subheaders, button
244
+
245
+ - `images` **(required)** - object that contains two objects, `desktop` and `mobile`. `desktop` is the 4x1 image object. `mobile` is the 2x1 image object. Each image object consists have `url` and `altText` strings.
246
+ - `desktop` - object consisting of `url` and `altText` strings for generating the desktop-size image
247
+ - `url` - string that points to the image source
248
+ - `altText` - string that generates image accessibility text
249
+ - `mobile` - object consisting of `url` and `altText` strings for generating the mobile-size image
250
+ - `url` - string that points to the image source
251
+ - `altText` - string that generates image accessibility text
252
+ - `header` **(required)** - string used for generating header text
253
+ - `subHeader` **(required)** - string used for generating sub-header text
254
+
255
+ - `theme` - object with `backgroundColor` as strings to represent hex value for background color
256
+ - theme-1 `backgroundColor` hex value `#F8F8FB`
257
+ - theme-2 `backgroundColor` hex value `#F1F2F7`
258
+ - theme-3 `backgroundColor` hex value `#E7E9EF`
259
+ - theme-4 `backgroundColor` hex value `#0063A3`
260
+ - theme-5 `backgroundColor` hex value `#004F83`
261
+
262
+ - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
263
+ - `motion` - object containing `motion`, `motionDistance`, and `motionDirection` keys. -`motion` value is a boolen to indicate if motion will be on this component -`motionDistance` - string indicating the direction that the component should travel from as it fades in -`motionDirection` - string indicating the distance that the component travels during motion. **Motion is currently not enabled in `Hero2`**
264
+ - `focalPointImage` - image object for focal point image. Consists of x & y coords along with image url.
265
+
266
+ ###### Example -
267
+
268
+ ```
269
+ const theme1 = {
270
+ backgroundColor: "#ffffff",
271
+ };
272
+
273
+
274
+ const content = {
275
+ header="Good Design is innovative",
276
+ subHeader="Esse aliquip ad in et ut ipsum paEu elit consectetur aliquip excepteur fugiat ut qui dolor pariatur consectetur.riatur elit quis.",
277
+ images: {
278
+ desktop: {
279
+ url: "http://fpoimg.com/1600x400?text=4:1",
280
+ altText: "placeholder image"
281
+ },
282
+ mobile: {
283
+ url: "http://fpoimg.com/1600x800?text=2:1",
284
+ altText: "placeholder image"
285
+ }
286
+ },
287
+ theme: theme1,
288
+ focalPointImage: {
289
+ x: 6000,
290
+ y: 0,
291
+ title: "union-station",
292
+ height: 4000,
293
+ width: 6000,
294
+ url: "https://images.ctfassets.net/citn2sn5tdjr/4NzwDSDlGECGIiokKomsyI/f78a74130fc60ae9b4fb2e0da2f405db/city.jpg"
295
+ },
296
+ }
297
+
298
+ return (
299
+ <Hero2
300
+ content={content}
301
+ />
302
+ );
303
+ ```
304
+
305
+ #### Hero3
306
+
307
+ ###### Props -
308
+
309
+ - `content` **(required)** - object containing `header`, `text`, `thumbnail`, and `video` data
310
+
311
+ - `header` - string for the header content
312
+ - `text` - string for the body text content
313
+ - `thumbnail` - object for generating the thumbnail with `url` and `altText` strings
314
+ - `url` **(required)** - string that points to the image source
315
+ - `altText` - string for creating accessibility text
316
+ - `video` - object for rendering the video embed
317
+ - `url` - string that points to the video source on YouTube or Vimeo
318
+ - `uuid` - string used for rendering Vidyard video embeds
319
+ - `vidyard` - boolean for indicating that a Vidyard component should be rendered
320
+ - `id` - string used for generating the component's id attribute. Will default to the organism's header text or the organism type.
321
+ - `motion` - boolean that indicates whether to use the react-reveal library to render the component inside a `<Fade>` component.
322
+ - `theme` - object with `backgroundColor` and `color` as strings to represent hex value for background color
323
+ - `theme` - object with `backgroundColor` and `color` as strings to represent hex value for background color
324
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
325
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
326
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
327
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
328
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
329
+ - `contentSide` string of either "left" or "right" which will dictate where the content will render.
330
+
331
+ ###### Example -
332
+
333
+ ```
334
+ const content = {
335
+ header: 'Video Header',
336
+ text: 'This is descriptive text for the video',
337
+ thumbnail: {
338
+ url: 'www.youtube.com/123467890/thumbnail.jpg',
339
+ altText: 'I am a thumbnail'
340
+ },
341
+ video: {
342
+ url: 'www.youtube.com/123467890',
343
+ allowFullScreen: true
344
+ }
345
+ }
346
+
347
+
348
+ return (
349
+ <Hero3
350
+ content={content}
351
+ theme={theme}
352
+ motion
353
+ />
354
+ );
355
+ ```
356
+
357
+ ---
358
+
359
+ #### Hero4/Hero5
360
+
361
+ ###### Note -
362
+
363
+ These two components are functionally the same from a React perspective but exist as separate entities in design. They are populated the same exact way and will always render a `Hero4` in your React tree.
364
+
365
+ ###### Props -
366
+
367
+ - `content` **(required)** - object containing header, subHeader, text, ctas, and image data
368
+ - `header` **(required)** - string for generating header text
369
+ - `subHeader` - string for generating sub-header text
370
+ - `text` - string for generating body text
371
+ - `ctas` - object for generating a `<CTASection>` component. Note that CTA should contain className for theme purposes.
372
+ - previous theme-1, theme-2, and theme-3 has className `primary--1` for ctaOne and `secondary--1` for ctaTwo
373
+ - previous theme-4 and theme-5 has className `primary--5` and `secondary--5`
374
+ - `image` - object for generating <img> element with url and altText strings
375
+ - `theme` - object with `backgroundColor` and `color` as strings to represent hex value for background color
376
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
377
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
378
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
379
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
380
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
381
+ - `id` - string used for generating the component's id attribute. Will default to the organism's header text or the organism type.
382
+ - `motion` - boolean that indicates whether to use the react-reveal library to render the component inside a `<Fade>` component.
383
+ - `contentSide` - optional string of "left" or "right", which defaults to "left" - dictates what side of the screen the content renders.
384
+ - `focalPointImage` - image object for focal point image. Consists of x & y coords along with image url.
385
+
386
+ ###### Example -
387
+
388
+ ```
389
+ const mockCTALinks = {
390
+ ctaOne: {
391
+ text: "Button",
392
+ url: "/#"
393
+ },
394
+ ctaTwo: {
395
+ text: "Button",
396
+ url: "/#"
397
+ },
398
+ subCTA: {
399
+ text: "Button",
400
+ url: "/#"
401
+ }
402
+ };
403
+
404
+ const mockImage = {
405
+ url: "./1-to-1.png",
406
+ altText: "placeholder"
407
+ };
408
+
409
+ const content = {
410
+ ctas: mockCTALinks,
411
+ image: mockImage,
412
+ header: 'Header',
413
+ text: 'I am text',
414
+ focalPointImage: {
415
+ x: 6000,
416
+ y: 0,
417
+ title: "union-station",
418
+ height: 4000,
419
+ width: 6000,
420
+ url: "https://images.ctfassets.net/citn2sn5tdjr/4NzwDSDlGECGIiokKomsyI/f78a74130fc60ae9b4fb2e0da2f405db/city.jpg"
421
+ },
422
+ }
423
+
424
+ <Hero4
425
+ content={content}
426
+ motion
427
+ theme='theme-1'
428
+ />
429
+ ```
430
+
431
+ ---
432
+
433
+ #### Hero7
434
+
435
+ ###### Props -
436
+
437
+ - `content` **(required)** - object containing images, header, text, ctas, and subHeader
438
+
439
+ - `header` **(required)** - string for generating header text
440
+ - `subHeader` - string for generating sub-header text
441
+ - `ctas` - object for generating a `<CTASection>` component
442
+ - `images` **(required)** - object consisting of three image objects, each with url and altText strings. The objects are `desktop`, `tablet`, and `mobile`.
443
+
444
+ - `desktop` - object with `url` and `altText` strings for generating the desktop hero image
445
+ - `url` - string that links to a 3x2 image source
446
+ - `altText` - string for generating image accessibility text
447
+ - `tablet` - object with `url` and `altText` strings for generating the desktop hero image
448
+ - `url` - string that links to a 1x1 image source
449
+ - `altText` - string for generating image accessibility text
450
+ - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
451
+ - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed - `mobile` - object with `url` and `altText` strings for generating the desktop hero image - `url` - string that links to a 4x3 image source - `altText` - string for generating image accessibility text
452
+
453
+ -`theme` - string for hex value of color that will overlay on hero image. This defaults to `#000000`,
454
+ - `focalPointImage` - image object for focal point image. Consists of x & y coords along with image url.
455
+
456
+ ###### Example -
457
+
458
+ ```
459
+ const images = {
460
+ desktop : {
461
+ url: "http://fpoimg.com/2400x1600?text=3:2",
462
+ altText: "placeholder image"
463
+ },
464
+ mobile: {
465
+ url: "http://fpoimg.com/1600x1200?text=4:3",
466
+ altText: "placeholder image"
467
+ },
468
+ tablet: {
469
+ url: "http://fpoimg.com/1600x1600?text=1:1",
470
+ altText: "placeholder image"
471
+ }
472
+ };
473
+
474
+ const ctas = {
475
+ ctaOne: {
476
+ url: "/#",
477
+ text: "Button"
478
+ },
479
+ ctaTwo: {
480
+ url: "/#",
481
+ text: "Button"
482
+ }
483
+ };
484
+
485
+ const content {
486
+ images,
487
+ ctas,
488
+ header: 'Header',
489
+ subHeader: 'Text!',
490
+ focalPointImage: {
491
+ x: 6000,
492
+ y: 0,
493
+ title: "union-station",
494
+ height: 4000,
495
+ width: 6000,
496
+ url: "https://images.ctfassets.net/citn2sn5tdjr/4NzwDSDlGECGIiokKomsyI/f78a74130fc60ae9b4fb2e0da2f405db/city.jpg"
497
+ },
498
+ }
499
+
500
+ return (
501
+ <Hero7
502
+ content={content}
503
+ theme='theme-1'
504
+ />
505
+ );
506
+ ```
507
+
508
+ #### FilterHero
509
+
510
+ ###### Props -
511
+
512
+ - `header` - string for generating header text
513
+ - `text` - string for generating body text.
514
+ - `dropdowns` - array used for generating Dropdown components - see example for structuring
515
+ - `checkboxes` - array used for generating Checkbox components - see example for structuring
516
+ - `handleDropdownChange` - function used for handling new dropdown selections - takes the new selection and the associated name of the dropdown from the event object arguments.
517
+ - `handleCheckboxChange` - function used for handling checkbox toggling - takes a boolean for the status of the checkbox and the name of the checkbox from the event object as arguments.
518
+ - `theme` - string indicating the theme that styles the organism. Options are `theme-1`, `theme-2`, `theme-3`, `theme-4`, `theme-5`.
519
+ - `motion` - boolean that indicates whether to use the react-reveal library to render the component inside a `<Fade>` component.
520
+ - `id` - string used for generating the component's id attribute. Will default to the organism's header text or the organism type.
521
+
522
+ ###### Example -
523
+
524
+ ```
525
+ handleDropdownChange = (selection, name) => {
526
+ this.setState({[name]: selection})
527
+ }
528
+
529
+ handleCheckboxChange = (bool, name) => {
530
+ this.setState({[name]: bool})
531
+ }
532
+
533
+ const header = 'I am a header'
534
+ const text = 'Tempor ex esse ipsum sit eiusmod dolor mollit cupidatat elit cupidatat pariatur commodo non est.'
535
+
536
+ const dropdownOne = {
537
+ options: ["trade one", "trade two", "trade three"],
538
+ defaultText: "All",
539
+ name: "Trade"
540
+ };
541
+ const dropdownTwo = {
542
+ options: ["category one", "category two", "category three"],
543
+ defaultText: "All",
544
+ name: "Category"
545
+ };
546
+ const dropdowns = [dropdownOne, dropdownTwo]
547
+
548
+ const checkboxOne = {
549
+ name: "Checkbox One"
550
+ };
551
+ const checkboxTwo = { name: "Checkbox Two" };
552
+ const checkboxes = [checkboxOne, checkboxTwo];
553
+
554
+ return (
555
+ <FilterHero
556
+ header={header}
557
+ text={text}
558
+ dropdowns={dropdowns}
559
+ checkboxes={checkboxes}
560
+ handleDropdownChange={this.handleDropdownChange}
561
+ handleCheckboxChange={this.handleCheckboxChange}
562
+ backgroundColor='#5e5e5e'
563
+ />
564
+ )
565
+ ```
566
+
567
+ ---
568
+
569
+ #### Feat1
570
+
571
+ ###### Props -
572
+
573
+ - `content` **(required)** - object containing the objects content (see example)
574
+ - `header` **(required)** - string for generating header text
575
+ - `subHeader` - string for generating sub-header text
576
+ - `text` **(required)** - string for generating body text
577
+ - `cta` - object for generating a `<ButtonLink>` component requiring `url` and `text` strings
578
+ - `ctas` - array of objects for generating a `<CTASection>` component requiring `ctaOne` and/or `ctaTwo` objects with `url`, `text`, and `className` strings, takes precedence over the `cta` object
579
+ - ctaClass names are important for themes. If no className is passed as a prop, the className will default to `primary--1` for ctaOne and `secondary--1` for ctaTwo. This is consistent for previous `theme-1`, `theme-2`, and `theme-3`. For `theme-4` and `theme-5`, use `className` of `primary--5` for ctaOne and `secondary--5` for ctaTwo
580
+ - `image` **(required)** - object consisting of `url` and `altText` strings.
581
+ - `Image` - optional Image component from gatsby-image to render images as gatsby-images instad of HTML `<img />`
582
+ - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
583
+ - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
584
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
585
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
586
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
587
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
588
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
589
+ - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
590
+ - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
591
+ - `Link` - optional - either a react-router-dom or gatsby-link component
592
+
593
+ - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
594
+ - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
595
+
596
+ ###### Example -
597
+
598
+ ```
599
+ const content = {
600
+ header: 'Header',
601
+ subHeader: 'Sub Header',
602
+ text: '<p>Sunt elit officia id aute esse dolore elit Lorem officia.</p>'
603
+ cta: {
604
+ url: '/',
605
+ text: 'link'
606
+ },
607
+ image: {
608
+ url: '/',
609
+ altText: 'Image'
610
+ },
611
+ theme: {
612
+ backgroundColor: "blue",
613
+ color: "green"
614
+ }
615
+ }
616
+
617
+ return (
618
+ <Feat1
619
+ content={content}
620
+ motion
621
+ id={data.id}
622
+ />
623
+ );
624
+ ```
625
+
626
+ ---
627
+
628
+ #### Feat2A
629
+
630
+ ###### Props -
631
+
632
+ - `image` **(required)** - object for generating the left-side image
633
+ - `url` - string that points to the source of the image
634
+ - `altText` - string for generating accessibility text
635
+ - `Image` - optional Image component from gatsby-image to render images as gatsby-images instad of HTML `<img />`
636
+   - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
637
+ - `<AccordionFold>` **(required)** - child component for rendering folds in the `<Accordion>` component with each fold taking a `header` string as a prop
638
+ - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
639
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
640
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
641
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
642
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
643
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
644
+ - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
645
+ - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
646
+
647
+ ###### Example -
648
+
649
+ ```
650
+ import { AccordionFold } from 'terra-component-lib'
651
+
652
+ const mockImage = {
653
+ url: "https://fpoimg.com/500x500",
654
+ altText: "Placeholder image"
655
+ };
656
+
657
+ const content = {
658
+ header: "I am a header!",
659
+ subHeader: "This is a sub header. ",
660
+ theme: {
661
+ color: "#363545",
662
+ backgroundColor: "#ffffff",
663
+ };
664
+ }
665
+
666
+ return (
667
+ <Feat2A
668
+ image={mockImage}
669
+ content={content}
670
+ >
671
+ <AccordionFold header="Test one">
672
+ <p>
673
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer
674
+ lobortis augue ligula, eget gravida tellus lacinia id. Sed ultricies
675
+ mi malesuada tincidunt dapibus. Donec porta ligula sagittis elit
676
+ sollicitudin.
677
+ </p>
678
+ </AccordionFold>
679
+ <AccordionFold header="Test two">
680
+ <p>
681
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer
682
+ lobortis augue ligula, eget gravida tellus lacinia id. Sed ultricies
683
+ mi malesuada tincidunt dapibus. Donec porta ligula sagittis elit
684
+ sollicitudin.
685
+ </p>
686
+ </AccordionFold>
687
+ <AccordionFold header="Test three">
688
+ <p>
689
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer
690
+ lobortis augue ligula, eget gravida tellus lacinia id. Sed ultricies
691
+ mi malesuada tincidunt dapibus. Donec porta ligula sagittis elit
692
+ sollicitudin.
693
+ </p>
694
+ </AccordionFold>
695
+ </Feat2>
696
+ );
697
+ ```
698
+
699
+ ---
700
+
701
+ #### Feat2B
702
+
703
+ ###### Props -
704
+
705
+ - `content` **(required)** - object containing images and cards
706
+
707
+ - `images` **(required)** - object for generating images
708
+ - `desktop` **(required)** - object for generating the desktop image
709
+ - `url` - string that points to the image source
710
+ - `altText` - string for generating image accessibility text
711
+ - `mobile` **(required)** - object for generating the mobile image
712
+ - `url` - string that points to the image source
713
+ - `altText` - string for generating image accessibility text
714
+ - `cards` **(required)** - array of objects for generating `IconListItem`
715
+ - `header` - string for generating card header text
716
+ - `text` - string for generating card descriptive text
717
+ - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
718
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
719
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
720
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
721
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
722
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
723
+
724
+ - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
725
+ - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
726
+
727
+ ###### Example -
728
+
729
+ ```
730
+ const content = {
731
+ images: {
732
+ desktop: {
733
+ url: "http://fpoimg.com/1600x400?text=4:1",
734
+ altText: "placeholder image"
735
+ },
736
+ mobile: {
737
+ url: "http://fpoimg.com/1600x800?text=2:1",
738
+ altText: "placeholder image"
739
+ }
740
+ },
741
+ cards: [
742
+ {
743
+ header: "Header",
744
+ text:
745
+ "Anim aliquip aliqua aliqua id qui aute anim reprehenderit tempor velit est sint laborum."
746
+ },
747
+ {
748
+ header: "Header",
749
+ text:
750
+ "Anim aliquip aliqua aliqua id qui aute anim reprehenderit tempor velit est sint laborum."
751
+ },
752
+ {
753
+ header: "Header",
754
+ text:
755
+ "Anim aliquip aliqua aliqua id qui aute anim reprehenderit tempor velit est sint laborum."
756
+ }
757
+ ],
758
+ theme: {
759
+ color: "#363545",
760
+ backgroundColor: "#ffffff",
761
+ }
762
+ }
763
+
764
+ return (
765
+ <Feat2B
766
+ content={content}
767
+ motion
768
+ id={data.id}
769
+ />
770
+ );
771
+ ```
772
+
773
+ ---
774
+
775
+ #### Feat3
776
+
777
+ ###### Description -
778
+
779
+ Featurette with a large image, header, and sub-header text
780
+
781
+ ###### Props -
782
+
783
+ - `content` **(required)** - object containing, images, header, and text
784
+ - `header` - string used for generating the feat header
785
+ - `subHeader` - string used for generating the feat sub-header
786
+ - `images` - object containing mobile and desktop images
787
+ - `mobile` - object containing the mobile image source and alt text
788
+ - `src` - string pointing to the image source
789
+ - `alt` - string used for assisted alternate text for screen readers
790
+ - `desktop` - object containing the desktop image source and alt text
791
+ - `src` - string pointing to the image source
792
+ - `alt` - string used for assisted alternate text for screen readers
793
+ - `motion` - boolean indicating if component animation is active
794
+ - `id` - string used for generating the component's id, defaults to the header text (spaces removed)
795
+ - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
796
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
797
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
798
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
799
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
800
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
801
+
802
+ ###### Example -
803
+
804
+ ```
805
+ const content = {
806
+ header: "Feat 3 Header",
807
+ subHeader: "This is sub-header text",
808
+ images: {
809
+ mobile: {
810
+ src: "www.image.com/mobile-image.jpg",
811
+ alt: "image alt text
812
+ },
813
+ desktop: {
814
+ src: "www.image.com/desktop-image.jpg",
815
+ alt: "image alt text
816
+ }
817
+ },
818
+ theme: {
819
+ backgroundColor: "#f2f2f2",
820
+ color: "#333333"
821
+ },
822
+ motion: true
823
+ }
824
+
825
+ return <Feat3 content={content} />
826
+ ```
827
+
828
+ ---
829
+
830
+ #### Feat4
831
+
832
+ ###### Props -
833
+
834
+ - content **(required)** - object containing, ctas, headers, subheaders
835
+
836
+ - `header` **(required)** - string used for generating header text
837
+ - `subHeader` **(required)** - string used for generating sub-header text
838
+
839
+ - `ctas` - objects for generating a `<CTASection>` component requiring `ctaOne` and/or `ctaTwo` objects with `url`, `text`, and `className` strings, takes precedence over the `cta` object
840
+
841
+ - ctaClass names are important for themes. If no className is passed as a prop, the className will default to `primary--1` for ctaOne and `secondary--1` for ctaTwo. This is consistent for previous `theme-1`, `theme-2`, and `theme-3`. For `theme-4` and `theme-5`, use `className` of `primary--5` for ctaOne and `secondary--5` for ctaTwo
842
+
843
+ - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
844
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
845
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
846
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
847
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
848
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
849
+
850
+ - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
851
+ - `motion` - object containing `motion`, `motionDistance`, and `motionDirection` keys. -`motion` value is a boolen to indicate if motion will be on this component -`motionDistance` - string indicating the direction that the component should travel from as it fades in -`motionDirection` - string indicating the distance that the component travels during motion.
852
+ - `Link` - optional - either a react-router-dom or gatsby-link component
853
+ - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
854
+ - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
855
+
856
+ ###### Example -
857
+
858
+ ```
859
+ const content = {
860
+ header:"Good Design is innovative",
861
+ subHeader:"Esse aliquip ad in et ut ipsum paEu elit consectetur aliquip excepteur fugiat ut qui dolor pariatur consectetur.riatur elit quis.",
862
+ ctas:{
863
+ ctaOne: {
864
+ text: "Button",
865
+ url: "/#"
866
+ },
867
+ ctaTwo: {
868
+ text: "Button",
869
+ url: "/#"
870
+ }
871
+ },
872
+ theme: {
873
+ color: "#363545",
874
+ backgroundColor: "#ffffff",
875
+ },
876
+ }
877
+
878
+ return (
879
+ <Feat4
880
+ content={content}
881
+ />
882
+ );
883
+ ```
884
+
885
+ ---
886
+
887
+ #### Feat5
888
+
889
+ ###### Props -
890
+
891
+ - `content` **(required)** - object for generating organism content
892
+
893
+ - `header` **(required)** - string used for generating header text
894
+ - `subHeader` - string used for generating sub-header text
895
+ - `thumbnail` - object for generating the thumbnail with `url` and `altText` strings - `url` **(required)** - string that points to the image source - `altText` - string for creating accessibility text - `Image` - optional Image component from gatsby-image to render images as gatsby-images instad of HTML `<img />`
896
+   - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
897
+ - `video` - object for rendering the video embed
898
+ - `url` - string that points to the video source on YouTube or Vimeo
899
+ - `uuid` - string used for rendering Vidyard video embeds
900
+ - `vidyard` - boolean for indicating that a Vidyard component should be rendered
901
+ - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
902
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
903
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
904
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
905
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
906
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
907
+
908
+ - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
909
+ - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
910
+ - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
911
+   - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
912
+
913
+ ###### Example -
914
+
915
+ ```
916
+ const content = {
917
+ header: 'Video Header',
918
+ text: 'This is descriptive text for the video',
919
+ thumbnail: {
920
+ url: 'www.youtube.com/123467890/thumbnail.jpg',
921
+ altText: 'I am a thumbnail'
922
+ },
923
+ video: {
924
+ url: 'www.youtube.com/123467890',
925
+ allowFullScreen: true
926
+ },
927
+ theme: {
928
+ color: "#363545",
929
+ backgroundColor: "#ffffff",
930
+ },
931
+ }
932
+
933
+
934
+ return (
935
+ <Feat5
936
+ content={content}
937
+ motion
938
+ />
939
+ );
940
+ ```
941
+
942
+ ---
943
+
944
+ #### Feat7
945
+
946
+ ###### Props -
947
+
948
+ - `content` **(required)** - array of objects used for generating organism content
949
+ - `header` - string used for generating header text
950
+ - `subHeader`- string used for generating sub-header text
951
+ - `theme` - object with `backgroundColor`, `color`, `activeTabBarColor`, `activeTabTextColor`, and `inactiveTabBarColor` as strings to represent hex value for background color
952
+ - `Theme Colors:`
953
+ - Props to pass into component for `theme-1`:
954
+ - `color`: `#98A0AB`
955
+ - `backgroundColor`: `#F8F8FB"`,
956
+ - `activeTabBarColor`: `#0063A3`,
957
+ - `ativeTabTextColor`: `#0063A3`,
958
+ - `inactiveTabBarColor`: `#ffffff`,
959
+ - `introTextColor`: `#242D2F`
960
+ - Props to pass into component fot `theme-2`:
961
+ - `color`: `#98A0AB`
962
+ - `backgroundColor`: `#F1F2F7"`,
963
+ - `activeTabBarColor`: `#0063A3`,
964
+ - `ativeTabTextColor`: `#0063A3`,
965
+ - `inactiveTabBarColor`: `#ffffff`,
966
+ - `introTextColor`: `#242D2F`
967
+ - Props to pass into component fot `theme-3`:
968
+ - `color`: `#98A0AB`
969
+ - `backgroundColor`: `#E7E9EF"`,
970
+ - `activeTabBarColor`: `#0063A3`,
971
+ - `ativeTabTextColor`: `#0063A3`,
972
+ - `inactiveTabBarColor`: `#ffffff`,
973
+ - `introTextColor`: `#242D2F`
974
+ - Props to pass into component fot `theme-4`:
975
+ - `color`: `#B6BCC5`
976
+ - `backgroundColor`: `#0063A3"`,
977
+ - `activeTabBarColor`: `#FFFFFF`,
978
+ - `ativeTabTextColor`: `#FFFFFF`,
979
+ - `inactiveTabBarColor`: `#217cbb`,
980
+ - `introTextColor`: `#FFFFFF`
981
+ - Props to pass into component fot `theme-5`:
982
+ - `color`: `#98A0AB`
983
+ - `backgroundColor`: `#004F83"`,
984
+ - `activeTabBarColor`: `#FFFFFF`,
985
+ - `ativeTabTextColor`: `#FFFFFF`,
986
+ - `inactiveTabBarColor`: `#0063a3`,
987
+ - `introTextColor`: `#FFFFFF`
988
+ - `children` - React components used for generating a Terra Tabs component. The children should consist of `TabsPanel` components. See Terra One documentation for details.
989
+
990
+ - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
991
+ - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
992
+
993
+ ###### Example -
994
+
995
+ ```
996
+ const content = {
997
+ header: 'Tabs Header',
998
+ subHeader: null,
999
+ theme: {
1000
+ color: "#363545",
1001
+ backgroundColor: "#f9f9fb",
1002
+ activeTabBarColor: "#0e6ba8",
1003
+ activeTabTextColor: "#0e6ba8",
1004
+ }
1005
+ }
1006
+
1007
+ return (
1008
+ <Feat7 content={content} motion>
1009
+ <TabsPanel name='Tab One'>
1010
+ <p>Ea eiusmod non nulla incididunt officia do nostrud.</p>
1011
+ <TabsPabel>
1012
+ <TabsPanel name='Tab Two'>
1013
+ <p>Tempor eiusmod nulla et dolore et magna veniam elit proident ullamco.</p>
1014
+ <TabsPabel>
1015
+ <TabsPanel name='Tab Three'>
1016
+ <p>Id nostrud id ut elit excepteur sit incididunt Lorem aliquip.</p>
1017
+ <TabsPabel>
1018
+ </Feat7>
1019
+ )
1020
+ ```
1021
+
1022
+ #### Feat8
1023
+
1024
+ ###### Props -
1025
+
1026
+ - `content` **(required)** - object containing the objects content (see example)
1027
+ - `header` **(required)** - string for generating header text
1028
+ - `subHeader` - string for generating sub-header text
1029
+ - `text` **(required)** - string for generating body text
1030
+ - `theme` - object with `backgroundColor`, and `color` as strings to represent hex value for background color,
1031
+
1032
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`
1033
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`
1034
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`
1035
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`
1036
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`
1037
+
1038
+ - `id` - string used for generating the component's `id` attribute. Will default to the organism's `header` text or the organism type.
1039
+ - `motion` - boolean that indicates whether to use the `react-reveal` library to render the component inside a `<Fade>` component.
1040
+ - `darkTheme` - boolean which indicates whether a dark theme is used - will toggle css class on body copy to use inverse colour as per global styles. Defaults to `false`.
1041
+ - `headerAlignment` - boolean to control alignment of `header`. Default option is `left`, with `center` as alternative option.
1042
+ - `subHeaderAlignment` - boolean to control alignment of `subHeader`. Default option is `left`, with `center` as alternative option.
1043
+
1044
+ #### SlideOut Feat
1045
+
1046
+ ###### Props -
1047
+
1048
+ - `content` **(required)** - object containing header, text, ctas, and image
1049
+ - `header` **(required)** - string for generating header text
1050
+ - `text` **(required)** - string for generating body text either HTML or plain text
1051
+ - `ctas` - objects for generating a `<CTASection>` component requiring `ctaOne` and/or `ctaTwo` objects with `url`, `text`, and `className` strings, takes precedence over the `cta` object
1052
+ - `image` object with `url` as key.
1053
+
1054
+ ###### Example -
1055
+
1056
+ ```
1057
+ const content = {
1058
+ image: {
1059
+ url: image,
1060
+ },
1061
+ header: "I am a header",
1062
+ text:
1063
+ "<p>Voluptate nisi sint nisi ullamco nulla aute ullamco eiusmod. Exercitation cillum anim aliqua nulla occaecat eiusmod.</p>",
1064
+ ctas: {
1065
+ ctaOne: {
1066
+ url: "/",
1067
+ text: "CTA",
1068
+ },
1069
+ ctaTwo: {
1070
+ url: "/",
1071
+ text: "CTA Two",
1072
+ },
1073
+ },
1074
+ };
1075
+
1076
+
1077
+ return (
1078
+ SlideOutFeat content={content} />
1079
+ );
1080
+ ```
1081
+
1082
+ ---
1083
+
1084
+ #### ListFeat1
1085
+
1086
+ ###### Props -
1087
+
1088
+ - `content` **(required)** - object containing all organism content
1089
+
1090
+ - `header` - string for generating organism header text
1091
+ - `subHeader` - string for generating organism sub-header text
1092
+ - `ctas` - object used to populate a `<CTASection>`
1093
+ - `ctaOne`: object with `text`, `url` and `className` strings
1094
+ - `ctaTwo`: object with `text`, `url` and `className` strings
1095
+ - Important to note that `className` corresponds to theme.
1096
+ - previous `theme-1`, `theme-2`, and `theme-3` take `classNames` of `primary--1` and `secondary--1` respectively
1097
+ - previous `theme-4` and `theme-5` take `classNames` of `primary--2` and `secondary--2` respectively.
1098
+ - `subCTA`: object with `text` and `url` strings
1099
+ - `cardOne`, `cardTwo` - objects that contains `header` and `text` keys with values that are strings.
1100
+ - `header` - string for card header text
1101
+ - `text` - string for card body text
1102
+ - `cta` - object for generating a cta on the card
1103
+ - `url` - string to generates the cta's link href
1104
+ - `text` - string for generating the cta's text
1105
+ - `cards` - array of objects with structure matching `cardOne` or `cardTwo`
1106
+ - `type` **(required)** - required to render the correct listFeat. ListFeat1 must be `list_feat_1`
1107
+
1108
+ - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1109
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1110
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1111
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1112
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1113
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1114
+
1115
+ * `motion` - boolean used to indicate whether or not motion should be used
1116
+ * `Link` - optional - either a react-router-dom or gatsby-link component
1117
+
1118
+ ###### Example -
1119
+
1120
+ ```
1121
+
1122
+ theme1 = {
1123
+ color: "#363545",
1124
+ backgroundColor: "#ffffff",
1125
+ };
1126
+
1127
+ const content = {
1128
+ sort: true,
1129
+ header: "Hello everyone! This is a header. Enjoy!",
1130
+ subHeader: "This is truly wonderful.",
1131
+ type: "list_feat_1",
1132
+ image: { src: "https://fpoimg.com/500x500", alt: "placeholder" },
1133
+ cardOne: {
1134
+ header: "I am Card One Header",
1135
+ text:
1136
+ "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex",
1137
+ cta: { url: "/#", text: "Click me!", className: "primary--1" }
1138
+ },
1139
+ cardTwo: {
1140
+ header: "I am Card Two Header",
1141
+ text:
1142
+ "The purpose of lorem ipsum is to create a natural looking block of text (sentence, paragraph, page, etc.) that doesn't distract from the layout. A practice not without controversy, la",
1143
+ cta: { url: "/#", text: "I am a button!", "secondary--1" }
1144
+ },
1145
+ theme: theme1
1146
+ };
1147
+
1148
+ return (
1149
+ <ListFeat content={content} motion />
1150
+ )
1151
+ ```
1152
+
1153
+ #### ListFeat2
1154
+
1155
+ ###### Props -
1156
+
1157
+ - `content` **(required)** - object containing text, headers, subheaders, headShotdumplings, and type
1158
+
1159
+ - `header` - string for generating organism header text
1160
+ - `subHeader` - string for generating organism sub-header text
1161
+ - `headShotdumplings` **(required)** - array of objects for generating headshot dumplings
1162
+ - `header` - string for generating dumpling header text
1163
+ - `subHeader` - string for generating dumpling sub-header text
1164
+ - `text` - string for generating dumpling body text
1165
+ - `color` - string to indicate color of text in headshotDumpling
1166
+ - `image` - object for generating dumpling image
1167
+ - `url` - string for the image's source
1168
+ - `altText` - string for the image's accessibility text
1169
+ - `filter` - string for indicating whether or not to use a colored overlay for the image. Options are "blue" and "grey"
1170
+ - `type` **(required)** - required to render the correct listFeat. ListFeat2 must be `list_feat_2`
1171
+ - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1172
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1173
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1174
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1175
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1176
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1177
+
1178
+ - `motion` - boolean used to indicate whether or not motion should be used
1179
+ - `Link` - optional - either a react-router-dom or gatsby-link component
1180
+
1181
+ ###### Example -
1182
+
1183
+ ```
1184
+ theme1 = {
1185
+ color: "#363545",
1186
+ backgroundColor: "#ffffff",
1187
+ };
1188
+
1189
+
1190
+ const content = {
1191
+ header: "Hello everyone! This is a header. Enjoy!",
1192
+ subheader: "This is truly wonderful.",
1193
+ type: "list_feat_2",
1194
+ headShotdumplings: [
1195
+ {
1196
+ content: {
1197
+ header: "Lorem Ipsum",
1198
+ image: { url: "https://fpoimg.com/150x150", altText: "FPO Image" },
1199
+ color: "pink",
1200
+ },
1201
+ filter: "default"
1202
+ },
1203
+ {
1204
+ content: {
1205
+ header: "Nemo enim ipsam",
1206
+ image: { url: "https://fpoimg.com/150x150", altText: "FPO Image" },
1207
+ color: "pink"
1208
+ },
1209
+ filter: "default"
1210
+ },
1211
+ {
1212
+ content: {
1213
+ header: "Sed ut perspiciatis",
1214
+ image: { url: "https://fpoimg.com/150x150", altText: "FPO Image" },
1215
+ color: "pink"
1216
+ },
1217
+ filter: "default"
1218
+ }
1219
+ ],
1220
+ theme: theme1
1221
+ };
1222
+
1223
+ return (
1224
+ <ListFeat content={content} motion />
1225
+ )
1226
+ ```
1227
+
1228
+ #### ListFeat4
1229
+
1230
+ ###### Props -
1231
+
1232
+ - `content` **(required)** - object containing header, subHeader, type, cards
1233
+ - `header` - key that has a string as a value
1234
+ - `subHeader` - key that has a string as a value
1235
+ - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1236
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1237
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1238
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1239
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1240
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1241
+ - `dumplings` - array containing objects for generating dumplings.
1242
+ - `header` - string for generating dumpling header text
1243
+ - `link` - object for generating dumpling link, is optional
1244
+ - `url` - string for generating the link href/to
1245
+ - `icon` - object for generating the dumpling's icon
1246
+ - `size` - string with a number and 'px' for indicating the icon's size
1247
+ - `type` - string for indicating the type of icon to render. See the Terra One icon options for reference
1248
+ - `color` - string for inddicating the hex color for icon and text. This will default to #000000
1249
+ - `type` **(required)** - required to render the correct listFeat. ListFeat4 must be `list_feat_4`
1250
+ - `motion` - boolean used to indicate whether or not motion should be used
1251
+ - `Link` - optional - either a react-router-dom or gatsby-link component
1252
+
1253
+ ###### Example -
1254
+
1255
+ ```
1256
+ theme1 = {
1257
+ color: "#363545",
1258
+ backgroundColor: "#ffffff",
1259
+ };
1260
+
1261
+ const content = {
1262
+ header: "Hello everyone! This is a header. Enjoy!",
1263
+ subheader: "This is truly wonderful.",
1264
+ type: "list_feat_4",
1265
+ dumplings: [
1266
+ {
1267
+ header: "Lorem Ipsum",
1268
+ link: { url: "/#" },
1269
+ size: "small",
1270
+ icon: { type: "enclosed-check-dark-48px", size: "48px" },
1271
+ color: "blue"
1272
+ },
1273
+ {
1274
+ header: "Nemo enim ipsam voluptatem",
1275
+ link: { url: "/#" },
1276
+ size: "small",
1277
+ icon: { type: "enclosed-check-dark-48px", size: "48px" }
1278
+ color: "blue"
1279
+ },
1280
+ {
1281
+ header: "Sed ut perspiciatis, unde omnis",
1282
+ link: { url: "/#" },
1283
+ size: "small",
1284
+ icon: { type: "enclosed-check-dark-48px", size: "48px" }
1285
+ color: "blue"
1286
+ }
1287
+ ],
1288
+ theme: theme1
1289
+ };
1290
+
1291
+
1292
+
1293
+ return (
1294
+ <ListFeat content={content} motion/>
1295
+ )
1296
+ ```
1297
+
1298
+ #### ListFeat5
1299
+
1300
+ ###### Props -
1301
+
1302
+ - `content` **(required)** - object containing header, subHeader, type, cards
1303
+
1304
+ - `header` - key that has a string as a value
1305
+ - `subHeader` - key that has a string as a value -`insertCardHTML` - key that is a boolean
1306
+ - `iconListItems` - array of objects for generating `IconListItem`
1307
+ - `header` - string for generating card header text
1308
+ - `text` - string for generating card descriptive text
1309
+ - `type` - string for indicating type of icon to render, see Terra One for options, defaults to a checkmark
1310
+ - `color` - string for indicating hex value for color of icon.
1311
+ - `type` **(required)** - required to render the correct listFeat. ListFeat5 must be `list_feat_5`
1312
+ - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1313
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1314
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1315
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1316
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1317
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1318
+
1319
+ - `motion` - boolean used to indicate whether or not motion should be used
1320
+ - `Link` - optional - either a react-router-dom or gatsby-link component
1321
+
1322
+ ###### Example -
1323
+
1324
+ ```
1325
+ theme1 = {
1326
+ color: "#363545",
1327
+ backgroundColor: "#ffffff",
1328
+ };
1329
+
1330
+ const content = {
1331
+ header: "Hello everyone! This is a header. Enjoy!",
1332
+ subheader: "This is truly wonderful.",
1333
+ type: "list_feat_5",
1334
+ insertCardHTML: true,
1335
+ iconListItems: [
1336
+ {
1337
+ header: "Good design is innovative",
1338
+ text:
1339
+ "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>",
1340
+ color: "pink"
1341
+ },
1342
+ {
1343
+ header: "Good design is innovative",
1344
+ text:
1345
+ "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>"
1346
+ color: "pink"
1347
+ },
1348
+ {
1349
+ header: "Good design is innovative",
1350
+ text:
1351
+ "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>"
1352
+ color: "pink"
1353
+ },
1354
+ {
1355
+ header: "Good design is innovative",
1356
+ text:
1357
+ "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>"
1358
+ color: "pink"
1359
+ },
1360
+ {
1361
+ header: "Good design is innovative",
1362
+ text:
1363
+ "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>"
1364
+ },
1365
+ {
1366
+ header: "Good design is innovative",
1367
+ text:
1368
+ "<p>Cupidatat ea in duis ullamco nostrud cupidatat quis aliqua ex labore occaecat sit.</p>"
1369
+ }
1370
+ ],
1371
+ theme: theme1
1372
+ };
1373
+
1374
+
1375
+ return (
1376
+ <ListFeat content={content} motion />
1377
+ )
1378
+ ```
1379
+
1380
+ #### ListFeat6
1381
+
1382
+ ###### Props -
1383
+
1384
+ - `content` **(required)** - object containing header, subHeader, type, cards
1385
+
1386
+ - `header` - key that has a string as a value
1387
+ - `subHeader` - key that has a string as a value
1388
+ - `images` - key that has an object as a value. Object has `src` and `altText` keys which values are strings.
1389
+ - `list` - array containing strings in each indice. The strings of each indice will be rendered onto the component as html tags
1390
+ - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1391
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1392
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1393
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1394
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1395
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1396
+
1397
+ - `motion` - boolean used to indicate whether or not motion should be used
1398
+ - `Link` - optional - either a react-router-dom or gatsby-link component
1399
+
1400
+ ###### Example -
1401
+
1402
+ ```
1403
+ theme1 = {
1404
+ color: "#363545",
1405
+ backgroundColor: "#ffffff",
1406
+ };
1407
+
1408
+ const content = {
1409
+ header: "Hello everyone! This is a header. Enjoy!",
1410
+ subheader: "This is truly wonderful.",
1411
+ images: { src: "https://fpoimg.com/500x500", alt: "placeholder" },
1412
+ type: "list_feat_6",
1413
+ list: [
1414
+ "<h4>Viewer Edition</h4><p>Lorem ipsum dolor sit amet consectetur adipiscing elit</p><p>Donec sit amet arcu nibh. Donec vitae dolor nunc.</p><p>Mauris ut feugiat mauris eu volutpat arcu. Integer mollis neque dui ac auctor dui tincidunt eget.</p>",
1415
+ "<h4>Field Data Edition</h4>p>Lorem ipsum dolor sit amet consectetur adipiscing elit</p><p>Lorem ipsum dolor sit amet consectetur adipiscing elit</p>",
1416
+ "<h4>A list of great ideas:</h4><ul><li>Lorem ipsum dolor sit amet consectetur adipiscing elit</li><li>Donec sit amet arcu nibh Donec vitae dolor nunc.</li><li>Cras vel pharetra augue at sollicitudin velit. Vivamus dapibus quis nisi et vestibulum.</li><li>Mauris ut feugiat mauris eu volutpat arcu. Integer mollis neque dui ac auctor dui tincidunt eget.</li><ul>",
1417
+ "<h4>Here It Is: </h4><ul><li>Lorem ipsum dolor sit amet consectetur adipiscing elit</li><li>Donec sit amet arcu nibh Donec vitae dolor nunc.</li><li>Cras vel pharetra augue at sollicitudin velit. Vivamus dapibus quis nisi et vestibulum.</li><li>Mauris ut feugiat mauris eu volutpat arcu. Integer mollis neque dui ac auctor dui tincidunt eget.</li><li>It's not Latin, though it looks like it, and it actually says nothing,</li><ul>"
1418
+ ],
1419
+ theme: theme1
1420
+ };
1421
+
1422
+
1423
+
1424
+ return (
1425
+ <ListFeat content={content} motion />
1426
+ )
1427
+ ```
1428
+
1429
+ #### ListFeat7
1430
+
1431
+ ###### Props -
1432
+
1433
+ - `content` **(required)** - object containing header, subHeader, type, cards
1434
+ - `header` **(required)** - string for generating header text
1435
+ - `subHeader` - string for generating sub-header text
1436
+ - `type` **(required)** - required to render the correct listFeat. ListFeat7 must be `list_feat_7`
1437
+ - `content` **(required)** - object containing images, ctas, text, variant, headers, subheaders, button, link, videos
1438
+ - `theme` - object with `backgroundColor`, `color`, `ctaOne`, and `ctaTwo` as strings to represent hex value for background color,
1439
+ - theme-1 `backgroundColor` hex value `#F8F8FB`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1440
+ - theme-2 `backgroundColor` hex value `#F1F2F7`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1441
+ - theme-3 `backgroundColor` hex value `#E7E9EF`, `color` hex value `#242D2F`, ctaOne `primary--1`, ctaTwo `secondary--1`
1442
+ - theme-4 `backgroundColor` hex value `#0063A3`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1443
+ - theme-5 `backgroundColor` hex value `#004F83`, `color` hex value `#ffffff`, ctaOne `primary--2`, ctaTwo `secondary--2`
1444
+ - `card` - an array containing the following objects:
1445
+ - `text` - string for generating body text
1446
+ - `ctas` - object for generating a `<CTASection>` component
1447
+ - `images` - object with keys `url` and `altText` with values as strings
1448
+ - `video` - object with keys `url` and `allowFullScreen`. `url` has a value as a string. `allowFullScreen` is a boolean
1449
+ - `uuid` - string used for rendering Vidyard video embeds
1450
+ - `vidyard` - boolean for indicating that a Vidyard component should be rendered
1451
+ - `thumbnail` - object with keys `url` and `altText` with values as strings, used for a thumbnail image in place of a video, while video is not playing
1452
+ - `link` - object with keys `url` and `text` with values as strings.
1453
+ - `Image` - optional Image component from gatsby-image to render images as gatsby-images instad of HTML `<img />`
1454
+ - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
1455
+ - `BackgroundImage` - optional BackgroundImage component from gatsby-background-image to render background images as gatsby-background-images instead of through styling
1456
+ - `fluid` or `fixed` must be accompanied along with Image. Refer to Gatsby docs for further details on fluid and fixed
1457
+ - `motion` - boolean used to indicate whether or not motion should be used
1458
+ - `Link` - optional - either a react-router-dom or gatsby-link component
1459
+
1460
+ ###### Example -
1461
+
1462
+ ```
1463
+ const theme1 = {
1464
+ color: "#363545",
1465
+ backgroundColor: "#ffffff",
1466
+ ctaOne: "primary--1",
1467
+ };
1468
+
1469
+ export const mockContent = {
1470
+ header: "Hello everyone! This is a header. Enjoy!",
1471
+ subheader: "This is truly wonderful.",
1472
+ type: "list_feat_7",
1473
+ cards: [
1474
+ {
1475
+ video: {
1476
+ url: "https://www.youtube.com/embed/UY7r0juBF8Y",
1477
+ allowFullScreen: "true"
1478
+ },
1479
+ thumbnail: {
1480
+ url: "https://fpoimg.com/2880x1920",
1481
+ altText: "fpo"
1482
+ },
1483
+ header: "Here is a title! Woooo",
1484
+ link: {
1485
+ url: "/#",
1486
+ text: "Link"
1487
+ },
1488
+ text:
1489
+ "Ut in amet id proident commodo officia cillum. Aliqua id ex culpa labore duis minim fugiat proident ad deserunt qui."
1490
+ },
1491
+ {
1492
+ video: {
1493
+ url: "https://www.youtube.com/watch?v=sBws8MSXN7A",
1494
+ allowFullScreen: "true"
1495
+ },
1496
+ thumbnail: {
1497
+ url: "https://fpoimg.com/2880x1920",
1498
+ altText: "fpo"
1499
+ },
1500
+ header: "This is a React Tutorial. Enjoy!",
1501
+ link: {
1502
+ url: "/#",
1503
+ text: "Link"
1504
+ },
1505
+ text:
1506
+ "Watch this and you'll be able to make beautiful applications using the wonderful framework of React, built by Facebook"
1507
+ },
1508
+ {
1509
+ image: { url: "https://fpoimg.com/400x225", altText: "FPO Image" },
1510
+ header: "Here is a title! Woooo",
1511
+ link: {
1512
+ url: "/#",
1513
+ text: "Link"
1514
+ },
1515
+ text:
1516
+ "It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout. It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout."
1517
+ },
1518
+ {
1519
+ header: "Here is a title! Woooo",
1520
+ subheader: "sub header! ",
1521
+ text:
1522
+ "It's difficult to find examples of lorem ipsum in use before Letraset made it popular as a dummy text in the 1960s, although McClintock says he remembers coming across the lorem ipsum passage in a book of old metal type samples. So far he hasn't relocated where he once saw the passage, but the popularity of Cicero in the 15th century supports the theory that the filler text has been used for centuries"
1523
+ },
1524
+ {
1525
+ image: { url: "https://fpoimg.com/400x225", altText: "FPO Image" },
1526
+ header: "Here is a title! Woooo",
1527
+ link: {
1528
+ url: "/#",
1529
+ text: "Link"
1530
+ },
1531
+ text:
1532
+ "It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout."
1533
+ }
1534
+ ],
1535
+ theme: theme1
1536
+ };
1537
+
1538
+ return (
1539
+ <ListFeat content={content} motion />
1540
+ )
1541
+ ```
1542
+
1543
+ ## Miscellaneous organisms
1544
+
1545
+ #### AdminCategoryData
1546
+
1547
+ ###### Props -
1548
+
1549
+ - `content` **(required)** - object containing name, industry, translations, url, and languageOptions
1550
+ - `name` - string for generating header
1551
+ - `industry` - string for generating subheader
1552
+ - `translations` - array of objects
1553
+ - `language` - string for language
1554
+ - `teaserImage` - object with key value pair of `url` to represent image path
1555
+ - `name` - string for name of product
1556
+ - `text` - string for text description
1557
+ - `languageOptions` - object with language abbreviations as key and value is language
1558
+
1559
+ ###### Example -
1560
+
1561
+ ```
1562
+ const translations = [
1563
+ {
1564
+ language: "en",
1565
+ teaserImage: { url: "http://fpoimg.com/95x95" },
1566
+ name: "Product name",
1567
+ text: "Dolore velit irure velit duis ea."
1568
+ },
1569
+ {
1570
+ language: "fr",
1571
+ teaserImage: { url: "http://fpoimg.com/95x95" },
1572
+ name: "Product name, but in French",
1573
+ text: "Dolore velit irure velit duis ea."
1574
+ },
1575
+ {
1576
+ language: "de",
1577
+ teaserImage: { url: "http://fpoimg.com/95x95" },
1578
+ name: "Product name, but in German",
1579
+ text: "Dolore velit irure velit duis ea."
1580
+ }
1581
+ ];
1582
+
1583
+ const content = {
1584
+ name: "Category name",
1585
+ industry: "Industry name",
1586
+ translations,
1587
+ url: "/products/industry_name/category_name",
1588
+ languageOptions: {
1589
+ de: "German",
1590
+ fr: "French",
1591
+ en: "English"
1592
+ }
1593
+ };
1594
+
1595
+ return (
1596
+ <AdminCategoryData content={content} currentLanguageURL="en" />
1597
+ )
1598
+
1599
+ ```
1600
+
1601
+ #### AdminProductData
1602
+
1603
+ ###### Props -
1604
+
1605
+ - `content` **(required)** - object containing name, regions, translations, url, and languageOptions
1606
+ - `regions` - array of regions as strings
1607
+ - `translations` - array of objects
1608
+ - `language` - string for language
1609
+ - `teaserImage` - object with key value pair of `url` to represent image path
1610
+ - `name` - string for name of product
1611
+ - `text` - string for text description
1612
+ - `languageOptions` - object with language abbreviations as key and value is language
1613
+
1614
+ ###### Example -
1615
+
1616
+ ```
1617
+ const translations = [
1618
+ {
1619
+ language: "en",
1620
+ teaserImage: {
1621
+ url: "http://fpoimg.com/95x95"
1622
+ },
1623
+ teaserName: "Product name",
1624
+ teaserText: "Dolore velit irure velit duis ea."
1625
+ },
1626
+ {
1627
+ language: "fr",
1628
+ teaserImage: {
1629
+ url: "http://fpoimg.com/95x95"
1630
+ },
1631
+ teaserName: "Product name, but in French",
1632
+ teaserText: "Dolore velit irure velit duis ea."
1633
+ },
1634
+ {
1635
+ language: "de",
1636
+ teaserImage: {
1637
+ url: "http://fpoimg.com/95x95"
1638
+ },
1639
+ teaserName: "Product name, but in German",
1640
+ teaserText: "Dolore velit irure velit duis ea."
1641
+ }
1642
+ ];
1643
+
1644
+ const content = {
1645
+ name: "Product name",
1646
+ regions: ["Illinois", "Colorado", "Ohio"],
1647
+ translations,
1648
+ url: "/products/product-name",
1649
+ languageOptions: {
1650
+ de: "Germand",
1651
+ fr: "French",
1652
+ en: "English"
1653
+ }
1654
+ };
1655
+
1656
+ return (
1657
+ <AdminProductData content={content} currentLanguageURL="en" />
1658
+ )
1659
+
1660
+ ```
1661
+
1662
+ #### MiniFeatDropdown
1663
+
1664
+ ###### Props -
1665
+
1666
+ - `content` - object containing header, text, and dropdowns
1667
+ - `header` - string to represent header
1668
+ - `text` - string to represent text. Can be either HTML or plain text
1669
+ - `dropdowns` - array of single object
1670
+ - `dropdownOne` - object with key options, defaultText, and name
1671
+ - `options` - array of strings to represent dropdown options
1672
+ - `defaultTetx` - string to represent dropdown default option
1673
+ - `name` - string to represent dropdown label
1674
+
1675
+ ###### Example
1676
+
1677
+ ```
1678
+ const header = "How can we help you?";
1679
+ const text =
1680
+ "<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.</p>";
1681
+ const dropdownOne = {
1682
+ options: [
1683
+ "General Contractor",
1684
+ "Software Engineer",
1685
+ "Cyber Security Analyst",
1686
+ "Graphic Designer",
1687
+ ],
1688
+ defaultText: "Choose Your Fighter",
1689
+ name: "I am a ...",
1690
+ };
1691
+
1692
+ const content = {
1693
+ header,
1694
+ text,
1695
+ };
1696
+
1697
+ return (
1698
+ <MiniFeatDropdown
1699
+ content={content}
1700
+ dropdowns={dropdowns}
1701
+ handleDropdownSelect={action("Dropdown Selected")}
1702
+ />
1703
+ )
1704
+
1705
+ ```
1706
+
1707
+ #### BrowserSupportBanner
1708
+
1709
+ ###### Props -
1710
+
1711
+ - `content` - object containing text, type, and browser
1712
+ - `text` - string to represent text
1713
+ - `type` - string to represent banner type. Options include "warning", "danger", and "success"
1714
+ - `browser` - represents type of browser the alert should render on
1715
+
1716
+ ###### Example
1717
+
1718
+ ```
1719
+ const content = {
1720
+ text:
1721
+ "WARNING: Internet Explorer is not recommended for use of this site. Please switch your browser to Chrome, Firefox, or Safari.",
1722
+ type: "danger",
1723
+ browser: "chrome",
1724
+ };
1725
+ return (
1726
+
1727
+ <BrowserSupportBanner content={content} />
1728
+ )
1729
+
1730
+ ```
1731
+
1732
+ #### SketchUp Pricing Card
1733
+
1734
+ ###### Props -
1735
+
1736
+ - `content` - object containing header, boldHeader, text, price, subscript, cta, icons, iconText, listtems, bottomLink, prevPrice, featured, featuredText, featuredColor
1737
+ - `header` - string for generating header text (example: SketchUp)
1738
+ - `boldHeader` - string for generating header type (example: Pro - will read as SketchUp Pro with Pro bolded)
1739
+ - `text` - string to represent text
1740
+ - `price` - string to generate price
1741
+ - `subscript` - string to represent cost frequency ("yr", "month", etc)
1742
+ - `cta` - object with key value pairs `text` and `url`
1743
+ - `text` - string to represent CTA text
1744
+ - `url` - string to represent path of where CTA links
1745
+ - `icons` - array of icon in strings
1746
+ - `listItems` - array of objects with key value pairs `items`, `featured`
1747
+ - `item` - string to generate bullet point items on card
1748
+ - `featured` - boolean: `true` will render "new" on card
1749
+ - `bottomLink` - object with key value pairs `text` and `url`
1750
+ - `text` - string to generate text for bottom link
1751
+ - `url` - string to represent path for link
1752
+ - `prevPrice` - string to represent previous price
1753
+ - `featured` - boolean - `true` will render featuredText
1754
+ - `featuredText` - string to generate featured text if card is featured
1755
+ - `featuredColor` - string to generate color of featuredText background
1756
+
1757
+ ###### Example
1758
+
1759
+ ```
1760
+
1761
+ const header = "SketchUp";
1762
+ const boldHeader = "Pro";
1763
+ const text = "Model Personal Projects";
1764
+ const price = "$199";
1765
+ const subscript = "/yr";
1766
+ const cta = {
1767
+ text: "Subscribe",
1768
+ url: "/",
1769
+ };
1770
+ const icons = ["enclosed-x-dark-16px", "enclosed-arrow-right-dark-32px"];
1771
+ const iconText = "Web Only";
1772
+ const listItems = [
1773
+ { item: "Lorem ipsum dolor site amet.", featured: false },
1774
+ { item: "Lorem ipsum dolor sit, adipisicing.", featured: false },
1775
+ {
1776
+ item: "Lorem ipsum dolor site amet Lorite amet.",
1777
+ featured: true,
1778
+ },
1779
+ ];
1780
+
1781
+ const bottomLink = {
1782
+ text: "Learn more about SHOP",
1783
+ url: "/",
1784
+ };
1785
+ const prevPrice = "$299";
1786
+
1787
+ const featured = true;
1788
+ const featuredText = "Most Popular";
1789
+ const featuredColor = "#0d6aa8";
1790
+
1791
+ const content = {
1792
+ header,
1793
+ boldHeader,
1794
+ text,
1795
+ price,
1796
+ subscript,
1797
+ cta,
1798
+ icons,
1799
+ iconText,
1800
+ listItems,
1801
+ bottomLink,
1802
+ prevPrice,
1803
+ featuredColor,
1804
+ featured,
1805
+ featuredText,
1806
+ };
1807
+
1808
+ return (
1809
+ <SketchUpPricingCard content={content} />
1810
+ )
1811
+
1812
+ ```
1813
+
1814
+ #### StoreFront Card
1815
+
1816
+ ###### Props -
1817
+
1818
+ - `content` - object containing title, header, text, link, image, priceTitle, quantityTitle, price, button, and deliveryEstimation
1819
+ - `title` - string to generate main title of card
1820
+ - `header` - string to generate header of card
1821
+ - `text` - string to represent the description
1822
+ - `link` - object with key value pairs `text` and `url`
1823
+ - `url` - string to represent the path for link
1824
+ - `text` - string to represent text on link
1825
+ - `priceTitle` - string to represent price label
1826
+ - `price` - string to represent price
1827
+ - `button` - object with key value pairs `url` and `text`
1828
+ - `text` - string to represent text of button
1829
+ - `url` - string to generate link path
1830
+ - `deliveryEstimation` - string to represent delivery time
1831
+
1832
+ ###### Example
1833
+
1834
+ ```
1835
+
1836
+ const title = "Trimble XR10";
1837
+ const header = "Desgined for the frontline worker";
1838
+ const text =
1839
+ "Additional information: Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et aliqua";
1840
+ const link = {
1841
+ url: "/",
1842
+ text: "Learn More",
1843
+ };
1844
+ const image = { url: "http://fpoimg.com/95x95", altText: "image" };
1845
+ const priceTitle = "Price";
1846
+ const quantityTitle = "Quantity";
1847
+ const price = "$4750.00";
1848
+ const button = { url: "Added", text: "Added" };
1849
+ const deliveryEstimation = "Delivery: 4-6 weeks";
1850
+
1851
+ const content = {
1852
+ title,
1853
+ header,
1854
+ text,
1855
+ link,
1856
+ image,
1857
+ priceTitle,
1858
+ price,
1859
+ button,
1860
+ quantityTitle,
1861
+ deliveryEstimation,
1862
+ };
1863
+ return (
1864
+ <StoreFrontCard content={content} />
1865
+ )
1866
+
1867
+ ```
1868
+
1869
+ #### SupportCard
1870
+
1871
+ ###### Props -
1872
+
1873
+ - `content` - object containing header, headerLabel, subHeader, product, subHeaderLabel, and sections
1874
+ - `header` - string for generating the header
1875
+ - `headerLabel` - string for generating header label
1876
+ - `subHeader` - string for generating the subheader
1877
+ - `product` - string for generating a product
1878
+ - sections - array of arrays of objects to represent sections
1879
+ - array of objects include key value pairs `value` and `format`
1880
+ - `value` - text or HTML for each section
1881
+ - `format` - optional - string to represent wysiwyg_editor
1882
+
1883
+ ###### Example
1884
+
1885
+ ```
1886
+
1887
+ const sectionOne = [
1888
+ {
1889
+ value:
1890
+ "<h1>Header</h1><p>Non anim voluptate eu cillum sunt voluptate ipsum laboris ipsum do irure.</p><a href='/#'>Link</a>",
1891
+ format: "wysiwyg_editor",
1892
+ },
1893
+ {
1894
+ value:
1895
+ "<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus sollicitudin lectus ligula, nec tempus eros viverra sed. Curabitur malesuada, leo ut porta pretium, turpis turpis dignissim neque, convallis vulputate nisl ante id sapien. Donec efficitur, turpis et blandit ornare, lorem sem aliquet ligula, euismod condimentum dui quam quis purus.</p>\r\n\r\n<p>adadasd</p>\r\n\r\n<ul>\r\n\t<li>asdasd</li>\r\n\t<li>sfdsdfsd</li>\r\n\t<li>sdfsdf</li>\r\n</ul>\r\n",
1896
+ format: "wysiwyg_editor",
1897
+ },
1898
+ {
1899
+ value: "<p>Non anim voluptate eu cillum sunt.</p>",
1900
+ format: "wysiwyg_editor",
1901
+ },
1902
+ {
1903
+ value: '<a href="mailto:jeff@biscuits.com">Email me</a>',
1904
+ },
1905
+ ];
1906
+
1907
+ const sectionTwo = [
1908
+ {
1909
+ value:
1910
+ "<p>Non anim voluptate eu cillum sunt voluptate ipsum laboris ipsum do irure.</p>",
1911
+ format: "w/e",
1912
+ },
1913
+ {
1914
+ value: "<p>Veniam labore sunt tempor nulla commodo ullamco tempor.</p>",
1915
+ format: "w/e",
1916
+ },
1917
+ ];
1918
+
1919
+ const sectionThree = [
1920
+ {
1921
+ value:
1922
+ "Non anim voluptate eu cillum sunt voluptate ipsum laboris ipsum do irure.",
1923
+ format: "w/e",
1924
+ },
1925
+ {
1926
+ value: "Veniam labore sunt tempor nulla commodo ullamco tempor.",
1927
+ format: "w/e",
1928
+ },
1929
+ {
1930
+ value: "Non anim voluptate eu cillum sunt. Okay",
1931
+ format: "w/e",
1932
+ },
1933
+ ];
1934
+
1935
+ const content = {
1936
+ header: "Construction",
1937
+ headerLabel: "Industry",
1938
+ subHeader: "Civil Engineering Software",
1939
+ product: "Novapoint and Quandri",
1940
+ subHeaderLabel: "Categories",
1941
+ sections: [sectionOne, sectionTwo, sectionThree],
1942
+ };
1943
+
1944
+ return (
1945
+ <SupportCard content={content} />
1946
+ )
1947
+
1948
+ ```
1949
+
1950
+ #### Trainer Card
1951
+
1952
+ ###### Props -
1953
+
1954
+ - `content` - object containing header, name, country, region, and link
1955
+ - `header` - string to generate header
1956
+ - `name` - string to generate name
1957
+ - `country` - string to represent country
1958
+ - link - object with key value pairs `url` and `text`
1959
+ - `text` - string to represent button text
1960
+ - `url` - string to represent url path
1961
+
1962
+ ###### Example
1963
+
1964
+ ```
1965
+ const content = {
1966
+ header: "Trainer",
1967
+ name: "Sketchy McSketcherson",
1968
+ country: "United States",
1969
+ region: "North America",
1970
+ link: {
1971
+ url: "/",
1972
+ text: "Get in touch",
1973
+ },
1974
+ };
1975
+
1976
+ return (
1977
+ <TrainerCard content={content} />
1978
+ )
1979
+
1980
+ ```
1981
+
1982
+ ---
1983
+
1984
+ ## Boilerplate Components, Hooks, and Methods
1985
+
1986
+ #### `FooterHandler`
1987
+
1988
+ ##### Description -
1989
+
1990
+ Takes the footer data from `App` and uses it to render `Footer`. Was broken out of Template to keep the component nice and lean.
1991
+
1992
+ ##### Props -
1993
+
1994
+ - `data` **(required)** - object containing all `Footer` data. See [Footer](#footer) for reference
1995
+
1996
+ ---
1997
+
1998
+ #### `HelmetHandler`
1999
+
2000
+ ##### Description -
2001
+
2002
+ Takes the helmet data from `Template` and uses it to render `Helmet`. Was broken out of Template to keep the component nice and lean.
2003
+
2004
+ ##### Props -
2005
+
2006
+ - `data` **(required)** - object containing all `Helmet` data.
2007
+ - `title` - string
2008
+ - `canonical_url` - string
2009
+ - `description` - string
2010
+ - `language` - string for the current active language code
2011
+
2012
+ ---
2013
+
2014
+ #### NavBarHandler
2015
+
2016
+ ##### Description -
2017
+
2018
+ Takes the navigation data from `App` and uses it to render `NavBar`. Was broken out of Template to keep the component nice and lean.
2019
+
2020
+ ##### Props -
2021
+
2022
+ - `data` **(required)** - object containing all `NavBar` data.
2023
+ - `innerPageNavData` - object used for populating the utility nav
2024
+ - `history`**(required)** - the React Router `history` object
2025
+ - `regionData` - object with `region`, `regions`, and method for `setRegion` from `App`
2026
+ - `applicationData` - object with the site data from `App`
2027
+ - `languages` - array of available languages
2028
+ - `language` - string with active language code
2029
+ - `setLanguage` - method for setting the active language
2030
+ - `navCTAOverride` - object used to override the utility nav CTA
2031
+
2032
+ ---
2033
+
2034
+ #### Routing
2035
+
2036
+ ##### Description -
2037
+
2038
+ Takes all the passed information from App and uses it to render the all routes.
2039
+
2040
+ ##### Props -
2041
+
2042
+ - `routes` - array of available route strings
2043
+ - `languages` - array of available languages
2044
+ - `language` - string with active language code
2045
+ - `setMetaData` - method for setting active metadata in React Helmet
2046
+ - `setInnerPageNavData` - method for setting active inner-page navigation
2047
+ - `fiveHundreData` - object for populating the 500 page
2048
+ - `fourZeroFourData` - object for populating the 404 page
2049
+ - `languageEnabled` - boolean for indicating that site translations are active and to reference the language code in pathname strings
2050
+ - `labels` - object used for passing various labels from site application data
2051
+ - `setNavCTAOverride` - method for setting the CTA override in the utility nav.
2052
+ - `Page` - the Page component from the React Boilerplate
2053
+ - `children` - array of custom routes for the page.
2054
+
2055
+ ---
2056
+
2057
+ #### Stack
2058
+
2059
+ ##### Description -
2060
+
2061
+ Responsible for iterating over the content array passed down from Page and rendering corresponding organisms. Custom organisms can be added here by creating a new method and adding the new organism's type and method name to the methods array
2062
+
2063
+ ##### Props -
2064
+
2065
+ - `content` - array of all organism content used for rendering organism components
2066
+ - `content` - object with content for the organism, structure varies
2067
+ - `type` - string indicating organism type
2068
+ - `theme` - object with organism theme data (`color`, `backgroundColor`)
2069
+ - `customMethods` - object of custom organisms for the site where the `key` is the organism type and the value is the organism object (`content`, `type`, `theme`)
2070
+
2071
+ ---
2072
+
2073
+ #### Loading
2074
+
2075
+ ##### Description -
2076
+
2077
+ Responsible for rendering a loading gif when the site is in a loading state
2078
+
2079
+ ##### Props -
2080
+
2081
+ - `image` - points to the image source you'd like to use for the. Defaults to the standard dancing dots without it.
2082
+
2083
+ ---
2084
+
2085
+ ## Hooks
2086
+
2087
+ #### useErrorPageData
2088
+
2089
+ ##### Description -
2090
+
2091
+ Takes the site application data and returns `errorPageData`
2092
+
2093
+ ##### Arguments -
2094
+
2095
+ - `data` - object containing site appplication data
2096
+ - `fourOhFourHeader` - string
2097
+ - `fourOhFourText` - string
2098
+ - `fourOhFourFiveHundredImage` - string (image src)
2099
+ - `homeButtonText` - string
2100
+ - `fiveHundredHeader` - string
2101
+ - `fiveHundredText` - string
2102
+
2103
+ ---
2104
+
2105
+ #### useFetch
2106
+
2107
+ ##### Description -
2108
+
2109
+ Makes a fetch call to the passed url and returns the `response` object, `status` string, and `setResponse` method
2110
+
2111
+ ##### Arguments -
2112
+
2113
+ - `url` - string
2114
+
2115
+ ---
2116
+
2117
+ #### useFooterData
2118
+
2119
+ ##### Description -
2120
+
2121
+ Formats the footer data returned from `useFooterResponse`
2122
+
2123
+ ##### Arguments -
2124
+
2125
+ - `language` - string
2126
+ - `footerResponse` - object
2127
+ - `setFooterURL` - method returned from `useFooterURL`
2128
+ - `setFooterResponse` - method return from `useFooterResponse`
2129
+
2130
+ ---
2131
+
2132
+ #### useFooterResponse
2133
+
2134
+ ##### Description -
2135
+
2136
+ Makes a fetch call for footer data to the passed url and returns the `footerResponse` object and `setFooterResponse` method
2137
+
2138
+ ##### Arguments -
2139
+
2140
+ - `url` - string
2141
+
2142
+ ---
2143
+
2144
+ #### useFooterURL
2145
+
2146
+ ##### Description -
2147
+
2148
+ Returns the footer url string.
2149
+
2150
+ ##### Arguments -
2151
+
2152
+ - `language` - string
2153
+ - `languageEnabled` - boolean
2154
+ - `backendURL` - string
2155
+
2156
+ ---
2157
+
2158
+ #### useInnerPageNav
2159
+
2160
+ ##### Description -
2161
+
2162
+ Used to how the utility nav is populated. Returns and `innerPageNavData` and `setInnerPageNavData`, which takes an object like `{ pageTitle: "", links: [] }`
2163
+
2164
+ ---
2165
+
2166
+ #### useLanguage
2167
+
2168
+ ##### Description -
2169
+
2170
+ Takes the site `languages` array as an argument and returns the browser-preferred language or 'en' and `setLanguage` a method for manually setting to another language.
2171
+
2172
+ ##### Arguments -
2173
+
2174
+ - `languages` - array of objects -`id` - string that is two letters
2175
+
2176
+ ---
2177
+
2178
+ #### useLanguages
2179
+
2180
+ ##### Description -
2181
+
2182
+ Takes the site `backendURL` method as an argument and returns all available site languages.
2183
+
2184
+ ##### Arguments -
2185
+
2186
+ - `backendURL` - method that returns the string for the site backend url
2187
+
2188
+ ---
2189
+
2190
+ #### useMetadata
2191
+
2192
+ ##### Description -
2193
+
2194
+ Returns the site `metadata` object and the `setMetadata` method for updating it.
2195
+
2196
+ ---
2197
+
2198
+ #### useNavData
2199
+
2200
+ ##### Description -
2201
+
2202
+ Formats the `navData` object and returns it and the `setNavData` method
2203
+
2204
+ ##### Arguments -
2205
+
2206
+ - `mainNavResponse` - object
2207
+ - `setMainNavResponse` - function
2208
+ - `setNavURLs` - function
2209
+ - `applicationData` - object
2210
+ - `language` - string
2211
+
2212
+ ---
2213
+
2214
+ #### useNavResponse
2215
+
2216
+ ##### Description -
2217
+
2218
+ Returns the fetched `mainNavResponse` object and `setMainNavResponse` method
2219
+
2220
+ ##### Arguments -
2221
+
2222
+ - `urls` - object with `navURL` string
2223
+
2224
+ ---
2225
+
2226
+ #### useNavURL
2227
+
2228
+ ##### Description -
2229
+
2230
+ Returns the `navURLs` object and `setNavURLs` function
2231
+
2232
+ ##### Arguments -
2233
+
2234
+ - `language` - string
2235
+ - `languageEnabled` - boolean
2236
+ - `backendURL` - function that return backend URL string
2237
+
2238
+ ---
2239
+
2240
+ #### usePageFetch
2241
+
2242
+ ##### Description -
2243
+
2244
+ Returns the page `response` object, `setResponse` function, and `error` boolean
2245
+
2246
+ ##### Arguments -
2247
+
2248
+ - `url` - string
2249
+ - `setStatus` - method that takes strings of `loading`, `success`, or `error`
2250
+ - `setURL` - function
2251
+
2252
+ ---
2253
+
2254
+ #### useRegions
2255
+
2256
+ ##### Description -
2257
+
2258
+ Used to determine user's region based on browser data and to set it dynamically. Returns the active `region`, `regions` options array, `setRegion` and `setRegions` functions, `userLocation` country code string, `setUserLocation` function.
2259
+
2260
+ ##### Arguments -
2261
+
2262
+ - `backendURL` - function that return backend URL string
2263
+
2264
+ ---
2265
+
2266
+ #### useRoutes
2267
+
2268
+ ##### Description -
2269
+
2270
+ Fetches all data for routing, used for setting up custom routes. Returns the `routesData` object
2271
+
2272
+ ##### Arguments -
2273
+
2274
+ - `backendURL` - function that return backend URL string
2275
+
2276
+ ---
2277
+
2278
+ #### useScrollTo
2279
+
2280
+ ##### Description -
2281
+
2282
+ This tracks movement from react-scroll and determines whether or not to add an extra 100px of distance between the scrollY and the element we're scrolling to so that when the navbar expands during upward scrolling it doesn't cover up the top of the container we've sxrolled to. Returns nothing and takes no arguments.
2283
+
2284
+ ---
2285
+
2286
+ #### useSiteData
2287
+
2288
+ ##### Description -
2289
+
2290
+ Fetches and stores all site data from Drupal. Returns the `data` object
2291
+
2292
+ ##### Arguments -
2293
+
2294
+ - `language` - string
2295
+ - `backendURL` - function that return backend URL string
2296
+
2297
+ ---
2298
+
2299
+ ## Methods
2300
+
2301
+ #### formatContentSections
2302
+
2303
+ ##### Description -
2304
+
2305
+ Used to format all page data from a Drupal fetch call. Returns the `formattedSections` array for rendering Luna organisms and `links` array for populating the utility nav
2306
+
2307
+ ##### Arguments -
2308
+
2309
+ - `content_sections` - `object`
2310
+ - `language` - string, defaults to 'en'
2311
+ - `languageEnabled`
2312
+ - `labels`
2313
+ - - `customMethods` - `object` of custom organisms used for the site. The key is the organisms `type` that is referenced in Drupal and the value is the function that formats the data. They take the following arguments: `section` object, `languageCode` string, `languageEnabled` bool, `labels` object, `fpoBox` image src, `formatLinks` function, and `fpoSquare` image src.
2314
+
2315
+ ---