PageSourceSearch

https://hyperdart.com/hd/_next/static/chunks/nutrition-no-cache.0ceac7a0e4368c6b.js

js hyperdart.com collected 2026-10-02 01:33:29 UTC 60,533 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6942],{4196:(e,t,n)=>{n.r(t),n.d(t,{default:()=>t_});var a,r=n(14232),i=n(31675),o=n(82230),l=n(585),s=n(83766),c=n(82702),u=n(33578),p=n(79718),d=n(58347),m=n(4468),h=n(64716),f=n(69750),g=n(40690),y=n(41452),v=n(28464),b=n(54524),x=n(31303),k=n(50010),E=n(83808),A=n(14796),N=n(62112),w=n(31504),C=n(75731),D=n(49106);function S(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=Array(t);n<t;n++)a[n]=e[n];return a}function T(e,t,n,a,r,i,o){try{var l=e[i](o),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(a,r)}function P(e){return function(){var t=this,n=arguments;return new Promise(function(a,r){var i=e.apply(t,n);function o(e){T(i,a,r,o,l,"next",e)}function l(e){T(i,a,r,o,l,"throw",e)}o(void 0)})}}function V(e,t,n){return t=U(t),function(e,t){if(t&&("object"==typeof t||"function"==typeof t))return t;if(void 0!==t)throw TypeError("Derived constructors may only return object or undefined");if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e,q()?Reflect.construct(t,n||[],U(e).constructor):t.apply(e,n))}function I(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}function F(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var a=t[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,B(a.key),a)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function L(e,t,n){return(t=B(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function O(){return(O=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var a in n)({}).hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e}).apply(null,arguments)}function U(e){return(U=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function R(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&z(e,t)}function q(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(q=function(){return!!e})()}function W(){var e,t,n="function"==typeof Symbol?Symbol:{},a=n.iterator||"@@iterator",r=n.toStringTag||"@@toStringTag";function i(n,a,r,i){var s=Object.create((a&&a.prototype instanceof l?a:l).prototype);return j(s,"_invoke",function(n,a,r){var i,l,s,c=0,u=r||[],p=!1,d={p:0,n:0,v:e,a:m,f:m.bind(e,4),d:function(t,n){return i=t,l=0,s=e,d.n=n,o}};function m(n,a){for(l=n,s=a,t=0;!p&&c&&!r&&t<u.length;t++){var r,i=u[t],m=d.p,h=i[2];n>3?(r=h===a)&&(s=i[(l=i[4])?5:(l=3,3)],i[4]=i[5]=e):i[0]<=m&&((r=n<2&&m<i[1])?(l=0,d.v=a,d.n=i[1]):m<h&&(r=n<3||i[0]>a||a>h)&&(i[4]=n,i[5]=a,d.n=h,l=0))}if(r||n>1)return o;throw p=!0,a}return function(r,u,h){if(c>1)throw TypeError("Generator is already running");for(p&&1===u&&m(u,h),l=u,s=h;(t=l<2?e:s)||!p;){i||(l?l<3?(l>1&&(d.n=-1),m(l,s)):d.n=s:d.v=s);try{if(c=2,i){if(l||(r="next"),t=i[r]){if(!(t=t.call(i,s)))throw TypeError("iterator result is not an object");if(!t.done)return t;s=t.value,l<2&&(l=0)}else 1===l&&(t=i.return)&&t.call(i),l<2&&(s=TypeError("The iterator does not provide a '"+r+"' method"),l=1);i=e}else if((t=(p=d.n<0)?s:n.call(a,d))!==o)break}catch(t){i=e,l=1,s=t}finally{c=1}}return{value:t,done:p}}}(n,r,i),!0),s}var o={};function l(){}function s(){}function c(){}t=Object.getPrototypeOf;var u=c.prototype=l.prototype=Object.create([][a]?t(t([][a]())):(j(t={},a,function(){return this}),t));function p(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,j(e,r,"GeneratorFunction")),e.prototype=Object.create(u),e}return s.prototype=c,j(u,"constructor",c),j(c,"constructor",s),s.displayName="GeneratorFunction",j(c,r,"GeneratorFunction"),j(u),j(u,r,"Generator"),j(u,a,function(){return this}),j(u,"toString",function(){return"[object Generator]"}),(W=function(){return{w:i,m:p}})()}function j(e,t,n,a){var r=Object.defineProperty;try{r({},"",{})}catch(e){r=0}(j=function(e,t,n,a){function i(t,n){j(e,t,function(e){return this._invoke(t,n,e)})}t?r?r(e,t,{value:n,enumerable:!a,configurable:!a,writable:!a}):e[t]=n:(i("next",0),i("throw",1),i("return",2))})(e,t,n,a)}function z(e,t){return(z=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function B(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var a=n.call(e,t);if("object"!=typeof a)return a;throw TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==typeof t?t:t+""}var H=[{name:"Total lipid (fat)",dailyValue:65,Unit:"g"},{name:"Fatty acids, total saturated",dailyValue:20,Unit:"g"},{name:"Cholesterol",dailyValue:300,Unit:"mg"},{name:"Sodium, Na",dailyValue:2400,Unit:"mg"},{name:"Potassium",dailyValue:3500,Unit:"mg"},{name:"Carbohydrate, by difference",dailyValue:300,Unit:"g"},{name:"Fiber, total dietary",dailyValue:25,Unit:"g"},{name:"Protein",dailyValue:50,Unit:"g"},{name:"Vitamin A, IU",dailyValue:5e3,Unit:"IU"},{name:"Vitamin C, total ascorbic acid",dailyValue:60,Unit:"mg"},{name:"Calcium, Ca",dailyValue:1e3,Unit:"mg"},{name:"Iron, Fe",dailyValue:18,Unit:"mg"},{name:"Vitamin D",dailyValue:400,Unit:"IU"},{name:"Vitamin E",dailyValue:30,Unit:"IU"},{name:"Vitamin K",dailyValue:80,Unit:"\xb5g"},{name:"Thiamin",dailyValue:1.5,Unit:"mg"},{name:"Riboflavin",dailyValue:1.7,Unit:"mg "},{name:"Niacin",dailyValue:20,Unit:"mg"},{name:"\xadVitamin B6",dailyValue:2,Unit:"mg"},{name:"\xadFolate",dailyValue:400,Unit:"\xb5g"},{name:"\xadVitamin B12",dailyValue:6,Unit:"\xb5g"},{name:"Biotin",dailyValue:300,Unit:"\xb5g"},{name:"Pantothenic acid",dailyValue:10,Unit:"mg"},{name:"Phosphorus",dailyValue:1e3,Unit:"mg"},{name:"Iodine",dailyValue:150,Unit:"\xb5g"},{name:"Magnesium",dailyValue:400,Unit:"mg"},{name:"Zinc",dailyValue:15,Unit:"mg"},{name:"Selenium",dailyValue:70,Unit:"\xb5g"},{name:"Copper",dailyValue:2,Unit:"mg"},{name:"Manganese",dailyValue:2,Unit:"mg"},{name:"Chromium",dailyValue:120,Unit:"\xb5g"},{name:"Molybdenum",dailyValue:75,Unit:"\xb5g"},{name:"Chloride",dailyValue:3400,Unit:"mg"}],M="__APP_SERVER",_=function(e){for(var t=[],n=[],a={common:[],branded:[]},r=0;r<e.length;r++){var i={foodName:e[r].description.toLowerCase(),itemID:e[r].fdcid,brandName:e[r].brandOwner?e[r].brandOwner.toLowerCase():null,photo:{thumb:""}};"Branded"===e[r].dataType?n.push(i):"SR Legacy"===e[r].dataType&&t.push(i)}var o=n.filter(function(e,t,n){return t===n.findIndex(function(t){return e.foodName===t.foodName&&e.brandName===t.brandName})});return a.common=t,a.branded=o,a},$=function(e){return fetch(C.HDComponent.generateURL("".concat("/nutrition/searchFoodUSDA2","?text=").concat(e),M),{credentials:"include"}).then(function(e){return e.json()}).catch(function(e){console.log("Error from usda!!!!",e)}).then(function(e){return _(e)}).catch(function(e){console.log(e)})},G=function(e,t){return{name:t,value:e.amount?Math.round(e.amount):0,percentValue:X(e),unit:e.nutrient.unitName}},Z=function(e){for(var t={name:null,value:null,percentValue:null,unit:null},n={calcium:t,calories:t,carbohydrates:t,cholesterol:t,fat:t,fiber:t,iron:t,protein:t,saturatedFat:t,transFat:t,sodium:t,sugars:t,vitaminA:t,vitaminC:t,vitaminD:t,itemID:null,foodName:null,brandName:null,measures:[]},a=e.foodNutrients,r=0;r<a.length;r++)"Calcium, Ca"===a[r].nutrient.name?n.calcium=G(a[r],"Calcium "):"Fiber, total dietary"===a[r].nutrient.name?n.fiber=G(a[r],"Dietary Fiber "):"Iron, Fe"===a[r].nutrient.name?n.iron=G(a[r],"Iron "):"Vitamin A, IU"===a[r].nutrient.name?n.vitaminA=G(a[r],"Vitamin A "):"Vitamin C, total ascorbic acid"===a[r].nutrient.name?n.vitaminC=G(a[r],"Vitamin C "):"Fatty acids, total saturated"===a[r].nutrient.name?n.saturatedFat=G(a[r],"Saturated Fat "):"Protein"===a[r].nutrient.name?n.protein=G(a[r],"Protein "):"Total lipid (fat)"===a[r].nutrient.name?n.fat=G(a[r],"Total Fat "):"Carbohydrate, by difference"===a[r].nutrient.name?n.carbohydrates=G(a[r],"Total Carbohydrates "):"Sugars, total including NLEA"===a[r].nutrient.name?n.sugars=G(a[r],"Total Sugars "):"Sodium, Na"===a[r].nutrient.name?n.sodium=G(a[r],"Sodium "):"Cholesterol"===a[r].nutrient.name?n.cholesterol=G(a[r],"Cholesterol "):"Fatty acids, total trans"===a[r].nutrient.name?n.transFat=G(a[r],"Trans Fat "):"Energy"===a[r].nutrient.name&&"kcal"===a[r].nutrient.unitName&&(n.calories=G(a[r],"Calories "));n.foodName=e.description.toLowerCase(),n.brandName=e.brandOwner?e.brandOwner.toLowerCase():null,n.itemID=e.fdcId;var i=e.foodPortions;if(n.measures.push({serving:"Per 100 g",weight:100}),i){for(var o=0;o<i.length;o++)if(100!==i[o].gramWeight){var l={serving:i[o].amount+" "+i[o].modifier+" ("+i[o].gramWeight+"g)",weight:i[o].gramWeight};n.measures.push(l)}}return n},Q=function(e){return fetch(C.HDComponent.generateURL("".concat("/nutrition/nutritionDetail
1s","?text=").concat(e),M),{credentials:"include"}).then(function(e){return e.json()}).catch(function(e){console.log(e)}).then(function(e){return e.message&&e.message.includes("Unable to find gov.usda.bhnrc.ndl.food.entity.FoodEntity with id")?null:Z(e)}).catch(function(e){console.log("Error in details",e)})},J=function(e,t){for(var n=null,a=0;a<H.length;a++)H[a].name===e.nutrientName&&(n=Math.round(100*e.amount/H[a].dailyValue));return{name:t,value:e.amount?Math.round(e.amount):0,percentValue:n,unit:e.unitName.toLowerCase()}},K=function(e,t){var n={name:null,value:null,percentValue:null,unit:null},a={calcium:n,calories:n,carbohydrates:n,cholesterol:n,fat:n,fiber:n,iron:n,protein:n,saturatedFat:n,transFat:n,sodium:n,sugars:n,vitaminA:n,vitaminC:n,vitaminD:n,itemID:null,foodName:null,brandName:null,measures:[]};if(e.nutrition&&e.nutrition.length>0?e.nutrition.map(function(e){"Calcium, Ca"===e.nutrientName?a.calcium=J(e,"Calcium "):"Fiber, total dietary"===e.nutrientName?a.fiber=J(e,"Dietary Fiber "):"Iron, Fe"===e.nutrientName?a.iron=J(e,"Iron "):"Vitamin A, IU"===e.nutrientName?a.vitaminA=J(e,"Vitamin A "):"Vitamin C, total ascorbic acid"===e.nutrientName?a.vitaminC=J(e,"Vitamin C "):"Fatty acids, total saturated"===e.nutrientName?a.saturatedFat=J(e,"Saturated Fat "):"Protein"===e.nutrientName?a.protein=J(e,"Protein "):"Total lipid (fat)"===e.nutrientName?a.fat=J(e,"Total Fat "):"Carbohydrate, by difference"===e.nutrientName?a.carbohydrates=J(e,"Total Carbohydrates "):"Sugars, total including NLEA"===e.nutrientName?a.sugars=J(e,"Total Sugars "):"Sodium, Na"===e.nutrientName?a.sodium=J(e,"Sodium "):"Cholesterol"===e.nutrientName?a.cholesterol=J(e,"Cholesterol "):"Fatty acids, total trans"===e.nutrientName?a.transFat=J(e,"Trans Fat "):"Energy"===e.nutrientName&&(a.calories=J(e,"Calories "))}):a=null,null!=a){a.foodName=e.description,a.itemID=e.fdcID;var r=e.foodPortions;if(a.measures.push({serving:"Per 100 g",weight:100}),r){for(var i=0;i<r.length;i++)if(100!==r[i].gramWeight){var o={serving:r[i].amount+" "+r[i].modifier+" ("+r[i].gramWeight+"g)",weight:r[i].gramWeight};a.measures.push(o)}}}return a},X=function(e){for(var t=0;t<H.length;t++)if(H[t].name===e.nutrient.name)return Math.round(100*e.amount/H[t].dailyValue);return null},Y=(a=P(W().m(function e(t){var n;return W().w(function(e){for(;;)if(0===e.n)return n=C.HDComponent.generateURL("/nutrition/getnutritiondetails",M),e.a(2,fetch(n,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({foodItems:t})}).then(function(e){if(!e.ok)throw Error("Network response was not ok "+e.statusText);return e.json()}).then(function(e){if(e)return e;throw Error("Expected an array but got something else")}).catch(function(e){throw console.error("Fetch error: ",e),e}))},e)})),function(e){return a.apply(this,arguments)}),ee=function(e){function t(e){I(this,t),L(n=V(this,t,[e]),"detailsHandler",function(e){for(var t=[],a=n.state.data,r=["common","branded"],i=0;i<r.length;i++)for(var o=0;o<a[r[i]].length;o++)a[r[i]][o].itemID===e&&(o>=2&&o<a[r[i]].length-2?(t.push(a[r[i]][o+1]),t.push(a[r[i]][o+2]),t.push(a[r[i]][o-1]),t.push(a[r[i]][o-2])):o<2&&o+4<a[r[i]].length?(t.push(a[r[i]][o+1]),t.push(a[r[i]][o+2]),t.push(a[r[i]][o+3]),t.push(a[r[i]][o+4])):o>a[r[i]].length-2&&o-4>=0&&(t.push(a[r[i]][o-1]),t.push(a[r[i]][o-2]),t.push(a[r[i]][o-3]),t.push(a[r[i]][o-4])));n.props.history.push({pathname:"/nutrition/details/"+e,state:{related:t}})}),L(n,"noDataView",function(){var e=n.props.classes,t=[];t.push(r.createElement(l.A,{style:{marginBottom:"18px"},selected:!0,value:n.state.tabsValue,onChange:function(e,t){n.setState({tabsValue:t})},indicatorColor:"primary"},r.createElement(s.A,{key:0,className:e.tab,classes:{selected:e.selected},label:r.createElement(c.A,{variant:"h6"},"Common Foods")}),r.createElement(s.A,{key:1,className:e.tab,classes:{selected:e.selected},label:r.createElement(c.A,{variant:"h6"},"Branded Foods")})));for(var a=0;a<7;++a)t.push(r.createElement(u.A,{key:a+1,className:e.placeholderPaper},r.createElement(p.Ay,{key:a+1,className:e.placeholderItemContainer},r.createElement(d.A,{size:{xs:12}},r.createElement("div",{style:{height:"24px"},className:"animated-background"})))));return r.createElement("div",{style:{flex:1,overflow:"auto"}},r.createElement(m.A,{style:{paddingTop:0}},t))}),L(n,"createList",function(){var e=n.props.classes,t=0===n.state.data.common.length?r.createElement(c.A,{style:{width:"100%",height:"100%",textAlign:"center",marginTop:"40%"},variant:"h6"},"No Data Available"):r.createElement(m.A,null,n.state.data.common.map(function(t,a){return r.createElement(r.Fragment,null,r.createElement(p.Ay,{className:e.itemContainer,key:a,onClick:function(){return n.detailsHandler(t.itemID)}},r.createElement(h.A,{primary:r.createElement("span",{style:{fontWeight:"500",textTransform:"capitalize"}},t.foodName)})),r.createElement(f.A,{style:{width:"100%"}}))})),a=0===n.state.data.branded.length?r.createElement(c.A,{style:{width:"100%",height:"100%",textAlign:"center",marginTop:"40%"},variant:"h6"},"No Data Available"):r.createElement(m.A,null,n.state.data.branded.map(function(t,a){return r.createElement(r.Fragment,null,r.createElement(p.Ay,{className:e.itemContainer,key:a,onClick:function(){return n.detailsHandler(t.itemID)}},r.createElement(h.A,{style:{textTransform:"capitalize"},primary:r.createElement("span",{style:{fontWeight:"500",textTransform:"capitalize"}},t.foodName),secondary:t.brandName})),r.createElement(f.A,{style:{width:"100%"}}))}));function i(e){var t=e.value,n=e.index,a=e.data;return t!==n?null:a}return r.createElement(r.Fragment,null,r.createElement(l.A,{value:n.state.tabsValue,selected:!0,onChange:function(e,t){n.setState({tabsValue:t})},indicatorColor:"primary"},r.createElement(s.A,{className:e.tab,classes:{selected:e.selected},label:r.createElement(c.A,{variant:"h6"},"Common Foods")}),r.createElement(s.A,{className:e.tab,classes:{selected:e.selected},label:r.createElement(c.A,{variant:"h6"},"Branded Foods")})),r.createElement(i,{value:n.state.tabsValue,index:0,data:t}),r.createElement(i,{value:n.state.tabsValue,index:1,data:a}))});var n,a=e.match.params.query.toLowerCase().split(" ").map(function(e){return e.charAt(0).toUpperCase()+e.substring(1)}).join(" ");n.setHDState({starEnabled:!1,isBookmarked:!1,header:{primary:a}});var i=null,o=!0;return e.location.state&&e.location.state.data?(i=e.location.state.data,o=!1):n.getResults(),n.state={data:i,isLoading:o,tabsValue:0},n}return R(t,e),F(t,[{key:"getResults",value:function(){var e=this;
1$(this.props.match.params.query).then(function(t){null!=t&&e.setState({data:t,isLoading:!1,tabsValue:0===t.common.length?+(0!==t.branded.length):0},function(){return e.props.history.replace(e.props.location.pathname,{data:e.state.data})})})}},{key:"componentDidUpdate",value:function(e,t){e.match.params.query!==this.props.match.params.query&&this.getResults()}},{key:"render",value:function(){var e=this.props.classes,t=null;return t=!0===this.state.isLoading?this.noDataView():this.createList(),r.createElement(u.A,{className:e.outerPaper},t)}}])}(C.HDComponent),et=(0,o.A)(function(e){return{outerPaper:L(L({maxWidth:"720px",width:"100%"},e.breakpoints.down("md"),{width:"auto",marginLeft:e.spacing(1.5),marginRight:e.spacing(1.5)}),e.breakpoints.up("md"),{margin:C.componentMargin}),innerPaper:{boxShadow:"none"},placeholderPaper:{margin:"10px",padding:"16px",paddingTop:"8px",paddingBottom:"8px",borderRadius:e.shape.borderRadius},tab:{width:"50%",maxWidth:"360px",padding:"1%",textTransform:"none"},itemContainer:{margin:10,flex:1,borderRadius:e.shape.borderRadius,cursor:"pointer"},placeholderItemContainer:{textAlign:"center",padding:0,margin:"4px",overflow:"hidden"},placeholder:{width:40,height:40,borderRadius:"50%",margin:"0 auto"},placeholderText:{width:"100%",height:16,padding:2},selected:{color:e.palette.primary.main}}})(ee),en=function(e){function t(e){I(this,t),L(n=V(this,t,[e]),"nutritionDetailsHandler",function(){Q(n.props.match.params.itemID).then(function(e){n.setState({data:JSON.parse(JSON.stringify(e)),isLoading:!1},function(){var t=n.state.data.foodName.toLowerCase().split(" ").map(function(e){return e.charAt(0).toUpperCase()+e.substring(1)}).join(" ");n.setHDState({header:{primary:t}}),n.props.history.replace({pathname:n.props.location.pathname,state:{data:e,related:n.props.location.state?n.props.location.state.related:null}})})}).catch(function(e){console.log(e)})}),L(n,"gridMaker",function(e,t,a){var i=n.props.classes;return(("null%"===t||null===t)&&(t=""),1===a)?r.createElement(d.A,{container:!0},r.createElement(d.A,{size:{xs:9}},n.state.isLoading?r.createElement("div",null):r.createElement("span",{className:i.boldText},e)),r.createElement(d.A,{className:i.alignRight,size:{xs:3}},t)):r.createElement(d.A,{container:!0},r.createElement(d.A,{size:{xs:9}},r.createElement("span",null,e)),r.createElement(d.A,{className:i.alignRight,size:{xs:3}},t))}),L(n,"itemChange",function(e){var t=e.target.value,a=!1===n.state.quickPanel?n.props.location.state.related:n.state.relatedData,r=[];if(r.push({itemID:n.state.data.itemID,foodName:n.state.data.foodName,brandName:n.state.data.brandName}),a)for(var i=0;i<a.length;i++)a[i].itemID!=t&&r.push(a[i]);n.props.history.push({pathname:"/nutrition/details/"+t,state:{related:r}})}),L(n,"itemChange2",function(e){var t=e.target.value;n.setState({data:t})}),L(n,"servingChange",function(e){var t=e.target.value;n.setState({gramWeight:t})}),L(n,"noDataView",function(){var e=n.props.classes;return r.createElement(u.A,{elevation:1,className:e.card},r.createElement(g.A,{variant:"text",width:"55%",height:44}),r.createElement(g.A,{variant:"text",width:"80%",sx:{mb:1}}),r.createElement(y.A,{className:e.ruleThick}),r.createElement(g.A,{variant:"text",width:"20%"}),r.createElement(g.A,{variant:"text",width:"35%",height:48}),r.createElement(y.A,{className:e.ruleThick}),[0,1,2,3,4,5,6,7].map(function(t){return r.createElement(r.Fragment,{key:t},r.createElement(y.A,{className:e.ruleThin}),r.createElement(g.A,{variant:"text",sx:{my:.5}}))}),r.createElement(y.A,{className:e.ruleThick}),r.createElement(g.A,{variant:"text",width:"70%",sx:{mt:1}}))}),L(n,"labelCreate",function(e){var t=n.props.classes,a=(n.state.gramWeight/100).toFixed(4);if(null===e)return r.createElement(y.A,{className:t.loadingContainer},r.createElement(c.A,{variant:"body2",color:"text.secondary"},"No Data Available"));var i=!0===n.state.quickPanel,o=!1===n.state.quickPanel?n.props.location&&n.props.location.state&&n.props.location.state.related?n.props.location.state.related:null:n.state.relatedData,l=function(n){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=e[n];if(!o||!o.name)return null;var l="".concat((o.value*a).toFixed()).concat((o.unit||"").toLowerCase()),s=!1!==i.showPercent&&null!=o.percentValue?"".concat((o.percentValue*a).toFixed(),"%"):"",u=i.indent2?t.indent2:i.indent?t.indent:"";return r.createElement(y.A,{className:"".concat(t.nutrientRow," ").concat(u)},r.createElement(c.A,{variant:"body2",className:"".concat(t.nutrientName," ").concat(i.bold?t.bold:"")},o.name),r.createElement(c.A,{variant:"body2",className:t.nutrientValue},l),r.createElement(c.A,{variant:"body2",className:t.nutrientPct},s))},s=function(e,t,n){var a=l(e,n);return a?r.createElement(r.Fragment,{key:e},r.createElement(y.A,{className:t}),a):null},p=e.calories&&e.calories.name?(e.calories.value*a).toFixed():"—";return r.createElement(u.A,{elevation:1,className:t.card},r.createElement(c.A,{variant:"h5",className:t.title},"Nutrition Facts"),!1===n.state.quickPanel?r.createElement(v.A,{variant:"standard",className:t.foodSelect,value:e.itemID,onChange:function(e){n.itemChange(e)}},e.brandName?r.createElement(b.A,{className:t.menuItem,key:0,value:e.itemID},"".concat(e.brandName," ").concat(e.foodName)):r.createElement(b.A,{className:t.menuItem,key:0,value:e.itemID},e.foodName),o&&o.map(function(e,n){return e.brandName?r.createElement(b.A,{className:t.menuItem,key:n+1,value:e.itemID},"".concat(e.brandName," ").concat(e.foodName)):r.createElement(b.A,{className:t.menuItem,key:n+1,value:e.itemID},e.foodName)})):r.createElement(v.A,{variant:"standard",className:t.foodSelect,value:n.state.data,onChange:function(e){n.itemChange2(e)}},n.state.menuData.map(function(e,n){var a=e.data.foodName;return a.length>35&&(a=a.slice(0,35)+"..."),r.createElement(b.A,{className:t.menuItem,key:n,value:e.data},a)})),r.createElement(y.A,{className:t.ruleThin}
1),r.createElement(y.A,{className:t.servingRow},r.createElement(c.A,{variant:"body2",className:t.servingLabel},"Serving Size"),r.createElement(v.A,{variant:"standard",className:t.servingSelect,value:n.state.gramWeight,onChange:function(e){n.servingChange(e)}},e.measures.map(function(e,t){return r.createElement(b.A,{key:t,value:e.weight},e.serving)}))),r.createElement(y.A,{className:t.servingRow},r.createElement(c.A,{variant:"body2",className:t.servingLabel},"Servings Per Container"),r.createElement(c.A,{variant:"body2",className:t.bold},"1")),r.createElement(y.A,{className:t.ruleThick}),r.createElement(y.A,{className:t.caloriesBlock},r.createElement(y.A,null,r.createElement(c.A,{variant:"subtitle2",className:t.caloriesLabel},"Calories"),r.createElement(c.A,{variant:"h4",className:t.caloriesNumber},p)),e.fat&&e.fat.name&&r.createElement(y.A,{className:t.fromFat},r.createElement(c.A,{variant:"caption",className:t.fromFatLabel},"Calories from Fat"),r.createElement(c.A,{variant:"body1",className:t.fromFatValue},(9*e.fat.value*a).toFixed()))),r.createElement(y.A,{className:t.ruleThick}),r.createElement(c.A,{variant:"caption",className:t.pctHeader},"% Daily Value*"),r.createElement(y.A,{className:i?t.sectionClickable:void 0,onClick:i?function(){return n.props.getNutritionDetails(n.state.data.itemID)}:void 0},s("fat",t.ruleThin,{bold:!0}),s("saturatedFat",t.ruleThin,{indent:!0}),s("transFat",t.ruleThin,{indent:!0}),s("cholesterol",t.ruleThin,{bold:!0}),s("sodium",t.ruleThin,{bold:!0}),s("carbohydrates",t.ruleMed,{bold:!0}),s("fiber",t.ruleThin,{indent:!0}),s("sugars",t.ruleThin,{indent:!0}),s("protein",t.ruleMed,{bold:!0,showPercent:!1})),r.createElement(y.A,{className:t.ruleThick}),r.createElement(y.A,{className:i?t.sectionClickable:void 0,onClick:i?function(){return n.props.getNutritionDetails(n.state.data.itemID)}:void 0},["vitaminD","calcium","iron","vitaminA","vitaminC"].map(function(e){return s(e,t.ruleThin,{})})),r.createElement(y.A,{className:t.ruleThick}),r.createElement(c.A,{variant:"caption",className:t.footnote},!0===n.state.quickPanel&&("xs"===n.props.width||"sm"===n.props.width||n.props.sideBar)?"* % DV are based on a 2,000 calorie diet":"* The % Daily Value (DV) tells you how much a nutrient in a serving of food contributes to a daily diet. 2,000 calories a day is used for general nutrition advice."),!1===n.state.quickPanel&&r.createElement(c.A,{variant:"caption",className:t.attribution},"SOURCE: Data retrieved from Data.gov (https://www.data.gov/)"))}),n.setHDState({starEnabled:!1,isBookmarked:!1,header:{primary:"Nutritional Facts"}});var n,a=null,i=!0;if(n.props.quickPanel&&!0===n.props.quickPanel)a=e.quickPanelData,i=!1;else if(e.location&&e.location.state&&e.location.state.data){a=e.location.state.data,i=!1;var o=e.location.state.data.foodName.toLowerCase().split(" ").map(function(e){return e.charAt(0).toUpperCase()+e.substring(1)}).join(" ");n.setHDState({header:{primary:o}})}else n.nutritionDetailsHandler();return n.state={data:a,isLoading:i,gramWeight:100,menuData:n.props.quickPanel&&!0===n.props.quickPanel?n.props.menuData:null,quickPanel:!!n.props.quickPanel&&!0===n.props.quickPanel,relatedData:n.props.quickPanel&&!0===n.props.quickPanel?n.props.relatedData:null,queryId:n.props.quickPanel&&!0===n.props.quickPanel?n.props.quickPanelData.itemID:null},n}
1return R(t,e),F(t,[{key:"componentDidUpdate",value:function(e,t){var n=this;!1===this.state.quickPanel&&e.match.params.itemID!==this.props.match.params.itemID&&this.setState({data:null,isLoading:!0},function(){n.nutritionDetailsHandler()})}},{key:"render",value:function(){var e=this.props.classes;return r.createElement("div",{className:e.content},this.state.isLoading?this.noDataView():this.labelCreate(this.state.data))}}])}(C.HDComponent),ea=(0,o.A)(function(e){return{content:L(L({maxWidth:"720px",width:"100%",boxSizing:"border-box"},e.breakpoints.down("md"),{width:"auto",marginLeft:e.spacing(1.5),marginRight:e.spacing(1.5)}),e.breakpoints.up("md"),{marginTop:"5px"}),contentDisamb:{width:"auto",margin:"4px"},card:{width:"100%",boxSizing:"border-box",padding:e.spacing(2),border:"2px solid ".concat(e.palette.text.primary),borderRadius:e.shape.borderRadius,backgroundColor:e.palette.background.paper},title:{fontWeight:e.typography.fontWeightBold,lineHeight:1.05,color:e.palette.text.primary},foodSelect:{width:"100%",color:e.palette.text.primary,"& .MuiSelect-select":{paddingTop:e.spacing(.25),paddingBottom:e.spacing(.25),fontWeight:e.typography.fontWeightBold,textTransform:"capitalize",color:e.palette.text.primary},"& .MuiSvgIcon-root":{color:e.palette.text.secondary},"&:before":{borderBottomColor:e.palette.divider}},servingSelect:{color:e.palette.text.primary,"& .MuiSelect-select":{paddingTop:e.spacing(.25),paddingBottom:e.spacing(.25),fontWeight:e.typography.fontWeightBold,color:e.palette.text.primary},"& .MuiSvgIcon-root":{color:e.palette.text.secondary},"&:before":{borderBottomColor:e.palette.divider}},ruleThick:{borderTop:"8px solid ".concat(e.palette.text.primary),margin:"".concat(e.spacing(.75)," 0")},ruleMed:{borderTop:"4px solid ".concat(e.palette.text.primary),margin:"".concat(e.spacing(.5)," 0")},ruleThin:{borderTop:"1px solid ".concat(e.palette.divider)},servingRow:{display:"flex",justifyContent:"space-between",alignItems:"center",padding:"".concat(e.spacing(.25)," 0")},servingLabel:{color:e.palette.text.primary},caloriesBlock:{display:"flex",justifyContent:"space-between",alignItems:"flex-end",padding:"".concat(e.spacing(.5)," 0")},caloriesLabel:{fontWeight:e.typography.fontWeightBold,color:e.palette.text.primary},caloriesNumber:{fontWeight:e.typography.fontWeightBold,lineHeight:1,color:e.palette.text.primary},fromFat:{textAlign:"right"},fromFatLabel:{display:"block",color:e.palette.text.secondary},fromFatValue:{fontWeight:e.typography.fontWeightBold,color:e.palette.text.primary},pctHeader:{textAlign:"right",fontWeight:e.typography.fontWeightBold,color:e.palette.text.primary,padding:"".concat(e.spacing(.5)," 0")},nutrientRow:{display:"flex",alignItems:"baseline",justifyContent:"space-between",gap:e.spacing(1),padding:"".concat(e.spacing(.5)," 0")},nutrientName:{flex:1,color:e.palette.text.primary},nutrientValue:{fontWeight:e.typography.fontWeightBold,whiteSpace:"nowrap",color:e.palette.text.primary},nutrientPct:{minWidth:44,textAlign:"right",fontWeight:e.typography.fontWeightBold,color:e.palette.text.primary},bold:{fontWeight:e.typography.fontWeightBold},indent:{paddingLeft:e.spacing(2)},indent2:{paddingLeft:e.spacing(3.5)},sectionClickable:{cursor:"pointer",transition:"background-color 0.3s ease-in-out","&:hover":{backgroundColor:e.palette.action.hover}},menuItem:{textTransform:"capitalize"},footnote:{display:"block",color:e.palette.text.secondary,marginTop:e.spacing(1)},attribution:{display:"block",color:e.palette.text.secondary,marginTop:e.spacing(.5)},loadingContainer:{display:"flex",justifyContent:"center",alignItems:"center",height:"100%",minHeight:"100px"},boldText:{fontWeight:"bold"},alignRight:{textAlign:"right"},smallFont:{listStyle:"none",padding:"0px",fontWeight:"bold"},space:{marginBottom:"8px"},spaceDisamb:{marginBottom:"12px",display:"inline"}}})(function(e){var t=(0,D.A)(),n=(0,x.A)(t.breakpoints.only("xs")),a=(0,x.A)(t.breakpoints.only("sm"));return r.createElement(en,O({},e,{width:n?"xs":a?"sm":"md"}))}),er=function(e){function t(e){var n;return I(this,t),L(n=V(this,t,[e]),"searchHandler",function(){var e=n.state.textValue;n.props.history.push("/nutrition/search-results/"+e)}),L(n,"textHandler",function(e){n.setState({textValue:e.target.value})}),n.setHDState({starEnabled:!1,isBookmarked:!1,header:{primary:"Nutrition"}}),n.state={textValue:null},n}return R(t,e),F(t,[{key:"render",value:function(){var e=this,t=this.props.classes;return r.createElement(u.A,{className:t.outerPaper},r.createElement(c.A,{variant:"h6",className:t.heading},"Enter search text and click submit"),r.createElement(k.A,{className:t.textField,type:"text",placeholder:"search f
1ield",onChange:function(t){return e.textHandler(t)}}),r.createElement(E.A,{className:t.submitButton,onClick:function(t){return e.searchHandler(t)}},"Submit Query"))}}])}(C.HDComponent),ei=(0,o.A)(function(e){return{outerPaper:L(L({maxWidth:"720px",width:"100%"},e.breakpoints.down("md"),{width:"auto",marginLeft:e.spacing(1.5),marginRight:e.spacing(1.5)}),e.breakpoints.up("md"),{margin:C.componentMargin}),heading:{paddingTop:"10%",paddingLeft:"3%"},textField:{padding:"2px",margin:e.spacing(1.25)},submitButton:{color:e.palette.primary.contrastText,backgroundColor:e.palette.primary.main,margin:e.spacing(1.25),"&:hover":{backgroundColor:e.palette.primary.dark}}}})(er),eo=function(e){function t(e){I(this,t),L(n=V(this,t,[e]),"quickPanelData",function(e){fetch(C.HDComponent.generateURL("/nutrition/results"+"?id=".concat(e),M),{credentials:"include"}).then(function(e){return e.json()}).then(function(e){if(void 0==e||e.err)return"error";var t=[];return e.map(function(e){var n=K(e);t.push({data:n,relatedData:[]})}),t}).catch(function(e){console.log("[ServiceClass] getTemplateAPI error",e)}).then(function(e){e.splice(5);var t=e[0];void 0!==t&&null!==t.data&&"error"!==t&&n.setState({data:t.data,isLoading:!1,relatedData:t.relatedData,menuData:e},function(){null!==n.props.componentLoaded&&n.props.componentLoaded()})}).catch(function(e){return console.log("[QuickPanel] quickPanelData error:",e)})}),L(n,"getCalories",function(){var e={},t=n.state.nutrientQuery.toUpperCase();return Object.keys(n.state.data).forEach(function(a){-1!==t.indexOf(a.toUpperCase())&&(e=n.state.data[a])}),e.name||(e=n.state.data.calories),e.name+" : "+e.value+" "+e.unit});var n,a=n.props.searchData&&n.props.searchData.keyword&&n.props.searchData.keyword.length>0&&n.props.searchData.keyword[0]?n.props.searchData.keyword[0].word:"",r=n.props.searchData&&n.props.searchData.entities.length>0&&n.props.searchData.entities[0]?n.props.searchData.entities[0].word:"",i="";return 1===(i=n.props.searchData&&n.props.searchData.entities.length>0?n.props.searchData.entities[0].sourceID:"").length?i="00"+i:2===i.length&&(i="0"+i),n.state={query:i,nutrientQuery:a,queryName:r,data:[],relatedData:[],isLoading:!0},n}
1return R(t,e),F(t,[{key:"componentDidMount",value:function(){""!==this.state.query&&""!==this.state.queryName&&this.quickPanelData(this.state.query)}},{key:"componentDidUpdate",value:function(e,t){var n=this;if(e.searchData!==this.props.searchData){var a="",r=this.props.searchData&&this.props.searchData.keyword&&this.props.searchData.keyword.length>0&&this.props.searchData.keyword[0]?this.props.searchData.keyword[0].word:"";1===(a=this.props.searchData&&this.props.searchData.entities.length>0?this.props.searchData.entities[0].sourceID:"").length?a="00"+a:2===a.length&&(a="0"+a),this.setState({query:a,nutrientQuery:r,data:[],relatedData:[],isLoading:!0},function(){""!==n.state.query&&n.quickPanelData(n.state.query)})}}},{key:"render",value:function(){var e=this,t=this.props,n=t.classes,a=t.theme;return!1===this.state.isLoading?r.createElement(r.Fragment,null,r.createElement("div",{className:n.divSource},r.createElement(c.A,{variant:"body2",className:n.source},"Result from USDA")),"card"===this.props.view?r.createElement(ea,{quickPanel:!0,sideBar:this.props.sideBar,quickPanelData:this.state.data,menuData:this.state.menuData,relatedData:this.state.relatedData,getNutritionDetails:this.props.getNutritionDetails}):r.createElement(A.A,{className:n.card,onClick:function(){e.props.getNutritionDetails(e.state.data.itemID)}}," ",r.createElement(d.A,{container:!0},r.createElement(d.A,{style:{marginRight:"20px"}},r.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",id:"Capa_1","enable-background":"new 0 0 512 512",height:"40",viewBox:"0 0 512 512",width:"40"},r.createElement("g",null,r.createElement("path",{d:"m198.543 49.443c4.629 0 8.382-3.752 8.382
1-8.382s-3.752-8.382-8.382-8.382-8.382 3.752-8.382 8.382 3.753 8.382 8.382 8.382z"}),r.createElement("path",{d:"m148.356 91.897h100.374c4.143 0 7.501-3.359 7.501-7.501 0-4.143-3.358-7.501-7.501-7.501h-100.374c-4.143 0-7.501 3.358-7.501 7.501 0 4.142 3.359 7.501 7.501 7.501z"}),r.createElement("path",{d:"m290.204 373.475v14.372c0 4.143 3.358 7.501 7.501 7.501s7.501-3.358 7.501-7.501v-14.372c0-4.143-3.358-7.501-7.501-7.501-4.142 0-7.501 3.358-7.501 7.501z"}),r.createElement("path",{d:"m439.787 373.475v14.372c0 4.143 3.358 7.501 7.501 7.501s7.501-3.358 7.501-7.501v-14.372c0-4.143-3.358-7.501-7.501-7.501s-7.501 3.358-7.501 7.501z"}),r.createElement("path",{d:"m386.56 382.491c-7.45 8.548-20.686 8.537-28.127 0-2.723-3.123-7.46-3.449-10.584-.727-3.123 2.722-3.448 7.46-.727 10.583 13.428 15.408 37.332 15.393 50.747 0 2.722-3.123 2.396-7.861-.727-10.583-3.122-2.722-7.86-2.398-10.582.727z"}),r.createElement("path",{d:"m116.841 214.804 42.085-21.583c3.686-1.89 5.142-6.411 3.252-10.098-1.89-3.686-6.411-5.143-10.098-3.251l-31.162 15.98v-9.305c0-4.143-3.358-7.501-7.501-7.501s-7.501 3.358-7.501 7.501v21.582c.001 5.643 5.986 9.206 10.925 6.675z"}),r.createElement("path",{d:"m194.762 204.839h66.23c4.143 0 7.501-3.358 7.501-7.501s-3.358-7.501-7.501-7.501h-66.23c-4.143 0-7.501 3.358-7.501 7.501s3.359 7.501 7.501 7.501z"}),r.createElement("path",{d:"m116.841 283.4 42.085-21.582c3.686-1.891 5.142-6.412 3.252-10.098s-6.411-5.143-10.098-3.252l-31.162 15.981v-9.306c0-4.143-3.358-7.501-7.501-7.501s-7.501 3.358-7.501 7.501v21.582c.001 5.615 5.957 9.223 10.925 6.675z"}),r.createElement("path",{d:"m194.762 273.436h66.23c4.143 0 7.501-3.359 7.501-7.501 0-4.143-3.358-7.501-7.501-7.501h-66.23c-4.143 0-7.501 3.358-7.501 7.501 0 4.142 3.359 7.501 7.501 7.501z"}),r.createElement("path",{d:"m113.418 352.822c3.241 0 1.017.078 45.508-22.409 3.686-1.89 5.142-6.411 3.252-10.097s-6.411-5.143-10.098-3.252l-31.162 15.98v-9.306c0-4.142-3.358-7.501-7.501-7.501s-7.501 3.359-7.501 7.501v21.583c.001 4.134 3.356 7.501 7.502 7.501z"}),r.createElement("path",{d:"m68.335 497.275h230.16c22.703 13.922 50.732 15.296 74.001 3.677 25.935 12.945 57.565 9.668 81.064-8.538 14.166-10.977 26.085-23.723 35.425-37.885 2.281-3.458 1.326-8.111-2.132-10.392s-8.111-1.326-10.392 2.132c-8.431 12.785-19.228 24.32-32.09 34.286-19.003 14.724-45.295 17.85-67.26 5.883-2.888-1.576-6.338-1.576-9.221-.004-.285.155-.569.308-.861.462-32.845 17.374-62.386-3.438-62.265-3.399-2.995-1.959-5.344-3.83-8.356-6.335-93.693-78.005-42.096-223.924 73.171-175.242 4.295 1.814 5.453-.51 17.978-4.491 83.151-26.425 128.777 52.297 101.763 123.746-1.465 3.875.488 8.204 4.363 9.669s8.204-.489 9.669-4.364c22.541-
159.615-.126-126.7-54.699-144.688 7.885-17.081 8.403-36.271 1.007-51.987-.743-1.579-2.014-2.85-3.593-3.593-15.154-7.132-32.858-6.947-48.98-.347v-101.965c0-37.681-30.656-68.336-68.336-68.336h-19.951c-4.676-12.025-16.368-20.574-30.025-20.574h-40.042c-4.319-18.294-20.783-31.775-40.189-31.775s-35.87 13.481-40.188 31.775h-40.043c-13.658 0-25.349 8.549-30.025 20.574h-19.953c-37.68 0-68.335 30.655-68.335 68.336v305.039c0 37.68 30.655 68.336 68.335 68.336zm309.109-212.254c-1.046.378-3.347 1.24-4.945 1.878-19.605-7.848-40.6-11.889-61.225-8.765-6.384-12.06-8.371-26.658-3.442-39.424 29.758-11.477 65.774 13.733 69.612 46.311zm59.718-46.31c4.663 12.073 3.363 26.634-3.46 39.496-13.189-1.977-27.168-1.173-41.721 2.396-1.504-9.358-5.21-18.563-10.063-26.177 15.856-17.215 38.491-22.179 55.244-15.715zm-55.077-114.811v110.351c-2.941 2.112-6.625 5.248-9.588 8.292-7.098-7.291-15.767-13.151-25.12-16.889v-97.36c0-12.339-10.039-22.378-22.377-22.378h-14.498c.311-1.794.482-3.634.482-5.515v-29.835h17.768c29.407 0 53.333 23.925 53.333 53.334zm-263.773-73.907h46.499c3.971 0 7.254-3.095 7.488-7.059.819-13.86 12.347-24.716 26.244-24.716s25.425 10.857 26.245 24.717c.234 3.963 3.517 7.058 7.488 7.058h46.498c9.508 0 17.207 7.776 17.207 17.207-.117 34.42 1.061 36.926-2.997 42.889-3.176 4.643-8.582 7.52-14.21 7.52-170.561-.034-161.262.195-163.915-.348-8.166-1.738-13.753-8.837-13.753-16.858.034-36.143-.105-33.417.169-35.48 1.12-8.414 8.323-14.93 17.037-14.93zm-103.31 73.907c0-29.408 23.925-53.334 53.333-53.334h17.768v29.835c0 1.881.171 3.722.482 5.515h-14.498c-12.339 0-22.377 10.039-22.377 22.378v90.106c0 4.143 3.358 7.501 7.501 7.501s7.501-3.358 7.501-7.501v-90.106c0-4.067 3.309-7.376 7.375-7.376h21.393c6.132 7.451 15.22 11.692 24.832 11.692 173.748-.018 162.605.446 168.542-1.027 6.547-1.681 12.4-5.377 16.752-10.665h21.393c4.066 0 7.375 3.309 7.375 7.376v93.282c-11.424-1.695-22.197-.146-31.402 3.727-2.346.986-4.38 1.827-5.638 4.501-7.005 14.892-7.283 33.894.977 51.936-23.234 7.823-40.676 24.263-51.315 45.288h-50.234c-4.143 0-7.501 3.358-7.501 7.501 0 4.142 3.358 7.501 7.501 7.501h44.035c-.124.372-.829 2.611-1.176 3.795v.001c-8.368 28.567-5.191 59.349 6.183 86.092h-171.717c-4.066 0-7.375-3.309-7.375-7.376v-176.137c0-4.143-3.358-7.501-7.501-7.501s-7.501 3.358-7.501 7.501v176.139c0 12.34 10.039 22.378 22.377 22.378h179.192c7.124 12.406 16.459 24.356 28.236 35.351h-211.18c-29.408 0-53.333-23.926-53.333-53.334z"})))),r.createElement(d.A,{size:{xs:!0}},r.createElement(c.A,{variant:"body1",className:n.text},this.state.data.foodName),r.createElement(c.A,{variant:"body1",className:n.textSecondary},this.getCalories()," Per 100 gm")))),r.createElement("div",{className:n.divSeeMore,onClick:function(){null!==e.props.loadMore&&e.props.loadMore()}},r.createElement(c.A,{variant:"caption",className:n.source},"See more in Nutrition"),r.createElement("svg",{focusable:"false",viewBox:"0 0 24 24",fill:a.palette.text.secondary,"aria-hidden":"true",style:{width:"15px",height:"15px"}},r.createElement("path",{d:"M15.5 5H11l5 7-5 7h4.5l5-7z"}),r.createElement("path",{d:"M8.5 5H4l5 7-5 7h4.5l5-7z"})))):null}}])}(C.HDComponent),el=(0,o.A)(function(e){return{card:{padding:"10px 10px 10px 10px",cursor:"pointer",margin:"0px 10px 10px 10px",borderRadius:e.shape.borderRadius,maxHeight:"80px",verticalAlign:"middle"},text:{color:e.palette.text.primary,marginTop:"0px !important",lineHeight:"1.3rem !important",textOverflow:"ellipsis",overflow:"hidden","-webkit-line-clamp":1,"-webkit-box-orient":"vertical",maxHeight:"1.5rem",display:"-webkit-box",textTransform:"capitalize"},textSecondary:{color:e.palette.text.secondary},source:{marginLeft:"8px",color:e.palette.text.secondary,fontWeight:"normal"},divSource:{display:"flex",marginBottom:"8px"},divSeeMore:{display:"flex",cursor:"pointer",alignItems:"center",marginTop:"5px"}}},{withTheme:!0})(eo);function es(){return(es=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e}).apply(this,arguments)}let ec=["children","options"],eu=["allowFullScreen","allowTransparency","autoComplete","autoF
1ocus","autoPlay","cellPadding","cellSpacing","charSet","classId","colSpan","contentEditable","contextMenu","crossOrigin","encType","formAction","formEncType","formMethod","formNoValidate","formTarget","frameBorder","hrefLang","inputMode","keyParams","keyType","marginHeight","marginWidth","maxLength","mediaGroup","minLength","noValidate","radioGroup","readOnly","rowSpan","spellCheck","srcDoc","srcLang","srcSet","tabIndex","useMap"].reduce((e,t)=>(e[t.toLowerCase()]=t,e),{class:"className",for:"htmlFor"}),ep={amp:"&",apos:"'",gt:">",lt:"<",nbsp:"\xa0",quot:"“"},ed=["style","script","pre"],em=["src","href","data","formAction","srcDoc","action"],eh=/([-A-Z0-9_:]+)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|(?:\{((?:\\.|{[^}]*?}|[^}])*)\})))?/gi,ef=/\n{2,}$/,eg=/^(\s*>[\s\S]*?)(?=\n\n|$)/,ey=/^ *> ?/gm,ev=/^(?:\[!([^\]]*)\]\n)?([\s\S]*)/,eb=/^ {2,}\n/,ex=/^(?:([-*_])( *\1){2,}) *(?:\n *)+\n/,ek=/^(?: {1,3})?(`{3,}|~{3,}) *(\S+)? *([^\n]*?)?\n([\s\S]*?)(?:\1\n?|$)/,eE=/^(?: {4}[^\n]+\n*)+(?:\n *)+\n?/,eA=/^(`+)((?:\\`|(?!\1)`|[^`])+)\1/,eN=/^(?:\n *)*\n/,ew=/\r\n?/g,eC=/^\[\^([^\]]+)](:(.*)((\n+ {4,}.*)|(\n(?!\[\^).+))*)/,eD=/^\[\^([^\]]+)]/,eS=/\f/g,eT=/^---[ \t]*\n(.|\n)*\n---[ \t]*\n/,eP=/^\s*?\[(x|\s)\]/,eV=/^ *(#{1,6}) *([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,eI=/^ *(#{1,6}) +([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,eF=/^([^\n]+)\n *(=|-)\2{2,} *\n/,eL=/^ *(?!<[a-z][^ >/]* ?\/>)<([a-z][^ >/]*) ?((?:[^>]*[^/])?)>\n?(\s*(?:<\1[^>]*?>[\s\S]*?<\/\1>|(?!<\1\b)[\s\S])*?)<\/\1>(?!<\/\1>)\n*/i,eO=/&([a-z0-9]+|#[0-9]{1,6}|#x[0-9a-fA-F]{1,6});/gi,eU=/^<!--[\s\S]*?(?:-->)/,eR=/^(data|aria|x)-[a-z_][a-z\d_.-]*$/,eq=/^ *<([a-z][a-z0-9:]*)(?:\s+((?:<.*?>|[^>])*))?\/?>(?!<\/\1>)(\s*\n)?/i,eW=/^\{.*\}$/,ej=/^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,ez=/^<([^ >]+[:@\/][^ >]+)>/,eB=/-([a-z])?/gi,eH=/^(\|.*)\n(?: *(\|? *[-:]+ *\|[-| :]*)\n((?:.*\|.*\n)*))?\n?/,eM=/^[^\n]+(?:  \n|\n{2,})/,e_=/^\[([^\]]*)\]:\s+<?([^\s>]+)>?\s*("([^"]*)")?/,e$=/^!\[([^\]]*)\] ?\[([^\]]*)\]/,eG=/^\[([^\]]*)\] ?\[([^\]]*)\]/,eZ=/(\n|^[-*]\s|^#|^ {2,}|^-{2,}|^>\s)/,eQ=/\t/g,eJ=/(^ *\||\| *$)/g,eK=/^ *:-+: *$/,eX=/^ *:-+ *$/,eY=/^ *-+: *$/,e1=e=>`(?=[\\s\\S]+?\\1${e?"\\1":""})`,e0="((?:\\[.*?\\][([].*?[)\\]]|<.*?>(?:.*?<.*?>)?|`.*?`|\\\\\\1|[\\s\\S])+?)",e3=RegExp(`^([*_])\\1${e1(1)}${e0}\\1\\1(?!\\1)`),e2=RegExp(`^([*_])${e1(0)}${e0}\\1(?!\\1)`),e5=RegExp(`^(==)${e1(0)}${e0}\\1`),e7=RegExp(`^(~~)${e1(0)}${e0}\\1`),e4=/^(:[a-zA-Z0-9-_]+:)/,e8=/^\\([^0-9A-Za-z\s])/,e6=/\\([^0-9A-Za-z\s])/g,e9=/^[\s\S](?:(?!  \n|[0-9]\.|http)[^=*_~\-\n:<`\\\[!])*/,te=/^\n+/,tt=/^([ \t]*)/,tn=/(?:^|\n)( *)$/,ta="(?:\\d+\\.)",tr="(?:[*+-])";function ti(e){return"( *)("+(1===e?ta:tr)+") +"}let to=ti(1),tl=ti(2);function ts(e){return RegExp("^"+(1===e?to:tl))}let tc=ts(1),tu=ts(2);function tp(e){return RegExp("^"+(1===e?to:tl)+"[^\\n]*(?:\\n(?!\\1"+(1===e?ta:tr)+" )[^\\n]*)*(\\n|$)","gm")}let td=tp(1),tm=tp(2);function th(e){let t=1===e?ta:tr;return RegExp("^( *)("+t+") [\\s\\S]+?(?:\\n{2,}(?! )(?!\\1"+t+" (?!"+t+" ))\\n*|\\s*\\n*$)")}let tf=th(1),tg=th(2);function ty(e,t){let n=1===t,a=n?tf:tg,r=n?td:tm,i=n?tc:tu;return{t:e=>i.test(e),o:tS(function(e,t){let n=tn.exec(t.prevCapture);return n&&(t.list||!t.inline&&!t.simple)?a.exec(e=n[1]+e):null}),i:1,u(e,t,a){let o=n?+e[2]:void 0,l=e[0].replace(ef,"\n").match(r),s=!1;return{items:l.map(function(e,n){let r,o=RegExp("^ {1,"+i.exec(e)[0].length+"}","gm"),c=e.replace(o,"").replace(i,""),u=n===l.length-1,p=-1!==c.indexOf("\n\n")||u&&s;s=p;let d=a.inline,m=a.list;a.list=!0,p?(a.inline=!1,r=tk(c)+"\n\n"):(a.inline=!0,r=tk(c));let h=t(r,a);return a.inline=d,a.list=m,h}),ordered:n,start:o}},l:(t,n,a)=>e(t.ordered?"ol":"ul",{key:a.key,start:"20"===t.type?t.start:void 0},t.items.map(function(t,r){return e("li",{key:r},n(t,a))}))}}let tv=RegExp("^\\[((?:\\[[^\\[\\]]*(?:\\[[^\\[\\]]*\\][^\\[\\]]*)*\\]|[^\\[\\]])*)\\]\\(\\s*<?((?:\\([^)]*\\)|[^\\s\\\\]|\\\\.)*?)>?(?:\\s+['\"]([\\s\\S]*?)['\"])?\\s*\\)"),tb=/^!\[(.*?)\]\( *((?:\([^)]*\)|[^() ])*) *"?([^)"]*)?"?\)/;function tx(e){return"string"==typeof e}function tk(e){let t=e.length;for(;t>0&&e[t-1]<=" ";)t--;return e.slice(0,t)}function tE(e,t){return e.startsWith(t)}function tA(e){return e.replace(/[ÀÁÂÃÄÅàáâãä忯]/g,"a").replace(/[çÇ]/g,"c").replace(/[ðÐ]/g,"d").replace(/[ÈÉÊËéèêë]/g,"e").replace(/[ÏïÎîÍíÌì]/g,"i").replace(/[Ññ]/g,"n").replace(/[øØœŒÕõÔôÓóÒò]/g,"o").replace(/[ÜüÛûÚúÙù]/g,"u").replace(/[ŸÿÝý]/g,"y").replace(/[^a-z0-9- ]/gi,"").replace(/ /gi,"-").toLowerCase()}function tN(e){return eY.test(e)?"right":eK.test(e)?"center":eX.test(e)?"left":null}function tw(e,t,n,a){let r=n.inTable;n.inTable=!0;let i=[[]],o="";function l(){if(!o)return;let e=i[i.length-1];e.push.apply(e,t(o,n)),o=""}
1return e.trim().split(/(`[^`]*`|\\\||\|)/).filter(Boolean).forEach((e,t,n)=>{"|"===e.trim()&&(l(),a)?0!==t&&t!==n.length-1&&i.push([]):o+=e}),l(),n.inTable=r,i}function tC(e,t,n){var a;n.inline=!0;let r=e[2]?e[2].replace(eJ,"").split("|").map(tN):[],i=e[3]?(a=e[3],a.trim().split("\n").map(function(e){return tw(e,t,n,!0)})):[],o=tw(e[1],t,n,!!i.length);return n.inline=!1,i.length?{align:r,cells:i,header:o,type:"25"}:{children:o,type:"21"}}function tD(e,t){return null==e.align[t]?{}:{textAlign:e.align[t]}}function tS(e){return e.inline=1,e}function tT(e){return tS(function(t,n){return n.inline?e.exec(t):null})}function tP(e){return tS(function(t,n){return n.inline||n.simple?e.exec(t):null})}function tV(e){return function(t,n){return n.inline||n.simple?null:e.exec(t)}}function tI(e){return tS(function(t){return e.exec(t)})}let tF=/(javascript|vbscript|data(?!:image)):/i;function tL(e){try{let t=decodeURIComponent(e).replace(/[^A-Za-z0-9/:]/g,"");if(tF.test(t))return null}catch(e){return null}return e}function tO(e){return e?e.replace(e6,"$1"):e}function tU(e,t,n){let a=n.inline||!1,r=n.simple||!1;n.inline=!0,n.simple=!0;let i=e(t,n);return n.inline=a,n.simple=r,i}function tR(e,t,n){let a=n.inline||!1;n.inline=!1;let r=e(t,n);return n.inline=a,r}let tq=(e,t,n)=>({children:tU(t,e[2],n)});function tW(){return{}}function tj(){return null}function tz(e,t,n){let a=e,r=t.split(".");for(;r.length&&void 0!==(a=a[r[0]]);)r.shift();return a||n}var tB=e=>{let{children:t,options:n}=e,a=function(e,t){if(null==e)return{};var n,a,r={},i=Object.keys(e);for(a=0;a<i.length;a++)t.indexOf(n=i[a])>=0||(r[n]=e[n]);return r}(e,ec);return r.cloneElement(function(e="",t={}){var n,a;t.overrides=t.overrides||{},t.namedCodesToUnicode=t.namedCodesToUnicode?es({},ep,t.namedCodesToUnicode):ep;let i=t.slugify||tA,o=t.sanitizer||tL,l=t.createElement||r.createElement,s=[eg,ek,eE,t.enforceAtxHeadings?eI:eV,eF,eH,tf,tg],c=[...s,eM,eL,eU,eq];function u(e,t){for(let n=0;n<e.length;n++)if(e[n].test(t))return!0;return!1}function p(e,n,...a){var r;let i,o=tz(t.overrides,e+".props",{});return l((i=tz(r=t.overrides,e))?"function"==typeof i||"object"==typeof i&&"render"in i?i:tz(r,e+".component",e):e,es({},n,o,{className:function(...e){return e.filter(Boolean).join(" ")}(null==n?void 0:n.className,o.className)||void 0}),...a)}function d(e){let n;e=e.replace(eT,"");let a=!1;t.forceInline?a=!0:t.forceBlock||(a=!1===eZ.test(e));let r=v(y(a?e:tk(e).replace(te,"")+"\n\n",{inline:a}));for(;tx(r[r.length-1])&&!r[r.length-1].trim();)r.pop();if(null===t.wrapper)return r;let i=t.wrapper||(a?"span":"div");if(r.length>1||t.forceWrapper)n=r;else{if(1===r.length)return"string"==typeof(n=r[0])?p("span",{key:"outer"},n):n;n=null}return l(i,{key:"outer"},n)}function m(e,t){if(!t||!t.trim())return null;let n=t.match(eh);return n?n.reduce(function(t,n){let a=n.indexOf("=");if(-1!==a){var r,i,l;let s,c=(-1!==(r=n.slice(0,a)).indexOf("-")&&null===r.match(eR)&&(r=r.replace(eB,function(e,t){return t.toUpperCase()})),r).trim(),u=('"'===(s=(i=n.slice(a+1).trim())[0])||"'"===s)&&i.length>=2&&i[i.length-1]===s?i.slice(1,-1):i,p=eu[c]||c;if("ref"===p)return t;let m=t[p]=(l=u,"style"===c?(function(e){let t=[],n="",a=!1,r=!1,i="";if(!e)return t;for(let o=0;o<e.length;o++){let l=e[o];if('"'!==l&&"'"!==l||a||(r?l===i&&(r=!1,i=""):(r=!0,i=l)),"("===l&&n.endsWith("url")?a=!0:")"===l&&a&&(a=!1),";"!==l||r||a)n+=l;else{let e=n.trim();if(e){let n=e.indexOf(":");if(n>0){let a=e.slice(0,n).trim(),r=e.slice(n+1).trim();t.push([a,r])}}n=""}}let o=n.trim();if(o){let e=o.indexOf(":");if(e>0){let n=o.slice(0,e).trim(),a=o.slice(e+1).trim();t.push([n,a])}}return t})(l).reduce(function(t,[n,a]){return t[n.replace(/(-[a-z])/g,e=>e[1].toUpperCase())]=o(a,e,n),t},{}):-1!==em.indexOf(c)?o(tO(l),e,c):(l.match(eW)&&(l=tO(l.slice(1,l.length-1))),"true"===l||"false"!==l&&l));"string"==typeof m&&(eL.test(m)||eq.test(m))&&(t[p]=d(m.trim()))}else"style"!==n&&(t[eu[n]||n]=!0);return t},{}):null}let h=[],f={},g={0:{t:[">"],o:tV(eg),i:1,u(e,t,n){let[,a,r]=e[0].replace(ey,"").match(ev);return{alert:a,children:t(r,n)}},l(e,t,n){let a={key:n.key};return e.alert&&(a.className="markdown-alert-"+i(e.alert.toLowerCase(),tA),e.children.unshift({attrs:{},children:[{type:"27",text:e.alert}],noInnerParse:!0,type:"11",tag:"header"})),p("blockquote",a,t(e.children,n))}}
1,1:{t:["  "],o:tI(eb),i:1,u:tW,l:(e,t,n)=>p("br",{key:n.key})},2:{t:["--","__","**","- ","* ","_ "],o:tV(ex),i:1,u:tW,l:(e,t,n)=>p("hr",{key:n.key})},3:{t:["    "],o:tV(eE),i:0,u:e=>({lang:void 0,text:tO(tk(e[0].replace(/^ {4}/gm,"")))}),l:(e,t,n)=>p("pre",{key:n.key},p("code",es({},e.attrs,{className:e.lang?"lang-"+e.lang:""}),e.text))},4:{t:["```","~~~"],o:tV(ek),i:0,u:e=>({attrs:m("code",e[3]||""),lang:e[2]||void 0,text:e[4],type:"3"})},5:{t:["`"],o:tP(eA),i:3,u:e=>({text:tO(e[2])}),l:(e,t,n)=>p("code",{key:n.key},e.text)},6:{t:["[^"],o:tV(eC),i:0,u:e=>(h.push({footnote:e[2],identifier:e[1]}),{}),l:tj},7:{t:["[^"],o:tT(eD),i:1,u:e=>({target:"#"+i(e[1],tA),text:e[1]}),l:(e,t,n)=>p("a",{key:n.key,href:o(e.target,"a","href")},p("sup",{key:n.key},e.text))},8:{t:["[ ]","[x]"],o:tT(eP),i:1,u:e=>({completed:"x"===e[1].toLowerCase()}),l:(e,t,n)=>p("input",{checked:e.completed,key:n.key,readOnly:!0,type:"checkbox"})},9:{t:["#"],o:tV(t.enforceAtxHeadings?eI:eV),i:1,u:(e,t,n)=>({children:tU(t,e[2],n),id:i(e[2],tA),level:e[1].length}),l:(e,t,n)=>p("h"+e.level,{id:e.id,key:n.key},t(e.children,n))},10:{t:e=>{let t=e.indexOf("\n");return t>0&&t<e.length-1&&("="===e[t+1]||"-"===e[t+1])},o:tV(eF),i:1,u:(e,t,n)=>({children:tU(t,e[1],n),level:"="===e[2]?1:2,type:"9"})},11:{t:["<"],o:tI(eL),i:1,u(e,t,n){let[,a]=e[3].match(tt),r=RegExp("^"+a,"gm"),i=e[3].replace(r,""),o=u(c,i)?tR:tU,l=e[1].toLowerCase(),s=-1!==ed.indexOf(l),p=(s?l:e[1]).trim(),d={attrs:m(p,e[2]),noInnerParse:s,tag:p};if(n.inAnchor=n.inAnchor||"a"===l,s)d.text=e[3];else{let e=n.inHTML;n.inHTML=!0,d.children=o(t,i,n),n.inHTML=e}return n.inAnchor=!1,d},l:(e,t,n)=>p(e.tag,es({key:n.key},e.attrs),e.text||(e.children?t(e.children,n):""))},13:{t:["<"],o:tI(eq),i:1,u(e){let t=e[1].trim();return{attrs:m(t,e[2]||""),tag:t}},l:(e,t,n)=>p(e.tag,es({},e.attrs,{key:n.key}))},12:{t:["\x3c!--"],o:tI(eU),i:1,u:()=>({}),l:tj},14:{t:["!["],o:tP(tb),i:1,u:e=>({alt:tO(e[1]),target:tO(e[2]),title:tO(e[3])}),l:(e,t,n)=>p("img",{key:n.key,alt:e.alt||void 0,title:e.title||void 0,src:o(e.target,"img","src")})},15:{t:["["],o:tT(tv),i:3,u:(e,t,n)=>{var a;let r,i,o;return{children:(a=e[1],r=n.inline||!1,i=n.simple||!1,n.inline=!1,n.simple=!0,o=t(a,n),n.inline=r,n.simple=i,o),target:tO(e[2]),title:tO(e[3])}},l:(e,t,n)=>p("a",{key:n.key,href:o(e.target,"a","href"),title:e.title},t(e.children,n))},16:{t:["<"],o:tT(ez),i:0,u(e){let t=e[1],n=!1;return -1!==t.indexOf("@")&&-1===t.indexOf("//")&&(n=!0,t=t.replace("mailto:","")),{children:[{text:t,type:"27"}],target:n?"mailto:"+t:t,type:"15"}}},17:{t:(e,n)=>!n.inAnchor&&!t.disableAutoLink&&(tE(e,"http://")||tE(e,"https://")),o:tT(ej),i:0,u:e=>({children:[{text:e[1],type:"27"}],target:e[1],title:void 0,type:"15"})},20:ty(p,1),33:ty(p,2),19:{t:["\n"],o:tV(eN),i:3,u:tW,l:()=>"\n"},21:{o:tS(function(e,t){if(t.inline||t.simple||t.inHTML&&-1===e.indexOf("\n\n")&&-1===t.prevCapture.indexOf("\n\n"))return null;let n="",a=0;for(;;){let t=e.indexOf("\n",a),r=e.slice(a,-1===t?void 0:t+1);if(u(s,r)||(n+=r,-1===t||!r.trim()))break;a=t+1}let r=tk(n);return""===r?null:[n,,r]}
vendor: 1,407 bytes, line 1
1),i:3,u:tq,l:(e,t,n)=>p("p",{key:n.key},t(e.children,n))},22:{t:["["],o:tT(e_),i:0,u:e=>(f[e[1]]={target:e[2],title:e[4]},{}),l:tj},23:{t:["!["],o:tP(e$),i:0,u:e=>({alt:e[1]?tO(e[1]):void 0,ref:e[2]}),l:(e,t,n)=>f[e.ref]?p("img",{key:n.key,alt:e.alt,src:o(f[e.ref].target,"img","src"),title:f[e.ref].title}):null},24:{t:e=>"["===e[0]&&-1===e.indexOf("]("),o:tT(eG),i:0,u:(e,t,n)=>({children:t(e[1],n),fallbackChildren:e[0],ref:e[2]}),l:(e,t,n)=>f[e.ref]?p("a",{key:n.key,href:o(f[e.ref].target,"a","href"),title:f[e.ref].title},t(e.children,n)):p("span",{key:n.key},e.fallbackChildren)},25:{t:["|"],o:tV(eH),i:1,u:tC,l:(e,t,n)=>p("table",{key:n.key},p("thead",null,p("tr",null,e.header.map(function(a,r){return p("th",{key:r,style:tD(e,r)},t(a,n))}))),p("tbody",null,e.cells.map(function(a,r){return p("tr",{key:r},a.map(function(a,r){return p("td",{key:r,style:tD(e,r)},t(a,n))}))})))},27:{o:tS(function(e,t){let n;return tE(e,":")&&(n=e4.exec(e)),n||e9.exec(e)}),i:4,u(e){let n=e[0];return{text:-1===n.indexOf("&")?n:n.replace(eO,(e,n)=>t.namedCodesToUnicode[n]||e)}},l:e=>e.text},28:{t:["**","__"],o:tP(e3),i:2,u:(e,t,n)=>({children:t(e[2],n)}),l:(e,t,n)=>p("strong",{key:n.key},t(e.children,n))},29:{t:e=>{let t=e[0];return("*"===t||"_"===t)&&e[1]!==t},o:tP(e2),i:3,u:(e,t,n)=>({children:t(e[2],n)}),l:(e,t,n)=>p("em",{key:n.key},t(e.children,n))},30:{t:["\\"],o:tP(e8),i:1,u:e=>({text:e[1],type:"27"})}
1,31:{t:["=="],o:tP(e5),i:3,u:tq,l:(e,t,n)=>p("mark",{key:n.key},t(e.children,n))},32:{t:["~~"],o:tP(e7),i:3,u:tq,l:(e,t,n)=>p("del",{key:n.key},t(e.children,n))}};!0===t.disableParsingRawHTML&&(delete g[11],delete g[13]);let y=((n=Object.keys(g)).sort(function(e,t){return g[e].i-g[t].i||(e<t?-1:1)}),function(e,t){return function e(t,a){var r=[];if(a.prevCapture=a.prevCapture||"",t.trim())for(;t;)for(var i=0;i<n.length;){var o=n[i],l=g[o];if(!l.t||function(e,t,n){if(Array.isArray(n)){for(let t=0;t<n.length;t++)if(tE(e,n[t]))return!0;return!1}return n(e,t)}(t,a,l.t)){var s=l.o(t,a);if(s&&s[0]){t=t.substring(s[0].length);var c=l.u(s,e,a);a.prevCapture+=s[0],c.type||(c.type=o),r.push(c);break}i++}else i++}return a.prevCapture="",r}(e.replace(ew,"\n").replace(eS,"").replace(eQ,"    "),t)}),v=(a=t.renderRule,function e(t,n={}){var r;let i;if(Array.isArray(t)){let a=n.key,r=[],i=!1;for(let a=0;a<t.length;a++){n.key=a;let o=e(t[a],n),l=tx(o);l&&i?r[r.length-1]+=o:null!==o&&r.push(o),i=l}return n.key=a,r}return r=e,i=g[t.type].l,a?a(()=>i(t,r,n),t,r,n):i(t,r,n)}),b=d(e);return h.length?p("div",null,b,p("footer",{key:"footer"},h.map(function(e){return p("div",{id:i(e.identifier,tA),key:e.identifier},e.identifier,v(y(e.footnote,{inline:!0})))}))):b}(null==t?"":t,n),a)},tH=function(e){var t;function n(e){var t;return I(this,n),L(t=V(this,n,[e]),"fetchAiGeneratedResponse",function(e,n){return t.props.loadAiGeneratedResponse(e,n).then(function(e){e&&e.answer&&t.setState({message:e.answer})}).catch(function(e){console.error("AI response error:",e)})}),t.state={message:null,isLoading:!0},t}return R(n,e),F(n,[{key:"componentDidMount",value:(t=P(W().m(function e(){var t,n,a,r,i,o,l,s,c,u,p,d,m;return W().w(function(e){for(;;)switch(e.p=e.n){case 0:if(n=(t=this.props).entities,a=t.query,r=[],!(n&&n.length>0)){e.n=7;break}i=function(e){var t="u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=function(e){if(e){if("string"==typeof e)return S(e,void 0);var t=({}).toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?S(e,void 0):void 0}}(e))){t&&(e=t);var n=0,a=function(){};return{s:a,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:a}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,i=!0,o=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return i=e.done,e},e:function(e){o=!0,r=e},f:function(){try{i||null==t.return||t.return()}finally{if(o)throw r}}}}(n);try{for(i.s();!(o=i.n()).done;)(l=o.value).sourceID&&r.push(l.sourceID)}catch(e){i.e(e)}finally{i.f()}if(!(r&&r.length>0)){e.n=7;break}return e.p=1,e.n=2,Y(r);case 2:if(u=void 0===(c=(s=e.v).data)?[]:c,p=s.success,m=void 0===(d=s.message)?"":d,!(p&&u&&u.length)){e.n=4;break}if(!a){e.n=3;break}return e.n=3,this.fetchAiGeneratedResponse(a,u);case 3:e.n=5;break;case 4:!1==p&&m&&console.error("Error fetching nutrition item data: ",m);case 5:e.n=7;break;case 6:e.p=6,console.error("Error in componentDidMount: ",e.v);case 7:this.setState({isLoading:!1});case 8:return e.a(2)}},e,this,[[1,6]])})),function(){return t.apply(this,arguments)})},{key:"render",value:function(){var e=this.props.classes,t=this.state,n=t.message,a=t.isLoading;return n||a?r.createElement(d.A,{container:!0,className:e.gridContainer},a?r.createElement(N.A,{size:30}):r.createElement(w.A,{in:!0,timeout:800},r.createElement("div",{className:"".concat(e.fullWidth," ").concat(e.fadeInWithTranslate)},r.createElement(u.A,{className:e.parent},r.createElement(d.A,{container:!0,className:e.contentPadding},n&&r.createElement(c.A,{variant:"subtitle1"},r.createElement(tB,null,n))))))):null}}])}(r.Component),tM=(0,o.A)(function(e){return{parent:L({background:e.palette.background.paper,padding:"2%"},e.breakpoints.down("sm"),{margin:"0 10px"}),viewMoreButtonContainer:{display:"flex",justifyContent:"center",marginTop:e.spacing(1)},viewMoreButton:{marginTop:e.spacing(1.25),width:"130px",height:"35px",borderRadius:e.shape.borderRadius,backgroundColor:e.palette.background.paper,border:"1px solid ".concat(e.palette.primary.main),"&:hover":{backgroundColor:e.palette.action.hover}},seeMore:{fontWeight:500,color:e.palette.primary.main},iconButton:{display:"flex",width:"10px",height:"10px",justifyContent:"center",alignItems:"center",flexShrink:0,backgroundColor:e.palette.primary.main,marginLeft:e.spacing(2.5)},chevronIcon:{fill:e.palette.background.paper},gridContainer:{alignItems:"center",justifyContent:"center"},fullWidth:{width:"100%"},contentPadding:{padding:"0 5px"},fadeInWithTranslate:{animation:"$fadeInDown 0.6s ease-out"}}},{withTheme:!0})(tH),t_=function(e){function t(e){var n;
1if(I(this,t),L(n=V(this,t,[e]),"getNutritionDetails",function(e){n.props.history.push({pathname:n.props.baseURL+"/details/"+e})}),n.setHDState({starEnabled:!1,isBookmarked:!1,header:{primary:"Nutrition"}}),n.props.location.state&&n.props.location.state.searchData){var a=n.props.location.state.searchData;a.url?n.props.history.replace(n.props.match.url+a.url):a.entities.length>0?n.props.history.replace(n.props.match.url+"/search-results/"+a.entities[0].word):a.queryWithoutStopWords?n.props.history.replace(n.props.match.url+"/search-results/"+a.queryWithoutStopWords):n.props.history.replace(n.props.match.url+"/search")}return n}return R(t,e),F(t,[{key:"render",value:function(){var e=this.props,t=e.searchData,n=e.classes,a=t||{},o=a.entities,l=a.query;a.queryObject;var s=a.intent;return r.createElement(r.Fragment,null,s&&"food-compare"===s||o&&o.length>1?r.createElement(tM,{entities:o,query:l,loadAiGeneratedResponse:this.props.loadAiGeneratedResponse,classes:n}):r.createElement(r.Fragment,null,this.props.quickPanel?r.createElement(el,{searchData:this.props.searchData,query:this.props.query,view:this.props.view,sideBar:this.props.sideBar,getNutritionDetails:this.getNutritionDetails,loadMore:this.props.loadMore?this.props.loadMore:null,componentLoaded:this.props.componentLoaded?this.props.componentLoaded:null,seeMore:this.routeToComponent}):null),r.createElement(i.qh,{exact:!0,path:this.props.match.url+"/search",render:function(e){return r.createElement(ei,e)}}),r.createElement(i.qh,{exact:!0,path:this.props.match.url+"/search-results/:query",render:function(e){return r.createElement(et,e)}}),r.createElement(i.qh,{exact:!0,path:this.props.match.url+"/details/:itemID",render:function(e){return r.createElement(ea,e)}}))}}])}(C.HDComponent)}}]);

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.