From 4993fb4cb0bb21e950620f21ce784faa720af82f Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Tue, 15 May 2012 15:29:33 -0400 Subject: [PATCH] Bug 7500 [FOLLOW-UP][Star ratings] Use CSS Sprites for faster page loading Combines two star ratings sprites into one and makes the corresponding CSS changes. The two original images have been removed. To test, view star ratings on search results and the detail page. Try setting star ratings on the detail page. Signed-off-by: Chris Cormack --- .../opac-tmpl/prog/en/css/jquery.rating.css | 8 +++++--- koha-tmpl/opac-tmpl/prog/images/delete.gif | Bin 752 -> 0 bytes .../prog/images/star-ratings-sprite.png | Bin 0 -> 2000 bytes koha-tmpl/opac-tmpl/prog/images/star.gif | Bin 815 -> 0 bytes 4 files changed, 5 insertions(+), 3 deletions(-) delete mode 100755 koha-tmpl/opac-tmpl/prog/images/delete.gif create mode 100644 koha-tmpl/opac-tmpl/prog/images/star-ratings-sprite.png delete mode 100644 koha-tmpl/opac-tmpl/prog/images/star.gif diff --git a/koha-tmpl/opac-tmpl/prog/en/css/jquery.rating.css b/koha-tmpl/opac-tmpl/prog/en/css/jquery.rating.css index e89096b6ea..616db6fc84 100644 --- a/koha-tmpl/opac-tmpl/prog/en/css/jquery.rating.css +++ b/koha-tmpl/opac-tmpl/prog/en/css/jquery.rating.css @@ -1,9 +1,11 @@ /* jQuery.Rating Plugin CSS - http://www.fyneworks.com/jquery/star-rating/ */ div.rating-cancel,div.star-rating{float:left;width:15px;height:15px;text-indent:-999em;cursor:pointer;display:block;background:transparent;overflow:hidden} -div.rating-cancel,div.rating-cancel a{background:url(../../images/delete.gif) no-repeat 0 -16px} -div.star-rating,div.star-rating a{background:url(../../images/star.gif) no-repeat 0 0px} -div.rating-cancel a,div.star-rating a{display:block;width:16px;height:100%;background-position:0 0px;border:0} +div.rating-cancel,div.rating-cancel a{background:url(../../images/star-ratings-sprite.png) no-repeat 0 -49px} +div.star-rating,div.star-rating a{background:url(../../images/star-ratings-sprite.png) no-repeat 0 0px} +div.rating-cancel a{display:block;width:16px;height:100%;background-position:0 -49px;border:0} +div.star-rating a{display:block;width:16px;height:100%;background-position:0 0px;border:0} div.star-rating-on a{background-position:0 -32px!important} +div.rating-cancel.star-rating-hover a{background-position:0 -65px} div.star-rating-hover a{background-position:0 -16px} /* Read Only CSS */ div.star-rating-readonly a{cursor:default !important} diff --git a/koha-tmpl/opac-tmpl/prog/images/delete.gif b/koha-tmpl/opac-tmpl/prog/images/delete.gif deleted file mode 100755 index 43c6ca8763d79bde87bcf437e497af00c8be562d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 752 zcmZ?wbhEHb6kt$bc*el6GthYN-n}zt&b)vB{*)i+-#|NQy$ zABXln&Q1FL`t{#CH*SY|{oJwc*Qz;h;)0))7aYq9ewP~fc2e)_P3vAY)$9wl{IzJp zy{ydlr;a^HiGHwZ{*SH8FZkJhE{gei`OM?;ir*_{?@ji478&@mD*tSH_`A&5@6Vqe z@G<&xeCOwiq-WvY-eS5f?;vgCP8#IHGBw=+^cY}xvy zx8c*8mDl2ff1W;kCeZrNm9vlQYJg5Caki?(^G9DBs4DA0KlA4-ZT3fl8 z8F_gb*}2-1v>0WWwY1oIg_&Emc-aM+Wn|bpRc1GF^$N-etzA1qr9X*XNNWw_j-BjG zGEKc(x)1gUF{(82E@ad^eMXp9hUxg0Q)f<}lVRDncBb&%dq*yAR+(|l-D@bZwvw%g)cL7VG z)An_f*+XqOetkIP*eg{wS7K(+qJ{-x0ue3?v&y~1d1To>MqD_2keNGNE=Pc|!BJ7b fV_(F^#N=Z_Jo9)pKRPly^YODPxtBy-~8&_;o+gq{@*Z@$!4=PMd^zJ z-ct|ll}e>Tp-`z*3tUf?Bz#_YcynPvaxPl_c&A#eUhe-^DLDQ-Cugzfn!Ja+GUT;7 z8uA;}MUl;1910msOIseGzNvGbIZvOgv3Xm4S5;p*`|u$*)P1e#7vNN?}blct_? zR5?9ly}5o}p%}S(byFo(4-U$@S~PO`5-V9HeZ4$!iy!GD<$5Rte2whQcvbN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.gif deleted file mode 100644 index d0948a70843bf01952d1f81dcfcdadc92976a04a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 815 zcmZ?wbhEHb6ksr5c*el6(A@m!(W5UnOP^`reSRqFN=wUy;^KSv?mbz*{y;*);~mc5 z-|RUW6m;#{wMW}bp6pHg_U+rN({8s`u6+0I-Q5+MAMeb%w`5!M# z{q=^=j}*N*e*EQepZ7;K-(U6l^W*)qy-uI5Mx04YJ9FmD@2@w0e|`3BzvYV!svmDJ zy1UBtA9dUx3IVz=bW<9TmSpMHPB|LHc1x92?H@6~*NPV?1P?R#4d zPbMV1-s|#ytJ9}D;U7+0e!n;8#jahi&$Zv4GUd&Fk1akv*Jf&ey1!wEi_7gU#eYv#yB=$CE4*Ha3+f942mV(XO4k$!yUkYI4!^v z(7()>%8M?Gl%7kx>Gn`^RAQF96>H~ zqm`q-QcY~aQ7_g~!8sNO9r=2u3Mlqi#CWtc9T(=ypIRf>c$iT@(<;xV@nLFbqN;ve z&H|wp@2R5NS2`L#KJ=KR(rKEJaLDyUmqb%cL}by=)-=YHmH-A@k7GPXma%d?aC*qL zh)X7I#x;cnUQ^jS^;|kOFmg@Nv0U}W!=<5%L(6DYL1B*CL?*3JjSUV#i&`dVbSiW! SUO9NY!6jXVS5kz7!5RQ