122 Commits (24f8b36afff519514686afa01fb8fc080f4ff6f0)
 

Author SHA1 Message Date
Peter Cai e727bce188
add support for hard-coded redirects in config.json 3 years ago
Peter Cai 0c61b2085c
also note wasm-opt 3 years ago
Peter Cai 1c2aebc6a9
add note about wasm-pack 3 years ago
Peter Cai 6d8ace64f2
add npm install in documentation 3 years ago
Peter Cai 2f5e901089
document themes 3 years ago
Peter Cai 35c03f3c72
write some documentation before I forget 3 years ago
Peter Cai 6555bf4c56
theme: style quoted text 3 years ago
Peter Cai ff235b1e90
theme: style inline code elements 3 years ago
Peter Cai 43f005fd72
theme: re-format css 3 years ago
Peter Cai 397596d269
theme: style .hljs code blocks better 3 years ago
Peter Cai 1d4ba2a07b
build.rs: also re-run when theme is changed 3 years ago
Peter Cai 2ee88e11b0
drop rbtag and use our own hand-rolled implementation
because we need to update build timestamp each time anything related to
rendering is changed. The rbtag crate only supports git commit times.

Also, reproducible build isn't exactly a goal of this project.
3 years ago
Peter Cai 54ca223ed6
blog: use build timestamp as CACHE_VERSION 3 years ago
Peter Cai 311b9a0d26
hljs: binding: catch hljs errors when specifying language
the language may not exist. do not crash the entire program due to this
3 years ago
Peter Cai f519152465
integrate hljs into backend to provide code highlighting
1. Use hljs and wasm_bindgen to parse code
2. Allow the final user to choose what language to include by generating
   inline_js in build.rs for #[wasm_bindgen] (a thin wrapper around the
   raw hljs to load whatever is needed by config.json statically rather
   than dynamically)
3. Integrate the monokai color scheme into our default theme
3 years ago
Peter Cai 26bb98b11e
blog: enable all markdown extensions supported by pulldown_cmark 3 years ago
Peter Cai de8eace92e
render: use static Handlebars instance 3 years ago
Peter Cai 1f2fee8341
implement RSS feed
as an alternative common template for home page
3 years ago
Peter Cai 84ff757700
Cargo.toml: flip real optimizations on
Since I don't expect to pull in any more significant dependency, and we
are far from running out of the 1MB compressed limitation of code size,
we should be perfectly fine flipping this on instead of sticking with
optimizing for size
3 years ago
Peter Cai 90ef03daaa
theme: remove text-shadow on mobile
performance is terrible on some mobile browsers
3 years ago
Peter Cai f143deb7da
theme: kill fixed background
the performance is poor on mobile
3 years ago
Peter Cai 9077e10876
theme: support defining target=_blank in theme_config
add "target": "_blank" to the JSON
3 years ago
Peter Cai f45bd92258
theme: polish modal dialog 3 years ago
Peter Cai 38ba17019a
theme: format style 3 years ago
Peter Cai 87b332ccd2
theme: add modal to view large image 3 years ago
Peter Cai 2f2611f498
theme: style: make position sticky work correctly
Parents cannot have `overflow: hidden`.

Also removed position absolute for the wrapper and instead rely on
inline-block for horizontal center
3 years ago
Peter Cai 1c6fa0ec7d
theme: fix img width
the width of image should take padding into account
3 years ago
Peter Cai 4cd4f72e25
theme: style: make .content and .post-list look the same 3 years ago
Peter Cai f55cdf9897
theme: add mobile support 3 years ago
Peter Cai f714591b25
implement manual summary marker 3 years ago
Peter Cai 48dd6cbabc
theme: style: unify styling of headings 3 years ago
Peter Cai 9b018b559d
implement automatic anchor generation for headings 3 years ago
Peter Cai f36bfb7afa
Cargo.toml: define default build target 3 years ago
Peter Cai 23d899dd0e
support build-time theme selection via build.rs 3 years ago
Peter Cai 292b204262
theme: hide overflow-x 3 years ago
Peter Cai d8f05bad95
render: remove dummy argument in handlebars helper
turns out they just can't handle `||` -- adding a space in between fixes
the problem.
3 years ago
Peter Cai e8fdba132b
theme: style scrollbar 3 years ago
Peter Cai 269d2ad9a9
theme: show progress bar before navigating to another page 3 years ago
Peter Cai caa6775d65
theme: add loading progressbar
do not show page until at least the stylesheet is loaded
3 years ago
Peter Cai bbcb48beeb
implement post page rendering 3 years ago
Peter Cai 1110a2614b
render: implement pagination 3 years ago
Peter Cai e599007ed4
use build datetime as version string on static resources 3 years ago
Peter Cai 150940cd8c
add template and implement rendering 3 years ago
Peter Cai b2d6678405
sanitize proxied remote content response
re-construct the Response object to make sure no strange headers slip
into our own response.
3 years ago
Peter Cai d8edb51d6a
add explanation why we need a custom binding 3 years ago
Peter Cai 4474769004
proxy remote media inserted in posts
To protect user privacy and speed up page loading
3 years ago
Peter Cai 1b42c65294
blog: add more comment on PostContentCache 3 years ago
Peter Cai 2bd9b169f3
blog: add more comment on cache version 3 years ago
Peter Cai 8ba086a9ec
implement Markdown rendering 3 years ago
Peter Cai 02d64f4a18
check Cargo.lock into project
this is an end-user project even if the Rust part is built as a WASM
library.
3 years ago