Add web-based code editor for tutorials - #47
Conversation
Implements a new 'Editor' tab type using Monaco Editor, integrated via a FileController API. - Added FileController.java for file read/write operations (restricted to user.dir). - Installed @monaco-editor/react. - Added EditorPanel.tsx with Monaco implementation. - Updated TabbedPane.tsx to support 'editor' tabs (programmatically triggered). - Updated MarkdownRenderer.tsx to support ':::editor filename' directive. Co-authored-by: mtthwcmpbll <226487+mtthwcmpbll@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
|
Please merge with the latest from the main branch and then take a look at AGENTS.md to see if there's anything we're missing for this feature. Focus on documentation, tests, and modularity. |
Merged with main. Reviewed AGENTS.md and added documentation for the new Code Editor feature in |
- Merge main branch to include AGENTS.md. - Implement FileController for secure file access. - Implement EditorPanel with Monaco Editor. - Update TabbedPane and MarkdownRenderer for integration. - Add documentation for the editor feature in the introduction lesson. - Ensure tests pass. Co-authored-by: mtthwcmpbll <226487+mtthwcmpbll@users.noreply.github.com>
This PR integrates a web-based code editor into the application, allowing users to edit files directly within the tutorial environment.
Key Changes:
Backend:
FileController(/api/files/content) to handle file read and write operations.user.dir) with path traversal protection.Frontend:
@monaco-editor/reactto embed a VS Code-like editor.EditorPanelcomponent that fetches file content on mount and saves changes via the API.TabbedPaneto handleeditortype tabs and listen foreditor:openevents.Markdown Integration:
MarkdownRendererto support the:::editor filenamedirective.Verification:
npm run test) to ensure no regressions in existing components.mvn test) run but fail on Java version mismatch (expected in this environment).PR created automatically by Jules for task 5226828525929215088 started by @mtthwcmpbll