mirror of
				https://github.com/zadam/trilium.git
				synced 2025-11-03 20:06:08 +01:00 
			
		
		
		
	note revisions for code is now properly formatted, fixes #97
This commit is contained in:
		@@ -54,7 +54,13 @@ $list.on('change', () => {
 | 
				
			|||||||
    const revisionItem = revisionItems.find(r => r.noteRevisionId === optVal);
 | 
					    const revisionItem = revisionItems.find(r => r.noteRevisionId === optVal);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    $title.html(revisionItem.title);
 | 
					    $title.html(revisionItem.title);
 | 
				
			||||||
    $content.html(revisionItem.content);
 | 
					
 | 
				
			||||||
 | 
					    if (revisionItem.type === 'text') {
 | 
				
			||||||
 | 
					        $content.html(revisionItem.content);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    else if (revisionItem.type === 'code') {
 | 
				
			||||||
 | 
					        $content.html($("<pre>").text(revisionItem.content));
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
});
 | 
					});
 | 
				
			||||||
 | 
					
 | 
				
			||||||
$(document).on('click', "a[action='note-revision']", event => {
 | 
					$(document).on('click', "a[action='note-revision']", event => {
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user