Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordiosmosis <diosmosis@users.noreply.github.com>2019-01-28 03:08:41 +0300
committerGitHub <noreply@github.com>2019-01-28 03:08:41 +0300
commit60adbbc9f65c4bb1f6228e508bd23f2937310788 (patch)
treefc14f6eff64e8afb7ca13d3607eacbfaaa15ca01 /plugins/Live/templates
parent0f5b2314eaa6786fab0c4ac653beead69e6dcad8 (diff)
Show url and page title on different lines in realtime visits widget & show tooltip more quickly (#14005)
* Display url and page title on different lines and truncate url. * Reduce tooltip delay so it shows up quicker. * Remove truncate. * Apply tooltip change to realtime visits widget only. * Detect empty actions.
Diffstat (limited to 'plugins/Live/templates')
-rw-r--r--plugins/Live/templates/getLastVisitsStart.twig20
1 files changed, 15 insertions, 5 deletions
diff --git a/plugins/Live/templates/getLastVisitsStart.twig b/plugins/Live/templates/getLastVisitsStart.twig
index 8f755b7391..27d4a417bb 100644
--- a/plugins/Live/templates/getLastVisitsStart.twig
+++ b/plugins/Live/templates/getLastVisitsStart.twig
@@ -85,7 +85,7 @@
{{ action.serverTimePretty }}
{% if action.timeSpentPretty is defined %}{{ 'General_TimeOnPage'|translate }}: {{ action.timeSpentPretty|raw }}{% endif %}
{%- endset %}
- <img src="plugins/Live/images/file{{ col }}.png" title="{{ action.url|e('html_attr') }}&mdash;{{- title -}}"/>
+ <img src="plugins/Live/images/file{{ col }}.png" title="{% if action.url|trim is not empty %}{{ action.url|e('html_attr') }}<br/>{% endif %}{{- title -}}"/>
{% elseif action.type == 'outlink' or action.type == 'download' %}
<img class='iconPadding' src="{{ action.icon }}"
title="{% if action.url is defined %}{{ action.url }} - {% endif %}{{ action.serverTimePretty }}"/>
@@ -115,9 +115,19 @@
{% endfor %}
</ul>
<script type="text/javascript">
-$('#visitsLive').on('click', '.visits-live-launch-visitor-profile', function (e) {
- e.preventDefault();
- broadcast.propagateNewPopoverParameter('visitorProfile', $(this).attr('data-visitor-id'));
- return false;
+$(function () {
+ $('#visitsLive').on('click', '.visits-live-launch-visitor-profile', function (e) {
+ e.preventDefault();
+ broadcast.propagateNewPopoverParameter('visitorProfile', $(this).attr('data-visitor-id'));
+ return false;
+ }).tooltip({
+ track: true,
+ content: function() {
+ var title = $(this).attr('title');
+ return piwikHelper.escape(title.replace(/\n/g, '<br />'));
+ },
+ show: {delay: 100, duration: 0},
+ hide: false
+ });
});
</script>