@remotion/lambda-client 4.0.482 → 4.0.483

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cjs/index.js CHANGED
@@ -70152,6 +70152,35 @@ function findRange(input, inputRange) {
70152
70152
  return i - 1;
70153
70153
  }
70154
70154
  var defaultEasing = (num) => num;
70155
+ var shouldExtendRightForEasing = (easing) => {
70156
+ return easing.remotionShouldExtendRight === true;
70157
+ };
70158
+ var resolveEasingForSegment = ({
70159
+ easing,
70160
+ segmentIndex
70161
+ }) => {
70162
+ if (easing === undefined) {
70163
+ return defaultEasing;
70164
+ }
70165
+ if (typeof easing === "function") {
70166
+ return easing;
70167
+ }
70168
+ return easing[segmentIndex];
70169
+ };
70170
+ var interpolateSegment = ({
70171
+ input,
70172
+ inputRange,
70173
+ outputRange,
70174
+ easing,
70175
+ extrapolateLeft,
70176
+ extrapolateRight
70177
+ }) => {
70178
+ return interpolateFunction(input, inputRange, outputRange, {
70179
+ easing,
70180
+ extrapolateLeft,
70181
+ extrapolateRight: input > inputRange[1] && extrapolateRight === "clamp" && shouldExtendRightForEasing(easing) ? "extend" : extrapolateRight
70182
+ });
70183
+ };
70155
70184
  var interpolateNumber = ({
70156
70185
  input,
70157
70186
  inputRange,
@@ -70162,15 +70191,6 @@ var interpolateNumber = ({
70162
70191
  return outputRange[0];
70163
70192
  }
70164
70193
  const easingOption = options?.easing;
70165
- const resolveEasingForSegment = (segmentIndex) => {
70166
- if (easingOption === undefined) {
70167
- return defaultEasing;
70168
- }
70169
- if (typeof easingOption === "function") {
70170
- return easingOption;
70171
- }
70172
- return easingOption[segmentIndex];
70173
- };
70174
70194
  let extrapolateLeft = "extend";
70175
70195
  if (options?.extrapolateLeft !== undefined) {
70176
70196
  extrapolateLeft = options.extrapolateLeft;
@@ -70181,11 +70201,41 @@ var interpolateNumber = ({
70181
70201
  }
70182
70202
  const posterizedInput = options?.posterize === undefined ? input : Math.floor(input / options.posterize) * options.posterize;
70183
70203
  const range = findRange(posterizedInput, inputRange);
70184
- return interpolateFunction(posterizedInput, [inputRange[range], inputRange[range + 1]], [outputRange[range], outputRange[range + 1]], {
70185
- easing: resolveEasingForSegment(range),
70204
+ const easing = resolveEasingForSegment({
70205
+ easing: easingOption,
70206
+ segmentIndex: range
70207
+ });
70208
+ let result = interpolateSegment({
70209
+ input: posterizedInput,
70210
+ inputRange: [inputRange[range], inputRange[range + 1]],
70211
+ outputRange: [outputRange[range], outputRange[range + 1]],
70212
+ easing,
70186
70213
  extrapolateLeft,
70187
70214
  extrapolateRight
70188
70215
  });
70216
+ for (let segmentIndex = 0;segmentIndex < range; segmentIndex++) {
70217
+ const previousEasing = resolveEasingForSegment({
70218
+ easing: easingOption,
70219
+ segmentIndex
70220
+ });
70221
+ if (!shouldExtendRightForEasing(previousEasing)) {
70222
+ continue;
70223
+ }
70224
+ const previousSegmentEnd = inputRange[segmentIndex + 1];
70225
+ if (posterizedInput <= previousSegmentEnd) {
70226
+ continue;
70227
+ }
70228
+ const continuedSegmentValue = interpolateSegment({
70229
+ input: posterizedInput,
70230
+ inputRange: [inputRange[segmentIndex], previousSegmentEnd],
70231
+ outputRange: [outputRange[segmentIndex], outputRange[segmentIndex + 1]],
70232
+ easing: previousEasing,
70233
+ extrapolateLeft,
70234
+ extrapolateRight: "extend"
70235
+ });
70236
+ result += continuedSegmentValue - outputRange[segmentIndex + 1];
70237
+ }
70238
+ return result;
70189
70239
  };
70190
70240
  var interpolateString = ({
70191
70241
  input,
@@ -71351,7 +71401,7 @@ var validateDownloadBehavior = (downloadBehavior) => {
71351
71401
  }
71352
71402
  }
71353
71403
  };
71354
- var VERSION = "4.0.482";
71404
+ var VERSION = "4.0.483";
71355
71405
  var isColorSupported = () => {
71356
71406
  const env = process.env || {};
71357
71407
  const isForceDisabled = "NO_COLOR" in env;
@@ -69495,6 +69495,35 @@ function findRange(input, inputRange) {
69495
69495
  return i - 1;
69496
69496
  }
69497
69497
  var defaultEasing = (num) => num;
69498
+ var shouldExtendRightForEasing = (easing) => {
69499
+ return easing.remotionShouldExtendRight === true;
69500
+ };
69501
+ var resolveEasingForSegment = ({
69502
+ easing,
69503
+ segmentIndex
69504
+ }) => {
69505
+ if (easing === undefined) {
69506
+ return defaultEasing;
69507
+ }
69508
+ if (typeof easing === "function") {
69509
+ return easing;
69510
+ }
69511
+ return easing[segmentIndex];
69512
+ };
69513
+ var interpolateSegment = ({
69514
+ input,
69515
+ inputRange,
69516
+ outputRange,
69517
+ easing,
69518
+ extrapolateLeft,
69519
+ extrapolateRight
69520
+ }) => {
69521
+ return interpolateFunction(input, inputRange, outputRange, {
69522
+ easing,
69523
+ extrapolateLeft,
69524
+ extrapolateRight: input > inputRange[1] && extrapolateRight === "clamp" && shouldExtendRightForEasing(easing) ? "extend" : extrapolateRight
69525
+ });
69526
+ };
69498
69527
  var interpolateNumber = ({
69499
69528
  input,
69500
69529
  inputRange,
@@ -69505,15 +69534,6 @@ var interpolateNumber = ({
69505
69534
  return outputRange[0];
69506
69535
  }
69507
69536
  const easingOption = options?.easing;
69508
- const resolveEasingForSegment = (segmentIndex) => {
69509
- if (easingOption === undefined) {
69510
- return defaultEasing;
69511
- }
69512
- if (typeof easingOption === "function") {
69513
- return easingOption;
69514
- }
69515
- return easingOption[segmentIndex];
69516
- };
69517
69537
  let extrapolateLeft = "extend";
69518
69538
  if (options?.extrapolateLeft !== undefined) {
69519
69539
  extrapolateLeft = options.extrapolateLeft;
@@ -69524,11 +69544,41 @@ var interpolateNumber = ({
69524
69544
  }
69525
69545
  const posterizedInput = options?.posterize === undefined ? input : Math.floor(input / options.posterize) * options.posterize;
69526
69546
  const range = findRange(posterizedInput, inputRange);
69527
- return interpolateFunction(posterizedInput, [inputRange[range], inputRange[range + 1]], [outputRange[range], outputRange[range + 1]], {
69528
- easing: resolveEasingForSegment(range),
69547
+ const easing = resolveEasingForSegment({
69548
+ easing: easingOption,
69549
+ segmentIndex: range
69550
+ });
69551
+ let result = interpolateSegment({
69552
+ input: posterizedInput,
69553
+ inputRange: [inputRange[range], inputRange[range + 1]],
69554
+ outputRange: [outputRange[range], outputRange[range + 1]],
69555
+ easing,
69529
69556
  extrapolateLeft,
69530
69557
  extrapolateRight
69531
69558
  });
69559
+ for (let segmentIndex = 0;segmentIndex < range; segmentIndex++) {
69560
+ const previousEasing = resolveEasingForSegment({
69561
+ easing: easingOption,
69562
+ segmentIndex
69563
+ });
69564
+ if (!shouldExtendRightForEasing(previousEasing)) {
69565
+ continue;
69566
+ }
69567
+ const previousSegmentEnd = inputRange[segmentIndex + 1];
69568
+ if (posterizedInput <= previousSegmentEnd) {
69569
+ continue;
69570
+ }
69571
+ const continuedSegmentValue = interpolateSegment({
69572
+ input: posterizedInput,
69573
+ inputRange: [inputRange[segmentIndex], previousSegmentEnd],
69574
+ outputRange: [outputRange[segmentIndex], outputRange[segmentIndex + 1]],
69575
+ easing: previousEasing,
69576
+ extrapolateLeft,
69577
+ extrapolateRight: "extend"
69578
+ });
69579
+ result += continuedSegmentValue - outputRange[segmentIndex + 1];
69580
+ }
69581
+ return result;
69532
69582
  };
69533
69583
  var interpolateString = ({
69534
69584
  input,
@@ -70694,7 +70744,7 @@ var validateDownloadBehavior = (downloadBehavior) => {
70694
70744
  }
70695
70745
  }
70696
70746
  };
70697
- var VERSION = "4.0.482";
70747
+ var VERSION = "4.0.483";
70698
70748
  var isColorSupported = () => {
70699
70749
  const env = process.env || {};
70700
70750
  const isForceDisabled = "NO_COLOR" in env;
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "url": "https://github.com/remotion-dev/remotion/tree/main/packages/lambda-client"
4
4
  },
5
5
  "name": "@remotion/lambda-client",
6
- "version": "4.0.482",
6
+ "version": "4.0.483",
7
7
  "main": "dist/cjs/index.js",
8
8
  "scripts": {
9
9
  "formatting": "oxfmt src --check",
@@ -26,10 +26,10 @@
26
26
  "@aws-sdk/lib-storage": "3.986.0",
27
27
  "mime-types": "2.1.34",
28
28
  "@aws-sdk/credential-provider-ini": "3.972.5",
29
- "@remotion/serverless-client": "4.0.482",
29
+ "@remotion/serverless-client": "4.0.483",
30
30
  "@types/express": "5.0.1",
31
31
  "express": "4.21.0",
32
- "@remotion/eslint-config-internal": "4.0.482",
32
+ "@remotion/eslint-config-internal": "4.0.483",
33
33
  "eslint": "9.19.0",
34
34
  "next": "16.2.6",
35
35
  "@types/mime-types": "2.1.1",