chore: enable typed signature by default (#1436)

Enable typed signature by default and also add the option to set a typed
signature in the profile page.
This commit is contained in:
Catalin Pit
2024-11-26 12:03:44 +02:00
committed by GitHub
parent dcb7c2436f
commit ab654a63d8
43 changed files with 1285 additions and 1351 deletions

View File

@ -1,6 +1,6 @@
'use client';
import { createContext, useContext, useState } from 'react';
import { createContext, useContext, useEffect, useState } from 'react';
export type SigningContextValue = {
fullName: string;
@ -44,6 +44,12 @@ export const SigningProvider = ({
const [email, setEmail] = useState(initialEmail || '');
const [signature, setSignature] = useState(initialSignature || null);
useEffect(() => {
if (initialSignature) {
setSignature(initialSignature);
}
}, [initialSignature]);
return (
<SigningContext.Provider
value={{