python migration

This commit is contained in:
2026-05-26 14:36:34 -04:00
parent a67815c61a
commit 1ba2aa39d8
694 changed files with 1396 additions and 86487 deletions
+13 -30
View File
@@ -17,9 +17,6 @@ export default function ConfigModal({ onClose }) {
const [scanResult, setScanResult] = useState(null) // { testCount, completedCount } | null
const [saveError, setSaveError] = useState(null)
// Directories are locked once both are saved — restart server to change them
const dirsLocked = !!(config?.target_dir && config?.results_dir)
useEffect(() => {
if (config) {
setForm({
@@ -104,9 +101,6 @@ export default function ConfigModal({ onClose }) {
<section>
<div className="flex items-center justify-between mb-3">
<h3 className="text-slate-300 text-xs uppercase tracking-widest">Directories</h3>
{dirsLocked && (
<span className="text-xs text-slate-500">🔒 Restart server to change directories</span>
)}
</div>
<div className="space-y-3">
{[
@@ -116,30 +110,19 @@ export default function ConfigModal({ onClose }) {
<div key={key}>
<label className="text-slate-400 text-xs block mb-1">{label}</label>
<div className="flex gap-2">
{dirsLocked ? (
<div
title={form[key] ?? ''}
className="flex-1 border border-slate-700/50 bg-slate-800/40 text-slate-500 text-sm rounded-lg px-3 py-2 truncate cursor-default select-all font-mono"
>
{(form[key] ?? '').replace(/^(.+[/\\])([^/\\]+[/\\][^/\\]*)$/, '…$2')}
</div>
) : (
<>
<input
type="text"
value={form[key] ?? ''}
onChange={e => setForm(f => ({ ...f, [key]: e.target.value }))}
placeholder="C:\path\to\folder"
className="flex-1 bg-slate-800 border border-slate-700 text-slate-200 text-sm rounded-lg px-3 py-2 focus:outline-none focus:border-blue-500"
/>
<button
onClick={() => setBrowser(key)}
className="px-3 py-2 text-sm rounded-lg border border-slate-700 text-slate-300 hover:bg-slate-800 transition-colors whitespace-nowrap"
>
Browse
</button>
</>
)}
<input
type="text"
value={form[key] ?? ''}
onChange={e => setForm(f => ({ ...f, [key]: e.target.value }))}
placeholder="C:\path\to\folder"
className="flex-1 bg-slate-800 border border-slate-700 text-slate-200 text-sm rounded-lg px-3 py-2 focus:outline-none focus:border-blue-500"
/>
<button
onClick={() => setBrowser(key)}
className="px-3 py-2 text-sm rounded-lg border border-slate-700 text-slate-300 hover:bg-slate-800 transition-colors whitespace-nowrap"
>
Browse
</button>
</div>
</div>
))}