@rr0/ufoathome 0.198.1 → 0.199.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-embed-scene/rr0-scene.mjs +4 -4
- package/dist-embed-sighting/CaseMessages_en-BC0lku35.js +1 -0
- package/dist-embed-sighting/CaseMessages_es-Cbktn5vj.js +1 -0
- package/dist-embed-sighting/CaseMessages_fr-D_6J6ONO.js +1 -0
- package/dist-embed-sighting/CaseMessages_it-CYyww4oG.js +1 -0
- package/dist-embed-sighting/{CaseReportExport-BetcYOov.js → CaseReportExport-CAuwP-Ec.js} +1 -1
- package/dist-embed-sighting/rr0-sighting.mjs +70 -59
- package/dist-embed-sighting-editor/{CaseEditorMessages_en-CpJLWbJD.js → CaseEditorMessages_en-pog3M_U6.js} +1 -1
- package/{dist-embed-ufoathome/CaseEditorMessages_es-C5YOqVpF.js → dist-embed-sighting-editor/CaseEditorMessages_es-Dz1N0VpM.js} +1 -1
- package/{dist-embed-ufoathome/CaseEditorMessages_fr-rMlMgrqV.js → dist-embed-sighting-editor/CaseEditorMessages_fr-BOKVeIXM.js} +1 -1
- package/{dist-embed-ufoathome/CaseEditorMessages_it-Bkiv2Hun.js → dist-embed-sighting-editor/CaseEditorMessages_it-BKAkbKq-.js} +1 -1
- package/dist-embed-sighting-editor/CaseElement--JmpOsUW.js +131 -0
- package/dist-embed-sighting-editor/CaseMessages_en-BC0lku35.js +1 -0
- package/dist-embed-sighting-editor/CaseMessages_es-Cbktn5vj.js +1 -0
- package/dist-embed-sighting-editor/CaseMessages_fr-D_6J6ONO.js +1 -0
- package/dist-embed-sighting-editor/CaseMessages_it-CYyww4oG.js +1 -0
- package/dist-embed-sighting-editor/{CaseReportExport-U-dk4A7z.js → CaseReportExport-nFM_7lq4.js} +1 -1
- package/dist-embed-sighting-editor/{SightingElement-BhyoU_gg.js → SightingElement-DsR4mBCh.js} +1 -1
- package/dist-embed-sighting-editor/rr0-sighting-editor.mjs +123 -111
- package/dist-embed-ufoathome/{AdsbLolArchiveProvider-CUkfGJbL.js → AdsbLolArchiveProvider-B9MGq-iQ.js} +1 -1
- package/dist-embed-ufoathome/{BallesterGuaspAssessor-CB2F8A6P.js → BallesterGuaspAssessor-BehuINgj.js} +1 -1
- package/dist-embed-ufoathome/{BeamEditor-Q_m3KK0S.js → BeamEditor-CFYAfywp.js} +1 -1
- package/dist-embed-ufoathome/{BeamSystem-CVMU5DeE.js → BeamSystem-Bt5Dnpzy.js} +1 -1
- package/dist-embed-ufoathome/{BodyEditor-BwsMj37A.js → BodyEditor-B96fap0d.js} +1 -1
- package/dist-embed-ufoathome/{CaseEditorElement-BrcX9sp0.js → CaseEditorElement-D-RKShTH.js} +88 -77
- package/dist-embed-ufoathome/{CaseEditorMessages_en-CpJLWbJD.js → CaseEditorMessages_en-pog3M_U6.js} +1 -1
- package/{dist-embed-sighting-editor/CaseEditorMessages_es-C5YOqVpF.js → dist-embed-ufoathome/CaseEditorMessages_es-Dz1N0VpM.js} +1 -1
- package/{dist-embed-sighting-editor/CaseEditorMessages_fr-rMlMgrqV.js → dist-embed-ufoathome/CaseEditorMessages_fr-BOKVeIXM.js} +1 -1
- package/{dist-embed-sighting-editor/CaseEditorMessages_it-Bkiv2Hun.js → dist-embed-ufoathome/CaseEditorMessages_it-BKAkbKq-.js} +1 -1
- package/dist-embed-ufoathome/CaseElement-BFDRYL5v.js +131 -0
- package/dist-embed-ufoathome/CaseMessages_en-BC0lku35.js +1 -0
- package/dist-embed-ufoathome/CaseMessages_es-Cbktn5vj.js +1 -0
- package/dist-embed-ufoathome/CaseMessages_fr-D_6J6ONO.js +1 -0
- package/dist-embed-ufoathome/CaseMessages_it-CYyww4oG.js +1 -0
- package/dist-embed-ufoathome/{CaseReportExport--IhmS67e.js → CaseReportExport-VrulN0VG.js} +3 -3
- package/dist-embed-ufoathome/{ColumnResize-CMfGWQHi.js → ColumnResize-DD0wwlp2.js} +7 -6
- package/dist-embed-ufoathome/{ContrailSystem-CuFduINP.js → ContrailSystem-BKeTHlcZ.js} +1 -1
- package/dist-embed-ufoathome/{ControlPasses-BS7yyZOR.js → ControlPasses-D3vc-NmG.js} +1 -1
- package/dist-embed-ufoathome/{CoverageAssessor-BwXJv4OD.js → CoverageAssessor-Be38W7Im.js} +1 -1
- package/dist-embed-ufoathome/{Flightradar24Provider-Cd4o260r.js → Flightradar24Provider-DdPjGVJg.js} +1 -1
- package/dist-embed-ufoathome/{GLTFLoader-BegH9SUA.js → GLTFLoader-D1_vI_Fe.js} +1 -1
- package/dist-embed-ufoathome/{GeoJsonExport-Czm1iAIW.js → GeoJsonExport-B2qogWLj.js} +1 -1
- package/dist-embed-ufoathome/{GeographicFigures-CKg7JYgf.js → GeographicFigures-Ds8kfyn7.js} +1 -1
- package/dist-embed-ufoathome/{HeadlightSystem-DIk-C7_5.js → HeadlightSystem-BdhHphIq.js} +1 -1
- package/dist-embed-ufoathome/{HynekAssessor-BybLMdda.js → HynekAssessor-MqnQfg3F.js} +1 -1
- package/dist-embed-ufoathome/{InterviewEditorElement-CbTakhyi.js → InterviewEditorElement-DjQuGytO.js} +1 -1
- package/dist-embed-ufoathome/{InterviewElement-fI19BieO.js → InterviewElement-BrlawcDm.js} +1 -1
- package/dist-embed-ufoathome/{KmlExport-De-2dnYz.js → KmlExport-AzofE76s.js} +1 -1
- package/dist-embed-ufoathome/{LaserBeam-CouNB7Pe.js → LaserBeam-Ced8VujI.js} +1 -1
- package/dist-embed-ufoathome/{LaunchEditor-BNInX90c.js → LaunchEditor-D-5OJi90.js} +1 -1
- package/dist-embed-ufoathome/{LaunchPlume-DVxzb0wy.js → LaunchPlume-DdeLDyDg.js} +1 -1
- package/dist-embed-ufoathome/{LaunchSimulation-CCvSd6qD.js → LaunchSimulation-BeCHjgE5.js} +1 -1
- package/dist-embed-ufoathome/{ModelSource-BZ1U1VU1.js → ModelSource-LY5T91ay.js} +1 -1
- package/dist-embed-ufoathome/{ModelThumbnails-Ckdb3qoW.js → ModelThumbnails-C25E4WMl.js} +1 -1
- package/dist-embed-ufoathome/{ModelViewer-B9PZN5c7.js → ModelViewer-D6JaOQS7.js} +1 -1
- package/dist-embed-ufoathome/{ModuleConformance-8JN5JVgE.js → ModuleConformance-DGjaEwAM.js} +2 -2
- package/dist-embed-ufoathome/{ModuleSession-ClSpEZMn.js → ModuleSession-pXE1aOJF.js} +3 -3
- package/dist-embed-ufoathome/{ModuleThree-CRG8PTLA.js → ModuleThree-xQDeVLs0.js} +1 -1
- package/dist-embed-ufoathome/{ModulesPanelElement-D4Hos-mF.js → ModulesPanelElement-Bio6lzC6.js} +3 -3
- package/dist-embed-ufoathome/{NearestApproach-DrJN7h_1.js → NearestApproach-DAiByBN2.js} +1 -1
- package/dist-embed-ufoathome/{PictureRegistration-LxhNTA4v.js → PictureRegistration-Dbr0O7NF.js} +1 -1
- package/dist-embed-ufoathome/{PoherAssessor-RyKMyps7.js → PoherAssessor-C7NN73NP.js} +1 -1
- package/dist-embed-ufoathome/{RailwaySystem-BOQvJ2r4.js → RailwaySystem-D3u3j_tw.js} +1 -1
- package/dist-embed-ufoathome/{ReentryEditor-B1H_TUMf.js → ReentryEditor-s-AkSgbU.js} +1 -1
- package/dist-embed-ufoathome/{ReentrySimulation-C7XZlAED.js → ReentrySimulation-2UWwXU7K.js} +1 -1
- package/dist-embed-ufoathome/{ReferenceSystem-BcsjHgaw.js → ReferenceSystem-BhEFpIis.js} +1 -1
- package/dist-embed-ufoathome/{ShareDialogElement-DHlxoHWP.js → ShareDialogElement-C9Uiwt0F.js} +11 -11
- package/dist-embed-ufoathome/{SightingElement-COJwKNNg.js → SightingElement-DTADTDwh.js} +2 -2
- package/dist-embed-ufoathome/{TraceSystem-BBCpq8-v.js → TraceSystem-BcWYbjQM.js} +1 -1
- package/dist-embed-ufoathome/{VideoButton-CGQI7iUA.js → VideoButton-CgfBskVu.js} +1 -1
- package/dist-embed-ufoathome/{WaterSystem-BrIS0Wzy.js → WaterSystem-BsGtTimO.js} +1 -1
- package/dist-embed-ufoathome/rr0-ufoathome.mjs +3 -3
- package/dist-embed-ufoathome/{surroundingsSources-Dg6vMWL7.js → surroundingsSources-B--F7TR5.js} +1 -1
- package/dist-embed-ufoathome/{trafficRuntime-BT5Ol_v5.js → trafficRuntime-B97u9ZY_.js} +1 -1
- package/package.json +1 -1
- package/dist-embed-sighting/CaseMessages_en-G5J5w1_d.js +0 -1
- package/dist-embed-sighting/CaseMessages_es-D7Rp1_1K.js +0 -1
- package/dist-embed-sighting/CaseMessages_fr-B8eZ1NIJ.js +0 -1
- package/dist-embed-sighting/CaseMessages_it-Cu02nVVo.js +0 -1
- package/dist-embed-sighting-editor/CaseElement-IzaexO7n.js +0 -121
- package/dist-embed-sighting-editor/CaseMessages_en-G5J5w1_d.js +0 -1
- package/dist-embed-sighting-editor/CaseMessages_es-D7Rp1_1K.js +0 -1
- package/dist-embed-sighting-editor/CaseMessages_fr-B8eZ1NIJ.js +0 -1
- package/dist-embed-sighting-editor/CaseMessages_it-Cu02nVVo.js +0 -1
- package/dist-embed-ufoathome/CaseElement-Ca8ctACA.js +0 -121
- package/dist-embed-ufoathome/CaseMessages_en-G5J5w1_d.js +0 -1
- package/dist-embed-ufoathome/CaseMessages_es-D7Rp1_1K.js +0 -1
- package/dist-embed-ufoathome/CaseMessages_fr-B8eZ1NIJ.js +0 -1
- package/dist-embed-ufoathome/CaseMessages_it-Cu02nVVo.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e={caseHeading:"Case",eventsHeading:"History",kindObservation:"Observation",kindReading:"Reading",kindInterview:"Interview",openEvent:"Open this event alone",toggleEvent:"Show beside the others, or put away",searchEvents:"Search the history",noEventFound:"No event matches",groupReadings:"Group the readings under their observation",resizeColumns:"Resize the history column (double-click: back to its width)",alsoAbout:"Also about",foldReadings:"Fold its readings away",unfoldReadings:"Unfold its readings",interpretationOf:"Reading of",passagesHeading:"Told in",byAuthor:"by",linkAnd:"and",caseSummary:"What this case says of itself",editCase:"Edit this case",shareCase:"Share this case"};export{e as caseMessages_en};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e={caseHeading:"Caso",eventsHeading:"Historial",kindObservation:"Observación",kindReading:"Lectura",kindInterview:"Entrevista",openEvent:"Abrir solo este evento",toggleEvent:"Mostrar junto a los demás, o quitar",searchEvents:"Buscar en el historial",noEventFound:"Ningún evento coincide",groupReadings:"Agrupar las lecturas por observación",resizeColumns:"Cambiar el ancho de la columna del historial (doble clic: ancho por defecto)",alsoAbout:"También trata de",foldReadings:"Plegar sus lecturas",unfoldReadings:"Desplegar sus lecturas",interpretationOf:"Lectura de",passagesHeading:"Relatado en",byAuthor:"por",linkAnd:"y",caseSummary:"Lo que este caso dice de sí mismo",editCase:"Editar este caso",shareCase:"Compartir este caso"};export{e as caseMessages_es};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e={caseHeading:"Dossier",eventsHeading:"Historique",kindObservation:"Observation",kindReading:"Lecture",kindInterview:"Interview",openEvent:"Ouvrir cet événement seul",toggleEvent:"Afficher à côté des autres, ou retirer",searchEvents:"Rechercher dans l'historique",noEventFound:"Aucun événement ne correspond",groupReadings:"Regrouper les lectures par observation",resizeColumns:"Redimensionner la colonne de l'historique (double-clic : largeur par défaut)",alsoAbout:"Porte aussi sur",foldReadings:"Replier ses lectures",unfoldReadings:"Déplier ses lectures",interpretationOf:"Lecture de",passagesHeading:"Relaté dans",byAuthor:"par",linkAnd:"et",caseSummary:"Ce que ce dossier dit de lui-même",editCase:"Modifier ce dossier",shareCase:"Partager ce dossier"};export{e as caseMessages_fr};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e={caseHeading:"Caso",eventsHeading:"Cronologia",kindObservation:"Osservazione",kindReading:"Lettura",kindInterview:"Intervista",openEvent:"Apri solo questo evento",toggleEvent:"Mostra accanto agli altri, o togli",searchEvents:"Cerca nella cronologia",noEventFound:"Nessun evento corrisponde",groupReadings:"Raggruppa le letture per osservazione",resizeColumns:"Ridimensiona la colonna della cronologia (doppio clic: larghezza predefinita)",alsoAbout:"Riguarda anche",foldReadings:"Chiudi le sue letture",unfoldReadings:"Apri le sue letture",interpretationOf:"Lettura di",passagesHeading:"Raccontato in",byAuthor:"di",linkAnd:"e",caseSummary:"Ciò che questo caso dice di sé",editCase:"Modificare questo caso",shareCase:"Condividi questo caso"};export{e as caseMessages_it};
|
|
@@ -62,4 +62,4 @@ ${o.join(`
|
|
|
62
62
|
`)}
|
|
63
63
|
</body>
|
|
64
64
|
</html>
|
|
65
|
-
`}static comparedTable(t,n){const a=n.texts.columns,s=z.escape;return z.table([a.reading,a.reads,a.reproduced,a.gap,a.robustness,a.supposedCount],t.readings.map(i=>{const e=n.robustness(i.sensitivity);return[s(i.title),s(i.reads),`<span class="n">${n.reproduced(i.sensitivity)}</span>`,n.degrees(i.sensitivity?.medianSeparationDeg),`<span class="${e.kind}">${s(e.text)}</span>`,String(i.supposed.length)]}),[2,3,5])}static witness(t,n,a){const s=a.texts,i=s.columns,e=z.escape,r=[`<h3>${e(a.fill(s.witnessHeading,{witness:t.title}))}</h3>`],o=[[s.columns.time,t.time??""],[s.place,t.place??""],[s.duration,t.durationSeconds!==void 0?a.instant(t.durationSeconds*1e3):""],[s.instrument,t.instrument??""]].filter(([,m])=>m!=="");o.length&&r.push(`<dl class="facts">${o.map(([m,d])=>`<dt>${e(m)}</dt><dd>${e(d)}</dd>`).join("")}</dl>`),t.description&&r.push(`<h4>${e(s.account)}</h4>`,`<blockquote>${e(t.description)}</blockquote>`),t.sources.length&&r.push(`<h4>${e(s.sources)}</h4>`,`<ul class="sources">${t.sources.map(m=>`<li>${[m.authors?.join(", "),m.title?`<em>${e(m.title)}</em>`:"",m.publisher,m.time,m.index].filter(Boolean).map(g=>g.startsWith("<em>")?g:e(g)).join(", ")}${m.url?` <a href="${e(m.url)}">${e(m.url)}</a>`:""}</li>`).join("")}</ul>`);const u=S.svg(t,a);u&&r.push(`<figure>${u}<figcaption>${e(s.timelineCaption)}</figcaption></figure>`),n=n.filter(m=>m.comparisons.length>0);const p=D.svg(t,n,a);if(p){const m=[`<li><svg viewBox="0 0 14 14" width="14" height="14" aria-hidden="true"><circle cx="7" cy="7" r="4" fill="#111827"/></svg>${e(s.saidLegend)}</li>`,...n.map((d,g)=>`<li>${D.legendMark(g)}${e(d.title)}</li>`)];r.push(`<figure>${p}<ul class="legend">${m.join("")}</ul><figcaption>${e(s.figureCaption)}</figcaption></figure>`)}if(t.pictures?.length){const m=t.pictures[0].views.map(d=>d.label);r.push(`<h4>${e(s.pictures)}</h4>`,`<div class="scroll"><table class="pictures"><thead><tr><th scope="col">${e(s.columns.instant)}</th>${m.map(d=>`<th scope="col">${e(d)}</th>`).join("")}</tr></thead><tbody>${t.pictures.map(d=>`<tr><td class="n">${a.instant(d.t)}</td>${d.views.map(g=>`<td>${g.image?`<img src="${g.image}" alt="${e(g.label)}, ${a.instant(d.t)}">`:`<span class="nothing">${e(s.noPicture)}</span>`}</td>`).join("")}</tr>`).join("")}</tbody></table></div>`,`<p class="caption">${e(s.picturesCaption)}</p>`)}r.push(`<h4>${e(s.indications)}</h4>`),t.indications.length===0?r.push(`<p>${e(s.noIndication)}</p>`):r.push(z.table([i.instant,i.phenomenon,i.azimuth,i.altitude,i.uncertainty,i.size,i.basis,i.rests],t.indications.map(m=>{const d=m.uncertainty;return[a.instant(m.t),e(m.phenomenon??m.sourceId),m.directionSaid?a.azimuth(m.aim?.azimuthDeg):"",m.directionSaid?a.degrees(m.aim?.altitudeDeg):"",d?`${a.azimuth(d.azimuthDeg[0])} … ${a.azimuth(d.azimuthDeg[1])} ; ${a.degrees(d.altitudeDeg[0])} … ${a.degrees(d.altitudeDeg[1])}`:"",m.sizeSaid?a.degrees(m.angular?.widthDeg):"",m.basis?e(s.bases[m.basis]):"",e(a.rests(m))]}),[0,2,3,5]));const l=t.values.filter(m=>!/^timeline\.keyframes\.\d+\.shapes\.\d+\.shape\.(aim|angular)/.test(m.path));return l.length>0&&r.push(`<h4>${e(s.values)}</h4>`,z.valuesTable(l,a)),r}static reading(t,n,a){const s=a.texts,i=s.columns,e=z.escape,r=[`<h2>${e(a.fill(s.readingHeading,{title:t.title,witness:t.reads}))}</h2>`],c=[t.by.length?a.fill(s.by,{names:t.by.join(", ")}):"",t.time?a.fill(s.made,{time:t.time}):""].filter(Boolean).join(" ");c&&r.push(`<p class="meta">${e(c)}</p>`),t.description&&r.push(`<blockquote>${e(t.description)}</blockquote>`),r.push(`<h4>${e(s.supposed)}</h4>`,t.supposed.length?z.valuesTable(t.supposed,a):`<p>${e(s.noneSupposed)}</p>`),r.push(`<h4>${e(s.findings)}</h4>`),r.push(t.findings.length?z.table([i.finding,i.outcome,i.against,i.origin],t.findings.map(u=>[e(u.text),`<span class="${u.outcome}">${e(s.outcomes[u.outcome])}</span>`,u.outcome==="fails"?e(s.grounds[u.against??"established"]):"",e(s.origins[u.written?"written":"computed"])])):`<p>${e(s.noFinding)}</p>`);const o=t.sensitivity;if(o){const u=a.robustness(o);if(r.push(`<h4>${e(s.sensitivity)}</h4>`,`<p>${e(i.reproduced)} : ${a.reproduced(o)||"–"} · ${e(i.gap)} : ${a.degrees(o.medianSeparationDeg)||"–"} · <span class="${u.kind}">${e(u.text)}</span></p>`),u.kind!=="too-few"&&u.kind!=="nothing"&&o.margins.length>0&&r.push(z.table([i.knob,i.from,i.to,i.reference,i.covered],o.margins.map(p=>{const l=a.ends(p),m=p.reference?`${a.amount(p.knob,p.reference.lower)} … ${a.amount(p.knob,p.reference.upper)}`:s.noLaw;return[e(s.knobs[p.knob]),l.from,l.to,e(m),p.coverage===void 0?"":`${Math.round(p.coverage*100)} %`]}),[1,2,4])),o.better){const{knob:p,amount:l,agreement:m}=o.better;r.push(`<p class="fine-tuned">${e(a.fill(s.better,{knob:s.knobs[p],amount:a.amount(p,l),agreed:String(Math.round(m*o.compared)),compared:String(o.compared)}))}</p>`)}}return t.comparisons.length>0&&r.push(`<h4>${e(s.comparisons)}</h4>`,z.table([i.instant,i.phenomenon,`${i.said} (${i.azimuth}, ${i.altitude})`,`${i.read} (${i.azimuth}, ${i.altitude})`,i.separation,i.agrees],t.comparisons.map(u=>[a.instant(u.t),e(n?.phenomena?.[u.sourceId]??u.sourceId),u.said?`${a.azimuth(u.said.azimuthDeg)}, ${a.degrees(u.said.altitudeDeg)}`:"",`${a.azimuth(u.predicted.azimuthDeg)}, ${a.degrees(u.predicted.altitudeDeg)}`,a.degrees(u.separationDeg),`<span class="${u.agrees?"holds":"fails"}">${e(u.agrees?s.yes:s.no)}</span>`]),[0,4])),r}static valuesTable(t,n){const a=n.texts,s=a.columns,i=z.escape;return z.table([s.path,s.value,s.basis,s.rests],t.map(e=>[`<code>${i(e.path)}</code>`,i(n.value(e)),i(a.bases[e.basis]),i(n.rests(e))]))}static table(t,n,a=[]){const s=z.escape,i=`<tr>${t.map(r=>`<th scope="col">${s(r)}</th>`).join("")}</tr>`,e=n.map(r=>`<tr>${r.map((c,o)=>`<td${a.includes(o)?' class="n"':""}>${c}</td>`).join("")}</tr>`);return`<div class="scroll"><table><thead>${i}</thead><tbody>${e.join("")}</tbody></table></div>`}static escape(t){return t.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}}const _=P.catalog({en:()=>B(()=>import("./CaseReportTexts_en-DlN7p1pC.js"),[],import.meta.url).then(N=>N.caseReportTexts_en),fr:()=>B(()=>import("./CaseReportTexts_fr-B5nP6RlP.js"),[],import.meta.url).then(N=>N.caseReportTexts_fr),es:()=>B(()=>import("./CaseReportTexts_es-CncAEaey.js"),[],import.meta.url).then(N=>N.caseReportTexts_es),it:()=>B(()=>import("./CaseReportTexts_it-Dc-oPmXB.js"),[],import.meta.url).then(N=>N.caseReportTexts_it)});class U{static async make(t,n,a,s,i=!1,e){const[r,c]=await Promise.all([_.load(a),J.load(a)]),o=A.of(n.caseJson,n.caseUrl,n.recordings,new C([...s]),new F(c));i&&t!=="csv"&&await U.pictures(o,n,r,e);const u=`${n.caseJson.id??"case"}-report`;switch(t){case"html":U.download(new Blob([z.of(o,r,a,"0.
|
|
65
|
+
`}static comparedTable(t,n){const a=n.texts.columns,s=z.escape;return z.table([a.reading,a.reads,a.reproduced,a.gap,a.robustness,a.supposedCount],t.readings.map(i=>{const e=n.robustness(i.sensitivity);return[s(i.title),s(i.reads),`<span class="n">${n.reproduced(i.sensitivity)}</span>`,n.degrees(i.sensitivity?.medianSeparationDeg),`<span class="${e.kind}">${s(e.text)}</span>`,String(i.supposed.length)]}),[2,3,5])}static witness(t,n,a){const s=a.texts,i=s.columns,e=z.escape,r=[`<h3>${e(a.fill(s.witnessHeading,{witness:t.title}))}</h3>`],o=[[s.columns.time,t.time??""],[s.place,t.place??""],[s.duration,t.durationSeconds!==void 0?a.instant(t.durationSeconds*1e3):""],[s.instrument,t.instrument??""]].filter(([,m])=>m!=="");o.length&&r.push(`<dl class="facts">${o.map(([m,d])=>`<dt>${e(m)}</dt><dd>${e(d)}</dd>`).join("")}</dl>`),t.description&&r.push(`<h4>${e(s.account)}</h4>`,`<blockquote>${e(t.description)}</blockquote>`),t.sources.length&&r.push(`<h4>${e(s.sources)}</h4>`,`<ul class="sources">${t.sources.map(m=>`<li>${[m.authors?.join(", "),m.title?`<em>${e(m.title)}</em>`:"",m.publisher,m.time,m.index].filter(Boolean).map(g=>g.startsWith("<em>")?g:e(g)).join(", ")}${m.url?` <a href="${e(m.url)}">${e(m.url)}</a>`:""}</li>`).join("")}</ul>`);const u=S.svg(t,a);u&&r.push(`<figure>${u}<figcaption>${e(s.timelineCaption)}</figcaption></figure>`),n=n.filter(m=>m.comparisons.length>0);const p=D.svg(t,n,a);if(p){const m=[`<li><svg viewBox="0 0 14 14" width="14" height="14" aria-hidden="true"><circle cx="7" cy="7" r="4" fill="#111827"/></svg>${e(s.saidLegend)}</li>`,...n.map((d,g)=>`<li>${D.legendMark(g)}${e(d.title)}</li>`)];r.push(`<figure>${p}<ul class="legend">${m.join("")}</ul><figcaption>${e(s.figureCaption)}</figcaption></figure>`)}if(t.pictures?.length){const m=t.pictures[0].views.map(d=>d.label);r.push(`<h4>${e(s.pictures)}</h4>`,`<div class="scroll"><table class="pictures"><thead><tr><th scope="col">${e(s.columns.instant)}</th>${m.map(d=>`<th scope="col">${e(d)}</th>`).join("")}</tr></thead><tbody>${t.pictures.map(d=>`<tr><td class="n">${a.instant(d.t)}</td>${d.views.map(g=>`<td>${g.image?`<img src="${g.image}" alt="${e(g.label)}, ${a.instant(d.t)}">`:`<span class="nothing">${e(s.noPicture)}</span>`}</td>`).join("")}</tr>`).join("")}</tbody></table></div>`,`<p class="caption">${e(s.picturesCaption)}</p>`)}r.push(`<h4>${e(s.indications)}</h4>`),t.indications.length===0?r.push(`<p>${e(s.noIndication)}</p>`):r.push(z.table([i.instant,i.phenomenon,i.azimuth,i.altitude,i.uncertainty,i.size,i.basis,i.rests],t.indications.map(m=>{const d=m.uncertainty;return[a.instant(m.t),e(m.phenomenon??m.sourceId),m.directionSaid?a.azimuth(m.aim?.azimuthDeg):"",m.directionSaid?a.degrees(m.aim?.altitudeDeg):"",d?`${a.azimuth(d.azimuthDeg[0])} … ${a.azimuth(d.azimuthDeg[1])} ; ${a.degrees(d.altitudeDeg[0])} … ${a.degrees(d.altitudeDeg[1])}`:"",m.sizeSaid?a.degrees(m.angular?.widthDeg):"",m.basis?e(s.bases[m.basis]):"",e(a.rests(m))]}),[0,2,3,5]));const l=t.values.filter(m=>!/^timeline\.keyframes\.\d+\.shapes\.\d+\.shape\.(aim|angular)/.test(m.path));return l.length>0&&r.push(`<h4>${e(s.values)}</h4>`,z.valuesTable(l,a)),r}static reading(t,n,a){const s=a.texts,i=s.columns,e=z.escape,r=[`<h2>${e(a.fill(s.readingHeading,{title:t.title,witness:t.reads}))}</h2>`],c=[t.by.length?a.fill(s.by,{names:t.by.join(", ")}):"",t.time?a.fill(s.made,{time:t.time}):""].filter(Boolean).join(" ");c&&r.push(`<p class="meta">${e(c)}</p>`),t.description&&r.push(`<blockquote>${e(t.description)}</blockquote>`),r.push(`<h4>${e(s.supposed)}</h4>`,t.supposed.length?z.valuesTable(t.supposed,a):`<p>${e(s.noneSupposed)}</p>`),r.push(`<h4>${e(s.findings)}</h4>`),r.push(t.findings.length?z.table([i.finding,i.outcome,i.against,i.origin],t.findings.map(u=>[e(u.text),`<span class="${u.outcome}">${e(s.outcomes[u.outcome])}</span>`,u.outcome==="fails"?e(s.grounds[u.against??"established"]):"",e(s.origins[u.written?"written":"computed"])])):`<p>${e(s.noFinding)}</p>`);const o=t.sensitivity;if(o){const u=a.robustness(o);if(r.push(`<h4>${e(s.sensitivity)}</h4>`,`<p>${e(i.reproduced)} : ${a.reproduced(o)||"–"} · ${e(i.gap)} : ${a.degrees(o.medianSeparationDeg)||"–"} · <span class="${u.kind}">${e(u.text)}</span></p>`),u.kind!=="too-few"&&u.kind!=="nothing"&&o.margins.length>0&&r.push(z.table([i.knob,i.from,i.to,i.reference,i.covered],o.margins.map(p=>{const l=a.ends(p),m=p.reference?`${a.amount(p.knob,p.reference.lower)} … ${a.amount(p.knob,p.reference.upper)}`:s.noLaw;return[e(s.knobs[p.knob]),l.from,l.to,e(m),p.coverage===void 0?"":`${Math.round(p.coverage*100)} %`]}),[1,2,4])),o.better){const{knob:p,amount:l,agreement:m}=o.better;r.push(`<p class="fine-tuned">${e(a.fill(s.better,{knob:s.knobs[p],amount:a.amount(p,l),agreed:String(Math.round(m*o.compared)),compared:String(o.compared)}))}</p>`)}}return t.comparisons.length>0&&r.push(`<h4>${e(s.comparisons)}</h4>`,z.table([i.instant,i.phenomenon,`${i.said} (${i.azimuth}, ${i.altitude})`,`${i.read} (${i.azimuth}, ${i.altitude})`,i.separation,i.agrees],t.comparisons.map(u=>[a.instant(u.t),e(n?.phenomena?.[u.sourceId]??u.sourceId),u.said?`${a.azimuth(u.said.azimuthDeg)}, ${a.degrees(u.said.altitudeDeg)}`:"",`${a.azimuth(u.predicted.azimuthDeg)}, ${a.degrees(u.predicted.altitudeDeg)}`,a.degrees(u.separationDeg),`<span class="${u.agrees?"holds":"fails"}">${e(u.agrees?s.yes:s.no)}</span>`]),[0,4])),r}static valuesTable(t,n){const a=n.texts,s=a.columns,i=z.escape;return z.table([s.path,s.value,s.basis,s.rests],t.map(e=>[`<code>${i(e.path)}</code>`,i(n.value(e)),i(a.bases[e.basis]),i(n.rests(e))]))}static table(t,n,a=[]){const s=z.escape,i=`<tr>${t.map(r=>`<th scope="col">${s(r)}</th>`).join("")}</tr>`,e=n.map(r=>`<tr>${r.map((c,o)=>`<td${a.includes(o)?' class="n"':""}>${c}</td>`).join("")}</tr>`);return`<div class="scroll"><table><thead>${i}</thead><tbody>${e.join("")}</tbody></table></div>`}static escape(t){return t.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}}const _=P.catalog({en:()=>B(()=>import("./CaseReportTexts_en-DlN7p1pC.js"),[],import.meta.url).then(N=>N.caseReportTexts_en),fr:()=>B(()=>import("./CaseReportTexts_fr-B5nP6RlP.js"),[],import.meta.url).then(N=>N.caseReportTexts_fr),es:()=>B(()=>import("./CaseReportTexts_es-CncAEaey.js"),[],import.meta.url).then(N=>N.caseReportTexts_es),it:()=>B(()=>import("./CaseReportTexts_it-Dc-oPmXB.js"),[],import.meta.url).then(N=>N.caseReportTexts_it)});class U{static async make(t,n,a,s,i=!1,e){const[r,c]=await Promise.all([_.load(a),J.load(a)]),o=A.of(n.caseJson,n.caseUrl,n.recordings,new C([...s]),new F(c));i&&t!=="csv"&&await U.pictures(o,n,r,e);const u=`${n.caseJson.id??"case"}-report`;switch(t){case"html":U.download(new Blob([z.of(o,r,a,"0.199.0")],{type:"text/html"}),`${u}.html`);return;case"print":U.print(z.of(o,r,a,"0.199.0"));return;case"json":U.download(new Blob([T.json(o,"0.199.0")],{type:"application/json"}),`${u}.json`);return;case"csv":{const{zipSync:p,strToU8:l}=await B(async()=>{const{zipSync:d,strToU8:g}=await import("./browser-CltifEM0.js");return{zipSync:d,strToU8:g}},[],import.meta.url),m=Object.fromEntries(Object.entries(T.csv(o,r,a)).map(([d,g])=>[d,l(`\uFEFF${g}`)]));U.download(new Blob([p(m)],{type:"application/zip"}),`${u}-tables.zip`)}}}static PICTURED_INSTANTS=3;static async pictures(t,n,a,s){const{registerScene:i,SCENE_ELEMENT_NAME:e}=await B(async()=>{const{registerScene:p,SCENE_ELEMENT_NAME:l}=await import("./rr0-sighting.mjs").then(m=>m.bY);return{registerScene:p,SCENE_ELEMENT_NAME:l}},[],import.meta.url);i();const r=t.witnesses.map(p=>{const l=p.indications.filter(f=>f.directionSaid).map(f=>f.t),m=l.length<=U.PICTURED_INSTANTS?l:[l[0],l[Math.floor(l.length/2)],l[l.length-1]],d=t.readings.filter(f=>f.reads===p.title&&f.comparisons.length>0),g=[{label:a.accountView,url:p.url,reading:void 0},...d.map(f=>({label:f.title,url:p.url,reading:f.url}))];return{witness:p,instants:[...new Set(m)],recordings:g}}).filter(p=>p.instants.length>0),c=r.reduce((p,l)=>p+l.instants.length*l.recordings.length,0);if(c===0)return;const o=document.createElement(e);o.setAttribute("max-pixel-ratio","1"),o.setAttribute("always-live",""),Object.assign(o.style,{position:"fixed",left:"-10000px",top:"0",width:"640px",height:"360px",visibility:"hidden",pointerEvents:"none"}),document.body.appendChild(o);let u=0;s?.(u,c);try{for(const p of r){const l=p.instants.map(d=>({t:d,views:[]})),m=n.recordings.get(p.witness.url);m&&(o.documentUrl=p.witness.url,o.sightingData=m);for(const d of p.recordings){const g=m,f=d.reading?n.recordings.get(d.reading):void 0;for(const w of l){let b;g&&(!d.reading||f)&&(w===l[0]&&(o.interpretation=U.bodiesOf(f??g,d.reading??p.witness.url)),b=await o.pictureAt(w.t,480).catch(()=>{})),w.views.push({label:d.label,...b?{image:b}:{}}),s?.(++u,c)}}p.witness.pictures=l}}finally{o.remove()}}static bodiesOf(t,n){const a=W.strip(t).recording.interpretation;if(a)return{...a,bodies:a.bodies.map(s=>s.model?.url?{...s,model:{...s.model,url:new URL(s.model.url,n).href}}:s)}}static print(t){const n=document.createElement("iframe");n.setAttribute("aria-hidden","true"),n.style.cssText="position: fixed; right: 0; bottom: 0; width: 0; height: 0; border: 0",n.addEventListener("load",()=>{const a=n.contentWindow;a&&(a.addEventListener("afterprint",()=>n.remove()),a.focus(),a.print(),window.setTimeout(()=>n.remove(),6e4))},{once:!0}),n.srcdoc=t,document.body.append(n)}static download(t,n){const a=URL.createObjectURL(t),s=document.createElement("a");s.href=a,s.download=n,s.click(),window.setTimeout(()=>URL.revokeObjectURL(a),1e3)}}export{U as CaseReportExport};
|