-Subproject commit b10cdf123648beb76120194d7f9bb69fc8433ede
+Subproject commit 2919eb4f57c7e1c9dead734c685a9b36f34e30ce
return [mandat, opt]
show_score: (score) ->
- $(".message", @element).text("Wynik: #{score[0]} / #{score[1]}")
+ $msg = $(".message", @element)
+ $msg.text("Wynik: #{score[0]} / #{score[1]}")
+ if score[0] == score[1]
+ $msg.addClass("maxscore")
+ else
+ $msg.removeClass("maxscore")
draggable_equal: ($draggable1, $draggable2) ->
};
Exercise.prototype.show_score = function(score) {
- return $(".message", this.element).text("Wynik: " + score[0] + " / " + score[1]);
+ var $msg;
+ $msg = $(".message", this.element);
+ $msg.text("Wynik: " + score[0] + " / " + score[1]);
+ if (score[0] === score[1]) {
+ return $msg.addClass("maxscore");
+ } else {
+ return $msg.removeClass("maxscore");
+ }
};
Exercise.prototype.draggable_equal = function($draggable1, $draggable2) {