-
Notifications
You must be signed in to change notification settings - Fork 14
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
Bring in new toolkit with new input fields #450
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pcraig3
force-pushed
the
pc-try-terrific-new-toolkit
branch
from
February 22, 2017 12:25
582f413
to
9e53c70
Compare
pcraig3
changed the title
[WIP] Bring in new toolkit with new input fields
Bring in new toolkit with new input fields
Feb 22, 2017
pcraig3
force-pushed
the
pc-try-terrific-new-toolkit
branch
from
February 22, 2017 12:28
9e53c70
to
a6215dd
Compare
Excellent commits, really easy to read and understand. 👍 |
Brings in the latest govuk_frontend_toolkit available on NPM, and the latest digitalmarketplace toolkit. Also: - removes external link styles, as these will no longer compile - removes custom focused/selected classes for radios/checks
The govuk_frontend_toolkit stuff uses different javascript formatting than us where they begin their files with semicolons but don't end files with them. Our JS does the opposite, and so concatenating the files results in a compilation bug somewhere in the middle.
The phase banner is now always dark blue, which doesn't work on our homepage. Reversing the colours (white background, blue text) instead.
Javascript will automatically treat links with a `role="button"` and a `.link-button` class as buttons. This is part of the govuk_frontend_toolkit, not the digitalmarketplace one.
The digitalmarketplace toolkit is no longer using this class, so let's get rid of it.
Our secondary action links have a few context dependent styles, so I've added a new one and I've pulled them into their own file. Also removed a duplicated import.
pcraig3
force-pushed
the
pc-try-terrific-new-toolkit
branch
from
February 23, 2017 10:11
a6215dd
to
9292dd5
Compare
This was referenced Feb 23, 2017
pcraig3
added a commit
that referenced
this pull request
Feb 24, 2017
Reverts #452 So yesterday, we merged in these changes (#450) and then our functional tests started to break. Upon investigation, we found that it was not able to find checkbox/radio elements [when calling its default 'find_all' method and looking for input fields](https://github.com/alphagov/digitalmarketplace-functional-tests/blob/19f5fa5c7aa2db20dddb921e96869a06614864ac/features/support/form_helpers.rb#L52). Since the default input elements are really small, the new elements actually hide the inputs and draw a custom interface using the `::before` and `::after` psuedo-elements. @robinwhittleton talks about how [hiding the elements was an accessibility challenge](https://gdstechnology.blog.gov.uk/2016/12/13/improving-forms-with-new-radios-and-checkboxes/), but now they work with real-world accessibility software. Unfortunately, [selenium doesn't find hidden elements](http://stackoverflow.com/questions/22110282/how-to-click-on-hidden-element-in-selenium-webdriver), which means it can't find our inputs. Since we can't make large interface changes while G-Cloud is open for suppliers, but we can make testing changes, the decision has been made to merge this now and fix the tests later.
pcraig3
added a commit
that referenced
this pull request
Feb 28, 2017
Reverts #452 So yesterday, we merged in these changes (#450) and then our functional tests started to break. Upon investigation, we found that it was not able to find checkbox/radio elements [when calling its default 'find_all' method and looking for input fields](https://github.com/alphagov/digitalmarketplace-functional-tests/blob/19f5fa5c7aa2db20dddb921e96869a06614864ac/features/support/form_helpers.rb#L52). Since the default input elements are really small, the new elements actually hide the inputs and draw a custom interface using the `::before` and `::after` psuedo-elements. @robinwhittleton talks about how [hiding the elements was an accessibility challenge](https://gdstechnology.blog.gov.uk/2016/12/13/improving-forms-with-new-radios-and-checkboxes/), but now they work with real-world accessibility software. Unfortunately, [selenium doesn't find hidden elements](http://stackoverflow.com/questions/22110282/how-to-click-on-hidden-element-in-selenium-webdriver), which means it can't find our inputs. Since we can't make large interface changes while G-Cloud is open for suppliers, but we can make testing changes, the decision has been made to merge this now and fix the tests later.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request
role="button"
as buttons (ie, "Apply for this opportunity" link)💥 Boom 💥