@@ -44,13 +44,13 @@ function deriveCategoryOrder(services: ServiceStatus[]): string[] {
4444const STATUS_COLORS : Record < string , string > = {
4545 up : "bg-green-500" ,
4646 down : "bg-red-500" ,
47- unconfigured : "bg-gray-300" ,
47+ unconfigured : "bg-gray-300 dark:bg-neutral-600 " ,
4848} ;
4949
5050const STATUS_TEXT_COLORS : Record < string , string > = {
51- up : "text-green-600" ,
52- down : "text-red-600" ,
53- unconfigured : "text-gray-400" ,
51+ up : "text-green-600 dark:text-green-400 " ,
52+ down : "text-red-600 dark:text-red-400 " ,
53+ unconfigured : "text-gray-400 dark:text-neutral-500 " ,
5454} ;
5555
5656const STATUS_LABELS : Record < string , string > = {
@@ -112,9 +112,9 @@ export default function StatusDashboard() {
112112 < div >
113113 < div className = "max-w-4xl mx-auto" >
114114 < div className = "flex items-center justify-between mb-1" >
115- < h1 className = "text-2xl font-bold text-gray-900" > System Status</ h1 >
115+ < h1 className = "text-2xl font-bold text-gray-900 dark:text-neutral-100 " > System Status</ h1 >
116116 < div className = "flex items-center gap-3" >
117- < label className = "flex items-center gap-1.5 text-sm text-gray-500 cursor-pointer select-none" >
117+ < label className = "flex items-center gap-1.5 text-sm text-gray-500 dark:text-neutral-400 cursor-pointer select-none" >
118118 < input
119119 type = "checkbox"
120120 checked = { autoRefresh }
@@ -127,7 +127,7 @@ export default function StatusDashboard() {
127127 type = "button"
128128 onClick = { fetchStatus }
129129 disabled = { loading }
130- className = "px-3 py-1.5 text-sm font-medium bg-white border border-gray-300 rounded-md shadow-sm hover:bg-gray-50 disabled:opacity-50 transition-colors"
130+ className = "px-3 py-1.5 text-sm font-medium bg-white dark:bg-neutral-800 border border-gray-300 dark:border-neutral-700 rounded-md shadow-sm hover:bg-gray-50 dark:hover:bg-neutral-700 dark:text-neutral-100 disabled:opacity-50 transition-colors"
131131 >
132132 { loading ? "Checking\u2026" : "Refresh" }
133133 </ button >
@@ -136,19 +136,25 @@ export default function StatusDashboard() {
136136
137137 { data && (
138138 < div className = "flex flex-wrap gap-x-4 gap-y-1 text-sm mb-6" >
139- < span className = "text-green-600 font-medium" > { upCount } operational</ span >
140- { downCount > 0 && < span className = "text-red-600 font-medium" > { downCount } down</ span > }
139+ < span className = "text-green-600 dark:text-green-400 font-medium" >
140+ { upCount } operational
141+ </ span >
142+ { downCount > 0 && (
143+ < span className = "text-red-600 dark:text-red-400 font-medium" > { downCount } down</ span >
144+ ) }
141145 { unconfiguredCount > 0 && (
142- < span className = "text-gray-400" > { unconfiguredCount } not configured</ span >
146+ < span className = "text-gray-400 dark:text-neutral-500" >
147+ { unconfiguredCount } not configured
148+ </ span >
143149 ) }
144- < span className = "text-gray-400 ml-auto" >
150+ < span className = "text-gray-400 dark:text-neutral-500 ml-auto" >
145151 { new Date ( data . timestamp ) . toLocaleString ( ) }
146152 </ span >
147153 </ div >
148154 ) }
149155
150156 { error && ! data && (
151- < div className = "bg-red-50 border border-red-200 rounded-lg p-4 text-sm text-red-700 mb-6" >
157+ < div className = "bg-red-50 dark:bg-red-950/40 border border-red-200 dark:border-red-900 rounded-lg p-4 text-sm text-red-700 dark:text-red-300 mb-6" >
152158 Failed to load status: { error }
153159 </ div >
154160 ) }
@@ -157,10 +163,10 @@ export default function StatusDashboard() {
157163 < div className = "space-y-6" >
158164 { [ 1 , 2 , 3 ] . map ( ( i ) => (
159165 < div key = { i } className = "animate-pulse" >
160- < div className = "h-4 w-32 bg-gray-200 rounded mb-2" />
161- < div className = "bg-white border border-gray-200 rounded-lg p-4 space-y-3" >
162- < div className = "h-4 bg-gray-100 rounded w-full" />
163- < div className = "h-4 bg-gray-100 rounded w-3/4" />
166+ < div className = "h-4 w-32 bg-gray-200 dark:bg-neutral-700 rounded mb-2" />
167+ < div className = "bg-white dark:bg-neutral-800 border border-gray-200 dark:border-neutral-700 rounded-lg p-4 space-y-3" >
168+ < div className = "h-4 bg-gray-100 dark:bg-neutral-700 rounded w-full" />
169+ < div className = "h-4 bg-gray-100 dark:bg-neutral-700 rounded w-3/4" />
164170 </ div >
165171 </ div >
166172 ) ) }
@@ -172,34 +178,42 @@ export default function StatusDashboard() {
172178 if ( ! services ?. length ) return null ;
173179 return (
174180 < div key = { category } className = "mb-6" >
175- < h2 className = "text-xs font-semibold text-gray-500 uppercase tracking-wider mb-2" >
181+ < h2 className = "text-xs font-semibold text-gray-500 dark:text-neutral-400 uppercase tracking-wider mb-2" >
176182 { category }
177183 </ h2 >
178- < div className = "bg-white border border-gray-200 rounded-lg divide-y divide-gray-100 shadow-sm" >
184+ < div className = "bg-white dark:bg-neutral-800 border border-gray-200 dark:border-neutral-700 rounded-lg divide-y divide-gray-100 dark:divide-neutral-700/60 shadow-sm" >
179185 { services . map ( ( s ) => (
180186 < div key = { s . id } className = "px-4 py-3 flex items-start gap-3" >
181187 < span
182- className = { `mt-1.5 shrink-0 w-2.5 h-2.5 rounded-full ${ STATUS_COLORS [ s . status ] ?? "bg-gray-300" } ` }
188+ className = { `mt-1.5 shrink-0 w-2.5 h-2.5 rounded-full ${ STATUS_COLORS [ s . status ] ?? "bg-gray-300 dark:bg-neutral-600 " } ` }
183189 />
184190 < div className = "min-w-0 flex-1" >
185191 < div className = "flex items-baseline gap-2 flex-wrap" >
186- < span className = "font-medium text-sm text-gray-900" > { s . name } </ span >
192+ < span className = "font-medium text-sm text-gray-900 dark:text-neutral-100" >
193+ { s . name }
194+ </ span >
187195 < span
188- className = { `text-xs font-medium ${ STATUS_TEXT_COLORS [ s . status ] ?? "text-gray-400" } ` }
196+ className = { `text-xs font-medium ${ STATUS_TEXT_COLORS [ s . status ] ?? "text-gray-400 dark:text-neutral-500 " } ` }
189197 >
190198 { STATUS_LABELS [ s . status ] ?? s . status }
191199 </ span >
192200 { s . responseTime != null && (
193- < span className = "text-xs text-gray-400" > { s . responseTime } ms</ span >
201+ < span className = "text-xs text-gray-400 dark:text-neutral-500" >
202+ { s . responseTime } ms
203+ </ span >
194204 ) }
195205 </ div >
196206 < div
197- className = "text-xs text-gray-500 font-mono truncate mt-0.5"
207+ className = "text-xs text-gray-500 dark:text-neutral-400 font-mono truncate mt-0.5"
198208 title = { s . url }
199209 >
200210 { s . url }
201211 </ div >
202- { s . error && < div className = "text-xs text-red-500 mt-0.5" > { s . error } </ div > }
212+ { s . error && (
213+ < div className = "text-xs text-red-500 dark:text-red-400 mt-0.5" >
214+ { s . error }
215+ </ div >
216+ ) }
203217 </ div >
204218 </ div >
205219 ) ) }
@@ -208,7 +222,9 @@ export default function StatusDashboard() {
208222 ) ;
209223 } ) }
210224
211- < div className = "text-center text-xs text-gray-400 mt-8 pb-4" > OpenMapX Status Dashboard</ div >
225+ < div className = "text-center text-xs text-gray-400 dark:text-neutral-500 mt-8 pb-4" >
226+ OpenMapX Status Dashboard
227+ </ div >
212228 </ div >
213229 </ div >
214230 ) ;
0 commit comments