-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop'. This is now the Velocity V2 beta branch
- Loading branch information
Showing
153 changed files
with
24,433 additions
and
35,344 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
/nbproject | ||
/node_modules | ||
/build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,46 +1,5 @@ | ||
module.exports = function(grunt) { | ||
"use strict"; | ||
|
||
grunt.initConfig({ | ||
pkg: grunt.file.readJSON('package.json'), | ||
jshint: { | ||
files: ['velocity.js', 'velocity.ui.js'], | ||
options: { | ||
browser: true, | ||
curly: true, | ||
eqeqeq: true, | ||
eqnull: true, | ||
esversion: 3, // Velocity 1.* | ||
forin: false, // Should really be true | ||
freeze: true, | ||
funcscope: true, | ||
futurehostile: true, | ||
laxbreak: true, // Makes it very hard to write readable code in some places without this option | ||
loopfunc: true, // Velocity 1.* | ||
nocomma: true, | ||
nonbsp: true, | ||
notypeof: true, | ||
strict: true, | ||
globals: { | ||
jQuery: true | ||
} | ||
} | ||
}, | ||
uglify: { | ||
my_target: { | ||
options: { | ||
preserveComments: /^!/, | ||
screwIE8: false // Velocity 1.* | ||
}, | ||
files: { | ||
'velocity.min.js': ['velocity.js'], | ||
'velocity.ui.min.js': ['velocity.ui.js'] | ||
} | ||
} | ||
} | ||
}); | ||
|
||
grunt.loadNpmTasks('grunt-contrib-jshint'); | ||
grunt.loadNpmTasks('grunt-contrib-uglify'); | ||
|
||
grunt.registerTask('default', ['jshint', 'uglify']); | ||
require("load-grunt-tasks")(grunt); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
# Velocity 1.5.1 | ||
# Velocity 2.0.0 beta | ||
|
||
# This is a public beta - files are *not* available on CDN | ||
|
||
## Docs | ||
[http://VelocityJS.org](http://velocityjs.org) | ||
[https://github.com/julianshapiro/velocity/wiki](https://github.com/julianshapiro/velocity/wiki) | ||
|
||
## News | ||
WhatsApp, Tumblr, Windows, Samsung, Uber, and thousands of other companies rely on Velocity. Visit [Libscore.com](http://libscore.com/#$.Velocity) to see which sites use Velocity on their homepage. | ||
|
@@ -14,17 +16,17 @@ NPM: https://www.npmjs.com/package/velocity-react | |
## Quickstart | ||
### Velocity (CDN, choose one of them): | ||
```html | ||
<script src="//cdn.jsdelivr.net/npm/velocity[email protected]/velocity.min.js"></script> | ||
<script src="//cdnjs.cloudflare.com/ajax/libs/velocity/1.5.1/velocity.min.js"></script> | ||
<script src="//cdn.jsdelivr.net/velocity/2.0/velocity.min.js"></script> | ||
<script src="//cdnjs.cloudflare.com/ajax/libs/velocity/2.0.0/velocity.min.js"></script> | ||
``` | ||
|
||
### Velocity UI pack (CDN, choose one of them): | ||
```html | ||
<script src="//cdn.jsdelivr.net/npm/velocity[email protected]/velocity.ui.min.js"></script> | ||
<script src="//cdnjs.cloudflare.com/ajax/libs/velocity/1.5.1/velocity.ui.min.js"></script> | ||
<script src="//cdn.jsdelivr.net/velocity/2.0/velocity.ui.min.js"></script> | ||
<script src="//cdnjs.cloudflare.com/ajax/libs/velocity/2.0.0/velocity.ui.min.js"></script> | ||
``` | ||
|
||
> Please note that JSDelivr will automatically supply the latest release, while CloudFlare needs to ask for a specific version. | ||
> Please note that JSDelivr can automatically supply the latest release, while CloudFlare needs to ask for a specific version. | ||
### Package managers: | ||
_npm:_ `npm install velocity-animate`<br> | ||
|
@@ -34,6 +36,7 @@ _bower:_ `bower install velocity` | |
Ask on [StackOverflow](http://stackoverflow.com/tags/velocity.js) (make sure you add the `[velocity.js]` and `[javascript]` tags). | ||
|
||
## Updates | ||
- **[2.0](https://github.com/julianshapiro/velocity/compare/1.5.0...2.0.0)**: Typescript update and complete refactoring. | ||
- **[1.5](https://github.com/julianshapiro/velocity/compare/1.4.0...1.5.0)**: Bugfixes, IE9 compatibility fixes. | ||
- **[1.4](https://github.com/julianshapiro/velocity/compare/1.3.0...1.4.0)**: Pause / Resume (per element or global).<br> | ||
Forcefed string animation (just have matching number spaces) including unit conversions and colour names (ie `background:["rgba(red,0.1)", "blue"]`). | ||
|
@@ -57,6 +60,6 @@ Various fixes including ticker (loading Velocity in a background window) and col | |
|
||
==== | ||
|
||
[MIT License](LICENSE.md). © Julian Shapiro (http://twitter.com/shapiro).<br> | ||
[Stripe](https://stripe.com/blog/stripe-open-source-retreat) sponsors Velocity's development.<br> | ||
[BrowserStack](http://www.browserstack.com/) provides testing services. | ||
[MIT License](LICENSE.md). © Julian Shapiro (http://twitter.com/shapiro). | ||
|
||
[![Kiss My Button](https://presskit.kissmybutton.gr/logos/kissmybutton-logo-small.png)](https://kissmybutton.gr) sponsors Velocity's development. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# Major Changes in Velocity V2 | ||
|
||
* Transforms - Use these directly within CSS, don't try the old shortcuts as they don't exist. | ||
* Colors - All web colors are supported internally. | ||
* SVG - All SVG attributes are supported internally, though they must be placed on the correct type of element. | ||
* Loop - This no longer copies the animation call, it calls it multiple times. | ||
* Repeat - This is almost identical to loop, but only runs one way. | ||
* Chaining - Chaining is awesome, use it. Chained commands are designed to operate on the chained animation, not on the elements within it. | ||
* Styles - Use `element.velocity("style", "propertyName"[, value])`, the old .Hook has gone. | ||
* Per-element - Animations are now copied per-element, and not one a one-animation-per-array basis as in other libraries (and old Velocity v1). | ||
* Sync - You can now de-sync animations so they start immediately per-element, rather than waiting for all to be ready. | ||
* Speed - You can control the speed of the animation playback. | ||
* Delay - You can pass a negative number to start inside the animation rather than just having a delay before it. | ||
* There are APIs for extending Velocity - see the various register* commands. | ||
* Display - This is a property, no longer an option. | ||
* Visibility - This is a property, no longer an option. | ||
|
||
# Currently disabled / not updated: | ||
|
||
* UI-Pack | ||
* Reverse | ||
* Scroll (working, but not happy with interface - it's a property if people want to play, alias of scrollTop, there's also scrollLeft) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
module.exports = function(grunt) { | ||
grunt.registerTask("default", [ | ||
"ts", | ||
"uglify" | ||
]); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
module.exports = function(grunt) { | ||
grunt.registerTask("patch", [ | ||
"bump-only:patch", | ||
"default", | ||
"bump-commit" | ||
]); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
module.exports = function(grunt) { | ||
grunt.registerTask("patch", [ | ||
"bump-only:patch", | ||
"default", | ||
"bump-commit" | ||
]); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
module.exports = function(grunt) { | ||
grunt.registerTask("patch", [ | ||
"bump-only:patch", | ||
"default", | ||
"bump-commit" | ||
]); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
module.exports = { | ||
main: { | ||
options: { | ||
updateConfigs: ["pkg"], | ||
commitFiles: ["package.json"], | ||
pushTo: "origin" | ||
} | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
module.exports = function(grunt) { | ||
return grunt.file.readJSON("package.json"); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
module.exports = { | ||
options: { | ||
"fast": "never" | ||
}, | ||
main: { | ||
"tsconfig": true, | ||
"files": { | ||
"build/velocity.js": ["src/app.ts"] | ||
} | ||
}, | ||
test: { | ||
"tsconfig": "test/tsconfig.json", | ||
"files": { | ||
"test/test.js": ["test/src/app.ts"] | ||
} | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
module.exports = { | ||
main: { | ||
options: { | ||
sourceMap: { | ||
root: "src/", | ||
includeSources: true | ||
}, | ||
sourceMapIn: "build/velocity.js.map", | ||
compress: false, | ||
mangle: false, | ||
beautify: true, | ||
output: { | ||
comments: "all" | ||
}, | ||
banner: `/*! VelocityJS.org (<%= pkg.version %>) (C) 2014 Julian Shapiro. MIT @license: en.wikipedia.org/wiki/MIT_License */ | ||
(function(root, factory) { | ||
if (typeof define === 'function' && define.amd) { | ||
define('Velocity', [], function() { | ||
return (root['Velocity'] = factory()); | ||
}); | ||
} else if (typeof module === 'object' && module.exports) { | ||
module.exports = factory(); | ||
} else { | ||
root['Velocity'] = factory(); | ||
} | ||
}(this, function() { | ||
`, | ||
footer: ` | ||
return VelocityFn; | ||
})); | ||
` | ||
}, | ||
files: { | ||
"velocity.js": ["build/velocity.js"] | ||
} | ||
}, | ||
min: { | ||
options: { | ||
sourceMap: false, | ||
banner: `/*! <%= pkg.name %> v<%= pkg.version %> (<%= grunt.template.today('dddd dS mmmm yyyy, h:MM:ss TT') %>) */`, | ||
compress: { | ||
drop_console: true, | ||
drop_debugger: true, | ||
pure_getters: true, | ||
unsafe: true | ||
} | ||
}, | ||
files: { | ||
"velocity.min.js": ["velocity.js"], | ||
"velocity.ui.min.js": ["velocity.ui.js"] | ||
} | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
module.exports = { | ||
main: { | ||
files: ["index.d.ts", "src/**/*.ts"], | ||
tasks: ["default"] | ||
}, | ||
test: { | ||
files: ["test/src/**/*.ts"], | ||
tasks: ["ts:test"] | ||
} | ||
}; |
Oops, something went wrong.