Material design components (inspired by Google Material Design) for iOS written in Swift
Please feel free to make pull requests.
Features
- Highly customizable
- Complete example
- Supports @IBDesignable to live-render the component in the Interface Builder
By suporting @IBInspectable, the class properties can be exposed in the Interface Builder, and you can edit these properties in realtime
[x] MKButton: floating action button, raised button, flat button, ripple effect
- [x] MKTextField: ripple effect, floating placeholder
- [x] MKTableViewCell
- [x] MKLabel
- [x] MKImageView
- [ ] MKTextView (In progress)
- [ ] MKSwitch (In progress)
- [ ] MKAlert (In progress)
- [ ] MKActivityIndicator (In progress)
- [x] MKLayer
- [x] MKColor
Components
MKButton
- There are 3 types of main buttons:
Floating Action Button
,Raised Button
,Flat Button
- Custommizable attributes: color, ripple location, animation timing function, animation duration…
1 2 3 4 |
|
MKTextField
- Single-line text field
- Floating placeholder
- Ripple Animation
- Custommizable attributes: color, ripple location, bottom border, animation timing function, animation duration…
1 2 3 4 5 |
|
MKTableViewCell
- Custommizable attributes: color, ripple location, animation timing function, animation duration…
1 2 3 |
|
MKLabel, MKImageView (BarButtonItem)
- Custommizable attributes: color, ripple location, animation timing function, animation duration…
Play ripple animation whenever you want by calling
animateRipple
method or by settinguserInteractionEnabled = true
ripple animation will be played when the label/imageview is tappedEasy to customize UIBarButtonItem or UITabBarButton by using MKLabel or MKImageView
1 2 3 4 5 6 7 8 |
|
MKProgressView (Coming Soon)
MKLayer
A subclass of CALayer.
MKColor
A category for UIColor that adds some methods to get flat colors designed by Google
1 2 |
|
TODO
- [x] pod file
Installation
- Installation with CocoaPods
1
|
|
- Copying all the files into your project
- Using submodule
Requirements
- iOS 7.0+
- Xcode 6.1
License
MaterialKit is released under the MIT license. See LICENSE for details.