Trying to fix phpcs issue observed in this module.
Used command to generate issue related to phpcs
phpcs --standard=Drupal --extensions=php,module,inc,install,test,profile,theme,info,txt,md,yml web/modules/custom/uswds_base

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\includes\base_themes.inc
-----------------------------------------------------------------------------------
FOUND 2 ERRORS AFFECTING 2 LINES
-----------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
11 | ERROR | [x] When importing a class with "use", do not include a leading \
-----------------------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\includes\blocks.inc
----------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
----------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\includes\menus.inc
-----------------------------------------------------------------------------------
FOUND 3 ERRORS AFFECTING 3 LINES
-----------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
52 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 3
56 | ERROR | [x] Closing brace indented incorrectly; expected 3 spaces, found 2
-----------------------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\block\block__block_content__hero.preprocess.inc
---------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
---------------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
---------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
---------------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\block\block__system_menu_block__footer_menu.preprocess.inc
--------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
--------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\block\block__system_menu_block__primary_menu.preprocess.inc
---------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
---------------------------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
---------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
---------------------------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\block\block__system_menu_block__secondary_menu.preprocess.inc
-----------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
-----------------------------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
-----------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\block\block__system_menu_block__sidebar_first.preprocess.inc
----------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
----------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\block\block__system_menu_block__sidebar_second.preprocess.inc
-----------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
-----------------------------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
-----------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\element\details.preprocess.inc
----------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
----------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\element\form_element.preprocess.inc
---------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
---------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
---------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
---------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\element\form_element_label.preprocess.inc
---------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
---------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
---------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
---------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\element\vertical_tabs.preprocess.inc
----------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
----------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\layout\page.preprocess.inc
------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\menu\menu_local_action.preprocess.inc
-----------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
-----------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
-----------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\menu\menu_local_tasks.preprocess.inc
----------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
----------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\menu\menu__footer_menu.preprocess.inc
-----------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
-----------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
-----------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\menu\menu__mobile_menu.preprocess.inc
-----------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
-----------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
-----------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\menu\menu__primary_menu.preprocess.inc
------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\menu\menu__secondary_menu.preprocess.inc
--------------------------------------------------------------------------------------------------------
FOUND 2 ERRORS AFFECTING 2 LINES
--------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
22 | ERROR | [x] Space found before comma in argument list
--------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\preprocess.inc
----------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
----------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\preprocess\views\views_mini_pager.preprocess.inc
-----------------------------------------------------------------------------------------------------
FOUND 4 ERRORS AFFECTING 4 LINES
-----------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
11 | ERROR | [x] Line indented incorrectly; expected 0 spaces, found 1
12 | ERROR | [x] Expected 2 space(s) before asterisk; 1 found
13 | ERROR | [x] Expected 2 space(s) before asterisk; 1 found
-----------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 4 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\starterkits\README.md
--------------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
--------------------------------------------------------------------------
9 | WARNING | [ ] Line exceeds 80 characters; contains 95 characters
24 | ERROR | [x] Expected 1 newline at end of file; 0 found
--------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\starterkits\uswds_base_subtheme\css\uswds_base.css
-------------------------------------------------------------------------------------------------------
FOUND 15 ERRORS AFFECTING 13 LINES
-------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
7 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 4
7 | ERROR | [x] Selectors must be on a single line
8 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 4
8 | ERROR | [x] Multiple selectors should each be on a single line
9 | ERROR | [x] Line indented incorrectly; expected 4 spaces, found 8
10 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 4
13 | ERROR | [x] Selectors must be on a single line
14 | ERROR | [x] Multiple selectors should each be on a single line
15 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 4
24 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 4
25 | ERROR | [x] Line indented incorrectly; expected 4 spaces, found 8
26 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 4
35 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 4
36 | ERROR | [x] Expected 1 newline at end of file; 0 found
-------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 15 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\starterkits\uswds_base_subtheme\README.md
----------------------------------------------------------------------------------------------
FOUND 1 ERROR AND 3 WARNINGS AFFECTING 3 LINES
----------------------------------------------------------------------------------------------
7 | WARNING | [ ] Line exceeds 80 characters; contains 148 characters
14 | WARNING | [ ] Line exceeds 80 characters; contains 108 characters
16 | WARNING | [ ] Line exceeds 80 characters; contains 87 characters
16 | ERROR | [x] Expected 1 newline at end of file; 0 found
----------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\starterkits\uswds_base_subtheme\uswds_base_subtheme.theme
--------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
--------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\starterkits\uswds_base_subtheme_sass\README.md
---------------------------------------------------------------------------------------------------
FOUND 1 ERROR AND 16 WARNINGS AFFECTING 16 LINES
---------------------------------------------------------------------------------------------------
3 | WARNING | [ ] Line exceeds 80 characters; contains 93 characters
8 | WARNING | [ ] Line exceeds 80 characters; contains 115 characters
10 | WARNING | [ ] Line exceeds 80 characters; contains 117 characters
14 | WARNING | [ ] Line exceeds 80 characters; contains 94 characters
15 | WARNING | [ ] Line exceeds 80 characters; contains 119 characters
16 | WARNING | [ ] Line exceeds 80 characters; contains 105 characters
18 | WARNING | [ ] Line exceeds 80 characters; contains 120 characters
19 | WARNING | [ ] Line exceeds 80 characters; contains 108 characters
21 | WARNING | [ ] Line exceeds 80 characters; contains 117 characters
22 | WARNING | [ ] Line exceeds 80 characters; contains 113 characters
23 | WARNING | [ ] Line exceeds 80 characters; contains 114 characters
24 | WARNING | [ ] Line exceeds 80 characters; contains 116 characters
26 | WARNING | [ ] Line exceeds 80 characters; contains 115 characters
27 | WARNING | [ ] Line exceeds 80 characters; contains 109 characters
28 | WARNING | [ ] Line exceeds 80 characters; contains 98 characters
29 | WARNING | [ ] Line exceeds 80 characters; contains 81 characters
29 | ERROR | [x] Expected 1 newline at end of file; 2 found
---------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
---------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\starterkits\uswds_base_subtheme_sass\uswds_base_subtheme.theme
-------------------------------------------------------------------------------------------------------------------
FOUND 3 ERRORS AFFECTING 3 LINES
-------------------------------------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
8 | ERROR | [x] There must be exactly one blank line after the file comment
12 | ERROR | [x] Expected 1 blank line before function; 0 found
-------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-------------------------------------------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\theme-settings.php
----------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
----------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------

FILE: C:\xampp\htdocs\drupal_9\web\themes\uswds_base\uswds_base.theme
-------------------------------------------------------------------------------------
FOUND 3 ERRORS AND 2 WARNINGS AFFECTING 3 LINES
-------------------------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
62 | WARNING | [ ] Hook implementations should not duplicate @param documentation
62 | ERROR | [ ] Missing parameter comment
63 | WARNING | [ ] Hook implementations should not duplicate @param documentation
63 | ERROR | [ ] Missing parameter comment
-------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY

Issue fork uswds_base-3363297

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

arti_parmar’s picture

End of line character is invalid; expected "\n" but found "\r\n"

arti_parmar’s picture

Status: Active » Needs review
StatusFileSize
new10.19 KB

Kindly review patch,,

avpaderno’s picture

Version: 3.0.0 » 3.0.x-dev
Category: Bug report » Task
Status: Needs review » Needs work
Issue tags: +Coding standards, +Needs issue summary update

The issue summary should always describe what the issue is trying to fix and, in the case of coding standards issues, show which command and arguments have been used and which report that command shown.

ashutosh ahirwal’s picture

Assigned: arti_parmar » Unassigned
Issue summary: View changes
Status: Needs work » Needs review
StatusFileSize
new10.48 KB

Hi I have reviewed #2 patch and there is minor change required is

FILE: /Users/ashutoshahirwal/Sites/lando/contribution/web/modules/custom/uswds_base/starterkits/uswds_base_subtheme/js/uswds_base.js
------------------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
------------------------------------------------------------------------------------------------------------------------------------
1 | ERROR | [x] Expected 1 newline at end of file; 0 found
------------------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
------------------------------------------------------------------------------------------------------------------------------------

Time: 286ms; Memory: 10MB

Command use to regenerate the issue is

phpcs --standard=Drupal --extensions=php,module,inc,install,test,profile,theme,info,txt,md,css,js,yml web/modules/custom/uswds_base

Fixing the remaining bug and providing patch for it.

avpaderno’s picture

Priority: Normal » Minor
Status: Needs review » Needs work
Issue tags: -Needs issue summary update
-      $search_item = t('<li class="js-search-button-container"><button class="usa-header-search-button js-search-button">@search</button></li>'
-          , ['@search' => 'Search']);
+      $search_item = t('<li class="js-search-button-container">

Code lines are not required to be shorter than 81 characters. Line length and wrapping, part of the Drupal coding standards, says:

  • Lines containing longer function names, function/class definitions, variable declarations, etc are allowed to exceed 80 characters.
  • Control structure conditions may exceed 80 characters, if they are simple to read and understand.

(Emphasis is mine.)

The existing code is simpler to read and understand than the changed code.

-1. Copy this directory to themes/custom and replace theme name in files and code with your own.
+1. Copy this directory to themes/custom and replace theme name in files and
+code with your own.

Since that text is part of a list, the last line needs to be indented.

-This sub-theme requires compiling of the USWDS CSS and also the assets folder for javascript.
+This sub-theme requires compiling of the USWDS CSS and also the assets
+folder for javascript.

Since that text is edited, the spelling of javascript should also be corrected.

+/**
+ * @file
+ * Add js code.
+ */

Add js code. does not make much sense as description, since it should describe the purpose of the code contained in that file.

nitin_lama’s picture

Assigned: Unassigned » nitin_lama
nitin_lama’s picture

Status: Needs work » Needs review
StatusFileSize
new10.56 KB
new3.51 KB

Addressed #5. Updated patch. Please review.

nitin_lama’s picture

Assigned: nitin_lama » Unassigned
arpitk’s picture

StatusFileSize
new104.83 KB

Hi The patch #7 applies cleanly. No errors/warnings are produced anymore. The issues from #5 are also taken care. I used phpcs --standard=Drupal --extensions=php,module,inc,install,test,profile,theme,info,txt,md,css,js,yml to test.

Thanks!

avpaderno’s picture

Status: Needs review » Needs work
- * Use init only once. The init task is meant for initializing the design system on a project.
-Since it will overwrite project files (like settings files and the Sass entry point), use it sparingly and don't use it
-for updating the design system on a project, or at any point after you've customized your settings files.
-
- * Update USWDS assets with copyAssets. Don't update assets with init, use the copyAssets task. This task updates static
-assets (like images, fonts, and compiled JavaScript) only and you don't risk clobbering your customizations.
-
- * Compile only from a single Sass entry point. Define the location of this entry point with paths.dist.theme. If you
-have project Sass files outside the paths.dist.theme directory, load these files into your single entry point via
-@forward, @use, or @import. To include these project Sass files in your gulp watch task, set paths.src.projectSass
-to your project Sass directory. The Sass will still compile from the single entry point located in paths.dist.theme.
-
- * Only check theme files and custom icons into version control. You should have a build process that copies static
-assets like images, fonts, and compiled JavaScript from the uswds package. This assures that these assets are
-up-to-date with whatever version of USWDS you're using. You only need to track your customizations
-(like settings, theme files, custom icons, and your gulpfile) in version control.
-
+ * Use init only once. The init task is meant for initializing the design
+ system on a project.
+Since it will overwrite project files (like settings files and the Sassentry
+point),use it sparingly and don't use it for updating the design system on a
+project, or at any point after you've customized your settings files.
+
+ * Update USWDS assets with copyAssets. Don't update assets with init, use
+the copyAssets task.
+This task updates static assets (like images, fonts, and compiled JavaScript)
+only and you don't risk clobbering your customizations.
+
+ * Compile only from a single Sass entry point. Define the location of this
+entry point with paths.dist.theme. If you have project Sass files outside the
+paths.dist.theme directory, load these files into your single entry point via
+@forward, @use, or @import. To include these project Sass files in your gulp
+watch task, set paths.src.
+projectSass to your project Sass directory. The Sass will still compile from the
+single entry point located in paths.dist.theme.

Since that text is part of a list, it should be formatted as the following text, similarly to the already changed text in a list.

* Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod
  tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
  quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
  consequat.
* Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore
  eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt
  in culpa qui officia deserunt mollit anim id est laborum.
nitin_lama’s picture

Assigned: Unassigned » nitin_lama
nitin_lama’s picture

Status: Needs work » Needs review
StatusFileSize
new10.61 KB
new2.86 KB

Addressed #10. Updated patch. Please review.

nitin_lama’s picture

Assigned: nitin_lama » Unassigned
mferanda’s picture

Hi everyone,

Just watching this progress.

When I reviewed at DrupalCon last week... I did notice this change.

@media (min-width: 64em) {
- .usa-header--extended .usa-navbar
- , .usa-header--extended .usa-nav__inner {
- max-width: none;
- }
+ .usa-header--extended .usa-navbar .usa-header--extended .usa-nav__inner {
+ max-width: none;
+ }
}

Please review the change... (comma)

avpaderno’s picture

Status: Needs review » Needs work

Yes, the comma is missing in two cases.

 @media (min-width: 64em) {
-    .usa-header--extended .usa-navbar
-    , .usa-header--extended .usa-nav__inner {
-        max-width: none;
-    }
+  .usa-header--extended .usa-navbar .usa-header--extended .usa-nav__inner {
+    max-width: none;
+  }
 }
-div.usa-banner__inner
-, div.grid-container {
-    max-width: none;
+div.usa-banner__inner div.grid-container {
+  max-width: none;
 }
mferanda’s picture

Ill definitely look at this closely when I’m not on my cell phone. USWDS 3.5.0 was just released, so we should be able to include these changes for uswds_base 3.4.x release. Since a new minor is out, I’d like to push out 3.4 soon.

smustgrave’s picture

Title: Fix the issues reported by phpcs » Fix the issues reported by phpcs + add gitlab
Version: 3.0.x-dev » 3.4.x-dev

Should be adding a gitlab file to avoid this in the future.

smustgrave’s picture

Status: Needs work » Needs review

Started at #12 but still had about a dozen issues. Also an eslint issue. Pipeline is showing all green now.

mferanda’s picture

My comment on #14 is still true

mferanda’s picture

Status: Needs review » Needs work
smustgrave’s picture

That was my mistake. Probably should of just started from scratch. These tickets have spammed the community as a whole, but adding the gitlab file will be important for the switch over.

Also with the recent changes there were some conflicts.

smustgrave’s picture

Status: Needs work » Needs review

Fixed

  • mferanda committed 0c69171d on 3.4.x authored by smustgrave
    Issue #3363297 by smustgrave, nitin_lama, arti_parmar, Ashutosh Ahirwal...
mferanda’s picture

Status: Needs review » Fixed
mferanda’s picture

Status: Fixed » Closed (fixed)