NASA Web Design System
The same USWDS you know and love, with NASA theming!
NASA Theme customizations
- Minor tweaks to colors in
- Headings use helvetica instead of source sans pro font in
- NASA meatball favicons in
- Dark header option and other minor visual tweaks in
- See it live!
- To use the dark header option, add the
.usa-header--darkclass to the
- For the close icon in the mobile slideout menu to appear white instead of dark gray replace
close-white.svgin this line of html
<button class="usa-nav__close"><img src="/assets/img/close.svg" alt="close"></button>
How to Use
Like USWDS, NASAWDS has two installation options:
Direct download - Download the .zip file attached to the latest stable release under the assets section. Extract then add the files to your project's code base. For more details see this section in the USWDS developer documentation.
Install using npm - NASAWDS is available as an npm package. To install via npm, follow these instructions, but where it says
nasawds. Once installed, you will find the compiled asset files in the
For more detailed installation and usage instructions see the USWDS developer documentation.
Creating a webpage using NASAWDS
- Create an index.html file at the top of your repository
- Paste into that file
<html> <head> <meta charset="utf-8" /> <meta http-equiv="X-UA-Compatible" content="IE=edge" /> <title>My Example Project</title> <link rel="stylesheet" href="./assets/css/styles.css" /> </head> <bod> <script src="assets/js/uswds.min.js"></script> </body> </html>
- Go to this USWDS page of page templates, find a page template you like, click the 'COMPONENT CODE' button, and copy the HTML code out of the window and into your index.html file between the
- Note that the page templates are form an earlier version of USWDS so the relative links to the CSS, JS, and Img files need to be changed. If you used NPM to get the NASAWDS files, you'll want to do a replace all on the index.html file you currently have such that all
assets/are replaced with
- You should now have a nice looking index.html page to start editing from.
NASAWDS now updates to the latest version of USWDS automagically. (thanks GitHub Actions!)
NASAWDS uses a GitHub Action workflow to check for an updated version of USWDS every 15 days and updates itself automatically with the latest version on the develop branch, and releases a beta pre-release on GitHub and NPM. A two week window is provided for testing. Any issues found should be opened in this repository. After two weeks, if no unresolved issues are present in this GitHub repository, a GitHub Action workflow creates a new stable release on GitHub and NPM and merges develop into master.
NASAWDS starting with version 3 is now using the theming options availble in version 2 of USWDS. Older versions of NASAWDS are still available at their new archived home nasawds-old. This will greatly simplify the maintenance of NASAWDS going forward. The repository is no longer a fork of USWDS, it only contains the theme files necessary to apply NASA-specific changes to USWDS, the build scripts that build NASAWDS by combining the NASAWDS theme files with USWDS, and the GitHub Action workflows that automatically update NASAWDS to the latest non-major version of USWDS.