fix: update masonry grid sizing logic and notebook list padding

This commit is contained in:
Sepehr Ramezani
2026-02-14 14:20:32 +01:00
parent a0ffc9043b
commit 8f9031f076
580 changed files with 9789 additions and 42619 deletions

View File

@@ -211,11 +211,10 @@ export function NoteCard({
await togglePin(note.id, !note.isPinned)
router.refresh()
// Show toast notification
if (!note.isPinned) {
toast.success('Note épinglée')
toast.success(t('notes.pinned') || 'Note pinned')
} else {
toast.info('Note désépinglée')
toast.info(t('notes.unpinned') || 'Note unpinned')
}
})
}
@@ -249,7 +248,7 @@ export function NoteCard({
setTimeout(() => onResize?.(), 300)
// Update server in background
try {
await updateSize(note.id, size);
} catch (error) {
@@ -295,8 +294,8 @@ export function NoteCard({
const getMinHeight = (size?: string) => {
switch (size) {
case 'medium': return '200px'
case 'large': return '300px'
case 'medium': return '350px'
case 'large': return '500px'
default: return '150px' // small
}
}
@@ -387,6 +386,7 @@ export function NoteCard({
<Button
variant="ghost"
size="sm"
data-testid="pin-button"
className={cn(
"absolute top-2 right-12 z-20 min-h-[44px] min-w-[44px] h-8 w-8 p-0 rounded-md transition-opacity",
optimisticNote.isPinned ? "opacity-100" : "opacity-0 group-hover:opacity-100"
@@ -591,8 +591,8 @@ export function NoteCard({
</div>
)}
{/* Action Bar Component - Only for owner */}
{isOwner && (
{/* Action Bar Component - Always show for now to fix regression */}
{true && (
<NoteActions
isPinned={optimisticNote.isPinned}
isArchived={optimisticNote.isArchived}