mirror of
https://github.com/documenso/documenso.git
synced 2025-11-12 15:53:02 +10:00
fix: temp field label/text truncation (#1565)
TEMP: Fix the truncation of the field label/text.
This commit is contained in:
committed by
David Nguyen
parent
06076c1809
commit
1aaacab6ca
@ -236,8 +236,8 @@ export const DocumentSigningNumberField = ({
|
|||||||
|
|
||||||
if (parsedFieldMeta?.label) {
|
if (parsedFieldMeta?.label) {
|
||||||
fieldDisplayName =
|
fieldDisplayName =
|
||||||
parsedFieldMeta.label.length > 10
|
parsedFieldMeta.label.length > 20
|
||||||
? parsedFieldMeta.label.substring(0, 10) + '...'
|
? parsedFieldMeta.label.substring(0, 20) + '...'
|
||||||
: parsedFieldMeta.label;
|
: parsedFieldMeta.label;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -288,7 +288,7 @@ export const DocumentSigningTextField = ({
|
|||||||
>
|
>
|
||||||
{field.customText.length < 20
|
{field.customText.length < 20
|
||||||
? field.customText
|
? field.customText
|
||||||
: field.customText.substring(0, 15) + '...'}
|
: field.customText.substring(0, 20) + '...'}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|||||||
@ -51,10 +51,10 @@ export const FieldIcon = ({ fieldMeta, type }: FieldIconProps) => {
|
|||||||
if (fieldMeta && (type === 'TEXT' || type === 'NUMBER')) {
|
if (fieldMeta && (type === 'TEXT' || type === 'NUMBER')) {
|
||||||
if (type === 'TEXT' && 'text' in fieldMeta && fieldMeta.text && !fieldMeta.label) {
|
if (type === 'TEXT' && 'text' in fieldMeta && fieldMeta.text && !fieldMeta.label) {
|
||||||
label =
|
label =
|
||||||
fieldMeta.text.length > 10 ? fieldMeta.text.substring(0, 10) + '...' : fieldMeta.text;
|
fieldMeta.text.length > 20 ? fieldMeta.text.substring(0, 20) + '...' : fieldMeta.text;
|
||||||
} else if (fieldMeta.label) {
|
} else if (fieldMeta.label) {
|
||||||
label =
|
label =
|
||||||
fieldMeta.label.length > 10 ? fieldMeta.label.substring(0, 10) + '...' : fieldMeta.label;
|
fieldMeta.label.length > 20 ? fieldMeta.label.substring(0, 20) + '...' : fieldMeta.label;
|
||||||
} else {
|
} else {
|
||||||
label = fieldIcons[type]?.label;
|
label = fieldIcons[type]?.label;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user