项目作者: nongshuqiner

项目描述 :
A Vue component to show summary list(基于vue的概要列表组件)
高级语言: JavaScript
项目地址: git://github.com/nongshuqiner/ns-vue-summary.git
创建时间: 2019-01-21T10:37:44Z
项目社区:https://github.com/nongshuqiner/ns-vue-summary

开源协议:

下载


ns-vue-summary

A Vue component to show summary list(基于vue的概要列表组件)

Install(安装)

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

  1. npm install --save ns-vue-summary

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

Namely(即):

  1. import NsVueSummary from 'ns-vue-summary'
  2. // 或者 const NsVueSummary = require('ns-vue-summary')
  3. // 或者 <script src="..."></script>
  4. Vue.use(NsVueSummary)

Usage(使用)

In Your HTML:

  1. <!-- 注意:此处案例icon使用的是fontawesome -->
  2. <!-- Note: The case icon here uses fontawesome -->
  3. <ns-summary class="my-summary" :show-space="true">
  4. <ns-summary-item title="title" describe="describe" type="gray" href="https://www.baidu.com/"></ns-summary-item>
  5. <ns-summary-item type="info">
  6. <template slot="title"> 综合用户 </template>
  7. <template slot="describe"> <i class="fa fa-user"></i>XX </template>
  8. </ns-summary-item>
  9. <ns-summary-item title="19 Sales">
  10. <template slot="describe"> 5000万元 </template>
  11. </ns-summary-item>
  12. <ns-summary-item title="FOLLOWING" describe="284" type="danger">
  13. <template slot="title"> <i class="fa fa-bullhorn"></i> FOLLOWING </template>
  14. </ns-summary-item>
  15. <ns-summary-item title="2 Photo Upload" type="success">
  16. <template slot="describe"> ...<i class="fa fa-tags"></i> </template>
  17. </ns-summary-item>
  18. <ns-summary-item title="15 Emails" type="warning">
  19. <template slot="describe"> Unread </template>
  20. </ns-summary-item>
  21. </ns-summary>

The icon used is(使用的图标是):fontawesome

result

:show-space=”false”

result(结果)

:show-space=”true”

result(结果)

props(属性)

ns-summary

参数 是否必须 说明 类型 可选值 默认值
size 大小 String large / medium / default / small / mini default
showSpace 是否有padding间隔 Boolean - true

ns-summary-item

参数 是否必须 说明 类型 可选值 默认值
type 类型 String primary-主要 info-蓝色 gray-灰色 success-绿色 warning-警告 danger-失败 primary
title 标题 String - -
describe 描述 String - -
target a标签的target String - _blank
href a标签的href String - -

event(事件)

none

run(运行)

  1. # git clone ...
  2. git clone https://github.com/nongshuqiner/ns-vue-summary.git
  3. # enter
  4. cd ns-vue-summary
  5. # install dependencies
  6. npm install
  7. # serve with hot reload at localhost:8080
  8. npm run dev
  9. # build for production with minification
  10. 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