app/Module/InteractiveTree/TreeView.php
private function getPersonDetails(Individual $individual, Family $family = null): string
    {
        $chart_url = route('module', [
            'module' => 'tree',
            'action' => 'Chart',
            'xref'   => $individual->xref(),
            'ged'    => $individual->tree()->name(),
        ]);

        $hmtl = $this->getThumbnail($individual);
        $hmtl .= '<a class="tv_link" href="' . e($individual->url()) . '">' . $individual->fullName() . '</a> <a href="' . e($chart_url) . '" title="' . I18N::translate('Interactive tree of %s', strip_tags($individual->fullName())) . '" class="wt-icon-individual tv_link tv_treelink"></a>';
        foreach ($individual->facts(Gedcom::BIRTH_EVENTS, true) as $fact) {
            $hmtl .= $fact->summary();
        }
        if ($family) {
            foreach ($family->facts(Gedcom::MARRIAGE_EVENTS, true) as $fact) {
                $hmtl .= $fact->summary();
            }
        }
        foreach ($individual->facts(Gedcom::DEATH_EVENTS, true) as $fact) {
            $hmtl .= $fact->summary();
        }

        return '<div class="tv' . $individual->sex() . ' tv_person_expanded">' . $hmtl . '</div>';
    }
private function getPersonDetails(Individual $individual, Family $family = null): string
    {
        $chart_url = route('module', [
            'module' => 'tree',
            'action' => 'Chart',
            'xref'   => $individual->xref(),
            'ged'    => $individual->tree()->name(),
        ]);

        $hmtl = $this->getThumbnail($individual);
        $hmtl .= '<a class="tv_link" href="' . e($individual->url()) . '">' . $individual->fullName() . '</a> <a href="' . e($chart_url) . '" title="' . I18N::translate('Interactive tree of %s', strip_tags($individual->fullName())) . '" class="wt-icon-individual tv_link tv_treelink"></a>';
        foreach ($individual->facts(Gedcom::BIRTH_EVENTS, true) as $fact) {
            $hmtl .= $fact->summary();
        }
        if ($family) {
            foreach ($family->facts(Gedcom::MARRIAGE_EVENTS, true) as $fact) {
                $hmtl .= $fact->summary();
            }
        }
        foreach ($individual->facts(Gedcom::DEATH_EVENTS, true) as $fact) {
            $hmtl .= $fact->summary();
        }

        return '<div class="tv' . $individual->sex() . ' tv_person_expanded">' . $hmtl . '</div>';
    }
private function getPersonDetails ( Individual $ individual , Family $ family = null ) : string { $ chart_url = route ( 'module' , [ 'module' => 'tree' , 'action' => 'Chart' , 'xref' => $ individual -> xref ( ) , 'ged' => $ individual -> tree ( ) -> name ( ) , ] ) ; $ hmtl = $ this -> getThumbnail ( $ individual ) ; $ hmtl .= '<a class="tv_link" href="' . e ( $ individual -> url ( ) ) . '">' . $ individual -> fullName ( ) . '</a> <a href="' . e ( $ chart_url ) . '" title="' . I18N :: translate ( 'Interactive tree of %s' , strip_tags ( $ individual -> fullName ( ) ) ) . '" class="wt-icon-individual tv_link tv_treelink"></a>' ; foreach ( $ individual -> facts ( Gedcom :: BIRTH_EVENTS , true ) as $ fact ) { $ hmtl .= $ fact -> summary ( ) ; } if ( $ family ) { foreach ( $ family -> facts ( Gedcom :: MARRIAGE_EVENTS , true ) as $ fact ) { $ hmtl .= $ fact -> summary ( ) ; } } foreach ( $ individual -> facts ( Gedcom :: DEATH_EVENTS , true ) as $ fact ) { $ hmtl .= $ fact -> summary ( ) ; } return '<div class="tv' . $ individual -> sex ( ) . ' tv_person_expanded">' . $ hmtl . '</div>' ; }
Return the details for a person

@param Individual  $individual
@param Family|null $family

@return string
Return the details for a person