// SONARA — Producer Wallet & Payout (Revenue · Payout · KYC · Fiscale) const WIcons = window.SonaraIcons; /* ─────── ICONS ─────── */ const ArrIc = ({ size = 13 }) => ; const UpIc = ({ size = 12 }) => ; const DownloadIc = ({ size = 13 }) => ; const CheckIc = ({ size = 12 }) => ; const ChevDownIc = ({ size = 11 }) => ; const EditIc = ({ size = 13 }) => ; const InfoIc = ({ size = 12 }) => ; /* ─────── REVENUE CHART (mini sparkline area) ─────── */ function RevenueChart({ data, max }) { const w = 100, h = 40; const points = data.map((v, i) => `${(i / (data.length - 1)) * w},${h - (v / max) * h * 0.9 - 2}`).join(" "); const area = `0,${h} ${points} ${w},${h}`; return ( ); } /* ─────── BAR CHART (30gg revenue) ─────── */ function BarChart({ data }) { const max = Math.max(...data.map(d => d.v), 1); return (
{data.map((d, i) => (
{i % 5 === 0 && {d.l}}
))}
); } /* ─────── TRANSACTIONS ─────── */ const TX = [ { id: "TX-3201", type: "credit", label: "Vendita beat \"Lupo Solitario\"", who: "RAZZA", whoIn: "RZ", date: "Oggi", net: 39.6, status: "clearance", clearIn: "7gg" }, { id: "TX-3198", type: "credit", label: "Vendita beat \"Lupo Solitario\"", who: "Yoshi K.", whoIn: "YK", date: "Ieri", net: 39.6, status: "clearance", clearIn: "6gg" }, { id: "TX-3192", type: "credit", label: "Vendita beat \"Notturno\"", who: "Marco T.", whoIn: "MT", date: "3gg fa", net: 39.6, status: "clearance", clearIn: "4gg" }, { id: "TX-3186", type: "credit", label: "Ordine completato \"Singolo Bagliore\" — Mix + Master", who: "Giulia P.", whoIn: "GP", date: "4gg fa", net: 158, status: "clearance", clearIn: "3gg" }, { id: "TX-3180", type: "credit", label: "Vendita beat esclusiva \"Mezzanotte\"", who: "RAZZA", whoIn: "RZ", date: "1 sett. fa", net: 369.6, status: "available" }, { id: "PY-104", type: "payout", label: "Auto-payout settimanale → IBAN ***4831", date: "Lun 11 maggio", net: -892, status: "paid", receipt: true }, { id: "TX-3175", type: "credit", label: "Vendita beat \"Asfalto Bagnato\"", who: "Federico V.", whoIn: "FV", date: "9gg fa", net: 44, status: "available" }, { id: "TX-3170", type: "credit", label: "Ordine completato \"Beat su brief Tramonto\" — Custom production", who: "Federico V.", whoIn: "FV", date: "11gg fa", net: 308, status: "available" }, { id: "PY-103", type: "payout", label: "Auto-payout settimanale → IBAN ***4831", date: "Lun 4 maggio", net: -643, status: "paid", receipt: true }, { id: "TX-3162", type: "fee", label: "Fee Sonara su ordine ORD-4780", date: "2 sett. fa", net: -15, status: "applied" }, ]; /* ─────── PAYOUTS HISTORY ─────── */ const PAYOUTS = [ { id: "PY-104", date: "11 maggio 2026", amount: 892, iban: "IT60 X054 2811 1010 0000 0**4 831", status: "paid" }, { id: "PY-103", date: "4 maggio 2026", amount: 643, iban: "IT60 X054 2811 1010 0000 0**4 831", status: "paid" }, { id: "PY-102", date: "27 aprile 2026", amount: 1120, iban: "IT60 X054 2811 1010 0000 0**4 831", status: "paid" }, { id: "PY-101", date: "20 aprile 2026", amount: 487, iban: "IT60 X054 2811 1010 0000 0**4 831", status: "paid" }, { id: "PY-100", date: "13 aprile 2026", amount: 920, iban: "IT60 X054 2811 1010 0000 0**4 831", status: "paid" }, ]; /* ─────── PAGE ─────── */ function WalletPage() { const [tab, setTab] = React.useState("overview"); const [txFilter, setTxFilter] = React.useState("all"); // mock 30d barchart data const bars = Array.from({ length: 30 }, (_, i) => ({ l: `${i + 1}`, v: Math.round(Math.abs(Math.sin(i * 0.7) * 80 + (i % 7 === 0 ? 200 : 60) + Math.random() * 40)), })); const sparkData = [220, 280, 180, 340, 290, 480, 540, 410, 620, 700, 580, 720]; return (

Wallet & payout

Auto-payout settimanale · IBAN ***4831 · ● KYC verificato
{tab === "overview" && ( <> {/* TOP BALANCE CARDS */}
Disponibile per payout
1.247 ,60
Prossimo auto-payout lunedì 18 maggio · puoi anticipare on-demand
In escrow
892,00
3 ordini · si liberano alla consegna
In clearance
340,00
Protezione chargeback · 7gg
Lifetime
4.120,00
47 ordini · membro da gennaio 2023
{/* 30gg revenue chart */}
Revenue ultimi 30gg
Totale €2.140 +24% vs prec.
Media giornaliera €71,30 · Picco €340 il 24 aprile (vendita esclusiva) · Min €0 · 3 giorni senza vendite
{/* breakdown source */}
Da dove arriva la revenue
Ultimi 30gg
Servizi mix/master
7 ordini chiusi · ticket medio €135
€945
Beat esclusivo
1 vendita · esclusiva "Mezzanotte"
€680
Custom production
1 ordine completato
€340
Beat non-esclusivi
5 vendite · ticket medio €35
€175
)} {tab === "transactions" && ( <>
{[ { v: "all", l: "Tutte" }, { v: "credit", l: "Entrate" }, { v: "payout", l: "Payout" }, { v: "fee", l: "Fee Sonara" }, ].map(c => ( ))}
{TX.filter(t => txFilter === "all" || t.type === txFilter).map(t => (
{t.type === "credit" && } {t.type === "payout" && } {t.type === "fee" && %}
{t.label}
0 ? "pos" : "neg"}`}> {t.net > 0 ? "+" : "−"} €{Math.abs(t.net).toFixed(2).replace(".", ",")}
{t.id} · {t.date} {t.who && ( <> · {t.whoIn} {t.who} )} · {t.status === "available" && Disponibile} {t.status === "clearance" && In clearance · {t.clearIn}} {t.status === "paid" && Pagato} {t.status === "applied" && Applicata}
{t.receipt && ( )}
))}
)} {tab === "payouts" && (
ID payout
Data esecuzione
IBAN
Importo
{PAYOUTS.map(p => (
{p.id}
Auto-payout settimanale
{p.date}
{p.iban}
€{p.amount.toFixed(2).replace(".", ",")}
))}
)} {tab === "settings" && }
); } /* ─────── SETTINGS / KYC ─────── */ function SettingsTab() { return (
{/* KYC SUMMARY */}
Stato KYC
Verificato
{[ { l: "Tipologia", v: "P.IVA forfettario", done: true }, { l: "Dati anagrafici", v: "Vega Nicolò · 21/03/1992", done: true }, { l: "Documento", v: "Carta d'identità AX1234567 · verificata", done: true }, { l: "Dati fiscali", v: "P.IVA 04598720963 · regime forfettario", done: true }, { l: "IBAN payout", v: "IT60 X054 2811 1010 0000 0**4 831 · verificato", done: true }, ].map((s, i) => (
{s.done ? : i + 1}
{s.l}
{s.v}
))}
Preferenze payout
Auto-payout settimanale
Ogni lunedì viene eseguito il payout di tutti i fondi disponibili
Soglia minima on-demand
Importo minimo per payout su richiesta · default €20
Notifiche payout
Email + push quando payout viene eseguito
Dati fiscali
Tipologia P.IVA forfettario
Ragione sociale Nicolò Vega
P.IVA 04598720963
Codice fiscale VGENCL92C21F205K
Codice SDI 5RUO82D
Indirizzo Via Tortona 32 · 20144 Milano (MI)
Sonara emette ricevuta marketplace mensile per la fee. Per ogni ordine emetti tu fattura al cliente — la trovi pronta nello storico.
Conto bancario
UniCredit · primario
IT60 X054 2811 1010 0000 0**4 831
Verificato Verifica il 18 feb 2024
); } window.WalletPage = WalletPage;