Merge pull request #2293 from PR0M3TH3AN/fix-qrcode-margin-1471063368087881560

Fix margin values calculation in QRCode drawing
This commit is contained in:
thePR0M3TH3AN authored and GitHub committed 2026-02-09 23:30:43 -05:00
commit 3eaee7be35
1 file changed
+2 -2
+2 -2
View File
@@ -364,8 +364,8 @@ if (hasDocument) {
// Fix the margin values as real size.
var elTable = _el.childNodes[0];
var nLeftMarginTable = (_htOption.width - elTable.offsetWidth) / 2;
var nTopMarginTable = (_htOption.height - elTable.offsetHeight) / 2;
var nLeftMarginTable = (_htOption.width - (nCount * nWidth)) / 2;
var nTopMarginTable = (_htOption.height - (nCount * nHeight)) / 2;
if (nLeftMarginTable > 0 && nTopMarginTable > 0) {
updateQrCodeContainerStyles(_el, {