From 09deb9906e39d9f651f180a58c64608e326abd04 Mon Sep 17 00:00:00 2001 From: Chris Date: Tue, 3 Mar 2015 00:22:26 -0700 Subject: [PATCH] request log filtering: add i18n prompt --- src/_locales/en/messages.json | 4 ++++ src/devtool-log.html | 3 ++- src/js/i18n.js | 6 ++++++ 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/src/_locales/en/messages.json b/src/_locales/en/messages.json index 5c88964e5..6be607e82 100644 --- a/src/_locales/en/messages.json +++ b/src/_locales/en/messages.json @@ -35,6 +35,10 @@ "message":"µBlock — Network request log", "description":"Title for the network request log window" }, + "statsFilterPrompt":{ + "message":"filter log entries", + "description": "English: filter log entries" + }, "aboutPageName":{ "message":"About", "description":"appears as tab name in dashboard" diff --git a/src/devtool-log.html b/src/devtool-log.html index e97ac1e9a..8733ee939 100644 --- a/src/devtool-log.html +++ b/src/devtool-log.html @@ -10,7 +10,7 @@
- +
@@ -18,6 +18,7 @@ + diff --git a/src/js/i18n.js b/src/js/i18n.js index bee0b96af..95304f51d 100644 --- a/src/js/i18n.js +++ b/src/js/i18n.js @@ -36,6 +36,12 @@ uDom.onLoad(function() { elem.attr('title', title); } }); + uDom('[placeholder]').forEach(function(elem) { + var placeholder = vAPI.i18n(elem.attr('placeholder')); + if ( placeholder ) { + elem.attr('placeholder', placeholder); + } + }); uDom('[data-i18n-tip]').forEach(function(elem) { elem.attr( 'data-tip',