"use strict";(self.webpackChunkcue_ui=self.webpackChunkcue_ui||[]).push([[329],{329(p,i,t){t.d(i,{CodeViewer:()=>u});var a=t(467),d=t(7705),_=t(5802),l=t(836),c=t(5547);let u=(()=>{class o{fileURL=d.hFB.required();codeType=(0,d.hFB)("text");content=(0,_.vPA)("");onFile=(0,_.QZP)((()=>{var e=this;return(0,a.A)(function*(){const n=e.fileURL(),r=yield(yield fetch(n)).text();if("json"===e.codeType()||"jsonld"===e.codeType())try{return void e.content.set(JSON.parse(r))}catch{}e.content.set(r)})})());static \u0275fac=function(n){return new(n||o)};static \u0275cmp=c.VBU({type:o,selectors:[["cue-code-viewer"]],inputs:{fileURL:[1,"fileURL"],codeType:[1,"codeType"]},decls:1,vars:3,consts:[[2,"height","100%","width","100%","display","block",3,"type","content","readonly"]],template:function(n,s){1&n&&c.nrm(0,"cue-code-editor",0),2&n&&c.Y8G("type",s.codeType())("content",s.content())("readonly",!0)},dependencies:[l.B],styles:["[_nghost-%COMP%]{display:contents}"],changeDetection:0})}return o})()}}]);