This repository has been archived by the owner on Aug 18, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
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 #25 from artsy/staging
Deploy
- Loading branch information
Showing
11 changed files
with
275 additions
and
68 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# Team Navigator | ||
|
||
Artsy's internal team directory. | ||
|
||
Team Nav started off as a hackathon project way back in 2015. It's evolved a lot over the years. This repo is its latest iteration, written in 2020 (see the original project [here](https://github.com/artsy/team-navigator)). | ||
|
||
## Getting started | ||
|
||
**Note**: Team Nav isn't yet configured to be runnable by the open source community | ||
|
||
_For Artsy Employees_ | ||
|
||
1. Copy down the `.env` file from citadel (You'll need proper access) | ||
2. Install dependencies and start the service in dev mode | ||
|
||
``` | ||
yarn && yarn dev | ||
``` | ||
|
||
## About Artsy | ||
|
||
<a href="https://www.artsy.net/"> | ||
<img align="left" src="https://avatars2.githubusercontent.com/u/546231?s=200&v=4"/> | ||
</a> | ||
|
||
This project is the work of engineers at [Artsy][footer_website], the world's | ||
leading and largest online art marketplace and platform for discovering art. | ||
One of our core [Engineering Principles][footer_principles] is being [Open | ||
Source by Default][footer_open] which means we strive to share as many details | ||
of our work as possible. | ||
|
||
You can learn more about this work from [our blog][footer_blog] and by following | ||
[@ArtsyOpenSource][footer_twitter] or explore our public data by checking out | ||
[our API][footer_api]. If you're interested in a career at Artsy, read through | ||
our [job postings][footer_jobs]! | ||
|
||
[footer_website]: https://www.artsy.net/ | ||
[footer_principles]: culture/engineering-principles.md | ||
[footer_open]: culture/engineering-principles.md#open-source-by-default | ||
[footer_blog]: https://artsy.github.io/ | ||
[footer_twitter]: https://twitter.com/ArtsyOpenSource | ||
[footer_api]: https://developers.artsy.net/ | ||
[footer_jobs]: https://www.artsy.net/jobs |
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,49 @@ | ||
import styled from "styled-components"; | ||
import { | ||
compose, | ||
color, | ||
ColorProps, | ||
layout, | ||
LayoutProps, | ||
space, | ||
SpaceProps, | ||
position, | ||
PositionProps, | ||
} from "styled-system"; | ||
import { ComponentPropsWithoutRef } from "react"; | ||
|
||
interface IconProps | ||
extends LayoutProps, | ||
SpaceProps, | ||
PositionProps, | ||
ColorProps {} | ||
const Icon = styled.svg<IconProps>(compose(layout, space, position, color)); | ||
|
||
interface AwardIconProps extends ComponentPropsWithoutRef<typeof Icon> {} | ||
|
||
export function AwardIcon(props: AwardIconProps) { | ||
return ( | ||
<Icon | ||
xmlns="http://www.w3.org/2000/svg" | ||
width="28px" | ||
height="28px" | ||
viewBox="0 -2 24 26" | ||
// fill="#6E1FFF" | ||
fill="currentColor" | ||
stroke="currentColor" | ||
strokeWidth="1.5" | ||
strokeLinecap="round" | ||
strokeLinejoin="round" | ||
{...props} | ||
> | ||
<circle strokeWidth="1" stroke="white" cx="12" cy="8" r="9" /> | ||
<polyline points="8.21 13.89 7 23 12 20 17 23 15.79 13.88"></polyline> | ||
<circle cx="12" cy="8" r="7" /> | ||
<circle strokeWidth="1.5" stroke="white" cx="12" cy="8" r="5.5" /> | ||
</Icon> | ||
); | ||
} | ||
|
||
AwardIcon.defaultProps = { | ||
color: "#6E1FFF", | ||
}; |
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 was deleted.
Oops, something went wrong.
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,42 @@ | ||
import { | ||
isSameWeek, | ||
setYear, | ||
startOfToday, | ||
getYear, | ||
isSameDay, | ||
isAfter, | ||
endOfToday, | ||
differenceInCalendarDays, | ||
} from "date-fns"; | ||
|
||
export const isWeekOf = (date: Date) => { | ||
return isSameWeek(setYear(date, getYear(startOfToday())), startOfToday(), { | ||
weekStartsOn: 1, | ||
}); | ||
}; | ||
|
||
export const isDayOf = (date: Date) => { | ||
return isSameDay(date, setYear(startOfToday(), getYear(date))); | ||
}; | ||
|
||
export const isAfterToday = (date: Date) => { | ||
return isAfter(date, setYear(endOfToday(), getYear(date))); | ||
}; | ||
|
||
export const relativeDaysTillAnniversary = (date: Date) => { | ||
const days = differenceInCalendarDays( | ||
setYear(date, getYear(Date.now())), | ||
Date.now() | ||
); | ||
if (days === 0) { | ||
return "is today"; | ||
} else if (days === 1) { | ||
return "is tomorrow"; | ||
} else if (days === -1) { | ||
return "was yesterday"; | ||
} else if (days > 0) { | ||
return `is in ${days} days`; | ||
} else { | ||
return `was ${days} ago`; | ||
} | ||
}; |
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.