@e-llm-studio/citation 0.0.170 → 0.0.171
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/cjs/features/ChatDrawer/ChatDrawer.js +1 -1
- package/dist/cjs/features/CodeCitation/_components/TooltipComponent.js +1 -1
- package/dist/cjs/features/CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.js +1 -1
- package/dist/features/ChatDrawer/ChatDrawer.js +1 -1
- package/dist/features/CodeCitation/_components/TooltipComponent.js +1 -1
- package/dist/features/CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.js +1 -1
- package/dist/types/src/features/ChatDrawer/types/ChatDrawer.types.d.ts +2 -0
- package/dist/types/src/features/ChatDrawer/types/ChatDrawer.types.d.ts.map +1 -1
- package/dist/types/src/features/CodeCitation/_components/TooltipComponent.d.ts.map +1 -1
- package/dist/types/src/features/CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -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"),i=require("lucide-react");exports.default=function(o){var r,s=o.children,
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),t=require("react/jsx-runtime"),n=require("react"),i=require("lucide-react");exports.default=function(o){var r,s,a=o.children,l=o.uploadListTopContent,d=o.defaultHeight,u=void 0===d?300:d,c=o.minHeight,p=void 0===c?150:c,g=o.maxHeight,f=o.isExpanded,x=void 0!==f&&f,h=o.onToggle,v=o.onHeightChange,m=o.styles,_=void 0===m?{}:m,y=n.useState(!1),b=y[0],w=y[1],j=n.useState(u),C=j[0],H=j[1],R=n.useRef(0),S=n.useRef(u),E=n.useRef(null),k=n.useRef(0),D="string"==typeof g?parseFloat(g)/100*window.innerHeight:null!=g?g:.4*window.innerHeight;n.useEffect(function(){!x&&E.current&&(k.current=E.current.getBoundingClientRect().height)},[x]);return n.useEffect(function(){if(b){var e=function(e){e.preventDefault();var t=e.clientY-R.current,n=Math.max(p,Math.min(D,S.current+t));H(n),null==v||v(n)},t=function(){w(!1),document.body.style.userSelect=""};return document.addEventListener("mousemove",e),document.addEventListener("mouseup",t),function(){document.removeEventListener("mousemove",e),document.removeEventListener("mouseup",t)}}},[b]),t.jsxs("div",e.__assign({ref:E,style:{position:"relative",width:"100%",minHeight:x?k.current:"auto"}},{children:[t.jsxs("div",e.__assign({style:e.__assign({position:x?"absolute":"relative",zIndex:x?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:x?"".concat(C,"px"):"auto",minHeight:x?"".concat(p,"px"):"auto",maxHeight:x?"".concat(C,"px"):"auto",overflow:"hidden",width:"100%"},_.container)},{children:[t.jsx("div",e.__assign({style:e.__assign({display:"flex",alignItems:"center",width:"100%",marginBottom:12,flexShrink:0,padding:"12px 20px 0 20px"},_.header)},{children:t.jsx("span",e.__assign({style:e.__assign({display:"inline-block",maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",fontSize:16,fontWeight:500,lineHeight:"24px",color:"#101828",fontFamily:"Inter, sans-serif"},_.title)},{children:(null==l?void 0:l.trim())?l:"Data uploaded for your context"}))})),x&&t.jsx("div",e.__assign({style:e.__assign({flex:1,overflowY:"auto",overflowX:"hidden",minHeight:0,padding:"0 20px"},_.body)},{children:a})),x&&t.jsx("div",e.__assign({onMouseDown:function(e){e.preventDefault(),w(!0),R.current=e.clientY,S.current=C,document.body.style.userSelect="none"},style:{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:b?null!==(r=_.dragPillActiveColor)&&void 0!==r?r:"#a78bfa":"#d1d5db"},_.dragPill)})}))]})),t.jsx("div",e.__assign({style:{position:x?"absolute":"relative",top:x?"".concat(C,"px"):"auto",width:"100%",display:"flex",justifyContent:"center",height:18,zIndex:x?10:"auto"}},{children:t.jsx("button",e.__assign({onClick:h,"aria-label":x?"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(i.ChevronDown,{size:14,color:null!==(s=_.notchArrowColor)&&void 0!==s?s:"#6d28d9",style:{transform:x?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.2s ease"}})}))}))]}))};
|
|
2
2
|
//# sourceMappingURL=ChatDrawer.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),r=require("react/jsx-runtime"),t=require("@mui/material/Tooltip"),a=require("@mui/material/styles");function s(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var i=s(t),n=a.styled(function(t){var a=t.className,s=e.__rest(t,["className"]);return r.jsx(i.default,e.__assign({},s,{classes:{popper:a}}))})(function(){var e;return(e={})["& .".concat(t.tooltipClasses.tooltip)]={fontFamily:"Plus Jakarta Sans, sans-serif",backgroundColor:"#555",color:"#fff",fontSize:12,padding:"5px 8px",borderRadius:6,maxWidth:250,textAlign:"center",whiteSpace:"normal",wordBreak:"break-word",lineHeight:1.4},e["& .".concat(t.tooltipClasses.arrow)]={color:"#555"},e});exports.default=function(t){var a=t.description,s=t.children;return r.jsx(n,e.__assign({title:r.jsx("span",{children:a})
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),r=require("react/jsx-runtime"),t=require("@mui/material/Tooltip"),a=require("@mui/material/styles");function s(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var i=s(t),n=a.styled(function(t){var a=t.className,s=e.__rest(t,["className"]);return r.jsx(i.default,e.__assign({},s,{classes:{popper:a},arrow:!0,placement:"top"}))})(function(){var e;return(e={})["& .".concat(t.tooltipClasses.tooltip)]={fontFamily:"Plus Jakarta Sans, sans-serif",backgroundColor:"#555",color:"#fff",fontSize:12,padding:"5px 8px",borderRadius:6,maxWidth:250,textAlign:"center",whiteSpace:"normal",wordBreak:"break-word",lineHeight:1.4},e["& .".concat(t.tooltipClasses.arrow)]={color:"#555"},e});exports.default=function(t){var a=t.description,s=t.children;return r.jsx(n,e.__assign({title:r.jsx("span",{children:a})},{children:r.jsx("span",e.__assign({style:{display:"inline-block"}},{children:s}))}))};
|
|
2
2
|
//# sourceMappingURL=TooltipComponent.js.map
|
package/dist/cjs/features/CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),n=require("react/jsx-runtime"),s=require("react"),a=require("./CognitiveNonWebSearchReasoning.module.css.js"),t=require("lucide-react");exports.default=function(i){var l=i.item,c=i.index,r=i.iconsConfig,d=i.headerTitle,o=void 0===d?"GPT - Gemini 2.5 Flash":d,u=i.previewCallback,h=i.DocumentTitle,f=null==r?void 0:r.ChevronDownIcon,g=null==r?void 0:r.ChevronUpIcon,_=null==r?void 0:r.MaximizeIcon,m=null==r?void 0:r.CloseIcon,x=s.useState(!1),v=x[0],
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),n=require("react/jsx-runtime"),s=require("react"),a=require("./CognitiveNonWebSearchReasoning.module.css.js"),t=require("lucide-react");exports.default=function(i){var l=i.item,c=i.index,r=i.iconsConfig,d=i.headerTitle,o=void 0===d?"GPT - Gemini 2.5 Flash":d,u=i.previewCallback,h=i.DocumentTitle,f=null==r?void 0:r.ChevronDownIcon,g=null==r?void 0:r.ChevronUpIcon,_=null==r?void 0:r.MaximizeIcon,m=null==r?void 0:r.CloseIcon,x=s.useState(!1),v=x[0],j=x[1],p=s.useState(0),N=p[0],I=p[1],C=s.useRef(null),b=s.useRef(null),T=s.useRef(null),k=s.useRef([]),H=s.useRef([]),L=s.useMemo(function(){return l.dataSource?l.dataSource.replace(/\\n/g,"\n").replace(/\n+/g,"\n"):""},[l.dataSource]),S=s.useMemo(function(){var e=L.split(/(<highlight>[\s\S]*?<\/highlight>)/g)||[],n=e.filter(function(e){return e.startsWith("<highlight>")}).length,s=0;return{parts:e.map(function(e,n){var a=e.startsWith("<highlight>"),t={text:a?e.replace(/<\/?highlight>/g,""):e,isHighlight:a,highlightIndex:a?s:-1,idx:n};return a&&s++,t}),totalHighlights:n}},[L]),B=S.parts,y=S.totalHighlights,D=function(e,n){void 0===n&&(n=!1);var s=n?H.current[e]:k.current[e],a=n?b.current:C.current;s&&a&&s.scrollIntoView({behavior:"smooth",block:"center"})},R=function(e){if(void 0===e&&(e=!1),y){var n=N>0?N-1:y-1;I(n),setTimeout(function(){return D(n,e)},50)}},W=function(e){if(void 0===e&&(e=!1),y){var n=N<y-1?N+1:0;I(n),setTimeout(function(){return D(n,e)},50)}};s.useEffect(function(){k.current=k.current.slice(0,y),H.current=H.current.slice(0,y)},[y]),s.useEffect(function(){var e;return v&&y>0&&(I(0),e=setTimeout(function(){return D(0)},50)),function(){e&&clearTimeout(e)}},[v,y]);var w=function(s){return s.split(/(\*\*.*?\*\*|__.*?__)/g).map(function(s,t){return s.startsWith("**")&&s.endsWith("**")||s.startsWith("__")&&s.endsWith("__")?n.jsx("strong",e.__assign({className:a.default.boldText},{children:s.slice(2,-2)}),t):s})},A=s.useMemo(function(){var n=[],s=[];return B.forEach(function(a){var t=a.text,i=a.isHighlight,l=a.highlightIndex;t.split("\n").forEach(function(a,t){t>0&&((s.length>0||n.length>0)&&n.push({segments:e.__spreadArray([],s,!0),isListItem:!1,isHeader:!1,indent:"",content:""}),s=[]),a&&s.push({text:a,isHighlight:i,highlightIndex:l})})}),s.length>0&&n.push({segments:e.__spreadArray([],s,!0),isListItem:!1,isHeader:!1,indent:"",content:""}),n.map(function(n){var s=n.segments.map(function(e){return e.text}).join(""),a=s.match(/^(\s*)(-|\*|\d+\.)\s+(.*)$/),t=s.match(/^(Title|Description|Training-basis):\s*(.*)$/i);return e.__assign(e.__assign({},n),{isListItem:!!a,isHeader:!!t,indent:(null==a?void 0:a[1])||"",content:(null==a?void 0:a[3])||s})})},[B]),E=function(s){void 0===s&&(s=!1);var t=0;return A.map(function(i,l){i.isHeader&&(t=0),i.isListItem&&(t+=1);var c=function(){return i.segments.map(function(t,l){var c=t.isHighlight&&t.highlightIndex===N,r=t.text;return i.isListItem&&0===l&&(r=t.text.replace(/^(\s*)(-|\*|\d+\.)\s+/,"")),t.isHighlight?n.jsx("span",e.__assign({ref:function(e){e&&(s?H.current[t.highlightIndex]=e:k.current[t.highlightIndex]=e)},className:"".concat(a.default.highlight).concat(c?" ".concat(a.default.highlightActive):"")},{children:w(r)}),l):n.jsx("span",{children:w(r)},l)})};return i.isHeader?n.jsx("span",e.__assign({className:a.default.headerLine},{children:c()}),l):i.isListItem?n.jsxs("span",e.__assign({className:a.default.listItemLine,style:{paddingLeft:i.indent?"1rem":"0"}},{children:[n.jsxs("span",e.__assign({className:a.default.listCounter},{children:[t,"."]})),n.jsx("span",{children:c()})]}),l):n.jsx("span",e.__assign({className:a.default.blockLine},{children:c()}),l)})};return n.jsxs("div",e.__assign({className:a.default.container},{children:[n.jsxs("div",e.__assign({className:a.default.itemRow},{children:["number"==typeof c&&n.jsxs("span",e.__assign({className:a.default.indexNumber},{children:[c+1,"."]})),n.jsxs("div",e.__assign({className:a.default.textContent},{children:[n.jsx("span",{children:null==l?void 0:l.text}),(null==l?void 0:l.paraphrase)&&n.jsxs("button",e.__assign({type:"button",onClick:function(){return j(!v)},className:a.default.paraphraseButton},{children:[n.jsxs("span",e.__assign({className:a.default.paraphraseText},{children:[n.jsx("span",e.__assign({className:a.default.paraphraseStar},{children:"✦"})),l.paraphrase]})),f&&n.jsx(f,{className:"".concat(a.default.chevronIcon).concat(v?" ".concat(a.default.chevronIconRotated):"")})]}))]}))]})),v&&n.jsxs("div",e.__assign({className:a.default.expandedContainer},{children:[n.jsxs("div",e.__assign({className:a.default.expandedHeader},{children:[n.jsx("span",e.__assign({className:a.default.headerTitle},{children:o})),n.jsxs("div",e.__assign({className:a.default.headerActions},{children:[y>1&&n.jsxs("div",e.__assign({className:a.default.navigationContainer},{children:[g&&n.jsx("button",e.__assign({onClick:function(){return R(!1)},className:a.default.navButton},{children:n.jsx(g,{className:a.default.navIcon})})),n.jsxs("span",e.__assign({className:a.default.navCounter},{children:[N+1,"/",y]})),f&&n.jsx("button",e.__assign({onClick:function(){return W(!1)},className:a.default.navButton},{children:n.jsx(f,{className:a.default.navIcon})}))]})),null!=(null==l?void 0:l.confidence_score)&&n.jsxs("span",e.__assign({className:a.default.confidenceBadge},{children:[n.jsx("span",e.__assign({className:a.default.confidenceStar},{children:"✦"})),n.jsxs("span",e.__assign({className:a.default.confidenceScore},{children:[null==l?void 0:l.confidence_score,"%"]}))]})),_&&n.jsx("button",e.__assign({onClick:function(){var e;null===(e=T.current)||void 0===e||e.showModal()},className:a.default.maximizeButton,title:"View fullscreen"},{children:n.jsx(_,{className:a.default.maximizeIcon})}))]}))]})),n.jsx("div",e.__assign({ref:C,className:a.default.contentArea},{children:n.jsx("div",e.__assign({className:a.default.contentInner},{children:E(!1)}))})),l.trainingDataTitle&&n.jsx("div",e.__assign({className:a.default.footer},{children:n.jsx("span",e.__assign({className:a.default.trainingTitle},{children:l.trainingDataTitle}))})),h&&n.jsx("div",e.__assign({className:a.default.modalFooterSource},{children:n.jsxs("button",e.__assign({type:"button",onClick:function(){null==u||u()},className:a.default.trainingTitleLink},{children:[h,n.jsx(t.ExternalLink,{size:16,color:"#2563eb"})]}))}))]})),n.jsx("dialog",e.__assign({ref:T,className:a.default.modalDialog,onClick:function(e){var n;e.target===T.current&&(null===(n=T.current)||void 0===n||n.close())}},{children:n.jsxs("div",e.__assign({className:a.default.modalContainer},{children:[n.jsxs("div",e.__assign({className:a.default.modalHeader},{children:[n.jsx("span",e.__assign({className:a.default.modalHeaderTitle},{children:o})),n.jsxs("div",e.__assign({className:a.default.modalHeaderActions},{children:[y>1&&n.jsxs("div",e.__assign({className:a.default.modalNavContainer},{children:[g&&n.jsx("button",e.__assign({onClick:function(){return R(!0)},className:a.default.modalNavButton},{children:n.jsx(g,{className:a.default.navIcon})})),n.jsxs("span",e.__assign({className:a.default.navCounter},{children:[N+1,"/",y]})),f&&n.jsx("button",e.__assign({onClick:function(){return W(!0)},className:a.default.modalNavButton},{children:n.jsx(f,{className:a.default.navIcon})}))]})),null!=(null==l?void 0:l.confidence_score)&&n.jsxs("span",e.__assign({className:a.default.confidenceBadge},{children:[n.jsx("span",e.__assign({className:a.default.confidenceStar},{children:"✦"})),n.jsxs("span",e.__assign({className:a.default.confidenceScore},{children:[null==l?void 0:l.confidence_score,"%"]}))]})),m&&n.jsx("button",e.__assign({onClick:function(){var e;null===(e=T.current)||void 0===e||e.close()},className:a.default.closeButton,title:"Close"},{children:n.jsx(m,{className:a.default.closeIcon})}))]}))]})),n.jsx("div",e.__assign({ref:b,className:a.default.modalContent},{children:n.jsx("div",e.__assign({className:a.default.modalContentInner},{children:E(!0)}))})),l.trainingDataTitle&&n.jsx("div",e.__assign({className:a.default.modalFooter},{children:n.jsx("span",e.__assign({className:a.default.trainingTitle},{children:l.trainingDataTitle}))})),h&&n.jsx("div",e.__assign({className:a.default.modalFooterSource},{children:n.jsxs("button",e.__assign({type:"button",onClick:function(){var e;null==u||u(),null===(e=T.current)||void 0===e||e.close()},className:a.default.trainingTitleLink},{children:[h,n.jsx(t.ExternalLink,{size:16,color:"#2563eb"})]}))}))]}))}))]}))};
|
|
2
2
|
//# sourceMappingURL=CognitiveInternalgptReasoningComponent.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as e}from"tslib";import{jsxs as t,jsx as
|
|
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,u=d.children,c=d.uploadListTopContent,p=d.defaultHeight,h=void 0===p?300:p,f=d.minHeight,x=void 0===f?150:f,m=d.maxHeight,g=d.isExpanded,v=void 0!==g&&g,y=d.onToggle,b=d.onHeightChange,w=d.styles,C=void 0===w?{}:w,H=n(!1),S=H[0],k=H[1],E=n(h),B=E[0],D=E[1],I=i(0),L=i(h),R=i(null),z=i(0),j="string"==typeof m?parseFloat(m)/100*window.innerHeight:null!=m?m:.4*window.innerHeight;r(function(){!v&&R.current&&(z.current=R.current.getBoundingClientRect().height)},[v]);return r(function(){if(S){var e=function(e){e.preventDefault();var t=e.clientY-I.current,o=Math.max(x,Math.min(j,L.current+t));D(o),null==b||b(o)},t=function(){k(!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("div",e({ref:R,style:{position:"relative",width:"100%",minHeight:v?z.current:"auto"}},{children:[t("div",e({style:e({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(B,"px"):"auto",minHeight:v?"".concat(x,"px"):"auto",maxHeight:v?"".concat(B,"px"):"auto",overflow:"hidden",width:"100%"},C.container)},{children:[o("div",e({style:e({display:"flex",alignItems:"center",width:"100%",marginBottom:12,flexShrink:0,padding:"12px 20px 0 20px"},C.header)},{children:o("span",e({style:e({display:"inline-block",maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",fontSize:16,fontWeight:500,lineHeight:"24px",color:"#101828",fontFamily:"Inter, sans-serif"},C.title)},{children:(null==c?void 0:c.trim())?c:"Data uploaded for your context"}))})),v&&o("div",e({style:e({flex:1,overflowY:"auto",overflowX:"hidden",minHeight:0,padding:"0 20px"},C.body)},{children:u})),v&&o("div",e({onMouseDown:function(e){e.preventDefault(),k(!0),I.current=e.clientY,L.current=B,document.body.style.userSelect="none"},style:{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:S?null!==(a=C.dragPillActiveColor)&&void 0!==a?a:"#a78bfa":"#d1d5db"},C.dragPill)})}))]})),o("div",e({style:{position:v?"absolute":"relative",top:v?"".concat(B,"px"):"auto",width:"100%",display:"flex",justifyContent:"center",height:18,zIndex:v?10:"auto"}},{children:o("button",e({onClick:y,"aria-label":v?"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},C.notch)},{children:o(l,{size:14,color:null!==(s=C.notchArrowColor)&&void 0!==s?s:"#6d28d9",style:{transform:v?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.2s ease"}})}))}))]}))};export{d as default};
|
|
2
2
|
//# sourceMappingURL=ChatDrawer.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__rest as r,__assign as a}from"tslib";import{jsx as t}from"react/jsx-runtime";import o,{tooltipClasses as e}from"@mui/material/Tooltip";import{styled as i}from"@mui/material/styles";var n=i(function(e){var i=e.className,n=r(e,["className"]);return t(o,a({},n,{classes:{popper:i}}))})(function(){var r;return(r={})["& .".concat(e.tooltip)]={fontFamily:"Plus Jakarta Sans, sans-serif",backgroundColor:"#555",color:"#fff",fontSize:12,padding:"5px 8px",borderRadius:6,maxWidth:250,textAlign:"center",whiteSpace:"normal",wordBreak:"break-word",lineHeight:1.4},r["& .".concat(e.arrow)]={color:"#555"},r}),l=function(r){var o=r.description,e=r.children;return t(n,a({title:t("span",{children:o})
|
|
1
|
+
import{__rest as r,__assign as a}from"tslib";import{jsx as t}from"react/jsx-runtime";import o,{tooltipClasses as e}from"@mui/material/Tooltip";import{styled as i}from"@mui/material/styles";var n=i(function(e){var i=e.className,n=r(e,["className"]);return t(o,a({},n,{classes:{popper:i},arrow:!0,placement:"top"}))})(function(){var r;return(r={})["& .".concat(e.tooltip)]={fontFamily:"Plus Jakarta Sans, sans-serif",backgroundColor:"#555",color:"#fff",fontSize:12,padding:"5px 8px",borderRadius:6,maxWidth:250,textAlign:"center",whiteSpace:"normal",wordBreak:"break-word",lineHeight:1.4},r["& .".concat(e.arrow)]={color:"#555"},r}),l=function(r){var o=r.description,e=r.children;return t(n,a({title:t("span",{children:o})},{children:t("span",a({style:{display:"inline-block"}},{children:e}))}))};export{l as default};
|
|
2
2
|
//# sourceMappingURL=TooltipComponent.js.map
|
package/dist/features/CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__spreadArray as n,__assign as e}from"tslib";import{jsxs as i,jsx as t}from"react/jsx-runtime";import{useState as a,useRef as c,useMemo as
|
|
1
|
+
import{__spreadArray as n,__assign as e}from"tslib";import{jsxs as i,jsx as t}from"react/jsx-runtime";import{useState as a,useRef as c,useMemo as l,useEffect as r}from"react";import s from"./CognitiveNonWebSearchReasoning.module.css.js";import{ExternalLink as o}from"lucide-react";var d=function(d){var h=d.item,u=d.index,m=d.iconsConfig,v=d.headerTitle,g=void 0===v?"GPT - Gemini 2.5 Flash":v,p=d.previewCallback,f=d.DocumentTitle,N=null==m?void 0:m.ChevronDownIcon,I=null==m?void 0:m.ChevronUpIcon,C=null==m?void 0:m.MaximizeIcon,x=null==m?void 0:m.CloseIcon,b=a(!1),T=b[0],H=b[1],k=a(0),L=k[0],S=k[1],_=c(null),B=c(null),D=c(null),W=c([]),w=c([]),y=l(function(){return h.dataSource?h.dataSource.replace(/\\n/g,"\n").replace(/\n+/g,"\n"):""},[h.dataSource]),z=l(function(){var n=y.split(/(<highlight>[\s\S]*?<\/highlight>)/g)||[],e=n.filter(function(n){return n.startsWith("<highlight>")}).length,i=0;return{parts:n.map(function(n,e){var t=n.startsWith("<highlight>"),a={text:t?n.replace(/<\/?highlight>/g,""):n,isHighlight:t,highlightIndex:t?i:-1,idx:e};return t&&i++,a}),totalHighlights:e}},[y]),A=z.parts,F=z.totalHighlights,j=function(n,e){void 0===e&&(e=!1);var i=e?w.current[n]:W.current[n],t=e?B.current:_.current;i&&t&&i.scrollIntoView({behavior:"smooth",block:"center"})},R=function(n){if(void 0===n&&(n=!1),F){var e=L>0?L-1:F-1;S(e),setTimeout(function(){return j(e,n)},50)}},E=function(n){if(void 0===n&&(n=!1),F){var e=L<F-1?L+1:0;S(e),setTimeout(function(){return j(e,n)},50)}};r(function(){W.current=W.current.slice(0,F),w.current=w.current.slice(0,F)},[F]),r(function(){var n;return T&&F>0&&(S(0),n=setTimeout(function(){return j(0)},50)),function(){n&&clearTimeout(n)}},[T,F]);var G=function(n){return n.split(/(\*\*.*?\*\*|__.*?__)/g).map(function(n,i){return n.startsWith("**")&&n.endsWith("**")||n.startsWith("__")&&n.endsWith("__")?t("strong",e({className:s.boldText},{children:n.slice(2,-2)}),i):n})},M=l(function(){var i=[],t=[];return A.forEach(function(e){var a=e.text,c=e.isHighlight,l=e.highlightIndex;a.split("\n").forEach(function(e,a){a>0&&((t.length>0||i.length>0)&&i.push({segments:n([],t,!0),isListItem:!1,isHeader:!1,indent:"",content:""}),t=[]),e&&t.push({text:e,isHighlight:c,highlightIndex:l})})}),t.length>0&&i.push({segments:n([],t,!0),isListItem:!1,isHeader:!1,indent:"",content:""}),i.map(function(n){var i=n.segments.map(function(n){return n.text}).join(""),t=i.match(/^(\s*)(-|\*|\d+\.)\s+(.*)$/),a=i.match(/^(Title|Description|Training-basis):\s*(.*)$/i);return e(e({},n),{isListItem:!!t,isHeader:!!a,indent:(null==t?void 0:t[1])||"",content:(null==t?void 0:t[3])||i})})},[A]),V=function(n){void 0===n&&(n=!1);var a=0;return M.map(function(c,l){c.isHeader&&(a=0),c.isListItem&&(a+=1);var r=function(){return c.segments.map(function(i,a){var l=i.isHighlight&&i.highlightIndex===L,r=i.text;return c.isListItem&&0===a&&(r=i.text.replace(/^(\s*)(-|\*|\d+\.)\s+/,"")),i.isHighlight?t("span",e({ref:function(e){e&&(n?w.current[i.highlightIndex]=e:W.current[i.highlightIndex]=e)},className:"".concat(s.highlight).concat(l?" ".concat(s.highlightActive):"")},{children:G(r)}),a):t("span",{children:G(r)},a)})};return c.isHeader?t("span",e({className:s.headerLine},{children:r()}),l):c.isListItem?i("span",e({className:s.listItemLine,style:{paddingLeft:c.indent?"1rem":"0"}},{children:[i("span",e({className:s.listCounter},{children:[a,"."]})),t("span",{children:r()})]}),l):t("span",e({className:s.blockLine},{children:r()}),l)})};return i("div",e({className:s.container},{children:[i("div",e({className:s.itemRow},{children:["number"==typeof u&&i("span",e({className:s.indexNumber},{children:[u+1,"."]})),i("div",e({className:s.textContent},{children:[t("span",{children:null==h?void 0:h.text}),(null==h?void 0:h.paraphrase)&&i("button",e({type:"button",onClick:function(){return H(!T)},className:s.paraphraseButton},{children:[i("span",e({className:s.paraphraseText},{children:[t("span",e({className:s.paraphraseStar},{children:"✦"})),h.paraphrase]})),N&&t(N,{className:"".concat(s.chevronIcon).concat(T?" ".concat(s.chevronIconRotated):"")})]}))]}))]})),T&&i("div",e({className:s.expandedContainer},{children:[i("div",e({className:s.expandedHeader},{children:[t("span",e({className:s.headerTitle},{children:g})),i("div",e({className:s.headerActions},{children:[F>1&&i("div",e({className:s.navigationContainer},{children:[I&&t("button",e({onClick:function(){return R(!1)},className:s.navButton},{children:t(I,{className:s.navIcon})})),i("span",e({className:s.navCounter},{children:[L+1,"/",F]})),N&&t("button",e({onClick:function(){return E(!1)},className:s.navButton},{children:t(N,{className:s.navIcon})}))]})),null!=(null==h?void 0:h.confidence_score)&&i("span",e({className:s.confidenceBadge},{children:[t("span",e({className:s.confidenceStar},{children:"✦"})),i("span",e({className:s.confidenceScore},{children:[null==h?void 0:h.confidence_score,"%"]}))]})),C&&t("button",e({onClick:function(){var n;null===(n=D.current)||void 0===n||n.showModal()},className:s.maximizeButton,title:"View fullscreen"},{children:t(C,{className:s.maximizeIcon})}))]}))]})),t("div",e({ref:_,className:s.contentArea},{children:t("div",e({className:s.contentInner},{children:V(!1)}))})),h.trainingDataTitle&&t("div",e({className:s.footer},{children:t("span",e({className:s.trainingTitle},{children:h.trainingDataTitle}))})),f&&t("div",e({className:s.modalFooterSource},{children:i("button",e({type:"button",onClick:function(){null==p||p()},className:s.trainingTitleLink},{children:[f,t(o,{size:16,color:"#2563eb"})]}))}))]})),t("dialog",e({ref:D,className:s.modalDialog,onClick:function(n){var e;n.target===D.current&&(null===(e=D.current)||void 0===e||e.close())}},{children:i("div",e({className:s.modalContainer},{children:[i("div",e({className:s.modalHeader},{children:[t("span",e({className:s.modalHeaderTitle},{children:g})),i("div",e({className:s.modalHeaderActions},{children:[F>1&&i("div",e({className:s.modalNavContainer},{children:[I&&t("button",e({onClick:function(){return R(!0)},className:s.modalNavButton},{children:t(I,{className:s.navIcon})})),i("span",e({className:s.navCounter},{children:[L+1,"/",F]})),N&&t("button",e({onClick:function(){return E(!0)},className:s.modalNavButton},{children:t(N,{className:s.navIcon})}))]})),null!=(null==h?void 0:h.confidence_score)&&i("span",e({className:s.confidenceBadge},{children:[t("span",e({className:s.confidenceStar},{children:"✦"})),i("span",e({className:s.confidenceScore},{children:[null==h?void 0:h.confidence_score,"%"]}))]})),x&&t("button",e({onClick:function(){var n;null===(n=D.current)||void 0===n||n.close()},className:s.closeButton,title:"Close"},{children:t(x,{className:s.closeIcon})}))]}))]})),t("div",e({ref:B,className:s.modalContent},{children:t("div",e({className:s.modalContentInner},{children:V(!0)}))})),h.trainingDataTitle&&t("div",e({className:s.modalFooter},{children:t("span",e({className:s.trainingTitle},{children:h.trainingDataTitle}))})),f&&t("div",e({className:s.modalFooterSource},{children:i("button",e({type:"button",onClick:function(){var n;null==p||p(),null===(n=D.current)||void 0===n||n.close()},className:s.trainingTitleLink},{children:[f,t(o,{size:16,color:"#2563eb"})]}))}))]}))}))]}))};export{d as default};
|
|
2
2
|
//# sourceMappingURL=CognitiveInternalgptReasoningComponent.js.map
|
|
@@ -41,6 +41,8 @@ export interface ChatDrawerProps {
|
|
|
41
41
|
notch?: CSSProperties;
|
|
42
42
|
/** Arrow/chevron color inside the notch. Default: #6d28d9 */
|
|
43
43
|
notchArrowColor?: string;
|
|
44
|
+
/** Drag pill color while actively dragging. Default: #a78bfa */
|
|
45
|
+
dragPillActiveColor?: string;
|
|
44
46
|
};
|
|
45
47
|
}
|
|
46
48
|
//# sourceMappingURL=ChatDrawer.types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChatDrawer.types.d.ts","sourceRoot":"","sources":["../../../../../../src/features/ChatDrawer/types/ChatDrawer.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEjD,MAAM,WAAW,eAAe;IAC9B,mGAAmG;IACnG,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,oEAAoE;IACpE,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,uDAAuD;IACvD,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,uDAAuD;IACvD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,sEAAsE;IACtE,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC5B,4BAA4B;IAC5B,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,sBAAsB;IACtB,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,iEAAiE;IACjE,cAAc,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IAC1C;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;;OAIG;IACH,MAAM,CAAC,EAAE;QACP,oEAAoE;QACpE,SAAS,CAAC,EAAE,aAAa,CAAC;QAC1B,sDAAsD;QACtD,MAAM,CAAC,EAAE,aAAa,CAAC;QACvB,sDAAsD;QACtD,KAAK,CAAC,EAAE,aAAa,CAAC;QACtB,oDAAoD;QACpD,IAAI,CAAC,EAAE,aAAa,CAAC;QACrB,0CAA0C;QAC1C,QAAQ,CAAC,EAAE,aAAa,CAAC;QACzB,qEAAqE;QACrE,KAAK,CAAC,EAAE,aAAa,CAAC;QACtB,6DAA6D;QAC7D,eAAe,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"ChatDrawer.types.d.ts","sourceRoot":"","sources":["../../../../../../src/features/ChatDrawer/types/ChatDrawer.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEjD,MAAM,WAAW,eAAe;IAC9B,mGAAmG;IACnG,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,oEAAoE;IACpE,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,uDAAuD;IACvD,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,uDAAuD;IACvD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,sEAAsE;IACtE,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC5B,4BAA4B;IAC5B,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,sBAAsB;IACtB,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,iEAAiE;IACjE,cAAc,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IAC1C;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;;OAIG;IACH,MAAM,CAAC,EAAE;QACP,oEAAoE;QACpE,SAAS,CAAC,EAAE,aAAa,CAAC;QAC1B,sDAAsD;QACtD,MAAM,CAAC,EAAE,aAAa,CAAC;QACvB,sDAAsD;QACtD,KAAK,CAAC,EAAE,aAAa,CAAC;QACtB,oDAAoD;QACpD,IAAI,CAAC,EAAE,aAAa,CAAC;QACrB,0CAA0C;QAC1C,QAAQ,CAAC,EAAE,aAAa,CAAC;QACzB,qEAAqE;QACrE,KAAK,CAAC,EAAE,aAAa,CAAC;QACtB,6DAA6D;QAC7D,eAAe,CAAC,EAAE,MAAM,CAAC;QACzB,gEAAgE;QAChE,mBAAmB,CAAC,EAAE,MAAM,CAAC;KAC9B,CAAC;CACH"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TooltipComponent.d.ts","sourceRoot":"","sources":["../../../../../../src/features/CodeCitation/_components/TooltipComponent.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"TooltipComponent.d.ts","sourceRoot":"","sources":["../../../../../../src/features/CodeCitation/_components/TooltipComponent.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AA0B1B,UAAU,qBAAqB;IAC7B,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED,QAAA,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,qBAAqB,CAMrD,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CognitiveInternalgptReasoningComponent.d.ts","sourceRoot":"","sources":["../../../../../src/features/CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.tsx"],"names":[],"mappings":";AAKA,MAAM,MAAM,mBAAmB,GAAG;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF,MAAM,MAAM,0BAA0B,GAAG;IACvC,eAAe,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC;IACpC,aAAa,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC;IAClC,YAAY,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC;IACjC,SAAS,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC;CAC/B,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG;IACjC,IAAI,EAAE,mBAAmB,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,0BAA0B,CAAC;IACzC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,eAAe,CAAC,EAAE,MAAM,IAAI,CAAC;IAC7B,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB,CAAC;AAEF,QAAA,MAAM,6BAA6B,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,
|
|
1
|
+
{"version":3,"file":"CognitiveInternalgptReasoningComponent.d.ts","sourceRoot":"","sources":["../../../../../src/features/CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.tsx"],"names":[],"mappings":";AAKA,MAAM,MAAM,mBAAmB,GAAG;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF,MAAM,MAAM,0BAA0B,GAAG;IACvC,eAAe,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC;IACpC,aAAa,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC;IAClC,YAAY,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC;IACjC,SAAS,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC;CAC/B,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG;IACjC,IAAI,EAAE,mBAAmB,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,0BAA0B,CAAC;IACzC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,eAAe,CAAC,EAAE,MAAM,IAAI,CAAC;IAC7B,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB,CAAC;AAEF,QAAA,MAAM,6BAA6B,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CAsdjE,CAAC;AAEF,eAAe,6BAA6B,CAAC"}
|