mirror of
https://github.com/chillpadclub/bedolaga-cabinet.git
synced 2026-07-30 10:27:49 +00:00
feat: add translations for permission sections and actions
Translate all permission section names (users, tickets, etc.) and action names (read, edit, delete, etc.) in ru/en/zh/fa locales. Apply translations in PermissionMatrix, PolicyEdit, and Policies list.
This commit is contained in:
@@ -360,12 +360,17 @@ export default function AdminPolicies() {
|
||||
|
||||
{/* Resource + actions */}
|
||||
<div className="mb-2 flex flex-wrap items-center gap-2 text-sm">
|
||||
<span className="rounded bg-dark-700 px-2 py-0.5 font-mono text-xs text-accent-400">
|
||||
{policy.resource}
|
||||
<span className="rounded bg-dark-700 px-2 py-0.5 text-xs text-accent-400">
|
||||
{t(
|
||||
`admin.roles.form.permissionSections.${policy.resource}`,
|
||||
policy.resource,
|
||||
)}
|
||||
</span>
|
||||
<span className="text-dark-500">:</span>
|
||||
<span className="font-mono text-xs text-dark-300">
|
||||
{(policy.actions ?? []).join(', ')}
|
||||
<span className="text-xs text-dark-300">
|
||||
{(policy.actions ?? [])
|
||||
.map((a) => t(`admin.roles.form.permissionActions.${a}`, a))
|
||||
.join(', ')}
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user