Skip to content

Commit

Permalink
update plausible script name in mako templates
Browse files Browse the repository at this point in the history
  • Loading branch information
sanjaysrikakulam committed Jun 28, 2024
1 parent 414bc64 commit c185367
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion lib/tool_shed/webapp/templates/galaxy_client_app.mako
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ ${ h.dumps( dictionary, indent=( 2 if trans.debug else 0 ) ) }

<%def name="config_plausible_analytics(plausible_server, plausible_domain)">
%if plausible_server and plausible_domain:
<script async defer data-domain="${plausible_domain}" src="${plausible_server}/js/plausible.js"></script>
<script async defer data-domain="${plausible_domain}" src="${plausible_server}/js/script.js"></script>
%else:
<script>console.warn("Missing plausible server or plausible domain");</script>
%endif
Expand Down
2 changes: 1 addition & 1 deletion templates/galaxy_client_app.mako
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ ${ h.dumps( dictionary, indent=( 2 if trans.debug else 0 ) ) }

<%def name="config_plausible_analytics(plausible_server, plausible_domain)">
%if plausible_server and plausible_domain:
<script async defer data-domain="${plausible_domain}" src="${plausible_server}/js/plausible.js"></script>
<script async defer data-domain="${plausible_domain}" src="${plausible_server}/js/script.js"></script>
<script>window.plausible = window.plausible || function() { (window.plausible.q = window.plausible.q || []).push(arguments) }</script>
%else:
<script>
Expand Down
8 changes: 4 additions & 4 deletions templates/js-app.mako
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@
| ${app.config.brand}
%endif
</title>

## relative href for site root
<link rel="index" href="${ h.url_for( '/' ) }"/>

## TODO: use loaders to move everything but the essentials below the fold
${ h.dist_css(
'base',
Expand Down Expand Up @@ -86,10 +86,10 @@
${ galaxy_client.config_google_analytics(app.config.ga_code) }
%endif
%if app.config.plausible_server and app.config.plausible_domain:
${ galaxy_client.config_plausible_analytics(app.config.plausible_server, app.config.plausible_domain) }
${ galaxy_client.config_plausible_analytics(app.config.plausible_server, app.config.plausible_domain) }
%endif
%if app.config.matomo_server and app.config.matomo_site_id:
${ galaxy_client.config_matomo_analytics(app.config.matomo_server, app.config.matomo_site_id) }
${ galaxy_client.config_matomo_analytics(app.config.matomo_server, app.config.matomo_site_id) }
%endif
</%def>

Expand Down

0 comments on commit c185367

Please sign in to comment.