Skip to content

Latest commit

Β 

History

History
143 lines (117 loc) Β· 6.05 KB

File metadata and controls

143 lines (117 loc) Β· 6.05 KB

🌟 Contributing to SortVision 🌟

Help us improve SortVision and make sorting algorithms more visual and intuitive!

Contributions Welcome Platform GitHub Issues Pull Requests License: MIT


πŸ› οΈ How to Contribute

1. Fork the Repository

  • Click the Fork button on the top-right corner of the repository page to create your copy.

2. Clone Your Fork

  • Clone the forked repository to your local machine:
    git clone https://github.com/<your-username>/SortVision.git
  • Replace <your-username> with your GitHub username.

3. Create a New Branch

  • Create a branch for your feature or bug fix:
    git checkout -b feature-name
  • Use a meaningful branch name (e.g., improve-ui, fix-bug-xyz).

4. Make Changes

  • Implement your changes in the codebase.
  • Ensure your code follows best practices and is well-documented.
  • Run tests and verify everything is working.

5. Commit Your Changes

  • Stage and commit your changes:
    git add .
    git commit -m "Describe your changes (e.g., Improved animation speed)"

6. Push to Your Branch

  • Push the changes to your forked repository:
    git push origin feature-name

7. Submit a Pull Request

  • Go to the original repository and click New Pull Request.
  • Select your branch, provide a detailed description of your changes, and submit the pull request.

πŸ“‚ Project Structure

Below is an overview of the SortVision project structure:

SortVision
β”œβ”€ .gitignore               # Specifies files Git should ignore (node_modules, build files, etc.)
β”œβ”€ components.json          # Configuration for UI components (ShadCN UI setup)
β”œβ”€ eslint.config.js         # ESLint configuration for enforcing coding standards
β”œβ”€ index.html              # Entry HTML file that loads the React application
β”œβ”€ jsconfig.json           # JavaScript configuration for path aliases and compiler options
β”œβ”€ package-lock.json       # Lock file for ensuring consistent dependency versions
β”œβ”€ package.json            # Contains project metadata, dependencies, and scripts
β”œβ”€ pnpm-lock.yaml         # Lock file for pnpm package manager
β”œβ”€ public/                # Static assets
β”‚  β”œβ”€ favicon.svg        # Website favicon icon
β”‚  β”œβ”€ manifest.json      # PWA manifest for app installation settings
β”‚  β”œβ”€ mobile-fix.js      # JavaScript fixes for mobile-specific issues
β”‚  β”œβ”€ mobile.css        # Mobile-specific CSS styles
β”‚  β”œβ”€ splash.svg        # Splash screen image for branding
β”‚  └─ sw.js             # Service Worker for PWA offline functionality
β”œβ”€ src/                  # Source code directory
β”‚  β”œβ”€ App.css           # Global styles for the main App component
β”‚  β”œβ”€ App.jsx           # Root React component with routing and layout
β”‚  β”œβ”€ algorithms/       # Sorting algorithm implementations
β”‚  β”‚  β”œβ”€ bubbleSort.jsx    # Bubble Sort algorithm
β”‚  β”‚  β”œβ”€ index.js          # Exports all sorting algorithms
β”‚  β”‚  β”œβ”€ insertionSort.jsx # Insertion Sort algorithm
β”‚  β”‚  β”œβ”€ mergeSort.jsx     # Merge Sort algorithm
β”‚  β”‚  β”œβ”€ quickSort.jsx     # Quick Sort algorithm
β”‚  β”‚  β”œβ”€ radixSort.jsx     # Radix Sort algorithm
β”‚  β”‚  └─ selectionSort.jsx # Selection Sort algorithm
β”‚  β”œβ”€ components/       # UI components directory
β”‚  β”‚  β”œβ”€ ArrayVisualization.jsx  # Handles sorting bar visualization
β”‚  β”‚  β”œβ”€ ConfigPanel.jsx         # User interface for selecting sorting parameters
β”‚  β”‚  β”œβ”€ MetricsPanel.jsx        # Displays performance metrics like swaps and comparisons
β”‚  β”‚  β”œβ”€ SortingVisualizer.jsx   # Main component for sorting execution
β”‚  β”‚  β”œβ”€ VisualizationPanel.jsx  # Panel for displaying facts and details
β”‚  β”‚  └─ ui/                     # Reusable UI components (buttons, cards, sliders, etc.)
β”‚  β”‚     β”œβ”€ badge.jsx      # Badge component for labels
β”‚  β”‚     β”œβ”€ button.jsx     # Styled button component
β”‚  β”‚     β”œβ”€ card.jsx       # Card component for UI grouping
β”‚  β”‚     β”œβ”€ input.jsx      # Custom input field component
β”‚  β”‚     β”œβ”€ select.jsx     # Dropdown selection component
β”‚  β”‚     β”œβ”€ slider.jsx     # Slider for adjusting speed and array size
β”‚  β”‚     └─ tabs.jsx       # Tab component for navigation
β”‚  β”œβ”€ index.css        # Global styles for the app
β”‚  β”œβ”€ lib/            # Utility functions
β”‚  β”‚  └─ utils.js     # Common helper functions
β”‚  └─ main.jsx        # Application entry point
└─ vite.config.js     # Vite bundler configuration

Why This Structure?

  • πŸš€ Organized β†’ Components, logic, and styles are neatly separated.
  • πŸ”§ Scalable β†’ Easy to add new features.
  • πŸ› οΈ Maintainable β†’ Clear structure for debugging and collaboration.

🀝 Code of Conduct

By contributing to this project, you agree to abide by our Code of Conduct. Be respectful, inclusive, and collaborative in all interactions.


πŸ’‘ Tips for Contributing

  1. Check the Issues tab for open feature requests or bug reports.
  2. Keep your commits small and focused on a single change.
  3. Avoid committing unnecessary files.
  4. Regularly sync your fork with the main repository:
    git pull upstream main

πŸ› οΈ Need Help?

If you have any questions:

  1. Open an Issue in the repository.
  2. Contact the maintainers via the repository discussion section.

Thank you for contributing to SortVision! πŸŽ‰ Let's make sorting visual, interactive, and fun! πŸš€