Skip to content

Commit

Permalink
Maintain /assets/v5.0.0/images for St Edward’s Crown
Browse files Browse the repository at this point in the history
This change prevents the new crown image assets being copied from v5.1.0+ and leaves Metalsmith to copy committed v5.0.0 assets from `src/assets` instead

1. Use `/assets/images` for new crown
2. Use `/assets/v5.0.0/images` for old crown
  • Loading branch information
colinrotherham committed Feb 6, 2024
1 parent 0a102d5 commit 6e4e44e
Show file tree
Hide file tree
Showing 10 changed files with 14 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lib/metalsmith.js
Original file line number Diff line number Diff line change
Expand Up @@ -134,11 +134,18 @@ module.exports = metalsmith
}

await Promise.all([
// GOV.UK Frontend `/assets/images` use new crown
copyAssets('{fonts/*,images/*,manifest.json}', {
cwd: join(dirname(require.resolve('govuk-frontend')), 'assets'),
dest: 'assets'
}),

// GOV.UK Frontend `/assets/v5.0.0/images` use old crown via `src/assets`
copyAssets('{fonts/*,manifest.json}', {
cwd: join(dirname(require.resolve('govuk-frontend')), 'assets'),
dest: 'assets/v5.0.0'
}),

copyAssets('govuk-frontend.min.css?(.map)', {
cwd: dirname(require.resolve('govuk-frontend')),
dest: 'stylesheets'
Expand Down
Binary file added src/assets/v5.0.0/images/favicon.ico
Binary file not shown.
4 changes: 4 additions & 0 deletions src/assets/v5.0.0/images/favicon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/v5.0.0/images/govuk-crest-2x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/v5.0.0/images/govuk-crest.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/v5.0.0/images/govuk-icon-180.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/v5.0.0/images/govuk-icon-192.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/v5.0.0/images/govuk-icon-512.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/assets/v5.0.0/images/govuk-icon-mask.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 6e4e44e

Please sign in to comment.