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

Type 'AnimationType' has no member 'from' #74

Open
d0hnj0e opened this issue Sep 19, 2020 · 7 comments
Open

Type 'AnimationType' has no member 'from' #74

d0hnj0e opened this issue Sep 19, 2020 · 7 comments

Comments

@d0hnj0e
Copy link

d0hnj0e commented Sep 19, 2020

Steps to Reproduce the Problem

  1. import ViewAnimator
  2. let moveFromLeftAnimation = AnimationType.from(direction: .left, offset: 50)
  3. swipeTextLabelOutlet.animate(animations: [moveFromLeftAnimation], initialAlpha: 0, finalAlpha: 1, delay: baseDelay + delayTwo, duration: duration)

results in

Cannot infer contextual base in reference to member 'left'
Type 'AnimationType' has no member 'from'

Possible choices are

Screenshot 2020-09-19 at 08 56 18

Specifications

  • Version: Xcode Version 12.0 (12A7209), iOS 14.0, iPhone 11 Pro, ViewAnimator v. 3.0.1
@boardmain
Copy link

Same problem

@marcosgriselli
Copy link
Owner

marcosgriselli commented Sep 19, 2020

@d0hnj0e @boardmain I changed the API in 3.0 to use AnimationType.vector(CGVector) to support different types of animations. This change brought some issues apparently which I'm still to review/fix (#72). If you'd like to keep using the .from API I recommend you stick to version 2.7.1 for the moment.

@d0hnj0e
Copy link
Author

d0hnj0e commented Sep 19, 2020

Thanks for the clarification!

@samdogg7
Copy link

samdogg7 commented Nov 5, 2020

@marcosgriselli Will AnimationType.from be added back or should I stick with the vector?

@marcosgriselli
Copy link
Owner

@samdogg7 I can add it back. Clearly the vector API idea created more confusion than solutions 😅

@samdogg7
Copy link

samdogg7 commented Nov 6, 2020

@marcosgriselli You don't need to add it back. I was originally confused, I didn't see anything about vector on the readme page. Figured it out through your examples!

@passatgt
Copy link

Btw i had to use 2.7.0 to resolve this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants