* Draw vertices to shared offscreen canvas on browsers that support OffscreenCanvas.
* Move gl rendering code to render_vertices.dart.
* Reuse shaders and program across calls.
This prevents us from synthesizing an 'add' event if we get a 'move'
event after a 'down' event. This was causing errors because on the
framework side, it will synthesize an 'add' event if it receives a
'down' event, and if you send another 'add' event (e.g. with a 'move'
after a 'down') then it will throw an AssertionError since it already
has received an 'add' event for that pointer.
Fixes https://github.com/flutter/flutter/issues/40385
* do not wrap font family name in webkit otherwise icons not show on safari 13 (both IOS and desktop)
* Changing the font loading to work in all browsers.
* Documentation, renaming, gramatical/spelling error related PR comments addressed. Regexp will be addressed in the next commit.
* Changing regular expressions to look simpler. Adding more unit tests.
* WIP on fixing pointer event clicks
* Don't set canvaskit as enabled by default
* Use a Set of pressed buttons rather than a Map of button status to
avoid memory leaks
* Add test for pointer binding
Fix bug where event listeners weren't properly removed
* Fixing invalid state bug for text editing. Flutter Framework was sending editing state selection base and extent as -1. Since -1 is an invalid value for a dom element selection it was not applied to the last editing state. Now if the base or offset is sent as negative value, web engine will set 0 to the selection range.
* Addressing PR comments.
* reflect selection changes in Firefox. With this change if the keyboard arrow keys to move the cursor the selection change is synced to Flutter Framework
* Addresing PR comments. Renaming. Adding the domelement to SelectionChangeDetection constructor.
* add initial value to selection start/end
add initial value to selection start/end
* Interpret negative radii as 0 in recording_canvas drawDRRect
This allows drawing DRRects that may have some negative values on
its corners (caused by deflating a RRect with some non-round corners,
for example)
See added unit test for an example of the above.
Fixes https://github.com/flutter/flutter/issues/40728
* Import all golden files and tests from internal repo.
* Adapt test files to new screenshot API, and tweak some settings.
(Check PR to see individual changes to each file)
Fixes https://github.com/flutter/flutter/issues/40975
New features for golden tests (for web):
* Height/width of headless browser instance extracted to constants
* Remove border from the host iframe
* Added 'region' to matchGoldenFile, so screenshots can capture only
a subset of the viewport
* Added image-format-awareness (png) to screenshot comparison, so it
doesn't only look at raw bytes
* When a test fails, output a diff image alongside the unexpected
output.
* enabling spellcheck for text editing
* Fixing errors in the input box, which arrises when the fontweight is null.
* Rollback the spellcheck change. Still not tested in safari mobile.
* Carrying the assignment of fontweight from index to EditingStyle constructor. This reduce # of null checks to one.
- Add a custom `PlatformPlugin` that spins up a server waiting for test to request a screenshot.
- When a screenshot is requested the plugin talks to Chrome via the debug port, captures a screenshot, and compares it with a golden file
- This PR also adds proper CLI for `dev/test.dart` with an `ArgParser` for future extension into a proper developer tool for the team.
- As a first couple of features, it adds `--debug` option to launch Chrome in debug mode, a `--target` option to choose a single test to run rather than all tests, and `--shard` option to choose a subset of tests to run.
Limitations:
- While screenshot test will run on Cirrus, they are configured to not fail on Cirrus. Need to solve Chrome version skew.
- Stack maps do not work yet (you get stacks, but they are nonsensical)
- When requesting a single test, build_runner builds all tests anyway
- Nothing but desktop Chrome is supported
- Nothing but Linux is supported
- There's no Chrome version pinning; currently assumed stable Chrome channel