OpenGraph 0.3.8: One assignment per scope and honest public cards
OpenGraph 0.3.8 makes assignments safer to manage and makes public share images show only what they really have.
A new assignment no longer replaces an existing one silently. For a scope that already has one, the modal says This scope already has an assignment. Edit that one instead. and offers Edit the existing assignment. When editing, the scope and group are locked. Deleting a template now says how many assignments go with it, and each removed assignment is logged.
On public cards, a wired slot with no value now renders as nothing instead of {{Description}}, and a remote image address is left off the card. The assignment form refuses one for an image slot and asks for a media file. [[site_url]], [[site_host]] and [[page_url]] now come from the configured site address, never from the request’s Host header.
Also: opening New template no longer creates a second template on reconnect, a taken “Untitled N” name moves to the next number, variable names keep only letters, digits and underscores, and Backspace in a focused dropdown no longer deletes the selected element. Cached PNGs are rendered again once, as the cache key changed.
Full release notes: OpenGraph 0.3.8
0.3.8 · 13 October 2026
Added
- Assignments (#14):
Assignments.create/6(refuses a scope that already has an assignment),update/4(saves the row it opened; scope is not an input),get_by_uuid/1,list_for_template/1,count_by_template/0. The admin Edit modal locks scope and group; New points at the existing assignment’s Edit instead of replacing it. - The templates list’s delete confirmation states how many assignments go with the template.
[[global]]entries in the editor’s insert menu show their label and description.
Changed
- Honest public cards. A wired slot with no value renders as nothing
rather than
{{Description}}; a remote http(s) image is left off the card (never a stand-in), and the assignments UI refuses a remote URL for an image slot.[[site_url]],[[site_host]]and[[page_url]]come from the configured origin (:canonical_host_resolver, thesite_urlsetting, the endpoint URL), never the request’sHostheader. /newcreates the template on its connected mount and navigates to/:uuid/edit, so a reconnect no longer creates a second template; a taken “Untitled N” name moves on to the next number.refine_og/4also survives an exit, logs identifiers only, and resolves the post’s group slug to the group uuid for the group tier.- The render cache key hashes only the globals a scene references and no longer includes the module key, so every PNG cached before this release is re-rendered once.
- Deleting a template writes one
assignment.deletedactivity row per cascaded assignment, in the delete’s transaction. - A typed variable name is normalised to letters, digits and underscores.
- Every
phx-changeform also carriesphx-submit; the template name commits on blur or Enter. - The JS bundle now carries only the keyboard hook; pointer gestures belong
to
open_fresco.
Fixed
- Backspace in a focused dropdown no longer deletes the selected element.
Templates.delete/2returns{:error, :not_found}for a template another admin already deleted, instead of raisingEcto.StaleEntryError.
OpenGraph 0.3.8. Install or update: {:phoenix_kit_og, "~> 0.3"}, then mix deps.get && mix phoenix_kit.update. Full history: CHANGELOG.