提交 a466fd11 编写于 作者: richard_1015's avatar richard_1015

feat(step): add props iconColor

上级 77167334
......@@ -2,12 +2,9 @@
<view :class="classes">
<view class="nut-step-head">
<view class="nut-step-line"></view>
<view
class="nut-step-icon"
:class="[!dot ? (icon ? 'is-icon' : 'is-text') : '']"
>
<view class="nut-step-icon" :class="[!dot ? (icon ? 'is-icon' : 'is-text') : '']">
<template v-if="icon">
<nut-icon class="nut-step-icon-inner" :name="icon" :size="size" />
<nut-icon class="nut-step-icon-inner" :color="iconColor" :name="icon" :size="size" />
</template>
<template v-else-if="dot"></template>
<template v-else>
......@@ -25,14 +22,7 @@
</template>
<script lang="ts">
import {
reactive,
computed,
inject,
toRefs,
getCurrentInstance,
ComponentInternalInstance
} from 'vue';
import { reactive, computed, inject, toRefs, getCurrentInstance, ComponentInternalInstance } from 'vue';
import { createComponent } from '../../utils/create';
const { create, componentName } = createComponent('step');
......@@ -50,6 +40,10 @@ export default create({
type: String,
default: null
},
iconColor: {
type: String,
default: ''
},
size: {
type: [String, Number],
default: '12px'
......
......@@ -91,4 +91,5 @@ app.use(Step);
| ---------------- | ---------------------- | ------------ | ----------- |
| title | 流程步骤的标题 | String | 步骤 |
| content | 流程步骤的描述性文字(支持 html 结构) | String | 步骤描述 |
| icon | 图标 | String | null |
\ No newline at end of file
| icon | 图标 | String | null |
| icon-color | 图标颜色 | String | null |
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册