style.css 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. /* Cell Component */
  2. /* Header Component */
  3. /* Button Component */
  4. /* Tab Item Component */
  5. /* Tabbar Component */
  6. /* Navbar Component */
  7. /* Checklist Component */
  8. /* Radio Component */
  9. /* z-index */
  10. .mint-switch {
  11. display: -webkit-box;
  12. display: -ms-flexbox;
  13. display: flex;
  14. -webkit-box-align: center;
  15. -ms-flex-align: center;
  16. align-items: center;
  17. position: relative;
  18. }
  19. .mint-switch * {
  20. pointer-events: none;
  21. }
  22. .mint-switch-label {
  23. margin-left: 10px;
  24. display: inline-block;
  25. }
  26. .mint-switch-label:empty {
  27. margin-left: 0;
  28. }
  29. .mint-switch-core {
  30. display: inline-block;
  31. position: relative;
  32. width: 52px;
  33. height: 32px;
  34. border: 1px solid #d9d9d9;
  35. border-radius: 16px;
  36. box-sizing: border-box;
  37. background: #d9d9d9;
  38. }
  39. .mint-switch-core::after, .mint-switch-core::before {
  40. content: " ";
  41. top: 0;
  42. left: 0;
  43. position: absolute;
  44. -webkit-transition: -webkit-transform .3s;
  45. transition: -webkit-transform .3s;
  46. transition: transform .3s;
  47. transition: transform .3s, -webkit-transform .3s;
  48. border-radius: 15px;
  49. }
  50. .mint-switch-core::after {
  51. width: 30px;
  52. height: 30px;
  53. background-color: #fff;
  54. box-shadow: 0 1px 3px rgba(0, 0, 0, .4);
  55. }
  56. .mint-switch-core::before {
  57. width: 50px;
  58. height: 30px;
  59. background-color: #fdfdfd;
  60. }
  61. .mint-switch-input {
  62. display: none;
  63. }
  64. .mint-switch-input:checked + .mint-switch-core {
  65. border-color: #26a2ff;
  66. background-color: #26a2ff;
  67. }
  68. .mint-switch-input:checked + .mint-switch-core::before {
  69. -webkit-transform: scale(0);
  70. transform: scale(0);
  71. }
  72. .mint-switch-input:checked + .mint-switch-core::after {
  73. -webkit-transform: translateX(20px);
  74. transform: translateX(20px);
  75. }