Skip to content

YunYouJun/hexo-widget-tree

main
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
js
 
 
lib
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

hexo-widget-tree

npm

δΈ­ζ–‡ζ–‡ζ‘£

Demo

Tree preview widget for hexo.

(If your theme supports ajax, it can achieve refreshless browsing)

Usage

npm install hexo-widget-tree
# yarn add hexo-widget-tree

Click the middle button on the left of the page to expand the "tree" menu.

Click the folder with the + icon to expand the menu. By clicking the folder name, you will be redirect to category page.

Options

  • cdn: true, default jsdelivr CDN.
  • hide: false, automatically hides unless you move the mouse to the middle of the left part of the page.
  • layout: Which page will code snippets being injected. More info see Injector | hexo.
  • showCount: Show number of posts in category.
  • toc: More info here.
    • enable: false, display toc for post
# You don't have to configure them.
widget_tree:
  cdn: false
  hide: false
  layout: default
  # layout:
  #   - home
  #   - page
  showCount: true
  toc:
    enable: false
    # max_depth:
    # min_depth:
    # list_number:

Features

  • Adapt for dark mode

You need data-user-color-scheme="dark" in parent node.

Dev

git clone https://github.com/YunYouJun/hexo-widget-tree

cd hexo-widget-tree
# install dependencies
npm install
npm link

# watch sass to compile
npm run dev

# start your hexo
cd your-hexo-blog
npm link hexo-widget-tree
hexo s
# We have to reload hexo server when plugin is modified.

About

🌲 Tree preview widget for hexo.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published