<script setup lang="ts">
import useConfig from '../composables/useConfig.ts';

definePageMeta({
    translatedPaths: (config) => {
        if (!config.user.enabled) {
            return [];
        }
        return [`/${encodeURIComponent(config.user.privacyRoute)}`];
    },
});

const { $translator: translator } = useNuxtApp();
useSimpleHead({
    title: translator.translate('privacy.header'),
    description: translator.translate('privacy.content.intro'),
}, translator);

const config = useConfig();
</script>

<template>
    <Page>
        <h2>
            <Icon v="user-secret" />
            <T>privacy.header</T>
        </h2>

        <p class="small">
            <em>
                <T>terms.lastUpdate</T><T>quotation.colon</T>
                2024-03-03
                (Sentry)
            </em>
        </p>

        <div v-if="$te('terms.translationDisclaimer')" class="alert alert-warning">
            <Icon v="exclamation-triangle" />
            <T>terms.translationDisclaimer</T>
        </div>

        <p>
            <T>privacy.content.intro</T>
            <a href="mailto:contact@pronouns.page" target="_blank" rel="noopener">contact@pronouns.page</a>.
        </p>
        <p><T>privacy.content.effort</T></p>
        <p><T>privacy.content.data</T></p>
        <p><T>privacy.content.editRemoval</T></p>
        <p><T>privacy.content.contact</T></p>
        <p><T>privacy.content.cookies</T></p>
        <p><T>privacy.content.plausible</T></p>
        <p><T>privacy.content.turnstile</T></p>
        <p><T>privacy.content.sentry</T></p>
        <p v-if="config.ads && config.ads.enabled">
            <T>privacy.content.publift</T>
            <span data-fuse-privacy-tool></span>
            <T>privacy.content.gtm</T>
        </p>
        <p><T>privacy.content.logsBackups</T></p>
        <p><T>privacy.content.gdpr</T></p>
    </Page>
</template>
