문제

I'm trying to apply jQuery UI Selectable to a portion of my website. However, I do not see either the selection box while dragging the mouse, nor does the color of selected li elements change.

So to understand the problem, I went back to the source:

http://jqueryui.com/demos/selectable/

I see (using IE9 developer tools) that a style .ui-selected is applied to selected elements. Using Trace Styles, IE shows that background-color is originally defined in jquery-ui.css but overridden (ultimately) by #selectable .ui-selected. However, IE does not show the source of #selectable .ui-selected. Searching the jQuery UI style sheet I reference, jquery-ui-1.8.18.custom.css, finds no mention of ui-selected, nor do I find it in jquery.ui.selectable.css.

Where exactly is the demo page getting the CSS for the background color?

도움이 되었습니까?

해결책

I found one of the other jQueryUI demos defines the style for those classes in a custom style sheet, so I ended up following that lead.

http://jqueryui.com/demos/selectable/#serialize

It seems odd that those styles are not part of jQueryUI Themeroller. Perhaps that will change in the future.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top