MCPcopy Index your code
hub / github.com/IrfanulM/BananaSlice

github.com/IrfanulM/BananaSlice @v0.2.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v0.2.0 ↗ · + Follow
295 symbols 537 edges 69 files 25 documented · 8% updated 36d agov0.2.0 · 2026-06-02★ 52
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

BananaSlice Logo

BananaSlice

Open-Source alternative to Adobe Photoshop's Generative Fill using Nano Banana & Nano Banana Pro

Version: 0.2.0 License: MIT

Demo

Features

  • AI-Powered Generative Fill: Fill selections using Google Gemini's Nano Banana and Nano Banana Pro models
  • Layer-Based Editing: Non-destructive workflow with layer visibility, opacity, and reordering
  • Multiple Selection Tools: Rectangle, lasso, and smart selections
  • Project Files: Save and load projects with full layer history (.banslice format)
  • Reference Images: Guide AI generation with optional reference images
  • Secure API Storage: API keys encrypted via OS native keychain
  • Cross-Platform: Available for Windows, macOS, and Linux

Getting Started

Download

Grab the latest release for your platform from the Releases page.

Build from Source

If you'd prefer to build the app yourself:

Prerequisites: - Node.js (v18+) - Rust (for Tauri builds)

Steps: 1. Clone the repository: bash git clone https://github.com/IrfanulM/BananaSlice.git 2. Install dependencies: bash npm install 3. Run in development mode: bash npm run tauri dev

Tech Stack

  • Frontend: React 19 + TypeScript
  • Canvas Engine: Fabric.js 6
  • State Management: Zustand
  • Desktop Wrapper: Tauri 2 (Rust)
  • Styling: CSS (Modern CSS3)
  • Testing: Vitest + JSDOM

License

MIT © Irfanul Majumder

See LICENSE for details.

Acknowledgments

  • Inspired by Adobe Photoshop's Generative Fill
  • Powered by Google Gemini's Image Generation API (Nano Banana & Nano Banana)

If this project helped you, consider giving it a ⭐️!

Extension points exported contracts — how you extend this code

AppInfo (Interface)
(no doc)
src/App.tsx
SelectionData (Interface)
(no doc)
src/types/index.ts
ProgressIndicatorProps (Interface)
(no doc)
src/components/ProgressIndicator.tsx
SelectionPoint (Interface)
(no doc)
src/utils/selectionStyle.ts
CanvasStoreState (Interface)
(no doc)
src/store/canvasStore.ts
GenerateRequest (Interface)
(no doc)
src/api/generate.ts
AspectRatioDialogState (Interface)
(no doc)
src/hooks/useGeneration.ts
ImageData (Interface)
(no doc)
src/types/index.ts

Core symbols most depended-on inside this repo

isBaseLayer
called by 14
src/components/LayerPanel.tsx
sample
called by 9
src/utils/contourTracer.ts
loadImage
called by 8
src/utils/imageUtils.ts
closeContextMenu
called by 5
src/components/LayerPanel.tsx
transformToImageSpace
called by 5
src/utils/selectionProcessor.ts
douglasPeucker
called by 4
src/utils/contourTracer.ts
exportImage
called by 4
src/utils/exportManager.ts
loadProjectFromPath
called by 4
src/utils/projectManager.ts

Shape

Function 194
Interface 65
Class 25
Method 8
Enum 3

Languages

TypeScript82%
Rust18%

Modules by API surface

src-tauri/src/api.rs19 symbols
src/components/LayerPanel.tsx17 symbols
src/utils/selectionProcessor.ts16 symbols
src/api/generate.ts13 symbols
src/utils/contourTracer.ts12 symbols
src-tauri/src/commands/composite.rs11 symbols
src/hooks/useFileOperations.ts9 symbols
src/components/ReferenceImages.tsx9 symbols
src/types/index.ts8 symbols
src/store/projectsStore.ts8 symbols
src/components/ErrorBoundary.tsx8 symbols
src-tauri/src/commands/generate.rs8 symbols

For agents

$ claude mcp add BananaSlice \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page