mirror of
				https://github.com/zadam/trilium.git
				synced 2025-11-04 05:28:59 +01:00 
			
		
		
		
	optimize initial render
This commit is contained in:
		
							parent
							
								
									e2f6191229
								
							
						
					
					
						commit
						48765cc87d
					
				@ -25,7 +25,6 @@ import RootContainer from "../widgets/containers/root_container.js";
 | 
			
		||||
import NoteUpdateStatusWidget from "../widgets/note_update_status.js";
 | 
			
		||||
import SpacerWidget from "../widgets/spacer.js";
 | 
			
		||||
import QuickSearchWidget from "../widgets/quick_search.js";
 | 
			
		||||
import ButtonWidget from "../widgets/buttons/button_widget.js";
 | 
			
		||||
import SplitNoteContainer from "../widgets/containers/split_note_container.js";
 | 
			
		||||
import LeftPaneToggleWidget from "../widgets/buttons/left_pane_toggle.js";
 | 
			
		||||
import CreatePaneButton from "../widgets/buttons/create_pane_button.js";
 | 
			
		||||
 | 
			
		||||
@ -111,7 +111,7 @@ export default class MobileLayout {
 | 
			
		||||
            .child(new ScreenContainer("detail", "column")
 | 
			
		||||
                .class("d-sm-flex d-md-flex d-lg-flex d-xl-flex col-12 col-sm-7 col-md-8 col-lg-8")
 | 
			
		||||
                .css('max-height', '100%')
 | 
			
		||||
                .child(new FlexContainer('row').overflowing().contentSized()
 | 
			
		||||
                .child(new FlexContainer('row').contentSized()
 | 
			
		||||
                    .css('font-size', 'larger')
 | 
			
		||||
                    .css('align-items', 'center')
 | 
			
		||||
                    .child(new MobileDetailMenuWidget().contentSized())
 | 
			
		||||
@ -124,7 +124,6 @@ export default class MobileLayout {
 | 
			
		||||
                .child(
 | 
			
		||||
                    new ScrollingContainer()
 | 
			
		||||
                        .filling()
 | 
			
		||||
                        .overflowing()
 | 
			
		||||
                        .contentSized()
 | 
			
		||||
                        .child(
 | 
			
		||||
                            new NoteDetailWidget()
 | 
			
		||||
 | 
			
		||||
@ -27,10 +27,10 @@ class AppContext extends Component {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    async start() {
 | 
			
		||||
        await Promise.all([froca.initializedPromise, options.initializedPromise]);
 | 
			
		||||
 | 
			
		||||
        this.showWidgets();
 | 
			
		||||
 | 
			
		||||
        await Promise.all([froca.initializedPromise, options.initializedPromise]);
 | 
			
		||||
 | 
			
		||||
        this.tabManager.loadTabs();
 | 
			
		||||
 | 
			
		||||
        setTimeout(() => bundleService.executeStartupBundles(), 2000);
 | 
			
		||||
 | 
			
		||||
@ -53,12 +53,6 @@ class BasicWidget extends Component {
 | 
			
		||||
        return this;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    overflowing() {
 | 
			
		||||
        console.log("Using overflowing() is deprecated NOOP and it is recommended to remove its use.");
 | 
			
		||||
 | 
			
		||||
        return this;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    collapsible() {
 | 
			
		||||
        this.css('min-height', '0');
 | 
			
		||||
        this.css('min-width', '0');
 | 
			
		||||
 | 
			
		||||
@ -2,7 +2,7 @@ import utils from "../../services/utils.js";
 | 
			
		||||
import toastService from "../../services/toast.js";
 | 
			
		||||
import TypeWidget from "./type_widget.js";
 | 
			
		||||
import libraryLoader from "../../services/library_loader.js";
 | 
			
		||||
import contextMenu from "../../services/context_menu.js";
 | 
			
		||||
import contextMenu from "../../menus/context_menu.js";
 | 
			
		||||
 | 
			
		||||
const TPL = `
 | 
			
		||||
<div class="note-detail-image note-detail-printable">
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user