@@ -6,6 +6,7 @@ import Image from 'next/image'
66import { useRouter } from 'next/navigation'
77import {
88 Button ,
9+ Combobox ,
910 Label ,
1011 Modal ,
1112 ModalBody ,
@@ -42,6 +43,62 @@ function getInitials(name: string | undefined | null): string {
4243 return parts [ 0 ] [ 0 ] . toUpperCase ( )
4344}
4445
46+ /**
47+ * Skeleton component for general settings loading state.
48+ * Matches the exact layout structure of the General component.
49+ */
50+ function GeneralSkeleton ( ) {
51+ return (
52+ < div className = 'flex h-full flex-col gap-[16px]' >
53+ { /* User Info Section */ }
54+ < div className = 'flex items-center gap-[12px]' >
55+ < Skeleton className = 'h-9 w-9 rounded-full' />
56+ < div className = 'flex flex-1 flex-col justify-center gap-[1px]' >
57+ < div className = 'flex items-center gap-[8px]' >
58+ < Skeleton className = 'h-5 w-24' />
59+ < Skeleton className = 'h-[10.5px] w-[10.5px]' />
60+ </ div >
61+ < Skeleton className = 'h-5 w-40' />
62+ </ div >
63+ </ div >
64+
65+ { /* Theme selector row */ }
66+ < div className = 'flex items-center justify-between border-b pb-[12px]' >
67+ < Skeleton className = 'h-4 w-12' />
68+ < Skeleton className = 'h-8 w-[100px] rounded-[4px]' />
69+ </ div >
70+
71+ { /* Auto-connect row */ }
72+ < div className = 'flex items-center justify-between pt-[12px]' >
73+ < Skeleton className = 'h-4 w-36' />
74+ < Skeleton className = 'h-[17px] w-[30px] rounded-full' />
75+ </ div >
76+
77+ { /* Error notifications row */ }
78+ < div className = 'flex items-center justify-between' >
79+ < Skeleton className = 'h-4 w-40' />
80+ < Skeleton className = 'h-[17px] w-[30px] rounded-full' />
81+ </ div >
82+
83+ { /* Telemetry row */ }
84+ < div className = 'flex items-center justify-between border-t pt-[12px]' >
85+ < Skeleton className = 'h-4 w-44' />
86+ < Skeleton className = 'h-[17px] w-[30px] rounded-full' />
87+ </ div >
88+
89+ { /* Telemetry description */ }
90+ < Skeleton className = 'h-[12px] w-full' />
91+ < Skeleton className = '-mt-2 h-[12px] w-4/5' />
92+
93+ { /* Action buttons */ }
94+ < div className = 'mt-auto flex items-center gap-[8px]' >
95+ < Skeleton className = 'h-8 w-20 rounded-[4px]' />
96+ < Skeleton className = 'h-8 w-28 rounded-[4px]' />
97+ </ div >
98+ </ div >
99+ )
100+ }
101+
45102interface GeneralProps {
46103 onOpenChange ?: ( open : boolean ) => void
47104}
@@ -384,7 +441,7 @@ export function General({ onOpenChange }: GeneralProps) {
384441 </ div >
385442 { uploadError && < p className = 'text-[13px] text-[var(--text-error)]' > { uploadError } </ p > }
386443
387- { /* <div className='flex items-center justify-between border-b pb-[12px]'>
444+ < div className = 'flex items-center justify-between border-b pb-[12px]' >
388445 < Label htmlFor = 'theme-select' > Theme</ Label >
389446 < div className = 'w-[100px]' >
390447 < Combobox
@@ -402,7 +459,7 @@ export function General({ onOpenChange }: GeneralProps) {
402459 ] }
403460 />
404461 </ div >
405- </div> */ }
462+ </ div >
406463
407464 < div className = 'flex items-center justify-between pt-[12px]' >
408465 < Label htmlFor = 'auto-connect' > Auto-connect on drop</ Label >
@@ -508,53 +565,3 @@ export function General({ onOpenChange }: GeneralProps) {
508565 </ div >
509566 )
510567}
511-
512- /**
513- * Skeleton component for general settings loading state.
514- * Matches the exact layout structure of the General component.
515- */
516- function GeneralSkeleton ( ) {
517- return (
518- < div className = 'flex h-full flex-col gap-[16px]' >
519- { /* User Info Section */ }
520- < div className = 'flex items-center gap-[12px]' >
521- < Skeleton className = 'h-9 w-9 rounded-full' />
522- < div className = 'flex flex-1 flex-col justify-center gap-[1px]' >
523- < div className = 'flex items-center gap-[8px]' >
524- < Skeleton className = 'h-5 w-24' />
525- < Skeleton className = 'h-[10.5px] w-[10.5px]' />
526- </ div >
527- < Skeleton className = 'h-5 w-40' />
528- </ div >
529- </ div >
530-
531- { /* Auto-connect row */ }
532- < div className = 'flex items-center justify-between pt-[12px]' >
533- < Skeleton className = 'h-4 w-36' />
534- < Skeleton className = 'h-[17px] w-[30px] rounded-full' />
535- </ div >
536-
537- { /* Error notifications row */ }
538- < div className = 'flex items-center justify-between' >
539- < Skeleton className = 'h-4 w-40' />
540- < Skeleton className = 'h-[17px] w-[30px] rounded-full' />
541- </ div >
542-
543- { /* Telemetry row */ }
544- < div className = 'flex items-center justify-between border-t pt-[12px]' >
545- < Skeleton className = 'h-4 w-44' />
546- < Skeleton className = 'h-[17px] w-[30px] rounded-full' />
547- </ div >
548-
549- { /* Telemetry description */ }
550- < Skeleton className = 'h-[12px] w-full' />
551- < Skeleton className = '-mt-2 h-[12px] w-4/5' />
552-
553- { /* Action buttons */ }
554- < div className = 'mt-auto flex items-center gap-[8px]' >
555- < Skeleton className = 'h-8 w-20 rounded-[4px]' />
556- < Skeleton className = 'h-8 w-28 rounded-[4px]' />
557- </ div >
558- </ div >
559- )
560- }
0 commit comments