Expensify: Multiline Titles & Markdown In Default Reports

by Alex Johnson 58 views

Introduction

In the Expensify application, a peculiar issue has been identified within the reports section, specifically concerning the default report title field. This field, intended for a single-line title, unexpectedly accepts multiline text input and renders markdown. This behavior deviates from the standard report title functionality observed when creating a new report in a workspace chat, where markdown rendering is not supported. This discrepancy can lead to inconsistencies in how report titles are displayed and interpreted across different areas of the application. Understanding the root cause and implications of this issue is crucial for maintaining a cohesive and user-friendly experience within Expensify. By addressing this anomaly, the application can ensure uniformity in report title formatting and prevent potential confusion for users.

This article delves into the specifics of this issue, outlining the steps to reproduce it, the expected and actual results, and the platforms affected. Additionally, it explores the potential workarounds and provides a visual demonstration of the problem through screenshots. This comprehensive analysis aims to provide a clear understanding of the issue and its impact on the Expensify application.

Issue Details

Version Number: 9.2.49-2

Reproducible in staging?: Yes

Reproducible in production?: Yes

Regression Test: Exp https://test-management.browserstack.com/projects/2219752/test-runs/TR-1934/folder/15397164/57242436/1008394969

Affected Tester: jsnoidjdosisjdios@gmail.com

Reported by: Applause Internal Team

Device: Mac 15.5 / Chrome

App Component: Money Requests

Action Performed:

  1. Go to staging.new.expensify.com
  2. Go to workspace settings > Reports.
  3. Click Default report title.
  4. Enter multiline text with some mark down.

Expected Result:

The default report title field should accept only a single-line title and should not render markdown. This is because the report title functionality, as confirmed by creating a new report in a workspace chat, does not support markdown rendering. The expectation is that the default report title field behaves consistently with the standard report title functionality, ensuring a uniform user experience.

When a user enters text into the default report title field, the system should validate the input to ensure it is a single line. If the input contains multiple lines, the system should either reject the input or automatically truncate it to a single line. Furthermore, any markdown syntax included in the input should be treated as plain text and not rendered as formatted text. This would prevent inconsistencies in report title formatting and ensure that all report titles are displayed in a consistent manner. This consistency is crucial for maintaining a professional and user-friendly interface.

The rationale behind this expectation is to maintain consistency across the application. If the standard report title functionality does not support markdown rendering, then the default report title field should adhere to the same limitations. This prevents confusion for users who may expect markdown to be rendered in the default report title field but not in other areas of the application. By enforcing a single-line limit and disabling markdown rendering, the system can ensure that report titles are displayed uniformly throughout the application. This uniformity enhances the overall user experience and reduces the likelihood of errors or misinterpretations.

Actual Result:

The default report title field accepts multiline titles and renders markdown. This is inconsistent with the expected behavior, as the report title functionality in workspace chats does not support markdown rendering. This discrepancy can lead to confusion and inconsistencies in how report titles are displayed across different areas of the application.

When a user enters multiline text into the default report title field, the system does not reject the input or truncate it to a single line. Instead, it accepts the entire multiline text and stores it as the default report title. Furthermore, any markdown syntax included in the input is rendered as formatted text, leading to a visually different and potentially unintended presentation of the report title. This behavior deviates from the standard report title functionality and can create a disjointed user experience.

The implications of this issue are significant. Users may unknowingly enter multiline text or markdown syntax into the default report title field, expecting it to be rendered as plain text. However, the system renders the markdown, resulting in a report title that is formatted differently from other report titles in the application. This inconsistency can lead to confusion and may require users to manually edit the report title to remove the unwanted formatting. Moreover, the acceptance of multiline text can disrupt the layout of the report title, making it difficult to read or understand. Therefore, it is crucial to address this issue to ensure consistency and a user-friendly experience.

Workaround:

Unknown

Platforms:

  • [x] Android: App
  • [x] Android: mWeb Chrome
  • [x] iOS: App
  • [x] iOS: mWeb Safari
  • [x] iOS: mWeb Chrome
  • [ ] Windows: Chrome
  • [x] MacOS: Chrome / Safari
  • [x] MacOS: Desktop

Visual Evidence

Screenshots/Videos

https://github.com/user-attachments/assets/29e9fbaa-7a77-42cd-9e48-0c8c69556414

The provided screenshot visually demonstrates the issue of the default report title field accepting multiline text and rendering markdown. As you can see from the image, the user has entered a report title that spans multiple lines, and the markdown syntax within the title has been interpreted and rendered accordingly. This clearly illustrates the discrepancy between the expected behavior (single-line title, no markdown rendering) and the actual behavior of the field.

The screenshot serves as concrete evidence of the problem, highlighting the visual impact of the issue on the user interface. The rendered markdown can alter the appearance of the report title, potentially making it stand out or clash with the overall design of the application. This visual inconsistency can detract from the user experience and may require developers to address the issue promptly.

Contributing

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!

Conclusion

The issue of the default report title field accepting multiline titles and rendering markdown in Expensify presents a clear inconsistency in the application's user interface. This deviation from the expected behavior, where report titles should be single-line and not render markdown, can lead to confusion and a disjointed user experience. The problem is reproducible across various platforms, including Android, iOS, and MacOS, and has been identified in both staging and production environments.

The implications of this issue extend beyond mere visual inconsistencies. The acceptance of multiline text can disrupt the layout of report titles, while the rendering of markdown can alter their appearance in unintended ways. These factors can negatively impact the readability and overall usability of the application. Therefore, addressing this issue is crucial for maintaining a cohesive and professional user experience.

To resolve this issue, developers should implement measures to restrict the default report title field to accept only single-line text and disable markdown rendering. This would ensure consistency with the standard report title functionality and prevent users from inadvertently creating report titles that are formatted differently from others in the application. By implementing these changes, Expensify can enhance the user experience and reduce the likelihood of errors or misinterpretations.

For more information on Expensify and its features, visit the Expensify website.

View all open jobs on GitHub