Skip to content

ListView-DEMO


vue
<div style="width: 100%; height: 500px; padding: 15px;">
    <fv-ListView v-model="items" :showSlider="true">
    </fv-ListView>
</div>

ListView-Multiple


vue
<div style="width: 100%; height: 500px; padding: 15px;">
    <fv-ListView v-model="items" :multiple="true">
    </fv-ListView>
</div>

ListView-Dark Theme


vue
<div style="width: 100%; height: 500px; padding: 15px; background: black;">
    <fv-ListView v-model="items" theme="dark">
    </fv-ListView>
</div>

ListView-Custom Choosen Background


vue
<div style="width: 100%; height: 500px; padding: 15px; background: black;">
    <fv-ListView v-model="items" theme="dark" choosenBackground="rgba(0, 204, 153, 0.6)">
    </fv-ListView>
</div>

Properties


PropertyTypeRequiredDefaultDescription
modelValuearrayNo[]See the ListView modelValue option.
choosenarrayNo[]See the ListView choosen option.
multiplebooleanNofalseSee the ListView multiple option.
rowHeightstringNo''See the ListView rowHeight option.
headerForegroundstringNo''See the ListView headerForeground option.
choosenBackgroundstringNo''See the ListView choosenBackground option.
itemPaddingstringNo''See the ListView itemPadding option.
itemBorderRadiusnumberNo3See the ListView itemBorderRadius option.
revealBorderColorbooleanNofalseSee the ListView revealBorderColor option.
revealBackgroundColorbooleanNofalseSee the ListView revealBackgroundColor option.
showSliderbooleanNofalseSee the ListView showSlider option.
sliderTargetobjectNo() => {}See the ListView sliderTarget option.
sliderIndexnumberNo-1See the ListView sliderIndex option.
themestringNo'global'Theme style. Supports global, light, dark, system, and custom.
disabledbooleanNofalseSee the ListView disabled option.
langstringNo"global"See the ListView lang option.

Events


EventArgumentsDescription
item-clickobjectSee the component item-click option.
chooseItemobjectSee the component chooseItem option.
choosen-itemsarraySee the component choosen-items option.
selection-changeobjectSee the component selection-change option.
item-drag-over{root, drop}Emitted when the dragged item enters the current item.
item-drag-leave{root, drop}Emitted when the dragged item leaves the current item.
item-drop{root, drop}Emitted when an item is dropped on the current item.

Slots


  1. ListItem
vue
<template v-slot:listItem="x">
    <p>{{ valueTrigger(item.name) }}</p>
</template>
  1. Header
vue
<template v-slot:header>
    <p></p>
</template>
  1. Footer
vue
<template v-slot:footer>
    <p></p>
</template>

Data


  1. items
javascript
items = [{key: '', name: '', type: '', disabled: '', show: ''}]

//e.g.//

items: [
    { key: "fruitsHeader", name: "Fruits", type: "header" },
    { key: "apple", name: "Apple" },
    { key: "banana", name: "Banana" },
    { key: "orange", name: "Orange", disabled: true },
    { key: "grape", name: "Grape" },
    { key: "divider_1", name: "", type: "divider" },
    { key: "vegetablesHeader", name: "Vegetables", type: "header" },
    { key: "broccoli", name: "Broccoli" },
    { key: "carrot", name: "Carrot" },
    { key: "lettuce", name: "Lettuce" }
]

Appendix


vue
<fv-ListView v-model="items" ref="list"></fv-ListView>
let item = this.$refs.list.$refs['list_item_<index>]'];
  • event

MIT Licensed