@compdfkit_pdf_sdk/webviewer 2.9.1 → 2.9.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -81,6 +81,7 @@
81
81
  "line": "Line",
82
82
  "freetext": "Free Text",
83
83
  "stamp": "Stamp",
84
+ "signature": "Signature",
84
85
  "image": "Image",
85
86
  "link": "Link",
86
87
  "cloudy": "Cloud",
@@ -81,6 +81,7 @@
81
81
  "line": "Doubler",
82
82
  "freetext": "Texte libre",
83
83
  "stamp": "Timbre",
84
+ "signature": "Signature",
84
85
  "image": "Image",
85
86
  "link": "Lien",
86
87
  "cloudy": "Nuage",
@@ -81,6 +81,7 @@
81
81
  "line": "ライン",
82
82
  "freetext": "フリーテキスト",
83
83
  "stamp": "スタンプ",
84
+ "signature": "署名",
84
85
  "image": "画像",
85
86
  "link": "リンク",
86
87
  "cloudy": "クラウド",
@@ -81,6 +81,7 @@
81
81
  "line": "เส้น",
82
82
  "freetext": "ข้อความฟรี",
83
83
  "stamp": "แสตมป์",
84
+ "signature": "ลายเซ็น",
84
85
  "image": "ภาพ",
85
86
  "link": "ลิงค์",
86
87
  "cloudy": "คลาวด์",
@@ -81,6 +81,7 @@
81
81
  "line": "线",
82
82
  "freetext": "文本",
83
83
  "stamp": "图章",
84
+ "signature": "签名",
84
85
  "image": "图片",
85
86
  "link": "链接",
86
87
  "cloudy": "云朵",
@@ -81,6 +81,7 @@
81
81
  "line": "線",
82
82
  "freetext": "文字",
83
83
  "stamp": "圖章",
84
+ "signature": "簽名",
84
85
  "image": "圖片",
85
86
  "link": "連結",
86
87
  "cloudy": "雲朵",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@compdfkit_pdf_sdk/webviewer",
3
- "version": "2.9.1",
3
+ "version": "2.9.2",
4
4
  "description": "",
5
5
  "keywords": [
6
6
  "PDF SDK",
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).ComPDFKitViewer=t()}(this,(function(){"use strict";function e(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}function t(t,i){for(var n=0;n<i.length;n++){var o=i[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,e(o.key),o)}}var i={init:function(e,t){return new Promise((function(i){t.addEventListener("ready",(function e(){t.removeEventListener("ready",e);var n=t.querySelector("iframe").contentWindow;try{var o=n.instance;Promise.resolve().then((function(){i(o)}))}catch(e){i()}})),new c(e,t)}))}};var n,o,r,s=0,a=new Map,c=function(){return e=function e(t,i){if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),!a.get(i)){this.version="2.9.1",this.docId=0,a.set(i,!0),this.instance=null,this.options=t,this.initialDoc=t.pdfUrl||null,this.element=i,this.options.path=this.options.path||e.config.path;var n=this.options.path.length-1;n>0&&"/"!==this.options.path[n]&&(this.options.path+="/"),this.options.webviewerPath=this.options.path+e.config.webviewerPath,i.addEventListener("ready",(function e(){i.removeEventListener("ready",e)})),this.create()}},(i=[{key:"_createEvent",value:function(e,t){var i;try{i=new CustomEvent(e,{detail:t,bubbles:!0,cancelable:!0})}catch(n){(i=document.createEvent("Event")).initEvent(e,!0,!0),i.detail=t}return i}},{key:"create",value:function(){this.initialDoc?(this.initialDoc=encodeURIComponent(JSON.stringify(this.initialDoc)),this._create()):this._create()}},{key:"_create",value:function(){this.docId=++s,this._trigger||(this._trigger=function(e,t){var i=this._createEvent(e,t);this.element.dispatchEvent(i)});var e=this;this.messageHandler=function(t){if("requestConfig"===t.data.type&&t.data.docId===e.docId&&t.source){window.removeEventListener("message",this.messageHandler);var i=e.options.config?e._correctRelativePath(e.options.config):"";t.source.postMessage({type:"responseConfig",value:i,options:e.options},"*")}},window.addEventListener("message",this.messageHandler,!1),this.createViewer()}},{key:"_correctRelativePath",value:function(e){return function(e,t){if("string"!=typeof e||!t)return e;var i=t.substring(0,t.lastIndexOf("/"));return/^(\/|%2F|[a-z0-9-]+:)/i.test(e)?e:"".concat(i,"/").concat(e)}(e,window.location.pathname)}},{key:"createViewer",value:function(){var e,t,i,n=this,o=this.options.webviewerPath+"?version="+this.version;this.initialDoc?o+="#d=".concat(this.initialDoc):o+="#",o+="&docId=".concat(this.docId),(null===(e=this.options)||void 0===e?void 0:e.css)&&(o+="&css=".concat(encodeURIComponent(this.options.css))),void 0!==this.options.showToolbarControl&&(o+="&header=".concat(this.options.showToolbarControl?"true":"false")),this.options.theme&&(o+="&theme=".concat(this.options.theme));var r=document.createElement("iframe");r.id="webviewer-"+this.docId,r.src=o,r.frameBorder=0,r.width="100%",r.height="100%",r.setAttribute("allowfullscreen",!0),r.setAttribute("webkitallowfullscreen",!0),r.setAttribute("mozallowfullscreen",!0),this.iframe=r,null!==(t=this.options)&&void 0!==t&&t.backgroundColor&&r.setAttribute("data-bgcolor",this.options.backgroundColor),null!==(i=this.options)&&void 0!==i&&i.assetPath&&r.setAttribute("data-assetpath",encodeURIComponent(this.options.assetPath)),this.element.appendChild(r),window.addEventListener("message",(function e(t){if("viewerLoaded"===t.data.type&&t.data.docId===n.docId)try{n.instance=n.iframe.contentWindow.instance}catch(e){}finally{window.removeEventListener("message",e),n._viewerLoaded(n.iframe)}}))}},{key:"_documentViewerLoaded",value:function(e){this.options.pdfUrl&&e.contentWindow.instance.UI.loadDocument(this.options.pdfUrl)}},{key:"_viewerLoaded",value:function(e){this._trigger("ready");try{e.contentWindow.postMessage({type:"viewerLoaded",options:this.options},"*")}catch(e){}}}])&&t(e.prototype,i),n&&t(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,i,n}();return n=c,r={path:"",webviewerPath:"./webviewer/index.html"},(o=e(o="config"))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r,i}));
1
+ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).ComPDFKitViewer=t()}(this,(function(){"use strict";function e(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}function t(t,i){for(var n=0;n<i.length;n++){var o=i[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,e(o.key),o)}}var i={init:function(e,t){return new Promise((function(i){t.addEventListener("ready",(function e(){t.removeEventListener("ready",e);var n=t.querySelector("iframe").contentWindow;try{var o=n.instance;Promise.resolve().then((function(){i(o)}))}catch(e){i()}})),new c(e,t)}))}};var n,o,r,s=0,a=new Map,c=function(){return e=function e(t,i){if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),!a.get(i)){this.version="2.9.2",this.docId=0,a.set(i,!0),this.instance=null,this.options=t,this.initialDoc=t.pdfUrl||null,this.element=i,this.options.path=this.options.path||e.config.path;var n=this.options.path.length-1;n>0&&"/"!==this.options.path[n]&&(this.options.path+="/"),this.options.webviewerPath=this.options.path+e.config.webviewerPath,i.addEventListener("ready",(function e(){i.removeEventListener("ready",e)})),this.create()}},(i=[{key:"_createEvent",value:function(e,t){var i;try{i=new CustomEvent(e,{detail:t,bubbles:!0,cancelable:!0})}catch(n){(i=document.createEvent("Event")).initEvent(e,!0,!0),i.detail=t}return i}},{key:"create",value:function(){this.initialDoc?(this.initialDoc=encodeURIComponent(JSON.stringify(this.initialDoc)),this._create()):this._create()}},{key:"_create",value:function(){this.docId=++s,this._trigger||(this._trigger=function(e,t){var i=this._createEvent(e,t);this.element.dispatchEvent(i)});var e=this;this.messageHandler=function(t){if("requestConfig"===t.data.type&&t.data.docId===e.docId&&t.source){window.removeEventListener("message",this.messageHandler);var i=e.options.config?e._correctRelativePath(e.options.config):"";t.source.postMessage({type:"responseConfig",value:i,options:e.options},"*")}},window.addEventListener("message",this.messageHandler,!1),this.createViewer()}},{key:"_correctRelativePath",value:function(e){return function(e,t){if("string"!=typeof e||!t)return e;var i=t.substring(0,t.lastIndexOf("/"));return/^(\/|%2F|[a-z0-9-]+:)/i.test(e)?e:"".concat(i,"/").concat(e)}(e,window.location.pathname)}},{key:"createViewer",value:function(){var e,t,i,n=this,o=this.options.webviewerPath+"?version="+this.version;this.initialDoc?o+="#d=".concat(this.initialDoc):o+="#",o+="&docId=".concat(this.docId),(null===(e=this.options)||void 0===e?void 0:e.css)&&(o+="&css=".concat(encodeURIComponent(this.options.css))),void 0!==this.options.showToolbarControl&&(o+="&header=".concat(this.options.showToolbarControl?"true":"false")),this.options.theme&&(o+="&theme=".concat(this.options.theme));var r=document.createElement("iframe");r.id="webviewer-"+this.docId,r.src=o,r.frameBorder=0,r.width="100%",r.height="100%",r.setAttribute("allowfullscreen",!0),r.setAttribute("webkitallowfullscreen",!0),r.setAttribute("mozallowfullscreen",!0),this.iframe=r,null!==(t=this.options)&&void 0!==t&&t.backgroundColor&&r.setAttribute("data-bgcolor",this.options.backgroundColor),null!==(i=this.options)&&void 0!==i&&i.assetPath&&r.setAttribute("data-assetpath",encodeURIComponent(this.options.assetPath)),this.element.appendChild(r),window.addEventListener("message",(function e(t){if("viewerLoaded"===t.data.type&&t.data.docId===n.docId)try{n.instance=n.iframe.contentWindow.instance}catch(e){}finally{window.removeEventListener("message",e),n._viewerLoaded(n.iframe)}}))}},{key:"_documentViewerLoaded",value:function(e){this.options.pdfUrl&&e.contentWindow.instance.UI.loadDocument(this.options.pdfUrl)}},{key:"_viewerLoaded",value:function(e){this._trigger("ready");try{e.contentWindow.postMessage({type:"viewerLoaded",options:this.options},"*")}catch(e){}}}])&&t(e.prototype,i),n&&t(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,i,n}();return n=c,r={path:"",webviewerPath:"./webviewer/index.html"},(o=e(o="config"))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r,i}));
package/webviewer.js CHANGED
@@ -1 +1 @@
1
- function e(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}function t(t,i){for(var n=0;n<i.length;n++){var o=i[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,e(o.key),o)}}var i={init:function(e,t){return new Promise((function(i){t.addEventListener("ready",(function e(){t.removeEventListener("ready",e);var n=t.querySelector("iframe").contentWindow;try{var o=n.instance;Promise.resolve().then((function(){i(o)}))}catch(e){i()}})),new c(e,t)}))}};var n,o,r,a=0,s=new Map,c=function(){return e=function e(t,i){if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),!s.get(i)){this.version="2.9.1",this.docId=0,s.set(i,!0),this.instance=null,this.options=t,this.initialDoc=t.pdfUrl||null,this.element=i,this.options.path=this.options.path||e.config.path;var n=this.options.path.length-1;n>0&&"/"!==this.options.path[n]&&(this.options.path+="/"),this.options.webviewerPath=this.options.path+e.config.webviewerPath,i.addEventListener("ready",(function e(){i.removeEventListener("ready",e)})),this.create()}},(i=[{key:"_createEvent",value:function(e,t){var i;try{i=new CustomEvent(e,{detail:t,bubbles:!0,cancelable:!0})}catch(n){(i=document.createEvent("Event")).initEvent(e,!0,!0),i.detail=t}return i}},{key:"create",value:function(){this.initialDoc?(this.initialDoc=encodeURIComponent(JSON.stringify(this.initialDoc)),this._create()):this._create()}},{key:"_create",value:function(){this.docId=++a,this._trigger||(this._trigger=function(e,t){var i=this._createEvent(e,t);this.element.dispatchEvent(i)});var e=this;this.messageHandler=function(t){if("requestConfig"===t.data.type&&t.data.docId===e.docId&&t.source){window.removeEventListener("message",this.messageHandler);var i=e.options.config?e._correctRelativePath(e.options.config):"";t.source.postMessage({type:"responseConfig",value:i,options:e.options},"*")}},window.addEventListener("message",this.messageHandler,!1),this.createViewer()}},{key:"_correctRelativePath",value:function(e){return function(e,t){if("string"!=typeof e||!t)return e;var i=t.substring(0,t.lastIndexOf("/"));return/^(\/|%2F|[a-z0-9-]+:)/i.test(e)?e:"".concat(i,"/").concat(e)}(e,window.location.pathname)}},{key:"createViewer",value:function(){var e,t,i,n=this,o=this.options.webviewerPath+"?version="+this.version;this.initialDoc?o+="#d=".concat(this.initialDoc):o+="#",o+="&docId=".concat(this.docId),(null===(e=this.options)||void 0===e?void 0:e.css)&&(o+="&css=".concat(encodeURIComponent(this.options.css))),void 0!==this.options.showToolbarControl&&(o+="&header=".concat(this.options.showToolbarControl?"true":"false")),this.options.theme&&(o+="&theme=".concat(this.options.theme));var r=document.createElement("iframe");r.id="webviewer-"+this.docId,r.src=o,r.frameBorder=0,r.width="100%",r.height="100%",r.setAttribute("allowfullscreen",!0),r.setAttribute("webkitallowfullscreen",!0),r.setAttribute("mozallowfullscreen",!0),this.iframe=r,null!==(t=this.options)&&void 0!==t&&t.backgroundColor&&r.setAttribute("data-bgcolor",this.options.backgroundColor),null!==(i=this.options)&&void 0!==i&&i.assetPath&&r.setAttribute("data-assetpath",encodeURIComponent(this.options.assetPath)),this.element.appendChild(r),window.addEventListener("message",(function e(t){if("viewerLoaded"===t.data.type&&t.data.docId===n.docId)try{n.instance=n.iframe.contentWindow.instance}catch(e){}finally{window.removeEventListener("message",e),n._viewerLoaded(n.iframe)}}))}},{key:"_documentViewerLoaded",value:function(e){this.options.pdfUrl&&e.contentWindow.instance.UI.loadDocument(this.options.pdfUrl)}},{key:"_viewerLoaded",value:function(e){this._trigger("ready");try{e.contentWindow.postMessage({type:"viewerLoaded",options:this.options},"*")}catch(e){}}}])&&t(e.prototype,i),n&&t(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,i,n}();n=c,r={path:"",webviewerPath:"./webviewer/index.html"},(o=e(o="config"))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r;export{i as default};
1
+ function e(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}function t(t,i){for(var n=0;n<i.length;n++){var o=i[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,e(o.key),o)}}var i={init:function(e,t){return new Promise((function(i){t.addEventListener("ready",(function e(){t.removeEventListener("ready",e);var n=t.querySelector("iframe").contentWindow;try{var o=n.instance;Promise.resolve().then((function(){i(o)}))}catch(e){i()}})),new c(e,t)}))}};var n,o,r,a=0,s=new Map,c=function(){return e=function e(t,i){if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),!s.get(i)){this.version="2.9.2",this.docId=0,s.set(i,!0),this.instance=null,this.options=t,this.initialDoc=t.pdfUrl||null,this.element=i,this.options.path=this.options.path||e.config.path;var n=this.options.path.length-1;n>0&&"/"!==this.options.path[n]&&(this.options.path+="/"),this.options.webviewerPath=this.options.path+e.config.webviewerPath,i.addEventListener("ready",(function e(){i.removeEventListener("ready",e)})),this.create()}},(i=[{key:"_createEvent",value:function(e,t){var i;try{i=new CustomEvent(e,{detail:t,bubbles:!0,cancelable:!0})}catch(n){(i=document.createEvent("Event")).initEvent(e,!0,!0),i.detail=t}return i}},{key:"create",value:function(){this.initialDoc?(this.initialDoc=encodeURIComponent(JSON.stringify(this.initialDoc)),this._create()):this._create()}},{key:"_create",value:function(){this.docId=++a,this._trigger||(this._trigger=function(e,t){var i=this._createEvent(e,t);this.element.dispatchEvent(i)});var e=this;this.messageHandler=function(t){if("requestConfig"===t.data.type&&t.data.docId===e.docId&&t.source){window.removeEventListener("message",this.messageHandler);var i=e.options.config?e._correctRelativePath(e.options.config):"";t.source.postMessage({type:"responseConfig",value:i,options:e.options},"*")}},window.addEventListener("message",this.messageHandler,!1),this.createViewer()}},{key:"_correctRelativePath",value:function(e){return function(e,t){if("string"!=typeof e||!t)return e;var i=t.substring(0,t.lastIndexOf("/"));return/^(\/|%2F|[a-z0-9-]+:)/i.test(e)?e:"".concat(i,"/").concat(e)}(e,window.location.pathname)}},{key:"createViewer",value:function(){var e,t,i,n=this,o=this.options.webviewerPath+"?version="+this.version;this.initialDoc?o+="#d=".concat(this.initialDoc):o+="#",o+="&docId=".concat(this.docId),(null===(e=this.options)||void 0===e?void 0:e.css)&&(o+="&css=".concat(encodeURIComponent(this.options.css))),void 0!==this.options.showToolbarControl&&(o+="&header=".concat(this.options.showToolbarControl?"true":"false")),this.options.theme&&(o+="&theme=".concat(this.options.theme));var r=document.createElement("iframe");r.id="webviewer-"+this.docId,r.src=o,r.frameBorder=0,r.width="100%",r.height="100%",r.setAttribute("allowfullscreen",!0),r.setAttribute("webkitallowfullscreen",!0),r.setAttribute("mozallowfullscreen",!0),this.iframe=r,null!==(t=this.options)&&void 0!==t&&t.backgroundColor&&r.setAttribute("data-bgcolor",this.options.backgroundColor),null!==(i=this.options)&&void 0!==i&&i.assetPath&&r.setAttribute("data-assetpath",encodeURIComponent(this.options.assetPath)),this.element.appendChild(r),window.addEventListener("message",(function e(t){if("viewerLoaded"===t.data.type&&t.data.docId===n.docId)try{n.instance=n.iframe.contentWindow.instance}catch(e){}finally{window.removeEventListener("message",e),n._viewerLoaded(n.iframe)}}))}},{key:"_documentViewerLoaded",value:function(e){this.options.pdfUrl&&e.contentWindow.instance.UI.loadDocument(this.options.pdfUrl)}},{key:"_viewerLoaded",value:function(e){this._trigger("ready");try{e.contentWindow.postMessage({type:"viewerLoaded",options:this.options},"*")}catch(e){}}}])&&t(e.prototype,i),n&&t(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,i,n}();n=c,r={path:"",webviewerPath:"./webviewer/index.html"},(o=e(o="config"))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r;export{i as default};
@@ -1 +0,0 @@
1
- import{At as e,Bt as t,Dt as n,Et as r,Ft as i,Gt as a,H as o,I as s,It as c,L as l,Lt as u,Mt as d,N as f,Nt as p,O as m,Ot as h,Pt as ee,R as te,Rt as g,S as _,T as v,Tt as y,Vt as b,X as ne,Z as x,at as re,g as S,h as C,it as w,jt as ie,k as ae,kt as oe,m as T,rt as se,v as ce,wt as E,xt as le,zt as D}from"./viewer-Bx-vwNpl.js";var O=void 0,ue=typeof window<`u`&&window.trustedTypes;if(ue)try{O=ue.createPolicy(`vue`,{createHTML:e=>e})}catch{}var de=O?e=>O.createHTML(e):e=>e,fe=`http://www.w3.org/2000/svg`,pe=`http://www.w3.org/1998/Math/MathML`,k=typeof document<`u`?document:null,me=k&&k.createElement(`template`),he={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{let t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{let i=t===`svg`?k.createElementNS(fe,e):t===`mathml`?k.createElementNS(pe,e):n?k.createElement(e,{is:n}):k.createElement(e);return e===`select`&&r&&r.multiple!=null&&i.setAttribute(`multiple`,r.multiple),i},createText:e=>k.createTextNode(e),createComment:e=>k.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>k.querySelector(e),setScopeId(e,t){e.setAttribute(t,``)},insertStaticContent(e,t,n,r,i,a){let o=n?n.previousSibling:t.lastChild;if(i&&(i===a||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),!(i===a||!(i=i.nextSibling)););else{me.innerHTML=de(r===`svg`?`<svg>${e}</svg>`:r===`mathml`?`<math>${e}</math>`:e);let i=me.content;if(r===`svg`||r===`mathml`){let e=i.firstChild;for(;e.firstChild;)i.appendChild(e.firstChild);i.removeChild(e)}t.insertBefore(i,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},A=`transition`,j=`animation`,M=Symbol(`_vtc`),ge={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},_e=r({},S,ge),ve=(e=>(e.displayName=`Transition`,e.props=_e,e))((e,{slots:t})=>te(C,ye(e),t)),N=(t,n=[])=>{e(t)?t.forEach(e=>e(...n)):t&&t(...n)},P=t=>t?e(t)?t.some(e=>e.length>1):t.length>1:!1;function ye(e){let t={};for(let n in e)n in ge||(t[n]=e[n]);if(e.css===!1)return t;let{name:n=`v`,type:i,duration:a,enterFromClass:o=`${n}-enter-from`,enterActiveClass:s=`${n}-enter-active`,enterToClass:c=`${n}-enter-to`,appearFromClass:l=o,appearActiveClass:u=s,appearToClass:d=c,leaveFromClass:f=`${n}-leave-from`,leaveActiveClass:p=`${n}-leave-active`,leaveToClass:m=`${n}-leave-to`}=e,h=be(a),ee=h&&h[0],te=h&&h[1],{onBeforeEnter:g,onEnter:_,onEnterCancelled:v,onLeave:y,onLeaveCancelled:b,onBeforeAppear:ne=g,onAppear:x=_,onAppearCancelled:re=v}=t,S=(e,t,n,r)=>{e._enterCancelled=r,L(e,t?d:c),L(e,t?u:s),n&&n()},C=(e,t)=>{e._isLeaving=!1,L(e,f),L(e,m),L(e,p),t&&t()},w=e=>(t,n)=>{let r=e?x:_,a=()=>S(t,e,n);N(r,[t,a]),xe(()=>{L(t,e?l:o),I(t,e?d:c),P(r)||Ce(t,i,ee,a)})};return r(t,{onBeforeEnter(e){N(g,[e]),I(e,o),I(e,s)},onBeforeAppear(e){N(ne,[e]),I(e,l),I(e,u)},onEnter:w(!1),onAppear:w(!0),onLeave(e,t){e._isLeaving=!0;let n=()=>C(e,t);I(e,f),e._enterCancelled?(I(e,p),V(e)):(V(e),I(e,p)),xe(()=>{e._isLeaving&&(L(e,f),I(e,m),P(y)||Ce(e,i,te,n))}),N(y,[e,n])},onEnterCancelled(e){S(e,!1,void 0,!0),N(v,[e])},onAppearCancelled(e){S(e,!0,void 0,!0),N(re,[e])},onLeaveCancelled(e){C(e),N(b,[e])}})}function be(e){if(e==null)return null;if(p(e))return[F(e.enter),F(e.leave)];{let t=F(e);return[t,t]}}function F(e){return a(e)}function I(e,t){t.split(/\s+/).forEach(t=>t&&e.classList.add(t)),(e[M]||(e[M]=new Set)).add(t)}function L(e,t){t.split(/\s+/).forEach(t=>t&&e.classList.remove(t));let n=e[M];n&&(n.delete(t),n.size||(e[M]=void 0))}function xe(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}var Se=0;function Ce(e,t,n,r){let i=e._endId=++Se,a=()=>{i===e._endId&&r()};if(n!=null)return setTimeout(a,n);let{type:o,timeout:s,propCount:c}=R(e,t);if(!o)return r();let l=o+`end`,u=0,d=()=>{e.removeEventListener(l,f),a()},f=t=>{t.target===e&&++u>=c&&d()};setTimeout(()=>{u<c&&d()},s+1),e.addEventListener(l,f)}function R(e,t){let n=window.getComputedStyle(e),r=e=>(n[e]||``).split(`, `),i=r(`${A}Delay`),a=r(`${A}Duration`),o=z(i,a),s=r(`${j}Delay`),c=r(`${j}Duration`),l=z(s,c),u=null,d=0,f=0;t===A?o>0&&(u=A,d=o,f=a.length):t===j?l>0&&(u=j,d=l,f=c.length):(d=Math.max(o,l),u=d>0?o>l?A:j:null,f=u?u===A?a.length:c.length:0);let p=u===A&&/\b(?:transform|all)(?:,|$)/.test(r(`${A}Property`).toString());return{type:u,timeout:d,propCount:f,hasTransform:p}}function z(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((t,n)=>B(t)+B(e[n])))}function B(e){return e===`auto`?0:Number(e.slice(0,-1).replace(`,`,`.`))*1e3}function V(e){return(e?e.ownerDocument:document).body.offsetHeight}function we(e,t,n){let r=e[M];r&&(t=(t?[t,...r]:[...r]).join(` `)),t==null?e.removeAttribute(`class`):n?e.setAttribute(`class`,t):e.className=t}var H=Symbol(`_vod`),Te=Symbol(`_vsh`),Ee={name:`show`,beforeMount(e,{value:t},{transition:n}){e[H]=e.style.display===`none`?``:e.style.display,n&&t?n.beforeEnter(e):U(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),U(e,!0),r.enter(e)):r.leave(e,()=>{U(e,!1)}):U(e,t))},beforeUnmount(e,{value:t}){U(e,t)}};function U(e,t){e.style.display=t?e[H]:`none`,e[Te]=!t}var De=Symbol(``),Oe=/(?:^|;)\s*display\s*:/;function ke(e,t,n){let r=e.style,i=u(n),a=!1;if(n&&!i){if(t)if(u(t))for(let e of t.split(`;`)){let t=e.slice(0,e.indexOf(`:`)).trim();n[t]??W(r,t,``)}else for(let e in t)n[e]??W(r,e,``);for(let i in n){i===`display`&&(a=!0);let o=n[i];o==null?W(r,i,``):Me(e,i,!u(t)&&t?t[i]:void 0,o)||W(r,i,o)}}else if(i){if(t!==n){let e=r[De];e&&(n+=`;`+e),r.cssText=n,a=Oe.test(n)}}else t&&e.removeAttribute(`style`);H in e&&(e[H]=a?r.display:``,e[Te]&&(r.display=`none`))}var Ae=/\s*!important$/;function W(t,r,i){if(e(i))i.forEach(e=>W(t,r,e));else if(i??=``,r.startsWith(`--`))t.setProperty(r,i);else{let e=je(t,r);Ae.test(i)?t.setProperty(n(e),i.replace(Ae,``),`important`):t[e]=i}}var G=[`Webkit`,`Moz`,`ms`],K={};function je(e,t){let n=K[t];if(n)return n;let r=E(t);if(r!==`filter`&&r in e)return K[t]=r;r=y(r);for(let n=0;n<G.length;n++){let i=G[n]+r;if(i in e)return K[t]=i}return t}function Me(e,t,n,r){return e.tagName===`TEXTAREA`&&(t===`width`||t===`height`)&&u(r)&&n===r}var Ne=`http://www.w3.org/1999/xlink`;function Pe(e,t,n,r,i,a=c(t)){r&&t.startsWith(`xlink:`)?n==null?e.removeAttributeNS(Ne,t.slice(6,t.length)):e.setAttributeNS(Ne,t,n):n==null||a&&!h(n)?e.removeAttribute(t):e.setAttribute(t,a?``:g(n)?String(n):n)}function Fe(e,t,n,r,i){if(t===`innerHTML`||t===`textContent`){n!=null&&(e[t]=t===`innerHTML`?de(n):n);return}let a=e.tagName;if(t===`value`&&a!==`PROGRESS`&&!a.includes(`-`)){let r=a===`OPTION`?e.getAttribute(`value`)||``:e.value,i=n==null?e.type===`checkbox`?`on`:``:String(n);(r!==i||!(`_value`in e))&&(e.value=i),n??e.removeAttribute(t),e._value=n;return}let o=!1;if(n===``||n==null){let r=typeof e[t];r===`boolean`?n=h(n):n==null&&r===`string`?(n=``,o=!0):r===`number`&&(n=0,o=!0)}try{e[t]=n}catch{}o&&e.removeAttribute(i||t)}function q(e,t,n,r){e.addEventListener(t,n,r)}function Ie(e,t,n,r){e.removeEventListener(t,n,r)}var Le=Symbol(`_vei`);function Re(e,t,n,r,i=null){let a=e[Le]||(e[Le]={}),o=a[t];if(r&&o)o.value=r;else{let[n,s]=Be(t);r?q(e,n,a[t]=We(r,i),s):o&&(Ie(e,n,o,s),a[t]=void 0)}}var ze=/(?:Once|Passive|Capture)$/;function Be(e){let t;if(ze.test(e)){t={};let n;for(;n=e.match(ze);)e=e.slice(0,e.length-n[0].length),t[n[0].toLowerCase()]=!0}return[e[2]===`:`?e.slice(3):n(e.slice(2)),t]}var Ve=0,He=Promise.resolve(),Ue=()=>Ve||=(He.then(()=>Ve=0),Date.now());function We(e,t){let n=e=>{if(!e._vts)e._vts=Date.now();else if(e._vts<=n.attached)return;_(Ge(e,n.value),t,5,[e])};return n.value=e,n.attached=Ue(),n}function Ge(t,n){if(e(n)){let e=t.stopImmediatePropagation;return t.stopImmediatePropagation=()=>{e.call(t),t._stopped=!0},n.map(e=>t=>!t._stopped&&e&&e(t))}else return n}var Ke=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,qe=(e,t,n,r,i,a)=>{let o=i===`svg`;t===`class`?we(e,r,o):t===`style`?ke(e,n,r):ee(t)?d(t)||Re(e,t,n,r,a):(t[0]===`.`?(t=t.slice(1),!0):t[0]===`^`?(t=t.slice(1),!1):Je(e,t,r,o))?(Fe(e,t,r),!e.tagName.includes(`-`)&&(t===`value`||t===`checked`||t===`selected`)&&Pe(e,t,r,o,a,t!==`value`)):e._isVueCE&&(Ye(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!u(r)))?Fe(e,E(t),r,a,t):(t===`true-value`?e._trueValue=r:t===`false-value`&&(e._falseValue=r),Pe(e,t,r,o))};function Je(e,t,n,r){if(r)return!!(t===`innerHTML`||t===`textContent`||t in e&&Ke(t)&&ie(n));if(t===`spellcheck`||t===`draggable`||t===`translate`||t===`autocorrect`||t===`sandbox`&&e.tagName===`IFRAME`||t===`form`||t===`list`&&e.tagName===`INPUT`||t===`type`&&e.tagName===`TEXTAREA`)return!1;if(t===`width`||t===`height`){let t=e.tagName;if(t===`IMG`||t===`VIDEO`||t===`CANVAS`||t===`SOURCE`)return!1}return Ke(t)&&u(n)?!1:t in e}function Ye(e,t){let n=e._def.props;if(!n)return!1;let r=E(t);return Array.isArray(n)?n.some(e=>E(e)===r):Object.keys(n).some(e=>E(e)===r)}var Xe=new WeakMap,Ze=new WeakMap,J=Symbol(`_moveCb`),Qe=Symbol(`_enterCb`),$e=(e=>(delete e.props.mode,e))({name:`TransitionGroup`,props:r({},_e,{tag:String,moveClass:String}),setup(e,{slots:t}){let n=s(),r=re(),i,a;return ne(()=>{if(!i.length)return;let t=e.moveClass||`${e.name||`v`}-move`;if(!it(i[0].el,n.vnode.el,t)){i=[];return}i.forEach(et),i.forEach(tt);let r=i.filter(nt);V(n.vnode.el),r.forEach(e=>{let n=e.el,r=n.style;I(n,t),r.transform=r.webkitTransform=r.transitionDuration=``;let i=n[J]=e=>{e&&e.target!==n||(!e||e.propertyName.endsWith(`transform`))&&(n.removeEventListener(`transitionend`,i),n[J]=null,L(n,t))};n.addEventListener(`transitionend`,i)}),i=[]}),()=>{let o=le(e),s=ye(o),c=o.tag||ce;if(i=[],a)for(let e=0;e<a.length;e++){let t=a[e];t.el&&t.el instanceof Element&&(i.push(t),w(t,se(t,s,r,n)),Xe.set(t,rt(t.el)))}a=t.default?l(t.default()):[];for(let e=0;e<a.length;e++){let t=a[e];t.key!=null&&w(t,se(t,s,r,n))}return f(c,null,a)}}});function et(e){let t=e.el;t[J]&&t[J](),t[Qe]&&t[Qe]()}function tt(e){Ze.set(e,rt(e.el))}function nt(e){let t=Xe.get(e),n=Ze.get(e),r=t.left-n.left,i=t.top-n.top;if(r||i){let t=e.el,n=t.style,a=t.getBoundingClientRect(),o=1,s=1;return t.offsetWidth&&(o=a.width/t.offsetWidth),t.offsetHeight&&(s=a.height/t.offsetHeight),(!Number.isFinite(o)||o===0)&&(o=1),(!Number.isFinite(s)||s===0)&&(s=1),Math.abs(o-1)<.01&&(o=1),Math.abs(s-1)<.01&&(s=1),n.transform=n.webkitTransform=`translate(${r/o}px,${i/s}px)`,n.transitionDuration=`0s`,e}}function rt(e){let t=e.getBoundingClientRect();return{left:t.left,top:t.top}}function it(e,t,n){let r=e.cloneNode(),i=e[M];i&&i.forEach(e=>{e.split(/\s+/).forEach(e=>e&&r.classList.remove(e))}),n.split(/\s+/).forEach(e=>e&&r.classList.add(e)),r.style.display=`none`;let a=t.nodeType===1?t:t.parentNode;a.appendChild(r);let{hasTransform:o}=R(r);return a.removeChild(r),o}var Y=t=>{let n=t.props[`onUpdate:modelValue`]||!1;return e(n)?e=>oe(n,e):n};function at(e){e.target.composing=!0}function ot(e){let t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event(`input`)))}var X=Symbol(`_assign`);function st(e,t,n){return t&&(e=e.trim()),n&&(e=b(e)),e}var Z={created(e,{modifiers:{lazy:t,trim:n,number:r}},i){e[X]=Y(i);let a=r||i.props&&i.props.type===`number`;q(e,t?`change`:`input`,t=>{t.target.composing||e[X](st(e.value,n,a))}),(n||a)&&q(e,`change`,()=>{e.value=st(e.value,n,a)}),t||(q(e,`compositionstart`,at),q(e,`compositionend`,ot),q(e,`change`,ot))},mounted(e,{value:t}){e.value=t??``},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:r,trim:i,number:a}},o){if(e[X]=Y(o),e.composing)return;let s=(a||e.type===`number`)&&!/^0\d/.test(e.value)?b(e.value):e.value,c=t??``;if(s===c)return;let l=e.getRootNode();(l instanceof Document||l instanceof ShadowRoot)&&l.activeElement===e&&e.type!==`range`&&(r&&t===n||i&&e.value.trim()===c)||(e.value=c)}},ct={deep:!0,created(n,r,a){n[X]=Y(a),q(n,`change`,()=>{let r=n._modelValue,a=Q(n),o=n.checked,s=n[X];if(e(r)){let e=t(r,a),n=e!==-1;if(o&&!n)s(r.concat(a));else if(!o&&n){let t=[...r];t.splice(e,1),s(t)}}else if(i(r)){let e=new Set(r);o?e.add(a):e.delete(a),s(e)}else s(pt(n,o))})},mounted:lt,beforeUpdate(e,t,n){e[X]=Y(n),lt(e,t,n)}};function lt(n,{value:r,oldValue:a},o){n._modelValue=r;let s;if(e(r))s=t(r,o.props.value)>-1;else if(i(r))s=r.has(o.props.value);else{if(r===a)return;s=D(r,pt(n,!0))}n.checked!==s&&(n.checked=s)}var ut={created(e,{value:t},n){e.checked=D(t,n.props.value),e[X]=Y(n),q(e,`change`,()=>{e[X](Q(e))})},beforeUpdate(e,{value:t,oldValue:n},r){e[X]=Y(r),t!==n&&(e.checked=D(t,r.props.value))}},dt={deep:!0,created(e,{value:t,modifiers:{number:n}},r){let a=i(t);q(e,`change`,()=>{let t=Array.prototype.filter.call(e.options,e=>e.selected).map(e=>n?b(Q(e)):Q(e));e[X](e.multiple?a?new Set(t):t:t[0]),e._assigning=!0,o(()=>{e._assigning=!1})}),e[X]=Y(r)},mounted(e,{value:t}){ft(e,t)},beforeUpdate(e,t,n){e[X]=Y(n)},updated(e,{value:t}){e._assigning||ft(e,t)}};function ft(n,r){let a=n.multiple,o=e(r);if(!(a&&!o&&!i(r))){for(let e=0,i=n.options.length;e<i;e++){let i=n.options[e],s=Q(i);if(a)if(o){let e=typeof s;e===`string`||e===`number`?i.selected=r.some(e=>String(e)===String(s)):i.selected=t(r,s)>-1}else i.selected=r.has(s);else if(D(Q(i),r)){n.selectedIndex!==e&&(n.selectedIndex=e);return}}!a&&n.selectedIndex!==-1&&(n.selectedIndex=-1)}}function Q(e){return`_value`in e?e._value:e.value}function pt(e,t){let n=t?`_trueValue`:`_falseValue`;return n in e?e[n]:t}var mt={created(e,t,n){$(e,t,n,null,`created`)},mounted(e,t,n){$(e,t,n,null,`mounted`)},beforeUpdate(e,t,n,r){$(e,t,n,r,`beforeUpdate`)},updated(e,t,n,r){$(e,t,n,r,`updated`)}};function ht(e,t){switch(e){case`SELECT`:return dt;case`TEXTAREA`:return Z;default:switch(t){case`checkbox`:return ct;case`radio`:return ut;default:return Z}}}function $(e,t,n,r,i){let a=ht(e.tagName,n.props&&n.props.type)[i];a&&a(e,t,n,r)}var gt=[`ctrl`,`shift`,`alt`,`meta`],_t={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>`button`in e&&e.button!==0,middle:e=>`button`in e&&e.button!==1,right:e=>`button`in e&&e.button!==2,exact:(e,t)=>gt.some(n=>e[`${n}Key`]&&!t.includes(n))},vt=(e,t)=>{if(!e)return e;let n=e._withMods||={},r=t.join(`.`);return n[r]||(n[r]=((n,...r)=>{for(let e=0;e<t.length;e++){let r=_t[t[e]];if(r&&r(n,t))return}return e(n,...r)}))},yt={esc:`escape`,space:` `,up:`arrow-up`,left:`arrow-left`,right:`arrow-right`,down:`arrow-down`,delete:`backspace`},bt=(e,t)=>{let r=e._withKeys||={},i=t.join(`.`);return r[i]||(r[i]=(r=>{if(!(`key`in r))return;let i=n(r.key);if(t.some(e=>e===i||yt[e]===i))return e(r)}))},xt=r({patchProp:qe},he),St;function Ct(){return St||=ae(xt)}var wt=((...e)=>{let t=Ct().createApp(...e),{mount:n}=t;return t.mount=e=>{let r=Et(e);if(!r)return;let i=t._component;!ie(i)&&!i.render&&!i.template&&(i.template=r.innerHTML),r.nodeType===1&&(r.textContent=``);let a=n(r,!1,Tt(r));return r instanceof Element&&(r.removeAttribute(`v-cloak`),r.setAttribute(`data-v-app`,``)),a},t});function Tt(e){if(e instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&e instanceof MathMLElement)return`mathml`}function Et(e){return u(e)?document.querySelector(e):e}var Dt={},Ot={width:`14`,height:`14`,viewBox:`0 0 14 14`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`};function kt(e,t){return x(),m(`svg`,Ot,[...t[0]||=[v(`path`,{d:`M13 1L1 13`,stroke:`currentColor`,"stroke-width":`2`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null,-1),v(`path`,{d:`M1 1L13 13`,stroke:`currentColor`,"stroke-width":`2`,"stroke-linecap":`round`,"stroke-linejoin":`round`},null,-1)]])}var At=T(Dt,[[`render`,kt]]),jt={},Mt={width:`16`,height:`16`,viewBox:`0 0 16 16`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`};function Nt(e,t){return x(),m(`svg`,Mt,[...t[0]||=[v(`path`,{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M12.6466 13.2531L13.0001 13.6066L13.7072 12.8995L13.3537 12.546L8.7072 7.8995L13.2532 3.35352L13.6067 2.99997L12.8996 2.29286L12.5461 2.64642L8.00009 7.19239L3.45418 2.64648L3.10063 2.29292L2.39352 3.00003L2.74708 3.35358L7.29299 7.8995L2.64657 12.5459L2.29302 12.8995L3.00013 13.6066L3.35368 13.253L8.0001 8.6066L12.6466 13.2531Z`,fill:`currentColor`},null,-1)]])}var Pt=T(jt,[[`render`,Nt]]),Ft={},It={xmlns:`http://www.w3.org/2000/svg`,width:`20`,height:`20`,viewBox:`0 0 20 20`,fill:`none`};function Lt(e,t){return x(),m(`svg`,It,[...t[0]||=[v(`path`,{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M14.7331 15.7936C15.026 16.0864 15.5009 16.0864 15.7937 15.7936C16.0866 15.5007 16.0866 15.0258 15.7937 14.7329L11.3743 10.3135L15.7938 5.89408C16.0867 5.60119 16.0867 5.12631 15.7938 4.83342C15.5009 4.54052 15.026 4.54053 14.7331 4.83342L10.3137 9.25284L5.89425 4.8334C5.60136 4.54051 5.12649 4.54051 4.83359 4.8334C4.5407 5.12629 4.5407 5.60117 4.83359 5.89406L9.25303 10.3135L4.83361 14.7329C4.54072 15.0258 4.54072 15.5007 4.83361 15.7936C5.1265 16.0865 5.60138 16.0865 5.89427 15.7936L10.3137 11.3742L14.7331 15.7936Z`,fill:`currentColor`},null,-1)]])}var Rt=T(Ft,[[`render`,Lt]]);export{$e as a,dt as c,bt as d,vt as f,ve as i,Z as l,Pt as n,wt as o,At as r,mt as s,Rt as t,Ee as u};
@@ -1 +0,0 @@
1
- import{$ as e,A as t,Ct as n,D as r,E as i,H as a,Ht as o,J as s,N as c,O as l,T as u,Ut as d,Wt as f,Y as p,Z as m,lt as h,ot as g,t as _,v,vt as y,w as b}from"./viewer-Bx-vwNpl.js";import{d as x}from"./CloseA-CEkvif0J.js";import{u as S}from"./index-BWvsaYab.js";var C=[`data-element`],w=[`innerHTML`],T={key:0},E=[`onClick`],D=[`onClick`],O=[`innerHTML`],k={key:0},A=[`onClick`],j=[`onClick`],M=[`innerHTML`],N={key:0},P=[`onClick`],F=[`onClick`],I={__name:`CustomModalItem`,props:{modal:{type:Object,required:!0}},setup(i){let I=i,L=_(),R=y(null),{dataElement:z,render:B,header:V,body:H,footer:U,disableBackdropClick:W=!1,disableEscapeKeyDown:G=!1}=I.modal,K=b(()=>L.isElementOpen(z)),q=e=>e?Object.entries(e).map(([e,t])=>Number.isInteger(t)?`${e}:${t}px`:`${e}:${t}`).join(`;`):``,J=()=>{W||X()},Y=e=>{G||(e.preventDefault(),X())},X=()=>{L.closeElement(z)};g(K,async e=>{if(e&&B&&R.value){await a();let e=B();typeof e==`string`?R.value.textContent=e:e instanceof Node&&(R.value.innerHTML=``,R.value.appendChild(e))}},{immediate:!0});let Z=e=>{e.key===`Escape`&&K.value&&!G&&X()};return s(()=>{document.addEventListener(`keydown`,Z)}),p(()=>{document.removeEventListener(`keydown`,Z)}),(i,a)=>{let s=S;return K.value?(m(),l(`div`,{key:0,class:o([`Modal CustomModal`,n(z)]),"data-element":n(z),tabindex:`-1`,onClick:J,onKeydown:x(Y,[`esc`])},[c(s,{show:!0,dialogName:n(z)},t({default:h(()=>[n(H)?(m(),l(`div`,{key:0,class:o([`CustomModal-body`,n(H).className]),style:d(n(H).style)},[n(H).innerHTML?(m(),l(`div`,{key:0,innerHTML:n(H).innerHTML},null,8,O)):(m(),l(v,{key:1},[n(H).title?(m(),l(`p`,k,f(n(H).title),1)):r(``,!0),(m(!0),l(v,null,e(n(H).children,(e,t)=>(m(),l(v,{key:t},[e.button?(m(),l(`button`,{key:0,class:o([`Button`,e.className,`customEl${t}`]),style:d(q(e.style)),onClick:e.onClick},f(e.title),15,A)):(m(),l(`div`,{key:1,class:o([e.className,`customEl${t}`]),style:d(q(e.style)),onClick:e.onClick},f(e.title),15,j))],64))),128))],64))],6)):r(``,!0)]),_:2},[n(V)?{name:`header`,fn:h(()=>[u(`div`,{class:o([`CustomModal-header`,n(V).className]),style:d(n(V).style)},[n(V).innerHTML?(m(),l(`div`,{key:0,innerHTML:n(V).innerHTML},null,8,w)):(m(),l(v,{key:1},[n(V).title?(m(),l(`p`,T,f(n(V).title),1)):r(``,!0),(m(!0),l(v,null,e(n(V).children,(e,t)=>(m(),l(v,{key:t},[e.button?(m(),l(`button`,{key:0,class:o([`Button`,e.className,`customEl${t}`]),style:d(q(e.style)),onClick:e.onClick},f(e.title),15,E)):(m(),l(`div`,{key:1,class:o([e.className,`customEl${t}`]),style:d(q(e.style)),onClick:e.onClick},f(e.title),15,D))],64))),128))],64))],6)]),key:`0`}:void 0,n(U)?{name:`footer`,fn:h(()=>[u(`div`,{class:o([`CustomModal-footer`,n(U).className]),style:d(n(U).style)},[n(U).innerHTML?(m(),l(`div`,{key:0,innerHTML:n(U).innerHTML},null,8,M)):(m(),l(v,{key:1},[n(U).title?(m(),l(`p`,N,f(n(U).title),1)):r(``,!0),(m(!0),l(v,null,e(n(U).children,(e,t)=>(m(),l(v,{key:t},[e.button?(m(),l(`button`,{key:0,class:o([`Button`,e.className,`customEl${t}`]),style:d(q(e.style)),onClick:e.onClick},f(e.title),15,P)):(m(),l(`div`,{key:1,class:o([e.className,`customEl${t}`]),style:d(q(e.style)),onClick:e.onClick},f(e.title),15,F))],64))),128))],64))],6)]),key:`1`}:void 0]),1032,[`dialogName`])],42,C)):r(``,!0)}}},L={__name:`CustomModal`,props:[`dataElement`],setup(t){let n=_(),r=b(()=>n.getCustomModals);r.value.forEach(e=>n.activeElements[e.dataElement]=!1);let a=b(()=>r.value.filter(e=>!n.isElementDisabled(e.dataElement)));return(t,n)=>{let r=I;return m(!0),l(v,null,e(a.value,e=>(m(),i(r,{key:e.dataElement,modal:e},null,8,[`modal`]))),128)}}};export{L as default};
@@ -1 +0,0 @@
1
- import{Ct as e,Ht as t,N as n,O as r,T as i,Wt as a,Z as o,a as s,f as c,lt as l,ot as u,p as d,s as f,t as p,w as m}from"./viewer-Bx-vwNpl.js";import{a as h,c as g,d as _,i as v,n as y,o as b,r as x,s as S,t as C}from"./index-BWvsaYab.js";var w={class:`sidebar-title`},T={class:`mode-container`},E={class:`mode-item`},D={class:`mode-tabs`},O={class:`mode-item`},k={class:`mode-tabs`},A={class:`mode-item`},j={class:`mode-tabs`},M={__name:`RightPanelPageMode`,setup(M){let N=p(),P=g(),F=m(()=>N.isElementOpen(d.PAGE_MODE_PANEL)),I=m(()=>N.getScrollMode),L=m(()=>N.getPageMode),R=m(()=>N.getTheme),z=m(()=>P.getActiveTool);u(F,e=>{e&&z.value===c.CROP_PAGE&&P.setToolState(``)});let B=(e,t)=>{L.value!==0&&e===`Horizontal`&&(f.switchSpreadMode(0),N.setPageMode(0)),N.setScrollMode(e),f.switchScrollMode(t)},V=e=>{I.value===`Horizontal`&&(N.setScrollMode(`Vertical`),f.switchScrollMode(0)),f.switchSpreadMode(e),N.setPageMode(e)},H=e=>{e!==R.value&&N.setTheme(e)};return(c,u)=>{let d=y,f=_,p=b,m=x,g=C,M=h,N=v,P=S;return o(),r(`div`,{class:t([`page-mode-panel`,{mobile:e(s)}])},[i(`div`,w,a(c.$t(`toolbar.viewControls.viewSetting`)),1),i(`div`,T,[i(`div`,E,[i(`h2`,null,a(c.$t(`panels.pageMode.displayMode.title`)),1),i(`div`,D,[n(f,{class:t({active:L.value===0}),onClick:u[0]||=e=>V(0),title:c.$t(`panels.pageMode.displayMode.singlePage`)},{default:l(()=>[n(d)]),_:1},8,[`class`,`title`]),n(f,{class:t({active:L.value===1}),onClick:u[1]||=e=>V(1),title:c.$t(`panels.pageMode.displayMode.twoPages`)},{default:l(()=>[n(p)]),_:1},8,[`class`,`title`]),n(f,{class:t({active:L.value===2}),onClick:u[2]||=e=>V(2),title:c.$t(`panels.pageMode.displayMode.coverMode`)},{default:l(()=>[n(m)]),_:1},8,[`class`,`title`])])]),i(`div`,O,[i(`h2`,null,a(c.$t(`panels.pageMode.splitView.title`)),1),i(`div`,k,[n(f,{class:t({active:I.value===`Vertical`}),onClick:u[3]||=e=>B(`Vertical`,0),title:c.$t(`panels.pageMode.splitView.vertical`)},{default:l(()=>[n(g)]),_:1},8,[`class`,`title`]),n(f,{class:t({active:I.value===`Horizontal`}),onClick:u[4]||=e=>B(`Horizontal`,1),title:c.$t(`panels.pageMode.splitView.horizontal`)},{default:l(()=>[n(M)]),_:1},8,[`class`,`title`])])]),i(`div`,A,[i(`h2`,null,a(c.$t(`panels.pageMode.themes`)),1),i(`div`,j,[n(f,{onClick:u[5]||=e=>H(`light`),class:t({active:R.value===`light`}),title:c.$t(`toolbar.themeSwitcher.light`)},{default:l(()=>[n(N)]),_:1},8,[`class`,`title`]),n(f,{onClick:u[6]||=e=>H(`dark`),class:t({active:R.value===`dark`}),title:c.$t(`toolbar.themeSwitcher.dark`)},{default:l(()=>[n(P)]),_:1},8,[`class`,`title`])])])])],2)}}};export{M as default};
@@ -1 +0,0 @@
1
- import{$ as e,Ct as t,D as n,E as r,Ht as i,J as a,N as o,O as s,T as c,Wt as l,Z as u,a as d,f,lt as p,ot as m,p as h,s as g,t as _,ut as v,v as y,vt as b,w as x}from"./viewer-Bx-vwNpl.js";import{r as ee,u as S}from"./CloseA-CEkvif0J.js";import{c as te,d as ne,l as re,u as ie}from"./index-BWvsaYab.js";var ae=``+new URL(`../images/stamp/Approved.png`,import.meta.url).href,oe=``+new URL(`../images/stamp/NotApproved.png`,import.meta.url).href,se=``+new URL(`../images/stamp/Completed.png`,import.meta.url).href,ce=``+new URL(`../images/stamp/Final.png`,import.meta.url).href,le=``+new URL(`../images/stamp/Draft.png`,import.meta.url).href,ue=``+new URL(`../images/stamp/Confidential.png`,import.meta.url).href,de=``+new URL(`../images/stamp/ForPublicRelease.png`,import.meta.url).href,fe=``+new URL(`../images/stamp/NotForPublicRelease.png`,import.meta.url).href,pe=``+new URL(`../images/stamp/ForComment.png`,import.meta.url).href,me=``+new URL(`../images/stamp/Void.png`,import.meta.url).href,he=``+new URL(`../images/stamp/PreliminaryResults.png`,import.meta.url).href,C=``+new URL(`../images/stamp/InformationOnly.png`,import.meta.url).href,w=``+new URL(`../images/stamp/Witness.png`,import.meta.url).href,T=``+new URL(`../images/stamp/InitialHere.png`,import.meta.url).href,E=``+new URL(`../images/stamp/SignHere.png`,import.meta.url).href,D=``+new URL(`../images/stamp/revised.png`,import.meta.url).href,O=class{updateStampPreview({imgSrc:e,width:t,height:n,stampType:r,contents:i,stampColor:a,time:o}){this.width=t,this.height=n,this.imgSrc=e,this.stampType=r,this.contents=i,this.stampColor=a,this.time=o;let s=this.stampPreviewElement||document.createElement(`div`);s.innerHTML=``,s.className=`stamp-preview`,this.applyStyles(s,{position:`absolute`,border:`1px solid #00A4E4`,"z-index":85,"pointer-events":`none`,left:`-9999px`,top:`-9999px`,width:t+`px`,height:n+`px`}),document.body.appendChild(s);let c=document.createElement(`img`);this.applyStyles(c,{width:`100%`,height:`100%`}),c.src=e,s.appendChild(c);let l=document.querySelector(`.document`);l.addEventListener(`mousemove`,this.handleMouseMove.bind(this,s)),l.addEventListener(`mouseleave`,()=>{s.style.left=`-9999px`,s.style.top=`-9999px`}),this.stampPreviewElement=s}handleMouseMove(e,t){let n=e.getBoundingClientRect();this.applyStyles(e,{left:t.clientX-n.width/2+`px`,top:t.clientY-n.height/2+`px`})}handleMouseLeave(e){this.applyStyles(e,{left:-9999,top:-9999})}hidePreview(){let e=this.stampPreviewElement||document.querySelector(`.stamp-preview`);e&&(e.style.display=`none`,e.remove(),this.stampPreviewElement=null,this.width=null,this.height=null,this.imgSrc=null,this.stampType=null,this.contents=null,this.stampColor=null,this.time=null)}applyStyles(e,t){Object.keys(t).forEach(n=>{e.style[n]=t[n]})}},k={class:`sidebar-title`},A={class:`sidebar-tabs-header`},j={class:`sidebar-content`},M={key:0,class:`standard-container`},N={class:`block`},P={class:`block`},F={class:`block`},I={class:`block`},L={class:`block`},R={class:`block`},ge={class:`block`},_e={class:`block`},ve={class:`block`},ye={class:`block`},be={class:`block`},xe={class:`block`},Se={class:`block`},Ce={class:`block`},we={class:`block`},z={class:`block`},Te={key:1,class:`customize-container`},Ee={class:`dynamic-stamp red`},De={class:`dynamic-stamp green`},Oe={key:2,class:`custom-container`},ke={key:0,class:`empty-list`},Ae=[`src`],je={class:`create-container`},Me={key:3,class:`custom-container`},Ne={key:0,class:`empty-list`},Pe={class:`stamps-container`},Fe=[`src`],Ie={key:0,class:`delete-page-popup`},Le={__name:`StampPanel`,setup(Le){let{switchTool:Re,switchAnnotationEditorMode:ze}=g,B=_(),Be=te(),V=b(!1),H=b(0),U=b(null),W=x(()=>B.getActiveElementTab(h.STAMP_PANEL)),Ve=x(()=>B.isElementOpen(h.STAMP_PANEL)),He=x(()=>Be.getActiveTool),G=x(()=>B.getCustomStamps),K=x(()=>B.getStampPanelTabs),q=x(()=>B.getImportStamps),J=b(``),Y=new O,Ue=()=>{B.openElement(`createCustomStampDialog`)};a(()=>{Z(),setInterval(Z,1e3);let e=document.querySelector(`.document-container`);e&&e.addEventListener(`click`,Ge)}),m(G.value,()=>{G.value.length&&(Array.isArray(U.value)?U.value[0]:U.value)?.scrollTo({top:0,behavior:`smooth`})});let We=e=>{let t=g.getScrollViewElement();if(!t)return;let n=t.scrollLeft||0,r=t.scrollTop||0,{pageX:i,pageY:a}=e;return{x:i+n,y:a+r}},Ge=e=>{let t=We(e),n=g.getSelectedPage(t,t).first;if(n<1)return;let r=g.windowToPage(t,n);if(Y.stampPreviewElement){let{width:e,height:t}=Y,i={stampType:Y.stampType,page:n,rect:{x:r.x-e/2,y:r.y-t/2,width:e,height:t}};Y.stampType===`dynamic`?(i.stampColor=Y.stampColor,i.stampShape=0,i.contents=Y.contents,i.time=J.value):Y.stampType===`image`?i.imageBase64=Y.imgSrc:i.contents=Y.contents,g.handleStamp(i),Y.hidePreview(),window.innerWidth<=640&&(B.toggleActiveHand(!1),Re(0),ze(0),B.closeElement(h.STAMP_PANEL))}};m(()=>He.value,(e,t)=>{e!==f.STAMP&&B.closeElement(h.STAMP_PANEL)}),m(()=>Ve.value,(e,t)=>{e&&X(h.STANDARD)});let X=e=>{B.setActiveElementTab(h.STAMP_PANEL,e)},Z=()=>{J.value=Ke(new Date)},Ke=e=>{let t=e.getFullYear(),n=String(e.getMonth()+1).padStart(2,`0`);return`${String(e.getDate()).padStart(2,`0`)}/${n}/${t} ${String(e.getHours()).padStart(2,`0`)}:${String(e.getMinutes()).padStart(2,`0`)}:${String(e.getSeconds()).padStart(2,`0`)}`},Q=async(e,t)=>{let n=await g.getDynamicStampPreview({contents:t,time:J.value,stampColor:e,stampShape:0});Y.updateStampPreview({imgSrc:n.imgSrc,width:n.width,height:n.height,stampType:`dynamic`,stampColor:e,contents:t,stampShape:0,time:J.value})},$=(e,t,n)=>{t===`standard`?Y.updateStampPreview({imgSrc:e.target.src,width:e.target.width,height:e.target.height,stampType:`standard`,contents:n}):Y.updateStampPreview({imgSrc:e.target.src,width:e.target.width,height:e.target.height,stampType:`image`,contents:n})},qe=e=>{V.value=!0,H.value=e},Je=()=>{B.removeCustomStamp(H.value),V.value=!1};return(a,f)=>{let m=ne,g=ee,_=re,b=ie;return u(),s(`div`,{class:i([`stamp-panel`,{mobile:t(d)}])},[c(`div`,k,l(a.$t(`toolbar.annotationTools.stamp`)),1),c(`div`,A,[(u(!0),s(y,null,e(K.value,e=>(u(),r(m,{class:i({active:W.value===e.dataElement,mobile:t(d)&&e.dataElement===`CUSTOM`}),isActive:W.value===e.dataElement,"data-element":e.dataElement,onClick:t=>X(e.dataElement)},{default:p(()=>[c(`span`,null,l(e.text?e.text:a.$t(`panels.stamp.`+e.dataElement.toLowerCase())),1)]),_:2},1032,[`class`,`isActive`,`data-element`,`onClick`]))),256))]),c(`div`,j,[(u(!0),s(y,null,e(K.value,r=>(u(),s(y,null,[r.dataElement===t(h).STANDARD?v((u(),s(`div`,M,[c(`div`,N,[c(`img`,{onClick:f[0]||=e=>$(e,`standard`,`Approved`),src:ae,alt:`Approved`})]),c(`div`,P,[c(`img`,{onClick:f[1]||=e=>$(e,`standard`,`Not Approved`),src:oe,alt:`Not Approved`})]),c(`div`,F,[c(`img`,{onClick:f[2]||=e=>$(e,`standard`,`Completed`),src:se,alt:`Completed`})]),c(`div`,I,[c(`img`,{onClick:f[3]||=e=>$(e,`standard`,`Final`),src:ce,alt:`Final`})]),c(`div`,L,[c(`img`,{onClick:f[4]||=e=>$(e,`standard`,`Draft`),src:le,alt:`Draft`})]),c(`div`,R,[c(`img`,{onClick:f[5]||=e=>$(e,`standard`,`Confidential`),src:ue,alt:`Confidential`})]),c(`div`,ge,[c(`img`,{onClick:f[6]||=e=>$(e,`standard`,`For Public Release`),src:de,alt:`For Public Release`})]),c(`div`,_e,[c(`img`,{onClick:f[7]||=e=>$(e,`standard`,`Not For Public Release`),src:fe,alt:`Not For Public Release`})]),c(`div`,ve,[c(`img`,{onClick:f[8]||=e=>$(e,`standard`,`For Comment`),src:pe,alt:`For Comment`})]),c(`div`,ye,[c(`img`,{onClick:f[9]||=e=>$(e,`standard`,`Void`),src:me,alt:`Void`})]),c(`div`,be,[c(`img`,{onClick:f[10]||=e=>$(e,`standard`,`Preliminary Results`),src:he,alt:`Preliminary Results`})]),c(`div`,xe,[c(`img`,{onClick:f[11]||=e=>$(e,`standard`,`Information Only`),src:C,alt:`Information Only`})]),c(`div`,Se,[c(`img`,{onClick:f[12]||=e=>$(e,`standard`,`Witness`),src:w,alt:`Witness`})]),c(`div`,Ce,[c(`img`,{onClick:f[13]||=e=>$(e,`standard`,`Initial Here`),src:T,alt:`Initial Here`})]),c(`div`,we,[c(`img`,{onClick:f[14]||=e=>$(e,`standard`,`Sign Here`),src:E,alt:`Sign Here`})]),c(`div`,z,[c(`img`,{onClick:f[15]||=e=>$(e,`standard`,`revised`),src:D,alt:`revised`})])],512)),[[S,W.value===t(h).STANDARD]]):r.dataElement===t(h).DYNAMIC?v((u(),s(`div`,Te,[c(`div`,{class:`block`,onClick:f[16]||=e=>Q(1,`REVISED`)},[c(`div`,Ee,[f[22]||=c(`p`,{class:`title`},`REVISED`,-1),c(`p`,null,l(J.value),1)])]),c(`div`,{class:`block`,onClick:f[17]||=e=>Q(2,`REVIEWED`)},[c(`div`,De,[f[23]||=c(`p`,{class:`title`},`REVIEWED`,-1),c(`p`,null,l(J.value),1)])])],512)),[[S,W.value===t(h).DYNAMIC]]):r.dataElement===t(h).CUSTOM?v((u(),s(`div`,Oe,[G.value&&G.value.length===0?(u(),s(`div`,ke,l(a.$t(`panels.stamp.createHere`)),1)):n(``,!0),c(`div`,{ref_for:!0,ref_key:`stampsRef`,ref:U,class:`stamps-container`},[(u(!0),s(y,null,e(G.value,(e,t)=>(u(),s(`div`,{class:`block`,key:t},[c(`img`,{onClick:f[18]||=e=>$(e,`custom`,``),src:e},null,8,Ae),o(m,{class:`close-button`,onClick:e=>qe(t)},{default:p(()=>[o(g)]),_:1},8,[`onClick`])]))),128))],512),c(`div`,je,[c(`div`,{class:`create-button`,onClick:f[19]||=e=>Ue()},l(a.$t(`panels.stamp.create`)),1)])],512)),[[S,W.value===t(h).CUSTOM]]):r.type===`custom`?v((u(),s(`div`,Me,[q.value.length===0?(u(),s(`div`,Ne,l(a.$t(`panels.stamp.importStamp`)),1)):n(``,!0),c(`div`,Pe,[(u(!0),s(y,null,e(q.value,(e,t)=>(u(),s(`div`,{class:`block`,key:t},[c(`img`,{onClick:f[20]||=e=>$(e,`custom`,``),src:e},null,8,Fe)]))),128))])],512)),[[S,W.value===r.dataElement]]):n(``,!0)],64))),256))]),V.value?(u(),s(`div`,Ie,[o(b,{show:V.value,dialogName:a.dialogName},{footer:p(()=>[c(`div`,{class:`rect-button white`,onClick:f[21]||=e=>V.value=!1},l(a.$t(`common.actions.cancel`)),1),c(`div`,{class:`rect-button blue`,onClick:Je},l(a.$t(`common.actions.ok`)),1)]),default:p(()=>[o(_),c(`p`,null,l(a.$t(`signatures.deleteConfirm`)),1)]),_:1},8,[`show`,`dialogName`])])):n(``,!0)],2)}}};export{Le as default};