forked from polka_billy/porridger
Added poetry picture, fixed spacing on UserPage
This commit is contained in:
@ -7,7 +7,7 @@ function Poetry() {
|
||||
const poetry = usePoetry()
|
||||
|
||||
return (
|
||||
<div className={styles.container}>
|
||||
<section>
|
||||
<h4 className='fw-bold'>Поэзия</h4> {
|
||||
gotResponse(poetry) ? (
|
||||
gotError(poetry) ? (
|
||||
@ -26,6 +26,7 @@ function Poetry() {
|
||||
}}
|
||||
/>
|
||||
<p><em>{poetry.data.author}</em></p>
|
||||
<img src={`/poem_pic/${poetry.data.id}`} alt='Иллюстрация' />
|
||||
</>
|
||||
)
|
||||
) : (
|
||||
@ -33,7 +34,7 @@ function Poetry() {
|
||||
)
|
||||
}
|
||||
|
||||
</div>
|
||||
</section>
|
||||
)
|
||||
}
|
||||
|
||||
|
@ -7,9 +7,6 @@ type PointsProps = {
|
||||
}
|
||||
|
||||
const styles = {
|
||||
container: {
|
||||
paddingBottom: 8,
|
||||
} as CSSProperties,
|
||||
points: {
|
||||
float: 'right',
|
||||
} as CSSProperties,
|
||||
@ -22,18 +19,16 @@ const styles = {
|
||||
|
||||
function Points({ points }: PointsProps) {
|
||||
return (
|
||||
<div style={styles.container}>
|
||||
<h5>
|
||||
Набрано очков:
|
||||
<span style={styles.points}>
|
||||
<img
|
||||
style={styles.icon}
|
||||
src={handStarsIcon}
|
||||
alt='Иконка руки, дающей звёзды' />
|
||||
{points}
|
||||
</span>
|
||||
</h5>
|
||||
</div>
|
||||
<h5>
|
||||
Набрано очков:
|
||||
<span style={styles.points}>
|
||||
<img
|
||||
style={styles.icon}
|
||||
src={handStarsIcon}
|
||||
alt='Иконка руки, дающей звёзды' />
|
||||
{points}
|
||||
</span>
|
||||
</h5>
|
||||
)
|
||||
}
|
||||
|
||||
|
@ -37,6 +37,7 @@ const styles = {
|
||||
objectFit: 'contain',
|
||||
borderRadius: 12,
|
||||
marginBottom: 5,
|
||||
maxWidth: 'inherit',
|
||||
} as CSSProperties,
|
||||
title: {
|
||||
overflow: 'hidden',
|
||||
|
Reference in New Issue
Block a user