|
@ -50,44 +50,21 @@ |
|
|
</ul> |
|
|
</ul> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
<div class="main container"> |
|
|
|
|
|
|
|
|
<div class="main container"> |
|
|
|
|
|
|
|
|
<div class="row align-center" id="searchBarTop"> |
|
|
|
|
|
<nav class="navbar navbar-light bg-light justify-content-between"> |
|
|
|
|
|
<a class="navbar-brand">Create Graph</a> |
|
|
|
|
|
<form class="form-inline"> |
|
|
|
|
|
<input class="form-control mr-sm-2" id='txtUsername' type="search" placeholder="GitHub Username" aria-label="Search"> |
|
|
|
|
|
<button class="btn btn-outline-success my-2 my-sm-0" onclick='fetchUserInput()' type='button'>Look Up</button> |
|
|
|
|
|
</form> |
|
|
|
|
|
</nav> |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<div class="row"> |
|
|
|
|
|
<div class="col-md-8 col-12"> |
|
|
|
|
|
<div id="graphLoading"></div> |
|
|
|
|
|
<div id="myGraph" class="w-100"></div> |
|
|
|
|
|
<pre id="eventSpan"></pre> |
|
|
|
|
|
|
|
|
<div class="row"> |
|
|
|
|
|
<div class="col-md-8 col-12"> |
|
|
|
|
|
<h2 id="graphLabel"></h2> |
|
|
|
|
|
<div id="myGraph" class="w-100"></div> |
|
|
|
|
|
<pre id="eventSpan"></pre> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="col-md-4 col-12 w-100"> |
|
|
|
|
|
<div id="profileGen"></div> |
|
|
|
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
<div class="col-md-4 col-12 w-100"> |
|
|
|
|
|
<div id="profileGen"></div> |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
</body> |
|
|
|
|
|
|
|
|
|
|
|
<script> |
|
|
<script> |
|
|
|
|
|
|
|
|
document.addEventListener("keydown", event => { |
|
|
|
|
|
if (event.key === "Enter") { |
|
|
|
|
|
fetchUserInput(); |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
function fetchUserInput() |
|
|
|
|
|
{ |
|
|
|
|
|
const inputedName = $("#txtUsername").val(); |
|
|
|
|
|
createGraphs(inputedName); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
function createGraphs(username) |
|
|
function createGraphs(username) |
|
|
{ |
|
|
{ |
|
|
options.width = $("#myGraph").width() + "px"; |
|
|
options.width = $("#myGraph").width() + "px"; |
|
|