Skip to content

Commit c5bd99d

Browse files
authored
feat(signin): Support passing any argument to credentials input (#2876)
Spreading the object into the input tag allows developers to specify any attribute for the input tag used in the builtin sign-in page, such as 'autocomplete', 'autofocus', etc. Removed the hardcoded attributes which just set the defaults of the 'input' tag and won't cause any behavior change in case they are absence from the object. Signed-off-by: Gegham Zakaryan <zakaryan.2004@outlook.com>
1 parent 72d4c5b commit c5bd99d

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/server/pages/signin.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,11 +106,10 @@ export default function Signin({
106106
<input
107107
name={credential}
108108
id={`input-${credential}-for-${provider.id}-provider`}
109-
type={provider.credentials[credential].type || "text"}
110-
value={provider.credentials[credential].value || ""}
111109
placeholder={
112110
provider.credentials[credential].placeholder || "Password"
113111
}
112+
{...provider.credentials[credential]}
114113
/>
115114
</div>
116115
)

0 commit comments

Comments
 (0)