fix: cw setting could not store

This commit is contained in:
sevichecc 2023-04-15 04:49:59 +08:00
parent bda1804b6a
commit 57cd5db168
Signed by untrusted user who does not match committer: SevicheCC
GPG key ID: C577000000000000

View file

@ -75,8 +75,8 @@ export default function SimpleCommand(props: CommandProps) {
} }
}; };
const handleCw = () => { const handleCw = (value:boolean) => {
setShowCw(!showCw); setShowCw(value);
if (cwRef.current) { if (cwRef.current) {
cwRef.current.focus(); cwRef.current.focus();
} }
@ -93,7 +93,7 @@ export default function SimpleCommand(props: CommandProps) {
</ActionPanel> </ActionPanel>
} }
> >
{fqn && <Form.Description title="Account" text={fqn} />} <Form.Description title="Account" text={fqn} />
{showCw && ( {showCw && (
<Form.TextField <Form.TextField
id="spoiler_text" id="spoiler_text"