import { TextStyle , ViewStyle } from 'react-native' ; import { config } from '../../constants/config' ; import { ResponsiveStyleSheet , ScaleByBreakpoints , ScaleByFactor , defaultHorizontalMarginByBreakpoints , } from '../../utils/responsive' ; export interface MultipleChoiceSummaryStyles { stats_container : ViewStyle ; result_container : ViewStyle ; result_row : ViewStyle ; percentage : TextStyle ; grade : TextStyle ; row : ViewStyle ; left : ViewStyle ; right : ViewStyle ; text_left : TextStyle ; text_right : TextStyle ; text_highlight : TextStyle ; text_touchable : ViewStyle ; horizontal_line : ViewStyle ; } export class MultipleChoiceSummaryResponsiveStyles extends ResponsiveStyleSheet < MultipleChoiceSummaryStyles > { public baseStyles ( scaleByFactor , scaleByBreakpoints ) { return { stats_container : { marginTop : scaleByFactor ( 12 ) , marginBottom : scaleByFactor ( 12 ) , } , result_container : { marginHorizontal : scaleByBreakpoints ( defaultHorizontalMarginByBreakpoints ) , } , result_row : { flexDirection : 'row' , justifyContent : 'flex-end' , paddingVertical : scaleByFactor ( 2 ) , } , percentage : { fontWeight : 'bold' , } , grade : { fontWeight : 'bold' , } , row : { paddingHorizontal : scaleByBreakpoints ( defaultHorizontalMarginByBreakpoints ) , paddingVertical : scaleByFactor ( 4 ) , flexDirection : 'row' , justifyContent : 'space-between' , alignItems : 'center' , } , left : { flexShrink : 1 , paddingRight : scaleByFactor ( 16 ) , } , right : { } , text_left : { fontSize : scaleByFactor ( 14 ) , } , text_right : { fontSize : scaleByFactor ( 14 ) , fontWeight : 'bold' , } , text_highlight : { color : config . styles . primaryColor , } , text_touchable : { } , horizontal_line : { height : 1 , marginVertical : scaleByFactor ( 12 ) , marginHorizontal : scaleByBreakpoints ( defaultHorizontalMarginByBreakpoints ) , } , } ; } public lightStyles ( ) { return { percentage : { color : config . styles . light . secondaryTextColor , } , grade : { color : config . styles . light . primaryTextColor , } , text_left : { color : config . styles . light . secondaryTextColor , } , text_right : { color : config . styles . light . primaryTextColor , } , horizontal_line : { backgroundColor : config . styles . light . primaryBorderColor , } , } ; } public darkStyles ( ) { return { percentage : { color : config . styles . dark . secondaryTextColor , } , grade : { color : config . styles . dark . primaryTextColor , } , text_left : { color : config . styles . dark . secondaryTextColor , } , text_right : { color : config . styles . dark . primaryTextColor , } , horizontal_line : { backgroundColor : config . styles . dark . primaryBorderColor , } , } ; } } export const multipleChoiceSummaryResponsiveStyles = new MultipleChoiceSummaryResponsiveStyles ( ) ;