mirror of
https://github.com/farion1231/cc-switch.git
synced 2026-05-18 19:20:07 +08:00
fix: avoid resetting usage query fields when editing extractor code (#1771)
This commit is contained in:
@@ -873,7 +873,9 @@ const UsageScriptModal: React.FC<UsageScriptModalProps> = ({
|
||||
<JsonEditor
|
||||
id="usage-code"
|
||||
value={script.code || ""}
|
||||
onChange={(value) => setScript({ ...script, code: value })}
|
||||
onChange={(value) =>
|
||||
setScript((prev) => ({ ...prev, code: value }))
|
||||
}
|
||||
height={480}
|
||||
language="javascript"
|
||||
showMinimap={false}
|
||||
|
||||
Reference in New Issue
Block a user