This enhanced test app now covers ALL editor features with interactive UI controls.
- Location: Controls Panel → Line Height section
- Range: 1.0 to 3.0 (step 0.1)
- Test: Adjust the slider to see line spacing change in real-time
- Props tested:
lineHeight
- Location: Controls Panel → Editor Height section
- Range: 200px to 800px (step 50px)
- Test: Adjust to make the editor taller or shorter
- Props tested:
height(dynamic)
- Location: Paste Events panel (appears when you paste)
- Test: Copy text and paste it into the editor
- Shows: Line number where content was pasted
- Props tested:
onDidPaste - Clear button: Remove paste event history
- Location: Controls Panel → Options → Enable Schema Doc checkbox
- Works with: N1QL and SQL++ languages only
- Test:
- Select N1QL or SqlPlusPlus language
- Enable "Enable Schema Doc" checkbox
- Start typing to see autocomplete suggestions for tables/fields
- Props tested:
schemaDoc - Sample data: travel-sample database schema with airlines, hotels, routes
- Location: Editor Preview header (top right)
- Shows: Number of times content has changed
- Test: Type in the editor and watch the counter increment
- Resets: When you change language
- Props tested:
onChange(enhanced tracking)
- Location: Editor Preview header (top right)
- Shows:
- Changes: Total edits made
- Lines: Current line count
- Chars: Total character count
- Updates: Real-time as you type
- Location: Activity Log panel (below editor)
- Tracks:
- Language changes
- Code executions
- Paste events
- Output clearing
- Features:
- Timestamp for each action
- Last 10 actions shown
- Clear button to reset log
- Output section: Clear execution results
- Paste Events: Clear paste history
- Activity Log: Clear action history
-
Language Switching
- 9 languages supported
- Sample code for each
- Props:
language
-
Theme Switching
- Dark theme (vs-dark)
- Light theme (vs-light)
- Props:
theme
-
Font Size Control
- Range: 10px to 30px
- Props:
fontSize
-
Word Wrap Toggle
- On/Off switch
- Props:
wordWrap
-
Read-Only Mode
- Checkbox to enable/disable editing
- Props:
readOnly
-
Run Button
- Toggle visibility
- Execute code action
- Props:
onRun
-
Content Changes
- Real-time updates
- Props:
onChange
-
Editor ID
- Unique identifier
- Props:
editorId(set to "demo-editor")
-
Initial Value
- Sample code loading
- Props:
value
Use this checklist to test all features:
- Switch between all 9 languages
- Toggle between dark and light themes
- Adjust font size from 10px to 30px
- Change line height from 1.0 to 3.0
- Adjust editor height from 200px to 800px
- Enable/disable read-only mode
- Toggle word wrap on and off
- Show/hide run button
- Type in the editor and watch change counter
- Copy and paste text to trigger paste event
- Check editor statistics (lines, chars)
- View activity log for all actions
- Click run button to execute code
- Clear output after execution
- Clear paste events
- Clear activity log
- Enable schema doc for N1QL
- Enable schema doc for SQL++
- Type to see autocomplete suggestions
- Test schema-aware code completion
- Verify schema doc doesn't affect other languages
- Very small font size (10px)
- Very large font size (30px)
- Minimal line height (1.0)
- Maximum line height (3.0)
- Small editor height (200px)
- Large editor height (800px)
- Read-only mode prevents editing
- Word wrap with long lines
1. Set font size to 16px
2. Move line height slider from 1.0 to 3.0
3. Observe line spacing increases
4. Try 1.0 (compact) vs 3.0 (spacious)
1. Move height slider to 200px (minimum)
2. Notice editor becomes compact
3. Move to 800px (maximum)
4. Observe editor takes more screen space
1. Copy any text (Ctrl/Cmd + C)
2. Paste into editor (Ctrl/Cmd + V)
3. Check "Paste Events" panel appears
4. Shows line number where pasted
5. Click Clear to remove events
1. Select "N1QL" language
2. Enable "Enable Schema Doc" checkbox
3. Clear editor and start typing: "SELECT * FROM "
4. Should see autocomplete for: travel-sample tables
5. Try typing field names like "name", "city"
6. Switch to JavaScript - schema doc disabled
1. Note current change count (0)
2. Type a character
3. Count increases to 1
4. Delete character
5. Count increases to 2
6. Change language - resets to 0
1. Change language - see log entry
2. Click run button - see execution log
3. Paste text - see paste log
4. Each entry has timestamp
5. Shows last 10 actions
6. Click Clear to reset
| Prop | Tested | Control Location | Status |
|---|---|---|---|
editorId |
✅ | Hard-coded | Fixed value |
language |
✅ | Language Selection | 9 languages |
value |
✅ | Sample code + editing | Dynamic |
theme |
✅ | Theme section | 2 themes |
onRun |
✅ | Show Run Button | Optional |
readOnly |
✅ | Options checkbox | Toggle |
schemaDoc |
✅ | Options checkbox | N1QL/SQL++ |
fontSize |
✅ | Font Size slider | 10-30px |
lineHeight |
✅ | Line Height slider | 1.0-3.0 |
wordWrap |
✅ | Options checkbox | on/off |
onChange |
✅ | Change counter | Real-time |
onDidPaste |
✅ | Paste Events panel | Tracked |
height |
✅ | Editor Height slider | 200-800px |
- Start Simple: Test basic features first (language, theme, font)
- Go Advanced: Then try line height, height, paste events
- Test Schema: Enable schema doc for N1QL/SQL++ to see autocomplete
- Watch Logs: Keep an eye on activity log to track all actions
- Clear Often: Use clear buttons to reset and retest
- Try Edge Cases: Test extreme values (min/max font, height, line height)
- Mobile Test: Resize browser to test responsive design
5-Minute Full Test:
1. Switch language: JavaScript → Python → N1QL
2. Change theme: Dark → Light → Dark
3. Adjust font: 10px → 20px → 30px
4. Adjust line height: 1.0 → 2.0 → 3.0
5. Adjust height: 300px → 600px
6. Enable read-only → Try to type → Disable
7. Paste some text → Check paste event
8. Toggle word wrap
9. Enable schema doc for N1QL → Type "SELECT "
10. Click run button → Check output
11. Review activity log
12. Clear all panels
- Controls Panel: All sliders and checkboxes working
- Editor: Responding to all changes in real-time
- Statistics: Live updates as you type
- Paste Events: Appearing when you paste
- Activity Log: Recording all actions with timestamps
- Output: Showing execution results
- Schema Doc: Autocomplete for N1QL/SQL++ when enabled
ALL editor features are now fully testable from the UI!
No need to modify code - everything is controllable through the interface.