mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-30 13:28:48 +01:00
This commit is contained in:
parent
a093759231
commit
9333f52edd
1 changed files with 6 additions and 2 deletions
|
|
@ -67,13 +67,13 @@ export const about = {
|
|||
<svg><use xlink:href="#iconLock"></use></svg>${window.siyuan.languages.config}
|
||||
</button>
|
||||
</label>
|
||||
<label class="b3-label fn__flex${window.siyuan.config.accessAuthCode ? "" : " fn__none"}">
|
||||
<label class="b3-label fn__flex${!window.siyuan.config.accessAuthCode || isBrowser() ? " fn__none" : ""}">
|
||||
<div class="fn__flex-1">
|
||||
${window.siyuan.languages.about7}
|
||||
<div class="b3-label__text">${window.siyuan.languages.about8}</div>
|
||||
</div>
|
||||
<div class="fn__space"></div>
|
||||
<input class="b3-switch fn__flex-center" id="lockScreenMode" type="checkbox"${window.siyuan.config.system.lockScreenMode === 0 ? " checked" : ""}>
|
||||
<input class="b3-switch fn__flex-center" id="lockScreenMode" type="checkbox"${window.siyuan.config.system.lockScreenMode === 1 ? " checked" : ""}>
|
||||
</label>
|
||||
</div>
|
||||
<label class="b3-label config__item${isBrowser() ? " fn__none" : " fn__flex"}">
|
||||
|
|
@ -310,6 +310,10 @@ export const about = {
|
|||
});
|
||||
});
|
||||
});
|
||||
const lockScreenModeElement = about.element.querySelector("#lockScreenMode") as HTMLInputElement;
|
||||
lockScreenModeElement.addEventListener("change", () => {
|
||||
fetchPost("/api/system/setFollowSystemLockScreen", {lockScreenMode: lockScreenModeElement.checked ? 1 : 0});
|
||||
});
|
||||
const googleAnalyticsElement = about.element.querySelector("#googleAnalytics") as HTMLInputElement;
|
||||
googleAnalyticsElement.addEventListener("change", () => {
|
||||
fetchPost("/api/system/setGoogleAnalytics", {googleAnalytics: googleAnalyticsElement.checked}, () => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue