From 6cb4a09a2c84279c2897e7b0bdbeb490e92f84af Mon Sep 17 00:00:00 2001 From: onezplpl Date: Sat, 3 Aug 2024 00:32:01 -0400 Subject: [PATCH] add more emojis --- emojis.svg | 65 ++++++++++++++++++++++++++++++++++++++++++------------ index.css | 7 ++++++ index.html | 5 ++--- index.js | 11 +++++---- 4 files changed, 67 insertions(+), 21 deletions(-) diff --git a/emojis.svg b/emojis.svg index b0f258c..7d52d15 100644 --- a/emojis.svg +++ b/emojis.svg @@ -22,15 +22,15 @@ inkscape:pageopacity="0.0" inkscape:pagecheckerboard="0" inkscape:deskcolor="#d1d1d1" - inkscape:zoom="2.2009868" - inkscape:cx="80.191302" - inkscape:cy="65.198027" + inkscape:zoom="3.1126654" + inkscape:cx="165.93496" + inkscape:cy="134.77196" inkscape:window-width="1860" inkscape:window-height="1005" inkscape:window-x="30" inkscape:window-y="45" inkscape:window-maximized="1" - inkscape:current-layer="doowie" /> + transform="translate(-2.060262,-6.634307)" /> diff --git a/index.css b/index.css index f48809a..7f1ec8a 100644 --- a/index.css +++ b/index.css @@ -109,4 +109,11 @@ svg.char.selected_true { input { display: block; margin: 10px; +} + +.inputs { + display: flex; + justify-content: center; + align-items: center; + flex-wrap: wrap; } \ No newline at end of file diff --git a/index.html b/index.html index 70b19c9..2deee30 100644 --- a/index.html +++ b/index.html @@ -14,9 +14,8 @@

Make your own Onezmoji! Work in progress...

More at the Zenoverse

- +
\ No newline at end of file diff --git a/index.js b/index.js index 0fc78d6..298e0f3 100644 --- a/index.js +++ b/index.js @@ -34,14 +34,14 @@ function main(init = false) { } } else { for (let char in charData) { - let p = document.createElement('p'); + let p = document.createElement('span'); p.textContent = char; - sec.appendChild(p); + document.querySelector('.inputs').appendChild(p); let input = document.createElement('input'); input.type = 'color'; input.id = 'color_' + char; input.value = getRandomColor(); - sec.appendChild(input); + document.querySelector('.inputs').appendChild(input); input.onchange = () => main(false); } } @@ -84,4 +84,7 @@ function main(init = false) { } } -window.onload = () => main(true); \ No newline at end of file +window.onload = () => { + main(true); + main(false); +} \ No newline at end of file