Skip to content

Instantly share code, notes, and snippets.

View Crocoblock's full-sized avatar

Crocoblock Crocoblock

View GitHub Profile
@Crocoblock
Crocoblock / remove-filters-button-appearence.css
Created October 17, 2022 12:56 — forked from LesykJulia/remove-filters-button-appearence.css
Allows adjusting the Remove Filters Button from the JetSmartFilters plugin loading speed to display simultaneously with the filtered-out content.
.jet-remove-all-filters {
visibility: visible;
opacity: 1;
transition: opacity 1.3s ease-out, visibility 1.3s ease-out;
}
.jet-remove-all-filters.hide {
display: flex;
visibility: hidden;
opacity: 0;
}
@Crocoblock
Crocoblock / Hide Listing Grid widget before filtering
Last active October 17, 2022 11:01 — forked from dislokacia/Hide Listing Grid widget before filtering
Hide Listing Grid widget before filtering
jQuery( document ).ready(function( $ ) {
$( document ).on( 'jet-filter-content-rendered', function() {
$( '.hide-listing' ).removeClass( 'hide-listing' );
});
});
@Crocoblock
Crocoblock / JE_Query_Filter_Options_Generator.php
Last active October 11, 2022 07:09 — forked from ihslimn/JE_Query_Filter_Options_Generator.php
Generate JetSmartFilters options from JetEngine Query
<?php
class JE_Query_Filter_Options_Generator {
public function __construct() {
add_action( 'plugins_loaded', array( $this, 'maybe_add_filters' ) );
}
public function maybe_add_filters() {
@Crocoblock
Crocoblock / include-class.php
Last active July 11, 2022 13:27 — forked from MjHead/include-class.php
JetEngine. Example of custom macros registration based on Jet_Engine_Base_Macros class
<?php
/**
* Note! Always include mcros file only on 'jet-engine/register-macros' hook - before base class is not avaialable,
* after - all macros already registered and you can't insert a new one.
*/
add_action( 'jet-engine/register-macros', function() {
require_once get_theme_file_path( 'macros.php' );
new My_JE_Macros();
} );