1
0
mirror of https://github.com/maximebf/php-debugbar.git synced 2025-07-16 06:16:31 +02:00

Tweak percentage for sticky (#700)

This commit is contained in:
Barry vd. Heuvel
2024-12-16 14:45:01 +01:00
committed by GitHub
parent f3b0022b54
commit bb21b0dfe0

View File

@ -961,11 +961,11 @@ if (typeof(PhpDebugBar) == 'undefined') {
var screenWidth = $(window).width();
var positionPercentage = (finalPosX / screenWidth) * 100; // Store as percentage
if (positionPercentage < 10) {
if (positionPercentage < 20) {
self.restorePosition = 'bottomLeft';
self.restoreOffset = finalPosX;
} else if (positionPercentage > 90) {
} else if (positionPercentage > 80) {
self.restorePosition = 'bottomRight';
self.restoreOffset = screenWidth - finalPosX;
} else {