1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-11-23 22:36:32 +02:00

Desktop: Use relative time in note list for today and yesterday

This commit is contained in:
Laurent Cozic
2024-06-20 14:01:13 +01:00
parent 9eb4944614
commit 1437dd5f27
7 changed files with 134 additions and 4 deletions

View File

@@ -21,6 +21,7 @@ import BaseItem from './models/BaseItem';
import Note from './models/Note';
import Tag from './models/Tag';
import { splitCommandString } from '@joplin/utils';
import { setDateFormat, setTimeFormat, setTimeLocale } from '@joplin/utils/time';
import { reg } from './registry';
import time from './time';
import BaseSyncTarget from './BaseSyncTarget';
@@ -357,6 +358,9 @@ export default class BaseApplication {
const sideEffects: any = {
'dateFormat': async () => {
time.setLocale(Setting.value('locale'));
setTimeLocale(Setting.value('locale'));
setDateFormat(Setting.value('dateFormat'));
setTimeFormat(Setting.value('timeFormat'));
time.setDateFormat(Setting.value('dateFormat'));
time.setTimeFormat(Setting.value('timeFormat'));
},