chore: format
This commit is contained in:
1 parent
f1be85d997
commit
5dae600ce7
81 files changed
+247
-140
No files matched your search
@@ -232,7 +232,10 @@
|
||||
pinnedChats.set(_pinnedChats);
|
||||
})(),
|
||||
await (async () => {
|
||||
if ($config?.features?.enable_notes && ($user?.role === 'admin' || ($user?.permissions?.features?.notes ?? true))) {
|
||||
if (
|
||||
$config?.features?.enable_notes &&
|
||||
($user?.role === 'admin' || ($user?.permissions?.features?.notes ?? true))
|
||||
) {
|
||||
console.log('Init pinned notes');
|
||||
const _pinnedNotes = await getPinnedNoteList(localStorage.token).catch(() => []);
|
||||
pinnedNotes.set(_pinnedNotes);
|
||||
@@ -1119,13 +1122,26 @@
|
||||
class="invisible group-hover:visible self-center p-0.5 hover:bg-gray-200 dark:hover:bg-gray-800 rounded-lg transition"
|
||||
on:click|preventDefault|stopPropagation={async () => {
|
||||
await toggleNotePinnedStatusById(localStorage.token, note.id);
|
||||
const _pinnedNotes = await getPinnedNoteList(localStorage.token).catch(() => []);
|
||||
const _pinnedNotes = await getPinnedNoteList(localStorage.token).catch(
|
||||
() => []
|
||||
);
|
||||
pinnedNotes.set(_pinnedNotes);
|
||||
}}
|
||||
aria-label={$i18n.t('Unpin')}
|
||||
>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" class="size-3.5">
|
||||
<path stroke-linecap="round" stroke-linejoin="round" d="M6 18 18 6M6 6l12 12" />
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
fill="none"
|
||||
viewBox="0 0 24 24"
|
||||
stroke-width="2"
|
||||
stroke="currentColor"
|
||||
class="size-3.5"
|
||||
>
|
||||
<path
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
d="M6 18 18 6M6 6l12 12"
|
||||
/>
|
||||
</svg>
|
||||
</button>
|
||||
</a>
|
||||
|
||||
Reference in new issue
Block a user