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

More natural swipe animations. #19

Merged
merged 4 commits into from Nov 6, 2022
Merged

More natural swipe animations. #19

merged 4 commits into from Nov 6, 2022

Conversation

dbuezas
Copy link
Contributor

@dbuezas dbuezas commented Nov 2, 2022

Changes all swipe animation easings to ease-in for the first half and ease-out for the second half

WARNING/SORRY: not tested.

How do you build this?

@zanna-37
Copy link
Owner

zanna-37 commented Nov 2, 2022

How do you build this?

I have to create a guide, I know, it's in the todo list.
Anyway, are you on linux? If so just call scripts/build.sh.

@zanna-37 zanna-37 linked an issue Nov 2, 2022 that may be closed by this pull request
@dbuezas
Copy link
Contributor Author

dbuezas commented Nov 2, 2022

How do you build this?

I have to create a guide, I know, it's in the todo list. Anyway, are you on linux? If so just call scripts/build.sh.

You can also add a script section to the package json, that's where the JavaScript folk (e.g me) looks for build scripts :)
npx rollup --config

@dbuezas
Copy link
Contributor Author

dbuezas commented Nov 2, 2022

Btw, I went slightly overboard and removed a lot of repetition in the code (almost 20 lines less), but the important part are the ease-in and ease-out parameters of the transition.

@dbuezas
Copy link
Contributor Author

dbuezas commented Nov 3, 2022

Built it yet. It has an issue, don't test/merge yet :)

@dbuezas dbuezas marked this pull request as draft November 3, 2022 11:26
@dbuezas dbuezas marked this pull request as ready for review November 3, 2022 12:03
@dbuezas
Copy link
Contributor Author

dbuezas commented Nov 5, 2022

I forgot to mention that the last commit works fine, I'm enjoying this component a lot :)

dbuezas and others added 4 commits November 6, 2022 23:40
@zanna-37
Copy link
Owner

zanna-37 commented Nov 6, 2022

You accidentally disabled swipe when animation=="none", which is the default. 😂 But don't worry, I fixed it.

I took the liberty of rewording your commits as I'm adhering to conventional commits (yes, I know I need to create a CONTRIBUTING file). I hope it's not a problem.

Anyway, thank you a lot for your contribution! Animations are now way snappier! I'm even thinking about using "swipe" as default.

@zanna-37 zanna-37 merged commit d61df03 into zanna-37:main Nov 6, 2022
src/swipe-navigation.ts Show resolved Hide resolved
src/swipe-navigation.ts Show resolved Hide resolved
@dbuezas
Copy link
Contributor Author

dbuezas commented Nov 6, 2022

Happy to hear my changes were worth a merge!
Re commit history rework: I'm rough on git, have been in management for the last 4 or 5 years so catching up. Thanks for mentioning the steps you follow, you inspired me to pay more attention to this (and learn) in my own repos

@dbuezas
Copy link
Contributor Author

dbuezas commented Nov 6, 2022

And yes, swipe feels nice :) I modified the default to swipe on my HA already.
It was a bit of a surprise that eaxh dashboard needs to be configured individually (i assume technical reasons)

@zanna-37
Copy link
Owner

zanna-37 commented Nov 6, 2022

I'm rough on git, have been in management for the last 4 or 5 years so catching up. Thanks for mentioning the steps you follow, you inspired me to pay more attention to this (and learn) in my own repos

Don't worry, and good that you're willing to learn!
I'm very strict when using git 😂 I try to be as clean as possible both with commits and with the graph. I try to create small commits with a single thing in it. In this way, it's easier to navigate the history in the future (and revert mistakes).
For the graph, I tend to follow the principles of gitflow.

It was a bit of a surprise that each dashboard needs to be configured individually (I assume technical reasons)

Yeah, the only way I (well, maykar to be precise) found to have a configuration is to piggyback the dashboard config. But I don't like it too much.
Oh, and be careful, there is a bug that prevent the configuration to update when changing dashboard. It's tracked here #12.

@zanna-37
Copy link
Owner

zanna-37 commented Nov 6, 2022

v1.6.5 is now in pre-release. Feel free to test it and let me know, so I push it for everyone.
Thanks again!

@dbuezas
Copy link
Contributor Author

dbuezas commented Nov 7, 2022

v1.6.5 RC Looking fone so fat

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

Successfully merging this pull request may close these issues.

Swipe animation speed
2 participants