Replaced single `id` argument to $.createSpinner with an options object. The options allow one to set the id (as before), spinner size (small or large), and its display mode (inline or block). Analogic change was made to $.fn.injectSpinner. Default options are kept the same as they used to be, and old-style calls still work. However, the definition of .mw-spinner CSS class has been changed (although, with a bit of hairy code, it could be kept compatible...). These changes should be enough to allow us to replace old usages of .mw-small-spinner and .mw-ajax-loader classes, as defined in shared.css. This is a reimplementation of the idea described in Ie55ffb6b. Copied spinner.gif and ajax-loader.gif from /skins/common/images/. Change-Id: I0ff71ba1eef299e0e699df84c68f1be1c20492f7
40 lines
808 B
CSS
40 lines
808 B
CSS
.mw-spinner {
|
|
background-color: transparent;
|
|
background-position: center center;
|
|
background-repeat: no-repeat;
|
|
}
|
|
|
|
.mw-spinner-small {
|
|
/* @embed */
|
|
background-image: url(images/spinner.gif);
|
|
height: 20px;
|
|
width: 20px;
|
|
/* Avoid issues with .mw-spinner-block when floated without width. */
|
|
min-width: 20px;
|
|
}
|
|
|
|
.mw-spinner-large {
|
|
/* @embed */
|
|
background-image: url(images/spinner-large.gif);
|
|
height: 32px;
|
|
width: 32px;
|
|
/* Avoid issues with .mw-spinner-block when floated without width. */
|
|
min-width: 32px;
|
|
}
|
|
|
|
.mw-spinner-block {
|
|
display: block;
|
|
/* This overrides width from .mw-spinner-large / .mw-spinner-small,
|
|
* This is where the min-width kicks in.
|
|
*/
|
|
width: 100%;
|
|
}
|
|
|
|
.mw-spinner-inline {
|
|
display: inline-block;
|
|
vertical-align: middle;
|
|
|
|
/* IE < 8 */
|
|
zoom: 1;
|
|
*display: inline;
|
|
}
|