@react-aria/utils
Advanced tools
Comparing version 3.0.0-nightly.3114 to 3.0.0-nightly-4980928d3-240906
@@ -38,3 +38,12 @@ var $78605a5d7424e31b$exports = require("./useLayoutEffect.main.js"); | ||
}, []); | ||
if ($8c61827343eed941$var$canUseDOM) $8c61827343eed941$var$idsUpdaterMap.set(res, updateValue); | ||
if ($8c61827343eed941$var$canUseDOM) { | ||
// TS not smart enough to know that `has` means the value exists | ||
if ($8c61827343eed941$var$idsUpdaterMap.has(res) && !$8c61827343eed941$var$idsUpdaterMap.get(res).includes(updateValue)) $8c61827343eed941$var$idsUpdaterMap.set(res, [ | ||
...$8c61827343eed941$var$idsUpdaterMap.get(res), | ||
updateValue | ||
]); | ||
else $8c61827343eed941$var$idsUpdaterMap.set(res, [ | ||
updateValue | ||
]); | ||
} | ||
(0, $78605a5d7424e31b$exports.useLayoutEffect)(()=>{ | ||
@@ -61,10 +70,10 @@ let r = res; | ||
if (idA === idB) return idA; | ||
let setIdA = $8c61827343eed941$var$idsUpdaterMap.get(idA); | ||
if (setIdA) { | ||
setIdA(idB); | ||
let setIdsA = $8c61827343eed941$var$idsUpdaterMap.get(idA); | ||
if (setIdsA) { | ||
setIdsA.forEach((fn)=>fn(idB)); | ||
return idB; | ||
} | ||
let setIdB = $8c61827343eed941$var$idsUpdaterMap.get(idB); | ||
if (setIdB) { | ||
setIdB(idA); | ||
let setIdsB = $8c61827343eed941$var$idsUpdaterMap.get(idB); | ||
if (setIdsB) { | ||
setIdsB.forEach((fn)=>fn(idA)); | ||
return idA; | ||
@@ -71,0 +80,0 @@ } |
@@ -30,3 +30,12 @@ import {useLayoutEffect as $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c} from "./useLayoutEffect.module.js"; | ||
}, []); | ||
if ($bdb11010cef70236$var$canUseDOM) $bdb11010cef70236$var$idsUpdaterMap.set(res, updateValue); | ||
if ($bdb11010cef70236$var$canUseDOM) { | ||
// TS not smart enough to know that `has` means the value exists | ||
if ($bdb11010cef70236$var$idsUpdaterMap.has(res) && !$bdb11010cef70236$var$idsUpdaterMap.get(res).includes(updateValue)) $bdb11010cef70236$var$idsUpdaterMap.set(res, [ | ||
...$bdb11010cef70236$var$idsUpdaterMap.get(res), | ||
updateValue | ||
]); | ||
else $bdb11010cef70236$var$idsUpdaterMap.set(res, [ | ||
updateValue | ||
]); | ||
} | ||
(0, $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c)(()=>{ | ||
@@ -53,10 +62,10 @@ let r = res; | ||
if (idA === idB) return idA; | ||
let setIdA = $bdb11010cef70236$var$idsUpdaterMap.get(idA); | ||
if (setIdA) { | ||
setIdA(idB); | ||
let setIdsA = $bdb11010cef70236$var$idsUpdaterMap.get(idA); | ||
if (setIdsA) { | ||
setIdsA.forEach((fn)=>fn(idB)); | ||
return idB; | ||
} | ||
let setIdB = $bdb11010cef70236$var$idsUpdaterMap.get(idB); | ||
if (setIdB) { | ||
setIdB(idA); | ||
let setIdsB = $bdb11010cef70236$var$idsUpdaterMap.get(idB); | ||
if (setIdsB) { | ||
setIdsB.forEach((fn)=>fn(idA)); | ||
return idA; | ||
@@ -63,0 +72,0 @@ } |
{ | ||
"name": "@react-aria/utils", | ||
"version": "3.0.0-nightly.3114+68403fe55", | ||
"version": "3.0.0-nightly-4980928d3-240906", | ||
"description": "Spectrum UI components in React", | ||
@@ -25,5 +25,5 @@ "license": "Apache-2.0", | ||
"dependencies": { | ||
"@react-aria/ssr": "3.9.6-nightly.5042+68403fe55", | ||
"@react-stately/utils": "3.0.0-nightly.3114+68403fe55", | ||
"@react-types/shared": "3.0.0-nightly.3114+68403fe55", | ||
"@react-aria/ssr": "^3.0.0-nightly-4980928d3-240906", | ||
"@react-stately/utils": "^3.0.0-nightly-4980928d3-240906", | ||
"@react-types/shared": "^3.0.0-nightly-4980928d3-240906", | ||
"@swc/helpers": "^0.5.0", | ||
@@ -38,3 +38,3 @@ "clsx": "^2.0.0" | ||
}, | ||
"gitHead": "68403fe55489dce3de1b3094c957d598ad719861" | ||
} | ||
"stableVersion": "3.25.2" | ||
} |
@@ -25,3 +25,3 @@ /* | ||
let idsUpdaterMap: Map<string, (v: string) => void> = new Map(); | ||
let idsUpdaterMap: Map<string, Array<(v: string) => void>> = new Map(); | ||
@@ -43,3 +43,8 @@ /** | ||
if (canUseDOM) { | ||
idsUpdaterMap.set(res, updateValue); | ||
// TS not smart enough to know that `has` means the value exists | ||
if (idsUpdaterMap.has(res) && !idsUpdaterMap.get(res)!.includes(updateValue)) { | ||
idsUpdaterMap.set(res, [...idsUpdaterMap.get(res)!, updateValue]); | ||
} else { | ||
idsUpdaterMap.set(res, [updateValue]); | ||
} | ||
} | ||
@@ -76,11 +81,11 @@ | ||
let setIdA = idsUpdaterMap.get(idA); | ||
if (setIdA) { | ||
setIdA(idB); | ||
let setIdsA = idsUpdaterMap.get(idA); | ||
if (setIdsA) { | ||
setIdsA.forEach(fn => fn(idB)); | ||
return idB; | ||
} | ||
let setIdB = idsUpdaterMap.get(idB); | ||
if (setIdB) { | ||
setIdB(idA); | ||
let setIdsB = idsUpdaterMap.get(idB); | ||
if (setIdsB) { | ||
setIdsB.forEach(fn => fn(idA)); | ||
return idA; | ||
@@ -87,0 +92,0 @@ } |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
6580
0
558391
202
+ Added@react-aria/ssr@3.9.7(transitive)
+ Added@react-stately/utils@3.10.5(transitive)
+ Added@react-types/shared@3.26.0(transitive)