On one page I use several JS extensions ( DataTables and JqueryUI - Dialog ). And in the header I declare links to their default styles <link rel="stylesheet" type="text/css" href= . There is a conflict. How to specify for a particular div style? This is not how it works:

 #dialog_create_product { @import url("https://code.jquery.com/ui/1.10.4/themes/ui-lightness/jquery-ui.css"); } 
  • one
    Even if you manage to connect the styles in this way - you will not eliminate all contacts, since In jquery-ui.css may be styles for, for example, elements in the body , and you lock styles for them inside #dialog_create_product . As a result, they will never be applied to the layout of jQueryUI components. - Vitaliy Emelyantsev
  • Thus, it was not possible to connect (. And what happens in cases of conflict of styles? In this case, how to tie a link to the css style to a specific selector, it seems that this should solve the problem because I think that the JS extension uses only the specified div - Bogdan Shulga
  • one
    External libraries such as jquery-ui do not need to, in principle, strive to connect in the context of a block. These are not modular styles. Connect them as they connected, through <link rel="... and fix conflicts by overloading custom styles. - Vitaly Emelyantsev
  • 2
    In addition, you may not need to connect the jquery-ui theme ( themes/ui-lightness ), but instead style the interface yourself. - Vitaliy Emelyantsev

1 answer 1

Point your styles right in the div. The best solution is to create separate styles for the div - this increases the loading speed. It is also possible to edit jquery styles - I did this.