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

peony-circle

v1.0.1

Published

A Vue Gradient Progress Circle Component(一个vue的可渐变的进度圆环组件)

Downloads

6

Readme

Peony Circle 圆形环

概述

A Vue Gradient Progress Circle Component(一个vue的可渐变的进度圆环组件)

图表类组件。一般有两种用途:

  • 显示某项任务进度的百分比;
  • 统计某些指标的占比。

Install(安装)

You can install it via NPM:(您可以通过NPM安装它)

npm install --save peony-circle

or,just include peony-circle.js to your view like this.(或者使用引用peony-circle.js的方式)

Namely(即):

import PeonyCircle from 'peony-circle'
// 或者 const PeonyCircle = require('peony-circle')
// 或者 <script src="..."></script>
Vue.use(PeonyCircle)

Usage(使用)

<template lang="html">
  <peony-circle :size="120" :stroke-width="6" :trail-width="6" :percent="percent" :stroke-color="strokeColor" :trail-color="trailColor">
    <span style="color:#36D1DC">{{ percent }}%</span>
  </peony-circle>
</template>

<script>
export default {
  data () {
    return {
      percent: 20,
      strokeColor: ['#36D1DC', '#5B86E5'],
      trailColor: '#ececec'
    }
  }
}
</script>

result

run-result.gif

Attributes(属性)

| 参数 | 说明 | 类型 | 可选值 | 默认值 | |---------- |-------- |---------- |------------- |-------- | | percent | 进度百分比 | Number | 0-100 | 0 | | size | 圆环的宽高大小 | Number | - | - | | strokeLinecap | 定义不同类型的开放路径的终结 | String | butt\round\square | butt | | strokeWidth | 圆形环的线条宽度 | Number | - | 1 | | strokeColor | 线条颜色,数组时表示渐变 | Array, String | - | #3FC7FA | | anticlockwise | 是否按逆时针方向展示百分比 | Boolean | true\false | false |

Events

none

slot

| 名称 | 说明 | |---------- |-------- | | none | 自定义显示中间内容,内容默认垂直居中 |

run(运行)

# git clone ...
git clone https://github.com/nongshuqiner/peony-circle.git

# enter
cd peony-circle

# install dependencies
npm install

# serve with hot reload at localhost:8080
npm run dev

# build for production with minification
npm run build

Donation

If you find component useful, you can buy me a cup of coffee 如果您发现此组件有用,您可以给我买一杯咖啡

payment-code.png

Contact me(联系我)

Just Contact Me At:

License

MIT Copyright (c) 2018 - forever Naufal Rabbani