cortex-react-components 2.4.1 → 2.5.1

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.
Files changed (174) hide show
  1. package/dist/chunk-2CS6P44F.mjs +4 -0
  2. package/dist/{chunk-UJSXVIXW.mjs → chunk-2R2QNFSX.mjs} +1 -1
  3. package/dist/chunk-34AVYSEY.mjs +4 -0
  4. package/dist/{chunk-5MWZTJYP.mjs → chunk-3GYD63ZU.mjs} +1 -1
  5. package/dist/{chunk-LW4QFIFR.mjs → chunk-3PHJWI4Q.mjs} +1 -1
  6. package/dist/{chunk-B2EJGXDG.mjs → chunk-4RYG24IZ.mjs} +1 -1
  7. package/dist/{chunk-IPIDKLAW.mjs → chunk-53FA54L3.mjs} +1 -1
  8. package/dist/{chunk-ECXVQZBN.mjs → chunk-5RDLHKTK.mjs} +1 -1
  9. package/dist/{chunk-3HNU2NYP.mjs → chunk-5ZAEFDWB.mjs} +1 -1
  10. package/dist/chunk-A3YDFYEB.mjs +1 -0
  11. package/dist/{chunk-C4RWEPVF.mjs → chunk-AUYUGOC2.mjs} +1 -1
  12. package/dist/{chunk-WIRQ5IRT.mjs → chunk-BZ2WQV4P.mjs} +1 -1
  13. package/dist/{chunk-LAQ3QAUW.mjs → chunk-CLGBBNRB.mjs} +1 -1
  14. package/dist/{chunk-INPV5MBU.mjs → chunk-E64KWNOT.mjs} +1 -1
  15. package/dist/{chunk-AJQHGVZ5.mjs → chunk-FBL3GXOL.mjs} +1 -1
  16. package/dist/{chunk-7R47MHQE.mjs → chunk-FJJXYLRH.mjs} +1 -1
  17. package/dist/{chunk-RGOKBIQ5.mjs → chunk-GP4TAG4X.mjs} +1 -1
  18. package/dist/{chunk-RJGYVDOU.mjs → chunk-GQ7ONZTM.mjs} +1 -1
  19. package/dist/{chunk-XBCYPOFD.mjs → chunk-GTK2SGS5.mjs} +1 -1
  20. package/dist/chunk-HPYNP5UQ.mjs +1 -0
  21. package/dist/{chunk-2BRDNDUB.mjs → chunk-I2KSLUQI.mjs} +1 -1
  22. package/dist/{chunk-ISBVFNWD.mjs → chunk-IDG2O4B7.mjs} +1 -1
  23. package/dist/{chunk-7HR6FNWF.mjs → chunk-IHPO27W4.mjs} +1 -1
  24. package/dist/chunk-J3UUZDJ7.mjs +1 -0
  25. package/dist/{chunk-GTZJWMZR.mjs → chunk-JZZS5W5F.mjs} +1 -1
  26. package/dist/{chunk-KWYJ3XZI.mjs → chunk-LIVFM3OH.mjs} +1 -1
  27. package/dist/{chunk-ATIEKI6M.mjs → chunk-O4GULNQE.mjs} +1 -1
  28. package/dist/{chunk-O5P35LEY.mjs → chunk-PXLSH6S2.mjs} +1 -1
  29. package/dist/{chunk-2SAKLSZ4.mjs → chunk-PZXOH6CZ.mjs} +1 -1
  30. package/dist/{chunk-3NRXQBBS.mjs → chunk-Q6IE534E.mjs} +1 -1
  31. package/dist/{chunk-TXVA6XJT.mjs → chunk-SRUG246N.mjs} +1 -1
  32. package/dist/{chunk-75F3LJMX.mjs → chunk-SWECU7TM.mjs} +1 -1
  33. package/dist/{chunk-M4UVNIK2.mjs → chunk-TN56JEUK.mjs} +1 -1
  34. package/dist/{chunk-BKR3FRMQ.mjs → chunk-U3F45KVI.mjs} +1 -1
  35. package/dist/{chunk-NINFDOV5.mjs → chunk-ULEGY3LW.mjs} +1 -1
  36. package/dist/{chunk-VR5WOPRD.mjs → chunk-URYIYEGY.mjs} +1 -1
  37. package/dist/{chunk-X3JZSN3W.mjs → chunk-UZSBX5GO.mjs} +1 -1
  38. package/dist/{chunk-GHOL5L32.mjs → chunk-VH6OVYYB.mjs} +1 -1
  39. package/dist/{chunk-XGIYNUGC.mjs → chunk-VNYUNZ3M.mjs} +1 -1
  40. package/dist/{chunk-2BR55L74.mjs → chunk-VRE6VCHX.mjs} +1 -1
  41. package/dist/{chunk-R75OR5VS.mjs → chunk-W4UCTPLC.mjs} +1 -1
  42. package/dist/{chunk-FE7ZGUPU.mjs → chunk-WSI4B2MA.mjs} +1 -1
  43. package/dist/{chunk-L3BLBPSR.mjs → chunk-WUA65ZZB.mjs} +1 -1
  44. package/dist/chunk-WY2CT5AT.mjs +1 -0
  45. package/dist/{chunk-7VDNUJZC.mjs → chunk-XIGBDWYI.mjs} +1 -1
  46. package/dist/chunk-XKM35QQD.mjs +4 -0
  47. package/dist/{chunk-VWLPVN4M.mjs → chunk-XW52WZ2B.mjs} +1 -1
  48. package/dist/{chunk-OQYER4E7.mjs → chunk-YQWQFS72.mjs} +1 -1
  49. package/dist/{chunk-CXOVEABI.mjs → chunk-Z57EE3LL.mjs} +1 -1
  50. package/dist/chunk-Z72RUYUU.mjs +1 -0
  51. package/dist/{chunk-6MSM3CZ6.mjs → chunk-ZI4KMPQF.mjs} +1 -1
  52. package/dist/components/Blocks/Banner.mjs +1 -1
  53. package/dist/components/Blocks/CallToAction.mjs +1 -1
  54. package/dist/components/Blocks/CollapsibleArea.mjs +1 -1
  55. package/dist/components/Blocks/Content.mjs +1 -1
  56. package/dist/components/Blocks/FeaturesBlock.mjs +1 -1
  57. package/dist/components/Blocks/ImageBlock.mjs +1 -1
  58. package/dist/components/Blocks/MediaBlock.mjs +1 -1
  59. package/dist/components/Blocks/RelatedPosts.mjs +1 -1
  60. package/dist/components/Blocks/RenderBlocks.mjs +1 -1
  61. package/dist/components/Blocks/ReusableContentBlock.mjs +1 -1
  62. package/dist/components/Blocks/index.mjs +1 -1
  63. package/dist/components/CRM/index.mjs +1 -1
  64. package/dist/components/Cards/ContentCard.mjs +1 -1
  65. package/dist/components/Cards/FeatureCard.mjs +1 -1
  66. package/dist/components/Cards/index.mjs +1 -1
  67. package/dist/components/Chat/demo-tests.css +1 -0
  68. package/dist/components/Chat/demo-tests.d.ts +10 -0
  69. package/dist/components/Chat/demo-tests.js +639 -0
  70. package/dist/components/Chat/demo-tests.mjs +635 -0
  71. package/dist/components/DigitalColleagues/AppSidebarLeft.mjs +1 -1
  72. package/dist/components/DigitalColleagues/MainPage.mjs +1 -1
  73. package/dist/components/DigitalColleagues/ManagementSidebar.mjs +1 -1
  74. package/dist/components/DigitalColleagues/Pages/dashboardpage.js +1 -1
  75. package/dist/components/DigitalColleagues/Pages/dashboardpage.mjs +1 -1
  76. package/dist/components/DigitalColleagues/Views/ColleaguesView.mjs +1 -1
  77. package/dist/components/DigitalColleagues/Views/KnowledgeView.js +1 -1
  78. package/dist/components/DigitalColleagues/Views/KnowledgeView.mjs +1 -1
  79. package/dist/components/DigitalColleagues/Views/index.d.ts +1 -0
  80. package/dist/components/DigitalColleagues/Views/index.js +1 -1
  81. package/dist/components/DigitalColleagues/Views/index.mjs +1 -1
  82. package/dist/components/DigitalColleagues/document-edit.js +1 -1
  83. package/dist/components/DigitalColleagues/document-edit.mjs +1 -1
  84. package/dist/components/DigitalColleagues/document-preview-examples.js +5 -5
  85. package/dist/components/DigitalColleagues/document-preview-examples.mjs +1 -1
  86. package/dist/components/DigitalColleagues/document-preview.js +1 -1
  87. package/dist/components/DigitalColleagues/document-preview.mjs +1 -1
  88. package/dist/components/DigitalColleagues/index.js +1 -1
  89. package/dist/components/DigitalColleagues/index.mjs +1 -1
  90. package/dist/components/DigitalColleagues/knowledge-browser.js +1 -1
  91. package/dist/components/DigitalColleagues/knowledge-browser.mjs +1 -1
  92. package/dist/components/HeaderFooter/Header.mjs +1 -1
  93. package/dist/components/HeaderFooter/HeaderDesktop.mjs +1 -1
  94. package/dist/components/HeaderFooter/SectionHeading.mjs +1 -1
  95. package/dist/components/HeaderFooter/index.mjs +1 -1
  96. package/dist/components/Heros/HighImpact/index.mjs +1 -1
  97. package/dist/components/Heros/LowImpact/index.mjs +1 -1
  98. package/dist/components/Heros/MediumImpact/index.mjs +1 -1
  99. package/dist/components/Heros/PostHero/index.mjs +1 -1
  100. package/dist/components/Heros/RenderHero.mjs +1 -1
  101. package/dist/components/Heros/index.mjs +1 -1
  102. package/dist/components/Layouts/OutputHeaderFooter.mjs +1 -1
  103. package/dist/components/Layouts/Print.mjs +1 -1
  104. package/dist/components/Layouts/SlideShow.mjs +1 -1
  105. package/dist/components/Layouts/index.mjs +1 -1
  106. package/dist/components/Menus/SidebarLeft.mjs +1 -1
  107. package/dist/components/Menus/SidebarRight.mjs +1 -1
  108. package/dist/components/Menus/index.mjs +1 -1
  109. package/dist/components/Payload/Card/index.mjs +1 -1
  110. package/dist/components/Payload/CollectionArchive/index.mjs +1 -1
  111. package/dist/components/Payload/Media/index.mjs +1 -1
  112. package/dist/components/Payload/RichText/index.mjs +1 -1
  113. package/dist/components/Payload/RichText/serialize.mjs +1 -1
  114. package/dist/components/Payload/index.mjs +1 -1
  115. package/dist/components/Projects/AddTaskModal.js +1 -1
  116. package/dist/components/Projects/AddTaskModal.mjs +1 -1
  117. package/dist/components/Projects/FileView.d.ts +2 -2
  118. package/dist/components/Projects/FileView.js +2 -2
  119. package/dist/components/Projects/FileView.mjs +1 -1
  120. package/dist/components/Projects/KanbanBoardView.js +1 -1
  121. package/dist/components/Projects/KanbanBoardView.mjs +1 -1
  122. package/dist/components/Projects/PlanningView.js +1 -1
  123. package/dist/components/Projects/PlanningView.mjs +1 -1
  124. package/dist/components/Projects/ProjectPage.js +1 -1
  125. package/dist/components/Projects/ProjectPage.mjs +1 -1
  126. package/dist/components/Projects/ProjectView.d.ts +4 -4
  127. package/dist/components/Projects/ProjectView.js +1 -1
  128. package/dist/components/Projects/ProjectView.mjs +1 -1
  129. package/dist/components/Projects/ProjectsIndexView.mjs +1 -1
  130. package/dist/components/Projects/TasksView.js +1 -1
  131. package/dist/components/Projects/TasksView.mjs +1 -1
  132. package/dist/components/Projects/file-list.d.ts +2 -2
  133. package/dist/components/Projects/file-list.js +1 -1
  134. package/dist/components/Projects/file-list.mjs +1 -1
  135. package/dist/components/dc-temp/index.js +1 -1
  136. package/dist/components/dc-temp/index.mjs +1 -1
  137. package/dist/components/index.js +11 -11
  138. package/dist/components/index.mjs +1 -1
  139. package/dist/components/ui/index.mjs +1 -1
  140. package/dist/components/ui/sidebar.mjs +1 -1
  141. package/dist/globals.css +1 -1
  142. package/dist/index.js +15 -15
  143. package/dist/index.mjs +1 -1
  144. package/dist/metafile-cjs.json +1 -1
  145. package/dist/metafile-esm.json +1 -1
  146. package/dist/pages/Blog.mjs +1 -1
  147. package/dist/pages/Documentation.mjs +1 -1
  148. package/dist/pages/IndexPage.mjs +1 -1
  149. package/dist/pages/Intranet.mjs +1 -1
  150. package/dist/pages/LandingPage.mjs +1 -1
  151. package/dist/pages/Page.mjs +1 -1
  152. package/dist/pages/Publish.mjs +1 -1
  153. package/dist/pages/Website.mjs +1 -1
  154. package/dist/sections/AboutSection.mjs +1 -1
  155. package/dist/sections/BlogDetail.mjs +1 -1
  156. package/dist/sections/BlogList.mjs +1 -1
  157. package/dist/sections/BlogListSection.mjs +1 -1
  158. package/dist/sections/ContactSection.mjs +1 -1
  159. package/dist/sections/PageSections.mjs +1 -1
  160. package/dist/sections/PricingSection.mjs +1 -1
  161. package/dist/sections/ServiceDetail.mjs +1 -1
  162. package/dist/sections/ServiceDetailSection.mjs +1 -1
  163. package/dist/sections/ServiceSection.mjs +1 -1
  164. package/dist/sections/form/index.mjs +1 -1
  165. package/dist/sections/index.mjs +1 -1
  166. package/package.json +7 -6
  167. package/dist/chunk-2VZWOBGP.mjs +0 -1
  168. package/dist/chunk-3U3PZBHQ.mjs +0 -4
  169. package/dist/chunk-553B5H2H.mjs +0 -4
  170. package/dist/chunk-AQZEZ3UR.mjs +0 -1
  171. package/dist/chunk-DKVCSRUJ.mjs +0 -1
  172. package/dist/chunk-FV3W3WL7.mjs +0 -4
  173. package/dist/chunk-NZS3XKXU.mjs +0 -1
  174. package/dist/chunk-PXPSM7OQ.mjs +0 -1
@@ -0,0 +1,639 @@
1
+ "use client";
2
+ "use strict";
3
+ 'use client'
4
+
5
+ "use strict";var po=Object.create;var mt=Object.defineProperty;var mo=Object.getOwnPropertyDescriptor;var uo=Object.getOwnPropertyNames;var go=Object.getPrototypeOf,fo=Object.prototype.hasOwnProperty;var ho=(e,t)=>{for(var a in t)mt(e,a,{get:t[a],enumerable:!0})},Yt=(e,t,a,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let l of uo(t))!fo.call(e,l)&&l!==a&&mt(e,l,{get:()=>t[l],enumerable:!(o=mo(t,l))||o.enumerable});return e};var J=(e,t,a)=>(a=e!=null?po(go(e)):{},Yt(t||!e||!e.__esModule?mt(a,"default",{value:e,enumerable:!0}):a,e)),bo=e=>Yt(mt({},"__esModule",{value:!0}),e);var xi={};ho(xi,{ChatDemoCapabilitiesInteraction:()=>yi,ChatDemoErrorHandling:()=>vi,ChatDemoFileUploads:()=>bi,ChatDemoMarkdownResponses:()=>fi,ChatDemoToolCalling:()=>gi,ChatDemoUIComponents:()=>hi});module.exports=bo(xi);var Ke=require("react");var Ya=require("@ai-sdk/react"),Tt=require("framer-motion"),Za=require("lucide-react");var na=require("clsx");var Ut="-",vo=e=>{let t=xo(e),{conflictingClassGroups:a,conflictingClassGroupModifiers:o}=e;return{getClassGroupId:c=>{let r=c.split(Ut);return r[0]===""&&r.length!==1&&r.shift(),ta(r,t)||yo(c)},getConflictingClassGroupIds:(c,r)=>{let u=a[c]||[];return r&&o[c]?[...u,...o[c]]:u}}},ta=(e,t)=>{if(e.length===0)return t.classGroupId;let a=e[0],o=t.nextPart.get(a),l=o?ta(e.slice(1),o):void 0;if(l)return l;if(t.validators.length===0)return;let s=e.join(Ut);return t.validators.find(({validator:c})=>c(s))?.classGroupId},Zt=/^\[(.+)\]$/,yo=e=>{if(Zt.test(e)){let t=Zt.exec(e)[1],a=t?.substring(0,t.indexOf(":"));if(a)return"arbitrary.."+a}},xo=e=>{let{theme:t,prefix:a}=e,o={nextPart:new Map,validators:[]};return Co(Object.entries(e.classGroups),a).forEach(([s,c])=>{Mt(c,o,s,t)}),o},Mt=(e,t,a,o)=>{e.forEach(l=>{if(typeof l=="string"){let s=l===""?t:ea(t,l);s.classGroupId=a;return}if(typeof l=="function"){if(wo(l)){Mt(l(o),t,a,o);return}t.validators.push({validator:l,classGroupId:a});return}Object.entries(l).forEach(([s,c])=>{Mt(c,ea(t,s),a,o)})})},ea=(e,t)=>{let a=e;return t.split(Ut).forEach(o=>{a.nextPart.has(o)||a.nextPart.set(o,{nextPart:new Map,validators:[]}),a=a.nextPart.get(o)}),a},wo=e=>e.isThemeGetter,Co=(e,t)=>t?e.map(([a,o])=>{let l=o.map(s=>typeof s=="string"?t+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([c,r])=>[t+c,r])):s);return[a,l]}):e,No=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,a=new Map,o=new Map,l=(s,c)=>{a.set(s,c),t++,t>e&&(t=0,o=a,a=new Map)};return{get(s){let c=a.get(s);if(c!==void 0)return c;if((c=o.get(s))!==void 0)return l(s,c),c},set(s,c){a.has(s)?a.set(s,c):l(s,c)}}},aa="!",ko=e=>{let{separator:t,experimentalParseClassName:a}=e,o=t.length===1,l=t[0],s=t.length,c=r=>{let u=[],m=0,R=0,b;for(let x=0;x<r.length;x++){let S=r[x];if(m===0){if(S===l&&(o||r.slice(x,x+s)===t)){u.push(r.slice(R,x)),R=x+s;continue}if(S==="/"){b=x;continue}}S==="["?m++:S==="]"&&m--}let N=u.length===0?r:r.substring(R),D=N.startsWith(aa),_=D?N.substring(1):N,k=b&&b>R?b-R:void 0;return{modifiers:u,hasImportantModifier:D,baseClassName:_,maybePostfixModifierPosition:k}};return a?r=>a({className:r,parseClassName:c}):c},Do=e=>{if(e.length<=1)return e;let t=[],a=[];return e.forEach(o=>{o[0]==="["?(t.push(...a.sort(),o),a=[]):a.push(o)}),t.push(...a.sort()),t},So=e=>({cache:No(e.cacheSize),parseClassName:ko(e),...vo(e)}),Po=/\s+/,Ro=(e,t)=>{let{parseClassName:a,getClassGroupId:o,getConflictingClassGroupIds:l}=t,s=[],c=e.trim().split(Po),r="";for(let u=c.length-1;u>=0;u-=1){let m=c[u],{modifiers:R,hasImportantModifier:b,baseClassName:N,maybePostfixModifierPosition:D}=a(m),_=!!D,k=o(_?N.substring(0,D):N);if(!k){if(!_){r=m+(r.length>0?" "+r:r);continue}if(k=o(N),!k){r=m+(r.length>0?" "+r:r);continue}_=!1}let x=Do(R).join(":"),S=b?x+aa:x,I=S+k;if(s.includes(I))continue;s.push(I);let C=l(k,_);for(let z=0;z<C.length;++z){let oe=C[z];s.push(S+oe)}r=m+(r.length>0?" "+r:r)}return r};function To(){let e=0,t,a,o="";for(;e<arguments.length;)(t=arguments[e++])&&(a=oa(t))&&(o&&(o+=" "),o+=a);return o}var oa=e=>{if(typeof e=="string")return e;let t,a="";for(let o=0;o<e.length;o++)e[o]&&(t=oa(e[o]))&&(a&&(a+=" "),a+=t);return a};function Ao(e,...t){let a,o,l,s=c;function c(u){let m=t.reduce((R,b)=>b(R),e());return a=So(m),o=a.cache.get,l=a.cache.set,s=r,r(u)}function r(u){let m=o(u);if(m)return m;let R=Ro(u,a);return l(u,R),R}return function(){return s(To.apply(null,arguments))}}var L=e=>{let t=a=>a[e]||[];return t.isThemeGetter=!0,t},ia=/^\[(?:([a-z-]+):)?(.+)\]$/ca,Io=/^\d+\/\d+$/,Mo=new Set(["px","full","screen"]),Uo=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Eo=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|ca|ca|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Bo=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,zo=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,_o=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Se=e=>qe(e)||Mo.has(e)||Io.test(e),Me=e=>Je(e,"length",Vo),qe=e=>!!e&&!Number.isNaN(Number(e)),It=e=>Je(e,"number",qe),at=e=>!!e&&Number.isInteger(Number(e)),Lo=e=>e.endsWith("%")&&qe(e.slice(0,-1)),v=e=>ia.test(e),Ue=e=>Uo.test(e),Fo=new Set(["length","size","percentage"]),jo=e=>Je(e,Fo,ra),Ho=e=>Je(e,"position",ra),Oo=new Set(["image","url"]),Go=e=>Je(e,Oo,Ko),Wo=e=>Je(e,"",$o),ot=()=>!0,Je=(e,t,a)=>{let o=ia.exec(e);return o?o[1]?typeof t=="string"?o[1]===t:t.has(o[1]):a(o[2]):!1},Vo=e=>Eo.test(e)&&!Bo.test(e),ra=()=>!1,$o=e=>zo.test(e),Ko=e=>_o.test(e);var qo=()=>{let e=L("colors"),t=L("spacing"),a=L("blur"),o=L("brightness"),l=L("borderColor"),s=L("borderRadius"),c=L("borderSpacing"),r=L("borderWidth"),u=L("contrast"),m=L("grayscale"),R=L("hueRotate"),b=L("invert"),N=L("gap"),D=L("gradientColorStops"),_=L("gradientColorStopPositions"),k=L("inset"),x=L("margin"),S=L("opacity"),I=L("padding"),C=L("saturate"),z=L("scale"),oe=L("sepia"),K=L("skew"),ee=L("space"),W=L("translate"),q=()=>["auto","contain","none"],X=()=>["auto","hidden","clip","visible","scroll"],ie=()=>["auto",v,t],U=()=>[v,t],ke=()=>["",Se,Me],d=()=>["auto",qe,v],E=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],T=()=>["solid","dashed","dotted","double","none"],p=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],A=()=>["start","end","center","between","around","evenly","stretch"],H=()=>["","0",v],se=()=>["auto","avoid","all","avoid-page","page","left","right","column"],O=()=>[qe,v];return{cacheSize:500,separator:":",theme:{colors:[ot],spacing:[Se,Me],blur:["none","",Ue,v],brightness:O(),borderColor:[e],borderRadius:["none","","full",Ue,v],borderSpacing:U(),borderWidth:ke(),contrast:O(),grayscale:H(),hueRotate:O(),invert:H(),gap:U(),gradientColorStops:[e],gradientColorStopPositions:[Lo,Me],inset:ie(),margin:ie(),opacity:O(),padding:U(),saturate:O(),scale:O(),sepia:H(),skew:O(),space:U(),translate:U()},classGroups:{aspect:[{aspect:["auto","square","video",v]}],container:["container"],columns:[{columns:[Ue]}],"break-after":[{"break-after":se()}],"break-before":[{"break-before":se()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...E(),v]}],overflow:[{overflow:X()}],"overflow-x":[{"overflow-x":X()}],"overflow-ca":[{"overflow-ca":X()}],overscroll:[{overscroll:q()}],"overscroll-x":[{"overscroll-x":q()}],"overscroll-ca":[{"overscroll-ca":q()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[k]}],"inset-x":[{"inset-x":[k]}],"inset-ca":[{"inset-ca":[k]}],start:[{start:[k]}],end:[{end:[k]}],top:[{top:[k]}],right:[{right:[k]}],bottom:[{bottom:[k]}],left:[{left:[k]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",at,v]}],basis:[{basis:ie()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",v]}],grow:[{grow:H()}],shrink:[{shrink:H()}],order:[{order:["first","last","none",at,v]}],"grid-cols":[{"grid-cols":[ot]}],"col-start-end":[{col:["auto",{span:["full",at,v]},v]}],"col-start":[{"col-start":d()}],"col-end":[{"col-end":d()}],"grid-rows":[{"grid-rows":[ot]}],"row-start-end":[{row:["auto",{span:[at,v]},v]}],"row-start":[{"row-start":d()}],"row-end":[{"row-end":d()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",v]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",v]}],gap:[{gap:[N]}],"gap-x":[{"gap-x":[N]}],"gap-ca":[{"gap-ca":[N]}],"justify-content":[{justify:["normal",...A()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...A(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...A(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[I]}],px:[{px:[I]}],py:[{py:[I]}],ps:[{ps:[I]}],ca:[{ca:[I]}],pt:[{pt:[I]}],pr:[{pr:[I]}],pb:[{pb:[I]}],pl:[{pl:[I]}],m:[{m:[x]}],mx:[{mx:[x]}],my:[{my:[x]}],ms:[{ms:[x]}],me:[{me:[x]}],mt:[{mt:[x]}],mr:[{mr:[x]}],mb:[{mb:[x]}],ml:[{ml:[x]}],"space-x":[{"space-x":[ee]}],"space-x-reverse":["space-x-reverse"],"space-ca":[{"space-ca":[ee]}],"space-ca-reverse":["space-ca-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",v,t]}],"min-w":[{"min-w":[v,t,"min","max","fit"]}],"max-w":[{"max-w":[v,t,"none","full","min","max","fit","prose",{screen:[Ue]},Ue]}],ca:[{ca:[v,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-ca":[{"min-ca":[v,t,"min","max","fit","svh","lvh","dvh"]}],"max-ca":[{"max-ca":[v,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[v,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Ue,Me]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",It]}],"font-family":[{font:[ot]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",v]}],"line-clamp":[{"line-clamp":["none",qe,It]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Se,v]}],"list-image":[{"list-image":["none",v]}],"list-style-type":[{list:["none","disc","decimal",v]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[S]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[S]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...T(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Se,Me]}],"underline-offset":[{"underline-offset":["auto",Se,v]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:U()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",v]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",v]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[S]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...E(),Ho]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","ca","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",jo]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Go]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[_]}],"gradient-via-pos":[{via:[_]}],"gradient-to-pos":[{to:[_]}],"gradient-from":[{from:[D]}],"gradient-via":[{via:[D]}],"gradient-to":[{to:[D]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-ee":[{"rounded-ee":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tl":[{"rounded-tl":[s]}],"rounded-tr":[{"rounded-tr":[s]}],"rounded-br":[{"rounded-br":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[r]}],"border-w-x":[{"border-x":[r]}],"border-w-ca":[{"border-ca":[r]}],"border-w-s":[{"border-s":[r]}],"border-w-e":[{"border-e":[r]}],"border-w-t":[{"border-t":[r]}],"border-w-r":[{"border-r":[r]}],"border-w-b":[{"border-b":[r]}],"border-w-l":[{"border-l":[r]}],"border-opacity":[{"border-opacity":[S]}],"border-style":[{border:[...T(),"hidden"]}],"divide-x":[{"divide-x":[r]}],"divide-x-reverse":["divide-x-reverse"],"divide-ca":[{"divide-ca":[r]}],"divide-ca-reverse":["divide-ca-reverse"],"divide-opacity":[{"divide-opacity":[S]}],"divide-style":[{divide:T()}],"border-color":[{border:[l]}],"border-color-x":[{"border-x":[l]}],"border-color-ca":[{"border-ca":[l]}],"border-color-s":[{"border-s":[l]}],"border-color-e":[{"border-e":[l]}],"border-color-t":[{"border-t":[l]}],"border-color-r":[{"border-r":[l]}],"border-color-b":[{"border-b":[l]}],"border-color-l":[{"border-l":[l]}],"divide-color":[{divide:[l]}],"outline-style":[{outline:["",...T()]}],"outline-offset":[{"outline-offset":[Se,v]}],"outline-w":[{outline:[Se,Me]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:ke()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[S]}],"ring-offset-w":[{"ring-offset":[Se,Me]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Ue,Wo]}],"shadow-color":[{shadow:[ot]}],opacity:[{opacity:[S]}],"mix-blend":[{"mix-blend":[...p(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":p()}],filter:[{filter:["","none"]}],blur:[{blur:[a]}],brightness:[{brightness:[o]}],contrast:[{contrast:[u]}],"drop-shadow":[{"drop-shadow":["","none",Ue,v]}],grayscale:[{grayscale:[m]}],"hue-rotate":[{"hue-rotate":[R]}],invert:[{invert:[b]}],saturate:[{saturate:[C]}],sepia:[{sepia:[oe]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[a]}],"backdrop-brightness":[{"backdrop-brightness":[o]}],"backdrop-contrast":[{"backdrop-contrast":[u]}],"backdrop-grayscale":[{"backdrop-grayscale":[m]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[R]}],"backdrop-invert":[{"backdrop-invert":[b]}],"backdrop-opacity":[{"backdrop-opacity":[S]}],"backdrop-saturate":[{"backdrop-saturate":[C]}],"backdrop-sepia":[{"backdrop-sepia":[oe]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[c]}],"border-spacing-x":[{"border-spacing-x":[c]}],"border-spacing-ca":[{"border-spacing-ca":[c]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",v]}],duration:[{duration:O()}],ease:[{ease:["linear","in","out","in-out",v]}],delay:[{delay:O()}],animate:[{animate:["none","spin","ping","pulse","bounce",v]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[z]}],"scale-x":[{"scale-x":[z]}],"scale-ca":[{"scale-ca":[z]}],rotate:[{rotate:[at,v]}],"translate-x":[{"translate-x":[W]}],"translate-ca":[{"translate-ca":[W]}],"skew-x":[{"skew-x":[K]}],"skew-ca":[{"skew-ca":[K]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",v]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",v]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","ca","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":U()}],"scroll-mx":[{"scroll-mx":U()}],"scroll-my":[{"scroll-my":U()}],"scroll-ms":[{"scroll-ms":U()}],"scroll-me":[{"scroll-me":U()}],"scroll-mt":[{"scroll-mt":U()}],"scroll-mr":[{"scroll-mr":U()}],"scroll-mb":[{"scroll-mb":U()}],"scroll-ml":[{"scroll-ml":U()}],"scroll-p":[{"scroll-p":U()}],"scroll-px":[{"scroll-px":U()}],"scroll-py":[{"scroll-py":U()}],"scroll-ps":[{"scroll-ps":U()}],"scroll-ca":[{"scroll-ca":U()}],"scroll-pt":[{"scroll-pt":U()}],"scroll-pr":[{"scroll-pr":U()}],"scroll-pb":[{"scroll-pb":U()}],"scroll-pl":[{"scroll-pl":U()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","ca","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-ca":[{"touch-pan":["ca","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",v]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Se,Me,It]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-ca"],overscroll:["overscroll-x","overscroll-ca"],inset:["inset-x","inset-ca","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-ca":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-ca"],p:["px","py","ps","ca","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","ca"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-ca"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-ca":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-ca":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-ca","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-ca","touch-pz"],"touch-x":["touch"],"touch-ca":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}};var sa=Ao(qo);function n(...e){return sa((0,na.clsx)(e))}var xt=J(require("react")),jt=J(require("next/link"));var la=require("class-variance-authority");var ca=require("react/jsx-runtime"),Jo=(0,la.cva)("inline-flex items-center rounded-md border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground shadow hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground shadow hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});function ce({className:e,variant:t,...a}){return(0,ca.jsx)("div",{className:n(Jo({variant:t}),e),...a})}var da=require("@radix-ui/react-slot"),ma=J(require("react")),Qo=(0,la.cva)("inline-flex items-center justify-center whitespace-nowrap rounded text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{defaultVariants:{size:"default",variant:"default"},variants:{size:{clear:"",default:"ca-10 px-4 py-2",icon:"ca-10 w-10",lg:"ca-11 rounded px-8",sm:"ca-9 rounded px-3"},variant:{default:"bg-accent text-accent-foreground hover:bg-background hover:text-accent hover:border-accent hover:border",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",ghost:"hover:bg-card hover:text-accent",link:"text-primary items-start justify-start underline-offset-4 hover:underline",outline:"border border-border bg-background hover:bg-card hover:text-accent",secondary:"bg-secondary text-secondary-foreground hover:bg-accent"}}}),P=ma.forwardRef(({asChild:e=!1,className:t,size:a,variant:o,...l},s)=>(0,ca.jsx)(e?da.Slot:"button",{className:n(Qo({className:t,size:a,variant:o})),ref:s,...l}));P.displayName="Button";var ga=J(require("react"));var it=ga.forwardRef(({className:e,type:t,...a},o)=>(0,ca.jsx)("input",{type:t,className:n("flex ca-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-sm shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",e),ref:o,...a}));it.displayName="Input";var Et=J(require("react")),me=J(require("@radix-ui/react-scroll-area"));var ve=Et.forwardRef(({className:e,children:t,...a},o)=>(0,ca.jsxs)(me.Root,{ref:o,className:n("relative overflow-hidden",e),...a,children:[(0,ca.jsx)(me.Viewport,{className:"ca-full w-full rounded-[inherit]",children:t}),(0,ca.jsx)(ha,{}),(0,ca.jsx)(me.Corner,{})]}));ve.displayName=me.Root.displayName;var ha=Et.forwardRef(({className:e,orientation:t="vertical",...a},o)=>(0,ca.jsx)(me.ScrollAreaScrollbar,{ref:o,orientation:t,className:n("flex touch-none select-none transition-colors",t==="vertical"&&"ca-full w-2.5 border-l border-l-transparent p-[1px]",t==="horizontal"&&"ca-2.5 flex-col border-t border-t-transparent p-[1px]",e),...a,children:(0,ca.jsx)(me.ScrollAreaThumb,{className:"relative flex-1 rounded-full bg-border"})}));ha.displayName=me.ScrollAreaScrollbar.displayName;var rt=J(require("react")),V=J(require("@radix-ui/react-dialog"));var va=V.Root;var Xo=V.Portal;var ya=rt.forwardRef(({className:e,...t},a)=>(0,ca.jsx)(V.Overlay,{ref:a,className:n("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));ya.displayName=V.Overlay.displayName;var Bt=rt.forwardRef(({className:e,children:t,...a},o)=>(0,ca.jsxs)(Xo,{children:[(0,ca.jsx)(ya,{}),(0,ca.jsxs)(V.Content,{ref:o,className:n("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-ca-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...a,children:[t,(0,ca.jsxs)(V.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[(0,ca.jsx)(Za.X,{className:"ca-4 w-4"}),(0,ca.jsx)("span",{className:"sr-only",children:"Close"})]})]})]}));Bt.displayName=V.Content.displayName;var zt=({className:e,...t})=>(0,ca.jsx)("div",{className:n("flex flex-col space-ca-1.5 text-center sm:text-left",e),...t});zt.displayName="DialogHeader";var Yo=({className:e,...t})=>(0,ca.jsx)("div",{className:n("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Yo.displayName="DialogFooter";var _t=rt.forwardRef(({className:e,...t},a)=>(0,ca.jsx)(V.Title,{ref:a,className:n("text-lg font-semibold leading-none tracking-tight",e),...t}));_t.displayName=V.Title.displayName;var Zo=rt.forwardRef(({className:e,...t},a)=>(0,ca.jsx)(V.Description,{ref:a,className:n("text-sm text-muted-foreground",e),...t}));Zo.displayName=V.Description.displayName;var st=J(require("@radix-ui/react-checkbox")),wa=J(require("react")),Lt=wa.forwardRef(({className:e,...t},a)=>(0,ca.jsx)(st.Root,{className:n("peer ca-4 w-4 shrink-0 rounded border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",e),ref:a,...t,children:(0,ca.jsx)(st.Indicator,{className:n("flex items-center justify-center text-current"),children:(0,ca.jsx)(Za.Check,{className:"ca-4 w-4"})})}));Lt.displayName=st.Root.displayName;var ye=e=>({id:Math.random().toString(36).substr(2,9),title:e,format:"markdown",createdAt:new Date});var Na=[{id:"design",name:"Design",description:"Creative and visual design team",icon:(0,ca.jsx)(Za.Palette,{className:"ca-4 w-4"}),color:"bg-purple-600",accentColor:"text-purple-600"},{id:"engineering",name:"Engineering",description:"Software development and technical teams",icon:(0,ca.jsx)(Za.Code,{className:"ca-4 w-4"}),color:"bg-blue-600",accentColor:"text-blue-600"},{id:"marketing",name:"Marketing",description:"Brand, campaigns, and growth marketing",icon:(0,ca.jsx)(Za.TrendingUp,{className:"ca-4 w-4"}),color:"bg-pink-600",accentColor:"text-pink-600"},{id:"sales",name:"Sales",description:"Revenue generation and customer acquisition",icon:(0,ca.jsx)(Za.DollarSign,{className:"ca-4 w-4"}),color:"bg-green-600",accentColor:"text-green-600"},{id:"hr",name:"Human Resources",description:"People operations and talent management",icon:(0,ca.jsx)(Za.Users,{className:"ca-4 w-4"}),color:"bg-orange-600",accentColor:"text-orange-600"},{id:"operations",name:"Operations",description:"Business operations and process optimization",icon:(0,ca.jsx)(Za.Wrench,{className:"ca-4 w-4"}),color:"bg-indigo-600",accentColor:"text-indigo-600"},{id:"legal",name:"Legal",description:"Legal affairs and compliance",icon:(0,ca.jsx)(Za.Scale,{className:"ca-4 w-4"}),color:"bg-slate-600",accentColor:"text-slate-600"},{id:"product",name:"Product",description:"Product strategy and management",icon:(0,ca.jsx)(Za.Package,{className:"ca-4 w-4"}),color:"bg-violet-600",accentColor:"text-violet-600"},{id:"it",name:"IT Support",description:"Information technology and infrastructure",icon:(0,ca.jsx)(Za.Zap,{className:"ca-4 w-4"}),color:"bg-cyan-600",accentColor:"text-cyan-600"},{id:"company",name:"Company",description:"Company-wide resources and information",icon:(0,ca.jsx)(Za.Building2,{className:"ca-4 w-4"}),color:"bg-gray-600",accentColor:"text-gray-600"}],ht=[{id:"1",name:"E-commerce Platform",description:"Main customer-facing e-commerce application",isSelected:!0},{id:"2",name:"Admin Dashboard",description:"Internal administration and analytics dashboard",isSelected:!1},{id:"3",name:"Mobile App",description:"Native mobile application for iOS and Android",isSelected:!1}];var Ft=[{id:"1",name:"User Authentication",color:"bg-blue-500",description:"Implement secure user authentication system",confidence:"high",phase:2,startDate:new Date("2024-01-01"),endDate:new Date("2024-02-15"),progress:75,isSelected:!0},{id:"2",name:"Dashboard Features",color:"bg-green-500",description:"Build comprehensive dashboard functionality",confidence:"medium",phase:1,startDate:new Date("2024-02-01"),endDate:new Date("2024-03-15"),progress:30,isSelected:!0},{id:"3",name:"Mobile Optimization",color:"bg-purple-500",description:"Optimize application for mobile devices",confidence:"low",phase:1,startDate:new Date("2024-03-01"),endDate:new Date("2024-04-15"),progress:10,isSelected:!0},{id:"4",name:"Performance Improvements",color:"bg-orange-500",description:"Enhance application performance and speed",confidence:"high",phase:3,startDate:new Date("2024-01-15"),endDate:new Date("2024-02-28"),progress:90,isSelected:!0}],gt=[{id:"backlog",name:"Backlog",description:"Tasks not yet assigned to a sprint",startDate:new Date("2024-01-01"),endDate:new Date("2024-12-31"),isActive:!1,isSelected:!1},{id:"all-tasks",name:"All Tasks",description:"View all tasks across all sprints",startDate:new Date("2024-01-01"),endDate:new Date("2024-12-31"),isActive:!1,isSelected:!0},{id:"1",name:"Sprint 1",description:"Initial development phase",startDate:new Date("2024-01-01"),endDate:new Date("2024-01-14"),isActive:!1,isSelected:!1},{id:"2",name:"Sprint 2",description:"Feature development",startDate:new Date("2024-01-15"),endDate:new Date("2024-01-28"),isActive:!0,isSelected:!1}],vt=[{id:"1",title:"Design login page",description:"Create wireframes and mockups for the login interface",status:"todo",priority:"high",type:"story",points:5,epicId:"1",sprintId:"2",assignee:"John Doe",createdAt:new Date("2024-01-15")},{id:"2",title:"Implement OAuth integration",description:"Add Google and GitHub OAuth authentication",status:"review",priority:"high",type:"task",points:8,epicId:"1",sprintId:"2",assignee:"Jane Smith",createdAt:new Date("2024-01-16")},{id:"3",title:"Create dashboard widgets",description:"Build analytics and metrics widgets for the main dashboard",status:"todo",priority:"medium",type:"story",points:13,epicId:"2",sprintId:"2",assignee:"Mike Johnson",createdAt:new Date("2024-01-17")},{id:"4",title:"Fix login redirect bug",description:"Resolve issue where users are not redirected after login",status:"done",priority:"high",type:"bug",points:3,epicId:"1",sprintId:"1",assignee:"Sarah Wilson",createdAt:new Date("2024-01-14")},{id:"5",title:"Research mobile frameworks",description:"Investigate best practices for mobile responsive design",status:"in-progress",priority:"medium",type:"spike",points:5,epicId:"3",assignee:"Alex Brown",createdAt:new Date("2024-01-18")},{id:"6",title:"Update user profile page",description:"Enhance user profile with new settings and preferences",status:"review",priority:"medium",type:"story",points:8,epicId:"2",sprintId:"2",assignee:"Emma Davis",createdAt:new Date("2024-01-19")},{id:"7",title:"Performance optimization",description:"Optimize database queries and improve page load times",status:"done",priority:"high",type:"task",points:13,epicId:"4",sprintId:"1",assignee:"Tom Wilson",createdAt:new Date("2024-01-13")}],ei=[...vt,{id:"8",title:"Add search functionality",description:"Implement search across all dashboard widgets",status:"todo",priority:"medium",type:"story",points:8,epicId:"2",sprintId:"2",assignee:"Chris Lee",createdAt:new Date("2024-01-20")},{id:"9",title:"Fix mobile responsive issues",description:"Resolve layout problems on mobile devices",status:"in-progress",priority:"high",type:"bug",points:5,epicId:"3",sprintId:"2",assignee:"Taylor Swift",createdAt:new Date("2024-01-21")},{id:"10",title:"Implement dark mode",description:"Add dark theme support across the application",status:"review",priority:"low",type:"story",points:13,epicId:"2",sprintId:"2",assignee:"Jordan Smith",createdAt:new Date("2024-01-22")},{id:"11",title:"API rate limiting",description:"Implement rate limiting for API endpoints",status:"done",priority:"high",type:"task",points:8,epicId:"4",sprintId:"1",assignee:"Morgan Davis",createdAt:new Date("2024-01-12")},{id:"12",title:"User onboarding flow",description:"Create guided tour for new users",status:"todo",priority:"medium",type:"story",points:21,epicId:"1",sprintId:"2",assignee:"Casey Johnson",createdAt:new Date("2024-01-23")}],ti=[...ht,{id:"4",name:"Analytics Platform",description:"Business intelligence and reporting system",isSelected:!1},{id:"5",name:"API Gateway",description:"Microservices API management layer",isSelected:!1}],ft={projects:[{id:"1",name:"Empty Project",description:"A project with no tasks",isSelected:!0}],epics:[],sprints:[{id:"all-tasks",name:"All Tasks",description:"View all tasks across all sprints",startDate:new Date("2024-01-01"),endDate:new Date("2024-12-31"),isActive:!1,isSelected:!0}],tasks:[]},Ca={epics:[{id:"1",name:"User Authentication",color:"bg-blue-500",description:"Implement secure user authentication system",confidence:"high",phase:2,startDate:new Date("2024-01-01"),endDate:new Date("2024-02-15"),progress:75,isSelected:!0}],tasks:vt.filter(e=>e.epicId==="1")};var Oi={empty:{initialProjects:ft.projects,initialEpics:ft.epics,initialSprints:ft.sprints,initialTasks:ft.tasks},default:{initialProjects:ht,initialEpics:Ft,initialSprints:gt,initialTasks:vt},highDensity:{initialProjects:ht,initialEpics:Ft,initialSprints:gt,initialTasks:ei},singleEpic:{initialProjects:ht,initialEpics:Ca.epics,initialSprints:gt,initialTasks:Ca.tasks},multipleProjects:{initialProjects:ti,initialEpics:Ft,initialSprints:gt,initialTasks:vt}},bt=[{id:"1",type:"human",name:"Sarah Johnson",email:"sarah.johnson@company.com",role:"Senior Designer",department:"Design",status:"active",joinedDate:new Date("2023-01-15"),lastActive:new Date,phone:"+1 (555) 123-4567",location:"San Francisco, CA",timezone:"PST",skills:["UI/UX Design","Figma","Adobe Creative Suite","Prototyping","User Research"],bio:"Passionate designer with 8+ years of experience creating user-centered digital experiences."},{id:"2",type:"digital",name:"CodeAssist Pro",status:"active",joinedDate:new Date("2024-01-01"),lastActive:new Date,jobDescription:"AI-powered coding assistant that helps with code review, debugging, and documentation generation.",workInstructions:"Review pull requests for code quality and best practices. Generate comprehensive documentation for new features. Assist with debugging complex issues. Provide code suggestions and optimizations.",capabilities:["Code Review","Documentation Generation","Debugging","Code Optimization","Testing"],knowledge:["JavaScript","TypeScript","React","Node.js","Python","Git"].map(ye),coreKnowledge:["Company coding standards","Architecture patterns","Security guidelines"].map(ye),version:"2",lastUpdated:new Date("2024-01-15"),isActive:!0},{id:"3",type:"human",name:"Michael Chen",email:"michael.chen@company.com",role:"Product Manager",department:"Product",status:"inactive",joinedDate:new Date("2022-08-20"),lastActive:new Date(Date.now()-2*60*60*1e3),phone:"+1 (555) 987-6543",location:"New York, NY",timezone:"EST",skills:["Product Strategy","Agile","Data Analysis","User Stories","Roadmapping"],bio:"Strategic product manager focused on driving user engagement and business growth."},{id:"4",type:"digital",name:"MarketingBot",status:"active",joinedDate:new Date("2024-02-01"),lastActive:new Date,jobDescription:"Specialized AI assistant for marketing campaigns, content creation, and social media management.",workInstructions:"Create engaging social media content. Analyze campaign performance metrics. Generate marketing copy and headlines. Schedule and manage social media posts.",capabilities:["Content Creation","Social Media Management","Analytics","SEO Optimization","Campaign Management"],knowledge:["Digital Marketing","Social Media Platforms","Content Strategy","Analytics Tools"].map(ye),coreKnowledge:["Brand guidelines","Target audience personas","Marketing objectives"].map(ye),version:"52",lastUpdated:new Date("2024-02-10"),isActive:!0},{id:"5",type:"human",name:"Emily Rodriguez",email:"emily.rodriguez@company.com",role:"UX Researcher",department:"Design",status:"inactive",joinedDate:new Date("2023-06-10"),lastActive:new Date(Date.now()-7*24*60*60*1e3),phone:"+1 (555) 456-7890",location:"Austin, TX",timezone:"CST",skills:["User Research","Usability Testing","Data Analysis","Survey Design","Interview Techniques"],bio:"User researcher dedicated to understanding user needs and improving product experiences."},{id:"6",type:"digital",name:"DataAnalyzer Pro",status:"active",joinedDate:new Date("2024-01-10"),lastActive:new Date,jobDescription:"Advanced AI assistant specializing in data analysis, reporting, and business intelligence.",workInstructions:"Analyze complex datasets, generate insightful reports, create data visualizations, and provide actionable business recommendations.",capabilities:["Data Analysis","Report Generation","Data Visualization","Business Intelligence","Statistical Analysis"],knowledge:["Python","SQL","Tableau","Excel","R","Statistics"].map(ye),coreKnowledge:["Company data sources","KPI definitions","Reporting standards"].map(ye),version:"3.1",lastUpdated:new Date("2024-02-20"),isActive:!0},{id:"7",type:"digital",name:"ProjectManager AI",status:"active",joinedDate:new Date("2024-01-05"),lastActive:new Date,jobDescription:"Intelligent project management assistant that helps coordinate tasks, track progress, and manage timelines.",workInstructions:"Coordinate project activities, track milestones, manage resource allocation, and provide project status updates.",capabilities:["Project Planning","Task Coordination","Timeline Management","Resource Allocation","Progress Tracking"],knowledge:["Agile","Scrum","Gantt Charts","Risk Management","Stakeholder Management"].map(ye),coreKnowledge:["Company project templates","Resource availability","Project methodologies"].map(ye),version:"2.5",lastUpdated:new Date("2024-02-15"),isActive:!0},{id:"8",type:"digital",name:"CustomerSupport Bot",status:"active",joinedDate:new Date("2024-02-01"),lastActive:new Date,jobDescription:"AI-powered customer support assistant that handles inquiries, resolves issues, and escalates complex problems.",workInstructions:"Respond to customer inquiries, troubleshoot common issues, provide product information, and escalate complex cases to human agents.",capabilities:["Customer Support","Issue Resolution","Product Knowledge","Escalation Management","Chat Support"],knowledge:["Product Documentation","FAQ","Troubleshooting Guides","Customer Service Best Practices"].map(ye),coreKnowledge:["Product catalog","Support processes","Escalation procedures"].map(ye),version:"1.8",lastUpdated:new Date("2024-02-25"),isActive:!0}],Gi=[{id:"1",title:"Review quarterly report",description:"Go through Q4 performance metrics and prepare summary for the team meeting",dueDate:new Date(2024,2,15),dueTime:"14:30",colleague:bt.find(e=>e.id==="2"&&e.type==="digital"),isCompleted:!1,isRecurring:!1,priority:"high",reminderEnabled:!0,reminderMinutes:30,createdAt:new Date(2024,2,10),tags:["quarterly","review","urgent"]},{id:"2",title:"Weekly team standup",description:"Join the weekly team synchronization meeting",dueDate:new Date(2024,2,18),dueTime:"10:00",colleague:bt.find(e=>e.id==="4"&&e.type==="digital"),isCompleted:!1,isRecurring:!0,recurrencePattern:"weekly",recurrenceInterval:1,priority:"medium",reminderEnabled:!0,reminderMinutes:15,createdAt:new Date(2024,2,11),tags:["meeting","standup","weekly"]},{id:"3",title:"Deploy to production",description:"Deploy the latest version to production environment",dueDate:new Date,dueTime:"16:00",colleague:bt.find(e=>e.id==="2"&&e.type==="digital"),isCompleted:!1,isRecurring:!1,priority:"high",reminderEnabled:!0,reminderMinutes:60,createdAt:new Date,tags:["deploy","production","urgent"]}];var Wi=bt.filter(e=>e.type==="digital");function ka(e,t){let[a,o]=(0,Ke.useState)(()=>{if(typeof window>"u")return t;try{let s=window.localStorage.getItem(e);return s?JSON.parse(s):t}catch{return t}}),l=s=>{try{o(s),typeof window<"u"&&window.localStorage.setItem(e,JSON.stringify(s))}catch{}};return(0,Ke.useEffect)(()=>{l(a)},[]),[a,l]}function Ht({items:e,isOpen:t,isMobile:a=!1,onClose:o,currentBusinessUnit:l=Na[0],onBusinessUnitChange:s,onSearch:c,className:r,logo:u="/headerlogo.png",appName:m="Nuvia",tagline:R="Collaboration Platform"}){let[b,N]=xt.useState({}),[D,_]=ka("sidebar-favorites",{}),[k,x]=xt.useState(null),[S,I]=xt.useState(""),C=d=>{N(E=>({...E,[d]:!E[d]}))},z=d=>{s?.(d)},oe=()=>{S.trim()&&c?.(S.trim())},K=d=>{d.key==="Enter"&&(d.preventDefault(),oe())},ee=(d,E)=>{let T=D[d]||[],p=T.includes(E)?T.filter(A=>A!==E):T.concat(E);_({...D,[d]:p})},W=d=>{if(!d.items||!d.maxItems||d.items.length<=d.maxItems)return d.items||[];let E=D[d.id]||[],T=d.items.filter(A=>E.includes(A.id)),p=d.items.filter(A=>!E.includes(A.id));return[...T,...p].slice(0,d.maxItems)},q=d=>d.maxItems&&d.items&&d.items.length>d.maxItems,X=e,ie=d=>{let E=q(d),T=W(d),p=(0,ca.jsxs)(ca.Fragment,{children:[(0,ca.jsxs)("div",{className:"flex items-center gap-3",children:[d.icon,(0,ca.jsx)("span",{children:d.title})]}),d.badge&&(0,ca.jsx)(ce,{variant:"outline",className:"ml-auto rounded-full px-2 py-0.5 text-xs",children:d.badge}),d.items&&(0,ca.jsx)(Za.ChevronDown,{className:n("ml-2 ca-4 w-4 transition-transform",b[d.title]?"rotate-180":"")})]}),A=n("flex w-full items-center justify-between rounded-2xl px-3 py-2 text-sm font-medium",d.isActive?"bg-primary/10 text-primary":"hover:bg-muted");return d.url?(0,ca.jsx)(jt.default,{href:d.url,className:A,onClick:a?o:void 0,children:p}):(0,ca.jsx)("button",{className:A,onClick:()=>d.items&&C(d.title),children:p})},U=()=>{let d=e.find(T=>T.id===k);if(!d||!d.items||!d.maxItems)return null;let E=D[d.id]||[];return(0,ca.jsx)(va,{open:!!k,onOpenChange:T=>!T&&x(null),children:(0,ca.jsxs)(Bt,{className:"sm:max-w-md",children:[(0,ca.jsxs)(zt,{children:[(0,ca.jsxs)(_t,{children:["Manage ",d.title," Favorites"]}),(0,ca.jsxs)("p",{className:"text-sm text-muted-foreground",children:["Select up to ",d.maxItems," items to show in ",d.title.toLowerCase(),"."]})]}),(0,ca.jsx)(ve,{className:"max-ca-96 pr-4",children:(0,ca.jsx)("div",{className:"space-ca-4",children:d.items.map(T=>(0,ca.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,ca.jsx)(Lt,{id:T.id,checked:E.includes(T.id),onCheckedChange:()=>ee(d.id,T.id),disabled:!E.includes(T.id)&&E.length>=(d.maxItems||0)}),(0,ca.jsxs)("label",{htmlFor:T.id,className:"flex items-center gap-2 text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70 cursor-pointer flex-1",children:[T.title,T.badge&&(0,ca.jsx)(ce,{variant:"outline",className:"text-xs",children:T.badge})]})]},T.id))})})]})})},ke=(0,ca.jsxs)("div",{className:"flex ca-full flex-col bg-background",children:[(0,ca.jsxs)("div",{className:"flex items-center justify-between p-4",children:[(0,ca.jsxs)("div",{className:"flex items-center gap-3",children:[(0,ca.jsx)("div",{className:"flex ca-14 w-14 items-center justify-center",children:(0,ca.jsx)("img",{src:u,alt:"Header Logo",className:"ca-14 w-14 object-contain"})}),(0,ca.jsxs)("div",{children:[(0,ca.jsx)("h2",{className:"font-semibold",children:m}),(0,ca.jsx)("p",{className:"text-xs text-muted-foreground",children:R})]})]}),a&&(0,ca.jsx)(P,{variant:"ghost",size:"icon",onClick:o,children:(0,ca.jsx)(Za.X,{className:"ca-5 w-5"})})]}),(0,ca.jsx)("div",{className:"px-3 py-2",children:(0,ca.jsxs)("div",{className:"relative",children:[(0,ca.jsx)(Za.Search,{className:"absolute left-3 top-3 ca-4 w-4 text-muted-foreground"}),(0,ca.jsx)(it,{type:"search",placeholder:"Search...",className:"w-full rounded-2xl bg-muted pl-9 pr-4 py-2",value:S,onChange:d=>I(d.target.value),onKeyPress:K})]})}),(0,ca.jsx)(ve,{className:"flex-1 px-3 py-2",children:(0,ca.jsx)("div",{className:"space-ca-1",children:X.map(d=>(0,ca.jsxs)("div",{className:"mb-1",children:[ie(d),d.items&&b[d.title]&&(0,ca.jsxs)("div",{className:"mt-1 ml-6 space-ca-1 border-l pl-3",children:[W(d).map(E=>(0,ca.jsxs)(jt.default,{href:E.url,className:"flex items-center justify-between rounded-2xl px-3 py-2 text-sm hover:bg-muted",onClick:a?o:void 0,children:[E.title,E.badge&&(0,ca.jsx)(ce,{variant:"outline",className:"ml-auto rounded-full px-2 py-0.5 text-xs",children:E.badge})]},E.id)),q(d)&&d.items&&d.items.length>W(d).length&&(0,ca.jsxs)("button",{onClick:()=>x(d.id),className:"w-full px-3 py-2 text-xs text-muted-foreground hover:text-foreground hover:bg-muted rounded-2xl transition-colors text-left",children:["...",d.items.length-W(d).length," more available"]})]})]},d.id))})}),(0,ca.jsx)("div",{className:"p-3",children:(0,ca.jsx)("div",{className:"space-ca-1",children:(0,ca.jsxs)("button",{className:"flex w-full items-center gap-3 rounded-2xl px-3 py-2 text-sm font-medium hover:bg-muted",children:[(0,ca.jsx)(Za.Settings,{className:"ca-5 w-5"}),(0,ca.jsx)("span",{children:"Settings"})]})})}),(0,ca.jsx)(U,{})]});return a?(0,ca.jsx)("div",{className:n("fixed inset-ca-0 left-0 z-50 w-64 transform bg-background transition-transform duration-300 ease-in-out",t?"translate-x-0":"-translate-x-full",r),children:ke}):(0,ca.jsx)("div",{className:n("fixed inset-ca-0 left-0 z-30 w-64 transform bg-background transition-transform duration-300 ease-in-out",t?"translate-x-0":"-translate-x-full",r),children:ke})}var wt=J(require("react")),Pe=J(require("@radix-ui/react-avatar"));var Fe=wt.forwardRef(({className:e,...t},a)=>(0,ca.jsx)(Pe.Root,{ref:a,className:n("relative flex ca-10 w-10 shrink-0 overflow-hidden rounded-full",e),...t}));Fe.displayName=Pe.Root.displayName;var Ot=wt.forwardRef(({className:e,...t},a)=>(0,ca.jsx)(Pe.Image,{ref:a,className:n("aspect-square ca-full w-full",e),...t}));Ot.displayName=Pe.Image.displayName;var je=wt.forwardRef(({className:e,...t},a)=>(0,ca.jsx)(Pe.Fallback,{ref:a,className:n("flex ca-full w-full items-center justify-center rounded-full bg-muted",e),...t}));je.displayName=Pe.Fallback.displayName;var Da=J(require("react")),he=J(require("@radix-ui/react-tooltip"));var Nt=he.Provider,kt=he.Root,Dt=he.Trigger,nt=Da.forwardRef(({className:e,sideOffset:t=4,...a},o)=>(0,ca.jsx)(he.Portal,{children:(0,ca.jsx)(he.Content,{ref:o,sideOffset:t,className:n("z-50 overflow-hidden rounded-md bg-primary px-3 py-1.5 text-xs text-primary-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...a})}));nt.displayName=he.Content.displayName;var Sa=require("next-themes");function Pa(){let{setTheme:e,theme:t}=(0,Sa.useTheme)();return(0,ca.jsx)(Nt,{children:(0,ca.jsxs)(kt,{children:[(0,ca.jsx)(Dt,{asChild:!0,children:(0,ca.jsxs)(P,{variant:"ghost",size:"icon",className:"rounded-2xl",onClick:()=>e(t==="light"?"dark":"light"),children:[(0,ca.jsx)(Za.Sun,{className:"ca-5 w-5 rotate-0 scale-100 transition-all dark:-rotate-90 dark:scale-0"}),(0,ca.jsx)(Za.Moon,{className:"absolute ca-5 w-5 rotate-90 scale-0 transition-all dark:rotate-0 dark:scale-100"}),(0,ca.jsx)("span",{className:"sr-only",children:"Toggle theme"})]})}),(0,ca.jsx)(nt,{children:"Toggle theme"})]})})}function Ra({notifications:e,open:t,onClose:a,onNotificationRemove:o,onRemoveAll:l,className:s}){let c=e.filter(m=>!m.read),r=c.length,u=m=>{switch(m){case"info":return(0,ca.jsx)(Za.Info,{className:"ca-5 w-5 text-blue-500"});case"success":return(0,ca.jsx)(Za.Check,{className:"ca-5 w-5 text-green-500"});case"warning":return(0,ca.jsx)(Za.AlertTriangle,{className:"ca-5 w-5 text-amber-500"});case"error":return(0,ca.jsx)(Za.AlertTriangle,{className:"ca-5 w-5 text-red-500"})}};return(0,ca.jsx)(Tt.AnimatePresence,{children:t&&(0,ca.jsxs)(ca.Fragment,{children:[(0,ca.jsx)(Tt.motion.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},className:"fixed inset-0 z-40 bg-black/20 backdrop-blur-sm md:hidden",onClick:a}),(0,ca.jsx)(Tt.motion.div,{initial:{x:"100%"},animate:{x:0},exit:{x:"100%"},transition:{type:"spring",damping:20,stiffness:300},className:n("fixed inset-ca-0 right-0 z-50 w-full max-w-sm border-l bg-background shadow-lg md:w-96",s),children:(0,ca.jsxs)("div",{className:"flex ca-full flex-col",children:[(0,ca.jsxs)("div",{className:"flex items-center justify-between border-b p-4",children:[(0,ca.jsxs)("div",{className:"flex items-center gap-2",children:[(0,ca.jsx)(Za.Bell,{className:"ca-5 w-5"}),(0,ca.jsx)("h2",{className:"text-lg font-semibold",children:"Notifications"}),r>0&&(0,ca.jsxs)(ce,{variant:"secondary",className:"rounded-full px-2 py-0.5",children:[r," new"]})]}),(0,ca.jsxs)(P,{variant:"ghost",size:"icon",onClick:a,className:"rounded-full",children:[(0,ca.jsx)(Za.X,{className:"ca-5 w-5"}),(0,ca.jsx)("span",{className:"sr-only",children:"Close"})]})]}),r>0&&(0,ca.jsxs)("div",{className:"flex items-center justify-between border-b p-2",children:[(0,ca.jsxs)("span",{className:"text-sm text-muted-foreground",children:[r," unread notification",r!==1?"s":""]}),(0,ca.jsx)(P,{variant:"ghost",size:"sm",onClick:l,className:"text-sm",children:"Dismiss all"})]}),c.length>0?(0,ca.jsx)(ve,{className:"flex-1",children:(0,ca.jsx)("div",{className:"divide-ca",children:c.map(m=>(0,ca.jsxs)("div",{className:n("flex gap-3 p-4 transition-colors bg-muted/50"),children:[(0,ca.jsx)("div",{className:"flex ca-10 w-10 flex-shrink-0 items-center justify-center rounded-full bg-muted",children:u(m.type)}),(0,ca.jsxs)("div",{className:"flex-1 space-ca-1",children:[(0,ca.jsxs)("div",{className:"flex items-center justify-between",children:[(0,ca.jsx)("p",{className:"font-medium",children:m.title}),(0,ca.jsxs)("div",{className:"flex items-center gap-2",children:[(0,ca.jsx)("p",{className:"text-xs text-muted-foreground",children:m.time}),(0,ca.jsx)(P,{variant:"ghost",size:"sm",className:"ca-6 w-6 p-0",onClick:()=>o?.(m.id),title:"Dismiss",children:(0,ca.jsx)(Za.Check,{className:"ca-3 w-3"})})]})]}),(0,ca.jsx)("p",{className:"text-sm text-muted-foreground",children:m.description}),m.actionLabel&&(0,ca.jsxs)(P,{variant:"link",size:"sm",className:"ca-auto p-0 text-sm",onClick:m.onAction,children:[m.actionLabel,(0,ca.jsx)(Za.ChevronRight,{className:"ml-1 ca-3 w-3"})]})]})]},m.id))})}):(0,ca.jsxs)("div",{className:"flex flex-1 flex-col items-center justify-center p-8 text-center",children:[(0,ca.jsx)("div",{className:"flex ca-16 w-16 items-center justify-center rounded-full bg-muted",children:(0,ca.jsx)(Za.Bell,{className:"ca-8 w-8 text-muted-foreground"})}),(0,ca.jsx)("h3",{className:"mt-4 text-lg font-medium",children:"No notifications"}),(0,ca.jsx)("p",{className:"mt-2 text-sm text-muted-foreground",children:"When you receive notifications, they'll appear here."})]})]})})]})})}var He=J(require("@radix-ui/react-tabs"));function Ta({className:e,...t}){return(0,ca.jsx)(He.Root,{"data-slot":"tabs",className:n("flex flex-col gap-2",e),...t})}function Aa({className:e,...t}){return(0,ca.jsx)(He.List,{"data-slot":"tabs-list",className:n("bg-muted text-muted-foreground inline-flex ca-9 w-fit items-center justify-center rounded-lg p-[3px]",e),...t})}function Ia({className:e,...t}){return(0,ca.jsx)(He.Trigger,{"data-slot":"tabs-trigger",className:n("data-[state=active]:bg-accent data-[state=active]:text-accent-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring text-foreground inline-flex ca-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...t})}var Re=J(require("react")),w=J(require("@radix-ui/react-dropdown-menu")),Qe=require("@radix-ui/react-icons");var Ma=w.Root,Ua=w.Trigger;var ai=Re.forwardRef(({className:e,inset:t,children:a,...o},l)=>(0,$.jsxs)(w.SubTrigger,{ref:l,className:n("flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...o,children:[a,(0,$.jsx)(Qe.ChevronRightIcon,{className:"ml-auto"})]}));ai.displayName=w.SubTrigger.displayName;var oi=Re.forwardRef(({className:e,...t},a)=>(0,$.jsx)(w.SubContent,{ref:a,className:n("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...t}));oi.displayName=w.SubContent.displayName;var Wt=Re.forwardRef(({className:e,sideOffset:t=4,...a},o)=>(0,$.jsx)(w.Portal,{children:(0,$.jsx)(w.Content,{ref:o,sideOffset:t,className:n("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...a})}));Wt.displayName=w.Content.displayName;var Vt=Re.forwardRef(({className:e,inset:t,...a},o)=>(0,$.jsx)(w.Item,{ref:o,className:n("relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&>svg]:size-4 [&>svg]:shrink-0",t&&"pl-8",e),...a}));Vt.displayName=w.Item.displayName;var ii=Re.forwardRef(({className:e,children:t,checked:a,...o},l)=>(0,$.jsxs)(w.CheckboxItem,{ref:l,className:n("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:a,...o,children:[(0,$.jsx)("span",{className:"absolute left-2 flex ca-3.5 w-3.5 items-center justify-center",children:(0,$.jsx)(w.ItemIndicator,{children:(0,$.jsx)(Qe.CheckIcon,{className:"ca-4 w-4"})})}),t]}));ii.displayName=w.CheckboxItem.displayName;var ri=Re.forwardRef(({className:e,children:t,...a},o)=>(0,$.jsxs)(w.RadioItem,{ref:o,className:n("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...a,children:[(0,$.jsx)("span",{className:"absolute left-2 flex ca-3.5 w-3.5 items-center justify-center",children:(0,$.jsx)(w.ItemIndicator,{children:(0,$.jsx)(Qe.DotFilledIcon,{className:"ca-4 w-4 fill-current"})})}),t]}));ri.displayName=w.RadioItem.displayName;var si=Re.forwardRef(({className:e,inset:t,...a},o)=>(0,$.jsx)(w.Label,{ref:o,className:n("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...a}));si.displayName=w.Label.displayName;var ni=Re.forwardRef(({className:e,...t},a)=>(0,$.jsx)(w.Separator,{ref:a,className:n("-mx-1 my-1 ca-px bg-muted",e),...t}));ni.displayName=w.Separator.displayName;var li=({className:e,...t})=>(0,$.jsx)("span",{className:n("ml-auto text-xs tracking-widest opacity-60",e),...t});li.displayName="DropdownMenuShortcut";function Ba({activeTab:e,onTabChange:t,tabOptions:a,className:o="",maxWidth:l="700px",gridCols:s=6}){let c=a.find(r=>r.value===e);return(0,ca.jsxs)($t.motion.div,{className:`flex-1 flex justify-center ${o}`,initial:{opacity:0,ca:-20},animate:{opacity:1,ca:0},transition:{duration:.3,ease:"easeOut"},children:[(0,ca.jsx)("div",{className:"hidden md:block",children:(0,ca.jsx)(Ta,{value:e,onValueChange:t,children:(0,ca.jsx)(Aa,{className:"grid w-full rounded-2xl p-0 ca-10",style:{maxWidth:l,gridTemplateColumns:`repeat(${Math.min(s,a.length)}, minmax(0, 1fr))`},children:a.map(r=>(0,ca.jsx)($t.motion.div,{whileHover:{scale:1.1},whileTap:{scale:.98},transition:{type:"spring",stiffness:400,damping:17},className:"flex-1 px-2",children:(0,ca.jsx)(Ia,{value:r.value,className:"w-full ca-8 rounded-xl data-[state=active]:rounded-xl transition-all duration-200 hover:border hover:border-accent hover:bg-accent/10 px-4 py-2 text-sm font-medium",children:r.label})},r.value))})})}),(0,ca.jsx)("div",{className:"md:hidden",children:(0,ca.jsxs)(Ma,{children:[(0,ca.jsx)(Ua,{asChild:!0,children:(0,ca.jsxs)(P,{variant:"outline",className:"rounded-2xl min-w-[140px] justify-between",children:[c?.label||"Select",(0,ca.jsx)(Za.ChevronDown,{className:"ca-4 w-4 ml-2"})]})}),(0,ca.jsx)(Wt,{align:"center",className:"w-[180px]",children:a.map(r=>(0,ca.jsx)(Vt,{onClick:()=>t?.(r.value),className:`cursor-pointer ${e===r.value?"bg-accent":""}`,children:r.label},r.value))})]})})]})}function za({title:e,notifications:t=[],onToggleSidebar:a,onToggleMobileMenu:o,sidebarOpen:l=!0,className:s,activeTab:c="assistant",onTabChange:r,showTabs:u=!0,tabOptions:m=[{value:"home",label:"Home"},{value:"chat",label:"Chat"},{value:"projects",label:"Projects"},{value:"colleagues",label:"Colleagues"},{value:"knowledge",label:"Knowledge"}],onActionClick:R,actionIcon:b=(0,ca.jsx)(Za.Bot,{className:"mr-2 ca-4 w-4"}),actionText:N="Action",onNotificationRemove:D,onRemoveAll:_,logo:k="/headerlogo.png",appName:x="Nuvia",tagline:S="Collaboration Platform"}){let[I,C]=(0,Ke.useState)(!1),[z,oe]=(0,Ke.useState)(t),K=z.filter(q=>!q.read).length,ee=q=>{oe(X=>X.filter(ie=>ie.id!==q)),D?.(q)},W=()=>{oe(q=>q.filter(X=>X.read)),_?.()};return(0,ca.jsxs)(ca.Fragment,{children:[(0,ca.jsxs)("header",{className:`sticky top-0 z-10 flex ca-16 items-center gap-3 px-4 backdrop-blur ${s||""}`,children:[(0,ca.jsx)(P,{variant:"ghost",size:"icon",className:"md:hidden",onClick:o,children:(0,ca.jsx)(Za.Menu,{className:"ca-5 w-5"})}),(0,ca.jsx)(P,{variant:"ghost",size:"icon",className:"hidden md:flex",onClick:a,children:(0,ca.jsx)(Za.PanelLeft,{className:"ca-5 w-5"})}),!l&&(0,ca.jsxs)(Tt.motion.div,{className:"flex items-center gap-3",initial:{opacity:0,x:-20},animate:{opacity:1,x:0},transition:{duration:.3},children:[(0,ca.jsx)("div",{className:"flex ca-10 w-10 items-center justify-center",children:(0,ca.jsx)("img",{src:k,alt:"Logo",className:"ca-10 w-10 object-contain"})}),(0,ca.jsxs)("div",{children:[(0,ca.jsx)("h2",{className:"font-semibold text-sm",children:x}),(0,ca.jsx)("p",{className:"text-xs text-muted-foreground",children:S})]})]}),(0,ca.jsxs)("div",{className:"flex flex-1 items-center",children:[u&&(0,ca.jsx)(Ba,{activeTab:c,onTabChange:r,tabOptions:m}),(0,ca.jsxs)("div",{className:"flex items-center gap-3 ml-auto",children:[(0,ca.jsx)(Tt.motion.div,{className:"hidden md:flex gap-2",initial:{opacity:0,x:20},animate:{opacity:1,x:0},transition:{duration:.3,ease:"easeOut",delay:.1},children:(0,ca.jsx)(Tt.motion.div,{whileHover:{scale:1.05},whileTap:{scale:.95},transition:{type:"spring",stiffness:400,damping:17},children:(0,ca.jsxs)(P,{className:"rounded-2xl transition-all duration-200 hover:shadow-md",onClick:R,children:[b,N]})})}),(0,ca.jsx)(Pa,{}),(0,ca.jsx)(Nt,{children:(0,ca.jsxs)(kt,{children:[(0,ca.jsx)(Dt,{asChild:!0,children:(0,ca.jsx)(Tt.motion.div,{whileHover:{scale:1.05},whileTap:{scale:.95},transition:{type:"spring",stiffness:400,damping:17},children:(0,ca.jsxs)(P,{variant:"ghost",size:"icon",className:"rounded-2xl relative transition-all duration-200",onClick:()=>C(!0),children:[(0,ca.jsx)(Tt.motion.div,{animate:K>0?{rotate:[0,-10,10,-10,0]}:{},transition:{duration:.5,repeat:K>0?1/0:0,repeatDelay:3},children:(0,ca.jsx)(Za.Bell,{className:"ca-5 w-5"})}),K>0&&(0,ca.jsx)(Tt.motion.span,{className:"absolute -right-1 -top-1 flex ca-5 w-5 items-center justify-center rounded-full bg-red-500 text-xs text-white",initial:{scale:0},animate:{scale:1},transition:{type:"spring",stiffness:500,damping:15},children:K})]})})}),(0,ca.jsx)(nt,{children:"Notifications"})]})}),(0,ca.jsx)(Tt.motion.div,{whileHover:{scale:1.05},whileTap:{scale:.95},transition:{type:"spring",stiffness:400,damping:17},children:(0,ca.jsxs)(Fe,{className:"ca-9 w-9 border-2 border-primary transition-all duration-200 hover:shadow-md cursor-pointer",children:[(0,ca.jsx)(Ot,{src:"/placeholder.svg?height=40&width=40",alt:"User"}),(0,ca.jsx)(je,{})]})})]})]})]}),(0,ca.jsx)(Ra,{notifications:z,open:I,onClose:()=>C(!1),onNotificationRemove:ee,onRemoveAll:W})]})}var _a=[{id:"copilot",name:"Peronal Copilot",description:"Your personal AI assistant for all tasks",icon:(0,ca.jsx)(Za.User,{className:"ca-4 w-4"}),color:"bg-orange-600",accentColor:"text-orange-600"}];function Fa({sidebarItems:e,children:t,title:a="Digital Colleagues",notifications:o=[],currentBusinessUnit:l=_a[0],onBusinessUnitChange:s,onSearch:c,businessUnits:r=_a,activeTab:u,onTabChange:m,showTabs:R=!1,onActionClick:b,actionIcon:N,actionText:D="Action",onNotificationRemove:_,onRemoveAll:k,logo:x="/headerlogo.png",appName:S="Nuvia",tagline:I="Collaboration Platform",sidebarInitiallyClosed:C=!1}){let[z,oe]=(0,Ke.useState)(!C),[K,ee]=(0,Ke.useState)(!1),[W,q]=(0,Ke.useState)(l),X=ie=>{q(ie),s?.(ie)};return(0,ca.jsxs)("div",{className:"flex ca-full flex-col overflow-hidden rounded-xl bg-background w-[]",children:[K&&(0,ca.jsx)("div",{className:"fixed inset-0 z-40 bg-black/50 md:hidden",onClick:()=>ee(!1)}),(0,ca.jsx)("div",{className:"md:hidden",children:(0,ca.jsx)(Ht,{items:e,isOpen:K,isMobile:!0,onClose:()=>ee(!1),currentBusinessUnit:W,onBusinessUnitChange:X,onSearch:c,logo:x,appName:S,tagline:I})}),(0,ca.jsx)("div",{className:"hidden md:block",children:(0,ca.jsx)(Ht,{items:e,isOpen:z,isMobile:!1,currentBusinessUnit:W,onBusinessUnitChange:X,onSearch:c,logo:x,appName:S,tagline:I})}),(0,ca.jsxs)("div",{className:n("min-ca-screen fixed w-full transition-all duration-300 ease-in-out",z?"md:pl-64":"md:pl-0"),children:[(0,ca.jsx)(za,{title:a,notifications:o,onToggleSidebar:()=>oe(!z),onToggleMobileMenu:()=>ee(!0),sidebarOpen:z,activeTab:u,onTabChange:m,showTabs:R,onActionClick:b,actionIcon:N,actionText:D,onNotificationRemove:_,onRemoveAll:k,logo:x,appName:S,tagline:I}),(0,ca.jsx)("main",{className:"flex-1 p-0 flex flex-col ca-[calc(100vh-4rem)] overflow-auto",children:t})]})]})}var Oe=J(require("react"));var ge=Oe.forwardRef(({className:e,...t},a)=>(0,ca.jsx)("div",{ref:a,className:n("rounded-xl border bg-card text-card-foreground shadow",e),...t}));ge.displayName="Card";var Te=Oe.forwardRef(({className:e,...t},a)=>(0,ca.jsx)("div",{ref:a,className:n("flex flex-col space-ca-1.5 p-6",e),...t}));Te.displayName="CardHeader";var Ae=Oe.forwardRef(({className:e,...t},a)=>(0,ca.jsx)("div",{ref:a,className:n("font-semibold leading-none tracking-tight",e),...t}));Ae.displayName="CardTitle";var qt=Oe.forwardRef(({className:e,...t},a)=>(0,ca.jsx)("div",{ref:a,className:n("text-sm text-muted-foreground",e),...t}));qt.displayName="CardDescription";var we=Oe.forwardRef(({className:e,...t},a)=>(0,ca.jsx)("div",{ref:a,className:n("p-6 pt-0",e),...t}));we.displayName="CardContent";var ct=Oe.forwardRef(({className:e,...t},a)=>(0,ca.jsx)("div",{ref:a,className:n("flex items-center p-6 pt-0",e),...t}));ct.displayName="CardFooter";function ja({sessions:e,currentSession:t,teams:a,onNewChat:o,onSessionSelect:l,onSessionEdit:s,onSessionDelete:c,className:r}){return(0,ca.jsx)("div",{className:`space-ca-4 ca-full ${r||""}`,children:(0,ca.jsxs)(ge,{className:"shadow-sm ca-full",children:[(0,ca.jsx)("div",{className:"p-4 border-b",children:(0,ca.jsxs)("div",{className:"flex items-center justify-between",children:[(0,ca.jsxs)("h3",{className:"font-semibold text-sm flex items-center gap-2",children:[(0,ca.jsx)(Za.Clock,{className:"ca-4 w-4"}),"Recent Chats"]}),(0,ca.jsxs)(P,{onClick:o,size:"sm",className:"gap-1 ca-7 px-2 rounded-lg shadow-sm",children:[(0,ca.jsx)(Za.Plus,{className:"ca-3 w-3"}),"New"]})]})}),(0,ca.jsx)(ve,{className:"ca-[600px]",children:(0,ca.jsx)("div",{className:"p-2",children:e.length===0?(0,ca.jsx)("div",{className:"p-4 text-center text-sm text-muted-foreground",children:"No chat sessions yet"}):e.map(u=>(0,ca.jsx)("div",{className:n("group relative p-3 rounded-xl cursor-pointer transition-all hover:bg-muted/50 mb-2",t?.id===u.id&&"bg-muted border"),onClick:()=>l(u),children:(0,ca.jsx)("div",{className:"flex items-start gap-3",children:(0,ca.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,ca.jsxs)("div",{className:"flex items-center justify-between mb-1",children:[(0,ca.jsx)("h4",{className:"font-medium text-sm truncate",children:u.title}),(0,ca.jsx)("div",{className:"flex items-center gap-1",children:(0,ca.jsxs)("div",{className:"opacity-0 group-hover:opacity-100 transition-opacity flex gap-1",children:[s&&(0,ca.jsx)(P,{variant:"ghost",size:"icon",className:"ca-5 w-5 rounded",onClick:m=>{m.stopPropagation(),s(u.id)},children:(0,ca.jsx)(Za.Edit3,{className:"ca-3 w-3"})}),c&&(0,ca.jsx)(P,{variant:"ghost",size:"icon",className:"ca-5 w-5 rounded text-destructive hover:text-destructive",onClick:m=>{m.stopPropagation(),c(u.id)},children:(0,ca.jsx)(Za.Trash2,{className:"ca-3 w-3"})})]})})]}),(0,ca.jsx)("p",{className:"text-xs text-muted-foreground line-clamp-2",children:u.lastMessage})]})})},u.id))})})]})})}var Ha={primary:"bg-blue-500",secondary:"bg-gray-500",accent:"bg-purple-500",categories:["bg-green-500","bg-blue-500","bg-purple-500","bg-pink-500","bg-indigo-500","bg-orange-500"],lists:["bg-green-400","bg-blue-400","bg-purple-400","bg-pink-400","bg-indigo-400","bg-orange-400"],items:["bg-green-300","bg-blue-300","bg-purple-300","bg-pink-300","bg-indigo-300","bg-orange-300"]},We=[{id:"sales",name:"Sales",description:"Revenue and customer management",iconName:"DollarSign",color:"bg-green-600",type:"category",actions:[{id:"view-pipeline",label:"View Pipeline",description:"See all opportunities in pipeline",iconName:"BarChart",action:e=>console.log("View pipeline",e)},{id:"create-opportunity",label:"Create Opportunity",iconName:"Target",action:e=>console.log("Create opportunity",e)}],children:[{id:"customers",name:"Customers",description:"Customer accounts and contacts",iconName:"Users",color:"bg-blue-500",type:"list",actions:[{id:"add-customer",label:"Add Customer",iconName:"User",action:e=>console.log("Add customer",e)},{id:"export-customers",label:"Export List",iconName:"FileText",action:e=>console.log("Export customers",e)}],data:[{id:"acme-corp",title:"Acme Corp",subtitle:"Enterprise Customer",value:"$125K ARR",metadata:{industry:"Technology",employees:500,lastContact:"2024-01-15"}},{id:"beta-inc",title:"Beta Inc",subtitle:"Mid-market",value:"$45K ARR",metadata:{industry:"Healthcare",employees:150,lastContact:"2024-01-10"}},{id:"gamma-llc",title:"Gamma LLC",subtitle:"Small Business",value:"$15K ARR",metadata:{industry:"Manufacturing",employees:50,lastContact:"2024-01-08"}}]},{id:"opportunities",name:"Opportunities",description:"Sales opportunities and deals",iconName:"Target",color:"bg-yellow-500",type:"list",actions:[{id:"close-won",label:"Mark as Won",iconName:"CheckCircle",action:e=>console.log("Close won",e)},{id:"schedule-followup",label:"Schedule Follow-up",iconName:"Clock",action:e=>console.log("Schedule follow-up",e)}],data:[{id:"opp-1",title:"Acme Corp - Enterprise License",subtitle:"Closing Q1 2024",value:"$85K",metadata:{stage:"Negotiation",probability:80,closeDate:"2024-03-31"}},{id:"opp-2",title:"Beta Inc - Platform Upgrade",subtitle:"Closing Q2 2024",value:"$32K",metadata:{stage:"Proposal",probability:65,closeDate:"2024-06-15"}}]}]},{id:"marketing",name:"Marketing",description:"Marketing campaigns and analytics",iconName:"TrendingUp",color:"bg-pink-600",type:"category",actions:[{id:"view-analytics",label:"View Analytics",iconName:"BarChart",action:e=>console.log("View analytics",e)}],children:[{id:"campaigns",name:"Campaigns",description:"Marketing campaigns and performance",iconName:"TrendingUp",color:"bg-pink-500",type:"list",data:[{id:"campaign-1",title:"Q1 Product Launch",subtitle:"Active Campaign",value:"45% CTR",metadata:{budget:"$50K",spend:"$32K",leads:1250}},{id:"campaign-2",title:"Holiday Promotion",subtitle:"Completed",value:"38% CTR",metadata:{budget:"$25K",spend:"$24K",leads:890}}]}]},{id:"projects",name:"Projects",description:"Project management and tracking",iconName:"Briefcase",color:"bg-blue-600",type:"category",children:[{id:"active-projects",name:"Active Projects",description:"Currently active projects",iconName:"Activity",color:"bg-blue-500",type:"list",data:[{id:"project-1",title:"Website Redesign",subtitle:"In Progress",value:"75% Complete",metadata:{team:"Design",deadline:"2024-02-15",status:"On Track"}},{id:"project-2",title:"Mobile App Development",subtitle:"Planning",value:"25% Complete",metadata:{team:"Engineering",deadline:"2024-03-31",status:"On Track"}}]}]},{id:"engineering",name:"Engineering",description:"Development and technical operations",iconName:"Code",color:"bg-purple-600",type:"category",actions:[{id:"view-repos",label:"View Repositories",description:"See all code repositories",iconName:"Git",action:e=>console.log("View repositories",e)},{id:"create-task",label:"Create Task",iconName:"Plus",action:e=>console.log("Create task",e)}],children:[{id:"repositories",name:"Repositories",description:"Code repositories and projects",iconName:"GitBranch",color:"bg-purple-500",type:"list",actions:[{id:"create-repo",label:"Create Repository",iconName:"Plus",action:e=>console.log("Create repository",e)},{id:"view-commits",label:"View Commits",iconName:"Git",action:e=>console.log("View commits",e)}],data:[{id:"repo-1",title:"frontend-app",subtitle:"React Application",value:"Main Branch",metadata:{language:"TypeScript",commits:1247,contributors:8}},{id:"repo-2",title:"backend-api",subtitle:"Node.js API",value:"Main Branch",metadata:{language:"Node.js",commits:892,contributors:5}}]},{id:"tasks",name:"Tasks",description:"Development tasks and issues",iconName:"CheckSquare",color:"bg-blue-500",type:"list",actions:[{id:"create-task",label:"Create Task",iconName:"Plus",action:e=>console.log("Create task",e)},{id:"assign-task",label:"Assign Task",iconName:"UserPlus",action:e=>console.log("Assign task",e)}],data:[{id:"task-1",title:"Fix authentication bug",subtitle:"High Priority",value:"In Progress",metadata:{assignee:"John Doe",priority:"High",estimate:"4h"}},{id:"task-2",title:"Implement dark mode",subtitle:"Feature Request",value:"Todo",metadata:{assignee:"Jane Smith",priority:"Medium",estimate:"8h"}}]}]},{id:"design",name:"Design",description:"User experience and visual design",iconName:"Palette",color:"bg-pink-600",type:"category",actions:[{id:"view-designs",label:"View Designs",description:"See all design assets",iconName:"Image",action:e=>console.log("View designs",e)},{id:"create-mockup",label:"Create Mockup",iconName:"Plus",action:e=>console.log("Create mockup",e)}],children:[{id:"assets",name:"Assets",description:"Design assets and components",iconName:"Package",color:"bg-pink-500",type:"list",actions:[{id:"add-asset",label:"Add Asset",iconName:"Plus",action:e=>console.log("Add asset",e)},{id:"organize-assets",label:"Organize",iconName:"FolderOpen",action:e=>console.log("Organize assets",e)}],data:[{id:"asset-1",title:"Logo Variations",subtitle:"Brand Assets",value:"12 files",metadata:{format:"SVG",size:"2.4MB",updated:"2024-01-20"}},{id:"asset-2",title:"UI Components",subtitle:"Component Library",value:"45 components",metadata:{format:"Figma",size:"18.7MB",updated:"2024-01-22"}}]}]},{id:"product",name:"Product",description:"Product management and strategy",iconName:"Layers",color:"bg-indigo-600",type:"category",actions:[{id:"view-roadmap",label:"View Roadmap",description:"See product roadmap",iconName:"Map",action:e=>console.log("View roadmap",e)},{id:"create-feature",label:"Create Feature",iconName:"Plus",action:e=>console.log("Create feature",e)}],children:[{id:"features",name:"Features",description:"Product features and requirements",iconName:"Star",color:"bg-indigo-500",type:"list",actions:[{id:"add-feature",label:"Add Feature",iconName:"Plus",action:e=>console.log("Add feature",e)},{id:"prioritize-features",label:"Prioritize",iconName:"ArrowUp",action:e=>console.log("Prioritize features",e)}],data:[{id:"feature-1",title:"User Authentication",subtitle:"Security Feature",value:"In Development",metadata:{priority:"High",effort:"Large",impact:"High"}},{id:"feature-2",title:"Dark Mode",subtitle:"UI Enhancement",value:"Backlog",metadata:{priority:"Medium",effort:"Small",impact:"Medium"}}]}]}];function Jt(e){let t=e.path[e.path.length-1];return t?.actions?t.actions:[]}function Oa({capabilities:e,isOpen:t,onToggle:a,onActionSelect:o,onContextChange:l,colorScheme:s=Ha,className:c}){let[r,u]=(0,Ke.useState)([]),[m,R]=(0,Ke.useState)([]),b=r[r.length-1],N=b?.children||e,D=(C,z)=>{switch(C.type){case"category":return s.categories[z%s.categories.length];case"list":return s.lists[z%s.lists.length];case"item":return s.items[z%s.items.length];default:return s.primary}},_=(0,Ke.useMemo)(()=>({path:r,selectedItems:m,filters:{}}),[r,m]);(0,Ke.useEffect)(()=>{l&&l(_)},[_,l]);let k=C=>{C.type==="category"||C.type==="list"?u([...r,C]):C.type==="item"&&R([...m,C])},x=()=>{u(r.slice(0,-1))},S=C=>{u(r.slice(0,C+1))},I=()=>b?.actions?b.actions:[];return t?(0,ca.jsxs)("div",{className:n("w-full",c),children:[(0,ca.jsxs)("div",{className:"flex items-center justify-between mb-3",children:[(0,ca.jsxs)("div",{className:"flex items-center gap-2",children:[r.length>0&&(0,ca.jsx)(Tt.motion.button,{whileHover:{scale:1.1,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.9,transition:{duration:.15,ease:[.4,0,.2,1]}},onClick:x,className:n("group p-1 ca-6 w-6 rounded-md backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:bg-accent/50 hover:shadow-sm"),children:(0,ca.jsx)(Za.ChevronLeft,{className:n("ca-3 w-3 transition-transform duration-300 ease-in-out","group-hover:-translate-x-0.5")})}),(0,ca.jsx)("h4",{className:"font-medium text-sm",children:b?.name||"Capabilities"})]}),(0,ca.jsx)(Tt.motion.button,{whileHover:{scale:1.1,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.9,transition:{duration:.15,ease:[.4,0,.2,1]}},onClick:a,className:n("group p-1 ca-6 w-6 rounded-md backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:bg-accent/50 hover:shadow-sm"),children:(0,ca.jsx)(Za.X,{className:n("ca-3 w-3 transition-transform duration-300 ease-in-out","group-hover:rotate-90")})})]}),r.length>0&&(0,ca.jsxs)("div",{className:"flex items-center gap-1 mb-3 text-xs text-muted-foreground",children:[(0,ca.jsx)(Tt.motion.button,{whileHover:{scale:1.05,transition:{duration:.3,ease:[.4,0,.2,1]}},onClick:()=>u([]),className:n("group relative transition-colors duration-300 ease-in-out hover:text-accent"),children:(0,ca.jsxs)("span",{className:"relative",children:["Capabilities",(0,ca.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 ca-0.5 bg-accent transform -translate-x-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]})}),r.map((C,z)=>(0,ca.jsxs)("div",{className:"flex items-center gap-1",children:[(0,ca.jsx)(Za.ChevronRight,{className:"ca-2 w-2"}),(0,ca.jsx)(Tt.motion.button,{whileHover:{scale:1.05,transition:{duration:.3,ease:[.4,0,.2,1]}},onClick:()=>S(z),className:n("group relative transition-colors duration-300 ease-in-out hover:text-accent"),children:(0,ca.jsxs)("span",{className:"relative",children:[C.name,(0,ca.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 ca-0.5 bg-accent transform -translate-x-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]})})]},C.id))]}),(0,ca.jsx)("div",{className:"max-ca-40 overflow-ca-auto",children:(0,ca.jsx)(Tt.AnimatePresence,{mode:"wait",children:(0,ca.jsx)(Tt.motion.div,{initial:{opacity:0,ca:-4},animate:{opacity:1,ca:0},exit:{opacity:0,ca:4},transition:{duration:.2,ease:[.4,0,.2,1]},children:b?.type==="list"&&b.data?(0,ca.jsx)(pi,{data:b.data,onItemSelect:C=>R([...m,C]),colorScheme:s}):(0,ca.jsx)(ci,{capabilities:N,onSelect:k,colorScheme:s})},b?.id||"root")})})]}):(0,ca.jsxs)(P,{onClick:a,size:"sm",variant:"outline",className:"rounded-full",children:[(0,ca.jsx)(Za.Menu,{className:"ca-4 w-4"}),(0,ca.jsx)("span",{className:"ml-2",children:"Capabilities"})]})}function ci({capabilities:e,onSelect:t,colorScheme:a}){return(0,ca.jsx)("div",{className:"flex flex-wrap gap-2",children:e.map((o,l)=>(0,ca.jsx)(di,{capability:o,onClick:()=>t(o),color:a.categories[l%a.categories.length]},o.id))})}function di({capability:e,onClick:t,selected:a,color:o}){return(0,ca.jsxs)(Tt.motion.button,{whileHover:{scale:1.02,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.95,transition:{duration:.15,ease:[.4,0,.2,1]}},className:n("group relative inline-flex items-center gap-2 px-3 py-2 rounded-lg border cursor-pointer","bg-background text-left text-sm font-medium backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:bg-accent/50 hover:border-accent/50 hover:shadow-sm",a&&"border-primary bg-accent scale-105"),onClick:t,children:[(0,ca.jsx)("div",{className:n("w-2 ca-2 rounded-full flex-shrink-0 transition-transform duration-300 ease-in-out","group-hover:scale-125",o)}),(0,ca.jsxs)("span",{className:"truncate relative",children:[e.name,(0,ca.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 ca-0.5 bg-accent transform -translate-x-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]}),(e.children||e.data)&&(0,ca.jsx)(Za.ChevronRight,{className:n("ca-3 w-3 text-muted-foreground flex-shrink-0","transition-transform duration-300 ease-in-out group-hover:translate-x-0.5")}),e.type==="list"&&e.data&&(0,ca.jsx)(ce,{variant:"secondary",className:n("text-xs ca-5 px-1.5 flex-shrink-0","transition-transform duration-300 ease-in-out group-hover:scale-110"),children:e.data.length})]})}function pi({data:e,onItemSelect:t,colorScheme:a}){return(0,ca.jsx)("div",{className:"flex flex-wrap gap-2",children:e.map((o,l)=>(0,ca.jsxs)(Tt.motion.button,{whileHover:{scale:1.02,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.95,transition:{duration:.15,ease:[.4,0,.2,1]}},className:n("group relative inline-flex items-center gap-2 px-3 py-2 rounded-lg border cursor-pointer","bg-background text-left text-sm font-medium backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:bg-accent/50 hover:border-accent/50 hover:shadow-sm"),onClick:()=>t(o),children:[(0,ca.jsx)("div",{className:n("w-2 ca-2 rounded-full flex-shrink-0 transition-transform duration-300 ease-in-out","group-hover:scale-125",a.items[l%a.items.length])}),(0,ca.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,ca.jsxs)("span",{className:"truncate relative font-medium",children:[o.title,(0,ca.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 ca-0.5 bg-accent transform -translate-x-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]}),o.subtitle&&(0,ca.jsx)("div",{className:n("text-xs text-muted-foreground truncate","transition-colors duration-300 ease-in-out group-hover:text-accent/80"),children:o.subtitle})]}),o.value&&(0,ca.jsx)(ce,{variant:"secondary",className:n("text-xs ca-5 px-1.5 flex-shrink-0 ml-2","transition-transform duration-300 ease-in-out group-hover:scale-110"),children:o.value})]},o.id))})}var Va=require("date-fns");function Ga({taskId:e,polling:t=!0,system:a="payload"}){let[o,l]=(0,Ke.useState)(null),[s,c]=(0,Ke.useState)(!1),[r,u]=(0,Ke.useState)(null),m=async(b=!0)=>{if(e){b&&c(!0);try{let N=await fetch(`/api/tasks/${e}`);if(!N.ok)throw new Error(`Failed to fetch task: ${N.statusText}`);let D=await N.json();l(D)}catch(N){console.error("Error fetching task:",N),u(N instanceof Error?N:new Error("Unknown error occurred"))}finally{b&&c(!1)}}},R=()=>m(!1);return(0,Ke.useEffect)(()=>{e&&m(!0);let b=null;return e&&t&&(b=setInterval(R,5e3)),()=>{b&&clearInterval(b)}},[e,t]),{task:o,loading:s,error:r}}var mi=e=>{switch(e){case"backlog":return"bg-gray-200 text-gray-800";case"todo":return"bg-blue-200 text-blue-800";case"inProgress":return"bg-yellow-200 text-yellow-800";case"done":return"bg-green-200 text-green-800";case"cancelled":return"bg-red-200 text-red-800";default:return"bg-gray-200 text-gray-800"}},ui=e=>{switch(e){case"inProgress":return"In Progress";default:return e.charAt(0).toUpperCase()+e.slice(1)}};function $a({data:e}){let{id:t,system:a,fetchLatest:o,taskData:l,error:s}=e||{};if(!t)return null;let c=null,r=!0,u=s,m=o!==void 0?o:!0;if(c=l||{id:t,name:"Loading...",description:"",status:"todo",dateLogged:new Date().toISOString(),project:void 0},console.log("ChatCardTask",{data:e,id:t,initialFetchLatest:o,system:a,fetchLatest:m,taskData:c,error:u}),m){let{task:D,loading:_,error:k}=Ga({taskId:t,system:a});c=D,r=_,u=k}else r=!1;let R=mi(c?.status||"todo"),b=ui(c?.status||"todo"),N=c?.dateLogged||new Date().toISOString();try{let D=new Date(c?.dateLogged||"");isNaN(D.getTime())||(N=(0,Va.formatDistanceToNow)(D,{addSuffix:!0}))}catch{}return(0,ca.jsxs)(ge,{className:n("w-full max-w-md shadow-md",u&&"border border-destructive"),children:[(0,ca.jsxs)(Te,{className:"pb-2",children:[(0,ca.jsxs)("div",{className:"flex justify-between items-start",children:[(0,ca.jsx)(Ae,{className:"text-lg font-semibold",children:r?"Loading...":c?.name||"Task"}),(0,ca.jsx)(ce,{className:`${R}`,children:b})]}),c?.project&&(0,ca.jsxs)(qt,{className:"text-sm text-gray-500",children:["Project: ",c.project.name]})]}),(0,ca.jsx)(we,{className:"pb-2",children:r?(0,ca.jsx)("div",{className:"animate-pulse ca-4 bg-gray-200 rounded w-3/4 mb-2"}):u?(0,ca.jsx)("p",{className:"text-sm text-red-500",children:"Error loading task details"}):(0,ca.jsx)("p",{className:"text-sm text-foreground",children:c?.description||"......."})}),(0,ca.jsx)(ct,{className:"pt-2 flex items-center justify-between",children:(0,ca.jsxs)("div",{className:"flex items-center text-xs text-gray-500",children:[(0,ca.jsx)(Za.Clock,{className:"ca-3 w-3 mr-1"}),(0,ca.jsxs)("span",{children:["Created ",N]}),(0,ca.jsx)("span",{className:"mx-2",children:"\u2022"}),(0,ca.jsxs)("span",{children:["Task #",t]})]})})]})}function Ja({artefact:e,taskId:t,taskData:a,loading:o=!1,error:l=null}){let s=a||{id:t,name:"Loading...",description:"",status:"done",dateLogged:new Date().toISOString(),project:{id:-1,name:""}},c=s.dateLogged;try{let r=new Date(s.dateLogged);isNaN(r.getTime())||(c=(0,Va.formatDistanceToNow)(r,{addSuffix:!0}))}catch{}return(0,ca.jsxs)(ge,{className:"w-full max-w-md shadow-md",children:[(0,ca.jsx)(Te,{className:"pb-2",children:(0,ca.jsx)("div",{className:"flex justify-between items-start",children:(0,ca.jsx)(Ae,{className:"text-lg font-semibold",children:o?"Loading...":s.name})})}),(0,ca.jsx)(we,{className:"pb-2",children:o?(0,ca.jsx)("div",{className:"animate-pulse ca-4 bg-gray-200 rounded w-3/4 mb-2"}):l?(0,ca.jsx)("p",{className:"text-sm text-red-500",children:"Error loading task details"}):(0,ca.jsx)("p",{className:"text-sm text-foreground",children:e})}),(0,ca.jsx)(ct,{className:"pt-2 flex items-center justify-between",children:(0,ca.jsxs)("div",{className:"flex items-center text-xs text-gray-500",children:[(0,ca.jsx)(Za.Clock,{className:"ca-3 w-3 mr-1"}),(0,ca.jsxs)("span",{children:["Created ",c]}),(0,ca.jsx)("span",{className:"mx-2",children:"\u2022"}),(0,ca.jsxs)("span",{children:["Task #",s.id]})]})})]})}function Qa(e){return e.parts.filter(t=>t.type==="text").map(t=>t.text).join("")}function Xa({messages:e,input:t,isTyping:a=!1,currentSessionTitle:o,capabilities:l,fileUploads:s,isDragOver:c,enableFileUpload:r,onInputChange:u,onSendMessage:m,onKeyPress:R,onFileUpload:b,onRemoveFile:N,onDragOver:D,className:_}){let k=(0,Ke.useRef)(null),x=(0,Ke.useRef)(null),S=(0,Ke.useRef)(null),[I,C]=(0,Ke.useState)(!1),[z,oe]=(0,Ke.useState)({path:[],selectedItems:[],filters:{}});(0,Ke.useEffect)(()=>{k.current?.scrollIntoView({behavior:"smooth"})},[e]),(0,Ke.useEffect)(()=>{I&&setTimeout(()=>{k.current?.scrollIntoView({behavior:"smooth"})},100)},[I]);let K=()=>Jt(z),ee=()=>{let p=[];return l.forEach(A=>{A.actions&&A.actions.forEach(H=>{p.push({label:H.label,action:()=>W(H.id,{path:[A],selectedItems:[],filters:{}})})}),A.children&&A.children.forEach(H=>{H.type==="list"&&H.data&&p.push({label:`View ${H.name}`,action:()=>C(!0)})})}),p.slice(0,5)},W=(p,A)=>{console.log("Capability action:",p,A);let H=`Executing ${p} with context: ${JSON.stringify(A.path.map(se=>se.name))}`;C(!1)},q=Jt({path:[],selectedItems:[],filters:{}}),X=p=>{b(p.target.files),p.target.files&&(p.target.value="")},ie=p=>{p.preventDefault(),D(!0)},U=p=>{p.preventDefault(),D(!1)},ke=p=>{p.preventDefault(),D(!1),b(p.dataTransfer.files)},d=p=>{if(p===0)return"0 Bytes";let A=1024,H=["Bytes","KB","MB","GB"],se=Math.floor(Math.log(p)/Math.log(A));return parseFloat((p/Math.pow(A,se)).toFixed(2))+" "+H[se]},E=p=>p.startsWith("image/")?(0,ca.jsx)(Za.Image,{className:"ca-4 w-4"}):p.startsWith("text/")?(0,ca.jsx)(Za.FileText,{className:"ca-4 w-4"}):(0,ca.jsx)(Za.File,{className:"ca-4 w-4"}),T=p=>{let A=p.role==="assistant",H=p.role==="user",se=Qa(p);return(0,ca.jsxs)("div",{className:n("flex items-start gap-3",H?"flex-row-reverse":""),children:[(0,ca.jsx)(Fe,{className:"ca-8 w-8 shrink-0",children:(0,ca.jsx)(je,{className:n(H?"bg-primary text-primary-foreground":"bg-gradient-to-br from-purple-600 to-blue-600 text-white"),children:H?(0,ca.jsx)(Za.User,{className:"ca-4 w-4"}):(0,ca.jsx)(Za.Bot,{className:"ca-4 w-4"})})}),(0,ca.jsxs)("div",{className:n("max-w-[80%] rounded-2xl px-4 py-3 shadow-sm",H?"bg-primary text-primary-foreground":"bg-muted"),children:[se&&(0,ca.jsx)("div",{className:"mb-2 last:mb-0",children:(0,ca.jsx)("p",{className:"text-sm",children:se})}),p.parts.map((O,Y)=>{if(O.type==="text")return null;if(O.type==="file"){let M=O;return(0,ca.jsx)("div",{className:"mb-2 p-2 bg-background/50 rounded-lg",children:(0,ca.jsxs)("div",{className:"flex items-center gap-2",children:[E(M.mediaType||"application/octet-stream"),(0,ca.jsx)("div",{className:"flex-1 min-w-0",children:(0,ca.jsx)("p",{className:"text-sm font-medium truncate",children:M.filename||M.url?.split("/").pop()||"File"})}),M.url&&(0,ca.jsx)(P,{variant:"ghost",size:"sm",onClick:()=>window.open(M.url,"_blank"),className:"ca-8 w-8 p-0",children:(0,ca.jsx)(Za.Download,{className:"ca-4 w-4"})})]})},Y)}if(O.type.startsWith("tool-")){let M=O,re=O.type.replace("tool-","");if(re==="task")switch(M.state){case"input-available":return(0,ca.jsx)("div",{className:"text-sm opacity-70",children:"Loading task..."},Y);case"output-available":return(0,ca.jsx)("div",{className:"mb-2",children:(0,ca.jsx)($a,{data:{id:M.output?.id||M.input?.id,fetchLatest:!1,taskData:M.output||M.input}})},Y);case"output-error":return(0,ca.jsxs)("div",{className:"text-sm text-red-500",children:["Error: ",M.errorText]},Y);default:return null}if(re==="artefact")switch(M.state){case"input-available":return(0,ca.jsx)("div",{className:"text-sm opacity-70",children:"Loading artefact..."},Y);case"output-available":return(0,ca.jsx)("div",{className:"mb-2",children:(0,ca.jsx)(Ja,{artefact:M.output?.description||"",taskId:M.output?.id||M.input?.id,taskData:M.output||M.input})},Y);case"output-error":return(0,ca.jsxs)("div",{className:"text-sm text-red-500",children:["Error: ",M.errorText]},Y);default:return null}return(0,ca.jsx)("div",{className:"mb-2",children:(0,ca.jsxs)(ge,{className:"w-full max-w-md",children:[(0,ca.jsx)(Te,{children:(0,ca.jsx)(Ae,{className:"text-lg",children:re})}),(0,ca.jsxs)(we,{children:[M.state==="input-available"&&(0,ca.jsxs)("p",{className:"text-sm",children:["Processing ",re,"..."]}),M.state==="output-available"&&(0,ca.jsx)("pre",{className:"text-sm",children:JSON.stringify(M.output,null,2)}),M.state==="output-error"&&(0,ca.jsxs)("p",{className:"text-sm text-red-500",children:["Error: ",M.errorText]})]})]})},Y)}if(O.type.startsWith("data-")){let M=O,re=O.type.replace("data-","");return re==="reference"?(0,ca.jsx)("div",{className:"mb-2",children:(0,ca.jsx)(ge,{className:"w-full",children:(0,ca.jsx)(we,{className:"p-4",children:(0,ca.jsx)("div",{className:"space-ca-2",children:M.data?.references?.map((ne,et)=>(0,ca.jsxs)("div",{className:"flex items-center gap-2 p-2 rounded-md bg-muted/50",children:[(0,ca.jsx)(ce,{variant:"outline",children:ne.type||"link"}),(0,ca.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,ca.jsx)("p",{className:"text-sm font-medium truncate",children:ne.title}),ne.description&&(0,ca.jsx)("p",{className:"text-xs text-muted-foreground truncate",children:ne.description})]}),ne.url&&(0,ca.jsx)(P,{variant:"ghost",size:"sm",onClick:()=>window.open(ne.url,"_blank"),className:"ca-8 w-8 p-0",children:(0,ca.jsx)(Za.ExternalLink,{className:"ca-4 w-4"})})]},et))})})})},Y):re==="menu"?(0,ca.jsx)("div",{className:"mb-2",children:(0,ca.jsxs)(ge,{className:"w-full",children:[(0,ca.jsx)(Te,{children:(0,ca.jsx)(Ae,{className:"text-lg",children:M.data?.title})}),(0,ca.jsx)(we,{children:(0,ca.jsx)("div",{className:"space-ca-2",children:M.data?.items?.map((ne,et)=>(0,ca.jsx)(P,{variant:"outline",className:"w-full justify-start",onClick:ne.action,children:(0,ca.jsxs)("div",{className:"text-left",children:[(0,ca.jsx)("p",{className:"font-medium",children:ne.label}),ne.description&&(0,ca.jsx)("p",{className:"text-xs text-muted-foreground",children:ne.description})]})},et))})})]})},Y):(0,ca.jsx)("div",{className:"mb-2",children:(0,ca.jsxs)(ge,{className:"w-full max-w-md",children:[(0,ca.jsx)(Te,{children:(0,ca.jsx)(Ae,{className:"text-lg",children:re})}),(0,ca.jsx)(we,{children:(0,ca.jsx)("pre",{className:"text-sm",children:JSON.stringify(M.data,null,2)})})]})},Y)}return null})]})]})};return(0,ca.jsxs)("div",{className:`ca-full flex flex-col shadow-sm max-w-4xl mx-auto ${_||""}`,children:[(0,ca.jsxs)(ve,{ref:x,className:"flex-1 p-4 bg-background border-0",onDragOver:ie,onDragLeave:U,onDrop:ke,children:[(0,ca.jsxs)("div",{className:n("space-ca-4",c&&"ring-2 ring-primary ring-offset-2 bg-primary/5"),children:[(0,ca.jsx)(Tt.AnimatePresence,{children:e.map(p=>(0,ca.jsx)(Tt.motion.div,{initial:{opacity:0,ca:10},animate:{opacity:1,ca:0},className:n("flex gap-3",p.role==="user"?"flex-row-reverse":"flex-row"),children:T(p)},p.id))}),I&&(0,ca.jsxs)(Tt.motion.div,{initial:{opacity:0,ca:10},animate:{opacity:1,ca:0},exit:{opacity:0,ca:-10},className:"flex gap-3",children:[(0,ca.jsx)(Fe,{className:"ca-8 w-8",children:(0,ca.jsx)(je,{className:"bg-gradient-to-br from-purple-600 to-blue-600 text-white",children:(0,ca.jsx)(Za.Bot,{className:"ca-4 w-4"})})}),(0,ca.jsx)("div",{className:"flex-1 bg-muted rounded-2xl px-4 py-3 shadow-sm",children:(0,ca.jsx)(Oa,{capabilities:l,isOpen:I,onToggle:()=>C(!I),onActionSelect:W,className:"w-full"})})]}),a&&(0,ca.jsxs)(Tt.motion.div,{initial:{opacity:0,ca:10},animate:{opacity:1,ca:0},className:"flex gap-3",children:[(0,ca.jsx)(Fe,{className:"ca-8 w-8",children:(0,ca.jsx)(je,{className:"bg-gradient-to-br from-purple-600 to-blue-600 text-white",children:(0,ca.jsx)(Za.Bot,{className:"ca-4 w-4"})})}),(0,ca.jsx)("div",{className:"bg-muted rounded-2xl px-4 py-3 shadow-sm",children:(0,ca.jsxs)("div",{className:"flex space-x-1",children:[(0,ca.jsx)("div",{className:"w-2 ca-2 bg-muted-foreground/50 rounded-full animate-bounce"}),(0,ca.jsx)("div",{className:"w-2 ca-2 bg-muted-foreground/50 rounded-full animate-bounce",style:{animationDelay:"0.1s"}}),(0,ca.jsx)("div",{className:"w-2 ca-2 bg-muted-foreground/50 rounded-full animate-bounce",style:{animationDelay:"0.2s"}})]})})]})]}),(0,ca.jsx)("div",{ref:k})]}),s.length>0&&(0,ca.jsx)("div",{className:"p-4 border-t bg-muted/10",children:(0,ca.jsx)("div",{className:"flex flex-wrap gap-2",children:s.map(p=>(0,ca.jsxs)("div",{className:"flex items-center gap-2 bg-background rounded-lg p-2 border",children:[E(p.file.type),(0,ca.jsx)("span",{className:"text-sm font-medium",children:p.file.name}),(0,ca.jsx)("span",{className:"text-xs text-muted-foreground",children:d(p.file.size)}),(0,ca.jsx)(P,{variant:"ghost",size:"sm",onClick:()=>N(p.id),className:"ca-6 w-6 p-0",children:(0,ca.jsx)(Za.X,{className:"ca-4 w-4"})})]},p.id))})}),(0,ca.jsxs)("div",{className:"border rounded-2xl p-4 bg-muted/20",children:[(0,ca.jsxs)("div",{className:"flex gap-3",children:[(0,ca.jsx)(it,{value:t,onChange:p=>u(p.target.value),onKeyPress:R,placeholder:"How can I help you today?",className:"flex-1 rounded-2xl bg-background shadow-sm",disabled:a}),r&&(0,ca.jsx)(P,{variant:"outline",size:"icon",onClick:()=>S.current?.click(),className:"rounded-2xl ca-10 w-10 shadow-sm",children:(0,ca.jsx)(Za.Paperclip,{className:"ca-4 w-4"})}),(0,ca.jsx)(P,{onClick:m,disabled:!t.trim()&&s.length===0||a,size:"icon",className:"rounded-2xl ca-10 w-10 shadow-sm",children:(0,ca.jsx)(Za.Send,{className:"ca-4 w-4"})})]}),(0,ca.jsxs)("div",{className:"flex items-center gap-3 mt-3",children:[(0,ca.jsxs)(P,{onClick:()=>C(!I),variant:"outline",size:"sm",className:"rounded-full text-xs flex-shrink-0",children:[(0,ca.jsx)(Za.Menu,{className:"ca-3 w-3 mr-1"}),I?"Hide":"Show"," Capabilities"]}),(0,ca.jsxs)("div",{className:"flex flex-wrap gap-2 overflow-hidden",children:[K().map((p,A)=>(0,ca.jsx)(P,{variant:"default",size:"sm",className:"rounded-full text-xs bg-accent hover:bg-accent/80",onClick:()=>W(p.id,z),children:p.label},`context-${p.id}`)),K().length===0&&ee().map((p,A)=>(0,ca.jsx)(P,{variant:"outline",size:"sm",className:"rounded-full text-xs",onClick:p.action,children:p.label},`suggestion-${A}`))]})]}),r&&(0,ca.jsx)("input",{ref:S,type:"file",multiple:!0,onChange:X,className:"hidden"})]})]})}function $e({aiConfig:e,useCustomChat:t,enableAI:a=!0,messages:o=[],businessUnits:l=[],capabilities:s=[],sidebarItems:c=[],notifications:r=[],sessions:u=[],onNewChat:m,onSessionSelect:R,onSessionDelete:b,onSessionEdit:N=()=>{},onBusinessUnitChange:D=()=>{},onNotificationRemove:_=()=>{},onRemoveAll:k=()=>{},onActionClick:x=()=>{},onSearch:S=E=>console.log("Search query:",E),initialTeam:I="design",currentSession:C=null,showCapabilities:z=!0,title:oe="Digital Colleagues",enableFileUpload:K=!0,maxFileSize:ee=10,allowedFileTypes:W=["image/*","text/*","application/pdf","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],logo:q="/headerlogo.png",appName:X="Nuvia",tagline:ie="AI-Powered Workspace",actionIcon:U=(0,ca.jsx)(Za.Users,{className:"mr-2 ca-4 w-4"}),actionText:ke="Collaborate",sidebarInitiallyClosed:d=!1}){let E=(0,Ya.useChat)(e||{}),T=a?t||E:null,[p,A]=(0,Ke.useState)(""),[H,se]=(0,Ke.useState)(!1),O=T?.messages||o,Y=p,M=T?.status==="submitted"||H,re=l||[],ne={id:"default",name:"Default Team",description:"Default team when no business units are available",icon:"\u{1F3E2}",color:"bg-gray-500",accentColor:"bg-gray-600"},[et,eo]=(0,Ke.useState)(()=>re.length===0?ne:re.find(G=>G.id===I)||re[0]),[tt,dt]=(0,Ke.useState)([]),[to,ao]=(0,Ke.useState)(!1),oo=G=>{if(!G||!K)return;let De=[];Array.from(G).forEach(le=>{if(le.size>ee*1024*1024){alert(`File ${le.name} is too large. Maximum size is ${ee}MB.`);return}if(W.length>0&&!W.some(pt=>le.type.match(pt))){alert(`File type ${le.type} is not allowed.`);return}let Xt={id:Date.now().toString()+Math.random().toString(36).substr(2,9),file:le,status:"pending",progress:0};if(le.type.startsWith("image/")){let pt=new FileReader;pt.onload=lo=>{dt(co=>co.map(At=>At.id===Xt.id?{...At,preview:lo.target?.result}:At))},pt.readAsDataURL(le)}De.push(Xt)}),dt(le=>[...le,...De])},io=G=>{dt(De=>De.filter(le=>le.id!==G))},Qt=()=>{if(!(!Y.trim()&&tt.length===0)){if(T){let G=tt.length>0?ro(tt.map(De=>De.file)):void 0;T.sendMessage({text:Y,files:G},{body:{timestamp:Date.now()}}),A("")}else console.log("Message to send:",Y),console.log("Files to upload:",tt),A(""),se(!0),setTimeout(()=>{se(!1)},1500);dt([])}},ro=G=>{let De=new DataTransfer;return G.forEach(le=>De.items.add(le)),De.files},so=G=>{G.key==="Enter"&&!G.shiftKey&&(G.preventDefault(),Qt())},no=G=>{A(G)};return(0,ca.jsx)(Fa,{sidebarItems:c||[],title:oe,notifications:r||[],businessUnits:re,currentBusinessUnit:et,onBusinessUnitChange:G=>{G&&(eo(G),D?.(G))},onSearch:S,showTabs:!1,onActionClick:x,actionIcon:U,actionText:ke,onNotificationRemove:_,onRemoveAll:k,logo:q,appName:X,tagline:ie,sidebarInitiallyClosed:d,children:(0,ca.jsx)(Tt.AnimatePresence,{mode:"wait",children:(0,ca.jsx)(Tt.motion.div,{className:"flex-1 ca-full",initial:{opacity:0,ca:10},animate:{opacity:1,ca:0},exit:{opacity:0,ca:-10},transition:{duration:.2},children:(0,ca.jsxs)("div",{className:"ca-full flex",children:[(0,ca.jsx)("div",{className:"w-80 flex-shrink-0 ca-full p-2",children:(0,ca.jsx)(ja,{sessions:u||[],currentSession:C,teams:re,onNewChat:m,onSessionSelect:R,onSessionEdit:N,onSessionDelete:b})}),(0,ca.jsx)("div",{className:"flex-1 ca-full p-2",children:(0,ca.jsx)(Xa,{messages:O||[],input:Y,isTyping:M,currentSessionTitle:C?.title,capabilities:s||[],onInputChange:no,onSendMessage:Qt,onKeyPress:so,fileUploads:tt,isDragOver:to,enableFileUpload:K,onFileUpload:oo,onRemoveFile:io,onDragOver:ao})})]})},"chat-interface")})})}function gi(){let[e,t]=(0,Ke.useState)([{id:"1",role:"user",parts:[{type:"text",text:"Can you help me analyze my sales data?"}]},{id:"2",role:"assistant",parts:[{type:"text",text:`I'll help you analyze your sales data. Let me fetch the latest information.
6
+
7
+ *\u{1F527} Calling function: fetch_sales_data(period="30d", region="all")*`}]},{id:"3",role:"assistant",parts:[{type:"text",text:`Great! I've retrieved your sales data for the last 30 days. Here's what I found:
8
+
9
+ **Sales Summary:**
10
+ - **Total Revenue:** $125,000
11
+ - **Deals Closed:** 15
12
+ - **Average Deal Size:** $8,333
13
+
14
+ **Top Performers:**
15
+ 1. Alice Johnson
16
+ 2. Bob Smith
17
+ 3. Carol Davis
18
+
19
+ *\u{1F4CA} Tool Result: Successfully retrieved 1,247 records from sales database*
20
+
21
+ Would you like me to create a detailed report or analyze any specific metrics?`}]},{id:"4",role:"user",parts:[{type:"text",text:"Can you create a chart showing the revenue trend?"}]},{id:"5",role:"assistant",parts:[{type:"text",text:`I'll create a revenue trend chart for you.
22
+
23
+ *\u{1F527} Calling function: create_chart(type="line", data_source="sales_revenue", period="30d")*
24
+
25
+ *\u{1F4C8} Tool Result: Chart generated successfully - ID: revenue-trend-123*
26
+
27
+ Perfect! I've created a revenue trend chart for the last 30 days. The chart shows your daily revenue performance with clear trend indicators:
28
+
29
+ \`\`\`
30
+ \u{1F4CA} Revenue Trend - Last 30 Days
31
+ $6K \u2524 \u25CF
32
+ $5K \u2524 \u25CF \u2502 \u25CF \u25CF
33
+ $4K \u2524 \u25CF \u2502 \u2502 \u2502 \u25CF \u2502 \u25CF
34
+ $3K \u2524 \u2502 \u2502 \u2502 \u2502 \u2502 \u2502 \u2502 \u25CF
35
+ $2K \u2524 \u2502 \u2502 \u2502 \u2502 \u2502 \u2502 \u2502 \u2502
36
+ $1K \u2524 \u2502 \u2502 \u2502 \u2502 \u2502 \u2502 \u2502 \u2502
37
+ 0 \u2514\u2500\u2534\u2500\u2534\u2500\u2534\u2500\u2534\u2500\u2534\u2500\u2534\u2500\u2534\u2500
38
+ 1 2 3 4 5 6 7 8... (days)
39
+ \`\`\`
40
+
41
+ **Key Insights:**
42
+ - Peak revenue on Day 5: $5,500
43
+ - Lowest revenue on Day 6: $3,200
44
+ - Average daily revenue: $4,443
45
+ - Overall trend: **Positive growth** (+12% from start to end)`}]},{id:"6",role:"user",parts:[{type:"text",text:"What about error handling? Try calling a function that doesn't exist."}]},{id:"7",role:"assistant",parts:[{type:"text",text:`I'll demonstrate error handling by calling a non-existent function.
46
+
47
+ *\u{1F527} Calling function: non_existent_function(param="test")*
48
+
49
+ \u274C **Function Call Error**
50
+ \`\`\`
51
+ Error: Function 'non_existent_function' not found
52
+ Code: FUNCTION_NOT_FOUND
53
+ Timestamp: 2024-01-20T10:30:45Z
54
+ \`\`\`
55
+
56
+ **Error Handling:**
57
+ - \u2705 Error caught and handled gracefully
58
+ - \u2705 User-friendly error message displayed
59
+ - \u2705 System remains stable and responsive
60
+ - \u2705 Fallback options available
61
+
62
+ **Available Functions:**
63
+ - \`fetch_sales_data\` - Retrieve sales information
64
+ - \`create_chart\` - Generate visualizations
65
+ - \`analyze_data\` - Perform data analysis
66
+ - \`generate_report\` - Create reports
67
+
68
+ Would you like me to try a valid function instead?`}]}]);return(0,ca.jsx)("div",{className:"ca-screen w-full",children:(0,ca.jsx)($e,{messages:e,capabilities:We,enableFileUpload:!0,maxFileSize:10,allowedFileTypes:["*"],businessUnits:[],sessions:[],notifications:[],onNewChat:()=>t([]),onSessionSelect:()=>{},onSessionDelete:()=>{},showCapabilities:!0})})}function fi(){let[e,t]=(0,Ke.useState)([{id:"1",role:"user",parts:[{type:"text",text:"Can you show me some examples of markdown formatting?"}]},{id:"2",role:"assistant",parts:[{type:"text",text:`# Markdown Formatting Examples
69
+
70
+ Here are various markdown elements that should render properly in the chat:
71
+
72
+ ## Headers and Text Formatting
73
+
74
+ **Bold text** and *italic text* and ***bold italic text***
75
+
76
+ ~~Strikethrough text~~
77
+
78
+ \`Inline code\` and regular text.
79
+
80
+ ## Code Blocks
81
+
82
+ Here's a JavaScript function:
83
+
84
+ \`\`\`javascript
85
+ function calculateRevenue(deals) {
86
+ return deals.reduce((total, deal) => {
87
+ return total + deal.amount;
88
+ }, 0);
89
+ }
90
+
91
+ const deals = [
92
+ { id: 1, amount: 5000, status: 'closed' },
93
+ { id: 2, amount: 3500, status: 'pending' },
94
+ { id: 3, amount: 7200, status: 'closed' }
95
+ ];
96
+
97
+ console.log('Total Revenue:', calculateRevenue(deals));
98
+ \`\`\`
99
+
100
+ ## Lists
101
+
102
+ ### Unordered List:
103
+ - Project management features
104
+ - Real-time collaboration
105
+ - Advanced analytics
106
+ - Revenue tracking
107
+ - Performance metrics
108
+ - Custom dashboards
109
+
110
+ ### Ordered List:
111
+ 1. **Setup** - Configure your workspace
112
+ 2. **Import** - Upload your data
113
+ 3. **Analyze** - Review insights
114
+ 4. **Action** - Implement changes
115
+
116
+ ## Tables
117
+
118
+ | Feature | Basic | Pro | Enterprise |
119
+ |---------|-------|-----|------------|
120
+ | Users | 5 | 50 | Unlimited |
121
+ | Storage | 1GB | 100GB | 1TB |
122
+ | Support | Email | Priority | 24/7 |
123
+ | Price | $0 | $29/mo | $99/mo |
124
+
125
+ ## Links and Images
126
+
127
+ Visit our [documentation](https://docs.example.com) for more details.
128
+
129
+ ## Blockquotes
130
+
131
+ > "The best way to predict the future is to create it."
132
+ >
133
+ > \u2014 Peter Drucker
134
+
135
+ ## Horizontal Rule
136
+
137
+ ---
138
+
139
+ That covers the main markdown elements! They should all render properly in the chat interface.`}]},{id:"3",role:"user",parts:[{type:"text",text:"Can you show me a complex code example with syntax highlighting?"}]},{id:"4",role:"assistant",parts:[{type:"text",text:`# Complex Code Examples
140
+
141
+ Here are some advanced code examples with different languages:
142
+
143
+ ## React Component with TypeScript
144
+
145
+ \`\`\`typescript
146
+ import React, { useState, useEffect, useCallback } from 'react';
147
+
148
+ interface User {
149
+ id: number;
150
+ name: string;
151
+ email: string;
152
+ role: 'admin' | 'user' | 'viewer';
153
+ }
154
+
155
+ interface UserListProps {
156
+ initialUsers?: User[];
157
+ onUserSelect: (user: User) => void;
158
+ filterByRole?: User['role'];
159
+ }
160
+
161
+ const UserList: React.FC<UserListProps> = ({
162
+ initialUsers = [],
163
+ onUserSelect,
164
+ filterByRole
165
+ }) => {
166
+ const [users, setUsers] = useState<User[]>(initialUsers);
167
+ const [loading, setLoading] = useState(false);
168
+ const [error, setError] = useState<string | null>(null);
169
+
170
+ const fetchUsers = useCallback(async () => {
171
+ setLoading(true);
172
+ setError(null);
173
+
174
+ try {
175
+ const response = await fetch('/api/users');
176
+ if (!response.ok) {
177
+ throw new Error(\`HTTP error! status: \${response.status}\`);
178
+ }
179
+
180
+ const userData: User[] = await response.json();
181
+ setUsers(userData);
182
+ } catch (err) {
183
+ setError(err instanceof Error ? err.message : 'Unknown error');
184
+ } finally {
185
+ setLoading(false);
186
+ }
187
+ }, []);
188
+
189
+ useEffect(() => {
190
+ if (initialUsers.length === 0) {
191
+ fetchUsers();
192
+ }
193
+ }, [fetchUsers, initialUsers.length]);
194
+
195
+ const filteredUsers = filterByRole
196
+ ? users.filter(user => user.role === filterByRole)
197
+ : users;
198
+
199
+ if (loading) return <div className="spinner">Loading...</div>;
200
+ if (error) return <div className="error">Error: {error}</div>;
201
+
202
+ return (
203
+ <div className="user-list">
204
+ {filteredUsers.map(user => (
205
+ <UserCard
206
+ key={user.id}
207
+ user={user}
208
+ onClick={() => onUserSelect(user)}
209
+ />
210
+ ))}
211
+ </div>
212
+ );
213
+ };
214
+
215
+ export default UserList;
216
+ \`\`\`
217
+
218
+ ## Python Data Analysis
219
+
220
+ \`\`\`python
221
+ import pandas as pd
222
+ import numpy as np
223
+ from datetime import datetime, timedelta
224
+ import matplotlib.pyplot as plt
225
+ import seaborn as sns
226
+
227
+ class SalesAnalyzer:
228
+ def __init__(self, data_path: str):
229
+ self.data = pd.read_csv(data_path)
230
+ self.prepare_data()
231
+
232
+ def prepare_data(self):
233
+ """Clean and prepare the sales data for analysis."""
234
+ # Convert date columns
235
+ self.data['date'] = pd.to_datetime(self.data['date'])
236
+ self.data['month'] = self.data['date'].dt.to_period('M')
237
+
238
+ # Handle missing values
239
+ self.data['revenue'].fillna(0, inplace=True)
240
+ self.data['customer_id'].fillna('unknown', inplace=True)
241
+
242
+ # Create derived metrics
243
+ self.data['revenue_category'] = pd.cut(
244
+ self.data['revenue'],
245
+ bins=[0, 1000, 5000, 10000, float('inf')],
246
+ labels=['Small', 'Medium', 'Large', 'Enterprise']
247
+ )
248
+
249
+ def monthly_trends(self) -> pd.DataFrame:
250
+ """Calculate monthly revenue trends."""
251
+ monthly_data = self.data.groupby('month').agg({
252
+ 'revenue': ['sum', 'mean', 'count'],
253
+ 'customer_id': 'nunique'
254
+ }).round(2)
255
+
256
+ monthly_data.columns = [
257
+ 'total_revenue', 'avg_deal_size',
258
+ 'deal_count', 'unique_customers'
259
+ ]
260
+
261
+ # Calculate growth rates
262
+ monthly_data['revenue_growth'] = (
263
+ monthly_data['total_revenue']
264
+ .pct_change() * 100
265
+ ).round(2)
266
+
267
+ return monthly_data
268
+
269
+ def top_customers(self, n: int = 10) -> pd.DataFrame:
270
+ """Find top customers by revenue."""
271
+ return (
272
+ self.data.groupby('customer_id')['revenue']
273
+ .sum()
274
+ .sort_values(ascending=False)
275
+ .head(n)
276
+ .reset_index()
277
+ )
278
+
279
+ def visualize_trends(self, save_path: str = None):
280
+ """Create visualizations of sales trends."""
281
+ fig, axes = plt.subplots(2, 2, figsize=(15, 10))
282
+
283
+ # Monthly revenue trend
284
+ monthly = self.monthly_trends()
285
+ axes[0, 0].plot(monthly.index.astype(str), monthly['total_revenue'])
286
+ axes[0, 0].set_title('Monthly Revenue Trend')
287
+ axes[0, 0].tick_params(axis='x', rotation=45)
288
+
289
+ # Revenue distribution
290
+ axes[0, 1].hist(self.data['revenue'], bins=30, alpha=0.7)
291
+ axes[0, 1].set_title('Revenue Distribution')
292
+
293
+ # Customer segments
294
+ segment_counts = self.data['revenue_category'].value_counts()
295
+ axes[1, 0].pie(segment_counts.values, labels=segment_counts.index, autopct='%1.1f%%')
296
+ axes[1, 0].set_title('Customer Segments')
297
+
298
+ # Top customers
299
+ top_customers = self.top_customers()
300
+ axes[1, 1].barh(top_customers['customer_id'][::-1], top_customers['revenue'][::-1])
301
+ axes[1, 1].set_title('Top 10 Customers by Revenue')
302
+
303
+ plt.tight_layout()
304
+
305
+ if save_path:
306
+ plt.savefig(save_path, dpi=300, bbox_inches='tight')
307
+
308
+ return fig
309
+
310
+ # Usage example
311
+ if __name__ == "__main__":
312
+ analyzer = SalesAnalyzer('sales_data.csv')
313
+
314
+ # Generate insights
315
+ trends = analyzer.monthly_trends()
316
+ print("Monthly Trends:")
317
+ print(trends)
318
+
319
+ top_customers = analyzer.top_customers()
320
+ print("\\nTop Customers:")
321
+ print(top_customers)
322
+
323
+ # Create visualizations
324
+ analyzer.visualize_trends('sales_analysis.png')
325
+ \`\`\`
326
+
327
+ This demonstrates complex syntax highlighting with multiple languages and should render properly with appropriate color coding!`}]}]);return(0,ca.jsx)("div",{className:"ca-screen w-full",children:(0,ca.jsx)($e,{messages:e,capabilities:We,enableFileUpload:!0,maxFileSize:10,allowedFileTypes:["*"],businessUnits:[],sessions:[],notifications:[],onNewChat:()=>t([]),onSessionSelect:()=>{},onSessionDelete:()=>{},showCapabilities:!0})})}function hi(){let[e,t]=(0,Ke.useState)([{id:"1",role:"user",parts:[{type:"text",text:"Can you show me some interactive dashboard components?"}]},{id:"2",role:"assistant",parts:[{type:"text",text:"I'll create some interactive dashboard components for you. Here are various UI elements:"},{type:"data-dashboard",data:{title:"Sales Dashboard",widgets:[{type:"metric",title:"Total Revenue",value:"$125,000",change:"+12.5%",trend:"up"},{type:"metric",title:"New Customers",value:"47",change:"+8.3%",trend:"up"},{type:"metric",title:"Conversion Rate",value:"3.2%",change:"-2.1%",trend:"down"}]}}]},{id:"3",role:"user",parts:[{type:"text",text:"Can you show me a data table with customer information?"}]},{id:"4",role:"assistant",parts:[{type:"text",text:"Here's a customer data table with sorting and filtering capabilities:"},{type:"data-table",data:{title:"Customer Information",columns:[{key:"name",label:"Customer Name",sortable:!0},{key:"company",label:"Company",sortable:!0},{key:"revenue",label:"Revenue",sortable:!0,type:"currency"},{key:"status",label:"Status",type:"badge"},{key:"lastContact",label:"Last Contact",type:"date"}],rows:[{id:"1",name:"Alice Johnson",company:"Acme Corp",revenue:85e3,status:"active",lastContact:"2024-01-15"},{id:"2",name:"Bob Smith",company:"Beta Inc",revenue:45e3,status:"pending",lastContact:"2024-01-12"},{id:"3",name:"Carol Davis",company:"Gamma LLC",revenue:15e3,status:"inactive",lastContact:"2024-01-08"},{id:"4",name:"David Wilson",company:"Delta Systems",revenue:125e3,status:"active",lastContact:"2024-01-18"}]}}]},{id:"5",role:"user",parts:[{type:"text",text:"Show me a progress tracker for a project"}]},{id:"6",role:"assistant",parts:[{type:"text",text:"Here's a project progress tracker with timeline and milestones:"},{type:"data-progress",data:{title:"Website Redesign Project",overall_progress:65,phases:[{name:"Discovery & Planning",status:"completed",progress:100,start_date:"2024-01-01",end_date:"2024-01-15",tasks:[{name:"Stakeholder interviews",completed:!0},{name:"Requirements gathering",completed:!0},{name:"Project timeline",completed:!0}]},{name:"Design & Prototyping",status:"completed",progress:100,start_date:"2024-01-16",end_date:"2024-02-15",tasks:[{name:"Wireframes",completed:!0},{name:"Visual design",completed:!0},{name:"Interactive prototype",completed:!0}]},{name:"Development",status:"in_progress",progress:75,start_date:"2024-02-16",end_date:"2024-03-30",tasks:[{name:"Frontend development",completed:!0},{name:"Backend integration",completed:!1},{name:"Testing & QA",completed:!1}]},{name:"Launch & Deployment",status:"pending",progress:0,start_date:"2024-03-31",end_date:"2024-04-15",tasks:[{name:"Production deployment",completed:!1},{name:"User training",completed:!1},{name:"Go-live support",completed:!1}]}]}}]}]);return(0,ca.jsx)("div",{className:"ca-screen w-full",children:(0,ca.jsx)($e,{messages:e,capabilities:We,enableFileUpload:!0,maxFileSize:10,allowedFileTypes:["*"],businessUnits:[],sessions:[],notifications:[],onNewChat:()=>t([]),onSessionSelect:()=>{},onSessionDelete:()=>{},showCapabilities:!0})})}function bi(){let[e,t]=(0,Ke.useState)([{id:"1",role:"user",parts:[{type:"text",text:"I want to upload some files for analysis. I have a sales_data.csv file and a quarterly_report.pdf that I need to analyze."}]},{id:"2",role:"assistant",parts:[{type:"text",text:`Perfect! I can help you analyze various file types. You can upload:
328
+
329
+ \u{1F4CA} **Data Files:**
330
+ - CSV/Excel spreadsheets
331
+ - JSON data files
332
+ - Database exports
333
+
334
+ \u{1F4C4} **Documents:**
335
+ - PDF reports
336
+ - Word documents
337
+ - Text files
338
+
339
+ \u{1F5BC}\uFE0F **Media Files:**
340
+ - Images (PNG, JPG, GIF)
341
+ - Charts and diagrams
342
+
343
+ **File Upload Features:**
344
+ - \u2705 Drag & drop support
345
+ - \u2705 Multiple file selection
346
+ - \u2705 Progress indicators
347
+ - \u2705 File type validation
348
+ - \u2705 Size limit checking (max 10MB)
349
+
350
+ Try uploading your files using the attachment button below! I'll analyze them once uploaded.`}]},{id:"3",role:"user",parts:[{type:"text",text:"I just uploaded sales_data.csv (15.4 KB) and quarterly_report.pdf (2.6 MB)"}]},{id:"4",role:"assistant",parts:[{type:"text",text:`Great! I can see you've uploaded two files:
351
+
352
+ ## \u{1F4C1} Uploaded Files
353
+
354
+ ### 1. \u{1F4CA} sales_data.csv (15.4 KB)
355
+ - **Type:** CSV Spreadsheet
356
+ - **Status:** \u2705 Successfully uploaded
357
+ - **Preview:** Contains sales transaction data
358
+ - **Columns:** Date, Customer, Product, Revenue, Region
359
+
360
+ ### 2. \u{1F4C4} quarterly_report.pdf (2.6 MB)
361
+ - **Type:** PDF Document
362
+ - **Status:** \u2705 Successfully uploaded
363
+ - **Pages:** 24 pages
364
+ - **Content:** Q4 2023 Business Report
365
+
366
+ *\u{1F527} Analyzing CSV file: sales_data.csv*
367
+
368
+ ## \u{1F50D} Analysis Results
369
+
370
+ **CSV Data Summary:**
371
+ - **Total Records:** 1,247 sales transactions
372
+ - **Date Range:** January 1, 2023 - December 31, 2023
373
+ - **Total Revenue:** $1,250,000
374
+ - **Average Deal Size:** $1,002.40
375
+
376
+ *\u{1F527} Extracting PDF content: quarterly_report.pdf*
377
+
378
+ **PDF Report Highlights:**
379
+ - **Q4 Revenue:** $485,000 (from report)
380
+ - **Annual Growth:** 15.2%
381
+ - **Top Region:** North America
382
+ - **Key Sections:** Executive Summary, Financial Performance, Sales Analysis
383
+
384
+ ## \u{1F50D} Data Comparison
385
+ - **Variance Found:** $70,000 difference between CSV total ($1,250,000) and PDF annual total ($1,180,000)
386
+ - **Recommendation:** Investigate timing differences or adjustments
387
+
388
+ Would you like me to:
389
+ - \u{1F4CA} Create detailed visualizations
390
+ - \u{1F50D} Investigate the revenue variance
391
+ - \u{1F4C8} Generate trend analysis
392
+ - \u{1F4CB} Create a unified report?`}]}]);return(0,ca.jsx)("div",{className:"ca-screen w-full",children:(0,ca.jsx)($e,{messages:e,capabilities:We,enableFileUpload:!0,maxFileSize:10,allowedFileTypes:["*"],businessUnits:[],sessions:[],notifications:[],onNewChat:()=>t([]),onSessionSelect:()=>{},onSessionDelete:()=>{},showCapabilities:!0})})}function vi(){let[e,t]=(0,Ke.useState)([{id:"1",role:"user",parts:[{type:"text",text:"Can you fetch my latest sales data?"}]},{id:"2",role:"assistant",parts:[{type:"text",text:`I'll fetch your latest sales data right away.
393
+
394
+ *\u{1F527} Calling function: fetch_sales_data(period="latest")*
395
+
396
+ \u26A0\uFE0F **Database Connection Timeout**
397
+
398
+ \`\`\`
399
+ Error: Database connection timeout
400
+ Code: DB_TIMEOUT
401
+ Retry after: 30 seconds
402
+ Timestamp: 2024-01-20T10:15:23Z
403
+ \`\`\`
404
+
405
+ This is usually a temporary issue. I'll retry the request in 30 seconds. In the meantime, you can:
406
+
407
+ 1. Check if there are any ongoing system maintenance notifications
408
+ 2. Try refreshing the page
409
+ 3. Contact support if the issue persists
410
+
411
+ Would you like me to try again now or wait for the suggested retry time?`}]},{id:"3",role:"user",parts:[{type:"text",text:"Please try again now"}]},{id:"4",role:"assistant",parts:[{type:"text",text:`Retrying the sales data fetch...
412
+
413
+ *\u{1F527} Calling function: fetch_sales_data(period="latest", retry=true)*
414
+
415
+ \u{1F6AB} **Access Denied**
416
+
417
+ \`\`\`
418
+ Error: Insufficient permissions
419
+ Code: AUTH_ERROR
420
+ Required permissions: ['sales:read', 'data:access']
421
+ Contact admin: true
422
+ \`\`\`
423
+
424
+ I'm unable to fetch the sales data due to insufficient permissions.
425
+
426
+ **Required Permissions:**
427
+ - \`sales:read\` - Read access to sales data
428
+ - \`data:access\` - General data access rights
429
+
430
+ **Next Steps:**
431
+ 1. **Contact your administrator** to request the necessary permissions
432
+ 2. **Verify your role** - You may need a sales or data analyst role
433
+ 3. **Check group memberships** - Ensure you're in the appropriate security groups
434
+
435
+ **Alternative Options:**
436
+ - Upload a sales data file directly (CSV, Excel)
437
+ - Request data from a colleague with appropriate access
438
+ - Use the capabilities menu to explore other available features
439
+
440
+ Would you like to try uploading a file instead, or explore other features I can help you with?`}]},{id:"5",role:"user",parts:[{type:"text",text:"What about creating a report with invalid data?"}]},{id:"6",role:"assistant",parts:[{type:"text",text:`I'll attempt to create a report with the data available.
441
+
442
+ *\u{1F527} Calling function: generate_report(data_source="invalid_source", report_type="sales_summary")*
443
+
444
+ \u274C **Invalid Data Source**
445
+
446
+ \`\`\`
447
+ Error: Invalid data source specified
448
+ Code: INVALID_SOURCE
449
+ Valid sources: ['sales_db', 'crm_system', 'uploaded_files']
450
+ Suggestion: Please specify a valid data source
451
+ \`\`\`
452
+
453
+ The report generation failed because the specified data source is not valid.
454
+
455
+ **Available Data Sources:**
456
+ - \`sales_db\` - Main sales database
457
+ - \`crm_system\` - Customer relationship management system
458
+ - \`uploaded_files\` - Files you've uploaded to the chat
459
+
460
+ **How to Fix This:**
461
+ 1. **Choose a valid source** from the list above
462
+ 2. **Upload data files** if you want to use your own data
463
+ 3. **Check data permissions** for database sources
464
+
465
+ **Example:** "Generate a sales report using the CRM system data"
466
+
467
+ Would you like me to try generating a report with one of the valid data sources?`}]},{id:"7",role:"user",parts:[{type:"text",text:"Let me try uploading some corrupted data (corrupted_data.xlsx - 0 bytes)"}]},{id:"8",role:"assistant",parts:[{type:"text",text:`I see you're trying to upload a file. Let me analyze it.
468
+
469
+ *\u{1F527} Processing file: corrupted_data.xlsx*
470
+
471
+ \u{1F4BE} **Corrupted or Empty File**
472
+
473
+ \`\`\`
474
+ Error: File appears to ca corrupted or empty
475
+ Code: CORRUPTED_FILE
476
+ File size: 0 bytes
477
+ MIME type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
478
+ \`\`\`
479
+
480
+ The uploaded Excel file appears to ca corrupted or empty (0 bytes).
481
+
482
+ **Possible Causes:**
483
+ - File upload was interrupted
484
+ - Original file is corrupted
485
+ - File format is not supported
486
+ - Network issues during upload
487
+
488
+ **Troubleshooting Steps:**
489
+
490
+ 1. **Re-save the file:**
491
+ - Open in Excel and save as a new file
492
+ - Try "Save As" \u2192 Excel Workbook (.xlsx)
493
+
494
+ 2. **Try different format:**
495
+ - Export as CSV (.csv) for better compatibility
496
+ - Save as Excel 97-2003 (.xls) if needed
497
+
498
+ 3. **Check file integrity:**
499
+ - Verify you can open the file locally
500
+ - Check file size (should ca > 0 bytes)
501
+
502
+ 4. **Re-upload:**
503
+ - Clear browser cache
504
+ - Try uploading again
505
+
506
+ **Alternative Solutions:**
507
+ - Copy data into a new spreadsheet
508
+ - Use Google Sheets and export as Excel
509
+ - Upload as a text/CSV file instead
510
+
511
+ Would you like to try uploading the file again or in a different format?`}]},{id:"9",role:"user",parts:[{type:"text",text:"What about network connectivity issues?"}]},{id:"10",role:"assistant",parts:[{type:"text",text:`Let me check the network connectivity and system status.
512
+
513
+ *\u{1F527} Calling function: check_system_status()*
514
+
515
+ \u{1F310} **Network Connectivity Issues**
516
+
517
+ \`\`\`
518
+ Error: Unable to reach external services
519
+ Code: NETWORK_ERROR
520
+ Status: Multiple service endpoints unreachable
521
+ Last successful connection: 5 minutes ago
522
+ \`\`\`
523
+
524
+ It appears there are network connectivity issues affecting several services:
525
+
526
+ **Affected Services:**
527
+ - \u274C Customer Database (timeout)
528
+ - \u274C File Processing Service (unreachable)
529
+ - \u274C Analytics Engine (connection refused)
530
+ - \u2705 Chat Service (operational)
531
+ - \u2705 Authentication (operational)
532
+
533
+ **Impact:**
534
+ - File uploads may fail or ca delayed
535
+ - Data retrieval functions unavailable
536
+ - Real-time analytics temporarily disabled
537
+ - Chat functionality remains available
538
+
539
+ **Troubleshooting:**
540
+ 1. **Check your internet connection**
541
+ 2. **Try refreshing the page**
542
+ 3. **Wait 2-3 minutes and retry**
543
+ 4. **Contact IT if issues persist**
544
+
545
+ **What you can still do:**
546
+ - Continue chatting for general assistance
547
+ - Review previously uploaded data
548
+ - Access cached reports and documents
549
+ - Plan future actions for when services restore
550
+
551
+ I'll continue monitoring the connection status. Services typically restore within 5-10 minutes during maintenance windows.`}]}]);return(0,ca.jsx)("div",{className:"ca-screen w-full",children:(0,ca.jsx)($e,{messages:e,capabilities:We,enableFileUpload:!0,maxFileSize:10,allowedFileTypes:["*"],businessUnits:[],sessions:[],notifications:[],onNewChat:()=>t([]),onSessionSelect:()=>{},onSessionDelete:()=>{},showCapabilities:!0})})}function yi(){let[e,t]=(0,Ke.useState)([{id:"1",role:"assistant",parts:[{type:"text",text:`Welcome! I can help you with various business tasks. Use the capabilities menu at the bottom to explore what I can do, or ask me directly about:
552
+
553
+ \u{1F3E2} **Sales & CRM**
554
+ - Customer management
555
+ - Sales pipeline tracking
556
+ - Revenue analysis
557
+
558
+ \u{1F4CA} **Marketing**
559
+ - Campaign management
560
+ - Analytics and reporting
561
+ - Lead generation
562
+
563
+ \u{1F465} **HR & Operations**
564
+ - Employee management
565
+ - Project tracking
566
+ - Document processing
567
+
568
+ \u{1F4B0} **Finance**
569
+ - Financial reporting
570
+ - Budget analysis
571
+ - Expense tracking
572
+
573
+ Try clicking on any capability in the menu below to get started!`}]},{id:"2",role:"user",parts:[{type:"text",text:"I clicked on Sales \u2192 Customers \u2192 Acme Corp"}]},{id:"3",role:"assistant",parts:[{type:"text",text:"Great! You've selected **Acme Corp** from the customers list. Here's what I found:"},{type:"data-customer-card",data:{id:"acme-corp",name:"Acme Corp",type:"Enterprise Customer",revenue:"$125,000 ARR",industry:"Technology",employees:500,lastContact:"2024-01-15",status:"active",contacts:[{name:"John Smith",role:"CTO",email:"john@acme.com"},{name:"Sarah Johnson",role:"Procurement",email:"sarah@acme.com"}],recent_activity:[{date:"2024-01-15",activity:"Contract renewal discussion"},{date:"2024-01-10",activity:"Product demo scheduled"},{date:"2024-01-05",activity:"Support ticket resolved"}],opportunities:[{name:"Enterprise License Renewal",value:"$150K",stage:"Negotiation"},{name:"Additional Modules",value:"$25K",stage:"Proposal"}]}}]},{id:"4",role:"assistant",parts:[{type:"text",text:`**Available Actions for Acme Corp:**
574
+
575
+ \u{1F3AF} **Sales Actions**
576
+ - Schedule follow-up meeting
577
+ - Update opportunity status
578
+ - Send contract renewal proposal
579
+
580
+ \u{1F4DE} **Communication**
581
+ - Log customer call
582
+ - Send email update
583
+ - Schedule product demo
584
+
585
+ \u{1F4CA} **Analytics**
586
+ - View customer health score
587
+ - Generate account report
588
+ - Analyze usage patterns
589
+
590
+ What would you like to do next?`}]},{id:"5",role:"user",parts:[{type:"text",text:"Now I want to explore Marketing \u2192 Campaign Management"}]},{id:"6",role:"assistant",parts:[{type:"text",text:"Perfect! You've navigated to **Campaign Management**. Here's an overview of your marketing campaigns:"},{type:"data-campaigns",data:{title:"Active Marketing Campaigns",campaigns:[{id:"winter-promo",name:"Winter Promotion 2024",status:"active",type:"Email + Social",start_date:"2024-01-01",end_date:"2024-02-29",budget:15e3,spent:8500,leads:247,conversions:23,roi:"180%"},{id:"product-launch",name:"New Product Launch",status:"planning",type:"Multi-channel",start_date:"2024-02-15",end_date:"2024-04-15",budget:25e3,spent:0,leads:0,conversions:0,roi:"TBD"},{id:"retargeting",name:"Retargeting Campaign",status:"active",type:"Digital Ads",start_date:"2024-01-10",end_date:"2024-03-10",budget:8e3,spent:3200,leads:89,conversions:12,roi:"150%"}]}}]},{id:"7",role:"assistant",parts:[{type:"text",text:`**Campaign Management Actions:**
591
+
592
+ \u{1F4DD} **Create & Edit**
593
+ - Create new campaign
594
+ - Duplicate existing campaign
595
+ - Edit campaign settings
596
+
597
+ \u{1F4CA} **Analytics & Reporting**
598
+ - View detailed performance
599
+ - Generate ROI report
600
+ - Compare campaign metrics
601
+
602
+ \u2699\uFE0F **Management**
603
+ - Pause/resume campaigns
604
+ - Adjust budgets
605
+ - Update target audiences
606
+
607
+ \u{1F3AF} **Optimization**
608
+ - A/Za test variations
609
+ - Optimize targeting
610
+ - Adjust bidding strategies
611
+
612
+ Which campaign would you like to work with, or what action would you like to take?`}]},{id:"8",role:"user",parts:[{type:"text",text:"Let me check HR \u2192 Employee Management \u2192 Performance Reviews"}]},{id:"9",role:"assistant",parts:[{type:"text",text:"You've accessed **Performance Reviews** in HR. Here's the current status of performance reviews:"},{type:"data-performance",data:{title:"Performance Review Dashboard",period:"Q4 2023",overview:{total_employees:127,reviews_completed:89,reviews_pending:23,reviews_overdue:15,completion_rate:70.1},departments:[{name:"Engineering",employees:45,completed:38,pending:5,overdue:2,avg_rating:4.2},{name:"Sales",employees:28,completed:22,pending:4,overdue:2,avg_rating:3.9},{name:"Marketing",employees:18,completed:12,pending:3,overdue:3,avg_rating:4},{name:"Operations",employees:15,completed:9,pending:4,overdue:2,avg_rating:3.8}],upcoming_deadlines:[{employee:"Alex Chen",department:"Engineering",due_date:"2024-01-25"},{employee:"Maria Garcia",department:"Sales",due_date:"2024-01-27"},{employee:"David Kim",department:"Marketing",due_date:"2024-01-30"}]}}]},{id:"10",role:"assistant",parts:[{type:"text",text:`**Performance Review Actions:**
613
+
614
+ \u2705 **Review Management**
615
+ - Schedule new reviews
616
+ - Send completion reminders
617
+ - Mark reviews as complete
618
+
619
+ \u{1F4CB} **Templates & Forms**
620
+ - Create review templates
621
+ - Customize evaluation forms
622
+ - Set review criteria
623
+
624
+ \u{1F4CA} **Analytics & Reports**
625
+ - Generate department reports
626
+ - Track completion rates
627
+ - Analyze performance trends
628
+
629
+ \u{1F514} **Notifications**
630
+ - Send deadline reminders
631
+ - Notify managers of overdue reviews
632
+ - Schedule follow-up meetings
633
+
634
+ **Attention Required:**
635
+ - 15 reviews are **overdue**
636
+ - 23 reviews are **pending**
637
+ - 3 employees have upcoming deadlines this week
638
+
639
+ Would you like me to send reminder notifications or help with any specific review tasks?`}]}]);return(0,ca.jsx)("div",{className:"ca-screen w-full",children:(0,ca.jsx)($e,{messages:e,capabilities:We,enableFileUpload:!0,maxFileSize:10,allowedFileTypes:["*"],businessUnits:[],sessions:[],notifications:[],onNewChat:()=>t([]),onSessionSelect:()=>{},onSessionDelete:()=>{},showCapabilities:!0})})}0&&(module.exports={ChatDemoCapabilitiesInteraction,ChatDemoErrorHandling,ChatDemoFileUploads,ChatDemoMarkdownResponses,ChatDemoToolCalling,ChatDemoUIComponents});