Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ export default function ReadMeExampleSingle() {
// }}
// onChange={} // same props as onConfirm but triggered without confirmed by user
// saveLabel="Save" // optional
// saveLabelDisabled={true} // optional, default is false
// uppercase={false} // optional, default is true
// label="Select date" // optional
// animationType="slide" // optional, default is 'slide' on ios/android and 'none' on web
Expand Down Expand Up @@ -194,6 +195,7 @@ export default function ReadMeExampleRange() {
// }}
// onChange={} // same props as onConfirm but triggered without confirmed by user
// saveLabel="Save" // optional
// saveLabelDisabled={true} // optional, default is false
// uppercase={false} // optional, default is true
// label="Select period" // optional
// startLabel="From" // optional
Expand Down Expand Up @@ -251,6 +253,7 @@ export default function ReadMeExampleMultiple() {
// uppercase={false} // optional, default is true
// label="Select period" // optional
// startLabel="From" // optional
// saveLabelDisabled={true} // optional, default is false
// endLabel="To" // optional
// animationType="slide" // optional, default is slide on ios/android and none on web
/>
Expand Down
2 changes: 1 addition & 1 deletion example/src/ReadMeExampleMultiple.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export default function ReadMeExampleMultiple() {
// }}
// locale={'nl'} // optional
// saveLabel="Save" // optional
// uppercase={false} // optional, default is true
// saveLabelDisabled={true} // optional, default is false // uppercase={false} // optional, default is true
// label="Select period" // optional
// startLabel="From" // optional
// endLabel="To" // optional
Expand Down
1 change: 1 addition & 0 deletions example/src/ReadMeExampleRange.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ export default function ReadMeExampleRange() {
// onChange={} // same props as onConfirm but triggered without confirmed by user
// locale={'nl'} // optional
// saveLabel="Save" // optional
// saveLabelDisabled={true} // optional, default is false
// uppercase={false} // optional, default is true
// label="Select period" // optional
// startLabel="From" // optional
Expand Down
1 change: 1 addition & 0 deletions example/src/ReadMeExampleSingle.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ export default function ReadMeExampleSingle() {
// }}
// onChange={} // same props as onConfirm but triggered without confirmed by user
// saveLabel="Save" // optional
// saveLabelDisabled={true} // optional, default is false
// uppercase={false} // optional, default is true
// label="Select date" // optional
// animationType="slide" // optional, default is 'slide' on ios/android and 'none' on web
Expand Down
1 change: 1 addition & 0 deletions src/Date/DatePickerModalContent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ export function DatePickerModalContent(
onSave={onInnerConfirm}
onDismiss={onDismiss}
saveLabel={props.saveLabel}
saveLabelDisabled={props.saveLabelDisabled ?? false}
uppercase={props.uppercase ?? true}
disableSafeTop={disableSafeTop}
/>
Expand Down
2 changes: 2 additions & 0 deletions src/Date/DatePickerModalHeader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { getTranslation } from '../translations/utils'
export interface DatePickerModalHeaderProps {
disableSafeTop?: boolean
saveLabel?: string
saveLabelDisabled?: boolean
uppercase?: boolean
onDismiss: () => void
onSave: () => void
Expand Down Expand Up @@ -44,6 +45,7 @@ export default function DatePickerModalHeader(
<Button
color={color}
onPress={props.onSave}
disabled={props.saveLabelDisabled ?? false}
uppercase={props.uppercase ?? true}
testID="react-native-paper-dates-save"
>
Expand Down