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

fix(Gallery): timeout inactive tab issue #5954

Merged
merged 1 commit into from
Oct 11, 2023

Conversation

BlackySoul
Copy link
Contributor


- [ ] Unit-тесты
- [ ] e2e-тесты
- [ ] Дизайн-ревью
- [ ] Документация фичи

Описание

При уходе с активной вкладки копились колбэки по проигрыванию анимации

Изменения

Подписываемся на событие visibilitychange, чтобы отключать автоматическое пролистывание слайдов, когда пользователь уходит с вкладки

@github-actions
Copy link
Contributor

size-limit report 📦

Path Size
JS 325.18 KB (+0.09% 🔺)
JS (gzip) 99.16 KB (+0.11% 🔺)
JS (brotli) 81.94 KB (+0.1% 🔺)
JS import Div (tree shaking) 2.71 KB (0%)
CSS 255.21 KB (0%)
CSS (gzip) 33.52 KB (0%)
CSS (brotli) 27.18 KB (0%)

@codesandbox-ci
Copy link

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 41094e6:

Sandbox Source
VKUI TypeScript Configuration

@github-actions
Copy link
Contributor

e2e tests

Playwright Report

@codecov
Copy link

codecov bot commented Oct 11, 2023

Codecov Report

Attention: 9 lines in your changes are missing coverage. Please review.

Comparison is base (0cb089e) 79.19% compared to head (41094e6) 79.14%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #5954      +/-   ##
==========================================
- Coverage   79.19%   79.14%   -0.06%     
==========================================
  Files         304      305       +1     
  Lines        9516     9535      +19     
  Branches     3219     3222       +3     
==========================================
+ Hits         7536     7546      +10     
- Misses       1980     1989       +9     
Flag Coverage Δ
unittests 79.14% <60.86%> (-0.06%) ⬇️

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

Files Coverage Δ
packages/vkui/src/components/Gallery/Gallery.tsx 97.14% <100.00%> (-0.16%) ⬇️
packages/vkui/src/components/Gallery/hooks.ts 57.14% <57.14%> (ø)

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

@github-actions
Copy link
Contributor

👀 Docs deployed

Commit 41094e6

Copy link
Contributor

@mendrew mendrew left a comment

Choose a reason for hiding this comment

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

Класс 🔥

Жаль, что тут тесты сложно написать.

@BlackySoul BlackySoul added patch Автоматизация: PR продублируется в ветку последнего минорного релиза для выпуска патча v5 Автоматизация: PR продублируется в ветку v5 labels Oct 11, 2023
@BlackySoul BlackySoul merged commit 2715ada into master Oct 11, 2023
@BlackySoul BlackySoul deleted the fix/5951/Gallery_fix_timeout branch October 11, 2023 11:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
patch Автоматизация: PR продублируется в ветку последнего минорного релиза для выпуска патча v5 Автоматизация: PR продублируется в ветку v5
Projects
None yet
3 participants