mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-29 02:28:57 +01:00 
			
		
		
		
	fix loading reference link titles in read-only text notes, closes #4404
This commit is contained in:
		
							parent
							
								
									7fc1eb5262
								
							
						
					
					
						commit
						4bdb40904f
					
				| @ -268,7 +268,9 @@ function linkContextMenu(e) { | ||||
| } | ||||
| 
 | ||||
| async function loadReferenceLinkTitle($el, href = null) { | ||||
|     href = href || $el.find("a").attr("href"); | ||||
|     const $link = $el[0].tagName === 'A' ? $el : $el.find("a"); | ||||
| 
 | ||||
|     href = href || $link.attr("href"); | ||||
|     if (!href) { | ||||
|         console.warn("Empty URL for parsing: " + $el[0].outerHTML); | ||||
|         return; | ||||
| @ -286,7 +288,7 @@ async function loadReferenceLinkTitle($el, href = null) { | ||||
| 
 | ||||
|     if (note) { | ||||
|         const icon = await getLinkIcon(noteId, viewScope.viewMode); | ||||
| 
 | ||||
| k | ||||
|         $el.prepend($("<span>").addClass(icon)); | ||||
|     } | ||||
| } | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 zadam
						zadam