🎨 桌面端支持隐藏底部状态栏 https://github.com/siyuan-note/siyuan/issues/5292

This commit is contained in:
Liang Ding 2022-06-26 22:27:18 +08:00
parent aa691726e0
commit fa9115a081
No known key found for this signature in database
GPG key ID: 136F30F901A2231D
7 changed files with 21 additions and 1 deletions

View file

@ -147,6 +147,14 @@ export const appearance = {
<span class="fn__space"></span>
<input class="b3-switch fn__flex-center" id="nativeEmoji" type="checkbox"${window.siyuan.config.appearance.nativeEmoji ? " checked" : ""}>
</label>
<label class="fn__flex b3-label">
<div class="fn__flex-1">
${window.siyuan.languages.appearance16}
<div class="b3-label__text">${window.siyuan.languages.appearance17}</div>
</div>
<span class="fn__space"></span>
<input class="b3-switch fn__flex-center" id="hideStatusBar" type="checkbox"${window.siyuan.config.appearance.hideStatusBar ? " checked" : ""}>
</label>
<label class="fn__flex b3-label">
<div class="fn__flex-1">
${window.siyuan.languages.appearance10}
@ -231,6 +239,7 @@ export const appearance = {
customCSS: window.siyuan.config.appearance.customCSS,
closeButtonBehavior: (appearance.element.querySelector("#closeButtonBehavior") as HTMLInputElement).checked ? 1 : 0,
nativeEmoji: (appearance.element.querySelector("#nativeEmoji") as HTMLInputElement).checked,
hideStatusBar: (appearance.element.querySelector("#hideStatusBar") as HTMLInputElement).checked,
}, response => {
let needTip = false;
if (modeNumber !== window.siyuan.config.appearance.mode || themeLight !== window.siyuan.config.appearance.themeLight ||
@ -344,7 +353,7 @@ export const appearance = {
ipcRenderer.send(Constants.SIYUAN_CONFIG_CLOSE, data.closeButtonBehavior);
/// #endif
loadAssets(data);
const modeElement = document.getElementById("barThemeMode");
const modeElement = document.getElementById("barThemeMode");
if (modeElement) {
if (data.mode === 1) {
modeElement.classList.add("toolbar__item--active");

View file

@ -205,6 +205,7 @@ declare interface IWebSocketData {
}
declare interface IAppearance {
hideStatusBar: boolean,
nativeEmoji: boolean,
customCSS: boolean,
themeJS: boolean,