mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 02:16:05 +01:00 
			
		
		
		
	fix(client/ts): dropdowns not working after conversion
This commit is contained in:
		| @@ -1,5 +1,4 @@ | |||||||
| import dayjs from "dayjs"; | import dayjs from "dayjs"; | ||||||
| import { Modal } from "bootstrap"; |  | ||||||
|  |  | ||||||
| function reloadFrontendApp(reason?: string) { | function reloadFrontendApp(reason?: string) { | ||||||
|     if (reason) { |     if (reason) { | ||||||
| @@ -205,6 +204,8 @@ function getMimeTypeClass(mime: string) { | |||||||
|  |  | ||||||
| function closeActiveDialog() { | function closeActiveDialog() { | ||||||
|     if (glob.activeDialog) { |     if (glob.activeDialog) { | ||||||
|  |         // TODO: Fix once we use proper ES imports. | ||||||
|  |         //@ts-ignore | ||||||
|         Modal.getOrCreateInstance(glob.activeDialog[0]).hide(); |         Modal.getOrCreateInstance(glob.activeDialog[0]).hide(); | ||||||
|         glob.activeDialog = null; |         glob.activeDialog = null; | ||||||
|     } |     } | ||||||
| @@ -249,6 +250,8 @@ async function openDialog($dialog: JQuery<HTMLElement>, closeActDialog = true) { | |||||||
|     } |     } | ||||||
|  |  | ||||||
|     saveFocusedElement(); |     saveFocusedElement(); | ||||||
|  |     // TODO: Fix once we use proper ES imports. | ||||||
|  |     //@ts-ignore | ||||||
|     Modal.getOrCreateInstance($dialog[0]).show(); |     Modal.getOrCreateInstance($dialog[0]).show(); | ||||||
|  |  | ||||||
|     $dialog.on('hidden.bs.modal', () => { |     $dialog.on('hidden.bs.modal', () => { | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user