@weppy/roblox-mcp 2.4.0 β†’ 2.5.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 (168) hide show
  1. package/.claude-plugin/marketplace.json +2 -2
  2. package/.github/workflows/install-test.yml +2 -21
  3. package/CHANGELOG.md +30 -5
  4. package/COMMERCIAL-LICENSE.md +1 -1
  5. package/README.md +11 -11
  6. package/TRADEMARKS.md +1 -1
  7. package/docs/en/dashboard/changelog.md +1 -1
  8. package/docs/en/dashboard/connection.md +1 -1
  9. package/docs/en/dashboard/overview.md +1 -1
  10. package/docs/en/dashboard/playtest.md +1 -1
  11. package/docs/en/dashboard/settings.md +1 -1
  12. package/docs/en/dashboard/sync.md +1 -1
  13. package/docs/en/dashboard/tools.md +1 -1
  14. package/docs/en/installation/README.md +4 -4
  15. package/docs/en/installation/ai-apps/antigravity.md +1 -1
  16. package/docs/en/installation/ai-apps/claude-app.md +1 -1
  17. package/docs/en/installation/ai-apps/claude-code.md +1 -1
  18. package/docs/en/installation/ai-apps/codex-app.md +1 -1
  19. package/docs/en/installation/ai-apps/codex-cli.md +1 -1
  20. package/docs/en/installation/ai-apps/cursor.md +1 -1
  21. package/docs/en/installation/ai-apps/gemini-cli.md +1 -1
  22. package/docs/en/installation/roblox-explorer.md +12 -12
  23. package/docs/en/installation/roblox-plugin.md +5 -5
  24. package/docs/en/pro-upgrade.md +3 -3
  25. package/docs/en/sync/luau-lsp.md +13 -13
  26. package/docs/en/sync/overview.md +8 -8
  27. package/docs/en/tools/overview.md +1 -1
  28. package/docs/en/tools/playtest.md +2 -2
  29. package/docs/es/README.md +10 -10
  30. package/docs/es/dashboard/changelog.md +1 -1
  31. package/docs/es/dashboard/connection.md +1 -1
  32. package/docs/es/dashboard/overview.md +1 -1
  33. package/docs/es/dashboard/playtest.md +1 -1
  34. package/docs/es/dashboard/settings.md +1 -1
  35. package/docs/es/dashboard/sync.md +1 -1
  36. package/docs/es/dashboard/tools.md +1 -1
  37. package/docs/es/installation/README.md +3 -3
  38. package/docs/es/installation/ai-apps/antigravity.md +1 -1
  39. package/docs/es/installation/ai-apps/claude-app.md +1 -1
  40. package/docs/es/installation/ai-apps/claude-code.md +1 -1
  41. package/docs/es/installation/ai-apps/codex-app.md +1 -1
  42. package/docs/es/installation/ai-apps/codex-cli.md +1 -1
  43. package/docs/es/installation/ai-apps/cursor.md +1 -1
  44. package/docs/es/installation/ai-apps/gemini-cli.md +1 -1
  45. package/docs/es/installation/roblox-explorer.md +11 -11
  46. package/docs/es/installation/roblox-plugin.md +3 -3
  47. package/docs/es/pro-upgrade.md +1 -1
  48. package/docs/es/sync/luau-lsp.md +13 -13
  49. package/docs/es/sync/overview.md +8 -8
  50. package/docs/es/tools/overview.md +1 -1
  51. package/docs/es/tools/playtest.md +2 -2
  52. package/docs/id/README.md +10 -10
  53. package/docs/id/dashboard/changelog.md +1 -1
  54. package/docs/id/dashboard/connection.md +1 -1
  55. package/docs/id/dashboard/overview.md +1 -1
  56. package/docs/id/dashboard/playtest.md +1 -1
  57. package/docs/id/dashboard/settings.md +1 -1
  58. package/docs/id/dashboard/sync.md +1 -1
  59. package/docs/id/dashboard/tools.md +1 -1
  60. package/docs/id/installation/README.md +4 -4
  61. package/docs/id/installation/ai-apps/antigravity.md +1 -1
  62. package/docs/id/installation/ai-apps/claude-app.md +1 -1
  63. package/docs/id/installation/ai-apps/claude-code.md +1 -1
  64. package/docs/id/installation/ai-apps/codex-app.md +1 -1
  65. package/docs/id/installation/ai-apps/codex-cli.md +1 -1
  66. package/docs/id/installation/ai-apps/cursor.md +1 -1
  67. package/docs/id/installation/ai-apps/gemini-cli.md +1 -1
  68. package/docs/id/installation/roblox-explorer.md +11 -11
  69. package/docs/id/installation/roblox-plugin.md +3 -3
  70. package/docs/id/pro-upgrade.md +1 -1
  71. package/docs/id/sync/luau-lsp.md +13 -13
  72. package/docs/id/sync/overview.md +8 -8
  73. package/docs/id/tools/overview.md +1 -1
  74. package/docs/id/tools/playtest.md +2 -2
  75. package/docs/installer/assets/index-Bz0amd7x.js +2 -2
  76. package/docs/installer/index.html +1 -1
  77. package/docs/installer/manifest.webmanifest +3 -3
  78. package/docs/ja/README.md +10 -10
  79. package/docs/ja/installation/README.md +4 -4
  80. package/docs/ja/installation/ai-apps/antigravity.md +1 -1
  81. package/docs/ja/installation/ai-apps/claude-app.md +1 -1
  82. package/docs/ja/installation/ai-apps/claude-code.md +1 -1
  83. package/docs/ja/installation/ai-apps/codex-app.md +1 -1
  84. package/docs/ja/installation/ai-apps/codex-cli.md +1 -1
  85. package/docs/ja/installation/ai-apps/cursor.md +1 -1
  86. package/docs/ja/installation/ai-apps/gemini-cli.md +1 -1
  87. package/docs/ja/installation/roblox-explorer.md +11 -11
  88. package/docs/ja/installation/roblox-plugin.md +3 -3
  89. package/docs/ja/pro-upgrade.md +1 -1
  90. package/docs/ja/sync/luau-lsp.md +13 -13
  91. package/docs/ja/sync/overview.md +8 -8
  92. package/docs/ja/tools/overview.md +1 -1
  93. package/docs/ja/tools/playtest.md +2 -2
  94. package/docs/ko/README.md +10 -10
  95. package/docs/ko/installation/README.md +4 -4
  96. package/docs/ko/installation/ai-apps/antigravity.md +1 -1
  97. package/docs/ko/installation/ai-apps/claude-app.md +1 -1
  98. package/docs/ko/installation/ai-apps/claude-code.md +1 -1
  99. package/docs/ko/installation/ai-apps/codex-app.md +1 -1
  100. package/docs/ko/installation/ai-apps/codex-cli.md +1 -1
  101. package/docs/ko/installation/ai-apps/cursor.md +1 -1
  102. package/docs/ko/installation/ai-apps/gemini-cli.md +1 -1
  103. package/docs/ko/installation/roblox-explorer.md +12 -12
  104. package/docs/ko/installation/roblox-plugin.md +5 -5
  105. package/docs/ko/pro-upgrade.md +1 -1
  106. package/docs/ko/sync/luau-lsp.md +13 -13
  107. package/docs/ko/sync/overview.md +8 -8
  108. package/docs/ko/tools/overview.md +1 -1
  109. package/docs/ko/tools/playtest.md +2 -2
  110. package/docs/pt-br/README.md +11 -11
  111. package/docs/pt-br/dashboard/changelog.md +1 -1
  112. package/docs/pt-br/dashboard/connection.md +1 -1
  113. package/docs/pt-br/dashboard/overview.md +1 -1
  114. package/docs/pt-br/dashboard/playtest.md +1 -1
  115. package/docs/pt-br/dashboard/settings.md +1 -1
  116. package/docs/pt-br/dashboard/sync.md +1 -1
  117. package/docs/pt-br/dashboard/tools.md +1 -1
  118. package/docs/pt-br/installation/README.md +4 -4
  119. package/docs/pt-br/installation/ai-apps/antigravity.md +1 -1
  120. package/docs/pt-br/installation/ai-apps/claude-app.md +1 -1
  121. package/docs/pt-br/installation/ai-apps/claude-code.md +1 -1
  122. package/docs/pt-br/installation/ai-apps/codex-app.md +1 -1
  123. package/docs/pt-br/installation/ai-apps/codex-cli.md +1 -1
  124. package/docs/pt-br/installation/ai-apps/cursor.md +1 -1
  125. package/docs/pt-br/installation/ai-apps/gemini-cli.md +1 -1
  126. package/docs/pt-br/installation/roblox-explorer.md +11 -11
  127. package/docs/pt-br/installation/roblox-plugin.md +3 -3
  128. package/docs/pt-br/pro-upgrade.md +1 -1
  129. package/docs/pt-br/sync/luau-lsp.md +13 -13
  130. package/docs/pt-br/sync/overview.md +8 -8
  131. package/docs/pt-br/tools/overview.md +1 -1
  132. package/docs/pt-br/tools/playtest.md +2 -2
  133. package/docs/troubleshooting.md +1 -1
  134. package/install.ps1 +8 -8
  135. package/install.sh +11 -11
  136. package/llms-full.txt +8 -8
  137. package/llms.txt +4 -4
  138. package/package.json +1 -1
  139. package/plugins/weppy-roblox-mcp/.claude-plugin/plugin.json +1 -1
  140. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{ChangelogDetailPage-CDMDeGei.js β†’ ChangelogDetailPage-DRfFUIvC.js} +1 -1
  141. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{ChangelogPage-Uhx5ND-w.js β†’ ChangelogPage-Dgl8dBt6.js} +1 -1
  142. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{ConfirmModal-BHlbjwL7.js β†’ ConfirmModal-DfdyAPrJ.js} +1 -1
  143. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{ConnectionPage-VXh4Hc9N.js β†’ ConnectionPage-LSvSX1_u.js} +1 -1
  144. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{InfoLabel-CGOLGj5z.js β†’ InfoLabel-DrK7vhO-.js} +1 -1
  145. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{OverviewPage-CWnqw6VH.js β†’ OverviewPage-CXsGuoPu.js} +1 -1
  146. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{PlaytestPage-62dIQkgo.js β†’ PlaytestPage-CgkzRAqQ.js} +2 -2
  147. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{PropertyDiff-DnLJY3ZB.js β†’ PropertyDiff-Dy3MffNh.js} +1 -1
  148. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/SettingsPage-D2ZBQ2KF.js +1 -0
  149. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{StatusBadge-6VL6HJhv.js β†’ StatusBadge-hJyzgRAl.js} +1 -1
  150. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/SyncPage-eX2Rh-Ct.js +4 -0
  151. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{TierComparison-7eRDwSAZ.js β†’ TierComparison-BwKqP_4s.js} +1 -1
  152. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{TierPromoProgress-DFG_858F.js β†’ TierPromoProgress-CLAr1gQq.js} +1 -1
  153. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/ToolsPage-54vIMfZg.css +1 -0
  154. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/ToolsPage-CqzfCxxH.js +1 -0
  155. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{WhatsNewPage-WPfXt13q.js β†’ WhatsNewPage-23o8LmsR.js} +1 -1
  156. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/index-BfvSPSNj.js +207 -0
  157. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/{useLiveUptime-BT-AiWEA.js β†’ useLiveUptime-BeRNzFBh.js} +1 -1
  158. package/plugins/weppy-roblox-mcp/dashboard/dist/index.html +3 -3
  159. package/plugins/weppy-roblox-mcp/dist/index.js +82 -82
  160. package/plugins/weppy-roblox-mcp/roblox-plugin/WeppyRobloxMCP.rbxm +0 -0
  161. package/.github/workflows/deploy-docs.yml +0 -41
  162. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/SettingsPage-Bjr3d4mM.js +0 -1
  163. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/SyncPage-jdplS80I.js +0 -4
  164. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/ToolsPage-B8iwhAW0.css +0 -1
  165. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/ToolsPage-Cc6Vl-VU.js +0 -1
  166. package/plugins/weppy-roblox-mcp/dashboard/dist/assets/index-BhDELp5r.js +0 -143
  167. /package/docs/installer/{wrox-icon.png β†’ weppy-icon.png} +0 -0
  168. /package/plugins/weppy-roblox-mcp/dashboard/dist/{wrox-icon.png β†’ weppy-icon.png} +0 -0
@@ -1 +1 @@
1
- import{j as t,u as $,r as u,d as L,a as D,D as F,T as U}from"./index-BhDELp5r.js";import{I as V}from"./InfoLabel-CGOLGj5z.js";import{S as A}from"./StatusBadge-6VL6HJhv.js";import{D as z,P as O}from"./PropertyDiff-DnLJY3ZB.js";import{u as J,T as X}from"./TierComparison-7eRDwSAZ.js";import{u as q,f as K}from"./useLiveUptime-BT-AiWEA.js";import{T as Q}from"./TierPromoProgress-DFG_858F.js";import"./TierPromo.module-CAoUYgIx.js";const W="_page_1xgxh_2",Y="_card_1xgxh_10",Z="_cardHeader_1xgxh_17",ee="_disconnectCard_1xgxh_28",te="_disconnectIcon_1xgxh_36",se="_disconnectTitle_1xgxh_41",ne="_disconnectMessage_1xgxh_48",ie="_reconnectGuide_1xgxh_55",re="_guideStep_1xgxh_64",ce="_stepNumber_1xgxh_72",ae="_reconnectIndicator_1xgxh_88",oe="_reconnectDot_1xgxh_98",le="_pulse_1xgxh_1",de="_disconnectActions_1xgxh_112",me="_btn_1xgxh_118",xe="_btnSecondary_1xgxh_134",ge="_metricRow_1xgxh_152",he="_metricGrid_1xgxh_158",ue="_metricCard_1xgxh_164",ve="_metric_ok_1xgxh_174",_e="_metric_warn_1xgxh_179",pe="_metric_error_1xgxh_184",fe="_metricHeader_1xgxh_189",Ce="_metricIcon_1xgxh_200",je="_metricTitle_1xgxh_204",we="_metricValue_1xgxh_208",Ne="_metricSubtitle_1xgxh_215",ye="_guideCard_1xgxh_225",Te="_guideTitle_1xgxh_232",Se="_checklist_1xgxh_239",be="_feedEmpty_1xgxh_263",Ie="_feedList_1xgxh_270",ke="_feedItem_1xgxh_278",De="_feedTime_1xgxh_291",Me="_feedIcon_1xgxh_298",Pe="_feedSummary_1xgxh_304",Ee="_feedText_1xgxh_313",Be="_feedContext_1xgxh_321",He="_feedItemClickable_1xgxh_330",Re="_feedChevron_1xgxh_338",$e="_feedDetail_1xgxh_347",Ge="_feedDetailPre_1xgxh_356",Le="_feedDetailText_1xgxh_365",Fe="_changelogSummary_1xgxh_372",Ue="_changeTag_1xgxh_381",Ve="_tierBar_1xgxh_393",Ae="_tierBarTrack_1xgxh_399",ze="_tierBarFillBasic_1xgxh_407",Oe="_tierBarFillPro_1xgxh_412",Je="_tierLabels_1xgxh_417",s={page:W,card:Y,cardHeader:Z,disconnectCard:ee,disconnectIcon:te,disconnectTitle:se,disconnectMessage:ne,reconnectGuide:ie,guideStep:re,stepNumber:ce,reconnectIndicator:ae,reconnectDot:oe,pulse:le,disconnectActions:de,btn:me,btnSecondary:xe,metricRow:ge,metricGrid:he,metricCard:ue,metric_ok:ve,metric_warn:_e,metric_error:pe,metricHeader:fe,metricIcon:Ce,metricTitle:je,metricValue:we,metricSubtitle:Ne,guideCard:ye,guideTitle:Te,checklist:Se,feedEmpty:be,feedList:Ie,feedItem:ke,feedTime:De,feedIcon:Me,feedSummary:Pe,feedText:Ee,feedContext:Be,feedItemClickable:He,feedChevron:Re,feedDetail:$e,feedDetailPre:Ge,feedDetailText:Le,changelogSummary:Fe,changeTag:Ue,tierBar:Ve,tierBarTrack:Ae,tierBarFillBasic:ze,tierBarFillPro:Oe,tierLabels:Je};function N({title:e,value:i,icon:r,subtitle:c,status:a,children:n}){const d=a?s[`metric_${a}`]:"";return t.jsxs("div",{className:`${s.metricCard} ${d}`,children:[t.jsxs("div",{className:s.metricHeader,children:[r&&t.jsx("span",{className:s.metricIcon,children:r}),t.jsx("span",{className:s.metricTitle,children:e})]}),t.jsx("div",{className:s.metricValue,children:i}),c&&t.jsx("div",{className:s.metricSubtitle,children:c}),n]})}function Xe(e){var r,c;const i=e==null?void 0:e.contextSummary;return(i==null?void 0:i.intent)??((c=(r=i==null?void 0:i.affectedAreas)==null?void 0:r[0])==null?void 0:c.label)??(i==null?void 0:i.testScenario)??null}function E({changes:e}){const{t:i}=$(),[r,c]=u.useState(null);return e.length===0?t.jsx("div",{className:s.feedEmpty,children:i("overview.feed.empty")}):t.jsx("div",{className:s.feedList,children:e.map((a,n)=>{const d=r===n,o=a.raw,v=o&&(o.before!=null||o.after!=null||o.details!=null),_=Xe(o);return t.jsxs("div",{children:[t.jsxs("div",{className:`${s.feedItem} ${v?s.feedItemClickable:""}`,onClick:()=>v&&c(d?null:n),children:[t.jsx("span",{className:s.feedTime,children:a.timestamp}),t.jsx("span",{className:s.feedIcon,children:a.icon}),t.jsxs("span",{className:s.feedText,children:[t.jsx("span",{className:s.feedSummary,children:a.summary}),_&&t.jsx("span",{className:s.feedContext,children:_})]}),v&&t.jsx("span",{className:s.feedChevron,children:d?"β–΄":"β–Ύ"})]}),d&&o&&t.jsx("div",{className:s.feedDetail,children:t.jsx(qe,{change:o})})]},n)})})}function qe({change:e}){return e.category==="script"&&(e.before||e.after)?t.jsx(z,{before:e.before,after:e.after}):e.category==="property"?t.jsx(O,{before:e.before,after:e.after}):e.details?t.jsx("pre",{className:s.feedDetailPre,children:JSON.stringify(e.details,null,2)}):t.jsx("div",{className:s.feedDetailText,children:e.target})}const B=20;function G(e){return`${String(e.getHours()).padStart(2,"0")}:${String(e.getMinutes()).padStart(2,"0")}`}function H(){return G(new Date)}function R(e){switch(e){case"script":return"πŸ“";case"instance":return"🧱";case"property":return"🎨";case"lighting":return"πŸ’‘";case"terrain":return"⛰️";case"asset":return"πŸ“¦";default:return"πŸ”§"}}function Ke(){const{level:e,status:i}=L(),r=J(),[c,a]=u.useState(null),[n,d]=u.useState(null),[o,v]=u.useState(null),[_,g]=u.useState([]),y=u.useRef(null),T=u.useCallback(async()=>{try{const l=await D.get("/connection-info");a(l)}catch{a(null)}},[]),S=u.useCallback(async()=>{try{const l=await D.get("/api/dashboard/changelog/active");if(v(l),l.recentChanges&&l.recentChanges.length>0){const p=l.recentChanges.map(h=>({timestamp:h.timestamp?G(new Date(h.timestamp)):H(),icon:R(h.category),summary:h.summary,category:h.category,raw:h}));g(p)}}catch{v(null)}},[]),f=u.useCallback(async()=>{try{const l=await D.get("/sync/status");d(l)}catch{d(null)}},[]);return u.useEffect(()=>{e!=="disconnected"?(T(),S(),f()):(a(null),d(null),v(null));const l=new F;y.current=l,l.connect();const p=l.on("game_change",C=>{const m=C,j={timestamp:H(),icon:R(m.category),summary:m.summary,category:m.category};g(k=>{const w=[j,...k];return w.length>B?w.slice(0,B):w}),S()}),h=l.on("sync",C=>{const m=C;d(j=>({...j,state:m.status,...m.placeId?{placeId:m.placeId}:{}}))});return()=>{p(),h(),l.disconnect(),y.current=null}},[e,T,S,f]),{level:e,status:i,connectionInfo:c,syncStatus:n,changeSummary:o,recentChanges:_,tier:r}}function M(e){return e.scriptsModified+e.scriptsCreated+e.instancesCreated+e.instancesDeleted+e.instancesMoved+e.propertiesChanged+e.assetsInserted+(e.lightingChanged?1:0)+(e.terrainChanged?1:0)}function Qe(e,i){switch(e){case"syncing":return i("status.syncing","Syncing");case"initializing":return i("status.initializing","Initializing");case"error":return i("status.error","Error");default:return i("status.idle","Idle")}}function We(e){switch(e){case"syncing":return"ok";case"initializing":return"warn";case"error":return"error";default:return"ok"}}function I(e,i,r,c){return t.jsxs("div",{className:e.metricSubtitle,children:[t.jsx(V,{label:i,tooltip:r}),": ",c]},i)}function x(e,i){return t.jsx(U,{text:i,children:e})}function ct(){var w,P;const{t:e}=$(),{level:i,status:r,connectionInfo:c,syncStatus:a,changeSummary:n,recentChanges:d,tier:o}=Ke(),v=q(r==null?void 0:r.uptime);if(i==="disconnected")return t.jsx("div",{className:s.page,children:t.jsxs("div",{className:s.disconnectCard,children:[t.jsx("div",{className:s.disconnectIcon,children:"⚠️"}),t.jsx("h2",{className:s.disconnectTitle,children:e("overview.l0.title")}),t.jsx("p",{className:s.disconnectMessage,children:e("overview.l0.message")}),t.jsxs("div",{className:s.reconnectGuide,children:[t.jsxs("div",{className:s.guideStep,children:[t.jsx("span",{className:s.stepNumber,children:"1"}),t.jsx("span",{children:e("overview.l0.step1")})]}),t.jsxs("div",{className:s.guideStep,children:[t.jsx("span",{className:s.stepNumber,children:"2"}),t.jsx("span",{children:e("overview.l0.step2")})]})]}),t.jsxs("div",{className:s.reconnectIndicator,children:[t.jsx("span",{className:s.reconnectDot}),e("overview.l0.reconnecting")]}),t.jsxs("div",{className:s.disconnectActions,children:[t.jsx("button",{className:s.btn,onClick:()=>window.location.reload(),children:e("overview.l0.reconnectBtn")}),t.jsx("button",{className:s.btnSecondary,onClick:()=>{window.location.hash="#/settings"},children:e("overview.l0.settingsBtn")})]})]})});const _=(c==null?void 0:c.mcpInstanceCount)??0,g=((w=c==null?void 0:c.mcpInstances)==null?void 0:w.find(b=>!b.isServer&&b.aiClientName))??((P=c==null?void 0:c.mcpInstances)==null?void 0:P.find(b=>!!b.aiClientName))??null,y=(r==null?void 0:r.pluginClients)??[],T=y.length>0,S=(r==null?void 0:r.sessionId)??(c==null?void 0:c.sessionId)??"-",f=e("overview.metric.server.tooltip","MCP server runtime and process status"),l=e("overview.metric.plugin.tooltip","Roblox Studio plugin connection and version status"),p=e("overview.metric.agent.tooltip","Connected AI coding agents and their runtime state"),h=e("overview.metric.sync.tooltip","Current Studio to local sync activity"),C=r?[I(s,e("overview.meta.version","Version"),e("overview.meta.version.tooltip","Installed MCP server version"),`v${r.version}`),I(s,e("overview.meta.session","Session"),e("overview.meta.session.tooltip","Current MCP session identifier"),S),I(s,e("overview.meta.pid","PID"),e("overview.meta.pid.tooltip","Operating system process identifier"),String(r.pid??"-")),I(s,e("overview.meta.uptime","Uptime"),e("overview.meta.uptime.tooltip","Time elapsed since the MCP server started"),K(v??r.uptime))]:[];if(i==="serverOnly")return t.jsxs("div",{className:s.page,children:[t.jsxs("div",{className:s.metricRow,children:[t.jsx(N,{title:x(e("overview.metric.server"),f),value:x(e("status.online"),f),icon:"πŸ–₯️",status:"ok",children:t.jsxs(t.Fragment,{children:[C,t.jsx(A,{status:"online"})]})}),t.jsx(N,{title:x(e("overview.metric.agent"),p),value:x((g==null?void 0:g.aiClientName)??e("overview.metric.noAgent"),p),icon:"πŸ€–",subtitle:_>1?`${_} ${e("overview.metric.agent.instancesUnit","instances")}`:void 0,status:g?"ok":"warn"})]}),t.jsxs("div",{className:s.guideCard,children:[t.jsx("h3",{className:s.guideTitle,children:e("overview.l1.pluginGuide")}),t.jsxs("ul",{className:s.checklist,children:[t.jsx("li",{children:e("overview.l1.check1")}),t.jsx("li",{children:e("overview.l1.check2")})]})]}),t.jsxs("div",{className:s.card,children:[t.jsx("div",{className:s.cardHeader,children:e("overview.feed.title")}),d.length>0?t.jsx(E,{changes:d}):t.jsx("div",{className:s.feedEmpty,children:e("overview.l1.feedHint")})]}),n&&M(n)>0&&t.jsxs("div",{className:s.card,children:[t.jsx("div",{className:s.cardHeader,children:e("overview.changelog.title")}),t.jsxs("div",{className:s.changelogSummary,children:[t.jsxs("span",{children:[e("overview.changelog.entries","Entries"),": ",M(n)]}),n.scriptsModified>0&&t.jsxs("span",{className:s.changeTag,children:["πŸ“"," ",n.scriptsModified," ",e("overview.changelog.scripts")]}),n.instancesCreated>0&&t.jsxs("span",{className:s.changeTag,children:["🧱"," ",n.instancesCreated," ",e("overview.changelog.instances")]}),n.propertiesChanged>0&&t.jsxs("span",{className:s.changeTag,children:["🎨"," ",n.propertiesChanged," ",e("overview.changelog.properties")]}),n.assetsInserted>0&&t.jsxs("span",{className:s.changeTag,children:["πŸ“¦"," ",n.assetsInserted," ",e("overview.changelog.assets")]})]})]})]});const m=y[0],j=n?M(n):0,k=!!n&&j>0;return t.jsxs("div",{className:s.page,children:[t.jsxs("div",{className:s.metricGrid,children:[t.jsx(N,{title:x(e("overview.metric.server"),f),value:x(e("status.online"),f),icon:"πŸ–₯️",status:"ok",children:t.jsx(t.Fragment,{children:C})}),t.jsx(N,{title:x(e("overview.metric.plugin"),l),value:x(e(T?"status.online":"status.offline"),l),icon:"πŸ”Œ",subtitle:m?`${m.placeName??m.projectName??"-"} / v${m.pluginVersion??"-"}`:void 0,status:T?"ok":"error"}),t.jsx(N,{title:x(e("overview.metric.agent"),p),value:x((g==null?void 0:g.aiClientName)??e("overview.metric.noAgent"),p),icon:"πŸ€–",subtitle:_>1?`${_} ${e("overview.metric.agent.instancesUnit","instances")}`:void 0,status:g?"ok":"warn"}),t.jsx(N,{title:x(e("overview.metric.sync"),h),value:x(Qe(a==null?void 0:a.state,e),h),icon:"πŸ”„",status:We(a==null?void 0:a.state)})]}),t.jsxs("div",{className:s.card,children:[t.jsx("div",{className:s.cardHeader,children:e("overview.feed.title")}),t.jsx(E,{changes:d})]}),k&&t.jsxs("div",{className:s.card,children:[t.jsx("div",{className:s.cardHeader,children:e("overview.changelog.title")}),t.jsxs("div",{className:s.changelogSummary,children:[t.jsxs("span",{children:[e("overview.changelog.entries","Entries"),": ",j]}),n.scriptsModified>0&&t.jsxs("span",{className:s.changeTag,children:["πŸ“"," ",n.scriptsModified," ",e("overview.changelog.scripts")]}),n.instancesCreated>0&&t.jsxs("span",{className:s.changeTag,children:["🧱"," ",n.instancesCreated," ",e("overview.changelog.instances")]}),n.propertiesChanged>0&&t.jsxs("span",{className:s.changeTag,children:["🎨"," ",n.propertiesChanged," ",e("overview.changelog.properties")]}),n.assetsInserted>0&&t.jsxs("span",{className:s.changeTag,children:["πŸ“¦"," ",n.assetsInserted," ",e("overview.changelog.assets")]})]})]}),!o.loading&&o.tier==="basic"&&o.totalCalls>0&&t.jsxs("div",{className:s.card,children:[t.jsx("div",{className:s.cardHeader,children:e("overview.tier.title")}),t.jsx(Q,{basicCalls:o.basicCalls,proCalls:o.proCalls,totalCalls:o.totalCalls,proUsagePercent:o.proUsagePercent,upgradeHref:X.overview})]})]})}export{ct as Component};
1
+ import{j as t,u as $,r as u,d as L,a as D,D as F,T as U}from"./index-BfvSPSNj.js";import{I as V}from"./InfoLabel-DrK7vhO-.js";import{S as A}from"./StatusBadge-hJyzgRAl.js";import{D as z,P as O}from"./PropertyDiff-Dy3MffNh.js";import{u as J,T as X}from"./TierComparison-BwKqP_4s.js";import{u as q,f as K}from"./useLiveUptime-BeRNzFBh.js";import{T as Q}from"./TierPromoProgress-CLAr1gQq.js";import"./TierPromo.module-CAoUYgIx.js";const W="_page_1xgxh_2",Y="_card_1xgxh_10",Z="_cardHeader_1xgxh_17",ee="_disconnectCard_1xgxh_28",te="_disconnectIcon_1xgxh_36",se="_disconnectTitle_1xgxh_41",ne="_disconnectMessage_1xgxh_48",ie="_reconnectGuide_1xgxh_55",re="_guideStep_1xgxh_64",ce="_stepNumber_1xgxh_72",ae="_reconnectIndicator_1xgxh_88",oe="_reconnectDot_1xgxh_98",le="_pulse_1xgxh_1",de="_disconnectActions_1xgxh_112",me="_btn_1xgxh_118",xe="_btnSecondary_1xgxh_134",ge="_metricRow_1xgxh_152",he="_metricGrid_1xgxh_158",ue="_metricCard_1xgxh_164",ve="_metric_ok_1xgxh_174",_e="_metric_warn_1xgxh_179",pe="_metric_error_1xgxh_184",fe="_metricHeader_1xgxh_189",Ce="_metricIcon_1xgxh_200",je="_metricTitle_1xgxh_204",we="_metricValue_1xgxh_208",Ne="_metricSubtitle_1xgxh_215",ye="_guideCard_1xgxh_225",Te="_guideTitle_1xgxh_232",Se="_checklist_1xgxh_239",be="_feedEmpty_1xgxh_263",Ie="_feedList_1xgxh_270",ke="_feedItem_1xgxh_278",De="_feedTime_1xgxh_291",Me="_feedIcon_1xgxh_298",Pe="_feedSummary_1xgxh_304",Ee="_feedText_1xgxh_313",Be="_feedContext_1xgxh_321",He="_feedItemClickable_1xgxh_330",Re="_feedChevron_1xgxh_338",$e="_feedDetail_1xgxh_347",Ge="_feedDetailPre_1xgxh_356",Le="_feedDetailText_1xgxh_365",Fe="_changelogSummary_1xgxh_372",Ue="_changeTag_1xgxh_381",Ve="_tierBar_1xgxh_393",Ae="_tierBarTrack_1xgxh_399",ze="_tierBarFillBasic_1xgxh_407",Oe="_tierBarFillPro_1xgxh_412",Je="_tierLabels_1xgxh_417",s={page:W,card:Y,cardHeader:Z,disconnectCard:ee,disconnectIcon:te,disconnectTitle:se,disconnectMessage:ne,reconnectGuide:ie,guideStep:re,stepNumber:ce,reconnectIndicator:ae,reconnectDot:oe,pulse:le,disconnectActions:de,btn:me,btnSecondary:xe,metricRow:ge,metricGrid:he,metricCard:ue,metric_ok:ve,metric_warn:_e,metric_error:pe,metricHeader:fe,metricIcon:Ce,metricTitle:je,metricValue:we,metricSubtitle:Ne,guideCard:ye,guideTitle:Te,checklist:Se,feedEmpty:be,feedList:Ie,feedItem:ke,feedTime:De,feedIcon:Me,feedSummary:Pe,feedText:Ee,feedContext:Be,feedItemClickable:He,feedChevron:Re,feedDetail:$e,feedDetailPre:Ge,feedDetailText:Le,changelogSummary:Fe,changeTag:Ue,tierBar:Ve,tierBarTrack:Ae,tierBarFillBasic:ze,tierBarFillPro:Oe,tierLabels:Je};function N({title:e,value:i,icon:r,subtitle:c,status:a,children:n}){const d=a?s[`metric_${a}`]:"";return t.jsxs("div",{className:`${s.metricCard} ${d}`,children:[t.jsxs("div",{className:s.metricHeader,children:[r&&t.jsx("span",{className:s.metricIcon,children:r}),t.jsx("span",{className:s.metricTitle,children:e})]}),t.jsx("div",{className:s.metricValue,children:i}),c&&t.jsx("div",{className:s.metricSubtitle,children:c}),n]})}function Xe(e){var r,c;const i=e==null?void 0:e.contextSummary;return(i==null?void 0:i.intent)??((c=(r=i==null?void 0:i.affectedAreas)==null?void 0:r[0])==null?void 0:c.label)??(i==null?void 0:i.testScenario)??null}function E({changes:e}){const{t:i}=$(),[r,c]=u.useState(null);return e.length===0?t.jsx("div",{className:s.feedEmpty,children:i("overview.feed.empty")}):t.jsx("div",{className:s.feedList,children:e.map((a,n)=>{const d=r===n,o=a.raw,v=o&&(o.before!=null||o.after!=null||o.details!=null),_=Xe(o);return t.jsxs("div",{children:[t.jsxs("div",{className:`${s.feedItem} ${v?s.feedItemClickable:""}`,onClick:()=>v&&c(d?null:n),children:[t.jsx("span",{className:s.feedTime,children:a.timestamp}),t.jsx("span",{className:s.feedIcon,children:a.icon}),t.jsxs("span",{className:s.feedText,children:[t.jsx("span",{className:s.feedSummary,children:a.summary}),_&&t.jsx("span",{className:s.feedContext,children:_})]}),v&&t.jsx("span",{className:s.feedChevron,children:d?"β–΄":"β–Ύ"})]}),d&&o&&t.jsx("div",{className:s.feedDetail,children:t.jsx(qe,{change:o})})]},n)})})}function qe({change:e}){return e.category==="script"&&(e.before||e.after)?t.jsx(z,{before:e.before,after:e.after}):e.category==="property"?t.jsx(O,{before:e.before,after:e.after}):e.details?t.jsx("pre",{className:s.feedDetailPre,children:JSON.stringify(e.details,null,2)}):t.jsx("div",{className:s.feedDetailText,children:e.target})}const B=20;function G(e){return`${String(e.getHours()).padStart(2,"0")}:${String(e.getMinutes()).padStart(2,"0")}`}function H(){return G(new Date)}function R(e){switch(e){case"script":return"πŸ“";case"instance":return"🧱";case"property":return"🎨";case"lighting":return"πŸ’‘";case"terrain":return"⛰️";case"asset":return"πŸ“¦";default:return"πŸ”§"}}function Ke(){const{level:e,status:i}=L(),r=J(),[c,a]=u.useState(null),[n,d]=u.useState(null),[o,v]=u.useState(null),[_,g]=u.useState([]),y=u.useRef(null),T=u.useCallback(async()=>{try{const l=await D.get("/connection-info");a(l)}catch{a(null)}},[]),S=u.useCallback(async()=>{try{const l=await D.get("/api/dashboard/changelog/active");if(v(l),l.recentChanges&&l.recentChanges.length>0){const p=l.recentChanges.map(h=>({timestamp:h.timestamp?G(new Date(h.timestamp)):H(),icon:R(h.category),summary:h.summary,category:h.category,raw:h}));g(p)}}catch{v(null)}},[]),f=u.useCallback(async()=>{try{const l=await D.get("/sync/status");d(l)}catch{d(null)}},[]);return u.useEffect(()=>{e!=="disconnected"?(T(),S(),f()):(a(null),d(null),v(null));const l=new F;y.current=l,l.connect();const p=l.on("game_change",C=>{const m=C,j={timestamp:H(),icon:R(m.category),summary:m.summary,category:m.category};g(k=>{const w=[j,...k];return w.length>B?w.slice(0,B):w}),S()}),h=l.on("sync",C=>{const m=C;d(j=>({...j,state:m.status,...m.placeId?{placeId:m.placeId}:{}}))});return()=>{p(),h(),l.disconnect(),y.current=null}},[e,T,S,f]),{level:e,status:i,connectionInfo:c,syncStatus:n,changeSummary:o,recentChanges:_,tier:r}}function M(e){return e.scriptsModified+e.scriptsCreated+e.instancesCreated+e.instancesDeleted+e.instancesMoved+e.propertiesChanged+e.assetsInserted+(e.lightingChanged?1:0)+(e.terrainChanged?1:0)}function Qe(e,i){switch(e){case"syncing":return i("status.syncing","Syncing");case"initializing":return i("status.initializing","Initializing");case"error":return i("status.error","Error");default:return i("status.idle","Idle")}}function We(e){switch(e){case"syncing":return"ok";case"initializing":return"warn";case"error":return"error";default:return"ok"}}function I(e,i,r,c){return t.jsxs("div",{className:e.metricSubtitle,children:[t.jsx(V,{label:i,tooltip:r}),": ",c]},i)}function x(e,i){return t.jsx(U,{text:i,children:e})}function ct(){var w,P;const{t:e}=$(),{level:i,status:r,connectionInfo:c,syncStatus:a,changeSummary:n,recentChanges:d,tier:o}=Ke(),v=q(r==null?void 0:r.uptime);if(i==="disconnected")return t.jsx("div",{className:s.page,children:t.jsxs("div",{className:s.disconnectCard,children:[t.jsx("div",{className:s.disconnectIcon,children:"⚠️"}),t.jsx("h2",{className:s.disconnectTitle,children:e("overview.l0.title")}),t.jsx("p",{className:s.disconnectMessage,children:e("overview.l0.message")}),t.jsxs("div",{className:s.reconnectGuide,children:[t.jsxs("div",{className:s.guideStep,children:[t.jsx("span",{className:s.stepNumber,children:"1"}),t.jsx("span",{children:e("overview.l0.step1")})]}),t.jsxs("div",{className:s.guideStep,children:[t.jsx("span",{className:s.stepNumber,children:"2"}),t.jsx("span",{children:e("overview.l0.step2")})]})]}),t.jsxs("div",{className:s.reconnectIndicator,children:[t.jsx("span",{className:s.reconnectDot}),e("overview.l0.reconnecting")]}),t.jsxs("div",{className:s.disconnectActions,children:[t.jsx("button",{className:s.btn,onClick:()=>window.location.reload(),children:e("overview.l0.reconnectBtn")}),t.jsx("button",{className:s.btnSecondary,onClick:()=>{window.location.hash="#/settings"},children:e("overview.l0.settingsBtn")})]})]})});const _=(c==null?void 0:c.mcpInstanceCount)??0,g=((w=c==null?void 0:c.mcpInstances)==null?void 0:w.find(b=>!b.isServer&&b.aiClientName))??((P=c==null?void 0:c.mcpInstances)==null?void 0:P.find(b=>!!b.aiClientName))??null,y=(r==null?void 0:r.pluginClients)??[],T=y.length>0,S=(r==null?void 0:r.sessionId)??(c==null?void 0:c.sessionId)??"-",f=e("overview.metric.server.tooltip","MCP server runtime and process status"),l=e("overview.metric.plugin.tooltip","Roblox Studio plugin connection and version status"),p=e("overview.metric.agent.tooltip","Connected AI coding agents and their runtime state"),h=e("overview.metric.sync.tooltip","Current Studio to local sync activity"),C=r?[I(s,e("overview.meta.version","Version"),e("overview.meta.version.tooltip","Installed MCP server version"),`v${r.version}`),I(s,e("overview.meta.session","Session"),e("overview.meta.session.tooltip","Current MCP session identifier"),S),I(s,e("overview.meta.pid","PID"),e("overview.meta.pid.tooltip","Operating system process identifier"),String(r.pid??"-")),I(s,e("overview.meta.uptime","Uptime"),e("overview.meta.uptime.tooltip","Time elapsed since the MCP server started"),K(v??r.uptime))]:[];if(i==="serverOnly")return t.jsxs("div",{className:s.page,children:[t.jsxs("div",{className:s.metricRow,children:[t.jsx(N,{title:x(e("overview.metric.server"),f),value:x(e("status.online"),f),icon:"πŸ–₯️",status:"ok",children:t.jsxs(t.Fragment,{children:[C,t.jsx(A,{status:"online"})]})}),t.jsx(N,{title:x(e("overview.metric.agent"),p),value:x((g==null?void 0:g.aiClientName)??e("overview.metric.noAgent"),p),icon:"πŸ€–",subtitle:_>1?`${_} ${e("overview.metric.agent.instancesUnit","instances")}`:void 0,status:g?"ok":"warn"})]}),t.jsxs("div",{className:s.guideCard,children:[t.jsx("h3",{className:s.guideTitle,children:e("overview.l1.pluginGuide")}),t.jsxs("ul",{className:s.checklist,children:[t.jsx("li",{children:e("overview.l1.check1")}),t.jsx("li",{children:e("overview.l1.check2")})]})]}),t.jsxs("div",{className:s.card,children:[t.jsx("div",{className:s.cardHeader,children:e("overview.feed.title")}),d.length>0?t.jsx(E,{changes:d}):t.jsx("div",{className:s.feedEmpty,children:e("overview.l1.feedHint")})]}),n&&M(n)>0&&t.jsxs("div",{className:s.card,children:[t.jsx("div",{className:s.cardHeader,children:e("overview.changelog.title")}),t.jsxs("div",{className:s.changelogSummary,children:[t.jsxs("span",{children:[e("overview.changelog.entries","Entries"),": ",M(n)]}),n.scriptsModified>0&&t.jsxs("span",{className:s.changeTag,children:["πŸ“"," ",n.scriptsModified," ",e("overview.changelog.scripts")]}),n.instancesCreated>0&&t.jsxs("span",{className:s.changeTag,children:["🧱"," ",n.instancesCreated," ",e("overview.changelog.instances")]}),n.propertiesChanged>0&&t.jsxs("span",{className:s.changeTag,children:["🎨"," ",n.propertiesChanged," ",e("overview.changelog.properties")]}),n.assetsInserted>0&&t.jsxs("span",{className:s.changeTag,children:["πŸ“¦"," ",n.assetsInserted," ",e("overview.changelog.assets")]})]})]})]});const m=y[0],j=n?M(n):0,k=!!n&&j>0;return t.jsxs("div",{className:s.page,children:[t.jsxs("div",{className:s.metricGrid,children:[t.jsx(N,{title:x(e("overview.metric.server"),f),value:x(e("status.online"),f),icon:"πŸ–₯️",status:"ok",children:t.jsx(t.Fragment,{children:C})}),t.jsx(N,{title:x(e("overview.metric.plugin"),l),value:x(e(T?"status.online":"status.offline"),l),icon:"πŸ”Œ",subtitle:m?`${m.placeName??m.projectName??"-"} / v${m.pluginVersion??"-"}`:void 0,status:T?"ok":"error"}),t.jsx(N,{title:x(e("overview.metric.agent"),p),value:x((g==null?void 0:g.aiClientName)??e("overview.metric.noAgent"),p),icon:"πŸ€–",subtitle:_>1?`${_} ${e("overview.metric.agent.instancesUnit","instances")}`:void 0,status:g?"ok":"warn"}),t.jsx(N,{title:x(e("overview.metric.sync"),h),value:x(Qe(a==null?void 0:a.state,e),h),icon:"πŸ”„",status:We(a==null?void 0:a.state)})]}),t.jsxs("div",{className:s.card,children:[t.jsx("div",{className:s.cardHeader,children:e("overview.feed.title")}),t.jsx(E,{changes:d})]}),k&&t.jsxs("div",{className:s.card,children:[t.jsx("div",{className:s.cardHeader,children:e("overview.changelog.title")}),t.jsxs("div",{className:s.changelogSummary,children:[t.jsxs("span",{children:[e("overview.changelog.entries","Entries"),": ",j]}),n.scriptsModified>0&&t.jsxs("span",{className:s.changeTag,children:["πŸ“"," ",n.scriptsModified," ",e("overview.changelog.scripts")]}),n.instancesCreated>0&&t.jsxs("span",{className:s.changeTag,children:["🧱"," ",n.instancesCreated," ",e("overview.changelog.instances")]}),n.propertiesChanged>0&&t.jsxs("span",{className:s.changeTag,children:["🎨"," ",n.propertiesChanged," ",e("overview.changelog.properties")]}),n.assetsInserted>0&&t.jsxs("span",{className:s.changeTag,children:["πŸ“¦"," ",n.assetsInserted," ",e("overview.changelog.assets")]})]})]}),!o.loading&&o.tier==="basic"&&o.totalCalls>0&&t.jsxs("div",{className:s.card,children:[t.jsx("div",{className:s.cardHeader,children:e("overview.tier.title")}),t.jsx(Q,{basicCalls:o.basicCalls,proCalls:o.proCalls,totalCalls:o.totalCalls,proUsagePercent:o.proUsagePercent,upgradeHref:X.overview})]})]})}export{ct as Component};
@@ -1,4 +1,4 @@
1
- import{r as n,a as v,u as S,j as e,T as x,i as A}from"./index-BhDELp5r.js";import{u as H,T as D,D as E,a as U}from"./TierComparison-7eRDwSAZ.js";import{I as R}from"./InfoLabel-CGOLGj5z.js";import{C as $}from"./ConfirmModal-BHlbjwL7.js";const O=5e3;function F(t){const o=(t==null?void 0:t.enabled)??!0,[d,r]=n.useState([]),[a,i]=n.useState(null),[m,l]=n.useState(o),c=n.useRef(null),p=n.useCallback(async()=>{try{const _=await v.get("/api/dashboard/playtest/history");r(_.entries??[])}catch{}},[]),u=n.useCallback(async()=>{if(!o){l(!1);return}await p(),l(!1)},[o,p]),y=n.useCallback(async()=>{o&&(await v.post("/api/dashboard/playtest/history/clear"),r([]),i(null))},[o]),w=n.useCallback(async _=>{if(o)try{const g=await v.get(`/api/dashboard/playtest/report/${_}`);i(g)}catch{i(null)}},[o]);return n.useEffect(()=>{if(!o){l(!1);return}return u(),c.current=setInterval(u,O),()=>{c.current&&clearInterval(c.current)}},[o,u]),{history:d,selectedReport:a,loading:m,loadReport:w,clearHistory:y}}function W(t){const o="2026-03-27T15:26:00.000Z",d={testScenario:t("playtest.sample.context.why","Spawn into the arena, survive the opener, and verify the HUD responds immediately."),expectedBehavior:t("playtest.sample.context.expected","The player spawns safely, the countdown UI appears within one second, and the first wave starts without errors."),observedBehavior:t("playtest.sample.context.observed","Spawn protection held, the HUD updated on time, and wave one completed with no gameplay regressions.")};return{history:[{timestamp:o,testName:t("playtest.sample.history.name","Sample Arena Smoke Test"),mode:"play",status:"passed",durationMs:4820,contextId:"sample_playtest_preview",contextSummary:d}],report:{markdown:t("playtest.sample.report.markdown",`# Sample Arena Smoke Test
1
+ import{r as n,a as v,u as S,j as e,T as x,i as A}from"./index-BfvSPSNj.js";import{u as H,T as D,D as E,a as U}from"./TierComparison-BwKqP_4s.js";import{I as P}from"./InfoLabel-DrK7vhO-.js";import{C as $}from"./ConfirmModal-DfdyAPrJ.js";const O=5e3;function F(t){const o=(t==null?void 0:t.enabled)??!0,[d,r]=n.useState([]),[a,i]=n.useState(null),[m,l]=n.useState(o),c=n.useRef(null),p=n.useCallback(async()=>{try{const _=await v.get("/api/dashboard/playtest/history");r(_.entries??[])}catch{}},[]),u=n.useCallback(async()=>{if(!o){l(!1);return}await p(),l(!1)},[o,p]),y=n.useCallback(async()=>{o&&(await v.post("/api/dashboard/playtest/history/clear"),r([]),i(null))},[o]),w=n.useCallback(async _=>{if(o)try{const g=await v.get(`/api/dashboard/playtest/report/${_}`);i(g)}catch{i(null)}},[o]);return n.useEffect(()=>{if(!o){l(!1);return}return u(),c.current=setInterval(u,O),()=>{c.current&&clearInterval(c.current)}},[o,u]),{history:d,selectedReport:a,loading:m,loadReport:w,clearHistory:y}}function W(t){const o="2026-03-27T15:26:00.000Z",d={testScenario:t("playtest.sample.context.why","Spawn into the arena, survive the opener, and verify the HUD responds immediately."),expectedBehavior:t("playtest.sample.context.expected","The player spawns safely, the countdown UI appears within one second, and the first wave starts without errors."),observedBehavior:t("playtest.sample.context.observed","Spawn protection held, the HUD updated on time, and wave one completed with no gameplay regressions.")};return{history:[{timestamp:o,testName:t("playtest.sample.history.name","Sample Arena Smoke Test"),mode:"play",status:"passed",durationMs:4820,contextId:"sample_playtest_preview",contextSummary:d}],report:{markdown:t("playtest.sample.report.markdown",`# Sample Arena Smoke Test
2
2
 
3
3
  - Spawn flow: PASS
4
4
  - HUD countdown: PASS
@@ -8,4 +8,4 @@ This is a sample preview. Upgrade to Pro to save and review real automated playt
8
8
  [sample] spawn protection active
9
9
  [sample] hud countdown rendered
10
10
  [sample] wave one completed
11
- [sample] preview report finished`),contextId:"sample_playtest_preview",contextSummary:d}}}const V="_page_wjm6d_2",z="_sampleBanner_wjm6d_9",G="_sampleBannerRow_wjm6d_21",X="_sampleBannerMain_wjm6d_28",Y="_sampleBadge_wjm6d_35",Z="_sampleTitle_wjm6d_50",q="_sampleMessage_wjm6d_57",J="_sampleActions_wjm6d_64",K="_primaryAction_wjm6d_72",Q="_secondaryAction_wjm6d_73",ee="_card_wjm6d_109",te="_cardHeader_wjm6d_116",se="_clearButton_wjm6d_128",ae="_statusRow_wjm6d_143",oe="_statusIndicator_wjm6d_150",re="_statusRunning_wjm6d_158",ne="_statusPaused_wjm6d_163",le="_statusNotRunning_wjm6d_167",ie="_statusLabel_wjm6d_171",ce="_statusMeta_wjm6d_178",de="_controlButtons_wjm6d_184",me="_btn_wjm6d_191",pe="_btnPrimary_wjm6d_213",ue="_btnDanger_wjm6d_223",he="_historyList_wjm6d_233",ye="_historyItem_wjm6d_241",_e="_historyItemSelected_wjm6d_260",xe="_historyItemHeader_wjm6d_265",je="_historyIcon_wjm6d_271",we="_historyTimestamp_wjm6d_276",ge="_historyName_wjm6d_283",ve="_historyItemMeta_wjm6d_293",Se="_historyMode_wjm6d_302",fe="_historyDuration_wjm6d_306",be="_historyStatus_wjm6d_310",Ne="_status_passed_wjm6d_317",Ce="_status_failed_wjm6d_321",Le="_status_running_wjm6d_325",Ie="_historyError_wjm6d_329",Re="_historyContext_wjm6d_339",Be="_historyContextLine_wjm6d_348",Pe="_historyContextLabel_wjm6d_354",Te="_reportContainer_wjm6d_363",Me="_reportContextPanel_wjm6d_369",ke="_reportContextRow_wjm6d_379",Ae="_reportContextLabel_wjm6d_387",He="_reportSection_wjm6d_395",De="_reportSectionHeader_wjm6d_401",Ee="_reportMarkdown_wjm6d_413",Ue="_reportLogs_wjm6d_426",$e="_emptyState_wjm6d_441",Oe="_emptyStateTitle_wjm6d_448",Fe="_emptyStateMessage_wjm6d_456",We="_upgradePanel_wjm6d_465",Ve="_upgradePanelIcon_wjm6d_473",ze="_upgradePanelTitle_wjm6d_478",Ge="_upgradePanelDesc_wjm6d_486",Xe="_benefitList_wjm6d_496",Ye="_benefitItem_wjm6d_507",Ze="_upgradeActions_wjm6d_522",s={page:V,sampleBanner:z,sampleBannerRow:G,sampleBannerMain:X,sampleBadge:Y,sampleTitle:Z,sampleMessage:q,sampleActions:J,primaryAction:K,secondaryAction:Q,card:ee,cardHeader:te,clearButton:se,statusRow:ae,statusIndicator:oe,statusRunning:re,statusPaused:ne,statusNotRunning:le,statusLabel:ie,statusMeta:ce,controlButtons:de,btn:me,btnPrimary:pe,btnDanger:ue,historyList:he,historyItem:ye,historyItemSelected:_e,historyItemHeader:xe,historyIcon:je,historyTimestamp:we,historyName:ge,historyItemMeta:ve,historyMode:Se,historyDuration:fe,historyStatus:be,status_passed:Ne,status_failed:Ce,status_running:Le,historyError:Ie,historyContext:Re,historyContextLine:Be,historyContextLabel:Pe,reportContainer:Te,reportContextPanel:Me,reportContextRow:ke,reportContextLabel:Ae,reportSection:He,reportSectionHeader:De,reportMarkdown:Ee,reportLogs:Ue,emptyState:$e,emptyStateTitle:Oe,emptyStateMessage:Fe,upgradePanel:We,upgradePanelIcon:Ve,upgradePanelTitle:ze,upgradePanelDesc:Ge,benefitList:Xe,benefitItem:Ye,upgradeActions:Ze};function j(t){return t.trim().toLowerCase()}function qe(t){switch(j(t)){case"passed":return"βœ…";case"failed":return"❌";case"running":return"⏱";default:return"❓"}}function Je(t,o){switch(j(o)){case"run":return t("playtest.status.mode.run","Run");case"server":return t("playtest.status.mode.server","Server");case"edit":return t("playtest.status.mode.edit","Edit");case"play":return t("playtest.status.mode.play","Play");default:return o}}function Ke(t,o){switch(j(o)){case"passed":return t("playtest.history.status.passed","Passed");case"failed":return t("playtest.history.status.failed","Failed");case"running":return t("playtest.history.status.running","Running");default:return t("playtest.history.status.unknown","Unknown")}}function Qe(t){return t<1e3?`${t}ms`:`${(t/1e3).toFixed(1)}s`}function et({entries:t,onSelect:o,selectedTimestamp:d}){const{t:r}=S();return t.length===0?e.jsx("div",{className:s.emptyState,children:r("playtest.history.empty","No test results yet")}):e.jsx("div",{className:s.historyList,children:t.map(a=>{var m,l,c,p,u,y;const i=a.timestamp===d;return e.jsxs("button",{className:`${s.historyItem} ${i?s.historyItemSelected:""}`,onClick:()=>o(a.timestamp),children:[e.jsxs("div",{className:s.historyItemHeader,children:[e.jsx("span",{className:s.historyIcon,children:qe(a.status)}),e.jsx("span",{className:s.historyTimestamp,children:a.timestamp}),e.jsx("span",{className:s.historyName,children:a.testName})]}),e.jsxs("div",{className:s.historyItemMeta,children:[e.jsx(x,{text:r("playtest.history.mode.tooltip","Playtest mode used for this recorded test run."),children:e.jsxs("span",{className:s.historyMode,children:[r("playtest.history.mode","Mode"),": ",Je(r,a.mode)]})}),e.jsx("span",{className:s.historyDuration,children:Qe(a.durationMs)}),e.jsx(x,{text:r("playtest.history.status.tooltip","Recorded result state for this automated playtest run."),children:e.jsx("span",{className:`${s.historyStatus} ${s[`status_${j(a.status)}`]??""}`,children:Ke(r,a.status)})})]}),a.errorMessage&&e.jsx("div",{className:s.historyError,children:a.errorMessage}),(a.contextId||((m=a.contextSummary)==null?void 0:m.testScenario)||((l=a.contextSummary)==null?void 0:l.expectedBehavior)||((c=a.contextSummary)==null?void 0:c.observedBehavior))&&e.jsxs("div",{className:s.historyContext,children:[a.contextId&&e.jsxs("div",{className:s.historyContextLine,children:[e.jsx("span",{className:s.historyContextLabel,children:r("playtest.context.contextId","Context ID")}),e.jsx("span",{children:a.contextId})]}),((p=a.contextSummary)==null?void 0:p.testScenario)&&e.jsxs("div",{className:s.historyContextLine,children:[e.jsx("span",{className:s.historyContextLabel,children:r("playtest.context.why","Why this test ran")}),e.jsx("span",{children:a.contextSummary.testScenario})]}),((u=a.contextSummary)==null?void 0:u.expectedBehavior)&&e.jsxs("div",{className:s.historyContextLine,children:[e.jsx("span",{className:s.historyContextLabel,children:r("playtest.context.expected","Expected")}),e.jsx("span",{children:a.contextSummary.expectedBehavior})]}),((y=a.contextSummary)==null?void 0:y.observedBehavior)&&e.jsxs("div",{className:s.historyContextLine,children:[e.jsx("span",{className:s.historyContextLabel,children:r("playtest.context.observed","Observed")}),e.jsx("span",{children:a.contextSummary.observedBehavior})]})]})]},a.timestamp)})})}function tt({report:t}){var r,a,i,m,l,c;const{t:o}=S(),d=!!((r=t.contextSummary)!=null&&r.testScenario||(a=t.contextSummary)!=null&&a.expectedBehavior||(i=t.contextSummary)!=null&&i.observedBehavior);return e.jsxs("div",{className:s.reportContainer,children:[d&&e.jsxs("div",{className:s.reportContextPanel,children:[((m=t.contextSummary)==null?void 0:m.testScenario)&&e.jsxs("div",{className:s.reportContextRow,children:[e.jsx("span",{className:s.reportContextLabel,children:o("playtest.context.why","Why this test ran")}),e.jsx("span",{children:t.contextSummary.testScenario})]}),((l=t.contextSummary)==null?void 0:l.expectedBehavior)&&e.jsxs("div",{className:s.reportContextRow,children:[e.jsx("span",{className:s.reportContextLabel,children:o("playtest.context.expected","Expected")}),e.jsx("span",{children:t.contextSummary.expectedBehavior})]}),((c=t.contextSummary)==null?void 0:c.observedBehavior)&&e.jsxs("div",{className:s.reportContextRow,children:[e.jsx("span",{className:s.reportContextLabel,children:o("playtest.context.observed","Observed")}),e.jsx("span",{children:t.contextSummary.observedBehavior})]})]}),t.markdown&&e.jsxs("div",{className:s.reportSection,children:[e.jsx("div",{className:s.reportSectionHeader,children:e.jsx(x,{text:o("playtest.report.content.tooltip","Markdown summary for the selected automated playtest run."),children:e.jsx("span",{children:o("playtest.report.content","Report")})})}),e.jsx("pre",{className:s.reportMarkdown,children:t.markdown})]}),t.logs&&e.jsxs("div",{className:s.reportSection,children:[e.jsx("div",{className:s.reportSectionHeader,children:e.jsx(x,{text:o("playtest.report.logs.tooltip","Execution logs captured for the selected automated playtest run."),children:e.jsx("span",{children:o("playtest.report.logs","Logs")})})}),e.jsx("pre",{className:s.reportLogs,children:t.logs})]}),!t.markdown&&!t.logs&&e.jsx("div",{className:s.emptyState,children:o("playtest.report.empty","No report content available")})]})}function nt(){var L;const{t}=S(),{tier:o,loading:d}=H(),r=!d&&o==="basic",a=F({enabled:!r}),{show:i}=A(),[m,l]=n.useState(null),[c,p]=n.useState(!1),[u,y]=n.useState(!1),[w,_]=n.useState(!1),{history:g,selectedReport:B,loading:P}=a,h=r?W(t):null,f=((L=h==null?void 0:h.history[0])==null?void 0:L.timestamp)??null,b=r?m??f:m,N=(h==null?void 0:h.history)??g,C=h&&b===f?h.report:B,T=r?!1:P,M=I=>{l(I),!r&&a.loadReport(I)},k=async()=>{y(!0);try{await a.clearHistory(),i(t("toast.clearSuccess","Cleared successfully"),"success"),p(!1),l(null)}catch{i(t("toast.clearFailed","Failed to clear data"),"error")}finally{y(!1)}};return e.jsxs("div",{className:s.page,children:[r&&e.jsxs("div",{className:s.sampleBanner,children:[e.jsxs("div",{className:s.sampleBannerRow,children:[e.jsxs("div",{className:s.sampleBannerMain,children:[e.jsx("div",{className:s.sampleBadge,children:t("playtest.sample.badge","Preview of the Pro playtest view")}),e.jsx("div",{className:s.sampleTitle,children:t("playtest.sample.title","You are previewing the report viewer that becomes available after upgrading to Pro.")}),e.jsx("div",{className:s.sampleMessage,children:t("playtest.sample.message","This preview uses sample data. Real playtest history management and stored reports unlock with Pro.")})]}),e.jsxs("div",{className:s.sampleActions,children:[e.jsx("button",{className:s.secondaryAction,onClick:()=>_(!0),children:t("tier.compare","Basic vs Pro")}),e.jsx("a",{className:s.primaryAction,href:D.playtest,target:"_blank",rel:"noreferrer",children:t("tier.upgrade","Upgrade to Pro")})]})]}),e.jsx(E,{variant:"centered"})]}),e.jsxs("div",{className:s.card,children:[e.jsxs("div",{className:s.cardHeader,children:[e.jsx(R,{label:t("playtest.history.title","Test History"),tooltip:t("playtest.history.title.tooltip","Recorded automated playtest runs for this project.")}),r?e.jsx(x,{text:t("playtest.sample.clearDisabled","Upgrade to Pro to clear live playtest history."),children:e.jsx("span",{children:e.jsx("button",{className:s.clearButton,disabled:!0,children:t("common.clear","Clear")})})}):e.jsx("button",{className:s.clearButton,onClick:()=>p(!0),children:t("common.clear","Clear")})]}),T?e.jsx("div",{className:s.emptyState,children:t("common.loading","Loading...")}):N.length===0?e.jsxs("div",{className:s.emptyState,children:[e.jsx("div",{className:s.emptyStateTitle,children:t("playtest.empty.title","No playtest results yet")}),e.jsxs("div",{className:s.emptyStateMessage,children:[t("playtest.empty.message.before","Test results will appear here when the AI agent runs automated tests via")," ",e.jsx(x,{text:t("playtest.empty.runTest.tooltip","WROX Dashboard automation entry point that runs Roblox playtest checks through the system_info tool."),children:e.jsx("span",{children:"system_info.run_test"})}),t("playtest.empty.message.after",".")]})]}):e.jsx(et,{entries:N,onSelect:M,selectedTimestamp:b??void 0})]}),C&&e.jsxs("div",{className:s.card,children:[e.jsx("div",{className:s.cardHeader,children:e.jsx(R,{label:t("playtest.report.title","Selected Report"),tooltip:t("playtest.report.title.tooltip","Detailed output for the currently selected automated playtest run.")})}),e.jsx(tt,{report:C})]}),!r&&e.jsx($,{open:c,title:t("playtest.clear.title","Clear test history?"),message:t("playtest.clear.message","This permanently removes the stored playtest reports for the current place."),cancelLabel:t("common.cancel","Cancel"),confirmLabel:t("common.clear","Clear"),loading:u,onCancel:()=>!u&&p(!1),onConfirm:k}),w&&e.jsx(U,{onClose:()=>_(!1)})]})}export{nt as Component};
11
+ [sample] preview report finished`),contextId:"sample_playtest_preview",contextSummary:d}}}const V="_page_wjm6d_2",Y="_sampleBanner_wjm6d_9",z="_sampleBannerRow_wjm6d_21",G="_sampleBannerMain_wjm6d_28",Z="_sampleBadge_wjm6d_35",q="_sampleTitle_wjm6d_50",J="_sampleMessage_wjm6d_57",K="_sampleActions_wjm6d_64",Q="_primaryAction_wjm6d_72",X="_secondaryAction_wjm6d_73",ee="_card_wjm6d_109",te="_cardHeader_wjm6d_116",se="_clearButton_wjm6d_128",ae="_statusRow_wjm6d_143",oe="_statusIndicator_wjm6d_150",re="_statusRunning_wjm6d_158",ne="_statusPaused_wjm6d_163",le="_statusNotRunning_wjm6d_167",ie="_statusLabel_wjm6d_171",ce="_statusMeta_wjm6d_178",de="_controlButtons_wjm6d_184",me="_btn_wjm6d_191",pe="_btnPrimary_wjm6d_213",ue="_btnDanger_wjm6d_223",he="_historyList_wjm6d_233",ye="_historyItem_wjm6d_241",_e="_historyItemSelected_wjm6d_260",xe="_historyItemHeader_wjm6d_265",je="_historyIcon_wjm6d_271",we="_historyTimestamp_wjm6d_276",ge="_historyName_wjm6d_283",ve="_historyItemMeta_wjm6d_293",Se="_historyMode_wjm6d_302",fe="_historyDuration_wjm6d_306",be="_historyStatus_wjm6d_310",Ne="_status_passed_wjm6d_317",Ce="_status_failed_wjm6d_321",Le="_status_running_wjm6d_325",Ie="_historyError_wjm6d_329",Pe="_historyContext_wjm6d_339",Re="_historyContextLine_wjm6d_348",Be="_historyContextLabel_wjm6d_354",Te="_reportContainer_wjm6d_363",Me="_reportContextPanel_wjm6d_369",ke="_reportContextRow_wjm6d_379",Ae="_reportContextLabel_wjm6d_387",He="_reportSection_wjm6d_395",De="_reportSectionHeader_wjm6d_401",Ee="_reportMarkdown_wjm6d_413",Ue="_reportLogs_wjm6d_426",$e="_emptyState_wjm6d_441",Oe="_emptyStateTitle_wjm6d_448",Fe="_emptyStateMessage_wjm6d_456",We="_upgradePanel_wjm6d_465",Ve="_upgradePanelIcon_wjm6d_473",Ye="_upgradePanelTitle_wjm6d_478",ze="_upgradePanelDesc_wjm6d_486",Ge="_benefitList_wjm6d_496",Ze="_benefitItem_wjm6d_507",qe="_upgradeActions_wjm6d_522",s={page:V,sampleBanner:Y,sampleBannerRow:z,sampleBannerMain:G,sampleBadge:Z,sampleTitle:q,sampleMessage:J,sampleActions:K,primaryAction:Q,secondaryAction:X,card:ee,cardHeader:te,clearButton:se,statusRow:ae,statusIndicator:oe,statusRunning:re,statusPaused:ne,statusNotRunning:le,statusLabel:ie,statusMeta:ce,controlButtons:de,btn:me,btnPrimary:pe,btnDanger:ue,historyList:he,historyItem:ye,historyItemSelected:_e,historyItemHeader:xe,historyIcon:je,historyTimestamp:we,historyName:ge,historyItemMeta:ve,historyMode:Se,historyDuration:fe,historyStatus:be,status_passed:Ne,status_failed:Ce,status_running:Le,historyError:Ie,historyContext:Pe,historyContextLine:Re,historyContextLabel:Be,reportContainer:Te,reportContextPanel:Me,reportContextRow:ke,reportContextLabel:Ae,reportSection:He,reportSectionHeader:De,reportMarkdown:Ee,reportLogs:Ue,emptyState:$e,emptyStateTitle:Oe,emptyStateMessage:Fe,upgradePanel:We,upgradePanelIcon:Ve,upgradePanelTitle:Ye,upgradePanelDesc:ze,benefitList:Ge,benefitItem:Ze,upgradeActions:qe};function j(t){return t.trim().toLowerCase()}function Je(t){switch(j(t)){case"passed":return"βœ…";case"failed":return"❌";case"running":return"⏱";default:return"❓"}}function Ke(t,o){switch(j(o)){case"run":return t("playtest.status.mode.run","Run");case"server":return t("playtest.status.mode.server","Server");case"edit":return t("playtest.status.mode.edit","Edit");case"play":return t("playtest.status.mode.play","Play");default:return o}}function Qe(t,o){switch(j(o)){case"passed":return t("playtest.history.status.passed","Passed");case"failed":return t("playtest.history.status.failed","Failed");case"running":return t("playtest.history.status.running","Running");default:return t("playtest.history.status.unknown","Unknown")}}function Xe(t){return t<1e3?`${t}ms`:`${(t/1e3).toFixed(1)}s`}function et({entries:t,onSelect:o,selectedTimestamp:d}){const{t:r}=S();return t.length===0?e.jsx("div",{className:s.emptyState,children:r("playtest.history.empty","No test results yet")}):e.jsx("div",{className:s.historyList,children:t.map(a=>{var m,l,c,p,u,y;const i=a.timestamp===d;return e.jsxs("button",{className:`${s.historyItem} ${i?s.historyItemSelected:""}`,onClick:()=>o(a.timestamp),children:[e.jsxs("div",{className:s.historyItemHeader,children:[e.jsx("span",{className:s.historyIcon,children:Je(a.status)}),e.jsx("span",{className:s.historyTimestamp,children:a.timestamp}),e.jsx("span",{className:s.historyName,children:a.testName})]}),e.jsxs("div",{className:s.historyItemMeta,children:[e.jsx(x,{text:r("playtest.history.mode.tooltip","Playtest mode used for this recorded test run."),children:e.jsxs("span",{className:s.historyMode,children:[r("playtest.history.mode","Mode"),": ",Ke(r,a.mode)]})}),e.jsx("span",{className:s.historyDuration,children:Xe(a.durationMs)}),e.jsx(x,{text:r("playtest.history.status.tooltip","Recorded result state for this automated playtest run."),children:e.jsx("span",{className:`${s.historyStatus} ${s[`status_${j(a.status)}`]??""}`,children:Qe(r,a.status)})})]}),a.errorMessage&&e.jsx("div",{className:s.historyError,children:a.errorMessage}),(a.contextId||((m=a.contextSummary)==null?void 0:m.testScenario)||((l=a.contextSummary)==null?void 0:l.expectedBehavior)||((c=a.contextSummary)==null?void 0:c.observedBehavior))&&e.jsxs("div",{className:s.historyContext,children:[a.contextId&&e.jsxs("div",{className:s.historyContextLine,children:[e.jsx("span",{className:s.historyContextLabel,children:r("playtest.context.contextId","Context ID")}),e.jsx("span",{children:a.contextId})]}),((p=a.contextSummary)==null?void 0:p.testScenario)&&e.jsxs("div",{className:s.historyContextLine,children:[e.jsx("span",{className:s.historyContextLabel,children:r("playtest.context.why","Why this test ran")}),e.jsx("span",{children:a.contextSummary.testScenario})]}),((u=a.contextSummary)==null?void 0:u.expectedBehavior)&&e.jsxs("div",{className:s.historyContextLine,children:[e.jsx("span",{className:s.historyContextLabel,children:r("playtest.context.expected","Expected")}),e.jsx("span",{children:a.contextSummary.expectedBehavior})]}),((y=a.contextSummary)==null?void 0:y.observedBehavior)&&e.jsxs("div",{className:s.historyContextLine,children:[e.jsx("span",{className:s.historyContextLabel,children:r("playtest.context.observed","Observed")}),e.jsx("span",{children:a.contextSummary.observedBehavior})]})]})]},a.timestamp)})})}function tt({report:t}){var r,a,i,m,l,c;const{t:o}=S(),d=!!((r=t.contextSummary)!=null&&r.testScenario||(a=t.contextSummary)!=null&&a.expectedBehavior||(i=t.contextSummary)!=null&&i.observedBehavior);return e.jsxs("div",{className:s.reportContainer,children:[d&&e.jsxs("div",{className:s.reportContextPanel,children:[((m=t.contextSummary)==null?void 0:m.testScenario)&&e.jsxs("div",{className:s.reportContextRow,children:[e.jsx("span",{className:s.reportContextLabel,children:o("playtest.context.why","Why this test ran")}),e.jsx("span",{children:t.contextSummary.testScenario})]}),((l=t.contextSummary)==null?void 0:l.expectedBehavior)&&e.jsxs("div",{className:s.reportContextRow,children:[e.jsx("span",{className:s.reportContextLabel,children:o("playtest.context.expected","Expected")}),e.jsx("span",{children:t.contextSummary.expectedBehavior})]}),((c=t.contextSummary)==null?void 0:c.observedBehavior)&&e.jsxs("div",{className:s.reportContextRow,children:[e.jsx("span",{className:s.reportContextLabel,children:o("playtest.context.observed","Observed")}),e.jsx("span",{children:t.contextSummary.observedBehavior})]})]}),t.markdown&&e.jsxs("div",{className:s.reportSection,children:[e.jsx("div",{className:s.reportSectionHeader,children:e.jsx(x,{text:o("playtest.report.content.tooltip","Markdown summary for the selected automated playtest run."),children:e.jsx("span",{children:o("playtest.report.content","Report")})})}),e.jsx("pre",{className:s.reportMarkdown,children:t.markdown})]}),t.logs&&e.jsxs("div",{className:s.reportSection,children:[e.jsx("div",{className:s.reportSectionHeader,children:e.jsx(x,{text:o("playtest.report.logs.tooltip","Execution logs captured for the selected automated playtest run."),children:e.jsx("span",{children:o("playtest.report.logs","Logs")})})}),e.jsx("pre",{className:s.reportLogs,children:t.logs})]}),!t.markdown&&!t.logs&&e.jsx("div",{className:s.emptyState,children:o("playtest.report.empty","No report content available")})]})}function nt(){var L;const{t}=S(),{tier:o,loading:d}=H(),r=!d&&o==="basic",a=F({enabled:!r}),{show:i}=A(),[m,l]=n.useState(null),[c,p]=n.useState(!1),[u,y]=n.useState(!1),[w,_]=n.useState(!1),{history:g,selectedReport:R,loading:B}=a,h=r?W(t):null,f=((L=h==null?void 0:h.history[0])==null?void 0:L.timestamp)??null,b=r?m??f:m,N=(h==null?void 0:h.history)??g,C=h&&b===f?h.report:R,T=r?!1:B,M=I=>{l(I),!r&&a.loadReport(I)},k=async()=>{y(!0);try{await a.clearHistory(),i(t("toast.clearSuccess","Cleared successfully"),"success"),p(!1),l(null)}catch{i(t("toast.clearFailed","Failed to clear data"),"error")}finally{y(!1)}};return e.jsxs("div",{className:s.page,children:[r&&e.jsxs("div",{className:s.sampleBanner,children:[e.jsxs("div",{className:s.sampleBannerRow,children:[e.jsxs("div",{className:s.sampleBannerMain,children:[e.jsx("div",{className:s.sampleBadge,children:t("playtest.sample.badge","Preview of the Pro playtest view")}),e.jsx("div",{className:s.sampleTitle,children:t("playtest.sample.title","You are previewing the report viewer that becomes available after upgrading to Pro.")}),e.jsx("div",{className:s.sampleMessage,children:t("playtest.sample.message","This preview uses sample data. Real playtest history management and stored reports unlock with Pro.")})]}),e.jsxs("div",{className:s.sampleActions,children:[e.jsx("button",{className:s.secondaryAction,onClick:()=>_(!0),children:t("tier.compare","Basic vs Pro")}),e.jsx("a",{className:s.primaryAction,href:D.playtest,target:"_blank",rel:"noreferrer",children:t("tier.upgrade","Upgrade to Pro")})]})]}),e.jsx(E,{variant:"centered"})]}),e.jsxs("div",{className:s.card,children:[e.jsxs("div",{className:s.cardHeader,children:[e.jsx(P,{label:t("playtest.history.title","Test History"),tooltip:t("playtest.history.title.tooltip","Recorded automated playtest runs for this project.")}),r?e.jsx(x,{text:t("playtest.sample.clearDisabled","Upgrade to Pro to clear live playtest history."),children:e.jsx("span",{children:e.jsx("button",{className:s.clearButton,disabled:!0,children:t("common.clear","Clear")})})}):e.jsx("button",{className:s.clearButton,onClick:()=>p(!0),children:t("common.clear","Clear")})]}),T?e.jsx("div",{className:s.emptyState,children:t("common.loading","Loading...")}):N.length===0?e.jsxs("div",{className:s.emptyState,children:[e.jsx("div",{className:s.emptyStateTitle,children:t("playtest.empty.title","No playtest results yet")}),e.jsxs("div",{className:s.emptyStateMessage,children:[t("playtest.empty.message.before","Test results will appear here when the AI agent runs automated tests via")," ",e.jsx(x,{text:t("playtest.empty.runTest.tooltip","WEPPY Dashboard automation entry point that runs Roblox playtest checks through the system_info tool."),children:e.jsx("span",{children:"system_info.run_test"})}),t("playtest.empty.message.after",".")]})]}):e.jsx(et,{entries:N,onSelect:M,selectedTimestamp:b??void 0})]}),C&&e.jsxs("div",{className:s.card,children:[e.jsx("div",{className:s.cardHeader,children:e.jsx(P,{label:t("playtest.report.title","Selected Report"),tooltip:t("playtest.report.title.tooltip","Detailed output for the currently selected automated playtest run.")})}),e.jsx(tt,{report:C})]}),!r&&e.jsx($,{open:c,title:t("playtest.clear.title","Clear test history?"),message:t("playtest.clear.message","This permanently removes the stored playtest reports for the current place."),cancelLabel:t("common.cancel","Cancel"),confirmLabel:t("common.clear","Clear"),loading:u,onCancel:()=>!u&&p(!1),onConfirm:k}),w&&e.jsx(U,{onClose:()=>_(!1)})]})}export{nt as Component};
@@ -1,4 +1,4 @@
1
- import{u as p,r as _,j as n}from"./index-BhDELp5r.js";const N="_container_uv8oc_2",x="_header_uv8oc_10",v="_modeBtn_uv8oc_18",j="_modeBtnActive_uv8oc_33",y="_unifiedView_uv8oc_40",g="_diffLine_uv8oc_46",C="_lineNum_uv8oc_55",B="_lineContent_uv8oc_64",V="_lineAdded_uv8oc_68",w="_lineRemoved_uv8oc_73",L="_lineContext_uv8oc_78",$="_sideBySide_uv8oc_83",b="_sidePane_uv8oc_90",A="_sideLabel_uv8oc_100",S="_sideContent_uv8oc_112",P="_empty_uv8oc_117",e={container:N,header:x,modeBtn:v,modeBtnActive:j,unifiedView:y,diffLine:g,lineNum:C,lineContent:B,lineAdded:V,lineRemoved:w,lineContext:L,sideBySide:$,sidePane:b,sideLabel:A,sideContent:S,empty:P};function R(i,a){const t=i.split(`
1
+ import{u as p,r as _,j as n}from"./index-BfvSPSNj.js";const N="_container_uv8oc_2",x="_header_uv8oc_10",v="_modeBtn_uv8oc_18",j="_modeBtnActive_uv8oc_33",y="_unifiedView_uv8oc_40",g="_diffLine_uv8oc_46",C="_lineNum_uv8oc_55",B="_lineContent_uv8oc_64",V="_lineAdded_uv8oc_68",w="_lineRemoved_uv8oc_73",L="_lineContext_uv8oc_78",$="_sideBySide_uv8oc_83",b="_sidePane_uv8oc_90",A="_sideLabel_uv8oc_100",S="_sideContent_uv8oc_112",P="_empty_uv8oc_117",e={container:N,header:x,modeBtn:v,modeBtnActive:j,unifiedView:y,diffLine:g,lineNum:C,lineContent:B,lineAdded:V,lineRemoved:w,lineContext:L,sideBySide:$,sidePane:b,sideLabel:A,sideContent:S,empty:P};function R(i,a){const t=i.split(`
2
2
  `),d=a.split(`
3
3
  `),o=[],u=Math.max(t.length,d.length);let s=0,l=0;for(;(s<t.length||l<d.length)&&(s<t.length&&l<d.length?t[s]===d[l]?(o.push({type:"context",content:t[s],lineNum:l+1}),s++,l++):(o.push({type:"removed",content:t[s],lineNum:s+1}),s++,s<t.length&&t[s]===d[l]?(o.push({type:"added",content:d[l],lineNum:l+1}),l++):l<d.length&&(o.push({type:"added",content:d[l],lineNum:l+1}),l++)):s<t.length?(o.push({type:"removed",content:t[s],lineNum:s+1}),s++):l<d.length&&(o.push({type:"added",content:d[l],lineNum:l+1}),l++),!(o.length>u*3)););return o}function E({before:i,after:a}){const{t}=p(),[d,o]=_.useState("unified"),u=typeof i=="string"?i:i!=null?JSON.stringify(i,null,2):"",s=typeof a=="string"?a:a!=null?JSON.stringify(a,null,2):"",l=_.useMemo(()=>R(u,s),[u,s]);if(!u&&!s)return n.jsx("div",{className:e.container,children:n.jsx("div",{className:e.empty,children:t("changelog.diff.empty","No diff available")})});if(!u&&s){const c=s.split(`
4
4
  `);return n.jsx("div",{className:e.container,children:n.jsx("div",{className:e.unifiedView,children:c.map((r,h)=>n.jsxs("div",{className:`${e.diffLine} ${e.lineAdded}`,children:[n.jsx("span",{className:e.lineNum,children:h+1}),n.jsxs("span",{className:e.lineContent,children:["+ ",r]})]},h))})})}return n.jsxs("div",{className:e.container,children:[n.jsxs("div",{className:e.header,children:[n.jsx("button",{className:`${e.modeBtn} ${d==="unified"?e.modeBtnActive:""}`,onClick:()=>o("unified"),children:t("changelog.diff.unified","Unified")}),n.jsx("button",{className:`${e.modeBtn} ${d==="side-by-side"?e.modeBtnActive:""}`,onClick:()=>o("side-by-side"),children:t("changelog.diff.sideBySide","Side by Side")})]}),d==="unified"?n.jsx("div",{className:e.unifiedView,children:l.map((c,r)=>n.jsxs("div",{className:`${e.diffLine} ${c.type==="added"?e.lineAdded:c.type==="removed"?e.lineRemoved:e.lineContext}`,children:[n.jsx("span",{className:e.lineNum,children:c.lineNum??""}),n.jsxs("span",{className:e.lineContent,children:[c.type==="added"?"+ ":c.type==="removed"?"- ":" ",c.content]})]},r))}):n.jsxs("div",{className:e.sideBySide,children:[n.jsxs("div",{className:e.sidePane,children:[n.jsx("div",{className:e.sideLabel,children:t("changelog.diff.before","Before")}),n.jsx("div",{className:e.sideContent,children:u.split(`
@@ -0,0 +1 @@
1
+ import{d as w,r,f as z,D as B,e as H,g as O,h as D,a as R,u as M,j as e,T as x,A as $,S as G}from"./index-BfvSPSNj.js";import{I as c}from"./InfoLabel-DrK7vhO-.js";function W(){const{level:t}=w(),[l,L]=r.useState(null),[u,a]=r.useState(null),[S,v]=r.useState(!1),[b,P]=r.useState(!0),[A,_]=r.useState(!1),[k,m]=r.useState(null),g="gumroad",h=t==="disconnected",p=r.useCallback(n=>{n&&a(o=>({...o,...n,maskedKey:n.maskedKey??(o==null?void 0:o.maskedKey),provider:n.provider??(o==null?void 0:o.provider)??g}))},[g]),f=r.useCallback(n=>{if(!n){a(null);return}a({...n,provider:n.provider??g})},[g]),N=r.useCallback(async()=>{try{return await z(g)}catch{return null}},[g]);r.useEffect(()=>{let n=!1;async function o(){try{const[d,T]=await Promise.all([R.get("/api/dashboard/settings").catch(()=>null),N()]);if(n)return;d&&L(d),T&&p(T)}catch{}finally{n||P(!1)}}return o(),()=>{n=!0}},[N,p]),r.useEffect(()=>{const n=new B;n.connect();const o=n.on("license",d=>{N().then(T=>{if(T){if((d==null?void 0:d.cleared)===!0){f(T);return}p(T)}})});return()=>{o(),n.disconnect()}},[N,p,f]);const j=r.useCallback((n,o)=>{m(n??o)},[]),E=r.useCallback(async n=>{if(h)return!1;if(!n.trim())return m("License key is required."),!1;_(!0);try{const o=await H({provider:g,licenseKey:n.trim()});return p(o.license),j(o.message,o.ok?"License updated.":"License activation failed."),o.ok}catch{return m("License activation failed."),!1}finally{_(!1)}},[j,h,g,p]),y=r.useCallback(async()=>{if(!h){_(!0);try{const n=await O({provider:g});p(n.license),j(n.message,n.ok?"License updated.":"License refresh failed.")}catch{m("License refresh failed.")}finally{_(!1)}}},[j,h,g,p]),C=r.useCallback(async()=>{if(!h){_(!0);try{const n=await D({provider:g});f(n.license),j(n.message,n.ok?"License reset.":"License reset failed.")}catch{m("License reset failed.")}finally{_(!1)}}},[j,h,g,f]),i=r.useCallback(async(n,o)=>{if(l){L(d=>d&&{...d,hot:{...d.hot,[n]:o}}),v(!0);try{await R.patch("/api/dashboard/settings",{[n]:o})}catch{L(d=>d&&{...d,hot:{...d.hot,[n]:l.hot[n]}})}finally{v(!1)}}},[l]);return{settings:l,license:u,saving:S,licenseProvider:g,licenseControlsDisabled:h,licenseSubmitting:A,licenseMessage:k,activateLicense:E,refreshLicense:y,resetLicense:C,updateHotSetting:i,loading:b}}const Y="_page_vbvzx_2",F="_card_vbvzx_10",q="_licenseCardPro_vbvzx_17",U="_cardHeader_vbvzx_28",K="_headerBadge_vbvzx_42",V="_headerBadgeLive_vbvzx_53",Q="_licenseGrid_vbvzx_59",X="_statusDot_vbvzx_77",J="_statusActive_vbvzx_86",Z="_statusGrace_vbvzx_91",ee="_statusInactive_vbvzx_96",te="_statusError_vbvzx_100",se="_proBadge_vbvzx_105",ie="_upgradeLink_vbvzx_119",ne="_licenseControls_vbvzx_133",ae="_licenseControlRow_vbvzx_142",le="_licenseField_vbvzx_149",oe="_licenseFieldGrow_vbvzx_155",ce="_controlLabel_vbvzx_160",re="_textInput_vbvzx_166",de="_actionBtn_vbvzx_182",ge="_licenseMessage_vbvzx_204",ue="_licenseNotice_vbvzx_211",he="_licenseNoticeInfo_vbvzx_221",ve="_licenseNoticeWarning_vbvzx_227",pe="_licenseNoticeMuted_vbvzx_233",be="_settingRow_vbvzx_239",xe="_settingLabel_vbvzx_253",_e="_settingControl_vbvzx_260",me="_select_vbvzx_269",je="_numberInput_vbvzx_287",Le="_toggleSwitch_vbvzx_305",fe="_toggleInput_vbvzx_312",Ne="_toggleTrack_vbvzx_320",Ce="_toggleThumb_vbvzx_342",Te="_savedIndicator_vbvzx_391",Pe="_savedIndicatorHidden_vbvzx_402",Ee="_coldGrid_vbvzx_407",ye="_coldHint_vbvzx_425",Se="_langRow_vbvzx_434",Ae="_loading_vbvzx_447",ke="_unit_vbvzx_456",s={page:Y,card:F,licenseCardPro:q,cardHeader:U,headerBadge:K,headerBadgeLive:V,licenseGrid:Q,statusDot:X,statusActive:J,statusGrace:Z,statusInactive:ee,statusError:te,proBadge:se,upgradeLink:ie,licenseControls:ne,licenseControlRow:ae,licenseField:le,licenseFieldGrow:oe,controlLabel:ce,textInput:re,actionBtn:de,licenseMessage:ge,licenseNotice:ue,licenseNoticeInfo:he,licenseNoticeWarning:ve,licenseNoticeMuted:pe,settingRow:be,settingLabel:xe,settingControl:_e,select:me,numberInput:je,toggleSwitch:Le,toggleInput:fe,toggleTrack:Ne,toggleThumb:Ce,savedIndicator:Te,savedIndicatorHidden:Pe,coldGrid:Ee,coldHint:ye,langRow:Se,loading:Ae,unit:ke},Ie={en:"English",ko:"ν•œκ΅­μ–΄",es:"EspaΓ±ol","pt-br":"PortuguΓͺs (BR)",ja:"ζ—₯本θͺž",id:"Bahasa Indonesia"},Re=["debug","info","warn","error"];function we(t){return t==="active"?s.statusActive:t==="grace"?s.statusGrace:t==="invalid"||t==="revoked"?s.statusError:s.statusInactive}function ze(t,l){return t.refreshBlockedReason==="missing_session_token"?{label:l("settings.license.status.activationRequired","Activation Required"),tooltip:l("settings.license.status.activationRequired.tooltip","Manual license activation is required before WEPPY Dashboard can refresh this status."),detail:l("settings.license.detail.missingSessionToken","Refresh is blocked because the current session token is missing."),detailTone:s.licenseNoticeWarning}:t.statusDetail==="active_cancel_pending"?{label:l("settings.license.active","Active"),tooltip:l("settings.license.status.activeCancelPending.tooltip","Cancellation is pending, but Pro access remains active until the current billing period ends."),detail:l("settings.license.detail.cancelPending","Cancellation is scheduled. Pro access remains active until the current billing period ends."),detailTone:s.licenseNoticeInfo}:t.statusDetail==="grace_provider_unavailable"?{label:l("settings.license.status.grace","Grace"),tooltip:l("settings.license.status.grace.tooltip","Provider verification is temporarily unavailable, but Pro access remains active during the grace period."),detail:l("settings.license.detail.graceProviderUnavailable","Provider unavailable. Pro access remains active during grace mode."),detailTone:s.licenseNoticeInfo}:t.statusDetail==="grace_expired"||t.statusDetail==="grace_payment_failed"?{label:l("settings.license.status.grace","Grace"),tooltip:l("settings.license.status.graceBilling.tooltip","Pro access is still available during a billing-related grace period."),detail:l("settings.license.detail.graceBilling","Pro access remains available during a billing grace period."),detailTone:s.licenseNoticeInfo}:{label:l(`settings.license.${t.status}`,t.status),tooltip:l(`settings.license.${t.status}.tooltip`,"Current license activation state."),detail:t.refreshRequired?l("settings.license.detail.refreshRecommended","License verification should be refreshed soon."):null,detailTone:s.licenseNoticeMuted}}function I({checked:t,onChange:l,testId:L,ariaLabel:u}){return e.jsxs("label",{className:s.toggleSwitch,"data-testid":L,children:[e.jsx("input",{type:"checkbox",className:s.toggleInput,checked:t,"aria-label":u,onChange:a=>l(a.target.checked)}),e.jsx("span",{className:s.toggleTrack,"aria-hidden":"true",children:e.jsx("span",{className:s.toggleThumb})})]})}function Oe(){const{t,selectedLocale:l,setLocale:L}=M(),{settings:u,license:a,licenseProvider:S,licenseControlsDisabled:v,licenseSubmitting:b,licenseMessage:P,activateLicense:A,refreshLicense:_,resetLicense:k,updateHotSetting:m,loading:g}=W(),[h,p]=r.useState(null),[f,N]=r.useState(""),j=a?ze(a,t):null,E=(a==null?void 0:a.tier)==="pro",y=(a==null?void 0:a.tier)==="pro"?a.maskedKey:void 0,C=r.useCallback(async(i,n)=>{await m(i,n),p(i),setTimeout(()=>p(o=>o===i?null:o),2e3)},[m]);return g?e.jsx("div",{className:s.page,children:e.jsx("div",{className:s.loading,children:t("common.loading")})}):e.jsxs("div",{className:s.page,children:[e.jsxs("div",{"data-testid":"settings-license-card",className:[s.card,(a==null?void 0:a.tier)==="pro"?s.licenseCardPro:""].filter(Boolean).join(" "),children:[e.jsxs("div",{className:s.cardHeader,children:[e.jsx(c,{label:t("settings.license.title","License"),tooltip:t("settings.license.title.tooltip","Current license status and subscription tier.")}),e.jsx(x,{text:v?t("settings.license.disconnected.tooltip","Reconnect to the MCP server to manage license actions from WEPPY Dashboard."):t("settings.license.live.tooltip","License actions are sent to the MCP server immediately."),children:e.jsx("span",{className:`${s.headerBadge} ${v?"":s.headerBadgeLive}`,children:v?t("settings.license.disconnected","Disconnected"):t("settings.general.liveApply","Live Apply")})})]}),e.jsxs(e.Fragment,{children:[a?e.jsxs(e.Fragment,{children:[(()=>{const i=j;return e.jsxs(e.Fragment,{children:[e.jsxs("dl",{className:s.licenseGrid,children:[e.jsx("dt",{children:e.jsx(c,{label:t("settings.license.status","Status"),tooltip:t("settings.license.status.tooltip","Current license activation state.")})}),e.jsxs("dd",{children:[e.jsx("span",{className:`${s.statusDot} ${we(a.status)}`}),e.jsx(x,{text:(i==null?void 0:i.tooltip)??t(`settings.license.${a.status}.tooltip`,"Current license activation state."),children:(i==null?void 0:i.label)??t(`settings.license.${a.status}`,a.status)})]}),e.jsx("dt",{children:e.jsx(c,{label:t("settings.license.tier","Tier"),tooltip:t("settings.license.tier.tooltip","Current subscription tier for available WEPPY Dashboard features.")})}),e.jsx("dd",{className:a.tier==="pro"?s.proBadge:"",children:e.jsx(x,{text:t(`tier.${a.tier}.tooltip`,"Available feature set for the connected license."),children:a.tier==="pro"?t("tier.pro","Pro"):t("tier.basic","Basic")})}),y&&e.jsxs(e.Fragment,{children:[e.jsx("dt",{children:e.jsx(c,{label:t("settings.license.key","Key"),tooltip:t("settings.license.key.tooltip","Masked license key currently loaded by the server.")})}),e.jsx("dd",{children:e.jsx(x,{text:t("settings.license.keyValue.tooltip","Masked license key currently loaded by the server."),children:y})})]}),a.provider&&e.jsxs(e.Fragment,{children:[e.jsx("dt",{children:e.jsx(c,{label:t("settings.license.provider","Provider"),tooltip:t("settings.license.provider.tooltip","License provider used to validate this key.")})}),e.jsx("dd",{children:e.jsx(x,{text:t("settings.license.providerValue.tooltip","License provider used to validate this key."),children:a.provider})})]})]}),(i==null?void 0:i.detail)&&e.jsx("p",{className:`${s.licenseNotice} ${i.detailTone}`,children:a.refreshBlockedReason==="missing_session_token"?t("settings.license.detail.manualActivation","Manual activation required to restore Pro access."):i.detail}),a.refreshBlockedReason==="missing_session_token"&&e.jsx("p",{className:`${s.licenseNotice} ${s.licenseNoticeMuted}`,children:i==null?void 0:i.detail})]})})(),a.tier==="basic"&&e.jsx("a",{className:s.upgradeLink,href:"https://gum.co/u/din5in7h",target:"_blank",rel:"noopener noreferrer",children:t("tier.upgrade")})]}):e.jsx("div",{className:s.loading,children:t("settings.license.unavailable")}),e.jsxs("div",{className:s.licenseControls,children:[e.jsxs("div",{className:s.licenseControlRow,children:[e.jsxs("label",{className:s.licenseField,children:[e.jsx("span",{className:s.controlLabel,children:e.jsx(c,{label:t("settings.license.provider","Provider"),tooltip:t("settings.license.provider.tooltip","License provider used to validate this key.")})}),e.jsx("select",{"aria-label":t("settings.license.provider","Provider"),className:s.select,value:S,disabled:v||b,onChange:()=>{},children:e.jsx("option",{value:"gumroad",children:"gumroad"})})]}),e.jsx("button",{type:"button",className:s.actionBtn,disabled:v||b||!E,onClick:()=>{_()},children:b?t("common.loading"):t("settings.license.refresh","Refresh License")}),e.jsx("button",{type:"button",className:s.actionBtn,disabled:v||b||!E,onClick:()=>{k()},children:b?t("common.loading"):t("settings.license.reset","Reset License")})]}),e.jsxs("div",{className:s.licenseControlRow,children:[e.jsxs("label",{className:`${s.licenseField} ${s.licenseFieldGrow}`,children:[e.jsx("span",{className:s.controlLabel,children:e.jsx(c,{label:t("settings.license.keyInput","License Key"),tooltip:t("settings.license.key.tooltip","Masked license key currently loaded by the server.")})}),e.jsx("input",{"aria-label":t("settings.license.keyInput","License Key"),className:s.textInput,type:"text",value:f,disabled:v||b,onChange:i=>N(i.target.value)})]}),e.jsx("button",{type:"button",className:s.actionBtn,disabled:v||b,onClick:()=>{(async()=>await A(f)&&N(""))()},children:b?t("common.loading"):t("settings.license.activate","Activate License")})]}),P&&e.jsx("p",{className:s.licenseMessage,children:P})]})]})]}),e.jsxs("div",{className:s.card,children:[e.jsxs("div",{className:s.cardHeader,children:[e.jsx(c,{label:t("settings.general.title","General Settings"),tooltip:t("settings.general.title.tooltip","Hot settings that apply immediately when changed.")}),e.jsx(x,{text:t("settings.general.liveApply.tooltip","Changes in this section are applied immediately without a separate save button."),children:e.jsx("span",{className:`${s.headerBadge} ${s.headerBadgeLive}`,children:t("settings.general.liveApply","Live Apply")})})]}),u?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:s.settingRow,children:[e.jsx("span",{className:s.settingLabel,children:e.jsx(c,{label:t("settings.general.logLevel","Log Level"),tooltip:t("settings.general.logLevel.tooltip","Sets how much detail WEPPY Dashboard writes to its logs.")})}),e.jsxs("div",{className:s.settingControl,children:[e.jsx("select",{className:s.select,value:u.hot.LOG_LEVEL,onChange:i=>C("LOG_LEVEL",i.target.value),children:Re.map(i=>e.jsx("option",{value:i,children:i},i))}),h==="LOG_LEVEL"&&e.jsx("span",{className:s.savedIndicator,children:t("settings.general.applied")})]})]}),e.jsxs("div",{className:s.settingRow,children:[e.jsx("span",{className:s.settingLabel,children:e.jsx(c,{label:t("settings.general.localHistory","Tool History Recording"),tooltip:t("settings.general.localHistory.tooltip","Stores local tool execution history for the WEPPY Dashboard history views.")})}),e.jsxs("div",{className:s.settingControl,children:[e.jsx("span",{className:`${s.savedIndicator} ${h==="ENABLE_LOCAL_HISTORY"?"":s.savedIndicatorHidden}`,children:t("settings.general.applied","Applied")}),e.jsx(I,{checked:u.hot.ENABLE_LOCAL_HISTORY,ariaLabel:t("settings.general.localHistory","Tool History Recording"),testId:"settings-toggle-enable-local-history",onChange:i=>C("ENABLE_LOCAL_HISTORY",i)})]})]}),e.jsxs("div",{className:s.settingRow,children:[e.jsx("span",{className:s.settingLabel,children:e.jsx(c,{label:t("settings.general.localStatistics","Tool Statistics Collection"),tooltip:t("settings.general.localStatistics.tooltip","Aggregates local usage statistics for WEPPY Dashboard reporting.")})}),e.jsxs("div",{className:s.settingControl,children:[e.jsx("span",{className:`${s.savedIndicator} ${h==="ENABLE_LOCAL_STATISTICS"?"":s.savedIndicatorHidden}`,children:t("settings.general.applied","Applied")}),e.jsx(I,{checked:u.hot.ENABLE_LOCAL_STATISTICS,ariaLabel:t("settings.general.localStatistics","Tool Statistics Collection"),testId:"settings-toggle-enable-local-statistics",onChange:i=>C("ENABLE_LOCAL_STATISTICS",i)})]})]}),e.jsxs("div",{className:s.settingRow,children:[e.jsx("span",{className:s.settingLabel,children:e.jsx(c,{label:t("settings.general.contextCapture","Context Capture"),tooltip:t("settings.general.contextCapture.tooltip","When enabled, WEPPY Dashboard records structured execution context for changelog and playtest views.")})}),e.jsxs("div",{className:s.settingControl,children:[e.jsx("span",{className:`${s.savedIndicator} ${h==="ENABLE_CONTEXT_CAPTURE"?"":s.savedIndicatorHidden}`,children:t("settings.general.applied","Applied")}),e.jsx(I,{checked:u.hot.ENABLE_CONTEXT_CAPTURE,ariaLabel:t("settings.general.contextCapture","Context Capture"),testId:"settings-toggle-enable-context-capture",onChange:i=>C("ENABLE_CONTEXT_CAPTURE",i)})]})]}),e.jsxs("div",{className:s.settingRow,children:[e.jsx("span",{className:s.settingLabel,children:e.jsx(c,{label:t("settings.general.requestTimeout","Request Timeout"),tooltip:t("settings.general.requestTimeout.tooltip","Maximum time WEPPY Dashboard waits for a request before it fails.")})}),e.jsxs("div",{className:s.settingControl,children:[e.jsx("input",{type:"number",className:s.numberInput,value:u.hot.REQUEST_TIMEOUT,min:1e3,max:12e4,step:1e3,onChange:i=>{const n=parseInt(i.target.value,10);isNaN(n)||C("REQUEST_TIMEOUT",n)}}),e.jsx(x,{text:t("settings.general.requestTimeout.unit.tooltip","Request timeout is measured in milliseconds."),children:e.jsx("span",{className:s.unit,children:t("settings.general.requestTimeout.unit","ms")})}),h==="REQUEST_TIMEOUT"&&e.jsx("span",{className:s.savedIndicator,children:t("settings.general.applied","Applied")})]})]})]}):e.jsx("div",{className:s.loading,children:t("settings.unavailable")})]}),e.jsxs("div",{className:s.card,children:[e.jsxs("div",{className:s.cardHeader,children:[e.jsx(c,{label:t("settings.cold.title","Server Environment"),tooltip:t("settings.cold.title.tooltip","Read-only server environment values loaded at startup.")}),e.jsx(x,{text:t("settings.readOnly.tooltip","This section shows values that cannot be edited from WEPPY Dashboard."),children:e.jsx("span",{className:s.headerBadge,children:t("settings.readOnly","Read-only")})})]}),u?e.jsxs(e.Fragment,{children:[e.jsxs("dl",{className:s.coldGrid,children:[e.jsx("dt",{children:e.jsx(c,{label:"HTTP_PORT",tooltip:t("settings.cold.httpPort.tooltip","Port number used by the MCP WEPPY Dashboard HTTP server.")})}),e.jsx("dd",{children:u.cold.HTTP_PORT}),e.jsx("dt",{children:e.jsx(c,{label:"HTTP_HOST",tooltip:t("settings.cold.httpHost.tooltip","Host interface that the MCP WEPPY Dashboard HTTP server binds to.")})}),e.jsx("dd",{children:u.cold.HTTP_HOST}),e.jsx("dt",{children:e.jsx(c,{label:"DASHBOARD_AUTO_OPEN",tooltip:t("settings.cold.dashboardAutoOpen.tooltip","Controls whether WEPPY Dashboard opens automatically in the browser when the server starts.")})}),e.jsx("dd",{children:e.jsx(x,{text:t("settings.cold.dashboardAutoOpen.value.tooltip","Current startup behavior for opening WEPPY Dashboard in a browser."),children:String(u.cold.DASHBOARD_AUTO_OPEN)})})]}),e.jsx("p",{className:s.coldHint,children:t("settings.cold.hint","Set via environment variables to change these values.")})]}):e.jsx("div",{className:s.loading,children:t("settings.unavailable")})]}),e.jsxs("div",{className:s.card,children:[e.jsx("div",{className:s.cardHeader,children:e.jsx(c,{label:t("settings.language.title","Language"),tooltip:t("settings.language.title.tooltip","Choose how the WEPPY Dashboard interface text is localized.")})}),e.jsxs("div",{className:s.langRow,children:[e.jsx("label",{children:e.jsx(c,{label:t("settings.language.dashboard","WEPPY Dashboard Language"),tooltip:t("settings.language.dashboard.tooltip","Overrides the WEPPY Dashboard language or follows the system language when set to Auto.")})}),e.jsxs("select",{className:s.select,value:l,onChange:i=>L(i.target.value),children:[e.jsx("option",{value:$,children:t("settings.language.auto","Auto")}),G.map(i=>e.jsx("option",{value:i,children:Ie[i]??i},i))]})]})]})]})}export{Oe as Component};
@@ -1 +1 @@
1
- import{u as o,j as s}from"./index-BhDELp5r.js";const e="_badge_1ucqq_2",c="_dot_1ucqq_12",a="_online_1ucqq_20",l="_offline_1ucqq_25",_="_idle_1ucqq_30",u="_syncing_1ucqq_34",d="_initializing_1ucqq_35",n={badge:e,dot:c,online:a,offline:l,idle:_,syncing:u,initializing:d},g={online:"status.online",offline:"status.offline",idle:"status.idle",syncing:"status.syncing",initializing:"status.initializing"};function f({status:i}){const{t}=o();return s.jsxs("span",{className:n.badge,children:[s.jsx("span",{className:`${n.dot} ${n[i]}`}),t(g[i])]})}export{f as S};
1
+ import{u as o,j as s}from"./index-BfvSPSNj.js";const e="_badge_1ucqq_2",c="_dot_1ucqq_12",a="_online_1ucqq_20",l="_offline_1ucqq_25",_="_idle_1ucqq_30",u="_syncing_1ucqq_34",d="_initializing_1ucqq_35",n={badge:e,dot:c,online:a,offline:l,idle:_,syncing:u,initializing:d},g={online:"status.online",offline:"status.offline",idle:"status.idle",syncing:"status.syncing",initializing:"status.initializing"};function f({status:i}){const{t}=o();return s.jsxs("span",{className:n.badge,children:[s.jsx("span",{className:`${n.dot} ${n[i]}`}),t(g[i])]})}export{f as S};
@@ -0,0 +1,4 @@
1
+ import{r as c,a as C,D as S,u as I,k as R,l as k,j as e,d as L,i as $,T as x,m as A}from"./index-BfvSPSNj.js";import{I as m}from"./InfoLabel-DrK7vhO-.js";import{C as E}from"./ConfirmModal-DfdyAPrJ.js";import{S as O}from"./StatusBadge-hJyzgRAl.js";import{D as B,a as D,u as H,T as M}from"./TierComparison-BwKqP_4s.js";import{t as l}from"./TierPromo.module-CAoUYgIx.js";const F=5e3;function U(){const[t,n]=c.useState(null),[w,p]=c.useState([]),[o,u]=c.useState(!0),[y,f]=c.useState(null),_=c.useRef(null),h=c.useRef(null),r=c.useCallback(async()=>{var d;try{const[i,b]=await Promise.all([C.get("/sync/status"),C.get("/api/dashboard/place-summary")]);n(i);const j=(d=b.places)==null?void 0:d.find(N=>N.isActive);f((j==null?void 0:j.placeDirName)??null)}catch{}},[]),g=c.useCallback(async()=>{try{const d=await C.get("/sync/history",{limit:"30"});p(d.entries??[])}catch{p([])}},[]),s=c.useCallback(async()=>{await Promise.all([r(),g()]),u(!1)},[r,g]),T=c.useCallback(()=>{s()},[s]),P=c.useCallback(async()=>{await C.post("/api/dashboard/sync/history/clear"),p([]),r()},[r]);return c.useEffect(()=>(s(),h.current=setInterval(s,F),()=>{h.current&&clearInterval(h.current)}),[s]),c.useEffect(()=>{const d=new S;_.current=d,d.connect();const i=d.on("sync",()=>{r(),g()});return()=>{i(),d.disconnect(),_.current=null}},[r,g]),{status:t,history:w,loading:o,activePlaceDirName:y,refresh:T,clearHistory:P}}function W({icon:t,title:n,description:w,benefits:p,upgradeLabel:o,upgradeHref:u}){const{t:y}=I(),[f,_]=c.useState(!1),{trackEvent:h}=R(),{pathname:r}=k(),g=r.replace(/^\//,"").split("/")[0]||"overview";return e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:l.panel,children:[t&&e.jsx("div",{className:l.panelIcon,children:t}),e.jsx("div",{className:l.panelTitle,children:n}),e.jsx("div",{className:l.panelDesc,children:w}),e.jsx("ul",{className:l.benefitList,children:p.map(s=>e.jsx("li",{className:l.benefitItem,children:s},s))}),e.jsx("div",{className:l.panelDiscountWrap,children:e.jsx(B,{variant:"centered"})}),e.jsxs("div",{className:l.actions,children:[e.jsx("button",{className:`${l.btn} ${l.btnOutline}`,onClick:()=>{h("dashboard_click_event",{click_target:"tier_compare",placement:"tier_panel",page:g}),_(!0)},children:y("tier.compare","Basic vs Pro")}),e.jsx("a",{className:`${l.btn} ${l.btnPrimary}`,href:u,target:"_blank",rel:"noreferrer",onClick:()=>h("dashboard_click_event",{click_target:"upgrade_cta",placement:"tier_panel",page:g}),children:o})]})]}),f&&e.jsx(D,{onClose:()=>_(!1)})]})}const q="_page_1warw_2",G="_card_1warw_10",z="_cardHeader_1warw_17",Y="_clearButton_1warw_29",V="_statusRow_1warw_39",J="_metaItem_1warw_46",Q="_statusGrid_1warw_52",X="_table_1warw_71",Z="_directionRail_1warw_99",K="_endpointLabel_1warw_105",ee="_optionRail_1warw_109",te="_directionOption_1warw_115",se="_directionOptionActive_1warw_129",ae="_directionOptionInactive_1warw_133",ne="_direction_forward_1warw_139",ie="_direction_bidirectional_1warw_143",ce="_direction_reverse_1warw_147",oe="_lockBadge_1warw_152",re="_proBadge_1warw_160",le="_forwardBadge_1warw_174",de="_logContainer_1warw_187",pe="_logEntry_1warw_194",ue="_logTime_1warw_206",ye="_logType_1warw_212",he="_logTypeWrite_1warw_221",me="_logTypeUpdate_1warw_225",_e="_logTypeDelete_1warw_229",ge="_logTypeIdle_1warw_233",we="_logPath_1warw_237",fe="_logEmpty_1warw_244",xe="_overlay_1warw_251",be="_overlayTitle_1warw_261",je="_overlayMessage_1warw_268",ve="_checklist_1warw_274",Te="_checkItem_1warw_284",Ne="_upgradePanel_1warw_300",Ce="_upgradePanelHeader_1warw_307",Pe="_benefitList_1warw_315",Ie="_benefitItem_1warw_324",Se="_upgradeActions_1warw_339",Re="_btn_1warw_344",ke="_btnPrimary_1warw_361",Le="_disabled_1warw_372",a={page:q,card:G,cardHeader:z,clearButton:Y,statusRow:V,metaItem:J,statusGrid:Q,table:X,directionRail:Z,endpointLabel:K,optionRail:ee,directionOption:te,directionOptionActive:se,directionOptionInactive:ae,direction_forward:ne,direction_bidirectional:ie,direction_reverse:ce,lockBadge:oe,proBadge:re,forwardBadge:le,logContainer:de,logEntry:pe,logTime:ue,logType:ye,logTypeWrite:he,logTypeUpdate:me,logTypeDelete:_e,logTypeIdle:ge,logPath:we,logEmpty:fe,overlay:xe,overlayTitle:be,overlayMessage:je,checklist:ve,checkItem:Te,upgradePanel:Ne,upgradePanelHeader:Ce,benefitList:Pe,benefitItem:Ie,upgradeActions:Se,btn:Re,btnPrimary:ke,disabled:Le},$e=[{key:"forward",symbol:"←"},{key:"bidirectional",symbol:"↔"},{key:"reverse",symbol:"β†’"}];function Ae(t){const n=new Date(t);return`${String(n.getHours()).padStart(2,"0")}:${String(n.getMinutes()).padStart(2,"0")}`}function Ee(t){switch(t){case"write":return a.logTypeWrite;case"update":return a.logTypeUpdate;case"delete":return a.logTypeDelete;default:return a.logTypeIdle}}function Oe(t){switch(t){case"syncing":return"syncing";case"initializing":return"initializing";case"idle":return"idle";default:return"offline"}}function Be(t,n,w,p){const o=t(`sync.directions.cat.${n}`,n.charAt(0).toUpperCase()+n.slice(1)),u=t("sync.directions.endpoint.local","Local"),y=t("sync.directions.endpoint.studio","Studio");switch(w){case"forward":return[`${o}: ${u} <- ${y}`,t("sync.directions.tooltip.forward.body","Studio changes sync to local files only")].join(`
2
+ `);case"bidirectional":return[`${o}: ${u} <-> ${y}`,t("sync.directions.tooltip.bidirectional.body","Two-way sync between Local and Studio"),p?t("sync.directions.tooltip.proRequired","Pro required in Basic tier"):""].filter(Boolean).join(`
3
+ `);case"reverse":return[`${o}: ${u} -> ${y}`,t("sync.directions.tooltip.reverse.body","Push local file changes to Studio"),p?t("sync.directions.tooltip.proRequired","Pro required in Basic tier"):""].filter(Boolean).join(`
4
+ `);default:return o}}const De=["scripts","values","containers","data","services"];function He(t,n){return n==="manual"?t("sync.directions.mode.manual","Manual"):n==="auto"?t("sync.directions.mode.auto","Auto"):"-"}function Me(t,n){return n==="manual"?t("sync.directions.mode.manual.tooltip","Applies sync changes only when you trigger them manually."):n==="auto"?t("sync.directions.mode.auto.tooltip","Applies sync changes automatically when updates arrive."):""}function Fe(t,n){switch(n){case"write":return t("sync.log.type.write","WRITE");case"update":return t("sync.log.type.update","UPDATE");case"delete":return t("sync.log.type.delete","DELETE");default:return t("sync.log.type.idle","IDLE")}}function Ue(t,n){switch(n){case"write":return t("sync.log.type.write.tooltip","A new sync output was written to disk.");case"update":return t("sync.log.type.update.tooltip","An existing synced file or instance was updated.");case"delete":return t("sync.log.type.delete.tooltip","A synced file or instance was removed.");default:return t("sync.log.type.idle.tooltip","A sync event was recorded without a file mutation.")}}function Je(){const{t}=I(),{level:n}=L(),{tier:w,loading:p}=H(),o=U(),{show:u}=$(),[y,f]=c.useState(!1),[_,h]=c.useState(!1),r=!p&&w==="basic";if(n==="disconnected"||n==="serverOnly")return e.jsx("div",{className:a.page,children:e.jsx("div",{className:a.card,children:e.jsxs("div",{className:a.overlay,children:[e.jsx("div",{className:a.overlayTitle,children:t("sync.overlay.title","Roblox Studio plugin required")}),e.jsx("div",{className:a.overlayMessage,children:t("sync.overlay.message","Sync status will be available once the Roblox Studio plugin connects.")}),e.jsxs("ul",{className:a.checklist,children:[e.jsx("li",{className:a.checkItem,children:t("sync.overlay.check1","Is Roblox Studio running?")}),e.jsx("li",{className:a.checkItem,children:t("sync.overlay.check2","Is the WEPPY Plugin installed?")})]})]})})});const s=o.status,T=o.history,P=Oe(s==null?void 0:s.state),d=async()=>{h(!0);try{await o.clearHistory(),u(t("toast.clearSuccess","Cleared successfully"),"success"),f(!1)}catch{u(t("toast.clearFailed","Failed to clear data"),"error")}finally{h(!1)}};return e.jsxs("div",{className:a.page,children:[e.jsxs("div",{className:a.card,children:[e.jsxs("div",{className:a.cardHeader,children:[e.jsx(x,{text:t("sync.status.title.tooltip","Current Studio and local file sync status for this place."),children:t("sync.status.title","Sync Status")}),r&&e.jsx(x,{text:t("sync.status.forwardOnly.tooltip","Basic tier allows Studio to local forward sync only."),children:e.jsx("span",{className:a.forwardBadge,children:t("sync.status.forwardOnly","Forward Only")})})]}),e.jsxs("div",{className:a.statusRow,children:[e.jsx(O,{status:P}),(s==null?void 0:s.placeName)&&e.jsxs("span",{className:a.metaItem,children:[e.jsx(m,{label:t("sync.status.place","Place"),tooltip:t("sync.status.place.tooltip","Connected Roblox place name and place ID.")}),": ",s.placeName,s.placeId?` (${s.placeId})`:""]})]}),e.jsxs("dl",{className:a.statusGrid,children:[(s==null?void 0:s.syncRoot)&&e.jsxs(e.Fragment,{children:[e.jsx("dt",{children:e.jsx(m,{label:t("sync.status.path","Path"),tooltip:t("sync.status.path.tooltip","Local filesystem root currently used for sync output.")})}),e.jsx("dd",{children:s.syncRoot})]}),o.activePlaceDirName&&(s==null?void 0:s.syncRoot)&&e.jsxs(e.Fragment,{children:[e.jsx("dt",{children:e.jsx(m,{label:t("sync.status.placePath","Place Path"),tooltip:t("sync.status.placePath.tooltip","Active place directory where explorer files are synced.")})}),e.jsx("dd",{children:`${s.syncRoot}/${o.activePlaceDirName}/explorer`})]}),(s==null?void 0:s.instanceCount)!=null&&e.jsxs(e.Fragment,{children:[e.jsx("dt",{children:e.jsx(m,{label:t("sync.status.instances","Instances"),tooltip:t("sync.status.instances.tooltip","Total synced Roblox instances tracked in the local mirror.")})}),e.jsx("dd",{children:s.instanceCount})]}),(s==null?void 0:s.scriptCount)!=null&&e.jsxs(e.Fragment,{children:[e.jsx("dt",{children:e.jsx(m,{label:t("sync.status.scripts","Scripts"),tooltip:t("sync.status.scripts.tooltip","Total synced script files currently indexed for this place.")})}),e.jsx("dd",{children:s.scriptCount})]}),(s==null?void 0:s.state)==="syncing"&&e.jsxs(e.Fragment,{children:[e.jsx("dt",{children:e.jsx(m,{label:t("sync.status.state","State"),tooltip:t("sync.status.state.tooltip","Current runtime sync state reported by the server.")})}),e.jsx("dd",{children:t("status.syncing","Syncing")})]})]})]}),(s==null?void 0:s.directions)&&e.jsxs("div",{className:a.card,children:[e.jsx("div",{className:a.cardHeader,children:e.jsx(x,{text:t("sync.directions.title.tooltip","Per-category sync direction and apply behavior between Local and Studio."),children:t("sync.directions.title","Sync Directions")})}),e.jsxs("table",{className:a.table,children:[e.jsx("thead",{children:e.jsxs("tr",{children:[e.jsx("th",{children:e.jsx(m,{label:t("sync.directions.type","Type"),tooltip:t("sync.directions.type.tooltip","Sync category affected by this rule.")})}),e.jsx("th",{children:e.jsx(m,{label:t("sync.directions.direction","Direction"),tooltip:t("sync.directions.direction.tooltip","Whether each category syncs from Studio, to Studio, or both ways.")})}),e.jsx("th",{children:e.jsx(m,{label:t("sync.directions.applyMode","Apply Mode"),tooltip:t("sync.directions.applyMode.tooltip","How incoming sync changes are applied for this category.")})})]})}),e.jsx("tbody",{children:De.map(i=>{var N;const b=s.directions[i],j=(N=s.applyModes)==null?void 0:N[i];return e.jsxs("tr",{children:[e.jsx("td",{children:t(`sync.directions.cat.${i}`,i.charAt(0).toUpperCase()+i.slice(1))}),e.jsx("td",{children:e.jsxs("div",{className:a.directionRail,"aria-label":`${i}-direction-rail`,children:[e.jsx(x,{text:t("sync.directions.endpoint.local.tooltip","Local files on disk are always shown on the left side of the direction rail."),children:e.jsx("span",{className:a.endpointLabel,children:t("sync.directions.endpoint.local","Local")})}),e.jsx("span",{className:a.optionRail,children:$e.map(v=>e.jsx(A,{text:Be(t,i,v.key,r),children:e.jsx("span",{className:`${a.directionOption} ${b===v.key?a.directionOptionActive:a.directionOptionInactive} ${a[`direction_${v.key}`]??""}`,"data-active":b===v.key?"true":"false",children:v.symbol})},v.key))}),e.jsx(x,{text:t("sync.directions.endpoint.studio.tooltip","Roblox Studio is always shown on the right side of the direction rail."),children:e.jsx("span",{className:a.endpointLabel,children:t("sync.directions.endpoint.studio","Studio")})})]})}),e.jsx("td",{children:e.jsx(x,{text:Me(t,j),children:He(t,j)})})]},i)})})]})]}),e.jsxs("div",{className:a.card,children:[e.jsxs("div",{className:a.cardHeader,children:[e.jsx("span",{children:t("sync.log.title","Sync Log")}),e.jsx("button",{className:a.clearButton,onClick:()=>f(!0),children:t("common.clear","Clear")})]}),e.jsx("div",{className:a.logContainer,children:T.length===0?e.jsx("div",{className:a.logEmpty,children:t("sync.log.empty","No sync events yet")}):T.map((i,b)=>e.jsxs("div",{className:a.logEntry,children:[e.jsx("span",{className:a.logTime,children:Ae(i.timestamp)}),e.jsx(x,{text:Ue(t,i.type),children:e.jsx("span",{className:`${a.logType} ${Ee(i.type)}`,children:Fe(t,i.type)})}),e.jsxs("span",{className:a.logPath,children:[i.path,i.details?` β€” ${i.details}`:""]})]},b))})]}),r&&e.jsx(W,{title:t("sync.upgrade.title","Unlock Full Sync with Pro"),description:t("tier.banner.save","Save AI tokens with Pro!"),benefits:[t("sync.upgrade.benefit1","Bidirectional sync β€” edit files, auto-apply to Studio"),t("sync.upgrade.benefit2","Reverse sync β€” push file changes back to Studio"),t("sync.upgrade.benefit3","Full sync history and detailed change log")],upgradeLabel:t("sync.upgrade.buy","Upgrade to Pro"),upgradeHref:M.sync}),e.jsx(E,{open:y,title:t("sync.clear.title","Clear sync log?"),message:t("sync.clear.message","This permanently removes the stored sync log for the current place."),cancelLabel:t("common.cancel","Cancel"),confirmLabel:t("common.clear","Clear"),loading:_,onCancel:()=>!_&&f(!1),onConfirm:d})]})}export{Je as Component};
@@ -1 +1 @@
1
- import{r as o,D as S,a as T,f as R,u as j,j as t}from"./index-BhDELp5r.js";function pe(){const[c,e]=o.useState("basic"),[m,n]=o.useState(0),[p,g]=o.useState(0),[a,i]=o.useState(0),[k,P]=o.useState(!0);o.useEffect(()=>{let _=!1;async function y(){try{return await R("gumroad")}catch{return null}}async function C(){var r,b;try{const[u,d]=await Promise.all([y(),T.get("/api/dashboard/tool-stats").catch(()=>null)]);if(_)return;if(u!=null&&u.tier&&e(u.tier),d!=null&&d.tierSummary){const f=((r=d.tierSummary.basic)==null?void 0:r.totalCalls)??0,x=((b=d.tierSummary.pro)==null?void 0:b.totalCalls)??0;i(f),g(x),n(f+x)}}catch{}finally{_||P(!1)}}C();const h=new S;h.connect();const N=h.on("license",()=>{y().then(r=>{!_&&(r!=null&&r.tier)&&e(r.tier)})});return()=>{_=!0,N(),h.disconnect()}},[]);const w=m>0?p/m*100:0;return{tier:c,proUsagePercent:w,totalCalls:m,proCalls:p,basicCalls:a,loading:k}}const O=[{name:"query_instances",description:"Query Roblox instances: get, children, find child/descendant, wait for child, class info, search by name/class. [PRO] file_tree, project_structure, descendants, ancestors, search by property/tag.",basic:["get","children","find_child","find_descendant","wait_for_child","class_info","search_name","search_class"],pro:["search_property","search_tag","file_tree","project_structure","descendants","ancestors"]},{name:"mutate_instances",description:"Create, delete, clone, move, rename, or pivot instances. [PRO] create_tree, mass_create, mass_delete, mass_duplicate, smart_duplicate.",basic:["create","create_with_props","delete","clone","move","rename","pivot"],pro:["create_tree","mass_create","mass_delete","mass_duplicate","smart_duplicate"]},{name:"manage_properties",description:"Get/set properties, attributes, and tags on instances. [PRO] set_calculated, set_relative, mass_set, mass_get, modify_children.",basic:["get","set","get_all","set_multiple","get_attr","set_attr","get_all_attrs","delete_attr","add_tag","remove_tag","check_tag","get_tags","get_tagged"],pro:["set_calculated","set_relative","mass_set","mass_get","modify_children"]},{name:"manage_scripts",description:"Manage script source code: read, write, create, delete, edit lines, search. [PRO] replace across scripts.",basic:["get_source","set_source","create","delete","edit_replace","edit_insert","edit_delete","search","get_dependencies"],pro:["replace"]},{name:"manage_lighting",description:"[PRO] Configure environment: lighting, atmosphere, sky, terrain properties, time of day.",basic:[],pro:["lighting","atmosphere","sky","terrain_props","time"]},{name:"manage_selection",description:"Get, set, or clear selection. [PRO] context, details, add/remove items, watch changes.",basic:["get","set","clear","cached"],pro:["context","details","add","remove","watch"]},{name:"manage_camera",description:"Camera operations: get info, focus on instance by path or position, get suggested view.",basic:["info","focus_path","focus_position","suggest"],pro:[]},{name:"manage_tween",description:"[PRO] Tween service: create, play, pause, cancel tweens for smooth animations.",basic:[],pro:["create","play","pause","cancel"]},{name:"manage_audio",description:"[PRO] Audio management: play, stop, pause, resume sounds. Set audio listener.",basic:[],pro:["play","stop","pause","resume","set_listener"]},{name:"manage_animation",description:"[PRO] Animation: load, play, stop animations. Get animation tracks from humanoid/controller.",basic:[],pro:["load","play","stop","get_tracks"]},{name:"manage_physics",description:"[PRO] Physics collision groups: register, set collidable between groups, list groups.",basic:[],pro:["register_group","set_collidable","get_groups"]},{name:"manage_effects",description:"[PRO] Particle effects: emit particles, clear all particles, toggle effect enabled state.",basic:[],pro:["emit","clear","toggle"]},{name:"manage_terrain",description:"[PRO] Terrain operations: fill shapes, clear regions, replace materials, manage colors, read/write voxels, generate procedural terrain, smooth terrain.",basic:[],pro:["fill_block","fill_ball","fill_cylinder","fill_wedge","clear_region","clear_bounds","replace_material","colors_get","colors_set","read_voxel","read_voxels","write_voxels","generate","smooth"]},{name:"spatial_query",description:"[PRO] Spatial queries: raycast, find ground, check placement, multi-raycast, scan area, find flat areas, find spawn positions, analyze walkable, spatial map, find empty space, get bounds, snap to grid, check collision.",basic:[],pro:["raycast","find_ground","check_placement","multi_raycast","scan_area","find_flat","find_spawn","analyze_walkable","spatial_map","find_space","bounds","snap_grid","collision"]},{name:"manage_assets",description:"[PRO] Asset management: insert models by ID, get asset info, search creator store, insert free models/packages, export selection.",basic:[],pro:["insert","info","search","search_insert","insert_free","insert_package","export"]},{name:"manage_sync",description:"[PRO] Project sync management: status, history, direction settings, read/write synced files.",basic:[],pro:["status_current_place","history","directions","read_file","write_file","progress"]},{name:"workspace_state",description:"[PRO] Workspace state: full sync, snapshot, recent changes, viewport info, clear history, metadata, scripts, selection info, clear cache.",basic:[],pro:["sync","snapshot","changes","viewport","clear_history","metadata","scripts","selection_info","clear_cache"]},{name:"manage_logs",description:"Output logs: get filtered logs, poll incrementally with sinceSeq cursor, clear buffer, get recent errors.",basic:["get","clear","errors"],pro:[]},{name:"system_info",description:"System info: ping, connection status, usage tier. [PRO] place info, services list, studio settings, playtest control, automated test runner.",basic:["ping","connection","usage"],pro:["place_info","services","studio_settings","play","stop","pause","resume","play_status","run_test"]},{name:"batch_execute",description:'[PRO] Execute multiple commands in a single batch. Each command is an object with "tool" name and "args". Commands execute sequentially; optionally continue on error.',basic:[],pro:["batch_execute"]},{name:"execute_luau",description:"[PRO] Execute arbitrary Luau code in Roblox Studio sandbox. Blocked services: HttpService, DataStoreService, MessagingService. Cannot access CoreGui/CorePackages.",basic:[],pro:["execute_luau"]}],B={proOnlyTools:13,mixedTools:6,totalBasicActions:51,totalProActions:106},L={tools:O,summary:B},A=new Date("2026-04-30T23:59:59");function v(){return Date.now()<=A.getTime()}const _e={overview:"https://gum.co/u/2nc0fhky",changelog:"https://gum.co/u/wjcnucpy",sync:"https://gum.co/u/p0barnlb",playtest:"https://gum.co/u/kchczjry",tools:"https://gum.co/u/ljmteaed"},D="_tag_1wj0q_2",E="_label_1wj0q_17",q="_code_1wj0q_22",G="_expiry_1wj0q_31",M="_inline_1wj0q_49",$="_centered_1wj0q_54",l={tag:D,label:E,code:q,expiry:G,inline:M,centered:$};function W({variant:c}){const{t:e}=j();return v()?t.jsxs("div",{className:`${l.tag} ${c==="centered"?l.centered:l.inline}`,children:[t.jsx("span",{className:l.label,children:e("tier.promo.discount.context","🎁 Gumroad 결제 μ‹œ ν• μΈμ½”λ“œ μž…λ ₯:")}),t.jsx("span",{className:l.code,children:e("tier.comparison.discount.code","WEPPY-MCP")}),t.jsx("span",{className:l.expiry,children:e("tier.comparison.discount.expiry","Valid until April 30")})]}):null}const H="_overlay_171mk_2",I="_modal_171mk_13",U="_summaryGrid_171mk_32",z="_summaryCard_171mk_39",Y="_basicCard_171mk_45",F="_proCard_171mk_49",Q="_cardTitle_171mk_54",V="_summarySection_171mk_70",X="_sectionTitle_171mk_78",J="_featureList_171mk_90",K="_summary_171mk_32",Z="_statBasic_171mk_116",ee="_statPro_171mk_120",te="_statMixed_171mk_124",se="_detailHeader_171mk_128",ae="_tableWrap_171mk_137",ie="_table_171mk_137",re="_toolName_171mk_165",ce="_description_171mk_171",ne="_actionList_171mk_176",oe="_none_171mk_184",le="_discountBanner_171mk_189",me="_closeBtn_171mk_227",s={overlay:H,modal:I,summaryGrid:U,summaryCard:z,basicCard:Y,proCard:F,cardTitle:Q,summarySection:V,sectionTitle:X,featureList:J,summary:K,statBasic:Z,statPro:ee,statMixed:te,detailHeader:se,tableWrap:ae,table:ie,toolName:re,description:ce,actionList:ne,none:oe,discountBanner:le,closeBtn:me};function ue({onClose:c}){const{t:e}=j(),{tools:m,summary:n}=L,p=[{title:e("tier.comparison.basic.core","Core MCP workflow"),items:[e("tier.comparison.basic.core.item1","Script create/edit"),e("tier.comparison.basic.core.item2","Instance management"),e("tier.comparison.basic.core.item3","Property control"),e("tier.comparison.basic.core.item4","Selection and search"),e("tier.comparison.basic.core.item5","Tag management"),e("tier.comparison.basic.core.item6","Camera control"),e("tier.comparison.basic.core.item7","Log monitoring")]},{title:e("tier.comparison.basic.sync","Sync (Basic)"),items:[e("tier.comparison.basic.sync.item1","Studio to Local one-way sync"),e("tier.comparison.basic.sync.item2","Manual apply as default")]}],g=[{title:e("tier.comparison.pro.all","Everything in Basic, plus"),items:[]},{title:e("tier.comparison.pro.sync","Advanced Sync workflow"),items:[e("tier.comparison.pro.sync.item1","Per-type sync direction"),e("tier.comparison.pro.sync.item2","Per-type apply mode"),e("tier.comparison.pro.sync.item3","Bidirectional and reverse sync"),e("tier.comparison.pro.sync.item4","Full sync, resync, and push to Studio"),e("tier.comparison.pro.sync.item5","Multi-place sync")]},{title:e("tier.comparison.pro.playtest","Playtest control"),items:[e("tier.comparison.pro.playtest.item1","Play, stop, pause, and resume"),e("tier.comparison.pro.playtest.item2","Playtest state inspection"),e("tier.comparison.pro.playtest.item3","Automated test execution")]},{title:e("tier.comparison.pro.creation","Advanced creation workflow"),items:[e("tier.comparison.pro.creation.item1","Bulk operations"),e("tier.comparison.pro.creation.item2","Terrain generation"),e("tier.comparison.pro.creation.item3","Asset search and insert"),e("tier.comparison.pro.creation.item4","Raycast and spatial analysis"),e("tier.comparison.pro.creation.item5","Environment control")]}];return t.jsx("div",{className:s.overlay,onClick:c,children:t.jsxs("div",{className:s.modal,onClick:a=>a.stopPropagation(),children:[v()&&t.jsx("div",{className:s.discountBanner,children:t.jsx(W,{variant:"centered"})}),t.jsx("h2",{children:e("tier.compare")}),t.jsxs("div",{className:s.summaryGrid,children:[t.jsxs("section",{className:`${s.summaryCard} ${s.basicCard}`,children:[t.jsx("h3",{className:s.cardTitle,children:e("tier.basic")}),p.map(a=>t.jsxs("div",{className:s.summarySection,children:[t.jsx("div",{className:s.sectionTitle,children:a.title}),t.jsx("ul",{className:s.featureList,children:a.items.map(i=>t.jsx("li",{children:i},i))})]},a.title))]}),t.jsxs("section",{className:`${s.summaryCard} ${s.proCard}`,children:[t.jsx("h3",{className:s.cardTitle,children:e("tier.pro")}),g.map(a=>t.jsxs("div",{className:s.summarySection,children:[t.jsx("div",{className:s.sectionTitle,children:a.title}),a.items.length>0&&t.jsx("ul",{className:s.featureList,children:a.items.map(i=>t.jsx("li",{children:i},i))})]},a.title))]})]}),t.jsxs("div",{className:s.summary,children:[t.jsxs("span",{className:s.statBasic,children:["Basic: ",n.totalBasicActions," actions"]}),t.jsxs("span",{className:s.statPro,children:["Pro: ",n.totalProActions," actions"]}),t.jsxs("span",{className:s.statMixed,children:[n.mixedTools," mixed / ",n.proOnlyTools," pro-only"]})]}),t.jsx("div",{className:s.detailHeader,children:e("tier.comparison.detailTitle","Detailed Tool Catalog")}),t.jsx("div",{className:s.tableWrap,children:t.jsxs("table",{className:s.table,children:[t.jsx("thead",{children:t.jsxs("tr",{children:[t.jsx("th",{children:e("tools.col.tool")}),t.jsx("th",{children:e("tier.comparison.description","Description")}),t.jsx("th",{children:e("tier.basic")}),t.jsx("th",{children:e("tier.pro")})]})}),t.jsx("tbody",{children:m.map(a=>t.jsxs("tr",{children:[t.jsx("td",{className:s.toolName,children:a.name}),t.jsx("td",{className:s.description,children:e(`tier.tool.${a.name}.desc`,a.description)}),t.jsx("td",{className:s.actionList,children:a.basic.length>0?a.basic.join(", "):t.jsx("span",{className:s.none,children:"β€”"})}),t.jsx("td",{className:s.actionList,children:a.pro.length>0?a.pro.join(", "):t.jsx("span",{className:s.none,children:"β€”"})})]},a.name))})]})}),t.jsx("button",{className:s.closeBtn,onClick:c,children:e("tier.comparison.close","Close")})]})})}export{W as D,_e as T,ue as a,pe as u};
1
+ import{r as o,D as S,a as T,f as R,u as j,j as t}from"./index-BfvSPSNj.js";function pe(){const[c,e]=o.useState("basic"),[m,n]=o.useState(0),[p,g]=o.useState(0),[a,i]=o.useState(0),[k,P]=o.useState(!0);o.useEffect(()=>{let _=!1;async function y(){try{return await R("gumroad")}catch{return null}}async function C(){var r,b;try{const[u,d]=await Promise.all([y(),T.get("/api/dashboard/tool-stats").catch(()=>null)]);if(_)return;if(u!=null&&u.tier&&e(u.tier),d!=null&&d.tierSummary){const f=((r=d.tierSummary.basic)==null?void 0:r.totalCalls)??0,x=((b=d.tierSummary.pro)==null?void 0:b.totalCalls)??0;i(f),g(x),n(f+x)}}catch{}finally{_||P(!1)}}C();const h=new S;h.connect();const N=h.on("license",()=>{y().then(r=>{!_&&(r!=null&&r.tier)&&e(r.tier)})});return()=>{_=!0,N(),h.disconnect()}},[]);const w=m>0?p/m*100:0;return{tier:c,proUsagePercent:w,totalCalls:m,proCalls:p,basicCalls:a,loading:k}}const O=[{name:"query_instances",description:"Query Roblox instances: get, children, find child/descendant, wait for child, class info, search by name/class. [PRO] file_tree, project_structure, descendants, ancestors, search by property/tag.",basic:["get","children","find_child","find_descendant","wait_for_child","class_info","search_name","search_class"],pro:["search_property","search_tag","file_tree","project_structure","descendants","ancestors"]},{name:"mutate_instances",description:"Create, delete, clone, move, rename, or pivot instances. [PRO] create_tree, mass_create, mass_delete, mass_duplicate, smart_duplicate.",basic:["create","create_with_props","delete","clone","move","rename","pivot"],pro:["create_tree","mass_create","mass_delete","mass_duplicate","smart_duplicate"]},{name:"manage_properties",description:"Get/set properties, attributes, and tags on instances. [PRO] set_calculated, set_relative, mass_set, mass_get, modify_children.",basic:["get","set","get_all","set_multiple","get_attr","set_attr","get_all_attrs","delete_attr","add_tag","remove_tag","check_tag","get_tags","get_tagged"],pro:["set_calculated","set_relative","mass_set","mass_get","modify_children"]},{name:"manage_scripts",description:"Manage script source code: read, write, create, delete, edit lines, search. [PRO] replace across scripts.",basic:["get_source","set_source","create","delete","edit_replace","edit_insert","edit_delete","search","get_dependencies"],pro:["replace"]},{name:"manage_lighting",description:"[PRO] Configure environment: lighting, atmosphere, sky, terrain properties, time of day.",basic:[],pro:["lighting","atmosphere","sky","terrain_props","time"]},{name:"manage_selection",description:"Get, set, or clear selection. [PRO] context, details, add/remove items, watch changes.",basic:["get","set","clear","cached"],pro:["context","details","add","remove","watch"]},{name:"manage_camera",description:"Camera operations: get info, focus on instance by path or position, get suggested view.",basic:["info","focus_path","focus_position","suggest"],pro:[]},{name:"manage_tween",description:"[PRO] Tween service: create, play, pause, cancel tweens for smooth animations.",basic:[],pro:["create","play","pause","cancel"]},{name:"manage_audio",description:"[PRO] Audio management: play, stop, pause, resume sounds. Set audio listener.",basic:[],pro:["play","stop","pause","resume","set_listener"]},{name:"manage_animation",description:"[PRO] Animation: load, play, stop animations. Get animation tracks from humanoid/controller.",basic:[],pro:["load","play","stop","get_tracks"]},{name:"manage_physics",description:"[PRO] Physics collision groups: register, set collidable between groups, list groups.",basic:[],pro:["register_group","set_collidable","get_groups"]},{name:"manage_effects",description:"[PRO] Particle effects: emit particles, clear all particles, toggle effect enabled state.",basic:[],pro:["emit","clear","toggle"]},{name:"manage_terrain",description:"[PRO] Terrain operations: fill shapes, clear regions, replace materials, manage colors, read/write voxels, generate procedural terrain, smooth terrain.",basic:[],pro:["fill_block","fill_ball","fill_cylinder","fill_wedge","clear_region","clear_bounds","replace_material","colors_get","colors_set","read_voxel","read_voxels","write_voxels","generate","smooth"]},{name:"spatial_query",description:"[PRO] Spatial queries: raycast, find ground, check placement, multi-raycast, scan area, find flat areas, find spawn positions, analyze walkable, spatial map, find empty space, get bounds, snap to grid, check collision.",basic:[],pro:["raycast","find_ground","check_placement","multi_raycast","scan_area","find_flat","find_spawn","analyze_walkable","spatial_map","find_space","bounds","snap_grid","collision"]},{name:"manage_assets",description:"[PRO] Asset management: insert models by ID, get asset info, search creator store, insert free models/packages, export selection.",basic:[],pro:["insert","info","search","search_insert","insert_free","insert_package","export"]},{name:"manage_sync",description:"[PRO] Project sync management: status, history, direction settings, read/write synced files.",basic:[],pro:["status_current_place","history","directions","read_file","write_file","progress"]},{name:"workspace_state",description:"[PRO] Workspace state: full sync, snapshot, recent changes, viewport info, clear history, metadata, scripts, selection info, clear cache.",basic:[],pro:["sync","snapshot","changes","viewport","clear_history","metadata","scripts","selection_info","clear_cache"]},{name:"manage_logs",description:"Output logs: get filtered logs, poll incrementally with sinceSeq cursor, clear buffer, get recent errors.",basic:["get","clear","errors"],pro:[]},{name:"system_info",description:"System info: ping, connection status, usage tier. [PRO] place info, services list, studio settings, playtest control, automated test runner.",basic:["ping","connection","usage"],pro:["place_info","services","studio_settings","play","stop","pause","resume","play_status","run_test"]},{name:"batch_execute",description:'[PRO] Execute multiple commands in a single batch. Each command is an object with "tool" name and "args". Commands execute sequentially; optionally continue on error.',basic:[],pro:["batch_execute"]},{name:"execute_luau",description:"[PRO] Execute arbitrary Luau code in Roblox Studio sandbox. Blocked services: HttpService, DataStoreService, MessagingService. Cannot access CoreGui/CorePackages.",basic:[],pro:["execute_luau"]}],B={proOnlyTools:13,mixedTools:6,totalBasicActions:51,totalProActions:106},L={tools:O,summary:B},A=new Date("2026-04-30T23:59:59");function v(){return Date.now()<=A.getTime()}const _e={overview:"https://gum.co/u/2nc0fhky",changelog:"https://gum.co/u/wjcnucpy",sync:"https://gum.co/u/p0barnlb",playtest:"https://gum.co/u/kchczjry",tools:"https://gum.co/u/ljmteaed"},D="_tag_1wj0q_2",E="_label_1wj0q_17",q="_code_1wj0q_22",G="_expiry_1wj0q_31",M="_inline_1wj0q_49",$="_centered_1wj0q_54",l={tag:D,label:E,code:q,expiry:G,inline:M,centered:$};function W({variant:c}){const{t:e}=j();return v()?t.jsxs("div",{className:`${l.tag} ${c==="centered"?l.centered:l.inline}`,children:[t.jsx("span",{className:l.label,children:e("tier.promo.discount.context","🎁 Gumroad 결제 μ‹œ ν• μΈμ½”λ“œ μž…λ ₯:")}),t.jsx("span",{className:l.code,children:e("tier.comparison.discount.code","WEPPY-MCP")}),t.jsx("span",{className:l.expiry,children:e("tier.comparison.discount.expiry","Valid until April 30")})]}):null}const H="_overlay_171mk_2",I="_modal_171mk_13",U="_summaryGrid_171mk_32",z="_summaryCard_171mk_39",Y="_basicCard_171mk_45",F="_proCard_171mk_49",Q="_cardTitle_171mk_54",V="_summarySection_171mk_70",X="_sectionTitle_171mk_78",J="_featureList_171mk_90",K="_summary_171mk_32",Z="_statBasic_171mk_116",ee="_statPro_171mk_120",te="_statMixed_171mk_124",se="_detailHeader_171mk_128",ae="_tableWrap_171mk_137",ie="_table_171mk_137",re="_toolName_171mk_165",ce="_description_171mk_171",ne="_actionList_171mk_176",oe="_none_171mk_184",le="_discountBanner_171mk_189",me="_closeBtn_171mk_227",s={overlay:H,modal:I,summaryGrid:U,summaryCard:z,basicCard:Y,proCard:F,cardTitle:Q,summarySection:V,sectionTitle:X,featureList:J,summary:K,statBasic:Z,statPro:ee,statMixed:te,detailHeader:se,tableWrap:ae,table:ie,toolName:re,description:ce,actionList:ne,none:oe,discountBanner:le,closeBtn:me};function ue({onClose:c}){const{t:e}=j(),{tools:m,summary:n}=L,p=[{title:e("tier.comparison.basic.core","Core MCP workflow"),items:[e("tier.comparison.basic.core.item1","Script create/edit"),e("tier.comparison.basic.core.item2","Instance management"),e("tier.comparison.basic.core.item3","Property control"),e("tier.comparison.basic.core.item4","Selection and search"),e("tier.comparison.basic.core.item5","Tag management"),e("tier.comparison.basic.core.item6","Camera control"),e("tier.comparison.basic.core.item7","Log monitoring")]},{title:e("tier.comparison.basic.sync","Sync (Basic)"),items:[e("tier.comparison.basic.sync.item1","Studio to Local one-way sync"),e("tier.comparison.basic.sync.item2","Manual apply as default")]}],g=[{title:e("tier.comparison.pro.all","Everything in Basic, plus"),items:[]},{title:e("tier.comparison.pro.sync","Advanced Sync workflow"),items:[e("tier.comparison.pro.sync.item1","Per-type sync direction"),e("tier.comparison.pro.sync.item2","Per-type apply mode"),e("tier.comparison.pro.sync.item3","Bidirectional and reverse sync"),e("tier.comparison.pro.sync.item4","Full sync, resync, and push to Studio"),e("tier.comparison.pro.sync.item5","Multi-place sync")]},{title:e("tier.comparison.pro.playtest","Playtest control"),items:[e("tier.comparison.pro.playtest.item1","Play, stop, pause, and resume"),e("tier.comparison.pro.playtest.item2","Playtest state inspection"),e("tier.comparison.pro.playtest.item3","Automated test execution")]},{title:e("tier.comparison.pro.creation","Advanced creation workflow"),items:[e("tier.comparison.pro.creation.item1","Bulk operations"),e("tier.comparison.pro.creation.item2","Terrain generation"),e("tier.comparison.pro.creation.item3","Asset search and insert"),e("tier.comparison.pro.creation.item4","Raycast and spatial analysis"),e("tier.comparison.pro.creation.item5","Environment control")]}];return t.jsx("div",{className:s.overlay,onClick:c,children:t.jsxs("div",{className:s.modal,onClick:a=>a.stopPropagation(),children:[v()&&t.jsx("div",{className:s.discountBanner,children:t.jsx(W,{variant:"centered"})}),t.jsx("h2",{children:e("tier.compare")}),t.jsxs("div",{className:s.summaryGrid,children:[t.jsxs("section",{className:`${s.summaryCard} ${s.basicCard}`,children:[t.jsx("h3",{className:s.cardTitle,children:e("tier.basic")}),p.map(a=>t.jsxs("div",{className:s.summarySection,children:[t.jsx("div",{className:s.sectionTitle,children:a.title}),t.jsx("ul",{className:s.featureList,children:a.items.map(i=>t.jsx("li",{children:i},i))})]},a.title))]}),t.jsxs("section",{className:`${s.summaryCard} ${s.proCard}`,children:[t.jsx("h3",{className:s.cardTitle,children:e("tier.pro")}),g.map(a=>t.jsxs("div",{className:s.summarySection,children:[t.jsx("div",{className:s.sectionTitle,children:a.title}),a.items.length>0&&t.jsx("ul",{className:s.featureList,children:a.items.map(i=>t.jsx("li",{children:i},i))})]},a.title))]})]}),t.jsxs("div",{className:s.summary,children:[t.jsxs("span",{className:s.statBasic,children:["Basic: ",n.totalBasicActions," actions"]}),t.jsxs("span",{className:s.statPro,children:["Pro: ",n.totalProActions," actions"]}),t.jsxs("span",{className:s.statMixed,children:[n.mixedTools," mixed / ",n.proOnlyTools," pro-only"]})]}),t.jsx("div",{className:s.detailHeader,children:e("tier.comparison.detailTitle","Detailed Tool Catalog")}),t.jsx("div",{className:s.tableWrap,children:t.jsxs("table",{className:s.table,children:[t.jsx("thead",{children:t.jsxs("tr",{children:[t.jsx("th",{children:e("tools.col.tool")}),t.jsx("th",{children:e("tier.comparison.description","Description")}),t.jsx("th",{children:e("tier.basic")}),t.jsx("th",{children:e("tier.pro")})]})}),t.jsx("tbody",{children:m.map(a=>t.jsxs("tr",{children:[t.jsx("td",{className:s.toolName,children:a.name}),t.jsx("td",{className:s.description,children:e(`tier.tool.${a.name}.desc`,a.description)}),t.jsx("td",{className:s.actionList,children:a.basic.length>0?a.basic.join(", "):t.jsx("span",{className:s.none,children:"β€”"})}),t.jsx("td",{className:s.actionList,children:a.pro.length>0?a.pro.join(", "):t.jsx("span",{className:s.none,children:"β€”"})})]},a.name))})]})}),t.jsx("button",{className:s.closeBtn,onClick:c,children:e("tier.comparison.close","Close")})]})})}export{W as D,_e as T,ue as a,pe as u};
@@ -1 +1 @@
1
- import{u as h,r as x,k as g,l as j,j as s}from"./index-BhDELp5r.js";import{D as v,a as u}from"./TierComparison-7eRDwSAZ.js";import{t as e}from"./TierPromo.module-CAoUYgIx.js";function k({basicCalls:n,proCalls:a,totalCalls:c,proUsagePercent:l,upgradeHref:p}){const{t:r}=h(),[m,t]=x.useState(!1),{trackEvent:o}=g(),{pathname:d}=j(),i=d.replace(/^\//,"").split("/")[0]||"overview";return s.jsxs(s.Fragment,{children:[s.jsxs("div",{className:e.progressPromoWrap,children:[s.jsxs("div",{className:e.progressPromo,children:[s.jsxs("div",{className:e.progressMain,children:[s.jsxs("div",{className:e.progressLabel,children:[s.jsx("span",{children:r("tier.progress.label","Pro / Total")}),s.jsxs("span",{children:[a," / ",c]})]}),s.jsx("div",{className:e.progressBar,children:s.jsx("div",{className:e.progressFill,style:{width:`${Math.min(l,100)}%`}})}),s.jsxs("div",{className:e.progressLabel,children:[s.jsxs("span",{children:[r("tier.basic")," ",n]}),s.jsxs("span",{children:[r("tier.pro")," ",a]})]})]}),s.jsx("span",{className:e.progressText,children:r("tier.banner.save","Save AI tokens with Pro!")}),s.jsxs("div",{className:e.actions,children:[s.jsx("button",{className:`${e.btn} ${e.btnOutline}`,onClick:()=>{o("dashboard_click_event",{click_target:"tier_compare",placement:"tier_progress",page:i}),t(!0)},children:r("tier.compare","Basic vs Pro")}),s.jsx("a",{className:`${e.btn} ${e.btnPrimary}`,href:p,target:"_blank",rel:"noreferrer",onClick:()=>o("dashboard_click_event",{click_target:"upgrade_cta",placement:"tier_progress",page:i}),children:r("tier.upgrade","Upgrade to Pro")})]})]}),s.jsx(v,{variant:"centered"})]}),m&&s.jsx(u,{onClose:()=>t(!1)})]})}export{k as T};
1
+ import{u as h,r as x,k as g,l as j,j as s}from"./index-BfvSPSNj.js";import{D as v,a as u}from"./TierComparison-BwKqP_4s.js";import{t as e}from"./TierPromo.module-CAoUYgIx.js";function k({basicCalls:n,proCalls:a,totalCalls:c,proUsagePercent:l,upgradeHref:p}){const{t:r}=h(),[m,t]=x.useState(!1),{trackEvent:o}=g(),{pathname:d}=j(),i=d.replace(/^\//,"").split("/")[0]||"overview";return s.jsxs(s.Fragment,{children:[s.jsxs("div",{className:e.progressPromoWrap,children:[s.jsxs("div",{className:e.progressPromo,children:[s.jsxs("div",{className:e.progressMain,children:[s.jsxs("div",{className:e.progressLabel,children:[s.jsx("span",{children:r("tier.progress.label","Pro / Total")}),s.jsxs("span",{children:[a," / ",c]})]}),s.jsx("div",{className:e.progressBar,children:s.jsx("div",{className:e.progressFill,style:{width:`${Math.min(l,100)}%`}})}),s.jsxs("div",{className:e.progressLabel,children:[s.jsxs("span",{children:[r("tier.basic")," ",n]}),s.jsxs("span",{children:[r("tier.pro")," ",a]})]})]}),s.jsx("span",{className:e.progressText,children:r("tier.banner.save","Save AI tokens with Pro!")}),s.jsxs("div",{className:e.actions,children:[s.jsx("button",{className:`${e.btn} ${e.btnOutline}`,onClick:()=>{o("dashboard_click_event",{click_target:"tier_compare",placement:"tier_progress",page:i}),t(!0)},children:r("tier.compare","Basic vs Pro")}),s.jsx("a",{className:`${e.btn} ${e.btnPrimary}`,href:p,target:"_blank",rel:"noreferrer",onClick:()=>o("dashboard_click_event",{click_target:"upgrade_cta",placement:"tier_progress",page:i}),children:r("tier.upgrade","Upgrade to Pro")})]})]}),s.jsx(v,{variant:"centered"})]}),m&&s.jsx(u,{onClose:()=>t(!1)})]})}export{k as T};
@@ -0,0 +1 @@
1
+ ._wrapper_hzgda_2{overflow-x:auto}._table_hzgda_7{width:100%;border-collapse:collapse;font-family:var(--font-code);font-size:12px}._table_hzgda_7 th{text-align:left;color:var(--text-muted);font-weight:500;padding:6px 8px;border-bottom:1px solid var(--border);background:var(--bg-secondary);white-space:nowrap;-webkit-user-select:none;user-select:none}._table_hzgda_7 td{padding:6px 8px;color:var(--text-primary);border-bottom:1px solid var(--border-dim, rgba(255, 255, 255, .04))}._sortable_hzgda_32{cursor:pointer;transition:color var(--transition)}._sortable_hzgda_32:hover{color:var(--accent)}._sortArrow_hzgda_41{margin-left:4px;font-size:10px}._table_hzgda_7 tbody tr:hover td{background:var(--accent-dim)}._clickable_hzgda_52{cursor:pointer}._empty_hzgda_57{text-align:center;color:var(--text-muted);font-style:italic;padding:24px 8px}._expandedRow_hzgda_65 td{padding:0!important;border-bottom:1px solid var(--border)}._expandedRow_hzgda_65:hover td{background:transparent!important}._expandedCell_hzgda_74{padding:0!important}._page_1wyl0_2{display:flex;flex-direction:column;gap:16px;max-width:900px}._tabs_1wyl0_10{display:flex;gap:2px;border-bottom:1px solid var(--border);margin-bottom:4px}._tab_1wyl0_10{font-family:var(--font-label);font-size:12px;font-weight:500;padding:8px 16px;background:none;border:none;border-bottom:2px solid transparent;color:var(--text-secondary);cursor:pointer;transition:color var(--transition),border-color var(--transition)}._tab_1wyl0_10:hover{color:var(--text-primary)}._tabActive_1wyl0_34{color:var(--accent);border-bottom-color:var(--accent)}._card_1wyl0_40{background:var(--bg-card);border:1px solid var(--border);border-radius:var(--radius);padding:16px 20px}._cardToolbar_1wyl0_47{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}._sectionTitle_1wyl0_55{font-family:var(--font-label);font-size:13px;color:var(--text-primary)}._dangerButton_1wyl0_61{border:1px solid rgba(209,84,84,.5);background:#d154541f;color:#f4c1c1;border-radius:8px;padding:6px 12px;cursor:pointer}._proBadge_1wyl0_71{display:inline-block;margin-left:6px;padding:1px 5px;font-size:9px;font-weight:600;letter-spacing:.05em;color:#1a1407;background:var(--pro-badge);border-radius:3px;vertical-align:middle}._statusOk_1wyl0_85{display:inline-block;padding:2px 8px;border-radius:999px;background:color-mix(in srgb,var(--success) 14%,transparent);color:var(--success);font-weight:500}._statusFallback_1wyl0_94{display:inline-block;padding:2px 8px;border-radius:999px;background:#4990e224;color:#6fb6ff;font-weight:600}._statusUnsupported_1wyl0_103{display:inline-block;padding:2px 8px;border-radius:999px;background:#f0b42826;color:#d7a43c;font-weight:600}._statusError_1wyl0_112{display:inline-block;padding:2px 8px;border-radius:999px;background:#d1545424;color:#f09c9c;font-weight:600}._tierBasic_1wyl0_122{color:var(--text-secondary)}._tierPro_1wyl0_126{color:var(--pro-badge);font-weight:500}._tierMixed_1wyl0_131{color:var(--text-primary);font-weight:500}._errorText_1wyl0_137{color:var(--error)}._filterRow_1wyl0_142{display:flex;align-items:center;gap:12px;margin-bottom:12px}._filterLabel_1wyl0_149{font-family:var(--font-label);font-size:11px;color:var(--text-secondary);display:flex;align-items:center;gap:6px}._filterSelect_1wyl0_158{font-family:var(--font-code);font-size:12px;padding:3px 8px;border:1px solid var(--border);border-radius:4px;background:var(--bg-secondary);color:var(--text-primary)}._expandedRow_1wyl0_169{background:var(--bg-secondary);padding:12px 16px}._expandedSection_1wyl0_174{margin-bottom:8px;font-size:12px;color:var(--text-secondary)}._expandedSection_1wyl0_174:last-child{margin-bottom:0}._detailList_1wyl0_184{display:flex;flex-direction:column;gap:6px}._detailItem_1wyl0_190{display:flex;flex-wrap:wrap;gap:6px}._detailLabel_1wyl0_196{font-family:var(--font-label);color:var(--text-muted)}._detailValue_1wyl0_201{color:var(--text-primary);word-break:break-word}._pre_1wyl0_206{font-family:var(--font-code);font-size:11px;color:var(--text-primary);background:var(--bg-card);border:1px solid var(--border);border-radius:4px;padding:8px;margin-top:4px;overflow-x:auto;max-height:200px;overflow-y:auto;white-space:pre-wrap;word-break:break-all}._pagination_1wyl0_223{display:flex;align-items:center;justify-content:center;gap:12px;margin-top:12px}._pageInfo_1wyl0_231{font-family:var(--font-code);font-size:12px;color:var(--text-secondary)}._btn_1wyl0_237{font-family:var(--font-label);font-size:12px;padding:4px 12px;border-radius:4px;border:1px solid var(--border);background:var(--bg-secondary);color:var(--text-primary);cursor:pointer;transition:background var(--transition),border-color var(--transition)}._btn_1wyl0_237:hover:not(:disabled){border-color:var(--accent);background:var(--accent-dim)}._btn_1wyl0_237:disabled{opacity:.4;cursor:default}._tierDistribution_1wyl0_260{margin-bottom:16px}._tierBarWrap_1wyl0_264{display:flex;height:12px;border-radius:6px;overflow:hidden;background:var(--bg-secondary)}._tierBarBasic_1wyl0_272{background:var(--text-secondary);transition:width .3s ease}._tierBarPro_1wyl0_277{background:var(--accent);transition:width .3s ease}._tierLabels_1wyl0_282{display:flex;justify-content:space-between;margin-top:4px;font-family:var(--font-code);font-size:11px;color:var(--text-secondary)}._statsTableWrap_1wyl0_291{border:1px solid var(--border);border-radius:var(--radius);overflow:hidden}._statsTable_1wyl0_291{width:100%;border-collapse:collapse}._statsTable_1wyl0_291 th,._statsTable_1wyl0_291 td{padding:10px 12px;font-size:12px;text-align:left;border-bottom:1px solid var(--border)}._statsTable_1wyl0_291 th{font-family:var(--font-label);font-size:11px;font-weight:500;color:var(--text-secondary);background:var(--bg-secondary)}._statsTable_1wyl0_291 tbody tr:last-child td{border-bottom:none}._sortableHeader_1wyl0_322{cursor:pointer;-webkit-user-select:none;user-select:none}._sortArrow_1wyl0_327{margin-left:4px}._statsToolRow_1wyl0_331{cursor:pointer}._statsToolRow_1wyl0_331:hover td{background:var(--bg-secondary)}._statsActionRow_1wyl0_339 td{background:color-mix(in srgb,var(--bg-secondary) 72%,transparent)}._expandButton_1wyl0_343{display:inline-flex;align-items:center;gap:8px;padding:0;border:none;background:transparent;color:inherit;font:inherit;cursor:pointer}._expandIcon_1wyl0_355{width:10px;color:var(--text-secondary)}._actionLabel_1wyl0_360{display:inline-block;padding-left:18px;font-family:var(--font-code);color:var(--text-secondary)}._emptyStats_1wyl0_367{text-align:center;color:var(--text-muted)}._summaryLine_1wyl0_373{margin-top:12px;font-family:var(--font-code);font-size:12px;color:var(--text-muted);text-align:right}
@@ -0,0 +1 @@
1
+ import{j as s,r,a as D,D as tt,u as et,i as st,T as M}from"./index-BfvSPSNj.js";import{C as at}from"./ConfirmModal-DfdyAPrJ.js";import{u as ot,T as lt}from"./TierComparison-BwKqP_4s.js";import{T as rt}from"./TierPromoProgress-CLAr1gQq.js";import"./TierPromo.module-CAoUYgIx.js";const it="_wrapper_hzgda_2",nt="_table_hzgda_7",ct="_sortable_hzgda_32",dt="_sortArrow_hzgda_41",ut="_clickable_hzgda_52",pt="_empty_hzgda_57",ht="_expandedRow_hzgda_65",mt="_expandedCell_hzgda_74",S={wrapper:it,table:nt,sortable:ct,sortArrow:dt,clickable:ut,empty:pt,expandedRow:ht,expandedCell:mt};function xt({columns:e,data:a,sortBy:m,sortDir:b="asc",onSort:w,onRowClick:j,rowKey:E,emptyMessage:L,expandedKey:A,renderExpandedRow:v}){return s.jsx("div",{className:S.wrapper,children:s.jsxs("table",{className:S.table,children:[s.jsx("thead",{children:s.jsx("tr",{children:e.map(n=>s.jsxs("th",{style:n.width?{width:n.width}:void 0,className:n.sortable?S.sortable:void 0,onClick:n.sortable&&w?()=>w(n.key):void 0,children:[s.jsx("span",{children:n.label}),n.sortable&&m===n.key&&s.jsx("span",{className:S.sortArrow,children:b==="asc"?"β–΄":"β–Ύ"})]},n.key))})}),s.jsx("tbody",{children:a.length===0?s.jsx("tr",{children:s.jsx("td",{colSpan:e.length,className:S.empty,children:L||"No data"})}):a.map((n,C)=>{const h=E?E(n):String(C),d=A!=null&&h===A&&v?v(n):null;return s.jsxs(r.Fragment,{children:[s.jsx("tr",{className:j?S.clickable:void 0,onClick:j?()=>j(n):void 0,children:e.map(T=>s.jsx("td",{children:T.render?T.render(n):String(n[T.key]??"")},T.key))}),d&&s.jsx("tr",{className:S.expandedRow,children:s.jsx("td",{colSpan:e.length,className:S.expandedCell,children:d})})]},h)})})]})})}function bt(e){return{...e,sequenceNumber:typeof e.sequenceNumber=="number"?e.sequenceNumber:void 0,executionTimeMs:typeof e.executionTimeMs=="number"?e.executionTimeMs:void 0}}const _t=50;function ft(){const[e,a]=r.useState(null),[m,b]=r.useState(!0),[w,j]=r.useState([]),[E,L]=r.useState(0),[A,v]=r.useState(!1),[n,C]=r.useState(!0),[h,H]=r.useState(0),[d,T]=r.useState(""),B=r.useRef(null),_=r.useCallback(async()=>{b(!0);try{const f=await D.get("/api/dashboard/tool-stats");a(f)}catch{}finally{b(!1)}},[]),g=r.useCallback(async(f,P)=>{C(!0);try{const F={limit:String(_t),offset:String(f)};P&&(F.tool=P);const y=await D.get("/api/dashboard/history",F);j(y.entries.map(bt)),L(y.total),v(y.hasMore)}catch{j([]),L(0),v(!1)}finally{C(!1)}},[]),U=r.useCallback(()=>{_(),g(h,d)},[g,_,h,d]),O=r.useCallback(async()=>{await D.post("/api/dashboard/tools/history/clear"),g(h,d)},[g,h,d]),u=r.useCallback(async()=>{await D.post("/api/dashboard/tools/statistics/clear"),_()},[_]);return r.useEffect(()=>{_()},[_]),r.useEffect(()=>{g(h,d)},[g,h,d]),r.useEffect(()=>{const f=new tt;B.current=f,f.connect();const P=f.on("command",()=>{_(),g(h,d)});return()=>{P(),f.disconnect(),B.current=null}},[g,_,h,d]),{statistics:e,statsLoading:m,history:w,historyTotal:E,historyHasMore:A,historyLoading:n,historyOffset:h,historyToolFilter:d,setHistoryOffset:H,setHistoryToolFilter:T,refresh:U,clearHistory:O,clearStatistics:u}}const yt="_page_1wyl0_2",gt="_tabs_1wyl0_10",Ct="_tab_1wyl0_10",wt="_tabActive_1wyl0_34",jt="_card_1wyl0_40",Tt="_cardToolbar_1wyl0_47",kt="_sectionTitle_1wyl0_55",St="_dangerButton_1wyl0_61",Nt="_proBadge_1wyl0_71",vt="_statusOk_1wyl0_85",Bt="_statusFallback_1wyl0_94",Mt="_statusUnsupported_1wyl0_103",Et="_statusError_1wyl0_112",Lt="_tierBasic_1wyl0_122",At="_tierPro_1wyl0_126",Pt="_tierMixed_1wyl0_131",Rt="_filterRow_1wyl0_142",Ht="_filterLabel_1wyl0_149",Ft="_filterSelect_1wyl0_158",Ot="_expandedRow_1wyl0_169",$t="_expandedSection_1wyl0_174",It="_detailList_1wyl0_184",Dt="_detailItem_1wyl0_190",qt="_detailLabel_1wyl0_196",Ut="_detailValue_1wyl0_201",zt="_pre_1wyl0_206",Wt="_pagination_1wyl0_223",Kt="_pageInfo_1wyl0_231",Vt="_btn_1wyl0_237",Gt="_tierDistribution_1wyl0_260",Jt="_tierBarWrap_1wyl0_264",Zt="_tierBarBasic_1wyl0_272",Qt="_tierBarPro_1wyl0_277",Xt="_tierLabels_1wyl0_282",Yt="_statsTableWrap_1wyl0_291",te="_statsTable_1wyl0_291",ee="_sortableHeader_1wyl0_322",se="_sortArrow_1wyl0_327",ae="_statsToolRow_1wyl0_331",oe="_statsActionRow_1wyl0_339",le="_expandButton_1wyl0_343",re="_expandIcon_1wyl0_355",ie="_actionLabel_1wyl0_360",ne="_emptyStats_1wyl0_367",ce="_summaryLine_1wyl0_373",o={page:yt,tabs:gt,tab:Ct,tabActive:wt,card:jt,cardToolbar:Tt,sectionTitle:kt,dangerButton:St,proBadge:Nt,statusOk:vt,statusFallback:Bt,statusUnsupported:Mt,statusError:Et,tierBasic:Lt,tierPro:At,tierMixed:Pt,filterRow:Rt,filterLabel:Ht,filterSelect:Ft,expandedRow:Ot,expandedSection:$t,detailList:It,detailItem:Dt,detailLabel:qt,detailValue:Ut,pre:zt,pagination:Wt,pageInfo:Kt,btn:Vt,tierDistribution:Gt,tierBarWrap:Jt,tierBarBasic:Zt,tierBarPro:Qt,tierLabels:Xt,statsTableWrap:Yt,statsTable:te,sortableHeader:ee,sortArrow:se,statsToolRow:ae,statsActionRow:oe,expandButton:le,expandIcon:re,actionLabel:ie,emptyStats:ne,summaryLine:ce},z=50;function de(e){const a=new Date(e);return`${String(a.getHours()).padStart(2,"0")}:${String(a.getMinutes()).padStart(2,"0")}:${String(a.getSeconds()).padStart(2,"0")}`}function q(e){return typeof e!="number"||!Number.isFinite(e)?"-":e<1e3?`${e}ms`:`${(e/1e3).toFixed(1)}s`}function R(e,a){return a==="pro"?e("tier.pro","Pro"):a==="mixed"?e("tier.mixed","Mixed"):e("tier.basic","Basic")}function J(e,a){return a!==e&&a.startsWith(`${e}_`)?a.slice(e.length+1):""}function ue(e,a){const m=J(e,a);return m?`${e}.${m}`:e}function G(e){return typeof e=="string"&&e.length>0?e:void 0}function pe(e){if(!Array.isArray(e))return;const a=e.filter(m=>typeof m=="string"&&m.length>0);return a.length>0?a:void 0}function he(e){const a=e.result??{};return{requestedCommand:e.requestedCommand??G(a.requestedCommand),executedCommand:e.executedCommand??G(a.executedCommand),alternatives:e.alternatives??pe(a.alternatives)}}function me(e,a){switch(e.status){case"fallback":return{label:a("tools.badge.fallback","FALLBACK"),tooltip:a("tools.badge.fallback.tooltip","The requested Pro action succeeded via a Basic fallback."),className:o.statusFallback};case"unsupported":return{label:a("tools.badge.unsupported","UNSUPPORTED"),tooltip:a("tools.badge.unsupported.tooltip","The requested Pro action was blocked and no fallback ran."),className:o.statusUnsupported};case"error":return{label:a("tools.badge.err","FAILED"),tooltip:a("tools.badge.err.tooltip","The tool run failed."),className:o.statusError};default:return{label:a("tools.status.ok","OK"),tooltip:a("tools.status.ok.tooltip","The tool run completed successfully."),className:o.statusOk}}}function N(e,a){return s.jsxs("div",{className:o.detailItem,children:[s.jsx("span",{className:o.detailLabel,children:e}),s.jsx("span",{className:o.detailValue,children:a})]})}function Ce(){const{t:e}=et(),a=ft(),{show:m}=st(),b=ot(),[w,j]=r.useState("history"),[E,L]=r.useState(null),[A,v]=r.useState(null),[n,C]=r.useState(null),[h,H]=r.useState(!1),[d,T]=r.useState("totalCalls"),[B,_]=r.useState("desc"),g=r.useCallback(t=>{T(l=>l===t?(_(i=>i==="asc"?"desc":"asc"),t):(_("desc"),t))},[]),U=r.useMemo(()=>{var l;const t=new Set;return Object.keys(((l=a.statistics)==null?void 0:l.tools)??{}).forEach(i=>t.add(i)),a.history.forEach(i=>{i.tool&&t.add(i.tool)}),a.historyToolFilter&&t.add(a.historyToolFilter),Array.from(t).sort()},[a.history,a.historyToolFilter,a.statistics]),O=r.useMemo(()=>{var t;return(t=a.statistics)!=null&&t.tools?Object.values(a.statistics.tools).map(l=>{var V;const i=Object.entries(l.commands??{}).map(([p,c])=>({toolName:l.tool,commandName:c.command??p,label:J(l.tool,c.command??p)||(c.command??p),tier:c.tier,totalCalls:c.totalCalls,successCount:c.successCount,fallbackCount:c.fallbackCount,unsupportedCount:c.unsupportedCount,failureCount:c.failureCount,totalExecutionTimeMs:c.totalExecutionTimeMs,avgExecutionTimeMs:c.avgExecutionTimeMs})),x=i.reduce((p,c)=>p+c.totalCalls,0),k=i.reduce((p,c)=>p+c.successCount,0),$=i.reduce((p,c)=>p+c.fallbackCount,0),I=i.reduce((p,c)=>p+c.unsupportedCount,0),X=i.reduce((p,c)=>p+c.failureCount,0),K=i.reduce((p,c)=>p+c.totalExecutionTimeMs,0),Y=new Set(i.map(p=>p.tier)).size>1?"mixed":((V=i[0])==null?void 0:V.tier)??l.tier;return{toolName:l.tool,tier:Y,commands:i,totalCalls:x,successCount:k,fallbackCount:$,unsupportedCount:I,failureCount:X,totalExecutionTimeMs:K,avgExecutionTimeMs:x>0?Math.round(K/x):0}}):[]},[a.statistics]),u=r.useCallback((t,l,i,x)=>s.jsx(M,{text:e(i,x),children:e(t,l)}),[e]),f=r.useMemo(()=>[...O].sort((l,i)=>{const x=l[d],k=i[d];if(typeof x=="number"&&typeof k=="number")return B==="asc"?x-k:k-x;const $=String(x??""),I=String(k??"");return B==="asc"?$.localeCompare(I):I.localeCompare($)}),[O,d,B]),P=r.useMemo(()=>[{key:"timestamp",label:u("tools.col.time","Time","tools.col.time.tooltip","When the tool run was recorded."),width:"80px",render:t=>de(t.timestamp)},{key:"toolName",label:u("tools.col.toolAction","Tool.Action","tools.col.toolAction.tooltip","Tool name and action that were executed."),render:t=>s.jsxs("span",{children:[ue(t.tool,t.command),t.tier==="pro"&&s.jsx(M,{text:e("tools.badge.pro.tooltip","This entry used a Pro-only tool or action."),children:s.jsx("span",{className:o.proBadge,children:e("tools.badge.pro","PRO")})})]})},{key:"executionTimeMs",label:u("tools.col.duration","Duration","tools.col.duration.tooltip","How long the tool took to finish."),width:"80px",render:t=>q(t.executionTimeMs)},{key:"status",label:u("tools.col.status","Status","tools.col.status.tooltip","Outcome of the recorded tool run."),width:"120px",render:t=>{const l=me(t,e);return s.jsx(M,{text:l.tooltip,children:s.jsx("span",{className:l.className,children:l.label})})}},{key:"tier",label:u("tools.col.tier","Tier","tools.col.tier.tooltip","License tier required for the tool or action."),width:"60px",render:t=>s.jsx("span",{className:t.tier==="pro"?o.tierPro:o.tierBasic,children:R(e,t.tier)})}],[e,u]),F=r.useMemo(()=>[{key:"toolName",label:u("tools.col.tool","Tool","tools.col.tool.tooltip","Consolidated tool name in the statistics table."),sortable:!0},{key:"totalCalls",label:u("tools.col.calls","Calls","tools.col.calls.tooltip","Total number of recorded calls for this tool."),sortable:!0,width:"70px"},{key:"successCount",label:u("tools.col.ok","OK","tools.col.ok.tooltip","Number of direct successful runs."),sortable:!0,width:"70px"},{key:"fallbackCount",label:u("tools.col.fallback","FALLBACK","tools.col.fallback.tooltip","Number of runs that succeeded through fallback execution."),sortable:!0,width:"110px"},{key:"unsupportedCount",label:u("tools.col.unsupported","UNSUPPORTED","tools.col.unsupported.tooltip","Number of blocked runs without fallback execution."),sortable:!0,width:"130px"},{key:"failureCount",label:u("tools.col.err","FAILED","tools.col.err.tooltip","Number of runs that failed."),sortable:!0,width:"70px"},{key:"avgExecutionTimeMs",label:u("tools.col.avgTime","Avg Time","tools.col.avgTime.tooltip","Average execution time across recorded calls."),sortable:!0,width:"90px",render:t=>q(t.avgExecutionTimeMs)},{key:"tier",label:u("tools.col.tier","Tier","tools.col.tierStats.tooltip","Basic, Pro, or Mixed summary for the tool statistics row."),sortable:!0,width:"70px",render:t=>s.jsx(M,{text:t.tier==="mixed"?e("tools.tier.mixed.tooltip","This tool includes both Basic and Pro actions."):"",children:s.jsx("span",{className:t.tier==="pro"?o.tierPro:t.tier==="mixed"?o.tierMixed:o.tierBasic,children:R(e,t.tier)})})}],[e,u]),y=r.useMemo(()=>{if(!a.statistics)return null;const t=a.statistics.tierSummary.basic.totalCalls,l=a.statistics.tierSummary.pro.totalCalls,i=t+l;if(i===0)return null;const x=Math.round(t/i*100),k=100-x;return{basic:t,pro:l,basicPct:x,proPct:k}},[a.statistics]),W=r.useCallback(t=>{v(l=>l===t?null:t)},[]),Z=r.useCallback(async()=>{if(n){H(!0);try{n==="history"?await a.clearHistory():await a.clearStatistics(),m(e("toast.clearSuccess","Cleared successfully"),"success"),C(null)}catch{m(e("toast.clearFailed","Failed to clear data"),"error")}finally{H(!1)}}},[n,m,e,a]),Q=r.useCallback(t=>{const l=he(t);return s.jsxs("div",{className:o.expandedRow,children:[s.jsxs("div",{className:o.expandedSection,children:[s.jsxs("strong",{children:[s.jsx(M,{text:e("tools.detail.params.tooltip","Input parameters passed to this tool run."),children:e("tools.detail.params","Parameters")}),":"]}),s.jsx("pre",{className:o.pre,children:JSON.stringify(t.parameters,null,2)})]}),t.result&&s.jsxs("div",{className:o.expandedSection,children:[s.jsxs("strong",{children:[s.jsx(M,{text:e("tools.detail.result.tooltip","Returned result payload for this tool run."),children:e("tools.detail.result","Result")}),":"]}),s.jsx("pre",{className:o.pre,children:JSON.stringify(t.result,null,2)})]}),(t.status==="fallback"||t.status==="unsupported"||t.status==="error")&&s.jsx("div",{className:o.expandedSection,children:s.jsxs("div",{className:o.detailList,children:[t.status==="fallback"&&(l==null?void 0:l.requestedCommand)&&N(e("tools.detail.requestedCommand","Requested Command"),l.requestedCommand),t.status==="fallback"&&(l==null?void 0:l.executedCommand)&&N(e("tools.detail.executedCommand","Executed Command"),l.executedCommand),t.status==="fallback"&&(l==null?void 0:l.alternatives)&&N(e("tools.detail.alternatives","Alternatives"),l.alternatives.join(", ")),t.status==="unsupported"&&t.blockedMessage&&N(e("tools.detail.blockedMessage","Blocked Reason"),t.blockedMessage),t.status==="unsupported"&&N(e("tools.detail.noFallback","No Fallback"),e("tools.detail.noFallback.value","No fallback ran.")),t.status==="error"&&t.errorMessage&&N(e("tools.detail.errorMessage","Error Message"),t.errorMessage),t.status==="error"&&t.blockedMessage&&N(e("tools.detail.blockedMessage","Blocked Reason"),t.blockedMessage),t.status==="error"&&t.fallbackCommand&&N(e("tools.detail.executedCommand","Executed Command"),t.fallbackCommand)]})})]})},[e]);return s.jsxs("div",{className:o.page,children:[s.jsx("div",{className:o.tabs,children:["history","statistics"].map(t=>s.jsx("button",{className:`${o.tab} ${w===t?o.tabActive:""}`,onClick:()=>j(t),children:e(`tools.tab.${t}`,t.charAt(0).toUpperCase()+t.slice(1))},t))}),w==="history"&&s.jsxs("div",{className:o.card,children:[s.jsxs("div",{className:o.cardToolbar,children:[s.jsx("div",{className:o.sectionTitle,children:e("tools.tab.history","History")}),s.jsx("button",{className:o.dangerButton,onClick:()=>C("history"),children:e("common.clear","Clear")})]}),s.jsx("div",{className:o.filterRow,children:s.jsxs("label",{className:o.filterLabel,children:[e("tools.filter.tool","Tool"),":",s.jsxs("select",{className:o.filterSelect,value:a.historyToolFilter,onChange:t=>{a.setHistoryToolFilter(t.target.value),a.setHistoryOffset(0)},children:[s.jsx("option",{value:"",children:e("tools.filter.all","All")}),U.map(t=>s.jsx("option",{value:t,children:t},t))]})]})}),s.jsx(xt,{columns:P,data:a.history,rowKey:t=>t.id,onRowClick:t=>L(l=>l===t.id?null:t.id),emptyMessage:e("tools.empty.history","No history entries"),expandedKey:E,renderExpandedRow:Q}),s.jsxs("div",{className:o.pagination,children:[s.jsx("button",{className:o.btn,disabled:a.historyOffset===0,title:e("tools.page.prev.tooltip","Go to the previous page of tool history results."),onClick:()=>a.setHistoryOffset(Math.max(0,a.historyOffset-z)),children:e("tools.page.prev","Prev")}),s.jsxs("span",{className:o.pageInfo,children:[a.historyOffset+1,"–",Math.min(a.historyOffset+z,a.historyTotal)," / ",a.historyTotal]}),s.jsx("button",{className:o.btn,disabled:!a.historyHasMore,title:e("tools.page.next.tooltip","Go to the next page of tool history results."),onClick:()=>a.setHistoryOffset(a.historyOffset+z),children:e("tools.page.next","Next")})]})]}),w==="statistics"&&s.jsxs("div",{className:o.card,children:[s.jsxs("div",{className:o.cardToolbar,children:[s.jsx("div",{className:o.sectionTitle,children:e("tools.tab.statistics","Statistics")}),s.jsx("button",{className:o.dangerButton,onClick:()=>C("statistics"),children:e("common.clear","Clear")})]}),y&&s.jsxs("div",{className:o.tierDistribution,children:[s.jsxs("div",{className:o.tierBarWrap,children:[s.jsx("div",{className:o.tierBarBasic,style:{width:`${y.basicPct}%`}}),s.jsx("div",{className:o.tierBarPro,style:{width:`${y.proPct}%`}})]}),s.jsxs("div",{className:o.tierLabels,children:[s.jsxs("span",{children:[R(e,"basic")," ",y.basicPct,"% (",y.basic,")"]}),s.jsxs("span",{children:[R(e,"pro")," ",y.proPct,"% (",y.pro,")"]})]})]}),s.jsx("div",{className:o.statsTableWrap,children:s.jsxs("table",{className:o.statsTable,children:[s.jsx("thead",{children:s.jsx("tr",{children:F.map(t=>s.jsxs("th",{style:t.width?{width:t.width}:void 0,className:t.sortable?o.sortableHeader:void 0,onClick:t.sortable?()=>g(t.key):void 0,children:[s.jsx("span",{children:t.label}),t.sortable&&d===t.key&&s.jsx("span",{className:o.sortArrow,children:B==="asc"?"β–΄":"β–Ύ"})]},t.key))})}),s.jsx("tbody",{children:f.length===0?s.jsx("tr",{children:s.jsx("td",{colSpan:F.length,className:o.emptyStats,children:e("tools.empty.stats","No tool statistics")})}):f.map(t=>{const l=A===t.toolName;return s.jsxs(r.Fragment,{children:[s.jsxs("tr",{className:o.statsToolRow,onClick:()=>W(t.toolName),children:[s.jsx("td",{children:s.jsxs("button",{type:"button",className:o.expandButton,"aria-expanded":l,"aria-label":`${t.toolName} ${l?e("common.collapse","Collapse"):e("common.expand","Expand")}`,onClick:i=>{i.stopPropagation(),W(t.toolName)},children:[s.jsx("span",{className:o.expandIcon,"aria-hidden":"true",children:l?"β–Ύ":"β–Έ"}),s.jsx("span",{children:t.toolName})]})}),s.jsx("td",{children:t.totalCalls}),s.jsx("td",{children:t.successCount}),s.jsx("td",{children:t.fallbackCount}),s.jsx("td",{children:t.unsupportedCount}),s.jsx("td",{children:t.failureCount}),s.jsx("td",{children:q(t.avgExecutionTimeMs)}),s.jsx("td",{children:s.jsx(M,{text:t.tier==="mixed"?e("tools.tier.mixed.tooltip","This tool includes both Basic and Pro actions."):"",children:s.jsx("span",{className:t.tier==="pro"?o.tierPro:t.tier==="mixed"?o.tierMixed:o.tierBasic,children:R(e,t.tier)})})})]}),l&&t.commands.map(i=>s.jsxs("tr",{className:o.statsActionRow,children:[s.jsx("td",{children:s.jsx("span",{className:o.actionLabel,children:i.label})}),s.jsx("td",{children:i.totalCalls}),s.jsx("td",{children:i.successCount}),s.jsx("td",{children:i.fallbackCount}),s.jsx("td",{children:i.unsupportedCount}),s.jsx("td",{children:i.failureCount}),s.jsx("td",{children:q(i.avgExecutionTimeMs)}),s.jsx("td",{children:s.jsx("span",{className:i.tier==="pro"?o.tierPro:o.tierBasic,children:R(e,i.tier)})})]},`${t.toolName}:${i.commandName}`))]},t.toolName)})})]})}),a.statistics&&s.jsxs("div",{className:o.summaryLine,children:[e("tools.summary.total","Total"),": ",a.statistics.totalCalls," ",e("tools.summary.calls","calls")," | ",e("tools.summary.sessions","Sessions"),": ",a.statistics.totalSessions]})]}),!b.loading&&b.tier==="basic"&&s.jsx(rt,{basicCalls:b.basicCalls,proCalls:b.proCalls,totalCalls:b.totalCalls,proUsagePercent:b.proUsagePercent,upgradeHref:lt.tools}),s.jsx(at,{open:n!==null,title:n==="history"?e("tools.clear.history.title","Clear history?"):e("tools.clear.statistics.title","Clear statistics?"),message:n==="history"?e("tools.clear.history.message","This permanently removes the current place tools history."):e("tools.clear.statistics.message","This permanently resets the current place tool statistics."),cancelLabel:e("common.cancel","Cancel"),confirmLabel:e("common.clear","Clear"),loading:h,onCancel:()=>!h&&C(null),onConfirm:Z})]})}export{Ce as Component};
@@ -1 +1 @@
1
- import{u as x,j as e,n as u,r as p,o as h,m as w,L as m}from"./index-BhDELp5r.js";const j="_card_1vaoq_2",v="_cardUnread_1vaoq_15",b="_cardRead_1vaoq_20",C="_topRow_1vaoq_25",T="_categoryChip_1vaoq_32",S="_versionChip_1vaoq_45",f="_date_1vaoq_57",k="_title_1vaoq_65",R="_body_1vaoq_74",q="_link_1vaoq_83",H="_newBadge_1vaoq_98",n={card:j,cardUnread:v,cardRead:b,topRow:C,categoryChip:T,versionChip:S,date:f,title:k,body:R,link:q,newBadge:H},E={release:"whatsNew.category.release",notice:"whatsNew.category.notice",deprecation:"whatsNew.category.deprecation",tip:"whatsNew.category.tip"};function y({announcement:s,isNew:d}){const{locale:i,t:c}=x(),o=d?n.cardUnread:n.cardRead,_=s.title[i]??s.title.en,l=s.body[i]??s.body.en,r=s.link?s.link.label[i]??s.link.label.en:null;return e.jsxs("div",{className:`${n.card} ${o}`,children:[e.jsxs("div",{className:n.topRow,children:[e.jsx("span",{className:n.categoryChip,children:c(E[s.category])}),s.version&&e.jsx("span",{className:n.versionChip,children:s.version}),d&&e.jsx("span",{className:n.newBadge,children:c("whatsNew.newBadge","NEW")}),e.jsx("span",{className:n.date,children:s.date})]}),e.jsx("h3",{className:n.title,children:_}),e.jsx("p",{className:n.body,children:l}),s.link&&r&&e.jsxs("a",{className:n.link,href:s.link.url,target:"_blank",rel:"noopener noreferrer",children:["β†—"," ",r]})]})}const U="_page_19yl3_2",A="_pageHeader_19yl3_10",B="_pageHeaderText_19yl3_17",I="_pageTitle_19yl3_24",$="_pageSubtitle_19yl3_31",L="_settingsIcon_19yl3_38",M="_section_19yl3_67",W="_sectionTitle_19yl3_73",z="_unreadCount_19yl3_85",O="_empty_19yl3_100",Y="_divider_19yl3_108",t={page:U,pageHeader:A,pageHeaderText:B,pageTitle:I,pageSubtitle:$,settingsIcon:L,section:M,sectionTitle:W,unreadCount:z,empty:O,divider:Y};function K(){const{t:s}=x(),{readSet:d,markRead:i}=u(),c=p.useMemo(()=>{const a=[];for(const N of h)d.has(N.id)||a.push(N.id);return a},[]),o=p.useRef(c);o.current=c,p.useEffect(()=>()=>{o.current.length>0&&i(o.current)},[]);const _=p.useMemo(()=>new Set(c),[c]),l=h.filter(a=>_.has(a.id)),r=l.length>0,g=e.jsxs("div",{className:t.pageHeader,children:[e.jsxs("div",{className:t.pageHeaderText,children:[e.jsx("h1",{className:t.pageTitle,children:s("whatsNew.pageTitle","What's New")}),e.jsx("p",{className:t.pageSubtitle,children:s("whatsNew.pageSubtitle","Stay up to date with MCP changes")})]}),e.jsx(w,{text:s("sidebar.settings","Settings"),children:e.jsx(m,{to:"/settings","aria-label":s("sidebar.settings","Settings"),className:t.settingsIcon,children:"βš™οΈ"})})]});return h.length===0?e.jsxs("div",{className:t.page,children:[g,e.jsx("p",{className:t.empty,children:s("whatsNew.empty","No announcements yet")})]}):e.jsxs("div",{className:t.page,children:[g,r&&e.jsxs("section",{className:t.section,children:[e.jsxs("h2",{className:t.sectionTitle,children:[s("whatsNew.unreadSection","Unread"),e.jsx("span",{className:t.unreadCount,children:l.length})]}),l.map(a=>e.jsx(y,{announcement:a,isNew:!0},`unread-${a.id}`))]}),r&&e.jsx("hr",{className:t.divider}),e.jsxs("section",{className:t.section,children:[e.jsx("h2",{className:t.sectionTitle,children:s("whatsNew.allSection","All Announcements")}),h.map(a=>e.jsx(y,{announcement:a,isNew:_.has(a.id)},`all-${a.id}`))]})]})}export{K as Component};
1
+ import{u as x,j as e,n as u,r as p,o as h,m as w,L as m}from"./index-BfvSPSNj.js";const j="_card_1vaoq_2",v="_cardUnread_1vaoq_15",b="_cardRead_1vaoq_20",C="_topRow_1vaoq_25",T="_categoryChip_1vaoq_32",S="_versionChip_1vaoq_45",f="_date_1vaoq_57",k="_title_1vaoq_65",R="_body_1vaoq_74",q="_link_1vaoq_83",H="_newBadge_1vaoq_98",n={card:j,cardUnread:v,cardRead:b,topRow:C,categoryChip:T,versionChip:S,date:f,title:k,body:R,link:q,newBadge:H},E={release:"whatsNew.category.release",notice:"whatsNew.category.notice",deprecation:"whatsNew.category.deprecation",tip:"whatsNew.category.tip"};function y({announcement:s,isNew:d}){const{locale:i,t:c}=x(),o=d?n.cardUnread:n.cardRead,_=s.title[i]??s.title.en,l=s.body[i]??s.body.en,r=s.link?s.link.label[i]??s.link.label.en:null;return e.jsxs("div",{className:`${n.card} ${o}`,children:[e.jsxs("div",{className:n.topRow,children:[e.jsx("span",{className:n.categoryChip,children:c(E[s.category])}),s.version&&e.jsx("span",{className:n.versionChip,children:s.version}),d&&e.jsx("span",{className:n.newBadge,children:c("whatsNew.newBadge","NEW")}),e.jsx("span",{className:n.date,children:s.date})]}),e.jsx("h3",{className:n.title,children:_}),e.jsx("p",{className:n.body,children:l}),s.link&&r&&e.jsxs("a",{className:n.link,href:s.link.url,target:"_blank",rel:"noopener noreferrer",children:["β†—"," ",r]})]})}const U="_page_19yl3_2",A="_pageHeader_19yl3_10",B="_pageHeaderText_19yl3_17",I="_pageTitle_19yl3_24",$="_pageSubtitle_19yl3_31",L="_settingsIcon_19yl3_38",M="_section_19yl3_67",W="_sectionTitle_19yl3_73",z="_unreadCount_19yl3_85",O="_empty_19yl3_100",Y="_divider_19yl3_108",t={page:U,pageHeader:A,pageHeaderText:B,pageTitle:I,pageSubtitle:$,settingsIcon:L,section:M,sectionTitle:W,unreadCount:z,empty:O,divider:Y};function K(){const{t:s}=x(),{readSet:d,markRead:i}=u(),c=p.useMemo(()=>{const a=[];for(const N of h)d.has(N.id)||a.push(N.id);return a},[]),o=p.useRef(c);o.current=c,p.useEffect(()=>()=>{o.current.length>0&&i(o.current)},[]);const _=p.useMemo(()=>new Set(c),[c]),l=h.filter(a=>_.has(a.id)),r=l.length>0,g=e.jsxs("div",{className:t.pageHeader,children:[e.jsxs("div",{className:t.pageHeaderText,children:[e.jsx("h1",{className:t.pageTitle,children:s("whatsNew.pageTitle","What's New")}),e.jsx("p",{className:t.pageSubtitle,children:s("whatsNew.pageSubtitle","Stay up to date with MCP changes")})]}),e.jsx(w,{text:s("sidebar.settings","Settings"),children:e.jsx(m,{to:"/settings","aria-label":s("sidebar.settings","Settings"),className:t.settingsIcon,children:"βš™οΈ"})})]});return h.length===0?e.jsxs("div",{className:t.page,children:[g,e.jsx("p",{className:t.empty,children:s("whatsNew.empty","No announcements yet")})]}):e.jsxs("div",{className:t.page,children:[g,r&&e.jsxs("section",{className:t.section,children:[e.jsxs("h2",{className:t.sectionTitle,children:[s("whatsNew.unreadSection","Unread"),e.jsx("span",{className:t.unreadCount,children:l.length})]}),l.map(a=>e.jsx(y,{announcement:a,isNew:!0},`unread-${a.id}`))]}),r&&e.jsx("hr",{className:t.divider}),e.jsxs("section",{className:t.section,children:[e.jsx("h2",{className:t.sectionTitle,children:s("whatsNew.allSection","All Announcements")}),h.map(a=>e.jsx(y,{announcement:a,isNew:_.has(a.id)},`all-${a.id}`))]})]})}export{K as Component};