Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,12 @@
"laravel/boost": "^2.0",
"laravel/framework": "^13.0",
"laravel/tinker": "^3.0",
"nativephp/mobile": "dev-combined/dev-null-app as 4.6.0",
"nativephp/mobile": "dev-main as 4.6.0",
"nativephp/mobile-browser": "^1.2",
"nativephp/mobile-camera": "^1.1",
"nativephp/mobile-secure-storage": "^1.1",
"nativephp/mobile-share": "^1.1",
"nativephp/mobile-ui": "dev-combined/dev-null-app as 0.8.0",
"nativephp/mobile-ui": "dev-main as 0.8.0",
"s2br/nativephp-mobile-splashscreen": "^1.4"
},
"require-dev": {
Expand Down
32 changes: 17 additions & 15 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions resources/views/native/partials/commit-sheet.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@
The sheet under a commit (see OpensCommitSheet). Quote opens it as a composer: a bar of Cancel, the title and
Commit, which waits for a body long enough to make, over the field, focused, with the commit being quoted under it
as a static card, then the counter. Cancel and Commit are a cross and a check in circles, as Apple draws a sheet's
bar, the same on both platforms (see sheet-bar-button), 16pt in from the sheet's top and sides. Android draws its
handle over the sheet, as iOS does, so the bar starts at the top there too. The title is centred.
bar, the same on both platforms (see sheet-bar-button), 16pt in from the sheet's top and sides. On Android the bar
sits under Material's handle strip, since mobile-ui has no way yet to draw the handle over the content. The title is
centred.
Cancel closes it as a swipe does, keeping the draft. If devnull says no, why shows here and the draft stays. The
Log's compose button opens the same composer for a new commit, without the card. A draft stashed last time comes
back in it, with the web's stash@{0} and drop beside the counter, in the toolbar at the bottom.
Expand All @@ -29,7 +30,7 @@
It's full height for the forms, and short for the receipts. It's always on the screen, shown or not, so iOS can
slide it away and say when it's gone.
--}}
<native:bottom-sheet ref="sheet" handle-over-content :visible="$sheetOpen" :detents="in_array($sheetView, ['reported', 'issued'], true) ? '0.3' : 'large'" @dismiss="commitSheetClosed">
<native:bottom-sheet ref="sheet" :visible="$sheetOpen" :detents="in_array($sheetView, ['reported', 'issued'], true) ? '0.3' : 'large'" @dismiss="commitSheetClosed">
@if ($sheetCommit || in_array($sheetView, ['compose', 'issued'], true))
@if (in_array($sheetView, ['quote', 'compose', 'reply'], true))
@php($quoting = $sheetView === 'quote')
Expand Down
4 changes: 1 addition & 3 deletions tests/Feature/Screens/ComposeSheetTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -193,9 +193,7 @@ function sheetCommitDisabled(TestableComponent $screen): bool
$bar = findNode($screen->tree(), fn (array $node): bool => in_array('sheet-cancel', array_column($node['children'] ?? [], 'ref'), true));
$size = fn (string $ref): array => [sheetButtonCircle($screen, $ref)['layout']['width'], sheetButtonCircle($screen, $ref)['layout']['height']];

// Android draws its handle over the content as iOS does, so the bar's padding is its distance from the sheet's edge.
expect(nodeByRef($screen, 'sheet')['props']['handle_over_content'])->toBeTrue()
->and($bar['layout']['padding'])->toBe(16.0)
expect($bar['layout']['padding'])->toBe(16.0)
->and($size('sheet-cancel'))->toBe([44.0, 44.0])
->and($size('sheet-commit'))->toBe([44.0, 44.0])
->and(nodeByRef($screen, 'sheet-cancel')['props']['a11y_label'])->toBe('Cancel')
Expand Down
Loading