mirror of
				https://github.com/zadam/trilium.git
				synced 2025-11-03 20:06:08 +01:00 
			
		
		
		
	fix(ck-mermaid): lazy loading if mermaid is not loaded
This commit is contained in:
		
							
								
								
									
										22
									
								
								libraries/ckeditor/ckeditor.js
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										22
									
								
								libraries/ckeditor/ckeditor.js
									
									
									
									
										vendored
									
									
								
							
										
											
												File diff suppressed because one or more lines are too long
											
										
									
								
							
										
											
												File diff suppressed because one or more lines are too long
											
										
									
								
							@@ -175,7 +175,8 @@ const editorConfig = {
 | 
				
			|||||||
        'AutoformatMath',
 | 
					        'AutoformatMath',
 | 
				
			||||||
        'indentBlockShortcutPlugin',
 | 
					        'indentBlockShortcutPlugin',
 | 
				
			||||||
        'removeFormatLinksPlugin',
 | 
					        'removeFormatLinksPlugin',
 | 
				
			||||||
        'Footnotes'
 | 
					        'Footnotes',
 | 
				
			||||||
 | 
					        'Mermaid'
 | 
				
			||||||
    ],
 | 
					    ],
 | 
				
			||||||
    toolbar: {
 | 
					    toolbar: {
 | 
				
			||||||
        items: []
 | 
					        items: []
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -257,6 +257,9 @@ export default class EditableTextTypeWidget extends AbstractTextTypeWidget {
 | 
				
			|||||||
                lazyLoad: async () => await libraryLoader.requireLibrary(libraryLoader.KATEX),
 | 
					                lazyLoad: async () => await libraryLoader.requireLibrary(libraryLoader.KATEX),
 | 
				
			||||||
                forceOutputType: false, // forces output to use outputType
 | 
					                forceOutputType: false, // forces output to use outputType
 | 
				
			||||||
                enablePreview: true // Enable preview view
 | 
					                enablePreview: true // Enable preview view
 | 
				
			||||||
 | 
					            },
 | 
				
			||||||
 | 
					            mermaid: {
 | 
				
			||||||
 | 
					                lazyLoad: async () => await libraryLoader.requireLibrary(libraryLoader.MERMAID)
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
        });
 | 
					        });
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user