fix: harden classroom persistence and editor flows#124
Open
cropsgg wants to merge 1 commit intoTHU-MAIC:mainfrom
Open
fix: harden classroom persistence and editor flows#124cropsgg wants to merge 1 commit intoTHU-MAIC:mainfrom
cropsgg wants to merge 1 commit intoTHU-MAIC:mainfrom
Conversation
Validate classroom storage inputs, persist resume generation data, sanitize rich HTML rendering, tighten interactive iframe isolation, and complete the editor creation and clipboard flows so the classroom experience is safer and more reliable.
wyuc
requested changes
Mar 22, 2026
Contributor
wyuc
left a comment
There was a problem hiding this comment.
Thanks for the contribution! The scope here is quite broad for a single PR (19 files across security hardening, IndexedDB persistence, and editor flows). This makes it hard to review confidently and increases merge conflict risk.
Could you split this into 2-3 focused PRs? For example:
- Security hardening: classroom ID validation, iframe sandbox, HTML sanitization, buildRequestOrigin
- Generation params persistence: sessionStorage to IndexedDB migration, stale job handling
- Editor flows: clipboard, link dialog, drag-drop, canvas operations
A few other things:
- CI hasn't run on this branch yet. Once you push a smaller PR, we can approve the workflow run and verify lint + typecheck pass.
- The project uses
pnpm, so please verify withpnpm check && pnpm lint && npx tsc --noEmitrather thanbunx.
Happy to review each focused PR once they're up.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test plan
bunx tsc --noEmitand verified the touched files do not introduce new TypeScript errorsNotes
The full repository
bunx tsc --noEmitrun still reports pre-existing dependency/type issues in unrelated files. This PR does not add new TypeScript failures in the files it changes.Made with Cursor