diff --git a/components/account/AccountHeader.vue b/components/account/AccountHeader.vue index ffe610b8..b1d63781 100644 --- a/components/account/AccountHeader.vue +++ b/components/account/AccountHeader.vue @@ -81,6 +81,8 @@ watchEffect(() => { iconFields.value = icons }) +const personalNoteDraft = ref(relationship?.note ?? '') + async function editNote(event: Event) { if (!event.target || !('value' in event.target) || !relationship) return @@ -92,10 +94,13 @@ async function editNote(event: Event) { const newNoteApiResult = await client.v1.accounts.createNote(account.id, { comment: newNote }) relationship.note = newNoteApiResult.note + personalNoteDraft.value = relationship.note ?? '' } const isSelf = $(useSelfAccount(() => account)) const isNotifiedOnPost = $computed(() => !!relationship?.notifying) + +const personalNoteMaxLength = 2000