diff --git a/.gitignore b/.gitignore index f267d1ba6a..a94eba5847 100644 --- a/.gitignore +++ b/.gitignore @@ -15,6 +15,10 @@ backstop_data/bitmaps_test/ backstop_data/html_report/ backstop.config-for-docker.json +# Generated from lighthouse tests +.lighthouseci/ +lighthouse/urls.json + # npm package folders /components/ /page-templates/ diff --git a/README.md b/README.md index 00a71a3f54..5be9bcc5ac 100644 --- a/README.md +++ b/README.md @@ -112,7 +112,7 @@ It is sometimes useful to adjust the following settings when writing tests or di ## Testing - Visual regression tests -This project uses [Backstop JS](https://github.com/garris/BackstopJS) for visual regression testing. The tests run in Chrome headless using Pupeteer inside docker and run in three viewports; 1920 (desktop), 768 (tablet) and 375 (mobile). Reference images are stored in Git LFS and any approved changes will automatically be stored in Git LFS when pushed to the repository. +This project uses [Backstop JS](https://github.com/garris/BackstopJS) for visual regression testing. The tests run in Chrome headless using Puppeteer inside docker and run in three viewports; 1920 (desktop), 768 (tablet) and 375 (mobile). Reference images are stored in Git LFS and any approved changes will automatically be stored in Git LFS when pushed to the repository. The visual tests will run automatically on pull requests and the result will be available in the Github Action logs. If the tests fail, the process for viewing the failures and approving changes will need to be handled locally using the following workflow and commands. diff --git a/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_0_desktop.png b/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_0_desktop.png index e1f1b1df74..6a1cbc60e7 100644 --- a/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_0_desktop.png +++ b/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_0_desktop.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bb13667ddddf83ddda3c6386854e6d69e2f7c7fea3a8a32120af5ed95ed450df -size 16478 +oid sha256:a80837903241b6c9c9046cb9734b16944c992969e90625a964320f0f473d7ee3 +size 16714 diff --git a/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_1_tablet.png b/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_1_tablet.png index cac1c01469..cef50594ff 100644 --- a/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_1_tablet.png +++ b/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_1_tablet.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ead2dab152a3bbdd2af28b6465d62ac4553dc4721e3c2e48c260d7b874f671c6 -size 11399 +oid sha256:ee9c3aedb9fc7ecbd54df53141be63e18085387efa1396b2b2cb7ba8f5ac6bf4 +size 11625 diff --git a/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_2_mobile.png b/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_2_mobile.png index df759651e7..875088032e 100644 --- a/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_2_mobile.png +++ b/backstop_data/bitmaps_reference/ds-vr-test__components_list_example-summary-list_0_document_2_mobile.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dad0ab15906634fa5fd940c8c1cc8b85d184f84db30d6c27039870900815bf4e -size 8326 +oid sha256:13ec35b4dd6ee7546d0671f19b1e48b6e8089218f2f8c0e6cca3acdf292e8f95 +size 8534 diff --git a/src/components/list/_list.scss b/src/components/list/_list.scss index a55ca32eb3..9804928232 100644 --- a/src/components/list/_list.scss +++ b/src/components/list/_list.scss @@ -109,8 +109,10 @@ } .ons-list__prefix, .ons-list__suffix { + @extend .ons-u-m-no; &--icon-check .ons-icon { fill: var(--ons-color-leaf-green) !important; + @extend .ons-u-mr-s; } } } diff --git a/src/components/list/example-summary-list.njk b/src/components/list/example-summary-list.njk index 37abcf2290..8d2824d22f 100644 --- a/src/components/list/example-summary-list.njk +++ b/src/components/list/example-summary-list.njk @@ -1,10 +1,12 @@ {% from "components/list/_macro.njk" import onsList %} {{ onsList({ + "iconPosition": "before", "variants": "summary", "itemsList": [ { - "text": 'birth certificate' + "text": 'birth certificate', + "iconType": "check" }, { "text": 'national insurance number'