@mechris3/glassbox 0.1.63 → 0.1.64
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/package.json
CHANGED
|
@@ -9,5 +9,5 @@
|
|
|
9
9
|
<style>:root{--bg-deep:#0d1117;--bg-panel:#161b22;--bg-surface:#1c2128;--bg-elevated:#21262d;--accent-primary:#e5a00d;--accent-hover:#f0b429;--accent-muted:#9e7a0c;--text-primary:#e6edf3;--text-secondary:#b1bac4;--text-muted:#7d8590;--color-success:#2ea043;--color-danger:#da3633;--color-warning:#d29922;--color-breakpoint:#f85149;--border-color:#30363d;--border-subtle:#21262d;--shadow-sm:0 1px 2px rgba(0, 0, 0, .3);--shadow-md:0 4px 12px rgba(0, 0, 0, .4);--radius-sm:4px;--radius-md:6px;--radius-lg:8px;--font-sans:-apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif;--font-mono:"SF Mono", "Fira Code", "Cascadia Code", Consolas, monospace;--space-xs:4px;--space-sm:8px;--space-md:16px;--space-lg:24px;--space-xl:32px}*,*:before,*:after{box-sizing:border-box;margin:0;padding:0}html,body{height:100%;font-family:var(--font-sans);font-size:14px;line-height:1.5;color:var(--text-primary);background-color:var(--bg-deep);-webkit-font-smoothing:antialiased}</style><link rel="stylesheet" href="styles-HMZYQRBV.css" media="print" onload="this.media='all'"><noscript><link rel="stylesheet" href="styles-HMZYQRBV.css"></noscript></head>
|
|
10
10
|
<body>
|
|
11
11
|
<gb-root></gb-root>
|
|
12
|
-
<script src="polyfills-5CFQRCPP.js" type="module"></script><script src="main-
|
|
12
|
+
<script src="polyfills-5CFQRCPP.js" type="module"></script><script src="main-LKQRYMFZ.js" type="module"></script></body>
|
|
13
13
|
</html>
|
|
@@ -8,9 +8,9 @@ ${n.map((r,o)=>`${o+1}) ${r.toString()}`).join(`
|
|
|
8
8
|
before dispatching the action. For example, someAction should be someAction().`);if(typeof n>"u")throw new TypeError("Actions must be objects");if(typeof n.type>"u")throw new TypeError("Actions must have a type property");super.next(n)}complete(){}ngOnDestroy(){super.complete()}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=T({token:e,factory:e.\u0275fac})}}return e})(),mC=[kt],Hg=new I("@ngrx/store Internal Root Guard"),Ng=new I("@ngrx/store Internal Initial State"),Qo=new I("@ngrx/store Initial State"),Ug=new I("@ngrx/store Reducer Factory"),Ag=new I("@ngrx/store Internal Reducer Factory Provider"),zg=new I("@ngrx/store Initial Reducers"),Pl=new I("@ngrx/store Internal Initial Reducers");var Rg=new I("@ngrx/store Internal Store Reducers");var yC=new I("@ngrx/store Internal Store Features");var vC=new I("@ngrx/store Feature Reducers"),Og=new I("@ngrx/store User Provided Meta Reducers"),aa=new I("@ngrx/store Meta Reducers"),kg=new I("@ngrx/store Internal Resolved Meta Reducers"),Fg=new I("@ngrx/store User Runtime Checks Config"),Pg=new I("@ngrx/store Internal User Runtime Checks Config"),Zo=new I("@ngrx/store Internal Runtime Checks"),Hl=new I("@ngrx/store Check if Action types are unique"),Yo=new I("@ngrx/store Root Store Provider"),ca=new I("@ngrx/store Feature State Provider");function EC(e,t={}){let n=Object.keys(e),r={};for(let i=0;i<n.length;i++){let s=n[i];typeof e[s]=="function"&&(r[s]=e[s])}let o=Object.keys(r);return function(s,a){s=s===void 0?t:s;let c=!1,u={};for(let l=0;l<o.length;l++){let d=o[l],f=r[d],p=s[d],h=f(p,a);u[d]=h,c=c||h!==p}return c?u:s}}function DC(e,t){return Object.keys(e).filter(n=>n!==t).reduce((n,r)=>Object.assign(n,{[r]:e[r]}),{})}function Gg(...e){return function(t){if(e.length===0)return t;let n=e[e.length-1];return e.slice(0,-1).reduceRight((o,i)=>i(o),n(t))}}function Wg(e,t){return Array.isArray(t)&&t.length>0&&(e=Gg.apply(null,[...t,e])),(n,r)=>{let o=e(n);return(i,s)=>(i=i===void 0?r:i,o(i,s))}}function bC(e){let t=Array.isArray(e)&&e.length>0?Gg(...e):n=>n;return(n,r)=>(n=t(n),(o,i)=>(o=o===void 0?r:o,n(o,i)))}var Qn=class extends j{},Pr=class extends kt{},la="@ngrx/store/update-reducers",ua=(()=>{class e extends jt{get currentReducers(){return this.reducers}constructor(n,r,o,i){super(i(o,r)),this.dispatcher=n,this.initialState=r,this.reducers=o,this.reducerFactory=i}addFeature(n){this.addFeatures([n])}addFeatures(n){let r=n.reduce((o,{reducers:i,reducerFactory:s,metaReducers:a,initialState:c,key:u})=>{let l=typeof i=="function"?bC(a)(i,c):Wg(s,a)(i,c);return o[u]=l,o},{});this.addReducers(r)}removeFeature(n){this.removeFeatures([n])}removeFeatures(n){this.removeReducers(n.map(r=>r.key))}addReducer(n,r){this.addReducers({[n]:r})}addReducers(n){this.reducers=E(E({},this.reducers),n),this.updateReducers(Object.keys(n))}removeReducer(n){this.removeReducers([n])}removeReducers(n){n.forEach(r=>{this.reducers=DC(this.reducers,r)}),this.updateReducers(n)}updateReducers(n){this.next(this.reducerFactory(this.reducers,this.initialState)),this.dispatcher.next({type:la,features:n})}ngOnDestroy(){this.complete()}static{this.\u0275fac=function(r){return new(r||e)(b(Pr),b(Qo),b(zg),b(Ug))}}static{this.\u0275prov=T({token:e,factory:e.\u0275fac})}}return e})(),wC=[ua,{provide:Qn,useExisting:ua},{provide:Pr,useExisting:kt}],Kn=(()=>{class e extends Ee{ngOnDestroy(){this.complete()}static{this.\u0275fac=(()=>{let n;return function(o){return(n||(n=To(e)))(o||e)}})()}static{this.\u0275prov=T({token:e,factory:e.\u0275fac})}}return e})(),CC=[Kn],Lr=class extends j{},Lg=(()=>{class e extends jt{static{this.INIT=Jo}constructor(n,r,o,i){super(i);let a=n.pipe(Bt(Yr)).pipe(Ke(r)),c={state:i},u=a.pipe(Xr(IC,c));this.stateSubscription=u.subscribe(({state:l,action:d})=>{this.next(l),o.next(d)}),this.state=sa(this,{manualCleanup:!0,requireSync:!0})}ngOnDestroy(){this.stateSubscription.unsubscribe(),this.complete()}static{this.\u0275fac=function(r){return new(r||e)(b(kt),b(Qn),b(Kn),b(Qo))}}static{this.\u0275prov=T({token:e,factory:e.\u0275fac})}}return e})();function IC(e={state:void 0},[t,n]){let{state:r}=e;return{state:n(r,t),action:t}}var _C=[Lg,{provide:Lr,useExisting:Lg}],Z=(()=>{class e extends j{constructor(n,r,o,i){super(),this.actionsObserver=r,this.reducerManager=o,this.injector=i,this.source=n,this.state=n.state}select(n,...r){return TC.call(null,n,...r)(this)}selectSignal(n,r){return jo(()=>n(this.state()),r)}lift(n){let r=new e(this,this.actionsObserver,this.reducerManager);return r.operator=n,r}dispatch(n,r){if(typeof n=="function")return this.processDispatchFn(n,r);this.actionsObserver.next(n)}next(n){this.actionsObserver.next(n)}error(n){this.actionsObserver.error(n)}complete(){this.actionsObserver.complete()}addReducer(n,r){this.reducerManager.addReducer(n,r)}removeReducer(n){this.reducerManager.removeReducer(n)}processDispatchFn(n,r){pC(this.injector,"Store Injector");let o=r?.injector??MC()??this.injector;return ho(()=>{let i=n();qn(()=>this.dispatch(i))},{injector:o})}static{this.\u0275fac=function(r){return new(r||e)(b(Lr),b(kt),b(ua),b(Ie))}}static{this.\u0275prov=T({token:e,factory:e.\u0275fac})}}return e})(),SC=[Z];function TC(e,t,...n){return function(o){let i;if(typeof e=="string"){let s=[t,...n].filter(Boolean);i=o.pipe(rc(e,...s))}else if(typeof e=="function")i=o.pipe(L(s=>e(s,t)));else throw new TypeError(`Unexpected type '${typeof e}' in select operator, expected 'string' or 'function'`);return i.pipe(dr())}}function MC(){try{return g(Ie)}catch(e){return}}var Ul="https://ngrx.io/guide/store/configuration/runtime-checks";function jg(e){return e===void 0}function Bg(e){return e===null}function qg(e){return Array.isArray(e)}function xC(e){return typeof e=="string"}function NC(e){return typeof e=="boolean"}function AC(e){return typeof e=="number"}function Zg(e){return typeof e=="object"&&e!==null}function RC(e){return Zg(e)&&!qg(e)}function OC(e){if(!RC(e))return!1;let t=Object.getPrototypeOf(e);return t===Object.prototype||t===null}function jl(e){return typeof e=="function"}function kC(e){return jl(e)&&e.hasOwnProperty("\u0275cmp")}function FC(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var PC=!1;function LC(){return PC}function Vg(e,t){return e===t}function jC(e,t,n){for(let r=0;r<e.length;r++)if(!n(e[r],t[r]))return!0;return!1}function Yg(e,t=Vg,n=Vg){let r=null,o=null,i;function s(){r=null,o=null}function a(l=void 0){i={result:l}}function c(){i=void 0}function u(){if(i!==void 0)return i.result;if(!r)return o=e.apply(null,arguments),r=arguments,o;if(!jC(arguments,r,t))return o;let l=e.apply(null,arguments);return r=arguments,n(o,l)?o:(o=l,l)}return{memoized:u,reset:s,setResult:a,clearResult:c}}function oe(...e){return VC(Yg)(...e)}function BC(e,t,n,r){if(n===void 0){let i=t.map(s=>s(e));return r.memoized.apply(null,i)}let o=t.map(i=>i(e,n));return r.memoized.apply(null,[...o,n])}function VC(e,t={stateFn:BC}){return function(...n){let r=n;if(Array.isArray(r[0])){let[l,...d]=r;r=[...l,...d]}else r.length===1&&$C(r[0])&&(r=HC(r[0]));let o=r.slice(0,r.length-1),i=r[r.length-1],s=o.filter(l=>l.release&&typeof l.release=="function"),a=e(function(...l){return i.apply(null,l)}),c=Yg(function(l,d){return t.stateFn.apply(null,[l,o,d,a])});function u(){c.reset(),a.reset(),s.forEach(l=>l.release())}return Object.assign(c.memoized,{release:u,projector:a.memoized,setResult:c.setResult,clearResult:c.clearResult})}}function Br(e){return oe(t=>{let n=t[e];return!LC()&&Vo()&&!(e in t)&&console.warn(`@ngrx/store: The feature name "${e}" does not exist in the state, therefore createFeatureSelector cannot access it. Be sure it is imported in a loaded module using StoreModule.forRoot('${e}', ...) or StoreModule.forFeature('${e}', ...). If the default state is intended to be undefined, as is the case with router state, this development-only warning message can be ignored.`),n},t=>t)}function $C(e){return!!e&&typeof e=="object"&&Object.values(e).every(t=>typeof t=="function")}function HC(e){let t=Object.values(e),n=Object.keys(e),r=(...o)=>n.reduce((i,s,a)=>C(E({},i),{[s]:o[a]}),{});return[...t,r]}function UC(e){return e instanceof I?g(e):e}function Jg(e){return typeof e=="function"?e():e}function zC(e,t){return e.concat(t)}function GC(){if(g(Z,{optional:!0,skipSelf:!0}))throw new TypeError("The root Store has been provided more than once. Feature modules should provide feature states instead.");return"guarded"}function WC(e,t){return function(n,r){let o=t.action(r)?Bl(r):r,i=e(n,o);return t.state()?Bl(i):i}}function Bl(e){Object.freeze(e);let t=jl(e);return Object.getOwnPropertyNames(e).forEach(n=>{if(!n.startsWith("\u0275")&&FC(e,n)&&(!t||n!=="caller"&&n!=="callee"&&n!=="arguments")){let r=e[n];(Zg(r)||jl(r))&&!Object.isFrozen(r)&&Bl(r)}}),e}function qC(e,t){return function(n,r){if(t.action(r)){let i=Vl(r);$g(i,"action")}let o=e(n,r);if(t.state()){let i=Vl(o);$g(i,"state")}return o}}function Vl(e,t=[]){return(jg(e)||Bg(e))&&t.length===0?{path:["root"],value:e}:Object.keys(e).reduce((r,o)=>{if(r)return r;let i=e[o];return kC(i)?r:jg(i)||Bg(i)||AC(i)||NC(i)||xC(i)||qg(i)?!1:OC(i)?Vl(i,[...t,o]):{path:[...t,o],value:i}},!1)}function $g(e,t){if(e===!1)return;let n=e.path.join("."),r=new Error(`Detected unserializable ${t} at "${n}". ${Ul}#strict${t}serializability`);throw r.value=e.value,r.unserializablePath=n,r}function ZC(e,t){return function(n,r){if(t.action(r)&&!re.isInAngularZone())throw new Error(`Action '${r.type}' running outside NgZone. ${Ul}#strictactionwithinngzone`);return e(n,r)}}function YC(e){return Vo()?E({strictStateSerializability:!1,strictActionSerializability:!1,strictStateImmutability:!0,strictActionImmutability:!0,strictActionWithinNgZone:!1,strictActionTypeUniqueness:!1},e):{strictStateSerializability:!1,strictActionSerializability:!1,strictStateImmutability:!1,strictActionImmutability:!1,strictActionWithinNgZone:!1,strictActionTypeUniqueness:!1}}function JC({strictActionSerializability:e,strictStateSerializability:t}){return n=>e||t?qC(n,{action:r=>e&&!zl(r),state:()=>t}):n}function QC({strictActionImmutability:e,strictStateImmutability:t}){return n=>e||t?WC(n,{action:r=>e&&!zl(r),state:()=>t}):n}function zl(e){return e.type.startsWith("@ngrx")}function KC({strictActionWithinNgZone:e}){return t=>e?ZC(t,{action:n=>e&&!zl(n)}):t}function XC(e){return[{provide:Pg,useValue:e},{provide:Fg,useFactory:tI,deps:[Pg]},{provide:Zo,deps:[Fg],useFactory:YC},{provide:aa,multi:!0,deps:[Zo],useFactory:QC},{provide:aa,multi:!0,deps:[Zo],useFactory:JC},{provide:aa,multi:!0,deps:[Zo],useFactory:KC}]}function eI(){return[{provide:Hl,multi:!0,deps:[Zo],useFactory:nI}]}function tI(e){return e}function nI(e){if(!e.strictActionTypeUniqueness)return;let t=Object.entries(Ll).filter(([,n])=>n>1).map(([n])=>n);if(t.length)throw new Error(`Action types are registered more than once, ${t.map(n=>`"${n}"`).join(", ")}. ${Ul}#strictactiontypeuniqueness`)}function rI(e={},t={}){return[{provide:Hg,useFactory:GC},{provide:Ng,useValue:t.initialState},{provide:Qo,useFactory:Jg,deps:[Ng]},{provide:Pl,useValue:e},{provide:Rg,useExisting:e instanceof I?e:Pl},{provide:zg,deps:[Pl,[new Wu(Rg)]],useFactory:UC},{provide:Og,useValue:t.metaReducers?t.metaReducers:[]},{provide:kg,deps:[aa,Og],useFactory:zC},{provide:Ag,useValue:t.reducerFactory?t.reducerFactory:EC},{provide:Ug,deps:[Ag,kg],useFactory:Wg},mC,wC,CC,_C,SC,XC(t.runtimeChecks),eI()]}function oI(){g(kt),g(Qn),g(Kn),g(Z),g(Hg,{optional:!0}),g(Hl,{optional:!0})}var iI=[{provide:Yo,useFactory:oI},mr(()=>g(Yo))];function Qg(e,t){return et([...rI(e,t),iI])}function sI(){g(Yo);let e=g(yC),t=g(vC),n=g(ua);g(Hl,{optional:!0});let r=e.map((o,i)=>{let a=t.shift()[i];return C(E({},o),{reducers:a,initialState:Jg(o.initialState)})});n.addFeatures(r)}var zV=[{provide:ca,useFactory:sI},mr(()=>g(ca))];function Y(...e){let t=e.pop(),n=e.map(r=>r.type);return{reducer:t,types:n}}function Vr(e,...t){let n=new Map;for(let r of t)for(let o of r.types){let i=n.get(o);if(i){let s=(a,c)=>r.reducer(i(a,c),c);n.set(o,s)}else n.set(o,r.reducer)}return function(r=e,o){let i=n.get(o.type);return i?i(r,o):r}}var U=jr({source:"Settings",events:{"Load Settings":ye(),"Load Settings Success":Te(),"Update Setting":Te(),"Save Settings":ye(),"Toggle Settings Panel":ye(),"Remove Url From History":Te()}});var mn=class e{constructor(t){this.store=t}currentTheme="dark";initialize(){let t=localStorage.getItem("glassbox-theme");t==="dark"||t==="light"?this.applyTheme(t):window.matchMedia("(prefers-color-scheme: light)").matches?this.applyTheme("light"):this.applyTheme("dark")}applyFromSettings(t){(t==="dark"||t==="light")&&this.applyTheme(t)}toggle(){let t=this.currentTheme==="dark"?"light":"dark";this.applyTheme(t),localStorage.setItem("glassbox-theme",t),this.store.dispatch(U.updateSetting({key:"theme",value:t}))}applyTheme(t){this.currentTheme=t,document.documentElement.setAttribute("data-theme",t)}static \u0275fac=function(n){return new(n||e)(b(Z))};static \u0275prov=T({token:e,factory:e.\u0275fac,providedIn:"root"})};var da=class e{constructor(t){this.themeService=t}settingsToggled=tg();toggleTheme(){this.themeService.toggle()}static \u0275fac=function(n){return new(n||e)(de(mn))};static \u0275cmp=Se({type:e,selectors:[["gb-header"]],outputs:{settingsToggled:"settingsToggled"},decls:10,vars:0,consts:[[1,"header"],[1,"header-left"],["src","assets/logo.svg","alt","Glassbox","width","24","height","24",1,"header-logo"],[1,"logo"],[1,"header-right"],["title","Toggle theme",1,"icon-btn",3,"click"],["title","Settings",1,"icon-btn",3,"click"]],template:function(n,r){n&1&&(m(0,"header",0)(1,"div",1),Rt(2,"img",2),m(3,"span",3),D(4,"Glassbox"),y()(),m(5,"div",4)(6,"button",5),G("click",function(){return r.toggleTheme()}),D(7,"\u{1F313}"),y(),m(8,"button",6),G("click",function(){return r.settingsToggled.emit()}),D(9,"\u2699\uFE0F"),y()()())},styles:[".header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:var(--space-sm) var(--space-md);background:var(--bg-panel);border-bottom:1px solid var(--border-color)}.header-left[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--space-sm)}.header-logo[_ngcontent-%COMP%]{display:block}.logo[_ngcontent-%COMP%]{font-weight:700;font-size:16px;color:var(--accent-primary);letter-spacing:-.5px}.header-right[_ngcontent-%COMP%]{display:flex;gap:var(--space-sm)}.icon-btn[_ngcontent-%COMP%]{width:32px;height:32px;display:flex;align-items:center;justify-content:center;border-radius:var(--radius-sm);border:none;background:none;cursor:pointer;font-size:16px}.icon-btn[_ngcontent-%COMP%]:hover{background:var(--bg-elevated)}"]})};var yn=Br("settings"),fa=oe(yn,e=>e),XV=oe(yn,e=>e.targetUrl),Xg=oe(yn,e=>e.settingsPanelOpen),em=oe(yn,e=>e.activeTab),tm=oe(yn,e=>e.sidebarWidth),nm=oe(yn,e=>({targetUrl:e.targetUrl,windowWidth:e.windowWidth,windowHeight:e.windowHeight,headless:e.headless,devtools:e.devtools,keepBrowserOpen:e.keepBrowserOpen,actionDelay:e.actionDelay,browserPath:e.browserPath||void 0,userDataDir:e.userDataDir||void 0}));var Pt=class e{constructor(t){this.http=t}baseUrl="/api";getDetectedBrowsers(){return this.http.get(`${this.baseUrl}/config/browsers`)}getProfiles(t){return this.http.get(`${this.baseUrl}/config/profiles`,{params:{userDataDir:t}})}getJourneys(){return this.http.get(`${this.baseUrl}/journeys`)}runTests(t,n){return this.http.post(`${this.baseUrl}/tests/run`,{journeys:t,config:n})}stopTests(){return this.http.post(`${this.baseUrl}/tests/stop`,{})}pauseTests(){return this.http.post(`${this.baseUrl}/tests/pause`,{})}resumeTests(){return this.http.post(`${this.baseUrl}/tests/resume`,{})}stepTests(t=1){return this.http.post(`${this.baseUrl}/tests/step`,{count:t})}setBreakpoints(t,n){return this.http.post(`${this.baseUrl}/breakpoints`,{journey:t,breakpoints:n})}getBreakpoints(t){return this.http.get(`${this.baseUrl}/breakpoints/${t}`)}clearBreakpoints(t){return this.http.delete(`${this.baseUrl}/breakpoints/${t}`)}updateConfig(t){return this.http.patch(`${this.baseUrl}/config`,t)}getSettings(){return this.http.get(`${this.baseUrl}/settings`)}saveSettings(t){return this.http.put(`${this.baseUrl}/settings`,t)}static \u0275fac=function(n){return new(n||e)(b(ia))};static \u0275prov=T({token:e,factory:e.\u0275fac,providedIn:"root"})};var aI=(e,t)=>t.executablePath,cI=(e,t)=>t.path;function uI(e,t){if(e&1){let n=Je();m(0,"div",45)(1,"button",46),G("mousedown",function(){let o=K(n).$implicit,i=$(3);return X(i.selectUrl(o))}),D(2),y(),m(3,"button",47),G("mousedown",function(o){let i=K(n).$implicit,s=$(3);return X(s.deleteUrl(i,o))}),D(4,"\u2715"),y()()}if(e&2){let n=t.$implicit;S(2),we(n)}}function lI(e,t){if(e&1&&(m(0,"div",9),vt(1,uI,5,1,"div",45,ml),y()),e&2){let n=$();S(),Et(n.targetUrlHistory)}}function dI(e,t){if(e&1&&(m(0,"option",11),D(1),y()),e&2){let n=t.$implicit;ae("value",n.executablePath),S(),we(n.name)}}function fI(e,t){if(e&1){let n=Je();m(0,"label",4),Rt(1,"span",5),m(2,"input",48),G("change",function(o){K(n);let i=$(2);return X(i.updateSetting("browserPath",o))}),y()()}if(e&2){let n=$();S(2),ae("value",n.browserPath)}}function pI(e,t){if(e&1&&(m(0,"option",15),D(1),y()),e&2){let n=t.$implicit,r=$();ae("value",n.path)("selected",n.path===r.userDataDir),S(),zs("",n.name," (",n.directory,")")}}function hI(e,t){if(e&1){let n=Je();m(0,"aside",2)(1,"div",3)(2,"label",4)(3,"span",5),D(4,"URL"),y(),m(5,"div",6)(6,"input",7),G("change",function(o){K(n);let i=$();return X(i.updateSetting("targetUrl",o))})("focus",function(){K(n);let o=$();return X(o.urlDropdownOpen.set(!0))})("blur",function(o){K(n);let i=$();return X(i.onUrlBlur(o))}),y(),m(7,"span",8),G("mousedown",function(){K(n);let o=$();return X(o.urlDropdownOpen.set(!o.urlDropdownOpen()))}),y(),ie(8,lI,3,0,"div",9),y()(),m(9,"label",4)(10,"span",5),D(11,"Browser"),y(),m(12,"select",10),G("change",function(o){K(n);let i=$();return X(i.selectBrowser(o))}),vt(13,dI,2,2,"option",11,aI),m(15,"option",12),D(16,"Custom path..."),y()()(),ie(17,fI,3,1,"label",4),m(18,"label",4)(19,"span",5),D(20,"Profile"),y(),m(21,"select",13),G("change",function(o){K(n);let i=$();return X(i.selectProfile(o))}),m(22,"option",14),D(23,"Temp (isolated)"),y(),vt(24,pI,2,4,"option",15,cI),y()()(),m(26,"div",16)(27,"label",17)(28,"span",5),D(29,"Window size"),y(),m(30,"select",18),G("change",function(o){K(n);let i=$();return X(i.applyWindowSizePreset(o))}),m(31,"option",19),D(32,"Custom"),y(),m(33,"optgroup",20)(34,"option",21),D(35,"2560\xD71440 (QHD)"),y(),m(36,"option",22),D(37,"1920\xD71080 (Full HD)"),y(),m(38,"option",23),D(39,"1680\xD71050"),y(),m(40,"option",24),D(41,"1536\xD7864"),y(),m(42,"option",25),D(43,"1440\xD7900 (MacBook Air)"),y(),m(44,"option",26),D(45,"1366\xD7768"),y(),m(46,"option",27),D(47,"1280\xD7800"),y(),m(48,"option",28),D(49,"1280\xD7720 (HD)"),y(),m(50,"option",29),D(51,"1024\xD7768"),y()(),m(52,"optgroup",30)(53,"option",31),D(54,"1024\xD71366 (iPad Pro 12.9)"),y(),m(55,"option",32),D(56,"820\xD71180 (iPad Air)"),y(),m(57,"option",33),D(58,"768\xD71024 (iPad Mini)"),y()(),m(59,"optgroup",34)(60,"option",35),D(61,"430\xD7932 (iPhone 15 Pro Max)"),y(),m(62,"option",36),D(63,"393\xD7852 (iPhone 15)"),y(),m(64,"option",37),D(65,"390\xD7844 (iPhone 14)"),y(),m(66,"option",38),D(67,"375\xD7667 (iPhone SE)"),y(),m(68,"option",39),D(69,"360\xD7800 (Android)"),y()()(),m(70,"span",40)(71,"input",41),G("change",function(o){K(n);let i=$();return X(i.updateSetting("windowWidth",o))}),y(),m(72,"span",42),D(73,"\xD7"),y(),m(74,"input",41),G("change",function(o){K(n);let i=$();return X(i.updateSetting("windowHeight",o))}),y()()(),m(75,"label",43)(76,"input",44),G("change",function(o){K(n);let i=$();return X(i.updateSetting("devtools",o))}),y(),D(77," DevTools "),y(),m(78,"label",43)(79,"input",44),G("change",function(o){K(n);let i=$();return X(i.updateSetting("headed",o))}),y(),D(80," Headed "),y(),m(81,"label",43)(82,"input",44),G("change",function(o){K(n);let i=$();return X(i.updateSetting("keepBrowserOpen",o))}),y(),D(83," Keep open "),y()()()}if(e&2){let n,r=t,o=$();S(6),ae("value",r.targetUrl),S(2),se(o.urlDropdownOpen()&&r.targetUrlHistory.length>0?8:-1),S(4),ae("value",r.browserPath||((n=o.detectedBrowsers()[0])==null?null:n.executablePath)),S(),Et(o.detectedBrowsers()),S(4),se(o.showCustomBrowserInput()?17:-1),S(5),ae("selected",!r.userDataDir),S(2),Et(o.availableProfiles()),S(47),ae("value",r.windowWidth),S(3),ae("value",r.windowHeight),S(2),ae("checked",r.devtools),S(3),ae("checked",!r.headless),S(3),ae("checked",r.keepBrowserOpen)}}var pa=class e{store=g(Z);api=g(Pt);destroyRef=g(Be);isOpen=ng(!1);settings$=this.store.select(fa);detectedBrowsers=gt([]);availableProfiles=gt([]);showCustomBrowserInput=gt(!1);urlDropdownOpen=gt(!1);detectedBrowserPath="";detectedUserDataDir="";ngOnInit(){this.api.getDetectedBrowsers().pipe(he(t=>t.length>0),lt(t=>{this.detectedBrowsers.set(t),this.detectedBrowserPath=t[0].executablePath,this.detectedUserDataDir=t[0].userDataDir})).subscribe(),Kt([this.settings$.pipe(L(t=>t.browserPath),dr()),this.api.getDetectedBrowsers()]).pipe(xg(this.destroyRef),he(([t,n])=>t!==""&&n.length>0),ge(([t,n])=>{let r=n.find(o=>o.executablePath===t);return r?this.api.getProfiles(r.userDataDir):ut([])}),lt(t=>this.availableProfiles.set(t))).subscribe()}updateSetting(t,n){let r=n.target,o=r.type==="checkbox"?r.checked:r.type==="number"?parseInt(r.value,10):r.value;if(t==="headed"){this.store.dispatch(U.updateSetting({key:"headless",value:!o}));return}this.store.dispatch(U.updateSetting({key:t,value:o}))}selectBrowser(t){let n=t.target.value;if(n==="custom"){this.showCustomBrowserInput.set(!0);return}this.showCustomBrowserInput.set(!1),this.store.dispatch(U.updateSetting({key:"browserPath",value:n})),this.store.dispatch(U.updateSetting({key:"userDataDir",value:""}))}selectProfile(t){let n=t.target.value;this.store.dispatch(U.updateSetting({key:"userDataDir",value:n}))}applyWindowSizePreset(t){let n=t.target.value;if(!n)return;let[r,o]=n.split("x").map(Number);this.store.dispatch(U.updateSetting({key:"windowWidth",value:r})),this.store.dispatch(U.updateSetting({key:"windowHeight",value:o}))}selectUrl(t){this.store.dispatch(U.updateSetting({key:"targetUrl",value:t})),this.urlDropdownOpen.set(!1)}deleteUrl(t,n){n.preventDefault(),n.stopPropagation(),this.store.dispatch(U.removeUrlFromHistory({url:t}))}onUrlBlur(t){t.relatedTarget?.closest(".url-dropdown")||this.urlDropdownOpen.set(!1)}static \u0275fac=function(n){return new(n||e)};static \u0275cmp=Se({type:e,selectors:[["gb-settings-panel"]],inputs:{isOpen:[1,"isOpen"]},decls:4,vars:4,consts:[[1,"settings-collapse"],[1,"settings-inner"],[1,"settings-panel"],[1,"settings-paths"],[1,"setting-row"],[1,"setting-label"],[1,"url-combo"],["type","text","placeholder","http://localhost:3000",1,"input-full","input-combo",3,"change","focus","blur","value"],[1,"url-combo__arrow",3,"mousedown"],[1,"url-dropdown"],[1,"input-full",3,"change","value"],[3,"value"],["value","custom"],[1,"input-full",3,"change"],["value","",3,"selected"],[3,"value","selected"],[1,"settings-options"],[1,"setting"],[1,"input-select",3,"change"],["value",""],["label","Desktop"],["value","2560x1440"],["value","1920x1080"],["value","1680x1050"],["value","1536x864"],["value","1440x900"],["value","1366x768"],["value","1280x800"],["value","1280x720"],["value","1024x768"],["label","Tablet"],["value","1024x1366"],["value","820x1180"],["value","768x1024"],["label","Mobile"],["value","430x932"],["value","393x852"],["value","390x844"],["value","375x667"],["value","360x800"],[1,"window-inputs"],["type","number",1,"input-num",3,"change","value"],[1,"muted"],[1,"setting","checkbox"],["type","checkbox",3,"change","checked"],[1,"url-dropdown__item"],[1,"url-dropdown__select",3,"mousedown"],["title","Remove",1,"url-dropdown__delete",3,"mousedown"],["type","text","placeholder","Full path to browser executable",1,"input-full",3,"change","value"]],template:function(n,r){if(n&1&&(m(0,"div",0)(1,"div",1),ie(2,hI,84,10,"aside",2),W(3,"async"),y()()),n&2){let o;Ye("data-open",r.isOpen()||null),S(2),se((o=q(3,2,r.settings$))?2:-1,o)}},dependencies:[ke,$e],styles:[`.settings-collapse{display:grid;grid-template-rows:0fr;transition:grid-template-rows .2s ease}.settings-collapse[data-open]{grid-template-rows:1fr}.settings-inner{overflow:hidden;min-height:0}.settings-panel{display:flex;flex-direction:column;gap:var(--space-sm);padding:var(--space-md);background:var(--bg-surface);border-bottom:1px solid var(--border-color);font-size:12px}.settings-paths{display:flex;flex-direction:column;gap:var(--space-xs);max-width:700px;min-width:400px}.setting-row{display:grid;grid-template-columns:60px 1fr;align-items:center;gap:var(--space-sm)}.settings-options{display:flex;align-items:center;gap:var(--space-lg);padding-top:var(--space-xs)}.setting{display:flex;align-items:center;gap:6px;color:var(--text-secondary)}.setting-label{color:var(--text-muted);white-space:nowrap;font-size:12px}.checkbox{cursor:pointer}.window-inputs{display:flex;align-items:center;gap:4px}.muted{color:var(--text-muted)}.input-full{width:100%;padding:4px 8px;background:var(--bg-panel);border:1px solid var(--border-color);border-radius:3px;color:var(--text-primary);font-size:12px;font-family:var(--font-mono)}select.input-full{appearance:none;-webkit-appearance:none;padding-right:28px;background:var(--bg-panel) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5'%3E%3Cpath d='M0 0l4 5 4-5z' fill='%237d8590'/%3E%3C/svg%3E") no-repeat right 10px center;cursor:pointer;font-family:var(--font-sans)}.url-combo{position:relative;width:100%}.url-combo .input-combo{padding-right:28px;background:var(--bg-panel) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5'%3E%3Cpath d='M0 0l4 5 4-5z' fill='%237d8590'/%3E%3C/svg%3E") no-repeat right 10px center}.url-combo__arrow{position:absolute;right:0;top:0;bottom:0;width:28px;cursor:pointer;pointer-events:auto}.url-dropdown{position:absolute;top:100%;left:0;right:0;z-index:10;background:var(--bg-surface);border:1px solid var(--border-color);border-radius:var(--radius-sm);box-shadow:var(--shadow-md);max-height:160px;overflow-y:auto}.url-dropdown__item{display:flex;align-items:center;border-bottom:1px solid var(--border-color)}.url-dropdown__item:last-child{border-bottom:none}.url-dropdown__select{flex:1;padding:6px 8px;text-align:left;font-size:12px;font-family:var(--font-mono);color:var(--text-primary);background:none;border:none;cursor:pointer}.url-dropdown__select:hover{background:var(--bg-elevated)}.url-dropdown__delete{padding:4px 8px;color:var(--text-muted);font-size:11px;background:none;border:none;cursor:pointer}.url-dropdown__delete:hover{color:var(--color-danger)}.input-num{width:56px;padding:4px 6px;background:var(--bg-panel);border:1px solid var(--border-color);border-radius:3px;color:var(--text-primary);font-size:12px}.input-select{appearance:none;-webkit-appearance:none;padding:4px 28px 4px 8px;background:var(--bg-panel) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5'%3E%3Cpath d='M0 0l4 5 4-5z' fill='%237d8590'/%3E%3C/svg%3E") no-repeat right 10px center;border:1px solid var(--border-color);border-radius:3px;color:var(--text-primary);font-size:12px;cursor:pointer}
|
|
9
9
|
`],encapsulation:2})};var Gl=Br("journeys"),ha=oe(Gl,e=>e.journeys),$r=oe(Gl,e=>e.selectedIds),Wl=oe(ha,$r,(e,t)=>e.filter(n=>t.includes(n.id)).map(n=>n.path)),m$=oe(Gl,e=>e.loading);var Yt=Br("execution"),Ko=oe(Yt,e=>e.fsmState),ga=oe(Yt,e=>e.actions),ma=oe(Yt,e=>e.consoleLogs),rm=oe(Yt,e=>e.connectionStatus),om=oe(Yt,e=>e.results.reduce((t,n)=>(n.status==="passed"?t.passed++:n.status==="failed"&&t.failed++,t),{passed:0,failed:0,skipped:0})),im=oe(Ko,e=>({fsmState:e,canPlay:e==="idle"||e==="completed"||e==="errored",canPause:e==="running",canResume:e==="paused",canStep:e==="paused",canStop:e==="running"||e==="paused"||e==="stepping"})),ya=oe(Yt,e=>e.breakpointsByJourney[e.currentJourney??""]??[]),sm=oe(Yt,e=>e.currentJourney),am=oe(Yt,e=>{let t={};return e.results.forEach(n=>{t[n.journey]=n.status}),t}),cm=oe(Yt,e=>{let t=e.consoleLogs.filter(n=>n.type==="error");return t.length>0?t[t.length-1].message:null});var Me=jr({source:"Journeys",events:{"Load Journeys":ye(),"Load Journeys Success":Te(),"Toggle Journey":Te(),"Select All":ye(),"Deselect All":ye()}});var gI=(e,t)=>t.id;function mI(e,t){e&1&&Rt(0,"span",12)}function yI(e,t){e&1&&D(0," \u2713 ")}function vI(e,t){e&1&&D(0," \u2717 ")}function EI(e,t){if(e&1){let n=Je();m(0,"li",8)(1,"label",4)(2,"input",9),G("change",function(){let o=K(n).$implicit,i=$();return X(i.toggleJourney(o.id))}),y(),m(3,"span",10),D(4),y(),m(5,"span",11),ie(6,mI,1,0,"span",12)(7,yI,1,0)(8,vI,1,0),y()()()}if(e&2){let n,r=t.$implicit;Ye("data-status",r.status),S(2),ae("checked",r.selected),S(2),we(r.name),S(2),se((n=r.status)==="running"?6:n==="passed"?7:n==="failed"?8:-1)}}var va=class e{constructor(t){this.store=t}journeyViews$;selectAllState$;ngOnInit(){this.store.dispatch(Me.loadJourneys()),this.selectAllState$=Kt([this.store.select(ha),this.store.select($r)]).pipe(L(([t,n])=>t.length===0||n.length===0?"none":n.length===t.length?"all":"indeterminate")),this.journeyViews$=Kt([this.store.select(ha),this.store.select($r),this.store.select(sm),this.store.select(am)]).pipe(L(([t,n,r,o])=>t.map(i=>C(E({},i),{selected:n.includes(i.id),status:this.getJourneyStatus(i.path,r,o)}))))}toggleAll(){return Qe(this,null,function*(){let t=yield Vt(this.selectAllState$);this.store.dispatch(t==="all"?Me.deselectAll():Me.selectAll())})}toggleJourney(t){this.store.dispatch(Me.toggleJourney({id:t}))}getJourneyStatus(t,n,r){return n===t?"running":r[t]?r[t]:"idle"}static \u0275fac=function(n){return new(n||e)(de(Z))};static \u0275cmp=Se({type:e,selectors:[["gb-sidebar"]],decls:15,vars:8,consts:[[1,"sidebar"],[1,"sidebar-header"],[1,"sidebar-title"],[1,"select-all-row"],[1,"journey-label"],["type","checkbox",3,"change","checked","indeterminate"],[1,"journey-name","select-all-label"],[1,"journey-list"],[1,"journey-item"],["type","checkbox",3,"change","checked"],[1,"journey-name"],[1,"journey-status-icon"],[1,"spinner"]],template:function(n,r){n&1&&(m(0,"nav",0)(1,"div",1)(2,"span",2),D(3,"Journeys"),y()(),m(4,"div",3)(5,"label",4)(6,"input",5),W(7,"async"),W(8,"async"),G("change",function(){return r.toggleAll()}),y(),m(9,"span",6),D(10,"Select all"),y()()(),m(11,"ul",7),vt(12,EI,9,4,"li",8,gI),W(14,"async"),y()()),n&2&&(S(6),ae("checked",q(7,2,r.selectAllState$)==="all")("indeterminate",q(8,4,r.selectAllState$)==="indeterminate"),S(6),Et(q(14,6,r.journeyViews$)))},dependencies:[ke,$e],styles:[`gb-sidebar .sidebar{background:var(--bg-panel);border-right:1px solid var(--border-color);overflow-y:auto;height:100%}gb-sidebar .sidebar-header{padding:var(--space-md);border-bottom:1px solid var(--border-color)}gb-sidebar .sidebar-title{font-weight:600;font-size:11px;text-transform:uppercase;letter-spacing:.5px;color:var(--text-muted)}gb-sidebar .select-all-row{border-bottom:1px solid var(--border-color)}gb-sidebar .select-all-label{font-size:12px;color:var(--text-secondary)}gb-sidebar .journey-list{list-style:none}gb-sidebar .journey-item{border-bottom:1px solid var(--border-color)}gb-sidebar .journey-item[data-status=running]{background:var(--bg-elevated)}gb-sidebar .journey-item[data-status=passed] .journey-status-icon{color:var(--color-success)}gb-sidebar .journey-item[data-status=failed] .journey-status-icon{color:var(--color-danger)}gb-sidebar .journey-label{display:flex;align-items:center;gap:var(--space-sm);padding:var(--space-sm) var(--space-md);cursor:pointer;font-size:13px}gb-sidebar .journey-label:hover{background:var(--bg-surface)}gb-sidebar .journey-name{flex:1}gb-sidebar .journey-status-icon{font-size:12px;width:16px;height:16px;display:inline-flex;align-items:center;justify-content:center}gb-sidebar .journey-item[data-status=running] .journey-status-icon{animation:none}gb-sidebar .spinner{width:10px;height:10px;border:2px solid var(--border-color);border-top-color:var(--accent-primary);border-radius:50%;animation:spin .8s linear infinite}@keyframes spin{to{transform:rotate(360deg)}}@keyframes flip{0%,60%{transform:rotate(0)}70%{transform:rotate(180deg)}80%{transform:rotate(180deg)}90%{transform:rotate(360deg)}to{transform:rotate(360deg)}}
|
|
10
10
|
`],encapsulation:2})};var x=jr({source:"Execution",events:{Play:ye(),Pause:ye(),Resume:ye(),Step:ye(),Stop:ye(),"Update Config":Te(),"Action Received":Te(),"Test Started":Te(),"Test Ended":Te(),"Log Received":Te(),"Error Received":Te(),"Paused By Runner":ye(),"Resumed By Runner":ye(),"Connection Status Changed":Te(),"Run Ended":ye(),"Toggle Breakpoint":Te(),"Clear All Breakpoints":ye(),"Clear Actions":ye(),"Clear Console":ye()}});function DI(e,t){if(e&1){let n=Je();m(0,"button",7),G("click",function(){let o=K(n),i=$();return X(o.canPlay?i.play():i.resume())}),D(1,"\u25B6"),y(),m(2,"button",8),G("click",function(){K(n);let o=$();return X(o.pause())}),D(3,"\u23F8"),y(),m(4,"button",9),G("click",function(){K(n);let o=$();return X(o.step())}),D(5,"\u23ED"),y(),m(6,"button",10),G("click",function(){K(n);let o=$();return X(o.stop())}),D(7,"\u23F9"),y()}if(e&2){let n=t;ae("disabled",!n.canPlay&&!n.canResume)("title",n.canResume?"Resume":"Run"),S(2),ae("disabled",!n.canPause),S(2),ae("disabled",!n.canStep),S(2),ae("disabled",!n.canStop)}}var Ea=class e{constructor(t){this.store=t;this.state$=this.store.select(im),this.settings$=this.store.select(yn)}state$;settings$;play(){this.store.dispatch(x.play())}pause(){this.store.dispatch(x.pause())}resume(){this.store.dispatch(x.resume())}step(){this.store.dispatch(x.step())}stop(){this.store.dispatch(x.stop())}onDelayChange(t){let n=parseInt(t.target.value,10),r=this.sliderToDelay(n);this.store.dispatch(U.updateSetting({key:"actionDelay",value:r})),this.store.dispatch(x.updateConfig({actionDelay:r}))}delayToSlider(t){return Math.round(Math.sqrt(t/5e3)*100)}sliderToDelay(t){return Math.round((t/100)**2*5e3)}static \u0275fac=function(n){return new(n||e)(de(Z))};static \u0275cmp=Se({type:e,selectors:[["gb-toolbar"]],decls:15,vars:12,consts:[[1,"gb-toolbar"],[1,"gb-toolbar__controls"],[1,"gb-toolbar__slider"],[1,"gb-toolbar__slider-label"],["type","range","min","0","max","100",3,"input","value"],[1,"gb-toolbar__slider-value"],[1,"gb-toolbar__state"],[1,"gb-toolbar__btn","gb-toolbar__btn--play",3,"click","disabled","title"],["title","Pause",1,"gb-toolbar__btn",3,"click","disabled"],["title","Step",1,"gb-toolbar__btn",3,"click","disabled"],["title","Stop",1,"gb-toolbar__btn","gb-toolbar__btn--stop",3,"click","disabled"]],template:function(n,r){if(n&1&&(m(0,"div",0)(1,"div",1),ie(2,DI,8,5),W(3,"async"),y(),m(4,"div",2)(5,"label",3),D(6,"Delay"),y(),m(7,"input",4),W(8,"async"),G("input",function(i){return r.onDelayChange(i)}),y(),m(9,"span",5),D(10),W(11,"async"),y()(),m(12,"span",6),D(13),W(14,"async"),y()()),n&2){let o,i,s,a;S(2),se((o=q(3,4,r.state$))?2:-1,o),S(5),ae("value",r.delayToSlider(((i=q(8,6,r.settings$))==null?null:i.actionDelay)??0)),S(3),it("",((s=q(11,8,r.settings$))==null?null:s.actionDelay)??0,"ms"),S(3),we((a=q(14,10,r.state$))==null?null:a.fsmState)}},dependencies:[ke,$e],styles:[`gb-toolbar .gb-toolbar{display:flex;align-items:center;justify-content:space-between;padding:var(--space-sm) var(--space-md);background:var(--bg-panel);border-bottom:1px solid var(--border-color)}gb-toolbar .gb-toolbar__controls{display:flex;gap:var(--space-xs)}gb-toolbar .gb-toolbar__btn{width:32px;height:32px;display:flex;align-items:center;justify-content:center;border-radius:var(--radius-sm);border:none;background:none;font-size:14px;cursor:pointer;color:var(--text-primary)}gb-toolbar .gb-toolbar__btn:hover:not(:disabled){background:var(--bg-elevated)}gb-toolbar .gb-toolbar__btn:disabled{opacity:.3;cursor:not-allowed}gb-toolbar .gb-toolbar__btn--play{color:var(--color-success)}gb-toolbar .gb-toolbar__btn--stop{color:var(--color-danger)}gb-toolbar .gb-toolbar__slider{display:flex;align-items:center;gap:var(--space-sm);flex:1;margin-left:var(--space-md);padding-left:var(--space-md);border-left:1px solid var(--border-color)}gb-toolbar .gb-toolbar__slider-label{font-size:12px;color:var(--text-muted)}gb-toolbar .gb-toolbar__slider-value{font-size:12px;color:var(--text-secondary);font-family:var(--font-mono);min-width:50px}gb-toolbar input[type=range]{flex:1;accent-color:var(--accent-primary);margin:0;padding:0}gb-toolbar .gb-toolbar__state{font-size:12px;color:var(--text-muted);font-family:var(--font-mono);margin-left:var(--space-md)}
|
|
11
|
-
`],encapsulation:2})};var bI=["scrollContainer"],wI=(e,t)=>t.index;function CI(e,t){if(e&1&&(m(0,"span",7),D(1),y()),e&2){let n=$().$implicit;S(),it("\u2192 ",n.result)}}function II(e,t){e&1&&D(0," \u23F3 ")}function _I(e,t){e&1&&D(0," \u2713 ")}function SI(e,t){e&1&&D(0," \u23F8 ")}function TI(e,t){e&1&&D(0," \u2717 ")}function MI(e,t){if(e&1){let n=Je();m(0,"div",2)(1,"button",4),G("click",function(){let o=K(n).$implicit,i=$();return X(i.toggleBreakpoint(o.index))}),y(),m(2,"span",5),D(3),y(),m(4,"span",6),D(5),y(),ie(6,CI,2,1,"span",7),m(7,"span",8),ie(8,II,1,0)(9,_I,1,0)(10,SI,1,0)(11,TI,1,0),y()()}if(e&2){let n,r=t.$implicit;Ye("data-status",r.status),S(),Ye("aria-label",yl("Toggle breakpoint at action ",r.index))("data-active",r.hasBreakpoint||null),S(2),we(r.index),S(2),we(r.description),S(),se(r.result!==void 0?6:-1),S(2),se((n=r.status)==="running"?8:n==="complete"?9:n==="breakpoint"?10:n==="failed"?11:-1)}}function xI(e,t){e&1&&(m(0,"div",3),D(1," No actions yet. Run a journey to see the action log. "),y())}var Da=class e{constructor(t){this.store=t;this.actionsWithBreakpoints$=Kt([this.store.select(ga),this.store.select(ya)]).pipe(L(([n,r])=>n.map(o=>C(E({},o),{hasBreakpoint:r.includes(o.index)}))))}scrollContainer;actionsWithBreakpoints$;lastActionCount=0;shouldAutoScroll=!0;ngAfterViewChecked(){let t=this.scrollContainer?.nativeElement;if(!t)return;let n=t.scrollHeight-t.scrollTop-t.clientHeight<60,r=t.querySelectorAll(".action-item");r.length!==this.lastActionCount&&(r.length<this.lastActionCount&&(this.shouldAutoScroll=!0),(this.shouldAutoScroll||n)&&(t.scrollTop=t.scrollHeight,this.shouldAutoScroll=!0),this.lastActionCount=r.length),!n&&r.length===this.lastActionCount&&(this.shouldAutoScroll=!1)}toggleBreakpoint(t){this.store.dispatch(x.toggleBreakpoint({index:t}))}static \u0275fac=function(n){return new(n||e)(de(Z))};static \u0275cmp=Se({type:e,selectors:[["gb-action-log"]],viewQuery:function(n,r){if(n&1&&Rr(bI,5),n&2){let o;Fo(o=Po())&&(r.scrollContainer=o.first)}},decls:7,vars:5,consts:[["scrollContainer",""],[1,"action-log"],[1,"action-item"],[1,"empty-state"],["title","Toggle breakpoint",1,"bp-pin",3,"click"],[1,"action-index"],[1,"action-description"],[1,"action-result"],[1,"action-status-icon"]],template:function(n,r){if(n&1&&(m(0,"div",1,0),vt(2,MI,12,8,"div",2,wI),W(4,"async"),ie(5,xI,2,0,"div",3),W(6,"async"),y()),n&2){let o;S(2),Et(q(4,1,r.actionsWithBreakpoints$)),S(3),se(((o=q(6,3,r.actionsWithBreakpoints$))==null?null:o.length)===0?5:-1)}},dependencies:[ke,$e],styles:[`gb-action-log .action-log{padding:var(--space-sm);font-family:var(--font-mono);font-size:13px;overflow-y:auto;height:100%}gb-action-log .action-item{display:flex;align-items:center;gap:var(--space-sm);padding:var(--space-xs) var(--space-sm);border-radius:var(--radius-sm)}gb-action-log .action-item[data-status=running]{background:var(--bg-elevated);color:var(--accent-primary)}gb-action-log .action-item[data-status=complete]{color:var(--text-secondary)}gb-action-log .action-item[data-status=failed]{color:var(--color-danger)}gb-action-log .action-item[data-status=breakpoint]{color:var(--color-breakpoint);background:#f8514914}gb-action-log .bp-pin{width:12px;height:12px;border-radius:50%;border:1.5px solid var(--border-color);flex-shrink:0;cursor:pointer;background:transparent;transition:background .1s,border-color .1s}gb-action-log .bp-pin:hover{border-color:var(--color-breakpoint);background:#f851494d}gb-action-log .bp-pin[data-active]{background:var(--color-breakpoint);border-color:var(--color-breakpoint)}gb-action-log .action-index{color:var(--text-muted);min-width:28px;text-align:right}gb-action-log .action-description{
|
|
11
|
+
`],encapsulation:2})};var bI=["scrollContainer"],wI=(e,t)=>t.index;function CI(e,t){if(e&1&&(m(0,"span",7),D(1),y()),e&2){let n=$().$implicit;S(),it("\u2192 ",n.result)}}function II(e,t){e&1&&D(0," \u23F3 ")}function _I(e,t){e&1&&D(0," \u2713 ")}function SI(e,t){e&1&&D(0," \u23F8 ")}function TI(e,t){e&1&&D(0," \u2717 ")}function MI(e,t){if(e&1){let n=Je();m(0,"div",2)(1,"button",4),G("click",function(){let o=K(n).$implicit,i=$();return X(i.toggleBreakpoint(o.index))}),y(),m(2,"span",5),D(3),y(),m(4,"span",6),D(5),y(),ie(6,CI,2,1,"span",7),m(7,"span",8),ie(8,II,1,0)(9,_I,1,0)(10,SI,1,0)(11,TI,1,0),y()()}if(e&2){let n,r=t.$implicit;Ye("data-status",r.status),S(),Ye("aria-label",yl("Toggle breakpoint at action ",r.index))("data-active",r.hasBreakpoint||null),S(2),we(r.index),S(2),we(r.description),S(),se(r.result!==void 0?6:-1),S(2),se((n=r.status)==="running"?8:n==="complete"?9:n==="breakpoint"?10:n==="failed"?11:-1)}}function xI(e,t){e&1&&(m(0,"div",3),D(1," No actions yet. Run a journey to see the action log. "),y())}var Da=class e{constructor(t){this.store=t;this.actionsWithBreakpoints$=Kt([this.store.select(ga),this.store.select(ya)]).pipe(L(([n,r])=>n.map(o=>C(E({},o),{hasBreakpoint:r.includes(o.index)}))))}scrollContainer;actionsWithBreakpoints$;lastActionCount=0;shouldAutoScroll=!0;ngAfterViewChecked(){let t=this.scrollContainer?.nativeElement;if(!t)return;let n=t.scrollHeight-t.scrollTop-t.clientHeight<60,r=t.querySelectorAll(".action-item");r.length!==this.lastActionCount&&(r.length<this.lastActionCount&&(this.shouldAutoScroll=!0),(this.shouldAutoScroll||n)&&(t.scrollTop=t.scrollHeight,this.shouldAutoScroll=!0),this.lastActionCount=r.length),!n&&r.length===this.lastActionCount&&(this.shouldAutoScroll=!1)}toggleBreakpoint(t){this.store.dispatch(x.toggleBreakpoint({index:t}))}static \u0275fac=function(n){return new(n||e)(de(Z))};static \u0275cmp=Se({type:e,selectors:[["gb-action-log"]],viewQuery:function(n,r){if(n&1&&Rr(bI,5),n&2){let o;Fo(o=Po())&&(r.scrollContainer=o.first)}},decls:7,vars:5,consts:[["scrollContainer",""],[1,"action-log"],[1,"action-item"],[1,"empty-state"],["title","Toggle breakpoint",1,"bp-pin",3,"click"],[1,"action-index"],[1,"action-description"],[1,"action-result"],[1,"action-status-icon"]],template:function(n,r){if(n&1&&(m(0,"div",1,0),vt(2,MI,12,8,"div",2,wI),W(4,"async"),ie(5,xI,2,0,"div",3),W(6,"async"),y()),n&2){let o;S(2),Et(q(4,1,r.actionsWithBreakpoints$)),S(3),se(((o=q(6,3,r.actionsWithBreakpoints$))==null?null:o.length)===0?5:-1)}},dependencies:[ke,$e],styles:[`gb-action-log .action-log{padding:var(--space-sm);font-family:var(--font-mono);font-size:13px;overflow-y:auto;height:100%}gb-action-log .action-item{display:flex;align-items:center;gap:var(--space-sm);padding:var(--space-xs) var(--space-sm);border-radius:var(--radius-sm)}gb-action-log .action-item[data-status=running]{background:var(--bg-elevated);color:var(--accent-primary)}gb-action-log .action-item[data-status=complete]{color:var(--text-secondary)}gb-action-log .action-item[data-status=failed]{color:var(--color-danger)}gb-action-log .action-item[data-status=breakpoint]{color:var(--color-breakpoint);background:#f8514914}gb-action-log .bp-pin{width:12px;height:12px;border-radius:50%;border:1.5px solid var(--border-color);flex-shrink:0;cursor:pointer;background:transparent;transition:background .1s,border-color .1s}gb-action-log .bp-pin:hover{border-color:var(--color-breakpoint);background:#f851494d}gb-action-log .bp-pin[data-active]{background:var(--color-breakpoint);border-color:var(--color-breakpoint)}gb-action-log .action-index{color:var(--text-muted);min-width:28px;text-align:right}gb-action-log .action-description{white-space:nowrap}gb-action-log .action-result{flex:1;color:var(--text-muted);font-weight:600;margin-left:var(--space-xs)}gb-action-log .action-status-icon{width:20px;text-align:center}gb-action-log .empty-state{padding:var(--space-xl);text-align:center;color:var(--text-muted);font-family:var(--font-sans)}
|
|
12
12
|
`],encapsulation:2})};var NI=["scrollContainer"],AI=(e,t)=>t.timestamp;function RI(e,t){if(e&1&&(m(0,"div",3),D(1),y()),e&2){let n=$().$implicit;S(),it("\u2500\u2500 ",n.message," \u2500\u2500")}}function OI(e,t){if(e&1&&(m(0,"div",4),D(1),y()),e&2){let n=$().$implicit;Ye("data-type",n.type),S(),we(n.message)}}function kI(e,t){if(e&1&&ie(0,RI,2,1,"div",3)(1,OI,2,2,"div",4),e&2){let n=t.$implicit;se(n.type==="separator"?0:1)}}function FI(e,t){e&1&&(m(0,"div",2),D(1,"Console output will appear here."),y())}var ba=class e{constructor(t,n){this.store=t;this.injector=n;this.logs$=this.store.select(ma),this.subscription=this.logs$.pipe(nc(),he(([r,o])=>o.length>r.length&&this.isAtBottom),lt(()=>{rl(()=>this.scrollToBottom(),{injector:this.injector})})).subscribe()}scrollContainer;logs$;isAtBottom=!0;subscription;ngOnDestroy(){this.subscription.unsubscribe()}onScroll(){if(!this.scrollContainer)return;let t=this.scrollContainer.nativeElement;this.isAtBottom=t.scrollHeight-t.scrollTop-t.clientHeight<20}scrollToBottom(){if(!this.scrollContainer)return;let t=this.scrollContainer.nativeElement;t.scrollTop=t.scrollHeight}static \u0275fac=function(n){return new(n||e)(de(Z),de(Ie))};static \u0275cmp=Se({type:e,selectors:[["gb-console-output"]],viewQuery:function(n,r){if(n&1&&Rr(NI,5),n&2){let o;Fo(o=Po())&&(r.scrollContainer=o.first)}},decls:7,vars:5,consts:[["scrollContainer",""],[1,"gb-console",3,"scroll"],[1,"gb-empty-state"],[1,"gb-console__separator"],[1,"gb-console__line"]],template:function(n,r){if(n&1&&(m(0,"div",1,0),G("scroll",function(){return r.onScroll()}),vt(2,kI,2,1,null,null,AI),W(4,"async"),ie(5,FI,2,0,"div",2),W(6,"async"),y()),n&2){let o;S(2),Et(q(4,1,r.logs$)),S(3),se(((o=q(6,3,r.logs$))==null?null:o.length)===0?5:-1)}},dependencies:[ke,$e],styles:[`gb-console-output{display:block;height:100%}gb-console-output .gb-console{padding:var(--space-sm);font-family:var(--font-mono);font-size:12px;line-height:1.6;overflow-y:auto;height:100%}gb-console-output .gb-console__line{padding:1px var(--space-sm);white-space:pre-wrap;word-break:break-all}gb-console-output .gb-console__line[data-type=error]{color:var(--color-danger)}gb-console-output .gb-console__separator{padding:var(--space-sm) 0;color:var(--text-muted);text-align:center;font-size:11px}
|
|
13
13
|
`],encapsulation:2})};function PI(e,t){if(e&1&&(m(0,"span",6),D(1),y(),m(2,"span",7),D(3),y()),e&2){let n=$();S(),it("\u2713 ",n.passed),S(2),it("\u2717 ",n.failed)}}function LI(e,t){if(e&1&&ie(0,PI,4,2),e&2){let n=t;se(n.passed>0||n.failed>0?0:-1)}}var wa=class e{constructor(t){this.store=t;this.connectionStatus$=this.store.select(rm),this.summary$=this.store.select(om),this.fsmState$=this.store.select(Ko)}connectionStatus$;summary$;fsmState$;static \u0275fac=function(n){return new(n||e)(de(Z))};static \u0275cmp=Se({type:e,selectors:[["gb-footer"]],decls:14,vars:12,consts:[[1,"gb-footer"],[1,"footer-left"],[1,"connection-dot"],[1,"footer-text"],[1,"footer-center"],[1,"footer-right"],[1,"result-passed"],[1,"result-failed"]],template:function(n,r){if(n&1&&(m(0,"footer",0)(1,"div",1),Rt(2,"span",2),W(3,"async"),m(4,"span",3),D(5),W(6,"async"),y()(),m(7,"div",4),ie(8,LI,1,1),W(9,"async"),y(),m(10,"div",5)(11,"span",3),D(12),W(13,"async"),y()()()),n&2){let o;S(2),Ye("data-status",q(3,4,r.connectionStatus$)),S(3),we(q(6,6,r.connectionStatus$)==="connected"?"Connected":"Disconnected"),S(3),se((o=q(9,8,r.summary$))?8:-1,o),S(4),we(q(13,10,r.fsmState$))}},dependencies:[ke,$e],styles:[`.gb-footer{display:flex;align-items:center;justify-content:space-between;padding:var(--space-xs) var(--space-md);background:var(--bg-panel);border-top:1px solid var(--border-color);font-size:12px}.gb-footer .footer-left,.gb-footer .footer-center,.gb-footer .footer-right{display:flex;align-items:center;gap:var(--space-sm)}.gb-footer .connection-dot{width:8px;height:8px;border-radius:50%;background:var(--color-danger)}.gb-footer .connection-dot[data-status=connected]{background:var(--color-success)}.gb-footer .footer-text{color:var(--text-muted);font-family:var(--font-mono)}.gb-footer .result-passed{color:var(--color-success);font-family:var(--font-mono)}.gb-footer .result-failed{color:var(--color-danger);font-family:var(--font-mono)}
|
|
14
|
-
`],encapsulation:2})};var jI=3e4,Ca=class e{constructor(t){this.store=t}ws=null;reconnectInterval=1e3;messageHandlers=new Map([["action",t=>this.store.dispatch(x.actionReceived({index:t.index,status:t.status,description:t.description,result:t.result}))],["test-start",t=>this.store.dispatch(x.testStarted({journey:t.journey}))],["test-end",t=>this.store.dispatch(x.testEnded({journey:t.journey,status:t.status,duration:t.duration}))],["run-end",()=>this.store.dispatch(x.runEnded())],["log",t=>this.store.dispatch(x.logReceived({message:t.message,journey:t.journey}))],["error",t=>this.store.dispatch(x.errorReceived({message:t.message,journey:t.journey}))],["ui-control",t=>{t.action==="pause"?this.store.dispatch(x.pausedByRunner()):t.action==="resume"&&this.store.dispatch(x.resumedByRunner())}]]);connect(){let n=`${window.location.protocol==="https:"?"wss:":"ws:"}//${window.location.host}/ws`;this.ws=new WebSocket(n),this.ws.onopen=()=>{this.reconnectInterval=1e3,this.store.dispatch(x.connectionStatusChanged({status:"connected"}))},this.ws.onclose=()=>{this.store.dispatch(x.connectionStatusChanged({status:"disconnected"})),setTimeout(()=>this.connect(),this.reconnectInterval),this.reconnectInterval=Math.min(this.reconnectInterval*2,jI)},this.ws.onmessage=r=>{try{let o=JSON.parse(r.data);this.dispatchMessage(o)}catch(o){}},this.ws.onerror=()=>{this.ws?.close()}}dispatchMessage(t){let n=this.messageHandlers.get(t.type);n&&n(t)}static \u0275fac=function(n){return new(n||e)(b(Z))};static \u0275prov=T({token:e,factory:e.\u0275fac,providedIn:"root"})};function VI(e,t){if(e&1){let n=Je();_e(0,"button",14),Ot("click",function(){K(n);let o=$();return X(o.clearBreakpoints())}),D(1,"\u2298"),Ve()}}function $I(e,t){e&1&&(_e(0,"div",13)(1,"span",15),D(2,"\u2717"),Ve(),_e(3,"span",16),D(4),Ve()()),e&2&&(S(4),we(t))}function HI(e,t){e&1&&At(0,"gb-action-log")}function UI(e,t){e&1&&At(0,"gb-console-output")}var Ia=class e{constructor(t,n,r){this.wsService=t;this.themeService=n;this.store=r;this.settingsOpen$=this.store.select(Xg),this.activeTab$=this.store.select(em),this.sidebarWidth$=this.store.select(tm),this.fsmState$=this.store.select(Ko),this.lastError$=this.store.select(cm)}settingsOpen$;activeTab$;sidebarWidth$;fsmState$;lastError$;ngOnInit(){this.wsService.connect(),this.themeService.initialize(),this.store.dispatch(U.loadSettings())}toggleSettings(){this.store.dispatch(U.toggleSettingsPanel())}setTab(t){this.store.dispatch(U.updateSetting({key:"activeTab",value:t}))}copyContent(){return Qe(this,null,function*(){let[t,n,r]=yield Promise.all([Vt(this.activeTab$),Vt(this.store.select(ga)),Vt(this.store.select(ma))]),o=t==="actions"?n.map(i=>`[${i.index}] ${i.description}`).join(`
|
|
14
|
+
`],encapsulation:2})};var jI=3e4,Ca=class e{constructor(t){this.store=t}ws=null;reconnectInterval=1e3;messageHandlers=new Map([["action",t=>this.store.dispatch(x.actionReceived({index:t.index,status:t.status,description:t.description,result:t.result}))],["test-start",t=>this.store.dispatch(x.testStarted({journey:t.journey}))],["test-end",t=>this.store.dispatch(x.testEnded({journey:t.journey,status:t.status,duration:t.duration}))],["run-end",()=>this.store.dispatch(x.runEnded())],["log",t=>this.store.dispatch(x.logReceived({message:t.message,journey:t.journey}))],["error",t=>this.store.dispatch(x.errorReceived({message:t.message,journey:t.journey}))],["ui-control",t=>{t.action==="pause"?this.store.dispatch(x.pausedByRunner()):t.action==="resume"&&this.store.dispatch(x.resumedByRunner())}]]);connect(){let n=`${window.location.protocol==="https:"?"wss:":"ws:"}//${window.location.host}/ws`;this.ws=new WebSocket(n),this.ws.onopen=()=>{this.reconnectInterval=1e3,this.store.dispatch(x.connectionStatusChanged({status:"connected"}))},this.ws.onclose=()=>{this.store.dispatch(x.connectionStatusChanged({status:"disconnected"})),setTimeout(()=>this.connect(),this.reconnectInterval),this.reconnectInterval=Math.min(this.reconnectInterval*2,jI)},this.ws.onmessage=r=>{try{let o=JSON.parse(r.data);this.dispatchMessage(o)}catch(o){}},this.ws.onerror=()=>{this.ws?.close()}}dispatchMessage(t){let n=this.messageHandlers.get(t.type);n&&n(t)}static \u0275fac=function(n){return new(n||e)(b(Z))};static \u0275prov=T({token:e,factory:e.\u0275fac,providedIn:"root"})};function VI(e,t){if(e&1){let n=Je();_e(0,"button",14),Ot("click",function(){K(n);let o=$();return X(o.clearBreakpoints())}),D(1,"\u2298"),Ve()}}function $I(e,t){e&1&&(_e(0,"div",13)(1,"span",15),D(2,"\u2717"),Ve(),_e(3,"span",16),D(4),Ve()()),e&2&&(S(4),we(t))}function HI(e,t){e&1&&At(0,"gb-action-log")}function UI(e,t){e&1&&At(0,"gb-console-output")}var Ia=class e{constructor(t,n,r){this.wsService=t;this.themeService=n;this.store=r;this.settingsOpen$=this.store.select(Xg),this.activeTab$=this.store.select(em),this.sidebarWidth$=this.store.select(tm),this.fsmState$=this.store.select(Ko),this.lastError$=this.store.select(cm)}settingsOpen$;activeTab$;sidebarWidth$;fsmState$;lastError$;ngOnInit(){this.wsService.connect(),this.themeService.initialize(),this.store.dispatch(U.loadSettings())}toggleSettings(){this.store.dispatch(U.toggleSettingsPanel())}setTab(t){this.store.dispatch(U.updateSetting({key:"activeTab",value:t}))}copyContent(){return Qe(this,null,function*(){let[t,n,r]=yield Promise.all([Vt(this.activeTab$),Vt(this.store.select(ga)),Vt(this.store.select(ma))]),o=t==="actions"?n.map(i=>`[${i.index}] ${i.description}${i.result!==void 0?` -> ${i.result}`:""}`).join(`
|
|
15
15
|
`):r.map(i=>i.message).join(`
|
|
16
16
|
`);navigator.clipboard.writeText(o)})}clearContent(){return Qe(this,null,function*(){(yield Vt(this.activeTab$))==="actions"?this.store.dispatch(x.clearActions()):this.store.dispatch(x.clearConsole())})}clearBreakpoints(){this.store.dispatch(x.clearAllBreakpoints())}startResize(t){return Qe(this,null,function*(){t.preventDefault();let n=t.clientX,r=yield Vt(this.sidebarWidth$),o=r,i=a=>{o=Math.max(150,Math.min(500,r+(a.clientX-n)));let c=document.querySelector("gb-sidebar");c&&(c.style.width=`${o}px`)},s=()=>{document.removeEventListener("mousemove",i),document.removeEventListener("mouseup",s),document.body.style.cursor="",document.body.style.userSelect="",this.store.dispatch(U.updateSetting({key:"sidebarWidth",value:o}))};document.body.style.cursor="col-resize",document.body.style.userSelect="none",document.addEventListener("mousemove",i),document.addEventListener("mouseup",s)})}static \u0275fac=function(n){return new(n||e)(de(Ca),de(mn),de(Z))};static \u0275cmp=Se({type:e,selectors:[["gb-root"]],decls:32,vars:26,consts:[[1,"app-layout"],[3,"settingsToggled"],[3,"isOpen"],[1,"main-layout"],[1,"resize-handle",3,"mousedown"],[1,"content"],[1,"tab-bar"],[1,"tab",3,"click"],[1,"tab-spacer"],["title","Clear all breakpoints",1,"tab-action"],["title","Copy to clipboard",1,"tab-action",3,"click"],["title","Clear",1,"tab-action",3,"click"],[1,"tab-content"],[1,"error-banner"],["title","Clear all breakpoints",1,"tab-action",3,"click"],[1,"error-banner__icon"],[1,"error-banner__text"]],template:function(n,r){if(n&1&&(_e(0,"div",0)(1,"gb-header",1),Ot("settingsToggled",function(){return r.toggleSettings()}),Ve(),At(2,"gb-settings-panel",2),W(3,"async"),_e(4,"div",3),At(5,"gb-sidebar"),W(6,"async"),_e(7,"div",4),Ot("mousedown",function(i){return r.startResize(i)}),Ve(),_e(8,"main",5),At(9,"gb-toolbar"),_e(10,"div",6)(11,"button",7),W(12,"async"),Ot("click",function(){return r.setTab("actions")}),D(13," Actions "),Ve(),_e(14,"button",7),W(15,"async"),Ot("click",function(){return r.setTab("console")}),D(16," Console "),Ve(),At(17,"span",8),ie(18,VI,2,0,"button",9),W(19,"async"),_e(20,"button",10),Ot("click",function(){return r.copyContent()}),D(21,"\u{1F4CB}"),Ve(),_e(22,"button",11),Ot("click",function(){return r.clearContent()}),D(23,"\u{1F5D1}\uFE0F"),Ve()(),_e(24,"div",12),ie(25,$I,5,1,"div",13),W(26,"async"),W(27,"async"),ie(28,HI,1,0,"gb-action-log"),W(29,"async"),Oo(30,UI,1,0,"gb-console-output"),Ve()()(),At(31,"gb-footer"),Ve()),n&2){let o;S(2),Hs("isOpen",q(3,10,r.settingsOpen$)??!1),S(3),Us("width",q(6,12,r.sidebarWidth$)??240,"px"),S(6),Lo("active",q(12,14,r.activeTab$)==="actions"),S(3),Lo("active",q(15,16,r.activeTab$)==="console"),S(4),se(q(19,18,r.activeTab$)==="actions"?18:-1),S(7),se((o=q(26,20,r.fsmState$)==="errored"&&q(27,22,r.lastError$))?25:-1,o),S(3),se(q(29,24,r.activeTab$)==="actions"?28:30)}},dependencies:[ke,da,pa,va,Ea,Da,ba,wa,$e],styles:[".app-layout[_ngcontent-%COMP%]{display:grid;grid-template-rows:auto auto 1fr auto;height:100vh;overflow:hidden}.main-layout[_ngcontent-%COMP%]{display:grid;grid-template-columns:auto 4px 1fr;overflow:hidden;min-height:0}.resize-handle[_ngcontent-%COMP%]{cursor:col-resize;background:var(--border-color);transition:background .15s}.resize-handle[_ngcontent-%COMP%]:hover{background:var(--accent-primary)}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;overflow:hidden;min-height:0}.tab-bar[_ngcontent-%COMP%]{display:flex;gap:var(--space-xs);padding:var(--space-xs) var(--space-md);border-bottom:1px solid var(--border-color);background:var(--bg-panel);align-items:center}.tab[_ngcontent-%COMP%]{padding:var(--space-xs) var(--space-md);border-radius:var(--radius-sm) var(--radius-sm) 0 0;color:var(--text-secondary);font-weight:500;border:none;background:none;cursor:pointer;transition:color .15s}.tab[_ngcontent-%COMP%]:hover{color:var(--text-primary)}.tab.active[_ngcontent-%COMP%]{color:var(--accent-primary);border-bottom:2px solid var(--accent-primary)}.tab-spacer[_ngcontent-%COMP%]{flex:1}.tab-action[_ngcontent-%COMP%]{width:28px;height:28px;display:flex;align-items:center;justify-content:center;border:none;background:none;border-radius:var(--radius-sm);cursor:pointer;font-size:14px;opacity:.6;transition:opacity .15s,background .15s}.tab-action[_ngcontent-%COMP%]:hover{opacity:1;background:var(--bg-elevated)}.tab-content[_ngcontent-%COMP%]{flex:1;overflow:auto;min-height:0}.error-banner[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--space-sm);padding:var(--space-sm) var(--space-md);background:#f851491a;border-bottom:1px solid var(--color-danger);color:var(--color-danger);font-size:13px;font-family:var(--font-mono)}.error-banner__icon[_ngcontent-%COMP%]{font-weight:700}.error-banner__text[_ngcontent-%COMP%]{flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}"]})};var zI={dispatch:!0,functional:!1,useEffectsErrorHandler:!0},_a="__@ngrx/effects_create__";function He(e,t={}){let n=t.functional?e:e(),r=E(E({},zI),t);return Object.defineProperty(n,_a,{value:r}),n}function GI(e){return Object.getOwnPropertyNames(e).filter(r=>e[r]&&e[r].hasOwnProperty(_a)?e[r][_a].hasOwnProperty("dispatch"):!1).map(r=>{let o=e[r][_a];return E({propertyName:r},o)})}function WI(e){return GI(e)}function um(e){return Object.getPrototypeOf(e)}function qI(e){return!!e.constructor&&e.constructor.name!=="Object"&&e.constructor.name!=="Function"}function lm(e){return typeof e=="function"}function ZI(e){return e.filter(lm)}function YI(e,t,n){let r=um(e),i=!!r&&r.constructor.name!=="Object"?r.constructor.name:null,s=WI(e).map(({propertyName:a,dispatch:c,useEffectsErrorHandler:u})=>{let l=typeof e[a]=="function"?e[a]():e[a],d=u?n(l,t):l;return c===!1?d.pipe(Ka()):d.pipe(tc()).pipe(L(p=>({effect:e[a],notification:p,propertyName:a,sourceName:i,sourceInstance:e})))});return Sn(...s)}var JI=10;function dm(e,t,n=JI){return e.pipe(Ce(r=>(t&&t.handleError(r),n<=1?e:dm(e,t,n-1))))}var Hr=(()=>{class e extends j{constructor(n){super(),n&&(this.source=n)}lift(n){let r=new e;return r.source=this,r.operator=n,r}static{this.\u0275fac=function(r){return new(r||e)(b(Kn))}}static{this.\u0275prov=T({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function Ue(...e){return he(t=>e.some(n=>typeof n=="string"?n===t.type:n.type===t.type))}var QI=new I("@ngrx/effects Effects Error Handler",{providedIn:"root",factory:()=>dm}),KI="@ngrx/effects/init",XI=$l(KI);function e0(e,t){if(e.notification.kind==="N"){let n=e.notification.value;!t0(n)&&t.handleError(new Error(`Effect ${n0(e)} dispatched an invalid action: ${r0(n)}`))}}function t0(e){return typeof e!="function"&&e&&e.type&&typeof e.type=="string"}function n0({propertyName:e,sourceInstance:t,sourceName:n}){let r=typeof t[e]=="function";return!!n?`"${n}.${String(e)}${r?"()":""}"`:`"${String(e)}()"`}function r0(e){try{return JSON.stringify(e)}catch(t){return e}}var o0="ngrxOnIdentifyEffects";function i0(e){return ql(e,o0)}var s0="ngrxOnRunEffects";function a0(e){return ql(e,s0)}var c0="ngrxOnInitEffects";function u0(e){return ql(e,c0)}function ql(e,t){return e&&t in e&&typeof e[t]=="function"}var fm=(()=>{class e extends Ee{constructor(n,r){super(),this.errorHandler=n,this.effectsErrorHandler=r}addEffects(n){this.next(n)}toActions(){return this.pipe(Ri(n=>qI(n)?um(n):n),Dt(n=>n.pipe(Ri(l0))),Dt(n=>{let r=n.pipe(fr(i=>d0(this.errorHandler,this.effectsErrorHandler)(i)),L(i=>(e0(i,this.errorHandler),i.notification)),he(i=>i.kind==="N"&&i.value!=null),Xa()),o=n.pipe(Kr(1),he(u0),L(i=>i.ngrxOnInitEffects()));return Sn(r,o)}))}static{this.\u0275fac=function(r){return new(r||e)(b(Re),b(QI))}}static{this.\u0275prov=T({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function l0(e){return i0(e)?e.ngrxOnIdentifyEffects():""}function d0(e,t){return n=>{let r=YI(n,e,t);return a0(n)?n.ngrxOnRunEffects(r):r}}var f0=(()=>{class e{get isStarted(){return!!this.effectsSubscription}constructor(n,r){this.effectSources=n,this.store=r,this.effectsSubscription=null}start(){this.effectsSubscription||(this.effectsSubscription=this.effectSources.toActions().subscribe(this.store))}ngOnDestroy(){this.effectsSubscription&&(this.effectsSubscription.unsubscribe(),this.effectsSubscription=null)}static{this.\u0275fac=function(r){return new(r||e)(b(fm),b(Z))}}static{this.\u0275prov=T({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function pm(...e){let t=e.flat(),n=ZI(t);return et([n,mr(()=>{g(Yo),g(ca,{optional:!0});let r=g(f0),o=g(fm),i=!r.isStarted;i&&r.start();for(let s of t){let a=lm(s)?g(s):s;o.addEffects(a)}i&&g(Z).dispatch(XI())})])}var ei="PERFORM_ACTION",p0="REFRESH",Em="RESET",Dm="ROLLBACK",bm="COMMIT",wm="SWEEP",Cm="TOGGLE_ACTION",h0="SET_ACTIONS_ACTIVE",Im="JUMP_TO_STATE",_m="JUMP_TO_ACTION",sd="IMPORT_STATE",Sm="LOCK_CHANGES",Tm="PAUSE_RECORDING",Ur=class{constructor(t,n){if(this.action=t,this.timestamp=n,this.type=ei,typeof t.type>"u")throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?')}},Zl=class{constructor(){this.type=p0}},Yl=class{constructor(t){this.timestamp=t,this.type=Em}},Jl=class{constructor(t){this.timestamp=t,this.type=Dm}},Ql=class{constructor(t){this.timestamp=t,this.type=bm}},Kl=class{constructor(){this.type=wm}},Xl=class{constructor(t){this.id=t,this.type=Cm}};var ed=class{constructor(t){this.index=t,this.type=Im}},td=class{constructor(t){this.actionId=t,this.type=_m}},nd=class{constructor(t){this.nextLiftedState=t,this.type=sd}},rd=class{constructor(t){this.status=t,this.type=Sm}},od=class{constructor(t){this.status=t,this.type=Tm}};var xa=new I("@ngrx/store-devtools Options"),hm=new I("@ngrx/store-devtools Initial Config");function Mm(){return null}var g0="NgRx Store DevTools";function m0(e){let t={maxAge:!1,monitor:Mm,actionSanitizer:void 0,stateSanitizer:void 0,name:g0,serialize:!1,logOnly:!1,autoPause:!1,trace:!1,traceLimit:75,features:{pause:!0,lock:!0,persist:!0,export:!0,import:"custom",jump:!0,skip:!0,reorder:!0,dispatch:!0,test:!0},connectInZone:!1},n=typeof e=="function"?e():e,r=n.logOnly?{pause:!0,export:!0,test:!0}:!1,o=n.features||r||t.features;o.import===!0&&(o.import="custom");let i=Object.assign({},t,{features:o},n);if(i.maxAge&&i.maxAge<2)throw new Error(`Devtools 'maxAge' cannot be less than 2, got ${i.maxAge}`);return i}function gm(e,t){return e.filter(n=>t.indexOf(n)<0)}function xm(e){let{computedStates:t,currentStateIndex:n}=e;if(n>=t.length){let{state:o}=t[t.length-1];return o}let{state:r}=t[n];return r}function Xo(e){return new Ur(e,+Date.now())}function y0(e,t){return Object.keys(t).reduce((n,r)=>{let o=Number(r);return n[o]=Nm(e,t[o],o),n},{})}function Nm(e,t,n){return C(E({},t),{action:e(t.action,n)})}function v0(e,t){return t.map((n,r)=>({state:Am(e,n.state,r),error:n.error}))}function Am(e,t,n){return e(t,n)}function Rm(e){return e.predicate||e.actionsSafelist||e.actionsBlocklist}function E0(e,t,n,r){let o=[],i={},s=[];return e.stagedActionIds.forEach((a,c)=>{let u=e.actionsById[a];u&&(c&&ad(e.computedStates[c],u,t,n,r)||(i[a]=u,o.push(a),s.push(e.computedStates[c])))}),C(E({},e),{stagedActionIds:o,actionsById:i,computedStates:s})}function ad(e,t,n,r,o){let i=n&&!n(e,t.action),s=r&&!t.action.type.match(r.map(c=>mm(c)).join("|")),a=o&&t.action.type.match(o.map(c=>mm(c)).join("|"));return i||s||a}function mm(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Om(e){return{ngZone:e?g(re):null,connectInZone:e}}var Na=(()=>{class e extends kt{static{this.\u0275fac=(()=>{let n;return function(o){return(n||(n=To(e)))(o||e)}})()}static{this.\u0275prov=T({token:e,factory:e.\u0275fac})}}return e})(),Sa={START:"START",DISPATCH:"DISPATCH",STOP:"STOP",ACTION:"ACTION"},id=new I("@ngrx/store-devtools Redux Devtools Extension"),km=(()=>{class e{constructor(n,r,o){this.config=r,this.dispatcher=o,this.zoneConfig=Om(this.config.connectInZone),this.devtoolsExtension=n,this.createActionStreams()}notify(n,r){if(this.devtoolsExtension)if(n.type===ei){if(r.isLocked||r.isPaused)return;let o=xm(r);if(Rm(this.config)&&ad(o,n,this.config.predicate,this.config.actionsSafelist,this.config.actionsBlocklist))return;let i=this.config.stateSanitizer?Am(this.config.stateSanitizer,o,r.currentStateIndex):o,s=this.config.actionSanitizer?Nm(this.config.actionSanitizer,n,r.nextActionId):n;this.sendToReduxDevtools(()=>this.extensionConnection.send(s,i))}else{let o=C(E({},r),{stagedActionIds:r.stagedActionIds,actionsById:this.config.actionSanitizer?y0(this.config.actionSanitizer,r.actionsById):r.actionsById,computedStates:this.config.stateSanitizer?v0(this.config.stateSanitizer,r.computedStates):r.computedStates});this.sendToReduxDevtools(()=>this.devtoolsExtension.send(null,o,this.getExtensionConfig(this.config)))}}createChangesObservable(){return this.devtoolsExtension?new j(n=>{let r=this.zoneConfig.connectInZone?this.zoneConfig.ngZone.runOutsideAngular(()=>this.devtoolsExtension.connect(this.getExtensionConfig(this.config))):this.devtoolsExtension.connect(this.getExtensionConfig(this.config));return this.extensionConnection=r,r.init(),r.subscribe(o=>n.next(o)),r.unsubscribe}):ce}createActionStreams(){let n=this.createChangesObservable().pipe(ic()),r=n.pipe(he(u=>u.type===Sa.START)),o=n.pipe(he(u=>u.type===Sa.STOP)),i=n.pipe(he(u=>u.type===Sa.DISPATCH),L(u=>this.unwrapAction(u.payload)),Jr(u=>u.type===sd?this.dispatcher.pipe(he(l=>l.type===la),Qa(1e3),Qr(1e3),L(()=>u),Ce(()=>ut(u)),Kr(1)):ut(u))),a=n.pipe(he(u=>u.type===Sa.ACTION),L(u=>this.unwrapAction(u.payload))).pipe(Tn(o)),c=i.pipe(Tn(o));this.start$=r.pipe(Tn(o)),this.actions$=this.start$.pipe(ge(()=>a)),this.liftedActions$=this.start$.pipe(ge(()=>c))}unwrapAction(n){return typeof n=="string"?(0,eval)(`(${n})`):n}getExtensionConfig(n){let r={name:n.name,features:n.features,serialize:n.serialize,autoPause:n.autoPause??!1,trace:n.trace??!1,traceLimit:n.traceLimit??75};return n.maxAge!==!1&&(r.maxAge=n.maxAge),r}sendToReduxDevtools(n){try{n()}catch(r){console.warn("@ngrx/store-devtools: something went wrong inside the redux devtools",r)}}static{this.\u0275fac=function(r){return new(r||e)(b(id),b(xa),b(Na))}}static{this.\u0275prov=T({token:e,factory:e.\u0275fac})}}return e})(),Ma={type:Jo},D0="@ngrx/store-devtools/recompute",b0={type:D0};function Fm(e,t,n,r,o){if(r)return{state:n,error:"Interrupted by an error up the chain"};let i=n,s;try{i=e(n,t)}catch(a){s=a.toString(),o.handleError(a)}return{state:i,error:s}}function Ta(e,t,n,r,o,i,s,a,c){if(t>=e.length&&e.length===i.length)return e;let u=e.slice(0,t),l=i.length-(c?1:0);for(let d=t;d<l;d++){let f=i[d],p=o[f].action,h=u[d-1],v=h?h.state:r,w=h?h.error:void 0,B=s.indexOf(f)>-1?h:Fm(n,p,v,w,a);u.push(B)}return c&&u.push(e[e.length-1]),u}function w0(e,t){return{monitorState:t(void 0,{}),nextActionId:1,actionsById:{0:Xo(Ma)},stagedActionIds:[0],skippedActionIds:[],committedState:e,currentStateIndex:0,computedStates:[],isLocked:!1,isPaused:!1}}function C0(e,t,n,r,o={}){return i=>(s,a)=>{let{monitorState:c,actionsById:u,nextActionId:l,stagedActionIds:d,skippedActionIds:f,committedState:p,currentStateIndex:h,computedStates:v,isLocked:w,isPaused:_}=s||t;s||(u=Object.create(u));function B(ne){let ee=ne,xe=d.slice(1,ee+1);for(let st=0;st<xe.length;st++)if(v[st+1].error){ee=st,xe=d.slice(1,ee+1);break}else delete u[xe[st]];f=f.filter(st=>xe.indexOf(st)===-1),d=[0,...d.slice(ee+1)],p=v[ee].state,v=v.slice(ee),h=h>ee?h-ee:0}function pe(){u={0:Xo(Ma)},l=1,d=[0],f=[],p=v[h].state,h=0,v=[]}let F=0;switch(a.type){case Sm:{w=a.status,F=1/0;break}case Tm:{_=a.status,_?(d=[...d,l],u[l]=new Ur({type:"@ngrx/devtools/pause"},+Date.now()),l++,F=d.length-1,v=v.concat(v[v.length-1]),h===d.length-2&&h++,F=1/0):pe();break}case Em:{u={0:Xo(Ma)},l=1,d=[0],f=[],p=e,h=0,v=[];break}case bm:{pe();break}case Dm:{u={0:Xo(Ma)},l=1,d=[0],f=[],h=0,v=[];break}case Cm:{let{id:ne}=a;f.indexOf(ne)===-1?f=[ne,...f]:f=f.filter(xe=>xe!==ne),F=d.indexOf(ne);break}case h0:{let{start:ne,end:ee,active:xe}=a,st=[];for(let ka=ne;ka<ee;ka++)st.push(ka);xe?f=gm(f,st):f=[...f,...st],F=d.indexOf(ne);break}case Im:{h=a.index,F=1/0;break}case _m:{let ne=d.indexOf(a.actionId);ne!==-1&&(h=ne),F=1/0;break}case wm:{d=gm(d,f),f=[],h=Math.min(h,d.length-1);break}case ei:{if(w)return s||t;if(_||s&&ad(s.computedStates[h],a,o.predicate,o.actionsSafelist,o.actionsBlocklist)){let ee=v[v.length-1];v=[...v.slice(0,-1),Fm(i,a.action,ee.state,ee.error,n)],F=1/0;break}o.maxAge&&d.length===o.maxAge&&B(1),h===d.length-1&&h++;let ne=l++;u[ne]=a,d=[...d,ne],F=d.length-1;break}case sd:{({monitorState:c,actionsById:u,nextActionId:l,stagedActionIds:d,skippedActionIds:f,committedState:p,currentStateIndex:h,computedStates:v,isLocked:w,isPaused:_}=a.nextLiftedState);break}case Jo:{F=0,o.maxAge&&d.length>o.maxAge&&(v=Ta(v,F,i,p,u,d,f,n,_),B(d.length-o.maxAge),F=1/0);break}case la:{if(v.filter(ee=>ee.error).length>0)F=0,o.maxAge&&d.length>o.maxAge&&(v=Ta(v,F,i,p,u,d,f,n,_),B(d.length-o.maxAge),F=1/0);else{if(!_&&!w){h===d.length-1&&h++;let ee=l++;u[ee]=new Ur(a,+Date.now()),d=[...d,ee],F=d.length-1,v=Ta(v,F,i,p,u,d,f,n,_)}v=v.map(ee=>C(E({},ee),{state:i(ee.state,b0)})),h=d.length-1,o.maxAge&&d.length>o.maxAge&&B(d.length-o.maxAge),F=1/0}break}default:{F=1/0;break}}return v=Ta(v,F,i,p,u,d,f,n,_),c=r(c,a),{monitorState:c,actionsById:u,nextActionId:l,stagedActionIds:d,skippedActionIds:f,committedState:p,currentStateIndex:h,computedStates:v,isLocked:w,isPaused:_}}}var ym=(()=>{class e{constructor(n,r,o,i,s,a,c,u){let l=w0(c,u.monitor),d=C0(c,l,a,u.monitor,u),f=Sn(Sn(r.asObservable().pipe(sc(1)),i.actions$).pipe(L(Xo)),n,i.liftedActions$).pipe(Bt(Yr)),p=o.pipe(L(d)),h=Om(u.connectInZone),v=new sr(1);this.liftedStateSubscription=f.pipe(Ke(p),vm(h),Xr(({state:B},[pe,F])=>{let ne=F(B,pe);return pe.type!==ei&&Rm(u)&&(ne=E0(ne,u.predicate,u.actionsSafelist,u.actionsBlocklist)),i.notify(pe,ne),{state:ne,action:pe}},{state:l,action:null})).subscribe(({state:B,action:pe})=>{if(v.next(B),pe.type===ei){let F=pe.action;s.next(F)}}),this.extensionStartSubscription=i.start$.pipe(vm(h)).subscribe(()=>{this.refresh()});let w=v.asObservable(),_=w.pipe(L(xm));Object.defineProperty(_,"state",{value:sa(_,{manualCleanup:!0,requireSync:!0})}),this.dispatcher=n,this.liftedState=w,this.state=_}ngOnDestroy(){this.liftedStateSubscription.unsubscribe(),this.extensionStartSubscription.unsubscribe()}dispatch(n){this.dispatcher.next(n)}next(n){this.dispatcher.next(n)}error(n){}complete(){}performAction(n){this.dispatch(new Ur(n,+Date.now()))}refresh(){this.dispatch(new Zl)}reset(){this.dispatch(new Yl(+Date.now()))}rollback(){this.dispatch(new Jl(+Date.now()))}commit(){this.dispatch(new Ql(+Date.now()))}sweep(){this.dispatch(new Kl)}toggleAction(n){this.dispatch(new Xl(n))}jumpToAction(n){this.dispatch(new td(n))}jumpToState(n){this.dispatch(new ed(n))}importState(n){this.dispatch(new nd(n))}lockChanges(n){this.dispatch(new rd(n))}pauseRecording(n){this.dispatch(new od(n))}static{this.\u0275fac=function(r){return new(r||e)(b(Na),b(kt),b(Qn),b(km),b(Kn),b(Re),b(Qo),b(xa))}}static{this.\u0275prov=T({token:e,factory:e.\u0275fac})}}return e})();function vm({ngZone:e,connectInZone:t}){return n=>t?new j(r=>n.subscribe({next:o=>e.run(()=>r.next(o)),error:o=>e.run(()=>r.error(o)),complete:()=>e.run(()=>r.complete())})):n}var I0=new I("@ngrx/store-devtools Is Devtools Extension or Monitor Present");function _0(e,t){return!!e||t.monitor!==Mm}function S0(){let e="__REDUX_DEVTOOLS_EXTENSION__";return typeof window=="object"&&typeof window[e]<"u"?window[e]:null}function T0(e){return e.state}function Pm(e={}){return et([km,Na,ym,{provide:hm,useValue:e},{provide:I0,deps:[id,xa],useFactory:_0},{provide:id,useFactory:S0},{provide:xa,deps:[hm],useFactory:m0},{provide:Lr,deps:[ym],useFactory:T0},{provide:Pr,useExisting:Na}])}var M0={fsmState:"idle",actions:[],breakpointsByJourney:{},consoleLogs:[],connectionStatus:"disconnected",results:[],currentJourney:null},Lm=Vr(M0,Y(x.play,e=>C(E({},e),{fsmState:"running",actions:[],consoleLogs:[],results:[]})),Y(x.pause,e=>C(E({},e),{fsmState:"paused"})),Y(x.resume,e=>C(E({},e),{fsmState:"running"})),Y(x.step,e=>C(E({},e),{fsmState:"stepping"})),Y(x.stop,e=>C(E({},e),{fsmState:"idle"})),Y(x.pausedByRunner,e=>C(E({},e),{fsmState:"paused"})),Y(x.resumedByRunner,e=>C(E({},e),{fsmState:"running"})),Y(x.runEnded,e=>C(E({},e),{fsmState:"idle"})),Y(x.actionReceived,(e,{index:t,status:n,description:r,result:o})=>{let i=e.actions.find(d=>d.index===t),s=x0(n),a=e.currentJourney??"",c=e.breakpointsByJourney[a]??[],u=n==="breakpoint"&&!c.includes(t)?[...c,t]:c,l=u!==c?C(E({},e.breakpointsByJourney),{[a]:u}):e.breakpointsByJourney;return i?C(E({},e),{breakpointsByJourney:l,actions:e.actions.map(d=>d.index===t?E(C(E({},d),{status:s}),o!==void 0&&{result:o}):d),fsmState:n==="breakpoint"?"paused":e.fsmState}):C(E({},e),{breakpointsByJourney:l,actions:[...e.actions,E({index:t,description:r??"",status:s,hasBreakpoint:u.includes(t)},o!==void 0&&{result:o})],fsmState:n==="breakpoint"?"paused":e.fsmState})}),Y(x.testStarted,(e,{journey:t})=>C(E({},e),{fsmState:"running",currentJourney:t,actions:[],consoleLogs:[...e.consoleLogs,{type:"separator",message:t,timestamp:Date.now()}]})),Y(x.testEnded,(e,{journey:t,status:n,duration:r})=>C(E({},e),{results:[...e.results,{journey:t,status:n,duration:r}],currentJourney:null,actions:n==="failed"?e.actions.map(o=>o.status==="running"?C(E({},o),{status:"failed"}):o):e.actions,fsmState:n==="failed"?"errored":e.fsmState})),Y(x.logReceived,(e,{message:t})=>C(E({},e),{consoleLogs:[...e.consoleLogs,{type:"log",message:t,timestamp:Date.now()}]})),Y(x.errorReceived,(e,{message:t})=>C(E({},e),{consoleLogs:[...e.consoleLogs,{type:"error",message:t,timestamp:Date.now()}]})),Y(x.connectionStatusChanged,(e,{status:t})=>C(E({},e),{connectionStatus:t})),Y(x.toggleBreakpoint,(e,{index:t})=>{let n=e.currentJourney??"",r=e.breakpointsByJourney[n]??[],o=r.includes(t);return C(E({},e),{breakpointsByJourney:C(E({},e.breakpointsByJourney),{[n]:o?r.filter(i=>i!==t):[...r,t]})})}),Y(x.clearAllBreakpoints,e=>{let t=e.currentJourney??"";return C(E({},e),{breakpointsByJourney:C(E({},e.breakpointsByJourney),{[t]:[]})})}),Y(x.clearActions,e=>C(E({},e),{actions:[]})),Y(x.clearConsole,e=>C(E({},e),{consoleLogs:[]})));function x0(e){switch(e){case"start":return"running";case"complete":return"complete";case"breakpoint":return"breakpoint";default:return"pending"}}var N0={journeys:[],selectedIds:[],loading:!1},jm=Vr(N0,Y(Me.loadJourneys,e=>C(E({},e),{loading:!0})),Y(Me.loadJourneysSuccess,(e,{journeys:t})=>C(E({},e),{journeys:t,selectedIds:e.selectedIds.length>0?e.selectedIds:t.map(n=>n.id),loading:!1})),Y(Me.toggleJourney,(e,{id:t})=>{let n=e.selectedIds.includes(t);return C(E({},e),{selectedIds:n?e.selectedIds.filter(r=>r!==t):[...e.selectedIds,t]})}),Y(Me.selectAll,e=>C(E({},e),{selectedIds:e.journeys.map(t=>t.id)})),Y(Me.deselectAll,e=>C(E({},e),{selectedIds:[]})),Y(U.loadSettingsSuccess,(e,{settings:t})=>{let n=t.selectedJourneyIds;return n&&n.length>0?C(E({},e),{selectedIds:n}):e}));var A0={targetUrl:"http://localhost:3000",browserPath:"",userDataDir:"",windowWidth:1280,windowHeight:720,actionDelay:0,devtools:!1,headless:!1,keepBrowserOpen:!1,settingsPanelOpen:!1,activeTab:"actions",sidebarWidth:240,selectedJourneyIds:[],targetUrlHistory:[],theme:""},Bm=Vr(A0,Y(U.loadSettingsSuccess,(e,{settings:t})=>E(E({},e),t)),Y(U.updateSetting,(e,{key:t,value:n})=>{let r=C(E({},e),{[t]:n});if(t==="targetUrl"&&typeof n=="string"&&n.trim()){let o=e.targetUrlHistory.filter(i=>i!==n);r.targetUrlHistory=[n,...o].slice(0,10)}return r}),Y(U.toggleSettingsPanel,e=>C(E({},e),{settingsPanelOpen:!e.settingsPanelOpen})),Y(U.removeUrlFromHistory,(e,{url:t})=>C(E({},e),{targetUrlHistory:e.targetUrlHistory.filter(n=>n!==t)})));var Aa=class e{actions$=g(Hr);api=g(Pt);store=g(Z);play$=He(()=>this.actions$.pipe(Ue(x.play),Ke(this.store.select(Wl),this.store.select(nm)),fr(([,t,n])=>this.api.runTests(t,n).pipe(Ce(()=>ce)))),{dispatch:!1});pause$=He(()=>this.actions$.pipe(Ue(x.pause),ge(()=>this.api.pauseTests().pipe(Ce(()=>ce)))),{dispatch:!1});resume$=He(()=>this.actions$.pipe(Ue(x.resume),ge(()=>this.api.resumeTests().pipe(Ce(()=>ce)))),{dispatch:!1});step$=He(()=>this.actions$.pipe(Ue(x.step),ge(()=>this.api.stepTests().pipe(Ce(()=>ce)))),{dispatch:!1});stop$=He(()=>this.actions$.pipe(Ue(x.stop),ge(()=>this.api.stopTests().pipe(Ce(()=>ce)))),{dispatch:!1});updateConfig$=He(()=>this.actions$.pipe(Ue(x.updateConfig),ge(({actionDelay:t})=>this.api.updateConfig({actionDelay:t}).pipe(Ce(()=>ce)))),{dispatch:!1});syncBreakpoints$=He(()=>this.actions$.pipe(Ue(x.toggleBreakpoint,x.clearAllBreakpoints),Ke(this.store.select(ya),this.store.select(Wl)),ge(([,t,n])=>{let r=n[0]??"";return r?this.api.setBreakpoints(r,t).pipe(Ce(()=>ce)):ce})),{dispatch:!1});static \u0275fac=function(n){return new(n||e)};static \u0275prov=T({token:e,factory:e.\u0275fac})};var Ra=class e{actions$=g(Hr);api=g(Pt);store=g(Z);themeService=g(mn);loadSettings$=He(()=>this.actions$.pipe(Ue(U.loadSettings),ge(()=>this.api.getSettings()),L(t=>U.loadSettingsSuccess({settings:t}))));applyTheme$=He(()=>this.actions$.pipe(Ue(U.loadSettingsSuccess),lt(({settings:t})=>{this.themeService.applyFromSettings(t.theme)})),{dispatch:!1});saveSettings$=He(()=>this.actions$.pipe(Ue(U.updateSetting,U.toggleSettingsPanel,U.removeUrlFromHistory),Qr(500),Ke(this.store.select(fa)),ge(([,t])=>this.api.saveSettings(t).pipe(Ce(()=>ce)))),{dispatch:!1});static \u0275fac=function(n){return new(n||e)};static \u0275prov=T({token:e,factory:e.\u0275fac})};var Oa=class e{actions$=g(Hr);api=g(Pt);store=g(Z);loadJourneys$=He(()=>this.actions$.pipe(Ue(Me.loadJourneys),ge(()=>this.api.getJourneys().pipe(L(t=>Me.loadJourneysSuccess({journeys:t})),Ce(()=>ce)))));persistSelection$=He(()=>this.actions$.pipe(Ue(Me.toggleJourney,Me.selectAll,Me.deselectAll),Ke(this.store.select($r)),lt(([,t])=>{this.store.dispatch(U.updateSetting({key:"selectedJourneyIds",value:t}))})),{dispatch:!1});static \u0275fac=function(n){return new(n||e)};static \u0275prov=T({token:e,factory:e.\u0275fac})};var Vm={providers:[rg({eventCoalescing:!0}),kl(),Qg({execution:Lm,journeys:jm,settings:Bm}),pm(Aa,Ra,Oa),Pm({maxAge:50,logOnly:!Vo(),name:"Glassbox"})]};xl(Ia,Vm).catch(e=>console.error(e));
|