Skip to content

Commit

Permalink
fix(pageicons): load if enabled
Browse files Browse the repository at this point in the history
  • Loading branch information
yoyurec committed Oct 15, 2022
1 parent 0b065b2 commit 937e68d
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/modules/pageIcons/pageIcons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,10 @@ const removePageIcons = () => {
}

export const pageIconsLoad = async () => {
if (!globalContext.pluginConfig?.featurePageIconsEnabled) {
return;
}

setTagType();
setPageIcons();
setTitleIcon();
Expand Down
4 changes: 4 additions & 0 deletions src/modules/sidebarIcon/sidebarIcon.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import {
doc,
globalContext,
searchProps
} from '../internal';

Expand Down Expand Up @@ -39,6 +40,9 @@ const removeSidebarIcons = () => {
}

export const sidebarIconsLoad = async () => {
if (!globalContext.pluginConfig?.featurePageIconsEnabled) {
return;
}
setSidebarIcons();
}

Expand Down
6 changes: 5 additions & 1 deletion src/modules/tabIcon/tabIcon.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import {
doc,
searchProps,
propsObject
propsObject,
globalContext
} from '../internal';

export const setTabIcons = async () => {
Expand Down Expand Up @@ -32,6 +33,9 @@ const removeTabIcons = () => {
}

export const tabIconsLoad = async () => {
if (!globalContext.pluginConfig?.featurePageIconsEnabled) {
return;
}
setTabIcons();
}

Expand Down

0 comments on commit 937e68d

Please sign in to comment.