simple_sitemap.sitemap_default:
  path: '/sitemap.xml'
  defaults:
    _controller: '\Drupal\simple_sitemap\Controller\SimplesitemapController::getSitemap'
    _disable_route_normalizer: 'TRUE'
  requirements:
    _access: 'TRUE'

# The actual path to a variant is '/{variant}/sitemap.xml'. Because Drupal 8
# cannot handle a parameter as first route argument,
# Drupal\simple_sitemap\PathProcessor\PathProcessorSitemapVariant::processInbound()
# is being used to catch the request and redirect to the following route.
simple_sitemap.sitemap_variant:
  path: '/sitemaps/{variant}/sitemap.xml'
  defaults:
    _controller: '\Drupal\simple_sitemap\Controller\SimplesitemapController::getSitemap'
    _disable_route_normalizer: 'TRUE'
  requirements:
    _access: 'TRUE'

simple_sitemap.sitemap_xsl:
  path: '/sitemap.xsl'
  defaults:
    _controller: '\Drupal\simple_sitemap\Controller\SimplesitemapController::getSitemapXsl'
    _title: 'Sitemap XSL'
    _disable_route_normalizer: 'TRUE'
  requirements:
    _access: 'TRUE'

simple_sitemap.sitemaps:
  path: '/admin/config/search/simplesitemap'
  defaults:
    _form: '\Drupal\simple_sitemap\Form\SimplesitemapSitemapsForm'
    _title: 'Simple XML Sitemap'
  requirements:
    _permission: 'administer sitemap settings'

simple_sitemap.settings:
  path: '/admin/config/search/simplesitemap/settings'
  defaults:
    _form: '\Drupal\simple_sitemap\Form\SimplesitemapSettingsForm'
    _title: 'Simple XML Sitemap'
  requirements:
    _permission: 'administer sitemap settings'

simple_sitemap.entities:
  path: '/admin/config/search/simplesitemap/entities'
  defaults:
    _form: '\Drupal\simple_sitemap\Form\SimplesitemapEntitiesForm'
    _title: 'Simple XML Sitemap'
  requirements:
    _permission: 'administer sitemap settings'

simple_sitemap.custom:
  path: '/admin/config/search/simplesitemap/custom'
  defaults:
    _form: '\Drupal\simple_sitemap\Form\SimplesitemapCustomLinksForm'
    _title: 'Simple XML Sitemap'
  requirements:
    _permission: 'administer sitemap settings'

simple_sitemap.variants:
  path: '/admin/config/search/simplesitemap/variants'
  defaults:
    _form: '\Drupal\simple_sitemap\Form\SimplesitemapVariantsForm'
    _title: 'Simple XML Sitemap'
  requirements:
    _permission: 'administer sitemap settings'
