Modules
Customizable dashboards for PhoenixKit.
Context for dashboard pages and their widget layouts.
Pure cell-placement math for grid dashboards.
The grid design space: a GAPLESS lattice of nominal 25px square cells.
Read/write a widget instance's geometry in the embedded item shape
Pure helpers for a grid dashboard's layout list — the ordered
config["layouts"] entries (%{"id","name","cols","rows"}), each one exactly
one screenful on the gapless 25px lattice (see PhoenixKitDashboards.Lattice).
Centralized path helpers for the Dashboards module.
Discovers and caches the widget catalog.
A dashboard page: an ordered set of placed widgets owned by a user (personal) or by the system / a role (shared).
The single source of truth for a widget instance's resize bounds.
Presentational function components + their render-only helpers for the
dashboard builder — extracted verbatim from Web.BuilderLive (review #4) so
the LiveView keeps the mount/event/refresh logic and this module owns the
~900 lines of HEEx. BuilderLive imports this module, so its render/1
resolves <.grid> / <.catalog_drawer> / <.settings_modal> here.
The dashboard builder — a responsive, server-rendered grid of widgets that can be added from the catalog, reordered, resized, configured, and removed.
Dedicated create/edit page for a dashboard's metadata (title, layout type, visibility). Replaces the old create modal.
Manage page — lists the current user's personal dashboards, all shared
(system) dashboards, and any role-scoped dashboards for the user's roles.
Creating and editing metadata happens on the dedicated form page
(DashboardFormLive); from here admins open the builder, clone any
visible dashboard into a private editable copy, edit, or delete (own
personal ones + shared/role ones).
Cross-cutting helpers shared by the Dashboards LiveViews.
A widget type — the catalog entry that describes a kind of widget that can be placed on a dashboard.
The built-in widget catalog shipped with this module.
Built-in "Clock" widget — the current time, ticking live, in one of three views, with a per-instance timezone.
Built-in "Module stats" widget — renders the get_config/0 map of any
discovered PhoenixKit module, selected by its module_key setting.
Built-in "Note" widget — a title + free-text body from its settings, with the
body rendered as Markdown (GFM, XSS-sanitized via core's <.markdown>),
so links, lists and emphasis actually work in a pinned note.