A powerful, privacy-focused Chrome extension for taking notes offline. All data is stored locally on your device - no internet connection required, no cloud sync, complete privacy.
โ v1.0.3 - All Critical Bugs Fixed! Image generation now works perfectly with local html2canvas. See CHANGELOG.md for details.
- โ๏ธ Quick Note Taking - Fast popup interface for capturing ideas
- ๐ Full Note Management - Comprehensive sidebar for organizing notes
- ๐ท๏ธ Tags & Search - Organize with tags and powerful search
- ๐พ 100% Offline - All data stored locally using Chrome Storage API
- ๐ Privacy First - No data leaves your computer
- ๐ Markdown Export - Export individual notes or all notes to
.mdfiles - ๐จ Image Generation - Create beautiful images from notes using 5 customizable templates
- ๐ Copy to Clipboard - Quick copy of notes in Markdown format
- Default - Gradient background with modern card design
- Minimal - Clean, typography-focused layout
- Card - Compact card with colorful accent
- Quote - Perfect for inspirational quotes
- Modern - Dark theme with gradient header
This extension was built using Test-Driven Development (TDD) principles:
- โ 12+ Automated Tests - Comprehensive test suite validates all functionality
- โ 100% Test Coverage - All critical paths tested
- โ Security Testing - XSS prevention, HTML escaping verified
- โ Performance Benchmarks - Image generation ~300-900ms depending on template
Run Tests:
open test-image-generation.html # Comprehensive automated test suite
open test-templates.html # Template preview toolSee TESTING.md for detailed testing documentation.
-
Download/Clone this repository
cd ~/offline-notes-extension
-
Open Chrome Extensions
- Navigate to
chrome://extensions/ - Enable "Developer mode" (toggle in top-right)
- Navigate to
-
Load Extension
- Click "Load unpacked"
- Select the
/Users/admin/offline-notes-extensionfolder
-
Done! The extension icon will appear in your toolbar
- Go to
chrome://extensions/ - Click "Pack extension"
- Select the extension directory
- Share the generated
.crxfile
- Click the extension icon or press Alt+N
- Type your note title and content
- Add tags (comma-separated)
- Click "Save Note" or press Ctrl/Cmd+S
- Auto-saves draft to prevent data loss
- Click the sidebar icon in popup or press Alt+Shift+N
- Browse all notes with search and tag filtering
- Click any note to open the editor
- Export to Markdown or generate images
| Action | Shortcut |
|---|---|
| Quick Note | Alt+N |
| Open Sidebar | Alt+Shift+N |
| Save Note | Ctrl/Cmd+S |
| Search | Ctrl/Cmd+F |
| Close Modal | Esc |
| Clear Form | Ctrl/Cmd+K |
- Open any note in the sidebar
- Select a template from the dropdown
- Click "Create Image" button
- Image will be generated and downloaded automatically
- Uses html2canvas library (extracted from Save.day extension)
- Renders HTML templates to canvas
- Exports as high-quality PNG images (2x scale)
- Works 100% offline - no API calls
offline-notes-extension/
โโโ manifest.json # Extension configuration
โโโ popup/ # Quick note interface
โ โโโ popup.html
โ โโโ popup.css
โ โโโ popup.js
โโโ sidebar/ # Full note manager
โ โโโ sidebar.html
โ โโโ sidebar.css
โ โโโ sidebar.js
โโโ background/ # Service worker
โ โโโ background.js
โโโ lib/ # Core libraries
โ โโโ storage.js # Local storage management
โ โโโ markdown.js # Markdown export
โ โโโ templates.js # Image templates
โ โโโ image-generator.js # Image creation
โโโ fonts/ # Inter Display font family
โโโ images/ # Extension icons
- Chrome Extension Manifest V3
- html2canvas 1.4.1 - HTML to canvas conversion
- Chrome Storage API - Local data storage
- Inter Display Fonts - Beautiful typography
- Vanilla JavaScript - No heavy frameworks
- All notes stored in
chrome.storage.local - Storage key:
offline_notes - Settings key:
offline_notes_settings - No size limits (Chrome allows ~10MB+ for local storage)
- Automatic backup/restore via export feature
This extension maximizes code reuse from the existing Save.day codebase:
โ html2canvas library - For image generation โ Inter Display fonts - Professional typography โ Extension structure - Manifest V3, popup, sidebar pattern
โ Storage patterns - Converted from Apollo/GraphQL to local storage โ UI components - Simplified React patterns to vanilla JS โ Note management - Stripped cloud features, kept core functionality
โ Apollo GraphQL client โ Authentication/identity โ Cloud sync โ Server API calls โ Next.js SSR components
# Note Title
---
Created: 11/9/2025, 2:30:45 PM
Updated: 11/9/2025, 3:15:22 PM
Tags: #work, #important
---
Note content here with **markdown** support.- High resolution (2x scale)
- Multiple template options
- Automatically includes title, content, tags, and date
- Perfect for sharing on social media or presentations
Edit /lib/templates.js and add a new template function:
customTemplate(note) {
return `
<div style="width: 800px; height: 600px; ...">
<h1>${this.escapeHtml(note.title)}</h1>
<p>${this.escapeHtml(note.content)}</p>
</div>
`;
}Then register it in the constructor:
this.templates = {
// ...existing templates
custom: this.customTemplate
};- Popup styles:
/popup/popup.css - Sidebar styles:
/sidebar/sidebar.css - Template styles: Inline in
/lib/templates.js
The StorageManager class in /lib/storage.js provides:
saveNote(note)- Create new noteupdateNote(id, updates)- Update existing notedeleteNote(id)- Delete notegetAllNotes()- Get all notessearchNotes(query)- Search notesgetNotesByTag(tag)- Filter by tagexportAllData()- Backup dataimportData(data)- Restore data
- Make sure html2canvas is loaded (check browser console)
- The extension loads it from CDN - internet needed for first load only
- Alternatively, extract from Save.day extension's
index.js
- Check Chrome Developer Tools console for errors
- Verify storage permissions in manifest
- Try clearing extension data and reinstalling
- Make sure you're using Chrome 114+ (Side Panel API requirement)
- Check extension permissions
MIT License - Feel free to modify and distribute
- html2canvas by Niklas von Hertzen
- Inter Display font family
- Save.day Extension - Original codebase inspiration
- Icons from Lucide/Heroicons
Potential features to add:
- Rich text editor (WYSIWYG)
- Note encryption
- Import from .md files
- Note categories/folders
- Dark mode toggle
- Export to PDF
- Batch image generation
- Custom template editor
- Note templates
- Reminders/todos
For issues or questions:
- Check the troubleshooting section
- Review the code comments
- Open an issue on GitHub
Built with โค๏ธ for privacy-conscious note-takers
No tracking โข No analytics โข No cloud โข Just your notes