Initial commit: apps.supersamsev.ru

This commit is contained in:
root committed 2026-10-21 23:46:31 +03:00
commit 54475e7d3d
17284 files changed
+98268

No files matched your search

+41
View File
@@ -0,0 +1,41 @@
function replaceToRus(str) {
let replacer = {
"q": "й", "w": "ц", "e": "у", "r": "к", "t": "е", "y": "н", "u": "г",
"i": "ш", "o": "щ", "p": "з", "[": "х", "]": "ъ", "a": "ф", "s": "ы",
"d": "в", "f": "а", "g": "п", "h": "р", "j": "о", "k": "л", "l": "д",
";": "ж", "'": "э", "z": "я", "x": "ч", "c": "с", "v": "м", "b": "и",
"n": "т", "m": "ь", ",": "б", ".": "ю",
"/": ".", '@': '"', '#': '№', '$': ';', '^': ':', '&': '?', '?': ',',
};
for(let i=0; i < str.length; i++){
if(replacer[str[i]] != undefined){
str = str.replace(str[i], replacer[str[i]]);
}
}
return str;
}
function replaceToEng(str) {
let replacer = {
"й": "q", "ц": "w", "у": "e", "к": "r", "е": "t", "н": "y", "г": "u",
"ш": "i", "щ": "o", "з": "p", "х": "[", "ъ": "]", "ф": "a", "ы": "s",
"в": "d", "а": "f", "п": "g", "р": "h", "о": "j", "л": "k", "д": "l",
"ж": ";", "э": "'", "я": "z", "ч": "x", "с": "c", "м": "v", "и": "b",
"т": "n", "ь": "m", "б": ",", "ю": ".",
".": "/", '"': '@', '№': '#', ';': '$', ':': '^', '?': '&', ',': '?',
};
for(let i=0; i < str.length; i++){
if(replacer[str[i]] != undefined){
str = str.replace(str[i], replacer[str[i]]);
}
}
return str;
}
function escapeRegExp(str) {
return str.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
}