twentysixteen
twentysixteen copied to clipboard
Tag cloud widget output as a list
Here is info about tag cloud widget output as a list in Twenty17. In short we should discuss should we use list format in tag cloud widget after it drops in the Core.
Here is the idea of code changes.
functions.php:
function twentysixteen_widget_tag_cloud_args( $args ) {
$args['largest'] = 1;
$args['smallest'] = 1;
$args['unit'] = 'em';
$args['format'] = 'list';
return $args;
}
add_filter( 'widget_tag_cloud_args', 'twentysixteen_widget_tag_cloud_args' );
style.css:
/* Tag Cloud widget */
.tagcloud ul {
list-style: none;
margin: 0;
}
.tagcloud li {
display: inline-block;
}
.tagcloud a {
border: 1px solid #d1d1d1;
border-radius: 2px;
display: block;
font-family: Montserrat, "Helvetica Neue", sans-serif;
line-height: 1;
padding: 0.5625em 0.4375em 0.5em;
margin: 0 0.1875em 0.4375em 0;
}
.tagcloud a:hover,
.tagcloud a:focus {
border-color: #007acc;
color: #007acc;
outline: 0;
}