@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,116 @@
|
|
|
1
|
+
import TopicDetailMoreItem from './TopicDetailMoreItem.vue'
|
|
2
|
+
export default {
|
|
3
|
+
title: 'WWW/TopicDetail/TopicDetailMore/TopicDetailMoreItem',
|
|
4
|
+
component: TopicDetailMoreItem,
|
|
5
|
+
decorators: [
|
|
6
|
+
() => ({
|
|
7
|
+
template: `<div id="storyDecorator" class="lg:w-1/3"><story/></div>`
|
|
8
|
+
})
|
|
9
|
+
],
|
|
10
|
+
parameters: {
|
|
11
|
+
html: {
|
|
12
|
+
root: '#storyDecorator'
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
excludeStories: /.*Data$/
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
const TopicDetailMoreItemData = {
|
|
19
|
+
default: {
|
|
20
|
+
__typename: 'ImageDetailPage',
|
|
21
|
+
type: 'ImageDetailPage',
|
|
22
|
+
url: '/images/placeholder/',
|
|
23
|
+
title: 'An Image Detail Page',
|
|
24
|
+
date: '2020-11-12T23:56:46.346940+00:00',
|
|
25
|
+
label: 'Image',
|
|
26
|
+
thumbnailImage: {
|
|
27
|
+
src: {
|
|
28
|
+
width: '600',
|
|
29
|
+
height: '400',
|
|
30
|
+
url: 'https://picsum.photos/600/400'
|
|
31
|
+
},
|
|
32
|
+
srcSet: 'https://picsum.photos/600/400 320w, https://picsum.photos/600/400 600w,'
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
pageChooser: {
|
|
36
|
+
__typename: 'PageChooserBlock',
|
|
37
|
+
type: 'PageChooserBlock',
|
|
38
|
+
page: {
|
|
39
|
+
label: 'Mission',
|
|
40
|
+
thumbnailImage: {
|
|
41
|
+
src: {
|
|
42
|
+
width: '600',
|
|
43
|
+
height: '400',
|
|
44
|
+
url: 'https://picsum.photos/600/400'
|
|
45
|
+
},
|
|
46
|
+
srcSet: 'https://picsum.photos/600/400 320w, https://picsum.photos/600/400 600w,'
|
|
47
|
+
},
|
|
48
|
+
title: 'Autonomous Sciencecraft Experiment',
|
|
49
|
+
url: '/missions/autonomous-sciencecraft-experiment-ase/'
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
externalLink: {
|
|
53
|
+
__typename: 'ExternalLinkCard',
|
|
54
|
+
type: 'ExternalLinkCard',
|
|
55
|
+
date: '2020-11-03',
|
|
56
|
+
title: 'Title for Link Card',
|
|
57
|
+
url: 'https://nasa.gov',
|
|
58
|
+
label: 'Link Label',
|
|
59
|
+
thumbnailImage: {
|
|
60
|
+
src: {
|
|
61
|
+
width: '600',
|
|
62
|
+
height: '400',
|
|
63
|
+
url: 'https://picsum.photos/600/400'
|
|
64
|
+
},
|
|
65
|
+
srcSet: 'https://picsum.photos/600/400 320w, https://picsum.photos/600/400 600w,'
|
|
66
|
+
}
|
|
67
|
+
},
|
|
68
|
+
video: {
|
|
69
|
+
__typename: 'VideoDetailPage',
|
|
70
|
+
type: 'VideoDetailPage',
|
|
71
|
+
url: '/video/placeholder/',
|
|
72
|
+
title: 'A Video Detail Page',
|
|
73
|
+
date: '2020-11-12T23:56:46.346940+00:00',
|
|
74
|
+
label: 'Video',
|
|
75
|
+
thumbnailImage: {
|
|
76
|
+
src: {
|
|
77
|
+
width: '600',
|
|
78
|
+
height: '400',
|
|
79
|
+
url: 'https://picsum.photos/600/400'
|
|
80
|
+
},
|
|
81
|
+
srcSet: 'https://picsum.photos/600/400 320w, https://picsum.photos/600/400 600w,'
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
// stories
|
|
87
|
+
export const Default = {
|
|
88
|
+
args: {
|
|
89
|
+
data: TopicDetailMoreItemData.default
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
export const PageChooser = {
|
|
93
|
+
args: {
|
|
94
|
+
data: TopicDetailMoreItemData.pageChooser
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
export const ExternalLink = {
|
|
98
|
+
args: {
|
|
99
|
+
data: TopicDetailMoreItemData.externalLink
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
export const Video = {
|
|
104
|
+
args: {
|
|
105
|
+
data: TopicDetailMoreItemData.video
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
export const NoImage = {
|
|
110
|
+
args: {
|
|
111
|
+
data: {
|
|
112
|
+
...TopicDetailMoreItemData.externalLink,
|
|
113
|
+
thumbnailImage: null
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
}
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<BaseLink
|
|
3
|
+
v-if="theData"
|
|
4
|
+
class="TopicDetailMoreItem group can-hover:hover:shadow-lg shadow-jpl transition-all duration-200 ease-in"
|
|
5
|
+
variant="none"
|
|
6
|
+
:link-class="theData.thumbnailImage ? 'block' : 'flex items-center block lg:min-h-100'"
|
|
7
|
+
:to="theData.__typename !== 'ExternalLinkCard' ? theData.url : undefined"
|
|
8
|
+
:href="theData.__typename === 'ExternalLinkCard' ? theData.url : undefined"
|
|
9
|
+
external-target-blank
|
|
10
|
+
>
|
|
11
|
+
<div
|
|
12
|
+
v-if="theData.thumbnailImage"
|
|
13
|
+
class="relative"
|
|
14
|
+
>
|
|
15
|
+
<!-- icon for media -->
|
|
16
|
+
<div
|
|
17
|
+
v-if="theData.__typename === 'VideoDetailPage'"
|
|
18
|
+
class="bg-jpl-red lg:text-2xl absolute bottom-0 left-0 z-10 text-lg text-white"
|
|
19
|
+
>
|
|
20
|
+
<IconPlay />
|
|
21
|
+
</div>
|
|
22
|
+
<!-- image -->
|
|
23
|
+
<BaseImagePlaceholder
|
|
24
|
+
aspect-ratio="3:2"
|
|
25
|
+
dark-mode
|
|
26
|
+
>
|
|
27
|
+
<BaseImage
|
|
28
|
+
v-if="theData.thumbnailImage.src"
|
|
29
|
+
:src="theData.thumbnailImage.src.url"
|
|
30
|
+
:srcset="theData.thumbnailImage.srcSet"
|
|
31
|
+
:width="theData.thumbnailImage.src.width"
|
|
32
|
+
:height="theData.thumbnailImage.src.height"
|
|
33
|
+
alt=""
|
|
34
|
+
object-fit-class="cover"
|
|
35
|
+
loading="lazy"
|
|
36
|
+
image-class="can-hover:group-hover:scale-100 scale-103 transition-all duration-200 ease-in transform"
|
|
37
|
+
/>
|
|
38
|
+
</BaseImagePlaceholder>
|
|
39
|
+
</div>
|
|
40
|
+
<div class="text-gray-dark md:px-5 md:py-5 lg:px-10 lg:py-8 w-full px-10 py-8">
|
|
41
|
+
<!-- label area -->
|
|
42
|
+
<div
|
|
43
|
+
v-if="theData.label || theData.date || theData.startDate"
|
|
44
|
+
class="flex flex-wrap items-center justify-between mb-5"
|
|
45
|
+
>
|
|
46
|
+
<p class="divide-gray-mid text-subtitle flex divide-x">
|
|
47
|
+
<span
|
|
48
|
+
v-if="theData.label"
|
|
49
|
+
class="pr-2"
|
|
50
|
+
>{{ theData.label }}</span
|
|
51
|
+
>
|
|
52
|
+
<span
|
|
53
|
+
v-if="theData.date || theData.startDate"
|
|
54
|
+
class="text-gray-mid-dark"
|
|
55
|
+
:class="{ 'pl-2': theData.label }"
|
|
56
|
+
>
|
|
57
|
+
<template v-if="theData.date">
|
|
58
|
+
{{
|
|
59
|
+
// @ts-ignore
|
|
60
|
+
$filters.displayDate(theData.date)
|
|
61
|
+
}}
|
|
62
|
+
</template>
|
|
63
|
+
<template v-else-if="theData.startDate">
|
|
64
|
+
{{ formattedEventDates }}
|
|
65
|
+
</template>
|
|
66
|
+
</span>
|
|
67
|
+
<span class="sr-only">.</span>
|
|
68
|
+
</p>
|
|
69
|
+
<IconExternal
|
|
70
|
+
v-if="theData.__typename === 'ExternalLinkCard'"
|
|
71
|
+
class="text-gray-mid-dark text-lg"
|
|
72
|
+
/>
|
|
73
|
+
</div>
|
|
74
|
+
|
|
75
|
+
<!-- title -->
|
|
76
|
+
<h3 class="text-h5">{{ theData.title }}</h3>
|
|
77
|
+
</div>
|
|
78
|
+
</BaseLink>
|
|
79
|
+
</template>
|
|
80
|
+
<script lang="ts">
|
|
81
|
+
import { defineComponent } from 'vue'
|
|
82
|
+
import type { PropType } from 'vue'
|
|
83
|
+
import type { Card } from '../../interfaces'
|
|
84
|
+
import { mixinFormatEventDates } from '../../utils/mixins'
|
|
85
|
+
import BaseLink from './../BaseLink/BaseLink.vue'
|
|
86
|
+
import BaseImage from './../BaseImage/BaseImage.vue'
|
|
87
|
+
import BaseImagePlaceholder from './../BaseImagePlaceholder/BaseImagePlaceholder.vue'
|
|
88
|
+
import IconPlay from './../Icons/IconPlay.vue'
|
|
89
|
+
import IconExternal from './../Icons/IconExternal.vue'
|
|
90
|
+
|
|
91
|
+
export default defineComponent({
|
|
92
|
+
name: 'TopicDetailMoreItem',
|
|
93
|
+
components: {
|
|
94
|
+
BaseLink,
|
|
95
|
+
BaseImage,
|
|
96
|
+
BaseImagePlaceholder,
|
|
97
|
+
IconPlay,
|
|
98
|
+
IconExternal
|
|
99
|
+
},
|
|
100
|
+
props: {
|
|
101
|
+
data: {
|
|
102
|
+
type: Object as PropType<Card>,
|
|
103
|
+
required: false
|
|
104
|
+
}
|
|
105
|
+
},
|
|
106
|
+
computed: {
|
|
107
|
+
theData(): Card | undefined {
|
|
108
|
+
if ((this.data as Card)?.page) {
|
|
109
|
+
return (this.data as Card).page
|
|
110
|
+
} else if (this.data) {
|
|
111
|
+
return this.data
|
|
112
|
+
}
|
|
113
|
+
return undefined
|
|
114
|
+
},
|
|
115
|
+
formattedEventDates() {
|
|
116
|
+
if (this.theData?.startDate) {
|
|
117
|
+
return mixinFormatEventDates(this.theData.startDate, this.theData.endDate)
|
|
118
|
+
}
|
|
119
|
+
return undefined
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
})
|
|
123
|
+
</script>
|
|
124
|
+
<style lang="scss">
|
|
125
|
+
.TopicDetailMoreItem {
|
|
126
|
+
.text-subtitle.divide-x {
|
|
127
|
+
@apply leading-none #{!important};
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
</style>
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { BlockImageGalleryData } from './../BlockImageGallery/BlockImageGallery.stories'
|
|
2
|
+
import { BlockQuoteData } from './../BlockQuote/BlockQuote.stories'
|
|
3
|
+
import { BlockRelatedLinksData } from './../BlockRelatedLinks/BlockRelatedLinks.stories'
|
|
4
|
+
import TopicDetailStreamfield from './TopicDetailStreamfield.vue'
|
|
5
|
+
|
|
6
|
+
export default {
|
|
7
|
+
title: 'WWW/TopicDetail/TopicDetailStreamfield',
|
|
8
|
+
component: TopicDetailStreamfield,
|
|
9
|
+
decorators: [
|
|
10
|
+
() => ({
|
|
11
|
+
template: `<div id="storyDecorator" class="absolute inset-0"><story/></div>`
|
|
12
|
+
})
|
|
13
|
+
],
|
|
14
|
+
parameters: {
|
|
15
|
+
html: {
|
|
16
|
+
root: '#storyDecorator'
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
excludeStories: /.*(Data)$/
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export const TopicDetailStreamfieldData = {
|
|
23
|
+
body: [
|
|
24
|
+
{
|
|
25
|
+
blockType: 'HeadingBlock',
|
|
26
|
+
heading: 'Heading Text'
|
|
27
|
+
},
|
|
28
|
+
BlockImageGalleryData.block,
|
|
29
|
+
BlockQuoteData,
|
|
30
|
+
BlockRelatedLinksData.data
|
|
31
|
+
]
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export const Default = { args: { data: TopicDetailStreamfieldData.body, topic: 'Topic Name' } }
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div v-if="data">
|
|
3
|
+
<template v-for="(block, index) in data">
|
|
4
|
+
<LayoutHelper
|
|
5
|
+
v-if="block.blockType == 'HeadingBlock'"
|
|
6
|
+
:key="`HeadingBlock${index}`"
|
|
7
|
+
indent="col-2"
|
|
8
|
+
>
|
|
9
|
+
<BaseHeading
|
|
10
|
+
level="h2"
|
|
11
|
+
class="lg:mt-18 mt-10 mb-5"
|
|
12
|
+
>
|
|
13
|
+
{{ block.heading }}
|
|
14
|
+
</BaseHeading>
|
|
15
|
+
</LayoutHelper>
|
|
16
|
+
<div
|
|
17
|
+
v-else-if="block.blockType == 'ImageGalleryBlock'"
|
|
18
|
+
:key="`ImageGalleryBlock${index}`"
|
|
19
|
+
class="max-w-screen-3xl lg:mb-18 mx-auto mb-10"
|
|
20
|
+
>
|
|
21
|
+
<BlockImageGallery
|
|
22
|
+
:label="topic"
|
|
23
|
+
:title="block.galleryTitle"
|
|
24
|
+
:description="block.galleryDescription"
|
|
25
|
+
:cover="block.coverImage"
|
|
26
|
+
:items="block.gallerySlides"
|
|
27
|
+
/>
|
|
28
|
+
</div>
|
|
29
|
+
|
|
30
|
+
<LayoutHelper
|
|
31
|
+
v-else-if="block.blockType == 'QuoteBlock'"
|
|
32
|
+
:key="`QuoteBlock${index}`"
|
|
33
|
+
indent="col-2"
|
|
34
|
+
class="lg:my-18 my-10"
|
|
35
|
+
>
|
|
36
|
+
<BlockQuote :data="block as unknown as BlockQuoteAttributes" />
|
|
37
|
+
</LayoutHelper>
|
|
38
|
+
<LayoutHelper
|
|
39
|
+
v-else-if="block.blockType == 'RelatedLinksBlock'"
|
|
40
|
+
:key="`RelatedLinksBlock${index}`"
|
|
41
|
+
indent="col-2"
|
|
42
|
+
class="lg:my-18 my-10"
|
|
43
|
+
>
|
|
44
|
+
<BlockRelatedLinks :data="block as any as BlockRelatedLinksObject" />
|
|
45
|
+
</LayoutHelper>
|
|
46
|
+
|
|
47
|
+
<div
|
|
48
|
+
v-else
|
|
49
|
+
:key="index"
|
|
50
|
+
class="p-3 overflow-hidden border"
|
|
51
|
+
>
|
|
52
|
+
<pre>{{ block }}</pre>
|
|
53
|
+
</div>
|
|
54
|
+
</template>
|
|
55
|
+
</div>
|
|
56
|
+
</template>
|
|
57
|
+
<script lang="ts">
|
|
58
|
+
import { defineComponent } from 'vue'
|
|
59
|
+
import type { PropType } from 'vue'
|
|
60
|
+
import type { ImageObject } from '../../interfaces'
|
|
61
|
+
import type { BlockQuoteAttributes } from './../BlockQuote/BlockQuote.vue'
|
|
62
|
+
import LayoutHelper from './../LayoutHelper/LayoutHelper.vue'
|
|
63
|
+
import BaseHeading from './../BaseHeading/BaseHeading.vue'
|
|
64
|
+
import BlockQuote from './../BlockQuote/BlockQuote.vue'
|
|
65
|
+
import BlockRelatedLinks, {
|
|
66
|
+
type BlockRelatedLinksObject
|
|
67
|
+
} from './../BlockRelatedLinks/BlockRelatedLinks.vue'
|
|
68
|
+
import BlockImageGallery from './../BlockImageGallery/BlockImageGallery.vue'
|
|
69
|
+
|
|
70
|
+
interface BlockData {
|
|
71
|
+
blockType: string
|
|
72
|
+
heading: string
|
|
73
|
+
galleryTitle: string
|
|
74
|
+
galleryDescription: string
|
|
75
|
+
coverImage: ImageObject
|
|
76
|
+
gallerySlides: ImageObject[]
|
|
77
|
+
}
|
|
78
|
+
export default defineComponent({
|
|
79
|
+
name: 'TopicDetailStreamfield',
|
|
80
|
+
components: {
|
|
81
|
+
LayoutHelper,
|
|
82
|
+
BaseHeading,
|
|
83
|
+
BlockQuote,
|
|
84
|
+
BlockRelatedLinks,
|
|
85
|
+
BlockImageGallery
|
|
86
|
+
},
|
|
87
|
+
props: {
|
|
88
|
+
data: {
|
|
89
|
+
type: Array as PropType<BlockData[]>,
|
|
90
|
+
required: false
|
|
91
|
+
},
|
|
92
|
+
topic: {
|
|
93
|
+
type: String,
|
|
94
|
+
required: false
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
})
|
|
98
|
+
</script>
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import YearTicker from './YearTicker.vue'
|
|
2
|
+
|
|
3
|
+
export default {
|
|
4
|
+
title: 'Components/YearTicker',
|
|
5
|
+
component: YearTicker,
|
|
6
|
+
excludeStories: /.*Data$/
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
// prettier-ignore
|
|
10
|
+
const demoYears = ['2019', '2018', '2017', '2016', '2015', '2014', '2013', '2012', '2011', '2006', '2005', '2004', '2002', '2000', '1998', '1997', '1995', '1993', '1991', '1990', '1989', '1986', '1983', '1979', '1978', '1975', '1974', '1971', '1966', '1965', '1964', '1963', '1962', '1959', '1958', '1956', '1947', '1944', '1943', '1939', '1936']
|
|
11
|
+
|
|
12
|
+
// templates
|
|
13
|
+
const YearTickerTemplate = (args) => ({
|
|
14
|
+
props: Object.keys(args),
|
|
15
|
+
components: { YearTicker },
|
|
16
|
+
data() {
|
|
17
|
+
return {
|
|
18
|
+
demoYear: demoYears[0]
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
mounted() {
|
|
22
|
+
window.addEventListener('mousemove', this.updateYear, { passive: true })
|
|
23
|
+
},
|
|
24
|
+
beforeDestroy() {
|
|
25
|
+
window.removeEventListener('mousemove', this.updateYear)
|
|
26
|
+
},
|
|
27
|
+
methods: {
|
|
28
|
+
updateYear(e) {
|
|
29
|
+
const index = Math.floor(e.clientY / demoYears.length)
|
|
30
|
+
this.demoYear = String(demoYears[index])
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
template: `<YearTicker :targetYear="demoYear"/>`
|
|
34
|
+
})
|
|
35
|
+
|
|
36
|
+
export const Default = YearTickerTemplate.bind({})
|
|
37
|
+
Default.storyName = 'YearTicker'
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
class="YearTicker"
|
|
4
|
+
:style="`--duration:${duration}ms`"
|
|
5
|
+
>
|
|
6
|
+
<!-- One transition group per digit. -->
|
|
7
|
+
<transition-group
|
|
8
|
+
v-for="(digit, index) in Array.from(targetYear)"
|
|
9
|
+
:key="index"
|
|
10
|
+
:name="animation"
|
|
11
|
+
:duration="duration"
|
|
12
|
+
>
|
|
13
|
+
<!-- Key by digit so there can be two digits rendered at the same time. -->
|
|
14
|
+
<span
|
|
15
|
+
:key="digit"
|
|
16
|
+
class="Digit"
|
|
17
|
+
>{{ digit }}</span
|
|
18
|
+
>
|
|
19
|
+
</transition-group>
|
|
20
|
+
</div>
|
|
21
|
+
</template>
|
|
22
|
+
<script lang="ts">
|
|
23
|
+
import { defineComponent } from 'vue'
|
|
24
|
+
|
|
25
|
+
export default defineComponent({
|
|
26
|
+
name: 'YearTicker',
|
|
27
|
+
props: {
|
|
28
|
+
targetYear: {
|
|
29
|
+
type: String,
|
|
30
|
+
required: true
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
data() {
|
|
34
|
+
return {
|
|
35
|
+
year: this.targetYear,
|
|
36
|
+
animation: 'digits-increment',
|
|
37
|
+
duration: 100
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
watch: {
|
|
41
|
+
targetYear(newYear) {
|
|
42
|
+
this.animation = this.year > newYear ? 'digits-increment' : 'digits-decrement'
|
|
43
|
+
this.year = newYear
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
})
|
|
47
|
+
</script>
|
|
48
|
+
<style lang="scss">
|
|
49
|
+
.YearTicker {
|
|
50
|
+
@apply sticky transform text-gray-light-mid translate-x-0.5 md:translate-x-0 ml-7 md:ml-8 lg:ml-30 pt-10 md:pt-5;
|
|
51
|
+
|
|
52
|
+
// Unitless 0 isn’t supported in a `calc` operation.
|
|
53
|
+
// stylelint-disable-next-line length-zero-no-unit
|
|
54
|
+
--top-offset: 0px;
|
|
55
|
+
|
|
56
|
+
font-variant-numeric: tabular-nums;
|
|
57
|
+
font-weight: 900;
|
|
58
|
+
line-height: 1;
|
|
59
|
+
font-size: min(5rem, 25vw);
|
|
60
|
+
// Secondary nav minus gap.
|
|
61
|
+
top: calc(theme('spacing.16') - 1px + var(--top-offset));
|
|
62
|
+
z-index: 50;
|
|
63
|
+
|
|
64
|
+
@screen md {
|
|
65
|
+
--top-offset: theme('spacing.20');
|
|
66
|
+
|
|
67
|
+
z-index: -20;
|
|
68
|
+
font-size: min(8rem, 20vw);
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
@screen lg {
|
|
72
|
+
font-size: min(11.25rem, 10vw);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
@screen xl {
|
|
76
|
+
font-size: min(11.25rem, 25vw);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.header-sticky-showing & {
|
|
80
|
+
// For the mobile viewport, offset by the height of the top header and NavSecondary combined.
|
|
81
|
+
top: calc(theme('spacing.18') + theme('spacing.16') + var(--top-offset));
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
&::after {
|
|
85
|
+
@apply md:hidden;
|
|
86
|
+
|
|
87
|
+
content: '';
|
|
88
|
+
position: absolute;
|
|
89
|
+
z-index: -10;
|
|
90
|
+
top: 2px;
|
|
91
|
+
left: 0;
|
|
92
|
+
width: 100%;
|
|
93
|
+
height: 140px;
|
|
94
|
+
pointer-events: none;
|
|
95
|
+
background-image: linear-gradient(to bottom, white 90%, transparent);
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
> span {
|
|
99
|
+
display: inline-grid;
|
|
100
|
+
grid-template-columns: 1fr;
|
|
101
|
+
grid-template-rows: 1fr;
|
|
102
|
+
overflow: hidden;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.Digit {
|
|
106
|
+
// Force all digits in the same cell so they superpose.
|
|
107
|
+
grid-area: 1 / 1 / 1 / 1;
|
|
108
|
+
transition: transform var(--duration);
|
|
109
|
+
transform: translateY(0);
|
|
110
|
+
|
|
111
|
+
@media (prefers-reduced-motion: reduce) {
|
|
112
|
+
transition-duration: 0.1ms;
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
// transitions
|
|
116
|
+
.digits-decrement-enter-active {
|
|
117
|
+
transform: translateY(100%);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.digits-decrement-leave-active {
|
|
121
|
+
transform: translateY(-100%);
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
.digits-increment-enter-active {
|
|
125
|
+
transform: translateY(-100%);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
.digits-increment-leave-active {
|
|
129
|
+
transform: translateY(100%);
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
</style>
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<table class="table-autotext-sm">
|
|
3
|
+
<thead>
|
|
4
|
+
<tr>
|
|
5
|
+
<th class="text-left w-1/2">Color</th>
|
|
6
|
+
<th class="text-left">Name</th>
|
|
7
|
+
<th class="text-left">Token</th>
|
|
8
|
+
</tr>
|
|
9
|
+
</thead>
|
|
10
|
+
<tbody>
|
|
11
|
+
<tr>
|
|
12
|
+
<td>
|
|
13
|
+
<div class="bg-primary-light p-4"></div>
|
|
14
|
+
</td>
|
|
15
|
+
<td>Primary light</td>
|
|
16
|
+
<td><code class="text-sm">primary-light</code></td>
|
|
17
|
+
</tr>
|
|
18
|
+
<tr>
|
|
19
|
+
<td>
|
|
20
|
+
<div class="bg-primary p-4"></div>
|
|
21
|
+
</td>
|
|
22
|
+
<td>Primary</td>
|
|
23
|
+
<td><code class="text-sm">primary</code></td>
|
|
24
|
+
</tr>
|
|
25
|
+
<tr>
|
|
26
|
+
<td>
|
|
27
|
+
<div class="bg-primary-dark p-4"></div>
|
|
28
|
+
</td>
|
|
29
|
+
<td>Primary dark</td>
|
|
30
|
+
<td><code class="text-sm">primary-dark</code></td>
|
|
31
|
+
</tr>
|
|
32
|
+
<tr>
|
|
33
|
+
<td>
|
|
34
|
+
<div class="bg-primary-darker p-4"></div>
|
|
35
|
+
</td>
|
|
36
|
+
<td>Primary darker</td>
|
|
37
|
+
<td><code class="text-sm">primary-darker</code></td>
|
|
38
|
+
</tr>
|
|
39
|
+
<tr>
|
|
40
|
+
<td>
|
|
41
|
+
<div class="bg-secondary-light p-4"></div>
|
|
42
|
+
</td>
|
|
43
|
+
<td>Secondary light</td>
|
|
44
|
+
<td><code class="text-sm">primary-light</code></td>
|
|
45
|
+
</tr>
|
|
46
|
+
<tr>
|
|
47
|
+
<td>
|
|
48
|
+
<div class="bg-secondary p-4"></div>
|
|
49
|
+
</td>
|
|
50
|
+
<td>Secondary</td>
|
|
51
|
+
<td><code class="text-sm">primary</code></td>
|
|
52
|
+
</tr>
|
|
53
|
+
<tr>
|
|
54
|
+
<td>
|
|
55
|
+
<div class="bg-secondary-dark p-4"></div>
|
|
56
|
+
</td>
|
|
57
|
+
<td>Secondary dark</td>
|
|
58
|
+
<td><code class="text-sm">primary-dark</code></td>
|
|
59
|
+
</tr>
|
|
60
|
+
<tr>
|
|
61
|
+
<td>
|
|
62
|
+
<div class="bg-secondary-darker p-4"></div>
|
|
63
|
+
</td>
|
|
64
|
+
<td>Secondary darker</td>
|
|
65
|
+
<td><code class="text-sm">primary-darker</code></td>
|
|
66
|
+
</tr>
|
|
67
|
+
<tr>
|
|
68
|
+
<td>
|
|
69
|
+
<div class="bg-action-light p-4"></div>
|
|
70
|
+
</td>
|
|
71
|
+
<td>Action light</td>
|
|
72
|
+
<td><code class="text-sm">action-light</code></td>
|
|
73
|
+
</tr>
|
|
74
|
+
<tr>
|
|
75
|
+
<td>
|
|
76
|
+
<div class="bg-action p-4"></div>
|
|
77
|
+
</td>
|
|
78
|
+
<td>Action</td>
|
|
79
|
+
<td><code class="text-sm">action</code></td>
|
|
80
|
+
</tr>
|
|
81
|
+
<tr>
|
|
82
|
+
<td>
|
|
83
|
+
<div class="bg-action-dark p-4"></div>
|
|
84
|
+
</td>
|
|
85
|
+
<td>Action dark</td>
|
|
86
|
+
<td><code class="text-sm">action-dark</code></td>
|
|
87
|
+
</tr>
|
|
88
|
+
<tr>
|
|
89
|
+
<td>
|
|
90
|
+
<div class="bg-action-darker p-4"></div>
|
|
91
|
+
</td>
|
|
92
|
+
<td>Action darker</td>
|
|
93
|
+
<td><code class="text-sm">action-darker</code></td>
|
|
94
|
+
</tr>
|
|
95
|
+
</tbody>
|
|
96
|
+
</table>
|
|
97
|
+
</template>
|
|
98
|
+
<style scoped>
|
|
99
|
+
.ThemeVariantDark table {
|
|
100
|
+
@apply text-white;
|
|
101
|
+
}
|
|
102
|
+
td,
|
|
103
|
+
th {
|
|
104
|
+
@apply px-2;
|
|
105
|
+
}
|
|
106
|
+
</style>
|