mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-27 01:28:59 +01:00 
			
		
		
		
	Format date and time
This commit is contained in:
		
							parent
							
								
									75941de449
								
							
						
					
					
						commit
						970c3bd7ad
					
				| @ -98,10 +98,15 @@ export default class BackupOptions extends OptionsWidget { | |||||||
|                 backupFiles = [{filePath: t('backup.no_backup_yet'), mtime: ''}]; |                 backupFiles = [{filePath: t('backup.no_backup_yet'), mtime: ''}]; | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|  |             const dateTimeFormatter = new Intl.DateTimeFormat(navigator.language, { | ||||||
|  |                 dateStyle: "medium", | ||||||
|  |                 timeStyle: "medium" | ||||||
|  |             }); | ||||||
|  | 
 | ||||||
|             for (const {filePath, mtime} of backupFiles) { |             for (const {filePath, mtime} of backupFiles) { | ||||||
|                 this.$existingBackupList.append($(` |                 this.$existingBackupList.append($(` | ||||||
|                     <tr> |                     <tr> | ||||||
|                         <td>${(mtime) ? mtime : "-"}</td> |                         <td>${(mtime) ? dateTimeFormatter.format(new Date(mtime)) : "-"}</td> | ||||||
|                         <td>${filePath}</td> |                         <td>${filePath}</td> | ||||||
|                     </tr> |                     </tr> | ||||||
|                 `));
 |                 `));
 | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Adorian Doran
						Adorian Doran