پیش‌نمایش زنده
کد HTML
<div class="checkbox-wrapper">
  <label>
    <input type="checkbox">
    <span class="checkbox"></span>
  </label>
</div>
کد CSS
.checkbox-wrapper *,
  .checkbox-wrapper *::before,
  .checkbox-wrapper *::after {
  box-sizing: border-box;
}

.checkbox-wrapper label {
  display: block;
  width: 35px;
  height: 35px;
  cursor: pointer;
}

.checkbox-wrapper input {
  visibility: hidden;
  display: none;
}

.checkbox-wrapper input:checked ~ .checkbox {
  transform: rotate(45deg);
  width: 14px;
  margin-left: 12px;
  border-color: #000000;
  border-top-color: transparent;
  border-left-color: transparent;
  border-radius: 0;
}

.checkbox-wrapper .checkbox {
  display: block;
  width: inherit;
  height: inherit;
  border: 3px solid #434343;
  border-radius: 6px;
  transition: all 0.375s;
}

نوع: checkbox
تاریخ ایجاد: 2026/06/05
آخرین بروزرسانی: 2026/06/05