🎥 Make videos programmatically with React
`remotion`: change error message from non-decreasing to increasing
Jonny Burger76250b629766
diff --git a/packages/core/src/interpolate.ts b/packages/core/src/interpolate.tsindex 00da13a8df..8defd2d311 100644--- a/packages/core/src/interpolate.ts+++ b/packages/core/src/interpolate.ts@@ -88,7 +88,7 @@ function checkValidInputRange(arr: readonly number[]) {for (let i = 1; i < arr.length; ++i) {if (!(arr[i] > arr[i - 1])) {throw new Error(- `inputRange must be strictly monotonically non-decreasing but got [${arr.join(+ `inputRange must be strictly monotonically increasing but got [${arr.join(',',)}]`,);diff --git a/packages/core/src/test/interpolate.test.ts b/packages/core/src/test/interpolate.test.tsindex 0882954c0a..32e776d03d 100644--- a/packages/core/src/test/interpolate.test.ts+++ b/packages/core/src/test/interpolate.test.ts@@ -38,10 +38,10 @@ test('Must pass at least 2 elements for input range', () => {test('Input range must be strictly monotonically non-decreasing', () => {expectToThrow(() => {interpolate(1, [0, 1, 0.5], [0, 2, 0.2]);- }, /inputRange must be strictly monotonically non-decreasing/);+ }, /inputRange must be strictly monotonically increasing/);expectToThrow(() => {interpolate(0.75, [0, 1, 1], [0, 2, 0]);- }, /inputRange must be strictly monotonically non-decreasing/);+ }, /inputRange must be strictly monotonically increasing/);});test('Output range can be non-monotonic', () => {