cortex-react-components 2.16.2 → 2.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-WIRQ5IRT.mjs → chunk-2GM2LPLB.mjs} +1 -1
- package/dist/{chunk-3HNU2NYP.mjs → chunk-2OOJ4ZFB.mjs} +1 -1
- package/dist/{chunk-7R47MHQE.mjs → chunk-4SRUEQTP.mjs} +1 -1
- package/dist/chunk-5HT2KC5I.mjs +4 -0
- package/dist/chunk-66MLFLL2.mjs +1 -0
- package/dist/chunk-6QERRKM4.mjs +1 -0
- package/dist/{chunk-CXOVEABI.mjs → chunk-7OMPPFGG.mjs} +1 -1
- package/dist/chunk-B44DI6WT.mjs +4 -0
- package/dist/{chunk-MFCVMJBO.mjs → chunk-BDDEMCAH.mjs} +1 -1
- package/dist/{chunk-75F3LJMX.mjs → chunk-BQQ4V4PX.mjs} +1 -1
- package/dist/{chunk-DKRRVTCV.mjs → chunk-CJDUN6R4.mjs} +1 -1
- package/dist/chunk-D2ARSS5J.mjs +4 -0
- package/dist/{chunk-GHOL5L32.mjs → chunk-F64CA5CH.mjs} +1 -1
- package/dist/{chunk-3Y7QG6VP.mjs → chunk-FEWOSBUJ.mjs} +1 -1
- package/dist/{chunk-2BRDNDUB.mjs → chunk-FYQBRCQM.mjs} +1 -1
- package/dist/{chunk-RJGYVDOU.mjs → chunk-GAZHKHGB.mjs} +1 -1
- package/dist/{chunk-RGOKBIQ5.mjs → chunk-GETYSIZV.mjs} +1 -1
- package/dist/chunk-GTHKYSK2.mjs +1 -0
- package/dist/chunk-H3RVI2OI.mjs +4 -0
- package/dist/{chunk-3NRXQBBS.mjs → chunk-HDKHF3EA.mjs} +1 -1
- package/dist/chunk-HFEN3KJC.mjs +1 -0
- package/dist/{chunk-C4RWEPVF.mjs → chunk-HKMNAXLM.mjs} +1 -1
- package/dist/chunk-HN22CVSV.mjs +1 -0
- package/dist/chunk-IPRG56MW.mjs +1 -0
- package/dist/{chunk-DMCFEJ2C.mjs → chunk-JCWFPKF3.mjs} +1 -1
- package/dist/{chunk-LJXTXROJ.mjs → chunk-KZAYLEFB.mjs} +1 -1
- package/dist/chunk-L2UJOICL.mjs +1 -0
- package/dist/{chunk-WUA65ZZB.mjs → chunk-L3BLBPSR.mjs} +1 -1
- package/dist/{chunk-CLGBBNRB.mjs → chunk-LAQ3QAUW.mjs} +1 -1
- package/dist/{chunk-AMVJPDM3.mjs → chunk-M527EJIX.mjs} +1 -1
- package/dist/{chunk-5MWZTJYP.mjs → chunk-MO4HRQEL.mjs} +1 -1
- package/dist/{chunk-TVTTUSWM.mjs → chunk-OQCMTGML.mjs} +1 -1
- package/dist/{chunk-GTZJWMZR.mjs → chunk-P6OSMPUQ.mjs} +1 -1
- package/dist/{chunk-3LRDESQ6.mjs → chunk-PEMW5ADK.mjs} +1 -1
- package/dist/{chunk-FE7ZGUPU.mjs → chunk-PNUBVBSR.mjs} +1 -1
- package/dist/{chunk-AJQHGVZ5.mjs → chunk-PTZT4QJW.mjs} +1 -1
- package/dist/{chunk-4AC6KKXQ.mjs → chunk-Q6PN3Y7R.mjs} +1 -1
- package/dist/{chunk-RK3L6MAM.mjs → chunk-QQFIVSBW.mjs} +1 -1
- package/dist/{chunk-EM3T2XYC.mjs → chunk-R6AYIVIR.mjs} +1 -1
- package/dist/{chunk-P55W6AFU.mjs → chunk-RIRZRO6U.mjs} +1 -1
- package/dist/{chunk-2HWSTGAP.mjs → chunk-RS4VD3ML.mjs} +1 -1
- package/dist/{chunk-TXVA6XJT.mjs → chunk-SRUG246N.mjs} +1 -1
- package/dist/chunk-T3F3RQIC.mjs +1 -0
- package/dist/{chunk-RSDUFAIB.mjs → chunk-T5HJS6OF.mjs} +1 -1
- package/dist/chunk-TH6RC62B.mjs +4 -0
- package/dist/chunk-U2OXF7PJ.mjs +1 -0
- package/dist/{chunk-NINFDOV5.mjs → chunk-U3FYDDE2.mjs} +1 -1
- package/dist/chunk-UP67R64J.mjs +1 -0
- package/dist/{chunk-X3JZSN3W.mjs → chunk-UZSBX5GO.mjs} +1 -1
- package/dist/{chunk-XGIYNUGC.mjs → chunk-VNYUNZ3M.mjs} +1 -1
- package/dist/{chunk-2BR55L74.mjs → chunk-VRE6VCHX.mjs} +1 -1
- package/dist/chunk-VSU7LYXZ.mjs +1 -0
- package/dist/chunk-XC3Y62VP.mjs +4 -0
- package/dist/chunk-XXL6LGBB.mjs +4 -0
- package/dist/{chunk-6MSM3CZ6.mjs → chunk-ZG5N4C4S.mjs} +1 -1
- package/dist/components/Blocks/Banner.mjs +1 -1
- package/dist/components/Blocks/CallToAction.mjs +1 -1
- package/dist/components/Blocks/CollapsibleArea.mjs +1 -1
- package/dist/components/Blocks/Content.mjs +1 -1
- package/dist/components/Blocks/FeaturesBlock.mjs +1 -1
- package/dist/components/Blocks/ImageBlock.mjs +1 -1
- package/dist/components/Blocks/MediaBlock.mjs +1 -1
- package/dist/components/Blocks/RelatedPosts.mjs +1 -1
- package/dist/components/Blocks/RenderBlocks.mjs +1 -1
- package/dist/components/Blocks/ReusableContentBlock.mjs +1 -1
- package/dist/components/Blocks/index.mjs +1 -1
- package/dist/components/CRM/CogeBoard.mjs +1 -1
- package/dist/components/CRM/KanbanBoard.mjs +1 -1
- package/dist/components/CRM/index.mjs +1 -1
- package/dist/components/Cards/ContentCard.mjs +1 -1
- package/dist/components/Cards/FeatureCard.mjs +1 -1
- package/dist/components/Cards/index.mjs +1 -1
- package/dist/components/DigitalColleagues/MainPage.mjs +1 -1
- package/dist/components/DigitalColleagues/Views/ColleaguesView.mjs +1 -1
- package/dist/components/DigitalColleagues/Views/index.mjs +1 -1
- package/dist/components/DigitalColleagues/index.mjs +1 -1
- package/dist/components/Foundary/Knowledge/add-knowledge-modal.css +1 -0
- package/dist/components/Foundary/Knowledge/add-knowledge-modal.d.ts +11 -0
- package/dist/components/Foundary/Knowledge/add-knowledge-modal.js +4 -0
- package/dist/components/Foundary/Knowledge/add-knowledge-modal.mjs +1 -0
- package/dist/components/Foundary/Knowledge/add-team-context.css +1 -0
- package/dist/components/Foundary/Knowledge/add-team-context.d.ts +9 -0
- package/dist/components/Foundary/Knowledge/add-team-context.js +4 -0
- package/dist/components/Foundary/Knowledge/add-team-context.mjs +1 -0
- package/dist/components/Foundary/MainPage.mjs +1 -1
- package/dist/components/Foundary/Pages/dashboardpage.js +1 -1
- package/dist/components/Foundary/Pages/dashboardpage.mjs +1 -1
- package/dist/components/Foundary/RichText/Icons/Bold.d.ts +2 -0
- package/dist/components/Foundary/RichText/Icons/Bold.js +1 -0
- package/dist/components/Foundary/RichText/Icons/Bold.mjs +1 -0
- package/dist/components/Foundary/RichText/Icons/Headings.d.ts +7 -0
- package/dist/components/Foundary/RichText/Icons/Headings.js +1 -0
- package/dist/components/Foundary/RichText/Icons/Headings.mjs +1 -0
- package/dist/components/Foundary/RichText/Icons/Italic.d.ts +2 -0
- package/dist/components/Foundary/RichText/Icons/Italic.js +1 -0
- package/dist/components/Foundary/RichText/Icons/Italic.mjs +1 -0
- package/dist/components/Foundary/RichText/Icons/StrikeThrough.d.ts +2 -0
- package/dist/components/Foundary/RichText/Icons/StrikeThrough.js +1 -0
- package/dist/components/Foundary/RichText/Icons/StrikeThrough.mjs +1 -0
- package/dist/components/Foundary/RichText/Icons/Subscript.d.ts +2 -0
- package/dist/components/Foundary/RichText/Icons/Subscript.js +1 -0
- package/dist/components/Foundary/RichText/Icons/Subscript.mjs +1 -0
- package/dist/components/Foundary/RichText/Icons/Superscript.d.ts +2 -0
- package/dist/components/Foundary/RichText/Icons/Superscript.js +1 -0
- package/dist/components/Foundary/RichText/Icons/Superscript.mjs +1 -0
- package/dist/components/Foundary/RichText/Icons/Underline.d.ts +2 -0
- package/dist/components/Foundary/RichText/Icons/Underline.js +1 -0
- package/dist/components/Foundary/RichText/Icons/Underline.mjs +1 -0
- package/dist/components/Foundary/RichText/index.css +1 -0
- package/dist/components/Foundary/RichText/index.d.ts +9 -0
- package/dist/components/Foundary/RichText/index.js +4 -0
- package/dist/components/Foundary/RichText/index.mjs +2 -0
- package/dist/components/Foundary/RichText/plugins/toolbar-plugin.css +1 -0
- package/dist/components/Foundary/RichText/plugins/toolbar-plugin.d.ts +1 -0
- package/dist/components/Foundary/RichText/plugins/toolbar-plugin.js +4 -0
- package/dist/components/Foundary/RichText/plugins/toolbar-plugin.mjs +1 -0
- package/dist/components/Foundary/Views/ColleaguesView.d.ts +3 -2
- package/dist/components/Foundary/Views/ColleaguesView.js +1 -1
- package/dist/components/Foundary/Views/ColleaguesView.mjs +1 -1
- package/dist/components/Foundary/Views/KnowledgeView.d.ts +5 -2
- package/dist/components/Foundary/Views/KnowledgeView.js +1 -1
- package/dist/components/Foundary/Views/KnowledgeView.mjs +1 -1
- package/dist/components/Foundary/Views/index.js +1 -1
- package/dist/components/Foundary/Views/index.mjs +1 -1
- package/dist/components/Foundary/colleague-form.d.ts +2 -2
- package/dist/components/Foundary/colleague-form.js +1 -1
- package/dist/components/Foundary/colleague-form.mjs +1 -1
- package/dist/components/Foundary/document-edit.d.ts +3 -2
- package/dist/components/Foundary/document-edit.js +1 -2
- package/dist/components/Foundary/document-edit.mjs +1 -1
- package/dist/components/Foundary/document-preview-examples.js +6 -7
- package/dist/components/Foundary/document-preview-examples.mjs +3 -3
- package/dist/components/Foundary/document-preview.d.ts +5 -4
- package/dist/components/Foundary/document-preview.js +1 -2
- package/dist/components/Foundary/document-preview.mjs +1 -1
- package/dist/components/Foundary/index.js +1 -1
- package/dist/components/Foundary/index.mjs +1 -1
- package/dist/components/Foundary/knowledge-browser.d.ts +2 -2
- package/dist/components/Foundary/knowledge-browser.js +1 -2
- package/dist/components/Foundary/knowledge-browser.mjs +1 -1
- package/dist/components/Foundary/knowledge-search.d.ts +1 -1
- package/dist/components/Foundary/knowledge-search.js +1 -2
- package/dist/components/Foundary/knowledge-search.mjs +1 -1
- package/dist/components/Foundary/types.d.ts +59 -1
- package/dist/components/Foundary/types.js +1 -1
- package/dist/components/HeaderFooter/Header.mjs +1 -1
- package/dist/components/HeaderFooter/HeaderDesktop.mjs +1 -1
- package/dist/components/HeaderFooter/SectionHeading.mjs +1 -1
- package/dist/components/HeaderFooter/index.mjs +1 -1
- package/dist/components/Heros/HighImpact/index.mjs +1 -1
- package/dist/components/Heros/LowImpact/index.mjs +1 -1
- package/dist/components/Heros/MediumImpact/index.mjs +1 -1
- package/dist/components/Heros/RenderHero.mjs +1 -1
- package/dist/components/Heros/index.mjs +1 -1
- package/dist/components/Layouts/OutputHeaderFooter.mjs +1 -1
- package/dist/components/Layouts/Print.mjs +1 -1
- package/dist/components/Layouts/SlideShow.mjs +1 -1
- package/dist/components/Layouts/index.mjs +1 -1
- package/dist/components/Payload/CollectionArchive/index.mjs +1 -1
- package/dist/components/Payload/Media/index.mjs +1 -1
- package/dist/components/Payload/PayloadCard/index.mjs +1 -1
- package/dist/components/Payload/RichText/index.mjs +1 -1
- package/dist/components/Payload/RichText/serialize.mjs +1 -1
- package/dist/components/Payload/index.mjs +1 -1
- package/dist/components/dc-temp/index.mjs +1 -1
- package/dist/components/index.js +16 -16
- package/dist/components/index.mjs +1 -1
- package/dist/globals.css +1 -1
- package/dist/index.js +25 -25
- package/dist/index.mjs +1 -1
- package/dist/metafile-cjs.json +1 -1
- package/dist/metafile-esm.json +1 -1
- package/dist/pages/Blog.mjs +1 -1
- package/dist/pages/Documentation.mjs +1 -1
- package/dist/pages/IndexPage.mjs +1 -1
- package/dist/pages/Intranet.mjs +1 -1
- package/dist/pages/LandingPage.mjs +1 -1
- package/dist/pages/Page.mjs +1 -1
- package/dist/pages/Publish.mjs +1 -1
- package/dist/pages/Website.mjs +1 -1
- package/dist/sections/AboutSection.mjs +1 -1
- package/dist/sections/BlogDetail.mjs +1 -1
- package/dist/sections/BlogList.mjs +1 -1
- package/dist/sections/ContactSection.mjs +1 -1
- package/dist/sections/PageSections.mjs +1 -1
- package/dist/sections/PricingSection.mjs +1 -1
- package/dist/sections/ServiceDetail.mjs +1 -1
- package/dist/sections/ServiceDetailSection.mjs +1 -1
- package/dist/sections/ServiceSection.mjs +1 -1
- package/dist/sections/form/index.mjs +1 -1
- package/dist/sections/index.mjs +1 -1
- package/package.json +5 -2
- package/dist/chunk-5ROLUQ45.mjs +0 -4
- package/dist/chunk-DYIBFAK7.mjs +0 -4
- package/dist/chunk-ISQS7QYK.mjs +0 -4
- package/dist/chunk-K5MJYNCD.mjs +0 -4
- package/dist/chunk-KO6JUP2L.mjs +0 -4
- package/dist/chunk-MDBYZZXI.mjs +0 -1
- package/dist/chunk-MFE4VZPC.mjs +0 -4
package/dist/chunk-DYIBFAK7.mjs
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";
|
|
3
|
-
|
|
4
|
-
import{a as K}from"./chunk-TVZOULLL.mjs";import{a as y}from"./chunk-FT3AE7L2.mjs";import{a as k}from"./chunk-L5JPAKPM.mjs";import{b as p}from"./chunk-ZUA4KNIR.mjs";import{b as u}from"./chunk-CSBGSBEU.mjs";import{a as d,e as v}from"./chunk-YO3GQYRJ.mjs";import{useState as h,useEffect as A}from"react";import{Search as D,X as F,FileText as L,Tag as I}from"lucide-react";import{jsx as t,jsxs as s}from"react/jsx-runtime";function H({selectedDocuments:l,onDocumentsChange:N,availableDocuments:x,label:S,placeholder:B="Search knowledge documents...",maxSelections:r,disabled:c=!1}){let[i,w]=h(""),[f,C]=h([]),[g,n]=h(!1);A(()=>{if(!i.trim()){C([]),n(!1);return}let e=x.filter(a=>{if(l.map(m=>m.id).includes(a.id))return!1;let o=i.toLowerCase();return a.title.toLowerCase().includes(o)||a.description?.toLowerCase().includes(o)||a.tags?.some(m=>m.toLowerCase().includes(o))||Object.values(a.metadata||{}).some(m=>String(m).toLowerCase().includes(o))});C(e),n(!0)},[i,l,x]);let z=e=>{r&&l.length>=r||(N([...l,e]),w(""),n(!1))},T=e=>{N(l.filter(a=>a.id!==e))},b=!r||l.length<r;return s("div",{className:"space-y-2",children:[t(K,{children:S}),s("div",{className:"relative",children:[s("div",{className:"relative",children:[t(D,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),t(k,{value:i,onChange:e=>w(e.target.value),placeholder:b?B:`Maximum ${r} documents selected`,className:"pl-9",disabled:c||!b,onFocus:()=>i&&n(!0)})]}),g&&f.length>0&&t(d,{className:"absolute top-full left-0 right-0 z-10 mt-1 max-h-60",children:t(y,{className:"h-full",children:t(v,{className:"p-2",children:f.map(e=>t(p,{variant:"ghost",className:"w-full justify-start h-auto p-3 mb-1",onClick:()=>z(e),disabled:c,children:s("div",{className:"flex items-start gap-3 w-full",children:[t(L,{className:"h-4 w-4 mt-0.5 text-muted-foreground flex-shrink-0"}),s("div",{className:"text-left flex-1 min-w-0",children:[t("div",{className:"font-medium text-sm truncate",children:e.title}),e.description&&t("div",{className:"text-xs text-muted-foreground mt-1 line-clamp-2",children:e.description}),e.tags&&e.tags.length>0&&s("div",{className:"flex flex-wrap gap-1 mt-2",children:[e.tags.slice(0,3).map(a=>t(u,{variant:"outline",className:"text-xs",children:a},a)),e.tags.length>3&&s(u,{variant:"outline",className:"text-xs",children:["+",e.tags.length-3," more"]})]})]})]})},e.id))})})}),g&&i&&f.length===0&&t(d,{className:"absolute top-full left-0 right-0 z-10 mt-1",children:s(v,{className:"p-4 text-center text-sm text-muted-foreground",children:['No knowledge documents found for "',i,'"']})})]}),l.length>0&&s("div",{className:"space-y-2",children:[s("div",{className:"text-sm text-muted-foreground",children:["Selected (",l.length,r&&`/${r}`,")"]}),t("div",{className:"space-y-2",children:l.map(e=>t(d,{className:"p-3",children:s("div",{className:"flex items-start gap-3",children:[t(L,{className:"h-4 w-4 mt-0.5 text-muted-foreground flex-shrink-0"}),s("div",{className:"flex-1 min-w-0",children:[t("div",{className:"font-medium text-sm",children:e.title}),e.description&&t("div",{className:"text-xs text-muted-foreground mt-1",children:e.description}),e.tags&&e.tags.length>0&&t("div",{className:"flex flex-wrap gap-1 mt-2",children:e.tags.map(a=>s(u,{variant:"outline",className:"text-xs",children:[t(I,{className:"h-3 w-3 mr-1"}),a]},a))})]}),t(p,{type:"button",variant:"ghost",size:"icon",className:"h-6 w-6 flex-shrink-0",onClick:()=>T(e.id),disabled:c,children:t(F,{className:"h-3 w-3"})})]})},e.id))})]}),g&&t("div",{className:"fixed inset-0 z-0",onClick:()=>n(!1)})]})}export{H as a};
|
package/dist/chunk-ISQS7QYK.mjs
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";
|
|
3
|
-
|
|
4
|
-
import{a as O}from"./chunk-K5MJYNCD.mjs";import{a as X}from"./chunk-FSCDCSVK.mjs";import{a as Y}from"./chunk-NDZ26EG6.mjs";import{a as Z}from"./chunk-M2REXGQW.mjs";import{a as S}from"./chunk-ATBKMJU6.mjs";import{a as Q}from"./chunk-Z22NSJMF.mjs";import{a as _}from"./chunk-Y7H3EUBR.mjs";import{a as R}from"./chunk-FGEFYI5E.mjs";import{a as U,c as $,d as k,g as F,i as p}from"./chunk-YFAZQYK4.mjs";import{a as J}from"./chunk-L5JPAKPM.mjs";import{b as H}from"./chunk-ZUA4KNIR.mjs";import{a as c,b as h,c as x,e as u}from"./chunk-YO3GQYRJ.mjs";import{useEffect as ue,useState as o}from"react";import{Plus as pe,Search as Ce,Users as ee,Bot as fe,User as ve,Filter as ye}from"lucide-react";import{motion as he,AnimatePresence as xe}from"motion/react";import{jsx as l,jsxs as t}from"react/jsx-runtime";function Se({initialColleagues:w,onColleagueAdd:N,onColleagueEdit:I,onColleagueDelete:le,compactView:n=!1,departments:te=["Design","Engineering","Marketing","Product","Sales","Operations"],className:ae,availableUsers:L=[],existingDigitalColleagues:P=[]}){let[s,r]=o(w||[]),[d,j]=o(""),[D,B]=o("all"),[b,K]=o("all"),[v,ie]=o("all"),[M,C]=o(null),[A,y]=o(null);ue(()=>{r(w||[])},[w]);let oe=Array.isArray(L)?L:[],ne=Array.isArray(P)?P:[],[m,a]=o("main"),f=s.filter(e=>!e||!e.name?!1:e.name.toLowerCase().includes(d.toLowerCase())||e.type==="human"&&e.email?.toLowerCase().includes(d.toLowerCase())||e.type==="digital"&&e.jobDescription?.toLowerCase().includes(d.toLowerCase())),G=f.filter(e=>e.type==="human"),W=f.filter(e=>e.type==="digital"),q=()=>{a("typeSelection")},T=e=>{e.type==="digital"&&(C(e),a("form")),console.log("Editing colleague:",e),I?.(e)},E=e=>{e.type==="digital"&&(y(e),a("view"))},se=e=>{let i={id:`human-${Date.now()}`,type:"human",name:e.name,email:e.email,updatedAt:e.updatedAt,createdAt:e.createdAt,accounts:e.accounts};r(g=>[...g,i]),N?.(i),a("main")},re=e=>{if(!e||!e.id){console.error("Invalid cloned colleague provided to handleDigitalColleagueClone:",e);return}r(i=>[...i,{...e,type:"digital"}]),N?.({...e,type:"digital"}),a("main")},de=()=>{C(null),a("form")},z=e=>{if(!e||!e.id){console.error("Invalid colleague provided to handleSaveColleague:",e);return}M?(r(i=>i.map(g=>g.id===e.id?{...e,type:"digital"}:g)),I?.({...e,type:"digital"})):(r(i=>[...i,{...e,type:"digital"}]),N?.({...e,type:"digital"})),a("main"),C(null)},me=()=>{a("main"),C(null),y(null)},ge=()=>{a("main"),y(null)},we=()=>{A&&(C(A),y(null),a("form"))},V=e=>{console.log("deleting",e,s),le?.(e,s.find(i=>i.id.toString()===e.toString())?.type),r(i=>i.filter(g=>g.id!==e))},ce=()=>{j(""),B("all"),K("all")};return m==="typeSelection"?l(X,{onSelectHuman:()=>a("userSelection"),onSelectDigital:()=>a("digitalOptions"),onCancel:()=>a("main")}):m==="userSelection"?l(_,{users:oe,onUserSelect:se,onCancel:()=>a("typeSelection")}):m==="digitalOptions"?l(Z,{onCloneExisting:()=>a("digitalClone"),onCreateNew:de,onCancel:()=>a("typeSelection")}):m==="digitalClone"?l(Y,{digitalColleagues:ne,onColleagueClone:re,onCancel:()=>a("digitalOptions")}):m==="form"?l(O,{colleague:M||void 0,onSave:z,onCancel:me}):m==="view"?l(O,{colleague:A||void 0,onSave:z,onCancel:ge,readOnly:!0}):l("div",{className:"px-2 md:px-4 py-4 space-y-8",children:l(xe,{mode:"wait",children:l(he.div,{initial:{opacity:0,y:10},animate:{opacity:1,y:0},exit:{opacity:0,y:-10},transition:{duration:.2},children:t("div",{className:`space-y-6 ${ae||""}`,children:[l(Q,{title:"Colleagues",description:"Manage your team members and digital colleagues.",gradient:"bg-gradient-to-r from-green-600 via-emerald-600 to-teal-600",primaryAction:{label:"Add colleague",onClick:q}}),t("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4",children:[t(c,{children:[t(h,{className:"flex flex-row items-center justify-between space-y-0 pb-2",children:[l(x,{className:"text-sm font-medium",children:"Total Colleagues"}),l(ee,{className:"h-4 w-4 text-muted-foreground"})]}),t(u,{children:[l("div",{className:"text-2xl font-bold",children:s.length}),l("p",{className:"text-xs text-muted-foreground",children:"0 active"})]})]}),t(c,{children:[t(h,{className:"flex flex-row items-center justify-between space-y-0 pb-2",children:[l(x,{className:"text-sm font-medium",children:"Human Members"}),l(ve,{className:"h-4 w-4 text-muted-foreground"})]}),t(u,{children:[l("div",{className:"text-2xl font-bold",children:s.filter(e=>e.type==="human").length}),l("p",{className:"text-xs text-muted-foreground",children:"active"})]})]}),t(c,{children:[t(h,{className:"flex flex-row items-center justify-between space-y-0 pb-2",children:[l(x,{className:"text-sm font-medium",children:"Digital Colleagues"}),l(fe,{className:"h-4 w-4 text-muted-foreground"})]}),t(u,{children:[l("div",{className:"text-2xl font-bold",children:s.filter(e=>e.type==="digital").length}),l("p",{className:"text-xs text-muted-foreground",children:"0 active"})]})]})]}),l(c,{children:l(u,{className:"pt-6",children:t("div",{className:"flex flex-col md:flex-row gap-4",children:[l("div",{className:"flex-1",children:t("div",{className:"relative",children:[l(Ce,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),l(J,{placeholder:"Search colleagues...",value:d,onChange:e=>j(e.target.value),className:"pl-9"})]})}),t(U,{value:D,onValueChange:B,children:[l(k,{className:"w-full md:w-[180px]",children:l($,{placeholder:"Department"})}),t(F,{children:[l(p,{value:"all",children:"All Departments"}),te.map(e=>l(p,{value:e,children:e},e))]})]}),t(U,{value:b,onValueChange:K,children:[l(k,{className:"w-full md:w-[140px]",children:l($,{placeholder:"Status"})}),t(F,{children:[l(p,{value:"all",children:"All Status"}),l(p,{value:"active",children:"Active"}),l(p,{value:"inactive",children:"Inactive"})]})]}),(d||D!=="all"||b!=="all")&&t(H,{variant:"outline",onClick:ce,className:"gap-2",children:[l(ye,{className:"h-4 w-4"}),"Clear"]})]})})}),t("div",{className:"space-y-4",children:[l(R,{activeTab:v,onTabChange:ie,tabOptions:[{value:"all",label:`All (${f.length})`},{value:"human",label:`Human (${G.length})`},{value:"digital",label:`Digital (${W.length})`}],maxWidth:"400px",gridCols:3}),v==="all"&&l("div",{className:`grid gap-4 ${n?"grid-cols-1 md:grid-cols-2 lg:grid-cols-4":"grid-cols-1 md:grid-cols-2 lg:grid-cols-3"}`,children:f.map(e=>l(S,{colleague:e,onEdit:T,onDelete:V,onViewDetails:E,compact:n},`${e}-${e.id}`))}),v==="human"&&l("div",{className:`grid gap-4 ${n?"grid-cols-1 md:grid-cols-2 lg:grid-cols-4":"grid-cols-1 md:grid-cols-2 lg:grid-cols-3"}`,children:G.map(e=>l(S,{colleague:e,onEdit:T,onDelete:V,onViewDetails:E,compact:n},e.id))}),v==="digital"&&l("div",{className:`grid gap-4 ${n?"grid-cols-1 md:grid-cols-2 lg:grid-cols-4":"grid-cols-1 md:grid-cols-2 lg:grid-cols-3"}`,children:W.map(e=>l(S,{colleague:e,onEdit:T,onDelete:V,onViewDetails:E,compact:n},e.id))})]}),f.length===0&&l(c,{children:l(u,{className:"pt-6",children:t("div",{className:"text-center py-8",children:[l(ee,{className:"h-12 w-12 text-muted-foreground mx-auto mb-4"}),l("h3",{className:"text-lg font-semibold mb-2",children:"No colleagues found"}),l("p",{className:"text-muted-foreground mb-4",children:d||D!=="all"||b!=="all"?"Try adjusting your filters to see more results.":"Get started by adding your first colleague."}),t(H,{onClick:q,className:"gap-2",children:[l(pe,{className:"h-4 w-4"}),"Add Colleague"]})]})})})]})},"projects-index-view")})})}export{Se as a};
|
package/dist/chunk-K5MJYNCD.mjs
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";
|
|
3
|
-
|
|
4
|
-
import{a as g}from"./chunk-B4H6T2GP.mjs";import{a as u}from"./chunk-TVZOULLL.mjs";import{a as y}from"./chunk-L5JPAKPM.mjs";import{b as p}from"./chunk-ZUA4KNIR.mjs";import{b as k}from"./chunk-CSBGSBEU.mjs";import{a as D,b as h,c as w,e as N}from"./chunk-YO3GQYRJ.mjs";import{useState as b,useEffect as H}from"react";import{Bot as M,Plus as J,X as O,Edit as U}from"lucide-react";import{jsx as t,jsxs as i}from"react/jsx-runtime";function ie({colleague:d,onSave:I,onCancel:F,isLoading:o=!1,title:x,submitLabel:B,cancelLabel:E="Cancel",readOnly:S=!1,availableKnowledgeDocuments:W=[]}){let[a,s]=b({type:"digital",name:"",description:"",jobDescription:"",workInstructions:"",capabilities:[],capabilityLevel:0,...d}),[X,_]=b(""),[T,A]=b(""),[l,j]=b(!S);H(()=>{d&&s(d)},[d]);let K=e=>{e.preventDefault();let r={id:a.id||parseInt(Date.now().toString()),name:a.name,type:"digital",description:a.description,jobDescription:a.jobDescription||"",workInstructions:a.workInstructions||"",capabilities:a.capabilities||[],capabilityLevel:a.capabilityLevel||0};I(r)},C=(e,r,n)=>{if(!r.trim())return;let m=a[e]||[];s({...a,[e]:[...m,r.trim()]}),n("")},P=(e,r)=>{let n=a[e]||[];s({...a,[e]:n.filter((m,v)=>v!==r)})},L=e=>{e.preventDefault(),j(!l)},R=(e,r,n,m,v)=>{let z=a[e]||[];return i("div",{className:"space-y-2",children:[t(u,{children:r}),l&&i("div",{className:"flex gap-2",children:[t(y,{value:n,onChange:c=>m(c.target.value),placeholder:v,onKeyPress:c=>{c.key==="Enter"&&(c.preventDefault(),C(e,n,m))},disabled:o}),t(p,{type:"button",variant:"outline",size:"icon",onClick:()=>C(e,n,m),disabled:o,children:t(J,{className:"h-4 w-4"})})]}),t("div",{className:"flex flex-wrap gap-2",children:z.map((c,f)=>i(k,{className:"gap-1",children:[c,l&&t(p,{type:"button",variant:"ghost",size:"icon",className:"h-4 w-4 p-0 hover:bg-accent hover:text-accent-foreground",onClick:()=>P(e,f),disabled:o,children:t(O,{className:"h-3 w-3"})})]},`${e}-${f}-${c}`))})]})},$=x||(l?d?"Edit Colleague":"Add New Colleague":"View Colleague"),q=B||(d?"Update Colleague":"Add Colleague");return i(D,{className:"m-8 w-full max-w-4xl mx-auto",children:[t(h,{children:i(w,{className:"flex items-center gap-2",children:[t(M,{className:"h-5 w-5"}),$]})}),t(N,{children:i("form",{onSubmit:K,className:"space-y-6",children:[i("div",{className:"space-y-4",children:[i("div",{className:"space-y-2",children:[t(u,{htmlFor:"name",children:"Name *"}),t(y,{id:"name",value:a.name||"",onChange:e=>s({...a,name:e.target.value}),required:!0,disabled:o||!l})]}),i("div",{className:"space-y-2",children:[t(u,{htmlFor:"description",children:"Description"}),t(g,{id:"description",value:a.description||"",onChange:e=>s({...a,description:e.target.value}),rows:3,placeholder:"Brief description of this digital colleague...",disabled:o||!l})]})]}),i("div",{className:"space-y-4",children:[t("h3",{className:"text-lg font-semibold",children:"Digital Colleague Details"}),i("div",{className:"space-y-2",children:[t(u,{htmlFor:"jobDescription",children:"Job Description *"}),t(g,{id:"jobDescription",value:a.jobDescription||"",onChange:e=>s({...a,jobDescription:e.target.value}),rows:4,required:a.type==="digital",disabled:o||!l})]}),i("div",{className:"space-y-2",children:[t(u,{htmlFor:"workInstructions",children:"Work Instructions"}),t(g,{id:"workInstructions",value:a.workInstructions||"",onChange:e=>s({...a,workInstructions:e.target.value}),rows:4,placeholder:"Enter detailed work instructions for this digital colleague...",disabled:o||!l})]}),R("capabilities","Capabilities",T,A,"Add capability")]}),i("div",{className:"flex justify-end gap-2 pt-4 border-t",children:[t(p,{type:"button",variant:"outline",onClick:F,disabled:o,children:l?E:"Close"}),l?t(p,{type:"submit",disabled:o,children:o?"Saving...":q}):i(p,{type:"button",onClick:L,disabled:o,className:"gap-2",children:[t(U,{className:"h-4 w-4"}),"Edit"]})]})]})})]})}export{ie as a};
|
package/dist/chunk-KO6JUP2L.mjs
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";
|
|
3
|
-
|
|
4
|
-
import{a as N,c as b,d as y,g as w,i as g}from"./chunk-YFAZQYK4.mjs";import{a as f}from"./chunk-B4H6T2GP.mjs";import{a as c}from"./chunk-L5JPAKPM.mjs";import{b as r}from"./chunk-ZUA4KNIR.mjs";import{b as h}from"./chunk-CSBGSBEU.mjs";import{motion as z}from"motion/react";import{Edit3 as F,Save as I,X as S,Plus as T}from"lucide-react";import{useState as $}from"react";import{jsx as t,jsxs as o}from"react/jsx-runtime";function J({document:C,onSave:K,onCancel:D,availableDocuments:p=[],knowledgeContexts:E=[]}){let[l,d]=$({...C,updatedAt:new Date}),k=()=>{let e=new Set,a=new Set;return E.forEach(s=>{s.menuConfig.groupBy.forEach(n=>e.add(n))}),p.forEach(s=>{s.metadata&&Object.keys(s.metadata).forEach(n=>a.add(n))}),{contextKeys:Array.from(e).sort(),documentKeys:Array.from(a).sort(),allKeys:Array.from(new Set([...e,...a])).sort()}},_=e=>{let a=new Set;return p.forEach(s=>{s.metadata?.[e]&&a.add(String(s.metadata[e]))}),Array.from(a).sort()},m=k(),A=()=>{K(l)},i=(e,a)=>{d(s=>({...s,metadata:{...s.metadata,[e]:a}}))},B=(e,a)=>{a==="__custom__"?i(e,""):i(e,a)},M=()=>{let e=`field_${Date.now()}`;i(e,"")},V=e=>{d(a=>{let s={...a.metadata};return delete s[e],{...a,metadata:s}})};return o(z.div,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.3},className:"h-full flex flex-col",children:[o("div",{className:"border-b border-border bg-card p-8",children:[o("div",{className:"flex items-start justify-between gap-4 mb-6",children:[o("div",{className:"flex items-center gap-3",children:[t("div",{className:"flex-shrink-0 p-3 rounded-xl bg-primary/10 border border-primary/20",children:t(F,{className:"h-6 w-6 text-primary"})}),t("h1",{className:"text-2xl font-bold text-foreground",children:"Edit Document"})]}),o("div",{className:"flex gap-2",children:[o(r,{variant:"outline",size:"sm",onClick:D,className:"gap-2",children:[t(S,{className:"h-4 w-4"}),"Cancel"]}),o(r,{size:"sm",onClick:A,className:"gap-2",children:[t(I,{className:"h-4 w-4"}),"Save Changes"]})]})]}),o("div",{className:"space-y-4",children:[o("div",{children:[t("label",{className:"block text-sm font-medium text-foreground mb-2",children:"Title"}),t(c,{value:l.title,onChange:e=>d(a=>({...a,title:e.target.value})),className:"text-lg font-semibold",placeholder:"Document title..."})]}),o("div",{children:[t("label",{className:"block text-sm font-medium text-foreground mb-2",children:"Description"}),t(f,{value:l.description||"",onChange:e=>d(a=>({...a,description:e.target.value})),placeholder:"Document description...",rows:2})]}),o("div",{children:[o("div",{className:"flex items-center justify-between mb-3",children:[o("div",{children:[t("label",{className:"block text-sm font-medium text-foreground",children:"Metadata"}),m.contextKeys.length>0&&o("p",{className:"text-xs text-muted-foreground",children:["Suggested: ",m.contextKeys.slice(0,4).join(", "),m.contextKeys.length>4&&` +${m.contextKeys.length-4}`]})]}),o(r,{type:"button",variant:"outline",size:"sm",onClick:M,className:"gap-1 h-8",children:[t(T,{className:"h-3 w-3"}),"Add"]})]}),l.metadata&&Object.keys(l.metadata).length>0?t("div",{className:"space-y-2",children:Object.entries(l.metadata).map(([e,a])=>{let s=_(e);return o("div",{className:"flex gap-2 items-center",children:[t(c,{value:e,onChange:n=>{let v=n.target.value,j=l.metadata?.[e];d(x=>{let u={...x.metadata};return delete u[e],v&&(u[v]=j||""),{...x,metadata:u}})},placeholder:"Key",className:"w-32 h-8 text-sm",list:`metadata-keys-${e}`}),t("datalist",{id:`metadata-keys-${e}`,children:m.allKeys.map(n=>t("option",{value:n},n))}),t("span",{className:"text-muted-foreground text-sm",children:"="}),s.length>0?o(N,{value:String(a||""),onValueChange:n=>B(e,n),children:[t(y,{className:"flex-1 h-8 text-sm",children:t(b,{placeholder:"Value"})}),o(w,{children:[s.map(n=>t(g,{value:n,children:n},n)),t(g,{value:"__custom__",children:t("span",{className:"text-muted-foreground text-xs",children:"Custom..."})})]})]}):t(c,{value:String(a||""),onChange:n=>i(e,n.target.value),placeholder:"Value",className:"flex-1 h-8 text-sm"}),t(r,{type:"button",variant:"ghost",size:"sm",onClick:()=>V(e),className:"h-8 w-8 p-0 text-muted-foreground hover:text-destructive",children:t(S,{className:"h-3 w-3"})})]},e)})}):t("div",{className:"text-center py-3 border border-dashed border-border rounded-lg bg-muted/20",children:t("p",{className:"text-xs text-muted-foreground",children:'No metadata \u2022 Click "Add" to create fields'})})]}),o("div",{className:"flex items-center gap-2",children:[t("span",{className:"text-sm font-medium text-foreground",children:"Format:"}),t(h,{variant:"secondary",className:"font-mono",children:l.format.toUpperCase()})]})]})]}),t("div",{className:"flex-1 overflow-auto",children:o("div",{className:"p-8",children:[t("label",{className:"block text-sm font-medium text-foreground mb-4",children:"Content"}),t(f,{value:l.content||"",onChange:e=>d(a=>({...a,content:e.target.value})),placeholder:"Document content...",className:"min-h-[400px] font-mono text-sm",style:{resize:"vertical"}})]})})]})}export{J as a};
|
package/dist/chunk-MDBYZZXI.mjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as l}from"./chunk-MFE4VZPC.mjs";import{a as r}from"./chunk-Z22NSJMF.mjs";import{useState as u}from"react";import{jsx as e,jsxs as t}from"react/jsx-runtime";function p({documents:a=[],contexts:d=[],onDocumentClick:i=o=>console.log("Document clicked:",o),onDocumentShare:m=o=>console.log("Share document:",o),onLoadDocumentContent:g,selectedDocumentId:c}){let[o,s]=u(d[0]);return!d||d.length===0?t("div",{className:"flex flex-col h-full max-h-[calc(100vh-8rem)]",children:[e("div",{className:"px-2 md:px-4 py-4 flex-shrink-0",children:e(r,{title:"Knowledge",description:"Access, manage, and share all your team knowledge in one place.",gradient:"bg-gradient-to-r from-teal-600 via-cyan-600 to-blue-600",primaryAction:{label:"Create",onClick:()=>console.log("Create document clicked")}})}),e("div",{className:"flex-1 min-h-0 px-2 md:px-4 pb-4 flex items-center justify-center",children:e("p",{className:"text-muted-foreground",children:"No contexts available"})})]}):t("div",{className:"flex flex-col h-full max-h-[calc(100vh-8rem)]",children:[t("div",{className:"px-2 md:px-4 py-4 flex-shrink-0",children:[e(r,{title:"Knowledge",description:"Access, manage, and share all your team knowledge in one place.",gradient:"bg-gradient-to-r from-teal-600 via-cyan-600 to-blue-600",primaryAction:{label:"Create",onClick:()=>console.log("Create document clicked")}}),t("div",{className:"mt-6",children:[e("div",{className:"border-b border-border",children:e("nav",{className:"-mb-px flex space-x-8 overflow-x-auto",children:d.map(n=>t("button",{onClick:()=>s(n),className:`group inline-flex items-center gap-2 py-3 px-1 border-b-2 font-medium text-sm whitespace-nowrap transition-colors ${o.id===n.id?"border-primary text-primary":"border-transparent text-muted-foreground hover:text-foreground hover:border-muted-foreground"}`,children:[n.icon,n.label]},n.id))})}),o.description&&e("div",{className:"mt-3 px-1",children:e("p",{className:"text-sm text-muted-foreground",children:o.description})})]})]}),e("div",{className:"flex-1 min-h-0 px-2 md:px-4 pb-4",children:e("div",{className:"h-full rounded-3xl border overflow-hidden",children:e(l,{documents:a,menuConfig:o.menuConfig,onDocumentClick:i,onDocumentShare:m,selectedDocumentId:c})})})]})}export{p as a};
|
package/dist/chunk-MFE4VZPC.mjs
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";
|
|
3
|
-
|
|
4
|
-
import{a as H}from"./chunk-5ROLUQ45.mjs";import{a as L}from"./chunk-FT3AE7L2.mjs";import{a as I}from"./chunk-L5JPAKPM.mjs";import{motion as p}from"motion/react";import{ChevronRight as T,File as O,FileText as k,Search as F}from"lucide-react";import{useState as K,useMemo as B}from"react";import{jsx as e,jsxs as n}from"react/jsx-runtime";function $({label:f,documents:m,children:i,level:u,onDocumentClick:x,selectedDocumentId:h,showDocumentCount:w=!0}){let[c,s]=K(u===0),b=i&&Object.keys(i).length>0,v=m.length+(i?Object.values(i).reduce((t,r)=>t+r.documents.length,0):0),N=t=>{switch(t){case"markdown":case"mdx":return e(k,{className:"h-3.5 w-3.5 text-muted-foreground"});case"richtext":return e(O,{className:"h-3.5 w-3.5 text-muted-foreground"});default:return e(O,{className:"h-3.5 w-3.5 text-muted-foreground"})}},y=t=>{let r=["bg-primary","bg-secondary","bg-accent","bg-chart-1"];return r[t%r.length]};return n("div",{className:"space-y-1",children:[(b||m.length>0)&&n(p.div,{className:`group flex items-center gap-3 p-3 rounded-xl cursor-pointer transition-all duration-200 ${c?"bg-card shadow-sm border border-border":"hover:bg-muted/50 hover:shadow-sm"}`,style:{marginLeft:`${u*20}px`},onClick:()=>s(!c),whileHover:{scale:1.01},whileTap:{scale:.99},children:[e("div",{className:`w-1 h-6 rounded-full ${y(u)}`}),e(p.div,{animate:{rotate:c?90:0},transition:{duration:.2},className:"flex-shrink-0",children:e(T,{className:"h-4 w-4 text-muted-foreground"})}),n("div",{className:"flex-1 flex items-center justify-between min-w-0",children:[e("div",{className:"flex items-center gap-2 min-w-0",children:e("span",{className:"font-medium text-foreground truncate",children:f})}),w&&v>0&&e("div",{className:"flex-shrink-0 ml-2",children:e("span",{className:"inline-flex items-center justify-center w-6 h-6 text-xs font-medium bg-muted text-muted-foreground rounded-full",children:v})})]})]}),e(p.div,{initial:!1,animate:{height:c?"auto":0,opacity:c?1:0},transition:{duration:.2,ease:"easeInOut"},className:"overflow-hidden",children:n("div",{className:"pt-2 space-y-1",children:[m.map((t,r)=>n(p.div,{initial:{opacity:0,x:-10},animate:{opacity:1,x:0},transition:{delay:r*.05,duration:.2},className:`group flex items-center gap-3 p-2.5 mx-2 rounded-lg cursor-pointer transition-all duration-150 ${h===t.id?"bg-primary/10 border-l-2 border-primary shadow-sm":"hover:bg-muted/50 hover:translate-x-1"}`,style:{marginLeft:`${u*20+20}px`},onClick:()=>x?.(t),whileHover:{scale:1.01},whileTap:{scale:.99},children:[e("div",{className:"flex-shrink-0",children:N(t.format)}),n("div",{className:"flex-1 min-w-0",children:[e("p",{className:`text-sm truncate transition-colors ${h===t.id?"text-primary font-medium":"text-foreground group-hover:text-foreground"}`,children:t.title}),t.description&&e("p",{className:"text-xs text-muted-foreground truncate mt-0.5",children:t.description})]}),t.tags&&t.tags.length>0&&e("div",{className:"flex-shrink-0",children:e("span",{className:"inline-flex items-center px-2 py-1 rounded-md text-xs font-medium bg-muted text-muted-foreground group-hover:bg-muted/80 transition-colors",children:t.tags[0]})})]},t.id)),i&&Object.entries(i).map(([t,r])=>e($,{label:t,documents:r.documents,children:r.children,level:u+1,onDocumentClick:x,selectedDocumentId:h,showDocumentCount:w},t))]})})]})}function V({documents:f,menuConfig:m,onDocumentClick:i,onDocumentShare:u,onDocumentUpdate:x,selectedDocumentId:h,className:w,editable:c=!0}){let[s,b]=K(""),[v,N]=K(null),y=B(()=>s?f.filter(o=>o.title.toLowerCase().includes(s.toLowerCase())||o.description?.toLowerCase().includes(s.toLowerCase())||o.tags?.some(d=>d.toLowerCase().includes(s.toLowerCase()))||Object.values(o.metadata||{}).some(d=>String(d).toLowerCase().includes(s.toLowerCase()))):f,[f,s]),t=B(()=>{let o=(d,j)=>{if(j.length===0)return{};let[M,...S]=j;return d.reduce((a,D)=>{let P=D.metadata?.[M]||"Uncategorized",l=String(P);if(a[l]||(a[l]={documents:[],children:{}}),S.length===0)a[l].documents.push(D);else{let C=o([D],S),g=Object.keys(C)[0];g&&(a[l].children||(a[l].children={}),a[l].children[g]?a[l].children[g].documents.push(...C[g].documents):a[l].children[g]=C[g])}return a},{})};return o(y,m.groupBy)},[y,m.groupBy]),r=o=>{N(o),i?.(o)};return n("div",{className:`flex h-full ${w||""}`,children:[n("div",{className:"w-1/3 border-r border-border bg-muted/20",children:[e("div",{className:"p-6 border-b border-border",children:n("div",{className:"relative",children:[e("div",{className:"absolute inset-y-0 left-0 pl-3 flex items-center pointer-events-none",children:e(F,{className:"h-4 w-4 text-muted-foreground"})}),e(I,{placeholder:"Search knowledge base...",value:s,onChange:o=>b(o.target.value),className:"pl-10 bg-background/80 border-border focus:border-primary/50 focus:ring-primary/20 rounded-xl h-11 text-sm placeholder:text-muted-foreground"})]})}),e(L,{className:"h-[calc(100%-100px)]",children:n("div",{className:"p-4 space-y-3",children:[Object.entries(t).map(([o,d])=>e($,{label:o,documents:d.documents,children:d.children,level:0,onDocumentClick:r,selectedDocumentId:h,showDocumentCount:m.showDocumentCount},o)),Object.keys(t).length===0&&n(p.div,{initial:{opacity:0},animate:{opacity:1},className:"text-center text-muted-foreground py-12",children:[e("div",{className:"w-16 h-16 mx-auto mb-4 rounded-full bg-muted flex items-center justify-center",children:e(k,{className:"h-8 w-8 text-muted-foreground"})}),e("p",{className:"text-sm font-medium",children:"No documents found"}),e("p",{className:"text-xs mt-1",children:"Try adjusting your search terms"})]})]})})]}),e("div",{className:"flex-1 bg-background",children:v?e(H,{document:v,onDocumentUpdate:x,editable:c}):e("div",{className:"h-full flex items-center justify-center text-center",children:n(p.div,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.4},className:"max-w-sm",children:[e("div",{className:"w-20 h-20 mx-auto mb-6 rounded-full bg-primary/10 flex items-center justify-center",children:e(k,{className:"h-10 w-10 text-primary"})}),e("h3",{className:"text-xl font-semibold text-foreground mb-2",children:"Select a document"}),e("p",{className:"text-muted-foreground leading-relaxed",children:"Choose any document from the knowledge base to view its content and details"})]})})})]})}export{V as a};
|