Files
Uroboros 6ffb936c39
continuous-integration/drone/push Build is passing
footer p-0
2026-10-08 14:40:31 +10:00

110 lines
3.1 KiB
Vue
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<script setup lang="ts">
import type { NavItem } from "~/types";
import { CONTACTS } from "~/data/site";
/**
* Подвал с контактными данными. На мобильных клик по номеру начинает
* звонок (tel:-ссылка), на ПК — копирует номер и показывает toast.
*/
interface Props {
links: NavItem[];
intro: string;
}
const props = defineProps<Props>();
const { toastVisible, toastMessage, onPhoneClick } = usePhoneCopy();
</script>
<template>
<footer class="py-5 text-color">
<div class="container">
<div class="row">
<!-- Левый столбец: навигация -->
<div class="col-xl-6 col-md-4">
<template v-for="link in props.links" :key="link.label">
<NuxtLink v-if="link.to" class="custom-nav-link" :to="link.to">
{{ link.label }}
</NuxtLink>
<a v-else class="custom-nav-link" :href="link.anchor">
{{ link.label }}
</a>
</template>
</div>
<div class="col-xl-1 col-md-2"></div>
<!-- Правый столбец: контакты -->
<div class="col-xl-5 col-md-6 p-0">
<div class="pozition-left" id="call-my">
<h2>Контактная информация:</h2>
<p>{{ props.intro }}</p>
<p
v-for="phone in CONTACTS.phones"
:key="phone.display"
class="fs-4"
id="phoneNumber"
>
<a
:href="phone.href"
class="text-ycheba"
@click="onPhoneClick($event, phone.display)"
>
<img
src="/assets/ico/call.png"
alt="Иконка трубки"
class="navbar-brand-img call"
/>{{ phone.display }}</a
>
</p>
<p class="text-color phone-schedule">{{ CONTACTS.schedule }}</p>
<div class="social-network">
<p>Официальные группы в социальных сетях:</p>
<a
v-for="social in CONTACTS.socials"
:key="social.name"
class="social-network-a"
:class="social.extraClass"
:href="social.url"
target="_blank"
rel="noopener noreferrer"
>
<img
:src="`/assets/ico/${social.icon}`"
:alt="`Иконка ${social.name}`"
/>
</a>
</div>
</div>
</div>
</div>
</div>
<!-- Уведомление о копировании номера (ПК) -->
<div
v-show="toastVisible"
class="copy-toast"
role="status"
aria-live="polite"
>
{{ toastMessage }}
</div>
</footer>
</template>
<style scoped>
.copy-toast {
position: fixed;
bottom: 20px;
right: 20px;
padding: 10px 20px;
background-color: rgba(0, 0, 0, 0.8);
color: #fff;
border-radius: 5px;
font-size: 14px;
z-index: 9999;
}
</style>