Repository navigation
USWDS 3.1.0 - #4904
Merged
Merged
USWDS 3.1.0#4904
Conversation
- Changes affect screen readers only - packages/usa-validation/src/index.js now adds hidden "incomplete" span on initialization - validate-input.js targets hidden data attribute for list items and sets complete/incomplete labels as necessary.
- Turning Multiple to true adds multiple and size attributes to markdown (twig) - Setting size to 0 defaults in 4 row height as standard for multiple select when size is absent
Updates the validation component's unit test and JS. The new hidden span is created by traversing the parent of validation input until it finds the checklist. Previously it looked for the first validation checklist, which causes problems when the component init's outside of document.body - Replace `select` with `selectOrMatches` to get proper elem context - Create constants for validation input and checklist item - Create function for hidden label span
- Restores select to it's original settings
Co-authored-by: Amy Leadem <93996430+amyleadem@users.noreply.github.com>
3.1.0 release updates (second attempt)
thisisdano
marked this pull request as ready for review
August 5, 2022 16:26
USWDS - HTMLProofer update broken links
thisisdano
marked this pull request as draft
August 5, 2022 16:29
Contributor
Author
|
Updated with most recent merge to |
thisisdano
marked this pull request as ready for review
August 5, 2022 16:35
mejiaj
approved these changes
Aug 5, 2022
amyleadem
approved these changes
Aug 5, 2022
amyleadem
left a comment
Contributor
There was a problem hiding this comment.
Looks good to me!
Note: I made one small copy edit in the description changing "HTML 5" to "HTML5"
thisisdano
marked this pull request as draft
August 5, 2022 20:09
Contributor
Author
|
Reverting changes to |
thisisdano
marked this pull request as ready for review
August 5, 2022 21:09
Contributor
Author
|
Updated hash: |
mejiaj
approved these changes
Aug 5, 2022
amyleadem
approved these changes
Aug 5, 2022
amyleadem
left a comment
Contributor
There was a problem hiding this comment.
Looks good on my checks
This file contains hidden or 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
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.
What's new in USWDS 3.1.0
This release contains markup changes and potentially breaking changes. A⚠️ icon indicates where we've made a change that might be a breaking change for your project.
Package updates
usa-button
Style
aria-disabledto matchdisabled. Now disabled styling is applied whether you usedisabled(disabled and hidden from screen readers) oraria-disabled(disabled and visible to screen readers). (#4783)This also affects these dependent or related packages:
usa-button-groupusa-cardusa-modaltype="button"to all non-form buttons to prevent defaultsubmitbehaviors. This allowed us to removepreventDefault()from the relevant component JS.This is a potentially breaking change. Teams should update all non-form buttons to include
type="button"in their markup.<button>elements that do not receive a definedtypeattribute will inherittype="submit"behaviors by default. This can cause unintended and undesired behavior in our buttons. Resource: Details on button types (Mozilla) (#4695)This also affects these dependent or related packages:
usa-accordionusa-bannerusa-cardusa-headerusa-navbarusa-modalusa-navusa-sidenavusa-button-group
Unstyled buttons in a button group now have proper baseline alignment. (#4812)
usa-checkbox
Style
aria-disabledto matchdisabled. Now disabled styling is applied whether you usedisabled(disabled and hidden from screen readers) oraria-disabled(disabled and visible to screen readers). (#4783)usa-date-picker
Style
aria-disabledto matchdisabled. Now disabled styling is applied whether you usedisabled(disabled and hidden from screen readers) oraria-disabled(disabled and visible to screen readers). (#4783)usa-date-range-picker
Updated documentation to properly show how to disable dates. Our documentation provided incorrect information about where to add
data-min-dateanddata-max-dateattributes to the date range picker component. Add these attributes to theusa-date-range-pickerelement. (uswds/uswds-site#1605)Style
aria-disabledto matchdisabled. Now disabled styling is applied whether you usedisabled(disabled and hidden from screen readers) oraria-disabled(disabled and visible to screen readers). (#4783)usa-header
Fixed mobile menu appearance for different CSS layouts. The menu now appears properly on layouts using flex or CSS grid. (#4817)
usa-hero
Optimize hero image. We replaced our default hero image (644 KB PNG) with an optimized image (147 KB JPG), saving 477 KB. We've also provided a next-generation image format version of the image (105 KB WEBP) as an example.
$theme-hero-image. If your project uses this default hero image, you'll need to make sure to move the new asset (hero.jpg) to your project images directory.$theme-hero-image"#{general.$theme-image-path}/hero.png""#{general.$theme-image-path}/hero.jpg"usa-icon
Added LinkedIn icon. We now have a LinkedIn icon included in our default icon sprite as
linkedin.This also affects these dependent or related packages:
usa-footerusa-password
usa-passwordpackage to use a<button>element instead of an anchor element. This markup is more semantically appropriate for the related on-page user interaction.This is not a breaking change. The old markup is still supported, but teams should consider updating to the new markup for improved semantics. (#4847)
Old
New
usa-radio
Style
aria-disabledto matchdisabled. Now disabled styling is applied whether you usedisabled(disabled and hidden from screen readers) oraria-disabled(disabled and visible to screen readers). (#4783)usa-select
Improved styling for
selectwhen themultipleattribute is present. According to the HTML5 standard, aselectelement whosemultipleattribute is present is "expected to render as an inline-block box whose height is the height necessary to contain as many rows for items as given by the element's display size, or four rows if the [size] attribute is absent." Ourselectnow conforms to this guidance. (#4766)uswds-core
Style
aria-disabledto matchdisabled. Now disabled styling is applied whether you usedisabled(disabled and hidden from screen readers) oraria-disabled(disabled and visible to screen readers). (#4783)uswds-utilities
Integrated the CSS
aspect-ratioproperty into ouradd-aspectutility and mixins. This change aligns us more closely with expected CSS behavior, while also extending the capabilities ofadd-aspect. Users can now applyadd-aspectdirectly to media and media wrappers — without the need to use.usa-embed-container. This update is backwards compatible and was written to preserve previous behavior for browsers that do not support the CSSaspect-ratioproperty. (#4811)Dependency updates
No dependency updates.
0vulnerabilities in regular dependencies (dependencies for USWDS projects installed withnpm install uswds)Internal only:
3 moderate, 32 highvulnerabilities in devDependencies (development dependencies)Release TGZ SHA-256 hash:
727a1883badb336f67f6f355e8fdf7ace9af871ca8af7dbb231b2e3cc7649a9b