-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Freeform text should be per-locale #12
Comments
Other freeform fields like "must" and "mustnot" should be localizable as well. (Each array item would be an object of locales.) Should "name" be localized? I feel like that's a job for an alternate field, since names are usually universal. (Maybe a "markets" array that lets you specify alternative formulations for certain fields, where markets use different locales? Hm- I think that's overkill since it would lead to stuff like every URL being specified for every possible country code for Google or something which doesn't really add stuff? IDK, this is probably worth another issue) |
Also, while we're doing this, we should also allow "url" as a value, when the effective value is best explained on a (potentially localized) page. (We don't bother with trying to localize URLs, so I think this is best - if it's a localizable URL, it probably deserves to be a link within per-locale text.) The specific use case I'm thinking here is for Mozilla's Persona, but I think it could also do well for linking to the Wiki or Issues on GitHub for this repo. |
Should "notes" be changed to an array, then? I think... yes. That way, each "note" can be localized individually. (Indeed, most freeform fields should be arrays of localized objects like this.) |
Also, while we're documenting freeform text structure, let's also say it should be parsed as Markdown with URLs auto-recognized. That codifies backticks and asterisk-emphasis. (And, of course, you don't have to parse Markdown.) |
This should be codified in a separate document describing the patterns of fixed complex value structures (stuff like "freeform note lists"). Or, actually... we can just do one header with all the things that use freeform this stuff, so:
|
This is the fallback logic a consumer should look for values in where, as a soft policy, there will always be a string at one of these fixed values:
|
Locales of text are labeled with BCP47-style keys (where locales may be distinguished beyond the lower-case language code with a capitalized country code), with underscores in place of hyphens. The simplest tag is picked for each localization: more complex tags may be used when writing alternative formulations that are more dialect-specific. (For instance, if the initial Portuguese localization of a freeform field were written with Brazilian Portuguese isms, it would be under "pt": a pull request to introduce a European Portuguese version would change it so there are "pt_BR" and "pt_PT" fields.) Fun fact: until now, I never realized this convention is a combination of ISO standards that is not, itself, an ISO standard - http://en.wikipedia.org/wiki/Language_localisation (which I only found by Googling "en-us pt-br") revealed that the most standard document for this is maintained by the IETF. |
This should maybe be followed up with / condensed into a "Locale Policy" similar to the "URL Policy" of #27 saying that an English (or en_US) version of any note should be included along with the target language, as a guaranteed last-chance fallback. Such a locale policy might do well to be coupled with a content-diversity statement (or at least a tie-in to it) like #9. |
To be honest, I think this might be worth jumping the queue on #42, just to come up with a special case for ensuring this structure is strictly adhered to, since it's a crucial structure, and one it's easy to accidentally not follow. |
Actually, I think I found somewhere in making the Dictionary of Reserved Words that this locale format is some kind of standard beyond the IETF. Anyway, also noting that eBay's profile uses a |
I'm thinking
Also, maybe there should be a field for profiles of domains that are profiled but in a specific localization should use, like |
Eh, the diversification of localization can be pursued and discussed in #17 or whatever the cross-repo successor to that issue is going to be, for v0.2.0 or later; this issue's point is, with some caveats (for example, |
Okay, so, all profiles do validate against the schema now, but the validator still doesn't process notes, which is kind of the most common kind of description list in the entire schema (so to speak, as I'll close this, as the concept it originally introduced has definitely landed, but with the open lament that it feels kind of empty, as this structure isn't being enforced against the one kind of property it was originally written for. |
Resolving that lament is being tackled with opws/opws-schemata#1 |
Per #308, further discussion of the subjects in this issue should be conducted on the opws-schemata issue tracker (such as in opws/opws-schemata#12, which rethinks the structure introduced by this issue). |
Fields of open-ended text like
notes
andredflags
should be changed to use objects with the language code for the language the notes are written in (to permit them to be localized in applications that present notes to the user).The text was updated successfully, but these errors were encountered: