Skip to content

Commit

Permalink
Refactored code
Browse files Browse the repository at this point in the history
  • Loading branch information
milospp committed Dec 10, 2024
1 parent a5570c5 commit 486e5da
Show file tree
Hide file tree
Showing 8 changed files with 9 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -188,8 +188,7 @@ var i18nStringsUriRdf = {
};
</script>

${stylesheets.add('<link rel="stylesheet" href="${urls.base}/bootstrap-5.3.2/css/bootstrap.min.css" />',
'<link rel="stylesheet" href="${urls.base}/css/individual/individual.css" />',
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/css/individual/individual.css" />',
'<link rel="stylesheet" href="${urls.base}/css/individual/individual-vivo.css" />',
'<link rel="stylesheet" href="${urls.base}/css/individual/individual-2column-view.css" />',
'<link rel="stylesheet" href="${urls.base}/js/jquery-ui/css/smoothness/jquery-ui-1.12.1.css" />')}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -257,8 +257,7 @@ ${headScripts.add('<script type="text/javascript" src="${urls.base}/js/tiny_mce/
'<script type="text/javascript" src="${urls.base}/js/json2.js"></script>',
'<script type="text/javascript" src="${urls.base}/js/jquery_plugins/jquery.truncator.js"></script>',
'<script type="text/javascript" src="${urls.base}/js/tooltip/tooltip-utils.js"></script>',
'<script type="text/javascript" src="${urls.base}/js/tooltip/popper.min.js"></script>',
'<script src="${urls.base}/bootstrap-5.3.2/js/bootstrap.min.js"></script>')}
'<script type="text/javascript" src="${urls.base}/js/tooltip/popper.min.js"></script>')}

${scripts.add('<script async type="text/javascript" src="${urls.base}/js/individual/individualUriRdf.js"></script>',
'<script async type="text/javascript" src="${urls.base}/js/individual/individualTooltipBubble.js"></script>',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,7 @@ corresponding changes in the included Templates. -->
</div>


${stylesheets.add('<link rel="stylesheet" type="text/css" href="${urls.base}/css/visualization/visualization.css" />',
'<link rel="stylesheet" href="${urls.base}/bootstrap-5.3.2/css/bootstrap.min.css" />')}
${stylesheets.add('<link rel="stylesheet" type="text/css" href="${urls.base}/css/visualization/visualization.css" />')}

${headScripts.add('<script type="text/javascript" src="${urls.base}/js/tooltip/tooltip-utils.js"></script>',
'<script type="text/javascript" src="${urls.base}/js/tooltip/popper.min.js"></script>',
Original file line number Diff line number Diff line change
Expand Up @@ -216,8 +216,7 @@ ${headScripts.add('<script type="text/javascript" src="${urls.base}/js/tiny_mce/
'<script type="text/javascript" src="${urls.base}/js/jquery_plugins/jquery.truncator.js"></script>',
'<script type="text/javascript" src="https://d1bxh8uas1mnw7.cloudfront.net/assets/embed.js"></script>',
'<script type="text/javascript" src="${urls.base}/js/tooltip/tooltip-utils.js"></script>',
'<script type="text/javascript" src="${urls.base}/js/tooltip/popper.min.js"></script>',
'<script type="text/javascript" src="${urls.base}/bootstrap-5.3.2/js/bootstrap.min.js"></script>')}
'<script type="text/javascript" src="${urls.base}/js/tooltip/popper.min.js"></script>')}

${scripts.add('<script type="text/javascript" src="${urls.base}/js/individual/individualUtils.js"></script>',
'<script type="text/javascript" src="${urls.base}/js/individual/individualTooltipBubble.js"></script>',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ $(document).ready(function(){
return false;
});
$(window).on('popstate', function () {
var anchor = location.hash || $('li[data-bs-toggle=\'tab\']').first().attr('href');
var anchor = location.hash || $('li[data-toggle=\'tab\']').first().attr('href');
$('li[href=\'' + anchor + '\']').tab('show');
if (anchor == "#viewAll") {
showViewAll();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,8 +189,7 @@ ${headScripts.add(
'<script type="text/javascript" src="${urls.base}/js/tiny_mce/tiny_mce.js"></script>',
'<script type="text/javascript" src="${urls.base}/js/jquery_plugins/jquery.truncator.js"></script>',
'<script type="text/javascript" src="${urls.base}/js/tooltip/tooltip-utils.js"></script>',
'<script type="text/javascript" src="${urls.base}/js/tooltip/popper.min.js"></script>',
'<script src="${urls.base}/bootstrap-5.3.2/js/bootstrap.min.js"></script>'
'<script type="text/javascript" src="${urls.base}/js/tooltip/popper.min.js"></script>'
)}

${scripts.add(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@
<#assign groupNameHtmlId = "${i18n().properties}" >
</#if>
<#if tabCount = 1 >
<li data-bs-toggle="tab" groupName="${groupNameHtmlId?replace("/","-")}" class="active" data-bs-target="#${groupNameHtmlId?replace("/","-")}Group" href="#${groupNameHtmlId?replace("/","-")}Group"><a href="#${groupNameHtmlId?replace("/","-")}Group">${groupName?capitalize}</a></li>
<li data-toggle="tab" groupName="${groupNameHtmlId?replace("/","-")}" class="active" href="#${groupNameHtmlId?replace("/","-")}Group"><a href="#">${groupName?capitalize}</a></li>
<#assign tabCount = 2>
<#else>
<li data-bs-toggle="tab" groupName="${groupNameHtmlId?replace("/","-")}" data-bs-target="#${groupNameHtmlId?replace("/","-")}Group" href="#${groupNameHtmlId?replace("/","-")}Group"><a href="#${groupNameHtmlId?replace("/","-")}Group">${groupName?capitalize}</a></li>
<li data-toggle="tab" groupName="${groupNameHtmlId?replace("/","-")}" href="#${groupNameHtmlId?replace("/","-")}Group"><a href="#">${groupName?capitalize}</a></li>
</#if>
</#if>
</#list>
<#if (propertyGroups.all?size > 1) >
<li id="viewAllTab" data-bs-toggle="tab" groupName="viewAll" href="#viewAll"><a href="#">${i18n().view_all_capitalized}</a></li>
<li id="viewAllTab" data-toggle="tab" groupName="viewAll" href="#viewAll"><a href="#">${i18n().view_all_capitalized}</a></li>
</#if>
</ul>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ var i18nStrings = {
allCapitalized: '${i18n().all_capitalized?js_string}',
};
</script>
<script src="${urls.base}/bootstrap-5.3.2/js/bootstrap.min.js"></script>
<script type="text/javascript" src="${urls.base}/js/jquery-1.12.4.min.js"></script>
<script type="text/javascript" src="${urls.base}/js/jquery-migrate-1.4.1.js"></script>
<script type="text/javascript" src="${urls.base}/js/vitroUtils.js"></script>
Expand Down

0 comments on commit 486e5da

Please sign in to comment.