1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/analytics-CYoCBVh_.js","assets/main-DY-9XjQU.js"])))=>i.map(i=>d[i]); 2import{c as b,j as e,B as u,r as o,a as Y,e as Z,C as J,k as X,l as Q,m as ee,n as se,T as D,_ as U,o as re,u as te,L as ae}from"./main-DY-9XjQU.js";import{trackConnectWithGithub as oe}from"./analytics-CYoCBVh_.js";import{G as F}from"./github-CBPR6abn.js";import{T as ie,a as ne,b as x,c as g,C as P,U as le}from"./UnitConfigureInstructions-qgRyF-eI.js";import{L as w}from"./label-CyKvqy81.js";import{I as ce}from"./input-CpD7b6uQ.js";import{R as G,a as N}from"./radio-group-Bd1BHauY.js";import{D as de,C as me,U as ue}from"./UnitCreateForm-BdMOML4o.js";import{S as he}from"./settings-l6BY8H0V.js";import{A as pe}from"./arrow-left-C1_IodFU.js";import"./index-D7KeiI7j.js";import"./index-C3DD1Kdc.js";import"./index-B_WwOjgt.js";import"./check-39IPjwp3.js";import"./badge-UUgHdAnj.js";/** 3 * @license lucide-react v0.545.0 - ISC 4 * 5 * This source code is licensed under the ISC license. 6 * See the LICENSE file in the root directory of this source tree. 7 */const fe=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],L=b("circle-check",fe);/** 8 * @license lucide-react v0.545.0 - ISC 9 * 10 * This source code is licensed under the ISC license. 11 * See the LICENSE file in the root directory of this source tree. 12 */const xe=[["path",{d:"M4 14.899A7 7 0 1 1 15.71 8h1.79a4.5 4.5 0 0 1 2.5 8.242",key:"1pljnt"}],["path",{d:"M16 14v6",key:"1j4efv"}],["path",{d:"M8 14v6",key:"17c4r9"}],["path",{d:"M12 16v6",key:"c8a4gj"}]],ge=b("cloud-rain",xe);/** 13 * @license lucide-react v0.545.0 - ISC 14 * 15 * This source code is licensed under the ISC license. 16 * See the LICENSE file in the root directory of this source tree. 17 */const je=[["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}],["path",{d:"M15.947 12.65a4 4 0 0 0-5.925-4.128",key:"dpwdj0"}],["path",{d:"M13 22H7a5 5 0 1 1 4.9-6H13a3 3 0 0 1 0 6Z",key:"s09mg5"}]],ye=b("cloud-sun",je);/** 18 * @license lucide-react v0.545.0 - ISC 19 * 20 * This source code is licensed under the ISC license. 21 * See the LICENSE file in the root directory of this source tree. 22 */const Ne=[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v4",key:"1pf5j1"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"m5 12-3 3 3 3",key:"oke12k"}],["path",{d:"m9 18 3-3-3-3",key:"112psh"}]],be=b("file-code-2",Ne);/** 23 * @license lucide-react v0.545.0 - ISC 24 * 25 * This source code is licensed under the ISC license. 26 * See the LICENSE file in the root directory of this source tree. 27 */const ve=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]],k=b("file-text",ve);function Ce({source:a,onClick:n,user:c,organizationId:h}){const d=()=>{oe(a,c,h),n()};return e.jsxs(u,{onClick:d,children:[e.jsx(F,{className:"mr-2 h-4 w-4"})," Connect with GitHub"]})}function we({onClick:a}){const n=()=>{a()};return e.jsxs(u,{onClick:n,children:[e.jsx(L,{className:"mr-2 h-4 w-4"})," I've added the workflow file"]})}function ke({onClick:a}){const n=()=>{a()};return e.jsxs(u,{onClick:n,children:[e.jsx(k,{className:"mr-2 h-4 w-4"})," I've added the digger.yml file"]})}const _=o.forwardRef(({className:a,...n},c)=>e.jsx("textarea",{className:Y("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",a),ref:c,...n}));_.displayName="Textarea";function M({repoName:a,repoOwner:n,onComplete:c,userId:h,email:d,organisationId:j,publicHostname:y,githubAppUrl:v}){const[W,l]=o.useState(()=>{if(typeof window<"u"){const s=new URLSearchParams(window.location.search).get("step");if(s)return s}return"create-unit"}),[i,C]=o.useState({githubConnected:!1,workflowCreated:!1,diggerConfigCreated:!1,unitCreated:!1,unitConfigured:!1,terraformPRCreated:!1}),[p,S]=o.useState(null),[m,T]=o.useState(null),[Te,_e]=o.useState([]),[Se,Ee]=o.useState(""),[t,f]=o.useState({cloudProvider:"aws",connection:"",iacType:"terraform",iacVersion:"1.5.6"}),E=s=>`projects: 28 - name: my-dev 29 dir: path/to/dev 30 opentofu: ${s==="opentofu"?"true":"false"} 31 terraform: ${s==="terraform"?"true":"false"} 32`,[I,A]=o.useState(E("terraform")),{toast:R}=Z();o.useEffect(()=>
32{i.workflowCreated||A(E(t.iacType))},[t.iacType]),o.useEffect(()=>{if(!(typeof window>"u"))try{const s=window.localStorage.getItem("onboardingMode");(s==="unit"||s==="pr_only")&&T(s);const r=window.localStorage.getItem("onboardingUnit");r&&S(JSON.parse(r))}catch{}},[]),o.useEffect(()=>{if(!(typeof window>"u"))try{m&&window.localStorage.setItem("onboardingMode",m),p&&window.localStorage.setItem("onboardingUnit",JSON.stringify(p))}catch{}},[m,p]);const $=s=>{const r=s.iacVersion||(s.iacType==="terraform"?"1.5.6":"1.9.1");s.iacType;const O=s.iacType==="terraform"?"terraform":"tofu";return p&&`${p.id}${p.name}`,`name: Digger Workflow 33 34on: 35 workflow_dispatch: 36 inputs: 37 spec: 38 required: true 39 run_name: 40 required: false 41 42run-name: '\${{inputs.run_name}}' 43 44jobs: 45 digger-job: 46 runs-on: ubuntu-latest 47 permissions: 48 contents: write # required to merge PRs 49 actions: write # required for plan persistence 50 id-token: write # required for workload-identity-federation 51 pull-requests: write # required to post PR comments 52 issues: read # required to check if PR number is an issue or not 53 statuses: write # required to validate combined PR status 54 55 steps: 56 - uses: actions/checkout@v4 57 - name: \${{ fromJSON(github.event.inputs.spec).job_id }} 58 run: echo "job id \${{ fromJSON(github.event.inputs.spec).job_id }}" 59 - uses: diggerhq/digger@vLatest 60 with: 61 digger-spec: \${{ inputs.spec }} 62 ${O=="terraform"?`setup-terraform: true 63 terraform-version: ${r}${m==="unit"?"\n terraform-tfe-token: ${{ secrets.TFE_TOKEN }}":""}${m==="unit"?` 64 terraform-tfe-hostname: ${y}`:""}`:""}${O=="tofu"?`setup-opentofu: true 65 opentofu-version: ${r}${m==="unit"?"\n opentofu-tfe-token: ${{ secrets.TFE_TOKEN }}":""}${m==="unit"?` 66 opentofu-tfe-hostname: ${y}`:""}`:""} 67 ${s.cloudProvider=="aws"?"setup-aws: true\n aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}\n aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}":""}${s.cloudProvider=="gcp"?"setup-google-cloud: true\n google-cloud-credentials: ${{ secrets.GOOGLE_CLOUD_CREDENTIALS }}":""}${s.cloudProvider=="azure"?"setup-azure: true\n azure-client-id: ${{ secrets.AZURE_CLIENT_ID }}\n azure-tenant-id: ${{ secrets.AZURE_TENANT_ID }}\n azure-subscription-id: ${{ secrets.AZURE_SUBSCRIPTION_ID }}":""} 68 env: 69 GITHUB_CONTEXT: \${{ toJson(github) }} 70 GITHUB_TOKEN: \${{ secrets.GITHUB_TOKEN }} 71`},z=()=>{navigator.clipboard.writeText($(t)),R({title:"Success",description:"Workflow content copied to clipboard",action:e.jsx(D,{altText:"OK",children:"OK"})});const s={id:h,email:d};U(async()=>{const{trackWorkflowFileAdded:r}=await import("./analytics-CYoCBVh_.js");return{trackWorkflowFileAdded:r}},__vite__mapDeps([0,1])).then(({trackWorkflowFileAdded:r})=>r(s,j))},V=()=>{navigator.clipboard.writeText(I),R({title:"Success",description:"digger.yml content copied to clipboard",action:e.jsx(D,{altText:"OK",children:"OK"})});const s={id:h,email:d};U(async()=>{const{trackDiggerYmlAdded:r}=await import("./analytics-CYoCBVh_.js");return{trackDiggerYmlAdded:r}},__vite__mapDeps([0,1])).then(({trackDiggerYmlAdded:r})=>r(s,j))},H=()=>{window.open(v,"_blank"),l("workflow"),C(s=>({...s,githubConnected:!0}))},q=async()=>{l("digger"),C(s=>({...s,workflowCreated:!0}))},B=async()=>{l("complete"),C(s=>({...s,diggerConfigCreated:!0}))},K=s=>{console.log("handleCreateUnit",s),s&&S({id:s.id,name:s.name}),T("unit"),C(r=>({...r,unitCreated:!0})),l("configure-unit")};return e.jsx("div",{className:"max-w-5xl mx-auto",children:e.jsxs(J,{children:[e.jsxs(X,{children:[e.jsx(Q,{children:"Repository Setup"}),e.jsx(ee,{children:"Follow these steps to set up your repository with Digger"})]}),e.jsx(se,{children:e.jsxs(ie,{value:W,onValueChange:l,className:"w-full",children:[e.jsxs(ne,{className:"grid w-full grid-cols-6",children:[e.jsxs(x,{value:"create-unit",disabled:i.unitCreated,children:[e.jsx(de,{className:"mr-2 h-4 w-4"})," Create Unit"]}),e.jsxs(x,{value:"configure-unit",disabled:!i.unitCreated||i.unitConfigured,children:[e.jsx(he,{className:"mr-2 h-4 w-4"})," Configure Unit"]}),e.jsxs(x,{value:"github",disabled:i.githubConnected,children:[e.jsx(F,{className:"mr-2 h-4 w-4"})," GitHub"]}),e.jsxs(x,{value:"workflow",disabled:!i.githubConnected||i.workflowCreated,children:[e.jsx(be,{className:"mr-2 h-4 w-4"})," Workflow"]}),e.jsxs(x,{value:"digger",disabled:!i.workflowCreated||i.diggerConfigCreated,children:[e.jsx(k,{className:"mr-2 h-4 w-4"})," digger.yml"]}),e.jsxs(x,{value:"complete",disabled:!i.unitCreated,children:[e.jsx(L,{className:"mr-2 h-4 w-4"})," Complete"]})]}),e.jsx(g,{value:"github",className:"mt-6",children:e.jsxs("div",{className:"space-y-4",children:[e.jsx("h3",{className:"font-medium",children:"Connect GitHub Repository"}),e.jsx("p",{className:"text-sm text-gray-500",children:"Install the Digger GitHub App to connect your repository"}),e.jsx(Ce,{source:"onboarding",onClick:H,user:{id:h,email:d},organizationId:j})]})}),e.jsx(g,{value:"workflow",className:"mt-6",children:e.jsxs("div",{className:"space-y-6",children:[e.jsx("h3",{className:"font-medium",children:"Create Workflow Files"}),e.jsx("p",{className:"text-sm text-gray-500",children:"Pick your settings and then copy the workflow file to your repository"}),e.jsx(e.Fragment,{children:e.jsxs("div",{className:"space-y-4",children:[e.jsxs("div",{className:"space-y-4",children:[e.jsxs("div",{children:[e.jsx(w,{children:"Cloud Provider"}),e.jsxs(G,{value:t.cloudProvider,onValueChange:s=>
71f(r=>({...r,cloudProvider:s})),className:"mt-3 grid grid-cols-1 md:grid-cols-3 gap-3",children:[e.jsxs("label",{htmlFor:"aws",className:`relative flex cursor-pointer items-start gap-4 rounded-lg border p-4 md:p-5 transition-colors hover:bg-muted/50 ${t.cloudProvider==="aws"?"ring-2 ring-primary border-primary":"border-muted"}`,onClick:()=>f(s=>({...s,cloudProvider:"aws"})),children:[e.jsx(N,{value:"aws",id:"aws",className:"sr-only"}),e.jsx("div",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-primary/10 text-primary",children:e.jsx(me,{className:"h-5 w-5"})}),e.jsxs("div",{className:"space-y-1",children:[e.jsx("span",{className:"text-base font-semibold",children:"AWS"}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"Use AWS credentials or OIDC in your workflow."})]})]}),e.jsxs("label",{htmlFor:"gcp",className:`relative flex cursor-pointer items-start gap-4 rounded-lg border p-4 md:p-5 transition-colors hover:bg-muted/50 ${t.cloudProvider==="gcp"?"ring-2 ring-primary border-primary":"border-muted"}`,onClick:()=>f(s=>({...s,cloudProvider:"gcp"})),children:[e.jsx(N,{value:"gcp",id:"gcp",className:"sr-only"}),e.jsx("div",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-primary/10 text-primary",children:e.jsx(ge,{className:"h-5 w-5"})}),e.jsxs("div",{className:"space-y-1",children:[e.jsx("span",{className:"text-base font-semibold",children:"GCP"}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"Provide service account JSON or workload identity."})]})]}),e.jsxs("label",{htmlFor:"azure",className:`relative flex cursor-pointer items-start gap-4 roun
71ded-lg border p-4 md:p-5 transition-colors hover:bg-muted/50 ${t.cloudProvider==="azure"?"ring-2 ring-primary border-primary":"border-muted"}`,onClick:()=>f(s=>({...s,cloudProvider:"azure"})),children:[e.jsx(N,{value:"azure",id:"azure",className:"sr-only"}),e.jsx("div",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-primary/10 text-primary",children:e.jsx(ye,{className:"h-5 w-5"})}),e.jsxs("div",{className:"space-y-1",children:[e.jsx("span",{className:"text-base font-semibold",children:"Azure"}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"Use federated credentials or client secret."})]})]})]})]}),e.jsxs("div",{children:[e.jsx(w,{children:"IAC Type"}),e.jsxs(G,{value:t.iacType,onValueChange:s=>f(r=>({...r,iacType:s,iacVersion:s==="terraform"?"1.5.6":"1.9.1"})),className:"mt-3 grid grid-cols-1 md:grid-cols-2 gap-3",children:[e.jsxs("label",{htmlFor:"terraform",className:`relative flex cursor-pointer items-start gap-4 rounded-lg border p-4 md:p-5 transition-colors hover:bg-muted/50 ${t.iacType==="terraform"?"ring-2 ring-primary border-primary":"border-muted"}`,onClick:()=>f(s=>({...s,iacType:"terraform",iacVersion:"1.5.6"})),children:[e.jsx(N,{value:"terraform",id:"terraform",className:"sr-only"}),e.jsx("div",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-primary/10 text-primary",children:e.jsx(k,{className:"h-5 w-5"})}),e.jsxs("div",{className:"space-y-1",children:[e.jsx("span",{className:"text-base font-semibold",children:"Terraform"}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"Use HashiCorp Terraform runtime."})]})]}),e.jsxs("label",{htmlFor:"opentofu",className:`relative flex cursor-pointer items-start gap-4 roun
71ded-lg border p-4 md:p-5 transition-colors hover:bg-muted/50 ${t.iacType==="opentofu"?"ring-2 ring-primary border-primary":"border-muted"}`,onClick:()=>f(s=>({...s,iacType:"opentofu",iacVersion:"1.9.1"})),children:[e.jsx(N,{value:"opentofu",id:"opentofu",className:"sr-only"}),e.jsx("div",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-primary/10 text-primary",children:e.jsx(k,{className:"h-5 w-5"})}),e.jsxs("div",{className:"space-y-1",children:[e.jsx("span",{className:"text-base font-semibold",children:"OpenTofu"}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"Use OpenTofu community runtime."})]})]})]})]}),e.jsxs("div",{children:[e.jsx(w,{htmlFor:"iacVersion",children:"IAC Version"}),e.jsx(ce,{id:"iacVersion",value:t.iacVersion,onChange:s=>f(r=>({...r,iacVersion:s.target.value})),placeholder:t.iacType==="terraform"?"1.5.6":"1.9.1"})]})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(w,{children:"Workflow Content"}),e.jsx("p",{className:"text-sm text-gray-500 mb-2",children:"Copy and paste this content into .github/workflows/digger_workflow.yml (must be in main or master branch)"}),e.jsxs("div",{className:"relative",children:[e.jsx(_,{value:$(t),readOnly:!0,className:"font-mono h-[440px]"}),e.jsx(u,{size:"sm",variant:"ghost",className:"absolute top-2 right-2",onClick:z,children:e.jsx(P,{className:"h-4 w-4"})})]}),e.jsxs("div",{className:"mt-4 rounded-md border bg-muted/30 p-4",children:[e.jsx("h4",{className:"text-sm font-medium mb-2",children:"Set these GitHub secrets"}),e.jsxs("div",{className:"text-sm text-muted-foreground",children:[e.jsx("p",{className:"mb-2",children:"Add the following secrets in your repository settings â Secrets and variables â Actions:"}),t.cloudProvider==="aws"&&e.jsxs("ul",{className:"list-disc pl-5 space-y-1",children:[e.jsx("li",{children:e.jsx("code",{className:"font-mono",children:"AWS_ACCESS_KEY_ID"})}),e.jsx("li",{children:e.jsx("code",{className:"font-mono",children:"AWS_SECRET_ACCESS_KEY"})})]}),t.cloudProvider==="gcp"&&e.jsx("ul",{className:"list-disc pl-5 space-y-1",children:e.jsx("li",{children:e.jsx("code",{className:"font-mono",children:"GOOGLE_CLOUD_CREDENTIALS"})})}),t.cloudProvider==="azure"&&e.jsxs("ul",{className:"list-disc pl-5 space-y-1",children:[e.jsx("li",{children:e.jsx("code",{className:"font-mono",children:"AZURE_CLIENT_ID"})}),e.jsx("li",{children:e.jsx("code",{className:"font-mono",children:"AZURE_TENANT_ID"})}),e.jsx("li",{children:e.jsx("code",{className:"font-mono",children:"AZURE_SUBSCRIPTION_ID"})})]}),m==="unit"&&e.jsxs("div",{className:"mt-3",children:[e.jsx("p",{className:"font-medium",children:"For remote state"}),e.jsx("ul",{className:"list-disc pl-5 space-y-1",children:e.jsxs("li",{children:[e.jsx("code",{className:"font-mono",children:"TFE_TOKEN"})," â API token for remote state access, generate from"," ",e.jsx("a",{href:"/dashboard/settings/tokens",target:"_blank",rel:"noopener noreferrer",className:"text-blue-500 hover:underline",children:"token settings page"})]})})]})]})]})]}),e.jsxs("p",{className:"text-sm text-gray-500 mt-4",children:["For more advanced workflow configuration options such as OIDC, check out the ",e.jsx("a",{href:"https://docs.digger.dev/",className:"text-blue-500 hover:underline",target:"_blank",rel:"noopener noreferrer",children:"Digger documentation"}),"."]}),e.jsx("div",{className:"flex justify-end",children:e.jsx(we,{onClick:q})})]})})]})}),e.jsx(g,{value:"digger",className:"mt-6",children:e.jsxs("div",{className:"space-y-4",children:[e.jsx("h3",{className:"font-medium",children:"Configure digger.yml"}),e.jsx("p",{className:"text-sm text-gray-500",children:"Configure your digger.yml file for the selected repository"}),e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"relative",children:[e.jsx(_,{value:I,onChange:s=>A(s.target.value),className:"font-mono h-[200px]",placeholder:"Enter your digger.yml configuration"}),e.jsx(u,{size:"sm",variant:"ghost",className:"absolute top-2 right-2",onClick:V,children:e.jsx(P,{className:"h-4 w-4"})})]}),e.jsx("div",{className:"flex justify-end mt-2",children:e.jsx(ke,{onClick:B})})]})]})}),e.jsx(g,{value:"create-unit",className:"mt-6",children:e.jsxs("div",{className:"space-y-4",children:[e.jsx("h3",{className:"font-medium",children:"Create a Unit"}),e.jsx("p",{className:"text-sm text-gray-500",children:'A unit is a deployable piece of Terraform that you plan and apply. You can also use it to run remote jobs. If you are coming from Terraform Cloud, this is very similar to a "Workspace".'}),!i.unitCreated&&e.jsx(ue,{onCreated:K,onBringOwnState:()=>{T("pr_only"),l("github")}})]})}),e.jsx(g,{value:"configure-unit",className:"mt-6",children:e.jsx("div",{className:"space-y-4",children:i.unitCreated?p?e.jsx(le,{unitId:p.id,organisationId:j,publicHostname:y,onGoToGithub:()=>l("github"),onGoToLocal:()=>l("complete")}
71):e.jsx("div",{className:"text-sm text-gray-500",children:"Preparing configurationâ¦"}):e.jsxs("div",{className:"text-sm text-gray-500",children:["Please create a unit first.",e.jsx("div",{className:"mt-4",children:e.jsx(u,{onClick:()=>l("create-unit"),children:"Go to Create Unit"})})]})})}),e.jsx(g,{value:"complete",className:"mt-6",children:e.jsxs("div",{className:"space-y-4",children:[e.jsx("h3",{className:"font-medium",children:"All set!"}),e.jsxs("p",{className:"text-sm text-gray-500",children:["Your unit is created and configured. If you want to test Terraform automation, create a PR that touches one of your Terraform directories defined in ",e.jsx("code",{className:"font-mono",children:"digger.yml"}),". Digger will comment with a plan and manage runs automatically. Alternatively, you can run ",e.jsx("code",{className:"font-mono",children:"terraform plan"})," and ",e.jsx("code",{className:"font-mono",children:"terraform apply"})," locally using the instructions in the previous step."]}),e.jsxs("div",{className:"flex items-center justify-end gap-2",children:[e.jsx(u,{variant:"outline",onClick:()=>l("configure-unit"),children:"Back"}),c&&e.jsx(u,{onClick:c,children:"Finish"})]})]})})]})})]})})}function He(){const{user:a,organisationId:n,publicHostname:c,githubAppUrl:h}=re.useLoaderData(),[d,j]=o.useState(null),y=te(),v=()=>{y.navigate({to:"/dashboard/units"})};return e.jsxs("div",{className:"container mx-auto p-4",children:[e.jsx("div",{className:"mb-6",children:e.jsx(u,{variant:"ghost",asChild:!0,children:e.jsxs(ae,{to:"/dashboard/repos",children:[e.jsx(pe,{className:"mr-2 h-4 w-4"})," Back to Dashboard"]})})}),d?e.jsx(M,{repoName:d.name,repoOwner:d.owner,userId:a?.id||"",email:a?.email||"",organisationId:n||"",publicHostname:c,githubAppUrl:h,onComplete:v}):e.jsx(M,{userId:a?.id||"",email:a?.email||"",organisationId:n||"",publicHostname:c,githubAppUrl:h,onComplete:v})]})}export{He as component};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.