Skip to content

Commit

Permalink
Merge branch 'main' into deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
tnaccarato committed Aug 12, 2024
2 parents 67e0a28 + 1617ce7 commit fb6a174
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 6 deletions.
4 changes: 2 additions & 2 deletions vis_phewas/static/mainapp/css/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ html, body, .container-fluid {

.col-md-6.right-column {
padding-right: 0;
padding-left: 1%;
padding-left: 0.5%;
width: 0; /* Hidden initially */
transition: width 0.5s ease; /* Smooth transition for width change */
}
Expand Down Expand Up @@ -89,7 +89,7 @@ body {
}

.filter-group {
margin-bottom: 10px;
margin-bottom: 0;
}

.filter-group label {
Expand Down
5 changes: 5 additions & 0 deletions vis_phewas/static/mainapp/js/FilterManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,12 @@ export class FilterManager {
const filterContainer = document.querySelector(".toolbar-wrapper");
filterContainer.style.display = "block";
const filterBody = document.querySelector(".toolbar");
const chevron = document.querySelector(".toggle-button .fa-chevron-down");
filterBody.style.display = "block";
// Ensure chevron is pointing down
const isFilterBodyVisible = filterBody.style.display === "block";
chevron.classList.toggle("up", !isFilterBodyVisible);
chevron.classList.toggle("down", isFilterBodyVisible);
// Adjust the sigma container height
this.adjustSigmaContainerHeight();
// Check if the maximum number of filters has been reached
Expand Down
5 changes: 3 additions & 2 deletions vis_phewas/static/mainapp/js/GraphHelper.js
Original file line number Diff line number Diff line change
Expand Up @@ -217,15 +217,16 @@ class GraphHelper {
.then((response) => response.json())
.then((data) => {
// Create a header for the diseases
const diseases = data.diseases;
const diseaseCount = diseases.length;
const header = document.createElement("h3");
header.textContent = `Diseases for ${formatCategoryString(category)}`;
header.innerHTML = `<i>${diseaseCount}</i> Diseases for ${formatCategoryString(category)}`;
header.style.alignSelf = "center";
infoContainer.appendChild(header);
// Create a table for the diseases for the category
const table = document.createElement("table");
table.className =
"table table-striped table-bordered table-hover table-sm";
const diseases = data.diseases;

const thead = document.createElement("thead");
thead.innerHTML = `<tr><th>Disease</th></tr>`;
Expand Down
3 changes: 1 addition & 2 deletions vis_phewas/static/mainapp/js/GraphManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -269,8 +269,7 @@ class GraphManager {

// Create a close button for the info container
const closeButton = document.createElement("button");
closeButton.className = "btn btn-danger";
closeButton.textContent = "X";
closeButton.className = "btn-close";
closeButton.onclick = closeInfoContainer(
// Call the closeInfoContainer function
this.adjustSigmaContainerHeight,
Expand Down

0 comments on commit fb6a174

Please sign in to comment.