mirror of
https://github.com/documenso/documenso.git
synced 2025-11-10 04:22:32 +10:00
chore: updated signing fields
Signed-off-by: Adithya Krishna <adikrish@redhat.com>
This commit is contained in:
@ -82,13 +82,17 @@ export const DateField = ({ field, recipient }: DateFieldProps) => {
|
||||
</div>
|
||||
)}
|
||||
|
||||
{!field.inserted && (
|
||||
<p className="group-hover:text-primary text-muted-foreground text-lg duration-200">Date</p>
|
||||
)}
|
||||
|
||||
{field.inserted && (
|
||||
<p className="text-muted-foreground text-sm duration-200">{field.customText}</p>
|
||||
)}
|
||||
<p
|
||||
className={`
|
||||
${
|
||||
!field.inserted
|
||||
? 'group-hover:text-primary text-muted-foreground text-lg duration-200'
|
||||
: 'text-muted-foreground text-sm duration-200'
|
||||
}
|
||||
`}
|
||||
>
|
||||
{field.inserted ? field.customText : 'Date'}
|
||||
</p>
|
||||
</SigningFieldContainer>
|
||||
);
|
||||
};
|
||||
|
||||
@ -139,9 +139,9 @@ export const SignatureField = ({ field, recipient }: SignatureFieldProps) => {
|
||||
/>
|
||||
)}
|
||||
|
||||
{state === 'signed-text' && (
|
||||
{state === 'signed-text' && signature?.typedSignature && (
|
||||
<p className="font-signature text-muted-foreground text-lg duration-200 sm:text-xl md:text-2xl lg:text-3xl">
|
||||
{signature?.typedSignature}
|
||||
{signature.typedSignature}
|
||||
</p>
|
||||
)}
|
||||
|
||||
|
||||
@ -60,19 +60,16 @@ export const SigningFieldContainer = ({
|
||||
'text-foreground hover:shadow-primary-foreground group flex h-full w-full flex-col items-center justify-center p-2',
|
||||
)}
|
||||
>
|
||||
{!field.inserted && !loading && (
|
||||
<button type="submit" className="absolute inset-0 z-10" onClick={onSignFieldClick} />
|
||||
)}
|
||||
|
||||
{field.inserted && !loading && (
|
||||
<button
|
||||
className="text-destructive bg-background/40 absolute inset-0 z-10 flex items-center justify-center rounded-md text-sm opacity-0 backdrop-blur-sm duration-200 group-hover:opacity-100"
|
||||
onClick={onRemoveSignedFieldClick}
|
||||
>
|
||||
Remove
|
||||
</button>
|
||||
)}
|
||||
|
||||
<button
|
||||
type="submit"
|
||||
className={`
|
||||
absolute inset-0 z-10 ${field.inserted ? 'text-destructive bg-background/40' : ''}
|
||||
`}
|
||||
onClick={field.inserted ? onRemoveSignedFieldClick : onSignFieldClick}
|
||||
disabled={loading}
|
||||
>
|
||||
{field.inserted ? 'Remove' : ''}
|
||||
</button>
|
||||
{children}
|
||||
</CardContent>
|
||||
</Card>
|
||||
|
||||
Reference in New Issue
Block a user