diff --git a/datamodels/2.x/itop-portal-base/portal/templates/layout.html.twig b/datamodels/2.x/itop-portal-base/portal/templates/layout.html.twig index bf27d16b2..bbe3e25bf 100644 --- a/datamodels/2.x/itop-portal-base/portal/templates/layout.html.twig +++ b/datamodels/2.x/itop-portal-base/portal/templates/layout.html.twig @@ -53,6 +53,9 @@ {# - Portal adjustments for BS theme #} + {# Tippy for tooltips and Popper for their placement #} + + {# UI Extensions CSS, in an undefined order #} {% if app['ui_extensions_helper'].css_files is defined %} {% for css_file in app['ui_extensions_helper'].css_files %} @@ -99,6 +102,9 @@ + {# Tippy for tooltips and Popper for their placement #} + + {# Visible.js to check if an element is visible on screen #} {# Base64.js #} @@ -497,6 +503,11 @@ ShowErrorDialog(); } }); + + // Enable tooltips based on existing HTML markup, won't work on markup added dynamically after DOM ready (AJAX, ...) + $('[data-tooltip-content]:not([data-tooltip-instanciated="true"])').each(function(){ + CombodoGlobalToolbox.InitTooltipFromMarkup($(this)); + }); // Initialize confirmation message handler when a form with touched fields is closed $('body').portal_leave_handler({'message': '{{ 'Portal:Form:Close:Warning'|dict_s }}'});