Tabview

You will find here a description of the component TabView and its attributes.

What is TabView?

A TabView is a component used to navigate between views that are listed in a tab. It displays all tabs that correspond to different previews that can be accessed through it.

The structure is represented by the attributes below:

AttributeTypeRequiredDefinition
childrenList<TabItem>List of tab items available in the TabView component. The TabItem itself is not a widget, but its content is a server driven component received through Beagle.
styleIdStringIt uses a key that is registered in the Design System of evert platform to customize your component.
contextContextDataAdd a context to your TabView component.

What is TabItem?

TabView is a component item that has this structure:

AttributeTypeRequiredDefinition
titleStringDisplays the text in a TabView item. If it is not declared or if it is configured with the null value, it will not be shown on the screen.
iconPathDisplays a local image as an icon in the TabView item. If it is not declared or if it is configured with the null value, it will not be shown on the screen.
childComponentDefines which view will be inflated in the TabItem, according to the tab clicked. Any server-driven component can be a Tab View item.

How to use it?

Screen(
  child = Container(
      children = listOf(
          TabView(children =
              listOf(
                  TabItem("Tab 1",
                      Text("First Tab Content").applyFlex(flex = Flex(grow = 1.0))
                  ),
                  TabItem("Tab 2",
                      Text("Second Tab Content").applyFlex(flex = Flex(grow = 1.0))
                  )
              )
              )
          )
      )
  )
TabView full screenTabView with dividing screen

Last modified February 12, 2021: Fix/migrate images to aws (#299) (a7bb5457)