import * as React from "react"; import Ripple from 'react-native-material-ripple'; import MaterialCommunityIcons from 'react-native-vector-icons/MaterialCommunityIcons' import {Text, View, ViewStyle} from "react-native"; import {MaterialProgress} from "../.."; export interface MaterialExtendedFabProps { icon?: React.ReactNode, color?:string, iconColor?: string, onPress?():void, iconName:string, textFont?:string, text:string, position:string,//{'bottomLeft','topRight','topLeft','bottomRight'} progress?:boolean, style?: ViewStyle } export default (props: MaterialExtendedFabProps) => props.onPress()} style={{borderRadius: 28, alignSelf:'center', height: 56, backgroundColor:props.color, overflow:'hidden', paddingLeft:16, paddingRight:16, flexDirection:'row', elevation:16, shadowColor:'black', shadowOffset: { width: 0, height: 16 }, shadowRadius: 16, shadowOpacity: 0.24, top:props.position === "top" ? 16:undefined, bottom:props.position === "bottom" ? 16:undefined, position:'absolute', alignItems: 'center', justifyContent: 'center', ...props.style }}> {props.icon ? props.icon : (!props.progress && props.iconName) && } {props.progress && } {props.text} ;