Skip to content

Conversation

@rtibbles
Copy link
Member

Summary

Standardizes usage of the localeCompare wrapper from i18n.js across all sorting operations to ensure proper locale-aware string comparison.

Changes:

  • Enhanced the localeCompare wrapper in i18n.js to default to currentLanguage and usage: 'sort'
  • Updated 9 files to use the wrapper instead of direct .localeCompare() calls
  • Fixed compareLanguages() to use proper locale-aware comparison
  • SideNav URL sorting uses simple string comparison (URLs are technical identifiers)

Screenshots showing sorted lists work correctly:

Classes Users
Classes Users

References

Fixes #3888

Reviewer guidance

The changes are mechanical - replacing direct .localeCompare() calls with the centralized wrapper. No risky areas (no auth, migrations, or API changes).

To verify: sorting of user/class lists should work correctly for names with accented characters and non-Latin scripts.

@github-actions github-actions bot added APP: Facility Re: Facility App (user/class management, facility settings, csv import/export, etc.) APP: Coach Re: Coach App (lessons, quizzes, groups, reports, etc.) APP: User Re: User app (sign-in, sign-up, user profile, etc.) DEV: frontend SIZE: small labels Jan 20, 2026
@rtibbles rtibbles force-pushed the claude/review-kolibri-issue-3888-017nnZLVRzfZRPKEp8jegFBb branch from ab884a4 to 6d6e230 Compare January 20, 2026 01:37
…earningequality#3888)

Use the localeCompare wrapper from i18n.js consistently across sorting
operations to ensure proper locale-aware string comparison.
@rtibbles rtibbles force-pushed the claude/review-kolibri-issue-3888-017nnZLVRzfZRPKEp8jegFBb branch from 6d6e230 to 9aa8b40 Compare January 20, 2026 02:00
@github-actions
Copy link
Contributor

github-actions bot commented Jan 20, 2026

@marcellamaki marcellamaki self-assigned this Jan 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

APP: Coach Re: Coach App (lessons, quizzes, groups, reports, etc.) APP: Facility Re: Facility App (user/class management, facility settings, csv import/export, etc.) APP: User Re: User app (sign-in, sign-up, user profile, etc.) DEV: frontend SIZE: small

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants