SubComponents

Page

The following components extend the native <div>arrow-up-right API. That's why the className prop is not included in the tables.

Props
Type
Required

children

ReactNode

βœ…

chevron-rightchildrenhashtag

This subcomponent will always receive the following subcomponents:

  • PageContent

  • PageContentFooter

  • PageHeader

  • PageHeaderActions

  • PageHeaderNavigation

  • PageHeaderNavigationButton

PageContent

Props
Type
Required

children

ReactNode

βœ…

hasPadding

boolean

❌

chevron-rightchildrenhashtag

The content that is shown. This subcomponent receives an structure to render, and as a footer, the following subcomponent as children:

  • PageContentFooter

chevron-righthasPaddinghashtag

To add/remove the default padding.

PageContentFooter

Props
Type
Required

children

ReactNode

βœ…

chevron-rightchildrenhashtag

The footer of the page content.

Props
Type
Required

children

ReactNode

βœ…

chevron-rightchildrenhashtag

This subcomponent will always receive the following subcomponents:

  • PageHeaderTitle

  • PageHeaderNavigation

  • PageHeaderActions

PageHeaderActions

Props
Type
Required

children

ReactNode

βœ…

chevron-rightchildrenhashtag

Normally call to action elements passed as child.

PageHeaderNavigation

Props
Type
Required

children

ReactNode

βœ…

chevron-rightchildrenhashtag

Used to navigate trough the page.

PageHeaderNavigationButton

This subcomponent extends the SDS Button API. Always a 'ghost' button.

PageHeaderTitle

Props
Type
Required

children

ReactNode

βœ…

chevron-rightchildrenhashtag

A node passed to render a title.

Props
Type
Required

children

ReactNode

βœ…

chevron-rightchildrenhashtag

This subcomponent receives the following subcomponents as child:

  • SidebarHeader

  • SidebarContent

SidebarContent

chevron-rightchildrenhashtag

Used to render content inside the sidebar.

SidebarContentDivider

Just to add a divider in the Sidebar. Extend the 'div' props.

SidebarContentGroup

Props
Type
Required

children

ReactNode

βœ…

variant

'static' | 'accordion'

❌

heading

string

❌

defaultExpanded

boolean

❌

isExpanded

boolean

❌

onClick

(e: React.MouseEvent) => void;

❌

chevron-rightchildrenhashtag

To create a group inside the sidebarcontent.

chevron-rightvarianthashtag

To change the behavior of the ContentGroup. If static, it's always expanded.

chevron-rightheadinghashtag

To pass a title.

chevron-rightdefaultExpanded and isExpandedhashtag

The default expanded prop is used when having an uncontrolled approach. The isExpanded prop is used when using a controlled approach.

chevron-rightonClickhashtag

Mainly used to change the state, when clicked, and updating the isExpanded prop.

SidebarContentGroupActions

Props
Type
Required

children

ReactNode

βœ…

chevron-rightchildrenhashtag

To add actions to a group inside the sidebarcontent.

SidebarContentGroupActionsButton

This subcomponent extends the SDS Button API. Always a 'ghost' button. Should be used inside a SidebarContentGroupActions. It is not required to use this button, but recommended. iconOnly variant used.

Props
Type
Required

SidebarContentGroupItem

Props
Type
Required

children

ReactNode

βœ…

avatar

string

❌

avatarProfilePic

string

❌

isLoading

boolean

❌

isActive

boolean

❌

notification

string

❌

notificationColor

| 'neutral' | 'inverted' | 'blue' | 'green' | 'yellow' | 'red' | 'indigo' | 'purple' | 'lime' | 'teal' | 'orange' | 'pink';

❌

collapseSidebarOnMobile

() => void

❌

chevron-rightchildrenhashtag

To create an item inside a group.

chevron-righticonhashtag

To render a custom icon, right next to the string passed.

chevron-rightavatarhashtag

To load an avatar instead of an icon.

chevron-rightavatarProfilePichashtag

If using an avatar, to pass a profile picture.

chevron-rightisLoading and isActivehashtag

The isLoading prop, overrides the icon, to a loading icon. The isActive prop, should be use in a controlled way, normally.

chevron-rightnotificationhashtag

To add a notification badge.

chevron-rightnotificationColorhashtag

To add a notification badge color.

chevron-rightcollapseSidebarOnMobilehashtag

Method executed when using a mobile resolution (below 767px).

SidebarHeader

Props
Type
Required

children

ReactNode

βœ…

chevron-rightchildrenhashtag

Used to render a header inside the sidebar.

TabBar

Props
Type
Required

children

ReactNode

βœ…

chevron-rightchildrenhashtag

To render the tabbar.

TabBarItem

Props
Type
Required

notifcation

string

❌

notificationColor

| 'neutral' | 'inverted' | 'blue' | 'green' | 'yellow' | 'red' | 'indigo' | 'purple' | 'lime' | 'teal' | 'orange' | 'pink';

❌

isActive

boolean

❌

chevron-righticonhashtag

To pass a custom icon.

chevron-rightisActivehashtag

The isActive prop, should be use in a controlled way, normally, to set an active state..

chevron-rightnotificationhashtag

To add a notification badge.

chevron-rightnotificationColorhashtag

To add a notification badge color.

Last updated