UNPKG

@gouvfr/dsfr-roller

Version:

Le module `dsfr-roller` permet de publier le site de documentation du Système de Design de l’État - DSFR

50 lines (45 loc) 1.41 kB
import { Component } from '../component.js'; class Skiplink extends Component { constructor(data) { super(data, 'skiplink'); } get ejsPath() { return 'src/dsfr/component/skiplink/template/ejs/skiplinks.ejs'; } async format() { return { id: 'skiplink', items: [ { attributes: { id: 'skiplink-content', }, label: this.data.resource.skiplink.content, href: this.data.path === '' ? '#content' : '#breadcrumb', }, { attributes: { id: 'skiplink-navigation', }, label: this.data.resource.skiplink.navigation, href: '#menu-modal', }, { attributes: { id: 'skiplink-search', }, label: this.data.resource.skiplink.search, href: '#search-modal', }, { attributes: { id: 'skiplink-footer', }, label: this.data.resource.skiplink.footer, href: '#footer', }, ], }; } } export { Skiplink };