html - 无法让占位符出现在输入框中
问题描述
.main {
background-color: #151515;
}
.signup_container {
align-items: center;
justify-self: center;
margin: 0 auto;
height: 100vh;
background-color: #151515;
z-index: 1;
width: 100%;
max-width: 1300px;
padding: 0 50px;
}
.signup_content {
padding-top: 100px;
font-size: 2rem;
background-color: #ff8177;
background-image: linear-gradient(to top, #ff0844 0%, #ffb199 100%);
background-size: 50%;
-webkit-background-clip: text;
-moz-background-clip: text;
-webkit-text-fill-color: transparent;
-moz-text-fill-color: transparent;
text-align: center;
}
.signup_input-position {
position: relative;
align-items: center;
justify-self: center;
margin: 0 auto;
width: 200px;
height: 25px;
display: block;
margin-top: 25px;
}
<div class="main">
<div class="signup_container">
<div class="signup_content">
<h1>Sign Up</h1>
<input type="text" name="uname" placeholder="Username" class="signup_input-position" />
</div>
</div>
</div>
我在那里有一堂课和一个占位符,但是我不明白为什么占位符没有出现在输入框中。
html中定义的一些css
解决方案
不用担心,我只会使用简单的颜色而不是渐变。不能被要求浪费我的时间。
推荐阅读
- jenkins - Jenkins Cobertura 插件 - 重置 Ratcheting / autoUpdateHealth 值
- python - 基于一组子字符串递归查找文件的有效方法,存储它们的路径
- php - 如何使用 php 从多维 json 响应中获取键和值
- javascript - 为什么Quasar抽屉覆盖Vue应用程序中的Quasar工具栏?
- html - Flexbox 等高 4x4 网格
- testing - 开玩笑地使用组合 api Vue3 quasar 获取变量
- regex - 需要正则表达式来返回倒数第二个目录表单路径
- c++ - 创建你自己的仿函数,C++
- linux - bash 使用 =~ 运算符测试内置单词正则表达式
- list - 列出函数内的变量分配导致对全局变量的不必要更改