<template>
    <div>

        <van-nav-bar
                title="step"
                left-arrow
                @click-left="back"
        />
        <div class="page">
            <ul>
                <li class="section">
                    <y-steps :step="step" swf>
                        <y-step-item title="步骤1"></y-step-item>
                        <y-step-item title="步骤2"></y-step-item>
                        <y-step-item title="步骤3"></y-step-item>
                    </y-steps>
                </li>

            </ul>
        </div>
    </div>
</template>

<script>
    import {NavBar} from 'vant';
    import ySteps from '../components/ySteps'
    import yStepItem from '../components/yStepItem'

    export default {
        components: {
            [NavBar.name]: NavBar,
            yStepItem,
            ySteps,
        },
        data:()=>{
            return {
                step:2,
            }
        },
        methods:{
            "fn_click"(e){
                //yToast.success("success");
                //yToast.error("error");
                yToast.loading();
                setTimeout(yToast.clear,100000);
            },
            back:()=>{
                window.history.go(-1);
            }
        },
        mounted(){
            window.test = this;
        },
        watch:{
            bool(){
                const self = this;
                setTimeout(t=>{

                    self.bool = true;
                },10)
            }
        }
    }
</script>

<style scoped>
    .page {
        padding: 10px;
    }
</style>
