fix: branch protection user list (#38570)

fix #38569, also fix the UI
This commit is contained in:
wxiaoguang
2026-07-23 02:48:39 +08:00
committed by GitHub
parent 4563c2c1b7
commit ae2ff1b467
11 changed files with 23 additions and 21 deletions
+1 -1
View File
@@ -133,7 +133,7 @@ function initDropdownUserRemoteSearch(el: Element) {
processedResults.length = 0;
for (const item of resp.results) {
const htmlAvatar = html`<img class="ui avatar tw-align-middle" src="${item.avatar_link}" aria-hidden="true" alt width="20" height="20">`;
const htmlFullName = item.full_name ? html`<span class="username-fullname gt-ellipsis">(${item.full_name})</span>` : '';
const htmlFullName = item.full_name ? html`<span class="username-fullname">(${item.full_name})</span>` : '';
const htmlItem = html`<span class="username-display">${htmlRaw(htmlAvatar)}<span>${item.username}</span>${htmlRaw(htmlFullName)}</span>`;
if (selectedUsername.toLowerCase() === item.username.toLowerCase()) selectedUsername = item.username;
processedResults.push({value: item.username, name: htmlItem});