mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 10:26:08 +01:00 
			
		
		
		
	hoisting support in mobile view WIP
This commit is contained in:
		| @@ -150,19 +150,11 @@ $(window).on('beforeunload', () => { | ||||
|     } | ||||
| }); | ||||
|  | ||||
| function isNotePathInAddress() { | ||||
|     const [notePath, ntxId] = treeService.getHashValueFromAddress(); | ||||
|  | ||||
|     return notePath.startsWith("root") | ||||
|         // empty string is for empty/uninitialized tab | ||||
|         || (notePath === '' && !!ntxId); | ||||
| } | ||||
|  | ||||
| $(window).on('hashchange', function() { | ||||
|     if (isNotePathInAddress()) { | ||||
|     if (treeService.isNotePathInAddress()) { | ||||
|         const [notePath, ntxId] = treeService.getHashValueFromAddress(); | ||||
|  | ||||
|         if (!notePath) { | ||||
|         if (!notePath && !ntxId) { | ||||
|             console.log(`Invalid hash value "${document.location.hash}", ignoring.`); | ||||
|             return; | ||||
|         } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user