|
@@ -84,6 +84,58 @@ add_color_rule( 'bg', 'white', array(
|
|
// Background-color lightened
|
|
// Background-color lightened
|
|
array( '.has-background-light-background-color[class]', 'background-color', '+1' ),
|
|
array( '.has-background-light-background-color[class]', 'background-color', '+1' ),
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * Grays
|
|
|
|
+ * Uses a slightly darker color
|
|
|
|
+ */
|
|
|
|
+ // Border-color
|
|
|
|
+ array( '.wp-block-code,
|
|
|
|
+ .wp-block-table td,
|
|
|
|
+ .wp-block-table th,
|
|
|
|
+ body .widget_eu_cookie_law_widget #eu-cookie-law,
|
|
|
|
+ input[type="color"],
|
|
|
|
+ input[type="date"],
|
|
|
|
+ input[type="datetime"],
|
|
|
|
+ input[type="datetime-local"],
|
|
|
|
+ input[type="email"],
|
|
|
|
+ input[type="month"],
|
|
|
|
+ input[type="number"],
|
|
|
|
+ input[type="password"],
|
|
|
|
+ input[type="range"],
|
|
|
|
+ input[type="search"],
|
|
|
|
+ input[type="tel"],
|
|
|
|
+ input[type="text"],
|
|
|
|
+ input[type="time"],
|
|
|
|
+ input[type="url"],
|
|
|
|
+ input[type="week"],
|
|
|
|
+ select,
|
|
|
|
+ table td,
|
|
|
|
+ table th,
|
|
|
|
+ textarea,
|
|
|
|
+ ', 'border-color', '-1' ),
|
|
|
|
+ // Border-top-color
|
|
|
|
+ array( '.comment-list .children > li,
|
|
|
|
+ .comment-list > li,
|
|
|
|
+ .entry-footer,
|
|
|
|
+ .wp-block-pullquote', 'border-top-color', '-1' ),
|
|
|
|
+ // Border-bottom-color
|
|
|
|
+ array( '.comment-list,
|
|
|
|
+ .wp-block-pullquote,
|
|
|
|
+ hr,
|
|
|
|
+ hr.wp-block-separator', 'border-bottom-color', '-1' ),
|
|
|
|
+ // Color
|
|
|
|
+ array( 'hr.wp-block-separator.is-style-dots:before', 'color', '-1' ),
|
|
|
|
+ // Background-color
|
|
|
|
+ array( '.comments-area:before,
|
|
|
|
+ .pagination:before,
|
|
|
|
+ .post-navigation:before,
|
|
|
|
+ ::-moz-selection,
|
|
|
|
+ ::selection,
|
|
|
|
+ body .widget_eu_cookie_law_widget #eu-cookie-law.negative input.accept.has-focus,
|
|
|
|
+ body .widget_eu_cookie_law_widget #eu-cookie-law.negative input.accept:focus,
|
|
|
|
+ body .widget_eu_cookie_law_widget #eu-cookie-law.negative input.accept:hover', 'background-color', '-1' ),
|
|
|
|
+
|
|
|
|
+
|
|
), __( 'Background Color' ) );
|
|
), __( 'Background Color' ) );
|
|
|
|
|
|
// Link Color
|
|
// Link Color
|
|
@@ -312,6 +364,44 @@ add_color_rule( 'txt', '#222222', array(
|
|
// Background-color brightened
|
|
// Background-color brightened
|
|
array( '.has-foreground-light-background-color[class]', 'background-color', '+2' ),
|
|
array( '.has-foreground-light-background-color[class]', 'background-color', '+2' ),
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * Gray (Same as text color)
|
|
|
|
+ */
|
|
|
|
+ // Text-color
|
|
|
|
+ array( '.a8c-posts-list__item .a8c-posts-list-item__meta,
|
|
|
|
+ .comment-meta .comment-metadata,
|
|
|
|
+ .comment-navigation a,
|
|
|
|
+ .entry-footer,
|
|
|
|
+ .entry-meta,
|
|
|
|
+ .footer-navigation .footer-menu,
|
|
|
|
+ .has-foreground-light-color[class],
|
|
|
|
+ .pagination .nav-links > *,
|
|
|
|
+ .post-navigation .meta-nav,
|
|
|
|
+ .site-branding,
|
|
|
|
+ .site-info,
|
|
|
|
+ .wp-block-image figcaption,
|
|
|
|
+ .wp-block-latest-comments .wp-block-latest-comments__comment-date,
|
|
|
|
+ .wp-block-latest-posts .wp-block-latest-posts__post-date,
|
|
|
|
+ .wp-block-newspack-blocks-homepage-articles article .cat-links,
|
|
|
|
+ .wp-block-newspack-blocks-homepage-articles article .entry-meta,
|
|
|
|
+ .wp-block-pullquote .wp-block-pullquote__citation,
|
|
|
|
+ .wp-block-pullquote cite,
|
|
|
|
+ .wp-block-pullquote footer,
|
|
|
|
+ .wp-block-quote .wp-block-quote__citation,
|
|
|
|
+ .wp-block-quote cite,
|
|
|
|
+ .wp-block-quote footer,
|
|
|
|
+ .wp-block-quote.is-large .wp-block-quote__citation,
|
|
|
|
+ .wp-block-quote.is-large cite,
|
|
|
|
+ .wp-block-quote.is-large footer,
|
|
|
|
+ .wp-block-quote.is-style-large .wp-block-quote__citation,
|
|
|
|
+ .wp-block-quote.is-style-large cite,
|
|
|
|
+ .wp-block-quote.is-style-large footer,
|
|
|
|
+ .wp-block-video figcaption,
|
|
|
|
+ figcaption,
|
|
|
|
+ .site-title', 'color' ),
|
|
|
|
+ // Border-color
|
|
|
|
+ array( 'body .widget_eu_cookie_law_widget #eu-cookie-law.negative', 'border-color' ),
|
|
|
|
+
|
|
), __( 'Text Color' ) );
|
|
), __( 'Text Color' ) );
|
|
|
|
|
|
// Accent Color
|
|
// Accent Color
|
|
@@ -327,4 +417,51 @@ add_color_rule( 'fg1', '#007FDB', array(
|
|
// Background-color
|
|
// Background-color
|
|
array( '.has-secondary-background-color[class]', 'background-color' ),
|
|
array( '.has-secondary-background-color[class]', 'background-color' ),
|
|
|
|
|
|
-), __( 'Secondary Color' ) );
|
|
|
|
|
|
+), __( 'Secondary Color' ) );
|
|
|
|
+
|
|
|
|
+/**
|
|
|
|
+ * Custom CSS
|
|
|
|
+ */
|
|
|
|
+function redhill_custom_colors_extra_css() { ?>
|
|
|
|
+ ::selection {
|
|
|
|
+ background-color: currentColor;
|
|
|
|
+ mix-blend-mode: hard-light;
|
|
|
|
+ }
|
|
|
|
+ ::-moz-selection {
|
|
|
|
+ background-color: currentColor;
|
|
|
|
+ mix-blend-mode: hard-light;
|
|
|
|
+ }
|
|
|
|
+ @media screen and (max-width: 560px) {
|
|
|
|
+ /* Prevent background color hovers on mobile */
|
|
|
|
+ .site-header .main-navigation > div,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.current-menu-item > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.current-menu-item li.current-menu-item > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.current-menu-item li.focus > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.current-menu-item li:hover > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.focus > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.focus li.current-menu-item > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.focus li.focus > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.focus li:hover > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li:hover > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li:hover li.current-menu-item > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li:hover li.focus > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li:hover li:hover > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li:hover li > a {
|
|
|
|
+ background: transparent;
|
|
|
|
+ color: inherit;
|
|
|
|
+ }
|
|
|
|
+ .site-header .main-navigation > div > ul > li.current-menu-item li.focus > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.current-menu-item li:hover > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.focus > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.focus li.current-menu-item > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.focus li.focus > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li.focus li:hover > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li:hover > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li:hover li.current-menu-item > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li:hover li.focus > a,
|
|
|
|
+ .site-header .main-navigation > div > ul > li:hover li:hover > a {
|
|
|
|
+ text-decoration: underline;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+<?php }
|
|
|
|
+add_theme_support( 'custom_colors_extra_css', 'redhill_custom_colors_extra_css' );
|