mirror of
https://github.com/vrc-get/vrc-get.git
synced 2026-06-21 09:58:08 +00:00
fix: add polyfill for ResizeObserver
This commit is contained in:
parent
9d2b851930
commit
033e1c5dbe
2 changed files with 11 additions and 1 deletions
|
|
@ -1,6 +1,6 @@
|
|||
"use client";
|
||||
|
||||
import "resize-observer-polyfill";
|
||||
import "@/lib/polyfill";
|
||||
import { CheckForUpdateMessage } from "@/components/CheckForUpdateMessage";
|
||||
import { TooltipProvider } from "@/components/ui/tooltip";
|
||||
import type { CheckForUpdateResponse, LogEntry } from "@/lib/bindings";
|
||||
|
|
|
|||
10
vrc-get-gui/lib/polyfill.ts
Normal file
10
vrc-get-gui/lib/polyfill.ts
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
import ResizeObserver from "resize-observer-polyfill";
|
||||
|
||||
if (typeof window !== "undefined") {
|
||||
if (typeof window.ResizeObserver === "undefined") {
|
||||
//window.ResizeObserver = (await import("resize-observer-polyfill")).default;
|
||||
window.ResizeObserver = ResizeObserver;
|
||||
}
|
||||
}
|
||||
|
||||
export default {};
|
||||
Loading…
Add table
Add a link
Reference in a new issue