Skip to content

Papermark is the open-source DocSend alternative and secure data rooms with built-in analytics and custom domains.

Refactor: Improve cursor and text alignment in cards

Cursor Agente863df6ea85c
diff --git a/components/view/dataroom/document-card.tsx b/components/view/dataroom/document-card.tsx
index fad26233..e981ba06 100644
--- a/components/view/dataroom/document-card.tsx
+++ b/components/view/dataroom/document-card.tsx
@@ -206,10 +206,10 @@ export default function DocumentCard({
>
<button
onClick={handleDocumentClick}
- className="w-full truncate"
+ className="cursor-pointer text-left"
disabled={isProcessing}
>
- <span>{displayName}</span>
+ {displayName}
{isProcessing && (
<span className="ml-2 text-xs text-muted-foreground">
(Processing...)
diff --git a/components/view/dataroom/folder-card.tsx b/components/view/dataroom/folder-card.tsx
index 45eb9c8e..f7ab2520 100644
--- a/components/view/dataroom/folder-card.tsx
+++ b/components/view/dataroom/folder-card.tsx
@@ -112,13 +112,13 @@ export default function FolderCard({
className="min-w-0 max-w-[300px] truncate text-sm font-semibold leading-6 text-foreground sm:max-w-lg"
style={HIERARCHICAL_DISPLAY_STYLE}
>
- <div
+ <span
onClick={() => setFolderId(folder.id)}
- className="w-full truncate"
+ className="cursor-pointer"
>
- <span>{displayName}</span>
+ {displayName}
<span className="absolute inset-0" />
- </div>
+ </span>
</h2>
</div>
<div className="mt-1 flex items-center space-x-1 text-xs leading-5 text-muted-foreground">