admesh-ui-sdk 0.16.2 → 0.16.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -19,7 +19,7 @@
19
19
  <%s {...props} />
20
20
  React keys must be passed directly to JSX without using spread:
21
21
  let props = %s;
22
- <%s key={someKey} {...props} />`,v,_,V,_),de[_+v]=!0)}if(_=null,b!==void 0&&(o(b),_=""+b),s(p)&&(o(p.key),_=""+p.key),"key"in p){b={};for(var te in p)te!=="key"&&(b[te]=p[te])}else b=p;return _&&l(b,typeof a=="function"?a.displayName||a.name||"Unknown":a),u(a,_,M,P,i(),b,Z,ee)}function c(a){typeof a=="object"&&a!==null&&a.$$typeof===w&&a._store&&(a._store.validated=1)}var h=y,w=Symbol.for("react.transitional.element"),f=Symbol.for("react.portal"),T=Symbol.for("react.fragment"),j=Symbol.for("react.strict_mode"),k=Symbol.for("react.profiler"),A=Symbol.for("react.consumer"),z=Symbol.for("react.context"),U=Symbol.for("react.forward_ref"),$=Symbol.for("react.suspense"),I=Symbol.for("react.suspense_list"),D=Symbol.for("react.memo"),F=Symbol.for("react.lazy"),m=Symbol.for("react.activity"),S=Symbol.for("react.client.reference"),R=h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,C=Object.prototype.hasOwnProperty,B=Array.isArray,N=console.createTask?console.createTask:function(){return null};h={"react-stack-bottom-frame":function(a){return a()}};var Q,W={},E=h["react-stack-bottom-frame"].bind(h,n)(),K=N(d(n)),de={};G.Fragment=T,G.jsx=function(a,p,b,v,P){var M=1e4>R.recentlyCreatedOwnerStacks++;return x(a,p,b,!1,v,P,M?Error("react-stack-top-frame"):E,M?N(d(a)):K)},G.jsxs=function(a,p,b,v,P){var M=1e4>R.recentlyCreatedOwnerStacks++;return x(a,p,b,!0,v,P,M?Error("react-stack-top-frame"):E,M?N(d(a)):K)}}()),G}var me;function _e(){return me||(me=1,process.env.NODE_ENV==="production"?X.exports=ke():X.exports=ve()),X.exports}var r=_e();const je=e=>{try{return new URL(e),!0}catch{return!1}},pe=(e,t)=>{const o=new Map;t.forEach(g=>{g.admesh_link&&o.set(g.admesh_link,g)});const d=/\[([^\]]+)\]\(([^)]+)\)/g,i=[];let n=0,s,l=0;for(;(s=d.exec(e))!==null;){const[g,u,x]=s,c=o.get(x);s.index>n&&i.push(e.slice(n,s.index)),c?(l++,i.push(r.jsx("a",{href:c.admesh_link,target:"_blank",rel:"noopener noreferrer",className:"text-blue-600 dark:text-blue-400 hover:text-blue-800 dark:hover:text-blue-300 underline decoration-blue-600 dark:decoration-blue-400 hover:decoration-blue-800 dark:hover:decoration-blue-300 transition-colors duration-200 font-medium",style:{color:"#2563eb",textDecoration:"underline",textDecorationColor:"#2563eb",textUnderlineOffset:"2px"},onClick:h=>{console.log("AdMesh summary link clicked:",{adId:c.ad_id,productId:c.product_id,title:c.title||c.recommendation_title,brand:c.brand,pricing:c.pricing,admeshLink:c.admesh_link,source:"summary"}),typeof window<"u"&&window.admeshTracker&&window.admeshTracker.trackClick({adId:c.ad_id,productId:c.product_id,admeshLink:c.admesh_link,source:"summary"})},children:u},`summary-link-${l}`))):(console.warn(`[AdMesh Summary] No recommendation found for link: [${u}](${x}), creating regular link`),je(x)?(l++,i.push(r.jsx("a",{href:x,target:"_blank",rel:"noopener noreferrer",className:"text-blue-600 dark:text-blue-400 hover:text-blue-800 dark:hover:text-blue-300 underline decoration-blue-600 dark:decoration-blue-400 hover:decoration-blue-800 dark:hover:decoration-blue-300 transition-colors duration-200 font-medium",style:{color:"#2563eb",textDecoration:"underline",textDecorationColor:"#2563eb",textUnderlineOffset:"2px"},onClick:h=>{console.log("AdMesh summary unmatched link clicked:",{linkText:u,url:x,source:"summary"}),typeof window<"u"&&window.admeshTracker&&window.admeshTracker.trackClick({url:x,linkText:u,source:"summary_unmatched"})},children:u},`summary-link-${l}`))):(console.warn(`[AdMesh Summary] Invalid URL in markdown link: [${u}](${x})`),i.push(u))),n=s.index+g.length}return n<e.length&&i.push(e.slice(n)),i},oe=({summaryText:e,recommendations:t,theme:o,className:d="",style:i={},onLinkClick:n})=>{if(!e||!e.trim())return console.warn("[AdMesh Summary] No summary text provided"),null;if(!t||t.length===0){console.warn("[AdMesh Summary] No recommendations provided");const l=pe(e,[]);return r.jsx("div",{className:`admesh-summary-unit ${d}`,style:i,children:r.jsx("p",{className:"text-gray-700 dark:text-gray-300 leading-relaxed",children:l.map((g,u)=>r.jsx(y.Fragment,{children:g},u))})})}const s=pe(e,t);return r.jsxs("div",{className:`admesh-summary-unit ${d}`,style:{fontFamily:(o==null?void 0:o.fontFamily)||'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',...i},children:[r.jsx("div",{className:"summary-content",children:r.jsx("p",{className:"text-gray-700 dark:text-gray-300 leading-relaxed text-base",children:s.map((l,g)=>r.jsx(y.Fragment,{children:l},g))})}),r.jsx("div",{className:"mt-3 pt-2 border-t border-gray-200 dark:border-gray-700",children:r.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400",children:"Sponsored"})})]})};var re={exports:{}};/*!
22
+ <%s key={someKey} {...props} />`,v,_,V,_),de[_+v]=!0)}if(_=null,b!==void 0&&(o(b),_=""+b),s(p)&&(o(p.key),_=""+p.key),"key"in p){b={};for(var te in p)te!=="key"&&(b[te]=p[te])}else b=p;return _&&l(b,typeof a=="function"?a.displayName||a.name||"Unknown":a),u(a,_,M,P,i(),b,Z,ee)}function c(a){typeof a=="object"&&a!==null&&a.$$typeof===w&&a._store&&(a._store.validated=1)}var h=y,w=Symbol.for("react.transitional.element"),f=Symbol.for("react.portal"),T=Symbol.for("react.fragment"),j=Symbol.for("react.strict_mode"),k=Symbol.for("react.profiler"),A=Symbol.for("react.consumer"),z=Symbol.for("react.context"),U=Symbol.for("react.forward_ref"),$=Symbol.for("react.suspense"),I=Symbol.for("react.suspense_list"),D=Symbol.for("react.memo"),F=Symbol.for("react.lazy"),m=Symbol.for("react.activity"),S=Symbol.for("react.client.reference"),R=h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,C=Object.prototype.hasOwnProperty,B=Array.isArray,N=console.createTask?console.createTask:function(){return null};h={"react-stack-bottom-frame":function(a){return a()}};var Q,W={},E=h["react-stack-bottom-frame"].bind(h,n)(),K=N(d(n)),de={};G.Fragment=T,G.jsx=function(a,p,b,v,P){var M=1e4>R.recentlyCreatedOwnerStacks++;return x(a,p,b,!1,v,P,M?Error("react-stack-top-frame"):E,M?N(d(a)):K)},G.jsxs=function(a,p,b,v,P){var M=1e4>R.recentlyCreatedOwnerStacks++;return x(a,p,b,!0,v,P,M?Error("react-stack-top-frame"):E,M?N(d(a)):K)}}()),G}var me;function _e(){return me||(me=1,process.env.NODE_ENV==="production"?X.exports=ke():X.exports=ve()),X.exports}var r=_e();const je=e=>{try{return new URL(e),!0}catch{return!1}},pe=(e,t)=>{const o=new Map;t.forEach(g=>{g.admesh_link&&o.set(g.admesh_link,g)});const d=/\[([^\]]+)\]\(([^)]+)\)/g,i=[];let n=0,s,l=0;for(;(s=d.exec(e))!==null;){const[g,u,x]=s,c=o.get(x);s.index>n&&i.push(e.slice(n,s.index)),c?(l++,i.push(r.jsx("a",{href:c.admesh_link,target:"_blank",rel:"noopener noreferrer",className:"text-blue-600 dark:text-blue-400 hover:text-blue-800 dark:hover:text-blue-300 underline decoration-blue-600 dark:decoration-blue-400 hover:decoration-blue-800 dark:hover:decoration-blue-300 transition-colors duration-200 font-medium",style:{color:"#2563eb",textDecoration:"underline",textDecorationColor:"#2563eb",textUnderlineOffset:"2px"},onClick:h=>{console.log("AdMesh summary link clicked:",{adId:c.ad_id,productId:c.product_id,title:c.title||c.recommendation_title,brand:c.brand,pricing:c.pricing,admeshLink:c.admesh_link,source:"summary"}),typeof window<"u"&&window.admeshTracker&&window.admeshTracker.trackClick({adId:c.ad_id,productId:c.product_id,admeshLink:c.admesh_link,source:"summary"})},children:u},`summary-link-${l}`))):(console.warn(`[AdMesh Summary] No recommendation found for link: [${u}](${x}), creating regular link`),je(x)?(l++,i.push(r.jsx("a",{href:x,target:"_blank",rel:"noopener noreferrer",className:"text-blue-600 dark:text-blue-400 hover:text-blue-800 dark:hover:text-blue-300 underline decoration-blue-600 dark:decoration-blue-400 hover:decoration-blue-800 dark:hover:decoration-blue-300 transition-colors duration-200 font-medium",style:{color:"#2563eb",textDecoration:"underline",textDecorationColor:"#2563eb",textUnderlineOffset:"2px"},onClick:h=>{console.log("AdMesh summary unmatched link clicked:",{linkText:u,url:x,source:"summary"}),typeof window<"u"&&window.admeshTracker&&window.admeshTracker.trackClick({url:x,linkText:u,source:"summary_unmatched"})},children:u},`summary-link-${l}`))):(console.warn(`[AdMesh Summary] Invalid URL in markdown link: [${u}](${x})`),i.push(u))),n=s.index+g.length}return n<e.length&&i.push(e.slice(n)),i},oe=({summaryText:e,recommendations:t,theme:o,className:d="",style:i={},onLinkClick:n})=>{if(!e||!e.trim())return console.warn("[AdMesh Summary] No summary text provided"),null;if(!t||t.length===0){console.warn("[AdMesh Summary] No recommendations provided");const l=pe(e,[]);return r.jsx("div",{className:`admesh-summary-unit ${d}`,style:i,children:r.jsx("p",{className:"text-gray-700 dark:text-gray-300 leading-relaxed",children:l.map((g,u)=>r.jsx(y.Fragment,{children:g},u))})})}const s=pe(e,t);return r.jsxs("div",{className:`admesh-summary-unit ${d}`,style:{fontFamily:(o==null?void 0:o.fontFamily)||'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',...i},children:[r.jsx("div",{className:"summary-content",children:r.jsx("p",{className:"text-gray-700 dark:text-gray-300 leading-relaxed text-base",children:s.map((l,g)=>r.jsx(y.Fragment,{children:l},g))})}),r.jsx("div",{className:"mt-3 pt-2 border-t border-gray-200 dark:border-gray-700",children:r.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400",children:"Sponsored"})})]})};var re={exports:{}};/*!
23
23
  Copyright (c) 2018 Jed Watson.
24
24
  Licensed under the MIT License (MIT), see
25
25
  http://jedwatson.github.io/classnames
@@ -691,7 +691,7 @@ React keys must be passed directly to JSX without using spread:
691
691
  .admesh-component .lg\\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
692
692
  .admesh-component .lg\\:col-span-1 { grid-column: span 1 / span 1; }
693
693
  }
694
- `;let ae=!1;const fe=()=>{y.useEffect(()=>{if(ae)return;const e=document.createElement("style");return e.id="admesh-ui-sdk-styles",e.textContent=Me,document.getElementById("admesh-ui-sdk-styles")||(document.head.appendChild(e),ae=!0),()=>{const t=document.getElementById("admesh-ui-sdk-styles");t&&document.head.contains(t)&&(document.head.removeChild(t),ae=!1)}},[])},q=(e,t={})=>{const o=e.intent_match_score||0,d=t.customLabels||{};return o>=.8?d.partnerRecommendation||"Sponsored":o>=.6?d.partnerMatch||"Partner Match":o>=.3?d.promotedOption||"Promoted":d.relatedOption||"Related"},se=(e,t)=>{const o=e.intent_match_score||0;return o>=.8?"This recommendation is from a partner who compensates us when you engage. We've matched it to your needs based on your query.":o>=.6?"Top-rated partner solution matched to your specific requirements. Partner compensates us for qualified referrals.":o>=.3?"This partner solution may be relevant to your needs. The partner compensates us when you take qualifying actions.":"This solution is somewhat related to your query. While not a perfect match, it might still be helpful. This partner compensates us for qualified referrals."},Ee=(e=!0,t=!1)=>e?t?"These curated recommendations are from partners who compensate us for referrals.":"Personalized Sponsoreds: All results are from vetted partners who compensate us for qualified matches. We've ranked them based on relevance to your specific needs.":"Expanded Results: While these don't perfectly match your query, they're related solutions from our partner network. All partners compensate us for referrals.",Pe=(e,t=!1)=>{const o=e.intent_match_score||0;return t?"Promoted":o>=.8?"Smart Recommendation":o>=.6?"Partner Match":"Promoted"},Ie=()=>"We've partnered with trusted providers to bring you relevant solutions. These partners compensate us for qualified referrals, which helps us keep our service free.",Fe=e=>({"Top Match":"Top Match",Sponsored:"Sponsored","Perfect Fit":"Perfect Fit","Great Match":"Great Match",Recommended:"Recommended","Good Fit":"Good Fit",Featured:"Featured","Popular Choice":"Popular Choice","Premium Pick":"Premium Pick","Free Tier":"Free Tier","AI Powered":"AI Powered",Popular:"Popular",New:"New","Trial Available":"Trial Available","Related Option":"Related Option","Alternative Solution":"Alternative Solution","Expanded Match":"Expanded Match"})[e]||e,Le=(e,t="button")=>{const o=e.recommendation_title||e.title;return t==="link"?o:e.trial_days&&e.trial_days>0?`Try ${o}`:"Learn More"},Oe=e=>e.some(t=>(t.intent_match_score||0)>=.8),ze=(e=!1)=>e?"":"Recommendations ",H=({recommendation:e,theme:t,showMatchScore:o=!1,showBadges:d=!0,variation:i="default",expandable:n=!1,className:s,style:l})=>{var f,T,j,k,A,z,U,$,I,D,F,m,S,R;fe();const[g,u]=y.useState(!1);y.useMemo(()=>{var W;const C=[];q(e)==="Sponsored"&&C.push("Top Match"),e.trial_days&&e.trial_days>0&&C.push("Trial Available");const N=["ai","artificial intelligence","machine learning","ml","automation"];return(((W=e.keywords)==null?void 0:W.some(E=>N.some(K=>E.toLowerCase().includes(K))))||e.title.toLowerCase().includes("ai"))&&C.push("AI Powered"),e.badges&&e.badges.length>0&&e.badges.forEach(E=>{["Top Match","Free Tier","AI Powered","Popular","New","Trial Available"].includes(E)&&!C.includes(E)&&C.push(E)}),C},[e]),Math.round(e.intent_match_score*100);const c=i==="simple"?{title:e.recommendation_title||e.title,description:e.recommendation_description||e.description||e.reason,ctaText:e.recommendation_title||e.title,isSimple:!0}:{title:e.recommendation_title||e.title,description:e.recommendation_description||e.description||e.reason,ctaText:e.recommendation_title||e.title},h=O("admesh-component","admesh-card","relative p-4 sm:p-5 rounded-xl bg-gradient-to-br from-white to-gray-50 dark:from-slate-800 dark:to-slate-900 border border-gray-200/50 dark:border-slate-700/50 shadow-lg hover:shadow-xl transition-all duration-300 hover:-translate-y-1",s),w=t?{"--admesh-primary":t.primaryColor||t.accentColor||"#3b82f6","--admesh-secondary":t.secondaryColor||"#10b981","--admesh-accent":t.accentColor||"#3b82f6","--admesh-background":t.backgroundColor,"--admesh-surface":t.surfaceColor,"--admesh-border":t.borderColor,"--admesh-text":t.textColor,"--admesh-text-secondary":t.textSecondaryColor,"--admesh-radius":t.borderRadius||"12px","--admesh-shadow-sm":(f=t.shadows)==null?void 0:f.small,"--admesh-shadow-md":(T=t.shadows)==null?void 0:T.medium,"--admesh-shadow-lg":(j=t.shadows)==null?void 0:j.large,"--admesh-spacing-sm":(k=t.spacing)==null?void 0:k.small,"--admesh-spacing-md":(A=t.spacing)==null?void 0:A.medium,"--admesh-spacing-lg":(z=t.spacing)==null?void 0:z.large,"--admesh-font-size-sm":(U=t.fontSize)==null?void 0:U.small,"--admesh-font-size-base":($=t.fontSize)==null?void 0:$.base,"--admesh-font-size-lg":(I=t.fontSize)==null?void 0:I.large,"--admesh-font-size-title":(D=t.fontSize)==null?void 0:D.title,fontFamily:t.fontFamily,width:((m=(F=t.components)==null?void 0:F.productCard)==null?void 0:m.width)||"100%"}:{width:"100%"};return i==="simple"?r.jsxs("div",{className:O("admesh-component admesh-simple-ad","inline-block text-sm leading-relaxed",s),style:{fontFamily:(t==null?void 0:t.fontFamily)||'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',...(S=t==null?void 0:t.components)==null?void 0:S.productCard,...l},"data-admesh-theme":t==null?void 0:t.mode,children:[r.jsx("span",{style:{fontSize:"11px",fontWeight:"600",color:(t==null?void 0:t.accentColor)||"#2563eb",backgroundColor:(t==null?void 0:t.mode)==="dark"?"#374151":"#f3f4f6",padding:"2px 6px",borderRadius:"4px",marginRight:"8px"},title:se(e,q(e)),children:q(e)}),r.jsxs("span",{style:{color:(t==null?void 0:t.mode)==="dark"?"#f3f4f6":"#374151",marginRight:"4px"},children:[c.description," "]}),r.jsx(J,{adId:e.ad_id,admeshLink:e.admesh_link,productId:e.product_id,trackingData:{title:e.title,matchScore:e.intent_match_score,component:"simple_ad_cta"},children:r.jsx("span",{style:{color:(t==null?void 0:t.accentColor)||"#2563eb",textDecoration:"underline",cursor:"pointer",fontSize:"inherit",fontFamily:"inherit"},children:c.ctaText})}),r.jsx("span",{style:{fontSize:"10px",color:(t==null?void 0:t.mode)==="dark"?"#9ca3af":"#6b7280",marginLeft:"8px"},children:"(Sponsored • )"})]}):r.jsx("div",{className:h,style:{fontFamily:(t==null?void 0:t.fontFamily)||'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',...(R=t==null?void 0:t.components)==null?void 0:R.productCard,...l},"data-admesh-theme":t==null?void 0:t.mode,children:r.jsxs("div",{className:"h-full flex flex-col",style:w,children:[r.jsx("div",{className:"mb-3",children:r.jsx("span",{style:{fontSize:"11px",fontWeight:"600",color:(t==null?void 0:t.accentColor)||"#2563eb",backgroundColor:(t==null?void 0:t.mode)==="dark"?"#374151":"#f3f4f6",padding:"2px 6px",borderRadius:"4px"},title:se(e,q(e)),children:q(e)})}),r.jsxs("div",{className:"flex justify-between items-center gap-3 mb-4",children:[r.jsxs("div",{className:"flex items-center gap-2 flex-1 min-w-0",children:[e.product_logo&&r.jsx("img",{src:e.product_logo.url,alt:`${e.title} logo`,className:"w-6 h-6 rounded flex-shrink-0",onError:C=>{C.target.style.display="none"}}),r.jsx("h4",{className:"font-semibold text-gray-800 dark:text-gray-200 text-sm sm:text-base truncate",children:c.title})]}),r.jsx("div",{className:"flex-shrink-0",children:r.jsx(J,{adId:e.ad_id,admeshLink:e.admesh_link,productId:e.product_id,trackingData:{title:e.title,matchScore:e.intent_match_score,component:"product_card_cta"},children:r.jsxs("button",{className:"text-xs px-2 py-1 sm:px-3 sm:py-2 rounded-full bg-gradient-to-r from-purple-500 to-pink-500 text-white hover:from-purple-600 hover:to-pink-600 flex items-center transition-all duration-200 transform hover:scale-105 shadow-md hover:shadow-lg whitespace-nowrap",children:["Visit",r.jsx("svg",{className:"ml-1 h-3 w-3",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:r.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"})})]})})})]}),r.jsx("div",{className:"mb-6",children:r.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-300 leading-relaxed",children:c.description})}),e.features&&e.features.length>0&&r.jsxs("div",{className:"mb-3",children:[r.jsx("div",{className:"text-xs text-gray-600 dark:text-gray-300 mb-2 font-medium",children:"✨ Key Features"}),r.jsxs("div",{className:"flex flex-wrap gap-1.5",children:[e.features.slice(0,4).map((C,B)=>r.jsxs("span",{className:"text-xs px-2 py-1 rounded-full bg-gradient-to-r from-indigo-100 to-purple-100 dark:from-indigo-900/30 dark:to-purple-900/30 text-indigo-700 dark:text-indigo-300 border border-indigo-200 dark:border-indigo-700",children:[r.jsx("svg",{className:"h-3 w-3 mr-0.5 inline text-indigo-500",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:r.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z"})}),C]},B)),e.features.length>4&&r.jsxs("span",{className:"text-xs text-gray-500 dark:text-gray-400 px-2 py-1",children:["+",e.features.length-4," more"]})]})]}),r.jsx("div",{className:"mt-auto pt-3 border-t border-gray-100 dark:border-slate-700",children:r.jsxs("div",{className:"flex items-center justify-between text-xs text-gray-500 dark:text-gray-400",children:[r.jsx("span",{children:"Sponsored"}),r.jsx("span",{className:"text-gray-400 dark:text-gray-500"})]})})]})})};H.displayName="AdMeshProductCard";const ge=({products:e=[],recommendations:t=[],title:o="Product Recommendations",showTitle:d=!0,className:i="",cardClassName:n="",onProductClick:s,showPricing:l=!0,showRatings:g=!0,showBrand:u=!0,showSource:x=!1,showShipping:c=!0,maxCards:h=10,cardWidth:w="md",theme:f="auto",borderRadius:T="md",shadow:j="sm"})=>{const k=t.length>0?t.slice(0,h):e.slice(0,h),A=()=>{switch(w){case"sm":return"w-48 min-w-48";case"md":return"w-64 min-w-64";case"lg":return"w-80 min-w-80";default:return"w-64 min-w-64"}},z=()=>{switch(T){case"none":return"rounded-none";case"sm":return"rounded-sm";case"md":return"rounded-lg";case"lg":return"rounded-xl";default:return"rounded-lg"}},U=()=>{switch(j){case"none":return"";case"sm":return"shadow-sm hover:shadow-md";case"md":return"shadow-md hover:shadow-lg";case"lg":return"shadow-lg hover:shadow-xl";default:return"shadow-sm hover:shadow-md"}},$=()=>f==="dark"?"bg-gray-900 text-white":f==="light"?"bg-white text-gray-900":"bg-white dark:bg-gray-900 text-gray-900 dark:text-white",I=m=>new Intl.NumberFormat("en-US",{style:"currency",currency:"USD",minimumFractionDigits:0,maximumFractionDigits:2}).format(m),D=m=>{const S=[],R=Math.floor(m),C=m%1!==0;for(let N=0;N<R;N++)S.push(r.jsx("span",{className:"text-yellow-400",children:"★"},N));C&&S.push(r.jsx("span",{className:"text-yellow-400",children:"☆"},"half"));const B=5-Math.ceil(m);for(let N=0;N<B;N++)S.push(r.jsx("span",{className:"text-gray-300 dark:text-gray-600",children:"☆"},`empty-${N}`));return S},F=m=>{if(s)s(m);else{const S=m.admesh_link||m.url;S&&window.open(S,"_blank","noopener,noreferrer")}};return(!e||e.length===0)&&(!t||t.length===0)?null:r.jsxs("div",{className:O("w-full",i),children:[d&&r.jsxs("div",{className:"mb-4",children:[r.jsx("h3",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:o}),r.jsx("div",{className:"mt-1 h-0.5 w-12 bg-blue-500"})]}),r.jsxs("div",{className:"relative",children:[k.length===0?r.jsx("div",{className:"text-center py-8 text-gray-500",children:"No products to display"}):r.jsx("div",{className:"flex gap-4 overflow-x-auto pb-4 scrollbar-hide",children:k.map(m=>{var R;const S=m.product_id||m.id||m.ad_id;return r.jsxs("div",{className:O(A(),z(),U(),$(),"flex-shrink-0 border border-gray-200 dark:border-gray-700 transition-all duration-200 cursor-pointer hover:scale-[1.02]",n),onClick:()=>F(m),children:[r.jsxs("div",{className:"relative aspect-square w-full overflow-hidden",children:[m.image_url?r.jsx("img",{src:m.image_url,alt:m.title,className:"h-full w-full object-cover transition-transform duration-200 hover:scale-105",loading:"lazy"}):r.jsx("div",{className:"flex h-full w-full items-center justify-center bg-gray-100 dark:bg-gray-800",children:r.jsx("svg",{className:"h-12 w-12 text-gray-400",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:r.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"})})}),l&&m.discount_percentage&&m.discount_percentage>0&&r.jsxs("div",{className:"absolute top-2 left-2 bg-red-500 text-white text-xs font-bold px-2 py-1 rounded",children:["-",Math.round(m.discount_percentage),"%"]}),x&&m.source&&r.jsx("div",{className:"absolute top-2 right-2 bg-blue-500 text-white text-xs font-medium px-2 py-1 rounded",children:m.source.toUpperCase()})]}),r.jsxs("div",{className:"p-3",children:[u&&m.brand&&r.jsx("div",{className:"text-xs text-gray-500 dark:text-gray-400 mb-1 uppercase tracking-wide",children:m.brand}),r.jsx("h4",{className:"text-sm font-medium text-gray-900 dark:text-white line-clamp-2 mb-2 leading-tight",children:m.title}),g&&m.rating&&r.jsxs("div",{className:"flex items-center gap-1 mb-2",children:[r.jsx("div",{className:"flex text-sm",children:D(m.rating)}),r.jsxs("span",{className:"text-xs text-gray-500 dark:text-gray-400",children:["(",m.review_count||0,")"]})]}),l&&m.price&&r.jsx("div",{className:"mb-2",children:r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsx("span",{className:"text-lg font-bold text-gray-900 dark:text-white",children:I(m.price)}),m.original_price&&m.original_price>m.price&&r.jsx("span",{className:"text-sm text-gray-500 dark:text-gray-400 line-through",children:I(m.original_price)})]})}),c&&((R=m.shipping_info)==null?void 0:R.free_shipping_over_35)&&r.jsx("div",{className:"text-xs text-green-600 dark:text-green-400 font-medium",children:"Free shipping over $35"}),m.availability&&m.availability!=="unknown"&&r.jsx("div",{className:O("text-xs font-medium mt-1",m.availability==="in_stock"?"text-green-600 dark:text-green-400":"text-red-600 dark:text-red-400"),children:m.availability==="in_stock"?"In Stock":"Out of Stock"})]})]},S)})}),k.length>0&&r.jsxs(r.Fragment,{children:[r.jsx("div",{className:"absolute top-1/2 -left-2 transform -translate-y-1/2 bg-white dark:bg-gray-800 rounded-full shadow-lg p-1 opacity-0 group-hover:opacity-100 transition-opacity",children:r.jsx("svg",{className:"w-4 h-4 text-gray-600 dark:text-gray-300",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:r.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M15 19l-7-7 7-7"})})}),r.jsx("div",{className:"absolute top-1/2 -right-2 transform -translate-y-1/2 bg-white dark:bg-gray-800 rounded-full shadow-lg p-1 opacity-0 group-hover:opacity-100 transition-opacity",children:r.jsx("svg",{className:"w-4 h-4 text-gray-600 dark:text-gray-300",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:r.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 5l7 7-7 7"})})})]})]}),r.jsxs("div",{className:"flex justify-between items-center mt-3 pt-2 border-t border-gray-200 dark:border-gray-700",children:[r.jsx("span",{className:"text-xs text-gray-500 dark:text-gray-400",children:"Sponsored"}),r.jsx("span",{className:"text-xs text-gray-400 dark:text-gray-500"})]}),r.jsx("style",{dangerouslySetInnerHTML:{__html:`
694
+ `;let ae=!1;const fe=()=>{y.useEffect(()=>{if(ae)return;const e=document.createElement("style");return e.id="admesh-ui-sdk-styles",e.textContent=Me,document.getElementById("admesh-ui-sdk-styles")||(document.head.appendChild(e),ae=!0),()=>{const t=document.getElementById("admesh-ui-sdk-styles");t&&document.head.contains(t)&&(document.head.removeChild(t),ae=!1)}},[])},q=(e,t={})=>{const o=e.intent_match_score||0,d=t.customLabels||{};return o>=.8?d.partnerRecommendation||"Sponsored":o>=.6?d.partnerMatch||"Partner Match":o>=.3?d.promotedOption||"Promoted":d.relatedOption||"Related"},se=(e,t)=>{const o=e.intent_match_score||0;return o>=.8?"This recommendation is from a partner who compensates us when you engage. We've matched it to your needs based on your query.":o>=.6?"Top-rated partner solution matched to your specific requirements. Partner compensates us for qualified referrals.":o>=.3?"This partner solution may be relevant to your needs. The partner compensates us when you take qualifying actions.":"This solution is somewhat related to your query. While not a perfect match, it might still be helpful. This partner compensates us for qualified referrals."},Ee=(e=!0,t=!1)=>e?t?"These curated recommendations are from partners who compensate us for referrals.":"Personalized Sponsoreds: All results are from vetted partners who compensate us for qualified matches. We've ranked them based on relevance to your specific needs.":"Expanded Results: While these don't perfectly match your query, they're related solutions from our partner network. All partners compensate us for referrals.",Pe=(e,t=!1)=>{const o=e.intent_match_score||0;return t?"Promoted":o>=.8?"Smart Recommendation":o>=.6?"Partner Match":"Promoted"},Ie=()=>"We've partnered with trusted providers to bring you relevant solutions. These partners compensate us for qualified referrals, which helps us keep our service free.",Fe=e=>({"Top Match":"Top Match",Sponsored:"Sponsored","Perfect Fit":"Perfect Fit","Great Match":"Great Match",Recommended:"Recommended","Good Fit":"Good Fit",Featured:"Featured","Popular Choice":"Popular Choice","Premium Pick":"Premium Pick","Free Tier":"Free Tier","AI Powered":"AI Powered",Popular:"Popular",New:"New","Trial Available":"Trial Available","Related Option":"Related Option","Alternative Solution":"Alternative Solution","Expanded Match":"Expanded Match"})[e]||e,Le=(e,t="button")=>{const o=e.recommendation_title||e.title;return t==="link"?o:e.trial_days&&e.trial_days>0?`Try ${o}`:"Learn More"},Oe=e=>e.some(t=>(t.intent_match_score||0)>=.8),ze=(e=!1)=>e?"":"Recommendations ",H=({recommendation:e,theme:t,showMatchScore:o=!1,showBadges:d=!0,variation:i="default",expandable:n=!1,className:s,style:l})=>{var f,T,j,k,A,z,U,$,I,D,F,m,S,R;fe();const[g,u]=y.useState(!1);y.useMemo(()=>{var W;const C=[];q(e)==="Sponsored"&&C.push("Top Match"),e.trial_days&&e.trial_days>0&&C.push("Trial Available");const N=["ai","artificial intelligence","machine learning","ml","automation"];return(((W=e.keywords)==null?void 0:W.some(E=>N.some(K=>E.toLowerCase().includes(K))))||e.title.toLowerCase().includes("ai"))&&C.push("AI Powered"),e.badges&&e.badges.length>0&&e.badges.forEach(E=>{["Top Match","Free Tier","AI Powered","Popular","New","Trial Available"].includes(E)&&!C.includes(E)&&C.push(E)}),C},[e]),Math.round(e.intent_match_score*100);const c=i==="simple"?{title:e.recommendation_title||e.title,description:e.recommendation_description||e.description||e.reason,ctaText:e.recommendation_title||e.title,isSimple:!0}:{title:e.recommendation_title||e.title,description:e.recommendation_description||e.description||e.reason,ctaText:e.recommendation_title||e.title},h=O("admesh-component","admesh-card","relative p-4 sm:p-5 rounded-xl bg-gradient-to-br from-white to-gray-50 dark:from-slate-800 dark:to-slate-900 border border-gray-200/50 dark:border-slate-700/50 shadow-lg hover:shadow-xl transition-all duration-300 hover:-translate-y-1",s),w=t?{"--admesh-primary":t.primaryColor||t.accentColor||"#3b82f6","--admesh-secondary":t.secondaryColor||"#10b981","--admesh-accent":t.accentColor||"#3b82f6","--admesh-background":t.backgroundColor,"--admesh-surface":t.surfaceColor,"--admesh-border":t.borderColor,"--admesh-text":t.textColor,"--admesh-text-secondary":t.textSecondaryColor,"--admesh-radius":t.borderRadius||"12px","--admesh-shadow-sm":(f=t.shadows)==null?void 0:f.small,"--admesh-shadow-md":(T=t.shadows)==null?void 0:T.medium,"--admesh-shadow-lg":(j=t.shadows)==null?void 0:j.large,"--admesh-spacing-sm":(k=t.spacing)==null?void 0:k.small,"--admesh-spacing-md":(A=t.spacing)==null?void 0:A.medium,"--admesh-spacing-lg":(z=t.spacing)==null?void 0:z.large,"--admesh-font-size-sm":(U=t.fontSize)==null?void 0:U.small,"--admesh-font-size-base":($=t.fontSize)==null?void 0:$.base,"--admesh-font-size-lg":(I=t.fontSize)==null?void 0:I.large,"--admesh-font-size-title":(D=t.fontSize)==null?void 0:D.title,fontFamily:t.fontFamily,width:((m=(F=t.components)==null?void 0:F.productCard)==null?void 0:m.width)||"100%"}:{width:"100%"};return i==="simple"?r.jsxs("div",{className:O("admesh-component admesh-simple-ad","inline-block text-sm leading-relaxed",s),style:{fontFamily:(t==null?void 0:t.fontFamily)||'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',...(S=t==null?void 0:t.components)==null?void 0:S.productCard,...l},"data-admesh-theme":t==null?void 0:t.mode,children:[r.jsx("span",{style:{fontSize:"11px",fontWeight:"600",color:(t==null?void 0:t.accentColor)||"#2563eb",backgroundColor:(t==null?void 0:t.mode)==="dark"?"#374151":"#f3f4f6",padding:"2px 6px",borderRadius:"4px",marginRight:"8px"},title:se(e,q(e)),children:q(e)}),r.jsxs("span",{style:{color:(t==null?void 0:t.mode)==="dark"?"#f3f4f6":"#374151",marginRight:"4px"},children:[c.description," "]}),r.jsx(J,{adId:e.ad_id,admeshLink:e.admesh_link,productId:e.product_id,trackingData:{title:e.title,matchScore:e.intent_match_score,component:"simple_ad_cta"},children:r.jsx("span",{style:{color:(t==null?void 0:t.accentColor)||"#2563eb",textDecoration:"underline",cursor:"pointer",fontSize:"inherit",fontFamily:"inherit"},children:c.ctaText})}),r.jsx("span",{style:{fontSize:"10px",color:(t==null?void 0:t.mode)==="dark"?"#9ca3af":"#6b7280",marginLeft:"8px"},children:"(Sponsored )"})]}):r.jsx("div",{className:h,style:{fontFamily:(t==null?void 0:t.fontFamily)||'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',...(R=t==null?void 0:t.components)==null?void 0:R.productCard,...l},"data-admesh-theme":t==null?void 0:t.mode,children:r.jsxs("div",{className:"h-full flex flex-col",style:w,children:[r.jsx("div",{className:"mb-3",children:r.jsx("span",{style:{fontSize:"11px",fontWeight:"600",color:(t==null?void 0:t.accentColor)||"#2563eb",backgroundColor:(t==null?void 0:t.mode)==="dark"?"#374151":"#f3f4f6",padding:"2px 6px",borderRadius:"4px"},title:se(e,q(e)),children:q(e)})}),r.jsxs("div",{className:"flex justify-between items-center gap-3 mb-4",children:[r.jsxs("div",{className:"flex items-center gap-2 flex-1 min-w-0",children:[e.product_logo&&r.jsx("img",{src:e.product_logo.url,alt:`${e.title} logo`,className:"w-6 h-6 rounded flex-shrink-0",onError:C=>{C.target.style.display="none"}}),r.jsx("h4",{className:"font-semibold text-gray-800 dark:text-gray-200 text-sm sm:text-base truncate",children:c.title})]}),r.jsx("div",{className:"flex-shrink-0",children:r.jsx(J,{adId:e.ad_id,admeshLink:e.admesh_link,productId:e.product_id,trackingData:{title:e.title,matchScore:e.intent_match_score,component:"product_card_cta"},children:r.jsxs("button",{className:"text-xs px-2 py-1 sm:px-3 sm:py-2 rounded-full bg-gradient-to-r from-purple-500 to-pink-500 text-white hover:from-purple-600 hover:to-pink-600 flex items-center transition-all duration-200 transform hover:scale-105 shadow-md hover:shadow-lg whitespace-nowrap",children:["Visit",r.jsx("svg",{className:"ml-1 h-3 w-3",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:r.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"})})]})})})]}),r.jsx("div",{className:"mb-6",children:r.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-300 leading-relaxed",children:c.description})}),e.features&&e.features.length>0&&r.jsxs("div",{className:"mb-3",children:[r.jsx("div",{className:"text-xs text-gray-600 dark:text-gray-300 mb-2 font-medium",children:"✨ Key Features"}),r.jsxs("div",{className:"flex flex-wrap gap-1.5",children:[e.features.slice(0,4).map((C,B)=>r.jsxs("span",{className:"text-xs px-2 py-1 rounded-full bg-gradient-to-r from-indigo-100 to-purple-100 dark:from-indigo-900/30 dark:to-purple-900/30 text-indigo-700 dark:text-indigo-300 border border-indigo-200 dark:border-indigo-700",children:[r.jsx("svg",{className:"h-3 w-3 mr-0.5 inline text-indigo-500",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:r.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z"})}),C]},B)),e.features.length>4&&r.jsxs("span",{className:"text-xs text-gray-500 dark:text-gray-400 px-2 py-1",children:["+",e.features.length-4," more"]})]})]}),r.jsx("div",{className:"mt-auto pt-3 border-t border-gray-100 dark:border-slate-700",children:r.jsxs("div",{className:"flex items-center justify-between text-xs text-gray-500 dark:text-gray-400",children:[r.jsx("span",{children:"Sponsored"}),r.jsx("span",{className:"text-gray-400 dark:text-gray-500"})]})})]})})};H.displayName="AdMeshProductCard";const ge=({products:e=[],recommendations:t=[],title:o="Product Recommendations",showTitle:d=!0,className:i="",cardClassName:n="",onProductClick:s,showPricing:l=!0,showRatings:g=!0,showBrand:u=!0,showSource:x=!1,showShipping:c=!0,maxCards:h=10,cardWidth:w="md",theme:f="auto",borderRadius:T="md",shadow:j="sm"})=>{const k=t.length>0?t.slice(0,h):e.slice(0,h),A=()=>{switch(w){case"sm":return"w-48 min-w-48";case"md":return"w-64 min-w-64";case"lg":return"w-80 min-w-80";default:return"w-64 min-w-64"}},z=()=>{switch(T){case"none":return"rounded-none";case"sm":return"rounded-sm";case"md":return"rounded-lg";case"lg":return"rounded-xl";default:return"rounded-lg"}},U=()=>{switch(j){case"none":return"";case"sm":return"shadow-sm hover:shadow-md";case"md":return"shadow-md hover:shadow-lg";case"lg":return"shadow-lg hover:shadow-xl";default:return"shadow-sm hover:shadow-md"}},$=()=>f==="dark"?"bg-gray-900 text-white":f==="light"?"bg-white text-gray-900":"bg-white dark:bg-gray-900 text-gray-900 dark:text-white",I=m=>new Intl.NumberFormat("en-US",{style:"currency",currency:"USD",minimumFractionDigits:0,maximumFractionDigits:2}).format(m),D=m=>{const S=[],R=Math.floor(m),C=m%1!==0;for(let N=0;N<R;N++)S.push(r.jsx("span",{className:"text-yellow-400",children:"★"},N));C&&S.push(r.jsx("span",{className:"text-yellow-400",children:"☆"},"half"));const B=5-Math.ceil(m);for(let N=0;N<B;N++)S.push(r.jsx("span",{className:"text-gray-300 dark:text-gray-600",children:"☆"},`empty-${N}`));return S},F=m=>{if(s)s(m);else{const S=m.admesh_link||m.url;S&&window.open(S,"_blank","noopener,noreferrer")}};return(!e||e.length===0)&&(!t||t.length===0)?null:r.jsxs("div",{className:O("w-full",i),children:[d&&r.jsxs("div",{className:"mb-4",children:[r.jsx("h3",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:o}),r.jsx("div",{className:"mt-1 h-0.5 w-12 bg-blue-500"})]}),r.jsxs("div",{className:"relative",children:[k.length===0?r.jsx("div",{className:"text-center py-8 text-gray-500",children:"No products to display"}):r.jsx("div",{className:"flex gap-4 overflow-x-auto pb-4 scrollbar-hide",children:k.map(m=>{var R;const S=m.product_id||m.id||m.ad_id;return r.jsxs("div",{className:O(A(),z(),U(),$(),"flex-shrink-0 border border-gray-200 dark:border-gray-700 transition-all duration-200 cursor-pointer hover:scale-[1.02]",n),onClick:()=>F(m),children:[r.jsxs("div",{className:"relative aspect-square w-full overflow-hidden",children:[m.image_url?r.jsx("img",{src:m.image_url,alt:m.title,className:"h-full w-full object-cover transition-transform duration-200 hover:scale-105",loading:"lazy"}):r.jsx("div",{className:"flex h-full w-full items-center justify-center bg-gray-100 dark:bg-gray-800",children:r.jsx("svg",{className:"h-12 w-12 text-gray-400",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:r.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"})})}),l&&m.discount_percentage&&m.discount_percentage>0&&r.jsxs("div",{className:"absolute top-2 left-2 bg-red-500 text-white text-xs font-bold px-2 py-1 rounded",children:["-",Math.round(m.discount_percentage),"%"]}),x&&m.source&&r.jsx("div",{className:"absolute top-2 right-2 bg-blue-500 text-white text-xs font-medium px-2 py-1 rounded",children:m.source.toUpperCase()})]}),r.jsxs("div",{className:"p-3",children:[u&&m.brand&&r.jsx("div",{className:"text-xs text-gray-500 dark:text-gray-400 mb-1 uppercase tracking-wide",children:m.brand}),r.jsx("h4",{className:"text-sm font-medium text-gray-900 dark:text-white line-clamp-2 mb-2 leading-tight",children:m.title}),g&&m.rating&&r.jsxs("div",{className:"flex items-center gap-1 mb-2",children:[r.jsx("div",{className:"flex text-sm",children:D(m.rating)}),r.jsxs("span",{className:"text-xs text-gray-500 dark:text-gray-400",children:["(",m.review_count||0,")"]})]}),l&&m.price&&r.jsx("div",{className:"mb-2",children:r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsx("span",{className:"text-lg font-bold text-gray-900 dark:text-white",children:I(m.price)}),m.original_price&&m.original_price>m.price&&r.jsx("span",{className:"text-sm text-gray-500 dark:text-gray-400 line-through",children:I(m.original_price)})]})}),c&&((R=m.shipping_info)==null?void 0:R.free_shipping_over_35)&&r.jsx("div",{className:"text-xs text-green-600 dark:text-green-400 font-medium",children:"Free shipping over $35"}),m.availability&&m.availability!=="unknown"&&r.jsx("div",{className:O("text-xs font-medium mt-1",m.availability==="in_stock"?"text-green-600 dark:text-green-400":"text-red-600 dark:text-red-400"),children:m.availability==="in_stock"?"In Stock":"Out of Stock"})]})]},S)})}),k.length>0&&r.jsxs(r.Fragment,{children:[r.jsx("div",{className:"absolute top-1/2 -left-2 transform -translate-y-1/2 bg-white dark:bg-gray-800 rounded-full shadow-lg p-1 opacity-0 group-hover:opacity-100 transition-opacity",children:r.jsx("svg",{className:"w-4 h-4 text-gray-600 dark:text-gray-300",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:r.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M15 19l-7-7 7-7"})})}),r.jsx("div",{className:"absolute top-1/2 -right-2 transform -translate-y-1/2 bg-white dark:bg-gray-800 rounded-full shadow-lg p-1 opacity-0 group-hover:opacity-100 transition-opacity",children:r.jsx("svg",{className:"w-4 h-4 text-gray-600 dark:text-gray-300",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:r.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 5l7 7-7 7"})})})]})]}),r.jsxs("div",{className:"flex justify-between items-center mt-3 pt-2 border-t border-gray-200 dark:border-gray-700",children:[r.jsx("span",{className:"text-xs text-gray-500 dark:text-gray-400",children:"Sponsored"}),r.jsx("span",{className:"text-xs text-gray-400 dark:text-gray-500"})]}),r.jsx("style",{dangerouslySetInnerHTML:{__html:`
695
695
  .scrollbar-hide {
696
696
  -ms-overflow-style: none;
697
697
  scrollbar-width: none;