Dynamic width of Reusable popup

Does anybody have a solution to dynamically setting the width of a reusable popup? I’ve tried CSS Tools, a basic javascript command, setting the element width to be narrower than the actual width (hoping it would then expand when needed.) No luck.

The use case is a popup with Simple and Advanced options. The advanced options are an additional panel of elements to the right of the main area. The advanced panel is hidden on narrow devices. All working well, but on desktop if I hide the advanced panel, I get a large white space since we can only collapse vertically, not horizontally. I’d like to be able to toggle from wide to narrow (the width of both will be a preset number of pixels.)

I’ve seen lots of threads on setting element widths, but can’t find the magic solution for reusable popups.

Appreciate any ideas…Anybody?

Just guessing, here, but what if you set background color of the popup to fully transparent, i.e. 0 opacity.

image

It seems to work for me but my case may be different than yours, and I’m not testing anything on mobile yet.

1 Like

That is one heck of an interesting idea. I did a quick try of it, and it has potential. First thing I’m noticing is that while I can pull off what I described, it would not be centered on the screen. But I’m two minutes into looking at it, so perhaps there is a way around it. Definitely will get some attention tomorrow.

Thanks much!

This topic was automatically closed after 70 days. New replies are no longer allowed.