Try Install Learn Blog API Packages GitHub
Pages

Ui.Layout.Documentation

A layout component for displaying documentation.

States

tocItems
:
Array(Tuple(String, String))
=
[]

The items for the table of contents.

Properties

children
:
Array(Html)
=
[]

The content to render.

items
:
Array(Ui.NavItem)
=
[]

The items groupped by a string.

size
:
Number
=
16

The size of the component.

Functions

When the component is mounted.

getTocData
(
element
:
Dom.Element
)
:
Tuple(String, String)

Gets the table of contents data of an element.

handleChange
(
key
:
String
)

Handles the change event from the select.

handleClick
(
event
:
Html.Event
)

Handles the click event of a table of contents item.

render
:
Html

Renders the layout.

renderContents
(
iconBefore
:
Html
iconAfter
:
Html
label
:
String
)

Renders the contents of an item.

renderItem
(
item
:
Ui.NavItem
)
:
Html

Renders an item.

Updates the table of contents.