stream settings: Add checks to render br tags only when required.

This is required as we added `br` tags irrespective of whether
there were any users in the subscribed or already subscribed
category. This made the spacing here look odd. We now include
br tags inside conditionals to render them only when required.
This commit is contained in:
m-e-l-u-h-a-n
2021-06-23 00:15:45 +05:30
committed by Tim Abbott
parent ffb811ef6e
commit a2b50bacee

View File

@@ -2,16 +2,20 @@
{{message}}
<br />
{{/if}}
{{#each subscribed_users}}
{{#if @first}}
{{t "Successfully subscribed users:" }}
{{/if}}
<a data-user-id="{{user_id}}" class="view_user_profile">{{full_name}}</a>{{#unless @last}},{{else}}.{{/unless}}
{{/each}}
<br />
{{#each already_subscribed_users}}
{{#if @first}}
{{t "Already subscribed users:" }}
{{/if}}
<a data-user-id="{{user_id}}" class="view_user_profile">{{full_name}}</a>{{#unless @last}},{{else}}.{{/unless}}
{{/each}}
{{#if subscribed_users}}
{{#each subscribed_users}}
{{#if @first}}
{{t "Successfully subscribed users:" }}
{{/if}}
<a data-user-id="{{user_id}}" class="view_user_profile">{{full_name}}</a>{{#unless @last}},{{else}}.{{/unless}}
{{/each}}
<br />
{{/if}}
{{#if already_subscribed_users}}
{{#each already_subscribed_users}}
{{#if @first}}
{{t "Already subscribed users:" }}
{{/if}}
<a data-user-id="{{user_id}}" class="view_user_profile">{{full_name}}</a>{{#unless @last}},{{else}}.{{/unless}}
{{/each}}
{{/if}}