Make WordPress Core

Opened 12 years ago

Closed 12 years ago

#18334 closed enhancement (fixed)

Add IDs to div.widgets-holder-wrap in widget admin screen to allow custom layout

Reported by: sillybean's profile sillybean Owned by:
Milestone: 3.3 Priority: normal
Severity: normal Version: 3.2.1
Component: Widgets Keywords: has-patch ui-feedback
Focuses: Cc:

Description

I've been fiddling around with the layout of wp-admin/widgets.php, using a stylesheet full of overrides enqueued to that page in my theme functions file, to see if I can produce a layout that better matches the theme and makes more sense to my users. (None of them understand the stacked-sidebar model.)

I've discovered that I can get pretty far, until it comes to creating two columns of sidebars. I can move the divs with the IDs matching those I registered, but the div.sidebar-name doesn't come with it. Since their wrapper, div.widgets-holder-wrap, doesn't have an ID, I can't easily rearrange the screen while the two parts as a group.

TL;DR: If you could add IDs to the wrappers within div#widgets-right, it'd be possible for adventurous theme developers to rearrange the sidebars.

See attached patch, and sample functions.php and admin-widget-overrides.css.

Screenshot without the IDs
Screenshot with the IDs

Attachments (3)

widgetIDs.diff (598 bytes) - added by sillybean 12 years ago.
Tiny patch to add IDs to widget wrappers
admin-widget-overrides.css (964 bytes) - added by sillybean 12 years ago.
CSS file that overrides the layout of the widget admin screen
functions.php (2.9 KB) - added by sillybean 12 years ago.
Sample theme functions.php including widget definitions and stylesheets

Download all attachments as: .zip

Change History (13)

@sillybean
12 years ago

Tiny patch to add IDs to widget wrappers

#1 @SergeyBiryukov
12 years ago

  • Keywords has-patch added

@sillybean
12 years ago

CSS file that overrides the layout of the widget admin screen

@sillybean
12 years ago

Sample theme functions.php including widget definitions and stylesheets

#2 @smub
12 years ago

This looks really neat Stephanie.

#3 @ramiy
12 years ago

i agree with you, the old stacked-sidebar model should be upgraded.

i hope to see this in 3.3.

#4 @mikeschinkel
12 years ago

  • Cc mikeschinkel@… added

This is really nice Stephanie, props.

As an aside, I'd would love to see a progressive search feature for the Available Widgets list like how search works in CPanel or on the Mac.

#5 @ashfame
12 years ago

  • Cc ashishsainiashfame@… added

#6 @naomicbush
12 years ago

  • Cc naomicbush added

#7 @ptahdunbar
12 years ago

+1 on this and search for available/inactive widgets.

#8 follow-up: @sillybean
12 years ago

  • Keywords ui-feedback added

Might this be folded in to the work being done on #17979?

#9 @SergeyBiryukov
12 years ago

  • Milestone changed from Awaiting Review to 3.3

#10 in reply to: ↑ 8 @azaozz
12 years ago

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

Replying to sillybean:

Yes, seems this was handled in #17979.

Note: See TracTickets for help on using tickets.