Drew Short
9 years ago
15 changed files with 275 additions and 0 deletions
-
199DPSResume.css
-
0DPSResume.outline
-
5base.min.css
-
BINbg1.png
-
7compatibility.min.js
-
BINf1.woff
-
BINf2.woff
-
BINf3.woff
-
BINf4.woff
-
BINf5.woff
-
BINf6.woff
-
5fancy.min.css
-
32index.html
-
BINpdf2htmlEX-64x64.png
-
27pdf2htmlEX.min.js
@ -0,0 +1,199 @@ |
|||||
|
.ff0{font-family:sans-serif;visibility:hidden;} |
||||
|
@font-face{font-family:ff1;src:url(f1.woff)format("woff");}.ff1{font-family:ff1;line-height:0.923000;font-style:normal;font-weight:normal;visibility:visible;} |
||||
|
@font-face{font-family:ff2;src:url(f2.woff)format("woff");}.ff2{font-family:ff2;line-height:0.947000;font-style:normal;font-weight:normal;visibility:visible;} |
||||
|
@font-face{font-family:ff3;src:url(f3.woff)format("woff");}.ff3{font-family:ff3;line-height:0.864000;font-style:normal;font-weight:normal;visibility:visible;} |
||||
|
@font-face{font-family:ff4;src:url(f4.woff)format("woff");}.ff4{font-family:ff4;line-height:0.854000;font-style:normal;font-weight:normal;visibility:visible;} |
||||
|
@font-face{font-family:ff5;src:url(f5.woff)format("woff");}.ff5{font-family:ff5;line-height:0.943000;font-style:normal;font-weight:normal;visibility:visible;} |
||||
|
@font-face{font-family:ff6;src:url(f6.woff)format("woff");}.ff6{font-family:ff6;line-height:0.388000;font-style:normal;font-weight:normal;visibility:visible;} |
||||
|
.m0{transform:matrix(0.325000,0.000000,0.000000,0.325000,0,0);-ms-transform:matrix(0.325000,0.000000,0.000000,0.325000,0,0);-webkit-transform:matrix(0.325000,0.000000,0.000000,0.325000,0,0);} |
||||
|
.m1{transform:matrix(1.300000,0.000000,0.000000,1.300000,0,0);-ms-transform:matrix(1.300000,0.000000,0.000000,1.300000,0,0);-webkit-transform:matrix(1.300000,0.000000,0.000000,1.300000,0,0);} |
||||
|
.v0{vertical-align:0.000000px;} |
||||
|
.ls0{letter-spacing:0.000000px;} |
||||
|
.sc_{text-shadow:none;} |
||||
|
.sc0{text-shadow:-0.015em 0 transparent,0 0.015em transparent,0.015em 0 transparent,0 -0.015em transparent;} |
||||
|
@media screen and (-webkit-min-device-pixel-ratio:0){ |
||||
|
.sc_{-webkit-text-stroke:0px transparent;} |
||||
|
.sc0{-webkit-text-stroke:0.015em transparent;text-shadow:none;} |
||||
|
} |
||||
|
.ws0{word-spacing:0.000000px;} |
||||
|
._1{margin-left:-7.173120px;} |
||||
|
._3{margin-left:-4.662497px;} |
||||
|
._2{margin-left:-2.191772px;} |
||||
|
._9{margin-left:-1.036110px;} |
||||
|
._f{width:7.890379px;} |
||||
|
._d{width:9.205442px;} |
||||
|
._8{width:10.799458px;} |
||||
|
._6{width:12.377442px;} |
||||
|
._0{width:13.724570px;} |
||||
|
._4{width:15.061254px;} |
||||
|
._c{width:19.926800px;} |
||||
|
._a{width:80.025095px;} |
||||
|
._15{width:95.760511px;} |
||||
|
._7{width:105.848154px;} |
||||
|
._5{width:116.169408px;} |
||||
|
._14{width:458.439002px;} |
||||
|
._e{width:462.452350px;} |
||||
|
._13{width:520.446224px;} |
||||
|
._b{width:580.107538px;} |
||||
|
._10{width:592.962410px;} |
||||
|
._12{width:941.107046px;} |
||||
|
._11{width:1090.864850px;} |
||||
|
.fc1{color:rgb(0,0,255);} |
||||
|
.fc0{color:rgb(0,0,0);} |
||||
|
.fs1{font-size:39.850400px;} |
||||
|
.fs0{font-size:47.820800px;} |
||||
|
.y30{bottom:54.745600px;} |
||||
|
.y2f{bottom:123.509100px;} |
||||
|
.y2e{bottom:139.050600px;} |
||||
|
.y2b{bottom:141.640200px;} |
||||
|
.y2d{bottom:154.592100px;} |
||||
|
.y2a{bottom:157.183000px;} |
||||
|
.y2c{bottom:170.133600px;} |
||||
|
.y29{bottom:172.724500px;} |
||||
|
.y28{bottom:207.782900px;} |
||||
|
.y27{bottom:223.324400px;} |
||||
|
.y26{bottom:238.865900px;} |
||||
|
.y25{bottom:254.407400px;} |
||||
|
.y24{bottom:269.950200px;} |
||||
|
.y23{bottom:285.491700px;} |
||||
|
.y22{bottom:316.574700px;} |
||||
|
.y21{bottom:332.116200px;} |
||||
|
.y20{bottom:347.659000px;} |
||||
|
.y1f{bottom:363.200500px;} |
||||
|
.y1e{bottom:378.742000px;} |
||||
|
.y1d{bottom:394.283500px;} |
||||
|
.y1c{bottom:409.825000px;} |
||||
|
.y1b{bottom:425.366500px;} |
||||
|
.y1a{bottom:440.909300px;} |
||||
|
.y19{bottom:456.450800px;} |
||||
|
.y18{bottom:487.533800px;} |
||||
|
.y17{bottom:503.075300px;} |
||||
|
.y16{bottom:518.616800px;} |
||||
|
.y15{bottom:534.159600px;} |
||||
|
.y14{bottom:549.701100px;} |
||||
|
.y13{bottom:565.242600px;} |
||||
|
.y12{bottom:580.784100px;} |
||||
|
.y11{bottom:596.325600px;} |
||||
|
.y10{bottom:611.867100px;} |
||||
|
.yf{bottom:627.409900px;} |
||||
|
.ye{bottom:642.951400px;} |
||||
|
.yd{bottom:678.009800px;} |
||||
|
.yc{bottom:693.551300px;} |
||||
|
.yb{bottom:709.092800px;} |
||||
|
.ya{bottom:724.635600px;} |
||||
|
.y9{bottom:759.694000px;} |
||||
|
.y8{bottom:775.235500px;} |
||||
|
.y7{bottom:790.777000px;} |
||||
|
.y6{bottom:806.318500px;} |
||||
|
.y5{bottom:841.378200px;} |
||||
|
.y4{bottom:856.919700px;} |
||||
|
.y3{bottom:891.978100px;} |
||||
|
.y2{bottom:907.519600px;} |
||||
|
.y0{bottom:919.750000px;} |
||||
|
.y1{bottom:923.048100px;} |
||||
|
.h1{height:0.650000px;} |
||||
|
.h4{height:29.369745px;} |
||||
|
.h3{height:29.529146px;} |
||||
|
.h2{height:35.243930px;} |
||||
|
.h0{height:1029.600000px;} |
||||
|
.w1{width:608.400000px;} |
||||
|
.w0{width:795.600000px;} |
||||
|
.x0{left:93.600000px;} |
||||
|
.x3{left:215.280000px;} |
||||
|
.x4{left:234.707200px;} |
||||
|
.x5{left:247.659100px;} |
||||
|
.x1{left:257.639200px;} |
||||
|
.x2{left:261.240200px;} |
||||
|
.x6{left:455.040300px;} |
||||
|
@media print{ |
||||
|
.v0{vertical-align:0.000000pt;} |
||||
|
.ls0{letter-spacing:0.000000pt;} |
||||
|
.ws0{word-spacing:0.000000pt;} |
||||
|
._1{margin-left:-7.357046pt;} |
||||
|
._3{margin-left:-4.782048pt;} |
||||
|
._2{margin-left:-2.247971pt;} |
||||
|
._9{margin-left:-1.062677pt;} |
||||
|
._f{width:8.092697pt;} |
||||
|
._d{width:9.441479pt;} |
||||
|
._8{width:11.076368pt;} |
||||
|
._6{width:12.694813pt;} |
||||
|
._0{width:14.076482pt;} |
||||
|
._4{width:15.447440pt;} |
||||
|
._c{width:20.437744pt;} |
||||
|
._a{width:82.077021pt;} |
||||
|
._15{width:98.215909pt;} |
||||
|
._7{width:108.562210pt;} |
||||
|
._5{width:119.148111pt;} |
||||
|
._14{width:470.193848pt;} |
||||
|
._e{width:474.310103pt;} |
||||
|
._13{width:533.790999pt;} |
||||
|
._b{width:594.982091pt;} |
||||
|
._10{width:608.166575pt;} |
||||
|
._12{width:965.237996pt;} |
||||
|
._11{width:1118.835743pt;} |
||||
|
.fs1{font-size:40.872205pt;} |
||||
|
.fs0{font-size:49.046974pt;} |
||||
|
.y30{bottom:56.149333pt;} |
||||
|
.y2f{bottom:126.676000pt;} |
||||
|
.y2e{bottom:142.616000pt;} |
||||
|
.y2b{bottom:145.272000pt;} |
||||
|
.y2d{bottom:158.556000pt;} |
||||
|
.y2a{bottom:161.213333pt;} |
||||
|
.y2c{bottom:174.496000pt;} |
||||
|
.y29{bottom:177.153333pt;} |
||||
|
.y28{bottom:213.110667pt;} |
||||
|
.y27{bottom:229.050667pt;} |
||||
|
.y26{bottom:244.990667pt;} |
||||
|
.y25{bottom:260.930667pt;} |
||||
|
.y24{bottom:276.872000pt;} |
||||
|
.y23{bottom:292.812000pt;} |
||||
|
.y22{bottom:324.692000pt;} |
||||
|
.y21{bottom:340.632000pt;} |
||||
|
.y20{bottom:356.573333pt;} |
||||
|
.y1f{bottom:372.513333pt;} |
||||
|
.y1e{bottom:388.453333pt;} |
||||
|
.y1d{bottom:404.393333pt;} |
||||
|
.y1c{bottom:420.333333pt;} |
||||
|
.y1b{bottom:436.273333pt;} |
||||
|
.y1a{bottom:452.214667pt;} |
||||
|
.y19{bottom:468.154667pt;} |
||||
|
.y18{bottom:500.034667pt;} |
||||
|
.y17{bottom:515.974667pt;} |
||||
|
.y16{bottom:531.914667pt;} |
||||
|
.y15{bottom:547.856000pt;} |
||||
|
.y14{bottom:563.796000pt;} |
||||
|
.y13{bottom:579.736000pt;} |
||||
|
.y12{bottom:595.676000pt;} |
||||
|
.y11{bottom:611.616000pt;} |
||||
|
.y10{bottom:627.556000pt;} |
||||
|
.yf{bottom:643.497333pt;} |
||||
|
.ye{bottom:659.437333pt;} |
||||
|
.yd{bottom:695.394667pt;} |
||||
|
.yc{bottom:711.334667pt;} |
||||
|
.yb{bottom:727.274667pt;} |
||||
|
.ya{bottom:743.216000pt;} |
||||
|
.y9{bottom:779.173333pt;} |
||||
|
.y8{bottom:795.113333pt;} |
||||
|
.y7{bottom:811.053333pt;} |
||||
|
.y6{bottom:826.993333pt;} |
||||
|
.y5{bottom:862.952000pt;} |
||||
|
.y4{bottom:878.892000pt;} |
||||
|
.y3{bottom:914.849333pt;} |
||||
|
.y2{bottom:930.789333pt;} |
||||
|
.y0{bottom:943.333333pt;} |
||||
|
.y1{bottom:946.716000pt;} |
||||
|
.h1{height:0.666667pt;} |
||||
|
.h4{height:30.122815pt;} |
||||
|
.h3{height:30.286304pt;} |
||||
|
.h2{height:36.147620pt;} |
||||
|
.h0{height:1056.000000pt;} |
||||
|
.w1{width:624.000000pt;} |
||||
|
.w0{width:816.000000pt;} |
||||
|
.x0{left:96.000000pt;} |
||||
|
.x3{left:220.800000pt;} |
||||
|
.x4{left:240.725333pt;} |
||||
|
.x5{left:254.009333pt;} |
||||
|
.x1{left:264.245333pt;} |
||||
|
.x2{left:267.938667pt;} |
||||
|
.x6{left:466.708000pt;} |
||||
|
} |
@ -0,0 +1,5 @@ |
|||||
|
/*! |
||||
|
* Base CSS for pdf2htmlEX |
||||
|
* Copyright 2012,2013 Lu Wang <coolwanglu@gmail.com> |
||||
|
* https://github.com/coolwanglu/pdf2htmlEX/blob/master/share/LICENSE |
||||
|
*/#sidebar{position:absolute;top:0;left:0;bottom:0;width:250px;padding:0;margin:0;overflow:auto}#page-container{position:absolute;top:0;left:0;margin:0;padding:0;border:0}@media screen{#sidebar.opened+#page-container{left:250px}#page-container{bottom:0;right:0;overflow:auto}.loading-indicator{display:none}.loading-indicator.active{display:block;position:absolute;width:64px;height:64px;top:50%;left:50%;margin-top:-32px;margin-left:-32px}.loading-indicator img{position:absolute;top:0;left:0;bottom:0;right:0}}@media print{@page{margin:0}html{margin:0}body{margin:0;-webkit-print-color-adjust:exact}#sidebar{display:none}#page-container{width:auto;height:auto;overflow:visible;background-color:transparent}.d{display:none}}.pf{position:relative;background-color:white;overflow:hidden;margin:0;border:0}.pc{position:absolute;border:0;padding:0;margin:0;top:0;left:0;width:100%;height:100%;overflow:hidden;display:block;transform-origin:0 0;-ms-transform-origin:0 0;-webkit-transform-origin:0 0}.pc.opened{display:block}.bf{position:absolute;border:0;margin:0;top:0;bottom:0;width:100%;height:100%;-ms-user-select:none;-moz-user-select:none;-webkit-user-select:none;user-select:none}.bi{position:absolute;border:0;margin:0;-ms-user-select:none;-moz-user-select:none;-webkit-user-select:none;user-select:none}@media print{.pf{margin:0;box-shadow:none;page-break-after:always;page-break-inside:avoid}@-moz-document url-prefix(){.pf{overflow:visible;border:1px solid #fff}.pc{overflow:visible}}}.c{position:absolute;border:0;padding:0;margin:0;overflow:hidden;display:block}.t{position:absolute;white-space:pre;font-size:1px;transform-origin:0 100%;-ms-transform-origin:0 100%;-webkit-transform-origin:0 100%;unicode-bidi:bidi-override;-moz-font-feature-settings:"liga" 0}.t:after{content:''}.t:before{content:'';display:inline-block}.t span{position:relative;unicode-bidi:bidi-override}._{display:inline-block;color:transparent;z-index:-1}::selection{background:rgba(127,255,255,0.4)}::-moz-selection{background:rgba(127,255,255,0.4)}.pi{display:none}.d{position:absolute;transform-origin:0 100%;-ms-transform-origin:0 100%;-webkit-transform-origin:0 100%}.it{border:0;background-color:rgba(255,255,255,0.0)}.ir:hover{cursor:pointer} |
After Width: 936 | Height: 1 | Size: 103 B |
@ -0,0 +1,7 @@ |
|||||
|
/* |
||||
|
Copyright 2012 Mozilla Foundation |
||||
|
Copyright 2013 Lu Wang <coolwanglu@gmail.com> |
||||
|
Apachine License Version 2.0 |
||||
|
*/ |
||||
|
(function(){function b(a,b,e,f){var c=(a.className||"").split(/\s+/g);""===c[0]&&c.shift();var d=c.indexOf(b);0>d&&e&&c.push(b);0<=d&&f&&c.splice(d,1);a.className=c.join(" ");return 0<=d}if(!("classList"in document.createElement("div"))){var e={add:function(a){b(this.element,a,!0,!1)},contains:function(a){return b(this.element,a,!1,!1)},remove:function(a){b(this.element,a,!1,!0)},toggle:function(a){b(this.element,a,!0,!0)}};Object.defineProperty(HTMLElement.prototype,"classList",{get:function(){if(this._classList)return this._classList; |
||||
|
var a=Object.create(e,{element:{value:this,writable:!1,enumerable:!0}});Object.defineProperty(this,"_classList",{value:a,writable:!1,enumerable:!1});return a},enumerable:!0})}})(); |
@ -0,0 +1,5 @@ |
|||||
|
/*! |
||||
|
* Fancy styles for pdf2htmlEX |
||||
|
* Copyright 2012,2013 Lu Wang <coolwanglu@gmail.com> |
||||
|
* https://github.com/coolwanglu/pdf2htmlEX/blob/master/share/LICENSE |
||||
|
*/@keyframes fadein{from{opacity:0}to{opacity:1}}@-webkit-keyframes fadein{from{opacity:0}to{opacity:1}}@keyframes swing{0{transform:rotate(0)}10%{transform:rotate(0)}90%{transform:rotate(720deg)}100%{transform:rotate(720deg)}}@-webkit-keyframes swing{0{-webkit-transform:rotate(0)}10%{-webkit-transform:rotate(0)}90%{-webkit-transform:rotate(720deg)}100%{-webkit-transform:rotate(720deg)}}@media screen{#sidebar{background-color:#2f3236;background-image:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI0IiBoZWlnaHQ9IjQiPgo8cmVjdCB3aWR0aD0iNCIgaGVpZ2h0PSI0IiBmaWxsPSIjNDAzYzNmIj48L3JlY3Q+CjxwYXRoIGQ9Ik0wIDBMNCA0Wk00IDBMMCA0WiIgc3Ryb2tlLXdpZHRoPSIxIiBzdHJva2U9IiMxZTI5MmQiPjwvcGF0aD4KPC9zdmc+")}#outline{font-family:Georgia,Times,"Times New Roman",serif;font-size:13px;margin:2em 1em}#outline ul{padding:0}#outline li{list-style-type:none;margin:1em 0}#outline li>ul{margin-left:1em}#outline a,#outline a:visited,#outline a:hover,#outline a:active{line-height:1.2;color:#e8e8e8;text-overflow:ellipsis;white-space:nowrap;text-decoration:none;display:block;overflow:hidden;outline:0}#outline a:hover{color:#0cf}#page-container{background-color:#9e9e9e;background-image:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI1IiBoZWlnaHQ9IjUiPgo8cmVjdCB3aWR0aD0iNSIgaGVpZ2h0PSI1IiBmaWxsPSIjOWU5ZTllIj48L3JlY3Q+CjxwYXRoIGQ9Ik0wIDVMNSAwWk02IDRMNCA2Wk0tMSAxTDEgLTFaIiBzdHJva2U9IiM4ODgiIHN0cm9rZS13aWR0aD0iMSI+PC9wYXRoPgo8L3N2Zz4=");-webkit-transition:left 500ms;transition:left 500ms}.pf{margin:13px auto;box-shadow:1px 1px 3px 1px #333;border-collapse:separate}.pc.opened{-webkit-animation:fadein 100ms;animation:fadein 100ms}.loading-indicator.active{-webkit-animation:swing 1.5s ease-in-out .01s infinite alternate none;animation:swing 1.5s ease-in-out .01s infinite alternate none}.checked{background:no-repeat url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAYAAADEtGw7AAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3goQDSYgDiGofgAAAslJREFUOMvtlM9LFGEYx7/vvOPM6ywuuyPFihWFBUsdNnA6KLIh+QPx4KWExULdHQ/9A9EfUodYmATDYg/iRewQzklFWxcEBcGgEplDkDtI6sw4PzrIbrOuedBb9MALD7zv+3m+z4/3Bf7bZS2bzQIAcrmcMDExcTeXy10DAFVVAQDksgFUVZ1ljD3yfd+0LOuFpmnvVVW9GHhkZAQcxwkNDQ2FSCQyRMgJxnVdy7KstKZpn7nwha6urqqfTqfPBAJAuVymlNLXoigOhfd5nmeiKL5TVTV+lmIKwAOA7u5u6Lped2BsbOwjY6yf4zgQQkAIAcedaPR9H67r3uYBQFEUFItFtLe332lpaVkUBOHK3t5eRtf1DwAwODiIubk5DA8PM8bYW1EU+wEgCIJqsCAIQAiB7/u253k2BQDDMJBKpa4mEon5eDx+UxAESJL0uK2t7XosFlvSdf0QAEmlUnlRFJ9Waho2Qghc1/U9z3uWz+eX+Wr+lL6SZfleEAQIggA8z6OpqSknimIvYyybSCReMsZ6TislhCAIAti2Dc/zejVNWwCAavN8339j27YbTg0AGGM3WltbP4WhlRWq6Q/btrs1TVsYHx+vNgqKoqBUKn2NRqPFxsbGJzzP05puUlpt0ukyOI6z7zjOwNTU1OLo6CgmJyf/gA3DgKIoWF1d/cIY24/FYgOU0pp0z/Ityzo8Pj5OTk9PbwHA+vp6zWghDC+VSiuRSOQgGo32UErJ38CO42wdHR09LBQK3zKZDDY2NupmFmF4R0cHVlZWlmRZ/iVJUn9FeWWcCCE4ODjYtG27Z2Zm5juAOmgdGAB2d3cBADs7O8uSJN2SZfl+WKlpmpumaT6Yn58vn/fs6XmbhmHMNjc3tzDGFI7jYJrm5vb29sDa2trPC/9aiqJUy5pOp4f6+vqeJ5PJBAB0dnZe/t8NBajx/z37Df5OGX8d13xzAAAAAElFTkSuQmCC)}} |
32
index.html
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
After Width: 64 | Height: 64 | Size: 3.3 KiB |
@ -0,0 +1,27 @@ |
|||||
|
(function(){/* |
||||
|
pdf2htmlEX.js: Core UI functions for pdf2htmlEX |
||||
|
Copyright 2012,2013 Lu Wang <coolwanglu@gmail.com> and other contributors |
||||
|
https://github.com/coolwanglu/pdf2htmlEX/blob/master/share/LICENSE
|
||||
|
*/ |
||||
|
var pdf2htmlEX=window.pdf2htmlEX=window.pdf2htmlEX||{},CSS_CLASS_NAMES={page_frame:"pf",page_content_box:"pc",page_data:"pi",background_image:"bi",link:"l",input_radio:"ir",__dummy__:"no comma"},DEFAULT_CONFIG={container_id:"page-container",sidebar_id:"sidebar",outline_id:"outline",loading_indicator_cls:"loading-indicator",preload_pages:3,render_timeout:100,scale_step:0.9,key_handler:!0,hashchange_handler:!0,view_history_handler:!0,__dummy__:"no comma"},EPS=1E-6; |
||||
|
function invert(a){var b=a[0]*a[3]-a[1]*a[2];return[a[3]/b,-a[1]/b,-a[2]/b,a[0]/b,(a[2]*a[5]-a[3]*a[4])/b,(a[1]*a[4]-a[0]*a[5])/b]}function transform(a,b){return[a[0]*b[0]+a[2]*b[1]+a[4],a[1]*b[0]+a[3]*b[1]+a[5]]}function get_page_number(a){return parseInt(a.getAttribute("data-page-no"),16)}function disable_dragstart(a){for(var b=0,c=a.length;b<c;++b)a[b].addEventListener("dragstart",function(){return!1},!1)} |
||||
|
function clone_and_extend_objs(a){for(var b={},c=0,e=arguments.length;c<e;++c){var h=arguments[c],d;for(d in h)h.hasOwnProperty(d)&&(b[d]=h[d])}return b} |
||||
|
function Page(a){if(a){this.shown=this.loaded=!1;this.page=a;this.num=get_page_number(a);this.original_height=a.clientHeight;this.original_width=a.clientWidth;var b=a.getElementsByClassName(CSS_CLASS_NAMES.page_content_box)[0];b&&(this.content_box=b,this.original_scale=this.cur_scale=this.original_height/b.clientHeight,this.page_data=JSON.parse(a.getElementsByClassName(CSS_CLASS_NAMES.page_data)[0].getAttribute("data-data")),this.ctm=this.page_data.ctm,this.ictm=invert(this.ctm),this.loaded=!0)}} |
||||
|
Page.prototype={hide:function(){this.loaded&&this.shown&&(this.content_box.classList.remove("opened"),this.shown=!1)},show:function(){this.loaded&&!this.shown&&(this.content_box.classList.add("opened"),this.shown=!0)},rescale:function(a){this.cur_scale=0===a?this.original_scale:a;this.loaded&&(a=this.content_box.style,a.msTransform=a.webkitTransform=a.transform="scale("+this.cur_scale.toFixed(3)+")");a=this.page.style;a.height=this.original_height*this.cur_scale+"px";a.width=this.original_width*this.cur_scale+ |
||||
|
"px"},view_position:function(){var a=this.page,b=a.parentNode;return[b.scrollLeft-a.offsetLeft-a.clientLeft,b.scrollTop-a.offsetTop-a.clientTop]},height:function(){return this.page.clientHeight},width:function(){return this.page.clientWidth}};function Viewer(a){this.config=clone_and_extend_objs(DEFAULT_CONFIG,0<arguments.length?a:{});this.pages_loading=[];this.init_before_loading_content();var b=this;document.addEventListener("DOMContentLoaded",function(){b.init_after_loading_content()},!1)} |
||||
|
Viewer.prototype={scale:1,cur_page_idx:0,first_page_idx:0,init_before_loading_content:function(){this.pre_hide_pages()},initialize_radio_button:function(){for(var a=document.getElementsByClassName(CSS_CLASS_NAMES.input_radio),b=0;b<a.length;b++)a[b].addEventListener("click",function(){this.classList.toggle("checked")})},init_after_loading_content:function(){this.sidebar=document.getElementById(this.config.sidebar_id);this.outline=document.getElementById(this.config.outline_id);this.container=document.getElementById(this.config.container_id); |
||||
|
this.loading_indicator=document.getElementsByClassName(this.config.loading_indicator_cls)[0];for(var a=!0,b=this.outline.childNodes,c=0,e=b.length;c<e;++c)if("ul"===b[c].nodeName.toLowerCase()){a=!1;break}a||this.sidebar.classList.add("opened");this.find_pages();if(0!=this.pages.length){disable_dragstart(document.getElementsByClassName(CSS_CLASS_NAMES.background_image));this.config.key_handler&&this.register_key_handler();var h=this;this.config.hashchange_handler&&window.addEventListener("hashchange", |
||||
|
function(a){h.navigate_to_dest(document.location.hash.substring(1))},!1);this.config.view_history_handler&&window.addEventListener("popstate",function(a){a.state&&h.navigate_to_dest(a.state)},!1);this.container.addEventListener("scroll",function(){h.update_page_idx();h.schedule_render(!0)},!1);[this.container,this.outline].forEach(function(a){a.addEventListener("click",h.link_handler.bind(h),!1)});this.initialize_radio_button();this.render()}},find_pages:function(){for(var a=[],b={},c=this.container.childNodes, |
||||
|
e=0,h=c.length;e<h;++e){var d=c[e];d.nodeType===Node.ELEMENT_NODE&&d.classList.contains(CSS_CLASS_NAMES.page_frame)&&(d=new Page(d),a.push(d),b[d.num]=a.length-1)}this.pages=a;this.page_map=b},load_page:function(a,b,c){var e=this.pages;if(!(a>=e.length||(e=e[a],e.loaded||this.pages_loading[a]))){var e=e.page,h=e.getAttribute("data-page-url");if(h){this.pages_loading[a]=!0;var d=e.getElementsByClassName(this.config.loading_indicator_cls)[0];"undefined"===typeof d&&(d=this.loading_indicator.cloneNode(!0), |
||||
|
d.classList.add("active"),e.appendChild(d));var f=this,g=new XMLHttpRequest;g.open("GET",h,!0);g.onload=function(){if(200===g.status||0===g.status){var b=document.createElement("div");b.innerHTML=g.responseText;for(var d=null,b=b.childNodes,e=0,h=b.length;e<h;++e){var p=b[e];if(p.nodeType===Node.ELEMENT_NODE&&p.classList.contains(CSS_CLASS_NAMES.page_frame)){d=p;break}}b=f.pages[a];f.container.replaceChild(d,b.page);b=new Page(d);f.pages[a]=b;b.hide();b.rescale(f.scale);disable_dragstart(d.getElementsByClassName(CSS_CLASS_NAMES.background_image)); |
||||
|
f.schedule_render(!1);c&&c(b)}delete f.pages_loading[a]};g.send(null)}void 0===b&&(b=this.config.preload_pages);0<--b&&(f=this,setTimeout(function(){f.load_page(a+1,b)},0))}},pre_hide_pages:function(){var a="@media screen{."+CSS_CLASS_NAMES.page_content_box+"{display:none;}}",b=document.createElement("style");b.styleSheet?b.styleSheet.cssText=a:b.appendChild(document.createTextNode(a));document.head.appendChild(b)},render:function(){for(var a=this.container,b=a.scrollTop,c=a.clientHeight,a=b-c,b= |
||||
|
b+c+c,c=this.pages,e=0,h=c.length;e<h;++e){var d=c[e],f=d.page,g=f.offsetTop+f.clientTop,f=g+f.clientHeight;g<=b&&f>=a?d.loaded?d.show():this.load_page(e):d.hide()}},update_page_idx:function(){var a=this.pages,b=a.length;if(!(2>b)){for(var c=this.container,e=c.scrollTop,c=e+c.clientHeight,h=-1,d=b,f=d-h;1<f;){var g=h+Math.floor(f/2),f=a[g].page;f.offsetTop+f.clientTop+f.clientHeight>=e?d=g:h=g;f=d-h}this.first_page_idx=d;for(var g=h=this.cur_page_idx,k=0;d<b;++d){var f=a[d].page,l=f.offsetTop+f.clientTop, |
||||
|
f=f.clientHeight;if(l>c)break;f=(Math.min(c,l+f)-Math.max(e,l))/f;if(d===h&&Math.abs(f-1)<=EPS){g=h;break}f>k&&(k=f,g=d)}this.cur_page_idx=g}},schedule_render:function(a){if(void 0!==this.render_timer){if(!a)return;clearTimeout(this.render_timer)}var b=this;this.render_timer=setTimeout(function(){delete b.render_timer;b.render()},this.config.render_timeout)},register_key_handler:function(){var a=this;window.addEventListener("DOMMouseScroll",function(b){if(b.ctrlKey){b.preventDefault();var c=a.container, |
||||
|
e=c.getBoundingClientRect(),c=[b.clientX-e.left-c.clientLeft,b.clientY-e.top-c.clientTop];a.rescale(Math.pow(a.config.scale_step,b.detail),!0,c)}},!1);window.addEventListener("keydown",function(b){var c=!1,e=b.ctrlKey||b.metaKey,h=b.altKey;switch(b.keyCode){case 61:case 107:case 187:e&&(a.rescale(1/a.config.scale_step,!0),c=!0);break;case 173:case 109:case 189:e&&(a.rescale(a.config.scale_step,!0),c=!0);break;case 48:e&&(a.rescale(0,!1),c=!0);break;case 33:h?a.scroll_to(a.cur_page_idx-1):a.container.scrollTop-= |
||||
|
a.container.clientHeight;c=!0;break;case 34:h?a.scroll_to(a.cur_page_idx+1):a.container.scrollTop+=a.container.clientHeight;c=!0;break;case 35:a.container.scrollTop=a.container.scrollHeight;c=!0;break;case 36:a.container.scrollTop=0,c=!0}c&&b.preventDefault()},!1)},rescale:function(a,b,c){var e=this.scale;this.scale=a=0===a?1:b?e*a:a;c||(c=[0,0]);b=this.container;c[0]+=b.scrollLeft;c[1]+=b.scrollTop;for(var h=this.pages,d=h.length,f=this.first_page_idx;f<d;++f){var g=h[f].page;if(g.offsetTop+g.clientTop>= |
||||
|
c[1])break}g=f-1;0>g&&(g=0);var g=h[g].page,k=g.clientWidth,f=g.clientHeight,l=g.offsetLeft+g.clientLeft,m=c[0]-l;0>m?m=0:m>k&&(m=k);k=g.offsetTop+g.clientTop;c=c[1]-k;0>c?c=0:c>f&&(c=f);for(f=0;f<d;++f)h[f].rescale(a);b.scrollLeft+=m/e*a+g.offsetLeft+g.clientLeft-m-l;b.scrollTop+=c/e*a+g.offsetTop+g.clientTop-c-k;this.schedule_render(!0)},fit_width:function(){var a=this.cur_page_idx;this.rescale(this.container.clientWidth/this.pages[a].width(),!0);this.scroll_to(a)},fit_height:function(){var a=this.cur_page_idx; |
||||
|
this.rescale(this.container.clientHeight/this.pages[a].height(),!0);this.scroll_to(a)},get_containing_page:function(a){for(;a;){if(a.nodeType===Node.ELEMENT_NODE&&a.classList.contains(CSS_CLASS_NAMES.page_frame)){a=get_page_number(a);var b=this.page_map;return a in b?this.pages[b[a]]:null}a=a.parentNode}return null},link_handler:function(a){var b=a.target,c=b.getAttribute("data-dest-detail");if(c){if(this.config.view_history_handler)try{var e=this.get_current_view_hash();window.history.replaceState(e, |
||||
|
"","#"+e);window.history.pushState(c,"","#"+c)}catch(h){}this.navigate_to_dest(c,this.get_containing_page(b));a.preventDefault()}},navigate_to_dest:function(a,b){try{var c=JSON.parse(a)}catch(e){return}if(c instanceof Array){var h=c[0],d=this.page_map;if(h in d){for(var f=d[h],h=this.pages[f],d=2,g=c.length;d<g;++d){var k=c[d];if(null!==k&&"number"!==typeof k)return}for(;6>c.length;)c.push(null);var g=b||this.pages[this.cur_page_idx],d=g.view_position(),d=transform(g.ictm,[d[0],g.height()-d[1]]), |
||||
|
g=this.scale,l=[0,0],m=!0,k=!1,n=this.scale;switch(c[1]){case "XYZ":l=[null===c[2]?d[0]:c[2]*n,null===c[3]?d[1]:c[3]*n];g=c[4];if(null===g||0===g)g=this.scale;k=!0;break;case "Fit":case "FitB":l=[0,0];k=!0;break;case "FitH":case "FitBH":l=[0,null===c[2]?d[1]:c[2]*n];k=!0;break;case "FitV":case "FitBV":l=[null===c[2]?d[0]:c[2]*n,0];k=!0;break;case "FitR":l=[c[2]*n,c[5]*n],m=!1,k=!0}if(k){this.rescale(g,!1);var p=this,c=function(a){l=transform(a.ctm,l);m&&(l[1]=a.height()-l[1]);p.scroll_to(f,l)};h.loaded? |
||||
|
c(h):(this.load_page(f,void 0,c),this.scroll_to(f))}}}},scroll_to:function(a,b){var c=this.pages;if(!(0>a||a>=c.length)){c=c[a].view_position();void 0===b&&(b=[0,0]);var e=this.container;e.scrollLeft+=b[0]-c[0];e.scrollTop+=b[1]-c[1]}},get_current_view_hash:function(){var a=[],b=this.pages[this.cur_page_idx];a.push(b.num);a.push("XYZ");var c=b.view_position(),c=transform(b.ictm,[c[0],b.height()-c[1]]);a.push(c[0]/this.scale);a.push(c[1]/this.scale);a.push(this.scale);return JSON.stringify(a)}}; |
||||
|
pdf2htmlEX.Viewer=Viewer;})(); |
Write
Preview
Loading…
Cancel
Save
Reference in new issue