feat(base/ui): fixed native button active style (#12353)

* feat(base/ui): fixed native button active style
This commit is contained in:
Calinteodor 2022-10-11 11:26:09 +03:00 committed by GitHub
parent 6423ed8fb5
commit abdc5123eb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 0 deletions

View File

@ -15,6 +15,7 @@ import styles from './buttonStyles';
export interface IButtonProps extends ButtonProps {
color?: string;
contentStyle?: Object | undefined;
labelStyle?: Object | undefined;
style?: Object | undefined;
}
@ -22,6 +23,7 @@ export interface IButtonProps extends ButtonProps {
const Button: React.FC<IButtonProps> = ({
accessibilityLabel,
color: buttonColor,
contentStyle,
disabled,
icon,
labelKey,
@ -88,6 +90,10 @@ const Button: React.FC<IButtonProps> = ({
accessibilityLabel = { t(accessibilityLabel ?? '') }
children = { t(labelKey ?? '') }
color = { color }
contentStyle = { [
styles.buttonContent,
contentStyle
] }
disabled = { disabled }
// @ts-ignore
icon = { icon }

View File

@ -23,6 +23,10 @@ export default {
...buttonLabel
},
buttonContent: {
height: BUTTON_HEIGHT
},
buttonLabelDisabled: {
...buttonLabel,
color: BaseTheme.palette.text03