Note and task ui fixes
This commit is contained in:
@@ -64,7 +64,11 @@ export const NotesSidebar: Component<{
|
||||
n = n.filter(note => note.tags?.includes(getFavoriteTag()));
|
||||
}
|
||||
|
||||
return n;
|
||||
return n.sort((a, b) => {
|
||||
const titleA = a.title || "Untitled";
|
||||
const titleB = b.title || "Untitled";
|
||||
return titleB.localeCompare(titleA);
|
||||
});
|
||||
});
|
||||
|
||||
const handleCreateNote = async () => {
|
||||
|
||||
@@ -434,6 +434,24 @@ export const TaskDetail: Component<TaskDetailProps> = (props) => {
|
||||
<span class="hidden sm:inline">Video</span>
|
||||
</Button>
|
||||
</div>
|
||||
|
||||
{/* File Upload Shortcut */}
|
||||
<div class="flex items-center gap-1 shrink-0">
|
||||
<Button
|
||||
variant="ghost"
|
||||
size="sm"
|
||||
class="h-8 px-1 sm:px-2 text-[0.625rem] font-bold uppercase tracking-wider hover:bg-muted/50 flex items-center gap-1 sm:gap-1.5 text-muted-foreground hover:text-foreground transition-colors"
|
||||
onClick={() => {
|
||||
const instance = editorInstance();
|
||||
if (instance) {
|
||||
instance.chain().focus().uploadFile().run();
|
||||
}
|
||||
}}
|
||||
>
|
||||
<FileText size={14} class="opacity-70" />
|
||||
<span class="hidden sm:inline">File</span>
|
||||
</Button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* Metadata Row (Dates/Timestamps) */}
|
||||
@@ -694,35 +712,7 @@ export const TaskDetail: Component<TaskDetailProps> = (props) => {
|
||||
</PopoverContent>
|
||||
</Popover>
|
||||
|
||||
{/* Close button (Mobile only) */}
|
||||
<Button
|
||||
variant="ghost"
|
||||
size="sm"
|
||||
class="h-8 w-8 p-0"
|
||||
onClick={() => {
|
||||
const instance = editorInstance();
|
||||
if (instance) {
|
||||
instance.chain().focus().uploadVideo().run();
|
||||
}
|
||||
}}
|
||||
title="Video"
|
||||
>
|
||||
<Film class="w-4 h-4" />
|
||||
</Button>
|
||||
<Button
|
||||
variant="ghost"
|
||||
size="sm"
|
||||
class="h-8 w-8 p-0"
|
||||
onClick={() => {
|
||||
const instance = editorInstance();
|
||||
if (instance) {
|
||||
instance.chain().focus().uploadFile().run();
|
||||
}
|
||||
}}
|
||||
title="File"
|
||||
>
|
||||
<FileText class="w-4 h-4" />
|
||||
</Button>
|
||||
|
||||
<Button
|
||||
variant="ghost"
|
||||
size="sm"
|
||||
|
||||
Reference in New Issue
Block a user