Skip to content

Tree view

Sanya Boriskin edited this page Aug 5, 2019 · 11 revisions

Components

  • va-tree-root
  • va-tree-category
  • va-tree-node

Here's the general example:

  <va-tree-root>
      <va-tree-category label="Electronics">
        <va-tree-node>Cellphones</va-tree-node>
      </va-tree-category>
      <va-tree-category isOpen label="Products">
        <va-tree-category label="Cables">
          <va-tree-node>Audio</va-tree-node>
          <!-- va-tree-node items -->
        </va-tree-category>
        <va-tree-node>Monitors</va-tree-node>
      </va-tree-category>
      <!-- va-tree-category items -->
    </va-tree-root>

va-tree-root

No props

va-tree-category

Props

  • label - String, Number - label of the category
  • isOpen - Boolean - default state of category
  • icon - String - set a icon before the label

va-tree-node

Props

  • hightlighted - Boolean - highlight the label of node
  • icon - String - name of icon at the left of node
  • iconRight - String - name of icon at the right of node

Slots

  • Components va-tree-category, va-tree-node
  • checkbox

Find DEMOs here!

Clone this wiki locally