mirror of
https://github.com/SteamDeckHomebrew/decky-frontend-lib.git
synced 2026-05-19 17:40:08 +02:00
fix(utils/react): shut it ts
This commit is contained in:
@@ -69,6 +69,7 @@ export function getReactRoot(o: HTMLElement | Element | Node) {
|
||||
return (
|
||||
// @ts-expect-error 7053
|
||||
o[Object.keys(o).find((k) => k.startsWith('__reactContainer$')) as string] ||
|
||||
// @ts-expect-error 7053
|
||||
o['_reactRootContainer']?._internalRoot?.current
|
||||
);
|
||||
}
|
||||
@@ -77,6 +78,7 @@ export function getReactInstance(o: HTMLElement | Element | Node) {
|
||||
return (
|
||||
// @ts-expect-error 7053
|
||||
o[Object.keys(o).find((k) => k.startsWith('__reactFiber')) as string] ||
|
||||
// @ts-expect-error 7053
|
||||
o[Object.keys(o).find((k) => k.startsWith('__reactInternalInstance')) as string]
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user