-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update DateMonth #303
Update DateMonth #303
Conversation
- Move DateMonth -> MonthInput using same code as DateInput - Add tests
This PR removes the DateMonth component and replaces with MonthInput, which uses the same interface and behavior as DateInput:
|
src/components/MonthCalendar.js
Outdated
|
||
import styles from './MonthCalendar.scss'; | ||
|
||
function range(start, end) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could share this in a util folder potentially
src/components/MonthCalendar.js
Outdated
const { format } = Fecha; | ||
|
||
const Label = ({ selected, label, onClick, visible = true }) => ( | ||
<li className={`px-0 py-1 text-center ${selected ? 'bg-primary text-white' : ''} ${!visible ? 'invisible' : ''}`} onClick={onClick}> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.picker { | ||
min-width: 16em; | ||
li { | ||
cursor: pointer; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can be removed once we're using buttons.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cool thanks, will check this out
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will mark as TODO for the release, after looking at it am porting markup used in app that had various tweaks to ensure we can click without dead areas, overlap, etc., and started re-introducing issues when I added links.
We should/will update this, will also create issue.
- Add TODO for Month labels
WIP, will update with more info on changes