This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
mobile-app/src/libs/native-base/components/Badge.ts
2021-04-04 14:31:01 +02:00

37 lines
927 B
TypeScript

import variable from '../variables/platform';
export default (variables /* : * */ = variable) => {
const badgeTheme = {
'.primary': {
backgroundColor: variables.buttonPrimaryBg,
},
'.warning': {
backgroundColor: variables.buttonWarningBg,
},
'.info': {
backgroundColor: variables.buttonInfoBg,
},
'.success': {
backgroundColor: variables.buttonSuccessBg,
},
'.danger': {
backgroundColor: variables.buttonDangerBg,
},
'NativeBase.Text': {
color: variables.badgeColor,
fontSize: variables.fontSizeBase,
lineHeight: variables.lineHeight - 1,
textAlign: 'center',
paddingHorizontal: 3,
},
backgroundColor: variables.badgeBg,
padding: variables.badgePadding,
paddingHorizontal: 6,
alignSelf: 'flex-start',
justifyContent: 'center',
borderRadius: 13.5,
height: 27,
};
return badgeTheme;
};