{% import "_includes/forms" as forms %}
{% from "seomatic/settings/_includes/macros.twig" import configWarning %}

<div id="sitemaps" class="hidden">
    {% namespace "settings" %}

        {{ forms.lightswitchField({
            label: "Sitemaps Enabled"|t("seomatic"),
            instructions: "Controls whether SEOmatic will automatically render frontend sitemaps for your website."|t("seomatic"),
            id: "sitemapsEnabled",
            name: "sitemapsEnabled",
            on: settings.sitemapsEnabled,
            warning: configWarning("sitemapsEnabled", "seomatic"),
            errors: settings.getErrors("sitemapsEnabled"),
        }) }}

        {{ forms.lightswitchField({
            label: "Exclude Non-Canonical URLs"|t("seomatic"),
            instructions: "Should items where the entry URL doesn't match the canonical URL be excluded?"|t("seomatic"),
            id: "excludeNonCanonicalUrls",
            name: "excludeNonCanonicalUrls",
            on: settings.excludeNonCanonicalUrls,
            warning: configWarning("excludeNonCanonicalUrls", "seomatic"),
            errors: settings.getErrors("excludeNonCanonicalUrls"),
        }) }}

    {% endnamespace %}
</div>
