2016-09-09 14:29:19 +08:00
|
|
|
<template>
|
2016-11-01 20:22:38 +08:00
|
|
|
<h4>基本</h4>
|
|
|
|
<br><br>
|
2016-11-21 09:48:16 +08:00
|
|
|
<i-button type="success">按钮</i-button>
|
|
|
|
<i-button type="warning">按钮</i-button>
|
|
|
|
<i-button type="error">按钮</i-button>
|
|
|
|
<i-button type="info">按钮</i-button>
|
2016-11-21 10:00:52 +08:00
|
|
|
<i-button icon="ios-search" type="success"></i-button>
|
|
|
|
<br><br>
|
2016-11-21 11:38:49 +08:00
|
|
|
<div style="width:400px">
|
2016-11-21 10:00:52 +08:00
|
|
|
<i-button type="error" long size="small">按钮</i-button>
|
|
|
|
</div>
|
2016-11-21 09:48:16 +08:00
|
|
|
<br><br>
|
2016-11-01 20:22:38 +08:00
|
|
|
<Button-group>
|
|
|
|
<i-button>取消</i-button>
|
|
|
|
<i-button type="primary">确定</i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group>
|
|
|
|
<i-button disabled>昨日</i-button>
|
|
|
|
<i-button disabled>今日</i-button>
|
|
|
|
<i-button disabled>明日</i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group>
|
|
|
|
<i-button type="primary">L</i-button>
|
|
|
|
<i-button>M</i-button>
|
|
|
|
<i-button type="ghost">M</i-button>
|
|
|
|
<i-button type="dashed">R</i-button>
|
|
|
|
</Button-group>
|
|
|
|
<br><br>
|
|
|
|
<h4>配合图标</h4>
|
|
|
|
<br><br>
|
|
|
|
<Button-group>
|
|
|
|
<i-button type="primary">
|
|
|
|
<Icon type="chevron-left"></Icon>
|
|
|
|
前进
|
|
|
|
</i-button>
|
|
|
|
<i-button type="primary">
|
|
|
|
后退
|
|
|
|
<Icon type="chevron-right"></Icon>
|
|
|
|
</i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group>
|
|
|
|
<i-button type="primary" icon="ios-skipbackward"></i-button>
|
|
|
|
<i-button type="primary" icon="ios-skipforward"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group>
|
|
|
|
<i-button type="ghost" icon="ios-color-wand-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-sunny-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-crop"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-color-filter-outline"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<br><br>
|
|
|
|
<h4>圆角</h4>
|
|
|
|
<br><br>
|
|
|
|
<Button-group shape="circle">
|
|
|
|
<i-button type="primary">
|
|
|
|
<Icon type="chevron-left"></Icon>
|
|
|
|
前进
|
|
|
|
</i-button>
|
|
|
|
<i-button type="primary">
|
|
|
|
后退
|
|
|
|
<Icon type="chevron-right"></Icon>
|
|
|
|
</i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group shape="circle">
|
|
|
|
<i-button type="primary" icon="ios-skipbackward"></i-button>
|
|
|
|
<i-button type="primary" icon="ios-skipforward"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group shape="circle">
|
|
|
|
<i-button type="ghost" icon="ios-color-wand-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-sunny-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-crop"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-color-filter-outline"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group shape="circle" size="large">
|
|
|
|
<i-button type="primary" icon="ios-skipbackward"></i-button>
|
|
|
|
<i-button type="primary" icon="ios-skipforward"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group shape="circle" size="large">
|
|
|
|
<i-button type="ghost" icon="ios-color-wand-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-sunny-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-crop"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-color-filter-outline"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group shape="circle" size="small">
|
|
|
|
<i-button type="primary" icon="ios-skipbackward"></i-button>
|
|
|
|
<i-button type="primary" icon="ios-skipforward"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group shape="circle" size="small">
|
|
|
|
<i-button type="ghost" icon="ios-color-wand-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-sunny-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-crop"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-color-filter-outline"></i-button>
|
|
|
|
</Button-group>
|
2016-11-29 13:08:47 -06:00
|
|
|
|
|
|
|
<br><br>
|
|
|
|
<h4>Vertical</h4>
|
|
|
|
<br><br>
|
|
|
|
|
|
|
|
<Button-group vertical>
|
|
|
|
<i-button>取消</i-button>
|
|
|
|
<i-button type="primary">确定</i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group vertical>
|
|
|
|
<i-button>取消</i-button>
|
|
|
|
<i-button type="primary">确定</i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group vertical>
|
|
|
|
<i-button disabled>昨日</i-button>
|
|
|
|
<i-button disabled>今日</i-button>
|
|
|
|
<i-button disabled>明日</i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group vertical>
|
|
|
|
<i-button type="primary">L</i-button>
|
|
|
|
<i-button>M</i-button>
|
|
|
|
<i-button type="ghost">M</i-button>
|
|
|
|
<i-button type="dashed">R</i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group vertical>
|
|
|
|
<i-button type="primary">
|
|
|
|
<Icon type="chevron-left"></Icon>
|
|
|
|
前进
|
|
|
|
</i-button>
|
|
|
|
<i-button type="primary">
|
|
|
|
后退
|
|
|
|
<Icon type="chevron-right"></Icon>
|
|
|
|
</i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group vertical>
|
|
|
|
<i-button type="primary" icon="ios-skipbackward"></i-button>
|
|
|
|
<i-button type="primary" icon="ios-skipforward"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group vertical>
|
|
|
|
<i-button type="ghost" icon="ios-color-wand-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-sunny-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-crop"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-color-filter-outline"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group vertical size="large">
|
|
|
|
<i-button type="primary" icon="ios-skipbackward"></i-button>
|
|
|
|
<i-button type="primary" icon="ios-skipforward"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group shape="circle" vertical size="large">
|
|
|
|
<i-button type="ghost" icon="ios-color-wand-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-sunny-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-crop"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-color-filter-outline"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group shape="circle" vertical size="small">
|
|
|
|
<i-button type="primary" icon="ios-skipbackward"></i-button>
|
|
|
|
<i-button type="primary" icon="ios-skipforward"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
<Button-group shape="circle" vertical size="small">
|
|
|
|
<i-button type="ghost" icon="ios-color-wand-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-sunny-outline"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-crop"></i-button>
|
|
|
|
<i-button type="ghost" icon="ios-color-filter-outline"></i-button>
|
|
|
|
</Button-group>
|
|
|
|
|
2016-11-01 20:22:38 +08:00
|
|
|
<br><br>
|
2016-11-01 17:01:59 +08:00
|
|
|
<i-button type="primary" icon="ios-search" shape="circle" size="small"></i-button>
|
|
|
|
<i-button type="primary" icon="ios-search" shape="circle"></i-button>
|
|
|
|
<i-button type="primary" icon="ios-search" shape="circle" size="large"></i-button>
|
|
|
|
<i-button type="primary" icon="ios-search" shape="circle" size="small">搜索</i-button>
|
|
|
|
<i-button type="primary" icon="ios-search" shape="circle">搜索</i-button>
|
|
|
|
<i-button type="primary" icon="ios-search" shape="circle" size="large">搜索</i-button>
|
|
|
|
<br><br>
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button>Default</i-button>
|
|
|
|
<i-button type="primary">Primary</i-button>
|
|
|
|
<i-button type="ghost">Ghost</i-button>
|
2016-11-01 17:01:59 +08:00
|
|
|
<i-button type="dashed">Dashed</i-button>
|
|
|
|
<i-button type="text">文字按钮</i-button>
|
|
|
|
<i-button type="text" disabled>文字按钮</i-button>
|
2016-09-20 17:10:17 +08:00
|
|
|
<br><br>
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button type="primary" size="large">Large</i-button>
|
|
|
|
<i-button type="primary">Default</i-button>
|
|
|
|
<i-button type="primary" size="small">Small</i-button>
|
2016-09-20 17:10:17 +08:00
|
|
|
<br><br>
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button>Default</i-button>
|
|
|
|
<i-button disabled>Default(Disabled)</i-button>
|
2016-09-20 17:10:17 +08:00
|
|
|
<br><br>
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button type="primary">Primary</i-button>
|
|
|
|
<i-button type="primary" disabled>Primary(Disabled)</i-button>
|
2016-09-20 17:10:17 +08:00
|
|
|
<br><br>
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button type="ghost">Ghost</i-button>
|
|
|
|
<i-button type="ghost" disabled>Ghost(Disabled)</i-button>
|
2016-09-20 17:10:17 +08:00
|
|
|
<br><br>
|
2016-11-01 17:01:59 +08:00
|
|
|
<i-button type="dashed">dashed</i-button>
|
|
|
|
<i-button type="dashed" disabled>dashed(Disabled)</i-button>
|
|
|
|
<br><br>
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button type="primary" shape="circle" icon="ios-search"></i-button>
|
|
|
|
<i-button type="primary" icon="ios-search">搜索</i-button>
|
2016-09-20 17:10:17 +08:00
|
|
|
<br><br>
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button type="ghost" shape="circle">
|
2016-09-20 17:10:17 +08:00
|
|
|
<Icon type="search"></Icon>
|
2016-10-28 17:24:52 +08:00
|
|
|
</i-button>
|
|
|
|
<i-button type="ghost">
|
2016-09-20 17:10:17 +08:00
|
|
|
<Icon type="search"></Icon>
|
|
|
|
搜索
|
2016-10-28 17:24:52 +08:00
|
|
|
</i-button>
|
|
|
|
<i-button type="ghost" shape="circle" size="large">
|
2016-09-20 17:10:17 +08:00
|
|
|
<Icon type="search"></Icon>
|
2016-10-28 17:24:52 +08:00
|
|
|
</i-button>
|
|
|
|
<i-button type="ghost" shape="circle" size="small">
|
2016-09-20 17:10:17 +08:00
|
|
|
<Icon type="search"></Icon>
|
2016-10-28 17:24:52 +08:00
|
|
|
</i-button>
|
2016-09-20 17:10:17 +08:00
|
|
|
<br><br><br>
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button type="primary" loading>Loading...</i-button>
|
|
|
|
<i-button type="primary" loading size="large">Loading...</i-button>
|
|
|
|
<i-button type="primary" loading size="small">Loading...</i-button>
|
|
|
|
<i-button type="primary" :loading="loading" @click="toLoading">
|
2016-09-20 17:10:17 +08:00
|
|
|
<span v-if="!loading">Click me!</span>
|
|
|
|
<span v-else>Loading...</span>
|
2016-10-28 17:24:52 +08:00
|
|
|
</i-button>
|
|
|
|
<i-button type="primary" :loading="loading2" icon="checkmark-round" @click="toLoading2">
|
2016-09-20 17:10:17 +08:00
|
|
|
<span v-if="!loading2">Click me!</span>
|
|
|
|
<span v-else>Loading...</span>
|
2016-10-28 17:24:52 +08:00
|
|
|
</i-button>
|
2016-09-20 17:10:17 +08:00
|
|
|
<h4>基本</h4>
|
|
|
|
<Button-group size="large">
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button>取消</i-button>
|
|
|
|
<i-button type="primary">确定</i-button>
|
2016-09-20 17:10:17 +08:00
|
|
|
</Button-group>
|
2016-09-09 14:29:19 +08:00
|
|
|
<Button-group>
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button type="primary">L</i-button>
|
|
|
|
<i-button>M</i-button>
|
|
|
|
<i-button type="ghost">R</i-button>
|
2016-11-01 17:01:59 +08:00
|
|
|
<i-button type="dashed">R</i-button>
|
2016-09-20 17:10:17 +08:00
|
|
|
</Button-group>
|
|
|
|
<h4>配合图标</h4>
|
|
|
|
<Button-group>
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button type="primary">
|
2016-09-20 17:10:17 +08:00
|
|
|
<Icon type="chevron-left"></Icon>
|
|
|
|
前进
|
2016-10-28 17:24:52 +08:00
|
|
|
</i-button>
|
|
|
|
<i-button type="primary">
|
2016-09-20 17:10:17 +08:00
|
|
|
后退
|
|
|
|
<Icon type="chevron-right"></Icon>
|
2016-10-28 17:24:52 +08:00
|
|
|
</i-button>
|
2016-09-20 17:10:17 +08:00
|
|
|
</Button-group>
|
|
|
|
<Button-group>
|
2016-10-28 17:24:52 +08:00
|
|
|
<i-button type="primary" icon="cloud"></i-button>
|
|
|
|
<i-button type="primary" icon="upload"></i-button>
|
2016-09-09 14:29:19 +08:00
|
|
|
</Button-group>
|
|
|
|
</template>
|
|
|
|
<script>
|
2016-11-09 18:23:17 +08:00
|
|
|
import { iButton, Icon, Input, Switch, Radio, Checkbox, InputNumber, Row, Col, Page } from 'iview';
|
|
|
|
const ButtonGroup = iButton.Group;
|
2016-09-09 14:29:19 +08:00
|
|
|
const RadioGroup = Radio.Group;
|
|
|
|
const CheckboxGroup = Checkbox.Group;
|
|
|
|
|
|
|
|
export default {
|
|
|
|
components: {
|
2016-11-09 18:23:17 +08:00
|
|
|
iButton,
|
2016-09-09 14:29:19 +08:00
|
|
|
ButtonGroup,
|
|
|
|
Icon,
|
|
|
|
iInput: Input,
|
|
|
|
Switch,
|
|
|
|
Radio,
|
|
|
|
RadioGroup,
|
|
|
|
Checkbox,
|
|
|
|
CheckboxGroup,
|
|
|
|
InputNumber,
|
|
|
|
Row,
|
|
|
|
iCol: Col,
|
2016-11-01 17:01:59 +08:00
|
|
|
Page
|
2016-09-09 14:29:19 +08:00
|
|
|
},
|
|
|
|
props: {
|
2016-10-28 17:24:52 +08:00
|
|
|
|
2016-09-09 14:29:19 +08:00
|
|
|
},
|
|
|
|
data () {
|
|
|
|
return {
|
2016-09-20 17:10:17 +08:00
|
|
|
loading: false,
|
2016-11-01 14:21:56 +08:00
|
|
|
loading2: false,
|
|
|
|
model6: ''
|
2016-10-28 17:24:52 +08:00
|
|
|
}
|
2016-09-09 14:29:19 +08:00
|
|
|
},
|
|
|
|
methods: {
|
2016-09-20 17:10:17 +08:00
|
|
|
toLoading () {
|
|
|
|
this.loading = true;
|
2016-09-09 14:29:19 +08:00
|
|
|
},
|
2016-09-20 17:10:17 +08:00
|
|
|
toLoading2 () {
|
|
|
|
this.loading2 = true;
|
2016-09-09 14:29:19 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</script>
|