How can I use themeroller'ed styles in the “normal” parts of the page?

I have a web application in which I recently applied the jQuery ThemeRoller theme. Now I want to have a simple <h2>. The element has the same rounded rectangular appearance as the title of the dialog header or the date name. How can I best apply them to my elements that are not part of the larger jQuery UI constructs?

I started by simply setting the css class values ​​manually, based on what I saw in the Chrome inspector tool, and I got some of this way before I started to get nervous that this would not necessarily be the best way, since I would bypass any CSS class assignment logic that can occur inside the jQuery user interface.

So, is there an easier way to apply these styles, or should I just go the path of explicitly defining CSS styles in my headers?

+3
source share
3 answers

There is no magic in jQuery ThemeRoller CSS styles, if you look at the CSS files that it generates, you will find that they are generally clear and concise and readable.

CSS ThemeRoller IE, , , CSS, style = 'blah'.

+3

stevedbrown answer .

ui-corner-. , div, ui-corner-all.

, ui-corner-tr ui-corner-tl TopLeft TopRight.

+3

, CSS, , , :

var defaultColor = $(".ui-state-default").css("color");
var defaultMargin = $(".ui-state-default").css("margin");

$(".your-css-class").css("color",color);
$(".another-css-class").css("margin",margin);

..

, CSS , .

+1
source

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


All Articles