Spaces:
Build error
Build error
Upload components/MetadataPanel.jsx with huggingface_hub
Browse files- components/MetadataPanel.jsx +59 -0
components/MetadataPanel.jsx
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import {
|
| 2 |
+
Camera,
|
| 3 |
+
Aperture,
|
| 4 |
+
Clock,
|
| 5 |
+
Hash,
|
| 6 |
+
Box,
|
| 7 |
+
Layers
|
| 8 |
+
} from 'lucide-react';
|
| 9 |
+
|
| 10 |
+
export default function MetadataPanel({ worldData }) {
|
| 11 |
+
if (!worldData) return null;
|
| 12 |
+
|
| 13 |
+
const stats = [
|
| 14 |
+
{ icon: Box, label: 'Points', value: worldData.pointCount?.toLocaleString() || '50,000' },
|
| 15 |
+
{ icon: Layers, label: 'Resolution', value: worldData.resolution || '8K' },
|
| 16 |
+
{ icon: Aperture, label: 'Aperture', value: worldData.aperture || 'f/2.8' },
|
| 17 |
+
{ icon: Clock, label: 'Shutter', value: worldData.shutterSpeed || '1/60s' },
|
| 18 |
+
{ icon: Hash, label: 'ISO', value: worldData.iso || '400' },
|
| 19 |
+
];
|
| 20 |
+
|
| 21 |
+
return (
|
| 22 |
+
<div className="glass-panel rounded-xl p-4 space-y-4">
|
| 23 |
+
<div className="flex items-center gap-2 mb-4">
|
| 24 |
+
<Camera className="w-5 h-5 text-indigo-400" />
|
| 25 |
+
<h3 className="font-semibold text-slate-200">Capture Metadata</h3>
|
| 26 |
+
</div>
|
| 27 |
+
|
| 28 |
+
<div className="grid grid-cols-2 gap-3">
|
| 29 |
+
{stats.map((stat) => (
|
| 30 |
+
<div key={stat.label} className="bg-slate-800/50 rounded-lg p-3">
|
| 31 |
+
<div className="flex items-center gap-2 text-slate-400 text-xs mb-1">
|
| 32 |
+
<stat.icon className="w-3 h-3" />
|
| 33 |
+
<span>{stat.label}</span>
|
| 34 |
+
</div>
|
| 35 |
+
<p className="text-slate-200 font-mono text-sm">{stat.value}</p>
|
| 36 |
+
</div>
|
| 37 |
+
))}
|
| 38 |
+
</div>
|
| 39 |
+
|
| 40 |
+
<div className="pt-4 border-t border-slate-700">
|
| 41 |
+
<h4 className="text-sm font-medium text-slate-300 mb-2">360° Capture Info</h4>
|
| 42 |
+
<div className="space-y-2 text-xs text-slate-400">
|
| 43 |
+
<div className="flex justify-between">
|
| 44 |
+
<span>Stitching Software</span>
|
| 45 |
+
<span className="text-slate-300">{worldData.software || 'Insta360 Studio'}</span>
|
| 46 |
+
</div>
|
| 47 |
+
<div className="flex justify-between">
|
| 48 |
+
<span>Projection</span>
|
| 49 |
+
<span className="text-slate-300">Equirectangular</span>
|
| 50 |
+
</div>
|
| 51 |
+
<div className="flex justify-between">
|
| 52 |
+
<span>Format</span>
|
| 53 |
+
<span className="text-slate-300">.ply Gaussian Splat</span>
|
| 54 |
+
</div>
|
| 55 |
+
</div>
|
| 56 |
+
</div>
|
| 57 |
+
</div>
|
| 58 |
+
);
|
| 59 |
+
}
|