revsisons from testers inplemented part 1

This commit is contained in:
Serg-Kv
2024-03-28 19:43:28 +05:00
parent f369cdd4c6
commit aa29617bf5
18 changed files with 36 additions and 28 deletions

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 12 KiB

View File

@ -47,7 +47,7 @@
}
],
"isViewer": false,
"EditorsSupport": ["word", "slide"],
"EditorsSupport": ["word", "slide", "cell"],
"isVisual": false,
"isModal": false,
"isInsideMode": false,

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 97 KiB

After

Width:  |  Height:  |  Size: 77 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 119 KiB

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 119 KiB

After

Width:  |  Height:  |  Size: 91 KiB

View File

@ -134,12 +134,12 @@
switch (option) {
case 'displaySettings':
variation = {
url: location.href.replace(file, 'settings.html'),
url: location.href.replace(file, 'settingsQR.html'),
description: generateText('Settings'),
isVisual: true,
isModal: true,
buttons: [],
EditorsSupport: ['slide', 'word'],
EditorsSupport: ['slide', 'word', 'cell'],
size: [400, 500]
};
break;
@ -150,7 +150,7 @@
isVisual: true,
isModal: true,
buttons: [],
EditorsSupport: ['slide', 'word'],
EditorsSupport: ['slide', 'word', 'cell'],
size: [400, 200]
};
break;

View File

@ -30,7 +30,8 @@
const qrColorElement = document.getElementById('qrColor')
const bgColorElement = document.getElementById('bgColor');
const errSpan = document.getElementById('error-msg');
let spanMssg = "";
let spanMssgMinErr = "";
let spanMssgMaxErr = "";
// Define a global variable to store QR parameters
let storedSettings = {};
@ -44,7 +45,8 @@
activateBGlabel.innerText = window.Asc.plugin.tr('Set Background Color');
qrWidth.innerText = window.Asc.plugin.tr('Width');
qrHeight.innerText = window.Asc.plugin.tr('Height');
spanMssg = window.Asc.plugin.tr('Minimum QR size is 50px');
spanMssgMinErr = window.Asc.plugin.tr('Minimum QR size is 50px');
spanMssgMaxErr = window.Asc.plugin.tr('Maximum QR size is 2000px');
};
// Function to send message to plugin
@ -162,24 +164,40 @@
bgColorElement.style.borderColor = 'red';
return; // Exit the function to prevent further execution
case qrColor === bgColor:
event.preventDefault();
qrColorElement.style.borderColor = 'red';
bgColorElement.style.borderColor = 'red';
return;
case parseInt(qrWidthValue, 10) < 50:
event.preventDefault();
errSpan.innerText = spanMssg;
errSpan.innerText = spanMssgMinErr;
return; // Exit the function to prevent further execution
case parseInt(qrHeightValue, 10) < 50:
event.preventDefault();
errSpan.innerText = spanMssg;
errSpan.innerText = spanMssgMinErr;
return; // Exit the function to prevent further execution
case parseInt(qrWidthValue, 10) > 2000:
event.preventDefault();
errSpan.innerText = spanMssgMaxErr;
return; // Exit the function to prevent further execution
case parseInt(qrHeightValue, 10) > 2000:
event.preventDefault();
errSpan.innerText = spanMssgMaxErr;
return; // Exit the function to prevent further execution
case qrWidthValue === "":
event.preventDefault();
errSpan.innerText = spanMssg;
errSpan.innerText = spanMssgMinErr;
return; // Exit the function to prevent further execution
case qrHeightValue === "":
event.preventDefault();
errSpan.innerText = spanMssg;
errSpan.innerText = spanMssgMinErr;
return; // Exit the function to prevent further execution
default:

View File

@ -5,6 +5,7 @@
"Width": "Breite",
"Height": "Höhe",
"Minimum QR size is 50px": "Die minimale QR-Größe beträgt 50 Pixel",
"Maximum QR size is 2000px": "Die maximale QR-Größe beträgt 2000px",
"Warning": "Warnung",
"Insert QR": "QR einfügen",
"The plugin is not supported in the Internet Explorer": "Das Plugin wird im Internet Explorer nicht unterstützt",

View File

@ -5,6 +5,7 @@
"Width": "Anchura",
"Height": "Altura",
"Minimum QR size is 50px": "El tamaño mínimo del QR es de 50 píxeles",
"Maximum QR size is 2000px": "El tamaño máximo de QR es de 2000px",
"Warning": "Advertencia",
"Insert QR": "Insertar QR",
"The plugin is not supported in the Internet Explorer": "El plugin no es compatible con Internet Explorer.",

View File

@ -5,6 +5,7 @@
"Width": "Largeur",
"Height": "Hauteur",
"Minimum QR size is 50px": "La taille minimale du QR est de 50px",
"Maximum QR size is 2000px": "La taille maximale du QR est de 2000px",
"Warning": "Avertissement",
"Insert QR": "Insérer un QR",
"The plugin is not supported in the Internet Explorer": "Le plugin n'est pas pris en charge par Internet Explorer",

View File

@ -5,6 +5,7 @@
"Width": "Larghezza",
"Height": "Altezza",
"Minimum QR size is 50px": "La dimensione minima del QR è 50px",
"Maximum QR size is 2000px": "La dimensione massima del QR è di 2000px",
"Warning": "Avviso",
"Insert QR": "Inserisci il codice QR",
"The plugin is not supported in the Internet Explorer": "Il plugin non è supportato in Internet Explorer.",

View File

@ -5,6 +5,7 @@
"Width": "幅",
"Height": "高さ",
"Minimum QR size is 50px": "最小QRサイズは50px",
"Maximum QR size is 2000px": "QRの最大サイズは2000pxです",
"Warning": "警告",
"Insert QR": "QRの挿入",
"The plugin is not supported in the Internet Explorer": "このプラグインはInternet Explorerには対応していません",

View File

@ -5,6 +5,7 @@
"Width": "Largura",
"Height": "Altura",
"Minimum QR size is 50px": "O tamanho mínimo do QR é de 50 pixels",
"Maximum QR size is 2000px": "O tamanho máximo do QR é de 2000px",
"Warning": "Aviso",
"Insert QR": "Inserir QR",
"The plugin is not supported in the Internet Explorer": "O plugin não é suportado no Internet Explorer",

View File

@ -5,6 +5,7 @@
"Width": "Ширина",
"Height": "Высота",
"Minimum QR size is 50px": "Минимальный размер QR-кода 50 пикселей",
"Maximum QR size is 2000px": "Максимальный размер QR-кода составляет 2000 пикселей",
"Warning": "Предупреждение",
"Insert QR": "Вставить QR",
"The selected text is too long": "Выбранный текст слишком длинный.",

View File

@ -5,6 +5,7 @@
"Width": "宽度",
"Height": "高度",
"Minimum QR size is 50px": "最小二维码尺寸为 50px",
"Maximum QR size is 2000px": "QR的最大尺寸为2000px",
"Warning": "警告",
"Insert QR": "插入二维码",
"The plugin is not supported in the Internet Explorer": "该插件不支持 Internet Explorer 浏览器",