Skip to content

Commit ddd839d

Browse files
Migrate to Sass modules
1 parent 04ed3b4 commit ddd839d

File tree

8 files changed

+22
-8
lines changed

8 files changed

+22
-8
lines changed

manage_breast_screening/assets/sass/components/_button.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
@use "../vendor/nhsuk-frontend/base" as *;
2+
13
.app-button--link {
24
@include nhsuk-link-style-default;
35

manage_breast_screening/assets/sass/components/_count.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
@use "../vendor/nhsuk-frontend/base" as *;
2+
13
.app-count {
24
@include nhsuk-font-size(16);
35

manage_breast_screening/assets/sass/components/_secondary-navigation.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
@use "../vendor/nhsuk-frontend/base" as *;
2+
13
/* FIXME: taken from prototype */
24
$govuk-spacing1: 5px;
35
$govuk-spacing2: 10px;

manage_breast_screening/assets/sass/components/_special-appointment-banner.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
@use "../vendor/nhsuk-frontend/base" as *;
2+
13
.app-special-appointment-banner__action {
24
text-align: right;
35
@include nhsuk-font-size(19);

manage_breast_screening/assets/sass/main.scss

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
1-
// Import NHS.UK frontend library
2-
@import "nhsuk-frontend/dist/nhsuk";
1+
// NHS.UK frontend library
2+
@use "vendor/nhsuk-frontend/base" as *;
3+
@forward "vendor/nhsuk-frontend";
34

45
// Components that are not in the NHS.UK frontend library
5-
@import "components/button";
6-
@import "components/count";
7-
@import "components/appointment-status";
8-
@import "components/secondary-navigation";
9-
@import "components/special-appointment-banner";
6+
@forward "components/button";
7+
@forward "components/count";
8+
@forward "components/appointment-status";
9+
@forward "components/secondary-navigation";
10+
@forward "components/special-appointment-banner";
1011

1112
h1 {
1213
@extend %nhsuk-heading-l;
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
@forward "nhsuk-frontend/dist/nhsuk/core/settings";
2+
@forward "nhsuk-frontend/dist/nhsuk/core/tools";
3+
@forward "nhsuk-frontend/dist/nhsuk/core/helpers";
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
@use "base";
2+
@forward "nhsuk-frontend/dist/nhsuk";

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
],
77
"scripts": {
88
"compile": "concurrently npm:compile:js npm:compile:css --group --prefix none",
9-
"compile:css": "sass --color --quiet-deps --silence-deprecation=import --load-path=. --load-path=node_modules manage_breast_screening/assets/sass:manage_breast_screening/assets/compiled/css",
9+
"compile:css": "sass --color --quiet-deps --load-path=node_modules manage_breast_screening/assets/sass:manage_breast_screening/assets/compiled/css",
1010
"compile:css:watch": "npm run compile:css -- --watch",
1111
"compile:js": "rollup -c rollup.config.js --sourcemap",
1212
"compile:js:watch": "npm run compile:js -- --watch",

0 commit comments

Comments
 (0)