How to use the progress component in WeChat mini program

亚连
Release: 2018-06-08 16:41:08
Original
1748 people have browsed it

This article mainly introduces the use of the progress component of the WeChat applet in detail. It has certain reference value. Interested friends can refer to it.

This article shares the progress component of the WeChat applet for everyone. How to use the component is for your reference. The specific content is as follows

Rendering

How to use the progress component in WeChat mini program

WXML

  show-info在进度条右侧显示百分比    stroke-width进度条线的宽度,单位px    color进度条颜色    active进度条从左往右的动画    backgroundColor未选择的进度条的颜色    动态设置进度条进度     10% 30% 50% 70% 90%   
Copy after login

JS

Page({ data: { index: 10 }, changeTabbar(e){ this.setData({ index: e.currentTarget.dataset.id}) } })
Copy after login

progress attribute

percent: initialization percentage
show-info: whether to display the progress bar percentage on the right side of the progress bar
stroke-width: progress bar width, unit px , the default is 6
color: color of the progress bar
activeColor: color of the selected progress bar
backgroundColor: color of the unselected progress bar
active: animation of the progress bar from left to right
active-mode: backwards: the animation will be played from the beginning; forwards: the animation will be played from the last ending point

The above is what I compiled for everyone. I hope it will be helpful to everyone in the future.

Related articles:

What are the differences between let and var defining variables in js?

Nuxt.js Vue server-side rendering exploration

VUE personal summary (problems encountered)

The above is the detailed content of How to use the progress component in WeChat mini program. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!