1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-07-16 00:14:34 +02:00

Desktop: Add support for multiple columns note list (#9924)

This commit is contained in:
Laurent Cozic
2024-03-02 15:29:18 +00:00
committed by GitHub
parent f19b1c5364
commit 53d5cf55bc
50 changed files with 1677 additions and 115 deletions

View File

@ -10,6 +10,7 @@ import Logger from '@joplin/utils/Logger';
import mergeGlobalAndLocalSettings from '../services/profileConfig/mergeGlobalAndLocalSettings';
import splitGlobalAndLocalSettings from '../services/profileConfig/splitGlobalAndLocalSettings';
import JoplinError from '../JoplinError';
import { defaultListColumns } from '../services/plugins/api/noteListType';
const { sprintf } = require('sprintf-js');
const ObjectUtils = require('../ObjectUtils');
const { toTitleCase } = require('../string-utils.js');
@ -964,6 +965,14 @@ class Setting extends BaseModel {
storage: SettingStorage.File,
isGlobal: true,
},
'notes.columns': {
value: defaultListColumns(),
public: false,
type: SettingItemType.Array,
storage: SettingStorage.File,
isGlobal: false,
},
'notes.sortOrder.reverse': { value: true, type: SettingItemType.Bool, storage: SettingStorage.File, isGlobal: true, section: 'note', public: true, label: () => _('Reverse sort order'), appTypes: [AppType.Cli] },
// NOTE: A setting whose name starts with 'notes.sortOrder' is special,
// which implies changing the setting automatically triggers the refresh of notes.