From b0fc4dee3d929f474aa7cbb1e10fbd15fb734107 Mon Sep 17 00:00:00 2001 From: WubzyGD Date: Sat, 11 Dec 2021 19:51:01 -0700 Subject: [PATCH] abandon that idea because robbery is bad --- scripts/contextmenu/newfolder.js | 1 + scripts/modal/exitbtn.js | 28 ------------ styles/modal.css | 75 -------------------------------- 3 files changed, 1 insertion(+), 103 deletions(-) delete mode 100644 scripts/modal/exitbtn.js diff --git a/scripts/contextmenu/newfolder.js b/scripts/contextmenu/newfolder.js index 5786e70..9902001 100644 --- a/scripts/contextmenu/newfolder.js +++ b/scripts/contextmenu/newfolder.js @@ -38,6 +38,7 @@ module.exports = () => { conf.onclick = () => { try { input.value.trim(); + if (!input.value.length) {return;} if (fs.existsSync(path.join(window.kade.cpath, input.value))) { if (!input.value.match(/^.+\(\d\)$/gm)) {input.value += ' (1)';} else { diff --git a/scripts/modal/exitbtn.js b/scripts/modal/exitbtn.js deleted file mode 100644 index 308a1c0..0000000 --- a/scripts/modal/exitbtn.js +++ /dev/null @@ -1,28 +0,0 @@ -module.exports = (parent, btnID) => { - let wr = document.createElement('div'); - wr.className = 'exit-wrapper'; - parent.appendChild(wr); - let btn = document.createElement('a'); - btn.className = 'exit-button'; - btn.id = btnID; - wr.appendChild(btn) - let ind = document.createElement('div'); - ind.className = 'exit-in'; - btn.appendChild(ind); - let inbl1 = document.createElement('div'); - inbl1.className = 'exit-button-block'; - ind.appendChild(inbl1); - let inbl2 = document.createElement('div'); - inbl2.className = 'exit-button-block'; - ind.appendChild(inbl2); - let outd = document.createElement('div'); - outd.className = 'exit-out'; - btn.appendChild(outd); - let outbl1 = document.createElement('div'); - outbl1.className = 'exit-button-block'; - outd.appendChild(outbl1); - let outbl2 = document.createElement('div'); - outbl2.className = 'exit-button-block'; - outd.appendChild(outbl2); - return wr; -}; \ No newline at end of file diff --git a/styles/modal.css b/styles/modal.css index b9760d3..ab039dc 100644 --- a/styles/modal.css +++ b/styles/modal.css @@ -60,78 +60,3 @@ z-index: 2; } - -/* robbed this shit from some website somewhere. i'm not this cool. - * https://codepen.io/maneeshc/pen/pPxKQm - * that's the codepen i robbed it from */ - -.exit-wrapper { - width: 100vw; - height: 100vh; - display: flex; - align-items: center; - justify-content: center; -} - -.exit-button { - display: block; - width: 40px; - height: 40px; - position: relative; - overflow: hidden; -} -.exit-button > div { - position: relative; -} -.exit-button-block { - width: 40px; - height: 20px; - position: relative; - overflow: hidden; -} -.exit-button-block:before, .exit-button-block:after { - content: ""; - position: absolute; - bottom: 0; - left: calc(55% - 4px); - display: block; - width: 4px; - height: 25px; - transform-origin: bottom center; - background: white; - transition: all ease-out 280ms; -} -.exit-button-block:last-of-type { - transform: rotate(180deg); -} -.exit-button .exit-in .exit-button-block:before { - transition-delay: 280ms; - transform: translateX(20px) translateY(-20px) rotate(45deg); -} -.exit-button .exit-in .exit-button-block:after { - transition-delay: 280ms; - transform: translateX(-22px) translateY(-22px) rotate(-45deg); -} -.exit-button .exit-out { - position: absolute; - top: 0; - left: 0; -} -.exit-button .exit-out .exit-button-block:before { - transform: translateX(-5px) translateY(5px) rotate(45deg); -} -.exit-button .exit-out .exit-button-block:after { - transform: translateX(5px) translateY(5px) rotate(-45deg); -} -.exit-button:hover .exit-in .exit-button-block:before { - transform: translateX(-5px) translateY(5px) rotate(45deg); -} -.exit-button:hover .exit-in .exit-button-block:after { - transform: translateX(5px) translateY(5px) rotate(-45deg); -} -.exit-button:hover .exit-out .exit-button-block:before { - transform: translateX(-20px) translateY(20px) rotate(45deg); -} -.exit-button:hover .exit-out .exit-button-block:after { - transform: translateX(20px) translateY(20px) rotate(-45deg); -} \ No newline at end of file