mirror of
https://github.com/tomru/pdfer.git
synced 2026-03-03 06:27:19 +01:00
drop some types in
This commit is contained in:
@@ -1,15 +1,27 @@
|
||||
import React from 'react'
|
||||
|
||||
export default function (props) {
|
||||
export default function Input({
|
||||
text,
|
||||
name,
|
||||
value,
|
||||
placeholder,
|
||||
onchange,
|
||||
}: {
|
||||
text: string
|
||||
name: string
|
||||
value: string
|
||||
placeholder: string
|
||||
onchange: () => void
|
||||
}) {
|
||||
return (
|
||||
<label>
|
||||
{props.text}
|
||||
{text}
|
||||
<input
|
||||
className={props.name}
|
||||
className={name}
|
||||
type="text"
|
||||
placeholder={props.placeholder}
|
||||
onChange={props.onchange.bind(null, props.name)}
|
||||
value={props.value}
|
||||
placeholder={placeholder}
|
||||
onChange={onchange.bind(null, name)}
|
||||
value={value}
|
||||
/>
|
||||
</label>
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user