mirror of
https://github.com/notion-enhancer/notion-enhancer.git
synced 2025-04-07 05:59:02 +00:00
platform-specific option overrides for features not required on macOS
This commit is contained in:
parent
bf800a0889
commit
dc60b3d9ae
@ -587,6 +587,13 @@ window['__start'] = async () => {
|
||||
const $options = mod.elem.querySelector('.options');
|
||||
if ($options)
|
||||
for (const opt of mod.options) {
|
||||
if (
|
||||
Object.keys(opt.platformOverwrite || {}).some(
|
||||
(platform) => process.platform === platform
|
||||
)
|
||||
) {
|
||||
continue;
|
||||
}
|
||||
const $opt = createOption(opt, mod.id);
|
||||
if (opt.type === 'color') {
|
||||
const $preview = $opt.querySelector('input');
|
||||
|
@ -46,6 +46,9 @@ module.exports = {
|
||||
it can be re-shown by clicking the tray icon or using the hotkey.`,
|
||||
type: 'toggle',
|
||||
value: true,
|
||||
platformOverwrite: {
|
||||
darwin: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
key: 'frameless',
|
||||
@ -53,6 +56,9 @@ module.exports = {
|
||||
description: `replace the native titlebar with buttons inset into the app.`,
|
||||
type: 'toggle',
|
||||
value: true,
|
||||
platformOverwrite: {
|
||||
darwin: false,
|
||||
},
|
||||
},
|
||||
{
|
||||
key: 'tiling_mode',
|
||||
|
@ -22,6 +22,9 @@ module.exports = {
|
||||
used to drag/move the window.`,
|
||||
type: 'input',
|
||||
value: 15,
|
||||
platformOverwrite: {
|
||||
darwin: 0,
|
||||
},
|
||||
},
|
||||
{
|
||||
key: 'responsive_breakpoint',
|
||||
|
Loading…
Reference in New Issue
Block a user