app.get('/', function (request, respons) {
respons.sendFile(__dirname + '/index.html');
});
bot.addScene('wizard',
({ reply, scene: { next } }) => {
next()
reply('Write me something!')
},
({ reply, body, scene: { leave } }) => {
leave()
reply(`You wrote: ${body}`)
}
);
bot.command('join', ({ scene: { join } }) => join('wizard'));
const feedbackSlider = () => {
let slideIndex = 1,
items = document.querySelectorAll(".feedback-slider-item"),
prev = document.querySelector(".main-prev-btn"),
next = document.querySelector(".main-next-btn");
const showSlides = (n) => {
if (n > items.length) {
slideIndex = 1;
}
if (n < 1) {
slideIndex = items.length;
}
items.forEach((item) => {
item.classList.add("animated");
item.style.display = "none";
});
items[slideIndex - 1].style.display = "block";
}
const plusSlides = (n) => {
showSlides(slideIndex += n);
}
showSlides(slideIndex);
prev.addEventListener("click", () => {
clearInterval(sliderInterval);
plusSlides(-1);
items[slideIndex - 1].classList.remove("slideInLeft");
items[slideIndex - 1].classList.add("slideInRight");
sliderInterval = auto();
}),
next.addEventListener("click", () => {
clearInterval(sliderInterval);
plusSlides(1);
items[slideIndex - 1].classList.remove("slideInRight");
items[slideIndex - 1].classList.add("slideInLeft");
sliderInterval = auto();
});
const auto = () => setInterval (() => {
plusSlides(1);
items[slideIndex - 1].classList.remove("slideInRight");
items[slideIndex - 1].classList.add("slideInLeft");
}, 5000);
let sliderInterval = auto();
}
И проверьте, что падает в консоль