Skip to main content

Theme Configuration (theme.json)

Version Docs Updated

Purpose

theme.json is the configuration hub for global styles, settings, and behavior. It defines the color palette, typography hierarchy, spacing scales, and global block styles.

Global Settings​

🎨 Color Palette​

The theme uses a comprehensive, harmonized color system:

SlugColorNameUsage
base#FFFFFFBaseGlobal background.
surface#F7F7F7SurfaceBackground for sections and cards.
contrast#222222ContrastPrimary text and headings.
accent#0066FFAccentLinks, active states, and primary actions.
cta#FF5A5FCTACall-to-action buttons (e.g., Book Now).
success#00A699SuccessPayouts, confirmed status labels.
warning#FFB400WarningPending IBAN changes or alerts.

πŸ”‘ Typography Hierarchy​

Integrated fonts: Plus Jakarta Sans (Primary) and Inter (Secondary).

Scale (Slug)SizeName
displayclamp(3rem, 6vw, 4.5rem)High-impact homepage headers.
xx-largeclamp(2rem, 4vw, 3rem)Primary page headings.
medium1remStandard body text.
small0.875remFooter links and metadata labels.

πŸ“ Spacing System​

The theme uses proportional spacing steps from 3xs to 3xl:

{
"slug": "xs",
"size": "0.75rem",
"name": "XS"
},
{
"slug": "m",
"size": "1.5rem",
"name": "M"
}

Global Styles​

Core Elements​

theme.json enforces global styles to ensure plugin-generated components inherit the correct theme aesthetics:

"styles": {
"typography": {
"fontFamily": "var(--wp--preset--font-family--jakarta)",
"lineHeight": "1.65"
},
"elements": {
"button": {
"border": { "radius": "9999px" },
"color": { "background": "var(--wp--preset--color--accent)" }
}
}
}

Layout Constraints​

  • Content Size: 1280px (standard width).
  • Wide Size: 1440px (for full-width or wide-aligned sections).
v0.3.0 Change

The page.html template now uses content-wide instead of content-narrow. The max-width value in 3-layout.css has been synchronized to theme.json via var(--wp--style--global--content-size, 1280px). This means changing the content-size in the theme editor automatically updates plugin pages as well.


Why this Architecture Matters​

By centralizing all design tokens in theme.json, the mhm-rentiva plugin can reference these variables directly in its CSS:

/* Inheriting global theme colors in plugin components */
.mhm-payout-card {
background-color: var(--wp--preset--color--surface);
border-color: var(--wp--preset--color--accent-subtle);
}

This "Tight Coupling" ensures that any global color change in the theme editor automatically propagates to:

  • The Booking Widget
  • Vendor Analytics Cards
  • Search Results Grid
  • Payout Management UI

Changelog​

DateVersionNote
23.04.2026v0.3.0English translation applied to Turkish sections.
27.03.2026v0.3.0content-wide layout and CSS variable synchronization documented.
09.03.20264.21.0-docsTheme configuration documentation created.