我要一个好看的样式
时间: 2023-07-25 18:03:37 浏览: 47
好的,下面是一个基本的微信支付页面样式,你可以根据自己的需要进行调整:
```
<template>
<div class="wechat-pay">
<div class="header">
<img src="./images/logo.png" alt="logo">
</div>
<div class="content">
<h1>微信支付</h1>
<p>订单号:{{ orderNumber }}</p>
<p>支付金额:{{ amount }}</p>
<button class="pay-btn" @click="pay">立即支付</button>
</div>
</div>
</template>
<style>
.wechat-pay {
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
background-color: #f5f5f5;
}
.header {
width: 100%;
height: 50px;
display: flex;
justify-content: center;
align-items: center;
background-color: #3f83f8;
}
.header img {
width: 100px;
height: 30px;
}
.content {
width: 80%;
max-width: 400px;
padding: 30px;
background-color: #fff;
border-radius: 10px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
}
h1 {
font-size: 24px;
font-weight: bold;
margin-bottom: 20px;
}
p {
font-size: 16px;
margin-bottom: 10px;
}
.pay-btn {
width: 100%;
height: 50px;
margin-top: 30px;
background-color: #3f83f8;
color: #fff;
font-size: 18px;
border: none;
border-radius: 5px;
cursor: pointer;
}
.pay-btn:hover {
background-color: #2d68c4;
}
</style>
```
这个样式使用了 flex 布局,使得页面可以自适应不同的屏幕大小,同时使用了圆角和阴影等效果,使得页面看起来更加美观。你可以根据自己的需要进行调整,比如修改颜色、调整字体大小等等。