-
Notifications
You must be signed in to change notification settings - Fork 54
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(single datepicker): add single datepicker
affects: @datepicker-react/hooks, @datepicker-react/styled
- Loading branch information
Showing
24 changed files
with
11,144 additions
and
1,541 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,47 @@ | ||
--- | ||
name: Bug report | ||
about: Create a report to help us improve | ||
title: '' | ||
labels: '' | ||
assignees: '' | ||
|
||
--- | ||
|
||
**@datepicker-react/hooks or @datepicker-react/styled version** | ||
e.g. @datepicker-react/hooks@1.0.0 | ||
|
||
**Describe the bug** | ||
A clear and concise description of what the bug is. | ||
|
||
**Source code (including props configuration)** | ||
Steps to reproduce the behavior: | ||
``` | ||
<DateRangeInput | ||
onDatesChange={data => dispatch({type: 'dateChange', payload: data})} | ||
onFocusChange={focusedInput => dispatch({type: 'focusChange', payload: focusedInput})} | ||
startDate={state.startDate} // Date or null | ||
endDate={state.endDate} // Date or null | ||
focusedInput={state.focusedInput} // START_DATE, END_DATE or null | ||
/> | ||
``` | ||
If you have custom methods that you are passing into a `@datepicker-react` component / hooks, please include the source for those as well. | ||
|
||
**Screenshots/Gifs** | ||
If applicable, add screenshots or gifs to help explain your problem. | ||
|
||
**Desktop (please complete the following information):** | ||
- OS: [e.g. iOS] | ||
- Browser [e.g. chrome, safari] | ||
- Version [e.g. 22] | ||
|
||
**Smartphone (please complete the following information):** | ||
- Device: [e.g. iPhone6] | ||
- OS: [e.g. iOS8.1] | ||
- Browser [e.g. stock browser, safari] | ||
- Version [e.g. 22] | ||
|
||
**Is the issue reproducible in Storybook?** | ||
Please link to the relevant storybook example | ||
|
||
**Additional context** | ||
Add any other context about the problem here. |
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,68 @@ | ||
# Contributor Covenant Code of Conduct | ||
|
||
## Our Pledge | ||
|
||
In the interest of fostering an open and welcoming environment, we as contributors and maintainers | ||
pledge to making participation in our project and our community a harassment-free experience for | ||
everyone, regardless of age, body size, disability, ethnicity, sex characteristics, gender identity | ||
and expression, level of experience, education, socio-economic status, nationality, personal | ||
appearance, race, religion, or sexual identity and orientation. | ||
|
||
## Our Standards | ||
|
||
Examples of behavior that contributes to creating a positive environment include: | ||
|
||
- Using welcoming and inclusive language | ||
- Being respectful of differing viewpoints and experiences | ||
- Gracefully accepting constructive criticism | ||
- Focusing on what is best for the community | ||
- Showing empathy towards other community members | ||
|
||
Examples of unacceptable behavior by participants include: | ||
|
||
- The use of sexualized language or imagery and unwelcome sexual attention or advances | ||
- Trolling, insulting/derogatory comments, and personal or political attacks | ||
- Public or private harassment | ||
- Publishing others' private information, such as a physical or electronic address, without explicit | ||
permission | ||
- Other conduct which could reasonably be considered inappropriate in a professional setting | ||
|
||
## Our Responsibilities | ||
|
||
Project maintainers are responsible for clarifying the standards of acceptable behavior and are | ||
expected to take appropriate and fair corrective action in response to any instances of unacceptable | ||
behavior. | ||
|
||
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, | ||
code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or | ||
to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, | ||
threatening, offensive, or harmful. | ||
|
||
## Scope | ||
|
||
This Code of Conduct applies both within project spaces and in public spaces when an individual is | ||
representing the project or its community. Examples of representing a project or community include | ||
using an official project e-mail address, posting via an official social media account, or acting as | ||
an appointed representative at an online or offline event. Representation of a project may be | ||
further defined and clarified by project maintainers. | ||
|
||
## Enforcement | ||
|
||
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting | ||
the project team at [[email protected]](mailto:[email protected]). All complaints will be | ||
reviewed and investigated and will result in a response that is deemed necessary and appropriate to | ||
the circumstances. The project team is obligated to maintain confidentiality with regard to the | ||
reporter of an incident. Further details of specific enforcement policies may be posted separately. | ||
|
||
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face | ||
temporary or permanent repercussions as determined by other members of the project's leadership. | ||
|
||
## Attribution | ||
|
||
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at | ||
https://www.contributor-covenant.org/version/1/4/code-of-conduct.html | ||
|
||
[homepage]: https://www.contributor-covenant.org | ||
|
||
For answers to common questions about this code of conduct, see | ||
https://www.contributor-covenant.org/faq |
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,44 @@ | ||
# Contribution Guidelines | ||
|
||
Styled System has a [Code of Conduct][]. Please review and help enforce this code of conduct to help | ||
us foster an open and inclusive project. | ||
|
||
[code of conduct]: ./CODE_OF_CONDUCT.MD | ||
|
||
## How to Contribute | ||
|
||
Feel free to contribute by opening and commenting on issues, helping answer questions, updating | ||
docs, or opening a pull request. For quick bug fixes or PRs that address an open issue, feel free to | ||
open a PR. If you'd like to suggest a new feature or change to the API, please open an issue for | ||
discussion first. | ||
|
||
## Pull Requests | ||
|
||
To submit a pull request, follow these steps | ||
|
||
1. Fork and clone this repo | ||
2. Create a branch for your changes | ||
3. Install dependencies with `yarn install && bootstrap` | ||
4. Ensure tests are passing by running `yarn test` | ||
5. If you're fixing a bug, it's recommended to write a failing test before writing any code | ||
6. Make changes locally and commit them | ||
7. Try to make sure tests still pass and that there's 100% coverage | ||
8. Push your branch to origin | ||
9. Open a pull request in this repository with a clear title and description and link to any | ||
relevant issues | ||
10. Wait for a maintainer to review your PR | ||
|
||
## Documentation | ||
|
||
The documentation is in [README](./README.MD). | ||
|
||
## Architecture | ||
|
||
@datepicker-react is intentionally divided into two libraries, `@datepicker-react/styled` | ||
(./packages/styled) and `@datepicker-react/hooks` (./packages/hooks). `@datepicker-react/hooks` | ||
library contains hooks, which allows us to control the date picker. The second library | ||
(`@datepicker-react/styled`) contains date picker components. | ||
|
||
### Monorepo | ||
|
||
This repo is set up as a monorepo using Yarn workspaces and Lerna. |
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.
Oops, something went wrong.