diff --git a/app/templating/AssetHelper.scala b/app/templating/AssetHelper.scala index c6d0c39374..1faeda7d21 100644 --- a/app/templating/AssetHelper.scala +++ b/app/templating/AssetHelper.scala @@ -7,7 +7,7 @@ import play.api.templates.Html trait AssetHelper { - val assetVersion = 65 + val assetVersion = 66 def cssTag(name: String) = css("stylesheets/" + name) diff --git a/public/javascripts/analyse.js b/public/javascripts/analyse.js index fba78249ea..a4ddbf20bc 100644 --- a/public/javascripts/analyse.js +++ b/public/javascripts/analyse.js @@ -59,7 +59,6 @@ function posToSquareId(pos) { function customFunctionOnMove() { var $comment = $('#GameLastComment'); - $comment.toggle($comment.find('> .comment').text().length > 0); var moves = $comment.find('.commentMove').map(function() { return $(this).text(); }); var ids = $.map(moves, posToSquareId); $("#GameBoard img.bestmove").removeClass("bestmove"); @@ -67,10 +66,13 @@ function customFunctionOnMove() { if (this) $("#" + this).addClass("bestmove"); }); refreshButtonset(); - var chart = $("div.adv_chart").data("chart"); + var $chart = $("div.adv_chart"); + var chart = $chart.data("chart"); if (chart) { var index = CurrentPly - 1; chart.setSelection([{ row: index, column: 1}]); + var rows = $chart.data('rows'); + $comment.prepend($("

").html("White advantage: " + rows[index][1] + "")); } var turn = Math.round(CurrentPly / 2); var $gameText = $("#GameText"); diff --git a/public/stylesheets/analyse.css b/public/stylesheets/analyse.css index fb53226e1a..d0689f1e02 100644 --- a/public/stylesheets/analyse.css +++ b/public/stylesheets/analyse.css @@ -109,9 +109,13 @@ span.board_mark.horz { position: absolute; top: 512px; margin-top: 1em; - font-size: 1.4em; width: 220px; } +#GameLastComment .comment { + margin-top: 0.2em; + font-size: 1.3em; + display: block; +} div.advice_summary { position: absolute; top: 740px; diff --git a/todo b/todo index 16847efffc..bbdb45a98c 100644 --- a/todo +++ b/todo @@ -30,7 +30,6 @@ game stats timeline issues http://en.lichess.org/forum/lichess-feedback/move-tim propagate IP ban to the user admin ip search interface analyse: show main line for every move http://en.lichess.org/forum/lichess-feedback/about-the-analysis-feature#5 -analyse: show cp every move (as graph popup?) clock in AI game try to show last analysis cp on graph (move 26) http://en.lichess.org/analyse/bwxnx0al elo range must contain player elo