` $(“.sb-modal-ranks__list tbody tr”).each(function() {
var currentScore = parseInt($(“.current-score”).text());
var minScore = parseInt($(this).find(“.sb-modal-ranks__rank-points”).text());
if (currentScore === minScore) {
var $currentRow = $(this);
var $nextRow = $currentRow.next();
$nextRow.addClass("sb-modal-ranks__achieved").removeClass("sb-modal-ranks__current")
.find(".sb-modal-ranks__rank-marker").removeClass("current-score");
$currentRow.addClass("sb-modal-ranks__current").find(".dot, .line").addClass("achieved")
.find(".sb-modal-ranks__rank-marker").append('<span class="current-score">' + currentScore + '</span>');
// Update sb-progress-dots with current score
$(".sb-progress-dot").each(function() {
var dotScore = parseInt($(this).text());
if (currentScore >= dotScore) {
$(this).addClass("completed");
} else {
$(this).removeClass("sb-progress-dot__achieved");
}
});
}
});`
I want to append the current-score class to the sb-modal-ranks__rank-marker class