Make WordPress Core

Opened 6 years ago

Closed 6 years ago

#46062 closed defect (bug) (fixed)

TinyMCE Classic Block: fix repositioning of the inline toolbar on scroll

Reported by: azaozz's profile azaozz Owned by: azaozz's profile azaozz
Milestone: 5.1 Priority: normal
Severity: normal Version: 5.0
Component: TinyMCE Keywords: has-patch commit
Focuses: Cc:

Description

In a TinyMCE instance the inline toolbars (like the Add/Edit Link toolbar) are hidden on scroll-start and repositioned and shown on scroll-end. This stopped working in the Classic Block instance as the scrolling element there is a container div, not the document/window (and the scroll event doesn't propagate).

Attachments (2)

46062.diff (620 bytes) - added by azaozz 6 years ago.
46062.1.diff (1.1 KB) - added by azaozz 6 years ago.

Download all attachments as: .zip

Change History (7)

@azaozz
6 years ago

#1 @azaozz
6 years ago

In 46062.diff: add another scroll handler to the wordpress TinyMCE plugin to hide and/or reposition the inline toolbars in Classic Block instances.

@azaozz
6 years ago

#2 @azaozz
6 years ago

After chatting with @iseulde, we can set capture for the scroll event and attach the listener to the document. That'd work better, see 46062.1.diff. Also added detaching of that listener.

#3 @azaozz
6 years ago

  • Keywords has-patch added

Tested in Firefox, Chrome and Edge on Win10.

#4 @iseulde
6 years ago

  • Keywords commit added

Looks good to me!

#5 @azaozz
6 years ago

  • Owner set to azaozz
  • Resolution set to fixed
  • Status changed from new to closed

In 44697:

TinyMCE Classic Block: fix repositioning of the inline toolbar on scrolling.

Props iseulde, azaozz.
Fixes #46062.

Note: See TracTickets for help on using tickets.