Open corbin-lounsbury opened 7 months ago
Seconded with a new symptom:
New Dnd default character sheets (the new red ones) do not open correctly in PopOut!. There are sizing issues making it unreadable.
I am currently travelling, but will take a look tomorrow when I get home. I'd also appreciate if you are seeing this issue if you would include the operating system and browser versions you are using.
I am currently travelling, but will take a look tomorrow when I get home.
I'd also appreciate if you are seeing this issue if you would include the operating system and browser versions you are using.
Certainly! For os, do you need client, server, or both?
Am also experiencing the issue. Windows 11 Pro, Chrome Version 121.0.6167.87
I am currently travelling, but will take a look tomorrow when I get home. I'd also appreciate if you are seeing this issue if you would include the operating system and browser versions you are using.
Certainly! For os, do you need client, server, or both?
The os of the client seeing the issue please
Character Sheet v2 is also missing the tabs on the side so there is no way to navigate the sheet even if the page was aligned right.
I've done some investigation and the primary reason for the issue is the heavy use of web components by the new 5e character sheet. Unfortunately moving shadow doms between documents is even less reliable/well defined than moving normal nodes.
Specifically if a node uses constructed css via the adoptedStyleSheets API on shadow roots, it will fail when being migrated to the new window because the spec just says to fail. DOMException: Failed to set the 'adoptedStyleSheets' property on 'ShadowRoot': Sharing constructed stylesheets in multiple documents is not allowed
I believe I have found a partial work around here. However it requires that every single shadow root being migrated be created in the open format. And handled individually (it will also slow down popouts, possibly by a human noticeable amount). Unfortunately every use of the adoptedStyleSheets method in the 5e character sheet is created with a closed shadow dom.
I will play around a bit more, but at this stage I am fairly sure it is unfix-able from my end.
If someone either provides with me with a zip/build of dnd5e with the shadow roots set to open, I'd be happy to test a fix, or likewise if someone gets that changed upstream, I'll again try to fix it here.
On a more general level, the more extensive use of modern
javascript features, such as private class member variables and web components or full blown frontend frameworks (i.e. react/vue etc), in foundry, will continue to break the popout module due to it's necessarily brittle design. I'll do what I can when I can, but some things (like how tooltips are now partially broken permanently) will not be fixable.
Further testing has convinced me that there is no way to support the use of constructed stylesheets from the popout side. i.e. if someone is using constructed css they will have to implement support themselves. I'll add more detailed instructions to the readme tomorrow, but the TL;DR is
adoptedCallback
for your custom web componentnew this.ownerDocument.defaultView.CSSStyleSheet()
for explicitness.
alternatively just always use new this.ownerDocument.defaultView.CSSStyleSheet()
in the connectedCallback
A note to myself, I also need to make the bounding box algo for window size the default since the new 5e sheet has overhanging buttons.
also @corbin-lounsbury when you say "roll would not work", do you mean that for an roll link i.e. [[/r 1d20]]
clicking it doesn't work? Because in that case it is working for me as expected.
Just tested on my end. Using Firefox 122 on Windows 11
With a popped out journal, clicking a DM note to prompt or request a roll does not work for me.
I brought this issue to the attention of the developers of the dnd5e
system to see if they are open to meeting in the middle to maintain compatibility with this module. PopOut is great functionality, and it would be sad to see D&D lose the ability to open character sheets in a new window.
Context for those following at home:
https://dom.spec.whatwg.org/#concept-node-adopt-ext https://drafts.csswg.org/cssom/#extensions-to-the-document-or-shadow-root-interface
@corbin-lounsbury can you please share the actual macro being used in that document? (i.e. edit the document and copy the underlying text link)
[[/check skill=his dc=15]]
Looks like this in context
Another for the pile: I could not edit the sheet when popped out. I needed to pop it back in order to edit it
So when I first pop out the screen it looks like the picture. But when I modify the HP, the whole thing straightens out.
So when I first pop out the screen it looks like the picture. But when I modify the HP, the whole thing straightens out.
Can confirm, changing HP will fix this. Sorta. However, I noticed the Spell Slot buttons disappear when you do that. Would be nice to get a complete fix for this in general. Any updates?
I tried changing HP, made now difference for me. Chrome, FVTT 11.13, DnD 5e 3.03, latest Popout 2.16
The primary compatibility issue has been fixed in DnD 5e 3.0.4 As stated before this only works in Chrome.
I am aware that some button clicks do not work on popped out journals, I'm still trying to work out if this is fixable. Please let me know if you are seeing any other issues.
DnD 5e 3.04 is an improvement - it is at least usable. However, an issue remains with casting spells. One can hover over the name or icon for the spell, and it brings up a description (it used to turn into a die) - and one clicks on it to cast the spell (it used to be clicking on the name brought up a description). With PopOut! under DND 5e 3.04, one gets a gray box with a "wait wheel" that does not move, but one can click on the gray box to cast the spell. (probably also affects inventory and features, I suppose). But there is now no apparent way to get the description when using a PopOut! window.
I am also experiencing the above issue. Am willing to provide data or whatever else is needed to investigate. Thanks for the mod and the attention to this issue.
For those following I am aware of the ongoing issues, however I am currently traveling and am unable to replicate and debug issues. I am happy to review fixes or suggestions, but otherwise I won't be able to produce material fixes until the 28th.
Chipping in that yes, the images have all been fixed but the issue with the descriptors not populating continue (just get the grey wheel of loading death) when the new default sheet is popped out. Thanks!
Hey @Posnet have you been able to look into the description/tooltip not populating? Before i try to take a look into it i wanted to reach out to make sure it would be helpful.
@Posnet i have started looking into it, the main issue is that the tooltip is now refferenced using uuid. i have started on a fix. this solves it already for compendium items (Skills for example). for spells etc it still struggles as it requires the global CONFIG wich is set in foundry.js (and is not included in the popout)
commons.js:2955 Uncaught (in promise) ReferenceError: CONFIG is not defined
at Object.parseUuid (commons.js:2955:53)
at TooltipManager.activate (game:211:79)
at #onActivate (game:112:30)
https://github.com/briavers/fvtt-module-popout/tree/tooltip-fix
@briavers I have spent a fair amount of time trying to find work around for re-implementing the core Tooltip code a second time. But yeah like you've found it appears to be the only way. If you provide the implementation I'll happily merge it. But I'm also going to try and reach out to the foundry Devs to see if they'd be willing to un-private some of the functions.
Any further word on this functionality? I don't mean to provide any pressure, at all, I know these things always take time, and sometimes just aren't possible, but just wondering if I should be looking at alternative options for my players with multi-scrreen setups, etc.
Any further word on this functionality? I don't mean to provide any pressure, at all, I know these things always take time, and sometimes just aren't possible, but just wondering if I should be looking at alternative options for my players with multi-scrreen setups, etc.
Most of it works now but a workaround that I've used is just resize your browser window so that it fills both screens.
I have a long term fix planned for tooltips in 5e, but it is very involved, and I have very little time available to work on it. The basic sketch of the implementation in on https://github.com/League-of-Foundry-Developers/fvtt-module-popout/pull/124 if someone wants to contribute. Otherwise I'll make progress when I have time.
Tested the new 5e 3.0 release today. We noticed if we popped out a journal page the roll would not work. We didn't see a card in the game chat and there was no indication anywhere else it was waiting for our action.
Running core version 11.315 with PopOut! 2.14, Dice So Nice! 4.6.9, LibWrapper 1.12.13.3, and Phandelvar & Below 1.0 loaded.