npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

vuetify-data-grid

v1.1.4

Published

Front-end package for the data-grid-laravel package.

Downloads

11

Readme

Data Grid Vuetify

Data grid package used to render advanced grids with a matching back-end package.

Allows for searching, filtering, paging & some other advanced features.

Installation

You can install the package via composer:

npm install vuetify-data-grid

Please also note that a companion back-end package is required to use this package to it's fullest:

composer require fitt-tech/data-grid-laravel

Usage

In you main.js or app.js register this package as a Vue plugin.

import DataGrid from 'vuetify-data-grid';

Vue.use(DataGrid);

After registering the package the main component can be used as such.


<data-grid :data="data"></data-grid>

The data property here receives its data from the data-grid-laravel package on the back-end.

Properties

selectable

The selectable property allows for row selection by checkboxes on the data grid itself. Using this property also requires the use of the item-value property.

item-value

The item-value property is used to indicate a unique item identifier. The property is only intended for use with the seectable property.

return-object

The return-object property returns the entire item object on select instead on the associated item value from the item-value property.

actions

The actions property is used to pass actions to the actions to each data grid item row. Actions consist of an array of objects that build actions with a series of properties. these are covered below:

  • color - Sets the color of the action
  • label - Sets the action label
  • icon - Sets the icon - takes a string or callback for dynamic icons - bind(this)
  • confimation - Apply a confirmation dialog on action event using this string - more info below
  • disabled - Sets whether the action should be disabled
  • show - Evaluates if the action should be displayed, receives a callback - bind(this)
  • closure - Callback function called by the action event itself - bind(this)

The confirmation property can be used in a more advanced way to edit the look and feel of the confirmation dialog. Either pass a string for the confirmation message, or a set of options via object notation. The example below shows all available options.

confirmation: {
   title: '<title>',
      text: '<text>',
      buttons: {
      cancel: {
          text: '<cancel button text>',
          color: '<cancel button color>',
      },
      confirm: {
          text: '<confirm button text>',
          color: '<confirm button color>',
      },
   },
},

additional-actions

The aditional-actions property is used to pass additional actions to the actions drawer for the data-grid. These actions operate the same as the actions property.

hide-additional-actions

The hide-additional-actions hides the action's drawer if it is not being used.

value / v-model

The value property is used to get the current selected items on the data-grid. For auto synced values use v-model instead.

drawer

The drawer property can be used to mutate the additional actions drawer state from outside. Simply pass a data property to this property and change it as needed.

close-drawer-on-data-changes

The close-drawer-on-data-changes property can be used to force close the drawer when any data changes occur. Data changes can include but are not limited to:

  • Applying a search query
  • Applying a filter
  • Sorting data
  • Changing pages

Events

@click:row

The @click:row event can be used to enable clicking on data grid rows. The event payload will be the row item itself.