-
Notifications
You must be signed in to change notification settings - Fork 185
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(Panel): Add mode #6678
feat(Panel): Add mode #6678
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 c96d514 |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #6678 +/- ##
==========================================
+ Coverage 82.24% 82.26% +0.01%
==========================================
Files 331 331
Lines 10270 10288 +18
Branches 3439 3445 +6
==========================================
+ Hits 8447 8463 +16
- Misses 1823 1825 +2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Because in any case it ends up as background of root. We just use same background we have for the root defined in the common.css for the layout. Remove transparency to avoid questions about why it needs here.
Скриншоты че т сильно выросли, там они точно нужны со всеми вариациями?) |
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.
Нужна именно вариация mode + sizeX. Переместил тесты в отдельный плейграунд, а то тут в куче уже непонятно становится. |
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.
🤝
Описание
Добавляем новое свойство
mode
дляPanel
, по аналогии с Group.Подразумевается использование вместе с Group, чтобы точечно задавать стиль card для Group с верным фоном, а не только для всего макета, как можно делать сейчас со свойством layout из
AppRoot
.Изменения
regular
. Не очень понятна причина по которой это раньше было добавлено. Судя по 71e1293, это связано со многоколоночным режимом, но что именно пытались решить не понятно, точнее не понятно актуально ли это сейчас или нет.Пока же, судя по коду, с прозрачностью фон становится идентичным тому, который задаёт
AppRoot
по стилям из common.css.VKUI/packages/vkui/src/styles/common.css
Lines 28 to 36 in f7f6dea
То есть замена прозрачности на явные токены, которые идентичны AppRoot, визуально для приложений ничего не меняет, но у прощает css.
Тем не менее это затронуло скриншотные тесты в Playwright в dark режиме. Должно быть потому, что
AppRootWrapper
имеет немного другой фон и без прозрачности цвет Panel в скриншотах стал отличаться.VKUI/packages/vkui/src/testing/e2e/AppDefaultWrapper.tsx
Line 11 in f7f6dea
VKUI/packages/vkui/playwright/index.css
Line 107 in f7f6dea
На скриншоте слева фон черный
#000000
, а справа#0a0a0a