Page MenuHomePhabricator

VisualEditor: Standalone demo toolbar breaks sometimes in Chrome
Closed, ResolvedPublic

Description

Screenshot of the bug

See attached screenshot.

This is because the standalone demo initializes the target into a detached DOM element, then attaches it once it's done. But you can't do that, because it causes ve.ui.Toolbar.prototype.initialize to be run before the toolbar is attached to the DOM (and generally causes initialize to be run on unattached things, which is not allowed), which means its measurements will be wrong, and so the toolbar gets right: 1840px; (width of screen) rather than width: 63px; or whatever.


Version: unspecified
Severity: normal

Attached:

toolbar-1840px.png (811×534 px, 44 KB)

Details

Reference
bz60183