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

@riil-frontend/component-column-config-cache

v1.0.4-alpha.1

Published

intro component

Downloads

34

Readme

列配置器(远程缓存)

column-config-cache

用于 Table 的列配置器

注意 maxSelectCount,minSelectCount 暂时不支持同时使用

API

| 参数名 | 说明 | 必填 | 类型 | 默认值 | 备注 | | -------------- | --------------------------------------------- | ---- | ------------------- | ------ | ------------------------------------------------------------------------ | | columns | 列配置数据(table columns 的数据格式) | 是 | Array | - | ‘重置’操作的默认数据的来源,且不能通过 onChange 修改 | | onChange | columns 更新后回调 | - | Function | (columns:Array) => {} | 点击‘确定’和修改 columns 均会触发 | | isLocal | 是否仅启用本地列设置 | - | Boolean | false | 不开启远程缓存功能 | | tableKey | 表格唯一标识 | - | String | - | 用于区分同一路径(pathname)下的多个表格,建议尽量填写 | | request | ice 中请求方法实例 | 是 | Function | - | 默认取完整的 response 返回值 | | responseInterceptors | request 返回值拦截器 | - | Function | - | 兼容不同全局拦截器场景,需返回 result | | hasHide | onChange 中是否回传隐藏列 | - | Boolean | false | 默认接管表格的显隐功能;设置为 true 时需自行处理隐藏逻辑,且需将 hidden 等自定义字段过滤掉 | | userId | 当前用户 id | - | String | - | 为空则自动通过 checkToken 接口获取 | | maxSelectCount | 最大选择个数,不能和 minSelectCount 同时使用 | - | Number | - | 最多可勾选几项,达到后其他项禁用勾选。启动此属性后,全选按钮将被取消 | | minSelectCount | 最少选择个数 ,不能和 maxSelectCount 同时使用 | - | Number | - | 最少可勾选几项,达到后其他项禁用取消勾选。启动此属性后,全选按钮将被取消 | | buttonProps | 透传按钮属性 | - | Object | - | 透传按钮属性 | | overlayProps | 透传 overlay 属性 | - | Object | - | 透传 overlay 属性 | | iconProps | 透传 icon 属性 | - | Object | - | 透传 icon 属性 |

column 数据

| 参数名 | 说明 | 必填 | 类型 | 默认值 | 备注 | | -------------- | ----------------- | ---- | ------- | ------ | ----------------------------------------- | | dataIndex | table 的快速取值字段 | - | String | - | 列设置中的唯一标识 | | title | table 的表头显示的内容 | - | String | - | 用于列设置的 label 展示 | | titleNode(待定) | table 的表头显示的内容 | - | ReactElement/ReactNode/Function | - | 回传时将覆盖 title | | hidden | 默认隐藏/显示该列 | - | Boolean | false | | | hiddenDisabled | 禁用该列的隐藏/显示操作 | - | Boolean | false | | | fixedIndex | 固定位置,不参与列设置 | - | Number | - | 忽略该列,并在返回时根据从大到小的顺序,正数插入头部,非正数插入尾部 |

todo

  • maxSelectCount,minSelectCount 优化