. * * @file * @ingroup Skins */ declare( strict_types=1 ); namespace Citizen\Partials; final class PageLinks extends Partial { /** * Render page-related links at the bottom * * @return array html */ public function buildPageLinks() : array { $contentNavigation = $this->skin->buildContentNavigationUrlsPublic(); $namespaceshtml = $this->skin->getMenuData( 'namespaces', $contentNavigation[ 'namespaces' ] ?? [] ); $variantshtml = $this->skin->getMenuData( 'variants', $contentNavigation[ 'variants' ] ?? [] ); if ( $namespaceshtml ) { $namespaceshtml[ 'label-class' ] .= 'screen-reader-text'; } if ( $variantshtml ) { $variantshtml[ 'label-class' ] .= 'screen-reader-text'; } return [ 'data-namespaces' => $namespaceshtml, 'data-variants' => $variantshtml, ]; } }