Skip to content
This repository was archived by the owner on Feb 28, 2026. It is now read-only.

Commit 593d6dc

Browse files
authored
Merge pull request #79 from WildCodeSchool/feature/responsive-2
responsie hire artists, create single et albums
2 parents 36088ad + 60a8684 commit 593d6dc

File tree

5 files changed

+23
-17
lines changed

5 files changed

+23
-17
lines changed

packages/frontend/web/src/components/arrow-left.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { useNavigate } from 'react-router-dom';
33
export function ArrowLeft() {
44
const navigate = useNavigate();
55
return (
6-
<div className='absolute mb-4 flex w-full items-center justify-between'>
6+
<div className='mb-4 flex items-center justify-between'>
77
<button
88
onClick={async () => {
99
await navigate(-1);
@@ -14,7 +14,7 @@ export function ArrowLeft() {
1414
<img
1515
src='/assets/arrow-left.png'
1616
alt='arrow left'
17-
className='W-10 h-10'
17+
className='h-7 w-7 md:h-10 md:w-10'
1818
/>
1919
</button>
2020
</div>

packages/frontend/web/src/components/artist-card-hire.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export default function ArtistCardHire({ artist }: ArtistCardHireProps) {
99
return (
1010
<div
1111
key={artist.id}
12-
className='bg-secondary flex h-12 w-60 items-center justify-evenly rounded-sm text-white shadow-[3px_5px_6px_rgba(0,0,0,0.30)]'
12+
className='bg-secondary flex h-14 w-50 items-center justify-evenly rounded-sm text-white shadow-[3px_5px_6px_rgba(0,0,0,0.30)] md:h-12 md:w-60'
1313
>
1414
<Link to={`/artists-hired/${artist.id}`}>
1515
<img

packages/frontend/web/src/components/artist-card.tsx

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,20 +16,20 @@ export default function ArtistCard({
1616
return (
1717
<div
1818
key={artist.id}
19-
className='bg-secondary flex h-20 w-110 items-center justify-evenly rounded-sm text-white shadow-[3px_5px_6px_rgba(0,0,0,0.30)]'
19+
className='bg-secondary flex h-14 w-70 items-center justify-evenly rounded-sm text-white shadow-[3px_5px_6px_rgba(0,0,0,0.30)] md:h-20 md:w-110'
2020
>
2121
<Link to={`/artists/${artist.id}`}>
2222
<img
23-
className='h-16 w-16 rounded-4xl'
23+
className='h-10 w-10 rounded-4xl md:h-16 md:w-16'
2424
src={`/assets/${artist.image}`}
2525
alt={`Portrait of ${artist.firstname} ${artist.lastname}`}
2626
/>{' '}
2727
</Link>
2828
<div className='flex flex-col items-center'>
29-
<h2 className='ml-2'>
29+
<h2 className='ml-2 text-sm md:text-xl'>
3030
{artist.firstname} {artist.lastname} {artist.alias}
3131
</h2>
32-
<h3>{artist.genre}</h3>
32+
<h3 className='text-sm md:text-xl'>{artist.genre}</h3>
3333
</div>
3434
<div className='flex items-center'>
3535
<h2 className='flex items-center font-bold'>{artist.notoriety}</h2>
@@ -46,15 +46,21 @@ export default function ArtistCard({
4646
onHire(artist.id);
4747
}}
4848
disabled={isDisabled}
49-
className={`flex h-8 w-18 items-center justify-center rounded-sm pl-2 text-xl font-bold shadow-[3px_5px_6px_rgba(0,0,0,0.30)] ${
49+
className={`flex h-5 w-12 items-center justify-center rounded-sm pl-2 text-sm font-bold shadow-[3px_5px_6px_rgba(0,0,0,0.30)] md:h-8 md:w-18 md:text-xl ${
5050
isDisabled ? 'cursor-not-allowed bg-gray-400' : 'bg-orange-500'
5151
}`}
5252
>
5353
{'Hire'}
54-
<img className='h-7 w-7' src='/assets/sign.png' alt='contract logo' />
54+
<img
55+
className='mr-0.5 h-5 md:mr-0 md:h-7 md:w-7'
56+
src='/assets/sign.png'
57+
alt='contract logo'
58+
/>
5559
</button>
5660
<div className='flex items-center'>
57-
<h2 className='flex items-center font-bold'>{artist.price}</h2>
61+
<h2 className='flex items-center text-sm font-bold md:text-xl'>
62+
{artist.price}
63+
</h2>
5864
<img
5965
className='mt-0.5 h-3.5 w-3.5'
6066
src='/assets/dollar-icon.png'

packages/frontend/web/src/pages/create-album.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,11 +182,11 @@ export default function CreateAlbum() {
182182
}}
183183
>
184184
<div className='bg-primary flex min-h-screen flex-col items-center px-4 py-6'>
185-
<div className='mb-4 flex w-full items-center justify-between'>
185+
<div className='mb-4 flex items-center'>
186186
<div>
187187
<ArrowLeft />
188188
</div>
189-
<h1 className='text-secondary text-center text-2xl font-bold'>
189+
<h1 className='text-secondary text-center text-lg font-bold md:text-2xl'>
190190
{'RECORDING A NEW ALBUM'}
191191
</h1>
192192
<div className='h-6 w-6' />

packages/frontend/web/src/pages/create-single.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -147,11 +147,11 @@ export default function CreateSingle() {
147147
<form onSubmit={handleSubmit}>
148148
<div className='bg-primary flex min-h-screen flex-col items-center px-4 py-6 sm:px-6 md:px-12'>
149149
{/* Header */}
150-
<div className='mb-4 flex w-full flex-col items-center justify-between gap-2 sm:flex-row'>
151-
<button type='button'>
150+
<div className='mb-4 flex items-center gap-2'>
151+
<div>
152152
<ArrowLeft />
153-
</button>
154-
<h1 className='text-secondary text-center text-xl font-bold sm:text-2xl'>
153+
</div>
154+
<h1 className='text-secondary text-center text-lg font-bold sm:text-2xl md:text-xl'>
155155
{' RECORDING A NEW SINGLE'}
156156
</h1>
157157
<div className='h-6 w-6' />
@@ -165,7 +165,7 @@ export default function CreateSingle() {
165165
/>
166166

167167
{/* Artist */}
168-
<div className='mt-6 w-full max-w-md'>
168+
<div className='mt-6 max-w-md'>
169169
{artistsHired.length > 0 ? (
170170
artistsHired.map((artist) => (
171171
<ArtistCardHire key={artist.artists_id} artist={artist} />

0 commit comments

Comments
 (0)