Skip to content

Instantly share code, notes, and snippets.

@fin-ger
Last active July 8, 2017 16:30
Show Gist options
  • Save fin-ger/43b05fe61dd1171fb4fb5ea713c8e179 to your computer and use it in GitHub Desktop.
Save fin-ger/43b05fe61dd1171fb4fb5ea713c8e179 to your computer and use it in GitHub Desktop.
Pandoc Github Theme

To use this theme run

$ pandoc --self-contained --css pandoc-github.css --highlight-style kate my-file.md > my-file.html

You can use any highlight style but I like kate the best.

/*! normalize.css v7.0.0 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,footer,header,nav,section{display:block}h1{font-size:2em;margin:.67em 0}figcaption,figure,main{display:block}figure{margin:1em 40px}hr{box-sizing:content-box;height:0;overflow:visible}pre{font-family:monospace,monospace;font-size:1em}a{background-color:transparent;-webkit-text-decoration-skip:objects}abbr[title]{border-bottom:none;text-decoration:underline;text-decoration:underline dotted}b,strong{font-weight:inherit}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace,monospace;font-size:1em}dfn{font-style:italic}mark{background-color:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}audio,video{display:inline-block}audio:not([controls]){display:none;height:0}img{border-style:none}svg:not(:root){overflow:hidden}button,input,optgroup,select,textarea{font-family:sans-serif;font-size:100%;line-height:1.15;margin:0}button,input{overflow:visible}button,select{text-transform:none}[type=reset],[type=submit],button,html [type=button]{-webkit-appearance:button}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner,button::-moz-focus-inner{border-style:none;padding:0}[type=button]:-moz-focusring,[type=reset]:-moz-focusring,[type=submit]:-moz-focusring,button:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:.35em .75em .625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}progress{display:inline-block;vertical-align:baseline}textarea{overflow:auto}[type=checkbox],[type=radio]{box-sizing:border-box;padding:0}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-cancel-button,[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}details,menu{display:block}summary{display:list-item}canvas{display:inline-block}template{display:none}[hidden]{display:none}/*# sourceMappingURL=normalize.min.css.map */
html,body
{
padding: 2em;
max-width: 56em;
color: #000;
margin: auto;
}
body
{
font: 13.34px helvetica, arial, freesans, clean, sans-serif;
background: #fff;
background-color: #fff;
line-height: 1.6;
}
p
{
margin: 1em 0;
}
a
{
color: #4183c4;
text-decoration: none;
}
body > :first-child
{
margin-top: 0 !important;
}
body > :last-child
{
margin-bottom: 0 !important;
}
pre
{
background-color: #f8f8f8;
padding: 1em;
overflow: auto;
}
h1, h2, h3, h4, h5, h6
{
font-weight: 700;
cursor: text;
margin: 20px 0 10px;
padding: 0;
}
h1
{
font-size: 28px;
color: #000;
}
h2
{
font-size: 24px;
border-bottom: 1px solid #ccc;
color: #000;
}
h3
{
font-size: 18px;
color: #333;
}
h4
{
font-size: 16px;
color: #333;
}
h5
{
font-size: 14px;
color: #333;
}
h6
{
color: #777;
font-size: 14px;
}
p, blockquote, table, pre
{
margin: 15px 0;
}
hr
{
background: transparent url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAYAAAAECAYAAACtBE5DAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6OENDRjNBN0E2NTZBMTFFMEI3QjRBODM4NzJDMjlGNDgiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6OENDRjNBN0I2NTZBMTFFMEI3QjRBODM4NzJDMjlGNDgiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo4Q0NGM0E3ODY1NkExMUUwQjdCNEE4Mzg3MkMyOUY0OCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo4Q0NGM0E3OTY1NkExMUUwQjdCNEE4Mzg3MkMyOUY0OCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PqqezsUAAAAfSURBVHjaYmRABcYwBiM2QSA4y4hNEKYDQxAEAAIMAHNGAzhkPOlYAAAAAElFTkSuQmCC) repeat-x 0 0;
border: 0 none;
color: #ccc;
height: 4px;
padding: 0;
}
dl dt
{
font-size: 14px;
font-weight: 700;
font-style: italic;
margin: 15px 0 5px;
padding: 0;
}
dl dd
{
margin: 0 0 15px;
padding: 0 15px;
}
blockquote
{
border-left: 4px solid #DDD;
color: #777;
padding: 0 15px;
}
table
{
border-collapse: collapse;
border-spacing: 0;
font-size: 100%;
font: inherit;
}
table th
{
font-weight: 700;
border: 1px solid #ccc;
padding: 6px 13px;
}
table td
{
border: 1px solid #ccc;
padding: 6px 13px;
}
table tr
{
border-top: 1px solid #ccc;
background-color: #fff;
}
table tr:nth-child(2n)
{
background-color: #f8f8f8;
}
img
{
max-width: 100%;
}
code, tt
{
white-space: nowrap;
background-color: #f8f8f8;
font-family: Consolas, 'Liberation Mono', Courier, monospace;
font-size: 12px;
color: #333;
margin: 0 2px;
padding: 0 5px;
}
pre > code
{
white-space: pre;
border: 0;
background: transparent;
margin: 0;
padding: 0;
}
pre code, pre tt
{
background-color: transparent;
border: 0;
}
.poetry pre
{
font-family: Georgia, Garamond, serif!important;
font-style: italic;
font-size: 110% !important;
line-height: 1.6em;
display: block;
margin-left: 1em;
}
.poetry pre code
{
font-family: Georgia, Garamond, serif !important;
word-break: break-word;
hyphens: auto;
white-space: pre-wrap;
}
sup, sub, a.footnote
{
font-size: 1.4ex;
height: 0;
line-height: 1;
vertical-align: super;
position: relative;
}
sub
{
vertical-align: sub;
top: -1px;
}
ul, ol
{
padding-left: 30px;
}
ol li ul:first-of-type,
h1 + p, h2 + p, h3 + p, h4 + p, h5 + p, h6 + p,
ul li > :first-child,
ol li > :first-child,
dl dt > :first-child,
dl dd > :first-child,
blockquote > :first-child
{
margin-top: 0;
}
body > h2:first-child,
body > h1:first-child,
body > h1:first-child + h2,
body > h3:first-child,
body > h4:first-child,
body > h5:first-child,
body > h6:first-child,
a:first-child h1,
a:first-child h2,
a:first-child h3,
a:first-child h4,
a:first-child h5,
a:first-child h6
{
margin-top: 0;
padding-top: 0;
}
dl, dl dt:first-child
{
padding: 0;
}
dl dt > :last-child,
dl dd > :last-child,
blockquote > :last-child
{
margin-bottom: 0;
}
@media screen {
.inverted td, .inverted th
{
background: #333;
}
.inverted h2
{
border-color: #555;
}
.inverted hr
{
border-color: #777;
border-width: 1px !important;
}
::selection
{
background: rgba(157, 193, 200, 0.5);
}
h1::selection
{
background-color: rgba(45, 156, 208, 0.3);
}
h2::selection
{
background-color: rgba(90, 182, 224, 0.3);
}
h3::selection, h4::selection, h5::selection, h6::selection, li::selection, ol::selection
{
background-color: rgba(133, 201, 232, 0.3);
}
code::selection
{
background-color: rgba(0, 0, 0, 0.7);
color: #eee;
}
code span::selection
{
background-color: rgba(0, 0, 0, 0.7) !important;
color: #eee !important;
}
a::selection
{
background-color: rgba(255, 230, 102, 0.2);
}
.inverted a::selection
{
background-color: rgba(255, 230, 102, 0.6);
}
td::selection, th::selection, caption::selection
{
background-color: rgba(180, 237, 95, 0.5);
}
.inverted a
{
color: #acd1d5;
}
body.inverted,
.inverted body,
.inverted hr .inverted p,
.inverted td,
.inverted li,
.inverted h1,
.inverted h2,
.inverted h3,
.inverted h4,
.inverted h5,
.inverted h6,
.inverted th,
.inverted .math,
.inverted caption,
.inverted dd,
.inverted dt,
.inverted blockquote
{
color: #eee !important;
box-shadow: none;
border-color: #555;
}
.inverted, .inverted body
{
background: #252a2a;
}
}
@media print {
body
{
background: #fff;
border: 0;
}
img, pre, blockquote, table, figure
{
page-break-inside: avoid;
}
code
{
background-color: #fff;
color: #333 !important;
padding: 0 .2em;
}
pre
{
background: #fff;
}
pre code
{
background-color: #fff !important;
overflow: visible;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment