diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a126b31 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +*.sublime-* diff --git a/html/css/app.css b/html/css/app.css new file mode 100644 index 0000000..12e315e --- /dev/null +++ b/html/css/app.css @@ -0,0 +1,56 @@ +@import url('https://fonts.googleapis.com/css?family=Roboto:400,700&subset=cyrillic'); + +* { + padding: 0; margin: 0; outline: 0; + font-family: "Roboto"; + font-size: 1.1rem; +} + +*::selection { + color: #fb4b4b; +} + +body { + background-color: #ffffff; +} + +div.wrap { + max-width: 800px; + margin: 0 auto; +} + +div.header { + background-color: #fb4b4b; + color: #ffffff; + padding: 16px; +} + +div.content { + margin: 16px 0; +} + +button, textarea { + display: block; + box-sizing: border-box; + border: 1px solid #fb4b4b; + width: 100%; + padding: 8px; +} + +button { + color: #000000; + background-color: #fb4b4b; + border-top: 0; + border-bottom: 0; +} +button:hover { + color: #ffffff; +} + +textarea { + + resize: none; +} +textarea:disabled { + background-color: #ffffff; +} diff --git a/html/index.html b/html/index.html new file mode 100644 index 0000000..d75beb1 --- /dev/null +++ b/html/index.html @@ -0,0 +1,23 @@ + + + + + + chola + + + +
+
Change of Layout
+
+
+
+ + + +
+
+ + + + diff --git a/html/js/app.js b/html/js/app.js new file mode 100644 index 0000000..766f989 --- /dev/null +++ b/html/js/app.js @@ -0,0 +1,23 @@ +function layoutReplace() +{ + keys = { + "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":"ь", ",":"б", ".":"ю", "/":"." + }; + + var dat = document.getElementById("one").value + var res = document.getElementById("two") + let text = null + + console.log(dat) + + + text = dat.replace(/[A-z/,.;\'\]\[]/g, function(x) { + return x == x.toLowerCase() ? keys[ x ] : keys[ x.toLowerCase() ].toUpperCase(); + }); + + res.value = text +}