Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface TabsProps<T>

Props to the Tabs component

Type parameters

  • T = undefined

    type of metadata, if present.

Hierarchy

  • TabsProps

Index

Properties

Optional active

active: ID

If specified and this id is present in children then it will be selected. In all other cases, the first tab will be selected by default.

children

children: TabData<T>[]

The specification from which the tabs are built.

Optional onMove

onMove: (toPosition: number, id: ID, metadata: T) => void

Called when a tab is dropped on this container. use removeTab to extract it from its current position and splice it into this container's children.

param

Tells you where to insert the tab

param

Refers to the dragged tab

param

Refers to the dragged tab

Type declaration

    • (toPosition: number, id: ID, metadata: T): void
    • Parameters

      • toPosition: number
      • id: ID
      • metadata: T

      Returns void

Optional onSelect

onSelect: (id: ID) => void

Called when a different tab is selected. Use this to update active if you set it explicitly.

Type declaration

    • (id: ID): void
    • Parameters

      Returns void

Generated using TypeDoc