Skip to content

Commit

Permalink
Merge pull request #4088 from uswds/release-2.10.3
Browse files Browse the repository at this point in the history
Release 2.10.3
  • Loading branch information
mejiaj authored Mar 15, 2021
2 parents 5c7d465 + 6138513 commit 1da984a
Show file tree
Hide file tree
Showing 22 changed files with 27,367 additions and 98 deletions.
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ This repository is for the design system code itself. We maintain [another repos
- [Recent updates](#recent-updates)
- [Getting started](#getting-started)
- [Using the design system](#using-the-design-system)
- [Download](#download)
- [Download and install](#download-and-install)
- [Install using `npm`](#install-using-npm)
- [Using the USWDS package](#using-the-uswds-package)
- [Sass and theme settings](#sass-and-theme-settings)
Expand Down Expand Up @@ -56,18 +56,18 @@ We’re glad you’d like to use the design system — here’s how you can get

How you implement the design system depends on the needs of your project and your workstyle. We recommend implementing the design system with `npm`, but we also provide a direct download if `npm` will not work for you or your project.

- **[Download the design system](#download)** if you are not familiar with `npm` and package management.
- **[Download the design system](#download-and-install)** if you are not familiar with `npm` and package management.

- **[Use the design system `npm` package](#install-using-npm)** if you are familiar with using `npm` and package management.

### Download and install

1. Download the [USWDS zip file](https://github.com/uswds/uswds/releases/download/v2.10.2/uswds-2.10.2.zip) from the latest USWDS release and open that file.
1. Download the [USWDS zip file](https://github.com/uswds/uswds/releases/download/v2.10.3/uswds-2.10.3.zip) from the latest USWDS release and open that file.

After extracting the zip file you should see the following file and folder structure:

```
uswds-2.10.2/
uswds-2.10.3/
├── css/
│   ├── uswds.min.css.map
│   ├── uswds.min.css
Expand Down Expand Up @@ -98,7 +98,7 @@ How you implement the design system depends on the needs of your project and you
```
example-project/
├── assets/
│   ├── uswds-2.10.2/
│   ├── uswds-2.10.3/
│   ├── stylesheets/
│   ├── images/
│   └── javascript/
Expand All @@ -118,11 +118,11 @@ How you implement the design system depends on the needs of your project and you
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<title>My Example Project</title>
<script src="assets/uswds-2.10.2/js/uswds-init.min.js"></script>
<link rel="stylesheet" href="assets/uswds-2.10.2/css/uswds.min.css" />
<script src="assets/uswds-2.10.3/js/uswds-init.min.js"></script>
<link rel="stylesheet" href="assets/uswds-2.10.3/css/uswds.min.css" />
</head>
<body>
<script src="assets/uswds-2.10.2/js/uswds.min.js"></script>
<script src="assets/uswds-2.10.3/js/uswds.min.js"></script>
</body>
</html>
```
Expand Down
6 changes: 2 additions & 4 deletions config/gulp/images.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,8 @@ const dutil = require("./doc-util");

const task = "images";

gulp.task(task, (done) => {
gulp.task(task, () => {
dutil.logMessage(task, "Copying Images");
const stream = gulp.src("src/img/**/*").pipe(gulp.dest("dist/img"));

done();
return stream;
return gulp.src("src/img/**/*").pipe(gulp.dest("dist/img"));
});
1 change: 1 addition & 0 deletions config/gulp/javascript.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/* eslint-disable arrow-body-style */
const buffer = require("vinyl-buffer");
const browserify = require("browserify");
const childProcess = require("child_process");
Expand Down
2 changes: 1 addition & 1 deletion config/gulp/release.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
const del = require("del");
const spawn = require("cross-spawn");
const gulp = require("gulp");
const dutil = require("./doc-util");
const crypto = require('crypto');
const fs = require('fs');
const dutil = require("./doc-util");

const task = "release";
const hash = crypto.createHash('sha256');
Expand Down
7 changes: 2 additions & 5 deletions config/gulp/sass.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,15 +73,12 @@ gulp.task("copy-vendor-sass", () => {
return stream;
});

gulp.task("copy-dist-sass", (cb) => {
gulp.task("copy-dist-sass", () => {
dutil.logMessage("copy-dist-sass", "Copying all Sass to dist dir");

const stream = gulp
return gulp
.src("src/stylesheets/**/*.scss")
.pipe(gulp.dest("dist/scss"));

cb();
return stream;
});

gulp.task(
Expand Down
40 changes: 18 additions & 22 deletions config/gulp/svg-sprite.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
/* eslint-disable arrow-body-style */
const gulp = require('gulp');
const del = require('del');
const svgSprite = require('gulp-svg-sprite');
const rename = require('gulp-rename');
const svgPath = 'src/img';

const svgPath = 'src/img';

// More complex configuration example
config = {
const config = {
shape: {
dimension: { // Set maximum dimensions
maxWidth: 24,
Expand All @@ -24,33 +25,28 @@ config = {
}
};

gulp.task("build-sprite", function (done) {
gulp.src(`${svgPath}/usa-icons/**/*.svg`)
gulp.task("build-sprite", (done) => {
return gulp.src(`${svgPath}/usa-icons/**/*.svg`)
.pipe(svgSprite(config))
.on('error', function(error) {
console.log("There was an error");
})
// eslint-disable-next-line no-console
.on('error', (error) => console.error("There was an error", error))
.pipe(gulp.dest(`${svgPath}`))
.on('end', function () { done(); });
});
.on('end', () => done())
});

gulp.task("rename-sprite", () => {
return gulp.src(`${svgPath}/symbol/svg/sprite.symbol.svg`)
.pipe(rename(`${svgPath}/sprite.svg`))
.pipe(gulp.dest(`./`));
});

gulp.task("rename-sprite", function (done) {
gulp.src(`${svgPath}/symbol/svg/sprite.symbol.svg`)
.pipe(rename(`${svgPath}/sprite.svg`))
.pipe(gulp.dest(`./`))
.on('end', function () { done(); });
});
gulp.task("clean-sprite", () => del(`${svgPath}/symbol`));

gulp.task("clean-sprite", function(cb) {
cb();
return del.sync(`${svgPath}/symbol`);
});

gulp.task(
gulp.task(
"svg-sprite",
gulp.series(
"build-sprite",
"rename-sprite",
"clean-sprite"
)
);
);
Loading

0 comments on commit 1da984a

Please sign in to comment.