Skip to content

Commit 8907276

Browse files
authored
组件 icon (#1975)
* feat: 处理组件tsc问题 * feat: popup icons-vue * feat: 删除注释 * feat: 删除多余注释 * feat: popup icons-vue * feat: popup taro demo修改icon * feat: popup md 修改 * feat: navbar icon替换 * feat: progress icon替换 * feat: navbar 修改titicon参数名 * feat: navbar md titicon * fix: navbar icon
1 parent 1387872 commit 8907276

File tree

5 files changed

+21
-20
lines changed

5 files changed

+21
-20
lines changed

src/packages/__VUE/comment/index.taro.vue

+1-3
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,7 @@
1919
<comment-images :images="images" :videos="videos" :type="imagesRows" @clickImages="clickImages"></comment-images>
2020

2121
<view class="nut-comment__follow" v-if="follow && follow.days > 0" @click="handleClick">
22-
<view class="nut-comment__follow-title"
23-
>购买{{ follow.days }}天后追评</view
24-
>
22+
<view class="nut-comment__follow-title">购买{{ follow.days }}天后追评</view>
2523
<view class="nut-comment__follow-com">{{ follow.content }}</view>
2624
<view class="nut-comment__follow-img" v-if="follow.images && follow.images.length > 0"
2725
>{{ follow.images.length }} 张追评图片 <Right width="12px"></Right

src/packages/__VUE/imagepreview/index.taro.vue

+2-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@
2222

2323
<view class="nut-image-preview-index" v-if="showIndex"> {{ active + 1 }} / {{ images.length }} </view>
2424
<view class="nut-image-preview-close-icon" @click="onClose" :style="styles" v-if="closeable"
25-
><CircleClose color="#ffffff"></CircleClose></view>
25+
><CircleClose color="#ffffff"></CircleClose
26+
></view>
2627
</nut-popup>
2728
</template>
2829
<script lang="ts">

src/packages/__VUE/navbar/doc.en-US.md

-3
Original file line numberDiff line numberDiff line change
@@ -155,9 +155,6 @@ export default {
155155
<nut-tab-pane title="Title3"> </nut-tab-pane>
156156
</nut-tabs>
157157
</template>
158-
<template #icons>
159-
<nut-icon class="icon" name="share"></nut-icon>
160-
</template>
161158

162159
<template #right>
163160
<HorizontalN class="right" width="16px"></HorizontalN>

src/packages/__VUE/navbar/doc.taro.md

+18-10
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ app.use(TabPane);
2727
<div>返回</div>
2828
</template>
2929
<template #right>
30-
<nut-icon class="right" name="share-n"></nut-icon>
30+
<ShareN width="16px"></ShareN>
3131
</template>
3232
</nut-navbar>
3333

@@ -46,18 +46,23 @@ app.use(TabPane);
4646
@on-click-icon="icon"
4747
@on-click-right="rightClick"
4848
title="购物车"
49-
titleIcon="cart2"
49+
:titleIcon="true"
5050
desc="编辑"
5151
>
52+
<template #titleIcon>
53+
<Cart2 width="16px"></Cart2>
54+
</template>
5255
<template #right>
53-
<nut-icon class="right" name="more-x"></nut-icon>
56+
<MoreX class="right" width="16px"></MoreX>
5457
</template>
5558
</nut-navbar>
5659
</template>
5760

5861
<script lang="ts">
5962
import { ref } from 'vue';
63+
import { ShareN, Cart2, MoreX } from '@nutui/icons-vue';
6064
export default {
65+
components: { ShareN, Cart2, MoreX },
6166
setup() {
6267
const methods = {
6368
back() {
@@ -100,14 +105,16 @@ app.use(TabPane);
100105
</template>
101106

102107
<template #right>
103-
<nut-icon class="right" name="more-x"></nut-icon>
108+
<MoreX class="right" width="16px"></MoreX>
104109
</template>
105110
</nut-navbar>
106111
</template>
107112

108113
<script lang="ts">
109114
import { ref } from 'vue';
115+
import { MoreX } from '@nutui/icons-vue';
110116
export default {
117+
components: { MoreX },
111118
setup() {
112119
const tab1value = ref(0);
113120
const methods = {
@@ -148,19 +155,18 @@ export default {
148155
<nut-tab-pane title="标题3"> </nut-tab-pane>
149156
</nut-tabs>
150157
</template>
151-
<template #icons>
152-
<nut-icon class="icon" name="share"></nut-icon>
153-
</template>
154158

155159
<template #right>
156-
<nut-icon class="right" name="horizontal-n"></nut-icon>
160+
<HorizontalN class="right" width="16px"></HorizontalN>
157161
</template>
158162
</nut-navbar>
159163
</template>
160164

161165
<script lang="ts">
162166
import { ref } from 'vue';
167+
import { HorizontalN } from '@nutui/icons-vue';
163168
export default {
169+
components: { HorizontalN },
164170
setup() {
165171
const tab2value = ref(0);
166172
const methods = {
@@ -190,7 +196,7 @@ export default {
190196
| left-text | 左侧文案 | String | - |
191197
| desc | 右侧描述 | String | - |
192198
| left-show | 是否展示左侧箭头 | Boolean | false |
193-
| title-icon | 标题中插入icon | String | - |
199+
| title-icon | 标题中是否展示icon | Boolean | false |
194200
| border | 是否显示下边框 | Boolean | false |
195201
| fixed | 是否固定到顶部 | Boolean | false |
196202
| placeholder | 固定在顶部时,是否在标签位置生成一个等高的占位元素 | Boolean | false |
@@ -212,6 +218,8 @@ export default {
212218
| left | 自定义左侧内容 | |
213219
| right | 自定义右侧内容 | |
214220
| content | 自定义导航栏中间内容 | |
221+
| leftShow | 左侧箭头自定义图标 |
222+
| titleIcon | 标题中自定义图标 |
215223

216224
## 主题定制
217225

@@ -232,4 +240,4 @@ export default {
232240
| --nut-navbar-title-font-weight| _0_ | - |
233241
| --nut-navbar-title-font-color| _var(--nut-navbar-color)_ | - |
234242
| --nut-navbar-title-width| _100px_ | - |
235-
| --nut-navbar-title-icon-margin| _0 0 0 13px_ | - |
243+
| --nut-navbar-title-icon-margin| _0 0 0 13px_ | - |

src/sites/mobile-taro/vue/src/nav/pages/navbar/index.vue

-3
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,6 @@
6161
<nut-tab-pane title="推荐"> </nut-tab-pane>
6262
</nut-tabs>
6363
</template>
64-
<template #icons>
65-
<nut-icon class="icon" name="share"></nut-icon>
66-
</template>
6764

6865
<template #right>
6966
<HorizontalN class="right" width="16px"></HorizontalN>

0 commit comments

Comments
 (0)