-
Notifications
You must be signed in to change notification settings - Fork 17
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
Use upstream form components #671
Conversation
@@ -4,7 +4,7 @@ cy: | |||
common: | |||
last_updated: "Diweddarwyd diwethaf" | |||
components: | |||
radio: | |||
radio: # TODO: Push this upstream to the govuk_publishing_gem and remove from here |
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.
See this TODO, I made a mistake forgetting to move the Welsh translation of the Radio component when moving it into the gem.
I'll follow this up with another PR, but this is a good illustration of why co-locating files is so important, this would have been pretty hard to mess up if the files were right next to each other.
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.
A script would help mitigate this in the short term.
I'm going to bump this with the fix and clean it up. |
@import 'components/*'; | ||
|
||
// Components from govuk_publishing_components gem | ||
@import 'components/fieldset'; |
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.
Using the same namespace is confusing isn't it.
I would have expected govuk_publishing_components/fieldset
. Developers unfamiliar with the gem will find it hard to locate the source.
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.
or gem_components/
to match static
Yeah very, we could consider moving the components, for now this comment should help somewhat.
cc @andysellick
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.
Yeah, govuk_publishing_components/component-name would be good. Firebreak? :)
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.
Namespace problem being looked at in alphagov/govuk_publishing_components#136
We moved this component into the gem for use across other apps.
df1b5b4
to
2817a3c
Compare
We moved some form components to the gem this PR removes the application ones and use the gem versions instead.
See https://government-frontend-pr-671.herokuapp.com/examples/service_sign_in/service_sign_in/choose-sign-in for an example of a real page using the new components
See the component guide for moved components: https://government-frontend-pr-671.herokuapp.com/component-guide