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 thank you page #786

Merged
merged 2 commits into from
Nov 29, 2016
Merged

Conversation

WenInCode
Copy link
Contributor

@WenInCode WenInCode commented Nov 27, 2016

What's in this PR?

  • Updated alt text for project's icon on thank you page
  • Updated src of project's icon on thank you page
  • Created thankyou-container component
  • Created thankyou-container component page object
  • Added minor tests for the component.
  • I tried to update the styles to match the desired specification of the related issue ( Finish thank you page #477 ), but I am not at all confident in that. Especially hoping for pointers here, maybe I'll ping it out in the design channel.

code_corps

References

Progress on: #477

}

.text {
margin-bottom: 18px;
color: $light-text;
font-size: 14px;
Copy link

Choose a reason for hiding this comment

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

on #703 I added "font-size: $body-font-size-normal" to the html element, that sets the baseline across the whole app to 14px so there's no need to set it here.

For future reference, we have four font sizes defined on _fonts.scss: 12px (small), 14px (normal), 16px (large) and 18px (x-large).

img {
display: inline-block;
}
margin-bottom: 0px;
Copy link

Choose a reason for hiding this comment

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

small tweak but 0 doesn't take units so "margin-bottom: 0" would be valid CSS


.header {
font-size: 1.5em;
margin-top: 0px;
Copy link

Choose a reason for hiding this comment

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

small tweak but 0 doesn't take units so "margin-bottom: 0" would be valid CSS

}

.header {
font-size: 1.5em;
Copy link

Choose a reason for hiding this comment

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

I like that you're using ems and I think that's probably the way going forward when the app becomes responsive.

With our baseline at 14px 1.5em is rendered as 21px, the Sketch reference has headers set at 24px (1.7em approx.).

Minor conversation at this point but hey, every pixel counts. 😛

.icon img {
display: inline-block;
.header, .text {
margin-bottom: 20px;
Copy link

Choose a reason for hiding this comment

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

I'd set margins as ems as well, 14px is the baseline multiplier so 20px would translate to "margin-bottom: 1.4em"

<div class="icon"><img src={{project.iconLargeUrl}} alt={{projectIconAltText}} data-test-selector="project icon" /></div>
<h3 class="header">Thank you!</h3>
<div class="text" data-test-selector="thank you message">From all the volunteers on the {{project.title}} team.</div>
<div class="project-link">{{#link-to "project" project}}Back to project{{/link-to}}</div>
Copy link

@rlueder rlueder Nov 28, 2016

Choose a reason for hiding this comment

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

This comment applies to all html elements above (and it's really just a suggestion). To follow the BEM approach described on #672 I'd make the following changes:

<div class="thankyou-container">
<div class="thankyou-container__message">
<div class="project-icon"></div> (more descriptive than just "icon" and could be used on other templates. If a class "icon" already exists you can extend project-icon with: @extend icon)
<h3>Thank you!</h3>
<p>From all the volunteers on the {{project.title}} team.</p>
{{#link-to "project" project class="project-link"}}Back to project{{/link-to}} (you can add a class directly to the view helper)
</div>
</div>

This would of course affect the css above and also the tests, I think it'd make it easier to style the component, most of the styling would be inherited.

@joshsmith
Copy link
Contributor

I've got this.

WenInCode and others added 2 commits November 28, 2016 20:57
add thankyou-container page object
add tests
update src and alt of icon image
try to update styling
@joshsmith joshsmith force-pushed the update-thank-you-page branch from 6c4d80a to 3d6457b Compare November 29, 2016 04:58
Copy link
Contributor

@joshsmith joshsmith left a comment

Choose a reason for hiding this comment

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

👍 from me but need another look.

@joshsmith joshsmith merged commit 3c53ead into code-corps:develop Nov 29, 2016
@joshsmith joshsmith deleted the update-thank-you-page branch November 29, 2016 05:41
@joshsmith joshsmith mentioned this pull request Nov 29, 2016
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants