1.css基本语法.html 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <title>Document</title>
  7. <style>
  8. div {
  9. width: 100px;
  10. height: 100px;
  11. background-color: red;
  12. color: #ff0;
  13. /*
  14. 圆角边框 border-radius
  15. 50% 圆形
  16. 右下border-bottom-right-radius
  17. 右上border-top-right-radius
  18. 左下border-bottom-left-radius
  19. 左上border-top-left-radius
  20. */
  21. /* border-radius: 50%; */
  22. border-bottom-right-radius: 10px;
  23. }
  24. input {
  25. /* 取消边框 */
  26. /* border:none; */
  27. border:1px solid #f00;
  28. /*
  29. outline 轮廓
  30. none 取消轮廓
  31. */
  32. outline: none;
  33. outline: 2px solid #00f;
  34. }
  35. /*
  36. ::before ::after css3的语法
  37. :before :after css2的语法
  38. */
  39. </style>
  40. </head>
  41. <body>
  42. <div>
  43. <div>你点我啊</div>
  44. <input type="text">
  45. </div>
  46. </body>
  47. </html>