Skip to content

feat(PopoutWrapper): add prop scrollLock#9513

Closed
EldarMuhamethanov wants to merge 1 commit intomasterfrom
e.muhamethanov/popout-wrapper-add-scroll-lock
Closed

feat(PopoutWrapper): add prop scrollLock#9513
EldarMuhamethanov wants to merge 1 commit intomasterfrom
e.muhamethanov/popout-wrapper-add-scroll-lock

Conversation

@EldarMuhamethanov
Copy link
Copy Markdown
Contributor

@EldarMuhamethanov EldarMuhamethanov commented Feb 25, 2026


  • Unit-тесты
  • Документация фичи
  • Release notes

Описание

Блокировка скролла страницы при показе всплывающих окон перенесена в компонент PopoutWrapper: добавлено свойство scrollLock. Компоненты, которые рендерят контент через PopoutWrapper (ActionSheet, Alert, ScreenSpinner), больше не вызывают useScrollLock сами — блокировка включается через проп scrollLock у PopoutWrapper.

В результате:

  • блокировка скролла настраивается в одном месте (PopoutWrapper);
  • потребителям достаточно передать scrollLock в PopoutWrapper вместо отдельного вызова useScrollLock;
  • документация и примеры переведены на использование scrollLock.

Release notes

Улучшения

  • PopoutWrapper: добавлено свойство scrollLock для блокировки скролла страницы при показе всплывающего окна.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 25, 2026

size-limit report 📦

Path Size
JS 413.6 KB (+0.01% 🔺)
JS (gzip) 126.82 KB (+0.02% 🔺)
JS (brotli) 104.44 KB (-0.01% 🔽)
JS import Div (tree shaking) 811 B (0%)
CSS 374.49 KB (0%)
CSS (gzip) 46.42 KB (0%)
CSS (brotli) 36.72 KB (0%)

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 25, 2026

e2e tests

⚠️ Some screenshots were failed. See Playwright Report.

Playwright Report

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 25, 2026

👀 Docs deployed

📦 Package ✅

yarn add @vkontakte/vkui@https://development.s3.prodcloud.vk.team/pull/9513/7ec8ba54eaa0d6e72a0747a3f9851789dce3a8ff/pkg/@vkontakte/vkui/_pkg.tgz

Commit 7ec8ba5

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 25, 2026

📊 Найдены изменения в собранных файлах: Отчет

Commit 7ec8ba5

@EldarMuhamethanov EldarMuhamethanov force-pushed the e.muhamethanov/popout-wrapper-add-scroll-lock branch from 7dedde9 to 7ec8ba5 Compare February 26, 2026 06:01
@EldarMuhamethanov EldarMuhamethanov changed the title [Draft] feat(PopoutWrapper): add prop scrollLock feat(PopoutWrapper): add prop scrollLock Feb 26, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented Feb 26, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.77%. Comparing base (df50528) to head (7ec8ba5).
⚠️ Report is 73 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #9513      +/-   ##
==========================================
- Coverage   94.77%   94.77%   -0.01%     
==========================================
  Files         441      441              
  Lines       11958    11957       -1     
  Branches     4407     4408       +1     
==========================================
- Hits        11333    11332       -1     
  Misses        625      625              
Flag Coverage Δ
unittests 94.77% <100.00%> (-0.01%) ⬇️

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

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

children,
onClick,
zIndex = 'var(--vkui--z_index_popout)',
scrollLock = false,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

nit: Возможно лучше сразу определиться с будущим поведением. Если в будущем по умолчанию блокируем скролл, то нужно сразу делать обратное свойство disableScrollLock

Suggested change
scrollLock = false,
disableScrollLock = true,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

suggestion: Нужно поправить пример в хуке useScrollLock, там используется PopoutWrapper

@vkcom-publisher vkcom-publisher added pr-needs-work Автоматизация: PR автоматически закроется через 14 дней при отсутствии активности and removed pr-needs-work Автоматизация: PR автоматически закроется через 14 дней при отсутствии активности labels Mar 5, 2026
@vkcom-publisher vkcom-publisher added pr-needs-work Автоматизация: PR автоматически закроется через 14 дней при отсутствии активности and removed pr-needs-work Автоматизация: PR автоматически закроется через 14 дней при отсутствии активности labels Mar 13, 2026
@EldarMuhamethanov
Copy link
Copy Markdown
Contributor Author

Обсудили с командой и решили, что PopoutWrapper пусть остается только вёрсткой

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants