PageSourceSearch

https://www.hellofresh.de/_next/static/chunks/pages/cookbook/import-81f87ebead5114c7.js

js hellofresh.de collected 2026-09-25 23:38:08 UTC 220,553 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[98430,35959,10454,53518,88985,72290,27408,72167,93438,20336,87167,12449,28643],{722527:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/cookbook/import",function(){return r(287354)}])},96840:function(e,t,r){"use strict";r.d(t,{N:function(){return h}});var o,n,i=r(456552),a=r(671718),l=r(447178),c=r(64294),u=r(43011),s=r(140224),p=r(699219);function d(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}function f(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function b(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var m=(o=function(e,t){var r,o,n,i,l,u,s,p,d,m,h,y,g,v=arguments;return function(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}(this,function(k){switch(k.label){case 0:return r=e.url,n=void 0===(o=e.usePublicAuth)||o,l=void 0!==(i=e.addMissingDetails)&&i,s=void 0!==(u=e.mirrorThumbnail)&&u,p=e.systemCountry,d=e.locale,m=e.parentSpan,[4,(v.length>2&&void 0!==v[2]?v[2]:a.Z)("/cookbook/v2/external-recipes",t,{method:"POST",headers:{"Content-Type":"application/json","X-Import-Source":"web_manual_url_entry"},query:f({country:p,locale:d,hf_public_id:(0,c.ZP)()},l?{add_missing_details:!0}:{},s?{mirror_thumbnail:!0}:{}),data:{url:r},timeout:6e4,parentSpan:m,fetchSpanAttributes:{"request.backend_service":"cookbook-api","request.backend_action":"create-external-recipe"}},{usePublicAuth:n})];case 1:return y=(h=k.sent()).headers.get("X-Free-Recipe-Save-Count"),g=h.headers.get("X-Free-Recipe-Save-Limit"),[4,h.json()];case 2:return[2,b(f({},k.sent()),{freeRecipeSaveCount:y?parseInt(y,10):null,freeRecipeSaveLimit:g?parseInt(g,10):null})]}})},n=function(){var e=this,t=arguments;return new Promise(function(r,n){var i=o.apply(e,t);function a(e){d(i,r,n,a,l,"next",e)}function l(e){d(i,r,n,a,l,"throw",e)}a(void 0)})},function(e,t){return n.apply(this,arguments)}),h=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=(0,l.Z)().fetch,r=(0,u.Z)(),o=(0,s.O)(),n=(0,i.useQueryClient)(),a=[p.Z["externalRecipes.create"]];return(0,i.useMutation)(function(e){return m(f(b(f({},e),{usePublicAuth:!r}),o),a,t)},b(f({},e),{onSuccess:function(t,r,o){var i;n.invalidateQueries(p.Z["externalRecipes.list"]),null===(i=e.onSuccess)||void 0===i||i.call(e,t,r,o)}}))}},410310:function(e,t,r){"use strict";r.d(t,{K:function(){return h}});var o,n,i=r(456552),a=r(671718),l=r(447178),c=r(64294),u=r(43011),s=r(140224),p=r(699219);function d(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}function f(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);
1"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function b(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var m=(o=function(e,t){var r,o,n,i,l,u,s,p,d,m,h,y=arguments;return function(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}(this,function(g){switch(g.label){case 0:return r=e.bookmarkId,o=e.bookmarkSource,n=e.importSource,l=void 0===(i=e.usePublicAuth)||i,u=e.systemCountry,s=e.locale,p=e.parentSpan,[4,(y.length>2&&void 0!==y[2]?y[2]:a.Z)("/cookbook/v1/internal-recipes",t,{method:"POST",headers:{"Content-Type":"application/json","X-Import-Source":null!=n?n:"web_".concat(o,"_recipe_redirect")},query:{country:u,locale:s,hf_public_id:(0,c.ZP)()},data:{bookmark_id:r,bookmark_source:o},timeout:6e4,parentSpan:p,fetchSpanAttributes:{"request.backend_service":"cookbook-api","request.backend_action":"create-internal-recipe-from-creator"}},{usePublicAuth:l})];case 1:return m=(d=g.sent()).headers.get("X-Free-Recipe-Save-Count"),h=d.headers.get("X-Free-Recipe-Save-Limit"),[4,d.json()];case 2:return[2,b(f({},g.sent()),{freeRecipeSaveCount:m?parseInt(m,10):null,freeRecipeSaveLimit:h?parseInt(h,10):null})]}})},n=function(){var e=this,t=arguments;return new Promise(function(r,n){var i=o.apply(e,t);function a(e){d(i,r,n,a,l,"next",e)}function l(e){d(i,r,n,a,l,"throw",e)}a(void 0)})},function(e,t){return n.apply(this,arguments)}),h=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=(0,l.Z)().fetch,r=(0,u.Z)(),o=(0,s.O)(),n=(0,i.useQueryClient)(),a=[p.Z["internalRecipes.createFromCreator"]];return(0,i.useMutation)(function(e){return m(f(b(f({},e),{usePublicAuth:!r}),o),a,t)},b(f({},e),{onSuccess:function(t,r,o){var i;n.invalidateQueries(p.Z["externalRecipes.list"]),n.invalidateQueries(p.Z["internalRecipes.search"]),null===(i=e.onSuccess)||void 0===i||i.call(e,t,r,o)}}))}},3032:function(e,t,r){"use strict";r.d(t,{x:function(){return h}});var o,n,i=r(456552),a=r(671718),l=r(447178),c=r(64294),u=r(43011),s=r(140224),p=r(699219);function d(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}function f(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function b(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r}
1)(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var m=(o=function(e,t){var r,o,n,i,l,u,s,p,d,f=arguments;return function(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}(this,function(b){switch(b.label){case 0:return r=e.id,n=void 0===(o=e.usePublicAuth)||o,i=e.systemCountry,l=e.locale,u=e.parentSpan,[4,(f.length>2&&void 0!==f[2]?f[2]:a.Z)("".concat("/cookbook/v1/external-recipes","/").concat(r),t,{method:"DELETE",query:{country:i,locale:l,hf_public_id:(0,c.ZP)()},parentSpan:u,fetchSpanAttributes:{"request.backend_service":"cookbook-api","request.backend_action":"delete-external-recipe"}},{usePublicAuth:n})];case 1:return p=(s=b.sent()).headers.get("X-Free-Recipe-Save-Count"),d=s.headers.get("X-Free-Recipe-Save-Limit"),[2,{freeRecipeSaveCount:p?parseInt(p,10):null,freeRecipeSaveLimit:d?parseInt(d,10):null}]}})},n=function(){var e=this,t=arguments;return new Promise(function(r,n){var i=o.apply(e,t);function a(e){d(i,r,n,a,l,"next",e)}function l(e){d(i,r,n,a,l,"throw",e)}a(void 0)})},function(e,t){return n.apply(this,arguments)}),h=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=(0,l.Z)().fetch,r=(0,u.Z)(),o=(0,s.O)(),n=(0,i.useQueryClient)(),a=[p.Z["externalRecipes.delete"]];return(0,i.useMutation)(function(e){return m(f(b(f({},e),{usePublicAuth:!r}),o),a,t)},b(f({},e),{onSuccess:function(t,r,o){var i;n.invalidateQueries(p.Z["externalRecipes.list"]),n.invalidateQueries(p.Z["internalRecipes.search"]),null===(i=e.onSuccess)||void 0===i||i.call(e,t,r,o)}}))}},304187:function(e,t,r){"use strict";r.d(t,{hX:function(){return b},yA:function(){return m}});var o,n,i=r(456552),a=r(671718),l=r(447178),c=r(140224),u=r(699219),s=r(309273);function p(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}function d(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}var f=(o=function(e,t){var r,o,n,i,l=arguments;return function(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}(this,function(c){switch(c.label){case 0:return r=e.parentSpan,o=e.creatorId,[4,(l.length>2&&void 0!==l[2]?l[2]:a.Z)((0,s.Ej)(o),t,{query:{include_recipes:"true"},parentSpan:r,fetchSpanAttributes:{"request.backend_service":"cookbook-api","request.backend_action":"get-creator-recipes"}})];case 1:return[4,c.sent().json()];case 2:return[2,{docs:i=null!==(n=c.sent().recipes)&&void 0!==n?n:[],totalDocs:i.length,limit:i.length,totalPages:1,page:1,pagingCounter:1,hasPrevPage:!1,hasNextPage:!1,prevPage:null,nextPage:null}]}})},n=function(){var e=this,t=arguments;return new Promise(function(r,n){var i=o.apply(e,t);function a(e){p(i,r,n,a,l,"next",e)}function l(e){p(i,r,n,a,l,"throw",e)}a(void 0)})},function(e,t){return n.apply(this,arguments)}),b=function(e,t){var r=(0,l.Z)().fetch,o=(0,c.O)(),n=[u.Z["cookbookCreators.recipes"],e];return(0,i.useInfiniteQuery)(n,function(){return f(d({},e,o),n,r)},{enabled:!!e.creatorId,getNextPageParam:function(){},initialData:t,staleTime:t?1/0:0,cacheTime:t?1/0:0,suspense:!1})},m=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=(0,l.Z)().fetch,r=(0,c.O)();return(0,i.useQueries)(e.map(function(e){var o={creatorId:e},n=[u.Z["cookbookCreators.recipes"],o];return{queryKey:n,queryFn:function(){return f(d({},o,r),n,t)},enabled:!!e,suspense:!1}}
1))}},571321:function(e,t,r){"use strict";r.d(t,{qZ:function(){return y},vV:function(){return h}});var o,n,i=r(456552),a=r(671718),l=r(447178),c=r(64294),u=r(43011),s=r(140224),p=r(699219);function d(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}function f(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function b(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var m=(o=function(e,t){var r,o,n,i,l,u,s,p,d,m,h=arguments;return function(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}(this,function(y){switch(y.label){case 0:return o=void 0===(r=e.usePublicAuth)||r,n=e.limit,i=e.cursor,l=e.systemCountry,u=e.locale,s=e.parentSpan,[4,(h.length>2&&void 0!==h[2]?h[2]:a.Z)("/cookbook/v1/external-recipes",t,{query:f({country:l,locale:u,hf_public_id:(0,c.ZP)()},void 0!==n&&{limit:n},void 0!==i&&{cursor:i}),parentSpan:s,fetchSpanAttributes:{"request.backend_service":"cookbook-api","request.backend_action":"get-external-recipes"}},{usePublicAuth:o})];case 1:return d=(p=y.sent()).headers.get("X-Free-Recipe-Save-Count"),m=p.headers.get("X-Free-Recipe-Save-Limit"),[4,p.json()];case 2:return[2,b(f({},y.sent()),{freeRecipeSaveCount:d?parseInt(d,10):null,freeRecipeSaveLimit:m?parseInt(m,10):null})]}})},n=function(){var e=this,t=arguments;return new Promise(function(r,n){var i=o.apply(e,t);function a(e){d(i,r,n,a,l,"next",e)}function l(e){d(i,r,n,a,l,"throw",e)}a(void 0)})},function(e,t){return n.apply(this,arguments)}),h=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=(0,l.Z)().fetch,o=(0,u.Z)(),n=f(b(f({},e),{usePublicAuth:!o}),(0,s.O)()),a=[p.Z["externalRecipes.list"],n];return(0,i.useQuery)(a,function(){return m(n,a,r)},f({staleTime:3e5,cacheTime:6e5},t))},y=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=(0,l.Z)().fetch,o=(0,u.Z)(),n=f(b(f({},e),{usePublicAuth:!o}),(0,s.O)()),a=[p.Z["externalRecipes.list"],n];return(0,i.useInfiniteQuery)(a,function(e){var t;return m(f({},n,null!==(t=e.pageParam)&&void 0!==t?t:{}),a,r)},f({getNextPageParam:function(e){return e.pagination.has_more?{cursor:e.pagination.next_cursor}:void 0},staleTime:3e5,cacheTime:6e5},t))}},309273:function(e,t,r){"use strict";r.d(t,{Ej:function(){return i},b9:function(){return n},fu:function(){return c},iQ:function(){return d},zW:function(){return p}});var o=r(892940),n="/gw/cookbook/v1/recipe-developers",i=function(e){return"".concat(n,"/").concat(e)},a=o.z.object({name:o.z.string(),quantity:o.z.string().nullable().optional(),unit:o.z.string().nullable().optional(),thumbnail_url:o.z.string().optional(),image_path:o.z.string().nullable().optional()}),l=o.z.object({index:o.z.number(),instructions:o.z.string()}
1),c=o.z.enum(["creator","customer_image","facebook","hellofresh","instagram","pinterest","tiktok","youtube","unsupported"]),u=o.z.object({id:o.z.string(),url:o.z.string(),title:o.z.string().optional(),headline:o.z.string().optional(),thumbnail_url:o.z.string().optional(),description:o.z.string().optional(),total_time:o.z.string().optional(),has_recipe_extracted:o.z.boolean(),source_platform:c.catch("unsupported"),owner_id:o.z.string(),owner_type:o.z.string().optional(),created_at:o.z.string(),updated_at:o.z.string().optional(),is_bookmark:o.z.boolean().optional(),bookmark_id:o.z.string().optional(),author_name:o.z.string().optional()});u.extend({ingredients:o.z.array(a),steps:o.z.array(l),share_token:o.z.string().optional()}),o.z.object({data:o.z.array(u),pagination:o.z.object({limit:o.z.number(),next_cursor:o.z.string().optional(),has_more:o.z.boolean()})});var s=o.z.enum(["instagram","youtube","tiktok","x","website"]),p=o.z.object({id:o.z.string(),type:o.z.string(),name:o.z.string(),slug:o.z.string(),bio:o.z.string(),headshotImage:o.z.object({url:o.z.string().optional()}).partial().passthrough(),socialLinks:o.z.array(o.z.object({platform:s,url:o.z.string()}).passthrough()),recipes:o.z.array(o.z.object({websiteUrl:o.z.string(),description:o.z.string().optional(),imageUrl:o.z.string().optional()}).passthrough())}).partial().passthrough(),d=o.z.object({avatarRef:o.z.string().nullable(),bio:o.z.string().max(300),socialLinks:o.z.array(o.z.object({platform:s,url:o.z.string().url(),id:o.z.string().optional()})),name:o.z.string().optional(),slug:o.z.string().optional(),consentChecked:o.z.boolean()})},122810:function(e,t,r){"use strict";r.d(t,{t:function(){return g}});var o,n=r(456552),i=r(671718),a=r(447178),l=r(43011),c=r(140224),u=r(699219);function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function p(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}function d(e){return function(){var t=this,r=arguments;return new Promise(function(o,n){var i=e.apply(t,r);function a(e){p(i,o,n,a,l,"next",e)}function l(e){p(i,o,n,a,l,"throw",e)}a(void 0)})}}function f(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function b(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function m(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}var h=function(e,t){for(var r=[],o=0;o<e.length;o+=t)r.push(e.slice(o,o+t));return r},y=(o=d(function(e,t){var r,o,n,a,l,c,u,s,p,f,b=arguments;return m(this,function(y){switch(y.label){case 0:var g;if(r=e.bookmarkIds,n=void 0!==(o=e.usePublicAuth)&&o,a=e.systemCountry,l=e.locale,c=e.parentSpan,u=b.length>2&&void 0!==b[2]?b[2]:i.Z,0===r.length)return[2,{bookmarkIds:[],recipeIdsByBookmarkId:{}}];return[4,Promise.all(h(r,50).map((g=d(function(e){return m(this,function(r){switch(r.label){case 0:return[4,u("/cookbook/v1/internal-recipes/search",t,{method:"POST",headers:{"Content-Type":"application/json"},query:{country:a,locale:l},data:{bookmark_ids:e},parentSpan:c,fetchSpanAttributes:{"request.backend_service":"cookbook-api","request.backend_action":"search-bookmarked-recipes"}},{usePublicAuth:n})];case 1:return[4,r.sent().json()];case 2:return[2,r.sent()]}})}),function(e){return g.apply(this,arguments)})))];case 1:return s=y.sent(),p=new Set,f={}
1,s.forEach(function(e){var t;return null===(t=e.recipes)||void 0===t?void 0:t.forEach(function(e){p.add(e.bookmark_id),f[e.bookmark_id]=e.id})}),[2,{bookmarkIds:Array.from(p),recipeIdsByBookmarkId:f}]}})}),function(e,t){return o.apply(this,arguments)}),g=function(e){var t,r,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=(0,a.Z)().fetch,p=(0,l.Z)(),d=((function(e){if(Array.isArray(e))return s(e)})(t=e.bookmarkIds)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||function(e,t){if(e){if("string"==typeof e)return s(e,void 0);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return s(e,void 0)}}(t)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).sort(),m=f(b(f({},e),{bookmarkIds:d,usePublicAuth:!p}),(0,c.O)()),h=[u.Z["internalRecipes.search"],m],g=null===(r=o.enabled)||void 0===r||r;return(0,n.useQuery)(h,function(){return y(m,h,i)},b(f({staleTime:3e5,cacheTime:6e5,suspense:!1},o),{enabled:p&&d.length>0&&g}))}},209628:function(e,t,r){"use strict";var o=r(669524),n=r(591953);function i(e,t){for(var r=0;r<t.length;r++){var o=t[r];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}function a(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var l=function(){var e,t;function r(e,t){var n,i=this;!function(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}(this,r),a(this,"id",void 0),a(this,"delayedTimer",void 0),a(this,"content",void 0),this.content=e,this.id=null!==(n=null==t?void 0:t.id)&&void 0!==n?n:(0,o.x)(),this.delayedTimer=(null==t?void 0:t.delayedTimer)?setTimeout(function(){return i.close()},t.delayedTimer):void 0}return e=[{key:"close",value:function(){var e=this;this.delayedTimer&&clearTimeout(this.delayedTimer),(0,n.Fh)(function(t){return t.id==e.id}),(0,n.VW)()}}],t=[{key:"create",value:function(e,t){return new r(e,t)}}],e&&i(r.prototype,e),t&&i(r,t),r}();t.Z=l},287354:function(e,t,r){"use strict";r.r(t),r.d(t,{__N_SSP:function(){return n9},default:function(){return ie}});var o,n,i,a,l,c,u,s=r(687800),p=r(827378),d=r(188038),f=r.n(d),b=r(581340),m=r(650603),h=r(31748),y=r(768587),g=r(463171),v=r(571321),k=r(96840),w=r(456552),O=r(671718),x=r(447178),S=r(64294),C=r(43011),j=r(140224),P=r(699219);function _(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}function Z(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function I(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var E=(o=function(e,t){var r,o,n,i,a,l,c,u,s,p,d,f=arguments;return function(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}(this,function(b){switch(b.label){case 0:return r=e.description,n=void 0===(o=e.usePublicAuth)||o,a=void 0!==(i=e.addMissingDetails)&&i,l=e.systemCountry,c=e.locale,u=e.parentSpan,[4,(f.length>2&&void 0!==f[2]?f[2]:O.Z)("/cookbook/v2/external-recipes",t,{method:"POST",headers:{"Content-Type":"application/json","X-Import-Source":"web_manual_text_entry"},query:Z({country:l,locale:c,hf_public_id:(0,S.ZP)()},a?{add_missing_details:!0}:{}),data:{description:r},timeout:12e4,parentSpan:u,fetchSpanAttributes:{"request.backend_service":"cookbook-api","request.backend_action":"create-external-recipe-by-description"}},{usePublicAuth:n})];case 1:return p=(s=b.sent()).headers.get("X-Free-Recipe-Save-Count"),d=s.headers.get("X-Free-Recipe-Save-Limit"),[4,s.json()];case 2:return[2,I(Z({},b.sent()),{freeRecipeSaveCount:p?parseInt(p,10):null,freeRecipeSaveLimit:d?parseInt(d,10):null})]}})},n=function(){var e=this,t=arguments;return new Promise(function(r,n){var i=o.apply(e,t);function a(e){_(i,r,n,a,l,"next",e)}function l(e){_(i,r,n,a,l,"throw",e)}a(void 0)})},function(e,t){return n.apply(this,arguments)}),R=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=(0,x.Z)().fetch,r=(0,C.Z)(),o=(0,j.O)(),n=(0,w.useQueryClient)(),i=[P.Z["externalRecipes.createFromDescription"]];return(0,w.useMutation)(function(e){return E(Z(I(Z({},e),{usePublicAuth:!r}),o),i,t)},I(Z({},e),{onSuccess:function(t,r,o){var i;n.invalidateQueries(P.Z["externalRecipes.list"]),null===(i=e.onSuccess)||void 0===i||i.call(e,t,r,o)}}))},A=r(3032);function T(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function D(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}function L(e){return function(){var t=this,r=arguments;return new Promise(function(o,n){var i=e.apply(t,r);function a(e){D(i,o,n,a,l,"next",e)}function l(e){D(i,o,n,a,l,"throw",e)}a(void 0)})}}function B(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);
1"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function M(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function V(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}var U=(i=L(function(e,t){var r,o,n,i,a,l,c,u,s=arguments;return V(this,function(p){switch(p.label){case 0:return r=e.fileName,o=e.mimeType,n=e.fileSizeBytes,a=void 0===(i=e.usePublicAuth)||i,l=e.systemCountry,c=e.locale,u=e.parentSpan,[4,(s.length>2&&void 0!==s[2]?s[2]:O.Z)("/cookbook/v1/external-recipes/upload-url",t,{method:"POST",headers:{"Content-Type":"application/json"},query:{country:l,locale:c,hf_public_id:(0,S.ZP)()},data:{file_name:r,mime_type:o,file_size_bytes:n},timeout:3e4,parentSpan:u,fetchSpanAttributes:{"request.backend_service":"cookbook-api","request.backend_action":"get-upload-url"}},{usePublicAuth:a})];case 1:return[2,p.sent().json()]}})}),function(e,t){return i.apply(this,arguments)}),N=(a=L(function(e){var t,r,o,n,i;return V(this,function(a){switch(a.label){case 0:return t=e.uploadUrl,r=e.uploadFields,o=e.file,n=new FormData,Object.entries(r).forEach(function(e){var t=function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,2)||function(e,t){if(e){if("string"==typeof e)return T(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return T(e,2)}}(e,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],o=t[1];n.append(r,o)}),n.append("file",o),[4,window.fetch(t,{method:"POST",body:n})];case 1:if(!(i=a.sent()).ok)throw Error("S3 upload failed with status ".concat(i.status));return[2]}})}),function(e){return a.apply(this,arguments)}),z=(l=L(function(e,t){var r,o,n,i,a,l,c,u,s,p=arguments;return V(this,function(d){switch(d.label){case 0:return r=e.imageRef,n=void 0===(o=e.usePublicAuth)||o,i=e.systemCountry,a=e.locale,l=e.parentSpan,[4,(p.length>2&&void 0!==p[2]?p[2]:O.Z)("/cookbook/v2/external-recipes",t,{method:"POST",headers:{"Content-Type":"application/json","X-Import-Source":"image_import_web"},query:{country:i,locale:a,hf_public_id:(0,S.ZP)()},data:{url:"",image_ref:r},timeout:12e4,parentSpan:l,fetchSpanAttributes:{"request.backend_service":"cookbook-api","request.backend_action":"create-external-recipe-from-image"}},{usePublicAuth:n})];case 1:return u=(c=d.sent()).headers.get("X-Free-Recipe-Save-Count"),s=c.headers.get("X-Free-Recipe-Save-Limit"),[4,c.json()];case 2:return[2,M(B({},d.sent()),{freeRecipeSaveCount:u?parseInt(u,10):null,freeRecipeSaveLimit:s?parseInt(s,10):null})]}})}),function(e,t){return l.apply(this,arguments)}),X=function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=(0,x.Z)().fetch,o=!(0,C.Z)(),n=(0,j.O)(),i=(0,w.useQueryClient)(),a=[P.Z["externalRecipes.uploadUrl"]],l=[P.Z["externalRecipes.create"]];return(0,w.useMutation)((e=L(function(e){var t,i;return V(this,function(c){switch(c.label){case 0:return[4,U(B({f
1ileName:(t=e.file).name,mimeType:t.type,fileSizeBytes:t.size,usePublicAuth:o},n),a,r)];case 1:return[4,N({uploadUrl:(i=c.sent()).upload_url,uploadFields:i.upload_fields,file:t})];case 2:return c.sent(),[2,z(B({imageRef:i.image_ref,usePublicAuth:o},n),l,r)]}})}),function(t){return e.apply(this,arguments)}),M(B({},t),{onSuccess:function(e,r,o){var n;i.invalidateQueries(P.Z["externalRecipes.list"]),null===(n=t.onSuccess)||void 0===n||n.call(t,e,r,o)}}))},F=r(164528),H={ANONYMOUS_LIMIT_REACHED:"You have reached the recipe limit.",AI_SERVICE_UNAVAILABLE:"Our AI is temporarily unavailable. Please try again in a moment.",URL_UNREACHABLE:"We couldn't reach this URL. Check the link and try again.",CONTENT_EMPTY:"We couldn't extract a recipe from this page.",EXTRACTION_FAILED:"We couldn't extract a recipe from this page.",RECIPE_NOT_DETECTED:"No recipe was detected on this page.",VIDEO_TOO_LONG:"This video is too long to process.",MULTIPLE_RECIPES:"Multiple recipes were detected. Try a more specific URL.",MULTIPLE_LANGUAGES:"Multiple languages were detected on this page.",PLATFORM_NOT_SUPPORTED:"We don't support importing from this site yet.",URL_NOT_SUPPORTED:"This URL is not supported.",IMAGE_NOT_FOOD_RELATED:"This page doesn't seem to contain a food recipe.",CONTENT_ACCESS_RESTRICTED:"This page is private or login-protected.",TRANSCRIPT_EXTRACTION_FAILED:"We had trouble reading this video's audio.",TIMEOUT:"This is taking longer than usual. Please try again.",DUPLICATE:"You've already saved this recipe.",PARSE_FAILURE:"We couldn't read this page properly. Try a different link.",RATE_LIMIT:"You're going a bit fast. Please wait a moment and try again.",OFFLINE:"You're offline. Check your connection and try again."},q=function(e){var t,r,o=null!==(t=e.name)&&void 0!==t?t:"",n=null!==(r=e.message)&&void 0!==r?r:"";return"AbortError"===o||"TimeoutError"===o||/timeout/i.test(n)},Y=function(e){if(!("undefined"==typeof navigator||!1!==navigator.onLine))return!0;var t,r,o=null!==(r=e.message)&&void 0!==r?r:"";return(null!=(t=TypeError)&&"undefined"!=typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t)||/network|fetch failed/i.test(o)},W=function(e){try{if(e.responseResult&&"string"==typeof e.responseResult){var t,r=JSON.parse(e.responseResult);return null!==(t=r.error_code)&&void 0!==t?t:null}}catch(e){}return null},K=function(e){if(!e)return null;if(Y(e))return"OFFLINE";if(q(e))return"TIMEOUT";var t,r=null===(t=e.response)||void 0===t?void 0:t.status;return 429===r?"RATE_LIMIT":409===r?"DUPLICATE":W(e)||("number"==typeof r&&r>=500?"PARSE_FAILURE":"TRANSPORT")},G=function(e,t){return e&&H[e]?t("cookbook.import.error.".concat(e.toLowerCase()))||H[e]:t("cookbook.import.error.generic")||"Something went wrong. Please try again."},J=r(718583),$="hf_cookbook_imports",Q=function(){try{var e=J.ZP.getItem($);return e?JSON.parse(e):[]}catch(e){return[]}},ee=function(e){try{J.ZP.setItem($,JSON.stringify(e))}catch(e){}},et=r(410310);function er(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function eo(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return er(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return er(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var en=["creator","hellofresh"],ei=function(e){var t;return e?Array.isArray(e)?null!==(t=e[0])&&void 0!==t?t:null:e:null},ea=function(e){var t=e.isCustomer,r=e.isAtLimit,o=e.isListLoaded,n=(0,F.ZP)("cookbook").translateRaw,i=(0,b.t)(),a=(0,p.useRef)(!1),l=eo((0,p.useState)(!1),2),c=l[0],u=l[1],s=eo((0,p.useState)(null),2),d=s[0],f=s[1],m=eo((0,p.useState)(!1),2),h=m[0],y=m[1],g=(0,et.K)(),v=g.mutateAsync,k=g.isLoading;return(0,p.useEffect)(function(){if(i.isReady&&!a.current&&o){var e=ei(i.query.bookmarkId);if(e){a.current=!0;var l=function(){i.replace("/cookbook/import",void 0,{shallow:!0})},c=ei(i.query.bookmarkSource);if(!c||!en.includes(c)){l();return}if(!t&&r){u(!0),l();return}f(null),v({bookmarkId:e,bookmarkSource:c}).then(function(){y(!0)}).catch(function(e){f(G(K(e),n))}).finally(l)}}},[i,o,r,t,v,n]),{isCreatingInternal:k,arrivedAtCap:c,consumeError:d,consumeSucceeded:h}},el=r(52130),ec=r(466630),eu=r(440716),es=r(211784),ep=r(182336),ed=function(e){var t,r,o,n;return null!==(n=null!==(o=null===(t=e.recipeDeveloper)||void 0===t?void 0:t.displayName)&&void 0!==o?o:null===(r=e.recipeDeveloper)||void 0===r?void 0:r.name)&&void 0!==n?n:null},ef=function(){var e=(0,el.L3)().trackJanusEvent;return{trackRecipeSaveSuccess:(0,p.useCallback)(function(t){var r,o,n,i,a=t.recipeId,l=t.recipeImportMethod,c=t.collectionId,u=t.recipe,s=t.recipeSourceType;e(ec.Dz.janusEvent({event:ec.Dz.event({systemMessage:null}),cookbookCollectionState:ec.Dz.cookbookCollectionState({collectionId:c,collectionName:ec.vQ.AllSaved}),cookbookRecipeAction:ec.Dz.cookbookRecipeAction({recipeId:a,recipeImportMethod:l})})),e(es.FW.janusEvent({event:es.FW.event({systemMessage:null}),cookbookRecipeAction:es.FW.cookbookRecipeAction({recipeId:a}),recipeView:es.FW.recipeView({authorId:null!==(o=null==u?void 0:null===(r=u.recipeDeveloper)||void 0===r?void 0:r.id)&&void 0!==o?o:null,authorName:u?ed(u):null,recipeId:null!==(n=null==u?void 0:u.id)&&void 0!==n?n:a,recipeSourceType:null!=s?s:es.m4.Unknown,recipeTags:null!==(i=null==u?void 0:u.tags.map(function(e){return e.name}))&&void 0!==i?i:[]})}))},[e]),trackRecipeSaveError:(0,p.useCallback)(function(t){var r=t.recipeId,o=t.recipeImportMethod,n=t.collectionId,i=t.systemMessage;e(eu.EC.janusEvent({event:eu.EC.event({systemMessage:i}),cookbookCollectionState:eu.EC.cookbookCollectionState({collectionId:n,collectionName:eu.vQ.AllSaved}),cookbookRecipeAction:eu.EC.cookbookRecipeAction({recipeId:r,recipeImportMethod:o})})),e(ep.C.janusEvent({event:ep.C.event({systemMessage:i})}))},[e])}},eb="AllSaved",em=function(){var e=ef(),t=e.trackRecipeSaveSuccess,r=e.trackRecipeSaveError;return{fireSaveSuccess:(0,p.useCallback)(function(e,r){return t({recipeId:r,recipeImportMethod:e,collectionId:eb,recipeSourceType:es.m4.External})},[t]),fireSaveError:(0,p.useCallback)(function(e,t){return r({recipeId:"",recipeImportMethod:e,collectionId:eb,systemMessage:t})},[r])}},eh=function(e){try{return new URL(e).hostname.replace(/^www\./,"")}catch(t){return e}},ey=function(e){return{id:e.id,url:e.url,title:e.title||eh(e.url),hostname:eh(e.url),thumbnailUrl:e.thumbnail_url||null,shareToken:null,importedAt:e.created_at,
1sourcePlatform:e.source_platform,authorName:e.author_name}};function eg(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function ev(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}function ek(e){return function(){var t=this,r=arguments;return new Promise(function(o,n){var i=e.apply(t,r);function a(e){ev(i,o,n,a,l,"next",e)}function l(e){ev(i,o,n,a,l,"throw",e)}a(void 0)})}}function ew(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return eg(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return eg(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function eO(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}var ex=function(){var e,t,r,o,n,i,a,l,c,u,s,d=(0,F.ZP)("cookbook").translateRaw,f=(0,C.Z)(),b=ew((0,p.useState)(null),2),m=b[0],h=b[1],y=ew((0,p.useState)(null),2),g=y[0],w=y[1],O=(0,p.useCallback)(function(e){return w(e?{message:e}:null)},[]),x=ew((0,p.useState)([]),2),S=x[0],j=x[1],P=ew((0,p.useState)(!1),2),_=P[0],Z=P[1],I=ew((0,p.useState)(!1),2),E=I[0],T=I[1];(0,p.useEffect)(function(){j(Q()),Z(!0)},[]);var D=(0,v.qZ)({limit:6},{suspense:!1,refetchOnMount:!0,staleTime:3e5,cacheTime:6e5,onSuccess:function(e){var t=e.pages.flatMap(function(e){return e.data}).map(ey);ee(t),j(t)}}),L=D.data,B=D.isLoading,M=D.isSuccess,V=D.refetch,U=D.fetchNextPage,N=D.isFetchingNextPage,z=(0,k.N)(),H=z.mutateAsync,q=z.isLoading,Y=R(),W=Y.mutateAsync,J=Y.isLoading,$=(0,A.x)().mutateAsync,et=X(),er=et.mutateAsync,eo=et.isLoading,en=em(),ei=en.fireSaveSuccess,el=en.fireSaveError,eu=M?(null!==(i=null==L?void 0:L.pages.flatMap(function(e){return e.data}))&&void 0!==i?i:[]).map(ey):S,es=null!==(a=null==L?void 0:null===(t=L.pages[L.pages.length-1])||void 0===t?void 0:t.pagination.has_more)&&void 0!==a&&a,ep=null!==(l=null==L?void 0:null===(r=L.pages[0])||void 0===r?void 0:r.freeRecipeSaveLimit)&&void 0!==l?l:3,ed=null!==(c=null==L?void 0:null===(o=L.pages[0])||void 0===o?void 0:o.freeRecipeSaveCount)&&void 0!==c?c:eu.length,ef=!f&&ed>=ep,eb=eu.some(function(e){return"creator"!==e.sourcePlatform&&"hellofresh"!==e.sourcePlatform}),eh=eu.map(function(e){return e.title}).filter(Boolean),eg=null!==(u=null===(n=eu[0])||void 0===n?void 0:n.thumbnailUrl)&&void 0!==u?u:null,ev=(0,p.useCallback)(function(){T(!0),V().catch(function(){}).finally(function(){return T(!1)})},[V]),ex=ea({isCustomer:f,isAtLimit:ef,isListLoaded:M}),eS=ex.isCreatingInternal,eC=ex.arrivedAtCap,ej=ex.consumeError,eP=ex.consumeSucceeded;(0,p.useLayoutEffect)(function(){eP&&ev()},[eP,ev]),(0,p.useEffect)(function(){ej&&O(ej)},[ej,O]);var e_=function(){return d("cookbook.import.error.limit_reached",{limit:String(ep),defaultValue:"You have reached the ".concat(ep," recipe limit.")})},eZ=function(e,t){var r=K(e);O(G(r,d)),el(t,r)},eI=(0,p.useCallback)(function(e){var t;h(null),O(null);try{t=new URL(e.trim()).toString()}
1catch(e){return h(d("cookbook.import.error.invalid_url",{defaultValue:"Please enter a valid URL."})),el(ec.L2.LinkImported,"INVALID_URL"),!1}return ef?(h(e_()),el(ec.L2.LinkImported,"ANONYMOUS_LIMIT_REACHED"),!1):(ek(function(){var e;return eO(this,function(r){switch(r.label){case 0:return r.trys.push([0,2,,3]),[4,H({url:t})];case 1:return e=r.sent(),ev(),ei(ec.L2.LinkImported,e.id),[3,3];case 2:return eZ(r.sent(),ec.L2.LinkImported),[3,3];case 3:return[2]}})})(),!0)},[ef,ep,H,d]),eE=(0,p.useCallback)(function(e){return(h(null),O(null),ef)?(h(e_()),el(ec.L2.PhotoImported,"ANONYMOUS_LIMIT_REACHED"),!1):e.type.startsWith("image/")?(ek(function(){var t;return eO(this,function(r){switch(r.label){case 0:return r.trys.push([0,2,,3]),[4,er({file:e})];case 1:return t=r.sent(),ev(),ei(ec.L2.PhotoImported,t.id),[3,3];case 2:return eZ(r.sent(),ec.L2.PhotoImported),[3,3];case 3:return[2]}})})(),!0):(h(d("cookbook.import.error.not_image",{defaultValue:"Please select an image file."})),el(ec.L2.PhotoImported,"NOT_IMAGE"),!1)},[ef,ep,er,d]),eR=(0,p.useCallback)(function(e){if(h(null),O(null),ef)return h(e_()),el(ec.L2.ManualImported,"ANONYMOUS_LIMIT_REACHED"),!1;var t=e.trim();return t?(ek(function(){var e;return eO(this,function(r){switch(r.label){case 0:return r.trys.push([0,2,,3]),[4,W({description:t})];case 1:return e=r.sent(),ev(),ei(ec.L2.ManualImported,e.id),[3,3];case 2:return eZ(r.sent(),ec.L2.ManualImported),[3,3];case 3:return[2]}})})(),!0):(h(d("cookbook.import.error.empty_text",{defaultValue:"Please enter some recipe text."})),el(ec.L2.ManualImported,"CONTENT_EMPTY"),!1)},[ef,ep,W,d]),eA=(0,p.useCallback)(function(){return h(null)},[]),eT=(0,p.useCallback)((e=ek(function(e){return eO(this,function(t){switch(t.label){case 0:return t.trys.push([0,2,,3]),[4,$({id:e})];case 1:case 2:return t.sent(),[3,3];case 3:return[2]}})}),function(t){return e.apply(this,arguments)}),[$]);return{recipes:eu,isLoaded:M||_&&!B,importing:q||eS||J||eo||E,importError:null!==(s=null!=m?m:null==g?void 0:g.message)&&void 0!==s?s:null,validationError:m,clearValidationError:eA,importErrorEvent:g,isAtLimit:ef,isCustomer:f,importRecipe:eI,importRecipeFromImage:eE,importRecipeFromText:eR,removeRecipe:eT,hasImportedRecipes:eb,recipeTitles:eh,firstRecipeThumbnailUrl:eg,arrivedAtCap:eC,hasMore:es,isLoadingMore:N,loadMore:U}};function eS(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function eC(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function ej(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var eP=r(892940),e_=r(309273);function eZ(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}function eI(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}var eE=eP.z.object({id:eP.z.string(),name:eP.z.string(),imageLink:eP.z.string().optional(),imagePath:eP.z.string().optional(),websiteUrl:eP.z.string().optional(),totalTime:eP.z.string().optional(),prepTime:eP.z.string().optional(),headline:eP.z.string().optional(),description:eP.z.string().optional(),is_bookmarked:eP.z.boolean().optional(),is_community:eP.z.boolean().optional(),source_platform:e_.fu.catch("unsupported"),author:eP.z.string().optional(),is_owner:eP.z.boolean().optional()}),eR=eP.z.object({total:eP.z.number(),count:eP.z.number(),take:eP.z.number(),skip:eP.z.number(),next_page_token:eP.z.string().optional(),items:eP.z.array(eE)}),eA=(c=function(e,t){var r,o,n,i,a,l,c,u,s=arguments;return function(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}(this,function(p){switch(p.label){case 0:return o=void 0===(r=e.usePublicAuth)||r,n=e.take,i=e.ski
1p,a=e.systemCountry,l=e.locale,c=e.parentSpan,[4,(s.length>2&&void 0!==s[2]?s[2]:O.Z)("/gw/cookbook/v1/discovery/community",t,{query:eI({country:a,locale:l,hf_public_id:(0,S.ZP)()},void 0!==n&&{take:String(n)},void 0!==i&&{skip:String(i)}),parentSpan:c,fetchSpanAttributes:{"request.backend_service":"cookbook-api","request.backend_action":"get_community_recipes"}},{usePublicAuth:o})];case 1:return[4,p.sent().json()];case 2:return u=p.sent(),[2,eR.parse(u)]}})},u=function(){var e=this,t=arguments;return new Promise(function(r,o){var n=c.apply(e,t);function i(e){eZ(n,r,o,i,a,"next",e)}function a(e){eZ(n,r,o,i,a,"throw",e)}i(void 0)})},function(e,t){return u.apply(this,arguments)}),eT=function(e){var t,r,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=(0,x.Z)().fetch,i=(0,C.Z)(),a=eI((t=eI({},e),r=r={usePublicAuth:!i},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t),(0,j.O)()),l=[P.Z["cookbookDiscoveryCommunity.list"],a];return(0,w.useQuery)(l,function(){return eA(a,l,n)},eI({suspense:!1,staleTime:3e5,cacheTime:6e5},o))},eD="CookbookCommunityCarousel",eL={ctaTile:"cookbook-community-carousel-cta-tile",ctaSave:"cookbook-community-carousel-cta-save",ctaLearnHow:"cookbook-community-carousel-cta-learn-how",card:"cookbook-community-carousel-card"},eB=function(){var e=eT({take:10,skip:0}),t=(0,p.useMemo)(function(){var t,r;return null!==(r=null===(t=e.data)||void 0===t?void 0:t.items)&&void 0!==r?r:[]},[e.data]),r=(0,p.useMemo)(function(){return e.isLoading?"loading":e.isError?"error":0===t.length?"empty":"success"},[e.isLoading,e.isError,t.length]);return{recipes:t,status:r}},eM=r(46152),eV=r(10454),eU=r(857222);function eN(){var e,t,r=(e=["\n  display: flex;\n  align-items: center;\n  min-height: 68px;\n  cursor: text;\n  border: 1px solid\n    ",";\n  border-radius: 999px;\n  padding: 8px 16px;\n  background: #ffffff;\n  box-shadow: 0px 1px 3px rgba(35, 26, 10, 0.06);\n  gap: 10px;\n  transition: border-color 0.2s;\n\n  &:focus-within {\n    border-color: ",";\n  }\n\n  & textarea {\n    flex: 1;\n    border: none;\n    outline: none;\n    font-family: 'Roboto', sans-serif;\n    font-size: 17px;\n    line-height: 20px;\n    background: transparent;\n    min-width: 0;\n    resize: none;\n    padding: 0;\n    field-sizing: content;\n    max-height: 60px;\n    overflow-y: auto;\n    overflow-x: hidden;\n    white-space: nowrap;\n    scrollbar-width: none;\n\n    &::-webkit-scrollbar {\n      display: none;\n    }\n\n    &::placeholder {\n      color: #656565;\n    }\n  }\n"],t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}})));return eN=function(){return r},r}var ez=(0,eU.ZP)(y.xu).withConfig({componentId:"sc-b39ae449-0"})(eN(),function(e){var t,r,o,n,i=e.$hasError,a=e.theme;return i?(null===(r=a.colors)||void 0===r?void 0:null===(t=r.error)||void 0===t?void 0:t[600])||"#d32f2f":(null===(n=a.colors)||void 0===n?void 0:null===(o=n.neutral)||void 0===o?void 0:o[300])||"#e0e0e0"},function(e){var t,r,o,n,i=e.$hasError,a=e.theme;return i?(null===(r=a.colors)||void 0===r?void 0:null===(t=r.error)||void 0===t?void 0:t[600])||"#d32f2f":(null===(n=a.colors)||void 0===n?void 0:null===(o=n.neutral)||void 0===o?void 0:o[500])||"#656565"}),eX=r(660061),eF=function(e){var t=e.onClick,r=e.isDisabled,o=(0,F.ZP)("cookbook").translateRaw;return(0,s.BX)(y.xu,{as:"button",type:"button",display:"flex",alignItems:"center",flexShrink:"0",gap:"global.xxs",bg:"transparent",borderWidth:"0",cursor:"pointer",opacity:r?"0.5":"1",color:"neutral.800",disabled:r,onClick:t,"data-test-id":"cookbook-import-paste-button",children:[(0,s.tZ)(y.JO,{icon:(0,s.tZ)(eX.default,{}),color:"inherit"}),(0,s.tZ)(y.xv,{type:"body-sm-bold",color:"inherit",children:o("cookbook.import.input.paste_button",{defaultValue:"Paste"})})]})},eH=r(60074),eq=r(387426),eY=r(799546),eW=r(304480),eK=r(58604),eG=function(){var e=(0,el.L3)().trackJanusEvent,t=(0,p.useRef)(!1),r=(0,p.useCallback)(function(e,t){try{t()}catch(t){(0,eH.Tb)(t,{tags:{event:e,component:"useImportInputTracking"}})}},[]);return{trackUploadPhotoClick:(0,p.useCallback)(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{componentName:"cookbook-import-photo-button",componentLabel:"Upload photo"},o=t.componentName,n=t.componentLabel;r("Cookbook_Start_Import_Button_Click",function(){return e(eq.Eq.janusEvent({uiComponent:eq.Eq.uiComponent({uiComponentName:o,uiComponentLabel:n}),uiModal:eq.Eq.uiModal({uiModalName:eq.E5.Photo})}))})},[r,e]),trackInputFieldFocus:(0,p.useCallback)(function(){t.current||(t.current=!0,r("Cookbook_Start_Import_InputField_Click",function(){return e(eW.C.janusEvent())}
1))},[r,e]),trackImportSubmitClick:(0,p.useCallback)(function(){r("Cookbook_Save_Recipe_Button_Click",function(){return e(eK.t8.janusEvent({cookbookRecipeAction:eK.t8.cookbookRecipeAction({recipeId:"",recipeImportMethod:eK.L2.LinkImported})}))})},[r,e]),trackTextImportClick:(0,p.useCallback)(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{componentName:"cookbook-add-recipe-dialog-paste-text-button",componentLabel:"Paste recipe text"},o=t.componentName,n=t.componentLabel;r("Cookbook_Start_Import_Button_Click",function(){return e(eY.Eq.janusEvent({uiComponent:eY.Eq.uiComponent({uiComponentName:o,uiComponentLabel:n,uiComponentPosition:null}),uiModal:eY.Eq.uiModal({uiModalName:eY.E5.RecipeAddMenu})}))})},[r,e])}};function eJ(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function e$(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}var eQ="image/jpeg,image/png,image/webp,image/heic",e0=function(e){var t,r,o,n=e.onImport,i=e.onImageImport,a=(0,F.ZP)("cookbook").translateRaw,l=function(e){if(Array.isArray(e))return e}(t=(0,p.useState)(""))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(t,2)||function(e,t){if(e){if("string"==typeof e)return eJ(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return eJ(e,2)}}(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),c=l[0],u=l[1],s=(0,p.useRef)(null),d=!i,f=eG(),b=f.trackUploadPhotoClick,m=f.trackInputFieldFocus,h=f.trackImportSubmitClick,y=(r=function(){var e,t,r;return function(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}(this,function(o){switch(o.label){case 0:return o.trys.push([0,2,3,4]),[4,null===(e=navigator.clipboard)||void 0===e?void 0:e.readText()];case 1:return(t=o.sent())&&u(t),[3,4];case 2:return o.sent(),[3,4];case 3:return null===(r=document.getElementById("cookbook-import-url-input"))||void 0===r||r.focus(),[7];case 4:return[2]}})},o=function(){var e=this,t=arguments;return new Promise(function(o,n){var i=r.apply(e,t);function a(e){e$(i,o,n,a,l,"next",e)}function l(e){e$(i,o,n,a,l,"throw",e)}a(void 0)})},function(){return o.apply(this,arguments)}),g=d?a("cookbook.import.add_recipe_dialog.input_placeholder",{defaultValue:"Paste your link here"}):a("cookbook.import.save_bar.placeholder"),v=a("cookbook.import.input.upload_photo_aria_label")||"Upload a photo of a recipe",k=a("cookbook.import.input.label")||"Paste a recipe link",w=a("cookbook.import.save_bar.submit");return{data:{value:c,isDialogVariant:d,fileInputRef:s},translations:{placeholder:g,photoAriaLabel:v,fileInputAriaLabel:"".concat(v," (JPEG, PNG, WebP, or HEIC)"),inputLabel:k,submitLabel:w},handlers:{setValue:u,handlePillClick:function(e){var t,r=e.target;"BUTTON"===r.tagName||r.closest("button")||null===(t=document.getElementById("cookbook-import-url-input"))||void 0===t||t.focus()},handleSubmit:function(e){e.preventDefault(),c.trim()&&(h(),n(c.trim()),u(""))},handleFileChange:function(e){var t,r=null===(t=e.target.files)||void 0===t?void 0:t[0];r&&(null==i||i(r)),s.current&&(s.current.value="")},handleUploadPhotoClick:function(){var e;b(),null===(e=s.current)||void 0===e||e.click()},handleClipboardPaste:y,trackInputFieldFocus:m}}},e1=(0,p.forwardRef)(function(e,t){var r=e.onImport,o=e.onImageImport,n=e.isLoading,i=e.isDisabled,a=e.error,l=e0({onImport:r,onImageImport:o}),c=l.data,u=l.translations,p=l.handlers,d=c.value,f=c.isDialogVariant,b=c.fileInputRef,m=u.placeholder,h=u.photoAriaLabel,g=u.fileInputAriaLabel,v=u.inputLabel,k=u.submitLabel,w=p.setValue,O=p.handlePillClick,x=p.handleSubmit,S=p.handleFileChange,C=p.handleUploadPhotoClick,j=p.handleClipboardPaste,P=p.trackInputFieldFocus;return(0,s.BX)(y.xu,{as:"form",onSubmit:x,children:[(0,s.BX)(y.xu,{display:"flex",flexDirection:f?"column":["column","row"],gap:"global.md-1",alignItems:f?"stretch":["stretch","center"],children:[(0,s.BX)(ez,{flex:"1",$hasError:!!a,onClick:O,children:[(0,s.tZ)(y.JO,{icon:(0,s.tZ)(eM.default,{}),color:"neutral.600"}),(0,s.tZ)("label",{htmlFor:"cookbook-import-url-input",style:{position:"absolute",width:"1px",height:"1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap"},children:v}),(0,s.tZ)("textarea",{ref:t,id:"cookbook-import-url-input",rows:1,placeholder:m,value:d,onChange:function(e){return w(e.target.value)},onFocus:P,disabled:i||n,autoComplete:"off","aria-describedby":a?"cookbook-import-error":void 0,"data-test-id":"
1cookbook-import-url-input"}),o?(0,s.tZ)(y.hU.Tertiary,{icon:(0,s.tZ)(eV.default,{}),size:"sm",type:"button",disabled:i||n,onClick:C,"aria-label":h,"data-test-id":"cookbook-import-photo-button"}):(0,s.tZ)(eF,{onClick:j,isDisabled:i||n})]}),(0,s.tZ)(y.xu,{flexShrink:f?void 0:"0",width:f?"100%":void 0,children:(0,s.tZ)(y.zx.Primary,{type:"submit",width:f?"100%":"auto",disabled:!d.trim()||i||n,loading:n,"data-test-id":"cookbook-import-submit-button",children:k})})]}),a&&(0,s.tZ)(y.xu,{mt:"global.xs",px:"global.sm-2",id:"cookbook-import-error",role:"alert",children:(0,s.tZ)(y.xv,{type:"body-sm-regular",color:"error.600",children:a})}),o&&(0,s.tZ)("input",{ref:b,type:"file",accept:eQ,onChange:S,"aria-label":g,style:{display:"none"},"data-test-id":"cookbook-import-file-input"})]})}),e2=r(987167),e4=function(e){var t=e.onClick,r=(0,F.ZP)("cookbook").translateRaw,o=(0,s.tZ)(y.zx.Primary,{leadingIcon:(0,s.tZ)(e2.default,{}),width:"auto",onClick:t,"data-test-id":"cookbook-save-recipe-cta",size:"lg",children:r("cookbook.import.save_bar.submit")});return(0,s.BX)(s.HY,{children:[(0,s.tZ)(y.xu,{display:["block","none"],position:"fixed",right:"16px",bottom:"24px",zIndex:100,color:"global.white",whiteSpace:"nowrap","data-test-id":"cookbook-save-recipe-cta-wrapper",children:o}),(0,s.tZ)(y.xu,{display:["none","block"],flexShrink:"0",whiteSpace:"nowrap",children:o})]})},e3=r(268481),e8=function(e){var t=e.imageSrc,r=e.label,o=e.onClick,n=e.isDisabled,i=void 0!==n&&n,a=e.testId;return(0,s.BX)(y.xu,{as:"button",type:"button",display:"flex",alignItems:"center",gap:"global.sm-2",width:"100%",p:"global.sm-2",minHeight:"72px",backgroundColor:"alias.elevation.level-1",borderRadius:"border-radius-lg",borderStyle:"none",cursor:i?"default":"pointer",opacity:i?"0.5":"1",textAlign:"left",disabled:i,onClick:o,"data-test-id":a,children:[(0,s.tZ)("img",{src:t,width:40,height:40,alt:"","aria-hidden":"true",style:{flexShrink:0}
1,"data-test-id":"cookbook-add-recipe-dialog-action-card-image"}),(0,s.tZ)(y.xv,{type:"body-md-bold",color:"neutral.800",children:r})]})},e5="cookbook-add-recipe-dialog-upload-image-button",e6={componentName:e5,componentLabel:"Upload image"},e7=function(e){var t=e.onImageImport,r=e.isDisabled,o=(0,F.ZP)("cookbook").translateRaw,n=(0,p.useRef)(null),i=eG().trackUploadPhotoClick,a=o("cookbook.import.add_recipe_dialog.upload_image.card_title",{defaultValue:"Save from image"}),l=o("cookbook.import.input.upload_photo_aria_label")||"Upload a photo of a recipe";return(0,s.BX)(s.HY,{children:[(0,s.tZ)(e8,{imageSrc:"https://www.hellofresh.com/assets/hellofresh/cookbook/import/import-photo-icon.webp",label:a,onClick:function(){var e;i(e6),null===(e=n.current)||void 0===e||e.click()},isDisabled:r,testId:e5}),(0,s.tZ)("input",{ref:n,type:"file",accept:eQ,onChange:function(e){var r,o=null===(r=e.target.files)||void 0===r?void 0:r[0];o&&t(o),n.current&&(n.current.value="")},"aria-label":"".concat(l," (JPEG, PNG, WebP, or HEIC)"),style:{display:"none"}
1,"data-test-id":"cookbook-add-recipe-dialog-upload-image-file-input"})]})},e9=r(723740),te="40px",tt=function(e){var t=e.title,r=e.subtitle,o=e.onBack,n=e.backAriaLabel,i=e.backTestId,a=e.titleTestId;return(0,s.BX)(y.xu,{display:"flex",alignItems:"flex-start",gap:"global.sm-1",width:"100%",children:[(0,s.tZ)(y.xu,{as:"button",type:"button",display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,width:te,height:te,borderRadius:"border-radius-lg",backgroundColor:"alias.brand.background.lighter",borderStyle:"none",cursor:"pointer","aria-label":n,onClick:o,"data-test-id":i,children:(0,s.tZ)(y.JO,{icon:(0,s.tZ)(e9.default,{}),color:"alias.brand.foreground.default"})}),(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",flex:"1",children:[(0,s.tZ)(y.xv,{as:"h2",type:"body-xl-bold","data-test-id":a,children:t}),r&&(0,s.tZ)(y.xv,{as:"p",type:"body-md-regular",color:"neutral.500",children:r})]})]})};function tr(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function to(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}var tn=function(e){var t,r,o,n=e.onTextImport,i=e.onBack,a=e.isDisabled,l=(0,F.ZP)("cookbook").translateRaw,c=function(e){if(Array.isArray(e))return e}(t=(0,p.useState)(""))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(t,2)||function(e,t){if(e){if("string"==typeof e)return tr(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return tr(e,2)}}(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),u=c[0],d=c[1],f=(0,p.useRef)(null);(0,p.useEffect)(function(){var e;null===(e=f.current)||void 0===e||e.focus()},[]);var b=l("cookbook.import.add_recipe_dialog.paste_text.title",{defaultValue:"Paste recipe text"}),m=l("cookbook.import.add_recipe_dialog.paste_text.subtitle",{defaultValue:"Drop in a full recipe and we'll tidy it."}),h=l("cookbook.import.add_recipe_dialog.paste_text.placeholder",{defaultValue:"Paste the recipe text here…"}),g=l("cookbook.import.input.paste_button",{defaultValue:"Paste"}),v=l("cookbook.import.add_recipe_dialog.paste_text.save",{defaultValue:"Save recipe"}),k=l("cookbook.import.add_recipe_dialog.paste_text.back",{defaultValue:"Back"}),w=u.trim().length,O=w>0&&w<100,x=0===w||O,S=(r=function(){var e,t;return function(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}(this,function(r){switch(r.label){case 0:return r.trys.push([0,2,,3]),[4,null===(e=navigator.clipboard)||void 0===e?void 0:e.readText()];case 1:return(t=r.sent())&&d(t),[3,3];case 2:return r.sent(),[3,3];case 3:return[2]}})},o=function(){var e=this,t=arguments;return new Promise(function(o,n){var i=r.apply(e,t);function a(e){to(i,o,n,a,l,"next",e)}function l(e){to(i,o,n,a,l,"throw",e)}a(void 0)})},function(){return o.apply(this,arguments)});return(0,s.BX)(y.xu,{as:"form",display:"flex",flexDirection:"column",width:"100%",gap:"global.sm-1",onSubmit:function(e){e.preventDefault(),x||(n(u.trim()),d(""))},children:[(0,s.tZ)(tt,{title:b,subtitle:m,onBack:i,backAriaLabel:k,backTestId:"cookbook-add-recipe
1-dialog-paste-text-back",titleTestId:"cookbook-add-recipe-dialog-paste-text-title"}),(0,s.BX)(y.xu,{position:"relative",width:"100%",pt:"global.sm-2",pb:"global.sm-1",px:"global.xxs",__dangerouslySetCustomCSS:{textarea:{paddingBottom:"48px"}},children:[(0,s.tZ)(y.Kx,{ref:f,value:u,onChange:function(e){return d(e.target.value)},placeholder:h,rows:7,error:O,disabled:a,"data-test-id":"cookbook-add-recipe-dialog-paste-text-input"}),(0,s.tZ)(y.xu,{position:"absolute",right:"global.sm-2",bottom:"global.sm-2","data-test-id":"cookbook-add-recipe-dialog-paste-text-paste",children:(0,s.BX)(y.xu,{as:"button",type:"button",display:"flex",alignItems:"center",gap:"global.xxs",bg:"transparent",borderWidth:"0",cursor:a?"default":"pointer",opacity:a?"0.5":"1",color:"alias.brand.foreground.default",disabled:a,onClick:S,children:[(0,s.tZ)(y.JO,{icon:(0,s.tZ)(eX.default,{}),color:"alias.brand.foreground.default"}),(0,s.tZ)(y.xv,{type:"body-sm-bold",color:"inherit",children:g})]})})]}),O&&(0,s.BX)(y.xv,{type:"body-sm-regular",color:"error.600","aria-live":"polite",children:[w,"/",100," min. characters"]}),(0,s.tZ)(y.zx.Primary,{type:"submit",width:"100%",disabled:x||a,"data-test-id":"cookbook-add-recipe
1-dialog-paste-text-submit",children:v})]})},ti="cookbook-add-recipe-dialog-paste-text-button",ta={componentName:ti,componentLabel:"Paste recipe text"},tl=function(e){var t=e.onExpand,r=e.isDisabled,o=(0,F.ZP)("cookbook").translateRaw,n=eG().trackTextImportClick,i=o("cookbook.import.add_recipe_dialog.paste_text.title",{defaultValue:"Paste recipe text"});return(0,s.tZ)(e8,{imageSrc:"https://www.hellofresh.com/assets/hellofresh/cookbook/import/import-text-icon.webp",label:i,onClick:function(){n(ta),t()},isDisabled:r,testId:ti})};function tc(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}var tu={SCREEN:"cookbook-add-recipe-dialog",TITLE:"cookbook-add-recipe-dialog-title",SUBTITLE:"cookbook-add-recipe-dialog-subtitle",BODY:"cookbook-add-recipe-dialog-body",DIVIDER:"cookbook-add-recipe-dialog-divider"},ts=function(e){var t,r=e.isOpen,o=e.onClose,n=e.onImport,i=e.onImageImport,a=e.onTextImport,l=e.isLoading,c=e.isDisabled,u=e.error,d=e.urlInputRef,f=(0,F.ZP)("cookbook").translateRaw,b=(0,e3.Sj)(),m=(0,p.useRef)(null),h=function(e){if(Array.isArray(e))return e}(t=(0,p.useState)(!1))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(t,2)||function(e,t){if(e){if("string"==typeof e)return tc(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return tc(e,2)}}(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),g=h[0],v=h[1];(0,p.useEffect)(function(){r||v(!1)},[r]);var k=f("cookbook.import.add_recipe_dialog.title",{defaultValue:"Add a recipe"}),w=f("cookbook.import.add_recipe_dialog.subtitle",{defaultValue:"Paste a link from any recipe site."}),O=f("cookbook.import.add_recipe_dialog.field_label",{defaultValue:"Paste recipe URL"}),x=f("cookbook.import.add_recipe_dialog.divider",{defaultValue:"or"}),S=(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",alignItems:"flex-start",width:"100%",gap:"global.xs","data-test-id":tu.BODY,children:[(0,s.tZ)(y.xv,{as:"h2",type:"body-xl-bold","data-test-id":tu.TITLE,children:k}),(0,s.tZ)(y.xv,{as:"p",type:"body-md-regular",color:"neutral.500","data-test-id":tu.SUBTITLE,children:w}),(0,s.BX)(y.xu,{width:"100%",mt:"global.xs",children:[(0,s.tZ)(y.xv,{as:"p",type:"body-sm-bold",mb:"global.xxs",children:O}),(0,s.tZ)(e1,{ref:d,onImport:n,isLoading:l,isDisabled:c,error:u})]}),(0,s.BX)(y.xu,{display:"flex",alignItems:"center",gap:"global.sm-1",width:"100%",my:"global.xs","data-test-id":tu.DIVIDER,children:[(0,s.tZ)(y.xu,{flex:"1",height:"1px",bg:"neutral.300"}),(0,s.tZ)(y.xv,{type:"body-sm-regular",color:"neutral.500",children:x}),(0,s.tZ)(y.xu,{flex:"1",height:"1px",bg:"neutral.300"})]}),(0,s.tZ)(e7,{onImageImport:i,isDisabled:c||l}),(0,s.tZ)(y.xu,{mt:"global.sm-1",width:"100%",children:(0,s.tZ)(tl,{onExpand:function(){return v(!0)},isDisabled:c||l})})]}),C=(0,s.tZ)(tn,{onTextImport:a,onBack:function(){return v(!1)},isDisabled:c||l}),j=g?C:S;return"mobile"===b?(0,s.tZ)(y.dy.Container,{isModal:!0,isOpen:r,placement:"bottom",width:"100%",backgroundColor:"global.white",returnFocusRef:m,onClose:o,onDismiss:o,isTouchMoveEnabled:!0,positionAbsoluteCloseButton:!0,"aria-label":k,"data-test-id":tu.SCREEN,children:j}):(0,s.tZ)(y.Vq,{isOpen:r,onClose:o,onDismiss:o,headless:!0,hasCloseButton:!0,width:["100%","100%","480px"],customBackgroundColor:"global.white",dialogCustomOverflow:"auto",dialogBodyMinHeight:["100%","100%","auto"],padding:["global.md-1","global.md-1","global.md-2"],"aria-label":k,"data-test-id":tu.SCREEN,children:j})},tp=r(132021),td=r(763724),tf=function(){return(0,s.tZ)(tp.Z,{customFilter:function(e){var t;return!!(null===(t=e.meta)||void 0===t?void 0:t.isCookbookImportNotification)},children:(0,s.tZ)(td.Z,{})})},tb=r(90295),tm=r(877520),th="cookbook-import-error-notification",ty=function(){return(0,tb.iX)(function(e){return e.id===th})},tg=function(e,t){(0,p.useEffect)(function(){if(!t||!e){ty();return}(0,tb.wN)(tm.ZP.create(e.message,th,{type:tm.k$.error,overrideId:th,meta:{isCookbookImportNotification:!0}
1}))},[e,t]),(0,p.useEffect)(function(){return ty},[])},tv=function(){var e=(0,F.ZP)("cookbook").translateRaw;return(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",py:"global.xl-2",px:"global.md-2",textAlign:"center","data-test-id":"cookbook-import-empty-state",children:[(0,s.tZ)(y.xu,{mb:"global.sm-2",children:(0,s.tZ)("span",{"aria-hidden":"true",style:{fontSize:"64px"},children:"\uD83C\uDF73"})}),(0,s.tZ)(y.xv,{as:"h2",type:"body-lg-bold",mb:"global.xxs",children:e("cookbook.import.empty_state.title")||"Save recipes from anywhere"}),(0,s.tZ)(y.xu,{maxWidth:"420px",children:(0,s.tZ)(y.xv,{type:"body-md-regular",color:"neutral.500",children:e("cookbook.import.empty_state.body")||"Paste a link to any recipe you find online — from food blogs, YouTube, Instagram, TikTok, and more."})})]})},tk=r(829676),tw=r(219773),tO=function(e){var t=(0,el.L3)().trackJanusEvent,r=(0,p.useRef)(!1),o=(0,p.useCallback)(function(e,t){try{t()}catch(t){(0,eH.Tb)(t,{tags:{event:e,component:"useEducationBannerTracking"}})}},[]);return(0,p.useEffect)(function(){r.current||(r.current=!0,o("Cookbook_Card_RecipeImportTutorial_Impression",function(){return t(tk.Q.janusEvent({uiComponent:tk.Q.uiComponent({uiComponentName:"EducationHeroBanner",uiComponentLabel:e})}))}))},[o,t,e]),{trackCtaClick:(0,p.useCallback)(function(){o("Cookbook_Start_Import_Button_Click",function(){return t(tw.Eq.janusEvent({uiComponent:tw.Eq.uiComponent({uiComponentName:"StartImportButton",uiComponentLabel:e,uiComponentPosition:null}),uiModal:tw.Eq.uiModal({uiModalName:tw.E5.RecipeImportTutorial})}))})},[o,t,e])}},tx=r(420336),tS=r(127408),tC=r(23287),tj=r(35959);function tP(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}function t_(){var e=tP(["\n  background: var(--color-brand-foreground-default, #067a46);\n  border-radius: 24px;\n"]);return t_=function(){return e},e}function tZ(){var e=tP(["\n  color: var(--color-accent-default, #bbf06a);\n"]);return tZ=function(){return e},e}function tI(){var e=tP(["\n  background: var(--color-brand-background-lighter, #e4fabf);\n  border: 1px solid rgba(0, 0, 0, 0.06);\n  box-shadow: 0px 2px 6px rgba(2, 40, 20, 0.1);\n  border-radius: 14px;\n"]);return tI=function(){return e},e}function tE(){var e=tP(["\n  width: 40px;\n  height: 40px;\n  border-radius: 11px;\n  display: flex;\n  align-items: center;\n  justify-content: center;\n  background: ",";\n"]);return tE=function(){return e},e}function tR(){var e=tP(["\n  background: #ffffff;\n  color: #242424;\n  border-radius: 8px;\n  width: 100%;\n\n  @media (min-width: 768px) {\n    width: auto;\n    min-width: 88px;\n  }\n\n  &:hover {\n    background: #f5f5f5;\n  }\n"]);return tR=function(){return e},e}function tA(){var e=tP(["\n  color: #e4fabf;\n  letter-spacing: 0.08em;\n  text-transform: uppercase;\n"]);return tA=function(){return e},e}function tT(){var e=tP(["\n  color: #656565;\n  letter-spacing: 0.08em;\n"]);return tT=function(){return e},e}function tD(){var e=tP(["\n  opacity: 0.55;\n"]);return tD=function(){return e},e}var tL=(0,eU.ZP)(y.xu).withConfig({componentId:"sc-3c1b48ba-0"})(t_()),tB=eU.ZP.span.withConfig({componentId:"sc-3c1b48ba-1"})(tZ()),tM=(0,eU.ZP)(y.xu).withConfig({componentId:"sc-3c1b48ba-2"})(tI()),tV=(0,eU.ZP)(y.xu).withConfig({componentId:"sc-3c1b48ba-3"})(tE(),function(e){return"done"===e.$variant?"var(--color-brand-foreground-default, #067a46)":"#faf8f3"}),tU=(0,eU.ZP)(y.zx.Primary).withConfig({componentId:"sc-3c1b48ba-4"})(tR()),tN=(0,eU.ZP)(y.xv).withConfig({componentId:"sc-3c1b48ba-5"})(tA()),tz=(0,eU.ZP)(y.xv).withConfig({componentId:"sc-3c1b48ba-6"})(tT()),tX=(0,eU.ZP)(y.xu).withConfig({componentId:"sc-3c1b48ba-7"})(tD()),tF=[{labelKey:"step_1_label",titleKey:"step_1_title",icon:tx.default,variant:"default"},{labelKey:"step_2_label",titleKey:"step_2_title",icon:tS.default,variant:"default"},{labelKey:"step_3_label",titleKey:"step_3_title",icon:tC.default,variant:"done"}],tH=function(e){var t=e.onCtaClick,r=(0,F.ZP)("cookbook").translateRaw,o=r("cookbook.import.education.hero.eyebrow"),n=r("cookbook.import.education.hero.headline"),i=r("cookbook.import.education.hero.body"),a=r("cookbook.import.education.hero.cta"),l=tO(a).trackCtaClick;
1return(0,s.tZ)("section",{"aria-label":o,"data-test-id":"cookbook-education-hero-banner",children:(0,s.BX)(tL,{display:"flex",flexDirection:["column","row"],alignItems:["stretch","center"],p:["global.md-2","global.lg-1"],gap:["global.md-2","global.md-2"],children:[(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",alignItems:"flex-start",gap:"global.sm-1",flex:"1",children:[(0,s.tZ)(tN,{type:"body-xs-bold",children:o}),(0,s.tZ)(y.xv,{type:"display-lg",strong:!0,color:"global.white",children:n.split(/(<em>.*?<\/em>)/).map(function(e,t){var r=e.match(/^<em>(.*)<\/em>$/);return r?(0,s.tZ)(tB,{children:r[1]},t):e})}),(0,s.tZ)(y.xv,{type:"body-md-regular",color:"global.white",children:i}),(0,s.tZ)(y.xu,{mt:"global.sm-2",alignSelf:["stretch","flex-start"],children:(0,s.tZ)(tU,{onClick:function(){l(),t()},children:a})})]}),(0,s.tZ)(y.xu,{display:"flex",flexDirection:"column",alignItems:["stretch","center"],gap:"global.xxs-2","aria-hidden":"true",children:tF.map(function(e,t){return(0,s.BX)(p.Fragment,{children:[t>0&&(0,s.tZ)(y.xu,{display:"flex",justifyContent:"center",py:"global.none",children:(0,s.tZ)(tX,{children:(0,s.tZ)(y.JO,{icon:(0,s.tZ)(tj.default,{}),color:"global.white"})})}),(0,s.BX)(tM,{display:"flex",flexDirection:"row",alignItems:"center",p:"global.sm-1",gap:"global.sm-1",width:["100%","320px"],children:[(0,s.tZ)(tV,{$variant:e.variant,children:(0,s.tZ)(y.JO,{icon:(0,s.tZ)(e.icon,{}),color:"done"===e.variant?"global.white":"alias.brand.foreground.default"})}),(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",gap:"global.none",children:[(0,s.tZ)(tz,{type:"body-xs-bold",children:r("cookbook.import.education.hero.".concat(e.labelKey))}),(0,s.tZ)(y.xv,{type:"body-md-bold",color:"neutral.800",children:r("cookbook.import.education.hero.".concat(e.titleKey))})]})]})]},e.labelKey)})})]})})},tq=r(953518),tY=r(285087);function tW(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}var tK="hf_cookbook_trust_strip_dismissed_v1",tG=function(){var e,t=(0,F.ZP)("cookbook").translateRaw,r=(0,tY.l)(),o=function(e){if(Array.isArray(e))return e}(e=(0,p.useState)(function(){return"1"===r.getItem(tK)}))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,2)||function(e,t){if(e){if("string"==typeof e)return tW(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return tW(e,2)}}(e,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),n=o[0],i=o[1];if(n)return null;var a=t("cookbook.import.trust_strip.lead",{defaultValue:"What's next?"}),l=t("cookbook.import.trust_strip.body",{defaultValue:"Save another recipe from Instagram, TikTok, YouTube, or Pinterest—or browse recipes from HelloFresh creators."}),c=t("cookbook.import.trust_strip.close",{defaultValue:"Dismiss"});return(0,s.BX)(y.gb,{variant:"neutral",icon:(0,s.tZ)(tq.default,{}),onClose:function(){r.setItem(tK,"1"),i(!0)},closeLabel:c,"data-test-id":"cookbook-import-platform-trust-strip",children:[(0,s.tZ)(y.xv,{as:"span",type:"body-md-bold",children:a})," ",l]})},tJ=r(509957),t$=r(789201),tQ=r(759046),t0=r(468253),t1=r(312290),t2="AllSaved",t4="CookbookSavedRecipesCarousel",t3=function(e,t,r){try{r()}catch(r){(0,eH.Tb)(r,{tags:{event:e,component:t}})}},t8=function(){var e=(0,el.L3)().trackJanusEvent;return{trackSavedRecipeCardClick:(0,p.useCallback)(function(t){var r=t.recipeId,o=t.uiComponentName,n=t.uiComponentLabel;t3("Cookbook_View_Recipe_Card_Click","useCookbookGridTracking",function(){e(t$._D.janusEvent({cookbookCollectionStateEntities:[t$._D.cookbookCollectionState({collectionId:t2,collectionName:t$.vQ.AllSaved}
1)],cookbookRecipeState:t$._D.cookbookRecipeState({recipeId:r}),uiComponent:t$._D.uiComponent({uiComponentName:o,uiComponentLabel:n})}))})},[e]),trackDeleteRecipeIconClick:(0,p.useCallback)(function(t){var r=t.recipeId;t3("Cookbook_Delete_Recipe_Icon_Click","useCookbookGridTracking",function(){e(tQ.Cy.janusEvent({event:tQ.Cy.event({actionType:tQ.Us.Click,interactionType:tQ.s_.Delete,target:tQ.Vz.Recipe,uiElementType:tQ.NM.Icon}),cookbookCollectionState:tQ.Cy.cookbookCollectionState({collectionId:t2,collectionName:tQ.vQ.AllSaved}),cookbookRecipeState:tQ.Cy.cookbookRecipeState({recipeId:r})}))})},[e]),trackSavedCarouselImpression:(0,p.useCallback)(function(){t3("Cookbook_Carousel_CookbookCollection_Impression","useCookbookGridTracking",function(){e(t0.ej.janusEvent({event:t0.ej.event({impressionType:t0.w7.ScrolledTo}),cookbookCollectionState:t0.ej.cookbookCollectionState({collectionId:t2,collectionName:t0.vQ.AllSaved}),uiComponent:t0.ej.uiComponent({uiComponentName:t4,uiComponentLabel:null})}))})},[e]),trackRecipeCardImpression:(0,p.useCallback)(function(t){var r=t.recipeId,o=t.uiComponentLabel;t3("Cookbook_Card_Recipe_Impression","useCookbookGridTracking",function(){e(t1.Z.janusEvent({cookbookCollectionState:t1.Z.cookbookCollectionState({collectionId:t2}),cookbookRecipeState:t1.Z.cookbookRecipeState({recipeId:r}),uiComponent:t1.Z.uiComponent({uiComponentName:t4,uiComponentLabel:o})}))})},[e])}},t5=r(706009),t6=r(318066),t7="https://media.hellofresh.com/hellofresh-website/cookbook/landing-page",t9={instagram:"Instagram",tiktok:"TikTok",pinterest:"Pinterest",youtube:"YouTube",facebook:"Facebook",hellofresh:"HelloFresh"},re={instagram:"".concat(t7,"/app-instagram-bw.png"),tiktok:"".concat(t7,"/app-tiktok-bw.png"),facebook:"".concat(t7,"/app-facebook-bw.png")},rt=function(e){if(!e||""===e.trim())return null;try{return new URL(e).hostname.replace(/^www\./,"")}catch(e){return null}},rr=function(e,t,r,o){if("creator"===e&&(null==o?void 0:o.trim()))return{label:o.trim(),iconUrl:null};var n,i=e&&t9[e];if(i)return{label:i,iconUrl:null!==(n=e&&re[e])&&void 0!==n?n:null};var a=rt(t);return a?{label:a,iconUrl:null}:{label:r,iconUrl:null}},ro=r(694343),rn=r(833190),ri=function(){var e=(0,el.L3)().trackJanusEvent;return{trackStartDeletionButtonClick:(0,p.useCallback)(function(t){var r;e(ro.DS.janusEvent({recipeView:ro.DS.recipeView({authorId:null,authorName:null!==(r=t.authorName)&&void 0!==r?r:null,recipeId:t.id,recipeSourceType:(0,rn.vk)(t.sourcePlatform),recipeTags:[]})}))},[e])}},ra=new Set,rl=function(e){try{var t=new URL(e,"https://hellofresh.com");return"".concat(t.pathname).concat(t.search).concat(t.hash)}catch(e){return null}},rc=function(e){var t=e.recipe,r=e.onRemove,o=(0,F.ZP)("cookbook").translateRaw,n=t8(),i=n.trackSavedRecipeCardClick,a=n.trackDeleteRecipeIconClick,l=n.trackRecipeCardImpression,c=ri().trackStartDeletionButtonClick,u="creator"===t.sourcePlatform||"hellofresh"===t.sourcePlatform?rl(t.url):null,d=null!=u?u:"/cookbook/import/".concat(t.id),f=o("cookbook.import.card.your_recipe")||"Your recipe",b=rr(t.sourcePlatform,t.url,f,t.authorName),m=o("cookbook.import.card.link_aria_label",{title:t.title,hostname:b.label})||"".concat(t.title," from ").concat(b.label),h=o("cookbook.import.card.remove_aria_label",{title:t.title})||"Remove ".concat(t.title),g=(0,tJ.YD)({threshold:1,triggerOnce:!0}),v=g.ref,k=g.inView;return(0,p.useEffect)(function(){!k||ra.has(t.id)||(ra.add(t.id),l({recipeId:t.id,uiComponentLabel:b.label}))},[k,t.id,b.label,l]),(0,s.BX)(y.xu,{ref:v,position:"relative",height:"100%","data-test-id":"cookbook-import-recipe-card",children:[(0,s.tZ)(y.Zb.Navigation,{variant:"elevated",href:d,padding:"global.none",display:"flex",flexDirection:"column",width:"100%",height:"100%",overflow:"hidden","aria-label":m,onClick:function(){i({recipeId:t.id,uiComponentName:t4,uiComponentLabel:b.label})},children:(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",height:"100%",width:"100%",children:[(0,s.tZ)(y.xu,{position:"relative",width:"100%",height:"180px",flexShrink:0,backgroundColor:"shared-alias.neutral.background.default",children:t.thumbnailUrl?(0,s.tZ)(t6.ZP,{src:t.thumbnailUrl,alt:"",fill:!0,unoptimized:!0,style:{objectFit:"cover"}}):(0,s.tZ)(y.xu,{display:"flex",alignItems:"center",justifyContent:"center",width:"100%",height:"100%",children:(0,s.tZ)(y.xv,{as:"span",type:"display-md","aria-hidden":!0,
1children:"\uD83C\uDF7D️"})})}),(0,s.BX)(y.xu,{p:"global.sm-2",display:"flex",flexDirection:"column",flexGrow:1,gap:"global.xs",children:[(0,s.tZ)(y.xv,{as:"span",type:"body-md-bold",overflow:"hidden",textOverflow:"ellipsis",children:t.title}),(0,s.tZ)(y.xu,{marginTop:"auto",alignSelf:"flex-start",children:(0,s.tZ)(y.uj,{size:"sm",type:"subtle",leadingIcon:b.iconUrl?(0,s.tZ)(t6.ZP,{src:b.iconUrl,alt:"",width:16,height:16,unoptimized:!0}):(0,s.tZ)(t5.Z,{"aria-hidden":!0}),children:b.label})})]})]})}),(0,s.tZ)(y.xu,{position:"absolute",top:"global.sm-1",right:"global.sm-1",zIndex:"1",children:(0,s.tZ)(y.PZ,{placement:"over-assets","aria-label":h,onClick:function(e){e.preventDefault(),e.stopPropagation(),a({recipeId:t.id}),c(t),r(t.id)},"data-test-id":"cookbook-import-remove-button"})})]})};function ru(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function rs(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function rp(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var rd={background:"linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%)",backgroundSize:"200% 100%",animation:"shimmer 1.4s infinite"},rf={borderRadius:"8px",overflow:"hidden",backgroundColor:"white",boxShadow:"0 1px 4px rgba(0, 0, 0, 0.08)"},rb=[{key:"cookbook.import.loading.scanning",fallback:"Scanning the source",durationMs:3500},{key:"cookbook.import.loading.collecting",fallback:"Collecting recipe info",durationMs:2800},{key:"cookbook.import.loading.cleaning",fallback:"Cleaning up ingredients & steps",durationMs:6500},{key:"cookbook.import.loading.almost_done",fallback:"Almost done",durationMs:0}],rm=function(){var e,t=(0,F.ZP)("cookbook").translateRaw,r=function(e){if(Array.isArray(e))return e}(e=(0,p.useState)(0))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,2)||function(e,t){if(e){if("string"==typeof e)return ru(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ru(e,2)}}(e,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),o=r[0],n=r[1];(0,p.useEffect)(function(){if(("function"!=typeof window.matchMedia||!window.matchMedia("(prefers-reduced-motion: reduce)").matches)&&!(o>=rb.length-1)){var e=setTimeout(function(){n(function(e){return e+1})},rb[o].durationMs);return function(){return clearTimeout(e)}}},[o]);var i=rb[o],a=t(i.key)||i.fallback;return(0,s.BX)(s.HY,{children:[(0,s.tZ)("style",{children:"\n      @keyframes shimmer {\n        0% { background-position: 200% 0; }\n        100% { background-position: -200% 0; }\n      }\n      @keyframes cookbookDots {\n        0%, 20% { content: '.'; }\n        40% { content: '..'; }\n        60%, 100% { content: '...'; }\n      }\n      .cookbook-loading-dots::after {\n        content: '.';\n        animation: cookbookDots 1.2s steps(3, end) infinite;\n      }\n      @media (prefers-reduced-motion: reduce) {\n        @keyframes shimmer {\n          0%, 100% { background-position: 0 0; }\n        }\n        .cookbook-loading-dots::after {\n          animation: none;\n          content: '…';\n        }\n      }\n    "}
1),(0,s.BX)("div",{style:rf,"data-test-id":"cookbook-import-skeleton",role:"status","aria-live":"polite","aria-label":t("cookbook.import.skeleton_aria_label")||"Loading recipe","aria-busy":"true",children:[(0,s.tZ)("div",{style:rp(rs({},rd),{height:"180px",position:"relative",display:"flex",alignItems:"center",justifyContent:"center",padding:"0 16px",textAlign:"center"}),children:(0,s.BX)(y.xv,{type:"body-md-bold",color:"neutral.800",children:[(0,s.tZ)("span",{children:a}),(0,s.tZ)("span",{className:"cookbook-loading-dots","aria-hidden":"true"})]})}),(0,s.BX)(y.xu,{p:"global.sm-2",children:[(0,s.tZ)("div",{style:rp(rs({},rd),{height:"16px",borderRadius:"4px",marginBottom:"8px",width:"70%"})}),(0,s.tZ)("div",{style:rp(rs({},rd),{height:"12px",borderRadius:"4px",width:"40%"})})]})]})]})},rh={tiktok:"TikTok",instagram:"Instagram",website:"a website"},ry=function(e){var t=e.platform,r=e.onClick,o=(0,F.ZP)("cookbook").translateRaw,n=o("cookbook.import.empty_platform_card.headline",{platform:rh[t],defaultValue:"Save from {{platform}}"}),i=o("cookbook.import.empty_platform_card.subcopy",{defaultValue:"Paste a link to add it"});return(0,s.tZ)(y.Zb.Navigation,{href:"#",variant:"filled",scroll:!1,onClick:function(e){e.preventDefault(),r()},backgroundColor:"alias.elevation.level-1",width:"100%",height:"100%",padding:"global.md-2","aria-label":n,"data-test-id":"cookbook-import-empty-platform-card-".concat(t),children:(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",textAlign:"center",width:"100%",minHeight:"240px",gap:"global.sm-1",children:[(0,s.tZ)(eM.default,{"aria-hidden":!0}),(0,s.tZ)(y.xv,{type:"body-md-bold",children:n}),(0,s.tZ)(y.xv,{type:"body-sm-regular",color:"neutral.500",children:i})]})})},rg=["instagram","tiktok","website"],rv=function(e){var t=e.recipes,r=e.isCustomer,o=e.showSkeleton,n=e.recipeLimit,i=e.hasMore,a=e.isLoadingMore,l=e.onLoadMore,c=e.onRemove,u=e.onEmptySlotClick,d=e.nextBestAction,f=(0,F.ZP)("cookbook").translateRaw,b=t8().trackSavedCarouselImpression,m=(0,tJ.YD)({threshold:.3,triggerOnce:!0}),h=m.ref,g=m.inView,v=(0,p.useRef)(!1);(0,p.useEffect)(function(){g&&!v.current&&(v.current=!0,b())},[g,b]);var k=(0,p.useCallback)(function(e){e.preventDefault(),null==l||l()},[l]),w=Math.max(0,n-(t.length+(o?1:0))),O=rg.filter(function(e){return!("website"!==e&&t.some(function(t){return t.sourcePlatform===e}))}).slice(0,w);return(0,s.BX)(y.xu,{ref:h,children:[(0,s.BX)(y.xu,{mb:"global.sm-2",display:"flex",alignItems:"center",gap:"global.sm-2",children:[(0,s.BX)(y.xv,{as:"h2",type:"body-xl-bold",children:[f("cookbook.import.saved_recipes",{defaultValue:"Recently saved"}),!r&&(0,s.BX)(y.xv,{as:"span",type:"body-md-regular",color:"neutral.500",ml:"global.xxs","aria-label":f("cookbook.import.count_aria_label",{count:String(t.length),limit:String(n),defaultValue:"".concat(t.length," of ").concat(n)}),children:["(",t.length,"/",n,")"]})]}),d&&(0,s.tZ)(y.xu,{display:["none","none","block"],flexShrink:0,width:"400px",children:d})]}),(0,s.BX)(y.xu,{display:"grid",gridTemplateColumns:["1fr","repeat(2, 1fr)","repeat(3, 1fr)"],gap:["global.sm-2","global.md-1","global.md-1"],children:[o&&(0,s.tZ)(rm,{}),t.map(function(e){return(0,s.tZ)(rc,{recipe:e,onRemove:c}
1,e.id)}),O.map(function(e){return(0,s.tZ)(ry,{platform:e,onClick:u},e)})]}),void 0!==i&&i&&(0,s.tZ)(y.xu,{display:"flex",justifyContent:"center",mt:"global.sm-2",children:(0,s.tZ)(y.rU,{href:"#",onClick:k,disabled:void 0!==a&&a,children:f("cookbook.import.load_more",{defaultValue:"See more"})})})]})},rk=r(958042);function rw(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}var rO={server:4.5,desktop:4.5,tablet:3,mobile:1.3},rx=function(){var e,t,r=(0,e3.Sj)(),o=(0,p.useRef)(null),n=(function(e){if(Array.isArray(e))return e}(e=(0,p.useReducer)(function(e){return e+1},0))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,2)||function(e,t){if(e){if("string"==typeof e)return rw(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return rw(e,2)}}(e,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[1];return(0,p.useEffect)(function(){var e=o.current;if(e&&"undefined"!=typeof ResizeObserver){var t=new ResizeObserver(function(){return n()});return t.observe(e),function(){return t.disconnect()}}},[]),{containerRef:o,perPage:null!==(t=rO[r])&&void 0!==t?t:rO.desktop,isDesktop:"desktop"===r}},rS=r(304187),rC=r(122810),rj="/creators",rP=(0,r(66077).Z)("cookbook-creator-recipes",{creatorIds:[]}).useConfig,r_=function(){var e=rP().creatorIds,t=(0,rS.yA)(e),r=(0,p.useMemo)(function(){return t.flatMap(function(e){var t,r;return null!==(r=null===(t=e.data)||void 0===t?void 0:t.docs)&&void 0!==r?r:[]}).slice(0,12)},[t]),o=(0,p.useMemo)(function(){return r.map(function(e){return e.id})},[r]),n=(0,rC.t)({bookmarkIds:o}).data,i=(0,p.useMemo)(function(){var e;return new Set(null!==(e=null==n?void 0:n.bookmarkIds)&&void 0!==e?e:[])},[n]),a=(0,p.useMemo)(function(){return r.map(function(e){var t,r;return t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}({},e),r=r={isSaved:i.has(e.id)},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t})},[r,i]),l=t.length>0,c=l&&t.every(function(e){return e.isLoading}),u=l&&t.every(function(e){return e.isError})?"error":c?"loading":0===a.length?"empty":"success";return{recipes:a,status:u}};function rZ(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function rI(e,t,r,o,n,i,a){try{var l=e[i](a),c=l.value}catch(e){r(e);return}l.done?t(c):Promise.resolve(c).then(o,n)}function rE(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return rZ(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);
1if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return rZ(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var rR="AllSaved",rA=function(){var e=rE((0,p.useState)(null),2),t=e[0],r=e[1],o=rE((0,p.useState)(!1),2),n=o[0],i=o[1],a=(0,p.useRef)(null),l=(0,w.useQueryClient)(),c=(0,et.K)().mutate,u=ef(),s=u.trackRecipeSaveSuccess,d=u.trackRecipeSaveError,f=(0,p.useCallback)(function(e){r(function(t){return t===e?null:t}),a.current===e&&(a.current=null)},[]);return{save:(0,p.useCallback)(function(e){var t,o,n=e.id;a.current!==n&&(a.current=n,r(n),c({bookmarkId:n,bookmarkSource:"creator"},{onSuccess:(t=function(t){var r,o,a;return function(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(r)throw TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=(n=a.trys).length>0&&n[n.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}(this,function(c){switch(c.label){case 0:return r=t.id,o=t.freeRecipeSaveCount,a=t.freeRecipeSaveLimit,null!==o&&null!==a&&o>=a&&i(!0),s({recipeId:r,recipeImportMethod:ec.L2.Bookmarked,collectionId:rR,recipe:e,recipeSourceType:es.m4.Creator}),[4,l.refetchQueries(P.Z["externalRecipes.list"])];case 1:return c.sent(),f(n),[2]}})},o=function(){var e=this,r=arguments;return new Promise(function(o,n){var i=t.apply(e,r);function a(e){rI(i,o,n,a,l,"next",e)}function l(e){rI(i,o,n,a,l,"throw",e)}a(void 0)})},function(e){return o.apply(this,arguments)}),onError:function(e){var t=K(e);"ANONYMOUS_LIMIT_REACHED"===t&&i(!0),d({recipeId:n,recipeImportMethod:ec.L2.Bookmarked,collectionId:rR,systemMessage:t}),f(n)}}))},[c,l,f,s,d]),savingId:t,isAtLimit:n}},rT=r(115371),rD=r(401738),rL=r(572557),rB=r(117584),rM=function(e){if(!e)return null;var t=e.match(/^PT(?:(\d+)H)?(?:(\d+)M)?$/);if(!t)return null;var r=60*(t[1]?parseInt(t[1],10):0)+(t[2]?parseInt(t[2],10):0);return r>0?r:null},rV="CookbookCreatorRecipes",rU=function(e,t,r){try{r()}catch(r){(0,eH.Tb)(r,{tags:{event:e,component:t}})}},rN=function(e){var t,r,o,n,i;return null!==(i=null!==(n=null!==(o=null===(t=e.recipeDeveloper)||void 0===t?void 0:t.displayName)&&void 0!==o?o:null===(r=e.recipeDeveloper)||void 0===r?void 0:r.name)&&void 0!==n?n:e.author)&&void 0!==i?i:""},rz=function(e){var t,r,o=null===(t=e.recipeDeveloper)||void 0===t?void 0:t.id;return o?{cookingTime:null!==(r=rM(e.totalTime))&&void 0!==r?r:rM(e.prepTime),cooksCount:null,creatorId:o,creatorName:rN(e),creatorRecipeId:e.id,recipeRating:"number"==typeof e.averageRating?e.averageRating:null}:null},rX=function(){var e=(0,el.L3)().trackJanusEvent;return{trackCarouselImpression:(0,p.useCallback)(function(){rU("Cookbook_Carousel_CreatorRecipe_Impression","useCookbookCreatorCarouselTracking",function(){e(rT.$.janusEvent())})},[e]),trackSeeMoreLinkClick:(0,p.useCallback)(function(){rU("Cookbook_View_CreatorList_Link_Click","useCookbookCreatorCarouselTracking",function(){e(rD.e.janusEvent())})},[e]),trackCreatorRecipeCardClick:(0,p.useCallback)(function(t){var r=rz(t);if(!r){(0,eH.Tb)(Error("CreatorRecipe missing recipeDeveloper; skipping Cookbook_View_Recipe_Card_Click"),{tags:{event:"Cookbook_View_Recipe_Card_Click",component:"useCookbookCreatorCarouselTracking"}});return}rU("Cookbook_View_Recipe_Card_Click","useCookbookCreatorCarouselTracking",function(){e(t$._D.janusEvent({cookbookRecipeState:t$._D.cookbookRecipeState({re
1cipeId:t.id}),creatorRecipeStateEntities:[t$._D.creatorRecipeState(r)],uiComponent:t$._D.uiComponent({uiComponentName:rV,uiComponentLabel:r.creatorName||null})}))})},[e]),trackSaveRecipeIconClick:(0,p.useCallback)(function(t){var r=rz(t);rU("Cookbook_Save_Recipe_Icon_Click","useCookbookCreatorCarouselTracking",function(){e(rL.U.janusEvent({cookbookRecipeAction:rL.U.cookbookRecipeAction({recipeId:t.id}),creatorRecipeStateEntities:r?[rL.U.creatorRecipeState(r)]:[]}))})},[e]),trackCarouselNavChange:(0,p.useCallback)(function(){rU("Cookbook_Change_Recipe_Icon_Click","useCookbookCreatorCarouselTracking",function(){e(rB.w.janusEvent({uiComponent:rB.w.uiComponent({uiComponentName:rV,uiComponentLabel:null})}))})},[e])}},rF=r(848699),rH=function(e){var t=e.headshotPath,r=e.label;return(0,s.BX)(y.xu,{display:"inline-flex",alignItems:"center",gap:"global.xxs",backgroundColor:"shared-alias.neutral.background.lightest",borderRadius:"global.lg",paddingY:"global.xxs",paddingX:"global.xs",maxWidth:"100%","data-test-id":"creator-source-tag",children:[!!t&&(0,s.tZ)(y.xu,{width:"".concat(20,"px"),height:"".concat(20,"px"),borderRadius:"global.circle",overflow:"hidden",flexShrink:0,position:"relative",children:(0,s.tZ)(t6.ZP,{src:t,alt:"",width:20,height:20,crop:"thumb",gravity:"face",style:{objectFit:"cover"}})}),(0,s.tZ)(y.xv,{as:"span",type:"body-xs-bold",color:"shared-alias.neutral.foreground.default",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap","aria-label":r,children:r})]})},rq=r(428637),rY=function(e){var t,r,o,n,i;return null!==(i=null!==(n=null!==(o=null===(t=e.recipeDeveloper)||void 0===t?void 0:t.displayName)&&void 0!==o?o:null===(r=e.recipeDeveloper)||void 0===r?void 0:r.name)&&void 0!==n?n:e.author)&&void 0!==i?i:""},rW=function(e){var t,r,o,n=[],i=null!==(o=rM(e.totalTime))&&void 0!==o?o:rM(e.prepTime);i&&n.push("".concat(i," min"));var a=null===(t=e.nutrition)||void 0===t?void 0:t.find(function(e){return"Calories"===e.name||"Energy (kcal)"===e.name});a&&n.push("".concat(Math.round(a.amount)," kcal"));var l=null===(r=e.nutrition)||void 0===r?void 0:r.find(function(e){return"Protein"===e.name});return l&&n.push("".concat(Math.round(l.amount),"g prot.")),n.join(" \xb7 ")},rK=p.memo(function(e){var t=e.imagePath,r=e.alt;return t?t.startsWith("http")?(0,s.tZ)(t6.ZP,{src:t,alt:r,fill:!0,unoptimized:!0,style:{objectFit:"cover"}}):(0,s.tZ)(t6.ZP,{src:"/recipes".concat(t),alt:r,fill:!0,sizes:"(max-width: 640px) 80vw, (max-width: 1024px) 40vw, 280px",style:{objectFit:"cover"}}):(0,s.tZ)(t6.ZP,{src:"/hellofresh_website/empty-dish-thumbnail.png",alt:r,fill:!0,sizes:"(max-width: 640px) 80vw, (max-width: 1024px) 40vw, 280px",style:{objectFit:"cover"}})});rK.displayName="CreatorRecipeImage";var rG=p.memo(function(e){var t,r,o,n,i,a,l=e.recipe,c=e.isSaved,u=e.isSaving,p=e.onSave,d=e.onCardClick,f=(0,F.ZP)("cookbook").translateRaw,b=rY(l),m=rW(l),h=f("cookbook.creator_recipes.recipe_by",{name:b,defaultValue:"Recipe by: ".concat(b)}),g=c||u,v=f("cookbook.creator_recipes.save_aria_label",{title:null!==(o=l.name)&&void 0!==o?o:"",defaultValue:"Save ".concat(null!==(n=l.name)&&void 0!==n?n:"recipe"," to your cookbook")}),k=f("cookbook.creator_recipes.saved_aria_label",{title:null!==(i=l.name)&&void 0!==i?i:"",defaultValue:"".concat(null!==(a=l.name)&&void 0!==a?a:"Recipe"," saved to your cookbook")});return(0,s.BX)(y.xu,{position:"relative",width:"100%",children:[(0,s.tZ)(y.Zb.Navigation,{variant:"filled",href:l.websiteUrl||rj,padding:"global.none",display:"block",width:"100%","data-test-id":"creator-recipe-card",onClick:d,children:(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",width:"100%",children:[(0,s.BX)(y.xu,{position:"relative",width:"100%",overflow:"hidden",borderRadius:"global.md",aspectRatio:"4 / 3",children:[(0,s.tZ)(rK,{imagePath:l.imagePath,alt:l.name||""}),b&&(0,s.tZ)(y.xu,{position:"absolute",bottom:"global.xs",left:"global.xs",children:(0,s.tZ)(rH,{headshotPath:null===(r=l.recipeDeveloper)||void 0===r?void 0:null===(t=r.headshotImage)||void 0===t?void 0:t.path,label:h})})]}),(0,s.BX)(y.xu,{marginTop:"global.sm-2",children:[(0,s.tZ)(y.xv,{as:"h4",type:"body-lg-bold",children:l.name}),m&&(0,s.tZ)(y.xv,{as:"p",type:"body-sm-regular",color:"shared-alias.neutral.foreground.dark",marginTop:"global.xxs",children:m})]})]})}),(0,s.tZ)(y.xu,{position:"absolute",top:"global.xs",right:"global.xs",zIndex:"1",children:(0,s.tZ)(y.hU.Primary,{shape:"circle",icon:g?(0,s.tZ)(rq.Z,{}):(0,s.tZ)(rF.default,{}),"aria-label":g?k:v,"aria-pressed":g,disabled:g,onClick:function(){g||p(l.id)}
1,"data-test-id":"creator-recipe-save-button",appearance:"brand"})})]})}),rJ={backgroundImage:"linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%)",backgroundSize:"200% 100%",animation:"creatorRecipeShimmer 1.4s infinite","@keyframes creatorRecipeShimmer":{"0%":{backgroundPosition:"200% 0"},"100%":{backgroundPosition:"-200% 0"}},"@media (prefers-reduced-motion: reduce)":{animation:"none"}},r$=function(e){return(0,s.tZ)(y.xu,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}({__dangerouslySetCustomCSS:rJ},e))},rQ=function(){return(0,s.BX)(y.xu,{width:"100%","data-test-id":"creator-recipe-card-skeleton","aria-hidden":!0,children:[(0,s.tZ)(r$,{width:"100%",overflow:"hidden",borderRadius:"global.md",aspectRatio:"4 / 3"}),(0,s.BX)(y.xu,{marginTop:"global.sm-2",children:[(0,s.tZ)(r$,{height:"16px",width:"80%",borderRadius:"global.sm",marginBottom:"global.xxs"}),(0,s.tZ)(r$,{height:"12px",width:"50%",borderRadius:"global.sm"})]})]})},r0=r(795016),r1=function(e){var t=e.title,r=e.socialProof,o=e.onSeeMoreClick,n=(0,F.ZP)("cookbook").translateRaw;return(0,s.BX)(y.xu,{display:"flex",justifyContent:"space-between",alignItems:"flex-start",gap:"global.sm-2",marginBottom:"global.sm-2",children:[(0,s.BX)(y.xu,{children:[(0,s.tZ)(y.xv,{as:"h2",type:"body-xl-bold",children:t}),(0,s.tZ)(y.xv,{type:"body-md-regular",color:"neutral.500",marginTop:"global.xxs",children:r})]}),(0,s.tZ)(y.xu,{flexShrink:0,children:(0,s.tZ)(y.rU,{href:rj,strong:!0,trailingIcon:(0,s.tZ)(r0.Z,{}),"aria-label":n("cookbook.creator_recipes.see_more_aria_label",{defaultValue:"See more recipes from this creator"}),"data-test-id":"creator-recipes-see-more",onClick:o,children:n("cookbook.creator_recipes.see_more",{defaultValue:"See more"})})})]})},r2=function(e){var t=e.isCustomer,r=e.onAtLimit,o=(0,F.ZP)("cookbook").translateRaw,n=r_(),i=n.recipes,a=n.status,l=rA(),c=l.save,u=l.savingId,d=l.isAtLimit,f=rx(),b=f.containerRef,m=f.perPage,h=(0,rk.Z)(),g=rX(),v=g.trackCarouselImpression,k=g.trackSeeMoreLinkClick,w=g.trackCreatorRecipeCardClick,O=g.trackSaveRecipeIconClick,x=g.trackCarouselNavChange,S=(0,p.useRef)(!1),C=(0,p.useCallback)(function(){if(!S.current){S.current=!0;return}x()},[x]),j=(0,tJ.YD)({threshold:.3,triggerOnce:!0}),P=j.ref,_=j.inView,Z=(0,p.useRef)(!1);(0,p.useEffect)(function(){_&&!Z.current&&"success"===a&&(Z.current=!0,v())},[_,a,v]);var I=(0,p.useCallback)(function(e){if(!t&&d){r();return}c(e)},[t,d,r,c]),E=(0,p.useCallback)(function(e){return function(){O(e),I(e)}},[I,O]),R=(0,p.useCallback)(function(e){return function(){return w(e)}},[w]),A=(0,p.useRef)(!1);if((0,p.useEffect)(function(){t||(!A.current&&d&&r(),A.current=d)},[d,t,r]),"empty"===a||"error"===a)return null;var T=new Intl.NumberFormat(h||void 0).format(12400),D=o("cookbook.creator_recipes.title",{defaultValue:"From HelloFresh creators"}),L=o("cookbook.creator_recipes.social_proof",{count:T,defaultValue:"Saved by ".concat(T," members this week.")}),B="loading"===a;return(0,s.BX)(y.xu,{ref:function(e){b&&"current"in b&&(b.current=e),P(e)},as:"section",maxWidth:["100%","100%","1144px"],mx:"auto",px:["global.sm-2","global.md-1","global.none"],py:["global.md-2","global.lg-1"],"data-test-id":"creator-recipes-section",children:[(0,s.tZ)(r1,{title:D,socialProof:L,onSeeMoreClick:k}),B?(0,s.tZ)(y.xu,{display:"grid",gridTemplateColumns:["repeat(2, 1fr)","repeat(3, 1fr)","repeat(4, 1fr)"],gap:["global.sm-2","global.md-1"],children:Array.from({length:4}).map(function(e,t){return(0,s.tZ)(rQ,{},t)})}):(0,s.tZ)(y.lr,{id:"cookbook-creator-recipes",perPage:m,snapAlign:"start",autosnap:!0,partialSlideView:m<3,showArrowNavigation:!0,hideNavigationWhenSinglePage:!0,paddingX:"global.none",onPageChange:C,children:i.slice(0,12).map(function(e){return(0,s.tZ)(y.xu,{paddingRight:["global.sm-2","global.md-1"],height:"100%",children:(0,s.tZ)(rG,{recipe:e,isSaved:e.isSaved,isSaving:u===e.id,onSave:E(e),onCardClick:R(e)})},e.id)})})]})};function r4(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}var r3={server:4.5,desktop:4.5,tablet:3,mobile:2.1},r8=function(){var e,t,r=(0,e3.Sj)(),o=(0,p.useRef)(null),n=(function(e){if(Array.isArray(e))return e}(e=(0,p.useReducer)(function(e){return e+1},0))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,2)||function(e,t){if(e){if("string"==typeof e)return r4(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);
1if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return r4(e,2)}}(e,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[1];return(0,p.useEffect)(function(){var e=o.current;if(e&&"undefined"!=typeof ResizeObserver){var t=new ResizeObserver(function(){return n()});return t.observe(e),function(){return t.disconnect()}}},[]),{containerRef:o,perPage:null!==(t=r3[r])&&void 0!==t?t:r3.desktop,isDesktop:"desktop"===r}},r5=r(809805),r6=function(){var e,t=(0,r5.Ae)("cookbook-metadata");return t.isReady&&t.value&&null!==(e=t.value.userCount)&&void 0!==e?e:"813k"},r7=r(439154),r9=r(337320),oe=r(233798),ot=function(){var e=(0,el.L3)().trackJanusEvent;return{trackCarouselImpression:(0,p.useCallback)(function(t){t.forEach(function(t){e(r9.Z.janusEvent({communityRecipeStateEntities:[r9.Z.communityRecipeState({recipeId:t.id})],cookbookRecipeState:r9.Z.cookbookRecipeState({recipeId:t.id}),uiComponent:r9.Z.uiComponent({uiComponentName:eD,uiComponentLabel:null})}))})},[e]),trackCommunityRecipeCardClick:(0,p.useCallback)(function(t){var r;e(r7._D.janusEvent({communityRecipeStateEntities:[r7._D.communityRecipeState({recipeId:t.id})],cookbookRecipeState:r7._D.cookbookRecipeState({recipeId:t.id}),uiComponent:r7._D.uiComponent({uiComponentName:eD,uiComponentLabel:null!==(r=t.author)&&void 0!==r?r:null})}))},[e]),trackCtaSaveRecipeClick:(0,p.useCallback)(function(){e(eY.Eq.janusEvent({uiComponent:eY.Eq.uiComponent({uiComponentName:"Recipe",uiComponentLabel:eD,uiComponentPosition:null}),uiModal:eY.Eq.uiModal({uiModalName:eY.E5.RecipeImportTutorial})}))},[e]),trackCtaLearnHowClick:(0,p.useCallback)(function(){e(oe.v0.janusEvent({uiComponent:oe.v0.uiComponent({uiComponentName:"LearnHowLink",uiComponentLabel:eD,uiComponentPosition:null}),uiModal:oe.v0.uiModal({uiModalName:oe.E5.RecipeImportTutorial})}))},[e])}},or={backgroundImage:"linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%)",backgroundSize:"200% 100%",animation:"communityRecipeShimmer 1.4s infinite","@keyframes communityRecipeShimmer":{"0%":{backgroundPosition:"200% 0"},"100%":{backgroundPosition:"-200% 0"}},"@media (prefers-reduced-motion: reduce)":{animation:"none"}},oo=function(){return(0,s.tZ)(y.xu,{width:"100%","data-test-id":"community-recipe-card-skeleton","aria-hidden":!0,children:(0,s.tZ)(y.xu,{width:"100%",overflow:"hidden",borderRadius:"global.md",aspectRatio:"3 / 4",__dangerouslySetCustomCSS:or})})};function on(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}var oi=function(e){var t,r=e.onSaveRecipePress,o=e.onLearnHowPress,n=(0,F.ZP)("cookbook").translateRaw,i=function(e){if(Array.isArray(e))return e}(t=(0,p.useState)(!1))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(t,2)||function(e,t){if(e){if("string"==typeof e)return on(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return on(e,2)}}(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),a=i[0],l=i[1],c=n("cookbook.empty_state.community_carousel.cta.title",{defaultValue:"Save recipes from anywhere"}),u=n("cookbook.empty_state.community_carousel.cta.save_button.label",{defaultValue:"Save a recipe"}),d=n("cookbook.empty_state.community_carousel.cta.learn_how.label",{defaultValue:"Learn how"});return(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",width:"100%",aspectRatio:"171 / 256",backgroundColor:"alias.brand.background.default",borderRadius:"global.lg",padding:"global.sm-1",overflow:"hidden","data-test-id":eL.ctaTile,children:[!a&&(0,s.tZ)(y.xu,{flex:"1",minHeight:0,display:"flex",alignItems:"center",justifyContent:"center",width:"100%",children:(0,s.tZ)("img",{src:"https://media.hellofresh.com/hellofresh-website/cookbook/onboarding/import-tutorial/community-cta-illustration-v2.gif",alt:"",onError:function(){return l(!0)},style:{objectFit:"contain",maxWidth:"100%",maxHeight:"100%",width:"auto",height:"auto"}})}),(0,s.tZ)(y.xv,{as:"h4",type:"body-lg-bold",color:"shared-alias.neutral.foreground.inverse",mt:"global.xs",mb:"global.xs",textAlign:"center",overflow:"hidden",children:c}),(0,s.tZ)(y.xu,{mt:"global.xxs",mb:"global.xs",width:"100%",children:(0,s.tZ)(y.zx.Primary,{appearance:"neutral",size:"sm",onClick:r,"data-test-id":eL.ctaSave,"aria-label":u,children:u})}),(0,s.tZ)(y.xu,{pb:"global.xs",children:(0,s.tZ)(y.rU,{href:"#",onClick:function(e){e.preventDefault(),o()},type:"body-sm-bold",customColor:"global.white",trailingIcon:(0,s.tZ)(r0.Z,{}),textDecoration:"underline","aria-label":d,"data-test-id":eL.ctaLearnHow,children:d})})]})},oa=r(645904),ol=r(832706),oc=r(813445),ou=r(126671),os=r(924759),op=r(793438),od={instagram:oa.Z,tiktok:ol.Z,youtube:oc.Z,unsupported:ou.Z,creator:os.Z,hellofresh:op.default},of=function(e){var t=e.platform;if(!("instagram"===t||"tiktok"===t||"youtube"===t||"unsupported"===t||"creator"===t||"hellofresh"===t))return null;var r=od[t];return(0,s.tZ)(y.JO,{icon:(0,s.tZ)(r,{}),color:"global.white","aria-hidden":!0})},ob=new Set(["instagram","tiktok","youtube","facebook","pinterest"]),om=function(e){var t=e.trim();return t.startsWith("@")?t:"@".concat(t)},oh=p.memo(function(e){var t=e.imagePath,r=e.alt;return t?t.startsWith("http")?(0,s.tZ)(t6.ZP,{src:t,alt:r,fill:!0,unoptimized:!0,style:{objectFit:"cover"}}):(0,s.tZ)(t6.ZP,{src:"/recipes".concat(t),alt:r,fill:!0,sizes:"(max-width: 640px) 60vw, (max-width: 1024px) 30vw, 260px",style:{objectFit:"cover"}}
1):(0,s.tZ)(t6.ZP,{src:"/hellofresh_website/empty-dish-thumbnail.png",alt:r,fill:!0,sizes:"(max-width: 640px) 60vw, (max-width: 1024px) 30vw, 260px",style:{objectFit:"cover"}})});oh.displayName="CommunityRecipeImage";var oy=p.memo(function(e){var t,r,o=e.recipe,n=e.onCardClick,i=(0,F.ZP)("cookbook").translateRaw,a=o.source_platform,l=i("cookbook.import.card.your_recipe")||"Your recipe",c=a&&ob.has(a)&&o.author?om(o.author):rr(a,null!==(t=o.websiteUrl)&&void 0!==t?t:"",l,o.author).label,u=o.name,p=(0,s.BX)(s.HY,{children:[(0,s.tZ)(oh,{imagePath:null!==(r=o.imagePath)&&void 0!==r?r:o.imageLink,alt:o.name}),(0,s.BX)("div",{style:{position:"absolute",top:0,left:0,right:0,bottom:0,display:"flex",flexDirection:"column",justifyContent:"flex-end",paddingTop:"32px",paddingLeft:"16px",paddingRight:"16px",paddingBottom:"16px",background:"linear-gradient(180deg, rgba(0, 0, 0, 0.45) 0%, transparent 28%, transparent 50%, rgba(0, 0, 0, 0.92) 100%)"},children:[c&&(0,s.BX)(y.xu,{display:"flex",alignItems:"center",gap:"global.xxs",mb:"global.xxs",children:[(0,s.tZ)(of,{platform:a}),(0,s.tZ)(y.xv,{type:"body-xs-regular",color:"shared-alias.neutral.foreground.inverse",children:c})]}),(0,s.tZ)(y.xv,{as:"h3",type:"body-md-bold",color:"shared-alias.neutral.foreground.inverse",children:o.name})]})]});return o.websiteUrl?(0,s.tZ)(y.Zb.Navigation,{variant:"filled",href:o.websiteUrl,padding:"global.none",display:"block",width:"100%","data-test-id":eL.card,onClick:n,"aria-label":u,children:(0,s.tZ)(y.xu,{position:"relative",width:"100%",overflow:"hidden",borderRadius:"global.md",aspectRatio:"171 / 256",children:p})}):(0,s.tZ)(y.xu,{position:"relative",width:"100%",overflow:"hidden",borderRadius:"global.md",aspectRatio:"171 / 256","aria-label":u,"data-test-id":eL.card,children:p})}),og=function(e,t){return function(){t(),e()}},ov=function(e){var t=e.onSaveRecipePress,r=e.onLearnHowPress,o=(0,F.ZP)("cookbook").translateRaw,n=eB(),i=n.recipes,a=n.status,l=r8(),c=l.containerRef,u=l.perPage,d=ot(),f=d.trackCarouselImpression,b=d.trackCommunityRecipeCardClick,m=d.trackCtaSaveRecipeClick,h=d.trackCtaLearnHowClick,g=(0,tJ.YD)({threshold:.3,triggerOnce:!0}),v=g.ref,k=g.inView,w=(0,p.useRef)(!1);(0,p.useEffect)(function(){k&&!w.current&&"success"===a&&(w.current=!0,f(i.slice(0,10)))},[k,a,i,f]);var O=r6();if("empty"===a||"error"===a)return null;var x=o("cookbook.empty_state.community_carousel.header.eyebrow",{defaultValue:"Recipes from the community"}),S=o("cookbook.empty_state.community_carousel.header.subtitle",{count:O,defaultValue:"".concat(O," people are saving recipes")}),C="loading"===a;return(0,s.BX)(y.xu,{ref:function(e){c&&"current"in c&&(c.current=e),v(e)},as:"section",width:"100%","data-test-id":"cookbook-community-carousel",mb:"global.md-2",children:[(0,s.BX)(y.xu,{mb:"global.sm-2",children:[(0,s.tZ)(y.xv,{type:"body-xs-bold",color:"neutral.500",textTransform:"uppercase",children:x}),(0,s.tZ)(y.xv,{as:"h2",type:"body-xl-bold",mt:"global.xxs",children:S})]}),C?(0,s.tZ)(y.xu,{display:"grid",gridTemplateColumns:["repeat(2, 1fr)","repeat(3, 1fr)","repeat(4, 1fr)"],gap:["global.sm-2","global.md-1"],children:Array.from({length:4}).map(function(e,t){return(0,s.tZ)(oo,{},t)})}):(0,s.BX)(y.lr,{id:"cookbook-community-carousel",perPage:u,snapAlign:"start",autosnap:!0,partialSlideView:u<3,showArrowNavigation:!0,hideNavigationWhenSinglePage:!0,paddingX:"global.none",children:[(0,s.tZ)(y.xu,{paddingRight:["global.sm-2","global.md-1"],aspectRatio:"171 / 256",children:(0,s.tZ)(oi,{onSaveRecipePress:og(t,m),onLearnHowPress:og(r,h)})}),i.slice(0,10).map(function(e){return(0,s.tZ)(y.xu,{paddingRight:["global.sm-2","global.md-1"],aspectRatio:"171 / 256",children:(0,s.tZ)(oy,{recipe:e,onCardClick:function(){return b(e)}})},e.id)})]})]})},ok=r(818997),ow=["save","picture","notes","learn"],oO={save:function(e){return!e.hasSavedRecipe},picture:function(e){return!e.hasUsedImageImport},notes:function(e){return!e.hasCreatedRecipe},learn:function(e){return e.needsEducation}},ox=function(e){var t=ow.filter(function(t){return oO[t](e)});return t.length>0?t:ow},oS={save:{label:"social-recipe-bridge.nba.save.label",a11yLabel:"social-recipe-bridge.nba.save.a11y.label"},picture:{label:"social-recipe-bridge.nba.picture.label",a11yLabel:"social-recipe-bridge.nba.picture.a11y.label"},notes:{label:"social-recipe-bridge.nba.notes.label",a11yLabel:"social-recipe-bridge.nba.notes.a11y.label"},learn:{label:"social-recipe-bridge.nba.learn.label",a11yLabel:"social-recipe-bridge.nba.learn.a11y.label"}},oC={save:"Save your first recipe",picture:"Save from a photo",notes:"Paste your recipe notes",learn:"Learn how to save recipes"},oj={save:"Recipe",picture:"Photo",notes:"Notes",learn:"LearnHow"},oP=function(){var e=(0,el.L3)().trackJanusEvent,t=(0,p.useRef)(!1);return(0,p.useEffect)(function(){t.current||(t.current=!0,e(ok.j.janusEvent()))},[e]),{trackNbaActionPress:(0,p.useCallback)(function(t){var r=oj[t];if("learn"===t){e(oe.v0.janusEvent({uiComponent:oe.v0.uiComponent({uiComponentName:r,uiComponentLabel:null,uiComponentPosition:null}
1),uiModal:oe.v0.uiModal({uiModalName:oe.E5.NextBestAction})}));return}e(eY.Eq.janusEvent({uiComponent:eY.Eq.uiComponent({uiComponentName:r,uiComponentLabel:oC[t],uiComponentPosition:null}),uiModal:eY.Eq.uiModal({uiModalName:eY.E5.NextBestAction})}))},[e])}};function o_(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function oZ(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return o_(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return o_(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var oI=function(e){var t=oZ((0,p.useState)(e[0]),2),r=t[0],o=t[1],n=oZ((0,p.useState)("visible"),2),i=n[0],a=n[1],l=(0,p.useRef)(e),c=(0,p.useRef)(0),u=(0,p.useRef)([]);l.current=e;var s=(0,p.useCallback)(function(){u.current.forEach(function(e){return window.clearTimeout(e)}),u.current=[]},[]);(0,p.useEffect)(function(){return s(),c.current=0,a("visible"),o(e[0]),s},[e.join("|")]);var d=(0,p.useCallback)(function(){var e,t=l.current;if(!(t.length<2)&&void 0!==t[0]){var r=null!==(e=t[c.current])&&void 0!==e?e:t[0],n=(t.indexOf(r)+1)%t.length;c.current=n,a("fading-out");var i=window.setTimeout(function(){o(null!==(e=t[n])&&void 0!==e?e:t[0]),a("fading-in");var e,r=window.setTimeout(function(){a("visible")},620);u.current.push(r)},320);u.current.push(i)}},[]);return(0,p.useEffect)(function(){if(!(e.length<2)){var t="function"==typeof window.matchMedia?window.matchMedia("(prefers-reduced-motion: reduce)"):{matches:!1},r=window.setInterval(function(){t.matches||d()},5940);return function(){window.clearInterval(r)}}},[e.length,d]),(0,p.useEffect)(function(){return s},[s]),{currentId:r,iconVisibility:i}},oE={save:"eie-nbavis-v5-save-web-alpha.gif",picture:"eie-nbavis-v5-picture-web-alpha.gif",notes:"eie-nbavis-v5-notes-web-alpha.gif",learn:"eie-nbavis-v5-learn-web-alpha.gif"},oR=function(e){var t=e.actionId;return(0,s.tZ)("img",{src:"".concat("https://media.hellofresh.com/hellofresh-website/cookbook/nba","/").concat(oE[t]),alt:"",width:80,height:54,style:{objectFit:"cover"}})},oA={hasSavedRecipe:!1,hasUsedImageImport:!1,hasCreatedRecipe:!1,needsEducation:!0}
1,oT="opacity ".concat(320,"ms ease-out, transform ").concat(320,"ms ease-out"),oD={visible:{opacity:1,transform:"translateX(0) scale(1) rotate(0deg)",transition:oT},"fading-out":{opacity:0,transform:"translateX(-14px) scale(0.6) rotate(-12deg)",transition:oT},"fading-in":{opacity:1,transform:"translateX(2px) scale(1) rotate(0deg)",transition:"opacity ".concat(620,"ms ease-out, transform ").concat(620,"ms ease-out")}},oL=function(e){var t=e.context,r=e.onActionPress,o=e.testId,n=(0,F.ZP)("social-recipe-bridge").translateRaw,i=oI(ox(void 0===t?oA:t)),a=i.currentId,l=i.iconVisibility,c=(0,p.useCallback)(function(){a&&r(a)},[a,r]);if(!a)return null;var u=oS[a],d=n(u.label,{defaultValue:oC[a]}),f=n(u.a11yLabel,{defaultValue:oC[a]});return(0,s.BX)(y.xu,{as:"button",type:"button",onClick:c,display:"flex",alignItems:"center",gap:"global.sm-1",width:"100%",height:"54px",px:"global.sm-1",backgroundColor:"alias.accent.default",borderRadius:"global.lg",boxShadow:"shadow-md","aria-label":f,"data-test-id":void 0===o?"next-best-action":o,cursor:"pointer",textAlign:"left",borderStyle:"none",children:[(0,s.tZ)(y.xu,{flexShrink:0,width:"80px",height:"54px",overflow:"hidden",children:(0,s.tZ)("div",{style:oD[l],children:(0,s.tZ)(oR,{actionId:a})})}),(0,s.tZ)(y.xu,{flex:"1",minWidth:0,children:(0,s.tZ)(y.xv,{type:"body-md-bold",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",children:d})}),(0,s.tZ)(y.xu,{flexShrink:0,children:(0,s.tZ)(y.JO,{icon:(0,s.tZ)(r0.Z,{}),color:"neutral.600"})})]})};function oB(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function oM(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return oB(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return oB(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var oV={platform:"platform",find:"copy",copy:"paste",paste:"paste"},oU={platform:"platform",find:"platform",copy:"find",paste:"copy"},oN=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"platform",t=oM((0,p.useState)(e),2),r=t[0],o=t[1],n=oM((0,p.useState)(null),2),i=n[0],a=n[1];return{screen:r,selectedPlatform:i,selectPlatform:(0,p.useCallback)(function(e){a(e),o("find")},[]),next:(0,p.useCallback)(function(){o(function(e){return oV[e]})},[]),back:(0,p.useCallback)(function(){o(function(e){return oU[e]})},[]),reset:(0,p.useCallback)(function(){o("platform"),a(null)},[]),goTo:(0,p.useCallback)(function(e,t){o(e),a(null!=t?t:null)},[])}},oz=r(988402),oX="https://media.hellofresh.com/hellofresh_website/cookbook/import/social-icons",oF=[{id:"website",iconUrl:"".concat(oX,"/web.png"),titleKey:"cookbook.import.tutorial_walkthrough.platform.website.title",defaultTitle:"Recipe website",descriptionKey:"cookbook.import.tutorial_walkthrough.platform.website.description",defaultDescription:"Copy the URL from your browser"},{id:"instagram",iconUrl:"".concat(oX,"/instagram.png"),titleKey:"cookbook.import.tutorial_walkthrough.platform.instagram.title",defaultTitle:"Instagram",descriptionKey:"cookbook.import.tutorial_walkthrough.platform.instagram.description",defaultDescription:"Copy a link from a post or Reel"},{id:"tiktok",iconUrl:"".concat(oX,"/tiktok.png"),titleKey:"cookbook.import.tutorial_walkthrough.platform.tiktok.title",defaultTitle:"TikTok",descriptionKey:"cookbook.import.tutorial_walkthrough.platform.tiktok.description",defaultDescription:"Copy a link from a recipe video"},{id:"youtube",iconUrl:"".concat(oX,"/youtube.png"),titleKey:"cookbook.import.tutorial_walkthrough.platform.y
1outube.title",defaultTitle:"YouTube",descriptionKey:"cookbook.import.tutorial_walkthrough.platform.youtube.description",defaultDescription:"Copy a link from a recipe video"},{id:"facebook",iconUrl:"".concat(oX,"/facebook.png"),titleKey:"cookbook.import.tutorial_walkthrough.platform.facebook.title",defaultTitle:"Facebook",descriptionKey:"cookbook.import.tutorial_walkthrough.platform.facebook.description",defaultDescription:"Copy a link from a post or Reel"}],oH=function(e){var t=e.onSelectPlatform,r=(0,F.ZP)("cookbook").translateRaw;return(0,s.tZ)(y.xu,{display:"grid",gridTemplateColumns:["1fr","1fr","repeat(2, 1fr)"],gap:"global.sm-2","data-test-id":"cookbook-import-tutorial-walkthrough-platform-select",children:oF.map(function(e){var o=r(e.titleKey,{defaultValue:e.defaultTitle}),n=r(e.descriptionKey,{defaultValue:e.defaultDescription});return(0,s.tZ)(y.Zb.Navigation,{href:"#",variant:"filled",scroll:!1,onClick:function(r){r.preventDefault(),t(e.id)},backgroundColor:"alias.elevation.level-1",padding:"global.sm-2","aria-label":o,"data-test-id":"cookbook-import-tutorial-walkthrough-platform-".concat(e.id),children:(0,s.BX)(y.xu,{display:"flex",alignItems:"center",gap:"global.sm-2",width:"100%",children:[(0,s.tZ)(t6.ZP,{src:e.iconUrl,alt:"","aria-hidden":"true",width:40,height:40,style:{objectFit:"contain",flexShrink:0},unoptimized:!0}),(0,s.BX)(y.xu,{flexGrow:1,minWidth:0,textAlign:"left",children:[(0,s.tZ)(y.xv,{as:"p",type:"body-md-bold",children:o}),(0,s.tZ)(y.xv,{as:"p",type:"body-sm-regular",color:"neutral.500",children:n})]}),(0,s.tZ)(oz.default,{"aria-hidden":!0})]})},e.id)})})},oq=[{screen:"find",listValueKey:"cookbook.import.tutorial_walkthrough.step.find.list_value",defaultListValue:"Find",titleKey:"cookbook.import.tutorial_walkthrough.step.find.title",defaultTitle:"Find the recipe",bodyKey:"cookbook.import.tutorial_walkthrough.step.find.body",defaultBody:"Open it on any recipe blog, website or social post you like."},{screen:"copy",listValueKey:"cookbook.import.tutorial_walkthrough.step.copy.list_value",defaultListValue:"Copy",titleKey:"cookbook.import.tutorial_walkthrough.step.copy.title",defaultTitle:"Copy the link",bodyKey:"cookbook.import.tutorial_walkthrough.step.copy.body",defaultBody:"Use Share, then Copy link — or copy the address from your browser."},{screen:"paste",listValueKey:"cookbook.import.tutorial_walkthrough.step.paste.list_value",defaultListValue:"Paste",titleKey:"cookbook.import.tutorial_walkthrough.step.paste.title",defaultTitle:"Paste the link and save",bodyKey:"cookbook.import.tutorial_walkthrough.step.paste.body",defaultBody:"Paste it into the field above and select Save recipe."}],oY="cookbook.import.tutorial_walkthrough.step.find",oW={website:{urlText:"hellofresh.com/recipes/creamy-garlic-pasta",titleKey:"".concat(oY,".title"),defaultTitle:"Find the recipe",bodyKey:"".concat(oY,".body"),defaultBody:"Open it on any recipe blog, website or social post you like."},instagram:{urlText:"instagram.com/recipe",titleKey:"".concat(oY,".instagram.title"),defaultTitle:"Open the recipe post",bodyKey:"".concat(oY,".instagram.body"),defaultBody:"Find the reel or post with the recipe in Instagram."},tiktok:{urlText:"tiktok.com/recipe",titleKey:"".concat(oY,".tiktok.title"),defaultTitle:"Find the recipe video",bodyKey:"".concat(oY,".tiktok.body"),defaultBody:"Open the recipe video in TikTok."},youtube:{urlText:"youtube.com/recipe",titleKey:"".concat(oY,".youtube.title"),defaultTitle:"Open the recipe video",bodyKey:"".concat(oY,".youtube.body"),defaultBody:"Find the cooking video on YouTube."},facebook:{urlText:"facebook.com/recipe",titleKey:"".concat(oY,".facebook.title"),defaultTitle:"Open the recipe post",bodyKey:"".concat(oY,".facebook.body"),defaultBody:"Find the reel or post with the recipe in Facebook."}},oK=r(972167),oG=function(e){var t=e.url;return(0,s.BX)(y.xu,{"data-test-id":"cookbook-import-tutorial-walkthrough-browser-chrome",backgroundColor:"global.white",borderRadius:"border-radius-md",boxShadow:"shadow-sm",overflow:"hidden",width:"300px",height:"126px",flexShrink:0,display:"flex",flexDirection:"column",children:[(0,s.BX)(y.xu,{display:"flex",alignItems:"center",gap:"global.xxs",flexShrink:"0",backgroundColor:"neutral.200",px:"global.xs",py:"global.xs",children:[(0,s.tZ)(y.xu,{display:"flex",gap:"global.xxs",flexShrink:"0",children:[0,1,2].map(function(e){return(0,s.tZ)(y.xu,{width:"5px",height:"5
1px",borderRadius:"border-radius-circle",backgroundColor:"neutral.400"},e)})}),(0,s.tZ)(y.xu,{flex:1,minWidth:0,backgroundColor:"global.white",borderRadius:"border-radius-pill",px:"global.xs",py:"global.xxs",overflow:"hidden",children:(0,s.tZ)(y.xv,{type:"body-xs-regular",color:"neutral.700",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",children:t})})]}),(0,s.tZ)(y.xu,{"data-test-id":"cookbook-import-tutorial-walkthrough-browser-chrome-content",flex:1,display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"neutral.100",children:(0,s.tZ)(y.JO,{icon:(0,s.tZ)(oK.default,{}),color:"neutral.400"})})]})};function oJ(){var e,t,r=(e=["\n  background: var(\n    --card-color-navigational-theme-elevated-backgound-default,\n    #efe9de\n  );\n"],t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}})));return oJ=function(){return r},r}var o$=(0,eU.ZP)(y.xu).withConfig({componentId:"sc-960c5e50-0"})(oJ()),oQ=function(e){var t=e.url;return(0,s.tZ)(o$,{"data-test-id":"cookbook-import-tutorial-walkthrough-find-mockup",borderRadius:"border-radius-sm",display:"flex",alignItems:"center",justifyContent:"center",minHeight:"220px",py:"global.md-2",children:(0,s.tZ)(oG,{url:t})})},o0=r(912449),o1=r(201425);function o2(){var e,t,r=(e=["\n  background: var(\n    --card-color-navigational-theme-elevated-backgound-default,\n    #efe9de\n  );\n"],t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}})));return o2=function(){return r},r}var o4=(0,eU.ZP)(y.xu).withConfig({componentId:"sc-c01d03e4-0"})(o2()),o3="cookbook.import.tutorial_walkthrough.step.copy.share_sheet",o8=function(e){var t=e.icon,r=e.label,o=e.highlighted,n=e["data-test-id"];return(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",alignItems:"center",gap:"global.xxs",children:[(0,s.tZ)(y.xu,{"data-test-id":n,backgroundColor:"global.white",borderRadius:"border-radius-circle",width:"40px",height:"40px",display:"flex",alignItems:"center",justifyContent:"center",borderWidth:o?"2px":void 0,borderStyle:o?"solid":void 0,borderColor:o?"success.300":void 0,children:t}),(0,s.tZ)(y.xv,{type:"body-xs-regular",color:"neutral.700",children:r})]})},o5=function(e){var t=e.url,r=(0,F.ZP)("cookbook").translateRaw,o=r("".concat(o3,".share"),{defaultValue:"Share"}),n=r("".concat(o3,".copy_link"),{defaultValue:"Copy link"}),i=r("".concat(o3,".more"),{defaultValue:"More"}),a=r("cookbook.import.tutorial_walkthrough.step.copy.link_copied",{defaultValue:"Link copied"});return(0,s.BX)(o4,{"data-test-id":"cookbook-import-tutorial-walkthrough-copy-mockup",borderRadius:"border-radius-sm",display:"flex",flexDirection:"column",alignItems:"center",gap:"global.sm-1",minHeight:"220px",py:"global.md-2",px:"global.sm-2",children:[(0,s.BX)(y.xu,{display:"flex",flexDirection:["column","column","row"],alignItems:"center",gap:"global.sm-2",children:[(0,s.tZ)(oG,{url:t}),(0,s.BX)(y.xu,{display:"flex",gap:"global.sm-1",children:[(0,s.tZ)(o8,{icon:(0,s.tZ)(y.JO,{icon:(0,s.tZ)(o0.default,{}),color:"neutral.700"}),label:o}),(0,s.tZ)(o8,{icon:(0,s.tZ)(y.JO,{icon:(0,s.tZ)(tS.default,{}),color:"neutral.700"}),label:n,highlighted:!0,"data-test-id":"cookbook-import-tutorial-walkthrough-copy-link-action"}),(0,s.tZ)(o8,{icon:(0,s.tZ)(y.xv,{type:"body-md-bold",color:"neutral.700",children:"•••"}),label:i,"data-test-id":"cookbook-import-tutorial-walkthrough-copy-more-action"})]})]}),(0,s.tZ)(y.uj,{type:"strong",variant:"v3",leadingIcon:(0,s.tZ)(o1.Z,{}),children:a})]})};function o6(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}function o7(){var e=o6(["\n  display: flex;\n  align-items: center;\n  min-height: 48px;\n  border: 1px solid #e0e0e0;\n  border-radius: 999px;\n  padding: 8px 16px;\n  background: #ffffff;\n  box-shadow: 0px 1px 3px rgba(35, 26, 10, 0.06);\n  gap: 10px;\n"]);return o7=function(){return e},e}function o9(){var e=o6(["\n  display: flex;\n  align-items: center;\n  justify-content: center;\n  min-height: 48px;\n  background: var(--color-brand-foreground-default, #067a46);\n  border-radius: 8px;\n  padding: 0 24px;\n  white-space: nowrap;\n  flex-shrink: 0;\n"]);return o9=function(){return e},e}function ne(){var e=o6(["\n  background: var(\n    --card-color-navigational-theme-elevated-backgound-default,\n    #efe9de\n  );\n"]);return ne=function(){return e},e}var nt=(0,eU.ZP)(y.xu).withConfig({componentId:"sc-390237fd-0"})(o7()),nr=(0,eU.ZP)(y.xu).withConfig({componentId:"sc-390237fd-1"})(o9()),no=(0,eU.ZP)(y.xu).withConfig({componentId:"sc-390237fd-2"})(ne()),nn=function(){var e=(0,F.ZP)("cookbook").translateRaw,t=e("cookbook.import.tutorial_walkthrough.step.paste.recipe_link",{defaultValue:"Paste a recipe link"}),r=e("cookbook.import.tutorial_walkthrough.step.paste.save",{defaultValue:"Save recipe"});
1return(0,s.tZ)(no,{"data-test-id":"cookbook-import-tutorial-walkthrough-paste-mockup",borderRadius:"border-radius-sm",display:"flex",alignItems:"center",justifyContent:"center",minHeight:"220px",py:"global.md-2",px:"global.md-1",children:(0,s.BX)(y.xu,{display:"flex",flexDirection:["column","column","row"],gap:"global.sm-2",alignItems:"center",width:"100%",maxWidth:"380px",children:[(0,s.BX)(nt,{flex:"1",minWidth:0,children:[(0,s.tZ)(y.JO,{icon:(0,s.tZ)(eM.default,{}),color:"neutral.400"}),(0,s.tZ)(y.xv,{type:"body-sm-regular",color:"neutral.500",children:t})]}),(0,s.tZ)(nr,{children:(0,s.tZ)(y.xv,{type:"body-sm-bold",color:"global.white",children:r})})]})})},ni=function(e){var t=e.screen,r=e.selectedPlatform,o=e.onBack,n=e.onPrimaryAction,i=(0,F.ZP)("cookbook").translateRaw,a=oq.findIndex(function(e){return e.screen===t}),l=oq[a],c=oW[null!=r?r:"website"],u=oq.map(function(e,t){var r=i(e.listValueKey,{defaultValue:e.defaultListValue});return{listValue:r,href:"#",disabled:t!==a,progress:t<a?"completed":t===a?"current":"next","aria-label":r}}),p="find"===t?i(c.titleKey,{defaultValue:c.defaultTitle}):i(l.titleKey,{defaultValue:l.defaultTitle}),d="find"===t?i(c.bodyKey,{defaultValue:c.defaultBody}):i(l.bodyKey,{defaultValue:l.defaultBody}),f=i("cookbook.import.tutorial_walkthrough.footer.back",{defaultValue:"Back"}),b=i("cookbook.import.tutorial_walkthrough.footer.next",{defaultValue:"Next"}),m=i("cookbook.import.tutorial_walkthrough.footer.done",{defaultValue:"Done"});return(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",gap:"global.md-1",pt:"global.xxs-2","data-test-id":"cookbook-import-tutorial-walkthrough-step-".concat(t),children:[(0,s.tZ)(y.pZ,{variant:"numbered",steps:u,customAriaLabel:i("cookbook.import.tutorial_walkthrough.stepper.aria_label",{defaultValue:"Walkthrough progress"})}),"paste"===t&&(0,s.tZ)(nn,{}),"find"===t&&(0,s.tZ)(oQ,{url:c.urlText}),"copy"===t&&(0,s.tZ)(o5,{url:c.urlText}),(0,s.BX)(y.xu,{children:[(0,s.tZ)(y.xv,{as:"h2",type:"body-xl-bold",children:p}),(0,s.tZ)(y.xv,{as:"p",type:"body-md-regular",color:"neutral.500",children:d})]}),(0,s.BX)(y.xu,{display:"flex",justifyContent:"space-between",mt:"global.sm-1",children:[(0,s.tZ)(y.zx.Secondary,{size:"lg",width:"fit-content",onClick:o,"data-test-id":"cookbook-import-tutorial-walkthrough-back",children:f}),(0,s.tZ)(y.zx.Primary,{size:"lg",width:"fit-content",onClick:n,"data-test-id":"cookbook-import-tutorial-walkthrough-primary-action",children:"paste"===t?m:b})]})]})},na=r(274090),nl=r(118380),nc=r(751554),nu=r(237555),ns="ImportTutorialWalkthrough",np={find:1,copy:2,paste:3},nd={website:"url",instagram:"social_media",tiktok:"social_media",youtube:"social_media",facebook:"social_media"},nf=function(e,t){var r=(0,el.L3)().trackJanusEvent,o=(0,p.useRef)(!1),n=(0,p.useRef)(!1),i=(0,p.useRef)(new Set),a=(0,p.useCallback)(function(e,t){try{t()}catch(t){(0,eH.Tb)(t,{tags:{event:e,component:"useTutorialWalkthroughTracking"}})}},[]);return(0,p.useEffect)(function(){if(!t){o.current=!1,n.current=!1,i.current.clear();return}if("platform"===e){if(o.current)return;o.current=!0,a("Cookbook_Drawer_SourceSelector_Impression",function(){return r(nc.e.janusEvent({uiComponent:nc.e.uiComponent({uiComponentName:"DiscoverSourceSelectorDrawer",uiComponentLabel:"Where's the recipe?"})}))})}else if("paste"===e)i.current.has(e)||(i.current.add(e),a("Cookbook_Drawer_RecipeImportTutorial_Impression",function(){return r(nl.X.janusEvent({uiComponent:nl.X.uiComponent({uiComponentName:ns,uiComponentLabel:e,uiComponentPosition:np[e]})}))})),n.current||(n.current=!0,a("Cookbook_Drawer_RecipeImportTutorialCompletion_Impression",function(){return r(na.Y.janusEvent({uiComponent:na.Y.uiComponent({uiComponentName:"ImportTutorialCompletion",uiComponentLabel:e,uiComponentPosition:np[e]})}))}));else{if(i.current.has(e))return;i.current.add(e),a("Cookbook_Drawer_RecipeImportTutorial_Impression",function(){return r(nl.X.janusEvent({uiComponent:nl.X.uiComponent({uiComponentName:ns,uiComponentLabel:e,uiComponentPosition:np[e]})}))})}},[t,e,a,r]),{trackSourceSelect:(0,p.useCallback)(function(e,t){a("
1Cookbook_Select_Source_Button_Click",function(){var o;return r(nu.M.janusEvent({uiComponent:nu.M.uiComponent({uiComponentName:null!==(o=nd[e])&&void 0!==o?o:"other",uiComponentLabel:t})}))})},[a,r])}},nb=function(e){var t=e.isOpen,r=e.onClose,o=e.initialScreen,n=(0,F.ZP)("cookbook").translateRaw,i=oN(o),a=i.screen,l=i.selectedPlatform,c=i.selectPlatform,u=i.next,d=i.back,f=i.reset,b=i.goTo,m=nf(a,t).trackSourceSelect,h=(0,p.useCallback)(function(e){var t=oF.findIndex(function(t){return t.id===e}),r=oF[t];m(e,n(r.titleKey,{defaultValue:r.defaultTitle})),c(e)},[c,m,n]);(0,p.useEffect)(function(){t?o&&b(o):f()},[t]);var g=n("cookbook.import.tutorial_walkthrough.platform_select.title",{defaultValue:"Where's the recipe?"}),v=n("cookbook.import.tutorial_walkthrough.platform_select.subtitle",{defaultValue:"Pick a website to save your recipe."}),k=oq.find(function(e){return e.screen===a}),w=oW[null!=l?l:"website"],O=g;return"find"===a?O=n(w.titleKey,{defaultValue:w.defaultTitle}):k&&(O=n(k.titleKey,{defaultValue:k.defaultTitle})),(0,s.tZ)(y.Vq,{isOpen:t,onClose:r,onDismiss:r,headless:!0,hasCloseButton:!0,width:["90%","90%","620px"],dialogCustomOverflow:"auto",dialogBodyMinHeight:"auto",padding:["global.md-1","global.md-1","global.md-2"],"aria-label":O,"data-test-id":"cookbook-import-tutorial-walkthrough-dialog",children:(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",gap:"global.md-1",children:["platform"===a&&(0,s.BX)(s.HY,{children:[(0,s.BX)(y.xu,{textAlign:"center",children:[(0,s.tZ)(y.xv,{as:"h2",type:"body-xl-bold",children:g}),(0,s.tZ)(y.xv,{as:"p",type:"body-md-regular",color:"neutral.500",children:v})]}),(0,s.tZ)(oH,{onSelectPlatform:h})]}),"platform"!==a&&(0,s.tZ)(ni,{screen:a,selectedPlatform:l,onBack:d,onPrimaryAction:"paste"===a?r:u})]})})},nm=r(659980),nh=function(e){var t=e.isOpen,r=e.onClose,o=e.recipeTitles,n=e.firstRecipeThumbnailUrl,i=(0,F.ZP)("cookbook").translateRaw,a=(0,e3.Sj)(),l=(0,b.t)(),c=(0,tY.l)(),u=function(e){c.setItem("hf_cookbook_pending_transfer_titles",o),l.push("".concat(e,"?redirectUrl=").concat(encodeURIComponent("/cookbook/import"),"&displayCookbookBanner=true"))},p=i("cookbook.import.sign_in_nudge.titles_heading",{count:String(o.length),defaultValue:"Your ".concat(o.length," saved recipes are waiting")}),d=o.join(", ");return(0,s.tZ)(y.Vq,{isOpen:t,onClose:r,onDismiss:r,headless:!0,hasCloseButton:!0,width:["100%","100%","480px"],fullScreen:"mobile"===a,dialogCustomOverflow:"auto",dialogBodyMinHeight:["100%","100%","auto"],padding:["global.md-1","global.md-1","global.md-2"],"aria-label":i("cookbook.import.sign_in_nudge.title",{defaultValue:"Sign in to keep saving"}),"data-test-id":"cookbook-import-sign-in-nudge-modal",children:(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",alignItems:"center",textAlign:"center",gap:"global.sm-2",py:"global.sm-2",children:[(0,s.tZ)(t6.ZP,{src:"/hellofresh_website/cookbook/landing-page/sign-in-nudge.png",alt:"","aria-hidden":"true",width:160,height:160,style:{objectFit:"contain"},"data-test-id":"cookbook-import-sign-in-nudge-illustration"}),(0,s.tZ)(y.xv,{as:"h2",type:"body-xl-bold",children:i("cookbook.import.sign_in_nudge.title",{defaultValue:"Sign in to keep saving"})}),(0,s.tZ)(y.xv,{as:"p",type:"body-md-regular",color:"neutral.700",children:i("cookbook.import.sign_in_nudge.subtitle",{defaultValue:"Save your recipes and never lose them."})}),o.length>0&&(0,s.BX)(y.xu,{"data-test-id":"cookbook-import-sign-in-nudge-titles",backgroundColor:"global.white",borderRadius:"border-radius-sm",borderWidth:"1px",borderColor:"neutral.300",borderStyle:"solid",width:"100%",mt:"global.sm-1",px:"global.md-1",py:"global.sm-2",display:"flex",alignItems:"center",gap:"global.sm-2",textAlign:"left",children:[n&&(0,s.tZ)(t6.ZP,{src:n,alt:"","aria-hidden":"true",width:56,height:56,style:{objectFit:"cover",borderRadius:"8px",flexShrink:0},unoptimized:!0,"data-test-id":"cookbook-import-sign-in-nudge-thumbnail"}),(0,s.BX)(y.xu,{children:[(0,s.tZ)(y.xv,{as:"p",type:"body-sm-bold",color:"neutral.800",children:p}),(0,s.BX)(y.xv,{as:"p",type:"body-sm-regular",color:"neutral.700",children:[d,"."]})]})]}),(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",gap:"global.xs",mt:"global.sm-2",width:"100%",children:[(0,s.tZ)(y.zx.Primary,{size:"lg",onClick:function(){return u("/login")}
1,"data-test-id":"cookbook-import-sign-in-nudge-signup-cta",children:i("cookbook.import.sign_in_nudge.signup_cta",{defaultValue:"Sign in to continue"})}),(0,s.tZ)(y.zx.Secondary,{size:"lg",onClick:function(){return u("/login")},"data-test-id":"cookbook-import-sign-in-nudge-login-cta",children:i("cookbook.import.sign_in_nudge.login_cta",{defaultValue:"Log in"})})]})]})})},ny=r(966622),ng=r(943701),nv=r(907070),nk=r(365603),nw=function(){var e=(0,el.L3)().trackJanusEvent;return{trackClose:(0,p.useCallback)(function(){try{e(nk.T.janusEvent())}catch(e){(0,eH.Tb)(e,{tags:{event:"Cookbook_Close_Onboarding_Modal_Click",component:"useTrackCookbookWelcomeCloseButtonClick"}})}},[e])}},nO=function(){var e=(0,el.L3)().trackJanusEvent;return{trackCtaClick:(0,p.useCallback)(function(){try{e(eY.Eq.janusEvent({uiComponent:eY.Eq.uiComponent({uiComponentName:"LetsGetStarted",uiComponentLabel:"Let's get started",uiComponentPosition:null}),uiModal:eY.Eq.uiModal({uiModalName:eY.E5.CookbookWelcome})}))}catch(e){(0,eH.Tb)(e,{tags:{event:"Cookbook_Start_Import_Button_Click",component:"useTrackCookbookWelcomeCtaButtonClick"}})}},[e])}},nx=r(803211),nS=function(){var e=(0,el.L3)().trackJanusEvent;return{trackImpression:(0,p.useCallback)(function(){try{e(nx.G.janusEvent())}catch(e){(0,eH.Tb)(e,{tags:{event:"Cookbook_Modal_CookbookWelcome_Impression",component:"useTrackCookbookWelcomeImpression"}})}},[e])}},nC=r(688985),nj=r(128643),nP={SCREEN:"cookbook-welcome",CTA:"cookbook-welcome-cta",FEATURE_LIST:"cookbook-welcome-feature-list",FEATURE_ROW:"cookbook-welcome-feature-row",EYEBROW:"cookbook-welcome-eyebrow",HEADLINE:"cookbook-welcome-headline",ILLUSTRATION:"cookbook-welcome-illustration"},n_={EYEBROW:"cookbook.welcome_drawer.eyebrow",EYEBROW_A11Y:"cookbook.welcome_drawer.eyebrow.accessibility_label",HEADLINE:"cookbook.welcome_drawer.headline",CTA:"cookbook.welcome_drawer.cta.label",CTA_A11Y_HINT:"cookbook.welcome_drawer.cta.accessibility_hint",CLOSE_A11Y_LABEL:"cookbook.welcome_drawer.close.accessibility_label",CLOSE_A11Y_HINT:"cookbook.welcome_drawer.close.accessibility_hint",FEATURE_SAVE:"cookbook.welcome_drawer.feature.save.label",FEATURE_SAVE_SUBTITLE:"cookbook.welcome_drawer.feature.save.subtitle",FEATURE_ORGANISE:"cookbook.welcome_drawer.feature.organise.label",FEATURE_ORGANISE_SUBTITLE:"cookbook.welcome_drawer.feature.organise.subtitle",FEATURE_PLAN:"cookbook.welcome_drawer.feature.plan.label",FEATURE_PLAN_SUBTITLE:"cookbook.welcome_drawer.feature.plan.subtitle",FEATURE_CREATE:"cookbook.welcome_drawer.feature.create.label",FEATURE_CREATE_SUBTITLE:"cookbook.welcome_drawer.feature.create.subtitle",FEATURE_KEEP:"cookbook.welcome_drawer.feature.keep.label",FEATURE_KEEP_SUBTITLE:"cookbook.welcome_drawer.feature.keep.subtitle"},nZ={save:rF.default,organise:nC.default,plan:nj.default,create:eV.default,keep:null},nI=function(e){var t=e.item;return(0,s.BX)(y.xu,{display:"flex",flexDirection:"row",alignItems:"center",gap:"global.sm-1","data-test-id":"".concat(nP.FEATURE_ROW,"-").concat(t.id),children:[(0,s.tZ)(y.xu,{display:"flex",alignItems:"center",justifyContent:"center",width:"".concat(40,"px"),height:"".concat(40,"px"),borderRadius:"border-radius-circle",backgroundColor:"alias.brand.background.lighter",flexShrink:0,"aria-hidden":"true",children:"keep"===t.id?(0,s.tZ)(y.xv,{type:"body-lg-regular",textAlign:"center",children:"∞"}):t.icon&&(0,s.tZ)(y.JO,{icon:(0,s.tZ)(t.icon,{}),color:"neutral.800"})}),(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",gap:"global.none",flex:1,children:[(0,s.tZ)(y.xv,{type:"body-md-bold",color:"neutral.800",children:t.label}),(0,s.tZ)(y.xv,{type:"body-sm-regular",color:"neutral.700",children:t.subtitle})]})]})},nE={EYEBROW:"Welcome to Cookbook",EYEBROW_A11Y:"Welcome to Cookbook",HEADLINE:"Your recipes, all in one place",CTA:"Save your first recipe",CTA_A11Y_HINT:"Dismisses the welcome screen",CLOSE_A11Y_LABEL:"Close",CLOSE_A11Y_HINT:"Dismisses the welcome screen",FEATURE_SAVE:"Save recipes from anywhere",FEATURE_SAVE_SUBTITLE:"Social media, blogs, websites and HelloFresh.",FEATURE_ORGANISE:"Organise everything",FEATURE_ORGANISE_SUBTITLE:"Curate collections to keep your recipes easy to find.",FEATURE_PLAN:"Turn recipes into a grocery list",FEATURE_PLAN_SUBTITLE:"Use your saved recipes to plan what you need.",FEATURE_CREATE:"Create recipes from photos & notes",FEATURE_CREATE_SUBTITLE:"Share a link, upload a photo or paste your own text.",FEATURE_KEEP:"Cookbook is yours to keep",FEATURE_KEEP_SUBTITLE:"Your saved recipes stay with you, even if you cancel your subscription."},nR=function(){var e=(0,F.ZP)("cookbook").translateRaw;return{translations:{eyebrow:e(n_.EYEBROW,{defaultValue:nE.EYEBROW}),eyebrowA11y:e(n_.EYEBROW_A11Y,{defaultValue:nE.EYEBROW_A11Y}),headline:e(n_.HEADLINE,{defaultValue:nE.HEADLINE}),cta:e(n_.CTA,{defaultValue:nE.CTA}),ctaA11yHint:e(n_.CTA_A11Y_HINT,{defaultValue:nE.CTA_A11Y_HINT}),closeA11yLabel:e(n_.CLOSE_A11Y_LABEL,{defaultValue:nE.CLOSE_A11Y_LABEL}),closeA11yHint:e(n_.CLOSE_A11Y_HINT,{defaultValue:nE.CLOSE_A11Y_HINT})},featureItems:["save","organise","plan","create","keep"].map(function(t){var r="FEATURE_".concat(t.toUpperCase()),o="".concat(r,"_SUBTITLE");return{id:t,icon:nZ[t],label:e(n_[r],{defaultValue:nE[r]}),subtitle:e(n_[o],{defaultValue:nE[o]})}})}},nA=r(425842),nT=function(){var e=(0,nA.J)();return{getVariants:function(t){return e?{initial:{opacity:1,y:0}
1,animate:{opacity:1,y:0}}:{initial:{opacity:0,y:8},animate:{opacity:1,y:0,transition:{delay:.25+.2*t,duration:.22}}}},prefersReducedMotion:e}};function nD(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}var nL=function(){var e,t=function(e){if(Array.isArray(e))return e}(e=(0,p.useState)(!1))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,2)||function(e,t){if(e){if("string"==typeof e)return nD(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return nD(e,2)}}(e,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],o=t[1];return r?null:(0,s.tZ)(y.xu,{display:"flex",justifyContent:"flex-start",alignItems:"flex-start","aria-hidden":"true","data-test-id":nP.ILLUSTRATION,children:(0,s.tZ)(t6.ZP,{src:"https://media.hellofresh.com/hellofresh-website/cookbook/onboarding/welcome/welcome-hero-v5.gif",alt:"",width:96,height:182,unoptimized:!0,style:{objectFit:"contain"},onError:function(){return o(!0)}})})},nB=function(e){var t,r=e.onDismiss,o=e.onGetStarted,n=nR(),i=n.translations,a=n.featureItems,l=nT().getVariants,c=nS().trackImpression,u=nw().trackClose,d=nO().trackCtaClick,f=(0,e3.Sj)(),b=(0,p.useRef)(null);(0,p.useEffect)(function(){c()},[c]);var m=function(){u(),r()},h=(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",alignItems:"flex-start",width:"100%",gap:"global.sm-1",children:[(0,s.tZ)(nL,{}),(0,s.tZ)(y.xu,{mb:"global.xs",children:(0,s.tZ)(y.uj,{type:"subtle",variant:"v6",size:"sm",fontWeight:"regular","data-test-id":nP.EYEBROW,"aria-label":null!==(t=i.eyebrowA11y)&&void 0!==t?t:i.eyebrow,children:i.eyebrow.toUpperCase()})}),(0,s.tZ)(y.xv,{as:"h3",type:"body-xxl-bold",color:"neutral.800",textAlign:"left",mb:"global.sm-1","data-test-id":nP.HEADLINE,children:i.headline}),(0,s.tZ)(y.xu,{display:"flex",flexDirection:"column",width:"100%",gap:"global.sm-3",mb:"global.sm-2","data-test-id":nP.FEATURE_LIST,children:a.map(function(e,t){return(0,s.tZ)(nv.E.div,{initial:l(t).initial,animate:l(t).animate,children:(0,s.tZ)(nI,{item:e})},e.id)})}),(0,s.tZ)(y.xu,{width:"100%",pb:"global.xs",children:(0,s.tZ)(y.zx.Primary,{size:"lg",appearance:"brand",width:"100%",onClick:function(){d(),o()},"data-test-id":nP.CTA,"aria-label":i.cta,"aria-description":i.ctaA11yHint,children:i.cta})})]});return"mobile"===f?(0,s.tZ)(y.dy.Container,{isModal:!0,isOpen:!0,placement:"bottom",width:"100%",returnFocusRef:b,onClose:m,onDismiss:m,isTouchMoveEnabled:!0,positionAbsoluteCloseButton:!0,"aria-label":i.headline,"data-test-id":nP.SCREEN,children:h}):(0,s.tZ)(y.Vq,{isOpen:!0,onClose:m,onDismiss:m,headless:!0,hasCloseButton:!0,width:["100%","100%","480px"],dialogCustomOverflow:"auto",dialogBodyMinHeight:["100%","100%","auto"],padding:["global.md-1","global.md-1","global.md-2"],"aria-label":i.headline,"data-test-id":nP.SCREEN,children:h})},nM=r(783244);function nV(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}var nU=function(){var e,t=function(e){if(Array.isArray(e))return e}(e=(0,nM.Z)("hf_cookbook_welcome_drawer_seen",{defaultValue:"false"}))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,2)||function(e,t){if(e){if("string"==typeof e)return nV(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);
1if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return nV(e,2)}}(e,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],o=t[1];return{hasSeen:"true"===r,markAsSeen:(0,p.useCallback)(function(){o("true")},[o])}},nN=function(e){var t=e.onDismiss,r=e.onGetStarted,o=(0,ny.py)({runUsingStatsig:!0}),n=o.decide,i=o.isReady,a=(0,ng.R)({runUsingStatsig:!0}),l=a.id,c=a.attributes,u=a.isReady,p=nU(),d=p.hasSeen,f=p.markAsSeen;if(!i||!u)return null;var b=n({experimentKey:"cookbook-welcome-web",experimentationUserId:l,experimentationUserAttributes:c}),m=b.variationKey,h=b.parameters;return!(i&&("Test"===m||(null==h?void 0:h.isEnabled)===!0))||d?null:(0,s.tZ)(nB,{onDismiss:function(){f(),t()},onGetStarted:function(){f(),r()}})};function nz(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}var nX=function(e){var t,r=e.isAtLimit,o=e.isCustomer,n=e.recipeTitles,i=e.firstRecipeThumbnailUrl,a=e.atCapArrival,l=function(e){if(Array.isArray(e))return e}(t=(0,p.useState)(!1))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(t,2)||function(e,t){if(e){if("string"==typeof e)return nz(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return nz(e,2)}}(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),c=l[0],u=l[1],s=(0,p.useRef)(null),d=(0,p.useRef)(!1);return(0,p.useEffect)(function(){if(!o){var e=s.current;s.current=r,null!==e&&!e&&r&&u(!0)}},[r,o]),(0,p.useEffect)(function(){!o&&!d.current&&a&&r&&(d.current=!0,u(!0))},[a,r,o]),{isOpen:c,open:(0,p.useCallback)(function(){o||u(!0)},[o]),close:(0,p.useCallback)(function(){return u(!1)},[]),recipeTitlesForCarryOver:n,firstRecipeThumbnailUrl:i}},nF=r(834224),nH=function(){var e=(0,ny.py)({runUsingStatsig:!0}),t=e.decide,r=e.isReady,o=(0,ng.R)({runUsingStatsig:!0}),n=o.id,i=o.attributes,a=o.isReady;if(!r||!a)return!1;var l=t({experimentKey:nF.yW,experimentationUserId:n,experimentationUserAttributes:i}),c=l.variationKey,u=l.parameters;return"Test"===c||(null==u?void 0:u.isEnabled)===!0},nq=r(591953),nY=r(209628),nW=r(432761),nK=r(672290),nG=r(40491),nJ=r(826902),n$=r(316308),nQ=function(e){var t=e.onDismiss,r=(0,F.ZP)("cookbook").translate,o=(0,nG.O)({userAction:"cookbookAppDownloadBannerAppInstall",gaEventLabel:"cookbookAppDownloadBannerAppInstall"}).handleDownloadClick,n=(0,nJ.qJ)(),i=n.trackBannerImpression,a=n.trackAppStoreBannerClick,l=n.trackCloseAppStoreIconClick;return(0,p.useEffect)(function(){i({impressionType:n$.w7.NavigatedTo,uiComponentName:nJ.E7,uiComponentLabel:"top"})},[i]),(0,s.BX)(y.xu,{"data-test-id":"cookbook-app-download-banner",display:"flex",alignItems:"center",justifyContent:"space-between",backgroundColor:"global.hellofresh.action-black.900",px:["global.sm-1","global.md-1","global.lg-1"],py:"global.sm-1",children:[(0,s.BX)(y.xu,{display:"flex",alignItems:"center",gap:"global.sm-2",children:[(0,s.tZ)(y.xu,{display:["none","flex"],alignItems:"center",justifyContent:"center",borderRadius:"border-radius-lg",width:"36px",height:"36px",flexShrink:"0",backgroundColor:"global.mint.500",children:(0,s.tZ)(y.JO,{icon:(0,s.tZ)(nK.default,{}),color:"global.white"})}),(0,s.BX)(y.xu,{display:"flex",flexDirection:"column",mr:"global.sm-1",children:[(0,s.tZ)(y.xv,{color:"global.white",type:"body-sm-bold",children:r("cookbook.app-download-banner.title",{defaultValue:"Get the HelloFresh app to keep cooking on the go."})}),(0,s.tZ)(y.xu,{display:["none","block"],children:(0,s.tZ)(y.xv,{color:"neutral.400",type:"body-sm-regular",children:r("cookbook.app-download-banner.subtitle",{defaultValue:"Browse all your saves, organize collections, auto-build your grocery list."})})})]})]}),(0,s.BX)(y.xu,{display:"flex",alignItems:"center",gap:["zero","global.md-1"],flexShrink:"0",children:[(0,s.tZ)(y.xu,{backgroundColor:"global.white",borderRadius:"border-radius-md",children:(0,s.tZ)(y.zx.Tertiary,{onClick:function(){a({uiComponentName:nJ.E7,uiComponentLabel:"DownloadFree"}),o()}
1,size:"sm",width:"fit-content","data-test-id":"cookbook-app-download-banner-cta",children:r("cookbook.app-download-banner.cta",{defaultValue:"Download free"})})}),(0,s.tZ)(y.xu,{p:"zero",children:(0,s.tZ)(y.zx.Tertiary,{as:"button",onClick:function(){l({uiComponentName:nJ.E7,uiComponentLabel:"dismiss"}),t()},"aria-label":"Dismiss","data-test-id":"cookbook-app-download-banner-dismiss",size:"sm",children:(0,s.tZ)(y.JO,{color:"global.white",icon:(0,s.tZ)(nW.Z,{})})})})]})]})};function n0(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}var n1="cookbook-app-download-banner",n2=function(){var e,t=function(e){if(Array.isArray(e))return e}(e=(0,nM.Z)("hf_cookbook-app-banner-dismissed",{defaultValue:"false",expiresIn:7776e3}))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,2)||function(e,t){if(e){if("string"==typeof e)return n0(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return n0(e,2)}}(e,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],o=t[1],n=(0,g.Z)("cookbook-app-download-banner").isEnabled,i="true"!==r&&n;(0,p.useEffect)(function(){if(!i){(0,nq.Oi)({id:n1});return}return(0,nq.qG)(nY.Z.create((0,s.tZ)(nQ,{onDismiss:function(){o("true"),(0,nq.Oi)({id:n1})}}),{id:n1})),function(){(0,nq.Oi)({id:n1})}},[i,o])};function n4(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function n3(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return n4(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return n4(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var n8=function(){var e,t,r,o,n,i,a,l=n3((0,p.useState)(!1),2),c=l[0],u=l[1],d=n3((0,p.useState)(!1),2),f=d[0],b=d[1],m=n3((0,p.useState)(),2),h=m[0],v=m[1],k=n3((0,p.useState)(!1),2),w=k[0],O=k[1],x=(0,p.useRef)(null);(0,p.useEffect)(function(){return u(!0)},[]);var S=ex(),C=S.recipes,j=S.isLoaded,P=S.importing,_=S.importError,Z=S.validationError,I=S.clearValidationError,E=S.importErrorEvent,R=S.isAtLimit,A=S.isCustomer,T=S.importRecipe,D=S.importRecipeFromImage,L=S.importRecipeFromText,B=S.removeRecipe,M=S.hasImportedRecipes,V=S.recipeTitles,U=S.firstRecipeThumbnailUrl,N=S.arrivedAtCap,z=S.hasMore,X=S.isLoadingMore,H=S.loadMore,q=(0,g.Z)(nF.qJ).isEnabled,Y=(0,g.Z)(nF.iu).isEnabled;tg(E,Y);var W=nH(),K=eB().status,G=nX({isAtLimit:R,isCustomer:A,recipeTitles:V,firstRecipeThumbnailUrl:U,atCapArrival:N}),J=(0,p.useCallback)(function(e){return R&&!A?(G.open(),!0):T(e)},[R,A,G,T]),$=(0,p.useCallback)(function(e){return R&&!A?(G.open(),!0):D(e)},[R,A,G,D]),Q=(0,p.useCallback)(function(e){return R&&!A?(G.open(),!0):L(e)},[R,A,G,L]),ee=(0,p.useCallback)(function(){O(!1),I()},[I]),et=(0,p.useCallback)(function(e){J(e)&&ee()},[J,ee]),er=(0,p.useCallback)(function(e){$(e)&&ee()},[$,ee]),eo=(0,p.useCallback)(function(e){Q(e)&&ee()},[Q,ee]),en=(0,p.useCallback)(function(){if(Y){O(!0);return}var e=x.current;e&&(e.scrollIntoView({behavior:"smooth",block:"center"}),e.focus({preventScroll:!0}))},[Y,x]),ei=(0,F.ZP)("cookbook").translateRaw;n2();var ea=(e=C.length,t=(0,F.ZP)("cookbook").translateRaw,n=(o=function(e){if(Array.isArray(e))return e}(r=(0,p.useState)(""))||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),2!==i.length);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(r,2)||function(e,t){if(e){if("string"==typeof e)return eS(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);
1if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return eS(e,2)}}(r,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0],i=o[1],a=(0,p.useRef)(0),(0,p.useEffect)(function(){if(c){var r={count:String(e),limit:String(3)};e>a.current?i(t("cookbook.import.status.recipe_imported",ej(eC({},r),{defaultValue:"Recipe imported. ".concat(e," of ").concat(3," saved.")}))):e<a.current&&i(t("cookbook.import.status.recipe_removed",ej(eC({},r),{defaultValue:"Recipe removed. ".concat(e," of ").concat(3," saved.")}))),a.current=e}},[e,c,t]),n),el=C.length>0,ec=C.filter(function(e){return"creator"!==e.sourcePlatform&&"hellofresh"!==e.sourcePlatform}).length,eu=W&&c&&j&&!P&&!M&&el&&"empty"!==K&&"error"!==K,es=W&&c&&j&&!P&&M&&ec<5,ep=c&&j&&!M&&!P&&!eu&&!es&&q&&A,ed=(0,p.useCallback)(function(e){v(e),b(!0)},[]),ef=oP().trackNbaActionPress,eb=(0,p.useCallback)(function(e){var t;if(ef(e),"learn"===e){ed("find");return}if(Y){O(!0);return}null===(t=x.current)||void 0===t||t.focus()},[ef,ed,Y]);return(0,s.BX)(s.HY,{children:[Y&&(0,s.tZ)(tf,{}),(0,s.BX)(y.xu,{maxWidth:["100%","100%","1144px"],mx:"auto",px:["global.sm-2","global.md-1","global.none"],py:["global.md-2","global.lg-1"],children:[(0,s.BX)(y.xu,{mb:"global.md-2",display:"flex",flexDirection:"row",alignItems:"flex-start",justifyContent:"space-between",gap:"global.sm-1",children:[(0,s.BX)(y.xu,{children:[(0,s.tZ)(y.xv,{as:"h1",mb:"global.xxs","data-test-id":"cookbook-import-heading",children:ei("cookbook.import.heading",{defaultValue:"My cookbook"})}),(0,s.tZ)(y.xv,{type:"body-md-regular",color:"neutral.500",children:A?ei("cookbook.import.subheading_customer",{limit:String(3),defaultValue:"Save recipes from any website and organize them into collections. Get the app for grocery lists and more."}):C.length>0?ei("cookbook.import.subheading_with_count",{count:String(C.length),limit:String(3),defaultValue:"".concat(C.length," of ").concat(3," saved — sign up to keep saving")}):ei("cookbook.import.subheading",{limit:String(3),defaultValue:"Save recipes from any website. Save ".concat(3," for free — sign up for unlimited.")})})]}),Y&&(0,s.tZ)(e4,{onClick:function(){return O(!0)}})]}),c&&!A&&(0,s.tZ)(y.xu,{mb:"global.md-2",children:(0,s.tZ)(tG,{})}),!Y&&(0,s.tZ)(y.xu,{mb:"global.md-2",children:(0,s.tZ)(e1,{ref:x,onImport:J,onImageImport:$,isLoading:P,isDisabled:!1,error:_})}),eu&&(0,s.tZ)(ov,{onSaveRecipePress:function(){return ed()},onLearnHowPress:function(){return ed()}}),es&&(0,s.tZ)(y.xu,{mb:"global.md-2",display:["block","block","none"],children:(0,s.tZ)(oL,{onActionPress:eb})}),(0,s.tZ)("div",{"aria-live":"polite",role:"status",style:{position:"absolute",width:"1px",height:"1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap"},children:ea}),ep?(0,s.tZ)(y.xu,{mb:"global.md-2",children:(0,s.tZ)(tH,{onCtaClick:function(){return ed()}})}):c&&j&&!el&&!P&&!eu&&!es&&(0,s.tZ)(tv,{}),c&&(el||P||ep)&&(0,s.tZ)(rv,{recipes:C,isCustomer:A,showSkeleton:P,recipeLimit:3,hasMore:z,isLoadingMore:X,onLoadMore:H,onRemove:B,onEmptySlotClick:en,nextBestAction:es?(0,s.tZ)(oL,{onActionPress:eb}):null})]}),c&&(0,s.tZ)(r2,{isCustomer:A,onAtLimit:G.open}),!ep&&(0,s.tZ)(nm.Z,{maxWidth:"1144px"}),(0,s.tZ)(nN,{onDismiss:function(){},onGetStarted:function(){return ed()}}),(0,s.tZ)(nb,{isOpen:f,onClose:function(){return b(!1)},initialScreen:h}),Y&&(0,s.tZ)(ts,{isOpen:w,onClose:ee,onImport:et,onImageImport:er,onTextImport:eo,isLoading:P,isDisabled:!1,error:Z,urlInputRef:x}),!A&&(0,s.tZ)(nh,{isOpen:G.isOpen,onClose:G.close,recipeTitles:G.recipeTitlesForCarryOver,firstRecipeThumbnailUrl:G.firstRecipeThumbnailUrl})]})},n5=r(645238),n6=r(277265),n7=function(){var e=(0,n5.r)(),t=e.isEnabled,r=e.isReady,o=(0,b.t)();return(0,el.Vq)(n6.q.Cookbook),(0,p.useEffect)(function(){r&&!t&&o.replace("/cookbook")},[r,t,o]),(0,s.BX)(s.HY,{children:[(0,s.tZ)(f(),{children:(0,s.tZ)("meta",{name:"robots",content:"noindex,nofollow"},"robots")}),(0,s.tZ)(h.Z,{}),r&&t&&(0,s.tZ)(n8,{})]})};n7.customLayout=m.ZP,n7.provideCustomLayoutProps=function(){return{}};var n9=!0,ie=n7},834224:function(e,t,r){"use strict";r.d(t,{Nz:function(){return i},hy:function(){return n},iu:function(){return l},qJ:function(){return a},rX:function(){return o},yW:function(){return c}});var o="cookbook_anonymous_web_import_enabled",n="cookbook_web_preview_enabled",i="c
1ookbook_import_unified_recipe_view",a="cookbook_web_import_tutorial",l="cookbook_import_dialog",c="cookbook_empty_state_redesign_web"},40491:function(e,t,r){"use strict";r.d(t,{O:function(){return p}});var o=r(827378),n=r(190341),i=r(887824);function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=Array(t);r<t;r++)o[r]=e[r];return o}function l(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,o,n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){l=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw o}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return a(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return a(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var c="7bdjd1g",u="hellofresh://cookbook?forceVideo=true",s=function(e,t){return"https://app.adjust.com/".concat(e,"?deep_link=").concat(encodeURIComponent(t))},p=function(e){var t=e.userAction,r=e.gaEventLabel,a=e.deepLinkParams,p=(0,n.G)().userAgent,d=(0,i.Z)().push,f=a?"".concat(u,"&").concat(new URLSearchParams(a)):u,b=l((0,o.useState)(s(c,f)),2),m=b[0],h=b[1],y=l((0,o.useState)("iOS"),2),g=y[0],v=y[1];return(0,o.useEffect)(function(){var e,t=/Android/i.test((null==p?void 0:null===(e=p.getResult())||void 0===e?void 0:e.ua)||"");h(s(t?"qfxjg4i":c,f)),v(t?"Android":"iOS")},[p,f]),{handleDownloadClick:function(){d({event:"gaEventTrigger",event_name:"Navigation_PageCTAclick",user_action:t,gaEventCategory:"navigation",gaEventAction:"CTA",gaEventLabel:r,mobileDevice:g}),window.open(m,"_blank","noopener,noreferrer")}}}},645238:function(e,t,r){"use strict";r.d(t,{r:function(){return l}});var o=r(743267),n=r(24165),i=r(463171),a=r(834224),l=function(){var e=(0,o.fB)((0,n.Z)())?a.hy:a.rX;return(0,i.Z)(e)}},833190:function(e,t,r){"use strict";r.d(t,{dn:function(){return n},vk:function(){return i}});var o=r(267230),n=function(e){switch(e){case"hellofresh":return o.m4.HelloFresh;case"creator":return o.m4.Creator;case"import":return o.m4.External;default:return o.m4.Unknown}},i=function(e){return n("hellofresh"===e||"creator"===e?e:"import")}},428637:function(e,t,r){"use strict";var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.Z=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);
1return(0,o.BX)("svg",i(n(i(n({width:"1rem",height:"1rem",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M13.667 4.06 5.36 12.37 2 9.01l1.06-1.06 2.299 2.298L12.607 3l1.06 1.06Z",fill:"currentColor"})]}))}},645904:function(e,t,r){"use strict";var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.Z=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);
1return(0,o.BX)("svg",i(n(i(n({width:"1rem",height:"1rem",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.BX)("g",{clipPath:"url(#instagram_16_svg__a)",children:[(0,o.tZ)("path",{d:"M4.687.055c-.851.04-1.433.177-1.94.376-.527.205-.973.48-1.416.925a3.92 3.92 0 0 0-.92 1.419c-.197.509-.33 1.09-.368 1.942C.005 5.571-.003 5.843 0 8.015c.004 2.172.014 2.445.054 3.299.041.85.177 1.432.376 1.94.205.526.48.972.925 1.415.446.444.892.716 1.42.92.508.197 1.09.331 1.941.368.854.038 1.126.046 3.298.042 2.173-.004 2.445-.014 3.298-.054.852-.04 1.433-.177 1.941-.376.526-.206.972-.48 1.415-.925.444-.445.716-.892.92-1.419.197-.509.331-1.09.368-1.942.037-.853.046-1.126.042-3.298-.004-2.173-.014-2.445-.054-3.298-.04-.852-.177-1.433-.376-1.941a3.924 3.924 0 0 0-.925-1.415 3.915 3.915 0 0 0-1.419-.92c-.509-.197-1.09-.331-1.942-.368-.853-.038-1.126-.046-3.298-.042C5.812.005 5.54.014 4.687.055Zm.093 14.462c-.78-.034-1.203-.163-1.486-.272a2.495 2.495 0 0 1-.92-.596 2.487 2.487 0 0 1-.6-.919c-.11-.282-.242-.705-.279-1.485-.04-.843-.049-1.096-.053-3.233-.004-2.135.004-2.388.04-3.232.034-.78.165-1.204.273-1.486.145-.374.317-.64.597-.92.28-.282.545-.455.919-.6.282-.111.705-.242 1.484-.279.844-.04 1.097-.048 3.232-.053 2.136-.004 2.39.004 3.233.04.78.035 1.204.164 1.485.273.374.145.641.317.922.597.28.28.454.545.6.919.11.281.241.705.278 1.484.04.844.049 1.097.053 3.232.004 2.136-.004 2.39-.04 3.233-.035.78-.164 1.204-.273 1.486-.145.374-.317.64-.597.921-.28.28-.545.454-.919.6-.281.11-.705.241-1.484.278-.844.04-1.096.049-3.233.053-2.135.004-2.388-.004-3.232-.04Zm6.522-10.793a.96.96 0 1 0 1.92-.005.96.96 0 0 0-1.92.005Zm-7.41 4.284a4.107 4.107 0 1 0 8.215-.016 4.107 4.107 0 0 0-8.215.016Zm1.441-.003a2.667 2.667 0 1 1 5.334-.01 2.667 2.667 0 0 1-5.334.01Z",fill:"url(#instagram_16_svg__b)"}),(0,o.tZ)("path",{d:"M4.687.055c-.851.04-1.433.177-1.94.376-.527.205-.973.48-1.416.925a3.92 3.92 0 0 0-.92 1.419c-.197.509-.33 1.09-.368 1.942C.005 5.571-.003 5.843 0 8.015c.004 2.172.014 2.445.054 3.299.041.85.177 1.432.376 1.94.205.526.48.972.925 1.415.446.444.892.716 1.42.92.508.197 1.09.331 1.941.368.854.038 1.126.046 3.298.042 2.173-.004 2.445-.014 3.298-.054.852-.04 1.433-.177 1.941-.376.526-.206.972-.48 1.415-.925.444-.445.716-.892.92-1.419.197-.509.331-1.09.368-1.942.037-.853.046-1.126.042-3.298-.004-2.173-.014-2.445-.054-3.298-.04-.852-.177-1.433-.376-1.941a3.924 3.924 0 0 0-.925-1.415 3.915 3.915 0 0 0-1.419-.92c-.509-.197-1.09-.331-1.942-.368-.853-.038-1.126-.046-3.298-.042C5.812.005 5.54.014 4.687.055Zm.093 14.462c-.78-.034-1.203-.163-1.486-.272a2.495 2.495 0 0 1-.92-.596 2.487 2.487 0 0 1-.6-.919c-.11-.282-.242-.705-.279-1.485-.04-.843-.049-1.096-.053-3.233-.004-2.135.004-2.388.04-3.232.034-.78.165-1.204.273-1.486.145-.374.317-.64.597-.92.28-.282.545-.455.919-.6.282-.111.705-.242 1.484-.279.844-.04 1.097-.048 3.232-.053 2.136-.004 2.39.004 3.233.04.78.035 1.204.164 1.485.273.374.145.641.317.922.597.28.28.454.545.6.919.11.281.241.705.278 1.484.04.844.049 1.097.053 3.232.004 2.136-.004 2.39-.04 3.233-.035.78-.164 1.204-.273 1.486-.145.374-.317.64-.597.921-.28.28-.545.454-.919.6-.281.11-.705.241-1.484.278-.844.04-1.096.049-3.233.053-2.135.004-2.388-.004-3.232-.04Zm6.522-10.793a.96.96 0 1 0 1.92-.005.96.96 0 0 0-1.92.005Zm-7.41 4.284a4.107 4.107 0 1 0 8.215-.016 4.107 4.107 0 0 0-8.215.016Zm1.441-.003a2.667 2.667 0 1 1 5.334-.01 2.667 2.667 0 0 1-5.334.01Z",fill:"url(#instagram_16_svg__c)"})]}),(0,o.BX)("defs",{children:[(0,o.BX)("radialGradient",{id:"instagram_16_svg__b",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(4.267 17.227) scale(23.7778)",children:[(0,o.tZ)("stop",{stopColor:"#FD5"}),(0,o.tZ)("stop",{offset:.1,stopColor:"#FD5"}),(0,o.tZ)("stop",{offset:.5,stopColor:"#FF543E"}),(0,o.tZ)("stop",{offset:1,stopColor:"#C837AB"})]}),(0,o.BX)("radialGradient",{id:"instagram_16_svg__c",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(6.827 .027) scale(15.04)",children:[(0,o.tZ)("stop",{stopColor:"#3771C8"}),(0,o.tZ)("stop",{offset:.128,stopColor:"#3771C8",stopOpacity:0})]}),(0,o.tZ)("clipPath",{id:"instagram_16_svg__a",children:(0,o.tZ)("path",{fill:"#fff",d:"M0 0h16v16H0z"})})]})]}))}},924759:function(e,t,r){"use strict";var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);
1"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.Z=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);
1return(0,o.BX)("svg",i(n(i(n({width:"1rem",height:"1rem",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M8 8c1.882 0 3.409-1.492 3.409-3.333 0-1.841-1.527-3.334-3.409-3.334-1.883 0-3.409 1.493-3.409 3.334C4.591 6.507 6.117 8 8 8ZM13.414 14.667c.904 0 1.622-.854 1.108-1.956-1.29-1.883-3.728-3.378-6.522-3.378s-5.232 1.495-6.522 3.378c-.514 1.102.204 1.956 1.108 1.956h10.828Z",fill:"currentColor"})]}))}},832706:function(e,t,r){"use strict";var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.Z=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);
1return(0,o.BX)("svg",i(n(i(n({width:"1rem",height:"1rem",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M6.819 6.57v-.39a3.287 3.287 0 0 0-.52-.04C4.233 6.14 2.5 7.77 2.5 9.792c0 1.327.658 2.46 1.657 3.132a3.742 3.742 0 0 1-1.128-2.703c0-2.017 1.726-3.646 3.79-3.65ZM8.01 2v7.86c0 1.03-.754 1.693-1.67 1.693-.305 0-.594-.07-.845-.199.319.32.822.63 1.373.63.917 0 1.67-.663 1.67-1.694V2.43h1.453A3.868 3.868 0 0 1 9.895 2H8.011Zm3.34 2.319a3.27 3.27 0 0 0 1.62.883V4.85a3.441 3.441 0 0 1-1.62-.531Z",fill:"#2DCCD3"}),(0,o.tZ)("path",{d:"M11.35 4.318c-.446-.451-.787-1.073-.926-1.889h-.432c.247.883.754 1.498 1.359 1.89Zm1.621.883V6.69c-.84 0-1.634-.157-2.334-.62.815.8 1.804 1.05 2.863 1.05V5.28a3.353 3.353 0 0 1-.53-.079Zm-7.475 6.153a1.666 1.666 0 0 1-.359-1.064c0-1.19.948-1.819 2.21-1.688V6.609c-.363-.03-.726-.04-1.02-.04H6.32v1.603c-1.263-.13-2.21.498-2.21 1.689 0 .696.362 1.224 1.387 1.493Zm4.613-1.623c0 2.51-1.956 3.84-3.8 3.84a3.85 3.85 0 0 1-2.152-.648A3.826 3.826 0 0 0 6.838 14c1.844 0 3.8-1.33 3.8-3.84V6.07a3.598 3.598 0 0 1-.53-.43v4.09Z",fill:"#F1204A"}),(0,o.tZ)("path",{d:"M6.31 13.571c1.843 0 3.799-1.33 3.799-3.84V5.64c.17.166.345.308.529.43.7.463 1.494.62 2.334.62V5.202a3.275 3.275 0 0 1-1.62-.883c-.605-.392-1.113-1.007-1.359-1.89H8.54v7.861c0 1.031-.753 1.693-1.67 1.693-.552 0-1.054-.31-1.373-.629-.525-.269-.888-.797-.888-1.493 0-1.19.947-1.819 2.21-1.689V6.61c-2.063.005-3.79 1.593-3.79 3.61 0 1.076.432 2.025 1.128 2.703a3.85 3.85 0 0 0 2.153.649Z",fill:"#000"})]}))}},706009:function(e,t,r){"use strict";var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.Z=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);
1return(0,o.BX)("svg",i(n(i(n({width:"1rem",height:"1rem",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M11.232 7.49 14.8 3.923a2 2 0 1 0-2.829-2.828L8.325 4.74l-4.05 1.186c-3.587 1.05-4.878 5.61-2.325 8.207 2.554 2.597 7.037 1.284 8.07-2.364l1.212-4.28Zm1.555-5.429a.7.7 0 0 1 .94-.045.606.606 0 0 1 .255.551.698.698 0 0 1-.205.485L9.967 6.86l-.99-.99 2.202-2.202a.399.399 0 0 0 .676.218l.85-.85a.399.399 0 0 0-.218-.676l.3-.3ZM4.659 7.283c-2.11.618-3.048 2.814-2.49 4.579.547-1.44 2.017-3.244 3.755-4.317l1.95-1.204-3.215.942Zm4.027 4.095c-.632 2.234-2.945 3.175-4.71 2.456 1.43-.524 3.261-2.047 4.341-3.856L9.774 7.54l-1.088 3.84Zm-5.55 1.612-.004-.011a.049.049 0 0 1 .003.01Zm.003-.179.054-.008c.294-.052.726-.22 1.244-.54A9.08 9.08 0 0 0 7.3 9.35l1.172-1.963-1.93 1.192c-1.18.729-2.237 1.863-2.864 2.912-.314.527-.48.966-.53 1.266l-.01.054Zm-.165.007-.01-.003.01.003Z",fill:"currentColor"})]}))}},126671:function(e,t,r){"use strict";var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.Z=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);
1return(0,o.BX)("svg",i(n(i(n({width:"1rem",height:"1rem",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M8.356 1.01a7 7 0 1 0-.712 13.98 7 7 0 0 0 .712-13.98ZM7.29 13.55a5.6 5.6 0 0 1-4.9-5.55c.003-.423.052-.843.147-1.254L5.89 10.1v.7a1.4 1.4 0 0 0 .594 1.143 1.829 1.829 0 0 1 .806 1.482v.126Zm4.83-1.778a1.39 1.39 0 0 0-1.33-.973h-.7V8.7a.7.7 0 0 0-.7-.7h-3.5a.7.7 0 0 1 0-1.4h.7a.7.7 0 0 0 .7-.7 1.4 1.4 0 0 1 1.4-1.4 1.4 1.4 0 0 0 1.4-1.4v-.287a5.588 5.588 0 0 1 2.03 8.96Z",fill:"currentColor"})]}))}},813445:function(e,t,r){"use strict";var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.Z=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);
1return(0,o.BX)("svg",i(n(i(n({width:"1rem",height:"1rem",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M14.703 4.564a1.759 1.759 0 0 0-1.237-1.262C12.382 3 7.995 3 7.995 3s-4.367 0-5.45.302a1.82 1.82 0 0 0-1.259 1.262C1 5.67 1 7.994 1 7.994s0 2.326.286 3.442a1.84 1.84 0 0 0 1.258 1.262C3.628 13 7.994 13 7.994 13s4.388 0 5.472-.302a1.776 1.776 0 0 0 1.237-1.262C15 10.32 15 7.995 15 7.995s0-2.325-.297-3.43Zm-8.099 5.58V5.856l3.63 2.138-3.63 2.148Z",fill:"#F03"})]}))}},35959:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"m13 18.333 6.666-6.666L21 13l-9 9-9-9 1.333-1.333L11 18.333V2h2v16.333Z",fill:"currentColor"})]}))}},10454:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M15 13a3 3 0 1 1-6 0 3 3 0 0 1 6 0Zm-2 0a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z",fill:"currentColor"}),(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M16 5H8L7 7H3v12h18V7h-4l-1-2ZM5 9h3.236l1-2h5.528l1 2H19v8H5V9Z",fill:"currentColor"})]}))}},953518:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);
1"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M6 2h12v2H6V2ZM4 6h16v2H4V6ZM22 10H2v12h20V10Z",fill:"currentColor"})]}))}},688985:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M6 2h12v2H6V2Z",fill:"currentColor"}),(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M2 10v12h20V10H2Zm18 2H4v8h16v-8Z",fill:"currentColor"}),(0,o.tZ)("path",{d:"M20 6H4v2h16V6Z",fill:"currentColor"})]}))}},672290:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r}
1)(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M11 6v8l-3-3-1.5 1.5L12 18l5.5-5.5L16 11l-3 3V6h-2Z",fill:"currentColor"}),(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Zm-2 0a8 8 0 1 1-16 0 8 8 0 0 1 16 0Z",fill:"currentColor"})]}))}},23287:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10Zm5.314-15-7.046 7.045-2.828-2.828L6 12.657l4.242 4.243 8.486-8.486L17.313 7Z",fill:"currentColor"})]}))}},127408:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M8 5v17h13V5H8Zm11 2h-9v13h9V7Z",fill:"currentColor"}),(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M3 19V2h13v3h-2V4H5v13h3v2H3Z",fill:"currentColor"})]}))}},972167:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);
1"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M10 13a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z",fill:"currentColor"}),(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M18 7h4v14H6v-4H2V3h16v4Zm-2-2H4v10h2V7h10V5Zm-3.92 14H9.92L11 17.458 12.08 19Zm6.088 0h-4.05l2.025-3.15L18.168 19ZM20 18.15l-3.857-6-3.072 4.78L11 13.97l-3 4.286V9h12v9.15Z",fill:"currentColor"})]}))}},793438:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M20.874 6.483a.886.886 0 0 1 .01.895 4.458 4.458 0 0 0-.726 2.892v-.002c.196 2.843-1.436 5.827-4.406 7.508-2.97 1.68-6.444 1.58-8.888.01v.001a4.783 4.783 0 0 0-2.941-.819.939.939 0 0 1-.797-.452.886.886 0 0 1-.009-.896 4.457 4.457 0 0 0 .724-2.891v.002C3.647 9.887 5.28 6.903 8.248 5.224c2.97-1.679 6.445-1.581 8.888-.01a4.785 4.785 0 0 0 2.942.82c.328.003.63.173.796.449Z",fill:"currentColor"})]}))}},420336:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r}
1)(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M14.388 15.827a7.123 7.123 0 1 1 1.44-1.439L20 18.561 18.561 20l-4.173-4.173Zm.822-5.704a5.088 5.088 0 1 1-10.175 0 5.088 5.088 0 0 1 10.175 0Z",fill:"currentColor"})]}))}},987167:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M13 3h-2v8H3v2h8v8h2v-8h8v-2h-8V3Z",fill:"currentColor"})]}))}},912449:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M6 22.5c-.55 0-1.02-.196-1.412-.587A1.926 1.926 0 0 1 4 20.5v-10c0-.55.196-1.02.588-1.412A1.926 1.926 0 0 1 6 8.5h3v2H6v10h12v-10h-3v-2h3c.55 0 1.02.196 1.413.588.391.391.587.862.587 1.412v10c0 .55-.196 1.02-.587 1.413A1.926 1.926 0 0 1 18 22.5H6Zm5-6V5.325l-1.6 1.6L8 5.5l4-4 4 4-1.4 1.425-1.6-1.6V16.5h-2Z",fill:"currentColor"})]}))}},128643:function(e,t,r){"use strict";r.r(t);var o=r(687800);function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},o=Object.keys(r);
1"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),o.forEach(function(t){var o;o=r[t],t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o})}return e}function i(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r.push.apply(r,o)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}r(827378),t.default=function(e){var t=e.title,r=e.titleId,a=function(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}(e,["title","titleId"]);return(0,o.BX)("svg",i(n(i(n({width:"1.5rem",height:"1.5rem",viewBox:"8 8 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t?"img":"graphics-symbol",color:"inherit","aria-hidden":!t},!t&&{focusable:!1}),{"aria-labelledby":r}),a),{children:[t?(0,o.tZ)("title",{id:r,children:t}):null,(0,o.tZ)("path",{d:"M18.4 24.816h-1.6v-2.389h1.6v2.389ZM20.8 24.816h-1.6v-2.389h1.6v2.389ZM23.2 24.816h-1.6v-2.389h1.6v2.389Z",fill:"currentColor"}),(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M26 28H14.4L12 20.04h16L26 28Zm-10.41-1.592h9.16l1.2-4.776h-11.8l1.44 4.776Z",fill:"currentColor"}),(0,o.tZ)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M25.51 16.855H28v4.777H12v-4.777h2.49L17.308 12l1.386.796-2.355 4.059h7.323l-2.355-4.06L22.692 12l2.817 4.855ZM13.6 20.039h12.8v-1.591H13.6v1.591Z",fill:"currentColor"})]}))}}},function(e){e.O(0,[47057,38579,12737,8139,14206,44355,274,24613,47710,63657,21835,87491,49178,57252,36060,74050,64944,56360,95851,7563,36152,29037,95325,45692,58351,89073,94414,53650,92888,49774,40179],function(){return e(e.s=722527)}),_N_E=e.O()}]);

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.