-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Conflicts: .gitignore CONTRIBUTING.mdown README.mdown _posts/docs/2010-12-01-introduction.md _posts/docs/2010-12-03-options.md _posts/docs/2010-12-04-methods.md _posts/docs/2010-12-05-layout-modes.md _posts/docs/2010-12-06-filtering.md _posts/docs/2010-12-07-sorting.md _posts/docs/2010-12-09-animating.md _posts/docs/2010-12-10-adding-items.md _posts/docs/2011-05-25-extending-isotope.md _posts/docs/2011-06-16-hash-history-jquery-bbq.md _posts/docs/2011-12-11-help.md _posts/docs/2011-12-20-license.md jquery.isotope.js jquery.isotope.min.js minify.sh
- Loading branch information
Showing
104 changed files
with
7,902 additions
and
5,623 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,4 +1,5 @@ | ||
_site | ||
isotope-site.zip | ||
components/ | ||
bower_components/ | ||
node_modules/ |
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 @@ | ||
{ | ||
"browser": true, | ||
"devel": false, | ||
"strict": true, | ||
"undef": true, | ||
"unused": true, | ||
"predef": { | ||
"define": false | ||
} | ||
} |
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,3 +1,3 @@ | ||
softTabs = true | ||
tabSize = 2 | ||
excludeInFileChooser = "{$exclude,_site/*}" | ||
excludeInFileChooser = "{$exclude,_site/*,bower_components,node_modules}" |
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,15 +1,24 @@ | ||
## Submitting issues | ||
|
||
### Read the Help page | ||
### Reduced test case required | ||
|
||
[The Help page in the docs](http://isotope.metafizzy.co/docs/help.html) covers most issues. Please look it over first before submitting an issue. | ||
All bug reports and problem issues require a [**reduced test case**](http://css-tricks.com/reduced-test-cases/). Create one by forking any one of the [CodePen examples](http://codepen.io/desandro/tag/isotope-docs) from [the docs](http://isotope.metafizzy.co). | ||
|
||
### Provide an isolated example with a live URL | ||
+ A reduced test case clearly demonstrates the bug or issue. | ||
+ It contains the bare minimum HTML, CSS, and JavaScript required to demonstrate the bug. | ||
+ A link to your production site is **not** a reduced test case. | ||
|
||
**A live URL is required** for any bug report or personal support request. Try re-creating the issue in jsFiddle using this template: | ||
Providing a reduced test case is the best way to get your issue addressed. Without a reduced test case, your issue may be closed. | ||
|
||
+ [jsFiddle jQuery Isotope template](http://jsfiddle.net/desandro/DQydj/) | ||
## Support | ||
|
||
### Look over the Issues Agreement | ||
+ Having trouble setting up Isotope? | ||
+ Running into a time-consuming problem? | ||
|
||
I wrote an [Issues Agreement](https://github.com/desandro/issues-agreement/#readme) that covers how to submit a good issue. | ||
[CodersClan has a dedicated support forum for Isotope](https://www.codersclan.net/?repo_id=1), where you can get personal support from experienced developers. | ||
|
||
#### [Get support on CodersClan](https://www.codersclan.net/?repo_id=1) | ||
|
||
## Pull requests | ||
|
||
Contributions are welcome! Please note: your code may be used as part of a commercial product if merged. Be clear about what license applies to your patch. [The MIT license](http://choosealicense.com/licenses/mit/) or [public domain unlicense](http://choosealicense.com/licenses/unlicense/) are permissive, and allow integration of your patch into Isotope as part of a commercial product. |
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,87 @@ | ||
/*jshint node: true, strict: false */ | ||
|
||
// -------------------------- grunt -------------------------- // | ||
|
||
module.exports = function( grunt ) { | ||
|
||
var banner = ( function() { | ||
var src = grunt.file.read('js/isotope.js'); | ||
var re = new RegExp('^\\s*(?:\\/\\*[\\s\\S]*?\\*\\/)\\s*'); | ||
var matches = src.match( re ); | ||
var banner = matches[0].replace( 'Isotope', 'Isotope PACKAGED' ); | ||
return banner; | ||
})(); | ||
|
||
grunt.initConfig({ | ||
// ----- global settings ----- // | ||
namespace: 'isotope', | ||
dataDir: 'tasks/data', | ||
|
||
// ----- tasks settings ----- // | ||
|
||
jshint: { | ||
docs: [ 'js/**/*.js' ], | ||
options: grunt.file.readJSON('.jshintrc') | ||
}, | ||
|
||
requirejs: { | ||
pkgd: { | ||
options: { | ||
baseUrl: 'bower_components', | ||
include: [ | ||
'jquery-bridget/jquery.bridget', | ||
'isotope/js/isotope' | ||
], | ||
out: 'dist/isotope.pkgd.js', | ||
optimize: 'none', | ||
paths: { | ||
isotope: '../', | ||
jquery: 'empty:' | ||
}, | ||
wrap: { | ||
start: banner | ||
} | ||
} | ||
} | ||
}, | ||
|
||
uglify: { | ||
pkgd: { | ||
files: { | ||
'dist/isotope.pkgd.min.js': [ 'dist/isotope.pkgd.js' ] | ||
}, | ||
options: { | ||
banner: banner | ||
} | ||
} | ||
} | ||
|
||
}); | ||
|
||
grunt.loadNpmTasks('grunt-contrib-jshint'); | ||
grunt.loadNpmTasks('grunt-contrib-uglify'); | ||
grunt.loadNpmTasks('grunt-requirejs'); | ||
|
||
grunt.registerTask( 'pkgd-edit', function() { | ||
var outFile = grunt.config.get('requirejs.pkgd.options.out'); | ||
var contents = grunt.file.read( outFile ); | ||
// get requireJS definition code | ||
var definitionRE = /define\(\s*'isotope\/js\/isotope'(.|\n)+isotopeDefinition\s*\)/; | ||
var definition = contents.match( definitionRE )[0]; | ||
// remove name module | ||
var fixDefinition = definition.replace( "'isotope/js/isotope',", '' ) | ||
// ./item -> isotope/js/item | ||
.replace( /'.\//g, "'isotope/js/" ); | ||
contents = contents.replace( definition, fixDefinition ); | ||
grunt.file.write( outFile, contents ); | ||
grunt.log.writeln( 'Edited ' + outFile ); | ||
}); | ||
|
||
grunt.registerTask( 'default', [ | ||
'jshint', | ||
'requirejs', | ||
'pkgd-edit', | ||
'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 |
---|---|---|
@@ -1,64 +1,77 @@ | ||
Isotope | ||
======== | ||
# Isotope | ||
|
||
**An exquisite jQuery plugin for magical layouts. Enables filtering, sorting, and dynamic layouts.** | ||
_Filter & sort magical layouts_ | ||
|
||
This package has all the documentation and demos to get you started. | ||
See [isotopejs.com](http://isotopejs.com) for complete docs and demos. | ||
|
||
View this project live at [http://isotope.metafizzy.co](http://isotope.metafizzy.co). | ||
## Install | ||
|
||
## Licensing | ||
A packaged source file includes everything you need to use Isotope. | ||
|
||
Isotope may be used in commercial projects and applications with the one-time purchase of a commercial license. If you are paid to do your job, and part of your job is implementing Isotope, a commercial license is required. | ||
+ [isotope.pkgd.js](http://isotope.metafizzy.co/beta/isotope.pkgd.js) | ||
+ [isotope.pkgd.min.js](http://isotope.metafizzy.co/beta/isotope.pkgd.min.js) | ||
|
||
http://isotope.metafizzy.co/docs/license.html | ||
### Bower | ||
|
||
For non-commercial, personal, or open source projects and applications, you may use Isotope under the terms of the MIT License. You may use Isotope for free. | ||
If you are cool with the command line, install Isotope as a [Bower](http://bower.io) package: | ||
|
||
## Support | ||
``` bash | ||
bower install isotope | ||
``` | ||
|
||
Need help with getting Isotope up and running? Got a time-consuming problem you want to get solved quickly? Get [Isotope support on CodersClan](http://codersclan.net/?repo_id=1). | ||
## License | ||
|
||
<p><a href="http://codersclan.net/?repo_id=1"><img src="http://www.codersclan.net/gs_button/?repo_id=1" width="200" /></a></p> | ||
Isotope may be used in commercial projects and applications with the one-time purchase of a commercial license. If you are paid to do your job, and part of your job is implementing Isotope, a commercial license is required. | ||
|
||
## Viewing this project locally | ||
http://isotope.metafizzy.co/license.html | ||
|
||
### Via download | ||
For non-commercial, personal, or open source projects and applications, you may use Isotope under the terms of the [GPL v3 License](http://choosealicense.com/licenses/gpl-v3/). You may use Isotope for free. | ||
|
||
You can download a zip of all the flat HTML files from [http://meta.metafizzy.co/files/isotope-site.zip](http://meta.metafizzy.co/files/isotope-site.zip). | ||
## Initialize | ||
|
||
### Via Jekyll | ||
### In JavaScript | ||
|
||
The documentation and demo pages are generated using [Jekyll](http://github.com/mojombo/jekyll/wiki). With Jekyll installed, you can clone this repo and run Jekyll from Terminal: | ||
``` js | ||
// jQuery | ||
$('#container').isotope({ | ||
// options... | ||
itemSelector: '.item', | ||
masonry: { | ||
columnWidth: 200 | ||
} | ||
}); | ||
``` | ||
|
||
``` bash | ||
git clone https://github.com/desandro/isotope.git | ||
cd isotope/ | ||
jekyll --server --auto | ||
``` js | ||
// vanilla JS | ||
var container = document.querySelector('#container'); | ||
var iso = new Isotope( container, { | ||
// options... | ||
itemSelector: '.item', | ||
masonry: { | ||
columnWidth: 200 | ||
} | ||
}); | ||
``` | ||
|
||
Then view the live site at [http://localhost:4000](http://localhost:4000). | ||
### In HTML | ||
|
||
Add a class of `js-isotope` to your element. Options can be set in JSON in `data-isotope-options`. | ||
|
||
## Changelog | ||
``` html | ||
<div class="js-isotope" data-isotope-options='{ "itemSelector": ".item", "masonry": { "columnWidth": 200 } }'> | ||
<div class="item"></div> | ||
<div class="item"></div> | ||
... | ||
</div> | ||
``` | ||
|
||
## Support | ||
|
||
View the [commit history](https://github.com/desandro/isotope/commits/master/jquery.isotope.js) for a complete robust list of changes to the script. | ||
[CodersClan has a dedicated support forum for Isotope](https://www.codersclan.net/?repo_id=1), where you can get personal support from experienced developers. | ||
|
||
+ **v1.5** | ||
[2011-10-19](https://github.com/desandro/isotope/commit/2c789ecb5ec#jquery.isotope.js) | ||
- add proper callback support that trigger after animation/transition | ||
+ **v1.4** [2011-06-29](https://github.com/desandro/isotope/commit/8e2f51612eaf20e3031b81b8c5ff5e322cbb7b4f#jquery.isotope.js) | ||
- shuffle method added | ||
- inserting and appending positions items then reveals them | ||
+ **v1.3** [2011-05-23](https://github.com/desandro/isotope/commit/a7cc0be2a0038c13a2955a889a873f63a39eb6c2#jquery.isotope.js) | ||
- refactor layout mode API | ||
- layoutModeResize -> layoutModeResizeChanged, which returns boolean | ||
+ **v1.2** [2011-05-13](https://github.com/desandro/isotope/commit/b3cf6139d7641f282724a7a541b3bfb10d1bbf54#jquery.isotope.js) | ||
- add updateOption method, for changing options after initialization | ||
+ **v1.1** [2011-04-26](https://github.com/desandro/isotope/commit/3c551406ee1e4cd8345cdbe589c2d8d1e164b259#jquery.isotope.js) | ||
- incremental additions, bug fixes, and refactorings | ||
+ **v1.0** [2011-02-07](https://github.com/desandro/isotope/commit/78253dfb34808d9a677ae721e97c5afc08aa19b8#jquery.isotope.js) | ||
- public release | ||
#### [Get support on CodersClan](https://www.codersclan.net/?repo_id=1) | ||
|
||
* * * | ||
|
||
Copyright (c) 2011-2014 David DeSandro / Metafizzy LLC | ||
By [Metafizzy](http://metafizzy.co) |
Oops, something went wrong.