From 3b83fe115b0f89d4028dce1afae76c43164fdf8c Mon Sep 17 00:00:00 2001 From: Nicolas Grekas Date: Mon, 17 Apr 2017 15:37:04 +0200 Subject: [PATCH] [VarDumper] Minor tweaks to html/css dumps --- .../Resources/views/Profiler/open.css.twig | 3 ++- src/Symfony/Component/VarDumper/Dumper/HtmlDumper.php | 2 +- .../Component/VarDumper/Tests/Caster/StubCasterTest.php | 6 +++--- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/open.css.twig b/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/open.css.twig index 144e86f062bb..02bc252f1200 100644 --- a/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/open.css.twig +++ b/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/open.css.twig @@ -64,6 +64,7 @@ a.doc:hover { .anchor { position: relative; - top: -7em; + padding-top: 7em; + margin-top: -7em; visibility: hidden; } diff --git a/src/Symfony/Component/VarDumper/Dumper/HtmlDumper.php b/src/Symfony/Component/VarDumper/Dumper/HtmlDumper.php index 198ec106be99..cc0b1ce179c3 100644 --- a/src/Symfony/Component/VarDumper/Dumper/HtmlDumper.php +++ b/src/Symfony/Component/VarDumper/Dumper/HtmlDumper.php @@ -496,7 +496,7 @@ protected function style($style, $value, $attr = array()) $attr['href'] = $href; } if (isset($attr['href'])) { - $v = sprintf('%s', esc($this->utf8Encode($attr['href'])), $v); + $v = sprintf('%s', esc($this->utf8Encode($attr['href'])), $v); } if (isset($attr['lang'])) { $v = sprintf('%s', esc($attr['lang']), $v); diff --git a/src/Symfony/Component/VarDumper/Tests/Caster/StubCasterTest.php b/src/Symfony/Component/VarDumper/Tests/Caster/StubCasterTest.php index b1d1c85be6a1..c626b595f83b 100644 --- a/src/Symfony/Component/VarDumper/Tests/Caster/StubCasterTest.php +++ b/src/Symfony/Component/VarDumper/Tests/Caster/StubCasterTest.php @@ -100,7 +100,7 @@ public function testLinkStub() $expectedDump = <<<'EODUMP' array:1 [ - 0 => "Symfony\Component\VarDumper\Tests\Caster\StubCasterTest" + 0 => "Symfony\Component\VarDumper\Tests\Caster\StubCasterTest" ] EODUMP; @@ -120,7 +120,7 @@ public function testClassStub() $expectedDump = <<<'EODUMP' array:1 [ - 0 => "hello" + 0 => "hello" ] EODUMP; @@ -161,7 +161,7 @@ public function testClassStubWithNotExistingMethod() $expectedDump = <<<'EODUMP' array:1 [ - 0 => "hello" + 0 => "hello" ] EODUMP;