Less Obvious Line Numbers in the Editor to Get More Focused

Hi YuTang,

I use the following CSS to make my line numbers fainter:

/* Very faint line numbers (cm5) */
.cm-s-obsidian div.CodeMirror-linenumber {
    color: var(--text-faint);
    filter: brightness(140%);
}

/* Very faint line numbers (cm6) */
.markdown-source-view.mod-cm6 .cm-gutterElement {
    color: var(--text-faint);
    filter: brightness(140%);
}

To make them further from the text I suppose you could add padding-right: 3em; or something similar.

4 Likes