This repository has been archived by the owner on Apr 22, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #81 from factchain/polishes
bunch of visual polishes
- Loading branch information
Showing
16 changed files
with
150 additions
and
73 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
26 changes: 26 additions & 0 deletions
26
fc-community-extension/src/pages/components/FCEmptyState.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
const IconNotebook = ({ size, ...p }) => { | ||
return ( | ||
<svg | ||
fill="currentColor" | ||
viewBox="0 0 16 16" | ||
height={size} | ||
width={size} | ||
{...p} | ||
> | ||
<path d="M4.98 4a.5.5 0 00-.39.188L1.54 8H6a.5.5 0 01.5.5 1.5 1.5 0 103 0A.5.5 0 0110 8h4.46l-3.05-3.812A.5.5 0 0011.02 4H4.98zm9.954 5H10.45a2.5 2.5 0 01-4.9 0H1.066l.32 2.562a.5.5 0 00.497.438h12.234a.5.5 0 00.496-.438L14.933 9zM3.809 3.563A1.5 1.5 0 014.981 3h6.038a1.5 1.5 0 011.172.563l3.7 4.625a.5.5 0 01.105.374l-.39 3.124A1.5 1.5 0 0114.117 13H1.883a1.5 1.5 0 01-1.489-1.314l-.39-3.124a.5.5 0 01.106-.374l3.7-4.625z" /> | ||
</svg> | ||
); | ||
}; | ||
|
||
const FCEmptyState = ({ text }) => { | ||
return ( | ||
<div className="absolute inset-0 flex items-center justify-center"> | ||
<div className="flex flex-col gap-4 rounded-2xl bg-neutral-950/30 items-center p-8"> | ||
<IconNotebook className="opacity-10" size={64} /> | ||
<div className="text-sm opacity-60">{text}</div> | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default FCEmptyState; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
import { elipseText } from '../../utils/constants'; | ||
|
||
const FCNote = (props) => { | ||
// assuming `postUrl` looks like: https://x.com/foo/status/<id> | ||
const postId = props.postUrl.split('/').slice(-1)[0]; | ||
return ( | ||
<a | ||
href={props.postUrl} | ||
target="_blank" | ||
rel="noreferrer noopener" | ||
className="bg-fcGrey/70 rounded-md p-2 text-xs space-y-2 shadow block hover:bg-fcGrey/90" | ||
> | ||
<div className="flex items-center gap-2"> | ||
<div className="shrink-0 w-[24px] h-[24px] rounded-full bg-pink-400/30"></div> | ||
<div className="truncate"> | ||
<strong>{elipseText(props.creator, 10)}</strong> | ||
<span className="opacity-70">{' - '}</span> | ||
<span className="italic">{postId}</span> | ||
</div> | ||
</div> | ||
<div className="flex items-start gap-2"> | ||
<div className="opacity-90 line-clamp-4 flex-grow">{props.content}</div> | ||
<div className="shrink-0 flex flex-col gap-1 items-center"> | ||
<div className="w-[32px] h-[32px] bg-pink-400/30 rounded"></div> | ||
<div className="flex items-center gap-1"> | ||
{/* TODO proper note + dynamic image based on note */} | ||
<strong>{'4.9'}</strong> | ||
<span> | ||
<img | ||
className="w-[16px] h-[16px]" | ||
alt="star-awesome" | ||
src="/ui/icons/star-awesome.png" | ||
/> | ||
</span> | ||
</div> | ||
</div> | ||
</div> | ||
</a> | ||
); | ||
}; | ||
|
||
export default FCNote; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters