# Meta Post - Common CSS Hacks

**URL:** <https://forum.obsidian.md/t/meta-post-common-css-hacks/1978>\
**Category:** Themes & CSS snippets\
**Tags:** custom-css\
**Created:** [June 16, 2020, 2:17pm UTC](https://forum.obsidian.md/t/meta-post-common-css-hacks/1978 "2020-06-16T14:17:57Z")\
**Posts on this page:** 1\
**Showing post:** 34

<div class="post-metadata">

**Author:** ![rsdimitrov](https://forum.obsidian.md/user_avatar/forum.obsidian.md/rsdimitrov/32/746_2.png) [@rsdimitrov](https://forum.obsidian.md/u/rsdimitrov)\
**Post date:** [July 3, 2020, 9:09am UTC](https://forum.obsidian.md/t/meta-post-common-css-hacks/1978/34 "2020-07-03T09:09:13Z")

</div>

Nicer checkboxes in preview by @kepano

> [@Nicer Checkboxes](https://forum.obsidian.md/t/nicer-checkboxes/2238):
>
> Just a simple CSS snippet that makes your checkboxes nicer. Drop the code below into your obsidian.css and it should work with your theme input[type=checkbox] { -webkit-appearance: none; appearance: none; border-radius: 50%; border: 1px solid var(--text-faint); padding: 0; } input[type=checkbox]:focus{ outline:0; } input[type=checkbox]:checked { background-color: var(--text-accent-hover); border: 1px solid var(--text-accent-…

And here is my remix, nicer checkboxes in Editor:

```
/* Round checkbxes in preview and editor */
input[type=checkbox], .cm-formatting-task {
    -webkit-appearance: none;
    appearance: none;
    border-radius: 50%;
    border: 1px solid var(--text-faint);
    padding: 0;
    vertical-align: middle;    
}

.cm-s-obsidian span.cm-formatting-task {
    color: transparent;
    width: 1.25em !important;
    height: 1.25em;
    display: inline-block;
}

input[type=checkbox]:focus{
  outline:0;
}
input[type=checkbox]:checked, .cm-formatting-task.cm-property {
    background-color: var(--text-accent-hover);
    border: 1px solid var(--text-accent-hover);
    background-position: center;
    background-size: 70%;
    background-repeat: no-repeat;
    background-image: url('data:image/svg+xml; utf8, <svg width="12px" height="10px" viewBox="0 0 12 8" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><g stroke="none" stroke-width="1" fill="none" fill-rule="evenodd"><g transform="translate(-4.000000, -6.000000)" fill="%23ffffff"><path d="M8.1043257,14.0367999 L4.52468714,10.5420499 C4.32525014,10.3497722 4.32525014,10.0368095 4.52468714,9.8424863 L5.24777413,9.1439454 C5.44721114,8.95166768 5.77142411,8.95166768 5.97086112,9.1439454 L8.46638057,11.5903727 L14.0291389,6.1442083 C14.2285759,5.95193057 14.5527889,5.95193057 14.7522259,6.1442083 L15.4753129,6.84377194 C15.6747499,7.03604967 15.6747499,7.35003511 15.4753129,7.54129009 L8.82741268,14.0367999 C8.62797568,14.2290777 8.3037627,14.2290777 8.1043257,14.0367999"></path></g></g></svg>');
}

```

Looks like this:  
 ![image](https://forum.obsidian.md/uploads/default/original/2X/6/6600bafd4c176e0f37335326b7c3c9a91a2fb2d5.png)

Since the contents of the element are transparent, to check/uncheck a checkbox, place your cursor right after it:  
 ![image](https://forum.obsidian.md/uploads/default/original/2X/1/10a07ce7e352d20d9f861c19fd539a087954c469.png)  
Press left arrow once, then press backspace.

To check an item:  
Press your cursor behind the checkbox, press left arrow once, press backspace, type ‘x’ and it will turn into a checkbox.

Here is how it works in practice  
 ![ezgif-1-1cb6fc8b02cf](https://forum.obsidian.md/uploads/default/original/2X/c/cd21281da87866804c826adf920e7245c8acfdc1.gif)

This makes long checklists in Edit more way more understandable and reduces my need to switch to Preview!

---

_[View the full topic](https://forum.obsidian.md/t/meta-post-common-css-hacks/1978)._
