Closed ucheNkadiCode closed 2 years ago
Hey @rishabhbhatia
I understand that the AwesomeAlerts background defaults to white, but I simply haven't been able to change the background color to darkgrey. I am using iOS with expo.
<AwesomeAlert show={showResetTimerModal} showProgress={false} title="Are you sure you want to do it?" alertContainerStyle={{ color: "purple", background: "yellow" }} contentContainerStyle={{ background: "pink", color: "green" }} contentStyle={{ color: "blue", background: "pink" }} actionContainerStyle={{ background: "orange", color: "brown" }} titleStyle={[styles.alertTitleText, { color: "red" }]} messageStyle={[ styles.alertMessageText, { textAlign: "center", color: appTheme.colors.text }, ]} confirmButtonTextStyle={styles.alertButtonTextStyle} cancelButtonTextStyle={styles.alertButtonTextStyle} confirmButtonStyle={[styles.alertButtonStyle, { marginLeft: 10 }]} cancelButtonStyle={[styles.alertButtonStyle, { marginRight: 10 }]} message={""} closeOnTouchOutside={true} closeOnHardwareBackPress={true} showCancelButton={true} showConfirmButton={true} cancelText="Yes" confirmText="No" cancelButtonColor="#2ecc71" confirmButtonColor="#e74c3c" onDismiss={() => { closeResetTimerModal(); }} onConfirmPressed={() => { closeModal(); }} onCancelPressed={() => { reset(); }} />
I've tried everything but nothing changes the background color from white. Thank you!
contentContainerStyle={{ background: "pink", color: "green" }}
@ucheNkadiCode Mate any chance you meant to pass backgroundColor instead? Try it out, see if that works for you.
backgroundColor
Hey @rishabhbhatia
I understand that the AwesomeAlerts background defaults to white, but I simply haven't been able to change the background color to darkgrey. I am using iOS with expo.
<AwesomeAlert show={showResetTimerModal} showProgress={false} title="Are you sure you want to do it?" alertContainerStyle={{ color: "purple", background: "yellow" }} contentContainerStyle={{ background: "pink", color: "green" }} contentStyle={{ color: "blue", background: "pink" }} actionContainerStyle={{ background: "orange", color: "brown" }} titleStyle={[styles.alertTitleText, { color: "red" }]} messageStyle={[ styles.alertMessageText, { textAlign: "center", color: appTheme.colors.text }, ]} confirmButtonTextStyle={styles.alertButtonTextStyle} cancelButtonTextStyle={styles.alertButtonTextStyle} confirmButtonStyle={[styles.alertButtonStyle, { marginLeft: 10 }]} cancelButtonStyle={[styles.alertButtonStyle, { marginRight: 10 }]} message={""} closeOnTouchOutside={true} closeOnHardwareBackPress={true} showCancelButton={true} showConfirmButton={true} cancelText="Yes" confirmText="No" cancelButtonColor="#2ecc71" confirmButtonColor="#e74c3c" onDismiss={() => { closeResetTimerModal(); }} onConfirmPressed={() => { closeModal(); }} onCancelPressed={() => { reset(); }} />
I've tried everything but nothing changes the background color from white. Thank you!