This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.screen-reader-text { | |
position: absolute; | |
display: block; | |
width: 1px; | |
height: 1px; | |
padding: 0; | |
margin: 0; | |
text-indent: 100%; | |
white-space: nowrap; | |
overflow: hidden; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.wp-block-gallery { | |
display: flex; | |
flex-wrap: wrap; | |
list-style-type: none; | |
padding: 0; | |
// allow gallery items to go edge to edge | |
margin: 0 -8px 0 -8px; | |
.blocks-gallery-image, | |
.blocks-gallery-item { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Example of custom color defined in the Customizer | |
$wp_customize->add_setting('primary_color', array( | |
'default' => '99CC00', | |
'sanitize_callback' => 'sanitize_hex_color', | |
'capability' => 'edit_theme_options', | |
'type' => 'theme_mod', | |
'transport' => 'refresh', | |
)); | |
$wp_customize->add_control( new WP_Customize_Color_control($wp_customize, 'primary_color_ctrl', array( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Define your own color palette | |
add_theme_support( 'editor-color-palette', | |
array( | |
'name' => __( 'very dark gray', 'textdomain' ), | |
'slug' => 'very-dark-gray', | |
'color' => '#4a4a4a', | |
), | |
array( | |
'name' => __( 'very light gray', 'textdomain' ), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Facetwp A11Y Pager | |
function fs_a11y_facetwp_pager_html( $output, $params ) { | |
$output = ''; | |
$page = $params['page']; | |
$total_pages = $params['total_pages']; | |
if ( 1 < $total_pages ) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function fs_add_dropdown_labels() { | |
?> | |
<script> | |
(function($) { | |
$(document).on('facetwp-loaded', function() { | |
$('.facetwp-dropdown').each(function() { | |
var facet_name = $(this).parent().attr('data-name'); | |
var facet_label = FWP.settings.labels[facet_name]; | |
$(this).attr('id', facet_name); | |