Linux 软件免费装
Banner图

Purplish - Block Design Toolkit for WooCommerce

开发者 shameemreza
更新时间 2026年11月6日 12:38
PHP版本: 7.4 及以上
WordPress版本: 7.1
版权: GPLv2 or later
版权网址: 版权信息

标签

woocommerce blocks design product gallery woocommerce blocks

下载

1.0.0 1.1.0

详情介绍:

Open a few WooCommerce stores on block themes and you'll see the same add to cart button, the same gallery and the same product cards, whatever they sell. The blocks are good. They all start out looking alike, though. Purplish is a block design toolkit for WooCommerce. It gives those blocks, and the patterns you build from them, the design options they don't have on their own. Select a block in the Site Editor, open the Purplish panel, and decide how it looks and moves. You need no page builder and no custom CSS, and nothing of WooCommerce's gets replaced. Think of a product page that takes the color of the variation a shopper picks, a gallery that tilts toward the mouse or slides in like a film reel, or a shop page where product cards fan out and hang from a clothes line. That's the kind of store Purplish is for. [youtube https://www.youtube.com/watch?v=K9pyGo5XebQ] Built to stay out of your way Product page colors When a shopper picks another color on a WooCommerce product page, the photo changes and nothing else does. The button, the sale badge and the price look the same for the orange sweater and the navy one. With Purplish, the page follows the color. Pick blue, and the add to cart button, the selected option and the sale badge turn blue. Pick orange, and they turn orange. Each variation has a Page color setting: A color taken straight from a photo is often too dark or too pale for a button. Purplish keeps the hue and adjusts it for each use: a button color with readable black or white text, a deeper shade for the sale price and a pale tint for the background. Simple products get one color for the whole page. You pick what takes the color: the add to cart button, the selected option and the sale badge (all three on by default), the sale price and a soft background tint. The page opens in the default variation's color, so there's no flash of your theme's colors first. When the color changes, the photo changes with a transition: Blur (the default), Fade, Zoom, Slide, Flip, Wipe, Circle reveal, Color wash or None. Product gallery Select the Product Gallery block and choose how the photos behave: Product cards On shop and collection pages, select the Product Collection block: Effects on hover: Spotlight, Color reveal, Fan deck, Expanded cards, Magnetic panel, Card folder, Bookmark and Roster. Effects in a carousel (a grid stays as it is): Deck, Arc, Spotlight carousel, Grow, Tilt, Depth and Overlap. Effects as cards scroll into view: Clothes line, Parallax and Zoom reveal. Small details On the Add to Cart + Options block: On other blocks: Nothing moves on its own. Every effect plays on a hover, a scroll, a color change or an add to cart, then stops. Visitors who turn on reduced motion on their device get the colors without the animation. Hanging Rail block A block of Purplish's own, in the Purplish group of the block inserter. It holds a heading, a short line and one Product Collection, so you pick the products the way you already do. Visitors who turn on reduced motion see the products as a row they can scroll sideways, with the rope and clips still drawn. Story Deck block Each story is a group with a photo, a quote, the customer's name and, if you want, a button to the product. The photos become a deck of cards, and the top card's story sits beside it. The deck never moves on its own. Visitors who turn on reduced motion switch stories with a short fade. Runway block It holds a heading, a short line and one Product Collection, so you pick the products the way you already do. Every product photo becomes a look, and the looks stand in one line that gets smaller and softer toward the back. The line never moves on its own, and a normal mouse wheel still scrolls the page past it. Visitors who turn on reduced motion step one look at a time with a short fade. Scroll Lookbook block It holds Cover blocks, one Product Collection and a Group. Each Cover is a shot: as visitors scroll, the camera moves from shot to shot, holds at each one and brings in that product's card on the side away from the subject. The opening video plays once and stops within 5 seconds, and nothing loops. Visitors who turn on reduced motion get each shot with its card beside it as a plain page. For video that follows the scroll smoothly, encode it with a keyframe every few frames; the block panel gives an ffmpeg line for it. Block and classic themes Purplish is built for block themes and tested with the free Purple theme. On a block theme, every option sits in a Purplish panel on the block it changes, in the Site Editor. Classic themes get a smaller set under WooCommerce > Settings > Products > Purplish: the page colors (except the selected option, since classic themes show a dropdown), the photo transition, the title and price rise, and three gallery options: hide thumbnails, rounded corners and the hover style. Why I made it
Purplish started with one small idea from a chat on X: let the product page take the color of the variation a shopper picks. Building it showed me how much more WooCommerce's blocks can do with a few good options, so I kept going. The Purplish website runs on WooCommerce, the Purple theme and Purplish itself. Shameem Reza
Source code The code is on GitHub. The readable source of the scripts ships in assets/src, next to the built files in build. To build them, run npm ci and npm run build.

安装:

  1. Make sure WooCommerce 11.0 or later is active.
  2. Go to Plugins > Add New, search for Purplish, then install and activate it. Purplish reads the colors of your variation photos in the background.
  3. To change a variation's color, edit the product, open Variations and use the Page color field. For a simple product, it's on the General tab.
  4. On a block theme, open a template in the Site Editor, select a block Purplish works on, like Add to Cart + Options, Product Gallery or Product Collection, and open the Purplish panel. Purplish's own blocks are in the Purplish group of the block inserter. On a classic theme, go to WooCommerce > Settings > Products > Purplish.

屏幕截图:

  • The same page after picking blue.
  • The Page color field on a variation: Automatic, Custom or Off.
  • The Purplish panel on the Add to Cart + Options block in the Site Editor.
  • Purplish settings for classic themes under WooCommerce > Settings > Products.

常见问题:

How do I change the add to cart button color for each variation in WooCommerce?

Install Purplish. Each variation takes its color from its photo by default, and the add to cart button follows the variation the shopper picks. To set a color yourself, edit the variation and set Page color to Custom.

Does Purplish work with my theme?

Yes. Block themes get every option through WooCommerce's product blocks. Classic themes get the page colors, the photo transition, the title and price rise, and three gallery options.

Does it work with simple products?

Yes. A simple product gets one Page color for its whole page, read from its photo or set by hand.

Do I need color swatches?

No. Purplish works with WooCommerce's plain dropdowns and option buttons. If you set swatch colors on the color attribute, Purplish uses those first. To show a dot of each color on the option buttons, turn on Color dots.

How do I add a hover effect to the WooCommerce product gallery?

On a block theme, open the Single Product template in the Site Editor, select the Product Gallery block, and pick a Hover style in the Purplish panel. The full-screen and slide styles are in the same panel. On a classic theme, pick the hover style under WooCommerce > Settings > Products > Purplish.

Can I change how product cards look on the shop page?

Yes, on block themes. Select the Product Collection block on your shop or collection template and open the Purplish panel. You can put add to cart on the photo, add button motion and pick one of 18 card effects.

A color Purplish found looks wrong. What do I do?

Set the variation's Page color to Custom and pick the color. A busy photo, like a model in a furnished room, can point Purplish at the wrong area.

Why do some option buttons have no color dot?

An option gets a dot only when every variation with it has the same color. A size, or an option that comes in several colors, has no single color to show. On the picked option, the dot turns the button's text color so it stays visible.

Can I turn it off for one variation or product?

Yes. Set its Page color to Off, and it keeps your theme's colors.

What about visitors who turn off motion?

Visitors who turn on reduced motion on their device get the colors without any animation.

Will Purplish slow down my store?

No. Photos are read in the background and the color is saved with the product. The product page loads a small stylesheet. The color script loads only on variable products, and each effect loads only on pages that use it.

Do my product photos leave my site?

No. Purplish reads the photos on your own server, with the image tools PHP already has, and never sends them anywhere.

Does it change WooCommerce's blocks or templates?

No. Purplish adds a panel to WooCommerce's own blocks and styles the parts you choose. Deactivate it, and your store looks exactly as it did before.

Where do I report a security issue?

Please report it privately through the security policy on GitHub, not in the support forum.

更新日志:

1.1.0 1.0.0