mirror of
https://github.com/pewdiepie-archdaemon/odysseus.git
synced 2026-10-17 04:12:24 +02:00
feat(photo-editor): Ajax Image Editor client (Photoshop-parity tools)
Photoshop-parity editor client: layers, selection/masking, brushes,
smart filters, LUT import, Quick Edit, mobile gestures, workspaces,
batch operations, and the service-worker versioning (v978->v1006).
Source: vendor/photocraft (ad1cff44) photo-editor client files, merged
onto upstream/dev (a8c147b2). Conflict resolution documented in
pr_work/A_conflicts.md; editor files taken from vendor/photocraft
(upstream's editor is an earlier snapshot of the same feature).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
c74f475679
commit
5fac693c1c
@@ -0,0 +1,39 @@
|
||||
from pathlib import Path
|
||||
|
||||
ROOT = Path(__file__).resolve().parents[1]
|
||||
|
||||
|
||||
def read(rel):
|
||||
return (ROOT / rel).read_text(encoding="utf-8")
|
||||
|
||||
|
||||
PSD = read("static/js/editor/psd.js")
|
||||
EXPORT = read("static/js/editor/export-dialog.js")
|
||||
IMPORT = read("static/js/editor/wire-import.js")
|
||||
SW = read("static/sw.js")
|
||||
|
||||
|
||||
def test_psd_module_exports():
|
||||
assert "export function exportPsd(" in PSD
|
||||
assert "export function parsePsd(" in PSD
|
||||
assert "export function packBits(" in PSD
|
||||
assert "export function unpackBits(" in PSD
|
||||
assert "8BPS" in PSD
|
||||
assert "const psb = version === 2;" in PSD
|
||||
|
||||
|
||||
def test_export_dialog_offers_psd():
|
||||
assert "from './psd.js';" in EXPORT
|
||||
assert "exportPsd(" in EXPORT
|
||||
assert "psd:" in EXPORT
|
||||
assert 'data-format="psd"' in EXPORT
|
||||
|
||||
|
||||
def test_import_handles_psd():
|
||||
assert "from './psd.js';" in IMPORT
|
||||
assert "parsePsd(" in IMPORT
|
||||
assert ".psd" in IMPORT
|
||||
|
||||
|
||||
def test_psd_module_is_precached():
|
||||
assert "/static/js/editor/psd.js" in SW
|
||||
Reference in New Issue
Block a user