All Projects → spite → Storyline.js

spite / Storyline.js

Licence: mit
Storyline - generic sequencer for JavaScript projects

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Storyline.js

Stevia
🍃 Concise Autolayout code
Stars: ✭ 3,182 (+4445.71%)
Mutual labels:  storyboard
Sidemenu
An interactive iOS side menu with rich features.
Stars: ✭ 442 (+531.43%)
Mutual labels:  storyboard
Iblinter
A linter tool for Interface Builder
Stars: ✭ 915 (+1207.14%)
Mutual labels:  storyboard
Ambtableviewcontroller
Storyboard and Prototype Cells-centric block-based UITableView controller to manage complex layouts.
Stars: ✭ 372 (+431.43%)
Mutual labels:  storyboard
Mylinearlayout
MyLayout is a powerful iOS UI framework implemented by Objective-C. It integrates the functions with Android Layout,iOS AutoLayout,SizeClass, HTML CSS float and flexbox and bootstrap. So you can use LinearLayout,RelativeLayout,FrameLayout,TableLayout,FlowLayout,FloatLayout,PathLayout,GridLayout,LayoutSizeClass to build your App 自动布局 UIView UITab…
Stars: ✭ 4,152 (+5831.43%)
Mutual labels:  storyboard
Kydrawercontroller
Side Drawer Navigation Controller similar to Android
Stars: ✭ 632 (+802.86%)
Mutual labels:  storyboard
RSCustomTabbarController
This is super flexible Custom tab bar controller implementation. You have the complete opportunity to customise according to your necessity ( ## Also support swift ## )
Stars: ✭ 35 (-50%)
Mutual labels:  storyboard
Keyboardhidemanager
Codeless manager to hide keyboard by tapping on views for iOS written in Swift
Stars: ✭ 57 (-18.57%)
Mutual labels:  storyboard
Uitextfield Navigation
🏄‍♂️ UITextField-Navigation makes it easier to navigate between UITextFields and UITextViews
Stars: ✭ 436 (+522.86%)
Mutual labels:  storyboard
Cyltabbarcontroller
[EN]It is an iOS UI module library for adding animation to iOS tabbar items and icons with Lottie, and adding a bigger center UITabBar Item. [CN]【中国特色 TabBar】一行代码实现 Lottie 动画TabBar,支持中间带+号的TabBar样式,自带红点角标,支持动态刷新。【iOS13 & Dark Mode & iPhone XS MAX supported】
Stars: ✭ 6,605 (+9335.71%)
Mutual labels:  storyboard
Autoinch
优雅的iPhone全尺寸/等比例精准适配工具
Stars: ✭ 395 (+464.29%)
Mutual labels:  storyboard
Cards
Awesome iOS 11 appstore cards in swift 5.
Stars: ✭ 4,017 (+5638.57%)
Mutual labels:  storyboard
Pmsuperbutton
🔥 PMSuperButton is a powerful UIButton coming from the countryside, but with super powers! 😎
Stars: ✭ 653 (+832.86%)
Mutual labels:  storyboard
Swiftymenu
Simple and Elegant Drop down menu for iOS 🔥💥
Stars: ✭ 356 (+408.57%)
Mutual labels:  storyboard
Tangramkit
TangramKit is a powerful iOS UI framework implemented by Swift. It integrates the functions with Android layout,iOS AutoLayout,SizeClass, HTML CSS float and flexbox and bootstrap. So you can use LinearLayout,RelativeLayout,FrameLayout,TableLayout,FlowLayout,FloatLayout,LayoutSizeClass to build your App 自动布局 UIView UITableView UICollectionView
Stars: ✭ 984 (+1305.71%)
Mutual labels:  storyboard
Wtrequestcenter
WTKit is my Code accumulation
Stars: ✭ 293 (+318.57%)
Mutual labels:  storyboard
Sidemenu
Simple side/slide menu control for iOS, no code necessary! Lots of customization. Add it to your project in 5 minutes or less.
Stars: ✭ 5,267 (+7424.29%)
Mutual labels:  storyboard
Capsuleview
An easy to use drop-in view to create a beautiful card style effect with a title placeholder and body content.
Stars: ✭ 68 (-2.86%)
Mutual labels:  storyboard
Bartycrouch
Localization/I18n: Incrementally update/translate your Strings files from .swift, .h, .m(m), .storyboard or .xib files.
Stars: ✭ 1,032 (+1374.29%)
Mutual labels:  storyboard
Forceblur
ForceBlur Animation for iOS Messaging Apps
Stars: ✭ 666 (+851.43%)
Mutual labels:  storyboard

Storyline.js - Multi-purpose sequencer

Storyline.js is a library to help define a storyboard using natural language.

This is the refined and polished version of the sytem created for BEYOND and cru·ci·form.

Check out the example to see it in action: Storyline.js with CSS 2D transforms.

IMAGE ALT TEXT HERE

Using Storyline.js

There's two parts: Storyline.js is the parser and player, and then a storyboard source object that defines the story. A storyline source has this format:

{
    "value1": [
        "0 cut to 10",
        "2 linear to 3"
    ],
    
    "value2": [
        "0 cut to 0",
        "4 ease to 1",
        "6 ease to 0"
    ]
}

This source object is a map of keys (each key is a value that you will be using in your code x, angle, power, etc.), and each key contains an array of entries. Each entry defines a point in time, and a storyline action, and has the following syntax:

{time in seconds} {action to perform} {value of action}

The actions are:

  • cut to instanteously changes to {value}
  • linear to will linearly interpolate from the last defined value to {value}
  • ease to will ease in-out from the last defined value to {value}

Minimal example

Include Storyline.js

<script src="Storyline.js"></script>

Create a storyline from a structured storyboard source. By calling storyline.get you can get the updated value:

var storyline = STORYLINE.parseStoryline( {

    "value1": [
        "0 cut to 0",
        "5 ease to 1",
        "10 ease to 0"
    ]
    
} );

function update() {
    
    requestAnimationFrame( update );
    console.log( storyline.get( 'value1', ( Date.now() / 1000 ) % 10 ) );
    
}

update();

External storyboard example

Simply export the storyline into its own file, and include it like a normal script.

var storyline = STORYLINE.parseStoryline( {

    "value1": [
        "0 cut to 0",
        "5 ease to 1",
        "10 ease to 0"
    ]
    
} );

Or load the content with AJAX and parse it when it's loaded:

var oReq = new XMLHttpRequest();
oReq.onload = function() {
	storyline = STORYLINE.parseStoryline( this.responseText );
	/* ready to use */
};
oReq.open( 'get', 'storyboard.json', true);
oReq.send();

Status

This is the first release. Next steps are to add syntax to control the easing functions, probably something like:

{time} ease to {value} { [ set of easing control points] }

Also, support specific functions to simplify animations:

{time} {wiggle|shake} {extent}

As always: forks, pull requests and code critiques are welcome!

License

MIT licensed

Copyright (C) 2015 Jaume Sanchez Elias, http://www.clicktorelease.com

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].