chore: update user profile page

This commit is contained in:
Steven
2023-09-10 10:33:22 +08:00
parent 44be7201c0
commit 3df550927d
24 changed files with 74 additions and 195 deletions

View File

@ -216,17 +216,15 @@ const Memo: React.FC<Props> = (props: Props) => {
};
const handleMemoCreatedTimeClick = (e: React.MouseEvent) => {
if (e.altKey) {
e.preventDefault();
showChangeMemoCreatedTsDialog(memo.id);
}
e.preventDefault();
showChangeMemoCreatedTsDialog(memo.id);
};
return (
<>
<div className={`memo-wrapper ${"memos-" + memo.id} ${memo.pinned && !readonly ? "pinned" : ""}`} ref={memoContainerRef}>
<div className="memo-top-wrapper">
<p className="w-full max-w-[calc(100%-20px)] flex flex-row justify-start items-center mr-1">
<div className="w-full max-w-[calc(100%-20px)] flex flex-row justify-start items-center mr-1">
{creator && (
<>
<Link className="flex flex-row justify-start items-center" to={`/u/${memo.creatorUsername}`}>
@ -236,10 +234,10 @@ const Memo: React.FC<Props> = (props: Props) => {
<Icon.Dot className="w-4 h-auto text-gray-400 dark:text-zinc-400" />
</>
)}
<span className="text-sm text-gray-400" onClick={handleMemoCreatedTimeClick}>
<span className="text-sm text-gray-400 select-none" onDoubleClick={handleMemoCreatedTimeClick}>
{displayTime}
</span>
</p>
</div>
<div className="btns-container space-x-2">
{!readonly && (
<>