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

[BUG] Item animation onAppear #297

Open
dmikots opened this issue Sep 14, 2022 · 0 comments
Open

[BUG] Item animation onAppear #297

dmikots opened this issue Sep 14, 2022 · 0 comments
Labels
bug Something isn't working

Comments

@dmikots
Copy link

dmikots commented Sep 14, 2022

Hi! I have some problem while slide back. I have 3 image on screen. 1st 1/2 of image, 2 full main image and 3nd 1/2 image. When I slide forward - everything ok. But when I slide back item 1 have animation like onAppear in LazyVGrid( blink ). How can I fix this

        Pager(page: page, data: viewModel.avatars) { avatar in
          ZStack {
            Circle()
              .fill(Color.blackWhite)
              .frame(width: 120, height: 120)
            Image(avatar.asset)
              .resizable()
              .foregroundColor(.whiteBlack)
              .scaledToFit()
              .frame(width: 57, height: 29)
          }
          .frame(width: 120, height: 120)
        }
        .sensitivity(.high)
        .interactive(opacity: 0.3)
        .preferredItemSize(CGSize(width: 200, height: 120))
        .itemSpacing(10)
        .draggingAnimation(.interactive)
        .onPageChanged { pageIndex in
          viewModel.selectAvatar(avatar: viewModel.avatars[pageIndex])
        }

Environment:

  • OSX: [e.g. iOS] 16
  • Device [e.g. iPhone6] 133 pro
  • SwiftUIPager version

Additional context
Add any other context about the problem here.

@dmikots dmikots added the bug Something isn't working label Sep 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant