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 🙏

© 2026 – Pkg Stats / Ryan Hefner

@xsyx/hanzo-shop-cart-card

v0.3.6

Published

购物车卡片

Readme

购物车商品卡片

changelog

v0.3.6

  • 修正购物车数量是否可输入参数 editable

v0.3.5

  • 修正购物车数量控制参数 hasCheckbox

v0.3.4

  • 调整视频商品卡片样式

v0.3.3

  • 添加价格随大小更替字号样式属性

v0.3.2

  • 已结束的商品,加入购物车按钮显示商品已结束

v0.3.1

  • 预售状态下加入购物车按钮为蓝色

v0.3.0

  • 添加优视卡片样式

v0.2.7

  • 更换已结束图标Url

v0.2.6

  • 样式微调

v0.2.5

  • 库存不足样式调整

v0.2.4

  • 禁用状态背景色
  • 圆角/字体调整

v0.2.3

  • 预售文案调整

v0.2.2

  • 提示语和倒计时宽度调整

v0.2.1

  • 增加倒计时属性

v0.2.0

  • 预售购买

v0.1.6

  • 用户小程序适配修 修改counter 版本依赖

v0.1.5

  • 用户小程序适配修 修改counter 版本依赖

v0.1.4

  • 用户小程序适配修改

v0.1.3

  • 用户小程序适配修改

v0.1.2

  • 用户小程序适配修改

v0.1.1

  • 依赖处理

v0.1.0

  • 组件初始化

基本调用

 <shop-cart-card></shop-cart-card>

参数 Props

| 参数 | 说明 | 类型 | 可选值 | 默认值 | | ------------ | ----------------------------------------- | ------- | ------------------------------------ | ------ | | key | 商品唯一标识 | String | - | - | | checked | 是否选中 | Boolean | - | false | | disabled | 是否可选 | Boolean | - | false | | status | 商品状态:(正常/卖光/库存不足/已结束/预售) | String | ACTIVE/SOLDOUT/LACK/OVER/WAITING | - | | title | 标题 | String | - | - | | cover | 商品封面 | String | - | - | | info | 商品顶部提示语 | String | - | - | | tag | 商品图片左上角标签 | String | - | - | | vendor | 商品图片底部(供应商名称) | String | - | - | | price | 价格 | Number | - | - | | market-price | 市场价(原价) | Number | - | - | | cart-count | 购物车数量 | Number | - | 1 | | countDown | 倒计时 | Object | { hours: '', minute:'', second: '' } | - |

事件 event

| 名称 | 参数 | 说明 | 备注 | | ------------- |:-------------:| :--------------------| :---------------| |onTap | | 点击图片标题区域触发 | | |onCheck | | 选中事件 | | |onAdd | | 添加购物车时触发 | | |onReduce | | 减少购物车数量 | | |onChange | | 改变购物车数量 | 输入框改变时触发| |onBlur | | 输入框失焦时触发 | | |onFocus | | 输入框聚焦时触发 | |

插槽 slot

| 名称 | 说明 | 备注 | | ------------- |:-------------:| :--------------------| | cell | 商品属性(包装单位) | |

相关演示

An image An image