mirror of
https://github.com/priyanshujain/margin.git
synced 2026-10-03 03:27:03 +00:00
changes
This commit is contained in:
1 parent
fa1c89af63
commit
78fff9b6f4
1 file changed
+10
-1
@@ -179,7 +179,16 @@ export function Sidebar() {
|
|||||||
</span>
|
</span>
|
||||||
<span className="num">{row.num ?? ""}</span>
|
<span className="num">{row.num ?? ""}</span>
|
||||||
<span className="text">
|
<span className="text">
|
||||||
<span className="title">{row.chapter.title || "Untitled"}</span>
|
<span
|
||||||
|
className="title"
|
||||||
|
onMouseEnter={(e) => {
|
||||||
|
const el = e.currentTarget;
|
||||||
|
if (el.scrollWidth > el.clientWidth) el.title = row.chapter.title || "Untitled";
|
||||||
|
else el.removeAttribute("title");
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
{row.chapter.title || "Untitled"}
|
||||||
|
</span>
|
||||||
{row.chapter.id === activeChapterId && (
|
{row.chapter.id === activeChapterId && (
|
||||||
<span className="meta">Edited {formatEdited(row.chapter.updatedAt, now)}</span>
|
<span className="meta">Edited {formatEdited(row.chapter.updatedAt, now)}</span>
|
||||||
)}
|
)}
|
||||||
|
|||||||
Reference in new issue
Block a user