esmero / format_strawberryfield

Set of Display formatters, extractors and utils to make Strawberry field data glow
GNU Lesser General Public License v3.0
6 stars 9 forks source link

Metadata Display Preview off-canvas dialog inconsistent resizing behavior #360

Open aksm opened 11 months ago

aksm commented 11 months ago

What?

Across OSes and browsers, the resizing behavior for the off-canvas dialog used in Metadata Display Preview is inconsistent (see below). Somewhere between the Javascript/jQuery and the CSS (media breakpoints?), things are going awry.

As noted in format_strawberryfield.module, as of Drupal 9.5.10, the off-canvas CSS reset is still a problem for CodeMirror:

https://github.com/esmero/format_strawberryfield/blob/df4cc3f3b69e62b6acb29db40f811fb440bc7298/format_strawberryfield.module#L212-L216

Chrome/Fedora Linux: resizing_metadata_display_preview_chrome

Firefox/Fedora Linux: resizing_metadata_display_preview_firefox

Safari/macOS Ventura: resizing_metadata_display_preview_safari

aksm commented 11 months ago

From what I can tell so far the issue seems to be related to Javascript events and keyboard shortcuts. Manually resizing the window by mouse doesn't cause the issue, but using the keyboard shortcut to snap the browser window to half screen and back disrupts functionality. It doesn't seem to be a problem in Firefox, but in a related issue, some of the CSS rules that are being stripped out because of the bug above, might be reintroduced so that, e.g. the dialog resizes to full screen on smaller screens.