Commit 83b3a2ef by Daniel Dahan

prepare for release with Grid

parent 8db29285
......@@ -39,10 +39,10 @@ class ViewController: UIViewController {
// Examples of using CardView.
// Uncomment different examples and read
// the comments below.
prepareGeneralCardViewExample()
// prepareGeneralCardViewExample()
// prepareCardViewWithoutPulseBackgroundImageExample()
// prepareCardViewWithPulseBackgroundImageExample()
// prepareCardViewButtonBarExample()
prepareCardViewButtonBarExample()
}
/**
......
......@@ -11,8 +11,6 @@
9656CD231C6CFA6200EBCEF1 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9656CD221C6CFA6200EBCEF1 /* ViewController.swift */; };
9656CD281C6CFA6200EBCEF1 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 9656CD271C6CFA6200EBCEF1 /* Assets.xcassets */; };
9656CD2B1C6CFA6200EBCEF1 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 9656CD291C6CFA6200EBCEF1 /* LaunchScreen.storyboard */; };
9656CD331C6CFACC00EBCEF1 /* Material.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9656CD321C6CFACC00EBCEF1 /* Material.framework */; };
9656CD341C6CFACC00EBCEF1 /* Material.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9656CD321C6CFACC00EBCEF1 /* Material.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
/* End PBXBuildFile section */
/* Begin PBXCopyFilesBuildPhase section */
......@@ -22,7 +20,6 @@
dstPath = "";
dstSubfolderSpec = 10;
files = (
9656CD341C6CFACC00EBCEF1 /* Material.framework in Embed Frameworks */,
);
name = "Embed Frameworks";
runOnlyForDeploymentPostprocessing = 0;
......@@ -36,7 +33,6 @@
9656CD271C6CFA6200EBCEF1 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
9656CD2A1C6CFA6200EBCEF1 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
9656CD2C1C6CFA6200EBCEF1 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
9656CD321C6CFACC00EBCEF1 /* Material.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; name = Material.framework; path = "/Users/danieldahan/Library/Developer/Xcode/DerivedData/Material-hbpnflxhoouqxebjcyhbbhqyesjd/Build/Products/Debug-iphoneos/Material.framework"; sourceTree = "<absolute>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
......@@ -44,7 +40,6 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
9656CD331C6CFACC00EBCEF1 /* Material.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
......@@ -54,7 +49,6 @@
9656CD141C6CFA6200EBCEF1 = {
isa = PBXGroup;
children = (
9656CD321C6CFACC00EBCEF1 /* Material.framework */,
9656CD1F1C6CFA6200EBCEF1 /* Grid */,
9656CD1E1C6CFA6200EBCEF1 /* Products */,
);
......
......@@ -39,8 +39,8 @@ class ViewController: UIViewController {
// Examples of using ImageCardView.
// Uncomment different examples and read
// the comments below.
// prepareGeneralImageCardViewExample()
prepareImageCardViewWithoutDetailLabelAndDividerExample()
prepareGeneralImageCardViewExample()
// prepareImageCardViewWithoutDetailLabelAndDividerExample()
}
/**
......@@ -117,7 +117,8 @@ class ViewController: UIViewController {
titleLabel.textColor = MaterialColor.white
titleLabel.font = RobotoFont.regularWithSize(24)
imageCardView.titleLabel = titleLabel
imageCardView.titleLabelInset.top = 80
// Star button.
let img1: UIImage? = UIImage(named: "ic_star_grey_darken_2")
let btn1: FlatButton = FlatButton()
......
......@@ -63,7 +63,6 @@ class ViewController: UIViewController {
let point: CGFloat = UIScreen.mainScreen().bounds.width / 2 - diameter / 2
let materialLayer: MaterialLayer = MaterialLayer(frame: CGRectMake(point, point, diameter, diameter))
materialLayer.shape = .Circle
materialLayer.depth = .Depth2
UIImage.contentsOfURL(NSURL(string: "http://www.cosmicmind.io/CM/iTunesArtwork.png")!) { (image: UIImage?, error: NSError?) in
if let v: UIImage = image {
......
......@@ -56,9 +56,8 @@ class ViewController: UIViewController {
let pulseView: MaterialPulseView = MaterialPulseView(frame: CGRectMake(point, point, 150, 150))
pulseView.image = UIImage(named: "Graph")
pulseView.shape = .Square
pulseView.depth = .Depth2
pulseView.depth = .Depth1
pulseView.cornerRadius = .Radius3
print(pulseView)
// Add pulseView to UIViewController.
view.addSubview(pulseView)
......
......@@ -237,7 +237,7 @@ class ViewController: UIViewController {
view.addSubview(btn3)
// Initialize the menu and setup the configuration options.
flashMenu = Menu(origin: CGPointMake(300, 100))
flashMenu = Menu(origin: CGPointMake((view.bounds.width + btn1.width) / 2, 100))
flashMenu.direction = .Left
flashMenu.buttonSize = btn1.intrinsicContentSize()
flashMenu.buttons = [btn1, btn2, btn3]
......
......@@ -239,7 +239,7 @@ class ViewController: UIViewController {
/// Prepares a text alignment example.
private func prepareAlignTitleAndDetailLabelToLeftExample() {
let navigationBarView: NavigationBarView = NavigationBarView()
navigationBarView.backgroundColor = MaterialColor.deepPurple.base
navigationBarView.backgroundColor = MaterialColor.blue.base
/*
To lighten the status bar - add the
......
......@@ -2,11 +2,12 @@
# Welcome to Material
Material is a graphics and animation framework for Google's Material Design. It is designed to allow the creativity of others to easily be expressed.
Material is a graphics and animation framework. It may be used for Google's Material Design and Apple's Flat UI. It is designed to allow the creativity of others to easily be expressed.
## Features
- [x] Fully Configurable UI Components
- [x] Grid System For Complex UIs
- [x] Base Material Layers & Material Views To Create New UI Components
- [x] Side Navigation View Controller
- [x] Navigation Bar View
......@@ -57,7 +58,8 @@ Material is a growing project and will encounter changes throughout its developm
* [FlatButton](#flatbutton)
* [RaisedButton](#raisedbutton)
* [FabButton](#fabbutton)
* [Menu](#menu)
* [Menu](#menu) (New)
* [Grid](#grid) (New)
* [NavigationBarView](#navigationbarview)
* [SideNavigationViewController](#sidenavigationviewcontroller)
* [CardView](#cardview)
......@@ -164,22 +166,41 @@ A FabButton is essential to Material Design's overall look. Below showcases its
<a name="menu"></a>
## Menu
A Menu manages a group of UIButtons that may be animated open in the Up, Down, Left, and Right directions. The animations are fully customizable. The Examples/Programmatic directory has a sample project using the Menu.
A Menu manages a group of UIButtons that may be animated open in the Up, Down, Left, and Right directions. The animations are fully customizable. The Examples/Programmatic directory has a sample project using the Menu.
Below is an example using FabButtons.
![MaterialFabButton](http://www.cosmicmind.io/MK/MaterialFabMenu.gif)
![MaterialFabMenu](http://www.cosmicmind.io/MK/MaterialFabMenu.gif)
Below is an example using FlatButtons.
![MaterialFabButton](http://www.cosmicmind.io/MK/MaterialFlatMenu.gif)
![MaterialFlatMenu](http://www.cosmicmind.io/MK/MaterialFlatMenu.gif)
Below is an example using FlatButtons with images.
![MaterialFabButton](http://www.cosmicmind.io/MK/MaterialFlashMenu.gif)
![MaterialFlashMenu](http://www.cosmicmind.io/MK/MaterialFlashMenu.gif)
[Learn More About Menu](https://github.com/CosmicMind/Material/wiki/Menu)
<a name="grid"></a>
## Grid
Grid is an extension of UIView that enables any collection of subviews to be managed in a flexible grid system, independent of other views that would need to be freely moving. Below are examples of using Grid. In the Examples/Programmatic directory, there are examples using this wonderful feature.
Below is an example of a small CardView using Grid.
![MaterialSmallCardView](http://www.cosmicmind.io/MK/MaterialGridSmallCardView.gif)
Below is an example of a medium CardView using Grid.
![MaterialGridMediumCardView](http://www.cosmicmind.io/MK/MaterialGridMediumCardView.gif)
Below is an example of a large CardView using Grid.
![MaterialGridLargeCardView](http://www.cosmicmind.io/MK/MaterialGridLargeCardView.gif)
[Learn More About Grid](https://github.com/CosmicMind/Material/wiki/Grid)
<a name="navigationbarview"></a>
## NavigationBarView
......@@ -211,10 +232,6 @@ Easily remove the pulse animation and add a background image for an entirely new
![MaterialCardViewFavorite](http://www.cosmicmind.io/MK/MaterialCardViewFavorite.gif)
Adjust the alignment of the UI elements to create different configurations of the CardView.
![MaterialCardViewDataDriven](http://www.cosmicmind.io/MK/MaterialCardViewFavoritePulse.gif)
CardViews are so flexible they create entirely new components by removing all but certain elements. For example, bellow is a button bar by only setting the button values of the CardView.
![MaterialCardViewButtonBar](http://www.cosmicmind.io/MK/MaterialCardViewButtonBar.gif)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment