基于Vue的Material Design UI库 Vue-Carbon

码农软件 · 软件分类 · Vue 组件 · 2019-03-20 11:12:56

软件介绍

vue-carbon,基于 vue 开发 material design 风格的移动端 WEB UI 库, 设计资源参考 CARBON FrameWork7

安装

目前只使用 npm 安装,和使用 webpack 项目的应用

npm install vue-carbon --save
import Vue from 'vue'
import VueCarbon from 'vue-carbon'
Vue.use(VueCarbon)

简单使用

例如这个 Refresh Control 组件的demo页面

<template>
<div class="page">
  <header-bar>
    <icon-button slot="left" @click="back()" icon="arrow_back"></icon-button>
    <span>Refresh Control</span>
    <icon-button slot="right" @click="refresh()" icon="refresh"></icon-button>
  </header-bar>
  <content v-el:trigger>
    <refresh-control @refresh="refresh" :trigger="$els.trigger" :refreshing="refreshing"></refresh-control>
    <content-block>
      <p class="refresh-desc">
         按住 - 下拉 - 释放可以刷新数据
      </p>
    </content-block>
    <list>
      <item-cell v-for="item in items">
        <item-title>
          {{item}}
        </item-title>
      </item-cell>
    </list>
  </content>
</div>
</template><script>export default {  data () {    return {      items: ['1', '2', '3', '5', '6', '7', '8', '9', '10'],      end: 10,      refreshing: false    }  },  methods: {    back () {      window.history.back()    },    refresh () {      this.refreshing = true      setTimeout(() => {        this.refreshing = false        var arr = []        for (let i = this.end; i < this.end + 10; i++) {          arr.push(String(i + 1))        }        this.end += 10        this.items = arr      }, 2000)    }  }}</script><style lang="less">.refresh-desc{  text-align: center;}</style>

效果如下


本文地址:https://codercto.com/soft/d/1752.html

Linux集群体系结构

Linux集群体系结构

Alex Vrenios / 马朝晖 / 机械工业出版社 / 2003-1 / 38.00元

本书对Linux集群体系结构的硬件环境组建与其软件开发作了深入细致的介绍。通过阅读本书,可以对Linux集群体系结构有深入的认识,掌握并了解如何设计和构造集群计算机。本书使你了解到开发项目可能遇到的问题,并掌握测试和调整分布式算法。 本书适合计算机系统集成技术人员、管理人员和计算机科研人员作为参考。一起来看看 《Linux集群体系结构》 这本书的介绍吧!

HTML 编码/解码
HTML 编码/解码

HTML 编码/解码

XML、JSON 在线转换
XML、JSON 在线转换

在线XML、JSON转换工具

RGB HSV 转换
RGB HSV 转换

RGB HSV 互转工具