mirror of
https://github.com/zadam/trilium.git
synced 2025-11-03 11:56:01 +01:00
ETAPI delete/patch, refactoring
This commit is contained in:
@@ -28,7 +28,15 @@ function initNotSyncedOptions(initialized, opts = {}) {
|
||||
optionService.createOption('lastSyncedPull', '0', false);
|
||||
optionService.createOption('lastSyncedPush', '0', false);
|
||||
|
||||
optionService.createOption('theme', opts.theme || 'white', false);
|
||||
let theme = 'dark'; // default based on the poll in https://github.com/zadam/trilium/issues/2516
|
||||
|
||||
if (utils.isElectron()) {
|
||||
const {nativeTheme} = require('electron');
|
||||
|
||||
theme = nativeTheme.shouldUseDarkColors ? 'dark' : 'light';
|
||||
}
|
||||
|
||||
optionService.createOption('theme', theme, false);
|
||||
|
||||
optionService.createOption('syncServerHost', opts.syncServerHost || '', false);
|
||||
optionService.createOption('syncServerTimeout', '120000', false);
|
||||
|
||||
Reference in New Issue
Block a user