How does jQuery user interface work?

Can anyone explain how jQuery UI themes work without assigning any elements to the css class on the html plan page. How can .css files in a jQuery user interface theme collect elements? Does jQuery script file support css file select elements?

+3
source share
4 answers

When jquery creates dynamic html elements, it assigns predefined classes to the elements in this way.

Ex. The tab container has the following css classes assigned to it ui-tabs ui-widget ui-widget-content ui-corner-all, and each tab header has the following classes ui-state-default ui-corner-top.

.css , .

+1

... . , , , , ..

, , , , , divs, . CSS . , ( Firebug ) .

0

. ...

.ui-helper-hidden { display: none; }
...
.ui-widget .ui-widget { font-size: 1em; }
...
.ui-icon-carat-1-n { background-position: 0 0; }
...
.ui-resizable-handle { position: absolute;font-size: 0.1px;z-index: 99999; display: block;}
...
.ui-menu .ui-menu {
 margin-top: -3px;
}

, jQuery css css. , css, ? Jquery UI javascript framework html, css .

0

jQuery UI, -

$('#myDiv').tabs();

,

$('#myDiv').addClass('ui-tabs');
$('#myDiv').addClass('ui-widget');

DOM , , , , , , div, List-Elements ..

.

CSS , jQuery

0

Source: https://habr.com/ru/post/1780808/


All Articles