1
0
mirror of https://github.com/maximebf/php-debugbar.git synced 2025-06-11 00:21:16 +02:00
Commit Graph

57 Commits

Author SHA1 Message Date
ae1f47ca11 Dark Theme + Theme variables + UI tweaks (#703)
* Add option to set theme

* Replace colors with variables

* Use mask for icons

* Fix borders

* Use better variables

* Remove theme

* Add github dark

* Fix select

* Tweak open handler

* Fix inputs

* Fix toolbar

* Fix labels

* Add theme switcher

* Use :after for icons

* Slight tweak to base css

* Tweak restore btn

* Use font variables, tweak timeline

* TWeak openhandler

* Tweak query hover

* Remove openhandler padding

* Fix dataset switcher

* Tweak toolbar

* Move settings, simplify storage

* Add floating position and autoshow to settings

* Tweak constructor

* Add test

* Add hide empty tabs option

* Tweak loading

* Fix test

* Breathe a little

* Add screenshots to tests, test light/dark

* Run screenshot only on 8.4

* Tweak folder

* Tweak

* Rename var

* Twaek hover

* TWeak sql

* Tweak accent

* Fix overly fanatic rename

* Tweak to header
2025-01-26 15:41:20 +01:00
63bae27159 Hide empty collectors until used (#672)
* Hide empty collectors until used

* Make hidden tabs configurable

* Tweak default, add test
2024-09-10 19:28:00 +02:00
1b5cabe0ce Add test-case for Fix parameter output if parameter is Datetime or array [v1.22.4] #671 (#673)
* Fix parameter output if parameter is Datetime or array

* use array_map for parsing parameters

* Add test-case for Doctrine datetime

* Fix doctrine query

---------

Co-authored-by: Alius <aliusa@users.noreply.github.com>
2024-09-09 10:05:55 +02:00
11896db266 Escape doctrine entries (#657)
* Escape doctrine entries

* Add PDO browsertest
2024-06-10 11:29:12 +02:00
2a722cccf5 Combine dropdown with dataset handler (#642)
* Combine dropdown with dataset handler

* Add test for tab
2024-04-01 11:12:18 +02:00
f9b5949093 Refactor browser test, test monolog bridge (#641)
* Refactor browser test, test monolog bridge

* Rename

* Add Doctrine
2024-03-31 20:14:48 +02:00
2bfe379a66 Add browser test (#639)
* Add browser test with Panther
2024-03-30 08:50:08 +01:00
6706ad4d2d Improve assertion and ignore cached PHPUnit file (#462) 2024-03-30 07:26:17 +01:00
42beef04ff Feat deprecate bindtojquery (#629)
* Deprecate bindToJquery

* Tweak
2024-03-20 13:35:26 +01:00
ff2b6d6346 fix open_basedir restriction error (#590) 2024-02-10 11:00:09 +01:00
dff80cdb1c Fix PHP 8.2 deprecations (#531)
* Fix deprecation: Use of "parent" in callables is deprecated

* Fix deprecations in tests

Creation of dynamic properties is deprecated since php 8.2
2023-08-18 19:36:53 +02:00
1386fe5c4f Php8 1 fixes (#497)
* PHP 8.1 warning fixes

Added #[\ReturnTypeWillChange] or appropriate return values
Typed parameters where appropriate

* Fixing unit tests to run without warnings

* Update to more reasonable versions of PHP and PHPUnit (was missing PHPUnit 8)

* mb_check_encoding param 1 can not be null

* Fix SeekingData class for 8.1

* Update tests to not polute the temp directory

* Revert PHP contrant

* Tabs to spaces

* Use Symfony\Component\VarDumper\Cloner\Data\SeekingData instead of local backported version

Avoids Fatal error: Declaration of DebugBar\DataFormatter\VarDumper\SeekingData::seek($key) must be compatible with Symfony\Component\VarDumper\Cloner\Data::seek(string|int $key): ?static

Co-authored-by: Barry vd. Heuvel <barryvdh@gmail.com>
2022-10-31 14:31:43 +01:00
fd43dfb084 Fix random instances of SQL queries having params repeated (#505)
* Fix random instances of SQL queries having params repeated

* Add test
2022-10-31 14:26:03 +01:00
b12bbde6f5 Test CSP Nonce 2021-06-22 10:01:30 +02:00
87e627ad1a Fix tests 2021-06-22 09:56:39 +02:00
ae942fd21d Create run-tests.yml for Github Actions (#461)
* Create run-tests.yml

* Update FileStorageTest.php
2020-12-07 11:47:36 +01:00
9544e0bf2a Test on PHP 8 (#456)
* Test on PHP 8

* Fix tests
2020-12-07 11:39:43 +01:00
1a1605b8e9 Add return value to measure() function. (#443)
Change-Id: I0e0277a019545bae6b4a9854b915a83bcea6757a

Co-authored-by: vdauchy <vdauchy@summit-tech.ca>
2020-05-06 09:06:27 +02:00
4048ff47ed Bug fix repead params sql (#387)
* Bug fix repead params sql

* Fix array

* Fix array
2018-05-19 19:41:13 +02:00
3f311533b5 Traced statement interpolation fixes (#381)
* Prevent back reference issues in TracedStatement

* Prevent substring replacement

If a previously replaced value in the query string contains the placeholder
for a future replacement, the string inside was being replaced
Also, PHP allows the bindParameter syntax to omit the leading ':', so we
test to make sure it's there and add it if not
2018-04-16 21:36:29 +02:00
3e3dad6f9a Bugfix getSqlWithParams ReplacementParamsQuery (#351)
* Bugfix getSqlWithParams ReplacementParamsQuery

* backward compatibility
2017-08-14 10:46:50 +02:00
35fa8abe90 Use new HtmlVariableListWidget with collectors (#346)
Introduce a new HtmlVariableListWidget that is similar to
VariableListWidget but for variables with HTML contents.

Update the collectors that use the existing VariableListWidget to use
DebugBarVarDumper to dump the variables using the VarDumper HtmlDumper.
Because many debug bar users may not yet support inline static assets,
default to use the old VariableListWidget for now.

Updated collectors:

* ConfigCollector
* RequestDataCollector
2017-07-21 13:35:58 +02:00
54214dadb6 Update MessagesCollector to support HTML var dumping (#345)
Use the new DebugBarVarDumper class to support dumping variables in
interactive collapsible HTML; the new useHtmlVarDumper() function will
enable this.

Since this will require users to handle the new inline assets provided
by the JavascriptRenderer, make this dumping format optional and default
to the old behavior for now.
2017-07-21 13:35:32 +02:00
13993afffe Introduce DebugBarVarDumper for HTML variable dumping (#344)
The Symfony VarDumper component includes an HtmlDumper that dumps
variables in a rich HTML format that allows for expanding and collapsing
individual tree nodes in the dumped variable.  This makes it much more
practical to navigate large/deep variables that have been dumped.

DebugBarVarDumper provides a Debug Bar-friendly wrapper around the
VarDumper component.  It’s intended as a better alternative to
DataFormatter::formatVar.  It provides for:

* Debug Bar-friendly styles for the VarDumper HTML.

* Implements AssetProvider for returning VarDumper static assets
  (requires users of JavascriptRenderer to support inline assets).

* Simplifies VarCloner and HtmlDumper function calls for cloning and
  dumping variables in a Debug Bar environment.  VarDumper was
  originally written/targeted to be a replacement for var_dump, so the
  default behavior of HtmlDumper echoing static assets and variable
  dumps directly to the page output isn’t really appropriate.
  Furthermore, we must contend with several different Symfony versions
  going back to v2.6.0.  This class provides a friendly wrapper.

I have tested this with these Symfony versions:

* v2.6.0
* v2.7.0
* v2.8.0
* v3.0.0
* v3.1.0
* v3.2.0
* v3.3.0

All seem to work fine, with graceful degradation as needed.

Furthermore, the class is ready to take advantage of new features that I
added and are upcoming in Symfony v3.4:

* setMinDepth: https://github.com/symfony/symfony/pull/23515
  This feature will be valuable for the upcoming BacktraceCollector.
2017-07-19 15:29:53 +02:00
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
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
b1f5e65c3b Added support for negative numbers in DataFormatter::formatBytes() 2016-03-17 11:31:17 -04:00
6266264bcc Added propel2 collector and tests 2015-08-26 00:38:57 +07:00
957c873543 Merge pull request #179 from maximebf/vardumper
User VarDumper component as DataFormatter
2014-11-29 13:18:24 +01:00
a01819af85 User VarDumper component
Use the VarDumper component instead of the kintLite method.
2014-11-29 12:35:43 +01:00
196a11203b allow disabling of specific vendor assets 2014-11-23 09:22:39 +01:00
0447abd246 Extend TimeData widget/collector
Add params + collector name. Make params expend on click.
2014-10-30 16:40:31 +01:00
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
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
0194f85bcf Whitespace cleanup 2014-07-26 12:00:45 +01:00
323415ca3f added syntax highlighting (fixed #99) 2014-03-22 22:29:09 -04:00
6e521e3990 added AssetProvider interface and JavascriptRenderer::addAssets() 2014-03-22 15:54:52 -04:00
d076e51b3a renamed DataFormater to DataFormatter (oups!) 2014-03-04 14:18:45 -03:00
cae98bc37a added DataFormater and now using kint to format variables (fixed #93 and #95) 2014-03-04 13:56:20 -03:00
3089d2f750 refactoring and improvements to resizing and responsivity
debugbar header is now split in left and right containers for better responsivity
changed the way the indicators position is handled (not a property of the indicator anymore)
moved resize-handle out of body
when closed, the debugbar will always restore to opened state
2014-02-14 12:42:43 -03:00
89ad71ab18 Test tweak 2014-01-17 19:58:09 +00:00
0071105c25 CS fixes 2014-01-16 21:41:41 +00:00
20051093ad Small change for responsive CSS
Update full_init.html, javascript : rename function and variable.
2013-12-27 09:33:05 +01:00
b8bd80b367 Update tests 2013-12-17 12:53:18 +01:00
85fc816102 fixed failing test 2013-10-07 10:49:52 -04:00
8972b82a9a added support for sending the request id in headers and retreiving the data using the open handler 2013-09-23 10:41:54 -04:00
3c5e8cca50 added getDataAsHeaders() 2013-09-20 13:42:12 -04:00
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
7e81754ef6 Added abstraction for HTTP features (fixed #28) 2013-09-19 16:31:00 -04:00
861ddc302e removed usage of session_status() 2013-09-15 13:06:20 -04:00