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

@mas.io/mas-cs-step-flow

v0.0.2

Published

@alipay/mas-cs-step-flow 的组件描述

Downloads

3

Readme

安装

tnpm install --save @alipay/mas-cs-step-flow

组件介绍

行业小程序步骤流程组件 场景一:步骤/流程 - 全状态(包含注意事项) 实现:办理项目、办理流程、注意事项 场景二:仅步骤 实现:办理流程

参数说明

| 属性 | 必填 | 参数类型 | 参数说明 | 默认值 | 示例 | | --------------- | :---: | :------: | :------------------: | :----: | :--: | | hasMention | Y | Boolean | 是否含有注意事项 | true | true/false | | category | N | Array | 办理项目,根据不同办理项目获取不同项目的办理流程,可以不用传,根据业务需求来 | null | [ { identify: 1, // 按钮标识 - 用于区分点击的按钮以获取不同分类下的数据 btnText: '代办年检标识', // 按钮文本 }, { identify: 2, btnText: 'VIP检车', }, { identify: 3, btnText: '代驾检车', }, { identify: 4, btnText: '预约车检站', }, ] | | selectId | N | Number | 选中按钮index,当hasMention为true时,该属性必传 | 1 | 1 | | stepflows | Y | Array | 步骤流程数组,为该组件主要展示部分,必传,数组中包含步骤icon值,步骤名称,步骤所需时间 | null | [ { iconClass: 'icon-Fillin', // 步骤icon,必填,此处是通过上传到confront实现,可根据自身项目icon方式实现 stepText: '填写资料', // 步骤名称,必填 stepTime: '1分钟', // 步骤所需时间,非必填,仅步骤展示时展示,根据业务需求 }, { iconClass: 'icon-PayCircle', stepText: '下单付款', stepTime: '1分钟', }, { iconClass: 'icon-User', stepText: '管家代办', stepTime: '1分钟', }, { iconClass: 'icon-File', stepText: '接收标识', stepTime: '1分钟', }, ] | | mentions | N | Array | 注意事项数组,当当hasMention为true时,该属性必传,数组中包含注意事项,以及扩展跳转事件 | null | [ { mentionText: '可办理车辆:支持办理非运营轿车、小型客车9座及以下', //注意事项内容,必填 mentionView: '', // 扩展事件,非必填 handleTapView: (params) => { console.log(params); }, // 扩展事件点击事件,非必填 }, { mentionText: '办理条件:如有交通事故或违法行为,请先处理完毕方可办理。', mentionView: '立即查询车辆违章情况', handleTapView: (params) => { console.log(params); }, }, { mentionText: '所需资料:行驶证及交强险照片,车辆保险必须在有效时间范围内,如有逾期请先办理保险续保。', mentionView: '', handleTapView: (params) => { console.log(params); }, }, ] |

在小程序中使用

.json配置 示例代码

{
  "usingComponents": {
    "mas-cs-step-flow": "@alipay/mas-cs-step-flow/es/index"
  }
}

.axml 示例代码

<!-- 页面使用方式 -->
 <mas-cs-step-flow
    hasMention="{{hasMention}}"
    category="{{category}}"
    selectId="{{selectId}}"
    stepflows="{{stepflows}}"
    mentions="{{mentions}}"
    handleTapCategory="{{handleTapCategory}}"
  />

.js 示例代码

data: {
  hasMention: true, // 是否有注意事项
  category: [
    {
      identify: 1, // 按钮标识 - 用于区分点击的按钮以获取不同分类下的数据
      btnText: '代办年检标识', // 按钮文本
    },
    {
      identify: 2,
      btnText: 'VIP检车',
    },
    {
      identify: 3,
      btnText: '代驾检车',
    },
    {
      identify: 4,
      btnText: '预约车检站',
    },
  ],
  selectId: 1, // 选中按钮的identify
  stepflows: [
    {
      iconClass: 'icon-Fillin',
      stepText: '填写资料',
      stepTime: '1分钟',
    },
    {
      iconClass: 'icon-PayCircle',
      stepText: '下单付款',
      stepTime: '1分钟',
    },
    {
      iconClass: 'icon-User',
      stepText: '管家代办',
      stepTime: '1分钟',
    },
    {
      iconClass: 'icon-File',
      stepText: '接收标识',
      stepTime: '1分钟',
    },
  ],
  mentions: [
    {
      mentionText: '可办理车辆:支持办理非运营轿车、小型客车9座及以下',
      mentionView: '',
      handleTapView: (params) => { console.log(params); },
    },
    {
      mentionText: '办理条件:如有交通事故或违法行为,请先处理完毕方可办理。',
      mentionView: '立即查询车辆违章情况',
      handleTapView: (params) => { console.log(params); },
    },
    {
      mentionText: '所需资料:行驶证及交强险照片,车辆保险必须在有效时间范围内,如有逾期请先办理保险续保。',
      mentionView: '',
      handleTapView: (params) => { console.log(params); },
    },
  ],
},

handleTapCategory(e) {
  const selectId = e.target.dataset.identify;
  this.setData({
    selectId,
  });
},

Badges

TNPM version TNPM downloads