Chrome, slots & nav

Sample documentation (demo only)
This is an incomplete, outdated docs snapshot shipped with the playground — screenshots were removed on purpose.
For the full, current manuals go to voodflow.com/docs.

Voodflow\Voodbuilder\Support\Editor\ChromeBrandLogos

  • File: Support/Editor/ChromeBrandLogos.php
  • Kind: class
  • Responsibility: Resolves desktop/mobile × light/dark logo URLs for nav/footer chrome. Empty slots fall back across the matrix, then to site Appearance logos.

Methods

  • public static function resolve(array $config = []): array
    • desktop_light: ?string, desktop_dark: ?string,
  • public static function normalizeConfigKeys(array $config): array
    • Normalize Config Keys.
  • public static function normalizeSize(mixed $size): string
    • Normalize Size.
  • public static function normalizeShape(mixed $shape): string
    • Normalize Shape.
  • public static function sizeDefinition(mixed $size): array
    • Size Definition.
  • public static function heightClass(mixed $size): string
    • Height Class.
  • public static function squareClass(mixed $size): string
    • Square Class.
  • public static function desktopLogoClass(mixed $size, bool $fullWidth = false): string
    • Desktop Logo Class.
  • public static function mobileLogoClass(mixed $size, bool $fullWidth = false): string
    • Mobile Logo Class.
  • public static function footerLogoClass( mixed $size, bool $logoOnly, bool $desktop = true, bool $fullWidth = false, bool $packageMark = false, mixed $shape = null, ): string
    • Footer logo: natural (wide/contain) by default; optional circular crop. Package default mark always uses object-contain.
  • public static function publicUrl(mixed $value): ?string
    • Public Url.

Voodflow\Voodbuilder\Support\Editor\EditorHostChrome

  • File: Support/Editor/EditorHostChrome.php
  • Kind: class
  • Responsibility: Editor Host Chrome.

Methods

  • public static function markActive(): void
    • Announce editor mode for the current request.
  • public static function isActive(): bool
    • Boolean predicate isActive.
  • public static function shouldSuppressHostRender(?bool $editorEditor = null): bool
    • Should Suppress Host Render.
  • public static function criticalHideCss(): string
    • Critical Hide Css.

Voodflow\Voodbuilder\Support\Editor\EditorSiteChromeSidebarPreview

  • File: Support/Editor/EditorSiteChromeSidebarPreview.php
  • Kind: class
  • Responsibility: Editor Site Chrome Sidebar Preview.

Methods

  • public static function fromPreviewHtml(string $html, string $blockId): string
    • From Preview Html.

Voodflow\Voodbuilder\Support\Editor\EditorSlotHydrator

  • File: Support/Editor/EditorSlotHydrator.php
  • Kind: class
  • Responsibility: Editor Slot Hydrator.

Methods

  • public static function hydrateSubtree(DOMDocument $document, DOMElement $root, bool $preview = false, array $config = []): void
    • Performs hydrateSubtree side effects.
  • public static function hydrateHtml(string $html, bool $preview = false, array $config = []): string
    • Hydrate Html.
  • public static function renderBrand(bool $preview = false, array $config = []): string
    • Render Brand.
  • public static function renderMenuList(string $menuSlug, bool $preview = false, array $config = []): string
    • Render Menu List.
  • protected static function hydrateBrands(DOMDocument $document, DOMElement $root, bool $preview, array $config = []): void
    • Performs hydrateBrands side effects.
  • protected static function resolveConfigForElement(DOMElement $element, array $fallback = []): array
    • Resolve Config For Element.
  • protected static function hydrateMenus(DOMDocument $document, DOMElement $root, bool $preview, array $config = []): void
    • Performs hydrateMenus side effects.
  • protected static function hydrateFooterCopy(DOMDocument $document, DOMElement $root, array $fallback = []): void
    • Apply tagline / copyright from block config onto saved markup.
  • protected static function hydrateFooterColumnTitles(DOMDocument $document, DOMElement $root): void
    • Keep column headings in sync with the assigned menu name (slot hydrate only refreshes nav inner HTML, so saved "Footer column N" would stick).
  • protected static function applyFooterSocialAlign(DOMDocument $document, DOMElement $root, array $config): void
    • Performs applyFooterSocialAlign side effects.
  • protected static function applyFooterChromeVisibility( DOMDocument $document, DOMElement $root, array $config, bool $preview, ): void
    • Performs applyFooterChromeVisibility side effects.
  • protected static function applyFooterColumnsVisibility( DOMDocument $document, DOMElement $root, array $config, bool $preview = false, ): void
    • Performs applyFooterColumnsVisibility side effects.
  • protected static function toggleElementClass(DOMElement $element, string $className, bool $add): void
    • Performs toggleElementClass side effects.
  • protected static function replaceElementInnerHtml(DOMDocument $document, DOMElement $element, string $html): void
    • Performs replaceElementInnerHtml side effects.
  • protected static function loadDocument(string $html): DOMDocument
    • Load Document.
  • protected static function extractBodyHtml(DOMDocument $document): ?string
    • Extract Body Html.

Voodflow\Voodbuilder\Support\Editor\SiteFooterConfig

  • File: Support/Editor/SiteFooterConfig.php
  • Kind: class
  • Responsibility: Site Footer Config.

Methods

  • public static function normalize(array $config): array
    • Normalize markup or attributes into the canonical storage form.
  • public static function defaults(): array
    • Defaults.
  • public static function resolveTagline(?string $value = null): string
    • Resolve Tagline.
  • public static function resolveCopyright(?string $value = null, ?string $brandName = null): string
    • Resolve Copyright.
  • public static function normalizeText(mixed $value): ?string
    • Normalize Text.
  • public static function normalizeSocialAlign(mixed $value): string
    • Normalize Social Align.
  • public static function socialJustifyClass(mixed $align): string
    • Social Justify Class.
  • public static function isChromeVisible(array $config, string $kind): bool
    • Boolean predicate isChromeVisible.
  • public static function isFooterColumnVisible(array $config, int $index): bool
    • Boolean predicate isFooterColumnVisible.
  • public static function chromeAttributes(array $config, string $kind, bool $preview = false): array
    • Chrome Attributes.
  • public static function visibleFooterColumnIndexes(array $config): array
    • Visible Footer Column Indexes.
  • public static function columnsRedistribute(array $config): bool
    • Columns Redistribute.
  • protected static function normalizeFooterColumnFlags(array &$normalized, array $config): void
    • Performs normalizeFooterColumnFlags side effects.

Voodflow\Voodbuilder\Support\Editor\SiteNavConfig

  • File: Support/Editor/SiteNavConfig.php
  • Kind: class
  • Responsibility: Site Nav Config.

Methods

  • public static function normalize(array $config): array
    • Normalize markup or attributes into the canonical storage form.
  • public static function defaults(): array
    • Defaults.
Demo resets in 00:29:40