Added signature form
This commit is contained in:
parent
7146159208
commit
e4c7448b0b
1 changed files with 15 additions and 1 deletions
|
|
@ -5,8 +5,9 @@ import Table from './Table';
|
|||
import getHash from '../utils/fingerprint';
|
||||
|
||||
const FingerprintBlock = ({ workerData }) => {
|
||||
const [signature, setSignature] = useState();
|
||||
|
||||
const hash = getHash(workerData);
|
||||
console.log(hash);
|
||||
return (
|
||||
<Block>
|
||||
<h1>Fingerprint</h1>
|
||||
|
|
@ -19,6 +20,19 @@ const FingerprintBlock = ({ workerData }) => {
|
|||
use private mode the hash will stay the same. Enter your name below and
|
||||
reload the page in private mode to test it out.
|
||||
</p>
|
||||
{signature ? (
|
||||
<p>Success! Reload browser.</p>
|
||||
) : (
|
||||
<form onSubmit={(e) => setSignature(e.target[0].value)}>
|
||||
<input
|
||||
type="text"
|
||||
id="name"
|
||||
name="name"
|
||||
placeholder="Enter signature"
|
||||
/>
|
||||
<input type="submit" id="saveButton" value="Save" maxLength="100" />
|
||||
</form>
|
||||
)}
|
||||
</Block>
|
||||
);
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue