[buddypress-trac] [BuddyPress Trac] #5817: Additional styling support for BuddyPress Widgets

buddypress-trac noreply at wordpress.org
Sun Aug 17 20:54:54 UTC 2014


#5817: Additional styling support for BuddyPress Widgets
--------------------------+------------------------------
 Reporter:  mercime       |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Theme         |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |
--------------------------+------------------------------

Comment (by mercime):

 > The new `.item-options` and `.avatar-block` CSS seems too general if
 you're trying to get the new CSS to only target widget blocks. Did you
 mean to add the new `bp-widget` class to these?

 I only targeted the widgets which had no styles using the new `bp-widget`
 class: Friends, Groups and Members for a simple but effective fix by
 removing list style, left margin, and styling content within those three
 widgets.

 Per my check, `.avatar-block`  and `.item-options` are only used in BP
 widgets, i.e., not used in any other elements within any BP component, so
 there are no conflicts.
 `.avatar-block` is used only in the "Who's Online" and "Recently Active"
 widgets
 `.item-options` is used only in the Friends, Groups, and Members widgets

 As for BP Blog Posts widget for multisite installations, there's no issue
 with having a list style, if any, for the links there.

 > I am also not sure about the name of the `bp-widget` class; to me, that
 sounds like something I would expect to see on an overall wrapper element,
 not on `UL`s in (not all of) the widgets. The duplicated CSS (for backpat)
 is understandable but kinda annoying.
 Agreed. Used `bp-widget` as it's a short but specific class name. Can be
 changed :)

 > For a different suggestion, if the root problem is that `before_widget`
 isn't guaranteed to contain `class=widget`, how about we make sure it is?
 It would be a straightforward change, and this way, the CSS doesn't need
 to change.
 That would be ideal. How do we do it? In addition to `class=widget`, we
 also need `class=buddypress` for styles rendered by following specific
 selectors like `.widget.buddypress div.item-meta` or `.widget.buddypress
 ul.item-list img.avatar` among others. There are themes which use
 `'before_widget' => '',` instead.

 P.S. This is the second trac ticket I created arising from ticket
 [https://buddypress.trac.wordpress.org/ticket/5804 #5804] :)

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/5817#comment:4>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list