Skip to content
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

Feature Request: Month / year picker #125

Open
devcodemada opened this issue Oct 23, 2024 · 3 comments
Open

Feature Request: Month / year picker #125

devcodemada opened this issue Oct 23, 2024 · 3 comments

Comments

@devcodemada
Copy link

Request new feature that picker can only max view in month or year

like a initialValue props, but if we click month that will be get data of the month

@Mneto12
Copy link

Mneto12 commented Nov 5, 2024

@devcodemada I recently used this library and could be nice if when I select the month get a onChange function for month and year, and not select the month and then the day.

@blazk0
Copy link

blazk0 commented Nov 24, 2024

Would be nice to be added, as in my case, i only need to select a month

@ulucantugberk
Copy link

react-native-ui-datepicker+2.0.4.patch

You can try adding this patch. I added it with a simple implementation.

import Moment from 'moment';
import DateTimePicker from 'react-native-ui-datepicker';

<DateTimePicker
calendarTextStyle={styles.calenderText}
headerTextStyle={styles.headerText}
selectedItemColor={COLOR_PRIMARY}
selectedTextStyle={styles.selectedText}
mode={'single'}
locale={'tr'}
initialView={'month'}
onlyMonth
buttonPrevIcon={()}
buttonNextIcon={()}
firstDayOfWeek={1}
date={start_date}
minDate={this.state.first_date}
maxDate={Moment()}
onChange={({date}) => _onChangeFunction()}
/>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants