Files
apt-nl/src/components/toast.vue

45 lines
747 B
Vue
Raw Normal View History

2023-05-05 14:20:13 +08:00
<template>
<div class="toast">
<div class="toast-wrap">
<div class="text">
{{toastMsg}}
</div>
</div>
</div>
</template>
<script>
import { mapState } from 'vuex'
export default {
data () {
return {}
},
computed: mapState({
toastMsg: state => state.com.toastMsg
})
}
</script>
<style lang="stylus" scoped>
.toast
.toast-wrap
position fixed
z-index 10001
width 100%
height 1rem
line-height 1rem
text-align center
left 50%
top 50%
transform translate(-50%, -50%)
.text
display inline-block
width auto
text-align center
padding 0 .5rem
border-radius 10px
background #858586
font-size .32rem
color #fff
</style>