|
|
|
@ -465,10 +465,9 @@ const Audio: React.FC<IAudio> = (props) => {
|
|
|
|
|
<canvas
|
|
|
|
|
role='button'
|
|
|
|
|
tabIndex={0}
|
|
|
|
|
className='audio-player__canvas'
|
|
|
|
|
className='audio-player__canvas absolute left-0 top-0 w-full'
|
|
|
|
|
width={width}
|
|
|
|
|
height={height}
|
|
|
|
|
style={{ width: '100%', position: 'absolute', top: 0, left: 0 }}
|
|
|
|
|
ref={canvas}
|
|
|
|
|
onClick={togglePlay}
|
|
|
|
|
onKeyDown={handleAudioKeyDown}
|
|
|
|
@ -480,15 +479,12 @@ const Audio: React.FC<IAudio> = (props) => {
|
|
|
|
|
<img
|
|
|
|
|
src={poster}
|
|
|
|
|
alt=''
|
|
|
|
|
className='pointer-events-none absolute aspect-1 -translate-x-1/2 -translate-y-1/2 rounded-full object-cover'
|
|
|
|
|
width={(_getRadius() - TICK_SIZE) * 2}
|
|
|
|
|
height={(_getRadius() - TICK_SIZE) * 2}
|
|
|
|
|
style={{
|
|
|
|
|
position: 'absolute',
|
|
|
|
|
left: _getCX(),
|
|
|
|
|
top: _getCY(),
|
|
|
|
|
transform: 'translate(-50%, -50%)',
|
|
|
|
|
borderRadius: '50%',
|
|
|
|
|
pointerEvents: 'none',
|
|
|
|
|
}}
|
|
|
|
|
/>
|
|
|
|
|
)}
|
|
|
|
|