Long files loading

Hi,

It takes too long to load some files (around 30sec). Their size is less than 1 MB. When I load such files, I also get friezes. I have discovered if there is added documentLoaded listener with instance.UI.openElements([‘notesPanel’]); instance.UI.openElements([‘thumbnailsPanel’]); inside, then load time increases up to 2 minutes. Could you find out the reason and reduce the loading time?

File for reproducing:
https://sharebox.codevog.com/download/CY5nz6pnTOZrUuaZ04kD2l_upXYtiAJvYgGuE8I9Hls

Thanks,
Martin