-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
report: new audit list display, indexes & new icons #5109
Conversation
about to merge displayValue & score together...
review on its way, but few UI comments before I forget:
|
+1 to Patrick's comments around adding dropdown arrows to the opportunities + manual audits + passed audits- i think that might impede discoverability. cc: @hwikyounglee |
.filter(audit => audit.group === 'diagnostics' && audit.result.score < 1); | ||
.filter(audit => audit.group === 'diagnostics' && audit.result.score < 1) | ||
.sort((a, b) => { | ||
const scoreA = a.result.informative ? 100 : a.result.score; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just a heads up to line up with #5105 whoever lands first 🐎 🚗 🏁
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
re:@vinamratasingal's comment on dropdown -- I think once we get the overall left/right alignments on the layout, and the dropdown color being darker as intended, it would look better. Keeping watching out for any issues though!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lookin' real good 👍
--pass-icon-url: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48"><title>check</title><path fill="hsl(139, 70%, 30%)" d="M24 4C12.95 4 4 12.95 4 24c0 11.04 8.95 20 20 20 11.04 0 20-8.96 20-20 0-11.05-8.96-20-20-20zm-4 30L10 24l2.83-2.83L20 28.34l15.17-15.17L38 16 20 34z"/></svg>'); | ||
--average-icon-url: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48"><title>info</title><path fill="hsl(31, 100%, 45%)" d="M24 4C12.95 4 4 12.95 4 24s8.95 20 20 20 20-8.95 20-20S35.05 4 24 4zm2 30h-4V22h4v12zm0-16h-4v-4h4v4z"/></svg>'); | ||
--fail-icon-url: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48"><title>warn</title><path fill="hsl(1, 73%, 45%)" d="M2 42h44L24 4 2 42zm24-6h-4v-4h4v4zm0-8h-4v-8h4v8z"/></svg>'); | ||
--collapsed-triangle-icon-url: url('data:image/svg+xml;utf8,<svg width="12" height="12" viewBox="0 0 12 12" xmlns="http://www.w3.org/2000/svg"><g fill="none" fill-rule="evenodd"><path fill="none" d="M0 0h12v12H0z"/><path fill="hsl(0, 0%, 60%)" d="M3 2l6 4-6 4z"/></g></svg>'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what are these? triangle
makes me think of the alert/fail icon
it looks like toggle-arrow
is the chevron?
maybe we need some comments :)
@@ -462,7 +446,7 @@ summary { | |||
|
|||
.lh-load-opportunity__stats { | |||
text-align: right; | |||
flex: 0 0 var(--lh-audit-score-width); | |||
flex: 0 0 calc(5 * var(--body-font-size)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why the drive by calc now? is the real width not in a var anymore?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just a temporary solution till i take on opportunity display. :)
.lh-score__value--fail::after { | ||
background: var(--fail-icon-url) no-repeat center center / 12px 12px; | ||
.lh-audit--informative .lh-audit__display-text { | ||
color: hsl(216, 5%, 39%); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are we going to reuse this color? it's a gray? css var perhaps then :)
about to merge displayValue & score together...
feedback addressed. bumped the surge reports, too. |
yes, separate PR.
added. and added in the "4 audits" count as well. :)
definitely want to do this. but categoryRenderer doesn't make it easy. so i'll leave it until the file isn't so volatile. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
code LGTM! just some text 🚲 🏠
report's lookin' great!!
let totalBootupTime = 0; | ||
/** @type {Object<string, Object<string, number>>} */ | ||
const extendedInfo = {}; | ||
const devtoolsTimelineModel = await artifacts.requestDevtoolsTimelineModel(trace); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rebase noise?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yah definitely. weird that it shows up. in the diff. I didn't touch these. :/
@@ -161,8 +166,8 @@ class CategoryRenderer { | |||
*/ | |||
_renderFailedAuditsSection(elements) { | |||
const failedElem = this.renderAuditGroup({ | |||
title: `${this._getTotalAuditsLength(elements)} Failed Audits`, | |||
}, {expandable: false}); | |||
title: `Failed audits`, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
aww I liked them caps'd :(
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mocks say no to Title Case. :)
cc @hwikyounglee
@@ -187,8 +192,8 @@ class CategoryRenderer { | |||
*/ | |||
_renderNotApplicableAuditsSection(elements) { | |||
const notApplicableElem = this.renderAuditGroup({ | |||
title: `${this._getTotalAuditsLength(elements)} Not Applicable Audits`, | |||
}, {expandable: true}); | |||
title: `Not applicable`, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why make this different from "Passed/Failed audits" we should remove from all if that's what we want, I'm cool with that 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good points. Happy for now with the current state. // Being said, we'll soon have a chance to polish the UI strings further (recently started sharing the latest mocks with the UX Writer for advice.
e.g.
example reports:
https://ambiguous-river.surge.sh/cnn.html
https://ambiguous-river.surge.sh/tinyhouse.html
https://ambiguous-river.surge.sh/dbwtester.html
https://ambiguous-river.surge.sh/example.html
https://ambiguous-river.surge.sh/paulirish.html
https://ambiguous-river.surge.sh/cnn.devtools.html
https://ambiguous-river.surge.sh/tinyhouse.devtools.html
https://ambiguous-river.surge.sh/dbwtester.devtools.html
https://ambiguous-river.surge.sh/example.devtools.html
https://ambiguous-river.surge.sh/paulirish.devtools.html
In a separate PR I will be adjusting the whitespace and alignment of everything.