framer-motion 8.3.3 → 8.3.4

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
@@ -588,8 +588,8 @@ const scale = {
588
588
  // to avoid exponents
589
589
  const sanitize = (v) => Math.round(v * 100000) / 100000;
590
590
  const floatRegex = /(-)?([\d]*\.?[\d])+/g;
591
- const colorRegex = /(#[0-9a-f]{6}|#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi;
592
- const singleColorRegex = /^(#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;
591
+ const colorRegex = /(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi;
592
+ const singleColorRegex = /^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;
593
593
  function isString(v) {
594
594
  return typeof v === "string";
595
595
  }
@@ -2072,7 +2072,7 @@ class MotionValue {
2072
2072
  * This will be replaced by the build step with the latest version number.
2073
2073
  * When MotionValues are provided to motion components, warn if versions are mixed.
2074
2074
  */
2075
- this.version = "8.3.3";
2075
+ this.version = "8.3.4";
2076
2076
  /**
2077
2077
  * Duration, in milliseconds, since last updating frame.
2078
2078
  *
@@ -5928,7 +5928,7 @@ function updateMotionValuesFromProps(element, next, prev) {
5928
5928
  * and warn against mismatches.
5929
5929
  */
5930
5930
  if (process.env.NODE_ENV === "development") {
5931
- warnOnce(nextValue.version === "8.3.3", `Attempting to mix Framer Motion versions ${nextValue.version} with 8.3.3 may not work as expected.`);
5931
+ warnOnce(nextValue.version === "8.3.4", `Attempting to mix Framer Motion versions ${nextValue.version} with 8.3.4 may not work as expected.`);
5932
5932
  }
5933
5933
  }
5934
5934
  else if (isMotionValue(prevValue)) {
@@ -22,7 +22,7 @@ function updateMotionValuesFromProps(element, next, prev) {
22
22
  * and warn against mismatches.
23
23
  */
24
24
  if (process.env.NODE_ENV === "development") {
25
- warnOnce(nextValue.version === "8.3.3", `Attempting to mix Framer Motion versions ${nextValue.version} with 8.3.3 may not work as expected.`);
25
+ warnOnce(nextValue.version === "8.3.4", `Attempting to mix Framer Motion versions ${nextValue.version} with 8.3.4 may not work as expected.`);
26
26
  }
27
27
  }
28
28
  else if (isMotionValue(prevValue)) {
@@ -25,7 +25,7 @@ class MotionValue {
25
25
  * This will be replaced by the build step with the latest version number.
26
26
  * When MotionValues are provided to motion components, warn if versions are mixed.
27
27
  */
28
- this.version = "8.3.3";
28
+ this.version = "8.3.4";
29
29
  /**
30
30
  * Duration, in milliseconds, since last updating frame.
31
31
  *
@@ -6,8 +6,8 @@
6
6
  // to avoid exponents
7
7
  const sanitize = (v) => Math.round(v * 100000) / 100000;
8
8
  const floatRegex = /(-)?([\d]*\.?[\d])+/g;
9
- const colorRegex = /(#[0-9a-f]{6}|#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi;
10
- const singleColorRegex = /^(#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;
9
+ const colorRegex = /(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi;
10
+ const singleColorRegex = /^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;
11
11
  function isString(v) {
12
12
  return typeof v === "string";
13
13
  }
@@ -586,8 +586,8 @@
586
586
  // to avoid exponents
587
587
  const sanitize = (v) => Math.round(v * 100000) / 100000;
588
588
  const floatRegex = /(-)?([\d]*\.?[\d])+/g;
589
- const colorRegex = /(#[0-9a-f]{6}|#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi;
590
- const singleColorRegex = /^(#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;
589
+ const colorRegex = /(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi;
590
+ const singleColorRegex = /^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;
591
591
  function isString$1(v) {
592
592
  return typeof v === "string";
593
593
  }
@@ -2070,7 +2070,7 @@
2070
2070
  * This will be replaced by the build step with the latest version number.
2071
2071
  * When MotionValues are provided to motion components, warn if versions are mixed.
2072
2072
  */
2073
- this.version = "8.3.3";
2073
+ this.version = "8.3.4";
2074
2074
  /**
2075
2075
  * Duration, in milliseconds, since last updating frame.
2076
2076
  *
@@ -5941,7 +5941,7 @@
5941
5941
  * and warn against mismatches.
5942
5942
  */
5943
5943
  {
5944
- warnOnce(nextValue.version === "8.3.3", `Attempting to mix Framer Motion versions ${nextValue.version} with 8.3.3 may not work as expected.`);
5944
+ warnOnce(nextValue.version === "8.3.4", `Attempting to mix Framer Motion versions ${nextValue.version} with 8.3.4 may not work as expected.`);
5945
5945
  }
5946
5946
  }
5947
5947
  else if (isMotionValue(prevValue)) {