@e-llm-studio/citation 0.0.175 → 0.0.177
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/SplitterCitations/Splitter.module.css.js +1 -1
- package/dist/cjs/features/SplitterCitations/SplitterCitationsComponent.js +1 -1
- package/dist/features/SplitterCitations/Splitter.module.css.js +1 -1
- package/dist/features/SplitterCitations/SplitterCitationsComponent.js +1 -1
- package/dist/types/src/features/SplitterCitations/SplitterCitationsComponent.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});!function(){if("undefined"==typeof document)return;const e=document.createElement("style");e.type="text/css";const t=window.__CSP_NONCE__||document.querySelector('meta[name="csp-nonce"]')?.content;t&&e.setAttribute("nonce",t),e.appendChild(document.createTextNode(".Splitter-module_container__RzL6s{border:1px solid #e5e7eb;border-radius:8px;display:flex;flex-direction:column;margin:8px;position:relative}.Splitter-module_containerHorizontal__2p-d4{overflow:hidden}.Splitter-module_containerVertical__9n65N{overflow:visible}.Splitter-module_header__TfhkL{align-items:center;background-color:#fff;border-bottom:1px solid #e5e7eb;display:flex;flex-shrink:0;justify-content:space-between;padding:12px 16px}.Splitter-module_headerLeft__85ugE{align-items:center;
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});!function(){if("undefined"==typeof document)return;const e=document.createElement("style");e.type="text/css";const t=window.__CSP_NONCE__||document.querySelector('meta[name="csp-nonce"]')?.content;t&&e.setAttribute("nonce",t),e.appendChild(document.createTextNode(".Splitter-module_container__RzL6s{border:1px solid #e5e7eb;border-radius:8px;display:flex;flex-direction:column;margin:8px;position:relative}.Splitter-module_containerHorizontal__2p-d4{overflow:hidden}.Splitter-module_containerVertical__9n65N{overflow:visible}.Splitter-module_header__TfhkL{align-items:center;background-color:#fff;border-bottom:1px solid #e5e7eb;display:flex;flex-shrink:0;justify-content:space-between;padding:12px 16px}.Splitter-module_headerLeft__85ugE{align-items:center;display:flex;gap:8px}.Splitter-module_headerTitle__TB5BN{display:flex;flex-direction:column;gap:2px}.Splitter-module_headerTitleText__L4F7s{font-size:14px;font-weight:600}.Splitter-module_headerIcon__OHxry{height:16px;width:16px}.Splitter-module_confidenceScore__0k845{align-items:center;border:2px solid #dff6e6;border-radius:16px;display:flex;font-size:13px;gap:4px;padding:4px 8px}.Splitter-module_confidenceScoreHigh__H8j5I{background-color:#f0fdf4;color:#087443}.Splitter-module_confidenceScoreMedium__qiIsl{background-color:#fef3c7;color:#92400e}.Splitter-module_confidenceScoreLow__-lIle{background-color:#fee2e2;color:#991b1b}.Splitter-module_contentArea__ajG2D{display:flex;gap:4px;position:relative}.Splitter-module_contentAreaHorizontal__xu6oA{flex:1;flex-direction:row;overflow:hidden}.Splitter-module_contentAreaVertical__DPFG7{flex:none;flex-direction:column;overflow:visible}.Splitter-module_panel__y11eZ{min-width:0;overflow:auto;position:relative}.Splitter-module_panelVertical__qrsgc{min-height:0}.Splitter-module_expandButton__w3AI-{align-items:center;background-color:#f9fafb;border:none;cursor:pointer;display:flex;flex-shrink:0;justify-content:center;transition:background-color .2s}.Splitter-module_expandButton__w3AI-:hover{background-color:#f3f4f6}.Splitter-module_expandButtonHorizontal__soV3P{border-right:1px solid #e5e7eb;width:28px}.Splitter-module_expandButtonVertical__-2hdL{border-bottom:1px solid #e5e7eb;height:28px;width:100%}.Splitter-module_expandButtonRightHorizontal__kN8SH{border-left:1px solid #e5e7eb;width:28px}.Splitter-module_expandButtonBottomVertical__QUw-u{border-top:1px solid #e5e7eb;height:28px;width:100%}.Splitter-module_divider__iY680{flex-shrink:0;overflow:visible;position:relative;transition:background-color .2s;z-index:10}.Splitter-module_dividerHorizontal__r6rzG{cursor:col-resize;width:4px}.Splitter-module_dividerVertical__J-KxS{cursor:row-resize;height:4px;width:100%}.Splitter-module_dividerDragging__P3fsp{background-color:#06c;transition:none}.Splitter-module_dividerIdle__OML9v{background-color:#e0e0e0}.Splitter-module_dividerHitArea__OkbGH{position:absolute}.Splitter-module_dividerHitAreaHorizontal__JP5DH{cursor:col-resize;height:100%;left:-4px;width:12px}.Splitter-module_dividerHitAreaVertical__S7npZ{cursor:row-resize;height:12px;top:-4px;width:100%}.Splitter-module_collapseButton__2kemB{top:50%}.Splitter-module_collapseButtonRight__vmbg5,.Splitter-module_collapseButton__2kemB{align-items:center;background-color:#fff;border:1px solid #e5e7eb;border-radius:4px;box-shadow:0 1px 3px #0000001a;cursor:pointer;display:flex;height:22px;justify-content:center;left:-9px;padding:0;position:absolute;transform:translateY(-50%);width:22px;z-index:100}.Splitter-module_collapseButtonRight__vmbg5{top:calc(50% + 30px)}.Splitter-module_dragOverlay__iUloH{bottom:0;left:0;position:absolute;right:0;top:0;z-index:9999}.Splitter-module_dragOverlayHorizontal__m9g3w{cursor:col-resize}.Splitter-module_dragOverlayVertical__9Nt5f{cursor:row-resize}.Splitter-module_headerActions__x-Rv8{align-items:center;display:flex;gap:8px}.Splitter-module_fullscreenButton__RmzBi{align-items:center;background:#fff;border:none;border-radius:6px;color:#6b7280;cursor:pointer;display:flex;flex-shrink:0;height:28px;justify-content:center;transition:background-color .15s,color .15s;width:28px}.Splitter-module_fullscreenButton__RmzBi:hover{background-color:#f3f4f6;color:#111827}.Splitter-module_dialogOverlay__mZjqy{background:#0000;border:none;border-radius:10px;box-shadow:0 20px 60px #0003;height:90vh;left:50%;margin:0;max-height:100vh;max-width:100vw;overflow:hidden;padding:0;position:fixed;top:50%;transform:translate(-50%,-50%);width:95vw}.Splitter-module_dialogOverlay__mZjqy::backdrop{background-color:#00000073}.Splitter-module_dialogContent__pmquD{background:#fff;border:1px solid #e5e7eb;border-radius:10px;display:flex;flex-direction:column;height:100%;overflow:hidden;width:100%}.Splitter-module_dialogContentArea__7xPgA{flex:1;min-height:0;overflow:hidden}"));const o=document.head||document.getElementsByTagName("head")[0]||document.documentElement;o&&o.appendChild(e)}(),exports.default={container:"Splitter-module_container__RzL6s",containerHorizontal:"Splitter-module_containerHorizontal__2p-d4",containerVertical:"Splitter-module_containerVertical__9n65N",header:"Splitter-module_header__TfhkL",headerLeft:"Splitter-module_headerLeft__85ugE",headerTitle:"Splitter-module_headerTitle__TB5BN",headerTitleText:"Splitter-module_headerTitleText__L4F7s",headerIcon:"Splitter-module_headerIcon__OHxry",confidenceScore:"Splitter-module_confidenceScore__0k845",confidenceScoreHigh:"Splitter-module_confidenceScoreHigh__H8j5I",confidenceScoreMedium:"Splitter-module_confidenceScoreMedium__qiIsl",confidenceScoreLow:"Splitter-module_confidenceScoreLow__-lIle",contentArea:"Splitter-module_contentArea__ajG2D",contentAreaHorizontal:"Splitter-module_contentAreaHorizontal__xu6oA",contentAreaVertical:"Splitter-module_contentAreaVertical__DPFG7",panel:"Splitter-module_panel__y11eZ",panelVertical:"Splitter-module_panelVertical__qrsgc",expandButton:"Splitter-module_expandButton__w3AI-",expandButtonHorizontal:"Splitter-module_expandButtonHorizontal__soV3P",expandButtonVertical:"Splitter-module_expandButtonVertical__-2hdL",expandButtonRightHorizontal:"Splitter-module_expandButtonRightHorizontal__kN8SH",expandButtonBottomVertical:"Splitter-module_expandButtonBottomVertical__QUw-u",divider:"Splitter-module_divider__iY680",dividerHorizontal:"Splitter-module_dividerHorizontal__r6rzG",dividerVertical:"Splitter-module_dividerVertical__J-KxS",dividerDragging:"Splitter-module_dividerDragging__P3fsp",dividerIdle:"Splitter-module_dividerIdle__OML9v",dividerHitArea:"Splitter-module_dividerHitArea__OkbGH",dividerHitAreaHorizontal:"Splitter-module_dividerHitAreaHorizontal__JP5DH",dividerHitAreaVertical:"Splitter-module_dividerHitAreaVertical__S7npZ",collapseButton:"Splitter-module_collapseButton__2kemB",collapseButtonRight:"Splitter-module_collapseButtonRight__vmbg5",dragOverlay:"Splitter-module_dragOverlay__iUloH",dragOverlayHorizontal:"Splitter-module_dragOverlayHorizontal__m9g3w",dragOverlayVertical:"Splitter-module_dragOverlayVertical__9Nt5f",headerActions:"Splitter-module_headerActions__x-Rv8",fullscreenButton:"Splitter-module_fullscreenButton__RmzBi",dialogOverlay:"Splitter-module_dialogOverlay__mZjqy",dialogContent:"Splitter-module_dialogContent__pmquD",dialogContentArea:"Splitter-module_dialogContentArea__7xPgA"};
|
|
2
2
|
//# sourceMappingURL=Splitter.module.css.js.map
|
|
@@ -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"),a=require("lucide-react"),i=require("./Splitter.module.css.js"),o=function(){return t.jsxs("svg",e.__assign({width:"21",height:"54",viewBox:"0 0 20 54",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:[t.jsx("path",{d:"M0.260742 1.57324L15.4268 10.8262C17.9563 12.3695 19.4999 15.1188 19.5 18.082V37.0273C19.4999 40.16 17.7767 43.0386 15.0156 44.5186L0.236328 52.4404L-0.5 52.835V1.10938L0.260742 1.57324Z",fill:"#F8FAFC",stroke:"#E0E0E0"}),t.jsx("path",{d:"M7.5 32L12.5 27L7.5 22",stroke:"#111827",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})]}))},c=function(){return t.jsxs("svg",e.__assign({width:"21",height:"54",viewBox:"0 0 21 54",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:[t.jsx("path",{d:"M1.26074 1.57324L16.4268 10.8262C18.9563 12.3695 20.4999 15.1188 20.5 18.082V37.0273C20.4999 40.16 18.7767 43.0386 16.0156 44.5186L1.23633 52.4404L0.5 52.835V1.10938L1.26074 1.57324Z",fill:"#F8FAFC",stroke:"#E0E0E0"}),t.jsx("path",{d:"M13.5 32L8.5 27L13.5 22",stroke:"black",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})]}))};exports.default=function(s){var l=s.left,r=s.right,d=s.defaultLeftWidth,u=void 0===d?50:d,f=s.minLeftWidth,h=void 0===f?250:f,v=s.minRightWidth,x=void 0===v?250:v,g=s.className,p=void 0===g?"":g,m=s.height,_=void 0===m?"400px":m,j=s.width,w=void 0===j?"100%":j,L=s.header,N=s.onLeftWidthChange,C=n.useState(u),E=C[0],S=C[1],k=n.useState(u),B=k[0],V=k[1],b=n.useState(!1),M=b[0],H=b[1],z=n.useState(!1),A=z[0],y=z[1],F=n.useState(!1),R=F[0],D=F[1],q=n.useState(0),T=q[0],W=q[1],O=n.useRef(null),P=n.useRef(null);n.useEffect(function(){var e=O.current;if(e){var t,n=new ResizeObserver(function(e){var n=e[0];t=requestAnimationFrame(function(){W(n.contentRect.width)})});return n.observe(e),W(e.getBoundingClientRect().width),function(){cancelAnimationFrame(t),n.disconnect()}}},[]);var I=T>0&&T<500;n.useEffect(function(){var e=function(e){if(M)if(I&&P.current){var t=P.current.getBoundingClientRect(),n=t.height,a=e.clientY-t.top;if(a>=h&&n-a-4>=x)V(a/n*100)}else if(!I&&O.current){var i=O.current.getBoundingClientRect(),o=i.width,c=e.clientX-i.left;if(c>=h&&o-c-4>=x)S(c/o*100),null==N||N(c)}},t=function(){H(!1)};return M&&(document.addEventListener("mousemove",e),document.addEventListener("mouseup",t)),function(){document.removeEventListener("mousemove",e),document.removeEventListener("mouseup",t)}},[M,I,h,x,N]);var Z,U=function(){A?(S(50),V(50),y(!1)):y(!0)},X=function(){R?(S(50),V(50),D(!1)):D(!0)},Y=E/100*T,G=T-Y-4;Z=I?R?{flex:1}:{height:"".concat(B,"%")}:R?{flex:1}:{width:"".concat(E,"%")};var J,K=!I&&!A&&Y<=Math.max(h+10,250),Q=!I&&!R&&G<=Math.max(x+10,250),$="number"==typeof _?"".concat(_,"px"):_,ee="number"==typeof w?"".concat(w,"px"):w;return t.jsxs("div",e.__assign({ref:O,className:"".concat(i.default.container," ").concat(I?i.default.containerVertical:i.default.containerHorizontal," ").concat(p),style:{height:I?"auto":$,width:ee}},{children:[L&&t.jsxs("div",e.__assign({className:i.default.header},{children:[t.jsxs("div",e.__assign({className:i.default.headerLeft},{children:[L.showDocIcon&&t.jsx(a.FileText,{className:i.default.headerIcon}),t.jsx("div",e.__assign({className:i.default.headerTitle},{children:L.title&&t.jsx("span",e.__assign({className:i.default.headerTitleText},{children:L.title}))}))]})),void 0!==L.confidenceScore&&t.jsxs("div",e.__assign({className:"".concat(i.default.confidenceScore," ").concat((J=L.confidenceScore,J>=80?i.default.confidenceScoreHigh:J>=60?i.default.confidenceScoreMedium:i.default.confidenceScoreLow))},{children:[t.jsxs("span",e.__assign({className:i.default.confidenceScoreTitle},{children:[L.confidenceScoreTitle," :"]})),t.jsxs("div",{children:[Math.round(L.confidenceScore),"%"]})]}))]})),t.jsxs("div",e.__assign({ref:P,className:"".concat(i.default.contentArea," ").concat(I?i.default.contentAreaVertical:i.default.contentAreaHorizontal)},{children:[!A&&t.jsx("div",e.__assign({className:"".concat(i.default.panel," ").concat(I?i.default.panelVertical:""),style:e.__assign(e.__assign({},Z),I?{height:$}:{})},{children:l})),A&&t.jsx("button",e.__assign({onClick:U,className:"".concat(i.default.expandButton," ").concat(I?i.default.expandButtonVertical:i.default.expandButtonHorizontal),title:I?"Expand top panel (50/50)":"Expand left panel (50/50)"},{children:I?t.jsx(a.ChevronDown,{size:14}):t.jsx(o,{})})),!A&&!R&&t.jsxs("div",e.__assign({onMouseDown:function(e){e.preventDefault(),H(!0)},className:"".concat(i.default.divider," ").concat(I?i.default.dividerVertical:i.default.dividerHorizontal," ").concat(M?i.default.dividerDragging:i.default.dividerIdle)},{children:[t.jsx("div",{className:"".concat(i.default.dividerHitArea," ").concat(I?i.default.dividerHitAreaVertical:i.default.dividerHitAreaHorizontal)}),K&&t.jsx("button",e.__assign({onClick:function(e){e.stopPropagation(),U()},onMouseDown:function(e){return e.stopPropagation()},className:i.default.collapseButton,title:"Collapse left panel"},{children:t.jsx(c,{})})),Q&&t.jsx("button",e.__assign({onClick:function(e){e.stopPropagation(),X()},onMouseDown:function(e){return e.stopPropagation()},className:i.default.collapseButton,title:"Collapse right panel"},{children:t.jsx(o,{})}))]})),!R&&t.jsx("div",e.__assign({className:"".concat(i.default.panel," ").concat(I?i.default.panelVertical:""),style:e.__assign({flex:1},I?{height:$}:{})},{children:r})),R&&t.jsx("button",e.__assign({onClick:X,className:"".concat(i.default.expandButton," ").concat(I?i.default.expandButtonBottomVertical:i.default.expandButtonRightHorizontal),title:I?"Expand bottom panel (50/50)":"Expand right panel (50/50)"},{children:I?t.jsx(a.ChevronUp,{size:14}):t.jsx(c,{})})),M&&t.jsx("div",{className:"".concat(i.default.dragOverlay," ").concat(I?i.default.dragOverlayVertical:i.default.dragOverlayHorizontal)})]}))]}))};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),t=require("react/jsx-runtime"),n=require("react"),a=require("lucide-react"),i=require("./Splitter.module.css.js"),s=function(){return t.jsxs("svg",e.__assign({width:"21",height:"54",viewBox:"0 0 20 54",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:[t.jsx("path",{d:"M0.260742 1.57324L15.4268 10.8262C17.9563 12.3695 19.4999 15.1188 19.5 18.082V37.0273C19.4999 40.16 17.7767 43.0386 15.0156 44.5186L0.236328 52.4404L-0.5 52.835V1.10938L0.260742 1.57324Z",fill:"#F8FAFC",stroke:"#E0E0E0"}),t.jsx("path",{d:"M7.5 32L12.5 27L7.5 22",stroke:"#111827",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})]}))},l=function(){return t.jsxs("svg",e.__assign({width:"21",height:"54",viewBox:"0 0 21 54",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:[t.jsx("path",{d:"M1.26074 1.57324L16.4268 10.8262C18.9563 12.3695 20.4999 15.1188 20.5 18.082V37.0273C20.4999 40.16 18.7767 43.0386 16.0156 44.5186L1.23633 52.4404L0.5 52.835V1.10938L1.26074 1.57324Z",fill:"#F8FAFC",stroke:"#E0E0E0"}),t.jsx("path",{d:"M13.5 32L8.5 27L13.5 22",stroke:"black",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})]}))},o=function(){return t.jsxs("svg",e.__assign({xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 12 12",fill:"none"},{children:[t.jsx("path",{d:"M7.58186 3.15354C7.51731 2.83771 7.06604 2.83771 7.00148 3.15354C6.60544 5.09119 5.09119 6.60544 3.15355 7.00148C2.83771 7.06603 2.83771 7.5173 3.15355 7.58185C5.09119 7.97789 6.60544 9.49215 7.00148 11.4298C7.06604 11.7456 7.51731 11.7456 7.58186 11.4298C7.9779 9.49215 9.49215 7.97789 11.4298 7.58185C11.7456 7.5173 11.7456 7.06603 11.4298 7.00148C9.49215 6.60544 7.9779 5.09119 7.58186 3.15354Z",fill:"#087443"}),t.jsx("path",{d:"M2.20669 0.0156637C2.20243 -0.00522128 2.17258 -0.0052212 2.16832 0.0156638C1.94676 1.09964 1.09964 1.94676 0.0156679 2.16831C-0.0052166 2.17258 -0.0052166 2.20242 0.0156679 2.20669C1.09964 2.42825 1.94676 3.27536 2.16832 4.35934C2.17258 4.38022 2.20243 4.38022 2.20669 4.35934C2.42825 3.27536 3.27537 2.42824 4.35934 2.20669C4.38023 2.20242 4.38023 2.17258 4.35934 2.16831C3.27537 1.94676 2.42825 1.09964 2.20669 0.0156637Z",fill:"#087443"})]}))},c=function(){return t.jsx("svg",e.__assign({xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 16 16",fill:"none"},{children:t.jsx("path",{d:"M3.125 2.75C3.02554 2.75 2.93016 2.78951 2.85983 2.85983C2.78951 2.93016 2.75 3.02554 2.75 3.125V6.125C2.75 6.22446 2.71049 6.31984 2.64017 6.39016C2.56984 6.46049 2.47446 6.5 2.375 6.5C2.27554 6.5 2.18016 6.46049 2.10983 6.39016C2.03951 6.31984 2 6.22446 2 6.125V3.125C2 2.82663 2.11853 2.54048 2.3295 2.3295C2.54048 2.11853 2.82663 2 3.125 2H6.125C6.22446 2 6.31984 2.03951 6.39016 2.10983C6.46049 2.18016 6.5 2.27554 6.5 2.375C6.5 2.47446 6.46049 2.56984 6.39016 2.64017C6.31984 2.71049 6.22446 2.75 6.125 2.75H3.125ZM9.5 2.375C9.5 2.27554 9.53951 2.18016 9.60983 2.10983C9.68016 2.03951 9.77554 2 9.875 2H12.875C13.1734 2 13.4595 2.11853 13.6705 2.3295C13.8815 2.54048 14 2.82663 14 3.125V6.125C14 6.22446 13.9605 6.31984 13.8902 6.39016C13.8198 6.46049 13.7245 6.5 13.625 6.5C13.5255 6.5 13.4302 6.46049 13.3598 6.39016C13.2895 6.31984 13.25 6.22446 13.25 6.125V3.125C13.25 3.02554 13.2105 2.93016 13.1402 2.85983C13.0698 2.78951 12.9745 2.75 12.875 2.75H9.875C9.77554 2.75 9.68016 2.71049 9.60983 2.64017C9.53951 2.56984 9.5 2.47446 9.5 2.375ZM2.375 9.5C2.47446 9.5 2.56984 9.53951 2.64017 9.60983C2.71049 9.68016 2.75 9.77554 2.75 9.875V12.875C2.75 12.9745 2.78951 13.0698 2.85983 13.1402C2.93016 13.2105 3.02554 13.25 3.125 13.25H6.125C6.22446 13.25 6.31984 13.2895 6.39016 13.3598C6.46049 13.4302 6.5 13.5255 6.5 13.625C6.5 13.7245 6.46049 13.8198 6.39016 13.8902C6.31984 13.9605 6.22446 14 6.125 14H3.125C2.82663 14 2.54048 13.8815 2.3295 13.6705C2.11853 13.4595 2 13.1734 2 12.875V9.875C2 9.77554 2.03951 9.68016 2.10983 9.60983C2.18016 9.53951 2.27554 9.5 2.375 9.5ZM13.625 9.5C13.7245 9.5 13.8198 9.53951 13.8902 9.60983C13.9605 9.68016 14 9.77554 14 9.875V12.875C14 13.1734 13.8815 13.4595 13.6705 13.6705C13.4595 13.8815 13.1734 14 12.875 14H9.875C9.77554 14 9.68016 13.9605 9.60983 13.8902C9.53951 13.8198 9.5 13.7245 9.5 13.625C9.5 13.5255 9.53951 13.4302 9.60983 13.3598C9.68016 13.2895 9.77554 13.25 9.875 13.25H12.875C12.9745 13.25 13.0698 13.2105 13.1402 13.1402C13.2105 13.0698 13.25 12.9745 13.25 12.875V9.875C13.25 9.77554 13.2895 9.68016 13.3598 9.60983C13.4302 9.53951 13.5255 9.5 13.625 9.5Z",fill:"#7A5AF8",stroke:"#7A5AF8","stroke-width":"0.5"})}))};exports.default=function(r){var d=r.left,u=r.right,f=r.defaultLeftWidth,h=void 0===f?50:f,x=r.minLeftWidth,g=void 0===x?250:x,v=r.minRightWidth,C=void 0===v?250:v,p=r.className,_=void 0===p?"":p,m=r.height,j=void 0===m?"400px":m,w=r.width,N=void 0===w?"100%":w,H=r.header,L=r.onLeftWidthChange,B=n.useState(h),A=B[0],M=B[1],k=n.useState(h),V=k[0],b=k[1],E=n.useState(!1),S=E[0],z=E[1],F=n.useState(!1),y=F[0],R=F[1],D=n.useState(!1),O=D[0],P=D[1],q=n.useState(0),T=q[0],Z=q[1],I=n.useState(0),W=I[0],X=I[1],U=n.useState(!1),Y=U[0],G=U[1],J=n.useRef(null),K=n.useRef(null),Q=n.useRef(null),$=n.useRef(null);n.useEffect(function(){var e=J.current;e&&(Y?(e.showModal(),requestAnimationFrame(function(){if($.current){var e=$.current.getBoundingClientRect().width;if(X(e),e>0){var t=Math.min(800/e*100,75);M(t)}}})):e.close())},[Y]),n.useEffect(function(){var e=$.current;if(e&&Y){var t,n=new ResizeObserver(function(e){var n=e[0];t=requestAnimationFrame(function(){X(n.contentRect.width)})});return n.observe(e),function(){cancelAnimationFrame(t),n.disconnect()}}},[Y]),n.useEffect(function(){var e=K.current;if(e){var t,n=new ResizeObserver(function(e){var n=e[0];t=requestAnimationFrame(function(){Z(n.contentRect.width)})});return n.observe(e),Z(e.getBoundingClientRect().width),function(){cancelAnimationFrame(t),n.disconnect()}}},[]);var ee=T>0&&T<500,te=function(e){e.preventDefault(),z(!0)};n.useEffect(function(){var e=function(e){if(S)if(ee&&Q.current){var t=Q.current.getBoundingClientRect(),n=t.height,a=e.clientY-t.top;if(a>=g&&n-a-4>=C)b(a/n*100)}else if(!ee){var i=Y?$.current:K.current;if(!i)return;var s=i.getBoundingClientRect(),l=s.width,o=e.clientX-s.left;if(o>=g&&l-o-4>=C)M(o/l*100),null==L||L(o)}},t=function(){z(!1)};return S&&(document.addEventListener("mousemove",e),document.addEventListener("mouseup",t)),function(){document.removeEventListener("mousemove",e),document.removeEventListener("mouseup",t)}},[S,ee,Y,g,C,L]);var ne,ae=function(){y?(M(50),b(50),R(!1)):R(!0)},ie=function(){O?(M(50),b(50),P(!1)):P(!0)},se=Y?W:T,le=A/100*se,oe=se-le-4,ce=Y?500:250;ne=ee?O?{flex:1}:{height:"".concat(V,"%")}:O?{flex:1}:{width:"".concat(A,"%")};var re,de=!ee&&!y&&le<=Math.max(g+10,ce),ue=!ee&&!O&&oe<=Math.max(C+10,ce),fe=function(e){return e>=80?i.default.confidenceScoreHigh:e>=60?i.default.confidenceScoreMedium:i.default.confidenceScoreLow},he="number"==typeof j?"".concat(j,"px"):j,xe="number"==typeof N?"".concat(N,"px"):N;return t.jsxs(t.Fragment,{children:[t.jsxs("div",e.__assign({ref:K,className:"".concat(i.default.container," ").concat(ee?i.default.containerVertical:i.default.containerHorizontal," ").concat(_),style:{height:ee?"auto":he,width:xe}},{children:[H&&t.jsxs("div",e.__assign({className:i.default.header},{children:[t.jsxs("div",e.__assign({className:i.default.headerLeft},{children:[H.showDocIcon&&t.jsx(a.FileText,{className:i.default.headerIcon}),t.jsx("div",e.__assign({className:i.default.headerTitle},{children:H.title&&t.jsx("span",e.__assign({className:i.default.headerTitleText},{children:H.title}))}))]})),t.jsxs("div",e.__assign({className:i.default.headerActions},{children:[void 0!==H.confidenceScore&&t.jsxs("div",e.__assign({className:"".concat(i.default.confidenceScore," ").concat(fe(H.confidenceScore))},{children:[t.jsx("div",e.__assign({style:{width:"16px",height:"16px"}},{children:t.jsx(o,{})})),t.jsxs("div",{children:[Math.round(H.confidenceScore),"%"]})]})),t.jsx("button",e.__assign({className:i.default.fullscreenButton,onClick:function(){return G(!0)},title:"Open fullscreen"},{children:t.jsx(c,{})}))]}))]})),(re=!1,t.jsxs("div",e.__assign({ref:re?void 0:Q,className:"".concat(i.default.contentArea," ").concat(ee?i.default.contentAreaVertical:i.default.contentAreaHorizontal)},{children:[!y&&t.jsx("div",e.__assign({className:"".concat(i.default.panel," ").concat(ee?i.default.panelVertical:""),style:e.__assign(e.__assign({},ne),ee?{height:he}:{})},{children:d})),y&&t.jsx("button",e.__assign({onClick:ae,className:"".concat(i.default.expandButton," ").concat(ee?i.default.expandButtonVertical:i.default.expandButtonHorizontal),title:ee?"Expand top panel (50/50)":"Expand left panel (50/50)"},{children:ee?t.jsx(a.ChevronDown,{size:14}):t.jsx(s,{})})),!y&&!O&&t.jsxs("div",e.__assign({onMouseDown:te,className:"".concat(i.default.divider," ").concat(ee?i.default.dividerVertical:i.default.dividerHorizontal," ").concat(S?i.default.dividerDragging:i.default.dividerIdle)},{children:[t.jsx("div",{className:"".concat(i.default.dividerHitArea," ").concat(ee?i.default.dividerHitAreaVertical:i.default.dividerHitAreaHorizontal)}),de&&t.jsx("button",e.__assign({onClick:function(e){e.stopPropagation(),ae()},onMouseDown:function(e){return e.stopPropagation()},className:i.default.collapseButton,title:"Collapse left panel"},{children:t.jsx(l,{})})),ue&&t.jsx("button",e.__assign({onClick:function(e){e.stopPropagation(),ie()},onMouseDown:function(e){return e.stopPropagation()},className:i.default.collapseButton,title:"Collapse right panel"},{children:t.jsx(s,{})}))]})),!O&&t.jsx("div",e.__assign({className:"".concat(i.default.panel," ").concat(ee?i.default.panelVertical:""),style:e.__assign({flex:1},ee?{height:he}:{})},{children:u})),O&&t.jsx("button",e.__assign({onClick:ie,className:"".concat(i.default.expandButton," ").concat(ee?i.default.expandButtonBottomVertical:i.default.expandButtonRightHorizontal),title:ee?"Expand bottom panel (50/50)":"Expand right panel (50/50)"},{children:ee?t.jsx(a.ChevronUp,{size:14}):t.jsx(l,{})})),S&&t.jsx("div",{className:"".concat(i.default.dragOverlay," ").concat(ee?i.default.dragOverlayVertical:i.default.dragOverlayHorizontal)})]})))]})),t.jsx("dialog",e.__assign({ref:J,className:i.default.dialogOverlay,onClose:function(){return G(!1)}},{children:t.jsxs("div",e.__assign({ref:$,className:i.default.dialogContent},{children:[H&&t.jsxs("div",e.__assign({className:i.default.header},{children:[t.jsxs("div",e.__assign({className:i.default.headerLeft},{children:[H.showDocIcon&&t.jsx(a.FileText,{className:i.default.headerIcon}),t.jsx("div",e.__assign({className:i.default.headerTitle},{children:H.title&&t.jsx(t.Fragment,{children:t.jsx("span",e.__assign({className:i.default.headerTitleText},{children:H.title}))})}))]})),t.jsxs("div",e.__assign({className:i.default.headerActions},{children:[void 0!==H.confidenceScore&&t.jsxs("div",e.__assign({className:"".concat(i.default.confidenceScore," ").concat(fe(H.confidenceScore))},{children:[t.jsx("div",e.__assign({style:{width:"16px",height:"16px"}},{children:t.jsx(o,{})})),t.jsxs("div",{children:[Math.round(H.confidenceScore),"%"]})]})),t.jsx("button",e.__assign({className:i.default.fullscreenButton,onClick:function(){return G(!1)},title:"Close fullscreen"},{children:t.jsx(a.X,{size:20,color:"#5928ed"})}))]}))]})),t.jsxs("div",e.__assign({className:"".concat(i.default.contentArea," ").concat(i.default.contentAreaHorizontal," ").concat(i.default.dialogContentArea)},{children:[!y&&t.jsx("div",e.__assign({className:i.default.panel,style:ne},{children:d})),y&&t.jsx("button",e.__assign({onClick:ae,className:"".concat(i.default.expandButton," ").concat(i.default.expandButtonHorizontal),title:"Expand left panel (50/50)"},{children:t.jsx(s,{})})),!y&&!O&&t.jsxs("div",e.__assign({onMouseDown:te,className:"".concat(i.default.divider," ").concat(i.default.dividerHorizontal," ").concat(S?i.default.dividerDragging:i.default.dividerIdle)},{children:[t.jsx("div",{className:"".concat(i.default.dividerHitArea," ").concat(i.default.dividerHitAreaHorizontal)}),de&&t.jsx("button",e.__assign({onClick:function(e){e.stopPropagation(),ae()},onMouseDown:function(e){return e.stopPropagation()},className:i.default.collapseButton,title:"Collapse left panel"},{children:t.jsx(l,{})})),ue&&t.jsx("button",e.__assign({onClick:function(e){e.stopPropagation(),ie()},onMouseDown:function(e){return e.stopPropagation()},className:i.default.collapseButton,title:"Collapse right panel"},{children:t.jsx(s,{})}))]})),!O&&t.jsx("div",e.__assign({className:i.default.panel,style:{flex:1}},{children:u})),O&&t.jsx("button",e.__assign({onClick:ie,className:"".concat(i.default.expandButton," ").concat(i.default.expandButtonRightHorizontal),title:"Expand right panel (50/50)"},{children:t.jsx(l,{})})),S&&t.jsx("div",{className:"".concat(i.default.dragOverlay," ").concat(i.default.dragOverlayHorizontal)})]}))]}))}))]})};
|
|
2
2
|
//# sourceMappingURL=SplitterCitationsComponent.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
var e={container:"Splitter-module_container__RzL6s",containerHorizontal:"Splitter-module_containerHorizontal__2p-d4",containerVertical:"Splitter-module_containerVertical__9n65N",header:"Splitter-module_header__TfhkL",headerLeft:"Splitter-module_headerLeft__85ugE",headerTitle:"Splitter-module_headerTitle__TB5BN",headerTitleText:"Splitter-module_headerTitleText__L4F7s",headerIcon:"Splitter-module_headerIcon__OHxry",confidenceScore:"Splitter-module_confidenceScore__0k845",confidenceScoreHigh:"Splitter-module_confidenceScoreHigh__H8j5I",confidenceScoreMedium:"Splitter-module_confidenceScoreMedium__qiIsl",confidenceScoreLow:"Splitter-module_confidenceScoreLow__-lIle",
|
|
1
|
+
var e={container:"Splitter-module_container__RzL6s",containerHorizontal:"Splitter-module_containerHorizontal__2p-d4",containerVertical:"Splitter-module_containerVertical__9n65N",header:"Splitter-module_header__TfhkL",headerLeft:"Splitter-module_headerLeft__85ugE",headerTitle:"Splitter-module_headerTitle__TB5BN",headerTitleText:"Splitter-module_headerTitleText__L4F7s",headerIcon:"Splitter-module_headerIcon__OHxry",confidenceScore:"Splitter-module_confidenceScore__0k845",confidenceScoreHigh:"Splitter-module_confidenceScoreHigh__H8j5I",confidenceScoreMedium:"Splitter-module_confidenceScoreMedium__qiIsl",confidenceScoreLow:"Splitter-module_confidenceScoreLow__-lIle",contentArea:"Splitter-module_contentArea__ajG2D",contentAreaHorizontal:"Splitter-module_contentAreaHorizontal__xu6oA",contentAreaVertical:"Splitter-module_contentAreaVertical__DPFG7",panel:"Splitter-module_panel__y11eZ",panelVertical:"Splitter-module_panelVertical__qrsgc",expandButton:"Splitter-module_expandButton__w3AI-",expandButtonHorizontal:"Splitter-module_expandButtonHorizontal__soV3P",expandButtonVertical:"Splitter-module_expandButtonVertical__-2hdL",expandButtonRightHorizontal:"Splitter-module_expandButtonRightHorizontal__kN8SH",expandButtonBottomVertical:"Splitter-module_expandButtonBottomVertical__QUw-u",divider:"Splitter-module_divider__iY680",dividerHorizontal:"Splitter-module_dividerHorizontal__r6rzG",dividerVertical:"Splitter-module_dividerVertical__J-KxS",dividerDragging:"Splitter-module_dividerDragging__P3fsp",dividerIdle:"Splitter-module_dividerIdle__OML9v",dividerHitArea:"Splitter-module_dividerHitArea__OkbGH",dividerHitAreaHorizontal:"Splitter-module_dividerHitAreaHorizontal__JP5DH",dividerHitAreaVertical:"Splitter-module_dividerHitAreaVertical__S7npZ",collapseButton:"Splitter-module_collapseButton__2kemB",collapseButtonRight:"Splitter-module_collapseButtonRight__vmbg5",dragOverlay:"Splitter-module_dragOverlay__iUloH",dragOverlayHorizontal:"Splitter-module_dragOverlayHorizontal__m9g3w",dragOverlayVertical:"Splitter-module_dragOverlayVertical__9Nt5f",headerActions:"Splitter-module_headerActions__x-Rv8",fullscreenButton:"Splitter-module_fullscreenButton__RmzBi",dialogOverlay:"Splitter-module_dialogOverlay__mZjqy",dialogContent:"Splitter-module_dialogContent__pmquD",dialogContentArea:"Splitter-module_dialogContentArea__7xPgA"};!function(){if("undefined"==typeof document)return;const e=document.createElement("style");e.type="text/css";const t=window.__CSP_NONCE__||document.querySelector('meta[name="csp-nonce"]')?.content;t&&e.setAttribute("nonce",t),e.appendChild(document.createTextNode(".Splitter-module_container__RzL6s{border:1px solid #e5e7eb;border-radius:8px;display:flex;flex-direction:column;margin:8px;position:relative}.Splitter-module_containerHorizontal__2p-d4{overflow:hidden}.Splitter-module_containerVertical__9n65N{overflow:visible}.Splitter-module_header__TfhkL{align-items:center;background-color:#fff;border-bottom:1px solid #e5e7eb;display:flex;flex-shrink:0;justify-content:space-between;padding:12px 16px}.Splitter-module_headerLeft__85ugE{align-items:center;display:flex;gap:8px}.Splitter-module_headerTitle__TB5BN{display:flex;flex-direction:column;gap:2px}.Splitter-module_headerTitleText__L4F7s{font-size:14px;font-weight:600}.Splitter-module_headerIcon__OHxry{height:16px;width:16px}.Splitter-module_confidenceScore__0k845{align-items:center;border:2px solid #dff6e6;border-radius:16px;display:flex;font-size:13px;gap:4px;padding:4px 8px}.Splitter-module_confidenceScoreHigh__H8j5I{background-color:#f0fdf4;color:#087443}.Splitter-module_confidenceScoreMedium__qiIsl{background-color:#fef3c7;color:#92400e}.Splitter-module_confidenceScoreLow__-lIle{background-color:#fee2e2;color:#991b1b}.Splitter-module_contentArea__ajG2D{display:flex;gap:4px;position:relative}.Splitter-module_contentAreaHorizontal__xu6oA{flex:1;flex-direction:row;overflow:hidden}.Splitter-module_contentAreaVertical__DPFG7{flex:none;flex-direction:column;overflow:visible}.Splitter-module_panel__y11eZ{min-width:0;overflow:auto;position:relative}.Splitter-module_panelVertical__qrsgc{min-height:0}.Splitter-module_expandButton__w3AI-{align-items:center;background-color:#f9fafb;border:none;cursor:pointer;display:flex;flex-shrink:0;justify-content:center;transition:background-color .2s}.Splitter-module_expandButton__w3AI-:hover{background-color:#f3f4f6}.Splitter-module_expandButtonHorizontal__soV3P{border-right:1px solid #e5e7eb;width:28px}.Splitter-module_expandButtonVertical__-2hdL{border-bottom:1px solid #e5e7eb;height:28px;width:100%}.Splitter-module_expandButtonRightHorizontal__kN8SH{border-left:1px solid #e5e7eb;width:28px}.Splitter-module_expandButtonBottomVertical__QUw-u{border-top:1px solid #e5e7eb;height:28px;width:100%}.Splitter-module_divider__iY680{flex-shrink:0;overflow:visible;position:relative;transition:background-color .2s;z-index:10}.Splitter-module_dividerHorizontal__r6rzG{cursor:col-resize;width:4px}.Splitter-module_dividerVertical__J-KxS{cursor:row-resize;height:4px;width:100%}.Splitter-module_dividerDragging__P3fsp{background-color:#06c;transition:none}.Splitter-module_dividerIdle__OML9v{background-color:#e0e0e0}.Splitter-module_dividerHitArea__OkbGH{position:absolute}.Splitter-module_dividerHitAreaHorizontal__JP5DH{cursor:col-resize;height:100%;left:-4px;width:12px}.Splitter-module_dividerHitAreaVertical__S7npZ{cursor:row-resize;height:12px;top:-4px;width:100%}.Splitter-module_collapseButton__2kemB{top:50%}.Splitter-module_collapseButtonRight__vmbg5,.Splitter-module_collapseButton__2kemB{align-items:center;background-color:#fff;border:1px solid #e5e7eb;border-radius:4px;box-shadow:0 1px 3px #0000001a;cursor:pointer;display:flex;height:22px;justify-content:center;left:-9px;padding:0;position:absolute;transform:translateY(-50%);width:22px;z-index:100}.Splitter-module_collapseButtonRight__vmbg5{top:calc(50% + 30px)}.Splitter-module_dragOverlay__iUloH{bottom:0;left:0;position:absolute;right:0;top:0;z-index:9999}.Splitter-module_dragOverlayHorizontal__m9g3w{cursor:col-resize}.Splitter-module_dragOverlayVertical__9Nt5f{cursor:row-resize}.Splitter-module_headerActions__x-Rv8{align-items:center;display:flex;gap:8px}.Splitter-module_fullscreenButton__RmzBi{align-items:center;background:#fff;border:none;border-radius:6px;color:#6b7280;cursor:pointer;display:flex;flex-shrink:0;height:28px;justify-content:center;transition:background-color .15s,color .15s;width:28px}.Splitter-module_fullscreenButton__RmzBi:hover{background-color:#f3f4f6;color:#111827}.Splitter-module_dialogOverlay__mZjqy{background:#0000;border:none;border-radius:10px;box-shadow:0 20px 60px #0003;height:90vh;left:50%;margin:0;max-height:100vh;max-width:100vw;overflow:hidden;padding:0;position:fixed;top:50%;transform:translate(-50%,-50%);width:95vw}.Splitter-module_dialogOverlay__mZjqy::backdrop{background-color:#00000073}.Splitter-module_dialogContent__pmquD{background:#fff;border:1px solid #e5e7eb;border-radius:10px;display:flex;flex-direction:column;height:100%;overflow:hidden;width:100%}.Splitter-module_dialogContentArea__7xPgA{flex:1;min-height:0;overflow:hidden}"));const o=document.head||document.getElementsByTagName("head")[0]||document.documentElement;o&&o.appendChild(e)}();export{e as default};
|
|
2
2
|
//# sourceMappingURL=Splitter.module.css.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as e}from"tslib";import{jsxs as t,jsx as n}from"react/jsx-runtime";import{useState as o,useRef as i,useEffect as c}from"react";import{FileText as a,ChevronDown as r,ChevronUp as l}from"lucide-react";import d from"./Splitter.module.css.js";var s=function(){return t("svg",e({width:"21",height:"54",viewBox:"0 0 20 54",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:[n("path",{d:"M0.260742 1.57324L15.4268 10.8262C17.9563 12.3695 19.4999 15.1188 19.5 18.082V37.0273C19.4999 40.16 17.7767 43.0386 15.0156 44.5186L0.236328 52.4404L-0.5 52.835V1.10938L0.260742 1.57324Z",fill:"#F8FAFC",stroke:"#E0E0E0"}),n("path",{d:"M7.5 32L12.5 27L7.5 22",stroke:"#111827",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})]}))},u=function(){return t("svg",e({width:"21",height:"54",viewBox:"0 0 21 54",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:[n("path",{d:"M1.26074 1.57324L16.4268 10.8262C18.9563 12.3695 20.4999 15.1188 20.5 18.082V37.0273C20.4999 40.16 18.7767 43.0386 16.0156 44.5186L1.23633 52.4404L0.5 52.835V1.10938L1.26074 1.57324Z",fill:"#F8FAFC",stroke:"#E0E0E0"}),n("path",{d:"M13.5 32L8.5 27L13.5 22",stroke:"black",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})]}))},h=function(h){var f=h.left,p=h.right,m=h.defaultLeftWidth,v=void 0===m?50:m,g=h.minLeftWidth,x=void 0===g?250:g,L=h.minRightWidth,w=void 0===L?250:L,N=h.className,C=void 0===N?"":N,k=h.height,B=void 0===k?"400px":k,E=h.width,V=void 0===E?"100%":E,b=h.header,H=h.onLeftWidthChange,M=o(v),z=M[0],A=M[1],S=o(v),y=S[0],F=S[1],R=o(!1),D=R[0],W=R[1],T=o(!1),j=T[0],O=T[1],P=o(!1),I=P[0],Z=P[1],q=o(0),X=q[0],Y=q[1],G=i(null),J=i(null);c(function(){var e=G.current;if(e){var t,n=new ResizeObserver(function(e){var n=e[0];t=requestAnimationFrame(function(){Y(n.contentRect.width)})});return n.observe(e),Y(e.getBoundingClientRect().width),function(){cancelAnimationFrame(t),n.disconnect()}}},[]);var K=X>0&&X<500;c(function(){var e=function(e){if(D)if(K&&J.current){var t=J.current.getBoundingClientRect(),n=t.height,o=e.clientY-t.top;if(o>=x&&n-o-4>=w)F(o/n*100)}else if(!K&&G.current){var i=G.current.getBoundingClientRect(),c=i.width,a=e.clientX-i.left;if(a>=x&&c-a-4>=w)A(a/c*100),null==H||H(a)}},t=function(){W(!1)};return D&&(document.addEventListener("mousemove",e),document.addEventListener("mouseup",t)),function(){document.removeEventListener("mousemove",e),document.removeEventListener("mouseup",t)}},[D,K,x,w,H]);var Q,U=function(){j?(A(50),F(50),O(!1)):O(!0)},$=function(){I?(A(50),F(50),Z(!1)):Z(!0)},_=z/100*X,ee=X-_-4;Q=K?I?{flex:1}:{height:"".concat(y,"%")}:I?{flex:1}:{width:"".concat(z,"%")};var te,ne=!K&&!j&&_<=Math.max(x+10,250),oe=!K&&!I&&ee<=Math.max(w+10,250),ie="number"==typeof B?"".concat(B,"px"):B,ce="number"==typeof V?"".concat(V,"px"):V;return t("div",e({ref:G,className:"".concat(d.container," ").concat(K?d.containerVertical:d.containerHorizontal," ").concat(C),style:{height:K?"auto":ie,width:ce}},{children:[b&&t("div",e({className:d.header},{children:[t("div",e({className:d.headerLeft},{children:[b.showDocIcon&&n(a,{className:d.headerIcon}),n("div",e({className:d.headerTitle},{children:b.title&&n("span",e({className:d.headerTitleText},{children:b.title}))}))]})),void 0!==b.confidenceScore&&t("div",e({className:"".concat(d.confidenceScore," ").concat((te=b.confidenceScore,te>=80?d.confidenceScoreHigh:te>=60?d.confidenceScoreMedium:d.confidenceScoreLow))},{children:[t("span",e({className:d.confidenceScoreTitle},{children:[b.confidenceScoreTitle," :"]})),t("div",{children:[Math.round(b.confidenceScore),"%"]})]}))]})),t("div",e({ref:J,className:"".concat(d.contentArea," ").concat(K?d.contentAreaVertical:d.contentAreaHorizontal)},{children:[!j&&n("div",e({className:"".concat(d.panel," ").concat(K?d.panelVertical:""),style:e(e({},Q),K?{height:ie}:{})},{children:f})),j&&n("button",e({onClick:U,className:"".concat(d.expandButton," ").concat(K?d.expandButtonVertical:d.expandButtonHorizontal),title:K?"Expand top panel (50/50)":"Expand left panel (50/50)"},{children:K?n(r,{size:14}):n(s,{})})),!j&&!I&&t("div",e({onMouseDown:function(e){e.preventDefault(),W(!0)},className:"".concat(d.divider," ").concat(K?d.dividerVertical:d.dividerHorizontal," ").concat(D?d.dividerDragging:d.dividerIdle)},{children:[n("div",{className:"".concat(d.dividerHitArea," ").concat(K?d.dividerHitAreaVertical:d.dividerHitAreaHorizontal)}),ne&&n("button",e({onClick:function(e){e.stopPropagation(),U()},onMouseDown:function(e){return e.stopPropagation()},className:d.collapseButton,title:"Collapse left panel"},{children:n(u,{})})),oe&&n("button",e({onClick:function(e){e.stopPropagation(),$()},onMouseDown:function(e){return e.stopPropagation()},className:d.collapseButton,title:"Collapse right panel"},{children:n(s,{})}))]})),!I&&n("div",e({className:"".concat(d.panel," ").concat(K?d.panelVertical:""),style:e({flex:1},K?{height:ie}:{})},{children:p})),I&&n("button",e({onClick:$,className:"".concat(d.expandButton," ").concat(K?d.expandButtonBottomVertical:d.expandButtonRightHorizontal),title:K?"Expand bottom panel (50/50)":"Expand right panel (50/50)"},{children:K?n(l,{size:14}):n(u,{})})),D&&n("div",{className:"".concat(d.dragOverlay," ").concat(K?d.dragOverlayVertical:d.dragOverlayHorizontal)})]}))]}))};export{h as default};
|
|
1
|
+
import{__assign as e}from"tslib";import{jsxs as n,Fragment as t,jsx as i}from"react/jsx-runtime";import{useState as o,useRef as c,useEffect as a}from"react";import{FileText as r,X as l,ChevronDown as d,ChevronUp as s}from"lucide-react";import u from"./Splitter.module.css.js";var h=function(){return n("svg",e({width:"21",height:"54",viewBox:"0 0 20 54",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:[i("path",{d:"M0.260742 1.57324L15.4268 10.8262C17.9563 12.3695 19.4999 15.1188 19.5 18.082V37.0273C19.4999 40.16 17.7767 43.0386 15.0156 44.5186L0.236328 52.4404L-0.5 52.835V1.10938L0.260742 1.57324Z",fill:"#F8FAFC",stroke:"#E0E0E0"}),i("path",{d:"M7.5 32L12.5 27L7.5 22",stroke:"#111827",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})]}))},v=function(){return n("svg",e({width:"21",height:"54",viewBox:"0 0 21 54",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:[i("path",{d:"M1.26074 1.57324L16.4268 10.8262C18.9563 12.3695 20.4999 15.1188 20.5 18.082V37.0273C20.4999 40.16 18.7767 43.0386 16.0156 44.5186L1.23633 52.4404L0.5 52.835V1.10938L1.26074 1.57324Z",fill:"#F8FAFC",stroke:"#E0E0E0"}),i("path",{d:"M13.5 32L8.5 27L13.5 22",stroke:"black",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})]}))},f=function(){return n("svg",e({xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 12 12",fill:"none"},{children:[i("path",{d:"M7.58186 3.15354C7.51731 2.83771 7.06604 2.83771 7.00148 3.15354C6.60544 5.09119 5.09119 6.60544 3.15355 7.00148C2.83771 7.06603 2.83771 7.5173 3.15355 7.58185C5.09119 7.97789 6.60544 9.49215 7.00148 11.4298C7.06604 11.7456 7.51731 11.7456 7.58186 11.4298C7.9779 9.49215 9.49215 7.97789 11.4298 7.58185C11.7456 7.5173 11.7456 7.06603 11.4298 7.00148C9.49215 6.60544 7.9779 5.09119 7.58186 3.15354Z",fill:"#087443"}),i("path",{d:"M2.20669 0.0156637C2.20243 -0.00522128 2.17258 -0.0052212 2.16832 0.0156638C1.94676 1.09964 1.09964 1.94676 0.0156679 2.16831C-0.0052166 2.17258 -0.0052166 2.20242 0.0156679 2.20669C1.09964 2.42825 1.94676 3.27536 2.16832 4.35934C2.17258 4.38022 2.20243 4.38022 2.20669 4.35934C2.42825 3.27536 3.27537 2.42824 4.35934 2.20669C4.38023 2.20242 4.38023 2.17258 4.35934 2.16831C3.27537 1.94676 2.42825 1.09964 2.20669 0.0156637Z",fill:"#087443"})]}))},p=function(){return i("svg",e({xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 16 16",fill:"none"},{children:i("path",{d:"M3.125 2.75C3.02554 2.75 2.93016 2.78951 2.85983 2.85983C2.78951 2.93016 2.75 3.02554 2.75 3.125V6.125C2.75 6.22446 2.71049 6.31984 2.64017 6.39016C2.56984 6.46049 2.47446 6.5 2.375 6.5C2.27554 6.5 2.18016 6.46049 2.10983 6.39016C2.03951 6.31984 2 6.22446 2 6.125V3.125C2 2.82663 2.11853 2.54048 2.3295 2.3295C2.54048 2.11853 2.82663 2 3.125 2H6.125C6.22446 2 6.31984 2.03951 6.39016 2.10983C6.46049 2.18016 6.5 2.27554 6.5 2.375C6.5 2.47446 6.46049 2.56984 6.39016 2.64017C6.31984 2.71049 6.22446 2.75 6.125 2.75H3.125ZM9.5 2.375C9.5 2.27554 9.53951 2.18016 9.60983 2.10983C9.68016 2.03951 9.77554 2 9.875 2H12.875C13.1734 2 13.4595 2.11853 13.6705 2.3295C13.8815 2.54048 14 2.82663 14 3.125V6.125C14 6.22446 13.9605 6.31984 13.8902 6.39016C13.8198 6.46049 13.7245 6.5 13.625 6.5C13.5255 6.5 13.4302 6.46049 13.3598 6.39016C13.2895 6.31984 13.25 6.22446 13.25 6.125V3.125C13.25 3.02554 13.2105 2.93016 13.1402 2.85983C13.0698 2.78951 12.9745 2.75 12.875 2.75H9.875C9.77554 2.75 9.68016 2.71049 9.60983 2.64017C9.53951 2.56984 9.5 2.47446 9.5 2.375ZM2.375 9.5C2.47446 9.5 2.56984 9.53951 2.64017 9.60983C2.71049 9.68016 2.75 9.77554 2.75 9.875V12.875C2.75 12.9745 2.78951 13.0698 2.85983 13.1402C2.93016 13.2105 3.02554 13.25 3.125 13.25H6.125C6.22446 13.25 6.31984 13.2895 6.39016 13.3598C6.46049 13.4302 6.5 13.5255 6.5 13.625C6.5 13.7245 6.46049 13.8198 6.39016 13.8902C6.31984 13.9605 6.22446 14 6.125 14H3.125C2.82663 14 2.54048 13.8815 2.3295 13.6705C2.11853 13.4595 2 13.1734 2 12.875V9.875C2 9.77554 2.03951 9.68016 2.10983 9.60983C2.18016 9.53951 2.27554 9.5 2.375 9.5ZM13.625 9.5C13.7245 9.5 13.8198 9.53951 13.8902 9.60983C13.9605 9.68016 14 9.77554 14 9.875V12.875C14 13.1734 13.8815 13.4595 13.6705 13.6705C13.4595 13.8815 13.1734 14 12.875 14H9.875C9.77554 14 9.68016 13.9605 9.60983 13.8902C9.53951 13.8198 9.5 13.7245 9.5 13.625C9.5 13.5255 9.53951 13.4302 9.60983 13.3598C9.68016 13.2895 9.77554 13.25 9.875 13.25H12.875C12.9745 13.25 13.0698 13.2105 13.1402 13.1402C13.2105 13.0698 13.25 12.9745 13.25 12.875V9.875C13.25 9.77554 13.2895 9.68016 13.3598 9.60983C13.4302 9.53951 13.5255 9.5 13.625 9.5Z",fill:"#7A5AF8",stroke:"#7A5AF8","stroke-width":"0.5"})}))},C=function(C){var m=C.left,g=C.right,w=C.defaultLeftWidth,x=void 0===w?50:w,N=C.minLeftWidth,H=void 0===N?250:N,L=C.minRightWidth,B=void 0===L?250:L,A=C.className,k=void 0===A?"":A,M=C.height,V=void 0===M?"400px":M,b=C.width,z=void 0===b?"100%":b,E=C.header,y=C.onLeftWidthChange,F=o(x),S=F[0],D=F[1],R=o(x),O=R[0],P=R[1],Z=o(!1),I=Z[0],T=Z[1],W=o(!1),j=W[0],q=W[1],X=o(!1),Y=X[0],G=X[1],J=o(0),K=J[0],Q=J[1],U=o(0),$=U[0],_=U[1],ee=o(!1),ne=ee[0],te=ee[1],ie=c(null),oe=c(null),ce=c(null),ae=c(null);a(function(){var e=ie.current;e&&(ne?(e.showModal(),requestAnimationFrame(function(){if(ae.current){var e=ae.current.getBoundingClientRect().width;if(_(e),e>0){var n=Math.min(800/e*100,75);D(n)}}})):e.close())},[ne]),a(function(){var e=ae.current;if(e&&ne){var n,t=new ResizeObserver(function(e){var t=e[0];n=requestAnimationFrame(function(){_(t.contentRect.width)})});return t.observe(e),function(){cancelAnimationFrame(n),t.disconnect()}}},[ne]),a(function(){var e=oe.current;if(e){var n,t=new ResizeObserver(function(e){var t=e[0];n=requestAnimationFrame(function(){Q(t.contentRect.width)})});return t.observe(e),Q(e.getBoundingClientRect().width),function(){cancelAnimationFrame(n),t.disconnect()}}},[]);var re=K>0&&K<500,le=function(e){e.preventDefault(),T(!0)};a(function(){var e=function(e){if(I)if(re&&ce.current){var n=ce.current.getBoundingClientRect(),t=n.height,i=e.clientY-n.top;if(i>=H&&t-i-4>=B)P(i/t*100)}else if(!re){var o=ne?ae.current:oe.current;if(!o)return;var c=o.getBoundingClientRect(),a=c.width,r=e.clientX-c.left;if(r>=H&&a-r-4>=B)D(r/a*100),null==y||y(r)}},n=function(){T(!1)};return I&&(document.addEventListener("mousemove",e),document.addEventListener("mouseup",n)),function(){document.removeEventListener("mousemove",e),document.removeEventListener("mouseup",n)}},[I,re,ne,H,B,y]);var de,se=function(){j?(D(50),P(50),q(!1)):q(!0)},ue=function(){Y?(D(50),P(50),G(!1)):G(!0)},he=ne?$:K,ve=S/100*he,fe=he-ve-4,pe=ne?500:250;de=re?Y?{flex:1}:{height:"".concat(O,"%")}:Y?{flex:1}:{width:"".concat(S,"%")};var Ce,me=!re&&!j&&ve<=Math.max(H+10,pe),ge=!re&&!Y&&fe<=Math.max(B+10,pe),we=function(e){return e>=80?u.confidenceScoreHigh:e>=60?u.confidenceScoreMedium:u.confidenceScoreLow},xe="number"==typeof V?"".concat(V,"px"):V,Ne="number"==typeof z?"".concat(z,"px"):z;return n(t,{children:[n("div",e({ref:oe,className:"".concat(u.container," ").concat(re?u.containerVertical:u.containerHorizontal," ").concat(k),style:{height:re?"auto":xe,width:Ne}},{children:[E&&n("div",e({className:u.header},{children:[n("div",e({className:u.headerLeft},{children:[E.showDocIcon&&i(r,{className:u.headerIcon}),i("div",e({className:u.headerTitle},{children:E.title&&i("span",e({className:u.headerTitleText},{children:E.title}))}))]})),n("div",e({className:u.headerActions},{children:[void 0!==E.confidenceScore&&n("div",e({className:"".concat(u.confidenceScore," ").concat(we(E.confidenceScore))},{children:[i("div",e({style:{width:"16px",height:"16px"}},{children:i(f,{})})),n("div",{children:[Math.round(E.confidenceScore),"%"]})]})),i("button",e({className:u.fullscreenButton,onClick:function(){return te(!0)},title:"Open fullscreen"},{children:i(p,{})}))]}))]})),(Ce=!1,n("div",e({ref:Ce?void 0:ce,className:"".concat(u.contentArea," ").concat(re?u.contentAreaVertical:u.contentAreaHorizontal)},{children:[!j&&i("div",e({className:"".concat(u.panel," ").concat(re?u.panelVertical:""),style:e(e({},de),re?{height:xe}:{})},{children:m})),j&&i("button",e({onClick:se,className:"".concat(u.expandButton," ").concat(re?u.expandButtonVertical:u.expandButtonHorizontal),title:re?"Expand top panel (50/50)":"Expand left panel (50/50)"},{children:re?i(d,{size:14}):i(h,{})})),!j&&!Y&&n("div",e({onMouseDown:le,className:"".concat(u.divider," ").concat(re?u.dividerVertical:u.dividerHorizontal," ").concat(I?u.dividerDragging:u.dividerIdle)},{children:[i("div",{className:"".concat(u.dividerHitArea," ").concat(re?u.dividerHitAreaVertical:u.dividerHitAreaHorizontal)}),me&&i("button",e({onClick:function(e){e.stopPropagation(),se()},onMouseDown:function(e){return e.stopPropagation()},className:u.collapseButton,title:"Collapse left panel"},{children:i(v,{})})),ge&&i("button",e({onClick:function(e){e.stopPropagation(),ue()},onMouseDown:function(e){return e.stopPropagation()},className:u.collapseButton,title:"Collapse right panel"},{children:i(h,{})}))]})),!Y&&i("div",e({className:"".concat(u.panel," ").concat(re?u.panelVertical:""),style:e({flex:1},re?{height:xe}:{})},{children:g})),Y&&i("button",e({onClick:ue,className:"".concat(u.expandButton," ").concat(re?u.expandButtonBottomVertical:u.expandButtonRightHorizontal),title:re?"Expand bottom panel (50/50)":"Expand right panel (50/50)"},{children:re?i(s,{size:14}):i(v,{})})),I&&i("div",{className:"".concat(u.dragOverlay," ").concat(re?u.dragOverlayVertical:u.dragOverlayHorizontal)})]})))]})),i("dialog",e({ref:ie,className:u.dialogOverlay,onClose:function(){return te(!1)}},{children:n("div",e({ref:ae,className:u.dialogContent},{children:[E&&n("div",e({className:u.header},{children:[n("div",e({className:u.headerLeft},{children:[E.showDocIcon&&i(r,{className:u.headerIcon}),i("div",e({className:u.headerTitle},{children:E.title&&i(t,{children:i("span",e({className:u.headerTitleText},{children:E.title}))})}))]})),n("div",e({className:u.headerActions},{children:[void 0!==E.confidenceScore&&n("div",e({className:"".concat(u.confidenceScore," ").concat(we(E.confidenceScore))},{children:[i("div",e({style:{width:"16px",height:"16px"}},{children:i(f,{})})),n("div",{children:[Math.round(E.confidenceScore),"%"]})]})),i("button",e({className:u.fullscreenButton,onClick:function(){return te(!1)},title:"Close fullscreen"},{children:i(l,{size:20,color:"#5928ed"})}))]}))]})),n("div",e({className:"".concat(u.contentArea," ").concat(u.contentAreaHorizontal," ").concat(u.dialogContentArea)},{children:[!j&&i("div",e({className:u.panel,style:de},{children:m})),j&&i("button",e({onClick:se,className:"".concat(u.expandButton," ").concat(u.expandButtonHorizontal),title:"Expand left panel (50/50)"},{children:i(h,{})})),!j&&!Y&&n("div",e({onMouseDown:le,className:"".concat(u.divider," ").concat(u.dividerHorizontal," ").concat(I?u.dividerDragging:u.dividerIdle)},{children:[i("div",{className:"".concat(u.dividerHitArea," ").concat(u.dividerHitAreaHorizontal)}),me&&i("button",e({onClick:function(e){e.stopPropagation(),se()},onMouseDown:function(e){return e.stopPropagation()},className:u.collapseButton,title:"Collapse left panel"},{children:i(v,{})})),ge&&i("button",e({onClick:function(e){e.stopPropagation(),ue()},onMouseDown:function(e){return e.stopPropagation()},className:u.collapseButton,title:"Collapse right panel"},{children:i(h,{})}))]})),!Y&&i("div",e({className:u.panel,style:{flex:1}},{children:g})),Y&&i("button",e({onClick:ue,className:"".concat(u.expandButton," ").concat(u.expandButtonRightHorizontal),title:"Expand right panel (50/50)"},{children:i(v,{})})),I&&i("div",{className:"".concat(u.dragOverlay," ").concat(u.dragOverlayHorizontal)})]}))]}))}))]})};export{C as default};
|
|
2
2
|
//# sourceMappingURL=SplitterCitationsComponent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SplitterCitationsComponent.d.ts","sourceRoot":"","sources":["../../../../../src/features/SplitterCitations/SplitterCitationsComponent.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"SplitterCitationsComponent.d.ts","sourceRoot":"","sources":["../../../../../src/features/SplitterCitations/SplitterCitationsComponent.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AA8B3D,UAAU,cAAc;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAED,UAAU,aAAa;IACrB,IAAI,EAAE,KAAK,CAAC,SAAS,CAAC;IACtB,KAAK,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACzB,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,MAAM,CAAC,EAAE,cAAc,CAAC;IACxB,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CAC7C;AAEA,QAAA,MAAM,0BAA0B,EAAE,KAAK,CAAC,EAAE,CAAC,aAAa,CAibxD,CAAC;AACF,eAAe,0BAA0B,CAAC"}
|