Skip to content

Commit

Permalink
Revert "#170: upgrade Chart.js libraries"
Browse files Browse the repository at this point in the history
  • Loading branch information
mattStorer authored Feb 7, 2024
1 parent cae6b65 commit c59a0e8
Show file tree
Hide file tree
Showing 747 changed files with 74,291 additions and 39,106 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,7 @@ public String view(HttpSession session, Model model) {
model.addAttribute("hasOtherGoals", goalService.hasAnyLocalNonBPGoals(sessionId));
model.addAttribute("pageStyles", new String[] { "goals.css" });
model.addAttribute("pageScripts", new String[] { "goals.js?v=1" });
model.addAttribute("pageNodeScripts", new String[] {
"inputmask/dist/jquery.inputmask.js",
"inputmask/dist/bindings/inputmask.binding.js"
});
model.addAttribute("pageNodeScripts", new String[] { "jquery.inputmask.js", "bindings/inputmask.binding.js" });

auditService.doAudit(sessionId, AuditLevel.INFO, "visited goals page");

Expand Down
16 changes: 2 additions & 14 deletions src/main/java/edu/ohsu/cmp/coach/controller/HomeController.java
Original file line number Diff line number Diff line change
Expand Up @@ -89,20 +89,8 @@ public String view(HttpSession session, Model model,
model.addAttribute("sessionEstablished", true);
model.addAttribute("loessBandwidth", bandwidthOverride == null ? -1:bandwidthOverride);
model.addAttribute("pageStyles", new String[] { "home.css?v=4", "recommendations.css?v=1" });
model.addAttribute("pageNodeScripts", new String[] {
"inputmask/dist/jquery.inputmask.js",
"inputmask/dist/bindings/inputmask.binding.js",
"chart.js/dist/chart.umd.js",
"chartjs-adapter-date-fns/dist/chartjs-adapter-date-fns.bundle.js",
"chartjs-plugin-annotation/dist/chartjs-plugin-annotation.min.js"
});
model.addAttribute("pageScripts", new String[] {
"science.js/science.v1.js",
"science.js/lib/d3/d3.js",
"home.js?v=2",
"bpchart.js",
"recommendations.js?v=2"
});
model.addAttribute("pageNodeScripts", new String[] { "jquery.inputmask.js", "bindings/inputmask.binding.js" });
model.addAttribute("pageScripts", new String[] { "science.js/science.v1.js", "science.js/lib/d3/d3.js", "home.js?v=2", "recommendations.js?v=2" });
model.addAttribute("patient", workspace.getPatient());
model.addAttribute("bpGoal", goalService.getCurrentBPGoal(sessionId));
model.addAttribute("bpGoalUpdated", workspace.getBpGoalUpdated());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,7 @@ public String view(HttpSession session, Model model) throws DataException {
model.addAttribute("homeReadings", homeReadings);
model.addAttribute("pageStyles", new String[] { "vitals.css" });
model.addAttribute("pageScripts", new String[] { "vitals.js?v=1", "form.js" });
model.addAttribute("pageNodeScripts", new String[] {
"inputmask/dist/jquery.inputmask.js",
"inputmask/dist/bindings/inputmask.binding.js"
});
model.addAttribute("pageNodeScripts", new String[] { "jquery.inputmask.js", "bindings/inputmask.binding.js" });

auditService.doAudit(session.getId(), AuditLevel.INFO, "visited vitals page");

Expand Down
10 changes: 5 additions & 5 deletions src/main/resources/static/js/coach.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ function loadScript(src, callback) {
document.head.appendChild(script);
}

// function isInternetExplorer() {
// // adapted from https://www.scratchcode.io/how-to-detect-ie-browser-in-javascript/
// let isIE = /*@cc_on!@*/false || !!document.documentMode;
// return isIE || navigator.userAgent.indexOf("MSIE") > 0;
// }
function isInternetExplorer() {
// adapted from https://www.scratchcode.io/how-to-detect-ie-browser-in-javascript/
let isIE = /*@cc_on!@*/false || !!document.documentMode;
return isIE || navigator.userAgent.indexOf("MSIE") > 0;
}

// function loadScript(document, url) {
// console.log("loading script " + url);
Expand Down
34 changes: 11 additions & 23 deletions src/main/resources/static/node_modules/.package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

This file was deleted.

79 changes: 0 additions & 79 deletions src/main/resources/static/node_modules/@kurkle/color/README.md

This file was deleted.

Loading

0 comments on commit c59a0e8

Please sign in to comment.