WordPress.org

Make WordPress Core

#22545 closed defect (bug) (fixed)

New media: 'Insert Embed' button remains disabled when pasting with context menu

Reported by: johnbillion Owned by: nacin
Milestone: 3.5 Priority: normal
Severity: normal Version: 3.5
Component: Media Keywords: has-patch commit dev-reviewed
Focuses: Cc:

Description

Steps to reproduce:

  1. Click 'Add Media' on the post editing screen
  2. Switch to the 'Embed From URL' tab on the left
  3. Paste a URL into the URL field by using the 'Paste' command in the context menu

Note that the 'Insert Embed' button at the bottom remains disabled. It only gets re-enabled if you type something in the URL field or if you were to use Ctrl/Cmd+V to paste.

Attachments (1)

22545.diff (524 bytes) - added by koopersmith 17 months ago.

Download all attachments as: .zip

Change History (7)

comment:1 nacin17 months ago

  • Milestone changed from Awaiting Review to 3.5

koopersmith17 months ago

comment:2 koopersmith17 months ago

Adds the input event to observable inputs for newer browsers, and the change event to catch any stragglers (like paste, autocomplete, etc).

comment:3 koopersmith17 months ago

  • Keywords has-patch added

comment:4 nacin17 months ago

  • Keywords commit added

Tested, seems solid.

comment:5 ryan17 months ago

  • Keywords dev-reviewed added

Tested with Chrome and Firefox on Mac OS. Tested typing in a URL manually, Cmd+V, and context menu paste. Looks good.

comment:6 nacin17 months ago

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

In 22836:

Media: Watch more events for input changes to catch paste, autocomplete, etc.

Fixes issue where pasting a URL in 'From URL' (via the context menu) did not
enable the insert button, as the event was not yet fired.

props koopersmith.
fixes #22545.

Note: See TracTickets for help on using tickets.