From 147efb628a9eea755dd2901a82f39f14435f6629 Mon Sep 17 00:00:00 2001
From: Ryan McLeod <excitinglyboring@gmail.com>
Date: Mon, 2 Dec 2024 21:25:10 -0500
Subject: Fix title/buttons in date picker not being visible on Android in dark
 mode (#6880)

---
 src/components/forms/DateField/index.android.tsx | 3 +++
 1 file changed, 3 insertions(+)

(limited to 'src/components/forms/DateField/index.android.tsx')

diff --git a/src/components/forms/DateField/index.android.tsx b/src/components/forms/DateField/index.android.tsx
index 1830ca4bf..0fd5bca01 100644
--- a/src/components/forms/DateField/index.android.tsx
+++ b/src/components/forms/DateField/index.android.tsx
@@ -50,11 +50,14 @@ export function DateField({
       />
 
       {open && (
+        // Android implementation of DatePicker currently does not change default button colors according to theme and only takes hex values for buttonColor
+        // Can remove the buttonColor setting if/when this PR is merged: https://github.com/henninghall/react-native-date-picker/pull/871
         <DatePicker
           modal
           open
           timeZoneOffsetInMinutes={0}
           theme={t.name === 'light' ? 'light' : 'dark'}
+          buttonColor={t.name === 'light' ? '#000000' : '#ffffff'}
           date={new Date(value)}
           onConfirm={onChangeInternal}
           onCancel={onCancel}
-- 
cgit 1.4.1

