WebKit Bugzilla
Attachment 357462 Details for
Bug 192769
: Web Inspector: Audit: add plural result strings
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-192769-20181217115957.patch (text/plain), 6.29 KB, created by
Devin Rousso
on 2018-12-17 11:59:58 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Devin Rousso
Created:
2018-12-17 11:59:58 PST
Size:
6.29 KB
patch
obsolete
>diff --git a/Source/WebInspectorUI/ChangeLog b/Source/WebInspectorUI/ChangeLog >index 9152ad45a76b7b16c7970000dfa89f9f834c0cdf..7bfb722a26464a417addd56a3de68047801ea68c 100644 >--- a/Source/WebInspectorUI/ChangeLog >+++ b/Source/WebInspectorUI/ChangeLog >@@ -1,3 +1,19 @@ >+2018-12-17 Devin Rousso <drousso@apple.com> >+ >+ Web Inspector: Audit: add plural result strings >+ https://bugs.webkit.org/show_bug.cgi?id=192769 >+ <rdar://problem/46628680> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * UserInterface/Views/AuditTestContentView.js: >+ (WI.AuditTestContentView.prototype.showNoResultDataPlaceholder): >+ >+ * UserInterface/Views/AuditTestGroupContentView.js: >+ (WI.AuditTestGroupContentView.prototype.layout): >+ >+ * Localizations/en.lproj/localizedStrings.js: >+ > 2018-12-15 Nikita Vasilyev <nvasilyev@apple.com> > > Web Inspector: Styles: toggling selected properties may cause data corruption >diff --git a/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js b/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js >index 0d1dba8a59daa7756ec278f99be8e01629e0f550..544b03b52574efd571df3ea60f10ea2bc0f99fbf 100644 >--- a/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js >+++ b/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js >@@ -25,14 +25,14 @@ localizedStrings["%.3fms"] = "%.3fms"; > localizedStrings["%d Error"] = "%d Error"; > localizedStrings["%d Errors"] = "%d Errors"; > localizedStrings["%d Errors, %d Warnings"] = "%d Errors, %d Warnings"; >-localizedStrings["%d Fail"] = "%d Fail"; >+localizedStrings["%d Failed"] = "%d Failed"; > localizedStrings["%d Frame"] = "%d Frame"; > localizedStrings["%d Frames"] = "%d Frames"; > localizedStrings["%d More\u2026"] = "%d More\u2026"; >-localizedStrings["%d Pass"] = "%d Pass"; >+localizedStrings["%d Passed"] = "%d Passed"; > localizedStrings["%d Threads"] = "%d Threads"; > localizedStrings["%d Unsupported"] = "%d Unsupported"; >-localizedStrings["%d Warn"] = "%d Warn"; >+localizedStrings["%d Warning"] = "%d Warning"; > localizedStrings["%d Warnings"] = "%d Warnings"; > localizedStrings["%d \xd7 %d pixels"] = "%d \xd7 %d pixels"; > localizedStrings["%d \xd7 %d pixels (Natural: %d \xd7 %d pixels)"] = "%d \xd7 %d pixels (Natural: %d \xd7 %d pixels)"; >@@ -921,8 +921,8 @@ localizedStrings["Text Node"] = "Text Node"; > localizedStrings["The \u201C%s\u201D audit failed"] = "The \u201C%s\u201D audit failed"; > localizedStrings["The \u201C%s\u201D audit is unsupported"] = "The \u201C%s\u201D audit is unsupported"; > localizedStrings["The \u201C%s\u201D audit passed"] = "The \u201C%s\u201D audit passed"; >+localizedStrings["The \u201C%s\u201D audit resulted in a warning"] = "The \u201C%s\u201D audit resulted in a warning"; > localizedStrings["The \u201C%s\u201D audit threw an error"] = "The \u201C%s\u201D audit threw an error"; >-localizedStrings["The \u201C%s\u201D audit warned"] = "The \u201C%s\u201D audit warned"; > localizedStrings["The \u201C%s\u201D\ntable is empty."] = "The \u201C%s\u201D\ntable is empty."; > localizedStrings["The page's content has changed"] = "The page's content has changed"; > localizedStrings["The resource was requested insecurely."] = "The resource was requested insecurely."; >diff --git a/Source/WebInspectorUI/UserInterface/Views/AuditTestContentView.js b/Source/WebInspectorUI/UserInterface/Views/AuditTestContentView.js >index 8a401f4cd868fa2219c5665793ddb5d2d3a2941d..840ae3bcaca0f8ee5e6df02266e41377c50f6d8d 100644 >--- a/Source/WebInspectorUI/UserInterface/Views/AuditTestContentView.js >+++ b/Source/WebInspectorUI/UserInterface/Views/AuditTestContentView.js >@@ -180,7 +180,7 @@ WI.AuditTestContentView = class AuditTestContentView extends WI.ContentView > else if (result.didFail) > message = WI.UIString("The \u201C%s\u201D audit failed"); > else if (result.didWarn) >- message = WI.UIString("The \u201C%s\u201D audit warned"); >+ message = WI.UIString("The \u201C%s\u201D audit resulted in a warning"); > else if (result.didPass) > message = WI.UIString("The \u201C%s\u201D audit passed"); > else if (result.unsupported) >diff --git a/Source/WebInspectorUI/UserInterface/Views/AuditTestGroupContentView.js b/Source/WebInspectorUI/UserInterface/Views/AuditTestGroupContentView.js >index a0377e4a4d2d5291b11b7c3b551e2955c4a28377..54bacf4db192211fa932cdb4d83651497bd9e0e9 100644 >--- a/Source/WebInspectorUI/UserInterface/Views/AuditTestGroupContentView.js >+++ b/Source/WebInspectorUI/UserInterface/Views/AuditTestGroupContentView.js >@@ -97,11 +97,12 @@ WI.AuditTestGroupContentView = class AuditTestGroupContentView extends WI.AuditT > if (!this._levelScopeBar) { > let scopeBarItems = []; > >- let addScopeBarItem = (level, label) => { >+ let addScopeBarItem = (level, labelSingular, labelPlural) => { > let count = levelCounts[level]; > if (isNaN(count) || count <= 0) > return; > >+ let label = (labelPlural && count !== 1) ? labelPlural : labelSingular; > let scopeBarItem = new WI.ScopeBarItem(level, label.format(count), { > className: level, > exclusive: false, >@@ -111,10 +112,10 @@ WI.AuditTestGroupContentView = class AuditTestGroupContentView extends WI.AuditT > scopeBarItems.push(scopeBarItem); > }; > >- addScopeBarItem(WI.AuditTestCaseResult.Level.Pass, WI.UIString("%d Pass")); >- addScopeBarItem(WI.AuditTestCaseResult.Level.Warn, WI.UIString("%d Warn")); >- addScopeBarItem(WI.AuditTestCaseResult.Level.Fail, WI.UIString("%d Fail")); >- addScopeBarItem(WI.AuditTestCaseResult.Level.Error, WI.UIString("%d Error")); >+ addScopeBarItem(WI.AuditTestCaseResult.Level.Pass, WI.UIString("%d Passed")); >+ addScopeBarItem(WI.AuditTestCaseResult.Level.Warn, WI.UIString("%d Warning"), WI.UIString("%d Warnings")); >+ addScopeBarItem(WI.AuditTestCaseResult.Level.Fail, WI.UIString("%d Failed")); >+ addScopeBarItem(WI.AuditTestCaseResult.Level.Error, WI.UIString("%d Error"), WI.UIString("%d Errors")); > addScopeBarItem(WI.AuditTestCaseResult.Level.Unsupported, WI.UIString("%d Unsupported")); > > this._levelScopeBar = new WI.ScopeBar(null, scopeBarItems);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 192769
: 357462