├── .gitignore ├── .idea ├── modules.xml ├── p2.iml ├── vcs.xml └── workspace.xml ├── README.md ├── bower.json ├── bower_components ├── jquery │ ├── .bower.json │ ├── AUTHORS.txt │ ├── LICENSE.txt │ ├── README.md │ ├── bower.json │ ├── dist │ │ ├── core.js │ │ ├── jquery.js │ │ ├── jquery.min.js │ │ ├── jquery.min.map │ │ ├── jquery.slim.js │ │ ├── jquery.slim.min.js │ │ └── jquery.slim.min.map │ ├── external │ │ └── sizzle │ │ │ ├── LICENSE.txt │ │ │ └── dist │ │ │ ├── sizzle.js │ │ │ ├── sizzle.min.js │ │ │ └── sizzle.min.map │ └── src │ │ ├── .eslintrc.json │ │ ├── ajax.js │ │ ├── ajax │ │ ├── jsonp.js │ │ ├── load.js │ │ ├── parseXML.js │ │ ├── script.js │ │ ├── var │ │ │ ├── location.js │ │ │ ├── nonce.js │ │ │ └── rquery.js │ │ └── xhr.js │ │ ├── attributes.js │ │ ├── attributes │ │ ├── attr.js │ │ ├── classes.js │ │ ├── prop.js │ │ ├── support.js │ │ └── val.js │ │ ├── callbacks.js │ │ ├── core.js │ │ ├── core │ │ ├── DOMEval.js │ │ ├── access.js │ │ ├── camelCase.js │ │ ├── init.js │ │ ├── nodeName.js │ │ ├── parseHTML.js │ │ ├── ready-no-deferred.js │ │ ├── ready.js │ │ ├── readyException.js │ │ ├── stripAndCollapse.js │ │ ├── support.js │ │ ├── toType.js │ │ └── var │ │ │ └── rsingleTag.js │ │ ├── css.js │ │ ├── css │ │ ├── addGetHookIf.js │ │ ├── adjustCSS.js │ │ ├── curCSS.js │ │ ├── hiddenVisibleSelectors.js │ │ ├── showHide.js │ │ ├── support.js │ │ └── var │ │ │ ├── cssExpand.js │ │ │ ├── getStyles.js │ │ │ ├── isHiddenWithinTree.js │ │ │ ├── rboxStyle.js │ │ │ ├── rnumnonpx.js │ │ │ └── swap.js │ │ ├── data.js │ │ ├── data │ │ ├── Data.js │ │ └── var │ │ │ ├── acceptData.js │ │ │ ├── dataPriv.js │ │ │ └── dataUser.js │ │ ├── deferred.js │ │ ├── deferred │ │ └── exceptionHook.js │ │ ├── deprecated.js │ │ ├── dimensions.js │ │ ├── effects.js │ │ ├── effects │ │ ├── Tween.js │ │ └── animatedSelector.js │ │ ├── event.js │ │ ├── event │ │ ├── ajax.js │ │ ├── alias.js │ │ ├── focusin.js │ │ ├── support.js │ │ └── trigger.js │ │ ├── exports │ │ ├── amd.js │ │ └── global.js │ │ ├── jquery.js │ │ ├── manipulation.js │ │ ├── manipulation │ │ ├── _evalUrl.js │ │ ├── buildFragment.js │ │ ├── getAll.js │ │ ├── setGlobalEval.js │ │ ├── support.js │ │ ├── var │ │ │ ├── rcheckableType.js │ │ │ ├── rscriptType.js │ │ │ └── rtagName.js │ │ └── wrapMap.js │ │ ├── offset.js │ │ ├── queue.js │ │ ├── queue │ │ └── delay.js │ │ ├── selector-native.js │ │ ├── selector-sizzle.js │ │ ├── selector.js │ │ ├── serialize.js │ │ ├── traversing.js │ │ ├── traversing │ │ ├── findFilter.js │ │ └── var │ │ │ ├── dir.js │ │ │ ├── rneedsContext.js │ │ │ └── siblings.js │ │ ├── var │ │ ├── ObjectFunctionString.js │ │ ├── arr.js │ │ ├── class2type.js │ │ ├── concat.js │ │ ├── document.js │ │ ├── documentElement.js │ │ ├── fnToString.js │ │ ├── getProto.js │ │ ├── hasOwn.js │ │ ├── indexOf.js │ │ ├── isFunction.js │ │ ├── isWindow.js │ │ ├── pnum.js │ │ ├── push.js │ │ ├── rcssNum.js │ │ ├── rnothtmlwhite.js │ │ ├── slice.js │ │ ├── support.js │ │ └── toString.js │ │ └── wrap.js ├── jszip-utils │ ├── .bower.json │ ├── CHANGES.md │ ├── Gruntfile.js │ ├── LICENSE.markdown │ ├── README.markdown │ ├── _config.yml │ ├── bower.json │ ├── component.json │ ├── dist │ │ ├── jszip-utils-ie.js │ │ ├── jszip-utils-ie.min.js │ │ ├── jszip-utils.js │ │ └── jszip-utils.min.js │ ├── documentation │ │ ├── _layouts │ │ │ └── default.html │ │ ├── api.md │ │ ├── api │ │ │ └── getbinarycontent.md │ │ └── css │ │ │ ├── main.css │ │ │ └── pygments.css │ ├── index.md │ ├── lib │ │ ├── index.js │ │ ├── index_IE.js │ │ └── license_header.js │ └── package.json ├── jszip │ ├── .bower.json │ ├── CHANGES.md │ ├── Gruntfile.js │ ├── LICENSE.markdown │ ├── README.markdown │ ├── _config.yml │ ├── bower.json │ ├── component.json │ ├── dist │ │ ├── jszip.js │ │ └── jszip.min.js │ ├── docs │ │ ├── APPNOTE.TXT │ │ ├── ZIP spec.txt │ │ └── references.txt │ ├── documentation │ │ ├── _layouts │ │ │ └── default.html │ │ ├── api_jszip.md │ │ ├── api_jszip │ │ │ ├── constructor.md │ │ │ ├── external.md │ │ │ ├── file_data.md │ │ │ ├── file_name.md │ │ │ ├── file_regex.md │ │ │ ├── filter.md │ │ │ ├── folder_name.md │ │ │ ├── folder_regex.md │ │ │ ├── for_each.md │ │ │ ├── generate_async.md │ │ │ ├── generate_internal_stream.md │ │ │ ├── generate_node_stream.md │ │ │ ├── load_async.md │ │ │ ├── load_async_object.md │ │ │ ├── remove.md │ │ │ ├── support.md │ │ │ └── version.md │ │ ├── api_streamhelper.md │ │ ├── api_streamhelper │ │ │ ├── accumulate.md │ │ │ ├── on.md │ │ │ ├── pause.md │ │ │ └── resume.md │ │ ├── api_zipobject.md │ │ ├── api_zipobject │ │ │ ├── async.md │ │ │ ├── internal_stream.md │ │ │ └── node_stream.md │ │ ├── contributing.md │ │ ├── css │ │ │ ├── main.css │ │ │ └── pygments.css │ │ ├── examples.md │ │ ├── examples │ │ │ ├── download-zip-file.html │ │ │ ├── download-zip-file.inc │ │ │ │ ├── blob.html │ │ │ │ ├── blob.js │ │ │ │ ├── data_uri.html │ │ │ │ └── data_uri.js │ │ │ ├── downloader.html │ │ │ ├── downloader.inc │ │ │ │ ├── downloader.html │ │ │ │ ├── downloader.js │ │ │ │ └── helpers.js │ │ │ ├── get-binary-files-ajax.html │ │ │ ├── get-binary-files-ajax.inc │ │ │ │ ├── fetch_api.html │ │ │ │ ├── fetch_api.js │ │ │ │ ├── jszip_utils.html │ │ │ │ └── jszip_utils.js │ │ │ ├── read-local-file-api.html │ │ │ └── read-local-file-api.inc │ │ │ │ ├── read.html │ │ │ │ └── read.js │ │ ├── faq.md │ │ ├── howto │ │ │ ├── read_zip.md │ │ │ └── write_zip.md │ │ ├── limitations.md │ │ └── upgrade_guide.md │ ├── index.html │ ├── lib │ │ ├── base64.js │ │ ├── compressedObject.js │ │ ├── compressions.js │ │ ├── crc32.js │ │ ├── defaults.js │ │ ├── external.js │ │ ├── flate.js │ │ ├── generate │ │ │ ├── ZipFileWorker.js │ │ │ └── index.js │ │ ├── index.js │ │ ├── license_header.js │ │ ├── load.js │ │ ├── nodejs │ │ │ ├── NodejsStreamInputAdapter.js │ │ │ └── NodejsStreamOutputAdapter.js │ │ ├── nodejsUtils.js │ │ ├── object.js │ │ ├── readable-stream-browser.js │ │ ├── reader │ │ │ ├── ArrayReader.js │ │ │ ├── DataReader.js │ │ │ ├── NodeBufferReader.js │ │ │ ├── StringReader.js │ │ │ ├── Uint8ArrayReader.js │ │ │ └── readerFor.js │ │ ├── signature.js │ │ ├── stream │ │ │ ├── ConvertWorker.js │ │ │ ├── Crc32Probe.js │ │ │ ├── DataLengthProbe.js │ │ │ ├── DataWorker.js │ │ │ ├── GenericWorker.js │ │ │ └── StreamHelper.js │ │ ├── support.js │ │ ├── utf8.js │ │ ├── utils.js │ │ ├── zipEntries.js │ │ ├── zipEntry.js │ │ └── zipObject.js │ ├── package-lock.json │ ├── package.json │ └── vendor │ │ └── FileSaver.js └── skeleton │ ├── LICENSE.md │ ├── README.md │ ├── bower.json │ ├── css │ ├── normalize.css │ └── skeleton.css │ ├── images │ └── favicon.png │ └── index.html ├── css └── style.css ├── img ├── encoded.png ├── favicon.ico ├── folder.png ├── logo-120px.png ├── logo-240px.png ├── logo-name.png └── organized.png ├── index.html └── js ├── FileSaver.js └── app.js /.gitignore: -------------------------------------------------------------------------------- 1 | .idea* 2 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /.idea/p2.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "fb2textile", 3 | "authors": [ 4 | "andrew@textile.io" 5 | ], 6 | "description": "Extract your facebook archive in a usable way.", 7 | "main": "index.html", 8 | "keywords": [ 9 | "textile", 10 | "facebook", 11 | "photos", 12 | "tools" 13 | ], 14 | "license": "MIT", 15 | "homepage": "https://textile.photos/", 16 | "ignore": [ 17 | "**/.*", 18 | "node_modules", 19 | "bower_components", 20 | "test", 21 | "tests" 22 | ], 23 | "dependencies": { 24 | "jquery": "^3.3.1", 25 | "skeleton": "^2.0.4", 26 | "jszip": "Stuk/jszip#^3.1.5", 27 | "jszip-utils": "Stuk/jszip-utils#^0.0.2" 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /bower_components/jquery/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ], 14 | "homepage": "https://github.com/jquery/jquery-dist", 15 | "version": "3.3.1", 16 | "_release": "3.3.1", 17 | "_resolution": { 18 | "type": "version", 19 | "tag": "3.3.1", 20 | "commit": "9e8ec3d10fad04748176144f108d7355662ae75e" 21 | }, 22 | "_source": "https://github.com/jquery/jquery-dist.git", 23 | "_target": "^3.3.1", 24 | "_originalSource": "jquery", 25 | "_direct": true 26 | } -------------------------------------------------------------------------------- /bower_components/jquery/LICENSE.txt: -------------------------------------------------------------------------------- 1 | Copyright JS Foundation and other contributors, https://js.foundation/ 2 | 3 | This software consists of voluntary contributions made by many 4 | individuals. For exact contribution history, see the revision history 5 | available at https://github.com/jquery/jquery 6 | 7 | The following license applies to all parts of this software except as 8 | documented below: 9 | 10 | ==== 11 | 12 | Permission is hereby granted, free of charge, to any person obtaining 13 | a copy of this software and associated documentation files (the 14 | "Software"), to deal in the Software without restriction, including 15 | without limitation the rights to use, copy, modify, merge, publish, 16 | distribute, sublicense, and/or sell copies of the Software, and to 17 | permit persons to whom the Software is furnished to do so, subject to 18 | the following conditions: 19 | 20 | The above copyright notice and this permission notice shall be 21 | included in all copies or substantial portions of the Software. 22 | 23 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 24 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 25 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 26 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 27 | LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION 28 | OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 29 | WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 30 | 31 | ==== 32 | 33 | All files located in the node_modules and external directories are 34 | externally maintained libraries used by this software which have their 35 | own licenses; we recommend you read them, as their terms may differ from 36 | the terms above. 37 | -------------------------------------------------------------------------------- /bower_components/jquery/README.md: -------------------------------------------------------------------------------- 1 | # jQuery 2 | 3 | > jQuery is a fast, small, and feature-rich JavaScript library. 4 | 5 | For information on how to get started and how to use jQuery, please see [jQuery's documentation](http://api.jquery.com/). 6 | For source files and issues, please visit the [jQuery repo](https://github.com/jquery/jquery). 7 | 8 | If upgrading, please see the [blog post for 3.3.1](https://blog.jquery.com/2017/03/20/jquery-3.3.1-now-available/). This includes notable differences from the previous version and a more readable changelog. 9 | 10 | ## Including jQuery 11 | 12 | Below are some of the most common ways to include jQuery. 13 | 14 | ### Browser 15 | 16 | #### Script tag 17 | 18 | ```html 19 | 20 | ``` 21 | 22 | #### Babel 23 | 24 | [Babel](http://babeljs.io/) is a next generation JavaScript compiler. One of the features is the ability to use ES6/ES2015 modules now, even though browsers do not yet support this feature natively. 25 | 26 | ```js 27 | import $ from "jquery"; 28 | ``` 29 | 30 | #### Browserify/Webpack 31 | 32 | There are several ways to use [Browserify](http://browserify.org/) and [Webpack](https://webpack.github.io/). For more information on using these tools, please refer to the corresponding project's documention. In the script, including jQuery will usually look like this... 33 | 34 | ```js 35 | var $ = require("jquery"); 36 | ``` 37 | 38 | #### AMD (Asynchronous Module Definition) 39 | 40 | AMD is a module format built for the browser. For more information, we recommend [require.js' documentation](http://requirejs.org/docs/whyamd.html). 41 | 42 | ```js 43 | define(["jquery"], function($) { 44 | 45 | }); 46 | ``` 47 | 48 | ### Node 49 | 50 | To include jQuery in [Node](nodejs.org), first install with npm. 51 | 52 | ```sh 53 | npm install jquery 54 | ``` 55 | 56 | For jQuery to work in Node, a window with a document is required. Since no such window exists natively in Node, one can be mocked by tools such as [jsdom](https://github.com/tmpvar/jsdom). This can be useful for testing purposes. 57 | 58 | ```js 59 | require("jsdom").env("", function(err, window) { 60 | if (err) { 61 | console.error(err); 62 | return; 63 | } 64 | 65 | var $ = require("jquery")(window); 66 | }); 67 | ``` 68 | -------------------------------------------------------------------------------- /bower_components/jquery/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ] 14 | } -------------------------------------------------------------------------------- /bower_components/jquery/external/sizzle/LICENSE.txt: -------------------------------------------------------------------------------- 1 | Copyright jQuery Foundation and other contributors, https://jquery.org/ 2 | 3 | This software consists of voluntary contributions made by many 4 | individuals. For exact contribution history, see the revision history 5 | available at https://github.com/jquery/sizzle 6 | 7 | The following license applies to all parts of this software except as 8 | documented below: 9 | 10 | ==== 11 | 12 | Permission is hereby granted, free of charge, to any person obtaining 13 | a copy of this software and associated documentation files (the 14 | "Software"), to deal in the Software without restriction, including 15 | without limitation the rights to use, copy, modify, merge, publish, 16 | distribute, sublicense, and/or sell copies of the Software, and to 17 | permit persons to whom the Software is furnished to do so, subject to 18 | the following conditions: 19 | 20 | The above copyright notice and this permission notice shall be 21 | included in all copies or substantial portions of the Software. 22 | 23 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 24 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 25 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 26 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 27 | LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION 28 | OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 29 | WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 30 | 31 | ==== 32 | 33 | All files located in the node_modules and external directories are 34 | externally maintained libraries used by this software which have their 35 | own licenses; we recommend you read them, as their terms may differ from 36 | the terms above. 37 | -------------------------------------------------------------------------------- /bower_components/jquery/src/.eslintrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "root": true, 3 | 4 | "extends": "../.eslintrc-browser.json" 5 | } 6 | -------------------------------------------------------------------------------- /bower_components/jquery/src/ajax/jsonp.js: -------------------------------------------------------------------------------- 1 | define( [ 2 | "../core", 3 | "../var/isFunction", 4 | "./var/nonce", 5 | "./var/rquery", 6 | "../ajax" 7 | ], function( jQuery, isFunction, nonce, rquery ) { 8 | 9 | "use strict"; 10 | 11 | var oldCallbacks = [], 12 | rjsonp = /(=)\?(?=&|$)|\?\?/; 13 | 14 | // Default jsonp settings 15 | jQuery.ajaxSetup( { 16 | jsonp: "callback", 17 | jsonpCallback: function() { 18 | var callback = oldCallbacks.pop() || ( jQuery.expando + "_" + ( nonce++ ) ); 19 | this[ callback ] = true; 20 | return callback; 21 | } 22 | } ); 23 | 24 | // Detect, normalize options and install callbacks for jsonp requests 25 | jQuery.ajaxPrefilter( "json jsonp", function( s, originalSettings, jqXHR ) { 26 | 27 | var callbackName, overwritten, responseContainer, 28 | jsonProp = s.jsonp !== false && ( rjsonp.test( s.url ) ? 29 | "url" : 30 | typeof s.data === "string" && 31 | ( s.contentType || "" ) 32 | .indexOf( "application/x-www-form-urlencoded" ) === 0 && 33 | rjsonp.test( s.data ) && "data" 34 | ); 35 | 36 | // Handle iff the expected data type is "jsonp" or we have a parameter to set 37 | if ( jsonProp || s.dataTypes[ 0 ] === "jsonp" ) { 38 | 39 | // Get callback name, remembering preexisting value associated with it 40 | callbackName = s.jsonpCallback = isFunction( s.jsonpCallback ) ? 41 | s.jsonpCallback() : 42 | s.jsonpCallback; 43 | 44 | // Insert callback into url or form data 45 | if ( jsonProp ) { 46 | s[ jsonProp ] = s[ jsonProp ].replace( rjsonp, "$1" + callbackName ); 47 | } else if ( s.jsonp !== false ) { 48 | s.url += ( rquery.test( s.url ) ? "&" : "?" ) + s.jsonp + "=" + callbackName; 49 | } 50 | 51 | // Use data converter to retrieve json after script execution 52 | s.converters[ "script json" ] = function() { 53 | if ( !responseContainer ) { 54 | jQuery.error( callbackName + " was not called" ); 55 | } 56 | return responseContainer[ 0 ]; 57 | }; 58 | 59 | // Force json dataType 60 | s.dataTypes[ 0 ] = "json"; 61 | 62 | // Install callback 63 | overwritten = window[ callbackName ]; 64 | window[ callbackName ] = function() { 65 | responseContainer = arguments; 66 | }; 67 | 68 | // Clean-up function (fires after converters) 69 | jqXHR.always( function() { 70 | 71 | // If previous value didn't exist - remove it 72 | if ( overwritten === undefined ) { 73 | jQuery( window ).removeProp( callbackName ); 74 | 75 | // Otherwise restore preexisting value 76 | } else { 77 | window[ callbackName ] = overwritten; 78 | } 79 | 80 | // Save back as free 81 | if ( s[ callbackName ] ) { 82 | 83 | // Make sure that re-using the options doesn't screw things around 84 | s.jsonpCallback = originalSettings.jsonpCallback; 85 | 86 | // Save the callback name for future use 87 | oldCallbacks.push( callbackName ); 88 | } 89 | 90 | // Call if it was a function and we have a response 91 | if ( responseContainer && isFunction( overwritten ) ) { 92 | overwritten( responseContainer[ 0 ] ); 93 | } 94 | 95 | responseContainer = overwritten = undefined; 96 | } ); 97 | 98 | // Delegate to script 99 | return "script"; 100 | } 101 | } ); 102 | 103 | } ); 104 | -------------------------------------------------------------------------------- /bower_components/jquery/src/ajax/load.js: -------------------------------------------------------------------------------- 1 | define( [ 2 | "../core", 3 | "../core/stripAndCollapse", 4 | "../var/isFunction", 5 | "../core/parseHTML", 6 | "../ajax", 7 | "../traversing", 8 | "../manipulation", 9 | "../selector" 10 | ], function( jQuery, stripAndCollapse, isFunction ) { 11 | 12 | "use strict"; 13 | 14 | /** 15 | * Load a url into a page 16 | */ 17 | jQuery.fn.load = function( url, params, callback ) { 18 | var selector, type, response, 19 | self = this, 20 | off = url.indexOf( " " ); 21 | 22 | if ( off > -1 ) { 23 | selector = stripAndCollapse( url.slice( off ) ); 24 | url = url.slice( 0, off ); 25 | } 26 | 27 | // If it's a function 28 | if ( isFunction( params ) ) { 29 | 30 | // We assume that it's the callback 31 | callback = params; 32 | params = undefined; 33 | 34 | // Otherwise, build a param string 35 | } else if ( params && typeof params === "object" ) { 36 | type = "POST"; 37 | } 38 | 39 | // If we have elements to modify, make the request 40 | if ( self.length > 0 ) { 41 | jQuery.ajax( { 42 | url: url, 43 | 44 | // If "type" variable is undefined, then "GET" method will be used. 45 | // Make value of this field explicit since 46 | // user can override it through ajaxSetup method 47 | type: type || "GET", 48 | dataType: "html", 49 | data: params 50 | } ).done( function( responseText ) { 51 | 52 | // Save response for use in complete callback 53 | response = arguments; 54 | 55 | self.html( selector ? 56 | 57 | // If a selector was specified, locate the right elements in a dummy div 58 | // Exclude scripts to avoid IE 'Permission Denied' errors 59 | jQuery( "
" ).append( jQuery.parseHTML( responseText ) ).find( selector ) : 60 | 61 | // Otherwise use the full result 62 | responseText ); 63 | 64 | // If the request succeeds, this function gets "data", "status", "jqXHR" 65 | // but they are ignored because response was set above. 66 | // If it fails, this function gets "jqXHR", "status", "error" 67 | } ).always( callback && function( jqXHR, status ) { 68 | self.each( function() { 69 | callback.apply( this, response || [ jqXHR.responseText, status, jqXHR ] ); 70 | } ); 71 | } ); 72 | } 73 | 74 | return this; 75 | }; 76 | 77 | } ); 78 | -------------------------------------------------------------------------------- /bower_components/jquery/src/ajax/parseXML.js: -------------------------------------------------------------------------------- 1 | define( [ 2 | "../core" 3 | ], function( jQuery ) { 4 | 5 | "use strict"; 6 | 7 | // Cross-browser xml parsing 8 | jQuery.parseXML = function( data ) { 9 | var xml; 10 | if ( !data || typeof data !== "string" ) { 11 | return null; 12 | } 13 | 14 | // Support: IE 9 - 11 only 15 | // IE throws on parseFromString with invalid input. 16 | try { 17 | xml = ( new window.DOMParser() ).parseFromString( data, "text/xml" ); 18 | } catch ( e ) { 19 | xml = undefined; 20 | } 21 | 22 | if ( !xml || xml.getElementsByTagName( "parsererror" ).length ) { 23 | jQuery.error( "Invalid XML: " + data ); 24 | } 25 | return xml; 26 | }; 27 | 28 | return jQuery.parseXML; 29 | 30 | } ); 31 | -------------------------------------------------------------------------------- /bower_components/jquery/src/ajax/script.js: -------------------------------------------------------------------------------- 1 | define( [ 2 | "../core", 3 | "../var/document", 4 | "../ajax" 5 | ], function( jQuery, document ) { 6 | 7 | "use strict"; 8 | 9 | // Prevent auto-execution of scripts when no explicit dataType was provided (See gh-2432) 10 | jQuery.ajaxPrefilter( function( s ) { 11 | if ( s.crossDomain ) { 12 | s.contents.script = false; 13 | } 14 | } ); 15 | 16 | // Install script dataType 17 | jQuery.ajaxSetup( { 18 | accepts: { 19 | script: "text/javascript, application/javascript, " + 20 | "application/ecmascript, application/x-ecmascript" 21 | }, 22 | contents: { 23 | script: /\b(?:java|ecma)script\b/ 24 | }, 25 | converters: { 26 | "text script": function( text ) { 27 | jQuery.globalEval( text ); 28 | return text; 29 | } 30 | } 31 | } ); 32 | 33 | // Handle cache's special case and crossDomain 34 | jQuery.ajaxPrefilter( "script", function( s ) { 35 | if ( s.cache === undefined ) { 36 | s.cache = false; 37 | } 38 | if ( s.crossDomain ) { 39 | s.type = "GET"; 40 | } 41 | } ); 42 | 43 | // Bind script tag hack transport 44 | jQuery.ajaxTransport( "script", function( s ) { 45 | 46 | // This transport only deals with cross domain requests 47 | if ( s.crossDomain ) { 48 | var script, callback; 49 | return { 50 | send: function( _, complete ) { 51 | script = jQuery( " 11 | 14 | 17 | ``` 18 | 19 | License 20 | ------- 21 | 22 | JSZipUtils is dual-licensed. You may use it under the MIT license *or* the GPLv3 23 | license. See LICENSE.markdown. 24 | -------------------------------------------------------------------------------- /bower_components/jszip-utils/_config.yml: -------------------------------------------------------------------------------- 1 | # will be overwritten by github, see https://help.github.com/articles/using-jekyll-with-pages 2 | safe: true 3 | lsi: false 4 | pygments: true 5 | source: ./ 6 | # /overwritten 7 | 8 | baseurl: /jszip-utils 9 | 10 | layouts: ./documentation/_layouts 11 | permalink: none 12 | exclude: ['bin', 'README.md', 'node_modules'] 13 | 14 | markdown: redcarpet 15 | redcarpet: 16 | extensions: [ 17 | 'no_intra_emphasis', 18 | 'fenced_code_blocks', 19 | 'autolink', 20 | 'strikethrough', 21 | 'superscript', 22 | 'with_toc_data', 23 | 'tables', 24 | 'hardwrap' 25 | ] 26 | -------------------------------------------------------------------------------- /bower_components/jszip-utils/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jszip-utils", 3 | "version": "0.0.2", 4 | "homepage": "https://github.com/Stuk/jszip-utils", 5 | "authors": [ 6 | "Stuart Knightley ", 7 | "David Duponchel " 8 | ], 9 | "description": "A collection of cross-browser utilities to go along with JSZip.", 10 | "main": "dist/jszip-utils.js", 11 | "keywords": [ 12 | "JSZip", 13 | "ajax", 14 | "cross browser", 15 | "IE", 16 | "Internet Explorer" 17 | ], 18 | "license": "MIT or GPLv3", 19 | "ignore": [ 20 | "**/.*", 21 | "node_modules", 22 | "bower_components", 23 | "test", 24 | "tests" 25 | ] 26 | } 27 | -------------------------------------------------------------------------------- /bower_components/jszip-utils/component.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jszip-utils", 3 | "repo": "Stuk/jszip-utils", 4 | "description": "A collection of cross-browser utilities to go along with JSZip.", 5 | "version": "0.0.2", 6 | "keywords": [ 7 | "JSZip", 8 | "ajax", 9 | "cross browser", 10 | "IE", 11 | "Internet Explorer" 12 | ], 13 | "main": "dist/jszip-utils.js", 14 | "license": "MIT or GPLv3", 15 | "scripts": [ 16 | "dist/jszip-utils.js" 17 | ] 18 | } 19 | -------------------------------------------------------------------------------- /bower_components/jszip-utils/dist/jszip-utils-ie.js: -------------------------------------------------------------------------------- 1 | /*! 2 | 3 | JSZipUtils - A collection of cross-browser utilities to go along with JSZip. 4 | 5 | 6 | (c) 2014 Stuart Knightley, David Duponchel 7 | Dual licenced under the MIT license or GPLv3. See https://raw.github.com/Stuk/jszip-utils/master/LICENSE.markdown. 8 | 9 | */ 10 | ;(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o\r\n"+ 18 | "\r\n"; 32 | 33 | // inject VBScript 34 | document.write(IEBinaryToArray_ByteStr_Script); 35 | 36 | global.JSZipUtils._getBinaryFromXHR = function (xhr) { 37 | var binary = xhr.responseBody; 38 | var byteMapping = {}; 39 | for ( var i = 0; i < 256; i++ ) { 40 | for ( var j = 0; j < 256; j++ ) { 41 | byteMapping[ String.fromCharCode( i + (j << 8) ) ] = 42 | String.fromCharCode(i) + String.fromCharCode(j); 43 | } 44 | } 45 | var rawBytes = IEBinaryToArray_ByteStr(binary); 46 | var lastChr = IEBinaryToArray_ByteStr_Last(binary); 47 | return rawBytes.replace(/[\s\S]/g, function( match ) { 48 | return byteMapping[match]; 49 | }) + lastChr; 50 | }; 51 | 52 | // enforcing Stuk's coding style 53 | // vim: set shiftwidth=4 softtabstop=4: 54 | 55 | },{}]},{},[1]) 56 | ; -------------------------------------------------------------------------------- /bower_components/jszip-utils/dist/jszip-utils-ie.min.js: -------------------------------------------------------------------------------- 1 | /*! 2 | 3 | JSZipUtils - A collection of cross-browser utilities to go along with JSZip. 4 | 5 | 6 | (c) 2014 Stuart Knightley, David Duponchel 7 | Dual licenced under the MIT license or GPLv3. See https://raw.github.com/Stuk/jszip-utils/master/LICENSE.markdown. 8 | 9 | */ 10 | !function a(b,c,d){function e(g,h){if(!c[g]){if(!b[g]){var i="function"==typeof require&&require;if(!h&&i)return i(g,!0);if(f)return f(g,!0);throw new Error("Cannot find module '"+g+"'")}var j=c[g]={exports:{}};b[g][0].call(j.exports,function(a){var c=b[g][1][a];return e(c?c:a)},j,j.exports,a,b,c,d)}return c[g].exports}for(var f="function"==typeof require&&require,g=0;g\r\n";document.write(b),a.JSZipUtils._getBinaryFromXHR=function(a){for(var b=a.responseBody,c={},d=0;256>d;d++)for(var e=0;256>e;e++)c[String.fromCharCode(d+(e<<8))]=String.fromCharCode(d)+String.fromCharCode(e);var f=IEBinaryToArray_ByteStr(b),g=IEBinaryToArray_ByteStr_Last(b);return f.replace(/[\s\S]/g,function(a){return c[a]})+g}},{}]},{},[1]); -------------------------------------------------------------------------------- /bower_components/jszip-utils/dist/jszip-utils.min.js: -------------------------------------------------------------------------------- 1 | /*! 2 | 3 | JSZipUtils - A collection of cross-browser utilities to go along with JSZip. 4 | 5 | 6 | (c) 2014 Stuart Knightley, David Duponchel 7 | Dual licenced under the MIT license or GPLv3. See https://raw.github.com/Stuk/jszip-utils/master/LICENSE.markdown. 8 | 9 | */ 10 | !function(a){"object"==typeof exports?module.exports=a():"function"==typeof define&&define.amd?define(a):"undefined"!=typeof window?window.JSZipUtils=a():"undefined"!=typeof global?global.JSZipUtils=a():"undefined"!=typeof self&&(self.JSZipUtils=a())}(function(){return function a(b,c,d){function e(g,h){if(!c[g]){if(!b[g]){var i="function"==typeof require&&require;if(!h&&i)return i(g,!0);if(f)return f(g,!0);throw new Error("Cannot find module '"+g+"'")}var j=c[g]={exports:{}};b[g][0].call(j.exports,function(a){var c=b[g][1][a];return e(c?c:a)},j,j.exports,a,b,c,d)}return c[g].exports}for(var f="function"==typeof require&&require,g=0;g 40 | 41 | __Example__ 42 | 43 | ```js 44 | // loading a zip file 45 | JSZipUtils.getBinaryContent("path/to/file.zip", function (err, data) { 46 | if(err) { 47 | throw err; // or handle the error 48 | } 49 | var zip = new JSZip(data); 50 | }); 51 | 52 | // loading a file and add it in a zip file 53 | JSZipUtils.getBinaryContent("path/to/picture.png", function (err, data) { 54 | if(err) { 55 | throw err; // or handle the error 56 | } 57 | var zip = new JSZip(); 58 | zip.file("picture.png", data, {binary:true}); 59 | }); 60 | ``` 61 | 62 | 63 | -------------------------------------------------------------------------------- /bower_components/jszip-utils/documentation/css/main.css: -------------------------------------------------------------------------------- 1 | ul.nav ul { 2 | list-style:none; 3 | margin: 0; 4 | padding: 0 0 0 25px; 5 | } 6 | 7 | 8 | -------------------------------------------------------------------------------- /bower_components/jszip-utils/index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: JSZipUtils 3 | layout: default 4 | --- 5 | 6 | A collection of cross-browser utilities to go along with JSZip, see 7 | http://stuk.github.io/jszip-utils for all the documentation. 8 | 9 | It has two parts, one for every browsers and one for IE < 10. To use it : 10 | 11 | ```html 12 | 13 | 16 | 19 | ``` 20 | 21 | License 22 | ------- 23 | 24 | JSZipUtils is dual-licensed. You may use it under the MIT license *or* the GPLv3 25 | license. See LICENSE.markdown. 26 | -------------------------------------------------------------------------------- /bower_components/jszip-utils/lib/index_IE.js: -------------------------------------------------------------------------------- 1 | /* jshint evil: true, newcap: false */ 2 | /* global IEBinaryToArray_ByteStr, IEBinaryToArray_ByteStr_Last */ 3 | "use strict"; 4 | 5 | // Adapted from http://stackoverflow.com/questions/1095102/how-do-i-load-binary-image-data-using-javascript-and-xmlhttprequest 6 | var IEBinaryToArray_ByteStr_Script = 7 | "\r\n"+ 8 | "\r\n"; 22 | 23 | // inject VBScript 24 | document.write(IEBinaryToArray_ByteStr_Script); 25 | 26 | global.JSZipUtils._getBinaryFromXHR = function (xhr) { 27 | var binary = xhr.responseBody; 28 | var byteMapping = {}; 29 | for ( var i = 0; i < 256; i++ ) { 30 | for ( var j = 0; j < 256; j++ ) { 31 | byteMapping[ String.fromCharCode( i + (j << 8) ) ] = 32 | String.fromCharCode(i) + String.fromCharCode(j); 33 | } 34 | } 35 | var rawBytes = IEBinaryToArray_ByteStr(binary); 36 | var lastChr = IEBinaryToArray_ByteStr_Last(binary); 37 | return rawBytes.replace(/[\s\S]/g, function( match ) { 38 | return byteMapping[match]; 39 | }) + lastChr; 40 | }; 41 | 42 | // enforcing Stuk's coding style 43 | // vim: set shiftwidth=4 softtabstop=4: 44 | -------------------------------------------------------------------------------- /bower_components/jszip-utils/lib/license_header.js: -------------------------------------------------------------------------------- 1 | /*! 2 | 3 | JSZipUtils - A collection of cross-browser utilities to go along with JSZip. 4 | 5 | 6 | (c) 2014 Stuart Knightley, David Duponchel 7 | Dual licenced under the MIT license or GPLv3. See https://raw.github.com/Stuk/jszip-utils/master/LICENSE.markdown. 8 | 9 | */ 10 | -------------------------------------------------------------------------------- /bower_components/jszip-utils/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jszip-utils", 3 | "version": "0.0.2", 4 | "author": "Stuart Knightley ", 5 | "description": "A collection of cross-browser utilities to go along with JSZip.", 6 | "scripts": { 7 | "test": "npm run test-browser", 8 | "test-browser": "grunt build && grunt test", 9 | "lint": "grunt jshint" 10 | }, 11 | "main": "./lib/index", 12 | "repository": { 13 | "type": "git", 14 | "url": "https://github.com/Stuk/jszip-utils.git" 15 | }, 16 | "contributors": [ 17 | { 18 | "name": "David Duponchel" 19 | } 20 | ], 21 | "keywords": [ 22 | "JSZip", 23 | "ajax", 24 | "cross browser", 25 | "IE", 26 | "Internet Explorer" 27 | ], 28 | "devDependencies": { 29 | "qunit": "~0.5.16", 30 | "qunitjs": "~1.14.0", 31 | "grunt": "~0.4.1", 32 | "grunt-cli": "~0.1.9", 33 | "grunt-saucelabs": "~4.1.2", 34 | "grunt-contrib-connect": "~0.5.0", 35 | "jshint": "~2.1.11", 36 | "browserify": "~2.35.0", 37 | "grunt-browserify": "~1.3.0", 38 | "grunt-contrib-jshint": "~0.6.4", 39 | "grunt-contrib-uglify": "~0.2.4" 40 | }, 41 | "dependencies":{ 42 | }, 43 | "license": "MIT or GPLv3" 44 | } 45 | -------------------------------------------------------------------------------- /bower_components/jszip/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jszip", 3 | "homepage": "http://stuartk.com/jszip", 4 | "authors": [ 5 | "Stuart Knightley " 6 | ], 7 | "description": "Create, read and edit .zip files with JavaScript http://stuartk.com/jszip", 8 | "main": "dist/jszip.js", 9 | "keywords": [ 10 | "zip", 11 | "deflate", 12 | "inflate" 13 | ], 14 | "license": "MIT or GPLv3", 15 | "ignore": [ 16 | "**/.*", 17 | "node_modules", 18 | "bower_components", 19 | "test", 20 | "tests" 21 | ], 22 | "version": "3.1.5", 23 | "_release": "3.1.5", 24 | "_resolution": { 25 | "type": "version", 26 | "tag": "v3.1.5", 27 | "commit": "a4138a23cb9b8eb773c19af7d36d5ce2bcf4bfda" 28 | }, 29 | "_source": "git://github.com/Stuk/jszip.git", 30 | "_target": "^3.1.5", 31 | "_originalSource": "Stuk/jszip", 32 | "_direct": true 33 | } -------------------------------------------------------------------------------- /bower_components/jszip/README.markdown: -------------------------------------------------------------------------------- 1 | JSZip [![Build Status](https://api.travis-ci.org/Stuk/jszip.svg?branch=master)](http://travis-ci.org/Stuk/jszip) [![Code Climate](https://codeclimate.com/github/Stuk/jszip/badges/gpa.svg)](https://codeclimate.com/github/Stuk/jszip) 2 | ===== 3 | 4 | [![Selenium Test Status](https://saucelabs.com/browser-matrix/jszip.svg)](https://saucelabs.com/u/jszip) 5 | 6 | A library for creating, reading and editing .zip files with JavaScript, with a 7 | lovely and simple API. 8 | 9 | See https://stuk.github.io/jszip for all the documentation. 10 | 11 | ```javascript 12 | var zip = new JSZip(); 13 | 14 | zip.file("Hello.txt", "Hello World\n"); 15 | 16 | var img = zip.folder("images"); 17 | img.file("smile.gif", imgData, {base64: true}); 18 | 19 | zip.generateAsync({type:"blob"}).then(function(content) { 20 | // see FileSaver.js 21 | saveAs(content, "example.zip"); 22 | }); 23 | 24 | /* 25 | Results in a zip containing 26 | Hello.txt 27 | images/ 28 | smile.gif 29 | */ 30 | ``` 31 | License 32 | ------- 33 | 34 | JSZip is dual-licensed. You may use it under the MIT license *or* the GPLv3 35 | license. See [LICENSE.markdown](LICENSE.markdown). 36 | -------------------------------------------------------------------------------- /bower_components/jszip/_config.yml: -------------------------------------------------------------------------------- 1 | # will be overwritten by github, see https://help.github.com/articles/using-jekyll-with-pages 2 | lsi: false 3 | safe: true 4 | source: ./ 5 | incremental: false 6 | highlighter: rouge 7 | gist: 8 | noscript: false 9 | # /overwritten 10 | 11 | baseurl: /jszip 12 | 13 | layouts_dir: ./documentation/_layouts 14 | permalink: none 15 | exclude: ['bin', 'README.md', 'node_modules'] 16 | 17 | 18 | kramdown: 19 | input: GFM 20 | hard_wrap: false 21 | gems: 22 | - jekyll-coffeescript 23 | - jekyll-paginate 24 | 25 | -------------------------------------------------------------------------------- /bower_components/jszip/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jszip", 3 | "homepage": "http://stuartk.com/jszip", 4 | "authors": [ 5 | "Stuart Knightley " 6 | ], 7 | "description": "Create, read and edit .zip files with JavaScript http://stuartk.com/jszip", 8 | "main": "dist/jszip.js", 9 | "keywords": [ 10 | "zip", 11 | "deflate", 12 | "inflate" 13 | ], 14 | "license": "MIT or GPLv3", 15 | "ignore": [ 16 | "**/.*", 17 | "node_modules", 18 | "bower_components", 19 | "test", 20 | "tests" 21 | ] 22 | } 23 | -------------------------------------------------------------------------------- /bower_components/jszip/component.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jszip", 3 | "repo": "Stuk/jszip", 4 | "description": "Create, read and edit .zip files with JavaScript http://stuartk.com/jszip", 5 | "version": "3.1.5", 6 | "keywords": [ 7 | "zip", 8 | "deflate", 9 | "inflate" 10 | ], 11 | "main": "dist/jszip.js", 12 | "license": "MIT or GPLv3", 13 | "scripts": [ 14 | "dist/jszip.js" 15 | ] 16 | } 17 | -------------------------------------------------------------------------------- /bower_components/jszip/docs/ZIP spec.txt: -------------------------------------------------------------------------------- 1 | Here are the notes I made while working through the ZIP file specification. 2 | 3 | For each file: 4 | 5 | local file header signature 4 bytes (0x04034b50) 6 | version needed to extract 2 bytes 7 | general purpose bit flag 2 bytes 8 | compression method 2 bytes 9 | last mod file time 2 bytes 10 | last mod file date 2 bytes 11 | crc-32 4 bytes 12 | compressed size 4 bytes 13 | uncompressed size 4 bytes 14 | file name length 2 bytes 15 | extra field length 2 bytes 16 | 17 | |sig |v |g |c |t |d |crc |csz |usz |n |x | 18 | PK.. ## 00 00 ?? ?? xxxx ???? ???? ?? 00 19 | 20 | 21 | Central directory: 22 | 23 | central file header signature 4 bytes (0x02014b50) 24 | version made by 2 bytes 25 | version needed to extract 2 bytes * 26 | general purpose bit flag 2 bytes * 27 | compression method 2 bytes * 28 | last mod file time 2 bytes * 29 | last mod file date 2 bytes * 30 | crc-32 4 bytes * 31 | compressed size 4 bytes * 32 | uncompressed size 4 bytes * 33 | file name length 2 bytes * 34 | extra field length 2 bytes * 35 | file comment length 2 bytes 36 | disk number start 2 bytes 37 | internal file attributes 2 bytes 38 | external file attributes 4 bytes 39 | relative offset of local header 4 bytes 40 | 41 | file name (variable size) 42 | extra field (variable size) 43 | file comment (variable size) 44 | 45 | |sig |vm|vx|g |c |d |t |crc |csz |usz |n |x |cm|dn|ia|xa |roff| 46 | PK.. ## ## 00 00 ?? ?? xxxx ???? ???? ?? 00 00 00 00 xxxx ???? 47 | 48 | End of central directory: 49 | 50 | end of central dir signature 4 bytes (0x06054b50) 51 | number of this disk 2 bytes 52 | number of the disk with the 53 | start of the central directory 2 bytes 54 | total number of entries in the 55 | central directory on this disk 2 bytes 56 | total number of entries in 57 | the central directory 2 bytes 58 | size of the central directory 4 bytes 59 | offset of start of central 60 | directory with respect to 61 | the starting disk number 4 bytes 62 | .ZIP file comment length 2 bytes 63 | .ZIP file comment (variable size) 64 | 65 | |sig |n1|n2|e |ne|size|off |cm| 66 | PK.. 00 00 ?? ?? ???? ???? 00 67 | -------------------------------------------------------------------------------- /bower_components/jszip/docs/references.txt: -------------------------------------------------------------------------------- 1 | Zip format 2 | ---------- 3 | http://www.pkware.com/support/zip-application-note 4 | http://www.xxcopy.com/xxcopy06.htm 5 | 6 | Data URL 7 | -------- 8 | https://developer.mozilla.org/en/The_data_URL_scheme 9 | http://msdn.microsoft.com/en-us/library/cc848897(VS.85).aspx 10 | http://www.phpied.com/mhtml-when-you-need-data-uris-in-ie7-and-under/ 11 | 12 | http://www.motobit.com/util/base64-decoder-encoder.asp 13 | 14 | Saving files 15 | ------------ 16 | http://msdn.microsoft.com/en-us/library/ms536676(VS.85).aspx 17 | http://msdn.microsoft.com/en-us/library/ms536419(VS.85).aspx 18 | http://msdn.microsoft.com/en-us/library/ms537418(VS.85).aspx 19 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "JSZip API" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | An instance of JSZip represents a set of files. You can add them, remove them, 8 | modify them. You can also import an existing zip file or generate one. 9 | 10 | ### Attributes 11 | 12 | attribute name | type | description 13 | ---------------------|-------------|------------- 14 | `files` | object | the [ZipObject]({{site.baseurl}}/documentation/api_zipobject.html)s inside the zip with the name as key. See [file(name)]({{site.baseurl}}/documentation/api_jszip/file_name.html). 15 | `comment` | string | the comment of the zip file. 16 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/constructor.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "new JSZip() or JSZip()" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Create a new JSZip instance. 8 | 9 | __Returns__ : A new JSZip. 10 | 11 | __Since__: v1.0.0 12 | 13 | ## Example 14 | 15 | ```js 16 | var zip = new JSZip(); 17 | // same as 18 | var zip = JSZip(); 19 | ``` 20 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/external.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "JSZip.external" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | JSZip uses objects that may not exist on every platform, in which case it uses 8 | a shim. 9 | Accessing or replacing these objects can sometimes be useful. JSZip.external 10 | contains the following properties : 11 | 12 | * `Promise` : the [Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise) implementation used. 13 | 14 | The global object is prefered when available. 15 | 16 | __Example__ 17 | 18 | ```js 19 | // use bluebird instead 20 | JSZip.external.Promise = Bluebird; 21 | 22 | // use the native Promise object: 23 | JSZip.external.Promise = Promise; 24 | ``` 25 | 26 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/file_name.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "file(name)" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Get a file with the specified name. You can specify folders 8 | in the name : the folder separator is a forward slash ("/"). 9 | 10 | __Returns__ : An instance of [ZipObject]({{site.baseurl}}/documentation/api_zipobject.html) representing 11 | the file if any, `null` otherwise. 12 | 13 | __Since__: v1.0.0 14 | 15 | ## Arguments 16 | 17 | name | type | description 18 | -----|--------|------------- 19 | name | string | the name of the file. 20 | 21 | __Throws__ : Nothing. 22 | 23 | 24 | 25 | ## Example 26 | 27 | ```js 28 | var zip = new JSZip(); 29 | zip.file("file.txt", "content"); 30 | 31 | zip.file("file.txt").name // "file.txt" 32 | zip.file("file.txt").async("string") // a promise of "content" 33 | zip.file("file.txt").dir // false 34 | 35 | // utf8 example 36 | var zip = new JSZip(); 37 | zip.file("amount.txt", "€15"); 38 | zip.file("amount.txt").async("string") // a promise of "€15" 39 | zip.file("amount.txt").async("arraybuffer") // a promise of an ArrayBuffer containing €15 encoded as utf8 40 | zip.file("amount.txt").async("uint8array") // a promise of an Uint8Array containing €15 encoded as utf8 41 | 42 | // with folders 43 | zip.folder("sub").file("file.txt", "content"); 44 | zip.file("sub/file.txt"); // the file 45 | // or 46 | zip.folder("sub").file("file.txt") // the file 47 | ``` 48 | 49 | 50 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/file_regex.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "file(regex)" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Search a file in the current folder and subfolders with a 8 | [regular expression](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions). 9 | The regex is tested against the relative filename. 10 | 11 | __Returns__ : An array of matching files (an empty array if none matched). Each 12 | matching file is an instance of [ZipObject]({{site.baseurl}}/documentation/api_zipobject.html). 13 | 14 | __Since__: v1.0.0 15 | 16 | ## Arguments 17 | 18 | name | type | description 19 | ------|--------|------------ 20 | regex | RegExp | the regex to use. 21 | 22 | ## Example 23 | 24 | ```js 25 | var zip = new JSZip(); 26 | zip.file("file1.txt", "content"); 27 | zip.file("file2.txt", "content"); 28 | 29 | zip.file(/file/); // array of size 2 30 | 31 | // example with a relative path : 32 | var folder = zip.folder("sub"); 33 | folder 34 | .file("file3.txt", "content") // relative path from folder : file3.txt 35 | .file("file4.txt", "content"); // relative path from folder : file4.txt 36 | 37 | folder.file(/file/); // array of size 2 38 | folder.file(/^file/); // array of size 2, the relative paths start with file 39 | 40 | // arrays contain objects in the form: 41 | // {name: "file2.txt", dir: false, async : function () {...}, ...} 42 | ``` 43 | 44 | 45 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/filter.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "filter(predicate)" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Filter nested files/folders with the specified function. 8 | 9 | __Returns__ : An array of matching ZipObject. 10 | 11 | __Since__: v1.0.0 12 | 13 | ## Arguments 14 | 15 | name | type | description 16 | ----------|----------|------------ 17 | predicate | function | the predicate to use. 18 | 19 | The predicate has the following signature : `function (relativePath, file) {...}` : 20 | 21 | name | type | description 22 | -------------|-----------|------------ 23 | relativePath | string | the filename and its path, relative to the current folder. 24 | file | ZipObject | the file being tested. See [ZipObject]({{site.baseurl}}/documentation/api_zipobject.html). 25 | 26 | The predicate must return true if the file should be included, false otherwise. 27 | 28 | 29 | ## Examples 30 | 31 | ```js 32 | var zip = new JSZip().folder("dir"); 33 | zip.file("readme.txt", "content"); 34 | zip.filter(function (relativePath, file){ 35 | // relativePath == "readme.txt" 36 | // file = {name:"dir/readme.txt",options:{...},async:function} 37 | return true/false; 38 | }); 39 | ``` 40 | 41 | 42 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/folder_name.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "folder(name)" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Create a directory if it doesn't exist, return a new JSZip 8 | object with the new folder as root. 9 | 10 | See also [the `dir` option of file()]({{site.baseurl}}/documentation/api_jszip/file_data.html). 11 | 12 | __Returns__ : A new JSZip (for chaining), with the new folder as root. 13 | 14 | __Since__: v1.0.0 15 | 16 | ## Arguments 17 | 18 | name | type | description 19 | -----|--------|------------ 20 | name | string | the name of the directory. 21 | 22 | ## Examples 23 | 24 | ```js 25 | zip.folder("images"); 26 | zip.folder("css").file("style.css", "body {background: #FF0000}"); 27 | // or specify an absolute path (using forward slashes) 28 | zip.file("css/font.css", "body {font-family: sans-serif}") 29 | 30 | // result : images/, css/, css/style.css, css/font.css 31 | ``` 32 | 33 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/folder_regex.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "folder(regex)" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Search a subdirectory in the current directory with a 8 | [regular expression](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions). 9 | The regex is tested against the relative path. 10 | 11 | __Returns__ : An array of matching folders (an empty array if none matched). 12 | Each matching folder is an instance of [ZipObject]({{site.baseurl}}/documentation/api_zipobject.html). 13 | 14 | __Since__: v1.0.0 15 | 16 | ## Arguments 17 | 18 | name | type | description 19 | ------|--------|------------ 20 | regex | RegExp | the regex to use. 21 | 22 | ## Examples 23 | 24 | ```js 25 | var zip = new JSZip(); 26 | zip.folder("home/Pierre/videos"); 27 | zip.folder("home/Pierre/photos"); 28 | zip.folder("home/Jean/videos"); 29 | zip.folder("home/Jean/photos"); 30 | 31 | zip.folder(/videos/); // array of size 2 32 | 33 | zip.folder("home/Jean").folder(/^vid/); // array of 1 34 | ``` 35 | 36 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/for_each.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "forEach(callback)" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Call a callback function for each entry at this folder level. 8 | 9 | __Returns__ : Nothing. 10 | 11 | __Since__: v3.0.0 12 | 13 | ## Arguments 14 | 15 | name | type | description 16 | ----------|----------|------------ 17 | callback | function | the callback to use. 18 | 19 | The callback has the following signature : `function (relativePath, file) {...}` : 20 | 21 | name | type | description 22 | -------------|-----------|------------ 23 | relativePath | string | the filename and its path, relative to the current folder. 24 | file | ZipObject | the current file. See [ZipObject]({{site.baseurl}}/documentation/api_zipobject.html). 25 | 26 | 27 | ## Examples 28 | 29 | ```js 30 | var zip = new JSZip(); 31 | zip.file("package.json", "..."); 32 | zip.file("lib/index.js", "..."); 33 | zip.file("test/index.html", "..."); 34 | zip.file("test/asserts/file.js", "..."); 35 | zip.file("test/asserts/generate.js", "..."); 36 | 37 | zip.folder("test").forEach(function (relativePath, file){ 38 | console.log("iterating over", relativePath); 39 | }); 40 | 41 | // will display: 42 | // iterating over index.html 43 | // iterating over asserts/ 44 | // iterating over asserts/file.js 45 | // iterating over asserts/generate.js 46 | ``` 47 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/generate_internal_stream.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "generateInternalStream(options)" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Generates the complete zip file with the internal stream implementation. 8 | 9 | __Returns__ : a [StreamHelper]({{site.baseurl}}/documentation/api_streamhelper.html). 10 | 11 | __Since__: v3.0.0 12 | 13 | ## Arguments 14 | 15 | name | type | default | description 16 | --------------------|----------|---------|------------ 17 | options | object | | the options to generate the zip file, see [the options of `generateAsync()`]({{site.baseurl}}/documentation/api_jszip/generate_async.html) 18 | 19 | __Metadata__ : see [the metadata of `generateAsync()`]({{site.baseurl}}/documentation/api_jszip/generate_async.html#onupdate-callback). 20 | 21 | ## Examples 22 | 23 | ```js 24 | zip.generateInternalStream({type:"blob"}).accumulate(function callback(err, content) { 25 | if (err) { 26 | // handle error 27 | } 28 | // see FileSaver.js 29 | saveAs(content, "hello.zip"); 30 | }, function updateCallback(metadata) { 31 | // print progression with metadata.percent and metadata.currentFile 32 | }); 33 | ``` 34 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/generate_node_stream.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "generateNodeStream(options[, onUpdate])" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Generates the complete zip file as a nodejs stream. 8 | 9 | __Returns__ : a [nodejs Streams3](https://github.com/nodejs/readable-stream). 10 | 11 | __Since__: v3.0.0 12 | 13 | ## Arguments 14 | 15 | name | type | default | description 16 | --------------------|----------|---------|------------ 17 | options | object | | the options to generate the zip file, see [the options of `generateAsync()`]({{site.baseurl}}/documentation/api_jszip/generate_async.html) 18 | onUpdate | function | | The optional function called on each internal update with the metadata. 19 | 20 | The `type` parameter has here the default value of `nodebuffer`. 21 | Only `nodebuffer` is currently supported. 22 | 23 | __Metadata__ : see [the metadata of `generateAsync()`]({{site.baseurl}}/documentation/api_jszip/generate_async.html#onupdate-callback). 24 | 25 | ## Examples 26 | 27 | ```js 28 | zip 29 | .generateNodeStream({streamFiles:true}) 30 | .pipe(fs.createWriteStream('out.zip')) 31 | .on('finish', function () { 32 | // JSZip generates a readable stream with a "end" event, 33 | // but is piped here in a writable stream which emits a "finish" event. 34 | console.log("out.zip written."); 35 | }); 36 | ``` 37 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/load_async_object.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "JSZip.loadAsync(data [, options])" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | This is a shortcut for 8 | 9 | ```js 10 | var zip = new JSZip(); 11 | zip.loadAsync(data, options); 12 | ``` 13 | 14 | Please see the documentation of [loadAsync]({{site.baseurl}}/documentation/api_jszip/load_async.html). 15 | 16 | 17 | __Examples__ 18 | 19 | ```js 20 | dataAsPromise 21 | .then(JSZip.loadAsync) 22 | .then(function(zip) {...}) 23 | ``` 24 | 25 | same as: 26 | 27 | ```js 28 | JSZip.loadAsync(dataAsPromise) 29 | .then(function(zip) {...}) 30 | ``` 31 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/remove.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "remove(name)" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Delete a file or folder (recursively). 8 | 9 | __Returns__ : The current JSZip object. 10 | 11 | __Since__: v1.0.0 12 | 13 | ## Arguments 14 | 15 | name | type | description 16 | -----|--------|------------ 17 | name | string | the name of the file/folder to delete. 18 | 19 | ## Examples 20 | 21 | ```js 22 | var zip = new JSZip(); 23 | zip.file("Hello.txt", "Hello World\n"); 24 | zip.file("temp.txt", "nothing").remove("temp.txt"); 25 | // result : Hello.txt 26 | 27 | zip.folder("css").file("style.css", "body {background: #FF0000}"); 28 | zip.remove("css"); 29 | //result : empty zip 30 | ``` 31 | 32 | 33 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/support.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "JSZip.support" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | If the browser supports them, JSZip can take advantage of some "new" features : 8 | ArrayBuffer, Blob, Uint8Array. To know if JSZip can use them, you can check the 9 | JSZip.support object. It contains the following boolean properties : 10 | 11 | * `arraybuffer` : true if JSZip can read and generate ArrayBuffer, false otherwise. 12 | * `uint8array` : true if JSZip can read and generate Uint8Array, false otherwise. 13 | * `blob` : true if JSZip can generate Blob, false otherwise. 14 | * `nodebuffer` : true if JSZip can read and generate nodejs Buffer, false otherwise. 15 | * `nodestream` : true if JSZip can read and generate nodejs stream, false otherwise. 16 | 17 | 18 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_jszip/version.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "JSZip.version" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | The version of JSZip as a string. 8 | 9 | __Since__: v3.1.0 10 | 11 | ## Example 12 | 13 | ```js 14 | JSZip.version == "3.1.0"; 15 | ``` 16 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_streamhelper.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "StreamHelper API" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | A `StreamHelper` can be viewed as a pausable stream with some helper methods. 8 | It is not a full featured stream like in nodejs (and can't directly used as one) 9 | but the exposed methods should be enough to write the glue code with other async 10 | libraries : `on('data', function)`, `on('end', function)` and `on('error', function)`. 11 | 12 | It starts paused, be sure to `resume()` it when ready. 13 | 14 | If you are looking for an asynchronous helper without writing glue code, take a 15 | look at `accumulate(function)`. 16 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_streamhelper/accumulate.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "accumulate([updateCallback])" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Read the whole stream and call a callback with the complete content. 8 | 9 | __Returns__ : A [Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise) 10 | of the full content. 11 | 12 | __Since__: v3.0.0 13 | 14 | ## Arguments 15 | 16 | name | type | description 17 | ----------------|----------|------------ 18 | updateCallback | function | the function called every time the stream updates. This function is optional. 19 | 20 | 21 | The update callback function takes 1 parameter: the metadata (see the [`on` method]({{site.baseurl}}/documentation/api_streamhelper/on.html)). 22 | 23 | ## Example 24 | 25 | ```js 26 | zip 27 | .generateInternalStream({type:"uint8array"}) 28 | .accumulate(function updateCallback(metadata) { 29 | // metadata contains for example currentFile and percent, see the generateInternalStream doc. 30 | }).then(function (data) { 31 | // data contains here the complete zip file as a uint8array (the type asked in generateInternalStream) 32 | }); 33 | ``` 34 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_streamhelper/on.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "on(event, callback)" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Register a listener on an event. 8 | 9 | __Returns__ : The current StreamHelper object, for chaining. 10 | 11 | __Throws__ : An exception if the event is unknown. 12 | 13 | ## Arguments 14 | 15 | name | type | description 16 | ----------|----------|------------ 17 | event | string | the name of the event. Only 3 events are supported : `data`, `end` and `error`. 18 | callback | function | the function called when the event occurs. See below for the arguments. 19 | 20 | The callbacks are executed in with the current `StreamHelper` as `this`. 21 | 22 | ### `data` callback 23 | 24 | It takes 2 parameters: 25 | 26 | - the current chunk of data (in a format specified by the method which 27 | generated this StreamHelper) 28 | - the metadata (see each method to know what's inside) 29 | 30 | ### `end` callback 31 | 32 | It does not take any parameter. 33 | 34 | ### `error` callback 35 | 36 | It takes an `Error` as parameter. 37 | 38 | ## Example 39 | 40 | ```js 41 | zip 42 | .generateInternalStream({type:"uint8array"}) 43 | .on('data', function (data, metadata) { 44 | // data is a Uint8Array because that's the type asked in generateInternalStream 45 | // metadata contains for example currentFile and percent, see the generateInternalStream doc. 46 | }) 47 | .on('error', function (e) { 48 | // e is the error 49 | }) 50 | .on('end', function () { 51 | // no parameter 52 | }) 53 | .resume(); 54 | ``` 55 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_streamhelper/pause.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "pause()" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Pause the stream if the stream is running. Once paused, the 8 | stream stops sending `data` events. 9 | 10 | __Returns__ : The current StreamHelper object, for chaining. 11 | 12 | ## Example 13 | 14 | ```js 15 | zip 16 | .generateInternalStream({type:"uint8array"}) 17 | .on('data', function(chunk) { 18 | 19 | // if we push the chunk to an other service which is overloaded, we can 20 | // pause the stream as backpressure. 21 | this.pause(); 22 | 23 | }).resume(); // start the stream the first time 24 | ``` 25 | 26 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_streamhelper/resume.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "resume()" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Resume the stream if the stream is paused. Once resumed, the stream starts 8 | sending `data` events again. 9 | 10 | __Returns__ : The current StreamHelper object, for chaining. 11 | 12 | __Since__: v3.0.0 13 | 14 | ## Example 15 | 16 | ```js 17 | zip 18 | .generateInternalStream({type:"uint8array"}) 19 | .on('data', function() {...}) 20 | .resume(); 21 | ``` 22 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_zipobject.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "ZipObject API" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | This represents an entry in the zip file. If the entry comes from an existing 8 | archive previously [loaded]({{site.baseurl}}/documentation/api_jszip/load_async.html), the content 9 | will be automatically decompressed/converted first. 10 | 11 | ### Attributes 12 | 13 | attribute name | type | description 14 | ----------------------------|-------------|------------- 15 | `name` | string | the absolute path of the file 16 | `dir` | boolean | true if this is a directory 17 | `date` | date | the last modification date 18 | `comment` | string | the comment for this file 19 | `unixPermissions` | 16 bits number | The UNIX permissions of the file, if any. 20 | `dosPermissions` | 6 bits number | The DOS permissions of the file, if any. 21 | `options` | object | the options of the file. The available options are : 22 | `options.compression` | compression | see [file(name, data [,options])]({{site.baseurl}}/documentation/api_jszip/file_data.html) 23 | 24 | Example: 25 | 26 | ```js 27 | { name: 'docs/', 28 | dir: true, 29 | date: 2016-12-25T08:09:27.153Z, 30 | comment: null, 31 | unixPermissions: 16877, 32 | dosPermissions: null, 33 | options: { 34 | compression: 'STORE', 35 | compressionOptions: null 36 | } 37 | } 38 | ``` 39 | 40 | ```js 41 | { name: 'docs/list.txt', 42 | dir: false, 43 | date: 2016-12-25T08:09:27.152Z, 44 | comment: null, 45 | unixPermissions: 33206, 46 | dosPermissions: null, 47 | options: { 48 | compression: 'DEFLATE', 49 | compressionOptions: null 50 | } 51 | } 52 | ``` 53 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_zipobject/async.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "async(type[, onUpdate])" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Return a [Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise) of the content in the asked type. 8 | 9 | __Returns__ : A [Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise) of the content. 10 | 11 | __Since__: v3.0.0 12 | 13 | ## Arguments 14 | 15 | name | type | description 16 | ---------|----------|------------ 17 | type | String | the type of the result. [More](#type-option). 18 | onUpdate | Function | an optional function called on each internal update with the metadata. [More](#onupdate-callback). 19 | 20 | ### `type` option 21 | 22 | Possible values for `type` : 23 | 24 | * `base64` : the result will be a string, the binary in a base64 form. 25 | * `text` (or `string`): the result will be an unicode string. 26 | * `binarystring`: the result will be a string in "binary" form, using 1 byte per char (2 bytes). 27 | * `array`: the result will be an Array of bytes (numbers between 0 and 255). 28 | * `uint8array` : the result will be a Uint8Array. This requires a compatible browser. 29 | * `arraybuffer` : the result will be a ArrayBuffer. This requires a compatible browser. 30 | * `blob` : the result will be a Blob. This requires a compatible browser. 31 | * `nodebuffer` : the result will be a nodejs Buffer. This requires nodejs. 32 | 33 | Note : when using type = "uint8array", "arraybuffer" or "blob", be sure to 34 | check if the browser supports it (you can use [`JSZip.support`]({{site.baseurl}}/documentation/api_jszip/support.html)). 35 | 36 | ```js 37 | zip.file("image.png").async("uint8array").then(function (u8) { 38 | // ... 39 | }); 40 | ``` 41 | 42 | ### `onUpdate` callback 43 | 44 | If specified, this function will be called each time a chunk is pushed to the 45 | output stream (or internally accumulated). 46 | 47 | The function takes a `metadata` object which contains informations about the 48 | ongoing process. 49 | 50 | __Metadata__ : the metadata are : 51 | 52 | name | type | description 53 | ------------|--------|------------ 54 | percent | number | the percent of completion (a double between 0 and 100) 55 | 56 | ```js 57 | zip.file("image.png").async("uint8array", function updateCallback(metadata) { 58 | console.log("progression: " + metadata.percent.toFixed(2) + " %"); 59 | }).then(function (u8) { 60 | // ... 61 | }) 62 | ``` 63 | 64 | 65 | ## Other examples 66 | 67 | ```js 68 | zip 69 | .file("my_text.txt") 70 | .async("string") 71 | .then(function success(content) { 72 | // use the content 73 | }, function error(e) { 74 | // handle the error 75 | }); 76 | ``` 77 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_zipobject/internal_stream.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "internalStream(type)" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Return a [StreamHelper]({{site.baseurl}}/documentation/api_streamhelper.html) 8 | of the content in the asked type. 9 | 10 | __Returns__ : a [StreamHelper]({{site.baseurl}}/documentation/api_streamhelper.html) 11 | of the content in the asked type. 12 | 13 | ## Arguments 14 | 15 | name | type | description 16 | ---------|----------|------------ 17 | type | String | the type of the result: `string`, `binarystring`, `uint8array`, `arraybuffer`, `nodebuffer`. 18 | 19 | 20 | ## Example 21 | 22 | ```js 23 | zip 24 | .file("my_text.txt") 25 | .internalStream("string") 26 | .on("data", function (data) {...}) 27 | .on("error", function (e) {...}) 28 | .on("end", function () {...}); 29 | ``` 30 | 31 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/api_zipobject/node_stream.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "nodeStream(type[, onUpdate])" 3 | layout: default 4 | section: api 5 | --- 6 | 7 | Return a [nodejs Streams3](https://github.com/nodejs/readable-stream) 8 | of the content in the asked type. 9 | 10 | __Returns__ : a [nodejs Streams3](https://github.com/nodejs/readable-stream). 11 | 12 | ## Arguments 13 | 14 | name | type | default | description 15 | ---------|----------|--------------|------------ 16 | type | String | `nodebuffer` | only `nodebuffer` is currently supported. 17 | onUpdate | Function | | an optional function called on each internal update with the metadata. 18 | 19 | __Metadata__ : see [the metadata of `async()`]({{site.baseurl}}/documentation/api_zipobject/async.html#onupdate-callback). 20 | 21 | ## Example 22 | 23 | ```js 24 | zip 25 | .file("my_text.txt") 26 | .nodeStream() 27 | .pipe(fs.createWriteStream('/tmp/my_text.txt')) 28 | .on('finish', function () { 29 | // JSZip generates a readable stream with a "end" event, 30 | // but is piped here in a writable stream which emits a "finish" event. 31 | console.log("text file written."); 32 | }); 33 | ``` 34 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/contributing.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Contributing 3 | layout: default 4 | section: main 5 | --- 6 | 7 | 8 | ### Download the sources 9 | 10 | You should create a [Github](https://github.com/) account and 11 | [fork the repository](https://help.github.com/articles/fork-a-repo) (you will 12 | need one to create the pull request). 13 | 14 | If you just want the get the source code, you can use git and do 15 | `git clone https://github.com/Stuk/jszip.git` to get the sources. You can also 16 | download the latest sources [here](https://github.com/Stuk/jszip/archive/master.zip). 17 | 18 | ### Building the project 19 | 20 | #### Code 21 | 22 | The dependencies are handled by npm, the first step is to run 23 | `npm install` to get the dependencies. 24 | JSZip uses Grunt to handle the build, [see here to install its CLI](http://gruntjs.com/getting-started). 25 | 26 | Here are the interesting build commands : 27 | 28 | * `grunt` will generate the final js file in dist/ and the minified version. 29 | * `npm run test-node` will run the tests in nodejs. 30 | * `npm run test-browser` will the tests in some browsers using SauceLabs, see 31 | below. 32 | * `npm run test` will run the tests in nodejs and in the browser. 33 | * `npm run lint` will use jshint the check the source code. 34 | 35 | #### Documentation 36 | 37 | The documentation uses jekyll on gh-pages. To render the documentation, you 38 | need to [install jekyll](http://jekyllrb.com/docs/installation/) and then run 39 | `jekyll serve --baseurl ''`. 40 | 41 | ### Testing the project 42 | 43 | To test JSZip in nodejs, use `npm run test-node`. 44 | 45 | To test JSZip in a browser, you can open the file `test/index.html` in the 46 | browser you want to test. Don't forget to update the dist/ files with `grunt`. 47 | 48 | You can also test JSZip in a lot of browsers at once with 49 | [SauceLabs](https://saucelabs.com/). You will need a SauceLabs account and two 50 | variables into your environment. On linux, just use 51 | 52 | ```bash 53 | export SAUCE_USERNAME=your-saucelabs-username 54 | export SAUCE_ACCESS_KEY=your-saucelabs-access-key 55 | ``` 56 | 57 | before running the `npm run test-browser` command. 58 | 59 | ### Merging the changes 60 | 61 | If you have tested bug fixes or new features, you can open a 62 | [pull request](https://help.github.com/articles/using-pull-requests) on Github. 63 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/css/main.css: -------------------------------------------------------------------------------- 1 | ul.nav ul { 2 | list-style:none; 3 | margin: 0; 4 | padding: 0 0 0 25px; 5 | } 6 | 7 | #downloader_application form { 8 | margin-bottom: 10px; 9 | } 10 | 11 | #downloader_application ul { 12 | list-style-type: none; 13 | } 14 | 15 | .browser_support th { 16 | border-bottom-width: 3px !important; 17 | } 18 | 19 | .support_ie {border-bottom-color: #0275BA !important;} 20 | .support_ff {border-bottom-color: #DF7215 !important;} 21 | .support_sf {border-bottom-color: #43B3E9 !important;} 22 | .support_cr {border-bottom-color: #39B642 !important;} 23 | .support_op {border-bottom-color: #C42122 !important;} 24 | .support_nd {border-bottom-color: #8CC84B !important;} 25 | 26 | .show-example { 27 | padding: 10px; 28 | border: 1px solid #ccc; 29 | border-radius: 4px; 30 | margin: 0 0 10px; 31 | } 32 | 33 | .tab-pane > figure.highlight > pre, .tab-pane > .show-example { 34 | border-radius: 0 0 4px 4px; 35 | border-top: 0px; 36 | } 37 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/css/pygments.css: -------------------------------------------------------------------------------- 1 | /* Generated with : 2 | * pygmentize -S default -f html > pygments.css 3 | */ 4 | .hll { background-color: #ffffcc } 5 | .c { color: #408080; font-style: italic } /* Comment */ 6 | .err { border: 1px solid #FF0000 } /* Error */ 7 | .k { color: #008000; font-weight: bold } /* Keyword */ 8 | .o { color: #666666 } /* Operator */ 9 | .cm { color: #408080; font-style: italic } /* Comment.Multiline */ 10 | .cp { color: #BC7A00 } /* Comment.Preproc */ 11 | .c1 { color: #408080; font-style: italic } /* Comment.Single */ 12 | .cs { color: #408080; font-style: italic } /* Comment.Special */ 13 | .gd { color: #A00000 } /* Generic.Deleted */ 14 | .ge { font-style: italic } /* Generic.Emph */ 15 | .gr { color: #FF0000 } /* Generic.Error */ 16 | .gh { color: #000080; font-weight: bold } /* Generic.Heading */ 17 | .gi { color: #00A000 } /* Generic.Inserted */ 18 | .go { color: #888888 } /* Generic.Output */ 19 | .gp { color: #000080; font-weight: bold } /* Generic.Prompt */ 20 | .gs { font-weight: bold } /* Generic.Strong */ 21 | .gu { color: #800080; font-weight: bold } /* Generic.Subheading */ 22 | .gt { color: #0044DD } /* Generic.Traceback */ 23 | .kc { color: #008000; font-weight: bold } /* Keyword.Constant */ 24 | .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */ 25 | .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */ 26 | .kp { color: #008000 } /* Keyword.Pseudo */ 27 | .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */ 28 | .kt { color: #B00040 } /* Keyword.Type */ 29 | .m { color: #666666 } /* Literal.Number */ 30 | .s { color: #BA2121 } /* Literal.String */ 31 | .na { color: #7D9029 } /* Name.Attribute */ 32 | .nb { color: #008000 } /* Name.Builtin */ 33 | .nc { color: #0000FF; font-weight: bold } /* Name.Class */ 34 | .no { color: #880000 } /* Name.Constant */ 35 | .nd { color: #AA22FF } /* Name.Decorator */ 36 | .ni { color: #999999; font-weight: bold } /* Name.Entity */ 37 | .ne { color: #D2413A; font-weight: bold } /* Name.Exception */ 38 | .nf { color: #0000FF } /* Name.Function */ 39 | .nl { color: #A0A000 } /* Name.Label */ 40 | .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */ 41 | .nt { color: #008000; font-weight: bold } /* Name.Tag */ 42 | .nv { color: #19177C } /* Name.Variable */ 43 | .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */ 44 | .w { color: #bbbbbb } /* Text.Whitespace */ 45 | .mf { color: #666666 } /* Literal.Number.Float */ 46 | .mh { color: #666666 } /* Literal.Number.Hex */ 47 | .mi { color: #666666 } /* Literal.Number.Integer */ 48 | .mo { color: #666666 } /* Literal.Number.Oct */ 49 | .sb { color: #BA2121 } /* Literal.String.Backtick */ 50 | .sc { color: #BA2121 } /* Literal.String.Char */ 51 | .sd { color: #BA2121; font-style: italic } /* Literal.String.Doc */ 52 | .s2 { color: #BA2121 } /* Literal.String.Double */ 53 | .se { color: #BB6622; font-weight: bold } /* Literal.String.Escape */ 54 | .sh { color: #BA2121 } /* Literal.String.Heredoc */ 55 | .si { color: #BB6688; font-weight: bold } /* Literal.String.Interpol */ 56 | .sx { color: #008000 } /* Literal.String.Other */ 57 | .sr { color: #BB6688 } /* Literal.String.Regex */ 58 | .s1 { color: #BA2121 } /* Literal.String.Single */ 59 | .ss { color: #19177C } /* Literal.String.Symbol */ 60 | .bp { color: #008000 } /* Name.Builtin.Pseudo */ 61 | .vc { color: #19177C } /* Name.Variable.Class */ 62 | .vg { color: #19177C } /* Name.Variable.Global */ 63 | .vi { color: #19177C } /* Name.Variable.Instance */ 64 | .il { color: #666666 } /* Literal.Number.Integer.Long */ 65 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/download-zip-file.html: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Download the generated zip file" 3 | layout: default 4 | section: example 5 | --- 6 | 7 |

The FileSaver API

8 | 25 |
26 |
27 |
28 | {% include_relative download-zip-file.inc/blob.html %} 29 |
30 |
31 |
32 | {% highlight js %} 33 | {% include_relative download-zip-file.inc/blob.js %} 34 | {% endhighlight %} 35 |
36 |
37 | {% highlight html %} 38 | {% include_relative download-zip-file.inc/blob.html %} 39 | {% endhighlight %} 40 |
41 |
42 | 43 |

The data URL

44 | 61 |
62 |
63 |
64 | {% include_relative download-zip-file.inc/data_uri.html %} 65 |
66 |
67 |
68 | {% highlight js %} 69 | {% include_relative download-zip-file.inc/data_uri.js %} 70 | {% endhighlight %} 71 |
72 |
73 | {% highlight html %} 74 | {% include_relative download-zip-file.inc/data_uri.html %} 75 | {% endhighlight %} 76 |
77 |
78 | 79 | 94 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/download-zip-file.inc/blob.html: -------------------------------------------------------------------------------- 1 |

Works on firefox, chrome , opera >= 15 and IE >= 10 (but NOT in compatibility view).

2 | 3 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/download-zip-file.inc/blob.js: -------------------------------------------------------------------------------- 1 | var zip = new JSZip(); 2 | zip.file("Hello.txt", "Hello world\n"); 3 | 4 | jQuery("#blob").on("click", function () { 5 | zip.generateAsync({type:"blob"}).then(function (blob) { // 1) generate the zip file 6 | saveAs(blob, "hello.zip"); // 2) trigger the download 7 | }, function (err) { 8 | jQuery("#blob").text(err); 9 | }); 10 | }); 11 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/download-zip-file.inc/data_uri.html: -------------------------------------------------------------------------------- 1 |

Does not work in IE, has restrictions on the length.

2 | 3 | 4 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/download-zip-file.inc/data_uri.js: -------------------------------------------------------------------------------- 1 | var zip = new JSZip(); 2 | zip.file("Hello.txt", "Hello world\n"); 3 | 4 | jQuery("#data_uri").on("click", function () { 5 | zip.generateAsync({type:"base64"}).then(function (base64) { 6 | window.location = "data:application/zip;base64," + base64; 7 | }, function (err) { 8 | jQuery("#data_uri").text(err); 9 | }); 10 | }); 11 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/downloader.html: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Mini app : Downloader" 3 | layout: default 4 | section: example 5 | --- 6 | 7 |

8 | This mini application let you choose the files you want in a list, download 9 | them, zip them and give the result to the user. 10 |

11 |

12 | This demo requires a recent browser, see 13 | the howto. 14 |

15 |

16 | This demo depends on the following libraries: 17 |

22 |

23 | 24 | 25 | 47 |
48 |
49 |
50 |
51 | {% include_relative downloader.inc/downloader.html %} 52 |
53 |
54 |
55 |
56 | {% highlight js %} 57 | {% include_relative downloader.inc/downloader.js %} 58 | {% endhighlight %} 59 |
60 |
61 | {% highlight js %} 62 | {% include_relative downloader.inc/helpers.js %} 63 | {% endhighlight %} 64 |
65 |
66 | {% highlight html %} 67 | {% include_relative downloader.inc/downloader.html %} 68 | {% endhighlight %} 69 |
70 |
71 | 72 | 78 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/downloader.inc/downloader.html: -------------------------------------------------------------------------------- 1 |

Please select your files

2 |
3 |
    4 |
  • 5 | 9 |
  • 10 |
  • 11 | 15 |
  • 16 |
  • 17 | 21 |
  • 22 |
  • 23 | 27 |
  • 28 |
29 | 30 | 31 |
32 | 33 |
34 |
35 |
36 |
37 | 38 |

39 | 40 | 41 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/downloader.inc/downloader.js: -------------------------------------------------------------------------------- 1 | 2 | var Promise = window.Promise; 3 | if (!Promise) { 4 | Promise = JSZip.external.Promise; 5 | } 6 | 7 | /** 8 | * Fetch the content and return the associated promise. 9 | * @param {String} url the url of the content to fetch. 10 | * @return {Promise} the promise containing the data. 11 | */ 12 | function urlToPromise(url) { 13 | return new Promise(function(resolve, reject) { 14 | JSZipUtils.getBinaryContent(url, function (err, data) { 15 | if(err) { 16 | reject(err); 17 | } else { 18 | resolve(data); 19 | } 20 | }); 21 | }); 22 | } 23 | 24 | var $form = $("#download_form").on("submit", function () { 25 | 26 | resetMessage(); 27 | 28 | var zip = new JSZip(); 29 | 30 | // find every checked item 31 | $(this).find(":checked").each(function () { 32 | var $this = $(this); 33 | var url = $this.data("url"); 34 | var filename = url.replace(/.*\//g, ""); 35 | zip.file(filename, urlToPromise(url), {binary:true}); 36 | }); 37 | 38 | // when everything has been downloaded, we can trigger the dl 39 | zip.generateAsync({type:"blob"}, function updateCallback(metadata) { 40 | var msg = "progression : " + metadata.percent.toFixed(2) + " %"; 41 | if(metadata.currentFile) { 42 | msg += ", current file = " + metadata.currentFile; 43 | } 44 | showMessage(msg); 45 | updatePercent(metadata.percent|0); 46 | }) 47 | .then(function callback(blob) { 48 | 49 | // see FileSaver.js 50 | saveAs(blob, "example.zip"); 51 | 52 | showMessage("done !"); 53 | }, function (e) { 54 | showError(e); 55 | }); 56 | 57 | return false; 58 | }); 59 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/downloader.inc/helpers.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Reset the message. 3 | */ 4 | function resetMessage () { 5 | $("#result") 6 | .removeClass() 7 | .text(""); 8 | } 9 | /** 10 | * show a successful message. 11 | * @param {String} text the text to show. 12 | */ 13 | function showMessage(text) { 14 | resetMessage(); 15 | $("#result") 16 | .addClass("alert alert-success") 17 | .text(text); 18 | } 19 | /** 20 | * show an error message. 21 | * @param {String} text the text to show. 22 | */ 23 | function showError(text) { 24 | resetMessage(); 25 | $("#result") 26 | .addClass("alert alert-danger") 27 | .text(text); 28 | } 29 | /** 30 | * Update the progress bar. 31 | * @param {Integer} percent the current percent 32 | */ 33 | function updatePercent(percent) { 34 | $("#progress_bar").removeClass("hide") 35 | .find(".progress-bar") 36 | .attr("aria-valuenow", percent) 37 | .css({ 38 | width : percent + "%" 39 | }); 40 | } 41 | 42 | if(!JSZip.support.blob) { 43 | showError("This demo works only with a recent browser !"); 44 | return; 45 | } 46 | 47 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/get-binary-files-ajax.inc/fetch_api.html: -------------------------------------------------------------------------------- 1 |
2 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/get-binary-files-ajax.inc/fetch_api.js: -------------------------------------------------------------------------------- 1 | fetch('{{site.baseurl}}/test/ref/text.zip') // 1) fetch the url 2 | .then(function (response) { // 2) filter on 200 OK 3 | if (response.status === 200 || response.status === 0) { 4 | return Promise.resolve(response.blob()); 5 | } else { 6 | return Promise.reject(new Error(response.statusText)); 7 | } 8 | }) 9 | .then(JSZip.loadAsync) // 3) chain with the zip promise 10 | .then(function (zip) { 11 | return zip.file("Hello.txt").async("string"); // 4) chain with the text content promise 12 | }) 13 | .then(function success(text) { // 5) display the result 14 | $("#fetch").append($("

", { 15 | "class": "alert alert-success", 16 | text: "loaded, content = " + text 17 | })); 18 | }, function error(e) { 19 | $("#fetch").append($("

", { 20 | "class": "alert alert-danger", 21 | text: e 22 | })); 23 | }); 24 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/get-binary-files-ajax.inc/jszip_utils.html: -------------------------------------------------------------------------------- 1 |

2 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/get-binary-files-ajax.inc/jszip_utils.js: -------------------------------------------------------------------------------- 1 | // 1) get a promise of the content 2 | var promise = new JSZip.external.Promise(function (resolve, reject) { 3 | JSZipUtils.getBinaryContent('{{site.baseurl}}/test/ref/text.zip', function(err, data) { 4 | if (err) { 5 | reject(err); 6 | } else { 7 | resolve(data); 8 | } 9 | }); 10 | }); 11 | 12 | promise.then(JSZip.loadAsync) // 2) chain with the zip promise 13 | .then(function(zip) { 14 | return zip.file("Hello.txt").async("string"); // 3) chain with the text content promise 15 | }) 16 | .then(function success(text) { // 4) display the result 17 | $("#jszip_utils").append($("

", { 18 | "class": "alert alert-success", 19 | text: "loaded, content = " + text 20 | })); 21 | }, function error(e) { 22 | $("#jszip_utils").append($("

", { 23 | "class": "alert alert-danger", 24 | text: e 25 | })); 26 | }); 27 | 28 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/read-local-file-api.html: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Reading a local file with the File API" 3 | layout: default 4 | section: example 5 | --- 6 | 7 |

24 |
25 |
26 |
27 | {% include_relative read-local-file-api.inc/read.html %} 28 |
29 |
30 |
31 | {% highlight js %} 32 | {% include_relative read-local-file-api.inc/read.js %} 33 | {% endhighlight %} 34 |
35 |
36 | {% highlight html %} 37 | {% include_relative read-local-file-api.inc/read.html %} 38 | {% endhighlight %} 39 |
40 |
41 | 42 | 45 | 56 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/read-local-file-api.inc/read.html: -------------------------------------------------------------------------------- 1 |

Choose the local(s) zip file(s)

2 |

Note : your browser will process the zip file, don't choose a file too big !

3 |
4 | 5 | 9 | 10 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/examples/read-local-file-api.inc/read.js: -------------------------------------------------------------------------------- 1 | var $result = $("#result"); 2 | $("#file").on("change", function(evt) { 3 | // remove content 4 | $result.html(""); 5 | // be sure to show the results 6 | $("#result_block").removeClass("hidden").addClass("show"); 7 | 8 | // Closure to capture the file information. 9 | function handleFile(f) { 10 | var $title = $("

", { 11 | text : f.name 12 | }); 13 | var $fileContent = $("
    "); 14 | $result.append($title); 15 | $result.append($fileContent); 16 | 17 | var dateBefore = new Date(); 18 | JSZip.loadAsync(f) // 1) read the Blob 19 | .then(function(zip) { 20 | var dateAfter = new Date(); 21 | $title.append($("", { 22 | "class": "small", 23 | text:" (loaded in " + (dateAfter - dateBefore) + "ms)" 24 | })); 25 | 26 | zip.forEach(function (relativePath, zipEntry) { // 2) print entries 27 | $fileContent.append($("
  • ", { 28 | text : zipEntry.name 29 | })); 30 | }); 31 | }, function (e) { 32 | $result.append($("
    ", { 33 | "class" : "alert alert-danger", 34 | text : "Error reading " + f.name + ": " + e.message 35 | })); 36 | }); 37 | } 38 | 39 | var files = evt.target.files; 40 | for (var i = 0; i < files.length; i++) { 41 | handleFile(files[i]); 42 | } 43 | }); 44 | 45 | -------------------------------------------------------------------------------- /bower_components/jszip/documentation/faq.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Frequently Asked Questions" 3 | layout: default 4 | section: main 5 | --- 6 | 7 | ### "Corrupted zip or bug: unexpected signature" 8 | 9 | If you are sure that the zip file is correct, that error often comes from a 10 | corrupted content. An ajax request, if not prepared correctly, will try to 11 | decode the binary content as a text and corrupt it. See 12 | [this page]({{site.baseurl}}/documentation/howto/read_zip.html). 13 | 14 | ### My browser crashes / becomes unresponsive / never finish the execution 15 | 16 | That happens if you try to handle to much data with the synchronous API. If 17 | possible, try the asynchronous API, see 18 | [this page]({{site.baseurl}}/documentation/limitations.html) for more informations. 19 | 20 | ### Can't read the data of [...]. Is it in a supported JavaScript type ? 21 | 22 | Or the old message: 23 | 24 | > The data of [...] is in an unsupported format 25 | 26 | The method [`file(name, data [,options])`]({{site.baseurl}}/documentation/api_jszip/file_data.html) 27 | accepts string and binary inputs for `data`. 28 | 29 | If you use an unsupported type, an object for example, you will get this error: 30 | 31 | ```js 32 | // WRONG 33 | var data = { 34 | content: new ArrayBuffer(...) 35 | }; 36 | zip.file("my.data", data); // won't work, data is an object 37 | 38 | // CORRECT 39 | var data = new ArrayBuffer(...); 40 | zip.file("my.data", data); // will work, JSZip accepts ArrayBuffer 41 | ``` 42 | 43 | ### My mac generates a `.cpgz` file when I try to extract the zip file 44 | 45 | MacOS Finder has a lot of bug related to zip files (the `unzip` command line 46 | tool is fine). When something goes wrong, Finder will generate this cpgz file 47 | instead of showing an error. 48 | 49 | To get a correct result, try to enable compression in `generateAsync`: 50 | 51 | ```js 52 | zip.generateAsync({ 53 | type:"...", 54 | compression: "DEFLATE" // <-- here 55 | }); 56 | ``` 57 | 58 | Using `platform: "UNIX"` may help too. 59 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/compressedObject.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var external = require("./external"); 4 | var DataWorker = require('./stream/DataWorker'); 5 | var DataLengthProbe = require('./stream/DataLengthProbe'); 6 | var Crc32Probe = require('./stream/Crc32Probe'); 7 | var DataLengthProbe = require('./stream/DataLengthProbe'); 8 | 9 | /** 10 | * Represent a compressed object, with everything needed to decompress it. 11 | * @constructor 12 | * @param {number} compressedSize the size of the data compressed. 13 | * @param {number} uncompressedSize the size of the data after decompression. 14 | * @param {number} crc32 the crc32 of the decompressed file. 15 | * @param {object} compression the type of compression, see lib/compressions.js. 16 | * @param {String|ArrayBuffer|Uint8Array|Buffer} data the compressed data. 17 | */ 18 | function CompressedObject(compressedSize, uncompressedSize, crc32, compression, data) { 19 | this.compressedSize = compressedSize; 20 | this.uncompressedSize = uncompressedSize; 21 | this.crc32 = crc32; 22 | this.compression = compression; 23 | this.compressedContent = data; 24 | } 25 | 26 | CompressedObject.prototype = { 27 | /** 28 | * Create a worker to get the uncompressed content. 29 | * @return {GenericWorker} the worker. 30 | */ 31 | getContentWorker : function () { 32 | var worker = new DataWorker(external.Promise.resolve(this.compressedContent)) 33 | .pipe(this.compression.uncompressWorker()) 34 | .pipe(new DataLengthProbe("data_length")); 35 | 36 | var that = this; 37 | worker.on("end", function () { 38 | if(this.streamInfo['data_length'] !== that.uncompressedSize) { 39 | throw new Error("Bug : uncompressed data size mismatch"); 40 | } 41 | }); 42 | return worker; 43 | }, 44 | /** 45 | * Create a worker to get the compressed content. 46 | * @return {GenericWorker} the worker. 47 | */ 48 | getCompressedWorker : function () { 49 | return new DataWorker(external.Promise.resolve(this.compressedContent)) 50 | .withStreamInfo("compressedSize", this.compressedSize) 51 | .withStreamInfo("uncompressedSize", this.uncompressedSize) 52 | .withStreamInfo("crc32", this.crc32) 53 | .withStreamInfo("compression", this.compression) 54 | ; 55 | } 56 | }; 57 | 58 | /** 59 | * Chain the given worker with other workers to compress the content with the 60 | * given compresion. 61 | * @param {GenericWorker} uncompressedWorker the worker to pipe. 62 | * @param {Object} compression the compression object. 63 | * @param {Object} compressionOptions the options to use when compressing. 64 | * @return {GenericWorker} the new worker compressing the content. 65 | */ 66 | CompressedObject.createWorkerFrom = function (uncompressedWorker, compression, compressionOptions) { 67 | return uncompressedWorker 68 | .pipe(new Crc32Probe()) 69 | .pipe(new DataLengthProbe("uncompressedSize")) 70 | .pipe(compression.compressWorker(compressionOptions)) 71 | .pipe(new DataLengthProbe("compressedSize")) 72 | .withStreamInfo("compression", compression); 73 | }; 74 | 75 | module.exports = CompressedObject; 76 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/compressions.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var GenericWorker = require("./stream/GenericWorker"); 4 | 5 | exports.STORE = { 6 | magic: "\x00\x00", 7 | compressWorker : function (compressionOptions) { 8 | return new GenericWorker("STORE compression"); 9 | }, 10 | uncompressWorker : function () { 11 | return new GenericWorker("STORE decompression"); 12 | } 13 | }; 14 | exports.DEFLATE = require('./flate'); 15 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/crc32.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var utils = require('./utils'); 4 | 5 | /** 6 | * The following functions come from pako, from pako/lib/zlib/crc32.js 7 | * released under the MIT license, see pako https://github.com/nodeca/pako/ 8 | */ 9 | 10 | // Use ordinary array, since untyped makes no boost here 11 | function makeTable() { 12 | var c, table = []; 13 | 14 | for(var n =0; n < 256; n++){ 15 | c = n; 16 | for(var k =0; k < 8; k++){ 17 | c = ((c&1) ? (0xEDB88320 ^ (c >>> 1)) : (c >>> 1)); 18 | } 19 | table[n] = c; 20 | } 21 | 22 | return table; 23 | } 24 | 25 | // Create table on load. Just 255 signed longs. Not a problem. 26 | var crcTable = makeTable(); 27 | 28 | 29 | function crc32(crc, buf, len, pos) { 30 | var t = crcTable, end = pos + len; 31 | 32 | crc = crc ^ (-1); 33 | 34 | for (var i = pos; i < end; i++ ) { 35 | crc = (crc >>> 8) ^ t[(crc ^ buf[i]) & 0xFF]; 36 | } 37 | 38 | return (crc ^ (-1)); // >>> 0; 39 | } 40 | 41 | // That's all for the pako functions. 42 | 43 | /** 44 | * Compute the crc32 of a string. 45 | * This is almost the same as the function crc32, but for strings. Using the 46 | * same function for the two use cases leads to horrible performances. 47 | * @param {Number} crc the starting value of the crc. 48 | * @param {String} str the string to use. 49 | * @param {Number} len the length of the string. 50 | * @param {Number} pos the starting position for the crc32 computation. 51 | * @return {Number} the computed crc32. 52 | */ 53 | function crc32str(crc, str, len, pos) { 54 | var t = crcTable, end = pos + len; 55 | 56 | crc = crc ^ (-1); 57 | 58 | for (var i = pos; i < end; i++ ) { 59 | crc = (crc >>> 8) ^ t[(crc ^ str.charCodeAt(i)) & 0xFF]; 60 | } 61 | 62 | return (crc ^ (-1)); // >>> 0; 63 | } 64 | 65 | module.exports = function crc32wrapper(input, crc) { 66 | if (typeof input === "undefined" || !input.length) { 67 | return 0; 68 | } 69 | 70 | var isArray = utils.getTypeOf(input) !== "string"; 71 | 72 | if(isArray) { 73 | return crc32(crc|0, input, input.length, 0); 74 | } else { 75 | return crc32str(crc|0, input, input.length, 0); 76 | } 77 | }; 78 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/defaults.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | exports.base64 = false; 3 | exports.binary = false; 4 | exports.dir = false; 5 | exports.createFolders = true; 6 | exports.date = null; 7 | exports.compression = null; 8 | exports.compressionOptions = null; 9 | exports.comment = null; 10 | exports.unixPermissions = null; 11 | exports.dosPermissions = null; 12 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/external.js: -------------------------------------------------------------------------------- 1 | /* global Promise */ 2 | 'use strict'; 3 | 4 | // load the global object first: 5 | // - it should be better integrated in the system (unhandledRejection in node) 6 | // - the environment may have a custom Promise implementation (see zone.js) 7 | var ES6Promise = null; 8 | if (typeof Promise !== "undefined") { 9 | ES6Promise = Promise; 10 | } else { 11 | ES6Promise = require("lie"); 12 | } 13 | 14 | /** 15 | * Let the user use/change some implementations. 16 | */ 17 | module.exports = { 18 | Promise: ES6Promise 19 | }; 20 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/flate.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | var USE_TYPEDARRAY = (typeof Uint8Array !== 'undefined') && (typeof Uint16Array !== 'undefined') && (typeof Uint32Array !== 'undefined'); 3 | 4 | var pako = require("pako"); 5 | var utils = require("./utils"); 6 | var GenericWorker = require("./stream/GenericWorker"); 7 | 8 | var ARRAY_TYPE = USE_TYPEDARRAY ? "uint8array" : "array"; 9 | 10 | exports.magic = "\x08\x00"; 11 | 12 | /** 13 | * Create a worker that uses pako to inflate/deflate. 14 | * @constructor 15 | * @param {String} action the name of the pako function to call : either "Deflate" or "Inflate". 16 | * @param {Object} options the options to use when (de)compressing. 17 | */ 18 | function FlateWorker(action, options) { 19 | GenericWorker.call(this, "FlateWorker/" + action); 20 | 21 | this._pako = null; 22 | this._pakoAction = action; 23 | this._pakoOptions = options; 24 | // the `meta` object from the last chunk received 25 | // this allow this worker to pass around metadata 26 | this.meta = {}; 27 | } 28 | 29 | utils.inherits(FlateWorker, GenericWorker); 30 | 31 | /** 32 | * @see GenericWorker.processChunk 33 | */ 34 | FlateWorker.prototype.processChunk = function (chunk) { 35 | this.meta = chunk.meta; 36 | if (this._pako === null) { 37 | this._createPako(); 38 | } 39 | this._pako.push(utils.transformTo(ARRAY_TYPE, chunk.data), false); 40 | }; 41 | 42 | /** 43 | * @see GenericWorker.flush 44 | */ 45 | FlateWorker.prototype.flush = function () { 46 | GenericWorker.prototype.flush.call(this); 47 | if (this._pako === null) { 48 | this._createPako(); 49 | } 50 | this._pako.push([], true); 51 | }; 52 | /** 53 | * @see GenericWorker.cleanUp 54 | */ 55 | FlateWorker.prototype.cleanUp = function () { 56 | GenericWorker.prototype.cleanUp.call(this); 57 | this._pako = null; 58 | }; 59 | 60 | /** 61 | * Create the _pako object. 62 | * TODO: lazy-loading this object isn't the best solution but it's the 63 | * quickest. The best solution is to lazy-load the worker list. See also the 64 | * issue #446. 65 | */ 66 | FlateWorker.prototype._createPako = function () { 67 | this._pako = new pako[this._pakoAction]({ 68 | raw: true, 69 | level: this._pakoOptions.level || -1 // default compression 70 | }); 71 | var self = this; 72 | this._pako.onData = function(data) { 73 | self.push({ 74 | data : data, 75 | meta : self.meta 76 | }); 77 | }; 78 | }; 79 | 80 | exports.compressWorker = function (compressionOptions) { 81 | return new FlateWorker("Deflate", compressionOptions); 82 | }; 83 | exports.uncompressWorker = function () { 84 | return new FlateWorker("Inflate", {}); 85 | }; 86 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/generate/index.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var compressions = require('../compressions'); 4 | var ZipFileWorker = require('./ZipFileWorker'); 5 | 6 | /** 7 | * Find the compression to use. 8 | * @param {String} fileCompression the compression defined at the file level, if any. 9 | * @param {String} zipCompression the compression defined at the load() level. 10 | * @return {Object} the compression object to use. 11 | */ 12 | var getCompression = function (fileCompression, zipCompression) { 13 | 14 | var compressionName = fileCompression || zipCompression; 15 | var compression = compressions[compressionName]; 16 | if (!compression) { 17 | throw new Error(compressionName + " is not a valid compression method !"); 18 | } 19 | return compression; 20 | }; 21 | 22 | /** 23 | * Create a worker to generate a zip file. 24 | * @param {JSZip} zip the JSZip instance at the right root level. 25 | * @param {Object} options to generate the zip file. 26 | * @param {String} comment the comment to use. 27 | */ 28 | exports.generateWorker = function (zip, options, comment) { 29 | 30 | var zipFileWorker = new ZipFileWorker(options.streamFiles, comment, options.platform, options.encodeFileName); 31 | var entriesCount = 0; 32 | try { 33 | 34 | zip.forEach(function (relativePath, file) { 35 | entriesCount++; 36 | var compression = getCompression(file.options.compression, options.compression); 37 | var compressionOptions = file.options.compressionOptions || options.compressionOptions || {}; 38 | var dir = file.dir, date = file.date; 39 | 40 | file._compressWorker(compression, compressionOptions) 41 | .withStreamInfo("file", { 42 | name : relativePath, 43 | dir : dir, 44 | date : date, 45 | comment : file.comment || "", 46 | unixPermissions : file.unixPermissions, 47 | dosPermissions : file.dosPermissions 48 | }) 49 | .pipe(zipFileWorker); 50 | }); 51 | zipFileWorker.entriesCount = entriesCount; 52 | } catch (e) { 53 | zipFileWorker.error(e); 54 | } 55 | 56 | return zipFileWorker; 57 | }; 58 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/index.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /** 4 | * Representation a of zip file in js 5 | * @constructor 6 | */ 7 | function JSZip() { 8 | // if this constructor is used without `new`, it adds `new` before itself: 9 | if(!(this instanceof JSZip)) { 10 | return new JSZip(); 11 | } 12 | 13 | if(arguments.length) { 14 | throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide."); 15 | } 16 | 17 | // object containing the files : 18 | // { 19 | // "folder/" : {...}, 20 | // "folder/data.txt" : {...} 21 | // } 22 | this.files = {}; 23 | 24 | this.comment = null; 25 | 26 | // Where we are in the hierarchy 27 | this.root = ""; 28 | this.clone = function() { 29 | var newObj = new JSZip(); 30 | for (var i in this) { 31 | if (typeof this[i] !== "function") { 32 | newObj[i] = this[i]; 33 | } 34 | } 35 | return newObj; 36 | }; 37 | } 38 | JSZip.prototype = require('./object'); 39 | JSZip.prototype.loadAsync = require('./load'); 40 | JSZip.support = require('./support'); 41 | JSZip.defaults = require('./defaults'); 42 | 43 | // TODO find a better way to handle this version, 44 | // a require('package.json').version doesn't work with webpack, see #327 45 | JSZip.version = "3.1.5"; 46 | 47 | JSZip.loadAsync = function (content, options) { 48 | return new JSZip().loadAsync(content, options); 49 | }; 50 | 51 | JSZip.external = require("./external"); 52 | module.exports = JSZip; 53 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/license_header.js: -------------------------------------------------------------------------------- 1 | /*! 2 | 3 | JSZip v__VERSION__ - A JavaScript class for generating and reading zip files 4 | 5 | 6 | (c) 2009-2016 Stuart Knightley 7 | Dual licenced under the MIT license or GPLv3. See https://raw.github.com/Stuk/jszip/master/LICENSE.markdown. 8 | 9 | JSZip uses the library pako released under the MIT license : 10 | https://github.com/nodeca/pako/blob/master/LICENSE 11 | */ 12 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/load.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | var utils = require('./utils'); 3 | var external = require("./external"); 4 | var utf8 = require('./utf8'); 5 | var utils = require('./utils'); 6 | var ZipEntries = require('./zipEntries'); 7 | var Crc32Probe = require('./stream/Crc32Probe'); 8 | var nodejsUtils = require("./nodejsUtils"); 9 | 10 | /** 11 | * Check the CRC32 of an entry. 12 | * @param {ZipEntry} zipEntry the zip entry to check. 13 | * @return {Promise} the result. 14 | */ 15 | function checkEntryCRC32(zipEntry) { 16 | return new external.Promise(function (resolve, reject) { 17 | var worker = zipEntry.decompressed.getContentWorker().pipe(new Crc32Probe()); 18 | worker.on("error", function (e) { 19 | reject(e); 20 | }) 21 | .on("end", function () { 22 | if (worker.streamInfo.crc32 !== zipEntry.decompressed.crc32) { 23 | reject(new Error("Corrupted zip : CRC32 mismatch")); 24 | } else { 25 | resolve(); 26 | } 27 | }) 28 | .resume(); 29 | }); 30 | } 31 | 32 | module.exports = function(data, options) { 33 | var zip = this; 34 | options = utils.extend(options || {}, { 35 | base64: false, 36 | checkCRC32: false, 37 | optimizedBinaryString: false, 38 | createFolders: false, 39 | decodeFileName: utf8.utf8decode 40 | }); 41 | 42 | if (nodejsUtils.isNode && nodejsUtils.isStream(data)) { 43 | return external.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")); 44 | } 45 | 46 | return utils.prepareContent("the loaded zip file", data, true, options.optimizedBinaryString, options.base64) 47 | .then(function(data) { 48 | var zipEntries = new ZipEntries(options); 49 | zipEntries.load(data); 50 | return zipEntries; 51 | }).then(function checkCRC32(zipEntries) { 52 | var promises = [external.Promise.resolve(zipEntries)]; 53 | var files = zipEntries.files; 54 | if (options.checkCRC32) { 55 | for (var i = 0; i < files.length; i++) { 56 | promises.push(checkEntryCRC32(files[i])); 57 | } 58 | } 59 | return external.Promise.all(promises); 60 | }).then(function addFiles(results) { 61 | var zipEntries = results.shift(); 62 | var files = zipEntries.files; 63 | for (var i = 0; i < files.length; i++) { 64 | var input = files[i]; 65 | zip.file(input.fileNameStr, input.decompressed, { 66 | binary: true, 67 | optimizedBinaryString: true, 68 | date: input.date, 69 | dir: input.dir, 70 | comment : input.fileCommentStr.length ? input.fileCommentStr : null, 71 | unixPermissions : input.unixPermissions, 72 | dosPermissions : input.dosPermissions, 73 | createFolders: options.createFolders 74 | }); 75 | } 76 | if (zipEntries.zipComment.length) { 77 | zip.comment = zipEntries.zipComment; 78 | } 79 | 80 | return zip; 81 | }); 82 | }; 83 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/nodejs/NodejsStreamInputAdapter.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | 3 | var utils = require('../utils'); 4 | var GenericWorker = require('../stream/GenericWorker'); 5 | 6 | /** 7 | * A worker that use a nodejs stream as source. 8 | * @constructor 9 | * @param {String} filename the name of the file entry for this stream. 10 | * @param {Readable} stream the nodejs stream. 11 | */ 12 | function NodejsStreamInputAdapter(filename, stream) { 13 | GenericWorker.call(this, "Nodejs stream input adapter for " + filename); 14 | this._upstreamEnded = false; 15 | this._bindStream(stream); 16 | } 17 | 18 | utils.inherits(NodejsStreamInputAdapter, GenericWorker); 19 | 20 | /** 21 | * Prepare the stream and bind the callbacks on it. 22 | * Do this ASAP on node 0.10 ! A lazy binding doesn't always work. 23 | * @param {Stream} stream the nodejs stream to use. 24 | */ 25 | NodejsStreamInputAdapter.prototype._bindStream = function (stream) { 26 | var self = this; 27 | this._stream = stream; 28 | stream.pause(); 29 | stream 30 | .on("data", function (chunk) { 31 | self.push({ 32 | data: chunk, 33 | meta : { 34 | percent : 0 35 | } 36 | }); 37 | }) 38 | .on("error", function (e) { 39 | if(self.isPaused) { 40 | this.generatedError = e; 41 | } else { 42 | self.error(e); 43 | } 44 | }) 45 | .on("end", function () { 46 | if(self.isPaused) { 47 | self._upstreamEnded = true; 48 | } else { 49 | self.end(); 50 | } 51 | }); 52 | }; 53 | NodejsStreamInputAdapter.prototype.pause = function () { 54 | if(!GenericWorker.prototype.pause.call(this)) { 55 | return false; 56 | } 57 | this._stream.pause(); 58 | return true; 59 | }; 60 | NodejsStreamInputAdapter.prototype.resume = function () { 61 | if(!GenericWorker.prototype.resume.call(this)) { 62 | return false; 63 | } 64 | 65 | if(this._upstreamEnded) { 66 | this.end(); 67 | } else { 68 | this._stream.resume(); 69 | } 70 | 71 | return true; 72 | }; 73 | 74 | module.exports = NodejsStreamInputAdapter; 75 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/nodejs/NodejsStreamOutputAdapter.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var Readable = require('readable-stream').Readable; 4 | 5 | var utils = require('../utils'); 6 | utils.inherits(NodejsStreamOutputAdapter, Readable); 7 | 8 | /** 9 | * A nodejs stream using a worker as source. 10 | * @see the SourceWrapper in http://nodejs.org/api/stream.html 11 | * @constructor 12 | * @param {StreamHelper} helper the helper wrapping the worker 13 | * @param {Object} options the nodejs stream options 14 | * @param {Function} updateCb the update callback. 15 | */ 16 | function NodejsStreamOutputAdapter(helper, options, updateCb) { 17 | Readable.call(this, options); 18 | this._helper = helper; 19 | 20 | var self = this; 21 | helper.on("data", function (data, meta) { 22 | if (!self.push(data)) { 23 | self._helper.pause(); 24 | } 25 | if(updateCb) { 26 | updateCb(meta); 27 | } 28 | }) 29 | .on("error", function(e) { 30 | self.emit('error', e); 31 | }) 32 | .on("end", function () { 33 | self.push(null); 34 | }); 35 | } 36 | 37 | 38 | NodejsStreamOutputAdapter.prototype._read = function() { 39 | this._helper.resume(); 40 | }; 41 | 42 | module.exports = NodejsStreamOutputAdapter; 43 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/nodejsUtils.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | module.exports = { 4 | /** 5 | * True if this is running in Nodejs, will be undefined in a browser. 6 | * In a browser, browserify won't include this file and the whole module 7 | * will be resolved an empty object. 8 | */ 9 | isNode : typeof Buffer !== "undefined", 10 | /** 11 | * Create a new nodejs Buffer from an existing content. 12 | * @param {Object} data the data to pass to the constructor. 13 | * @param {String} encoding the encoding to use. 14 | * @return {Buffer} a new Buffer. 15 | */ 16 | newBufferFrom: function(data, encoding) { 17 | // XXX We can't use `Buffer.from` which comes from `Uint8Array.from` 18 | // in nodejs v4 (< v.4.5). It's not the expected implementation (and 19 | // has a different signature). 20 | // see https://github.com/nodejs/node/issues/8053 21 | // A condition on nodejs' version won't solve the issue as we don't 22 | // control the Buffer polyfills that may or may not be used. 23 | return new Buffer(data, encoding); 24 | }, 25 | /** 26 | * Create a new nodejs Buffer with the specified size. 27 | * @param {Integer} size the size of the buffer. 28 | * @return {Buffer} a new Buffer. 29 | */ 30 | allocBuffer: function (size) { 31 | if (Buffer.alloc) { 32 | return Buffer.alloc(size); 33 | } else { 34 | return new Buffer(size); 35 | } 36 | }, 37 | /** 38 | * Find out if an object is a Buffer. 39 | * @param {Object} b the object to test. 40 | * @return {Boolean} true if the object is a Buffer, false otherwise. 41 | */ 42 | isBuffer : function(b){ 43 | return Buffer.isBuffer(b); 44 | }, 45 | 46 | isStream : function (obj) { 47 | return obj && 48 | typeof obj.on === "function" && 49 | typeof obj.pause === "function" && 50 | typeof obj.resume === "function"; 51 | } 52 | }; 53 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/readable-stream-browser.js: -------------------------------------------------------------------------------- 1 | /* 2 | * This file is used by module bundlers (browserify/webpack/etc) when 3 | * including a stream implementation. We use "readable-stream" to get a 4 | * consistent behavior between nodejs versions but bundlers often have a shim 5 | * for "stream". Using this shim greatly improve the compatibility and greatly 6 | * reduce the final size of the bundle (only one stream implementation, not 7 | * two). 8 | */ 9 | module.exports = require("stream"); 10 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/reader/ArrayReader.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | var DataReader = require('./DataReader'); 3 | var utils = require('../utils'); 4 | 5 | function ArrayReader(data) { 6 | DataReader.call(this, data); 7 | for(var i = 0; i < this.data.length; i++) { 8 | data[i] = data[i] & 0xFF; 9 | } 10 | } 11 | utils.inherits(ArrayReader, DataReader); 12 | /** 13 | * @see DataReader.byteAt 14 | */ 15 | ArrayReader.prototype.byteAt = function(i) { 16 | return this.data[this.zero + i]; 17 | }; 18 | /** 19 | * @see DataReader.lastIndexOfSignature 20 | */ 21 | ArrayReader.prototype.lastIndexOfSignature = function(sig) { 22 | var sig0 = sig.charCodeAt(0), 23 | sig1 = sig.charCodeAt(1), 24 | sig2 = sig.charCodeAt(2), 25 | sig3 = sig.charCodeAt(3); 26 | for (var i = this.length - 4; i >= 0; --i) { 27 | if (this.data[i] === sig0 && this.data[i + 1] === sig1 && this.data[i + 2] === sig2 && this.data[i + 3] === sig3) { 28 | return i - this.zero; 29 | } 30 | } 31 | 32 | return -1; 33 | }; 34 | /** 35 | * @see DataReader.readAndCheckSignature 36 | */ 37 | ArrayReader.prototype.readAndCheckSignature = function (sig) { 38 | var sig0 = sig.charCodeAt(0), 39 | sig1 = sig.charCodeAt(1), 40 | sig2 = sig.charCodeAt(2), 41 | sig3 = sig.charCodeAt(3), 42 | data = this.readData(4); 43 | return sig0 === data[0] && sig1 === data[1] && sig2 === data[2] && sig3 === data[3]; 44 | }; 45 | /** 46 | * @see DataReader.readData 47 | */ 48 | ArrayReader.prototype.readData = function(size) { 49 | this.checkOffset(size); 50 | if(size === 0) { 51 | return []; 52 | } 53 | var result = this.data.slice(this.zero + this.index, this.zero + this.index + size); 54 | this.index += size; 55 | return result; 56 | }; 57 | module.exports = ArrayReader; 58 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/reader/NodeBufferReader.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | var Uint8ArrayReader = require('./Uint8ArrayReader'); 3 | var utils = require('../utils'); 4 | 5 | function NodeBufferReader(data) { 6 | Uint8ArrayReader.call(this, data); 7 | } 8 | utils.inherits(NodeBufferReader, Uint8ArrayReader); 9 | 10 | /** 11 | * @see DataReader.readData 12 | */ 13 | NodeBufferReader.prototype.readData = function(size) { 14 | this.checkOffset(size); 15 | var result = this.data.slice(this.zero + this.index, this.zero + this.index + size); 16 | this.index += size; 17 | return result; 18 | }; 19 | module.exports = NodeBufferReader; 20 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/reader/StringReader.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | var DataReader = require('./DataReader'); 3 | var utils = require('../utils'); 4 | 5 | function StringReader(data) { 6 | DataReader.call(this, data); 7 | } 8 | utils.inherits(StringReader, DataReader); 9 | /** 10 | * @see DataReader.byteAt 11 | */ 12 | StringReader.prototype.byteAt = function(i) { 13 | return this.data.charCodeAt(this.zero + i); 14 | }; 15 | /** 16 | * @see DataReader.lastIndexOfSignature 17 | */ 18 | StringReader.prototype.lastIndexOfSignature = function(sig) { 19 | return this.data.lastIndexOf(sig) - this.zero; 20 | }; 21 | /** 22 | * @see DataReader.readAndCheckSignature 23 | */ 24 | StringReader.prototype.readAndCheckSignature = function (sig) { 25 | var data = this.readData(4); 26 | return sig === data; 27 | }; 28 | /** 29 | * @see DataReader.readData 30 | */ 31 | StringReader.prototype.readData = function(size) { 32 | this.checkOffset(size); 33 | // this will work because the constructor applied the "& 0xff" mask. 34 | var result = this.data.slice(this.zero + this.index, this.zero + this.index + size); 35 | this.index += size; 36 | return result; 37 | }; 38 | module.exports = StringReader; 39 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/reader/Uint8ArrayReader.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | var ArrayReader = require('./ArrayReader'); 3 | var utils = require('../utils'); 4 | 5 | function Uint8ArrayReader(data) { 6 | ArrayReader.call(this, data); 7 | } 8 | utils.inherits(Uint8ArrayReader, ArrayReader); 9 | /** 10 | * @see DataReader.readData 11 | */ 12 | Uint8ArrayReader.prototype.readData = function(size) { 13 | this.checkOffset(size); 14 | if(size === 0) { 15 | // in IE10, when using subarray(idx, idx), we get the array [0x00] instead of []. 16 | return new Uint8Array(0); 17 | } 18 | var result = this.data.subarray(this.zero + this.index, this.zero + this.index + size); 19 | this.index += size; 20 | return result; 21 | }; 22 | module.exports = Uint8ArrayReader; 23 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/reader/readerFor.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var utils = require('../utils'); 4 | var support = require('../support'); 5 | var ArrayReader = require('./ArrayReader'); 6 | var StringReader = require('./StringReader'); 7 | var NodeBufferReader = require('./NodeBufferReader'); 8 | var Uint8ArrayReader = require('./Uint8ArrayReader'); 9 | 10 | /** 11 | * Create a reader adapted to the data. 12 | * @param {String|ArrayBuffer|Uint8Array|Buffer} data the data to read. 13 | * @return {DataReader} the data reader. 14 | */ 15 | module.exports = function (data) { 16 | var type = utils.getTypeOf(data); 17 | utils.checkSupport(type); 18 | if (type === "string" && !support.uint8array) { 19 | return new StringReader(data); 20 | } 21 | if (type === "nodebuffer") { 22 | return new NodeBufferReader(data); 23 | } 24 | if (support.uint8array) { 25 | return new Uint8ArrayReader(utils.transformTo("uint8array", data)); 26 | } 27 | return new ArrayReader(utils.transformTo("array", data)); 28 | }; 29 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/signature.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | exports.LOCAL_FILE_HEADER = "PK\x03\x04"; 3 | exports.CENTRAL_FILE_HEADER = "PK\x01\x02"; 4 | exports.CENTRAL_DIRECTORY_END = "PK\x05\x06"; 5 | exports.ZIP64_CENTRAL_DIRECTORY_LOCATOR = "PK\x06\x07"; 6 | exports.ZIP64_CENTRAL_DIRECTORY_END = "PK\x06\x06"; 7 | exports.DATA_DESCRIPTOR = "PK\x07\x08"; 8 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/stream/ConvertWorker.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var GenericWorker = require('./GenericWorker'); 4 | var utils = require('../utils'); 5 | 6 | /** 7 | * A worker which convert chunks to a specified type. 8 | * @constructor 9 | * @param {String} destType the destination type. 10 | */ 11 | function ConvertWorker(destType) { 12 | GenericWorker.call(this, "ConvertWorker to " + destType); 13 | this.destType = destType; 14 | } 15 | utils.inherits(ConvertWorker, GenericWorker); 16 | 17 | /** 18 | * @see GenericWorker.processChunk 19 | */ 20 | ConvertWorker.prototype.processChunk = function (chunk) { 21 | this.push({ 22 | data : utils.transformTo(this.destType, chunk.data), 23 | meta : chunk.meta 24 | }); 25 | }; 26 | module.exports = ConvertWorker; 27 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/stream/Crc32Probe.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var GenericWorker = require('./GenericWorker'); 4 | var crc32 = require('../crc32'); 5 | var utils = require('../utils'); 6 | 7 | /** 8 | * A worker which calculate the crc32 of the data flowing through. 9 | * @constructor 10 | */ 11 | function Crc32Probe() { 12 | GenericWorker.call(this, "Crc32Probe"); 13 | this.withStreamInfo("crc32", 0); 14 | } 15 | utils.inherits(Crc32Probe, GenericWorker); 16 | 17 | /** 18 | * @see GenericWorker.processChunk 19 | */ 20 | Crc32Probe.prototype.processChunk = function (chunk) { 21 | this.streamInfo.crc32 = crc32(chunk.data, this.streamInfo.crc32 || 0); 22 | this.push(chunk); 23 | }; 24 | module.exports = Crc32Probe; 25 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/stream/DataLengthProbe.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var utils = require('../utils'); 4 | var GenericWorker = require('./GenericWorker'); 5 | 6 | /** 7 | * A worker which calculate the total length of the data flowing through. 8 | * @constructor 9 | * @param {String} propName the name used to expose the length 10 | */ 11 | function DataLengthProbe(propName) { 12 | GenericWorker.call(this, "DataLengthProbe for " + propName); 13 | this.propName = propName; 14 | this.withStreamInfo(propName, 0); 15 | } 16 | utils.inherits(DataLengthProbe, GenericWorker); 17 | 18 | /** 19 | * @see GenericWorker.processChunk 20 | */ 21 | DataLengthProbe.prototype.processChunk = function (chunk) { 22 | if(chunk) { 23 | var length = this.streamInfo[this.propName] || 0; 24 | this.streamInfo[this.propName] = length + chunk.data.length; 25 | } 26 | GenericWorker.prototype.processChunk.call(this, chunk); 27 | }; 28 | module.exports = DataLengthProbe; 29 | 30 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/stream/DataWorker.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var utils = require('../utils'); 4 | var GenericWorker = require('./GenericWorker'); 5 | 6 | // the size of the generated chunks 7 | // TODO expose this as a public variable 8 | var DEFAULT_BLOCK_SIZE = 16 * 1024; 9 | 10 | /** 11 | * A worker that reads a content and emits chunks. 12 | * @constructor 13 | * @param {Promise} dataP the promise of the data to split 14 | */ 15 | function DataWorker(dataP) { 16 | GenericWorker.call(this, "DataWorker"); 17 | var self = this; 18 | this.dataIsReady = false; 19 | this.index = 0; 20 | this.max = 0; 21 | this.data = null; 22 | this.type = ""; 23 | 24 | this._tickScheduled = false; 25 | 26 | dataP.then(function (data) { 27 | self.dataIsReady = true; 28 | self.data = data; 29 | self.max = data && data.length || 0; 30 | self.type = utils.getTypeOf(data); 31 | if(!self.isPaused) { 32 | self._tickAndRepeat(); 33 | } 34 | }, function (e) { 35 | self.error(e); 36 | }); 37 | } 38 | 39 | utils.inherits(DataWorker, GenericWorker); 40 | 41 | /** 42 | * @see GenericWorker.cleanUp 43 | */ 44 | DataWorker.prototype.cleanUp = function () { 45 | GenericWorker.prototype.cleanUp.call(this); 46 | this.data = null; 47 | }; 48 | 49 | /** 50 | * @see GenericWorker.resume 51 | */ 52 | DataWorker.prototype.resume = function () { 53 | if(!GenericWorker.prototype.resume.call(this)) { 54 | return false; 55 | } 56 | 57 | if (!this._tickScheduled && this.dataIsReady) { 58 | this._tickScheduled = true; 59 | utils.delay(this._tickAndRepeat, [], this); 60 | } 61 | return true; 62 | }; 63 | 64 | /** 65 | * Trigger a tick a schedule an other call to this function. 66 | */ 67 | DataWorker.prototype._tickAndRepeat = function() { 68 | this._tickScheduled = false; 69 | if(this.isPaused || this.isFinished) { 70 | return; 71 | } 72 | this._tick(); 73 | if(!this.isFinished) { 74 | utils.delay(this._tickAndRepeat, [], this); 75 | this._tickScheduled = true; 76 | } 77 | }; 78 | 79 | /** 80 | * Read and push a chunk. 81 | */ 82 | DataWorker.prototype._tick = function() { 83 | 84 | if(this.isPaused || this.isFinished) { 85 | return false; 86 | } 87 | 88 | var size = DEFAULT_BLOCK_SIZE; 89 | var data = null, nextIndex = Math.min(this.max, this.index + size); 90 | if (this.index >= this.max) { 91 | // EOF 92 | return this.end(); 93 | } else { 94 | switch(this.type) { 95 | case "string": 96 | data = this.data.substring(this.index, nextIndex); 97 | break; 98 | case "uint8array": 99 | data = this.data.subarray(this.index, nextIndex); 100 | break; 101 | case "array": 102 | case "nodebuffer": 103 | data = this.data.slice(this.index, nextIndex); 104 | break; 105 | } 106 | this.index = nextIndex; 107 | return this.push({ 108 | data : data, 109 | meta : { 110 | percent : this.max ? this.index / this.max * 100 : 0 111 | } 112 | }); 113 | } 114 | }; 115 | 116 | module.exports = DataWorker; 117 | -------------------------------------------------------------------------------- /bower_components/jszip/lib/support.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | exports.base64 = true; 4 | exports.array = true; 5 | exports.string = true; 6 | exports.arraybuffer = typeof ArrayBuffer !== "undefined" && typeof Uint8Array !== "undefined"; 7 | exports.nodebuffer = typeof Buffer !== "undefined"; 8 | // contains true if JSZip can read/generate Uint8Array, false otherwise. 9 | exports.uint8array = typeof Uint8Array !== "undefined"; 10 | 11 | if (typeof ArrayBuffer === "undefined") { 12 | exports.blob = false; 13 | } 14 | else { 15 | var buffer = new ArrayBuffer(0); 16 | try { 17 | exports.blob = new Blob([buffer], { 18 | type: "application/zip" 19 | }).size === 0; 20 | } 21 | catch (e) { 22 | try { 23 | var Builder = self.BlobBuilder || self.WebKitBlobBuilder || self.MozBlobBuilder || self.MSBlobBuilder; 24 | var builder = new Builder(); 25 | builder.append(buffer); 26 | exports.blob = builder.getBlob('application/zip').size === 0; 27 | } 28 | catch (e) { 29 | exports.blob = false; 30 | } 31 | } 32 | } 33 | 34 | try { 35 | exports.nodestream = !!require('readable-stream').Readable; 36 | } catch(e) { 37 | exports.nodestream = false; 38 | } 39 | -------------------------------------------------------------------------------- /bower_components/jszip/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jszip", 3 | "version": "3.1.5", 4 | "author": "Stuart Knightley ", 5 | "description": "Create, read and edit .zip files with JavaScript http://stuartk.com/jszip", 6 | "scripts": { 7 | "test": "npm run test-node && npm run test-browser", 8 | "test-node": "qunit-cli -c test/helpers/test-utils.js test/helpers/node-test-utils.js test/asserts/*.js", 9 | "test-browser": "grunt build && grunt test", 10 | "lint": "grunt jshint" 11 | }, 12 | "contributors": [ 13 | { 14 | "name": "Franz Buchinger" 15 | }, 16 | { 17 | "name": "António Afonso" 18 | }, 19 | { 20 | "name": "David Duponchel" 21 | }, 22 | { 23 | "name": "yiminghe" 24 | } 25 | ], 26 | "main": "./lib/index", 27 | "browser": { 28 | "readable-stream": "./lib/readable-stream-browser.js" 29 | }, 30 | "repository": { 31 | "type": "git", 32 | "url": "https://github.com/Stuk/jszip.git" 33 | }, 34 | "keywords": [ 35 | "zip", 36 | "deflate", 37 | "inflate" 38 | ], 39 | "devDependencies": { 40 | "grunt": "~0.4.1", 41 | "grunt-cli": "~1.1.0", 42 | "grunt-saucelabs": "8.6.2", 43 | "grunt-contrib-connect": "1.0.0", 44 | "jshint": "~2.9.1", 45 | "browserify": "~13.0.0", 46 | "grunt-browserify": "~5.0.0", 47 | "grunt-contrib-jshint": "~1.0.0", 48 | "grunt-contrib-qunit": "~1.2.0", 49 | "grunt-contrib-uglify": "~1.0.0", 50 | "phantomjs-prebuilt": "2.1.15", 51 | "jszip-utils": "~0.0.2", 52 | "package-json-versionify": "1.0.2", 53 | "qunit-cli": "~0.2.0", 54 | "qunitjs": "~1.23.0", 55 | "tmp": "0.0.28" 56 | }, 57 | "dependencies": { 58 | "core-js": "~2.3.0", 59 | "es6-promise": "~3.0.2", 60 | "lie": "~3.1.0", 61 | "pako": "~1.0.2", 62 | "readable-stream": "~2.0.6" 63 | }, 64 | "license": "(MIT OR GPL-3.0)" 65 | } 66 | -------------------------------------------------------------------------------- /bower_components/skeleton/LICENSE.md: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2011-2014 Dave Gamache 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. -------------------------------------------------------------------------------- /bower_components/skeleton/README.md: -------------------------------------------------------------------------------- 1 | # [Skeleton](http://getskeleton.com) 2 | Skeleton is a simple, responsive boilerplate to kickstart any responsive project. 3 | 4 | Check out for documentation and details. 5 | 6 | ## Getting started 7 | 8 | There are a couple ways to download Skeleton: 9 | - [Download the zip](https://github.com/dhg/Skeleton/releases/download/2.0.4/Skeleton-2.0.4.zip) 10 | - Clone the repo: `git clone https://github.com/dhg/Skeleton.git` (Note: this is under active development, so if you're looking for stable and safe, use the zipped download) 11 | 12 | 13 | ### What's in the download? 14 | 15 | The download includes Skeleton's CSS, Normalize CSS as a reset, a sample favicon, and an index.html as a starting point. 16 | 17 | ``` 18 | Skeleton/ 19 | ├── index.html 20 | ├── css/ 21 | │ ├── normalize.min.css 22 | │ └── skeleton.css 23 | └── images/ 24 | └── favicon.ico 25 | 26 | ``` 27 | 28 | ### Why it's awesome 29 | 30 | Skeleton is lightweight and simple. It styles only raw HTML elements (with a few exceptions) and provides a responsive grid. Nothing more. 31 | - Around 400 lines of CSS unminified and with comments 32 | - It's a starting point, not a UI framework 33 | - No compiling or installing...just vanilla CSS 34 | 35 | 36 | ## Browser support 37 | 38 | - Chrome latest 39 | - Firefox latest 40 | - Opera latest 41 | - Safari latest 42 | - IE latest 43 | 44 | The above list is non-exhaustive. Skeleton works perfectly with almost all older versions of the browsers above, though IE certainly has large degradation prior to IE9. 45 | 46 | 47 | ## License 48 | 49 | All parts of Skeleton are free to use and abuse under the [open-source MIT license](https://github.com/dhg/Skeleton/blob/master/LICENSE.md). 50 | 51 | 52 | ## Extensions 53 | 54 | The following are extensions to Skeleton built by the community. They are not officially supported, but all have been tested and are compatible with v2.0 (exact release noted): 55 | - [Skeleton on LESS](https://github.com/whatsnewsaes/Skeleton-less): Skeleton built with LESS for easier replacement of grid, color, and media queries. (Last update was to match v2.0.1) 56 | - [Skeleton on Sass](https://github.com/whatsnewsaes/Skeleton-Sass): Skeleton built with Sass for easier replacement of grid, color, and media queries. (Last update was to match v2.0.1) 57 | 58 | Have an extension you want to see here? Just shoot an email to hi@getskeleton.com with your extension! 59 | 60 | 61 | ## Colophon 62 | 63 | Skeleton was built using [Sublime Text 3](http://www.sublimetext.com/3) and designed with [Sketch](http://bohemiancoding.com/sketch). The typeface [Raleway](http://www.google.com/fonts/specimen/Raleway) was created by [Matt McInerney](http://matt.cc/) and [Pablo Impallari](http://www.impallari.com/). Code highlighting by Google's [Prettify library](https://code.google.com/p/google-code-prettify/). Icons in the header of the documentation are all derivative work of icons from [The Noun Project](http://thenounproject.com). [Feather](http://thenounproject.com/term/feather/22073) by Zach VanDeHey, [Pen](http://thenounproject.com/term/pen/21163) (with cap) by Ed Harrison, [Pen](http://thenounproject.com/term/pen/32847) (with clicker) by Matthew Hall, and [Watch](http://thenounproject.com/term/watch/48015) by Julien Deveaux. 64 | 65 | 66 | ## Acknowledgement 67 | 68 | Skeleton was created by [Dave Gamache](https://twitter.com/dhg) for a better web. 69 | -------------------------------------------------------------------------------- /bower_components/skeleton/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "skeleton", 3 | "version": "2.0.4", 4 | "homepage": "http://getskeleton.com/", 5 | "repository": { 6 | "type": "git", 7 | "url": "https://github.com/dhg/Skeleton" 8 | }, 9 | "authors": [ 10 | "Dave Gamache (http://davegamache.com/)" 11 | ], 12 | "description": "Skeleton is a dead-simple, responsive boilerplate to kickstart any responsive project.", 13 | "main": "css/skeleton.css", 14 | "keywords": [ 15 | "css", 16 | "skeleton", 17 | "responsive", 18 | "boilerplate" 19 | ], 20 | "license": "MIT" 21 | } -------------------------------------------------------------------------------- /bower_components/skeleton/images/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/textileio/textile-facebook/0432ae0f89c20128900615f01a105673f0b51baa/bower_components/skeleton/images/favicon.png -------------------------------------------------------------------------------- /bower_components/skeleton/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 7 | 8 | Your page title here :) 9 | 10 | 11 | 12 | 14 | 15 | 16 | 18 | 19 | 20 | 22 | 23 | 24 | 25 | 27 | 28 | 29 | 30 | 31 | 32 | 34 |
    35 |
    36 |
    37 |

    Basic Page

    38 |

    This index.html page is a placeholder with the CSS, font and favicon. It's just waiting for you to add some content! If you need some help hit up the Skeleton documentation.

    39 |
    40 |
    41 |
    42 | 43 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /css/style.css: -------------------------------------------------------------------------------- 1 | body { 2 | font-family: "Open Sans", "HelveticaNeue", "Helvetica Neue", Helvetica, Arial, sans-serif; 3 | } 4 | h1,h2,h3,h4,h5 { 5 | font-family: "Raleway", "HelveticaNeue", "Helvetica Neue", Helvetica, Arial, sans-serif; 6 | } 7 | 8 | h5 { 9 | font-size: 18px; 10 | } 11 | 12 | @media screen and (min-width: 540px) { /* Specific to this particular image */ 13 | .mobile { 14 | display: none; 15 | } 16 | } 17 | 18 | .header .logo { 19 | margin: 10px 0; 20 | height: 80px; 21 | } 22 | .header .login { 23 | margin-top: 4px; 24 | padding-top: 30px; 25 | text-align: right; 26 | float: right; 27 | } 28 | .header .login .button { 29 | font-size: 12px; 30 | float: right; 31 | } 32 | @media screen and (max-width: 540px) { /* Specific to this particular image */ 33 | .header .login { 34 | display: none; 35 | } 36 | } 37 | 38 | .hero { 39 | border: 1px dashed #aaa; 40 | text-align: left; 41 | padding: 10% 0%; 42 | margin: 0 1%; 43 | } 44 | @media screen and (min-width: 1024px) { /* Specific to this particular image */ 45 | .hero { 46 | background: url("/img/folder.png") no-repeat center right; 47 | /*background-size: auto 60% ;*/ 48 | background-repeat: no-repeat; 49 | } 50 | } 51 | .hero.drag { 52 | background: #fcfcfc; 53 | } 54 | 55 | .caution { 56 | margin-top: 10px; 57 | padding: 10px; 58 | border-radius: 5px; 59 | } 60 | .caution p { 61 | margin-bottom: 0; 62 | } 63 | .partial-caution { 64 | text-decoration: none; 65 | } 66 | .full-caution { 67 | background-color: #ffe2cf; 68 | } 69 | 70 | .explainer { 71 | margin-top: 45px; 72 | text-align: center; 73 | } 74 | .explainer .column { 75 | padding: 5px 0; 76 | } 77 | .point { 78 | text-align: left; 79 | margin-top: 45px; 80 | } 81 | 82 | .steps .step { 83 | height: 120px; 84 | } 85 | .steps .show { 86 | margin-top: 10px; 87 | } 88 | 89 | .folder { 90 | border: 2px solid #efefef; 91 | } 92 | .cta { 93 | text-align: center; 94 | margin: 30px 0 50px 0; 95 | } 96 | 97 | .footer { 98 | margin-top: 25px; 99 | height: 118px; 100 | padding-top: 100px; 101 | background-color: #0065ff; 102 | color: white; 103 | text-align: center; 104 | } -------------------------------------------------------------------------------- /img/encoded.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/textileio/textile-facebook/0432ae0f89c20128900615f01a105673f0b51baa/img/encoded.png -------------------------------------------------------------------------------- /img/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/textileio/textile-facebook/0432ae0f89c20128900615f01a105673f0b51baa/img/favicon.ico -------------------------------------------------------------------------------- /img/folder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/textileio/textile-facebook/0432ae0f89c20128900615f01a105673f0b51baa/img/folder.png -------------------------------------------------------------------------------- /img/logo-120px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/textileio/textile-facebook/0432ae0f89c20128900615f01a105673f0b51baa/img/logo-120px.png -------------------------------------------------------------------------------- /img/logo-240px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/textileio/textile-facebook/0432ae0f89c20128900615f01a105673f0b51baa/img/logo-240px.png -------------------------------------------------------------------------------- /img/logo-name.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/textileio/textile-facebook/0432ae0f89c20128900615f01a105673f0b51baa/img/logo-name.png -------------------------------------------------------------------------------- /img/organized.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/textileio/textile-facebook/0432ae0f89c20128900615f01a105673f0b51baa/img/organized.png -------------------------------------------------------------------------------- /js/FileSaver.js: -------------------------------------------------------------------------------- 1 | /*! @source http://purl.eligrey.com/github/FileSaver.js/blob/master/FileSaver.js */ 2 | var saveAs=saveAs||function(e){"use strict";if(typeof e==="undefined"||typeof navigator!=="undefined"&&/MSIE [1-9]\./.test(navigator.userAgent)){return}var t=e.document,n=function(){return e.URL||e.webkitURL||e},r=t.createElementNS("http://www.w3.org/1999/xhtml","a"),o="download"in r,a=function(e){var t=new MouseEvent("click");e.dispatchEvent(t)},i=/constructor/i.test(e.HTMLElement)||e.safari,f=/CriOS\/[\d]+/.test(navigator.userAgent),u=function(t){(e.setImmediate||e.setTimeout)(function(){throw t},0)},s="application/octet-stream",d=1e3*40,c=function(e){var t=function(){if(typeof e==="string"){n().revokeObjectURL(e)}else{e.remove()}};setTimeout(t,d)},l=function(e,t,n){t=[].concat(t);var r=t.length;while(r--){var o=e["on"+t[r]];if(typeof o==="function"){try{o.call(e,n||e)}catch(a){u(a)}}}},p=function(e){if(/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)){return new Blob([String.fromCharCode(65279),e],{type:e.type})}return e},v=function(t,u,d){if(!d){t=p(t)}var v=this,w=t.type,m=w===s,y,h=function(){l(v,"writestart progress write writeend".split(" "))},S=function(){if((f||m&&i)&&e.FileReader){var r=new FileReader;r.onloadend=function(){var t=f?r.result:r.result.replace(/^data:[^;]*;/,"data:attachment/file;");var n=e.open(t,"_blank");if(!n)e.location.href=t;t=undefined;v.readyState=v.DONE;h()};r.readAsDataURL(t);v.readyState=v.INIT;return}if(!y){y=n().createObjectURL(t)}if(m){e.location.href=y}else{var o=e.open(y,"_blank");if(!o){e.location.href=y}}v.readyState=v.DONE;h();c(y)};v.readyState=v.INIT;if(o){y=n().createObjectURL(t);setTimeout(function(){r.href=y;r.download=u;a(r);h();c(y);v.readyState=v.DONE});return}S()},w=v.prototype,m=function(e,t,n){return new v(e,t||e.name||"download",n)};if(typeof navigator!=="undefined"&&navigator.msSaveOrOpenBlob){return function(e,t,n){t=t||e.name||"download";if(!n){e=p(e)}return navigator.msSaveOrOpenBlob(e,t)}}w.abort=function(){};w.readyState=w.INIT=0;w.WRITING=1;w.DONE=2;w.error=w.onwritestart=w.onprogress=w.onwrite=w.onabort=w.onerror=w.onwriteend=null;return m}(typeof self!=="undefined"&&self||typeof window!=="undefined"&&window||this.content);if(typeof module!=="undefined"&&module.exports){module.exports.saveAs=saveAs}else if(typeof define!=="undefined"&&define!==null&&define.amd!==null){define("FileSaver.js",function(){return saveAs})} 3 | --------------------------------------------------------------------------------