Skip to content

The Open Source DocuSign Alternative.

fix: correctly render new lines in text fields (#1920)

David Nguyen07119f0e8d89
diff --git a/apps/remix/app/components/general/document-signing/document-signing-fields.tsx b/apps/remix/app/components/general/document-signing/document-signing-fields.tsx
index 8899836ba..805cbf7ea 100644
--- a/apps/remix/app/components/general/document-signing/document-signing-fields.tsx
+++ b/apps/remix/app/components/general/document-signing/document-signing-fields.tsx
@@ -12,7 +12,7 @@ export const DocumentSigningFieldsLoader = () => {
export const DocumentSigningFieldsUninserted = ({ children }: { children: React.ReactNode }) => {
return (
- <p className="group-hover:text-primary text-foreground group-hover:text-recipient-green text-[clamp(0.425rem,25cqw,0.825rem)] duration-200">
+ <p className="text-foreground group-hover:text-recipient-green whitespace-pre-wrap text-[clamp(0.425rem,25cqw,0.825rem)] duration-200">
{children}
</p>
);
@@ -37,7 +37,7 @@ export const DocumentSigningFieldsInserted = ({
<div className="flex h-full w-full items-center overflow-hidden">
<p
className={cn(
- 'text-foreground w-full text-left text-[clamp(0.425rem,25cqw,0.825rem)] duration-200',
+ 'text-foreground w-full whitespace-pre-wrap text-left text-[clamp(0.425rem,25cqw,0.825rem)] duration-200',
{
'!text-center': textAlign === 'center',
'!text-right': textAlign === 'right',