ompchamber 0.5.0 → 0.6.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.
Files changed (76) hide show
  1. package/README.md +46 -1
  2. package/dist/client/index.html +1 -1
  3. package/dist/client/static/css/{index.5291f58223.css → index.51f68210a5.css} +1 -1
  4. package/dist/client/static/js/async/{3y.ededeebde8.js → 3y.4c2596f64c.js} +3 -3
  5. package/dist/client/static/js/async/73.308dff4da8.js +1 -0
  6. package/dist/client/static/js/async/{ty.3d93cf5f5f.js → 7g.a7814350c3.js} +1 -1
  7. package/dist/client/static/js/async/a.bce4542392.js +1 -0
  8. package/dist/client/static/js/async/g.8515cbc6f7.js +2 -0
  9. package/dist/client/static/js/async/hn.b645041e00.js +1 -0
  10. package/dist/client/static/js/async/{jg.69a4beade8.js → jg.d86ebd4013.js} +1 -1
  11. package/dist/client/static/js/async/l.12dd34e1be.js +1 -0
  12. package/dist/client/static/js/async/ls.9d9a01026c.js +104 -0
  13. package/dist/client/static/js/async/mw.ca1512563c.js +10 -0
  14. package/dist/client/static/js/async/nk.fc7e58325e.js +1 -0
  15. package/dist/client/static/js/async/{q.7fb4d2f374.js → q.542c184fec.js} +3 -3
  16. package/dist/client/static/js/async/t.cda4891526.js +1 -0
  17. package/dist/client/static/js/async/tr.e878658140.js +309 -0
  18. package/dist/client/static/js/async/uf.24ca3d49c3.js +2 -0
  19. package/dist/client/static/js/{index.0ac93ee878.js → index.47d3b04d5f.js} +7 -7
  20. package/dist/client/static/js/{uy.5f791144ce.js → uy.2e8929ed0c.js} +2 -2
  21. package/package.json +13 -5
  22. package/src/cli/lib/args.js +6 -6
  23. package/src/cli/lib/commands/logs.js +76 -34
  24. package/src/cli/lib/commands/restart.js +30 -9
  25. package/src/cli/lib/commands/serve.js +12 -4
  26. package/src/cli/lib/commands/status.js +40 -18
  27. package/src/cli/lib/commands/stop.js +12 -7
  28. package/src/cli/lib/commands/update.js +2 -5
  29. package/src/cli/lib/paths.js +8 -28
  30. package/src/cli/lib/runtime.js +118 -108
  31. package/src/client/components/common/code-editor/index.tsx +5 -1
  32. package/src/client/components/common/code-surface/index.tsx +49 -1
  33. package/src/client/components/common/code-surface/measure.ts +99 -0
  34. package/src/client/components/layout/RightActivityBar.tsx +42 -69
  35. package/src/client/components/layout/desktop-layout/WorkspacePanels.tsx +5 -6
  36. package/src/client/components/layout/desktop-layout/index.tsx +11 -9
  37. package/src/client/components/layout/desktop-layout/resizer/index.tsx +22 -29
  38. package/src/client/components/layout/desktop-layout/resizer/utils.test.ts +33 -0
  39. package/src/client/components/layout/desktop-layout/resizer/utils.ts +34 -0
  40. package/src/client/components/mobile/RightSidebar.tsx +42 -119
  41. package/src/client/components/mobile/mobile-main-view/Header.tsx +17 -1
  42. package/src/client/components/workspace/editor/index.tsx +4 -1
  43. package/src/client/hooks/editor/use-file-editor.test.ts +158 -0
  44. package/src/client/hooks/editor/use-file-editor.ts +35 -19
  45. package/src/server/index.ts +51 -1
  46. package/src/server/lib/lifecycle/identity.ts +108 -0
  47. package/src/server/lib/lifecycle/instance.ts +102 -0
  48. package/src/server/lib/lifecycle/occupant.ts +101 -0
  49. package/src/server/lib/lifecycle/paths.ts +50 -0
  50. package/src/server/lib/lifecycle/port-guard.ts +170 -0
  51. package/src/server/lib/lifecycle/probe.ts +121 -0
  52. package/src/server/plugins/static.test.ts +63 -0
  53. package/src/server/plugins/static.ts +28 -4
  54. package/src/server/routes/health/probe.ts +8 -0
  55. package/src/shared/lib/markdown/mermaid.ts +8 -0
  56. package/src/shared/lib/workspace/panel-widths.test.ts +5 -5
  57. package/src/shared/lib/workspace/panel-widths.ts +23 -10
  58. package/src/shared/lib/workspace/right-panels.ts +10 -4
  59. package/dist/client/static/js/async/73.50280ce58d.js +0 -1
  60. package/dist/client/static/js/async/a.e05da304c8.js +0 -10
  61. package/dist/client/static/js/async/ar.1e14da5588.js +0 -1
  62. package/dist/client/static/js/async/g.7a4bbd4798.js +0 -2
  63. package/dist/client/static/js/async/hn.7568bdb58b.js +0 -1
  64. package/dist/client/static/js/async/l.102a97fce6.js +0 -104
  65. package/dist/client/static/js/async/l6.c56640c205.js +0 -1
  66. package/dist/client/static/js/async/nk.6de011832e.js +0 -1
  67. package/dist/client/static/js/async/t.cb3fcf8615.js +0 -1
  68. package/dist/client/static/js/async/uf.46ad6209fa.js +0 -2
  69. package/dist/client/static/js/async/vn.e98e2f3b61.js +0 -309
  70. /package/dist/client/static/js/async/{3y.ededeebde8.js.LICENSE.txt → 3y.4c2596f64c.js.LICENSE.txt} +0 -0
  71. /package/dist/client/static/js/async/{g.7a4bbd4798.js.LICENSE.txt → g.8515cbc6f7.js.LICENSE.txt} +0 -0
  72. /package/dist/client/static/js/async/{a.e05da304c8.js.LICENSE.txt → mw.ca1512563c.js.LICENSE.txt} +0 -0
  73. /package/dist/client/static/js/async/{q.7fb4d2f374.js.LICENSE.txt → q.542c184fec.js.LICENSE.txt} +0 -0
  74. /package/dist/client/static/js/async/{uf.46ad6209fa.js.LICENSE.txt → uf.24ca3d49c3.js.LICENSE.txt} +0 -0
  75. /package/dist/client/static/js/{index.0ac93ee878.js.LICENSE.txt → index.47d3b04d5f.js.LICENSE.txt} +0 -0
  76. /package/dist/client/static/js/{uy.5f791144ce.js.LICENSE.txt → uy.2e8929ed0c.js.LICENSE.txt} +0 -0
@@ -0,0 +1 @@
1
+ "use strict";(self.rspackChunkompchamber=self.rspackChunkompchamber||[]).push([["l"],{DW(t,e,r){r.d(e,{T:()=>I});var n=r("QU"),i=r("UR"),o=r("Hs"),u=r("q9"),s=r("Y4"),a=r("j7V"),c=r("PP"),f=r("FI"),h=r("Riw"),l=r("sA"),A=r("YrZ"),d=r("z1"),p=Object.prototype.hasOwnProperty,v=function(t){if(null==t)return!0;if((0,h.A)(t)&&((0,f.A)(t)||"string"==typeof t||"function"==typeof t.splice||(0,l.A)(t)||(0,d.A)(t)||(0,c.A)(t)))return!t.length;var e=(0,a.A)(t);if("[object Map]"==e||"[object Set]"==e)return!t.size;if((0,A.A)(t))return!(0,s.A)(t).length;for(var r in t)if(p.call(t,r))return!1;return!0},_=r("Y7"),b=r("Dm"),y=r("tS"),g=r("ln"),j=r("Ls"),m=r("TQ"),w=function(t){return t!=t},O=function(t,e,r){for(var n=r-1,i=t.length;++n<i;)if(t[n]===e)return n;return -1},P=function(t,e){return!!(null==t?0:t.length)&&(e==e?O(t,e,0):(0,m.A)(t,w,0))>-1},D=function(t,e,r){for(var n=-1,i=null==t?0:t.length;++n<i;)if(r(e,t[n]))return!0;return!1},C=r("WI"),F=r("CUN"),E=r("We"),L=F.A&&1/(0,E.A)(new F.A([,-0]))[1]==1/0?function(t){return new F.A(t)}:function(){},z=function(t,e,r){var n=-1,i=P,o=t.length,u=!0,s=[],a=s;if(r)u=!1,i=D;else if(o>=200){var c=e?null:L(t);if(c)return(0,E.A)(c);u=!1,i=C.A,a=new j.A}else a=e?[]:s;t:for(;++n<o;){var f=t[n],h=e?e(f):f;if(f=r||0!==f?f:0,u&&h==h){for(var l=a.length;l--;)if(a[l]===h)continue t;e&&a.push(h),s.push(f)}else i(a,h,r)||(a!==s&&a.push(h),s.push(f))}return s},N=r("Fm"),S=(0,g.A)(function(t){return z((0,y.A)(t,1,N.A,!0))}),x=r("Ol"),k=r("ja6");class I{constructor(t={}){this._isDirected=!Object.prototype.hasOwnProperty.call(t,"directed")||t.directed,this._isMultigraph=!!Object.prototype.hasOwnProperty.call(t,"multigraph")&&t.multigraph,this._isCompound=!!Object.prototype.hasOwnProperty.call(t,"compound")&&t.compound,this._label=void 0,this._defaultNodeLabelFn=n.A(void 0),this._defaultEdgeLabelFn=n.A(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children["\0"]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(t){return this._label=t,this}graph(){return this._label}setDefaultNodeLabel(t){return i.A(t)||(t=n.A(t)),this._defaultNodeLabelFn=t,this}nodeCount(){return this._nodeCount}nodes(){return o.A(this._nodes)}sources(){var t=this;return u.A(this.nodes(),function(e){return v(t._in[e])})}sinks(){var t=this;return u.A(this.nodes(),function(e){return v(t._out[e])})}setNodes(t,e){var r=arguments,n=this;return _.A(t,function(t){r.length>1?n.setNode(t,e):n.setNode(t)}),this}setNode(t,e){return Object.prototype.hasOwnProperty.call(this._nodes,t)?arguments.length>1&&(this._nodes[t]=e):(this._nodes[t]=arguments.length>1?e:this._defaultNodeLabelFn(t),this._isCompound&&(this._parent[t]="\0",this._children[t]={},this._children["\0"][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount),this}node(t){return this._nodes[t]}hasNode(t){return Object.prototype.hasOwnProperty.call(this._nodes,t)}removeNode(t){if(Object.prototype.hasOwnProperty.call(this._nodes,t)){var e=t=>this.removeEdge(this._edgeObjs[t]);delete this._nodes[t],this._isCompound&&(this._removeFromParentsChildList(t),delete this._parent[t],_.A(this.children(t),t=>{this.setParent(t)}),delete this._children[t]),_.A(o.A(this._in[t]),e),delete this._in[t],delete this._preds[t],_.A(o.A(this._out[t]),e),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this}setParent(t,e){if(!this._isCompound)throw Error("Cannot set parent in a non-compound graph");if(b.A(e))e="\0";else{e+="";for(var r=e;!b.A(r);r=this.parent(r))if(r===t)throw Error("Setting "+e+" as parent of "+t+" would create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this}_removeFromParentsChildList(t){delete this._children[this._parent[t]][t]}parent(t){if(this._isCompound){var e=this._parent[t];if("\0"!==e)return e}}children(t){if(b.A(t)&&(t="\0"),this._isCompound){var e=this._children[t];if(e)return o.A(e)}else if("\0"===t)return this.nodes();else if(this.hasNode(t))return[]}predecessors(t){var e=this._preds[t];if(e)return o.A(e)}successors(t){var e=this._sucs[t];if(e)return o.A(e)}neighbors(t){var e=this.predecessors(t);if(e)return S(e,this.successors(t))}isLeaf(t){return 0===(this.isDirected()?this.successors(t):this.neighbors(t)).length}filterNodes(t){var e=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});e.setGraph(this.graph());var r=this;_.A(this._nodes,function(r,n){t(n)&&e.setNode(n,r)}),_.A(this._edgeObjs,function(t){e.hasNode(t.v)&&e.hasNode(t.w)&&e.setEdge(t,r.edge(t))});var n={};return this._isCompound&&_.A(e.nodes(),function(t){e.setParent(t,function t(i){var o=r.parent(i);return void 0===o||e.hasNode(o)?(n[i]=o,o):o in n?n[o]:t(o)}(t))}),e}setDefaultEdgeLabel(t){return i.A(t)||(t=n.A(t)),this._defaultEdgeLabelFn=t,this}edgeCount(){return this._edgeCount}edges(){return x.A(this._edgeObjs)}setPath(t,e){var r=this,n=arguments;return k.A(t,function(t,i){return n.length>1?r.setEdge(t,i,e):r.setEdge(t,i),i}),this}setEdge(){var t,e,r,n,i=!1,o=arguments[0];"object"==typeof o&&null!==o&&"v"in o?(t=o.v,e=o.w,r=o.name,2==arguments.length&&(n=arguments[1],i=!0)):(t=o,e=arguments[1],r=arguments[3],arguments.length>2&&(n=arguments[2],i=!0)),t=""+t,e=""+e,b.A(r)||(r=""+r);var u=T(this._isDirected,t,e,r);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,u))return i&&(this._edgeLabels[u]=n),this;if(!b.A(r)&&!this._isMultigraph)throw Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[u]=i?n:this._defaultEdgeLabelFn(t,e,r);var s=function(t,e,r,n){var i=""+e,o=""+r;if(!t&&i>o){var u=i;i=o,o=u}var s={v:i,w:o};return n&&(s.name=n),s}(this._isDirected,t,e,r);return t=s.v,e=s.w,Object.freeze(s),this._edgeObjs[u]=s,R(this._preds[e],t),R(this._sucs[t],e),this._in[e][u]=s,this._out[t][u]=s,this._edgeCount++,this}edge(t,e,r){var n=1==arguments.length?U(this._isDirected,arguments[0]):T(this._isDirected,t,e,r);return this._edgeLabels[n]}hasEdge(t,e,r){var n=1==arguments.length?U(this._isDirected,arguments[0]):T(this._isDirected,t,e,r);return Object.prototype.hasOwnProperty.call(this._edgeLabels,n)}removeEdge(t,e,r){var n=1==arguments.length?U(this._isDirected,arguments[0]):T(this._isDirected,t,e,r),i=this._edgeObjs[n];return i&&(t=i.v,e=i.w,delete this._edgeLabels[n],delete this._edgeObjs[n],W(this._preds[e],t),W(this._sucs[t],e),delete this._in[e][n],delete this._out[t][n],this._edgeCount--),this}inEdges(t,e){var r=this._in[t];if(r){var n=x.A(r);return e?u.A(n,function(t){return t.v===e}):n}}outEdges(t,e){var r=this._out[t];if(r){var n=x.A(r);return e?u.A(n,function(t){return t.w===e}):n}}nodeEdges(t,e){var r=this.inEdges(t,e);if(r)return r.concat(this.outEdges(t,e))}}function R(t,e){t[e]?t[e]++:t[e]=1}function W(t,e){--t[e]||delete t[e]}function T(t,e,r,n){var i=""+e,o=""+r;if(!t&&i>o){var u=i;i=o,o=u}return i+"\x01"+o+"\x01"+(b.A(n)?"\0":n)}function U(t,e){return T(t,e.v,e.w,e.name)}I.prototype._nodeCount=0,I.prototype._edgeCount=0},v2(t,e,r){var n=r("DW");r.d(e,{T:()=>n.T})},PE(t,e,r){r.d(e,{A:()=>s});var n=r("cN"),i=function(t,e){for(var r=t.length;r--;)if((0,n.A)(t[r][0],e))return r;return -1},o=Array.prototype.splice;function u(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}u.prototype.clear=function(){this.__data__=[],this.size=0},u.prototype.delete=function(t){var e=this.__data__,r=i(e,t);return!(r<0)&&(r==e.length-1?e.pop():o.call(e,r,1),--this.size,!0)},u.prototype.get=function(t){var e=this.__data__,r=i(e,t);return r<0?void 0:e[r][1]},u.prototype.has=function(t){return i(this.__data__,t)>-1},u.prototype.set=function(t,e){var r=this.__data__,n=i(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this};var s=u},Oa(t,e,r){var n=r("eD"),i=r("W0m");e.A=(0,n.A)(i.A,"Map")},DX(t,e,r){r.d(e,{A:()=>l});var n=(0,r("eD").A)(Object,"create"),i=Object.prototype.hasOwnProperty,o=Object.prototype.hasOwnProperty;function u(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}u.prototype.clear=function(){this.__data__=n?n(null):{},this.size=0},u.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=!!e,e},u.prototype.get=function(t){var e=this.__data__;if(n){var r=e[t];return"__lodash_hash_undefined__"===r?void 0:r}return i.call(e,t)?e[t]:void 0},u.prototype.has=function(t){var e=this.__data__;return n?void 0!==e[t]:o.call(e,t)},u.prototype.set=function(t,e){var r=this.__data__;return this.size+=+!this.has(t),r[t]=n&&void 0===e?"__lodash_hash_undefined__":e,this};var s=r("PE"),a=r("Oa"),c=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t},f=function(t,e){var r=t.__data__;return c(e)?r["string"==typeof e?"string":"hash"]:r.map};function h(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}h.prototype.clear=function(){this.size=0,this.__data__={hash:new u,map:new(a.A||s.A),string:new u}},h.prototype.delete=function(t){var e=f(this,t).delete(t);return this.size-=!!e,e},h.prototype.get=function(t){return f(this,t).get(t)},h.prototype.has=function(t){return f(this,t).has(t)},h.prototype.set=function(t,e){var r=f(this,t),n=r.size;return r.set(t,e),this.size+=+(r.size!=n),this};var l=h},CUN(t,e,r){var n=r("eD"),i=r("W0m");e.A=(0,n.A)(i.A,"Set")},Ls(t,e,r){r.d(e,{A:()=>o});var n=r("DX");function i(t){var e=-1,r=null==t?0:t.length;for(this.__data__=new n.A;++e<r;)this.add(t[e])}i.prototype.add=i.prototype.push=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},i.prototype.has=function(t){return this.__data__.has(t)};var o=i},pb(t,e,r){r.d(e,{A:()=>s});var n=r("PE"),i=r("Oa"),o=r("DX");function u(t){var e=this.__data__=new n.A(t);this.size=e.size}u.prototype.clear=function(){this.__data__=new n.A,this.size=0},u.prototype.delete=function(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r},u.prototype.get=function(t){return this.__data__.get(t)},u.prototype.has=function(t){return this.__data__.has(t)},u.prototype.set=function(t,e){var r=this.__data__;if(r instanceof n.A){var u=r.__data__;if(!i.A||u.length<199)return u.push([t,e]),this.size=++r.size,this;r=this.__data__=new o.A(u)}return r.set(t,e),this.size=r.size,this};var s=u},er(t,e,r){e.A=r("W0m").A.Symbol},Ry(t,e,r){e.A=r("W0m").A.Uint8Array},X2(t,e){e.A=function(t,e){for(var r=-1,n=null==t?0:t.length;++r<n&&!1!==e(t[r],r,t););return t}},KT(t,e){e.A=function(t,e){for(var r=-1,n=null==t?0:t.length,i=0,o=[];++r<n;){var u=t[r];e(u,r,t)&&(o[i++]=u)}return o}},jJ(t,e,r){r.d(e,{A:()=>f});var n=function(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n},i=r("PP"),o=r("FI"),u=r("sA"),s=r("wAQ"),a=r("z1"),c=Object.prototype.hasOwnProperty,f=function(t,e){var r=(0,o.A)(t),f=!r&&(0,i.A)(t),h=!r&&!f&&(0,u.A)(t),l=!r&&!f&&!h&&(0,a.A)(t),A=r||f||h||l,d=A?n(t.length,String):[],p=d.length;for(var v in t)(e||c.call(t,v))&&!(A&&("length"==v||h&&("offset"==v||"parent"==v)||l&&("buffer"==v||"byteLength"==v||"byteOffset"==v)||(0,s.A)(v,p)))&&d.push(v);return d}},Ka(t,e){e.A=function(t,e){for(var r=-1,n=null==t?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}},LE(t,e){e.A=function(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}},CZ(t,e,r){r.d(e,{A:()=>u});var n,i=r("rw"),o=r("Riw"),u=(n=i.A,function(t,e){if(null==t)return t;if(!(0,o.A)(t))return n(t,e);for(var r=t.length,i=-1,u=Object(t);++i<r&&!1!==e(u[i],i,u););return t})},TQ(t,e){e.A=function(t,e,r,n){for(var i=t.length,o=r+(n?1:-1);n?o--:++o<i;)if(e(t[o],o,t))return o;return -1}},tS(t,e,r){r.d(e,{A:()=>c});var n=r("LE"),i=r("er"),o=r("PP"),u=r("FI"),s=i.A?i.A.isConcatSpreadable:void 0,a=function(t){return(0,u.A)(t)||(0,o.A)(t)||!!(s&&t&&t[s])},c=function t(e,r,i,o,u){var s=-1,c=e.length;for(i||(i=a),u||(u=[]);++s<c;){var f=e[s];r>0&&i(f)?r>1?t(f,r-1,i,o,u):(0,n.A)(u,f):o||(u[u.length]=f)}return u}},Yj(t,e,r){r.d(e,{A:()=>n});var n=function(t,e,r){for(var n=-1,i=Object(t),o=r(t),u=o.length;u--;){var s=o[++n];if(!1===e(i[s],s,i))break}return t}},rw(t,e,r){var n=r("Yj"),i=r("Hs");e.A=function(t,e){return t&&(0,n.A)(t,e,i.A)}},hW(t,e,r){var n=r("eX"),i=r("ZR");e.A=function(t,e){e=(0,n.A)(e,t);for(var r=0,o=e.length;null!=t&&r<o;)t=t[(0,i.A)(e[r++])];return r&&r==o?t:void 0}},V8(t,e,r){var n=r("LE"),i=r("FI");e.A=function(t,e,r){var o=e(t);return(0,i.A)(t)?o:(0,n.A)(o,r(t))}},FA(t,e,r){r.d(e,{A:()=>h});var n=r("er"),i=Object.prototype,o=i.hasOwnProperty,u=i.toString,s=n.A?n.A.toStringTag:void 0,a=function(t){var e=o.call(t,s),r=t[s];try{t[s]=void 0;var n=!0}catch(t){}var i=u.call(t);return n&&(e?t[s]=r:delete t[s]),i},c=Object.prototype.toString,f=n.A?n.A.toStringTag:void 0,h=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":f&&f in Object(t)?a(t):c.call(t)}},n8(t,e,r){r.d(e,{A:()=>Z});var n=r("pb"),i=r("Ls"),o=function(t,e){for(var r=-1,n=null==t?0:t.length;++r<n;)if(e(t[r],r,t))return!0;return!1},u=r("WI"),s=function(t,e,r,n,s,a){var c=1&r,f=t.length,h=e.length;if(f!=h&&!(c&&h>f))return!1;var l=a.get(t),A=a.get(e);if(l&&A)return l==e&&A==t;var d=-1,p=!0,v=2&r?new i.A:void 0;for(a.set(t,e),a.set(e,t);++d<f;){var _=t[d],b=e[d];if(n)var y=c?n(b,_,d,e,t,a):n(_,b,d,t,e,a);if(void 0!==y){if(y)continue;p=!1;break}if(v){if(!o(e,function(t,e){if(!(0,u.A)(v,e)&&(_===t||s(_,t,r,n,a)))return v.push(e)})){p=!1;break}}else if(!(_===b||s(_,b,r,n,a))){p=!1;break}}return a.delete(t),a.delete(e),p},a=r("er"),c=r("Ry"),f=r("cN"),h=function(t){var e=-1,r=Array(t.size);return t.forEach(function(t,n){r[++e]=[n,t]}),r},l=r("We"),A=a.A?a.A.prototype:void 0,d=A?A.valueOf:void 0,p=function(t,e,r,n,i,o,u){switch(r){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)break;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":if(t.byteLength!=e.byteLength||!o(new c.A(t),new c.A(e)))break;return!0;case"[object Boolean]":case"[object Date]":case"[object Number]":return(0,f.A)(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var a=h;case"[object Set]":var A=1&n;if(a||(a=l.A),t.size!=e.size&&!A)break;var p=u.get(t);if(p)return p==e;n|=2,u.set(t,e);var v=s(a(t),a(e),n,i,o,u);return u.delete(t),v;case"[object Symbol]":if(d)return d.call(t)==d.call(e)}return!1},v=r("JJ"),_=Object.prototype.hasOwnProperty,b=function(t,e,r,n,i,o){var u=1&r,s=(0,v.A)(t),a=s.length;if(a!=(0,v.A)(e).length&&!u)return!1;for(var c=a;c--;){var f=s[c];if(!(u?f in e:_.call(e,f)))return!1}var h=o.get(t),l=o.get(e);if(h&&l)return h==e&&l==t;var A=!0;o.set(t,e),o.set(e,t);for(var d=u;++c<a;){var p=t[f=s[c]],b=e[f];if(n)var y=u?n(b,p,f,e,t,o):n(p,b,f,t,e,o);if(!(void 0===y?p===b||i(p,b,r,n,o):y)){A=!1;break}d||(d="constructor"==f)}if(A&&!d){var g=t.constructor,j=e.constructor;g!=j&&"constructor"in t&&"constructor"in e&&!("function"==typeof g&&g instanceof g&&"function"==typeof j&&j instanceof j)&&(A=!1)}return o.delete(t),o.delete(e),A},y=r("j7V"),g=r("FI"),j=r("sA"),m=r("z1"),w="[object Arguments]",O="[object Array]",P="[object Object]",D=Object.prototype.hasOwnProperty,C=function(t,e,r,i,o,u){var a=(0,g.A)(t),c=(0,g.A)(e),f=a?O:(0,y.A)(t),h=c?O:(0,y.A)(e);f=f==w?P:f,h=h==w?P:h;var l=f==P,A=h==P,d=f==h;if(d&&(0,j.A)(t)){if(!(0,j.A)(e))return!1;a=!0,l=!1}if(d&&!l)return u||(u=new n.A),a||(0,m.A)(t)?s(t,e,r,i,o,u):p(t,e,f,r,i,o,u);if(!(1&r)){var v=l&&D.call(t,"__wrapped__"),_=A&&D.call(e,"__wrapped__");if(v||_){var C=v?t.value():t,F=_?e.value():e;return u||(u=new n.A),o(C,F,r,i,u)}}return!!d&&(u||(u=new n.A),b(t,e,r,i,o,u))},F=r("ic"),E=function t(e,r,n,i,o){return e===r||(null!=e&&null!=r&&((0,F.A)(e)||(0,F.A)(r))?C(e,r,n,i,t,o):e!=e&&r!=r)},L=function(t,e,r,i){var o=r.length,u=o,s=!i;if(null==t)return!u;for(t=Object(t);o--;){var a=r[o];if(s&&a[2]?a[1]!==t[a[0]]:!(a[0]in t))return!1}for(;++o<u;){var c=(a=r[o])[0],f=t[c],h=a[1];if(s&&a[2]){if(void 0===f&&!(c in t))return!1}else{var l=new n.A;if(i)var A=i(f,h,c,t,e,l);if(!(void 0===A?E(h,f,3,i,l):A))return!1}}return!0},z=r("uD"),N=function(t){return t==t&&!(0,z.A)(t)},S=r("Hs"),x=function(t){for(var e=(0,S.A)(t),r=e.length;r--;){var n=e[r],i=t[n];e[r]=[n,i,N(i)]}return e},k=function(t,e){return function(r){return null!=r&&r[t]===e&&(void 0!==e||t in Object(r))}},I=function(t){var e=x(t);return 1==e.length&&e[0][2]?k(e[0][0],e[0][1]):function(r){return r===t||L(r,t,e)}},R=r("hW"),W=function(t,e,r){var n=null==t?void 0:(0,R.A)(t,e);return void 0===n?r:n},T=r("Qs"),U=r("hT"),M=r("ZR"),B=r("LP"),V=r("kd"),X=function(t){return(0,U.A)(t)?(0,V.A)((0,M.A)(t)):function(e){return(0,R.A)(e,t)}},Z=function(t){if("function"==typeof t)return t;if(null==t)return B.A;if("object"==typeof t){var e,r;return(0,g.A)(t)?(e=t[0],r=t[1],(0,U.A)(e)&&N(r)?k((0,M.A)(e),r):function(t){var n=W(t,e);return void 0===n&&n===r?(0,T.A)(t,e):E(r,n,3)}):I(t)}return X(t)}},Y4(t,e,r){r.d(e,{A:()=>u});var n=r("YrZ"),i=(0,r("oP").A)(Object.keys,Object),o=Object.prototype.hasOwnProperty,u=function(t){if(!(0,n.A)(t))return i(t);var e=[];for(var r in Object(t))o.call(t,r)&&"constructor"!=r&&e.push(r);return e}},kd(t,e){e.A=function(t){return function(e){return null==e?void 0:e[t]}}},ln(t,e,r){var n=r("LP"),i=r("Rs"),o=r("dN");e.A=function(t,e){return(0,o.A)((0,i.A)(t,e,n.A),t+"")}},mX3(t,e){e.A=function(t){return function(e){return t(e)}}},WI(t,e){e.A=function(t,e){return t.has(e)}},uh(t,e,r){var n=r("LP");e.A=function(t){return"function"==typeof t?t:n.A}},eX(t,e,r){r.d(e,{A:()=>A});var n,i,o=r("FI"),u=r("hT"),s=r("DX");function a(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw TypeError("Expected a function");var r=function(){var n=arguments,i=e?e.apply(this,n):n[0],o=r.cache;if(o.has(i))return o.get(i);var u=t.apply(this,n);return r.cache=o.set(i,u)||o,u};return r.cache=new(a.Cache||s.A),r}a.Cache=s.A;var c=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,f=/\\(\\)?/g,h=(i=(n=a(function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(c,function(t,r,n,i){e.push(n?i.replace(f,"$1"):r||t)}),e},function(t){return 500===i.size&&i.clear(),t})).cache,n),l=r("DS"),A=function(t,e){return(0,o.A)(t)?t:(0,u.A)(t,e)?[t]:h((0,l.A)(t))}},Jy(t,e,r){var n=r("eD");e.A=function(){try{var t=(0,n.A)(Object,"defineProperty");return t({},"",{}),t}catch(t){}}()},ny(t,e){e.A="object"==typeof global&&global&&global.Object===Object&&global},JJ(t,e,r){var n=r("V8"),i=r("Fe"),o=r("Hs");e.A=function(t){return(0,n.A)(t,o.A,i.A)}},eD(t,e,r){r.d(e,{A:()=>p});var n,i=r("UR"),o=r("W0m").A["__core-js_shared__"],u=(n=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",s=r("uD"),a=r("m7"),c=/^\[object .+?Constructor\]$/,f=Object.prototype,h=Function.prototype.toString,l=f.hasOwnProperty,A=RegExp("^"+h.call(l).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),d=function(t){return!!(0,s.A)(t)&&(!u||!(u in t))&&((0,i.A)(t)?A:c).test((0,a.A)(t))},p=function(t,e){var r=null==t?void 0:t[e];return d(r)?r:void 0}},Fe(t,e,r){var n=r("KT"),i=r("Jx"),o=Object.prototype.propertyIsEnumerable,u=Object.getOwnPropertySymbols;e.A=u?function(t){return null==t?[]:(t=Object(t),(0,n.A)(u(t),function(e){return o.call(t,e)}))}:i.A},j7V(t,e,r){r.d(e,{A:()=>w});var n=r("eD"),i=r("W0m"),o=(0,n.A)(i.A,"DataView"),u=r("Oa"),s=(0,n.A)(i.A,"Promise"),a=r("CUN"),c=(0,n.A)(i.A,"WeakMap"),f=r("FA"),h=r("m7"),l="[object Map]",A="[object Promise]",d="[object Set]",p="[object WeakMap]",v="[object DataView]",_=(0,h.A)(o),b=(0,h.A)(u.A),y=(0,h.A)(s),g=(0,h.A)(a.A),j=(0,h.A)(c),m=f.A;(o&&m(new o(new ArrayBuffer(1)))!=v||u.A&&m(new u.A)!=l||s&&m(s.resolve())!=A||a.A&&m(new a.A)!=d||c&&m(new c)!=p)&&(m=function(t){var e=(0,f.A)(t),r="[object Object]"==e?t.constructor:void 0,n=r?(0,h.A)(r):"";if(n)switch(n){case _:return v;case b:return l;case y:return A;case g:return d;case j:return p}return e});var w=m},gd(t,e,r){var n=r("eX"),i=r("PP"),o=r("FI"),u=r("wAQ"),s=r("wy"),a=r("ZR");e.A=function(t,e,r){e=(0,n.A)(e,t);for(var c=-1,f=e.length,h=!1;++c<f;){var l=(0,a.A)(e[c]);if(!(h=null!=t&&r(t,l)))break;t=t[l]}return h||++c!=f?h:!!(f=null==t?0:t.length)&&(0,s.A)(f)&&(0,u.A)(l,f)&&((0,o.A)(t)||(0,i.A)(t))}},wAQ(t,e){var r=/^(?:0|[1-9]\d*)$/;e.A=function(t,e){var n=typeof t;return!!(e=null==e?0x1fffffffffffff:e)&&("number"==n||"symbol"!=n&&r.test(t))&&t>-1&&t%1==0&&t<e}},hT(t,e,r){var n=r("FI"),i=r("B7"),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,u=/^\w*$/;e.A=function(t,e){if((0,n.A)(t))return!1;var r=typeof t;return!!("number"==r||"symbol"==r||"boolean"==r||null==t||(0,i.A)(t))||u.test(t)||!o.test(t)||null!=e&&t in Object(e)}},YrZ(t,e){var r=Object.prototype;e.A=function(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||r)}},Vl(t,e,r){var n=r("ny"),i="object"==typeof exports&&exports&&!exports.nodeType&&exports,o=i&&"object"==typeof module&&module&&!module.nodeType&&module,u=o&&o.exports===i&&n.A.process;e.A=function(){try{var t=o&&o.require&&o.require("util").types;if(t)return t;return u&&u.binding&&u.binding("util")}catch(t){}}()},oP(t,e){e.A=function(t,e){return function(r){return t(e(r))}}},Rs(t,e,r){r.d(e,{A:()=>o});var n=function(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)},i=Math.max,o=function(t,e,r){return e=i(void 0===e?t.length-1:e,0),function(){for(var o=arguments,u=-1,s=i(o.length-e,0),a=Array(s);++u<s;)a[u]=o[e+u];u=-1;for(var c=Array(e+1);++u<e;)c[u]=o[u];return c[e]=r(a),n(t,this,c)}}},W0m(t,e,r){var n=r("ny"),i="object"==typeof self&&self&&self.Object===Object&&self;e.A=n.A||i||Function("return this")()},We(t,e){e.A=function(t){var e=-1,r=Array(t.size);return t.forEach(function(t){r[++e]=t}),r}},dN(t,e,r){r.d(e,{A:()=>f});var n,i,o=r("QU"),u=r("Jy"),s=r("LP"),a=u.A?function(t,e){return(0,u.A)(t,"toString",{configurable:!0,enumerable:!1,value:(0,o.A)(e),writable:!0})}:s.A,c=Date.now,f=(n=0,i=0,function(){var t=c(),e=16-(t-i);if(i=t,e>0){if(++n>=800)return arguments[0]}else n=0;return a.apply(void 0,arguments)})},ZR(t,e,r){var n=r("B7");e.A=function(t){if("string"==typeof t||(0,n.A)(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}},m7(t,e){var r=Function.prototype.toString;e.A=function(t){if(null!=t){try{return r.call(t)}catch(t){}try{return t+""}catch(t){}}return""}},QU(t,e){e.A=function(t){return function(){return t}}},cN(t,e){e.A=function(t,e){return t===e||t!=t&&e!=e}},q9(t,e,r){r.d(e,{A:()=>a});var n=r("KT"),i=r("CZ"),o=function(t,e){var r=[];return(0,i.A)(t,function(t,n,i){e(t,n,i)&&r.push(t)}),r},u=r("n8"),s=r("FI"),a=function(t,e){return((0,s.A)(t)?n.A:o)(t,(0,u.A)(e,3))}},Y7(t,e,r){var n=r("X2"),i=r("CZ"),o=r("uh"),u=r("FI");e.A=function(t,e){return((0,u.A)(t)?n.A:i.A)(t,(0,o.A)(e))}},Qs(t,e,r){r.d(e,{A:()=>o});var n=function(t,e){return null!=t&&e in Object(t)},i=r("gd"),o=function(t,e){return null!=t&&(0,i.A)(t,e,n)}},LP(t,e){e.A=function(t){return t}},PP(t,e,r){r.d(e,{A:()=>c});var n=r("FA"),i=r("ic"),o=function(t){return(0,i.A)(t)&&"[object Arguments]"==(0,n.A)(t)},u=Object.prototype,s=u.hasOwnProperty,a=u.propertyIsEnumerable,c=o(function(){return arguments}())?o:function(t){return(0,i.A)(t)&&s.call(t,"callee")&&!a.call(t,"callee")}},FI(t,e){e.A=Array.isArray},Riw(t,e,r){var n=r("UR"),i=r("wy");e.A=function(t){return null!=t&&(0,i.A)(t.length)&&!(0,n.A)(t)}},Fm(t,e,r){var n=r("Riw"),i=r("ic");e.A=function(t){return(0,i.A)(t)&&(0,n.A)(t)}},sA(t,e,r){r.d(e,{A:()=>s});var n=r("W0m"),i="object"==typeof exports&&exports&&!exports.nodeType&&exports,o=i&&"object"==typeof module&&module&&!module.nodeType&&module,u=o&&o.exports===i?n.A.Buffer:void 0,s=(u?u.isBuffer:void 0)||function(){return!1}},UR(t,e,r){var n=r("FA"),i=r("uD");e.A=function(t){if(!(0,i.A)(t))return!1;var e=(0,n.A)(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},wy(t,e){e.A=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=0x1fffffffffffff}},uD(t,e){e.A=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}},ic(t,e){e.A=function(t){return null!=t&&"object"==typeof t}},B7(t,e,r){var n=r("FA"),i=r("ic");e.A=function(t){return"symbol"==typeof t||(0,i.A)(t)&&"[object Symbol]"==(0,n.A)(t)}},z1(t,e,r){r.d(e,{A:()=>f});var n=r("FA"),i=r("wy"),o=r("ic"),u={};u["[object Float32Array]"]=u["[object Float64Array]"]=u["[object Int8Array]"]=u["[object Int16Array]"]=u["[object Int32Array]"]=u["[object Uint8Array]"]=u["[object Uint8ClampedArray]"]=u["[object Uint16Array]"]=u["[object Uint32Array]"]=!0,u["[object Arguments]"]=u["[object Array]"]=u["[object ArrayBuffer]"]=u["[object Boolean]"]=u["[object DataView]"]=u["[object Date]"]=u["[object Error]"]=u["[object Function]"]=u["[object Map]"]=u["[object Number]"]=u["[object Object]"]=u["[object RegExp]"]=u["[object Set]"]=u["[object String]"]=u["[object WeakMap]"]=!1;var s=r("mX3"),a=r("Vl"),c=a.A&&a.A.isTypedArray,f=c?(0,s.A)(c):function(t){return(0,o.A)(t)&&(0,i.A)(t.length)&&!!u[(0,n.A)(t)]}},Dm(t,e){e.A=function(t){return void 0===t}},Hs(t,e,r){var n=r("jJ"),i=r("Y4"),o=r("Riw");e.A=function(t){return(0,o.A)(t)?(0,n.A)(t):(0,i.A)(t)}},ja6(t,e,r){r.d(e,{A:()=>a});var n=function(t,e,r,n){var i=-1,o=null==t?0:t.length;for(n&&o&&(r=t[++i]);++i<o;)r=e(r,t[i],i,t);return r},i=r("CZ"),o=r("n8"),u=function(t,e,r,n,i){return i(t,function(t,i,o){r=n?(n=!1,t):e(r,t,i,o)}),r},s=r("FI"),a=function(t,e,r){var a=(0,s.A)(t)?n:u,c=arguments.length<3;return a(t,(0,o.A)(e,4),r,c,i.A)}},Jx(t,e){e.A=function(){return[]}},DS(t,e,r){r.d(e,{A:()=>f});var n=r("er"),i=r("Ka"),o=r("FI"),u=r("B7"),s=n.A?n.A.prototype:void 0,a=s?s.toString:void 0,c=function t(e){if("string"==typeof e)return e;if((0,o.A)(e))return(0,i.A)(e,t)+"";if((0,u.A)(e))return a?a.call(e):"";var r=e+"";return"0"==r&&1/e==-1/0?"-0":r},f=function(t){return null==t?"":c(t)}},Ol(t,e,r){r.d(e,{A:()=>o});var n=r("Ka"),i=r("Hs"),o=function(t){var e;return null==t?[]:(e=(0,i.A)(t),(0,n.A)(e,function(e){return t[e]}))}}}]);
@@ -0,0 +1,104 @@
1
+ "use strict";(self.rspackChunkompchamber=self.rspackChunkompchamber||[]).push([["ls"],{jE(t,e,r){var o=r("Gt"),a=class{constructor(t){this.init=t,this.records=this.init()}static{(0,o.K)(this,"ImperativeState")}reset(){this.records=this.init()}};r.d(e,{m:()=>a})},P0(t,e,r){function o(t,e){t.accDescr&&e.setAccDescription?.(t.accDescr),t.accTitle&&e.setAccTitle?.(t.accTitle),t.title&&e.setDiagramTitle?.(t.title)}(0,r("Gt").K)(o,"populateCommonDb"),r.d(e,{S:()=>o})},Xd(t,e,r){var o=r("jE"),a=r("P0"),i=r("NH"),n=r("Yr"),s=r("M4"),c=r("Gt"),d=r("Xe"),l=r("El"),h={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},$=n.UI.gitGraph,m=(0,c.K)(()=>(0,i.$t)({...$,...(0,n.zj)().gitGraph}),"getConfig"),g=new o.m(()=>{let t=m(),e=t.mainBranchName,r=t.mainBranchOrder;return{mainBranchName:e,commits:new Map,head:null,branchConfig:new Map([[e,{name:e,order:r}]]),branches:new Map([[e,null]]),currBranch:e,direction:"LR",seq:0,options:{}}});function p(){return(0,i.yT)({length:7})}function y(t,e){let r=Object.create(null);return t.reduce((t,o)=>{let a=e(o);return r[a]||(r[a]=!0,t.push(o)),t},[])}(0,c.K)(p,"getID"),(0,c.K)(y,"uniqBy");var f=(0,c.K)(function(t){g.records.direction=t},"setDirection"),x=(0,c.K)(function(t){s.R.debug("options str",t),t=(t=t?.trim())||"{}";try{g.records.options=JSON.parse(t)}catch(t){s.R.error("error while parsing gitGraph options",t.message)}},"setOptions"),u=(0,c.K)(function(){return g.records.options},"getOptions"),b=(0,c.K)(function(t){let e=t.msg,r=t.id,o=t.type,a=t.tags;s.R.info("commit",e,r,o,a),s.R.debug("Entering commit:",e,r,o,a);let i=m();r=n.Y2.sanitizeText(r,i),e=n.Y2.sanitizeText(e,i),a=a?.map(t=>n.Y2.sanitizeText(t,i));let c={id:r||g.records.seq+"-"+p(),message:e,seq:g.records.seq++,type:o??h.NORMAL,tags:a??[],parents:null==g.records.head?[]:[g.records.head.id],branch:g.records.currBranch};g.records.head=c,s.R.info("main branch",i.mainBranchName),g.records.commits.has(c.id)&&s.R.warn(`Commit ID ${c.id} already exists`),g.records.commits.set(c.id,c),g.records.branches.set(g.records.currBranch,c.id),s.R.debug("in pushCommit "+c.id)},"commit"),k=(0,c.K)(function(t){let e=t.name,r=t.order;if(e=n.Y2.sanitizeText(e,m()),g.records.branches.has(e))throw Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${e}")`);g.records.branches.set(e,null!=g.records.head?g.records.head.id:null),g.records.branchConfig.set(e,{name:e,order:r}),E(e),s.R.debug("in createBranch")},"branch"),B=(0,c.K)(t=>{let e=t.branch,r=t.id,o=t.type,a=t.tags,i=m();e=n.Y2.sanitizeText(e,i),r&&(r=n.Y2.sanitizeText(r,i));let c=g.records.branches.get(g.records.currBranch),d=g.records.branches.get(e),l=c?g.records.commits.get(c):void 0,$=d?g.records.commits.get(d):void 0;if(l&&$&&l.branch===e)throw Error(`Cannot merge branch '${e}' into itself.`);if(g.records.currBranch===e){let t=Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},t}if(void 0===l||!l){let t=Error(`Incorrect usage of "merge". Current branch (${g.records.currBranch})has no commits`);throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["commit"]},t}if(!g.records.branches.has(e)){let t=Error('Incorrect usage of "merge". Branch to be merged ('+e+") does not exist");throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:[`branch ${e}`]},t}if(void 0===$||!$){let t=Error('Incorrect usage of "merge". Branch to be merged ('+e+") has no commits");throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:['"commit"']},t}if(l===$){let t=Error('Incorrect usage of "merge". Both branches have same head');throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},t}if(r&&g.records.commits.has(r)){let t=Error('Incorrect usage of "merge". Commit with id:'+r+" already exists, use different custom id");throw t.hash={text:`merge ${e} ${r} ${o} ${a?.join(" ")}`,token:`merge ${e} ${r} ${o} ${a?.join(" ")}`,expected:[`merge ${e} ${r}_UNIQUE ${o} ${a?.join(" ")}`]},t}let y={id:r||`${g.records.seq}-${p()}`,message:`merged branch ${e} into ${g.records.currBranch}`,seq:g.records.seq++,parents:null==g.records.head?[]:[g.records.head.id,d||""],branch:g.records.currBranch,type:h.MERGE,customType:o,customId:!!r,tags:a??[]};g.records.head=y,g.records.commits.set(y.id,y),g.records.branches.set(g.records.currBranch,y.id),s.R.debug(g.records.branches),s.R.debug("in mergeBranch")},"merge"),w=(0,c.K)(function(t){let e=t.id,r=t.targetId,o=t.tags,a=t.parent;s.R.debug("Entering cherryPick:",e,r,o);let i=m();if(e=n.Y2.sanitizeText(e,i),r=n.Y2.sanitizeText(r,i),o=o?.map(t=>n.Y2.sanitizeText(t,i)),a=n.Y2.sanitizeText(a,i),!e||!g.records.commits.has(e)){let t=Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw t.hash={text:`cherryPick ${e} ${r}`,token:`cherryPick ${e} ${r}`,expected:["cherry-pick abc"]},t}let c=g.records.commits.get(e);if(void 0===c||!c)throw Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(a&&!(Array.isArray(c.parents)&&c.parents.includes(a)))throw Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");let d=c.branch;if(c.type===h.MERGE&&!a)throw Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!r||!g.records.commits.has(r)){if(d===g.records.currBranch){let t=Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw t.hash={text:`cherryPick ${e} ${r}`,token:`cherryPick ${e} ${r}`,expected:["cherry-pick abc"]},t}let t=g.records.branches.get(g.records.currBranch);if(void 0===t||!t){let t=Error(`Incorrect usage of "cherry-pick". Current branch (${g.records.currBranch})has no commits`);throw t.hash={text:`cherryPick ${e} ${r}`,token:`cherryPick ${e} ${r}`,expected:["cherry-pick abc"]},t}let i=g.records.commits.get(t);if(void 0===i||!i){let t=Error(`Incorrect usage of "cherry-pick". Current branch (${g.records.currBranch})has no commits`);throw t.hash={text:`cherryPick ${e} ${r}`,token:`cherryPick ${e} ${r}`,expected:["cherry-pick abc"]},t}let n={id:g.records.seq+"-"+p(),message:`cherry-picked ${c?.message} into ${g.records.currBranch}`,seq:g.records.seq++,parents:null==g.records.head?[]:[g.records.head.id,c.id],branch:g.records.currBranch,type:h.CHERRY_PICK,tags:o?o.filter(Boolean):[`cherry-pick:${c.id}${c.type===h.MERGE?`|parent:${a}`:""}`]};g.records.head=n,g.records.commits.set(n.id,n),g.records.branches.set(g.records.currBranch,n.id),s.R.debug(g.records.branches),s.R.debug("in cherryPick")}},"cherryPick"),E=(0,c.K)(function(t){if(t=n.Y2.sanitizeText(t,m()),g.records.branches.has(t)){g.records.currBranch=t;let e=g.records.branches.get(g.records.currBranch);void 0!==e&&e?g.records.head=g.records.commits.get(e)??null:g.records.head=null}else{let e=Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${t}")`);throw e.hash={text:`checkout ${t}`,token:`checkout ${t}`,expected:[`branch ${t}`]},e}},"checkout");function T(t,e,r){let o=t.indexOf(e);-1===o?t.push(r):t.splice(o,1,r)}function C(t){let e=t.reduce((t,e)=>t.seq>e.seq?t:e,t[0]),r="";t.forEach(function(t){t===e?r+=" *":r+=" |"});let o=[r,e.id,e.seq];for(let t in g.records.branches)g.records.branches.get(t)===e.id&&o.push(t);if(s.R.debug(o.join(" ")),e.parents&&2==e.parents.length&&e.parents[0]&&e.parents[1]){let r=g.records.commits.get(e.parents[0]);T(t,e,r),e.parents[1]&&t.push(g.records.commits.get(e.parents[1]))}else if(0==e.parents.length)return;else if(e.parents[0]){let r=g.records.commits.get(e.parents[0]);T(t,e,r)}C(t=y(t,t=>t.id))}(0,c.K)(T,"upsert"),(0,c.K)(C,"prettyPrintCommitHistory");var L=(0,c.K)(function(){s.R.debug(g.records.commits),C([I()[0]])},"prettyPrint"),K=(0,c.K)(function(){g.reset(),(0,n.IU)()},"clear"),M=(0,c.K)(function(){return[...g.records.branchConfig.values()].map((t,e)=>null!==t.order&&void 0!==t.order?t:{...t,order:parseFloat(`0.${e}`)}).sort((t,e)=>(t.order??0)-(e.order??0)).map(({name:t})=>({name:t}))},"getBranchesAsObjArray"),R=(0,c.K)(function(){return g.records.branches},"getBranches"),v=(0,c.K)(function(){return g.records.commits},"getCommits"),I=(0,c.K)(function(){let t=[...g.records.commits.values()];return t.forEach(function(t){s.R.debug(t.id)}),t.sort((t,e)=>t.seq-e.seq),t},"getCommitsArray"),P={commitType:h,getConfig:m,setDirection:f,setOptions:x,getOptions:u,commit:b,branch:k,merge:B,cherryPick:w,checkout:E,prettyPrint:L,clear:K,getBranchesAsObjArray:M,getBranches:R,getCommits:v,getCommitsArray:I,getCurrentBranch:(0,c.K)(function(){return g.records.currBranch},"getCurrentBranch"),getDirection:(0,c.K)(function(){return g.records.direction},"getDirection"),getHead:(0,c.K)(function(){return g.records.head},"getHead"),setAccTitle:n.SV,getAccTitle:n.iN,getAccDescription:n.m7,setAccDescription:n.EI,setDiagramTitle:n.ke,getDiagramTitle:n.ab},O=(0,c.K)((t,e)=>{for(let r of((0,a.S)(t,e),t.dir&&e.setDirection(t.dir),t.statements))G(r,e)},"populate"),G=(0,c.K)((t,e)=>{let r={Commit:(0,c.K)(t=>e.commit(A(t)),"Commit"),Branch:(0,c.K)(t=>e.branch(S(t)),"Branch"),Merge:(0,c.K)(t=>e.merge(H(t)),"Merge"),Checkout:(0,c.K)(t=>e.checkout(D(t)),"Checkout"),CherryPicking:(0,c.K)(t=>e.cherryPick(W(t)),"CherryPicking")}[t.$type];r?r(t):s.R.error(`Unknown statement type: ${t.$type}`)},"parseStatement"),A=(0,c.K)(t=>({id:t.id,msg:t.message??"",type:void 0!==t.type?h[t.type]:h.NORMAL,tags:t.tags??void 0}),"parseCommit"),S=(0,c.K)(t=>({name:t.name,order:t.order??0}),"parseBranch"),H=(0,c.K)(t=>({branch:t.branch,id:t.id??"",type:void 0!==t.type?h[t.type]:void 0,tags:t.tags??void 0}),"parseMerge"),D=(0,c.K)(t=>t.branch,"parseCheckout"),W=(0,c.K)(t=>({id:t.id,targetId:"",tags:t.tags?.length===0?void 0:t.tags,parent:t.parent}),"parseCherryPicking"),q={parse:(0,c.K)(async t=>{let e=await (0,d.qg)("gitGraph",t);s.R.debug(e),O(e,P)},"parse")},z=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),_=new Set(["redux-color","redux-dark-color"]),Y=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),j=(0,c.K)((t,e,r=!1)=>r&&t>0?(t-1)%(e-1)+1:t%e,"calcColorIndex"),N=new Map,F=new Map,U=new Map,V=[],X=0,J="LR",Q=(0,c.K)(()=>{N.clear(),F.clear(),U.clear(),X=0,V=[],J="LR"},"clear"),Z=(0,c.K)(t=>{let e=document.createElementNS("http://www.w3.org/2000/svg","text");return("string"==typeof t?t.split(/\\n|\n|<br\s*\/?>/gi):t).forEach(t=>{let r=document.createElementNS("http://www.w3.org/2000/svg","tspan");r.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.setAttribute("dy","1em"),r.setAttribute("x","0"),r.setAttribute("class","row"),r.textContent=t.trim(),e.appendChild(r)}),e},"drawText"),tt=(0,c.K)(t=>{let e,r,o;return"BT"===J?(r=(0,c.K)((t,e)=>t<=e,"comparisonFunc"),o=1/0):(r=(0,c.K)((t,e)=>t>=e,"comparisonFunc"),o=0),t.forEach(t=>{let a="TB"===J||"BT"==J?F.get(t)?.y:F.get(t)?.x;void 0!==a&&r(a,o)&&(e=t,o=a)}),e},"findClosestParent"),te=(0,c.K)(t=>{let e="",r=1/0;return t.forEach(t=>{let o=F.get(t).y;o<=r&&(e=t,r=o)}),e||void 0},"findClosestParentBT"),tr=(0,c.K)((t,e,r)=>{let o=r,a=r,i=[];t.forEach(t=>{let r=e.get(t);if(!r)throw Error(`Commit not found for key ${t}`);r.parents.length?a=Math.max(o=ta(r),a):i.push(r),ti(r,o)}),o=a,i.forEach(t=>{tn(t,o,r)}),t.forEach(t=>{let r=e.get(t);if(r?.parents.length){let t=te(r.parents);(o=F.get(t).y-40)<=a&&(a=o);let e=N.get(r.branch).pos,i=o-10;F.set(r.id,{x:e,y:i})}})},"setParallelBTPos"),to=(0,c.K)(t=>{let e=tt(t.parents.filter(t=>null!==t));if(!e)throw Error(`Closest parent not found for commit ${t.id}`);let r=F.get(e)?.y;if(void 0===r)throw Error(`Closest parent position not found for commit ${t.id}`);return r},"findClosestParentPos"),ta=(0,c.K)(t=>to(t)+40,"calculateCommitPosition"),ti=(0,c.K)((t,e)=>{let r=N.get(t.branch);if(!r)throw Error(`Branch not found for commit ${t.id}`);let o=r.pos,a=e+10;return F.set(t.id,{x:o,y:a}),{x:o,y:a}},"setCommitPosition"),tn=(0,c.K)((t,e,r)=>{let o=N.get(t.branch);if(!o)throw Error(`Branch not found for commit ${t.id}`);let a=o.pos;F.set(t.id,{x:a,y:e+r})},"setRootPosition"),ts=(0,c.K)((t,e,r,o,a,i)=>{let{theme:s}=(0,n.D7)(),c=z.has(s??""),d=_.has(s??""),l=Y.has(s??"");if(i===h.HIGHLIGHT)t.append("rect").attr("x",r.x-10+3*!!c).attr("y",r.y-10+3*!!c).attr("width",c?14:20).attr("height",c?14:20).attr("class",`commit ${e.id} commit-highlight${j(a,8,d)} ${o}-outer`),t.append("rect").attr("x",r.x-6+2*!!c).attr("y",r.y-6+2*!!c).attr("width",c?8:12).attr("height",c?8:12).attr("class",`commit ${e.id} commit${j(a,8,d)} ${o}-inner`);else if(i===h.CHERRY_PICK)t.append("circle").attr("cx",r.x).attr("cy",r.y).attr("r",c?7:10).attr("class",`commit ${e.id} ${o}`),t.append("circle").attr("cx",r.x-3).attr("cy",r.y+2).attr("r",c?2.5:2.75).attr("fill",l?"#000000":"#fff").attr("class",`commit ${e.id} ${o}`),t.append("circle").attr("cx",r.x+3).attr("cy",r.y+2).attr("r",c?2.5:2.75).attr("fill",l?"#000000":"#fff").attr("class",`commit ${e.id} ${o}`),t.append("line").attr("x1",r.x+3).attr("y1",r.y+1).attr("x2",r.x).attr("y2",r.y-5).attr("stroke",l?"#000000":"#fff").attr("class",`commit ${e.id} ${o}`),t.append("line").attr("x1",r.x-3).attr("y1",r.y+1).attr("x2",r.x).attr("y2",r.y-5).attr("stroke",l?"#000000":"#fff").attr("class",`commit ${e.id} ${o}`);else{let n=t.append("circle");if(n.attr("cx",r.x),n.attr("cy",r.y),n.attr("r",c?7:10),n.attr("class",`commit ${e.id} commit${j(a,8,d)}`),i===h.MERGE){let i=t.append("circle");i.attr("cx",r.x),i.attr("cy",r.y),i.attr("r",c?5:6),i.attr("class",`commit ${o} ${e.id} commit${j(a,8,d)}`)}if(i===h.REVERSE){let i=t.append("path"),n=c?4:5;i.attr("d",`M ${r.x-n},${r.y-n}L${r.x+n},${r.y+n}M${r.x-n},${r.y+n}L${r.x+n},${r.y-n}`).attr("class",`commit ${o} ${e.id} commit${j(a,8,d)}`)}}},"drawCommitBullet"),tc=(0,c.K)((t,e,r,o,a)=>{if(e.type!==h.CHERRY_PICK&&(e.customId&&e.type===h.MERGE||e.type!==h.MERGE)&&a.showCommitLabel){let i=t.append("g"),n=i.insert("rect").attr("class","commit-label-bkg"),s=i.append("text").attr("x",o).attr("y",r.y+25).attr("class","commit-label").text(e.id),c=s.node()?.getBBox();if(c&&(n.attr("x",r.posWithOffset-c.width/2-2).attr("y",r.y+13.5).attr("width",c.width+4).attr("height",c.height+4),"TB"===J||"BT"===J?(n.attr("x",r.x-(c.width+16+5)).attr("y",r.y-12),s.attr("x",r.x-(c.width+16)).attr("y",r.y+c.height-12)):s.attr("x",r.posWithOffset-c.width/2),a.rotateCommitLabel))if("TB"===J||"BT"===J)s.attr("transform","rotate(-45, "+r.x+", "+r.y+")"),n.attr("transform","rotate(-45, "+r.x+", "+r.y+")");else{let t=-7.5-(c.width+10)/25*9.5,e=10+c.width/25*8.5;i.attr("transform","translate("+t+", "+e+") rotate(-45, "+o+", "+r.y+")")}}},"drawCommitLabel"),td=(0,c.K)((t,e,r,o)=>{if(e.tags.length>0){let a=0,i=0,n=0,s=[];for(let o of e.tags.reverse()){let e=t.insert("polygon"),c=t.append("circle"),d=t.append("text").attr("y",r.y-16-a).attr("class","tag-label").text(o),l=d.node()?.getBBox();if(!l)throw Error("Tag bbox not found");i=Math.max(i,l.width),n=Math.max(n,l.height),d.attr("x",r.posWithOffset-l.width/2),s.push({tag:d,hole:c,rect:e,yOffset:a}),a+=20}for(let{tag:t,hole:e,rect:a,yOffset:c}of s){let s=n/2,d=r.y-19.2-c;if(a.attr("class","tag-label-bkg").attr("points",`
2
+ ${o-i/2-2},${d+2}
3
+ ${o-i/2-2},${d-2}
4
+ ${r.posWithOffset-i/2-4},${d-s-2}
5
+ ${r.posWithOffset+i/2+4},${d-s-2}
6
+ ${r.posWithOffset+i/2+4},${d+s+2}
7
+ ${r.posWithOffset-i/2-4},${d+s+2}`),e.attr("cy",d).attr("cx",o-i/2+2).attr("r",1.5).attr("class","tag-hole"),"TB"===J||"BT"===J){let n=o+c;a.attr("class","tag-label-bkg").attr("points",`
8
+ ${r.x},${n+2}
9
+ ${r.x},${n-2}
10
+ ${r.x+10},${n-s-2}
11
+ ${r.x+10+i+4},${n-s-2}
12
+ ${r.x+10+i+4},${n+s+2}
13
+ ${r.x+10},${n+s+2}`).attr("transform","translate(12,12) rotate(45, "+r.x+","+o+")"),e.attr("cx",r.x+2).attr("cy",n).attr("transform","translate(12,12) rotate(45, "+r.x+","+o+")"),t.attr("x",r.x+5).attr("y",n+3).attr("transform","translate(14,14) rotate(45, "+r.x+","+o+")")}}}},"drawCommitTags"),tl=(0,c.K)(t=>{switch(t.customType??t.type){case h.NORMAL:return"commit-normal";case h.REVERSE:return"commit-reverse";case h.HIGHLIGHT:return"commit-highlight";case h.MERGE:return"commit-merge";case h.CHERRY_PICK:return"commit-cherry-pick";default:return"commit-normal"}},"getCommitClassType"),th=(0,c.K)((t,e,r,o)=>{let a={x:0,y:0};if(t.parents.length>0){let r=tt(t.parents);if(r){let i=o.get(r)??a;return"TB"===e?i.y+40:"BT"===e?(o.get(t.id)??a).y-40:i.x+40}}else if("TB"===e)return 30;else if("BT"===e)return(o.get(t.id)??a).y-40;return 0},"calculatePosition"),t$=(0,c.K)((t,e,r)=>{let o="BT"===J&&r?e:e+10,a=N.get(t.branch)?.pos,i="TB"===J||"BT"===J?N.get(t.branch)?.pos:o;if(void 0===i||void 0===a)throw Error(`Position were undefined for commit ${t.id}`);let s=z.has((0,n.D7)().theme??"");return{x:i,y:"TB"===J||"BT"===J?o:a+(s?7:-2),posWithOffset:o}},"getCommitPosition"),tm=(0,c.K)((t,e,r,o)=>{let a=t.append("g").attr("class","commit-bullets"),i=t.append("g").attr("class","commit-labels"),n=30*("TB"===J||"BT"===J),s=[...e.keys()],d=o.parallelCommits??!1,l=s.sort((0,c.K)((t,r)=>{let o=e.get(t)?.seq,a=e.get(r)?.seq;return void 0!==o&&void 0!==a?o-a:0},"sortKeys"));"BT"===J&&(d&&tr(l,e,n),l=l.reverse()),l.forEach(t=>{let s=e.get(t);if(!s)throw Error(`Commit not found for key ${t}`);d&&(n=th(s,J,n,F));let c=t$(s,n,d);if(r){let t=tl(s),e=s.customType??s.type,r=N.get(s.branch)?.index??0;ts(a,s,c,t,r,e),tc(i,s,c,n,o),td(i,s,c,n)}"TB"===J||"BT"===J?F.set(s.id,{x:c.x,y:c.posWithOffset}):F.set(s.id,{x:c.posWithOffset,y:c.y}),(n="BT"===J&&d?n+40:n+40+10)>X&&(X=n)})},"drawCommits"),tg=(0,c.K)((t,e,r,o,a)=>{let i=("TB"===J||"BT"===J?r.x<o.x:r.y<o.y)?e.branch:t.branch,n=(0,c.K)(t=>t.branch===i,"isOnBranchToGetCurve"),s=(0,c.K)(r=>r.seq>t.seq&&r.seq<e.seq,"isBetweenCommits");return[...a.values()].some(t=>s(t)&&n(t))},"shouldRerouteArrow"),tp=(0,c.K)((t,e,r=0)=>{let o=t+Math.abs(t-e)/2;if(r>5)return o;if(V.every(t=>Math.abs(t-o)>=10))return V.push(o),o;let a=Math.abs(t-e);return tp(t,e-a/5,r+1)},"findLane"),ty=(0,c.K)((t,e,r,o)=>{let a,{theme:i}=(0,n.D7)(),s=_.has(i??""),c=F.get(e.id),d=F.get(r.id);if(void 0===c||void 0===d)throw Error(`Commit positions not found for commits ${e.id} and ${r.id}`);let l=tg(e,r,c,d,o),$="",m="",g=0,p=0,y=N.get(r.branch)?.index;if(r.type===h.MERGE&&e.id!==r.parents[0]&&(y=N.get(e.branch)?.index),l){$="A 10 10, 0, 0, 0,",m="A 10 10, 0, 0, 1,",g=10,p=10;let t=c.y<d.y?tp(c.y,d.y):tp(d.y,c.y),r=c.x<d.x?tp(c.x,d.x):tp(d.x,c.x);"TB"===J?c.x<d.x?a=`M ${c.x} ${c.y} L ${r-g} ${c.y} ${m} ${r} ${c.y+p} L ${r} ${d.y-g} ${$} ${r+p} ${d.y} L ${d.x} ${d.y}`:(y=N.get(e.branch)?.index,a=`M ${c.x} ${c.y} L ${r+g} ${c.y} ${$} ${r} ${c.y+p} L ${r} ${d.y-g} ${m} ${r-p} ${d.y} L ${d.x} ${d.y}`):"BT"===J?c.x<d.x?a=`M ${c.x} ${c.y} L ${r-g} ${c.y} ${$} ${r} ${c.y-p} L ${r} ${d.y+g} ${m} ${r+p} ${d.y} L ${d.x} ${d.y}`:(y=N.get(e.branch)?.index,a=`M ${c.x} ${c.y} L ${r+g} ${c.y} ${m} ${r} ${c.y-p} L ${r} ${d.y+g} ${$} ${r-p} ${d.y} L ${d.x} ${d.y}`):c.y<d.y?a=`M ${c.x} ${c.y} L ${c.x} ${t-g} ${$} ${c.x+p} ${t} L ${d.x-g} ${t} ${m} ${d.x} ${t+p} L ${d.x} ${d.y}`:(y=N.get(e.branch)?.index,a=`M ${c.x} ${c.y} L ${c.x} ${t+g} ${m} ${c.x+p} ${t} L ${d.x-g} ${t} ${$} ${d.x} ${t-p} L ${d.x} ${d.y}`)}else $="A 20 20, 0, 0, 0,",m="A 20 20, 0, 0, 1,",g=20,p=20,"TB"===J?(c.x<d.x&&(a=r.type===h.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${c.x} ${d.y-g} ${$} ${c.x+p} ${d.y} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${d.x-g} ${c.y} ${m} ${d.x} ${c.y+p} L ${d.x} ${d.y}`),c.x>d.x&&($="A 20 20, 0, 0, 0,",m="A 20 20, 0, 0, 1,",g=20,p=20,a=r.type===h.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${c.x} ${d.y-g} ${m} ${c.x-p} ${d.y} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${d.x+g} ${c.y} ${$} ${d.x} ${c.y+p} L ${d.x} ${d.y}`),c.x===d.x&&(a=`M ${c.x} ${c.y} L ${d.x} ${d.y}`)):"BT"===J?(c.x<d.x&&(a=r.type===h.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${c.x} ${d.y+g} ${m} ${c.x+p} ${d.y} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${d.x-g} ${c.y} ${$} ${d.x} ${c.y-p} L ${d.x} ${d.y}`),c.x>d.x&&($="A 20 20, 0, 0, 0,",m="A 20 20, 0, 0, 1,",g=20,p=20,a=r.type===h.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${c.x} ${d.y+g} ${$} ${c.x-p} ${d.y} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${d.x+g} ${c.y} ${m} ${d.x} ${c.y-p} L ${d.x} ${d.y}`),c.x===d.x&&(a=`M ${c.x} ${c.y} L ${d.x} ${d.y}`)):(c.y<d.y&&(a=r.type===h.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${d.x-g} ${c.y} ${m} ${d.x} ${c.y+p} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${c.x} ${d.y-g} ${$} ${c.x+p} ${d.y} L ${d.x} ${d.y}`),c.y>d.y&&(a=r.type===h.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${d.x-g} ${c.y} ${$} ${d.x} ${c.y-p} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${c.x} ${d.y+g} ${m} ${c.x+p} ${d.y} L ${d.x} ${d.y}`),c.y===d.y&&(a=`M ${c.x} ${c.y} L ${d.x} ${d.y}`));if(void 0===a)throw Error("Line definition not found");t.append("path").attr("d",a).attr("class","arrow arrow"+j(y,8,s))},"drawArrow"),tf=(0,c.K)((t,e)=>{let r=t.append("g").attr("class","commit-arrows");[...e.keys()].forEach(t=>{let o=e.get(t);o.parents&&o.parents.length>0&&o.parents.forEach(t=>{ty(r,e.get(t),o,e)})})},"drawArrows"),tx=(0,c.K)((t,e,r,o)=>{let{look:a,theme:i,themeVariables:s}=(0,n.D7)(),{dropShadow:c,THEME_COLOR_LIMIT:d}=s,l=z.has(i??""),h=_.has(i??""),$=t.append("g");e.forEach((t,e)=>{let i=j(e,l?d:8,h),n=N.get(t.name)?.pos;if(void 0===n)throw Error(`Position not found for branch ${t.name}`);let s="TB"===J||"BT"===J?n:l?n+6+1:n-2,m=$.append("line");m.attr("x1",0),m.attr("y1",s),m.attr("x2",X),m.attr("y2",s),m.attr("class","branch branch"+i),"TB"===J?(m.attr("y1",30),m.attr("x1",n),m.attr("y2",X),m.attr("x2",n)):"BT"===J&&(m.attr("y1",X),m.attr("x1",n),m.attr("y2",30),m.attr("x2",n)),V.push(s);let g=Z(t.name),p=$.insert("rect"),y=$.insert("g").attr("class","branchLabel").insert("g").attr("class","label branch-label"+i);y.node().appendChild(g);let f=g.getBBox(),x=4*!l,u=16*!!l,b=12*!!l;"neo"===a&&p.attr("data-look","neo"),p.attr("class","branchLabelBkg label"+i).attr("style","neo"===a?`filter:${l?`url(#${o}-drop-shadow)`:c}`:"").attr("rx",x).attr("ry",x).attr("x",-f.width-4-30*(!0===r.rotateCommitLabel)).attr("y",-f.height/2+10).attr("width",f.width+18+u).attr("height",f.height+4+b),y.attr("transform","translate("+(-f.width-14-30*(!0===r.rotateCommitLabel)+u/2)+", "+(s-f.height/2-2)+")"),"TB"===J?(p.attr("x",n-f.width/2-10).attr("y",0),y.attr("transform","translate("+(n-f.width/2-5)+", 0)"),l&&(p.attr("transform",`translate(${-u/2-3}, ${-b-10})`),y.attr("transform","translate("+(n-f.width/2-5)+", "+(-(2*b)+7)+")"))):"BT"===J?(p.attr("x",n-f.width/2-10).attr("y",X),y.attr("transform","translate("+(n-f.width/2-5)+", "+X+")"),l&&(p.attr("transform",`translate(${-u/2-3}, ${b+10})`),y.attr("transform","translate("+(n-f.width/2-5)+", "+(X+2*b+4)+")"))):p.attr("transform","translate(-19, "+(s-12-b/2)+")")})},"drawBranches"),tu=(0,c.K)(function(t,e,r,o,a){return N.set(t,{pos:e,index:r}),e+=50+40*!!a+("TB"===J||"BT"===J?o.width/2:0)},"setBranchPosition"),tb=(0,c.K)(function(t,e,r,o){Q(),s.R.debug("in gitgraph renderer",t+"\n","id:",e,r);let a=o.db;if(!a.getConfig)return void s.R.error("getConfig method is not available on db");let c=a.getConfig(),d=c.rotateCommitLabel??!1;U=a.getCommits();let h=a.getBranchesAsObjArray();J=a.getDirection();let $=(0,l.Ltv)(`[id="${e}"]`),{look:m,theme:g,themeVariables:p}=(0,n.D7)(),{useGradient:y,gradientStart:f,gradientStop:x,filterColor:u}=p;if(y){let t=$.append("defs").append("linearGradient").attr("id",e+"-gradient").attr("gradientUnits","objectBoundingBox").attr("x1","0%").attr("y1","0%").attr("x2","100%").attr("y2","0%");t.append("stop").attr("offset","0%").attr("stop-color",f).attr("stop-opacity",1),t.append("stop").attr("offset","100%").attr("stop-color",x).attr("stop-opacity",1)}"neo"===m&&z.has(g??"")&&$.append("defs").append("filter").attr("id",e+"-drop-shadow").attr("height","130%").attr("width","130%").append("feDropShadow").attr("dx","4").attr("dy","4").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",u);let b=0;h.forEach((t,e)=>{let r=Z(t.name),o=$.append("g"),a=o.insert("g").attr("class","branchLabel"),i=a.insert("g").attr("class","label branch-label");i.node()?.appendChild(r);let n=r.getBBox();b=tu(t.name,b,e,n,d),i.remove(),a.remove(),o.remove()}),tm($,U,!1,c),c.showBranches&&tx($,h,c,e),tf($,U),tm($,U,!0,c),i._K.insertTitle($,"gitTitleText",c.titleTopMargin??0,a.getDiagramTitle()),(0,n.mj)(void 0,$,c.diagramPadding,c.useMaxWidth)},"draw"),tk=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),tB=new Set(["redux-color","redux-dark-color"]),tw=new Set(["neo","neo-dark"]),tE=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),tT=new Set(["redux","redux-dark","redux-color","redux-dark-color","neo","neo-dark"]),tC=(0,c.K)(t=>{let{svgId:e}=t,r="";if(t.useGradient&&e)for(let o=0;o<t.THEME_COLOR_LIMIT;o++)r+=`
14
+ .label${o} { fill: ${t.mainBkg}; stroke: url(${e}-gradient); stroke-width: ${t.strokeWidth};}
15
+ `;return r},"genGitGraphGradient"),tL=(0,c.K)(t=>{let{theme:e,themeVariables:r}=(0,n.zj)(),{borderColorArray:o}=r,a=tk.has(e);if(tw.has(e)){let e="";for(let r=0;r<t.THEME_COLOR_LIMIT;r++)if(0===r)e+=`
16
+ .branch-label${r} { fill: ${t.nodeBorder};}
17
+ .commit${r} { stroke: ${t.nodeBorder}; }
18
+ .commit-highlight${r} { stroke: ${t.nodeBorder}; fill: ${t.nodeBorder}; }
19
+ .arrow${r} { stroke: ${t.nodeBorder}; }
20
+ .commit-bullets { fill: ${t.nodeBorder}; }
21
+ .commit-cherry-pick${r} { stroke: ${t.nodeBorder}; }
22
+ ${tC(t)}`;else{let o=r%8;e+=`
23
+ .branch-label${r} { fill: ${t["gitBranchLabel"+o]}; }
24
+ .commit${r} { stroke: ${t["git"+o]}; fill: ${t["git"+o]}; }
25
+ .commit-highlight${r} { stroke: ${t["gitInv"+o]}; fill: ${t["gitInv"+o]}; }
26
+ .arrow${r} { stroke: ${t["git"+o]}; }
27
+ `}return e}if(tB.has(e)){let r="";for(let i=0;i<t.THEME_COLOR_LIMIT;i++)if(0===i)r+=`
28
+ .branch-label${i} { fill: ${t.nodeBorder}; ${a?`font-weight:${t.noteFontWeight}`:""} }
29
+ .commit${i} { stroke: ${t.nodeBorder}; }
30
+ .commit-highlight${i} { stroke: ${t.nodeBorder}; fill: ${t.mainBkg}; }
31
+ .label${i} { fill: ${t.mainBkg}; stroke: ${t.nodeBorder}; stroke-width: ${t.strokeWidth}; ${a?`font-weight:${t.noteFontWeight}`:""} }
32
+ .arrow${i} { stroke: ${t.nodeBorder}; }
33
+ .commit-bullets { fill: ${t.nodeBorder}; }
34
+ `;else{let n=i%o.length;r+=`
35
+ .branch-label${i} { fill: ${t.nodeBorder}; ${a?`font-weight:${t.noteFontWeight}`:""} }
36
+ .commit${i} { stroke: ${o[n]}; fill: ${o[n]}; }
37
+ .commit-highlight${i} { stroke: ${o[n]}; fill: ${o[n]}; }
38
+ .label${i} { fill: ${tE.has(e)?t.mainBkg:o[n]}; stroke: ${o[n]}; stroke-width: ${t.strokeWidth}; }
39
+ .arrow${i} { stroke: ${o[n]}; }
40
+ `}return r}{let e="";for(let r=0;r<t.THEME_COLOR_LIMIT;r++)e+=`
41
+ .branch-label${r} { fill: ${t.nodeBorder}; ${a?`font-weight:${t.noteFontWeight}`:""} }
42
+ .commit${r} { stroke: ${t.nodeBorder}; }
43
+ .commit-highlight${r} { stroke: ${t.nodeBorder}; fill: ${t.nodeBorder}; }
44
+ .label${r} { fill: ${t.mainBkg}; stroke: ${t.nodeBorder}; stroke-width: ${t.strokeWidth}; ${a?`font-weight:${t.noteFontWeight}`:""}}
45
+ .arrow${r} { stroke: ${t.nodeBorder}; }
46
+ .commit-bullets { fill: ${t.nodeBorder}; }
47
+ .commit-cherry-pick${r} { stroke: ${t.nodeBorder}; }
48
+ `;return e}},"genColor"),tK=(0,c.K)(t=>`${Array.from({length:t.THEME_COLOR_LIMIT},(t,e)=>e).map(e=>{let r=e%8;return`
49
+ .branch-label${e} { fill: ${t["gitBranchLabel"+r]}; }
50
+ .commit${e} { stroke: ${t["git"+r]}; fill: ${t["git"+r]}; }
51
+ .commit-highlight${e} { stroke: ${t["gitInv"+r]}; fill: ${t["gitInv"+r]}; }
52
+ .label${e} { fill: ${t["git"+r]}; }
53
+ .arrow${e} { stroke: ${t["git"+r]}; }
54
+ `}).join("\n")}`,"normalTheme"),tM={parser:q,db:P,renderer:{draw:tb},styles:(0,c.K)(t=>{let{theme:e}=(0,n.zj)(),r=tT.has(e);return`
55
+ .commit-id,
56
+ .commit-msg,
57
+ .branch-label {
58
+ fill: lightgrey;
59
+ color: lightgrey;
60
+ font-family: 'trebuchet ms', verdana, arial, sans-serif;
61
+ font-family: var(--mermaid-font-family);
62
+ }
63
+
64
+ ${r?tL(t):tK(t)}
65
+
66
+ .branch {
67
+ stroke-width: ${t.strokeWidth};
68
+ stroke: ${t.commitLineColor??t.lineColor};
69
+ stroke-dasharray: ${r?"4 2":"2"};
70
+ }
71
+ .commit-label { font-size: ${t.commitLabelFontSize}; fill: ${r?t.nodeBorder:t.commitLabelColor}; ${r?`font-weight:${t.noteFontWeight};`:""}}
72
+ .commit-label-bkg { font-size: ${t.commitLabelFontSize}; fill: ${r?"transparent":t.commitLabelBackground}; opacity: ${r?"":.5}; }
73
+ .tag-label { font-size: ${t.tagLabelFontSize}; fill: ${t.tagLabelColor};}
74
+ .tag-label-bkg { fill: ${r?t.mainBkg:t.tagLabelBackground}; stroke: ${r?t.nodeBorder:t.tagLabelBorder}; ${r?`filter:${t.dropShadow}`:""} }
75
+ .tag-hole { fill: ${t.textColor}; }
76
+
77
+ .commit-merge {
78
+ stroke: ${r?t.mainBkg:t.primaryColor};
79
+ fill: ${r?t.mainBkg:t.primaryColor};
80
+ }
81
+ .commit-reverse {
82
+ stroke: ${r?t.mainBkg:t.primaryColor};
83
+ fill: ${r?t.mainBkg:t.primaryColor};
84
+ stroke-width: ${r?t.strokeWidth:3};
85
+ }
86
+ .commit-highlight-outer {
87
+ }
88
+ .commit-highlight-inner {
89
+ stroke: ${r?t.mainBkg:t.primaryColor};
90
+ fill: ${r?t.mainBkg:t.primaryColor};
91
+ }
92
+
93
+ .arrow {
94
+ /* Intentional: neo themes keep the bold 8px arrow (like classic themes); only redux-geometry themes use the thinner options.strokeWidth. */
95
+ stroke-width: ${tk.has(e)?t.strokeWidth:8};
96
+ stroke-linecap: round;
97
+ fill: none
98
+ }
99
+ .gitTitleText {
100
+ text-anchor: middle;
101
+ font-size: 18px;
102
+ fill: ${t.textColor};
103
+ }
104
+ `},"getStyles")};r.d(e,{diagram:()=>tM})}}]);
@@ -0,0 +1,10 @@
1
+ /*! LICENSE: mw.ca1512563c.js.LICENSE.txt */
2
+ "use strict";(self.rspackChunkompchamber=self.rspackChunkompchamber||[]).push([["mw"],{Ml(e,t,n){n.d(t,{P:()=>f});var r=n("j"),i=n("H");let s=`
3
+ .code-editor-native-textarea {
4
+ -webkit-text-fill-color: transparent;
5
+ }
6
+ .code-editor-native-textarea::placeholder {
7
+ -webkit-text-fill-color: var(--theme-ink);
8
+ opacity: 0.45;
9
+ }
10
+ `;function l(){return(0,r.Y)("style",{dangerouslySetInnerHTML:{__html:s}})}function a(e,t){return e.substring(0,t).split("\n")}function o(e){let{value:t,onValueChange:n,highlight:s,padding:o=0,preClassName:c,textareaClassName:d,style:u,preRef:h,className:p,placeholder:f,readOnly:m,autoFocus:x}=e,g=(0,i.li)(null),b=(0,i.li)({stack:[],offset:-1}),[y,k]=(0,i.J0)(!0);(0,i.vJ)(()=>{let e=g.current;if(!e)return;let t={value:e.value,selectionStart:e.selectionStart,selectionEnd:e.selectionEnd,timestamp:Date.now()},{stack:n,offset:r}=b.current;n.length&&r>-1&&(b.current.stack=n.slice(0,r+1)),b.current.stack.push(t),b.current.offset=b.current.stack.length-1},[t]);let v=e=>{let t=g.current,r=b.current.stack[b.current.offset];if(r&&t&&(b.current.stack[b.current.offset]={...r,selectionStart:t.selectionStart,selectionEnd:t.selectionEnd}),b.current.stack.push({...e,timestamp:Date.now()}),b.current.offset=b.current.stack.length-1,b.current.stack.length>100){let e=b.current.stack.length-100;b.current.stack=b.current.stack.slice(e),b.current.offset=Math.max(b.current.offset-e,0)}n(e.value),t&&(t.value=e.value,t.selectionStart=e.selectionStart,t.selectionEnd=e.selectionEnd)},w={paddingTop:o,paddingRight:o,paddingBottom:o,paddingLeft:o},N=s(t),Y={margin:0,border:0,background:"none",boxSizing:"inherit",display:"inherit",fontFamily:"inherit",fontSize:"inherit",fontStyle:"inherit",fontVariantLigatures:"inherit",fontWeight:"inherit",letterSpacing:"inherit",lineHeight:"inherit",tabSize:"inherit",textIndent:"inherit",textRendering:"inherit",textTransform:"inherit",whiteSpace:"pre-wrap",wordBreak:"keep-all",overflowWrap:"break-word"};return(0,r.FD)("div",{className:p,style:{position:"relative",textAlign:"left",boxSizing:"border-box",padding:0,overflow:"hidden",...u},children:[(0,r.Y)("pre",{ref:h,className:c,"aria-hidden":"true",style:{...Y,...w,position:"relative",pointerEvents:"none"},dangerouslySetInnerHTML:{__html:N+"<br />"}}),(0,r.Y)("textarea",{ref:g,className:`code-editor-native-textarea${d?` ${d}`:""}`,style:{...Y,...w,position:"absolute",top:0,left:0,height:"100%",width:"100%",resize:"none",color:"inherit",overflow:"hidden",WebkitTextFillColor:"transparent"},value:t,onChange:e=>{let{value:t,selectionStart:r,selectionEnd:i}=e.target,{stack:s,offset:l}=b.current,o=Date.now();s.length&&l>-1&&(b.current.stack=s.slice(0,l+1));let c=b.current.stack[b.current.offset];if(c&&o-c.timestamp<3e3){let e=/[^a-z0-9]([a-z0-9]+)$/i,s=a(c.value,c.selectionStart).pop()?.match(e),l=a(t,r).pop()?.match(e);if(s?.[1]&&l?.[1]?.startsWith(s[1])){b.current.stack[b.current.offset]={value:t,selectionStart:r,selectionEnd:i,timestamp:o},n(t);return}}b.current.stack.push({value:t,selectionStart:r,selectionEnd:i,timestamp:o}),b.current.offset=b.current.stack.length-1,n(t)},onKeyDown:e=>{if("Escape"===e.key)return void e.currentTarget.blur();let{value:t,selectionStart:r,selectionEnd:i}=e.currentTarget,s=/(Mac|iPhone|iPod|iPad)/i.test(navigator.platform),l=/Win/i.test(navigator.platform);if("Tab"===e.key&&y){if(e.preventDefault(),e.shiftKey){let e=a(t,r),n=e.length-1,s=a(t,i).length-1,l=t.split("\n").map((e,t)=>t>=n&&t<=s&&e.startsWith(" ")?e.substring(2):e).join("\n");if(l!==t){let s=e[n];v({value:l,selectionStart:s?.startsWith(" ")?r-2:r,selectionEnd:i-(t.length-l.length)})}}else if(r!==i){let e=a(t,r),n=e.length-1,s=a(t,i).length-1,l=e[n];v({value:t.split("\n").map((e,t)=>t>=n&&t<=s?" "+e:e).join("\n"),selectionStart:l&&/\S/.test(l)?r+2:r,selectionEnd:i+2*(s-n+1)})}else{let e=r+2;v({value:t.substring(0,r)+" "+t.substring(i),selectionStart:e,selectionEnd:e})}return}if("Backspace"===e.key&&r===i){if(t.substring(0,r).endsWith(" ")){e.preventDefault();let n=r-2;v({value:t.substring(0,r-2)+t.substring(i),selectionStart:n,selectionEnd:n})}return}if("Enter"===e.key&&r===i){let n=a(t,r).pop(),s=n?.match(/^\s+/);if(s?.[0]){e.preventDefault();let n="\n"+s[0],l=r+n.length;v({value:t.substring(0,r)+n+t.substring(i),selectionStart:l,selectionEnd:l})}return}if((s?e.metaKey&&"z"===e.key.toLowerCase():e.ctrlKey&&"z"===e.key.toLowerCase())&&!e.shiftKey&&!e.altKey){e.preventDefault();let{stack:t,offset:r}=b.current,i=t[r-1];i&&g.current&&(g.current.value=i.value,g.current.selectionStart=i.selectionStart,g.current.selectionEnd=i.selectionEnd,n(i.value),b.current.offset=Math.max(r-1,0));return}if((s?e.metaKey&&e.shiftKey&&"z"===e.key.toLowerCase():l?e.ctrlKey&&"y"===e.key.toLowerCase():e.ctrlKey&&e.shiftKey&&"z"===e.key.toLowerCase())&&!e.altKey){e.preventDefault();let{stack:t,offset:r}=b.current,i=t[r+1];i&&g.current&&(g.current.value=i.value,g.current.selectionStart=i.selectionStart,g.current.selectionEnd=i.selectionEnd,n(i.value),b.current.offset=Math.min(r+1,t.length-1));return}e.ctrlKey&&"m"===e.key.toLowerCase()&&(!s||e.shiftKey)&&(e.preventDefault(),k(e=>!e))},placeholder:f,readOnly:m,autoFocus:x,autoCapitalize:"off",autoComplete:"off",autoCorrect:"off",spellcheck:!1,"data-gramm":!1}),(0,r.Y)(l,{})]})}let c=["direction","fontFamily","fontFeatureSettings","fontKerning","fontSize","fontStyle","fontVariantLigatures","fontWeight","letterSpacing","overflowWrap","tabSize","textRendering","textTransform","whiteSpace","wordBreak","wordSpacing"],d=null,u=[];var h=n("DU"),p=n("Po");function f(e){let{value:t,onValueChange:n,language:s,wordWrap:l,rootClassName:a,gutterClassName:f,gutterStyle:m,gutterLineClassName:x,editorWrapperClassName:g,editorClassName:b,editorPadding:y=0,editorStyle:k}=e,v=l?"!whitespace-pre-wrap !break-words":"!whitespace-pre !break-normal",w=(0,i.li)(null),[N,Y]=(0,i.J0)(null);(0,p.w)();let S=(0,i.hb)(()=>{let e=w.current,n=l&&e?function(e,t){if("u"<typeof document||!e.isConnected)return null;let n=getComputedStyle(e),r=Number.parseFloat(n.lineHeight);if(!Number.isFinite(r)||r<=0)return null;let i=e.clientWidth-Number.parseFloat(n.paddingLeft||"0")-Number.parseFloat(n.paddingRight||"0");if(i<=0)return null;let s=(d&&d.isConnected||((d=document.createElement("div")).setAttribute("aria-hidden","true"),d.style.cssText="position:fixed;top:0;left:-100000px;visibility:hidden;pointer-events:none;margin:0;border:0;padding:0;box-sizing:border-box;",document.body.appendChild(d),u=[]),d);for(let e of c)s.style[e]=n[e];s.style.lineHeight=`${r}px`,s.style.width=`${i}px`;let l=t.split("\n");for(;u.length>l.length;)u.pop()?.remove();for(;u.length<l.length;){let e=document.createElement("div");s.appendChild(e),u.push(e)}for(let e=0;e<l.length;e++)u[e].textContent=l[e];let a=u.map(e=>{let t=e.getBoundingClientRect().height;return t>r?Math.round(t/r)*r:r});return{rowHeight:r,heights:a}}(e,t):null;Y(e=>e===n||e&&n&&e.rowHeight===n.rowHeight&&e.heights.length===n.heights.length&&e.heights.every((e,t)=>e===n.heights[t])?e:n)},[t,l,y,k?.fontSize]);(0,i.Nf)(()=>{S()},[S]);let D=(0,i.li)(S);return D.current=S,(0,i.vJ)(()=>{let e=w.current;if(!e||"u"<typeof ResizeObserver)return;let t=new ResizeObserver(()=>D.current());return t.observe(e),()=>t.disconnect()},[]),(0,r.FD)("div",{className:a,children:[(0,r.Y)("div",{className:f,style:m,children:t.split("\n").map((e,t)=>(0,r.Y)("div",{className:x,style:N?{height:N.heights[t],flexShrink:0}:void 0,children:t+1},t+1))}),(0,r.Y)("div",{className:g,children:(0,r.Y)(o,{value:t,onValueChange:n,highlight:e=>(0,h.wY)(e,s),padding:y,preRef:w,textareaClassName:`focus:outline-none ${v}`,preClassName:v,style:k,className:b})})]})}},Xg(e,t,n){n.d(t,{M:()=>D});var r=n("j"),i=n("H"),s=n("X"),l=n("FL"),a=n("DU"),o=n("lP"),c=n("y");let d=(0,c.A)({name:"text-align-justify",size:24,node:[["path",{d:"M3 5h18",key:"1u36vt"}],["path",{d:"M3 12h18",key:"1i2n21"}],["path",{d:"M3 19h18",key:"awlh7x"}]],aliases:["align-justify"]}),u=(0,c.A)({name:"space",size:24,node:[["path",{d:"M22 17v1c0 .5-.5 1-1 1H3c-.5 0-1-.5-1-1v-1",key:"lt2kga"}]]});var h=n("n"),p=n("z"),f=n("b0"),m=n("I"),x=n("DV"),g=n("r"),b=n("AB"),y=n("ob"),k=n("LQ");function v(e){let{filePath:t,status:n,isStaged:i,viewMode:s,ignoreWhitespace:l,additions:a,deletions:c,isLoading:v,isCopied:w,onToggleViewMode:N,onToggleWhitespace:Y,onStageUnstage:S,onDiscard:D,onOpenInEditor:F,onRefresh:z,onCopyDiff:C}=e,T=t.split("/").pop()||t,L=(0,k.R)(n,i);return(0,r.FD)("div",{className:"flex items-center justify-between px-3 py-1.5 bg-paper border-b border-ink/10 text-xs font-sans select-none flex-shrink-0 overflow-x-auto no-scrollbar",children:[(0,r.FD)("div",{className:"hidden md:flex items-center space-x-2 min-w-0 pr-2",children:[(0,r.Y)(y.o,{name:T,size:14,className:"flex-shrink-0"}),(0,r.Y)("span",{className:"font-mono text-ink font-medium truncate",title:t,children:T}),(0,r.FD)("span",{className:`px-1.5 py-0.5 text-[10px] font-mono font-semibold rounded border ${L.badgeBgClass} flex-shrink-0`,children:[L.charStatus," ",L.label]}),(a>0||c>0)&&(0,r.FD)("div",{className:"flex items-center space-x-1.5 text-[11px] font-mono flex-shrink-0 ml-1",children:[a>0&&(0,r.FD)("span",{className:"text-success font-semibold",children:["+",a]}),c>0&&(0,r.FD)("span",{className:"text-error font-semibold",children:["-",c]})]})]}),(0,r.FD)("div",{className:"flex items-center space-x-1 text-ink/70 flex-shrink-0 ml-auto",children:[(0,r.FD)("div",{className:"flex items-center bg-canvas rounded border border-ink/15 p-0.5 mr-1",children:[(0,r.FD)("button",{type:"button",onClick:N,className:`px-2 py-0.5 rounded text-[11px] font-medium flex items-center space-x-1 transition-colors ${"split"===s?"bg-paper text-ink shadow-xs":"text-ink/60 hover:text-ink"}`,title:"Split (side-by-side) Diff",children:[(0,r.Y)(o.A,{size:12}),(0,r.Y)("span",{className:"hidden sm:inline",children:"Split"})]}),(0,r.FD)("button",{type:"button",onClick:N,className:`px-2 py-0.5 rounded text-[11px] font-medium flex items-center space-x-1 transition-colors ${"unified"===s?"bg-paper text-ink shadow-xs":"text-ink/60 hover:text-ink"}`,title:"Unified Diff",children:[(0,r.Y)(d,{size:12}),(0,r.Y)("span",{className:"hidden sm:inline",children:"Unified"})]})]}),(0,r.Y)("button",{type:"button",onClick:Y,className:`p-1.5 rounded transition-colors ${l?"bg-ink/10 text-ink":"text-ink/50 hover:text-ink hover:bg-ink/5"}`,title:l?"Whitespace ignored":"Ignore whitespace",children:(0,r.Y)(u,{size:13})}),(0,r.Y)("button",{type:"button",onClick:z,className:"p-1.5 text-ink/50 hover:text-ink hover:bg-ink/5 rounded transition-colors",title:"Refresh Diff",disabled:v,children:(0,r.Y)(h.A,{size:13,className:v?"animate-spin":""})}),(0,r.Y)("button",{type:"button",onClick:C,className:"p-1.5 text-ink/50 hover:text-ink hover:bg-ink/5 rounded transition-colors",title:"Copy Diff Text",children:w?(0,r.Y)(p.A,{size:13,className:"text-success"}):(0,r.Y)(f.A,{size:13})}),!i&&(0,r.Y)("button",{type:"button",onClick:D,className:"p-1.5 text-ink/50 hover:text-error hover:bg-error/10 rounded transition-colors",title:"Discard changes in this file",children:(0,r.Y)(m.A,{size:13})}),(0,r.Y)("button",{type:"button",onClick:S,className:"px-2 py-1 text-[11px] font-medium rounded border border-ink/15 hover:bg-ink/5 flex items-center space-x-1 transition-colors text-ink",title:i?"Unstage file":"Stage file",children:i?(0,r.FD)(r.FK,{children:[(0,r.Y)(x.A,{size:12}),(0,r.Y)("span",{children:"Unstage"})]}):(0,r.FD)(r.FK,{children:[(0,r.Y)(g.A,{size:12}),(0,r.Y)("span",{children:"Stage"})]})}),F&&(0,r.FD)("button",{type:"button",onClick:F,className:"px-2 py-1 text-[11px] font-medium rounded bg-ink text-canvas hover:bg-ink/90 flex items-center space-x-1 transition-colors shadow-xs ml-1",title:"Open in Code Editor",children:[(0,r.Y)(b.A,{size:12}),(0,r.Y)("span",{className:"hidden sm:inline",children:"Edit File"})]})]})]})}var w=n("Po");function N(e){let{lines:t,language:n}=e,s=(0,w.w)(),l=(0,i.Kr)(()=>{let e=Array(t.length).fill(""),r=-1,i=i=>{if(r<0)return;let s=(0,a.O9)(t.slice(r,i).map(e=>e.text).join("\n"),n);for(let t=r;t<i;t++)e[t]=s[t-r]??"";r=-1};return t.forEach((e,t)=>{"meta"===e.type?i(t):r<0&&(r=t)}),i(t.length),e},[t,n,s]);return 0===t.length?(0,r.Y)("div",{className:"flex-1 flex items-center justify-center text-ink/40 font-mono text-xs p-8",children:"No differences between working file and target."}):(0,r.Y)("div",{className:"w-full h-full overflow-auto font-mono text-xs select-text bg-paper text-ink code-surface",children:(0,r.Y)("table",{className:"w-max min-w-full border-collapse",children:(0,r.Y)("tbody",{children:t.map((e,t)=>{if("meta"===e.type)return(0,r.FD)("tr",{className:"bg-canvas border-y border-ink/10 text-meta select-none",children:[(0,r.Y)("td",{className:"w-12 text-center py-1 px-2 text-[10px] opacity-60 border-r border-ink/10 font-mono",children:"..."}),(0,r.Y)("td",{className:"w-12 text-center py-1 px-2 text-[10px] opacity-60 border-r border-ink/10 font-mono",children:"..."}),(0,r.Y)("td",{className:"py-1 px-3 text-[11px] font-semibold text-meta font-mono tracking-tight",children:e.text})]},t);let n="add"===e.type,i="del"===e.type;return(0,r.FD)("tr",{className:`transition-colors group ${n?"bg-success/10 hover:bg-success/15":i?"bg-error/10 hover:bg-error/15":"hover:bg-ink/[0.03]"}`,children:[(0,r.Y)("td",{className:`w-12 py-0.5 px-2 text-right text-[10px] select-none border-r border-ink/10 font-mono ${i?"bg-error/15 text-error font-semibold":n?"bg-success/15 text-success/70":"bg-canvas/50 text-ink/40"}`,children:e.oldLineNumber||""}),(0,r.Y)("td",{className:`w-12 py-0.5 px-2 text-right text-[10px] select-none border-r border-ink/10 font-mono ${n?"bg-success/15 text-success font-semibold":i?"bg-error/15 text-error/70":"bg-canvas/50 text-ink/40"}`,children:e.newLineNumber||""}),(0,r.FD)("td",{className:"py-0.5 px-3 whitespace-pre text-ink pr-6",children:[(0,r.Y)("span",{className:`inline-block w-4 text-center select-none font-bold ${n?"text-success":i?"text-error":"opacity-0"}`,children:n?"+":i?"-":" "}),(0,r.Y)("span",{className:"shiki",dangerouslySetInnerHTML:{__html:e.text&&l[t]||"&nbsp;"}})]})]},t)})})})})}function Y(e){let{rows:t,language:n}=e,s=(0,w.w)(),l=(0,i.Kr)(()=>{let e=Array(t.length).fill(""),r=Array(t.length).fill(""),i=-1,s=s=>{if(i<0)return;let l=t.slice(i,s),o=(0,a.O9)(l.map(e=>e.left?.text??"").join("\n"),n),c=(0,a.O9)(l.map(e=>e.right?.text??"").join("\n"),n);for(let t=i;t<s;t++)e[t]=o[t-i]??"",r[t]=c[t-i]??"";i=-1};return t.forEach((e,t)=>{e.isMeta?s(t):i<0&&(i=t)}),s(t.length),{left:e,right:r}},[t,n,s]);return 0===t.length?(0,r.Y)("div",{className:"flex-1 flex items-center justify-center text-ink/40 font-mono text-xs p-8",children:"No differences between working file and target."}):(0,r.Y)("div",{className:"w-full h-full overflow-auto font-mono text-xs select-text bg-paper text-ink code-surface",children:(0,r.FD)("div",{className:"w-max min-w-full min-w-[700px]",children:[(0,r.FD)("div",{className:"grid grid-cols-2 sticky top-0 z-10 bg-canvas border-b border-ink/10 text-[11px] text-ink/70 font-sans select-none shadow-xs",children:[(0,r.Y)("div",{className:"px-3 py-1 font-medium border-r border-ink/10 flex items-center justify-between",children:(0,r.Y)("span",{children:"Original (HEAD / Base)"})}),(0,r.Y)("div",{className:"px-3 py-1 font-medium flex items-center justify-between",children:(0,r.Y)("span",{children:"Modified (Working Tree)"})})]}),(0,r.Y)("table",{className:"w-full border-collapse",children:(0,r.Y)("tbody",{children:t.map((e,t)=>{if(e.isMeta)return(0,r.Y)("tr",{className:"bg-canvas border-y border-ink/10 text-meta select-none",children:(0,r.Y)("td",{colSpan:4,className:"py-1 px-3 text-[11px] font-semibold text-meta text-center font-mono",children:e.metaText})},t);let n=e.left,i=e.right,s=n?.type==="del",a=i?.type==="add";return(0,r.FD)("tr",{className:"border-b border-ink/[0.04]",children:[(0,r.Y)("td",{className:`w-12 py-0.5 px-2 text-right text-[10px] select-none border-r border-ink/10 font-mono ${s?"bg-error/15 text-error font-semibold":n?"bg-canvas/50 text-ink/40":"bg-canvas/80 text-transparent"}`,children:n?.lineNumber||""}),(0,r.Y)("td",{className:`min-w-[320px] py-0.5 px-2 whitespace-pre border-r border-ink/10 text-ink ${s?"bg-error/10":n?"hover:bg-ink/[0.02]":"bg-canvas/40 select-none"}`,children:n?(0,r.FD)(r.FK,{children:[(0,r.Y)("span",{className:`inline-block w-4 text-center select-none font-bold ${s?"text-error":"opacity-0"}`,children:s?"-":" "}),(0,r.Y)("span",{className:"shiki",dangerouslySetInnerHTML:{__html:n.text&&l.left[t]||"&nbsp;"}})]}):(0,r.Y)("span",{className:"opacity-0",children:" "})}),(0,r.Y)("td",{className:`w-12 py-0.5 px-2 text-right text-[10px] select-none border-r border-ink/10 font-mono ${a?"bg-success/15 text-success font-semibold":i?"bg-canvas/50 text-ink/40":"bg-canvas/80 text-transparent"}`,children:i?.lineNumber||""}),(0,r.Y)("td",{className:`min-w-[320px] py-0.5 px-2 whitespace-pre text-ink ${a?"bg-success/10":i?"hover:bg-ink/[0.02]":"bg-canvas/40 select-none"}`,children:i?(0,r.FD)(r.FK,{children:[(0,r.Y)("span",{className:`inline-block w-4 text-center select-none font-bold ${a?"text-success":"opacity-0"}`,children:a?"+":" "}),(0,r.Y)("span",{className:"shiki",dangerouslySetInnerHTML:{__html:i.text&&l.right[t]||"&nbsp;"}})]}):(0,r.Y)("span",{className:"opacity-0",children:" "})})]},t)})})})]})})}var S=n("p");function D(e){let{filePath:t,status:n="M",isStaged:o=!1,root:c,repo:d=".",onOpenInEditor:u,onFileSaved:p,className:f=""}=e,[m,x]=(0,l.LO)("diff.viewMode","unified"),[g,b]=(0,l.LO)("diff.ignoreWhitespace",!1),[y,k]=(0,i.J0)(""),[w,D]=(0,i.J0)(n),[F,z]=(0,i.J0)(o),[C,T]=(0,i.J0)(!0),[L,M]=(0,i.J0)(null),[j,A]=(0,i.J0)(!1),[W,E]=(0,i.J0)(!1),$=(0,s.L)(),J=(0,i.hb)(async()=>{if(t){T(!0),M(null);try{let e=new URLSearchParams({fileDiff:"1",file:t,staged:F?"1":"0",repo:d||"."});(n||w)&&e.set("status",n||w),c&&e.set("root",c);let r=await fetch(`/api/fs/git?${e.toString()}`),i=await r.json();i.success?(k(i.diff||""),i.status&&D(i.status)):M(i.error||"Failed to load file diff")}catch(e){M(e.message||"Error fetching diff")}finally{T(!1)}}},[t,F,d,c]);(0,i.vJ)(()=>{D(n),z(o)},[n,o,t]),(0,i.vJ)(()=>{J()},[J]);let K=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=[],r=[],i=0,s=0;if(!e||!e.trim())return{lines:n,splitRows:r,additions:i,deletions:s};let l=e.split(/\r?\n/),a=l.some(e=>e.startsWith("@@"))?l:[`@@ -1,${l.length} +1,${l.length} @@`,...l],o=1,c=1,d=[],u=[],h=()=>{let e=Math.max(d.length,u.length);for(let t=0;t<e;t++)r.push({left:d[t]?{type:"del",text:d[t].text,lineNumber:d[t].lineNumber}:void 0,right:u[t]?{type:"add",text:u[t].text,lineNumber:u[t].lineNumber}:void 0});d=[],u=[]};for(let e of a)if(!(e.startsWith("diff --git")||e.startsWith("index ")||e.startsWith("---")||e.startsWith("+++")||e.startsWith("new file mode")||e.startsWith("deleted file mode")||e.startsWith("similarity index")||e.startsWith("old mode")||e.startsWith("new mode")||e.startsWith("\\ No newline"))){if(e.startsWith("@@")){h();let t=e.match(/@@ -(\d+)(?:,\d+)? \+(\d+)(?:,\d+)? @@/);t&&(o=parseInt(t[1],10),c=parseInt(t[2],10)),n.push({type:"meta",text:e}),r.push({isMeta:!0,metaText:e});continue}if(e.startsWith("+")){let r=e.slice(1),s=t?r.trim():r;i++,n.push({type:"add",text:s,newLineNumber:c}),u.push({text:s,lineNumber:c}),c++}else if(e.startsWith("-")){let r=e.slice(1),i=t?r.trim():r;s++,n.push({type:"del",text:i,oldLineNumber:o}),d.push({text:i,lineNumber:o}),o++}else{h();let i=e.startsWith(" ")?e.slice(1):e,s=t?i.trim():i;n.push({type:"context",text:s,oldLineNumber:o,newLineNumber:c}),r.push({left:{type:"context",text:s,lineNumber:o},right:{type:"context",text:s,lineNumber:c}}),o++,c++}}return h(),{lines:n,splitRows:r,additions:i,deletions:s}}(y,g),R=(0,a.sQ)(t);return(0,r.FD)("div",{className:`flex flex-col h-full bg-paper select-text relative font-sans ${f}`,children:[(0,r.Y)(v,{filePath:t,status:w,isStaged:F,viewMode:m,ignoreWhitespace:g,additions:K.additions,deletions:K.deletions,isLoading:C,isCopied:j,onToggleViewMode:()=>{x("unified"===m?"split":"unified")},onToggleWhitespace:()=>{b(!g)},onStageUnstage:()=>{let e=F?"unstage":"stage",n=new FormData;n.set("actionType",e),n.set("file",t),n.set("repo",d||"."),c&&n.set("root",c),$.submit(n,{method:"POST",action:"/api/fs/git"}),z(!F),setTimeout(()=>{J(),p?.()},300)},onDiscard:()=>{E(!0)},onOpenInEditor:u,onRefresh:J,onCopyDiff:()=>{y&&(navigator.clipboard.writeText(y),A(!0),setTimeout(()=>A(!1),2e3))}}),(0,r.Y)("div",{className:"flex-1 overflow-hidden relative flex flex-col bg-paper",children:C?(0,r.FD)("div",{className:"flex-1 flex items-center justify-center space-x-2 text-ink/50 text-xs font-mono",children:[(0,r.Y)(h.A,{size:14,className:"animate-spin"}),(0,r.Y)("span",{children:"Loading file diff..."})]}):L?(0,r.FD)("div",{className:"flex-1 flex flex-col items-center justify-center p-6 text-center space-y-2",children:[(0,r.Y)(S.A,{size:20,className:"text-error"}),(0,r.Y)("p",{className:"text-xs text-error font-medium",children:L}),(0,r.Y)("button",{onClick:J,className:"px-3 py-1 text-xs bg-ink/10 hover:bg-ink/15 text-ink rounded font-sans transition-colors",children:"Retry"})]}):"split"===m?(0,r.Y)(Y,{rows:K.splitRows,language:R}):(0,r.Y)(N,{lines:K.lines,language:R})}),W&&(0,r.Y)("div",{className:"fixed inset-0 bg-ink/20 z-50 flex items-center justify-center p-4 backdrop-blur-xs",children:(0,r.FD)("div",{className:"bg-paper rounded-lg shadow-xl p-4 w-full max-w-sm border border-ink/15",children:[(0,r.Y)("h3",{className:"font-semibold text-ink mb-1.5 text-sm",children:"Discard Changes?"}),(0,r.FD)("p",{className:"text-xs text-ink/70 mb-4",children:["Are you sure you want to discard all unstaged changes in ",(0,r.Y)("span",{className:"font-mono font-medium text-ink",children:t}),"? This cannot be undone."]}),(0,r.FD)("div",{className:"flex justify-end space-x-2",children:[(0,r.Y)("button",{type:"button",onClick:()=>E(!1),className:"px-3 py-1.5 text-xs text-ink hover:bg-ink/5 rounded transition-colors",children:"Cancel"}),(0,r.Y)("button",{type:"button",onClick:()=>{E(!1);let e=new FormData;e.set("actionType","discard"),e.set("file",t),e.set("repo",d||"."),c&&e.set("root",c),$.submit(e,{method:"POST",action:"/api/fs/git"}),setTimeout(()=>{J(),p?.()},300)},className:"px-3 py-1.5 text-xs bg-error text-white rounded hover:bg-error/90 font-medium transition-colors",children:"Discard Changes"})]})]})})]})}},XY(e,t,n){var r=n("H"),i=n("DU");function s(e){return String(e.id??e.path??e.name)}function l(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{fallback:n,reportLoadError:l=!1,flushOnUnmount:a=!1,reportSaveError:o=!1,downloadMimeType:c="text/plain",onFileSaved:d}=t,[u,h]=(0,r.J0)({}),[p,f]=(0,r.J0)({}),[m,x]=(0,r.J0)(!1),[g,b]=(0,r.J0)(null),[y,k]=(0,r.J0)("idle"),[v,w]=(0,r.J0)(!1),[N,Y]=(0,r.J0)(0),S=e?s(e):"",D=e?u[S]??e.content??"":"",F=D!==(p[S]??D),z=(0,r.li)(new Set),C=(0,r.li)(null),T=(0,r.li)(u);T.current=u;let L=(0,r.li)(p);L.current=p;let M=(0,r.hb)((e,t)=>{h(n=>({...n,[e]:t})),f(n=>({...n,[e]:t}))},[]),j=(0,r.hb)(async(e,t)=>{if(!e.path)return;k("saving");let n=new FormData;n.append("actionType","save"),n.append("path",e.path),n.append("content",t),e.root&&n.append("root",e.root),e.repo&&"."!==e.repo&&n.append("repo",e.repo);try{let r=await fetch("/api/fs/action",{method:"POST",body:n}),i=await r.json().catch(()=>null);r.ok&&i?.success?(k("saved"),f(n=>({...n,[s(e)]:t})),d?.()):k(o?"error":"idle")}catch{k(o?"error":"idle")}},[d,o]),A=(0,r.li)(j);A.current=j,(0,r.vJ)(()=>{if(!e)return;let t=s(e);if(z.current.has(t))return;if(z.current.add(t),void 0!==e.content){M(t,e.content),b(null);return}if(!e.path)return l?void b("No file path supplied for this attachment."):void M(t,n?n(e.name):"");let r=void 0===T.current[t],i=!1;r&&x(!0),b(null);let a=new URLSearchParams({path:e.path});return e.root&&a.set("root",e.root),e.repo&&"."!==e.repo&&a.set("repo",e.repo),fetch(`/api/fs/read?${a.toString()}`).then(async e=>{let t=await e.json().catch(()=>null);if(l){if(!e.ok||!t||"string"!=typeof t.content)throw Error(t?.error||`HTTP ${e.status}`);return t.content}return"string"==typeof t?.content?t.content:null}).then(r=>{if(i)return;let l=T.current[t];if(void 0!==l&&l!==L.current[t])return;let a=C.current;a&&s(a.file)===t||M(t,r??(n?n(e.name):""))}).catch(s=>{i||r&&(l?(M(t,""),b(s instanceof Error?s.message:"Failed to read file")):M(t,n?n(e.name):""))}).finally(()=>{i||x(!1)}),()=>{i=!0}},[S,e,n,l,M,N]),(0,r.vJ)(()=>{if("saved"!==y)return;let e=window.setTimeout(()=>k("idle"),1500);return()=>window.clearTimeout(e)},[y]);let W=(0,r.hb)(t=>{if(!e)return;let n=s(e);if(h(e=>({...e,[n]:t})),!e.path)return;C.current&&window.clearTimeout(C.current.timer);let r=window.setTimeout(()=>{C.current=null,A.current(e,t)},800);C.current={timer:r,file:e,content:t}},[e]),E=(0,r.hb)(()=>{if(!e)return;let t=u[s(e)];void 0!==t&&(C.current&&(window.clearTimeout(C.current.timer),C.current=null),A.current(e,t))},[e,u]),$=(0,r.hb)(()=>{e&&navigator.clipboard&&navigator.clipboard.writeText(u[s(e)]??"").then(()=>{w(!0),window.setTimeout(()=>w(!1),1500)}).catch(()=>{})},[e,u]),J=(0,r.hb)(()=>{if(!e)return;let t=new Blob([u[s(e)]??""],{type:c}),n=URL.createObjectURL(t),r=document.createElement("a");r.href=n,r.download=e.name,r.click(),URL.revokeObjectURL(n)},[e,u,c]),K=(0,r.hb)(()=>{z.current.clear(),Y(e=>e+1)},[]),R=(0,r.hb)(e=>{let t=new Set(e.map(String));for(let e of Array.from(z.current))t.has(e)||z.current.delete(e);h(e=>{let n=Object.keys(e);if(n.every(e=>t.has(e)))return e;let r={};for(let i of n)t.has(i)&&(r[i]=e[i]);return r})},[]);return(0,r.vJ)(()=>{if(a)return()=>{let e=C.current;e&&(window.clearTimeout(e.timer),C.current=null,A.current(e.file,e.content))}},[a]),{content:D,onChange:W,isLoading:m,loadError:g,saveStatus:y,copied:v,isDirty:F,language:e?(0,i.sQ)(e.name):"javascript",saveNow:E,copy:$,download:J,reset:K,retain:R}}n.d(t,{n:()=>l})},Soe(e,t,n){let r=(0,n("y").A)({name:"eye-off",size:24,node:[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]});n.d(t,{},{A:r})},DV(e,t,n){let r=(0,n("y").A)({name:"minus",size:24,node:[["path",{d:"M5 12h14",key:"1ays0h"}]]});n.d(t,{},{A:r})},yh(e,t,n){let r=(0,n("y").A)({name:"text-wrap",size:24,node:[["path",{d:"m16 16-3 3 3 3",key:"117b85"}],["path",{d:"M3 12h14.5a1 1 0 0 1 0 7H13",key:"18xa6z"}],["path",{d:"M3 19h6",key:"1ygdsz"}],["path",{d:"M3 5h18",key:"1u36vt"}]],aliases:["wrap-text"]});n.d(t,{},{A:r})},na(e,t,n){let r=(0,n("y").A)({name:"zoom-in",size:24,node:[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["line",{x1:"21",x2:"16.65",y1:"21",y2:"16.65",key:"13gj7c"}],["line",{x1:"11",x2:"11",y1:"8",y2:"14",key:"1vmskp"}],["line",{x1:"8",x2:"14",y1:"11",y2:"11",key:"durymu"}]]});n.d(t,{},{A:r})},hj(e,t,n){let r=(0,n("y").A)({name:"zoom-out",size:24,node:[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["line",{x1:"21",x2:"16.65",y1:"21",y2:"16.65",key:"13gj7c"}],["line",{x1:"8",x2:"14",y1:"11",y2:"11",key:"durymu"}]]});n.d(t,{},{A:r})}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.rspackChunkompchamber=self.rspackChunkompchamber||[]).push([["nk"],{d7(e,r,t){var a=t("I6"),n=t("P0");t("MM"),t("Yr");var s=t("M4"),l=t("Gt"),p=t("Xe"),i=(0,p.Pz)().RailroadPeg.parser.LangiumParser,o=(0,l.K)(e=>{let r=e.alternatives.map(u);return 1===r.length?r[0]:{type:"choice",alternatives:r}},"transformOrderedChoice"),u=(0,l.K)(e=>{let r=e.elements.map(m);return 1===r.length?r[0]:{type:"sequence",elements:r}},"transformSequence"),m=(0,l.K)(e=>{let r=c(e.suffix);return e.operator?{type:"special",text:"&"===e.operator?`&${d(r)}`:`!${d(r)}`}:r},"transformPrefix"),d=(0,l.K)(e=>{switch(e.type){case"terminal":return`"${e.value}"`;case"nonterminal":return e.name;case"special":return e.text;default:return"(...)"}},"nodeToLabel"),c=(0,l.K)(e=>{let r=f(e.primary);if(!e.operator)return r;switch(e.operator){case"?":return{type:"optional",element:r};case"*":return{type:"repetition",element:r,min:0,max:1/0};case"+":return{type:"repetition",element:r,min:1,max:1/0};default:throw Error(`Unsupported PEG suffix operator: ${e.operator}`)}},"transformSuffix"),f=(0,l.K)(e=>{switch(e.$type){case"PegLiteral":return{type:"terminal",value:e.value};case"PegIdentifier":return{type:"nonterminal",name:e.name};case"PegGroup":return o(e.element);case"PegAny":return{type:"special",text:e.dot};default:throw Error(`Unsupported PEG primary node: ${e.$type}`)}},"transformPrimary"),P=(0,l.K)(e=>({name:e.name,definition:o(e.definition)}),"transformRule"),y=(0,l.K)(e=>{(0,n.S)(e,a.db),e.title&&a.db.setTitle(e.title),e.rules.map(e=>a.db.addRule(P(e)))},"populateDb"),g={parser:{parse:(0,l.K)(e=>{a.db.clear(),s.R.debug("[PEG Parser] Starting Langium parse");let r=i.parse(e);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new p.zg(r);let t=r.value;s.R.debug("[PEG Parser] Parsed rules:",t.rules.length),y(t),s.R.debug("[PEG Parser] Parse complete")},"parse"),parser:{yy:a.db}},db:a.db,renderer:a.U,styles:a.$};t.d(r,{diagram:()=>g})}}]);
@@ -1,5 +1,5 @@
1
- /*! LICENSE: q.7fb4d2f374.js.LICENSE.txt */
2
- "use strict";(self.rspackChunkompchamber=self.rspackChunkompchamber||[]).push([["q"],{o3(e,t,i){i.d(t,{Editor:()=>W});var n=i("j"),r=i("H"),o=i("ob"),a=i("HO"),s=i("rK"),l=i("jo"),c=i("YOg"),d=i("S"),m=i("Go"),p=i("oj"),f=i("LQ");function h(e){let{openedFiles:t,activeFileId:i,onSelectFile:a,onCloseFile:s}=e,l=(0,r.li)(null),h=(0,r.li)(null),[x,u]=(0,r.J0)(5),[v,k]=(0,r.J0)(!1);(0,p.W)(h,()=>k(!1)),(0,r.vJ)(()=>{let e=new ResizeObserver(e=>{for(let t of e)u(Math.max(1,Math.floor((t.contentRect.width-60)/150)))});return l.current&&e.observe(l.current),()=>e.disconnect()},[]);let b=[],g=[];if(t.length<=x)b=t;else{let e=t.findIndex(e=>e.id===i),n=new Set;-1!==e&&null!==i&&n.add(i);for(let e=t.length-1;e>=0&&!(n.size>=x);e--)n.add(t[e].id);b=t.filter(e=>n.has(e.id)),g=t.filter(e=>!n.has(e.id))}return(0,n.FD)("div",{className:"flex bg-ink/10 w-full relative border-b border-ink/10",ref:l,children:[(0,n.Y)("div",{className:"flex overflow-hidden",children:b.map(e=>{let t=e.id===i,r=!!e.isDiff,l=r?(0,f.R)(e.diffStatus||"M",e.diffStaged):null;return(0,n.FD)("div",{onClick:()=>a(e.id),className:`flex items-center space-x-1.5 px-3 py-1.5 cursor-pointer border-r border-ink/10 min-w-[120px] max-w-[210px] group ${t?"bg-paper border-t-2 border-t-ink text-ink":"bg-transparent border-t-2 border-t-transparent text-ink/60 hover:bg-paper/50"}`,title:e.path,children:[r?(0,n.Y)(c.A,{size:14,className:t?"text-blue-600 dark:text-blue-400 flex-shrink-0":"opacity-60 flex-shrink-0"}):(0,n.Y)(o.o,{name:e.name,size:14,className:t?"flex-shrink-0":"opacity-60 flex-shrink-0"}),(0,n.Y)("span",{className:"text-xs font-mono truncate flex-1",children:e.name}),l&&(0,n.Y)("span",{className:`px-1 text-[9px] font-mono font-bold rounded ${l.badgeBgClass}`,children:l.charStatus}),(0,n.Y)("div",{className:`p-0.5 rounded hover:bg-ink/10 ${t?"opacity-100":"opacity-0 group-hover:opacity-100"}`,onClick:t=>{t.stopPropagation(),s(e.id)},children:(0,n.Y)(d.A,{size:12})})]},e.id)})}),g.length>0&&(0,n.FD)("div",{className:"relative flex items-center ml-auto bg-ink/10",ref:h,children:[(0,n.Y)("button",{className:`p-1.5 mx-1 rounded hover:bg-ink/10 text-ink/60 ${v?"bg-ink/10 text-ink":""}`,onClick:()=>k(!v),title:"More open files",children:(0,n.Y)(m.A,{size:14})}),v&&(0,n.FD)("div",{className:"absolute right-0 top-full mt-1 w-52 bg-paper border border-ink/10 rounded shadow-lg z-50 py-1",children:[(0,n.Y)("div",{className:"px-3 py-1 text-[10px] uppercase font-mono text-ink/40 border-b border-ink/10 mb-1",children:"Older Tabs"}),g.map(e=>(0,n.FD)("div",{onClick:()=>{a(e.id),k(!1)},className:"flex items-center space-x-2 px-3 py-1.5 hover:bg-ink/5 cursor-pointer group",children:[e.isDiff?(0,n.Y)(c.A,{size:14,className:"text-blue-600 opacity-70"}):(0,n.Y)(o.o,{name:e.name,size:14,className:"opacity-60"}),(0,n.Y)("span",{className:"text-xs font-mono truncate flex-1 text-ink/80",children:e.name}),(0,n.Y)("div",{className:"p-0.5 rounded hover:bg-ink/10 opacity-0 group-hover:opacity-100",onClick:t=>{t.stopPropagation(),s(e.id),1===g.length&&k(!1)},children:(0,n.Y)(d.A,{size:12,className:"text-ink/60"})})]},e.id))]})]})]})}var x=i("ES0"),u=i("z"),v=i("Soe"),k=i("bH"),b=i("yh"),g=i("hj"),N=i("na"),y=i("b0"),Y=i("tC");let w=(0,i("y").A)({name:"maximize",size:24,node:[["path",{d:"M8 3H5a2 2 0 0 0-2 2v3",key:"1dcmit"}],["path",{d:"M21 8V5a2 2 0 0 0-2-2h-3",key:"1e4gt3"}],["path",{d:"M3 16v3a2 2 0 0 0 2 2h3",key:"wsl5sc"}],["path",{d:"M16 21h3a2 2 0 0 0 2-2v-3",key:"18trek"}]]});function z(e){let{path:t,saveStatus:i,wordWrap:r,isMd:o,isPreview:a,onSave:s,onTogglePreview:l,onToggleWordWrap:c,onZoomIn:d,onZoomOut:m,onCopy:p,onDownload:f,onToggleMaximize:h}=e;return(0,n.FD)("div",{className:"flex items-center justify-between px-3 py-2 border-b border-ink/10 bg-paper",children:[(0,n.Y)("div",{className:"flex items-center space-x-2 text-xs font-mono text-ink/40",children:(0,n.Y)("span",{className:"truncate max-w-[300px]",title:t,children:t})}),(0,n.FD)("div",{className:"flex items-center space-x-3 text-ink/40",children:[(0,n.Y)("div",{className:"flex items-center pr-3 border-r border-ink/10",children:(0,n.Y)("button",{type:"button",onClick:s,className:"flex items-center justify-center rounded hover:bg-ink/5 transition-colors",title:"Save file (Ctrl+S)",children:"saving"===i?(0,n.Y)(x.A,{size:14,className:"text-amber-500 animate-pulse"}):"saved"===i?(0,n.Y)(u.A,{size:14,className:"text-success"}):(0,n.Y)(x.A,{size:14,className:"hover:text-ink cursor-pointer"})})}),o&&(0,n.Y)("div",{onClick:l,className:"flex items-center pr-3 border-r border-ink/10",children:a?(0,n.Y)(v.A,{size:14,className:"hover:text-ink cursor-pointer"}):(0,n.Y)(k.A,{size:14,className:"hover:text-ink cursor-pointer"})}),(0,n.Y)("div",{className:"flex items-center space-x-2 pr-3 border-r border-ink/10",children:(0,n.Y)(b.A,{size:14,className:`cursor-pointer ${r?"text-ink":"hover:text-ink"}`,onClick:c})}),(0,n.FD)("div",{className:"flex items-center space-x-2 pr-3 border-r border-ink/10",children:[(0,n.Y)(g.A,{size:14,className:"hover:text-ink cursor-pointer",onClick:m}),(0,n.Y)(N.A,{size:14,className:"hover:text-ink cursor-pointer",onClick:d})]}),(0,n.FD)("div",{className:"flex items-center space-x-2 pr-3 border-r border-ink/10",children:[(0,n.Y)(y.A,{size:14,className:"hover:text-ink cursor-pointer",onClick:p}),(0,n.Y)(Y.A,{size:14,className:"hover:text-ink cursor-pointer",onClick:f})]}),(0,n.Y)("div",{className:"flex items-center pl-1",children:(0,n.Y)(w,{size:14,className:"hover:text-ink cursor-pointer",onClick:h})})]})]})}function C(e){if(e.endsWith(".md"))return`# ${e.replace(".md","")}
1
+ /*! LICENSE: q.542c184fec.js.LICENSE.txt */
2
+ "use strict";(self.rspackChunkompchamber=self.rspackChunkompchamber||[]).push([["q"],{o3(e,t,i){i.d(t,{Editor:()=>W});var n=i("j"),r=i("H"),o=i("ob"),a=i("Ml"),s=i("rK"),l=i("jo"),c=i("YOg"),d=i("S"),m=i("Go"),p=i("oj"),f=i("LQ");function h(e){let{openedFiles:t,activeFileId:i,onSelectFile:a,onCloseFile:s}=e,l=(0,r.li)(null),h=(0,r.li)(null),[x,u]=(0,r.J0)(5),[v,k]=(0,r.J0)(!1);(0,p.W)(h,()=>k(!1)),(0,r.vJ)(()=>{let e=new ResizeObserver(e=>{for(let t of e)u(Math.max(1,Math.floor((t.contentRect.width-60)/150)))});return l.current&&e.observe(l.current),()=>e.disconnect()},[]);let b=[],g=[];if(t.length<=x)b=t;else{let e=t.findIndex(e=>e.id===i),n=new Set;-1!==e&&null!==i&&n.add(i);for(let e=t.length-1;e>=0&&!(n.size>=x);e--)n.add(t[e].id);b=t.filter(e=>n.has(e.id)),g=t.filter(e=>!n.has(e.id))}return(0,n.FD)("div",{className:"flex bg-ink/10 w-full relative border-b border-ink/10",ref:l,children:[(0,n.Y)("div",{className:"flex overflow-hidden",children:b.map(e=>{let t=e.id===i,r=!!e.isDiff,l=r?(0,f.R)(e.diffStatus||"M",e.diffStaged):null;return(0,n.FD)("div",{onClick:()=>a(e.id),className:`flex items-center space-x-1.5 px-3 py-1.5 cursor-pointer border-r border-ink/10 min-w-[120px] max-w-[210px] group ${t?"bg-paper border-t-2 border-t-ink text-ink":"bg-transparent border-t-2 border-t-transparent text-ink/60 hover:bg-paper/50"}`,title:e.path,children:[r?(0,n.Y)(c.A,{size:14,className:t?"text-blue-600 dark:text-blue-400 flex-shrink-0":"opacity-60 flex-shrink-0"}):(0,n.Y)(o.o,{name:e.name,size:14,className:t?"flex-shrink-0":"opacity-60 flex-shrink-0"}),(0,n.Y)("span",{className:"text-xs font-mono truncate flex-1",children:e.name}),l&&(0,n.Y)("span",{className:`px-1 text-[9px] font-mono font-bold rounded ${l.badgeBgClass}`,children:l.charStatus}),(0,n.Y)("div",{className:`p-0.5 rounded hover:bg-ink/10 ${t?"opacity-100":"opacity-0 group-hover:opacity-100"}`,onClick:t=>{t.stopPropagation(),s(e.id)},children:(0,n.Y)(d.A,{size:12})})]},e.id)})}),g.length>0&&(0,n.FD)("div",{className:"relative flex items-center ml-auto bg-ink/10",ref:h,children:[(0,n.Y)("button",{className:`p-1.5 mx-1 rounded hover:bg-ink/10 text-ink/60 ${v?"bg-ink/10 text-ink":""}`,onClick:()=>k(!v),title:"More open files",children:(0,n.Y)(m.A,{size:14})}),v&&(0,n.FD)("div",{className:"absolute right-0 top-full mt-1 w-52 bg-paper border border-ink/10 rounded shadow-lg z-50 py-1",children:[(0,n.Y)("div",{className:"px-3 py-1 text-[10px] uppercase font-mono text-ink/40 border-b border-ink/10 mb-1",children:"Older Tabs"}),g.map(e=>(0,n.FD)("div",{onClick:()=>{a(e.id),k(!1)},className:"flex items-center space-x-2 px-3 py-1.5 hover:bg-ink/5 cursor-pointer group",children:[e.isDiff?(0,n.Y)(c.A,{size:14,className:"text-blue-600 opacity-70"}):(0,n.Y)(o.o,{name:e.name,size:14,className:"opacity-60"}),(0,n.Y)("span",{className:"text-xs font-mono truncate flex-1 text-ink/80",children:e.name}),(0,n.Y)("div",{className:"p-0.5 rounded hover:bg-ink/10 opacity-0 group-hover:opacity-100",onClick:t=>{t.stopPropagation(),s(e.id),1===g.length&&k(!1)},children:(0,n.Y)(d.A,{size:12,className:"text-ink/60"})})]},e.id))]})]})]})}var x=i("ES0"),u=i("z"),v=i("Soe"),k=i("bH"),b=i("yh"),g=i("hj"),N=i("na"),y=i("b0"),Y=i("tC");let w=(0,i("y").A)({name:"maximize",size:24,node:[["path",{d:"M8 3H5a2 2 0 0 0-2 2v3",key:"1dcmit"}],["path",{d:"M21 8V5a2 2 0 0 0-2-2h-3",key:"1e4gt3"}],["path",{d:"M3 16v3a2 2 0 0 0 2 2h3",key:"wsl5sc"}],["path",{d:"M16 21h3a2 2 0 0 0 2-2v-3",key:"18trek"}]]});function z(e){let{path:t,saveStatus:i,wordWrap:r,isMd:o,isPreview:a,onSave:s,onTogglePreview:l,onToggleWordWrap:c,onZoomIn:d,onZoomOut:m,onCopy:p,onDownload:f,onToggleMaximize:h}=e;return(0,n.FD)("div",{className:"flex items-center justify-between px-3 py-2 border-b border-ink/10 bg-paper",children:[(0,n.Y)("div",{className:"flex items-center space-x-2 text-xs font-mono text-ink/40",children:(0,n.Y)("span",{className:"truncate max-w-[300px]",title:t,children:t})}),(0,n.FD)("div",{className:"flex items-center space-x-3 text-ink/40",children:[(0,n.Y)("div",{className:"flex items-center pr-3 border-r border-ink/10",children:(0,n.Y)("button",{type:"button",onClick:s,className:"flex items-center justify-center rounded hover:bg-ink/5 transition-colors",title:"Save file (Ctrl+S)",children:"saving"===i?(0,n.Y)(x.A,{size:14,className:"text-amber-500 animate-pulse"}):"saved"===i?(0,n.Y)(u.A,{size:14,className:"text-success"}):(0,n.Y)(x.A,{size:14,className:"hover:text-ink cursor-pointer"})})}),o&&(0,n.Y)("div",{onClick:l,className:"flex items-center pr-3 border-r border-ink/10",children:a?(0,n.Y)(v.A,{size:14,className:"hover:text-ink cursor-pointer"}):(0,n.Y)(k.A,{size:14,className:"hover:text-ink cursor-pointer"})}),(0,n.Y)("div",{className:"flex items-center space-x-2 pr-3 border-r border-ink/10",children:(0,n.Y)(b.A,{size:14,className:`cursor-pointer ${r?"text-ink":"hover:text-ink"}`,onClick:c})}),(0,n.FD)("div",{className:"flex items-center space-x-2 pr-3 border-r border-ink/10",children:[(0,n.Y)(g.A,{size:14,className:"hover:text-ink cursor-pointer",onClick:m}),(0,n.Y)(N.A,{size:14,className:"hover:text-ink cursor-pointer",onClick:d})]}),(0,n.FD)("div",{className:"flex items-center space-x-2 pr-3 border-r border-ink/10",children:[(0,n.Y)(y.A,{size:14,className:"hover:text-ink cursor-pointer",onClick:p}),(0,n.Y)(Y.A,{size:14,className:"hover:text-ink cursor-pointer",onClick:f})]}),(0,n.Y)("div",{className:"flex items-center pl-1",children:(0,n.Y)(w,{size:14,className:"hover:text-ink cursor-pointer",onClick:h})})]})]})}function C(e){if(e.endsWith(".md"))return`# ${e.replace(".md","")}
3
3
 
4
4
  This is a mock markdown file.
5
5
 
@@ -18,4 +18,4 @@ export default function ${t||"Component"}() {
18
18
  }`:e.endsWith(".css")?`.container {
19
19
  display: flex;
20
20
  flex-direction: column;
21
- }`:`Content for ${e}`}var S=i("Xg"),F=i("FL"),M=i("As"),A=i("SS"),D=i("XY");function W(e){let{className:t="",openedFiles:i,activeFileId:c,onSelectFile:d,onCloseFile:m,refreshKey:p=0,onFileSaved:f}=e,x=i.find(e=>e.id===c),[u,v,k]=(0,F.bL)("editor.previewMode",{}),[b,g]=(0,F.bL)("editor.zoomLevel",12),[N,y]=(0,r.J0)(!1),[Y,w]=(0,F.bL)("editor.wordWrap",!0),{sessionId:W}=(0,M.O)(),{isScrolling:$,handleScroll:H}=(0,l.K)(),j=(0,D.n)(x??null,{fallback:C,onFileSaved:f});if((0,r.vJ)(()=>{p>0&&j.reset()},[p]),(0,r.vJ)(()=>{j.retain(i.map(e=>e.id))},[i]),(0,r.vJ)(()=>{if(!k)return;let e=x?.id;if(null==e||!x.name.endsWith(".md"))return;let t=(0,A.WV)(W,"editor.previewMode");t&&void 0!==t[e]||v(t=>void 0===t[e]?{...t,[e]:!0}:t)},[k,x]),(0,r.vJ)(()=>{let e=e=>{(e.ctrlKey||e.metaKey)&&"s"===e.key&&(e.preventDefault(),j.saveNow())};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[j.saveNow]),0===i.length)return(0,n.FD)("div",{className:`flex flex-col h-full bg-canvas items-center justify-center text-ink/40 ${t}`,children:[(0,n.Y)(o.o,{name:"placeholder.txt",size:48,className:"mb-4 opacity-20"}),(0,n.Y)("p",{className:"font-mono text-sm",children:"Select a file to open"})]});let J=j.content,L=x?.name.endsWith(".md"),O=!!x&&u[x.id],P="error"===j.saveStatus?"idle":j.saveStatus,T=N?"fixed inset-0 z-50 flex flex-col bg-canvas":`flex flex-col h-full bg-canvas ${t}`;return(0,n.FD)("div",{className:T,children:[(0,n.Y)(h,{openedFiles:i,activeFileId:c,onSelectFile:d,onCloseFile:m}),x?x.isDiff?(0,n.Y)(S.M,{filePath:x.path,status:x.diffStatus||"M",isStaged:!!x.diffStaged,root:x.root,repo:x.repo||".",onOpenInEditor:()=>{x.isDiff=!1,d(x.id)},onFileSaved:f,className:"flex-1"}):(0,n.FD)(n.FK,{children:[(0,n.Y)(z,{path:x.path,saveStatus:P,wordWrap:Y,isMd:L,isPreview:O,onSave:j.saveNow,onTogglePreview:()=>{x&&v(e=>({...e,[x.id]:!e[x.id]}))},onToggleWordWrap:()=>w(!Y),onZoomIn:()=>g(e=>Math.min(24,e+1)),onZoomOut:()=>g(e=>Math.max(8,e-1)),onCopy:j.copy,onDownload:j.download,onToggleMaximize:()=>y(!N)}),(0,n.Y)("div",{onScroll:H,className:`flex-1 overflow-auto bg-paper flex ${(0,l.p)($)}`,children:L&&O?(0,n.Y)("div",{className:"p-6 prose prose-sm max-w-4xl mx-auto font-sans flex-1",style:{fontSize:`${b}px`},children:(0,n.Y)(s.T,{content:J})}):(0,n.Y)(a.P,{value:J,onValueChange:j.onChange,language:j.language,wordWrap:Y,rootClassName:"flex",gutterClassName:"flex flex-col text-right pl-4 pr-3 select-none text-ink/30 font-mono border-r border-ink/10 bg-canvas sticky left-0 z-10",gutterStyle:{fontSize:b,paddingTop:16,paddingBottom:16,lineHeight:1.5,fontFamily:'"Fira Code", "JetBrains Mono", "SF Mono", Consolas, monospace'},gutterLineClassName:"min-w-[1.5rem]",editorWrapperClassName:"flex-1 min-w-max code-surface",editorPadding:16,editorClassName:"font-mono focus:outline-none",editorStyle:{fontFamily:'"Fira Code", "JetBrains Mono", "SF Mono", Consolas, monospace',fontSize:b,lineHeight:1.5,minHeight:"100%"}})})]}):(0,n.Y)("div",{className:"flex-1 flex items-center justify-center text-ink/40",children:(0,n.Y)("p",{className:"font-mono text-sm",children:"Select a tab to view content"})})]})}},YOg(e,t,i){let n=(0,i("y").A)({name:"git-compare",size:24,node:[["circle",{cx:"18",cy:"18",r:"3",key:"1xkwt0"}],["circle",{cx:"6",cy:"6",r:"3",key:"1lh9wr"}],["path",{d:"M13 6h3a2 2 0 0 1 2 2v7",key:"1yeb86"}],["path",{d:"M11 18H8a2 2 0 0 1-2-2V9",key:"19pyzm"}]]});i.d(t,{},{A:n})},ES0(e,t,i){let n=(0,i("y").A)({name:"save",size:24,node:[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]});i.d(t,{},{A:n})}}]);
21
+ }`:`Content for ${e}`}var S=i("Xg"),M=i("FL"),F=i("As"),A=i("SS"),D=i("XY");function W(e){let{className:t="",openedFiles:i,activeFileId:c,onSelectFile:d,onCloseFile:m,refreshKey:p=0,onFileSaved:f}=e,x=i.find(e=>e.id===c),[u,v,k]=(0,M.bL)("editor.previewMode",{}),[b,g]=(0,M.bL)("editor.zoomLevel",12),[N,y]=(0,r.J0)(!1),[Y,w]=(0,M.bL)("editor.wordWrap",!0),{sessionId:W}=(0,F.O)(),{isScrolling:$,handleScroll:j}=(0,l.K)(),H=(0,D.n)(x??null,{fallback:C,onFileSaved:f});if((0,r.vJ)(()=>{p>0&&H.reset()},[p]),(0,r.vJ)(()=>{H.retain(i.map(e=>e.id))},[i]),(0,r.vJ)(()=>{if(!k)return;let e=x?.id;if(null==e||!x.name.endsWith(".md"))return;let t=(0,A.WV)(W,"editor.previewMode");t&&void 0!==t[e]||v(t=>void 0===t[e]?{...t,[e]:!0}:t)},[k,x]),(0,r.vJ)(()=>{let e=e=>{(e.ctrlKey||e.metaKey)&&"s"===e.key&&(e.preventDefault(),H.saveNow())};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[H.saveNow]),0===i.length)return(0,n.FD)("div",{className:`flex flex-col h-full bg-canvas items-center justify-center text-ink/40 ${t}`,children:[(0,n.Y)(o.o,{name:"placeholder.txt",size:48,className:"mb-4 opacity-20"}),(0,n.Y)("p",{className:"font-mono text-sm",children:"Select a file to open"})]});let J=H.content,L=x?.name.endsWith(".md"),O=!!x&&u[x.id],P="error"===H.saveStatus?"idle":H.saveStatus,T=N?"fixed inset-0 z-50 flex flex-col bg-canvas":`flex flex-col h-full bg-canvas ${t}`;return(0,n.FD)("div",{className:T,children:[(0,n.Y)(h,{openedFiles:i,activeFileId:c,onSelectFile:d,onCloseFile:m}),x?x.isDiff?(0,n.Y)(S.M,{filePath:x.path,status:x.diffStatus||"M",isStaged:!!x.diffStaged,root:x.root,repo:x.repo||".",onOpenInEditor:()=>{x.isDiff=!1,d(x.id)},onFileSaved:f,className:"flex-1"}):(0,n.FD)(n.FK,{children:[(0,n.Y)(z,{path:x.path,saveStatus:P,wordWrap:Y,isMd:L,isPreview:O,onSave:H.saveNow,onTogglePreview:()=>{x&&v(e=>({...e,[x.id]:!e[x.id]}))},onToggleWordWrap:()=>w(!Y),onZoomIn:()=>g(e=>Math.min(24,e+1)),onZoomOut:()=>g(e=>Math.max(8,e-1)),onCopy:H.copy,onDownload:H.download,onToggleMaximize:()=>y(!N)}),(0,n.Y)("div",{onScroll:j,className:`flex-1 overflow-auto bg-paper flex ${(0,l.p)($)}`,children:L&&O?(0,n.Y)("div",{className:"p-6 prose prose-sm max-w-4xl mx-auto font-sans flex-1",style:{fontSize:`${b}px`},children:(0,n.Y)(s.T,{content:J})}):(0,n.Y)(a.P,{value:J,onValueChange:H.onChange,language:H.language,wordWrap:Y,rootClassName:"flex",gutterClassName:"flex flex-col text-right pl-4 pr-3 select-none text-ink/30 font-mono border-r border-ink/10 bg-canvas sticky left-0 z-10",gutterStyle:{fontSize:b,paddingTop:16,paddingBottom:16,lineHeight:1.5,fontFamily:'"Fira Code", "JetBrains Mono", "SF Mono", Consolas, monospace'},gutterLineClassName:"min-w-[1.5rem]",editorWrapperClassName:`flex-1 code-surface ${Y?"min-w-0":"min-w-max"}`,editorPadding:16,editorClassName:"font-mono focus:outline-none",editorStyle:{fontFamily:'"Fira Code", "JetBrains Mono", "SF Mono", Consolas, monospace',fontSize:b,lineHeight:1.5,minHeight:"100%"}})})]}):(0,n.Y)("div",{className:"flex-1 flex items-center justify-center text-ink/40",children:(0,n.Y)("p",{className:"font-mono text-sm",children:"Select a tab to view content"})})]})}},YOg(e,t,i){let n=(0,i("y").A)({name:"git-compare",size:24,node:[["circle",{cx:"18",cy:"18",r:"3",key:"1xkwt0"}],["circle",{cx:"6",cy:"6",r:"3",key:"1lh9wr"}],["path",{d:"M13 6h3a2 2 0 0 1 2 2v7",key:"1yeb86"}],["path",{d:"M11 18H8a2 2 0 0 1-2-2V9",key:"19pyzm"}]]});i.d(t,{},{A:n})},ES0(e,t,i){let n=(0,i("y").A)({name:"save",size:24,node:[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]});i.d(t,{},{A:n})}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.rspackChunkompchamber=self.rspackChunkompchamber||[]).push([["t"],{Tef(e,r,t){var a=t("I6"),n=t("P0");t("MM"),t("Yr");var l=t("M4"),s=t("Gt"),p=t("Xe"),i=(0,p.sB)().RailroadAbnf.parser.LangiumParser,m=(0,s.K)(e=>{let r=e.alternatives.map(u);return 1===r.length?r[0]:{type:"choice",alternatives:r}},"transformAlternation"),u=(0,s.K)(e=>{let r=e.elements.map(d);return 1===r.length?r[0]:{type:"sequence",elements:r}},"transformConcatenation"),o=(0,s.K)(e=>{if(e.includes("*")){let[r,t]=e.split("*");return{min:r?parseInt(r,10):0,max:t?parseInt(t,10):1/0}}let r=parseInt(e,10);return{min:r,max:r}},"parseRepeat"),d=(0,s.K)(e=>{let r=f(e.primary);if(!e.repeat)return r;let{min:t,max:a}=o(e.repeat);return 0===t&&1===a?{type:"optional",element:r}:{type:"repetition",element:r,min:t,max:a}},"transformElement"),f=(0,s.K)(e=>{switch(e.$type){case"AbnfStringLiteral":case"AbnfNumVal":return{type:"terminal",value:e.value};case"AbnfRuleName":return{type:"nonterminal",name:e.name};case"AbnfGroup":return m(e.element);case"AbnfOptionalGroup":return{type:"optional",element:m(e.element)};default:throw Error(`Unsupported ABNF primary node: ${e.$type}`)}},"transformPrimary"),b=(0,s.K)(e=>({name:e.name,definition:m(e.definition)}),"transformRule"),c=(0,s.K)(e=>{(0,n.S)(e,a.db),e.title&&a.db.setTitle(e.title),e.rules.map(e=>a.db.addRule(b(e)))},"populateDb"),y={parser:{parse:(0,s.K)(e=>{a.db.clear(),l.R.debug("[ABNF Parser] Starting Langium parse");let r=i.parse(e);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new p.zg(r);let t=r.value;l.R.debug("[ABNF Parser] Parsed rules:",t.rules.length),c(t),l.R.debug("[ABNF Parser] Parse complete")},"parse"),parser:{yy:a.db}},db:a.db,renderer:a.U,styles:a.$};t.d(r,{diagram:()=>y})}}]);