Skip to content

OpenGraph 0.3.5: The preview switcher uses core's tabs

OpenGraph 0.3.5 rebuilds the editor’s preview switcher on PhoenixKit’s shared tab strip, so it looks like the tabs elsewhere in the admin.

The switcher above the canvas still offers Card, Facebook, X (Twitter), LinkedIn and Discord / Slack, and picking one still wraps the card in that platform’s frame. Only the component behind it changed. The segmented controls in the property panel stay as they were.

Upgrading

The new switcher uses the tab component API that shipped in PhoenixKit 2.13.5. The module’s requirement stays ~> 2.0, so keep core at 2.13.5 or later.

Full release notes: OpenGraph 0.3.5

0.3.5 · 22 August 2026

Changed

  • The preview-platform switcher is core’s <.nav_tabs> instead of a hand-rolled tabs-box strip. Event tabs dispatch phx-value-tab, so the handler now matches %{"tab" => _} rather than %{"platform" => _} (#10). The nine property-panel segmented controls stay radio inputs in phx-change forms — they are not tabs.

  • Dependency lock: phoenix_kit 2.13.5 → 2.13.6. This call site uses the event-tab API that already shipped in 2.13.5 (on_change + phx-value-tab); it does not need :border or verbatim :patch.

Fixed

  • Post-merge: class="tabs-sm p-0.5" was appended to boxed’s baked-in p-1. class can only add, so the two padding utilities fought (stylesheet order, not HTML order — p-1 wins). Dropped p-0.5 and kept tabs-sm. Tab ids are now maps at the source, matching every other event-tab strip.

Added

  • Regression tests for the payload-key contract: a source-level guard that the template is <.nav_tabs> matching %{"tab" => _} and that platform_tabs/0 ids stay in sync with @preview_platforms, plus a LiveView click that wraps the stage in Facebook chrome and proves the old %{"platform" => _} payload is a silent no-op.

OpenGraph 0.3.5. Install or update: {:phoenix_kit_og, "~> 0.3"}, then mix deps.get && mix phoenix_kit.update. Full history: CHANGELOG.