1 line
20 KiB
JavaScript
1 line
20 KiB
JavaScript
|
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-49636333"],{"13a3":function(e,t,a){"use strict";a("bada")},"182d":function(e,t,a){var o=a("f8cd"),r=RangeError;e.exports=function(e,t){var a=o(e);if(a%t)throw r("Wrong offset");return a}},"1d02":function(e,t,a){"use strict";var o=a("ebb5"),r=a("a258").findLastIndex,n=o.aTypedArray,c=o.exportTypedArrayMethod;c("findLastIndex",(function(e){return r(n(this),e,arguments.length>1?arguments[1]:void 0)}))},"2ae1":function(e,t,a){},"3c5d":function(e,t,a){"use strict";var o=a("da84"),r=a("c65b"),n=a("ebb5"),c=a("07fa"),l=a("182d"),i=a("7b0b"),d=a("d039"),s=o.RangeError,u=o.Int8Array,b=u&&u.prototype,f=b&&b.set,p=n.aTypedArray,h=n.exportTypedArrayMethod,j=!d((function(){var e=new Uint8ClampedArray(2);return r(f,e,{length:1,0:3},1),3!==e[1]})),O=j&&n.NATIVE_ARRAY_BUFFER_VIEWS&&d((function(){var e=new u(2);return e.set(1),e.set("2",1),0!==e[0]||2!==e[1]}));h("set",(function(e){p(this);var t=l(arguments.length>1?arguments[1]:void 0,1),a=i(e);if(j)return r(f,this,a,t);var o=this.length,n=c(a),d=0;if(n+t>o)throw s("Wrong length");while(d<n)this[t+d]=a[d++]}),!j||O)},"77d9":function(e,t,a){a("1d02")},"8e74":function(e,t,a){"use strict";a("caad"),a("d9e2"),a("907a"),a("3c5d"),a("fa9e"),a("77d9");var o=a("7a23"),r=a("bc3a"),n=a.n(r),c=a("fedc");function l(e,t,a){a.width=t.width,a.height=t.height;const o=t.naturalHeight/t.height,r=a.getContext("2d");r.drawImage(t,0,0,a.width,a.height),e.forEach(e=>{r.beginPath(),r.strokeStyle="red",r.moveTo(e[0][0]/o,e[0][1]/o),r.lineTo(e[1][0]/o,e[1][1]/o),r.lineTo(e[2][0]/o,e[2][1]/o),r.lineTo(e[3][0]/o,e[3][1]/o),r.closePath(),r.stroke()})}var i=a("5502");const d=e=>(Object(o["pushScopeId"])("data-v-c62807bc"),e=e(),Object(o["popScopeId"])(),e),s={class:"flex align-center"},u=d(()=>Object(o["createElementVNode"])("h3",null,"提取文件类型:",-1)),b=Object(o["createTextVNode"])("文件解析"),f=Object(o["createTextVNode"])("图片解析"),p=d(()=>Object(o["createElementVNode"])("h1",null,"文件文本提取工具",-1)),h=d(()=>Object(o["createElementVNode"])("p",null,"上传文件提取文本内容(支持 .txt, .pdf, .docx, mp4 , mp3, wav)",-1)),j={class:"container"},O=d(()=>Object(o["createElementVNode"])("input",{type:"file",id:"file-input",accept:".txt,.pdf,.docx,'.mp4','.mp3','.wav'"},null,-1)),v={id:"file-info"},m=d(()=>Object(o["createElementVNode"])("button",{id:"extract-btn",disabled:""},"提取文本",-1)),y=d(()=>Object(o["createElementVNode"])("h3",null,"提取结果:",-1)),g={id:"result"},w={"element-loading-text":"模型加载中......"},x={class:"flex align-center just-between"},C=d(()=>Object(o["createElementVNode"])("h1",null,"文件文本提取工具",-1)),V={title:"刷新",class:"pointer"},k=d(()=>Object(o["createElementVNode"])("p",null,"上传文件提取文本内容(支持 .png, .jpg )",-1)),A={class:"container flex",style:{height:"248px"}},E={class:"mr10"},T=Object(o["createTextVNode"])("上传图片"),N={id:"file-info"},B={class:"box"},S={class:"imd"},_=["src"],I=["src"],R={class:"imd"},D=d(()=>Object(o["createElementVNode"])("h3",null,"提取结果:",-1)),L={class:"textModel noScollLine","element-loading-text":"图片解析中......"},z={key:0},P=Object(o["createTextVNode"])("取消"),F=Object(o["createTextVNode"])("确认");var U={__name:"index",props:{modelValue:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(e,{emit:t}){const a=e,r=Object(i["b"])(),d=Object(o["ref"])("请先上传文件..."),U=Object(o["ref"])("未选择文件"),{proxy:K}=Object(o["getCurrentInstance"])(),M=Object(o["ref"])("文件解析"),$=Object(o["ref"])(!1),H=Object(o["ref"])({}),W=Object(o["ref"])(!0),Y=Object(o["ref"])(!1),G=Object(o["ref"])(""),J=Object(o["ref"])("请先上传文件..."),q=Object(o["ref"])([]),Q=Object(o["ref"])(),X=Object(o["ref"])(),Z=Object(o["reactive"])({width:"",height:""}),ee=Object(o["ref"])({Authorization:r.getters.token}),te=Object(o["ref"])(""),ae=Object(o["ref"])(""),oe=()=>{W.value=!imgIsLoad,$.value=!!imgIsLoad,Object(o["nextTick"])(()=>{const e=document.getElementByI
|