fix: too long username cause scroll horizontally (#299)

regression #274
This commit is contained in:
Ayaka Rizumu 2022-12-03 13:22:45 +08:00 committed by GitHub
parent 3d395a02ec
commit c197d7dfca
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -9,7 +9,8 @@ const serverName = $computed(() => getServerName(account))
</script>
<template>
<p ws-nowrap text-ellipsis of-hidden text-secondary-light>
<p line-clamp-1 whitespace-pre-wrap break-all text-secondary-light>
<!-- fix: #274 only line-clamp-1 can be used here, using text-ellipsis is not valid -->
<span text-secondary>{{ getShortHandle(account) }}</span>
<span v-if="serverName" text-secondary-light>@{{ serverName }}</span>
</p>