summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPreston Pan <ret2pop@nullring.xyz>2026-03-07 23:39:24 -0800
committerPreston Pan <ret2pop@nullring.xyz>2026-03-07 23:39:24 -0800
commit5e1742a3be5afae155fb37f1c469945d2ee0dffc (patch)
tree88b409acb39a566fb7a38f25988d3c27df12f093
parentd8f8ee32a996a4d8b8c1ac252243ae9fe009873e (diff)
fix latex block overflow mobile
l---------.pre-commit-config.yaml2
-rw-r--r--flake.nix12
m---------nix0
-rw-r--r--style.css20
4 files changed, 27 insertions, 7 deletions
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
index ced6b79..b3352a7 120000
--- a/.pre-commit-config.yaml
+++ b/.pre-commit-config.yaml
@@ -1 +1 @@
-/nix/store/0c2jj36d8x29xq9010x4j4qyl6bx4m7c-pre-commit-config.json \ No newline at end of file
+/nix/store/zlqkxn1ybpxqhdyh99xp5a2ri8sj77va-pre-commit-config.json \ No newline at end of file
diff --git a/flake.nix b/flake.nix
index ff8bc14..9d73f82 100644
--- a/flake.nix
+++ b/flake.nix
@@ -64,6 +64,12 @@ fi
RESULT_PATH=$(nix build .#website --no-link --print-out-paths)
if [ -d "$RESULT_PATH" ]; then
echo "Running lychee link check..."
+ ${pkgs.lychee}/bin/lychee --root-dir "$RESULT_PATH" \
+ --offline \
+ --verbose \
+ --no-progress \
+ --exclude-mail \
+ "$RESULT_PATH/**/*.html"
else
echo "Website build failed, skipping lychee."
exit 1
@@ -203,10 +209,13 @@ emacs -q --batch \
--eval '(setq default-directory (expand-file-name "~/monorepo"))' \
--eval '(setq org-html-link-use-abs-url nil)' \
--eval '(setq org-html-link-org-files-as-html t)' \
+ --eval '(setq vc-handled-backends nil)' \
--eval '(require (quote htmlize))' \
--eval '(require (quote nix-mode))' \
+ --eval '(setq gc-cons-threshold 100000000)' \
+ --eval '(setq make-backup-files nil auto-save-default nil create-lockfiles nil)' \
--eval '(setq org-html-htmlize-output-type (quote css))' \
- --eval '(setq org-html-head-extra "<link rel=\"stylesheet\" type=\"text/css\" href=\"/syntax.css\" />")' \
+ --eval '(setq org-html-head-extra "<link rel=\"stylesheet\" type=\"text/css\" href=\"/syntax.css\" />\n<script> window.MathJax = { tex: { tags: \"ams\", tagSide: \"left\", tagIndent: \"1em\" }, chtml: { displayAlign: \"left\", displayIndent: \"3em\" } }; </script>")' \
--eval '(org-publish-all t)' \
--eval '(org-publish-all nil)' || (echo "FAIL:" && cat /build/*.log && exit 1)
echo "Setting up Graph View..."
@@ -254,6 +263,7 @@ sha256sum installer.iso > installer.iso.sha256
${pre-commit-check.shellHook}
git config branch.main.mergeoptions "--no-ff"
alias gprune='git branch --merged | grep -v -E "^\*|main|master|dev" | xargs -r git branch -d'
+alias serve='cd result; python3 -m http.server 10005'
'';
buildInputs = [
deadnix
diff --git a/nix b/nix
-Subproject 589f94a13d2ef53ec56c3f29df4fd988e290fda
+Subproject 3563f2560116ad3d8345f34edf11ac7921c1d02
diff --git a/style.css b/style.css
index bda5c63..88760b4 100644
--- a/style.css
+++ b/style.css
@@ -337,9 +337,13 @@ li { margin: 0.3rem 0; }
mjx-container[jax="CHTML"] {
&[display="true"] {
+ display: block !important;
+ min-width: 0 !important;
+ overflow-y: hidden !important;
+ overflow-x: auto !important;
+
background: rgba(212, 163, 115, 0.05);
padding: 1.5rem;
- text-align: left !important;
border-left: 2px solid var(--accent);
margin: 2rem 0 !important;
@@ -347,10 +351,16 @@ mjx-container[jax="CHTML"] {
}
&:not([display="true"]) {
- padding: 0;
- margin: 0;
- background: transparent;
- border: none;
+ padding: 0; margin: 0; background: transparent; border: none;
+ }
+
+ & mjx-mtable {
+ margin-left: 0 !important;
+ text-align: left !important;
+ }
+
+ & mjx-mtd {
+ text-align: left !important;
}
}