-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Homepage Hero Upgrade w/ Alert (#10377)
* updating hero with ecs info * updates to hero * Include back the Basic Hero styles The basic hero is still used on the use case pages * Revert the tsconfig changes Nothing in the scope of this PR requires these changes! * Remove the old Carousel CSS file This is no longer needed as we're using the @hashicorp/react-hero which comes with all the styling required for this carousel to work. * Rename ConsulHero -> HomepageHero imports/exports This will help prevent any confusion for future devs here -- this is a convention we have that helps us from having to trace every import, which helps us find the source of the component without actually having to look at the import. * Pin the deps These were previously pinned to the exact version; including ^ will allow minor & patch updates to sneak in, which normally shouldn't cause an issue but we tend to be more conservative on dep upgrades. * Revert unneeded changes to the document file * Revert changes to app.js file Not needed in the scope of this PR! * Hard pin react-alert * Remove unneeded css Co-authored-by: Brandon Romano <brandon@hashicorp.com>
- Loading branch information
1 parent
1199602
commit 50b42c1
Showing
8 changed files
with
9,419 additions
and
33,795 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
import s from './style.module.css' | ||
import Hero from '@hashicorp/react-hero' | ||
|
||
export default function HomepageHero({ | ||
title, | ||
description, | ||
links, | ||
uiVideo, | ||
cliVideo, | ||
alert, | ||
image, | ||
}) { | ||
return ( | ||
<div className={s.consulHero}> | ||
<Hero | ||
data={{ | ||
product: 'consul', | ||
alert: alert ? { ...alert, tagColor: 'consul-pink' } : null, | ||
title: title, | ||
description: description, | ||
buttons: links, | ||
backgroundTheme: 'light', | ||
centered: false, | ||
image: image ? { ...image } : null, | ||
videos: [ | ||
...(uiVideo | ||
? [ | ||
{ | ||
name: uiVideo.name ?? 'UI', | ||
playbackRate: uiVideo.playbackRate, | ||
src: [ | ||
{ | ||
srcType: uiVideo.srcType, | ||
url: uiVideo.url, | ||
}, | ||
], | ||
}, | ||
] | ||
: []), | ||
...(cliVideo | ||
? [ | ||
{ | ||
name: cliVideo.name ?? 'CLI', | ||
playbackRate: cliVideo.playbackRate, | ||
src: [ | ||
{ | ||
srcType: cliVideo.srcType, | ||
url: cliVideo.url, | ||
}, | ||
], | ||
}, | ||
] | ||
: []), | ||
], | ||
}} | ||
/> | ||
</div> | ||
) | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.