jupyter-ai
jupyter-ai copied to clipboard
Error in console caused by jupyter-ai chat component (":first-child" is potentially unsafe)
trafficstars
Description
When opening chat in JupyterLab a warning is shown:
The pseudo class ":first-child" is potentially unsafe when doing server-side rendering. Try changing it to ":first-of-type".
Using debugger I can confirm that this is an issue in jupyter-ai, caused by this inline style:
https://github.com/jupyterlab/jupyter-ai/blob/4b45ec23f3e16a0fa29718eefaf37064f59cafe6/packages/jupyter-ai/src/components/settings/existing-api-keys.tsx#L37-L42
While the warning is likely spurious, jupyter-ai (or its dependencies as is the case here) should not spam dev console as it wastes dev time.
Reproduce
- Open the dev tools
- Open the chat
- See warning in dev console
Expected behavior
No errors
Context
Tip of main corresponding to https://github.com/jupyterlab/jupyter-ai/releases/tag/v2.22.0