Skip to content

"Open in new tab" property is not always saved when "Save draft" is used #19365

@tofumatt

Description

@tofumatt

Describe the bug
The "Open in a new tab" setting is not persisted if "Save draft" is used after it is set and the inline editing screen is not closed.

This happens in Gutenberg in the latest version of WordPress and with Gutenberg on master.

To reproduce
Steps to reproduce the behavior:

  1. Create a new post or load an existing post with several paragraph blocks that have text.
  2. Create a link for some of the text to a URL.
  3. Save the post as a draft.
  4. Select a link you made and click the "edit"/pencil button (sometimes this is buggy for me, at least in Firefox, but keep trying until it appears).
  5. Change the setting of "Open in new tab" to "on".
  6. Click "Save Draft" and then blur the link you have open by clicking on the title or another block, hiding the link selection.
  7. Wait until the draft is saved.
  8. Check the link. It will not have changed setting (it's still set not to "open in new tab").

Expected behavior
The setting is changed and saved immediately, and saving is not blocked by the "Save draft" button.

Screenshots
2019-12-30 12 35 18

Desktop (please complete the following information):

  • OS: MacOS (10.15)
  • Browser Firefox 72.0b11 (64-bit), Chrome 79.0.3945.88

Metadata

Metadata

Assignees

No one assigned

    Labels

    [Block] ParagraphAffects the Paragraph Block[Feature] Link EditingLink components (LinkControl, URLInput) and integrations (RichText link formatting)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions