refactor: 💡 replace renderTemplate with components

This commit is contained in:
Randall Morey committed 2022-01-14 15:09:15 -05:00
1 parent ff9c659ada
commit 0d1dfb23b2
10 files changed
+162 -173

No files matched your search

@@ -0,0 +1,21 @@
<Rose::Dropdown
@text='{{t 'actions.manage'}}'
@dropdownRight={{true}}
as |dropdown|
>
{{#if (can 'addAccounts user' @model)}}
<dropdown.link @route='scopes.scope.users.user.add-accounts'>
{{t 'resources.user.actions.add-accounts'}}
</dropdown.link>
{{/if}}
{{#if (can 'delete model' @model)}}
<dropdown.separator />
<dropdown.button
@style='danger'
@disabled={{@model.canSave}}
{{on 'click' (route-action 'delete' @model)}}
>
{{t 'resources.user.actions.delete'}}
</dropdown.button>
{{/if}}
</Rose::Dropdown>
@@ -0,0 +1,12 @@
<h2>
{{t 'resources.user.title'}}
<DocLink @doc='user' @iconSize='large' />
</h2>
<p>{{t 'resources.user.description'}}</p>
<Copyable
@text={{@model.id}}
@buttonText={{t 'actions.copy-to-clipboard'}}
@acknowledgeText={{t 'states.copied'}}
>
<code>{{@model.id}}</code>
</Copyable>
@@ -0,0 +1,8 @@
<Rose::Nav::Tabs as |nav|>
<nav.link @route='scopes.scope.users.user.index'>
{{t 'titles.details'}}
</nav.link>
<nav.link @route='scopes.scope.users.user.accounts'>
{{t 'resources.user.messages.accounts.title'}}
</nav.link>
</Rose::Nav::Tabs>