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

Update design for recommended Test Plans in the support tables #1096

Merged

Conversation

Paul-Clue
Copy link
Collaborator

see issue #3018

This pull request adds support for tests with a "Recommended" phase in the APG support tables.

@Paul-Clue Paul-Clue requested a review from alflennik May 15, 2024 15:24
@Paul-Clue Paul-Clue changed the title Recommended reports banner in support table Account for tests that have recommended phase in the support tabels May 15, 2024
@Paul-Clue Paul-Clue requested a review from howard-e May 15, 2024 16:00
@Paul-Clue Paul-Clue changed the base branch from development to support-tables-restructure May 15, 2024 19:54
@Paul-Clue Paul-Clue changed the base branch from support-tables-restructure to development May 15, 2024 19:57
@Paul-Clue Paul-Clue changed the base branch from development to support-tables-restructure May 15, 2024 19:58
Copy link
Contributor

@howard-e howard-e left a comment

Choose a reason for hiding this comment

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

Looks good! Thanks for taking another look at the design supporting the RECOMMENDED copy and color scheme as well!

I've left some additional inline thoughts below.

But the key "issue" is a color change has been missed, when the details panel is open. I tested it on the WAI website to see how it looks and noticed the borders in the expanded view are don't match the green accent. You can also see it on the /embed link by zooming in your browser to the maximum %.

Screenshot 2024-05-16 at 9 27 35 AM

Comment on lines 75 to 78
.details > summary.recommended {
border: 1.5px solid #7ac498;
background-color: #e9fbe9;
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
.details > summary.recommended {
border: 1.5px solid #7ac498;
background-color: #e9fbe9;
}

Duplicated below rule

Comment on lines 105 to 116
.details > summary > span {
position: relative;
padding-left: var(--left-right-padding);
padding-right: var(--left-right-padding);
}

.details > summary > span > h4 {
font-family: Arial, Helvetica, sans-serif;
font-size: 1em;
color: #60470c;
display: inline-block;
}
Copy link
Contributor

Choose a reason for hiding this comment

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

It is a bit lost on me why an extra <span> is needed looking at the structure. But I also acknowledge that I'm looking at this after several revisions so perhaps this has already been explained.

Seems to me like the following should give the same result:

.details > summary > h4 {
    position: relative;
    padding-left: var(--left-right-padding);
    padding-right: var(--left-right-padding);

    font-family: Arial, Helvetica, sans-serif;
    font-size: 1em;
    color: #60470c;
    display: inline-block;
}

<details id='embed-report-phase-container'>
<summary id='candidate-title'><span>Warning! Unapproved Report</span></summary>
<div id='candidate-content-container'>
<details class="details">
Copy link
Contributor

Choose a reason for hiding this comment

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

While not wrong to have the class name be the same as the element name, and there may be cases why you'd want to do that, I'm not sure why the need here. To me, it seems better to directly target the details element rather than define a .details class, but this is purely opinion.

<summary id='candidate-title'><span>Warning! Unapproved Report</span></summary>
<div id='candidate-content-container'>
<details class="details">
<summary><span><h4>Warning! Unapproved Report</h4></span></summary>
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
<summary><span><h4>Warning! Unapproved Report</h4></span></summary>
<summary><h4>Warning! Unapproved Report</h4></summary>

Based on my above comment on not needing to target <span>. Also typically, inline elements shouldn't contain block elements and I can't say I come across much instances of <h*> inside a <span> (but I'm sure there are exceptions!)

</div>
</details>
<details class="details">
<summary class="recommended"><span><h4>Recommended Report</h4></span></summary>
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
<summary class="recommended"><span><h4>Recommended Report</h4></span></summary>
<summary class="recommended"><h4>Recommended Report</h4></summary>

Same thought as before

</ol>
</div>
</details>
<details >
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
<details >
<details>

@howard-e
Copy link
Contributor

@Paul-Clue thanks for addressing so much here. Last issue I just came across is that the default <summary> arrow is still showing when on Safari. Please see the following screenshot:

screenshot show default summary arrow

You could fix this by adding the following to the css:

details summary::-webkit-details-marker {
    display: none;
}

Should be good to merge after!

@howard-e howard-e changed the title Account for tests that have recommended phase in the support tabels Update design for recommended Test Plans in the support tables May 20, 2024
Copy link
Contributor

@howard-e howard-e left a comment

Choose a reason for hiding this comment

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

Looks good, thanks for addressing the feedback!

@howard-e howard-e merged commit 9161715 into support-tables-restructure May 20, 2024
3 checks passed
@howard-e howard-e deleted the recommended-reports-banner-in-support-table branch May 20, 2024 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants