<script> $(document).ready(function(){ 'use strict'; const $container = $('#article [name="canvas"] .content'); if (!$container.length) return; const root = $container[0]; const article = document.querySelector('#article'); if (root.sparklingCleanup) { root.sparklingCleanup(); } $container.find('canvas').remove(); // ───────────────────────────────────── // SETTINGS — STARS // ───────────────────────────────────── const p = { density: 34, intensity: 60, length: 72, speed: 22, bloom: 22 }; // ───────────────────────────────────── // SETTINGS — CURSOR WALKERS // ───────────────────────────────────── const WALKER_WIDTH = 210; const WALKER_INTENSITY = 0.49; const WALKER_LIFE = 0.75; const WALKER_COUNT = 84; // Warm champagne light palette const LIGHT_COLORS = { outer: '232,201,166', inner: '255,234,210', core: '255,249,238', fibers: '245,223,196' }; const Z_INDEX = 9999; // ───────────────────────────────────── // CANVAS // ───────────────────────────────────── const canvas = document.createElement('canvas'); canvas.id = 'sparkling-page-overlay'; canvas.setAttribute('aria-hidden', 'true'); canvas.style.cssText = ` position: fixed !important; top: 0 !important; left: 0 !important; width: 100vw !important; height: 100vh !important; margin: 0 !important; padding: 0 !important; border: 0 !important; display: block !important; background: transparent !important; pointer-events: none !important; z-index: ${Z_INDEX} !important; `; document.body.appendChild(canvas); const ctx = canvas.getContext('2d'); const starLayer = document.createElement('canvas'); const sc = starLayer.getContext('2d'); const cursorLayer = document.createElement('canvas'); const cc = cursorLayer.getContext('2d'); let W = 0; let H = 0; let time = 0; let last = 0; let raf = 0; let active = true; // ───────────────────────────────────── // POINTER // ───────────────────────────────────── const mouse = { x: 0, y: 0, inside: false }; let brush = null; let energy = 0; let angle = 0; let spin = 0; let history = []; let clock = 0; let cursorLast = 0; // ───────────────────────────────────── // STAR DISTRIBUTION // ───────────────────────────────────── // Stars are generated in document space. // Only visible tiles are rendered. const TILE_SIZE = 512; const tileCache = new Map(); const STAR_DENSITY = (30 + p.density * 18) / (1920 * 1080); const STARS_PER_TILE = Math.round( TILE_SIZE * TILE_SIZE * STAR_DENSITY ); // Deterministic random generator function seededRandom(seed) { let state = seed >>> 0; return function() { state = ( Math.imul(1664525, state) + 1013904223 ) >>> 0; return state / 4294967296; }; } function getTile(tx, ty) { const key = tx + ':' + ty; if (tileCache.has(key)) { return tileCache.get(key); } const seed = ( Math.imul(tx, 73856093) ^ Math.imul(ty, 19349663) ^ 83492791 ) >>> 0; const random = seededRandom(seed); const stars = []; for (let i = 0; i < STARS_PER_TILE; i++) { stars.push({ x: tx * TILE_SIZE + random() * TILE_SIZE, y: ty * TILE_SIZE + random() * TILE_SIZE, r: 205, g: 224, b: 255, power: 0.45 + random() * 0.55, phase: random() * Math.PI * 2, seed: random() * 1000 }); } tileCache.set(key, stars); return stars; } // ───────────────────────────────────── // RESIZE // ───────────────────────────────────── function resize() { W = Math.max( 1, window.innerWidth ); H = Math.max( 1, window.innerHeight ); for (const c of [ canvas, starLayer, cursorLayer ]) { c.width = W; c.height = H; } brush = null; history = []; energy = 0; mouse.inside = false; } // ───────────────────────────────────── // ARTICLE BOUNDS // ───────────────────────────────────── function getArticleBounds() { const r = article.getBoundingClientRect(); return { left: r.left + window.scrollX, top: r.top + window.scrollY, right: r.right + window.scrollX, bottom: r.bottom + window.scrollY }; } // ───────────────────────────────────── // POINTER TRACKING // ───────────────────────────────────── function pointer(e) { if (e.pointerType === 'touch') { mouse.inside = false; return; } const r = article.getBoundingClientRect(); mouse.inside = e.clientX >= 0 && e.clientX <= W && e.clientY >= 0 && e.clientY <= H && e.clientX >= r.left && e.clientX <= r.right && e.clientY >= r.top && e.clientY <= r.bottom; if (mouse.inside) { mouse.x = e.clientX; mouse.y = e.clientY; } } function leave() { mouse.inside = false; brush = null; } function onOut(e) { if (!e.relatedTarget) { leave(); } } function onScroll() { // Prevent unwanted light lines // caused by scrolling. brush = null; mouse.inside = false; energy = 0; } // ───────────────────────────────────── // STAR COLOR // ───────────────────────────────────── function color(q, a) { const r = Math.min( 255, Math.round(q.r * 0.45 + 140) ); const g = Math.min( 255, Math.round(q.g * 0.45 + 140) ); const b = Math.min( 255, Math.round(q.b * 0.45 + 140) ); const alpha = Math.max( 0, Math.min(1, a) ); return `rgba(${r},${g},${b},${alpha})`; } // ───────────────────────────────────── // OPTICAL GLOW // ───────────────────────────────────── function glow(c, q, x, y, r, a) { if (r < 0.5 || a <= 0) return; const g = c.createRadialGradient( x, y, 0, x, y, r ); g.addColorStop( 0, color(q, a) ); g.addColorStop( 0.2, color(q, a * 0.45) ); g.addColorStop( 1, color(q, 0) ); c.fillStyle = g; c.fillRect( x - r, y - r, r * 2, r * 2 ); } // ───────────────────────────────────── // DRAW INDIVIDUAL STAR // ───────────────────────────────────── function drawStar(q, x, y) { const I = p.intensity / 100; const L = p.length / 100; const S = p.speed / 100; const B = p.bloom / 100; const pulse = Math.pow( 0.5 + 0.5 * Math.sin( time * (0.8 + S * 4) * (1 + q.seed % 1) + q.phase ), 5 ); const a = I * q.power * pulse; if (a < 0.012) return; const r = 1 + q.power * 2; // Soft optical bloom glow( sc, q, x, y, r * (2 + B * 9), a * B * 0.7 ); // Star ray length const len = (4 + L * 65) * pulse * q.power; const rays = [ [len, 0], [-len, 0], [0, len * 0.42], [0, -len * 0.42] ]; // Four optical rays for (const [dx, dy] of rays) { const g = sc.createLinearGradient( x, y, x + dx, y + dy ); g.addColorStop( 0, color(q, a) ); g.addColorStop( 1, color(q, 0) ); sc.strokeStyle = g; sc.lineWidth = 0.8; sc.beginPath(); sc.moveTo( x, y ); sc.lineTo( x + dx, y + dy ); sc.stroke(); } // Bright center glow( sc, q, x, y, 2.5, a ); } // ───────────────────────────────────── // ANIMATED STARS — FULL PAGE // ───────────────────────────────────── function drawStars() { sc.clearRect(0, 0, W, H); const sx = window.scrollX; const sy = window.scrollY; const bounds = getArticleBounds(); const margin = 100; const left = Math.max( bounds.left, sx - margin ); const right = Math.min( bounds.right, sx + W + margin ); const top = Math.max( bounds.top, sy - margin ); const bottom = Math.min( bounds.bottom, sy + H + margin ); if ( right <= left || bottom <= top ) { return; } const minTX = Math.floor(left / TILE_SIZE); const maxTX = Math.floor(right / TILE_SIZE); const minTY = Math.floor(top / TILE_SIZE); const maxTY = Math.floor(bottom / TILE_SIZE); sc.save(); // Limit stars to the article area. sc.beginPath(); sc.rect( bounds.left - sx, bounds.top - sy, bounds.right - bounds.left, bounds.bottom - bounds.top ); sc.clip(); sc.globalCompositeOperation = 'lighter'; for ( let ty = minTY; ty <= maxTY; ty++ ) { for ( let tx = minTX; tx <= maxTX; tx++ ) { const stars = getTile(tx, ty); for (const q of stars) { if ( q.x < bounds.left || q.x > bounds.right || q.y < bounds.top || q.y > bounds.bottom ) { continue; } const x = q.x - sx; const y = q.y - sy; if ( x < -margin || x > W + margin || y < -margin || y > H + margin ) { continue; } drawStar(q, x, y); } } } sc.restore(); // Remove distant tiles from memory. // Their positions are recreated // identically when scrolling back. if (tileCache.size > 120) { for (const key of tileCache.keys()) { const parts = key.split(':'); const tx = Number(parts[0]); const ty = Number(parts[1]); if ( tx < minTX - 2 || tx > maxTX + 2 || ty < minTY - 2 || ty > maxTY + 2 ) { tileCache.delete(key); } } } } // ───────────────────────────────────── // LIGHT WALKERS // ───────────────────────────────────── const fibers = Array.from( { length: WALKER_COUNT }, (_, i) => ({ u: i / (WALKER_COUNT - 1) * 2 - 1, phase: i * 2.39996 }) ); // ───────────────────────────────────── // DRAW LIGHT SEGMENT // ───────────────────────────────────── function segment(a, b, w, alpha, rgb) { if (alpha <= 0) return; cc.strokeStyle = `rgba(${rgb},${Math.min(1, alpha)})`; cc.lineWidth = w; cc.beginPath(); cc.moveTo( a.x, a.y ); cc.lineTo( b.x, b.y ); cc.stroke(); } // ───────────────────────────────────── // INDIVIDUAL FIBER POSITION // ───────────────────────────────────── function fiberPosition(point, fiber) { const offset = fiber.u * point.width * 0.5; const bend = Math.sin( point.spin * 1.4 + fiber.u * 3 ) * offset * 0.22; return { x: point.x + Math.cos(point.angle) * offset - Math.sin(point.angle) * bend, y: point.y + Math.sin(point.angle) * offset + Math.cos(point.angle) * bend }; } // ───────────────────────────────────── // CURSOR LIGHT RENDER // ───────────────────────────────────── function cursorRender(dt) { const now = performance.now(); dt = cursorLast ? Math.min( 3, (now - cursorLast) / 1000 ) : dt; cursorLast = now; clock += dt; const life = WALKER_LIFE; const power = WALKER_INTENSITY; if (!mouse.inside) { brush = null; energy = 0; } else { if (!brush) { brush = { x: mouse.x, y: mouse.y, last: null }; } const dx = mouse.x - brush.x; const dy = mouse.y - brush.y; const k = 1 - Math.exp(-dt * 9); const vx = dx * k; const vy = dy * k; brush.x += vx; brush.y += vy; const speed = Math.hypot(vx, vy) / Math.max(dt, 0.001); energy += ( Math.min(1, speed / 180) - energy ) * ( 1 - Math.exp(-dt * 10) ); if (speed > 12) { const a = Math.atan2(vy, vx) + Math.PI / 2; const diff = 0.5 * Math.atan2( Math.sin(2 * (a - angle)), Math.cos(2 * (a - angle)) ); angle += diff * ( 1 - Math.exp(-dt * 5) ); spin += dt * 1.6; // Dynamic walker width const width = WALKER_WIDTH * ( 0.24 + 0.76 * ( 0.5 + 0.5 * Math.sin(spin) ) ) * ( 0.45 + 0.55 * energy ); const next = { x: brush.x, y: brush.y, angle, width, spin, energy }; if (brush.last) { history.push({ a: brush.last, b: next, t: clock }); } brush.last = next; } else { brush.last = null; } } // Remove expired light trails history = history.filter( h => clock - h.t < life ); cc.clearRect( 0, 0, W, H ); if (!history.length) return; cc.globalCompositeOperation = 'lighter'; cc.lineCap = 'round'; // Render accumulated light history for (const h of history) { const fade = Math.pow( Math.max( 0, 1 - (clock - h.t) / life ), 1.7 ); const v = fade * power * h.b.energy; // Warm outer glow segment( h.a, h.b, 15, v * 0.10, LIGHT_COLORS.outer ); // Champagne inner glow segment( h.a, h.b, 6, v * 0.28, LIGHT_COLORS.inner ); // Bright ivory core segment( h.a, h.b, 2.4, v * 0.65, LIGHT_COLORS.core ); // Fine warm optical fibers for (const f of fibers) { const weight = Math.exp( -Math.abs(f.u) * 1.5 ); segment( fiberPosition(h.a, f), fiberPosition(h.b, f), 0.48, v * 0.17 * weight, LIGHT_COLORS.fibers ); } } // Composite cursor light ctx.save(); const r = article.getBoundingClientRect(); ctx.beginPath(); ctx.rect( r.left, r.top, r.width, r.height ); ctx.clip(); ctx.globalCompositeOperation = 'lighter'; // Soft optical bloom ctx.save(); ctx.globalAlpha = 0.35; ctx.filter = 'blur(7px)'; ctx.drawImage( cursorLayer, 0, 0 ); ctx.restore(); // Sharp light fibers ctx.drawImage( cursorLayer, 0, 0 ); ctx.restore(); } // ───────────────────────────────────── // ANIMATION LOOP // ───────────────────────────────────── function frame(now) { if ( !active || !root.isConnected || !article.isConnected ) { cleanup(); return; } const dt = last ? Math.min( 0.05, (now - last) / 1000 ) : 0.016; last = now; time += dt; // Transparent background ctx.globalCompositeOperation = 'source-over'; ctx.clearRect( 0, 0, W, H ); // Layer 1 — animated stars drawStars(); ctx.drawImage( starLayer, 0, 0 ); // Layer 2 — warm cursor light cursorRender(dt); raf = requestAnimationFrame(frame); } // ───────────────────────────────────── // VISIBILITY // ───────────────────────────────────── function onVisibilityChange() { if (document.hidden) { cancelAnimationFrame(raf); leave(); history = []; ctx.clearRect( 0, 0, W, H ); } else if (active) { last = 0; cursorLast = 0; cancelAnimationFrame(raf); raf = requestAnimationFrame(frame); } } // ───────────────────────────────────── // INITIALIZATION // ───────────────────────────────────── resize(); window.addEventListener( 'resize', resize, { passive: true } ); window.addEventListener( 'pointermove', pointer, { passive: true } ); window.addEventListener( 'blur', leave ); window.addEventListener( 'scroll', onScroll, { passive: true } ); document.addEventListener( 'pointerout', onOut ); document.addEventListener( 'visibilitychange', onVisibilityChange ); if (!document.hidden) { raf = requestAnimationFrame(frame); } // ───────────────────────────────────── // CLEANUP // ───────────────────────────────────── function cleanup() { active = false; cancelAnimationFrame(raf); window.removeEventListener( 'resize', resize ); window.removeEventListener( 'pointermove', pointer ); window.removeEventListener( 'blur', leave ); window.removeEventListener( 'scroll', onScroll ); document.removeEventListener( 'pointerout', onOut ); document.removeEventListener( 'visibilitychange', onVisibilityChange ); tileCache.clear(); history = []; canvas.remove(); delete root.sparklingCleanup; } root.sparklingCleanup = cleanup; }); </script>
The Sparkle Issue
T

образ жизни •

the Sparkle Issue

3 декабря 2026

126 лет назад, также в начале декабря, в Лейпциге вышел первый номер газеты «Искра», и на этом все сходство того печатного издания с нашим — заканчивается. Этот искрящийся, как бенгальский огонь, выпуск не собирается разжигать пожар революции, но хочет напомнить, что даже в непроглядной тьме предновогодней ночи всегда найдутся проблески надежды, а счастье, как пел когда-то король российской эстрады, — «лишь только вспышка». И у нас этих вспышек целая россыпь — люди с ярчайшей искрой таланта, наряды для тех, кто хочет сиять, украшения, которые никогда не состарятся, золотой век клубной культуры и другие сокровища. Наденьте темные очки, чтобы следить
за обновлениями.

Интервью с Юлией Снигирь и Алисой Юнусовой

В фильме «Дива» они соревнуются в пении, а здесь — поддерживают друг друга словом.

Канкан-капкан. Расцвет
и увядание парижского кабаре

Алексей Тарханов о торжестве объективации и безопасных переживаниях XXI века.

Вы стали более лучше одеваться

Встречаем по одежке всех, у кого руки в брюки, дело в шляпе и два сапога — пара.

Материалы еще будут добавляться, оставайтесь на связи