From f1e60d7a09d1c2b77869435e99603f1c8b41fe71 Mon Sep 17 00:00:00 2001 From: Yuchen Pei Date: Fri, 18 Jun 2021 18:10:00 +1000 Subject: Updated. --- assets/js/analytics.js | 13 ------------- css/default.css | 2 +- publish.el | 17 ++++++++++++++++- 3 files changed, 17 insertions(+), 15 deletions(-) delete mode 100644 assets/js/analytics.js diff --git a/assets/js/analytics.js b/assets/js/analytics.js deleted file mode 100644 index 58f1074..0000000 --- a/assets/js/analytics.js +++ /dev/null @@ -1,13 +0,0 @@ - - var _paq = _paq || []; - /* tracker methods like "setCustomDimension" should be called before "trackPageView" */ - _paq.push(['trackPageView']); - _paq.push(['enableLinkTracking']); - (function() { - var u="//analytics.ypei.me/"; - _paq.push(['setTrackerUrl', u+'piwik.php']); - _paq.push(['setSiteId', '1']); - var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0]; - g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s); - })(); - diff --git a/css/default.css b/css/default.css index a48c7ba..3195780 100644 --- a/css/default.css +++ b/css/default.css @@ -38,7 +38,7 @@ header { div#content { width: 39rem; margin: auto; - margin-bottom: 3rem; + margin-bottom: 2rem; line-height: 1.6; } diff --git a/publish.el b/publish.el index 664be9a..b1f6659 100644 --- a/publish.el +++ b/publish.el @@ -78,6 +78,11 @@ PUB-DIR is when the output will be placed." (if (equal "../pages/microblog.org" (file-name-nondirectory filename)) (org-html-publish-to-html plist filename pub-dir))) +(defun my-blog-local-mathjax () + '((path "/js/MathJax.js?config=TeX-AMS-MML_HTMLorMML") + (scale "100") (align "center") (indent "2em") (tagside "right") + (mathml nil))) + (setq org-publish-project-alist '(("posts" :base-directory "posts/" @@ -96,6 +101,7 @@ PUB-DIR is when the output will be placed." :html-self-link-headlines t :author ("Yuchen Pei") :html-postamble me/html-postamble + :html-mathjax-options ((path "/js/MathJax.js?config=TeX-AMS-MML_HTMLorMML")) ) ("microposts" :base-directory "microposts/" @@ -113,6 +119,7 @@ PUB-DIR is when the output will be placed." :html-preamble me/html-preamble :author ("Yuchen Pei") :html-postamble me/html-postamble + :html-mathjax-options ((path "/js/MathJax.js?config=TeX-AMS-MML_HTMLorMML")) ) ("pages" :base-directory "pages/" @@ -126,6 +133,7 @@ PUB-DIR is when the output will be placed." :author ("Yuchen Pei") :html-postamble me/html-postamble :html-prefer-user-labels t + :html-mathjax-options ((path "/js/MathJax.js?config=TeX-AMS-MML_HTMLorMML")) ) ("css" :base-directory "css/" @@ -134,4 +142,11 @@ PUB-DIR is when the output will be placed." :publishing-function org-publish-attachment :recursive t ) - ("all" :components ("posts" "microposts" "pages" "css")))) + ("js" + :base-directory "js/" + :base-extension "js" + :publishing-directory "site/js" + :publishing-function org-publish-attachment + :recursive t + ) + ("all" :components ("posts" "microposts" "pages" "css" "js")))) -- cgit v1.2.3