Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Empty file removed .context/notes.md
Empty file.
Empty file removed .context/todos.md
Empty file.
1 change: 1 addition & 0 deletions conductor.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"scripts": {
"setup": "./toolkit/Conductor/setup.sh",
"run": "./toolkit/Conductor/run.sh"
},
"runScriptMode": "nonconcurrent"
Expand Down
53 changes: 53 additions & 0 deletions docs/PRIVACY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# Privacy Policy for Clean Autofill

**Last updated:** January 31, 2026

## Overview

Clean Autofill is a Chrome extension that generates email addresses based on website domains. This policy explains how the extension handles your data.

## Data Collection

**Clean Autofill does not collect any personal data.**

The extension does not:
- Collect or transmit browsing history
- Track your activity across websites
- Use analytics or tracking services
- Send any data to external servers
- Access or store passwords or sensitive information

## Data Storage

The extension stores only one piece of information:

- **Your email domain setting** (e.g., "example.com") — This is stored locally in Chrome's sync storage so your preference persists across browser sessions and syncs across your devices if you're signed into Chrome.

This setting is configured by you in the extension's options page and is never transmitted anywhere.

## How the Extension Works

1. When you click the extension icon, it reads the current tab's URL to extract the website domain
2. It combines that domain with your configured email domain to generate an address (e.g., "amazon.com@example.com")
3. It fills this generated address into an input field on the page

All processing happens locally in your browser. No data leaves your device.

## Permissions Explained

- **activeTab**: Required to read the current tab's URL when you click the extension icon
- **storage**: Required to save your email domain setting
- **notifications**: Required to show confirmation messages when emails are filled
- **Host permissions (<all_urls>)**: Required to inject the email-filling functionality into web pages

## Third Parties

Clean Autofill does not share any data with third parties because it does not collect any data.

## Changes to This Policy

If this privacy policy changes, the updated version will be posted here with a new "Last updated" date.

## Contact

If you have questions about this privacy policy, please visit the [GitHub Issues page](https://github.com/ZAAI-com/Clean-Autofill/issues).
82 changes: 0 additions & 82 deletions docs/QUICK_RELEASE_GUIDE.md

This file was deleted.

189 changes: 162 additions & 27 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,124 @@
# Clean-Autofill Chrome Extension
# Clean Autofill Chrome Extension

A Chrome extension that automatically generates and fills email addresses based on the current website's domain.
**Stop typing email addresses. One click, done.**

Clean Autofill is a Chrome extension for users with catch-all email domains who want unique, trackable email addresses for every website—without the hassle of typing them manually.

**[Install from Chrome Web Store](https://chromewebstore.google.com/detail/clean-autofill/klbbkndjohchnidkbnjijdbggfadpppf)**

![Clean-Autofill in action](Screenshots/Clean-Autofill-Screenshot-1.png)

## Why Clean Autofill?

If you use a catch-all email domain (like `@yourdomain.com`), you know the benefits:
- **Track who sells your data** — instantly know which company leaked your email
- **Easy filtering** — create rules based on the sender address
- **Spam control** — disable a single address without affecting others

But typing `sitename@yourdomain.com` on every signup form gets old fast. **Clean Autofill does it for you in one click.**

## Features

- **Automatic Email Generation**: Creates email addresses in the format `domain@your-email-domain`
- **Smart Field Detection**: Automatically fills the currently focused text field or finds email input fields
- **Easy Configuration**: Simple settings page to configure your email domain
- **Clean UI**: Modern, user-friendly interface
- **One-Click Fill** — Click the extension icon and your email is instantly filled
- **Automatic Domain Detection** — Generates emails like `linear.app@yourdomain.com` based on the current site
- **Smart Field Detection** — Finds email fields automatically, or fills your focused field
- **Privacy-First** — No data collection, no tracking, works entirely offline
- **Cross-Device Sync** — Your settings sync across Chrome browsers via your Google account

![Settings and Preview](Screenshots/Clean-Autofill-Screenshot-2.png)

## How It Works

When you visit a website, Clean-Autofill creates an email address by combining:
- The current website's main domain (subdomains are removed, e.g., `subdomain.example.com` becomes `example.com`)
- Your configured email domain (e.g., `mg1.de`)
- Result: `example.com@mg1.de`
1. **Configure once** — Enter your catch-all email domain in settings (e.g., `manuelgruber.net`)
2. **Visit any website** — Navigate to a signup or login page
3. **Click the icon** — Clean Autofill generates and fills `sitedomain@yourdomain.com`

The extension extracts the main domain (removing subdomains like `www.` or `app.`) and combines it with your configured email domain:
- `linear.app/signup` → `linear.app@yourdomain.com`
- `account.apple.com` → `apple.com@yourdomain.com`
- `mail.google.com` → `google.com@yourdomain.com`

## Tech Stack

- **TypeScript** - Strict mode, compiles to `dist/`
- **Bun** - Test runner with happy-dom for DOM testing
- **Biome** - Linting and formatting (single tool, replaces ESLint + Prettier)
- **Husky** - Pre-commit hooks for automated checks
- **GitHub Actions** - CI/CD pipeline for automated testing
- **Chrome Extension Manifest V3**

## Build & Development Commands

```bash
# Build extension (compile TypeScript + copy assets to dist/)
bun run build

# Run tests (119 tests with DOM support)
bun test src/

# Run tests in watch mode
bun run test:watch

# Lint and format check
bun run check

# Lint and format fix
bun run check:fix

# TypeScript type check only
bun run typecheck

# Package extension for distribution
bun run pack

# Version bumping
bun run bump:patch # 0.1.0 → 0.1.1
bun run bump:minor # 0.1.0 → 0.2.0
bun run bump:major # 0.1.0 → 1.0.0
```

## Architecture

The extension follows Chrome Extension Manifest V3 architecture with three main components:

### Service Worker (`src/background.ts`)
- Handles extension icon clicks via `chrome.action.onClicked`
- Generates email addresses using domain extraction logic
- Manages Chrome storage API for user settings
- Shows notifications for success/error states
- Opens options page on first install

### Content Script (`src/content.ts`)
- Injected into all web pages
- Receives messages from service worker to fill email fields
- Smart field detection with priority order:
1. Currently focused input field
2. Email-specific input fields (type="email", email-related names/ids)
3. General text input fields
- Handles React/framework compatibility with native input events

### Options Page (`src/options.html` + `src/options.ts`)
- Settings interface for configuring user's email domain
- Uses Chrome sync storage for cross-device settings

### Shared Utilities (`src/utils.ts`)
- `extractMainDomain()` - Removes subdomains and handles special TLDs (.co.uk, .com.au, etc.)
- `isValidEmail()` - Basic email format validation
- `createTimeout()` - Promise-based timeout for async operations
- `debounce()` - Rate-limiting for input events

## Installation

### Chrome Web Store (Recommended)

Install directly from the [Chrome Web Store](https://chromewebstore.google.com/detail/clean-autofill/klbbkndjohchnidkbnjijdbggfadpppf).

### Developer Mode Installation (For Testing)

1. Open Chrome and navigate to `chrome://extensions/`
2. Enable "Developer mode" in the top right corner
3. Click "Load unpacked"
4. Select the Clean-Autofill directory
4. Select the Clean Autofill directory
5. The extension will appear in your extensions bar

### First-Time Setup
Expand All @@ -37,7 +132,7 @@ When you visit a website, Clean-Autofill creates an email address by combining:

1. **Navigate to any website**
2. **Click on a text field** where you want to enter an email (or let the extension find email fields automatically)
3. **Click the Clean-Autofill icon** in your extensions bar - the email will be filled immediately!
3. **Click the Clean Autofill icon** in your extensions bar - the email will be filled immediately!

The extension will:
- First try to fill the currently focused field
Expand All @@ -50,25 +145,45 @@ The extension will:

```
Clean-Autofill/
├── manifest.json # Extension configuration
├── package.json # NPM configuration
├── src/ # Extension source code (TypeScript)
│ ├── background.ts # Service worker for handling icon clicks
│ ├── content.ts # Content script for filling emails
│ ├── options.html # Settings page HTML
│ ├── options.ts # Settings page logic
├── manifest.json # Extension configuration (MV3)
├── package.json # NPM/Bun configuration
├── bunfig.toml # Bun test configuration (DOM support)
├── .github/
│ └── workflows/
│ └── ci.yml # GitHub Actions CI pipeline
├── src/ # TypeScript source (edit these)
│ ├── background.ts # Service worker
│ ├── background.test.ts # Service worker tests
│ ├── content.ts # Content script for email filling
│ ├── content.test.ts # Content script tests
│ ├── options.ts # Options page logic
│ ├── options.test.ts # Options page tests
│ ├── options.html # Options page UI
│ ├── utils.ts # Shared utilities
│ ├── utils.test.ts # Utility tests
│ ├── test-setup.ts # DOM test setup (happy-dom)
│ ├── types/
│ │ └── index.ts # TypeScript type definitions
│ └── icons/ # Extension icons (16, 32, 48, 128px)
├── toolkit/ # Build and utility scripts
│ └── scripts/
├── toolkit/
│ ├── biome/
│ │ └── biome.json # Biome linter/formatter config
│ ├── typescript/
│ │ └── tsconfig.json # TypeScript configuration
│ ├── husky/
│ │ └── pre-commit # Pre-commit hook (typecheck, lint, test)
│ └── scripts/ # Build scripts
│ ├── build.js # Compiles TS + copies assets to dist/
│ ├── pack.js # Creates distribution package
│ ├── validate.js # Manifest and file validation
│ ├── pack.js # Creates distribution zip
│ ├── validate.js # Manifest validation
│ └── bump-version.js # Version management
├── docs/ # Documentation
└── dist/ # Build output (gitignored)
├── Clean-Autofill/ # Unpacked extension folder
└── Clean-Autofill.zip # Chrome Web Store package
└── dist/ # Build output (load this in Chrome)
├── *.js # Compiled JavaScript
├── options.html # Copied from src/
├── manifest.json # Copied from root
├── icons/ # Copied from src/
└── Clean-Autofill.zip # Distribution package
```

## Permissions
Expand All @@ -95,6 +210,26 @@ The extension requires minimal permissions:
- Check that you're entering a valid domain format (e.g., `example.com`)
- Don't include the @ symbol in your domain

## Development Workflow

1. Edit TypeScript files in `src/`
2. Run `bun run build` to compile to `dist/`
3. Load `dist/` folder in Chrome (chrome://extensions, Developer mode)
4. Run `bun test src/` to verify changes
5. Run `bun run check` before committing

Pre-commit hooks automatically run type checking, linting, and tests.

## Testing

Tests are colocated with source files (`*.test.ts`). DOM testing is supported via happy-dom.

```bash
bun test src/ # Run all 119 tests
bun run test:watch # Watch mode
bun run test:coverage # Coverage report (98%+ line coverage)
```

## Future Improvements

- Multiple email domain profiles
Expand All @@ -105,4 +240,4 @@ The extension requires minimal permissions:

## License

This extension is provided as-is for personal use.
MIT License
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/Screenshots/Clean-Autofill-Screenshot-2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading