Skip to content

Instantly share code, notes, and snippets.

@jmabbas
jmabbas / style.css
Created April 27, 2026 08:16
Electro - Customisation
@media(min-width: 801px) {
body .site-main .desktopacacher {
display: none;
}
}
@media(max-width: 801px) {
body .site-main .mobileacacher {
display: none;
}
@jmabbas
jmabbas / functions.php
Created April 27, 2026 06:46
Electro - Desktop header on tablet view
add_filter( 'electro_handheld_header_responsive_class', 'ec_child_handheld_header_responsive_class', 10 );
add_filter( 'electro_desktop_header_responsive_class', 'ec_child_desktop_header_responsive_class', 10 );
function ec_child_handheld_header_responsive_class( $responsive_class ) {
$responsive_class = 'hidden-lg-up';
return $responsive_class;
}
function ec_child_desktop_header_responsive_class( $responsive_class ) {
$responsive_class = 'hidden-md-down';
@jmabbas
jmabbas / style.css
Created April 22, 2026 14:42
Electro - Elementor header v16 styles to header v12
@media (min-width: 1480px) {
body.home .content-area {
width: 100%;
}
}
.primary-nav-menu .yamm-sm-fw .dropdown-submenu.menu-item-has-children>a::after,
.header-v12 .col-auto.d-xl-none.d-xxl-block,
body.home.page .entry-header {
@jmabbas
jmabbas / style.css
Created April 21, 2026 12:40
FreshCart - Header cart icon to white color
.wc-block-mini-cart .wc-block-mini-cart__quantity-badge::before {
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 2L3 6v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6l-3-4z'/%3E%3Cline x1='3' y1='6' x2='21' y2='6'/%3E%3Cpath d='M16 10a4 4 0 0 1-8 0'/%3E%3C/svg%3E") !important;
}
@jmabbas
jmabbas / functions.php
Created April 21, 2026 06:17
Frunique - Product tabs
add_action('wp_footer', function () {
if ( ! is_product() ) return;
?>
<script>
jQuery(document).ready(function($){
const $tabsWrapper = $('.woocommerce-tabs');
const $tabsList = $tabsWrapper.find('ul.tabs');
$('.woocommerce-Tabs-panel > li[role="presentation"]').each(function(){
@jmabbas
jmabbas / functions.php
Created April 20, 2026 08:45
Electro - Jjumbotron compatible with blocks
function electro_shop_archive_jumbotron() {
$static_block_id = '';
$brands_taxonomy = electro_get_brands_taxonomy();
if ( is_shop() ) {
$static_block_id = apply_filters( 'electro_shop_jumbotron_id', '' );
} elseif ( is_product_category() || is_tax( $brands_taxonomy ) ) {
$term = get_queried_object();
$term_id = $term->term_id;
@jmabbas
jmabbas / style.css
Created April 17, 2026 05:48
Skinnel - Mobile sub menu click
@media(max-width:768px) {
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content .wp-block-navigation__submenu-icon {
display: block;
width: 13px;
height: 13px;
}
:root :where(.wp-block-navigation) .is-style-header-nav .wp-block-navigation-item.has-child {
display: flex;
width: 100%;
@jmabbas
jmabbas / functions.php
Last active April 15, 2026 13:04
Sportiq - Dark mode by default
function dark_mode_by_devault() {
?>
<script>
(function() {
try {
var theme = localStorage.getItem('theme');
if (theme === 'dark' || theme === null) {
document.documentElement.classList.add('dark-mode');
localStorage.setItem('theme', 'dark');
}
@jmabbas
jmabbas / style.css
Created April 14, 2026 10:05
Geeks - Custom style
.tutor-widget.tutor-widget-course-price.tutor-mt-48 {
padding-left: 24px;
}
.tutor-form-check-input.tutor-form-check-input[type=checkbox] {
border-radius: 4px;
--bs-form-check-bg: #fff;
flex-shrink: 0;
width: 1em;
height: 1em;
@jmabbas
jmabbas / functions.php
Created April 13, 2026 05:14
Electro - Remove Header Mini Cart
function ec_child_remove_header_mini_cart_icon() {
remove_action( 'electro_header_icons', 'electro_header_mini_cart_icon', 90 );
}
add_action( 'init', 'ec_child_remove_header_mini_cart_icon' );