Skip to content
This repository has been archived by the owner on Aug 13, 2021. It is now read-only.

Commit

Permalink
Merge branch 'release-candidate' into stable
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeff Verkoeyen committed Mar 25, 2017
2 parents c3140ba + 9726d78 commit 65580d6
Show file tree
Hide file tree
Showing 200 changed files with 12,392 additions and 509 deletions.
5 changes: 3 additions & 2 deletions .arcconfig
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,18 @@
],
"arcanist_configuration": "HookConphig",
"phabricator.uri": "http://codereview.cc/",
"repository.callsign": "REACTIVEMOTIONSWIFT",
"arc.land.onto.default": "develop",
"arc.feature.start.default": "origin/develop",
"unit.xcode": {
"build": {
"workspace": "MaterialMotionStreams.xcworkspace",
"workspace": "MaterialMotion.xcworkspace",
"scheme": "UnitTests",
"configuration": "Debug",
"destination": "platform=iOS Simulator,name=iPhone 6s"
},
"coverage": {
"product": "MaterialMotionStreams.framework/MaterialMotionStreams"
"product": "MaterialMotion.framework/MaterialMotion"
},
"pre-build": "pod install"
}
Expand Down
10 changes: 5 additions & 5 deletions .jazzy.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module: MaterialMotionStreams
module: MaterialMotion
module_version: 1.0.0
sdk: iphonesimulator
xcodebuild_arguments:
- -workspace
- MaterialMotionStreams.xcworkspace
- MaterialMotion.xcworkspace
- -scheme
- MaterialMotionStreams
github_url: https://github.com/material-motion/streams-swift
github_file_prefix: https://github.com/material-motion/streams-swift/tree/v1.0.0
- MaterialMotion
github_url: https://github.com/material-motion/material-motion-swift
github_file_prefix: https://github.com/material-motion/material-motion-swift/tree/v1.0.0
4 changes: 1 addition & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
language: objective-c
osx_image: xcode8.1
sudo: false
notifications:
email: false
before_install:
- gem install cocoapods --no-rdoc --no-ri --no-document --quiet
- git clone https://github.com/phacility/arcanist.git
Expand All @@ -12,6 +10,6 @@ before_install:
script:
- set -o pipefail
- arcanist/bin/arc unit --everything --trace
- xcodebuild build -workspace MaterialMotionStreams.xcworkspace -scheme Catalog -sdk "iphonesimulator10.1" -destination "name=iPhone 6s,OS=10.1" ONLY_ACTIVE_ARCH=YES | xcpretty -c;
- xcodebuild build -workspace MaterialMotion.xcworkspace -scheme MaterialMotionCatalog -sdk "iphonesimulator10.1" -destination "name=iPhone 6s,OS=10.1" ONLY_ACTIVE_ARCH=YES | xcpretty -c;
after_success:
- bash <(curl -s https://codecov.io/bash)
461 changes: 461 additions & 0 deletions CHANGELOG.md

Large diffs are not rendered by default.

15 changes: 15 additions & 0 deletions MaterialMotion.podspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
Pod::Spec.new do |s|
s.name = "MaterialMotion"
s.summary = "Reactive motion driven by Core Animation."
s.version = "1.0.0"
s.authors = "The Material Motion Authors"
s.license = "Apache 2.0"
s.homepage = "https://github.com/material-motion/material-motion-swift"
s.source = { :git => "https://github.com/material-motion/material-motion-swift.git", :tag => "v" + s.version.to_s }
s.platform = :ios, "9.0"
s.requires_arc = true

s.source_files = "src/**/*.{swift}"

s.dependency "IndefiniteObservable", "~> 3.0"
end
28 changes: 0 additions & 28 deletions MaterialMotionStreams.podspec

This file was deleted.

14 changes: 8 additions & 6 deletions Podfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
workspace 'MaterialMotionStreams.xcworkspace'
workspace 'MaterialMotion.xcworkspace'
use_frameworks!

target "Catalog" do
target "MaterialMotionCatalog" do
pod 'CatalogByConvention'
pod 'MaterialMotionStreams/examples', :path => './'
project 'examples/apps/Catalog/Catalog.xcodeproj'
pod 'MaterialMotion', :path => './'

project 'examples/apps/Catalog/MaterialMotionCatalog.xcodeproj'
end

target "UnitTests" do
project 'examples/apps/Catalog/Catalog.xcodeproj'
pod 'MaterialMotionStreams/tests', :path => './'
pod 'MaterialMotion', :path => './'

project 'examples/apps/Catalog/MaterialMotionCatalog.xcodeproj'
end

post_install do |installer|
Expand Down
24 changes: 24 additions & 0 deletions Podfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
PODS:
- CatalogByConvention (2.0.0)
- IndefiniteObservable (3.1.0):
- IndefiniteObservable/lib (= 3.1.0)
- IndefiniteObservable/lib (3.1.0)
- MaterialMotion (1.0.0):
- IndefiniteObservable (~> 3.0)

DEPENDENCIES:
- CatalogByConvention
- MaterialMotion (from `./`)

EXTERNAL SOURCES:
MaterialMotion:
:path: "./"

SPEC CHECKSUMS:
CatalogByConvention: be55c2263132e4f9f59299ac8a528ee8715b3275
IndefiniteObservable: 2789d61f487d8d37fa2b9c3153cc44d4447ff744
MaterialMotion: 967eed88a2f4add305ea8768bbc49283283c1e83

PODFILE CHECKSUM: f503265a0d60526a0d28c96dd4bdcfb40fb562fc

COCOAPODS: 1.2.0
165 changes: 146 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,82 @@
# Material Motion streams for Apple devices

[![Build Status](https://travis-ci.org/material-motion/streams-swift.svg?branch=develop)](https://travis-ci.org/material-motion/streams-swift)
[![codecov](https://codecov.io/gh/material-motion/streams-swift/branch/develop/graph/badge.svg)](https://codecov.io/gh/material-motion/streams-swift)
[![CocoaPods Compatible](https://img.shields.io/cocoapods/v/MaterialMotionStreams.svg)](https://cocoapods.org/pods/MaterialMotionStreams)
[![Platform](https://img.shields.io/cocoapods/p/MaterialMotionStreams.svg)](http://cocoadocs.org/docsets/MaterialMotionStreams)
[![Docs](https://img.shields.io/cocoapods/metrics/doc-percent/MaterialMotionStreams.svg)](http://cocoadocs.org/docsets/MaterialMotionStreams)
# Material Motion

> Reactive motion driven by Core Animation.
![Swift 3.1.x](https://img.shields.io/badge/Swift-3.1.x-orange.svg)
![iOS 9.0+](https://img.shields.io/badge/iOS-9.0+-orange.svg)
[![Build Status](https://travis-ci.org/material-motion/material-motion-swift.svg?branch=develop)](https://travis-ci.org/material-motion/material-motion-swift)
[![codecov](https://codecov.io/gh/material-motion/material-motion-swift/branch/develop/graph/badge.svg)](https://codecov.io/gh/material-motion/material-motion-swift)
[![CocoaPods Compatible](https://img.shields.io/cocoapods/v/MaterialMotion.svg)](https://cocoapods.org/pods/MaterialMotion)
[![Platform](https://img.shields.io/cocoapods/p/MaterialMotion.svg)](http://cocoadocs.org/docsets/MaterialMotion)
[![Docs](https://img.shields.io/cocoapods/metrics/doc-percent/MaterialMotion.svg)](http://cocoadocs.org/docsets/MaterialMotion)

This library includes a variety of ready-to-use **interactions**. Interactions are registered to an
instance of `MotionRuntime`:

```swift
// Store me for as long as the interactions should take effect.
let runtime = MotionRuntime(containerView: <#view#>)
```

<table>
<thead><tr><th></th><th>Interaction</th><th>Snippet</th></tr></thead>
<tbody>
<tr>
<td align="center"><img src="assets/arcmove.gif" /></td>
<td><pre><code class="language-swift">ArcMove</code></pre></td>
<td><pre><code class="language-swift">let arcMove = ArcMove()
arcMove.from.value = <#from#>
arcMove.to.value = <#to#>
runtime.add(arcMove, to: <#view#>)</code></pre></td>
</tr>
<tr>
<td align="center"><img src="assets/directlymanipulable.gif" /></td>
<td><pre><code class="language-swift">DirectlyManipulable</code></pre></td>
<td><pre><code class="language-swift">runtime.add(DirectlyManipulable(), to: <#view#>)</code></pre></td>
</tr>
<tr>
<td align="center"><img src="assets/draggable.gif" /></td>
<td><pre><code class="language-swift">Draggable</code></pre></td>
<td><pre><code class="language-swift">runtime.add(Draggable(), to: <#view#>)</code></pre></td>
</tr>
<tr>
<td align="center"><img src="assets/rotatable.gif" /></td>
<td><pre><code class="language-swift">Rotatable</code></pre></td>
<td><pre><code class="language-swift">runtime.add(Rotatable(), to: <#view#>)</code></pre></td>
</tr>
<tr>
<td align="center"><img src="assets/scalable.gif" /></td>
<td><pre><code class="language-swift">Scalable</code></pre></td>
<td><pre><code class="language-swift">runtime.add(Scalable(), to: <#view#>)</code></pre></td>
</tr>
<tr>
<td align="center"><img src="assets/setpositionontap.gif" /></td>
<td><pre><code class="language-swift">SetPositionOnTap</code></pre></td>
<td><pre><code class="language-swift">runtime.add(SetPositionOnTap(),
to: runtime.get(<#view#>.layer).position)</code></pre></td>
</tr>
<tr>
<td align="center"><img src="assets/spring.gif" /></td>
<td><pre><code class="language-swift">Spring</code></pre></td>
<td><pre><code class="language-swift">let spring = Spring()
spring.destination.value = <#initial destination#>
runtime.add(spring, to: <#view#>)</code></pre></td>
</tr>
<tr>
<td align="center"><img src="assets/tossable.gif" /></td>
<td><pre><code class="language-swift">Tossable</code></pre></td>
<td><pre><code class="language-swift">let tossable = Tossable()
tossable.spring.destination.value = <#initial destination#>
runtime.add(tossable, to: <#view#>)</code></pre></td>
</tr>
<tr>
<td align="center"><img src="assets/tween.gif" /></td>
<td><pre><code class="language-swift">Tween</code></pre></td>
<td><pre><code class="language-swift">runtime.add(Tween(duration: 0.5, values: [1, 0]),
to: runtime.get(<#view#>.layer).opacity)</code></pre></td>
</tr>
</tbody>
</table>

## Installation

Expand All @@ -17,9 +89,9 @@
>
> gem install cocoapods
Add `MaterialMotionStreams` to your `Podfile`:
Add `MaterialMotion` to your `Podfile`:

pod 'MaterialMotionStreams'
pod 'MaterialMotion'

Then run the following command:

Expand All @@ -29,7 +101,7 @@ Then run the following command:

Import the framework:

@import MaterialMotionStreams;
import MaterialMotion

You will now have access to all of the APIs.

Expand All @@ -38,25 +110,80 @@ You will now have access to all of the APIs.
Check out a local copy of the repo to access the Catalog application by running the following
commands:

git clone https://github.com/material-motion/streams-swift.git
cd streams-swift
git clone https://github.com/material-motion/material-motion-swift.git
cd material-motion-swift
pod install
open MaterialMotionStreams.xcworkspace
open MaterialMotion.xcworkspace

## Case studies

### Carousel

<img src="assets/carousel.gif" />

A carousel with pages that scale in and fade out in reaction to their scroll position.

[View the source](examples/CarouselExample.swift).

### Contextual transition

<img src="assets/contextualtransition.gif" />

A contextual view can be used to create continuity during transitions between view controllers. In
this case study the selected photo is the contextual view. It's possible to flick the view to
dismiss it using the tossable interaction.

Makes use of: `Draggable`, `Tossable`, `Transition`, `TransitionSpring`, `Tween`.

[View the source](examples/ContextualTransitionExample.swift).

### Floating action button transition

<img src="assets/fabtransition.gif" />

A floating action button transition is a type of contextual transition that animates a mask outward
from a floating button.

Makes use of: `Transition` and `Tween`.

[View the source](examples/FabTransitionExample.swift).

### Material expansion

<img src="assets/materialexpansion.gif" />

A Material Design transition using assymetric transformations.

Makes use of: `Tween`.

[View the source](examples/MaterialExpansionExample.swift).

### Modal dialog

<img src="assets/modaldialog.gif" />

A modal dialog that's presented over the existing context and is dismissable using gestures.

Makes use of: `Tossable` and `TransitionSpring`.

[View the source](examples/ModalDialogExample.swift).

### Sticker picker

## Guides
<img src="assets/stickerpicker.gif" />

1. [Architecture](#architecture)
2. [How to ...](#how-to-...)
Each sticker is individually **directly manipulable**, meaning they can be dragged, rotated, and
scaled using multitouch gestures.

### Architecture
Makes use of: `DirectlyManipulable`.

### How to ...
[View the source](examples/StickerPickerExample.swift).

## Contributing

We welcome contributions!

Check out our [upcoming milestones](https://github.com/material-motion/streams-swift/milestones).
Check out our [upcoming milestones](https://github.com/material-motion/material-motion-swift/milestones).

Learn more about [our team](https://material-motion.github.io/material-motion/team/),
[our community](https://material-motion.github.io/material-motion/team/community/), and
Expand Down
Binary file added assets/arcmove.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/carousel.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/contextualtransition.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/directlymanipulable.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/draggable.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/fabtransition.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/materialexpansion.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/modaldialog.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/rotatable.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/scalable.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/setpositionontap.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/spring.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/stickerpicker.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/tossable.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/tween.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 65580d6

Please sign in to comment.