Header

    Introduction

    Header structure is a template that explains the areas in the header and how it work which helps combine other components to create a consistent user experience.

    Default

    Header structure
    1. Container: Using container to wrap header contents and grid system to set fix-width or full-width header.
    2. Logo: Using this area for logo of the site.
    3. Main content wrapper: Used to wrap all the header contents, except logo. This part is also replaced by a hamburger button on mobile.
    4. Right: Often used to present icons, CTA buttons or components about users' account.
    5. Left: Often used to display top menu of the site.

    Absolute

    Header structure
    1. Container: Using container to wrap header contents and grid system to set fix-width or full-width header.
    2. Logo: Using this area for logo of the site.
    3. Main content wrapper: Used to wrap all the header contents, except logo. This part is also replaced by a hamburger button on mobile.
    4. Right: Often used to present icons, CTA buttons or components about users' account.
    5. Absolute center-aligned objects: Using this area to display the components which are always center-aligned such as a countdown or session remaining component in workspace.

    Examples

    Desktop layout

    Note: Only "LEFT" area or "CENTER" area is shown up at a time.

    Mobile layout

    Examples

    API

    Header

    import { Header } from  '@ahaui/react'Copy import code for the Header component
    NameTypeDefaultDescription
    show
    boolean
    true

    Whether or not the Header is visible.

    innerClassName
    string

    Custom className for Inner

    HeaderMobile.HeaderContext

    import { HeaderMobile } from  '@ahaui/react'Copy import code for the HeaderMobile component
    NameTypeDefaultDescription
    classNameToggle
    string

    HeaderMobile

    import { HeaderMobile } from  '@ahaui/react'Copy import code for the HeaderMobile component
    NameTypeDefaultDescription
    show
    boolean
    true

    Whether or not the Header is visible.

    hasDropContext
    boolean

    Define has DropContext

    onToggle
    function

    A callback fired when the HeaderMobile wishes to change visibility. Called with the requested show value, the DOM event.

    Powered by Got It, Inc.Slack