Some values in the single resource view appear with extra spaces
Opened this issue · 3 comments
For instance, in a textngram resource "5-gram" appears as "5 - gram".
The reason for these extra spaces is a generic “prettify” function for pre-defined values.
Other bad examples are these:
- “UTF - 8”
- “CC - BY - SA”
- “CD - ROM”
The problem is, however, that there are many more cases where it makes sense to add whitespaces around dashes:
- “Available - Unrestricted Use”
- “Semantics - Cross References”
- “Speech Annotation - Sound To Text Alignment”
In some cases it might make sense to change the pre-defined values in the XML Schema to get rid of the dashes:
- “Usage - Notes” → “Usage Notes”
- “Semantics - Relations - Antonyms” → “Semantics Relations - Antonyms”
I think I can easily add some restrictions to this method to avoid this behaviour. The following criteria would -at least- catch the problematic values we have spotted so far and leave the rest untouched:
- If the string contains numbers.
- If all the letters in the string are capital.
@dmavroeidis Sounds good to me as a first improvement. Note however, that this will likely also affect our nightly tests.