@viswa-test/test-citation 0.0.7 → 0.0.9
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/README.md +67 -0
- package/dist/cjs/features/AiRedLineCompare/AiRedLineCompare.js +1 -1
- package/dist/cjs/features/MarkdownWithImageCitation/MarkdownWithImageCitation.js +2 -0
- package/dist/cjs/features/MarkdownWithImageCitation/MarkdownWithImageCitation.js.map +1 -0
- package/dist/cjs/features/MarkdownWithImageCitation/MarkdownWithImageCitation.module.css.js +2 -0
- package/dist/cjs/features/MarkdownWithImageCitation/MarkdownWithImageCitation.module.css.js.map +1 -0
- package/dist/cjs/features/PdfViewer/PdfViewer.js +1 -1
- package/dist/cjs/features/PdfViewer/usePdfHighlight.js +1 -1
- package/dist/cjs/features/TableCitation/TableCitationContent.module.css.js +1 -1
- package/dist/cjs/index.js +1 -1
- package/dist/features/AiRedLineCompare/AiRedLineCompare.js +1 -1
- package/dist/features/MarkdownWithImageCitation/MarkdownWithImageCitation.js +2 -0
- package/dist/features/MarkdownWithImageCitation/MarkdownWithImageCitation.js.map +1 -0
- package/dist/features/MarkdownWithImageCitation/MarkdownWithImageCitation.module.css.js +2 -0
- package/dist/features/MarkdownWithImageCitation/MarkdownWithImageCitation.module.css.js.map +1 -0
- package/dist/features/PdfViewer/PdfViewer.js +1 -1
- package/dist/features/PdfViewer/usePdfHighlight.js +1 -1
- package/dist/features/TableCitation/TableCitationContent.module.css.js +1 -1
- package/dist/index.js +1 -1
- package/dist/types/src/AiRedLineCompareTest.d.ts.map +1 -1
- package/dist/types/src/MarkdownWithImageCitationTest.d.ts +3 -0
- package/dist/types/src/MarkdownWithImageCitationTest.d.ts.map +1 -0
- package/dist/types/src/PdfViewerTest.d.ts +3 -1
- package/dist/types/src/PdfViewerTest.d.ts.map +1 -1
- package/dist/types/src/features/AiRedLineCompare/AiRedLineCompare.d.ts.map +1 -1
- package/dist/types/src/features/MarkdownWithImageCitation/MarkdownWithImageCitation.d.ts +37 -0
- package/dist/types/src/features/MarkdownWithImageCitation/MarkdownWithImageCitation.d.ts.map +1 -0
- package/dist/types/src/features/PdfViewer/PdfViewer.d.ts +11 -1
- package/dist/types/src/features/PdfViewer/PdfViewer.d.ts.map +1 -1
- package/dist/types/src/features/PdfViewer/usePdfHighlight.d.ts +4 -2
- package/dist/types/src/features/PdfViewer/usePdfHighlight.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +1 -1
- package/dist/types/src/index.d.ts.map +1 -1
- package/package.json +35 -34
package/README.md
CHANGED
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
- [PdfEditorCitation](#pdfeditorcitation) [<img src="https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png" width="18" height="18">](https://github.com/Techolution/e-llm-studio-lib/blob/dev/citation/src/features/PdfEditorCitation/README.md)
|
|
20
20
|
- [RequirementAICitation](#requirementaicitation) [<img src="https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png" width="18" height="18">](https://github.com/Techolution/e-llm-studio-lib/blob/dev/citation/src/features/RequirementAiCitations/RequirementAiCitationsReadme.md)
|
|
21
21
|
- [VideoCitationContent](#videocitationcontent) [<img src="https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png" width="18" height="18">](https://github.com/Techolution/e-llm-studio-lib/blob/dev/citation/src/features/RequirementAiCitations/RequirementAiCitationsReadme.md)
|
|
22
|
+
- [MarkdownWithImageCitation](#markdownwithimagecitation) [<img src="https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png" width="18" height="18">](https://github.com/Techolution/e-llm-studio-lib/blob/dev/citation/src/features/MarkdownWithImageCitation/README.md)
|
|
22
23
|
- [ScannedDocCitation](#scanneddoccitation) [<img src="https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png" width="18" height="18">](https://github.com/Techolution/e-llm-studio-lib/blob/dev/citation/src/features/ScannedDocCitation/README.md)
|
|
23
24
|
- [Other Components](#other-components)
|
|
24
25
|
- [Bookemon](#bookemon) [<img src="https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png" width="18" height="18">](https://github.com/Techolution/e-llm-studio-lib/blob/dev/citation/src/features/Bookemon/BookemonReadme.md)
|
|
@@ -887,6 +888,61 @@ import { WebCitationWithImageContent } from '@e-llm-studio/citation/WebCitationW
|
|
|
887
888
|
|
|
888
889
|
---
|
|
889
890
|
|
|
891
|
+
### Usage 5: Standalone Markdown With Image Citation
|
|
892
|
+
|
|
893
|
+
Use this component when the image should be rendered as part of the markdown content itself rather than as a separate prop-driven media block.
|
|
894
|
+
|
|
895
|
+
```tsx
|
|
896
|
+
import { MarkdownWithImageCitation } from '@e-llm-studio/citation/MarkdownWithImageCitation'
|
|
897
|
+
|
|
898
|
+
const markdownContent = `
|
|
899
|
+
## Product Collaboration Workspace
|
|
900
|
+
|
|
901
|
+
<img src="https://images.unsplash.com/photo-1516321318423-f06f85e504b3?auto=format&fit=crop&w=1200&q=80" alt="Team collaboration workspace" />
|
|
902
|
+
|
|
903
|
+
This visual captures a clean product collaboration workspace prepared for planning, note-taking, and design review.
|
|
904
|
+
|
|
905
|
+
### Key observations
|
|
906
|
+
|
|
907
|
+
- The laptop acts as the primary working surface for product or engineering review
|
|
908
|
+
- The surrounding setup reinforces a structured, research-oriented workflow
|
|
909
|
+
- The image is rendered inline as part of the markdown citation
|
|
910
|
+
`;
|
|
911
|
+
|
|
912
|
+
<MarkdownWithImageCitation
|
|
913
|
+
citationTitle="Inline Markdown Image Reference"
|
|
914
|
+
timestamp="Apr 03, 2026 - 11:15 AM"
|
|
915
|
+
relevanceScore={98}
|
|
916
|
+
markdownContent={markdownContent}
|
|
917
|
+
closeCitationConfig={{
|
|
918
|
+
CloseIcon: () => <span>✕</span>,
|
|
919
|
+
handleCloseCitationPreview: () => console.log('Closed'),
|
|
920
|
+
}}
|
|
921
|
+
/>
|
|
922
|
+
```
|
|
923
|
+
|
|
924
|
+
**With CitationRenderer (Expandable Pill):**
|
|
925
|
+
```tsx
|
|
926
|
+
import { CitationRenderer } from '@e-llm-studio/citation/CitationRenderer'
|
|
927
|
+
import { MarkdownWithImageCitation } from '@e-llm-studio/citation/MarkdownWithImageCitation'
|
|
928
|
+
|
|
929
|
+
<CitationRenderer
|
|
930
|
+
inLineCitation={true}
|
|
931
|
+
citationTitle="Markdown Image Reference"
|
|
932
|
+
citationComponent={
|
|
933
|
+
<MarkdownWithImageCitation
|
|
934
|
+
citationTitle="Workspace Note"
|
|
935
|
+
markdownContent={markdownContent}
|
|
936
|
+
relevanceScore={98}
|
|
937
|
+
/>
|
|
938
|
+
}
|
|
939
|
+
chevronDownComponent={<span>▼</span>}
|
|
940
|
+
chevronUpComponent={<span>▲</span>}
|
|
941
|
+
/>
|
|
942
|
+
```
|
|
943
|
+
|
|
944
|
+
---
|
|
945
|
+
|
|
890
946
|
### Component Props Reference
|
|
891
947
|
|
|
892
948
|
#### AiReasoningCitation Props
|
|
@@ -949,6 +1005,17 @@ import { WebCitationWithImageContent } from '@e-llm-studio/citation/WebCitationW
|
|
|
949
1005
|
|
|
950
1006
|
*Either `signedUrl` or `gsUtilPath` must be provided
|
|
951
1007
|
|
|
1008
|
+
#### MarkdownWithImageCitation Props
|
|
1009
|
+
|
|
1010
|
+
| Prop Name | Type | Required | Description |
|
|
1011
|
+
|-----------|------|----------|-------------|
|
|
1012
|
+
| `markdownContent` | `string` | ✅ | Markdown/HTML string to render. Inline `<img />` tags are supported. |
|
|
1013
|
+
| `citationTitle` | `string` | ❌ | Title shown in the header. Defaults to `"Markdown With Image"`. |
|
|
1014
|
+
| `timestamp` | `string` | ❌ | Optional subtitle shown below the title. |
|
|
1015
|
+
| `relevanceScore` | `number` | ❌ | Confidence score to display in the header badge (0–100). |
|
|
1016
|
+
| `closeCitationConfig` | `Object` | ❌ | `{ CloseIcon, handleCloseCitationPreview }` — renders a close button in the header. |
|
|
1017
|
+
| `styles` | `Object` | ❌ | Deep style overrides for container, header, image wrapper, and markdown regions. |
|
|
1018
|
+
|
|
952
1019
|
---
|
|
953
1020
|
|
|
954
1021
|
**Required peer dependencies:**
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),n=require("react"),s=require("lucide-react"),t=require("./utils/helpers.js"),o=require("react-markdown");function r(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var a=r(n),l=r(o),d=function(n){var t=n.type,o=n.label,r={display:"inline-flex",alignItems:"center",gap:"4px",whiteSpace:"nowrap",borderRadius:"9999px",padding:"4px 12px",fontSize:"12px",fontWeight:600};switch(t){case"similarity":return i.jsx("span",e.__assign({style:e.__assign(e.__assign({},r),{border:"1px solid #C4B5FD",backgroundColor:"#F5F3FF",color:"#6D28D9"})},{children:o}));case"no_deviation":return i.jsx("span",e.__assign({style:e.__assign(e.__assign({},r),{border:"1px solid #A7F3D0",backgroundColor:"#ECFDF3",color:"#027A48"})},{children:o}));case"deviation":return i.jsxs("span",e.__assign({style:e.__assign(e.__assign({},r),{gap:"6px",border:"1px solid #FECACA",backgroundColor:"#FEF2F2",color:"#DC2626"})},{children:[o,i.jsx("span",e.__assign({style:{borderRadius:"9999px",backgroundColor:"#FEE2E2",padding:"2px",display:"flex",alignItems:"center",justifyContent:"center"}},{children:i.jsx(s.ThumbsDown,{style:{width:"12px",height:"12px"}})})),i.jsx(s.ChevronDown,{style:{width:"12px",height:"12px",color:"#DC2626"}})]}));default:return null}};function p(n,s,t){return n&&n.length>0?i.jsx("div",e.__assign({style:{display:"flex",flexDirection:"column",gap:"8px"}},{children:n.map(function(n){return i.jsx("p",e.__assign({style:{fontSize:"13px",lineHeight:"1.625",color:"#374151",margin:0}},{children:i.jsx(l.default,e.__assign({components:t},{children:n.text}))}),n.id)})})):s||i.jsx("p",e.__assign({style:{fontSize:"13px",fontStyle:"italic",color:"#9CA3AF",margin:0}},{children:"No content available"}))}var x=function(o){var r=o.leftDocumentName,x=void 0===r?"Uploaded Contract":r,c=o.rightDocumentName,g=void 0===c?"Template":c,h=o.overallSimilarity,u=void 0===h?"Similarity":h,_=o.rawMappingData,f=o.deviationMappingData,F=o.defaultExpandedIds,
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),n=require("react"),s=require("lucide-react"),t=require("./utils/helpers.js"),o=require("react-markdown");function r(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var a=r(n),l=r(o),d=function(n){var t=n.type,o=n.label,r={display:"inline-flex",alignItems:"center",gap:"4px",whiteSpace:"nowrap",borderRadius:"9999px",padding:"4px 12px",fontSize:"12px",fontWeight:600};switch(t){case"similarity":return i.jsx("span",e.__assign({style:e.__assign(e.__assign({},r),{border:"1px solid #C4B5FD",backgroundColor:"#F5F3FF",color:"#6D28D9"})},{children:o}));case"no_deviation":return i.jsx("span",e.__assign({style:e.__assign(e.__assign({},r),{border:"1px solid #A7F3D0",backgroundColor:"#ECFDF3",color:"#027A48"})},{children:o}));case"deviation":return i.jsxs("span",e.__assign({style:e.__assign(e.__assign({},r),{gap:"6px",border:"1px solid #FECACA",backgroundColor:"#FEF2F2",color:"#DC2626"})},{children:[o,i.jsx("span",e.__assign({style:{borderRadius:"9999px",backgroundColor:"#FEE2E2",padding:"2px",display:"flex",alignItems:"center",justifyContent:"center"}},{children:i.jsx(s.ThumbsDown,{style:{width:"12px",height:"12px"}})})),i.jsx(s.ChevronDown,{style:{width:"12px",height:"12px",color:"#DC2626"}})]}));default:return null}};function p(n,s,t){return n&&n.length>0?i.jsx("div",e.__assign({style:{display:"flex",flexDirection:"column",gap:"8px"}},{children:n.map(function(n){return i.jsx("p",e.__assign({style:{fontSize:"13px",lineHeight:"1.625",color:"#374151",margin:0}},{children:i.jsx(l.default,e.__assign({components:t},{children:n.text}))}),n.id)})})):s||i.jsx("p",e.__assign({style:{fontSize:"13px",fontStyle:"italic",color:"#9CA3AF",margin:0}},{children:"No content available"}))}var x=function(o){var r=o.leftDocumentName,x=void 0===r?"Uploaded Contract":r,c=o.rightDocumentName,g=void 0===c?"Template":c,h=o.overallSimilarity,u=void 0===h?"Similarity":h,_=o.rawMappingData,f=o.deviationMappingData,F=o.defaultExpandedIds,y=void 0===F?[]:F,b=o.onSectionToggle,v=o.showDeviationBar,j=void 0===v||v,m=o.centerColumnWidth,C=void 0===m?15:m,w=o.className,D=void 0===w?"":w,A=o.style,B=t.transformContractComparisons(_),E=n.useState(function(){return new Set(null!=y?y:[B[0].id])}),k=E[0],z=E[1],S=n.useMemo(function(){return{p:function(n){var s=n.children;return i.jsx("div",e.__assign({className:"inline",style:{padding:"8px 0px 8px 0px"}},{children:s}))},strong:function(n){var s=n.children;return i.jsx("strong",e.__assign({className:"font-semibold"},{children:s}))},em:function(n){var s=n.children;return i.jsx("em",e.__assign({className:"italic"},{children:s}))}}},[]),I=n.useState(!0),T=I[0],R=I[1],N=n.useCallback(function(e){z(function(i){var n=new Set(i),s=!n.has(e);return s?n.add(e):n.delete(e),null==b||b(e,s),n})},[b]),q=function(){return R(function(e){return!e})},W=j?"1fr minmax(80px, ".concat(C,"%) 1fr"):"1fr 1fr";return i.jsx("div",e.__assign({className:D,style:e.__assign({display:"flex",flexDirection:"column",height:"100%",width:"100%",overflow:"auto",fontFamily:"sans-serif",background:"#FFFFFF"},A)},{children:i.jsx("div",e.__assign({style:{width:"100%",padding:"24px 16px 40px"}},{children:i.jsxs("div",e.__assign({style:{position:"relative",display:"grid",gridTemplateColumns:W,rowGap:"0px"}},{children:[T&&i.jsx("div",{style:{pointerEvents:"none",position:"absolute",top:56,bottom:0,left:0,width:j?"calc((100% - ".concat(C,"%) / 2)"):"50%",zIndex:0,border:"2px dashed #A0AAB4",borderTop:"none",borderRadius:"0 0 12px 12px",background:"#FFFFFF"}}),T&&i.jsx("div",{style:{pointerEvents:"none",position:"absolute",top:56,bottom:0,right:0,width:j?"calc((100% - ".concat(C,"%) / 2)"):"50%",zIndex:0,border:"1px solid #E5E7EB",borderTop:"none",background:"#F7F8FA",borderRadius:"0 0 12px 12px"}}),i.jsxs("div",e.__assign({style:{position:"relative",zIndex:10,display:"flex",alignItems:"center",gap:"12px",padding:"0 16px",height:56,cursor:"pointer",background:"#F7F8FA",border:"2px dashed #A0AAB4",borderBottom:T?"1px dashed #A0AAB4":"2px dashed #A0AAB4",borderRadius:T?"12px 12px 0 0":"12px",transition:"border-radius 0.2s ease"},onClick:q},{children:[i.jsx(s.FileText,{style:{width:"18px",height:"18px",color:"#4B5563"}}),i.jsx("span",e.__assign({style:{flex:1,fontSize:"15px",fontWeight:700,color:"#19213D"}},{children:x})),T?i.jsx(s.ChevronUp,{style:{width:"20px",height:"20px",color:"#6B7280"}}):i.jsx(s.ChevronDown,{style:{width:"20px",height:"20px",color:"#6B7280"}})]})),j&&i.jsxs("div",e.__assign({style:{position:"relative",zIndex:10,display:"flex",alignItems:"center",justifyContent:"center"}},{children:[i.jsx("div",{style:{position:"absolute",top:"50%",left:0,right:0,height:"1.5px",background:"#C4B5FD",opacity:.5}}),i.jsx("div",e.__assign({style:{position:"relative",zIndex:11,background:"#FFFFFF",padding:"0 8px"}},{children:i.jsx(d,{type:"similarity",label:u})}))]})),i.jsxs("div",e.__assign({style:{position:"relative",zIndex:10,display:"flex",alignItems:"center",gap:"12px",padding:"0 16px",height:56,cursor:"pointer",background:"#F7F8FA",border:"1px solid #E5E7EB",borderRadius:T?"12px 12px 0 0":"12px",transition:"border-radius 0.2s ease"},onClick:q},{children:[i.jsx(s.FileText,{style:{width:"18px",height:"18px",color:"#5928ED"}}),i.jsx("span",e.__assign({style:{flex:1,fontSize:"15px",fontWeight:600,color:"#5928ED"}},{children:g})),T?i.jsx(s.ChevronUp,{style:{width:"20px",height:"20px",color:"#6B7280"}}):i.jsx(s.ChevronDown,{style:{width:"20px",height:"20px",color:"#6B7280"}})]})),T&&B.map(function(n,t){var o,r,x,c=k.has(n.id),g=0===t?"42px":"38px";return i.jsxs(a.default.Fragment,{children:[i.jsx("div",e.__assign({style:{position:"relative",zIndex:10,padding:"12px 16px"}},{children:i.jsxs("div",e.__assign({style:{borderRadius:"8px",border:"1px solid #E5E7EB",background:"#FFFFFF",boxShadow:"0 1px 2px rgba(0,0,0,0.05)"}},{children:[i.jsxs("button",e.__assign({onClick:function(){return N(n.id)},style:{display:"flex",width:"100%",alignItems:"center",justifyContent:"space-between",padding:"16px",background:"transparent",border:"none",cursor:"pointer"}},{children:[i.jsx("span",e.__assign({style:{fontSize:"13px",fontWeight:600,color:"#111827"}},{children:i.jsx(l.default,e.__assign({components:S},{children:n.leftTitle}))})),c?i.jsx(s.ChevronUp,{size:16,color:"#6B7280"}):i.jsx(s.ChevronDown,{size:16,color:"#6B7280"})]})),c&&i.jsx("div",e.__assign({style:{borderTop:"1px solid #F3F4F6",padding:"16px"}},{children:p(null!==(o=n.leftClauses)&&void 0!==o?o:[],n.contentLeft,S)}))]}))})),j&&i.jsxs("div",e.__assign({style:{position:"relative",zIndex:10}},{children:[i.jsx("div",{style:{position:"absolute",left:"-16px",right:"-16px",top:g,height:"1.5px",background:(x=f[t].matchType,"deviation"===x?"#FECACA":"no_deviation"===x?"#77BB9D":"#C4B5FD")}}),i.jsx("div",e.__assign({style:{position:"absolute",left:"50%",transform:"translate(-50%, -50%)",top:g,background:"#FFFFFF",padding:"0 8px"}},{children:i.jsx(d,{type:f[t].matchType,label:f[t].matchLabel})}))]})),i.jsx("div",e.__assign({style:{position:"relative",zIndex:10,padding:"12px 16px"}},{children:i.jsxs("div",e.__assign({style:{borderRadius:"8px",border:"1px solid #E5E7EB",background:"#FFFFFF",boxShadow:"0 1px 2px rgba(0,0,0,0.05)"}},{children:[i.jsxs("button",e.__assign({onClick:function(){return N(n.id)},style:{display:"flex",width:"100%",alignItems:"center",justifyContent:"space-between",padding:"16px",background:"transparent",border:"none",cursor:"pointer"}},{children:[i.jsx("span",e.__assign({style:{fontSize:"13px",fontWeight:600,color:"#111827"}},{children:i.jsx(l.default,e.__assign({components:S},{children:n.rightTitle}))})),c?i.jsx(s.ChevronUp,{size:16,color:"#6B7280"}):i.jsx(s.ChevronDown,{size:16,color:"#6B7280"})]})),c&&i.jsx("div",e.__assign({style:{borderTop:"1px solid #F3F4F6",padding:"16px"}},{children:p(null!==(r=n.rightClauses)&&void 0!==r?r:[],n.contentRight,S)}))]}))}))]},n.id)})]}))}))}))};exports.AiRedLineCompare=x,exports.default=x;
|
|
2
2
|
//# sourceMappingURL=AiRedLineCompare.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),n=require("react"),l=require("react-markdown"),s=require("rehype-raw"),t=require("../RequirementAiCitations/components/CitationAIConfidenceDisplay.js"),a=require("./MarkdownWithImageCitation.module.css.js");function r(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var d=r(n),o=r(l),u=r(s);exports.default=function(n){var l,s,r,c,v=null===(l=null==n?void 0:n.closeCitationConfig)||void 0===l?void 0:l.CloseIcon,m=n.styles,_=function(e){if(!e)return"";var i=e.replace(/\t/g," ").split("\n"),n=i.filter(function(e){return e.trim().length>0}).reduce(function(e,i){var n=i.match(/^ */),l=n?n[0].length:0;return Math.min(e,l)},Number.POSITIVE_INFINITY);return i.map(function(e){return n&&Number.isFinite(n)?e.slice(n):e}).join("\n").trim()}(n.markdownContent);return i.jsxs("div",e.__assign({className:a.default.container,style:null==m?void 0:m.container},{children:[i.jsxs("div",e.__assign({className:a.default.header,style:null==m?void 0:m.header},{children:[i.jsxs("div",e.__assign({className:a.default.titleGroup,style:null==m?void 0:m.titleGroup},{children:[i.jsx("h2",e.__assign({className:a.default.title,style:null==m?void 0:m.title},{children:(null==n?void 0:n.citationTitle)||"Markdown With Image"})),(null==n?void 0:n.timestamp)?i.jsx("span",e.__assign({className:a.default.timestamp,style:null==m?void 0:m.timestamp},{children:n.timestamp})):null]})),(null==n?void 0:n.closeCitationConfig)?i.jsxs("div",e.__assign({className:a.default.headerRight,style:null==m?void 0:m.headerRight},{children:[t.renderCitationAIConfidenceDisplay(n.relevanceScore,!1,null==m?void 0:m.aiConfidenceDisplayPill),i.jsx("div",{className:a.default.divider,style:null==m?void 0:m.divider}),v&&i.jsx("div",e.__assign({className:a.default.closeIconWrapper,style:null==m?void 0:m.closeIconWrapper,onClick:n.closeCitationConfig.handleCloseCitationPreview},{children:i.jsx(v,{className:a.default.closeIcon})}))]})):t.renderCitationAIConfidenceDisplay(n.relevanceScore,!0,null==m?void 0:m.aiConfidenceDisplayPill)]})),i.jsx("div",e.__assign({className:a.default.content,style:null==m?void 0:m.content},{children:i.jsx("div",e.__assign({style:null===(s=null==m?void 0:m.markdown)||void 0===s?void 0:s.containerWrapper},{children:i.jsx("div",e.__assign({style:null===(r=null==m?void 0:m.markdown)||void 0===r?void 0:r.mainCard},{children:i.jsx("div",e.__assign({className:a.default.markdownBody,style:null===(c=null==m?void 0:m.markdown)||void 0===c?void 0:c.scrollArea},{children:i.jsx(o.default,e.__assign({rehypePlugins:[u.default],components:{p:function(n){n.node;var l=n.children,s=e.__rest(n,["node","children"]);return i.jsx("p",e.__assign({},s,{children:d.default.Children.map(l,function(n){var l,s,t;return"string"==typeof n?(s=n,(t=null===(l=null==m?void 0:m.markdown)||void 0===l?void 0:l.customHighlight)?i.jsx("span",e.__assign({style:t},{children:s})):s):n})}))},img:function(n){n.node;var l=e.__rest(n,["node"]);return i.jsx("div",e.__assign({className:a.default.imageWrapper,style:null==m?void 0:m.imageWrapper},{children:i.jsx("img",e.__assign({},l,{className:a.default.image,style:null==m?void 0:m.image,alt:l.alt||"Citation image"}))}))},ul:function(n){var l;n.node,n.ordered;var s=e.__rest(n,["node","ordered"]);return i.jsx("ul",e.__assign({},s,{style:null===(l=null==m?void 0:m.markdown)||void 0===l?void 0:l.list}))},ol:function(n){var l;n.node,n.ordered;var s=e.__rest(n,["node","ordered"]);return i.jsx("ol",e.__assign({},s,{style:null===(l=null==m?void 0:m.markdown)||void 0===l?void 0:l.list}))}}},{children:_}))}))}))}))}))]}))};
|
|
2
|
+
//# sourceMappingURL=MarkdownWithImageCitation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MarkdownWithImageCitation.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});!function(){if("undefined"==typeof document)return;const o=document.createElement("style");o.type="text/css";const e=window.__CSP_NONCE__||document.querySelector('meta[name="csp-nonce"]')?.content;e&&o.setAttribute("nonce",e),o.appendChild(document.createTextNode(".MarkdownWithImageCitation-module_container__IIipw{border:1px solid #e5e7eb;display:flex;flex-direction:column;height:100%;min-height:200px;position:relative;row-gap:1rem}.MarkdownWithImageCitation-module_header__yELrX{align-items:center;border-bottom:1px solid #e5e7eb;display:flex;flex-direction:row;justify-content:space-between;padding:.5rem 1rem;width:100%}.MarkdownWithImageCitation-module_titleGroup__NoGZT{display:flex;flex-direction:column;overflow:hidden;row-gap:.125rem}.MarkdownWithImageCitation-module_title__2ol0g{color:#1f2937;font-family:Inter,sans-serif;font-weight:400;margin-top:.5rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.MarkdownWithImageCitation-module_timestamp__TycMU{color:#6b7280;font-family:Inter,sans-serif;font-size:.75rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.MarkdownWithImageCitation-module_headerRight__fKorY{align-items:center;column-gap:1rem;display:flex;flex-direction:row}.MarkdownWithImageCitation-module_divider__DBf2T{align-self:stretch;background-color:#e5e7eb;margin-bottom:-.5rem;margin-top:-.5rem;width:1px}.MarkdownWithImageCitation-module_closeIconWrapper__alT2Q{cursor:pointer}.MarkdownWithImageCitation-module_closeIcon__KvaUd{color:#6b7280;height:24px;width:24px}.MarkdownWithImageCitation-module_content__omW6T{display:flex;flex-direction:column;gap:.875rem;padding:1rem 1rem 1.25rem}.MarkdownWithImageCitation-module_imageWrapper__IuQaH{background:#f8fafc;border:1px solid #e5e7eb;border-radius:12px;margin-bottom:1rem;margin-top:1rem;overflow:hidden;width:100%}.MarkdownWithImageCitation-module_image__69FkI{display:block;height:auto;max-width:100%;object-fit:cover;vertical-align:middle;width:100%}.MarkdownWithImageCitation-module_markdownBody__Lf-gb{color:#1f2937;font-family:Inter,sans-serif;font-size:.975rem;line-height:1.65}.MarkdownWithImageCitation-module_markdownBody__Lf-gb>:first-child{margin-top:0}.MarkdownWithImageCitation-module_markdownBody__Lf-gb>:last-child{margin-bottom:0}.MarkdownWithImageCitation-module_markdownBody__Lf-gb h1,.MarkdownWithImageCitation-module_markdownBody__Lf-gb h2,.MarkdownWithImageCitation-module_markdownBody__Lf-gb h3,.MarkdownWithImageCitation-module_markdownBody__Lf-gb h4,.MarkdownWithImageCitation-module_markdownBody__Lf-gb h5,.MarkdownWithImageCitation-module_markdownBody__Lf-gb h6{color:#111827;line-height:1.2;margin:0 0 .625rem}.MarkdownWithImageCitation-module_markdownBody__Lf-gb h1{font-size:2rem}.MarkdownWithImageCitation-module_markdownBody__Lf-gb h2{font-size:1.125rem;font-weight:700}.MarkdownWithImageCitation-module_markdownBody__Lf-gb h3{font-size:1rem;font-weight:700}.MarkdownWithImageCitation-module_markdownBody__Lf-gb p{margin:0 0 .875rem}.MarkdownWithImageCitation-module_markdownBody__Lf-gb ol,.MarkdownWithImageCitation-module_markdownBody__Lf-gb ul{margin:0 0 1rem;padding-left:1.25rem}.MarkdownWithImageCitation-module_markdownBody__Lf-gb li+li{margin-top:.25rem}.MarkdownWithImageCitation-module_markdownBody__Lf-gb strong{color:#111827}.MarkdownWithImageCitation-module_markdownBody__Lf-gb blockquote{border-left:3px solid #dbe3f0;color:#4b5563;margin:0 0 1rem;padding-left:.875rem}"));const t=document.head||document.getElementsByTagName("head")[0]||document.documentElement;t&&t.appendChild(o)}(),exports.default={container:"MarkdownWithImageCitation-module_container__IIipw",header:"MarkdownWithImageCitation-module_header__yELrX",titleGroup:"MarkdownWithImageCitation-module_titleGroup__NoGZT",title:"MarkdownWithImageCitation-module_title__2ol0g",timestamp:"MarkdownWithImageCitation-module_timestamp__TycMU",headerRight:"MarkdownWithImageCitation-module_headerRight__fKorY",divider:"MarkdownWithImageCitation-module_divider__DBf2T",closeIconWrapper:"MarkdownWithImageCitation-module_closeIconWrapper__alT2Q",closeIcon:"MarkdownWithImageCitation-module_closeIcon__KvaUd",content:"MarkdownWithImageCitation-module_content__omW6T",imageWrapper:"MarkdownWithImageCitation-module_imageWrapper__IuQaH",image:"MarkdownWithImageCitation-module_image__69FkI",markdownBody:"MarkdownWithImageCitation-module_markdownBody__Lf-gb"};
|
|
2
|
+
//# sourceMappingURL=MarkdownWithImageCitation.module.css.js.map
|
package/dist/cjs/features/MarkdownWithImageCitation/MarkdownWithImageCitation.module.css.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MarkdownWithImageCitation.module.css.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),t=require("react/jsx-runtime"),i=require("@react-pdf-viewer/core"),r=require("./PdfContainer.js"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),t=require("react/jsx-runtime"),i=require("@react-pdf-viewer/core"),r=require("./PdfContainer.js"),o=require("./PdfToolbar.js"),s=require("./PdfStyle.js"),n=require("./usePdfHighlight.js");require("@react-pdf-viewer/zoom/lib/styles/index.css"),require("@react-pdf-viewer/page-navigation/lib/styles/index.css"),require("@react-pdf-viewer/core/lib/styles/index.css"),require("@react-pdf-viewer/search/lib/styles/index.css");var l=require("react");exports.default=function(a){var u,c=a.pdfUrl,d=a.highlightText,g=a.highlightPages,f=a.highlightCordinatePages,h=a.jumpToPageValue,p=void 0===h?0:h,v=a.pdfName,m=a.onClose,x=a.customStyles,y=a.customClasses,_=a.customIcons,q=a.useCoordinates,P=l.useRef(null),S=l.useMemo(function(){if(q)return new Set(f.map(function(e){return e.pageIndex}));var e=new Set;return Object.values(g).forEach(function(t){t>0&&e.add(t-1)}),e},[g]),T=(u=d)&&0!==u.length?u.filter(function(e){return!u.some(function(t){return t!==e&&t.includes(e)})}):u,C=n.PdfHighlightControls(T,q?{}:g,P,S,q,q?f:[]),b=C.highlightIndex,j=C.cursorIndex,w=C.setCursorIndex,I=C.orderedKeys,H=C.totalHighlights,A=C.getValidPosition,F=C.tryJump,R=C.jumpToPage,V=C.zoomTo,N=C.plugins,z=C.controls,B=C.hideNonTargetHighlights,O=C.deduplicateHighlights,U=A(j);if(!c)return t.jsx("div",e.__assign({style:e.__assign(e.__assign({},s.pdfStyles.emptyState),null==x?void 0:x.emptyState)},{children:"PDF is not available for this selection"}));return t.jsxs("div",e.__assign({ref:P,className:(null==y?void 0:y.pdfViewerWrapper)||"",style:e.__assign(e.__assign(e.__assign({},s.pdfStyles.pdfViewer),{display:"flex",flexDirection:"column",height:"100%",width:"100%",backgroundColor:"#FAFAFA"}),null==x?void 0:x.pdfViewer)},{children:[t.jsx(o.default,{highlightIndex:b,totalHighlights:H,controls:z,currentPosition:U,pdfName:v,onClose:m,pdfUrl:c,viewerRef:P,customStyles:x,customClasses:y,customIcons:_}),t.jsx(r.default,{pdfUrl:c,plugins:N,customStyles:x,onLoad:function(){if(V(i.SpecialZoomLevel.ActualSize),p>0){var e=p-1,t=I[e],r=g[t],o=f[e];w(e),console.log(o,"cordinateTargetHighlight"),q&&o.pageIndex>0&&R(o.pageIndex),r>0&&(setTimeout(function(){B(S),O(r-1)},1e3),q||R(r-1))}requestAnimationFrame(function(){F(),q||function(){if(P.current){var e=p-1,t=I[e],i=g[t],r=i>0?i-1:0,o={};I.forEach(function(e,t){var i=g[e];i>0&&(o[i]||(o[i]=[]),o[i].push(t))});var s=(o[i]||[]).indexOf(e),n=0,l=function(){var e,t;if(!(++n>40)){var i=null===(e=P.current)||void 0===e?void 0:e.querySelector(".rpv-core__inner-pages");if(i){var o=null===(t=P.current)||void 0===t?void 0:t.querySelector('[data-testid="core__page-layer-'.concat(r,'"]'));if(o){var a=i.getBoundingClientRect(),u=o.getBoundingClientRect();if(u.top<a.bottom&&u.bottom>a.top){var c=o.querySelectorAll(".rpv-search__highlight")[s];if(c){var d=c.getBoundingClientRect(),g=i.scrollTop+(d.top-a.top)-i.clientHeight/2+d.height/2;i.scrollTo({top:g,behavior:"smooth"})}else setTimeout(l,100)}else setTimeout(l,100)}else setTimeout(l,100)}else setTimeout(l,100)}};setTimeout(l,500)}}()})},onPageChange:function(e){var t=e.currentPage;S.has(t)?(O(t),B(S)):B(S)}})]}))};
|
|
2
2
|
//# sourceMappingURL=PdfViewer.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("react"),r=require("@react-pdf-viewer/search"),n=require("@react-pdf-viewer/page-navigation"),o=require("@react-pdf-viewer/zoom"),i=require("@react-pdf-viewer/highlight");exports.PdfHighlightControls=function(u,a,c,l,s,g){var p=t.useState(0),f=p[0],h=p[1],v=t.useRef(!1),d=t.useState(0),m=d[0],y=d[1];t.useRef([]);var _=function(e){if(!e)return[];return e.replace(/\]\s*\n\s*\(/g,"](").split(/\n+/).map(function(e){var t=e.trim(),r=(t=(t=t.replace(/[\u200B-\u200D\uFEFF]/g,"").replace(/[\u00A0\u2009\u202F]/g," ")).replace(/^[-•]\s+/,"")).match(/^((\d+(?:\.\d+)*[.)]?)|[A-Za-z][.)]|\([A-Za-z0-9]+\)|(?:i|ii|iii|iv|v|vi|vii|viii|ix|x)[.)])\s*/i);return r?t.slice(r[0].length).trim():t}).flatMap(function(e){var t=e.match(/^\s*\|(.+)\|\s*$/);return t?t[1].split("|").map(function(e){return e.trim()}).filter(Boolean):[e]}).map(function(e){return e.replace(/&[#\w]+;/g,function(e){return t=e,(r=document.createElement("textarea")).innerHTML=t,r.value;var t,r}).replace(/<br\s*\/?>/gi,"\n").replace(/\[([^\]]+)\]\(([^)]+)\)/g,"$1").replace(/[^\S\n]+/g," ").trim()}).flatMap(function(e){return e.split(/\n+/)}).flatMap(function(e){for(var t,r=[],n=/([*_]{1,3})([^*_]+)\1|([*_]{1,3})/g,o=0;null!==(t=n.exec(e));){var i=e.slice(o,t.index).trim();i&&r.push(i),t[2]&&r.push(t[2].trim()),o=t.index+t[0].length}var u=e.slice(o).trim();return u&&r.push(u),r.flatMap(function(e){return e.split(/[\u2013\u2014-]/g)}).flatMap(function(e){return e.split(/\n+/)}).map(function(e){return e.replace(/[*_]+/g,"").replace(/`([^`]+)`/g,"$1").replace(/[^\S\n]+/g," ").trim()})})},x=Object.keys(a).map(Number).sort(function(e,t){return e-t}),T=t.useMemo(function(){return s?g.length:s?0:Object.values(a).filter(function(e){return e>0}).length},[g,a]),b=function(e){if(c.current){var t=c.current.querySelectorAll(".rpv-search__highlights"),r=new Set;t.forEach(function(t){var n=t.getAttribute("data-testid"),o=parseInt((null==n?void 0:n.replace("search__highlights-",""))||"-1"),i=t.querySelectorAll(".rpv-search__highlight");o===e&&(i.forEach(function(e){var t=e,n=(t.getAttribute("title")||"").toLowerCase(),o=t.style.top,i="".concat(n,"_#$_").concat(o);r.has(i)?t.style.display="none":(r.add(i),t.style.display="")}),console.groupCollapsed("[debug: PDF highlight text]"),console.log("input->",u),console.log("processed text->",q),console.groupEnd())})}},I=function(e){c.current&&c.current.querySelectorAll(".rpv-search__highlights").forEach(function(t){var r=t.getAttribute("data-testid"),n=parseInt((null==r?void 0:r.replace(/search__highlights-/g,""))||"-1"),o=t.querySelectorAll(".rpv-search__highlight");e.has(n)||o.forEach(function(e){e.style.display="none"})})},q=u.map(function(e){return _(e)}).flat(),j=r.searchPlugin({keyword:q}),S=n.pageNavigationPlugin(),P=o.zoomPlugin(),w=j.jumpToMatch,A=S.jumpToPage,B=P.zoomTo,M=P.ZoomInButton,C=P.ZoomOutButton,E=P.ZoomPopover,F=i.highlightPlugin({renderHighlights:function(t){return e.jsx(e.Fragment,{children:g.filter(function(e){return e.pageNumber?e.pageNumber-1===t.pageIndex:e.pageIndex===t.pageIndex}).map(function(t,r){var n=g.findIndex(function(e){return e.pageIndex===t.pageIndex&&e.top===t.top&&e.left===t.left})===m;return e.jsx("div",{style:{position:"absolute",left:"".concat(t.left,"%"),top:"".concat(t.top,"%"),width:"".concat(t.width,"%"),height:"".concat(t.height,"%"),background:n?"#F6D739":"yellow",opacity:n?.7:.4,transition:"background 0.2s, opacity 0.2s"}},r)})})}}),H=function(){if(!v.current)try{w(0),v.current=!0;var e=g[0];e&&s&&Z(e.pageIndex,e.top)}catch(e){requestAnimationFrame(H)}},O=function(e,t){if(c.current&&c.current.querySelector(".rpv-core__viewer")){var r=-1,n=function(){var o,i,u=null===(o=c.current)||void 0===o?void 0:o.querySelector(".rpv-core__inner-pages");if(u){if(u.scrollTop!==r)return r=u.scrollTop,void setTimeout(n,100);var a=null===(i=c.current)||void 0===i?void 0:i.querySelector('[data-testid="core__page-layer-'.concat(e,'"]'));if(a){var l=a.querySelectorAll(".rpv-search__highlight")[t];if(l){var s=u.getBoundingClientRect(),g=l.getBoundingClientRect(),p=u.scrollTop+(g.top-s.top)-u.clientHeight/2+g.height/2;u.scrollTo({top:p,behavior:"smooth"})}}}};setTimeout(n,300)}},Z=function(e,t){if(c.current){var r=0,n=function(){var o,i;if(!(++r>60)){var u=null===(o=c.current)||void 0===o?void 0:o.querySelector(".rpv-core__inner-pages");if(u){var a=null===(i=c.current)||void 0===i?void 0:i.querySelector('[data-testid="core__page-layer-'.concat(e,'"]'));if(a){var l=a.getBoundingClientRect();if(0!==l.height){var s=u.getBoundingClientRect(),g=t/100*l.height,p=l.top-s.top+g;u.scrollTo({top:u.scrollTop+p-40,behavior:"smooth"})}else setTimeout(n,100)}else setTimeout(n,100)}else setTimeout(n,100)}};setTimeout(n,100)}},k=t.useMemo(function(){var e={};return x.forEach(function(t,r){var n=a[t];n>0&&(e[n]||(e[n]=[]),e[n].push(r))}),e},[x,a]),z=function(e){var t=a[x[e]];return(k[t]||[]).indexOf(e)};return{setHighlightIndex:h,highlightIndex:f,cursorIndex:m,setCursorIndex:y,orderedKeys:x,totalHighlights:T,getValidPosition:function(e){if(s)return e+1;if(!a)return 0;for(var t=0,r=0;r<=e;r++)a[x[r]]>0&&t++;return t},tryJump:H,jumpToPage:A,zoomTo:B,hideNonTargetHighlights:I,deduplicateHighlights:b,scrollToCoord:Z,plugins:[s?F:j,S,P],controls:{ZoomInButton:M,ZoomOutButton:C,ZoomPopover:E,goToNext:function(){if(s&&g)for(var e=function(e){var t=g[e];return y(e),A(t.pageIndex),setTimeout(function(){Z(t.pageIndex,t.top)},400),{value:void 0}},t=m+1;t<g.length;t++){var r=e(t);if("object"==typeof r)return r.value}else{var n=function(e){var t=x[e];if(a[t]>0){var r=a[t]-1,n=z(e);return y(e),A(a[t]-1),O(r,n),setTimeout(function(){b(r)},500),1===Object.keys(a).length&&I(l),{value:void 0}}};for(t=m+1;t<x.length;t++){var o=n(t);if("object"==typeof o)return o.value}}},goToPrevious:function(){if(s&&g)for(var e=function(e){var t=g[e];return y(e),A(t.pageIndex),setTimeout(function(){Z(t.pageIndex,t.top)},400),{value:void 0}},t=m-1;t>=0;t--){var r=e(t);if("object"==typeof r)return r.value}else{var n=function(e){var t=x[e];if(a[t]>0){var r=a[t]-1,n=z(e);return y(e),A(a[t]-1),O(r,n),setTimeout(function(){b(r)},500),1===Object.keys(a).length&&I(l),{value:void 0}}};for(t=m-1;t>=0;t--){var o=n(t);if("object"==typeof o)return o.value}}}}}};
|
|
2
2
|
//# sourceMappingURL=usePdfHighlight.js.map
|
|
@@ -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(".TableCitationContent-module_container__OfivB{background-color:var(--cite-bg-color,#fff);border:1px solid var(--cite-border-color,#e5e7eb);display:flex;flex-direction:column;font-family:var(--cite-font-family,Inter,system-ui,sans-serif);height:100%;min-height:200px;width:100%}.TableCitationContent-module_header__ANgC5{align-items:center;border-bottom:1px solid var(--cite-border-color,#e5e7eb);display:flex;justify-content:space-between;padding:.5rem 1rem}.TableCitationContent-module_title__UzB8i{color:var(--cite-text-primary,#1f2937);font-size:1.1rem;font-weight:500;margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.TableCitationContent-module_headerRight__GLyqb{align-items:center;display:flex;gap:1rem}.TableCitationContent-module_divider__SYxWE{align-self:stretch;background-color:var(--cite-border-color,#e5e7eb);margin-bottom:-.5rem;margin-top:-.5rem;width:1px}.TableCitationContent-module_closeBtn__lTrT4{align-items:center;color:var(--cite-text-secondary,#6b7280);cursor:pointer;display:flex;transition:opacity .2s}.TableCitationContent-module_ccloseBtn__Gp3l5:hover{opacity:.7}.TableCitationContent-
|
|
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(".TableCitationContent-module_container__OfivB{background-color:var(--cite-bg-color,#fff);border:1px solid var(--cite-border-color,#e5e7eb);display:flex;flex-direction:column;font-family:var(--cite-font-family,Inter,system-ui,sans-serif);height:100%;min-height:200px;overflow:hidden;width:100%}.TableCitationContent-module_header__ANgC5{align-items:center;border-bottom:1px solid var(--cite-border-color,#e5e7eb);display:flex;justify-content:space-between;padding:.5rem 1rem}.TableCitationContent-module_title__UzB8i{color:var(--cite-text-primary,#1f2937);font-size:1.1rem;font-weight:500;margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.TableCitationContent-module_headerRight__GLyqb{align-items:center;display:flex;gap:1rem}.TableCitationContent-module_divider__SYxWE{align-self:stretch;background-color:var(--cite-border-color,#e5e7eb);margin-bottom:-.5rem;margin-top:-.5rem;width:1px}.TableCitationContent-module_closeBtn__lTrT4{align-items:center;color:var(--cite-text-secondary,#6b7280);cursor:pointer;display:flex;transition:opacity .2s}.TableCitationContent-module_ccloseBtn__Gp3l5:hover{opacity:.7}.TableCitationContent-module_tableScroll__Gv2KN{flex:1;overflow:auto;padding:.75rem 1rem}.TableCitationContent-module_table__ZIHBi{border-collapse:collapse;font-size:.875rem;min-width:100%;width:max-content}.TableCitationContent-module_table__ZIHBi td,.TableCitationContent-module_table__ZIHBi th{border:1px solid var(--cite-border-color,#e5e7eb);padding:.5rem .75rem}.TableCitationContent-module_table__ZIHBi th{background-color:var(--cite-header-bg,#f9fafb);color:var(--cite-text-header,#374151);font-weight:600;position:sticky;top:0}.TableCitationContent-module_highlightCell__1RESY{background-color:var(--cite-highlight-color,#f7ef9e)!important}.TableCitationContent-module_failedCell__-Q2WX{background-color:var(--cite-error-bg,#fee2e2);color:var(--cite-error-text,#991b1b)}.TableCitationContent-module_actions__yvyTj{align-items:center;display:flex;gap:.5rem}"));const o=document.head||document.getElementsByTagName("head")[0]||document.documentElement;o&&o.appendChild(e)}(),exports.default={container:"TableCitationContent-module_container__OfivB",header:"TableCitationContent-module_header__ANgC5",title:"TableCitationContent-module_title__UzB8i",headerRight:"TableCitationContent-module_headerRight__GLyqb",divider:"TableCitationContent-module_divider__SYxWE",closeBtn:"TableCitationContent-module_closeBtn__lTrT4",ccloseBtn:"TableCitationContent-module_ccloseBtn__Gp3l5",tableScroll:"TableCitationContent-module_tableScroll__Gv2KN",table:"TableCitationContent-module_table__ZIHBi",highlightCell:"TableCitationContent-module_highlightCell__1RESY",failedCell:"TableCitationContent-module_failedCell__-Q2WX",actions:"TableCitationContent-module_actions__yvyTj"};
|
|
2
2
|
//# sourceMappingURL=TableCitationContent.module.css.js.map
|
package/dist/cjs/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./features/CodeCitation/CodeCitation.js"),t=require("./features/ProjectAccordion/ProjectAccordion.js"),i=require("./features/BookCitation/BookCitation.js"),r=require("./features/Bookemon/Bookemon.js"),o=require("./features/PdfEditorCitation/PdfEditorCitation.js"),a=require("./features/CitationRenderer/CitationRenderer.js"),n=require("./features/CitationRenderer/MarkdownRenderer.js"),s=require("./features/CodeCitation/_components/CodeEditor.js"),C=require("./features/PaginatedTable/PaginatedTable.js"),u=require("./features/CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.js"),d=require("./features/ChatCitation/ChatCitationRenderer.js"),f=require("./features/CognitiveDecisioning/CognitiveDecisioningWrapper.js"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./features/CodeCitation/CodeCitation.js"),t=require("./features/ProjectAccordion/ProjectAccordion.js"),i=require("./features/BookCitation/BookCitation.js"),r=require("./features/Bookemon/Bookemon.js"),o=require("./features/PdfEditorCitation/PdfEditorCitation.js"),a=require("./features/CitationRenderer/CitationRenderer.js"),n=require("./features/CitationRenderer/MarkdownRenderer.js"),s=require("./features/CodeCitation/_components/CodeEditor.js"),C=require("./features/PaginatedTable/PaginatedTable.js"),u=require("./features/CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.js"),d=require("./features/ChatCitation/ChatCitationRenderer.js"),f=require("./features/CognitiveDecisioning/CognitiveDecisioningWrapper.js"),l=require("./features/PdfViewer/PdfViewer.js"),p=require("./features/CognitiveDecisioning/FaqCitation/FaqCitation.js"),q=require("./features/RequirementAiCitations/ImageCitation/ImageCitationContent.js"),g=require("./features/RequirementAiCitations/VideoCitation/VideoCitationContent.js"),x=require("./features/RequirementAiCitations/FileCitation/FileCitationContent.js"),j=require("./features/RequirementAiCitations/WebCitation/WebCitationWithImageContent.js"),c=require("./features/MarkdownWithImageCitation/MarkdownWithImageCitation.js"),R=require("./features/RequirementAiCitations/AiReasoning/AiReasoningCitation.js"),E=require("./features/TableCitation/TableCitationContent.js"),m=require("./features/CitationViewer/CitationsViewer.js"),D=require("./features/ExcelCitation/ExcelCitations.js"),T=require("./features/ScannedDocCitation/ScannedDocCitation.js"),A=require("./features/ChatDrawer/ChatDrawer.js"),I=require("./features/ChatDrawer/constants/ChatDrawer.js");exports.CodeCitation=e.default,exports.ProjectAccordian=t.default,exports.BookCitation=i.default,exports.Bookemon=r.default,exports.PdfCitation=o.PdfEditorCitation,exports.CitationRenderer=a.default,exports.MarkdownRenderer=n.default,Object.defineProperty(exports,"DiagnosticSeverity",{enumerable:!0,get:function(){return s.DiagnosticSeverity}}),exports.PaginatedTable=C.default,exports.NonWebReasoningComponent=u.default,exports.ChatCitation=d.default,exports.CognitiveDecisioningCard=f.default,exports.PdfViewer=l.default,exports.FaqCitation=p.default,exports.ImageCitationContent=q.default,exports.VideoCitationContent=g.default,exports.FileCitationContent=x.default,exports.WebCitationWithImageContent=j.default,exports.MarkdownWithImageCitation=c.default,exports.AiReasoningCitation=R.default,exports.TableCitationContent=E.default,exports.CitationsViewer=m.default,exports.ExcelCitation=D.default,exports.ScannedDocCitation=T.default,exports.ChatDrawer=A.default,exports.FILE_INGESTION_STATUS=I.FILE_INGESTION_STATUS,exports.SUMMARY_EXPAND_HEIGHT_NUDGE=I.SUMMARY_EXPAND_HEIGHT_NUDGE,exports.TRUNCATE_THRESHOLD=I.TRUNCATE_THRESHOLD;
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as e}from"tslib";import{jsx as i,jsxs as t}from"react/jsx-runtime";import n,{useState as o,useMemo as r,useCallback as d}from"react";import{FileText as l,ChevronUp as a,ChevronDown as p,ThumbsDown as s}from"lucide-react";import{transformContractComparisons as c}from"./utils/helpers.js";import x from"react-markdown";var h=function(n){var o=n.type,r=n.label,d={display:"inline-flex",alignItems:"center",gap:"4px",whiteSpace:"nowrap",borderRadius:"9999px",padding:"4px 12px",fontSize:"12px",fontWeight:600};switch(o){case"similarity":return i("span",e({style:e(e({},d),{border:"1px solid #C4B5FD",backgroundColor:"#F5F3FF",color:"#6D28D9"})},{children:r}));case"no_deviation":return i("span",e({style:e(e({},d),{border:"1px solid #A7F3D0",backgroundColor:"#ECFDF3",color:"#027A48"})},{children:r}));case"deviation":return t("span",e({style:e(e({},d),{gap:"6px",border:"1px solid #FECACA",backgroundColor:"#FEF2F2",color:"#DC2626"})},{children:[r,i("span",e({style:{borderRadius:"9999px",backgroundColor:"#FEE2E2",padding:"2px",display:"flex",alignItems:"center",justifyContent:"center"}},{children:i(s,{style:{width:"12px",height:"12px"}})})),i(p,{style:{width:"12px",height:"12px",color:"#DC2626"}})]}));default:return null}};function u(t,n,o){return t&&t.length>0?i("div",e({style:{display:"flex",flexDirection:"column",gap:"8px"}},{children:t.map(function(t){return i("p",e({style:{fontSize:"13px",lineHeight:"1.625",color:"#374151",margin:0}},{children:i(x,e({components:o},{children:t.text}))}),t.id)})})):n||i("p",e({style:{fontSize:"13px",fontStyle:"italic",color:"#9CA3AF",margin:0}},{children:"No content available"}))}var g=function(s){var g=s.leftDocumentName,f=void 0===g?"Uploaded Contract":g,F=s.rightDocumentName,
|
|
1
|
+
import{__assign as e}from"tslib";import{jsx as i,jsxs as t}from"react/jsx-runtime";import n,{useState as o,useMemo as r,useCallback as d}from"react";import{FileText as l,ChevronUp as a,ChevronDown as p,ThumbsDown as s}from"lucide-react";import{transformContractComparisons as c}from"./utils/helpers.js";import x from"react-markdown";var h=function(n){var o=n.type,r=n.label,d={display:"inline-flex",alignItems:"center",gap:"4px",whiteSpace:"nowrap",borderRadius:"9999px",padding:"4px 12px",fontSize:"12px",fontWeight:600};switch(o){case"similarity":return i("span",e({style:e(e({},d),{border:"1px solid #C4B5FD",backgroundColor:"#F5F3FF",color:"#6D28D9"})},{children:r}));case"no_deviation":return i("span",e({style:e(e({},d),{border:"1px solid #A7F3D0",backgroundColor:"#ECFDF3",color:"#027A48"})},{children:r}));case"deviation":return t("span",e({style:e(e({},d),{gap:"6px",border:"1px solid #FECACA",backgroundColor:"#FEF2F2",color:"#DC2626"})},{children:[r,i("span",e({style:{borderRadius:"9999px",backgroundColor:"#FEE2E2",padding:"2px",display:"flex",alignItems:"center",justifyContent:"center"}},{children:i(s,{style:{width:"12px",height:"12px"}})})),i(p,{style:{width:"12px",height:"12px",color:"#DC2626"}})]}));default:return null}};function u(t,n,o){return t&&t.length>0?i("div",e({style:{display:"flex",flexDirection:"column",gap:"8px"}},{children:t.map(function(t){return i("p",e({style:{fontSize:"13px",lineHeight:"1.625",color:"#374151",margin:0}},{children:i(x,e({components:o},{children:t.text}))}),t.id)})})):n||i("p",e({style:{fontSize:"13px",fontStyle:"italic",color:"#9CA3AF",margin:0}},{children:"No content available"}))}var g=function(s){var g=s.leftDocumentName,f=void 0===g?"Uploaded Contract":g,F=s.rightDocumentName,y=void 0===F?"Template":F,b=s.overallSimilarity,m=void 0===b?"Similarity":b,v=s.rawMappingData,C=s.deviationMappingData,w=s.defaultExpandedIds,E=void 0===w?[]:w,A=s.onSectionToggle,k=s.showDeviationBar,B=void 0===k||k,D=s.centerColumnWidth,z=void 0===D?15:D,I=s.className,S=void 0===I?"":I,T=s.style,R=c(v),N=o(function(){return new Set(null!=E?E:[R[0].id])}),j=N[0],W=N[1],L=r(function(){return{p:function(t){var n=t.children;return i("div",e({className:"inline",style:{padding:"8px 0px 8px 0px"}},{children:n}))},strong:function(t){var n=t.children;return i("strong",e({className:"font-semibold"},{children:n}))},em:function(t){var n=t.children;return i("em",e({className:"italic"},{children:n}))}}},[]),M=o(!0),_=M[0],G=M[1],H=d(function(e){W(function(i){var t=new Set(i),n=!t.has(e);return n?t.add(e):t.delete(e),null==A||A(e,n),t})},[A]),U=function(){return G(function(e){return!e})},q=B?"1fr minmax(80px, ".concat(z,"%) 1fr"):"1fr 1fr";return i("div",e({className:S,style:e({display:"flex",flexDirection:"column",height:"100%",width:"100%",overflow:"auto",fontFamily:"sans-serif",background:"#FFFFFF"},T)},{children:i("div",e({style:{width:"100%",padding:"24px 16px 40px"}},{children:t("div",e({style:{position:"relative",display:"grid",gridTemplateColumns:q,rowGap:"0px"}},{children:[_&&i("div",{style:{pointerEvents:"none",position:"absolute",top:56,bottom:0,left:0,width:B?"calc((100% - ".concat(z,"%) / 2)"):"50%",zIndex:0,border:"2px dashed #A0AAB4",borderTop:"none",borderRadius:"0 0 12px 12px",background:"#FFFFFF"}}),_&&i("div",{style:{pointerEvents:"none",position:"absolute",top:56,bottom:0,right:0,width:B?"calc((100% - ".concat(z,"%) / 2)"):"50%",zIndex:0,border:"1px solid #E5E7EB",borderTop:"none",background:"#F7F8FA",borderRadius:"0 0 12px 12px"}}),t("div",e({style:{position:"relative",zIndex:10,display:"flex",alignItems:"center",gap:"12px",padding:"0 16px",height:56,cursor:"pointer",background:"#F7F8FA",border:"2px dashed #A0AAB4",borderBottom:_?"1px dashed #A0AAB4":"2px dashed #A0AAB4",borderRadius:_?"12px 12px 0 0":"12px",transition:"border-radius 0.2s ease"},onClick:U},{children:[i(l,{style:{width:"18px",height:"18px",color:"#4B5563"}}),i("span",e({style:{flex:1,fontSize:"15px",fontWeight:700,color:"#19213D"}},{children:f})),i(_?a:p,{style:{width:"20px",height:"20px",color:"#6B7280"}})]})),B&&t("div",e({style:{position:"relative",zIndex:10,display:"flex",alignItems:"center",justifyContent:"center"}},{children:[i("div",{style:{position:"absolute",top:"50%",left:0,right:0,height:"1.5px",background:"#C4B5FD",opacity:.5}}),i("div",e({style:{position:"relative",zIndex:11,background:"#FFFFFF",padding:"0 8px"}},{children:i(h,{type:"similarity",label:m})}))]})),t("div",e({style:{position:"relative",zIndex:10,display:"flex",alignItems:"center",gap:"12px",padding:"0 16px",height:56,cursor:"pointer",background:"#F7F8FA",border:"1px solid #E5E7EB",borderRadius:_?"12px 12px 0 0":"12px",transition:"border-radius 0.2s ease"},onClick:U},{children:[i(l,{style:{width:"18px",height:"18px",color:"#5928ED"}}),i("span",e({style:{flex:1,fontSize:"15px",fontWeight:600,color:"#5928ED"}},{children:y})),i(_?a:p,{style:{width:"20px",height:"20px",color:"#6B7280"}})]})),_&&R.map(function(o,r){var d,l,s,c=j.has(o.id),g=0===r?"42px":"38px";return t(n.Fragment,{children:[i("div",e({style:{position:"relative",zIndex:10,padding:"12px 16px"}},{children:t("div",e({style:{borderRadius:"8px",border:"1px solid #E5E7EB",background:"#FFFFFF",boxShadow:"0 1px 2px rgba(0,0,0,0.05)"}},{children:[t("button",e({onClick:function(){return H(o.id)},style:{display:"flex",width:"100%",alignItems:"center",justifyContent:"space-between",padding:"16px",background:"transparent",border:"none",cursor:"pointer"}},{children:[i("span",e({style:{fontSize:"13px",fontWeight:600,color:"#111827"}},{children:i(x,e({components:L},{children:o.leftTitle}))})),i(c?a:p,{size:16,color:"#6B7280"})]})),c&&i("div",e({style:{borderTop:"1px solid #F3F4F6",padding:"16px"}},{children:u(null!==(d=o.leftClauses)&&void 0!==d?d:[],o.contentLeft,L)}))]}))})),B&&t("div",e({style:{position:"relative",zIndex:10}},{children:[i("div",{style:{position:"absolute",left:"-16px",right:"-16px",top:g,height:"1.5px",background:(s=C[r].matchType,"deviation"===s?"#FECACA":"no_deviation"===s?"#77BB9D":"#C4B5FD")}}),i("div",e({style:{position:"absolute",left:"50%",transform:"translate(-50%, -50%)",top:g,background:"#FFFFFF",padding:"0 8px"}},{children:i(h,{type:C[r].matchType,label:C[r].matchLabel})}))]})),i("div",e({style:{position:"relative",zIndex:10,padding:"12px 16px"}},{children:t("div",e({style:{borderRadius:"8px",border:"1px solid #E5E7EB",background:"#FFFFFF",boxShadow:"0 1px 2px rgba(0,0,0,0.05)"}},{children:[t("button",e({onClick:function(){return H(o.id)},style:{display:"flex",width:"100%",alignItems:"center",justifyContent:"space-between",padding:"16px",background:"transparent",border:"none",cursor:"pointer"}},{children:[i("span",e({style:{fontSize:"13px",fontWeight:600,color:"#111827"}},{children:i(x,e({components:L},{children:o.rightTitle}))})),i(c?a:p,{size:16,color:"#6B7280"})]})),c&&i("div",e({style:{borderTop:"1px solid #F3F4F6",padding:"16px"}},{children:u(null!==(l=o.rightClauses)&&void 0!==l?l:[],o.contentRight,L)}))]}))}))]},o.id)})]}))}))}))};export{g as AiRedLineCompare,g as default};
|
|
2
2
|
//# sourceMappingURL=AiRedLineCompare.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{__assign as e,__rest as i}from"tslib";import{jsxs as l,jsx as n}from"react/jsx-runtime";import o from"react";import r from"react-markdown";import t from"rehype-raw";import{renderCitationAIConfidenceDisplay as d}from"../RequirementAiCitations/components/CitationAIConfidenceDisplay.js";import a from"./MarkdownWithImageCitation.module.css.js";var s=function(s){var c,m,u,v,p=null===(c=null==s?void 0:s.closeCitationConfig)||void 0===c?void 0:c.CloseIcon,h=s.styles,f=function(e){if(!e)return"";var i=e.replace(/\t/g," ").split("\n"),l=i.filter(function(e){return e.trim().length>0}).reduce(function(e,i){var l=i.match(/^ */),n=l?l[0].length:0;return Math.min(e,n)},Number.POSITIVE_INFINITY);return i.map(function(e){return l&&Number.isFinite(l)?e.slice(l):e}).join("\n").trim()}(s.markdownContent);return l("div",e({className:a.container,style:null==h?void 0:h.container},{children:[l("div",e({className:a.header,style:null==h?void 0:h.header},{children:[l("div",e({className:a.titleGroup,style:null==h?void 0:h.titleGroup},{children:[n("h2",e({className:a.title,style:null==h?void 0:h.title},{children:(null==s?void 0:s.citationTitle)||"Markdown With Image"})),(null==s?void 0:s.timestamp)?n("span",e({className:a.timestamp,style:null==h?void 0:h.timestamp},{children:s.timestamp})):null]})),(null==s?void 0:s.closeCitationConfig)?l("div",e({className:a.headerRight,style:null==h?void 0:h.headerRight},{children:[d(s.relevanceScore,!1,null==h?void 0:h.aiConfidenceDisplayPill),n("div",{className:a.divider,style:null==h?void 0:h.divider}),p&&n("div",e({className:a.closeIconWrapper,style:null==h?void 0:h.closeIconWrapper,onClick:s.closeCitationConfig.handleCloseCitationPreview},{children:n(p,{className:a.closeIcon})}))]})):d(s.relevanceScore,!0,null==h?void 0:h.aiConfidenceDisplayPill)]})),n("div",e({className:a.content,style:null==h?void 0:h.content},{children:n("div",e({style:null===(m=null==h?void 0:h.markdown)||void 0===m?void 0:m.containerWrapper},{children:n("div",e({style:null===(u=null==h?void 0:h.markdown)||void 0===u?void 0:u.mainCard},{children:n("div",e({className:a.markdownBody,style:null===(v=null==h?void 0:h.markdown)||void 0===v?void 0:v.scrollArea},{children:n(r,e({rehypePlugins:[t],components:{p:function(l){l.node;var r=l.children,t=i(l,["node","children"]);return n("p",e({},t,{children:o.Children.map(r,function(i){var l,o,r;return"string"==typeof i?(o=i,(r=null===(l=null==h?void 0:h.markdown)||void 0===l?void 0:l.customHighlight)?n("span",e({style:r},{children:o})):o):i})}))},img:function(l){l.node;var o=i(l,["node"]);return n("div",e({className:a.imageWrapper,style:null==h?void 0:h.imageWrapper},{children:n("img",e({},o,{className:a.image,style:null==h?void 0:h.image,alt:o.alt||"Citation image"}))}))},ul:function(l){var o;l.node,l.ordered;var r=i(l,["node","ordered"]);return n("ul",e({},r,{style:null===(o=null==h?void 0:h.markdown)||void 0===o?void 0:o.list}))},ol:function(l){var o;l.node,l.ordered;var r=i(l,["node","ordered"]);return n("ol",e({},r,{style:null===(o=null==h?void 0:h.markdown)||void 0===o?void 0:o.list}))}}},{children:f}))}))}))}))}))]}))};export{s as default};
|
|
2
|
+
//# sourceMappingURL=MarkdownWithImageCitation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MarkdownWithImageCitation.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var o={container:"MarkdownWithImageCitation-module_container__IIipw",header:"MarkdownWithImageCitation-module_header__yELrX",titleGroup:"MarkdownWithImageCitation-module_titleGroup__NoGZT",title:"MarkdownWithImageCitation-module_title__2ol0g",timestamp:"MarkdownWithImageCitation-module_timestamp__TycMU",headerRight:"MarkdownWithImageCitation-module_headerRight__fKorY",divider:"MarkdownWithImageCitation-module_divider__DBf2T",closeIconWrapper:"MarkdownWithImageCitation-module_closeIconWrapper__alT2Q",closeIcon:"MarkdownWithImageCitation-module_closeIcon__KvaUd",content:"MarkdownWithImageCitation-module_content__omW6T",imageWrapper:"MarkdownWithImageCitation-module_imageWrapper__IuQaH",image:"MarkdownWithImageCitation-module_image__69FkI",markdownBody:"MarkdownWithImageCitation-module_markdownBody__Lf-gb"};!function(){if("undefined"==typeof document)return;const o=document.createElement("style");o.type="text/css";const e=window.__CSP_NONCE__||document.querySelector('meta[name="csp-nonce"]')?.content;e&&o.setAttribute("nonce",e),o.appendChild(document.createTextNode(".MarkdownWithImageCitation-module_container__IIipw{border:1px solid #e5e7eb;display:flex;flex-direction:column;height:100%;min-height:200px;position:relative;row-gap:1rem}.MarkdownWithImageCitation-module_header__yELrX{align-items:center;border-bottom:1px solid #e5e7eb;display:flex;flex-direction:row;justify-content:space-between;padding:.5rem 1rem;width:100%}.MarkdownWithImageCitation-module_titleGroup__NoGZT{display:flex;flex-direction:column;overflow:hidden;row-gap:.125rem}.MarkdownWithImageCitation-module_title__2ol0g{color:#1f2937;font-family:Inter,sans-serif;font-weight:400;margin-top:.5rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.MarkdownWithImageCitation-module_timestamp__TycMU{color:#6b7280;font-family:Inter,sans-serif;font-size:.75rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.MarkdownWithImageCitation-module_headerRight__fKorY{align-items:center;column-gap:1rem;display:flex;flex-direction:row}.MarkdownWithImageCitation-module_divider__DBf2T{align-self:stretch;background-color:#e5e7eb;margin-bottom:-.5rem;margin-top:-.5rem;width:1px}.MarkdownWithImageCitation-module_closeIconWrapper__alT2Q{cursor:pointer}.MarkdownWithImageCitation-module_closeIcon__KvaUd{color:#6b7280;height:24px;width:24px}.MarkdownWithImageCitation-module_content__omW6T{display:flex;flex-direction:column;gap:.875rem;padding:1rem 1rem 1.25rem}.MarkdownWithImageCitation-module_imageWrapper__IuQaH{background:#f8fafc;border:1px solid #e5e7eb;border-radius:12px;margin-bottom:1rem;margin-top:1rem;overflow:hidden;width:100%}.MarkdownWithImageCitation-module_image__69FkI{display:block;height:auto;max-width:100%;object-fit:cover;vertical-align:middle;width:100%}.MarkdownWithImageCitation-module_markdownBody__Lf-gb{color:#1f2937;font-family:Inter,sans-serif;font-size:.975rem;line-height:1.65}.MarkdownWithImageCitation-module_markdownBody__Lf-gb>:first-child{margin-top:0}.MarkdownWithImageCitation-module_markdownBody__Lf-gb>:last-child{margin-bottom:0}.MarkdownWithImageCitation-module_markdownBody__Lf-gb h1,.MarkdownWithImageCitation-module_markdownBody__Lf-gb h2,.MarkdownWithImageCitation-module_markdownBody__Lf-gb h3,.MarkdownWithImageCitation-module_markdownBody__Lf-gb h4,.MarkdownWithImageCitation-module_markdownBody__Lf-gb h5,.MarkdownWithImageCitation-module_markdownBody__Lf-gb h6{color:#111827;line-height:1.2;margin:0 0 .625rem}.MarkdownWithImageCitation-module_markdownBody__Lf-gb h1{font-size:2rem}.MarkdownWithImageCitation-module_markdownBody__Lf-gb h2{font-size:1.125rem;font-weight:700}.MarkdownWithImageCitation-module_markdownBody__Lf-gb h3{font-size:1rem;font-weight:700}.MarkdownWithImageCitation-module_markdownBody__Lf-gb p{margin:0 0 .875rem}.MarkdownWithImageCitation-module_markdownBody__Lf-gb ol,.MarkdownWithImageCitation-module_markdownBody__Lf-gb ul{margin:0 0 1rem;padding-left:1.25rem}.MarkdownWithImageCitation-module_markdownBody__Lf-gb li+li{margin-top:.25rem}.MarkdownWithImageCitation-module_markdownBody__Lf-gb strong{color:#111827}.MarkdownWithImageCitation-module_markdownBody__Lf-gb blockquote{border-left:3px solid #dbe3f0;color:#4b5563;margin:0 0 1rem;padding-left:.875rem}"));const t=document.head||document.getElementsByTagName("head")[0]||document.documentElement;t&&t.appendChild(o)}();export{o as default};
|
|
2
|
+
//# sourceMappingURL=MarkdownWithImageCitation.module.css.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MarkdownWithImageCitation.module.css.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as e}from"tslib";import{jsx as t,jsxs as i}from"react/jsx-runtime";import{SpecialZoomLevel as o}from"@react-pdf-viewer/core";import r from"./PdfContainer.js";import n from"./PdfToolbar.js";import{pdfStyles as s}from"./PdfStyle.js";import{PdfHighlightControls as l}from"./usePdfHighlight.js";import"@react-pdf-viewer/zoom/lib/styles/index.css";import"@react-pdf-viewer/page-navigation/lib/styles/index.css";import"@react-pdf-viewer/core/lib/styles/index.css";import"@react-pdf-viewer/search/lib/styles/index.css";import{useRef as a,useMemo as c}from"react";var u=function(u){var d,f=u.pdfUrl,
|
|
1
|
+
import{__assign as e}from"tslib";import{jsx as t,jsxs as i}from"react/jsx-runtime";import{SpecialZoomLevel as o}from"@react-pdf-viewer/core";import r from"./PdfContainer.js";import n from"./PdfToolbar.js";import{pdfStyles as s}from"./PdfStyle.js";import{PdfHighlightControls as l}from"./usePdfHighlight.js";import"@react-pdf-viewer/zoom/lib/styles/index.css";import"@react-pdf-viewer/page-navigation/lib/styles/index.css";import"@react-pdf-viewer/core/lib/styles/index.css";import"@react-pdf-viewer/search/lib/styles/index.css";import{useRef as a,useMemo as c}from"react";var u=function(u){var d,f=u.pdfUrl,g=u.highlightText,p=u.highlightPages,m=u.highlightCordinatePages,h=u.jumpToPageValue,v=void 0===h?0:h,y=u.pdfName,x=u.onClose,T=u.customStyles,C=u.customClasses,P=u.customIcons,b=u.useCoordinates,w=a(null),S=c(function(){if(b)return new Set(m.map(function(e){return e.pageIndex}));var e=new Set;return Object.values(p).forEach(function(t){t>0&&e.add(t-1)}),e},[p]),I=(d=g)&&0!==d.length?d.filter(function(e){return!d.some(function(t){return t!==e&&t.includes(e)})}):d,j=l(I,b?{}:p,w,S,b,b?m:[]),H=j.highlightIndex,A=j.cursorIndex,_=j.setCursorIndex,F=j.orderedKeys,V=j.totalHighlights,q=j.getValidPosition,N=j.tryJump,R=j.jumpToPage,z=j.zoomTo,B=j.plugins,U=j.controls,D=j.hideNonTargetHighlights,E=j.deduplicateHighlights,O=q(A);if(!f)return t("div",e({style:e(e({},s.emptyState),null==T?void 0:T.emptyState)},{children:"PDF is not available for this selection"}));return i("div",e({ref:w,className:(null==C?void 0:C.pdfViewerWrapper)||"",style:e(e(e({},s.pdfViewer),{display:"flex",flexDirection:"column",height:"100%",width:"100%",backgroundColor:"#FAFAFA"}),null==T?void 0:T.pdfViewer)},{children:[t(n,{highlightIndex:H,totalHighlights:V,controls:U,currentPosition:O,pdfName:y,onClose:x,pdfUrl:f,viewerRef:w,customStyles:T,customClasses:C,customIcons:P}),t(r,{pdfUrl:f,plugins:B,customStyles:T,onLoad:function(){if(z(o.ActualSize),v>0){var e=v-1,t=F[e],i=p[t],r=m[e];_(e),console.log(r,"cordinateTargetHighlight"),b&&r.pageIndex>0&&R(r.pageIndex),i>0&&(setTimeout(function(){D(S),E(i-1)},1e3),b||R(i-1))}requestAnimationFrame(function(){N(),b||function(){if(w.current){var e=v-1,t=F[e],i=p[t],o=i>0?i-1:0,r={};F.forEach(function(e,t){var i=p[e];i>0&&(r[i]||(r[i]=[]),r[i].push(t))});var n=(r[i]||[]).indexOf(e),s=0,l=function(){var e,t;if(!(++s>40)){var i=null===(e=w.current)||void 0===e?void 0:e.querySelector(".rpv-core__inner-pages");if(i){var r=null===(t=w.current)||void 0===t?void 0:t.querySelector('[data-testid="core__page-layer-'.concat(o,'"]'));if(r){var a=i.getBoundingClientRect(),c=r.getBoundingClientRect();if(c.top<a.bottom&&c.bottom>a.top){var u=r.querySelectorAll(".rpv-search__highlight")[n];if(u){var d=u.getBoundingClientRect(),f=i.scrollTop+(d.top-a.top)-i.clientHeight/2+d.height/2;i.scrollTo({top:f,behavior:"smooth"})}else setTimeout(l,100)}else setTimeout(l,100)}else setTimeout(l,100)}else setTimeout(l,100)}};setTimeout(l,500)}}()})},onPageChange:function(e){var t=e.currentPage;S.has(t)?(E(t),D(S)):D(S)}})]}))};export{u as default};
|
|
2
2
|
//# sourceMappingURL=PdfViewer.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{jsx as e,Fragment as t}from"react/jsx-runtime";import{useState as r,useRef as n,useMemo as o}from"react";import{searchPlugin as i}from"@react-pdf-viewer/search";import{pageNavigationPlugin as a}from"@react-pdf-viewer/page-navigation";import{zoomPlugin as u}from"@react-pdf-viewer/zoom";import{highlightPlugin as c}from"@react-pdf-viewer/highlight";var l=function(l,p,f,s,g,v){var h=r(0),d=h[0],m=h[1],y=n(!1),_=r(0),x=_[0],T=_[1];n([]);var b=function(e){if(!e)return[];return e.replace(/\]\s*\n\s*\(/g,"](").split(/\n+/).map(function(e){var t=e.trim(),r=(t=(t=t.replace(/[\u200B-\u200D\uFEFF]/g,"").replace(/[\u00A0\u2009\u202F]/g," ")).replace(/^[-•]\s+/,"")).match(/^((\d+(?:\.\d+)*[.)]?)|[A-Za-z][.)]|\([A-Za-z0-9]+\)|(?:i|ii|iii|iv|v|vi|vii|viii|ix|x)[.)])\s*/i);return r?t.slice(r[0].length).trim():t}).flatMap(function(e){var t=e.match(/^\s*\|(.+)\|\s*$/);return t?t[1].split("|").map(function(e){return e.trim()}).filter(Boolean):[e]}).map(function(e){return e.replace(/&[#\w]+;/g,function(e){return t=e,(r=document.createElement("textarea")).innerHTML=t,r.value;var t,r}).replace(/<br\s*\/?>/gi,"\n").replace(/\[([^\]]+)\]\(([^)]+)\)/g,"$1").replace(/[^\S\n]+/g," ").trim()}).flatMap(function(e){return e.split(/\n+/)}).flatMap(function(e){for(var t,r=[],n=/([*_]{1,3})([^*_]+)\1|([*_]{1,3})/g,o=0;null!==(t=n.exec(e));){var i=e.slice(o,t.index).trim();i&&r.push(i),t[2]&&r.push(t[2].trim()),o=t.index+t[0].length}var a=e.slice(o).trim();return a&&r.push(a),r.flatMap(function(e){return e.split(/[\u2013\u2014-]/g)}).flatMap(function(e){return e.split(/\n+/)}).map(function(e){return e.replace(/[*_]+/g,"").replace(/`([^`]+)`/g,"$1").replace(/[^\S\n]+/g," ").trim()})})},I=Object.keys(p).map(Number).sort(function(e,t){return e-t}),S=o(function(){return g?v.length:g?0:Object.values(p).filter(function(e){return e>0}).length},[v,p]),j=function(e){if(f.current){var t=f.current.querySelectorAll(".rpv-search__highlights"),r=new Set;t.forEach(function(t){var n=t.getAttribute("data-testid"),o=parseInt((null==n?void 0:n.replace("search__highlights-",""))||"-1"),i=t.querySelectorAll(".rpv-search__highlight");o===e&&(i.forEach(function(e){var t=e,n=(t.getAttribute("title")||"").toLowerCase(),o=t.style.top,i="".concat(n,"_#$_").concat(o);r.has(i)?t.style.display="none":(r.add(i),t.style.display="")}),console.groupCollapsed("[debug: PDF highlight text]"),console.log("input->",l),console.log("processed text->",A),console.groupEnd())})}},w=function(e){f.current&&f.current.querySelectorAll(".rpv-search__highlights").forEach(function(t){var r=t.getAttribute("data-testid"),n=parseInt((null==r?void 0:r.replace(/search__highlights-/g,""))||"-1"),o=t.querySelectorAll(".rpv-search__highlight");e.has(n)||o.forEach(function(e){e.style.display="none"})})},A=l.map(function(e){return b(e)}).flat(),q=i({keyword:A}),B=a(),C=u(),E=q.jumpToMatch,Z=B.jumpToPage,F=C.zoomTo,H=C.ZoomInButton,M=C.ZoomOutButton,O=C.ZoomPopover,P=c({renderHighlights:function(r){return e(t,{children:v.filter(function(e){return e.pageNumber?e.pageNumber-1===r.pageIndex:e.pageIndex===r.pageIndex}).map(function(t,r){var n=v.findIndex(function(e){return e.pageIndex===t.pageIndex&&e.top===t.top&&e.left===t.left})===x;return e("div",{style:{position:"absolute",left:"".concat(t.left,"%"),top:"".concat(t.top,"%"),width:"".concat(t.width,"%"),height:"".concat(t.height,"%"),background:n?"#F6D739":"yellow",opacity:n?.7:.4,transition:"background 0.2s, opacity 0.2s"}},r)})})}}),k=function(){if(!y.current)try{E(0),y.current=!0;var e=v[0];e&&g&&N(e.pageIndex,e.top)}catch(e){requestAnimationFrame(k)}},z=function(e,t){if(f.current&&f.current.querySelector(".rpv-core__viewer")){var r=-1,n=function(){var o,i,a=null===(o=f.current)||void 0===o?void 0:o.querySelector(".rpv-core__inner-pages");if(a){if(a.scrollTop!==r)return r=a.scrollTop,void setTimeout(n,100);var u=null===(i=f.current)||void 0===i?void 0:i.querySelector('[data-testid="core__page-layer-'.concat(e,'"]'));if(u){var c=u.querySelectorAll(".rpv-search__highlight")[t];if(c){var l=a.getBoundingClientRect(),p=c.getBoundingClientRect(),s=a.scrollTop+(p.top-l.top)-a.clientHeight/2+p.height/2;a.scrollTo({top:s,behavior:"smooth"})}}}};setTimeout(n,300)}},N=function(e,t){if(f.current){var r=0,n=function(){var o,i;if(!(++r>60)){var a=null===(o=f.current)||void 0===o?void 0:o.querySelector(".rpv-core__inner-pages");if(a){var u=null===(i=f.current)||void 0===i?void 0:i.querySelector('[data-testid="core__page-layer-'.concat(e,'"]'));if(u){var c=u.getBoundingClientRect();if(0!==c.height){var l=a.getBoundingClientRect(),p=t/100*c.height,s=c.top-l.top+p;a.scrollTo({top:a.scrollTop+s-40,behavior:"smooth"})}else setTimeout(n,100)}else setTimeout(n,100)}else setTimeout(n,100)}};setTimeout(n,100)}},R=o(function(){var e={};return I.forEach(function(t,r){var n=p[t];n>0&&(e[n]||(e[n]=[]),e[n].push(r))}),e},[I,p]),$=function(e){var t=p[I[e]];return(R[t]||[]).indexOf(e)};return{setHighlightIndex:m,highlightIndex:d,cursorIndex:x,setCursorIndex:T,orderedKeys:I,totalHighlights:S,getValidPosition:function(e){if(g)return e+1;if(!p)return 0;for(var t=0,r=0;r<=e;r++)p[I[r]]>0&&t++;return t},tryJump:k,jumpToPage:Z,zoomTo:F,hideNonTargetHighlights:w,deduplicateHighlights:j,scrollToCoord:N,plugins:[g?P:q,B,C],controls:{ZoomInButton:H,ZoomOutButton:M,ZoomPopover:O,goToNext:function(){if(g&&v)for(var e=function(e){var t=v[e];return T(e),Z(t.pageIndex),setTimeout(function(){N(t.pageIndex,t.top)},400),{value:void 0}},t=x+1;t<v.length;t++){var r=e(t);if("object"==typeof r)return r.value}else{var n=function(e){var t=I[e];if(p[t]>0){var r=p[t]-1,n=$(e);return T(e),Z(p[t]-1),z(r,n),setTimeout(function(){j(r)},500),1===Object.keys(p).length&&w(s),{value:void 0}}};for(t=x+1;t<I.length;t++){var o=n(t);if("object"==typeof o)return o.value}}},goToPrevious:function(){if(g&&v)for(var e=function(e){var t=v[e];return T(e),Z(t.pageIndex),setTimeout(function(){N(t.pageIndex,t.top)},400),{value:void 0}},t=x-1;t>=0;t--){var r=e(t);if("object"==typeof r)return r.value}else{var n=function(e){var t=I[e];if(p[t]>0){var r=p[t]-1,n=$(e);return T(e),Z(p[t]-1),z(r,n),setTimeout(function(){j(r)},500),1===Object.keys(p).length&&w(s),{value:void 0}}};for(t=x-1;t>=0;t--){var o=n(t);if("object"==typeof o)return o.value}}}}}};export{l as PdfHighlightControls};
|
|
2
2
|
//# sourceMappingURL=usePdfHighlight.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
var e={container:"TableCitationContent-module_container__OfivB",header:"TableCitationContent-module_header__ANgC5",title:"TableCitationContent-module_title__UzB8i",headerRight:"TableCitationContent-module_headerRight__GLyqb",divider:"TableCitationContent-module_divider__SYxWE",closeBtn:"TableCitationContent-module_closeBtn__lTrT4",ccloseBtn:"TableCitationContent-module_ccloseBtn__Gp3l5",
|
|
1
|
+
var e={container:"TableCitationContent-module_container__OfivB",header:"TableCitationContent-module_header__ANgC5",title:"TableCitationContent-module_title__UzB8i",headerRight:"TableCitationContent-module_headerRight__GLyqb",divider:"TableCitationContent-module_divider__SYxWE",closeBtn:"TableCitationContent-module_closeBtn__lTrT4",ccloseBtn:"TableCitationContent-module_ccloseBtn__Gp3l5",tableScroll:"TableCitationContent-module_tableScroll__Gv2KN",table:"TableCitationContent-module_table__ZIHBi",highlightCell:"TableCitationContent-module_highlightCell__1RESY",failedCell:"TableCitationContent-module_failedCell__-Q2WX",actions:"TableCitationContent-module_actions__yvyTj"};!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(".TableCitationContent-module_container__OfivB{background-color:var(--cite-bg-color,#fff);border:1px solid var(--cite-border-color,#e5e7eb);display:flex;flex-direction:column;font-family:var(--cite-font-family,Inter,system-ui,sans-serif);height:100%;min-height:200px;overflow:hidden;width:100%}.TableCitationContent-module_header__ANgC5{align-items:center;border-bottom:1px solid var(--cite-border-color,#e5e7eb);display:flex;justify-content:space-between;padding:.5rem 1rem}.TableCitationContent-module_title__UzB8i{color:var(--cite-text-primary,#1f2937);font-size:1.1rem;font-weight:500;margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.TableCitationContent-module_headerRight__GLyqb{align-items:center;display:flex;gap:1rem}.TableCitationContent-module_divider__SYxWE{align-self:stretch;background-color:var(--cite-border-color,#e5e7eb);margin-bottom:-.5rem;margin-top:-.5rem;width:1px}.TableCitationContent-module_closeBtn__lTrT4{align-items:center;color:var(--cite-text-secondary,#6b7280);cursor:pointer;display:flex;transition:opacity .2s}.TableCitationContent-module_ccloseBtn__Gp3l5:hover{opacity:.7}.TableCitationContent-module_tableScroll__Gv2KN{flex:1;overflow:auto;padding:.75rem 1rem}.TableCitationContent-module_table__ZIHBi{border-collapse:collapse;font-size:.875rem;min-width:100%;width:max-content}.TableCitationContent-module_table__ZIHBi td,.TableCitationContent-module_table__ZIHBi th{border:1px solid var(--cite-border-color,#e5e7eb);padding:.5rem .75rem}.TableCitationContent-module_table__ZIHBi th{background-color:var(--cite-header-bg,#f9fafb);color:var(--cite-text-header,#374151);font-weight:600;position:sticky;top:0}.TableCitationContent-module_highlightCell__1RESY{background-color:var(--cite-highlight-color,#f7ef9e)!important}.TableCitationContent-module_failedCell__-Q2WX{background-color:var(--cite-error-bg,#fee2e2);color:var(--cite-error-text,#991b1b)}.TableCitationContent-module_actions__yvyTj{align-items:center;display:flex;gap:.5rem}"));const o=document.head||document.getElementsByTagName("head")[0]||document.documentElement;o&&o.appendChild(e)}();export{e as default};
|
|
2
2
|
//# sourceMappingURL=TableCitationContent.module.css.js.map
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export{default as CodeCitation}from"./features/CodeCitation/CodeCitation.js";export{default as ProjectAccordian}from"./features/ProjectAccordion/ProjectAccordion.js";export{default as BookCitation}from"./features/BookCitation/BookCitation.js";export{default as Bookemon}from"./features/Bookemon/Bookemon.js";export{PdfEditorCitation as PdfCitation}from"./features/PdfEditorCitation/PdfEditorCitation.js";export{default as CitationRenderer}from"./features/CitationRenderer/CitationRenderer.js";export{default as MarkdownRenderer}from"./features/CitationRenderer/MarkdownRenderer.js";export{DiagnosticSeverity}from"./features/CodeCitation/_components/CodeEditor.js";export{default as PaginatedTable}from"./features/PaginatedTable/PaginatedTable.js";export{default as NonWebReasoningComponent}from"./features/CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.js";export{default as ChatCitation}from"./features/ChatCitation/ChatCitationRenderer.js";export{default as CognitiveDecisioningCard}from"./features/CognitiveDecisioning/CognitiveDecisioningWrapper.js";export{default as PdfViewer}from"./features/PdfViewer/PdfViewer.js";export{default as FaqCitation}from"./features/CognitiveDecisioning/FaqCitation/FaqCitation.js";export{default as ImageCitationContent}from"./features/RequirementAiCitations/ImageCitation/ImageCitationContent.js";export{default as VideoCitationContent}from"./features/RequirementAiCitations/VideoCitation/VideoCitationContent.js";export{default as FileCitationContent}from"./features/RequirementAiCitations/FileCitation/FileCitationContent.js";export{default as WebCitationWithImageContent}from"./features/RequirementAiCitations/WebCitation/WebCitationWithImageContent.js";export{default as AiReasoningCitation}from"./features/RequirementAiCitations/AiReasoning/AiReasoningCitation.js";export{default as TableCitationContent}from"./features/TableCitation/TableCitationContent.js";export{default as CitationsViewer}from"./features/CitationViewer/CitationsViewer.js";export{default as ExcelCitation}from"./features/ExcelCitation/ExcelCitations.js";export{default as ScannedDocCitation}from"./features/ScannedDocCitation/ScannedDocCitation.js";export{default as ChatDrawer}from"./features/ChatDrawer/ChatDrawer.js";export{FILE_INGESTION_STATUS,SUMMARY_EXPAND_HEIGHT_NUDGE,TRUNCATE_THRESHOLD}from"./features/ChatDrawer/constants/ChatDrawer.js";
|
|
1
|
+
export{default as CodeCitation}from"./features/CodeCitation/CodeCitation.js";export{default as ProjectAccordian}from"./features/ProjectAccordion/ProjectAccordion.js";export{default as BookCitation}from"./features/BookCitation/BookCitation.js";export{default as Bookemon}from"./features/Bookemon/Bookemon.js";export{PdfEditorCitation as PdfCitation}from"./features/PdfEditorCitation/PdfEditorCitation.js";export{default as CitationRenderer}from"./features/CitationRenderer/CitationRenderer.js";export{default as MarkdownRenderer}from"./features/CitationRenderer/MarkdownRenderer.js";export{DiagnosticSeverity}from"./features/CodeCitation/_components/CodeEditor.js";export{default as PaginatedTable}from"./features/PaginatedTable/PaginatedTable.js";export{default as NonWebReasoningComponent}from"./features/CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.js";export{default as ChatCitation}from"./features/ChatCitation/ChatCitationRenderer.js";export{default as CognitiveDecisioningCard}from"./features/CognitiveDecisioning/CognitiveDecisioningWrapper.js";export{default as PdfViewer}from"./features/PdfViewer/PdfViewer.js";export{default as FaqCitation}from"./features/CognitiveDecisioning/FaqCitation/FaqCitation.js";export{default as ImageCitationContent}from"./features/RequirementAiCitations/ImageCitation/ImageCitationContent.js";export{default as VideoCitationContent}from"./features/RequirementAiCitations/VideoCitation/VideoCitationContent.js";export{default as FileCitationContent}from"./features/RequirementAiCitations/FileCitation/FileCitationContent.js";export{default as WebCitationWithImageContent}from"./features/RequirementAiCitations/WebCitation/WebCitationWithImageContent.js";export{default as MarkdownWithImageCitation}from"./features/MarkdownWithImageCitation/MarkdownWithImageCitation.js";export{default as AiReasoningCitation}from"./features/RequirementAiCitations/AiReasoning/AiReasoningCitation.js";export{default as TableCitationContent}from"./features/TableCitation/TableCitationContent.js";export{default as CitationsViewer}from"./features/CitationViewer/CitationsViewer.js";export{default as ExcelCitation}from"./features/ExcelCitation/ExcelCitations.js";export{default as ScannedDocCitation}from"./features/ScannedDocCitation/ScannedDocCitation.js";export{default as ChatDrawer}from"./features/ChatDrawer/ChatDrawer.js";export{FILE_INGESTION_STATUS,SUMMARY_EXPAND_HEIGHT_NUDGE,TRUNCATE_THRESHOLD}from"./features/ChatDrawer/constants/ChatDrawer.js";
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AiRedLineCompareTest.d.ts","sourceRoot":"","sources":["../../../src/AiRedLineCompareTest.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AiRedLineCompareTest.d.ts","sourceRoot":"","sources":["../../../src/AiRedLineCompareTest.tsx"],"names":[],"mappings":"AAkKA,QAAA,MAAM,oBAAoB,+CAazB,CAAA;AAED,eAAe,oBAAoB,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MarkdownWithImageCitationTest.d.ts","sourceRoot":"","sources":["../../../src/MarkdownWithImageCitationTest.tsx"],"names":[],"mappings":"AAwBA,QAAA,MAAM,6BAA6B,+CA+BlC,CAAC;AAEF,eAAe,6BAA6B,CAAC"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
-
declare const PdfViewerTest: (
|
|
1
|
+
declare const PdfViewerTest: ({ useCoordinates }: {
|
|
2
|
+
useCoordinates?: boolean | undefined;
|
|
3
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
2
4
|
export default PdfViewerTest;
|
|
3
5
|
//# sourceMappingURL=PdfViewerTest.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PdfViewerTest.d.ts","sourceRoot":"","sources":["../../../src/PdfViewerTest.tsx"],"names":[],"mappings":"AAcA,QAAA,MAAM,aAAa
|
|
1
|
+
{"version":3,"file":"PdfViewerTest.d.ts","sourceRoot":"","sources":["../../../src/PdfViewerTest.tsx"],"names":[],"mappings":"AAcA,QAAA,MAAM,aAAa;;6CA2DlB,CAAA;AAED,eAAe,aAAa,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AiRedLineCompare.d.ts","sourceRoot":"","sources":["../../../../../src/features/AiRedLineCompare/AiRedLineCompare.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAIZ,KAAK,aAAa,EAEnB,MAAM,OAAO,CAAC;AAQf,OAAO,EAAU,sBAAsB,EAAa,MAAM,8BAA8B,CAAC;AAIzF,MAAM,WAAW,qBAAqB;IACpC,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,cAAc,EAAE,sBAAsB,EAAE,CAAC;IACzC,oBAAoB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,CAAA;IAC9C,kBAAkB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC9B,eAAe,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,KAAK,IAAI,CAAC;IAGxD,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAE3B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,aAAa,CAAC;CACvB;AAyHD,eAAO,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,qBAAqB,
|
|
1
|
+
{"version":3,"file":"AiRedLineCompare.d.ts","sourceRoot":"","sources":["../../../../../src/features/AiRedLineCompare/AiRedLineCompare.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAIZ,KAAK,aAAa,EAEnB,MAAM,OAAO,CAAC;AAQf,OAAO,EAAU,sBAAsB,EAAa,MAAM,8BAA8B,CAAC;AAIzF,MAAM,WAAW,qBAAqB;IACpC,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,cAAc,EAAE,sBAAsB,EAAE,CAAC;IACzC,oBAAoB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,CAAA;IAC9C,kBAAkB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC9B,eAAe,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,KAAK,IAAI,CAAC;IAGxD,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAE3B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,aAAa,CAAC;CACvB;AAyHD,eAAO,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,qBAAqB,CAwP5D,CAAC;AACF,eAAe,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
interface MarkdownWithImageCitationProps {
|
|
3
|
+
citationTitle?: string;
|
|
4
|
+
timestamp?: string;
|
|
5
|
+
relevanceScore?: number;
|
|
6
|
+
markdownContent: string;
|
|
7
|
+
closeCitationConfig?: {
|
|
8
|
+
CloseIcon: React.ElementType;
|
|
9
|
+
handleCloseCitationPreview: () => void;
|
|
10
|
+
};
|
|
11
|
+
styles?: {
|
|
12
|
+
container?: React.CSSProperties;
|
|
13
|
+
header?: React.CSSProperties;
|
|
14
|
+
titleGroup?: React.CSSProperties;
|
|
15
|
+
timestamp?: React.CSSProperties;
|
|
16
|
+
title?: React.CSSProperties;
|
|
17
|
+
headerRight?: React.CSSProperties;
|
|
18
|
+
divider?: React.CSSProperties;
|
|
19
|
+
closeIconWrapper?: React.CSSProperties;
|
|
20
|
+
content?: React.CSSProperties;
|
|
21
|
+
imageWrapper?: React.CSSProperties;
|
|
22
|
+
image?: React.CSSProperties;
|
|
23
|
+
markdown?: {
|
|
24
|
+
containerWrapper?: React.CSSProperties;
|
|
25
|
+
mainCard?: React.CSSProperties;
|
|
26
|
+
scrollArea?: React.CSSProperties;
|
|
27
|
+
customHighlight?: React.CSSProperties;
|
|
28
|
+
list?: React.CSSProperties;
|
|
29
|
+
};
|
|
30
|
+
aiConfidenceDisplayPill?: {
|
|
31
|
+
container?: React.CSSProperties;
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
}
|
|
35
|
+
declare const MarkdownWithImageCitation: React.FC<MarkdownWithImageCitationProps>;
|
|
36
|
+
export default MarkdownWithImageCitation;
|
|
37
|
+
//# sourceMappingURL=MarkdownWithImageCitation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MarkdownWithImageCitation.d.ts","sourceRoot":"","sources":["../../../../../src/features/MarkdownWithImageCitation/MarkdownWithImageCitation.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwB,MAAM,OAAO,CAAC;AAM7C,UAAU,8BAA8B;IACtC,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,eAAe,EAAE,MAAM,CAAC;IACxB,mBAAmB,CAAC,EAAE;QACpB,SAAS,EAAE,KAAK,CAAC,WAAW,CAAC;QAC7B,0BAA0B,EAAE,MAAM,IAAI,CAAC;KACxC,CAAC;IACF,MAAM,CAAC,EAAE;QACP,SAAS,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QAChC,MAAM,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QAC7B,UAAU,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QACjC,SAAS,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QAChC,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QAC5B,WAAW,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QAClC,OAAO,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QAC9B,gBAAgB,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QACvC,OAAO,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QAC9B,YAAY,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QACnC,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;QAC5B,QAAQ,CAAC,EAAE;YACT,gBAAgB,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;YACvC,QAAQ,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;YAC/B,UAAU,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;YACjC,eAAe,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;YACtC,IAAI,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;SAC5B,CAAC;QACF,uBAAuB,CAAC,EAAE;YACxB,SAAS,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;SACjC,CAAC;KACH,CAAC;CACH;AAkCD,QAAA,MAAM,yBAAyB,EAAE,KAAK,CAAC,EAAE,CAAC,8BAA8B,CAsGvE,CAAC;AAEF,eAAe,yBAAyB,CAAC"}
|
|
@@ -27,6 +27,7 @@ interface PdfViewerProps {
|
|
|
27
27
|
pdfUrl?: string;
|
|
28
28
|
highlightText: string[];
|
|
29
29
|
highlightPages?: any;
|
|
30
|
+
highlightCordinatePages: HighlightArea[];
|
|
30
31
|
jumpToPageValue?: number;
|
|
31
32
|
pdfName?: string;
|
|
32
33
|
onClose?: () => void;
|
|
@@ -34,7 +35,16 @@ interface PdfViewerProps {
|
|
|
34
35
|
customStyles?: CustomStylesType;
|
|
35
36
|
customClasses?: CustomClassesType;
|
|
36
37
|
customIcons?: CustomIconsType;
|
|
38
|
+
useCoordinates: boolean;
|
|
37
39
|
}
|
|
38
|
-
|
|
40
|
+
export type HighlightArea = {
|
|
41
|
+
pageIndex: number;
|
|
42
|
+
left: number;
|
|
43
|
+
top: number;
|
|
44
|
+
width: number;
|
|
45
|
+
height: number;
|
|
46
|
+
pageNumber?: number;
|
|
47
|
+
};
|
|
48
|
+
declare const PdfViewer: ({ pdfUrl, highlightText, highlightPages, highlightCordinatePages, jumpToPageValue, pdfName, onClose, customStyles, customClasses, customIcons, useCoordinates }: PdfViewerProps) => import("react/jsx-runtime").JSX.Element;
|
|
39
49
|
export default PdfViewer;
|
|
40
50
|
//# sourceMappingURL=PdfViewer.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PdfViewer.d.ts","sourceRoot":"","sources":["../../../../../src/features/PdfViewer/PdfViewer.tsx"],"names":[],"mappings":"AAKA,OAAO,6CAA6C,CAAC;AACrD,OAAO,wDAAwD,CAAC;AAChE,OAAO,6CAA6C,CAAC;AACrD,OAAO,+CAA+C,CAAC;AACvD,OAAO,KAA0B,MAAM,OAAO,CAAC;AAE/C,MAAM,MAAM,eAAe,GAAG;IAC5B,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,cAAc,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACjC,YAAY,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC/B,SAAS,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC7B,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,SAAS,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IAChC,MAAM,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IAC7B,cAAc,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IACrC,OAAO,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IAC9B,YAAY,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IACnC,UAAU,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;CAClC,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,UAAU,cAAc;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,aAAa,EAAE,MAAM,EAAE,CAAC;IACxB,cAAc,CAAC,EAAE,GAAG,CAAC;IACrB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,YAAY,CAAC,EAAE,gBAAgB,CAAC;IAChC,aAAa,CAAC,EAAE,iBAAiB,CAAC;IAClC,WAAW,CAAC,EAAE,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"PdfViewer.d.ts","sourceRoot":"","sources":["../../../../../src/features/PdfViewer/PdfViewer.tsx"],"names":[],"mappings":"AAKA,OAAO,6CAA6C,CAAC;AACrD,OAAO,wDAAwD,CAAC;AAChE,OAAO,6CAA6C,CAAC;AACrD,OAAO,+CAA+C,CAAC;AACvD,OAAO,KAA0B,MAAM,OAAO,CAAC;AAE/C,MAAM,MAAM,eAAe,GAAG;IAC5B,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,cAAc,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACjC,YAAY,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC/B,SAAS,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC7B,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,SAAS,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IAChC,MAAM,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IAC7B,cAAc,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IACrC,OAAO,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IAC9B,YAAY,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IACnC,UAAU,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;CAClC,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,UAAU,cAAc;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,aAAa,EAAE,MAAM,EAAE,CAAC;IACxB,cAAc,CAAC,EAAE,GAAG,CAAC;IACrB,uBAAuB,EAAG,aAAa,EAAE,CAAA;IACzC,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,YAAY,CAAC,EAAE,gBAAgB,CAAC;IAChC,aAAa,CAAC,EAAE,iBAAiB,CAAC;IAClC,WAAW,CAAC,EAAE,eAAe,CAAC;IAC9B,cAAc,EAAG,OAAO,CAAA;CACzB;AAED,MAAM,MAAM,aAAa,GAAG;IAC1B,SAAS,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,CAAC,EAAE,MAAM,CAAA;CACpB,CAAC;AAEF,QAAA,MAAM,SAAS,oKAYZ,cAAc,4CAoOhB,CAAC;AAEF,eAAe,SAAS,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
|
|
2
|
+
import { HighlightArea } from "./PdfViewer";
|
|
3
|
+
export declare const PdfHighlightControls: (highlightText: string[], highlightPages: Record<number, number>, viewerRef: React.RefObject<HTMLDivElement | null>, highlightPageSet: Set<number>, useCoordinates: boolean, highlightCordinatePages: HighlightArea[]) => {
|
|
3
4
|
setHighlightIndex: import("react").Dispatch<import("react").SetStateAction<number>>;
|
|
4
5
|
highlightIndex: number;
|
|
5
6
|
cursorIndex: number;
|
|
@@ -12,7 +13,8 @@ export declare const PdfHighlightControls: (highlightText: string[], highlightPa
|
|
|
12
13
|
zoomTo: (scale: number | import("@react-pdf-viewer/core").SpecialZoomLevel) => void;
|
|
13
14
|
hideNonTargetHighlights: (targetPages: Set<number>) => void;
|
|
14
15
|
deduplicateHighlights: (targetPage: number) => void;
|
|
15
|
-
|
|
16
|
+
scrollToCoord: (pageIndex: number, top: number) => void;
|
|
17
|
+
plugins: (import("@react-pdf-viewer/page-navigation").PageNavigationPlugin | import("@react-pdf-viewer/zoom").ZoomPlugin | import("@react-pdf-viewer/highlight").HighlightPlugin | import("@react-pdf-viewer/search").SearchPlugin)[];
|
|
16
18
|
controls: {
|
|
17
19
|
ZoomInButton: () => import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>;
|
|
18
20
|
ZoomOutButton: () => import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"usePdfHighlight.d.ts","sourceRoot":"","sources":["../../../../../src/features/PdfViewer/usePdfHighlight.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"usePdfHighlight.d.ts","sourceRoot":"","sources":["../../../../../src/features/PdfViewer/usePdfHighlight.tsx"],"names":[],"mappings":";AAIA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAM5C,eAAO,MAAM,oBAAoB,kBAChB,MAAM,EAAE,kBACP,OAAO,MAAM,EAAE,MAAM,CAAC,aAC3B,MAAM,SAAS,CAAC,cAAc,GAAG,IAAI,CAAC,oBAC9B,IAAI,MAAM,CAAC,kBACb,OAAO,2BACE,aAAa,EAAE;;;;;;;+BAiIP,MAAM,KAAG,MAAM;;;;2CA0PH,IAAI,MAAM,CAAC;wCAvKZ,MAAM;+BAkTjB,MAAM,OAAO,MAAM;;;;;;;;;CAiKtD,CAAC"}
|
|
@@ -16,6 +16,7 @@ export { default as ImageCitationContent } from "./features/RequirementAiCitatio
|
|
|
16
16
|
export { default as VideoCitationContent } from "./features/RequirementAiCitations/VideoCitation/VideoCitationContent";
|
|
17
17
|
export { default as FileCitationContent } from "./features/RequirementAiCitations/FileCitation/FileCitationContent";
|
|
18
18
|
export { default as WebCitationWithImageContent } from "./features/RequirementAiCitations/WebCitation/WebCitationWithImageContent";
|
|
19
|
+
export { default as MarkdownWithImageCitation } from "./features/MarkdownWithImageCitation/MarkdownWithImageCitation";
|
|
19
20
|
export { default as AiReasoningCitation } from "./features/RequirementAiCitations/AiReasoning/AiReasoningCitation";
|
|
20
21
|
export { default as TableCitationContent } from "./features/TableCitation/TableCitationContent";
|
|
21
22
|
export { default as CitationsViewer } from "./features/CitationViewer/CitationsViewer";
|
|
@@ -24,5 +25,4 @@ export { default as ScannedDocCitation } from "./features/ScannedDocCitation/Sca
|
|
|
24
25
|
export { default as ChatDrawer } from "./features/ChatDrawer/ChatDrawer";
|
|
25
26
|
export type { ChatDrawerProps } from "./features/ChatDrawer/types/ChatDrawer.types";
|
|
26
27
|
export { FILE_INGESTION_STATUS, SUMMARY_EXPAND_HEIGHT_NUDGE, TRUNCATE_THRESHOLD } from "./features/ChatDrawer/constants/ChatDrawer";
|
|
27
|
-
export { default as AiRedLineCompare } from "./features/AiRedLineCompare/AiRedLineCompare";
|
|
28
28
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,sCAAsC,CAAC;AAC/E,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAC3F,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,sCAAsC,CAAC;AAC/E,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EAAE,iBAAiB,IAAI,WAAW,EAAE,MAAM,gDAAgD,CAAC;AAClG,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAC3F,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAC3F,OAAO,EAAE,kBAAkB,IAAI,kBAAkB,EAAE,MAAM,gDAAgD,CAAC;AAC1G,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,0CAA0C,CAAC;AACrF,OAAO,EAAE,OAAO,IAAI,wBAAwB,EAAE,MAAM,iFAAiF,CAAC;AACtI,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,8CAA8C,CAAC;AACvF,OAAO,EAAE,OAAO,IAAI,wBAAwB,EAAE,MAAM,6DAA6D,CAAC;AAClH,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,gCAAgC,CAAC;AACtE,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,yDAAyD,CAAC;AAEjG,OAAO,EAAE,OAAO,IAAI,oBAAoB,EAAE,MAAM,sEAAsE,CAAC;AACvH,OAAO,EAAE,OAAO,IAAI,oBAAoB,EAAE,MAAM,sEAAsE,CAAC;AACvH,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,oEAAoE,CAAC;AACpH,OAAO,EAAE,OAAO,IAAI,2BAA2B,EAAE,MAAM,2EAA2E,CAAC;AACnI,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,mEAAmE,CAAC;AACnH,OAAO,EAAE,OAAO,IAAI,oBAAoB,EAAC,MAAM,+CAA+C,CAAC;AAC/F,OAAO,EAAE,OAAO,IAAI,eAAe,EAAE,MAAM,2CAA2C,CAAC;AACvF,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,yCAAyC,CAAC;AACnF,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,kDAAkD,CAAC;AACjG,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,kCAAkC,CAAC;AACzE,YAAY,EAAE,eAAe,EAAE,MAAM,8CAA8C,CAAC;AACpF,OAAO,EAAE,qBAAqB,EAAE,2BAA2B,EAAE,kBAAkB,EAAE,MAAM,4CAA4C,CAAC
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,sCAAsC,CAAC;AAC/E,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAC3F,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,sCAAsC,CAAC;AAC/E,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EAAE,iBAAiB,IAAI,WAAW,EAAE,MAAM,gDAAgD,CAAC;AAClG,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAC3F,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAC3F,OAAO,EAAE,kBAAkB,IAAI,kBAAkB,EAAE,MAAM,gDAAgD,CAAC;AAC1G,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,0CAA0C,CAAC;AACrF,OAAO,EAAE,OAAO,IAAI,wBAAwB,EAAE,MAAM,iFAAiF,CAAC;AACtI,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,8CAA8C,CAAC;AACvF,OAAO,EAAE,OAAO,IAAI,wBAAwB,EAAE,MAAM,6DAA6D,CAAC;AAClH,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,gCAAgC,CAAC;AACtE,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,yDAAyD,CAAC;AAEjG,OAAO,EAAE,OAAO,IAAI,oBAAoB,EAAE,MAAM,sEAAsE,CAAC;AACvH,OAAO,EAAE,OAAO,IAAI,oBAAoB,EAAE,MAAM,sEAAsE,CAAC;AACvH,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,oEAAoE,CAAC;AACpH,OAAO,EAAE,OAAO,IAAI,2BAA2B,EAAE,MAAM,2EAA2E,CAAC;AACnI,OAAO,EAAE,OAAO,IAAI,yBAAyB,EAAE,MAAM,gEAAgE,CAAC;AACtH,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,mEAAmE,CAAC;AACnH,OAAO,EAAE,OAAO,IAAI,oBAAoB,EAAC,MAAM,+CAA+C,CAAC;AAC/F,OAAO,EAAE,OAAO,IAAI,eAAe,EAAE,MAAM,2CAA2C,CAAC;AACvF,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,yCAAyC,CAAC;AACnF,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,kDAAkD,CAAC;AACjG,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,kCAAkC,CAAC;AACzE,YAAY,EAAE,eAAe,EAAE,MAAM,8CAA8C,CAAC;AACpF,OAAO,EAAE,qBAAqB,EAAE,2BAA2B,EAAE,kBAAkB,EAAE,MAAM,4CAA4C,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@viswa-test/test-citation",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.9",
|
|
4
4
|
"author": "Viswa Koduru",
|
|
5
5
|
"description": "",
|
|
6
6
|
"license": "MIT",
|
|
@@ -97,6 +97,11 @@
|
|
|
97
97
|
"require": "./dist/cjs/features/RequirementAiCitations/ImageCitation/ImageCitationContent.js",
|
|
98
98
|
"types": "./dist/types/src/features/RequirementAiCitations/ImageCitation/ImageCitationContent.d.ts"
|
|
99
99
|
},
|
|
100
|
+
"./MarkdownWithImageCitation": {
|
|
101
|
+
"import": "./dist/features/MarkdownWithImageCitation/MarkdownWithImageCitation.js",
|
|
102
|
+
"require": "./dist/cjs/features/MarkdownWithImageCitation/MarkdownWithImageCitation.js",
|
|
103
|
+
"types": "./dist/types/src/features/MarkdownWithImageCitation/MarkdownWithImageCitation.d.ts"
|
|
104
|
+
},
|
|
100
105
|
"./FileCitationContent": {
|
|
101
106
|
"import": "./dist/features/RequirementAiCitations/FileCitation/FileCitationContent.js",
|
|
102
107
|
"require": "./dist/cjs/features/RequirementAiCitations/FileCitation/FileCitationContent.js",
|
|
@@ -116,11 +121,6 @@
|
|
|
116
121
|
"import": "./dist/features/ReviewPanel/ReviewPanel.js",
|
|
117
122
|
"require": "./dist/cjs/features/ReviewPanel/ReviewPanel.js",
|
|
118
123
|
"types": "./dist/types/src/features/ReviewPanel/ReviewPanel.d.ts"
|
|
119
|
-
},
|
|
120
|
-
"./PdfViewer": {
|
|
121
|
-
"import": "./dist/features/AiRedLineCompare/AiRedLineCompare.js",
|
|
122
|
-
"require": "./dist/cjs/features/AiRedLineCompare/AiRedLineCompare.js",
|
|
123
|
-
"types": "./dist/types/src/features/AiRedLineCompare/AiRedLineCompare.d.ts"
|
|
124
124
|
}
|
|
125
125
|
},
|
|
126
126
|
"repository": {
|
|
@@ -185,17 +185,25 @@
|
|
|
185
185
|
"@react-pdf-viewer/page-navigation": "^3.12.0",
|
|
186
186
|
"@react-pdf-viewer/search": "^3.12.0",
|
|
187
187
|
"@react-pdf-viewer/zoom": "^3.12.0",
|
|
188
|
-
"highlight.js": "^11.11.1",
|
|
189
|
-
"pdfjs-dist": "^3.11.174",
|
|
190
|
-
"react-player": "^3.4.0",
|
|
191
|
-
"react-reader": "^2.0.13",
|
|
192
|
-
"wavesurfer.js": "^7.12.1",
|
|
193
188
|
"@rollup/plugin-commonjs": "28.0.2",
|
|
194
189
|
"@rollup/plugin-json": "6.1.0",
|
|
195
190
|
"@rollup/plugin-node-resolve": "13.3.0",
|
|
196
191
|
"@rollup/plugin-strip": "3.0.4",
|
|
197
192
|
"@rollup/plugin-url": "^8.0.2",
|
|
198
193
|
"@svgr/rollup": "8.1.0",
|
|
194
|
+
"@types/react": "17.0.83",
|
|
195
|
+
"@types/react-dom": "17.0.26",
|
|
196
|
+
"@types/react-router-dom": "5.3.3",
|
|
197
|
+
"@types/react-syntax-highlighter": "^15.5.13",
|
|
198
|
+
"@types/react-window": "^1.8.8",
|
|
199
|
+
"ajv": "8.12.0",
|
|
200
|
+
"ajv-keywords": "5.1.0",
|
|
201
|
+
"highlight.js": "^11.11.1",
|
|
202
|
+
"pdfjs-dist": "^3.11.174",
|
|
203
|
+
"react-player": "^3.4.0",
|
|
204
|
+
"react-reader": "^2.0.13",
|
|
205
|
+
"react-router-dom": "5.2.0",
|
|
206
|
+
"react-scripts": ">=5.0.1",
|
|
199
207
|
"rollup": "2.79.2",
|
|
200
208
|
"rollup-plugin-babel": "4.4.0",
|
|
201
209
|
"rollup-plugin-peer-deps-external": "2.2.4",
|
|
@@ -204,36 +212,28 @@
|
|
|
204
212
|
"rollup-plugin-terser": "7.0.2",
|
|
205
213
|
"rollup-plugin-typescript2": "0.36.0",
|
|
206
214
|
"rollup-plugin-visualizer": "5.12.0",
|
|
207
|
-
"typescript": "4.9.5",
|
|
208
215
|
"ts-loader": "9.5.1",
|
|
209
|
-
"
|
|
210
|
-
"
|
|
211
|
-
"@types/react-router-dom": "5.3.3",
|
|
212
|
-
"@types/react-syntax-highlighter": "^15.5.13",
|
|
213
|
-
"@types/react-window": "^1.8.8",
|
|
214
|
-
"ajv": "8.12.0",
|
|
215
|
-
"ajv-keywords": "5.1.0",
|
|
216
|
-
"react-scripts": ">=5.0.1",
|
|
217
|
-
"react-router-dom": "5.2.0",
|
|
216
|
+
"typescript": "4.9.5",
|
|
217
|
+
"wavesurfer.js": "^7.12.1",
|
|
218
218
|
"webpack-bundle-analyzer": "^4.10.2"
|
|
219
219
|
},
|
|
220
220
|
"peerDependencies": {
|
|
221
|
-
"react": ">=16.8.0 <19.0.0",
|
|
222
|
-
"react-dom": ">=16.8.0 <19.0.0",
|
|
223
|
-
"@mui/material": "^6.5.0",
|
|
224
221
|
"@emotion/react": "^11.13.5",
|
|
225
222
|
"@emotion/styled": "^11.13.0",
|
|
226
|
-
"
|
|
223
|
+
"@monaco-editor/react": "^4.7.0",
|
|
224
|
+
"@mui/icons-material": "^6.5.0",
|
|
225
|
+
"@mui/material": "^6.5.0",
|
|
227
226
|
"@react-pdf-viewer/core": "^3.12.0",
|
|
228
227
|
"@react-pdf-viewer/page-navigation": "^3.12.0",
|
|
229
228
|
"@react-pdf-viewer/search": "^3.12.0",
|
|
230
229
|
"@react-pdf-viewer/zoom": "^3.12.0",
|
|
231
|
-
"
|
|
230
|
+
"highlight.js": "^11.11.1",
|
|
231
|
+
"pdfjs-dist": "^3.11.174",
|
|
232
|
+
"react": ">=16.8.0 <19.0.0",
|
|
233
|
+
"react-dom": ">=16.8.0 <19.0.0",
|
|
232
234
|
"react-player": "^3.4.0",
|
|
233
|
-
"@monaco-editor/react": "^4.7.0",
|
|
234
235
|
"react-reader": "^2.0.13",
|
|
235
|
-
"
|
|
236
|
-
"@mui/icons-material": "^6.5.0"
|
|
236
|
+
"wavesurfer.js": "^7.12.1"
|
|
237
237
|
},
|
|
238
238
|
"peerDependenciesMeta": {
|
|
239
239
|
"@mui/icons-material": {
|
|
@@ -271,18 +271,19 @@
|
|
|
271
271
|
}
|
|
272
272
|
},
|
|
273
273
|
"dependencies": {
|
|
274
|
+
"@react-pdf-viewer/highlight": "^3.12.0",
|
|
275
|
+
"axios": "^1.7.9",
|
|
274
276
|
"dayjs": "^1.11.19",
|
|
275
277
|
"dompurify": "^3.3.1",
|
|
276
278
|
"lucide-react": "^0.562.0",
|
|
277
279
|
"pdf-collaborative-tool": "^0.7.0",
|
|
278
280
|
"react-markdown": "^8.0.7",
|
|
281
|
+
"react-resizable-panels": "^3.0.6",
|
|
279
282
|
"react-syntax-highlighter": "^15.6.1",
|
|
283
|
+
"react-virtualized-auto-sizer": "^1.0.26",
|
|
284
|
+
"react-window": "^1.8.11",
|
|
280
285
|
"rehype-raw": "^7.0.0",
|
|
281
|
-
"remark-gfm": "^4.0.1",
|
|
282
286
|
"remark-breaks": "^4.0.0",
|
|
283
|
-
"
|
|
284
|
-
"react-virtualized-auto-sizer": "^1.0.26",
|
|
285
|
-
"react-resizable-panels": "^3.0.6",
|
|
286
|
-
"axios": "^1.7.9"
|
|
287
|
+
"remark-gfm": "^4.0.1"
|
|
287
288
|
}
|
|
288
289
|
}
|