Front: Prettier
This commit is contained in:
@@ -20,22 +20,22 @@ type ScoreModalProps = {
|
||||
};
|
||||
};
|
||||
|
||||
const ScoreModal = (props: ScoreModalProps) => {
|
||||
// const props = {
|
||||
// songId: 1,
|
||||
// overallScore: 74,
|
||||
// precision: 0,
|
||||
// score: {
|
||||
// missed: 9,
|
||||
// good: 1,
|
||||
// great: 2,
|
||||
// perfect: 4,
|
||||
// wrong: 0,
|
||||
// max_score: 100,
|
||||
// current_streak: 1,
|
||||
// max_streak: 11,
|
||||
// } as const
|
||||
// } as const; //TODO DELETE ME
|
||||
const ScoreModal = () => {
|
||||
const props = {
|
||||
songId: 1,
|
||||
overallScore: 74,
|
||||
precision: 0,
|
||||
score: {
|
||||
missed: 9,
|
||||
good: 1,
|
||||
great: 2,
|
||||
perfect: 4,
|
||||
wrong: 0,
|
||||
max_score: 100,
|
||||
current_streak: 1,
|
||||
max_streak: 11,
|
||||
} as const
|
||||
} as const; //TODO DELETE ME
|
||||
const navigation = useNavigation()
|
||||
const theme = useTheme();
|
||||
const score = (props.overallScore * 100) / props.score.max_score
|
||||
|
||||
@@ -34,18 +34,20 @@ const PopupCC = ({ title, description, children, isVisible, setIsVisible }: Popu
|
||||
}}
|
||||
space={4}
|
||||
>
|
||||
{(setIsVisible || title) && <Heading size="md" mb={2} alignItems={'flex-end'}>
|
||||
<Row style={{ flex: 1, width: '100%', alignItems: 'flex-end' }}>
|
||||
<Text style={{ flex: 1, width: '100%' }}>{title}</Text>
|
||||
{setIsVisible !== undefined && (
|
||||
<ButtonBase
|
||||
type="menu"
|
||||
icon={CloseSquare}
|
||||
onPress={async () => setIsVisible(false)}
|
||||
/>
|
||||
)}
|
||||
</Row>
|
||||
</Heading>}
|
||||
{(setIsVisible || title) && (
|
||||
<Heading size="md" mb={2} alignItems={'flex-end'}>
|
||||
<Row style={{ flex: 1, width: '100%', alignItems: 'flex-end' }}>
|
||||
<Text style={{ flex: 1, width: '100%' }}>{title}</Text>
|
||||
{setIsVisible !== undefined && (
|
||||
<ButtonBase
|
||||
type="menu"
|
||||
icon={CloseSquare}
|
||||
onPress={async () => setIsVisible(false)}
|
||||
/>
|
||||
)}
|
||||
</Row>
|
||||
</Heading>
|
||||
)}
|
||||
{description !== undefined && <Text>{description}</Text>}
|
||||
{children !== undefined && children}
|
||||
</Column>
|
||||
|
||||
Reference in New Issue
Block a user