Created
March 12, 2011 19:50
-
-
Save jophde/867502 to your computer and use it in GitHub Desktop.
prototype for dashboard
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#dashboard { | |
border: 3px solid; | |
width: auto; | |
float:left; | |
} | |
#incoming { | |
border: 2px solid; | |
padding: 10px 10px 10px 10px; | |
margin: 10px 5px 10px 10px; | |
width: 200px; | |
height:400px; | |
overflow:auto; | |
float:left; | |
text-align:center; | |
} | |
#outgoing { | |
border: 2px solid; | |
padding: 10px 10px 10px 10px; | |
margin: 10px 10px 10px 5px; | |
width: 200px; | |
height:400px; | |
overflow:auto; | |
float:left; | |
text-align:center; | |
} | |
.response { | |
width:auto; | |
overflow:auto; | |
margin: 1px 0px 1px 0px; | |
padding: 5px 5px 5px 5px; | |
text-align:center; | |
border:1px solid; | |
} | |
.add { | |
text-align: center; | |
} | |
.remove { | |
text-align: center; | |
} | |
#reply { | |
padding: 10px 10px 10px 10px; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Dashboard Prototype</title> | |
<script src="jquery.js"></script> | |
<script src="dashboard.js"></script> | |
<link rel="stylesheet" type="text/css" href="dashboard.css" /> | |
</head> | |
<body> | |
<div id="dashboard"> | |
<center><h1>Replysome</h1></center> | |
<div id="incoming"> | |
<h1>Incoming</h1> | |
<div class="response"> | |
<h3>Alex</h3> | |
<p>Alex's Message...</p> | |
<input type="button" class="move" value="Move" /> | |
</div> | |
<div class="response"> | |
<h3>Beth</h3> | |
<p>Beth's Message...</p> | |
<input type="button" class="move" value="Move" /> | |
</div> | |
<div class="response"> | |
<h3>Chelsea</h3> | |
<p>Chelsea's Message...</p> | |
<input type="button" class="move" value="Move" /> | |
</div> | |
<div class="response"> | |
<h3>Devon</h3> | |
<p>Devon's Message...</p> | |
<input type="button" class="move" value="Move" /> | |
</div> | |
</div> | |
<div id="outgoing"> | |
<h1>Outgoing</h1> | |
<!--Response is moved here to be answered--> | |
<div class="response"> | |
<h3>Erika</h3> | |
<p>Erika's Message...</p> | |
<input type="button" class="move" value="Move" /> | |
</div> | |
</div> | |
<div id="reply"> | |
<center><input type="submit" value="Reply" /><input type="text" size="30" /></center> | |
</div> | |
</div> | |
</body> | |
</html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(document).ready(function () { | |
$(".move").click(function () { | |
$(this).closest("div.response").hide(function () { | |
if ($(this).parent().attr("id") === "incoming") { | |
$(this).appendTo("div#outgoing"); | |
} | |
else if ($(this).parent().attr("id") === "outgoing"){ | |
$(this).appendTo("div#incoming"); | |
} | |
else { | |
return false; | |
} | |
$(this).show(); | |
}); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment