We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 8e0069d + 60617a9 commit 5043f18Copy full SHA for 5043f18
app/utils/threshold.js
@@ -17,14 +17,14 @@ export function parseThreshold(scrollThreshold) {
17
}
18
19
if (typeof scrollThreshold === "string") {
20
- if (scrollThreshold.match(/^(\d*(.\d+)?)px$/)) {
+ if (scrollThreshold.match(/^(\d*(\.\d+)?)px$/)) {
21
return {
22
unit: ThresholdUnits.Pixel,
23
value: parseFloat(scrollThreshold),
24
};
25
26
27
- if (scrollThreshold.match(/^(\d*(.\d+)?)%$/)) {
+ if (scrollThreshold.match(/^(\d*(\.\d+)?)%$/)) {
28
29
unit: ThresholdUnits.Percent,
30
0 commit comments