{"version":3,"file":"InsightCard.D3hDb07m.mjs","names":["__esmMin","p","c","init_jsx_runtime","addPropertyControls","ControlType","init_framer_CKT6jEEQ","InsightCard","props","shown","cardTitle","title","href","slug","basePath","when","fmt","date","category","shortAnswer","readLabel","init_InsightCard","d"],"sources":["https:/framerusercontent.com/modules/qUHayjwrgXdiOKjHb3LE/WzKyPYqyBKJFf0NH0nxZ/InsightCard.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";/**\n * Auberique — one article card on Insights (Draft 79, slide 20).\n * Place inside the Insights Collection List and connect each property to the\n * CMS field of the same name (Category, Published date, Card title, Title,\n * Short answer). The list item links to the article; connect Slug only when\n * the card is used outside a linked list item. InsightsIndex filters these cards.\n * Hover (mouse) and keyboard focus use the Home \"Wash\" in Auberique orange\n * #FC5B04 (as polish §40): pale orange tint, a 3px orange rule drawn down the\n * left edge, orange \"Read\" arrow. All cards in the list are the same height.\n *\n * @framerSupportedLayoutWidth any-prefer-fixed\n * @framerSupportedLayoutHeight auto\n * @framerIntrinsicWidth 352\n */const fmt=d=>{if(!d)return\"\";const t=new Date(d);if(isNaN(t.getTime()))return String(d);return t.toLocaleDateString(\"en-GB\",{day:\"numeric\",month:\"short\",year:\"numeric\",timeZone:\"Asia/Singapore\"});};export default function InsightCard(props){const{category,date,cardTitle,title,shortAnswer,slug,basePath,readLabel}=props;const shown=cardTitle||title;const href=slug?`${basePath||\"/insights/\"}${slug}`:undefined;const when=fmt(date)||\"[Date]\";// Inside a Collection List the item itself links to the article, so the\n// card only becomes a link when a Slug is connected (avoids nested links).\nconst Tag=href?\"a\":\"div\";return /*#__PURE__*/_jsxs(Tag,{className:\"aub-ic\",href:href,\"data-aub-insight\":\"\",\"data-cat\":category||\"\",\"data-text\":[shown,title,shortAnswer,category].join(\" \"),children:[/*#__PURE__*/_jsx(\"style\",{dangerouslySetInnerHTML:{__html:`\n.aub-ic{box-sizing:border-box;display:flex;flex-direction:column;width:100%;height:100%;min-height:158px;padding:26px 32px 28px;background:linear-gradient(#FC5B04,#FC5B04) no-repeat 0 0/3px 0%,#FFFFFF;box-shadow:inset 0 0 0 1px #E6E1D7;border-radius:2px;text-decoration:none;color:#1A1918;font-family:Inter,system-ui,sans-serif;transition:background-size .4s cubic-bezier(.2,.7,.2,1),background-color .3s ease,box-shadow .2s ease}\n.aub-ic .top{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:10px 16px}\n.aub-ic .tag{display:inline-flex;align-items:center;height:28px;padding:0 20px;box-shadow:inset 0 0 0 1px #B8860B;font:600 11px/1 Inter,system-ui,sans-serif;letter-spacing:.04em;text-transform:uppercase;color:#1A1918;white-space:nowrap}\n.aub-ic .date{font:500 11px/1 Inter,system-ui,sans-serif;letter-spacing:.12em;text-transform:uppercase;color:#4A4640;white-space:nowrap;font-variant-numeric:tabular-nums}\n.aub-ic h3{margin:18px 0 0;font:400 22px/1.25 \"EB Garamond\",Georgia,serif;color:#1A1918}\n.aub-ic .read{margin-top:auto;padding-top:22px;font:600 15px/1 Inter,system-ui,sans-serif;color:#1A1918;display:inline-flex;gap:10px;align-items:center}\n.aub-ic .read i{font-style:normal;transition:transform .2s ease,color .3s ease}\n@media (hover:hover){\n.aub-ic:hover{background-size:3px 100%;background-color:#FFF4ED}\n.aub-ic:hover .read i{color:#FC5B04;transform:translateX(3px)}\n}\n.aub-ic:focus-visible,a:focus-visible .aub-ic{outline:2px solid #FC5B04;outline-offset:-2px;background-size:3px 100%;background-color:#FFF4ED}\n.aub-ic:focus-visible .read i,a:focus-visible .aub-ic .read i{color:#FC5B04}\n@media (prefers-reduced-motion:reduce){.aub-ic,.aub-ic .read i{transition:none}}\n/* Equal tiles: the Collection List item and Framer's wrapper stretch to the grid row, so every card is the same height */\n:has(> * > .aub-ic){align-self:stretch!important;height:auto!important}\n:has(> .aub-ic){flex:1 1 auto!important;align-self:stretch!important;height:auto!important}\n`}}),/*#__PURE__*/_jsxs(\"div\",{className:\"top\",children:[category?/*#__PURE__*/_jsx(\"span\",{className:\"tag\",children:category}):/*#__PURE__*/_jsx(\"span\",{}),/*#__PURE__*/_jsx(\"span\",{className:\"date\",children:when})]}),/*#__PURE__*/_jsx(\"h3\",{children:shown||\"[TBC: Bertin] Title\"}),/*#__PURE__*/_jsxs(\"span\",{className:\"read\",children:[readLabel,\" \",/*#__PURE__*/_jsx(\"i\",{\"aria-hidden\":\"true\",children:\"→\"})]})]});}InsightCard.defaultProps={category:\"Investment funds\",cardTitle:\"Ring-fencing sub-funds\",title:\"\",shortAnswer:\"\",slug:\"\",basePath:\"/insights/\",readLabel:\"Read\"};addPropertyControls(InsightCard,{category:{type:ControlType.String,title:\"Category\"},date:{type:ControlType.Date,title:\"Published date\"},cardTitle:{type:ControlType.String,title:\"Card title\"},title:{type:ControlType.String,title:\"Title\"},shortAnswer:{type:ControlType.String,title:\"Short answer\"},slug:{type:ControlType.String,title:\"Slug\"},basePath:{type:ControlType.String,title:\"Base path\"},readLabel:{type:ControlType.String,title:\"Read label\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"InsightCard\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./InsightCard.map"],"mappings":"A,mKAayM,SAAwBO,EAAY,EAAM,CAAC,GAAK,CAAC,WAAS,OAAK,YAAU,QAAM,cAAY,OAAK,WAAS,aAAWC,EAAYC,EAAMC,GAAWC,EAAYC,EAAKC,EAAK,GAAGC,GAAU,eAAeD,IAAO,IAAA,GAAgBE,EAAKC,EAAIC,CAAI,GAAG,SAE1Z,MAAoB,gBAAnCL,EAAK,IAAI,MAAoC,CAAC,UAAU,SAAc,OAAK,mBAAmB,GAAG,WAAWM,GAAU,GAAG,YAAY,CAACT,EAAME,EAAMQ,EAAYD,CAAQ,CAAC,CAAC,KAAK,GAAG,EAAE,SAAS,CAAc,gBAAK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