security-package icon indicating copy to clipboard operation
security-package copied to clipboard

Wrapping less in missing guards

Open friendscottn opened this issue 2 years ago • 1 comments

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 #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 (*)

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

friendscottn avatar Jan 11 '23 17:01 friendscottn

Signed agreement. Reopening

friendscottn avatar Jan 11 '23 17:01 friendscottn