mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-12-17 03:43:02 -06:00
[bugfix/frontend] Add nosubmit option to form fields + use it when instance custom CSS disabled (#2290)
This commit is contained in:
parent
4facad3d81
commit
48a0687736
6 changed files with 29 additions and 6 deletions
|
|
@ -39,7 +39,8 @@ export default function useTextInput(
|
|||
dontReset = false,
|
||||
validator,
|
||||
showValidation = true,
|
||||
initValidation
|
||||
initValidation,
|
||||
nosubmit = false,
|
||||
}: HookOpts<string>
|
||||
): TextFormInputHook {
|
||||
const [text, setText] = useState(initialValue);
|
||||
|
|
@ -91,6 +92,7 @@ export default function useTextInput(
|
|||
reset,
|
||||
name,
|
||||
Name: "", // Will be set by inputHook function.
|
||||
nosubmit,
|
||||
value: text,
|
||||
ref: textRef,
|
||||
setter: setText,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue