1"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[32334],{17998(e,t,r){r.r(t),r.d(t,{default:()=>f});var s=r(36870),i=r(44110),o=r(86326),a=r(82432),n=r(67925),c=r(87310),l=r(7474),h=r(9229),d=r(42661),u=r(53227),g=r(15290),p=r(17661);let f=(0,l.Q)((0,a.Ng)((e,t)=>({step:Number(t.step),gitProvider:d.Sc.get(t.match.params.provider||(0,h.Zq)(t.location.search).provider),git:e.git}))(e=>{let{location:t,git:r,step:a,gitProvider:l}=e,{setIsLoadingApp:d}=(0,c.ZT)();(0,o.useEffect)(()=>{d(!1)},[d]);let[f,w]=(0,o.useState)(null),[m,x]=(0,o.useState)(!1),{host:j}=(0,h.Zq)(t.search);(0,o.useEffect)(()=>{let e=decodeURIComponent(j);if(e)try{if("localhost"!==new URL(e).hostname)throw Error("Forbidden host for CLI.")}catch(e){w(e.message)}},[j]),(0,o.useEffect)(()=>{if(r?.get("user")&&m){let e=new URL(decodeURIComponent(j));e.searchParams.set("user",r.get("user").get("login")),e.searchParams.set("token",r.get("accessToken")),e.searchParams.set("provider",r.get("provider")),window.location.href=e.href}},[m,r,j]);let v=(e=>{let{gitProvider:t}=e;return(0,i.fromJS)([{label:t?`Authenticate with ${t.get("name")}`:"Connect to Git provider",path:"/cli"}])})({gitProvider:l}),C=(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("h1",{children:"Log in to Netlify CLI"}),(0,s.jsx)("p",{children:"Please log in to your Git hosting provider to use with CLI."})]});return(0,s.jsx)("div",{className:"container tw-@container/StartPage",children:(0,s.jsxs)("section",{children:[(0,s.jsxs)("header",{children:[(0,s.jsx)(p.A,{top:6,children:(0,s.jsx)(g.Ay,{steps:v,current:v.get(a)})}),(0,s.jsx)("div",{className:"tw-mt-26",children:C})]}),(0,s.jsx)("div",{className:"tw-grid tw-grid-cols-1 tw-justify-between tw-gap-10 @4xl/StartPage:tw-grid-cols-[1fr,280px]",children:(0,s.jsxs)("div",{children:[!f&&(0,s.jsx)(u.A,{warning:"Youâre about to share your Git provider credentials with Netlify CLI. Please close this page if you didnât authorize this request."}),(0,s.jsx)(u.A,{error:f}),!f&&(0,s.jsx)(n.A,{onError:w,onSuccess:()=>{x(!0)},isOnStartPage:!0})]})})]})})}))}}]);
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.