mirror of
https://github.com/pewdiepie-archdaemon/odysseus.git
synced 2026-10-16 11:52:25 +02:00
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>
69 lines
1.8 KiB
Python
69 lines
1.8 KiB
Python
from pathlib import Path
|
|
|
|
ROOT = Path(__file__).resolve().parents[1]
|
|
|
|
|
|
def read(rel):
|
|
return (ROOT / rel).read_text(encoding="utf-8")
|
|
|
|
|
|
def test_actions_panel_module_shape():
|
|
src = read("static/js/editor/actions-panel.js")
|
|
for token in [
|
|
"export const ACTION_COMMANDS",
|
|
"export function createActionsPanel(",
|
|
"ge-panel-actions",
|
|
"localStorage",
|
|
"'ge-actions'",
|
|
]:
|
|
assert token in src
|
|
|
|
|
|
def test_actions_panel_supports_batch():
|
|
src = read("static/js/editor/actions-panel.js")
|
|
for token in [
|
|
"ge-actions-batch-row",
|
|
"ge-actions-batch-select",
|
|
"runOnAllLayers",
|
|
"getLayers",
|
|
"selectLayer",
|
|
]:
|
|
assert token in src
|
|
|
|
|
|
def test_gallery_wires_actions_batch():
|
|
src = read("static/js/galleryEditor.js")
|
|
for token in ["getLayers: () =>", "selectLayer: (id) =>"]:
|
|
assert token in src
|
|
|
|
|
|
def test_gallery_wires_actions_panel():
|
|
src = read("static/js/galleryEditor.js")
|
|
for token in [
|
|
"from './editor/actions-panel.js'",
|
|
"createActionsPanel(",
|
|
"element: actionsPanel.element",
|
|
]:
|
|
assert token in src
|
|
|
|
|
|
def test_window_menu_exposes_actions():
|
|
src = read("static/js/editor/build/topbar.js")
|
|
assert 'data-window-action="actions"' in src
|
|
|
|
|
|
def test_wire_extra_menus_dispatches_actions():
|
|
src = read("static/js/editor/wire-extra-menus.js")
|
|
assert "'actions'" in src
|
|
|
|
|
|
def test_actions_panel_css_present():
|
|
src = read("static/css/13-image-editor.css")
|
|
for token in [".ge-actions-step", ".ge-actions-name", ".ge-action-remove", ".ge-actions-batch-row"]:
|
|
assert token in src
|
|
|
|
|
|
def test_actions_panel_is_precached():
|
|
src = read("static/sw.js")
|
|
assert "/static/js/editor/actions-panel.js" in src
|