@e-llm-studio/citation 0.0.199 → 0.0.200
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.
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),t=require("react/jsx-runtime"),n=require("react"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),t=require("react/jsx-runtime"),n=require("react"),o=require("lucide-react");exports.default=function(i){var r,s,a,l,d=i.children,u=i.uploadListTopContent,c=i.defaultHeight,p=void 0===c?300:c,g=i.minHeight,f=void 0===g?150:g,x=i.maxHeight,h=i.isExpanded,v=void 0!==h&&h,m=i.onToggle,b=i.onHeightChange,y=i.styles,_=void 0===y?{}:y,w=i.drawerSummaryComponent,C=i.totalCountsBadge,j=i.headerComponent,H=n.useState(!1),S=H[0],R=H[1],k=n.useState(p),E=k[0],B=k[1],D=n.useRef(0),I=n.useRef(p),L=n.useRef(null),z=n.useRef(0),q="string"==typeof x?parseFloat(x)/100*window.innerHeight:null!=x?x:.4*window.innerHeight;n.useEffect(function(){!v&&L.current&&(z.current=L.current.getBoundingClientRect().height)},[v]);return n.useEffect(function(){if(S){var e=function(e){e.preventDefault();var t=e.clientY-D.current,n=Math.max(f,Math.min(q,I.current+t));B(n),null==b||b(n)},t=function(){R(!1),document.body.style.userSelect=""};return document.addEventListener("mousemove",e),document.addEventListener("mouseup",t),function(){document.removeEventListener("mousemove",e),document.removeEventListener("mouseup",t)}}},[S]),t.jsxs("div",e.__assign({ref:L,style:{position:"relative",width:"100%",minHeight:v?z.current:"auto"}},{children:[t.jsxs("div",e.__assign({style:e.__assign({position:v?"absolute":"relative",zIndex:v?10:"auto",left:0,right:0,top:0,display:"flex",flexDirection:"column",backgroundColor:"#fff",borderRadius:20,border:"1px solid #BDB4FE",boxShadow:"0 4px 8px -2px rgba(16, 24, 40, 0.05), 0 2px 4px -2px rgba(16, 24, 40, 0.06)",height:v?"".concat(E,"px"):"auto",minHeight:v?"".concat(f,"px"):"auto",maxHeight:v?"".concat(E,"px"):"auto",overflow:"hidden",width:"100%"},_.container)},{children:[t.jsxs("div",e.__assign({style:e.__assign({display:"flex",alignItems:"center",justifyContent:"space-between",width:"100%",marginBottom:12,flexShrink:0,padding:"12px 20px 0 20px",gap:"16px"},_.header)},{children:[t.jsx("span",e.__assign({style:e.__assign({display:"inline-block",flex:1,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",fontSize:16,fontWeight:500,lineHeight:"24px",color:"#101828",fontFamily:"Inter, sans-serif"},_.title)},{children:j||((null==u?void 0:u.trim())?u:"Data uploaded for your context")})),C]})),w,v&&t.jsx("div",e.__assign({style:e.__assign({flex:1,overflowY:"auto",overflowX:"hidden",minHeight:0,padding:"0 20px",paddingBottom:"36px"},_.body)},{children:d})),v&&t.jsx("div",e.__assign({onMouseDown:function(e){e.preventDefault(),R(!0),D.current=e.clientY,I.current=E,document.body.style.userSelect="none"},style:{position:"absolute",bottom:0,left:0,right:0,backgroundColor:null!==(s=null===(r=_.body)||void 0===r?void 0:r.backgroundColor)&&void 0!==s?s:"#fff",display:"flex",justifyContent:"center",alignItems:"center",padding:"8px 20px",cursor:"ns-resize",userSelect:"none",flexShrink:0}},{children:t.jsx("div",{style:e.__assign({width:48,height:4,borderRadius:4,background:S?null!==(a=_.dragPillActiveColor)&&void 0!==a?a:"#a78bfa":"#d1d5db"},_.dragPill)})}))]})),t.jsx("div",e.__assign({style:{position:v?"absolute":"relative",top:v?"".concat(E,"px"):"auto",width:"100%",display:"flex",justifyContent:"center",height:18,zIndex:v?10:"auto"}},{children:t.jsx("button",e.__assign({onClick:m,"aria-label":v?"Collapse":"Expand",style:e.__assign({position:"absolute",width:"52px",height:"18px",borderBottomLeftRadius:"10px",borderBottomRightRadius:"10px",border:"1px solid rgb(189, 180, 254)",borderTop:"none",backgroundColor:"#fff",display:"flex",alignItems:"center",justifyContent:"center",cursor:"pointer",padding:0},_.notch)},{children:t.jsx(o.ChevronDown,{size:14,color:null!==(l=_.notchArrowColor)&&void 0!==l?l:"#6d28d9",style:{transform:v?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.2s ease"}})}))}))]}))};
|
|
2
2
|
//# sourceMappingURL=ChatDrawer.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as e}from"tslib";import{jsxs as t,jsx as o}from"react/jsx-runtime";import{useState as n,useRef as i,useEffect as r}from"react";import{ChevronDown as l}from"lucide-react";var d=function(d){var a,s,
|
|
1
|
+
import{__assign as e}from"tslib";import{jsxs as t,jsx as o}from"react/jsx-runtime";import{useState as n,useRef as i,useEffect as r}from"react";import{ChevronDown as l}from"lucide-react";var d=function(d){var a,u,s,c,p=d.children,f=d.uploadListTopContent,h=d.defaultHeight,g=void 0===h?300:h,m=d.minHeight,x=void 0===m?150:m,v=d.maxHeight,b=d.isExpanded,y=void 0!==b&&b,w=d.onToggle,C=d.onHeightChange,H=d.styles,k=void 0===H?{}:H,S=d.drawerSummaryComponent,B=d.totalCountsBadge,E=d.headerComponent,D=n(!1),I=D[0],L=D[1],R=n(g),j=R[0],z=R[1],F=i(0),M=i(g),T=i(null),Y=i(0),A="string"==typeof v?parseFloat(v)/100*window.innerHeight:null!=v?v:.4*window.innerHeight;r(function(){!y&&T.current&&(Y.current=T.current.getBoundingClientRect().height)},[y]);return r(function(){if(I){var e=function(e){e.preventDefault();var t=e.clientY-F.current,o=Math.max(x,Math.min(A,M.current+t));z(o),null==C||C(o)},t=function(){L(!1),document.body.style.userSelect=""};return document.addEventListener("mousemove",e),document.addEventListener("mouseup",t),function(){document.removeEventListener("mousemove",e),document.removeEventListener("mouseup",t)}}},[I]),t("div",e({ref:T,style:{position:"relative",width:"100%",minHeight:y?Y.current:"auto"}},{children:[t("div",e({style:e({position:y?"absolute":"relative",zIndex:y?10:"auto",left:0,right:0,top:0,display:"flex",flexDirection:"column",backgroundColor:"#fff",borderRadius:20,border:"1px solid #BDB4FE",boxShadow:"0 4px 8px -2px rgba(16, 24, 40, 0.05), 0 2px 4px -2px rgba(16, 24, 40, 0.06)",height:y?"".concat(j,"px"):"auto",minHeight:y?"".concat(x,"px"):"auto",maxHeight:y?"".concat(j,"px"):"auto",overflow:"hidden",width:"100%"},k.container)},{children:[t("div",e({style:e({display:"flex",alignItems:"center",justifyContent:"space-between",width:"100%",marginBottom:12,flexShrink:0,padding:"12px 20px 0 20px",gap:"16px"},k.header)},{children:[o("span",e({style:e({display:"inline-block",flex:1,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",fontSize:16,fontWeight:500,lineHeight:"24px",color:"#101828",fontFamily:"Inter, sans-serif"},k.title)},{children:E||((null==f?void 0:f.trim())?f:"Data uploaded for your context")})),B]})),S,y&&o("div",e({style:e({flex:1,overflowY:"auto",overflowX:"hidden",minHeight:0,padding:"0 20px",paddingBottom:"36px"},k.body)},{children:p})),y&&o("div",e({onMouseDown:function(e){e.preventDefault(),L(!0),F.current=e.clientY,M.current=j,document.body.style.userSelect="none"},style:{position:"absolute",bottom:0,left:0,right:0,backgroundColor:null!==(u=null===(a=k.body)||void 0===a?void 0:a.backgroundColor)&&void 0!==u?u:"#fff",display:"flex",justifyContent:"center",alignItems:"center",padding:"8px 20px",cursor:"ns-resize",userSelect:"none",flexShrink:0}},{children:o("div",{style:e({width:48,height:4,borderRadius:4,background:I?null!==(s=k.dragPillActiveColor)&&void 0!==s?s:"#a78bfa":"#d1d5db"},k.dragPill)})}))]})),o("div",e({style:{position:y?"absolute":"relative",top:y?"".concat(j,"px"):"auto",width:"100%",display:"flex",justifyContent:"center",height:18,zIndex:y?10:"auto"}},{children:o("button",e({onClick:w,"aria-label":y?"Collapse":"Expand",style:e({position:"absolute",width:"52px",height:"18px",borderBottomLeftRadius:"10px",borderBottomRightRadius:"10px",border:"1px solid rgb(189, 180, 254)",borderTop:"none",backgroundColor:"#fff",display:"flex",alignItems:"center",justifyContent:"center",cursor:"pointer",padding:0},k.notch)},{children:o(l,{size:14,color:null!==(c=k.notchArrowColor)&&void 0!==c?c:"#6d28d9",style:{transform:y?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.2s ease"}})}))}))]}))};export{d as default};
|
|
2
2
|
//# sourceMappingURL=ChatDrawer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChatDrawer.d.ts","sourceRoot":"","sources":["../../../../../src/features/ChatDrawer/ChatDrawer.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAE3D,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAE3D,QAAA,MAAM,UAAU,EAAE,KAAK,CAAC,EAAE,CAAC,eAAe,
|
|
1
|
+
{"version":3,"file":"ChatDrawer.d.ts","sourceRoot":"","sources":["../../../../../src/features/ChatDrawer/ChatDrawer.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAE3D,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAE3D,QAAA,MAAM,UAAU,EAAE,KAAK,CAAC,EAAE,CAAC,eAAe,CAyNzC,CAAC;AAEF,eAAe,UAAU,CAAC"}
|