From 9ab91f3fcf50a9eacc372bdf362b5dd1f7e58a80 Mon Sep 17 00:00:00 2001 From: funix Date: Mon, 30 Aug 2021 10:09:48 +0200 Subject: [PATCH] open/clse --- scripts/App.js | 12 ++---------- styles/style.css | 10 +++++----- 2 files changed, 7 insertions(+), 15 deletions(-) diff --git a/scripts/App.js b/scripts/App.js index 47fa840..374001b 100644 --- a/scripts/App.js +++ b/scripts/App.js @@ -37,7 +37,7 @@ $(document).ready(function(){ // generate divs Object.values(corpi).forEach(corpus => { - $('#boxes' ).append(`

${corpus['title']}

${corpus['content']}

`) + $('#boxes' ).append(`

${corpus['title']}

${corpus['content']}

`) $("#icons").append(``) }); @@ -110,16 +110,8 @@ $(document).ready(function(){ // close window $(".closable").click(function() { - $( this ).fadeOut(); + $( this ).parent().fadeOut(); }); - // open window - // $( ".draggable" ).each(function() { - // let idid = $( this ).attr('id') - // // console.log(idid) - // $("#icons").append(``) - // }); - - }); diff --git a/styles/style.css b/styles/style.css index e44b36c..a631e46 100644 --- a/styles/style.css +++ b/styles/style.css @@ -37,7 +37,7 @@ button{ z-index: 2; cursor: grab; border: 2px white solid; - background: black + background: black; } .draggable p{ @@ -73,15 +73,15 @@ button{ } .closable{ - + position: absolute; + top: 0; + right: 0; } .closable button{ width: 30px; height: 30px; - position: absolute; - top: 0; - right: 0; + }