diff --git a/src/Mapper/Printer/HtmlTreePrinter.php b/src/Mapper/Printer/HtmlTreePrinter.php deleted file mode 100644 index 370a4a3..0000000 --- a/src/Mapper/Printer/HtmlTreePrinter.php +++ /dev/null @@ -1,182 +0,0 @@ - summary:after { - content: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz48IURPQ1RZUEUgc3ZnICBQVUJMSUMKICAgICAgICAnLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4nCiAgICAgICAgJ2h0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCc+PHN2ZyBlbmFibGUtYmFja2dyb3VuZD0ibmV3IDAgMCAyNTEuODgyIDI1MS44ODIiIHZlcnNpb249IjEuMSIgdmlld0JveD0iMCAwIDI1MS44OCAyNTEuODgiIHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0ibTE5NC44MiAxMTYuOTRoLTEzNy43NmMtNC45NzEgMC05IDQuMDI5LTkgOXM0LjAyOSA5IDkgOWgxMzcuNzZjNC45NzEgMCA5LTQuMDI5IDktOXMtNC4wMjktOS05LTl6Ii8+PC9zdmc+Cg=='); - } - - div.tree .test-summary:before { - position: absolute; - top: 0; - left: 0; - - width: 1em; /* width of horizontal line */ - height: 1em; /* vertical position of line */ - border-bottom: thin solid #e8e8e8; - content: ""; - } - - - div.tree .test-details:last-child { - border-left: none; - } - - div.tree .test-details:last-child .test-summary { - /*border-left: thin solid red;*/ - } - - .test-details .test-details:last-child .test-summary:before { - /*border-left: thin solid #e8e8e8;*/ - } - - details summary::-webkit-details-marker { - display:none; - } - CSS; - - // phpcs:enable - - private string $html = << - - - HTML; - - public function __construct(string $title = 'Test title') - { - $this->html .= '

' . $title . '

'; - } - - public function print(Node $node): string - { - $value = $node->isValid() ? $node->value() : null; - - if (! empty($node->children())) { - $details = 'details'; - $summary = 'summary'; - } else { - $details = 'div'; - $summary = 'div'; - } - - $this->html .= << - <$summary class="test-summary">{$node->name()} - HTML; - - if (is_scalar($value)) { - $this->html .= ' : ' . $node->value(); - } - -// foreach ($node->messages() as $message) { -// $this->html .= '
' . $message . '
'; -// } - - $this->html .= ""; - - if (! empty($node->children())) { - foreach ($node->children() as $subNode) { - $this->print($subNode); - } - } - - $this->html .= ""; - - $name = $node->name(); -// $parent = $node->parent(); -// $messages = $node->messages(); - - if (is_scalar($value)) { -// $this->html .= '
  • ' . $name . ' : ' . $value . '
  • '; - } else { -// if ($node->isRoot()) { -// $this->html .= '∞