1
0
mirror of https://github.com/maximebf/php-debugbar.git synced 2025-07-28 04:00:43 +02:00
Commit Graph

15 Commits

Author SHA1 Message Date
James Johnston
e6f0b5a48d Enable AssetProvider to support inline assets (#338)
Add new inline_css, inline_js, and inline_head keys on the
AssetProvider::getAssets() function.  This allows us to support
collectors that require static assets that are not actually saved to a
file.

Then, update all the asset functions in JavascriptRenderer to support
these new keys.

An initial use case for this is supporting the HtmlDumper in Symfony’s
VarDumper.  HtmlDumper only provides the styles and scripts in inline
HTML form.  The static assets can be customized based on some
configuration properties available on the HtmlDumper class.  One can
actually view the CSS/JS as a long PHP string/heredoc embedded in the
HtmlDumper.php source code.  They are only accessible via the
getDumpHeader function, which returns the CSS/JS in a combined HTML
string.
2017-07-15 11:08:32 +02:00
James Johnston
cbdeba00d0 Add option to not immediately show AJAX requests (#315)
By default, the debug bar will immediately show new AJAX requests. If
your page makes a lot of requests in the background (e.g. tracking),
this constant switching of the active data set can be disruptive to the
debug bar user.

This commit adds an option for disabling this behavior by calling
setAjaxHandlerAutoShow(false) on the JavascriptRenderer, like this:

    $renderer = $debugbar->getJavascriptRenderer();
    $renderer->setAjaxHandlerAutoShow(false);

When this behavior is disabled, AJAX requests are still available in the
drop-down list, but won’t become active until the user explicitly
selects them.
2017-03-05 08:17:18 +01:00
Andreas Lutro
196a11203b allow disabling of specific vendor assets 2014-11-23 09:22:39 +01:00
Barry vd. Heuvel
306c9920b3 Fix tests with assertTag
assertTag is deprecated and throws an deprecated message, failing the tests.
Replaced it with a simple Contains assertion.
2014-08-15 14:22:06 +02:00
maximebf
4a660ced6f moved the call to jquery.noConflict() to the head rather than when calling render() (fixed #127) 2014-07-26 15:36:58 +02:00
maximebf
323415ca3f added syntax highlighting (fixed #99) 2014-03-22 22:29:09 -04:00
maximebf
6e521e3990 added AssetProvider interface and JavascriptRenderer::addAssets() 2014-03-22 15:54:52 -04:00
Graham Campbell
89ad71ab18 Test tweak 2014-01-17 19:58:09 +00:00
Graham Campbell
0071105c25 CS fixes 2014-01-16 21:41:41 +00:00
Maxime Fabre
b8bd80b367 Update tests 2013-12-17 12:53:18 +01:00
maximebf
1b7e7fdbc8 jQuery.noConflict() is now called by default (fixed #29)
Will not be called if the js vendors are not included.
Can be enabled/disabled using JavascriptRenderer::setEnableJqueryNoConflict()
2013-09-19 16:31:50 -04:00
maximebf
90248ebb3c fixed unit tests with ajax handler 2013-09-15 11:40:37 -04:00
Pascal Borreli
68dfa87ef6 Fixed typos 2013-08-16 00:52:32 +01:00
maximebf
c5a145ad14 added tests 2013-08-14 22:12:33 +10:00
maximebf
fb1605e93c added unit tests 2013-08-14 21:37:24 +10:00