Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix ScrollConfig in web target (#569) #628

Merged
merged 1 commit into from Jul 10, 2023
Merged

Conversation

eymar
Copy link
Collaborator

@eymar eymar commented Jul 7, 2023

This PR "upstreams" the change #569 from wasm-main branch.

It passes the scrollDelta from SkikoPointerEvent to compose pointer event.
The scroll will be animated same as on desktop - it looks more smooth.

* Fix ScrollConfig for web apps

Now it makes the tests pass while looking fine in UI.

* Enable isSmoothScrollingEnabled for web ScrollConfig

* Update compose/foundation/foundation/src/jsWasmMain/kotlin/androidx/compose/foundation/gestures/JsScrollable.js.kt

Co-authored-by: Ivan Matkov <ivan.matkov@jetbrains.com>

* remove redundant imports

* Simplify the fun calculateMouseWheelScroll body

---------

Co-authored-by: Ivan Matkov <ivan.matkov@jetbrains.com>
@eymar eymar requested a review from dima-avdeev-jb July 7, 2023 13:29
@eymar eymar merged commit a258d55 into jb-main Jul 10, 2023
2 checks passed
@eymar eymar deleted the upstream_569_to_jb-main branch July 10, 2023 08:45
Walingar pushed a commit to Walingar/androidx that referenced this pull request Jul 11, 2023
* Fix ScrollConfig for web apps

Now it makes the tests pass while looking fine in UI.

* Enable isSmoothScrollingEnabled for web ScrollConfig

* Update compose/foundation/foundation/src/jsWasmMain/kotlin/androidx/compose/foundation/gestures/JsScrollable.js.kt



* remove redundant imports

* Simplify the fun calculateMouseWheelScroll body

---------

Co-authored-by: Ivan Matkov <ivan.matkov@jetbrains.com>
mazunin-v-jb pushed a commit that referenced this pull request Jul 11, 2023
* Fix ScrollConfig for web apps

Now it makes the tests pass while looking fine in UI.

* Enable isSmoothScrollingEnabled for web ScrollConfig

* Update compose/foundation/foundation/src/jsWasmMain/kotlin/androidx/compose/foundation/gestures/JsScrollable.js.kt



* remove redundant imports

* Simplify the fun calculateMouseWheelScroll body

---------

Co-authored-by: Ivan Matkov <ivan.matkov@jetbrains.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants