WordPress.org

Make WordPress Core

Opened 6 years ago

Closed 5 years ago

Last modified 5 years ago

#7905 closed enhancement (fixed)

Nest the 'flat' formatted tag cloud into some element

Reported by: hudatoriq Owned by: hudatoriq
Milestone: 2.8 Priority: normal
Severity: normal Version:
Component: Widgets Keywords: has-patch commit
Focuses: Cc:

Description

When displayed as comma separated format, the clouds don't have any parent block element to assign some stylesheet properties to. When used in a sidebar widget, the tag cloud is on the same level with the widget title.

<li class="widget widget_tag_cloud" id="tag_cloud">
	<h2 class="widgettitle">Tag Cloud</h2>
	<a href="">Tag 1</a> <a href="">Tag 2</a> <a href="">Tag 3</a>
</li>

We can't treat the tag clouds as a block, for example styling their margin, padding etc.

When displayed as a list, we are able to do so, cause the tag list is contained inside <ul></ul>.

Providing a parent element to the 'flat' (comma separated) tag cloud would be the solution, for example:

<li class="widget widget_tag_cloud" id="tag_cloud">
	<h2 class="widgettitle">Tag Cloud</h2>
	<p><a href="">Tag 1</a> <a href="">Tag 2</a> <a href="">Tag 3</a></p>
</li>

I will come up with patches after hearing some opinions.

Attachments (1)

7905.diff (383 bytes) - added by Denis-de-Bernardy 5 years ago.

Download all attachments as: .zip

Change History (8)

comment:1 hudatoriq6 years ago

  • Milestone changed from 2.8 to 2.7
  • Owner changed from anonymous to hudatoriq

comment:2 DD326 years ago

  • Component changed from General to Template

comment:3 jacobsantos5 years ago

  • Milestone changed from 2.7 to 2.8

2.7 is feature freeze, sending to 2.8.

comment:4 Denis-de-Bernardy5 years ago

  • Keywords needs-patch added
  • Milestone changed from 2.8 to Future Release

Denis-de-Bernardy5 years ago

comment:5 Denis-de-Bernardy5 years ago

  • Component changed from Template to Widgets
  • Keywords has-patch commit added; needs-patch removed
  • Milestone changed from Future Release to 2.8

comment:6 azaozz5 years ago

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

(In [11199]) Wrap tag cloud in a block element, props hudatoriq, fixes #7905

comment:7 azaozz5 years ago

Better in <div> as it's neutral.

Note: See TracTickets for help on using tickets.