[GH-ISSUE #2216] i18n: Signing auth components don't use RECIPIENT_ROLES_DESCRIPTION strings #640

Closed
opened 2026-02-26 18:47:53 +03:00 by kerem · 1 comment
Owner

Originally created by @mKoonrad on GitHub (Nov 19, 2025).
Original GitHub issue: https://github.com/documenso/documenso/issues/2216

Issue Description

Signing authentication components

currently construct UI text dynamically by concatenating strings and applying .toLowerCase() to variables like actionVerb and actionTarget.

Example:
github.com/documenso/documenso@11d9bde8f8/apps/remix/app/components/general/document-signing/document-signing-auth-passkey.tsx (L54-L55)
github.com/documenso/documenso@11d9bde8f8/apps/remix/app/components/general/document-signing/document-signing-auth-passkey.tsx (L130-L134)

This approach is problematic because:

  • Variables aren't translated
  • It prevents proper translation of the full sentence structure.
  • It ignores the existing infrastructure: The project already defines localized role descriptions in RECIPIENT_ROLES_DESCRIPTION

Steps to Reproduce

  1. Open any of the auth components mentioned above.
  2. Observe code that use actionTarget and actionVerb
  3. Compare this with the unused (in this context) definitions available in the RECIPIENT_ROLES_DESCRIPTION constant, which contains proper localized keys like actionVerb.

Expected Behavior

Components should rely on the centralized RECIPIENT_ROLES_DESCRIPTION map or use distinct, full sentences wrapped in tags for each message.

Current Behavior

The UI manually reconstructs phrases by manipulating raw strings, bypassing the established Lingui localization patterns and causing grammatical errors in non-English languages. Furthermore, the variables injected into these phrases (actionVerb and actionTarget) are raw English strings and are not translated.

Screenshots (optional)

No response

Operating System [e.g., Windows 10]

Windows 11

Browser [e.g., Chrome, Firefox]

Chrome

Version [e.g., 2.0.1]

v2.0.13

Please check the boxes that apply to this issue report.

  • I have searched the existing issues to make sure this is not a duplicate.
  • I have provided steps to reproduce the issue.
  • I have included relevant environment information.
  • I have included any relevant screenshots.
  • I understand that this is a voluntary contribution and that there is no guarantee of resolution.
  • I want to work on creating a PR for this issue if approved
Originally created by @mKoonrad on GitHub (Nov 19, 2025). Original GitHub issue: https://github.com/documenso/documenso/issues/2216 ### Issue Description Signing authentication components - [document-signing-auth-2fa.tsx](https://github.com/documenso/documenso/blob/11d9bde8f8b2c0086a25c9bae65affd5e3b75c93/apps/remix/app/components/general/document-signing/document-signing-auth-2fa.tsx) - [document-signing-auth-account.tsx](https://github.com/documenso/documenso/blob/11d9bde8f8b2c0086a25c9bae65affd5e3b75c93/apps/remix/app/components/general/document-signing/document-signing-auth-account.tsx) - [document-signing-auth-passkey.tsx](https://github.com/documenso/documenso/blob/11d9bde8f8b2c0086a25c9bae65affd5e3b75c93/apps/remix/app/components/general/document-signing/document-signing-auth-passkey.tsx) - [document-signing-auth-password.tsx](https://github.com/documenso/documenso/blob/11d9bde8f8b2c0086a25c9bae65affd5e3b75c93/apps/remix/app/components/general/document-signing/document-signing-auth-password.tsx) currently construct UI text dynamically by concatenating strings and applying `.toLowerCase()` to variables like `actionVerb` and `actionTarget`. Example: https://github.com/documenso/documenso/blob/11d9bde8f8b2c0086a25c9bae65affd5e3b75c93/apps/remix/app/components/general/document-signing/document-signing-auth-passkey.tsx#L54-L55 https://github.com/documenso/documenso/blob/11d9bde8f8b2c0086a25c9bae65affd5e3b75c93/apps/remix/app/components/general/document-signing/document-signing-auth-passkey.tsx#L130-L134 This approach is problematic because: - Variables aren't translated - It prevents proper translation of the full sentence structure. - It ignores the existing infrastructure: The project already defines localized role descriptions in [RECIPIENT_ROLES_DESCRIPTION](https://github.com/documenso/documenso/blob/11d9bde8f8b2c0086a25c9bae65affd5e3b75c93/packages/lib/constants/recipient-roles.ts) ### Steps to Reproduce 1. Open any of the auth components mentioned above. 2. Observe code that use `actionTarget` and `actionVerb` 3. Compare this with the unused (in this context) definitions available in the RECIPIENT_ROLES_DESCRIPTION constant, which contains proper localized keys like actionVerb. ### Expected Behavior Components should rely on the centralized [RECIPIENT_ROLES_DESCRIPTION](https://github.com/documenso/documenso/blob/11d9bde8f8b2c0086a25c9bae65affd5e3b75c93/packages/lib/constants/recipient-roles.ts) map or use distinct, full sentences wrapped in <Trans> tags for each message. ### Current Behavior The UI manually reconstructs phrases by manipulating raw strings, bypassing the established Lingui localization patterns and causing grammatical errors in non-English languages. Furthermore, the variables injected into these phrases (`actionVerb` and `actionTarget`) are raw English strings and are not translated. ### Screenshots (optional) _No response_ ### Operating System [e.g., Windows 10] Windows 11 ### Browser [e.g., Chrome, Firefox] Chrome ### Version [e.g., 2.0.1] v2.0.13 ### Please check the boxes that apply to this issue report. - [x] I have searched the existing issues to make sure this is not a duplicate. - [x] I have provided steps to reproduce the issue. - [ ] I have included relevant environment information. - [ ] I have included any relevant screenshots. - [x] I understand that this is a voluntary contribution and that there is no guarantee of resolution. - [ ] I want to work on creating a PR for this issue if approved
kerem 2026-02-26 18:47:53 +03:00
Author
Owner

@mKoonrad commented on GitHub (Feb 17, 2026):

Resolved in #2451

<!-- gh-comment-id:3911155987 --> @mKoonrad commented on GitHub (Feb 17, 2026): Resolved in #2451
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/documenso#640
No description provided.