edemaine / coauthor

Coauthor supercollaboration/discussion forum
MIT License
249 stars 34 forks source link

Sidebar height is not recalculated on window resize when embedded in an iframe #484

Closed diomidov closed 4 years ago

diomidov commented 4 years ago

What's wrong?

Sidebar height is not recalculated on window resize when embedded in an iframe.

This is especially annoying when embedded in Comingle.

How to Reproduce

Steps to reproduce the behavior:

  1. Open any thread in Comingle
  2. Increase the window height
  3. The sidebar now looks like this:

Screenshots

image

Context

diomidov commented 4 years ago

I think replacing https://github.com/edemaine/coauthor/blob/bf43d8dc5517ca67051000ae8702fde569318bf8/client/message.coffee#L224-L225 with ResizeObserver could fix this

edemaine commented 4 years ago

iframes get window resize events no problem. The issue was that we were resizing in one case (affix-top) but not the other case (affix).