import { StyleProp, StyleSheet, View, ViewStyle } from "react-native"; import { ThemedText } from "../ThemedText"; interface CreateCountProps { title: string; icon: React.ReactNode; number: number; style?: StyleProp; } const CreateCountComponent = (props: CreateCountProps) => { return ( {props.title} {props.icon} {props.number} ); }; const styles = StyleSheet.create({ container: { flex: 1, display: "flex", flexDirection: "column", alignItems: "flex-start", justifyContent: "space-between", gap: 8, backgroundColor: "#FAF9F6", padding: 16, borderRadius: 12, shadowColor: "#000", shadowOffset: { width: 0, height: 2, }, shadowOpacity: 0.25, shadowRadius: 3.84, elevation: 5, }, header: { width: "100%", display: "flex", flexDirection: "row", gap: 8, // 靠左展示 textAlign: 'left', }, title: { width: "53%", fontSize: 11, fontWeight: "700", // 允许换行 flexWrap: "wrap", }, number: { fontSize: 32, fontWeight: "700", paddingTop: 8, width: "100%", // 靠右展示 textAlign: "right", }, }) export default CreateCountComponent;