Commit Graph

322 Commits

Author SHA1 Message Date
Cell c8d028aa0e feat(tabs): enhance tab styles and improve active code tab handling (#712)
* feat(tabs): enhance tab styles with sliding indicators and hover effects

* feat(tabs): improve active code tab handling and initialization logic
2026-03-12 11:41:52 +08:00
Cell f2c112e402 feat(code): add tabbed codeblocks support (#710) 2026-03-10 17:33:28 +08:00
Cell fe7105a38a fix: optimize TOC initialization with a timeout and clean up button spacing in decryptor 2026-03-08 17:57:41 +08:00
Cell d97e69ad0a feat(tooltip): add cell-tooltip integration for footnote references a… (#709)
* feat(tooltip): add cell-tooltip integration for footnote references and initialize tooltips

* fix(code-header): add data-ct-tooltip attribute to action buttons for better accessibility
2026-03-06 19:25:35 +08:00
Cell 98a82d845a refactor(Util): convert methods to static for better accessibility and usage 2026-03-06 10:46:47 +08:00
Cell 69d8e67c24 feat(code): add fullscreen functionality for code blocks (#707) 2026-03-03 16:15:01 +08:00
Cell 6196cd5edf feat(code): add download button for code blocks and related functionality (#706) 2026-03-02 17:34:57 +08:00
Cell 3926cc0220 refactor: reorganize CSS structure and standardize CSS variable usage for improved maintainability (#690)
* refactor: CSS variables to use fixit-var for consistency across styles

* refactor: reorganize CSS structure and consolidate imports for improved maintainability

* refactor: unify CSS variable usage and improve structure across stylesheets

* refactor: standardize CSS variable usage for layout

* refactor: standardize CSS variable usage for archive and special pages

* refactor: standardize CSS variable usage for single page

* refactor: standardize CSS variable usage for widgets

* refactor(css): refactors the border-radius mixin and adds the .rounded-full utility class

* refactor: standardize z-index usage across components

* refactor(css): removes deprecated compatibility mixins and replaces them with native CSS properties

* feat: unify color variable naming and update theme color values

- Rename `global-font-secondary-color` to `global-placeholder-color` for more accurate description of its purpose
- Update multiple style references to use the new `secondary` theme color variable
- Update theme color mapping to the new color values ​​for improved visual consistency
- Fixed the use of search box placeholder colors and removed hard-coded transparency values
- Added color preview test documentation for easier verification of color rendering
- Cleaned up some duplicate dark mode styles and replaced them with unified CSS variables

* refactor: remove the `hr-background-color` variable and uses `global-border-color` uniformly

* feat(CSE): add dark theme style to Google CSE search box and results container

* fix(task-lists): fixed styling and rendering issues with nested task lists
2026-02-28 17:24:10 +08:00
Cell 8367c13ebd fix(i): make change for FontAwesome v7
https://docs.fontawesome.com/upgrade/whats-changed/
2026-01-17 00:39:12 +08:00
Cell 536e0b171e fix: add HTMLEscape function to fix XSS attack in search feature (#687) 2026-01-16 20:02:22 +08:00
Cell fdfd772100 feat(File Tree): add file-tree shortcode support (#685)
* feat(File Tree): add `file-tree` shortcode support

* feat(file-tree): add ignoreList parameter to file-tree shortcode

* feat(file-tree): enhance file-tree shortcode with ignoreList and folderSlash options

* feat(file-tree): enhance file-tree shortcode to support data mode

* feat(file-tree): enhance file-tree shortcode to support file mode

* feat(file-tree): improve content parsing in file-tree shortcode

* feat(file-tree): improve root path validation and error handling in filesystem mode

* test(file-tree): add unit tests for `file-tree` shortcode

* feat(file-tree): add file-tree code block rendering support

* refactor(file-tree): extract filesystem scanning to get-file-tree partial

Move directory traversal and root path validation to a separate partial function,
consolidating all filesystem-related logic in one place. This simplifies the
shortcode implementation and ensures a unified data format for rendering.

* docs(readme): extend code fence and shortcode support for file tree in documentation

* feat(file-tree): add fullRootName parameter for root path display in file tree

* feat(file-tree): add language parameter to get-file-tree function

* feat(file-tree): add highlightList parameter for file-tree shortcode

* perf(file-tree): add level param for get-file-tree function to descend only level directories deep
2026-01-14 16:01:22 +08:00
Cell e87060f707 perf(search): enable anchorify for headings in search results (#672) 2025-12-31 16:43:04 +08:00
Cell 825d458222 fix(tabs): add support for Mermaid diagrams within tabs (#671) 2025-12-31 15:15:11 +08:00
Cell 10b355bdee refactor: enhance code/diagram copy button functionality and styling 2025-12-20 16:10:50 +08:00
Cell 0a614e1763 fix: improve code block handling and compatibility for non-Chromium browsers
fixes #312
// ignore-for-release
2025-12-19 17:34:53 +08:00
Cell c35dce56d0 refactor: table wrapper via table render hook
resolve #503
2025-12-19 14:10:33 +08:00
Cell e600d047da fix: code block mac mode and gist shortcode styles 2025-12-18 14:30:13 +08:00
Cell 93478b47e1 refactor: code block wrapper (#665)
* feat: optimize code highlighting for diff language

* refactor: update codeblock configuration and enhance code wrapper functionality

* fix: extra blank lines would appear when copying lines containing code highlighting

* refactor: enhance code block wrapper functionality and add new styles (mac style)

* refactor: enhance code block normal mode

* feat: do noting for code block simple mode

* feat: add copy btn for code block modes mac and simple

* refactor: add code-related variables and update styles for code blocks and gist layout

* feat: update code copy button visibility on hover for larger screens

* feat: update code block mode attribute and remove mac wrapper

* feat!: code block parameters accurate to a single

Remove the `data-open` attribute and use `.open` instead.

* refactor: enhance initCopyCode method to accept optional button parameter

* feat: improve code/diagram copy button styles and transitions for better visibility

* fix: disable copy buttons for simple/mac mode code blocks when copyable set to false

* chore: rename normal partial to code-header

* feat: add preview and expand feature for code blocks (close #312)

* fix: adjust transition timing for code header and fade-out animation

* test: update code block test case

* docs: update comments for code highlight and markup configurations

* feat: adjust code header background color darkening for light and dark themes

* fix: hide aside and breadcrumb pseudo-elements on small screens

* perf: change the code copy button and code expand button to server-side rendering

* fix: the code expand button obscured the code content

* fix: update code background and header colors for improved visibility

* fix: ensure code copy button is only added for copyable code blocks

* feat(code block): add lineNosToggler and lineWrapToggler params and feature for code blocks

* refactor: code syntax highlighting styles

* fix: update background color for line numbers and ensure proper sticky effect

* feat(code block): add support for code file names in code blocks

* fix: code review for PR #665

* feat(i18n): add Japanese and Korean translations; update toggle options in multiple languages

* docs: update configurations and comments
2025-12-17 16:56:52 +08:00
Cell 9c98f2142f fix(MathJax): parsing error after decrypting encrypted articles 2025-11-24 15:14:14 +08:00
Cell 0630497968 fix: update back-to-top button styles for better compatibility and performance 2025-11-20 16:21:07 +08:00
Cell afc8c07511 fix: update TOC drawer button visibility logic 2025-11-19 16:56:08 +08:00
Cell 237c2f3d13 feat: update TOC styles and improve active state handling in dialog 2025-11-19 16:29:58 +08:00
Cell b78f22b698 fix: remove redundant ESC key event listener for dialog 2025-11-19 14:43:43 +08:00
Cell aad75044e9 feat: implement TOC drawer feature (#657)
* feat: add toc drawer button

* feat: add TOC dialog functionality and related styles

* feat: change back-to-top button with scroll progress indicator

* feat: update color-scheme handling in theme switcher

* fix: code review for checking mistakes and optimization

* fix: the issue where the TOC was still clickable even when it was hidden.
2025-11-18 12:35:34 +08:00
Cell 113ad247de fix: add missing 'const' keyword for CACHE_VERSION declaration 2025-11-14 10:49:31 +08:00
Cell 1ba0303572 feat: enhance search functionality with additional attributes and improved anchor handling 2025-11-13 16:19:13 +08:00
Copilot 96b2f5f8ae refactor: Refactor duplicated code in theme.js (#655)
* Initial plan

* Refactor duplicated code in theme.js

- Extract highlight text logic into _applyHighlightToText helper method
- Extract search UI reset logic into _resetSearchUI helper method
- Extract content initialization logic into _initContentComponents helper method
- Extract encrypted class toggling into _toggleEncryptedClass helper method
- Reduce code duplication in initSearch, initFixItDecryptor, and init methods

Co-authored-by: Lruihao <33419593+Lruihao@users.noreply.github.com>

* Simplify _toggleEncryptedClass with boolean parameter

- Replace fromClass and toClass parameters with a single show boolean
- Hardcode class names 'encrypted-hidden' and 'decrypted-shown' in function body
- More semantic API: true to show decrypted content, false to hide
- Simplifies all 3 call sites with clearer intent

Co-authored-by: Lruihao <33419593+Lruihao@users.noreply.github.com>

* refactor: remove redundant DOMContentLoaded checks in aplayer and mermaid initialization

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Lruihao <33419593+Lruihao@users.noreply.github.com>
Co-authored-by: Cell <1024@lruihao.cn>
2025-11-13 14:46:47 +08:00
Cell fe129dd207 feat: add APlayer shortcode and audio support (#650)
* docs: improve error message clarity for shortcode parent block validation

* feat: add APlayer shortcode and audio support

* feat: support both APlayer and MetingJS

* feat: initialize APlayer when content decrypted
2025-10-21 15:47:04 +08:00
Cell 5c74d4318a fix: enhance diagram copy button functionality and ensure Echarts visibility on home page 2025-10-14 15:26:01 +08:00
Cell fa94e69877 feat: add JSON Viewer support and related configurations (#643)
* feat: add JSON Viewer support and related configurations

* feat: add JSON Viewer initialization and theme switching support
2025-10-14 15:03:45 +08:00
Cell 50488dfb51 refactor: adjust the loading order and output path of theme resources (#635)
* refactor: update config script handling to support dynamic target paths

* refactor: refactor the output paths of the script and style shortcodes, and add test cases

* fix: remove redundant console log in script-style-test.md and update MathJax and Mermaid plugin configurations in assets.html
2025-09-19 11:37:21 +08:00
Cell fde7e1cf38 fix: Params configurations case insensitive for mathjax and watermark (#633)
* refactor: set watermark config in template, change the default content to author name or site title

* fix: case insensitive for mathjax options param

* chore: fix typo
2025-09-08 16:28:08 +08:00
Cell 2d581efbc2 Feat: add layout loaders and layout configuration for Mermaid diagrams (#627) 2025-08-21 16:01:27 +08:00
Cell 841eb3d20f 🐛 Fix: add Mermaid support in home scope 2025-08-20 11:37:10 +08:00
Cell d4305d9bb2 Test: add Mermaid diagram test cases and fix configuration missing 2025-08-20 11:01:20 +08:00
Cell 77fcd7fa93 ♻️ Refactor: Mermaid theme switching again (#623) 2025-08-17 14:32:51 +08:00
Cell 3c3f6084cc 🐛 Fix: dirty hack for Mermaid loading 2025-08-14 21:29:12 +08:00
Cell e04bb611dc Feat: enhance Mermaid configuration and fix initialization bug (#617)
* 🐛 Fix: Mermaid initialization conflict error

*  Feat: enhance Mermaid configuration with security level, look, and font family options
2025-08-14 15:29:23 +08:00
Cell ba6cc4ed8e 🚚 Feat(i): rename load-mathjax.js to mathjax.js 2025-08-14 09:53:09 +08:00
Cell 7b9c3e62c7 Feat: add diagram copy button support for Mermaid and ECharts (#616) 2025-08-13 17:14:52 +08:00
Cell 311501ad6e 💄 Style: add Mermaid loading style 2025-08-13 14:06:47 +08:00
Cell fe034a2a40 🔧 Chore(i): Mermaid ZenUML is not enabled by default 2025-08-13 10:20:23 +08:00
Cell bf3fe68378 ♻️ Refactor: improve Mermaid initialize (#615) 2025-08-12 18:06:02 +08:00
Cell b27a3098ac Perf: enhance forEach method in Util class to handle asynchronous handlers 2025-08-12 17:48:52 +08:00
Cell 45f101a456 ♻️ Refactor: update layout and media styles to use fi-container class, improve Mermaid script handling (#614)
docs: https://fixit.lruihao.cn/documentation/content-management/diagrams-support/mermaid/#cdn
2025-08-12 12:04:15 +08:00
Cell a1cd700b54 🥚 Chore(i): print FixIt version in console panel 2025-07-04 16:27:33 +08:00
Cell 0ce74d82f8 ♻️ Refactor: mathematical formula render (#609)
*  Feat: add support for math passthrough render hook

*  Feat: enable copy-tex extension for KaTeX server-side render

*  Feat: enhance mathematical rendering support with KaTeX and MathJax configurations

*  Feat: add KaTeX error handling and custom macros map config

*  Feat: add MathJax client-side rendering as an alternative math engine

*  Feat: update MathJax CDN configuration and enhance asset loading parameters

* 🔥 Feat: remove unused KaTeX math rendering scripts and update KaTex

*  Feat: make \KaTeX command work in MathJax

*  Feat: update KaTeX CDN links for Twikoo integration

*  Perf: Math in content encryption

* 🐛 Fix: update class name from 'fi-row' to 'fi-raw' in raw.html shortcode

* 🐛 Fix: correct MathJax math delimiters in load-mathjax.js

*  Feat: enhance MathJax configuration with additional tex parameters and update asset handling

* 🐛 Fix: adjust KaTeX display overflow behavior
2025-06-30 12:58:48 +08:00
Cell 6eb582fef7 Feat: add async and data params for echarts shortcode (#592) 2025-04-28 14:57:58 +08:00
Cell 78971cdedb Feat: add JS code support for echarts (#582) 2025-04-26 02:56:16 +08:00
Cell f5b867d717 Feat: add echarts shortcode and code fences support JS object literal (#587) 2025-04-22 12:38:07 +08:00