Skip to content
Open
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
7 changes: 4 additions & 3 deletions src/DateTimePickerModal.ios.js
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,8 @@ export class DateTimePickerModal extends React.PureComponent {
onChange,
onHide,
backdropStyleIOS,
buttonTextColorIOS,
confirmButtonTextColorIOS,
cancelButtonTextColorIOS,
...otherProps
} = this.props;
const isAppearanceModuleAvailable = !!(
Expand Down Expand Up @@ -202,15 +203,15 @@ export class DateTimePickerModal extends React.PureComponent {
isDarkModeEnabled={_isDarkModeEnabled}
onPress={this.handleConfirm}
label={confirmTextIOS}
buttonTextColorIOS={buttonTextColorIOS}
buttonTextColorIOS={confirmButtonTextColorIOS}
/>
</View>
<CancelButtonComponent
cancelButtonTestID={cancelButtonTestID}
isDarkModeEnabled={_isDarkModeEnabled}
onPress={this.handleCancel}
label={cancelTextIOS}
buttonTextColorIOS={buttonTextColorIOS}
buttonTextColorIOS={cancelButtonTextColorIOS}
/>
</Modal>
);
Expand Down
11 changes: 9 additions & 2 deletions typings/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,11 +95,18 @@ export type PickerComponent = React.ComponentType<IOSNativeProps>;

export interface DateTimePickerProps {
/**
* iOS buttons text color
* iOS confirm button text color
*
* Default is '#007ff9'
*/
buttonTextColorIOS?: string;
confirmButtonTextColorIOS?: string;

/**
* iOS cancel button text color
*
* Default is '#007ff9'
*/
cancelButtonTextColorIOS?: string;

/**
* The prop to locate cancel button for e2e testing
Expand Down