Skip to content

Commit

Permalink
VACMS-2312: User guides content model part 2, and theming. (#2440)
Browse files Browse the repository at this point in the history
* VACMS-2438: 3 column layout paragraph type.

* VACMS-2438: List of links content block config.

* VACMS-2438: Enable two new content blocks on user guides.

* VACMS-2438: Update paragraph bundle descriptions.

* VACMS-2438: Update field widgets for 3 column layout.

* VACMS-2438: Behat tests for user guide paragraph types.

* VACMS-000: Fix layout padding.

* VACMS-2312: Twig and CSS to support user guide view.

* VACMS-000: Code comment for paragraphs.scss.

* VACMS-2312: Various minor typography updates.

* VACMS-2312: PHPCS should ignore user_guides.css.

* VACMS-2312: Fix typography regressions.

* VACMS-2312: Establish new view mode for paragraphs for user guides.

* VACMS-2312: Delete Three column layout paragraph type.

* VACMS-2312: Template updates for paragraphs.

* VACMS-2438: Lists of links paragraph type.

* VACMS-2312: User guides should use paragraph user guide display mode.

* VACMS-2312: Add node type as a page template suggestion.

* VACMS-2312: CSS for user guides.

* VACMS-2312: Add a Final link field ot list of links.

* VACMS-2438: Update behat tests.

* VACMS-2312: Update behat tests.

* VACMS-2312: Related user guides field template.

* VACMS-2312: Display related user guides field label.

* VACMS-2312: Max width of text and user guide CSS.

* VACMS-2438: Fix behat test.
  • Loading branch information
kevwalsh authored Jul 30, 2020
1 parent 10dc721 commit 123ddb1
Show file tree
Hide file tree
Showing 49 changed files with 1,131 additions and 60 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,7 @@
"find docroot/modules/custom docroot/themes -name '*.install' -print0 | xargs -0 -n1 php -l > /dev/null"
],
"va:test:cs": [
"phpcs --ignore=*.md,*.min.css,styles.css,wysiwyg.css,proofing.css,*/node_modules/*,*/simplesaml*/* --extensions=php,module,inc,install,profile,engine,theme,js,css --standard=./docroot/vendor/drupal/coder/coder_sniffer/Drupal/ruleset.xml docroot/modules/custom docroot/modules/contrib/workflow_assignments docroot/themes/custom --colors"
"phpcs --ignore=*.md,*.min.css,styles.css,wysiwyg.css,proofing.css,user_guides.css,*/node_modules/*,*/simplesaml*/* --extensions=php,module,inc,install,profile,engine,theme,js,css --standard=./docroot/vendor/drupal/coder/coder_sniffer/Drupal/ruleset.xml docroot/modules/custom docroot/modules/contrib/workflow_assignments docroot/themes/custom --colors"
],
"va:test:unit": "phpunit tests/phpunit --colors=always --exclude-group=disabled",
"va:cbf": "phpcbf --ignore=*.md,*.min.css,uswds.css,*/node_modules/*,*/simplesaml*/* --standard=./docroot/vendor/drupal/coder/coder_sniffer/Drupal/ruleset.xml docroot/modules/custom docroot/themes/custom --colors",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
uuid: cc44b26f-ddba-4489-a41a-ebf7e83376b7
langcode: en
status: true
dependencies:
config:
- field.field.paragraph.list_of_links.field_link
- field.field.paragraph.list_of_links.field_links
- field.field.paragraph.list_of_links.field_section_header
- paragraphs.paragraphs_type.list_of_links
module:
- linkit
id: paragraph.list_of_links.default
targetEntityType: paragraph
bundle: list_of_links
mode: default
content:
field_link:
weight: 2
settings:
placeholder_url: ''
placeholder_title: ''
linkit_profile: default
third_party_settings: { }
type: linkit
region: content
field_links:
weight: 1
settings:
placeholder_url: ''
placeholder_title: ''
linkit_profile: default
third_party_settings: { }
type: linkit
region: content
field_section_header:
weight: 0
settings:
size: 60
placeholder: ''
third_party_settings: { }
type: string_textfield
region: content
hidden:
created: true
status: true
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
uuid: dcd26a1e-1a88-4b94-a8da-40abec6a4da2
langcode: en
status: true
dependencies:
config:
- field.field.paragraph.lists_of_links.field_section_header
- field.field.paragraph.lists_of_links.field_va_paragraphs
- paragraphs.paragraphs_type.lists_of_links
module:
- paragraphs
id: paragraph.lists_of_links.default
targetEntityType: paragraph
bundle: lists_of_links
mode: default
content:
field_section_header:
weight: 0
settings:
size: 60
placeholder: ''
third_party_settings: { }
type: string_textfield
region: content
field_va_paragraphs:
weight: 1
settings:
title: 'List of links'
title_plural: 'Lists of links'
edit_mode: open
closed_mode: summary
autocollapse: none
closed_mode_threshold: 0
add_mode: button
form_display_mode: default
default_paragraph_type: list_of_links
features:
add_above: '0'
collapse_edit_all: '0'
duplicate: '0'
third_party_settings: { }
type: paragraphs
region: content
hidden:
created: true
status: true
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ content:
weight: 2
label: hidden
settings:
view_mode: default
view_mode: user_guides
link: ''
third_party_settings: { }
type: entity_reference_revisions_entity_view
Expand All @@ -40,7 +40,7 @@ content:
region: content
field_related_user_guides:
weight: 3
label: hidden
label: above
settings:
link: true
third_party_settings: { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,5 @@ content:
third_party_settings: { }
type: string
region: content
hidden: { }
hidden:
search_api_excerpt: true
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
uuid: 62d8e14b-5ae6-458d-906e-f9b4b4d4019b
langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.paragraph.user_guides
- field.field.paragraph.link_teaser.field_link
- field.field.paragraph.link_teaser.field_link_summary
- paragraphs.paragraphs_type.link_teaser
module:
- layout_builder
- link
third_party_settings:
layout_builder:
allow_custom: false
enabled: false
id: paragraph.link_teaser.user_guides
targetEntityType: paragraph
bundle: link_teaser
mode: user_guides
content:
field_link:
weight: 0
label: hidden
settings:
trim_length: 80
url_only: false
url_plain: false
rel: ''
target: ''
third_party_settings: { }
type: link
region: content
field_link_summary:
weight: 1
label: hidden
settings:
link_to_entity: false
third_party_settings: { }
type: string
region: content
hidden:
search_api_excerpt: true
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,5 @@ content:
third_party_settings: { }
type: entity_reference_revisions_entity_view
region: content
hidden: { }
hidden:
search_api_excerpt: true
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
uuid: c0c4b52a-6f9b-4ffb-9ddd-0145ae25b68f
langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.paragraph.user_guides
- field.field.paragraph.list_of_link_teasers.field_title
- field.field.paragraph.list_of_link_teasers.field_va_paragraphs
- paragraphs.paragraphs_type.list_of_link_teasers
module:
- entity_reference_revisions
- layout_builder
third_party_settings:
layout_builder:
allow_custom: false
enabled: false
id: paragraph.list_of_link_teasers.user_guides
targetEntityType: paragraph
bundle: list_of_link_teasers
mode: user_guides
content:
field_title:
weight: 0
label: hidden
settings:
link_to_entity: false
third_party_settings: { }
type: string
region: content
field_va_paragraphs:
weight: 1
label: hidden
settings:
view_mode: user_guides
link: ''
third_party_settings: { }
type: entity_reference_revisions_entity_view
region: content
hidden:
search_api_excerpt: true
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
uuid: bfc80983-5068-4c69-962b-62ba97e51888
langcode: en
status: true
dependencies:
config:
- field.field.paragraph.list_of_links.field_link
- field.field.paragraph.list_of_links.field_links
- field.field.paragraph.list_of_links.field_section_header
- paragraphs.paragraphs_type.list_of_links
module:
- link
id: paragraph.list_of_links.default
targetEntityType: paragraph
bundle: list_of_links
mode: default
content:
field_link:
weight: 3
label: hidden
settings:
trim_length: 80
url_only: false
url_plain: false
rel: ''
target: ''
third_party_settings: { }
type: link
region: content
field_links:
weight: 2
label: hidden
settings:
trim_length: 80
url_only: false
url_plain: false
rel: ''
target: ''
third_party_settings: { }
type: link
region: content
field_section_header:
weight: 0
label: hidden
settings:
link_to_entity: false
third_party_settings: { }
type: string
region: content
hidden:
search_api_excerpt: true
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
uuid: eedf5602-5332-4aea-9b72-69de665998ce
langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.paragraph.user_guides
- field.field.paragraph.list_of_links.field_link
- field.field.paragraph.list_of_links.field_links
- field.field.paragraph.list_of_links.field_section_header
- paragraphs.paragraphs_type.list_of_links
module:
- layout_builder
- link
third_party_settings:
layout_builder:
allow_custom: false
enabled: false
id: paragraph.list_of_links.user_guides
targetEntityType: paragraph
bundle: list_of_links
mode: user_guides
content:
field_link:
type: link
weight: 2
region: content
label: hidden
settings:
trim_length: 80
url_only: false
url_plain: false
rel: ''
target: ''
third_party_settings: { }
field_links:
weight: 1
label: hidden
settings:
trim_length: 80
url_only: false
url_plain: false
rel: ''
target: ''
third_party_settings: { }
type: link
region: content
field_section_header:
weight: 0
label: hidden
settings:
link_to_entity: false
third_party_settings: { }
type: string
region: content
hidden:
search_api_excerpt: true
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
uuid: 6533e579-a77c-4e2a-b46c-1ee8ec200c2e
langcode: en
status: true
dependencies:
config:
- field.field.paragraph.lists_of_links.field_section_header
- field.field.paragraph.lists_of_links.field_va_paragraphs
- paragraphs.paragraphs_type.lists_of_links
module:
- entity_reference_revisions
id: paragraph.lists_of_links.default
targetEntityType: paragraph
bundle: lists_of_links
mode: default
content:
field_section_header:
weight: 0
label: hidden
settings:
link_to_entity: false
third_party_settings: { }
type: string
region: content
field_va_paragraphs:
weight: 1
label: hidden
settings:
view_mode: default
link: ''
third_party_settings: { }
type: entity_reference_revisions_entity_view
region: content
hidden:
search_api_excerpt: true
Loading

1 comment on commit 123ddb1

@va-cms-bot
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❌ Test Failed: va/tests/accessibility
composer va:test:accessibility
> [email protected] install /var/www/cms/node_modules/phantomjs-prebuilt
> node install.js

PhantomJS not found on PATH
Downloading https://github.com/Medium/phantomjs/releases/download/v2.1.1/phantomjs-2.1.1-linux-x86_64.tar.bz2
Saving to /tmp/phantomjs/phantomjs-2.1.1-linux-x86_64.tar.bz2
Receiving...

Received 22866K total.
Extracting tar contents (via spawned process)
Removing /var/www/cms/node_modules/phantomjs-prebuilt/lib/phantom
Copying extracted folder /tmp/phantomjs/phantomjs-2.1.1-linux-x86_64.tar.bz2-extract-1596130191368/phantomjs-2.1.1-linux-x86_64 -> /var/www/cms/node_modules/phantomjs-prebuilt/lib/phantom
Writing location.js file
Done. Phantomjs binary available at /var/www/cms/node_modules/phantomjs-prebuilt/lib/phantom/bin/phantomjs

> [email protected] postinstall /var/www/cms/node_modules/core-js
> node scripts/postinstall || echo "ignore"

Thank you for using core-js ( https://github.com/zloirock/core-js ) for polyfilling JavaScript standard library!

The project needs your help! Please consider supporting of core-js on Open Collective or Patreon: 
> https://opencollective.com/core-js 
> https://www.patreon.com/zloirock 

Also, the author of core-js ( https://github.com/zloirock ) is looking for a good job -)

added 134 packages from 190 contributors and audited 134 packages in 13.159s
found 3 low severity vulnerabilities
  run `npm audit fix` to fix them, or `npm audit` for details

> [email protected] test /var/www/cms
> node ./tests/accessibility/aXeAccessibilityCheck.js

!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com 1
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/sections  = 0
[]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/page  = 2
[ { id: 'duplicate-id',
    impact: 'minor',
    tags: [ 'cat.parsing', 'wcag2a', 'wcag411' ],
    description: 'Ensures every id attribute value is unique',
    help: 'id attribute value must be unique',
    helpUrl:
     'https://dequeuniversity.com/rules/axe/3.3/duplicate-id?application=webdriverjs',
    nodes: [ [Object], [Object] ] },
  { id: 'label',
    impact: 'critical',
    tags:
     [ 'cat.forms',
       'wcag2a',
       'wcag332',
       'wcag131',
       'section508',
       'section508.22.n' ],
    description: 'Ensures every form element has a label',
    help: 'Form elements must have labels',
    helpUrl:
     'https://dequeuniversity.com/rules/axe/3.3/label?application=webdriverjs',
    nodes: [ [Object] ] } ]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/landing_page  = 0
[]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/documentation_page  = 1
[ { id: 'label',
    impact: 'critical',
    tags:
     [ 'cat.forms',
       'wcag2a',
       'wcag332',
       'wcag131',
       'section508',
       'section508.22.n' ],
    description: 'Ensures every form element has a label',
    help: 'Form elements must have labels',
    helpUrl:
     'https://dequeuniversity.com/rules/axe/3.3/label?application=webdriverjs',
    nodes: [ [Object] ] } ]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/event  = 0
[]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/health_care_local_facility  = 1
[ { id: 'label',
    impact: 'critical',
    tags:
     [ 'cat.forms',
       'wcag2a',
       'wcag332',
       'wcag131',
       'section508',
       'section508.22.n' ],
    description: 'Ensures every form element has a label',
    help: 'Form elements must have labels',
    helpUrl:
     'https://dequeuniversity.com/rules/axe/3.3/label?application=webdriverjs',
    nodes:
     [ [Object],
       [Object],
       [Object],
       [Object],
       [Object],
       [Object],
       [Object],
       [Object],
       [Object],
       [Object],
       [Object],
       [Object],
       [Object],
       [Object] ] } ]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/health_care_region_detail_page  = 2
[ { id: 'duplicate-id',
    impact: 'minor',
    tags: [ 'cat.parsing', 'wcag2a', 'wcag411' ],
    description: 'Ensures every id attribute value is unique',
    help: 'id attribute value must be unique',
    helpUrl:
     'https://dequeuniversity.com/rules/axe/3.3/duplicate-id?application=webdriverjs',
    nodes: [ [Object], [Object] ] },
  { id: 'label',
    impact: 'critical',
    tags:
     [ 'cat.forms',
       'wcag2a',
       'wcag332',
       'wcag131',
       'section508',
       'section508.22.n' ],
    description: 'Ensures every form element has a label',
    help: 'Form elements must have labels',
    helpUrl:
     'https://dequeuniversity.com/rules/axe/3.3/label?application=webdriverjs',
    nodes: [ [Object] ] } ]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/health_care_region_page  = 0
[]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/office  = 0
[]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/outreach_asset  = 0
[]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/person_profile  = 0
[]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/press_release  = 1
[ { id: 'aria-allowed-attr',
    impact: 'critical',
    tags: [ 'cat.aria', 'wcag2a', 'wcag412' ],
    description: 'Ensures ARIA attributes are allowed for an element\'s role',
    help: 'Elements must only use allowed ARIA attributes',
    helpUrl:
     'https://dequeuniversity.com/rules/axe/3.3/aria-allowed-attr?application=webdriverjs',
    nodes: [ [Object] ] } ]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/regional_health_care_service_des  = 0
[]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/news_story  = 0
[]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/node/add/support_service  = 0
[]
!!!  NUMBER OF NEW VIOLATIONS on http://internal-dsva-vagov-staging-cms-1188006.us-gov-west-1.elb.amazonaws.com/user  = 1
[ { id: 'color-contrast',
    impact: 'serious',
    tags: [ 'cat.color', 'wcag2aa', 'wcag143' ],
    description:
     'Ensures the contrast between foreground and background colors meets WCAG 2 AA contrast ratio thresholds',
    help: 'Elements must have sufficient color contrast',
    helpUrl:
     'https://dequeuniversity.com/rules/axe/3.3/color-contrast?application=webdriverjs',
    nodes:
     [ [Object], [Object], [Object], [Object], [Object], [Object] ] } ]
!!!  VIOLATION TYPES FOUND: 9 PROCESS EXITED WITH CODE 1  !!!
> npm install --only=production
> npm test
Thu, 30 Jul 2020 17:29:56 GMT axe-webdriverjs deprecated Error must be handled as the first argument of axe.analyze. See: #83 at tests/accessibility/aXeAccessibilityCheck.js:45:14
Thu, 30 Jul 2020 17:30:06 GMT axe-webdriverjs deprecated Error must be handled as the first argument of axe.analyze. See: #83 at tests/accessibility/aXeAccessibilityCheck.js:57:42
npm ERR! Test failed.  See above for more details.
Script npm test handling the va:test:accessibility event returned with error code 1
  • On: ip-10-247-34-228
  • In: 02:52

Please sign in to comment.