[Text Entry] Strip whitespace from beginning of search

This idea has been developed and deployed to Canvas

Problem statement:

When searching for a subject or person, having a space character at the start of the field for a single-word search causes the search to not find anything

Proposed solution:

Strip whitespace from the beginning of the search (and other places where it's not useful) before form submission. something like the following validation - https://stackoverflow.com/questions/24282158/how-to-remove-the-white-space-at-the-start-of-the-strin... NB this should not be done in all fields, as whitespace can be useful for text formatting (ie in code submissions)

User role(s):

admin,instructor,student

4 Comments
Mikee
Community Participant
Author

Screenshot 2022-10-28 at 11.55.34 am.jpg Without space at the beginning of the field. I don't need to self-validate for this in any other platform I can think of.

Screenshot 2022-10-28 at 11.55.26 am.jpg With space at the beginning of the field - I had received a request from a teacher in this subject for assistance, and had difficulty locating the subject for no apparent reason...

KristinL
Community Team
Community Team
Status changed to: Open
 
KristinL
Community Team
Community Team
Status changed to: On Beta
  Comments from Instructure

 

For more information, please read through the Canvas Deploy Notes (2023-01-18)

KristinL
Community Team
Community Team
Status changed to: Completed
Comments from Instructure

 

For more information, please read through the Canvas Deploy Notes (2023-01-18)