Likewise. I have the same setup (I based my setup on this post Manifest 5 - 2 panels in same plugin? - #4 by pklaschka). I can open and see the second panel, but it remains blank whatever I put in the tag. It’s frustrating. Is it possible to have a second panel in an InDesign plugin or not?
I suppose this is a bug.
I tried to run same plugin on both applications Photoshop and InDesign.
It works properly on Photoshop. on the other hands, on InDesign it loads only first panel.
Ah, you’ve definitely got further than I have. At a glance, your entrypoints.setup function is slightly different to mine, as are the three alternative ways of referencing the panelid in the html. I’ll see if I can now get a working version here. Thanks
OK, following your screenshots, I have a got a working version here.
One thing I have discovered (which tripped me up for a while) is that there are two ways of showing the second panel, one of which works correctly and one of which doesn’t. I have named my test plugin simply “Multipanel”. In InDesign’s Plug-Ins menu, “Multipanel” appears as a menu item with a submenu containing the labels of the two panels (“Primary” and “Secondary”). If I select “Secondary” from that submenu, the panel appears BUT is blank. If, on the other hand, I show the Plugins Panel (from the Plug-Ins menu) and click “Secondary” under “Multipanel” there, the panel shows correctly WITH its content. That looks like a bug to me – surely the two ways of showing a panel should work the same.
Anyway, thanks for the screenshots. I have at least got two panels working now. I’ll have to do some more testing to see how stable or otherwise it is – it feels flakey.
I tried this too. In my case, it also depends how the panel is opened the first time after the plugin is loaded. If I open it the first time using the plugin panel, it works. If I open via its MenuAction or the Menu, it will not load. This state will hold even if I close the panel and reopen it in any manner. This effect will also hold if I reload the plugin. It will only be possible to load it correctly after unloading the plugin, and loading it again.
First time I read about the menu action, I did not even notice that it exists.
Except for writing the minimum example I have not used the multi-panel approach. After writing few single UXP panels I’ve returned to ScriptUI (waiting for Illustrator to come along with UXP, I skipped CEP) and native plug-ins (both AI and ID).
No fixes after many months – hey, ScriptUI has bugs that date back to the move from CS to CC, that would be about a decade. Some others got addressed, though.
If you want UXP issues to get fixed, please file bug reports the way that you as developer would wish them (provide example project, detailed step-by-step instructions). Use all available channels – uservoice (for votes), and developer prerelease (for details) and leave pointers here. While I would agree on Philip’s “feels flaky”, that is nothing that would end up in a PM’s backlog.
to your manifest.json, otherwise you’re not allowed to access the plugin manager (there will be no meaningful error, uxp.pluginManager just won’t exist).
You can use a helper function like this to open a panel:
where the id is the panel id from the manifest.json.
Opening all panels on plugin load will possibly be a bad user experience, but the main panel will open anyway, and it seems to be the only way to avoid this bug.
–
Edit: I didn’t test this with an exported an installed plugin. There seem to be differences.