diff --git a/package.json b/package.json index b6144c5e9..8484a627a 100644 --- a/package.json +++ b/package.json @@ -65,6 +65,7 @@ "@reduxjs/toolkit": "^1.8.1", "@sentry/browser": "^7.74.1", "@sentry/react": "^7.74.1", + "@soapbox.pub/wasmboy": "^0.8.0", "@tabler/icons": "^2.0.0", "@tailwindcss/aspect-ratio": "^0.4.2", "@tailwindcss/forms": "^0.5.3", @@ -174,7 +175,6 @@ "vite-plugin-html": "^3.2.0", "vite-plugin-require": "^1.1.10", "vite-plugin-static-copy": "^0.17.0", - "wasmboy": "^0.7.1", "wicg-inert": "^3.1.1", "zod": "^3.21.4" }, diff --git a/src/components/gameboy.tsx b/src/components/gameboy.tsx index 775386080..47d8e060a 100644 --- a/src/components/gameboy.tsx +++ b/src/components/gameboy.tsx @@ -1,6 +1,6 @@ -import React, { useCallback, useEffect, useRef } from 'react'; // @ts-ignore No types available -import { WasmBoy } from 'wasmboy'; +import { WasmBoy } from '@soapbox.pub/wasmboy'; +import React, { useCallback, useEffect, useRef } from 'react'; interface IGameboy extends React.CanvasHTMLAttributes { /** URL to the ROM. */ diff --git a/yarn.lock b/yarn.lock index 79e9ac9e2..08b18ba00 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2100,6 +2100,16 @@ resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-4.6.0.tgz#3c7c9c46e678feefe7a2e5bb609d3dbd665ffb3f" integrity sha512-t09vSN3MdfsyCHoFcTRCH/iUtG7OJ0CsjzB8cjAmKc/va/kIgeDI/TxsigdncE/4be734m0cvIYwNaV4i2XqAw== +"@soapbox.pub/wasmboy@^0.8.0": + version "0.8.0" + resolved "https://registry.yarnpkg.com/@soapbox.pub/wasmboy/-/wasmboy-0.8.0.tgz#ca7e86b9c144af44530223536fdbcd29930953b1" + integrity sha512-feecE/YHmE7RdKe5IWzTCeLSaO3gF2XtHqAZWZ31YGzm0Fc8vAxuZC2Tyt0lrKRsS7rEs2L1SxT9oYAiEJcOZA== + dependencies: + audiobuffer-to-wav "git+https://github.com/torch2424/audiobuffer-to-wav.git#es-module-rollup" + idb "^2.1.3" + raf "^3.4.0" + responsive-gamepad "1.1.0" + "@surma/rollup-plugin-off-main-thread@^2.2.3": version "2.2.3" resolved "https://registry.yarnpkg.com/@surma/rollup-plugin-off-main-thread/-/rollup-plugin-off-main-thread-2.2.3.tgz#ee34985952ca21558ab0d952f00298ad2190c053" @@ -9054,16 +9064,6 @@ warning@^4.0.0, warning@^4.0.1, warning@^4.0.2: dependencies: loose-envify "^1.0.0" -wasmboy@^0.7.1: - version "0.7.1" - resolved "https://registry.yarnpkg.com/wasmboy/-/wasmboy-0.7.1.tgz#5bbf0f0f386f8e9ea322a611689b889f9c3495d2" - integrity sha512-qgA3bIFAqioYs8kYXtsanIvedgZlZQf382zs3gNlZHIItsAnRzV70/Vp6cJxbK4FyaiG58ah8/g7OW3orrs9Lg== - dependencies: - audiobuffer-to-wav "git+https://github.com/torch2424/audiobuffer-to-wav.git#es-module-rollup" - idb "^2.1.3" - raf "^3.4.0" - responsive-gamepad "1.1.0" - watchpack@^2.4.0: version "2.4.0" resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-2.4.0.tgz#fa33032374962c78113f93c7f2fb4c54c9862a5d"