clementpep commited on
Commit
518daca
·
1 Parent(s): cddecd3

fix: last ui inhancement in pack page

Browse files
Files changed (2) hide show
  1. Dockerfile +1 -1
  2. frontend/src/pages/PacksPage.tsx +17 -17
Dockerfile CHANGED
@@ -57,7 +57,7 @@ EXPOSE 7860
57
 
58
  # Health check
59
  HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \
60
- CMD python -c "import requests; requests.get('http://localhost:7860/health')"
61
 
62
  # Change to backend directory for proper Python module resolution
63
  WORKDIR /app/backend
 
57
 
58
  # Health check
59
  HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \
60
+ CMD python -c "import urllib.request; urllib.request.urlopen('http://localhost:7860/health', timeout=5).read()"
61
 
62
  # Change to backend directory for proper Python module resolution
63
  WORKDIR /app/backend
frontend/src/pages/PacksPage.tsx CHANGED
@@ -83,29 +83,29 @@ export const PacksPage = () => {
83
  <div className="container mx-auto px-4 py-8 max-w-7xl">
84
  {/* Page Header */}
85
  <div className="mb-12 text-center">
86
- <h1 className="font-display text-6xl font-black mb-4 uppercase tracking-wider text-gradient-psg">
87
  MES PACKS
88
  </h1>
89
  <p className="text-text-secondary text-lg">
90
  Ouvre tes packs pour obtenir des récompenses exclusives !
91
  </p>
92
  {/* Display Credits and Points */}
93
- <div className="mt-6 flex justify-center gap-6">
94
- <div className="inline-flex items-center gap-2 px-6 py-3 rounded-xl border" style={{
95
  background: 'rgba(26, 41, 66, 0.6)',
96
  borderColor: 'rgba(255, 255, 255, 0.1)',
97
  backdropFilter: 'blur(10px)',
98
  }}>
99
- <span className="text-text-secondary text-sm uppercase tracking-wide">Crédits:</span>
100
- <span className="font-numbers text-2xl font-bold text-fifa-gold">{userCredits}</span>
101
  </div>
102
- <div className="inline-flex items-center gap-2 px-6 py-3 rounded-xl border" style={{
103
  background: 'rgba(26, 41, 66, 0.6)',
104
  borderColor: 'rgba(255, 255, 255, 0.1)',
105
  backdropFilter: 'blur(10px)',
106
  }}>
107
- <span className="text-text-secondary text-sm uppercase tracking-wide">Points:</span>
108
- <span className="font-numbers text-2xl font-bold text-fifa-green">{userPoints}</span>
109
  </div>
110
  </div>
111
  </div>
@@ -120,15 +120,15 @@ export const PacksPage = () => {
120
  {/* Pack Inventory Summary - Mobile First */}
121
  <div className="mb-8 md:mb-12 flex justify-center px-4">
122
  <div
123
- className="grid grid-cols-2 sm:flex sm:flex-row gap-3 sm:gap-6 rounded-2xl p-4 sm:p-6 border w-full max-w-2xl sm:w-auto"
124
  style={{
125
  background: 'rgba(26, 41, 66, 0.6)',
126
  borderColor: 'rgba(255, 255, 255, 0.1)',
127
  backdropFilter: 'blur(10px)',
128
  }}
129
  >
130
- <div className="text-center px-2 sm:px-4">
131
- <div className="font-numbers text-2xl sm:text-4xl font-black text-fifa-bronze mb-1 sm:mb-2">
132
  {inventory?.bronze || 0}
133
  </div>
134
  <div className="text-text-secondary text-xs sm:text-sm uppercase tracking-wide">
@@ -138,8 +138,8 @@ export const PacksPage = () => {
138
 
139
  <div className="hidden sm:block w-px bg-white/10"></div>
140
 
141
- <div className="text-center px-2 sm:px-4">
142
- <div className="font-numbers text-2xl sm:text-4xl font-black text-fifa-silver mb-1 sm:mb-2">
143
  {inventory?.silver || 0}
144
  </div>
145
  <div className="text-text-secondary text-xs sm:text-sm uppercase tracking-wide">
@@ -149,8 +149,8 @@ export const PacksPage = () => {
149
 
150
  <div className="hidden sm:block w-px bg-white/10"></div>
151
 
152
- <div className="text-center px-2 sm:px-4">
153
- <div className="font-numbers text-2xl sm:text-4xl font-black text-fifa-gold mb-1 sm:mb-2">
154
  {inventory?.gold || 0}
155
  </div>
156
  <div className="text-text-secondary text-xs sm:text-sm uppercase tracking-wide">
@@ -160,8 +160,8 @@ export const PacksPage = () => {
160
 
161
  <div className="hidden sm:block w-px bg-white/10"></div>
162
 
163
- <div className="text-center px-2 sm:px-4">
164
- <div className="font-numbers text-2xl sm:text-4xl font-black text-psg-red mb-1 sm:mb-2">
165
  {inventory?.ultimate || 0}
166
  </div>
167
  <div className="text-text-secondary text-xs sm:text-sm uppercase tracking-wide">
 
83
  <div className="container mx-auto px-4 py-8 max-w-7xl">
84
  {/* Page Header */}
85
  <div className="mb-12 text-center">
86
+ <h1 className="font-display text-3xl sm:text-5xl lg:text-6xl font-black mb-4 uppercase tracking-wider text-gradient-psg">
87
  MES PACKS
88
  </h1>
89
  <p className="text-text-secondary text-lg">
90
  Ouvre tes packs pour obtenir des récompenses exclusives !
91
  </p>
92
  {/* Display Credits and Points */}
93
+ <div className="mt-6 flex flex-col sm:flex-row justify-center items-center gap-3 sm:gap-6">
94
+ <div className="inline-flex items-center gap-2 px-4 py-2 sm:px-6 sm:py-3 rounded-xl border w-full sm:w-auto" style={{
95
  background: 'rgba(26, 41, 66, 0.6)',
96
  borderColor: 'rgba(255, 255, 255, 0.1)',
97
  backdropFilter: 'blur(10px)',
98
  }}>
99
+ <span className="text-text-secondary text-xs sm:text-sm uppercase tracking-wide">Crédits:</span>
100
+ <span className="font-numbers text-xl sm:text-2xl font-bold text-fifa-gold">{userCredits}</span>
101
  </div>
102
+ <div className="inline-flex items-center gap-2 px-4 py-2 sm:px-6 sm:py-3 rounded-xl border w-full sm:w-auto" style={{
103
  background: 'rgba(26, 41, 66, 0.6)',
104
  borderColor: 'rgba(255, 255, 255, 0.1)',
105
  backdropFilter: 'blur(10px)',
106
  }}>
107
+ <span className="text-text-secondary text-xs sm:text-sm uppercase tracking-wide">Points:</span>
108
+ <span className="font-numbers text-xl sm:text-2xl font-bold text-fifa-green">{userPoints}</span>
109
  </div>
110
  </div>
111
  </div>
 
120
  {/* Pack Inventory Summary - Mobile First */}
121
  <div className="mb-8 md:mb-12 flex justify-center px-4">
122
  <div
123
+ className="grid grid-cols-2 sm:flex sm:flex-row gap-3 sm:gap-6 rounded-2xl p-5 sm:p-6 border w-full max-w-2xl sm:w-auto"
124
  style={{
125
  background: 'rgba(26, 41, 66, 0.6)',
126
  borderColor: 'rgba(255, 255, 255, 0.1)',
127
  backdropFilter: 'blur(10px)',
128
  }}
129
  >
130
+ <div className="text-center px-3 sm:px-4">
131
+ <div className="font-numbers text-3xl sm:text-4xl font-black text-fifa-bronze mb-1 sm:mb-2">
132
  {inventory?.bronze || 0}
133
  </div>
134
  <div className="text-text-secondary text-xs sm:text-sm uppercase tracking-wide">
 
138
 
139
  <div className="hidden sm:block w-px bg-white/10"></div>
140
 
141
+ <div className="text-center px-3 sm:px-4">
142
+ <div className="font-numbers text-3xl sm:text-4xl font-black text-fifa-silver mb-1 sm:mb-2">
143
  {inventory?.silver || 0}
144
  </div>
145
  <div className="text-text-secondary text-xs sm:text-sm uppercase tracking-wide">
 
149
 
150
  <div className="hidden sm:block w-px bg-white/10"></div>
151
 
152
+ <div className="text-center px-3 sm:px-4">
153
+ <div className="font-numbers text-3xl sm:text-4xl font-black text-fifa-gold mb-1 sm:mb-2">
154
  {inventory?.gold || 0}
155
  </div>
156
  <div className="text-text-secondary text-xs sm:text-sm uppercase tracking-wide">
 
160
 
161
  <div className="hidden sm:block w-px bg-white/10"></div>
162
 
163
+ <div className="text-center px-3 sm:px-4">
164
+ <div className="font-numbers text-3xl sm:text-4xl font-black text-psg-red mb-1 sm:mb-2">
165
  {inventory?.ultimate || 0}
166
  </div>
167
  <div className="text-text-secondary text-xs sm:text-sm uppercase tracking-wide">