@explorer-1/vue 0.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +9 -0
- package/components.d.ts +215 -0
- package/index.html +18 -0
- package/lib/main.ts +78 -0
- package/package.json +54 -0
- package/postcss.config.js +7 -0
- package/public/edu/.gitkeep +0 -0
- package/public/edu/explorer-1/bg-stars-edu.png +0 -0
- package/public/edu/explorer-1/bg-stars.jpg +0 -0
- package/public/explorer-1/bg-stars-edu.png +0 -0
- package/public/explorer-1/bg-stars.jpg +0 -0
- package/src/App.vue +30 -0
- package/src/assets/fonts/README.md +12 -0
- package/src/assets/fonts/archivo-narrow/ArchivoNarrow-Bold.woff2 +0 -0
- package/src/assets/fonts/archivo-narrow/ArchivoNarrow-BoldItalic.woff2 +0 -0
- package/src/assets/fonts/archivo-narrow/ArchivoNarrow-SemiBold.woff2 +0 -0
- package/src/assets/fonts/archivo-narrow/ArchivoNarrow-SemiBoldItalic.woff2 +0 -0
- package/src/assets/fonts/metropolis/Metropolis-Bold.woff2 +0 -0
- package/src/assets/fonts/metropolis/Metropolis-BoldItalic.woff2 +0 -0
- package/src/assets/fonts/metropolis/Metropolis-ExtraBold.woff2 +0 -0
- package/src/assets/fonts/metropolis/Metropolis-Medium.woff2 +0 -0
- package/src/assets/fonts/metropolis/Metropolis-MediumItalic.woff2 +0 -0
- package/src/assets/fonts/metropolis/Metropolis-Regular.woff2 +0 -0
- package/src/assets/fonts/metropolis/Metropolis-RegularItalic.woff2 +0 -0
- package/src/assets/fonts/metropolis/Metropolis-SemiBold.woff2 +0 -0
- package/src/assets/fonts/metropolis/Metropolis-SemiBoldItalic.woff2 +0 -0
- package/src/assets/scss/styles.scss +1 -0
- package/src/components/AsteroidWatchWidget/AsteroidWatchWidget.stories.js +156 -0
- package/src/components/AsteroidWatchWidget/AsteroidWatchWidget.vue +156 -0
- package/src/components/BackToTop/BackToTop.stories.js +24 -0
- package/src/components/BackToTop/BackToTop.vue +76 -0
- package/src/components/BaseAudio/BaseAudio.stories.js +29 -0
- package/src/components/BaseAudio/BaseAudio.vue +359 -0
- package/src/components/BaseButton/BaseButton.stories.ts +65 -0
- package/src/components/BaseButton/BaseButton.vue +114 -0
- package/src/components/BaseCheckboxGroup/BaseCheckboxGroup.stories.mdx +68 -0
- package/src/components/BaseCheckboxGroup/BaseCheckboxGroup.vue +101 -0
- package/src/components/BaseHeading/BaseHeading.stories.js +75 -0
- package/src/components/BaseHeading/BaseHeading.vue +58 -0
- package/src/components/BaseImage/BaseImage.stories.ts +52 -0
- package/src/components/BaseImage/BaseImage.vue +120 -0
- package/src/components/BaseImageCaption/BaseImageCaption.stories.js +27 -0
- package/src/components/BaseImageCaption/BaseImageCaption.vue +51 -0
- package/src/components/BaseImagePlaceholder/BaseImagePlaceholder.stories.js +73 -0
- package/src/components/BaseImagePlaceholder/BaseImagePlaceholder.vue +90 -0
- package/src/components/BaseLightboxCloseButton/BaseLightboxCloseButton.vue +45 -0
- package/src/components/BaseLightboxOpenButton/BaseLightboxOpenButton.vue +46 -0
- package/src/components/BaseLink/BaseLink.stories.js +47 -0
- package/src/components/BaseLink/BaseLink.vue +227 -0
- package/src/components/BaseModal/BaseModal.stories.js +90 -0
- package/src/components/BaseModal/BaseModal.vue +54 -0
- package/src/components/BaseModal/BaseModalDialog.vue +59 -0
- package/src/components/BasePlaceholder/BasePlaceholder.stories.js +29 -0
- package/src/components/BasePlaceholder/BasePlaceholder.vue +30 -0
- package/src/components/BaseRadioGroup/BaseRadioGroup.stories.mdx +68 -0
- package/src/components/BaseRadioGroup/BaseRadioGroup.vue +102 -0
- package/src/components/BaseSwimlane/BaseSwimlane.stories.mdx +64 -0
- package/src/components/BaseSwimlane/BaseSwimlane.vue +204 -0
- package/src/components/BaseTag/BaseTag.stories.js +34 -0
- package/src/components/BaseTag/BaseTag.vue +36 -0
- package/src/components/BaseTimer/BaseTimer.stories.js +78 -0
- package/src/components/BaseTimer/BaseTimer.test.js +15 -0
- package/src/components/BaseTimer/BaseTimer.vue +270 -0
- package/src/components/BaseUnitToggle/BaseUnitToggle.stories.js +86 -0
- package/src/components/BaseUnitToggle/BaseUnitToggle.test.js +26 -0
- package/src/components/BaseUnitToggle/BaseUnitToggle.vue +255 -0
- package/src/components/BaseVideo/BaseVideo.stories.js +31 -0
- package/src/components/BaseVideo/BaseVideo.vue +73 -0
- package/src/components/BlockAnchor/BlockAnchor.vue +38 -0
- package/src/components/BlockAudio/BlockAudio.stories.js +29 -0
- package/src/components/BlockAudio/BlockAudio.vue +78 -0
- package/src/components/BlockCard/BlockCard.stories.js +24 -0
- package/src/components/BlockCard/BlockCard.vue +88 -0
- package/src/components/BlockCardGroup/BlockCardGroup.stories.js +71 -0
- package/src/components/BlockCardGroup/BlockCardGroup.vue +61 -0
- package/src/components/BlockCircleImageCard/BlockCircleImageCard.stories.js +55 -0
- package/src/components/BlockCircleImageCard/BlockCircleImageCard.vue +120 -0
- package/src/components/BlockCta/BlockCta.stories.js +35 -0
- package/src/components/BlockCta/BlockCta.vue +55 -0
- package/src/components/BlockHeading/BlockHeading.stories.js +22 -0
- package/src/components/BlockHeading/BlockHeading.vue +27 -0
- package/src/components/BlockIframeEmbed/BlockIframeEmbed.stories.js +40 -0
- package/src/components/BlockIframeEmbed/BlockIframeEmbed.vue +84 -0
- package/src/components/BlockImage/BlockImage.stories.js +137 -0
- package/src/components/BlockImage/BlockImage.vue +48 -0
- package/src/components/BlockImage/BlockImageFullBleed.vue +119 -0
- package/src/components/BlockImage/BlockImageStandard.vue +106 -0
- package/src/components/BlockImageCarousel/BlockImageCarousel.stories.js +108 -0
- package/src/components/BlockImageCarousel/BlockImageCarousel.vue +201 -0
- package/src/components/BlockImageCarouselItem/BlockImageCarouselItem.stories.js +63 -0
- package/src/components/BlockImageCarouselItem/BlockImageCarouselItem.vue +120 -0
- package/src/components/BlockImageComparison/BlockImageComparison.stories.js +46 -0
- package/src/components/BlockImageComparison/BlockImageComparison.vue +59 -0
- package/src/components/BlockImageGallery/BlockImageGallery.stories.js +55 -0
- package/src/components/BlockImageGallery/BlockImageGallery.vue +128 -0
- package/src/components/BlockInlineImage/BlockInlineImage.stories.js +68 -0
- package/src/components/BlockInlineImage/BlockInlineImage.vue +124 -0
- package/src/components/BlockKeyPoints/BlockKeyPoints.stories.js +28 -0
- package/src/components/BlockKeyPoints/BlockKeyPoints.vue +48 -0
- package/src/components/BlockLinkCard/BlockLinkCard.stories.js +102 -0
- package/src/components/BlockLinkCard/BlockLinkCard.vue +197 -0
- package/src/components/BlockLinkCarousel/BlockLinkCarousel.stories.js +217 -0
- package/src/components/BlockLinkCarousel/BlockLinkCarousel.vue +68 -0
- package/src/components/BlockLinkTile/BlockLinkTile.stories.js +72 -0
- package/src/components/BlockLinkTile/BlockLinkTile.vue +193 -0
- package/src/components/BlockListCards/BlockListCards.stories.js +69 -0
- package/src/components/BlockListCards/BlockListCards.vue +129 -0
- package/src/components/BlockQuote/BlockQuote.stories.js +84 -0
- package/src/components/BlockQuote/BlockQuote.vue +87 -0
- package/src/components/BlockRelatedLinks/BlockRelatedLinks.stories.js +60 -0
- package/src/components/BlockRelatedLinks/BlockRelatedLinks.vue +77 -0
- package/src/components/BlockRelatedLinks/RelatedLink.vue +85 -0
- package/src/components/BlockStreamfield/BlockStreamfield.stories.js +88 -0
- package/src/components/BlockStreamfield/BlockStreamfield.vue +333 -0
- package/src/components/BlockTable/BlockTable.stories.js +20 -0
- package/src/components/BlockTable/BlockTable.vue +73 -0
- package/src/components/BlockTeaser/BlockTeaser.stories.js +74 -0
- package/src/components/BlockTeaser/BlockTeaser.test.js +12 -0
- package/src/components/BlockTeaser/BlockTeaser.vue +174 -0
- package/src/components/BlockText/BlockText.stories.js +21 -0
- package/src/components/BlockText/BlockText.vue +44 -0
- package/src/components/BlockTwitterEmbed/BlockTwitterEmbed.stories.js +19 -0
- package/src/components/BlockTwitterEmbed/BlockTwitterEmbed.vue +61 -0
- package/src/components/BlockVideo/BlockVideo.stories.js +23 -0
- package/src/components/BlockVideo/BlockVideo.vue +41 -0
- package/src/components/BlockVideoEmbed/BlockVideoEmbed.stories.js +20 -0
- package/src/components/BlockVideoEmbed/BlockVideoEmbed.vue +71 -0
- package/src/components/CalendarButton/CalendarButton.stories.js +36 -0
- package/src/components/CalendarButton/CalendarButton.vue +86 -0
- package/src/components/DetailHeadline/DetailHeadline.stories.js +48 -0
- package/src/components/DetailHeadline/DetailHeadline.vue +143 -0
- package/src/components/DsnWidget/DsnWidget.stories.js +29 -0
- package/src/components/DsnWidget/DsnWidget.vue +96 -0
- package/src/components/EventCard/EventCard.vue +188 -0
- package/src/components/EventDetailHero/EventDetailHero.stories.js +53 -0
- package/src/components/EventDetailHero/EventDetailHero.vue +64 -0
- package/src/components/FormContact/FormContact.stories.js +16 -0
- package/src/components/FormContact/FormContact.vue +202 -0
- package/src/components/FormNewsletterSignup/FormNewsletterSignup.stories.js +16 -0
- package/src/components/FormNewsletterSignup/FormNewsletterSignup.vue +355 -0
- package/src/components/HeroLarge/HeroLarge.stories.js +46 -0
- package/src/components/HeroLarge/HeroLarge.vue +93 -0
- package/src/components/HeroListingIndex/HeroListingIndex.stories.js +156 -0
- package/src/components/HeroListingIndex/HeroListingIndex.vue +80 -0
- package/src/components/HeroMedia/HeroMedia.stories.js +135 -0
- package/src/components/HeroMedia/HeroMedia.vue +174 -0
- package/src/components/HeroMedium/HeroMedium.stories.js +73 -0
- package/src/components/HeroMedium/HeroMedium.vue +166 -0
- package/src/components/HomepageCarousel/HomepageCarousel.stories.js +112 -0
- package/src/components/HomepageCarousel/HomepageCarousel.vue +382 -0
- package/src/components/HomepageCarouselItem/HomepageCarouselItem.stories.js +60 -0
- package/src/components/HomepageCarouselItem/HomepageCarouselItem.vue +168 -0
- package/src/components/HomepageEmbedBlock/HomepageEmbedBlock.stories.js +35 -0
- package/src/components/HomepageEmbedBlock/HomepageEmbedBlock.vue +39 -0
- package/src/components/HomepageFeaturedRobot/HomepageFeaturedRobot.stories.js +93 -0
- package/src/components/HomepageFeaturedRobot/HomepageFeaturedRobot.vue +129 -0
- package/src/components/HomepageMissionsCarousel/HomepageMissionsCarousel.stories.js +153 -0
- package/src/components/HomepageMissionsCarousel/HomepageMissionsCarousel.vue +282 -0
- package/src/components/HomepageMissionsCarousel/HomepageMissionsCarouselItem.vue +143 -0
- package/src/components/HomepageStats/HomepageStats.stories.js +155 -0
- package/src/components/HomepageStats/HomepageStats.vue +362 -0
- package/src/components/HomepageTeaserBlock/HomepageTeaserBlock.stories.js +90 -0
- package/src/components/HomepageTeaserBlock/HomepageTeaserBlock.vue +156 -0
- package/src/components/HomepageTeaserBlock/HomepageTeaserBlockCardImage.vue +58 -0
- package/src/components/Icons/Icon360.vue +29 -0
- package/src/components/Icons/IconArrow.vue +26 -0
- package/src/components/Icons/IconArrows.vue +43 -0
- package/src/components/Icons/IconAudio.vue +27 -0
- package/src/components/Icons/IconBook.vue +21 -0
- package/src/components/Icons/IconBookUser.vue +21 -0
- package/src/components/Icons/IconBriefcase.vue +21 -0
- package/src/components/Icons/IconCalendar.vue +25 -0
- package/src/components/Icons/IconCaret.vue +26 -0
- package/src/components/Icons/IconCheckbox.vue +26 -0
- package/src/components/Icons/IconCheckboxSelected.vue +35 -0
- package/src/components/Icons/IconClose.vue +27 -0
- package/src/components/Icons/IconCloseLightbox.vue +25 -0
- package/src/components/Icons/IconDownload.vue +31 -0
- package/src/components/Icons/IconDropdown.vue +25 -0
- package/src/components/Icons/IconEnvelope.vue +21 -0
- package/src/components/Icons/IconExpand.vue +28 -0
- package/src/components/Icons/IconExternal.vue +25 -0
- package/src/components/Icons/IconFilter.vue +25 -0
- package/src/components/Icons/IconForwardTen.vue +38 -0
- package/src/components/Icons/IconGrid.vue +25 -0
- package/src/components/Icons/IconHand.vue +21 -0
- package/src/components/Icons/IconInfo.vue +26 -0
- package/src/components/Icons/IconLink.vue +27 -0
- package/src/components/Icons/IconList.vue +25 -0
- package/src/components/Icons/IconLocation.vue +37 -0
- package/src/components/Icons/IconMagnifyingGlass.vue +21 -0
- package/src/components/Icons/IconMedal.vue +21 -0
- package/src/components/Icons/IconMenu.vue +27 -0
- package/src/components/Icons/IconMinus.vue +26 -0
- package/src/components/Icons/IconMute.vue +27 -0
- package/src/components/Icons/IconNext.vue +25 -0
- package/src/components/Icons/IconPause.vue +28 -0
- package/src/components/Icons/IconPlay.vue +28 -0
- package/src/components/Icons/IconPlus.vue +25 -0
- package/src/components/Icons/IconPrev.vue +25 -0
- package/src/components/Icons/IconRewindTen.vue +42 -0
- package/src/components/Icons/IconSearch.vue +25 -0
- package/src/components/Icons/IconShare.vue +30 -0
- package/src/components/Icons/IconSlideshow.vue +30 -0
- package/src/components/Icons/IconSocialEmail.vue +26 -0
- package/src/components/Icons/IconSocialFacebook.vue +26 -0
- package/src/components/Icons/IconSocialGoogleClassroom.vue +26 -0
- package/src/components/Icons/IconSocialInstagram.vue +35 -0
- package/src/components/Icons/IconSocialPinterest.vue +26 -0
- package/src/components/Icons/IconSocialReddit.vue +25 -0
- package/src/components/Icons/IconSocialTwitter.vue +25 -0
- package/src/components/Icons/IconSocialYoutube.vue +35 -0
- package/src/components/Icons/IconStop.vue +27 -0
- package/src/components/Icons/IconTime.vue +25 -0
- package/src/components/Icons/IconUniversity.vue +21 -0
- package/src/components/Icons/IconUser.vue +26 -0
- package/src/components/Icons/IconVolume.vue +27 -0
- package/src/components/Icons/Icons.stories.ts +440 -0
- package/src/components/ImageDetailContextImage/ImageDetailContextImage.vue +125 -0
- package/src/components/LayoutHelper/LayoutHelper.vue +38 -0
- package/src/components/LoadingTransition/LoadingTransition.vue +48 -0
- package/src/components/LogoCaltech/LogoCaltech.stories.js +39 -0
- package/src/components/LogoCaltech/LogoCaltech.vue +29 -0
- package/src/components/LogoTribrand/LogoTribrand.stories.js +76 -0
- package/src/components/LogoTribrand/LogoTribrand.vue +93 -0
- package/src/components/MissionDetailAbout/MissionDetailAbout.stories.js +70 -0
- package/src/components/MissionDetailAbout/MissionDetailAbout.vue +204 -0
- package/src/components/MissionDetailHero/MissionDetailHero.stories.js +303 -0
- package/src/components/MissionDetailHero/MissionDetailHero.vue +292 -0
- package/src/components/MissionDetailHighlights/MissionDetailHighlights.stories.js +278 -0
- package/src/components/MissionDetailHighlights/MissionDetailHighlights.vue +332 -0
- package/src/components/MissionDetailHighlights/MissionDetailHighlightsCarousel.vue +160 -0
- package/src/components/MissionDetailHighlights/MissionDetailHighlightsCarouselItem.vue +123 -0
- package/src/components/MissionDetailInlineImage/MissionDetailInlineImage.stories.js +43 -0
- package/src/components/MissionDetailInlineImage/MissionDetailInlineImage.vue +97 -0
- package/src/components/MissionDetailStats/DistanceStats.test.js +133 -0
- package/src/components/MissionDetailStats/DistanceStats.vue +250 -0
- package/src/components/MissionDetailStats/MissionDetailStats.stories.js +95 -0
- package/src/components/MissionDetailStats/MissionDetailStats.test.js +23 -0
- package/src/components/MissionDetailStats/MissionDetailStats.vue +187 -0
- package/src/components/MissionDetailStats/MissionDetailStatsMicro.vue +52 -0
- package/src/components/MissionDetailStats/MissionDetailStatsMini.vue +109 -0
- package/src/components/MissionDetailStreamfield/MissionDetailStreamfield.stories.js +55 -0
- package/src/components/MissionDetailStreamfield/MissionDetailStreamfield.vue +95 -0
- package/src/components/MixinAnimationCaret/MixinAnimationCaret.stories.ts +24 -0
- package/src/components/MixinAnimationCaret/MixinAnimationCaret.vue +81 -0
- package/src/components/MixinCarousel/MixinCarousel.docs.mdx +33 -0
- package/src/components/MixinCarousel/MixinCarousel.stories.js +53 -0
- package/src/components/MixinCarousel/MixinCarousel.vue +236 -0
- package/src/components/MixinDropdownToggle/MixinDropdownToggle.vue +53 -0
- package/src/components/MixinFancybox/MixinFancybox.vue +405 -0
- package/src/components/MixinFancybox/MixinFancyboxOpenButton.vue +35 -0
- package/src/components/MixinVideoBg/MixinVideoBg.stories.js +23 -0
- package/src/components/MixinVideoBg/MixinVideoBg.vue +39 -0
- package/src/components/NavDesktop/NavDesktop.stories.js +254 -0
- package/src/components/NavDesktop/NavDesktop.vue +355 -0
- package/src/components/NavDesktop/NavDesktopDropdown.vue +201 -0
- package/src/components/NavDesktop/NavDesktopDropdownContent.vue +87 -0
- package/src/components/NavDesktop/NavDesktopDropdownMore.vue +112 -0
- package/src/components/NavDesktop/NavDesktopTopHat.vue +56 -0
- package/src/components/NavHeading/NavHeading.stories.js +23 -0
- package/src/components/NavHeading/NavHeading.vue +40 -0
- package/src/components/NavHighlight/NavHighlight.stories.js +42 -0
- package/src/components/NavHighlight/NavHighlight.vue +67 -0
- package/src/components/NavLinkList/NavLinkList.stories.js +46 -0
- package/src/components/NavLinkList/NavLinkList.vue +66 -0
- package/src/components/NavLogoLinks/NavLogoLinks.stories.js +22 -0
- package/src/components/NavLogoLinks/NavLogoLinks.vue +57 -0
- package/src/components/NavMobile/NavMobile.stories.js +231 -0
- package/src/components/NavMobile/NavMobile.vue +280 -0
- package/src/components/NavMobile/NavMobileDropdown.vue +175 -0
- package/src/components/NavMobile/NavMobileLink.vue +69 -0
- package/src/components/NavMobile/NavMobileSecondaryDropdown.vue +124 -0
- package/src/components/NavSearchForm/NavSearchForm.stories.js +13 -0
- package/src/components/NavSearchForm/NavSearchForm.vue +102 -0
- package/src/components/NavSecondary/NavSecondary.stories.js +24 -0
- package/src/components/NavSecondary/NavSecondary.vue +191 -0
- package/src/components/NavSecondary/NavSecondaryDropdown.vue +181 -0
- package/src/components/NavSecondary/NavSecondaryDropdownContent.vue +140 -0
- package/src/components/NavSecondary/NavSecondaryLink.vue +62 -0
- package/src/components/NavSocial/NavSocial.stories.js +20 -0
- package/src/components/NavSocial/NavSocial.vue +97 -0
- package/src/components/NewsDetailMediaContact/NewsDetailMediaContact.stories.js +60 -0
- package/src/components/NewsDetailMediaContact/NewsDetailMediaContact.test.js +30 -0
- package/src/components/NewsDetailMediaContact/NewsDetailMediaContact.vue +73 -0
- package/src/components/ParallaxContainer/ParallaxContainer.stories.js +47 -0
- package/src/components/ParallaxContainer/ParallaxContainer.vue +76 -0
- package/src/components/ParallaxElement/ParallaxElement.vue +25 -0
- package/src/components/PastEventsCarousel/PastEventsCarousel.vue +86 -0
- package/src/components/PodcastEpisodeCard/PodcastEpisodeCard.vue +251 -0
- package/src/components/PodcastSeriesCarousel/PodcastSeriesCarousel.stories.js +235 -0
- package/src/components/PodcastSeriesCarousel/PodcastSeriesCarousel.vue +171 -0
- package/src/components/ProfileDetailSectionGroup/ProfileDetailSectionGroup.vue +84 -0
- package/src/components/RoboticsDetailStats/RoboticsDetailStats.stories.js +97 -0
- package/src/components/RoboticsDetailStats/RoboticsDetailStats.test.js +21 -0
- package/src/components/RoboticsDetailStats/RoboticsDetailStats.vue +217 -0
- package/src/components/RoboticsDetailStats/RoboticsDetailStatsMini.vue +182 -0
- package/src/components/SearchFilterGroup/SearchFilterGroup.stories.js +59 -0
- package/src/components/SearchFilterGroup/SearchFilterGroup.vue +221 -0
- package/src/components/SearchInput/SearchInput.stories.js +35 -0
- package/src/components/SearchInput/SearchInput.vue +93 -0
- package/src/components/SearchPagination/SearchPagination.stories.js +55 -0
- package/src/components/SearchPagination/SearchPagination.vue +173 -0
- package/src/components/SearchResultCard/SearchResultCard.stories.js +57 -0
- package/src/components/SearchResultCard/SearchResultCard.vue +282 -0
- package/src/components/SearchResultGridItem/SearchResultGridItem.stories.js +70 -0
- package/src/components/SearchResultGridItem/SearchResultGridItem.vue +140 -0
- package/src/components/SearchResultsList/SearchResultsList.vue +183 -0
- package/src/components/SearchSelectMenu/SearchSelectMenu.stories.js +25 -0
- package/src/components/SearchSelectMenu/SearchSelectMenu.vue +86 -0
- package/src/components/ShareButtons/ShareButtons.stories.js +16 -0
- package/src/components/ShareButtons/ShareButtons.vue +132 -0
- package/src/components/ShareButtonsEdu/ShareButtonsEdu.stories.js +14 -0
- package/src/components/ShareButtonsEdu/ShareButtonsEdu.vue +215 -0
- package/src/components/SkipLink/SkipLink.stories.js +9 -0
- package/src/components/SkipLink/SkipLink.vue +53 -0
- package/src/components/SwimlaneCTA/SwimlaneCTA.stories.mdx +77 -0
- package/src/components/SwimlaneCTA/SwimlaneCTA.vue +281 -0
- package/src/components/TheFooter/TheFooter.stories.js +602 -0
- package/src/components/TheFooter/TheFooter.vue +228 -0
- package/src/components/TheFooter/TheFooterSignUp.vue +61 -0
- package/src/components/ThumbnailCarousel/ThumbnailCarousel.stories.js +106 -0
- package/src/components/ThumbnailCarousel/ThumbnailCarousel.vue +76 -0
- package/src/components/TopicDetailMissionCarousel/TopicDetailMissionCarousel.stories.js +93 -0
- package/src/components/TopicDetailMissionCarousel/TopicDetailMissionCarousel.vue +68 -0
- package/src/components/TopicDetailMissionCarouselItem/TopicDetailMissionCarouselItem.stories.js +38 -0
- package/src/components/TopicDetailMissionCarouselItem/TopicDetailMissionCarouselItem.vue +104 -0
- package/src/components/TopicDetailMissionSpotlight/TopicDetailMissionSpotlight.stories.js +84 -0
- package/src/components/TopicDetailMissionSpotlight/TopicDetailMissionSpotlight.vue +112 -0
- package/src/components/TopicDetailMore/TopicDetailMore.stories.js +221 -0
- package/src/components/TopicDetailMore/TopicDetailMore.vue +124 -0
- package/src/components/TopicDetailMore/TopicDetailMoreVisibility.vue +51 -0
- package/src/components/TopicDetailMoreItem/TopicDetailMoreItem.stories.js +116 -0
- package/src/components/TopicDetailMoreItem/TopicDetailMoreItem.vue +130 -0
- package/src/components/TopicDetailStreamfield/TopicDetailStreamfield.stories.js +34 -0
- package/src/components/TopicDetailStreamfield/TopicDetailStreamfield.vue +98 -0
- package/src/components/YearTicker/YearTicker.stories.js +37 -0
- package/src/components/YearTicker/YearTicker.vue +132 -0
- package/src/docs/foundation/DynamicTokens.vue +106 -0
- package/src/docs/foundation/FontVariants.vue +80 -0
- package/src/docs/foundation/color.docs.mdx +112 -0
- package/src/docs/foundation/grid.docs.mdx +189 -0
- package/src/docs/foundation/grid.stories.js +263 -0
- package/src/docs/foundation/grid_layouthelpers.docs.mdx +78 -0
- package/src/docs/foundation/grid_layouthelpers.stories.js +53 -0
- package/src/docs/foundation/themes.docs.mdx +71 -0
- package/src/docs/foundation/themes.stories.js +63 -0
- package/src/docs/foundation/typography.docs.mdx +50 -0
- package/src/docs/foundation/typography.stories.js +119 -0
- package/src/interfaces.ts +129 -0
- package/src/main.ts +34 -0
- package/src/store/header.ts +40 -0
- package/src/store/theme.ts +27 -0
- package/src/templates/PageContent/PageContent.stories.js +92 -0
- package/src/templates/PageContent/PageContent.vue +140 -0
- package/src/templates/PageEventDetail/PageEventDetail.stories.js +104 -0
- package/src/templates/PageEventDetail/PageEventDetail.vue +358 -0
- package/src/templates/PageNewsDetail/PageNewsDetail.stories.js +158 -0
- package/src/templates/PageNewsDetail/PageNewsDetail.vue +242 -0
- package/src/templates/edu/PageEduNewsDetail.stories.js +64 -0
- package/src/templates/edu/PageEduNewsDetail.vue +155 -0
- package/src/templates/www/HomePage/HomePage.vue +30 -0
- package/src/utils/dayjs.js +32 -0
- package/src/utils/filters.js +33 -0
- package/src/utils/mixins.ts +353 -0
- package/src/vite-env.d.ts +1 -0
- package/tailwind.config.js +24 -0
- package/tsconfig.json +29 -0
- package/tsconfig.node.json +11 -0
- package/vite.config.ts +55 -0
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
v-if="pageData"
|
|
4
|
+
class="max-w-screen-3xl mx-auto"
|
|
5
|
+
:class="{ '-nav-offset': pageData.featured }"
|
|
6
|
+
>
|
|
7
|
+
<HeroMedium
|
|
8
|
+
v-if="pageData.featured"
|
|
9
|
+
class="md:mb-12 lg:mb-18 mb-10"
|
|
10
|
+
:custom-tag="themeStore.theme === 'ThemeEdu' && customLabel ? customLabel : undefined"
|
|
11
|
+
:custom-label="themeStore.theme === 'ThemeEdu' ? pageData.featured.topicLabel : customLabel"
|
|
12
|
+
:feature="pageData.featured"
|
|
13
|
+
:custom-video="customVideo"
|
|
14
|
+
:custom-image="customImage"
|
|
15
|
+
:cta="cta"
|
|
16
|
+
/>
|
|
17
|
+
</div>
|
|
18
|
+
</template>
|
|
19
|
+
<script lang="ts">
|
|
20
|
+
// HeroListingIndex
|
|
21
|
+
// Creating a wrapper for HeroMedium as HeroListingIndex needs to parse several different data shapes.
|
|
22
|
+
// Parsing occurs in the computed data and returns the appropriate data object for the media if it exists.
|
|
23
|
+
import { defineComponent } from 'vue'
|
|
24
|
+
import { useThemeStore } from '../../store/theme'
|
|
25
|
+
import { mapStores } from 'pinia'
|
|
26
|
+
import HeroMedium from '../HeroMedium/HeroMedium.vue'
|
|
27
|
+
|
|
28
|
+
export default defineComponent({
|
|
29
|
+
name: 'HeroListingIndex',
|
|
30
|
+
components: {
|
|
31
|
+
HeroMedium
|
|
32
|
+
},
|
|
33
|
+
props: {
|
|
34
|
+
// pass these directly to HeroMedium
|
|
35
|
+
pageData: {
|
|
36
|
+
type: Object,
|
|
37
|
+
required: false
|
|
38
|
+
},
|
|
39
|
+
customLabel: {
|
|
40
|
+
type: String,
|
|
41
|
+
required: false
|
|
42
|
+
},
|
|
43
|
+
cta: {
|
|
44
|
+
type: String,
|
|
45
|
+
default: 'Read Article'
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
computed: {
|
|
49
|
+
...mapStores(useThemeStore),
|
|
50
|
+
// parses a hero streamfield block for a video (newsDetailPage model)
|
|
51
|
+
customVideo(): object | undefined {
|
|
52
|
+
if (this.pageData && this.pageData.featured?.heroBlocks?.length > 0) {
|
|
53
|
+
if (this.pageData.featured.heroBlocks[0].blockType === 'VideoBlock') {
|
|
54
|
+
return this.pageData.featured.heroBlocks[0].video
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
return undefined
|
|
58
|
+
},
|
|
59
|
+
customImage(): object | undefined {
|
|
60
|
+
// parse hero streamfield block for the first usable image (newsDetailPage model)
|
|
61
|
+
if (this.pageData && this.pageData.featured?.heroBlocks?.length > 0) {
|
|
62
|
+
const block = this.pageData.featured.heroBlocks[0]
|
|
63
|
+
if (block.blockType === 'ImageChooserBlock' || block.blockType === 'HeroImageBlock') {
|
|
64
|
+
return block.listingPageHeroImage
|
|
65
|
+
} else if (block.blockType === 'CarouselBlock') {
|
|
66
|
+
// use the first image in the carousel
|
|
67
|
+
if (block.blocks && block.blocks.length > 0) {
|
|
68
|
+
return block.blocks[0].listingPageHeroImage
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
// else use heroImage
|
|
73
|
+
else if (this.pageData?.featured?.listingPageHeroImage) {
|
|
74
|
+
return this.pageData.featured.listingPageHeroImage
|
|
75
|
+
}
|
|
76
|
+
return undefined
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
})
|
|
80
|
+
</script>
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
import { BaseVideoData } from './../BaseVideo/BaseVideo.stories'
|
|
2
|
+
import HeroMedia from './HeroMedia.vue'
|
|
3
|
+
|
|
4
|
+
export default {
|
|
5
|
+
title: 'Components/Heroes/HeroMedia',
|
|
6
|
+
component: HeroMedia,
|
|
7
|
+
decorators: [
|
|
8
|
+
() => ({
|
|
9
|
+
template: `<div id="storyDecorator" class="absolute inset-0"><story/></div>`
|
|
10
|
+
})
|
|
11
|
+
],
|
|
12
|
+
parameters: {
|
|
13
|
+
html: {
|
|
14
|
+
root: '#storyDecorator'
|
|
15
|
+
},
|
|
16
|
+
viewMode: 'canvas'
|
|
17
|
+
},
|
|
18
|
+
excludeStories: /.*Data$/
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export const HeroMediaData = {
|
|
22
|
+
blockType: 'ImageChooserBlock',
|
|
23
|
+
imageInline: {
|
|
24
|
+
alt: 'A inline hero image',
|
|
25
|
+
caption:
|
|
26
|
+
'<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed vel porttitor urna. Maecenas at est laoreet, sagittis risus a, rutrum ipsum. Quisque tincidunt lacus nunc, dapibus facilisis felis scelerisque sit amet. </p>',
|
|
27
|
+
credit: 'NASA/JPL',
|
|
28
|
+
detailUrl: '/image/placeholder/',
|
|
29
|
+
original: 'https://picsum.photos/869/700',
|
|
30
|
+
src: {
|
|
31
|
+
height: 700,
|
|
32
|
+
url: 'https://picsum.photos/869/700',
|
|
33
|
+
width: 869
|
|
34
|
+
},
|
|
35
|
+
srcSet: 'https://picsum.photos/320/258 320w, https://picsum.photos/869/700 1024w'
|
|
36
|
+
},
|
|
37
|
+
image: {
|
|
38
|
+
src: {
|
|
39
|
+
url: 'https://picsum.photos/1440/620',
|
|
40
|
+
width: 1440,
|
|
41
|
+
height: 620
|
|
42
|
+
},
|
|
43
|
+
screenXs: {
|
|
44
|
+
url: 'https://picsum.photos/320/139',
|
|
45
|
+
width: 320
|
|
46
|
+
},
|
|
47
|
+
screenSm: {
|
|
48
|
+
url: 'https://picsum.photos/640/276',
|
|
49
|
+
width: 640
|
|
50
|
+
},
|
|
51
|
+
screenMd: {
|
|
52
|
+
url: 'https://picsum.photos/768/331',
|
|
53
|
+
width: 768
|
|
54
|
+
},
|
|
55
|
+
screenLg: {
|
|
56
|
+
url: 'https://picsum.photos/1024/442',
|
|
57
|
+
width: 1024
|
|
58
|
+
},
|
|
59
|
+
screenXl: {
|
|
60
|
+
url: 'https://picsum.photos/1280/552',
|
|
61
|
+
width: 1280
|
|
62
|
+
},
|
|
63
|
+
screenTwoxl: {
|
|
64
|
+
url: 'https://picsum.photos/1440/620',
|
|
65
|
+
width: 1440
|
|
66
|
+
},
|
|
67
|
+
screenThreexl: {
|
|
68
|
+
url: 'https://picsum.photos/1800/775',
|
|
69
|
+
width: 1800
|
|
70
|
+
},
|
|
71
|
+
alt: 'News detail page hero image',
|
|
72
|
+
caption:
|
|
73
|
+
'<p>NASA InSight's robotic arm will use its scoop to pin the spacecraft's heat probe against the wall of its hole.</p>',
|
|
74
|
+
credit: 'NASA/JPL',
|
|
75
|
+
detailUrl: '/images/image-123/'
|
|
76
|
+
},
|
|
77
|
+
caption: '',
|
|
78
|
+
displayCaption: true
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
// stories
|
|
82
|
+
export const Hero = {
|
|
83
|
+
args: HeroMediaData
|
|
84
|
+
}
|
|
85
|
+
export const CustomImageCaption = {
|
|
86
|
+
args: {
|
|
87
|
+
...HeroMediaData,
|
|
88
|
+
caption: '<p>My custom caption.</p>'
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
export const NoCaptionText = {
|
|
93
|
+
args: {
|
|
94
|
+
...HeroMediaData,
|
|
95
|
+
caption: '<p>My custom caption.</p>',
|
|
96
|
+
displayCaption: false
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
export const NoCaptionArea = {
|
|
101
|
+
args: {
|
|
102
|
+
image: {
|
|
103
|
+
src: HeroMediaData.image.src,
|
|
104
|
+
alt: 'The hero image',
|
|
105
|
+
caption: '\n', // a lot of prod data has this for caption
|
|
106
|
+
credit: '',
|
|
107
|
+
detailUrl: ''
|
|
108
|
+
},
|
|
109
|
+
caption: '<p>My custom caption.</p>',
|
|
110
|
+
displayCaption: false
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
export const NoLink = {
|
|
114
|
+
args: {
|
|
115
|
+
image: {
|
|
116
|
+
src: HeroMediaData.image.src,
|
|
117
|
+
alt: HeroMediaData.image.src,
|
|
118
|
+
caption: HeroMediaData.image.caption,
|
|
119
|
+
credit: HeroMediaData.image.credit,
|
|
120
|
+
detailUrl: ''
|
|
121
|
+
},
|
|
122
|
+
caption: '',
|
|
123
|
+
displayCaption: true
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
export const Video = {
|
|
128
|
+
args: {
|
|
129
|
+
blockType: 'VideoBlock',
|
|
130
|
+
video: BaseVideoData,
|
|
131
|
+
caption:
|
|
132
|
+
'<p>Lorem ipsum dolor sit amet. <a href="#">A link in the caption</a> testing render.</p>',
|
|
133
|
+
credit: 'NASA/JPL'
|
|
134
|
+
}
|
|
135
|
+
}
|
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
v-if="image || video"
|
|
4
|
+
class="HeroMedia"
|
|
5
|
+
>
|
|
6
|
+
<div class="bg-gray-light">
|
|
7
|
+
<div class="vh-crop max-w-screen-3xl relative flex items-center mx-auto overflow-hidden">
|
|
8
|
+
<div class="hero">
|
|
9
|
+
<template v-if="theImageData">
|
|
10
|
+
<img
|
|
11
|
+
v-if="theImageData.src"
|
|
12
|
+
class="object-cover object-center w-full h-full"
|
|
13
|
+
:srcset="theSrcSet"
|
|
14
|
+
:src="theImageData.src.url"
|
|
15
|
+
:width="theImageData.src.width"
|
|
16
|
+
:height="theImageData.src.height"
|
|
17
|
+
:alt="theImageData.alt"
|
|
18
|
+
itemprop="image"
|
|
19
|
+
/>
|
|
20
|
+
</template>
|
|
21
|
+
<template v-else-if="video">
|
|
22
|
+
<MixinVideoBg :video="video" />
|
|
23
|
+
</template>
|
|
24
|
+
</div>
|
|
25
|
+
<div
|
|
26
|
+
v-if="hasCaptionArea"
|
|
27
|
+
class="lg:hidden absolute bottom-0 left-0 w-full h-auto mx-auto"
|
|
28
|
+
>
|
|
29
|
+
<button
|
|
30
|
+
class="bg-opacity-90 text-gray-dark flex items-center justify-center w-12 h-12 ml-auto bg-white cursor-pointer"
|
|
31
|
+
aria-label="Toggle caption"
|
|
32
|
+
@click="toggleCaption"
|
|
33
|
+
>
|
|
34
|
+
<IconInfo
|
|
35
|
+
v-show="!captionVisible"
|
|
36
|
+
class="text-xl"
|
|
37
|
+
/>
|
|
38
|
+
<IconClose v-show="captionVisible" />
|
|
39
|
+
</button>
|
|
40
|
+
</div>
|
|
41
|
+
</div>
|
|
42
|
+
|
|
43
|
+
<div
|
|
44
|
+
v-if="hasCaptionArea"
|
|
45
|
+
:class="captionVisibilityClass"
|
|
46
|
+
class="max-w-screen-3xl bg-gray-light bg-opacity-90 lg:bg-opacity-100 lg:block lg:pb-4 lg:px-3 xl:px-8 lg:pt-4 items-start p-4 mx-auto"
|
|
47
|
+
>
|
|
48
|
+
<BaseImageCaption :data="theImageData || customCaption" />
|
|
49
|
+
</div>
|
|
50
|
+
</div>
|
|
51
|
+
</div>
|
|
52
|
+
</template>
|
|
53
|
+
<script lang="ts">
|
|
54
|
+
import { defineComponent } from 'vue'
|
|
55
|
+
import MixinVideoBg from './../MixinVideoBg/MixinVideoBg.vue'
|
|
56
|
+
import BaseImageCaption from './../BaseImageCaption/BaseImageCaption.vue'
|
|
57
|
+
import IconInfo from './../Icons/IconInfo.vue'
|
|
58
|
+
import IconClose from './../Icons/IconClose.vue'
|
|
59
|
+
import type { ImageObject } from '../../interfaces'
|
|
60
|
+
import { mixinGetSrcSet, mixinTransparentHeader } from './../../utils/mixins'
|
|
61
|
+
|
|
62
|
+
export default defineComponent({
|
|
63
|
+
/*
|
|
64
|
+
This component displays a full-width hero item at the top of the page
|
|
65
|
+
- accommodates images or videos
|
|
66
|
+
- uses vh to dynamically crop the media based on viewport height
|
|
67
|
+
- manages display state for navigation
|
|
68
|
+
*/
|
|
69
|
+
name: 'HeroMedia',
|
|
70
|
+
components: {
|
|
71
|
+
MixinVideoBg,
|
|
72
|
+
BaseImageCaption,
|
|
73
|
+
IconInfo,
|
|
74
|
+
IconClose
|
|
75
|
+
},
|
|
76
|
+
props: {
|
|
77
|
+
// image object includes the image caption and credit
|
|
78
|
+
image: {
|
|
79
|
+
type: Object,
|
|
80
|
+
required: false
|
|
81
|
+
},
|
|
82
|
+
video: {
|
|
83
|
+
type: Object,
|
|
84
|
+
required: false
|
|
85
|
+
},
|
|
86
|
+
// if a caption should even be visible
|
|
87
|
+
displayCaption: {
|
|
88
|
+
type: Boolean,
|
|
89
|
+
default: true
|
|
90
|
+
},
|
|
91
|
+
// for video heroes that pass separate caption and credit data
|
|
92
|
+
caption: {
|
|
93
|
+
type: String,
|
|
94
|
+
required: false
|
|
95
|
+
},
|
|
96
|
+
credit: {
|
|
97
|
+
type: String,
|
|
98
|
+
required: false
|
|
99
|
+
}
|
|
100
|
+
},
|
|
101
|
+
data() {
|
|
102
|
+
return {
|
|
103
|
+
captionVisible: false
|
|
104
|
+
}
|
|
105
|
+
},
|
|
106
|
+
computed: {
|
|
107
|
+
theImageCaption(): string | undefined {
|
|
108
|
+
if (this.image && this.caption && this.caption.length > 2 && this.displayCaption) {
|
|
109
|
+
return this.caption
|
|
110
|
+
} else if (
|
|
111
|
+
this.image &&
|
|
112
|
+
this.image.caption &&
|
|
113
|
+
this.image.caption.length > 2 &&
|
|
114
|
+
this.displayCaption
|
|
115
|
+
) {
|
|
116
|
+
return this.image.caption
|
|
117
|
+
}
|
|
118
|
+
return undefined
|
|
119
|
+
},
|
|
120
|
+
theImageData(): Partial<ImageObject> | undefined {
|
|
121
|
+
if (this.image) {
|
|
122
|
+
return {
|
|
123
|
+
...this.image,
|
|
124
|
+
caption: this.theImageCaption
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
return undefined
|
|
128
|
+
},
|
|
129
|
+
theSrcSet(): string | undefined {
|
|
130
|
+
return this.theImageData ? mixinGetSrcSet(this.theImageData) : undefined
|
|
131
|
+
},
|
|
132
|
+
// to handle captions for videos
|
|
133
|
+
customCaption(): Partial<ImageObject> | undefined {
|
|
134
|
+
if ((this.caption && this.caption.length > 2) || this.credit) {
|
|
135
|
+
return {
|
|
136
|
+
caption: this.caption,
|
|
137
|
+
credit: this.credit
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
return undefined
|
|
141
|
+
},
|
|
142
|
+
captionVisibilityClass() {
|
|
143
|
+
if (!this.captionVisible) {
|
|
144
|
+
return 'hidden'
|
|
145
|
+
} else {
|
|
146
|
+
return 'flex'
|
|
147
|
+
}
|
|
148
|
+
},
|
|
149
|
+
hasCaptionArea(): string | boolean {
|
|
150
|
+
if (this.theImageData) {
|
|
151
|
+
return this.theImageCaption || this.image?.credit || this.image?.detailUrl
|
|
152
|
+
} else if (this.customCaption) {
|
|
153
|
+
return true
|
|
154
|
+
}
|
|
155
|
+
return false
|
|
156
|
+
}
|
|
157
|
+
},
|
|
158
|
+
mounted() {
|
|
159
|
+
mixinTransparentHeader()
|
|
160
|
+
},
|
|
161
|
+
methods: {
|
|
162
|
+
toggleCaption() {
|
|
163
|
+
if (this.captionVisible) {
|
|
164
|
+
this.captionVisible = false
|
|
165
|
+
} else {
|
|
166
|
+
this.captionVisible = true
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
})
|
|
171
|
+
</script>
|
|
172
|
+
<style lang="scss">
|
|
173
|
+
@import '@explorer-1/common/src/scss/components/HeroMedia';
|
|
174
|
+
</style>
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { BaseVideoData } from './../BaseVideo/BaseVideo.stories'
|
|
2
|
+
import HeroMedium from './HeroMedium.vue'
|
|
3
|
+
|
|
4
|
+
export default {
|
|
5
|
+
title: 'Components/Heroes/HeroMedium',
|
|
6
|
+
component: HeroMedium,
|
|
7
|
+
decorators: [
|
|
8
|
+
() => ({
|
|
9
|
+
template: `<div id="storyDecorator" class="max-w-screen-3xl mx-auto"><story/></div>`
|
|
10
|
+
})
|
|
11
|
+
],
|
|
12
|
+
parameters: {
|
|
13
|
+
html: {
|
|
14
|
+
root: '#storyDecorator'
|
|
15
|
+
},
|
|
16
|
+
themes: {
|
|
17
|
+
clearable: false,
|
|
18
|
+
list: [
|
|
19
|
+
{
|
|
20
|
+
name: 'FullWidthDocs',
|
|
21
|
+
class: 'sbdocs-preview-full-width',
|
|
22
|
+
default: true,
|
|
23
|
+
visible: false
|
|
24
|
+
}
|
|
25
|
+
]
|
|
26
|
+
},
|
|
27
|
+
viewMode: 'docs'
|
|
28
|
+
},
|
|
29
|
+
excludeStories: /.*Data$/
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
// data
|
|
33
|
+
export const HeroMediumData = {
|
|
34
|
+
label: 'Featured',
|
|
35
|
+
cta: 'View',
|
|
36
|
+
feature: {
|
|
37
|
+
url: '/news/new-maps-open-roads-to-research/',
|
|
38
|
+
title: 'Creating Robots to go Where Humans Can’t',
|
|
39
|
+
image: {
|
|
40
|
+
src: {
|
|
41
|
+
url: 'https://picsum.photos/id/973/1800/1200',
|
|
42
|
+
width: 1800,
|
|
43
|
+
height: 1200
|
|
44
|
+
},
|
|
45
|
+
srcSet:
|
|
46
|
+
'https://picsum.photos/id/865/768/548 768w, https://picsum.photos/id/865/1024/684 1024w, https://picsum.photos/id/865/1440/770 1440w, https://picsum.photos/id/865/1800/963 1800w',
|
|
47
|
+
screenMd: {
|
|
48
|
+
url: 'https://picsum.photos/id/921/800/640'
|
|
49
|
+
},
|
|
50
|
+
screenSm: {
|
|
51
|
+
url: 'https://picsum.photos/id/247/640/900'
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export const Default = {
|
|
58
|
+
args: {
|
|
59
|
+
customTag: 'News',
|
|
60
|
+
customLabel: HeroMediumData.label,
|
|
61
|
+
feature: HeroMediumData.feature,
|
|
62
|
+
cta: HeroMediumData.cta,
|
|
63
|
+
customVideo: undefined
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
export const Video = {
|
|
67
|
+
args: {
|
|
68
|
+
customLabel: HeroMediumData.label,
|
|
69
|
+
feature: HeroMediumData.feature,
|
|
70
|
+
cta: HeroMediumData.cta,
|
|
71
|
+
customVideo: BaseVideoData
|
|
72
|
+
}
|
|
73
|
+
}
|
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<section
|
|
3
|
+
aria-label="Feature"
|
|
4
|
+
class="HeroMedium ThemeVariantDark relative flex items-center overflow-hidden"
|
|
5
|
+
>
|
|
6
|
+
<div class="absolute inset-0 z-10 overflow-hidden bg-black">
|
|
7
|
+
<!-- video always overrides the image -->
|
|
8
|
+
<MixinVideoBg
|
|
9
|
+
v-if="theVideo"
|
|
10
|
+
:video="theVideo"
|
|
11
|
+
/>
|
|
12
|
+
<!-- change to v-if if image should load as fallback until video loads -->
|
|
13
|
+
<picture v-else-if="theImage && theImage.src">
|
|
14
|
+
<source
|
|
15
|
+
media="(min-width: 768px)"
|
|
16
|
+
:srcset="theImage.srcSet"
|
|
17
|
+
/>
|
|
18
|
+
<source
|
|
19
|
+
media="(min-width: 420px)"
|
|
20
|
+
:srcset="theImage.screenMd?.url"
|
|
21
|
+
/>
|
|
22
|
+
<source :data-srcset="theImage.screenSm?.url" />
|
|
23
|
+
<img
|
|
24
|
+
class="object-cover w-full h-full"
|
|
25
|
+
:src="theImage.src.url"
|
|
26
|
+
:width="theImage.src.width"
|
|
27
|
+
:height="theImage.src.height"
|
|
28
|
+
alt=""
|
|
29
|
+
/>
|
|
30
|
+
</picture>
|
|
31
|
+
</div>
|
|
32
|
+
<div class="lg:flex lg:items-end lg:relative lg:h-full absolute bottom-0 z-20 w-full">
|
|
33
|
+
<div
|
|
34
|
+
class="bg-gradient-to-b lg:bg-gradient-to-bl from-transparent lg:from-transparent-w50 to-black lg:to-transparent-black-75 absolute inset-0"
|
|
35
|
+
></div>
|
|
36
|
+
<div
|
|
37
|
+
v-if="feature"
|
|
38
|
+
class="lg:px-10 2xl:px-0 lg:pb-0 lg:py-0 text-contrast container relative px-4 pt-40 pb-2 mx-auto mb-10 text-white"
|
|
39
|
+
>
|
|
40
|
+
<nuxt-link
|
|
41
|
+
:to="feature.url"
|
|
42
|
+
class="lg:w-1/2 xl:w-5/12 block"
|
|
43
|
+
>
|
|
44
|
+
<div
|
|
45
|
+
v-if="customTag || customLabel || feature.label"
|
|
46
|
+
class="flex items-center lg:mb-3 mb-2"
|
|
47
|
+
>
|
|
48
|
+
<BaseTag
|
|
49
|
+
v-if="customTag"
|
|
50
|
+
variant="primary"
|
|
51
|
+
size="sm"
|
|
52
|
+
class="mr-3"
|
|
53
|
+
>{{ customTag }}</BaseTag
|
|
54
|
+
>
|
|
55
|
+
<p
|
|
56
|
+
v-if="customLabel || feature.label"
|
|
57
|
+
class="text-subtitle"
|
|
58
|
+
>
|
|
59
|
+
{{ customLabel || feature.label }}
|
|
60
|
+
<span class="sr-only">.</span>
|
|
61
|
+
</p>
|
|
62
|
+
</div>
|
|
63
|
+
<p class="text-h3 font-semibold mb-0">
|
|
64
|
+
<span class="mr-2">{{ feature.title }}</span>
|
|
65
|
+
<span
|
|
66
|
+
class="text-jpl-red-light lg:hidden can-hover:group-hover:ml-2 ml-0 text-4xl transition-all duration-200 ease-in"
|
|
67
|
+
>
|
|
68
|
+
<IconArrow class="inline" />
|
|
69
|
+
</span>
|
|
70
|
+
</p>
|
|
71
|
+
</nuxt-link>
|
|
72
|
+
<BaseLink
|
|
73
|
+
:to="feature.url"
|
|
74
|
+
class="lg:block hidden"
|
|
75
|
+
link-class="inline-block"
|
|
76
|
+
caret-wrapper-class="py-3"
|
|
77
|
+
variant="primary"
|
|
78
|
+
>
|
|
79
|
+
{{ cta }}
|
|
80
|
+
</BaseLink>
|
|
81
|
+
</div>
|
|
82
|
+
</div>
|
|
83
|
+
</section>
|
|
84
|
+
</template>
|
|
85
|
+
<script lang="ts">
|
|
86
|
+
// HeroMedium
|
|
87
|
+
// A hero image with article link overlay
|
|
88
|
+
// For use when the hero includes a featured content item with link
|
|
89
|
+
// note: This component is very similar to a HomepageCarousel slide
|
|
90
|
+
import { defineComponent } from 'vue'
|
|
91
|
+
import { mixinTransparentHeader } from '../../utils/mixins'
|
|
92
|
+
import type { ImageObject } from '../../interfaces'
|
|
93
|
+
import IconArrow from './../Icons/IconArrow.vue'
|
|
94
|
+
import BaseLink from './../BaseLink/BaseLink.vue'
|
|
95
|
+
import BaseTag from './../BaseTag/BaseTag.vue'
|
|
96
|
+
import MixinVideoBg from './../MixinVideoBg/MixinVideoBg.vue'
|
|
97
|
+
|
|
98
|
+
export default defineComponent({
|
|
99
|
+
name: 'HeroMedium',
|
|
100
|
+
components: {
|
|
101
|
+
IconArrow,
|
|
102
|
+
BaseLink,
|
|
103
|
+
MixinVideoBg
|
|
104
|
+
},
|
|
105
|
+
props: {
|
|
106
|
+
feature: {
|
|
107
|
+
type: Object,
|
|
108
|
+
required: false
|
|
109
|
+
},
|
|
110
|
+
customTag: {
|
|
111
|
+
type: String,
|
|
112
|
+
required: false
|
|
113
|
+
},
|
|
114
|
+
customLabel: {
|
|
115
|
+
type: String,
|
|
116
|
+
required: false
|
|
117
|
+
},
|
|
118
|
+
cta: {
|
|
119
|
+
type: String,
|
|
120
|
+
default: 'View'
|
|
121
|
+
},
|
|
122
|
+
// to override media
|
|
123
|
+
// use-case: news detail pages use this b/c their feature hero is structured differently
|
|
124
|
+
customVideo: {
|
|
125
|
+
type: Object,
|
|
126
|
+
required: false
|
|
127
|
+
},
|
|
128
|
+
customImage: {
|
|
129
|
+
type: Object,
|
|
130
|
+
required: false
|
|
131
|
+
}
|
|
132
|
+
},
|
|
133
|
+
computed: {
|
|
134
|
+
theVideo(): object | null {
|
|
135
|
+
if (this.customVideo) {
|
|
136
|
+
return this.customVideo
|
|
137
|
+
} else if (this.feature?.video?.file) {
|
|
138
|
+
return this.feature.video
|
|
139
|
+
}
|
|
140
|
+
return null
|
|
141
|
+
},
|
|
142
|
+
theImage(): Partial<ImageObject> | null {
|
|
143
|
+
if (this.customImage) {
|
|
144
|
+
return this.customImage
|
|
145
|
+
} else if (this.feature?.image?.src) {
|
|
146
|
+
return this.feature.image
|
|
147
|
+
}
|
|
148
|
+
return null
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
watch: {
|
|
152
|
+
// watch queries to reset the header in case user navigation only changes params
|
|
153
|
+
'$route.query': {
|
|
154
|
+
handler() {
|
|
155
|
+
mixinTransparentHeader()
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
},
|
|
159
|
+
mounted() {
|
|
160
|
+
mixinTransparentHeader()
|
|
161
|
+
}
|
|
162
|
+
})
|
|
163
|
+
</script>
|
|
164
|
+
<style lang="scss">
|
|
165
|
+
@import '@explorer-1/common/src/scss/components/HeroMedium';
|
|
166
|
+
</style>
|