Breadcrumb Block
This is a single-block plugin for the breadcrumb trail. It’s simple, lightweight, SEO-friendly, and WooCommerce compatibility. It also includes some simple separator icons. It works everywhere: Page Editor, Site Editor, and template files. How to customize the breadcrumb How to change/remove an item? add_filter( 'breadcrumb_block_get_item', function ( $item_args, $context, $breadcrumbs_instance ) { // Ignore items without context. if ( ! $context || ! ( $context['object'] ?? false ) ) { return $item_args; } // Eg: remove a term. if ( 'term' === ( $context['type'] ?? '' ) && 'term-slug' === $context['object']->slug ) { return false; } // Eg: Change the title of a page. if ( 'page' === ( $context['type'] ?? '' ) && page_id_to_change === $context['object']->ID ) { $item_args[0] = 'Make it shorter'; } return $item_args; }, 10, 3 ); $item_args is a 3-item array: [$item_label, $item_link, $item_attrs] $context is an associative array: ['type' => 'item type', 'object' => 'item object']. type can be one of the following values: front_page, home, shop, page, post, single, term, taxonomy, post_type_archive, search, 404, paged, author, date_year, date_month, date_day, attachment. How to change the markup of the block? add_filter( 'breadcrumb_block_get_breadcrumb_trail', function ( $markup, $args, $breadcrumbs_instance ) { return $markup; }, 10, 3 ); How to add or remove the items from the breadcrumb trail? add_filter( 'breadcrumb_block_get_items', function ( $items, $breadcrumbs_instance ) { return $items; }, 10, 2 ); How to use a custom separator for the breadcrumb trail? add_filter( 'breadcrumb_block_get_args', function ( $args ) { // For example, change separator. $args['separator'] = ' '; return $args; } ); The custom separator should be an inline SVG. To make sure it displays properly, it should have three attributes: width, height, and fill. The values of these attributes should be as follows: fill="currentColor" width="1em" height="1em". Using this hook, you can customize other attributes such as container, before, after, list_tag, item_tag, item_before, item_after, separator. How to prepend the blog page to all single posts? add_action( 'breadcrumb_block_single_prepend', function ( $post, $breadcrumbs_instance ) { if ( 'post' === $post->post_type ) { $blog_id = get_option( 'page_for_posts'); if ( $blog_id ) { $breadcrumbs_instance->add_item( get_the_title( $blog_id ), get_permalink( $blog_id ) ); } } }, 10, 2 ); If this plugin is useful for you, please do a quick review and rate it on WordPress.org to help us spread the word. I would very much appreciate it. Please check out my other plugins if you’re interested: Content Blocks Builder – Build custom layouts and blocks visually in the Block Editor without needing a code editor, using only core blocks and native Gutenberg features. Meta Field Block – A single block to display custom fields in the Block Editor without coding. It supports ACF, MetaBox, WooCommerce, meta, rest field, shortcode and more. Works everywhere: in the Site Editor (FSE), the Block Editor, inside Query Loop, WooCommerce Product Collection, Term Query blocks, and even in template files. SVG Block – A block to display SVG images as blocks. Useful for images, icons, dividers, and buttons. It allows you to upload SVG images and load them into the icon library. Icon separator – A tiny block just like the core/separator block but with the ability to add an icon. Block Enhancements – Adds practical features to blocks like icons, box shadows, transforms, etc. Counting Number Block – A block to display numbers with a counting effect Better YouTube Embed Block – A block to solve the performance issue with embedded YouTube videos. It can also embed multiple videos and playlists. The plugin is developed using @wordpress/create-block.
MakeITeasy Popup
Need popups to grab your users’ attention? Marketing call-to-actions that open on scroll, timer, click, matched referer, hover, or exit intent? Multiple popups on one page? This plugin has it all. It provides styling consistent with core block editor blocks plus additional features. Why choose Makeiteasy Popup? ▶️ Unlike some other plugins, Makeiteasy Popup integrates seamlessly with WordPress, feeling like a native, built-in WP block. It’s lightweight and self-sufficient, without the heavy burden of a large blocks library. It relies on a single tiny dependency – micromodal.js – with a combined total of only 10 kB of JavaScript❕ 👆 Try demo – there is a “Live preview” button on the top of this page 👆 ❗ Sometimes “Live preview” does not start due to slower responds of servers with resources. If progress stops with black screen or progress indicator does not advance anymore (loading should be finished at max 30 seconds) – in that case please refresh the page in browser. Key Features 🥇 Feature-Rich and free. 🥈 Fully Open Source: Including the block source code. Fork and adjust as needed. 🥉 Developer friendly: Hooks for modifications and unopinionated starting CSS. ⏲️ Future-Proof Compatibility: Guaranteed compatibility with future WordPress versions. 🆕 Added “open on exit intent” feature. It works only on desktop. When popup is set up to open on exit intent and user moves mouse outside the top border of the browser inner window (screen), popup appears. User can choose when feature is activated (after how many seconds since page was loaded), so popup can’t open too early. ⏱️❗Queue if another popup is opened, popup is placed in queue and opened upon closing the former. Known limitations Currently, opening several modal popups simultaneously is impossible due to the limitations of the Micromodal.js library. Future versions will replace this library with the native Dialog HTML element, including automatic migration for existing popups. Block options The block sidebar provides many options, most of which function similarly to other blocks. Notable options include: – Opening time selector: See the detailed section below. – Layout type: Floating, Fixed, Attached – Popup Enabled: Temporarily hide the popup without deleting it. – Open on interval: Open on given interval in days. – Open on matching referer: Open if the user’s referral URL matches. Layout Types Floating: popup floats above content. Clicking on area outside popup closes it. Fixed: popup is “fixed” to one of sides of screen — top, bottom, right, left Attached: popup is attached to element on screen. When user scrolls, it moves with it. Modality Modal: popup blocks everything else on screen, scrolling is not possible, popup can be closed by clicking outside of popup Modeless: popup is non-blocking, user can scroll, popup can’t be closed by clicking outside of popup Developers Github repository https://github.com/Lovor01/makeiteasy-popup Changing the Close button Using Javascript: import { ReactComponent as CloseIcon } from '../assets/close-x.svg'; addFilter( 'makeiteasy-closeButtonIcon', 'makeiteasy/makeiteasy-popup/close-icon', () => ( ) ); If you customize button this way and you already have posts(or pages) with popup block, on post reopening the message “This block contains unexpected or invalid content.” will be presented. In such case choose “Attempt to repair block” and if it looks good, save post. Using PHP: add_action( 'render_block_makeiteasy/popup', function($content) { $svg = file_get_contents( __DIR__ . '/path_to_file/close-button-dark.svg' ); return preg_replace( '~( ).*( )~m', "$1$svg$2", $content ); } ); Attaching Code to Modal Events Custom events ‘makeiteasy/openModal’ and ‘makeiteasy/closeModal’ are fired on modal open and close. Events fire on modal itself, DOM element with class .wp-block-makeiteasy-popup.