Just catching up to this in email...
On 5/7/12 8:36 PM, John Karahalis wrote:
> Luke: It looks like the whole page showed up as one string in the .po
> file. Let me know if you figure out what caused that. I edit this page
> often and want to be sure I don't upset our localizers.
What happened is this in templates/demos/devderby_landing.html [1]:
<section id="tab-judging" class="block">
{% trans %}
... 176 lines of HTML later ...
{% endtrans %}
</section>
[1]:
https://github.com/mozilla/kuma/blob/master/apps/demos/templates/demos/devderby_landing.html#L123
I stuck that translation block in there last June, and I think we've
just been expanding its contents ever since then. There's a lot of
content there, though. How would localizers generally like to see it
broken up?
Splitting it such that no HTML appears in strings will result in
probably hundreds of new strings, most without much context to know what
any string means.
Splitting it up at the paragraph or list-item level will result in a
dozen or so new strings, but they will contain HTML. Though for what
it's worth, we have lots of strings containing HTML across projects.
We've always done that in webdev, because sometimes you just can't get
around it. Some strings need to offer the ability to tweak markup and
localize URLs in links.
Either way, splitting this block of content into new {% trans %}...{%
endtrans %} blocks could be done right along with the next content
update for dev derby. I don't think it needs a special-purpose bug,
unless we really want to rework the current dev derby's content.
> On a side note, I know that Drupal's localization tools include syntax
> for excluding HTML (basically sprintf-style placeholders for HTML). Does
> Django have anything similar? Might make work a little bit easier for
> localizers.
FWIW, it's not what Django can support, but what gettext and Verbatim
support. We have to support what localizers use on daily basis, because
introducing new tools just for MDN will mean that they won't get used
and we won't get translations.
That said, just about every project at Mozilla uses gettext, so I think
we can figure something out :)
> Jean-Yves: Please do let me and all of us on the MDN know if there is
> anything we can do to make things easier for our localizers. They can
> even ping us on #mdndev any time they want. I can't speak for everyone,
> but I don't know much about what they see and how our decisions affect
> them (this is my first time seeing a localization form). Any tips to
> improve the feedback loop between us and the localizers would be greatly
> appreciated.
Maybe we need to have an l10n MDN Hack Day / Test Day sometime. It might
be nice, at some point, to schedule an open invite for anyone who's
touched l10n on MDN to come yell at us and be thanked for their work.
For me, l10n is a big black box: We mark up strings, they go down the
hole, and sometimes we get translations back from people I've never met.
It kind of magical, but ignorance means sometimes we try shoving 176
lines of HTML into verbatim :)
--
lorc...@mozilla.com
http://lmorchard.com
{web,mad,computer} scientist