diff --git a/assets/index-5b02eac9.js b/assets/index-8410345b.js similarity index 90% rename from assets/index-5b02eac9.js rename to assets/index-8410345b.js index bcbde8c..a65c398 100644 --- a/assets/index-5b02eac9.js +++ b/assets/index-8410345b.js @@ -923,7 +923,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho border-radius: 50%; } } -`,FS={root:function(t){var n=t.props,r=t.instance;return["p-badge p-component",{"p-badge-no-gutter":U.isNotEmpty(n.value)&&String(n.value).length===1,"p-badge-dot":U.isEmpty(n.value)&&!r.$slots.default,"p-badge-lg":n.size==="large","p-badge-xl":n.size==="xlarge","p-badge-info":n.severity==="info","p-badge-success":n.severity==="success","p-badge-warning":n.severity==="warning","p-badge-danger":n.severity==="danger"}]}},DS=gt.extend({name:"badge",css:$S,classes:FS}),zS={name:"BaseBadge",extends:Xt,props:{value:{type:[String,Number],default:null},severity:{type:String,default:null},size:{type:String,default:null}},style:DS,provide:function(){return{$parentInstance:this}}},T1={name:"Badge",extends:zS};function RS(e,t,n,r,i,o){return E(),j("span",$({class:e.cx("root")},e.ptm("root"),{"data-pc-name":"badge"}),[le(e.$slots,"default",{},function(){return[et(Y(e.value),1)]})],16)}T1.render=RS;function Pi(e){"@babel/helpers - typeof";return Pi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Pi(e)}function bn(e,t,n){return t=NS(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function NS(e){var t=VS(e,"string");return Pi(t)==="symbol"?t:String(t)}function VS(e,t){if(Pi(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Pi(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var HS={root:function(t){var n=t.instance,r=t.props;return["p-button p-component",bn(bn(bn(bn(bn(bn(bn(bn({"p-button-icon-only":n.hasIcon&&!r.label&&!r.badge,"p-button-vertical":(r.iconPos==="top"||r.iconPos==="bottom")&&r.label,"p-disabled":n.$attrs.disabled||n.$attrs.disabled===""||r.loading,"p-button-loading":r.loading,"p-button-loading-label-only":r.loading&&!n.hasIcon&&r.label,"p-button-link":r.link},"p-button-".concat(r.severity),r.severity),"p-button-raised",r.raised),"p-button-rounded",r.rounded),"p-button-text",r.text),"p-button-outlined",r.outlined),"p-button-sm",r.size==="small"),"p-button-lg",r.size==="large"),"p-button-plain",r.plain)]},loadingIcon:"p-button-loading-icon pi-spin",icon:function(t){var n=t.props;return["p-button-icon",{"p-button-icon-left":n.iconPos==="left"&&n.label,"p-button-icon-right":n.iconPos==="right"&&n.label,"p-button-icon-top":n.iconPos==="top"&&n.label,"p-button-icon-bottom":n.iconPos==="bottom"&&n.label}]},label:"p-button-label"},BS=gt.extend({name:"button",classes:HS}),US={name:"BaseButton",extends:Xt,props:{label:{type:String,default:null},icon:{type:String,default:null},iconPos:{type:String,default:"left"},iconClass:{type:String,default:null},badge:{type:String,default:null},badgeClass:{type:String,default:null},badgeSeverity:{type:String,default:null},loading:{type:Boolean,default:!1},loadingIcon:{type:String,default:void 0},link:{type:Boolean,default:!1},severity:{type:String,default:null},raised:{type:Boolean,default:!1},rounded:{type:Boolean,default:!1},text:{type:Boolean,default:!1},outlined:{type:Boolean,default:!1},size:{type:String,default:null},plain:{type:Boolean,default:!1}},style:BS,provide:function(){return{$parentInstance:this}}},Fo={name:"Button",extends:US,methods:{getPTOptions:function(t){var n,r;return this.ptm(t,{parent:{props:(n=this.$parent)===null||n===void 0?void 0:n.$props,state:(r=this.$parent)===null||r===void 0?void 0:r.$data},context:{disabled:this.disabled}})}},computed:{disabled:function(){return this.$attrs.disabled||this.$attrs.disabled===""||this.loading},defaultAriaLabel:function(){return this.label?this.label+(this.badge?" "+this.badge:""):this.$attrs["aria-label"]},hasIcon:function(){return this.icon||this.$slots.icon}},components:{SpinnerIcon:Di,Badge:T1},directives:{ripple:Xn}},KS=["aria-label","disabled","data-pc-severity"];function WS(e,t,n,r,i,o){var s=dt("SpinnerIcon"),l=dt("Badge"),a=Cn("ripple");return Ot((E(),j("button",$({class:e.cx("root"),type:"button","aria-label":o.defaultAriaLabel,disabled:o.disabled},o.getPTOptions("root"),{"data-pc-name":"button","data-pc-severity":e.severity}),[le(e.$slots,"default",{},function(){return[e.loading?le(e.$slots,"loadingicon",{key:0,class:Pe([e.cx("loadingIcon"),e.cx("icon")])},function(){return[e.loadingIcon?(E(),j("span",$({key:0,class:[e.cx("loadingIcon"),e.cx("icon"),e.loadingIcon]},e.ptm("loadingIcon")),null,16)):(E(),Ee(s,$({key:1,class:[e.cx("loadingIcon"),e.cx("icon")],spin:""},e.ptm("loadingIcon")),null,16,["class"]))]}):le(e.$slots,"icon",{key:1,class:Pe([e.cx("icon")])},function(){return[e.icon?(E(),j("span",$({key:0,class:[e.cx("icon"),e.icon,e.iconClass]},e.ptm("icon")),null,16)):ye("",!0)]}),C("span",$({class:e.cx("label")},e.ptm("label")),Y(e.label||" "),17),e.badge?(E(),Ee(l,$({key:2,value:e.badge,class:e.badgeClass,severity:e.badgeSeverity,unstyled:e.unstyled},e.ptm("badge")),null,16,["value","class","severity","unstyled"])):ye("",!0)]})],16,KS)),[[a]])}Fo.render=WS;const GS={class:"flex flex-wrap md:grid md:grid-cols-3 md:space-x-0 md:gap-2 lg:flex lg:space-x-5 lg:flex-nowrap items-start text-sm text-slate-700"},YS={class:"flex flex-col"},ZS={class:"font-medium"},qS={key:0},XS={key:1},QS={key:0,class:"flex flex-col py-1 space-y-1 overflow-y-scroll max-w-[80vw] sm:max-w-[90vw] max-h-[300px]"},JS={key:1,class:"py-1 px-2"},eO={class:"flex space-x-2 p-4"},tO={class:"border-b-2 border-gray-300"},nO=rt({__name:"TimelineItemMetadata",props:{gtMetadata:{}},setup(e){const{t}=xt(),n=e,r=ue(),i=ue(),o={label:t("volume"),data:Array.isArray(n.gtMetadata.volume)?n.gtMetadata.volume.reduce((c,u)=>({...c,[u.metric]:u.count}),{}):n.gtMetadata.volume},s=[{label:t("language",n.gtMetadata.language.length),data:n.gtMetadata.language,isArray:!0},{label:t("script",n.gtMetadata.script.length),data:n.gtMetadata.script,isArray:!0},{label:t("script-type"),data:n.gtMetadata["script-type"]}];function l(c){var u;(u=r.value)==null||u.toggle(c)}function a(c){var u;(u=i.value)==null||u.toggle(c)}return(c,u)=>(E(),j(se,null,[C("div",GS,[(E(),j(se,null,He(s,f=>{var d;return C("div",{key:f.label,class:"mr-5 mb-5 md:mr-0 md:mb-0"},[C("div",YS,[C("span",ZS,Y(f.label)+":",1),f.isArray?(E(),j("span",qS,Y((d=f.data)==null?void 0:d.join(", ")),1)):(E(),j("span",XS,Y(f.data),1))])])}),64)),te(ne(Fo),{onClick:l,unstyled:"",pt:{root:"text-sm mr-5 md:mr-0 flex items-center bg-gray-100 text-slate-700 p-2 hover:bg-gray-200 rounded hover:text-black focus:outline-none"}},{default:ke(()=>{var f;return[C("span",null,Y(c.$t("labelling")),1),(f=r.value)!=null&&f.visible?(E(),Ee(ne(Nn),{key:0,icon:"ic:baseline-close-fullscreen",class:"ml-2"})):(E(),Ee(ne(Nn),{key:1,icon:"ic:baseline-open-in-full",class:"ml-2"}))]}),_:1}),te(ne(Fo),{onClick:a,unstyled:"",pt:{root:"text-sm flex items-center bg-gray-100 text-slate-700 p-2 hover:bg-gray-200 rounded hover:text-black focus:outline-none"}},{default:ke(()=>{var f;return[C("span",null,Y(c.$t("volume")),1),(f=i.value)!=null&&f.visible?(E(),Ee(ne(Nn),{key:0,icon:"ic:baseline-close-fullscreen",class:"ml-2"})):(E(),Ee(ne(Nn),{key:1,icon:"ic:baseline-open-in-full",class:"ml-2"}))]}),_:1})]),te(ne(Wn),{ref_key:"opLabelling",ref:r,unstyled:"",pt:ne(Zl)},{container:ke(()=>{var f;return[((f=c.gtMetadata.labelling)==null?void 0:f.length)>0?(E(),j("div",QS,[(E(!0),j(se,null,He(c.gtMetadata.labelling.slice(0).sort(),d=>(E(),j("span",{key:d,class:"hover:bg-gray-200 rounded px-2 text-sm"},Y(d),1))),128))])):(E(),j("div",JS,[C("span",null,Y(c.$t("no_labels_for_this_entry")),1)]))]}),_:1},8,["pt"]),te(ne(Wn),{ref_key:"opVolume",ref:i,unstyled:"",pt:ne(Zl)},{container:ke(()=>[C("div",eO,[(E(!0),j(se,null,He(o.data,(f,d)=>(E(),j("div",{key:d},[C("div",tO,Y(d),1),C("div",null,Y(f),1)]))),128))])]),_:1},8,["pt"])],64))}});const rO=pn(nO,[["__scopeId","data-v-de34c596"]]),iO=e=>(ua("data-v-301e1b75"),e=e(),fa(),e),oO={class:"flex flex-col px-4 pb-2"},sO={class:"flex items-center overflow-hidden"},lO=["title"],aO=["href"],cO={class:"text-xs"},uO=["href"],fO={class:"text-xs"},dO={class:"flex mt-6 md:flex-row flex-col"},pO={class:"md:w-1/2 mb-5 md:mb-0"},hO={class:"md:w-1/2 flex flex-col overflow-x-auto md:items-end"},mO={class:"font-bold pr-[240px] mb-2"},gO={class:"flex border-t border-gray-300 py-4 px-4"},yO={class:"table-fixed w-full"},vO={class:""},bO={class:"text-left pb-4"},xO={class:"text-left pb-4"},wO={class:"text-right pr-[314px] pb-4"},_O={class:"font-semibold pe-2"},SO={class:"p-1 overflow-x-auto"},OO=["onClick"],IO={class:"overflow-x-auto"},CO={class:"flex flex-col pt-2"},TO={class:"font-bold px-2 pb-2 mb-2 border-b border-gray-300"},EO={class:"overflow-y-scroll max-h-[400px] w-full"},kO={key:0,class:"text-sm border-collapse"},MO=iO(()=>C("tr",{class:""},[C("th",{class:"p-1 pl-2 font-semibold"},"Parameter"),C("th",{class:"p-1 pr-2 font-semibold"},"Value")],-1)),AO={class:"p-1 pl-2 border-collapse border border-l-0 border-b-0 border-gray-300"},jO={class:"p-1 pr-2 border-collapse border border-r-0 border-b-0 border-gray-300"},PO=rt({__name:"TimelineItem",props:{gt:{},metric:{}},setup(e){const t=ue(),n=ue(!1),r=ue(null),i=ue(new Date("2023-10-01")),o=ue(new Date),s=me(()=>Ie.workflows.filter(({id:f})=>kt.workflow.findIndex(({value:d})=>d===f)>-1));function l(f){return Yw[f]}function a(f,d){var p;r.value=f,(p=t.value)==null||p.show(d)}function c(){var f;(f=t.value)==null||f.hide()}function u(f,d){n.value?(c(),r.value!==f&&Ko(()=>{a(f,d)})):a(f,d)}return(f,d)=>(E(),j(se,null,[te(ne(uh),{header:"Header",toggleable:"",collapsed:!0,unstyled:"",pt:{root:"border border-gray-300 rounded-lg overflow-hidden",header:"pt-4",content:"",icons:"w-full flex",toggler:"w-full flex justify-center bg-gray-50 text-gray-500 p-2 hover:bg-gray-100 rounded hover:text-gray-700 focus:outline-none"}},{header:ke(()=>[C("div",oO,[C("div",sO,[C("h2",{class:"text-xl font-bold truncate mr-8",title:f.gt.label},Y(f.gt.label),9,lO),C("a",{href:f.gt.metadata.url,class:"text-gray-500 hover:text-gray-600 flex-shrink-0 ml-auto mr-2 flex items-center bg-gray-100 rounded-full py-1 px-2"},[te(ne(Nn),{icon:"mdi:github",class:"text-xl mr-1"}),C("span",cO,Y(f.gt.metadata.title),1)],8,aO),C("a",{href:f.gt.metadata.license[0].url,class:"text-gray-500 hover:text-gray-600 flex-shrink-0 flex items-center bg-gray-100 rounded-full py-1 px-2"},[te(ne(Nn),{icon:"octicon:law",class:"text-xl mr-1"}),C("span",fO,Y(f.gt.metadata.license[0].name),1)],8,uO)]),C("div",dO,[C("div",pO,[te(rO,{gtMetadata:f.gt.metadata},null,8,["gtMetadata"])]),C("div",hO,[C("h3",mO,Y(f.$t("average_timeline")),1),te(L8,{"workflow-name":f.$t("average"),"gt-name":f.gt.label,runs:ne(Ie).getRuns(f.gt.id),metric:f.metric,class:"",width:400,"start-date":i.value,"end-date":o.value},null,8,["workflow-name","gt-name","runs","metric","start-date","end-date"])])])])]),default:ke(()=>[C("div",gO,[C("table",yO,[C("thead",null,[C("tr",vO,[C("th",bO,Y(f.$t("workflows")),1),C("th",xO,Y(f.$t("processors")),1),C("th",wO,Y(f.$t("timeline")),1)])]),C("tbody",null,[(E(!0),j(se,null,He(s.value,p=>(E(),j("tr",{key:p.id},[C("td",_O,Y(p.label),1),C("td",SO,[(E(!0),j(se,null,He(p.steps,h=>(E(),j("span",{key:h.id,class:"p-1 cursor-pointer text-highlight",onClick:m=>u(h,m)},Y(l(h.id)),9,OO))),128))]),C("td",IO,[te(P8,{runs:ne(Ie).getRuns(f.gt.id,p.id),"gt-name":f.gt.label,"workflow-name":p.label,metric:f.metric,width:400,"start-date":i.value,"end-date":o.value,class:"flex justify-end"},null,8,["runs","gt-name","workflow-name","metric","start-date","end-date"])])]))),128))])])])]),togglericon:ke(({collapsed:p})=>[te(ne(Nn),{icon:p?"bi:chevron-down":"bi:chevron-up"},null,8,["icon"])]),_:1}),te(ne(Wn),{ref_key:"op",ref:t,pt:ne(Zl),onShow:d[0]||(d[0]=p=>n.value=!0),onHide:d[1]||(d[1]=p=>n.value=!1)},{default:ke(()=>{var p;return[C("div",CO,[C("h2",TO,Y((p=r.value)==null?void 0:p.id),1),C("div",EO,[r.value?(E(),j("table",kO,[MO,(E(!0),j(se,null,He(Object.keys(r.value.params),h=>(E(),j("tr",{key:h},[C("td",AO,Y(h),1),C("td",jO,Y(r.value.params[h]),1)]))),128))])):ye("",!0)])])]}),_:1},8,["pt"])],64))}});const LO=pn(PO,[["__scopeId","data-v-301e1b75"]]),$O={class:"flex flex-wrap mb-4 justify-start lg:justify-end"},FO=rt({__name:"TimelineFilters",setup(e){const{t}=xt(),n=me(()=>{const x=Ie.gt.reduce((S,O)=>(S.add(`${O.metadata.time.notBefore}-${O.metadata.time.notAfter}`),S),new Set);return Array.from(x).sort().map(S=>({value:S,label:S}))}),r=ue([]),i=me(()=>Ie.workflows.map(({id:x,label:S})=>({value:x,label:S}))),o=ue([]),s=ue([]),l=ue([]),a=me(()=>n.value.length===r.value.length?t("filter_by_date_range"):null),c=me(()=>i.value.length===o.value.length?t("filter_by_workflow"):null),u=me(()=>s.value.length===l.value.length?t("filter_by_processor"):null),f=x=>{r.value=x,h()},d=x=>{o.value=x,h(),m()},p=x=>{l.value=x,h(),m()},h=()=>{kt.gtTimeline=kt.gt.filter(({value:x})=>{const S=Ie.getGtById(x);return S?v(S)&&y(S)&&b(S):!1})},m=()=>{kt.workflow=o.value.filter(({value:x})=>_(x))},v=x=>{const S=Ie.getRuns(x.id);return l.value.some(O=>S.some(P=>P.metadata.workflow_steps.findIndex(({id:R})=>R===O.value)>-1))},y=x=>r.value.some(({value:S})=>{const O=S.split("-"),P=O[0],R=O[1];return x.metadata.time.notBefore===P&&x.metadata.time.notAfter===R}),b=x=>Ie.getRuns(x.id).some(O=>o.value.findIndex(({value:P})=>P===Yt(O.metadata.ocr_workflow.id))),_=x=>{const S=Ie.getWorkflowById(x);return S==null?!1:S.steps.some(O=>l.value.findIndex(({value:P})=>P===O.id)>-1)};return mt(()=>{s.value=Gv(Ie.workflows).map(x=>({value:x,label:t(x)})),r.value=n.value,o.value=i.value,l.value=s.value,h(),m()}),(x,S)=>(E(),j("div",$O,[te(ne(ii),{modelValue:r.value,"onUpdate:modelValue":[S[0]||(S[0]=O=>r.value=O),S[1]||(S[1]=O=>f(O))],"max-selected-labels":1,options:n.value,optionLabel:"label",placeholder:ne(t)("select_a_date_range"),"selected-items-label":a.value,class:"mr-4 mb-2 lg:m-0 lg:ml-auto md:w-14rem"},null,8,["modelValue","options","placeholder","selected-items-label"]),te(ne(ii),{modelValue:o.value,"onUpdate:modelValue":[S[2]||(S[2]=O=>o.value=O),S[3]||(S[3]=O=>d(O))],"max-selected-labels":1,options:i.value,optionLabel:"label",placeholder:ne(t)("select_a_workflow"),"selected-items-label":c.value,class:"mr-4 mb-2 lg:m-0 lg:ml-4 md:w-14rem"},null,8,["modelValue","options","placeholder","selected-items-label"]),te(ne(ii),{modelValue:l.value,"onUpdate:modelValue":[S[4]||(S[4]=O=>l.value=O),S[5]||(S[5]=O=>p(O))],filter:"","max-selected-labels":1,options:s.value,optionLabel:"label",placeholder:ne(t)("select_a_processor"),"selected-items-label":u.value,class:"lg:ml-4 md:w-14rem"},null,8,["modelValue","options","placeholder","selected-items-label"])]))}}),DO={class:"flex flex-col"},zO={class:"flex w-full mb-4"},RO={class:"flex flex-col space-y-6"},NO={key:1,class:"my-6"},VO={key:2,class:"my-6"},HO=rt({__name:"WorkflowsTimeline",setup(e){const{t}=xt(),n=me(()=>Ie.gt.filter(({id:l})=>kt.gtTimeline.findIndex(({value:a})=>a===l)>-1)),r=ue([]),i=ue(null),o=me(()=>Object.keys(Ye).map(l=>({value:Ye[l],label:t(Ye[l])}))),s=me(()=>{var l;return((l=i.value)==null?void 0:l.value)||Ye.CER_MEAN});return mt(async()=>{i.value=o.value[0],r.value=Ie.workflows}),Xe(i,()=>rc.setMaxValue(s.value,j8(s.value,Ie.runs)),{immediate:!0}),(l,a)=>(E(),j("div",DO,[C("div",zO,[te(ne(Fa),{modelValue:i.value,"onUpdate:modelValue":a[0]||(a[0]=c=>i.value=c),options:o.value,pt:ne(LS),optionLabel:"label",placeholder:"Select a metric",class:"ml-auto md:w-14rem",unstyled:""},null,8,["modelValue","options","pt"])]),te(th,{class:"ml-auto mb-4"}),te(FO),C("div",RO,[n.value.length>0?(E(!0),j(se,{key:0},He(n.value,c=>(E(),Ee(LO,{key:c.id,gt:c,metric:s.value},null,8,["gt","metric"]))),128)):ne(Ie).gt.length>0?(E(),j("div",NO,Y(l.$t("no_documents_selected")),1)):(E(),j("div",VO,Y(l.$t("error_please_try_again_later")),1))])]))}}),BO={class:"text-base font-light"},UO={key:0},KO=C("br",null,null,-1),WO=["href"],GO=["href"],YO=rt({__name:"WorkflowsIntroSection",props:{page:{}},setup(e){const{t}=xt();return(n,r)=>{const i=dt("i18n-t");return E(),j("div",BO,[C("p",null,Y(ne(t)("workflows_intro_text")),1),n.page==="timeline"?(E(),j("p",UO,Y(ne(t)("workflows_intro_additional_text_timeline")),1)):ye("",!0),KO,te(i,{keypath:"workflows_intro_additional_infos",tag:"p",scope:"global"},{ocrd_link:ke(()=>[C("a",{href:ne(t)("ocrd_link"),class:"underline hover:text-primary"},Y(ne(t)("ocrd_link")),9,WO)]),_:1}),te(i,{keypath:"workflows_intro_gt_guidelines",tag:"p",scope:"global"},{gt_guidelines_link:ke(()=>[C("a",{href:ne(t)("gt_guidelines_link"),class:"underline hover:text-primary"},Y(ne(t)("gt_guidelines_link")),9,GO)]),_:1})])}}}),ZO=C("div",{class:"flex mb-6"},[C("p",{class:"text-amber-600 flex-grow-0 px-4 py-2 bg-amber-100 rounded-md text-sm"},[C("span",{class:"font-semibold"},"Disclaimer:"),et(" This is an experimental view.")])],-1),qO={class:"flex mb-6"},XO={key:0,class:"mb-12"},QO=rt({__name:"Workflows",setup(e){const{t}=xt(),n=ue([]),r=ue([]),i=Cp(),o=Tp(),s=ue(!1),l=ue([{name:t("timeline"),value:"timeline"},{name:t("table"),value:"table"}]),a=ue(l.value[0]);return Xe(()=>kt.gt,()=>{r.value=n.value.filter(({metadata:c})=>kt.gt.findIndex(({value:u})=>u===Yt(c.gt_workspace.id))>-1)}),Xe(a,({value:c})=>{i.push({query:{view:c}})}),mt(async()=>{await i.isReady(),s.value=!0;const c=l.value.find(f=>o.query.view&&o.query.view===f.value);c&&(a.value=c),Ie.runs=await gr.getRuns(),Ie.gt=await gr.getGroundTruth(),Ie.workflows=await gr.getWorkflows(),Ie.runs.forEach(f=>{const d=Yt(f.metadata.gt_workspace.id);Ie.gt.find(p=>p.id===d)||console.log(d)});const u=Ie.runs.reduce((f,d)=>(f[d.metadata.release_info.tag_name]=d.metadata.release_info,f),{});Ie.releases=Object.keys(u).map(f=>u[f]),Wv(Ie.runs),s.value=!1}),(c,u)=>s.value?(E(),j(se,{key:0},[et(" Loading... ")],64)):(E(),j(se,{key:1},[ZO,te(YO,{page:a.value.value,class:"mb-6"},null,8,["page"]),C("div",qO,[te(ne(lh),{modelValue:a.value,"onUpdate:modelValue":u[0]||(u[0]=f=>a.value=f),options:l.value,optionLabel:"name"},null,8,["modelValue","options"]),te(nw,{class:"ml-auto"})]),a.value?(E(),j("div",XO,[a.value.value==="timeline"?(E(),Ee(HO,{key:0})):(E(),Ee(px,{key:1}))])):ye("",!0)],64))}}),ql=un({repos:[],releases:[],evaluations:[],metricDefinitions:{},gtList:[],workflows:[],setGTList(e){this.gtList=e},setWorkflows(e){this.workflows=e},setRepos(e){this.repos=e},setReleases(e){this.releases=e},setEvaluations(e){this.evaluations=e},setMetricDefinitions(e){this.metricDefinitions=e},getRepoById(e){return this.repos.find(t=>t.id===e)}});var E1={exports:{}};(function(e,t){(function(r,i){e.exports=i()})(typeof self<"u"?self:I8,function(){return function(n){var r={};function i(o){if(r[o])return r[o].exports;var s=r[o]={i:o,l:!1,exports:{}};return n[o].call(s.exports,s,s.exports,i),s.l=!0,s.exports}return i.m=n,i.c=r,i.d=function(o,s,l){i.o(o,s)||Object.defineProperty(o,s,{configurable:!1,enumerable:!0,get:l})},i.r=function(o){Object.defineProperty(o,"__esModule",{value:!0})},i.n=function(o){var s=o&&o.__esModule?function(){return o.default}:function(){return o};return i.d(s,"a",s),s},i.o=function(o,s){return Object.prototype.hasOwnProperty.call(o,s)},i.p="",i(i.s=0)}({"./dist/icons.json":function(n){n.exports={activity:'',airplay:'',"alert-circle":'',"alert-octagon":'',"alert-triangle":'',"align-center":'',"align-justify":'',"align-left":'',"align-right":'',anchor:'',aperture:'',archive:'',"arrow-down-circle":'',"arrow-down-left":'',"arrow-down-right":'',"arrow-down":'',"arrow-left-circle":'',"arrow-left":'',"arrow-right-circle":'',"arrow-right":'',"arrow-up-circle":'',"arrow-up-left":'',"arrow-up-right":'',"arrow-up":'',"at-sign":'',award:'',"bar-chart-2":'',"bar-chart":'',"battery-charging":'',battery:'',"bell-off":'',bell:'',bluetooth:'',bold:'',"book-open":'',book:'',bookmark:'',box:'',briefcase:'',calendar:'',"camera-off":'',camera:'',cast:'',"check-circle":'',"check-square":'',check:'',"chevron-down":'',"chevron-left":'',"chevron-right":'',"chevron-up":'',"chevrons-down":'',"chevrons-left":'',"chevrons-right":'',"chevrons-up":'',chrome:'',circle:'',clipboard:'',clock:'',"cloud-drizzle":'',"cloud-lightning":'',"cloud-off":'',"cloud-rain":'',"cloud-snow":'',cloud:'',code:'',codepen:'',codesandbox:'',coffee:'',columns:'',command:'',compass:'',copy:'',"corner-down-left":'',"corner-down-right":'',"corner-left-down":'',"corner-left-up":'',"corner-right-down":'',"corner-right-up":'',"corner-up-left":'',"corner-up-right":'',cpu:'',"credit-card":'',crop:'',crosshair:'',database:'',delete:'',disc:'',"divide-circle":'',"divide-square":'',divide:'',"dollar-sign":'',"download-cloud":'',download:'',dribbble:'',droplet:'',"edit-2":'',"edit-3":'',edit:'',"external-link":'',"eye-off":'',eye:'',facebook:'',"fast-forward":'',feather:'',figma:'',"file-minus":'',"file-plus":'',"file-text":'',file:'',film:'',filter:'',flag:'',"folder-minus":'',"folder-plus":'',folder:'',framer:'',frown:'',gift:'',"git-branch":'',"git-commit":'',"git-merge":'',"git-pull-request":'',github:'',gitlab:'',globe:'',grid:'',"hard-drive":'',hash:'',headphones:'',heart:'',"help-circle":'',hexagon:'',home:'',image:'',inbox:'',info:'',instagram:'',italic:'',key:'',layers:'',layout:'',"life-buoy":'',"link-2":'',link:'',linkedin:'',list:'',loader:'',lock:'',"log-in":'',"log-out":'',mail:'',"map-pin":'',map:'',"maximize-2":'',maximize:'',meh:'',menu:'',"message-circle":'',"message-square":'',"mic-off":'',mic:'',"minimize-2":'',minimize:'',"minus-circle":'',"minus-square":'',minus:'',monitor:'',moon:'',"more-horizontal":'',"more-vertical":'',"mouse-pointer":'',move:'',music:'',"navigation-2":'',navigation:'',octagon:'',package:'',paperclip:'',"pause-circle":'',pause:'',"pen-tool":'',percent:'',"phone-call":'',"phone-forwarded":'',"phone-incoming":'',"phone-missed":'',"phone-off":'',"phone-outgoing":'',phone:'',"pie-chart":'',"play-circle":'',play:'',"plus-circle":'',"plus-square":'',plus:'',pocket:'',power:'',printer:'',radio:'',"refresh-ccw":'',"refresh-cw":'',repeat:'',rewind:'',"rotate-ccw":'',"rotate-cw":'',rss:'',save:'',scissors:'',search:'',send:'',server:'',settings:'',"share-2":'',share:'',"shield-off":'',shield:'',"shopping-bag":'',"shopping-cart":'',shuffle:'',sidebar:'',"skip-back":'',"skip-forward":'',slack:'',slash:'',sliders:'',smartphone:'',smile:'',speaker:'',square:'',star:'',"stop-circle":'',sun:'',sunrise:'',sunset:'',table:'',tablet:'',tag:'',target:'',terminal:'',thermometer:'',"thumbs-down":'',"thumbs-up":'',"toggle-left":'',"toggle-right":'',tool:'',"trash-2":'',trash:'',trello:'',"trending-down":'',"trending-up":'',triangle:'',truck:'',tv:'',twitch:'',twitter:'',type:'',umbrella:'',underline:'',unlock:'',"upload-cloud":'',upload:'',"user-check":'',"user-minus":'',"user-plus":'',"user-x":'',user:'',users:'',"video-off":'',video:'',voicemail:'',"volume-1":'',"volume-2":'',"volume-x":'',volume:'',watch:'',"wifi-off":'',wifi:'',wind:'',"x-circle":'',"x-octagon":'',"x-square":'',x:'',youtube:'',"zap-off":'',zap:'',"zoom-in":'',"zoom-out":''}},"./node_modules/classnames/dedupe.js":function(n,r,i){var o,s;/*! +`,FS={root:function(t){var n=t.props,r=t.instance;return["p-badge p-component",{"p-badge-no-gutter":U.isNotEmpty(n.value)&&String(n.value).length===1,"p-badge-dot":U.isEmpty(n.value)&&!r.$slots.default,"p-badge-lg":n.size==="large","p-badge-xl":n.size==="xlarge","p-badge-info":n.severity==="info","p-badge-success":n.severity==="success","p-badge-warning":n.severity==="warning","p-badge-danger":n.severity==="danger"}]}},DS=gt.extend({name:"badge",css:$S,classes:FS}),zS={name:"BaseBadge",extends:Xt,props:{value:{type:[String,Number],default:null},severity:{type:String,default:null},size:{type:String,default:null}},style:DS,provide:function(){return{$parentInstance:this}}},T1={name:"Badge",extends:zS};function RS(e,t,n,r,i,o){return E(),j("span",$({class:e.cx("root")},e.ptm("root"),{"data-pc-name":"badge"}),[le(e.$slots,"default",{},function(){return[et(Y(e.value),1)]})],16)}T1.render=RS;function Pi(e){"@babel/helpers - typeof";return Pi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Pi(e)}function bn(e,t,n){return t=NS(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function NS(e){var t=VS(e,"string");return Pi(t)==="symbol"?t:String(t)}function VS(e,t){if(Pi(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Pi(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var HS={root:function(t){var n=t.instance,r=t.props;return["p-button p-component",bn(bn(bn(bn(bn(bn(bn(bn({"p-button-icon-only":n.hasIcon&&!r.label&&!r.badge,"p-button-vertical":(r.iconPos==="top"||r.iconPos==="bottom")&&r.label,"p-disabled":n.$attrs.disabled||n.$attrs.disabled===""||r.loading,"p-button-loading":r.loading,"p-button-loading-label-only":r.loading&&!n.hasIcon&&r.label,"p-button-link":r.link},"p-button-".concat(r.severity),r.severity),"p-button-raised",r.raised),"p-button-rounded",r.rounded),"p-button-text",r.text),"p-button-outlined",r.outlined),"p-button-sm",r.size==="small"),"p-button-lg",r.size==="large"),"p-button-plain",r.plain)]},loadingIcon:"p-button-loading-icon pi-spin",icon:function(t){var n=t.props;return["p-button-icon",{"p-button-icon-left":n.iconPos==="left"&&n.label,"p-button-icon-right":n.iconPos==="right"&&n.label,"p-button-icon-top":n.iconPos==="top"&&n.label,"p-button-icon-bottom":n.iconPos==="bottom"&&n.label}]},label:"p-button-label"},BS=gt.extend({name:"button",classes:HS}),US={name:"BaseButton",extends:Xt,props:{label:{type:String,default:null},icon:{type:String,default:null},iconPos:{type:String,default:"left"},iconClass:{type:String,default:null},badge:{type:String,default:null},badgeClass:{type:String,default:null},badgeSeverity:{type:String,default:null},loading:{type:Boolean,default:!1},loadingIcon:{type:String,default:void 0},link:{type:Boolean,default:!1},severity:{type:String,default:null},raised:{type:Boolean,default:!1},rounded:{type:Boolean,default:!1},text:{type:Boolean,default:!1},outlined:{type:Boolean,default:!1},size:{type:String,default:null},plain:{type:Boolean,default:!1}},style:BS,provide:function(){return{$parentInstance:this}}},Fo={name:"Button",extends:US,methods:{getPTOptions:function(t){var n,r;return this.ptm(t,{parent:{props:(n=this.$parent)===null||n===void 0?void 0:n.$props,state:(r=this.$parent)===null||r===void 0?void 0:r.$data},context:{disabled:this.disabled}})}},computed:{disabled:function(){return this.$attrs.disabled||this.$attrs.disabled===""||this.loading},defaultAriaLabel:function(){return this.label?this.label+(this.badge?" "+this.badge:""):this.$attrs["aria-label"]},hasIcon:function(){return this.icon||this.$slots.icon}},components:{SpinnerIcon:Di,Badge:T1},directives:{ripple:Xn}},KS=["aria-label","disabled","data-pc-severity"];function WS(e,t,n,r,i,o){var s=dt("SpinnerIcon"),l=dt("Badge"),a=Cn("ripple");return Ot((E(),j("button",$({class:e.cx("root"),type:"button","aria-label":o.defaultAriaLabel,disabled:o.disabled},o.getPTOptions("root"),{"data-pc-name":"button","data-pc-severity":e.severity}),[le(e.$slots,"default",{},function(){return[e.loading?le(e.$slots,"loadingicon",{key:0,class:Pe([e.cx("loadingIcon"),e.cx("icon")])},function(){return[e.loadingIcon?(E(),j("span",$({key:0,class:[e.cx("loadingIcon"),e.cx("icon"),e.loadingIcon]},e.ptm("loadingIcon")),null,16)):(E(),Ee(s,$({key:1,class:[e.cx("loadingIcon"),e.cx("icon")],spin:""},e.ptm("loadingIcon")),null,16,["class"]))]}):le(e.$slots,"icon",{key:1,class:Pe([e.cx("icon")])},function(){return[e.icon?(E(),j("span",$({key:0,class:[e.cx("icon"),e.icon,e.iconClass]},e.ptm("icon")),null,16)):ye("",!0)]}),C("span",$({class:e.cx("label")},e.ptm("label")),Y(e.label||" "),17),e.badge?(E(),Ee(l,$({key:2,value:e.badge,class:e.badgeClass,severity:e.badgeSeverity,unstyled:e.unstyled},e.ptm("badge")),null,16,["value","class","severity","unstyled"])):ye("",!0)]})],16,KS)),[[a]])}Fo.render=WS;const GS={class:"flex flex-wrap md:grid md:grid-cols-3 md:space-x-0 md:gap-2 lg:flex lg:space-x-5 lg:flex-nowrap items-start text-sm text-slate-700"},YS={class:"flex flex-col"},ZS={class:"font-medium"},qS={key:0},XS={key:1},QS={key:0,class:"flex flex-col py-1 space-y-1 overflow-y-scroll max-w-[80vw] sm:max-w-[90vw] max-h-[300px]"},JS={key:1,class:"py-1 px-2"},eO={class:"flex space-x-2 p-4"},tO={class:"border-b-2 border-gray-300"},nO=rt({__name:"TimelineItemMetadata",props:{gtMetadata:{}},setup(e){const{t}=xt(),n=e,r=ue(),i=ue(),o={label:t("volume"),data:Array.isArray(n.gtMetadata.volume)?n.gtMetadata.volume.reduce((c,u)=>({...c,[u.metric]:u.count}),{}):n.gtMetadata.volume},s=[{label:t("language",n.gtMetadata.language.length),data:n.gtMetadata.language,isArray:!0},{label:t("script",n.gtMetadata.script.length),data:n.gtMetadata.script,isArray:!0},{label:t("script-type"),data:n.gtMetadata["script-type"]}];function l(c){var u;(u=r.value)==null||u.toggle(c)}function a(c){var u;(u=i.value)==null||u.toggle(c)}return(c,u)=>(E(),j(se,null,[C("div",GS,[(E(),j(se,null,He(s,f=>{var d;return C("div",{key:f.label,class:"mr-5 mb-5 md:mr-0 md:mb-0"},[C("div",YS,[C("span",ZS,Y(f.label)+":",1),f.isArray?(E(),j("span",qS,Y((d=f.data)==null?void 0:d.join(", ")),1)):(E(),j("span",XS,Y(f.data),1))])])}),64)),te(ne(Fo),{onClick:l,unstyled:"",pt:{root:"text-sm mr-5 md:mr-0 flex items-center bg-gray-100 text-slate-700 p-2 hover:bg-gray-200 rounded hover:text-black focus:outline-none"}},{default:ke(()=>{var f;return[C("span",null,Y(c.$t("labelling")),1),(f=r.value)!=null&&f.visible?(E(),Ee(ne(Nn),{key:0,icon:"ic:baseline-close-fullscreen",class:"ml-2"})):(E(),Ee(ne(Nn),{key:1,icon:"ic:baseline-open-in-full",class:"ml-2"}))]}),_:1}),te(ne(Fo),{onClick:a,unstyled:"",pt:{root:"text-sm flex items-center bg-gray-100 text-slate-700 p-2 hover:bg-gray-200 rounded hover:text-black focus:outline-none"}},{default:ke(()=>{var f;return[C("span",null,Y(c.$t("volume")),1),(f=i.value)!=null&&f.visible?(E(),Ee(ne(Nn),{key:0,icon:"ic:baseline-close-fullscreen",class:"ml-2"})):(E(),Ee(ne(Nn),{key:1,icon:"ic:baseline-open-in-full",class:"ml-2"}))]}),_:1})]),te(ne(Wn),{ref_key:"opLabelling",ref:r,unstyled:"",pt:ne(Zl)},{container:ke(()=>{var f;return[((f=c.gtMetadata.labelling)==null?void 0:f.length)>0?(E(),j("div",QS,[(E(!0),j(se,null,He(c.gtMetadata.labelling.slice(0).sort(),d=>(E(),j("span",{key:d,class:"hover:bg-gray-200 rounded px-2 text-sm"},Y(d),1))),128))])):(E(),j("div",JS,[C("span",null,Y(c.$t("no_labels_for_this_entry")),1)]))]}),_:1},8,["pt"]),te(ne(Wn),{ref_key:"opVolume",ref:i,unstyled:"",pt:ne(Zl)},{container:ke(()=>[C("div",eO,[(E(!0),j(se,null,He(o.data,(f,d)=>(E(),j("div",{key:d},[C("div",tO,Y(d),1),C("div",null,Y(f),1)]))),128))])]),_:1},8,["pt"])],64))}});const rO=pn(nO,[["__scopeId","data-v-de34c596"]]),iO=e=>(ua("data-v-301e1b75"),e=e(),fa(),e),oO={class:"flex flex-col px-4 pb-2"},sO={class:"flex items-center overflow-hidden"},lO=["title"],aO=["href"],cO={class:"text-xs"},uO=["href"],fO={class:"text-xs"},dO={class:"flex mt-6 md:flex-row flex-col"},pO={class:"md:w-1/2 mb-5 md:mb-0"},hO={class:"md:w-1/2 flex flex-col overflow-x-auto md:items-end"},mO={class:"font-bold pr-[240px] mb-2"},gO={class:"flex border-t border-gray-300 py-4 px-4"},yO={class:"table-fixed w-full"},vO={class:""},bO={class:"text-left pb-4"},xO={class:"text-left pb-4"},wO={class:"text-right pr-[314px] pb-4"},_O={class:"font-semibold pe-2"},SO={class:"p-1 overflow-x-auto"},OO=["onClick"],IO={class:"overflow-x-auto"},CO={class:"flex flex-col pt-2"},TO={class:"font-bold px-2 pb-2 mb-2 border-b border-gray-300"},EO={class:"overflow-y-scroll max-h-[400px] w-full"},kO={key:0,class:"text-sm border-collapse"},MO=iO(()=>C("tr",{class:""},[C("th",{class:"p-1 pl-2 font-semibold"},"Parameter"),C("th",{class:"p-1 pr-2 font-semibold"},"Value")],-1)),AO={class:"p-1 pl-2 border-collapse border border-l-0 border-b-0 border-gray-300"},jO={class:"p-1 pr-2 border-collapse border border-r-0 border-b-0 border-gray-300"},PO=rt({__name:"TimelineItem",props:{gt:{},metric:{}},setup(e){const t=ue(),n=ue(!1),r=ue(null),i=ue(new Date("2023-10-01")),o=ue(new Date),s=me(()=>Ie.workflows.filter(({id:f})=>kt.workflow.findIndex(({value:d})=>d===f)>-1));function l(f){return Yw[f]}function a(f,d){var p;r.value=f,(p=t.value)==null||p.show(d)}function c(){var f;(f=t.value)==null||f.hide()}function u(f,d){n.value?(c(),r.value!==f&&Ko(()=>{a(f,d)})):a(f,d)}return(f,d)=>(E(),j(se,null,[te(ne(uh),{header:"Header",toggleable:"",collapsed:!0,unstyled:"",pt:{root:"border border-gray-300 rounded-lg overflow-hidden",header:"pt-4",content:"",icons:"w-full flex",toggler:"w-full flex justify-center bg-gray-50 text-gray-500 p-2 hover:bg-gray-100 rounded hover:text-gray-700 focus:outline-none"}},{header:ke(()=>[C("div",oO,[C("div",sO,[C("h2",{class:"text-xl font-bold truncate mr-8",title:f.gt.label},Y(f.gt.label),9,lO),C("a",{href:f.gt.metadata.url,class:"text-gray-500 hover:text-gray-600 flex-shrink-0 ml-auto mr-2 flex items-center bg-gray-100 rounded-full py-1 px-2"},[te(ne(Nn),{icon:"mdi:github",class:"text-xl mr-1"}),C("span",cO,Y(f.gt.metadata.title),1)],8,aO),C("a",{href:f.gt.metadata.license[0].url,class:"text-gray-500 hover:text-gray-600 flex-shrink-0 flex items-center bg-gray-100 rounded-full py-1 px-2"},[te(ne(Nn),{icon:"octicon:law",class:"text-xl mr-1"}),C("span",fO,Y(f.gt.metadata.license[0].name),1)],8,uO)]),C("div",dO,[C("div",pO,[te(rO,{gtMetadata:f.gt.metadata},null,8,["gtMetadata"])]),C("div",hO,[C("h3",mO,Y(f.$t("average_timeline")),1),te(L8,{"workflow-name":f.$t("average"),"gt-name":f.gt.label,runs:ne(Ie).getRuns(f.gt.id),metric:f.metric,class:"",width:400,"start-date":i.value,"end-date":o.value},null,8,["workflow-name","gt-name","runs","metric","start-date","end-date"])])])])]),default:ke(()=>[C("div",gO,[C("table",yO,[C("thead",null,[C("tr",vO,[C("th",bO,Y(f.$t("workflows")),1),C("th",xO,Y(f.$t("processors")),1),C("th",wO,Y(f.$t("timeline")),1)])]),C("tbody",null,[(E(!0),j(se,null,He(s.value,p=>(E(),j("tr",{key:p.id},[C("td",_O,Y(p.label),1),C("td",SO,[(E(!0),j(se,null,He(p.steps,h=>(E(),j("span",{key:h.id,class:"p-1 cursor-pointer text-highlight",onClick:m=>u(h,m)},Y(l(h.id)),9,OO))),128))]),C("td",IO,[te(P8,{runs:ne(Ie).getRuns(f.gt.id,p.id),"gt-name":f.gt.label,"workflow-name":p.label,metric:f.metric,width:400,"start-date":i.value,"end-date":o.value,class:"flex justify-end"},null,8,["runs","gt-name","workflow-name","metric","start-date","end-date"])])]))),128))])])])]),togglericon:ke(({collapsed:p})=>[te(ne(Nn),{icon:p?"bi:chevron-down":"bi:chevron-up"},null,8,["icon"])]),_:1}),te(ne(Wn),{ref_key:"op",ref:t,pt:ne(Zl),onShow:d[0]||(d[0]=p=>n.value=!0),onHide:d[1]||(d[1]=p=>n.value=!1)},{default:ke(()=>{var p;return[C("div",CO,[C("h2",TO,Y((p=r.value)==null?void 0:p.id),1),C("div",EO,[r.value?(E(),j("table",kO,[MO,(E(!0),j(se,null,He(Object.keys(r.value.params),h=>(E(),j("tr",{key:h},[C("td",AO,Y(h),1),C("td",jO,Y(r.value.params[h]),1)]))),128))])):ye("",!0)])])]}),_:1},8,["pt"])],64))}});const LO=pn(PO,[["__scopeId","data-v-301e1b75"]]),$O={class:"flex flex-wrap mb-4 justify-start lg:justify-end"},FO=rt({__name:"TimelineFilters",setup(e){const{t}=xt(),n=me(()=>{const x=Ie.gt.reduce((S,O)=>(S.add(`${O.metadata.time.notBefore}-${O.metadata.time.notAfter}`),S),new Set);return Array.from(x).sort().map(S=>({value:S,label:S}))}),r=ue([]),i=me(()=>Ie.workflows.map(({id:x,label:S})=>({value:x,label:S}))),o=ue([]),s=ue([]),l=ue([]),a=me(()=>n.value.length===r.value.length?t("filter_by_date_range"):null),c=me(()=>i.value.length===o.value.length?t("filter_by_workflow"):null),u=me(()=>s.value.length===l.value.length?t("filter_by_processor"):null),f=x=>{r.value=x,h()},d=x=>{o.value=x,h(),m()},p=x=>{l.value=x,h(),m()},h=()=>{kt.gtTimeline=kt.gt.filter(({value:x})=>{const S=Ie.getGtById(x);return S?v(S)&&y(S)&&b(S):!1})},m=()=>{kt.workflow=o.value.filter(({value:x})=>_(x))},v=x=>{const S=Ie.getRuns(x.id);return l.value.some(O=>S.some(P=>P.metadata.workflow_steps.findIndex(({id:R})=>R===O.value)>-1))},y=x=>r.value.some(({value:S})=>{const O=S.split("-"),P=O[0],R=O[1];return x.metadata.time.notBefore===P&&x.metadata.time.notAfter===R}),b=x=>Ie.getRuns(x.id).some(O=>o.value.findIndex(({value:P})=>P===Yt(O.metadata.ocr_workflow.id))>-1),_=x=>{const S=Ie.getWorkflowById(x);return S==null?!1:S.steps.some(O=>l.value.findIndex(({value:P})=>P===O.id)>-1)};return mt(()=>{s.value=Gv(Ie.workflows).map(x=>({value:x,label:t(x)})),r.value=n.value,o.value=i.value,l.value=s.value,h(),m()}),(x,S)=>(E(),j("div",$O,[te(ne(ii),{modelValue:r.value,"onUpdate:modelValue":[S[0]||(S[0]=O=>r.value=O),S[1]||(S[1]=O=>f(O))],"max-selected-labels":1,options:n.value,optionLabel:"label",placeholder:ne(t)("select_a_date_range"),"selected-items-label":a.value,class:"mr-4 mb-2 lg:m-0 lg:ml-auto md:w-14rem"},null,8,["modelValue","options","placeholder","selected-items-label"]),te(ne(ii),{modelValue:o.value,"onUpdate:modelValue":[S[2]||(S[2]=O=>o.value=O),S[3]||(S[3]=O=>d(O))],"max-selected-labels":1,options:i.value,optionLabel:"label",placeholder:ne(t)("select_a_workflow"),"selected-items-label":c.value,class:"mr-4 mb-2 lg:m-0 lg:ml-4 md:w-14rem"},null,8,["modelValue","options","placeholder","selected-items-label"]),te(ne(ii),{modelValue:l.value,"onUpdate:modelValue":[S[4]||(S[4]=O=>l.value=O),S[5]||(S[5]=O=>p(O))],filter:"","max-selected-labels":1,options:s.value,optionLabel:"label",placeholder:ne(t)("select_a_processor"),"selected-items-label":u.value,class:"lg:ml-4 md:w-14rem"},null,8,["modelValue","options","placeholder","selected-items-label"])]))}}),DO={class:"flex flex-col"},zO={class:"flex w-full mb-4"},RO={class:"flex flex-col space-y-6"},NO={key:1,class:"my-6"},VO={key:2,class:"my-6"},HO=rt({__name:"WorkflowsTimeline",setup(e){const{t}=xt(),n=me(()=>Ie.gt.filter(({id:l})=>kt.gtTimeline.findIndex(({value:a})=>a===l)>-1)),r=ue([]),i=ue(null),o=me(()=>Object.keys(Ye).map(l=>({value:Ye[l],label:t(Ye[l])}))),s=me(()=>{var l;return((l=i.value)==null?void 0:l.value)||Ye.CER_MEAN});return mt(async()=>{i.value=o.value[0],r.value=Ie.workflows}),Xe(i,()=>rc.setMaxValue(s.value,j8(s.value,Ie.runs)),{immediate:!0}),(l,a)=>(E(),j("div",DO,[C("div",zO,[te(ne(Fa),{modelValue:i.value,"onUpdate:modelValue":a[0]||(a[0]=c=>i.value=c),options:o.value,pt:ne(LS),optionLabel:"label",placeholder:"Select a metric",class:"ml-auto md:w-14rem",unstyled:""},null,8,["modelValue","options","pt"])]),te(th,{class:"ml-auto mb-4"}),te(FO),C("div",RO,[n.value.length>0?(E(!0),j(se,{key:0},He(n.value,c=>(E(),Ee(LO,{key:c.id,gt:c,metric:s.value},null,8,["gt","metric"]))),128)):ne(Ie).gt.length>0?(E(),j("div",NO,Y(l.$t("no_documents_selected")),1)):(E(),j("div",VO,Y(l.$t("error_please_try_again_later")),1))])]))}}),BO={class:"text-base font-light"},UO={key:0},KO=C("br",null,null,-1),WO=["href"],GO=["href"],YO=rt({__name:"WorkflowsIntroSection",props:{page:{}},setup(e){const{t}=xt();return(n,r)=>{const i=dt("i18n-t");return E(),j("div",BO,[C("p",null,Y(ne(t)("workflows_intro_text")),1),n.page==="timeline"?(E(),j("p",UO,Y(ne(t)("workflows_intro_additional_text_timeline")),1)):ye("",!0),KO,te(i,{keypath:"workflows_intro_additional_infos",tag:"p",scope:"global"},{ocrd_link:ke(()=>[C("a",{href:ne(t)("ocrd_link"),class:"underline hover:text-primary"},Y(ne(t)("ocrd_link")),9,WO)]),_:1}),te(i,{keypath:"workflows_intro_gt_guidelines",tag:"p",scope:"global"},{gt_guidelines_link:ke(()=>[C("a",{href:ne(t)("gt_guidelines_link"),class:"underline hover:text-primary"},Y(ne(t)("gt_guidelines_link")),9,GO)]),_:1})])}}}),ZO=C("div",{class:"flex mb-6"},[C("p",{class:"text-amber-600 flex-grow-0 px-4 py-2 bg-amber-100 rounded-md text-sm"},[C("span",{class:"font-semibold"},"Disclaimer:"),et(" This is an experimental view.")])],-1),qO={class:"flex mb-6"},XO={key:0,class:"mb-12"},QO=rt({__name:"Workflows",setup(e){const{t}=xt(),n=ue([]),r=ue([]),i=Cp(),o=Tp(),s=ue(!1),l=ue([{name:t("timeline"),value:"timeline"},{name:t("table"),value:"table"}]),a=ue(l.value[0]);return Xe(()=>kt.gt,()=>{r.value=n.value.filter(({metadata:c})=>kt.gt.findIndex(({value:u})=>u===Yt(c.gt_workspace.id))>-1)}),Xe(a,({value:c})=>{i.push({query:{view:c}})}),mt(async()=>{await i.isReady(),s.value=!0;const c=l.value.find(f=>o.query.view&&o.query.view===f.value);c&&(a.value=c),Ie.runs=await gr.getRuns(),Ie.gt=await gr.getGroundTruth(),Ie.workflows=await gr.getWorkflows(),Ie.runs.forEach(f=>{const d=Yt(f.metadata.gt_workspace.id);Ie.gt.find(p=>p.id===d)||console.log(d)});const u=Ie.runs.reduce((f,d)=>(f[d.metadata.release_info.tag_name]=d.metadata.release_info,f),{});Ie.releases=Object.keys(u).map(f=>u[f]),Wv(Ie.runs),s.value=!1}),(c,u)=>s.value?(E(),j(se,{key:0},[et(" Loading... ")],64)):(E(),j(se,{key:1},[ZO,te(YO,{page:a.value.value,class:"mb-6"},null,8,["page"]),C("div",qO,[te(ne(lh),{modelValue:a.value,"onUpdate:modelValue":u[0]||(u[0]=f=>a.value=f),options:l.value,optionLabel:"name"},null,8,["modelValue","options"]),te(nw,{class:"ml-auto"})]),a.value?(E(),j("div",XO,[a.value.value==="timeline"?(E(),Ee(HO,{key:0})):(E(),Ee(px,{key:1}))])):ye("",!0)],64))}}),ql=un({repos:[],releases:[],evaluations:[],metricDefinitions:{},gtList:[],workflows:[],setGTList(e){this.gtList=e},setWorkflows(e){this.workflows=e},setRepos(e){this.repos=e},setReleases(e){this.releases=e},setEvaluations(e){this.evaluations=e},setMetricDefinitions(e){this.metricDefinitions=e},getRepoById(e){return this.repos.find(t=>t.id===e)}});var E1={exports:{}};(function(e,t){(function(r,i){e.exports=i()})(typeof self<"u"?self:I8,function(){return function(n){var r={};function i(o){if(r[o])return r[o].exports;var s=r[o]={i:o,l:!1,exports:{}};return n[o].call(s.exports,s,s.exports,i),s.l=!0,s.exports}return i.m=n,i.c=r,i.d=function(o,s,l){i.o(o,s)||Object.defineProperty(o,s,{configurable:!1,enumerable:!0,get:l})},i.r=function(o){Object.defineProperty(o,"__esModule",{value:!0})},i.n=function(o){var s=o&&o.__esModule?function(){return o.default}:function(){return o};return i.d(s,"a",s),s},i.o=function(o,s){return Object.prototype.hasOwnProperty.call(o,s)},i.p="",i(i.s=0)}({"./dist/icons.json":function(n){n.exports={activity:'',airplay:'',"alert-circle":'',"alert-octagon":'',"alert-triangle":'',"align-center":'',"align-justify":'',"align-left":'',"align-right":'',anchor:'',aperture:'',archive:'',"arrow-down-circle":'',"arrow-down-left":'',"arrow-down-right":'',"arrow-down":'',"arrow-left-circle":'',"arrow-left":'',"arrow-right-circle":'',"arrow-right":'',"arrow-up-circle":'',"arrow-up-left":'',"arrow-up-right":'',"arrow-up":'',"at-sign":'',award:'',"bar-chart-2":'',"bar-chart":'',"battery-charging":'',battery:'',"bell-off":'',bell:'',bluetooth:'',bold:'',"book-open":'',book:'',bookmark:'',box:'',briefcase:'',calendar:'',"camera-off":'',camera:'',cast:'',"check-circle":'',"check-square":'',check:'',"chevron-down":'',"chevron-left":'',"chevron-right":'',"chevron-up":'',"chevrons-down":'',"chevrons-left":'',"chevrons-right":'',"chevrons-up":'',chrome:'',circle:'',clipboard:'',clock:'',"cloud-drizzle":'',"cloud-lightning":'',"cloud-off":'',"cloud-rain":'',"cloud-snow":'',cloud:'',code:'',codepen:'',codesandbox:'',coffee:'',columns:'',command:'',compass:'',copy:'',"corner-down-left":'',"corner-down-right":'',"corner-left-down":'',"corner-left-up":'',"corner-right-down":'',"corner-right-up":'',"corner-up-left":'',"corner-up-right":'',cpu:'',"credit-card":'',crop:'',crosshair:'',database:'',delete:'',disc:'',"divide-circle":'',"divide-square":'',divide:'',"dollar-sign":'',"download-cloud":'',download:'',dribbble:'',droplet:'',"edit-2":'',"edit-3":'',edit:'',"external-link":'',"eye-off":'',eye:'',facebook:'',"fast-forward":'',feather:'',figma:'',"file-minus":'',"file-plus":'',"file-text":'',file:'',film:'',filter:'',flag:'',"folder-minus":'',"folder-plus":'',folder:'',framer:'',frown:'',gift:'',"git-branch":'',"git-commit":'',"git-merge":'',"git-pull-request":'',github:'',gitlab:'',globe:'',grid:'',"hard-drive":'',hash:'',headphones:'',heart:'',"help-circle":'',hexagon:'',home:'',image:'',inbox:'',info:'',instagram:'',italic:'',key:'',layers:'',layout:'',"life-buoy":'',"link-2":'',link:'',linkedin:'',list:'',loader:'',lock:'',"log-in":'',"log-out":'',mail:'',"map-pin":'',map:'',"maximize-2":'',maximize:'',meh:'',menu:'',"message-circle":'',"message-square":'',"mic-off":'',mic:'',"minimize-2":'',minimize:'',"minus-circle":'',"minus-square":'',minus:'',monitor:'',moon:'',"more-horizontal":'',"more-vertical":'',"mouse-pointer":'',move:'',music:'',"navigation-2":'',navigation:'',octagon:'',package:'',paperclip:'',"pause-circle":'',pause:'',"pen-tool":'',percent:'',"phone-call":'',"phone-forwarded":'',"phone-incoming":'',"phone-missed":'',"phone-off":'',"phone-outgoing":'',phone:'',"pie-chart":'',"play-circle":'',play:'',"plus-circle":'',"plus-square":'',plus:'',pocket:'',power:'',printer:'',radio:'',"refresh-ccw":'',"refresh-cw":'',repeat:'',rewind:'',"rotate-ccw":'',"rotate-cw":'',rss:'',save:'',scissors:'',search:'',send:'',server:'',settings:'',"share-2":'',share:'',"shield-off":'',shield:'',"shopping-bag":'',"shopping-cart":'',shuffle:'',sidebar:'',"skip-back":'',"skip-forward":'',slack:'',slash:'',sliders:'',smartphone:'',smile:'',speaker:'',square:'',star:'',"stop-circle":'',sun:'',sunrise:'',sunset:'',table:'',tablet:'',tag:'',target:'',terminal:'',thermometer:'',"thumbs-down":'',"thumbs-up":'',"toggle-left":'',"toggle-right":'',tool:'',"trash-2":'',trash:'',trello:'',"trending-down":'',"trending-up":'',triangle:'',truck:'',tv:'',twitch:'',twitter:'',type:'',umbrella:'',underline:'',unlock:'',"upload-cloud":'',upload:'',"user-check":'',"user-minus":'',"user-plus":'',"user-x":'',user:'',users:'',"video-off":'',video:'',voicemail:'',"volume-1":'',"volume-2":'',"volume-x":'',volume:'',watch:'',"wifi-off":'',wifi:'',wind:'',"x-circle":'',"x-octagon":'',"x-square":'',x:'',youtube:'',"zap-off":'',zap:'',"zoom-in":'',"zoom-out":''}},"./node_modules/classnames/dedupe.js":function(n,r,i){var o,s;/*! Copyright (c) 2016 Jed Watson. Licensed under the MIT License (MIT), see http://jedwatson.github.io/classnames diff --git a/index.html b/index.html index ff63fad..85feb65 100644 --- a/index.html +++ b/index.html @@ -5,7 +5,7 @@ Quiver - OCR-D Benchmarking Dashboard - +