private function resolveElement(DescriptorAbstract $element, $link, ?string $description = null): string
    {
        $rule = $this->router->match($element);

        if ($rule) {
            $url = '..' . $rule->generate($element);
            $link = $this->generateMarkdownLink($url, $description ?: (string) $link);
        }

        return $link;
    }
private function resolveElement(DescriptorAbstract $element, $link, ?string $description = null): string
    {
        $rule = $this->router->match($element);

        if ($rule) {
            $url = '..' . $rule->generate($element);
            $link = $this->generateMarkdownLink($url, $description ?: (string) $link);
        }

        return $link;
    }
private function resolveElement ( DescriptorAbstract $ element , $ link , ? string $ description = null ) : string { $ rule = $ this -> router -> match ( $ element ) ; if ( $ rule ) { $ url = '..' . $ rule -> generate ( $ element ) ; $ link = $ this -> generateMarkdownLink ( $ url , $ description ? : ( string ) $ link ) ; } return $ link ; }
Generates a Markdown link to the given Descriptor or returns the link text if no route to the Descriptor could
be matched.

@param Fqsen|string $link
Generates a Markdown link to the given Descriptor or returns the link text if no route to the Descriptor could be matched .