修复pdf生成的公式横线缺失问题

sso
anke1460 5 years ago
parent 262cafb327
commit c113e52790

@ -4,17 +4,33 @@
<meta charset="utf-8">
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.10.0-rc.1/katex.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.11.1/katex.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.11.1/katex.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.11.1/contrib/auto-render.min.js"></script>
<script>
document.addEventListener("DOMContentLoaded", function() {
renderMathInElement(document.getElementById('markdown_content'), {
displayMode: true,
delimiters: [
{left: "$$", right: "$$", display: true},
{left: "$", right: "$", display: false}
]
});
function fix_frac_line(){
var win = window;
var frac_lines = document.getElementsByClassName("frac-line");
for (var i = 0; i < frac_lines.length; i++) {
var frac = frac_lines[i];
if (win.getComputedStyle) {
style = win.getComputedStyle(frac, '');
if (style['border-bottom-width'] == '0px') {
frac.style['border-bottom-width'] = '1px';
}
}
}
};
fix_frac_line();
})
</script>
</head>

Loading…
Cancel
Save