metamigo: Use react 17, next 12. Disable react-mic

* We have to stay on react 17 (and therefore next 12) because we require
@mui/styles which does not support react 18
* Furthermore react-mic does not support a version of react after 16
  So I disabled the mic feature for now since it is not in use.
  In the future we will probably have to fork or implement our own mic
  library.
This commit is contained in:
Abel Luck 2023-03-10 10:19:08 +00:00
parent fe2e53ea6f
commit ad893637e6
3 changed files with 10 additions and 10 deletions

View file

@ -8,11 +8,11 @@ import { makeStyles, useTheme } from "@material-ui/core/styles";
import AudioPlayer from "material-ui-audio-player";
import { useStopwatch } from "react-timer-hook";
import style from "./MicInput.module.css";
import type { ReactMicProps } from "react-mic";
//import type { ReactMicProps } from "react-mic";
const ReactMic = dynamic<ReactMicProps>(
// eslint-disable-next-line promise/prefer-await-to-then
() => import("react-mic").then((mod) => mod.ReactMic),
() => { throw new Error("MIC INPUT FEATURE IS DISABLED"); /*return import("react-mic").then((mod) => mod.ReactMic);*/ } ,
{ ssr: false }
);