From 8497ad7ce9fc086cee27f64b7e9a999f0cdfc136 Mon Sep 17 00:00:00 2001 From: Omar Yepez Date: Wed, 9 Sep 2015 15:09:41 -0430 Subject: [PATCH] [WebProfilerBundle ] Removes the ajax animation in | sf-toolbar-block-ajax | Q | A | ------------- | --- | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | n/a | Fixed tickets | n/a | License | MIT | Doc PR | n/a The change removes the animation in the "sf-toolbar-block-ajax" when the request state was "ok". --- .../Resources/views/Profiler/base_js.html.twig | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/base_js.html.twig b/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/base_js.html.twig index 2b1eeff3c00e9..753f383e43577 100644 --- a/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/base_js.html.twig +++ b/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/base_js.html.twig @@ -179,7 +179,10 @@ var className = 'sf-toolbar-ajax-requests sf-toolbar-value'; requestCounter[0].className = className; - if (state == 'error') { + if (state == 'ok') { + Sfjs.removeClass(ajaxToolbarPanel, 'sf-ajax-request-loading'); + Sfjs.removeClass(ajaxToolbarPanel, 'sf-toolbar-status-red'); + } else if (state == 'error') { Sfjs.addClass(ajaxToolbarPanel, 'sf-toolbar-status-red'); } else { Sfjs.addClass(ajaxToolbarPanel, 'sf-ajax-request-loading');