WordPress.org

Make WordPress Core

Opened 6 weeks ago

Last modified 9 hours ago

#41629 assigned enhancement

Widgets: Default to "custom URL" in the image widget

Reported by: melchoyce Owned by: desrosj
Milestone: 4.9 Priority: high
Severity: normal Version:
Component: Media Keywords: needs-patch
Focuses: ui Cc:

Description

To help improve discoverability of custom URLs in the image widget, let's default to showing them rather than Link to: none.

See before/after screenshots.

Attachments (2)

before.png (1.9 MB) - added by melchoyce 6 weeks ago.
after.png (1.9 MB) - added by melchoyce 6 weeks ago.

Change History (17)

@melchoyce
6 weeks ago

@melchoyce
6 weeks ago

This ticket was mentioned in Slack in #core-media by desrosj. View the logs.


4 weeks ago

#2 follow-up: @joemcgill
4 weeks ago

  • Keywords reporter-feedback added

@melchoyce do we only want this as the default in the image widget, or across all instances of the media modal, i.e., in the post edit screen as well?

#3 @joemcgill
4 weeks ago

No sooner did I ask that question than did @desrosj come across #31467 (Images should default to not linking).

#4 in reply to: ↑ 2 @melchoyce
4 weeks ago

Replying to joemcgill:

@melchoyce do we only want this as the default in the image widget, or across all instances of the media modal, i.e., in the post edit screen as well?

Only the image widget.

This ticket was mentioned in Slack in #core-media by joemcgill. View the logs.


3 weeks ago

This ticket was mentioned in Slack in #core-media by joemcgill. View the logs.


2 weeks ago

This ticket was mentioned in Slack in #core by joemcgill. View the logs.


8 days ago

#8 follow-up: @philmcdonnell
8 days ago

What would be the case if the user didn't enter anything and just submitted the form? The http:// that is there is just a placeholder so it would not save I assume?

#9 in reply to: ↑ 8 ; follow-up: @joemcgill
8 days ago

Replying to philmcdonnell:

What would be the case if the user didn't enter anything and just submitted the form? The http:// that is there is just a placeholder so it would not save I assume?

The behavior should work just like it currently does if the form is submitted while custom URL is selected and the URL field is left blank. The image is inserted with no link at all.

This ticket was mentioned in Slack in #core-media by joemcgill. View the logs.


7 days ago

#11 in reply to: ↑ 9 ; follow-up: @philmcdonnell
7 days ago

Replying to joemcgill:

The behavior should work just like it currently does if the form is submitted while custom URL is selected and the URL field is left blank. The image is inserted with no link at all.

Thanks! That is what I thought, just making sure. So it is trivial to make this work, however there are two links withing the image widget, one is replace image which uses the same code as the original insert image so that would work as expected. There is another link (button) that says edit image, what would the expected behavior be there? If there is no link currently on the inserted image it would just default to 'none' or would that want to default to custom url as well? I would think editing an existing should be set to none if that is what was there originally. Thoughts?

#12 in reply to: ↑ 11 @joemcgill
7 days ago

  • Owner set to desrosj
  • Status changed from new to assigned

Replying to philmcdonnell:

If there is no link currently on the inserted image it would just default to 'none' or would that want to default to custom url as well? I would think editing an existing should be set to none if that is what was there originally. Thoughts?

I think your suggestion makes sense. Additionally, if a site has the image_default_link_type option set, we should probably respect it. So this would only apply as a default when that option is not set.

#13 @joemcgill
7 days ago

  • Keywords needs-patch added; reporter-feedback removed

Also, I'm assigning to @desrosj for further review, but @philmcdonnell feel free to add a patch if you have an approach you think will work. Thanks!

#14 @westonruter
29 hours ago

  • Priority changed from normal to high

Bumping priority to high for visibility and alignment with 4.9 goals, and given proximity to beta 1 deadline.

This ticket was mentioned in Slack in #core-media by joemcgill. View the logs.


9 hours ago

Note: See TracTickets for help on using tickets.