Add mnin margin to buttons.

This commit is contained in:
Pedro Silva 2023-12-21 17:46:07 +00:00
parent c8ee62892a
commit e04f76d078
No known key found for this signature in database
GPG key ID: E2EE20C0669D24B3

View file

@ -104,8 +104,10 @@ export class ApmButtons {
return true;
}
const minMargin = 11; // Minimum margin.
const height = $el.height();
$el.css('margin-top', `${Math.round(height * 0.3)}px`);
const margin = Math.max(minMargin, Math.round(height * 0.3));
$el.css('margin-top', `${margin}px`);
});
}