1*5feea232STomasz Sapetaimport { Code } from '@expo/html-elements'; 2*5feea232STomasz Sapetaimport { PropsWithChildren } from 'react'; 3*5feea232STomasz Sapetaimport { ScrollView, StyleSheet, ViewStyle } from 'react-native'; 4*5feea232STomasz Sapeta 5*5feea232STomasz Sapetatype Props = PropsWithChildren<{ 6*5feea232STomasz Sapeta style?: ViewStyle; 7*5feea232STomasz Sapeta}>; 8*5feea232STomasz Sapeta 9*5feea232STomasz Sapetaexport default function ConsoleBox({ children, style }: Props) { 10*5feea232STomasz Sapeta return ( 11*5feea232STomasz Sapeta <ScrollView style={[styles.scrollView, style]} indicatorStyle="black"> 12*5feea232STomasz Sapeta <ScrollView contentContainerStyle={styles.contentContainer} horizontal indicatorStyle="black"> 13*5feea232STomasz Sapeta <Code style={styles.monoText}>{children}</Code> 14*5feea232STomasz Sapeta </ScrollView> 15*5feea232STomasz Sapeta </ScrollView> 16*5feea232STomasz Sapeta ); 17*5feea232STomasz Sapeta} 18*5feea232STomasz Sapeta 19*5feea232STomasz Sapetaconst styles = StyleSheet.create({ 20*5feea232STomasz Sapeta scrollView: { 21*5feea232STomasz Sapeta backgroundColor: '#fff', 22*5feea232STomasz Sapeta borderWidth: 1, 23*5feea232STomasz Sapeta borderColor: '#666', 24*5feea232STomasz Sapeta }, 25*5feea232STomasz Sapeta contentContainer: { 26*5feea232STomasz Sapeta padding: 6, 27*5feea232STomasz Sapeta }, 28*5feea232STomasz Sapeta monoText: { 29*5feea232STomasz Sapeta fontSize: 10, 30*5feea232STomasz Sapeta }, 31*5feea232STomasz Sapeta}); 32