Business · Gutenberg

Location Cards block for WordPress

Multi-location business directory grid. Each card shows address, phone, email, business hours snippet, and a directions link.

Get Blockenberg

Free Gutenberg block in Blockenberg. The inspector controls and front-end behavior on this page come from this block’s source, not a shared stub.

Get Blockenberg

What it actually does

Multi-location business directory grid. Each card shows address, phone, email, business hours snippet, and a directions link.

Inspector panels on this block: Display Settings, Layout, Locations. Those titles come from index.js, not from a shared template.

Behavior controls: “Card Style” options: Card (border + shadow), Flat (border only), Ghost (no border); “Hover Effect” options: Lift (shadow), Border Glow, None; “Image Aspect Ratio” options: 16:9, 4:3, 1:1, 3:2.

Where to find it

Gutenberg inserter → Business → search “Location Cards” (block name `blockenberg/location-cards` in block.json). Style it in the sidebar after insert.

How to use Location Cards block for WordPress

  1. Install Blockenberg. Install from WordPress.org and activate the plugin.
  2. Insert the block. Edit a page, click +, search for “Location Cards”, insert it. Category: Business.
  3. Configure inspector controls that exist on this block. Open Display Settings. Set “Show Location Image”, “Show Phone Number”, “Show Email”, “Show Website”.
  4. Check the published page. The view script reads HTML data attributes: data-address. The block editor preview may not run the same view script.

Inspector controls from this block’s code

ControlWhat the code does
Show Location ImageOn/off toggle in the inspector. On by default. Saved as `showImage`.
Show Phone NumberOn/off toggle in the inspector. On by default. Saved as `showPhone`.
Show EmailOn/off toggle in the inspector. On by default. Saved as `showEmail`.
Show WebsiteOn/off toggle in the inspector. Off by default. Saved as `showWebsite`.
Show HoursOn/off toggle in the inspector. On by default. Saved as `showHours`.
Show Directions ButtonOn/off toggle in the inspector. On by default. Saved as `showDirectionsLink`.
Directions Button LabelText field in the inspector. block.json default: Get Directions. Saved as `directionsLabel`.
Columns (Desktop)Numeric range control in the inspector. Range 1–4. block.json default: 3. Saved as `columns`.
Columns (Tablet)Numeric range control in the inspector. Range 1–3. block.json default: 2. Saved as `columnsTablet`.
Columns (Mobile)Numeric range control in the inspector. Range 1–2. block.json default: 1. Saved as `columnsMobile`.
Gap Between Cards (px)Numeric range control in the inspector. Range 0–80. block.json default: 24. Saved as `gap`.
Card StyleSelect control; the chosen value is saved on the block. Options: Card (border + shadow); Flat (border only); Ghost (no border). block.json default: card. Saved as `cardStyle`.
Hover EffectSelect control; the chosen value is saved on the block. Options: Lift (shadow); Border Glow; None. block.json default: lift. Saved as `hoverEffect`.
Image Aspect RatioSelect control; the chosen value is saved on the block. Options: 16:9; 4:3; 1:1; 3:2. block.json default: 16/9. Saved as `imageRatio`.
Card Border RadiusNumeric range control in the inspector. Range 0–40. block.json default: 16. Saved as `cardRadius`.
Card PaddingNumeric range control in the inspector. Range 8–60. block.json default: 24. Saved as `cardPadding`.
Image Border RadiusNumeric range control in the inspector. Range 0–40. block.json default: 0. Saved as `imageRadius`.
Button Border RadiusNumeric range control in the inspector. Range 0–40. block.json default: 8. Saved as `btnRadius`.
Padding Top (px)Numeric range control in the inspector. Range 0–200. block.json default: 64. Saved as `paddingTop`.
Padding Bottom (px)Numeric range control in the inspector. Range 0–200. block.json default: 64. Saved as `paddingBottom`.
NameText field in the inspector.
Street AddressText field in the inspector.
CityText field in the inspector.
State / ProvinceText field in the inspector.
ZIP / PostcodeText field in the inspector.
CountryText field in the inspector.
PhoneText field in the inspector.
EmailText field in the inspector.
WebsiteText field in the inspector.
Google Maps URLText field in the inspector.
Hours SnippetText field in the inspector.

What the front-end script actually does

When this is the right block

Notes from the implementation

viewScript: this folder’s frontend.js is enqueued on the front end for this block.

FAQ

How do I add the Location Cards block in WordPress?

Install Blockenberg from WordPress.org, edit a page in the block editor, click +, and search for “Location Cards”. It sits under Business. After insert, open Display Settings and set “Show Location Image”, “Show Phone Number”, “Show Email”, “Show Website”.

What makes Location Cards different from other Blockenberg blocks?

Multi-location business directory grid. Each card shows address, phone, email, business hours snippet, and a directions link. Inspector labels on this block include “Show Location Image”, “Show Phone Number”, “Show Email”, “Show Website”.

Is the Location Cards Gutenberg block free?

Yes. Location Cards ships inside Blockenberg. Get the plugin from WordPress.org — no paid add-on is required for this block.

Can I style Location Cards to match my theme?

Yes. Blockenberg’s shared typography and color panels apply here, plus any block-specific style controls listed on this page (panels: Display Settings, Layout, Locations).

Related business blocks

Get Blockenberg

Install Blockenberg from WordPress.org, then insert Location Cards from the Gutenberg inserter.

Get Blockenberg