Momo Component Kits
Installing
Use yarn
yarn add momo-component-kits
Or npm
npm i momo-component-kits
Usage
MomoButton
import { MomoButton, MomoIcons, ButtonType } from 'momo-component-kits'
<MomoButton
text="Momo Button"
type={ButtonType.primary}
/>
<MomoButton
text="Momo Button"
type={ButtonType.primaryBorder}
/>
<MomoButton
icon={MomoIcons.ic_close_24}
text="Custom Text Style"
type={ButtonType.primaryBorder}
/>
MomoTextInput
BrandInfo
SelectionItem
MomoHintBox
Avatar
RoundTextInput
UserShortedInfo
IconText
UnderlineTextInput
CalculatorTextInput
Register keyboard for app
import {KeyboardCalculator} from 'momo-component-kits';
AppRegistry.registerComponent('KeyboardCalculator', () => KeyboardCalculator);
const keyboardTypeRegistry = {};
export function register(type, factory) {
keyboardTypeRegistry[type] = factory;
}
class CustomKeyboardContainer extends Component {
render() {
const { tag, type } = this.props;
const factory = keyboardTypeRegistry[type];
if (!factory) {
return null;
}
const Comp = factory();
return <Comp tag={tag} />;
}
}
AppRegistry.registerComponent('CustomKeyboard', () => CustomKeyboardContainer);
MoneySuggestionList
MomoCardView
MomoCoverFlow
MomoCarousel
MomoSkeleton
MomoTypography
MomoToast
MomoLine
SelectionItemList
Balance
Changes log
v0.10.41.1
Fix:
- remove react-navigation from dependencies
v0.10.41
New components
v0.10.40.0
New components
Update
- add isHide properties, default isShow=false
v0.10.39.2
- Remove react-navigation from dependencies
v0.10.39.1
New components
Update
- add show and hide function
v0.10.39
New components
Update
- fix bugs: header show when scroll to bottom
- add focusBorderColor, focusBackgroundColor
- add rightComponent
- able to hide rightIcon
Components
See more details
Click here