nus-cs2103-AY2324S2 / pe-dev-response

0 stars 0 forks source link

No Input Validation for Phone Number Length Causes UI Display Issues #515

Open nus-pe-bot opened 4 months ago

nus-pe-bot commented 4 months ago

Description: The application does not restrict the length of phone numbers entered by users, leading to display problems in the user interface where long phone numbers are not fully visible. This can hinder user interaction and affect the usability of the application, particularly for cases where users have very long phone numbers or multiple phone numbers.

Steps to reproduce: When adding a new person, enter a long phone number.

Expected Behavior: The application should handle phone numbers in a way that ensures they fit within the UI constraints or provide an effective method to manage phone numbers that exceed these lengths.

Actual Behavior: Phone numbers that are too long for the display area are cut off.

Screenshot 2024-04-19 at 4.36.12 PM.png

When the phone number gets too long, it shows this: Screenshot 2024-04-19 at 4.38.52 PM.png

Suggested Improvement: Introduce a validation rule to limit the maximum length of phone numbers based on the UI's display capabilities. Alternatively, implement a UI design that accommodates longer phone numbers, such as truncation with a tooltip that shows the full phone number on hover or a click-to-expand functionality.


[original: nus-cs2103-AY2324S2/pe-interim#667] [original labels: severity.Low type.FeatureFlaw]

gerteck commented 4 months ago

Team's Response

Please refer: https://nus-cs2103-ay2324s2.github.io/website/admin/tp-pe.html#pe-phase-2-developer-response

image.png

As per ITU-T recommendation E.164 for the international telephone network, the specification of an entire phone number (including country code) should be at most 15 characters. [1] [2]. Hence, there is ground to believe such an input can only happen in case of deliberate sabotage, in which case it should not be considered a bug. Additionally, the input provided by the tester shows a phone number with more than 100+ digits, which goes above and beyond the example given in the CS2103/T example of deliberate sabotage.

Hence, in accordance to CS2103/T policy, it should not be considered a bug.

1: https://www.itu.int/ITU-T/recommendations/rec.aspx?rec=E.164 2: https://stackoverflow.com/questions/723587/whats-the-longest-possible-worldwide-phone-number-i-should-consider-in-sql-varc

Duplicate status (if any):

Duplicate of #4537