-
Notifications
You must be signed in to change notification settings - Fork 334
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 various components to be callable #2734
Conversation
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.
This looks good to me - and anecdotally would've been useful in my previous work using govuk-frontend
!
I've left two small notes on the Changelog, which aren't blocking.
58a2a5d
to
304f02f
Compare
304f02f
to
aab5d33
Compare
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.
Looks grand!
I have been manually doing this in my projects for quite a while (with a wrapper macro). This is brill! |
Updates various components to be callable.
Callers make it easier for users of the Design System to pass large amounts of HTML directly into a component, without having to first assign it to a variable and then pass it to the
html
parameter.Suggested in #941, and based on the list of components I commented there, with some changes.
I intend to make these components callable. In all situations, the called content will replace and take priority over the
html
andtext
parameters.descriptionHtml
anddescriptionText
parameters)I'm no longer considering the following components:
<strong>
element, negating the usefulness of using a caller, as it's unlikely to ever be more than one line of text.