Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

core(locales): streamline hover texts #6508

Merged
merged 6 commits into from
Jan 8, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lighthouse-core/audits/metrics/estimated-input-latency.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ const UIStrings = {
/** The name of the metric that marks the estimated time between the page receiving input (a user clicking, tapping, or typing) and the page responding. Shown to users as the label for the numeric metric value. Ideally fits within a ~40 character limit. */
title: 'Estimated Input Latency',
/** Description of the Estimated Input Latency metric that estimates the amount of time, in milliseconds, that the app takes to respond to user input. This description is displayed within a tooltip when the user hovers on the metric name to see more. No character length limits. 'Learn More' becomes link text to additional documentation. */
description: 'The score above is an estimate of how long your app takes to respond to user ' +
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah yes good catch we should definitely change from The score above to Estimated Input Latency 👍

I'm not sure I like a rough guess rather than an estimate, that feels like it doesn't give us quite enough credit for how it's computed :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, simply estimate is probably more meaningful. I want to avoid the word twice in a sentence. Maybe there's an alternative word around.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I'm not sure about "rough guess" maybe "an approximation"?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 on keeping "estimate"

'input, in milliseconds, during the busiest 5s window of page load. If your ' +
description: 'Estimated Input Latency is an estimate of how long your app takes to respond to ' +
'user input, in milliseconds, during the busiest 5s window of page load. If your ' +
'latency is higher than 50 ms, users may perceive your app as laggy. ' +
'[Learn more](https://developers.google.com/web/tools/lighthouse/audits/estimated-input-latency).',
};
Expand Down
4 changes: 2 additions & 2 deletions lighthouse-core/audits/metrics/interactive.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ const UIStrings = {
/** The name of the metric that marks the time at which the page is fully loaded and is able to quickly respond to user input (clicks, taps, and keypresses feel responsive). Shown to users as the label for the numeric metric value. Ideally fits within a ~40 character limit. */
title: 'Time to Interactive',
/** Description of the Time to Interactive (TTI) metric, which evaluates when a page has completed its primary network activity and main thread work. This is displayed within a tooltip when the user hovers on the metric name to see more. No character length limits. 'Learn More' becomes link text to additional documentation. */
description: 'Interactive marks the time at which the page is fully interactive. ' +
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We went with this because the actual moment is called interactive and the metric is the timespan until that moment Time To Interactive. Not opposed to rewording so that the name of the metric is the subject but we'll need to change up the rest of the sentence then :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this was my intention to bring the title to first words in the description as everywhere else already.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it be better as "Time to interactive is the amount of time it takes for the page to become fully interactive?" Since yea, there is a unit disconnect between a span of time (tti) and a point in time (interactive).

nit: What is the capitalization: Time to Interactive or Time to interactive?

'[Learn more](https://developers.google.com/web/tools/lighthouse/audits/consistently-interactive).',
description: 'Time to interactive is the amount of time it takes for the page to become fully ' +
'interactive. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/consistently-interactive).',
};

const str_ = i18n.createMessageInstanceIdFn(__filename, UIStrings);
Expand Down
4 changes: 2 additions & 2 deletions lighthouse-core/lib/i18n/en-US.json
Original file line number Diff line number Diff line change
Expand Up @@ -672,7 +672,7 @@
"description": "Title of a diagnostic audit that provides detail on the main thread work the browser did to load the page. This descriptive title is shown to users when the amount is acceptable and no user action is required."
},
"lighthouse-core/audits/metrics/estimated-input-latency.js | description": {
"message": "The score above is an estimate of how long your app takes to respond to user input, in milliseconds, during the busiest 5s window of page load. If your latency is higher than 50 ms, users may perceive your app as laggy. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/estimated-input-latency).",
"message": "Estimated Input Latency is an estimate of how long your app takes to respond to user input, in milliseconds, during the busiest 5s window of page load. If your latency is higher than 50 ms, users may perceive your app as laggy. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/estimated-input-latency).",
"description": "Description of the Estimated Input Latency metric that estimates the amount of time, in milliseconds, that the app takes to respond to user input. This description is displayed within a tooltip when the user hovers on the metric name to see more. No character length limits. 'Learn More' becomes link text to additional documentation."
},
"lighthouse-core/audits/metrics/estimated-input-latency.js | title": {
Expand Down Expand Up @@ -704,7 +704,7 @@
"description": "The name of the metric that marks the time at which a majority of the content has been painted by the browser. Shown to users as the label for the numeric metric value. Ideally fits within a ~40 character limit."
},
"lighthouse-core/audits/metrics/interactive.js | description": {
"message": "Interactive marks the time at which the page is fully interactive. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/consistently-interactive).",
"message": "Time to interactive is the amount of time it takes for the page to become fully interactive. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/consistently-interactive).",
"description": "Description of the Time to Interactive (TTI) metric, which evaluates when a page has completed its primary network activity and main thread work. This is displayed within a tooltip when the user hovers on the metric name to see more. No character length limits. 'Learn More' becomes link text to additional documentation."
},
"lighthouse-core/audits/metrics/interactive.js | title": {
Expand Down
4 changes: 2 additions & 2 deletions lighthouse-core/test/results/sample_v2.json
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@
"estimated-input-latency": {
"id": "estimated-input-latency",
"title": "Estimated Input Latency",
"description": "The score above is an estimate of how long your app takes to respond to user input, in milliseconds, during the busiest 5s window of page load. If your latency is higher than 50 ms, users may perceive your app as laggy. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/estimated-input-latency).",
"description": "Estimated Input Latency is an estimate of how long your app takes to respond to user input, in milliseconds, during the busiest 5s window of page load. If your latency is higher than 50 ms, users may perceive your app as laggy. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/estimated-input-latency).",
"score": 1,
"scoreDisplayMode": "numeric",
"rawValue": 16,
Expand Down Expand Up @@ -279,7 +279,7 @@
"interactive": {
"id": "interactive",
"title": "Time to Interactive",
"description": "Interactive marks the time at which the page is fully interactive. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/consistently-interactive).",
"description": "Time to interactive is the amount of time it takes for the page to become fully interactive. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/consistently-interactive).",
"score": 0.78,
"scoreDisplayMode": "numeric",
"rawValue": 4927.278,
Expand Down
4 changes: 2 additions & 2 deletions proto/sample_v2_round_trip.json
Original file line number Diff line number Diff line change
Expand Up @@ -569,7 +569,7 @@
"title": "Browser errors were logged to the console"
},
"estimated-input-latency": {
"description": "The score above is an estimate of how long your app takes to respond to user input, in milliseconds, during the busiest 5s window of page load. If your latency is higher than 50 ms, users may perceive your app as laggy. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/estimated-input-latency).",
"description": "Estimated Input Latency is an estimate of how long your app takes to respond to user input, in milliseconds, during the busiest 5s window of page load. If your latency is higher than 50 ms, users may perceive your app as laggy. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/estimated-input-latency).",
"displayValue": "20\u00a0ms",
"id": "estimated-input-latency",
"score": 1.0,
Expand Down Expand Up @@ -953,7 +953,7 @@
"title": "Web app manifest does not meet the installability requirements"
},
"interactive": {
"description": "Interactive marks the time at which the page is fully interactive. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/consistently-interactive).",
"description": "Time to interactive is the amount of time it takes for the page to become fully interactive. [Learn more](https://developers.google.com/web/tools/lighthouse/audits/consistently-interactive).",
"displayValue": "4.9\u00a0s",
"id": "interactive",
"score": 0.78,
Expand Down