diff --git a/ui/src/adapters/openclaw/config-fields.tsx b/ui/src/adapters/openclaw/config-fields.tsx index 5200256a..a50892eb 100644 --- a/ui/src/adapters/openclaw/config-fields.tsx +++ b/ui/src/adapters/openclaw/config-fields.tsx @@ -1,3 +1,5 @@ +import { useState } from "react"; +import { Eye, EyeOff } from "lucide-react"; import type { AdapterConfigFieldsProps } from "../types"; import { Field, @@ -8,6 +10,41 @@ import { const inputClass = "w-full rounded-md border border-border px-2.5 py-1.5 bg-transparent outline-none text-sm font-mono placeholder:text-muted-foreground/40"; +function SecretField({ + label, + value, + onCommit, + placeholder, +}: { + label: string; + value: string; + onCommit: (v: string) => void; + placeholder?: string; +}) { + const [visible, setVisible] = useState(false); + return ( + +
+ + +
+
+ ); +} + export function OpenClawConfigFields({ isCreate, values, @@ -120,27 +157,19 @@ export function OpenClawConfigFields({ )} - - mark("adapterConfig", "webhookAuthHeader", v || undefined)} - immediate - className={inputClass} - placeholder="Bearer " - /> - + mark("adapterConfig", "webhookAuthHeader", v || undefined)} + placeholder="Bearer " + /> - - - + )}