Display problem with Switchbox when label strings aren't the same length as "On" & "Off"
Bug #1467252 reported by
Dominique-Alain JAN
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mahara |
Fix Released
|
Medium
|
Gilles-Philippe Leblanc |
Bug Description
It was ok in 15.04 but the the new interface of 15.10dev, the translated text for the "switch" options are not displayed correctly.
1/ When "On", the translated text for "on" is displayed, with the text for "off" partially
2/ When "Off", the translated text for "off" is displayed centered below the the red bullet
(see inclosed picture)
tags: | added: bootstrap translations |
Changed in mahara: | |
status: | New → Triaged |
importance: | Undecided → High |
tags: | removed: interface |
summary: |
- Display problem with the new Switch button when translated + Display problem with Switchbox when label strings aren't exactly the + same length as English-language label strings |
no longer affects: | mahara/15.04 |
tags: | removed: bite-sized |
Changed in mahara: | |
milestone: | 16.10.1 → 17.04.0 |
Changed in mahara: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
On further testing, it looks like the problem here is that the switchbox's width is hard-coded to the English language labels "On" and "Off". Having a label that is significantly shorter *or* longer than this, will cause display problems. So, it works for the "Yes" and "No" switches (which you see on the "Add users by CSV" screen) but it doesn't work for "True" and "False" (which is supported by the switchbox element but not currently used in core)
The French langpack has cleverly worked around this for on/off by setting them to "❙" (that's some kind of unicode pipe character which is wider than the ASCII "|") and "O" (capital-O).
For "Yes" & "No" it has "Oui" and "Non", and as a result it has display problems.