mirror of
https://github.com/captbaritone/webamp.git
synced 2026-07-19 09:33:47 +00:00
Inline style
This commit is contained in:
parent
e345d07e41
commit
e7c474e7f6
1 changed files with 5 additions and 6 deletions
|
|
@ -123,11 +123,6 @@ const Marquee = React.memo(() => {
|
|||
const { handleMouseDown, dragOffset, dragging } = useDragX();
|
||||
const offset = stepOffset(text, marqueeStep, dragOffset);
|
||||
const offsetPixels = pixelUnits(-offset);
|
||||
const style: React.CSSProperties = {
|
||||
whiteSpace: "nowrap",
|
||||
willChange: "transform",
|
||||
transform: `translateX(${offsetPixels})`,
|
||||
};
|
||||
|
||||
useStepper({ step: stepMarquee, dragging });
|
||||
|
||||
|
|
@ -139,7 +134,11 @@ const Marquee = React.memo(() => {
|
|||
title="Song Title"
|
||||
>
|
||||
<div
|
||||
style={style}
|
||||
style={{
|
||||
whiteSpace: "nowrap",
|
||||
willChange: "transform",
|
||||
transform: `translateX(${offsetPixels})`,
|
||||
}}
|
||||
// Force the DOM node to be recreated when the doubled size changes.
|
||||
// This works around a Chrome browser bug where the `will-change: transform;`
|
||||
// on this node seems to cause a change to the `image-rendering:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue