import React, { useState } from 'react'; import { useApp } from '../../context/AppContext'; import { Smartphone, Wifi, WifiOff, Download, Bell, CheckCircle2, ShieldCheck, Zap, Sparkles, Moon } from 'lucide-react'; import confetti from 'canvas-confetti'; export const PwaSettings = () => { const { userProfile, reminderSettings, setReminderSettings, requestPushPermission, notify, isQuietNow } = useApp(); const [offlineMode, setOfflineMode] = useState(true); const [installed, setInstalled] = useState(false); const [permission, setPermission] = useState(typeof Notification !== 'undefined' ? Notification.permission : 'unsupported'); const handleEnablePush = async () => { const p = await requestPushPermission(); setPermission(p); if (p === 'granted') { setReminderSettings((s) => ({ ...s, pushEnabled: true })); notify('Bildirimler açıldı', 'Yeni ihale ve son tarih uyarıları buradan gelecek.'); confetti({ particleCount: 50 }); } }; const setQuiet = (patch) => setReminderSettings((s) => ({ ...s, ...patch })); const handleInstallPwa = () => { setInstalled(true); confetti({ particleCount: 70 }); }; return (
Saha satış temsilcileriniz için internet bağlantısı olmadığında dahi çevrimdışı çalışma ve anlık push bildirimi.
İhale Kayıtları: 102 İhale Önbellekte
Şartname PDF'leri: 18 Belge Çevrimdışı
Son Senkronizasyon: Bugün 14:45
Tarayıcı bildirimlerine izin verin; yeni ihale ve son tarih uyarıları gerçek bildirim olarak gelir.
{permission !== 'granted' ? ( ) : ( )} {/* Sessiz saatler — gerçek */}{isQuietNow() ? '🔕 Şu an sessiz saatte — tarayıcı bildirimi gösterilmez, uyarılar listeye eklenir.' : '🔔 Şu an aktif — bildirimler gösterilir.'}
)}İhaleist'i iOS, Android, Windows veya Mac cihazınıza bir tıklama ile uygulama olarak kurun.