原理:利用兄弟选择器配合伪元素自定义单复选框
Demo 预览
基本样式
<body>
<form>
<fieldset class="todo-list"> // fieldset 元素可将表单内的相关元素分组。
<legend class="todo-list__title">My Special Todo List</legend> // legend 标签为 fieldset 元素定义标题。
<label class="todo-list__label">
<input type="checkbox" name="" id="" />
<i class="check"></i>
<span>Make awesome CSS animation</span>
</label>
<label class="todo-list__label">
<input type="checkbox" name="" id="" />
<i class="check"></i>
<span>Watch awesome bangumi</span>
</label>
<label class="todo-list__label">
<input type="checkbox" name="" id="" />
<i class="check"></i>
<span>Encounter awesome people</span>
</label>
<label class="todo-list__label">
<input type="checkbox" name="" id="" />
<i