mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-21 00:50:13 +01:00
🚨
This commit is contained in:
parent
f8842918be
commit
8220bad9dd
3 changed files with 13 additions and 13 deletions
|
|
@ -497,17 +497,17 @@ export const bazaar = {
|
||||||
}, response => {
|
}, response => {
|
||||||
bazaar.element.querySelectorAll(`[data-name="${window.siyuan.config.appearance.icon}"]`).forEach(item => {
|
bazaar.element.querySelectorAll(`[data-name="${window.siyuan.config.appearance.icon}"]`).forEach(item => {
|
||||||
item.parentElement.classList.remove("b3-card--current");
|
item.parentElement.classList.remove("b3-card--current");
|
||||||
const switchElement = item.querySelector('[data-type="switch"]')
|
const switchElement = item.querySelector('[data-type="switch"]');
|
||||||
switchElement.classList.remove("fn__none");
|
switchElement.classList.remove("fn__none");
|
||||||
switchElement.previousElementSibling.classList.remove("fn__none");
|
switchElement.previousElementSibling.classList.remove("fn__none");
|
||||||
})
|
});
|
||||||
appearance.onSetappearance(response.data);
|
appearance.onSetappearance(response.data);
|
||||||
bazaar.element.querySelectorAll(`[data-name="${packageName}"]`).forEach(item => {
|
bazaar.element.querySelectorAll(`[data-name="${packageName}"]`).forEach(item => {
|
||||||
item.parentElement.classList.add("b3-card--current");
|
item.parentElement.classList.add("b3-card--current");
|
||||||
const switchElement = item.querySelector('[data-type="switch"]')
|
const switchElement = item.querySelector('[data-type="switch"]');
|
||||||
switchElement.classList.add("fn__none");
|
switchElement.classList.add("fn__none");
|
||||||
switchElement.previousElementSibling.classList.add("fn__none");
|
switchElement.previousElementSibling.classList.add("fn__none");
|
||||||
})
|
});
|
||||||
appearance.onSetappearance(response.data);
|
appearance.onSetappearance(response.data);
|
||||||
});
|
});
|
||||||
} else if (bazaarType === "themes") {
|
} else if (bazaarType === "themes") {
|
||||||
|
|
@ -535,17 +535,17 @@ export const bazaar = {
|
||||||
const oldTheme = window.siyuan.config.appearance.mode === 1 ? window.siyuan.config.appearance.themeDark : window.siyuan.config.appearance.themeLight;
|
const oldTheme = window.siyuan.config.appearance.mode === 1 ? window.siyuan.config.appearance.themeDark : window.siyuan.config.appearance.themeLight;
|
||||||
bazaar.element.querySelectorAll(`[data-name="${oldTheme}"]`).forEach(item => {
|
bazaar.element.querySelectorAll(`[data-name="${oldTheme}"]`).forEach(item => {
|
||||||
item.parentElement.classList.remove("b3-card--current");
|
item.parentElement.classList.remove("b3-card--current");
|
||||||
const switchElement = item.querySelector('[data-type="switch"]')
|
const switchElement = item.querySelector('[data-type="switch"]');
|
||||||
switchElement.classList.remove("fn__none");
|
switchElement.classList.remove("fn__none");
|
||||||
switchElement.previousElementSibling.classList.remove("fn__none");
|
switchElement.previousElementSibling.classList.remove("fn__none");
|
||||||
})
|
});
|
||||||
appearance.onSetappearance(response.data);
|
appearance.onSetappearance(response.data);
|
||||||
bazaar.element.querySelectorAll(`[data-name="${packageName}"]`).forEach(item => {
|
bazaar.element.querySelectorAll(`[data-name="${packageName}"]`).forEach(item => {
|
||||||
item.parentElement.classList.add("b3-card--current");
|
item.parentElement.classList.add("b3-card--current");
|
||||||
const switchElement = item.querySelector('[data-type="switch"]')
|
const switchElement = item.querySelector('[data-type="switch"]');
|
||||||
switchElement.classList.add("fn__none");
|
switchElement.classList.add("fn__none");
|
||||||
switchElement.previousElementSibling.classList.add("fn__none");
|
switchElement.previousElementSibling.classList.add("fn__none");
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -458,10 +458,10 @@ export class Wnd {
|
||||||
}
|
}
|
||||||
|
|
||||||
private renderTabList(event: MouseEvent) {
|
private renderTabList(event: MouseEvent) {
|
||||||
window.siyuan.menus.menu.remove()
|
window.siyuan.menus.menu.remove();
|
||||||
Array.from(this.headersElement.children).forEach((item: HTMLElement) => {
|
Array.from(this.headersElement.children).forEach((item: HTMLElement) => {
|
||||||
const iconElement = item.querySelector(".item__icon")
|
const iconElement = item.querySelector(".item__icon");
|
||||||
const graphicElement = item.querySelector(".item__graphic")
|
const graphicElement = item.querySelector(".item__graphic");
|
||||||
window.siyuan.menus.menu.append(new MenuItem({
|
window.siyuan.menus.menu.append(new MenuItem({
|
||||||
label: item.querySelector(".item__text").textContent,
|
label: item.querySelector(".item__text").textContent,
|
||||||
iconHTML: iconElement ? `<span class="b3-menu__icon">${iconElement.innerHTML}</span>` : "",
|
iconHTML: iconElement ? `<span class="b3-menu__icon">${iconElement.innerHTML}</span>` : "",
|
||||||
|
|
@ -471,7 +471,7 @@ export class Wnd {
|
||||||
},
|
},
|
||||||
current: item.classList.contains("item--focus")
|
current: item.classList.contains("item--focus")
|
||||||
}).element);
|
}).element);
|
||||||
})
|
});
|
||||||
window.siyuan.menus.menu.popup({
|
window.siyuan.menus.menu.popup({
|
||||||
x: event.clientX,
|
x: event.clientX,
|
||||||
y: event.clientY,
|
y: event.clientY,
|
||||||
|
|
|
||||||
|
|
@ -181,7 +181,7 @@ export const insertHTML = (html: string, protyle: IProtyle, isBlock = false) =>
|
||||||
doOperation.splice(index, 1);
|
doOperation.splice(index, 1);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
doOperation.push({
|
doOperation.push({
|
||||||
action: "delete",
|
action: "delete",
|
||||||
id
|
id
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue