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

feat(AppRoot): add layout #5642

Merged
merged 2 commits into from
Aug 31, 2023
Merged

feat(AppRoot): add layout #5642

merged 2 commits into from
Aug 31, 2023

Conversation

SevereCloud
Copy link
Contributor

@SevereCloud SevereCloud commented Aug 18, 2023

Добавляем новое свойство layout: 'plain' | 'card'

image

Изменяем вид Group при mode="card" и sizeX="compact"

image

@codesandbox-ci
Copy link

codesandbox-ci bot commented Aug 18, 2023

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.

Latest deployment of this branch, based on commit 3a7b44f:

Sandbox Source
VKUI TypeScript Configuration

@codecov
Copy link

codecov bot commented Aug 18, 2023

Codecov Report

Patch coverage: 82.75% and project coverage change: -0.01% ⚠️

Comparison is base (38a57c6) 81.93% compared to head (3a7b44f) 81.92%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #5642      +/-   ##
==========================================
- Coverage   81.93%   81.92%   -0.01%     
==========================================
  Files         296      296              
  Lines        9780     9800      +20     
  Branches     3102     3105       +3     
==========================================
+ Hits         8013     8029      +16     
- Misses       1767     1771       +4     
Flag Coverage Δ
unittests 81.92% <82.75%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Changed Coverage Δ
...ages/vkui/src/components/AppRoot/AppRootContext.ts 100.00% <ø> (ø)
packages/vkui/src/components/Group/Group.tsx 87.27% <69.23%> (-4.22%) ⬇️
packages/vkui/src/components/AppRoot/AppRoot.tsx 92.37% <92.30%> (-0.29%) ⬇️
packages/vkui/src/components/Panel/Panel.tsx 100.00% <100.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@github-actions
Copy link
Contributor

github-actions bot commented Aug 18, 2023

size-limit report 📦

Path Size
JS 316.37 KB (+0.09% 🔺)
JS (gzip) 93.22 KB (+0.1% 🔺)
JS (brotli) 77.06 KB (+0.12% 🔺)
JS import Div (tree shaking) 3.04 KB (0%)
CSS 276.71 KB (+0.33% 🔺)
CSS (gzip) 36.11 KB (+0.28% 🔺)
CSS (brotli) 28.64 KB (+0.31% 🔺)

@github-actions
Copy link
Contributor

👀 Docs deployed

Commit ee5bed3

@github-actions
Copy link
Contributor

github-actions bot commented Aug 18, 2023

e2e tests

Playwright Report

@SevereCloud SevereCloud requested a review from a team August 18, 2023 12:27
@github-actions github-actions bot added the pr-needs-work Автоматизация: PR автоматически закроется через 14 дней при отсутствии активности label Aug 26, 2023
@inomdzhon
Copy link
Contributor

В ветке конфликты :(

SevereCloud and others added 2 commits August 30, 2023 11:45
Добавляем новое свойство `layout: 'plain' | 'card'`

Изменяем вид Group при mode="card" и sizeX="compact"

- closed #3018
Co-authored-by: Inomdzhon Mirdzhamolov <[email protected]>
Copy link
Contributor

@inomdzhon inomdzhon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚡⚡⚡

@github-actions
Copy link
Contributor

👀 Docs deployed

Commit 3a7b44f

@github-actions github-actions bot removed the pr-needs-work Автоматизация: PR автоматически закроется через 14 дней при отсутствии активности label Aug 30, 2023
@SevereCloud SevereCloud merged commit 5520f4e into master Aug 31, 2023
22 of 23 checks passed
@SevereCloud SevereCloud deleted the SevereCloud/issue3018 branch August 31, 2023 06:26
inomdzhon added a commit that referenced this pull request Aug 2, 2024
inomdzhon added a commit that referenced this pull request Aug 5, 2024
inomdzhon added a commit that referenced this pull request Aug 7, 2024
h2. Описание

- реструктурировал CSS файл, чтобы было понятней что к чему;
- размеры заменил на токены из [@vkonktate/vkui-tokens](https://github.com/VKCOM/vkui-tokens/blob/ecdad88decf36df7ad14f5df493ba5adbddae6a5/src/themeDescriptions/base/paradigm.ts#L749-L759);
- отказался от использования `<Separator />` из-за того, что его задевает `vkuiInternalModalPage`, вместо этого объединил `Group__separator--spacing` и `Group__separator--separator` в один элемент `Group__separator`;
- добавил модификатор `Group--sizeX--regular`, т.к. он определяет `mode` как `"card"` при `sizeX="regular"`, если `mode === "none"`;
- вынес `<Separator />` из `<div />` в `ModalPageHeader.tsx`, чтобы боковые отступы не влияли на размеры сепаратора.

h3. Дизайн

Внутри `ModalPage`

При `platform="android"`/`platform="ios"` и `sizeX="regular"` в `ModalPageHeader` удаляем отступы у `Separator`.

<img width="320" alt="image" src="https://github.com/user-attachments/assets/104f9be1-d7b5-4d60-8618-1d4dbee904f0"> <img width="313" alt="image" src="https://github.com/user-attachments/assets/53149f5b-e662-4908-9ae1-774b8e475dd8">

_до и после_

---

- related to #5344, #5364, #5371, #5642
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants