From 1df08f1ebcc46e236f1351d48e92e723816ffdaf Mon Sep 17 00:00:00 2001 From: Preston Pan Date: Sun, 8 Mar 2026 23:41:51 -0700 Subject: mass remove headers and centralise it --- mindmap/recursion.org | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'mindmap/recursion.org') diff --git a/mindmap/recursion.org b/mindmap/recursion.org index 6dc3942..07d3eb1 100644 --- a/mindmap/recursion.org +++ b/mindmap/recursion.org @@ -3,9 +3,7 @@ :END: #+title: recursion #+author: Preston Pan -#+html_head: -#+html_head: -#+html_head: + #+startup: latexpreview #+OPTIONS: broken-links:t #+description: A description of recursive hierarchies in everything. -- cgit v1.3 From 9776145fc444bea2729efe8ee104b41b0ffe3f38 Mon Sep 17 00:00:00 2001 From: Preston Pan Date: Mon, 9 Mar 2026 18:51:40 -0700 Subject: add descriptions to everything; checkpoint --- .gitignore | 1 + config/emacs.org | 15 +- config/nix.org | 39 +- flake.nix | 21 +- img/bitcoin.png | Bin 418 -> 0 bytes img/bitcoin.webp | Bin 0 -> 3530 bytes img/churchill.png | Bin 296744 -> 0 bytes img/churchill.webp | Bin 0 -> 53174 bytes img/drawing-old.png | Bin 52643 -> 0 bytes img/drawing.png | Bin 33418 -> 0 bytes img/eth.png | Bin 419 -> 0 bytes img/eth.webp | Bin 0 -> 3584 bytes img/logo.webp | Bin 0 -> 27810 bytes img/monero.png | Bin 7547 -> 0 bytes img/monero.webp | Bin 0 -> 7452 bytes img/relativity1.jpg | Bin 99304 -> 0 bytes img/relativity1.webp | Bin 0 -> 53212 bytes img/relativity2.jpg | Bin 116362 -> 0 bytes img/relativity2.webp | Bin 0 -> 64630 bytes index.org | 20 +- mindmap/LRC circuit.org | 2 + mindmap/derivative.org | 2 +- mindmap/differential equation.org | 1 + mindmap/dirac delta.org | 1 + mindmap/divergence theorem.org | 1 + mindmap/duality.org | 1 + mindmap/egoism.org | 1 + mindmap/electrostatics.org | 1 + mindmap/emergence.org | 1 + mindmap/everything.org | 1 + mindmap/factorial.org | 1 + mindmap/framework.org | 1 + mindmap/function.org | 1 + mindmap/group.org | 1 + mindmap/index.org | 1 + mindmap/induction.org | 1 + mindmap/infinity.org | 1 + mindmap/inheritance.org | 1 + mindmap/inner product space.org | 2 +- mindmap/interpreter.org | 1 + mindmap/limit.org | 1 + mindmap/logic.org | 1 + mindmap/lrc_circuit.png | Bin 0 -> 3177 bytes mindmap/magnetostatics.org | 1 + mindmap/mathematics.org | 2 +- mindmap/metric space.org | 1 + mindmap/natural number.org | 2 +- mindmap/normed vector space.org | 1 + mindmap/partial derivative.org | 1 + mindmap/quantum mechanics.org | 1 + mindmap/recursion.org | 3 +- mindmap/self-assembly.org | 2 +- mindmap/special relativity.org | 9 +- mindmap/stack.org | 1 + mindmap/vector space.org | 1 + nix | 2 +- style.scss | 773 +++++++++++++++++--------------------- yasnippet/org-mode/blognew | 8 - 58 files changed, 469 insertions(+), 460 deletions(-) delete mode 100644 img/bitcoin.png create mode 100644 img/bitcoin.webp delete mode 100644 img/churchill.png create mode 100644 img/churchill.webp delete mode 100644 img/drawing-old.png delete mode 100644 img/drawing.png delete mode 100644 img/eth.png create mode 100644 img/eth.webp create mode 100644 img/logo.webp delete mode 100644 img/monero.png create mode 100644 img/monero.webp delete mode 100644 img/relativity1.jpg create mode 100644 img/relativity1.webp delete mode 100644 img/relativity2.jpg create mode 100644 img/relativity2.webp create mode 100644 mindmap/lrc_circuit.png (limited to 'mindmap/recursion.org') diff --git a/.gitignore b/.gitignore index 5d77956..ae58085 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ ./website/** ./result/** +style.css result .env diff --git a/config/emacs.org b/config/emacs.org index 57aae97..2d87907 100644 --- a/config/emacs.org +++ b/config/emacs.org @@ -167,8 +167,17 @@ This is my org mode configuration, which also configures latex. (org-html-with-latex 'html) (org-html-mathjax-options nil) (org-html-mathjax-template "") - (org-html-container-element "main") - (org-html-head-extra "\n\n\n\n\n\n") + (org-html-head-include-default-style nil) ; Clear Org's default CSS + (org-html-head-include-scripts nil) ; Clear Org's default JS + (org-html-divs '((preamble "header" "preamble") + (content "main" "content") + (postamble "footer" "postamble"))) + (org-html-head-extra (concat "\n\n\n\n\n\n\n\n\n\n\n" + "")) (org-latex-to-html-convert-command "printf '%%s' %i | pandoc -f latex -t html --mathml | tr -d '\\n' | sed -e 's/^

//' -e 's/<\\/p>$//'") (org-html-viewport '((width "device-width") @@ -189,7 +198,7 @@ This is my org mode configuration, which also configures latex. :html-preamble-format (("en" "

home | section main page


"))) ("website-static" :base-directory "~/monorepo" - :base-extension "css\\|js\\|png\\|jpg\\|gif\\|pdf\\|mp3\\|ogg\\|swf\\|ico\\|asc\\|pub\\|webmanifest\\|xml\\|svg\\|txt" + :base-extension "css\\|js\\|png\\|jpg\\|gif\\|pdf\\|mp3\\|ogg\\|swf\\|ico\\|asc\\|pub\\|webmanifest\\|xml\\|svg\\|txt\\|webp" :publishing-directory "~/website_html/" :recursive t :publishing-function org-publish-attachment) diff --git a/config/nix.org b/config/nix.org index e131016..a32c14d 100644 --- a/config/nix.org +++ b/config/nix.org @@ -584,6 +584,13 @@ largely self-documenting. description = "Linux timezone"; }; + ntfySecret = lib.mkOption { + type = lib.types.str; + default = "ntfy"; + example = "ntfy-env"; + description = "Name of Ntfy secret for notification handling"; + }; + monitors = lib.mkOption { type = lib.types.listOf lib.types.str; default = [ @@ -708,6 +715,7 @@ to relevant places. content = (builtins.concatStringsSep "\n" (builtins.map (x: "machine mail.${config.monorepo.vars.orgHost} login ${x}@${config.monorepo.vars.orgHost} password ${config.sops.placeholder."mail_monorepo_password_pi"}") config.monorepo.vars.projects)) + '' machine mail.${config.monorepo.vars.orgHost} login discussion@${config.monorepo.vars.orgHost} password ${config.sops.placeholder."mail_monorepo_password_pi"}''; }; + "matterbridge" = { owner = "matterbridge"; content = '' @@ -772,15 +780,19 @@ to relevant places. znc = { format = "yaml"; }; + znc_password_salt = { format = "yaml"; }; + znc_password_hash = { format = "yaml"; }; + matrix_bridge = { format = "yaml"; }; + mail_password = { format = "yaml"; owner = "maddy"; @@ -794,12 +806,15 @@ to relevant places. mautrix_env = { format = "yaml"; }; + telegram_token = { format = "yaml"; }; + discord_token = { format = "yaml"; }; + mpd_password = { format = "yaml"; owner = "nginx"; @@ -1585,12 +1600,13 @@ I want to have notifications on my phone, and run my own server to do this. let serverName = "ntfy.${config.monorepo.vars.remoteHost}"; port = 2586; - ntfySecret = "ntfy"; + ntfySecret = config.monorepo.vars.ntfySecret; in { sops.secrets."${ntfySecret}" = lib.mkIf config.services.ntfy-sh.enable { format = "yaml"; owner = "ntfy-sh"; + sopsFile = ../secrets/common_secrets.yaml; }; services.ntfy-sh = { @@ -1673,6 +1689,7 @@ to the outside world under a domain. user = "nginx"; recommendedGzipSettings = true; recommendedOptimisation = true; + recommendedBrotliSettings = true; recommendedTlsSettings = true; recommendedProxySettings = false; virtualHosts = { @@ -1682,6 +1699,18 @@ to the outside world under a domain. root = "${monorepoSelf.packages.${pkgs.system}.website}"; addSSL = true; enableACME = true; + locations."/" = { + extraConfig = '' + add_header Cache-Control "no-cache, must-revalidate"; + expires off; + ''; + }; + locations."~* \\.(?:woff2|ttf|otf|eot|woff|ico|css|js|gif|jpe?g|png|svg|mp3|mp4|iso|webmanifest)$" = { + extraConfig = '' + add_header Cache-Control "public, max-age=31536000, immutable"; + access_log off; + ''; + }; }; # the port comes from ssh tunnelling @@ -3243,6 +3272,12 @@ These are some secrets that I use regularly for my programs in home. format = "yaml"; path = "${config.sops.defaultSymlinkPath}/dn42"; }; + + ntfy = { + format = "yaml"; + path = "${config.sops.defaultSymlinkPath}/${super.monorepo.vars.ntfySecret}"; + sopsFile = ../../secrets/common_secrets.yaml; + }; } else { }; defaultSymlinkPath = "/run/user/1000/secrets"; @@ -4892,8 +4927,6 @@ This contains the installation script I use to install my systems. }; }; - users.extraUsers.root.password = "nixos"; - users.extraUsers.nixos.password = "nixos"; users.users = { root.openssh.authorizedKeys.keys = [ "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICts6+MQiMwpA+DfFQxjIN214Jn0pCw/2BDvOzPhR/H2 preston@continuity-dell" diff --git a/flake.nix b/flake.nix index b2b8e9c..e0bf9d1 100644 --- a/flake.nix +++ b/flake.nix @@ -40,10 +40,18 @@ inherit specialArgs; }; + affinity = nixmacs.nixosConfigurations.affinity.extendModules { + inherit specialArgs; + }; + installer-iso = installer.config.system.build.isoImage; spontaneityHost = spontaneity.config.monorepo.vars.orgHost; + secretsPath = affinity.config.home-manager.sops.defaultSymlinkPath; + + ntfyFile = affinity.config.monorepo.vars.ntfySecret; + topology = nixmacs.topology.x86_64-linux.config.output; pre-commit-check = git-hooks.lib.${system}.run { @@ -145,6 +153,7 @@ fi pkgs.pandoc pkgs.rsass pkgs.minify + pkgs.woff2 (pkgs.texlive.combine { inherit (pkgs.texlive) @@ -169,6 +178,7 @@ cp -a . $HOME/monorepo/ cd $HOME/monorepo mkdir -p mindmap/img rsass style.scss | minify --type=css > style.css +minify --type=css -o syntax.css syntax.css cat < $TMPDIR/policy.xml @@ -221,7 +231,8 @@ emacs -q --batch \ --eval '(require (quote htmlize))' \ --eval '(require (quote nix-mode))' \ --eval '(setq org-html-htmlize-output-type (quote css))' \ - --eval '(org-publish-all t)' || (echo "FAIL:" && cat /build/*.log && exit 1) + --eval '(org-publish-all t)' \ + --eval '(org-publish-all nil)' || (echo "FAIL:" && cat /build/*.log && exit 1) echo "Setting up Graph View..." ${publish-org-roam-ui.packages.${system}.default}/bin/build-org-roam-graph \ @@ -242,6 +253,11 @@ cp ${garamond}/ttf/CormorantGaramond-Medium.ttf $out/fonts/ cp ${garamond}/ttf/CormorantGaramond-MediumItalic.ttf $out/fonts/ cp ${garamond}/ttf/CormorantGaramond-Bold.ttf $out/fonts/ +for font in $out/fonts/*.ttf; do + woff2_compress "$font" + rm "$font" +done + cp -r $HOME/website_html/. $out/ cp ${topology}/main.svg $out/img/topology.svg cp ${installer-iso}/iso/*.iso $out/installer.iso @@ -272,12 +288,15 @@ ${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' +alias build='nix build .#website && curl -u "ret2pop:$(grep ADMIN_PASSWORD "${secretsPath}/${ntfyFile}" | cut -d "\"" -f 2)" -d "Website build done!" https://ntfy.ret2pop.net' ''; buildInputs = [ deadnix lychee python3 miniserve + rsass + imagemagickBig ]; }; }; diff --git a/img/bitcoin.png b/img/bitcoin.png deleted file mode 100644 index 55deae5..0000000 Binary files a/img/bitcoin.png and /dev/null differ diff --git a/img/bitcoin.webp b/img/bitcoin.webp new file mode 100644 index 0000000..d2d4918 Binary files /dev/null and b/img/bitcoin.webp differ diff --git a/img/churchill.png b/img/churchill.png deleted file mode 100644 index 23003ad..0000000 Binary files a/img/churchill.png and /dev/null differ diff --git a/img/churchill.webp b/img/churchill.webp new file mode 100644 index 0000000..73c21c4 Binary files /dev/null and b/img/churchill.webp differ diff --git a/img/drawing-old.png b/img/drawing-old.png deleted file mode 100644 index d2907a4..0000000 Binary files a/img/drawing-old.png and /dev/null differ diff --git a/img/drawing.png b/img/drawing.png deleted file mode 100644 index 2629939..0000000 Binary files a/img/drawing.png and /dev/null differ diff --git a/img/eth.png b/img/eth.png deleted file mode 100644 index b1b7c62..0000000 Binary files a/img/eth.png and /dev/null differ diff --git a/img/eth.webp b/img/eth.webp new file mode 100644 index 0000000..bb6a089 Binary files /dev/null and b/img/eth.webp differ diff --git a/img/logo.webp b/img/logo.webp new file mode 100644 index 0000000..51f2b1e Binary files /dev/null and b/img/logo.webp differ diff --git a/img/monero.png b/img/monero.png deleted file mode 100644 index 761f75c..0000000 Binary files a/img/monero.png and /dev/null differ diff --git a/img/monero.webp b/img/monero.webp new file mode 100644 index 0000000..38be19c Binary files /dev/null and b/img/monero.webp differ diff --git a/img/relativity1.jpg b/img/relativity1.jpg deleted file mode 100644 index e3b0a82..0000000 Binary files a/img/relativity1.jpg and /dev/null differ diff --git a/img/relativity1.webp b/img/relativity1.webp new file mode 100644 index 0000000..8432d3d Binary files /dev/null and b/img/relativity1.webp differ diff --git a/img/relativity2.jpg b/img/relativity2.jpg deleted file mode 100644 index 3455404..0000000 Binary files a/img/relativity2.jpg and /dev/null differ diff --git a/img/relativity2.webp b/img/relativity2.webp new file mode 100644 index 0000000..8df2d7c Binary files /dev/null and b/img/relativity2.webp differ diff --git a/index.org b/index.org index 9dfdf95..d844efe 100644 --- a/index.org +++ b/index.org @@ -5,10 +5,11 @@ #+language: en #+OPTIONS: broken-links:t #+OPTIONS: html-preamble:nil +#+HTML_HEAD: -#+attr_html: :width 50% +#+attr_html: :width 595 :height 746 #+caption: All Hope Abandon, Ye Who Enter Here -[[./img/drawing-old.png]] +[[./img/logo.webp]] Hello! I'm a person on the internet that does things, such as: - Music @@ -63,12 +64,10 @@ It's meant to be a general purpose mailing list as well as a collaborative space Who is the man behind ret2pop? How do you contact him? So many mysteries await… ** About this Website I wrote this website in org mode. For more information, see the [[file:README.org][README]]. Here is how I upload my -website: +website (with my nix config): #+begin_src shell :exports code :results silent -git add . -rsync -azvP --chmod="Du=rwx,Dg=rx,Do=rx,Fu=rw,Fg=r,Fo=r" ~/website_html/ root@nullring.xyz:/usr/share/nginx/ret2pop/ + remote-build preston@nullring.xyz #+end_src -Then I run magit after. * Donate If you like anything that I do, donate! But [[file:blog/crypto.org][should you use cryptocurrency]]? Should it be used as a means of exchange? Probably not, but it's cool and free for me to do so here you go. @@ -76,14 +75,16 @@ Alternatively for all of these addresses, you can use ~ret2pop.eth~, if you can ** XMR An anonymous form of ecash, the only one out of these that is actually being used for the purpose of currency (on the dark web): -[[./img/monero.png]] +#+attr_html: :width 240 :height 240 +[[./img/monero.webp]] #+begin_example 88DQVgiowjJLwsHfTaNjNgJ9Wu4Pw9msie89M2fMrTVJeDEnzqwYMQjX9nAnEDegWrU9LsJdNYp5EKkzxT73DuD6EGa9eWf #+end_example ** ETH (And associated tokens) Utility in the form of smart contracts (which are perhaps useful for something important in the future), with first mover advantage in this regard: -[[./img/eth.png]] +#+attr_html: :width 147 :height 147 +[[./img/eth.webp]] #+begin_example 0x135Ed80afB7Cd06E494e5Bb737Da8D4B23153480 #+end_example @@ -91,7 +92,8 @@ Note that this includes subprojects such as LINK which I find to have some value ** BTC The standard, and probably will continue to be used as a prediction market/speculative asset for the efficacy of other cryptocurrencies: -[[./img/bitcoin.png]] +#+attr_html: :width 147 :height 147 +[[./img/bitcoin.webp]] #+begin_example bc1qaymk2ky8unwq7jdydjw6y9a5xr9z60mkds9ttq #+end_example diff --git a/mindmap/LRC circuit.org b/mindmap/LRC circuit.org index a7686ed..f685940 100644 --- a/mindmap/LRC circuit.org +++ b/mindmap/LRC circuit.org @@ -38,6 +38,7 @@ another circuit diagram will include a possibly variable voltage source. #+end_export #+CAPTION: LRC Circuit without voltage source +#+attr_html: :width 400 :height 310 [[./lrc_circuit.png]] * Mass-Spring Equation Equivalence @@ -114,6 +115,7 @@ Here is the circuit diagram for the LRC circuit with a voltage source: #+end_export #+CAPTION: LRC Circuit +#+attr_html: :width 400 :height 319 [[./lrc_circuit_source.png]] This new [[id:4be41e2e-52b9-4cd1-ac4c-7ecb57106692][differential equation]] looks like this: \begin{align*} diff --git a/mindmap/derivative.org b/mindmap/derivative.org index 6e41443..d187b2f 100644 --- a/mindmap/derivative.org +++ b/mindmap/derivative.org @@ -3,7 +3,7 @@ :END: #+title: derivative #+author: Preston Pan - +#+description: The beginning of understanding. #+options: broken-links:t * Derivation diff --git a/mindmap/differential equation.org b/mindmap/differential equation.org index f811c26..756bf68 100644 --- a/mindmap/differential equation.org +++ b/mindmap/differential equation.org @@ -3,6 +3,7 @@ :END: #+title: differential equation #+author: Preston Pan +#+description: Do you want to model everything? #+options: broken-links:t * Introduction diff --git a/mindmap/dirac delta.org b/mindmap/dirac delta.org index 59bed32..42bec9c 100644 --- a/mindmap/dirac delta.org +++ b/mindmap/dirac delta.org @@ -3,6 +3,7 @@ :END: #+title: dirac delta #+author: Preston Pan +#+description: Essential in the theory of distributions. #+options: broken-links:t diff --git a/mindmap/divergence theorem.org b/mindmap/divergence theorem.org index e4231da..c50d7b9 100644 --- a/mindmap/divergence theorem.org +++ b/mindmap/divergence theorem.org @@ -3,6 +3,7 @@ :END: #+title: divergence theorem #+author: Preston Pan +#+description: Stokes' the flame. #+options: broken-links:t diff --git a/mindmap/duality.org b/mindmap/duality.org index a79ab7b..f3267bf 100644 --- a/mindmap/duality.org +++ b/mindmap/duality.org @@ -3,6 +3,7 @@ :END: #+title: duality #+author: Preston Pan +#+description: Are you two? #+date: <2023-06-10 Sat> * is it One or is it Two? diff --git a/mindmap/egoism.org b/mindmap/egoism.org index c0d1635..52c9efb 100644 --- a/mindmap/egoism.org +++ b/mindmap/egoism.org @@ -3,6 +3,7 @@ :END: #+title: egoism #+author: Preston Pan +#+description: I am the leopard eating your face. #+options: broken-links:t * Introduction diff --git a/mindmap/electrostatics.org b/mindmap/electrostatics.org index d2fbdde..4be25ef 100644 --- a/mindmap/electrostatics.org +++ b/mindmap/electrostatics.org @@ -3,6 +3,7 @@ :END: #+title: electrostatics #+author: Preston Pan +#+description: Let's start with the simple stuff. #+options: broken-links:t diff --git a/mindmap/emergence.org b/mindmap/emergence.org index 4797ec0..26610d5 100644 --- a/mindmap/emergence.org +++ b/mindmap/emergence.org @@ -3,6 +3,7 @@ :END: #+title: emergence #+author: Preston Pan +#+description: there's a lot of layers to this. #+options: broken-links:t diff --git a/mindmap/everything.org b/mindmap/everything.org index 5803350..d014c27 100644 --- a/mindmap/everything.org +++ b/mindmap/everything.org @@ -3,6 +3,7 @@ :END: #+title: everything #+author: Preston Pan +#+description: It's all on this page! #+date: <2023-06-10 Sat> diff --git a/mindmap/factorial.org b/mindmap/factorial.org index 72d2acc..63a3d67 100644 --- a/mindmap/factorial.org +++ b/mindmap/factorial.org @@ -3,6 +3,7 @@ :END: #+title: factorial #+author: Preston Pan +#+description: combinatorial combinations of combining other combinations. #+options: num:nil diff --git a/mindmap/framework.org b/mindmap/framework.org index f865d54..be002da 100644 --- a/mindmap/framework.org +++ b/mindmap/framework.org @@ -4,6 +4,7 @@ :END: #+title: framework #+author: Preston Pan +#+description: But isn't this just another framework? Nooooo... #+options: broken-links:t * Introduction diff --git a/mindmap/function.org b/mindmap/function.org index 9b8cdc2..5ed1efb 100644 --- a/mindmap/function.org +++ b/mindmap/function.org @@ -3,6 +3,7 @@ :END: #+title: function #+author: Preston Pan +#+description: Not the best explanation, but it functions. #+options: broken-links:t diff --git a/mindmap/group.org b/mindmap/group.org index 1b00fd1..389f67d 100644 --- a/mindmap/group.org +++ b/mindmap/group.org @@ -3,6 +3,7 @@ :END: #+title: group #+author: Preston Pan +#+description: "Get into groups of three, class" #+options: broken-links:t diff --git a/mindmap/index.org b/mindmap/index.org index 36d5fd8..6c46596 100644 --- a/mindmap/index.org +++ b/mindmap/index.org @@ -2,6 +2,7 @@ #+title: Mindmap #+author: Preston Pan #+date: <2023-06-10 Sat> +#+description: A tool for knowing everything. * Introducing: the Mindmap Do you want to know everything like me and be a smart person instead of dumb? diff --git a/mindmap/induction.org b/mindmap/induction.org index 2dec025..cf2adcf 100644 --- a/mindmap/induction.org +++ b/mindmap/induction.org @@ -3,6 +3,7 @@ :END: #+title: induction #+author: Preston Pan +#+description: I can tell you what induction is, when I have a definition for all the other words. #+options: num:nil #+options: tex:dvipng diff --git a/mindmap/infinity.org b/mindmap/infinity.org index 204502c..8208105 100644 --- a/mindmap/infinity.org +++ b/mindmap/infinity.org @@ -3,6 +3,7 @@ :END: #+title: infinity #+author: Preston Pan +#+description: What crypto bros think their ponzi will be worth. #+options: broken-links:t diff --git a/mindmap/inheritance.org b/mindmap/inheritance.org index 49cd516..aff1c92 100644 --- a/mindmap/inheritance.org +++ b/mindmap/inheritance.org @@ -3,6 +3,7 @@ :END: #+title: inheritance #+author: Preston Pan +#+description: No, not the thing I stole from your grandmother. #+options: broken-links:t diff --git a/mindmap/inner product space.org b/mindmap/inner product space.org index b5be3a5..0491b9d 100644 --- a/mindmap/inner product space.org +++ b/mindmap/inner product space.org @@ -3,7 +3,7 @@ :END: #+title: inner product space #+author: Preston Pan - +#+description: It need not be complete, without Hilbert. #+options: broken-links:t * Introduction diff --git a/mindmap/interpreter.org b/mindmap/interpreter.org index 76fb195..e34bba5 100644 --- a/mindmap/interpreter.org +++ b/mindmap/interpreter.org @@ -3,6 +3,7 @@ :END: #+title: interpreter #+author: Preston Pan +#+description: Computers understanding language. #+options: broken-links:t * Introduction diff --git a/mindmap/limit.org b/mindmap/limit.org index 2d49c74..27531a2 100644 --- a/mindmap/limit.org +++ b/mindmap/limit.org @@ -3,6 +3,7 @@ :END: #+title: limit #+author: Preston Pan +#+description: Pushing math to its limit #+options: broken-links:t diff --git a/mindmap/logic.org b/mindmap/logic.org index e96d87b..c37e868 100644 --- a/mindmap/logic.org +++ b/mindmap/logic.org @@ -3,6 +3,7 @@ :END: #+title: logic #+author: Preston Pan +#+description: A logical explanation of logic. #+options: broken-links:t diff --git a/mindmap/lrc_circuit.png b/mindmap/lrc_circuit.png new file mode 100644 index 0000000..a1790f0 Binary files /dev/null and b/mindmap/lrc_circuit.png differ diff --git a/mindmap/magnetostatics.org b/mindmap/magnetostatics.org index a543ac6..14295d4 100644 --- a/mindmap/magnetostatics.org +++ b/mindmap/magnetostatics.org @@ -3,6 +3,7 @@ :END: #+title: magnetostatics #+author: Preston Pan +#+description: A simple model of magnetism. #+options: broken-links:t diff --git a/mindmap/mathematics.org b/mindmap/mathematics.org index 2fdb11d..fcdf109 100644 --- a/mindmap/mathematics.org +++ b/mindmap/mathematics.org @@ -3,7 +3,7 @@ :END: #+title: mathematics #+author: Preston Pan - +#+description: Building frameworks for studying frameworks. * Mathematics is [[id:29ebc4f9-0fd8-4203-8bfe-84f8558e09cf][Logic]] With a couple of set theory axioms. One might describe it as an extrapolation framework diff --git a/mindmap/metric space.org b/mindmap/metric space.org index 97b08c2..2609691 100644 --- a/mindmap/metric space.org +++ b/mindmap/metric space.org @@ -4,6 +4,7 @@ :END: #+title: metric space #+author: Preston Pan +#+description: The basis of modern analysis. #+options: broken-links:t diff --git a/mindmap/natural number.org b/mindmap/natural number.org index 46d2450..8eadefb 100644 --- a/mindmap/natural number.org +++ b/mindmap/natural number.org @@ -3,7 +3,7 @@ :END: #+title: natural number #+author: Preston Pan - +#+description: How hard could counting be? * What is a Natural Number? We can formulate the natural numbers from set construction, or by Peano arithmetic. diff --git a/mindmap/normed vector space.org b/mindmap/normed vector space.org index 6e8362b..ef917fb 100644 --- a/mindmap/normed vector space.org +++ b/mindmap/normed vector space.org @@ -3,6 +3,7 @@ :END: #+title: normed vector space #+author: Preston Pan +#+description: Length matters! #+options: broken-links:t diff --git a/mindmap/partial derivative.org b/mindmap/partial derivative.org index b7ef9b0..9dd2cca 100644 --- a/mindmap/partial derivative.org +++ b/mindmap/partial derivative.org @@ -3,6 +3,7 @@ :END: #+title: partial derivative #+author: Preston Pan +#+description: Let's take a slice of a larger pie. #+options: broken-links:t diff --git a/mindmap/quantum mechanics.org b/mindmap/quantum mechanics.org index b208c49..edbc0d7 100644 --- a/mindmap/quantum mechanics.org +++ b/mindmap/quantum mechanics.org @@ -3,6 +3,7 @@ :END: #+title: quantum mechanics #+author: Preston Pan +#+description: Everything is a spectral decomposition problem. #+options: broken-links:t * Introduction diff --git a/mindmap/recursion.org b/mindmap/recursion.org index 07d3eb1..e221ac5 100644 --- a/mindmap/recursion.org +++ b/mindmap/recursion.org @@ -3,10 +3,9 @@ :END: #+title: recursion #+author: Preston Pan +#+description: A description of recursive hierarchies in everything. -#+startup: latexpreview #+OPTIONS: broken-links:t -#+description: A description of recursive hierarchies in everything. * Recursion is Recursion Exactly as I say in the title. ** but what is recursion? diff --git a/mindmap/self-assembly.org b/mindmap/self-assembly.org index 55d5b77..d736430 100644 --- a/mindmap/self-assembly.org +++ b/mindmap/self-assembly.org @@ -3,7 +3,7 @@ :END: #+title: self-assembly #+author: Preston Pan - +#+description: This article speaks for itself. * Introduction Self assembly is the process by which a system decreases entropy in its surrounding area diff --git a/mindmap/special relativity.org b/mindmap/special relativity.org index d79dfa0..aca50de 100644 --- a/mindmap/special relativity.org +++ b/mindmap/special relativity.org @@ -3,6 +3,7 @@ :END: #+title: special relativity #+author: Preston Pan +#+description: Where are you, but also at what time? #+options: broken-links:t @@ -31,15 +32,15 @@ no information can either; light in this case can be replaced with something els once the light reaches the roof from the floor, where this distance is $d$ meters, $\frac{d}{c}$ seconds will have passed for Bob. #+caption: A very scientifically accurate drawing of the situation -#+attr_html: :width 300px -[[../img/relativity1.jpg]] +#+attr_html: :width 1800 :height 1800 +[[../img/relativity1.webp]] Now this image is from Bob's perspective; when we switch to Alice's perspective, we gain a new insight; that /light has to travel the same speed for her/, but it has a larger distance to travel because of the train's velocity. #+caption: Light ray from Alice's perspective -#+attr_html: :width 300px -[[../img/relativity2.jpg]] +#+attr_html: :width 1800 :height 1800 +[[../img/relativity2.webp]] from this diagram, we can gather that the amount of time it takes for light to reach the roof will be longer. Also, we can see that if Alice believes in Bob's clock, her time would be: diff --git a/mindmap/stack.org b/mindmap/stack.org index c66e3fa..a4878f4 100644 --- a/mindmap/stack.org +++ b/mindmap/stack.org @@ -3,6 +3,7 @@ :END: #+title: stack #+author: Preston Pan +#+description: pop; ret * Introduction A stack in programming is a data structure that satisfies the following API rules: diff --git a/mindmap/vector space.org b/mindmap/vector space.org index b28877d..b58dbf1 100644 --- a/mindmap/vector space.org +++ b/mindmap/vector space.org @@ -4,6 +4,7 @@ :END: #+title: vector space #+author: Preston Pan +#+description: Everything is a vector space. If it isn't just igore it. #+options: broken-links:t diff --git a/nix b/nix index fa6c282..7e0ff16 160000 --- a/nix +++ b/nix @@ -1 +1 @@ -Subproject commit fa6c2826f9daf7a8dfb5e55793e1b30cc35430e8 +Subproject commit 7e0ff1661d94a061d0ad6db72803d211f9df4638 diff --git a/style.scss b/style.scss index 7c5e872..db04896 100644 --- a/style.scss +++ b/style.scss @@ -2,42 +2,48 @@ font-family: 'Lora'; font-style: normal; font-weight: 500; - src: url('./fonts/Lora-Medium.ttf') format('truetype'); + src: url('/fonts/Lora-Medium.woff2') format('woff2'); + font-display: swap; } @font-face { font-family: 'Inconsolata'; font-style: normal; font-weight: 400; - src: url('./fonts/Inconsolata-Regular.ttf') format('truetype'); + src: url('/fonts/Inconsolata-Regular.woff2') format('woff2'); + font-display: swap; +} + +@font-face { + font-family: 'STIX Two Math'; + font-style: normal; + font-weight: 400; + src: url('/fonts/STIXTwoMath-Regular.woff2') format('woff2'); + font-display: swap; } @font-face { font-family: 'CormorantGaramond'; font-style: normal; font-weight: 600; - src: url('./fonts/CormorantGaramond-Medium.ttf') format('truetype'); + src: url('/fonts/CormorantGaramond-Medium.woff2') format('woff2'); + font-display: swap; } @font-face { font-family: 'CormorantGaramond'; font-style: normal; font-weight: 700; - src: url('./fonts/CormorantGaramond-Bold.ttf') format('truetype'); + src: url('/fonts/CormorantGaramond-Bold.woff2') format('woff2'); + font-display: swap; } @font-face { font-family: 'CormorantGaramond'; font-style: italic; font-weight: 500; - src: url('./fonts/CormorantGaramond-MediumItalic.ttf') format('truetype'); -} - -@font-face { - font-family: 'STIX Two Math'; - font-style: normal; - font-weight: 400; - src: url('./fonts/STIXTwoMath-Regular.ttf') format('truetype'); + src: url('/fonts/CormorantGaramond-MediumItalic.woff2') format('woff2'); + font-display: swap; } @mixin hide-scrollbar { @@ -73,103 +79,35 @@ background: #ff4081; } -:not(pre) > code { - font-family: var(--font-mono), monospace; - background: var(--code-bg); - color: var(--code-text); - padding: 0.15em 0.4em; - border-radius: 4px; - font-size: 0.85em; - white-space: pre-wrap; - word-break: break-word; - box-decoration-break: clone; - - -webkit-box-decoration-break: clone; -} +*, *::before, *::after { box-sizing: border-box; } body { background: radial-gradient(rgba(0,0,0,0.02) 1px, transparent 1px), var(--bg-main); - max-width: 65ch; - line-height: 1.75; background-size: 6px 6px; - margin: 40px auto; - font-size: 16px; + margin: 0; + padding: 0; + padding-left: 250px; + color: var(--text-main); - padding: 0 10px; - - /* fonts */ + font-family: var(--font-serif), serif; font-size: 18px; - font-family: var(--font-serif); + line-height: 1.75; font-weight: 500; font-variant-ligatures: common-ligatures; -webkit-font-smoothing: antialiased; - @media (max-width: 1250px) { - margin: 20px auto; - font-size: 20px; - } - - @media (max-width: 768px) { - max-width: 100%; - padding: 0 15px; - box-sizing: border-box; - } -} - -input { - padding: 10px 16px; - margin: 2px 0; - box-sizing: border-box; - border: 2px solid #dabebe; - border-radius: 6px; - background: var(--bg-main); - color: var(--text-main); - font-size: 16px; - -webkit-transition: 0.5s; - transition: 0.5s; - outline: none; - - &:focus { border: 2px solid var(--text-main); } -} - -figure { - margin: 2rem auto; - text-align: center; -} - -p, li, blockquote, figcaption { - overflow-wrap: break-word; - word-wrap: break-word; - word-break: break-word; -} - -p, ul, ol { - margin-top: 1rem; - margin-bottom: 1rem; -} - -figcaption { - font-size: 0.9rem; - color: color-mix(in srgb, var(--text-main) 80%, gray); - margin-top: 0.5rem; -} - -h1, h2, h3 { - line-height: 1.2; - font-family: var(--font-header), serif; + display: flex; + flex-direction: column; + align-items: center; + min-height: 100vh; } -h4, h5, h6 { - font-family: var(--font-mono); - line-height: 1.3; - margin-top: 1.5rem; - margin-bottom: 0.5rem; -} +h1, h2, h3 { line-height: 1.2; font-family: var(--font-header), serif; } +h4, h5, h6 { font-family: var(--font-mono), monospace; line-height: 1.3; margin-top: 1.5rem; margin-bottom: 0.5rem; } h1, h2 { - border-bottom: 1px solid var(--border-color); padding-bottom: 8px; margin-top: 2.5rem; letter-spacing: -0.01em; @@ -183,63 +121,50 @@ h1 { font-weight: 600; letter-spacing: 0; line-height: 1.3; - -webkit-font-smoothing: antialiased; - - @media (max-width: 1250px) { font-size: 1.8rem; } -} - -h2 { - font-size: 1.6rem; - margin-top: 2.5rem; - margin-bottom: 0.6rem; - - @media (max-width: 1250px) { font-size: 18px; } - @media (max-width: 768px) { font-size: 1.5rem; } } -h3 { - font-size: 1.25rem; - font-weight: 700; - margin-top: 2rem; - margin-bottom: 0.4rem; - letter-spacing: 0.02em; -} +h2 { font-size: 1.6rem; margin-top: 2.5rem; margin-bottom: 0.6rem; } +h3 { font-size: 1.25rem; font-weight: 700; margin-top: 2rem; margin-bottom: 0.4rem; letter-spacing: 0.02em; } +h4 { font-size: 1.1rem; font-weight: 700; color: var(--text-main); } +h5 { font-size: 1rem; font-weight: 700; color: var(--link-color); } +h6 { font-size: 0.85rem; font-weight: 400; text-transform: uppercase; letter-spacing: 1px; color: color-mix(in srgb, var(--text-main) 60%, transparent); } -h4 { - font-size: 1.1rem; - font-weight: 700; - color: var(--text-main); -} +p, ul, ol { margin-top: 1rem; margin-bottom: 1rem; } +p { margin: 1.2rem 0; } +li { margin: 0.3rem 0; } -h5 { - font-size: 1rem; - font-weight: 700; +a { + cursor: pointer; color: var(--link-color); + text-decoration: underline; + text-decoration-thickness: 2px; + text-underline-offset: 4px; + transition: all 0.2s ease-in-out; + &:hover { + color: color-mix(in srgb, var(--link-color) 80%, black); + text-decoration-thickness: 4px; + } } -h6 { - font-size: 0.85rem; - font-weight: 400; - text-transform: uppercase; - letter-spacing: 1px; - color: color-mix(in srgb, var(--text-main) 60%, transparent); +figure { + margin: 2rem auto; + text-align: center; } -img, blockquote { - @media (max-width: 768px) { - max-width: 100%; - width: 100%; - box-sizing: border-box; - } +figcaption { + font-family: var(--text-serif); + font-size: 0.9rem; + color: color-mix(in srgb, var(--text-main) 80%, gray); + margin-top: 0.5rem; } img { border-radius: 10px; - text-align: center; - margin-left: auto; - margin-right: auto; - width: 50%; display: block; + margin: 2rem auto; + max-width: 50%; + width: auto; + height: auto; } blockquote { @@ -264,47 +189,25 @@ blockquote { top: -20px; opacity: 0.5; } - - &::after { content: ''; } - - @media (max-width: 768px) { - padding: 1em 15px 1em 40px; - width: 100%; - } -} - -pre { - font-family: var(--font-mono), monospace; - &.src-stem::before { content: "Stem"; } -} - -a { - cursor: pointer; - color: var(--link-color); - text-decoration: underline; - text-decoration-thickness: 2px; - text-underline-offset: 4px; - transition: all 0.2s ease-in-out; - - &:hover { - color: color-mix(in srgb, var(--link-color) 80%, black); - text-decoration-thickness: 4px; - } } -table { - display: block; - width: 100%; - overflow-x: auto; - border-collapse: collapse; - margin: 2rem 0; - - @include hide-scrollbar; +input { + padding: 10px 16px; + margin: 2px 0; + border: 2px solid #dabebe; + border-radius: 6px; + background: var(--bg-main); + color: var(--text-main); + font-size: 16px; + transition: 0.5s; + outline: none; + &:focus { border: 2px solid var(--text-main); } } math { display: inline-block; white-space: nowrap; + &[display="block"] { font-family: 'STIX Two Math', 'Latin Modern Math', serif; font-size: 1.3em; @@ -323,186 +226,84 @@ math { } } -p { margin: 1.2rem 0; } - -li { margin: 0.3rem 0; } - -.org-svg { - width: 100%; - max-width: none; +.button { + background-color: var(--bg-main); + border: none; + color: black; + padding: 6px 14px; + text-align: center; + text-decoration: none; + display: inline-block; + font-size: 16px; + margin: 4px 2px; + transition-duration: 0.4s; + cursor: pointer; + border: 2px solid var(--text-main); + border-radius: 6px; + &:hover { background-color: var(--text-main); color: white; } } -.org-src-container { - position: relative; - margin: 1.2em 0; - - pre.src { - position: relative !important; - overflow: visible !important; - background: var(--code-bg); - border-radius: 6px; - margin: 0 !important; - padding: 0 !important; - border: none !important; +header, .title + p, .subtitle + p { + margin-bottom: 3rem; + padding-bottom: 1rem; +} - & > code { - display: block; - overflow-x: auto; - padding: 1.5rem 1rem 1rem 1rem; - white-space: pre; - @include hide-scrollbar; - } +#preamble { + padding-bottom: 0 !important; +} - &::before { - content: attr(data-language); - display: block !important; - position: absolute !important; - top: 0.5rem; - right: 0.5rem; - z-index: 20; - - font-family: var(--font-mono), monospace; - font-size: 0.7rem; - color: var(--code-text); - background: var(--code-bg); - padding: 2px 8px; - border-radius: 4px; - opacity: 0.6; - pointer-events: none; - } - } +#preamble hr { + margin-bottom: 0 !important; } -.content { - margin-left: 280px; - padding: 0px 10px; +#content { + padding-top: 0 !important; +} - @media (max-width: 1250px) { margin-left: 0; } +h1.title { + padding-top: 1.5rem !important; } -.equation-container { - display: grid; - grid-template-columns: 1fr minmax(0, auto) 1fr; - align-items: center; - width: 100%; - box-sizing: border-box; +#preamble + hr, header + hr { + display: none !important; +} - margin: 2rem 0; - background: rgba(212, 163, 115, 0.05); - padding: 1.5rem; - border-left: 2px solid var(--accent); +#preamble, header { + padding-bottom: 0 !important; +} - .equation { - grid-column: 2; - text-align: center; +h1.title { + margin-top: 0.5rem; /* Reduced from 3rem */ +} - & math[display="block"] { margin: 0 !important; } - @include horizontal-scroll; - @include hide-scrollbar; - } +.title { + font-size: 2.6rem; + margin-bottom: 0.5rem; + text-align: center; +} - .equation-label { - grid-column: 3; - justify-self: end; - } +.subtitle { + display: block; + font-size: 1.2rem; + text-align: center; + font-style: italic; + margin-top: 0.5rem; + font-family: var(--font-header), serif; } -.src, .example { - position: relative; - background: var(--code-bg); - color: var(--code-text); - padding: 1rem; - border-radius: 6px; - font-size: 0.9rem; - box-shadow: none; - overflow-x: auto; - - @media (max-width: 768px) { - max-width: 100%; - box-sizing: border-box; - width: 100%; - } - - &::before { - position: absolute; - top: 0.5rem; - right: 0.5rem; - float: right; - z-index: 10; - font-family: var(--font-mono), monospace; - font-size: 0.7rem; - opacity: 0.5; - pointer-events: none; - - background: var(--code-bg); - padding: 2px 4px; - } - - @include hide-scrollbar; -} - -.theorem, .proof { +.title + .subtitle { + text-align: center; + font-style: italic; + padding-bottom: 30px; + margin-top: -10px; + color: #555; display: block; - margin-left: 10px; - font-style: normal; - background: color-mix(in srgb, var(--accent) 8%, transparent); - border-left: 3px solid var(--accent); - padding: 1rem 1.3rem; - margin: 2rem 0; - &::before { - float: left; - font-weight: bold; - } -} - -.theorem { - margin-bottom:20px; - &::before { content:"Theorem.\00a0\00a0"; } -} - -.proof { - margin-bottom:30px; - - &::after { - content: "\25FC"; - float: right; - } - - &::before { content:'Proof.\00a0\00a0'; } -} - -.links-page > ul { - columns: 2; - -webkit-columns: 2; - -moz-columns: 2; - - @media (max-width: 768px) { - columns: 1; - -webkit-columns: 1; - -moz-columns: 1; - } -} - -header, .title + p, .subtitle + p { - margin-bottom: 3rem; - border-bottom: 1px double var(--accent); - padding-bottom: 1rem; -} - -.title { - font-size: 2.6rem; - margin-bottom: 0.5rem; -} - -.subtitle { - font-size: 1.2rem; - color: color-mix(in srgb, var(--text-main) 70%, gray); } .author, .date { display: inline; - font-family: var(--font-serif); + font-family: var(--font-serif), serif; font-style: italic; font-size: 1.1rem; color: color-mix(in srgb, var(--text-main) 70%, gray); @@ -511,85 +312,26 @@ header, .title + p, .subtitle + p { .author { &::before { content: "by "; - font-family: var(--font-mono); + font-family: var(--font-mono), monospace; font-style: normal; font-weight: bold; text-transform: uppercase; font-size: 0.8rem; letter-spacing: 1px; margin-right: 4px; + text-align: center; } - - &:not(:last-child)::after { - content: ", "; - font-style: normal; - } -} - -.button { - background-color: var(--bg-main); - border: none; - color: black; - padding: 6px 14px; - text-align: center; - text-decoration: none; - display: inline-block; - font-size: 16px; - margin: 4px 2px; - transition-duration: 0.4s; - cursor: pointer; - border: 2px solid var(--text-main); - border-radius: 6px; - - &:hover { - background-color: var(--text-main); - color: white; - } -} - -.isa_info, .isa_success, .isa_warning, .isa_error { - width: 90%; - margin: 10px 0px; - padding: 12px; -} - -.isa_info { - color: #00529b; - background-color: #bde5f8; -} - -.isa_success { - color: #4f8a10; - background-color: #dff2bf; -} - -.isa_warning { - color: #9f6000; - background-color: #feefb3; -} - -.isa_error { - color: #d8000c; - background-color: #ffd2d2; -} - -.title + .subtitle { - text-align: center; - font-style: italic; - padding-bottom: 30px; - margin-top: -10px; - color: #555; - display: block; + &:not(:last-child)::after { content: ", "; font-style: normal; } } .preamble { - font-family: var(--font-mono); + font-family: var(--font-mono), monospace; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 1px; margin-top: 10px; color: color-mix(in srgb, var(--text-main) 50%, transparent); - + a { color: var(--text-main); text-decoration: none; @@ -606,13 +348,16 @@ header, .title + p, .subtitle + p { border: none; height: 1px; background: linear-gradient(to right, var(--accent), transparent); - margin-bottom: 2.5rem; + margin-bottom: 0rem; opacity: 0.5; + + width: 100%; + max-width: 85ch; } } -.todo { - font-family: var(--font-mono); +.todo, .done { + font-family: var(--font-mono), monospace; font-size: 0.75em; font-weight: bold; letter-spacing: 1px; @@ -622,16 +367,179 @@ header, .title + p, .subtitle + p { margin-right: 6px; } -.todo.TODO { - color: var(--link-color); - background-color: color-mix(in srgb, var(--accent) 20%, transparent); - border: 1px solid color-mix(in srgb, var(--accent) 50%, transparent); +.todo.TODO { + color: #5c3a21; + background-color: color-mix(in srgb, var(--accent) 30%, var(--bg-main)); + border: 1px solid var(--accent); } -.done.DONE { - color: #4f8a10; - background-color: color-mix(in srgb, var(--accent) 20%, transparent); - border: 1px solid color-mix(in srgb, var(--accent) 50%, transparent); +.done.DONE { + color: #2a3b24; + background-color: #e4e7d3; + border: 1px solid #8f9e76; +} + +.isa_info, .isa_success, .isa_warning, .isa_error { width: 90%; margin: 10px 0px; padding: 12px; } +.isa_info { color: #00529b; background-color: #bde5f8; } +.isa_success { color: #4f8a10; background-color: #dff2bf; } +.isa_warning { color: #9f6000; background-color: #feefb3; } +.isa_error { color: #d8000c; background-color: #ffd2d2; } + +.theorem, .proof { + display: block; + margin-left: 10px; + font-style: normal; + background: color-mix(in srgb, var(--accent) 8%, transparent); + border-left: 3px solid var(--accent); + padding: 1rem 1.3rem; + margin: 2rem 0; + &::before { float: left; font-weight: bold; } +} + +.theorem { margin-bottom: 20px; &::before { content: "Theorem.\00a0\00a0"; } } +.proof { margin-bottom: 30px; &::after { content: "\25FC"; float: right; } &::before { content: 'Proof.\00a0\00a0'; } } + +.links-page > ul { columns: 2; -webkit-columns: 2; -moz-columns: 2; } + +:not(pre) > code { + font-family: var(--font-mono), monospace; + background: var(--code-bg); + color: var(--code-text); + padding: 0.15em 0.4em; + border-radius: 4px; + font-size: 0.85em; + white-space: pre-wrap; + word-break: break-word; +} + +pre { + font-family: var(--font-mono), monospace; + &.src-stem::before { content: "Stem"; } +} + +.org-svg { width: 100%; max-width: none; } + +.src, .example { + @include hide-scrollbar; + @include horizontal-scroll; + + position: relative; + background: var(--code-bg); + color: var(--code-text); + padding: 1rem; + border-radius: 6px; + font-size: 0.9rem; + box-shadow: none; + + &::before { + position: absolute; + top: 0.5rem; + right: 0.5rem; + float: right; + z-index: 10; + font-family: var(--font-mono), monospace; + font-size: 0.7rem; + opacity: 0.5; + pointer-events: none; + background: var(--code-bg); + padding: 2px 4px; + } +} + +.org-src-container { + position: relative; + margin: 1.2em 0; + + pre.src { + position: relative !important; + overflow: visible !important; + background: var(--code-bg); + border-radius: 6px; + margin: 0 !important; + padding: 0 !important; + border: none !important; + + & > code { + display: block; + overflow-x: auto; + padding: 1.5rem 1rem 1rem 1rem; + white-space: pre; + @include hide-scrollbar; + } + + &::before { + content: attr(data-language); + display: block !important; + position: absolute !important; + top: 0.5rem; + right: 0.5rem; + z-index: 20; + font-family: var(--font-mono), monospace; + font-size: 0.7rem; + color: var(--code-text); + background: var(--code-bg); + padding: 2px 8px; + border-radius: 4px; + opacity: 0.6; + pointer-events: none; + } + } +} + +.equation-container { + display: grid; + grid-template-columns: 1fr minmax(0, auto) 1fr; + align-items: center; + width: 100%; + box-sizing: border-box; + + margin: 2rem 0; + background: rgba(212, 163, 115, 0.05); + padding: 1.5rem; + border-left: 2px solid var(--accent); + + .equation { + grid-column: 2; + text-align: center; + + & math[display="block"] { margin: 0 !important; } + + @include horizontal-scroll; + @include hide-scrollbar; + } + + .equation-label { + grid-column: 3; + justify-self: end; + } +} + +.figure { + margin: 2rem auto; + text-align: center; + display: flex; + flex-direction: column; + align-items: center; +} + +.figure p:last-of-type { + font-size: 0.9rem; + color: color-mix(in srgb, var(--text-main) 80%, gray); + margin-top: 0.5rem; + max-width: 80%; /* Keeps long captions from stretching too far */ +} + +.figure-number { + font-weight: 700; + color: var(--text-main); +} + + +#preamble, #content, #postamble, main, header { + width: 100%; + max-width: 85ch; + padding: 1rem 20px; + display: block; } #table-of-contents { @@ -646,12 +554,14 @@ header, .title + p, .subtitle + p { border-right: 1px solid var(--accent); overflow-y: auto; overflow-x: hidden; + + @include hide-scrollbar; &::before { content: "NAVIGATION"; display: block; padding: 24px 16px 12px 19px; - font-family: var(--font-mono); + font-family: var(--font-mono), monospace; font-size: 11px; font-weight: bold; letter-spacing: 2px; @@ -669,15 +579,14 @@ header, .title + p, .subtitle + p { display: block; width: 100%; padding: 10px 16px 10px 32px; - box-sizing: border-box; font-size: 15px; - font-family: var(--font-mono); + font-family: var(--font-mono), monospace; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1); border-left: 3px solid transparent; - opacity: 0.8; + opacity: 1; &, &:visited { color: var(--text-main); @@ -694,31 +603,47 @@ header, .title + p, .subtitle + p { ul { a { padding-left: 48px; - opacity: 0.55; + opacity: 0.85; font-size: 13px; - - &:hover { - padding-left: 38px; - opacity: 1; - } + &:hover { padding-left: 38px; opacity: 1; } } - ul a { padding-left: 64px; - opacity: 0.4; - - &:hover { - padding-left: 54px; - } + opacity: 0.75; + &:hover { padding-left: 54px; } } - } } h2 { display: none !important; } - - @media (max-width: 1250px) { display: none; } - @include hide-scrollbar; } #postamble { text-align: center; } + +@media (max-width: 1250px) { + body { + padding-left: 0; + font-size: 20px; + } + #table-of-contents { display: none !important; } + h1 { font-size: 1.8rem; } + h2 { font-size: 18px; } +} + +@media (max-width: 768px) { + h2 { font-size: 1.5rem; } + + blockquote, .src, .example { + max-width: 100%; + width: 100%; + box-sizing: border-box; + } + + img { + max-width: 100%; + width: auto; + } + + blockquote { padding: 1em 15px 1em 40px; } + .links-page > ul { columns: 1; -webkit-columns: 1; -moz-columns: 1; } +} diff --git a/yasnippet/org-mode/blognew b/yasnippet/org-mode/blognew index 1f37518..767c9d5 100644 --- a/yasnippet/org-mode/blognew +++ b/yasnippet/org-mode/blognew @@ -7,14 +7,6 @@ #+date: [`(format-time-string "%Y-%m-%d %a")`] #+subtitle: By {{{author}}}, `(format-time-string "%B %d, %Y")` #+description: $2 -#+html_head: -#+html_head: -#+html_head: -#+html_head: -#+html_head: -#+html_head: -#+html_head: -#+html_head: #+language: en #+OPTIONS: broken-links:t -- cgit v1.3