Skip to content
Browse files

i18n for input placeholders

  • Loading branch information...
1 parent bd9e363 commit 5135df1c1223fa5baf0bebf268267b7625fcc7c1 @jsamuel jsamuel committed Aug 24, 2012
View
14 src/content/settings/yourpolicy.html
@@ -39,7 +39,7 @@
<div>
<div class="policyheader">
<div id="policysearch">
- <input type="search" placeholder="Search" id="rulesearch"/>
+ <input type="search" id="rulesearch"/>
</div>
<table class="policy">
<colgroup>
@@ -97,15 +97,15 @@
<table>
<tr>
<td class="origindest" data-string="origin"></td>
- <td class="scheme"><input type="text" name="originscheme" placeholder="scheme"/></td>
- <td class="host"><input type="text" name="originhost" placeholder="host"/></td>
- <td class="port"><input type="text" name="originport" placeholder="port"/></td>
+ <td class="scheme"><input type="text" name="originscheme"/></td>
+ <td class="host"><input type="text" name="originhost"/></td>
+ <td class="port"><input type="text" name="originport"/></td>
</tr>
<tr>
<td class="origindest" data-string="destination"></td>
- <td class="scheme"><input type="text" name="destscheme" placeholder="scheme"/></td>
- <td class="host"><input type="text" name="desthost" placeholder="host"/></td>
- <td class="port"><input type="text" name="destport" placeholder="port"/></td>
+ <td class="scheme"><input type="text" name="destscheme"/></td>
+ <td class="host"><input type="text" name="desthost"/></td>
+ <td class="port"><input type="text" name="destport"/></td>
</tr>
</table>
<button onclick="addRule();" data-string="addRule"></button>
View
8 src/content/settings/yourpolicy.js
@@ -4,6 +4,14 @@ PAGE_STRINGS = ['yourPolicy', 'defaultPolicy', 'subscriptions', 'type',
$(function () {
common.localize(PAGE_STRINGS);
+ // l10n for input placeholders.
+ $('#rulesearch').prop('placeholder', _('search'));
+ $('[name=originscheme]').prop('placeholder', _('scheme'));
+ $('[name=destscheme]').prop('placeholder', _('scheme'));
+ $('[name=originhost]').prop('placeholder', _('host'));
+ $('[name=desthost]').prop('placeholder', _('host'));
+ $('[name=originport]').prop('placeholder', _('port'));
+ $('[name=destport]').prop('placeholder', _('port'));
});
const SEARCH_DELAY = 500;
View
4 src/locale/en-US/requestpolicy.properties
@@ -51,6 +51,10 @@ restoreDefaultOnUninstall=Restore default when RequestPolicy is uninstalled
yourPolicy=Your Policy
defaultPolicy=Default Policy
subscriptions=Subscriptions
+search=Search
+scheme=scheme
+host=host
+port=port
type=Type
origin=Origin
destination=Destination

0 comments on commit 5135df1

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