(window.ansFrontendRelayWebpackJsonpFunction=window.ansFrontendRelayWebpackJsonpFunction||[]).push([["component-Modals-NUX"],{"+22L":function(e,n,t){"use strict";var a=t("QILm"),l=t.n(a),i=t("q1tI"),o=t("AaDK"),r=t("nW6E"),s=t("Yc5t"),u=t("jufJ"),c=function(e){var n=e.children,t=e.stepType,a=e.isLastStep,c=e.isNextButtonDisabled,d=e.isNextButtonHidden,p=e.triggerTransition,g=e.titleText,m=e.overriddenNextButtonText,f=l()(e,["children","stepType","isLastStep","isNextButtonDisabled","isNextButtonHidden","triggerTransition","titleText","overriddenNextButtonText"]);return i.createElement(r.f,Object.assign({navButton:"none"},f,{primaryButtonProps:!d&&{text:m||Object(u.plaintextTranslate)(a?"Done":"Next"),onClick:p,disabled:c},titleText:a?Object(u.plaintextTranslate)("One Last Step"):g}),i.createElement(s.a,{onImpression:function(){Object(o.a)("nux_step_impression",{step_name:t})}},n))};c.displayName="NUXModalLayout",n.a=c},SA9J:function(e,n,t){"use strict";t.r(n);var a={};t.r(a),t.d(a,"default",(function(){return w}));var l=t("RIqP"),i=t.n(l),o=t("lwsE"),r=t.n(o),s=t("W8MJ"),u=t.n(s),c=t("7W2i"),d=t.n(c),p=t("a1gu"),g=t.n(p),m=t("Nsbk"),f=t.n(m),k=function(){var e=[{kind:"LocalArgument",name:"stepType",type:"String!",defaultValue:null}],n=[{kind:"Variable",name:"stepType",variableName:"stepType"}],t={kind:"ScalarField",alias:null,name:"id",args:null,storageKey:null},a={kind:"ScalarField",alias:null,name:"__typename",args:null,storageKey:null},l={kind:"ScalarField",alias:null,name:"minTopicsToFollowForNuxStepCompletion",args:null,storageKey:null},i={platforms:["DESKTOP"]},o={kind:"Condition",passingValue:!0,isCustom:!0,customValue:i,condition:"onPlatform",selections:[{kind:"LinkedField",alias:null,name:"viewer",storageKey:null,args:null,concreteType:"Viewer",plural:!1,selections:[t,a,{kind:"LinkedField",alias:null,name:"user",storageKey:null,args:null,concreteType:"User",plural:!1,selections:[t,a,{kind:"ScalarField",alias:null,name:"numFollowedTopics",args:null,storageKey:null}]}]}]},r=[{kind:"Literal",name:"after",value:""},{kind:"Literal",name:"first",value:30},{kind:"Literal",name:"shownTids",value:[]},{kind:"Literal",name:"suggestionSeedTids",value:[]}];return{kind:"Request",fragment:{kind:"Fragment",name:"FollowInterestsStepQuery",type:"QueryRoot",metadata:null,argumentDefinitions:e,selections:[{kind:"LinkedField",alias:null,name:"nuxStep",storageKey:null,args:n,concreteType:null,plural:!1,selections:[t,a,{kind:"InlineFragment",type:"FollowInterestsStep",selections:[l,{kind:"FragmentSpread",name:"FollowInterestsStepList_followInterestsStep",args:null},o]}]}]},operation:{kind:"Operation",name:"FollowInterestsStepQuery",argumentDefinitions:e,selections:[{kind:"LinkedField",alias:null,name:"nuxStep",storageKey:null,args:n,concreteType:null,plural:!1,selections:[t,a,{kind:"InlineFragment",type:"FollowInterestsStep",selections:[l,{kind:"LinkedField",alias:null,name:"topicSuggestionsConnection",storageKey:'topicSuggestionsConnection(after:"",first:30,shownTids:[],suggestionSeedTids:[])',args:r,concreteType:"TopicSuggestionsConnection",plural:!1,selections:[t,a,{kind:"LinkedField",alias:null,name:"pageInfo",storageKey:null,args:null,concreteType:"PageInfo",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"endCursor",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"hasNextPage",args:null,storageKey:null}]},{kind:"LinkedField",alias:null,name:"edges",storageKey:null,args:null,concreteType:"TopicEdge",plural:!0,selections:[t,a,{kind:"LinkedField",alias:null,name:"node",storageKey:null,args:null,concreteType:"Topic",plural:!1,selections:[t,a,{kind:"ScalarField",alias:null,name:"tid",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"isFollowing",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"name",args:null,storageKey:null},{kind:"Condition",passingValue:!0,isCustom:!0,customValue:i,condition:"onPlatform",selections:[{kind:"ScalarField",alias:null,name:"photoUrl",args:[{kind:"Literal",name:"size",value:200}],storageKey:"photoUrl(size:200)"}]}]},{kind:"ScalarField",alias:null,name:"cursor",args:null,storageKey:null}]}]},{kind:"LinkedHandle",alias:null,name:"topicSuggestionsConnection",args:r,handle:"connection",key:"FollowInterestsStepList_topicSuggestionsConnection",filters:[]},o]}]}]},params:{operationKind:"query",name:"FollowInterestsStepQuery",id:"29eb57b1c6472b82bacfda421211a69054efd83b69320d8ea9cd07185b117385",text:null,metadata:{}}}}();k.hash="fe5d9b796c89f945084d9ce2cdc8ca68";var y,w=k,S=t("q1tI"),F=t("jufJ"),h=t("RA+f"),v=t("AaDK"),T=t("+22L"),b=t("nwxp"),L=t("Xqoj"),_=t("/bbo");function x(e){var n=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var t,a=f()(e);if(n){var l=f()(this).constructor;t=Reflect.construct(a,arguments,l)}else t=a.apply(this,arguments);return g()(this,t)}}var I=!1,C=function(e){d()(t,e);var n=x(t);function t(e){var a,l,i,o,s;return r()(this,t),(s=n.call(this,e)).state={tidsFollowed:new Set,stepFollowedTopicsCount:Object(b.c)()&&null!==(a=null===(l=s.props.queryResult.nuxStep)||void 0===l||null===(i=l.viewer)||void 0===i||null===(o=i.user)||void 0===o?void 0:o.numFollowedTopics)&&void 0!==a?a:0},s}return u()(t,[{key:"render",value:function(){var e=this;if(!this.props.queryResult.nuxStep)throw Error("nuxStep of Query Result is expected for FollowInterestsStep.");var n=this.props.queryResult.nuxStep.minTopicsToFollowForNuxStepCompletion;if(!n)throw Error("minTopicsToFollowForNuxStepCompletion of Query Result is expected for FollowInterestsStep.");var t=Math.max(0,n-this.state.stepFollowedTopicsCount);I||0!==t||(Object(v.a)("nux_follow_topics_next_button_enabled",{framework:"react"}),I=!0);var a=t>0?S.createElement(F.Translate,null,"Follow ",S.createElement(F.FormattedNumber,{value:t})," more",S.createElement(F.PluralTranslate,{value:t},{ONE:" topic",OTHER:" topics"}),Object(b.c)()&&" to continue"):Object(F.plaintextTranslate)(this.props.flowData.isLastStep?"Done":"Next");return S.createElement(T.a,{titleText:Object(b.c)()?Object(F.plaintextTranslate)("What are your interests?"):Object(F.plaintextTranslate)("Follow topics"),isLastStep:this.props.flowData.isLastStep,triggerTransition:this.props.triggerTransition,stepType:"follow_interests",isNextButtonDisabled:t>0,hasPadding:Object(b.c)(),overriddenNextButtonText:Object(b.c)()?a:undefined},S.createElement(h.e,{className:"puppeteer_test_follow_interests_step",mb:Object(b.f)()?"44px":undefined},Object(b.f)()&&S.createElement(h.e,{p:"medium"},S.createElement(F.Translate,null,"You are almost done. Select at least"," ",S.createElement(F.FormattedNumber,{value:n})," ",S.createElement(F.PluralTranslate,{value:n},{ONE:"topic",OTHER:"topics"})," ","so we can show you stories you might like.")),S.createElement(L.a,{followInterestsStep:this.props.queryResult.nuxStep,onTopicClicked:function(n,t){e.setState((function(e){return{tidsFollowed:t?new Set([].concat(i()(e.tidsFollowed),[n])):new Set(i()(e.tidsFollowed).filter((function(e){return e!=n}))),stepFollowedTopicsCount:e.stepFollowedTopicsCount+(t?1:-1)}}))}})),Object(b.f)()&&S.createElement(h.i,{bg:"white",fullX:!0,zIndex:"footer",bottom:0,p:"medium",boxShadow:"0 -5px 5px #fff"},S.createElement(_.a,{isFullWidth:!0,text:a,onClick:this.props.triggerTransition,disabled:t>0})))}}]),t}(S.Component);C.queries={onLoad:void 0!==y?y:y=a},C.displayName="FollowInterestsStep";n["default"]=C},VMwC:function(e,n,t){"use strict";t.r(n),t.d(n,"default",(function(){return R}));var a={};t.r(a),t.d(a,"default",(function(){return w}));var l={};t.r(l),t.d(l,"default",(function(){return v}));var i=t("RIqP"),o=t.n(i),r=t("lwsE"),s=t.n(r),u=t("W8MJ"),c=t.n(u),d=t("7W2i"),p=t.n(d),g=t("a1gu"),m=t.n(g),f=t("Nsbk"),k=t.n(f),y=function(){var e=[{kind:"LocalArgument",name:"languageCodes",type:"[String!]!",defaultValue:null}],n=[{kind:"LinkedField",alias:null,name:"languagesAddAndRelevantTopicsFollow",storageKey:null,args:[{kind:"Variable",name:"languageCodes",variableName:"languageCodes"}],concreteType:"LanguagesAddAndRelevantTopicsFollow",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"success",args:null,storageKey:null}]}];return{kind:"Request",fragment:{kind:"Fragment",name:"LanguageStep_languagesAddAndRelevantTopicsFollow_Mutation",type:"MutationRoot",metadata:null,argumentDefinitions:e,selections:n},operation:{kind:"Operation",name:"LanguageStep_languagesAddAndRelevantTopicsFollow_Mutation",argumentDefinitions:e,selections:n},params:{operationKind:"mutation",name:"LanguageStep_languagesAddAndRelevantTopicsFollow_Mutation",id:"2e7aa926bbb9cab812403c9b859af95dd77f8bc2f515b32d05ecb4f260aa0570",text:null,metadata:{}}}}();y.hash="10f47c3a7fef6a27faf1c7a0087f0b34";var w=y,S=function(){var e=[{kind:"LocalArgument",name:"stepType",type:"String!",defaultValue:null}],n={kind:"ScalarField",alias:null,name:"id",args:null,storageKey:null},t={kind:"ScalarField",alias:null,name:"__typename",args:null,storageKey:null},a=[{kind:"LinkedField",alias:null,name:"nuxStep",storageKey:null,args:[{kind:"Variable",name:"stepType",variableName:"stepType"}],concreteType:null,plural:!1,selections:[n,t,{kind:"InlineFragment",type:"LanguageStep",selections:[{kind:"ScalarField",alias:null,name:"orderedWorldTopLanguageCodes",args:null,storageKey:null}]}]},{kind:"LinkedField",alias:null,name:"viewer",storageKey:null,args:null,concreteType:"Viewer",plural:!1,selections:[n,t,{kind:"ScalarField",alias:null,name:"preferredLanguageCodes",args:null,storageKey:null}]},{kind:"LinkedField",alias:null,name:"network",storageKey:null,args:null,concreteType:"Network",plural:!1,selections:[n,t,{kind:"ScalarField",alias:null,name:"contentLanguageCode",args:null,storageKey:null}]}];return{kind:"Request",fragment:{kind:"Fragment",name:"LanguageStepQuery",type:"QueryRoot",metadata:null,argumentDefinitions:e,selections:a},operation:{kind:"Operation",name:"LanguageStepQuery",argumentDefinitions:e,selections:a},params:{operationKind:"query",name:"LanguageStepQuery",id:"42d4a27d7838b064f4eb5722e512e9093ff2bd4ebe54c52d8ab38753289c6091",text:null,metadata:{}}}}();S.hash="81aef9c5d5e8525dad774443a556353e";var F,h,v=S,T=t("q1tI"),b=t("VyO/"),L=t("jufJ"),_=t("MI6j"),x=t("06DM"),I=t("cBSy"),C=t("RA+f"),K=t("rAPm"),E=t("+22L");function O(e){var n=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var t,a=k()(e);if(n){var l=k()(this).constructor;t=Reflect.construct(a,arguments,l)}else t=a.apply(this,arguments);return m()(this,t)}}var R=function(e){p()(t,e);var n=O(t);function t(e){var a,l,i,o;s()(this,t),(o=n.call(this,e)).userLanguageCodes=void 0,o.restOfWorldLanguageCodes=void 0;var r=o.props.queryResult,u=null===(a=r.network)||void 0===a?void 0:a.contentLanguageCode,c=null!==(l=null===(i=r.nuxStep)||void 0===i?void 0:i.orderedWorldTopLanguageCodes)&&void 0!==l?l:[],d=r.viewer.preferredLanguageCodes;return o.userLanguageCodes=d.filter((function(e){return e!==u&&Object(L.isLanguageNameSupported)(e)})),o.restOfWorldLanguageCodes=c.filter((function(e){return e!==u&&!d.includes(e)})),o.state={checkedLanguages:o.userLanguageCodes.map((function(e){return e.toUpperCase()}))},o}return c()(t,[{key:"handleListItemClick",value:function(e){this.state.checkedLanguages.includes(e)?this.setState((function(n){return{checkedLanguages:n.checkedLanguages.filter((function(n){return n!==e}))}})):this.setState((function(n){return{checkedLanguages:[].concat(o()(n.checkedLanguages),[e])}}))}},{key:"render",value:function(){var e=this,n=function(n){return T.createElement(C.e,{className:"puppeteer_test_language_list_item",key:n},T.createElement(_.c,{key:n,mainText:T.createElement(L.LanguageName,{languageCode:n}),subText:T.createElement(L.LanguageName,{languageCode:n,nativeName:!0}),variant:"check",selected:e.state.checkedLanguages.includes(n.toUpperCase()),size:"dense",onClick:function(){e.handleListItemClick(n.toUpperCase())}}))};return T.createElement(b.a,{mutation:t.mutations.addLanguagesAndFollowRelevantTopicsMutation,variables:{languageCodes:this.state.checkedLanguages}},(function(t){return T.createElement(E.a,{titleText:Object(L.plaintextTranslate)("Add Languages"),isLastStep:e.props.flowData.isLastStep,hasPadding:!1,triggerTransition:function(){t(),e.props.triggerTransition()},stepType:"language"},T.createElement(C.e,{className:"puppeteer_test_language_step"},T.createElement(C.e,{p:"medium"},T.createElement(L.Translate,null,"What other languages do you know?")),e.userLanguageCodes.length>0&&T.createElement("div",null,T.createElement(x.a,{borderBottom:!1,titleText:Object(L.plaintextTranslate)("Suggested from browser settings")}),T.createElement(C.e,{className:"puppeteer_test_user_language_list"},T.createElement(I.a,null,e.userLanguageCodes.map(n))),T.createElement(x.a,{borderBottom:!1,titleText:Object(L.plaintextTranslate)("More languages")})),T.createElement(C.e,{className:"puppeteer_test_world_language_list"},T.createElement(I.a,null,e.restOfWorldLanguageCodes.map(n))),T.createElement(K.a,{mt:"tiny",mb:"small",px:"medium"},T.createElement(L.Translate,null,"Don't see your language here? You can add more languages from your profile page later."))))}))}}]),t}(T.Component);R.queries={onLoad:void 0!==F?F:F=l},R.mutations={addLanguagesAndFollowRelevantTopicsMutation:void 0!==h?h:h=a},R.displayName="LanguageStep"},Xqoj:function(e,n,t){"use strict";var a={};t.r(a),t.d(a,"default",(function(){return h}));var l={};t.r(l),t.d(l,"default",(function(){return T}));var i={};t.r(i),t.d(i,"default",(function(){return O}));var o={};t.r(o),t.d(o,"default",(function(){return j}));var r={};t.r(r),t.d(r,"default",(function(){return q}));var s=t("RIqP"),u=t.n(s),c=t("lwsE"),d=t.n(c),p=t("W8MJ"),g=t.n(p),m=t("7W2i"),f=t.n(m),k=t("a1gu"),y=t.n(k),w=t("Nsbk"),S=t.n(w),F=function(){var e=[{kind:"LocalArgument",name:"first",type:"Int",defaultValue:null},{kind:"LocalArgument",name:"cursor",type:"String",defaultValue:null},{kind:"LocalArgument",name:"shownTids",type:"[BigInt!]!",defaultValue:null},{kind:"LocalArgument",name:"suggestionSeedTids",type:"[BigInt!]!",defaultValue:null}],n=[{kind:"Literal",name:"stepType",value:"follow_interests"}],t={kind:"ScalarField",alias:null,name:"id",args:null,storageKey:null},a={kind:"ScalarField",alias:null,name:"__typename",args:null,storageKey:null},l={kind:"ScalarField",alias:null,name:"tid",args:null,storageKey:null},i={kind:"ScalarField",alias:null,name:"cursor",args:null,storageKey:null},o={kind:"LinkedField",alias:null,name:"pageInfo",storageKey:null,args:null,concreteType:"PageInfo",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"endCursor",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"hasNextPage",args:null,storageKey:null}]},r=[{kind:"Variable",name:"after",variableName:"cursor"},{kind:"Variable",name:"first",variableName:"first"},{kind:"Variable",name:"shownTids",variableName:"shownTids"},{kind:"Variable",name:"suggestionSeedTids",variableName:"suggestionSeedTids"}];return{kind:"Request",fragment:{kind:"Fragment",name:"FollowInterestsStepListQuery",type:"QueryRoot",metadata:null,argumentDefinitions:e,selections:[{kind:"LinkedField",alias:null,name:"nuxStep",storageKey:'nuxStep(stepType:"follow_interests")',args:n,concreteType:null,plural:!1,selections:[t,a,{kind:"InlineFragment",type:"FollowInterestsStep",selections:[{kind:"LinkedField",alias:"topicSuggestionsConnection",name:"__FollowInterestsStepList_topicSuggestionsConnection_connection",storageKey:null,args:null,concreteType:"TopicSuggestionsConnection",plural:!1,selections:[t,a,{kind:"LinkedField",alias:null,name:"edges",storageKey:null,args:null,concreteType:"TopicEdge",plural:!0,selections:[t,a,{kind:"LinkedField",alias:null,name:"node",storageKey:null,args:null,concreteType:"Topic",plural:!1,selections:[t,a,l,{kind:"FragmentSpread",name:"FollowInterestsListItem_topic",args:null}]},i]},o]}]}]}]},operation:{kind:"Operation",name:"FollowInterestsStepListQuery",argumentDefinitions:e,selections:[{kind:"LinkedField",alias:null,name:"nuxStep",storageKey:'nuxStep(stepType:"follow_interests")',args:n,concreteType:null,plural:!1,selections:[t,a,{kind:"InlineFragment",type:"FollowInterestsStep",selections:[{kind:"LinkedField",alias:null,name:"topicSuggestionsConnection",storageKey:null,args:r,concreteType:"TopicSuggestionsConnection",plural:!1,selections:[t,a,{kind:"LinkedField",alias:null,name:"edges",storageKey:null,args:null,concreteType:"TopicEdge",plural:!0,selections:[t,a,{kind:"LinkedField",alias:null,name:"node",storageKey:null,args:null,concreteType:"Topic",plural:!1,selections:[t,a,l,{kind:"ScalarField",alias:null,name:"isFollowing",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"name",args:null,storageKey:null},{kind:"Condition",passingValue:!0,isCustom:!0,customValue:{platforms:["DESKTOP"]},condition:"onPlatform",selections:[{kind:"ScalarField",alias:null,name:"photoUrl",args:[{kind:"Literal",name:"size",value:200}],storageKey:"photoUrl(size:200)"}]}]},i]},o]},{kind:"LinkedHandle",alias:null,name:"topicSuggestionsConnection",args:r,handle:"connection",key:"FollowInterestsStepList_topicSuggestionsConnection",filters:[]}]}]}]},params:{operationKind:"query",name:"FollowInterestsStepListQuery",id:"6b32e96ccc2f362c6a5d081cf00a68646a2c6c34a47e7f9e2f9897e412428ab1",text:null,metadata:{connection:[{count:"first",cursor:"cursor",direction:"forward",path:["nuxStep","topicSuggestionsConnection"]}]}}}}();F.hash="354cced29756adf1af3fba7d4e049e06";var h=F,v=function(){var e={kind:"ScalarField",alias:null,name:"id",args:null,storageKey:null},n={kind:"ScalarField",alias:null,name:"__typename",args:null,storageKey:null};return{kind:"Fragment",name:"FollowInterestsStepList_followInterestsStep",type:"FollowInterestsStep",metadata:{connection:[{count:null,cursor:null,direction:"forward",path:["topicSuggestionsConnection"]}]},argumentDefinitions:[],selections:[e,n,{kind:"LinkedField",alias:"topicSuggestionsConnection",name:"__FollowInterestsStepList_topicSuggestionsConnection_connection",storageKey:null,args:null,concreteType:"TopicSuggestionsConnection",plural:!1,selections:[e,n,{kind:"LinkedField",alias:null,name:"pageInfo",storageKey:null,args:null,concreteType:"PageInfo",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"endCursor",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"hasNextPage",args:null,storageKey:null}]},{kind:"LinkedField",alias:null,name:"edges",storageKey:null,args:null,concreteType:"TopicEdge",plural:!0,selections:[e,n,{kind:"LinkedField",alias:null,name:"node",storageKey:null,args:null,concreteType:"Topic",plural:!1,selections:[e,n,{kind:"ScalarField",alias:null,name:"tid",args:null,storageKey:null},{kind:"FragmentSpread",name:"FollowInterestsListItem_topic",args:null}]},{kind:"ScalarField",alias:null,name:"cursor",args:null,storageKey:null}]}]}]}}();v.hash="381661c4d2dfab933481ff97d41f2074";var T=v,b=t("q1tI"),L=t("VyO/"),_=t("cBSy"),x=t("m+xM"),I=t("nwxp"),C=t("RA+f"),K=t("vOnD"),E=function(){var e=[{kind:"LocalArgument",name:"tid",type:"BigInt!",defaultValue:null}],n=[{kind:"LinkedField",alias:null,name:"topicFollowRemove",storageKey:null,args:[{kind:"Variable",name:"tid",variableName:"tid"}],concreteType:"TopicFollowRemove",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"topic",storageKey:null,args:null,concreteType:"Topic",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"id",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"__typename",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"isFollowing",args:null,storageKey:null}]}]}];return{kind:"Request",fragment:{kind:"Fragment",name:"FollowInterestsListItem_topicFollowRemove_Mutation",type:"MutationRoot",metadata:null,argumentDefinitions:e,selections:n},operation:{kind:"Operation",name:"FollowInterestsListItem_topicFollowRemove_Mutation",argumentDefinitions:e,selections:n},params:{operationKind:"mutation",name:"FollowInterestsListItem_topicFollowRemove_Mutation",id:"cc78e3eb864882990fa34ed759c3dce5d3080001cb9f4a162e65431f1194f468",text:null,metadata:{}}}}();E.hash="c4e37b4e1954424c2071dad13d4bd313";var O=E,R=function(){var e=[{kind:"LocalArgument",name:"tid",type:"BigInt!",defaultValue:null}],n=[{kind:"LinkedField",alias:null,name:"topicFollowAdd",storageKey:null,args:[{kind:"Variable",name:"tid",variableName:"tid"},{kind:"Literal",name:"useInNux",value:!0}],concreteType:"TopicFollowAdd",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"topic",storageKey:null,args:null,concreteType:"Topic",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"id",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"__typename",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"isFollowing",args:null,storageKey:null}]}]}];return{kind:"Request",fragment:{kind:"Fragment",name:"FollowInterestsListItem_topicFollowAdd_Mutation",type:"MutationRoot",metadata:null,argumentDefinitions:e,selections:n},operation:{kind:"Operation",name:"FollowInterestsListItem_topicFollowAdd_Mutation",argumentDefinitions:e,selections:n},params:{operationKind:"mutation",name:"FollowInterestsListItem_topicFollowAdd_Mutation",id:"2f6bdedcee2abebe813641303eb27506420afe4210e989f7adbee1cc2489db07",text:null,metadata:{}}}}();R.hash="f4de94c1abac5e73983ed82ad050b401";var N,A,D,j=R,M={kind:"Fragment",name:"FollowInterestsListItem_topic",type:"Topic",metadata:null,argumentDefinitions:[],selections:[{kind:"ScalarField",alias:null,name:"id",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"__typename",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"isFollowing",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"tid",args:null,storageKey:null},{kind:"Condition",passingValue:!0,isCustom:!0,customValue:{platforms:["DESKTOP"]},condition:"onPlatform",selections:[{kind:"ScalarField",alias:null,name:"photoUrl",args:[{kind:"Literal",name:"size",value:200}],storageKey:"photoUrl(size:200)"}]},{kind:"FragmentSpread",name:"TopicName_topic",args:null}],hash:"77518a0bf125489e76de46d9fcba6a60"},q=M,V=t("cecZ"),P=t("MI6j"),B=t("OMLc");function W(e){var n=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var t,a=S()(e);if(n){var l=S()(this).constructor;t=Reflect.construct(a,arguments,l)}else t=a.apply(this,arguments);return y()(this,t)}}var z=Object(K["default"])(C.f).withConfig({displayName:"FollowInterestsListItem___StyledClickWrapper",componentId:"li8d0a-0"})(["background-image:url(",');background-position:center;background-size:cover;&:after{content:" ";display:block;padding-bottom:100%;background-color:rgba(0,0,0,0.3);transition:background-color ease 180ms;border-radius:inherit;}&:hover:after{background-color:rgba(0,0,0,0.45);}'],(function(e){return e._css})),Q=Object(K["default"])(C.g).withConfig({displayName:"FollowInterestsListItem___StyledCssComponent",componentId:"li8d0a-1"})(["transition-delay:",";"],(function(e){return e._css2})),U=function(e){f()(t,e);var n=W(t);function t(e){var a;return d()(this,t),(a=n.call(this,e)).onClick=function(e){var n=a.props.topic.tid,t=a.state.isFollowing;e(),a.props.onClick(n,!t),a.setState({isFollowing:!t})},a.state={isFollowing:a.props.topic.isFollowing},a}return g()(t,[{key:"getMutationOptions",value:function(){var e=this.props.topic,n=e.tid,a=this.state.isFollowing,l=a?t.mutations.topicFollowRemoveMutation:t.mutations.topicFollowAddMutation,i={tid:n},o={id:e.id,__typename:e.__typename,isFollowing:!a};return{mutation:l,variables:i,optimisticResponse:a?{topicFollowRemove:{topic:o}}:{topicFollowAdd:{topic:o}}}}},{key:"shouldComponentUpdate",value:function(e,n){return this.state.isFollowing!==n.isFollowing}},{key:"render",value:function(){var e=this,n=this.props,t=n.topic,a=n.itemSize,l=t.photoUrl,i=this.state.isFollowing;return b.createElement(L.a,this.getMutationOptions(),(function(n){return Object(I.c)()?b.createElement(z,{className:"puppeteer_test_follow_interests_list_item",onClick:function(){e.onClick(n)},position:"relative",flexBasis:"calc(".concat(16.6,"% - 8px)"),m:"tiny",bg:"black",boxShadow:"inset 0 -40px 20px rgba(0, 0, 0, 0.5), inset 0 0 0 1px rgba(0,0,0,.1)",borderRadius:"small",userSelect:"none",_css:l},b.createElement(C.a,{bottom:"0",p:"tiny"},b.createElement(C.s,{bold:!0,color:"white",lineHeight:1.3,fontSize:"small",truncateLines:4},b.createElement(V.a,{topic:t}))),b.createElement(C.a,{borderRadius:"circle",top:"tiny",right:"tiny",p:"tiny",bg:i?"blue":"rgba(255, 255, 255, 0.75)",boxShadow:i?undefined:"inset 0 2px 4px rgba(0,0,0,.1), 0 0 0 1px rgba(0,0,0,.1)",size:32,transitionProperty:"background-color",transitionDuration:"50ms",transitionTimingFunction:"ease-out"},b.createElement(C.c,{"in":i},(function(e){return b.createElement(Q,{animation:e,fadeIn:!0,fadeOut:!0,scaleIn:!0,scaleOut:!0,_css2:"entered"===e.state?"100ms":0},b.createElement(B.b,{color:"white",name:"Checkmark"}))})))):b.createElement(C.e,{className:"puppeteer_test_follow_interests_list_item",width:"100%"},b.createElement(P.c,{onClick:function(){e.onClick(n)},mainText:b.createElement(V.a,{topic:t}),variant:"check",selected:i,size:a||"regular"}))}))}}]),t}(b.Component);U.fragments={topic:void 0!==N?N:N=r},U.mutations={topicFollowAddMutation:void 0!==A?A:A=o,topicFollowRemoveMutation:void 0!==D?D:D=i},U.displayName="FollowInterestsListItem";var J,H,X=Object(L.b)(U);function Y(e){var n=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var t,a=S()(e);if(n){var l=S()(this).constructor;t=Reflect.construct(a,arguments,l)}else t=a.apply(this,arguments);return y()(this,t)}}var G=function(e){f()(t,e);var n=Y(t);function t(e){var a;return d()(this,t),(a=n.call(this,e)).alreadyFetchedTids=new Set,a.checkedTids=new Set,a.itemSize=void 0,a.itemSize="regular",a}return g()(t,[{key:"onTopicClicked",value:function(e,n,t,a){var l,i;n?this.alreadyFetchedTids.has(e)||(this.checkedTids.add(e),t&&a()):this.checkedTids["delete"](e),null===(l=(i=this.props).onTopicClicked)||void 0===l||l.call(i,e,n)}},{key:"getSeedTids",value:function(){var e=this;return u()(this.checkedTids).filter((function(n){return!e.alreadyFetchedTids.has(n)}))}},{key:"getVariables",value:function(){var e=this.getSeedTids();return this.alreadyFetchedTids=new Set([].concat(u()(this.alreadyFetchedTids),u()(e))),{shownTids:this.props.followInterestsStep.topicSuggestionsConnection.edges.map((function(e){return e.node.tid})),suggestionSeedTids:e}}},{key:"render",value:function(){var e,n,t=this,a=this.props,l=a.followInterestsStep,i=a.relay;if(0===(null!==(e=null===(n=l.topicSuggestionsConnection.edges)||void 0===n?void 0:n.length)&&void 0!==e?e:0))return null;var o=function(e){i?i.refetchConnection(30,null,{seedTids:t.getSeedTids()}):e()};return b.createElement(x.a,{relayObject:i,autoPaged:{enabled:!1},pagingIndicator:undefined,prefetchingEnabled:!1,connection:l.topicSuggestionsConnection,animated:!Object(I.c)(),listWrapper:function(e){return Object(I.c)()?b.createElement(C.j,{flexWrap:"wrap",m:"n_tiny"},e):b.createElement(_.a,null,e)}},(function(e){var n=e.index,a=e.readyToLoadMore,l=e.loadMore,i=e.node;return 0===n&&a&&t.getSeedTids().length>0&&o(l),b.createElement(X,{key:i.tid,topic:i,itemSize:Object(I.c)()?undefined:t.itemSize,onClick:function(e,n){t.onTopicClicked(e,n,a,(function(){return o(l)}))}})}))}}]),t}(b.Component);G.fragments={followInterestsStep:void 0!==J?J:J=l},G.queries={loadMore:void 0!==H?H:H=a},G.connectionConfig={direction:"forward",getConnectionFromProps:function(e){return e.followInterestsStep&&e.followInterestsStep.topicSuggestionsConnection},getVariables:function(e,n,t){return{count:n.count,cursor:String(e.followInterestsStep.topicSuggestionsConnection.edges.length-1),shownTids:e.followInterestsStep.topicSuggestionsConnection.edges.map((function(e){return e.node.tid})),suggestionSeedTids:t.seedTids}},query:G.queries.loadMore},G.displayName="FollowInterestsStepList";n.a=Object(L.d)(G)},aMaN:function(e,n,t){"use strict";t.r(n),t.d(n,"default",(function(){return K}));var a={};t.r(a),t.d(a,"default",(function(){return k}));var l=t("lwsE"),i=t.n(l),o=t("W8MJ"),r=t.n(o),s=t("7W2i"),u=t.n(s),c=t("a1gu"),d=t.n(c),p=t("Nsbk"),g=t.n(p),m=function(){var e={kind:"ScalarField",alias:null,name:"trackId",args:null,storageKey:null},n={kind:"ScalarField",alias:null,name:"linkData",args:null,storageKey:null};return{kind:"Request",fragment:{kind:"Fragment",name:"DownloadAppStepQuery",type:"QueryRoot",metadata:null,argumentDefinitions:[],selections:[{kind:"LinkedField",alias:null,name:"viewInAppLink",storageKey:null,args:null,concreteType:"ViewInAppLink",plural:!1,selections:[e,n]}]},operation:{kind:"Operation",name:"DownloadAppStepQuery",argumentDefinitions:[],selections:[{kind:"LinkedField",alias:null,name:"viewInAppLink",storageKey:null,args:null,concreteType:"ViewInAppLink",plural:!1,selections:[e,n,{kind:"ScalarField",alias:null,name:"id",args:null,storageKey:null}]}]},params:{operationKind:"query",name:"DownloadAppStepQuery",id:"0755e5d378bd193b921cb0c0d96e26e793da0d28fd5ce52391226f8785f71ad9",text:null,metadata:{}}}}();m.hash="442464490f138d86b4492a667d0c83f8";var f,k=m,y=t("q1tI"),w=t("jufJ"),S=t("zLpq"),F=t("/bbo"),h=t("RA+f"),v=t("UyMh"),T=t("nwxp"),b=t("T5JH"),L=t("SKAY"),_=t("AaDK"),x=t("zXuH"),I=t("+22L");function C(e){var n=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var t,a=g()(e);if(n){var l=g()(this).constructor;t=Reflect.construct(a,arguments,l)}else t=a.apply(this,arguments);return d()(this,t)}}var K=function(e){u()(t,e);var n=C(t);function t(e){var a;return i()(this,t),(a=n.call(this,e)).deepLinkInfo=void 0,a.deepLinkGenerator=void 0,a.logEvent=function(e){var n=a.getDownloadAppLinkNuxStepInfo();n&&Object(_.a)("mweb_view_in_app_link_logger",{step:e,component:n.viewInAppLinkType,url:n.referrerLink,controller:Object(L.getSetting)("controller"),action:Object(L.getSetting)("action"),deepLinkId:n.deepLinkId,deepLink:n.deepLink,provider:n.provider})},a.getLinkToStore=function(){return a.getDownloadAppLinkNuxStepInfo().deepLink},a.onDownloadAppLinkClicked=function(){a.logEvent("click"),Object(v.b)(a.getLinkToStore())},a.deepLinkGenerator=new x.a(e.queryResult.viewInAppLink.trackId),a}return r()(t,[{key:"getDownloadAppLinkNuxStepInfo",value:function(){if(this.deepLinkInfo)return this.deepLinkInfo;var e=JSON.parse(this.props.queryResult.viewInAppLink.linkData),n=this.deepLinkGenerator.getDeepLinkInfo({linkType:x.b.DOWNLOAD_APP_LINK_NUX_STEP,extraData:e});return this.deepLinkInfo=n,n}},{key:"componentDidMount",value:function(){this.logEvent("show")}},{key:"render",value:function(){var e=this;return y.createElement(I.a,{titleText:Object(w.plaintextTranslate)("Download App"),isLastStep:this.props.flowData.isLastStep,triggerTransition:this.props.triggerTransition,isNextButtonHidden:!0,stepType:"download_app"},y.createElement(h.e,{className:"puppeteer_test_download_app_step"},y.createElement(h.f,{width:"100%",onClick:this.onDownloadAppLinkClicked},y.createElement(b.a,{height:"250px",bgSize:"contain",bgColor:"white",src:T.p?"//qsf.fs.quoracdn.net/-4-ans_frontend_assets.images.app_download.app_download_ios.png-26-c0bc38376fde4e13.png":"//qsf.fs.quoracdn.net/-4-ans_frontend_assets.images.app_download.app_download_android.png-26-fb6779583c415b11.png",mb:"medium"})),y.createElement(h.e,{textAlign:"center"},y.createElement(h.s,{bold:!0,fontSize:"large"},y.createElement(w.Translate,null,"There's more to see"))),y.createElement(h.e,{textAlign:"center",mb:"medium"},y.createElement(w.Translate,null,"We are always updating the Quora app to be better than ever before. Take a look!")),y.createElement(F.a,{text:T.p?Object(w.plaintextTranslate)("Download the iOS app"):Object(w.plaintextTranslate)("Download the Android app"),isFullWidth:!0,mb:"small",onClick:this.onDownloadAppLinkClicked,className:"puppeteer_test_download_app_button"}),y.createElement(S.a,{text:Object(w.plaintextTranslate)("Not now"),onClick:function(){return e.props.triggerTransition()},className:"puppeteer_test_skip_download_button",isFullWidth:!0})))}}]),t}(y.Component);K.queries={onLoad:void 0!==f?f:f=a},K.displayName="DownloadAppStep"},"cPp+":function(e,n,t){"use strict";t.r(n);var a=t("q1tI"),l=t("jufJ"),i=t("EFAP"),o=t("RqIh"),r=t("nwxp"),s=t("RA+f"),u=t("td6z"),c=t("yju1"),d=t("VyO/"),p=t("+22L"),g=t("SpgY"),m=function(e){var n=e.triggerTransition,t=e.flowData;return Object(a.useEffect)((function(){t.pageType===o.a.home_feed_main&&(Object(d.c)({mutation:g["default"].mutations.nuxMarkComplete}),Object(r.h)()&&Object(c.a)("broadcastAllWebViews",{messageName:"refreshFeedAfterNux",data:{"null":null}})),setTimeout((function(){Object(r.h)()||t.pageType!==o.a.home_feed_main?n():window.location.reload()}),3e3)}),[t.pageType,n]),a.createElement(p.a,{titleText:Object(l.plaintextTranslate)("Loading your feed"),isLastStep:!1,triggerTransition:n,stepType:"spinner",isNextButtonHidden:!0},a.createElement(s.e,{textAlign:"center",mb:"small",className:"puppeteer_test_spinner_step"},a.createElement(i.e.Consumer,null,(function(e){return e===o.a.answer?a.createElement(l.Translate,null,"Hold on while we find more great answers for you..."):Object(r.f)()?a.createElement(l.Translate,null,"You're all done! Creating your personalized feed..."):a.createElement(l.Translate,null,"Creating your personalized feed...")}))),a.createElement(u.c,null))};m.displayName="SpinnerStep",n["default"]=m}}]);