30 Commits

Author SHA1 Message Date
Xin
3a2ce0b5c0 fix: class selector in sidebar.js 2024-04-30 22:44:09 +01:00
Xin
55af474f51 chore: update sidebar item list and link class names 2024-04-30 22:42:04 +01:00
Xin
68e1e25119 feat: caching for sidebar items from data 2024-04-29 22:36:48 +01:00
Xin
462cc5b68d chore: add new sidebar template 2024-04-04 21:57:17 +00:00
Xin
5103da4cd5
chore: improve search bar shortcut display (#346)
* chore: improve search bar shortcut display

* chore: remove focusout handler
2024-04-01 19:34:57 +01:00
Xin
d8351aa432
feat: allow enable/disable code block copy button (#331)
* refactor: move codeblock to a partial component

* feat: add flags for code block copy button

* allow disable code copy button completely
* allow make the copy button always visible

* chore: run build:css
2024-03-28 07:32:51 +00:00
loenvom
c634cb83eb
feat: support customize flexsearch tokenize option (#319)
Co-authored-by: loenvom <loenvom@qq.com>
2024-03-17 18:50:22 +00:00
Xin
5c7303bee7
feat: add hx- prefix to Hextra Tailwind CSS classes (#300)
* feat: add prefix to tailwind css classes

* fix: remove unnecessary prefixes

* fix: add missing prefix in other places

* chore: regenerate hugo_stats.json

* chore: run `npm run build:css`

* chore: add `hx-` prefix to _index.fa.md

* fix: lang switcher display issue

* fix: add `hx-` prefix to showcase/index.fa.md

* fix: lang switch param mistake
2024-02-20 22:59:31 +00:00
c2tz
35c733b7ee
chore: increase time for "copied" animation duration (#214)
* align-logo-footer

add vertical align 2px for logo footer

* modify logo align in footer

* noobie things

* modify logo & vertical align

* build css

* revert change in icons.yaml

* increase duration for copied button effect

* Update hugo_stats.json

* Update main.css

* Update footer.html

* modify timeout to 1000 (1sec)
2023-11-21 00:07:14 +00:00
Xin
c2d7ba8ce5
fix: code copy issue for code blocks in shortcode (#201)
* chore: add translation key for copy code button title

* chore: remove id from code block elements

* fix: copy the correct code target in code-copy.js

* chore: update details.md

* chore: remove console.log :)

* chore: remove `$` in shell commands

* chore: update docs
2023-11-12 01:14:39 +00:00
Xin
363c8c91ee
fix: scroll bug due to incorrect toggle state (#186)
* fix: add mobile menu overlay to toggle body scroll

* chore: update styles
2023-11-03 20:39:36 +00:00
Xin
97e6945c04
feat: add option to set default theme and hide toggle button (#146)
resolves #135 

Light / dark theme can be configured via:

```yaml
  theme:
    # light | dark | system
    default: system
    displayToggle: true
```
2023-10-21 22:18:04 +01:00
Xin
cb09b7ce1e
fix: skip scroll event if no backToTop element (#138) 2023-10-12 23:25:34 +01:00
Xin
28a20e1e7e
chore: add code copy button icons in js (#133) 2023-10-07 20:01:19 +01:00
Remy Sheppard
d1bed05843
feat: Back To Top (#105)
* Scroll to top

* Update scripts.html

---------

Co-authored-by: Xin <xin@imfing.com>
2023-10-01 10:06:28 +01:00
Xin
ec02eb34fe
fix: search shortcut based on user platform (#101)
* fix: search shortcut based on user platform

* chore: make it work with iPad and iPhone as well
2023-09-27 19:47:20 +01:00
Xin
e9ea9786e9
feat: enhance scrollbar style (#56)
* feat: enhance scrollbar style

* chore: set `color-scheme` for document element
2023-09-14 00:01:38 +01:00
Xin
c8b1d764e0 chore: add more i18n options and update templates 2023-08-27 17:32:44 +01:00
Xin
15d3a4da5e feat: implement collapsible sidebar
chore: basic sidebar toggle button
chore: update compiled css
2023-08-20 12:29:55 +01:00
Xin
db8374a724 feat: add filetree component for shortcode
chore: update tailwind config and move hugo_stats
2023-08-16 20:44:21 +01:00
Xin
7a2cca9181 feat: add multi-language select and fix minor issues
fix: navbar icon should use home relative link

fix: copy code for raw <code> element

fix: missing breadcrumb hover style

fix: tabs typo preventing loading the script
2023-08-16 20:43:28 +01:00
Xin
3d7a4b7c99 refactor: concat built-in js scripts
chore: vendorize katex 0.16.8

chore: vendorize flexsearch 0.7.31

chore: add katex fonts

chore: vendorize mermaid

* add option to disable math globally

chore: fix edit url nil variable

chore: add comments
2023-08-16 20:43:28 +01:00
Xin
d66ae7146f fix: remove extra space for rendered link
chore: update theme info

chore: use dataset

chore: support editURL config option

* add toc and search config option

chore: update head template
2023-08-16 20:43:28 +01:00
Xin
a7aa9fa1cb feat: add blog list layout
chore: add toc to mobile dropdown menu single items

chore: refactor sidebar

chore: add single layout for blog

chore: add vscode settings

chore: add blog section

chore: add devcontainer.json

chore: exclude icon from mobile nav

chore: support multiple theme switches

- simplify theme switch implementation using data attributes
- hide theme switch when sidebar is disabled

chore: add theme switch to footer

- enable when sidebar is disabled

chore: add format-date partial
2023-08-16 20:40:00 +01:00
Xin
2f34627da3 feat: multi-level sidebar
chore: support multiple search elements

chore: sidebar display toc on mobile view

chore: add hamburger menu to navbar on mobile

chore: add markdown link hook

for opening external link in new window

chore: add sidebar footer

- put search under params.type
- make navbar link aware of external link
2023-08-16 20:39:58 +01:00
Xin
7e37b73779 feat: revamp search experience
chore: hide toc on small screen

chore: make sidebar responsive
2023-08-16 20:39:54 +01:00
Xin
16a656947b feat: basic flexsearch implementation 2023-08-16 20:39:54 +01:00
Xin
b6e0ab0872 feat: add tabs implementation
chore: use filename by default in sidebar
2023-08-16 20:39:42 +01:00
Xin
e71887d00e feat: support mermaid
feat: codeblock highlight

feat: dark mode for highlight

feat: copy button for code block

feat: support katex math rendering
2023-08-16 20:39:41 +01:00
Xin
e99f44319a feat: add theme switcher to support dark mode 2023-08-16 20:39:41 +01:00