UX: Comma separate public custom field lists (#14200)

This commit is contained in:
Kris 2021-08-31 14:08:04 -04:00 committed by GitHub
parent 8f06528bb2
commit 2bf81592ec
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 27 additions and 2 deletions

View File

@ -235,7 +235,13 @@
{{#if uf.value}}
<div class="public-user-field {{uf.field.dasherized_name}}">
<span class="user-field-name">{{uf.field.name}}:</span>
<span class="user-field-value">{{uf.value}}</span>
<span class="user-field-value">
{{#each uf.value as |v|}} {{! some values are arrays }}
<span class="user-field-value-list-item">{{v}}</span>
{{else}}
{{uf.value}}
{{/each}}
</span>
</div>
{{/if}}
{{/each}}

View File

@ -159,7 +159,13 @@
{{#if uf.value}}
<div class="public-user-field {{uf.field.dasherized_name}}">
<span class="user-field-name">{{uf.field.name}}</span>:
<span class="user-field-value">{{uf.value}}</span>
<span class="user-field-value">
{{#each uf.value as |v|}} {{! some values are arrays }}
<span class="user-field-value-list-item">{{v}}</span>
{{else }}
{{uf.value}}
{{/each}}
</span>
</div>
{{/if}}
{{/each}}

View File

@ -362,6 +362,13 @@
.collapsed-info & {
display: none;
}
.user-field-value-list-item:not(:last-of-type) {
&:after {
// create comma separated list
content: ",";
}
}
}
.avatar-selector {

View File

@ -221,6 +221,12 @@ $avatar_margin: -50px; // negative margin makes avatars extend above cards
// custom user fields
.public-user-fields {
margin: 0;
.user-field-value-list-item:not(:last-of-type) {
&:after {
// create comma separated list
content: ",";
}
}
}
// badges