-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: author details sidebar (#1403)
* feat: add author details sidebar * feat: add chevron in author details stats container * feat: improve date in mobile * feat: add view more grants button * feat: improve typing * feat: clickable only if it has projects * feat: update project status pill colors * fix: proposal card props * feat: hide date on mobile
- Loading branch information
Showing
31 changed files
with
535 additions
and
272 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
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
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 @@ | ||
import { ProjectStatus } from '../../entities/Grant/types' | ||
import { getEnumDisplayName } from '../../helpers' | ||
import Pill, { PillColor } from '../Common/Pill' | ||
|
||
interface Props { | ||
status: ProjectStatus | ||
} | ||
|
||
const STATUS_COLORS: Record<ProjectStatus, PillColor> = { | ||
[ProjectStatus.InProgress]: PillColor.Green, | ||
[ProjectStatus.Finished]: PillColor.Green, | ||
[ProjectStatus.Revoked]: PillColor.Red, | ||
[ProjectStatus.Paused]: PillColor.Gray, | ||
[ProjectStatus.Pending]: PillColor.Gray, | ||
} | ||
|
||
export default function ProjectStatusPill({ status }: Props) { | ||
const displayedStatus = getEnumDisplayName(status) | ||
const style = status === ProjectStatus.InProgress ? 'outline' : 'shiny' | ||
|
||
return ( | ||
<Pill size="sm" color={STATUS_COLORS[status]} style={style}> | ||
{displayedStatus} | ||
</Pill> | ||
) | ||
} |
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
Oops, something went wrong.