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
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).

## [Unreleased]

- Fix browser input and action events on NativePHP versions that expose
`dispatchUiEvent()`, retaining the legacy dispatcher for older versions.

First public alpha, installable from `main`. Renders `Route::native()`
screens as HTML in a browser from the same Blade source the mobile app
ships.
Expand Down
6 changes: 5 additions & 1 deletion src/Protocol/WebScreenRunner.php
Original file line number Diff line number Diff line change
Expand Up @@ -340,7 +340,11 @@ public function update(Request $request)

static::scoped($component, function () use ($event) {
/** @var NativeComponent $this */
$this->dispatch($event);
if (method_exists($this, 'dispatchUiEvent')) {
$this->dispatchUiEvent($event);
} else {
$this->dispatch($event);
}
});
}

Expand Down
Loading