banko-ai-assistant 1.0.0__py3-none-any.whl → 1.0.1__py3-none-any.whl
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.
- banko_ai/static/creditcard_files/0dbda187ceb472a466dff54b7015b1d4.jpg +0 -0
- banko_ai/static/creditcard_files/10903-7f8736e237ced107.mjs +2 -0
- banko_ai/static/creditcard_files/10966-809952783184ae4b.mjs +4 -0
- banko_ai/static/creditcard_files/13351-8a7dda060266efff.mjs +2 -0
- banko_ai/static/creditcard_files/1342-c79d3d17da82f23c.mjs +11 -0
- banko_ai/static/creditcard_files/16142-bdecf7bfdd6d70ae.mjs +2 -0
- banko_ai/static/creditcard_files/16550-e89f65017860221d.mjs +2 -0
- banko_ai/static/creditcard_files/17492-942c70b114fdcce1.mjs +10 -0
- banko_ai/static/creditcard_files/18352-481d67e871cc6985.mjs +2 -0
- banko_ai/static/creditcard_files/18555-0d9763eb744f7a77.mjs +2 -0
- banko_ai/static/creditcard_files/19437-575ba467ea85e866.mjs +2 -0
- banko_ai/static/creditcard_files/1aca1669c3b4a07f0966c4733c939d6d.jpg +0 -0
- banko_ai/static/creditcard_files/20126-602c15db592cf3c4.mjs +26 -0
- banko_ai/static/creditcard_files/20224-b6de2c08cc8ad497.mjs +66 -0
- banko_ai/static/creditcard_files/2029a63f9af76541f860b6a6a4ec0c90.jpg +0 -0
- banko_ai/static/creditcard_files/21662-1214728138c72aa2.css +1 -0
- banko_ai/static/creditcard_files/22517-5f7ab2631d424b77.mjs +9 -0
- banko_ai/static/creditcard_files/23019-be3b8956cee94725.mjs +2 -0
- banko_ai/static/creditcard_files/26067-cb77f2673c5f757c.mjs +2 -0
- banko_ai/static/creditcard_files/27405-880a12623820964d.mjs +9 -0
- banko_ai/static/creditcard_files/27503-82078c18034012ed.mjs +38 -0
- banko_ai/static/creditcard_files/28090-8e4b5fd6c88f8eb2.mjs +6 -0
- banko_ai/static/creditcard_files/2c66dacf04db64cc1099835f2e2328d5.jpg +0 -0
- banko_ai/static/creditcard_files/30090868cb2b559a7093999fec5fbcc8.jpg +0 -0
- banko_ai/static/creditcard_files/30102-608e861dccc907f1.mjs +2 -0
- banko_ai/static/creditcard_files/31600-ca2e152d871d51d5.mjs +2 -0
- banko_ai/static/creditcard_files/31d5156a9cc5fe5fd780c2d9e59db98f.jpg +0 -0
- banko_ai/static/creditcard_files/34713-54729fd9c7517d50.mjs +2 -0
- banko_ai/static/creditcard_files/35074-d765c14dc3e8eafc.mjs +77 -0
- banko_ai/static/creditcard_files/38230-4d6eb1a608eecdeb.mjs +7 -0
- banko_ai/static/creditcard_files/40566-e2dbb4226dd2ab42.mjs +6 -0
- banko_ai/static/creditcard_files/42298-668aa166e1146c6c.mjs +2 -0
- banko_ai/static/creditcard_files/43203-3a1e46e5259313c8.mjs +14 -0
- banko_ai/static/creditcard_files/44429-6534f772a6bd895b.mjs +13 -0
- banko_ai/static/creditcard_files/48327-48fb70091d7ac731.mjs +2 -0
- banko_ai/static/creditcard_files/49923-dc71193d54a0b99c.mjs +2 -0
- banko_ai/static/creditcard_files/49c3cac3c5a09ca104a2efea48536d14.jpg +0 -0
- banko_ai/static/creditcard_files/50040-3c27b1fe14ca588b.mjs +2 -0
- banko_ai/static/creditcard_files/5047473e06297bbccfae9c43ca36bd93.jpg +0 -0
- banko_ai/static/creditcard_files/51531-253e8d8f8f527d9c.mjs +26 -0
- banko_ai/static/creditcard_files/58103-d6be57f2d624e7b4.mjs +2 -0
- banko_ai/static/creditcard_files/58822-d1779ebe9d4fab59.mjs +51 -0
- banko_ai/static/creditcard_files/61b440e4366b35d7213172be53d3864e.jpg +0 -0
- banko_ai/static/creditcard_files/61d121a699367070f3988f633ed6ac7d.jpg +0 -0
- banko_ai/static/creditcard_files/65610-15f55d146aa3cc6f.mjs +2 -0
- banko_ai/static/creditcard_files/65662-2b7065d2ddcf6a0c.mjs +2 -0
- banko_ai/static/creditcard_files/67631-9d4d7f4aab06e79c.mjs +2 -0
- banko_ai/static/creditcard_files/68445-8aae26e83c03d9bc.mjs +7 -0
- banko_ai/static/creditcard_files/6863-da15e99ca946f07a.mjs +2 -0
- banko_ai/static/creditcard_files/71526-518cf6126a32651b.mjs +2 -0
- banko_ai/static/creditcard_files/72268-8f69a6e8585b9af2.mjs +2 -0
- banko_ai/static/creditcard_files/76f1a52015cf2a243ed085586f3d44e8.jpg +0 -0
- banko_ai/static/creditcard_files/80538-65bd348271403336.mjs +2 -0
- banko_ai/static/creditcard_files/81505-387f6ddb644ae967.mjs +38 -0
- banko_ai/static/creditcard_files/8151-1a0cf04ea45ad513.mjs +2 -0
- banko_ai/static/creditcard_files/83119-1cf7ca2f5ba0e1ab.mjs +9 -0
- banko_ai/static/creditcard_files/83485-27ce97f9e7369ed7.mjs +5 -0
- banko_ai/static/creditcard_files/8575-e1977ceb3b34da9c.mjs +2 -0
- banko_ai/static/creditcard_files/8962-664b3c9b21ec2e0f.mjs +2 -0
- banko_ai/static/creditcard_files/90123-40fd5c2d5dc1c0a1.mjs +2 -0
- banko_ai/static/creditcard_files/91846-55cc5635c18159a0.mjs +47 -0
- banko_ai/static/creditcard_files/91936-56d11562a38b3f77.mjs +2 -0
- banko_ai/static/creditcard_files/96833-fbcb1ab8436924d4.mjs +36 -0
- banko_ai/static/creditcard_files/99246-889e96fc0a42e07a.mjs +2 -0
- banko_ai/static/creditcard_files/99961-ee8d9a1207a9db7a.mjs +2 -0
- banko_ai/static/creditcard_files/DefaultPinRep-78e567622e9cb382.mjs +27 -0
- banko_ai/static/creditcard_files/DesktopUnauthPageWrapper-26b3c2c050f09d27.css +1 -0
- banko_ai/static/creditcard_files/DesktopUnauthPageWrapper-a120f0b0faa773a2.mjs +252 -0
- banko_ai/static/creditcard_files/KkWFeSURekXGycdprVC-UY6ED-ZF5ll2JCMiHhJE2Rk.js +1 -0
- banko_ai/static/creditcard_files/MobileAndUnauthPinPage-0083f61f79e906d2.mjs +400 -0
- banko_ai/static/creditcard_files/UnauthCloseupRelatedPins-d98c713ac2e141a7.mjs +2 -0
- banko_ai/static/creditcard_files/[id]-87f8f6f1f81e3a8a.mjs +2 -0
- banko_ai/static/creditcard_files/_client-49638f60bdf5658e.mjs +43 -0
- banko_ai/static/creditcard_files/a7ee24644496b7a3131cd4e13b8c6edb.jpg +0 -0
- banko_ai/static/creditcard_files/a8ada9395c00dffc8fb81a7b76bd34b5.jpg +0 -0
- banko_ai/static/creditcard_files/abbf5a82906bef8c6be49ab38eaeea7c.jpg +0 -0
- banko_ai/static/creditcard_files/ad910641231bb413f6a985e4e9961efb.jpg +0 -0
- banko_ai/static/creditcard_files/anchor.html +186 -0
- banko_ai/static/creditcard_files/b6083df3cfa26856caef114c51a8d21e.jpg +0 -0
- banko_ai/static/creditcard_files/b957829ac112a8c28b313307e5ff0df6.jpg +0 -0
- banko_ai/static/creditcard_files/bb2d3d28e3421d901d8d431c33f0c6ed.jpg +0 -0
- banko_ai/static/creditcard_files/bb2d3d28e3421d901d8d431c33f0c6ed.png +0 -0
- banko_ai/static/creditcard_files/c3031b4a938377789e00d3d2f3b2438c.jpg +0 -0
- banko_ai/static/creditcard_files/client +300 -0
- banko_ai/static/creditcard_files/ct.html +3 -0
- banko_ai/static/creditcard_files/d03e6db9649ea3479b799d5a21008ac2.jpg +0 -0
- banko_ai/static/creditcard_files/d3d38fd9aa0c808a28ff5bd9ae5b5576.jpg +0 -0
- banko_ai/static/creditcard_files/de7cb9e198b4ebc9430824132ccfce2e.jpg +0 -0
- banko_ai/static/creditcard_files/e4330b4a4e71a3f77dd0682b99037cad.jpg +0 -0
- banko_ai/static/creditcard_files/ecdf72d4d54e70608e9416020f8ad67d.jpg +0 -0
- banko_ai/static/creditcard_files/eef64355b9f10e89c355b138adbae1e9.jpg +0 -0
- banko_ai/static/creditcard_files/enterprise.js +1 -0
- banko_ai/static/creditcard_files/f1354f6bb993409ea12235a01a978936.jpg +0 -0
- banko_ai/static/creditcard_files/f7c30e2615fe0e57d9ab6e41aac5e738.jpg +0 -0
- banko_ai/static/creditcard_files/fa72fa1ae9bb3ec93f41595333d22d16.jpg +0 -0
- banko_ai/static/creditcard_files/fb09ce3b0feb4931402867cf109cd618.jpg +0 -0
- banko_ai/static/creditcard_files/i +0 -0
- banko_ai/static/creditcard_files/locale-en_US-lite-js-d0d346142714beb1.mjs +2 -0
- banko_ai/static/creditcard_files/login-3c695aa28fdc27a5.mjs +161 -0
- banko_ai/static/creditcard_files/login-e161a84cea9cd0a3.css +1 -0
- banko_ai/static/creditcard_files/packages-rich-snippet-LeafSnippet-b7f61038a4431021.mjs +2 -0
- banko_ai/static/creditcard_files/polyfills-c5ca6e711f8975ec.mjs +2 -0
- banko_ai/static/creditcard_files/recaptcha__en.js +1011 -0
- banko_ai/static/creditcard_files/repin-62bbd4d7c8e22f17.css +1 -0
- banko_ai/static/creditcard_files/repin-d49f19d89ddd3cbe.mjs +292 -0
- banko_ai/static/creditcard_files/runtime-505e4380476a458b.mjs +2 -0
- banko_ai/static/creditcard_files/saved_resource(1).html +7 -0
- banko_ai/static/creditcard_files/saved_resource(2).html +3 -0
- banko_ai/static/creditcard_files/saved_resource.html +3 -0
- banko_ai/static/creditcard_files/sdk(1).js +22 -0
- banko_ai/static/creditcard_files/sdk.js +228 -0
- banko_ai/static/creditcard_files/select.html +387 -0
- banko_ai/static/creditcard_files/style +1 -0
- banko_ai/static/creditcard_files/styles__ltr.css +1 -0
- banko_ai/static/creditcard_files/unnamed.jpg +0 -0
- banko_ai/static/creditcard_files/vendor-react-76e71fd67c83934b.mjs +54 -0
- banko_ai/static/creditcard_files/visual-search-fe95849c7568d600.mjs +123 -0
- banko_ai/static/css/style.css +1274 -0
- banko_ai/templates/dashboard.html +5 -5
- banko_ai/templates/index.html +6 -6
- banko_ai/web/app.py +14 -2
- {banko_ai_assistant-1.0.0.dist-info → banko_ai_assistant-1.0.1.dist-info}/METADATA +2 -2
- banko_ai_assistant-1.0.1.dist-info/RECORD +164 -0
- banko_ai_assistant-1.0.0.dist-info/RECORD +0 -46
- {banko_ai_assistant-1.0.0.dist-info → banko_ai_assistant-1.0.1.dist-info}/WHEEL +0 -0
- {banko_ai_assistant-1.0.0.dist-info → banko_ai_assistant-1.0.1.dist-info}/entry_points.txt +0 -0
- {banko_ai_assistant-1.0.0.dist-info → banko_ai_assistant-1.0.1.dist-info}/licenses/LICENSE +0 -0
- {banko_ai_assistant-1.0.0.dist-info → banko_ai_assistant-1.0.1.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,252 @@
|
|
1
|
+
"use strict";(self.__LOADABLE_LOADED_CHUNKS__=self.__LOADABLE_LOADED_CHUNKS__||[]).push([[73489,96833,71526],{983707:e=>{var t={argumentDefinitions:[],kind:"Fragment",metadata:null,name:"FullPageResponse_pin",selections:[{alias:null,args:null,kind:"ScalarField",name:"entityId",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"description",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"title",storageKey:null},{args:null,kind:"FragmentSpread",name:"useFindImageBySize_pin"}],type:"Pin",abstractKey:null};t.hash="ccea2eef3e65889aefb1fe35ca2f2bd2",e.exports=t},170128:e=>{var t,i={argumentDefinitions:[],kind:"Fragment",metadata:null,name:"useFindImageBySize_pin",selections:[{alias:"imageSpec_orig",args:[{kind:"Literal",name:"spec",value:"orig"}],concreteType:"ImageDetails",kind:"LinkedField",name:"images",plural:!1,selections:t=[{alias:null,args:null,kind:"ScalarField",name:"height",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"url",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"width",storageKey:null}],storageKey:'images(spec:"orig")'},{alias:"imageSpec_736x",args:[{kind:"Literal",name:"spec",value:"736x"}],concreteType:"ImageDetails",kind:"LinkedField",name:"images",plural:!1,selections:t,storageKey:'images(spec:"736x")'},{alias:"imageSpec_564x",args:[{kind:"Literal",name:"spec",value:"564x"}],concreteType:"ImageDetails",kind:"LinkedField",name:"images",plural:!1,selections:t,storageKey:'images(spec:"564x")'},{alias:"imageSpec_474x",args:[{kind:"Literal",name:"spec",value:"474x"}],concreteType:"ImageDetails",kind:"LinkedField",name:"images",plural:!1,selections:t,storageKey:'images(spec:"474x")'},{alias:"imageSpec_236x",args:[{kind:"Literal",name:"spec",value:"236x"}],concreteType:"ImageDetails",kind:"LinkedField",name:"images",plural:!1,selections:t,storageKey:'images(spec:"236x")'},{alias:"imageSpec_170x",args:[{kind:"Literal",name:"spec",value:"170x"}],concreteType:"ImageDetails",kind:"LinkedField",name:"images",plural:!1,selections:t,storageKey:'images(spec:"170x")'}],type:"Pin",abstractKey:null};i.hash="1cecb885d07496a18ebf10e9ee8c3953",e.exports=i},157796:(e,t,i)=>{i.d(t,{Z:()=>s});var n=i(667294),o=i(883119),l=i(785893);function s({color:e="red",duration:t,finalProgress:i,shape:s="pill"}){let[a,r]=(0,n.useState)(!1);(0,n.useEffect)(()=>{let e=setTimeout(()=>{r(!0)},0);return()=>{clearTimeout(e)}},[]);let d="pill"===s;return(0,l.jsx)(o.xu,{color:e,height:d?8:6,rounding:d?"pill":2,width:`${i}%`,dangerouslySetInlineStyle:{__style:{transform:d?`translateX(${a?"-5px":"-100%"})`:`scaleX(${a?1:0})`,transformOrigin:"left",transitionDuration:`${t}ms`,transitionTimingFunction:"ease-in"}}})}},489582:(e,t,i)=>{i.d(t,{c:()=>Q,Z:()=>ee});var n=i(667294),o=i(702664),l=i(616550),s=i(883119),a=i(469134),r=i(176326),d=i(898781),c=i(773285),u=i(100110),p=i(785893);let h=()=>Promise.resolve();function _({errorMessage:e,value:t,useNewFormat:i=!1,isInRevampPageExp:o=!1,setValidState:l=()=>{},setBirthday:_=()=>{}}){let g=(0,d.ZP)(),{checkExperiment:m}=(0,c.F)(),x=m("adv_growth_biz_signup_birthday_new_copy").anyEnabled,b=g._('To help keep Pinterest safe, we now require your birthdate. Your birthdate also helps us provide more personalized recommendations and relevant ads. We don\'t share this information and it won\'t be visible on your profile.', 'businessAccountCreate.birthdate.label.tooltip.description', 'Tooltip explaining why we require birthdate'),f=g._('As the person creating the business account, please provide your birthdate. This info is used to provide a better, safer experience for the younger people in our community and will not be publicly displayed.', 'businessAccountCreate.birthdate.label.tooltip.newDescription', 'Revised tooltip explaining why we require birthdate'),[y,v]=(0,n.useState)(null),[w,j]=(0,n.useState)(null),S=e=>{let t=e.toString();e&&!(0,a.M5)(t)?v(g._('The birthdate you entered may have an error. Please try again.', 'settings.birthdate.errors.minMaxAge', 'Error message to be displayed when the user input a age <5 or >120')):y&&v(null),j(e),_((0,a.IA)(t))};return(0,p.jsxs)(s.xu,{"data-test-id":"business-birthdate",paddingY:o?4:1,position:"relative",zIndex:new s.Ry(2),children:[(0,p.jsxs)(s.xu,{alignItems:"center",marginBottom:o?4:0,display:"flex",children:[(0,p.jsx)(s.xu,{marginEnd:2,marginBottom:o?0:1,marginStart:2,children:(0,p.jsx)(s.__,{htmlFor:"birthdate",children:(0,p.jsx)(s.xv,{size:o?"300":"200",children:g._('Birthdate', 'businessAccountCreate.birthdate.label', 'Label for Birthdate field')})})}),(0,p.jsx)(s.u,{zIndex:new s.Ry(1e4),idealDirection:"right",text:x?f:b,children:(0,p.jsx)(s.JO,{accessibilityLabel:g._('Tooltip', 'businessAccountCreate.birthdate.label.tooltip.icon', 'accessibility tooltip for birthdate'),icon:"info-circle"})})]}),(0,p.jsx)(s.xu,{"data-test-id":"signup-birthdate-field",children:i&&!o?(0,p.jsx)(u.Z,{handleChangeBirthday:h,birthday:t,setBirthday:_,setValidState:l}):(0,p.jsx)(r.Mt,{id:"birthdate",idealDirection:"down",name:"birthdate",maxDate:new Date,errorMessage:e||y||"",onChange:({value:e})=>S(e||new Date),placeholder:g._('MM/DD/YYYY', 'businessAccountCreate.birthdate.placeholder', 'Placeholder for the birthdate field'),selectLists:["year","month"],value:w})})]})}var g=i(56641),m=i(146395),x=i(664433),b=i(369309),f=i(489670),y=i(118494),v=i(904431),w=i(924196),j=i(407043),S=i(385740),P=i(231486),k=i(226198),A=i(816068),C=i(766935),z=i(233211),Z=i(597922),I=i(754124),T=i(186656),E=i(349700),L=i(966224),B=i(584595),M=i(780280),O=i(966113),R=i(826067),D=i(123906),F=i(19121),N=i(824385),U=i(134906),H=i(67347);function W(e,t,i){var n;return(t="symbol"==typeof(n=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"))?n:String(n))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}let $=O.R_9,G=O.V$B,Y=O.cvl,K=(0,x.$)("create_business_account_singlestep."),X=e=>K(`${e}FieldFocused`),q=[B.bd,B.Jt],J=["6e9dfd","carousel_onboarding"];class V extends n.Component{constructor(...e){var t;super(...e),t=this,W(this,"state",{clickedSubmit:!1,shouldShowUnderageConfirmationModal:!1,email:"",password:"",birthdayString:"",errors:{businessName:[],email:[],password:[],birthdayString:[]}}),W(this,"validators",{email:[(0,U.aH)({message:this.props.i18n._('You missed a spot! Don\'t forget to add your email.', 'businessAccountCreate.email.error.required', 'Prompt user to input email when email field is empty')}),(0,U.GT)({message:this.props.i18n._('Hmm... that doesn\'t look like an email address.', 'businessAccountCreate.email.error.invalid', 'Prompt user to input a valid email')})],password:[(0,U.aH)({message:this.props.i18n._('Your password is too short! You need 6+ characters.', 'businessAccountCreate.password.error.required', 'Prompt user to input password when password field is empty')}),(0,U.oR)({message:this.props.i18n._('Use only a mix of letters, numbers and special characters (for example: ?, !, $).', 'businessAccountCreate.password.error.onlyASCII', 'Only ASCII characters are allowed for password')}),(0,N.Z)({shortPassStr:this.props.i18n._('Your password is too short! You need 6+ characters.', 'businessAccountCreate.password.error.short', 'Password must be at least 6 characters'),samePasswordStr:this.props.i18n._('Please make your username and password different.', 'businessAccountCreate.password.error.invalid', 'Password and username cannot be the same, user must choose a new password'),blackPassStr:this.props.i18n._('Please make a stronger password.', 'businessAccountCreate.password.error.weak', 'Password is too simple')})],businessName:[(0,U.aH)({message:this.props.i18n._('You missed a spot! Don\'t forget to add your business name.', 'businessAccountCreate.businessName.error.required', 'Prompt user to input business name when business name field is empty')})],birthdayString:[(0,U.aH)({message:this.props.i18n._('You missed a spot. Don\u2019t forget to add your birthdate.', 'businessAccountCreate.birthdate.error.required', 'Prompt user to input a valid birthdate')}),(0,U.ES)({date:new Date(new Date().getFullYear(),0,1),message:(0,a.Uy)(this.props.i18n)})]}),W(this,"setUnderageError",()=>{let e=this.props.i18n._('Sorry, you\u2019re not eligible to sign up for Pinterest right now.', 'businessAccountCreate.age.error.underage', 'Error message for underage users');this.setState(({errors:t})=>({errors:{...t,birthdayString:[e]}}))}),W(this,"getLoginUrl",()=>{let{location:{search:e}}=this.props;if(e&&"next"in(0,R.mB)(e))return(0,D.Z)("/business/login",{next:(0,R.mB)(e).next});let t=this.inAdCreditsCampaign()?(0,R.ru)("/business/create/",{utm_medium:"adcredits"}):"/business/create/";return(0,D.Z)("/business/login",{next:t})}),W(this,"handleFieldChange",(e,t)=>{let i;i=t.nativeEvent?t.nativeEvent.target.value:t.value?t.value:t,this.setState({[e]:i}),this.state.clickedSubmit&&this.validateField(e,i)}),W(this,"validateField",(0,C.Z)((e,t)=>{let i=this.validators[e];(0,U.Ks)(i,t).then(t=>{this.setState(({errors:i})=>({errors:{...i,[e]:t}}))})},x.w)),W(this,"hasValidationErrors",async function(e){let i=await (0,U.Ks)(t.validators[e],t.state[e]);return i.length>0&&(t.setState(({errors:t})=>({errors:{...t,[e]:i}})),!0)}),W(this,"validateForm",async function(){let e=await t.hasValidationErrors("birthdayString"),i=await t.hasValidationErrors("email"),n=await t.hasValidationErrors("password");return!(i||n||e)}),W(this,"handleFormSubmission",async function(e){e&&e.preventDefault&&e.preventDefault(),K("submit_clicked");let{email:i,password:n,birthdayString:o}=t.state,{i18n:l,unifiedSignup:s,location:{search:a},requestContext:r,viewer:d,logContextEvent:c,pixelBlocked:u,register:p,setIsSumittingForm:h,setIsUnderageConfirmationModalVisible:_}=t.props;h(!0);let m=(0,R.mB)(a)||{},x=i.split("@")[0],b=await t.validateForm();if(t.setState({clickedSubmit:!0}),c({event_type:101,component:13097,element:10283,aux_data:{successful_frontend_validation:b,in_unified_modal:s}}),"1"===P.U2(k.It)){t.setUnderageError(),h(!1);return}let y=o?(0,A.Z)(o):void 0;if(!b||void 0===y){h(!1);return}(0,T.Z)({url:"/v3/register/exists/",data:{email:i}}).then(e=>{if(e.resource_response.data)t.setState(({errors:e})=>({errors:{...e,email:[l._('Deja vu! That email\'s taken.', 'businessAccountCreate.email.error.taken', 'User entered an email that is already taken')]}})),h(!1);else{let e="utm_source"in m&&"shopify"===m.utm_source;(0,f.Z)("client.partner.account.create_attempt",{source:{utmPartner:m.utm_partner,utmSource:m.utm_source,utmMedium:m.utm_medium},isAuth:!1,unifiedSignup:s,country:r.country}),p({type:"email",birthday:y,business_name:x,email:i,password:n,has_ads_credits:t.inAdCreditsCampaign(),third_party_apps:e?[0]:null,utm_campaign:m.utm_campaign},{signupContext:void 0,signupAttemptContextEvent:{event_type:7537,view_type:156,view_parameter:3129}}).then(()=>{K("signup_success"),(0,f.Z)("client.partner.account.create",{source:{utmPartner:m.utm_partner,utmSource:m.utm_source,utmMedium:m.utm_medium},isAuth:!1,unifiedSignup:s,country:r.country}),c({event_type:8631,view_type:7,view_parameter:3561}),J.indexOf(m.utm_campaign)>=0&&(0,H.nP)("catalogs.carousel.merchant.create.success",{sampleRate:1,tags:{email:i}});let e=m&&"next"in m?m.next:null;d.third_party_marketing_tracking_enabled?(v.Z.reportFacebookConversion(w.Z.FACEBOOK_ADVERTISER_ID,"CompleteRegistration",{content_name:"/business/create"}),v.Z.reportPinterestConversion("track","lead",{lead_type:"Self-serve"}),v.Z.reportLinkedInConversion(w.Z.LINKEDIN_PARTNER_ID,w.Z.LINKEDIN_CONVERSION_ID_SUBMISSION_EVENT),v.Z.reportGoogleConversion(w.Z.GOOGLE_ADWORDS_ID,w.Z.GOOGLE_ADWORDS_LABEL_BUSINESS_CREATE,e?void 0:"/",u)):window.location.assign(e?void 0:"/"),e&&(0,g.Z)((0,D.Z)("/",{next:e}))},e=>{let i={errors:t.state.errors};[B.dj,B.tL].includes(e.api_error_code)?i.errors.birthdayString=[e.message]:e.api_error_code===B.tz?(P.t8(k.It,"1",(0,P.kZ)(k.It)),t.setState({shouldShowUnderageConfirmationModal:!0}),_(!0)):q.includes(e.api_error_code)&&(i.errors.email=[e.message]),t.setState(i),h(!1)})}},()=>{t.setState(({errors:e})=>({errors:{...e,email:[l._('Add a valid email', 'businessAccountCreate.email.error.invalid', 'Prompt user to input a valid email')]}})),h(!1)})}),W(this,"inAdCreditsCampaign",()=>{let{location:e}=this.props;return(0,b.Z)(e)}),W(this,"setBirthday",e=>{this.handleFieldChange("birthdayString",e)}),W(this,"setValidState",e=>{this.setState(({errors:t})=>({errors:{...t,birthdayString:[e]}}))})}componentDidMount(){let{location:e,logContextEvent:t,viewer:i,viewType:n,pixelBlocked:o}=this.props;K("loaded"),i.third_party_marketing_tracking_enabled&&(v.Z.insertGoogleAdWordsTag(w.Z.GOOGLE_ADWORDS_ID,o),v.Z.insertFacebookPixelTag(w.Z.FACEBOOK_ADVERTISER_ID),v.Z.insertPinterestTag(w.Z.SMB_PAID_PINTEREST_ID)),"1"===P.U2(k.It)&&this.setUnderageError(),n||t({event_type:13,view_type:156,view_parameter:3129}),t({event_type:120,component:13097,aux_data:{in_unified_modal:this.props.unifiedSignup}}),(0,y.kh)(e.search),(0,H.nP)("partner.business_account_create.visit",{sampleRate:1,tags:{platform:"web"}})}render(){let{email:e,errors:t,password:i,birthdayString:o,shouldShowUnderageConfirmationModal:l}=this.state,{unifiedSignup:a,secondaryAccountFlow:r,isSubmittingForm:d,i18n:c,setIsUnderageConfirmationModalVisible:u,newBirthdayFormat:h,isInRevampPageExp:g=!1,onRedirectToLogin:x=()=>{}}=this.props,b=this.inAdCreditsCampaign(),f=g?(0,p.jsxs)(s.xu,{paddingY:6,display:"flex",children:[(0,p.jsx)(s.xv,{weight:"normal",size:"300",children:this.props.i18n._('Already have a business account?', 'businessAccountCreate.loginLink.text', 'The text to let user login')}),(0,p.jsx)(s.xu,{marginStart:1,children:(0,p.jsx)(s.rU,{href:"#",display:"inlineBlock",onClick:({event:e,dangerouslyDisableOnNavigation:t})=>{e.preventDefault(),t(),x()},children:(0,p.jsx)(s.xv,{weight:"normal",size:"300",children:this.props.i18n._('Log in', 'businessAccountCreate.loginLink.CTA', 'The actual CTA to redirect user to login page')})},0)})]}):(0,p.jsx)(s.xu,{"data-test-id":"business-existing-account",paddingY:1,children:(0,p.jsx)(s.ZP,{fullWidth:!0,size:"md",onClick:({dangerouslyDisableOnNavigation:e})=>e(),href:this.getLoginUrl(),target:"self",text:this.props.i18n._('Log into existing account', 'businessAccountCreate.logInto.button', 'Text for button where user can click to log into an exisiting account')})}),y=g?"subtle":void 0,v=(0,E.nk)(this.props.i18n._('By continuing, you agree to Pinterest\'s {{ termsLink }} and acknowledge you\'ve read our {{ privacyLink }}. {{ noticeAtCollection }}', 'businessAccountCreate.birthday.agreement.text', 'Notice that proceeding indicates acceptance of term and policy (termsLink: link element for terms of use, privacyLink: link element for privacy policy, noticeAtCollection: link element for notice at collection)'),{termsLink:(0,p.jsx)("span",{"data-test-id":"business-tos",children:(0,p.jsx)(s.xv,{inline:!0,weight:"bold",size:"100",color:y,children:(0,p.jsx)(s.rU,{href:G,target:"blank",display:"inlineBlock",onClick:({dangerouslyDisableOnNavigation:e})=>e(),underline:"hover",children:this.props.i18n._('Business Terms of Service', 'businessAccountCreate.termsOfService.link.text', 'Link to Terms of Service')},0)})},"business-tos"),privacyLink:(0,p.jsx)("span",{"data-test-id":"privacy",children:(0,p.jsx)(s.xv,{inline:!0,weight:"bold",size:"100",color:y,children:(0,p.jsx)(s.rU,{href:$,target:"blank",display:"inlineBlock",onClick:({dangerouslyDisableOnNavigation:e})=>e(),underline:"hover",children:this.props.i18n._('Privacy Policy', 'businessAccountCreate.privacyPolicy.link.text', 'Link to Pinterest Privacy Policy')},1)})},"privacy"),noticeAtCollection:(0,p.jsx)("span",{"data-test-id":"noticeAtCollection",children:(0,p.jsx)(s.xv,{inline:!0,weight:"bold",size:"100",color:y,children:(0,p.jsx)(s.rU,{href:Y,target:"blank",display:"inlineBlock",onClick:({dangerouslyDisableOnNavigation:e})=>e(),underline:"hover",children:c._('Notice at collection', 'termOfService.link.noticeAtCollection', 'Link to notice at collection')},"noticeAtCollectionLink")})},"noticeAtCollection")});return(0,p.jsxs)(n.Fragment,{children:[l&&(0,p.jsx)(s.mh,{children:(0,p.jsx)(s.xu,{color:"transparent",position:"fixed",zIndex:new s.Ry(1e4),top:!0,left:!0,right:!0,bottom:!0,display:"flex",alignItems:"center",justifyContent:"center",children:(0,p.jsx)(s.xu,{rounding:8,color:"light",borderStyle:"shadow",children:(0,p.jsx)(I.Z,{birthday:o,onEditBirthday:()=>{this.setState({shouldShowUnderageConfirmationModal:!1}),u(!1)}})})})}),(0,p.jsx)("form",{method:"POST",noValidate:!0,onSubmit:this.handleFormSubmission,children:(0,p.jsxs)(s.xu,{children:[(0,p.jsxs)(s.xu,{"data-test-id":"business-email",paddingY:g?4:1,position:"relative",zIndex:new s.Ry(2),children:[(0,p.jsx)(s.xu,{marginBottom:g?4:1,marginStart:2,children:(0,p.jsx)(s.__,{htmlFor:"email",children:(0,p.jsx)(s.xv,{size:g?"300":"200",children:c._('Email', 'businessAccountCreate.email.label', 'Label for email field')})})}),(0,p.jsx)(Z.Z,{hasError:t.email.length>0,id:"email",name:"email",onChange:e=>{this.handleFieldChange("email",e)},onFocus:()=>X("email"),placeholder:this.props.i18n._('Email', 'businessAccountCreate.email.placeholder', 'Placeholder text for email field'),tooltip:t.email.length>0?t.email[0]:null,type:"email",useExperimentalTextfield:a,value:e})]}),(0,p.jsxs)(s.xu,{"data-test-id":"business-password",paddingY:g?4:1,position:"relative",zIndex:new s.Ry(2),children:[(0,p.jsx)(s.xu,{marginBottom:g?4:1,marginStart:2,children:(0,p.jsx)(s.__,{htmlFor:"password",children:(0,p.jsx)(s.xv,{size:g?"300":"200",children:c._('Password', 'businessAccountCreate.password.label', 'Label for password field')})})}),(0,p.jsx)(Z.Z,{hasError:t.password.length>0,id:"password",name:"password",onChange:e=>{this.handleFieldChange("password",e)},onFocus:()=>X("password"),placeholder:a?this.props.i18n._('Create a password', 'businessAccountCreate.password.placeholder', 'Placeholder text for password field'):this.props.i18n._('Password', 'businessAccountCreate.password.placeholder', 'Placeholder text for password field'),tooltip:t.password.length>0?t.password[0]:null,type:"password",useExperimentalTextfield:a,value:i})]}),(0,p.jsx)(_,{errorMessage:t.birthdayString[0]||null,setBirthday:this.setBirthday,value:o,useNewFormat:h,isInRevampPageExp:g,setValidState:this.setValidState}),(0,p.jsx)(s.xu,{"data-test-id":"business-create-account",paddingY:g?4:1,children:(0,p.jsx)(s.zx,{fullWidth:!0,color:"red",disabled:d,onClick:()=>{this.handleFormSubmission()},type:"submit",text:this.props.i18n._('Create account', 'businessAccountCreate.createAccount.business', 'Button text for creating a business account'),size:"md"})}),!r&&f,(0,p.jsxs)(s.xu,{paddingY:1,children:[g?(0,p.jsx)(s.xv,{size:"100",align:"start",overflow:"normal",color:y,children:v}):(0,p.jsx)(s.xv,{size:"100",align:b?"start":"center",overflow:"normal",children:v}),b&&(0,p.jsx)(s.xv,{size:"100",align:"start",overflow:"normal",children:m.Z})]})]})})]})}}function Q(e){let t=(0,d.ZP)(),i=(0,l.useLocation)(),n=(0,M.B)(),{logContextEvent:s}=(0,j.v)(),{register:a}=(0,z.B$)(),{viewType:r}=(0,S.SU)(),u=(0,o.useDispatch)(),{checkExperiment:h}=(0,c.F)(),_=h("ppm_p_gate").anyEnabled,g=h("adv_growth_biz_signup_birthday_format").anyEnabled;return(0,p.jsx)(V,{...e,setIsUnderageConfirmationModalVisible:e=>{u({type:"SET_IS_UNDERAGE_CONFIRMATION_MODAL_VISIBLE",payload:{isUnderageConfirmationModalVisible:e}})},unifiedSignup:!!e.unifiedSignup,location:i,pixelBlocked:_,newBirthdayFormat:g,requestContext:n,viewer:(0,F.Z)(),register:a,i18n:t,logContextEvent:s,viewType:r})}function ee({secondaryAccountFlow:e}){let[t,i]=(0,n.useState)(!1);return(0,p.jsxs)(s.kC,{alignItems:"center",justifyContent:"center",children:[t&&(0,p.jsx)(L.Z,{}),(0,p.jsx)(s.xu,{width:268,color:"default",children:(0,p.jsx)(Q,{isSubmittingForm:t,secondaryAccountFlow:e,setIsSumittingForm:i,unifiedSignup:!0})})]})}},583375:(e,t,i)=>{i.d(t,{Z:()=>s});var n=i(858472),o=i(898781),l=i(785893);function s({fillColor:e,size:t,noCircle:i}){let s=(0,o.ZP)();return(0,l.jsxs)("svg",{height:t,style:{display:"block"},viewBox:i?"3 3 70 70":"-3 -3 82 82",width:t,children:[(0,l.jsx)("title",{children:s._('Pinterest logo', 'Accessibility label for Pinterest icon', 'Accessibility label for Pinterest icon')}),i?null:(0,l.jsx)("circle",{cx:"38",cy:"38",fill:e?"transparent":"white",r:"40"}),(0,l.jsx)("path",{d:"M27.5 71c3.3 1 6.7 1.6 10.3 1.6C57 72.6 72.6 57 72.6 37.8 72.6 18.6 57 3 37.8 3 18.6 3 3 18.6 3 37.8c0 14.8 9.3 27.5 22.4 32.5-.3-2.7-.6-7.2 0-10.3l4-17.2s-1-2-1-5.2c0-4.8 3-8.4 6.4-8.4 3 0 4.4 2.2 4.4 5 0 3-2 7.3-3 11.4C35.6 49 38 52 41.5 52c6.2 0 11-6.6 11-16 0-8.3-6-14-14.6-14-9.8 0-15.6 7.3-15.6 15 0 3 1 6 2.6 8 .3.2.3.5.2 1l-1 3.8c0 .6-.4.8-1 .4-4.4-2-7-8.3-7-13.4 0-11 7.8-21 22.8-21 12 0 21.3 8.6 21.3 20 0 12-7.4 21.6-18 21.6-3.4 0-6.7-1.8-7.8-4L32 61.7c-.8 3-3 7-4.5 9.4z",fill:null!=e?e:n.x7,fillRule:"evenodd"})]})}},501338:(e,t,i)=>{i.d(t,{Pw:()=>n,SB:()=>o,ZP:()=>s,x9:()=>l});let n=80,o=56,l=e=>"phone"===e?o:n;function s(e,t){return t?0:l(e)}},283698:(e,t,i)=>{i.d(t,{Z:()=>n});function n(e){return("undefined"==typeof window||!Object.prototype.hasOwnProperty.call(window,"requestAnimationFrame"))&&e&&e(),window.requestAnimationFrame(()=>{window.requestAnimationFrame(()=>{e&&e()})})}},100183:(e,t,i)=>{i.d(t,{CC:()=>o,Ll:()=>s,XF:()=>l});let n=(e,t,i)=>({x:Math.floor(e*Math.cos(i)),y:Math.floor(t*Math.sin(i))}),o=(e,t)=>n(t/2,e/2,2*Math.random()*Math.PI),l=(e,t)=>Math.floor(Math.random()*(t-e+1))+e,s=e=>["@-webkit-keyframes","@keyframes"].map(t=>e.map(e=>t+" "+e).join("\n")).join("\n")},780678:(e,t,i)=>{i.d(t,{Z:()=>o,v:()=>n});let n=()=>"undefined"!=typeof navigator&&"getInstalledRelatedApps"in navigator;async function o(){if(!n())return[];try{let e=await navigator.getInstalledRelatedApps();return e}catch(e){return[]}}},436851:(e,t,i)=>{i.d(t,{$K:()=>r,dh:()=>n,ry:()=>a});let n=e=>/instagram/i.test(e||""),o=e=>/facebook/i.test(e||""),l=e=>/line/i.test(e||""),s=e=>/wechat/i.test(e||""),a=e=>n(e)||o(e)||l(e)||s(e),r=e=>(e||"").includes("[Pinterest/iOS]")||(e||"").includes("[Pinterest/Android]")},204324:(e,t,i)=>{i.d(t,{Z:()=>s});var n=i(616550),o=i(78714),l=i(50286);function s(){let e=(0,n.useHistory)(),t=(0,l.HG)();return i=>{t?(0,o.Z)(i,{disableOriginCheck:!0}):e.push(i)}}},146395:(e,t,i)=>{i.d(t,{Z:()=>n});let n="*Spend $30 in your first 7 days to receive a $20 refund on your bill. There’s a 1 offer limit per account. New accounts only. You must be a legal resident of the 50 United States or DC, and at least 18 years old to be eligible for this offer."},664433:(e,t,i)=>{i.d(t,{$:()=>l,w:()=>o});var n=i(67347);let o=300,l=e=>t=>(0,n.nP)(e+t,{sampleRate:1})},369309:(e,t,i)=>{i.d(t,{Z:()=>o});var n=i(826067);let o=e=>!!(e&&e.search)&&"adcredits"===(0,n.mB)(e.search).utm_medium},489670:(e,t,i)=>{i.d(t,{Z:()=>l});var n=i(67347);let o=e=>e.source&&e.source.utmPartner&&"partneracquisition"===e.source.utmPartner,l=(e,t)=>{let i=!!(t&&t.isAuth),l=!!(t&&t.unifiedSignup),s=t&&t.country;t&&o(t)?(0,n.nP)(e,{sampleRate:1,tags:{app_type:"web",is_paid:!0,paid_source:t.source.utmSource,is_auth:i,unified_signup:l}}):(0,n.nP)(e,{sampleRate:1,tags:{app_type:"web",is_auth:i,unified_signup:l,country:s}})}},118494:(e,t,i)=>{i.d(t,{DM:()=>d,Q2:()=>r,kh:()=>a,wK:()=>c});var n=i(339363),o=i(388619);let l="AMEX_MERCHANT_HUB_OFFER",s="business.marketing.offer",a=e=>{let t=(0,o.Z)({url:e});t.offerCode===l&&(0,n.Nh)(s,l)},r=()=>(0,n.qn)(s)===l,d=()=>(0,n.qn)(s),c=()=>{(0,n.L_)(s)}},989392:(e,t,i)=>{i.d(t,{Z:()=>n});let n=(e,t)=>{let i=new Date;return new Date(1e3*e)<=new Date(i.getFullYear()-(t||18),i.getMonth(),i.getDate())}},816068:(e,t,i)=>{i.d(t,{Z:()=>n});let n=e=>Math.floor(new Date(e).getTime()/1e3)},856241:(e,t,i)=>{i.d(t,{Z:()=>n});let n=e=>{let t=new Date(e);return new Date(t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate())}},966476:(e,t,i)=>{i.d(t,{Z:()=>o});var n=i(667294);let o=()=>{let[e,t]=(0,n.useState)(!1);return(0,n.useEffect)(()=>{t(!0)},[]),e}},803491:(e,t,i)=>{i.d(t,{Z:()=>s,m:()=>l});var n=i(858472),o=i(785893);let l=`
|
2
|
+
.red.active:focus,
|
3
|
+
.red.active:hover {
|
4
|
+
background-color: #d50c22 !important;
|
5
|
+
}
|
6
|
+
.lightGrey.active:focus,
|
7
|
+
.lightGrey.active:hover {
|
8
|
+
background-color: #f5f3f3 !important;
|
9
|
+
}
|
10
|
+
.SignupButton:focus {
|
11
|
+
box-shadow: 0 0 0 4px rgba(0, 132, 255, 0.5);
|
12
|
+
outline: 0;
|
13
|
+
}
|
14
|
+
`;function s({accessibilityLabel:e,children:t,className:i,dataTestId:l,disabled:s,href:a,id:r,noButtonStyles:d,onClick:c,styleOverrides:u,tabIndex:p,type:h}){let _=(i?i.split(" "):[]).concat(s?[]:["active"]),g=d?{background:"none",border:"none",padding:"0",textAlign:"left",display:"block"}:{border:"0px",height:"40px",display:"inline-block",borderRadius:"4px",WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",padding:"0 18px",fontSize:"15px",fontWeight:"bold",cursor:"pointer",marginTop:"10px",verticalAlign:"middle",textAlign:"center",...s&&{backgroundColor:"#efefef",color:"#767676"}||_.includes("red")&&{backgroundColor:n.x7,color:"#fff"}||_.includes("lightGrey")&&{backgroundColor:"#ebebeb",color:"#444"}};return g={...g,...u},s&&(g={...g,cursor:"not-allowed"}),(0,o.jsx)("button",{"aria-label":e||"",className:_.join(" "),"data-test-id":l,disabled:s,href:a,id:r,onClick:c,...p?{tabIndex:p}:{},style:g,type:h||"button",children:t})}},89136:(e,t,i)=>{i.d(t,{Z:()=>S});var n,o=i(667294);i(167912);var l=i(883119),s=i(214494),a=i(157796),r=i(356997),d=i(898781),c=i(290148),u=i(785893);let p=({color:e="#efefef",width:t=500,reverse:i=!1})=>(0,u.jsx)("svg",{"data-name":"Layer 1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 180 113",width:t,children:(0,u.jsx)("g",{children:(0,u.jsx)("g",{children:(0,u.jsx)("g",{children:(0,u.jsx)("path",{d:i?"M49.33871,98.67741A49.33871,49.33871,0,0,1,49.33871,0h81.32258a49.33871,49.33871,0,0,1,0,98.67742H104.34757l3.17049,12.02761c.64946,1.2671-1.29892,2.53419-2.59784,1.90064L76.22791,98.67741Z":"M103.77209,98.67741,75.07978,112.60566c-1.29892.63355-3.2473-.63354-2.59784-1.90064l3.17049-12.02761H49.33871A49.33871,49.33871,0,0,1,49.33871,0h81.32258a49.33871,49.33871,0,0,1,0,98.67742Z",fill:e})})})})}),h=()=>(0,u.jsx)(r.qE,{name:"unauthUser",src:"https://i.pinimg.com/originals/d1/7f/3d/d17f3dbfdeaadfb3cddbf956f0c203d0.png"}),_=({sender:e,showIconScale:t})=>{let i=(0,d.ZP)(),n=e?e.first_name:"",s=e?e.image_medium_url:"";return(0,u.jsxs)(o.Fragment,{children:[(0,u.jsxs)(l.xu,{children:[(0,u.jsx)(l.xu,{position:"absolute",width:100,height:100,dangerouslySetInlineStyle:{__style:{top:"25%",left:"25%"}},children:(0,u.jsx)(r.qE,{name:n,src:s})}),(0,u.jsx)(l.xu,{position:"absolute",dangerouslySetInlineStyle:{__style:{top:"10%",left:"30%"}},children:(0,u.jsx)(p,{width:200})})]}),(0,u.jsxs)(l.xu,{children:[(0,u.jsx)(l.xu,{position:"absolute",width:100,height:100,dangerouslySetInlineStyle:{__style:{bottom:"26%",right:"19%"}},children:(0,u.jsx)(h,{})}),(0,u.jsxs)(l.xu,{position:"absolute",dangerouslySetInlineStyle:{__style:{bottom:"35%",right:"27%"}},children:[(0,u.jsx)(l.xu,{position:"absolute",dangerouslySetInlineStyle:{__style:{left:"42%",top:"32%",...t?{transform:"scale(1.8)",transition:"all .8s cubic-bezier(0.66, 0.025, 0.33, 0.975)"}:Object.freeze({})}},children:(0,u.jsx)(l.JO,{accessibilityLabel:i._('checkmark Green', 'accesibility label for a green checkmark icon', 'accesibility label for a green checkmark icon'),icon:"check-circle",color:"success",size:25})}),(0,u.jsx)(p,{reverse:!0,width:200})]})]}),(0,u.jsx)(l.xu,{position:"absolute",dangerouslySetInlineStyle:{__style:{bottom:"13%",right:"32%"}},children:(0,u.jsx)(l.xu,{dangerouslySetInlineStyle:{__style:t?{opacity:1,transition:"opacity .5s cubic-bezier(0.66, 0.025, 0.33, 0.975)"}:{opacity:0}},children:(0,u.jsx)(l.X6,{children:i._('Message sent!', 'Response letting users know the message they wrote just sent', 'Response letting users know the message they wrote just sent')})})})]})},g=()=>{let e=(0,d.ZP)(),[t,i]=(0,o.useState)(!1);return(0,o.useEffect)(()=>{let e=window.setTimeout(()=>{i(!0)},100);return()=>{window.clearTimeout(e)}},[]),(0,u.jsxs)(o.Fragment,{children:[(0,u.jsx)(l.xu,{position:"absolute",width:100,height:100,dangerouslySetInlineStyle:{__style:t?{bottom:"26%",right:"19%",transition:"transform .8s cubic-bezier(0.66, 0.025, 0.33, 0.975)",transform:"translate(-11em, -16em)"}:{bottom:"26%",right:"19%",transition:"transform .8s cubic-bezier(0.66, 0.025, 0.33, 0.975)"}},children:(0,u.jsx)(h,{})}),(0,u.jsx)(l.xu,{position:"absolute",maxWidth:"52%",dangerouslySetInlineStyle:{__style:{bottom:"24%",right:"23%"}},children:(0,u.jsxs)(l.xu,{dangerouslySetInlineStyle:{__style:t?{opacity:1,transition:"opacity .5s cubic-bezier(0.66, 0.025, 0.33, 0.975)",transitionDelay:".8s"}:{opacity:0}},children:[(0,u.jsx)(l.X6,{children:e._('Now, set up your Pinterest account', 'header asking users to set up Pinteret account after signing up', 'header asking users to set up Pinteret account after signing up')}),(0,u.jsx)(l.xu,{paddingY:6,children:(0,u.jsx)(l.xv,{align:"center",weight:"bold",children:(0,u.jsx)("span",{className:"deprecatedTextSizeXL",children:e._('This creates a home feed of ideas you\'ll love', 'after signup and transition going into the nux step which will help customize their experience', 'after signup and transition going into the nux step which will help customize their experience')})})})]})})]})};function m({sender:e}){let[t,i]=(0,o.useState)(!1),[n,s]=(0,o.useState)(!1);return(0,o.useEffect)(()=>{let e=null;return e=window.setTimeout(()=>{i(!0),e=window.setTimeout(()=>{s(!0),e=window.setTimeout(()=>{c.ZP.handleSignupRedirect("/",!0)},3e3)},3e3)},500),()=>{window.clearTimeout(e)}},[]),(0,u.jsx)(l.xu,{marginTop:12,display:"flex",flex:"grow",children:n?(0,u.jsx)(g,{}):(0,u.jsx)(_,{sender:e,showIconScale:t})})}var x=i(357998);function b({alt:e,className:t,errorFallback:i,onLoad:n,src:l,srcSet:s,style:a}){let[r,d]=(0,o.useState)(!1);return r?(0,u.jsx)("span",{children:i&&i()}):(0,u.jsx)("img",{alt:e,className:t,onError:()=>d(!0),onLoad:n,src:l,style:a,srcSet:s})}var f=i(425944),y=i(67347);let v=void 0!==n?n:n=i(983707),w=e=>({description:e.description,entityId:e.id,title:e.title});function j({children:e,inTransition:t}){return(0,u.jsx)(l.xu,{color:"default","data-test-id":"signup-modal-full-page",dangerouslySetInlineStyle:{__style:{transition:"all .25s cubic-bezier(0.66, 0.025, 0.33, 0.975)",textAlign:"center",boxShadow:"0 2px 10px rgba(0,0,0,0.45)",...t?{maxWidth:"50.5em",maxHeight:"700px",height:"640px",width:"50.5em"}:{maxWidth:"60.5em",maxHeight:"500px"}}},display:"inlineBlock",margin:"auto",minHeight:450,position:"relative",rounding:2,children:e})}function S({pinKey:e,sender:t,modalType:i}){var n,p;let[h,_]=(0,o.useState)(""),[g,S]=(0,o.useState)(!1),P=(0,d.ZP)(),{data:k}=(0,x.Q)(v,e,{useLegacyAdapter:w}),A=(0,f.Z)({pinKey:k,preferredSize:"orig"});if(g)return(0,u.jsx)(j,{inTransition:!0,children:(0,u.jsxs)(l.xu,{children:[(0,u.jsx)(l.xu,{width:"100%",color:"secondary",rounding:2,children:(0,u.jsx)(a.Z,{duration:6500,finalProgress:100,shape:"rounded"})}),(0,u.jsx)(m,{sender:t})]})});let C=async()=>{(0,y.nP)("web.social.unauth.response.message.notsimilar.click",{sampleRate:1}),await s.Z.create("ConversationsResource",{user_ids:[t.id],text:h,pin:k.entityId}).callCreate(),(0,y.nP)(`web.social.unauth.response.message.${i}.notsimilar.send`,{sampleRate:1}),"signup"===i?S(!0):c.ZP.handleRedirect("/notifications/?tab=inbox")},z=t.first_name,Z=h.trim().length>0;return(0,u.jsx)(j,{children:(0,u.jsxs)(l.xu,{direction:"row",alignItems:"start",justifyContent:"between",display:"flex",flex:"grow",padding:8,children:[(0,u.jsxs)(l.xu,{width:"55%",children:[(0,u.jsxs)(l.xu,{alignItems:"center",justifyContent:"between",direction:"row",display:"flex",flex:"grow",marginBottom:3,children:[(0,u.jsx)(l.xu,{marginBottom:2,children:(0,u.jsx)(l.X6,{children:P._('So, what do you think?', 'asking reciever what they think of the pin sent to them', 'asking reciever what they think of the pin sent to them')})}),(0,u.jsx)(l.xu,{children:(0,u.jsx)(r.qE,{name:z,size:"lg",src:t.image_medium_url})})]}),(0,u.jsxs)(l.xu,{marginTop:6,children:[(0,u.jsx)(l.xu,{marginBottom:6,children:(0,u.jsx)(l.Kx,{id:"unauth_response",onChange:({value:e})=>_(e),value:h,placeholder:z?(P._('Reply to {{ name }}', 'placholder text prompting users to reply back to sender(name)', 'placholder text prompting users to reply back to sender(name)')).replace("{{ name }}",z):"",rows:6})}),(0,u.jsx)(l.xu,{marginBottom:1,children:(0,u.jsx)(l.zx,{fullWidth:!0,text:P._('Send message', 'button text to send a message', 'button text to send a message'),color:Z?"red":"gray",disabled:!Z,accessibilityLabel:P._('Send message', ' accessibilty label for sending a message', ' accessibilty label for sending a message'),onClick:()=>{C()}})}),(0,u.jsx)(l.xu,{children:(0,u.jsx)(l.zx,{fullWidth:!0,text:P._('Skip for now', 'button text to continue signup flow without sending a message', 'button text to continue signup flow without sending a message'),color:"white",accessibilityLabel:P._('Skip for now', ' accessibilty label for continuing signup flow without a response message', ' accessibilty label for continuing signup flow without a response message'),onClick:()=>{(0,y.nP)(`web.social.unauth.response.${i}.notsimilar.skip`,{sampleRate:1}),"signup"===i?c.ZP.handleSignupRedirect("/",!0):c.ZP.handleRedirect("/notifications/?tab=inbox")}})})]})]}),(0,u.jsx)(l.xu,{children:(0,u.jsxs)(l.xu,{rounding:2,minWidth:262,children:[(0,u.jsx)(l.xu,{display:"inlineBlock",overflow:"hidden",position:"relative",rounding:2,children:(0,u.jsx)(l.GH,{contentAspectRatio:"number"==typeof(null==A?void 0:A.height)&&"number"==typeof A.width?A.width/A.height:1,height:362,width:262,children:(0,u.jsx)(b,{alt:null!==(n=k.description)&&void 0!==n?n:"",src:null!==(p=null==A?void 0:A.url)&&void 0!==p?p:"",style:{width:"262px",height:"362px",objectFit:"cover"}})})}),(0,u.jsx)(l.xu,{marginTop:2,children:(0,u.jsx)(l.xv,{lineClamp:1,weight:"bold",children:k.title||k.description})})]})})]})})}},789540:(e,t,i)=>{i.d(t,{Z:()=>w});var n=i(667294),o=i(616550),l=i(240684),s=i(883119),a=i(322438),r=i(89136),d=i(66211),c=i(536462),u=i(923548),p=i(391254),h=i(957161),_=i(867820),g=i(101331),m=i(38161),x=i(785893);let b=(0,l.ZP)({resolved:{},chunkName:()=>"FullPageSignup",isReady(e){let t=this.resolve(e);return!0===this.resolved[t]&&!!i.m[t]},importAsync:()=>Promise.all([i.e(97270),i.e(16458)]).then(i.bind(i,720224)),requireAsync(e){let t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then(e=>(this.resolved[t]=!0,e))},requireSync(e){let t=this.resolve(e);return i(t)},resolve:()=>720224}),f=({isPinOrBoardPage:e})=>((0,n.useEffect)(()=>{e&&(0,c.Z)()},[e]),null),y=e=>{"saveButtonExp"===e&&h.Z.getItem("unauthDesktopSavePinId")&&h.Z.removeItem("unauthDesktopSavePinId")},v=(e,t,i)=>{i.push(`${e}?${(0,m.Z)(t,"mt")}`)},w=({hideDesktopSignupModal:e,inviter:t,pageType:i,setShouldShowSignupWelcomeLoading:l,displayProps:c})=>{let[h,m]=(0,n.useState)(null),{attributionLabel:w,signupFlow:j,container:S,source:P,savePinId:k}=c,A=["pin","board"].includes(i),{pathname:C,search:z}=(0,o.useLocation)(),Z=(0,o.useHistory)(),{trackConversionUpsell:I}=(0,g.Z)();return(0,x.jsxs)(n.Fragment,{children:[(0,x.jsxs)(n.Fragment,{children:[(0,x.jsx)(p.Z,{unsafeCSS:"body { overflow: hidden !important }"}),(0,x.jsx)(s.xu,{"data-test-id":"fullPageSignupModal",children:(0,x.jsxs)(u.Z,{canClose:!0,onCloseClick:()=>{y(P),e({shouldDoSideEffects:!0}),I({element:13503,eventType:10243}),"navigation_1"===w&&v(C,z,Z)},type:"default",children:[(0,x.jsx)(a.Z,{children:i=>"business"===i.accountType?i.businessSignupForm:(0,x.jsx)(b,{fallback:(0,x.jsx)(d.Z,{}),container:null!=S?S:"",handleCloseButtonClick:()=>{I({element:75,eventType:10243}),A&&((0,_.My)("unauth.web.page_wrapper.handle_close_click"),y(P)),e({shouldDoSideEffects:!A}),"navigation_1"===w&&v(C,z,Z)},handleShowingSignupWelcomeLoading:l,inviter:t,savePinId:k,showResponseMessageModal:t=>{e({shouldDoSideEffects:!1}),m(t?"signup":"login")},signupSource:P||void 0,toggleType:"NOT_NOW_BUTTON",signupFlow:j,showCloseIcon:!0,renderBusinessCreateButton:i.renderBusinessCreateButton,attributionLabel:w})}),(0,x.jsx)(f,{isPinOrBoardPage:A})]})})]}),h&&(0,x.jsx)(s.xu,{"data-test-id":"fullPageResponseModal",children:(0,x.jsx)(u.Z,{canClose:!1,type:"default",children:!!("respondMessage"===j.type&&t)&&(0,x.jsx)(r.Z,{modalType:h,pinKey:{type:"deprecated",data:j.pin},sender:t})})})]})}},796592:(e,t,i)=>{i.d(t,{Z:()=>a});var n=i(883119),o=i(157796),l=i(898781),s=i(785893);let a=()=>{let e=(0,l.ZP)();return(0,s.jsx)(n.xu,{alignItems:"center",display:"flex",justifyContent:"center",position:"absolute",width:"100%",height:"100%",children:(0,s.jsxs)(n.xu,{color:"default",height:600,minWidth:"500px",rounding:2,width:"30%",children:[(0,s.jsxs)(n.xu,{alignItems:"center",direction:"column",display:"flex",height:"99%",justifyContent:"center",padding:12,children:[(0,s.jsx)(n.xu,{alignItems:"center",color:"primary",display:"flex",height:60,justifyContent:"center",marginBottom:4,rounding:"circle",width:60,children:(0,s.jsx)(n.JO,{accessibilityLabel:e._('Loading state for google one tap registration', ' - ', ' -- '),color:"inverse",icon:"pin",size:"28"})}),(0,s.jsx)(n.xu,{paddingY:5,dangerouslySetInlineStyle:{__style:{"text-align":"center"}},children:(0,s.jsx)(n.X6,{children:e._('Welcome to Pinterest!', 'Welcome to Pinterest!', 'Welcome to Pinterest!')})}),(0,s.jsx)(n.xv,{align:"center",overflow:"normal",children:(0,s.jsx)("span",{className:"deprecatedTextSizeXL",children:e._('Your answers to the next questions will help us find the right ideas for you', 'loading state description while waiting for google one tap registration to complete', 'loading state description while waiting for google one tap registration to complete')})})]}),(0,s.jsx)(n.xu,{width:"100%",children:(0,s.jsx)(o.Z,{duration:6e3,finalProgress:95,shape:"rounded"})})]})})}},563387:(e,t,i)=>{i.d(t,{E:()=>r,Z:()=>c});var n=i(883119),o=i(898781),l=i(349700),s=i(966113),a=i(785893);let r=`
|
15
|
+
.TermsOfService__light a {
|
16
|
+
color: rgba(255,255,255,0.9);
|
17
|
+
}
|
18
|
+
`,d={dark:{color:"#767676",width:"224px"},light:{color:"rgba(255,255,255,0.9)",lineHeight:"150%",margin:"10px auto",textShadow:"0 1px rgba(0,0,0,0.18)",width:"272px"},revampedBizSignup:{color:"#5f5f5f",fontSize:"12px",fontWeight:"400"}};function c({dark:e,container:t=""}){let i;let r=(0,o.ZP)();return i="revamped_business_login_page"===t?"revampedBizSignup":e?"dark":"light",(0,a.jsx)(n.xu,{marginTop:3,children:(0,a.jsx)("span",{"data-test-id":"terms-of-service",className:e?"":"TermsOfService__light",color:"revampedBizSignup"===i?"subtle":void 0,style:{WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",fontSize:"11px",fontWeight:"normal",textAlign:"center",WebkitTransition:"opacity .2s linear",transition:"opacity .2s linear",...d[i]},children:(0,a.jsx)("span",{children:(0,l.nk)(r._('By continuing, you agree to Pinterest\'s {{ tos }} and acknowledge you\'ve read our {{ privacyPolicy }}. {{ noticeAtCollection }}.', 'termOfService.text', 'Agreement to legal texts for new users tos:Link to Terms of service privacyPolicy:Link to the Privacy Policy noticeAtCollection:Link to the Notice at collection article'),{tos:(0,a.jsx)(n.xu,{"data-test-id":"tos",display:"inlineBlock",dangerouslySetInlineStyle:{__style:{fontWeight:"bold",..."revampedBizSignup"!==i&&{color:"#111"}}},children:(0,a.jsx)(n.rU,{display:"inlineBlock",target:"blank",href:s.U5h,underline:"hover",children:r._('Terms of Service', 'termOfService.link.tos', 'Link to TOS')},"tos")},"tos"),privacyPolicy:(0,a.jsx)(n.xu,{"data-test-id":"privacy",display:"inlineBlock",dangerouslySetInlineStyle:{__style:{fontWeight:"bold",..."revampedBizSignup"!==i&&{color:"#111"}}},children:(0,a.jsx)(n.rU,{display:"inlineBlock",target:"blank",href:"/_/_/policy/privacy-policy/",underline:"hover",children:r._('Privacy Policy', 'termOfService.link.privacyPolicy', 'Link to privacy policy')},"privacy")},"privacy"),noticeAtCollection:(0,a.jsx)(n.xu,{"data-test-id":"noticeAtCollection",display:"inlineBlock",dangerouslySetInlineStyle:{__style:{fontWeight:"bold",..."revampedBizSignup"!==i&&{color:"#111"}}},children:(0,a.jsx)(n.rU,{display:"inlineBlock",target:"blank",href:s.cvl,underline:"hover",children:r._('Notice at collection', 'termOfService.link.noticeAtCollection', 'Link to notice at collection')},"noticeAtCollection")},"noticeAtCollection")})})})})}},597922:(e,t,i)=>{i.d(t,{Z:()=>s});var n=i(667294),o=i(883119),l=i(785893);function s({accessibilityLabel:e,autoComplete:t="on",disabled:i,domainError:s,focused:a,hasError:r,helperText:d,id:c,name:u,onBlur:p,onChange:h,onFocus:_,placeholder:g,tooltip:m,type:x,useExperimentalTextfield:b,value:f}){var y;let v=(0,n.useRef)(a),w=(0,n.useRef)(null),j=(0,n.useRef)(r);return(0,n.useEffect)(()=>{if(v.current){var e;null===(e=w.current)||void 0===e||e.focus()}},[]),(0,n.useEffect)(()=>{if(!1===j.current&&r){var e;null===(e=w.current)||void 0===e||e.focus()}j.current=r},[r]),(0,l.jsxs)("fieldset",{style:{position:"relative"},children:[(0,l.jsx)(o.xu,{display:"visuallyHidden",children:(0,l.jsx)(o.__,{htmlFor:c,children:null!==(y=null!=e?e:g)&&void 0!==y?y:""})}),(0,l.jsx)(o.nv,{autoComplete:b?void 0:t,disabled:i,errorMessage:m?b&&s||m:"",helperText:b?void 0:d,id:c,name:u,onBlur:p,onChange:({event:e})=>{h(e)},onFocus:_,placeholder:g,ref:w,size:b?void 0:"lg",type:x,value:f||""})]})}},640672:(e,t,i)=>{i.d(t,{Z:()=>l,g:()=>o});var n=i(785893);let o=`
|
19
|
+
.Tooltip_message:before, .Tooltip_message:after {
|
20
|
+
border-style: solid;
|
21
|
+
content: '';
|
22
|
+
display: block;
|
23
|
+
margin-top: -8px;
|
24
|
+
position: absolute;
|
25
|
+
right: 100%;
|
26
|
+
top: 17px;
|
27
|
+
width: 0;
|
28
|
+
}
|
29
|
+
.Tooltip_message:before {
|
30
|
+
border-color: transparent rgba(0,0,0,0.48);
|
31
|
+
border-width: 8px 10px 8px 0;
|
32
|
+
}
|
33
|
+
.Tooltip_message:after {
|
34
|
+
border-color: transparent #fff;
|
35
|
+
border-width: 8px 10px 8px 0;
|
36
|
+
margin-right: -1px;
|
37
|
+
}
|
38
|
+
.Tooltip_mobileMessage:before, .Tooltip_message:after {
|
39
|
+
border-style: solid;
|
40
|
+
display: block;
|
41
|
+
margin-top: -8px;
|
42
|
+
position: absolute;
|
43
|
+
right: 100%;
|
44
|
+
top: 17px;
|
45
|
+
width: 0;
|
46
|
+
}
|
47
|
+
.Tooltip_mobileMessage:before {
|
48
|
+
border-color: transparent rgba(0,0,0,0.48);
|
49
|
+
border-width: 8px 10px 8px 0;
|
50
|
+
}
|
51
|
+
.Tooltip_mobileMessage:after {
|
52
|
+
border-color: transparent #fff;
|
53
|
+
border-width: 8px 10px 8px 0;
|
54
|
+
margin-right: -1px;
|
55
|
+
}
|
56
|
+
.Tooltip_wrapper {
|
57
|
+
position: absolute;
|
58
|
+
left: calc(100% + 12px);
|
59
|
+
z-index: 1;
|
60
|
+
}
|
61
|
+
.Tooltip_mobileWrapper {
|
62
|
+
margin-top: 7px;
|
63
|
+
z-index: 1;
|
64
|
+
}
|
65
|
+
`;function l({message:e,color:t}){return(0,n.jsx)("div",{className:"Tooltip_wrapper","data-test-id":"tooltip",style:{top:"0px",width:"215px"},children:(0,n.jsx)("div",{className:"Tooltip_message",style:{background:t||"#fff",borderRadius:"6px",WebkitBoxShadow:"0 0 2px rgba(0,0,0,0.38),0 1px 3px rgba(0,0,0,0.32)",boxShadow:"0 0 2px rgba(0,0,0,0.38),0 1px 3px rgba(0,0,0,0.32)",color:t?"#fff":"#000",fontStyle:"normal",fontWeight:"normal",fontSize:t?"14px":"",lineHeight:"150%",padding:"8px 14px",textAlign:"left",maxWidth:"215px",display:"inline-block",float:"left"},children:(0,n.jsx)("span",{dangerouslySetInnerHTML:{__html:e},style:{overflowWrap:"break-word",wordWrap:"break-word"}})})})}},917254:(e,t,i)=>{i.d(t,{Z:()=>u});var n=i(667294),o=i(883119),l=i(905171),s=i(923548),a=i(898781),r=i(780280),d=i(785893);let c=({dismiss:e,errorMessage:t})=>{let i=(0,a.ZP)(),{isRTL:n}=(0,r.B)();return(0,d.jsx)(s.Z,{canClose:!1,hidden:!1,type:"error",children:(0,d.jsxs)(o.xu,{color:"default",margin:"auto",width:380,zIndex:new o.Ry(2e3),dangerouslySetInlineStyle:{__style:{borderRadius:"6px"}},children:[(0,d.jsx)(o.xu,{dangerouslySetInlineStyle:{__style:{fontSize:"20px",fontWeight:"bold",borderBottom:"1px solid #e7e7e7"}},padding:5,children:i._('Oops!', 'unauth.error.modal', 'Header for error modal')}),(0,d.jsx)(o.xu,{dangerouslySetInlineStyle:{__style:{color:"#333",fontSize:"14px",lineHeight:"21px"}},padding:5,children:t}),(0,d.jsx)(o.xu,{dangerouslySetInlineStyle:{__style:{background:"#f0f0f0",borderBottom:"1px solid #dadada",borderRadius:"0 0 6px 6px",padding:"10px 20px"}},height:30,children:(0,d.jsx)(o.xu,{dangerouslySetInlineStyle:{__style:{float:n?"left":"right"}},children:(0,d.jsx)("button",{className:"UnauthBanner__continueButton",onClick:()=>e(),style:{backgroundColor:"#ab171e",border:"1px solid #820a0f",borderRadius:"3px",color:"#fff",cursor:"pointer",fontSize:"14px",fontWeight:"bold",padding:"6px 12px",marginTop:"-10px"},children:i._('Okay', 'unauth.error.modal.okay', 'Button text for accepting that there was an error')})})})]})})},u=({children:e})=>{let[t,i]=(0,n.useState)(null),o=(0,n.useRef)(null);return(0,l.o)(e=>{i(e),clearTimeout(o.current),o.current=setTimeout(()=>{i(null)},3e3)}),(0,n.useEffect)(()=>()=>{clearTimeout(o.current)},[]),(0,d.jsxs)(n.Fragment,{children:[e,!!t&&(0,d.jsx)(c,{dismiss:()=>i(null),errorMessage:t})]})}},923548:(e,t,i)=>{i.d(t,{Z:()=>d});var n=i(667294),o=i(883119),l=i(662730),s=i(867820),a=i(785893);function r(e,t,i){var n;return(t="symbol"==typeof(n=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"))?n:String(n))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}class d extends n.Component{constructor(...e){super(...e),r(this,"state",{hidden:this.props.hidden||!1}),r(this,"handleKeyDown",e=>{let{canClose:t,type:i}=this.props;"Escape"===e.key&&((0,s.My)(`unauth.authentication_modal.esc_key_click.NOT_NOW_BUTTON.${i}.${t?"can":"cant"}_close`),t&&((0,s.My)(`unauth.authentication_modal.esc_key_click.DISMISSED.${i}`),this.close())),e.stopPropagation()}),r(this,"close",()=>{let{onCloseClick:e,onHide:t}=this.props;e?e():(this.setState({hidden:!0}),t&&t())})}componentDidMount(){window.addEventListener("keydown",this.handleKeyDown)}componentWillUnmount(){window.removeEventListener("keydown",this.handleKeyDown)}render(){let{hidden:e}=this.state,{canClose:t,children:i,type:n}=this.props;return e?null:(0,a.jsx)(o.xu,{bottom:!0,left:!0,opacity:1,position:"fixed",right:!0,top:!0,zIndex:l.P,dangerouslySetInlineStyle:{__style:{backgroundColor:"closeup"===n?"rgba(239, 239, 239, 0.96)":"rgba(0, 0, 0, 0.6)",cursor:"closeup"===n?"zoom-out":void 0}},children:(0,a.jsx)("div",{onClick:()=>{(0,s.My)(`unauth.full_page_modal.${n}.empty_space_click`),t&&this.close()},"aria-label":"modal",role:"dialog",style:{WebkitOverflowScrolling:"touch",overflowY:"scroll",bottom:0,left:0,right:0,top:0,position:"fixed",display:"flex"},children:(0,a.jsx)("div",{onClick:e=>{e.stopPropagation()},onKeyDown:e=>{t&&"Escape"===e.key&&e.stopPropagation()},"aria-label":"modal",role:"dialog",style:{height:"100%",display:"flex",minHeight:"0px",position:"relative",opacity:1,borderRadius:"6px",margin:"0 auto"},children:i})})})}}},700842:(e,t,i)=>{i.d(t,{Z:()=>x});var n=i(667294),o=i(240684),l=i(883119),s=i(366284),a=i(407043),r=i(366394),d=i(780280),c=i(622096),u=i(700380),p=i(101331),h=i(785893);function _(e,t,i){var n;return(t="symbol"==typeof(n=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"))?n:String(n))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}let g=(0,o.ZP)({resolved:{},chunkName:()=>"UnauthHybridBannerSignupModal",isReady(e){let t=this.resolve(e);return!0===this.resolved[t]&&!!i.m[t]},importAsync:()=>i.e(33099).then(i.bind(i,841957)),requireAsync(e){let t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then(e=>(this.resolved[t]=!0,e))},requireSync(e){let t=this.resolve(e);return i(t)},resolve:()=>841957});class m extends n.Component{constructor(...e){super(...e),_(this,"state",{scrollSessionCount:0,shouldShowBanner:!1,bannerViewed:!1,bannerDismissed:!1}),_(this,"setShouldShowBanner",e=>this.setState({shouldShowBanner:e})),_(this,"onScrollHybridBanner",e=>{let{isSafari:t,trackConversionUpsell:i}=this.props,n=0,o=e&&e.target instanceof Document?e.target:null;if(o&&o.documentElement&&o.documentElement.scrollTop>0?n=o.documentElement.scrollTop:o&&o.body&&o.body.scrollTop>0&&(n=o.body.scrollTop),n<64)this.state.shouldShowBanner&&!this.state.bannerDismissed&&(i({element:13893,eventType:10243}),this.state.bannerDismissed=!0),this.setShouldShowBanner(!1);else if(n<4e3){let e=this.state.shouldShowBanner;this.setState(e=>({shouldShowBanner:(0,r.o)()||t||3!==e.scrollSessionCount,scrollSessionCount:Math.ceil(n/800)}),()=>{e||!this.state.shouldShowBanner||this.state.bannerViewed||(i({eventType:14688,element:13319,component:14479,upsellReason:"scroll_down"}),this.state.bannerViewed=!0)})}else!c.Z.getItem("HAS_SEEN_LOGIN_MODAL")&&!(0,r.o)()&&t&&e&&e.preventDefault()}),_(this,"onScrollHybridBannerThrottled",(0,u.Z)(this.onScrollHybridBanner,10))}componentDidMount(){window.addEventListener("scroll",this.onScrollHybridBannerThrottled)}componentWillUnmount(){window.removeEventListener("scroll",this.onScrollHybridBannerThrottled)}render(){let{inviter:e,setHasDismissedBottomRightUpsell:t}=this.props,{shouldShowBanner:i}=this.state;return(0,h.jsx)(l.xu,{children:(0,h.jsx)(g,{fallback:(0,h.jsx)(l.xu,{}),inviter:e,setHasDismissedBottomRightUpsell:t,shouldShowBanner:i})})}}let x=e=>{let{isBot:t}=(0,d.B)(),{logContextEvent:i}=(0,a.v)(),{userAgent:{browserName:n}}=(0,d.B)(),{trackConversionUpsell:o}=(0,p.Z)();return t?null:(0,h.jsx)(m,{...e,isSafari:(0,s.G6)(n),logContextEvent:i,trackConversionUpsell:o})}},754124:(e,t,i)=>{i.d(t,{Z:()=>g});var n=i(667294),o=i(31397),l=i(883119),s=i(469134),a=i(231486),r=i(226198),d=i(856241),c=i(499128),u=i(898781),p=i(290148),h=i(867820),_=i(785893);let g=({birthday:e,onEditBirthday:t,onConfirmBirthday:i=()=>{}})=>{let g=(0,u.ZP)(),[m,x]=(0,n.useState)(!1),b=e?(0,o.Z)(new Date,(0,d.Z)(e)):0;return(0,_.jsxs)(n.Fragment,{children:[(0,_.jsx)(l.xu,{padding:8,"data-test-id":"underageconfirmation-modal",children:(0,_.jsxs)(l.kC,{direction:"column",justifyContent:"center",alignItems:"center",children:[(0,_.jsx)(l.xu,{width:420,marginBottom:5,"data-test-id":"underageconfirmation-title",children:(0,_.jsx)(l.X6,{align:"center",size:"600",children:(0,s.ew)(b,g)})}),(0,_.jsx)(l.xu,{marginBottom:10,maxWidth:540,children:(0,_.jsx)(l.xv,{align:"center",children:(0,s.Pe)(g)})}),(0,_.jsx)(l.xu,{children:(0,_.jsxs)(l.kC,{children:[(0,_.jsx)(l.xu,{marginEnd:2,children:(0,_.jsx)(l.zx,{text:g._('Edit', 'signup.underageconfirmation.edit', 'Text on the edit button for birthday collection underage screen'),onClick:()=>{(0,h.My)("dweb.underageconfirmation.edit"),a.t8(r.It,"0",(0,a.kZ)(r.It)),t()}})}),(0,_.jsx)(l.zx,{text:g._('Confirm', 'signup.underageconfirmation.confirm', 'Text on the confirm button for birthday collection underage screen'),type:"submit",color:"red",onClick:()=>{x(!0),(0,h.My)("dweb.underageconfirmation.confirm"),i(),setTimeout(()=>{p.ZP.handleRedirect("/")},4e3)}})]})})]})}),m&&(0,_.jsx)(l.xu,{fit:!0,dangerouslySetInlineStyle:{__style:{bottom:"50%",left:"50%",transform:"translateX(-50%)"}},paddingX:1,position:"fixed",children:(0,_.jsx)(c.ZP,{onHide:()=>x(!m),text:g._('Sorry, you\u2019re not eligible to sign up for Pinterest right now.', 'signup.underageconfirmation.error', 'Error message shown when underage user tries to register'),duration:3500})})]})}},322438:(e,t,i)=>{i.d(t,{Z:()=>y});var n=i(667294),o=i(702664),l=i(883119),s=i(56641),a=i(489582),r=i(407043),d=i(898781),c=i(583375),u=i(773285),p=i(867820),h=i(52022),_=i(101331),g=i(123906),m=i(785893);function x({isBusinessAccountType:e,toggle:t}){let i=(0,d.ZP)(),{logContextEvent:n}=(0,r.v)(),o=(0,h.Z)(),{trackConversionUpsell:s}=(0,_.Z)();return(0,m.jsx)(l.xu,{height:62,color:"secondary",bottom:!0,left:!0,width:"100%",dangerouslySetInlineStyle:{__style:{borderRadius:"0 0 32px 32px"}},"data-test-id":"create-business-account-button",children:(0,m.jsx)(l.iP,{fullHeight:!0,onTap:({event:i})=>{t(),(0,p.My)(e?"unauth.home.pinner_business_toggle.business.click":"unauth.home.pinner_business_toggle.pinner.click"),n({event_type:101,component:13096,element:10773,aux_data:{is_business_signup:e}}),s({element:10773,eventType:14689}),(0,p.NC)("press_business_signup"),o({action:"click",item:"create-business-account-button"})},children:(0,m.jsx)(l.kC,{alignItems:"center",height:"100%",justifyContent:"center",children:(0,m.jsx)(l.xv,{weight:"bold",children:e?i._('Create a personal account', 'signupModal.switchToPersonalAccountSignup', 'Button on signup modal to switch from business to personal signup.'):i._('Create a free business account', 'signupModal.switchToBusinessAccountSignup.free', 'Button on signup modal to switch from personal to business signup.')})})})})}function b(){let e=(0,d.ZP)(),{logContextEvent:t}=(0,r.v)(),i=(0,h.Z)(),{trackConversionUpsell:n}=(0,_.Z)();return(0,m.jsx)(l.xu,{height:62,color:"secondary",bottom:!0,left:!0,width:"100%",dangerouslySetInlineStyle:{__style:{borderRadius:"0 0 32px 32px"}},"data-test-id":"create-business-account-button",children:(0,m.jsx)(l.iP,{fullHeight:!0,onTap:()=>{(0,s.Z)((0,g.Z)("/business/create/"),!0),(0,p.My)("unauth.home.pinner_business_toggle.business.click"),t({event_type:101,component:13096,element:10773,aux_data:{is_business_signup:!1}}),n({element:10773,eventType:14689}),(0,p.NC)("press_business_signup"),i({action:"click",item:"create-business-account-button"})},children:(0,m.jsx)(l.kC,{alignItems:"center",height:"100%",justifyContent:"center",children:(0,m.jsx)(l.xv,{weight:"bold",children:e._('Create a free business account', 'signupModal.switchToBusinessAccountSignup.free', 'Button on signup modal to switch from personal to business signup.')})})})})}function f({toggleAccountType:e}){let t=(0,d.ZP)(),i=(0,o.useSelector)(({underageConfirmation:e})=>e.isUnderageConfirmationModalVisible);return(0,m.jsx)(l.xu,{color:"default",display:i?"none":"block","data-test-id":"signup-modal-business-signup-form",minHeight:533,rounding:8,dangerouslySetInlineStyle:{__style:{paddingTop:"10px",boxShadow:"0 2px 10px rgba(0, 0, 0, 0.45)",margin:"auto 0px"}},width:484,children:(0,m.jsx)(l.kC,{alignItems:"center",direction:"row",justifyContent:"between",children:(0,m.jsx)(l.xu,{width:484,children:(0,m.jsxs)(l.xu,{width:"100%",height:"100%",position:"relative",children:[(0,m.jsx)(l.xu,{display:"block",height:45,width:45,dangerouslySetInlineStyle:{__style:{margin:"15px auto 8px"}},children:(0,m.jsx)(c.Z,{size:40})}),(0,m.jsxs)(l.xu,{children:[(0,m.jsx)(l.xu,{dangerouslySetInlineStyle:{__style:{color:"#333",fontSize:"36px",fontWeight:"600",WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",letterSpacing:"-1.2px",margin:"4px 26px 26px",textAlign:"center"}},children:t._('Welcome to Pinterest', 'businessSignupModal.title', 'Title on business signup modal.')}),(0,m.jsx)(l.xu,{dangerouslySetInlineStyle:{__style:{textAlign:"center",color:"#333",fontSize:"16px",fontWeight:"normal",margin:"-23px 26px 18px"}},children:t._('Grow your business', 'businessSignupModal.subtitle', 'Subtitle on business signup modal.')})]}),(0,m.jsx)(l.xu,{alignItems:"center",display:"flex",justifyContent:"center",minHeight:400,dangerouslySetInlineStyle:{__style:{padding:"21px 10px 24px",flexDirection:"column"}},children:(0,m.jsx)(a.Z,{})}),(0,m.jsx)(l.xu,{height:62,marginTop:3,dangerouslySetInlineStyle:{__style:{borderRadius:"0 0 8px 8px"}}}),(0,m.jsx)(x,{isBusinessAccountType:!0,toggle:e})]})})})})}function y({children:e}){let[t,i]=(0,n.useState)(!1),{checkExperiment:o}=(0,u.F)(),l=o("adv_growth_biz_signup_revamp").anyEnabled;return e(t?{accountType:"business",businessSignupForm:(0,m.jsx)(f,{toggleAccountType:()=>i(!1)})}:{accountType:"personal",renderBusinessCreateButton:l?()=>(0,m.jsx)(b,{}):()=>(0,m.jsx)(x,{isBusinessAccountType:!1,toggle:()=>i(!0)})})}},905171:(e,t,i)=>{i.d(t,{o:()=>a,x:()=>s});var n=i(667294),o=i(898781);let l=new Set,s=e=>{l.forEach(t=>t(e))},a=e=>{let t=(0,o.ZP)();(0,n.useEffect)(()=>{let i=i=>{e(i||t._('Unknown Error', 'unauth.error.modal.unknown', 'Text saying an unknown error occurredr'))};return l.add(i),()=>{l.delete(i)}},[])}},950209:(e,t,i)=>{i.d(t,{Z:()=>s});var n=i(803491),o=i(563387),l=i(640672);let s=[n.m,l.g,o.E].join("")},536462:(e,t,i)=>{i.d(t,{Z:()=>l});var n=i(957161),o=i(709113);let l=()=>{try{n.Z.setItem(o.bY,Date.now())}catch(e){console.error(e)}}},780679:(e,t,i)=>{i.d(t,{g:()=>s,t:()=>l});var n=i(667294);let o=(0,n.createContext)(null),l=o.Provider,s=()=>(0,n.useContext)(o)},662730:(e,t,i)=>{i.d(t,{C:()=>l,P:()=>o});var n=i(883119);let o=new n.Ry(1e4),l=new n.H3([o])},612470:(e,t,i)=>{i.d(t,{Z:()=>s});var n=i(199324);let o=`
|
66
|
+
article,
|
67
|
+
aside,
|
68
|
+
details,
|
69
|
+
figcaption,
|
70
|
+
figure,
|
71
|
+
footer,
|
72
|
+
header,
|
73
|
+
hgroup,
|
74
|
+
nav,
|
75
|
+
section,
|
76
|
+
ul {
|
77
|
+
display: block;
|
78
|
+
}
|
79
|
+
|
80
|
+
audio,
|
81
|
+
canvas,
|
82
|
+
video {
|
83
|
+
display: inline-block;
|
84
|
+
}
|
85
|
+
|
86
|
+
audio:not([controls]) {
|
87
|
+
display: none;
|
88
|
+
}
|
89
|
+
|
90
|
+
html {
|
91
|
+
font-size: 100%;
|
92
|
+
text-size-adjust: none;
|
93
|
+
}
|
94
|
+
|
95
|
+
a:hover,
|
96
|
+
a:active {
|
97
|
+
outline: 0;
|
98
|
+
}
|
99
|
+
|
100
|
+
sub,
|
101
|
+
sup {
|
102
|
+
position: relative;
|
103
|
+
font-size: 75%;
|
104
|
+
line-height: 0;
|
105
|
+
vertical-align: baseline;
|
106
|
+
}
|
107
|
+
sup {
|
108
|
+
top: -0.5em;
|
109
|
+
}
|
110
|
+
sub {
|
111
|
+
bottom: -0.25em;
|
112
|
+
}
|
113
|
+
|
114
|
+
img {
|
115
|
+
max-width: 100%;
|
116
|
+
width: auto;
|
117
|
+
height: auto;
|
118
|
+
|
119
|
+
vertical-align: middle;
|
120
|
+
border: 0;
|
121
|
+
-ms-interpolation-mode: bicubic;
|
122
|
+
}
|
123
|
+
|
124
|
+
#map_canvas img {
|
125
|
+
max-width: none;
|
126
|
+
}
|
127
|
+
|
128
|
+
fieldset {
|
129
|
+
border: 0;
|
130
|
+
margin: 0;
|
131
|
+
padding: 0;
|
132
|
+
}
|
133
|
+
|
134
|
+
button,
|
135
|
+
input,
|
136
|
+
select,
|
137
|
+
textarea {
|
138
|
+
font-size: 100%;
|
139
|
+
margin: 0;
|
140
|
+
vertical-align: middle;
|
141
|
+
}
|
142
|
+
button,
|
143
|
+
input {
|
144
|
+
overflow: visible;
|
145
|
+
line-height: normal;
|
146
|
+
}
|
147
|
+
button::-moz-focus-inner,
|
148
|
+
input::-moz-focus-inner {
|
149
|
+
padding: 0;
|
150
|
+
border: 0;
|
151
|
+
}
|
152
|
+
button,
|
153
|
+
input[type='button'],
|
154
|
+
input[type='reset'],
|
155
|
+
input[type='submit'] {
|
156
|
+
cursor: pointer;
|
157
|
+
-webkit-appearance: button;
|
158
|
+
}
|
159
|
+
textarea {
|
160
|
+
overflow: auto;
|
161
|
+
vertical-align: top;
|
162
|
+
}
|
163
|
+
body {
|
164
|
+
margin: 0;
|
165
|
+
}
|
166
|
+
h1, h2, h3, h4, h5, h6 {
|
167
|
+
margin: 0;
|
168
|
+
}
|
169
|
+
figure {
|
170
|
+
margin: 0;
|
171
|
+
}`,l=`
|
172
|
+
html {
|
173
|
+
background-color: #fff;
|
174
|
+
}
|
175
|
+
|
176
|
+
html, body {
|
177
|
+
font-family: ${n.Z};
|
178
|
+
color: rgb(33, 25, 34);
|
179
|
+
font-size: 12px;
|
180
|
+
height: 100%;
|
181
|
+
}
|
182
|
+
|
183
|
+
body {
|
184
|
+
position: relative;
|
185
|
+
overflow-y: overlay;
|
186
|
+
overflow-x: hidden;
|
187
|
+
}
|
188
|
+
|
189
|
+
input::-ms-clear {
|
190
|
+
display: none;
|
191
|
+
}
|
192
|
+
|
193
|
+
ul {
|
194
|
+
margin: 0;
|
195
|
+
padding: 0;
|
196
|
+
}
|
197
|
+
|
198
|
+
ul li {
|
199
|
+
list-style: none;
|
200
|
+
padding: 0;
|
201
|
+
}
|
202
|
+
|
203
|
+
:focus {
|
204
|
+
outline: #d1d1d1 auto 1px
|
205
|
+
}
|
206
|
+
|
207
|
+
button, input, select, textarea {
|
208
|
+
font-family: ${n.Z};
|
209
|
+
font-size: 100%;
|
210
|
+
vertical-align: middle;
|
211
|
+
margin: 0px;
|
212
|
+
}
|
213
|
+
|
214
|
+
.SkipToContent {
|
215
|
+
display: none;
|
216
|
+
}
|
217
|
+
`,s=o+l},366394:(e,t,i)=>{i.d(t,{$:()=>s,o:()=>a});var n=i(532975),o=i(622096);let l="openUnauthType",s=()=>{o.Z.setItem(l,"OPEN_UNAUTH")},a=()=>(0,n.a)()||"OPEN_UNAUTH"===o.Z.getItem(l)},413764:(e,t,i)=>{i.d(t,{Z:()=>o});var n=i(785893);let o=({size:e})=>(0,n.jsxs)("svg",{height:e,style:{display:"block"},viewBox:"-3 -3 82 82",width:e,children:[(0,n.jsx)("circle",{cx:"38",cy:"38",fill:"white",r:"40"}),(0,n.jsx)("path",{d:"M27.5 71c3.3 1 6.7 1.6 10.3 1.6C57 72.6 72.6 57 72.6 37.8 72.6 18.6 57 3 37.8 3 18.6 3 3 18.6 3 37.8c0 14.8 9.3 27.5 22.4 32.5-.3-2.7-.6-7.2 0-10.3l4-17.2s-1-2-1-5.2c0-4.8 3-8.4 6.4-8.4 3 0 4.4 2.2 4.4 5 0 3-2 7.3-3 11.4C35.6 49 38 52 41.5 52c6.2 0 11-6.6 11-16 0-8.3-6-14-14.6-14-9.8 0-15.6 7.3-15.6 15 0 3 1 6 2.6 8 .3.2.3.5.2 1l-1 3.8c0 .6-.4.8-1 .4-4.4-2-7-8.3-7-13.4 0-11 7.8-21 22.8-21 12 0 21.3 8.6 21.3 20 0 12-7.4 21.6-18 21.6-3.4 0-6.7-1.8-7.8-4L32 61.7c-.8 3-3 7-4.5 9.4z",fill:"#fb7072",fillRule:"evenodd"})]})},400964:(e,t,i)=>{i.d(t,{Z:()=>l});var n=i(785893);let o=(0,n.jsx)("svg",{width:"40px",height:"40px",viewBox:"0 0 40 40",version:"1.1",xmlns:"http://www.w3.org/2000/svg",children:(0,n.jsx)("g",{stroke:"none",strokeWidth:"1",fill:"none",fillRule:"evenodd",children:(0,n.jsx)("path",{d:"M28.2226562,20.3846154 C29.0546875,20.3846154 30.0976562,19.8048315 30.71875,19.0317864 C31.28125,18.3312142 31.6914062,17.352829 31.6914062,16.3744437 C31.6914062,16.2415766 31.6796875,16.1087095 31.65625,16 C30.7304687,16.0362365 29.6171875,16.640178 28.9492187,17.4494596 C28.421875,18.06548 27.9414062,19.0317864 27.9414062,20.0222505 C27.9414062,20.1671964 27.9648438,20.3121424 27.9765625,20.3604577 C28.0351562,20.3725366 28.1289062,20.3846154 28.2226562,20.3846154 Z M25.2929688,35 C26.4296875,35 26.9335938,34.214876 28.3515625,34.214876 C29.7929688,34.214876 30.109375,34.9758423 31.375,34.9758423 C32.6171875,34.9758423 33.4492188,33.792117 34.234375,32.6325493 C35.1132812,31.3038779 35.4765625,29.9993643 35.5,29.9389701 C35.4179688,29.9148125 33.0390625,28.9122695 33.0390625,26.0979021 C33.0390625,23.6579784 34.9140625,22.5588048 35.0195312,22.474253 C33.7773438,20.6382708 31.890625,20.5899555 31.375,20.5899555 C29.9804688,20.5899555 28.84375,21.4596313 28.1289062,21.4596313 C27.3554688,21.4596313 26.3359375,20.6382708 25.1289062,20.6382708 C22.8320312,20.6382708 20.5,22.5950413 20.5,26.2911634 C20.5,28.5861411 21.3671875,31.013986 22.4335938,32.5842339 C23.3476562,33.9129053 24.1445312,35 25.2929688,35 Z",id:"",fill:"#FFFFFF",fillRule:"nonzero"})})}),l=o},994999:(e,t,i)=>{i.d(t,{Z:()=>s});var n=i(858472),o=i(785893);let l=(0,o.jsxs)("svg",{width:"40",height:"40",viewBox:"0 0 40 40",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,o.jsx)("rect",{width:"40",height:"40",rx:"6",fill:"#EFEFEF"}),(0,o.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M6 20C6 25.9768 9.74617 31.0798 15.0183 33.0877C14.89 31.9945 14.7535 30.192 15.0475 28.9273C15.3007 27.84 16.682 21.9997 16.682 21.9997C16.682 21.9997 16.2655 21.1655 16.2655 19.93C16.2655 17.9933 17.3878 16.5467 18.7867 16.5467C19.9767 16.5467 20.5507 17.4392 20.5507 18.509C20.5507 19.7048 19.7888 21.4922 19.3957 23.15C19.0678 24.5372 20.0922 25.6688 21.4595 25.6688C23.9363 25.6688 25.8415 23.0567 25.8415 19.286C25.8415 15.9482 23.4428 13.616 20.0187 13.616C16.0543 13.616 13.7268 16.5898 13.7268 19.664C13.7268 20.8622 14.1877 22.1455 14.764 22.8443C14.8772 22.9832 14.8947 23.1033 14.8608 23.2445C14.7547 23.6855 14.519 24.6317 14.4735 24.8253C14.4117 25.0797 14.2717 25.1345 14.0068 25.0108C12.2662 24.2012 11.1788 21.6567 11.1788 19.6127C11.1788 15.2155 14.372 11.1788 20.3862 11.1788C25.2208 11.1788 28.9787 14.624 28.9787 19.2277C28.9787 24.0308 25.9512 27.8972 21.7465 27.8972C20.3337 27.8972 19.0072 27.1622 18.5522 26.2953C18.5522 26.2953 17.8533 28.9577 17.6842 29.6087C17.3552 30.8733 16.4428 32.474 15.877 33.3828C17.1813 33.7842 18.565 34 20 34C27.7315 34 34 27.7315 34 20C34 12.2685 27.7315 6 20 6C12.2685 6 6 12.2685 6 20Z",fill:n.x7})]}),s=l},579014:(e,t,i)=>{i.d(t,{B1:()=>o,Md:()=>c,iX:()=>d,lI:()=>l,op:()=>r,uZ:()=>s,wN:()=>n,z_:()=>a});let n="var(--color-background-default)",o="var(--color-background-inverse-base)",l="var(--color-background-secondary-base)",s="var(--color-background-error-base)",a="var(--color-background-info-weak)",r="var(--color-border-error)",d="var(--color-border-container)",c="var(--color-text-subtle)"},430322:(e,t,i)=>{i.r(t),i.d(t,{default:()=>x});var n=i(667294),o=i(883119),l=i(283698),s=i(968121),a=i(898781),r=i(124580),d=i(780280),c=i(223815),u=i(867820),p=i(50286),h=i(965900),_=i(785893);let g=()=>{if(document.body){let{body:{style:e}}=document;e.overflow="hidden",e.touchAction="none"}},m=()=>{if(document.body){let{body:{style:e}}=document;e.overflow="visible",e.touchAction="auto"}};function x({accessibilityModalLabel:e,align:t="center",allowClickAndDrag:i,allowScroll:x=!1,children:b,closeOnOutsideClick:f=!0,footer:y,heading:v,isOpen:w,mobileAccessibilityCloseIconLabel:j,mobileHideCloseIcon:S,mobileIsFooter:P,mobileIsFullscreen:k,mobileIsSlideUp:A,onDismiss:C,subHeading:z,type:Z,zIndex:I}){let T=(0,a.ZP)(),{isRTL:E}=(0,d.B)(),L=(0,n.useRef)(!1),[B,M]=(0,n.useState)(!1),{setAppFocusState:O}=(0,h.I)(),R=(0,p.ZP)();return((0,n.useEffect)(()=>{(0,u.My)(`mweb_unauth.mobile_modal.${Z||"unknown_type"}.did_mount.is_open.${String(!!w)}`)},[w,Z]),(0,n.useEffect)(()=>(L.current=(0,l.Z)(()=>{L.current&&M(!0)}),()=>{"undefined"!=typeof window&&Object.prototype.hasOwnProperty.call(window,"cancelAnimationFrame")&&L.current&&(window.cancelAnimationFrame(L.current),L.current=null)}),[]),(0,n.useEffect)(()=>(w?(r.Z.pause(),O(!1)):(r.Z.resume(),O(!0)),()=>{w&&(r.Z.resume(),O(!0))}),[O,w]),(0,n.useEffect)(()=>{let e=w&&!x;return e&&g(),()=>{e&&m()}},[w,x]),w)?(0,_.jsx)(c.Z,{allowClickAndDrag:i,children:(0,_.jsx)(o.mh,{children:(0,_.jsxs)(o.xu,{"aria-label":e,display:"inlineBlock",zIndex:I||s.ZM,position:"relative",role:"dialog",children:[(0,_.jsx)(o.iP,{accessibilityLabel:T._('Mobile Signup Modal Mask', 'mweb.signup_modal.mask', 'The accessibility label for the mask of mobile signup modal'),onTap:({event:e})=>{e.clientX&&e.clientY&&(0,u.tj)(`mweb_unauth.mobile_modal.wash_tap.${Z||"unknown_type"}.with_dismissal`,{x:e.clientX,y:e.clientY}),f&&C()},tapStyle:"none",children:(0,_.jsx)(o.xu,{height:"100%",left:!0,position:"fixed",top:!0,width:"100%",zIndex:new o.Ry(1),dangerouslySetInlineStyle:{__style:{backgroundColor:"rgba(0, 0, 0, .5)",touchAction:"none",transitionProperty:"opacity",transitionTimingFunction:"ease-out"}}})}),(0,_.jsxs)(o.xu,{position:"fixed",color:"default","data-test-id":"mobile-signup-mask",dangerouslySetInlineStyle:A?(0,s.Vf)({isFullscreen:k,isTablet:"tablet"===R,isShowing:B,isRelatedInterestsModal:"related_interests_modal"===Z}):(0,s.JN)({variant:k?"fullscreen":"tablet"===R?"tablet":P?"footer":"signup"===Z?"signup":void 0}),children:[(0,_.jsxs)(o.kC,{alignItems:"center",justifyContent:"start",width:"100%",gap:{row:2,column:0},children:[j&&!S?(0,_.jsx)(o.xu,{padding:2,"data-test-id":"mobile-modal-cancel-button",children:(0,_.jsx)(o.hU,{accessibilityLabel:j,iconColor:"darkGray",icon:"cancel",onClick:C,padding:4,size:"sm"})}):null,v?(0,_.jsx)(o.kC.Item,{flex:"grow",children:(0,_.jsx)(o.kC,{direction:"column",alignItems:"center",justifyContent:"center",children:(0,_.jsxs)(o.xu,{"data-test-id":"mobile-modal-heading",dangerouslySetInlineStyle:{__style:j&&!S?{marginRight:E?-10:50,marginLeft:E?50:-10}:{}},children:[k?v:(0,_.jsx)(o.xv,{align:t,weight:"bold",size:"400",children:v}),z?(0,_.jsx)(o.xv,{align:t,children:z}):null]})})}):null]}),(0,_.jsxs)(o.xu,{overflow:"auto",children:[b,y]})]})]})})}):null}},176326:(e,t,i)=>{i.d(t,{Mt:()=>c});var n=i(667294),o=i(835074);let l={"af-ZA":()=>i.e(4701).then(i.bind(i,4701)),"ar-SA":()=>i.e(69884).then(i.bind(i,869884)),"bg-BG":()=>i.e(50349).then(i.bind(i,350349)),"bn-IN":()=>i.e(97094).then(i.bind(i,497094)),"cs-CZ":()=>i.e(17586).then(i.bind(i,717586)),"da-DK":()=>i.e(24221).then(i.bind(i,824221)),de:()=>i.e(70879).then(i.bind(i,870879)),"el-GR":()=>i.e(84912).then(i.bind(i,184912)),"en-AU":()=>i.e(89345).then(i.bind(i,389345)),"en-GB":()=>i.e(89345).then(i.bind(i,389345)),"en-IN":()=>i.e(89345).then(i.bind(i,389345)),"en-US":()=>i.e(16117).then(i.bind(i,983975)),"es-419":()=>i.e(63345).then(i.bind(i,663345)),"es-AR":()=>i.e(63345).then(i.bind(i,663345)),"es-ES":()=>i.e(63345).then(i.bind(i,663345)),"es-MX":()=>i.e(63345).then(i.bind(i,663345)),"fi-FI":()=>i.e(40302).then(i.bind(i,140302)),fr:()=>i.e(38587).then(i.bind(i,438587)),"he-IL":()=>i.e(94433).then(i.bind(i,494433)),"hi-IN":()=>i.e(69927).then(i.bind(i,269927)),"hr-HR":()=>i.e(40499).then(i.bind(i,240499)),"hu-HU":()=>i.e(94393).then(i.bind(i,994393)),"id-ID":()=>i.e(72728).then(i.bind(i,472728)),it:()=>i.e(64962).then(i.bind(i,264962)),ja:()=>i.e(40944).then(i.bind(i,340944)),"ko-KR":()=>i.e(3006).then(i.bind(i,803006)),"ms-MY":()=>i.e(59265).then(i.bind(i,259265)),"nb-NO":()=>i.e(3304).then(i.bind(i,103304)),nl:()=>i.e(94638).then(i.bind(i,594638)),"pl-PL":()=>i.e(73020).then(i.bind(i,973020)),"pt-BR":()=>i.e(94952).then(i.bind(i,494952)),"pt-PT":()=>i.e(94952).then(i.bind(i,494952)),"ro-RO":()=>i.e(88397).then(i.bind(i,188397)),"ru-RU":()=>i.e(68554).then(i.bind(i,368554)),"sk-SK":()=>i.e(51418).then(i.bind(i,151418)),"sv-SE":()=>i.e(15155).then(i.bind(i,215155)),"te-IN":()=>i.e(43553).then(i.bind(i,943553)),"th-TH":()=>i.e(22095).then(i.bind(i,322095)),tr:()=>i.e(12329).then(i.bind(i,812329)),"uk-UA":()=>i.e(16969).then(i.bind(i,116969)),"vi-VN":()=>i.e(34215).then(i.bind(i,934215)),"zh-CN":()=>i.e(90632).then(i.bind(i,990632)),"zh-TW":()=>i.e(85673).then(i.bind(i,485673))};async function s(e){if(window&&window.__localeData__&&e in window.__localeData__)return Promise.resolve(window.__localeData__[e]);if(e in l&&!(window.__localeData__&&e in window.__localeData__)){let t=await l[e]();return t.default}return Promise.resolve(null)}var a=i(780280),r=i(785893);let d=(0,n.forwardRef)(({disabled:e,errorMessage:t,excludeDates:i,helperText:l,id:d,idealDirection:c,includeDates:u,label:p,maxDate:h,minDate:_,nextRef:g,onChange:m,placeholder:x,rangeEndDate:b,rangeSelector:f,rangeStartDate:y,selectLists:v,value:w},j)=>{let{locale:S}=(0,a.B)(),[P,k]=(0,n.useState)(void 0);return(0,n.useEffect)(()=>{let e=async()=>{let e=await s(S);k(e)};e()},[S,k]),(0,r.jsx)(o.Mt,{id:d,onChange:m,disabled:e,errorMessage:t,excludeDates:i,helperText:l,idealDirection:c,includeDates:u,label:p,localeData:P,maxDate:h,minDate:_,nextRef:g,placeholder:x,rangeEndDate:b,rangeSelector:f,rangeStartDate:y,ref:j,selectLists:v,value:w})});d.displayName="DatePicker";let c=d},313047:(e,t,i)=>{i.r(t),i.d(t,{DEFAULT_HEIGHT:()=>p,DEFAULT_PADDING_Y:()=>h,FixedFooter:()=>m,FixedHeader:()=>g});var n=i(667294),o=i(883119),l=i(643010),s=i(579014),a=i(858472),r=i(124580),d=i(834256),c=i(773285),u=i(785893);let p=64,h=3;function _({children:e,footerConfig:t,headerConfig:i,height:d,hideOnScroll:_,hideOnScrollState:{isHidden:g,updateHiddenState:m},noPadding:x,paddingY:b=h,type:f,zIndex:y}){let v,w;let{headerLimitedOverflow:j,ignoreObstructions:S,zIndexForGestaltBug:P}=i||{},{appUpsellFooterConfig:k,footerInLego:A,navFooterConfig:C}=t||{},z=!!k,Z="header"===f?"top":"bottom",{anyEnabled:I}=(0,c.F)().checkExperiment("hfp_hf_ssr_mweb",{dangerouslySkipActivation:!0}),T=(0,l.vs)(),E=I?T:(0,l.Yc)(),L=(0,n.useRef)(null),B=(0,n.useRef)(null);(0,n.useEffect)(()=>{try{if(!S){let e=L.current;B.current=j&&e&&Array.isArray(e.children)?e.children[0]:e,B.current instanceof HTMLElement&&r.Z.addObstruction(Z,B.current)}}catch(e){window.console.error(e),window.console.error('Can only register impression obstructions for type "HTMLElement"')}return()=>{!S&&B.current instanceof HTMLElement&&r.Z.removeObstruction(Z,B.current)}},[S,j,Z,E]);let M="top"===Z?"relative":"fixed",O=(null!=d?d:p)+((null==i?void 0:i.overrideTop)||0),R=_||C?{transition:A?"transform 300ms ease-in-out, opacity 300ms ease-in-out":"transform 200ms linear",...g?{transform:`translateY(${"top"===Z?-O:O}px)`,opacity:A?0:1}:Object.freeze({})}:{},D="relative"!==M||null!=i&&i.noGutter?0:2,F=D?-D:0,N=E?"rgba(0,0,0,.95)":"rgba(255,255,255,.95)";return E&&("header"===f?v=-1:w=-1),(0,u.jsx)(o.xu,{ref:L,dangerouslySetInlineStyle:{__style:{top:v,bottomStyle:w,...!y||P?{zIndex:P||1}:Object.freeze({}),...j?{background:"transparent",overflow:"hidden",paddingBottom:100,marginBottom:-100,pointerEvents:"none"}:Object.freeze({}),...null!=i&&i.hasBorder?{borderBottom:"1px solid #efefef"}:Object.freeze({}),...null!=t&&t.hasTopShadow?{boxShadow:"0 -2px 4px 1px rgba(0, 0, 0, 0.08)"}:Object.freeze({}),...R}},zIndex:P?void 0:y,"data-test-id":f,display:z?"flex":void 0,height:d&&!A?d:void 0,position:M,bottom:"footer"===f,top:"header"===f,left:!0,right:!0,marginStart:A?"auto":F,marginEnd:A?"auto":F,onTransitionEnd:()=>{(_||C)&&B.current&&(g?r.Z.removeObstruction(Z,B.current):r.Z.addObstruction(Z,B.current))},width:A||"fixed"!==M?void 0:"100%",children:(0,u.jsx)(o.xu,{dangerouslySetInlineStyle:{__style:{backgroundColor:(null==i?void 0:i.isTranslucent)&&N||(null==i?void 0:i.isTransparentBackground)&&a.FZ||s.wN,height:A?z?void 0:null!=d?d:p:"100%",boxShadow:A?"0px 0px 8px rgba(0, 0, 0, 0.1)":void 0,marginBottom:A&&!(null!=C&&C.docked)?16:void 0,...j?{pointerEvents:"auto"}:Object.freeze({}),...null!=i&&i.useRoundedCorners?{zIndex:5,borderTopRightRadius:17,borderTopLeftRadius:17,borderBottomRightRadius:0,borderBottomLeftRadius:0}:Object.freeze({})}},paddingX:("footer"!==f||x?0:4)+D,paddingY:x?0:b,position:"relative",width:C?C.footerWidth:z?void 0:"100%",rounding:A&&!(null!=C&&C.docked)?"pill":void 0,display:A||null!=t&&t.alignCenter?"flex":void 0,marginStart:A?"auto":void 0,marginEnd:A?"auto":void 0,alignItems:null!=t&&t.alignCenter?"center":void 0,children:"function"==typeof e?e({updateHiddenState:m}):e})})}function g({hasBorder:e,headerLimitedOverflow:t,ignoreObstructions:i,isTranslucent:n,isTransparentBackground:l,noGutter:s,overrideTop:a,useRoundedCorners:r,zIndexForGestaltBug:c,...p}){let{noPadding:g,paddingY:m=h,zIndex:x}=p;return(0,u.jsx)(o.Le,{top:a||0,height:t?44+8*(g?0:m):void 0,zIndex:x||void 0,children:(0,u.jsx)(d.Z,{hideOnScroll:p.hideOnScroll,children:o=>(0,u.jsx)(_,{...p,hideOnScrollState:o,type:"header",headerConfig:{isTranslucent:n,isTransparentBackground:l,headerLimitedOverflow:t,hasBorder:e,ignoreObstructions:i,noGutter:s,overrideTop:a,zIndexForGestaltBug:c,useRoundedCorners:r}})})})}function m({alignCenter:e,appUpsellFooterConfig:t,footerInLego:i,hasTopShadow:n,navFooterConfig:o,...l}){return(0,u.jsx)(d.Z,{appUpsellFooterConfig:t,hideOnScroll:l.hideOnScroll,navFooterConfig:null==o?void 0:o.scrollConfig,children:s=>(0,u.jsx)(_,{...l,hideOnScrollState:s,type:"footer",footerConfig:{alignCenter:e,appUpsellFooterConfig:t,footerInLego:i,hasTopShadow:n,navFooterConfig:o}})})}},834256:(e,t,i)=>{i.d(t,{Z:()=>a,m:()=>s});var n=i(667294),o=i(700380);function l(e,t,i){var n;return(t="symbol"==typeof(n=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"))?n:String(n))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}let s=20;class a extends n.Component{constructor(...e){var t;super(...e),l(this,"state",{isHidden:!!this.props.appUpsellFooterConfig||!!(null!==(t=this.props.navFooterConfig)&&void 0!==t&&t.isDockedNavOnPlp)}),l(this,"lastScrollPos",0),l(this,"updateHiddenState",e=>{this.reqAnimationId=window.requestAnimationFrame(()=>{this.setState({isHidden:e})})}),l(this,"handleScroll",(0,o.Z)(()=>{var e;let{appUpsellFooterConfig:t,navFooterConfig:i}=this.props,{isHidden:n}=this.state,o=window.scrollY,l=o-this.lastScrollPos,a="none",{scrollHeight:r,clientHeight:d}=document.documentElement||{};if(!Number.isNaN(r)&&!Number.isNaN(d)){if(l<0){let e=window.scrollMinY||0;a=o<=Math.abs(e+Math.max(l,s))?"start":"none"}else{let e=window.scrollMaxY||r-d;a=o>=e-Math.max(l,s)?"end":"none"}}let c=null!=i&&i.isModal?0:55;if(t){if(l>s&&n&&o>=500){let e=t.shouldShowAfterScroll();e&&(this.updateHiddenState(!1),null==i||i.onScroll(!1))}else(l<-s&&!n||o<=c)&&(this.updateHiddenState(!0),null==i||i.onScroll(!0))}else null!==(e=this.props.navFooterConfig)&&void 0!==e&&e.isDockedNavOnPlp?"start"===a&&!n||o<=c?(this.updateHiddenState(!0),null==i||i.onScroll(!0)):(o>c||"end"===a)&&n&&(this.updateHiddenState(!1),null==i||i.onScroll(!1)):(l<-s||"start"===a)&&n||o<=c?(this.updateHiddenState(!1),null==i||i.onScroll(!1)):(l>s||"end"===a)&&!n&&(this.updateHiddenState(!0),null==i||i.onScroll(!0));this.lastScrollPos=o},30))}componentDidMount(){try{var e;(this.props.hideOnScroll||null!==(e=this.props.navFooterConfig)&&void 0!==e&&e.isDockedNavOnPlp)&&window.addEventListener("scroll",this.handleScroll)}catch(e){window.console.error(e),window.console.error('Can only register impression obstructions for type "HTMLElement"')}}componentWillUnmount(){var e;(this.props.hideOnScroll||null!==(e=this.props.navFooterConfig)&&void 0!==e&&e.isDockedNavOnPlp)&&window.removeEventListener("scroll",this.handleScroll),this.reqAnimationId&&(window.cancelAnimationFrame(this.reqAnimationId),this.reqAnimationId=null)}componentDidUpdate(e){var t,i,n,o;!e.hideOnScroll&&this.props.hideOnScroll||!(null!==(t=e.navFooterConfig)&&void 0!==t&&t.isDockedNavOnPlp)&&null!==(i=this.props.navFooterConfig)&&void 0!==i&&i.isDockedNavOnPlp?(this.updateHiddenState(!0),window.addEventListener("scroll",this.handleScroll)):(e.hideOnScroll&&!this.props.hideOnScroll||null!==(n=e.navFooterConfig)&&void 0!==n&&n.isDockedNavOnPlp&&!(null!==(o=this.props.navFooterConfig)&&void 0!==o&&o.isDockedNavOnPlp))&&(this.updateHiddenState(!1),window.removeEventListener("scroll",this.handleScroll))}render(){let{children:e,navFooterConfig:t}=this.props,{isHidden:i}=this.state,n=!(null!=t&&t.forceShow)&&i;return e({isHidden:n,updateHiddenState:this.updateHiddenState})}}},248975:(e,t,i)=>{i.d(t,{Z:()=>n});function n({embedSrc:e,embedType:t,imagesUrls:i,preferredResolution:n,excludeOriginals:o}){if(!e&&!t&&!i)return"";if("gif"===t)return e||"";if(!i)return"";if(n){let e="474x"===n&&i["474x"]||"236x"===n&&i["236x"]||i["736x"];if(e)return e}let l=Object.keys(i).reduce((e,t)=>{try{let n=t.split("x")[0];if(Number.isNaN(Number(n)))return{...e,[t]:i[t]};return{...e,[n]:i[t]}}catch(t){return e}},{}),s=Object.keys(l);o&&"orig"===s[s.length-1]&&s.pop();let a=s.pop();return l[a]||""}},992750:(e,t,i)=>{i.d(t,{eg:()=>s,kt:()=>g,rw:()=>h,fs:()=>c,eK:()=>u,Ly:()=>p,BY:()=>_,bN:()=>m,RC:()=>r,EU:()=>d});let n=/\s\s+/g,o=e=>e.replace(n," ");var l=i(883561);let s=Object.freeze(new Set(["sensitive_raw_pin_text","is_sensitive_rich_pin_description","is_sensitive_rich_pin_title","is_sensitive_board_title"])),a=e=>"string"==typeof e?e:"",r=({storyPinDataMetadataPinTitle:e,pinTitle:t})=>e||t,d=(e,t)=>e?e.trim().length>t?(0,l.ZP)(e.trim(),t).trim():e.trim():"",c=({pinTitle:e,gridTitle:t,richSummaryDisplayName:i,richMetadataTitle:n,storyPinDataId:o,storyPinDataMetadataPinTitle:l})=>{let s=l||e,a=d(t,200);return a||i||n||(o&&s?s:null)},u=e=>{let{richSummaryDisplayName:t}=e,i=e.pinJoinVisualAnnotation||[],n=e.pinJoinAnnotationsWithLinks||{},s=e.richMetadataDescription||"",a=e.closeupUnifiedDescription||"",r=i.map(e=>(n||{})[e]||{name:e,url:""}),d="",c=(t||"").toLocaleLowerCase().trim(),u=s.toLocaleLowerCase().trim(),p=a.toLocaleLowerCase().trim();return a&&a.length>3&&p!==c?d=a:s&&s.length>3&&u!==c&&(d=s),d&&(d=o((0,l.ZP)(d,496)).trim()),{description:d,annotationsWithLinks:r}},p=({pinTitle:e,gridTitle:t,richSummaryDisplayName:i,richMetadataTitle:n,storyPinDataId:o,storyPinDataMetadataPinTitle:l,pinJoinVisualAnnotation:a,seoNoindexReason:r,seoTitle:d})=>s.has(null!=r?r:"")?d:c({pinTitle:e,gridTitle:t,richSummaryDisplayName:i,richMetadataTitle:n,storyPinDataId:o,storyPinDataMetadataPinTitle:l})||(null==a?void 0:a[0])||e,h=(e,t,i,n,o)=>{let l=a(e).trim(),s=(e,t)=>t&&t.length>0?`${e} ${t.join(", ")}`:e;return n&&n.trim().length?s(n.trim(),i):o&&o.trim().length?o.trim():l?s(l,i):i?i.join(", "):""},_=e=>`/pin/${e}/`,g=(e,t)=>{let i=`Pinterest video from ${t}: `.concat(e);return""===t?e:i},m=({pinId:e,seoUrl:t})=>t&&"string"==typeof t?t:_(e)},425944:(e,t,i)=>{i.d(t,{Z:()=>d}),i(167912);var n,o=i(357998);let l=["orig","736x","564x","474x","236x","170x"],s=({imageSizeToImageMap:e,preferredSize:t})=>{var i,n,o;let s=e[t];if(s)return{height:s.height,url:s.url,width:s.width};let a=l.indexOf(t);if(a>=0)for(let t=a+1;t<l.length;t+=1){let i=l[t],n=e[i];if(n)return{height:n.height,url:n.url,width:n.width}}return{height:null===(i=e["236x"])||void 0===i?void 0:i.height,url:null===(n=e["236x"])||void 0===n?void 0:n.url,width:null===(o=e["236x"])||void 0===o?void 0:o.width}},a=void 0!==n?n:n=i(170128),r=e=>{var t,i,n,o,l,s;return{imageSpec_170x:(null===(t=e.images)||void 0===t?void 0:t["170x"])&&{height:e.images["170x"].height,url:e.images["170x"].url,width:e.images["170x"].width},imageSpec_236x:(null===(i=e.images)||void 0===i?void 0:i["236x"])&&{height:e.images["236x"].height,url:e.images["236x"].url,width:e.images["236x"].width},imageSpec_474x:(null===(n=e.images)||void 0===n?void 0:n["474x"])&&{height:e.images["474x"].height,url:e.images["474x"].url,width:e.images["474x"].width},imageSpec_564x:(null===(o=e.images)||void 0===o?void 0:o["564x"])&&{height:e.images["564x"].height,url:e.images["564x"].url,width:e.images["564x"].width},imageSpec_736x:(null===(l=e.images)||void 0===l?void 0:l["736x"])&&{height:e.images["736x"].height,url:e.images["736x"].url,width:e.images["736x"].width},imageSpec_orig:(null===(s=e.images)||void 0===s?void 0:s.orig)&&{height:e.images.orig.height,url:e.images.orig.url,width:e.images.orig.width}}};function d({pinKey:e,preferredSize:t}){let{data:i}=(0,o.Q)(a,e,{useLegacyAdapter:r}),n={orig:i.imageSpec_orig,"736x":i.imageSpec_736x,"564x":i.imageSpec_564x,"474x":i.imageSpec_474x,"236x":i.imageSpec_236x,"170x":i.imageSpec_170x};return s({imageSizeToImageMap:null!=n?n:Object.freeze({}),preferredSize:t})}},472644:(e,t,i)=>{i.d(t,{Z:()=>o});var n=i(785893);function o({size:e}){return(0,n.jsx)("svg",{height:e,viewBox:"0 0 512 512",width:e,xmlns:"http://www.w3.org/2000/svg",children:(0,n.jsxs)("g",{fill:"none",fillRule:"evenodd",children:[(0,n.jsx)("path",{d:"M482.56 261.36c0-16.73-1.5-32.83-4.29-48.27H256v91.29h127.01c-5.47 29.5-22.1 54.49-47.09 71.23v59.21h76.27c44.63-41.09 70.37-101.59 70.37-173.46z",fill:"#4285f4"}),(0,n.jsx)("path",{d:"M256 492c63.72 0 117.14-21.13 156.19-57.18l-76.27-59.21c-21.13 14.16-48.17 22.53-79.92 22.53-61.47 0-113.49-41.51-132.05-97.3H45.1v61.15c38.83 77.13 118.64 130.01 210.9 130.01z",fill:"#34a853"}),(0,n.jsx)("path",{d:"M123.95 300.84c-4.72-14.16-7.4-29.29-7.4-44.84s2.68-30.68 7.4-44.84V150.01H45.1C29.12 181.87 20 217.92 20 256c0 38.08 9.12 74.13 25.1 105.99l78.85-61.15z",fill:"#fbbc05"}),(0,n.jsx)("path",{d:"M256 113.86c34.65 0 65.76 11.91 90.22 35.29l67.69-67.69C373.03 43.39 319.61 20 256 20c-92.25 0-172.07 52.89-210.9 130.01l78.85 61.15c18.56-55.78 70.59-97.3 132.05-97.3z",fill:"#ea4335"}),(0,n.jsx)("path",{d:"M20 20h472v472H20V20z"})]})})}},830269:(e,t,i)=>{i.d(t,{Z:()=>n});let n={EMAIL:1,FACEBOOK:2,GPLUS:3,GOOGLE_ONE_TAP:4,SMARTLOCK:5,MULTIFACTOR:6,SWITCH_ACCOUNT:7,LINE:8}},553171:(e,t,i)=>{i.d(t,{Z:()=>_});var n=i(231486),o=i(226198),l=i(844974),s=i(966113),a=i(826067),r=i(643913),d=i(709113);let c="undefined"!=typeof window,u=c?`${window.location.origin}/oauth/line/redirect`:"",p=({origin:e,data:t})=>t&&e===window.location.origin?String(t):null,h=({url:e,key:t})=>{if(!e.startsWith(window.location.origin)||t!==d.MM)return null;let i=(0,l.qn)(d.MM);return(0,l.L_)(d.MM),i};function _(e,t){let i;if(!c){var l;null===(l=t.error)||void 0===l||l.call(t,{message:"Window is undefined"});return}let d=function(e=5){let t="abcdefghijklmnopqrstuvwxyz1234567890";return Array(e).fill("").map(()=>t[Math.floor(Math.random()*t.length)]).join("")}(10),_=async e=>{if(!e.isTrusted)return;let l=e instanceof MessageEvent?p(e):h(e),s=(0,a.mB)(l);if(s.state&&s.code&&s.state===d){var c,g,m;i&&!i.closed&&i.close();try{let e=await fetch("/oauth/line/verify",{headers:{"Content-type":"application/x-www-form-urlencoded; charset=UTF-8","x-csrftoken":`${String(n.U2(o.fS))}`},method:"POST",body:(0,r.Z)({code:s.code,redirect_uri:u})}),i=await e.json(),{id_token:l,access_token:a}=i;l&&a?t.success({line_id_token:l,line_access_token:a}):null===(c=t.error)||void 0===c||c.call(t,{message:"No tokens returned"})}catch(e){null===(g=t.error)||void 0===g||g.call(t,e)}finally{i&&!i.closed&&i.close(),window.removeEventListener("message",_),window.removeEventListener("storage",_),null===(m=t.complete)||void 0===m||m.call(t)}}};window.addEventListener("message",_),window.addEventListener("storage",_),i=window.open(`https://access.line.me/oauth2/v2.1/authorize?response_type=code&client_id=${s.zal}&redirect_uri=${encodeURIComponent(u)}&state=${d}&ui_locales=${e}&scope=profile%20openid%20email`,"_blank")}},711781:(e,t,i)=>{i.d(t,{Z:()=>o});let n=e=>(e||"").replace(/-/g,"+").replace(/_/g,"/"),o=e=>JSON.parse(decodeURIComponent(atob(n(e.split(".")[1])).split("").map(e=>"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)).join("")))},467570:(e,t,i)=>{i.d(t,{GH:()=>r,JF:()=>x,Jb:()=>h,MI:()=>g,_V:()=>d,sl:()=>u,we:()=>p});var n=i(816068),o=i(186656),l=i(713930),s=i(935879),a=i(867820);let r="274266067164",d=()=>["public_profile","email","user_friends"],c=["picture.type(large)","id","first_name","last_name","email","gender"],u=e=>{e&&(0,a.dy)({event:"load_script_success",provider:"facebook"}),"undefined"!=typeof window&&window.FB?(e&&(0,a.dy)({event:"initialize_library",provider:"facebook"}),window.FB.init({appId:r,status:!0,xfbml:!0,version:"v2.7"})):e?(0,a.dy)({event:"global_object_not_found",provider:"facebook"}):(0,a.My)("pcons.non_autologin.fb.global_object_not_found")},p=(e,t)=>{t&&(0,a.dy)({event:"load_script_start",provider:"facebook"});let i=(0,l.Z)((0,s.Z)(e),"FACEBOOK");return i.then(()=>u(t))},h=()=>new Promise(e=>{"undefined"!=typeof window&&window.FB&&window.FB.getLoginStatus(e)}),_=({userID:e,accessToken:t,data:{birthday:i,email:o,first_name:l,gender:s,last_name:a,picture:r}})=>({type:"facebook",facebook_id:e,facebook_token:t,birthday:i?(0,n.Z)(i):void 0,email:o,first_name:l,gender:s,image_url:r&&!r.data.is_silhouette?r.data.url:void 0,last_name:a});async function g(e){let t=await (0,o.Z)({url:"/v3/facebook/profile_data/",method:"POST",data:{access_token:e,pii_safe_birthday:!0,fields:c}}),i=t.resource_response.data||{};return(0,a.My)(i?"pcons.facebook_user.non_empty_user_data_returned":"pcons.facebook_user.empty_user_data_returned"),{access_token:e,birthday:i.birthday,email:i.email,first_name:i.first_name,gender:i.gender,id:i.id,last_name:i.last_name,picture:i.picture}}let m=(e,t)=>new Promise((i,n)=>{if("connected"!==e.status){n({status:e.status||"unknown"});return}let{userID:o,accessToken:l}=e.authResponse;g(l).then(e=>{i({creds:{facebook_id:o,facebook_token:l,facebook_autologin:(null==t?void 0:t.autologin)||!1},signupOptions:_({userID:o,accessToken:l,data:e})})},n)}),x=()=>new Promise(e=>{window.FB.login(e,{scope:d().join(",")})}).then(e=>m(e))},935879:(e,t,i)=>{i.d(t,{Z:()=>o});let n=e=>{let t=e.replace(/-/g,"_");if(t.startsWith("es"))return"es_LA";if(t.startsWith("ar"))return"ar_AR";switch(t){case"de":return"de_DE";case"fr":return"fr_FR";case"it":return"it_IT";case"ja":return"ja_JP";case"nl":return"nl_NL";case"tr":return"tr_TR";case"en_AU":return"en_US";default:return t}},o=e=>`//connect.facebook.net/${n(e)}/sdk.js`},143461:(e,t,i)=>{i.d(t,{D:()=>r,T:()=>a});var n=i(667294),o=i(874103),l=i(785893);let s=(0,n.createContext)({recaptchaV3Token:"",refreshToken:()=>{}});function a({children:e}){let[t,i]=(0,n.useState)(""),a=(0,n.useCallback)(()=>{(0,o.rY)(e=>i(e),e=>{},o.sk)},[]);(0,n.useEffect)(()=>{a();let e=setInterval(a,o.yc);return()=>{clearInterval(e)}},[a]);let r=(0,n.useMemo)(()=>({recaptchaV3Token:t,refreshToken:a}),[t,a]);return(0,l.jsx)(s.Provider,{value:r,children:e})}let r=()=>(0,n.useContext)(s)},458882:(e,t,i)=>{i.d(t,{l:()=>l,r:()=>s});var n=i(667294);let o=(0,n.createContext)(null),l=()=>(0,n.useContext)(o),s=o.Provider},667679:(e,t,i)=>{i.d(t,{Z:()=>l});var n=i(780679),o=i(458882);let l=()=>{let e=(0,n.g)(),t=(0,o.l)();return i=>{let{mobileOptions:n,desktopOptions:o,reason:l,attributionLabel:s,pinId:a}=i;e?e.showDesktopSignupModal({signupFlow:(null==o?void 0:o.modalType)==="login"?{type:"login"}:{type:"signup"},reason:l,attributionLabel:s,...null==o?void 0:o.modalOptions}):t&&t.showMobileSignupModal({reason:l,attributionLabel:s,headingType:null==n?void 0:n.headingType,pinId:a})}}},101331:(e,t,i)=>{i.d(t,{A:()=>u,Z:()=>c});var n=i(667294),o=i(112690),l=i(385740),s=i(780679),a=i(458882),r=i(957161),d=i(709113);function c(){let{trackConversionUpsellForContext:e}=(0,s.g)()||{},{trackConversionUpsellForContext:t}=(0,a.l)()||{},{viewType:i,viewParameter:n}=(0,l.SU)();return{trackConversionUpsell:({eventType:o,viewType:l,viewParameter:s,element:a,component:r,upsellReason:d,incrementUpsellReasonCounter:c})=>{let u=e||t;u&&u({eventType:o,viewType:l||i||202,viewParameter:s||n,element:a,component:r,upsellReason:d,incrementUpsellReasonCounter:c})}}}function u(){let e=(0,o.Z)(),t=(0,n.useRef)(null),i=()=>r.Z.getItem(d.w0)||0,l=()=>{r.Z.setItem(d.w0,i()+1)};return{trackConversionUpsellForContext:({eventType:n,viewType:o,viewParameter:s,element:a,component:c,upsellReason:u,incrementUpsellReasonCounter:p})=>{14688===n&&(r.Z.setItem(d.bg,u||""),t.current=c,!1!==p&&l()),e({event_type:n,view_type:o,view_parameter:s,element:a,component:t.current,aux_data:{upsell_reason:r.Z.getItem(d.bg)||null,upsell_view_count:i()}})}}}},123906:(e,t,i)=>{i.d(t,{Z:()=>n});let n=(e,t)=>{let i=new URL(e,"https://pinterest.com");return i.search=new URLSearchParams(t).toString(),i.toString().substring(i.origin.length)}},81072:(e,t,i)=>{i.d(t,{Z:()=>l});var n=i(667294),o=i(700380);let l=()=>{let[e,t]=(0,n.useState)(0);return(0,n.useEffect)(()=>{let e=(0,o.Z)(()=>t(window.scrollY),10);return window.addEventListener("scroll",e),()=>{window.removeEventListener("scroll",e)}},[]),e}},824385:(e,t,i)=>{i.d(t,{Z:()=>n});let n=e=>async()=>{let{NewPassword:t}=await i.e(23468).then(i.bind(i,323468));return t(e)}},329900:(e,t,i)=>{i.d(t,{Z:()=>w});var n=i(407043),o=i(773285),l=i(780280),s=i(619277),a=i(948376),r=i(780678),d=i(826067),c=i(67347);let u="http://play.google.com/store/apps/details?id=com.pinterest",p=["access_token","new_password","new_password_confirm","password","next"],h=(e,t)=>t?(0,d.ru)(e,{invite_code:t}):e,_=(e,t,i)=>{if("ios"===t&&"string"==typeof e&&e.startsWith("discover/article/")){let t=e.split("/")[2];e=`discover_article/${t}/?is_deeplink=1`}return("string"==typeof e&&"shopping/"===e&&(e="?is_deeplink=1"),"string"==typeof e)?h(e,i):"ios"===t||"ipad"===t?h(e.iOS,i):"android"===t?h(e.android,i):null},g=({deeplinkUri:e,invite_code:t,platform:i,fallbackUrl:n,unauthId:o,app_upsell_type:l})=>({deeplink_path:_(e,i,t),current_page_url:(0,d.Gw)("undefined"!=typeof window?window.location.href:"",p),install_id:o,utm_source:140,utm_medium:2152,app_upsell_type:l,...n?{af_r:n}:null}),m=({deeplinkUri:e,invite_code:t,platform:i,unauthId:n,app_upsell_type:o})=>{let l=JSON.stringify({deeplink_path:_(e,i,t),current_page_url:(0,d.Gw)("undefined"!=typeof window?window.location.href:"",p),install_id:n}),s=(0,d.XP)({utm_source:"mweb",utm_medium:"upsell",utm_content:l,app_upsell_type:o});return{referrer:s}},x=({unauthId:e,app_upsell_type:t})=>{let i=(0,d.XP)({utm_source:"mweb",utm_medium:"upsell",utm_campaign:"twa",utm_content:e,app_upsell_type:t});return{referrer:encodeURI(i)}},b=({isAuthenticated:e,deeplinkUri:t,fallbackUrl:i,invite_code:n,logContextEvent:o,platform:l,redirectToLite:s,unauthId:a,userAgent:p,app_upsell_type:h})=>{if(null==o||o({component:14347,element:13582,event_type:701,view_type:20,view_parameter:3844,aux_data:{app_upsell_type:h}}),t){let _=g({isAuthenticated:e,deeplinkUri:t,fallbackUrl:i,invite_code:n,platform:l,unauthId:a,userAgent:p,app_upsell_type:h});if((0,c.nP)("mweb.deeplink",{sampleRate:1,tags:{platform:l}}),n&&(0,c.nP)("mweb.deeplink.invite_code",{sampleRate:1}),(0,c.nP)("mweb.deeplink.unauthId",{sampleRate:1,tags:{withUnauthId:!!a}}),s){(0,c.nP)("mweb.deeplink.lite_link",{sampleRate:1}),null==o||o({component:14347,element:13582,event_type:14540,view_type:20,view_parameter:3844,aux_data:{app_upsell_type:h}});let e=x({unauthId:a,app_upsell_type:h});window.location.href=(0,d.ru)("http://play.google.com/store/apps/details?id=com.pinterest.twa",e)}else if("android"===l){let e=m({deeplinkUri:t,invite_code:n,platform:l,unauthId:a,app_upsell_type:h});(0,r.v)()?(0,r.Z)().then(t=>{if(t.length>0){let e=(0,d.ru)(window.location.href,_);null==o||o({component:14347,element:13582,event_type:703,view_type:20,view_parameter:3844,aux_data:{app_upsell_type:h}});let t=window.open(e);t||null==o||o({component:14347,element:13582,event_type:702,view_type:20,view_parameter:3844,aux_data:{app_upsell_type:h}})}else null==o||o({component:14347,element:13582,event_type:14538,view_type:20,view_parameter:3844,aux_data:{app_upsell_type:h}}),window.location.href=(0,d.ru)(u,e)}).catch(()=>{(0,c.nP)("mweb_android.deeplink.playStore.error",{sampleRate:1})}):(null==o||o({component:14347,element:13582,event_type:14538,view_type:20,view_parameter:3844,aux_data:{app_upsell_type:h}}),window.location.href=(0,d.ru)(u,e))}else{if((0,c.nP)("mweb.deeplink.appsflyer_link",{sampleRate:1}),"ios"===l&&"undefined"!=typeof window&&window.location.href.includes("show_yip_modal")){window.location.href=(0,d.ru)("https://pinterest.com/pinterest-predicts",_);return}null==o||o({component:14347,element:13582,event_type:14539,view_type:20,view_parameter:3844,aux_data:{app_upsell_type:h}}),window.location.href=(0,d.ru)("https://pinterest.onelink.me/TVSr/21e04bfd",_)}}};var f=i(785893);function y({children:e,invite_code:t}){let{isAuthenticated:i,isBot:s,unauthId:r,userAgent:{platform:d,raw:c}}=(0,l.B)(),{logContextEvent:u}=(0,n.v)(),{checkExperiment:p}=(0,o.F)(),h=async(e,n,o)=>{u({component:14347,element:13582,event_type:700,view_type:20,view_parameter:3844,aux_data:{app_upsell_type:n}}),b({isAuthenticated:i,checkExperiment:p,deeplinkUri:e,fallbackUrl:o,invite_code:t,logContextEvent:u,platform:d,redirectToLite:(0,a.Rp)({isBot:s,platform:d,userAgent:c}),unauthId:r,userAgent:c,app_upsell_type:n})};return e(h)}let v=e=>(0,f.jsx)(s.ty,{children:t=>(0,f.jsx)(y,{...e,invite_code:t})});v.displayName="DeepLinkNavigator";let w=v},962482:(e,t,i)=>{i.d(t,{Z:()=>s});var n=i(883119),o=i(898781),l=i(785893);let s=({isInModal:e})=>{let t=(0,o.ZP)();return(0,l.jsx)(n.xu,{alignItems:"center",display:"flex",height:"100%",justifyContent:"center",left:!0,position:e?"absolute":"fixed",top:!0,width:"100%",zIndex:new n.Ry(1),dangerouslySetInlineStyle:{__style:{backgroundColor:"rgba(255, 255, 255, .5)"}},children:(0,l.jsx)(n.$j,{accessibilityLabel:t._('Loading', 'Full page loading state', 'Full page loading state'),show:!0})})}},63552:(e,t,i)=>{i.d(t,{Z:()=>l});var n=i(883119),o=i(785893);function l({children:e,onMouseEnter:t,onMouseLeave:i,onTouch:l,rounding:s,fullWidth:a=!1,pressState:r="none",accessibilityLabel:d,role:c}){let u=(Array.isArray(r)?r:[r]).includes("compress");return(0,o.jsx)(n.iP,{fullWidth:a,onMouseEnter:t&&(({event:e})=>t(e)),onMouseLeave:i&&(({event:e})=>i(e)),onTap:l&&(({event:e})=>l(e)),rounding:s,tapStyle:u?"compress":"none",accessibilityLabel:d,role:c,children:e})}},237014:(e,t,i)=>{i.r(t),i.d(t,{default:()=>eo});var n=i(667294),o=i(950209),l=i(616550),s=i(883119),a=i(789540),r=i(796592),d=i(700842),c=i(53987),u=i(622096),p=i(807609),h=i(785893);let _=["passwordReset","passwordUserName","topic","flashlight","todayTab","todayArticleFeed","todayArticleInterestFeed","ideasHub","ideasRoot","invited","pinBookmarklet","shoppingRoot","shoppingCategory","videosRoot","videosCategory"],g="_bottomRightUpsellDismissed";function m({hideDesktopSignupModal:e,inviter:t,pageType:i,signupModalState:o,shouldShowSignupWelcomeLoading:m,setShouldShowSignupWelcomeLoading:x}){var b;let f=(0,p.Z)(),y=(0,l.useLocation)(),[v,w]=(0,n.useState)(null!==(b=u.Z.getItem(g))&&void 0!==b&&b);(0,n.useEffect)(()=>{u.Z.setItem(g,v)},[v]);let j=!f&&!(({pageType:e,location:t})=>_.includes(e)||(0,c.Ni)(t)||(0,c.C$)(t)||(0,c.Xn)(t)||"/invited/"===t.pathname||t.pathname.startsWith("/about/"))({location:y,pageType:i});return(0,h.jsxs)(n.Fragment,{children:[j&&!v&&(0,h.jsx)(d.Z,{inviter:t,setHasDismissedBottomRightUpsell:w}),o.modal.isShown&&(0,h.jsx)(a.Z,{inviter:t,hideDesktopSignupModal:e,pageType:i,setShouldShowSignupWelcomeLoading:x,displayProps:o.modal.displayProps}),m&&(0,h.jsx)(s.xu,{opacity:1,position:"fixed",bottom:!0,top:!0,right:!0,left:!0,zIndex:new s.Ry(100),dangerouslySetInlineStyle:{__style:{backgroundColor:"rgba(0, 0, 0, 0.6)"}},children:(0,h.jsx)(r.Z,{})})]})}var x=i(917254),b=i(780679),f=i(56641),y=i(385740),v=i(67347);let w=(e,t)=>(0,v.nP)(`pinner_conversion.upsell.dweb_signup_modal.${e}`,{flushImmediate:!0,sampleRate:1,tags:t}),j=(e,t)=>{switch(t.type){case"dismiss":return{...e,modal:{isShown:!1}};case"show":return{...e,modal:{isShown:!0,displayProps:t.displayProps}};default:return e}},S=()=>(0,n.useReducer)(j,{modal:{isShown:!1}});var P=i(957161),k=i(844974),A=i(709113);let C=604800,z=(e,t=C)=>{let i=(0,k.qn)(e);return i&&Date.now()-parseInt(i,10)>1e3*t},Z=(e=C)=>{let t=P.Z.getItem(A.TO);return z(A.On,e)||!t?0:parseInt(t,10)||0},I=(e=C)=>{let t=Z();if(z(A.On,e)||!t)try{P.Z.setItem(A.TO,1),P.Z.setItem(A.On,Date.now())}catch(e){console.error(e)}else try{P.Z.setItem(A.TO,t+1)}catch(e){console.error(e)}};var T=i(366394),E=i(992750),L=i(773285),B=i(867820),M=i(52022),O=i(101331),R=i(826067),D=i(794230),F=i(987318);let N=e=>{switch(e){case"todayArticleFeed":return{eligible:!0,container:"todayArticleFeed"};case"todayTab":return{eligible:!0,container:"todayTab"};default:return{eligible:!1}}},U=({pageType:e})=>{let t=(0,l.useLocation)(),[i,o]=S(),{loginForMore:s}=(0,F.H)(),a=(0,l.useHistory)(),r=(0,M.Z)(),{viewType:d,viewParameter:p}=(0,y.SU)(),{trackConversionUpsellForContext:h}=(0,O.A)(),{checkExperiment:_}=(0,L.F)(),g=({shouldDoSideEffects:t})=>{t&&s&&N(e).eligible&&s.setVisible(!1),o({type:"dismiss"}),w("dispatch_dismiss",{shouldDoSideEffects:t})},m=e=>{o({type:"show",displayProps:e});let{attributionLabel:t,container:i,signupFlow:n,reason:l}=e;(0,B.My)(`unauth_web_container.${null!=i?i:"undefined"}.tier1.${n.type}.shown`),r({action:"trigger",item:n.type.includes("signup")?"signup-modal":"login-modal"}),h({viewType:d,viewParameter:p,eventType:14688,element:{UPSELL_LOGIN_OR_SIGNUP:13319,ACTION_REQUIRES_LOGIN_OR_SIGNUP:13320,CLICK_LOGIN_OR_SIGNUP:13321}[l]||13322,component:"login"===n.type?14212:14214,upsellReason:t}),w("dispatch_show",{attributionLabel:t,modalType:n.type,reason:l})},x=(e,t)=>m({signupFlow:{type:"login"},attributionLabel:t,container:e,reason:"UPSELL_LOGIN_OR_SIGNUP"}),b=!!(null==s?void 0:s.visible),v=(0,n.useRef)(b);return(0,n.useEffect)(()=>{if(b!==v.current){v.current=b;let t=N(e);t.eligible&&(b?x(t.container,"loginForMoreIsVisible"):g({shouldDoSideEffects:!0}))}}),(0,n.useEffect)(()=>{(0,B.My)(`unauth_web.unauth_page_wrapper.${e}.mounted.is_mobile_false`);let t="p100"===(0,R.mB)(window.location.search).utm_source;t&&(0,T.$)()},[]),{hideDesktopSignupModal:g,pinImageClickHandler:({event:i,pinId:n,seoUrl:o,linkTarget:l})=>{i&&i.preventDefault(),(0,B.My)(`unauth.desktop.${e}.pin_image.click`);let s=null;if(!(0,T.o)()){var r;let e=null!==(r=P.Z.getItem(A.cu))&&void 0!==r?r:0;if(e+1>=4){let e=u.Z.getItem("VISUAL_SEARCH_SOURCE"),i=(0,c.mP)(t),n=i&&_("dweb_unauth_main_pin_visual_search_v2");i&&n.anyEnabled?("MAIN_PIN_WASH"===e&&"enabled_1_nav_upsell_post_land"===n.group||"FLASH_LIGHT_BUTTON"===e&&"enabled_3_no_wash_upsell_post_land"===n.group)&&(s={mt:"login"},(0,B.My)("dweb.navigational.upsell.show")):u.Z.getItem("HAS_SEEN_LOGIN_MODAL")||(u.Z.setItem("HAS_SEEN_LOGIN_MODAL","true"),s={mt:"login"},(0,B.My)("dweb.navigational.upsell.show"))}P.Z.setItem(A.cu,e+1)}let d=(0,D.Z)((0,E.bN)({pinId:n,seoUrl:o}),s||{});if("fullPageLoad"===l){(0,f.Z)(d,!1);return}if("duploClientNav"===l)a.push(d);else{let e=window.open(d,"_blank");e.focus()}g({shouldDoSideEffects:!1})},pinLinkClickHandler:()=>{if(I(),(0,T.o)())return;let e=Z();(2===e||e%5==0)&&x("hybrid_clickthrough","pinLinkClickHandler_tier1")},modalOpened:!!i.modal.isShown,showDesktopSignupModal:m,signupModalState:i,showGoogleOneTapTriggeredModal:e=>{switch(e.type){case"CLICK_LOGIN_BUTTON":m({signupFlow:{type:"login"},attributionLabel:"tap_googleOneTap_login",source:"login",container:"google_one_tap_modal",reason:"CLICK_LOGIN_OR_SIGNUP"});break;case"LOGIN_ERROR":m({signupFlow:{type:"login"},source:"login",reason:"CLICK_LOGIN_OR_SIGNUP",attributionLabel:"tap_googleOneTap_loginError"});break;case"MFA":m({signupFlow:{type:"loginMfa",creds:{google_open_id_token:e.mfaGoogleOpenId}},reason:"CLICK_LOGIN_OR_SIGNUP",attributionLabel:"tap_googleOneTap_mfa"});break;case"GDPR_REQUIRES_AGE":m({signupFlow:{type:"socialSignupWithAge",registrationCredentials:e.socialRegistrationCredentials},reason:"CLICK_LOGIN_OR_SIGNUP",attributionLabel:"tap_googleOneTap_gdprRequiresAge"})}},trackConversionUpsellForContext:h}};var H=i(612470),W=i(391254),$=i(143461),G=i(829407),Y=i(207594),K=i(100745),X=i(82058),q=i(412544),J=i(496311),V=i(7882),Q=i(503347),ee=i(791185);function et({children:e,showDesktopSignupModal:t}){return(0,h.jsx)(J.Z,{children:(0,h.jsxs)(s.xu,{children:[(0,h.jsx)(Q.default,{showDesktopSignupModal:t}),(0,h.jsxs)(s.xu,{id:"mweb-unauth-container",children:[e,(0,h.jsx)(ee.Z,{})]}),(0,h.jsx)(V.default,{})]})})}let ei=H.Z+o.Z,en=({children:e})=>{var t;let i=(0,q.Z)(),{hideDesktopSignupModal:o,pinImageClickHandler:l,pinLinkClickHandler:s,showDesktopSignupModal:a,signupModalState:r,showGoogleOneTapTriggeredModal:d,trackConversionUpsellForContext:c}=U({pageType:i}),u=(0,X.cO)(),[p,_]=(0,n.useState)(!1),g=(0,n.useMemo)(()=>({isModalShown:r.modal.isShown,showDesktopSignupModal:a,pinImageClickHandler:l,pinLinkClickHandler:s,showGoogleOneTapTriggeredModal:d,trackConversionUpsellForContext:c}),[r.modal.isShown,a,l,s,d,c]);return(0,G.Z)(()=>{let e=Intl.DateTimeFormat().resolvedOptions().timeZone;(0,B.tj)("web.unauth.locale_data",{tz:e})}),(0,h.jsxs)(b.t,{value:g,children:[(0,h.jsx)(et,{showDesktopSignupModal:a,children:e}),(0,h.jsx)(m,{hideDesktopSignupModal:o,inviter:(null==u?void 0:null===(t=u.data)||void 0===t?void 0:t.inviter)||void 0,pageType:i,signupModalState:r,shouldShowSignupWelcomeLoading:p,setShouldShowSignupWelcomeLoading:_})]})};function eo({children:e}){return(0,h.jsx)($.T,{children:(0,h.jsx)(K.N,{children:(0,h.jsx)(Y.h,{children:(0,h.jsx)(X.xM,{children:(0,h.jsxs)("div",{role:"main",children:[(0,h.jsx)(W.Z,{unsafeCSS:ei}),(0,h.jsx)(x.Z,{children:(0,h.jsx)(en,{children:e})})]})})})})})}},872482:(e,t,i)=>{i.d(t,{D:()=>o,a:()=>l});var n=i(425288);let{Provider:o,useMaybeHook:l}=(0,n.Z)("unauthPageWrapperContext")},496311:(e,t,i)=>{i.d(t,{Z:()=>g});var n=i(667294),o=i(702664),l=i(616550),s=i(53987),a=i(773285),r=i(780280),d=i(19121),c=i(938917),u=i(948376),p=i(364034),h=i(872482),_=i(785893);function g({children:e}){let t;let{isAuth:i}=(0,d.Z)(),{isBot:g}=(0,r.B)(),m=(0,l.useLocation)(),x=(0,l.useRouteMatch)(),[b,f]=(0,n.useState)((0,s.uM)(m)?{isStoryPin:"unknown"}:null);(0,n.useEffect)(()=>{f((0,s.uM)(m)?{isStoryPin:"unknown"}:null)},[m]);let y=(0,n.useCallback)(e=>f({isStoryPin:e}),[]),{userAgent:v,userAgentPlatform:w}=(0,o.useSelector)(({session:e})=>({userAgent:e.userAgent,userAgentPlatform:e.userAgentPlatform}),o.shallowEqual),j=(0,c.Z)(),S=j||(0,u.Rp)({isBot:g,platform:w,userAgent:v}),{checkExperiment:P}=(0,a.F)(),[k,A]=(0,n.useState)(!1),[C,z]=(0,n.useState)(!1),[Z,I]=(0,n.useState)(!1),[T,E]=(0,n.useState)(!1),[L,B]=(0,n.useState)(!1),M=(0,p.Z)();if(!i){let e=S&&((0,s.uM)(m)||(0,s.am)(m)||(0,s.$Y)(m)||(0,s.E0)(m)||(0,s.Zz)(m)||(0,s.dr)(m)||(0,s.tZ)(m)||(0,s.Q0)(m)||(0,s.f1)(m)||(0,s.OX)(m)||(0,s.gT)(m)||(0,s.bW)(m)||(0,s.En)(m)||(0,s.wg)(m)||"/unauth-profile"===x.path||"/:username"===x.path||"/:username/:slug/:section_slug"===x.path||(0,s.Xn)(m)||("/:username/_created"===x.path||"/:username/_saved"===x.path)&&"enabled_add_tabs"===P("pcons_header_on_created_and_saved_tab").group);t={appInstallBannerIsEnabled:e,hasScrolledPastMainContent:k,setHasScrolledPastMainContent:A,hasDraggedDrawerToFullScreen:C,setHasDraggedDrawerToFullScreen:z,shouldShowVisualSearchAppUpsell:Z,setShouldShowVisualSearchAppUpsell:I,pinPageGlobalContext:b,onPinTypeLoad:y,shouldShowLearningUpsell:T,setShouldShowLearningUpsell:E,shouldShowHomepageAppUpsellSheet:L,setShouldShowHomepageAppUpsellSheet:B,unauthSavedPinsStore:M}}return(0,_.jsx)(h.D,{value:t,children:e})}},7882:(e,t,i)=>{i.r(t),i.d(t,{default:()=>to});var n=i(667294),o=i(702664),l=i(616550),s=i(436851),a=i(407043),r=i(231486),d=i(226198),c=i(319915),u=i(332611),p=i(53987),h=i(773285),_=i(780280),g=i(947599),m=i(458882),x=i(844974),b=i(339363),f=i(867820),y=i(826067),v=i(50286),w=i(829407),j=i(116485),S=i(529195),P=i(883119),k=i(807609);function A({children:e}){return!(0,k.Z)()&&e}var C=i(499128),z=i(898781),Z=i(584595),I=i(830269),T=i(343341),E=i(275926),L=i(785893);let B="keychainAutologinDisabled",M="mweb.unauth.ios_keychain_autologin";function O(){let[e,t]=(0,n.useState)(""),[i,o]=(0,n.useState)(""),s=(0,n.useRef)(!1),a=!!e&&!!i,r=(0,n.useRef)(),d=(0,E.f)(),c=(0,l.useHistory)(),u=(0,l.useLocation)(),p=(0,z.ZP)(),{showToast:h}=(0,T.F9)();(0,n.useEffect)(()=>{r.current&&r.current.focus()},[]);let _=({errorReason:e,errorCode:t,errorMessage:i})=>{let n=e||t===Z.oP?"invalid_password":t===Z.hU?"invalid_email":"login";(0,f.My)(`${M}.failure.${n}`),(0,b.Nh)(B,!0),c.push({pathname:"/login",state:{keychainiOSAutologinError:{code:t,message:i}}})};(0,n.useEffect)(()=>{s.current!==a&&(s.current=a,(0,b.Nh)(B,!0),d({username_or_email:e,password:i},c,u.pathname,{isAutologin:!0},{event_type:7534,view_type:9,view_parameter:63,aux_data:{signup_login_method:I.Z.EMAIL,upsell_reason:"autologin_keychain"}}).then(()=>{h(({hideToast:e})=>(0,L.jsx)(C.ZP,{text:p._('You\'re logged in!', 'mweb.unauth.ios_keychain_autologin.login_success_toast', 'Toast to alert user they are being logged in'),onHide:e})),(0,f.My)(`${M}.login_success`)}).catch(e=>{_({errorCode:e.api_error_code,errorMessage:e.message})}))});let g=({value:e,type:i})=>{if(1===e.length){_({errorReason:"manual_input_attempt"});return}"email"===i?t(e):o(e)},m=()=>{a||(0,f.My)(`${M}.failure.user_dismissed_prompt`),(0,b.Nh)(B,!0)};return(0,L.jsx)(P.xu,{position:"absolute",top:!0,opacity:0,dangerouslySetInlineStyle:{__style:{zIndex:-100}},children:(0,L.jsxs)("form",{onSubmit:e=>{e.preventDefault()},autoComplete:"on","aria-hidden":"true",children:[(0,L.jsx)(P.nv,{autoComplete:"username",id:"username",onChange:({value:e})=>g({value:e,type:"email"}),ref:r,size:"lg",type:"email",value:e,onBlur:m}),(0,L.jsx)(P.nv,{autoComplete:"current-password",id:"current-password",onChange:({value:e})=>g({value:e,type:"password"}),size:"lg",type:"password",value:i,onBlur:m})]})})}let R=()=>{let e=(0,l.useLocation)(),{isBot:t,userAgent:{browserName:i}}=(0,_.B)();return!t&&"Mobile Safari"===i&&((0,p.bo)(e)||(0,p.E0)(e)||(0,p.dr)(e)||(0,p.gT)(e)||(0,p.uM)(e)||(0,p.am)(e))&&!(0,b.qn)(B,!1)};function D(){let e=R();return e&&(0,L.jsx)(O,{})}function F(){return(0,L.jsx)(A,{children:(0,L.jsx)(D,{})})}var N=i(622096);let U="susdst",H="susdd",W=e=>{N.Z.getItem(H)||N.Z.setItem(H,e),N.Z.setItem(U,new Date().getTime())},$=()=>{if("undefined"==typeof window)return!1;let e=N.Z.getItem(U),t=N.Z.getItem(H);return!!e&&!!t&&new Date().getTime()-e<=t},G=(e,t)=>e===t||!!e&&!!t&&e.pathname===t.pathname,Y=e=>e&&!!e.key,K=({newLocation:e,oldLocation:t})=>Y(e)&&(0,p.L6)(e)&&((0,p.L6)(t)||(0,p.am)(t)||(0,p.cD)(t)||(0,p.En)(t))&&!(0,b.qn)("openUnauthType")&&!$();var X=i(56390);let q=e=>e.includes("_created")||e.includes("boards"),J="SEEN_NAV_UPSELL",V=({mobileSignupModalContext:e})=>{let t=(0,l.useLocation)(),i=(0,n.useRef)(t);(0,n.useEffect)(()=>{let n=i.current,o="?source=swipe"===t.search;if(n!==t&&!G(n,t)&&!q(t.pathname)){(0,X.C)(t);let{showMobileSignupModal:i,dismissMobileSignupModal:l,incrementUpsellEligibleNavigationCount:s,upsellIsEnabledGlobally:a,upsellEligibleNavigationCount:r,modal:{isShown:d}}=e,c=r+1;d?l():a()&&K({newLocation:t,oldLocation:n})&&!o&&(r>=3&&!N.Z.getItem(J)&&(i({reason:"UPSELL_LOGIN_OR_SIGNUP",attributionLabel:`navigation_3_${c}`,navigationTriggeredUpsell:{newLocation:t,oldLocation:n}}),N.Z.setItem(J,!0),(0,f.My)(`mweb.nav.upsell.show.${c}`)),s())}i.current=t},[t,e])};function Q({context:e}){return V({mobileSignupModalContext:e}),null}var ee=i(639952),et=i(214494),ei=i(385740),en=i(619277),eo=i(598615),el=i(313047),es=i(19121),ea=i(664166);function er({onOpenInAppClick:e}){let{isAuth:t}=(0,es.Z)(),i=(0,l.useLocation)(),n=(0,z.ZP)();return(0,L.jsx)(el.FixedFooter,{footerInLego:!0,appUpsellFooterConfig:{shouldShowAfterScroll:()=>!!(!t&&(0,p.L6)(i))&&((0,ea.y)(),!0)},hideOnScroll:!0,noPadding:!0,children:(0,L.jsx)(P.xu,{alignItems:"center",display:"flex",justifyContent:"around",marginEnd:4,marginStart:4,maxWidth:264,children:(0,L.jsx)(P.iP,{onTap:e,children:(0,L.jsxs)(P.xu,{alignItems:"center",display:"flex",paddingY:4,children:[(0,L.jsx)(P.xu,{marginEnd:2,children:(0,L.jsx)(P.JO,{accessibilityLabel:n._('Pinterest logo', 'AppUpsellFooter.icon', 'Pinterest logo icon for app upsell footer'),color:"brandPrimary",icon:"pinterest",inline:!0,size:24})}),(0,L.jsx)(P.xv,{weight:"bold",children:n._('Open in app', 'AppUpsellFooter.text.open', 'Short phrase for footer to upsell installing the app')})]})})})})}function ed({clientTrackingParams:e,onOpenInApp:t,viewParameter:i,viewType:n}){return(0,L.jsx)(ea.Z,{clientTrackingParams:e,viewParameter:i,viewType:n,children:(0,L.jsx)(er,{onOpenInAppClick:()=>{(0,ea.y)(),t()}})})}var ec=i(938917),eu=i(350576),ep=i(114020),eh=i(640064);let e_="sumdc",eg=()=>{let e=(0,es.Z)(),t=e&&e.isAuth,{referrerFromCookie:i}=(0,_.B)(),n=(0,eu.Xn)((0,eu.an)(null!=i?i:"")),l=(0,o.useSelector)(({session:e})=>e.unauthSavePinId&&!t),{unauthCommentPinId:s,removeUnauthCommentPinId:a}=(0,ep.C)(),r=s&&t,{unauthFollowUserId:d,removeUnauthFollowUserId:c}=(0,eh.f)(),u=d&&t,p=(0,o.useDispatch)();return()=>{l&&p((0,ee.n1)()),r&&a(),u&&c(),(0,f.NC)("hide_dismissable_modal"),(0,f.My)("mweb.unauth_dismiss_modal");let e=N.Z.getItem(e_)||0;e+=1,N.Z.setItem(e_,e);let t=1===e;n&&t&&W(6e4)}};var em=i(356997),ex=i(349700),eb=i(966113),ef=i(63552),ey=i(172351),ev=i(542837),ew=i(67347);function ej(e,t,i){var n;return(t="symbol"==typeof(n=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"))?n:String(n))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}let eS={visible:{transform:"translateY(0)",transition:"all 225ms cubic-bezier(0.0,0.0,0.2,1)"},hiding:{transform:"translateY(350px)",transition:"all 225ms cubic-bezier(0.0,0.0,0.2,1)"},wash:{backgroundColor:"rgba(0, 0, 0, 0.5)",height:"100%",touchAction:"none",width:"100%",zIndex:10001,position:"fixed",top:0,left:0},mask:{baseStyles:{backgroundColor:"rgba(0,0,0, .5)",height:"100%",touchAction:"none",width:"100%",zIndex:1}}};class eP extends n.PureComponent{constructor(...e){super(...e),ej(this,"state",{visible:!1,hiding:!1,showWash:!1}),ej(this,"getTitle",()=>{let{invite:e}=this.props,t=e&&e.sender,i=t&&t.first_name;return(this.props.i18n._('Join {{ name }} on Pinterest for more ideas', 'Prompt user to signup to access all Pinterest features', 'Prompt user to signup to access all Pinterest features')).replace("{{ name }}",i||"")}),ej(this,"getAvatar",()=>{let{invite:e}=this.props,t=e&&e.sender,i=t&&t.image_medium_url,n=t&&t.full_name;return(0,L.jsx)(em.qE,{src:i||"",name:n||"",size:"sm"})}),ej(this,"handleHide",()=>{let{onDismiss:e}=this.props;(0,ew.nP)("mweb_facebook_social_upsell.close"),this.setState({hiding:!0,showWash:!1}),this.slideInAnimation=window.requestAnimationFrame(()=>{setTimeout(()=>{e&&e()},1e3)})}),ej(this,"handleHideOutsideTap",()=>{let{onDismiss:e}=this.props;(0,ew.nP)("mweb_facebook_social_upsell.close.outside.modal"),this.setState({hiding:!0,showWash:!1}),this.slideInAnimation=window.requestAnimationFrame(()=>{setTimeout(()=>{e&&e()},1e3)})}),ej(this,"handleFBConnect",e=>{(0,ew.nP)(`mweb_facebook_social_upsell.fb_connect_button_click.${e}`)}),ej(this,"handleSignupClick",()=>{var e;let t=null===(e=this.props.location.state)||void 0===e?void 0:e.attributionLabel;(0,ew.nP)("mweb_facebook_social_upsell.signup_button_click"),this.props.history.push({pathname:"/",state:{from:this.props.location.pathname,next:this.props.location.pathname,attributionLabel:t}})}),ej(this,"initializeShowAnimation",()=>{(0,ew.nP)("mweb_facebook_social_upsell.shown"),this.slideInAnimation=window.requestAnimationFrame(()=>{setTimeout(()=>{this.setState({visible:!0})},1e3)})})}componentDidMount(){(0,ew.nP)("mweb_facebook_social_upsell.land");let{invite:e}=this.props,t=e?e.invite_channel:null;t&&(0,ew.nP)(`mweb_social_unauth.invite_channel.${t}`),this.initializeShowAnimation()}componentWillUnmount(){window.cancelAnimationFrame(this.slideInAnimation)}renderDefaultLoginHeader(){return(0,L.jsxs)(P.xu,{flex:"grow",display:"flex",alignItems:"center",marginBottom:2,justifyContent:"center",children:[(0,L.jsxs)(P.xu,{alignItems:"center",display:"flex",direction:"column",marginBottom:5,children:[(0,L.jsx)(P.xu,{children:(0,L.jsx)(P.xv,{align:"start",weight:"bold",children:(0,L.jsx)("span",{className:"deprecatedTextSizeXL",children:this.props.i18n._('Sign up to see more', 'Title on mobile web signup modal to prompt users to signup for Pinterest.', 'Title on mobile web signup modal to prompt users to signup for Pinterest.')})})}),(0,L.jsx)(P.xu,{marginBottom:1}),(0,L.jsx)(P.kC,{alignItems:"center",direction:"column",justifyContent:"start",children:(0,L.jsx)(P.xv,{align:"start",children:this.props.i18n._('Free, unlimited access to ideas', 'First value prop on mobile web sign up modal', 'First value prop on mobile web sign up modal')})})]}),(0,L.jsx)(P.iz,{})]})}renderInviterHeader(){return(0,L.jsxs)(P.xu,{flex:"grow",display:"flex",alignItems:"center",marginBottom:2,children:[(0,L.jsxs)(P.xu,{alignItems:"center",direction:"row",display:"flex",paddingY:3,children:[(0,L.jsx)(P.xu,{children:(0,L.jsx)(P.xv,{align:"start",weight:"bold",children:(0,L.jsx)("span",{className:"deprecatedTextSizeXL",children:this.getTitle()})})}),(0,L.jsx)(P.xu,{dangerouslySetInlineStyle:{__style:{marginLeft:"26%"}},children:this.getAvatar()})]}),(0,L.jsx)(P.iz,{})]})}render(){var e;let{location:t,invite:i,checkExperiment:n}=this.props,{visible:o,hiding:l,showWash:s}=this.state,a=eb.ZEf,r=i?i.sender:null,d=o&&!l?eS.visible:eS.hiding;return(0,L.jsxs)(P.xu,{dangerouslySetInlineStyle:{__style:s?eS.wash:{}},children:[o&&!l?(0,L.jsx)(ef.Z,{onTouch:this.handleHideOutsideTap,pressState:"none",children:(0,L.jsx)(P.xu,{position:"fixed",top:!0,left:!0,opacity:1,dangerouslySetInlineStyle:{__style:eS.mask.baseStyles}})}):null,(0,L.jsx)(P.xu,{position:"fixed",bottom:!0,color:"default",paddingX:6,width:"100%",zIndex:new P.Ry(10001),dangerouslySetInlineStyle:{__style:{...d,boxShadow:"0 1px 5px 0 rgba(0,0,0,0.25)",paddingBottom:"5%",paddingTop:"2%",touchAction:"none"}},children:(0,L.jsxs)(P.xu,{maxWidth:400,marginStart:"auto",marginEnd:"auto",children:[(0,L.jsx)(P.xu,{paddingY:2}),(0,L.jsx)(P.xu,{position:"absolute",left:!0,top:!0,marginStart:4,marginTop:2,children:(0,L.jsx)(P.hU,{accessibilityLabel:this.props.i18n._('Close modal', 'Close the modal for facebook upsell', 'Close the modal for facebook upsell'),icon:"cancel",onClick:this.handleHide,size:"sm",iconColor:"gray"})}),(0,L.jsx)(P.xu,{paddingY:2}),r?this.renderInviterHeader():this.renderDefaultLoginHeader(),(0,L.jsx)(P.xu,{marginBottom:1,height:40,children:(0,L.jsx)(ey.Z,{facebook:!n("mweb_unauth_remove_fb_signup_iteration").anyEnabled,from:t.pathname,next:t.pathname,fbConnectHandler:this.handleFBConnect,attributionLabel:null===(e=t.state)||void 0===e?void 0:e.attributionLabel})}),(0,L.jsx)(P.xu,{marginBottom:1,marginTop:2,children:(0,L.jsx)(P.zx,{fullWidth:!0,onClick:this.handleSignupClick,color:"gray",text:this.props.i18n._('Sign Up', 'Button to redirect user to Signup Page on mweb', 'Button to redirect user to Signup Page on mweb')})}),(0,L.jsx)(P.xu,{marginTop:3,children:(0,L.jsx)(P.xv,{color:"subtle",align:"center",size:"100",children:(0,ex.nk)(this.props.i18n._('Have an account? {{ logIn }}', 'Asking users if they already have an account', 'Asking users if they already have an account'),{logIn:(0,L.jsx)(P.rU,{href:a,display:"inlineBlock",onClick:({dangerouslyDisableOnNavigation:e})=>e(),underline:"hover",children:(0,L.jsx)(P.xv,{color:"subtle",inline:!0,size:"100",weight:"bold",children:this.props.i18n._('Log in', 'Mobile web link to log in page', 'Mobile web link to log in page')})})})})}),(0,L.jsx)(P.xu,{marginTop:3,children:(0,L.jsx)(ev.Z,{size:"xs"})})]})})]})}}function ek(e){let t=(0,l.useHistory)(),i=(0,l.useLocation)(),n=(0,z.ZP)(),{checkExperiment:o}=(0,h.F)();return(0,L.jsx)(eP,{...e,history:t,i18n:n,location:i,checkExperiment:o})}var eA=i(999023),eC=i(430322);let ez=({children:e,isOpen:t,onDismiss:i,type:n})=>(0,L.jsx)(eC.default,{accessibilityModalLabel:"",mobileAllowScroll:!0,mobileHideCloseIcon:!0,isOpen:t,onDismiss:i,type:n,mobileIsFooter:!0,children:(0,L.jsx)(P.xu,{padding:4,children:e})});var eZ=i(10693);class eI extends n.PureComponent{constructor(...e){var t,i,n;super(...e),t="handleJoinBoardClick",i=({event:e})=>{e.stopPropagation();let{history:t,socialCollabGroupBoardPath:i}=this.props;(0,ew.nP)("mweb.social.group_board.public.modal.display"),t.push({pathname:"/signup/step1/",state:{next:i||"",isFromGroupBoardsInvite:!0}})},(t="symbol"==typeof(n=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"))?n:String(n))in this?Object.defineProperty(this,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):this[t]=i}componentDidMount(){let{inviteObject:e}=this.props,t=e?e.invite_channel:null;(0,ew.nP)("mweb.social.group_board.public.modal.display"),t&&(0,ew.nP)(`mweb.social.group_board.public.invite_channel.${t}`)}render(){let{viewType:e,viewParameter:t,inviteObject:i,board:n}=this.props,o=i?i.sender:null,l=o?o.first_name:"",s=o?o.image_medium_url:"",a=o?o.full_name:"",r=l?(this.props.i18n._('{{ name }} invited you to join their board', 'Mobile Modal prompting users to join a friends({{ name }}) board', 'Mobile Modal prompting users to join a friends({{ name }}) board')).replace("{{ name }}",l):this.props.i18n._('Your friends invited you to join their board', 'Mobile Modal prompting users to join a friends board', 'Mobile Modal prompting users to join a friends board'),d=this.props.i18n._('Join board', 'Join Board Button', 'Join Board Button');return(0,L.jsx)(eA.Z,{viewType:e||202,viewParameter:t,component:13196,children:(0,L.jsx)(ez,{isOpen:!0,onDismiss:()=>{},type:"groupboard_join",children:n?(0,L.jsxs)(P.xu,{padding:3,children:[(0,L.jsxs)(P.xu,{children:[(0,L.jsxs)(P.kC,{alignItems:"center",direction:"row",justifyContent:"start",children:[(0,L.jsx)(P.xu,{dangerouslySetInlineStyle:{__style:{marginRight:"5%"}},width:"48px",children:(0,L.jsx)(em.qE,{src:s||"",name:a||""})}),(0,L.jsx)(P.xu,{maxWidth:"74%",children:(0,L.jsx)(P.xv,{align:"start",overflow:"normal",weight:"bold",children:r})})]}),(0,L.jsx)(P.xu,{marginBottom:4})]}),(0,L.jsx)(P.zx,{fullWidth:!0,text:d,color:"red",type:"button",onClick:this.handleJoinBoardClick})]}):(0,L.jsx)(P.xu,{padding:3,children:(0,L.jsx)(P.$j,{show:!0,accessibilityLabel:this.props.i18n._('Loading Board', 'Accessiblity label for Spinner searching for board', 'Accessiblity label for Spinner searching for board')})})})})}}function eT({inviteObject:e,socialCollabGroupBoardPath:t}){let i=(0,z.ZP)(),n=(0,l.useHistory)(),{country:s}=(0,_.B)(),{viewType:a,viewParameter:r}=(0,ei.SU)(),d=t&&t.split("?")[0]||"",c=(0,o.useSelector)(e=>(0,eZ.Z)(e)[d]);return(0,L.jsx)(eI,{board:c,country:s,history:n,i18n:i,inviteObject:e,socialCollabGroupBoardPath:t,viewParameter:r,viewType:a})}var eE=i(112690),eL=i(994999),eB=i(248975),eM=i(52022),eO=i(81072),eR=i(594353),eD=i(872482),eF=i(350118);function eN({children:e}){let{checkExperiment:t}=(0,h.F)();return t("pcons_ideal_floating_upsell").anyEnabled?(0,L.jsx)(eo.Z,{componentType:14156,app_upsell_type:"unauth-floating-upsell",children:({handleOpenApp:t})=>(0,L.jsx)(P.iP,{onTap:()=>{(0,f.My)("pcons_floating_redesign_click"),t()},children:e})}):e}var eU=i(893101);let eH=new P.Ry(1e4),eW=()=>{let e=(0,l.useLocation)(),t=(0,l.useParams)(),{countryFromIp:i,isBot:n,userAgent:{isMobile:s}}=(0,_.B)(),a=(0,eF.S6)(),r=t.id?a(t.id):void 0;return(0,o.useSelector)(t=>{var o,l,d,c;let u=(0,eZ.Z)(t)[e.pathname],p=null==u?void 0:null===(o=u.cover_pin)||void 0===o?void 0:o.pin_id,h=p&&r&&a(p),_=r||h,{session:{isSocialBot:g}}=t,m=(0,eR.Z)(i||"",n||g,!s)&&["Dialup","Cellular"].includes(null==_?void 0:null===(l=_.pinner)||void 0===l?void 0:l.connection_type),x=(0,eB.Z)({imagesUrls:null!=_&&_.images?Object.keys(_.images).reduce((e,t)=>{var i,n;return t&&null!==(i=_.images)&&void 0!==i&&null!==(n=i[t])&&void 0!==n&&n.url?{...e,[t]:_.images[t].url}:e},{}):void 0,embedSrc:null==_?void 0:null===(d=_.embed)||void 0===d?void 0:d.src,embedType:null==_?void 0:null===(c=_.embed)||void 0===c?void 0:c.type,preferredResolution:m&&"236x"||"736x",excludeOriginals:!n&&!g})||u&&u.image_cover_url||"";return x?{color:(_||{}).dominant_color,src:x}:null})},e$=({onDismiss:e})=>{let t=(0,z.ZP)(),{viewType:i,viewParameter:o}=(0,ei.SU)(),l=(0,S.dc)(),s=eW(),a=(0,eE.Z)(),r=(0,eM.Z)(),{checkExperiment:d}=(0,h.F)(),c=(0,v.Wb)(),u=!c&&d("pcons_ideal_floating_upsell").anyEnabled;return(0,L.jsxs)(n.Fragment,{children:[(0,L.jsx)(P.xu,{alignSelf:u?void 0:"end","data-test-id":"cancel-button",display:"flex",dangerouslySetInlineStyle:{__style:{flexGrow:u?0:void 0}},children:(0,L.jsx)(P.hU,{accessibilityLabel:t._('Cancel', 'unauth.mweb.floating_app_modal.cancel_button', 'Cancel IconButton on the floating app install modal prompting the users to download the app'),icon:"cancel",onClick:({event:t})=>{(0,f.tj)("mweb_unauth.float_app_upsell.dismiss_tap",{x:(null==t?void 0:t.pageX)||-1,y:(null==t?void 0:t.pageY)||-1}),(0,f.My)(`pcons_dismiss_floating_app_upsell_after_${l}_rp_clicks`),(0,f.NC)("click_dismiss_float_app_upsell"),a({component:14156,element:75,event_type:102,view_type:i,view_parameter:o}),r({action:"click",item:"cancel-button",within:"unauth-floating-upsell"}),t.stopPropagation(),e()},size:"sm",iconColor:u?"darkGray":"gray"})}),(0,L.jsxs)(P.xu,{dangerouslySetInlineStyle:{__style:{flexGrow:u?1:void 0}},children:[(0,L.jsxs)(P.xu,{"data-test-id":"interest-image",display:"flex",margin:u?0:2,children:[u?(0,L.jsx)(P.xu,{dangerouslySetInlineStyle:{__style:{paddingRight:16}},children:eL.Z}):s&&(0,L.jsx)(P.xu,{minWidth:48,height:64,overflow:"hidden",rounding:2,marginEnd:4,children:(0,L.jsx)(P.Ee,{src:s.src,fit:"cover",naturalWidth:48,naturalHeight:64,color:s.color||"white",alt:"image"})}),(0,L.jsxs)(P.kC,{alignItems:"stretch",direction:"column",justifyContent:u?"center":"start",children:[(0,L.jsx)(P.xu,{children:(0,L.jsx)(P.xv,{weight:u?void 0:"bold",children:t._('Loving these ideas?', 'unauth.mweb.floating_app_modal.main_text', 'Top text on the floating app install modal prompting the users to download the app')})}),(0,L.jsx)(P.xv,{weight:u?"bold":void 0,children:u?t._('Get the app to see more', 'unauth.mweb.floating_app_modal.main_text.experimental', 'Top text on the floating app install modal prompting the users to download the app'):t._('Get the free Pinterest app to see more', 'unauth.mweb.floating_app_modal.main_text', 'Top text on the floating app install modal prompting the users to download the app')})]})]}),!c&&!d("pcons_ideal_floating_upsell").anyEnabled&&(0,L.jsx)(P.xu,{alignItems:"center",alignSelf:"center","data-test-id":"download-button",display:"flex",direction:"row",justifyContent:"center",marginBottom:3,marginStart:4,marginEnd:4,wrap:!0,children:(0,L.jsx)(eo.Z,{componentType:14156,app_upsell_type:"unauth-floating-upsell",children:({handleOpenApp:e})=>(0,L.jsx)(P.zx,{color:"red",onClick:()=>{(0,f.My)(`pcons_download_floating_app_upsell_after_${l}_rp_clicks`),e()},size:"md",text:t._('Download app', 'unauth.mweb.floating_app_modal', 'CTA on the app upsell modal')})})})]})]})},eG=()=>{var e;let t=(0,z.ZP)(),i=(0,l.useLocation)(),{checkExperiment:o}=(0,h.F)();return(0,L.jsxs)(P.xu,{alignItems:"center",direction:"column",display:"flex",paddingX:2,paddingY:4,children:[(0,L.jsx)(P.xu,{flex:"grow",children:(0,L.jsxs)(P.xu,{marginBottom:6,children:[(0,L.jsx)(P.xu,{marginBottom:2,children:(0,L.jsx)(P.X6,{overflow:"normal",size:"400",align:"center",children:t._('You are signed out', 'Heading on the bottom right upsell suggesting user is not signed in', 'Heading on the bottom right upsell suggesting user is not signed in')})}),(0,L.jsx)(P.xv,{overflow:"normal",align:"center",children:t._('Sign in to get the best experience', 'Subheader value prop on the bottom right upsell', 'Subheader value prop on the bottom right upsell')})]})}),(0,L.jsxs)(n.Fragment,{children:[(0,L.jsx)(ey.Z,{facebook:!o("mweb_unauth_remove_fb_signup_iteration").anyEnabled,google:!0,line:!0,showEmailButton:!0,next:(0,S.Yy)(i),attributionLabel:null===(e=i.state)||void 0===e?void 0:e.attributionLabel}),(0,L.jsx)(P.xu,{paddingX:6,marginTop:-3,children:(0,L.jsx)(ev.Z,{})})]})]})};function eY({onDismiss:e}){let{checkExperiment:t}=(0,h.F)(),i=(0,eM.Z)(),o=(0,eD.a)(),s=!!(null!=o&&o.hasScrolledPastMainContent),a=!!(null!=o&&o.hasDraggedDrawerToFullScreen),r=(0,v.Wb)(),d=(0,l.useLocation)(),c=(0,eO.Z)(),[u,p]=(0,n.useState)(!1),{viewType:_,viewParameter:g}=(0,ei.SU)(),m=(t("mweb_better_related_pins_drawer").group||"").includes("draggable"),x=!r&&t("pcons_ideal_floating_upsell").anyEnabled,b=t("pcons_ideal_floating_upsell").group,f=(0,n.useRef)(c);return(0,n.useEffect)(()=>{let e=t("pcons_ideal_floating_upsell").group;!r&&(e.includes("delay_01")||"enabled_bottom"===e)?(p(s&&c>f.current),f.current=c):!r&&e.includes("delay_04")?(p(c>700&&c>f.current),f.current=c):!r&&e.includes("delay_14")?(p(c>2450&&c>f.current),f.current=c):t("pcons_ideal_floating_upsell").anyEnabled?c>200?p(!0):r&&p(!1):p(s||m&&a)},[c,r,s,m,a,t]),(0,n.useEffect)(()=>{i({action:"trigger",item:u?"show-floating-app-upsell":"hide-floating-app-upsell"})},[u,d,i]),(0,L.jsx)(eA.Z,{viewType:_||202,viewParameter:g,component:13130,children:(0,L.jsx)(eN,{children:(0,L.jsx)(P.xu,{borderStyle:"shadow","data-test-id":"floating-app-upsell",rounding:r?6:t("pcons_ideal_floating_upsell").anyEnabled?4:8,padding:r||x?4:2,display:"flex",direction:"column",top:!(r||t("pcons_ideal_floating_upsell").group.includes("bottom")),bottom:r||t("pcons_ideal_floating_upsell").group.includes("bottom"),left:!r,right:!0,marginStart:r?0:t("pcons_ideal_floating_upsell").anyEnabled?4:"auto",marginEnd:r?4:t("pcons_ideal_floating_upsell").anyEnabled?4:"auto",maxWidth:r?350:x?void 0:360,maxHeight:x?96:void 0,justifyContent:r?"center":void 0,alignItems:r?"center":void 0,color:"default",opacity:1,zIndex:!r&&t("pcons_ideal_floating_upsell").group.includes("bottom")?new P.Ry(2):eH,dangerouslySetInlineStyle:{__style:{marginTop:x?16:void 0,transition:"transform 225ms ease-in-out",transform:!r&&t("pcons_ideal_floating_upsell").group.includes("bottom")?`translateY(${u?"-84px":"120%"})`:`translateY(${u?!r&&b.includes("top_offset")?66:0:r?145:-120}%)`,marginBottom:r?84:void 0,paddingRight:x?"8px":void 0,flexDirection:x?"row-reverse":void 0}},position:"fixed",children:r?(0,L.jsx)(eG,{}):(0,L.jsx)(e$,{onDismiss:e})})})})}function eK({setShouldShowAppUpsellFooter:e}){let{viewType:t,viewParameter:i}=(0,ei.SU)(),[o,l]=(0,n.useState)(!1),s=(0,eU.Z)(),a=(0,v.Wb)(),{checkExperiment:r}=(0,h.F)();return(0,L.jsx)(eA.Z,{viewType:t||202,viewParameter:i,component:13198,children:(0,L.jsx)(P.xu,{children:s&&!o&&(0,L.jsx)(eY,{onDismiss:()=>{l(!0),!a&&r("pcons_footer_after_dismiss").anyEnabled&&e&&e()}})})})}var eX=i(143892);let eq=[5,18,17,6,19],eJ=(0,n.lazy)(()=>Promise.all([i.e(721),i.e(86560)]).then(i.bind(i,500721))),eV=()=>{let e=eg(),t=(0,v.ZP)(),i=(0,m.l)();if(!i||!i.modal.isShown)return null;let{dismissMobileSignupModal:n,modal:{displayProps:o,pinId:l}}=i;return(0,L.jsx)(c.Z,{name:"SafeSuspense_UnauthPageWrapper_SignupModal",children:(0,L.jsx)(g.Z,{fallback:(0,L.jsx)(P.xu,{}),children:(0,L.jsx)(eJ,{displayProps:o,isTablet:"tablet"===t,onDismiss:()=>{n(),e()},pinId:l})})})},eQ=()=>{let e=(0,en.vE)(),t=(0,l.useLocation)(),[i]=(0,n.useState)(t),o=t===i&&(0,p.Fw)(t)||null,[s,a]=(0,n.useState)(null);return(0,w.Z)(()=>{e&&o&&et.Z.create("InviteCodeMetadataResource",{invite_code:e}).callGet().then(e=>{var t;return a(null!==(t=e.resource_response.data)&&void 0!==t?t:null)}).catch(()=>{})}),e&&o?{invite:s,pageType:o}:null};function e0(){let e=(0,l.useLocation)(),t=eQ(),i=(0,o.useDispatch)(),s=(0,ec.Z)(),a=(0,o.useSelector)(({session:e})=>e.unauthInterstitialDismissed),r=(0,eX.Z)(),[d,u]=(0,n.useState)(!1),p=(0,m.l)(),[_,x]=(0,n.useState)(!1),b=!!(null!=p&&p.modal.isShown),{viewType:f}=(0,ei.SU)(),{checkExperiment:y}=(0,h.F)();(0,n.useEffect)(()=>{b&&(x(!0),i((0,ee.W)()))},[b,i]);let v=b&&(0,L.jsx)(eV,{});if(!v&&t&&t.invite){var w;let{invite:i,pageType:n}=t;"board"===n&&(null===(w=i.sender)||void 0===w?void 0:w.invite_category)===4?v=(0,L.jsx)(c.Z,{name:"SafeSuspense_UnauthPageWrapper_GroupBoardsJoinModal",children:(0,L.jsx)(g.Z,{children:(0,L.jsx)(eT,{inviteObject:i,socialCollabGroupBoardPath:`${e.pathname}${e.search}`})})}):eq.includes(i.invite_channel)&&!_&&(v=(0,L.jsx)(ek,{invite:i,onDismiss:()=>x(!0)}))}return(0,L.jsxs)(n.Fragment,{children:[r&&!a&&(0,L.jsx)(eK,{setShouldShowAppUpsellFooter:()=>u(!0)}),d&&s&&!y("mweb_unauth_remove_app_upsell_footer").anyEnabled&&(0,L.jsx)(eo.Z,{componentType:14158,app_upsell_type:"footer-button",children:({handleOpenApp:e})=>(0,L.jsx)(ed,{onOpenInApp:()=>e(),viewType:f})}),(0,L.jsx)(P.xu,{children:v})]})}var e1=i(675149),e2=i(911691),e3=i(3223),e8=i(161164);let e4=["CA","VA","CO","CT"];var e6=i(709113),e7=i(562647),e5=i(597897);let e9=(0,n.lazy)(()=>i.e(14259).then(i.bind(i,814259))),te=(0,n.lazy)(()=>i.e(48185).then(i.bind(i,848185))),tt=()=>{try{let{count:e,time:t}=JSON.parse((0,x.qn)(e6.SI));return"number"==typeof e&&"number"==typeof t?{count:e,time:t}:null}catch(e){return null}},ti=e=>{(0,x.Nh)(e6.SI,JSON.stringify(e))},tn=()=>{let e=(0,l.useLocation)(),t=(0,o.useDispatch)(),{logContextEvent:i}=(0,a.v)(),{isBot:n,userAgent:{raw:c}}=(0,_.B)();(0,w.Z)(()=>{let o=e.search||"";if(o.includes("amp_client_id")&&(0,f.My)("amp_duplo_redirect"),!n){t((0,u.pz)([1000180],n)),(0,S.Yi)().then(e=>{t((0,ee.iW)(e))},()=>{t((0,ee.iW)())});let e=tt();e&&!(e.count<1)&&e.time?new Date().getTime()-e.time>6e5&&ti(e={...e,count:e.count+1}):ti(e={count:1,time:0}),i({event_type:7686,view_type:51,aux_data:{unauth_revisitation:e.count,unauth_previously_logged_out:r.U2(d.e7)}}),window.addEventListener("unload",()=>{var e,t;ti({count:null!==(e=null===(t=tt())||void 0===t?void 0:t.count)&&void 0!==e?e:1,time:new Date().getTime()})})}(0,s.$K)(c)&&(0,b.Nh)("openUnauthType",j.zu)})};function to(){let e=(0,v.HG)(),t=(0,l.useLocation)(),i=(0,e5.U)(),{checkExperiment:o}=(0,h.F)(),[s,a]=(0,n.useState)(!1),[r,d]=(0,n.useState)(!1);(0,n.useEffect)(()=>{i&&setTimeout(()=>{var e;null===(e=i.preload)||void 0===e||e.call(i,(0,e7.ke)("login.js"))},500)},[]);let{referrerFromCookie:u,userAgent:x}=(0,_.B)(),b=(0,m.l)(),w=t&&t.search?(0,y.mB)(t.search):"",j=!!w&&"1"===w.ur,S=(0,n.useRef)(!1);return(0,n.useEffect)(()=>{!S.current&&j&&(0,X.C)(t),S.current=j,"GSA"===x.browserName&&"ios"===x.platform?(0,f.My)("pcons.gsa_and_ios_session.platform"):"GSA"===x.browserName&&"iOS"===x.osName&&(0,f.My)("pcons.gsa_and_ios_session.osName");let e="GSA"===x.browserName,i="ios"===x.platform&&"iOS"===x.osName,n=e&&i;d(n&&o("pcons_measure_gsa_ios_disable").group.includes("autologin")),a(n&&o("pcons_measure_gsa_ios_disable").group.includes("one_tap"))},[j,x.browserName,x.platform,x.osName,o,t]),(0,n.useEffect)(()=>{(0,f.My)("mweb.unauth_seo.referrer",{referrer:u,docReferrer:document.referrer})},[u]),!function(){let{country:e,countryFromHostName:t,countryFromIp:i,isBot:o,regionFromIp:l,unauthId:s}=(0,_.B)(),a=new Set(e2.Z),r=a.has(e)||a.has(t)||a.has(i),d=e4.includes(l),c=eb.nBl.includes(l),u="undefined"!=typeof window&&!!window.navigator&&!!window.navigator.globalPrivacyControl&&window.navigator.globalPrivacyControl;(0,n.useEffect)(()=>{r||d||u&&c||((0,e3.NR)({country:e,isBot:o})&&(0,e8.kQ)({unauthId:s}),(0,e3.c_)({country:e,isBot:o})&&(0,e8.X)({id:e1.Un,eventName:"Mobile"}),(0,e3.$r)({country:e,regionFromIp:l,isBot:o})&&(0,e8.Kv)({id:"flashtalking-m-ses",eventName:"Mobile"}),(0,e3.Fc)({country:e,isBot:o})&&s&&(0,e8.o4)({unauthId:s}))},[e,r,s,o,l,d,c,u])}(),tn(),(0,L.jsxs)(n.Fragment,{children:[!(0,p.re)(t)&&!(0,p.FO)(t)&&(0,L.jsx)(c.Z,{name:"SafeSuspense_UnauthPageWrapper_AutoLogin",children:(0,L.jsx)(g.Z,{children:(0,L.jsx)(e9,{})})}),!s&&(0,L.jsx)(c.Z,{name:"SafeSuspense_UnauthPageWrapper_GoogleOneTap",children:(0,L.jsx)(g.Z,{children:(0,L.jsx)(te,{disableGoogleAutologinExp:r})})}),(0,L.jsx)(F,{}),!e&&(0,L.jsx)(e0,{}),b&&(0,L.jsx)(Q,{context:b})]})}},503347:(e,t,i)=>{i.r(t),i.d(t,{default:()=>N});var n=i(616550),o=i(883119),l=i(385740),s=i(53987),a=i(50286),r=i(348584),d=i(913351),c=i(510020),u=i(553342),p=i(702664),h=i(112690),_=i(643010),g=i(966476);let m=()=>{let e=(0,p.useSelector)(e=>{var t;return!!(null!=e&&null!==(t=e.session)&&void 0!==t&&t.isSeoBot)}),t=(0,g.Z)();return!e&&!t},x=({children:e,fallback:t})=>m()?t||null:e;var b=i(413764),f=i(898781),y=i(773285),v=i(780280),w=i(52022),j=i(101331),S=i(501338),P=i(598615),k=i(938917),A=i(948376),C=i(867820),z=i(893101),Z=i(785893);function I(){let e=(0,f.ZP)(),t=(0,n.useLocation)(),i=(0,n.useHistory)(),{viewType:a,viewParameter:r}=(0,l.SU)(),{userAgentPlatform:d,userAgent:c}=(0,p.useSelector)(({session:e})=>e),{isBot:u}=(0,v.B)(),g=(0,A.Rp)({isBot:u,platform:d,userAgent:c}),m=(0,z.Z)(),I=function(){let{isBot:e}=(0,v.B)();return(t,i)=>{e||(0,C.NC)(t,i)}}(),T=(0,k.Z)(),{checkExperiment:E}=(0,y.F)(),L=(0,h.Z)(),B=(0,w.Z)(),{trackConversionUpsell:M}=(0,j.Z)(),O=E("pcons_mweb_sign_in_copy").anyEnabled?e._('Sign in', 'unauth.sign_in.text', 'Label for sign in button'):e._('Log in', 'Label for log in button', 'Label for log in button'),R=e._('Sign up', 'Text on button on the top bar that leads users to signing up.', 'Text on button on the top bar that leads users to signing up.'),D=!g&&!(0,s.Xn)(t),F=((0,s.dr)(t)||(0,s.$Y)(t)||(0,s.E0)(t))&&!E("lex_follow_button").group.includes("main_cta"),N=!T||m||F?"signup":"download",U=E("mweb_unauth_login_primary_header").group,H=U.includes("login_primary"),W=!H&&U.includes("login"),$=e._('Download', 'mweb.unauth.interstitial_upsell.download_button_text', 'CTA on the app interstitial upsell to install the app'),G=(D?O.length:0)+("signup"===N?R.length:0)+("download"===N?$.length:0),Y=(0,Z.jsx)(o.zx,{fullWidth:!0,color:H?"white":F?"red":"gray",onClick:()=>{B({action:"click",within:"unauth-header",item:"signup-button"}),L({component:13198,element:31,event_type:102,view_type:a,view_parameter:r}),I("press_header_signup"),M({viewType:a,viewParameter:r,eventType:14688,component:14215,upsellReason:"click_signup_on_header"}),i.push({pathname:"/signup",state:{attributionLabel:"click_signup_on_header",...t.state}})},size:"md",text:R});return(0,Z.jsx)(o.xu,{dangerouslySetInlineStyle:{__style:{boxShadow:"0 1px 0 0 rgba(0, 0, 0, 0.08)",backgroundColor:(0,_.Yc)()?"#333":"white",transition:"all 225ms cubic-bezier(0.0,0.0,0.2,1) 500ms",transform:"translateY(0)"}},top:!0,left:!0,width:"100vw",position:"relative",paddingX:3,children:(0,Z.jsxs)(o.xu,{alignItems:"center","data-test-id":"unauth-header",direction:"row",display:"flex",justifyContent:"between",children:[(0,Z.jsx)(o.iP,{accessibilityLabel:e._('Pinterest App', 'Pinterest icon for app upsell', 'Pinterest icon for app upsell'),onTap:()=>{B({action:"click",within:"unauth-header",item:"pinterest-logo"})},children:(0,Z.jsxs)(o.xu,{alignItems:"center",display:"flex",direction:"row",marginEnd:3,children:[(0,Z.jsx)(o.xu,{alignItems:"center",display:"flex",height:S.SB,justifyContent:"center",rounding:2,"data-test-id":"pinterest-logo-icon",children:(0,Z.jsx)(o.Tg,{tapStyle:"none",href:"/",children:g?(0,Z.jsx)(b.Z,{size:24}):(0,Z.jsx)(o.hU,{icon:"pinterest",iconColor:"brandPrimary",padding:1,size:"xl",accessibilityLabel:e._('Pinterest App', 'Pinterest icon for app upsell', 'Pinterest icon for app upsell')})})}),(0,Z.jsx)(o.xu,{paddingY:2,paddingX:1,"data-test-id":"pinterest-logo-text",children:G<18&&(0,Z.jsxs)(o.xu,{children:[(0,Z.jsx)(o.X6,{color:"error",size:"400",overflow:"normal",children:g?e._('Pinterest Lite', 'Pinterest lite brand for the app upsell', 'Pinterest lite brand for the app upsell'):e._('Pinterest', 'Pinterest brand for the app upsell', 'Pinterest brand for the app upsell')}),g&&(0,Z.jsx)(o.xu,{dangerouslySetInlineStyle:{__style:{whiteSpace:"pre-wrap"}},children:(0,Z.jsx)(o.xu,{children:(0,Z.jsx)(o.xv,{inline:!0,size:"100",color:"subtle",children:e._('Save space on your device', 'Unauth app upsell copy that describe Pinterest product core value to users', 'Unauth app upsell copy that describe Pinterest product core value to users')})})})]})})]})}),(0,Z.jsx)(x,{children:(0,Z.jsxs)(o.xu,{marginEnd:0,flex:"none",alignItems:"center",display:"flex",direction:"row","data-test-id":"UnauthAppUpsellButton",children:["signup"===N&&H&&(0,Z.jsx)(o.xu,{"data-test-id":"signup-button",children:Y}),D&&(0,Z.jsx)(o.xu,{"data-test-id":"login-button",children:(0,Z.jsx)(o.zx,{fullWidth:!0,color:U.includes("red")&&"signup"===N?"red":U.includes("gray")&&"signup"===N?"gray":"white",onClick:()=>{B({action:"click",within:"unauth-header",item:"login-button"}),L({component:13198,element:30,event_type:102,view_type:a,view_parameter:r}),I("press_header_login"),M({viewType:a,viewParameter:r,eventType:14688,component:14213,upsellReason:"click_login_on_header"}),i.push({pathname:"/login",state:{attributionLabel:"click_login_on_header",...t.state}})},size:"md",text:O})}),"signup"!==N||W||H?"signup"!==N&&(0,Z.jsx)(o.xu,{"data-test-id":"download-button",children:(0,Z.jsx)(P.Z,{componentType:14161,app_upsell_type:"unauth-header",children:({handleOpenApp:e})=>(0,Z.jsx)(o.zx,{fullWidth:!0,color:(0,s.j8)(t)||E("lex_follow_button").group.includes("main_cta")?"gray":"red",onClick:()=>{e()},size:"md",text:$})})}):(0,Z.jsx)(o.xu,{"data-test-id":"signup-button",children:Y})]})})]})})}var T=i(143892);let E=new o.Ry(5),L=new o.Ry(1),B={signup:{attributionLabel:"click_signup_on_header",signupFlow:{type:"signup"},source:"defaultSource"},login:{attributionLabel:"click_login_on_header",signupFlow:{type:"login"},source:"login"}},M=e=>(0,s.mP)(e)||(0,s.hd)(e),O=e=>(0,s.Ni)(e)||(0,s.Xn)(e)||(0,s.C$)(e)||"/invited/"===e.pathname,R=e=>e.pathname.includes("_created")||e.pathname.includes("boards")&&!(0,s.En)(e)||e.pathname.includes("_saved"),D=e=>(0,s.mP)(e),F=({deviceType:e})=>{let t=(0,n.useLocation)(),i=(0,r.Z)(),a=(0,T.Z)(),p=(0,c.n)(),{viewParameter:h,viewType:_}=(0,l.SU)(),g=(0,Z.jsxs)(o.xu,{color:"default",children:["tablet"===e?!(0,s.En)(t)&&!(0,s.Xn)(t)&&(0,Z.jsx)(u.Z,{}):a&&!R(t)&&!i&&(0,Z.jsx)(I,{})," "]});return p.showReferredAppUpsell?(0,Z.jsx)(d.Z,{onDismiss:()=>p.setShowReferredAppUpsellVal(!1),viewParameter:h,viewType:_}):D(t)?(0,Z.jsx)(o.xu,{zIndex:E,position:"fixed",width:"100%",children:g}):(0,Z.jsx)(o.Le,{top:0,zIndex:E,children:g})};function N({showDesktopSignupModal:e}){let t=(0,a.ZP)(),i=(0,n.useLocation)();if("desktop"===t){let t=(0,Z.jsx)(u.Z,{showDesktopSignupModal:e&&(t=>e({signupFlow:B[t].signupFlow,attributionLabel:B[t].attributionLabel,source:B[t].source,container:"unauth_header",reason:"CLICK_LOGIN_OR_SIGNUP"}))});return M(i)?(0,Z.jsx)(o.xu,{width:"100%",position:"fixed",zIndex:L,children:t}):!O(i)&&t}return(0,Z.jsx)(F,{deviceType:t})}},999023:(e,t,i)=>{i.d(t,{Z:()=>r});var n=i(667294),o=i(112690),l=i(867820);let s=e=>Object.keys(e).reduce((t,i)=>(void 0===e[i]&&delete t[i],t),{...e}),a=({viewType:e,viewParameter:t,viewData:i,auxData:n,objectIdStr:o,component:a,clientTrackingParams:r,element:d},c)=>{let u=s({event_type:13,view_type:e,view_parameter:t,view_data:i,aux_data:n,object_id_str:o,component:a,clientTrackingParams:r,element:d});-1===Object.keys(u).indexOf("view_type")&&(0,l.My)("mweb.logging.null_view_type"),c(u)};function r(e){let{auxData:t,clientTrackingParams:i,children:l,component:s,element:r,objectIdStr:d,viewData:c,viewParameter:u,viewType:p}=e,h=(0,o.Z)(),_=JSON.stringify(t),g=JSON.stringify(c);return(0,n.useEffect)(()=>{a(e,h)},[h,_,i,s,r,d,g,u,p]),n.Children.only(l)}},598615:(e,t,i)=>{i.d(t,{B:()=>g,Z:()=>m});var n=i(667294),o=i(616550),l=i(407043),s=i(385740),a=i(53987),r=i(780280),d=i(867820),c=i(52022),u=i(938917),p=i(329900),h=i(67347),_=i(785893);let g=(e,t)=>"/"===e.pathname?"/":(0,a.am)(e)&&t?`board/${e.pathname.substr(1)}`:e.pathname.substr(1);function m({children:e,componentType:t,app_upsell_type:i}){let a=(0,o.useLocation)(),{flushContextEvents:m,logContextEvent:x}=(0,l.v)(),{viewType:b,viewParameter:f}=(0,s.SU)(),y=(0,c.Z)(),{userAgent:{platform:v}}=(0,r.B)();(0,n.useEffect)(()=>{y({action:"view",item:"download-button",within:i})},[a,i,y]);let w=(0,n.useRef)(!1);(0,n.useEffect)(()=>{b&&202!==b?(x({component:t||13106,element:10308,event_type:9976,view_type:b,view_parameter:f,aux_data:{app_upsell_type:i,app_upsell_is_dupe:w.current}}),w.current=!0):(0,h.nP)("webapp.track_app_upsell_viewed_invalid_parameters",{sampleRate:1,tags:{component:t,view_type:b,view_parameter:f,app_upsell_type:i,app_upsell_is_dupe:w.current}})},[t,x,f,b,i]);let j=(0,u.Z)();return(0,n.useEffect)(()=>{j||(0,d.My)(`mweb.app_upsell.forbidden_upsell.${i}`)},[j,i]),(0,_.jsx)(p.Z,{children:n=>e({handleOpenApp:e=>{if(y({action:"click",item:"download-button",within:i}),(0,d.NC)("press_open_app",!0),x({component:t||13106,element:10308,event_type:102,view_type:b||202,view_parameter:f,aux_data:{app_upsell_type:i}}),x({component:t||13106,element:10308,event_type:9977,view_type:b||202,view_parameter:f,aux_data:{app_upsell_type:i}}),m(!0),n){var o;x({component:t||13106,element:10308,event_type:1701,view_type:b||202,view_parameter:f,aux_data:{app_upsell_type:i}}),n(null!==(o=null==e?void 0:e.deepLinkUri)&&void 0!==o?o:g(a,"android"===v),i)}}})})}},664166:(e,t,i)=>{i.d(t,{Z:()=>u,y:()=>c});var n=i(667294),o=i(30287),l=i(844974),s=i(339363),a=i(807609),r=i(999023),d=i(785893);let c=()=>{(0,l.Nh)("appUpsell",Date.now()),(0,l.qn)("firstUpsellTime")||(0,l.Nh)("firstUpsellTime",Date.now()),(0,s.Nh)("showedAppUpsellCurrentSession",!0)};function u({children:e,clientTrackingParams:t,viewParameter:i,viewType:l}){let s=(0,a.Z)();return s||(0,o.FP)(window)?null:(0,d.jsx)(r.Z,{viewType:l,viewParameter:i,component:13106,clientTrackingParams:t,children:(0,d.jsx)(n.Fragment,{children:e})})}},938917:(e,t,i)=>{i.d(t,{Z:()=>o});var n=i(702664);let o=()=>(0,n.useSelector)(({session:{canUseNativeApp:e}})=>e)},207594:(e,t,i)=>{i.d(t,{N:()=>r,h:()=>d});var n=i(667294),o=i(780678),l=i(425288),s=i(785893);let{Provider:a,useHook:r}=(0,l.Z)("NativeAppInstalled");function d({children:e}){let[t,i]=(0,n.useState)(!1),[l,r]=(0,n.useState)(!1),d=(0,n.useCallback)(e=>{i(e)},[]),c=(0,n.useCallback)(e=>{r(e)},[]);(0,n.useEffect)(()=>{!async function(){let e=await (0,o.Z)();r(!0),e.length>0&&i(!0)}()},[]);let u=(0,n.useMemo)(()=>({isNativeAppInstalled:t,setIsNativeAppInstalledVal:d,isCheckComplete:l,setIsCheckCompleteVal:c}),[t,d,l,c]);return(0,s.jsx)(a,{value:u,children:e})}},510020:(e,t,i)=>{i.d(t,{P:()=>r,n:()=>a});var n=i(667294),o=i(425288),l=i(785893);let{Provider:s,useHook:a}=(0,o.Z)("ShowReferredAppUpsell");function r({children:e}){let[t,i]=(0,n.useState)(!1),[o,a]=(0,n.useState)(!1),[r,d]=(0,n.useState)("other"),[c,u]=(0,n.useState)(""),p=(0,n.useCallback)(e=>{i(e)},[]),h=(0,n.useCallback)(e=>{a(e)},[]),_=(0,n.useCallback)(e=>{d(e)},[]),g=(0,n.useCallback)(e=>{u(e)},[]),m=(0,n.useMemo)(()=>({showReferredAppUpsell:t,setShowReferredAppUpsellVal:p,isInlineUpsell:o,setIsInlineUpsellVal:h,appUpsellType:r,setAppUpsellTypeVal:_,uiType:c,setUiTypeVal:g}),[t,p,o,h,r,_,c,g]);return(0,l.jsx)(s,{value:m,children:e})}},948376:(e,t,i)=>{i.d(t,{G3:()=>c,Rp:()=>d,kp:()=>a});var n=i(202139),o=i(844974),l=i(339363);let s=14*n.F4,a=(e,t)=>{let i=function(){let e=Date.now(),t=Number((0,o.qn)("appUpsell")),i=Number((0,o.qn)("firstUpsellTime")),n=!!(0,l.qn)("showedAppUpsellCurrentSession");return{currentTime:e,firstUpsellTime:i,lastUpsellTime:t,showedAppUpsellCurrentSession:n}}();return e?function(e,t,i){let{currentTime:n,firstUpsellTime:l,lastUpsellTime:a,showedAppUpsellCurrentSession:r}=e;return(i=i||s,!l||n<l+t)?!r:n-a>i&&((0,o.L_)("firstUpsellTime"),!0)}(i,n.F4):function(e,t){let{currentTime:i,lastUpsellTime:n}=e;return t=t||s,!n||i-n>t}(i,t)},r=e=>{e=e.toLowerCase();let t=e.match(/android\s([0-9\.]*)/i);return t?t[1]:void 0},d=({isBot:e,platform:t,userAgent:i})=>{try{return!e&&"android"===t&&7>parseFloat(r(i))}catch(e){return!1}},c=e=>(e.startsWith("zh")||e.startsWith("ar")?e:e.slice(0,2)).toUpperCase()},421322:(e,t,i)=>{i.d(t,{Z:()=>l});var n=i(7893),o=i(867820);async function l(e){let t=await (0,n.Kw)(),i=t?{user_ids:Object.keys(t)}:{};(0,o.tj)(`mweb_multiple_accounts_${e}`,i)}},993723:(e,t,i)=>{i.d(t,{eN:()=>d,_:()=>u,kB:()=>c});var n=i(966113),o=i(826067),l=i(616550);let s=["/resource/:name/:method/","/resource/commerce/:name/:method/","/:username/pins/follow/","/email/remove/","/about/trademark/form/:claim_type/","/about/copyright/dmca-pin/web-result/:id/","/about/copyright/dmca-pin/pin/:id/","/about/copyright/dmca-pin/","/about/koplg/","/about/:lawName/","/about/radtc/","/website/confirm/","/oauth/","/app-factory-oauth/","/settings/extension/uninstall/","/offsite/","/amp/(.*)"],a=(e,t)=>{let i=new URL(e,t);return s.some(e=>!!(0,l.matchPath)(i.pathname,{path:e,exact:!0}))};var r=i(67347);let d=e=>e&&(0,o.Qg)(e)&&n.lfe!==e?(0,o.Qc)(e).relative:"/",c=(e,t)=>{let i=(0,o.Jx)(e);return a(i,t)||(0,o.OM)(i)===o.vx.TRUSTED_DIFFERENT_ORIGIN},u=({forceFullPageNavigation:e,history:t,next:i,noLocationReplace:n,origin:l})=>{let s=(0,o.Jx)(i);c(i,l)||!t||e?(e&&(0,r.nP)("webapp.duplo.navigateOnLogin.forceFullPageNavigation",{sampleRate:1}),window.location.assign(s)):n?t.push(d(s)):t.replace(d(s))}},412544:(e,t,i)=>{i.d(t,{Z:()=>l});var n=i(616550);let o=Object.freeze({"/:username":"profile","/:username/:slug/:section_slug":"board","/:username/:slug":"board","/csrf_error":"csrfError","/email_verification_error":"emailVerificationError","/email/remove":"emailRemove","/email/subscription":"emailSubscription","/ideas":"ideasRoot","/ideas/:interest/:id":"ideasHub","/invited":"invited","/password/reset":"passwordReset","/pin/:id":"pin","/pin/:id/feedback":"pinFeedBack","/pin/:id/sent":"pinFeedBack","/pin/:id/visual-search":"flashlight","/pin/create/:method":"pinBookmarklet","/pw/:username":"resetPasswordUsername","/panic/":"panic","/search/:scope":"search","/shopping":"shoppingRoot","/shopping/:category/:id":"shoppingCategory","/today":"todayTab","/today/:term/:title/:articleId":"todayArticleFeed","/today/popular/:interest/:interestId":"todayArticleInterestFeed","/tv":"LiveSessionEvent","/tv/:pin_id":"liveSessionCloseup","/unlink":"unlinkAccount","/videos":"videosRoot","/videos/:category/:id":"videosCategory"}),l=()=>{let{path:e}=(0,n.useRouteMatch)();return o[e]||"unknown"}},364034:(e,t,i)=>{i.d(t,{$:()=>a,Z:()=>c});var n=i(667294),o=i(844974);let l=e=>{if(!e)return null;try{return JSON.parse(e)}catch(e){return null}},s=new Set,a=2,r=e=>{var t;return null!==(t=null==e?void 0:e.pins)&&void 0!==t?t:[]},d=e=>e.length?{pins:e}:null,c=()=>{let[e,t]=function(e){let t=(0,n.useCallback)(t=>{let i=i=>{i===e&&t()};return s.add(i),()=>{s.delete(i)}},[e]),i=(0,n.useSyncExternalStore)(t,()=>(0,o.qn)(e),()=>null),a=(0,n.useCallback)(t=>{null===t?(0,o.L_)(e):(0,o.Nh)(e,JSON.stringify(t)),s.forEach(t=>t(e))},[e]);return(0,n.useMemo)(()=>[l(i),a],[i,a])}("unauthSavedPins"),i=r(e),c=e=>t(d(e)),u=()=>i.length<a;return{pins:i,save:e=>{u()&&c(i.filter(({id:t})=>t!==e.id).concat([e]))},unsave:e=>c(i.filter(({id:t})=>t!==e)),isSaved:e=>i.some(({id:t})=>t===e),clear:()=>c([]),canSaveMore:u}}},473138:(e,t,i)=>{i.d(t,{Z:()=>b,u:()=>m});var n=i(667294),o=i(616550),l=i(883119),s=i(56641),a=i(400964),r=i(499128),d=i(898781),c=i(844974),u=i(867820),p=i(343341),h=i(529195),_=i(275926),g=i(785893);let m="web_siwa_redirect_path",x="id_token=";function b(){let e=(0,d.ZP)(),t=(0,o.useLocation)(),i=(0,_.f)(),b=(0,o.useHistory)(),{showToast:f}=(0,p.F9)(),[y,v]=(0,n.useState)(!1),w=t.hash.indexOf(x),j=w>=0?t.hash.substring(w+x.length):null,S=(0,n.useRef)(null);return(0,n.useEffect)(()=>{let n=async n=>{(0,u.My)("in_app_oauth.login.siwa.returned_with_token"),v(!0),i({apple_token:n},b,t.pathname,{noImmediateRedirect:!0},{event_type:7534,view_type:10}).then(()=>{v(!1),(0,u.My)("in_app_oauth.login.siwa.login_success");let e=(0,c.qn)(m);(0,c.L_)(m),(0,s.Z)(e||"/")}).catch(()=>{v(!1),(0,u.My)("in_app_oauth.login.siwa.login_failure"),f(({hideToast:t})=>(0,g.jsx)(r.ZP,{text:e._('Oops! You do not have an account connected with Apple. Please try another method.', 'mweb.unauth.oauth_apple_login.login_failure_toast', 'Toast to alert user they failed to login with Apple'),onHide:t,type:"error"}))})};S.current!==j&&j&&n(j),S.current=j},[b,e,j,t,i,f]),y?(0,g.jsx)(l.$j,{accessibilityLabel:e._('Loading...', 'Loading', 'Loading'),show:!0}):(0,g.jsx)(l.iP,{onTap:()=>{var e;(0,u.My)("in_app_oauth.login.siwa_button.tapped");let i=(null===(e=t.state)||void 0===e?void 0:e.next)||(0,h.Yy)(t),n=i?decodeURIComponent(i):null;(0,c.Nh)(m,n),(0,s.Z)(`https://appleid.apple.com/auth/authorize?client_id=com.pinterest.signinwithapple&redirect_uri=${encodeURIComponent(window.location.origin.toString()+"/oauth/login")}&response_type=${encodeURIComponent("code id_token")}&response_mode=fragment`)},children:(0,g.jsxs)(l.xu,{height:40,width:"100%",display:"flex",alignItems:"center",color:"dark",rounding:"pill",paddingX:2,paddingY:1,children:[(0,g.jsx)(l.xu,{marginStart:-3,marginTop:-2,children:a.Z}),(0,g.jsx)(l.xu,{marginStart:"auto",marginEnd:"auto",children:(0,g.jsx)(l.xv,{weight:"bold",color:"light",children:e._('Continue with Apple', 'mweb.unauth.oauth_apple_login.login_button', 'Text on button allowing users to login with their Apple account')})})]})})}},368095:(e,t,i)=>{i.d(t,{Z:()=>d});var n=i(667294),o=i(883119),l=i(121151),s=i(898781),a=i(867820),r=i(785893);function d({onDismiss:e}){let t=(0,s.ZP)();(0,n.useEffect)(()=>{(0,a.My)("unauth_mweb.login_rate_limited.view")},[]);let i=t._('Oops! Too many login attempts', 'LoginRateLimitedModal.Modal.Heading', 'Modal heading for user who have tried to login too many times');return(0,r.jsxs)(l.ZP,{accessibilityModalLabel:i,onDismiss:e,heading:(0,r.jsxs)(o.xu,{"data-test-id":"login-rate-limited-header",children:[(0,r.jsx)(o.xu,{justifyContent:"center",display:"flex",padding:6,children:(0,r.jsx)(o.JO,{icon:"pinterest",accessibilityLabel:t._('Pinterest logo', 'Accessibility label for Pinterest icon', 'Accessibility label for Pinterest icon'),color:"brandPrimary",size:40})}),(0,r.jsx)(o.X6,{align:"center",size:"500",accessibilityLevel:1,children:i})]}),children:[(0,r.jsx)(o.xu,{paddingX:12,marginTop:4,marginBottom:8,"data-test-id":"login-rate-limited-text",children:(0,r.jsx)(o.xv,{align:"center",children:t._('You have reached the maximum number of login attempts. Try again in 30 minutes.', 'LoginRateLimitedModal.Modal.Heading', 'Modal heading for user who have tried to login too many times')})}),(0,r.jsx)(o.xu,{paddingX:12,marginBottom:8,"data-test-id":"login-rate-limited-footer",children:(0,r.jsx)(o.zx,{fullWidth:!0,color:"red",text:t._('Okay', 'LoginRateLimitedModal.Modal.OkButton', 'Okay button used to close modal'),onClick:e})})]})}},160561:(e,t,i)=>{i.d(t,{Z:()=>b});var n=i(667294),o=i(883119),l=i(711781),s=i(83969),a=i(524172),r=i(773285),d=i(780280),c=i(867820),u=i(898781),p=i(472644),h=i(348584),_=i(107287),g=i(785893);function m(){let e=(0,u.ZP)(),[t,i]=(0,n.useState)(),l=(0,h.Z)();return l?null:(0,g.jsxs)(o.xu,{position:"relative",children:[(0,g.jsx)(o.iP,{onTap:()=>i(!0),children:(0,g.jsxs)(o.xu,{position:"relative",display:"flex",alignItems:"center",justifyContent:"center",height:40,rounding:"pill",color:"secondary",children:[(0,g.jsx)(o.xu,{height:24,width:24,marginTop:1,children:(0,g.jsx)(p.Z,{size:20})}),(0,g.jsx)(o.xu,{marginStart:2,children:(0,g.jsx)(o.xv,{weight:"bold",children:e._('Connect with Google', 'googleConnectButtonWithDisabledSDK.buttonText', 'Connect with Google button text')})})]})}),t&&(0,g.jsx)(_.Z,{type:"google",onDismiss:()=>i(!1)})]})}function x({onGoogleConnectSuccess:e,onTouch:t}){let{locale:i}=(0,d.B)(),r=(0,n.useRef)(null),u=(0,a.M)(),p=(0,n.useRef)(e);return(0,n.useEffect)(()=>{p.current=e},[e]),(0,n.useEffect)(()=>{let e=({credential:e,select_by:t})=>{(0,c.My)(`unauth_mweb.gsi_button.select_by.${t}`),(0,c.NC)("press_google_connect_button");let i=(0,l.Z)(e);p.current({google_open_id_token:e,autologin:!1},{type:"google",google_open_id_token:e,first_name:i.given_name,last_name:i.family_name,image_url:i.picture})};return(async()=>{await (null==u?void 0:u.ensureInit("button",e)),(0,s.ru)({buttonRef:r,isDesktop:!1,locale:i})})(),()=>{null==u||u.removeButtonCallback(e)}},[u,i]),(0,g.jsx)(o.xu,{position:"relative",children:(0,g.jsx)(o.iP,{onTap:()=>{null==t||t(),(0,c.My)("gsi_personalized_button.tap"),(0,c.EX)({event:"start",provider:"google"})},children:(0,g.jsx)(o.xu,{"aria-label":"GOOGLE_SIGNIN_BUTTON",height:44,children:(0,g.jsx)(o.xu,{ref:r,position:"absolute",width:"100%"})})})})}function b({onGoogleConnectSuccess:e,onTouch:t}){let{checkExperiment:i}=(0,r.F)(),{anyEnabled:n}=i("mweb_google_disabled");return n?(0,g.jsx)(m,{}):(0,g.jsx)(x,{onGoogleConnectSuccess:e,onTouch:t})}},56390:(e,t,i)=>{i.d(t,{C:()=>r,P:()=>a});var n=i(53987),o=i(339363),l=i(67347);let s="msmrsfda",a=()=>!!(0,o.qn)(s),r=e=>{(0,n.LM)(e)&&!a()&&((0,o.Nh)(s,"1"),(0,l.nP)("mobile_signup_modal.rules.suppress_for_discover_article",{flushImmediate:!0,sampleRate:1}))}},477310:(e,t,i)=>{i.d(t,{Z:()=>y});var n=i(667294),o=i(883119),l=i(100183),s=i(391254);let a={yellow:"#FAB904",orange:"#FF6400",green:"#0FA573",blue:"#0074e8",purple:"#B469EB"},r="DelightfulBubbles__",d=(e,t)=>{let i=e.length,n=e.indexOf(t)+1>=i?0:e.indexOf(t)+1;return e[n]},c=`${r}fadeIn {
|
218
|
+
to {
|
219
|
+
opacity: 1;
|
220
|
+
}
|
221
|
+
}
|
222
|
+
`,u=`${r}growShrink {
|
223
|
+
0% {
|
224
|
+
transform: scale(0);
|
225
|
+
}
|
226
|
+
50% {
|
227
|
+
transform: scale(1);
|
228
|
+
}
|
229
|
+
100% {
|
230
|
+
transform: scale(0);
|
231
|
+
}
|
232
|
+
}
|
233
|
+
`,p=`${r}swirl {
|
234
|
+
0% {
|
235
|
+
transform: rotate(0deg) translateX(-50%);
|
236
|
+
}
|
237
|
+
100% {
|
238
|
+
transform: rotate(-360deg) translateX(-50%);
|
239
|
+
}
|
240
|
+
}
|
241
|
+
`,h=[c,u,p,...(()=>{let e=Object.keys(a).map(e=>{let t=d(Object.keys(a),e);return`${r}colorChange_${e} {
|
242
|
+
0% {
|
243
|
+
background-color: ${a[e]};
|
244
|
+
}
|
245
|
+
50% {
|
246
|
+
background-color: ${a[t]};
|
247
|
+
}
|
248
|
+
}
|
249
|
+
`});return e})()],_=(0,l.Ll)(h),g=(e,t,i,n,o,l,s,d)=>({bubblePositionStyles:{position:"absolute",marginLeft:`${l/2-o}px`,marginTop:`${i/2-o}px`,left:`${s}px`,top:`${d}px`},bubbleSwirlStyles:{animation:`${r}swirl 6s ease-in-out ${e}s infinite forwards`,WebkitAnimation:`${r}swirl 6s ease-in-out ${e}s infinite forwards`},bubbleGrowShrinkStyles:{transform:"scale(0)",WebkitTransform:"scale(0)",animation:`${r}growShrink 6s ease-in-out ${e}s infinite alternate`,WebkitAnimation:`${r}growShrink 6s ease-in-out ${e}s infinite alternate`},bubbleShapeStyles:{height:`${t}px`,width:`${t}px`,borderRadius:"50%",backgroundColor:a[n],opacity:0,animation:`${r}colorChange_${n} 12s steps(1, start) ${e}s infinite forwards,
|
250
|
+
${r}fadeIn 3s linear ${e}s 1 forwards`,WebkitAnimation:`${r}colorChange_${n} 12s steps(1, start) ${e}s infinite forwards,
|
251
|
+
${r}fadeIn 3s linear ${e}s 1 forwards`}});var m=i(785893);function x(e,t,i){var n;return(t="symbol"==typeof(n=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"))?n:String(n))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}let b=e=>{let{delay:t,diameter:i,height:n,initialColor:l,width:s,xOffset:a,yOffset:r}=e,d=Math.floor(i/2),c=g(t,i,n,l,d,s,a,r);return(0,m.jsx)(o.xu,{dangerouslySetInlineStyle:{__style:c.bubblePositionStyles},children:(0,m.jsx)(o.xu,{dangerouslySetInlineStyle:{__style:c.bubbleSwirlStyles},children:(0,m.jsx)(o.xu,{dangerouslySetInlineStyle:{__style:c.bubbleGrowShrinkStyles},children:(0,m.jsx)(o.xu,{dangerouslySetInlineStyle:{__style:c.bubbleShapeStyles}})})})})};class f extends n.Component{constructor(...e){super(...e),x(this,"state",{isInitialized:!1})}componentDidMount(){window.requestAnimationFrame(()=>{this.setState({isInitialized:!0})})}shouldComponentUpdate(e,t){return!e.numBubbles===this.props.numBubbles||!t.isInitialized===this.state.isInitialized}getSize(){let{width:e,height:t}=this.props;return void 0!==e&&void 0!==t?{width:e,height:t}:this.containerElement?{height:this.containerElement.offsetHeight,width:this.containerElement.offsetWidth}:{height:void 0,width:void 0}}createBubbles(e,t){let{delayFactor:i,delayOffset:n,numBubbles:o,xRadiusAdjustment:s,yRadiusAdjustment:r}=this.props,d=e+2*r,c=t+2*s,u=[],p=Object.keys(a);for(let s=0;s<o;s+=1){let o=16+(0,l.XF)(-4,4),a=p[s%p.length],{x:r,y:h}=(0,l.CC)(d,c);u.push((0,m.jsx)(b,{delay:s*i+n,diameter:o,initialColor:a,xOffset:r,yOffset:h,height:e,width:t},s))}return u}render(){let{isDesktop:e}=this.props,{height:t,width:i}=this.getSize();return(0,m.jsxs)(o.xu,{height:t,width:i,position:"relative",children:[(0,m.jsx)(s.Z,{unsafeCSS:_}),(0,m.jsxs)(o.xu,{position:e?void 0:"absolute",ref:e=>this.containerElement=e,children:[this.state.isInitialized&&this.createBubbles(t||0,i||0),(0,m.jsx)(o.xu,{position:"relative",children:this.props.children})]})]})}}x(f,"defaultProps",{numBubbles:10,xRadiusAdjustment:0,yRadiusAdjustment:0,delayFactor:1,delayOffset:0});let y=f},155949:(e,t,i)=>{i.d(t,{R:()=>h,Z:()=>_});var n=i(667294),o=i(883119),l=i(157796),s=i(81636),a=i(898781),r=i(780280),d=i(962482),c=i(116485),u=i(477310),p=i(785893);let h=e=>{let t=new Set([...c.EU,...c.rT,...c.IO]);return t.has(e)};function _({isReducedHeader:e,progressBarAnimationDuration:t}){let i=(0,a.ZP)(),{country:c}=(0,r.B)(),_=h(c);return(0,p.jsx)(n.Fragment,{children:_?(0,p.jsx)(s.Z,{log:{view_type:10,view_parameter:259},children:(0,p.jsxs)(o.xu,{position:"fixed",top:!0,left:!0,right:!0,bottom:!0,width:"100%",color:"default",children:[(0,p.jsx)(l.Z,{color:"dark",duration:t||3e3,finalProgress:95}),(0,p.jsxs)(o.kC,{alignItems:"stretch",justifyContent:"start",direction:"column",height:"100%",children:[(0,p.jsxs)(o.xu,{margin:10,children:[(0,p.jsx)(o.X6,{overflow:"normal",size:e?"500":"600",children:i._('Your account is being created!', 'account created heading', 'account created heading')}),(0,p.jsx)(o.xv,{overflow:"normal",children:i._('You can now save ideas, get personalized recommendations, and more', 'loading state description while waiting for any sign up registration to complete', 'loading state description while waiting for any sign up registration to complete')})]}),(0,p.jsx)(o.kC,{alignItems:"center",flex:"grow",justifyContent:"center",children:(0,p.jsx)(u.Z,{delayOffset:-5,isDesktop:!1,xRadiusAdjustment:40,yRadiusAdjustment:40,children:(0,p.jsx)(o.xu,{alignItems:"center",color:"lightWash",direction:"column",display:"flex",height:120,justifyContent:"end",overflow:"hidden",rounding:"circle",width:120,children:(0,p.jsx)(o.JO,{accessibilityLabel:i._('Loading', 'Loading state for any sign up registration', 'Loading state for any sign up registration'),color:"subtle",icon:"person",size:"90"})})})})]})]})}):(0,p.jsx)(d.Z,{})})}},594353:(e,t,i)=>{i.d(t,{Z:()=>o});var n=i(116485);let o=(e,t,i)=>!t&&!i&&n.ZR.has(e)},38161:(e,t,i)=>{i.d(t,{Z:()=>n});function n(e,t){let i=new URLSearchParams(e);return i.delete(t),i.toString()}},275926:(e,t,i)=>{i.d(t,{f:()=>I,l:()=>T});var n=i(667294),o=i(702664),l=i(214494),s=i(112690),a=i(231486),r=i(226198),d=i(628551),c=i(957191),u=i(88307),p=i(539278),h=i(290148),_=i(773285),g=i(383690),m=i(330102),x=i(780280),b=i(735422),f=i(957161),y=i(844974),v=i(867820),w=i(69642),j=i(116485),S=i(421322),P=i(993723),k=i(529195),A=i(534427),C=i(709113),z=i(67347);let Z=e=>({type:"AUTHENTICATE_USER",payload:{user:e}}),I=()=>{let e=(0,s.Z)(),t=(0,_.F)(),i=(0,o.useDispatch)(),{country:I,countryFromHostName:T,countryFromIp:E,regionFromIp:L,userAgent:{isTablet:B,isMobile:M}}=(0,x.B)(),O=(0,g.Z)(),R=(0,w.Z)();return(0,n.useCallback)(async(n,o,s="/",_={isAutologin:!1,isSwitchAccount:!1,noLocationReplace:!1,recaptchaV3Token:"default",noImmediateRedirect:!1,useAlternativeResourceCall:!1,trigger:"other",accountUnlinked:!1},g)=>{O();let x=!B&&!M,{isAutologin:w,isSwitchAccount:D,noLocationReplace:F,recaptchaV3Token:N,noImmediateRedirect:U,useAlternativeResourceCall:H,trigger:W,accountUnlinked:$}=_;f.Z.setItem(C.V6,(0,h.nY)(n));let G=t=>{var i;e({...g,event_type:t,aux_data:{...g.aux_data,upsell_reason:(null===(i=g.aux_data)||void 0===i?void 0:i.upsell_reason)||(w?"autologin":f.Z.getItem(C.bg)||null),upsell_view_count:f.Z.getItem(C.w0)||0}}),7536===t&&f.Z.setItem(C.w0,0)},Y={get_user:!0,...n,app_type_from_client:6,recaptchaV3Token:N},K=(0,k.t_)();K&&(Y={...Y,visited_pages_before_login:K});let X=(0,k.OJ)();X&&(Y={...Y,referrer:X});let q=l.Z.create("UserSessionResource",Y).callCreate();if(H&&n.username_or_email&&n.password){let e=new FormData;e.append("username",n.username_or_email),e.append("password",n.password);let t={method:"POST",body:e,credentials:"include",headers:{Accept:"application/json, text/javascript, */*","X-CSRFToken":(0,d.getCsrfToken)()||"","X-Requested-With":"XMLHttpRequest"}};q=fetch("/resource/UserSessionResource/create/",t).then(e=>{if(200!==e.status)throw Error(e.statusText);return e.json()}).catch(e=>Promise.reject(e))}try{w?(0,v.dy)({event:"login_api_call_start",provider:n.google_open_id_token?"google":"facebook"}):(0,v.EX)({event:"login_api_call_start",provider:(0,h.nY)(n)}),G(7534),R({action:w?"autologin":"login",event:"attempt",type:(0,h.lp)(n),trigger:W});let e=await q;w?(0,v.dy)({event:"login_api_call_success",provider:n.google_open_id_token?"google":"facebook"}):(0,v.EX)({event:"login_api_call_success",provider:(0,h.nY)(n)}),i(Z(e.resource_response.data.user));let l=e.client_context,d=e.resource_response.data.user.gatekeeper_experiments;if(d){let{active:e,triggerable:i}=d;e&&i||(0,z.nP)("webapp.authentication.emptyExperimentsDebug",{sampleRate:1,tags:{active:String(!!e),triggerable:String(!!i)}}),t.updateExperiments(e,i)}else(0,z.nP)("webapp.authentication.updateExperimentsFailed");l&&l.placed_experiences&&i((0,c.OD)(l.placed_experiences)),(0,S.Z)("authentication.login_success"),h.ZP.storeLoginCredentialsToBrowser(n),G(7536),R({action:w?"autologin":"login",event:"success",type:(0,h.lp)(n),trigger:W}),(0,u.Z)(),a.zN(r.e7.name),a.zN(r.x3.name),(0,y.Nh)(j.AA,1),"/"!==s&&(0,A.E)(!0),D?(0,b.Dm)().then(()=>{var t;let i=`/${(null===(t=e.resource_response.data)||void 0===t?void 0:t.user.username)||""}`+($?`?message=${p.aU}`:"");window.location.href=i}):w&&!x||U||(0,P._)({forceFullPageNavigation:x,history:o,next:s,noLocationReplace:F,origin:window.location}),(0,m.ko)({country:I,countryFromHostName:T,countryFromIp:E,regionFromIp:L,deviceType:"Mobile",eventCategory:"Logins"})}catch(e){if(w?(0,v.dy)({event:"login_api_call_failure",provider:n.google_open_id_token?"google":"facebook"}):(0,v.EX)({event:"login_api_call_failure",provider:(0,h.nY)(n)}),1201!==e.api_error_code||w||x)throw G(7535),R({action:w?"autologin":"login",event:"fail",type:(0,h.lp)(n),trigger:W}),D&&(0,S.Z)("authentication.login_error"),e;if(o){let t={creds:n,next:s,phoneNumber:e.data.phone_number_end};o.push({pathname:"/login/mfa/",state:t})}}},[i,I,T,E,O,t,M,B,e,L,R])},T=()=>{let e=(0,_.F)(),t=(0,o.useDispatch)(),i=(0,g.Z)();return({client_context:n,resource_response:o})=>{let{data:l}=o;l&&(i(),t(Z(l.user)));let s=l.user.gatekeeper_experiments;if(s){let{active:t,triggerable:i}=s;t&&i||(0,z.nP)("webapp.crossDomainAutologin.emptyExperimentsDebug",{sampleRate:1,tags:{active:String(!!t),triggerable:String(!!i)}}),e.updateExperiments(t,i)}else(0,z.nP)("webapp.crossDomainAutologin.updateExperimentsFailed");n&&t((0,c.OD)(n.placed_experiences))}}},122485:(e,t,i)=>{i.d(t,{m:()=>Z});var n=i(702664),o=i(214494),l=i(594881),s=i(112690),a=i(231486),r=i(226198),d=i(957191),c=i(88307),u=i(584595),p=i(45169),h=i(773285),_=i(383690),g=i(330102),m=i(780280),x=i(735422),b=i(957161),f=i(339363),y=i(867820),v=i(69642),w=i(421322),j=i(529195),S=i(844974),P=i(116485),k=i(155949),A=i(709113),C=i(67347);let z=e=>({type:"REGISTER_USER",payload:{user:e}}),Z=()=>{let e=(0,h.F)(),t=(0,n.useDispatch)(),{country:i,countryFromHostName:Z,countryFromIp:I,regionFromIp:T,isAuthenticated:E}=(0,m.B)(),L=(0,_.Z)(),B=(0,s.Z)(),M=(0,v.Z)();return(n,{signupAttemptContextEvent:s})=>{let h=(0,p.yV)(n),_=e=>{var t;B({...s,event_type:e,aux_data:{...s.aux_data,upsell_reason:(null===(t=s.aux_data)||void 0===t?void 0:t.upsell_reason)||b.Z.getItem(A.bg)||null,upsell_view_count:b.Z.getItem(A.w0)||0}}),7487===e&&b.Z.setItem(A.w0,0)};_(7537),M({action:"signup",event:"attempt",type:h}),L();let m=0,v=(0,k.R)(i),O=new Promise(e=>{v?setTimeout(()=>{e()},3e3):e()});return new Promise((s,b)=>{let v=()=>{var k;let A=(0,j.t_)(),L=(0,j.OJ)(),B={...n,user_behavior_data:function(){let e=[P.E9];return function(e){let t={};return e.forEach(e=>{let i=JSON.parse((0,S.qn)(e));i&&(t[e]=i)}),JSON.stringify(t)}(e)}(),visited_pages:A};L&&(B.referrer=L),(0,C.nP)("webapp.debug_signup_type.redux_registration",{sampleRate:1,tags:{CHECK_TYPE:null!==(k=(0,p.Eh)(B,"CHECK_TYPE"))&&void 0!==k?k:"none",CHECK_EXISTS:(0,p.Eh)(B,"DEPRECATED_CHECK_EXISTS"),CHECK_TRUTHY:(0,p.Eh)(B,"DEPRECATED_CHECK_TRUTHY")}}),o.Z.create("UserRegisterResource",{...B,get_user:!0}).callCreate().then(o=>O.then(()=>{(0,f.L_)("d_pif_invite");let a=o.client_context;t(z(o.resource_response.data.user));let r=o.resource_response.data.user.gatekeeper_experiments;if(r){let{active:t,triggerable:i}=r;t&&i||(0,C.nP)("webapp.registration.emptyExperimentsDebug",{sampleRate:1,tags:{active:String(!!t),triggerable:String(!!i)}}),e.updateExperiments(t,i)}else(0,C.nP)("webapp.registration.updateExperimentsFailed");a&&a.placed_experiences&&t((0,d.OD)(a.placed_experiences)),E&&(0,w.Z)("registration.signup_success");let u=n.email||n.username||null,p=n.password||null,{credentials:m}=navigator;if(m&&u&&p)try{let e=new window.PasswordCredential({id:u,password:p});(0,y.My)("unauth_mweb.navigatorCredentials.store.attempt"),m.store(e).then(()=>{(0,y.My)("unauth_mweb.navigatorCredentials.store.success")})}catch(e){(0,y.My)("unauth_mweb.navigatorCredentials.store.error")}_(7487),M({action:"signup",event:"success",type:h}),(0,l.Z)(),(0,c.Z)(),E&&(0,x.Dm)(),(0,g.ko)({country:i,countryFromHostName:Z,countryFromIp:I,regionFromIp:T,deviceType:"Mobile",eventCategory:"NewUsers"}),s()})).catch(e=>{(null==e?void 0:e.api_error_code)===u.tz&&((0,y.My)("multi_step_set_age_restrict_cookie"),a.t8(r.It,"1",(0,a.kZ)(r.It))),m<3&&[u.dO,u.cZ].includes(null==e?void 0:e.api_error_code)?(m+=1,v()):(_(7488),M({action:"signup",event:"fail",type:h}),E&&(0,w.Z)("registration.signup_error"),b(e))})};v()})}}},10693:(e,t,i)=>{i.d(t,{Z:()=>l});var n=i(442279);let o=(0,n.P1)(e=>e.boards,e=>Object.keys(e).reduce((t,i)=>{var n;let o=e[i];t[null!==(n=o.url)&&void 0!==n?n:""]=o;let{oldSlugUrl:l}=o;return l&&(t[l]=o),t},{})),l=o},107287:(e,t,i)=>{i.d(t,{Z:()=>a});var n=i(883119),o=i(121151),l=i(898781),s=i(785893);function a({type:e,onDismiss:t}){let i=(0,l.ZP)(),a="facebook"===e?i._('Oops! Facebook isn\'t available', 'socialAuthDisabled.facebook.title', 'Title for the modal shown when Facebook services are not working'):i._('Oops! Google isn\'t available', 'socialAuthDisabled.google.title', 'Title for the modal shown when Google services are not working'),r="facebook"===e?i._('Looks like Facebook isn\'t available right now.\n\nGive another option a try or refresh the page and try again later.', 'socialAuthDisabled.facebook.description', 'Description for the modal shown when Facebook services are not working'):i._('Looks like Google isn\'t available right now.\n\nGive another option a try or refresh the page and try again later.', 'socialAuthDisabled.google.description', 'Description for the modal shown when Google services are not working');return(0,s.jsx)(o.ZP,{accessibilityModalLabel:"",mobileHideCloseIcon:!0,isOpen:!0,onDismiss:t,type:"social_auth_disabled_modal",children:(0,s.jsxs)(n.xu,{padding:5,children:[(0,s.jsx)(n.xu,{marginBottom:3,children:(0,s.jsx)(n.X6,{size:"500",accessibilityLevel:1,children:a})}),(0,s.jsx)(n.xu,{marginBottom:3,children:(0,s.jsx)(n.xv,{children:r})}),(0,s.jsx)(n.kC,{alignItems:"stretch",justifyContent:"start",direction:"column",children:(0,s.jsx)(n.xu,{paddingY:1,children:(0,s.jsx)(n.zx,{accessibilityLabel:i._('OK', 'socialAuthDisabled.okButton', 'Button that closes modal shown when Facebook or Google services are not working'),size:"lg",color:"red",text:i._('OK', 'socialAuthDisabled.okButton', 'Button that closes modal shown when Facebook or Google services are not working'),onClick:t})})})]})})}},100110:(e,t,i)=>{i.d(t,{Z:()=>m});var n=i(667294),o=i(824002),l=i(112274),s=i(883119),a=i(469134),r=i(898781),d=i(780280),c=i(50286),u=i(134906),p=i(109322),h=i(272275),_=i(785893);let g=(e,t,i,n)=>{let s=(0,o.Z)(e,"yyyy-MM-dd",new Date);if(!(0,l.Z)(s)){let e=(0,a.Tv)(t,!0,!0,!0);i(e),n("date error");return}if(!(0,a.Cd)(e,p.kx)){let e=(0,a.Uy)(t);i(e),n(e);return}let r=(0,u.a3)(e,[(0,u.C9)({date:new Date(new Date().getFullYear(),0,1),message:t._('Invalid date', 'signup.emailpasswordstep.birthday.validator_message', 'Error message shown when user input a birthday date later than allowed')})]);i(r),n(r)};function m({disabled:e,handleChangeBirthday:t,setValidState:i,birthdayErrorMessage:l,birthday:u,onChange:p,setBirthday:m,hideFieldLabel:x}){let b=(0,r.ZP)(),f=(0,c.HG)(),y=u?(0,o.Z)(u,"yyyy-MM-dd",new Date):void 0,[v,w]=(0,n.useState)({day:y?y.getDate():void 0,month:y?y.getMonth()+1:void 0,year:y?y.getFullYear():void 0}),[j,S]=(0,n.useState)(!1),[P,k]=(0,n.useState)(!1),[A,C]=(0,n.useState)(!1),[z,Z]=(0,n.useState)(""),{locale:I}=(0,d.B)(),T=(0,n.useCallback)(({day:e,month:n,year:o})=>{if(void 0!==o&&(o<a.nN||o>a.cO)?C(!0):C(!1),void 0!==n&&(n>a.Xf||n<a.Oh)?k(!0):k(!1),void 0!==e&&(e<a.p9||e>a.G)?S(!0):S(!1),j||P||A){let e=(0,a.Tv)(b,j,P,A);m(""),t(u),Z(e),i("error birthday fields")}else void 0!==n&&void 0!==o&&void 0!==e?(m(o.toString()+"-"+n.toString().padStart(2,"0")+"-"+e.toString().padStart(2,"0")),t(u),g(u,b,Z,i)):(m(""),t(u),Z(""))},[j,P,A,b,i,m,t,u]);(0,n.useEffect)(()=>{T(v)},[v,T]);let E=(e,t)=>{w({...v,[e.target.name]:t}),null==p||p()},L=(0,_.jsx)(s.xu,{"data-test-id":"birthday-fields",children:(0,_.jsx)(s.Ki,{disabled:e,name:"day",id:"birthday-day",label:x?"":b._('Day', 'signup.birthdate.day', 'Signup birthdate textfield day label'),onBlur:()=>T(v),onChange:({event:e,value:t})=>{E(e,t)},placeholder:b._('DD', 'signup.birthdate.placeholder.day', 'Signup birthdate textfield day placeholder'),value:v.day})}),B=(0,_.jsx)(s.xu,{"data-test-id":"birthday-fields",children:(0,_.jsx)(s.Ki,{disabled:e,name:"month",id:"birthday-month",label:x?"":b._('Month', 'signup.birthdate.month', 'Signup birthdate textfield month label'),onBlur:()=>T(v),onChange:({event:e,value:t})=>{E(e,t)},placeholder:b._('MM', 'signup.birthdate.placeholder.month', 'Signup birthdate textfield month placeholder'),value:v.month})}),M=(0,_.jsx)(s.xu,{"data-test-id":"birthday-fields",children:(0,_.jsx)(s.Ki,{disabled:e,name:"year",id:"birthday-year",label:x?"":b._('Year', 'signup.birthdate.year', 'Signup birthdate textfield year label'),onBlur:()=>T(v),onChange:({event:e,value:t})=>{E(e,t)},placeholder:b._('YYYY', 'signup.birthdate.placeholder.year', 'Signup birthdate textfield year placeholder'),value:v.year})}),O=(0,h.Z)(I);return(0,_.jsx)(s.xu,{display:"flex",paddingY:2,marginStart:f?2:3,marginEnd:f?-1:3,children:(0,_.jsx)(s.pg,{id:"birthday-input-fields",legend:b._('birthday input fields', 'birthday legend', 'Label to birthday legend'),legendDisplay:"hidden",errorMessage:l||z,children:(0,_.jsxs)(s.kC,{gap:4,children:["YYMMDD"===O?M:"MMDDYY"===O?B:L,"YYMMDD"===O?B:"MMDDYY"===O?L:B,"YYMMDD"===O?L:M]})})})}},272275:(e,t,i)=>{i.d(t,{Z:()=>n});function n(e){let t=new Intl.DateTimeFormat(e).formatToParts(new Date),i=t.map(e=>{switch(e.type){case"day":return"DD";case"month":return"MM";case"year":return"YY";default:return""}}).join("");return i.startsWith("Y")?"YYMMDD":i.startsWith("M")?"MMDDYY":"DDMMYY"}},172351:(e,t,i)=>{i.d(t,{Z:()=>Y});var n=i(667294),o=i(702664),l=i(616550),s=i(883119),a=i(204324),r=i(112690),d=i(989392),c=i(499128),u=i(898781),p=i(584595),h=i(432300),_=i(45169),g=i(830269),m=i(773285),x=i(780280),b=i(957161),f=i(867820),y=i(52022),v=i(101331),w=i(343341),j=i(50286),S=i(19121),P=i(962482),k=i(63552),A=i(473138),C=i(467570),z=i(107287),Z=i(785893);function I({onFacebookConnectError:e,onFacebookConnectSuccess:t,onTouch:i,isRerequest:o}){let l=(0,u.ZP)(),{checkExperiment:a}=(0,m.F)(),{locale:r}=(0,x.B)(),{anyEnabled:d}=a("mweb_facebook_disabled"),[c,p]=(0,n.useState)(!1),[h,_]=(0,n.useState)(!1);return(0,n.useEffect)(()=>{d||((0,C.we)(r).then(()=>{p(!0)}),(0,f.My)("pcons.facebook_connect_button_renderd"))},[r,d]),(0,Z.jsxs)(s.xu,{position:"relative","data-test-id":"FacebookConnectContainer",children:[(0,Z.jsx)(s.xu,{bottom:!0,left:!0,right:!0,top:!0,dangerouslySetInlineStyle:{__style:{pointerEvents:"none"}},position:"absolute",rounding:5,children:(0,Z.jsx)("div",{className:"fb-login-button","data-width":"100%","data-max-rows":"1","data-size":"large","data-button-type":"continue_with","data-layout":"rounded","data-show-faces":"false","data-auth-type":o?"rerequest":void 0,"data-scope":(0,C._V)().join(","),"data-auto-logout-link":"false","data-use-continue-as":"true"})}),(0,Z.jsxs)("button",{onClick:()=>{(0,f.My)("unauth_mweb.facebook_connect.button_click"),(0,f.EX)({event:"start",provider:"facebook"}),null==i||i(),d?_(!0):c&&(0,C.JF)().then(({creds:e,signupOptions:i})=>{t(e,i)},e)},style:{display:"flex",alignItems:"center",backgroundColor:"#1877F2",border:"none",height:"40px",transition:"opacity .2s linear",width:"100%",minWidth:"240px",borderRadius:"20px",padding:"0px 0px 0px 8px"},type:"button","data-test-id":"FacebookConnectButton",children:[(0,Z.jsx)(s.xu,{color:"default",rounding:3,dangerouslySetInlineStyle:{__style:{paddingTop:"5px",paddingLeft:"3px",paddingRight:"2px",marginLeft:"4px",marginRight:"4.4px"}},children:(0,Z.jsx)(s.JO,{accessibilityLabel:l._('facebook', 'accessible label for facebook icon', 'accessible label for facebook icon'),color:"shopping",icon:"facebook",inline:!0,size:19})}),(0,Z.jsx)(s.xu,{alignItems:"center",display:"flex",justifyContent:"center",flex:"grow",marginEnd:1,children:(0,Z.jsx)("span",{style:{fontFamily:"Helvetica, Arial, sans-serif",fontWeight:"bold",color:"#fff",fontSize:"16px",paddingRight:"8px",letterSpacing:"0.25px"},children:l._('Continue with Facebook', 'Login page button', 'Login page button')})})]}),h&&(0,Z.jsx)(z.Z,{type:"facebook",onDismiss:()=>_(!1)})]})}var T=i(553171);let E={defaultButton:{display:"flex",alignItems:"center",backgroundColor:"#00C300",border:"none",height:"40px",transition:"opacity .2s linear",width:"100%",borderRadius:"20px",padding:"0px 0px 0px 8px"},lineLogo:{borderRadius:"12px",backgroundColor:"#00C300",width:"32px",height:"32px"},buttonText:{fontWeight:"bold",color:"#fff",fontSize:"16px",paddingRight:"33px"}},L=({buttonText:e,onLineConnectSuccess:t,onLineConnectError:i,onTouch:n})=>{let o=(0,u.ZP)(),{locale:l}=(0,x.B)(),a={success:e=>{let{line_id_token:i,line_access_token:n}=e;i&&n&&t({line_id_token:i,line_access_token:n},{line_id_token:i,line_access_token:n,type:"line"})},error:i},r=E.defaultButton;return(0,Z.jsx)(s.xu,{position:"relative","data-test-id":"LineConnectContainer",children:(0,Z.jsxs)("button",{onClick:()=>{(0,f.My)("unauth_mweb.line_connect.button_click"),n&&n(),(0,T.Z)(l,a)},style:r,type:"button","data-test-id":"line-connect-button",children:[(0,Z.jsx)("img",{style:E.lineLogo,src:"https://s.pinimg.com/webapp/btn_base-a34b3f23.png",alt:o._('line', 'accessible label for line icon', 'accessible label for line icon')}),(0,Z.jsx)(s.kC,{alignItems:"center",justifyContent:"center",flex:"grow",children:(0,Z.jsx)("span",{style:E.buttonText,children:e})})]})})};var B=i(368095),M=i(160561),O=i(155949),R=i(275926),D=i(122485),F=i(639952),N=i(53987),U=i(598615);function H({app_upsell_type:e}){let t=(0,u.ZP)(),i=(0,l.useLocation)(),{userAgent:{platform:n}}=(0,x.B)(),{pathname:o}=i;return(0,Z.jsx)(s.xu,{"data-test-id":"continue-app-button",marginBottom:2,children:(0,Z.jsx)(U.Z,{componentType:13858,app_upsell_type:null!=e?e:"unauth-signup-modal",children:({handleOpenApp:l})=>(0,Z.jsx)(s.zx,{text:t._('Get Pinterest App', 'unauth.modal.get_app.button_text', 'App download button text'),color:"red",fullWidth:!0,onClick:()=>{(0,f.My)("homepage_top_module"===e?"mweb.unauth.homepage.top.download_app_button.click":"homepage_bottom_module"===e?"mweb.unauth.homepage.bottom.download_app_button.click":"mweb.unauth.signup_modal.download_app_button.click"),o&&l({deepLinkUri:"/"===o?"/":(0,N.cD)(i)&&("ios"===n||"ipad"===n)?"user"+o:o.substr(1)})}})})})}var W=i(709113),$=i(562647),G=i(597897);function Y({apple:e,facebook:t,fbConnectHandler:i,footer:C,from:z,google:T,isBusiness:E,isRerequest:N,line:U,next:Y="/",noImmediateRedirect:K,disableFBSignup:X,onFacebookTouch:q,onLoginTouch:J,onSignupTouch:V,showAppInstallButton:Q,showEmailButton:ee,showTextDivider:et,viewParameter:ei,app_upsell_type:en,attributionLabel:eo}){let el=(0,l.useHistory)(),es=(0,l.useLocation)(),{country:ea}=(0,x.B)(),er=(0,u.ZP)(),{showToast:ed}=(0,w.F9)(),ec=(0,r.Z)(),eu=(0,y.Z)(),ep=(0,o.useDispatch)(),eh=(0,R.f)(),e_=(0,G.U)(),{flush:eg}=(0,m.F)(),em=(0,D.m)(),ex=(0,a.Z)(),{isAuth:eb,isLimitedLogin:ef}=(0,S.Z)(),ey=(0,j.ml)(),{checkExperiment:ev}=(0,m.F)(),[ew,ej]=(0,n.useState)(null),[eS,eP]=(0,n.useState)(!1),[ek,eA]=(0,n.useState)("default"),{trackConversionUpsell:eC}=(0,v.Z)(),ez=(0,x.B)(),eZ=!!b.Z.getItem(W.V6)&&(ez.experimentsClient.checkExperiment("pcons_mweb_last_logged_in").anyEnabled||ez.experimentsClient.checkExperiment("pcons_last_logged_in").anyEnabled),eI="facebook"===ek&&5e3||"google"===ek&&4e3||void 0;(0,n.useEffect)(()=>{if(e_){var e,t;C&&(null===(e=e_.preload)||void 0===e||e.call(e_,(0,$.ke)("login.js"))),ee&&(null===(t=e_.preload)||void 0===t||t.call(e_,(0,$.ke)("signup.js")))}},[]);let eT=eb?{login_state:ef?h.Z.LIMITED:h.Z.DEFAULT}:Object.freeze({}),eE=e=>{ec({view_type:10,view_parameter:ei,element:e,event_type:102,aux_data:eT})},eL=e=>{eC({viewType:10,viewParameter:ei,eventType:14689,element:e})},eB=(e,t)=>{let i,n;switch(t){case"facebook":i=3205,n=g.Z.FACEBOOK;break;case"google":i=3204,n=g.Z.GPLUS;break;case"line":i=3556,n=g.Z.LINE}return{event_type:e,view_type:10,view_parameter:i,element:n===g.Z.GPLUS?12981:void 0,aux_data:{...eT,signup_login_method:n,upsell_reason:eo}}},eM=(e,t,i,n)=>{ej(null);let o=()=>ed(({hideToast:e})=>(0,Z.jsx)(c.ZP,{text:t&&t.api_error_code&&t.message?t.message:er._('Sorry, we can\'t log you in.', 'Error message when user having trouble login in.', 'Error message when user having trouble login in.'),onHide:e}));if(t){if((0,f.My)(`unauth_mweb.login_error.api_error_code.${String(t.api_error_code)}`),[p.xN,p.lg,p.Pv].includes(t.api_error_code)){if("facebook"===i.type&&ev("mweb_unauth_remove_fb_signup_iteration").anyEnabled){null==X||X();return}(0,f.Rp)({event:"start",provider:n}),"facebook"!==i.type||i.email?(()=>{(0,f.My)("unauth_mweb.facebook_signup_attempt"),i.gender||(0,f.My)("unauth_mweb.facebook_signup_attempt.nogender");let{birthday:e}=i;if(void 0===e||!(0,d.Z)(e)){eg(),el.push({pathname:"/signup/thirdpartyage/",state:{signupOptions:"facebook"===i.type?{...i,email_source_site:_.E_.FACEBOOK}:i,progressBarAnimationDuration:eI},attributionLabel:eo});return}ej("signup"),eA(n);let t="facebook"===i.type?{...i,email_source_site:_.E_.FACEBOOK,birthday_source_site:_.E_.FACEBOOK,birthday:e}:{...i,birthday:e};(0,f.Rp)({event:"signup_api_call_start",provider:n}),em(t,{signupAttemptContextEvent:eB(7537,n)}).then(()=>{(0,f.NC)("signup_via_login_buttons"),(0,f.Rp)({event:"signup_api_call_success",provider:n}),["facebook","google"].includes(n)&&ex(Y||"/"),ej(null)},e=>{(0,f.Rp)({event:"signup_api_call_failure",provider:n}),"line"===i.type&&(e.api_error_code===p.iZ?el.push({pathname:"/signup/line-email-collect/",state:{signupOptions:i},attributionLabel:eo}):e.api_error_code===p.NF&&el.push({pathname:"/signup/thirdpartyage/",state:{signupOptions:i},attributionLabel:eo})),ed(({hideToast:t})=>(0,Z.jsx)(c.ZP,{text:e.api_error_code&&e.message?e.message:er._('Sorry! Something went wrong on our end.', 'Error logging on', 'Error logging on'),onHide:t})),ej(null)})})():(el.push({pathname:"/signup/fbemailcollect/",state:{signupOptions:i},attributionLabel:eo}),(0,f.My)("unauth_mweb.reg_via_fb.has_email_perm.false"))}else p.ik.includes(t.api_error_code)&&eP(!0);o()}else(0,f.My)("unauth_mweb.login.unexpected_error"),o()},eO=e=>(t,n)=>{var o;let l="google"===e?"gsi_btn":"other",s=(null===(o=es.state)||void 0===o?void 0:o.switch_account)==="true"?{isSwitchAccount:!0,trigger:l}:{noImmediateRedirect:K,trigger:l};"facebook"===e&&(null==i||i("success"),(0,f.EX)({event:"receive_credential_response_from_provider",provider:e})),(0,f.NC)(e+"_login_success"),eh(t,el,Y,s,eB(7534,e)).catch(i=>{eM(t,i,n,e)}),ej("login"),eA(e)},eR=({event:e})=>{e.stopPropagation(),e.preventDefault(),null==J||J(),z&&ep((0,F.rm)(z)),eu({action:"click",item:"login-button"}),eE(30),(0,f.My)(`unauth_mweb.login_buttons.footer.${(null==C?void 0:C.type)||"button"}`),(0,f.NC)("press_login"),eC({eventType:14689,element:30,viewType:10,viewParameter:ei}),eC({eventType:14688,component:14213,upsellReason:eo,incrementUpsellReasonCounter:!1}),el.push({pathname:E?"/business/login/":"/login/",search:es.search,state:{next:Y,attributionLabel:eo}})};return(0,Z.jsxs)(s.xu,{marginTop:E?-5:0,maxWidth:400,marginStart:"auto",marginEnd:"auto","data-test-id":"LoginButtonsContainer",children:[eS&&(0,Z.jsx)(B.Z,{onDismiss:()=>eP(!1)}),et&&(0,Z.jsx)(s.xu,{marginBottom:3,marginTop:3,children:(0,Z.jsx)(s.xv,{align:"center",size:"100",weight:"bold",children:er._('OR', 'Separator for email login button and social login button', 'Separator for email login button and social login button')})}),(0,Z.jsx)(s.xu,{marginBottom:eZ?0:6,children:(0,Z.jsxs)(n.Fragment,{children:[Q&&(0,Z.jsx)(H,{app_upsell_type:en}),ee&&(0,Z.jsx)(s.xu,{"data-test-id":"continue-email-button",marginBottom:E?-2:2,children:(0,Z.jsx)(s.zx,{fullWidth:!0,color:Q?"gray":"red",text:E?er._('Create account', 'Button text for creating a business account', 'Button text for creating a business account'):er._('Continue with email', 'Sign up button', 'Sign up button'),onClick:({event:e})=>{e&&(e.stopPropagation(),e.preventDefault()),(0,f.NC)("press_email_signup"),(0,f.Rp)({event:"start",provider:"email"}),eu({action:"click",item:"email-signup-button"}),null==V||V(),z&&ep((0,F.rm)(z)),eL(13506),eE(31),eC({eventType:14688,component:14215,upsellReason:eo,incrementUpsellReasonCounter:!1}),el.push({pathname:E?"/business/signup/step1/":"/signup/step1/",search:es.search,state:{next:Y,attributionLabel:eo}})}})}),t&&(0,Z.jsx)(s.xu,{marginBottom:eZ?1:2,"data-test-id":"facebook-connect-button",children:(0,Z.jsx)(I,{onFacebookConnectError:()=>{null==i||i("error"),(0,f.EX)({event:"receive_no_credential_response_from_provider",provider:"facebook"}),ed(({hideToast:e})=>(0,Z.jsx)(c.ZP,{text:er._('Unable to connect to Facebook', 'Error logging on with Facebook', 'Error logging on with Facebook'),onHide:e}))},onFacebookConnectSuccess:eO("facebook"),onTouch:()=>{null==q||q(),eL(13505),eu({action:"click",item:"facebook-connect-button"}),eE(68)},isRerequest:N})}),T&&(0,Z.jsx)(s.xu,{marginBottom:eZ?0:2,"data-test-id":"google-connect-button",children:(0,Z.jsx)(M.Z,{onGoogleConnectSuccess:eO("google"),onTouch:()=>{eL(13504)}})}),U&&"JP"===ea&&(0,Z.jsx)(s.xu,{marginBottom:2,"data-test-id":"line-connect-button",children:(0,Z.jsx)(L,{buttonText:er._('Continue with LINE', 'Login page button', 'Login page button'),onLineConnectError:()=>{ed(({hideToast:e})=>(0,Z.jsx)(c.ZP,{text:er._('Unable to connect to Line', 'Error logging on with Line', 'Error logging on with Line'),onHide:e}))},onLineConnectSuccess:eO("line"),onTouch:()=>{eL(13507),eE(12277),eu({action:"click",item:"line-connect-button"})}})}),e&&(0,Z.jsx)(s.xu,{marginBottom:2,"data-test-id":"apple-connect-button",children:(0,Z.jsx)(A.Z,{})})]})}),C&&("member_link"===C.type?(0,Z.jsx)(s.xu,{marginTop:-4,"data-test-id":"login-member",children:(0,Z.jsx)(k.Z,{pressState:"none",onTouch:e=>eR({event:e}),children:(0,Z.jsx)(s.xu,{paddingY:C.noPadding?0:4,marginBottom:C.increasedSpaceBelow?-1:-2,children:(0,Z.jsx)(s.xv,{align:"center",size:"200",weight:"bold",color:C.textColorIsLight?"light":"dark",children:ey&&ev("pcons_mweb_sign_in_copy").anyEnabled?er._('Already a member? Sign in', 'unauth.sign_in.text.home_page', 'Label for sign in button'):er._('Already a member? Log in', 'Link on mobile web sign up modal to direct unauth users to the login page', 'Link on mobile web sign up modal to direct unauth users to the login page')})})})}):(0,Z.jsx)(s.xu,{marginBottom:5,"data-test-id":"login-button",children:(0,Z.jsx)(s.zx,{fullWidth:!0,color:"transparent",onClick:eR,text:er._('Log in', 'Login page button', 'Login page button')})})),ew&&("signup"===ew?(0,Z.jsx)(O.Z,{progressBarAnimationDuration:eI}):(0,Z.jsx)(P.Z,{}))]})}},542837:(e,t,i)=>{i.d(t,{Z:()=>u});var n=i(883119),o=i(112690),l=i(385740),s=i(898781),a=i(349700),r=i(966113),d=i(52022),c=i(785893);function u({isMobileHomepage:e,isBusiness:t=!1,alignText:i="center",modernizedUI:u}){let p=(0,s.ZP)(),h=(0,o.Z)(),_=(0,d.Z)(),{viewType:g,viewParameter:m}=(0,l.SU)(),x=r.R_9,b=r.cvl,f=t?r.V$B:r.U5h;return(0,c.jsx)(n.xu,{display:"flex",alignItems:"left"===i?"start":"center",alignSelf:"center",direction:"row",justifyContent:"center",paddingX:4,wrap:!0,children:(0,c.jsx)(n.xv,{color:e?"inverse":"subtle",align:"left"===i?"start":"center",size:"100",overflow:"normal",inline:!0,children:(0,a.nk)(p._('By continuing, you agree to Pinterest\'s {{ termsOfService }} and acknowledge you\'ve read our {{ privacyPolicy }}. {{ noticeAtCollection }}.', ' - ', ' -- '),{termsOfService:(0,c.jsx)(n.xu,{display:"inlineBlock","data-test-id":"business-tos",children:(0,c.jsx)(n.xv,{color:u&&"default"||e&&"inverse"||"subtle",inline:!0,size:"100",weight:"bold",children:(0,c.jsx)(n.rU,{href:f,display:"inlineBlock",target:"blank",onClick:()=>{_({action:"click",item:"business-tos"}),g&&h({view_type:g,view_parameter:m,element:8012,event_type:102})},underline:"hover",children:t?p._('Business Terms of Service', 'Mobile web business terms of service link for partners', 'Mobile web business terms of service link for partners'):p._('Terms of Service', 'Mobile web terms of service link', 'Mobile web terms of service link')})})},"termsOfService"),privacyPolicy:(0,c.jsx)(n.xu,{display:"inlineBlock","data-test-id":"privacy",children:(0,c.jsx)(n.xv,{color:u&&"default"||e&&"inverse"||"subtle",inline:!0,size:"100",weight:"bold",children:(0,c.jsx)(n.rU,{href:x,display:"inlineBlock",target:"blank",onClick:()=>{_({action:"click",item:"privacy-policy"}),g&&h({view_type:g,view_parameter:m,element:8004,event_type:102})},underline:"hover",children:p._('Privacy Policy', 'Mobile web privacy policy link', 'Mobile web privacy policy link')})})},"privacyPolicy"),noticeAtCollection:(0,c.jsx)(n.xu,{display:"inlineBlock","data-test-id":"noticeAtCollection",children:(0,c.jsx)(n.xv,{color:e?"inverse":"subtle",inline:!0,size:"100",weight:"bold",children:(0,c.jsx)(n.rU,{href:b,display:"inlineBlock",target:"blank",onClick:()=>{_({action:"click",item:"notice-at-collection"})},underline:"hover",children:p._('Notice at collection', 'Mobile web notice at collection link', 'termOfService.link.noticeAtCollection')})})},"noticeAtCollection")})})})}},553342:(e,t,i)=>{i.d(t,{Z:()=>I});var n=i(667294),o=i(616550),l=i(883119),s=i(385740),a=i(898781),r=i(867820),d=i(52022),c=i(101331),u=i(766935),p=i(319915),h=i(53987),_=i(773285),g=i(947599),m=i(780280),x=i(784641),b=i(224525),f=i(785893);function y({onClick:e,onDismiss:t,open:i}){let s=(0,a.ZP)(),r=(0,o.useRouteMatch)(),[c,u]=(0,n.useState)(""),p=(0,d.Z)(),h=(0,n.useRef)(null),{country:_,isBot:g,isAuthenticated:y,locale:v}=(0,m.B)(),w=(0,x.bl)(),j="en"===v.slice(0,2),S={id:"ideas",text:y||"JP"!==_?s._('Explore', 'unauth.header.tabs.ideas', 'label for ideas hub'):s._('Explore ideas', 'unauth.header.tabs.ideas.jp', 'label for jp ideas hub'),href:"/ideas/"},P=[S];j&&P.push({id:"videos",text:s._('Watch', 'unauth.header.tabs.videos', 'label for the videos hub tab'),href:"/videos/"}),(g||!y&&j&&"US"===_)&&P.push({id:"shopping",text:s._('Shop', 'unauth.header.tabs.shop', 'label for the shopping hub tab'),href:"/shopping/"}),w&&P.push({id:"today",text:s._('Today', 'unauth.header.tabs.today', 'label for today tab'),href:(0,b.tG)()});let k=-1;r.url.startsWith("/today/")?k=P.findIndex(e=>e.href===(0,b.tG)()):r.url.startsWith("/ideas/")?k=P.findIndex(e=>"/ideas/"===e.href):r.url.startsWith("/videos/")?k=P.findIndex(e=>"/videos/"===e.href):r.url.startsWith("/shopping/")&&(k=P.findIndex(e=>"/shopping/"===e.href));let A=P[k]||S,C=((0,o.useRouteMatch)(A.href)||{isExact:!1}).isExact,z=e=>{e===(0,b.tG)()?p({action:"click",item:"nav-bar-hub-dropdown-today"}):"/videos/"===e?p({action:"click",item:"nav-bar-hub-dropdown-videos"}):"/ideas/"===e?p({action:"click",item:"nav-bar-hub-dropdown-ideas"}):"/shopping/"===e&&p({action:"click",item:"nav-bar-hub-dropdown-shopping"})};return(0,f.jsxs)(n.Fragment,{children:[(0,f.jsx)(l.kC,{justifyContent:"center",width:"100%",height:"100%",children:(0,f.jsx)(l.xu,{"data-test-id":"hub-dropdown",marginStart:2,minWidth:110,children:(0,f.jsx)(l.zx,{accessibilityControls:"hub-dropdown",accessibilityExpanded:i,accessibilityHaspopup:!0,accessibilityLabel:A.text,iconEnd:"arrow-down",onClick:e,ref:h,selected:i,size:"lg",text:A.text,fullWidth:!0})})}),i&&(0,f.jsx)(l.xu,{"data-test-id":"unauth-header-nav-dropdown",marginTop:1,dangerouslySetInlineStyle:{__style:{zIndex:1100}},children:(0,f.jsx)(l.J2,{id:"hub-dropdown",anchor:h.current,color:"white",idealDirection:"forceDown",onDismiss:t,shouldFocus:!0,role:"listbox",size:"lg",accessibilityLabel:A.text,children:(0,f.jsx)(l.xu,{direction:"column",display:"flex",flex:"grow",margin:2,children:P.map(({text:e,href:t,id:i})=>{let n=A.href===t&&C;return(0,f.jsx)(l.xu,{onMouseEnter:()=>{u(i)},onMouseLeave:()=>{u("")},color:c===i?"secondary":"transparent",direction:"column",display:"flex",padding:2,rounding:2,role:"option",children:(0,f.jsx)(l.rU,{underline:"none",href:t,accessibilityLabel:e,onClick:({event:e,dangerouslyDisableOnNavigation:i})=>{if(n){e.preventDefault(),i();return}z(t)},children:(0,f.jsxs)(l.kC,{children:[(0,f.jsx)(l.kC,{direction:"column",flex:"grow",gap:{column:1,row:0},children:(0,f.jsx)(l.xv,{inline:!0,lineClamp:1,color:"default",weight:"bold",children:e})}),n&&(0,f.jsx)(l.xu,{alignItems:"center",color:"transparent",display:"flex",justifyContent:"center",children:(0,f.jsx)(l.JO,{accessibilityLabel:"Selected item",color:"default",icon:"check",size:12})})]})})},i)})})})})]})}function v({isDesktop:e}){let t=(0,a.ZP)(),i=(0,o.useRouteMatch)(),n=(0,d.Z)(),{country:s,isBot:r,isAuthenticated:c,locale:u}=(0,m.B)(),p=(0,x.bl)(),h="en"===u.slice(0,2),_=[];p&&_.push({text:t._('Today', 'unauth.header.tabs.today', 'label for today tab'),href:(0,b.tG)()}),h&&_.push({text:t._('Watch', 'unauth.header.tabs.videos', 'label for the videos hub tab'),href:"/videos/"}),(r||!c&&h&&"US"===s)&&_.push({text:t._('Shop', 'unauth.header.tabs.shop', 'label for the shopping hub tab'),href:"/shopping/"}),_.push({text:c||"JP"!==s?t._('Explore', 'unauth.header.tabs.ideas', 'label for ideas hub'):t._('Explore ideas', 'unauth.header.tabs.ideas.jp', 'label for jp ideas hub'),href:"/ideas/"});let g=-1;return i.path.startsWith("/today/")?g=_.findIndex(e=>e.href===(0,b.tG)()):i.path.startsWith("/ideas/")?g=_.findIndex(e=>"/ideas/"===e.href):i.path.startsWith("/videos/")?g=_.findIndex(e=>"/videos/"===e.href):i.path.startsWith("/shopping/")&&(g=_.findIndex(e=>"/shopping/"===e.href)),(0,f.jsx)(l.mQ,{activeTabIndex:g,onChange:({activeTabIndex:t})=>{_[t].href===(0,b.tG)()?n({action:"click",item:"site-map-today"}):"/videos/"===_[t].href?n({action:"click",item:"site-map-videos"}):"/ideas/"===_[t].href?n({action:"click",item:"site-map-ideas"}):"/shopping/"===_[t].href&&n({action:"click",item:"root-nav-shopping"}),e&&(window.location.href=_[t].href)},tabs:_})}var w=i(501338),j=i(829407),S=i(873268);let P=(0,n.lazy)(()=>i.e(80673).then(i.bind(i,580673))),k=(0,n.forwardRef)(({isDesktop:e,onPrimaryButtonClick:t,onLoginButtonClick:i,primaryButtonText:s},c)=>{let[m,x]=(0,n.useState)(!1),[b,k]=(0,n.useState)(!1),[A,C]=(0,n.useState)(!1),z=(0,a.ZP)(),Z=(0,o.useLocation)(),I=(0,n.useRef)(null),T=(0,n.useRef)(null),E=(0,n.useRef)(null),{checkExperiment:L}=(0,_.F)(),B=(0,d.Z)(),M=e&&(0,h.C$)(Z),O=e&&!(0,h.C$)(Z),[R,D]=(0,h.C$)(Z)&&["red","gray"]||(0,h.uM)(Z)&&["transparent","gray"]||["gray","red"];return(0,j.Z)(()=>{let e=(0,u.Z)(()=>{var e;let t=(null===(e=document.getElementById("searchBoxContainer"))||void 0===e?void 0:e.offsetWidth)||0;C(t<=232)},100);return e(),window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)}),(0,n.useEffect)(()=>{if(O){let e=e=>{var t,i;let{target:n}=e;n instanceof Node&&!(null!==(t=E.current)&&void 0!==t&&t.contains(n))&&!(null!==(i=T.current)&&void 0!==i&&i.contains(n))&&x(!1)};return window.addEventListener("mousedown",e),function(){window.removeEventListener("mousedown",e)}}},[O]),(0,f.jsxs)(l.xu,{alignItems:"center",color:"default",direction:"row",display:"flex",height:w.Pw,justifyContent:"between",padding:4,ref:c,width:"100%",children:[(0,f.jsxs)(l.kC,{alignItems:"center",direction:"row",justifyContent:"start",children:[(0,f.jsx)(l.iP,{onTap:()=>{B({action:"click",item:"pinterest-logo",within:"unauth-header"})},children:(0,f.jsx)(l.xu,{"data-test-id":"unauth-header-logo",children:(0,f.jsx)(l.rU,{href:"/",target:"self",display:"inlineBlock",tapStyle:"compress",rounding:"pill",underline:"none",onClick:({dangerouslyDisableOnNavigation:e})=>e(),children:(0,f.jsxs)(l.xu,{display:"flex",alignItems:"center",direction:"row",paddingX:3,children:[(0,f.jsx)(l.JO,{accessibilityLabel:z._('Pinterest', 'Pinterest logo', 'Pinterest logo'),icon:"pinterest",size:M?32:24,color:"brandPrimary"}),e&&(0,f.jsx)(l.xu,{marginStart:1,dangerouslySetInlineStyle:{__style:{letterSpacing:"-1px"}},onClick:()=>{B({action:"click",item:"pinterest-logo"})},children:(0,f.jsx)(l.X6,{size:"400",color:"error",overflow:"normal",accessibilityLevel:M?1:2,children:z._('Pinterest', 'Company name', 'Company name')})})]})})})}),!(0,h.C$)(Z)&&e?(0,f.jsx)(y,{onClick:()=>{k(!b),(0,r.NC)("click_hub_dropdown_nav"),B({action:"click",item:"nav-bar-hub-dropdown"})},open:b,onDismiss:()=>k(!1)}):(0,f.jsx)(v,{isDesktop:e})]}),!(0,h.C$)(Z)&&(0,f.jsx)(l.xu,{display:"none",mdDisplay:"block",flex:"grow",paddingX:2,"data-test-id":"search-box-container",children:(0,f.jsx)(S.Z,{iconOnly:A,widthType:"auto"})}),(0,f.jsxs)(l.kC,{alignItems:"center",direction:"row",flex:"none",justifyContent:"start",children:[(0,h.C$)(Z)&&(0,f.jsxs)(l.xu,{display:"flex",alignItems:"center",justifyContent:"between",marginEnd:6,children:[(0,f.jsx)(l.xu,{margin:4,"data-test-id":"header-about-button",children:(0,f.jsx)(l.xv,{weight:"bold",children:(0,f.jsx)(l.rU,{href:"/_/_/about/",target:"blank",onClick:()=>{(0,r.My)("unauth.homepage_redesign.about_button_click"),B({action:"click",item:"header-about-button"})},children:z._('About', 'Link to page describing what Pinterest is.', 'Link to page describing what Pinterest is.')})})}),(0,f.jsx)(l.xu,{margin:4,"data-test-id":"header-business-button",children:(0,f.jsx)(l.xv,{weight:"bold",children:(0,f.jsx)(l.rU,{href:"/_/_/business/",target:"blank",onClick:()=>{(0,r.My)("unauth.homepage_redesign.business_button_click"),B({action:"click",item:"header-business-button"})},children:z._('Business', 'unauth.homepage.link', 'Link to the Pinterest business site.')})})}),(0,f.jsx)(l.xu,{margin:4,"data-test-id":"header-blog-button",children:(0,f.jsx)(l.xv,{weight:"bold",children:(0,f.jsx)(l.rU,{href:"/_/_/blog/",target:"blank",onClick:()=>{(0,r.My)("unauth.homepage_redesign.blog_button_click"),B({action:"click",item:"header-blog-button"})},children:z._('Blog', 'Link to the Pinterest business site.', 'Link to the Pinterest business site.')})})})]}),(0,f.jsx)(l.xu,{marginEnd:2,"data-test-id":M?"simple-login-button":"login-button",children:(0,f.jsx)(l.zx,{text:z._('Log in', 'Label for log in button', 'Label for log in button'),onClick:({event:e})=>i(e),size:M?"md":"lg",color:e&&L("pcons_login_primary_dweb").anyEnabled?e&&(0,h.uM)(Z)&&L("pcons_login_primary_dweb").group.includes("pin_page_secondary")?"gray":"red":R,ref:I})}),(!e||!L("pcons_login_primary_dweb").anyEnabled)&&(0,f.jsx)(l.xu,{"data-test-id":M?"simple-signup-button":"signup-button",children:(0,f.jsx)(l.zx,{text:s,onClick:e=>{t(e.event)},color:L("lex_follow_button").group.includes("main_cta")?"gray":D,size:M?"md":"lg"})}),O&&(0,f.jsxs)(n.Fragment,{children:[(0,f.jsx)(l.xu,{ref:T,children:(0,f.jsx)(l.xu,{display:"flex",marginStart:2,marginTop:3,marginBottom:3,justifyContent:"center","data-test-id":"setting-button",children:(0,f.jsx)(l.hU,{accessibilityLabel:z._('Setting', 'unauthHeaderBar.seetingsButton', 'Text for the setting button in the header'),icon:"arrow-down",size:"xs",onClick:({event:e})=>{e.preventDefault(),e.stopPropagation(),(0,r.NC)("click_header_setting"),B({action:"click",item:"setting-button"}),x(!m)},iconColor:"gray"})})}),m&&(0,f.jsx)(p.Z,{name:"SafeSuspense_UnauthHeader_UnauthSettingFlyout",children:(0,f.jsx)(g.Z,{fallback:(0,f.jsx)(l.xu,{}),children:(0,f.jsx)(l.xu,{ref:E,children:(0,f.jsx)(P,{anchor:T.current})})})})]},"settingButton")]})]})});k.displayName="UnauthHeader";var A=i(50286),C=i(598615),z=i(938917),Z=i(158989);function I({showDesktopSignupModal:e}){let t=(0,a.ZP)(),i=(0,A.ZP)(),u=(0,o.useHistory)(),p=(0,o.useLocation)(),h="desktop"===i,_=(0,z.Z)(),g=(0,d.Z)(),{viewType:m,viewParameter:x}=(0,s.SU)(),{trackConversionUpsell:b}=(0,c.Z)(),y=()=>{(0,r.My)("unauth.login_button.click"),(0,r.NC)("mweb_press_header_login"),g({action:"click",within:"unauth-header",item:"login-button"}),e?e("login"):(b({viewType:m,viewParameter:x,element:30,eventType:14688,component:14213,upsellReason:"click_login_on_header"}),u.push({pathname:"/login",state:{attributionLabel:"click_login_on_header",...p.state}}))};return(0,f.jsxs)(n.Fragment,{children:[(0,f.jsx)(l.xu,{"data-test-id":"unauth-header",position:"fixed",top:!0,width:"100%",zIndex:Z.Z,children:_?(0,f.jsx)(C.Z,{componentType:14161,app_upsell_type:"unauth-header",children:({handleOpenApp:e})=>(0,f.jsx)(k,{isDesktop:h,primaryButtonText:t._('Download app', 'mweb.unauth_header.download_app', 'CTA on the app interstitial upsell to install the app'),onLoginButtonClick:y,onPrimaryButtonClick:()=>e({deepLinkUri:"/"===p.pathname?p.pathname:p.pathname.substr(1)})})}):(0,f.jsx)(k,{isDesktop:h,primaryButtonText:t._('Sign up', 'Text on button on the top bar that leads users to signing up.', 'Text on button on the top bar that leads users to signing up.'),onLoginButtonClick:y,onPrimaryButtonClick:()=>{(0,r.My)("unauth.signup_button.click"),(0,r.NC)("mweb_press_header_signup"),g({action:"click",within:"unauth-header",item:"signup-button"}),e?e("signup"):(b({viewType:m,viewParameter:x,element:31,eventType:14688,component:14215,upsellReason:"click_signup_on_header"}),u.push({pathname:"/signup",state:{attributionLabel:"click_signup_on_header",...p.state}}))}})}),(0,f.jsx)(l.xu,{height:w.Pw})]})}},158989:(e,t,i)=>{i.d(t,{Z:()=>l});var n=i(883119);let o=new n.Ry(9999),l=o},143892:(e,t,i)=>{i.d(t,{Z:()=>r});var n=i(616550),o=i(436851),l=i(780280),s=i(826067),a=i(872482);let r=()=>{let e=(0,n.useLocation)(),t=(0,a.a)(),{locale:i,userAgent:{platform:r,raw:d}}=(0,l.B)();if(!t)return!1;let{appInstallBannerIsEnabled:c,pinPageGlobalContext:u}=t,p=!!(0,s.mB)(e.search).invite_code;return c&&!(0,o.$K)(d)&&!(i.includes("ar")&&"ios"!==r)&&!((null==u?void 0:u.isStoryPin)===!0&&p)}},893101:(e,t,i)=>{i.d(t,{Z:()=>g});var n=i(702664),o=i(616550),l=i(436851),s=i(53987),a=i(780280),r=i(339363),d=i(50286),c=i(938917),u=i(948376),p=i(56390),h=i(67347);let _=e=>!!(0,l.dh)(e)&&((0,r.qn)("ufausfiiab")||((0,h.nP)("unauth.floating_app_upsell.suppress_for_instagram_in_app_browser"),(0,r.Nh)("ufausfiiab","1")),!0),g=()=>{let{isBot:e}=(0,a.B)(),t=(0,o.useLocation)(),{userAgentPlatform:i,userAgent:l}=(0,n.useSelector)(e=>e.session),r=(0,c.Z)(),h=(0,d.ml)();return!(h&&!r)&&!(0,u.Rp)({isBot:e,platform:i,userAgent:l})&&((0,s.uM)(t)||(0,s.am)(t))&&!(0,p.P)()&&!_(l)}}}]);
|
252
|
+
//# sourceMappingURL=https://sm.pinimg.com/webapp/DesktopUnauthPageWrapper-a120f0b0faa773a2.mjs.map
|