From 20c6de5d562b982b573fa52932fb0d9ed38457c3 Mon Sep 17 00:00:00 2001 From: sarahmwong Date: Thu, 19 Dec 2024 15:15:06 +0000 Subject: [PATCH] update css file name, attach dependency and update contributing guidelines for css changes --- .github/CONTRIBUTING.md | 8 +++++--- R/attachDependency.R | 2 +- ...uk-frontend-norem.css => govuk-frontend-5.7.1.min.css} | 0 3 files changed, 6 insertions(+), 4 deletions(-) rename inst/www/css/{govuk-frontend-norem.css => govuk-frontend-5.7.1.min.css} (100%) diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index bd49531..2ba1dd3 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -30,11 +30,13 @@ Currently we take [static precompiled exports of the GOV.UK Frontend files](http 2. Download and unzip the ZIP folder, copying the assets (including fonts and images) into the `inst/www/` folder -3. Apply any changes from `css_changes.md` manually, to preserve previous edits +3. Update the CSS file name in `attachDependency.R` script -4. Test all the code functions as expected using `devtools::check()` +4. Apply any changes from `css_changes.md` manually, to preserve previous edits -5. Manually test the examples using `shinyGovstyle::run_example()`, ensuring the styling is as expected +5. Test all the code functions as expected using `devtools::check()` + +6. Manually test the examples using `shinyGovstyle::run_example()`, ensuring the styling is as expected If unsure on the styling and expected appearance, use the [GOV.UK Design System site](https://design-system.service.gov.uk/) to explore the components in more detail and official guidance for their use. diff --git a/R/attachDependency.R b/R/attachDependency.R index d9b00ea..0d38513 100644 --- a/R/attachDependency.R +++ b/R/attachDependency.R @@ -14,7 +14,7 @@ attachDependency <- function(tag, widget = NULL) { dep <- htmltools::htmlDependency( name = "stylecss", version = version, src = c(href="shinyGovstyle/css"), - stylesheet = "govuk-frontend-norem.css" + stylesheet = "govuk-frontend-5.7.1.min.css" ) if (!is.null(widget)) { diff --git a/inst/www/css/govuk-frontend-norem.css b/inst/www/css/govuk-frontend-5.7.1.min.css similarity index 100% rename from inst/www/css/govuk-frontend-norem.css rename to inst/www/css/govuk-frontend-5.7.1.min.css