docs: simplify $t to t

This commit is contained in:
chenjiahan
2020-03-21 14:46:02 +08:00
parent 10f32d6619
commit d8fa4b9495
80 changed files with 918 additions and 950 deletions
+14 -22
View File
@@ -1,30 +1,26 @@
<template>
<div>
<demo-section>
<demo-block :title="$t('basicUsage')">
<demo-block :title="t('basicUsage')">
<van-swipe-cell>
<template #left>
<van-button square type="primary" :text="$t('select')" />
<van-button square type="primary" :text="t('select')" />
</template>
<van-cell
:border="false"
:title="$t('title')"
:value="$t('content')"
/>
<van-cell :border="false" :title="t('title')" :value="t('content')" />
<template #right>
<van-button square type="danger" :text="$t('delete')" />
<van-button square type="primary" :text="$t('collect')" />
<van-button square type="danger" :text="t('delete')" />
<van-button square type="primary" :text="t('collect')" />
</template>
</van-swipe-cell>
</demo-block>
<demo-block :title="$t('customContent')">
<demo-block :title="t('customContent')">
<van-swipe-cell>
<van-card
num="2"
price="2.00"
:desc="$t('desc')"
:title="$t('cardTitle')"
:desc="t('desc')"
:title="t('cardTitle')"
:thumb="imageURL"
/>
<template #right>
@@ -32,24 +28,20 @@
square
type="danger"
class="delete-button"
:text="$t('delete')"
:text="t('delete')"
/>
</template>
</van-swipe-cell>
</demo-block>
<demo-block :title="$t('beforeClose')">
<demo-block :title="t('beforeClose')">
<van-swipe-cell :before-close="beforeClose">
<template #left>
<van-button square type="primary" :text="$t('select')" />
<van-button square type="primary" :text="t('select')" />
</template>
<van-cell
:border="false"
:title="$t('title')"
:value="$t('content')"
/>
<van-cell :border="false" :title="t('title')" :value="t('content')" />
<template #right>
<van-button square type="danger" :text="$t('delete')" />
<van-button square type="danger" :text="t('delete')" />
</template>
</van-swipe-cell>
</demo-block>
@@ -99,7 +91,7 @@ export default {
case 'right':
this.$dialog
.confirm({
message: this.$t('confirm'),
message: this.t('confirm'),
})
.then(() => {
instance.close();