@explorer-1/vue 0.1.4 → 0.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (162) hide show
  1. package/components.d.ts +25 -3
  2. package/dist/explorer-1-vue.js +8978 -10024
  3. package/dist/explorer-1-vue.umd.cjs +13 -16
  4. package/dist/src/components/BaseHeading/BaseHeading.stories.d.ts +6 -11
  5. package/dist/src/components/BaseHeading/BaseHeading.vue.d.ts +6 -10
  6. package/dist/src/components/BasePlaceholder/BasePlaceholder.stories.d.ts +0 -1
  7. package/dist/src/components/BlockDialog/BlockDialog.stories.d.ts +81 -0
  8. package/dist/src/components/BlockImage/BlockImage.stories.d.ts +0 -1
  9. package/dist/src/components/BlockLinkCarousel/BlockLinkCarousel.stories.d.ts +6 -0
  10. package/dist/src/components/BlockLinkCarousel/BlockLinkCarousel.vue.d.ts +6 -0
  11. package/dist/src/components/BlockQuote/BlockQuote.stories.d.ts +0 -1
  12. package/dist/src/components/BlockStreamfield/BlockStreamfield.stories.d.ts +58 -8
  13. package/dist/src/components/BlockVideoEmbed/BlockVideoEmbed.vue.d.ts +7 -3
  14. package/dist/src/components/HeroListingIndex/HeroListingIndex.stories.d.ts +1 -0
  15. package/dist/src/components/HeroMedium/HeroMedium.stories.d.ts +1 -0
  16. package/dist/src/components/HeroMedium/HeroSmall.stories.d.ts +1 -0
  17. package/dist/src/components/HomepageEmbedBlock/HomepageEmbedBlock.stories.d.ts +1 -6
  18. package/dist/src/components/HomepageMissionsCarousel/HomepageMissionsCarousel.stories.d.ts +31 -47
  19. package/dist/src/components/HomepageMissionsCarousel/HomepageMissionsCarousel.vue.d.ts +5 -1
  20. package/dist/src/components/HomepageStats/HomepageStats.stories.d.ts +19 -9
  21. package/dist/src/components/HomepageTeaserBlock/HomepageTeaserBlock.stories.d.ts +6 -50
  22. package/dist/src/components/HomepageTeaserBlock/HomepageTeaserBlock.vue.d.ts +7 -1
  23. package/dist/src/components/MissionDetailAbout/MissionDetailAbout.stories.d.ts +1 -6
  24. package/dist/src/components/MissionDetailHero/MissionDetailHero.stories.d.ts +11 -11
  25. package/dist/src/components/MissionDetailHighlights/MissionDetailHighlights.stories.d.ts +6 -6
  26. package/dist/src/components/NavDesktop/NavDesktop.stories.d.ts +3 -6
  27. package/dist/src/components/NavDesktopEdu/NavDesktopEdu.stories.d.ts +289 -0
  28. package/dist/src/components/NavLogoLinks/NavLogoLinks.stories.d.ts +0 -5
  29. package/dist/src/components/NavMobile/NavMobile.stories.d.ts +42 -9
  30. package/dist/src/components/NavMobile/NavMobile.vue.d.ts +13 -2
  31. package/dist/src/components/NavMobile/NavMobileEdu.stories.d.ts +392 -0
  32. package/dist/src/components/NavSocial/NavSocial.stories.d.ts +42 -1
  33. package/dist/src/components/NavSocial/NavSocial.vue.d.ts +42 -1
  34. package/dist/src/components/TheFooter/TheFooter.vue.d.ts +9 -1
  35. package/dist/src/components/TimelineDialog/TimelineDialog.stories.d.ts +75 -0
  36. package/dist/src/components/TopicDetailMissionSpotlight/TopicDetailMissionSpotlight.stories.d.ts +1 -7
  37. package/dist/src/components/TopicDetailStreamfield/TopicDetailStreamfield.stories.d.ts +1 -6
  38. package/dist/src/docs/foundation/typography.stories.d.ts +6 -10
  39. package/dist/src/store/curatedGallery.d.ts +6 -0
  40. package/dist/src/store/search.d.ts +10 -0
  41. package/dist/src/templates/PageAudioDetail/PageAudioDetail.stories.d.ts +102 -0
  42. package/dist/src/templates/PageContent/PageContent.stories.d.ts +2 -1
  43. package/dist/src/templates/PageContent/PageContent.vue.d.ts +8 -1
  44. package/dist/src/templates/PageEventDetail/PageEventDetail.stories.d.ts +1 -1
  45. package/dist/src/templates/PageImageDetail/PageImageDetail.stories.d.ts +141 -0
  46. package/dist/src/templates/PageNewsDetail/PageNewsDetail.stories.d.ts +1163 -228
  47. package/dist/src/templates/PageVideoDetail/PageVideoDetail.stories.d.ts +56 -0
  48. package/dist/src/templates/edu/PageContentEdu.stories.d.ts +27 -0
  49. package/dist/src/templates/edu/PageEduNewsDetail/PageEduNewsDetail.stories.d.ts +360 -0
  50. package/dist/src/templates/edu/PageEduResourceArticle/PageEduResourceArticle.stories.d.ts +327 -0
  51. package/dist/src/templates/www/PageAsteroidWatchContent/PageAsteroidWatchContent.stories.d.ts +99 -0
  52. package/dist/src/templates/{edu/PageEduNewsDetail.stories.d.ts → www/PageAsteroidWatchIndex/PageAsteroidWatchIndex.stories.d.ts} +48 -67
  53. package/dist/src/templates/www/PageCuratedGallery/PageCuratedGallery.stories.d.ts +98 -0
  54. package/dist/src/templates/www/PageGoDirectory/PageGoDirectory.stories.d.ts +56 -0
  55. package/dist/src/templates/www/PageHomepage/PageHomepage.stories.d.ts +704 -0
  56. package/dist/src/templates/www/PageInfographicDetail/PageInfographicDetail.stories.d.ts +41 -0
  57. package/dist/src/templates/www/PageMaintenanceMode/PageMaintenanceMode.stories.d.ts +14 -0
  58. package/dist/src/templates/www/PageMissionDetail/PageMissionDetail.stories.d.ts +875 -0
  59. package/dist/src/templates/www/PagePodcast/PagePodcast.stories.d.ts +115 -0
  60. package/dist/src/templates/www/PagePodcastSeason/PagePodcastSeason.stories.d.ts +84 -0
  61. package/dist/src/templates/www/PagePressKitIndex/PagePressKitIndex.stories.d.ts +64 -0
  62. package/dist/src/templates/www/PageProfileDetail/PageProfileDetail.stories.d.ts +60 -0
  63. package/dist/src/templates/www/PageRoboticsDetail/PageRoboticsDetail.stories.d.ts +170 -0
  64. package/dist/src/templates/www/PageTimeline/PageTimeline.stories.d.ts +339 -0
  65. package/dist/src/templates/www/PageTopicDetail/PageTopicDetail.stories.d.ts +297 -0
  66. package/dist/style.css +1 -1
  67. package/lib/main.ts +4 -0
  68. package/package.json +2 -1
  69. package/src/components/BaseAudio/BaseAudio.vue +0 -1
  70. package/src/components/BaseHeading/BaseHeading.stories.js +0 -1
  71. package/src/components/BaseHeading/BaseHeading.vue +5 -7
  72. package/src/components/BasePlaceholder/BasePlaceholder.stories.js +0 -1
  73. package/src/components/BlockAudio/BlockAudio.stories.js +2 -3
  74. package/src/components/BlockDialog/BlockDialog.stories.js +56 -0
  75. package/src/components/BlockDialog/BlockDialog.stories.mdx +28 -0
  76. package/src/components/BlockDialog/BlockDialog.vue +132 -0
  77. package/src/components/BlockHeading/BlockHeading.stories.js +2 -2
  78. package/src/components/BlockImage/BlockImage.stories.js +0 -1
  79. package/src/components/BlockImageCarouselItem/BlockImageCarouselItem.vue +0 -1
  80. package/src/components/BlockImageGallery/BlockImageGallery.vue +0 -1
  81. package/src/components/BlockLinkCarousel/BlockLinkCarousel.vue +4 -2
  82. package/src/components/BlockQuote/BlockQuote.stories.js +0 -1
  83. package/src/components/BlockStreamfield/BlockStreamfield.stories.js +20 -9
  84. package/src/components/BlockVideoEmbed/BlockVideoEmbed.vue +3 -2
  85. package/src/components/DetailHeadline/DetailHeadline.vue +3 -2
  86. package/src/components/DsnWidget/DsnWidget.vue +2 -2
  87. package/src/components/HomepageEmbedBlock/HomepageEmbedBlock.stories.js +1 -8
  88. package/src/components/HomepageMissionsCarousel/HomepageMissionsCarousel.stories.js +115 -118
  89. package/src/components/HomepageMissionsCarousel/HomepageMissionsCarousel.vue +3 -23
  90. package/src/components/HomepageMissionsCarousel/HomepageMissionsCarouselItem.vue +1 -2
  91. package/src/components/HomepageStats/HomepageStats.stories.js +10 -10
  92. package/src/components/HomepageStats/HomepageStats.vue +8 -8
  93. package/src/components/HomepageTeaserBlock/HomepageTeaserBlock.stories.js +11 -18
  94. package/src/components/HomepageTeaserBlock/HomepageTeaserBlock.vue +20 -14
  95. package/src/components/HomepageTeaserBlock/HomepageTeaserBlockCardImage.vue +1 -1
  96. package/src/components/MissionDetailAbout/MissionDetailAbout.stories.js +1 -8
  97. package/src/components/MissionDetailHero/MissionDetailHero.stories.js +11 -11
  98. package/src/components/MissionDetailHighlights/MissionDetailHighlights.stories.js +6 -6
  99. package/src/components/MixinCarousel/MixinCarousel.docs.mdx +1 -1
  100. package/src/components/NavDesktop/NavDesktop.stories.js +1 -4
  101. package/src/components/NavDesktopEdu/NavDesktopEdu.stories.js +2 -1
  102. package/src/components/NavMobile/NavMobileEdu.stories.js +2 -1
  103. package/src/components/RoboticsDetailStats/RoboticsDetailStats.stories.js +1 -1
  104. package/src/components/TimelineDialog/TimelineDialog.stories.js +47 -0
  105. package/src/components/TimelineDialog/TimelineDialog.stories.mdx +26 -0
  106. package/src/components/TimelineDialog/TimelineDialog.vue +145 -0
  107. package/src/components/TopicDetailMissionSpotlight/TopicDetailMissionSpotlight.stories.js +1 -9
  108. package/src/components/TopicDetailStreamfield/TopicDetailStreamfield.stories.js +1 -8
  109. package/src/docs/utils/ComponentItem.jsx +0 -1
  110. package/src/store/curatedGallery.ts +23 -0
  111. package/src/store/search.ts +43 -0
  112. package/src/templates/PageAudioDetail/PageAudioDetail.stories.js +106 -0
  113. package/src/templates/PageAudioDetail/PageAudioDetail.vue +375 -0
  114. package/src/templates/PageContent/PageContent.stories.js +2 -1
  115. package/src/templates/PageContent/PageContent.vue +16 -19
  116. package/src/templates/PageEventDetail/PageEventDetail.stories.js +1 -1
  117. package/src/templates/PageEventDetail/PageEventDetail.vue +15 -15
  118. package/src/templates/PageImageDetail/PageImageDetail.stories.js +116 -0
  119. package/src/templates/PageImageDetail/PageImageDetail.vue +444 -0
  120. package/src/templates/PageNewsDetail/PageNewsDetail.stories.js +3 -2
  121. package/src/templates/PageNewsDetail/PageNewsDetail.vue +4 -5
  122. package/src/templates/PageVideoDetail/PageVideoDetail.stories.js +84 -0
  123. package/src/templates/PageVideoDetail/PageVideoDetail.vue +173 -0
  124. package/src/templates/edu/PageContentEdu.stories.js +1 -0
  125. package/src/templates/edu/{PageEduNewsDetail.stories.js → PageEduNewsDetail/PageEduNewsDetail.stories.js} +5 -3
  126. package/src/templates/edu/{PageEduNewsDetail.vue → PageEduNewsDetail/PageEduNewsDetail.vue} +3 -2
  127. package/src/templates/edu/PageEduResourceArticle/PageEduResourceArticle.stories.js +192 -0
  128. package/src/templates/edu/PageEduResourceArticle/PageEduResourceArticle.vue +196 -0
  129. package/src/templates/www/PageAsteroidWatchContent/PageAsteroidWatchContent.stories.js +54 -0
  130. package/src/templates/www/PageAsteroidWatchContent/PageAsteroidWatchContent.vue +79 -0
  131. package/src/templates/www/PageAsteroidWatchIndex/PageAsteroidWatchIndex.stories.js +34 -0
  132. package/src/templates/www/PageAsteroidWatchIndex/PageAsteroidWatchIndex.vue +56 -0
  133. package/src/templates/www/PageCuratedGallery/PageCuratedGallery.stories.js +110 -0
  134. package/src/templates/www/PageCuratedGallery/PageCuratedGallery.vue +345 -0
  135. package/src/templates/www/PageGoDirectory/PageGoDirectory.stories.js +61 -0
  136. package/src/templates/www/PageGoDirectory/PageGoDirectory.vue +76 -0
  137. package/src/templates/www/PageHomepage/PageHomepage.stories.js +101 -0
  138. package/src/templates/www/PageHomepage/PageHomepage.vue +136 -0
  139. package/src/templates/www/PageInfographicDetail/PageInfographicDetail.stories.js +46 -0
  140. package/src/templates/www/PageInfographicDetail/PageInfographicDetail.vue +125 -0
  141. package/src/templates/www/PageMaintenanceMode/PageMaintenanceMode.stories.js +14 -0
  142. package/src/templates/www/PageMaintenanceMode/PageMaintenanceMode.vue +94 -0
  143. package/src/templates/www/PageMissionDetail/PageMissionDetail.stories.js +246 -0
  144. package/src/templates/www/PageMissionDetail/PageMissionDetail.vue +136 -0
  145. package/src/templates/www/PagePodcast/PagePodcast.stories.js +86 -0
  146. package/src/templates/www/PagePodcast/PagePodcast.vue +219 -0
  147. package/src/templates/www/PagePodcastSeason/PagePodcastSeason.stories.js +96 -0
  148. package/src/templates/www/PagePodcastSeason/PagePodcastSeason.vue +191 -0
  149. package/src/templates/www/PagePressKitIndex/PagePressKitIndex.stories.js +72 -0
  150. package/src/templates/www/PagePressKitIndex/PagePressKitIndex.vue +76 -0
  151. package/src/templates/www/PageProfileDetail/PageProfileDetail.stories.js +76 -0
  152. package/src/templates/www/PageProfileDetail/PageProfileDetail.vue +178 -0
  153. package/src/templates/www/PageRoboticsDetail/PageRoboticsDetail.stories.js +43 -0
  154. package/src/templates/www/PageRoboticsDetail/PageRoboticsDetail.vue +101 -0
  155. package/src/templates/www/PageTimeline/BlockMilestone.vue +99 -0
  156. package/src/templates/www/PageTimeline/PageTimeline.stories.js +357 -0
  157. package/src/templates/www/PageTimeline/PageTimeline.vue +384 -0
  158. package/src/templates/www/PageTopicDetail/PageTopicDetail.stories.js +87 -0
  159. package/src/templates/www/PageTopicDetail/PageTopicDetail.vue +121 -0
  160. package/src/utils/mixins.ts +1 -1
  161. package/src/templates/www/HomePage/HomePage.vue +0 -30
  162. /package/dist/src/components/{MixinDropdownToggle/MixinDropdownToggle.vue.d.ts → NavDropdownToggle/NavDropdownToggle.vue.d.ts} +0 -0
@@ -0,0 +1,246 @@
1
+ import { MissionDetailHighlightsData } from './../../../components/MissionDetailHighlights/MissionDetailHighlights.stories.js'
2
+ import { MissionDetailStatsData } from './../../../components/MissionDetailStats/MissionDetailStats.stories.js'
3
+ import { MissionDetailAboutData } from './../../../components/MissionDetailAbout/MissionDetailAbout.stories.js'
4
+ import { MissionDetailStreamfieldData } from './../../../components/MissionDetailStreamfield/MissionDetailStreamfield.stories.js'
5
+ import {
6
+ BlockLinkCardCarouselData,
7
+ BlockLinkTileCarouselData
8
+ } from './../../../components/BlockLinkCarousel/BlockLinkCarousel.stories.js'
9
+ import { BlockRelatedLinksData } from './../../../components/BlockRelatedLinks/BlockRelatedLinks.stories.js'
10
+ import PageMissionDetail from './PageMissionDetail.vue'
11
+
12
+ export default {
13
+ title: 'Templates/WWW/PageMissionDetail',
14
+ component: PageMissionDetail,
15
+ tags: ['!autodocs'],
16
+ decorators: [
17
+ () => ({
18
+ template: `<div id="storyDecorator" class="disable-nav-offset"><story/></div>`
19
+ })
20
+ ],
21
+ parameters: {
22
+ layout: 'fullscreen',
23
+ html: {
24
+ root: '#storyDecorator'
25
+ }
26
+ },
27
+ excludeStories: /.*(Data)$/
28
+ }
29
+
30
+ // stories
31
+ export const BaseStory = {
32
+ name: 'Dark Template',
33
+ args: {
34
+ data: {
35
+ ...MissionDetailStatsData,
36
+ ...MissionDetailHighlightsData,
37
+ ...MissionDetailStreamfieldData,
38
+ ...MissionDetailAboutData,
39
+ relatedLinks: [BlockRelatedLinksData.data],
40
+ relatedPages: BlockLinkCardCarouselData,
41
+ otherMissions: BlockLinkTileCarouselData,
42
+ slug: 'oco-2',
43
+ templateStyle: 'dark',
44
+ title: 'OCO-2',
45
+ subtitle: 'Orbiting Carbon Observatory 2',
46
+ summary:
47
+ 'OCO-2 is an Earth satellite mission designed to study the sources and sinks of carbon dioxide globally and provide scientists with a better idea of how carbon is contributing to climate change. ',
48
+ thumbnailImage: 'https://picsum.photos/400/200',
49
+ missionWebsiteUrl: 'http://oco.jpl.nasa.gov/',
50
+ topicLabels: ['Stars and Galaxies', 'Exoplanets'],
51
+ heroImage: {
52
+ srcSet: 'https://https://picsum.photos/320/200 320w, https://picsum.photos/1920/1200 1440w',
53
+ src: {
54
+ url: 'https://picsum.photos/1920/1200',
55
+ width: 1920,
56
+ height: 1200
57
+ },
58
+ alt: 'OCO-2 hero image'
59
+ },
60
+ instrumentImage: {
61
+ webp: {
62
+ url: '/public/images/mission-oco2.webp'
63
+ },
64
+ src: {
65
+ url: '/public/images/mission-grace-fo-75.webp',
66
+ width: 1597,
67
+ height: 700
68
+ },
69
+ alt: 'The instrument'
70
+ },
71
+ instrumentBackground: {
72
+ image: {
73
+ srcSet: '/public/images/bg-earth-1440x810.jpg' + ' 1440w',
74
+ src: {
75
+ url: '/public/images/bg-earth-1440x810.jpg',
76
+ width: 1440,
77
+ height: 810
78
+ }
79
+ }
80
+ }
81
+ }
82
+ }
83
+ }
84
+
85
+ export const LightTemplateWithHero = {
86
+ args: {
87
+ data: {
88
+ ...MissionDetailStatsData,
89
+ ...MissionDetailHighlightsData,
90
+ ...MissionDetailStreamfieldData,
91
+ ...MissionDetailAboutData,
92
+ relatedLinks: [BlockRelatedLinksData.data],
93
+ relatedPages: BlockLinkCardCarouselData,
94
+ otherMissions: BlockLinkTileCarouselData,
95
+ slug: 'oco-2',
96
+ templateStyle: 'light',
97
+ title: 'OCO-2',
98
+ subtitle: 'Orbiting Carbon Observatory 2',
99
+ summary:
100
+ 'OCO-2 is an Earth satellite mission designed to study the sources and sinks of carbon dioxide globally and provide scientists with a better idea of how carbon is contributing to climate change. ',
101
+ missionWebsiteUrl: 'http://oco.jpl.nasa.gov/',
102
+ heroImage: {
103
+ srcSet: 'https://picsum.photos/320/320 320w, https://picsum.photos/1920/1200 1440w',
104
+ src: {
105
+ url: 'https://picsum.photos/1920/1200',
106
+ width: 1920,
107
+ height: 1200
108
+ },
109
+ alt: 'The hero image'
110
+ },
111
+ instrumentImage: null,
112
+ instrumentBackground: null
113
+ }
114
+ }
115
+ }
116
+
117
+ export const LightTemplateNoBackground = {
118
+ args: {
119
+ data: {
120
+ ...MissionDetailStatsData,
121
+ ...MissionDetailHighlightsData,
122
+ ...MissionDetailStreamfieldData,
123
+ ...MissionDetailAboutData,
124
+ relatedLinks: [BlockRelatedLinksData.data],
125
+ relatedPages: BlockLinkCardCarouselData,
126
+ otherMissions: BlockLinkTileCarouselData,
127
+ slug: 'oco-2',
128
+ templateStyle: 'light',
129
+ title: 'OCO-2',
130
+ subtitle: 'Orbiting Carbon Observatory 2',
131
+ summary:
132
+ 'OCO-2 is an Earth satellite mission designed to study the sources and sinks of carbon dioxide globally and provide scientists with a better idea of how carbon is contributing to climate change. ',
133
+ missionWebsiteUrl: 'http://oco.jpl.nasa.gov/',
134
+ heroImage: {
135
+ srcSet: 'https://picsum.photos/320/320 320w, https://picsum.photos/1920/1200 1440w',
136
+ src: {
137
+ url: 'https://picsum.photos/1920/1200',
138
+ width: 1920,
139
+ height: 1200
140
+ },
141
+ alt: 'The hero image'
142
+ },
143
+ instrumentImage: {
144
+ webp: {
145
+ url: '/public/images/mission-oco2.webp'
146
+ },
147
+ src: {
148
+ url: '/public/images/mission-grace-fo-75.webp',
149
+ width: 1597,
150
+ height: 700
151
+ },
152
+ alt: 'The instrument'
153
+ },
154
+ instrumentBackground: null
155
+ }
156
+ }
157
+ }
158
+
159
+ // stories
160
+ export const GraceFO = {
161
+ args: {
162
+ data: {
163
+ showClock: true,
164
+ showDistance: false,
165
+ clockType: 'time_in_orbit',
166
+ startDateTime: '2018-10-22 10:04:21+01:00',
167
+ distanceType: 'earth',
168
+ distanceValue: 4986444,
169
+ distanceApiUrls: '',
170
+ displayDate: 'Oct. 22, 2018',
171
+ missionTypes: [{ missionType: 'Orbiters' }],
172
+ missionTargets: [{ target: 'Earth' }],
173
+ status: 'current',
174
+ ...MissionDetailHighlightsData,
175
+ highlightsHeading: 'Mission Highlights',
176
+ highlights: [
177
+ {
178
+ date: '2018-11-01',
179
+ heading: 'GRACE-FO Resumes Data Collection',
180
+ summary:
181
+ 'Orci varius natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Nam sagittis orci purus, in luctus ex volutpat sit amet. Orci varius natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Nam sagittis orci purus, in luctus ex volutpat sit amet.'
182
+ }
183
+ ],
184
+ feature: [
185
+ {
186
+ blockType: 'QuoteBlock',
187
+ quote:
188
+ "“A nice thing about it is it doesn't shatter. If impacted, it bends rather than breaks and still has good optical properties”",
189
+ attribution: 'Amy Ross, Spacesuit Designer'
190
+ }
191
+ ],
192
+ relatedLinks: [
193
+ {
194
+ links: [
195
+ {
196
+ text: 'Mission Website',
197
+ document: '',
198
+ page: '',
199
+ externalLink: 'http://gracefo.jpl.nasa.gov/'
200
+ }
201
+ ]
202
+ }
203
+ ],
204
+ relatedPages: BlockLinkCardCarouselData,
205
+ otherMissions: BlockLinkTileCarouselData,
206
+ slug: 'grace-fo',
207
+ templateStyle: 'dark',
208
+ title: 'GRACE-FO',
209
+ subtitle: 'Gravity Recovery and Climate Experiment Follow-On',
210
+ summary:
211
+ 'The Gravity Recovery and Climate Experiment Follow-on (GRACE-FO) mission is a partnership between NASA and the German Research Centre for Geosciences (GFZ).',
212
+ thumbnailImage: 'https://picsum.photos/400/200',
213
+ missionWebsiteUrl: 'http://gracefo.jpl.nasa.gov/',
214
+ heroImage: {
215
+ srcSet: 'https://picsum.photos/320/320 320w, https://picsum.photos/1920/1200 1440w',
216
+ src: {
217
+ url: 'https://picsum.photos/1920/1200',
218
+ width: 1920,
219
+ height: 1200
220
+ },
221
+ alt: 'GRACE-FO hero image'
222
+ },
223
+ instrumentImage: {
224
+ webp: {
225
+ url: '/public/images/mission-grace-fo-75.webp'
226
+ },
227
+ src: {
228
+ url: '/public/images/mission-grace-fo.png',
229
+ width: 1597,
230
+ height: 700
231
+ },
232
+ alt: 'The instrument'
233
+ },
234
+ instrumentBackground: {
235
+ image: {
236
+ srcSet: '/public/images/bg-earth-1440x810.jpg' + ' 1440w',
237
+ src: {
238
+ url: '/public/images/bg-earth-1440x810.jpg',
239
+ width: 1440,
240
+ height: 810
241
+ }
242
+ }
243
+ }
244
+ }
245
+ }
246
+ }
@@ -0,0 +1,136 @@
1
+ <template>
2
+ <div
3
+ v-if="data"
4
+ class="-nav-offset"
5
+ >
6
+ <div :class="theTheme">
7
+ <MissionDetailHero
8
+ :title="data.title"
9
+ :subtitle="data.subtitle"
10
+ :summary="data.summary"
11
+ :template-style="data.templateStyle"
12
+ :mission-website-url="data.missionWebsiteUrl"
13
+ :instrument-image="data.instrumentImage"
14
+ :instrument-background="data.instrumentBackground"
15
+ :hero-fallback="data.heroImage"
16
+ />
17
+ <MissionDetailStats
18
+ :show-clock="data.showClock"
19
+ :show-distance="data.showDistance"
20
+ :clock-type="data.clockType"
21
+ :start-date-time="data.startDateTime"
22
+ :distance-type="data.distanceType"
23
+ :distance-value="data.distanceValue"
24
+ :distance-api-urls="data.distanceApiUrls"
25
+ :display-date="data.displayDate"
26
+ :mission-types="data.missionTypes"
27
+ :mission-targets="data.missionTargets"
28
+ :status="data.status"
29
+ />
30
+ <MissionDetailAbout
31
+ class="py-10"
32
+ :description-heading="data.descriptionHeading"
33
+ :description="data.description"
34
+ :instruments="data.instruments"
35
+ />
36
+ <!-- 3D model -->
37
+ <MissionDetailHighlights
38
+ v-if="data.highlights && data.highlights.length"
39
+ :animation="data.showHighlightsAnimation"
40
+ :graphic="data.highlightsGraphic"
41
+ :heading="data.highlightsHeading"
42
+ :mission-title="data.title"
43
+ :highlights="data.highlights"
44
+ />
45
+ <!-- Mission Streamfield (text and image, blockquote) -->
46
+ <MissionDetailStreamfield
47
+ v-if="data.feature && data.feature.length"
48
+ class="pt-10"
49
+ :class="{ 'pb-10': data.templateStyle === 'dark' }"
50
+ :data="data.feature"
51
+ />
52
+ </div>
53
+ <!-- Related Pages, data returned only if a topic is assigned -->
54
+ <BlockLinkCarousel
55
+ item-type="cards"
56
+ class="lg:mt-24 mt-18 lg:mb-18 mb-10"
57
+ :heading="moreAboutTopicHeading"
58
+ :items="data.relatedPages"
59
+ />
60
+ <!-- Related Links -->
61
+ <LayoutHelper
62
+ v-if="data.relatedLinks && data.relatedLinks.length"
63
+ indent="col-2"
64
+ class="lg:mb-18 mb-10"
65
+ >
66
+ <BlockRelatedLinks :data="data.relatedLinks[0]" />
67
+ </LayoutHelper>
68
+ <!-- Other Missions -->
69
+ <div
70
+ v-if="data.otherMissions && data.otherMissions.length"
71
+ class="bg-gray-light lg:py-24 lg:mt-24 py-12 mt-12"
72
+ >
73
+ <BlockLinkCarousel
74
+ item-type="tiles"
75
+ heading="Explore Other Missions"
76
+ :items="data.otherMissions"
77
+ />
78
+ </div>
79
+ </div>
80
+ </template>
81
+ <script lang="ts">
82
+ import { defineComponent } from 'vue'
83
+ import MissionDetailHighlights from './../../../components/MissionDetailHighlights/MissionDetailHighlights.vue'
84
+ import MissionDetailHero from './../../../components/MissionDetailHero/MissionDetailHero.vue'
85
+ import MissionDetailAbout from './../../../components/MissionDetailAbout/MissionDetailAbout.vue'
86
+ import MissionDetailStats from './../../../components/MissionDetailStats/MissionDetailStats.vue'
87
+ import MissionDetailStreamfield from './../../../components/MissionDetailStreamfield/MissionDetailStreamfield.vue'
88
+ import BlockRelatedLinks from './../../../components/BlockRelatedLinks/BlockRelatedLinks.vue'
89
+ import BlockLinkCarousel from './../../../components/BlockLinkCarousel/BlockLinkCarousel.vue'
90
+ import LayoutHelper from './../../../components/LayoutHelper/LayoutHelper.vue'
91
+
92
+ interface dataShape {
93
+ templateStyle: string
94
+ }
95
+ export default defineComponent({
96
+ name: 'PageMissionDetail',
97
+ components: {
98
+ MissionDetailHighlights,
99
+ MissionDetailHero,
100
+ MissionDetailAbout,
101
+ MissionDetailStats,
102
+ MissionDetailStreamfield,
103
+ BlockRelatedLinks,
104
+ BlockLinkCarousel,
105
+ LayoutHelper
106
+ },
107
+ props: {
108
+ data: {
109
+ type: Object,
110
+ required: false,
111
+ default: undefined
112
+ }
113
+ },
114
+ computed: {
115
+ theTheme() {
116
+ if ((this.data as dataShape).templateStyle === 'dark') {
117
+ return 'ThemeVariantDark bg-black'
118
+ }
119
+ return 'ThemeVariantLight'
120
+ },
121
+ moreAboutTopicHeading() {
122
+ // @ts-ignore
123
+ const { topicLabels } = this.data
124
+ if (!topicLabels || topicLabels.length === 0) {
125
+ return 'More'
126
+ }
127
+ if (topicLabels.length === 1) {
128
+ return `More about ${topicLabels[0]}`
129
+ }
130
+ const last = topicLabels[topicLabels.length - 1]
131
+ const firsts = topicLabels.slice(0, topicLabels.length - 1).join(', ')
132
+ return `More about ${firsts} and ${last}`
133
+ }
134
+ }
135
+ })
136
+ </script>
@@ -0,0 +1,86 @@
1
+ import { BlockRelatedLinksData } from './../../../components/BlockRelatedLinks/BlockRelatedLinks.stories.js'
2
+ import { HeroMediaData } from './../../../components/HeroMedia/HeroMedia.stories'
3
+ import { BlockLinkTileCarouselData } from './../../../components/BlockLinkCarousel/BlockLinkCarousel.stories.js'
4
+ import PagePodcast from './PagePodcast.vue'
5
+
6
+ export default {
7
+ title: 'Templates/WWW/PagePodcast',
8
+ component: PagePodcast,
9
+ tags: ['!autodocs'],
10
+ decorators: [
11
+ () => ({
12
+ template: `<div id="storyDecorator" class="disable-nav-offset"><story/></div>`
13
+ })
14
+ ],
15
+ parameters: {
16
+ layout: 'fullscreen',
17
+ html: {
18
+ root: '#storyDecorator'
19
+ }
20
+ },
21
+ excludeStories: /.*(Data)$/
22
+ }
23
+
24
+ // data
25
+ export const PagePodcastData = {
26
+ title: 'On a Mission',
27
+ topicLabel: 'Mars',
28
+ label: 'Podcast',
29
+ summary:
30
+ 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Maecenas in nibh mauris. Praesent vel tempus enim, a ultricies justo. Cras nec lorem quis lorem ullamcorper accumsan. Aliquam lacus tortor, vulputate sit amet purus vitae, accumsan maximus diam. Vivamus ac dui non sapien hendrerit elementum. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis porttitor ac quam sed eleifend.',
31
+ heroImage: HeroMediaData.image,
32
+ seasons: [
33
+ {
34
+ id: 1,
35
+ seasonNumber: 1,
36
+ label: 'On a Mission | Season 1',
37
+ subtitle: 'Descriptive Title of Season 1',
38
+ summary:
39
+ 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis porttitor ac quam sed eleifend.',
40
+ parent: {
41
+ title: 'On a Mission'
42
+ },
43
+ thumbnailImage: {
44
+ src: {
45
+ url: 'https://picsum.photos/560/560',
46
+ width: '560',
47
+ height: '560'
48
+ }
49
+ },
50
+ title: 'Season 1',
51
+ url: '/podcasts/season1/',
52
+ firstPublishedAt: '2020-10-01'
53
+ },
54
+ {
55
+ id: 2,
56
+ seasonNumber: 2,
57
+ label: 'On a Mission | Season 2',
58
+ subtitle: 'Descriptive Title of Season 2',
59
+ summary:
60
+ 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis porttitor ac quam sed eleifend.',
61
+ parent: {
62
+ title: 'On a Mission'
63
+ },
64
+ thumbnailImage: {
65
+ src: {
66
+ url: 'https://picsum.photos/560/560',
67
+ width: '560',
68
+ height: '560'
69
+ }
70
+ },
71
+ title: 'Season 2',
72
+ url: '/podcasts/season2/',
73
+ firstPublishedAt: '2020-12-01'
74
+ }
75
+ ],
76
+ relatedLinks: [BlockRelatedLinksData.data],
77
+ relatedPodcasts: BlockLinkTileCarouselData
78
+ }
79
+
80
+ // stories
81
+ export const BaseStory = {
82
+ name: 'PagePodcast',
83
+ args: {
84
+ data: PagePodcastData
85
+ }
86
+ }
@@ -0,0 +1,219 @@
1
+ <template>
2
+ <div
3
+ v-if="data"
4
+ class="ThemeVariantLight"
5
+ :class="{ '-nav-offset': data.heroImage }"
6
+ >
7
+ <!-- hero image -->
8
+ <HeroMedia
9
+ v-if="data.heroImage"
10
+ class="md:mb-12 lg:mb-18 mb-10"
11
+ :image="data.heroImage"
12
+ :caption="data.heroImageCaption"
13
+ :display-caption="!data.heroImageCaption ? false : true"
14
+ />
15
+
16
+ <!-- page headline -->
17
+ <LayoutHelper
18
+ indent="col-1"
19
+ class="3xl:px-0 lg:mt-12 px-5 mx-auto mt-5 mb-5 lg:mb-10"
20
+ >
21
+ <DetailHeadline
22
+ :title="data.title"
23
+ :publication-date="data.publicationDate"
24
+ label="Podcast Series"
25
+ schema
26
+ />
27
+ <BlockText
28
+ v-if="data.summary"
29
+ :text="data.summary"
30
+ variant="medium"
31
+ class="lg:w-2/3 mt-5"
32
+ />
33
+ </LayoutHelper>
34
+
35
+ <LayoutHelper>
36
+ <div class="col-span-12 pb-2 justify-end flex flex-row pr-0.5">
37
+ <!-- toggle gallery view -->
38
+ <div
39
+ v-if="allowGridView"
40
+ class="align-end flex text-2xl font-secondary font-semibold tracking-wider"
41
+ >
42
+ <button
43
+ class="lg:ml-6"
44
+ :class="
45
+ showGridView
46
+ ? 'text-theme-red cursor-default'
47
+ : 'text-gray-mid can-hover:hover:text-theme-red-hover cursor-pointer'
48
+ "
49
+ :aria-label="showGridView ? 'Grid View (enabled)' : 'Grid View'"
50
+ :disabled="showGridView"
51
+ @click="
52
+ isGallery
53
+ ? searchStore.updateGridViewForPodcasts(true)
54
+ : searchStore.updateGridView(true)
55
+ "
56
+ >
57
+ <span class="flex items-center">
58
+ <IconGrid />
59
+ </span>
60
+ </button>
61
+ <button
62
+ class="ml-3"
63
+ :class="
64
+ !showGridView
65
+ ? 'text-theme-red cursor-default'
66
+ : 'text-gray-mid can-hover:hover:text-theme-red-hover cursor-pointer'
67
+ "
68
+ :aria-label="!showGridView ? 'List View (enabled)' : 'List View'"
69
+ :disabled="!showGridView"
70
+ @click="
71
+ isGallery
72
+ ? searchStore.updateGridViewForPodcasts(false)
73
+ : searchStore.updateGridView(false)
74
+ "
75
+ >
76
+ <span class="flex items-center">
77
+ <IconList />
78
+ </span>
79
+ </button>
80
+ </div>
81
+ </div>
82
+ </LayoutHelper>
83
+
84
+ <LayoutHelper
85
+ v-if="sortedSeasons && sortedSeasons.length"
86
+ indent="col-2"
87
+ class="border-gray-mid lg:mb-24 pt-10 mb-12 border-t"
88
+ >
89
+ <section aria-label="Podcast Seasons">
90
+ <template v-if="!showGridView">
91
+ <SearchResultCard
92
+ v-for="season of sortedSeasons"
93
+ :key="season.id"
94
+ :type="season.parent.title"
95
+ :topic="season.title"
96
+ :url="season.url"
97
+ :image="season.thumbnailImage"
98
+ :title="season.subtitle"
99
+ :summary="season.summary"
100
+ :date="
101
+ // @ts-ignore
102
+ $filters.displayDate(season.firstPublishedAt)
103
+ "
104
+ heading-level="h2"
105
+ />
106
+ </template>
107
+ <template v-else>
108
+ <div class="md:grid grid-cols-12 gap-10">
109
+ <div
110
+ v-for="season of sortedSeasons"
111
+ :key="season.id"
112
+ class="col-span-6 lg:col-span-4"
113
+ >
114
+ <SearchResultGridItem
115
+ :type="season.parent.title"
116
+ :topic="season.title"
117
+ :url="season.url"
118
+ :image="season.thumbnailImage"
119
+ :title="season.title"
120
+ :summary="season.summary"
121
+ :date="
122
+ // @ts-ignore
123
+ $filters.displayDate(season.firstPublishedAt)
124
+ "
125
+ heading-level="h2"
126
+ />
127
+ </div>
128
+ </div>
129
+ </template>
130
+ </section>
131
+ </LayoutHelper>
132
+
133
+ <!-- related links -->
134
+ <LayoutHelper
135
+ v-if="data.relatedLinks && data.relatedLinks.length"
136
+ indent="col-2"
137
+ class="lg:mb-18 mb-10 -mt-5"
138
+ >
139
+ <BlockRelatedLinks :data="data.relatedLinks[0]" />
140
+ </LayoutHelper>
141
+
142
+ <div
143
+ v-if="data.relatedPodcasts && data.relatedPodcasts.length"
144
+ class="bg-gray-light lg:py-24 lg:mt-24 py-12 mt-12"
145
+ >
146
+ <BlockLinkCarousel
147
+ item-type="tiles"
148
+ heading="Explore Other Podcasts"
149
+ :items="data.relatedPodcasts"
150
+ />
151
+ </div>
152
+ </div>
153
+ </template>
154
+ <script>
155
+ import { defineComponent } from 'vue'
156
+ import { mapStores } from 'pinia'
157
+ import { useSearchStore } from './../../../store/search.ts'
158
+ import HeroMedia from './../../../components/HeroMedia/HeroMedia.vue'
159
+ import IconGrid from './../../../components/Icons/IconGrid.vue'
160
+ import IconList from './../../../components/Icons/IconList.vue'
161
+ import DetailHeadline from './../../../components/DetailHeadline/DetailHeadline.vue'
162
+ import SearchResultCard from './../../../components/SearchResultCard/SearchResultCard.vue'
163
+ import SearchResultGridItem from './../../../components/SearchResultGridItem/SearchResultGridItem.vue'
164
+ import LayoutHelper from './../../../components/LayoutHelper/LayoutHelper.vue'
165
+ import BlockRelatedLinks from './../../../components/BlockRelatedLinks/BlockRelatedLinks.vue'
166
+ import BlockText from './../../../components/BlockText/BlockText.vue'
167
+ import BlockLinkCarousel from './../../../components/BlockLinkCarousel/BlockLinkCarousel.vue'
168
+
169
+ export default defineComponent({
170
+ name: 'PagePodcast',
171
+ components: {
172
+ HeroMedia,
173
+ DetailHeadline,
174
+ SearchResultCard,
175
+ SearchResultGridItem,
176
+ LayoutHelper,
177
+ BlockRelatedLinks,
178
+ BlockText,
179
+ BlockLinkCarousel,
180
+ IconGrid,
181
+ IconList
182
+ },
183
+ props: {
184
+ data: {
185
+ type: Object,
186
+ required: false
187
+ }
188
+ },
189
+
190
+ data() {
191
+ return {
192
+ allowGridView: true,
193
+ defaultShowGridView: false,
194
+ isGallery: true
195
+ }
196
+ },
197
+ computed: {
198
+ ...mapStores(useSearchStore),
199
+ showGridView() {
200
+ if (this.isGallery) {
201
+ if (this.searchStore.showGridViewForPodcasts !== undefined) {
202
+ return this.searchStore.showGridViewForPodcasts
203
+ }
204
+ } else if (this.searchStore.showGridView !== undefined) {
205
+ return this.searchStore.showGridView
206
+ }
207
+ return this.defaultShowGridView
208
+ },
209
+ sortedSeasons() {
210
+ let seasons = null
211
+ if (this.data && this.data.seasons) {
212
+ seasons = this.data.seasons
213
+ return seasons.sort((a, b) => a.seasonNumber - b.seasonNumber)
214
+ }
215
+ return seasons
216
+ }
217
+ }
218
+ })
219
+ </script>