Skip to content

Commit

Permalink
Split preview gif, update readme (jjochen#120)
Browse files Browse the repository at this point in the history
  • Loading branch information
jjochen authored Jan 17, 2018
1 parent a715abb commit 64ff69e
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 9 deletions.
Binary file modified Images/JJFloatingActionButton.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 Images/JJFloatingActionButtonBasics.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 Images/JJFloatingActionButtonCircularPop.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 Images/JJFloatingActionButtonConfiguration.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 Images/JJFloatingActionButtonSingleItem.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 7 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,10 @@ Floating Action Button for iOS
## <a name="preview"></a>Preview

<p align="center">
<img src="https://github.com/jjochen/JJFloatingActionButton/raw/master/Images/JJFloatingActionButton.gif" width='250' alt="Preview">
<img src="https://github.com/jjochen/JJFloatingActionButton/raw/master/Images/JJFloatingActionButtonBasics.gif" width='250' alt="Preview Basics">
<img src="https://github.com/jjochen/JJFloatingActionButton/raw/master/Images/JJFloatingActionButtonConfiguration.gif" width='250' alt="Preview Configuration">
<img src="https://github.com/jjochen/JJFloatingActionButton/raw/master/Images/JJFloatingActionButtonCircularPop.gif" width='250' alt="Preview Circular Pop">
<img src="https://github.com/jjochen/JJFloatingActionButton/raw/master/Images/JJFloatingActionButtonSingleItem.gif" width='250' alt="Preview Single Item">
</p>


Expand Down Expand Up @@ -99,16 +102,12 @@ Button appearance and behavior can be customized:
```swift
var buttonColor: UIColor
var defaultButtonImage: UIImage?
var openButtonImage: UIImage?
var buttonImageColor: UIColor
var shadowColor: UIColor
var shadowOffset: CGSize
var shadowOpacity: Float
var shadowRadius: CGFloat

var interItemSpacing: CGFloat
var rotationAngle: CGFloat

var itemTitleFont: UIFont
var itemButtonColor: UIColor
var itemImageColor: UIColor
Expand All @@ -118,6 +117,9 @@ var itemShadowOffset: CGSize
var itemShadowOpacity: Float
var itemShadowRadius: CGFloat
var itemSizeRatio: CGFloat

var buttonOpeningStyle: ButtonOpeningStyle
var itemOpeningStyle: ItemOpeningStyle
```

### Delegate
Expand Down
13 changes: 9 additions & 4 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -128,19 +128,24 @@ begin

#-- Record Video -----------------------------------------------------------#

desc 'Record video booted simulator and convert to gif'
desc 'Record video of booted simulator and convert to gif'
task :record_gif do
Rake::Task[:record_gif_with_name].invoke 'JJFloatingActionButton'
end

desc 'Record video of booted simulator and convert to gif with given name'
task :record_gif_with_name, :name do |task, args|
title 'Recording video'
check_executable('ffmpeg')

mov_path='./Images/JJFloatingActionButton.mov'
mov_path="./Images/#{args.name}.mov"

trap('SIGINT') { puts }
%x{xcrun simctl io booted recordVideo #{mov_path}}

title 'Convert to gif'
title 'Converting to gif'

gif_path='./Images/JJFloatingActionButton.gif'
gif_path="./Images/#{args.name}.gif"
palette_path='./Images/palette.png'
filters='fps=30,setpts=1*PTS,scale=250:-1:flags=lanczos'

Expand Down

0 comments on commit 64ff69e

Please sign in to comment.