mirror of
				https://github.com/zadam/trilium.git
				synced 2025-11-04 13:39:01 +01:00 
			
		
		
		
	relation promoted attribute has clickable button, fixes #155
This commit is contained in:
		
							parent
							
								
									406d74c4d7
								
							
						
					
					
						commit
						0aa08b1c1e
					
				@ -320,6 +320,16 @@ async function loadAttributes() {
 | 
			
		||||
 | 
			
		||||
            // no need to wait for this
 | 
			
		||||
            noteAutocompleteService.initNoteAutocomplete($input);
 | 
			
		||||
 | 
			
		||||
            // ideally we'd use link instead of button which would allow tooltip preview, but
 | 
			
		||||
            // we can't guarantee updating the link in the a element
 | 
			
		||||
            const $openButton = $("<button>").addClass("btn btn-small").text("Open").click(() => {
 | 
			
		||||
                const notePath = linkService.getNotePathFromLabel($input.val());
 | 
			
		||||
 | 
			
		||||
                treeService.activateNode(notePath);
 | 
			
		||||
            });
 | 
			
		||||
 | 
			
		||||
            $actionCell.append($openButton);
 | 
			
		||||
        }
 | 
			
		||||
        else {
 | 
			
		||||
            messagingService.logError("Unknown attribute type=" + valueAttr.type);
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user