docs: update AI Studio design token audits

Refresh design token inventory files to reflect the latest UI sizing and layout configurations from the sandbox prototype.
This commit is contained in:
Md Najmul committed 2026-10-23 11:43:49 -05:00
1 parent 50449e96ad
commit d39d9f92f9
139 files changed
+10982 -6

No files matched your search

+32
View File
@@ -0,0 +1,32 @@
import { useState, useEffect, useCallback } from 'react';
export function useVconMetrics(refreshIntervalMs = 3000) {
const [metrics, setMetrics] = useState<any>(null);
const [loading, setLoading] = useState(true);
const [error, setError] = useState<string | null>(null);
const fetchMetrics = useCallback(async () => {
try {
const res = await fetch('/api/metrics');
if (res.ok) {
const data = await res.json();
setMetrics(data);
setError(null);
} else {
setError('Failed to fetch metrics');
}
} catch (err: any) {
setError(err.message);
} finally {
setLoading(false);
}
}, []);
useEffect(() => {
fetchMetrics();
const timer = setInterval(fetchMetrics, refreshIntervalMs);
return () => clearInterval(timer);
}, [fetchMetrics, refreshIntervalMs]);
return { metrics, loading, error, refetch: fetchMetrics };
}