openfrontio / openfrontio/OpenFrontIO
JoinLobbyModal does not properly replace CJK fullwidth colon
- Dominant language
- TypeScript
- Stars
- 2.7k
- Forks
- 1.4k
- Avg merge
- 17h 43m
- Merged PRs (30d)
- 310
Description
**Describe the bug**
JoinLobbyModal currently uses regex to replace existed colon in the i18n translation, but it missed CJK full-width colon, which resulted in duplicated colons in the final html span.
**To Reproduce**
Steps to reproduce the behavior:
1. Open public game with tribes count adjusted to 200
2. Use separate client to view public lobbies in Traditional Chinese
**Expected behavior**
CJK full-width colon should also be trimmed.
**Screenshots**
**Additional context**
As it appears that there are several colon unicode variants (e.g. Hebrew), this issue may need additional assessment on whether to handle other colon variants as well.
**Assignment**
- [x] I'd like to be assigned to this issue and work on it myself
discord id: chaosunity
Contributor guide
Research direction
Locate the TypeScript JoinLobbyModal component and inspect the existing regex that replaces colons in translated lobby text. Reproduce the issue using a Traditional Chinese public lobby with the tribe count set to 200, then verify that the CJK fullwidth colon is trimmed without duplicated punctuation in the final span and assess whether other variants need coverage.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend, internationalization, localization
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 66/100