# `MishkaCmsCoreWeb.Live.Admin.Components.PermissionDetailsModal`
[🔗](https://github.com/mishka-group/mishka_cms_core/blob/v0.0.1/lib/mishka_cms_core_web/live/admin/components/permission_details_modal.ex#L5)

Permission record modal: a read-only **view** (name, description, created/updated) that flips to the
editable `MishkaGervaz.Form.Web.Live` permission form via **Edit Permission** (master users only). Also
hosts the create form when opened with no record (the "+ Add Permission" flow).

Shares the modal shell + card helpers with the other admin record modals through
`MishkaCmsCoreWeb.Live.Admin.Components.DetailModal` (used here without a tab bar — `tabs={[]}`). Driven
by the parent's `@permission_modal` map (`record`, `edit_mode?`, `loading?`, `form_record_id`); the
form's `record_id` flows through the template so the view/edit toggle keeps it mounted. See the parent
`MishkaCmsCoreWeb.Live.Admin.Dashboard.Account.Permission.Index`.

# `modal`

## Attributes

* `permission_modal` (`:map`) (required)
* `current_user` (`:any`) - Defaults to `nil`.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
