You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

66 lines
1.3 KiB

  1. /* Customize the label (the container) */
  2. .checkbox-container {
  3. display: block;
  4. position: relative;
  5. padding-left: 30px;
  6. margin-left: 20px;
  7. margin-bottom: 12px;
  8. cursor: pointer;
  9. -webkit-user-select: none;
  10. -moz-user-select: none;
  11. -ms-user-select: none;
  12. user-select: none;
  13. font-weight: normal;
  14. }
  15. /* Hide the browser's default checkbox */
  16. .checkbox-container input {
  17. position: absolute;
  18. opacity: 0;
  19. }
  20. /* Create a custom checkbox */
  21. .checkmark {
  22. position: absolute;
  23. top: 0;
  24. left: 0;
  25. height: 20px;
  26. width: 20px;
  27. border-radius: 3px;
  28. border: 1px solid #DDD;
  29. }
  30. /* On mouse-over tint the border */
  31. .checkmark:hover {
  32. border-color: #5db4ea;
  33. }
  34. /* When the checkbox is checked, add a colored background */
  35. .checkbox-container input:checked ~ .checkmark {
  36. border-color: #0091EA;
  37. background-color: #0091EA;
  38. }
  39. /* Create the checkmark/indicator (hidden when not checked) */
  40. .checkmark:after {
  41. content: "";
  42. position: absolute;
  43. display: none;
  44. }
  45. /* Show the checkmark when checked */
  46. .checkbox-container input:checked ~ .checkmark:after {
  47. display: block;
  48. }
  49. /* Style the checkmark/indicator */
  50. .checkbox-container .checkmark:after {
  51. left: 7px;
  52. top: 3px;
  53. width: 5px;
  54. height: 10px;
  55. border: solid white;
  56. border-width: 0 2px 2px 0;
  57. -webkit-transform: rotate(45deg);
  58. -ms-transform: rotate(45deg);
  59. transform: rotate(45deg);
  60. }