diff --git a/apps/web/layouts/organization/standalone/components/Header.tsx b/apps/web/layouts/organization/standalone/components/Header.tsx index 919361d42d5f..0ec899b9ea58 100644 --- a/apps/web/layouts/organization/standalone/components/Header.tsx +++ b/apps/web/layouts/organization/standalone/components/Header.tsx @@ -2,8 +2,17 @@ import { useEffect, useState } from 'react' import { useWindowSize } from 'react-use' import cn from 'classnames' -import { ResponsiveSpace, Text, TextProps } from '@island.is/island-ui/core' +import { + Box, + Hidden, + ResponsiveSpace, + Stack, + Text, + TextProps, +} from '@island.is/island-ui/core' import { theme } from '@island.is/island-ui/theme' +import { SearchInput } from '@island.is/web/components' +import { useI18n } from '@island.is/web/i18n' import * as styles from './Header.css' @@ -21,6 +30,7 @@ export interface HeaderProps { imageObjectPosition?: 'left' | 'center' | 'right' className?: string isFrontpage?: boolean + organizationSlug?: string } export const Header: React.FC> = ({ @@ -36,8 +46,10 @@ export const Header: React.FC> = ({ imageObjectPosition = 'center', className, isFrontpage = false, + organizationSlug, }) => { const { width } = useWindowSize() + const { activeLocale } = useI18n() const imageProvided = !!image const [isMobile, setIsMobile] = useState(false) @@ -46,50 +58,64 @@ export const Header: React.FC> = ({ setIsMobile(width < theme.breakpoints.lg) }, [width]) return ( -
+
- {underTitle && isFrontpage && ( -
- - {underTitle} - -
+
+ {underTitle && isFrontpage && ( +
+ + {underTitle} + +
+ )} +
+ {imageProvided && isFrontpage && ( + )}
- {imageProvided && isFrontpage && ( - - )}
-
+ {isFrontpage && ( + + + + + + )} + ) } diff --git a/apps/web/layouts/organization/standalone/standalone.tsx b/apps/web/layouts/organization/standalone/standalone.tsx index e170c447de52..0546ad67422a 100644 --- a/apps/web/layouts/organization/standalone/standalone.tsx +++ b/apps/web/layouts/organization/standalone/standalone.tsx @@ -67,6 +67,7 @@ export const StandaloneLayout = ({ mobileBackground: organizationPage?.themeProperties.mobileBackgroundColor, isFrontpage: isFrontpage, underTitle: bannerTitle, + organizationSlug: organizationPage?.organization?.slug ?? '', } const { activeLocale } = useI18n()