/*
# ==================================================================== #
# TITLE #
# Antimicrobial Resistance (AMR) Analysis #
# #
# SOURCE #
# https://gitlab.com/msberends/AMR #
# #
# LICENCE #
# (c) 2018-2020 Berends MS, Luz CF et al. #
# #
# This R package is free software; you can freely use and distribute #
# it for both personal and commercial purposes under the terms of the #
# GNU General Public License version 2.0 (GNU GPL-2), as published by #
# the Free Software Foundation. #
# #
# We created this package for both routine data analysis and academic #
# research and it was publicly released in the hope that it will be #
# useful, but it comes WITHOUT ANY WARRANTY OR LIABILITY. #
# Visit our website for more info: https://msberends.gitlab.io/AMR. #
# ==================================================================== #
*/
// Add updated Font Awesome 5.8.2 library
$('head').append('');
// Email template for new GitLab issues
//https://stackoverflow.com/a/33190494/4575331
//incoming+msberends-amr-9011429-5miwzuo1xo70wbz9r6fwv4dmg-issue@incoming.gitlab.com
$( document ).ready(function() {
// add SurveyMonkey
// $('body').append('');
// add link to survey at home sidebar
// $('.template-home #sidebar .list-unstyled:first').append('
');
// remove version label from header
$(".version.label").remove();
// redirect to GitLab
var url_old = window.location.href;
var url_new = url_old.replace("github", "gitlab");
if (url_old != url_new) {
window.location.replace(url_new);
}
// Replace 'Value' in manual to 'Returned value'
$(".template-reference-topic h2#value").text("Returned value");
// PR for 'R for Data Science' on How To pages
if ($(".template-article").length > 0) {
$('#sidebar').prepend(
'
');
// all links should open in new tab/window
$('footer').html($('footer').html().replace(/href/g, 'target="_blank" href'));
// doctoral titles of authors
function doct_tit(x) {
if (typeof(x) != "undefined") {
// authors
x = x.replace(/Author, maintainer/g, "Main developer");
x = x.replace(/Author, contributor/g, "Main contributor");
x = x.replace(/Author, thesis advisor/g, "Doctoral advisor");
x = x.replace("Alex", "Prof. Dr. Alex");
x = x.replace("Bhanu", "Prof. Dr. Bhanu");
x = x.replace("Casper", "Prof. Dr. Casper");
x = x.replace("Corinna", "Dr. Corinna");
// others
x = x.replace("Bart", "Dr. Bart");
x = x.replace("Sofia", "Dr. Sofia");
x = x.replace("Dennis", "Dr. Dennis");
x = x.replace("Judith", "Dr. Judith");
}
return(x);
}
$(".template-authors").html(doct_tit($(".template-authors").html()));
$(".template-citation-authors").html(doct_tit($(".template-citation-authors").html()));
$(".developers").html(doct_tit($(".developers").html()));
// $("footer").html(doct_tit($("footer").html()));
// Edit title of manual
$('.template-reference-index h1').text('Manual');
});
$('head').append("");