diff --git a/index.html b/index.html index 22eae71..57b5e78 100644 --- a/index.html +++ b/index.html @@ -895,87 +895,91 @@

Selected Data Points

} - // Updated addNewPlot function function addNewPlot(config = {}) { plotCounter++; const plotId = `plot-${plotCounter}`; let plotHTML = ` -
- -
- -
- -
- - - -
+ + + + + + +
diff --git a/snipe-explore.js b/snipe-explore.js index cbd1eec..71881b9 100644 --- a/snipe-explore.js +++ b/snipe-explore.js @@ -405,4 +405,4 @@ function showModal(title, message) { modal.style.display = 'none'; } }; -} \ No newline at end of file +} diff --git a/styles.css b/styles.css index a12a928..0185745 100644 --- a/styles.css +++ b/styles.css @@ -1077,4 +1077,262 @@ tr:nth-child(even) { .floating-search-button:hover .search-input { width: 200px; opacity: 1; -} \ No newline at end of file +} + +/* Updated CSS for Filter Modal */ + +#filter-modal { + display: none; + /* Hidden by default */ + position: fixed; + z-index: 1002; + left: 0; + top: 0; + width: 100%; + height: 100%; + backdrop-filter: blur(5px); + background-color: rgba(0, 0, 0, 0.5); + align-items: center; + justify-content: center; + overflow: auto; +} + +#filter-modal .modal-content { + background: #fff; + padding: 20px; + border-radius: 10px; + width: 80%; + max-width: 700px; + position: relative; +} + +#filter-modal .close-button { + position: absolute; + top: 15px; + right: 20px; + font-size: 28px; + font-weight: bold; + cursor: pointer; +} + +.filter-group { + border: 1px solid #ccc; + padding: 15px; + border-radius: 8px; + margin-bottom: 10px; + background-color: #f9f9f9; +} + +.filter-group .form-row { + display: flex; + align-items: center; + gap: 10px; +} + +.filter-group .form-control { + flex: 1; +} + +.remove-filter-group { + background-color: #e74c3c; + color: #fff; + border: none; + padding: 5px 10px; + border-radius: 4px; + cursor: pointer; +} + +.remove-filter-group:hover { + background-color: #c0392b; +} + +#add-filter-group { + background-color: #3498db; + color: #fff; + border: none; + padding: 8px 12px; + border-radius: 4px; + cursor: pointer; + margin-bottom: 15px; +} + +#add-filter-group:hover { + background-color: #2980b9; +} + +#apply-filters, #reset-filters { + background-color: #2ecc71; + color: #fff; + border: none; + padding: 10px 15px; + border-radius: 4px; + cursor: pointer; + margin-right: 10px; +} + +#apply-filters:hover, #reset-filters:hover { + background-color: #27ae60; +} + + +/* Styles for Loading Modal */ +#loading-modal { + display: none; /* Hidden by default */ + position: fixed; + z-index: 1000; /* Ensure it's on top */ + left: 0; + top: 0; + width: 100%; + height: 100%; + overflow: auto; + background-color: rgba(0,0,0,0.5); /* Semi-transparent background */ +} + +#loading-modal .modal-content { + position: absolute; + top: 50%; + left: 50%; + transform: translate(-50%, -50%); + background-color: #fff; + padding: 20px; + border-radius: 8px; + text-align: center; +} + +.spinner { + border: 8px solid #f3f3f3; /* Light grey */ + border-top: 8px solid #3498db; /* Blue */ + border-radius: 50%; + width: 60px; + height: 60px; + animation: spin 2s linear infinite; + margin: 0 auto 10px auto; +} + +@keyframes spin { + 0% { transform: rotate(0deg); } + 100% { transform: rotate(360deg); } +} + +/* Styles for Filter Modal */ +#filter-modal .modal-content { + max-height: 80vh; + overflow-y: auto; + width: 500px; /* Adjust width as needed */ + padding: 20px; + position: relative; + background-color: #fff; + border-radius: 8px; +} + +/* Filter Group Layout */ +.filter-group { + display: flex; + flex-direction: column; + align-items: center; + gap: 10px; + position: relative; +} + +/* Logic Selector Styling */ +.logic-div { + text-align: center; + width: 100%; +} + +.logic-select { + width: 150px; + margin-bottom: 10px; +} + +/* Condition Div Styling */ +.condition-div { + width: 100%; + display: flex; + flex-direction: column; + gap: 10px; + align-items: center; +} + +/* Remove Button Styling */ +.filter-group .remove-filter-group { + background: none; + border: none; + color: #e74c3c; + cursor: pointer; + font-size: 16px; + position: absolute; + top: 10px; + right: 10px; +} + +/* Action Buttons Styling */ +.button { + margin-top: 10px; + margin-right: 10px; +} + + + +.slider-inputs { + display: flex; + align-items: center; + gap: 10px; + width: 100%; +} + +.slider-inputs input[type="number"] { + width: 80px; + padding: 5px; + font-size: 0.9rem; + border: 1px solid #ccc; + border-radius: 4px; +} + + +/* Styles specific to the filter modal slider */ +.filter-group .slider-wrapper .filter-modal-slider { + flex-grow: 1; + margin-right: 10px; +} + +.filter-group .slider-wrapper .filter-modal-slider .noUi-target { + width: 100%; +} + +.filter-group .slider-wrapper .filter-modal-slider .noUi-horizontal { + height: 10px; /* Adjust as needed */ +} + + + +#filter-modal .range-slider { + width: 100%; +} + +#filter-modal .slider-wrapper { + width: 100%; +} + + +.tags-container { + display: flex; + flex-wrap: wrap; + margin-top: 5px; +} + +.tag { + display: inline-flex; + align-items: center; + padding: 5px; + margin: 2px; + background-color: #007bff; + color: #fff; + border-radius: 3px; + font-size: 0.9em; +} + +.tag span { + cursor: pointer; + margin-left: 5px; +}