Skip to content

Instantly share code, notes, and snippets.

@JordanShurmer
Last active February 18, 2020 16:54
Show Gist options
  • Save JordanShurmer/9886f391f955713ce7e725a7b8af3662 to your computer and use it in GitHub Desktop.
Save JordanShurmer/9886f391f955713ce7e725a7b8af3662 to your computer and use it in GitHub Desktop.
CSS for Intellij Markdown

Intellij Markdown CSS

This is the custom CSS I use for Intellij's markdown preview tool.

Usage

https://www.jetbrains.com/help/idea/markdown.html#css

Customize it

The font-familys that are used must be installed on your system and available in Intellij. Change them as desired.

The background-color is also something you'll want to change to match your theme.

html, body {
font-family: "Lato", serif;
}
code, pre {
font-family: "Jetbrains mono", monospace;
}
h1, h2, h3, h4, h5, h6 {
font-family: 'Spectral', serif;
}
body {
max-width: 980px;
margin: auto;
line-height: 1.4em;
background-color: #263238;
}
blockquote {
width: 80%;
margin-left: auto;
margin-right: auto;
min-width: 480px;
text-align: center;
}
html {
box-sizing: border-box
}
*, *::before, *::after {
box-sizing: inherit
}
html, body {
font-size: 16px
}
small, .small {
font-size: 13px
}
table td {
font-size: 13px
}
b, strong {
font-weight: 700
}
h1 {
font-size: 32px
}
h2 {
font-size: 28px
}
h3 {
font-size: 24px
}
h4 {
font-size: 20px
}
h5 {
font-size: 18px
}
h6 {
font-size: 16px
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment