Coupon with marching dashes in WordPress
A cut-out discount coupon whose dashed border keeps marching around the promo code.
Here is an excerpt of this component's code in WordPress. The full code is free for members, ready to copy into your project.
This component also comes in
The code in WordPress
<?php
/**
* Plugin Name: Forge, Coupon aux pointillés animés
* Description: Un bon de réduction à découper dont la bordure en pointillés avance en continu autour du code promo. Ajoute la composition « Coupon aux pointillés animés » à l'éditeur de blocs.
* Version: 1.0.0
* Requires at least: 6.6
* Requires PHP: 8.1
* Author: Forge
* License: GPL-2.0-or-later
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
* Text Domain: forge-effet-bordure-pointillee-animee
*<!-- wp:group {"tagName": "article", "className": "efbp", "layout": {"type": "default"}} -->
<article class="wp-block-group efbp"><!-- wp:html -->
<span class="efbp__ants" aria-hidden="true"></span>
<!-- /wp:html -->
<!-- wp:paragraph {"className": "efbp__eyebrow"} -->
<p class="efbp__eyebrow">Fleurs d’Hélène · Angers</p>
<!-- /wp:paragraph -->
<!-- wp:heading {"level": 2, "className": "efbp__title", "anchor": "efbp-titre"} -->
<h2 class="wp-block-heading efbp__title" id="efbp-titre">−15 % sur les bouquets de mariée</h2>
<!-- /wp:heading -->
<!-- wp:paragraph {"className": "efbp__text"} -->
<p class="efbp__text">Pour toute commande passée avant le 30 avril, avec un essai de bouquet offert lors du rendez-vous en boutique.</p>:root {
--efbp-card: #f0fdf4;
--efbp-ant: #15803d;
--efbp-text: #052e16;
--efbp-body: #166534;
--efbp-code-bg: #ffffff;
--efbp-accent: #15803d;
--efbp-on-accent: #ffffff;
--demo-effet-bordure-pointillee-animee-bg: #f7fdf9;
--demo-effet-bordure-pointillee-animee-text: #052e16;
}
Free component: copy it freely, including for commercial projects.
Other visual effects components in WordPress
Visual effects components in WordPress
A large heading whose words turn from grey to ink as the page scrolls, then whose key phrases get a marker stroke, in pure CSS with a readable fallback.
- Tailwind
- React
- CSS
- WordPress

Cards that fade in as they enter the screen, one after another in each row, without a line of JavaScript and with a static fallback.
- Tailwind
- React
- CSS
- WordPress

A translucent card with a saturated blur whose sharper edge refracts the colourful shapes drifting behind it, with an opaque fallback when transparency is reduced.
- Tailwind
- React
- CSS
- WordPress

A help block shaped like a conversation: bubbles, three animated typing dots and clickable quick replies that show your answers to frequent questions, frozen under prefers-reduced-motion.
- Tailwind
- React
- CSS
- WordPress

A paragraph whose words turn from grey to full ink, one by one, as the page scrolls, in pure CSS with a plain-text fallback.
- Tailwind
- React
- CSS
- WordPress

Four offset, translucent sine waves gently roll along the bottom of a section, each at its own pace.
- Tailwind
- React
- CSS
- WordPress