From fbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Fri, 19 Apr 2024 03:14:29 +0200 Subject: Merging upstream version 125.0.1. Signed-off-by: Daniel Baumann --- devtools/client/inspector/animation/components/App.js | 2 +- devtools/client/inspector/animation/components/NoAnimationPanel.js | 2 +- .../client/inspector/animation/components/PlaybackRateSelector.js | 2 +- .../animation/test/browser_animation_keyframes-progress-bar.js | 2 +- .../client/inspector/animation/test/summary-graph_delay-sign_head.js | 5 +++-- .../inspector/animation/test/summary-graph_end-delay-sign_head.js | 5 +++-- 6 files changed, 10 insertions(+), 8 deletions(-) (limited to 'devtools/client/inspector/animation') diff --git a/devtools/client/inspector/animation/components/App.js b/devtools/client/inspector/animation/components/App.js index 75a000286c..74ce8e7b40 100644 --- a/devtools/client/inspector/animation/components/App.js +++ b/devtools/client/inspector/animation/components/App.js @@ -60,7 +60,7 @@ class App extends Component { }; } - shouldComponentUpdate(nextProps, nextState) { + shouldComponentUpdate(nextProps) { return ( this.props.animations.length !== 0 || nextProps.animations.length !== 0 ); diff --git a/devtools/client/inspector/animation/components/NoAnimationPanel.js b/devtools/client/inspector/animation/components/NoAnimationPanel.js index ea034e413d..260325518b 100644 --- a/devtools/client/inspector/animation/components/NoAnimationPanel.js +++ b/devtools/client/inspector/animation/components/NoAnimationPanel.js @@ -26,7 +26,7 @@ class NoAnimationPanel extends Component { }; } - shouldComponentUpdate(nextProps, nextState) { + shouldComponentUpdate(nextProps) { return this.props.elementPickerEnabled != nextProps.elementPickerEnabled; } diff --git a/devtools/client/inspector/animation/components/PlaybackRateSelector.js b/devtools/client/inspector/animation/components/PlaybackRateSelector.js index 2d0de53a0c..9f2c56cdb6 100644 --- a/devtools/client/inspector/animation/components/PlaybackRateSelector.js +++ b/devtools/client/inspector/animation/components/PlaybackRateSelector.js @@ -28,7 +28,7 @@ class PlaybackRateSelector extends PureComponent { }; } - static getDerivedStateFromProps(props, state) { + static getDerivedStateFromProps(props) { const { animations, playbackRates } = props; const currentPlaybackRates = sortAndUnique( diff --git a/devtools/client/inspector/animation/test/browser_animation_keyframes-progress-bar.js b/devtools/client/inspector/animation/test/browser_animation_keyframes-progress-bar.js index a7051d9a01..bb69249907 100644 --- a/devtools/client/inspector/animation/test/browser_animation_keyframes-progress-bar.js +++ b/devtools/client/inspector/animation/test/browser_animation_keyframes-progress-bar.js @@ -91,7 +91,7 @@ add_task(async function () { } }); -function assertPosition(barEl, areaEl, expectedRate, animationInspector) { +function assertPosition(barEl, areaEl, expectedRate) { const controllerBounds = areaEl.getBoundingClientRect(); const barBounds = barEl.getBoundingClientRect(); const barX = barBounds.x + barBounds.width / 2 - controllerBounds.x; diff --git a/devtools/client/inspector/animation/test/summary-graph_delay-sign_head.js b/devtools/client/inspector/animation/test/summary-graph_delay-sign_head.js index fd601821b6..fffd653b1d 100644 --- a/devtools/client/inspector/animation/test/summary-graph_delay-sign_head.js +++ b/devtools/client/inspector/animation/test/summary-graph_delay-sign_head.js @@ -75,8 +75,9 @@ async function testSummaryGraphDelaySign() { function assertExpected(key) { const actual = parseFloat(delaySignEl.style[key]); const expected = parseFloat(expectedResult[key]); - ok( - Math.abs(actual - expected) < 0.01, + Assert.less( + Math.abs(actual - expected), + 0.01, `${key} should be ${expected} (got ${actual})` ); } diff --git a/devtools/client/inspector/animation/test/summary-graph_end-delay-sign_head.js b/devtools/client/inspector/animation/test/summary-graph_end-delay-sign_head.js index f87a554420..09838fcadf 100644 --- a/devtools/client/inspector/animation/test/summary-graph_end-delay-sign_head.js +++ b/devtools/client/inspector/animation/test/summary-graph_end-delay-sign_head.js @@ -69,8 +69,9 @@ async function testSummaryGraphEndDelaySign() { function assertExpected(key) { const actual = parseFloat(endDelaySignEl.style[key]); const expected = parseFloat(expectedResult[key]); - ok( - Math.abs(actual - expected) < 0.01, + Assert.less( + Math.abs(actual - expected), + 0.01, `${key} should be ${expected} (got ${actual})` ); } -- cgit v1.2.3