-
-
Notifications
You must be signed in to change notification settings - Fork 9.5k
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
feat(swipe): add RTL mode #13123
base: main
Are you sure you want to change the base?
feat(swipe): add RTL mode #13123
Conversation
swipe add rtl mode
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #13123 +/- ##
==========================================
- Coverage 93.81% 93.67% -0.14%
==========================================
Files 257 257
Lines 6999 7018 +19
Branches 1730 1742 +12
==========================================
+ Hits 6566 6574 +8
- Misses 377 386 +9
- Partials 56 58 +2 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个 PR 看起来会极大地影响 Swipe 组件的性能,因为涉及到大量的 isRtl()
调用,里面需要调用 getComputedStyle
,会产生性能开销。
社区里 Swipe 组件一般都是怎么适配 RTL 的呢?感觉需要先做下调研
对这里进行了优化,只在initialize中进行一次调用 |
新增了swipe在direction属性为rtl时的布局和交互
更好的支持阿拉伯语、波斯语等RTL语言场景