add ClideLightbox — click image cards to enlarge (T-252)
The inline image cards (T-249) are often too small to read. Clicking one now opens a full-screen lightbox: zoom (scroll wheel / pinch), pan when zoomed, double-click to reset to fit, Esc / close button / backdrop click to dismiss. ClideLightbox is a reusable primitive (lib/widgets/) over Flutter's InteractiveViewer with clide-owned zoom gestures, shown via the DialogRouter (dimmed backdrop, single modal at a time, D-78). The card stays display-only; the click is a navigation gesture, not an inline control. CLI parity (D-6): `clide image show <path> --fullscreen` opens straight into the lightbox instead of injecting a card. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -49,6 +49,14 @@ void main() {
|
||||
expect(published.single.data, {'path': '/abs/docs/diagram.png', 'caption': 'before the fix'});
|
||||
});
|
||||
|
||||
test('--fullscreen rides along in the payload (T-252)', () async {
|
||||
wire();
|
||||
final r = await show(['docs/diagram.png'], flags: {'fullscreen': true});
|
||||
expect(r.ok, isTrue, reason: r.error?.message);
|
||||
expect(r.data['fullscreen'], isTrue);
|
||||
expect(published.single.data, {'path': '/abs/docs/diagram.png', 'fullscreen': true});
|
||||
});
|
||||
|
||||
test('accepts the documented formats case-insensitively', () async {
|
||||
for (final name in ['a.PNG', 'b.jpg', 'c.jpeg', 'd.gif', 'e.webp', 'f.bmp']) {
|
||||
wire(found: {name});
|
||||
|
||||
Reference in New Issue
Block a user