Replace all @Controller('acadenice/...') decorators with 'v1/...' on 16 NestJS controllers. Update all client services, hooks, tests, extension-clipper, and doc comments to match. DB table names (acadenice_*) and folder structure untouched.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
||
|---|---|---|
| .. | ||
| src | ||
| tests | ||
| .gitignore | ||
| manifest.json | ||
| package.json | ||
| README.md | ||
| tsconfig.json | ||
| vite.config.ts | ||
DocAdenice Web Clipper Extension
Browser extension (Chrome + Firefox, Manifest V3) that clips web pages into DocAdenice.
Prerequisites
- Node.js 20+
- pnpm 10.4.0 (
npx --yes pnpm@10.4.0) - A running DocAdenice instance
Install & dev build
# From repo root
npx --yes pnpm@10.4.0 install
# Start extension dev mode (hot-reload via @crxjs/vite-plugin)
npx --yes pnpm@10.4.0 --filter @docadenice/extension-clipper dev
The dist/ folder is auto-created and refreshed.
Load in Chrome (dev)
- Open
chrome://extensions - Enable "Developer mode" (top right)
- Click "Load unpacked" -> select
apps/extension-clipper/dist/
Load in Firefox (dev)
- Open
about:debugging#/runtime/this-firefox - Click "Load Temporary Add-on"
- Select
apps/extension-clipper/dist/manifest.json
Production zip for Chrome Web Store
npx --yes pnpm@10.4.0 --filter @docadenice/extension-clipper build
cd apps/extension-clipper/dist
zip -r ../docadenice-clipper.zip .
Submit docadenice-clipper.zip in the Chrome Web Store dashboard.
Generate a clipper token
- Log into your DocAdenice workspace.
- Go to Settings > Clipper tokens.
- Click Generate token, set a label and expiry.
- Copy the token — it is shown only once.
- Open the extension popup -> Settings tab.
- Fill in:
- DocAdenice URL: e.g.
https://your-docadenice.example.com - Clipper token: paste the token from step 4
- Default workspace ID: UUID of your workspace
- Default space ID: UUID of the target space
- DocAdenice URL: e.g.
- Click Save.
Usage
- Click the extension icon on any page -> fill in title + optional parent page -> Clip page.
- Right-click on a page or selection -> Clip to DocAdenice.
Tests
npx --yes pnpm@10.4.0 --filter @docadenice/extension-clipper test
Security design
- HTML selections are sanitized by DOMPurify in the content script before leaving the page.
- The server applies a second sanitization pass via the Tiptap pipeline.
- Tokens are stored as bcrypt hashes in the database; the plaintext is returned only at creation time and is not persisted or written to application logs by the ClipperTokenService.