If you are using a zero-config tool with automatic detection of which runtime (classic vs. automatic) should be used and you are already using a React version that has the new JSX runtimes (hence runtime: 'automatic' being configured automatically for you) such as Create React App 4 then /* @jsx jsx / pragma might not work and you should use /* @jsxImportSource @emotion/react / instead.
from the emotion documenation.
https://emotion.sh/docs/css-prop#jsx-pragma
in order to use the new runtime, needed to update react/react-dom past 16.14. so just updated to the latest version instead.
Also replaced enyzme adapter for react 17