Skip to content

6g. Cell: Segment

i_82 edited this page Mar 26, 2018 · 1 revision

Segment cell is a plain cell with a UISegmentedControl called cellSegmentControl inside.

Key Type Description Flags Default
options Array <Dictionary> option dictionary list Required -

options is an array contains option dictionary:

Key Type Description Flags Default
title String option title Required, Localizable -
value Any? option value Optional the same to title

icon is not supported.

value Type Description
Any? options[cellSegmentControl.selectedSegmentIndex]["value"]

Example

{
    "default": "Green",
    "label": "List of Options",
    "cell": "Segment",
    "key": "list-segment",
    "options": [
        {
            "title": "Red"
        },
        {
            "title": "Green"
        },
        {
            "title": "Blue"
        }
    ]
}

Clone this wiki locally