2019-08-14 09:48:44 +00:00
|
|
|
<template>
|
|
|
|
<div>
|
|
|
|
<div class="ui-snackbar">
|
2021-12-09 01:32:00 +00:00
|
|
|
<div class="ui-snackbar-text">
|
|
|
|
{{ message }}
|
|
|
|
</div>
|
2022-01-13 19:15:40 +00:00
|
|
|
<div v-if="action" class="ui-snackbar-action">
|
|
|
|
<router-link v-if="action.type == 'link'" :to="action.to">
|
|
|
|
{{ action.message }}
|
|
|
|
</router-link>
|
|
|
|
</div>
|
2019-08-14 09:48:44 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
export default {
|
|
|
|
props: {
|
2021-12-27 08:19:31 +00:00
|
|
|
message: { type: String, default: '' },
|
2022-01-13 19:15:40 +00:00
|
|
|
action: {
|
|
|
|
type: Object,
|
|
|
|
default: () => {},
|
|
|
|
},
|
2019-08-14 09:48:44 +00:00
|
|
|
showButton: Boolean,
|
|
|
|
duration: {
|
|
|
|
type: [String, Number],
|
|
|
|
default: 3000,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
toggleAfterTimeout: false,
|
|
|
|
};
|
|
|
|
},
|
2021-12-09 01:32:00 +00:00
|
|
|
mounted() {},
|
|
|
|
methods: {},
|
2019-08-14 09:48:44 +00:00
|
|
|
};
|
|
|
|
</script>
|