PageSourceSearch

https://cloud.tipo.gov.tw/S400/_next/static/chunks/pages/patent/search/result-2681961aaf4620b7.js

js tipo.gov.tw collected 2026-09-24 09:00:34 UTC 112,873 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5160],{90948:function(n,e,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/patent/search/result",function(){return t(90566)}])},90566:function(n,e,t){"use strict";t.r(e),t.d(e,{default:function(){return rS}});var i,r,o=t(7297),a=t(85893),l=t(53923),c=t(29136),s=t(67294),d=t(50066),u=t(48038),p=t(88014),x=t(45699),f=t(30493),h=t(39441),g=t(10522),m=t(50576),v=t(36631),w=t(46657),y=t(8100),b=t(8762),j=t(67630),Z=t(49770);let C={keyCode:"IC",facetFieldCounts:[]},k=n=>{let{displayName:e,expandingFacet:t,facet:i,selectedField:r,handleFacetExpand:o,handleFieldSelect:l,handleFieldCancel:c}=n,{data:s}=(0,Z.Z)(["ipc/descriptions",i.facetFieldCounts.map(n=>n.name)],async(n,e)=>{let t=await (0,v.ti)({}).post(n,e).then(n=>n.data).catch(n=>((0,j.Po)(n),{}));return{keyCode:i.keyCode,facetFieldCounts:i.facetFieldCounts.map(n=>{let e=t[n.name]||void 0;return{...n,name:n.name+(e?" "+e:"")}})}}),d=(n,e)=>l(n,{...e,name:e.identity}),u=void 0===s;return(0,a.jsx)(w.Z,{displayName:e,isFieldsLoading:u,facet:u?C:s,expandingFacet:t,selectedField:r,handleFacetExpand:o,handleFieldSelect:d,handleFieldCancel:c})},I=n=>n.filter(n=>(0,b._)(n.keyCode)).map(n=>({keyCode:n.keyCode,facetFieldCounts:n.patentFacetFieldCount.map(n=>({...n,identity:n.identity||n.name}))})),P=(n,e)=>{let t=e.find(e=>e.keyCode===n);return t?{identity:t.identity,name:t.keyword}:void 0},S=n=>{let{expandingFacet:e,setDisplayingFacet:t,setIsLoading:i}=n,r=(0,x.I)(n=>n.basicRequest,m.Z),o=(0,x.I)(n=>n.dedupe),l=(0,x.I)(n=>n.bilingualTerm),c=(0,x.I)(n=>n.advanceKeywords,m.Z),{setFacets:d}=(0,x.I)(n=>({setFacets:n.setFacets})),u=(0,x.I)(n=>n.ptab),[p,f]=(0,x.I)(n=>[n.addAdvanceKeyword,n.removeAdvanceKeyword,n.setDedupe,n.setBilingualTerm]),h=(0,s.useMemo)(()=>({...r,advanceKeywords:c,dedupe:o,bilingualTerm:l,ptab:u}),[c,r,l,o,u]),{data:g,error:j}=(0,y.ZP)(["patent/search/facet",h],(n,e)=>(0,v.ti)({}).post(n,e).then(n=>I(n.data)),{revalidateOnFocus:!1,shouldRetryOnError:!1,onSuccess:n=>{d(n)}}),Z=void 0===g&&void 0===j;(0,s.useEffect)(()=>{i(Z)},[Z,i]);let C=(n,e)=>{t(void 0),p({keyCode:n,keyword:e.name,identity:e.identity})},S=g&&g.reduce((n,e)=>n+e.facetFieldCounts.length,0)>0,F=n=>"IC"===n.keyCode?(0,a.jsx)(k,{displayName:(0,b.X)(n.keyCode),facet:n,expandingFacet:e,selectedField:P(n.keyCode,c),handleFacetExpand:t,handleFieldSelect:C,handleFieldCancel:f},n.keyCode):(0,a.jsx)(w.Z,{displayName:(0,b.X)(n.keyCode),facet:n,expandingFacet:e,selectedField:P(n.keyCode,c),handleFacetExpand:t,handleFieldSelect:C,handleFieldCancel:f},n.keyCode);return Z?(0,a.jsx)(a.Fragment,{}):(0,a.jsx)(a.Fragment,{children:S?g.map(n=>n.facetFieldCounts.length>0&&F(n)):(0,a.jsx)(a.Fragment,{})})},F="BILINGUAL",A={keyCode:F,facetFieldCounts:[]},R=n=>({keyCode:F,facetFieldCounts:n.map(n=>({name:n.term,identity:n.term,count:n.count}))}),T=n=>{let{expandingFacet:e,setDisplayingFacet:t}=n,i=(0,x.I)(n=>n.basicRequest,m.Z),r=(0,x.I)(n=>n.bilingualTerm),o=(0,x.I)(n=>n.advanceKeywords,m.Z),[l]=(0,x.I)(n=>[n.setBilingualTerm]),c=(0,x.I)(n=>n.ptab),s={keyword:c?"".concat(i.queryString," AND ptab=").concat(c):i.queryString,advanceKeywords:o},{data:d,error:u}=(0,y.ZP)(["patent/search/bilingual/facet",s],(n,e)=>(0,v.ti)({}).post(n,e).then(n=>R(n.data)),{revalidateOnFocus:!1,shouldRetryOnError:!1});if(d&&0===d.facetFieldCounts.length)return(0,a.jsx)(a.Fragment,{});let p=(n,e)=>{t(void 0),l(e.name)},f=void 0===d&&void 0===u;return(0,a.jsx)(w.Z,{displayName:(0,b.X)(F),facet:f?A:d||A,isFieldsLoading:f,expandingFacet:e,selectedField:r?{identity:r,name:r}:void 0,handleFacetExpand:t,handleFieldSelect:p,handleFieldCancel:()=>l("")})},E={name:"檢索去重",identity:"dedupe"},z=n=>{let{expandingFacet:e,setDisplayingFacet:t}=n,i=(0,x.I)(n=>n.dedupe),r=(0,x.I)(n=>n.setDedupe),o=(0,x.I)(n=>n.facets),l=()=>{t(void 0),r(!0)},c=o&&o.reduce((n,e)=>n+e.facetFieldCounts.length,0)>0;return(0,a.jsx)(a.Fragment,{children:c?(0,a.jsx)(w.Z,{displayName:"檢索去重",facet:{keyCode:"DEDUPE",facetFieldCounts:[E]},selectedField:i?E:void 0,expandingFacet:e,handleFacetExpand:t,handleFieldSelect:l,handleFieldCancel:()=>r(!1)}):(0,a.jsx)(a.Fragment,{})})};var L=t(34134),_=t(72543),N=t(84357),M=t(95600),D=t(50779),O=t(53340);function X(){let n=(0,o.Z)(["\n      display: none;\n    "]);return X=function(){return n},n}function U(){let n=(0,o.Z)(["\n  padding: 16px 0;\n  background-color: ",";\n  border: 1px solid ",";\n\n  ","\n  @media (min-width: ",") {\n    padding: 0;\n    min-height: 50px;\n  }\n"]);return U=function(){return n},n}let Y=d.ZP.div.withConfig({componentId:"sc-c65fe8db-0"})(U(),D.Xt,D.yf,n=>n.hide&&(0,d.iv)(X()),O.zp),q=n=>{let{useButton:e=!1,inHeader:t}=n,i=(0,x.I)(n=>n.advanceKeywords,m.Z),r=(0,x.I)(n=>n.dedupe),o=(0,x.I)(n=>
1n.bilingualTerm),[l,c]=(0,s.useState)(!1),[d,u]=(0,s.useState)(!0),[p,f]=(0,s.useState)(),h=n=>{n||f(void 0),c(n)},g=p?(0,b.X)(p.keyCode)||p.keyCode:"篩選",v=i.filter(n=>(0,b._)(n.keyCode)),w=r||o||v.length>0,{size:y}=(0,M.Z)(),j="small"===y||"medium"===y;return(0,a.jsx)(a.Fragment,{children:e?j&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(_.Z,{onClick:()=>h(!0),selected:!!w,primary:t,large:!t,text:"篩選"}),(0,a.jsxs)(N.default,{title:g,open:l,setOpen:h,backButton:p?{preventDefault:!0,onClick:()=>f(void 0)}:void 0,children:[d&&(0,a.jsx)(L.$,{margin:"130px auto 96px auto"}),(0,a.jsxs)(Y,{hide:d,children:[(0,a.jsx)(z,{expandingFacet:null==p?void 0:p.keyCode,setDisplayingFacet:f}),(0,a.jsx)(T,{expandingFacet:null==p?void 0:p.keyCode,setDisplayingFacet:f}),(0,a.jsx)(S,{expandingFacet:null==p?void 0:p.keyCode,setDisplayingFacet:f,setIsLoading:u})]})]})]}):!j&&(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)(Y,{children:[(0,a.jsx)(z,{expandingFacet:null==p?void 0:p.keyCode,setDisplayingFacet:f}),(0,a.jsx)(T,{expandingFacet:null==p?void 0:p.keyCode,setDisplayingFacet:f}),(0,a.jsx)(S,{expandingFacet:null==p?void 0:p.keyCode,setDisplayingFacet:f,setIsLoading:u})]})})})};var H=t(73454),B=t(20122),K=t(82031),V=t(65889);let G=n=>{let{onClick:e}=n,[t,i]=(0,V.Z)(!1),r=(0,x.I)(n=>n.basicRequest.queryString),o=(0,s.useMemo)(()=>({subscribeName:r,criteria:r}),[r]);return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(B.T,{third:!1,sideThird:!0,onClick:()=>{i(n=>!n),e&&e()}}),(0,a.jsx)(K.Z,{open:t,setOpen:i,defaultValues:o})]})};var W=t(76248),$=t(53855);let J=n=>{let{message:e}=n;return(0,a.jsx)($.W2,{children:(0,a.jsx)($.v0,{children:e})})};var Q=t(34736),nn=t(52091);let ne=n=>{let{content:e,appendKeyword:t}=n,[i,r]=(0,s.useState)(!0),o=n=>{n.stopPropagation(),r(!i)};return(0,a.jsxs)($._6,{children:[(0,a.jsxs)($.O4,{onClick:()=>t(e.keyword),children:[(0,a.jsx)($.dA,{children:e.keyword}),e.subKeywords&&(0,a.jsx)($.nW,{onClick:o,children:i?(0,a.jsx)(nn.$Pg,{}):(0,a.jsx)(nn.iUH,{})})]}),e.subKeywords&&(0,a.jsx)($.Bl,{isShow:i,children:e.subKeywords.map(n=>(0,a.jsx)("p",{onClick:()=>t(n),children:n},n))})]},e.keyword)};var nt=t(43216);let ni=n=>{let{content:e,colorIndex:t}=n,{basicRequest:i,setBasicRequest:r,setUserCriteria:o,industrialClasses:l}=(0,x.I)(),[c,d]=(0,s.useState)(!1),u=n=>n>0?"行業 (".concat(n,")"):nt.b,p=n=>{let e=n.trim(),t=u(l.length);e.length>0&&(r({queryString:e}),o(t+" : ".concat(n)))},f=()=>{let n=e.keyword;p("".concat(i.queryString,' AND "').concat(n,'"'))},h=n=>{p("".concat(i.queryString,' AND "').concat(n,'"'))},g=n=>{n.stopPropagation(),d(!c)},m=void 0!==t&&D.tR[t]?D.tR[t].txt:void 0;return(0,a.jsxs)($.W2,{children:[(0,a.jsxs)($.iM,{color:m,onClick:f,children:[(0,a.jsx)($.dA,{children:e.keyword}),e.subClusters&&(0,a.jsx)($.nW,{onClick:g,children:c?(0,a.jsx)(nn.$Pg,{}):(0,a.jsx)(nn.iUH,{})})]}),e.subClusters&&(0,a.jsx)($.al,{isShow:c,children:e.subClusters.map(n=>(0,a.jsx)(ne,{content:n,appendKeyword:h},n.keyword))})]})};var nr=t(94751),no=t(96486),na=t.n(no),nl=t(63657);function nc(n,e,t){return null==n||n.length<=e?n:n.substring(0,e-t)+"..."+n.substring(n.length-t)}function ns(){let n=(0,o.Z)(["\n  text-align: center;\n  color: ",";\n  max-width: 180px;\n"]);return ns=function(){return n},n}let nd=d.ZP.div.withConfig({componentId:"sc-7a6266cc-0"})(ns(),D.di),nu=n=>{let[e,t]=(0,s.useState)(),[i,r]=(0,s.useState)(),o=(0,s.useRef)(null);return(0,s.useEffect)(()=>{t(np(n.mapData))},[n.mapData]),(0,s.useEffect)(()=>{if(e){nr.Ys(o.current).selectAll("*").remove();let i=n.mapData.children?n.mapData.children.map(n=>n.text):[],a=n=>{let e=D.ST;if(1===n.data.level){let t=i.findIndex(e=>e===n.data.text);t>=0&&(e=D.tR[t])}else 2===n.data.level?e=D.LH:3===n.data.level&&(e=D.$J);return e},l=n=>0===n.depth?36:24,c=n=>{let e="15px",t=n.data.text?n.data.text.length:0;return 0!==n.depth&&t>4&&(e="12px"),0!==n.depth&&t>6&&(e="10px"),e},s=n=>{let e=nr.Ys(n).text().length,t=4;switch(e){case 4:t=2;break;case 5:case 6:t=3}let i=15*t+4;!function(n,e,t){n.each(function(){let n=void 0!==t?t:5,i=RegExp("(.{1,"+n+"}W)|(.{1,"+n+"})","gm"),r=nr.Ys(this),o=(r.text().match(i)||[]).reverse(),a=r.attr("y")||"0",l=parseFloat(r.attr("dy")||"0"),c,s=[],d=0,u=r.text(null).append("tspan").attr("x",0).attr("y",a).attr("dy",l+"em");for(;c=o.pop();){s.push(c),u.text(s.join(""));let p=u.node();p&&p.getComputedTextLength()>e&&(s.pop(),u.text(s.join("")),s=[c],u=r.append("tspan").attr("x",0).attr("y",a).attr("dy",1.2*++d+l+"em").text(c))}})}(nr.Ys(n),i,t)},d=(n,e,t)=>{let i=u.node();return{left:n.pageX-window.scrollX,top:i?i.getBoundingClientRect().top+32:n.pageY-window.scrollY,text:t}},u=nr.Ys(o.current).append("g").attr("class","root").attr("transform","translate(123,130)"),p=nr.G_s().size([360,83]).separation(function(n,e){return(n.parent===e.parent?1:2)/n.depth}),x=nr.bT9(e,function(n){return n.children});x.children&&x.children.filter(n=>n),x=p(x);let f=u.append("g").attr("class","line").selectAll("line").data(x.links()).enter().append("line").attr("stroke-width",1).attr("stroke","#d0d4d6"),h=u.selectAll(".node").data(x.descendants()).enter().append("g").attr("class","node").style("cursor",n=>0!==n.data.level&&3!==n.data.level&&"pointer");h.append("circle").attr("r",n=>l(n)).style("fill",n=>a(n).bg),h.append("text").text(n=>n.data.text).attr("text-anchor","middle").style("user-select","none").attr("fill",n=>a(n).txt).attr("y",n=>n.data.text&&n.data.text.length>3?-3:3),h.selectAll("text").each(function(){s(this)}),h.selectAll("tspan").style("font-size",n=>c(n)),h.on("mouseenter",function(e,t){nr.Ys(this).select("circle").attr("r",1.1*l(t)),0===t.data.level&&r(d(e,t,n.toolTipText))}).on("mouseleave",function(n,e){nr.Ys(this).select("circle").attr("r",l(e)),r(void 0)}).on("click",(n,e)=>{console.log("d",e),g(e)});let g=e=>{0!==e.data.level&&3!==e.data.level&&(f.merge(f.selectAll("line")).transition().duration(500).style("opacity","0").attr("x1",0).attr("y1",0).attr("x2",0).attr("y2",0),h.merge
1(h.selectAll(".node")).transition().duration(500).attr("transform","translate(0,0)").style("opacity","0"),u.transition().duration(500).remove().on("end",()=>t(np(n.mapData,e))))};f.style("opacity","0").attr("transform",n=>"rotate("+(-n.target.x-45)+")").transition().duration(500).style("opacity","1").attr("x1",n=>n.source.y).attr("y1",n=>n.source.x/180*Math.PI).attr("x2",n=>n.target.y).attr("y2",n=>n.target.x/180*Math.PI),h.style("opacity","0").transition().duration(500).style("opacity","1").attr("transform",n=>"rotate("+(-n.x-45)+")translate("+n.y+")rotate("+(n.x+45)+")")}},[e,n.mapData,n.toolTipText]),(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("svg",{ref:o,width:246,height:260}),i&&""!==i.text&&(0,a.jsx)(nl.Z,{left:i.left,top:i.top,overlay:(0,a.jsx)(nd,{children:(0,a.jsx)("div",{children:i.text})})})]})},np=(n,e)=>{let t;let i=e?e.data.text:n.text,r=na().cloneDeep(n),o=r.children||[];if(e&&0!==e.depth&&1===e.data.level)t=o.find(n=>n.text===i);else if(e&&0!==e.depth&&2===e.data.level){let a=o.find(n=>n.text===e.data.parentText),l=a&&a.children||[];t=l.find(n=>n.text===i)}else e&&0===e.depth&&1===e.data.level?t=r:e&&0===e.depth&&2===e.data.level&&(t=o.find(n=>n.text===e.data.parentText));return t&&(r=t),r.children&&r.children.forEach(n=>{n.children=void 0}),r},nx="檢索條件",nf=n=>{let e=[];return n.forEach(n=>{let t={text:n.keyword,parentText:nx,level:1};if(n.subClusters){let i=[];n.subClusters.forEach(e=>{let t={text:e.keyword,parentText:n.keyword,level:2};e.subKeywords&&(t.children=e.subKeywords.map(n=>({text:n,parentText:e.keyword,level:3}))),i.push(t)}),t.children=i}e.push(t)}),{text:nx,children:e,level:0}},nh=()=>{let[n,e]=(0,s.useState)(null),[t,i]=(0,s.useState)(!1),{resultTotalCount:r,country:o,basicRequest:l,ptab:c}=(0,x.I)(),d=c?"".concat(l.queryString," AND ptab=").concat(c):l.queryString;return((0,s.useEffect)(()=>{let n=async()=>{if("string"==typeof d&&""!==d.trim())try{let n=await (0,v.ti)({useOnPremisesApi:!0}).get("patent/search/cluster?country=".concat(o,"&query=").concat(d,"&totalCount=").concat(r));e(n.data)}catch(t){(0,j.Po)(t),i(!0)}};n()},[o,d,r]),"string"!=typeof d||""===d.trim())?(0,a.jsx)(J,{message:"本次檢索結果未進行聚類分析,請先輸入關鍵字。"}):n&&r>n.dataMax?(0,a.jsx)(J,{message:"本次檢索結果超過 ".concat((0,Q.tV)(n.dataMax)," 筆\n            ,超過聚類上限,請嘗試變更檢索條件。")}
1):n||""===d.trim()?n&&n.clusters&&0!==n.clusters.length?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)($.lZ,{children:(0,a.jsx)(nu,{mapData:nf(n.clusters),toolTipText:d})}),(0,a.jsx)($.W2,{children:(0,a.jsx)($.su,{children:"主題知識地圖架構"})}),(0,a.jsx)($.gz,{children:n.clusters.map((n,e)=>(0,a.jsx)(ni,{content:n,colorIndex:e},n.keyword))})]}):(0,a.jsx)(J,{message:"本次檢索結果主題性不足或是查無資料,請嘗試變更產業類別或修改關鍵字。"}):t?(0,a.jsx)(J,{message:"聚類分析服務發生錯誤,請稍後再嘗試重新查詢。"}):(0,a.jsx)($.W2,{children:(0,a.jsx)(L.$,{margin:"58px auto"})})};function ng(){let n=(0,o.Z)(["\n  display: flex;\n  align-items: center;\n  margin-top: 4px;\n  margin-left: 16px;\n  gap: 20px;\n"]);return ng=function(){return n},n}function nm(){let n=(0,o.Z)(["\n  svg {\n    color: ",";\n  }\n  :hover {\n    cursor: pointer;\n  }\n"]);return nm=function(){return n},n}let nv=d.ZP.div.withConfig({componentId:"sc-8b5e9545-0"})(ng()),nw=d.ZP.div.withConfig({componentId:"sc-8b5e9545-1"})(nm(),n=>(0,D.mQ)(n.isActive?1:.6)),ny=n=>{let{isGridMode:e,setIsGridMode:t}=n;return(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)(nv,{children:[(0,a.jsx)(nw,{isActive:e,children:(0,a.jsx)(nn.xyo,{onClick:()=>t(!0)})}),(0,a.jsx)(nw,{isActive:!e,children:(0,a.jsx)(nn.MJA,{onClick:()=>t(!1)})})]})})};var nb=t(11163),nj=t(61048),nZ=t(6640);function nC(){let n=(0,o.Z)(["\n  border-radius: 4px;\n  border: solid 1px ",";\n  background-color: primary200;\n\n  :hover {\n    background-color: ",";\n  }\n\n  @media (min-width: ",") {\n    min-width: 408px;\n  }\n"]);return nC=function(){return n},n}function nk(){let n=(0,o.Z)(["\n  padding: 16px;\n  font-size: 18px;\n  :hover {\n    cursor: pointer;\n  }\n"]);return nk=function(){return n},n}function nI(){let n=(0,o.Z)(["\n  color: ",";\n  font-size: 1em;\n  font-weight: 500;\n\n  margin: 0 -1em 0 0;\n  padding: 0 1em 0 0;\n  width: calc(100% - 1em);\n  line-height: calc(1em * 1.5);\n  max-height: calc(1em * 1.5 * 2);\n\n  overflow: hidden;\n  position: relative;\n  word-break: break-all;\n\n  :before {\n    content: '...';\n    position: absolute;\n    right: 2px;\n    bottom: 1px;\n  }\n\n  :after {\n    content: '';\n    position: absolute;\n    right: 0;\n    width: 1em;\n    height: 1em;\n    margin-top: calc(1em * 0.2);\n    background-color: ",";\n  }\n\n  ",":hover & {\n    :after {\n      background-color: ",";\n    }\n  }\n"]);return nI=function(){return n},n}function nP(){let n=(0,o.Z)(["\n  margin-top: 8px;\n  opacity: 0.8;\n  color: ",";\n"]);return nP=function(){return n},n}let nS=d.ZP.div.withConfig({componentId:"sc-3566b448-0"})(nC(),D.q4,D.fS,O.Sv),nF=d.ZP.div.withConfig({componentId:"sc-3566b448-1"})(nk()),nA=d.ZP.div.withConfig({componentId:"sc-3566b448-2"})(nI(),D.RP,D.Xt,nS,D.fS),nR=d.ZP.div.withConfig({componentId:"sc-3566b448-3"})(nP(),D.vr),nT=n=>{let{patent:e,distance:t,hasOverlay:i,listIndex:r,isCompareMode:o=!1,setComparePatentId:l}=n,{titles:c}=e,s=(0,nb.useRouter)(),d=()=>{o&&l?l(e.id):s.push("/patent/".concat(e.id))};return(0,a.jsxs)(nS,{children:[(0,a.jsxs)(nF,{onClick:d,children:[(0,a.jsx)(nA,{children:c}),t&&(0,a.jsxs)(nR,{children:["相似度分數\xa0:\xa0",parseFloat(t).toFixed(2),"\xa0(分數越低者越接近)"]})]}),e.imgAlias&&e.imgAlias.length>0&&(i?(0,a.jsx)(nj.Z,{patent:e,listIndex:r}):(0,a.jsx)(nj.l,{children:(0,a.jsx)(nZ.Z,{patent:e})}))]})};var nE=t(42844),nz=t(60974),nL=t(45728),n_=t(47148),nN=t(80366),nM=t(39059),nD=t(89755),nO=t.n(nD),nX=t(2291),nU=t(41664),nY=t.n(nU),nq=t(57634),nH=t(10637);function nB(){let n=(0,o.Z)(["\n  width: 37%;\n  margin-top: -60px;\n  margin-left: 40px;\n  background-color: ",";\n  box-shadow: 0 0 50px 0 rgba(0, 0, 0, 0.1);\n  position: fixed;\n  overflow: hidden;\n  z-index: ",";\n  border-radius: 4px 4px 0 0;\n"]);return nB=function(){return n},n}function nK(){let n=(0,o.Z)(["\n  border-radius: 4px 4px 0 0;\n  background-image: linear-gradient(93deg, ",", ",");\n  color: ",";\n  padding: 8px 16px;\n  display: flex;\n  justify-content: space-between;\n  align-items: center;\n  position: relative;\n  z-index: ",";\n"]);return nK=function(){return n},n}function nV(){let n=(0,o.Z)(["\n  display: flex;\n"]);return nV=function(){return n},n}function nG(){let n=(0,o.Z)(["\n  white-space: nowrap;\n  overflow: hidden;\n  text-overflow: ellipsis;\n  font-weight: 600;\n  margin-right: 16px;\n"]);return nG=function(){return n},n}function nW(){let n=(0,o.Z)(["\n  display: flex;\n  align-items: center;\n  svg {\n    color: ",";\n    margin-left: 16px;\n    :hover {\n      cursor: pointer;\n    }\n  }\n"]);return nW=function(){return n},n}function n$(){let n=(0,o.Z)(["\n  height: calc(100vh - 105px);\n\n  overflow-x: hidden;\n  overflow-y: auto;\n  ::-webkit-scrollbar {\n    width: 8px;\n  }\n  ::-webkit-scrollbar-thumb {\n    border-radius: 20px;\n    box-shadow: inset 0 0 8px 8px #b5e4ec;\n    border: solid 2px transparent;\n  }\n"]);return n$=function(){return n},n}function nJ(){let n=(0,o.Z)(["\n  padding: 16px 32px;\n\n  div {\n    color: ",";\n    font-weight: 600;\n    margin-bottom: 8px;\n  }\n  span {\n    color: ",";\n  }\n"]);return nJ=function(){return n},n}function nQ(){let n=(0,o.Z)(["\n  margin: ",";\n  line-height: 100%;\n  cursor: pointer;\n"]);return nQ=function(){return n},n}let n0=d.ZP.div.withConfig({componentId:"sc-2a0c8d0a-0"})(nB(),D.Xt,nq.H7.resultPreviewPane_Container),n1=d.ZP.div.withConfig({componentId:"sc-2a0c8d0a-1"})(nK(),D.Ub,D.RP,D.Xt,nq.H7.resultPreviewPane_Header),n5=d.ZP.div.withConfig({componentId:"sc-2a0c8d0a-2"})(nV()),n6=d.ZP.div.withConfig({componentId:"sc-2a0c8d0a-3"})(nG()),n2=d.ZP.div.withConfig({componentId:"sc-2a0c8d0a-4"})(nW(),D.Xt),n8=d.ZP.div.withConfig({componentId:"sc-2a0c8d0a-5"})(n$()),n4=d.ZP.div.withConfig({componentId:"sc-2a0c8d0a-6"})(nJ(),D.Ub,D.FT),n3=d.ZP.span.withConfig({componentId:"sc-2a0c8d0a-7"})(nQ(),n=>n.margin),n7=n=>{var e;let{isCompareMode:t,isLoading:i,patentData:r,onPaneClose:o}
1=n,[l,c]=(0,s.useState)(null),[d,u]=(0,s.useState)(0),[p,x]=(0,s.useState)("PatentPreview"),[f,h]=(0,s.useState)(1),g=(0,s.useMemo)(()=>{var n;return null==r?void 0:null===(n=r.imgAlias)||void 0===n?void 0:n.slice(0,nM.IMG_DISPLAY_COUNT).map(n=>"patent/".concat(r.id,"/img/").concat(n))},[null==r?void 0:r.imgAlias,null==r?void 0:r.id]),m=(0,nH.jV)(g),w=g&&m.length===g.length?m:void 0,y=(0,s.useCallback)(()=>{r&&(0,nz.DV)((0,v.ti)({}),r.id).then(n=>{console.log("daa",n),null!==n&&c(n)})},[r]),b=n=>{x(n)};(0,s.useEffect)(()=>{"PatentPreview"===p&&y()},[p,y]),(0,s.useEffect)(()=>{r&&b("PatentPreview")},[r]);let j=(null==r?void 0:r.imgAlias)?r.imgAlias.length-nM.IMG_DISPLAY_COUNT:0,Z=(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)(n0,{children:[(0,a.jsxs)(n1,{children:[(0,a.jsx)(n6,{children:!i&&r&&(null==r?void 0:null===(e=r.titles)||void 0===e?void 0:e.join(" | "))}),(0,a.jsxs)(n2,{children:[r&&(0,a.jsx)(nY(),{href:"/patent/".concat(r.id),passHref:!0,legacyBehavior:!0,children:(0,a.jsx)("a",{target:"_blank",rel:"noopener noreferrer",children:(0,a.jsx)(n3,{margin:"0 10px",children:(0,a.jsx)(nn.CkN,{})})})}),(0,a.jsx)(nn.aHS,{onClick:()=>o()})]})]}),(0,a.jsx)(n8,{children:i?(0,a.jsx)(L.$,{width:"150px",margin:"200px auto"}):(0,a.jsx)(a.Fragment,{children:r?(0,a.jsx)(a.Fragment,{children:(0,a.jsx)(nN.I2,{children:(0,a.jsx)(nX.Z,{patent:r,showFeatureButton:!1,searchText:[],tagColorArray:[],openActionDrawer:()=>null,imageChildren:(0,a.jsxs)(nM.ImageRow,{children:[null==w?void 0:w.map((n,e)=>(0,a.jsxs)(nM.ImageContainer,{onClick:()=>{b("PatentCompareOcrLabel"),u(e)},children:[(0,a.jsx)(nO(),{src:n,alt:"patent image",layout:"fill",unoptimized:!0}),e===nM.IMG_DISPLAY_COUNT-1&&j>0&&(0,a.jsxs)(nM.ImageShade,{children:["+",j]})]},e)),j<0&&Array(-j).fill(0).map((n,e)=>(0,a.jsx)(nM.NoImage,{},e))]})})})}):(0,a.jsxs)(n4,{children:[(0,a.jsx)("div",{children:"請選擇欲瀏覽之專利"}),(0,a.jsx)("span",{children:"點擊左欄專利標題,即可快速檢視您搜尋的專利內容。"})]})})})]})}),C=(null==r?void 0:r.imgAlias)&&(0,a.jsxs)(n0,{children:[(0,a.jsxs)(n1,{children:[(0,a.jsxs)(n5,{children:[(0,a.jsx)(n6,{children:(0,a.jsx)("span",{children:"圖式"})}),(0,a.jsxs)(n2,{children:[(0,a.jsx)(nn.LT3,{size:"16px",onClick:()=>h((0,nL.F)(f,!0))}),(0,a.jsx)(nn.oN5,{size:"16px",onClick:()=>h((0,nL.F)(f,!1))})]})]}),(0,a.jsx)(n2,{children:(0,a.jsx)(nn.aHS,{onClick:()=>b("PatentPreview")})})]}),(0,a.jsx)(n8,{children:(0,a.jsx)(n_.Z,{images:r.imgAlias,imageOnDisplay:d,isOpen:r.imgAlias&&0!==r.imgAlias.length,showThumbnails:!0,data:l,setAddSize:h,addSize:f})})]});return(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)(nN.$V,{show:t,children:["PatentPreview"===p&&Z,"PatentCompareOcrLabel"===p&&C]})})};var n9=t(83461),en=t(53360),ee=t(8807),et=t(94923);function ei(){let n=(0,o.Z)(["\n  margin-bottom: 16px;\n  font-size: 20px;\n  font-weight: 600;\n  color: ",";\n"]);return ei=function(){return n},n}function er(){let n=(0,o.Z)(["\n  margin-bottom: 24px;\n\n  > span {\n    display: block;\n    margin-bottom: 4px;\n  }\n"]);return er=function(){return n},n}function eo(){let n=(0,o.Z)(["\n  display: block;\n\n  input {\n    width: 100%;\n    border-radius: 4px;\n    background-color: ",";\n    color: ",";\n    padding: 5px 12px;\n  }\n"]);return eo=function(){return n},n}function ea(){let n=(0,o.Z)(["\n  color: ",";\n  min-height: 23px;\n  max-height: 45px;\n  overflow-x: hidden;\n  overflow-y: auto;\n  ::-webkit-scrollbar {\n    width: 8px;\n  }\n  ::-webkit-scrollbar-thumb {\n    border-radius: 4px;\n    box-shadow: inset 0 0 8px 8px ",";\n    border: solid 2px transparent;\n  }\n  scrollbar-width: thin;\n"]);return ea=function(){return n},n}function el(){let n=(0,o.Z)(["\n  margin-bottom: 24px;\n  text-align: center;\n  display: flex;\n  gap: 12px;\n  justify-content: center;\n"]);return el=function(){return n},n}function ec(){let n=(0,o.Z)(["\n  margin-bottom: 8px;\n  opacity: 0.8;\n"]);return ec=function(){return n},n}d.ZP.div.withConfig({componentId:"sc-daf78d1b-0"})(ei(),D.Xt);let es=d.ZP.div.withConfig({componentId:"sc-daf78d1b-1"})(er()),ed=(0,d.ZP)(es).attrs(()=>({as:"label"})).withConfig({componentId:"sc-daf78d1b-2"})(eo(),D.Xt,D.R_),eu=d.ZP.div.withConfig({componentId:"sc-daf78d1b-3"})(ea(),D.Ub,(0,D.hp)(.5)),ep=d.ZP.div.withConfig({componentId:"sc-daf78d1b-4"})(el()),ex=d.ZP.div.withConfig({componentId:"sc-daf78d1b-5"})(ec());var ef=t(65496),eh=t(39957),eg=t(91819);let em="svgId",ev="\n  @import url('https://fonts.googleapis.com/css?family=Noto+Sans+SC&amp;display=swap');\n  svg {\n    background-color: ".concat(D.Xt,";\n  }\n  text,\n  tspan {\n    font-family: 'Noto Sans SC', 'Microsoft JhengHei', 'Apple LiGothic Medium';\n    font-size: 15px;\n  }\n"),ew='<defs><style type="text/css">'.concat(ev,"</style></defs>"),ey=n=>{let e="",t=document.getElementById(n);return t&&(e=new XMLSerializer().serializeToString(t).replace(/>/,">"+ew)),e},eb=n=>{let e=ey(em);e.match(/^<svg[^>]+xmlns="http:\/\/www\.w3\.org\/2000\/svg"/)||(e=e.replace(/^<svg/,'<svg xmlns="http://www.w3.org/2000/svg"')),e.match(/^<svg[^>]+"http:\/\/www\.w3\.org\/1999\/xlink"/)||(e=e.replace(/^<svg/,'<svg xmlns:xlink="http://www.w3.org/1999/xlink"')),e='<?xml version="1.0" standalone="no"?>\r\n'+e;let t="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(e);eP(n+".svg",t)},ej=async n=>{await eC(n+".png","image/png")},eZ=async n=>{await eC(n+".jpeg","image/jpeg")},eC=async(n,e)=>{try{let t=await ek(),i=t.toDataURL(e);eP(n,i)}catch(r){console.error("保存為 ".concat(e," 時發生錯誤:"),r)}},ek=async()=>{let n=ey(em),e=document.createElement("canvas"),t=e.getContext("2d");if(t)try{let i=await eh.wh.from(t,n);await i.render(),t.globalCompositeOperation="destination-over",t.fillStyle=D.Xt,t.fillRect(0,0,e.width,e.height)}catch(r){throw console.error("渲染 SVG 時發生錯誤:",r),r}return e},eI=async n=>{try{let e=await ek(),t=e.toDataURL("image/jpeg"),i=new eg.ZP,r=i.internal.pageSize.getWidth(),o=r/e.width*e.height;i.addImage(t,"JPEG",0,0,r,o),i.save(n+".pdf")}catch(a){console.error("保存為 PDF 時發生錯誤:",a)}},eP=(n,e)=>{let t=window.document.createElement("a");t.href=e,t.download=n,document.body.appendChild(t),t.click(),document.body.removeChild(t)},eS={top:50,right:50,bottom:120,left:100}
1,eF=750-eS.left-eS.right,eA=350-eS.top-eS.bottom,eR=n=>{let{fieldName:e,dataset:t}=n,i=(0,s.useRef)(null);return(0,s.useEffect)(()=>{let n=750/t.length*.5,r=nr.tiA().domain(t.map((n,e)=>"".concat(e))).rangeRound([0,750-eS.left-eS.right]),o=nr.BYU().domain([0,nr.Fp7(t,n=>n.count)]).range([350-eS.top-eS.bottom,0]).nice(5),a=nr.LLu(r).tickFormat((n,e)=>nc(t[e].name,5,0)).tickSize(5),l=nr.y4O(o).ticks(5).tickFormat(nr.WUZ(",")).tickSize(-eF),c=nr.Ys(i.current),s=c.append("g").attr("transform","translate("+eS.left+","+(eS.top+eA)+")").style("color",D.R_).call(a);s.selectAll("text").style("text-anchor","end").style("font-size","13px").attr("dx","-1em").attr("transform","rotate(-65)"),s.selectAll("path").remove();let d=c.append("g").attr("transform","translate("+eS.left+","+eS.top+")").style("color",D.R_).call(l);d.selectAll("text").attr("x","-0.8em"),d.selectAll("path").remove(),d.selectAll("line").attr("fill","none").attr("stroke","".concat(D.yf)),c.append("text").attr("transform","translate(375 ,348)").attr("fill","".concat(D.di)).style("text-anchor","middle").text(e),c.append("text").attr("transform","rotate(-90)").attr("y",0).attr("x",-175).attr("dy","1em").attr("fill","".concat(D.di)).style("text-anchor","middle").text("專利數量"),c.selectAll(".rect").data(t).enter().append("path").attr("fill","".concat(D.RP)).attr("d",(e,t)=>{var i,a,l;return i=eS.left+(r("".concat(t))||0)+r.bandwidth()/2-n/2,a=eS.top+o(e.count||0),"M"+(i+4)+","+a+"h"+(n-8)+"a4,4 
10 0 1 4,4v"+((l=eA-o(e.count||0))-8)+"v4h"+-4+"h"+(8-n)+"h"+-4+"v"+-4+"v"+(8-l)+"a4,4 0 0 1 4,"+-4+"z"}),t.length<=15&&c.selectAll(".rect-text").data(t).enter().append("text").attr("fill","".concat(D.RP)).attr("text-anchor","middle").style("font-size","13px").attr("x",(e,t)=>eS.left+(r("".concat(t))||0)+r.bandwidth()/2-n/2).attr("y",n=>eS.top+o(n.count||0)).attr("dx",n/2).attr("dy","-0.6em").text(n=>(0,Q.tV)(n.count))},[e,t]),(0,a.jsx)("svg",{id:em,ref:i,width:750,height:350})};function eT(){let n=(0,o.Z)(["\n  text-align: center;\n  color: ",";\n"]);return eT=function(){return n},n}let eE=d.ZP.div.withConfig({componentId:"sc-ffdab592-0"})(eT(),D.Xt),ez={top:50,right:50,bottom:120,left:100},eL=750-ez.left-ez.right,e_=350-ez.top-ez.bottom,eN=n=>{let{fieldName:e,dataset:t}=n,[i,r]=(0,s.useState)(),o=(0,s.useRef)(null);return(0,s.useEffect)(()=>{let n=nr.tiA().domain(t.map((n,e)=>"".concat(e))).rangeRound([0,750-ez.left-ez.right]),i=nr.BYU().domain([0,nr.Fp7(t,n=>n.count)]).range([350-ez.top-ez.bottom,0]).nice(5),a=nr.LLu(n).tickFormat((n,e)=>nc(t[e].name,5,0)).tickSize(5),l=nr.y4O(i).ticks(5).tickFormat(nr.WUZ(",")).tickSize(-eL),c=nr.jvg().x((e,t)=>(n("".concat(t))||0)+n.bandwidth()/2).y(n=>i(n.count||0)),s=nr.Ys(o.current),d=s.append("g").attr("transform","translate("+ez.left+","+(ez.top+e_)+")").style("color",D.R_).call(a);d.selectAll("text").style("text-anchor","end").style("font-size","13px").attr("dx","-1em").attr("transform","rotate(-65)"),d.selectAll("path").remove();let u=s.append("g").attr("transform","translate("+ez.left+","+ez.top+")").style("color",D.R_).call(l);u.selectAll("text").attr("x","-0.8em"),u.selectAll("path").remove(),u.selectAll("line").attr("fill","none").attr("stroke","".concat(D.yf)),s.append("text").attr("transform","translate(375 ,348)").attr("fill","".concat(D.di)).style("text-anchor","middle").text(e),s.append("text").attr("transform","rotate(-90)").attr("y",0).attr("x",-175).attr("dy","1em").attr("fill","".concat(D.di)).style("text-anchor","middle").text("專利數量"),s.datum(t).append("path").attr("transform","translate("+ez.left+","+ez.top+")").attr("d",c).attr("fill","none").attr("stroke-width","1px").attr("stroke","".concat(D.RP)),s.selectAll("circle").data(t).enter().append("circle").attr("class","circle").attr("fill","".concat(D.RP)).attr("cx",(e,t)=>ez.left+(n("".concat(t))||0)+n.bandwidth()/2).attr("cy",n=>ez.top+i(n.count||0)).attr("r",4).on("mouseover",(n,e)=>{nr.Ys(n.currentTarget).attr("r",5).style("fill","".concat(D.K3))}).on("mousemove",(n,e)=>{}).on("mouseout",n=>{nr.Ys(n.currentTarget).attr("r",4).style("fill","".concat(D.RP)),r(void 0)})},[e,t]),(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("svg",{id:em,ref:o,width:750,height:350}),i&&(0,a.jsx)(nl.Z,{left:i.left,top:i.top,overlay:(0,a.jsxs)(eE,{children:[(0,a.jsx)("div",{children:i.name}),(0,a.jsxs)("div",{children:["專利數量:\xa0",(0,Q.tV)(i.count)]})]})})]})};function eM(){let n=(0,o.Z)(["\n  text-align: center;\n  color: ",";\n"]);return eM=function(){return n},n}let eD=d.ZP.div.withConfig({componentId:"sc-3265ef2b-0"})(eM(),D.Xt),eO=["#ca0b38","#e64f43","#ffc28c","#fbe7b4","#acdfb2","#077790","#7dd3e2","#7e5aad","#5f686c","#7c4141",...nr.Mr0,...nr.xHP,"#4682b4"],eX=n=>{let{fieldName:e,dataset:t}=n,[i,r]=(0,s.useState)(),[o,l]=(0,s.useState)(420),c=(0,s.useRef)(null);return(0,s.useEffect)(()=>{let n=nr.Ys(c.current),e=nr.ve8().value(n=>n.count||0).sort(null),i=nr.Nb1().innerRadius(0).outerRadius(160),o=n.selectAll(".arc").data(e(t)).enter().append("g").attr("class","arc").attr("transform","translate(400,210)"),a=n.selectAll(".arc-line").data(e(t)).enter().append("g").attr("class","arc-line").attr("transform","translate(400,210)"),s=[];o.each((n,e)=>{let t=n.startAngle+(n.endAngle-n.startAngle)/2,r=t<=Math.PI?"start":"end",o="start"===r,a=2.3*i.centroid(n)[0],l=2.3*i.centroid(n)[1];if(e>0){let c=s[e-1],d=r===c.textAnchor,u=0;if(d){let p=l-c.posY;o?p>0&&(u=p):p<0&&(u=-p),u<15&&(o?(l=c.posY+15)>0?a=c.posX+1:176>=Math.sqrt(Math.pow(a,2)+Math.pow(l,2))&&(a=Math.sqrt(36864-Math.pow(l,2))):(l=c.posY-15)<0?a=c.posX-1:176>=Math.sqrt(Math.pow(a,2)+Math.pow(l,2))&&(a=-Math.sqrt(36864-Math.pow(l,2))))}}s.push({textAnchor:r,posX:a,posY:l})});let d=s.map(n=>n.posY),u=nr.Fp7(d),p=nr.VV$(d);if(u&&p){let x=420;u+15>210&&(x+=u+15-210),Math.abs(p)+15>210&&(x+=Math.abs(p)+15-210,o.attr("transform","translate(400,"+(Math.abs(p)+15)+")"),a.attr("transform","translate(400,"+(Math.abs(p)+15)+")")),l(x)}o.append("path").attr("fill",(n,e)=>eO[e].toString()).attr("d",i).on("mouseover",(n,e)=>{nr.Ys(n.currentTarget).style("opacity",.5)}).on("mousemove",(n,e)=>{}).on("mouseout",n=>{nr.Ys(n.currentTarget).style("opacity",1),r(void 0)}
1),a.append("polyline").attr("fill","none").attr("stroke",(n,e)=>eO[e].toString()).attr("points",(n,e)=>{let t=n.startAngle+(n.endAngle-n.startAngle)/2,r=s[e].posX+(t<=Math.PI?-5:5),o=s[e].posY-5,a=2.1*i.centroid(n)[0];return Math.abs(r)<Math.abs(a)&&(r=a),[[2*i.centroid(n)[0],2*i.centroid(n)[1]],[a,2.1*i.centroid(n)[1]],[r,o]]}),o.append("text").attr("transform",(n,e)=>"translate("+s[e].posX+","+s[e].posY+")").style("font-size","13px").style("text-anchor",(n,e)=>s[e].textAnchor).text(n=>{let e=Number(n.value)/nr.Smz(t,n=>n.count)*100;return nc(n.data.name,10,0)+" : "+e.toFixed(1)+"%"})},[e,t]),(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("svg",{id:em,ref:c,width:800,height:o}),i&&(0,a.jsx)(nl.Z,{left:i.left,top:i.top,overlay:(0,a.jsxs)(eD,{children:[(0,a.jsx)("div",{children:i.name}),(0,a.jsxs)("div",{children:["專利數量:\xa0",(0,Q.tV)(i.count)]})]})})]})};function eU(){let n=(0,o.Z)(["\n  padding: 0 24px;\n  max-width: 960px;\n  margin: 0 auto;\n\n  @media print {\n    padding: 0;\n    margin: 0;\n  }\n"]);return eU=function(){return n},n}function eY(){let n=(0,o.Z)(["\n  display: flex;\n  align-items: center;\n  justify-content: center;\n  \n  @media print {\n    display: block;\n  }\n"]);return eY=function(){return n},n}function eq(){let n=(0,o.Z)(["\n  display: table;\n  border-collapse: collapse;\n  border-radius: 4px;\n  overflow: hidden;\n  margin: 32px auto;\n  @media print {\n    display: none;\n  }\n"]);return eq=function(){return n},n}function eH(){let n=(0,o.Z)(["\n  display: table-row;\n"]);return eH=function(){return n},n}function eB(){let n=(0,o.Z)(["\n  display: table-cell;\n  width: 132.5px;\n  min-width: 88px;\n  vertical-align: middle;\n  text-align: center;\n  padding: 10px;\n  border: 1px solid ",";\n\n  /* 首欄為標題不換行。 */\n  :nth-child(1) {\n    white-space: nowrap;\n  }\n"]);return eB=function(){return n},n}function eK(){let n=(0,o.Z)(["\n  background-color: ",";\n  color: ",";\n"]);return eK=function(){return n},n}function eV(){let n=(0,o.Z)(["\n  background-color: ",";\n  color: ",";\n"]);return eV=function(){return n},n}function eG(){let n=(0,o.Z)(["\n  text-align: center;\n  color: ",";\n  @media print {\n    display: none;\n  }\n"]);return eG=function(){return n},n}let eW=d.ZP.div.withConfig({componentId:"sc-7e111cdf-0"})(eU()),e$=d.ZP.div.withConfig({componentId:"sc-7e111cdf-1"})(eY()),eJ=d.ZP.div.withConfig({componentId:"sc-7e111cdf-2"})(eq()),eQ=d.ZP.div.withConfig({componentId:"sc-7e111cdf-3"})(eH()),e0=d.ZP.div.withConfig({componentId:"sc-7e111cdf-4"})(eB(),D.yf),e1=(0,d.ZP)(e0).withConfig({componentId:"sc-7e111cdf-5"})(eK(),D.vr,D.Xt),e5=(0,d.ZP)(e0).withConfig({componentId:"sc-7e111cdf-6"})(eV(),D.yf,D.R_),e6=d.ZP.div.withConfig({componentId:"sc-7e111cdf-7"})(eG(),D.di);(i=r||(r={})).COLUMN="長條圖",i.LINE="折線圖",i.PIE="圓餅圖",i.PIE_MERGE_OTHERS="圓餅圖 - 超出項目計入其他";let e2=n=>{let{type:e,fieldName:t,dataset:i}=n;return(0,a.jsxs)(eW,{children:[(0,a.jsx)(e$,{children:(()=>{switch(e){case r.COLUMN:return(0,a.jsx)(eR,{fieldName:t,dataset:i});case r.LINE:return(0,a.jsx)(eN,{fieldName:t,dataset:i});case r.PIE:case r.PIE_MERGE_OTHERS:return(0,a.jsx)(eX,{fieldName:t,dataset:i});default:return null}})()}),(0,a.jsxs)(eJ,{children:[(0,a.jsxs)(eQ,{children:[(0,a.jsx)(e1,{children:t}),i.map((n,e)=>(0,a.jsx)(e1,{children:nc(n.name,10,0)},e))]}),(0,a.jsxs)(eQ,{children:[(0,a.jsx)(e5,{children:"專利數量"}),i.map((n,e)=>(0,a.jsx)(e5,{children:(0,Q.tV)(n.count)},e))]})]}),(0,a.jsx)(e6,{children:"專利圖表分析之統計資料 係以當時資料庫資料量分析"})]})};var e8=t(88934),e4=t(8922),e3=t(31470);function e7(){let n=(0,o.Z)(["\n  @media print {\n    * {\n      overflow: hidden !important;\n      visibility: hidden !important;\n    }\n\n    #printable-area, #printable-area * {\n      visibility: visible !important;\n    }\n\n    #printable-area {\n      position: fixed;\n      top: 0;\n      left: 0;\n      width: 100vw;\n      height: 100vh;\n      background: white;\n      padding: 32px;\n      box-sizing: border-box;\n      page-break-inside: avoid;\n    }\n\n    @page { \n    }\n\n    html, body {\n      margin: 0 !important;\n      padding: 0 !important;\n      overflow: hidden !important;\n      height: 0 !important;\n    }\n  \n  }\n"]);return e7=function(){return n},n}function e9(){let n=(0,o.Z)(["\n  & .MuiDialog-paper {\n    overflow: hidden;\n    border-radius: 12px;\n  }\n  @media print {\n    display: block !important;\n  }\n"]);return e9=function(){return n},n}function tn(){let n=(0,o.Z)(["\n  padding: 32px;\n  border-radius: 4px;\n  box-shadow: 0 0 50px 0 ",";\n  background-color: ",";\n  color: ",";\n  min-width: 914px;\n\n  @media print {\n    padding: 0px;\n    box-shadow: none;\n  }\n"]);return tn=function(){return n},n}function te(){let n=(0,o.Z)(["\n  padding-left: 24px;\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n\n  @media print {\n    padding: 0;\n  }\n"]);return te=function(){return n},n}function tt(){let n=(0,o.Z)(["\n  font-size: 20px;\n  font-weight: 600;\n  margin-bottom: 4px;\n  max-width: 80%;\n  word-break: break-all;\n"]);return tt=function(){return n},n}function ti(){let n=(0,o.Z)(["\n  @media print {\n    display: none;\n  }\n"]);return ti=function(){return n},n}function tr(){let n=(0,o.Z)(["\n  display: inline-flex;\n  align-items: center;\n  padding: 12px;\n  :hover {\n    cursor: pointer;\n  }\n  svg {\n    font-size: 20px;\n  }\n"]);return tr=function(){return n},n}function to(){let n=(0,o.Z)(["\n      border-radius: 50%;\n      background-color: ",";\n    "]);return to=function(){return n},n}function ta(){let n=(0,o.Z)(["\n  ","\n"]);return ta=function(){return n},n}function tl(){let n=(0,o.Z)(["\n  display: inline-block;\n  position: relative;\n"]);return tl=function(){return n},n}function tc(){let n=(0,o.Z)(["\n  position: absolute;\n  top: 52px;\n  right: 0;\n  padding: 4px 0;\n  background-color: ",";\n  box-shadow: 0 5px 20px 0 ",";\n  border-radius: 4px;\n\n  div {\n    white-space: nowrap;\n    padding: 4px 16px;\n    :hover {\n      cursor: pointer;\n      background-color: ",";\n    }\n  }\n\n  > a {\n    color: inherit;\n  }\n"]);return tc=function(){return n},n}function ts(){let n=(0,o.Z)(["\n  padding-left: 24px;\n  span {\n    margin-right: 4px;\n  }\n  margin-bottom: 8px;\n\n  @media print {\n    padding: 0;\n  }\n"]);return ts=function(){return n},n}function td(){let n=(0,o.Z)(["\n  ::-webkit-scrollbar {\n    height: 8px; /* height of horizontal scrollbar */\n    width: 8px;\n  }\n  ::-webkit-scrollbar-thumb {\n    border-radius: 20px;\n    box-shadow: inset 0 0 8px 8px ",";\n    border: solid 2px transparent;\n  }\n"]);return td=function(){return n},n}function tu(){let n=(0,o.Z)(["\n  max-height: 72.5vh;\n  overflow: auto;\n  ","\n  @media print {\n    max-height: none;\n  }\n"]);return tu=function(){return n},n}function tp(){let n=(0,o.Z)(["\n  margin: 16px 32px;\n  padding: 16px 32px;\n  background-color: ",";\n  border-radius: 4px;\n\n  div {\n    color: ",";\n    font-weight: 600;\n    margin-bottom: 8px;\n  }\n  span {\n    color: ",";\n  }\n"]);return tp=function(){return n},n}let tx=(0,d.vJ)(e7()),tf=(0,e4.ZP)(e3.Z)(e9()),th=d.ZP.div.withConfig({componentId:"sc-ba637652-0"})(tn(),(0,D.GV)(.1),D.Xt,D.R_),tg=d.ZP.div.withConfig({componentId:"sc-ba637652-1"})(te()),tm=d.ZP.div.withConfig({componentId:"sc-ba637652-2"})(tt()),tv=d.ZP.div.withConfig({componentId:"sc-ba637652-3"})(ti()),tw=d.ZP.i.withConfig({componentId:"sc-ba637652-4"})(tr()),ty=(0,d.ZP)(tw).withConfig({componentId:"sc-ba637652-5"})(ta(),n=>n.isPopup&&(0,d.iv)(to(),D.m9)),tb=d.ZP.div.withConfig({componentId:"sc-ba637652-6"})(tl()),tj=d.ZP.div.withConfig({componentId:"sc-ba637652-7"})(tc(),D.Xt,(0,D.GV)(.1),D.m9),tZ=d.ZP.div.withConfig({componentId:"sc-ba637652-8"})(ts()),tC=(0,d.iv)(td(),(0,D.hp)(.8)),tk=d.ZP.div.withConfig({componentId:"sc-ba637652-9"})(tu(),tC),tI=d.ZP.div.withConfig({componentId:"sc-ba637652-10"})(tp(),D.fS,D.Ub,D.FT),tP=n=>
1{let[e,t]=(0,s.useState)((0,Q.o0)(new Date,!0,!0)),[i,r]=(0,s.useState)(!1);(0,s.useEffect)(()=>{n.isDataLoading||t((0,Q.o0)(new Date,!0,!0))},[n.isDataLoading]);let o=e=>(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)(tg,{children:[(0,a.jsx)(tm,{children:n.title}),(0,a.jsx)(tv,{children:(0,a.jsx)(tw,{onClick:()=>n.setClose,children:(0,a.jsx)(nn.aHS,{color:D.di})})})]}),(0,a.jsx)(tk,{children:e})]});return(0,a.jsxs)(a.Fragment,{children:[n.open&&(0,a.jsx)(tx,{}),(0,a.jsx)(tf,{open:n.open,maxWidth:"lg",fullWidth:!0,sx:{display:{mobile:"none",tablet:"block"}},children:(0,a.jsx)(th,{id:"printable-area",children:n.isError?o((0,a.jsxs)(tI,{children:[(0,a.jsx)("div",{children:"很抱歉,目前服務發生異常。"}),(0,a.jsx)("span",{children:"請確認您的設備連線或嘗試變更檢索內容或稍後再試,謝謝。"})]})):n.isDataLoading?o((0,a.jsx)(L.$,{width:"200px",margin:"120px auto"})):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)(tg,{children:[(0,a.jsx)(tm,{children:n.title}),(0,a.jsxs)(tv,{children:[(0,a.jsx)(tw,{onClick:()=>window.print(),children:(0,a.jsx)(nn.rcQ,{color:D.K3})}),(0,a.jsxs)(tb,{children:[(0,a.jsx)(ty,{isPopup:i,onClick:()=>r(n=>!n),children:(0,a.jsx)(nn.aBF,{color:D.K3})}),i&&(0,a.jsxs)(tj,{children:[(0,a.jsx)("div",{onClick:()=>ej(n.title),children:"PNG 格式"}),(0,a.jsx)("div",{onClick:()=>eZ(n.title),children:"JPG 格式"}),(0,a.jsx)("div",{onClick:()=>eb(n.title),children:"SVG 格式"}),n.extraDownloadItem]})]}),(0,a.jsx)(tw,{onClick:n.setClose,children:(0,a.jsx)(nn.aHS,{color:D.di})})]})]}),(0,a.jsxs)(tZ,{children:[(0,a.jsx)("span",{children:"表格產生時間:"}),(0,a.jsx)("span",{children:e})]}),(0,a.jsx)(tk,{children:n.children})]})})})]})};var tS=t(15775),tF=t(49186),tA=t(20931);function tR(){let n=(0,o.Z)(["\n  border-radius: 4px;\n  font-size: 15px;\n  border: 1px solid ",";\n  min-width: 0;\n  ::placeholder {\n    color: ",";\n  }\n\n  :focus {\n    outline: none;\n    border: 1px solid ",";\n  }\n"]);return tR=function(){return n},n}function tT(){let n=(0,o.Z)(["\n  ",";\n  flex: 4;\n  position: relative;\n"]);return tT=function(){return n},n}function tE(){let n=(0,o.Z)(["\n  span {\n    margin-right: 10px;\n  }\n  label {\n    width: 100%;\n  }\n"]);return tE=function(){return n},n}function tz(){let n=(0,o.Z)(["\n  padding: 24px;\n  width: 304px;\n  border-radius: 4px;\n  background-color: ",";\n  color: black;\n  position: absolute;\n  top: -100px;\n  right: 130px;\n  display: flex;\n  flex-direction: column;\n  justify-content: space-between;\n  cursor: default;\n  box-shadow: 0px 16px 52px -4px #1212121f;\n  z-index: ",";\n  max-height: calc(100vh - 70px);\n  overflow: auto;\n  ","\n"]);return tz=function(){return n},n}function tL(){let n=(0,o.Z)(["\n  display: flex;\n  align-items: center;\n  margin: 8px 0;\n  justify-content: space-between;\n"]);return tL=function(){return n},n}function t_(){let n=(0,o.Z)(["\n  padding: 2px 0;\n  margin-right: 8px;\n  font-size: 20px;\n  font-weight: 600;\n  color: ",";\n"]);return t_=function(){return n},n}function tN(){let n=(0,o.Z)(["\n  display: flex;\n  align-items: center;\n  > span,\n  > div {\n    margin: 0 8px 0 0;\n  }\n"]);return tN=function(){return n},n}function tM(){let n=(0,o.Z)(["\n  display: flex;\n  align-items: flex-start;\n  justify-content: space-between;\n  margin-bottom: 8px;\n\n  > span {\n    margin-right: 24px;\n  }\n\n  > div {\n    flex: 1;\n    /* 覆寫 CheckBox 的 style */\n    > div {\n      margin: 0 0 8px 0;\n    }\n  }\n"]);return tM=function(){return n},n}let tD=(0,d.iv)(tR(),D.q4,D.w5,D.K3),tO=(0,d.iv)(tT(),tD),tX=(0,d.iv)(tE()),tU=d.ZP.div.withConfig({componentId:"sc-e16f7234-0"})(tz(),D.Xt,nq.H7.subscriptionPane_Container,tA.T),tY=d.ZP.div.withConfig({componentId:"sc-e16f7234-1"})(tL()),tq=d.ZP.div.withConfig({componentId:"sc-e16f7234-2"})(t_(),D.R_),tH=(0,d.ZP)(es).withConfig({componentId:"sc-e16f7234-3"})(tN()),tB=d.ZP.div.withConfig({componentId:"sc-e16f7234-4"})(tM()),tK=n=>{let{searchRequest:e}=n,[t,i]=(0,s.useState)(""),[o,l]=(0,s.useState)(""),[c,d]=(0,s.useState)({facetField:{name:"請選擇",value:""},analysisNum:{name:"5",value:"5"}}),u=(0,x.I)(n=>n.facets),p=()=>{i(""),l(""),d({facetField:{name:"請選擇",value:""},analysisNum:{name:"5",value:"5"}}),console.log("表單已清除")},f=Array.from(Array(6),(n,e)=>{let t=((e+1)*5).toString();return{text:t,value:t}}),h=null==u?void 0:u.map((n,e)=>({text:ef.db.get(n.keyCode)||"",value:e.toString()}
1)),[g,m]=(0,s.useState)({text:"請選擇",value:""}),[v,w]=(0,s.useState)({text:"5",value:"5"}),[y,b]=(0,s.useState)(!1),j=null==u?void 0:u[parseInt(c.facetField.value)||0],Z=()=>{""===c.facetField.value?(0,en.xh)(ee.j.STATISTICS_ANALYSIS_ITEM_UNSELECTED):""===o?(0,en.xh)(ee.j.STATISTICS_CHART_TYPE_UNSELECTED):b(!0)},C=()=>{let n=parseInt(c.analysisNum.value),e=null==j?void 0:j.facetFieldCounts.slice(0,n);if(o!==r.PIE_MERGE_OTHERS)return e;{let t=null==j?void 0:j.facetFieldCounts.slice(n),i=null==t?void 0:t.reduce((n,e)=>n+(e.count?e.count:0),0);return i&&i>0?null==e?void 0:e.concat({name:"其他",count:i,identity:""}):e}},k=()=>""!==c.facetField.value||((0,en.xh)(ee.j.STATISTICS_ANALYSIS_ITEM_UNSELECTED),!1),I=c.facetField.name+".csv",P=[{label:c.facetField.value,key:"name"},{label:"專利數量",key:"count"}],S=n=>{m(n),d({facetField:{name:n.text,value:n.value},analysisNum:{name:"5",value:"5"}})},F=n=>{w(n),d(e=>({...e,analysisNum:{name:n.text,value:n.value}}))};return(0,a.jsxs)(tU,{children:[(0,a.jsxs)(tY,{children:[(0,a.jsx)(tq,{children:"統計分析"}),(""!==t||""!==c.facetField.value||""!==o)&&(0,a.jsx)(et.zx,{type:"button",template:et.YS.PRIMARY,onClick:p,children:"清除"})]}),(0,a.jsxs)(es,{children:[(0,a.jsx)("span",{children:"分析數據母體"}),(0,a.jsx)(eu,{children:e.queryString})]}),(0,a.jsxs)(ed,{children:[(0,a.jsx)("span",{children:"圖表標題"}),(0,a.jsx)(tS.Z,{type:"text",name:"chartTitle",maxLength:32,value:t,onChange:n=>i(n.target.value)})]}),(0,a.jsxs)(es,{children:[(0,a.jsx)("span",{children:"分析項目"}),(0,a.jsx)(tF.Z,{selected:g,options:h,customStyle:tO,menuHeight:"200px",onChange:S})]}),""!==c.facetField.value&&(0,a.jsxs)(tH,{children:[(0,a.jsx)("span",{children:"項目數量前"}),(0,a.jsx)(tF.Z,{selected:v,options:f,customStyle:tO,menuHeight:"200px",onChange:F}),(0,a.jsx)("span",{children:"項"})]}),(0,a.jsxs)(tB,{children:[(0,a.jsx)("span",{children:"圖表類型"}),(0,a.jsx)("div",{children:Object.values(r).map(n=>{let e=o===n;return(0,a.jsx)(e8.Z,{name:n,checked:e,color:D.Xt,themeReverse:!0,customStyle:tX,children:(0,a.jsx)("input",{type:"checkbox",checked:e,onChange:()=>l(n)})},n)})})]}),(0,a.jsxs)(ep,{children:[(0,a.jsx)(et.zx,{template:et.YS.PRIMARY,onClick:Z,children:"圖表分析"}),(0,a.jsx)(n9.CSVLink,{filename:I,headers:P,data:j.facetFieldCounts,onClick:k,children:(0,a.jsx)(et.zx,{template:et.YS.PRIMARY_LIGHT,children:"下載全部資料"})})]}),(0,a.jsx)(ex,{children:"數據可視化工具是種統計方式,可協助研究者更了解專利數據分布狀態。"}),y&&(0,a.jsx)(tP,{open:y,title:""!==t?t:o,setClose:()=>b(!1),extraDownloadItem:(0,a.jsx)(n9.CSVLink,{filename:I,headers:P,data:C(),children:(0,a.jsx)("div",{children:"CSV 資料表"})}),children:(0,a.jsx)(e2,{type:o,fieldName:c.facetField.name,dataset:C()})})]})};var tV=t(57460),tG=t.n(tV),tW=t(32512);let t$=(n,e)=>(0,nr.LLu)(n).tickSize(e).tickFormat(""),tJ=(n,e)=>(0,nr.y4O)(n).tickSize(e).tickFormat("");function tQ(){let n=(0,o.Z)(["\n  color: ",";\n"]);return tQ=function(){return n},n}let t0=d.ZP.div.withConfig({componentId:"sc-9cadfd41-0"})(tQ(),D.Xt),t1={top:8,right:8,bottom:108,left:88},t5=n=>{let{xAxisLabels:e,yAxisLabels:t,dataset:i}=n;i.reverse(),t.reverse();
1let[r,o]=(0,s.useState)(),l=(0,s.useRef)(null);return(0,s.useEffect)(()=>{let n=nr.Ys(l.current);n.selectAll("*").remove(),n.style("background-color",D.Xt);let r=[].concat(...i),a=n.selectAll("circle").data(r),c=i.length,s=i[0].length,d=820-(t1.left+t1.right),u=d/s,p=600-(t1.top+t1.bottom),x=p/c,f=(n,i)=>{let r=n.currentTarget,o=A.nodes().indexOf(r),a={x:o%s,y:Math.floor(o/s)};return{left:n.pageX-window.scrollX,top:n.pageY-window.scrollY-16,technology:e[a.x],function:t[a.y],count:i}};n.append("rect").attr("x",t1.left).attr("y",t1.top).attr("width",d).attr("height",p).attr("fill","#f9f9f9");let h=n.append("g").attr("transform","translate(".concat(t1.left,", ").concat(t1.top,")")),g=h.append("g").attr("transform","translate(0, ".concat(p,")")).style("color",D.R_),m=h.append("g").style("color",D.R_),v=h.append("g").attr("transform","translate(0, ".concat(p,")")).style("color",D.yf),w=h.append("g").style("color",D.yf),y=nr.BYU().domain([0,nr.Fp7(r)]).range([0,.8*(Math.min(u,x)/2)]),b=nr.tiA().domain(i[0].map((n,e)=>"x".concat(e+1))).range([0,d]),j=nr.tiA().domain(i.map((n,e)=>"y".concat(e+1))).range([p,0]),Z=n=>t1.left+u*(n%s+.5),C=n=>p+t1.top-x*(Math.floor(n/s)+.5),k=nr.LLu(b).tickFormat((n,t)=>nc(e[t],8,0)).tickSize(0).tickPadding(16),I=nr.y4O(j).tickFormat((n,e)=>nc(t[e],8,0)).tickSize(0).tickPadding(16),P=t$(b,-p).tickSizeOuter(0),S=tJ(j,-d).tickSizeOuter(0),F=nr.aE8().domain([0,p]).range(["#7DD3E2","#95B4C9","#AC95AF","#C47796","#DB587C","#F33963"]);a.exit().remove();let A=a.enter().append("circle").merge(a);A.attr("cx",(n,e)=>Z(e)).attr("cy",(n,e)=>C(e)).style("opacity","0.6").transition().duration(2e3).ease(nr.mfJ).attr("r",n=>y(n)).attr("fill",(n,e)=>F(C(e))),A.style("cursor","pointer").on("mouseover",(n,e)=>{nr.Ys(n.currentTarget).style("opacity",.8),o(f(n,e))}).on("mousemove",(n,e)=>{o(f(n,e))}).on("mouseout",n=>{nr.Ys(n.currentTarget).style("opacity",.6),o(void 0)}),g.call(k),m.call(I),v.call(n=>P(n)),w.call(n=>S(n)),g.selectAll("text").style("font-size","13px").style("text-anchor","end").attr("transform","rotate(-55)").attr("dx","-0.5em").attr("dy","-0.5em"),m.selectAll("text").style("font-size","13px").attr("transform","rotate(-55)").attr("dx","0.6em").attr("dy","-0.6em"),g.select(".domain").remove(),m.select(".domain").remove(),v.select(".domain").remove(),w.select(".domain").remove()},[e,t,i]),(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("svg",{id:em,ref:l,width:820,height:600}),r&&(0,a.jsx)(nl.Z,{left:r.left,top:r.top,overlay:(0,a.jsxs)(t0,{children:[(0,a.jsxs)("div",{children:["技術:\xa0",r.technology]}),(0,a.jsxs)("div",{children:["功效:\xa0",r.function]}),(0,a.jsxs)("div",{children:["專利數量:\xa0",(0,Q.tV)(r.count)]})]})})]})};function t6(){let n=(0,o.Z)(["\n  ::-webkit-scrollbar {\n    width: 8px;\n  }\n  ::-webkit-scrollbar-thumb {\n    border-radius: 20px;\n    box-shadow: inset 0 0 8px 8px ",";\n    border: solid 2px transparent;\n  }\n"]);return t6=function(){return n},n}function t2(){let n=(0,o.Z)(["\n  padding: 24px;\n  width: 504px;\n  border-radius: 4px;\n  background-color: ",";\n  color: black;\n  position: absolute;\n  top: -60px;\n  right: 130px;\n  display: flex;\n  flex-direction: column;\n  justify-content: space-between;\n  cursor: default;\n  box-shadow: 0px 16px 52px -4px #1212121f;\n  z-index: ",";\n  max-height: calc(100vh - 80px);\n  overflow: auto;\n  ","\n"]);return t2=function(){return n},n}function t8(){let n=(0,o.Z)(["\n  display: flex;\n  align-items: center;\n  margin: 8px 0;\n  justify-content: space-between;\n"]);return t8=function(){return n},n}function t4(){let n=(0,o.Z)(["\n  display: flex;\n"]);return t4=function(){return n},n}function t3(){let n=(0,o.Z)(["\n  padding: 2px 0;\n  margin-right: 8px;\n  font-size: 20px;\n  font-weight: 600;\n  color: ",";\n"]);return t3=function(){return n},n}function t7(){let n=(0,o.Z)(["\n  max-height: 50vh;\n  overflow: auto;\n  ","\n  margin-bottom: 24px;\n"]);return t7=function(){return n},n}function t9(){let n=(0,o.Z)(["\n  color: ",";\n  background-color: ",";\n\n  :hover {\n    background-color: ",";\n  }\n"]);return t9=function(){return n},n}function ie(){let n=(0,o.Z)(["\n  color: ",";\n  background-color: ",";\n\n  :hover {\n    background-color: ",";\n  }\n"]);return ie=function(){return n},n}function it(){let n=(0,o.Z)(["\n  user-select: none;\n  position: relative;\n  display: flex;\n  align-items: center;\n  width: 100%;\n  padding: 16px;\n  border-radius: 4px;\n  margin-bottom: 8px;
1\n\n  svg:nth-child(1) {\n    color: ",";\n    margin-right: 16px;\n  }\n\n  span {\n    font-weight: 600;\n    margin-right: 16px;\n  }\n\n  ","\n"]);return it=function(){return n},n}function ii(){let n=(0,o.Z)(["\n  position: relative;\n  width: 20%;\n  margin-right: 8px;\n\n  input {\n    width: 100%;\n    padding: 8px;\n    border: 1px solid ",";\n    border-radius: 4px;\n\n    ::placeholder {\n      color: ",";\n    }\n  }\n"]);return ii=function(){return n},n}function ir(){let n=(0,o.Z)(["\n  flex: 1;\n  position: relative;\n  display: flex;\n  align-items: center;\n\n  textarea {\n    width: 100%;\n    height: 33px;\n    resize: vertical;\n    padding: 6px 8px;\n    border: 1px solid ",";\n    border-radius: 4px;\n\n    ::placeholder {\n      color: ",";\n    }\n  }\n"]);return ir=function(){return n},n}function io(){let n=(0,o.Z)(["\n  position: absolute;\n  bottom: -16px;\n  left: 0;\n  color: ",";\n  font-size: 12px;\n  min-width: 200px;\n"]);return io=function(){return n},n}function ia(){let n=(0,o.Z)(["\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n  padding: 8px 0;\n"]);return ia=function(){return n},n}function il(){let n=(0,o.Z)(["\n  width: calc((100% - 12px) / 2);\n  padding: 8px;\n  border-radius: 4px;\n\n  display: flex;\n  align-items: center;\n  justify-content: center;\n\n  svg {\n    margin-right: 8px;\n  }\n\n  :hover {\n    cursor: pointer;\n  }\n\n  ","\n"]);return il=function(){return n},n}function ic(){let n=(0,o.Z)(["\n  position: absolute;\n  top: 4px;\n  right: 4px;\n  color: ",";\n  font-size: 12px;\n\n  :hover {\n    cursor: pointer;\n  }\n"]);return ic=function(){return n},n}function is(){let n=(0,o.Z)(["\n  display: flex;\n  align-items: center;\n  justify-content: center;\n  @media print {\n    justify-content: flex-start;\n  }\n"]);return is=function(){return n},n}function id(){let n=(0,o.Z)(["\n  @media print {\n    display: none;\n  }\n"]);return id=function(){return n},n}function iu(){let n=(0,o.Z)(["\n  display: table;\n  border-collapse: collapse;\n  border-radius: 4px;\n  overflow: hidden;\n  margin: 32px auto;\n\n  background-color: ",";\n  color: ",";\n"]);return iu=function(){return n},n}function ip(){let n=(0,o.Z)(["\n  display: table-row;\n\n  &:nth-child(2) {\n    background-color: ",";\n  }\n"]);return ip=function(){return n},n}function ix(){let n=(0,o.Z)(["\n  display: table-cell;\n  width: 132.5px;\n  word-break: break-all;\n  vertical-align: middle;\n  text-align: center;\n  padding: 10px;\n  border: 1px solid ",";\n"]);return ix=function(){return n},n}function ih(){let n=(0,o.Z)(["\n  background-color: ",";\n  color: ",";\n\n  &:nth-child(1) {\n    background-color: ",";\n    border: none;\n  }\n\n  &:nth-child(2) {\n    border-top-left-radius: 8px;\n    border-top: 1px solid ",";\n    border-left: 1px solid ",";\n  }\n"]);return ih=function(){return n},n}function ig(){let n=(0,o.Z)(["\n  &:nth-child(1) {\n    background-color: ",";\n    color: ",";\n  }\n\n  &:nth-child(2) {\n    background-color: ",";\n  }\n\n  ",":nth-child(2) > &:nth-child(1) {\n    border-top-left-radius: 8px;\n    border-top: 1px solid ",";\n    border-left: 1px solid ",";\n  }\n\n  ",":nth-child(2) > &:nth-child(2) {\n    background-color: ",";\n    color: ",";\n  }\n"]);return ig=function(){return n},n}function im(){let n=(0,o.Z)(["\n  color: ",";\n  @media print {\n    display: none;\n  }\n"]);return im=function(){return n},n}function iv(){let n=(0,o.Z)(["\n  font-size: 20px;\n  font-weight: 600;\n  margin-bottom: 4px;\n"]);return iv=function(){return n},n}function iw(){let n=(0,o.Z)(["\n  color: ",";\n  margin-bottom: 8px;\n  span {\n    margin-right: 4px;\n  }\n"]);return iw=function(){return n},n}function iy(){let n=(0,o.Z)(["\n  color: ",";\n  text-decoration: underline;\n  :hover {\n    cursor: pointer;\n  }\n"]);return iy=function(){return n},n}let ib=(0,d.iv)(t6(),(0,D.hp)(.5)),ij=d.ZP.div.withConfig({componentId:"sc-9eb0a930-0"})(t2(),D.Xt,nq.H7.matrixPane_Container,ib),iZ=d.ZP.div.withConfig({componentId:"sc-9eb0a930-1"})(t8()),iC=d.ZP.div.withConfig({componentId:"sc-9eb0a930-2"})(t4()),ik=d.ZP.div.withConfig({componentId:"sc-9eb0a930-3"})(t3(),D.R_),iI=d.ZP.div.withConfig({componentId:"sc-9eb0a930-4"})(t7(),ib),iP=n=>(0,d.iv)(t9(),D.RP,D.m9,n&&D.Om),iS=n=>
1(0,d.iv)(ie(),D.LW,D.ZJ,n&&D.zi),iF=d.ZP.div.withConfig({componentId:"sc-9eb0a930-5"})(it(),D.di,n=>"technology"===n.type&&iP()||"function"===n.type&&iS()),iA=d.ZP.div.withConfig({componentId:"sc-9eb0a930-6"})(ii(),n=>n.hasError?D.az:D.w5,D.di),iR=d.ZP.div.withConfig({componentId:"sc-9eb0a930-7"})(ir(),n=>n.hasError?D.az:D.w5,D.di),iT=d.ZP.div.withConfig({componentId:"sc-9eb0a930-8"})(io(),D.si),iE=d.ZP.div.withConfig({componentId:"sc-9eb0a930-9"})(ia()),iz=d.ZP.div.withConfig({componentId:"sc-9eb0a930-10"})(il(),n=>"technology"===n.type&&iP(!0)||"function"===n.type&&iS(!0)),iL=(0,d.ZP)(nn.aHS).withConfig({componentId:"sc-9eb0a930-11"})(ic(),D.RP),i_=d.ZP.div.withConfig({componentId:"sc-9eb0a930-12"})(is()),iN=d.ZP.div.withConfig({componentId:"sc-9eb0a930-13"})(id()),iM=d.ZP.div.withConfig({componentId:"sc-9eb0a930-14"})(iu(),D.yf,D.R_),iD=d.ZP.div.withConfig({componentId:"sc-9eb0a930-15"})(ip(),D.w5),iO=d.ZP.div.withConfig({componentId:"sc-9eb0a930-16"})(ix(),D.yf),iX=(0,d.ZP)(iO).withConfig({componentId:"sc-9eb0a930-17"})(ih(),D.vr,D.Xt,D.Xt,D.Xt,D.Xt),iU=(0,d.ZP)(iO).withConfig({componentId:"sc-9eb0a930-18"})(ig(),D.vr,D.Xt,D.w5,iD,D.Xt,D.Xt,iD,D.SL,D.Xt),iY=d.ZP.div.withConfig({componentId:"sc-9eb0a930-19"})(im(),D.di),iq=d.ZP.div.withConfig({componentId:"sc-9eb0a930-20"})(iv()),iH=d.ZP.div.withConfig({componentId:"sc-9eb0a930-21"})(iw(),D.RP),iB=d.ZP.div.withConfig({componentId:"sc-9eb0a930-22"})(iy(),D.Ub),iK=n=>{let{searchRequest:e,setClose:t}
1=n,[i,r]=(0,s.useState)([{name:"",keyword:""}]),[o,l]=(0,s.useState)([{name:"",keyword:""}]),[c,d]=(0,s.useState)({}),[u,p]=(0,s.useState)([]),[x,f]=(0,s.useState)(!1),h="技術功效矩陣繪圖",g=(0,s.useRef)(null),m=()=>{g.current.link.click()},w=()=>{let n={};return i.forEach((e,t)=>{e.name.trim()||(n["technologyList[".concat(t,"].name")]="請輸入技術名稱"),e.keyword.trim()||(n["technologyList[".concat(t,"].keyword")]="請輸入技術檢索式")}),o.forEach((e,t)=>{e.name.trim()||(n["functionList[".concat(t,"].name")]="請輸入功效名稱"),e.keyword.trim()||(n["functionList[".concat(t,"].keyword")]="請輸入功效檢索式")}),d(n),na().isEmpty(n)},y=async n=>{if(n.preventDefault(),w())try{let t=await (0,v.ti)({}).post("patent/search/matrix",{industrialClassIds:e.industrialClassIds,queryString:e.queryString,techQueries:i.map(n=>n.keyword),funcQueries:o.map(n=>n.keyword)});p(t.data),f(!0)}catch(r){(0,j.Po)(r)}},b=()=>{r([{name:"",keyword:""}]),l([{name:"",keyword:""}]),d({})},Z=(n,e,t,a)=>{let s="technology"===a?[...i]:[...o];s[n][e]=t;let u={...c};u["".concat(a,"List[").concat(n,"].").concat(e)]&&""!==t.trim()&&delete u["".concat(a,"List[").concat(n,"].").concat(e)],d(u),"technology"===a?r(s):l(s)},C=n=>
1{"technology"===n?i.length<6?r([...i,{name:"",keyword:""}]):(0,en.xh)("技術"+ee.j.MATRIX_FIELD_LIMIT):o.length<6?l([...o,{name:"",keyword:""}]):(0,en.xh)("功效"+ee.j.MATRIX_FIELD_LIMIT)},k=(n,e)=>{if("technology"===e){let t=i.filter((e,t)=>t!==n);r(t)}else{let a=o.filter((e,t)=>t!==n);l(a)}},I=n=>{if(0===n.length)return;let e=n[0];if(e.size>1048576){(0,en.xh)("檔案超過最大大小限制");return}tG().parse(e,{header:!0,skipEmptyLines:!0,complete:n=>{let e=n.data,t=[],i=[],o="";e.forEach(n=>{"技術"===n.axis?t.push({name:n.name,keyword:n.keyword}):"功效"===n.axis?i.push({name:n.name,keyword:n.keyword}):o="無效的座標軸名稱"}),o?(0,en.xh)(o):(r(t),l(i),d({}))},error:()=>{(0,en.xh)("檔案解析失敗")}})};return(0,a.jsxs)(ij,{children:[(0,a.jsxs)("form",{onSubmit:y,children:[(0,a.jsxs)(iZ,{children:[(0,a.jsxs)(iC,{children:[(0,a.jsx)(ik,{children:"技術功效分析"}),(0,a.jsx)(tW.ZP,{onDrop:I,accept:{"text/csv":[".csv"]},children:n=>{let{getRootProps:e,getInputProps:t}=n;return(0,a.jsxs)("div",{...e(),children:[(0,a.jsx)("input",{...t()}),(0,a.jsx)(et.zx,{type:"button",template:et.YS.DEFAULT,fontSize:14,children:"上傳設定檔"})]})}})]}),(i.some(n=>n.name||n.keyword)||o.some(n=>n.name||n.keyword))&&(0,a.jsx)(et.zx,{type:"button",template:et.YS.PRIMARY,onClick:b,children:"清除"})]}),(0,a.jsxs)(iI,{children:[(0,a.jsx)("h4",{children:"技術清單"}),i.map((n,e)=>(0,a.jsxs)(iF,{type:"technology",children:[(0,a.jsx)("span",{children:"技術"}),(0,a.jsxs)(iA,{hasError:!!c["technologyList[".concat(e,"].name")],children:[(0,a.jsx)("input",{type:"text",value:n.name,placeholder:"名稱",onChange:n=>Z(e,"name",n.target.value,"technology")}),c["technologyList[".concat(e,"].name")]&&(0,a.jsx)(iT,{children:c["technologyList[".concat(e,"].name")]})]}),(0,a.jsxs)(iR,{hasError:!!c["technologyList[".concat(e,"].keyword")],children:[(0,a.jsx)("textarea",{value:n.keyword,placeholder:"檢索式",onChange:n=>Z(e,"keyword",n.target.value,"technology")}),c["technologyList[".concat(e,"].keyword")]&&(0,a.jsx)(iT,{children:c["technologyList[".concat(e,"].keyword")]})]}),i.length>1&&(0,a.jsx)(iL,{onClick:()=>k(e,"technology")})]},e)),(0,a.jsx)("h4",{children:"功效清單"}),o.map((n,e)=>(0,a.jsxs)(iF,{type:"function",children:[(0,a.jsx)("span",{children:"功效"}),(0,a.jsxs)(iA,{hasError:!!c["functionList[".concat(e,"].name")],children:[(0,a.jsx)("input",{type:"text",value:n.name,placeholder:"名稱",onChange:n=>Z(e,"name",n.target.value,"function")}),c["functionList[".concat(e,"].name")]&&(0,a.jsx)(iT,{children:c["functionList[".concat(e,"].name")]})]}),(0,a.jsxs)(iR,{hasError:!!c["functionList[".concat(e,"].keyword")],children:[(0,a.jsx)("textarea",{value:n.keyword,placeholder:"檢索式",onChange:n=>Z(e,"keyword",n.target.value,"function")}),c["functionList[".concat(e,"].keyword")]&&(0,a.jsx)(iT,{children:c["functionList[".concat(e,"].keyword")]})]}),o.length>1&&(0,a.jsx)(iL,{onClick:()=>k(e,"function")})]},e)),(0,a.jsxs)(iE,{children:[(0,a.jsxs)(iz,{type:"technology",onClick:()=>C("technology"),children:[(0,a.jsx)(nn.wEH,{}),"新增技術"]}),(0,a.jsxs)(iz,{type:"function",onClick:()=>C("function"),children:[(0,a.jsx)(nn.wEH,{}),"新增功效"]})]})]}),(0,a.jsxs)(ep,{children:[(0,a.jsx)(et.zx,{type:"submit",template:et.YS.PRIMARY,children:"分析結果"}),(0,a.jsx)(et.zx,{type:"button",template:et.YS.PRIMARY_LIGHT,onClick:m,children:"下載設定檔"}),(0,a.jsx)(n9.CSVLink,{ref:g,filename:"技術功效矩陣設定檔.csv",headers:[{label:"axis",key:"axis"},{label:"name",key:"name"},{label:"keyword",key:"keyword"}],data:(()=>{let n=i.map(n=>({axis:"技術",name:n.name,keyword:n.keyword})),e=o.map(n=>({axis:"功效",name:n.name,keyword:n.keyword}));return[...n,...e]})(),style:{display:"none"}})]})]}),x&&(0,a.jsxs)(tP,{open:x,title:h,setClose:()=>f(!1),extraDownloadItem:(0,a.jsx)("div",{onClick:()=>eI(h),children:"PDF 格式"}),children:[(0,a.jsx)(i_,{children:(0,a.jsx)(t5,{xAxisLabels:i.map(n=>n.name),yAxisLabels:o.map(n=>n.name),dataset:u})}),(0,a.jsxs)(iN,{children:[(0,a.jsx)(iq,{children:"矩陣結果"}),(0,a.jsxs)(iH,{children:[(0,a.jsx)("span",{children:"分析母體:"}),e.queryString]}),(0,a.jsxs)(iM,{children:[(0,a.jsxs)(iD,{children:[(0,a.jsx)(iX,{}),(0,a.jsx)(iX,{children:"技術"}),i.map((n,e)=>(0,a.jsx)(iX,{children:n.name},e))]}),(0,a.jsxs)(iD,{children:[(0,a.jsx)(iU,{children:"功效"}),(0,a.jsx)(iU,{children:"檢索條件"}),i.map((n,e)=>(0,a.jsx)(iU,{children:n.keyword},e))]}),o.map((n,e)=>(0,a.jsxs)(iD,{children:[(0,a.jsx)(iU,{children:n.name}),(0,a.jsx)(iU,{children:n.keyword}),i.map((n,t)=>{let i=u[e][t];return(0,a.jsx)(iU,{children:i>0?(0,a.jsx)(iB,{children:(0,Q.tV)(i)}):(0,a.jsx)("span",{children:"0"})},t)})]},e))]})]}),(0,a.jsxs)(iY,{children:[(0,a.jsx)("div",{children:"本系統書目資料為公告時原始資料,後續異動更新請至「權利異動」頁面瀏覽。"}),(0,a.jsx)("div",{children:"本系統資料僅供參考,不作為懷薄之依據,所有資料以經濟部智慧財產局公告為準。"})]})]})]})},iV=n=>
1{let{data:e,iconOnly:t,hideLong:i}=n,[r,o]=(0,s.useState)(t),[l,c]=(0,s.useState)(!1),[d,u]=(0,s.useState)(!1),p=(0,s.useRef)(null),f=null==e?void 0:e.map(n=>{var e;return{titles:n.titles||"",country:n.country||"",publicationNumber:n.publicationNumber||"",publicationDate:n.publicationDate||"",inventorNames:n.inventorNames?n.inventorNames.map(n=>n.names.join(", ")).join(", "):"",applicantNames:n.applicantNames?n.applicantNames.map(n=>n.names.join(", ")).join(", "):"",abstracts:(null===(e=n.abstracts)||void 0===e?void 0:e.join(", "))||""}}),h=()=>{p.current&&p.current.link&&p.current.link.click()},g=(0,x.I)(n=>n.basicRequest),m=(0,x.I)(n=>n.resultTotalCount),v=()=>{m<=0?(0,en.xh)(ee.j.RESULT_COUNT_NOT_ENOUGH):(c(!l),u(!1))},w=()=>{m<=0?(0,en.xh)(ee.j.RESULT_COUNT_NOT_ENOUGH):(u(!d),c(!1))};return(0,s.useEffect)(()=>{l||d?o(!1):o(!0)},[l,d]),(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)(nN.qJ,{top:120,hideLong:i,iconOnly:r,children:[(0,a.jsxs)(nN.Eg,{active:!1,onClick:v,children:[(0,a.jsx)(nN._4,{children:(0,a.jsx)(nn.NMh,{size:"16px"})}),"統計分析"]}),(0,a.jsxs)(nN.Eg,{active:!1,onClick:w,children:[(0,a.jsx)(nN._4,{children:(0,a.jsx)(nn.uOL,{size:"16px"})}),"功效矩陣"]}),(0,a.jsxs)(nN.Eg,{active:!1,onClick:h,children:[e&&(0,a.jsx)(n9.CSVLink,{ref:p,filename:"專利匯出結果.csv",headers:[{label:"專利名稱",key:"titles"},{label:"國別",key:"country"},{label:"公開/公告號",key:"publicationNumber"},{label:"公開/公告日",key:"publicationDate"},{label:"發明人",key:"inventorNames"},{label:"申請人",key:"applicantNames"},{label:"摘要",key:"abstracts"}],data:f}),(0,a.jsx)(nN._4,{children:(0,a.jsx)(nn.aBF,{size:"14px"})}),"專利匯出"]}),l&&(0,a.jsx)(tK,{searchRequest:g}),d&&(0,a.jsx)(iK,{searchRequest:g,setClose:()=>u(!1)})]})})};var iG=t(43205),iW=t(87998);function i$(){let n=(0,o.Z)(["\n    margin: 0;\n    margin-bottom: 18px;\n    padding-left: 32px;\n  "]);return i$=function(){return n},n}function iJ(){let n=(0,o.Z)(["\n  ","\n"]);return iJ=function(){return n},n}function iQ(){let n=(0,o.Z)(["\n  display: none;\n  @media (min-width: ",") {\n    display: flex;\n    left: 60px;\n    flex-direction: column;\n    max-width: 300px;\n  }\n"]);return iQ=function(){return n},n}function i0(){let n=(0,o.Z)(["\n  border: 0;\n  box-shadow: none;\n  padding: 0;\n  margin: 0;\n\n  > p {\n    margin: 8px 32px;\n    padding-top: 8px;\n    color: ",";\n  }\n\n  @media (min-width: ",") {\n    > p {\n      margin: 8px;\n    }\n  }\n\n  @media (min-width: ",") {\n    padding: 0;\n    display: flex;\n    flex-direction: column;\n    justify-content: space-between;\n    min-width: 680px;\n    gap: 20px;\n    > p {\n      margin: 0;\n      padding: 0;\n    }\n  }\n"]);return i0=function(){return n},n}function i1(){let n=(0,o.Z)(["\n  width: 100%;\n  padding: 0;\n  justify-content: space-between;\n  align-items: flex-start;\n  flex-direction: column-reverse;\n  padding: 0;\n\n  @media (min-width: ",") {\n    flex-direction: row;\n    align-items: center;\n    gap: 0;\n  }\n"]);return i1=function(){return n},n}function i5(){let n=(0,o.Z)(["\n  flex: 0 0 48px;\n"]);return i5=function(){return n},n}function i6(){let n=(0,o.Z)(["\n    width: 750px;\n    overflow-y: auto;\n  "]);return i6=function(){return n},n}function i2(){let n=(0,o.Z)(["\n  ","\n\n  ","\n"]);return i2=function(){return n},n}function i8(){let n=(0,o.Z)(["\n  border-radius: 4px 4px 0 0;\n  background-image: linear-gradient(99deg, ",", ",");\n  display: flex;\n  align-items: flex-end;\n  padding: 8px 16px 0 16px;\n"]);return i8=function(){return n},n}function i4(){let n=(0,o.Z)(["\n          color: ",";\n          background-color: ",";\n        "]);return i4=function(){return n},n}function i3(){let n=(0,o.Z)(["\n          color: ",";\n          background-color: ",";\n        "]);return i3=function(){return n},n}function i7(){let n=(0,o.Z)(["\n  padding: 8px 16px;\n  margin-right: 4px;\n  line-height: 1;\n  border-radius: 4px 4px 0 0;\n  text-align: center;\n  :hover {\n    cursor: pointer;\n  }\n\n  transition: 0.3s ease;\n  transition-property: color, background-color;\n\n  ","\n"]);return i7=function(){return n},n}function i9(){let n=(0,o.Z)(["\n          padding-top: 0px;\n        "]);return i9=function(){return n},n}function rn(){let n=(0,o.Z)(["\n          display: none;\n        "]);return rn=function(){return n},n}function re(){let n=(0,o.Z)(["\n  width: 271px;\n  background-color: ",";\n  border-left: 1px solid #dee2e4;\n  border-right: 1px solid #dee2e4;\n  border-radius: 0 0 4px 4px;\n  max-height: calc(100vh - 45px);\n  overflow: auto;\n  ","\n\n  ","\n"]);return re=function(){return n},n}function rt(){let n=(0,o.Z)(["\n  display: flex;\n  align-items: center;\n  min-width: 150px;\n"]);return rt=function(){return n},n}function ri(){let n=(0,o.Z)(["\n  color: ",";\n  margin-right: 8px;\n"]);return ri=function(){return n},n}function rr(){let n=(0,o.Z)(["\n  display: flex;\n  position: relative;\n"]);return rr=function(){return n},n}function ro(){let n=(0,o.Z)(["\n  display: flex;\n  gap: 20px;\n"]);return ro=function(){return n},n}function ra(){let n=(0,o.Z)(["\n  width: 120px;\n  font-size: 16px;\n  color: ",";\n"]);return ra=function(){return n},n}function rl(){let n=(0,o.Z)(["\n  width: 120px;\n  font-size: 16px;\n  color: ",";\n\n  @media (max-width: ",") {\n    display: none;\n  }\n"]);return rl=function(){return n},n}let rc=s.memo(nh),rs=n=>(0,d.iv)(iJ(),n&&(0,d.iv)(i$())),rd=(0,d.iv)(iQ(),O.Sv),ru=(0,d.iv)(i0(),D.di,O.zp,O.Sv),rp=(0,d.iv)(i1(),O.zp),rx=(0,d.iv)(i5()),rf=n=>
1(0,d.iv)(i2(),c.re,n&&(0,d.iv)(i6())),rh=d.ZP.div.withConfig({componentId:"sc-52386b4d-0"})(i8(),D.K3,D.Ub),rg=d.ZP.div.withConfig({componentId:"sc-52386b4d-1"})(i7(),n=>n.isActive?(0,d.iv)(i4(),D.Ub,D.Xt):(0,d.iv)(i3(),D.Xt,(0,D.OH)(.3))),rm=d.ZP.div.withConfig({componentId:"sc-52386b4d-2"})(re(),D.Xt,tA.T,n=>n.isActive?(0,d.iv)(i9()):(0,d.iv)(rn())),rv=d.ZP.div.withConfig({componentId:"sc-52386b4d-3"})(rt()),rw=d.ZP.span.withConfig({componentId:"sc-52386b4d-4"})(ri(),D.Ub),ry=d.ZP.div.withConfig({componentId:"sc-52386b4d-5"})(rr()),rb=d.ZP.div.withConfig({componentId:"sc-52386b4d-6"})(ro()),rj=(0,d.iv)(ra(),D.K3),rZ=(0,d.iv)(rl(),D.K3,O.Sv),rC=[{text:"相關度",value:"SCORE"},{text:"日期",value:"DATE"}],rk=[{text:"TW",value:"TW"},{text:"CN",value:"CN"},{text:"JP",value:"JP"},{text:"EP",value:"EP"},{text:"US",value:"US"},{text:"KR",value:"KR"}],rI=n=>({...n,data:n.data.map(n=>(0,p.VX)(n))}),rP=()=>{let[n,e]=(0,s.useState)(!1),[t,i]=(0,s.useState)(""),[r,o]=(0,s.useState)(!1),[d,p]=(0,s.useState)(!1),[m,w]=(0,s.use
1State)(),[y,b]=(0,s.useState)(null),[j,Z]=(0,s.useState)(!1),[C,k]=(0,s.useState)(0),[I,P]=(0,s.useState)([...Array(rk.length)].map((n,e)=>0===e||e===C)),S=n=>{k(n),I[n]||P(I.map((e,t)=>t===n||e))},[F,A]=(0,s.useState)(rC[0]),[R,T]=(0,s.useState)({text:"不限時間",value:""}),E=(0,x.I)(n=>n.needRefetch),z=(0,x.I)(n=>n.basicRequest),L=(0,x.I)(n=>n.expert,W.Z),_=(0,x.I)(n=>n.dedupe),N=(0,x.I)(n=>n.bilingualTerm),D=(0,x.I)(n=>n.country),O=(0,x.I)(n=>n.advanceKeywords),X=(0,x.I)(n=>n.userCriteria),U=(0,x.I)(n=>n.ptab),Y=(0,x.I)(n=>n.resultTotalCount),B=(0,s.useMemo)(()=>[{title:"篩選",panel:(0,a.jsx)(q,{})},{title:"聚類",panel:j?(0,a.jsx)(rc,{}):null}],[j]),[K,V,$]=(0,x.I)(n=>[n.startRefetch,n.refetchFinished,n.setCountry]),J=n=>{n!==D&&($(n),nc())},nn=(0,a.jsx)(g.Z,{headerText:U?"美國PTAB資料檢索":"專利檢索",queryCriteria:X,hasSideMenu:!0,customStyle:rs(r)}),ne=L||"以文找文"===X&&"以文找文"!==z.queryString?rk.filter(n=>n.text===D):"1"===U?[{text:"US",value:"US"}]:rk,{size:nt}=(0,M.Z)(),ni="large"===nt,nr=e=>n?(0,a.jsx)(nT,{patent:e,isCompareMode:d,setComparePatentId:i},e.id):(0,a.jsx)(c.QY,{maxWidth:768,customStyle:ru,children:(0,a.jsx)(u.Z,{patent:e,isCompareMode:d,setComparePatentId:i},e.id)}),no=(0,s.useCallback)(()=>{r?p(!1):p(!0),o(n=>!n)},[r]);(0,s.useEffect)(()=>{if(t){let n=(0,v.ti)({}),e=async()=>{try{let e=await (0,nz.vZ)(n,t);w(e)}catch(i){console.error("獲取資料發生錯誤:",i)}};e()}},[t]);let na=()=>{o(!1),w(void 0),p(!1)},nl=(0,s.useCallback)(n=>{b(n),Z(!0)},[]);(0,s.useEffect)(()=>{E&&Z(!1)},[E]);let nc=(0,s.useCallback)(()=>{try{var n;let{basicRequest:e,advanceKeywords:t,userCriteria:i}=x.I.getState(),r=null==e?void 0:null===(n=e.queryString)||void 0===n?void 0:n.trim();if(!r||"以文找文"===i)return;(0,v.ti)({}).post("patent/search/log",{...e,keyword:e.queryString,advanceKeywords:t})}catch(o){console.error("Failed to write search log:",o)}},[]);(0,s.useEffect)(()=>{var n;let e=null==z?void 0:null===(n=z.queryString)||void 0===n?void 0:n.trim();if(e)try{let t=JSON.stringify({basicRequest:z,country:D,advanceKeywords:O,bilingualTerm:N,dedupe:_,ptab:U,sortBasis:F,dateRange:R,userCriteria:X});sessionStorage.setItem("patentStore.temp",t)}catch(i){console.error("[searchApiParams] saved failed:",i)}},[z,D,O,N,_,U,F,R,X]);let[ns,nd]=(0,s.useState)(!1);(0,s.useEffect)(()=>{try{let n=sessionStorage.getItem("patentStore.temp"),e=n?JSON.parse(n):null;if(e){var t,i,r,o,a,l;x.I.setState(n=>({...n,basicRequest:null!==(t=e.basicRequest)&&void 0!==t?t:n.basicRequest,country:null!==(i=e.country)&&void 0!==i?i:n.country,advanceKeywords:null!==(r=e.advanceKeywords)&&void 0!==r?r:n.advanceKeywords,bilingualTerm:null!==(o=e.bilingualTerm)&&void 0!==o?o:n.bilingualTerm,dedupe:"boolean"==typeof e.dedupe?e.dedupe:n.dedupe,ptab:null!==(a=e.ptab)&&void 0!==a?a:n.ptab,userCriteria:null!==(l=e.userCriteria)&&void 0!==l?l:n.userCriteria})),e.sortBasis&&A(e.sortBasis),e.dateRange&&T(e.dateRange)}}catch(c){console.error("[searchApiParams] restore is failed",c)}finally{nd(!0)}},[]);let nu=ns&&!!((null==z?void 0:z.queryString)&&z.queryString.trim().length>0),np=(0,s.useRef)(!1),nx=(0,s.useRef)(void 0);return(0,s.useEffect)(()=>{var n,e;if(!ns)return;let t=null===(n=x.I.getState().basicRequest)||void 0===n?void 0:null===(e=n.queryString)||void 0===e?void 0:e.trim();if(t){if(!np.current){np.current=!0,nx.current=t,nc();return}nx.current!==t&&(nx.current=t,nc())}},[null==z?void 0:z.queryString,ns,nc]),(0,a.jsx)(l.Z,{theme:"white",headerMinHeight:114,isFixed:r,headerContent:nn,contentMaxWidth:ni?1440:768,name:"search.result",floatActions:ni?void 0:[(0,a.jsx)(G,{},"PatentSubscribeFloatAction")],children:(0,a.jsxs)(c.or,{customStyle:rf(r),children:[!r&&(0,a.jsxs)(c.fM,{customStyle:rd,children:[(0,a.jsx)(rh,{children:B.map((n,e)=>(0,a.jsx)(rg,{isActive:C===e,onClick:()=>S(e),children:n.title},n.title))}),B.map((n,e)=>(0,a.jsx)(rm,{isActive:C===e,children:I[e]&&n.panel},n.title))]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)(c.QY,{maxWidth:768,customStyle:ru,children:[(0,a.jsx)("p",{children:"共 ".concat((0,Q.tV)(Y)," 件搜尋結果")}),(0,a.jsx)(f.Z,{listStyle:rp,tabStyle:rx,tabs:ne,active:D,onTabClick:n=>J(n),rightChildren:(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(q,{inHeader:!0,useButton:!0}),(0,a.jsxs)("div",{style:{display:"flex",alignItems:"center",position:"relative"},children:[ni&&(0,a.jsxs)(ry,{children:[(0,a.jsx)(iG.Z,{options:iW.N,selected:R,onChange:n=>{T(n),nc(),K()},customStyle:rZ,menuWidth:"100px"}),(0,a.jsx)(H.Z,{selected:F,options:rC,onChange:n=>{A(n),nc(),K()},text:F.text,transparent:!0,customStyle:rj,menuPosition:{width:"100px"}})]}),(0,a.jsxs)(rb,{children:[(0,a.jsx)(ny,{isGridMode:n,setIsGridMode:e}),!ni&&(0,a.jsx)(H.Z,{selected:F,options:rC,onChange:n=>{A(n),nc(),K()},text:F.text}),ni&&(0,a.jsxs)(rv,{children:[(0,a.jsx)(rw,{children:"雙欄瀏覽"}),(0,a.jsx)(nE.Z,{checked:r,change:no})]})]})]})]}),rightBlockVariant:"up"})]}),nu&&(0,a.jsx)(h.Z,{api:"api/patent/search",method:"POST",params:{...z,expert:L,bilingualTerm:N,dedupe:_,sortByDate:F&&"DATE"===F.value,dateRange:R.value,advanceKeywords:O,ptab:U},respToPaginated:rI,needRefetch:E,refetchFinished:V,render:nr,noResultsFound:{description:""},isGridMode:n,gridColumns:ni?2:1,gridMaxWidth:"850px",onDataLoaded:nl})]}),r&&(0,a.jsx)(n7,{isCompareMode:d,isLoading:!1,patentData:m,onPaneClose:na}),ni&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(G,{},"PatentSubscribeFloatAction"),(0,a.jsx)(iV,{data:null==y?void 0:y.data,iconOnly:!0,hideLong:-75})]})]})})};var rS=rP},82031:function(n,e,t){"use strict";t.d(e,{Z:function(){return Z}});var i=t(7297),r=t(85893),o=t(67294),a=t(87536),l=t(36631);let c=async(n,e)=>n.post("/patent/subscription",{...e,industryId:0}),s=async(n,e,t)=>n.patch("/patent/subscription/".concat(e),{name:t});var d=t(67630),u=t(84357),p=t(37982),x=t(45699),f=t(16553),h=t(50366),g=t(68830),m=t(50066);function v(){let n=(0,i.Z)(["\n  padding: 16px 32px;\n  > * + * {\n    margin-top: 16px;\n  }\n"]);return v=function(){return n},n}let w=m.ZP.div.withConfig({componentId:"sc-69328183-0"})(v()),y=async(n,e,t)=>c((0,l.ti)({}),{name:n.subscribeName,keyword:n.criteria,advanceKeywords:e,bilingualTerm:t}),b=async(n,e)=>s((0,l.ti)({}),n,e),j=n=>{let{defaultValues:e,trackId:t}=n,i=void 0!==t,l=(0,f.th)(n=>n.openSnackbar),c=(0,x.I)(n=>n.advanceKeywords),s=(0,x.I)(n=>n.bilingualTerm),m=(0,h.I)(n=>n.fetchTracks),{register:v,getValues:j,reset:Z,formState:{errors:C},handleSubmit:k,clearErrors:I}=(0,a.cI)({defaultValues:e});return(0,o.useEffect)(()=>{n.open||(I(),Z(e))},[n.open,I,Z,e]),(0,r.jsx)(u.default,{expand:!0,title:(i?"編輯":"新增")+"專利追蹤",confirmButton:{text:i?"儲存":"新增",preventDefault:!0,onClick:()=>{let e=j(),r=k(async()=>{(i?b(t,e.subscribeName):y(e,c,s)).then(()=>{l({message:i?"編輯「".concat(e.subscribeName,"」成功"):"專利追蹤成功"}),m(),n.setOpen(!1)}).catch(n=>(0,d.Po)(n))});r()}},cancelButton:{preventDefault:!0,onClick:()=>{Z(e)}},...n,children:(0,r.jsxs)(w,{children:[(0,r.jsx)(p.Z,{type:"text",label:"專利追蹤名稱",placeholder:"請輸入追蹤名稱",fieldName:"subscribeName",register:v,registerConfig:{validate:g.np},errors:C}),(0,r.jsx)(p.Z,{type:"textarea",plainText:e.criteria,label:"追蹤條件設定",fieldName:"
1criteria",register:v,registerConfig:{validate:g.np},errors:C})]})})};var Z=j},48038:function(n,e,t){"use strict";t.d(e,{Z:function(){return G}});var i=t(7297),r=t(85893);t(67294);var o=t(50066),a=t(25675),l=t.n(a),c=t(50779),s=t(34736),d=t(53340),u=t(71570),p=t(41664),x=t.n(p),f=t(18318),h=t(52091);function g(){let n=(0,i.Z)(["\n  color: ",";\n"]);return g=function(){return n},n}let m=o.ZP.span.withConfig({componentId:"sc-d3947e87-0"})(g(),n=>n.light?"#ffa500":"#ebebeb"),v=n=>{let e=Array.from([,,,,,].keys());return(0,r.jsx)("div",{children:e.map(e=>e<n.stars?(0,r.jsx)(m,{light:!0,children:(0,r.jsx)(h.QJe,{})},"star".concat(e)):(0,r.jsx)(m,{light:!1,children:(0,r.jsx)(h.QJe,{})},"star".concat(e)))})};var w=t(89780),y=t(95600),b=t(10637);function j(){let n=(0,i.Z)(["\n  border-bottom: 1px solid ",";\n\n  padding: 24px 32px;\n  // RWD Tablet\n  @media screen and (min-width: ",") {\n    padding: 24px 0;\n  }\n"]);return j=function(){return n},n}function Z(){let n=(0,i.Z)(["\n  color: ",";\n  font-size: 14px;\n  margin-bottom: 8px;\n"]);return Z=function(){return n},n}function C(){let n=(0,i.Z)(["\n  display: flex;\n"]);return C=function(){return n},n}function k(){let n=(0,i.Z)(["\n  flex: 1;\n  font-size: 18px;\n  line-height: 26px;\n  color: ",";\n  margin-bottom: 8px;\n  ",";\n  cursor: pointer;\n"]);return k=function(){return n},n}function I(){let n=(0,i.Z)(["\n  margin: 8px 0;\n"]);return I=function(){return n},n}function P(){let n=(0,i.Z)(["\n  text-align: right;\n  height: 26px;\n  padding-top: 3px;\n  font-size: 18px;\n  font-weight: 400;\n  color: ",";\n  margin-left: 14px;\n"]);return P=function(){return n},n}function S(){let n=(0,i.Z)(["\n  display: flex;\n  align-items: center;\n"]);return S=function(){return n},n}function F(){let n=(0,i.Z)(["\n  flex: 1;\n  min-width: 0;\n  padding-right: 8px;\n"]);return F=function(){return n},n}function A(){let n=(0,i.Z)(["\n  flex: 0 0 76px;\n  min-height: 76px;\n  border-radius: 4px;\n  overflow: hidden;\n  align-self: flex-start;\n"]);return A=function(){return n},n}function R(){let n=(0,i.Z)(["\n  color: ",";\n  font-size: 15px;\n  margin-bottom: 8px;\n  ",";\n"]);return R=function(){return n},n}function T(){let n=(0,i.Z)(["\n  color: ",";\n  font-size: 14px;\n  margin-bottom: 16px;\n  div {\n    margin-bottom: 2px;\n    ",";\n  }\n"]);return T=function(){return n},n}function E(){let n=(0,i.Z)(["\n  width: 96px;\n  height: 96px;\n  border-radius: 4px;\n  overflow: hidden;\n"]);return E=function(){return n},n}function z(){let n=(0,i.Z)(["\n  position: absolute;\n  top: 24px;\n  right: 0;\n"]);return z=function(){return n},n}let L=o.ZP.div.withConfig({componentId:"sc-e181a6cc-0"})(j(),c.yf,d.zp),_=o.ZP.div.withConfig({componentId:"sc-e181a6cc-1"})(Z(),c.di),N=o.ZP.div.withConfig({componentId:"sc-e181a6cc-2"})(C()),M=o.ZP.a.withConfig({componentId:"sc-e181a6cc-3"})(k(),c.Ub,u.D),D=o.ZP.div.withConfig({componentId:"sc-e181a6cc-4"})(I()),O=o.ZP.div.withConfig({componentId:"sc-e181a6cc-5"})(P(),c.vr),X=o.ZP.div.withConfig({componentId:"sc-e181a6cc-6"})(S()),U=o.ZP.div.withConfig({componentId:"sc-e181a6cc-7"})(F()),Y=o.ZP.div.withConfig({componentId:"sc-e181a6cc-8"})(A()),q=o.ZP.div.withConfig({componentId:"sc-e181a6cc-9"})(R(),c.R_,u.D),H=o.ZP.div.withConfig({componentId:"sc-e181a6cc-10"})(T(),c.di,u.D),B=o.ZP.div.withConfig({componentId:"sc-e181a6cc-11"})(E()),K=o.ZP.div.withConfig({componentId:"sc-e181a6cc-12"})(z()),V=n=>{let{topLabel:e,patent:t,handleMenuClick:i,isCompareMode:o=!1,isShowTags:a=!1,setComparePatentId:d}=n,{id:u,patentDataId:p,titles:h,abstracts:g,inventorNames:m,applicantNames:j,publicationNumber:Z,kind:C,publicationDate:k,imgAlias:I,rating:P}=t,{size:S}=(0,y.Z)(),F="large"===S,A=I&&I.length>0?"patent/".concat(u,"/img/").concat(I[0]):void 0,R=(0,b.Gh)(A);return(0,r.jsxs)(L,{children:[e&&(0,r.jsx)(_,{children:e}),(0,r.jsxs)(N,{children:[o?(0,r.jsx)(M,{as:"div",maxLine:3,onClick:()=>{o&&d&&d(u)},children:h?h.join(" | "):""}):(0,r.jsx)(x(),{href:"/patent/".concat(u),passHref:!0,legacyBehavior:!0,children:(0,r.jsx)(M,{target:"_blank",maxLine:3,children:h?h.join(" | "):""})}),i&&(0,r.jsx)(O,{onClick:()=>i(t),children:(0,r.jsx)(f.tvF,{})})]}),p&&a&&!F&&(0,r.jsx)(D,{children:(0,r.jsx)(w.Z,{patentDataId:p,editorAnchor:K,fontColor:c.Ub,maxTagsVisible:2,showDeleteIcon:!1})}),(0,r.jsxs)(X,{children:[(0,r.jsxs)(U,{children:[(0,r.jsx)(q,{maxLine:3,children:g?g.join(" "):""}),void 0!==P&&(0,r.jsx)(v,{stars:P}),(0,r.jsxs)(H,{children:[(0,r.jsx)("div",{children:(0,r.jsx)("div",{children:m?m.map(n=>n.names.join(" ")).join(", "):""})}),(0,r.jsx)("div",{children:(0,r.jsx)("div",{children:j?j.map(n=>n.names.join(" ")).join(", "):""})}),(0,r.jsx)("div",{children:(0,r.jsx)("div",{children:"".concat(Z).concat(C).concat(k?" / "+(0,s.vh)(k):"")})})]}),p&&a&&F&&(0,r.jsx)(w.Z,{patentDataId:p,title:"標籤",editorAnchor:K,fontColor:c.di})]}),(0,r.jsx)(Y,{children:R&&(0,r.jsx)(B,{children:(0,r.jsx)(l(),{src:R,alt:"patent image",width:100,height:100,style:{objectFit:"cover",width:"100%",height:"100%"},unoptimized:!0})})})]})]})};var G=V},6640:function(n,e,t){"use strict";var i=t(7297),r=t(85893),o=t(67294),a=t(50066),l=t(52091),c=t(89755),s=t.n(c),d=t(25675),u=t.n(d),p=t(50779),x=t(10637);function f(){let n=(0,i.Z)(["\n  display: flex;\n  align-items: center;\n  justify-content: center;\n  width: calc(100% - 75px);\n  height: ",";\n  position: ",";\n\n  img {\n    max-width: 100%;\n    max-height: 100%;\n  }\n"]);return f=function(){return n},n}function h(){let n=(0,i.Z)(["\n  position: absolute;\n  width: 37px;\n  height: 75px;\n  background-color: ",";\n  display: flex;\n  align-items: center;\n  :hover {\n    cursor: pointer;\n  }\n\n  svg {\n    font-size: 28px;\n    color: ",";\n  }\n"]);return h=function(){return n},n}function g(){let n=(0,i.Z)(["\n  left: 0;\n  border-bottom-right-radius: 75px;\n  border-top-right-radius: 75px;\n  justify-content: flex-start;\n"]);return g=function(){return n},n}function m(){let n=(0,i.Z)(["\n  right: 0;\n  border-bottom-left-radius: 75px;\n  border-top-left-radius: 75px;\n  justify-content: flex-end;\n"]);return m=function(){return n},n}let v=a.ZP.div.withConfig({componentId:"sc-f84115ea-0"})(f(),n=>{let{height:e}=n;return e||"240px"},n=>{let{contentType:e}=n;return"image"===e&&"relative"}),w=a.ZP.div.withConfig({componentId:"sc-f84115ea-1"})(h(),p.q4,p.FT),y=(0,a.ZP)(w).withConfig({componentId:"sc-f84115ea-2"})(g()),b=(0,a.ZP)(w).withConfig({componentId:"sc-f84115ea-3"})(m()),j=n=>{var e;let{patent:t,isOverlayDetailShow:i,height:a,initialImageAlias:c,contentType:d=""}=n,p=(0,o.useMemo)(()=>
1{if(!t.imgAlias||!c)return 0;let n=t.imgAlias.findIndex(n=>{let e=n.split("/").pop();return e===c});return n>=0?n:0},[t.imgAlias,c]),[f,h]=(0,o.useState)(p),g=null===(e=t.imgAlias)||void 0===e?void 0:e[i?0:f],m=g?"patent/".concat(t.id,"/img/").concat(g):void 0,w=(0,x.Gh)(m),j=n=>{n.stopPropagation(),t.imgAlias&&f<t.imgAlias.length-1&&h(f+1)},Z=n=>{n.stopPropagation(),f>0&&h(f-1)};return(0,r.jsx)(r.Fragment,{children:t.imgAlias&&w&&(i?(0,r.jsx)(v,{height:a,contentType:d,children:"image"===d?(0,r.jsx)(u(),{src:w,alt:"patent image",fill:!0,style:{objectFit:"contain"},unoptimized:!0}):(0,r.jsx)(s(),{src:w,alt:"patent image",width:200,height:200,style:{objectFit:"cover",width:"100%",height:"100%"},unoptimized:!0})}):(0,r.jsxs)(r.Fragment,{children:[f>0&&(0,r.jsx)(y,{onClick:Z,children:(0,r.jsx)(l._HU,{})}),(0,r.jsx)(v,{height:a,contentType:d,children:"image"===d?(0,r.jsx)(u(),{src:w,alt:"patent image",fill:!0,style:{objectFit:"contain"},unoptimized:!0}):(0,r.jsx)(s(),{src:w,alt:"patent image",width:200,height:200,style:{objectFit:"cover",width:"100%",height:"100%"},unoptimized:!0})}),f<t.imgAlias.length-1&&(0,r.jsx)(b,{onClick:j,children:(0,r.jsx)(l.H_v,{})})]}))})};e.Z=j},61048:function(n,e,t){"use strict";t.d(e,{l:function(){return j}});var i=t(7297),r=t(85893),o=t(67294),a=t(50066),l=t(41664),c=t.n(l),s=t(52091),d=t(50779),u=(t(67630),t(6640));function p(){let n=(0,i.Z)(["\n      display: flex;\n      align-items: center;\n      justify-content: space-between;\n    "]);return p=function(){return n},n}function x(){let n=(0,i.Z)(["\n  position: absolute;\n  left: 0;\n  bottom: 0;\n  width: 100%;\n  ","\n  background-color: ",";\n  transition: 0.5s ease;\n  opacity: ",";\n"]);return x=function(){return n},n}function f(){let n=(0,i.Z)(["\n  padding: 8px 16px;\n  overflow: hidden;\n  text-overflow: ellipsis;\n  white-space: nowrap;\n  color: ",";\n  font-weight: 500;\n"]);return f=function(){return n},n}function h(){let n=(0,i.Z)(["\n  padding: 4px 16px 0 16px;\n  user-select: text;\n\n  div {\n    overflow: hidden;\n    text-overflow: ellipsis;\n    white-space: nowrap;\n    color: ",";\n    margin-bottom: 4px;\n\n    span {\n      font-weight: 500;\n      margin-right: 4px;\n    }\n  }\n"]);return h=function(){return n},n}function g(){let n=(0,i.Z)(["\n  display: flex;\n  align-items: center;\n  justify-content: flex-end;\n  color: ",";\n"]);return g=function(){return n},n}function m(){let n=(0,i.Z)(["\n  display: flex;\n  align-items: center;\n  flex-wrap: nowrap;\n  white-space: nowrap;\n  padding: 8px 16px;\n\n  svg {\n    margin-right: 4px;\n  }\n\n  :hover {\n    cursor: pointer;\n  }\n\n  a:link,\n  a:visited {\n    color: inherit;\n  }\n\n  @media screen and (max-width: 1280px) {\n    padding: 8px 8px;\n  }\n"]);return m=function(){return n},n}function v(){let n=(0,i.Z)(["\n  position: relative;\n  display: flex;\n  align-items: center;\n  justify-content: center;\n  width: 100%;\n  min-height: 120px;\n  border-top: solid 1px ",";\n  /** 避免使用者連點造成反白 */\n  user-select: none;\n"]);return v=function(){return n},n}let w=a.ZP.div.withConfig({componentId:"sc-8c564651-0"})(x(),n=>!n.isDetailShow&&(0,a.iv)(p()),d.q4,n=>n.isShow?1:0);a.ZP.div.withConfig({componentId:"sc-8c564651-1"})(f(),d.R_),a.ZP.div.withConfig({componentId:"sc-8c564651-2"})(h(),d.R_);let y=a.ZP.div.withConfig({componentId:"sc-8c564651-3"})(g(),(0,d.Ti)(.8)),b=a.ZP.div.withConfig({componentId:"sc-8c564651-4"})(m()),j=a.ZP.div.withConfig({componentId:"sc-8c564651-5"})(v(),d.yf),Z=n=>{let{patent:e,listIndex:t}=n,[i,a]=(0,o.useState)(!1),[l,d]=(0,o.useState)(!1),p=()=>{x(e.id)},x=async n=>{};return(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)(j,{onMouseOver:()=>a(!0),onMouseOut:()=>a(!1),children:[(0,r.jsx)(u.Z,{patent:e,isOverlayDetailShow:l}),(0,r.jsx)(w,{isShow:i,isDetailShow:l,onMouseEnter:()=>d(!0),onMouseLeave:()=>d(!1),children:(0,r.jsxs)(y,{children:[(0,r.jsxs)(b,{onClick:p,children:[(0,r.jsx)(s.z5B,{}),"預覽"]}),(0,r.jsx)(b,{children:(0,r.jsx)(c(),{href:"/patent/".concat(e.id,"/view"),passHref:!0,children:(0,r.jsxs)("a",{target:"_blank",rel:"noopener noreferrer",children:[(0,r.jsx)(s.CkN,{}),"進入頁面"]})})})]})})]})})};e.Z=Z},46657:function(n,e,t){"use strict";t.d(e,{Z:function(){return C}});var i=t(7297),r=t(85893),o=t(67294),a=t(67675),l=t(93726),c=t(95600),s=t(53340),d=t(20931),u=t(50779),p=t(50066),x=t(52091);function f(){let n=(0,i.Z)(["\n  position: relative;\n  display: flex;\n  align-items: center;\n  padding: 16px;\n  border-bottom: 1px solid ",";\n  background-color: ",";\n\n  input {\n    width: 100%;\n    border-radius: 4px;\n    border: solid 1px ",";\n    background-color: ",";\n    padding: 8px 32px 8px 16px;\n  }\n  svg {\n    position: absolute;\n    right: 32px;\n    font-size: 16px;\n  }\n"]);return f=function(){return n},n}let h=p.ZP.div.withConfig({componentId:"sc-1cd6660-0"})(f(),u.yf,u.Vn,u.w5,u.Xt),g=n=>(0,r.jsxs)(h,{children:[(0,r.jsx)("input",{type:"text",placeholder:"Search",value:n.searchKeyword,onChange:n.onChange}),(0,r.jsx)(x.U41,{color:u.di})]});var m=t(53855),v=function(n){let[e,t]=(0,o.useState)(""),[i,a]=(0,o.useState)(n);(0,o.useEffect)(()=>{a(n)},[n]);let l=e=>{let i=e.target.value;""!==i?a(n.filter(function(n){let e=i.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1");return -1!==n.name.search(RegExp(e,"i"))})):a(n),t(i)},c=(n,e)=>{if(""===e)return n;{let t=e.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1"),i=n.split(RegExp("(".concat(t,")"),"gi"));return(0,r.jsx)("span",{children:i.map((n,t)=>(0,r.jsx)(m.iP,{isMatched:1===t&&n.toLowerCase()===e.toLowerCase(),children:n},t))})}};return{searchKeyword:e,filteredContent:i,handleKeywordChange:l,getHighlightedText:c}};function w(){let n=(0,i.Z)(["\n  padding-left: 32px;\n  @media (min-width: ",") {\n    padding-left: 0;\n    width: 260px;\n    height: fit-content;\n    border-bottom: 1px solid ",";\n  }\n"]);return w=function(){return n},n}function y(){let n=(0,i.Z)(["\n  max-height: 300px;\n  overflow: auto;\n  ","\n  background-color: ",";\n"]);return y=function(){return n},n}let b=p.ZP.div.withConfig({componentId:"sc-de82ceff-0"})(w(),s.zp,u.yf),j=p.ZP.div.withConfig({componentId:"sc-de82ceff-1"})(y(),d.T,u.Vn),Z=n=>
1{let{facet:e,displayName:t,selectedField:i,expandingFacet:s,isFieldsLoading:d,handleFieldSelect:u,handleFieldCancel:p,handleFacetExpand:x,pageType:f=""}=n,{searchKeyword:h,filteredContent:w,handleKeywordChange:y,getHighlightedText:Z}=v(e.facetFieldCounts),[C,k]=(0,o.useState)(!1),I=e.keyCode===s,P=e.facetFieldCounts.length>0,S=()=>{k(!C)},{size:F}=(0,c.Z)();return(0,o.useEffect)(()=>{"IQ"===e.keyCode&&k(!0)},[]),(0,r.jsx)(r.Fragment,{children:"large"===F?(0,r.jsxs)(b,{children:[(0,r.jsx)(l.Z,{label:t,selected:!!i,disabled:!P,nestedSelectedText:null==i?void 0:i.name,onSelectedCancel:()=>p(e.keyCode),isNextLoading:d,onNextClick:P?S:void 0,keyCode:e.keyCode}),C&&(0,r.jsxs)(r.Fragment,{children:[e.facetFieldCounts.length>6&&(0,r.jsx)(g,{searchKeyword:h,onChange:n=>y(n)}),(0,r.jsx)(j,{children:""!==h&&0===w.length?(0,r.jsx)(m.vM,{children:'查無 "'.concat(h,'" 的符合結果')}):w.map(n=>(0,r.jsx)(a.Z,{label:n.name,count:n.count,selected:i&&i.identity===n.identity,onRowClick:()=>u(e.keyCode,n),searchKeyword:h,getHighlightedText:Z,pageType:f},n.identity))})]})]}):s&&!I?(0,r.jsx)(r.Fragment,{}):(0,r.jsx)(b,{children:I?e.facetFieldCounts.map(n=>(0,r.jsx)(a.Z,{label:n.name,count:n.count,selected:i&&i.identity===n.identity,onRowClick:()=>u(e.keyCode,n)},n.identity)):(0,r.jsx)(l.Z,{label:t,selected:!!i,disabled:!P,nestedSelectedText:null==i?void 0:i.name,onSelectedCancel:()=>p(e.keyCode),isNextLoading:d,onNextClick:P?()=>x(e):void 0})})})};var C=Z},37462:function(n,e,t){"use strict";t.d(e,{Z:function(){return x}});var i=t(7297),r=t(85893),o=t(67294),a=t(50066),l=t(84357),c=t(93726);let s=n=>{let{selected:e,displayingParent:t,setDisplayingParent:i}=n,[a,l]=(0,o.useState)(()=>n.options);(0,o.useEffect)(()=>{t||l(n.options)},[t,n.options]);let s=n=>{let e=null==n?void 0:n.nestedOption;return e&&i?()=>{l(e),i(n)}:void 0};return(0,r.jsx)(r.Fragment,{children:a.map(t=>{let i=t.value===(null==e?void 0:e.parentVal);return(0,r.jsx)(c.Z,{label:t.text,selected:t.value===(null==e?void 0:e.value)||i,nestedSelectedText:i?e.text:void 0,trailedText:t.trailedText,onSelectedCancel:i?()=>n.setSelected(t):void 0,onRowClick:()=>n.setSelected(t,!0),onNextClick:s(t)},t.value)})})};function d(){let n=(0,i.Z)(["\n  padding: 16px 0 16px 32px;\n"]);return d=function(){return n},n}let u=a.ZP.div.withConfig({componentId:"sc-1caef813-0"})(d()),p=n=>{let{options:e,selected:t,open:i,setOpen:a,setSelected:c}=n,[d,p]=(0,o.useState)(),x=(n,e)=>{c(n),e&&a(!1)};return(0,r.jsx)(l.default,{title:d?d.text:n.label,open:i,setOpen:a,backButton:d?{preventDefault:!0,onClick:()=>{p(void 0)}}:void 0,children:(0,r.jsx)(u,{children:(0,r.jsx)(s,{options:e,selected:t,setSelected:x,displayingParent:d,setDisplayingParent:p})})})};var x=p},67675:function(n,e,t){"use strict";var i=t(7297),r=t(85893),o=t(67294),a=t(52091),l=t(50779),c=t(94923),s=t(34736),d=t(50066),u=t(58990),p=t(53340);function x(){let n=(0,i.Z)(["\n  display: flex;\n  gap: 18px;\n  align-items: flex-start;\n  border-bottom: 1px solid ",";\n  padding-right: 16px;\n\n  @media (min-width: ",") {\n    padding-left: 16px;\n    cursor: pointer;\n    :hover {\n      background-color: ",";\n      > div {\n        color: ",";\n      }\n    }\n  }\n"]);return x=function(){return n},n}function f(){let n=(0,i.Z)(["\n  padding: ",";\n\n  flex-grow: 1;\n  min-width: 0;\n  display: flex;\n  align-items: flex-start;\n  color: ",";\n  font-weight: 400;\n  gap: 18px;\n  justify-content: space-between;\n\n  cursor: pointer;\n"]);return f=function(){return n},n}function h(){let n=(0,i.Z)(["\n      span {\n        white-space: normal;\n        overflow-wrap: anywhere;\n        overflow: visible;\n      }\n    "]);return h=function(){return n},n}function g(){let n=(0,i.Z)(["\n      color: ",";\n      font-weight: 500;\n      ",":hover & {\n        color: ",";\n      }\n    "]);return g=function(){return n},n}function m(){let n=(0,i.Z)(["\n  flex-grow: 1;\n  display: flex;\n  align-items: center;\n  align-items: flex-start;\n  min-width: 0;\n  span {\n    white-space: nowrap;\n    overflow: hidden;\n    text-overflow: ellipsis;\n  }\n  ","\n\n  ","\n"]);return m=function(){return n},n}function v(){let n=(0,i.Z)(["\n  color: ",";\n  text-align: right;\n  display: flex;\n  align-items: center;\n  justify-content: flex-end;\n"]);return v=function(){return n},n}function w(){let n=(0,i.Z)(["\n  flex: 0 0 16px;\n  font-size: 16px;\n  line-height: 1;\n  font-weight: 400;\n  display: flex;\n  align-items: center;\n  padding: 0;\n  height: ",";\n"]);return w=function(){return n},n}let y=d.ZP.div.withConfig({componentId:"sc-9be2d671-0"})(x(),l.yf,p.zp,l.Ub,l.Xt),b=d.ZP.div.withConfig({componentId:"sc-9be2d671-1"})(f(),n=>{let{pageType:e}=n;return"image"===e?"10px 0":"16px 0"},l.R_),j=d.ZP.div.withConfig({componentId:"sc-9be2d671-2"})(m(),n=>n.expand&&(0,d.iv)(h()),n=>n.selected&&(0,d.iv)(g(),l.Ub,y,l.Xt)),Z=d.ZP.div.withConfig({componentId:"sc-9be2d671-3"})(v(),l.FT),C=(0,d.ZP)(c.Av).withConfig({componentId:"sc-9be2d671-4"})(w(),n=>{let{pageType:e}=n;return"image"===e?"45px":"56px"}),k=n=>{let{pageType:e="",...t}=n,i=(0,o.useRef)(null),l=(0,u.Z)(i),[c,d]=(0,o.useState)(!1),p=()=>{t.selected||t.onRowClick()};return(0,r.jsxs)(y,{children:[(0,r.jsxs)(b,{onClick:p,pageType:e,children:[(0,r.jsx)(j,{expand:c,selected:t.selected,children:t.searchKeyword&&t.getHighlightedText?(0,r.jsx)("span",{ref:i,children:t.getHighlightedText(t.label,t.searchKeyword)}):(0,r.jsx)("span",{ref:i,children:t.label})}),t.count&&(0,r.jsx)(Z,{children:(0,s.tV)(t.count)})]}),(0,r.jsx)(C,{onClick:()=>l&&d(n=>!n),pageType:e,children:l&&(c?(0,r.jsx)(a.s$2,{}):(0,r.jsx)(a.RiI,{}))})]})};e.Z=k},43205:function(n,e,t){"use strict";
1var i=t(85893),r=t(67294),o=t(73935),a=t(94067),l=t(95842),c=t(50779),s=t(52091),d=t(72853);let u=n=>{let{label:e,showLabel:t,selected:u,options:p,onChange:x,customStyle:f,menuborderRadius:h=4,menuHeight:g,menuWidth:m="100%",activeOption:v,isSort:w}=n,[y,b]=(0,r.useState)(!1),[j,Z]=(0,r.useState)(""),[C,k]=(0,r.useState)({top:0,left:0}),[I,P]=(0,r.useState)(!1),S=(0,r.useRef)(null),F=(0,d.Z)(()=>{b(!1),Z("")});(0,r.useEffect)(()=>{if(y&&S.current){let n=S.current.getBoundingClientRect();k({top:n.bottom+window.scrollY,left:n.left+window.scrollX}),P(!0)}else P(!1)},[y]),(0,r.useEffect)(()=>{v&&Z(v.text)},[v]);let A=n=>{x(n),b(!1)};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("div",{ref:S,children:(0,i.jsx)(a.Z,{customStyle:f,isOpen:y,setOpen:b,label:e,showLabel:t,text:null==u?void 0:u.text,isSort:w},null==u?void 0:u.text)}),y&&I&&(0,o.createPortal)((0,i.jsx)(l.v2,{ref:F,width:m,height:g,borderRadius:h,menuPositionTop:C.top,menuPositionLeft:C.left,children:p.map(n=>(0,i.jsxs)(r.Fragment,{children:[(0,i.jsxs)(l.sN,{defaultColor:c.v5,HoverColor:c.Ub,onClick:()=>A(n),active:(null==u?void 0:u.text)===n.text,children:[n.text,n.nestedOption&&n.nestedOption.length>0&&(j===n.text?(0,i.jsx)(s.s$2,{onClick:n=>{n.stopPropagation(),Z("")}}):(0,i.jsx)(s.RiI,{onClick:e=>{e.stopPropagation(),Z(n.text)}}))]}),j===n.text&&n.nestedOption&&(0,i.jsx)(l.Bv,{children:n.nestedOption.map(e=>(0,i.jsx)(l.pI,{active:(null==u?void 0:u.text)===e.text,onClick:()=>x(e),children:e.text},"".concat(n.value,"-").concat(e.value)))})]},n.value))}),document.body)]})};e.Z=u},49186:function(n,e,t){"use strict";var i=t(85893),r=t(67294),o=t(94067),a=t(95842),l=t(50779),c=t(52091),s=t(72853);let d=n=>{let{label:e,showLabel:t,selected:d,options:u,onChange:p,customStyle:x,menuPositionTop:f=55,menuPositionLeft:h=0,menuborderRadius:g=4,menuHeight:m,menuWidth:v="100%",activeOption:w}=n,[y,b]=(0,r.useState)(!1),[j,Z]=(0,r.useState)("");(0,r.useEffect)(()=>{w&&Z(w.text)},[w]);let C=n=>{p(n),b(!1)},k=()=>{b(!1),Z("")},I=(0,s.Z)(k);return(0,i.jsx)(i.Fragment,{children:(0,i.jsx)(o.Z,{customStyle:x,isOpen:y,setOpen:b,label:e,showLabel:t,text:null==d?void 0:d.text,ref:I,children:y&&u&&(0,i.jsx)(a.v2,{width:v,menuPositionTop:f,menuPositionLeft:h,borderRadius:g,height:m,children:u.length>0&&u.map(n=>(0,i.jsxs)(r.Fragment,{children:[(0,i.jsxs)(a.sN,{defaultColor:l.v5,HoverColor:l.Ub,onClick:()=>C(n),active:(null==d?void 0:d.text)===n.text,children:[n.text,n.nestedOption&&n.nestedOption.length>0&&(j===n.text?(0,i.jsx)(c.s$2,{onClick:n=>{n.stopPropagation(),Z("")}}):(0,i.jsx)(c.RiI,{onClick:e=>{e.stopPropagation(),Z(n.text)}}))]}),j===n.text&&n.nestedOption&&(0,i.jsx)(a.Bv,{children:n.nestedOption.map(e=>(0,i.jsx)(a.pI,{active:(null==d?void 0:d.text)===e.text,onClick:()=>p(e),children:e.text},"".concat(n.value,"-").concat(e.value)))})]},n.value))})},null==d?void 0:d.text)})};e.Z=d},73454:function(n,e,t){"use strict";t.d(e,{Z:function(){return p}});var i=t(85893),r=t(67294),o=t(37462),a=t(30200),l=t(61121);let c=n=>{let{onClick:e,text:t,transparent:r}=n;return(0,i.jsx)(a.Z,{onClick:e,text:t,transparent:r,children:(0,i.jsx)(l.bM7,{size:22})})};var s=t(95600),d=t(43205);let u=n=>{let{selected:e,options:t,onChange:a,text:l,transparent:u,customStyle:p,menuPosition:x}=n,[f,h]=(0,r.useState)(!1),{size:g}=(0,s.Z)();return(0,i.jsx)(i.Fragment,{children:"large"===g?(0,i.jsx)(d.Z,{options:t,selected:e,onChange:a,customStyle:p,menuWidth:null==x?void 0:x.width,menuHeight:null==x?void 0:x.height,menuborderRadius:null==x?void 0:x.borderRadius,isSort:!0}):(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(c,{onClick:()=>h(!0),text:l,transparent:u}),(0,i.jsx)(o.Z,{label:"排序",open:f,setOpen:h,selected:e,setSelected:a,options:t})]})})};var p=u},72543:function(n,e,t){"use strict";var i=t(85893),r=t(30200),o=t(52091);let a=n=>(0,i.jsx)(r.Z,{...n,children:(0,i.jsx)(o.ulB,{})});e.Z=a},20122:function(n,e,t){"use strict";t.d(e,{T:function(){return u}});var i=t(7297),r=t(85893);t(67294);var o=t(52091),a=t(26944),l=t(50066),c=t(53340);function s(){let n=(0,i.Z)(["\n  display: none;\n  @media (min-width: ",") {\n    display: flex;\n  }\n"]);return s=function(){return n},n}let d=l.ZP.div.withConfig({componentId:"sc-ad598a57-0"})(s(),c.Sv),u=n=>{let{onClick:e,third:t,sideThird:i}=n;return(0,r.jsx)(a.I,{onClick:e,secondary:!0,third:t,sideThird:i,children:(0,r.jsxs)(r.Fragment,{children:[(t||i)&&(0,r.jsx)(d,{children:"專利追蹤"}),(0,r.jsx)(o.FZ6,{})]})})}},37982:function(n,e,t){"use strict";var i=t(7297),r=t(85893),o=t(15775),a=t(20500),l=t(50779),c=t(50066),s=t(32866);function d(){let n=(0,i.Z)(["\n  color: ",";\n"]);return d=function(){return n},n}let u=c.ZP.div.withConfig({componentId:"sc-34d541cb-0"})(d(),l.di),p=n=>{let{type:e,required:t,label:i,description:l,fieldName:c,register:d,registerConfig:p,plainText:x,errors:f}=n,h=!!f[c],g=void 0!==x;return(0,r.jsxs)(a.sg,{children:[(0,r.jsx)(a.__,{required:t,children:i}),g&&(0,r.jsx)(u,{children:x}),"textarea"!==e||g?(0,r.jsx)(o.Z,{error:h,...n,...d(c,p),type:g?"hidden":e}):(0,r.jsx)(o.Z,{as:"textarea",error:h,...n,...d(c,p)}),!h&&(0,r.jsx)(a.dk,{children:l}),(0,r.jsx)(s.B,{errors:f,name:c,render:n=>{let{message:e}=n;return(0,r.jsx)(a.dk,{error:!0,children:e})}})]})};e.Z=p},20500:function(n,e,t){"use strict";t.d(e,{__:function(){return f},dk:function(){return x},sg:function(){return p}});var i=t(7297),r=t(50779),o=t(50066);function a(){let n=(0,i.Z)(["\n        margin-top: 8px;\n      "]);return a=function(){return n},n}function l(){let n=(0,i.Z)(["\n  > * + * {\n    margin-top: 12px;\n    ",";\n  }\n  input {\n    height: 40px;\n  }\n"]);return l=function(){return n},n}function c(){let n=(0,i.Z)(["\n      color: ",";\n    "]);return c=function(){return n},n}function s(){let n=(0,i.Z)(["\n  line-height: 16px;\n  font-size: 12px;\n  color: ",";\n\n  ","\n"]);return s=function(){return n},n}function d(){let n=(0,i.Z)(["\n      ::before {\n        content: '';\n        background-color: ",";\n        position: absolute;\n        border-radius: 3px;\n        width: 6px;\n        height: 6px;\n        left: -8px;\n      }\n    "]);return d=function(){return n},n}function u(){let n=(0,i.Z)(["\n  position: relative;\n  font-size: 16px;\n  line-height: 22px;\n  color: ",";\n\n  ","\n"]);return u=function(){return n},n}let p=o.ZP.div.withConfig({componentId:"sc-d175a043-0"})(l(),n=>n.dense&&(0,o.iv)(a())),x=o.ZP.div.withConfig({componentId:"sc-d175a043-1"})(s(),r.SL,n=>n.error&&(0,o.iv)(c(),r.si)),f=o.ZP.div.withConfig({componentId:"sc-d175a043-2"})(u(),r.R_,n=>n.required&&(0,o.iv)(d(),r.si))},94067:function(n,e,t){"use strict";var i=t(7297),r=t(85893),o=t(67294),a=t(50066),l=t(50779),c=t(52091),s=t(61121);function d(){let n=(0,i.Z)(["\n  width: 100%;\n  padding: 4px 0 4px 16px;\n  color: ",";\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n  min-width: 0;\n  cursor: pointer;\n\n  & > div {\n    min-width: 0;\n  }\n\n  & > svg {\n    flex: 0 0 36px;\n  }\n\n  ",";\n"]);return d=function(){return n},n}function u(){let n=(0,i.Z)(["\n  display: inline-block;\n  font-size: 12px;\n  color: ",";\n"]);return u=function(){return n},n}function p(){let n=(0,i.Z)(["\n  overflow: hidden;\n  text-overflow: ellipsis;\n  white-space: nowrap;\n"]);return p=function(){return n},n}let x=a.ZP.div.withConfig({componentId:"sc-20e7d76f-0"})(d(),l.R_,n=>n.customStyle),f=a.ZP.span.withConfig({componentId:"sc-20e7d76f-1"})(u(),l.w5),h=a.ZP.div.withConfig({componentId:"sc-20e7d76f-2"})(p()),g=(0,o.forwardRef)((n,e)=>{let{label:t,showLabel:i,text:o="",customStyle:a,isOpen:l,setOpen:d,children:u,isSort:p}=n;return(0,r.jsxs)(x,{ref:e,customStyle:a,onClick:()=>d(!l),children:[(0,r.jsxs)("div",{children:[t&&i&&(0,r.jsx)(f,{children:t}),(0,r.jsx)(h,{children:o})]}),p?(0,r.jsx)(s.bM7,{size:22}):l?(0,r.jsx)(c.IkZ,{size:20}):(0,r.jsx)(c.qL$,{size:20}),u]})});g.displayName="SelectInput",e.Z=g},50366:function(n,e,t){"use strict";t.d(e,{I:function(){return l}});var i=t(36631),r=t(67630),o=t(64529);let a={selectedTrack:void 0,needRefetch:!1},l=(0,o.ZP)((n,e)=>({...a,fetchTracks:async()=>{let t=new AbortController;try{let o=e().selectedTrack,a=await (0,i.ti)({}).get("patent/subscription",{signal:t.signal}).then(n=>n.data),l=o&&a.find(n=>n.id===o.id);n(n=>({...n,tracks:a,selectedTrack:l||a[0],needRefetch:!0}))}catch(c){(0,r.Po)(c)}return()=>t.abort()},refetchFinished:()=>n(n=>({...n,needRefetch:!1})),setSelectedTrack:e=>n(n=>({...n,selectedTrack:e,needRefetch:!0}),!1)}))},53855:function(n,e,t){"use strict";t.d(e,{Bl:function(){return H},O4:function(){return q},W2:function(){return A},_6:function(){return Y},al:function(){return D},dA:function(){return N},gz:function(){return U},iM:function(){return _},iP:function(){return z},lZ:function(){return O},nW:function(){return M},su:function(){return X},v0:function(){return R},vM:function(){return L}});var i=t(7297),r=t(50066),o=t(50779),a=t(63657);function l(){let n=(0,i.Z)(["\n  border-bottom: 1px solid #dee2e4;\n  background-color: ",";\n"]);return l=function(){return n},n}function c(){let n=(0,i.Z)(["\n  margin: 16px;\n  color: #bdc9cb;\n"]);return c=function(){return n},n}function s(){let n=(0,i.Z)(["\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n  color: ",";\n  padding: 10px 16px;\n  :hover {\n    cursor: pointer;\n  }\n"]);return s=function(){return n},n}function d(){let n=(0,i.Z)(["\n  background-color: ",";\n  :hover {\n    cursor: auto;\n  }\n  svg {\n    :hover {\n      cursor: pointer;\n    }\n  }\n"]);return d=function(){return n},n}function u(){let n=(0,i.Z)(["\n  /* width */\n  ::-webkit-scrollbar {\n    width: 2px;\n  }\n  /* Handle */\n  ::-webkit-scrollbar-thumb {\n    background: ",";\n    border-radius: 10px;\n  }\n  /* Handle on hover */\n  ::-webkit-scrollbar-thumb:hover {\n    background: ",";\n  }\n"]);return u=function(){return n},n}function p(){let n=(0,i.Z)(["\n  margin: 0 16px 8px 0;\n  background-color: ",";\n  color: ",";\n  display: ",";\n  max-height: 160px;\n  overflow-x: hidden;\n  overflow-y: auto;\n  ","\n"]);return p=function(){return n},n}function x(){let n=(0,i.Z)(["\n  max-width: 45%;\n"]);return x=function(){return n},n}function f(){let n=(0,i.Z)(["\n  display: inline-block;\n  color: ",";\n  overflow: hidden;\n  text-overflow: ellipsis;\n  max-width: 40%;\n"]);return f=function(){return n},n}function h(){let n=(0,i.Z)(["\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n  /* 避免遮到scrollbar */\n  margin-right: 2px;\n  padding: 4px 8px 4px 16px;\n  :hover {\n    cursor: pointer;\n    background-color: ",";\n  }\n"]);return h=function(){return n},n}function g(){let n=(0,i.Z)(["\n  overflow: hidden;\n  text-overflow: ellipsis;\n  min-width: 40px;\n"]);return g=function(){return n},n}function m(){let n=(0,i.Z)(["\n  font-size: 10px;\n"]);return m=function(){return n},n}function v(){let n=(0,i.Z)(["\n  text-decoration: ",";\n"]);return v=function(){return n},n}function w(){let n=(0,i.Z)(["\n  padding: 4px 16px;\n  color: ",";\n"]);return w=function(){return n},n}function y(){let n=(0,i.Z)(["\n  color: ",";\n  user-select: none;\n  :hover {\n    background-color: ",";\n    cursor: pointer;\n  }\n"]);return y=function(){return n},n}function b(){let n=(0,i.Z)(["\n  margin-right: 8px;\n  overflow: hidden;\n  text-overflow: ellipsis;\n"]);return b=function(){return n},n}function j(){let n=(0,i.Z)(["\n  display: flex;
1\n  svg {\n    width: 20px;\n    height: 20px;\n  }\n  :hover {\n    cursor: pointer;\n    opacity: 0.6;\n  }\n"]);return j=function(){return n},n}function Z(){let n=(0,i.Z)(["\n  margin: 0;\n  background-color: ",";\n  color: ",";\n  display: ",";\n  user-select: none;\n"]);return Z=function(){return n},n}function C(){let n=(0,i.Z)(["\n  width: 100%;\n  height: 260px;\n  background-color: #ffffff;\n"]);return C=function(){return n},n}function k(){let n=(0,i.Z)(["\n  color: #b3b9bc;\n  user-select: none;\n  :hover {\n    cursor: auto;\n  }\n"]);return k=function(){return n},n}function I(){let n=(0,i.Z)(["\n  max-height: 500px;\n  overflow: auto;\n  ","\n"]);return I=function(){return n},n}function P(){let n=(0,i.Z)(["\n  margin-bottom: 8px;\n  color: ",";\n"]);return P=function(){return n},n}function S(){let n=(0,i.Z)(["\n  color: ",";\n  padding: 6px 16px;\n"]);return S=function(){return n},n}function F(){let n=(0,i.Z)(["\n  display: ",";\n  border-left: 1px solid ",";\n  margin-left: 24px;\n  p {\n    padding: 0 16px;\n    line-height: 32px;\n    overflow: hidden;\n    text-overflow: ellipsis;\n  }\n  p:hover {\n    cursor: pointer;\n    background-color: ",";\n  }\n"]);return F=function(){return n},n}let A=r.ZP.div.withConfig({componentId:"sc-8581d458-0"})(l(),o.Xt),R=r.ZP.p.withConfig({componentId:"sc-8581d458-1"})(c()),T=r.ZP.div.withConfig({componentId:"sc-8581d458-2"})(s(),o.di);(0,r.ZP)(T).withConfig({componentId:"sc-8581d458-3"})(d(),(0,o.hp)(.3));let E=(0,r.iv)(u(),o.RP,o.K3);r.ZP.div.withConfig({componentId:"sc-8581d458-4"})(p(),o.Xt,o.Ub,n=>n.isShow?"block":"none",E),r.ZP.div.withConfig({componentId:"sc-8581d458-5"})(x()),(0,r.ZP)(a.Z).withConfig({componentId:"sc-8581d458-6"})(f(),o.Ub),r.ZP.div.withConfig({componentId:"sc-8581d458-7"})(h(),o.m9),r.ZP.span.withConfig({componentId:"sc-8581d458-8"})(g()),r.ZP.span.withConfig({componentId:"sc-8581d458-9"})(m());let z=r.ZP.span.withConfig({componentId:"sc-8581d458-10"})(v(),n=>n.isMatched?"underline":""),L=r.ZP.div.withConfig({componentId:"sc-8581d458-11"})(w(),o.di),_=(0,r.ZP)(T).withConfig({componentId:"sc-8581d458-12"})(y(),n=>n.color||o.di,o.m9),N=r.ZP.div.withConfig({componentId:"sc-8581d458-13"})(b()),M=r.ZP.span.withConfig({componentId:"sc-8581d458-14"})(j()),D=r.ZP.div.withConfig({componentId:"sc-8581d458-15"})(Z(),o.Xt,o.Ub,n=>n.isShow?"block":"none"),O=r.ZP.div.withConfig({componentId:"sc-8581d458-16"})(C()),X=(0,r.ZP)(T).withConfig({componentId:"sc-8581d458-17"})(k()),U=r.ZP.div.withConfig({componentId:"sc-8581d458-18"})(I(),E),Y=r.ZP.div.withConfig({componentId:"sc-8581d458-19"})(P(),o.FT),q=(0,r.ZP)(_).withConfig({componentId:"sc-8581d458-20"})(S(),o.FT),H=r.ZP.div.withConfig({componentId:"sc-8581d458-21"})(F(),n=>n.isShow?"block":"none",o.yf,o.m9)},87998:function(n,e,t){"use strict";var i,r;t.d(e,{N:function(){return o},X:function(){return i}}),(r=i||(i={})).U="不限時間",r.Y="年",r.H="半年",r.Q="季",r.M="月",r.W="週";let o=[{text:"不限時間",value:""},{text:"月",value:"1"},{text:"季",value:"3"},{text:"半年",value:"6"},{text:"一年 ",value:"12"}]},43216:function(n,e,t){"use strict";t.d(e,{b:function(){return i}});let i="不分行業"},8762:function(n,e,t){"use strict";t.d(e,{X:function(){return o},_:function(){return r}});let i=new Map([["IC","國際分類號"],["IN","發明人"],["PA","申請人"],["ID","公開日"],["KC","專利種類"],["DEDUPE","檢索去重"],["BILINGUAL","雙語詞彙"],["IQ","LOC"]]),r=n=>"PO"!==n,o=n=>i.get(n)||n},68830:function(n,e,t){"use strict";t.d(e,{KP:function(){return g},Lr:function(){return w},SU:function(){return u},aH:function(){return d},h:function(){return m},iS:function(){return a},jA:function(){return v},np:function(){return s},qg:function(){return x},sC:function(){return p},tA:function(){return l},tH:function(){return f},x$:function(){return c},xG:function(){return r},xJ:function(){return i}});let i=n=>{let e;return/^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,4}$/i.test(n)||(e="無效的電子郵件"),e},r=n=>{let e;return n&&0!==n.length&&""!==n.trim()||(e="請描述問題"),e},o=(n,e,t)=>{let i;return""===n&&(i="請".concat(e).concat(t)),i},a=n=>o(n,"輸入","帳號"),l=n=>o(n,"輸入","密碼"),c=n=>o(n,"輸入","驗證碼"),s=n=>""===n.trim()?"此欄位不可空白":void 0,d=n=>0===n.length?"此欄位不可空白":void 0,u=n=>{let e;return""===n.trim()?e="此欄位不可空白":/^(?=.*[a-z])(?=.*[A-Z])[a-zA-Z\d._]{6,32}$/i.test(n)||(e="無效的帳號, 請輸入6-32位的字母、數字、英文句號「.」或底線「_」組合"),e},p=(n,e)=>
1{if((!e||""!==n)&&!/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)[a-zA-Z\d()[\]{}&lt;&gt;+-\\*/?,.:;&quot;'_\\|~`!@#$%^&=]{8,32}$/.test(n))return"請輸入8到32位包含英文大小寫字母,以及數字"},x=n=>{let e;return/^.{1,400}$/.test(n)||(e="此欄位不可空白"),e},f=n=>{let e;return/^[0-9-#]{8,20}$/.test(n)||(e="無效的電話, 請輸入數字及「-」「#」, 8-20字元"),e},h=(n,e)=>{let t;return n||(t="請輸入".concat(e,"日期")),t},g=n=>h(n,"起始"),m=n=>h(n,"結束"),v=n=>o(n,"選擇","資料來源"),w=n=>o(n,"輸入","案件公開/公告號")}},function(n){n.O(0,[9317,4738,3365,4817,6660,4396,3662,724,7847,4011,7151,9243,7536,8320,6510,4751,2398,8944,6491,3750,3923,8638,2240,9062,805,4647,9774,2888,179],function(){return n(n.s=90948)}),_N_E=n.O()}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.