Skip to content

Commit

Permalink
Apply SVG optimization recursively to image subfolders (#411)
Browse files Browse the repository at this point in the history
* Update svgo to latest

* Run SVG optimization recursively

* Optimize images

* Update CHANGELOG.md

* Update dependencies for 9.0 release (#412)

* Use non-abbreviated name for command flags

Co-authored-by: Zach Margolis <zachmargolis@users.noreply.github.com>

---------

Co-authored-by: Zach Margolis <zachmargolis@users.noreply.github.com>
  • Loading branch information
aduth and zachmargolis authored Mar 1, 2024
1 parent 6c68c10 commit d999c64
Show file tree
Hide file tree
Showing 18 changed files with 1,515 additions and 1,136 deletions.
29 changes: 17 additions & 12 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,18 +31,23 @@
- `gray-50` (use `base` instead)
- `gray-70` (use `base-darker` instead)
- `gray-90` (use `base-darkest` instead)
- Remove images not integral to the design system. If you use any of these images, consider proposed alternatives below, or copy [the image from the previous release](https://github.com/18F/identity-design-system/tree/v8.1.2/src/img) into your project:
- `illustrations/fail.svg` (legacy alert icon, new alert icons will be introduced in a future release)
- `illustrations/security-key.svg`
- `angle-arrow-down-white-hover.svg` (use `expand_more` icon instead)
- `angle-arrow-down-white.svg` (use `expand_more` icon instead)
- `angle-arrow-down.svg` (use `expand_more` icon instead)
- `angle-arrow-up-white-hover.svg` (use `expand_less` icon instead)
- `angle-arrow-up-white.svg` (use `expand_less` icon instead)
- `angle-arrow-up.svg` (use `expand_less` icon instead)
- `close-primary.svg` (use `close` icon instead)
- `close.svg` (use `close` icon instead)
- `hero.png`
- Remove images not integral to the design system. ([#410](https://github.com/18F/identity-design-system/pull/410))
- If you use any of these images, consider proposed alternatives below, or copy [the image from the previous release](https://github.com/18F/identity-design-system/tree/v8.1.2/src/img) into your project:
- `illustrations/fail.svg` (legacy alert icon, new alert icons will be introduced in a future release)
- `illustrations/security-key.svg`
- `angle-arrow-down-white-hover.svg` (use `expand_more` icon instead)
- `angle-arrow-down-white.svg` (use `expand_more` icon instead)
- `angle-arrow-down.svg` (use `expand_more` icon instead)
- `angle-arrow-up-white-hover.svg` (use `expand_less` icon instead)
- `angle-arrow-up-white.svg` (use `expand_less` icon instead)
- `angle-arrow-up.svg` (use `expand_less` icon instead)
- `close-primary.svg` (use `close` icon instead)
- `close.svg` (use `close` icon instead)
- `hero.png`

### Improvements

- Optimize images to reduce their size. ([#411](https://github.com/18F/identity-design-system/pull/411))

### New Features

Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ typecheck:
npm run typecheck

optimize-svg:
$(NODE_BIN)/svgo --config svgo.config.js -f src/img
$(NODE_BIN)/svgo --config svgo.config.js --recursive --folder src/img

optimize-assets: optimize-svg

Expand Down
Loading

0 comments on commit d999c64

Please sign in to comment.