- This is a modified version of the orginal Modern (Sans) theme by IAwriter
- Code Blocks are highlighted with highlight.js (monokai-sublime theme)
- Learn more about custom templates for IAWriter here
- Drag an drop the
sansWithHLJS.iatemplate
file into Preferences => Templates.
sansWithHLJS.iatemplate/Contents/Resources/document.html
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<link rel="stylesheet" media="all" href="normalize.css">
<link rel="stylesheet" media="all" href="core.css">
<link rel="stylesheet" media="all" href="style.css">
<link rel="stylesheet" href="hljs_styles/monokai-sublime.css"> <!--Change Theme here-->
<script src="highlight.pack.js"></script>
<script>
document.addEventListener("DOMContentLoaded", function(){
document.body.addEventListener('ia-writer-change', function(event) {
var codeBlocks = document.querySelectorAll('pre code');
[].forEach.call(codeBlocks, function(codeBlock) {
hljs.highlightBlock(codeBlock);
});
});
});
</script>
</head>
<body data-document> </body>
</html>
sansWithHLJS.iatemplate/Contents/Resources/core.css
/*...*/
pre {
padding: 1rem;
overflow: hidden;
background-color: #23241f;/*Overwrite to match momokai-sublime theme*/
}
pre code {
padding: 0;
border: transparent; /*Overwrite to match momokai-sublime theme*/
}
/*...*/