From 0342cc898000746cc06278127f1f2e89ce0c28aa Mon Sep 17 00:00:00 2001 From: Cezar Augusto Date: Mon, 10 Apr 2017 20:21:26 -0300 Subject: [PATCH] include and locale-ready webtorrent description (#8209) - Auditors: @jonathansampson - Fix #8208 --- app/extensions.js | 2 ++ app/extensions/brave/locales/en-US/extensions.properties | 2 +- app/locale.js | 1 + js/about/extensions.js | 2 +- 4 files changed, 5 insertions(+), 2 deletions(-) diff --git a/app/extensions.js b/app/extensions.js index 9c525799806..623b339cdea 100644 --- a/app/extensions.js +++ b/app/extensions.js @@ -14,6 +14,7 @@ const extensionState = require('./common/state/extensionState') const appActions = require('../js/actions/appActions') const fs = require('fs') const path = require('path') +const l10n = require('../js/l10n') // Takes Content Security Policy flags, for example { 'default-src': '*' } // Returns a CSP string, for example 'default-src: *;' @@ -193,6 +194,7 @@ let generateTorrentManifest = () => { return { name: 'Torrent Viewer', + description: l10n.translation('l10nWebtorrentDesc'), manifest_version: 2, version: '1.0', content_security_policy: concatCSP(cspDirectives), diff --git a/app/extensions/brave/locales/en-US/extensions.properties b/app/extensions/brave/locales/en-US/extensions.properties index 76ac0b6c3d2..c0406857e13 100644 --- a/app/extensions/brave/locales/en-US/extensions.properties +++ b/app/extensions/brave/locales/en-US/extensions.properties @@ -26,6 +26,6 @@ l10nPocketDesc=Pocket Extension for Brave - The best way to save articles, video l10nSync= Brave Sync l10nSyncDesc= l10nWebtorrent= Torrent Viewer -l10nWebtorrentDesc= +l10nWebtorrentDesc=Uses WebTorrent to display torrents directly in the browser. Supports torrent files and magnet links. l10nVimium= Vimium l10nVimiumDesc= diff --git a/app/locale.js b/app/locale.js index 4d32683445c..2a35e9813bc 100644 --- a/app/locale.js +++ b/app/locale.js @@ -231,6 +231,7 @@ var rendererIdentifiers = function () { 'downloadItemClear', 'downloadToolbarHide', 'downloadItemClearCompleted', + 'l10nWebtorrentDesc', // Caption buttons in titlebar (min/max/close - Windows only) 'windowCaptionButtonMinimize', 'windowCaptionButtonMaximize', diff --git a/js/about/extensions.js b/js/about/extensions.js index c1540d2a68f..318ae656a87 100644 --- a/js/about/extensions.js +++ b/js/about/extensions.js @@ -59,7 +59,7 @@ class ExtensionItem extends ImmutableComponent { {this.props.extension.get('version')} { !['__MSG_extDescriptionGoogleChrome__', '__MSG_appDesc__'].includes(this.props.extension.get('description')) - ?
{bravifyText(this.props.extension.get('description'))}
+ ?
: null }
{this.props.extension.get('base_path')}