mirror of
https://github.com/element-plus/element-plus.git
synced 2024-11-27 02:01:15 +08:00
refactor(steps): correct requested changes
This commit is contained in:
parent
45f2efe88d
commit
d28d0c30d8
@ -6,8 +6,7 @@
|
||||
|
||||
<script lang="ts">
|
||||
import { defineComponent, watch, ref, provide } from 'vue'
|
||||
|
||||
const CHANGE_EVENT = 'change'
|
||||
import { CHANGE_EVENT } from '@element-plus/utils/constants'
|
||||
|
||||
export default defineComponent({
|
||||
name: 'ElSteps',
|
||||
|
@ -56,9 +56,14 @@ interface IStepsProps {
|
||||
processStatus: string
|
||||
}
|
||||
|
||||
interface IStepsSetupState {
|
||||
currentStatus: string
|
||||
setIndex: (val: number) => void
|
||||
calcProgress: (status: string) => void
|
||||
}
|
||||
|
||||
interface IStepInstance extends ComponentInternalInstance {
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
setupState: any
|
||||
setupState: IStepsSetupState
|
||||
}
|
||||
|
||||
interface IStepsInject {
|
||||
@ -84,7 +89,7 @@ export default defineComponent({
|
||||
status: {
|
||||
type: String,
|
||||
default: '',
|
||||
validator: (val: string): boolean => ['', 'wait', 'process', 'finish', 'error', 'success'].indexOf(val) > -1,
|
||||
validator: (val: string): boolean => ['', 'wait', 'process', 'finish', 'error', 'success'].includes(val) > -1,
|
||||
},
|
||||
},
|
||||
setup(props) {
|
||||
|
Loading…
Reference in New Issue
Block a user