commit | a14625daebe1ea7986f5e54d1ed2eb531388f9e4 | [log] [tgz] |
---|---|---|
author | Mandy Chen <[email protected]> | Fri Jun 14 21:54:39 2019 |
committer | Commit Bot <[email protected]> | Fri Jun 14 21:54:39 2019 |
tree | a22ec3d8256519af43d5717adc118932182ec44d | |
parent | b07d998d110555ee6b1c905400d4195534d94a21 [diff] [blame] |
DevTools: Convert concatenated string and link to embedded link in string in the Network Pane Use UI.formatLocalize to embed a link inside a localizable string. This is a sequent patch to https://crrev.com/c/1658750 Bug: 941561 Change-Id: Ide799e38c935eb63a60a665d77f686f0fa7b4b85 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1660359 Reviewed-by: Alexei Filippov <[email protected]> Commit-Queue: Mandy Chen <[email protected]> Cr-Original-Commit-Position: refs/heads/master@{#669391} Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src Cr-Mirrored-Commit: 447b80d261d6e9aaa932996b61fa0ff8484290a6
diff --git a/front_end/network/BlockedURLsPane.js b/front_end/network/BlockedURLsPane.js index 21e81fb..3991d91 100644 --- a/front_end/network/BlockedURLsPane.js +++ b/front_end/network/BlockedURLsPane.js
@@ -50,11 +50,9 @@ */ _createEmptyPlaceholder() { const element = this.contentElement.createChild('div', 'no-blocked-urls'); - element.createChild('span').textContent = Common.UIString('Requests are not blocked. '); - const addLink = element.createChild('span', 'link'); - addLink.textContent = Common.UIString('Add pattern.'); - addLink.href = ''; + const addLink = UI.XLink.create('', ls`Add pattern`); addLink.addEventListener('click', this._addButtonClicked.bind(this), false); + element.appendChild(UI.formatLocalized('Requests are not blocked. %s.', [addLink])); return element; }