PageSourceSearch

https://connect.femmeactuelle.fr/assets/scripts/containers_checkout_index_js.74ef65fa.0ef15b04.js

js femmeactuelle.fr collected 2026-09-24 09:09:05 UTC 26,243 bytes, 406 lines download raw bytes

1"use strict";(self.webpackChunk=self.webpackChunk||[]).push([["containers_checkout_index_js"],{6168:(e,t,n)=>{n.d(t,{A:()=>s});var i=n(2540),r=n(3696),o=n(9503);const a=o.Ay.div`
2	text-align: center;
3	width: 100%;
4	margin-bottom: 10px;
5
6	button {
7		cursor: pointer;
8		text-decoration: underline;
9	}
10`,l=o.Ay.div`
11	position: relative;
12	padding: 40px 0 0 0;
13	svg {
14		position: absolute;
15		top: ${e=>e.top||"15px"};
16		right: 15px;
17	}
18`;class s extends r.Component{constructor(e){super(e),this.state={enabled:!1},this.handleChange=this.handleChange.bind(this)}handleChange(){this.setState({enabled:!this.state.enabled})}content(){return this.state.enabled?(0,i.jsxs)(l,{top:this.props.top,children:[(0,i.jsx)("svg",{onClick:this.handleChange,xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 31.112 31.112",width:"12",height:"12",children:(0,i.jsx)("polygon",{points:"31.112,1.414 29.698,0 15.556,14.142 1.414,0 0,1.414 14.142,15.556 0,29.698 1.414,31.112 15.556,16.97 29.698,31.112 31.112,29.698 16.97,15.556"})}),this.props.children]}):(0,i.jsx)(a,{children:(0,i.jsx)("button",{onClick:this.handleChange,style:{fontSize:this.props.toggleTextSize||"16px"},children:this.props.toggleText})})}render(){return this.content()}}},1052:(e,t,n)=>{n.d(t,{vM:()=>y});var i=n(2540),r=(n(3696),n(8710)),o=n(3049),a=n(202),l=n(5508),s=n(9503),d=n(9933);const c=(0,s.Ay)(d.Ai)`
19	min-height: 69px;
20	margin: 0 0 30px 0;
21`,p=(0,s.Ay)(d.EY)`
22	text-align: center;
23	font-weight: ${({bold:e,isPassPrismaTitle:t,theme:n})=>e||t?n.boldWeight?n.boldWeight:"bold":n.normalWeight?n.normalWeight:"normal"};
24`,u=(0,s.Ay)(d.EY)`
25	min-height: 69px;
26	font-size: ${({small:e,isPassPrismaTitle:t})=>e&&!t?"13px":"15px"};
27`,g=s.Ay.div`
28	min-width: 280px;
29	max-height: 132px;
30	background-color: #f7f9ff;
31	margin: 0 auto;
32	padding: 15px 15px 5px 15px;
33	overflow-y: scroll;
34
35	& ul {
36		list-style: none;
37		text-align: center;
38		padding: 0;
39		margin: 0;
40
41		& li {
42			color: #000;
43			font-size: 12px;
44			font-weight: ${e=>e.theme.boldWeight?e.theme.boldWeight:"600"};
45			line-height: 18px;
46			margin-bottom: 11px;
47		}
48	}
49`;var m=Object.defineProperty,h=Object.getOwnPropertySymbols,x=Object.prototype.hasOwnProperty,f=Object.prototype.propertyIsEnumerable,v=(e,t,n)=>t in e?m(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,b=(e,t)=>{for(var n in t||(t={}))x.call(t,n)&&v(e,n,t[n]);if(h)for(var n of h(t))f.call(t,n)&&v(e,n,t[n]);return e};function y(e){return(0,i.jsxs)(c,{children:[(0,i.jsx)(w,b({},e)),(0,i.jsx)(A,b({},e))]})}function w(e){return e.title?(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(k,b({},e)),(0,i.jsx)(S,b({},e)),(0,i.jsx)(T,b({},e))]}):null}const j=()=>{const e=new a.A,t=new l.A;return e.splitService(t.getSignupService())[4].match(/^RECIPE/gi)?"recipe":"article"};function S({title:e,isLoading:t,valuesTitle:n,alertName:a,removeDesc:l,isBmkTitle:s,isUrvTitle:d,isPassPrismaTitle:c,urvSaveTitle:u}){const g=(0,r.A)();if(t)return(0,i.jsx)("p",{children:(0,i.jsx)(o.A,{height:30})});if(s){const t="recipe"===j()?"Sauvegarder la recette":"Sauvegarder l’article";return(0,i.jsxs)(p,{as:"div",children:[(0,i.jsx)("p",{children:t}),(0,i.jsx)("strong",{children:g.formatMessage({id:e},n)})]})}return d?(0,i.jsxs)(p,{as:"div",children:[(0,i.jsx)("p",{children:u||"Donner mon avis"}),(0,i.jsx)("strong",{children:g.formatMessage({id:e},n)})]}):(0,i.jsx)(p,{bold:!!a||l,isPassPrismaTitle:c,dangerouslySetInnerHTML:{__html:`${g.formatMessage({id:e},n)}${a||""}`}})}function k({icon:e,isLoading:t}){return e?t?(0,i.jsx)("div",{style:{textAlign:"center"},children:(0,i.jsx)(o.A,{circle:!0,height:100,width:100})}):e:null}function A({removeDesc:e,description:t,smallDesc:n,values:a,isLoading:l,weakRole:s}){const d=(0,r.A)();return e||!t?null:l?(0,i.jsx)(o.A,{height:65,className:"welcome-description-loading"}):(s&&t&&t.indexOf(".login.strong")&&(t=t.replace(".login.strong",".login.weak")),(0,i.jsx)(u,{small:n,dangerouslySetInnerHTML:{__html:d.formatMessage({id:t},a)}}))}function T({list:e,isLoading:t}){return e?t?(0,i.jsx)("p",{children:(0,i.jsx)(o.A,{height:200})}):(0,i.jsx)(g,{children:(0,i.jsx)("ul",{children:e.map(((e,t)=>(0,i.jsx)("li",{children:e},t)))})}):null}}
49,852:(e,t,n)=>{n.r(t),n.d(t,{default:()=>ne});var i=n(2540),r=n(3696),o=n(9263),a=n(5022),l=n(2697),s=n(4658),d=n(9208),c=n(6796),p=n(277),u=n(7435),g=n(9348),m=n(1316),h=n(5508),x=n(6391),f=n(9835);const v=new h.A,b=v.getLang()||"fr";function y(e,t){return n=>{n({type:x.CALL_ROUTE_PAYMENTSESSION_LOADING});const i=t.targetingCMP?`_sp_targeting_params=${t.targetingCMP}`:"",r={successUrl:t&&t.successUrl?t.successUrl.indexOf("?")>-1?`${t.successUrl}${i?`&${i}`:""}`:`${t.successUrl}${i?`?${i}`:""}`:"https://connect."+v.getDomain()+`/checkout/${e}/success${i?`?${i}`:""}`,cancelUrl:t&&t.cancelUrl?t.cancelUrl.indexOf("?")>-1?`${t.cancelUrl}${i?`&${i}`:""}`:`${t.cancelUrl}${i?`?${i}`:""}`:"https://connect."+v.getDomain()+`/checkout/${e}/cancel${i?`?${i}`:""}`,productId:e&&!["passprisma","paywall"].includes(e)?e:`passprisma_${b}`};return(0,m.IT)({route:"/payment/stripe/session",method:"POST",body:r}).then((e=>{return n((t=e.data,{type:x.CALL_ROUTE_PAYMENTSESSION_SUCCESS,paymentSession:t}));var t})).catch((e=>{return n((t=(0,f.H)(e),{type:x.CALL_ROUTE_PAYMENTSESSION_ERROR,error:t}));var t}))}}var w,j=n(76),S="https://js.stripe.com/v3",k=/^https:\/\/js\.stripe\.com\/v3\/?(\?.*)?$/,A=function(e){var t=e&&!e.advancedFraudSignals?"?advancedFraudSignals=false":"",n=document.createElement("script");n.src="".concat(S).concat(t);var i=document.head||document.body;if(!i)throw new Error("Expected document.body not to be null. Stripe.js requires a <body> element.");return i.appendChild(n),n},T=null,E=null,P=null,M=function(e){return null!==T?T:(T=new Promise((function(t,n){if("undefined"!=typeof window&&"undefined"!=typeof document)if(window.Stripe,window.Stripe)t(window.Stripe);else try{var i=function(){for(var e=document.querySelectorAll('script[src^="'.concat(S,'"]')),t=0;t<e.length;t++){var n=e[t];if(k.test(n.src))return n}return null}();if(i&&e);else if(i){if(i&&null!==P&&null!==E){var r;i.removeEventListener("load",P),i.removeEventListener("error",E),null===(r=i.parentNode)||void 0===r||r.removeChild(i),i=A(e)}}else i=A(e);P=function(e,t){return function(){window.Stripe?e(window.Stripe):t(new Error("Stripe.js not available"))}}(t,n),E=function(e){return function(){e(new Error("Failed to load Stripe.js"))}}(n),i.addEventListener("load",P),i.addEventListener("error",E)}catch(e){return void n(e)}else t(null)})),T.catch((function(e){return T=null,Promise.reject(e)})))},$=function(){return w||(w=M(null).catch((function(e){return w=null,Promise.reject(e)})),w)};Promise.resolve().then((function(){return $()})).catch((function(e){}));var O=n(4953),C=n(8710),U=n(5276),_=n(9503),z=n(3321);const I=_.Ay.div`
50	display: flex;
51	flex-direction: column;
52	margin-bottom: 10px;
53
54	.labelRow {
55		display: flex;
56		justify-content: space-between;
57		align-items: baseline;
58	}
59
60	label {
61		font-size: 15px;
62		display: inline-block;
63	}
64
65	input,
66	textarea {
67		border: ${e=>e.theme.inputBorder};
68		background: #fff;
69		font-size: 16px;
70		line-height: 18px;
71		width: 100%;
72		font-weight: ${e=>e.theme.inputBorder};
73		border-radius: 2px;
74		outline: 0;
75		margin-top: 0;
76		transition: all 0.3s ease-in-out;
77		padding: ${e=>e.padding||"15px"};
78
79		&:focus {
80			box-shadow: 0 0 5px #999999;
81		}
82		${({error:e})=>e&&_.AH`
83				border-color: #e20024;
84				color: #e20024;
85			`}
86	}
87
88	.validityError {
89		font-size: 12px;
90		color: #f35b63;
91		margin-top: 5px;
92		${({error:e})=>{!e&&_.AH`
93					display: none;
94				`}}
95	}
96	.helperText {
97		margin-top: 0;
98		font-size: 11px;
99		color: #444455;
100	}
101
102	@media screen and (min-width: 768px) {
103		padding-right: 0.75rem;
104		flex-basis: 50%;
105
106		label {
107			margin-bottom: 5px;
108		}
109	}
110`;_.Ay.div`
111	padding: 9px 0 10px;
112	text-align: center;
113	background-color: #ffffff;
114	border: 1px solid #c3c9cb;
115	border-radius: 2px;
116	position: relative;
117	display: inline-block;
118	margin-bottom: 10px;
119	input {
120		position: absolute;
121		cursor: pointer;
122		height: 0;
123		width: 0;
124		opacity: 0;
125	}
126	label {
127		color: ${({theme:e,checked:t})=>t?e.brandA:"#d4d4d4"};
128		font-size: 16px;
129		line-height: 20px;
130		position: relative;
131		::before {
132			content: '';
133			position: absolute;
134			top: 5px;
135			left: -17px;
136			display: inline-block;
137			width: 10px;
138			height: 10px;
139			background-color: #d4d4d4;
140			border-radius: 50%;
141			${({checked:e})=>e&&_.AH`
142					left: -20px;
143					top: 1px;
144					padding: 2px;
145					width: 16px;
146					bottom: 2px;
147					height: 16px;
148					background-clip: content-box;
149					background-color: ${({theme:e})=>e.brandA};
150					border: 1px solid ${({theme:e})=>e.brandA};
151				`}
152		}
153	}
154`,_.Ay.div`
155	label {
156		font-size: 15px;
157		display: inline-block;
158	}
159	@media screen and (min-width: 768px) {
160		label {
161			margin-bottom: 5px;
162		}
163		padding-right: 0.75rem;
164	}
165
166	> div {
167		display: grid;
168		grid-template-columns: auto auto;
169		grid-gap: 10px;
170	}
171`,_.Ay.fieldset`
172	border: 0;
173	margin: 0;
174	padding: 0;
175	margin-top: 20px;
176	min-width: 0;
177
178	> div {
179		display: flex;
180		flex-wrap: wrap;
181		flex-direction: column;
182		@media (min-width: 768px) {
183			padding: 0 35px;
184		}
185	}
186
187	hr {
188		border-top: 1px solid #d4d4d4;
189		margin: 0 0 20px 0;
190		height: 1px;
191	}
192
193	button {
194		margin: auto;
195		width: auto;
196	}
197
198	legend {
199		border-top: 1px solid #d4d4d4;
200		padding-top: 24px;
201		padding-bottom: 15px;
202		font-size: 16px;
203		width: 100%;
204		text-align: center;
205		color: #444455;
206		font-weight: ${({theme:e})=>e.boldWeight||"bold"};
207		margin-top: 20px;
208		@media (min-width: 768px) {
209			padding-left: 35px;
210		}
211	}
212
213	@media screen and (min-width: 768px) {
214		margin-right: -0.75rem;
215
216		> div {
217			flex-direction: row;
218			> div {
219				flex-basis: 49%;
220			}
221		}
222
223		hr {
224			display: none;
225		}
226
227		legend {
228			border: none;
229			text-align: left;
230			padding-top: 14px;
231			font-size: 18px;
232			font-weight: ${({theme:e})=>e.boldWeight||"bold"};
233		}
234	}
235
236	.fakeFields {
237		> div {
238			width: 100%;
239			@media (min-width: 768px) {
240				padding-right: 0.75rem;
241				flex-basis: 49%;
242				width: 0;
243			}
244		}
245		span {
246			text-decoration: underline;
247			cursor: pointer;
248			color: #000;
249			font-size: 13px;
250			border-bottom: 25px;
251			display: block;
252			margin-bottom: 25px;
253		}
254	}
255`,_.Ay.div`
256	form {
257		display: flex;
258		flex-direction: column;
259		justify-content: center;
260		align-items: center;
261		margin: auto;
262		text-align: center;
263
264		h2 {
265			font-size: 20px;
266			margin-top: 25px;
267			margin-bottom: 15px;
268		}
269
270		.inputWrapper {
271			width: 100%;
272			display: flex;
273			flex-direction: column;
274			align-content: center;
275			margin-top: 35px;
276			margin-bottom: 10px;
277			> div {
278				margin: 0;
279			}
280			@media (min-width: 768px) {
281				flex-direction: row;
282			}
283
284			+ span {
285				margin-bottom: 20px;
286
287				&:hover {
288					cursor: default;
289				}
290			}
291		}
292
293		p {
294			text-align: center;
295			font-size: 14px;
296			max-width: 450px;
297			margin: auto;
298		}
299
300		button {
301			flex-basis: 50%;
302
303			@media (min-width: 768px) {
304				margin: 0;
305			}
306		}
307
308		> span {
309			text-decoration: underline;
310			font-size: 14px;
311			margin: auto;
312			&:hover {
313				cursor: pointer;
314			}
315		}
316	}
317`,_.Ay.div`
318	color: #444455;
319	background-color: #fff;
320	border: 1px solid #c3c9cb;
321	height: 50px;
322	border-radius: 2px;
323	padding: 15px;
324	line-height: 20px;
325	margin-bottom: 10px;
326	white-space: nowrap;
327	text-overflow: ellipsis;
328	overflow: hidden;
329	font-weight: ${({theme:e})=>e.boldWeight||"bold"};
330`,_.Ay.div`
331	display: flex;
332	flex-direction: column;
333	padding-right: 0.75rem;
334	margin-bottom: 10px;
335	@media (max-width: 768px) {
336		padding-right: 0;
337	}
338
339	label {
340		margin-bottom: 5px;
341	}
342	> span {
343		margin-top: 5px;
344	}
345	select {
346		width: 100%;
347		background-image: none;
348		outline: 0;
349		line-height: 18px;
350		padding: 15px;
351		font-size: 16px;
352		border: 1px solid rgba(81, 81, 81, 0.2);
353		border-radius: 2px;
354		background-color: #fff;
355		appearance: none;
356		&:not([multiple]):not([size]) {
357			background-image: none;
358		}
359		&:focus {
360			box-shadow: 0 0 5px #999999;
361		}
362		&:after {
363			content: url(${z.A});
364		}
365		${({error:e})=>e&&_.AH`
366				border-color: #e20024;
367				color: #e20024;
368			`}
369		&::-ms-expand {
370			display: none;
371		}
372	}
373	div {
374		position: relative;
375
376		&:after {
377			content: '';
378			width: 13px;
379			height: 9px;
380			position: absolute;
381			right: 14px;
382			top: 21px;
383			mask: url(${z.A}) no-repeat left top;
384			mask-size: 13px 9px;
385			background-color: #515151;
386		}
387	}
388`;var L=n(9933),N=Object.defineProperty,R=Object.defineProperties,D=Object.getOwnPropertyDescriptors,B=Object.getOwnPropertySymbols,H=Object.prototype.hasOwnProperty,W=Object.prototype.propertyIsEnumerable,Y=(e,t,n)=>t in e?N(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,q=(e,t)=>{for(var n in t||(t={}))H.call(t,n)&&Y(e,n,t[n]);if(B)for(var n of B(t))W.call(t,n)&&Y(e,n,t[n]);return e},F=(e,t)=>R(e,D(t));const V=({input:e={},type:t,meta:n={},label:r,labelHelper:o,placeHolder:a,helperText:l,multiline:s,rows:d,maxlength:c,padding:p})=>{const{error:u,submitError:g,dirty:m,dirtySinceLastSubmit:h}=n,x=(0,C.A)();return(0,i.jsxs)(I,{error:!(!u&&!g||!m),padding:p,children:[r&&(o?(0,i.jsxs)("div",{className:"labelRow",children:[(0,i.jsx)("label",{htmlFor:e.name,children:r}),o]}):(0,i.jsx)("label",{htmlFor:e.name,children:r})),s?(0,i.jsx)("textarea",F(q({id:e.name},e),{type:t,placeholder:a,rows:d||2,maxLength:c})):(0,i.jsx)("input",F(q({id:e.name},e),{type:t,placeholder:a})),l&&(0,i.jsx)("span",{className:"helperText",children:l}),(u||g)&&m&&!h&&(0,i.jsx)("span",{className:"validityError",children:(0,i.jsx)(L.g9,{children:x.formatMessage({id:u||g})})})]})};var J=n(7146),G=n(9053),K=n(8098),Z=n(1052),Q=n(6168);const X=_.Ay.label`
389	display: flex;
390	alignitems: center;
391
392	input {
393		transform: scale(1.15);
394	}
395	a {
396		text-decoration: underline;
397	}
398	span {
399		margin-left: 10px;
400		text-align: left;
401		a {
402			color: inherit;
403		}
404	}
405`;var ee=n(3049);const te=e=>e?void 0:"Required",ne=()=>{const e=(0,C.A)(),{params:{productId:t}}=(0,u.RQ)("/checkout/:productId"),n=(0,a.wA)(),{profile:m,queryVars:h,requestPayment:x,product:f,productError:v,lang:b}=(0,a.d4)((e=>({profile:e.user.profile,queryVars:e.queryVars,requestPayment:e.requestPayment,product:e.caller.getProduct.success,productError:e.caller.getProduct.error,lang:e.intl.locale})),a.bN),{data:{config:w}}=(0,l.IT)(d.uD),[S,{data:k,error:A,loading:T}]=(0,s.n)(c.ab),E=new p.A;let P=E.get();const[M,_]=(0,r.useState)(!1),[z,I]=(0,r.useState)(!1),[N,R]=(0,r.useState)(!1);(0,J.pK)();const D=e=>{return t=void 0,n=null,i=function*(){const t=yield function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];!0;var i=Date.now();return $().then((function(e){return function(e,t,n){if(null===e)return null;var i=e.apply(void 0,t);return function(e,t){e&&e._registerWrapper&&e._registerWrapper({name:"stripe-js",version:"3.0.6",startTime:t})}(i,n),i}(e,t,i)}))}("pk_live_51IQBYxIldPtlgwa1LmNU7TRGwZKWBizFMlYVKwhUggKRYDpBVV0JWC9mYRY9CkMGdfmEj1yJHfIap6zmTUEjeLSa00wnbZnvzW");t.redirectToCheckout({sessionId:e})},new Promise(((e,r)=>{var o=e=>{try{l(i.next(e))}catch(e){r(e)}},a=e=>{try{l(i.throw(e))}catch(e){r(e)}},l=t=>t.done?e(t.value):Promise.resolve(t.value).then(o,a);l((i=i.apply(t,n)).next())}));var t,n,i},B=(0,r.useCallback)((e=>{R((()=>(!1===N&&S({variables:{data:e}}),{updatedProfileBefore:!0})))}),[N,S]),H=(0,r.useCallback)((()=>{I(!0);const e={};h.successUrl&&(e.successUrl=decodeURIComponent(h.successUrl)),h.cancelUrl&&(e.cancelUrl=decodeURIComponent(h.cancelUrl)),h.targetingCMP&&(e.targetingCMP=decodeURIComponent(h.targetingCMP)),!f||x.loading||x.success||x.error||n(y(t,e))}),[h.successUrl,h.cancelUrl,h.targetingCMP,f,x.loading,x.success,x.error,n,t]),W=(0,r.useCallback)((()=>{var e;e=t,n((0,j.oo)(e))}),[n,t]);(0,r.useEffect)((()=>{W()}),[W]),(0,r.useEffect)((()=>{!f||!f.autoRedirect||z||x.loading||x.success||x.error||H()}),[H,f,x.error,x.loading,x.success,z]),P&&!h.redirectTo||(E.defineUrl(h.redirectTo),P=E.get()),f&&(!f.firstName||f.firstName&&(k&&N||!N))&&x&&x.success&&(x.success.checkoutId||x.success.url)&&(x.success.url?window.location.assign(x.success.url):D(x.success.checkoutId)),["passprisma","paywall",G[b].production].includes(t)&&m&&m.passPrisma&&m.passPrisma.isActive&&m.passPrisma.endAt>Date.now()&&window.location.assign(decodeURIComponent(P));
405const Y=f?`${f.name}<br /><br />${f.checkoutDescription1}`:null,q=f?f.checkoutDescription2:null,F=f?f.checkoutButton:null,ne=f?f.cgv:null,ie=!!f&&!!parseInt(f.firstName),re=(0,i.jsx)("img",{style:{maxHeight:"250px",marginBottom:"-15px"},src:w.svg.checkoutSuccess});return x&&x.error||v?(0,i.jsx)(o.Nj,{navigation:"false",children:(0,i.jsx)(L.mO,{maxWidth:"335px",margin:"30px auto 0",children:(0,i.jsxs)(L.Ai,{children:[(0,i.jsx)("div",{style:{textAlign:"center"},children:(0,i.jsx)("img",{style:{maxHeight:"250px",marginBottom:"-15px"},src:w.svg.errorIcon})}),(0,i.jsx)("p",{children:(null==x?void 0:x.error)||e.formatMessage({id:"welcome.title.getProductError"})})]})})}):!m||"loading"===m||!w||!f||f&&f.autoRedirect?(0,i.jsx)(L.mO,{maxWidth:"335px",margin:"30px auto 0",children:(0,i.jsxs)(L.Ai,{children:[(0,i.jsx)("div",{style:{textAlign:"center"},children:(0,i.jsx)(ee.A,{circle:!0,height:100,width:100})}),(0,i.jsx)("p",{children:(0,i.jsx)(ee.A,{height:30})}),(0,i.jsx)("p",{children:(0,i.jsx)(ee.A,{count:3})})]})}):(0,i.jsx)(o.Nj,{navigation:!1,children:(0,i.jsxs)(L.mO,{maxWidth:"335px",margin:"0 auto",txtAlign:"center",children:[(0,i.jsx)(Z.vM,{title:Y,description:q,icon:re,isLoading:!1,isBmkTitle:!1,isUrvTitle:!1,smallDesc:!0}),(0,i.jsx)(U.lV,{onSubmit:e=>{const t=e.firstname&&e.firstname!==m.firstname?{firstname:e.firstname}:null;t&&!N&&B(t),z||H()},children:({handleSubmit:e})=>(0,i.jsxs)("form",{id:"pmc-profile-form",onSubmit:t=>{t.preventDefault(),e()},children:[ie&&(0,i.jsxs)(L.mO,{fontSize:"12px",margin:"0 0 0x 0",padding:"0",lineHeight:"1.2",txtAlign:"left",children:[" ",(0,i.jsx)(U.D0,{label:"Prénom",name:"firstname",parse:e=>e,initialValue:m.firstname,component:V,type:"text",validate:te})]}),(0,i.jsx)(L.EY,{fontSize:"12px",margin:"0 0 0x 0",padding:"20px 0 0 0",lineHeight:"1.2",align:"center",children:(0,i.jsxs)(X,{children:[(0,i.jsx)("input",{type:"checkbox",onClick:()=>{_(!M)}}),(0,i.jsx)("span",{dangerouslySetInnerHTML:{__html:ne}})]})}),(0,i.jsx)(K.j,{type:"submit",disabled:!M&&!z,children:F})]})}),(0,i.jsx)(L.EY,{fontSize:"12px",margin:"0 0 0x 0",padding:"20px 0 0 0",lineHeight:"1.2",align:"center",children:(0,i.jsx)(g.N_,{to:O.JL(),target:"_blank",style:{color:"inherit"},children:e.formatMessage({id:"common.faq"})})}),(0,i.jsx)(L.mO,{children:(0,i.jsx)(Q.A,{top:"-15px",toggleText:e.formatMessage({id:"legals.infoAboutDataTreatment"}),toggleTextSize:"12px",children:(0,i.jsx)(L.TI,{dangerouslySetInnerHTML:{__html:e.formatMessage({id:"legals.datatreatment"})}})})})]})})}},7146:(e,t,n)=>{n.d(t,{Ny:()=>f,yi:()=>l,rv:()=>i.r,_J:()=>x,pK:()=>s.p});var i=n(2391),r=n(2697),o=n(9208);const a=new(n(5508).A);function l(e=""){const{data:{config:t}}=(0,r.IT)(o.uD);return t.config.magazineRedirections?t.config.magazineRedirections.prod+e:"https://boutique."+a.getDomain()+e}var s=n(5107),d=(n(7469),n(3696)),c=n(5339),p=n(5022),u=n(5648),g=n(8710),m=n(2583);var h=n(153);const x=()=>{var e,t,n,i;const a=(0,p.wA)(),s=(0,g.A)(),[x,f]=(0,d.useState)((new Date).getFullYear()),[v,b]=(0,d.useState)(!1),[y,w]=(0,d.useState)(null),[j,S]=(0,d.useState)(null),{data:{config:k}}=(0,r.IT)(o.uD),{availableBrandsMag:A,loading:T}=(()=>{const{data:e}=(0,r.IT)(o.uJ),[t,{data:n,loading:i}]=(0,c._)(o.UV);return(0,d.useEffect)((()=>{if(t({variables:{expired:"ALL",brands:"*",status:"all"}}),!i&&n){const{me:e}=n,{paymentSubscriptions:t}=e;if(t&&t.items){const e=t.items.map((e=>{var t;if((null==(t=e.rights)?void 0:t.includes("paid-web-magazine"))&&["succeeded","pending","pending_cancel"].includes(e.status))return e.brandId})).filter((e=>void 0!==e)),n=e.length>0?[...new Set(e)]:[];(0,m._B)(n)}}}),[t,n,i]),{availableBrandsMag:null==e?void 0:e.availableBrandsMag,loading:i}})(),[E,{data:P,loading:M,error:$}]=(0,c._)(o.n),[O,{data:C,error:U}]=(0,c._)(o.EH),_=l(),z=(0,d.useMemo)((()=>{var e,t;return(null==(t=null==(e=null==P?void 0:P.me)?void 0:e.magazines)?void 0:t.availableYears)||[]}),[null==(t=null==(e=null==P?void 0:P.me)?void 0:e.magazines)?void 0:t.availableYears]),I=(0,d.useMemo)((()=>z.map((e=>({value:e,label:e}))).reverse()),[z]),L=(0,d.useMemo)((()=>
405{if(!(null==A?void 0:A.length))return[];return[k.config.trigram,...A.filter((e=>e!==k.config.trigram))].map((e=>({name:h[e],id:e})))}),[A,k.config.trigram]),N=(null==(i=null==(n=null==P?void 0:P.me)?void 0:n.magazines)?void 0:i.edges)||[];(0,d.useEffect)((()=>{(U||$)&&a((0,u.P0)({text:s.formatMessage({id:"common.errors.genericError"}),type:"error"}))}),[U,$,a,s]),(0,d.useEffect)((()=>{L.length>0&&!y&&(w(L[0].id),S({brand:L[0].id,page:1}))}),[L,y]),(0,d.useEffect)((()=>{(null==A?void 0:A.length)>0&&y&&x&&(E({variables:{brands:[y.toUpperCase()],limit:100,year:`${x}`}}),S({brand:y,page:1}))}),[y,x,E,A]),(0,d.useEffect)((()=>{if(!M&&!v&&z.length>0){if(z.some((e=>String(e)===String(x))))b(!0);else{const e=z[z.length-1];f(e),E({variables:{brands:[y.toUpperCase()],limit:100,year:String(e)}})}}else v||M||0!==(null==A?void 0:A.length)||b(!0)}),[z,M,A,v,x,y,E]),(0,d.useEffect)((()=>{var e,t,n;(null==(e=null==C?void 0:C.magazineUrl)?void 0:e.url)&&(window.open(null==(t=null==C?void 0:C.magazineUrl)?void 0:t.url,"_blank")||window.location.assign(null==(n=null==C?void 0:C.magazineUrl)?void 0:n.url))}),[C]);const R=T||M,D=0===(null==A?void 0:A.length),B=(null==A?void 0:A.length)>0&&!A.includes(y),H=I.length>0,W=N.length>0;return{brand:k,navItems:L,magazines:N,filterOptions:I,year:x,brandStart:j,advertiseSubscriptionUrl:_,isLoading:R,isFilterReady:v,loadingMagazines:M,hasNoSubscription:D,currentBrandNotSubscribed:B,hasFilterOptions:H,hasMagazines:W,readMagazine:e=>new Promise((t=>{try{O({variables:{parutionId:e}}),setTimeout((()=>{t()}),1e3)}catch(e){t()}})),changeYear:e=>{f(e)},changeBrand:e=>{w(e),b(!1)}}},f=()=>{const{data:e,loading:t}=(0,r.IT)(o.UV,{variables:{expired:"ALL",brands:"*",status:"all"}});return{canSeeContactForm:(0,d.useMemo)((()=>{var t,n,i,r;return(null==(n=null==(t=null==e?void 0:e.me)?void 0:t.paymentSubscriptions)?void 0:n.items)&&(null==(r=null==(i=null==e?void 0:e.me)?void 0:i.paymentSubscriptions)?void 0:r.items.length)>0}),[e]),loading:t}}},7469:(e,t,n)=>{n.d(t,{t:()=>l,v:()=>a});var i=n(3696),r=n(2697),o=n(9208);function a({type:e}){const[t,n]=(0,i.useState)([]),[a,l]=(0,i.useState)(null),[s,d]=(0,i.useState)(!1),[c,p]=(0,i.useState)(0),{data:u,loading:g,error:m,fetchMore:h}=(0,r.IT)(o.AK,{variables:{where:{type:{in:{values:e.split(",")}}},offset:c,limit:30}});return(0,i.useEffect)((()=>{var e,i,r,o,d;if(!g&&!m&&!s)if((null==(r=null==(i=null==(e=null==u?void 0:u.me)?void 0:e.bookmarks)?void 0:i.edges)?void 0:r.length)>0){const e=u.me.bookmarks.edges,i=c+e.length;n([...t,...e]),null===a&&l(u.me.bookmarks.total),p(i)}else 0===(null==(d=null==(o=null==u?void 0:u.me)?void 0:o.bookmarks)?void 0:d.total)&&l(u.me.bookmarks.total)}),[u,g,m,t,s,c,a]),(0,i.useEffect)((()=>{null!==a&&c<a&&!s&&h({variables:{where:{type:{in:{values:e.split(",")}}},offset:c,limit:30}})}),[t,a,c,h,e,s]),(0,i.useEffect)((()=>{(null!==a&&t.length===a||u&&0===a||m)&&d(!0)}),[t,a,s,u,m]),{allBmks:t,done:s,error:m}}function l({type:e,brand:t}){const[n,a]=(0,i.useState)([]),[l,s]=(0,i.useState)(null),[d,c]=(0,i.useState)(!1),[p,u]=(0,i.useState)(0),{data:g,loading:m,error:h,fetchMore:x}=(0,r.IT)(o.Ud,{variables:{where:{brand:{key:{eq:t}},type:{in:{values:e.split(",")}},updatedAt:{gt:"P-30D"}},offset:p,limit:30},context:{fetchOptions:{method:"GET"}}});return(0,i.useEffect)((()=>{var e,t,i;if(!m&&!h&&!d)if((null==(t=null==(e=null==g?void 0:g.bookmarkTops)?void 0:e.edges)?void 0:t.length)>0){const e=g.bookmarkTops.edges,t=p+e.length;a([...n,...e]),null===l&&s(Math.min(g.bookmarkTops.total,30)),u(t)}else s(null==(i=null==g?void 0:g.bookmarkTops)?void 0:i.total)}),[g,m,h,n,d,p,l]),(0,i.useEffect)((()=>{null!==l&&p<30&&!d&&x({variables:{where:{brand:{key:{eq:t}},type:{in:{values:e.split(",")}},updatedAt:{gt:"P-30D"}},offset:p,limit:30},context:{fetchOptions:{method:"GET"}}})}),[n,l,p,x,e,t,d]),(0,i.useEffect)((()=>{(null!==l&&n.length>=l||0===l||h)&&c(!0)}),[n,l,d,h]),{allTops:n,done:d,error:h}}},2391:(e,t,n)=>{n.d(t,{r:()=>r});var i=n(8710);function r(e,t,n={}){const r=(0,i.A)(),o={};return t.forEach((t=>{n[t]?o[t]=r.formatMessage({id:`${e}.${t}`},n[t]):o[t]=r.formatMessage({id:`${e}.${t}`})})),o}},5107:(e,t,n)=>{n.d(t,{p:()=>l});var i=n(3696),r=n(7435),o=n(2697),a=n(9208);function l(){var e,t,n;const{pathname:l}=(0,r.zy)(),{loading:s,error:d,data:c}=(0,o.IT)(a.TH,{fetchPolicy:"network-only"});return(0,i.useEffect)((()=>{var e,t,n,i,r,o;s||(d||(null==(n=null==(t=null==(e=null==c?void 0:c.me)?void 0:e.connection)?void 0:t.roles)?void 0:n.length)&&(null==(o=null==(r=null==(i=null==c?void 0:c.me)?void 0:i.connection)?void 0:r.roles)?void 0:o.includes("ALIVE")))&&(window.location.href="/?redirectTo="+l)}),[s,d,c,l]),!s&&!d&&!(null==(n=null==(t=null==(e=null==c?void 0:c.me)?void 0:e.connection)?void 0:t.roles)?void 0:n.includes("ALIVE"))}},3321:(e,t,n)=>{n.d(t,{A:()=>i});const i=n.p+"assets/icons/down-chevron-280f5b2c7cd2039a64875a5fb21f78f0.svg"},153:e=>{e.exports=JSON.parse('{"cam":"Ça m\'intéresse","ctv":"Ce soir TV","cap":"C
405apital","cac":"Cuisine Actuelle","ctm":"Côté Maison","fac":"Femme Actuelle","geo":"Geo","gen":"Gentside","neo":"Neon","omm":"Ohmymag","ptv":"Télé 2 Semaines","tel":"Télé-Loisirs","voi":"Voici","pmc":"Prisma Connect","pms":"Prismashop","frgsd":"Maxisciences","inf":"Infonity","ppr":"PassPresse","hbz":"Harper\'s Bazaar","deomm":"Oh! My Mag","degs":"Gentside","ukomm":"Oh! My Mag","ukgs":"Gentside","uksas":"See&So","desas":"See&So","frgsg":"Gamesider","frgss":"Uppercut MMA","caz":"CuisineAZ"}')},9053:e=>{e.exports=JSON.parse('{"fr":{"development":"prod_J2K77fpQ0TyN5P","recette":"prod_J2K77fpQ0TyN5P","production":"prod_J2f3Gk6x8FqqbC"},"en":{"development":"prod_OSg9R194KUNUcP","recette":"prod_OSg9R194KUNUcP","production":"prod_OSgJe55vZyJCoz"},"de":{"development":"prod_OSgMYZw0Bc0xuR","recette":"prod_OSgMYZw0Bc0xuR","production":"prod_OSgWjLHkNieeeB"}}')}}]);
406//# sourceMappingURL=containers_checkout_index_js.74ef65fa.0ef15b04.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.