Skip to content

Commit

Permalink
v0.9.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Cameron Lakenen committed Oct 16, 2014
1 parent 98a5c13 commit aa5fd87
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 10 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

Viewer.js uses [semantic versioning](http://semver.org/) for its version numbers.

* **0.9.0**
* Add option to disable auto-loading of first page assets at `load()`
* **0.8.0**
* Add support for 2xx response codes in ajax utility
* Add download plugin
Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "viewer",
"version": "0.8.0",
"version": "0.9.0",
"homepage": "https://github.com/box/viewer.js",
"authors": [
"Cameron Lakenen <lakenen@box.com>",
Expand Down
2 changes: 1 addition & 1 deletion dist/crocodoc.viewer.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! Crocodoc Viewer - v0.8.0 | (c) 2014 Box */
/*! Crocodoc Viewer - v0.9.0 | (c) 2014 Box */

.crocodoc-viewer {
padding:0;
Expand Down
12 changes: 9 additions & 3 deletions dist/crocodoc.viewer.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! Crocodoc Viewer - v0.8.0 | (c) 2014 Box */
/*! Crocodoc Viewer - v0.9.0 | (c) 2014 Box */

(function (window) {
/*global jQuery*/
Expand Down Expand Up @@ -830,6 +830,10 @@ var Crocodoc = (function () {
pageStart: null,
pageEnd: null,

// whether or not to automatically load page one assets immediately (even
// if conversion is not yet complete)
autoloadFirstPage: true,

// zoom levels are relative to the viewport size,
// and the dynamic zoom levels (auto, fitwidth, etc) will be added into the mix
zoomLevels: [0.25, 0.5, 0.75, 1.0, 1.25, 1.5, 2.0, 3.0]
Expand Down Expand Up @@ -1566,7 +1570,7 @@ Crocodoc.addUtility('ajax', function (framework) {
req.abort();
}
});
},
}
};
});

Expand Down Expand Up @@ -6476,8 +6480,10 @@ Crocodoc.addComponent('viewer-base', function (scope) {
});
}


// load page 1 assets immediately if necessary
if (!config.pageStart || config.pageStart === 1) {
if (config.autoloadFirstPage &&
(!config.pageStart || config.pageStart === 1)) {
if (support.svg) {
$pageOneContentPromise = scope.get('page-svg', 1);
} else if (config.conversionIsComplete) {
Expand Down
2 changes: 1 addition & 1 deletion dist/crocodoc.viewer.min.css

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions dist/crocodoc.viewer.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "viewer",
"version": "0.8.0",
"version": "0.9.0",
"description": "A viewer for documents converted with the Box View API",
"author": "Cameron Lakenen <lakenen@box.com>",
"contributors": [
Expand Down

0 comments on commit aa5fd87

Please sign in to comment.