$(document).on('mousemove', '.transfusionButton', function (event) {
const buttonProportions = $(this)[0].getBoundingClientRect();
const {
clientX
} = event;
const {
left
} = buttonProportions;
const x = clientX - left;
const {
width
} = buttonProportions;
$html.attr('style', `--transfusionPercent:${x - width / 2}px;`);
});
function getCellsBy(cellIndex) {
return $(`[data-cell-index=${cellIndex}]`);
}
const {
clientX
} = event;