mirror of
				https://github.com/TriliumNext/Notes.git
				synced 2025-10-31 21:11:30 +08:00 
			
		
		
		
	chore(client): partial integrate jquery.fancytree
This commit is contained in:
		
							parent
							
								
									3f2a0e302d
								
							
						
					
					
						commit
						23db7fe602
					
				| @ -27,6 +27,7 @@ import type { AttributeRow, BranchRow } from "../services/load_results.js"; | |||||||
| import type { SetNoteOpts } from "../components/note_context.js"; | import type { SetNoteOpts } from "../components/note_context.js"; | ||||||
| import type { TouchBarItem } from "../components/touch_bar.js"; | import type { TouchBarItem } from "../components/touch_bar.js"; | ||||||
| import type { TreeCommandNames } from "../menus/tree_context_menu.js"; | import type { TreeCommandNames } from "../menus/tree_context_menu.js"; | ||||||
|  | import "jquery.fancytree"; | ||||||
| 
 | 
 | ||||||
| const TPL = /*html*/` | const TPL = /*html*/` | ||||||
| <div class="tree-wrapper"> | <div class="tree-wrapper"> | ||||||
|  | |||||||
| @ -4,8 +4,7 @@ | |||||||
|   "description": "The server-side component of TriliumNext, which exposes the client via the web, allows for sync and provides a REST API for both internal and external use.", |   "description": "The server-side component of TriliumNext, which exposes the client via the web, allows for sync and provides a REST API for both internal and external use.", | ||||||
|   "private": true, |   "private": true, | ||||||
|   "dependencies": { |   "dependencies": { | ||||||
|     "better-sqlite3": "11.10.0", |     "better-sqlite3": "11.10.0" | ||||||
|     "jquery.fancytree": "2.38.5" |  | ||||||
|   }, |   }, | ||||||
|   "devDependencies": { |   "devDependencies": { | ||||||
|     "@electron/remote": "2.1.2", |     "@electron/remote": "2.1.2", | ||||||
|  | |||||||
| @ -39,7 +39,6 @@ | |||||||
| 
 | 
 | ||||||
| <!-- Include Fancytree library and skip --> | <!-- Include Fancytree library and skip --> | ||||||
| <link href="<%= assetPath %>/stylesheets/tree.css" rel="stylesheet"> | <link href="<%= assetPath %>/stylesheets/tree.css" rel="stylesheet"> | ||||||
| <script src="<%= assetPath %>/node_modules/jquery.fancytree/dist/jquery.fancytree-all-deps.min.js"></script> |  | ||||||
| 
 | 
 | ||||||
| <script src="<%= assetPath %>/node_modules/autocomplete.js/dist/autocomplete.jquery.min.js"></script> | <script src="<%= assetPath %>/node_modules/autocomplete.js/dist/autocomplete.jquery.min.js"></script> | ||||||
| 
 | 
 | ||||||
|  | |||||||
| @ -116,7 +116,6 @@ | |||||||
| <script src="<%= assetPath %>/node_modules/autocomplete.js/dist/autocomplete.jquery.min.js"></script> | <script src="<%= assetPath %>/node_modules/autocomplete.js/dist/autocomplete.jquery.min.js"></script> | ||||||
| 
 | 
 | ||||||
| <link href="<%= assetPath %>/stylesheets/tree.css" rel="stylesheet"> | <link href="<%= assetPath %>/stylesheets/tree.css" rel="stylesheet"> | ||||||
| <script src="<%= assetPath %>/node_modules/jquery.fancytree/dist/jquery.fancytree-all-deps.min.js"></script> |  | ||||||
| 
 | 
 | ||||||
| <script src="<%= appPath %>/runtime.js" crossorigin type="module"></script> | <script src="<%= appPath %>/runtime.js" crossorigin type="module"></script> | ||||||
| <script src="<%= appPath %>/mobile.js" crossorigin type="module"></script> | <script src="<%= appPath %>/mobile.js" crossorigin type="module"></script> | ||||||
|  | |||||||
| @ -48,8 +48,6 @@ async function register(app: express.Application) { | |||||||
|     const nodeModulesDir = isDev ? path.join(srcRoot, "..", "node_modules") : path.join(resourceDir, "node_modules"); |     const nodeModulesDir = isDev ? path.join(srcRoot, "..", "node_modules") : path.join(resourceDir, "node_modules"); | ||||||
| 
 | 
 | ||||||
|     app.use(`/${assetPath}/node_modules/jquery/dist/`, persistentCacheStatic(path.join(nodeModulesDir, "jquery/dist/"))); |     app.use(`/${assetPath}/node_modules/jquery/dist/`, persistentCacheStatic(path.join(nodeModulesDir, "jquery/dist/"))); | ||||||
| 
 |  | ||||||
|     app.use(`/${assetPath}/node_modules/jquery.fancytree/dist/`, persistentCacheStatic(path.join(nodeModulesDir, "jquery.fancytree/dist/"))); |  | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| export default { | export default { | ||||||
|  | |||||||
| @ -14,7 +14,6 @@ function buildFilesToCopy() { | |||||||
| 
 | 
 | ||||||
|   const nodePaths = [ |   const nodePaths = [ | ||||||
|     "jquery/dist", |     "jquery/dist", | ||||||
|     "jquery.fancytree/dist", |  | ||||||
| 
 | 
 | ||||||
|     // Required as they are native dependencies and cannot be well bundled.
 |     // Required as they are native dependencies and cannot be well bundled.
 | ||||||
|     "better-sqlite3", |     "better-sqlite3", | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Elian Doran
						Elian Doran