Add Laravel / PHP prefixes to their version tooltips (#1073)

This commit is contained in:
Ernestas Kvedaras 2020-08-01 16:18:22 +02:00 committed by GitHub
parent c0ba718c95
commit 31f660f8d1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 19 additions and 2 deletions

View File

@ -50,7 +50,7 @@ class LaravelCollector extends DataCollector implements Renderable
return [
"version" => [
"icon" => "github",
"tooltip" => "Version",
"tooltip" => "Laravel Version",
"map" => "laravel.version",
"default" => ""
],

View File

@ -0,0 +1,17 @@
<?php
namespace Barryvdh\Debugbar\DataCollector;
use DebugBar\DataCollector\PhpInfoCollector as DebugBarPhpInfoCollector;
class PhpInfoCollector extends DebugBarPhpInfoCollector
{
/**
* @inheritDoc
*/
public function getWidgets()
{
return tap(parent::getWidgets(), function (&$widgets) {
data_set($widgets, 'php_version.tooltip', 'PHP Version');
});
}
}

View File

@ -22,7 +22,7 @@ use DebugBar\DataCollector\DataCollectorInterface;
use DebugBar\DataCollector\ExceptionsCollector;
use DebugBar\DataCollector\MemoryCollector;
use DebugBar\DataCollector\MessagesCollector;
use DebugBar\DataCollector\PhpInfoCollector;
use Barryvdh\Debugbar\DataCollector\PhpInfoCollector;
use DebugBar\DataCollector\RequestDataCollector;
use DebugBar\DataCollector\TimeDataCollector;
use Barryvdh\Debugbar\DataFormatter\QueryFormatter;