diff options
| author | muqiuhan <[email protected]> | 2023-02-28 09:58:51 +0000 |
|---|---|---|
| committer | muqiuhan <[email protected]> | 2023-02-28 09:58:51 +0000 |
| commit | 7e2f3fca091c08771486df0b870ce187f869d363 (patch) | |
| tree | 025e1b18a0d94c940a85eb631a7f48951efbc18d /css/post/task_list.css | |
| parent | 2605fd54aa163fcfc97fc265a300b1b54bf38543 (diff) | |
| download | blog-7e2f3fca091c08771486df0b870ce187f869d363.tar.gz | |
deploy: b780169745c17f9fc971299e923e5ca5669b5a22
Diffstat (limited to 'css/post/task_list.css')
| -rw-r--r-- | css/post/task_list.css | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/css/post/task_list.css b/css/post/task_list.css new file mode 100644 index 00000000..ee2ec895 --- /dev/null +++ b/css/post/task_list.css @@ -0,0 +1,44 @@ +ul li.task-list-item { + position: relative; +} +ul li.task-list-item>input[type=checkbox] { + list-style: none; + background: none; + appearance: none; + -webkit-appearance: none; + -moz-appearance: none; + width: $margin-l-0; + display: inline-block; + border: none; + opacity: 1; +} +ul li.task-list-item>input[type=checkbox][checked]:before { + background: $color-text-primary; + -webkit-mask-image: url("../icon/checkbox-checked.svg"); + -webkit-mask-position: center center; + mask-image: url("../icon/checkbox-checked.svg"); + -webkit-mask-repeat: no-repeat; +} +ul li.task-list-item>input[type=checkbox]:before { + background: $color-text-primary; + -webkit-mask-image: url("../icon/checkbox-default.svg"); + -webkit-mask-position: center center; + mask-image: url("../icon/checkbox-default.svg"); + -webkit-mask-repeat: no-repeat; +} +ul li.task-list-item>input[type=checkbox]:after, +ul li.task-list-item>input[type=checkbox]:before { + display: block; + position: absolute; + content: "X"; + color: transparent; + left: 0; + top: 0; + width: $icon-size; + height: $line-height-body; + background-size: contain; + background-repeat: no-repeat; + background-position-x: 0; + background-position-y: center; + --webkit-touch-callout: none; +} |
