../generateblocks-layouts/references/dynamic-tags.md — REQUIRED for any
dynamic content. Tag syntax is {{tag option:value|option2:value}} —
wrong syntax saves fine but renders as literal text.
For Elementor Posts/Loop widgets, build the GB equivalent with the V2 Query
block family — see ../generateblocks-layouts/references/query-block.md.
For Elementor widgets that map to Pro features (accordion, tabs, carousel,
sticky header), see ../generateblocks-layouts/references/gb-pro.md.
Output Requirements
ALWAYS output converted blocks to a file, never inline in the chat.
When converting Elementor without CSS values, infer styles based on context:
Default GeneratePress Design System
Use these defaults when no specific styles are provided:
Colors:
Primary: #0073e6 (GeneratePress default accent)
Text: #222222
Muted text: #757575
Background: #ffffff
Light background: #f7f8f9
Border: #e0e0e0
Typography:
Body: 17px, line-height 1.7
H1: 42px, font-weight 600
H2: 35px, font-weight 600
H3: 29px, font-weight 600
H4: 24px, font-weight 600
Spacing:
Section padding: 60px top/bottom
Container max-width: var(--gb-container-width)
Content padding: 20px
Gap between elements: 20px
Buttons:
Padding: 15px 30px
Border-radius: 4px
Background: primary color
Hover: darken 10%
Site-Specific Inference
When the target site is known, extract design tokens from:
Theme's style.css - Primary colors, fonts, base sizes
theme.json (block themes) - Color palette, typography presets
Existing pages - Match the established visual language
Anything you infer (rather than copy from the Elementor source) must pass
the anti-slop gate in ../generateblocks-layouts/SKILL.md ("Design quality
— no slop") — load the /design-slop skill when available. Elementor
sources are often slop-heavy themselves (decorative gradients, card soup,
thick rounded borders); flattening the DOM is also the moment to drop those.
Example inference for gauravtiwari.org:
{"colors":{"primary":"#c0392b","text":"#0a0a0a","muted":"#5c5c5c","background":"#ffffff","lightBg":"#f5f5f3","border":"#e5e5e5"},"typography":{"body":"1rem","h1":"clamp(2rem, 5vw, 3.5rem)","h2":"clamp(1.5rem, 3vw, 2.5rem)","fontWeight":"900 for headings"},"spacing":{"sectionPadding":"4rem","containerMax":"var(--gb-container-width)","gap":"1rem to 2rem"},"effects":{"borderRadius":"1rem for cards, 2rem for buttons","hoverLift":"translateY(-6px)","shadow":"0 20px 60px rgba(0,0,0,0.15)"}}
CRITICAL: No Extra HTML Comments
⛔ NEVER add HTML comments other than WordPress block markers.
The ONLY allowed comments are WordPress block delimiters:
<!-- wp:generateblocks/element {...} --> and <!-- /wp:generateblocks/element -->
<!-- wp:generateblocks/text {...} --> and <!-- /wp:generateblocks/text -->
<!-- wp:generateblocks/media {...} --> and <!-- /wp:generateblocks/media -->
<!-- wp:generateblocks/shape {...} --> and <!-- /wp:generateblocks/shape -->
<!-- wp:image {...} --> and <!-- /wp:image -->
<!-- wp:video {...} --> and <!-- /wp:video -->
<!-- wp:gallery {...} --> and <!-- /wp:gallery -->
Any other <!-- wp:{namespace}/{block} --> format
WRONG - These will break the block editor:
<!-- This is a card --><!-- Hero section --><!-- Converted from Elementor -->
Note:linkHtmlAttributes (media blocks) is also a plain object: {"href":"https://...","target":"_blank"}.
2. Always Include Both styles and css
Every block needs:
styles object with camelCase properties (supports responsive keys like "@media (max-width:1024px)":{...})
css string with minified CSS (kebab-case, alphabetically sorted, base styles only)
The css attribute must NOT contain hover states or transitions (the plugin generates those from the styles object)
Exceptions that go in css: pseudo-elements (::before/::after), media queries, animations, parent hover targeting children
3. Element Blocks Need className (Option A)
Add "className":"gb-element" — the base class only, serialized last. The
plugin injects gb-element-{id} into the rendered class list; never
duplicate the id-class into className. HTML class order stays
gb-element-{id} gb-element: