refactoring

This commit is contained in:
Frank Knoll
2024-07-17 16:33:16 +02:00
parent 5adb52c0e0
commit 44ac5f895a
4 changed files with 63 additions and 89 deletions

View File

@@ -5,7 +5,6 @@
<meta content="width=device-width, initial-scale=1.0" name="viewport"/> <meta content="width=device-width, initial-scale=1.0" name="viewport"/>
<title>Pfizer Vaccine Distribution by ZIP Code</title> <title>Pfizer Vaccine Distribution by ZIP Code</title>
<link href="https://cdn.datatables.net/1.13.1/css/jquery.dataTables.css" rel="stylesheet" type="text/css"/> <link href="https://cdn.datatables.net/1.13.1/css/jquery.dataTables.css" rel="stylesheet" type="text/css"/>
<link href="batchCodeTable.css" rel="stylesheet" type="text/css"/>
<link href="forkMeOnGitHub.css" rel="stylesheet" type="text/css"/> <link href="forkMeOnGitHub.css" rel="stylesheet" type="text/css"/>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script charset="utf8" src="https://cdn.datatables.net/1.13.1/js/jquery.dataTables.min.js" type="text/javascript"></script> <script charset="utf8" src="https://cdn.datatables.net/1.13.1/js/jquery.dataTables.min.js" type="text/javascript"></script>

View File

@@ -1,13 +0,0 @@
.chartWithSlider {
display: flex;
flex-wrap: nowrap;
flex-direction: row;
}
.chartWithSlider .chartContainer {
flex: 95%;
}
.chartWithSlider .sliderContainer {
flex: 5%;
}

View File

@@ -1,35 +1,41 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="utf-8"/> <meta charset="utf-8" />
<meta content="width=device-width, initial-scale=1.0" name="viewport"/> <meta content="width=device-width, initial-scale=1.0" name="viewport" />
<title>Batch Codes of Coronavirus 2019 Vaccines</title> <title>Batch Codes of Coronavirus 2019 Vaccines</title>
<!-- Google tag (gtag.js) --> <!-- Google tag (gtag.js) -->
<script async="" src="https://www.googletagmanager.com/gtag/js?id=G-ERHYDH4P64"></script> <script async="" src="https://www.googletagmanager.com/gtag/js?id=G-ERHYDH4P64"></script>
<script> <script>
window.dataLayer = window.dataLayer || []; window.dataLayer = window.dataLayer || [];
function gtag() { dataLayer.push(arguments); } function gtag() { dataLayer.push(arguments); }
gtag('js', new Date()); gtag('js', new Date());
gtag('config', 'G-ERHYDH4P64'); gtag('config', 'G-ERHYDH4P64');
</script> </script>
<link href="https://cdn.datatables.net/1.13.1/css/jquery.dataTables.css" rel="stylesheet" type="text/css"/> <link href="https://cdn.datatables.net/1.13.1/css/jquery.dataTables.css" rel="stylesheet" type="text/css" />
<link href="batchCodeTable.css" rel="stylesheet" type="text/css"/> <link href="forkMeOnGitHub.css" rel="stylesheet" type="text/css" />
<link href="forkMeOnGitHub.css" rel="stylesheet" type="text/css"/> <script crossorigin="anonymous"
<script crossorigin="anonymous" integrity="sha512-T5Bneq9hePRO8JR0S/0lQ7gdW+ceLThvC80UjwkMRz+8q+4DARVZ4dqKoyENC7FcYresjfJ6ubaOgIE35irf4w==" referrerpolicy="no-referrer" src="https://cdnjs.cloudflare.com/ajax/libs/noUiSlider/15.5.1/nouislider.min.js"></script> integrity="sha512-T5Bneq9hePRO8JR0S/0lQ7gdW+ceLThvC80UjwkMRz+8q+4DARVZ4dqKoyENC7FcYresjfJ6ubaOgIE35irf4w=="
<link crossorigin="anonymous" href="https://cdnjs.cloudflare.com/ajax/libs/noUiSlider/15.5.1/nouislider.css" integrity="sha512-MKxcSu/LDtbIYHBNAWUQwfB3iVoG9xeMCm32QV5hZ/9lFaQZJVaXfz9aFa0IZExWzCpm7OWvp9zq9gVip/nLMg==" referrerpolicy="no-referrer" rel="stylesheet"/> referrerpolicy="no-referrer"
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script> src="https://cdnjs.cloudflare.com/ajax/libs/noUiSlider/15.5.1/nouislider.min.js"></script>
<script charset="utf8" src="https://cdn.datatables.net/1.13.1/js/jquery.dataTables.min.js" type="text/javascript"></script> <link crossorigin="anonymous" href="https://cdnjs.cloudflare.com/ajax/libs/noUiSlider/15.5.1/nouislider.css"
<script src="https://cdn.jsdelivr.net/npm/chart.js@4.2.0/dist/chart.umd.min.js"></script> integrity="sha512-MKxcSu/LDtbIYHBNAWUQwfB3iVoG9xeMCm32QV5hZ/9lFaQZJVaXfz9aFa0IZExWzCpm7OWvp9zq9gVip/nLMg=="
<script src="./Utils.js"></script> referrerpolicy="no-referrer" rel="stylesheet" />
<script src="./UIUtils.js"></script> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script src="./UrlUtils.js"></script> <script charset="utf8" src="https://cdn.datatables.net/1.13.1/js/jquery.dataTables.min.js"
<script src="./DataTablesFilter.js"></script> type="text/javascript"></script>
<script src="./ColumnSearch.js"></script> <script src="https://cdn.jsdelivr.net/npm/chart.js@4.2.0/dist/chart.umd.min.js"></script>
<script src="./BatchCodeTableInitializer.js"></script> <script src="./Utils.js"></script>
<script src="./BatchcodeByCountryBarChartView.js"></script> <script src="./UIUtils.js"></script>
<script src="./BatchcodeByCountryBarChart.js"></script> <script src="./UrlUtils.js"></script>
<script> <script src="./DataTablesFilter.js"></script>
<script src="./ColumnSearch.js"></script>
<script src="./BatchCodeTableInitializer.js"></script>
<script src="./BatchcodeByCountryBarChartView.js"></script>
<script src="./BatchcodeByCountryBarChart.js"></script>
<script>
$(document).ready(function () { $(document).ready(function () {
const urlSearchParams = new URLSearchParams(window.location.search); const urlSearchParams = new URLSearchParams(window.location.search);
new BatchCodeTableInitializer().initialize( new BatchCodeTableInitializer().initialize(
@@ -41,46 +47,42 @@
}); });
</script> </script>
</head> </head>
<body> <body>
<h1>Batch Codes of Coronavirus 2019 Vaccines</h1> <h1>Batch Codes of Coronavirus 2019 Vaccines</h1>
<table class="display" id="batchCodeTable"> <table class="display" id="batchCodeTable">
<thead> <thead>
<tr> <tr>
<th>Batch</th> <th>Batch</th>
<th>Adverse Reaction Reports</th> <th>Adverse Reaction Reports</th>
<th>Deaths</th> <th>Deaths</th>
<th>Disabilities</th> <th>Disabilities</th>
<th>Life-Threatening Illnesses</th> <th>Life-Threatening Illnesses</th>
<th>Hospitalizations</th> <th>Hospitalizations</th>
<th>Company</th> <th>Company</th>
<th>Severe reports</th> <th>Severe reports</th>
<th>Lethality</th> <th>Lethality</th>
<th>Countries</th> <th>Countries</th>
</tr> </tr>
</thead> </thead>
</table> </table>
<footer> <footer>
<dl> <dl>
<dt>Data Source:</dt> <dt>Data Source:</dt>
<dd><a href="https://vaers.hhs.gov/data/datasets.html" target="_blank">Vaccine Adverse Event Reporting System <dd><a href="https://vaers.hhs.gov/data/datasets.html" target="_blank">Vaccine Adverse Event Reporting System
(VAERS)</a></dd> (VAERS)</a></dd>
<dt>Last updated:</dt> <dt>Last updated:</dt>
<dd id="last_updated">July 05, 2024</dd> <dd id="last_updated">July 05, 2024</dd>
</dl> </dl>
<span id="forkongithub"><a href="https://github.com/KnollFrank/HowBadIsMyBatch" target="_blank">Fork me on <span id="forkongithub"><a href="https://github.com/KnollFrank/HowBadIsMyBatch" target="_blank">Fork me on
GitHub</a></span> GitHub</a></span>
<div class="clearfix"></div> <div class="clearfix"></div>
</footer> </footer>
<template id="template-chartWithSlider"> <template id="template-chartWithSlider">
<div class="chartWithSlider"> <div class="chartContainer">
<div class="chartContainer"> <canvas class="canvas"></canvas>
<canvas class="canvas"></canvas> </div>
</div> </template>
<!-- FK-TODO: remove sliderContainer and slider -->
<div class="sliderContainer">
<div class="slider"></div>
</div>
</div>
</template>
</body> </body>
</html> </html>

View File

@@ -4906,20 +4906,6 @@ table thead .checkbox.radio { margin-top:-7px;margin-top:-21px; }
/*prevent datatables overflowing its container*/ /*prevent datatables overflowing its container*/
} }
.chartWithSlider {
display: flex;
flex-wrap: nowrap;
flex-direction: row;
}
.chartWithSlider .chartContainer {
flex: 95%;
}
.chartWithSlider .sliderContainer {
flex: 5%;
}
.bar { .bar {
height: 3px; height: 3px;
background-color: #1a73e8; background-color: #1a73e8;