Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: option for disabling the "New code pasted" warning #5941

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

gap-editor
Copy link

 I have modified the libs/remix-ui/editor/src/lib/remix-ui-editor.tsx file.

I've added:

  1. A state variable showPasteWarning that checks localStorage when the component mounts to see if the user has previously chosen to hide the warning.

  2. A checkbox labeled "Do not show this warning again" within the "New code pasted" modal.

  3. Logic within the modal's close functions (okFn and cancelFn) to save the preference to localStorage if the checkbox is checked when the modal is dismissed.

Now, when you paste more than 10 lines of code, the warning modal will appear with the new checkbox. If you check it and close the modal (either via "Close" or "Ask RemixAI"), the warning should not appear again in future sessions.

Copy link

netlify bot commented Apr 8, 2025

👷 Deploy request for remixproject pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 7408fca

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant