Spaces:
Sleeping
Sleeping
Update index.html
Browse files12 unmodified lines1314151617181719202122232425138 unmodified lines164165166167168169170171172173174175176177178179180181182183184185100 unmodified lines28628728826928929029129242 unmodified lines33533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536612 unmodified lines *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; } html, body, #root { min-height: 100vh; } body { background: #0A0C0F; color: #E8EBF0; font-family: 'Inter', system-ui, sans-serif; overflow-x: hidden; } /* Tyylitelty scrollbar, pätee myös uuteen bulk-listaan */ ::-webkit-scrollbar { width: 6px; } ::-webkit-scrollbar-track { background: #0A0C0F; } ::-webkit-scrollbar-track { background: transparent; } ::-webkit-scrollbar-thumb { background: #FF6B2B55; border-radius: 3px; } ::-webkit-scrollbar-thumb:hover { background: #FF6B2B88; } #bg-video { position: fixed; top: 50%; left: 50%;138 unmodified lines }; }, [items]);
// Bulk / Stacked items laskenta (yli 3 kpl samaa esinettä) const bulkItems = useMemo(() => { const counts = {}; items.forEach(item => { if (!counts[item.name]) { counts[item.name] = { name: item.name, count: 0 }; } counts[item.name].count += 1; }); // Suodatetaan yli 3 kpl sisältävät ja järjestetään laskevasti return Object.values(counts) .filter(x => x.count > 3) .sort((a, b) => b.count - a.count); }, [items]);
// Filtteröintilogiikka const filtered = useMemo(() => { let list = [...items];100 unmodified lines )} </div>
{/* OIKEA PUOLI (PUNAINEN NELIÖ): Stats & Secondary Filters */} {/* OIKEA PUOLI (PUNAINEN NELIÖ): Stats, Categories & Bulk list */} <div className="glass" style={{ flex: '0 0 320px', position: 'sticky', top: '100px', padding: '24px', display: 'flex', flexDirection: 'column', gap: '28px' }}> {/* Statistiikka */}42 unmodified lines ))} </div> </div>
{/* Bulk Items (Yli 3 kpl samoja esineitä) */} {bulkItems.length > 0 && ( <div> <h3 style={{ fontSize: 12, color: F.muted, letterSpacing: '0.1em', textTransform: 'uppercase', marginBottom: 12, borderBottom: `1px solid ${F.border}`, paddingBottom: 8 }}> Bulk Items (>3) </h3> <div style={{ display: 'flex', flexDirection: 'column', gap: 8, maxHeight: '300px', overflowY: 'auto', paddingRight: '4px' }}> {bulkItems.map(b => ( <div key={b.name} style={{ display: 'flex', justifyContent: 'space-between', alignItems: 'center', background: 'rgba(255,255,255,0.02)', padding: '8px 12px', borderRadius: 6, border: `1px solid ${F.border}` }}> <span style={{ fontSize: 12, color: F.text, whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis', marginRight: 8 }} title={b.name}> {b.name} </span> <span style={{ fontSize: 11, fontWeight: 700, color: F.accent, background: F.accentGlow, padding: '2px 6px', borderRadius: 4, flexShrink: 0 }}> {b.count}x </span> </div> ))} </div> </div> )}
</div>
</div>index.html+48-2