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

@sibat-gs/gs-table

v1.4.2

Published

table滚动条自定义

Downloads

5

Readme

gs-table

@Date 202102231458 version 1.4.2
fixed: 修复高度字符串相加问题
@Date 202101281634 version 1.4.1
fixed: 修复样式
@Date 202101251733 version 1.4.0
feat: 新增no-data展示
@Date 202001181834 version 1.3.2
fixed: 修复header因为不同浏览器计算小数点加减一像素问题, 把thead都设置固定的整数theadHeight
@Date 09-15 version 1.3.1
# 修复行滑动样式
使用实例
<GsTable class="default-table data-join-table" :colData="colData" :data="results" ref="data-join-table" :height="tableHeight">
    <template v-slot:td-0="{i}">
        {{$getIndex(i, page, pageSize)}}
    </template>
    <template v-slot:td-1="{item}">
        {{item.dataSourceName}}
    </template>
    <template v-slot:td-2="{item}">
        <i :class="['icon-input-type', `icon-input-type-${formatInputType(item.inputType)}`]"></i>
        <span class="input-type">{{item.inputType}}</span>
    </template>
    <template v-slot:td-3="{item}">
        {{item.dataOrigin}}
    </template>
    <template v-slot:td-4="{item}">
        <i :class="['icon-task-status', `icon-task-status-${item.dataSyncTaskStatus}`]"></i>
        <span class="task-status-text">{{$taskStatusToText(item.dataSyncTaskStatus)}}</span>
    </template>
    <template v-slot:td-5="{item}">
        {{item.dataCountOfRecent1Hour}}
    </template>
    <template v-slot:td-6="{item}">
        <span  v-if="item.destTableTagNames && item.destTableTagNames.length" class="dest-tags" :title="item.destTableTagNames.join('; ')">{{item.destTableTagNames.join('; ')}}</span>
        <span  v-else></span>
    </template>
    <template v-slot:td-7="{item}">
        {{item.createTime}}
    </template>
    <template v-slot:td-8="{item, i}">
        <span class="view-btn" @click.stop="handleView(item, i)">查看</span>
    </template>
</GsTable>

// colData
colData: [
    {
        th: '序号',
        width: 100,
        fixed: 'left',
    },
    {
        th: '数据源名称',
        key: 'dataSourceName',
        isSortable: true,
    },
    {
        th: '接入类型',
        key: 'inputType',
        isSortable: true,

    },
    {
        th: '数据来源',
        key: 'dataOrigin',
        isSortable: true,

    },
    {
        th: '任务状态',
        key: 'dataSyncTaskStatus',
        isSortable: true,
    },
    {
        th: '最近1h数据量(万条)',
        key: 'dataCountOfRecent1Hour',
        isSortable: true,
    },
    {
        th: '标签',
        key: 'destTableTagNames',
        isSortable: true,
    },
    {
        th: '创建时间',
        key: 'createTime',
        isSortable: true
    },
    {
        th: '操作',
        width: 100,
        fixed: 'right'
    },
],

props
|name    | 类型    | 是否必须          |   备注            |
|data    | Array   |  是              |    数据           |
|colData | Array   |  是               |   表头列数据定义  |
|height  | Number  |  是               | 表格内容高度      |
|multiple | Boolean | 否                | 是否多选        |

// 事件
// checkChange(checks, checkAll);

update

v1.3.0


修复bug