Files
odysseus/tests/test_editor_text_options_layout.py
T
pewdiepie-archdaemonandClaude Opus 5.5 5fac693c1c 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>
2026-10-15 11:57:35 +00:00

30 lines
1.3 KiB
Python

from pathlib import Path
ROOT = Path(__file__).resolve().parents[1]
CSS = ROOT / "static/css/13-image-editor.css"
def test_text_options_strip_lays_grids_out_as_rows():
css = CSS.read_text(encoding="utf-8")
# The vertical Text panel must become a horizontal strip in the options bar.
assert ".ge-controls--in-options .ge-text-section .ge-text-grid" in css
assert ".ge-controls--in-options .ge-text-section .ge-text-field" in css
def test_text_options_font_picker_keeps_its_width():
css = CSS.read_text(encoding="utf-8")
# Regression: the Font picker collapsed to ~14px and the Font/Size labels
# piled into "FoSize". The font field must reserve real width.
assert ".ge-controls--in-options .ge-text-section .ge-text-font-field { min-width: 116px; }" in css
assert ".ge-controls--in-options .ge-text-section .ge-text-size-field { min-width: 56px; }" in css
# And the pickers must fill their reserved field.
assert ".ge-controls--in-options .ge-text-section .ge-text-field > select," in css
assert ".ge-controls--in-options .ge-text-section .ge-text-field > input { width: 100%; }" in css
def test_text_options_textarea_sized_for_the_bar():
css = CSS.read_text(encoding="utf-8")
assert ".ge-controls--in-options .ge-text-section textarea" in css
assert "width: 200px;" in css