Skip to content

Commit

Permalink
Remove canvas_nest
Browse files Browse the repository at this point in the history
  • Loading branch information
stevenjoezhang committed Apr 6, 2020
1 parent d6731e6 commit 632768c
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions layout/_scripts/vendors.njk
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,6 @@
{%- set js_vendors = js_vendors | attr('velocity_ui', 'velocity/velocity.ui.min.js') %}
{%- endif %}

{%- if theme.canvas_nest.enable %}
{%- if theme.canvas_nest.onmobile %}
{%- set canvas_nest_uri = theme.vendors.canvas_nest or next_vendors('canvas-nest/canvas-nest.min.js') %}
{% else %}
{%- set canvas_nest_uri = theme.vendors.canvas_nest_nomobile or next_vendors('canvas-nest/canvas-nest-nomobile.min.js') %}
{%- endif %}
<script color='{{ theme.canvas_nest.color }}' opacity='{{ theme.canvas_nest.opacity }}' zIndex='{{ theme.canvas_nest.zIndex }}' count='{{ theme.canvas_nest.count }}' src="{{ canvas_nest_uri }}"></script>
{%- endif %}

{%- if theme.canvas_ribbon.enable %}
{%- set canvas_ribbon_uri = theme.vendors.canvas_ribbon or next_vendors('canvas-ribbon/canvas-ribbon.js') %}
<script size="{{ theme.canvas_ribbon.size }}" alpha="{{ theme.canvas_ribbon.alpha }}" zIndex="{{ theme.canvas_ribbon.zIndex }}" src="{{ canvas_ribbon_uri }}"></script>
Expand Down

4 comments on commit 632768c

@pltukz
Copy link

@pltukz pltukz commented on 632768c Apr 14, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

为什么要移除nest啊,这个我好喜欢的

@stevenjoezhang
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nest 太吃 CPU 了。喜欢可以自己加。

@pltukz
Copy link

@pltukz pltukz commented on 632768c Apr 14, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

感谢答复!之前都是直接配置,说来惭愧,查了好多资料才勉强解决方案

@stevenjoezhang
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

自定义内容的文档在这(以 Live2d 为例):https://theme-next.js.org/docs/advanced-settings/custom-files.html#Live2d-Widget
可以加任意 script 标签

Please sign in to comment.