DEV: Create new component to reify the user fields (#7655)

This commit is contained in:
Roman Rizzi 2019-05-30 16:17:16 -03:00 committed by GitHub
parent c4fa20d644
commit c169456ee5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 18 additions and 14 deletions

View File

@ -0,0 +1,6 @@
{{#if value }}
<div class={{classes}}>
<div class='name'>{{name}}</div>
<div class='value'>{{value}}</div>
</div>
{{/if}}

View File

@ -12,21 +12,19 @@
{{/if}}
</div>
</div>
{{#if reviewable.payload.name}}
<div class='reviewable-user-details name'>
<div class='name'>{{i18n "review.user.name"}}</div>
<div class='value'>{{reviewable.payload.name}}</div>
</div>
{{/if}}
<div class='reviewable-user-details email'>
<div class='name'>{{i18n "review.user.email"}}</div>
<div class='value'>{{reviewable.payload.email}}</div>
</div>
{{reviewable-field classes='reviewable-user-details name'
name=(i18n 'review.user.name')
value=reviewable.payload.name}}
{{reviewable-field classes='reviewable-user-details email'
name=(i18n 'review.user.email')
value=reviewable.payload.email}}
{{#each userFields as |f|}}
<div class='reviewable-user-details user-field'>
<div class='name'>{{f.name}}</div>
<div class='value'>{{f.value}}</div>
</div>
{{reviewable-field classes='reviewable-user-details user-field'
name=f.name
value=f.value}}
{{/each}}
</div>