magento / magento2-page-builder

Magento2 PageBuilder
Other
79 stars 59 forks source link

slick class too generic and also impact to other slider area #846

Open mrtuvn opened 1 year ago

mrtuvn commented 1 year ago

While works with side project used magento i recognised slick slide from module magento-pagebuilder also have same class and it impacted accidently to slider components not used page builder. Only simple slider with simple default class

Styles from page builder

.slick-slide {
 /// Magento code
}

But inmho it's should have prefix class to avoid impact

example

.pb-slide {
  .slick-slide {

  }
}

.page-builder-slide {
  .slick-slide {
    // Code here will no impact to other slider used slick.
    // Only apply for slick slide from page builder
  }
}

Code problem line https://github.com/magento/magento2-page-builder/blob/develop/app/code/Magento/PageBuilder/view/frontend/web/css/source/slick/_slick.less#L75

Preconditions (*)

  1. version magento 2.4.6 (maybe core upstream)
  2. page builder latest version installed

Steps to reproduce (*)

  1. Include custom slick slider from home page
  2. Inspect into slick item

Expected result (*)

  1. Slick only apply styles from slider custom in homepage

Actual result (*)

  1. page builder slick slider impact to slider at homepage
m2-assistant[bot] commented 1 year ago

Hi @mrtuvn. Thank you for your report. To speed up processing of this issue, make sure that you provided sufficient information. Add a comment to assign the issue: @magento I am working on this


Join Magento Community Engineering Slack and ask your questions in #github channel.