1
1
/** @preserve
2
2
* jsPDF - PDF Document creation from JavaScript
3
- * Version 1.1.135 -git Built on 2015-05-16T00:15
4
- * CommitID e0da47f3da
3
+ * Version 1.1.239 -git Built on 2015-08-26T20:20
4
+ * CommitID 6b73dc2e73
5
5
*
6
6
* Copyright (c) 2010-2014 James Hall <
[email protected] >, https://github.com/MrRio/jsPDF
7
7
* 2010 Aaron Spike, https://github.com/acspike
@@ -2035,7 +2035,7 @@ var jsPDF = (function(global) {
2035
2035
* pdfdoc.mymethod() // <- !!!!!!
2036
2036
*/
2037
2037
jsPDF.API = {events:[]};
2038
- jsPDF.version = "1.1.135 -debug 2015-05-16T00:15:jameshall ";
2038
+ jsPDF.version = "1.1.239 -debug 2015-08-26T20:20:danielzamorano ";
2039
2039
2040
2040
if (typeof define === 'function' && define.amd) {
2041
2041
define('jsPDF', function() {
@@ -7480,7 +7480,7 @@ jsPDFAPI.putTotalPages = function(pageExpression) {
7480
7480
}(typeof self !== "undefined" && self || typeof window !== "undefined" && window || this.content || this));
7481
7481
/* FileSaver.js
7482
7482
* A saveAs() FileSaver implementation.
7483
- * 2015-05-07.2
7483
+ * 1.1.20150716
7484
7484
*
7485
7485
* By Eli Grey, http://eligrey.com
7486
7486
* License: X11/MIT
@@ -7507,11 +7507,7 @@ var saveAs = saveAs || (function(view) {
7507
7507
, save_link = doc.createElementNS("http://www.w3.org/1999/xhtml", "a")
7508
7508
, can_use_save_link = "download" in save_link
7509
7509
, click = function(node) {
7510
- var event = doc.createEvent("MouseEvents");
7511
- event.initMouseEvent(
7512
- "click", true, false, view, 0, 0, 0, 0, 0
7513
- , false, false, false, false, 0, null
7514
- );
7510
+ var event = new MouseEvent("click");
7515
7511
node.dispatchEvent(event);
7516
7512
}
7517
7513
, webkit_req_fs = view.webkitRequestFileSystem
@@ -7562,8 +7558,10 @@ var saveAs = saveAs || (function(view) {
7562
7558
}
7563
7559
return blob;
7564
7560
}
7565
- , FileSaver = function(blob, name) {
7566
- blob = auto_bom(blob);
7561
+ , FileSaver = function(blob, name, no_auto_bom) {
7562
+ if (!no_auto_bom) {
7563
+ blob = auto_bom(blob);
7564
+ }
7567
7565
// First try a.download, then web filesystem, then object URLs
7568
7566
var
7569
7567
filesaver = this
@@ -7611,10 +7609,12 @@ var saveAs = saveAs || (function(view) {
7611
7609
object_url = get_URL().createObjectURL(blob);
7612
7610
save_link.href = object_url;
7613
7611
save_link.download = name;
7614
- click(save_link);
7615
- filesaver.readyState = filesaver.DONE;
7616
- dispatch_all();
7617
- revoke(object_url);
7612
+ setTimeout(function() {
7613
+ click(save_link);
7614
+ dispatch_all();
7615
+ revoke(object_url);
7616
+ filesaver.readyState = filesaver.DONE;
7617
+ });
7618
7618
return;
7619
7619
}
7620
7620
// Object and web filesystem URLs have a problem saving in Google Chrome when
@@ -7685,14 +7685,17 @@ var saveAs = saveAs || (function(view) {
7685
7685
}), fs_error);
7686
7686
}
7687
7687
, FS_proto = FileSaver.prototype
7688
- , saveAs = function(blob, name) {
7689
- return new FileSaver(blob, name);
7688
+ , saveAs = function(blob, name, no_auto_bom ) {
7689
+ return new FileSaver(blob, name, no_auto_bom );
7690
7690
}
7691
7691
;
7692
7692
// IE 10+ (native saveAs)
7693
7693
if (typeof navigator !== "undefined" && navigator.msSaveOrOpenBlob) {
7694
- return function(blob, name) {
7695
- return navigator.msSaveOrOpenBlob(auto_bom(blob), name);
7694
+ return function(blob, name, no_auto_bom) {
7695
+ if (!no_auto_bom) {
7696
+ blob = auto_bom(blob);
7697
+ }
7698
+ return navigator.msSaveOrOpenBlob(blob, name || "download");
7696
7699
};
7697
7700
}
7698
7701
@@ -15633,7 +15636,7 @@ function XHR(url) {
15633
15636
* http://opensource.org/licenses/mit-license
15634
15637
*/
15635
15638
15636
- html2pdf = function (html,pdf,callback) {
15639
+ function html2pdf (html,pdf,callback) {
15637
15640
var canvas = pdf.canvas;
15638
15641
if (!canvas) {
15639
15642
alert('jsPDF canvas plugin not installed');
@@ -16880,6 +16883,9 @@ var FlateStream = (function() {
16880
16883
* This allows a host page to simply include require.js and bootstrap the page with a single require statement.
16881
16884
*/
16882
16885
16886
+ // Skip if Require.JS not installed
16887
+ if (typeof require === 'object') {
16888
+
16883
16889
if (typeof require_baseUrl_override === 'undefined'){
16884
16890
require_baseUrl_override = '../';
16885
16891
}
@@ -16980,6 +16986,7 @@ require.config({
16980
16986
'html2pdf': 'libs/html2pdf'
16981
16987
}
16982
16988
});
16989
+ } // Require.JS
16983
16990
/** vim: et:ts=4:sw=4:sts=4
16984
16991
* @license RequireJS 2.1.15 Copyright (c) 2010-2014, The Dojo Foundation All Rights Reserved.
16985
16992
* Available via the MIT or new BSD license.
0 commit comments