mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 18:36:30 +01:00 
			
		
		
		
	feat(client): implement top launcher pane
This commit is contained in:
		| @@ -93,15 +93,18 @@ export default class DesktopLayout { | |||||||
|         appContext.noteTreeWidget = new NoteTreeWidget(); |         appContext.noteTreeWidget = new NoteTreeWidget(); | ||||||
|  |  | ||||||
|         const launcherPaneIsHorizontal = true; |         const launcherPaneIsHorizontal = true; | ||||||
|         const launcherPane = new FlexContainer("column") |         const launcherPane = new FlexContainer(launcherPaneIsHorizontal ? "row" : "column") | ||||||
|             .id("launcher-pane") |             .id("launcher-pane") | ||||||
|             .css("width", "53px") |             .css(launcherPaneIsHorizontal ? "height" : "width", "53px") | ||||||
|             .child(new GlobalMenuWidget()) |             .child(new GlobalMenuWidget()) | ||||||
|             .child(new LauncherContainer()) |             .child(new LauncherContainer(launcherPaneIsHorizontal)) | ||||||
|             .child(new LeftPaneToggleWidget()); |             .child(new LeftPaneToggleWidget()); | ||||||
|  |  | ||||||
|         return new RootContainer() |         return new RootContainer() | ||||||
|             .setParent(appContext) |             .setParent(appContext) | ||||||
|  |             .optChild(launcherPaneIsHorizontal, launcherPane) | ||||||
|  |             .child(new FlexContainer('row') | ||||||
|  |                 .css("flex-grow", "1") | ||||||
|                 .optChild(!launcherPaneIsHorizontal, launcherPane) |                 .optChild(!launcherPaneIsHorizontal, launcherPane) | ||||||
|                 .child(new LeftPaneContainer() |                 .child(new LeftPaneContainer() | ||||||
|                     .child(new QuickSearchWidget()) |                     .child(new QuickSearchWidget()) | ||||||
| @@ -203,6 +206,7 @@ export default class DesktopLayout { | |||||||
|                         ) |                         ) | ||||||
|                     ) |                     ) | ||||||
|                 ) |                 ) | ||||||
|  |             ) | ||||||
|             .child(new BulkActionsDialog()) |             .child(new BulkActionsDialog()) | ||||||
|             .child(new AboutDialog()) |             .child(new AboutDialog()) | ||||||
|             .child(new HelpDialog()) |             .child(new HelpDialog()) | ||||||
|   | |||||||
| @@ -4,11 +4,11 @@ import appContext from "../../components/app_context.js"; | |||||||
| import LauncherWidget from "./launcher.js"; | import LauncherWidget from "./launcher.js"; | ||||||
|  |  | ||||||
| export default class LauncherContainer extends FlexContainer { | export default class LauncherContainer extends FlexContainer { | ||||||
|     constructor() { |     constructor(horizontal) { | ||||||
|         super('column'); |         super(horizontal ? "row" : "column"); | ||||||
|  |  | ||||||
|         this.id('launcher-container'); |         this.id('launcher-container'); | ||||||
|         this.css('height', '100%'); |         this.css(horizontal ? "width" : 'height', '100%'); | ||||||
|         this.filling(); |         this.filling(); | ||||||
|  |  | ||||||
|         this.load(); |         this.load(); | ||||||
|   | |||||||
| @@ -2,7 +2,7 @@ import FlexContainer from "./flex_container.js"; | |||||||
|  |  | ||||||
| export default class RootContainer extends FlexContainer { | export default class RootContainer extends FlexContainer { | ||||||
|     constructor() { |     constructor() { | ||||||
|         super('row'); |         super('column'); | ||||||
|  |  | ||||||
|         this.id('root-widget'); |         this.id('root-widget'); | ||||||
|         this.css('height', '100%'); |         this.css('height', '100%'); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user