
$w.onReady(function () { let images = $w("Image"); // Seleciona todas as imagens da página images.forEach((img) => { img.src = img.src.replace("?auto=format", "?auto=format&dpr=2&w=800"); }); }); import wixWindow from 'wix-window'; $w.onReady(function () { if (wixWindow.rendering.env === "browser") { setTimeout(() => { $w("#container").show("fade"); // Faz elementos surgirem suavemente }, 500); } }); $w.onReady(function () { $w("#botaoWhatsApp").label = "Fale no WhatsApp"; $w("#botaoWhatsApp").onClick(() => { let telefone = "5599999999999"; // Substitua pelo seu número com DDD e DDI let mensagem = "Olá, gostaria de saber mais sobre os serviços!"; let url = `https://api.whatsapp.com/send?phone=${telefone}&text=${encodeURIComponent(mensagem)}`; wixLocation.to(url); }); }); $w.onReady(function () { let respostas = { "Olá": "Olá! Como posso ajudar você?", "Quais são os serviços?": "Oferecemos mapeamento com drone, georreferenciamento e mais.", "Qual o contato?": "Você pode falar conosco pelo WhatsApp clicando no botão ao lado!" }; $w("#botaoEnviarChat").onClick(() => { let pergunta = $w("#inputPergunta").value; let resposta = respostas[pergunta] || "Desculpe, não entendi. Tente perguntar de outra forma."; $w("#respostaChat").text = resposta; }); });