css修改背景透明度background-color:rgba(255,255,255,0.0);
修改透明度有很多方法,我这里使用的css background的rgba
<div style='width:300px;height: 300px;margin-left: 41%;background: rgba(255,255,255,0.7);'>
<h2 style="margin-bottom: 20px;">用户登录</h2>
<Form action="../view/index.vue" ref="loginForm" :model="form":label-width="60">
<FormItem label ="用户名:">
<Input v-model="form.username" placeholder="请输入用户名" />
</FormItem>
<FormItem label="密码:">
<Input type="password" v-model="form.password" placeholder="请输入用户名" />
</FormItem>
</Form>
<Button type="info" @click="onLogin" style="width:250px;height:40px;">登录</Button>
</div>