[wp-trac] [WordPress Trac] #38949: Twenty Seventeen: child themes can't easily extend custom color patterns
WordPress Trac
noreply at wordpress.org
Wed Nov 30 22:56:09 UTC 2016
#38949: Twenty Seventeen: child themes can't easily extend custom color patterns
-------------------------------------------+----------------------------
Reporter: celloexpressions | Owner: davidakennedy
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 4.7
Component: Bundled Theme | Version: trunk
Severity: normal | Resolution: fixed
Keywords: has-patch commit dev-reviewed | Focuses:
-------------------------------------------+----------------------------
Comment (by ocean90):
In [changeset:"39387"]:
{{{
#!CommitTicketReference repository="" revision="39387"
Twenty Seventeen: Allow child themes to easily extend custom color
patterns
By adding a filter, child themes can add additional selectors onto the
custom color scheme CSS. Like so:
{{{
// Add child theme selectors for color schemes.
function dynamic_seventeen_custom_colors_css( $css, $hue, $saturation ) {
$css .= '
.colors-custom .content-menu > article:not(.has-post-thumbnail),
.colors-custom .content-menu > section:not(.has-post-thumbnail) {
border-top-color: hsl( ' . $hue . ', ' . $saturation . ',
87% ); /* base: #ddd; */
}';
return $css;
}
add_filter( 'twentyseventeen_custom_colors_css',
'dynamic_seventeen_custom_colors_css', 10, 3 );
}}}
Merge of [39386] to the 4.7 branch.
Props celloexpressions.
See #38949.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/38949#comment:9>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list