Skip to content

Commit

Permalink
feat: live2d
Browse files Browse the repository at this point in the history
  • Loading branch information
D-Sketon committed Jan 10, 2024
1 parent 3f81166 commit d1c96d5
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
10 changes: 10 additions & 0 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -227,8 +227,15 @@ firework:
# Experimental, may have a lot of bugs, open with caution!
pjax:
enable: false

# Experimental
serviceworker:
enable: true

# Experimental
live2d:
enable: false

# Dependent cdn links
vendor:
js:
Expand All @@ -248,6 +255,9 @@ vendor:
wow: https://unpkg.com/[email protected]/dist/wow.min.js
firework: https://www.unpkg.com/[email protected]/dist/index.umd.js
pjax: https://www.unpkg.com/[email protected]/dist/index.umd.js
live2d:
base: https://fastly.jsdelivr.net/gh/MliKiowa/plugin-live2d/
js: https://fastly.jsdelivr.net/gh/MliKiowa/plugin-live2d/js/live2d-autoload.js
css:
highlight: https://unpkg.com/[email protected]/index.css
fancybox: https://unpkg.com/@fancyapps/[email protected]/dist/jquery.fancybox.min.css
Expand Down
6 changes: 6 additions & 0 deletions layout/_partial/after-footer.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -204,3 +204,9 @@
<%- js('js/pjax.js') %>
<% } %>

<% if (theme.live2d.enable){ %>
<%- js(theme.vendor.js.live2d.js) %>
<script>
live2d.init("<%- theme.vendor.js.live2d.base %>", {themeTipsPath:""});
</script>
<% } %>

0 comments on commit d1c96d5

Please sign in to comment.