Skip to content

Releases: newjersey/njwds

v2.1.0

17 Dec 21:48
Compare
Choose a tag to compare

What's Changed

  • [✨ New] Separate icon compiled CSS included (dist/css/icon.css)

Full Changelog: v2.0.1...v2.1.0

v2.0.0

13 Dec 16:42
Compare
Choose a tag to compare

What's changed

General

  • [⚙️ Tweak] USWDS bumped from 3.5 to 3.10 (see USWDS changelog)
  • [✨ New] Separate button compiled CSS included (dist/css/button.css)

Buttons (breaking changes)

After upgrading to this version, check all button uses for potential regressions.

  • [🚨 Breaking] Default vertical padding increased from 0.75 rem to 1 rem
  • [🚨 Breaking] Default height changed from auto to fixed 3 rem
  • [⚙️ Tweak] Color changes to focus outline on the following buttons variants:
    • .usa-button–secondary (including hover and active states)
    • .usa-button–outline (including hover and active states)
    • .usa-button–unstyled (including hover and active states)
    • .usa-button–outline.usa-button–inverse
  • [⚙️ Tweak] Styling changes to .usa-button–unstyled
    • Rounded border radius (0.25 rem)
    • Increased padding (0.25 rem)
    • Default bolded font weight
    • Auto height
  • [✨ New] Added nj-button--icon class that can be used to include icons in buttons with the correct padding, etc. already adjusted.
    • See docs for examples of icon trailing, icon leading, and icon only buttons for each variant.
  • [✨ New] Updated button variants to include type (primary, secondary, tertiary) and color theme (light, dark, danger). See the comparison below and our documentation for more.

Button comparison

Visual style New naming Old naming CSS classes
Screenshot 2024-12-13 at 4 18 28 PM primary light primary usa-button
Screenshot 2024-12-13 at 4 18 59 PM primary dark n/a usa-button nj–button--primary-dark
Screenshot 2024-12-13 at 4 19 08 PM primary danger danger usa-button usa-button--secondary
Screenshot 2024-12-13 at 4 20 23 PM secondary light outline usa-button usa-button--outline
Screenshot 2024-12-13 at 4 20 31 PM secondary dark outline inverse usa-button usa-button--outline usa-button--inverse
Screenshot 2024-12-13 at 4 20 36 PM secondary danger n/a usa-button usa-button--outline nj-button--outline-danger
Screenshot 2024-12-13 at 4 20 40 PM tertiary light unstyled (for all old variants besides outline inverse ) usa-button usa-button--unstyled
Screenshot 2024-12-13 at 4 20 45 PM tertiary dark unstyled (for the old outline inverse variant) usa-button usa-button--unstyled nj-button--unstyled-dark
Screenshot 2024-12-13 at 4 20 50 PM tertiary danger n/a usa-button usa-button--unstyled nj-button--unstyled-danger

Icons (breaking changes)

  • [🚨 Breaking] Default sizing for usa-icon class is now 20px x 20px.
    • Before, they used to scale automatically with font size. If you need to keep that behavior, use the class .nj-icon--size-scale.
  • [✨ New] Added documentation for icons with example sizes

Radio buttons

  • [⚙️ Tweak] Updated default radio button styling – adjusted colors of the input circle and focus rings, removed white background from the button labels.
  • [⚙️ Tweak] Color changes for tile variant (see below)
  • [✨ New] Added documentation for tile variant (usa-radio__input--tile)

Radio button comparison

USWDS Version (old) NJWDS Version (new)
Screenshot 2024-12-13 at 4 25 40 PM Screenshot 2024-12-13 at 4 25 43 PM
Screenshot 2024-12-13 at 4 25 50 PM Screenshot 2024-12-13 at 4 25 56 PM

Radio button tile comparison

USWDS Version (old) NJWDS Version (new)
Screenshot 2024-12-13 at 4 26 03 PM Screenshot 2024-12-13 at 4 26 07 PM

Full changelog: v1.0.0...v2.0.1

New contributors

v1.0.0

07 Jul 15:41
10edbb9
Compare
Choose a tag to compare

What's Changed

Design system

  • [Potentially UI/UX breaking change] Updated theme color palette - primary color changed from green to blue; base color changed from gray to a lighter cool gray; added state palette related to error, warning, info, disabled, and emergency states (see src/sass/_uswds-theme.scss for full palette)
  • Upgraded USWDS dependency from version 3.0.1 to 3.5.0 (learn more about the upstream changes on the USWDS Releases page)
  • Set custom override to usa-nav__secondary-link a to make link color base-darker instead of base, preventing color contrast issues
  • Set custom override to usa-header--extended usa-logo to make container max-width 50% instead of 30%, preventing text wrapping on header title

Component previews

  • Fixed incorrect label for "Public Sans" font component
  • Added "kitchen sink" component that allows previewing of multiple patterns on a page

Full Changelog: v0.3.0...v1.0.0

v0.3.0

19 Oct 15:31
Compare
Choose a tag to compare

What's Changed

  • Include src directory in NPM package (to allow users of package to customize assets pulled into project) by @namanaman in #22
  • Include build files in NPM package by @namanaman in #23

New Contributors

Full Changelog: v0.2.0...v0.3.0

v0.2.0

26 Sep 19:36
Compare
Choose a tag to compare

What's Changed

  • Initial release of NJWDS to NPM registry

Full Changelog: https://github.com/newjersey/njwds/commits/v0.2.0