design: better list

This commit is contained in:
Julien Calixte
2026-02-13 23:54:56 +01:00
parent 1baa9794ba
commit 7ab4d64dea
2 changed files with 29 additions and 14 deletions

View File

@@ -31,7 +31,6 @@ const getAlias = (did: string) => aka.value.get(did) ?? ""
<ul class="list rounded-box shadow-sm">
<li v-for="note in state.notes" class="list-row">
<div class="list-col">
<div>
<router-link
:to="{
name: 'PublicNoteView',
@@ -40,8 +39,7 @@ const getAlias = (did: string) => aka.value.get(did) ?? ""
class="btn btn-link"
>{{ note.title }}</router-link
>
</div>
<div class="text-xs uppercase font-semibold opacity-60">
<div class="text-xs opacity-80 alias">
<span v-if="getAlias(note.did)">
{{ getAlias(note.did) }}
</span>
@@ -87,10 +85,28 @@ const getAlias = (did: string) => aka.value.get(did) ?? ""
margin-top: 1rem;
}
a {
a.back-button {
display: flex;
gap: 0.5rem;
align-items: center;
}
li {
display: flex;
.list-col {
display: flex;
flex-direction: column;
flex: 1;
}
a {
text-align: left;
}
.alias {
text-align: right;
}
}
}
</style>

View File

@@ -70,6 +70,7 @@ const content = computed(() =>
>{{ title }}</a
>
</div>
<span class="badge badge-accent">{{ alias }}</span>
<article v-html="content"></article>
</div>
</div>
@@ -118,12 +119,10 @@ const content = computed(() =>
}
.note {
position: sticky;
display: flex;
flex-direction: column;
overflow-y: auto;
height: 100vh;
position: sticky;
.title {
text-align: left;