Changeset View
Changeset View
Standalone View
Standalone View
landing/app-landing.react.js
// @flow | // @flow | ||||
import * as React from 'react'; | import * as React from 'react'; | ||||
import { assetMetaData } from './asset-meta-data.js'; | import { imageAssetMetaData } from './asset-meta-data.js'; | ||||
import HeroContent from './hero-content.react.js'; | import HeroContent from './hero-content.react.js'; | ||||
import css from './landing.css'; | import css from './landing.css'; | ||||
import Picture from './Picture.react.js'; | import Picture from './Picture.react.js'; | ||||
import usePreloadAssets from './use-pre-load-assets.react.js'; | import usePreloadImageAssets from './use-pre-load-image-assets.react.js'; | ||||
function AppLanding(): React.Node { | function AppLanding(): React.Node { | ||||
usePreloadAssets(assetMetaData); | usePreloadImageAssets(imageAssetMetaData); | ||||
const [hero] = assetMetaData; | const [hero] = imageAssetMetaData; | ||||
return ( | return ( | ||||
<main className={css.wrapper}> | <main className={css.wrapper}> | ||||
<div className={hero.imageStyle}> | <div className={hero.imageStyle}> | ||||
<Picture url={hero.url} alt={hero.alt} /> | <Picture url={hero.url} alt={hero.alt} /> | ||||
</div> | </div> | ||||
<HeroContent /> | <HeroContent /> | ||||
</main> | </main> | ||||
); | ); | ||||
} | } | ||||
export default AppLanding; | export default AppLanding; |