优化toast组件

This commit is contained in:
TOP糯米 2023-04-07 23:51:09 +08:00
parent 96d2bb6e32
commit 75fd2a5024
1 changed files with 9 additions and 1 deletions

View File

@ -28,16 +28,24 @@ export default {
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
@keyframes fadeIn {
0% {
opacity: 0;
}
100% {
opacity: 0.9;
}
}
.components-widgets-toast { .components-widgets-toast {
z-index: 25; z-index: 25;
position: fixed; position: fixed;
top: 50%; top: 50%;
left: 0; left: 0;
right: 0; right: 0;
transform: translateY(-50%);
margin: 0 auto; margin: 0 auto;
text-align: center; text-align: center;
max-width: 400rpx; max-width: 400rpx;
animation: fadeIn 0.35s forwards;
.toast { .toast {
display: inline-block; display: inline-block;
font-size: 28rpx; font-size: 28rpx;