Skip to content
Browse files

Merge branch 'master' of github.com:mozilla/kuma

  • Loading branch information...
2 parents 3feaaef + 36ce01f commit ef16f17d4c3df03add30b3a381e63b8fa89ba24b @lmorchard lmorchard committed Jun 14, 2012
Showing with 55 additions and 21 deletions.
  1. +3 −1 apps/wiki/views.py
  2. +18 −18 configs/htaccess
  3. +19 −1 docs/localization.rst
  4. +14 −0 media/css/mdn-screen.css
  5. +1 −1 settings.py
View
4 apps/wiki/views.py
@@ -1052,7 +1052,9 @@ def autosuggest_documents(request):
# TODO: isolate to just approved docs?
docs = (Document.objects.filter(title__icontains=partial_title,
is_template=0,
- locale=request.locale))
+ locale=request.locale).
+ exclude(title__iregex=r'Redirect [0-9]+$').
+ order_by('title'))
docs_list = []
for d in docs:
View
36 configs/htaccess
@@ -5,24 +5,24 @@
ReWriteEngine On
RewriteBase /
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?mwc/?)$ /apps [NC,PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/?)?)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?addons/?)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?demos.*)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?docs.*)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?users.*/?)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?mobile/?)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?mozilla/?)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?search/?)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?web/?)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?apps.*)$ /mwsgi/$1 [NC,PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?learn.*)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?promote.*)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?events.*)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?profiles?.*)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?discussions.*)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?forum-archive.*)$ /mwsgi/$1 [PT,L]
-RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?jsi18n.*)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?mwc/?)$ /apps [NC,PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/?)?)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?addons/?)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?demos.*)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?docs.*)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?users.*/?)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?mobile/?)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?mozilla/?)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?search/?)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?web/?)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?apps.*)$ /mwsgi/$1 [NC,PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?learn.*)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?promote.*)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?events.*)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?profiles?.*)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?discussions.*)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?forum-archive.*)$ /mwsgi/$1 [PT,L]
+RewriteRule ^(((en-US|de|el|es|fr|fy-NL|ga|ga-IE|he|hr|hu|id|it|ja|ko|nl|pl|pt-BR|pt-PT|ro|ru|sl|sq|th|x-testing|zh-TW|zh-CN)/)?jsi18n.*)$ /mwsgi/$1 [PT,L]
RewriteRule ^(admin(/.*)?)$ /mwsgi/$1 [PT,L]
View
20 docs/localization.rst
@@ -2,7 +2,7 @@
Localization
============
-Kitsune is localized with `gettext <http://www.gnu.org/software/gettext/>`_.
+Kuma is localized with `gettext <http://www.gnu.org/software/gettext/>`_.
User-facing strings in the code or templates need to be marked for gettext
localization.
@@ -278,3 +278,21 @@ Updating strings is pretty easy. Check out the localizations as above, then::
$ python manage.py verbatimize --rename
Congratulations! You've now updated the POT file.
+
+Now commit the POT file to svn::
+
+ $ cd locale
+ $ svn up
+ $ svn ci -m "MDN string update YYYY-MM-DD"
+
+After committing, update the `templates in Verbatim
+<https://localize.mozilla.org/templates/mdn/>`_ from SVN.
+
+![Updating verbatim templates from
+SVN](https://dl.dropbox.com/u/21969365/images/templates_mdn.png)
+
+After updating the templates in Verbatim, `update each language
+<https://localize.mozilla.org/projects/mdn/admin.html>`_ from the templates.
+
+![Updating messages from
+templates](https://dl.dropbox.com/u/21969365/images/mdn_admin_update.png)
View
14 media/css/mdn-screen.css
@@ -1120,3 +1120,17 @@ li.tag-expert label:hover { border-color: #bbb; }
/* @Utility Classes *********/
.hidden { display: none; }
+
+
+/* RTL Classes *********/
+
+/* need to shift around the header */
+.html-rtl #nav { float: right; margin: 0 70px 6px 0; font: 200 18px/1 "Bebas Neue", "League Gothic", "Arial Narrow", Arial, Helvetica, sans-serif; text-transform: uppercase; letter-spacing: .5px; }
+.html-rtl #branding { position: absolute; right: 10px; top: 10px; width: 50%; padding: 2px 70px 0 0; margin: 0 0 10px; }
+.html-rtl #logo img { position: absolute; right: -3px; top: -4px; }
+.html-rtl #masthead .user-state { left: 150px; right: auto; }
+.html-rtl .user-state li + li { padding-right: 10px; margin-right: 8px; margin-left:0; padding-left:0; border-right: 1px solid #666; border-left: 0; }
+.html-rtl #masthead #tabzilla { position: absolute; left: 0; top: 0; right: auto; }
+
+.html-rtl #welcome-close { right: auto; left: 15px; }
+.html-rtl #welcome-open { right: auto; left: 10px; }
View
2 settings.py
@@ -105,7 +105,7 @@
'ca', 'fy-NL', 'ga-IE', 'he', 'hr', 'hu', 'id', 'it', 'ja',
'ka', 'ko', 'nl', 'pl', 'pt-BR', 'pt-PT', 'ro', 'ru', 'sq',
'th', 'tr', 'vi', 'zh-CN', 'zh-TW')
-RTL_LANGUAGES = None # ('ar', 'fa', 'fa-IR', 'he')
+RTL_LANGUAGES = ('ar', 'fa', 'fa-IR', 'he')
DEV_POOTLE_PRODUCT_DETAILS_MAP = {
'pt': 'pt-PT',

0 comments on commit ef16f17

Please sign in to comment.
Something went wrong with that request. Please try again.