@testver/testver 1.4.2 → 1.4.3

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 (89) hide show
  1. package/dist/index.js +1174 -800
  2. package/package.json +1 -1
  3. package/src/ui/static/assets/AIPanel-KQFq4c0Q.js +32 -0
  4. package/src/ui/static/assets/AIRecordPanel-CAs8fXyS.js +40 -0
  5. package/src/ui/static/assets/AIStreamUI-p_sMTEDQ.js +9 -0
  6. package/src/ui/static/assets/{AITestGenPage-D3t2gPAA.js → AITestGenPage-CHaHfmu4.js} +1 -1
  7. package/src/ui/static/assets/APITestingPage-BSGJY_hd.js +19 -0
  8. package/src/ui/static/assets/{AboutPage-CjEqKB-q.js → AboutPage-CDa24SCJ.js} +1 -1
  9. package/src/ui/static/assets/{AdvancedPage-4kAcpE8Y.js → AdvancedPage-BqXP0FLg.js} +1 -1
  10. package/src/ui/static/assets/{AnalyticsPage-64mYNK2v.js → AnalyticsPage-Lm8noJqC.js} +1 -1
  11. package/src/ui/static/assets/{AuditLogPage-BQjOzQje.js → AuditLogPage-BvldSIik.js} +1 -1
  12. package/src/ui/static/assets/ChangesSummary-Cu0_4Ucf.js +3 -0
  13. package/src/ui/static/assets/{CodeMapPage-B1ezmnlE.js → CodeMapPage-uEjuo3fk.js} +3 -3
  14. package/src/ui/static/assets/{ConfirmDialog-t7mpeeSN.js → ConfirmDialog-DtotgVmI.js} +1 -1
  15. package/src/ui/static/assets/{CoveragePage-YMmCbiBk.js → CoveragePage-jNkQJA1P.js} +1 -1
  16. package/src/ui/static/assets/{CronBuilder-Nk-K-_8I.js → CronBuilder-D2fERHt9.js} +1 -1
  17. package/src/ui/static/assets/{Dashboard-BDVxO2V4.js → Dashboard-BaIj_IdQ.js} +1 -1
  18. package/src/ui/static/assets/{DefectsPage-l8yGeCyR.js → DefectsPage-DH0njYFG.js} +3 -3
  19. package/src/ui/static/assets/{EmptyState-D1T3JWUr.js → EmptyState-utxlJ0fu.js} +1 -1
  20. package/src/ui/static/assets/{ExportButton-Dt5RhL-h.js → ExportButton-ouKqn9CU.js} +1 -1
  21. package/src/ui/static/assets/{FileViewer-CrKgh_cB.js → FileViewer-mU3JloJ6.js} +1 -1
  22. package/src/ui/static/assets/{GitPage-_4nCEzkJ.js → GitPage-TrX-RqNC.js} +5 -5
  23. package/src/ui/static/assets/{ImportExportPage-BcR7IQi9.js → ImportExportPage-CIhK_raX.js} +1 -1
  24. package/src/ui/static/assets/{JiraPushDialog-C2sP4_4h.js → JiraPushDialog-DgEZS-0u.js} +1 -1
  25. package/src/ui/static/assets/{KpiTile-inmeEsy3.js → KpiTile-BHLE3HVj.js} +1 -1
  26. package/src/ui/static/assets/{LiveExecutionView-D5BRe9jq.js → LiveExecutionView-CaIf7Jux.js} +1 -1
  27. package/src/ui/static/assets/{ManagePage-B8iG6Q0B.js → ManagePage-SvRQ6L19.js} +1 -1
  28. package/src/ui/static/assets/{MediaModal-C5n6sHYi.js → MediaModal-DNM45Uz2.js} +1 -1
  29. package/src/ui/static/assets/{MobileRunPicker-0h-N2c6d.js → MobileRunPicker-DFKm6_nU.js} +1 -1
  30. package/src/ui/static/assets/{MobileRunTarget-Bo_xekig.js → MobileRunTarget-DHDoDZ_F.js} +3 -3
  31. package/src/ui/static/assets/{ModuleExplorer-VGcmK167.js → ModuleExplorer-rni7JbsL.js} +1 -1
  32. package/src/ui/static/assets/{OutputPage-B_1nPPxE.js → OutputPage-Cn2WCpJ6.js} +1 -1
  33. package/src/ui/static/assets/{PipelinesPanel-PmmPu8pj.js → PipelinesPanel-D6zWcLtD.js} +1 -1
  34. package/src/ui/static/assets/{ProfilePage-y7tJNNFd.js → ProfilePage-BKNdkSnx.js} +1 -1
  35. package/src/ui/static/assets/{ProjectExplorer-DbfGhRq0.js → ProjectExplorer-5e7J8t-o.js} +1 -1
  36. package/src/ui/static/assets/{RemoteFileStrip-WuRKtx_h.js → RemoteFileStrip-C1S2aclP.js} +1 -1
  37. package/src/ui/static/assets/{ReportCard-G52Q6-2i.js → ReportCard-D4EElEe9.js} +2 -2
  38. package/src/ui/static/assets/{ReportFullView-Bt8UFP2J.js → ReportFullView-2w2ysKRg.js} +1 -1
  39. package/src/ui/static/assets/{ReportsPage-DMtDi73Q.js → ReportsPage-9Fx-IEwV.js} +2 -2
  40. package/src/ui/static/assets/{ResultsPage-BI9jpK2N.js → ResultsPage-DPkfGh-K.js} +1 -1
  41. package/src/ui/static/assets/{RunState-ifC4zi6M.js → RunState-CRuS_bC2.js} +1 -1
  42. package/src/ui/static/assets/{RunTargets-C7vpCbck.js → RunTargets-CPKBrefj.js} +1 -1
  43. package/src/ui/static/assets/{ScriptMappingPage-7vHuvhQw.js → ScriptMappingPage-C3K_uyf0.js} +1 -1
  44. package/src/ui/static/assets/{SearchableDevicePicker-BYxYJNWl.js → SearchableDevicePicker-DubIldKj.js} +1 -1
  45. package/src/ui/static/assets/{SettingsPage-DSISg7r7.js → SettingsPage-BuZrrlW2.js} +1 -1
  46. package/src/ui/static/assets/{SharedReportView-BOqKGJmR.js → SharedReportView-ig5hECRk.js} +1 -1
  47. package/src/ui/static/assets/{SourcesPage-CgqtYGBi.js → SourcesPage-BPkqRqkC.js} +1 -1
  48. package/src/ui/static/assets/{TestExplorerPage-gYLhCD4d.js → TestExplorerPage-C_jl93GR.js} +3 -3
  49. package/src/ui/static/assets/{TestManagementPage-wqYTKP7W.js → TestManagementPage-DJiWpCne.js} +2 -2
  50. package/src/ui/static/assets/{TestPlansPage-DOKX9p6z.js → TestPlansPage-G1lvK1C0.js} +3 -3
  51. package/src/ui/static/assets/{TestverCreditsDetail-cSW0SpNx.js → TestverCreditsDetail-BKpt4oLW.js} +1 -1
  52. package/src/ui/static/assets/{TestverCreditsRing-DpMzl3h7.js → TestverCreditsRing-CEBSy3w3.js} +1 -1
  53. package/src/ui/static/assets/{UncommittedDiffViewer-BxS0zi-p.js → UncommittedDiffViewer-FKvUZcRi.js} +2 -2
  54. package/src/ui/static/assets/{UserManagementPage-B5d0uDU_.js → UserManagementPage-gDGhaHE4.js} +3 -3
  55. package/src/ui/static/assets/{WorkflowsPage-Bk0DFnFS.js → WorkflowsPage-BACdnU-1.js} +1 -1
  56. package/src/ui/static/assets/{hiddenLlmProviders-CdhhNa5G.js → hiddenLlmProviders-DzwaR-b9.js} +1 -1
  57. package/src/ui/static/assets/index-D6sQYc_0.js +47 -0
  58. package/src/ui/static/assets/{index-DpQhqcHv.js → index-DLmlY2Ol.js} +1 -1
  59. package/src/ui/static/assets/index-aInN0yoR.css +1 -0
  60. package/src/ui/static/assets/{reportMeta-AKcU_qwq.js → reportMeta-3kxT7BIT.js} +1 -1
  61. package/src/ui/static/assets/{useChartTheme-BFz2QcND.js → useChartTheme-CTIe6M63.js} +1 -1
  62. package/src/ui/static/assets/{useDebouncedValue-BsHptIvX.js → useDebouncedValue-C9odz7b2.js} +1 -1
  63. package/src/ui/static/assets/{useFeatureFlags-DNkIctil.js → useFeatureFlags-DrhvBp0C.js} +1 -1
  64. package/src/ui/static/assets/{useJiraConnector-D5ysBBvz.js → useJiraConnector-Dwj69Rfh.js} +1 -1
  65. package/src/ui/static/assets/useOwnership-C1CmzcvJ.js +1 -0
  66. package/src/ui/static/assets/useSuites-V0AxZYex.js +1 -0
  67. package/src/ui/static/assets/{useTabParam-ChbOedP1.js → useTabParam-CyYAP90W.js} +1 -1
  68. package/src/ui/static/assets/{useTestExplorer-DT8frjCK.js → useTestExplorer-CUqC18DV.js} +1 -1
  69. package/src/ui/static/assets/{useTestLifecycle-OcwQaB1s.js → useTestLifecycle-C2S_vaX2.js} +1 -1
  70. package/src/ui/static/assets/{useTestManagement-Xm4Bcx3u.js → useTestManagement-DW6AW2mt.js} +2 -2
  71. package/src/ui/static/assets/{useTestResults-D5EwGIX9.js → useTestResults-yjH1aUy-.js} +1 -1
  72. package/src/ui/static/assets/{vendor-charts-DWFQlmCz.js → vendor-charts-By5uZ93z.js} +1 -1
  73. package/src/ui/static/assets/{vendor-flow-YGpC9U9I.js → vendor-flow-B61ZV-pm.js} +1 -1
  74. package/src/ui/static/assets/{vendor-icons-BKPiFyYV.js → vendor-icons-D_Dmmj8d.js} +277 -282
  75. package/src/ui/static/assets/vendor-query-DkZSMtfn.js +1 -0
  76. package/src/ui/static/assets/{vendor-quill-W-RoQfb6.js → vendor-quill-xJF2Jvjc.js} +1 -1
  77. package/src/ui/static/assets/{vendor-react-CTbHBddL.js → vendor-react-DOVfxdUy.js} +1 -1
  78. package/src/ui/static/index.html +5 -5
  79. package/src/ui/static/assets/AIPanel-B_R-CbrF.js +0 -32
  80. package/src/ui/static/assets/AIRecordPanel-BRQWIU5h.js +0 -40
  81. package/src/ui/static/assets/AIStreamUI-C3D989_6.js +0 -9
  82. package/src/ui/static/assets/APITestingPage-Cmwkiiys.js +0 -19
  83. package/src/ui/static/assets/ChangesSummary-CY_Vb27i.js +0 -2
  84. package/src/ui/static/assets/DiffViewer-BIU09a_i.js +0 -2
  85. package/src/ui/static/assets/index-BYVxKLrT.js +0 -47
  86. package/src/ui/static/assets/index-C2KJt7SI.css +0 -1
  87. package/src/ui/static/assets/useOwnership-U0AfKBRo.js +0 -1
  88. package/src/ui/static/assets/useSuites-DyfN9HVv.js +0 -1
  89. package/src/ui/static/assets/vendor-query-BrzmPFT3.js +0 -1
@@ -1 +1 @@
1
- import{r,j as e,b as q}from"./vendor-react-CTbHBddL.js";import{J as E,a0 as F,y as G,R as J,v as K,W as Q,ag as V}from"./vendor-icons-BKPiFyYV.js";const ee="No devices connected. Start an emulator or simulator in Settings → Connectors → Local Devices, or plug in a phone.";function te({devices:s,selectedId:o,onSelect:g,loading:i,disabled:b,onRefresh:a,placeholder:d="Select a device…",errorText:l,variant:x="runner",emptyText:O="No devices available for this provider."}){const[c,u]=r.useState(!1),[m,k]=r.useState(""),[Y,U]=r.useState(!1),[f,_]=r.useState(null),j=r.useRef(null),v=r.useRef(null),L=r.useRef(null);r.useEffect(()=>{c?setTimeout(()=>{var t;return(t=L.current)==null?void 0:t.focus()},30):k("")},[c]);const S=()=>{if(!v.current)return;const t=v.current.getBoundingClientRect(),p=384,n=window.innerHeight-t.bottom,D=t.top,P=n<p+16&&D>n;U(P),_({left:t.left,width:t.width,...P?{bottom:window.innerHeight-t.top+4}:{top:t.bottom+4}})},A=()=>{b||(c||S(),u(t=>!t))};r.useLayoutEffect(()=>{if(!c)return;const t=()=>S();return window.addEventListener("scroll",t,!0),window.addEventListener("resize",t),()=>{window.removeEventListener("scroll",t,!0),window.removeEventListener("resize",t)}},[c]),r.useEffect(()=>{if(!c)return;const t=p=>{j.current&&!j.current.contains(p.target)&&u(!1)};return document.addEventListener("mousedown",t),()=>document.removeEventListener("mousedown",t)},[c]);const h=r.useMemo(()=>s.find(t=>t.id===o)||null,[s,o]),{realMatches:N,simMatches:C}=r.useMemo(()=>{const t=m.trim().toLowerCase(),p=t?s.filter(n=>[n.name,n.os,n.manufacturer,n.platform].filter(Boolean).join(" ").toLowerCase().includes(t)):s;return{realMatches:p.filter(n=>n.realMobile),simMatches:p.filter(n=>!n.realMobile)}},[s,m]),y=N.length+C.length,B=x==="compact"?"h-8 px-2.5 text-xs gap-1.5 rounded-lg":"h-[42px] px-3 text-[15px] gap-2 rounded-lg",R="bg-white dark:bg-white/[0.04] border border-gray-200 dark:border-white/10",z="hover:border-gray-300 dark:hover:border-white/20",T="text-gray-800 dark:text-gray-200",w="text-gray-500",W=x==="compact"?"bg-white dark:bg-surface-1 border border-gray-200 dark:border-white/10 shadow-xl":"bg-surface-1 border border-white/10 shadow-xl shadow-black/40";return e.jsxs("div",{ref:j,className:"relative w-full min-w-0",children:[e.jsxs("div",{className:"flex items-center gap-1 min-w-0",children:[e.jsxs("button",{ref:v,type:"button",disabled:b,onClick:A,className:`${B} ${R} ${z} flex-1 min-w-0 flex items-center justify-between text-left transition-colors disabled:opacity-50 disabled:cursor-not-allowed`,title:h?$(h):d,children:[e.jsxs("span",{className:"flex items-center gap-1.5 min-w-0 flex-1",children:[e.jsx(E,{size:x==="compact"?11:12,className:`${w} flex-shrink-0`}),e.jsx("span",{className:`${T} truncate min-w-0 flex-1`,title:h?$(h):void 0,children:i?"Loading devices…":h?$(h):e.jsx("span",{className:w,children:d})})]}),i?e.jsx(F,{size:x==="compact"?11:12,className:`${w} animate-spin flex-shrink-0`}):e.jsx(G,{size:x==="compact"?11:12,className:`${w} flex-shrink-0 transition-transform ${c?"rotate-180":""}`})]}),a&&e.jsx("button",{type:"button",onClick:a,disabled:i||b,title:"Refresh device list",className:`${x==="compact"?"h-8 w-8 rounded-lg":"h-[42px] w-[42px] rounded-lg"} ${R} ${z} flex-shrink-0 flex items-center justify-center text-gray-500 hover:text-gray-700 dark:hover:text-gray-300 disabled:opacity-40 transition-colors`,children:e.jsx(J,{size:x==="compact"?12:13,className:i?"animate-spin":""})})]}),c&&f&&q.createPortal(e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"fixed inset-0 z-[60]",onClick:()=>u(!1)}),e.jsxs("div",{style:{position:"fixed",left:Math.max(8,Math.min(f.left,window.innerWidth-272-8)),width:x==="compact"?Math.max(f.width,272):f.width,top:f.top,bottom:f.bottom},className:`z-[70] ${W} rounded-lg flex flex-col overflow-hidden max-h-96`,onMouseDown:t=>t.stopPropagation(),children:[e.jsxs("div",{className:"px-2 py-2 border-b border-gray-200 dark:border-white/5 flex items-center gap-1.5 bg-white dark:bg-surface-1 sticky top-0",children:[e.jsx(K,{size:12,className:"text-gray-500 flex-shrink-0 ml-1"}),e.jsx("input",{ref:L,type:"text",value:m,onChange:t=>k(t.target.value),placeholder:"Search by name, OS, manufacturer…",className:"flex-1 bg-transparent border-0 outline-none text-xs text-gray-800 dark:text-gray-200 placeholder-gray-400 dark:placeholder-gray-600",onKeyDown:t=>{t.key==="Escape"&&(t.preventDefault(),u(!1))}}),m&&e.jsx("button",{type:"button",onClick:()=>k(""),className:"text-[10px] text-gray-500 hover:text-gray-700 dark:hover:text-gray-300 px-1.5",children:"Clear"})]}),e.jsxs("div",{className:"flex-1 overflow-y-auto py-1",children:[l&&e.jsx("div",{className:"px-3 py-2 text-xs text-red-300",children:l}),!l&&i&&s.length===0&&e.jsxs("div",{className:"flex items-center justify-center gap-1.5 px-3 py-4 text-xs text-gray-500",children:[e.jsx(F,{size:11,className:"animate-spin"}),"Fetching devices…"]}),!l&&!i&&y===0&&e.jsx("div",{className:"px-3 py-4 text-xs text-gray-500 text-center",children:m?e.jsxs(e.Fragment,{children:["No devices match ",e.jsxs("span",{className:"text-gray-300",children:["“",m,"”"]})]}):O}),N.length>0&&e.jsx(H,{title:"Real devices",icon:e.jsx(Q,{size:9,className:"text-emerald-400/80"}),devices:N,selectedId:o,onPick:t=>{g(t),u(!1)}}),C.length>0&&e.jsx(H,{title:"Emulators / Simulators",icon:e.jsx(E,{size:9,className:"text-gray-500"}),devices:C,selectedId:o,onPick:t=>{g(t),u(!1)}})]}),!i&&y>0&&e.jsx("div",{className:"px-3 py-1.5 border-t border-gray-200 dark:border-white/5 text-[10px] text-gray-500 bg-white dark:bg-surface-1",children:m?e.jsxs(e.Fragment,{children:[y," match",y===1?"":"es"," of ",s.length," devices"]}):e.jsxs(e.Fragment,{children:[s.length," device",s.length===1?"":"s"]})})]})]}),document.body)]})}function H({title:s,icon:o,devices:g,selectedId:i,onPick:b}){return e.jsxs("div",{children:[e.jsxs("div",{className:"px-3 pt-1.5 pb-0.5 flex items-center gap-1 text-[10px] uppercase tracking-wider text-gray-500 dark:text-gray-500 font-semibold",children:[o," ",s,e.jsx("span",{className:"ml-auto text-gray-400 dark:text-gray-600 normal-case font-normal",children:g.length})]}),g.map(a=>{const d=a.id===i,l=!!a.unavailableReason;return e.jsxs("button",{type:"button",disabled:l,onClick:()=>b(a),title:l?`${a.name} — ${a.unavailableReason}`:`${a.name} · ${M(a)}${a.manufacturer?" · "+a.manufacturer:""}${a.realMobile?" · real device":" · emulator/simulator"}`,className:`w-full text-left px-3 py-1.5 flex items-center gap-2 text-xs transition-colors ${l?"text-gray-400 dark:text-gray-600 cursor-not-allowed":d?"bg-indigo-50 dark:bg-indigo-500/15 text-indigo-700 dark:text-indigo-100":"text-gray-700 dark:text-gray-300 hover:bg-gray-50 dark:hover:bg-white/5"}`,children:[e.jsx(E,{size:11,className:d?"text-indigo-500 dark:text-indigo-300 flex-shrink-0":"text-gray-400 dark:text-gray-500 flex-shrink-0"}),e.jsxs("span",{className:"flex-1 truncate",children:[e.jsx("span",{className:"font-medium",children:a.name}),e.jsxs("span",{className:"text-gray-500 dark:text-gray-500",children:[" · ",M(a)]}),l?e.jsxs("span",{className:"text-amber-600 dark:text-amber-400 ml-1",children:["· ",a.unavailableReason]}):a.manufacturer&&a.manufacturer!==a.name.split(" ")[0]&&e.jsxs("span",{className:"text-gray-400 dark:text-gray-600 ml-1",children:["· ",a.manufacturer]})]}),d&&e.jsx(V,{size:11,className:"text-indigo-500 dark:text-indigo-300 flex-shrink-0"})]},a.id)})]})}function $(s){return`${s.name} · ${M(s)}${s.realMobile?"":" · sim"}`}function M(s){const o=s.platform==="ios"?"iOS":X(s.platform);return/^\d/.test(s.os)?`${o} ${s.os}`:o}function X(s){return s&&s.charAt(0).toUpperCase()+s.slice(1)}export{ee as L,te as S};
1
+ import{r,j as e,d as q}from"./vendor-react-DOVfxdUy.js";import{J as E,a0 as F,y as G,R as J,v as K,W as Q,ag as V}from"./vendor-icons-D_Dmmj8d.js";const ee="No devices connected. Start an emulator or simulator in Settings → Connectors → Local Devices, or plug in a phone.";function te({devices:s,selectedId:o,onSelect:g,loading:i,disabled:b,onRefresh:a,placeholder:d="Select a device…",errorText:l,variant:x="runner",emptyText:O="No devices available for this provider."}){const[c,u]=r.useState(!1),[m,k]=r.useState(""),[Y,U]=r.useState(!1),[f,_]=r.useState(null),j=r.useRef(null),v=r.useRef(null),L=r.useRef(null);r.useEffect(()=>{c?setTimeout(()=>{var t;return(t=L.current)==null?void 0:t.focus()},30):k("")},[c]);const S=()=>{if(!v.current)return;const t=v.current.getBoundingClientRect(),p=384,n=window.innerHeight-t.bottom,D=t.top,P=n<p+16&&D>n;U(P),_({left:t.left,width:t.width,...P?{bottom:window.innerHeight-t.top+4}:{top:t.bottom+4}})},A=()=>{b||(c||S(),u(t=>!t))};r.useLayoutEffect(()=>{if(!c)return;const t=()=>S();return window.addEventListener("scroll",t,!0),window.addEventListener("resize",t),()=>{window.removeEventListener("scroll",t,!0),window.removeEventListener("resize",t)}},[c]),r.useEffect(()=>{if(!c)return;const t=p=>{j.current&&!j.current.contains(p.target)&&u(!1)};return document.addEventListener("mousedown",t),()=>document.removeEventListener("mousedown",t)},[c]);const h=r.useMemo(()=>s.find(t=>t.id===o)||null,[s,o]),{realMatches:N,simMatches:C}=r.useMemo(()=>{const t=m.trim().toLowerCase(),p=t?s.filter(n=>[n.name,n.os,n.manufacturer,n.platform].filter(Boolean).join(" ").toLowerCase().includes(t)):s;return{realMatches:p.filter(n=>n.realMobile),simMatches:p.filter(n=>!n.realMobile)}},[s,m]),y=N.length+C.length,B=x==="compact"?"h-8 px-2.5 text-xs gap-1.5 rounded-lg":"h-[42px] px-3 text-[15px] gap-2 rounded-lg",R="bg-white dark:bg-white/[0.04] border border-gray-200 dark:border-white/10",z="hover:border-gray-300 dark:hover:border-white/20",T="text-gray-800 dark:text-gray-200",w="text-gray-500",W=x==="compact"?"bg-white dark:bg-surface-1 border border-gray-200 dark:border-white/10 shadow-xl":"bg-surface-1 border border-white/10 shadow-xl shadow-black/40";return e.jsxs("div",{ref:j,className:"relative w-full min-w-0",children:[e.jsxs("div",{className:"flex items-center gap-1 min-w-0",children:[e.jsxs("button",{ref:v,type:"button",disabled:b,onClick:A,className:`${B} ${R} ${z} flex-1 min-w-0 flex items-center justify-between text-left transition-colors disabled:opacity-50 disabled:cursor-not-allowed`,title:h?$(h):d,children:[e.jsxs("span",{className:"flex items-center gap-1.5 min-w-0 flex-1",children:[e.jsx(E,{size:x==="compact"?11:12,className:`${w} flex-shrink-0`}),e.jsx("span",{className:`${T} truncate min-w-0 flex-1`,title:h?$(h):void 0,children:i?"Loading devices…":h?$(h):e.jsx("span",{className:w,children:d})})]}),i?e.jsx(F,{size:x==="compact"?11:12,className:`${w} animate-spin flex-shrink-0`}):e.jsx(G,{size:x==="compact"?11:12,className:`${w} flex-shrink-0 transition-transform ${c?"rotate-180":""}`})]}),a&&e.jsx("button",{type:"button",onClick:a,disabled:i||b,title:"Refresh device list",className:`${x==="compact"?"h-8 w-8 rounded-lg":"h-[42px] w-[42px] rounded-lg"} ${R} ${z} flex-shrink-0 flex items-center justify-center text-gray-500 hover:text-gray-700 dark:hover:text-gray-300 disabled:opacity-40 transition-colors`,children:e.jsx(J,{size:x==="compact"?12:13,className:i?"animate-spin":""})})]}),c&&f&&q.createPortal(e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"fixed inset-0 z-[60]",onClick:()=>u(!1)}),e.jsxs("div",{style:{position:"fixed",left:Math.max(8,Math.min(f.left,window.innerWidth-272-8)),width:x==="compact"?Math.max(f.width,272):f.width,top:f.top,bottom:f.bottom},className:`z-[70] ${W} rounded-lg flex flex-col overflow-hidden max-h-96`,onMouseDown:t=>t.stopPropagation(),children:[e.jsxs("div",{className:"px-2 py-2 border-b border-gray-200 dark:border-white/5 flex items-center gap-1.5 bg-white dark:bg-surface-1 sticky top-0",children:[e.jsx(K,{size:12,className:"text-gray-500 flex-shrink-0 ml-1"}),e.jsx("input",{ref:L,type:"text",value:m,onChange:t=>k(t.target.value),placeholder:"Search by name, OS, manufacturer…",className:"flex-1 bg-transparent border-0 outline-none text-xs text-gray-800 dark:text-gray-200 placeholder-gray-400 dark:placeholder-gray-600",onKeyDown:t=>{t.key==="Escape"&&(t.preventDefault(),u(!1))}}),m&&e.jsx("button",{type:"button",onClick:()=>k(""),className:"text-[10px] text-gray-500 hover:text-gray-700 dark:hover:text-gray-300 px-1.5",children:"Clear"})]}),e.jsxs("div",{className:"flex-1 overflow-y-auto py-1",children:[l&&e.jsx("div",{className:"px-3 py-2 text-xs text-red-300",children:l}),!l&&i&&s.length===0&&e.jsxs("div",{className:"flex items-center justify-center gap-1.5 px-3 py-4 text-xs text-gray-500",children:[e.jsx(F,{size:11,className:"animate-spin"}),"Fetching devices…"]}),!l&&!i&&y===0&&e.jsx("div",{className:"px-3 py-4 text-xs text-gray-500 text-center",children:m?e.jsxs(e.Fragment,{children:["No devices match ",e.jsxs("span",{className:"text-gray-300",children:["“",m,"”"]})]}):O}),N.length>0&&e.jsx(H,{title:"Real devices",icon:e.jsx(Q,{size:9,className:"text-emerald-400/80"}),devices:N,selectedId:o,onPick:t=>{g(t),u(!1)}}),C.length>0&&e.jsx(H,{title:"Emulators / Simulators",icon:e.jsx(E,{size:9,className:"text-gray-500"}),devices:C,selectedId:o,onPick:t=>{g(t),u(!1)}})]}),!i&&y>0&&e.jsx("div",{className:"px-3 py-1.5 border-t border-gray-200 dark:border-white/5 text-[10px] text-gray-500 bg-white dark:bg-surface-1",children:m?e.jsxs(e.Fragment,{children:[y," match",y===1?"":"es"," of ",s.length," devices"]}):e.jsxs(e.Fragment,{children:[s.length," device",s.length===1?"":"s"]})})]})]}),document.body)]})}function H({title:s,icon:o,devices:g,selectedId:i,onPick:b}){return e.jsxs("div",{children:[e.jsxs("div",{className:"px-3 pt-1.5 pb-0.5 flex items-center gap-1 text-[10px] uppercase tracking-wider text-gray-500 dark:text-gray-500 font-semibold",children:[o," ",s,e.jsx("span",{className:"ml-auto text-gray-400 dark:text-gray-600 normal-case font-normal",children:g.length})]}),g.map(a=>{const d=a.id===i,l=!!a.unavailableReason;return e.jsxs("button",{type:"button",disabled:l,onClick:()=>b(a),title:l?`${a.name} — ${a.unavailableReason}`:`${a.name} · ${M(a)}${a.manufacturer?" · "+a.manufacturer:""}${a.realMobile?" · real device":" · emulator/simulator"}`,className:`w-full text-left px-3 py-1.5 flex items-center gap-2 text-xs transition-colors ${l?"text-gray-400 dark:text-gray-600 cursor-not-allowed":d?"bg-indigo-50 dark:bg-indigo-500/15 text-indigo-700 dark:text-indigo-100":"text-gray-700 dark:text-gray-300 hover:bg-gray-50 dark:hover:bg-white/5"}`,children:[e.jsx(E,{size:11,className:d?"text-indigo-500 dark:text-indigo-300 flex-shrink-0":"text-gray-400 dark:text-gray-500 flex-shrink-0"}),e.jsxs("span",{className:"flex-1 truncate",children:[e.jsx("span",{className:"font-medium",children:a.name}),e.jsxs("span",{className:"text-gray-500 dark:text-gray-500",children:[" · ",M(a)]}),l?e.jsxs("span",{className:"text-amber-600 dark:text-amber-400 ml-1",children:["· ",a.unavailableReason]}):a.manufacturer&&a.manufacturer!==a.name.split(" ")[0]&&e.jsxs("span",{className:"text-gray-400 dark:text-gray-600 ml-1",children:["· ",a.manufacturer]})]}),d&&e.jsx(V,{size:11,className:"text-indigo-500 dark:text-indigo-300 flex-shrink-0"})]},a.id)})]})}function $(s){return`${s.name} · ${M(s)}${s.realMobile?"":" · sim"}`}function M(s){const o=s.platform==="ios"?"iOS":X(s.platform);return/^\d/.test(s.os)?`${o} ${s.os}`:o}function X(s){return s&&s.charAt(0).toUpperCase()+s.slice(1)}export{ee as L,te as S};
@@ -1,4 +1,4 @@
1
- import{r as n,j as e,b as fe,L as os,n as Zt,R as er,u as sr}from"./vendor-react-CTbHBddL.js";import{a as Ct}from"./formatDate-T65-Y6Mi.js";import{a as Je,u as Ge,c as Ze}from"./vendor-query-BrzmPFT3.js";import{b as ge,a4 as tr,d0 as rr,a3 as ar,d1 as nr,bS as St,d2 as lr,h as or,P as ir,d3 as dr,d4 as cr,d5 as xr,a8 as ws,a5 as mr,d6 as ur,d7 as Es,d8 as hr,d9 as pr,da as gr,db as br,dc as fr,dd as yr,de as jr,df as vr,a6 as Nr,dg as wr,dh as kr,di as Cr,dj as Sr,aj as Tr,dk as st,dl as Ar,dm as zr,dn as Er,dp as Pr,dq as Lr,dr as $r,ds as Rr,dt as Mr,du as Dr,dv as Fr,j as Qs,dw as Ir,dx as ms,dy as Or,dz as Ur,dA as Br,dB as Kr,dC as _r,dD as Hr,dE as Tt,dF as Vr,dG as Gr,dH as Wr,dI as qr,dJ as Jr,dK as Qr,x as ks,dL as Yr,dM as Xr,dN as Zr,dO as ea,dP as sa,y as At,dQ as ta,dR as ra,dS as aa,dT as na,S as la,X as oa,dU as ia,dV as da,dW as ca,v as xa,dX as ma,dY as tt,a7 as ua,dZ as rt,d_ as ha,d$ as pa,e0 as ga,e1 as ba,e2 as fa,e3 as at,e4 as nt,bR as lt,d as ya,e5 as ot,e6 as it,e7 as ja,e8 as va,e9 as Na,ea as wa,eb as ka,ec as Ca,ed as Sa,ee as Ta,ef as Aa}from"./index-BYVxKLrT.js";import{G as za,o as ue,r as ne,bC as zt,aJ as Ea,ci as Pa,aS as ts,aa as ve,X as me,a0 as J,b0 as Et,bd as bs,g as dt,d as La,k as ze,S as Te,v as Ks,b4 as je,an as fs,b7 as we,bO as $a,y as Me,bl as Ys,cH as ys,cI as We,a5 as Pt,bK as Lt,Z as Ee,bt as Ra,Q as js,ag as Ue,a7 as Pe,l as Qe,ap as Se,P as ct,j as Ma,cJ as $t,b6 as Cs,t as Ie,bx as Rt,_ as Ss,a as Ts,K as cs,c9 as Da,N as Fa,cK as Ia,a6 as _s,$ as Oa,bw as Ua,cL as Ba,cM as Ka,au as _a,a1 as Ha,cN as Va,cO as Ga,e as Wa,ac as Mt,aC as qa,J as Oe,cP as Ja,R as $e,F as rs,c as As,cQ as vs,bJ as Qa,a9 as is,az as Ya,bZ as Xa,cR as Ve,cS as Hs,u as zs,cT as qe,b9 as ds,by as Za,cU as Vs,ah as xs,b8 as Ns,a2 as Xs,at as Dt,c8 as en,c7 as sn,h as as,I as Ps,aB as tn,cV as rn,aF as an,b2 as Ft,ck as nn,cW as xt,b5 as gs,cX as ln,ch as on,U as dn,al as cn}from"./vendor-icons-BKPiFyYV.js";import{u as mt}from"./useTabParam-ChbOedP1.js";import{B as xn,a as ns}from"./RunTargets-C7vpCbck.js";import{r as It}from"./simpleMarkdown-kWs-10D8.js";import{s as mn}from"./visibleInterval-BKsLfJZ3.js";import{u as un}from"./useFeatureFlags-DNkIctil.js";import{C as Ot}from"./ConfirmDialog-t7mpeeSN.js";import{H as hn,P as pn}from"./hiddenLlmProviders-CdhhNa5G.js";import{h as Ls}from"./aiHandoff-vhtR29Fh.js";import{u as gn,c as bn,d as fn,e as yn,f as jn}from"./useOwnership-U0AfKBRo.js";import{u as vn,b as Nn}from"./TestverCreditsRing-DpMzl3h7.js";import{T as wn}from"./TestverCreditsDetail-cSW0SpNx.js";const kn=[[0,"Off"],[5,"Every 5 min"],[15,"Every 15 min"],[60,"Every hour"]];function us({on:s,onChange:t,label:a}){return e.jsx("button",{role:"switch","aria-checked":s,"aria-label":a,onClick:()=>t(!s),className:`relative inline-flex h-5 w-9 flex-shrink-0 items-center rounded-full transition-colors mt-1 disabled:opacity-50 ${s?"bg-brand-500":"bg-surface-3"}`,children:e.jsx("span",{className:`inline-block h-3.5 w-3.5 transform rounded-full bg-white transition-transform ${s?"translate-x-4":"translate-x-1"}`})})}function Cn(){const{toast:s}=ge(),t=Je(),a=tr(),{data:l}=Ge({queryKey:["git-status"],queryFn:rr,staleTime:3e4}),m=l!==void 0&&l.available!==!0,{data:i}=ar(a),h=nr(),[d,f]=n.useState(null),[g,y]=n.useState(""),[c,j]=n.useState("1"),{data:p}=Ge({queryKey:["connectors"],queryFn:St,staleTime:6e4}),u=Array.isArray(p)?p:(p==null?void 0:p.connectors)??[],b=u.filter(v=>v.type==="slack"&&v.status==="connected"),z=u.filter(v=>v.type==="email"&&v.status==="connected"),M=n.useCallback(()=>{lr().then(v=>{f(v),y(v.emailRecipients.join(", ")),j(String(v.notifyMinCommits))}).catch(()=>{})},[]);n.useEffect(()=>{M()},[M]);const V=(v,x)=>{f(o=>o&&{...o,...v}),xr(v).then(o=>{f(o),y(o.emailRecipients.join(", ")),j(String(o.notifyMinCommits)),t.invalidateQueries({queryKey:["git-remote-updates"]}),s("success",x??"Remote updates saved")}).catch(o=>{s("error",`Could not save: ${o.message}`),M()})};if(!d)return null;const U=i==null?void 0:i.check,O=or(U),S=()=>{const v=g.split(/[\s,;]+/).map(x=>x.trim()).filter(Boolean);v.join(",")!==d.emailRecipients.join(",")&&V({emailRecipients:v},"Recipients saved")},I=()=>{const v=Math.round(Number(c));if(!Number.isFinite(v)||v<1||v>100){j(String(d.notifyMinCommits)),s("error","Use a number from 1 to 100");return}v!==d.notifyMinCommits&&V({notifyMinCommits:v})},w=(v,x,o)=>e.jsxs("div",{className:"flex items-start justify-between gap-4",children:[e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-medium text-gray-200",children:v}),e.jsx("p",{className:"text-sm text-gray-500 mt-1 max-w-xl",children:x})]}),o]});return e.jsxs("div",{className:"bg-surface-1 rounded-xl border border-white/5 p-6 space-y-5",children:[e.jsxs("div",{children:[e.jsxs("h2",{className:"text-base font-semibold text-gray-200 flex items-center gap-2.5",children:[e.jsx(za,{size:18,className:"text-sky-500"}),"Remote updates",e.jsx("span",{className:"text-[11px] font-medium px-2 py-0.5 rounded-full bg-sky-500/10 text-sky-500 border border-sky-500/20",title:"These settings apply only when the project is a Git repository",children:"Git projects only"})]}),e.jsx("p",{className:"text-sm text-gray-500 mt-1.5 max-w-2xl",children:"For projects kept in a Git repository: Testver checks the remote (GitHub, GitLab, Bitbucket, Azure DevOps or any git server) for new commits on the branch this server is on, tells you before they surprise you, and predicts whether pulling them will conflict with local work. A check only downloads — your files never change until someone pulls."})]}),m&&e.jsxs("div",{className:"flex items-start gap-2 rounded-lg border border-amber-500/20 bg-amber-500/5 px-3.5 py-2.5 text-sm text-gray-400",children:[e.jsx(ue,{size:14,className:"mt-0.5 flex-shrink-0 text-amber-500"}),e.jsxs("span",{children:[e.jsx("b",{className:"text-gray-300",children:"This project isn't a Git repository"}),", so there is nothing to check. These settings take effect once it is — for example after you clone the project with git, or set it up on the Git page."]})]}),a&&U&&e.jsxs("div",{className:"flex items-start gap-2 rounded-lg border border-white/10 bg-surface-2/40 px-3.5 py-2.5 text-sm text-gray-400",children:[U.ok?e.jsx(ne,{size:14,className:"mt-0.5 flex-shrink-0 text-emerald-500"}):e.jsx(ue,{size:14,className:"mt-0.5 flex-shrink-0 text-amber-500"}),e.jsxs("span",{children:["Last check ",ir(U.checkedAt),":"," ",U.skipped?e.jsxs("b",{className:"text-gray-300",children:["nothing to check (",U.skipped==="unpublished"?"the branch isn't published":U.skipped==="detached"?"not on a branch":U.skipped==="operation"?"a merge or rebase is in progress":"no remote",")"]}):U.ok?U.behind>0?e.jsxs("b",{className:"text-gray-300",children:[U.upstream," has ",dr(U.behind,"new commit")]}):e.jsxs("b",{className:"text-gray-300",children:["up to date with ",U.upstream]}):e.jsxs("b",{className:"text-gray-300",children:["couldn't reach ",O]}),i!=null&&i.nextCheckAt?e.jsxs(e.Fragment,{children:[" · next check ",cr(i.nextCheckAt)]}):null," · ",e.jsx("button",{onClick:()=>h.mutate(void 0,{onError:v=>s("error",v.message)}),className:"text-sky-600 hover:underline",disabled:h.isPending,children:h.isPending?"Checking…":"Check now"})]})]}),w("Check for new commits","How often to look. Checks pause while a merge or rebase is in progress and on branches that aren't published.",e.jsx("div",{role:"group",className:"inline-flex rounded-lg border border-white/10 bg-white dark:bg-surface-2 overflow-hidden flex-shrink-0",children:kn.map(([v,x],o)=>e.jsx("button",{onClick:()=>v!==d.intervalMinutes&&V({intervalMinutes:v},v?`Checks every ${v===60?"hour":`${v} minutes`}`:"Remote checks turned off"),className:`px-3.5 py-1.5 text-sm font-medium transition-colors ${o?"border-l border-white/10":""} ${d.intervalMinutes===v?"bg-sky-500/15 text-sky-700 dark:text-sky-300":"text-gray-500 hover:text-gray-300 hover:bg-white/5"}`,children:x},v))})),e.jsx("div",{className:"border-t border-white/5"}),w("Warn before test runs","When the branch is behind, a run first asks “Pull, then run / Run anyway” — and says which incoming commits change files the tests use.",e.jsx(us,{on:d.warnBeforeRuns,label:"Warn before test runs",onChange:v=>V({warnBeforeRuns:v})})),w("Tell the AI Assistant","The assistant mentions when a file it is working on is newer on the remote.",e.jsx(us,{on:d.tellAI,label:"Tell the AI Assistant",onChange:v=>V({tellAI:v})})),e.jsx("div",{className:"border-t border-white/5"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-medium text-gray-200",children:"Notifications"}),e.jsx("p",{className:"text-sm text-gray-500 mt-1 max-w-xl",children:"Sent once per new set of commits that meets the rule below. The Git page, the header and the sidebar always show new commits."}),e.jsxs("div",{className:"mt-3 space-y-3",children:[e.jsxs("div",{className:"flex items-center gap-3 flex-wrap",children:[e.jsx(us,{on:d.emailEnabled,label:"E-mail notifications",onChange:v=>V({emailEnabled:v})}),e.jsx(zt,{size:15,className:"text-gray-500"}),e.jsx("span",{className:"text-sm text-gray-300 w-20",children:"Email"}),e.jsx("input",{value:g,onChange:v=>y(v.target.value),onBlur:S,onKeyDown:v=>{v.key==="Enter"&&S()},placeholder:"qa-team@example.com, lead@example.com",className:"flex-1 min-w-[16rem] bg-surface-2 border border-white/10 rounded-lg px-3 py-1.5 text-sm text-gray-200 focus:outline-none focus:border-sky-500/50"})]}),d.emailEnabled&&z.length===0&&e.jsx("p",{className:"text-xs text-amber-600 dark:text-amber-400 ml-12",children:"No e-mail connector is connected — add one in Connectors, or nothing can be sent."}),e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx(us,{on:d.slackEnabled,label:"Slack notifications",onChange:v=>V({slackEnabled:v})}),e.jsx(Ea,{size:15,className:"text-gray-500"}),e.jsx("span",{className:"text-sm text-gray-300 w-20",children:"Slack"}),e.jsx("span",{className:"flex-1 text-sm text-gray-400",children:b.length===0?"No Slack connector is connected — add one in Connectors.":e.jsxs(e.Fragment,{children:["Posts to ",b.map((v,x)=>{var o;return e.jsxs("b",{className:"text-gray-300",children:[x?", ":"",(o=v.config)!=null&&o.channel?`#${String(v.config.channel).replace(/^#/,"")}`:v.name||"Slack"]},v.id??x)})]})})]}),e.jsxs("div",{className:"flex items-start gap-3 flex-wrap",children:[e.jsx("span",{className:"w-9"}),e.jsx(Pa,{size:15,className:"text-gray-500 mt-1.5"}),e.jsx("span",{className:"text-sm text-gray-300 w-20 mt-1",children:"Notify when"}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs("div",{className:"flex items-center gap-2 text-sm text-gray-300",children:["At least",e.jsx("input",{value:c,onChange:v=>j(v.target.value.replace(/[^\d]/g,"")),onBlur:I,onKeyDown:v=>{v.key==="Enter"&&I()},inputMode:"numeric","aria-label":"Minimum new commits",className:"w-16 bg-surface-2 border border-white/10 rounded-lg px-2 py-1.5 text-sm text-gray-200 text-center focus:outline-none focus:border-sky-500/50"}),"new commit(s)"]}),e.jsxs("label",{className:"flex items-center gap-2 text-sm text-gray-400",children:[e.jsx("input",{type:"checkbox",checked:d.notifyOnlyRisky,onChange:v=>V({notifyOnlyRisky:v.target.checked}),className:"rounded border-white/20"}),"Only when pulling would conflict or touch uncommitted work"]})]})]})]})]})]})}const ut=s=>`---
1
+ import{r as n,j as e,d as fe,L as os,n as Zt,R as er,u as sr}from"./vendor-react-DOVfxdUy.js";import{a as Ct}from"./formatDate-T65-Y6Mi.js";import{a as Je,u as Ge,c as Ze}from"./vendor-query-DkZSMtfn.js";import{b as ge,aa as tr,db as rr,a9 as ar,dc as nr,c1 as St,dd as lr,h as or,P as ir,de as dr,df as cr,dg as xr,ae as ws,ab as mr,dh as ur,di as Es,dj as hr,dk as pr,dl as gr,dm as br,dn as fr,dp as yr,dq as jr,dr as vr,ac as Nr,ds as wr,dt as kr,du as Cr,dv as Sr,at as Tr,dw as st,dx as Ar,dy as zr,dz as Er,dA as Pr,dB as Lr,dC as $r,dD as Rr,dE as Mr,dF as Dr,dG as Fr,j as Qs,dH as Ir,dI as ms,dJ as Or,dK as Ur,dL as Br,dM as Kr,dN as _r,dO as Hr,dP as Tt,dQ as Vr,dR as Gr,dS as Wr,dT as qr,dU as Jr,dV as Qr,x as ks,dW as Yr,dX as Xr,dY as Zr,dZ as ea,d_ as sa,y as At,d$ as ta,e0 as ra,e1 as aa,e2 as na,S as la,X as oa,e3 as ia,e4 as da,bO as ca,v as xa,e5 as ma,e6 as tt,ad as ua,e7 as rt,e8 as ha,e9 as pa,ea as ga,eb as ba,ec as fa,ed as at,ee as nt,c0 as lt,d as ya,ef as ot,eg as it,eh as ja,ei as va,ej as Na,ek as wa,el as ka,em as Ca,en as Sa,eo as Ta,ep as Aa}from"./index-D6sQYc_0.js";import{G as za,o as ue,r as ne,bC as zt,aJ as Ea,ci as Pa,aS as ts,aa as ve,X as me,a0 as J,b0 as Et,bd as bs,i as dt,f as La,C as ze,S as Te,v as Ks,b4 as je,an as fs,b7 as we,bO as $a,y as Me,bl as Ys,cH as ys,cI as We,a5 as Pt,bK as Lt,Z as Ee,bt as Ra,Q as js,ag as Ue,a7 as Pe,a as Qe,ap as Se,P as ct,l as Ma,cJ as $t,b6 as Cs,t as Ie,bx as Rt,_ as Ss,c as Ts,K as cs,c9 as Da,N as Fa,cK as Ia,a6 as _s,$ as Oa,bw as Ua,cL as Ba,cM as Ka,au as _a,a1 as Ha,cN as Va,cO as Ga,g as Wa,ac as Mt,aC as qa,J as Oe,cP as Ja,R as $e,F as rs,e as As,cQ as vs,bJ as Qa,a9 as is,az as Ya,bZ as Xa,cR as Ve,cS as Hs,u as zs,cT as qe,b9 as ds,by as Za,cU as Vs,ah as xs,b8 as Ns,a2 as Xs,at as Dt,c8 as en,c7 as sn,j as as,I as Ps,aB as tn,cV as rn,aF as an,b2 as Ft,ck as nn,cW as xt,b5 as gs,cX as ln,ch as on,U as dn,al as cn}from"./vendor-icons-D_Dmmj8d.js";import{u as mt}from"./useTabParam-CyYAP90W.js";import{B as xn,a as ns}from"./RunTargets-CPKBrefj.js";import{r as It}from"./simpleMarkdown-kWs-10D8.js";import{s as mn}from"./visibleInterval-BKsLfJZ3.js";import{u as un}from"./useFeatureFlags-DrhvBp0C.js";import{C as Ot}from"./ConfirmDialog-DtotgVmI.js";import{H as hn,P as pn}from"./hiddenLlmProviders-DzwaR-b9.js";import{h as Ls}from"./aiHandoff-vhtR29Fh.js";import{u as gn,c as bn,d as fn,e as yn,f as jn}from"./useOwnership-C1CmzcvJ.js";import{u as vn,b as Nn}from"./TestverCreditsRing-CEBSy3w3.js";import{T as wn}from"./TestverCreditsDetail-BKpt4oLW.js";const kn=[[0,"Off"],[5,"Every 5 min"],[15,"Every 15 min"],[60,"Every hour"]];function us({on:s,onChange:t,label:a}){return e.jsx("button",{role:"switch","aria-checked":s,"aria-label":a,onClick:()=>t(!s),className:`relative inline-flex h-5 w-9 flex-shrink-0 items-center rounded-full transition-colors mt-1 disabled:opacity-50 ${s?"bg-brand-500":"bg-surface-3"}`,children:e.jsx("span",{className:`inline-block h-3.5 w-3.5 transform rounded-full bg-white transition-transform ${s?"translate-x-4":"translate-x-1"}`})})}function Cn(){const{toast:s}=ge(),t=Je(),a=tr(),{data:l}=Ge({queryKey:["git-status"],queryFn:rr,staleTime:3e4}),m=l!==void 0&&l.available!==!0,{data:i}=ar(a),h=nr(),[d,f]=n.useState(null),[g,y]=n.useState(""),[c,j]=n.useState("1"),{data:p}=Ge({queryKey:["connectors"],queryFn:St,staleTime:6e4}),u=Array.isArray(p)?p:(p==null?void 0:p.connectors)??[],b=u.filter(v=>v.type==="slack"&&v.status==="connected"),z=u.filter(v=>v.type==="email"&&v.status==="connected"),M=n.useCallback(()=>{lr().then(v=>{f(v),y(v.emailRecipients.join(", ")),j(String(v.notifyMinCommits))}).catch(()=>{})},[]);n.useEffect(()=>{M()},[M]);const V=(v,x)=>{f(o=>o&&{...o,...v}),xr(v).then(o=>{f(o),y(o.emailRecipients.join(", ")),j(String(o.notifyMinCommits)),t.invalidateQueries({queryKey:["git-remote-updates"]}),s("success",x??"Remote updates saved")}).catch(o=>{s("error",`Could not save: ${o.message}`),M()})};if(!d)return null;const U=i==null?void 0:i.check,O=or(U),S=()=>{const v=g.split(/[\s,;]+/).map(x=>x.trim()).filter(Boolean);v.join(",")!==d.emailRecipients.join(",")&&V({emailRecipients:v},"Recipients saved")},I=()=>{const v=Math.round(Number(c));if(!Number.isFinite(v)||v<1||v>100){j(String(d.notifyMinCommits)),s("error","Use a number from 1 to 100");return}v!==d.notifyMinCommits&&V({notifyMinCommits:v})},w=(v,x,o)=>e.jsxs("div",{className:"flex items-start justify-between gap-4",children:[e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-medium text-gray-200",children:v}),e.jsx("p",{className:"text-sm text-gray-500 mt-1 max-w-xl",children:x})]}),o]});return e.jsxs("div",{className:"bg-surface-1 rounded-xl border border-white/5 p-6 space-y-5",children:[e.jsxs("div",{children:[e.jsxs("h2",{className:"text-base font-semibold text-gray-200 flex items-center gap-2.5",children:[e.jsx(za,{size:18,className:"text-sky-500"}),"Remote updates",e.jsx("span",{className:"text-[11px] font-medium px-2 py-0.5 rounded-full bg-sky-500/10 text-sky-500 border border-sky-500/20",title:"These settings apply only when the project is a Git repository",children:"Git projects only"})]}),e.jsx("p",{className:"text-sm text-gray-500 mt-1.5 max-w-2xl",children:"For projects kept in a Git repository: Testver checks the remote (GitHub, GitLab, Bitbucket, Azure DevOps or any git server) for new commits on the branch this server is on, tells you before they surprise you, and predicts whether pulling them will conflict with local work. A check only downloads — your files never change until someone pulls."})]}),m&&e.jsxs("div",{className:"flex items-start gap-2 rounded-lg border border-amber-500/20 bg-amber-500/5 px-3.5 py-2.5 text-sm text-gray-400",children:[e.jsx(ue,{size:14,className:"mt-0.5 flex-shrink-0 text-amber-500"}),e.jsxs("span",{children:[e.jsx("b",{className:"text-gray-300",children:"This project isn't a Git repository"}),", so there is nothing to check. These settings take effect once it is — for example after you clone the project with git, or set it up on the Git page."]})]}),a&&U&&e.jsxs("div",{className:"flex items-start gap-2 rounded-lg border border-white/10 bg-surface-2/40 px-3.5 py-2.5 text-sm text-gray-400",children:[U.ok?e.jsx(ne,{size:14,className:"mt-0.5 flex-shrink-0 text-emerald-500"}):e.jsx(ue,{size:14,className:"mt-0.5 flex-shrink-0 text-amber-500"}),e.jsxs("span",{children:["Last check ",ir(U.checkedAt),":"," ",U.skipped?e.jsxs("b",{className:"text-gray-300",children:["nothing to check (",U.skipped==="unpublished"?"the branch isn't published":U.skipped==="detached"?"not on a branch":U.skipped==="operation"?"a merge or rebase is in progress":"no remote",")"]}):U.ok?U.behind>0?e.jsxs("b",{className:"text-gray-300",children:[U.upstream," has ",dr(U.behind,"new commit")]}):e.jsxs("b",{className:"text-gray-300",children:["up to date with ",U.upstream]}):e.jsxs("b",{className:"text-gray-300",children:["couldn't reach ",O]}),i!=null&&i.nextCheckAt?e.jsxs(e.Fragment,{children:[" · next check ",cr(i.nextCheckAt)]}):null," · ",e.jsx("button",{onClick:()=>h.mutate(void 0,{onError:v=>s("error",v.message)}),className:"text-sky-600 hover:underline",disabled:h.isPending,children:h.isPending?"Checking…":"Check now"})]})]}),w("Check for new commits","How often to look. Checks pause while a merge or rebase is in progress and on branches that aren't published.",e.jsx("div",{role:"group",className:"inline-flex rounded-lg border border-white/10 bg-white dark:bg-surface-2 overflow-hidden flex-shrink-0",children:kn.map(([v,x],o)=>e.jsx("button",{onClick:()=>v!==d.intervalMinutes&&V({intervalMinutes:v},v?`Checks every ${v===60?"hour":`${v} minutes`}`:"Remote checks turned off"),className:`px-3.5 py-1.5 text-sm font-medium transition-colors ${o?"border-l border-white/10":""} ${d.intervalMinutes===v?"bg-sky-500/15 text-sky-700 dark:text-sky-300":"text-gray-500 hover:text-gray-300 hover:bg-white/5"}`,children:x},v))})),e.jsx("div",{className:"border-t border-white/5"}),w("Warn before test runs","When the branch is behind, a run first asks “Pull, then run / Run anyway” — and says which incoming commits change files the tests use.",e.jsx(us,{on:d.warnBeforeRuns,label:"Warn before test runs",onChange:v=>V({warnBeforeRuns:v})})),w("Tell the AI Assistant","The assistant mentions when a file it is working on is newer on the remote.",e.jsx(us,{on:d.tellAI,label:"Tell the AI Assistant",onChange:v=>V({tellAI:v})})),e.jsx("div",{className:"border-t border-white/5"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-medium text-gray-200",children:"Notifications"}),e.jsx("p",{className:"text-sm text-gray-500 mt-1 max-w-xl",children:"Sent once per new set of commits that meets the rule below. The Git page, the header and the sidebar always show new commits."}),e.jsxs("div",{className:"mt-3 space-y-3",children:[e.jsxs("div",{className:"flex items-center gap-3 flex-wrap",children:[e.jsx(us,{on:d.emailEnabled,label:"E-mail notifications",onChange:v=>V({emailEnabled:v})}),e.jsx(zt,{size:15,className:"text-gray-500"}),e.jsx("span",{className:"text-sm text-gray-300 w-20",children:"Email"}),e.jsx("input",{value:g,onChange:v=>y(v.target.value),onBlur:S,onKeyDown:v=>{v.key==="Enter"&&S()},placeholder:"qa-team@example.com, lead@example.com",className:"flex-1 min-w-[16rem] bg-surface-2 border border-white/10 rounded-lg px-3 py-1.5 text-sm text-gray-200 focus:outline-none focus:border-sky-500/50"})]}),d.emailEnabled&&z.length===0&&e.jsx("p",{className:"text-xs text-amber-600 dark:text-amber-400 ml-12",children:"No e-mail connector is connected — add one in Connectors, or nothing can be sent."}),e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx(us,{on:d.slackEnabled,label:"Slack notifications",onChange:v=>V({slackEnabled:v})}),e.jsx(Ea,{size:15,className:"text-gray-500"}),e.jsx("span",{className:"text-sm text-gray-300 w-20",children:"Slack"}),e.jsx("span",{className:"flex-1 text-sm text-gray-400",children:b.length===0?"No Slack connector is connected — add one in Connectors.":e.jsxs(e.Fragment,{children:["Posts to ",b.map((v,x)=>{var o;return e.jsxs("b",{className:"text-gray-300",children:[x?", ":"",(o=v.config)!=null&&o.channel?`#${String(v.config.channel).replace(/^#/,"")}`:v.name||"Slack"]},v.id??x)})]})})]}),e.jsxs("div",{className:"flex items-start gap-3 flex-wrap",children:[e.jsx("span",{className:"w-9"}),e.jsx(Pa,{size:15,className:"text-gray-500 mt-1.5"}),e.jsx("span",{className:"text-sm text-gray-300 w-20 mt-1",children:"Notify when"}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs("div",{className:"flex items-center gap-2 text-sm text-gray-300",children:["At least",e.jsx("input",{value:c,onChange:v=>j(v.target.value.replace(/[^\d]/g,"")),onBlur:I,onKeyDown:v=>{v.key==="Enter"&&I()},inputMode:"numeric","aria-label":"Minimum new commits",className:"w-16 bg-surface-2 border border-white/10 rounded-lg px-2 py-1.5 text-sm text-gray-200 text-center focus:outline-none focus:border-sky-500/50"}),"new commit(s)"]}),e.jsxs("label",{className:"flex items-center gap-2 text-sm text-gray-400",children:[e.jsx("input",{type:"checkbox",checked:d.notifyOnlyRisky,onChange:v=>V({notifyOnlyRisky:v.target.checked}),className:"rounded border-white/20"}),"Only when pulling would conflict or touch uncommitted work"]})]})]})]})]})]})}const ut=s=>`---
2
2
  name: My Custom Skill
3
3
  slug: my-custom-skill
4
4
  description: Describe what this skill teaches the AI
@@ -1 +1 @@
1
- import{o as m,r as a,j as e}from"./vendor-react-CTbHBddL.js";import{a as o}from"./formatDate-T65-Y6Mi.js";import{io as p}from"./index-BYVxKLrT.js";import{R as h}from"./ReportCard-G52Q6-2i.js";import{a0 as f,l as g,al as u}from"./vendor-icons-BKPiFyYV.js";import"./vendor-query-BrzmPFT3.js";import"./KpiTile-inmeEsy3.js";import"./vendor-charts-DWFQlmCz.js";function R(){const{token:t}=m(),[r,c]=a.useState(null),[x,n]=a.useState(!0),[d,l]=a.useState(null);return a.useEffect(()=>{if(!t){l("No share token provided"),n(!1);return}p(t).then(s=>c(s)).catch(s=>{const i=s instanceof Error?s.message:String(s);l(i.includes("not found")||i.includes("revoked")?"This share link is no longer valid — it expired or was revoked. Ask the report owner for a fresh link.":i)}).finally(()=>n(!1))},[t]),x?e.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gray-50 dark:bg-surface-0",children:e.jsxs("div",{className:"flex items-center gap-2 text-gray-500 dark:text-gray-400",children:[e.jsx(f,{size:18,className:"animate-spin"}),e.jsx("span",{children:"Loading shared report…"})]})}):d||!r?e.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gray-50 dark:bg-surface-0 px-6",children:e.jsxs("div",{className:"max-w-md w-full rounded-xl border border-rose-500/30 bg-white dark:bg-white/[0.03] p-6 text-center",children:[e.jsx(g,{size:24,className:"text-rose-500 mx-auto mb-3"}),e.jsx("div",{className:"text-sm font-semibold text-gray-900 dark:text-gray-100 mb-1",children:"Share link unavailable"}),e.jsx("div",{className:"text-xs text-gray-600 dark:text-gray-400",children:d||"Share link not found"})]})}):e.jsx("div",{className:"min-h-screen bg-gray-50 dark:bg-surface-0",children:e.jsxs("div",{className:"max-w-[1360px] mx-auto px-4 sm:px-6 py-6",children:[e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-2 mb-5 text-[12px] text-gray-600 dark:text-gray-400",children:[e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx("span",{className:"font-semibold tracking-wide uppercase",children:"Testver"}),e.jsx(u,{size:10,className:"opacity-50"}),e.jsx("span",{children:"Shared Report"})]}),e.jsxs("div",{children:["Read-only view · ",o(r.updatedAt||r.createdAt),r.shareExpiresAt&&e.jsxs(e.Fragment,{children:[" · link expires ",o(r.shareExpiresAt)]})]})]}),e.jsx(h,{variant:"page",spec:r.spec,savedId:r.id,initialShareToken:t,readonly:!0,links:!1}),e.jsx("div",{className:"text-center text-[11px] text-gray-400 dark:text-gray-600 mt-6",children:"Generated by Testver"})]})})}export{R as SharedReportView};
1
+ import{o as m,r as a,j as e}from"./vendor-react-DOVfxdUy.js";import{a as o}from"./formatDate-T65-Y6Mi.js";import{it as p}from"./index-D6sQYc_0.js";import{R as h}from"./ReportCard-D4EElEe9.js";import{a0 as f,a as g,al as u}from"./vendor-icons-D_Dmmj8d.js";import"./vendor-query-DkZSMtfn.js";import"./KpiTile-BHLE3HVj.js";import"./vendor-charts-By5uZ93z.js";function R(){const{token:t}=m(),[r,c]=a.useState(null),[x,n]=a.useState(!0),[d,l]=a.useState(null);return a.useEffect(()=>{if(!t){l("No share token provided"),n(!1);return}p(t).then(s=>c(s)).catch(s=>{const i=s instanceof Error?s.message:String(s);l(i.includes("not found")||i.includes("revoked")?"This share link is no longer valid — it expired or was revoked. Ask the report owner for a fresh link.":i)}).finally(()=>n(!1))},[t]),x?e.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gray-50 dark:bg-surface-0",children:e.jsxs("div",{className:"flex items-center gap-2 text-gray-500 dark:text-gray-400",children:[e.jsx(f,{size:18,className:"animate-spin"}),e.jsx("span",{children:"Loading shared report…"})]})}):d||!r?e.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gray-50 dark:bg-surface-0 px-6",children:e.jsxs("div",{className:"max-w-md w-full rounded-xl border border-rose-500/30 bg-white dark:bg-white/[0.03] p-6 text-center",children:[e.jsx(g,{size:24,className:"text-rose-500 mx-auto mb-3"}),e.jsx("div",{className:"text-sm font-semibold text-gray-900 dark:text-gray-100 mb-1",children:"Share link unavailable"}),e.jsx("div",{className:"text-xs text-gray-600 dark:text-gray-400",children:d||"Share link not found"})]})}):e.jsx("div",{className:"min-h-screen bg-gray-50 dark:bg-surface-0",children:e.jsxs("div",{className:"max-w-[1360px] mx-auto px-4 sm:px-6 py-6",children:[e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-2 mb-5 text-[12px] text-gray-600 dark:text-gray-400",children:[e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx("span",{className:"font-semibold tracking-wide uppercase",children:"Testver"}),e.jsx(u,{size:10,className:"opacity-50"}),e.jsx("span",{children:"Shared Report"})]}),e.jsxs("div",{children:["Read-only view · ",o(r.updatedAt||r.createdAt),r.shareExpiresAt&&e.jsxs(e.Fragment,{children:[" · link expires ",o(r.shareExpiresAt)]})]})]}),e.jsx(h,{variant:"page",spec:r.spec,savedId:r.id,initialShareToken:t,readonly:!0,links:!1}),e.jsx("div",{className:"text-center text-[11px] text-gray-400 dark:text-gray-600 mt-6",children:"Generated by Testver"})]})})}export{R as SharedReportView};
@@ -1,4 +1,4 @@
1
- import{u as $e,r as d,j as e}from"./vendor-react-CTbHBddL.js";import{a as Ie}from"./formatDate-T65-Y6Mi.js";import{u as Le,a as Je}from"./useTabParam-ChbOedP1.js";import{ah as ge,aI as Ee,aJ as Oe,aK as Ue,aL as Be}from"./useTestManagement-Xm4Bcx3u.js";import{a8 as Me,b as be,il as Qe,im as _e}from"./index-BYVxKLrT.js";import{C as Ke}from"./ConfirmDialog-t7mpeeSN.js";import{a as fe,c as Ze}from"./vendor-query-BrzmPFT3.js";import{u as Ye,d as Ge,b as He}from"./useJiraConnector-D5ysBBvz.js";import{B as We,v as je,b4 as de,X as me,g as X,bd as Xe,b0 as Ve,r as et,b as K,a2 as xe,bh as ye,bj as ae,a7 as ue,a0 as te,o as se,a5 as tt,ag as pe,_ as Ne,c as st,bb as at,b7 as rt,y as nt,R as it}from"./vendor-icons-BKPiFyYV.js";function _(s){var b,r,f;if(!s)return"";if(typeof s=="string")return s;if(s.type==="text")return s.text||"";if(s.type==="inlineCard")return((b=s.attrs)==null?void 0:b.url)||"";if(s.type==="mention")return`@${((r=s.attrs)==null?void 0:r.text)||""}`;if(s.type==="emoji")return((f=s.attrs)==null?void 0:f.shortName)||"";if(s.type==="hardBreak")return`
1
+ import{u as $e,r as d,j as e}from"./vendor-react-DOVfxdUy.js";import{a as Ie}from"./formatDate-T65-Y6Mi.js";import{u as Le,a as Je}from"./useTabParam-CyYAP90W.js";import{ah as ge,aI as Ee,aJ as Oe,aK as Ue,aL as Be}from"./useTestManagement-DW6AW2mt.js";import{ae as Me,b as be,ir as Qe,is as _e}from"./index-D6sQYc_0.js";import{C as Ke}from"./ConfirmDialog-DtotgVmI.js";import{a as fe,c as Ze}from"./vendor-query-DkZSMtfn.js";import{u as Ye,d as Ge,b as He}from"./useJiraConnector-Dwj69Rfh.js";import{B as We,v as je,b4 as de,X as me,i as X,bd as Xe,b0 as Ve,r as et,d as K,a2 as xe,bh as ye,bj as ae,a7 as ue,a0 as te,o as se,a5 as tt,ag as pe,_ as Ne,e as st,bb as at,b7 as rt,y as nt,R as it}from"./vendor-icons-D_Dmmj8d.js";function _(s){var b,r,f;if(!s)return"";if(typeof s=="string")return s;if(s.type==="text")return s.text||"";if(s.type==="inlineCard")return((b=s.attrs)==null?void 0:b.url)||"";if(s.type==="mention")return`@${((r=s.attrs)==null?void 0:r.text)||""}`;if(s.type==="emoji")return((f=s.attrs)==null?void 0:f.shortName)||"";if(s.type==="hardBreak")return`
2
2
  `;const p=Array.isArray(s.content)?s.content:[],n=p.map(i=>_(i)).join("");switch(s.type){case"doc":return n;case"paragraph":return n+`
3
3
  `;case"heading":return n+`
4
4
  `;case"bulletList":case"orderedList":return p.map((i,h)=>(s.type==="orderedList"?`${h+1}. `:"• ")+_(i).trim()).join(`