From a9f2dfdbec927fe6d37c3218f2e322a49e3a0cd7 Mon Sep 17 00:00:00 2001
From: Roger Howell
Date: Wed, 17 Jan 2024 21:17:46 +0000
Subject: [PATCH] Update page styling to use the DfE styling/layout, and update
the build to have webpack build/package up the HTML/JS/(S)CSS etc.
---
README.md | 27 +
.../.browserslistrc | 16 +
...ayout.cshtml => _DfE_1200px_Layout.cshtml} | 143 ++---
.../Views/Shared/_Layout.cshtml.css | 49 --
.../Views/_ViewStart.cshtml | 13 +-
.../assets/fonts/bold-affa96571d-v2.woff | Bin
.../assets/fonts/bold-b542beb274-v2.woff2 | Bin
.../assets/fonts/light-94a07e06a1-v2.woff2 | Bin
.../assets/fonts/light-f591b13f7d-v2.woff | Bin
.../images/govuk-apple-touch-icon-152x152.png | Bin
.../images/govuk-apple-touch-icon-167x167.png | Bin
.../images/govuk-apple-touch-icon-180x180.png | Bin
.../assets/images/govuk-apple-touch-icon.png | Bin
.../assets/images/govuk-mask-icon.svg | 14 +-
.../babel.config.js | 32 +
.../package-lock.json | 595 +++++++++++++++++-
.../package.json | 10 +-
.../webpack.config.js | 132 +++-
.../wwwroot/css/site.scss | 91 +++
.../wwwroot/js/site.js | 11 +-
20 files changed, 926 insertions(+), 207 deletions(-)
create mode 100644 README.md
create mode 100644 src/ServiceAssessmentService/ServiceAssessmentService.WebApp/.browserslistrc
rename src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/Shared/{_Layout.cshtml => _DfE_1200px_Layout.cshtml} (54%)
delete mode 100644 src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/Shared/_Layout.cshtml.css
mode change 100755 => 100644 src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/bold-affa96571d-v2.woff
mode change 100755 => 100644 src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/bold-b542beb274-v2.woff2
mode change 100755 => 100644 src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/light-94a07e06a1-v2.woff2
mode change 100755 => 100644 src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/light-f591b13f7d-v2.woff
mode change 100755 => 100644 src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon-152x152.png
mode change 100755 => 100644 src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon-167x167.png
mode change 100755 => 100644 src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon-180x180.png
mode change 100755 => 100644 src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon.png
create mode 100644 src/ServiceAssessmentService/ServiceAssessmentService.WebApp/babel.config.js
diff --git a/README.md b/README.md
new file mode 100644
index 00000000..27719980
--- /dev/null
+++ b/README.md
@@ -0,0 +1,27 @@
+## Getting started - local development
+
+- **Software dependencies**
+ - .NET
+ - Node
+- **Install node dependencies**
+ - ```shell
+ cd src/ServiceAssessmentService/ServiceAssessmentService.WebApp
+ npm install
+ ```
+- **Build the HTML/CSS/JS files**
+ - ```shell
+ cd src/ServiceAssessmentService/ServiceAssessmentService.WebApp
+ npm run buildDev:watch
+ ```
+- **Setup secrets**
+ - ...
+- **Compile the C# code**
+ - ```shell
+ cd src/ServiceAssessmentService/ServiceAssessmentService.WebApp
+ dotnet build
+ ```
+- **Run the application**
+ - ```shell
+ cd src/ServiceAssessmentService/ServiceAssessmentService.WebApp
+ dotnet watch
+ ```
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/.browserslistrc b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/.browserslistrc
new file mode 100644
index 00000000..8df824c9
--- /dev/null
+++ b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/.browserslistrc
@@ -0,0 +1,16 @@
+[javascripts]
+supports es6-module
+
+[stylesheets]
+> 0.1% in GB and not dead
+last 6 Chrome versions
+last 6 Firefox versions
+last 6 Edge versions
+last 2 Samsung versions
+Firefox ESR
+Safari >= 11
+iOS >= 11
+ie 11
+
+[node]
+node 18
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/Shared/_Layout.cshtml b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/Shared/_DfE_1200px_Layout.cshtml
similarity index 54%
rename from src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/Shared/_Layout.cshtml
rename to src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/Shared/_DfE_1200px_Layout.cshtml
index 81ad435c..eb197d91 100644
--- a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/Shared/_Layout.cshtml
+++ b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/Shared/_DfE_1200px_Layout.cshtml
@@ -1,15 +1,50 @@
@{
+ // ReSharper disable once Razor.LayoutNotResolved
Layout = "_GovUkPageTemplate";
ViewData["BodyClasses"] = "govuk-template__body";
+
+ // Use the page title, suffixed by the service name
+ ViewData["Title"] += " - Service Assessment Service";
+
+ // get name of current area
+ var area = ViewContext.RouteData.Values["area"] as string;
+
+ // get name of current controller
+ var controller = ViewContext.RouteData.Values["controller"] as string;
+
+ // get name of current action
+ var action = ViewContext.RouteData.Values["action"] as string;
+
+ // get name of current page
+ var page = ViewContext.RouteData.Values["page"] as string;
+
+ // If not a production environment, show the environment name within the title
+ if (!"Production".Equals(Environment.GetEnvironmentVariable("ASPNETCORE_ENVIRONMENT"), StringComparison.OrdinalIgnoreCase))
+ {
+ ViewData["Title"] += $" (environment: {Environment.GetEnvironmentVariable("ASPNETCORE_ENVIRONMENT")})";
+ }
+
+ // If local development environment, include route information in the title (for debugging purposes)
+ if ("Development".Equals(Environment.GetEnvironmentVariable("ASPNETCORE_ENVIRONMENT"), StringComparison.OrdinalIgnoreCase))
+ {
+ ViewData["Title"] += $" (route debug -- area: {area}, controller: {controller}, action: {action}, page: {page})";
+ }
+
+ // Helpers, used to determine which navigation item is currently active
+ var isAreaDefault = (area is null) || ("Home".Equals(area, StringComparison.OrdinalIgnoreCase));
+ var isAreaBook = ("Book".Equals(area, StringComparison.OrdinalIgnoreCase));
+
+
}
+@* ReSharper disable once Razor.SectionNotResolved *@
@section Head {
-
-
+
}
+@* ReSharper disable once Razor.SectionNotResolved *@
@section Header {
@@ -153,6 +106,7 @@
}
+@* ReSharper disable once Razor.SectionNotResolved *@
@section BeforeContent{
Beta
@@ -164,6 +118,7 @@
@RenderBody()
+@* ReSharper disable once Razor.SectionNotResolved *@
@section Footer {
-
}
+
+@* ReSharper disable once Razor.SectionNotResolved *@
@section BodyEnd {
@await RenderSectionAsync("Scripts", required: false)
+
}
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/Shared/_Layout.cshtml.css b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/Shared/_Layout.cshtml.css
deleted file mode 100644
index aa9ecece..00000000
--- a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/Shared/_Layout.cshtml.css
+++ /dev/null
@@ -1,49 +0,0 @@
-/* Please see documentation at https://docs.microsoft.com/aspnet/core/client-side/bundling-and-minification
-for details on configuring this project to bundle and minify static web assets. */
-
-a.navbar-brand {
- white-space: normal;
- text-align: center;
- word-break: break-all;
-}
-
-a {
- color: #0077cc;
-}
-
-.btn-primary {
- color: #fff;
- background-color: #1b6ec2;
- border-color: #1861ac;
-}
-
-.nav-pills .nav-link.active, .nav-pills .show > .nav-link {
- color: #fff;
- background-color: #1b6ec2;
- border-color: #1861ac;
-}
-
-.border-top {
- border-top: 1px solid #e5e5e5;
-}
-.border-bottom {
- border-bottom: 1px solid #e5e5e5;
-}
-
-.box-shadow {
- box-shadow: 0 .25rem .75rem rgba(0, 0, 0, .05);
-}
-
-button.accept-policy {
- font-size: 1rem;
- line-height: inherit;
-}
-
-.footer {
- position: absolute;
- bottom: 0;
- width: 100%;
- white-space: nowrap;
- line-height: 60px;
-}
-
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/_ViewStart.cshtml b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/_ViewStart.cshtml
index 42bd7906..5fda3bbb 100644
--- a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/_ViewStart.cshtml
+++ b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/Views/_ViewStart.cshtml
@@ -1,4 +1,11 @@
-@{
- Layout = "_Layout";
-}
+@*
+ This file, at the application root folder (next to Program.cs), is shared between all views (including within areas).
+ This provides a common default layout for the entire application.
+
+ See also:
+ - https://learn.microsoft.com/en-us/aspnet/core/mvc/controllers/areas?view=aspnetcore-7.0#shared-layout-for-razor-pages-areas
+*@
+@{
+ Layout = "_DfE_1200px_Layout";
+}
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/bold-affa96571d-v2.woff b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/bold-affa96571d-v2.woff
old mode 100755
new mode 100644
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/bold-b542beb274-v2.woff2 b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/bold-b542beb274-v2.woff2
old mode 100755
new mode 100644
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/light-94a07e06a1-v2.woff2 b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/light-94a07e06a1-v2.woff2
old mode 100755
new mode 100644
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/light-f591b13f7d-v2.woff b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/fonts/light-f591b13f7d-v2.woff
old mode 100755
new mode 100644
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon-152x152.png b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon-152x152.png
old mode 100755
new mode 100644
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon-167x167.png b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon-167x167.png
old mode 100755
new mode 100644
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon-180x180.png b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon-180x180.png
old mode 100755
new mode 100644
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon.png b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-apple-touch-icon.png
old mode 100755
new mode 100644
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-mask-icon.svg b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-mask-icon.svg
index 2cf32d6c..d7dc2bbd 100644
--- a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-mask-icon.svg
+++ b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/assets/images/govuk-mask-icon.svg
@@ -1,7 +1,7 @@
-
+
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/babel.config.js b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/babel.config.js
new file mode 100644
index 00000000..b725e0a9
--- /dev/null
+++ b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/babel.config.js
@@ -0,0 +1,32 @@
+/**
+ * Babel config
+ *
+ * @type {import('@babel/core').ConfigFunction}
+ */
+module.exports = function (api) {
+ const isBrowser = !api.env('test')
+
+ // Apply Browserslist environment for supported targets
+ // https://github.com/browserslist/browserslist#configuring-for-different-environments
+ const browserslistEnv = isBrowser ? 'js' : 'node'
+
+ return {
+ presets: [
+ [
+ '@babel/preset-env',
+ {
+ browserslistEnv,
+
+ // Apply bug fixes to avoid transforms
+ bugfixes: true,
+
+ // Apply smaller "loose" transforms for browsers
+ loose: isBrowser,
+
+ // Skip ES module transforms for browsers
+ modules: isBrowser ? false : 'auto'
+ }
+ ]
+ ]
+ }
+}
\ No newline at end of file
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/package-lock.json b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/package-lock.json
index 8efa87ef..b70c4c29 100644
--- a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/package-lock.json
+++ b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/package-lock.json
@@ -13,11 +13,15 @@
"govuk-frontend": "^4.7.0"
},
"devDependencies": {
- "css-loader": "^6.7.1",
+ "copy-webpack-plugin": "^11.0.0",
+ "css-loader": "^6.7.4",
+ "mini-css-extract-plugin": "^2.7.6",
"node-sass": "^9.0.0",
+ "postcss-loader": "^7.3.4",
"sass": "^1.67.0",
- "sass-loader": "^13.3.2",
- "style-loader": "^3.3.1",
+ "sass-loader": "^13.3.3",
+ "style-loader": "^3.3.3",
+ "terser-webpack-plugin": "^5.3.10",
"webpack": "^5.88.2",
"webpack-cli": "^4.9.2"
}
@@ -2172,9 +2176,9 @@
"integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg=="
},
"node_modules/@jridgewell/trace-mapping": {
- "version": "0.3.19",
- "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.19.tgz",
- "integrity": "sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw==",
+ "version": "0.3.21",
+ "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.21.tgz",
+ "integrity": "sha512-SRfKmRe1KvYnxjEMtxEr+J4HIeMX5YBg/qhRHpxEIGjhX1rshcHlnFUE9K0GazhVKWM7B+nARSkV8LuvJdJ5/g==",
"dependencies": {
"@jridgewell/resolve-uri": "^3.1.0",
"@jridgewell/sourcemap-codec": "^1.4.14"
@@ -2877,6 +2881,45 @@
"ajv": ">=5.0.0"
}
},
+ "node_modules/ajv-formats": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-2.1.1.tgz",
+ "integrity": "sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==",
+ "dev": true,
+ "dependencies": {
+ "ajv": "^8.0.0"
+ },
+ "peerDependencies": {
+ "ajv": "^8.0.0"
+ },
+ "peerDependenciesMeta": {
+ "ajv": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/ajv-formats/node_modules/ajv": {
+ "version": "8.12.0",
+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.12.0.tgz",
+ "integrity": "sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==",
+ "dev": true,
+ "dependencies": {
+ "fast-deep-equal": "^3.1.1",
+ "json-schema-traverse": "^1.0.0",
+ "require-from-string": "^2.0.2",
+ "uri-js": "^4.2.2"
+ },
+ "funding": {
+ "type": "github",
+ "url": "https://github.com/sponsors/epoberezkin"
+ }
+ },
+ "node_modules/ajv-formats/node_modules/json-schema-traverse": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",
+ "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==",
+ "dev": true
+ },
"node_modules/ajv-keywords": {
"version": "3.5.2",
"resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.2.tgz",
@@ -4477,6 +4520,135 @@
"node": ">=0.10.0"
}
},
+ "node_modules/copy-webpack-plugin": {
+ "version": "11.0.0",
+ "resolved": "https://registry.npmjs.org/copy-webpack-plugin/-/copy-webpack-plugin-11.0.0.tgz",
+ "integrity": "sha512-fX2MWpamkW0hZxMEg0+mYnA40LTosOSa5TqZ9GYIBzyJa9C3QUaMPSE2xAi/buNr8u89SfD9wHSQVBzrRa/SOQ==",
+ "dev": true,
+ "dependencies": {
+ "fast-glob": "^3.2.11",
+ "glob-parent": "^6.0.1",
+ "globby": "^13.1.1",
+ "normalize-path": "^3.0.0",
+ "schema-utils": "^4.0.0",
+ "serialize-javascript": "^6.0.0"
+ },
+ "engines": {
+ "node": ">= 14.15.0"
+ },
+ "funding": {
+ "type": "opencollective",
+ "url": "https://opencollective.com/webpack"
+ },
+ "peerDependencies": {
+ "webpack": "^5.1.0"
+ }
+ },
+ "node_modules/copy-webpack-plugin/node_modules/ajv": {
+ "version": "8.12.0",
+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.12.0.tgz",
+ "integrity": "sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==",
+ "dev": true,
+ "dependencies": {
+ "fast-deep-equal": "^3.1.1",
+ "json-schema-traverse": "^1.0.0",
+ "require-from-string": "^2.0.2",
+ "uri-js": "^4.2.2"
+ },
+ "funding": {
+ "type": "github",
+ "url": "https://github.com/sponsors/epoberezkin"
+ }
+ },
+ "node_modules/copy-webpack-plugin/node_modules/ajv-keywords": {
+ "version": "5.1.0",
+ "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-5.1.0.tgz",
+ "integrity": "sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw==",
+ "dev": true,
+ "dependencies": {
+ "fast-deep-equal": "^3.1.3"
+ },
+ "peerDependencies": {
+ "ajv": "^8.8.2"
+ }
+ },
+ "node_modules/copy-webpack-plugin/node_modules/glob-parent": {
+ "version": "6.0.2",
+ "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz",
+ "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==",
+ "dev": true,
+ "dependencies": {
+ "is-glob": "^4.0.3"
+ },
+ "engines": {
+ "node": ">=10.13.0"
+ }
+ },
+ "node_modules/copy-webpack-plugin/node_modules/globby": {
+ "version": "13.2.2",
+ "resolved": "https://registry.npmjs.org/globby/-/globby-13.2.2.tgz",
+ "integrity": "sha512-Y1zNGV+pzQdh7H39l9zgB4PJqjRNqydvdYCDG4HFXM4XuvSaQQlEc91IU1yALL8gUTDomgBAfz3XJdmUS+oo0w==",
+ "dev": true,
+ "dependencies": {
+ "dir-glob": "^3.0.1",
+ "fast-glob": "^3.3.0",
+ "ignore": "^5.2.4",
+ "merge2": "^1.4.1",
+ "slash": "^4.0.0"
+ },
+ "engines": {
+ "node": "^12.20.0 || ^14.13.1 || >=16.0.0"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
+ "node_modules/copy-webpack-plugin/node_modules/ignore": {
+ "version": "5.3.0",
+ "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.0.tgz",
+ "integrity": "sha512-g7dmpshy+gD7mh88OC9NwSGTKoc3kyLAZQRU1mt53Aw/vnvfXnbC+F/7F7QoYVKbV+KNvJx8wArewKy1vXMtlg==",
+ "dev": true,
+ "engines": {
+ "node": ">= 4"
+ }
+ },
+ "node_modules/copy-webpack-plugin/node_modules/json-schema-traverse": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",
+ "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==",
+ "dev": true
+ },
+ "node_modules/copy-webpack-plugin/node_modules/schema-utils": {
+ "version": "4.2.0",
+ "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-4.2.0.tgz",
+ "integrity": "sha512-L0jRsrPpjdckP3oPug3/VxNKt2trR8TcabrM6FOAAlvC/9Phcmm+cuAgTlxBqdBR1WJx7Naj9WHw+aOmheSVbw==",
+ "dev": true,
+ "dependencies": {
+ "@types/json-schema": "^7.0.9",
+ "ajv": "^8.9.0",
+ "ajv-formats": "^2.1.1",
+ "ajv-keywords": "^5.1.0"
+ },
+ "engines": {
+ "node": ">= 12.13.0"
+ },
+ "funding": {
+ "type": "opencollective",
+ "url": "https://opencollective.com/webpack"
+ }
+ },
+ "node_modules/copy-webpack-plugin/node_modules/slash": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/slash/-/slash-4.0.0.tgz",
+ "integrity": "sha512-3dOsAHXXUkQTpOYcoAxLIorMTp4gIQr5IW3iVb7A7lFIp0VHhnynm9izx6TssdrIcVIESAlVjtnO2K8bg+Coew==",
+ "dev": true,
+ "engines": {
+ "node": ">=12"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
"node_modules/core-js-compat": {
"version": "3.33.1",
"resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.33.1.tgz",
@@ -8410,6 +8582,15 @@
"node": ">= 10.13.0"
}
},
+ "node_modules/jiti": {
+ "version": "1.21.0",
+ "resolved": "https://registry.npmjs.org/jiti/-/jiti-1.21.0.tgz",
+ "integrity": "sha512-gFqAIbuKyyso/3G2qhiO2OM6shY6EPP/R0+mkDbyspxKazh8BXDC5FiFsUjlczgdNz/vfra0da2y+aHrusLG/Q==",
+ "dev": true,
+ "bin": {
+ "jiti": "bin/jiti.js"
+ }
+ },
"node_modules/joi": {
"version": "17.11.0",
"resolved": "https://registry.npmjs.org/joi/-/joi-17.11.0.tgz",
@@ -9067,6 +9248,78 @@
"node": ">=4"
}
},
+ "node_modules/mini-css-extract-plugin": {
+ "version": "2.7.7",
+ "resolved": "https://registry.npmjs.org/mini-css-extract-plugin/-/mini-css-extract-plugin-2.7.7.tgz",
+ "integrity": "sha512-+0n11YGyRavUR3IlaOzJ0/4Il1avMvJ1VJfhWfCn24ITQXhRr1gghbhhrda6tgtNcpZaWKdSuwKq20Jb7fnlyw==",
+ "dev": true,
+ "dependencies": {
+ "schema-utils": "^4.0.0"
+ },
+ "engines": {
+ "node": ">= 12.13.0"
+ },
+ "funding": {
+ "type": "opencollective",
+ "url": "https://opencollective.com/webpack"
+ },
+ "peerDependencies": {
+ "webpack": "^5.0.0"
+ }
+ },
+ "node_modules/mini-css-extract-plugin/node_modules/ajv": {
+ "version": "8.12.0",
+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.12.0.tgz",
+ "integrity": "sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==",
+ "dev": true,
+ "dependencies": {
+ "fast-deep-equal": "^3.1.1",
+ "json-schema-traverse": "^1.0.0",
+ "require-from-string": "^2.0.2",
+ "uri-js": "^4.2.2"
+ },
+ "funding": {
+ "type": "github",
+ "url": "https://github.com/sponsors/epoberezkin"
+ }
+ },
+ "node_modules/mini-css-extract-plugin/node_modules/ajv-keywords": {
+ "version": "5.1.0",
+ "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-5.1.0.tgz",
+ "integrity": "sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw==",
+ "dev": true,
+ "dependencies": {
+ "fast-deep-equal": "^3.1.3"
+ },
+ "peerDependencies": {
+ "ajv": "^8.8.2"
+ }
+ },
+ "node_modules/mini-css-extract-plugin/node_modules/json-schema-traverse": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",
+ "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==",
+ "dev": true
+ },
+ "node_modules/mini-css-extract-plugin/node_modules/schema-utils": {
+ "version": "4.2.0",
+ "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-4.2.0.tgz",
+ "integrity": "sha512-L0jRsrPpjdckP3oPug3/VxNKt2trR8TcabrM6FOAAlvC/9Phcmm+cuAgTlxBqdBR1WJx7Naj9WHw+aOmheSVbw==",
+ "dev": true,
+ "dependencies": {
+ "@types/json-schema": "^7.0.9",
+ "ajv": "^8.9.0",
+ "ajv-formats": "^2.1.1",
+ "ajv-keywords": "^5.1.0"
+ },
+ "engines": {
+ "node": ">= 12.13.0"
+ },
+ "funding": {
+ "type": "opencollective",
+ "url": "https://opencollective.com/webpack"
+ }
+ },
"node_modules/minimalistic-assert": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz",
@@ -10429,6 +10682,72 @@
"url": "https://opencollective.com/postcss/"
}
},
+ "node_modules/postcss-loader": {
+ "version": "7.3.4",
+ "resolved": "https://registry.npmjs.org/postcss-loader/-/postcss-loader-7.3.4.tgz",
+ "integrity": "sha512-iW5WTTBSC5BfsBJ9daFMPVrLT36MrNiC6fqOZTTaHjBNX6Pfd5p+hSBqe/fEeNd7pc13QiAyGt7VdGMw4eRC4A==",
+ "dev": true,
+ "dependencies": {
+ "cosmiconfig": "^8.3.5",
+ "jiti": "^1.20.0",
+ "semver": "^7.5.4"
+ },
+ "engines": {
+ "node": ">= 14.15.0"
+ },
+ "funding": {
+ "type": "opencollective",
+ "url": "https://opencollective.com/webpack"
+ },
+ "peerDependencies": {
+ "postcss": "^7.0.0 || ^8.0.1",
+ "webpack": "^5.0.0"
+ }
+ },
+ "node_modules/postcss-loader/node_modules/argparse": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz",
+ "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==",
+ "dev": true
+ },
+ "node_modules/postcss-loader/node_modules/cosmiconfig": {
+ "version": "8.3.6",
+ "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.3.6.tgz",
+ "integrity": "sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==",
+ "dev": true,
+ "dependencies": {
+ "import-fresh": "^3.3.0",
+ "js-yaml": "^4.1.0",
+ "parse-json": "^5.2.0",
+ "path-type": "^4.0.0"
+ },
+ "engines": {
+ "node": ">=14"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/d-fischer"
+ },
+ "peerDependencies": {
+ "typescript": ">=4.9.5"
+ },
+ "peerDependenciesMeta": {
+ "typescript": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/postcss-loader/node_modules/js-yaml": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz",
+ "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==",
+ "dev": true,
+ "dependencies": {
+ "argparse": "^2.0.1"
+ },
+ "bin": {
+ "js-yaml": "bin/js-yaml.js"
+ }
+ },
"node_modules/postcss-media-query-parser": {
"version": "0.2.3",
"resolved": "https://registry.npmjs.org/postcss-media-query-parser/-/postcss-media-query-parser-0.2.3.tgz",
@@ -11701,9 +12020,9 @@
}
},
"node_modules/sass-loader": {
- "version": "13.3.2",
- "resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-13.3.2.tgz",
- "integrity": "sha512-CQbKl57kdEv+KDLquhC+gE3pXt74LEAzm+tzywcA0/aHZuub8wTErbjAoNI57rPUWRYRNC5WUnNl8eGJNbDdwg==",
+ "version": "13.3.3",
+ "resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-13.3.3.tgz",
+ "integrity": "sha512-mt5YN2F1MOZr3d/wBRcZxeFgwgkH44wVc2zohO2YF6JiOMkiXe4BYRZpSu2sO1g71mo/j16txzUhsKZlqjVGzA==",
"dev": true,
"dependencies": {
"neo-async": "^2.6.2"
@@ -13248,9 +13567,9 @@
}
},
"node_modules/terser": {
- "version": "5.19.4",
- "resolved": "https://registry.npmjs.org/terser/-/terser-5.19.4.tgz",
- "integrity": "sha512-6p1DjHeuluwxDXcuT9VR8p64klWJKo1ILiy19s6C9+0Bh2+NWTX6nD9EPppiER4ICkHDVB1RkVpin/YW2nQn/g==",
+ "version": "5.27.0",
+ "resolved": "https://registry.npmjs.org/terser/-/terser-5.27.0.tgz",
+ "integrity": "sha512-bi1HRwVRskAjheeYl291n3JC4GgO/Ty4z1nVs5AAsmonJulGxpSektecnNedrwK9C7vpvVtcX3cw00VSLt7U2A==",
"dependencies": {
"@jridgewell/source-map": "^0.3.3",
"acorn": "^8.8.2",
@@ -13265,15 +13584,15 @@
}
},
"node_modules/terser-webpack-plugin": {
- "version": "5.3.9",
- "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.9.tgz",
- "integrity": "sha512-ZuXsqE07EcggTWQjXUj+Aot/OMcD0bMKGgF63f7UxYcu5/AJF53aIpK1YoP5xR9l6s/Hy2b+t1AM0bLNPRuhwA==",
+ "version": "5.3.10",
+ "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz",
+ "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==",
"dependencies": {
- "@jridgewell/trace-mapping": "^0.3.17",
+ "@jridgewell/trace-mapping": "^0.3.20",
"jest-worker": "^27.4.5",
"schema-utils": "^3.1.1",
"serialize-javascript": "^6.0.1",
- "terser": "^5.16.8"
+ "terser": "^5.26.0"
},
"engines": {
"node": ">= 10.13.0"
@@ -17087,9 +17406,9 @@
"integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg=="
},
"@jridgewell/trace-mapping": {
- "version": "0.3.19",
- "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.19.tgz",
- "integrity": "sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw==",
+ "version": "0.3.21",
+ "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.21.tgz",
+ "integrity": "sha512-SRfKmRe1KvYnxjEMtxEr+J4HIeMX5YBg/qhRHpxEIGjhX1rshcHlnFUE9K0GazhVKWM7B+nARSkV8LuvJdJ5/g==",
"requires": {
"@jridgewell/resolve-uri": "^3.1.0",
"@jridgewell/sourcemap-codec": "^1.4.14"
@@ -17721,6 +18040,35 @@
"integrity": "sha512-DCRfO/4nQ+89p/RK43i8Ezd41EqdGIU4ld7nGF8OQ14oc/we5rEntLCUa7+jrn3nn83BosfwZA0wb4pon2o8iQ==",
"requires": {}
},
+ "ajv-formats": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-2.1.1.tgz",
+ "integrity": "sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==",
+ "dev": true,
+ "requires": {
+ "ajv": "^8.0.0"
+ },
+ "dependencies": {
+ "ajv": {
+ "version": "8.12.0",
+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.12.0.tgz",
+ "integrity": "sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==",
+ "dev": true,
+ "requires": {
+ "fast-deep-equal": "^3.1.1",
+ "json-schema-traverse": "^1.0.0",
+ "require-from-string": "^2.0.2",
+ "uri-js": "^4.2.2"
+ }
+ },
+ "json-schema-traverse": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",
+ "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==",
+ "dev": true
+ }
+ }
+ },
"ajv-keywords": {
"version": "3.5.2",
"resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.2.tgz",
@@ -18968,6 +19316,95 @@
"resolved": "https://registry.npmjs.org/copy-descriptor/-/copy-descriptor-0.1.1.tgz",
"integrity": "sha512-XgZ0pFcakEUlbwQEVNg3+QAis1FyTL3Qel9FYy8pSkQqoG3PNoT0bOCQtOXcOkur21r2Eq2kI+IE+gsmAEVlYw=="
},
+ "copy-webpack-plugin": {
+ "version": "11.0.0",
+ "resolved": "https://registry.npmjs.org/copy-webpack-plugin/-/copy-webpack-plugin-11.0.0.tgz",
+ "integrity": "sha512-fX2MWpamkW0hZxMEg0+mYnA40LTosOSa5TqZ9GYIBzyJa9C3QUaMPSE2xAi/buNr8u89SfD9wHSQVBzrRa/SOQ==",
+ "dev": true,
+ "requires": {
+ "fast-glob": "^3.2.11",
+ "glob-parent": "^6.0.1",
+ "globby": "^13.1.1",
+ "normalize-path": "^3.0.0",
+ "schema-utils": "^4.0.0",
+ "serialize-javascript": "^6.0.0"
+ },
+ "dependencies": {
+ "ajv": {
+ "version": "8.12.0",
+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.12.0.tgz",
+ "integrity": "sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==",
+ "dev": true,
+ "requires": {
+ "fast-deep-equal": "^3.1.1",
+ "json-schema-traverse": "^1.0.0",
+ "require-from-string": "^2.0.2",
+ "uri-js": "^4.2.2"
+ }
+ },
+ "ajv-keywords": {
+ "version": "5.1.0",
+ "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-5.1.0.tgz",
+ "integrity": "sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw==",
+ "dev": true,
+ "requires": {
+ "fast-deep-equal": "^3.1.3"
+ }
+ },
+ "glob-parent": {
+ "version": "6.0.2",
+ "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz",
+ "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==",
+ "dev": true,
+ "requires": {
+ "is-glob": "^4.0.3"
+ }
+ },
+ "globby": {
+ "version": "13.2.2",
+ "resolved": "https://registry.npmjs.org/globby/-/globby-13.2.2.tgz",
+ "integrity": "sha512-Y1zNGV+pzQdh7H39l9zgB4PJqjRNqydvdYCDG4HFXM4XuvSaQQlEc91IU1yALL8gUTDomgBAfz3XJdmUS+oo0w==",
+ "dev": true,
+ "requires": {
+ "dir-glob": "^3.0.1",
+ "fast-glob": "^3.3.0",
+ "ignore": "^5.2.4",
+ "merge2": "^1.4.1",
+ "slash": "^4.0.0"
+ }
+ },
+ "ignore": {
+ "version": "5.3.0",
+ "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.0.tgz",
+ "integrity": "sha512-g7dmpshy+gD7mh88OC9NwSGTKoc3kyLAZQRU1mt53Aw/vnvfXnbC+F/7F7QoYVKbV+KNvJx8wArewKy1vXMtlg==",
+ "dev": true
+ },
+ "json-schema-traverse": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",
+ "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==",
+ "dev": true
+ },
+ "schema-utils": {
+ "version": "4.2.0",
+ "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-4.2.0.tgz",
+ "integrity": "sha512-L0jRsrPpjdckP3oPug3/VxNKt2trR8TcabrM6FOAAlvC/9Phcmm+cuAgTlxBqdBR1WJx7Naj9WHw+aOmheSVbw==",
+ "dev": true,
+ "requires": {
+ "@types/json-schema": "^7.0.9",
+ "ajv": "^8.9.0",
+ "ajv-formats": "^2.1.1",
+ "ajv-keywords": "^5.1.0"
+ }
+ },
+ "slash": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/slash/-/slash-4.0.0.tgz",
+ "integrity": "sha512-3dOsAHXXUkQTpOYcoAxLIorMTp4gIQr5IW3iVb7A7lFIp0VHhnynm9izx6TssdrIcVIESAlVjtnO2K8bg+Coew==",
+ "dev": true
+ }
+ }
+ },
"core-js-compat": {
"version": "3.33.1",
"resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.33.1.tgz",
@@ -22009,6 +22446,12 @@
"supports-color": "^8.0.0"
}
},
+ "jiti": {
+ "version": "1.21.0",
+ "resolved": "https://registry.npmjs.org/jiti/-/jiti-1.21.0.tgz",
+ "integrity": "sha512-gFqAIbuKyyso/3G2qhiO2OM6shY6EPP/R0+mkDbyspxKazh8BXDC5FiFsUjlczgdNz/vfra0da2y+aHrusLG/Q==",
+ "dev": true
+ },
"joi": {
"version": "17.11.0",
"resolved": "https://registry.npmjs.org/joi/-/joi-17.11.0.tgz",
@@ -22524,6 +22967,56 @@
"resolved": "https://registry.npmjs.org/min-indent/-/min-indent-1.0.1.tgz",
"integrity": "sha512-I9jwMn07Sy/IwOj3zVkVik2JTvgpaykDZEigL6Rx6N9LbMywwUSMtxET+7lVoDLLd3O3IXwJwvuuns8UB/HeAg=="
},
+ "mini-css-extract-plugin": {
+ "version": "2.7.7",
+ "resolved": "https://registry.npmjs.org/mini-css-extract-plugin/-/mini-css-extract-plugin-2.7.7.tgz",
+ "integrity": "sha512-+0n11YGyRavUR3IlaOzJ0/4Il1avMvJ1VJfhWfCn24ITQXhRr1gghbhhrda6tgtNcpZaWKdSuwKq20Jb7fnlyw==",
+ "dev": true,
+ "requires": {
+ "schema-utils": "^4.0.0"
+ },
+ "dependencies": {
+ "ajv": {
+ "version": "8.12.0",
+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.12.0.tgz",
+ "integrity": "sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==",
+ "dev": true,
+ "requires": {
+ "fast-deep-equal": "^3.1.1",
+ "json-schema-traverse": "^1.0.0",
+ "require-from-string": "^2.0.2",
+ "uri-js": "^4.2.2"
+ }
+ },
+ "ajv-keywords": {
+ "version": "5.1.0",
+ "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-5.1.0.tgz",
+ "integrity": "sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw==",
+ "dev": true,
+ "requires": {
+ "fast-deep-equal": "^3.1.3"
+ }
+ },
+ "json-schema-traverse": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",
+ "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==",
+ "dev": true
+ },
+ "schema-utils": {
+ "version": "4.2.0",
+ "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-4.2.0.tgz",
+ "integrity": "sha512-L0jRsrPpjdckP3oPug3/VxNKt2trR8TcabrM6FOAAlvC/9Phcmm+cuAgTlxBqdBR1WJx7Naj9WHw+aOmheSVbw==",
+ "dev": true,
+ "requires": {
+ "@types/json-schema": "^7.0.9",
+ "ajv": "^8.9.0",
+ "ajv-formats": "^2.1.1",
+ "ajv-keywords": "^5.1.0"
+ }
+ }
+ }
+ },
"minimalistic-assert": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz",
@@ -23576,6 +24069,46 @@
}
}
},
+ "postcss-loader": {
+ "version": "7.3.4",
+ "resolved": "https://registry.npmjs.org/postcss-loader/-/postcss-loader-7.3.4.tgz",
+ "integrity": "sha512-iW5WTTBSC5BfsBJ9daFMPVrLT36MrNiC6fqOZTTaHjBNX6Pfd5p+hSBqe/fEeNd7pc13QiAyGt7VdGMw4eRC4A==",
+ "dev": true,
+ "requires": {
+ "cosmiconfig": "^8.3.5",
+ "jiti": "^1.20.0",
+ "semver": "^7.5.4"
+ },
+ "dependencies": {
+ "argparse": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz",
+ "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==",
+ "dev": true
+ },
+ "cosmiconfig": {
+ "version": "8.3.6",
+ "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.3.6.tgz",
+ "integrity": "sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==",
+ "dev": true,
+ "requires": {
+ "import-fresh": "^3.3.0",
+ "js-yaml": "^4.1.0",
+ "parse-json": "^5.2.0",
+ "path-type": "^4.0.0"
+ }
+ },
+ "js-yaml": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz",
+ "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==",
+ "dev": true,
+ "requires": {
+ "argparse": "^2.0.1"
+ }
+ }
+ }
+ },
"postcss-media-query-parser": {
"version": "0.2.3",
"resolved": "https://registry.npmjs.org/postcss-media-query-parser/-/postcss-media-query-parser-0.2.3.tgz",
@@ -24531,9 +25064,9 @@
}
},
"sass-loader": {
- "version": "13.3.2",
- "resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-13.3.2.tgz",
- "integrity": "sha512-CQbKl57kdEv+KDLquhC+gE3pXt74LEAzm+tzywcA0/aHZuub8wTErbjAoNI57rPUWRYRNC5WUnNl8eGJNbDdwg==",
+ "version": "13.3.3",
+ "resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-13.3.3.tgz",
+ "integrity": "sha512-mt5YN2F1MOZr3d/wBRcZxeFgwgkH44wVc2zohO2YF6JiOMkiXe4BYRZpSu2sO1g71mo/j16txzUhsKZlqjVGzA==",
"dev": true,
"requires": {
"neo-async": "^2.6.2"
@@ -25755,9 +26288,9 @@
}
},
"terser": {
- "version": "5.19.4",
- "resolved": "https://registry.npmjs.org/terser/-/terser-5.19.4.tgz",
- "integrity": "sha512-6p1DjHeuluwxDXcuT9VR8p64klWJKo1ILiy19s6C9+0Bh2+NWTX6nD9EPppiER4ICkHDVB1RkVpin/YW2nQn/g==",
+ "version": "5.27.0",
+ "resolved": "https://registry.npmjs.org/terser/-/terser-5.27.0.tgz",
+ "integrity": "sha512-bi1HRwVRskAjheeYl291n3JC4GgO/Ty4z1nVs5AAsmonJulGxpSektecnNedrwK9C7vpvVtcX3cw00VSLt7U2A==",
"requires": {
"@jridgewell/source-map": "^0.3.3",
"acorn": "^8.8.2",
@@ -25766,15 +26299,15 @@
}
},
"terser-webpack-plugin": {
- "version": "5.3.9",
- "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.9.tgz",
- "integrity": "sha512-ZuXsqE07EcggTWQjXUj+Aot/OMcD0bMKGgF63f7UxYcu5/AJF53aIpK1YoP5xR9l6s/Hy2b+t1AM0bLNPRuhwA==",
+ "version": "5.3.10",
+ "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz",
+ "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==",
"requires": {
- "@jridgewell/trace-mapping": "^0.3.17",
+ "@jridgewell/trace-mapping": "^0.3.20",
"jest-worker": "^27.4.5",
"schema-utils": "^3.1.1",
"serialize-javascript": "^6.0.1",
- "terser": "^5.16.8"
+ "terser": "^5.26.0"
}
},
"test-exclude": {
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/package.json b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/package.json
index 0f65abe6..3c333a7a 100644
--- a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/package.json
+++ b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/package.json
@@ -9,11 +9,15 @@
"govuk-frontend": "^4.7.0"
},
"devDependencies": {
- "css-loader": "^6.7.1",
+ "css-loader": "^6.7.4",
+ "copy-webpack-plugin": "^11.0.0",
+ "mini-css-extract-plugin": "^2.7.6",
"node-sass": "^9.0.0",
+ "postcss-loader": "^7.3.4",
"sass": "^1.67.0",
- "sass-loader": "^13.3.2",
- "style-loader": "^3.3.1",
+ "sass-loader": "^13.3.3",
+ "style-loader": "^3.3.3",
+ "terser-webpack-plugin": "^5.3.10",
"webpack": "^5.88.2",
"webpack-cli": "^4.9.2"
},
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/webpack.config.js b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/webpack.config.js
index cea59591..c7b5c728 100644
--- a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/webpack.config.js
+++ b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/webpack.config.js
@@ -1,25 +1,127 @@
-const path = require("path");
+const { dirname, join } = require('path')
-module.exports = {
- entry: {
- site: "./wwwroot/js/site.js",
+const CopyPlugin = require('copy-webpack-plugin')
+const MiniCssExtractPlugin = require('mini-css-extract-plugin')
+const TerserPlugin = require('terser-webpack-plugin')
+
+// Module resolution
+const frontendPath = dirname(require.resolve('govuk-frontend/package.json'))
+
+// Build paths
+const srcPath = join(__dirname, '')
+const destPath = join(__dirname, 'wwwroot/dist')
+
+/**
+ * @type {() => import('webpack-dev-server').WebpackConfiguration}
+ */
+module.exports = ({ WEBPACK_SERVE }, { mode }) => ({
+ devServer: {
+ watchFiles: {
+ paths: ['**/*.html']
+ }
},
- output: {
- filename: "[name].entry.js",
- path: path.resolve(__dirname, ".", "wwwroot", "dist"),
+
+ devtool: WEBPACK_SERVE ? 'inline-source-map' : 'source-map',
+
+ entry: {
+ site: [
+ join(srcPath, 'wwwroot/js/site.js'),
+ join(srcPath, 'wwwroot/css/site.scss')
+ ]
},
- devtool: "source-map",
- mode: "development",
+
module: {
rules: [
{
- test: /\.(scss|css)$/,
- use: ["style-loader", "css-loader", "sass-loader"],
+ test: /\.(cjs|js|mjs)$/,
+ exclude: /node_modules/,
+ use: {
+ loader: 'babel-loader',
+ options: {
+ rootMode: 'upward'
+ }
+ }
},
{
- test: /\.(eot|woff(2)?|ttf|otf|svg)$/i,
- type: "asset",
+ test: /\.scss$/,
+ use: [
+ MiniCssExtractPlugin.loader,
+ {
+ loader: 'css-loader',
+ options: {
+ // Allow sass-loader to process CSS @import first
+ // before we use css-loader to extract `url()` etc
+ importLoaders: 2
+ }
+ },
+ 'postcss-loader',
+ {
+ loader: 'sass-loader',
+ options: {
+ sassOptions: {
+ includePaths: [`${frontendPath}/src`],
+ quietDeps: true
+ }
+ }
+ }
+ ]
},
- ],
+ {
+ test: /\.(woff|woff2)$/,
+ type: 'asset/resource',
+ generator: {
+ filename: 'assets/fonts/[name][ext]'
+ }
+ },
+ {
+ test: /\.(png|svg)$/,
+ type: 'asset/resource',
+ generator: {
+ filename: 'assets/images/[name][ext]'
+ }
+ }
+ ]
},
-};
+
+ optimization: {
+ minimize: mode === 'production',
+ minimizer: [
+ new TerserPlugin({
+ extractComments: true,
+ terserOptions: {
+ format: { comments: false },
+
+ // Compatibility workarounds
+ safari10: true
+ }
+ })
+ ]
+ },
+
+ output: {
+ clean: true,
+ filename: 'js/[name].min.js',
+ iife: true,
+ path: destPath,
+ publicPath: '/'
+ },
+
+ plugins: [
+ new MiniCssExtractPlugin({
+ filename: 'css/[name].min.css'
+ })
+ ],
+
+ resolve: {
+ alias: {
+ '/assets/': join(frontendPath, './src/govuk/assets/')
+ }
+ },
+
+ stats: {
+ preset: 'minimal',
+ errorDetails: true
+ },
+
+ target: ['web', 'es2015']
+})
\ No newline at end of file
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/wwwroot/css/site.scss b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/wwwroot/css/site.scss
index 8f238865..f8333d26 100644
--- a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/wwwroot/css/site.scss
+++ b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/wwwroot/css/site.scss
@@ -37,3 +37,94 @@ tr {
font-family: BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif !important;
}
+
+// Task list pattern
+// TODO: Update to govuk-frontend v5 to incorporate the new task list pattern
+// https://github.com/alphagov/govuk-prototype-kit/blob/main/lib/assets/sass/patterns/_task-list.scss
+
+.app-task-list {
+ list-style-type: none;
+ padding-left: 0;
+ margin-top: 0;
+ margin-bottom: 0;
+ @include govuk-media-query($from: tablet) {
+ min-width: 550px;
+ }
+}
+
+.app-task-list__section {
+ display: table;
+ @include govuk-font($size:24, $weight: bold);
+}
+
+.app-task-list__section-number {
+ display: table-cell;
+
+ @include govuk-media-query($from: tablet) {
+ min-width: govuk-spacing(6);
+ padding-right: 0;
+ }
+}
+
+.app-task-list__items {
+ @include govuk-font($size: 19);
+ @include govuk-responsive-margin(9, "bottom");
+ list-style: none;
+ padding-left: 0;
+ @include govuk-media-query($from: tablet) {
+ padding-left: govuk-spacing(6);
+ }
+}
+
+.app-task-list__item {
+ border-bottom: 1px solid $govuk-border-colour;
+ margin-bottom: 0 !important;
+ padding-top: govuk-spacing(2);
+ padding-bottom: govuk-spacing(2);
+ @include govuk-clearfix;
+}
+
+.app-task-list__item:first-child {
+ border-top: 1px solid $govuk-border-colour;
+}
+
+.app-task-list__task-name {
+ display: block;
+ @include govuk-media-query($from: 450px) {
+ float: left;
+ }
+}
+
+// The `app-task-list__task-completed` class was previously used on the task
+// list for the completed tag (changed in 86c90ec) – it's still included here to
+// avoid breaking task lists in existing prototypes.
+.app-task-list__tag,
+.app-task-list__task-completed {
+ margin-top: govuk-spacing(2);
+ margin-bottom: govuk-spacing(1);
+
+ @include govuk-media-query($from: 450px) {
+ float: right;
+ margin-top: 0;
+ margin-bottom: 0;
+ }
+}
+
+
+// Custom "three-column" task list
+// Specific to the Service Assessment Service, where the value is displayed within the centre column
+
+.app-task-list__item .app-task-list__task-name {
+ width: 30%;
+ display: inline-block
+}
+
+.app-task-list__item .app-task-list__task-value {
+ display: inline-block;
+ width: 49%
+}
+
+.app-task-list__item .app-task-list__task-tag {
+ display: inline-block;
+ width: 20%
+}
\ No newline at end of file
diff --git a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/wwwroot/js/site.js b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/wwwroot/js/site.js
index 9e1778af..bedd6374 100644
--- a/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/wwwroot/js/site.js
+++ b/src/ServiceAssessmentService/ServiceAssessmentService.WebApp/wwwroot/js/site.js
@@ -1,5 +1,6 @@
-// Custom CSS imports
-import "../css/site.scss";
-// Custom JS imports
-import "/node_modules/dfe-frontend-alpha/dist/dfefrontend.js";
-console.log("The 'site' bundle has been loaded!");
+// Custom JS imports
+import "../../node_modules/dfe-frontend-alpha/dist/dfefrontend.js";
+
+import { initAll } from 'govuk-frontend'
+initAll();
+