Commit Graph
245 Commits
Author SHA1 Message Date
SnapOtter aa773addb4 merge: resolve conflict with main branch in tool-registry.tsx 2026-05-08 18:55:28 +08:00
SnapOtter e118717337 merge: resolve conflict with main branch in README.md 2026-05-08 17:32:16 +08:00
SnapOtter d32c7a279e test(beautify): fix E2E test selectors for processing flow 2026-05-08 17:12:16 +08:00
SnapOtter e9151c5532 fix: update convert unsupported format test (BMP is now supported) 2026-05-08 16:56:35 +08:00
SnapOtter 3d9324b82a chore: update tool count to 50 across all references 2026-05-08 16:33:12 +08:00
SnapOtter 53b717243b fix(meme-generator): add opentype.js types, fix no-dropzone registry test 2026-05-08 16:29:44 +08:00
SnapOtter 0deea29c37 test(beautify): add Playwright E2E tests 2026-05-08 16:28:12 +08:00
SnapOtter 136a4a0752 Merge branch 'feat/format-support-expansion'
# Conflicts:
#	README.md
#	apps/web/src/components/layout/app-layout.tsx
2026-05-08 16:21:11 +08:00
SnapOtter 7650844c8f test(beautify): add comprehensive integration tests 2026-05-08 16:20:44 +08:00
SnapOtter 6ec3a51fa4 feat(meme-generator): add meme generation API route with template and custom image modes
Custom route handler supporting template mode (JSON body with templateId)
and custom image mode (multipart upload). Registers process function for
pipeline compatibility. Includes 18 integration tests.
2026-05-08 16:13:34 +08:00
SnapOtter 69e107fbab feat(beautify): add device frame assets and PNG frame compositing 2026-05-08 16:12:46 +08:00
SnapOtter d8c1fdf5c2 feat(beautify): add SVG frame generators (macOS, Windows, browser) 2026-05-08 16:09:31 +08:00
SnapOtter 39358524cd feat(beautify): add shadow rendering (extracted from border.ts pattern) 2026-05-08 16:06:37 +08:00
SnapOtter b13df56273 feat(beautify): add background generation (solid, gradient, image, transparent) 2026-05-08 16:04:34 +08:00
SnapOtter 3d103d5092 test(meme-generator): add template manifest validation tests 2026-05-08 16:03:21 +08:00
SnapOtter 9dff59c400 feat(meme-generator): add text renderer with opentype.js SVG path generation 2026-05-08 16:01:46 +08:00
SnapOtter cb8684d796 test: remove JP2 and DDS from E2E exotic upload tests (Chromium rejects these extensions) 2026-05-08 15:40:23 +08:00
SnapOtter 98b2e5a269 test: add Playwright e2e spec for color-blindness tool 2026-05-08 15:21:39 +08:00
SnapOtter eedc2443d6 feat: add color-blindness API route and integration tests 2026-05-08 15:18:38 +08:00
SnapOtter 5deb25c9e3 test: expand format decoder and detection unit tests for all new formats 2026-05-08 15:18:04 +08:00
SnapOtter 9720e6409e test: expand new-formats integration tests with output matrix, resize, and preview tests 2026-05-08 15:17:18 +08:00
SnapOtter 93a246ce23 test: add QOI codec unit tests and E2E GUI format support tests
- QOI codec: 16 tests covering encode/decode round-trips, error handling, fixture validation
- E2E: 28 tests for format upload/resize, convert new outputs, dropdown verification,
  HEIC-to-JPG flow, and exotic format upload acceptance
2026-05-08 15:16:06 +08:00
SnapOtter 44608733c6 feat: add PPM/PGM/PBM CLI decoder fallback, QOI fixture and format-matrix entry
- Add ppm/pgm/pbm to CLI_DECODED_FORMATS with Sharp-first, ImageMagick fallback
- Create sample.qoi test fixture (10x10 solid color)
- Add QOI to format-matrix test FORMAT_SAMPLES
- Mark PPM/PGM/PBM as needsCliDecoder in tests (Sharp doesn't support them natively)
2026-05-08 15:12:23 +08:00
SnapOtter 0b6a970912 feat: add color blindness simulation image-engine operation
Add colorBlindness() operation with 8 simulation matrices (Vienot/Machado)
for protanopia, deuteranopia, tritanopia, protanomaly, deuteranomaly,
tritanomaly, achromatopsia, and blue cone monochromacy.
2026-05-08 15:11:36 +08:00
SnapOtter e9fb35b7cd test: add integration tests for new input and output formats 2026-05-08 00:24:45 +08:00
SnapOtter bd6f80ff3e test: add format fixtures for SVGZ, JP2, EPS, PPM, PGM, PBM, DDS, CUR, DPX, FITS, APNG 2026-05-08 00:22:22 +08:00
SnapOtter e99bae428a fix: resolve 50+ bugs across editor store, canvas, panels, and tools
- Store: loadImage resets state, applyCrop updates sourceImageSize,
  setTool clears stale cropState, layer ordering preserved across
  layers, rotateCanvas/flipCanvas account for object dimensions,
  trimCanvas implemented, resizeCanvas supports anchor positioning
- Canvas: crop overlay interactive, move tool drag events wired,
  hand tool panning, stage ref effect mount-only, checkerboard
  tracks pan offset, filter cache clearing
- Panels: hslToHex color fix for hue 240-360, adjustments single
  setAdjustment call, curves draggingIndex after sort, history
  panel fresh temporal reads, export transparent setting, canvas
  resize dialog re-sync, hex input respects picker target
- Tools: text tool fixed positioning and event cleanup, shape tool
  deferred addObject, selection mode wired to store, magic wand
  tolerance controlled, eyedropper coordinate transform
- Options: dodge-burn/shape/clone/fill/gradient/pixel-brush use
  proper store actions instead of raw setState
- Added 20+ store actions for tool settings
- Updated tests for corrected rotation/flip/trim behavior
- Excluded e2e-editor from vitest config
2026-05-07 23:47:08 +08:00
SnapOtter 1669e34909 Merge fix/129-face-enhancement-mediapipe: add mediapipe to upscale-enhance bundle
fix: add mediapipe to upscale-enhance bundle for face enhancement

The enhance-faces tool requires MediaPipe for face detection, but the
upscale-enhance feature bundle did not include mediapipe in its pip
packages. Added mediapipe to both amd64 and arm64 package lists.

Added 25 regression tests validating bundle dependency completeness.

Closes #129
2026-05-07 22:24:03 +08:00
SnapOtter 6fc767523c fix: add mediapipe to upscale-enhance bundle for face enhancement
The enhance-faces tool requires MediaPipe for face detection, but the
upscale-enhance feature bundle did not include mediapipe in its pip
packages. Users who installed only the upscale-enhance bundle got
"Face detection requires MediaPipe" errors. Added mediapipe to both
amd64 and arm64 package lists, matching the pattern used by the
face-detection and photo-restoration bundles.

Also added feature-manifest.test.ts with 25 tests validating bundle
dependency completeness to prevent similar missing-dependency bugs.

Closes #129
2026-05-07 22:21:45 +08:00
SnapOtter 14810c3c78 fix: prevent repeated redirect when switching from grid to sidebar view
The default-view redirect in HomePage fired on every mount, not just the
initial page load. A module-level flag now gates the redirect so it only
applies once per session, allowing users to switch to sidebar view when
grid is the default.

Closes #128
2026-05-07 22:16:26 +08:00
SnapOtter 16af9c573a feat: remove app name and logo customization feature
Users can no longer customize the app name or logo. The branding API
endpoints, permission, frontend UI, env vars (APP_NAME, MAX_LOGO_SIZE_KB),
and all related tests are removed. Includes a migration to clean up
branding data from existing databases.
2026-05-07 19:41:30 +08:00
SnapOtter 79897fcdb0 test: fix brush test assertion for hardness visibility 2026-05-07 19:22:50 +08:00
SnapOtter 8208acfb78 fix: restore missing text options and font loader, wire text tool options bar, fix e2e test selectors 2026-05-07 19:13:36 +08:00
SnapOtter 25a1dd7aba Merge fix/131-content-aware-resize-registry: add frontend registry for content-aware resize
fix: add frontend registry entry for content-aware resize tool

Closes #131
2026-05-07 09:44:14 +08:00
SnapOtter cc15821c5e fix: add frontend registry entry for content-aware resize tool
The content-aware-resize tool had a full backend implementation (API route,
caire binary, seam-carving bridge) but was missing from the frontend
toolRegistry Map. Navigating to /content-aware-resize showed "Tool not found"
because ToolPage could not resolve a registry entry for the tool ID.

Added a dedicated ContentAwareResizeSettings component and registered it in
the tool registry with side-by-side display mode. Also added a guard test
that verifies every tool in the shared TOOLS[] array has a matching registry
entry, preventing this class of bug from recurring.

Closes #131
2026-05-07 09:38:38 +08:00
SnapOtter e11e3660d9 test: add editor E2E test specs 2026-05-07 09:29:01 +08:00
SnapOtter 4a96d4b217 test: add editor store and types unit tests (161 tests) 2026-05-07 09:27:47 +08:00
SnapOtter 979a833978 fix: resolve analytics data gaps and resize validation failures
- Fix resize 20% failure rate: add Zod refine requiring at least one
  dimension, enforce integer/max constraints, clamp percentage scaling
  to minimum 1px, and guard against missing metadata in withoutEnlargement
- Fix PostHog init race condition: move consent check before async import
  so frontend events (search, pageview) are no longer silently dropped
- Fix identify() passing nested $set/$set_once wrappers instead of flat
  properties, so version person property now appears on PostHog profiles
- Add error_code and error_message to failed tool_used analytics events
  for debugging tool failures from PostHog
2026-05-06 23:21:45 +08:00
SnapOtter d705c863e3 Merge feat/transparency-fixer: add PNG Transparency Fixer tool
New AI-powered tool that fixes fake transparent PNGs in one click.
Uses BiRefNet HR-matting (2048x2048) with Sharp defringe post-processing.
2026-05-06 21:57:46 +08:00
SnapOtter 8f9ba701be fix: QR code logo causes preview to vanish and become unrecoverable
The QR code generator's logo feature was broken in production (Docker)
due to three interacting issues:

1. The CSP connect-src directive did not include data:, so the
   qr-code-styling library's internal XHR to convert logo data URLs to
   blobs was silently blocked. The library has no onerror handler, so the
   render promise hung forever after the container was already cleared.

2. crossOrigin: "anonymous" was unnecessarily set on imageOptions for
   data URLs, which can cause canvas taint issues.

3. The logo options used a conditional spread that omitted the image key
   when no logo was set. The library's update() deep-merges options, so
   removing the logo preserved the stale data URL and the QR stayed
   broken even after logo removal.

Closes #121
2026-05-06 21:38:12 +08:00
SnapOtter 84e62e6132 refactor: rename tool display name to "PNG Transparency Fixer" 2026-05-06 18:53:37 +08:00
SnapOtter 75e48f2738 test: add transparency-fixer to GUI AI tools and tools-all E2E tests 2026-05-06 10:39:15 +08:00
SnapOtter eb3d0828cb docs: add transparency-fixer endpoint documentation 2026-05-05 23:24:22 +08:00
SnapOtter 4745e435a4 test: add Playwright E2E tests for transparency-fixer tool 2026-05-05 23:17:24 +08:00
SnapOtter c263834037 test: add integration tests for transparency-fixer tool 2026-05-05 23:14:42 +08:00
SnapOtter 5e45cb292b test: increase QR max-size test timeout to 180s for CI
The 10000x10000 QR generation exceeds 120s on GitHub-hosted runners.
2026-05-05 22:31:53 +08:00
SnapOtter 83fa0a39dc test: add fake transparency PNG fixture for transparency-fixer tool 2026-05-05 21:50:43 +08:00
SnapOtter d46510138f fix: custom logo not showing in sidebar and silent upload failures
The desktop sidebar never rendered the custom logo because only mobile
views used the customLogo state. Added a logo section at the top of
the desktop sidebar that displays the custom logo (or the default
OtterLogo when none is set).

The upload handler used raw fetch() without checking response.ok, so
HTTP 4xx errors (e.g. file too large) were silently ignored and the UI
falsely reported success. Now checks response status and surfaces the
server error message.

Closes #125
2026-05-05 21:45:51 +08:00
SnapOtter f856c26fcb fix: upscale tool times out on CPU-only systems (NAS/low-power hardware)
The upscale function called runPythonWithProgress without a timeout parameter,
defaulting to the bridge's 10-minute hard limit. On CPU-only systems like
Synology NAS devices, Real-ESRGAN 4x upscaling easily exceeds this for modest
images. Additionally, when the timeout fired on the dispatcher path, the Python
process was left running and blocked all subsequent AI operations.

This fix adds an adaptive timeout based on input megapixels, scale factor, and
GPU availability (180s/effective-MP on CPU, 30s/effective-MP on GPU, floor of
10 minutes). It also kills the dispatcher on timeout so subsequent requests can
proceed via a fresh restart.

Closes #119
2026-05-05 21:14:56 +08:00
SnapOtter 7ff100c4f9 docs: update tagline to "Your images never leave your home" 2026-05-05 21:12:44 +08:00