Skip to content

Bug: mixed-case gvid IDs created by variable_create are not emitted on the Divi frontend #13

Description

@undefined3491

Summary

diviops_variable_create accepts and creates Number Variables with mixed-case gvid-* IDs. The Variables pass registry lookup, validate_blocks, and persisted read-back, but Divi 5.11.1 does not emit the matching CSS custom properties on the public frontend.

As a result, valid $variable(...)$ references resolve to an empty value, causing spacing to become 0px or normal.

Environment

  • WordPress version: 7.1
  • Divi theme version: 5.11.1
  • MCP server version: 1.5.40
  • DiviOps Agent plugin version: 1.5.13
  • Hosting environment: public staging site
  • MCP client: Codex desktop (Windows)
  • Node version: v24.18.1

Steps to reproduce

  1. Create a Number Variable through diviops_variable_create.

  2. The tool accepts the write and returns a mixed-case ID. Example from a controlled test:

    gvid-mHHHC2iK
    
  3. Bind the Variable through a normal full $variable(...)$ reference.

  4. Run validate_blocks and perform persisted read-back. Both pass.

  5. Open the public page without an authenticated wp-admin session.

  6. Evaluate:

    getComputedStyle(document.documentElement)
      .getPropertyValue('--gvid-mHHHC2iK')

Actual result

The returned value is empty on desktop, tablet, and mobile.

The frontend CSS contains a reference such as:

var(--gvid-mHHHC2iK)

but Divi does not emit the matching root custom property.

Existing mixed-case spacing Variables show the same failure:

gvid-KJ3j25K9 — 8px
gvid-VdjqrmpT — 16px
gvid-W1fcbmBJ — 24px
gvid-9aP0jmuP — 32px
gvid-o1oo8J9I — 48px

Impact on the public page:

  • rail gap resolves to 0px;
  • information-column padding resolves to 0px;
  • form margin resolves to 0px;
  • mobile row gap resolves to normal.

Additionally, diviops_variable_used_on_page truncates mixed-case IDs at the first uppercase character. For example:

gvid-9aP0jmuP -> gvid-9a

Expected result

Either:

  1. variable_create should generate lowercase-only IDs; or
  2. Divi's frontend emitter and DiviOps parsing should support mixed-case IDs consistently.

At minimum, variable_create or validate_blocks should reject or warn about mixed-case gvid-* IDs before they are bound to a page.

Control case

An existing lowercase Variable ID, for example:

gvid-7udcc8xnsc

is emitted correctly and returns a non-empty value from:

getComputedStyle(document.documentElement)
  .getPropertyValue('--gvid-7udcc8xnsc')

Temporary mitigation

We have disabled new numeric Variable bindings until this is fixed. We do not use hardcoded CSS or Custom CSS as a workaround.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions