[improvement] replace icons (#2304)
This commit is contained in:
@@ -32,7 +32,7 @@
|
||||
<van-cell
|
||||
:title="$t('cell')"
|
||||
:value="$t('content')"
|
||||
icon="location"
|
||||
icon="location-o"
|
||||
/>
|
||||
</demo-block>
|
||||
|
||||
@@ -74,7 +74,7 @@
|
||||
<demo-block :title="$t('advancedUsage')">
|
||||
<van-cell
|
||||
:value="$t('content')"
|
||||
icon="shop"
|
||||
icon="shop-o"
|
||||
is-link
|
||||
>
|
||||
<template slot="title">
|
||||
@@ -84,7 +84,7 @@
|
||||
</van-cell>
|
||||
<van-cell
|
||||
:title="$t('cell')"
|
||||
icon="location"
|
||||
icon="location-o"
|
||||
is-link
|
||||
/>
|
||||
<van-cell :title="$t('cell')">
|
||||
|
||||
@@ -31,7 +31,7 @@ Vue.use(Cell).use(CellGroup);
|
||||
|
||||
```html
|
||||
<van-cell-group>
|
||||
<van-cell title="Cell title" icon="location" />
|
||||
<van-cell title="Cell title" icon="location-o" />
|
||||
</van-cell-group>
|
||||
```
|
||||
|
||||
@@ -66,13 +66,13 @@ Vue.use(Cell).use(CellGroup);
|
||||
|
||||
```html
|
||||
<van-cell-group>
|
||||
<van-cell value="Content" icon="shop" is-link>
|
||||
<van-cell value="Content" icon="shop-o" is-link>
|
||||
<template slot="title">
|
||||
<span class="custom-text">Cell title</span>
|
||||
<van-tag type="danger">Tag</van-tag>
|
||||
</template>
|
||||
</van-cell>
|
||||
<van-cell title="Cell title" icon="location" is-link />
|
||||
<van-cell title="Cell title" icon="location-o" is-link />
|
||||
<van-cell title="Cell title">
|
||||
<van-icon slot="right-icon" name="search" class="custom-icon" />
|
||||
</van-cell>
|
||||
|
||||
@@ -41,7 +41,7 @@ exports[`renders demo correctly 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell"><i class="van-icon van-icon-location van-cell__left-icon" style="color:undefined;font-size:undefined;">
|
||||
<div class="van-cell"><i class="van-icon van-icon-location-o van-cell__left-icon" style="color:undefined;font-size:undefined;">
|
||||
<!---->
|
||||
<!----></i>
|
||||
<div class="van-cell__title"><span>单元格</span>
|
||||
@@ -109,7 +109,7 @@ exports[`renders demo correctly 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable"><i class="van-icon van-icon-shop van-cell__left-icon" style="color:undefined;font-size:undefined;">
|
||||
<div class="van-cell van-cell--clickable"><i class="van-icon van-icon-shop-o van-cell__left-icon" style="color:undefined;font-size:undefined;">
|
||||
<!---->
|
||||
<!----></i>
|
||||
<div class="van-cell__title"><span class="custom-text">单元格</span> <span class="van-tag" style="background-color:#f44;">标签</span></div>
|
||||
@@ -117,7 +117,7 @@ exports[`renders demo correctly 1`] = `
|
||||
<!---->
|
||||
<!----></i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"><i class="van-icon van-icon-location van-cell__left-icon" style="color:undefined;font-size:undefined;">
|
||||
<div class="van-cell van-cell--clickable"><i class="van-icon van-icon-location-o van-cell__left-icon" style="color:undefined;font-size:undefined;">
|
||||
<!---->
|
||||
<!----></i>
|
||||
<div class="van-cell__title"><span>单元格</span>
|
||||
|
||||
@@ -34,7 +34,7 @@ Vue.use(Cell).use(CellGroup);
|
||||
通过`icon`属性在标题左侧展示图标
|
||||
|
||||
```html
|
||||
<van-cell title="单元格" icon="location" />
|
||||
<van-cell title="单元格" icon="location-o" />
|
||||
```
|
||||
|
||||
#### 只设置 value
|
||||
@@ -69,13 +69,13 @@ Vue.use(Cell).use(CellGroup);
|
||||
如以上用法不能满足你的需求,可以使用对应的`slot`来自定义显示的内容
|
||||
|
||||
```html
|
||||
<van-cell value="内容" icon="shop" is-link>
|
||||
<van-cell value="内容" icon="shop-o" is-link>
|
||||
<template slot="title">
|
||||
<span class="custom-text">单元格</span>
|
||||
<van-tag type="danger">标签</van-tag>
|
||||
</template>
|
||||
</van-cell>
|
||||
<van-cell title="单元格" icon="location" is-link />
|
||||
<van-cell title="单元格" icon="location-o" is-link />
|
||||
<van-cell title="单元格">
|
||||
<van-icon slot="right-icon" name="search" class="custom-icon" />
|
||||
</van-cell>
|
||||
|
||||
Reference in New Issue
Block a user