25

GitHub - zmcartor/ThinkingFaces: Collection of animated spinners and bouncers fo...

 6 years ago
source link: https://github.com/zmcartor/ThinkingFaces
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

README.md

ThinkingFaces

Collection of animated spinners and bouncers for iOS. Thanks very much for looking at this repo. Hopefully these classes can form the starting point to your own custom activity indicator, or 'thinking face.'

Contributing ?

Contributions always welcome. If you have a new idea for a fun spinner or bouncer, or see something that could be improved, please open a PR.

Usage ?

Playgrounds built with Xcode 9.3 ? All components are a single class, and come packaged within a playground. Tweak any parameters or timing curves you'd like, and then copy the code out into your own project. All of the classes come with built-in accessors for timing, tint, and other params.

⭐️Each component is ~100lines of code, and can be tweaked or act as a starting point for your own custom spinner. ?

Component Summary ?

SquareForce ◾️

Kinetic bouncing ball. Customizable via tintColor and circleDiameter

square.gif

StickySpinner ?

Inspired by Google, this spinner stretches and adjusts it's thickness for a more organic feel. Customizable via tintColor , thickness and rotationTime

sticky.gif

FlowerSpinner ?

Much like the system default UIActivitySpinner. Customizable via speed, numberOfCircles and tintColor

flower1.gif

Adding many circles can create a more interesting shape.

flower2.gif

SolarSpinner ??

A plinky animated solarsystem. The sizes of all planets, colors and spacing is all parameterizable. spacing and masses all take a tuple of three Ints. bodyColors accepts a tuple of UIColor. Use this as a starting point and hack the code to add more than 3 planets.

solar.gif

Shoestrap ?

Inspired from the ubiquitous 'Bootstrap' styled spinner. Customizable via tintColor, thickness, rotationTime, trackColor

A very thin track tinted blue:

shoestrap1.gif

Or a very thick track

shoestrap2.gif

Ringo ?

Pulsing ring animation customizable via tintColor, speed, and entropy. A higher entropy will make the pulse animation looks like a telescoping gradient.

The blue gif has a high entropy. Notice the pulse feels like it's 'buzzing'

ringo.gif

The red gif has a lower entropy.

ringored.gif

YoYo Bouncer ?

Abstract bouncer that looks a little like sun/moon trading places. Supports speed and tintColor

yoyo.gif

FadeSpinner ?

Fading circles rotate clockwise. Customizable speed, numberOfCircles , tintColor.

dot-fade.gif

Adding more circles

dot-fade2.gif


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK