Skip to content

Conversation

friendscottn
Copy link

@friendscottn friendscottn commented Jan 11, 2023

Description (*)

This prevents unnecessary duplicated CSS from showing in all stylesheets. For example styles-m.css and styles-l.css

Fixed Issues (if relevant)

  1. Fixes Missing LESS guards create duplicate CSS #325

Manual testing scenarios (*)

  1. Compile the less files into CSS
  2. Make sure the following styles only appear in styles-m.css:
.form-discount .g-recaptcha {
  margin-top: 50px !important;
}
...
.login-container .g-recaptcha,
.form-login .g-recaptcha,
.form-edit-account .g-recaptcha {
  margin-bottom: 10px !important;
}
...
.required-captcha.checkbox {
  position: absolute;
  display: block;
  visibility: visible;
  overflow: hidden;
  opacity: 0;
  width: 1px;
  height: 1px;
}
...
.block.newsletter .field-recaptcha .field .control:before {
  content: none;
}
...
.review-form .field-recaptcha {
  margin-bottom: 10px;
}

Contribution checklist (*)

  • Author has signed the Adobe CLA
  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • All automated tests passed successfully (all builds are green)

This prevents unnecessary duplicated CSS from showing in all stylesheets. For example styles-m.css and styles-l.css
@friendscottn
Copy link
Author

Signed agreement. Reopening

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Missing LESS guards create duplicate CSS
3 participants