/kai/public/css/rating.css

https://bitbucket.org/bbangert/kai/ · CSS · 67 lines · 61 code · 3 blank · 3 comment · 0 complexity · b371622c58e0bf5f08fab6fc4fe3e76e MD5 · raw file

  1. #rating_area {
  2. float: right;
  3. text-align: right;
  4. margin-top: -35px;
  5. }
  6. .rating{
  7. width:80px;
  8. height:16px;
  9. padding:0;
  10. list-style:none;
  11. position:relative;
  12. background: url(/css/images/star-matrix.gif) no-repeat 0 0;
  13. display: block;
  14. clear: none;
  15. text-align: center;
  16. }
  17. .rating_text {
  18. margin-right: 15px;
  19. font-size: 12px;
  20. color: #ababab;
  21. }
  22. /* add these classes to the ul to effect the change to the correct number of stars */
  23. .nostar {background-position:0 0;
  24. }
  25. .onestar {background-position:0 -16px}
  26. .twostar {background-position:0 -32px}
  27. .threestar {background-position:0 -48px}
  28. .fourstar {background-position:0 -64px}
  29. .fivestar {background-position:0 -80px}
  30. ul.rating li {
  31. cursor: pointer;
  32. /*ie5 mac doesn't like it if the list is floated\*/
  33. float:left;
  34. /* end hide*/
  35. text-indent:-999em;
  36. list-style: none;
  37. }
  38. ul.rating li a {
  39. position:absolute;
  40. left:0;
  41. top:0;
  42. width:16px;
  43. height:16px;
  44. text-decoration:none;
  45. z-index: 200;
  46. }
  47. ul.rating li.one a {left:0}
  48. ul.rating li.two a {left:16px;}
  49. ul.rating li.three a {left:32px;}
  50. ul.rating li.four a {left:48px;}
  51. ul.rating li.five a {left:64px;}
  52. ul.rating li a:hover {
  53. z-index:2;
  54. width:80px;
  55. height:16px;
  56. overflow:hidden;
  57. left:0;
  58. background: url(/css/images/star-matrix.gif) no-repeat 0 0
  59. }
  60. ul.rating li.one a:hover {background-position:0 -96px;}
  61. ul.rating li.two a:hover {background-position:0 -112px;}
  62. ul.rating li.three a:hover {background-position:0 -128px}
  63. ul.rating li.four a:hover {background-position:0 -144px}
  64. ul.rating li.five a:hover {background-position:0 -160px}