mirror of
				https://github.com/zadam/trilium.git
				synced 2025-11-04 13:39:01 +01:00 
			
		
		
		
	added "jump to note" to header
This commit is contained in:
		
							parent
							
								
									af8b26cbd5
								
							
						
					
					
						commit
						a363b43c2b
					
				@ -6,27 +6,26 @@
 | 
			
		||||
  </head>
 | 
			
		||||
  <body>
 | 
			
		||||
    <div id="container">
 | 
			
		||||
      <div id="header" class="hide-toggle" style="grid-area: header; background-color: #f1f1f1;">
 | 
			
		||||
        <div style="display: flex; align-items: center;">
 | 
			
		||||
          <div id="header-title">
 | 
			
		||||
            Trilium
 | 
			
		||||
          </div>
 | 
			
		||||
      <div id="header" class="hide-toggle">
 | 
			
		||||
        <div id="header-title">
 | 
			
		||||
          Trilium
 | 
			
		||||
        </div>
 | 
			
		||||
 | 
			
		||||
          <div style="flex-grow: 100;">
 | 
			
		||||
            <button class="btn btn-xs" onclick="showRecentChanges();">Recent changes</button>
 | 
			
		||||
            <button class="btn btn-xs" onclick="showRecentNotes();">Recent notes</button>
 | 
			
		||||
          </div>
 | 
			
		||||
        <div style="flex-grow: 100;">
 | 
			
		||||
          <button class="btn btn-xs" onclick="showRecentChanges();">Recent changes</button>
 | 
			
		||||
          <button class="btn btn-xs" onclick="showRecentNotes();">Recent notes</button>
 | 
			
		||||
          <button class="btn btn-xs" onclick="showJumpToNote();">Jump to note</button>
 | 
			
		||||
        </div>
 | 
			
		||||
 | 
			
		||||
          <div>
 | 
			
		||||
            <span id="top-message"></span>
 | 
			
		||||
            <span id="error-message"></span>
 | 
			
		||||
        <div>
 | 
			
		||||
          <span id="top-message"></span>
 | 
			
		||||
          <span id="error-message"></span>
 | 
			
		||||
 | 
			
		||||
            <button class="btn btn-xs" onclick="displaySettings();">Settings</button>
 | 
			
		||||
          <button class="btn btn-xs" onclick="displaySettings();">Settings</button>
 | 
			
		||||
 | 
			
		||||
            <form action="logout" method="POST" style="display: inline;">
 | 
			
		||||
              <input type="submit" class="btn btn-xs" value="Logout">
 | 
			
		||||
            </form>
 | 
			
		||||
          </div>
 | 
			
		||||
          <form action="logout" method="POST" style="display: inline;">
 | 
			
		||||
            <input type="submit" class="btn btn-xs" value="Logout">
 | 
			
		||||
          </form>
 | 
			
		||||
        </div>
 | 
			
		||||
      </div>
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -1,4 +1,4 @@
 | 
			
		||||
$(document).bind('keydown', 'alt+j', () => {
 | 
			
		||||
function showJumpToNote() {
 | 
			
		||||
    $("#jump-to-note-autocomplete").val('');
 | 
			
		||||
 | 
			
		||||
    $("#jump-to-note-dialog").dialog({
 | 
			
		||||
@ -10,7 +10,9 @@ $(document).bind('keydown', 'alt+j', () => {
 | 
			
		||||
        source: getAutocompleteItems(globalAllNoteIds),
 | 
			
		||||
        minLength: 0
 | 
			
		||||
    });
 | 
			
		||||
});
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
$(document).bind('keydown', 'alt+j', showJumpToNote);
 | 
			
		||||
 | 
			
		||||
$("#jump-to-note-form").submit(() => {
 | 
			
		||||
    const val = $("#jump-to-note-autocomplete").val();
 | 
			
		||||
 | 
			
		||||
@ -15,6 +15,13 @@
 | 
			
		||||
    grid-gap: 10px;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
#header {
 | 
			
		||||
    grid-area: header;
 | 
			
		||||
    background-color: #f1f1f1;
 | 
			
		||||
    display: flex;
 | 
			
		||||
    align-items: center;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
.note-editable {
 | 
			
		||||
    /* This is because with empty content height of editor is 0 and it's impossible to click into it */
 | 
			
		||||
    min-height: 400px;
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user