Latest 1.0.5
Homepage https://github.com/longhorn499/ActivityIndicatingNavigationItem
License MIT
Platforms ios 10.0, requires ARC
Authors

UINavigationItem subclass that indicates activity with UIActivityIndicator for right and left bar button items.

Platform iOS
CocoaPods compatible
MIT license

Description

A UINavigationItem subclass you can use to easily animate loading on either side.

  • Useful for indicating activity with system "Save" or "Done" bar buttons
  • Common in iOS UI/UX design when tapping a bar button saves or loads information

ActivityNavigationItem

Installation

With CocoaPods, add ActivityNavigationItem to your Podfile:

pod 'ActivityNavigationItem'

Then install with pod install.

Or you can manually import the files from the Source folder.

Usage

If you’re using a Storyboard, set the name of the Class and Module, then create an outlet:

@IBOutlet weak var activityNavigationItem: ActivityNavigationItem!

Or set up programmatically:

let activityNavigationItem = ActivityNavigationItem.init(title: "Edit Profile", indicatorStyle: .white)

Start animating side:

activityNavigationItem.startAnimating(.right)

Stop animating:

activityNavigationItem.stopAnimating(.right)

Configuration

Changing the activity indicator style (default style is gray):

activityNavigationItem.indicatorStyle = .white

Changing the activity indicator color (can also update in Storyboard):

activityNavigationItem.indicatorColor = .blue

Requirements

Written in Swift 4.0, requires iOS 10.0 and above, Xcode 9.0 and above.

Credits

Created by Kevin Johnson.

License

Available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "ActivityNavigationItem",
    "version": "1.0.5",
    "summary": "UINavigationItem subclass that indicates activity",
    "description": "Animate the right/left positions with this UINavigationItem subclass. Now a common UI practice for saving/loading information with bar button taps",
    "homepage": "https://github.com/longhorn499/ActivityIndicatingNavigationItem",
    "license": "MIT",
    "authors": {
        "longhorn499": "[email protected]"
    },
    "social_media_url": "http://twitter.com/dirtydan499",
    "platforms": {
        "ios": "10.0"
    },
    "source": {
        "git": "https://github.com/longhorn499/ActivityIndicatingNavigationItem.git",
        "tag": "1.0.5"
    },
    "source_files": "Source/*.swift",
    "requires_arc": true,
    "pushed_with_swift_version": "4.0"
}

Pin It on Pinterest

Share This