Make WordPress Core

Opened 4 years ago

Last modified 4 years ago

#50211 new enhancement

Add Ajax to Activate/Deactivate links in the Installed Plugins screen - keep focus on the screen location

Reported by: paaljoachim's profile paaljoachim Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version:
Component: Plugins Keywords:
Focuses: ui, administration Cc:

Description

As we update a plugin a spinner is seen and we are kept at the same location on the Installed plugin screen.
Clicking Activate/Deactivate the focus jumps to the top and one loses connection with the screen location.
It would be very helpful to add Ajax to the Activate/Deactivate links so we are kept in the same location on the screen and not kicked to the top of the page.

Change History (7)

#1 @pbiron
4 years ago

  • Focuses ui administration added

#2 @azaozz
4 years ago

Clicking Activate/Deactivate the focus jumps to the top

Don't see this here. The link element is the same (only the text changes inside it) so it never looses focus after the initial click.

Could you give more info about browser used, etc. (and perhaps check if you're not using old version of the plugin).

Version 0, edited 4 years ago by azaozz (next)

#3 @pbiron
4 years ago

@azaozz I believe @paaljoachim is talking about the Activate/Deactivate row actions.

#4 @azaozz
4 years ago

Ah, sorry, "the focus jumps to the top" made it sound like we are talking about the same page, not about clicking a link and navigating away from the page :)

Last edited 4 years ago by azaozz (previous) (diff)

#5 @ocean90
4 years ago

While deactivation may work, activation doesn’t due to redirects upon activation which is done by some plugins. See #40454 and #29820 where this was also discussed.
Since not all plugins provide an action link for the settings you’d have to reload the page anyway to get any new menu or toolbar items.

#6 @pbiron
4 years ago

For context, see https://github.com/WordPress/wp-autoupdates/issues/47, which was opened before Ajax handling was added for the Enable/Disable links in the auto-updates feature plugin.

So, the idea of this ticket is to add Ajax handling for the Activate/Deactivate/etc row actions on the plugins and multisite themes screen.

#7 @knutsp
4 years ago

Since activation requires reload, add a jump to the activated plugin after reload by url #bookmark to table-row (tr) id (now missing), or by script to existing data-slug attribute.

Note: See TracTickets for help on using tickets.