12d7f24d0f
Introduce new UI and behavior for playing audio attachments in conversations. Previously, playback stopped unexpectedly during window resizes and scrolling through the messages due to the row height recomputation in `react-virtualized`. With this commit we introduce `<GlobalAudioContext/>` instance that wraps whole conversation and provides an `<audio/>` element that doesn't get re-rendered (or destroyed) whenever `react-virtualized` recomputes messages. The audio players (with a freshly designed UI) now share this global `<audio/>` instance and manage access to it using `audioPlayer.owner` state from the redux. New UI computes on the fly, caches, and displays waveforms for each audio attachment. Storybook had to be slightly modified to accomodate testing of Android bubbles by introducing the new knob for `authorColor`.
1 line
No EOL
373 B
XML
1 line
No EOL
373 B
XML
<svg width="20" height="20" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M7.917 1.667H3.75a.417.417 0 0 0-.417.416v15.834c0 .23.187.416.417.416h4.167c.23 0 .416-.186.416-.416V2.083a.417.417 0 0 0-.416-.416zM16.25 1.667h-4.167a.417.417 0 0 0-.416.416v15.834c0 .23.186.416.416.416h4.167c.23 0 .417-.186.417-.416V2.083a.417.417 0 0 0-.417-.416z" fill="#000"/></svg> |