Skip to content

HamDQan1/cheatsheet_project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

4 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Tech Cheatsheet

A modern, feature-rich Django web application for creating and managing technical cheatsheets with an intuitive VS Code-inspired interface.

Django Python License

✨ Features

🎯 Core Functionality

  • Topic Management: Create and organize cheatsheets by topics
  • Flashcard System: Each entry has a summary (front) and detailed content (back) with 3D flip animation
  • Markdown Support: Write notes with full Markdown syntax including:
    • Code syntax highlighting (via Highlight.js)
    • Mathematical equations (via KaTeX)
    • Diagrams (via Mermaid)
  • User Authentication: Secure registration and login system
  • Personal Workspace: Each user has their own private cheatsheets

🎨 User Interface

  • VS Code-Style Layout:
    • Activity Bar (48px vertical icon bar)
    • Collapsible Sidebar with topic navigation
    • Main content area
  • Dark/Light Mode: Theme toggle with localStorage persistence
  • Responsive Design: Works seamlessly on desktop, tablet, and mobile
  • Keyboard Shortcuts:
    • Ctrl+B - Toggle sidebar
  • Immersive CSS: Extensively commented styles for learning

πŸ”§ Technical Features

  • Clean, modular template architecture
  • Context processors for global data
  • CSS variables for theming
  • Vanilla JavaScript (no heavy frameworks)
  • Static file management
  • SQLite database

πŸ“Έ Screenshots

Login Page

Login

Topic List

Topic List

Entries List (Flashcards)

Entries List

Add Entry

Add Entry

πŸš€ Getting Started

Prerequisites

  • Python 3.8 or higher
  • pip (Python package manager)
  • Git

Installation

  1. Clone the repository

    git clone https://github.com/HamDQan1/cheatsheet_project.git
    cd cheatsheet_project
  2. Create a virtual environment

    python -m venv venv
    
    # On Windows
    venv\Scripts\activate
    
    # On macOS/Linux
    source venv/bin/activate
  3. Install dependencies

    pip install -r requirements.txt
  4. Run migrations

    python manage.py makemigrations
    python manage.py migrate
  5. Create a superuser (optional)

    python manage.py createsuperuser
  6. Run the development server

    python manage.py runserver
  7. Open your browser Navigate to http://127.0.0.1:8000/

πŸ“ Project Structure

cheatsheet_project/
β”œβ”€β”€ config/                    # Project configuration
β”‚   β”œβ”€β”€ settings.py           # Django settings
β”‚   β”œβ”€β”€ urls.py               # URL configuration
β”‚   └── context_processors.py # Custom context processors
β”œβ”€β”€ sheets/                    # Main app
β”‚   β”œβ”€β”€ models.py             # Topic and Entry models
β”‚   β”œβ”€β”€ views.py              # View logic
β”‚   β”œβ”€β”€ forms.py              # Entry and Topic forms
β”‚   β”œβ”€β”€ urls.py               # App URLs
β”‚   β”œβ”€β”€ static/
β”‚   β”‚   └── sheets/
β”‚   β”‚       └── styles.css    # Comprehensive stylesheet
β”‚   β”œβ”€β”€ templates/
β”‚   β”‚   └── sheets/
β”‚   β”‚       β”œβ”€β”€ base.html     # Base template
β”‚   β”‚       β”œβ”€β”€ sidebar.html  # Modular sidebar
β”‚   β”‚       β”œβ”€β”€ topic_list.html
β”‚   β”‚       β”œβ”€β”€ topic_detail.html
β”‚   β”‚       └── ...           # Other templates
β”‚   └── templatetags/
β”‚       └── markdown_extras.py # Custom Markdown filter
β”œβ”€β”€ users/                     # Authentication app
β”‚   β”œβ”€β”€ views.py
β”‚   β”œβ”€β”€ urls.py
β”‚   └── templates/
β”‚       └── registration/
β”œβ”€β”€ manage.py
β”œβ”€β”€ requirements.txt
└── README.md

πŸŽ“ Usage

Creating a Topic

  1. Click "New Topic" in the sidebar
  2. Enter a title for your topic
  3. Click "Add Topic"

Adding Entries (Flashcards)

  1. Navigate to a topic
  2. Click "Add New Entry"
  3. Fill in:
    • Title: Entry name
    • Summary: Quick notes (shown on front of card)
    • Content: Detailed information (shown on back)
  4. Use Markdown for formatting

Markdown Examples

Code blocks: ```python def hello_world(): print("Hello, World!") ```

Math equations:

$E = mc^2$
$$\int_{0}^{\infty} e^{-x^2} dx = \frac{\sqrt{\pi}}{2}$$

Mermaid diagrams: ```mermaid graph TD; A-->B; A-->C; B-->D; ```

🎨 Customization

Changing Theme Colors

Edit CSS variables in sheets/static/sheets/styles.css:

:root {
    --primary: #4a9eff;
    --bg: #0b1220;
    /* ... more variables */
}

Adding Activity Bar Icons

Edit sheets/templates/sheets/base.html:

<button class="activity-bar-item" id="your-feature" aria-label="Feature">
    <span class="activity-icon">πŸ”</span>
</button>

πŸ› οΈ Technologies Used

  • Backend: Django 4.2.25
  • Frontend: HTML5, CSS3, Vanilla JavaScript
  • Database: SQLite (development)
  • Markdown Processing: Python Markdown, Bleach
  • Syntax Highlighting: Highlight.js
  • Math Rendering: KaTeX
  • Diagrams: Mermaid.js

πŸ“ License

This project is licensed under the MIT License - see the LICENSE file for details.

🀝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the project
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

πŸ‘€ Author

Huthayfa Abdulrauf Mohammad Derham

πŸ™ Acknowledgments

  • Inspired by VS Code's interface design
  • Built as a learning project for Django and modern web development

πŸ“§ Contact

For questions or feedback, please open an issue on GitHub.


Happy Learning! πŸ“š

About

A modern Django cheatsheet app with VS Code-style interface

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published