-
Notifications
You must be signed in to change notification settings - Fork 186
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(PanelHeader): Replace FixedLayout with sticky position #6609
fix(PanelHeader): Replace FixedLayout with sticky position #6609
Conversation
size-limit report 📦
|
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. |
e2e tests |
👀 Docs deployed
Commit 49b6f96 |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #6609 +/- ##
==========================================
- Coverage 82.21% 82.20% -0.01%
==========================================
Files 331 331
Lines 10250 10246 -4
Branches 3439 3436 -3
==========================================
- Hits 8427 8423 -4
Misses 1823 1823
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Because it's the default value, so we don't need set it again. Also it breaks fixed prop as it doesn't allow to override position due to cascade.
221ba5c
to
c6d079d
Compare
@@ -244,7 +240,6 @@ | |||
* VKCOM | |||
*/ | |||
.PanelHeader--vkcom { | |||
position: relative; |
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.
Убрал, потому что иначе проп fixed
не работает с платформой vkcom
.
А не работает из-за того, что веса PanelHeader--fixed
cо sticky
и .PanelHeader--vkcom
теперь одинаковы.
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.
🎉
display: block; | ||
content: ''; | ||
.PanelHeader--fixed { | ||
position: sticky; |
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.
Возможно стоит добавить backface-visibility: hidden
, сталкивался с багом то ли в сафари, то ли в хроме, когда стики то пропадает, то появляется. Мб сейчас уже ок, не смог найти инфы в инете поправлено ли.
Ссылки
Заметил, что если использовать PanelHeader в многоколоночном интерфейсе на широком экране на Android или iOS, передавая PanelHeader в свойство Screen.Recording.2024-03-01.at.16.33.26.movПеревожу пока в draft. Надо подумать. |
Другая причина не переходить полностью на Screen.Recording.2024-03-05.at.18.23.17.mov |
PR закрыт из-за отсутствия активности в течение последних 14 дней. Если это произошло по ошибке или изменения все ещё актуальны, откройте PR повторно. |
related (по поводу использования
position sticky
): #2422 (comment) #2414 (comment)Описание
Убираем использование
FixedLayout
изPanelHeader
, так как это провоцирует ререндер и сдвиг контента из-за того, чтоFixedLayout
адаптирует свою ширину под ширинуSplitCol
.Только сейчас по браузерной поддержке мы можем использовать
position: sticky
.Изменения
FixedLayout
наposition: sticky
.