Table

You can manage the data by adding a table with a nice and very functional style

Default

To implement a data table we have the component vs-table, also sub components and slots for a better management of the structure and operation

  • vs-th: Component
  • vs-tr: Component
  • vs-td: Component
  • thead: Slot
  • tbody: Slot
  • header: Slot

TIP

In order to manipulate the data within the table, it is necessary to add the property: data="myDataTable" and thus be able to use the v-slot="{data}"

Users

Email
Name
Website
Nro
No data Available

Striped

You can have a sebra effect by adding the property stripe

Users

Email
Name
Website
Nro
No data Available

State

There are times when we need to add a state to our tr in the table so we have the property state inside the component vs-tr

Users

Email
Name
website
Nro
No data Available

Pagination

You can add a paginated table with the pagination property

TIP

by default the maximum number of elements per page is 5 to change it using the max-items property

Users

Email
Name
Website
Nro
No data Available

Description

You can add a paginated table with description with the description property

TIP

You can change the items of the description using the description-items property, this sends an array with maximum values of items

Users

Email
Name
Website
Nro
No data Available
Registries: 0 - 0 of 11 | Pages:
  • 3 ,
  • 5 ,
  • 15

Single Selected

You can add the functionality of select a specific tr to do this add the property data with the value to be selected, it is usually the triterated

TIP

if you need to execute a certain function to select the user, we have the property @selected and @dblSelection, as the first parameter the data is returned,one with one click and the other with double click.

Users

Email
Name
Website
Nro
No data Available
[]

Multiple Selected

To select multiples tr we have the property multiple and each of the selected items will be added to the v-model

Users

remove
Email
Name
Website
Nro
No data Available
[]

Expandable Data

You can add the functionality of expanding a tr to visualize more data to make a structure of data or more complex functionalities

Users

Email
Name
Website
Nro
No data Available

Edit Data Table

You can edit the data with slot edit, so you have better flexibility and mastery of what you need

Email
Name
Nro1
Nro2
No data Available

Filter and Sorter

You can add the Filter functionality by adding the search property

if you need a property to be sorted you just have to add the sort-key property and the value you need to be sorted

TIP

You can use queriedResults property of table component to get queried results by table component.

Users

Email
Name
Nro
No data Available

Miscellaneous

You can add a filtered, sorted, paginated and multi selected table with combination of the search, multiple and pagination properties for example

Users

remove
Email
Name
Website
Nro
No data Available
[]

SST (Server-site Table)

The table stops doing its functionalities on the client side and proceeds to issue the functions that the user does to capture them and make the requests to the server's api making the change in the data

Users

Email
Name
Website
Nro
No data Available

API #

NameTypeParametersDescriptiondefault
dataArray, ObjectData that will be represented in the table.
headerslotHeader of the table.
theadslotthead of the table and where the vs-th should be added.
tbodyslottbody of the table and where the vs-tr should be added.
stripeBooleanAdd a stripes effect.false
hoverFlatBooleanChange effect hover and flat.false
maxHeightpxChange the high maximum of the table, generating the scroll.false
multipleBooleanDetermines if multiple items can be selected.false
notSpacerBooleanEliminates the space between each tr.false
searchBooleanDetermine if the filtering functionality through an input is active.false
paginationBooleanDetermine if the page is active so that only a certain number of items can be displayed.false
maxItemsNumberChange the maximum number of items that can be displayed when the page is active.5
descriptionBooleanDetermine if the description is active so that only a certain number of items can be displayed.false
description-itemsArrayMaximum elements that will be represented in the description.
description-titleStringTitle of the description.
description-connectorStringConnector of the description.
description-bodyStringBody of the description.
state (vs-tr)BooleanDetermine the state of the element with a color.
data (vs-tr)Object, Number, Array, StringDetermines the value of the element for when it is selected.
sortKey (vs-th)StringDetermine the value to be raffled and if this activates that functionality.
data (vs-td)StringThis property is required if you are going to use the edit slot.
noDataTextStringChange the text of the notification when there is no data in the table.
total (total items if sst)NumberTotal number of items if the data is being loaded through sst (server-site table)0
sst (server-site table)BooleanIt does not execute the functions of the client side like search, pagination change or sort, now the methods are executed (search, change-page and sort) to be used when making the call to the api of the server.false