Skip to content

Commit

Permalink
renamed fc/nls/templates to fc/nls/ui, and merged fc/nls/misc into it.
Browse files Browse the repository at this point in the history
  • Loading branch information
toolness committed Dec 5, 2012
1 parent fc1d50a commit 045f73a
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 25 deletions.
17 changes: 0 additions & 17 deletions js/fc/nls/misc.js

This file was deleted.

21 changes: 18 additions & 3 deletions js/fc/nls/templates.js → js/fc/nls/ui.js
@@ -1,7 +1,16 @@
"use strict";

define([ define([
"inline-l10n" "inline-l10n"
], function(InlineL10n) { ], function(InlineL10n) {
var root = {}; var root = {
"page-load-err": 'Sorry, an error occurred while trying to get the page.',
"publish-err": 'Sorry, an error occurred while trying to publish.',
"facebook-locale": "en_US",
"default-tweet": "Check out the #MozThimble page I just made:",
"tweet": "Tweet"
};

if (typeof(document) == "undefined") { if (typeof(document) == "undefined") {
// We're running in node. Parse all inline l10n strings out // We're running in node. Parse all inline l10n strings out
// of all templates. // of all templates.
Expand All @@ -17,8 +26,14 @@ define([
} }
}); });
} }

return { return {
description: "Strings for the UI defined in template files.", description: "Strings for the user interface.",
root: root root: root,
metadata: {
"facebook-locale": {
help: "Locale passed to Facebook for social media actions."
}
}
}; };
}); });
2 changes: 1 addition & 1 deletion js/fc/ui/publish.js
Expand Up @@ -2,7 +2,7 @@


define(function (require) { define(function (require) {
var $ = require("jquery"), var $ = require("jquery"),
i18nBundle = require("i18n!fc/nls/misc"), i18nBundle = require("i18n!fc/nls/ui"),
BackboneEvents = require("backbone-events"), BackboneEvents = require("backbone-events"),
SocialMedia = require("./social-media"), SocialMedia = require("./social-media"),
ConfirmDialogTemplate = require("template!confirm-dialog"), ConfirmDialogTemplate = require("template!confirm-dialog"),
Expand Down
2 changes: 1 addition & 1 deletion js/fc/ui/social-media.js
Expand Up @@ -6,7 +6,7 @@
* they click the like button and we don't like that kind of * they click the like button and we don't like that kind of
* monitoring behaviour. * monitoring behaviour.
*/ */
define(["i18n!fc/nls/misc"], function(i18nBundle) { define(["i18n!fc/nls/ui"], function(i18nBundle) {
return function SocialMedia() { return function SocialMedia() {
var urlPlaceHolder = "__URL__PLACE__HOLDER__"; var urlPlaceHolder = "__URL__PLACE__HOLDER__";


Expand Down
2 changes: 1 addition & 1 deletion js/friendlycode.js
@@ -1,6 +1,6 @@
define(function(require) { define(function(require) {
var $ = require("jquery"), var $ = require("jquery"),
i18nBundle = require("i18n!fc/nls/misc"), i18nBundle = require("i18n!fc/nls/ui"),
Preferences = require("fc/prefs"), Preferences = require("fc/prefs"),
Editor = require("fc/ui/editor"), Editor = require("fc/ui/editor"),
Modals = require("fc/ui/modals"), Modals = require("fc/ui/modals"),
Expand Down
4 changes: 2 additions & 2 deletions js/require-plugins/template.js
Expand Up @@ -4,7 +4,7 @@ define([
"text", "text",
"underscore", "underscore",
"inline-l10n", "inline-l10n",
"i18n!fc/nls/templates" "i18n!fc/nls/ui"
], function (module, text, _, InlineL10n, i18nBundle) { ], function (module, text, _, InlineL10n, i18nBundle) {
var buildMap = {}, var buildMap = {},
masterConfig = module.config(); masterConfig = module.config();
Expand All @@ -29,7 +29,7 @@ define([
if (buildMap[moduleName]) { if (buildMap[moduleName]) {
var content = buildMap[moduleName]; var content = buildMap[moduleName];
write.asModule(pluginName + "!" + moduleName, write.asModule(pluginName + "!" + moduleName,
"define(['underscore', 'inline-l10n', 'i18n!fc/nls/templates'], " + "define(['underscore', 'inline-l10n', 'i18n!fc/nls/ui'], " +
"function (_, InlineL10n, i18nBundle) { \n return " + content + "function (_, InlineL10n, i18nBundle) { \n return " + content +
";});\n"); ";});\n");
} }
Expand Down

0 comments on commit 045f73a

Please sign in to comment.