refactor(admin): split dsr/[requestId] page.tsx into colocated components

Split the 854-line DSR detail page into colocated components under
_components/ and a data-loading hook under _hooks/. No behavior changes.

page.tsx is now 172 LOC, all extracted files under 300 LOC.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Sharang Parnerkar
2026-04-15 08:20:24 +02:00
parent e6ff76d0e1
commit cc3a9a37dc
10 changed files with 855 additions and 725 deletions

View File

@@ -0,0 +1,15 @@
'use client'
import React from 'react'
import { DSR_STATUS_INFO } from '@/lib/sdk/dsr/types'
export function StatusBadge({ status }: { status: string }) {
const info = DSR_STATUS_INFO[status as keyof typeof DSR_STATUS_INFO]
if (!info) return null
return (
<span className={`px-3 py-1.5 text-sm font-medium rounded-lg ${info.bgColor} ${info.color} border ${info.borderColor}`}>
{info.label}
</span>
)
}