reactjs - React中textarea中滚动条的边框半径问题
问题描述
我想在滚动条和 textarea 的边缘之间放置一些空间,并使用以下代码:
export const Textarea = styled.textarea`
font-family: Open Sans, sans-serif;
font-size: 16px;
line-height: 24px;
border-radius: 14px;
width: 600px;
height: 200px;
border-width: 0px;
border: 1px solid #DCDCDC;
padding: 14px 16px;
left:-100px;
resize: none;
box-sizing: border-box;
::-webkit-scrollbar {
width: 8px;
height: 60px;
}
::-webkit-scrollbar-thumb {
background-color: #3AA4A4;
border-radius:2px;
border-right: 4px white solid;
background-clip: padding-box;
}
::-webkit-scrollbar-track {
margin-top: 20px;
margin-bottom: 20px;
}
:focus {
outline: none;
}
:placeholder {
color: #96a2ac;
}
`;
但问题是添加了空间,但右上角和右下角的滚动条的边框半径没有添加且可见。
解决方案
推荐阅读
- c++14 - count = count + n&1 和 count += n&1 之间的差异
- css - 如何在 Wordpress 上禁用移动设备上的元素?
- android - Kotlin - 广播接收器调用问题
- spring - 如何使用 Spring JDBC 模板更新从具有相似条件的表中删除记录?
- mysql - 无法将 MySQL 从 8.0.3 升级到 8.0.14
- c# - 在页面底部的现有 PDF 中添加表格
- c# - 使用 c# 列出安装在 Windows 10 机器上的游戏
- ios - Mac 10.14 中的 Intellij Idea 看不到 ios 模拟器
- linux - 如何在变量中添加“”字符作为自己?
- ios - 在 TableView 单元格中处理从 Firebase 检索数据的更好方法