@viswa-test/test-citation 0.0.377 → 0.0.378

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.
Files changed (532) hide show
  1. package/dist/cjs/features/CognitiveCompare/CitationAnchor.js +1 -1
  2. package/dist/cjs/features/CognitiveCompare/CognitiveCompare.js +1 -1
  3. package/dist/cjs/features/CognitiveCompare/CognitiveComparehelpers.js +1 -1
  4. package/dist/cjs/features/CognitiveCompare/CognitivePopup.js +1 -1
  5. package/dist/cjs/features/CognitiveCompare/Guidelines/components/GuidelinePanel.js +1 -1
  6. package/dist/cjs/features/CognitiveCompare/Guidelines/components/WebGptPanel.js +1 -1
  7. package/dist/cjs/features/CognitiveCompare/Guidelines/utils/processGuidelinesMarkdown.js +1 -1
  8. package/dist/cjs/features/CognitiveCompare/components/SectionAccordion.js +1 -1
  9. package/dist/cjs/features/CognitiveCompare/components/SubSectionAccordion.js +1 -1
  10. package/dist/cjs/features/CognitiveCompare/hooks/memoizedMarkdown.js +1 -1
  11. package/dist/cjs/features/CognitiveCompare/hooks/useCompareData.js +1 -1
  12. package/dist/cjs/features/CognitiveCompare/hooks/useLinesCalculator.js +1 -1
  13. package/dist/cjs/features/CognitiveCompare/hooks/useSideBySide.js +1 -1
  14. package/dist/cjs/features/CognitiveInternalgptReasoning/CognitiveInternalgptCoreComponent.js +1 -1
  15. package/dist/cjs/features/GptWebCitation/GptWebCitation.js +1 -1
  16. package/dist/cjs/features/GptWebCitation/GptWebCitationImageCitation.js +1 -1
  17. package/dist/cjs/features/GptWebCitation/utils/fixedHeight.utils.js +1 -1
  18. package/dist/cjs/features/PdfViewer/PdfContainer.js +1 -1
  19. package/dist/cjs/features/PdfViewer/PdfStyle.js +1 -1
  20. package/dist/cjs/features/PdfViewer/PdfToolbar.js +1 -1
  21. package/dist/cjs/features/PdfViewer/PdfViewer.js +1 -1
  22. package/dist/cjs/features/RequirementAI/components/RequirementAIWrapper/RequirementAIWrapper.js +1 -1
  23. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/constants/updateTags.js +2 -0
  24. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/constants/updateTags.js.map +1 -0
  25. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/InitialHtml.js +1 -1
  26. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/ManualNode.js +1 -1
  27. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/ProtectTableCellBoundaries.js +2 -0
  28. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/ProtectTableCellBoundaries.js.map +1 -0
  29. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/UpdateNode.js +1 -1
  30. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/manualEditSerialization.js +2 -0
  31. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/manualEditSerialization.js.map +1 -0
  32. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/normalizeRedlineMarkdown.js +2 -0
  33. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/normalizeRedlineMarkdown.js.map +1 -0
  34. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownEmphasis.js +2 -0
  35. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownEmphasis.js.map +1 -0
  36. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownLineBreaks.js +2 -0
  37. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownLineBreaks.js.map +1 -0
  38. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownListFormatting.js +2 -0
  39. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownListFormatting.js.map +1 -0
  40. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveReviewBoundaryWhitespace.js +2 -0
  41. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveReviewBoundaryWhitespace.js.map +1 -0
  42. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveTableDelimiters.js +2 -0
  43. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveTableDelimiters.js.map +1 -0
  44. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/tableBoundaryRedlines.js +2 -0
  45. package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/utils/tableBoundaryRedlines.js.map +1 -0
  46. package/dist/cjs/features/RequirementAI/components/RichTextEditor/RichTextEditor.js +1 -1
  47. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/Avatar.css.js +2 -0
  48. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/Avatar.css.js.map +1 -0
  49. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/Avatar.js +2 -0
  50. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/Avatar.js.map +1 -0
  51. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsGroup.css.js +2 -0
  52. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsGroup.css.js.map +1 -0
  53. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsGroup.js +2 -0
  54. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsGroup.js.map +1 -0
  55. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsPopup.css.js +2 -0
  56. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsPopup.css.js.map +1 -0
  57. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsPopup.js +2 -0
  58. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsPopup.js.map +1 -0
  59. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/avatarUtils.js +2 -0
  60. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Avatar/avatarUtils.js.map +1 -0
  61. package/dist/cjs/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CitationAnchor.js +1 -1
  62. package/dist/cjs/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CognitiveComponent.js +1 -1
  63. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/DeviationSummary.js +1 -1
  64. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/HistoryMenu.js +1 -1
  65. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/ManualEditPopup.js +1 -1
  66. package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/RedlineStatusCard.js +1 -1
  67. package/dist/cjs/features/RequirementAI/components/UserStoryCard/UserStoryCard.js +1 -1
  68. package/dist/cjs/features/RequirementAI/components/UserStoryCard/UserStoryCard.module.css.js +1 -1
  69. package/dist/cjs/features/RequirementAI/components/UserStoryCard/cws/CwsEvent.js +1 -1
  70. package/dist/cjs/features/RequirementAI/components/UserStoryCard/cws/CwsEventProvider.js +1 -1
  71. package/dist/cjs/features/RequirementAI/components/UserStoryCard/cws/SocketManager.js +1 -1
  72. package/dist/cjs/features/RequirementAI/components/UserStoryCard/cws/useCwsEvent.js +1 -1
  73. package/dist/cjs/features/RequirementAI/components/ai-reasoning/AiReasonMarkdownWrapper.js +1 -1
  74. package/dist/cjs/features/RequirementAI/components/ai-reasoning/AiReasoningCitationContent.js +1 -1
  75. package/dist/cjs/features/RequirementAI/components/citations/file-citation/FileCitationContent.js +1 -1
  76. package/dist/cjs/features/RequirementAI/components/citations/file-citation/FileCitationContent.module.css.js +1 -1
  77. package/dist/cjs/features/RequirementAI/components/citations/file-citation/FileCitationRender.js +1 -1
  78. package/dist/cjs/features/RequirementAI/components/citations/readfile-citation/ReadFileCitationContent.js +1 -1
  79. package/dist/cjs/features/RequirementAI/components/lsc-reason-gap/CustomChatCrRedirection.js +1 -1
  80. package/dist/cjs/features/RequirementAI/components/lsc-reason-gap/GapFilterBlock.js +1 -1
  81. package/dist/cjs/features/RequirementAI/components/segment/Segment.js +1 -1
  82. package/dist/cjs/features/RequirementAI/components/segment/SegmentWrapper.js +1 -1
  83. package/dist/cjs/features/RequirementAI/components/userstory-approval-screen/UserStoryApprovalScreen.js +1 -1
  84. package/dist/cjs/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.js +1 -1
  85. package/dist/cjs/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.module.css.js +1 -1
  86. package/dist/cjs/features/RequirementAI/components/userstory-with-citation/components/InlineUpdatedComponent.js +1 -1
  87. package/dist/cjs/features/RequirementAI/components/userstory-with-citation/utils/inlineMarkdown.js +2 -0
  88. package/dist/cjs/features/RequirementAI/components/userstory-with-citation/utils/inlineMarkdown.js.map +1 -0
  89. package/dist/cjs/features/RequirementAI/hooks/useStreamContentHandler.js +1 -1
  90. package/dist/cjs/features/RequirementAI/utils/exponential-retry.js +2 -0
  91. package/dist/cjs/features/RequirementAI/utils/exponential-retry.js.map +1 -0
  92. package/dist/cjs/features/RequirementAI/utils/helpers.js +1 -1
  93. package/dist/cjs/features/RequirementAI/utils/proccess-stream.utils.js +1 -1
  94. package/dist/cjs/index.js +1 -1
  95. package/dist/cjs/service/redlineService.js +1 -1
  96. package/dist/cjs/utils/tagHelper.js +1 -1
  97. package/dist/features/CognitiveCompare/CitationAnchor.js +1 -1
  98. package/dist/features/CognitiveCompare/CognitiveCompare.js +1 -1
  99. package/dist/features/CognitiveCompare/CognitiveComparehelpers.js +1 -1
  100. package/dist/features/CognitiveCompare/CognitivePopup.js +1 -1
  101. package/dist/features/CognitiveCompare/Guidelines/components/GuidelinePanel.js +1 -1
  102. package/dist/features/CognitiveCompare/Guidelines/components/WebGptPanel.js +1 -1
  103. package/dist/features/CognitiveCompare/Guidelines/utils/processGuidelinesMarkdown.js +1 -1
  104. package/dist/features/CognitiveCompare/components/SectionAccordion.js +1 -1
  105. package/dist/features/CognitiveCompare/components/SubSectionAccordion.js +1 -1
  106. package/dist/features/CognitiveCompare/hooks/memoizedMarkdown.js +1 -1
  107. package/dist/features/CognitiveCompare/hooks/useCompareData.js +1 -1
  108. package/dist/features/CognitiveCompare/hooks/useLinesCalculator.js +1 -1
  109. package/dist/features/CognitiveCompare/hooks/useSideBySide.js +1 -1
  110. package/dist/features/CognitiveInternalgptReasoning/CognitiveInternalgptCoreComponent.js +1 -1
  111. package/dist/features/GptWebCitation/GptWebCitation.js +1 -1
  112. package/dist/features/GptWebCitation/GptWebCitationImageCitation.js +1 -1
  113. package/dist/features/GptWebCitation/utils/fixedHeight.utils.js +1 -1
  114. package/dist/features/PdfViewer/PdfContainer.js +1 -1
  115. package/dist/features/PdfViewer/PdfStyle.js +1 -1
  116. package/dist/features/PdfViewer/PdfToolbar.js +1 -1
  117. package/dist/features/PdfViewer/PdfViewer.js +1 -1
  118. package/dist/features/RequirementAI/components/RequirementAIWrapper/RequirementAIWrapper.js +1 -1
  119. package/dist/features/RequirementAI/components/RichTextEditor/Editor/constants/updateTags.js +2 -0
  120. package/dist/features/RequirementAI/components/RichTextEditor/Editor/constants/updateTags.js.map +1 -0
  121. package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/InitialHtml.js +1 -1
  122. package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/ManualNode.js +1 -1
  123. package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/ProtectTableCellBoundaries.js +2 -0
  124. package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/ProtectTableCellBoundaries.js.map +1 -0
  125. package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/UpdateNode.js +1 -1
  126. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/manualEditSerialization.js +2 -0
  127. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/manualEditSerialization.js.map +1 -0
  128. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/normalizeRedlineMarkdown.js +2 -0
  129. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/normalizeRedlineMarkdown.js.map +1 -0
  130. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownEmphasis.js +2 -0
  131. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownEmphasis.js.map +1 -0
  132. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownLineBreaks.js +2 -0
  133. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownLineBreaks.js.map +1 -0
  134. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownListFormatting.js +2 -0
  135. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownListFormatting.js.map +1 -0
  136. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveReviewBoundaryWhitespace.js +2 -0
  137. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveReviewBoundaryWhitespace.js.map +1 -0
  138. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveTableDelimiters.js +2 -0
  139. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveTableDelimiters.js.map +1 -0
  140. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/tableBoundaryRedlines.js +2 -0
  141. package/dist/features/RequirementAI/components/RichTextEditor/Editor/utils/tableBoundaryRedlines.js.map +1 -0
  142. package/dist/features/RequirementAI/components/RichTextEditor/RichTextEditor.js +1 -1
  143. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/Avatar.css.js +2 -0
  144. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/Avatar.css.js.map +1 -0
  145. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/Avatar.js +2 -0
  146. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/Avatar.js.map +1 -0
  147. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsGroup.css.js +2 -0
  148. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsGroup.css.js.map +1 -0
  149. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsGroup.js +2 -0
  150. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsGroup.js.map +1 -0
  151. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsPopup.css.js +2 -0
  152. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsPopup.css.js.map +1 -0
  153. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsPopup.js +2 -0
  154. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsPopup.js.map +1 -0
  155. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/avatarUtils.js +2 -0
  156. package/dist/features/RequirementAI/components/UserStoryCard/Avatar/avatarUtils.js.map +1 -0
  157. package/dist/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CitationAnchor.js +1 -1
  158. package/dist/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CognitiveComponent.js +1 -1
  159. package/dist/features/RequirementAI/components/UserStoryCard/Popups/DeviationSummary.js +1 -1
  160. package/dist/features/RequirementAI/components/UserStoryCard/Popups/HistoryMenu.js +1 -1
  161. package/dist/features/RequirementAI/components/UserStoryCard/Popups/ManualEditPopup.js +1 -1
  162. package/dist/features/RequirementAI/components/UserStoryCard/Popups/RedlineStatusCard.js +1 -1
  163. package/dist/features/RequirementAI/components/UserStoryCard/UserStoryCard.js +1 -1
  164. package/dist/features/RequirementAI/components/UserStoryCard/UserStoryCard.module.css.js +1 -1
  165. package/dist/features/RequirementAI/components/UserStoryCard/cws/CwsEvent.js +1 -1
  166. package/dist/features/RequirementAI/components/UserStoryCard/cws/CwsEventProvider.js +1 -1
  167. package/dist/features/RequirementAI/components/UserStoryCard/cws/SocketManager.js +1 -1
  168. package/dist/features/RequirementAI/components/UserStoryCard/cws/useCwsEvent.js +1 -1
  169. package/dist/features/RequirementAI/components/ai-reasoning/AiReasonMarkdownWrapper.js +1 -1
  170. package/dist/features/RequirementAI/components/ai-reasoning/AiReasoningCitationContent.js +1 -1
  171. package/dist/features/RequirementAI/components/citations/file-citation/FileCitationContent.js +1 -1
  172. package/dist/features/RequirementAI/components/citations/file-citation/FileCitationContent.module.css.js +1 -1
  173. package/dist/features/RequirementAI/components/citations/file-citation/FileCitationRender.js +1 -1
  174. package/dist/features/RequirementAI/components/citations/readfile-citation/ReadFileCitationContent.js +1 -1
  175. package/dist/features/RequirementAI/components/lsc-reason-gap/CustomChatCrRedirection.js +1 -1
  176. package/dist/features/RequirementAI/components/lsc-reason-gap/GapFilterBlock.js +1 -1
  177. package/dist/features/RequirementAI/components/segment/Segment.js +1 -1
  178. package/dist/features/RequirementAI/components/segment/SegmentWrapper.js +1 -1
  179. package/dist/features/RequirementAI/components/userstory-approval-screen/UserStoryApprovalScreen.js +1 -1
  180. package/dist/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.js +1 -1
  181. package/dist/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.module.css.js +1 -1
  182. package/dist/features/RequirementAI/components/userstory-with-citation/components/InlineUpdatedComponent.js +1 -1
  183. package/dist/features/RequirementAI/components/userstory-with-citation/utils/inlineMarkdown.js +2 -0
  184. package/dist/features/RequirementAI/components/userstory-with-citation/utils/inlineMarkdown.js.map +1 -0
  185. package/dist/features/RequirementAI/hooks/useStreamContentHandler.js +1 -1
  186. package/dist/features/RequirementAI/utils/exponential-retry.js +2 -0
  187. package/dist/features/RequirementAI/utils/exponential-retry.js.map +1 -0
  188. package/dist/features/RequirementAI/utils/helpers.js +1 -1
  189. package/dist/features/RequirementAI/utils/proccess-stream.utils.js +1 -1
  190. package/dist/index.js +1 -1
  191. package/dist/service/redlineService.js +1 -1
  192. package/dist/types/src/CitationAccordionTest.d.ts +1 -0
  193. package/dist/types/src/CitationAccordionTest.d.ts.map +1 -0
  194. package/dist/types/src/MockDeviationSummary.d.ts +1 -0
  195. package/dist/types/src/MockDeviationSummary.d.ts.map +1 -0
  196. package/dist/types/src/RedlineEditorTest.d.ts.map +1 -1
  197. package/dist/types/src/RequirementAiTest.d.ts.map +1 -1
  198. package/dist/types/src/features/CognitiveCompare/CitationAnchor.d.ts.map +1 -1
  199. package/dist/types/src/features/CognitiveCompare/CognitiveCompare.d.ts +1 -1
  200. package/dist/types/src/features/CognitiveCompare/CognitiveCompare.d.ts.map +1 -1
  201. package/dist/types/src/features/CognitiveCompare/CognitiveCompareTypes.d.ts +1 -1
  202. package/dist/types/src/features/CognitiveCompare/CognitiveCompareTypes.d.ts.map +1 -1
  203. package/dist/types/src/features/CognitiveCompare/CognitiveComparehelpers.d.ts +12 -0
  204. package/dist/types/src/features/CognitiveCompare/CognitiveComparehelpers.d.ts.map +1 -1
  205. package/dist/types/src/features/CognitiveCompare/Guidelines/components/GuidelinePanel.d.ts.map +1 -1
  206. package/dist/types/src/features/CognitiveCompare/Guidelines/components/WebGptPanel.d.ts.map +1 -1
  207. package/dist/types/src/features/CognitiveCompare/Guidelines/constants/guidelines.mockData.d.ts +11312 -433
  208. package/dist/types/src/features/CognitiveCompare/Guidelines/constants/guidelines.mockData.d.ts.map +1 -1
  209. package/dist/types/src/features/CognitiveCompare/Guidelines/constants/new-guidelines.mockData.d.ts +33 -0
  210. package/dist/types/src/features/CognitiveCompare/Guidelines/constants/new-guidelines.mockData.d.ts.map +1 -0
  211. package/dist/types/src/features/CognitiveCompare/Guidelines/utils/processGuidelinesMarkdown.d.ts +14 -1
  212. package/dist/types/src/features/CognitiveCompare/Guidelines/utils/processGuidelinesMarkdown.d.ts.map +1 -1
  213. package/dist/types/src/features/CognitiveCompare/components/SectionAccordion.d.ts.map +1 -1
  214. package/dist/types/src/features/CognitiveCompare/components/SubSectionAccordion.d.ts.map +1 -1
  215. package/dist/types/src/features/CognitiveCompare/hooks/memoizedMarkdown.d.ts +2 -1
  216. package/dist/types/src/features/CognitiveCompare/hooks/memoizedMarkdown.d.ts.map +1 -1
  217. package/dist/types/src/features/CognitiveCompare/hooks/useCompareData.d.ts +1 -1
  218. package/dist/types/src/features/CognitiveCompare/hooks/useCompareData.d.ts.map +1 -1
  219. package/dist/types/src/features/CognitiveCompare/hooks/useCompareLayout.d.ts +1 -0
  220. package/dist/types/src/features/CognitiveCompare/hooks/useCompareLayout.d.ts.map +1 -1
  221. package/dist/types/src/features/CognitiveCompare/hooks/useLinesCalculator.d.ts.map +1 -1
  222. package/dist/types/src/features/CognitiveCompare/hooks/useSideBySide.d.ts.map +1 -1
  223. package/dist/types/src/features/CognitiveInternalgptReasoning/CognitiveInternalgptCoreComponent.d.ts +1 -0
  224. package/dist/types/src/features/CognitiveInternalgptReasoning/CognitiveInternalgptCoreComponent.d.ts.map +1 -1
  225. package/dist/types/src/features/GptWebCitation/GptWebCitation.d.ts.map +1 -1
  226. package/dist/types/src/features/GptWebCitation/GptWebCitationImageCitation.d.ts +2 -1
  227. package/dist/types/src/features/GptWebCitation/GptWebCitationImageCitation.d.ts.map +1 -1
  228. package/dist/types/src/features/GptWebCitation/types.d.ts +11 -0
  229. package/dist/types/src/features/GptWebCitation/types.d.ts.map +1 -1
  230. package/dist/types/src/features/GptWebCitation/utils/fixedHeight.utils.d.ts +2 -0
  231. package/dist/types/src/features/GptWebCitation/utils/fixedHeight.utils.d.ts.map +1 -1
  232. package/dist/types/src/features/PdfViewer/PdfContainer.d.ts +2 -4
  233. package/dist/types/src/features/PdfViewer/PdfContainer.d.ts.map +1 -1
  234. package/dist/types/src/features/PdfViewer/PdfStyle.d.ts.map +1 -1
  235. package/dist/types/src/features/PdfViewer/PdfToolbar.d.ts +1 -4
  236. package/dist/types/src/features/PdfViewer/PdfToolbar.d.ts.map +1 -1
  237. package/dist/types/src/features/PdfViewer/PdfViewer.d.ts +2 -19
  238. package/dist/types/src/features/PdfViewer/PdfViewer.d.ts.map +1 -1
  239. package/dist/types/src/features/RequirementAI/components/RequirementAIWrapper/RequirementAIWrapper.d.ts +39 -29
  240. package/dist/types/src/features/RequirementAI/components/RequirementAIWrapper/RequirementAIWrapper.d.ts.map +1 -1
  241. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/constants/updateTags.d.ts +2 -0
  242. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/constants/updateTags.d.ts.map +1 -0
  243. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/InitialHtml.d.ts.map +1 -1
  244. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/ManualNode.d.ts +2 -0
  245. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/ManualNode.d.ts.map +1 -1
  246. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/ProtectTableCellBoundaries.d.ts +3 -0
  247. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/ProtectTableCellBoundaries.d.ts.map +1 -0
  248. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/UpdateNode.d.ts +2 -0
  249. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/UpdateNode.d.ts.map +1 -1
  250. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/reviewBoundaryLexical.test.d.ts +2 -0
  251. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/reviewBoundaryLexical.test.d.ts.map +1 -0
  252. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/manualEditSerialization.d.ts +7 -0
  253. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/manualEditSerialization.d.ts.map +1 -0
  254. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/normalizeRedlineMarkdown.d.ts +2 -0
  255. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/normalizeRedlineMarkdown.d.ts.map +1 -0
  256. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownEmphasis.d.ts +29 -0
  257. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownEmphasis.d.ts.map +1 -0
  258. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownEmphasis.test.d.ts +2 -0
  259. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownEmphasis.test.d.ts.map +1 -0
  260. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownLineBreaks.d.ts +7 -0
  261. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownLineBreaks.d.ts.map +1 -0
  262. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownListFormatting.d.ts +3 -0
  263. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveMarkdownListFormatting.d.ts.map +1 -0
  264. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveReviewBoundaryWhitespace.d.ts +86 -0
  265. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveReviewBoundaryWhitespace.d.ts.map +1 -0
  266. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveReviewBoundaryWhitespace.test.d.ts +9 -0
  267. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveReviewBoundaryWhitespace.test.d.ts.map +1 -0
  268. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveTableDelimiters.d.ts +7 -0
  269. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/preserveTableDelimiters.d.ts.map +1 -0
  270. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/tableBoundaryRedlines.d.ts +5 -0
  271. package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/utils/tableBoundaryRedlines.d.ts.map +1 -0
  272. package/dist/types/src/features/RequirementAI/components/RichTextEditor/RichTextEditor.d.ts.map +1 -1
  273. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Avatar/Avatar.d.ts +10 -0
  274. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Avatar/Avatar.d.ts.map +1 -0
  275. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsGroup.d.ts +17 -0
  276. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsGroup.d.ts.map +1 -0
  277. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsPopup.d.ts +23 -0
  278. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Avatar/CollaboratorsPopup.d.ts.map +1 -0
  279. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Avatar/avatarUtils.d.ts +3 -0
  280. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Avatar/avatarUtils.d.ts.map +1 -0
  281. package/dist/types/src/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CitationAnchor.d.ts.map +1 -1
  282. package/dist/types/src/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CognitiveComponent.d.ts +1 -1
  283. package/dist/types/src/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CognitiveComponent.d.ts.map +1 -1
  284. package/dist/types/src/features/RequirementAI/components/UserStoryCard/CognitiveComponents/userstory.mock.data.d.ts +84 -5439
  285. package/dist/types/src/features/RequirementAI/components/UserStoryCard/CognitiveComponents/userstory.mock.data.d.ts.map +1 -1
  286. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/DeviationSummary.d.ts +1 -1
  287. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/DeviationSummary.d.ts.map +1 -1
  288. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/ManualEditPopup.d.ts +1 -1
  289. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/ManualEditPopup.d.ts.map +1 -1
  290. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/RedlineStatusCard.d.ts +2 -2
  291. package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/RedlineStatusCard.d.ts.map +1 -1
  292. package/dist/types/src/features/RequirementAI/components/UserStoryCard/UserStoryCard.d.ts +20 -2
  293. package/dist/types/src/features/RequirementAI/components/UserStoryCard/UserStoryCard.d.ts.map +1 -1
  294. package/dist/types/src/features/RequirementAI/components/UserStoryCard/cws/CwsEvent.d.ts +7 -2
  295. package/dist/types/src/features/RequirementAI/components/UserStoryCard/cws/CwsEvent.d.ts.map +1 -1
  296. package/dist/types/src/features/RequirementAI/components/UserStoryCard/cws/CwsEventProvider.d.ts.map +1 -1
  297. package/dist/types/src/features/RequirementAI/components/UserStoryCard/cws/SocketManager.d.ts +15 -1
  298. package/dist/types/src/features/RequirementAI/components/UserStoryCard/cws/SocketManager.d.ts.map +1 -1
  299. package/dist/types/src/features/RequirementAI/components/UserStoryCard/cws/useCwsEvent.d.ts +2 -1
  300. package/dist/types/src/features/RequirementAI/components/UserStoryCard/cws/useCwsEvent.d.ts.map +1 -1
  301. package/dist/types/src/features/RequirementAI/components/ai-reasoning/AiReasonMarkdownWrapper.d.ts +3 -2
  302. package/dist/types/src/features/RequirementAI/components/ai-reasoning/AiReasonMarkdownWrapper.d.ts.map +1 -1
  303. package/dist/types/src/features/RequirementAI/components/ai-reasoning/AiReasoningCitationContent.d.ts.map +1 -1
  304. package/dist/types/src/features/RequirementAI/components/citations/file-citation/FileCitationContent.d.ts +1 -0
  305. package/dist/types/src/features/RequirementAI/components/citations/file-citation/FileCitationContent.d.ts.map +1 -1
  306. package/dist/types/src/features/RequirementAI/components/citations/file-citation/FileCitationRender.d.ts +1 -0
  307. package/dist/types/src/features/RequirementAI/components/citations/file-citation/FileCitationRender.d.ts.map +1 -1
  308. package/dist/types/src/features/RequirementAI/components/citations/readfile-citation/ReadFileCitationContent.d.ts.map +1 -1
  309. package/dist/types/src/features/RequirementAI/components/common/onDemandCitationButton.d.ts +12 -0
  310. package/dist/types/src/features/RequirementAI/components/common/onDemandCitationButton.d.ts.map +1 -0
  311. package/dist/types/src/features/RequirementAI/components/lsc-reason-gap/CustomChatCrRedirection.d.ts +3 -2
  312. package/dist/types/src/features/RequirementAI/components/lsc-reason-gap/CustomChatCrRedirection.d.ts.map +1 -1
  313. package/dist/types/src/features/RequirementAI/components/lsc-reason-gap/GapFilterBlock.d.ts +1 -1
  314. package/dist/types/src/features/RequirementAI/components/lsc-reason-gap/GapFilterBlock.d.ts.map +1 -1
  315. package/dist/types/src/features/RequirementAI/components/segment/Segment.d.ts +3 -1
  316. package/dist/types/src/features/RequirementAI/components/segment/Segment.d.ts.map +1 -1
  317. package/dist/types/src/features/RequirementAI/components/segment/SegmentWrapper.d.ts +2 -1
  318. package/dist/types/src/features/RequirementAI/components/segment/SegmentWrapper.d.ts.map +1 -1
  319. package/dist/types/src/features/RequirementAI/components/userstory-approval-screen/UserStoryApprovalContext.d.ts +1 -0
  320. package/dist/types/src/features/RequirementAI/components/userstory-approval-screen/UserStoryApprovalContext.d.ts.map +1 -1
  321. package/dist/types/src/features/RequirementAI/components/userstory-approval-screen/UserStoryApprovalScreen.d.ts +2 -0
  322. package/dist/types/src/features/RequirementAI/components/userstory-approval-screen/UserStoryApprovalScreen.d.ts.map +1 -1
  323. package/dist/types/src/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.d.ts +2 -1
  324. package/dist/types/src/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.d.ts.map +1 -1
  325. package/dist/types/src/features/RequirementAI/components/userstory-with-citation/components/InlineUpdatedComponent.d.ts +2 -1
  326. package/dist/types/src/features/RequirementAI/components/userstory-with-citation/components/InlineUpdatedComponent.d.ts.map +1 -1
  327. package/dist/types/src/features/RequirementAI/components/userstory-with-citation/utils/inlineMarkdown.d.ts +9 -0
  328. package/dist/types/src/features/RequirementAI/components/userstory-with-citation/utils/inlineMarkdown.d.ts.map +1 -0
  329. package/dist/types/src/features/RequirementAI/hooks/useStreamContentHandler.d.ts +1 -1
  330. package/dist/types/src/features/RequirementAI/hooks/useStreamContentHandler.d.ts.map +1 -1
  331. package/dist/types/src/features/RequirementAI/interfaces/userstory.interface.d.ts +2 -0
  332. package/dist/types/src/features/RequirementAI/interfaces/userstory.interface.d.ts.map +1 -1
  333. package/dist/types/src/features/RequirementAI/types/aiReasoning.type.d.ts +7 -0
  334. package/dist/types/src/features/RequirementAI/types/aiReasoning.type.d.ts.map +1 -1
  335. package/dist/types/src/features/RequirementAI/types/segment.type.d.ts +2 -1
  336. package/dist/types/src/features/RequirementAI/types/segment.type.d.ts.map +1 -1
  337. package/dist/types/src/features/RequirementAI/utils/exponential-retry.d.ts +12 -0
  338. package/dist/types/src/features/RequirementAI/utils/exponential-retry.d.ts.map +1 -0
  339. package/dist/types/src/features/RequirementAI/utils/helpers.d.ts +2 -0
  340. package/dist/types/src/features/RequirementAI/utils/helpers.d.ts.map +1 -1
  341. package/dist/types/src/features/RequirementAI/utils/proccess-stream.utils.d.ts.map +1 -1
  342. package/dist/types/src/index.d.ts +0 -4
  343. package/dist/types/src/index.d.ts.map +1 -1
  344. package/dist/types/src/service/redlineService.d.ts.map +1 -1
  345. package/dist/types/src/utils/tagHelper.d.ts +9 -0
  346. package/dist/types/src/utils/tagHelper.d.ts.map +1 -1
  347. package/dist/utils/tagHelper.js +1 -1
  348. package/package.json +1 -1
  349. package/dist/assests/icons/InfoAlert.js +0 -2
  350. package/dist/assests/icons/InfoAlert.js.map +0 -1
  351. package/dist/cjs/assests/icons/InfoAlert.js +0 -2
  352. package/dist/cjs/assests/icons/InfoAlert.js.map +0 -1
  353. package/dist/cjs/features/ParentCitationComponent/ParentCitationComponent.js +0 -2
  354. package/dist/cjs/features/ParentCitationComponent/ParentCitationComponent.js.map +0 -1
  355. package/dist/cjs/features/PdfViewer/nyc-components/BoundaryCard.js +0 -2
  356. package/dist/cjs/features/PdfViewer/nyc-components/BoundaryCard.js.map +0 -1
  357. package/dist/cjs/features/PdfViewer/nyc-components/CardWrapper.js +0 -2
  358. package/dist/cjs/features/PdfViewer/nyc-components/CardWrapper.js.map +0 -1
  359. package/dist/cjs/features/PdfViewer/nyc-components/CognitiveIcon.js +0 -2
  360. package/dist/cjs/features/PdfViewer/nyc-components/CognitiveIcon.js.map +0 -1
  361. package/dist/cjs/features/PdfViewer/nyc-components/LabelCheck.js +0 -2
  362. package/dist/cjs/features/PdfViewer/nyc-components/LabelCheck.js.map +0 -1
  363. package/dist/cjs/features/PdfViewer/nyc-components/SegmentReviewPdfWrapper.js +0 -2
  364. package/dist/cjs/features/PdfViewer/nyc-components/SegmentReviewPdfWrapper.js.map +0 -1
  365. package/dist/cjs/features/PdfViewer/nyc-components/infoAlert.js +0 -2
  366. package/dist/cjs/features/PdfViewer/nyc-components/infoAlert.js.map +0 -1
  367. package/dist/cjs/features/PdfViewer/nyc-components/reviewStepAdapters.js +0 -2
  368. package/dist/cjs/features/PdfViewer/nyc-components/reviewStepAdapters.js.map +0 -1
  369. package/dist/cjs/features/PdfViewer/rotationManager.js +0 -2
  370. package/dist/cjs/features/PdfViewer/rotationManager.js.map +0 -1
  371. package/dist/cjs/features/ReviewPanel/ReviewPanel.js +0 -2
  372. package/dist/cjs/features/ReviewPanel/ReviewPanel.js.map +0 -1
  373. package/dist/cjs/features/SegmentReviewComponents/BoundaryCard.js +0 -2
  374. package/dist/cjs/features/SegmentReviewComponents/BoundaryCard.js.map +0 -1
  375. package/dist/cjs/features/SegmentReviewComponents/CardWrapper.js +0 -2
  376. package/dist/cjs/features/SegmentReviewComponents/CardWrapper.js.map +0 -1
  377. package/dist/cjs/features/SegmentReviewComponents/ChartBreakoutCircle.js +0 -2
  378. package/dist/cjs/features/SegmentReviewComponents/ChartBreakoutCircle.js.map +0 -1
  379. package/dist/cjs/features/SegmentReviewComponents/CognitiveIcon.js +0 -2
  380. package/dist/cjs/features/SegmentReviewComponents/CognitiveIcon.js.map +0 -1
  381. package/dist/cjs/features/SegmentReviewComponents/CognitiveIntegrity.js +0 -2
  382. package/dist/cjs/features/SegmentReviewComponents/CognitiveIntegrity.js.map +0 -1
  383. package/dist/cjs/features/SegmentReviewComponents/CognitiveScoreBadge.js +0 -2
  384. package/dist/cjs/features/SegmentReviewComponents/CognitiveScoreBadge.js.map +0 -1
  385. package/dist/cjs/features/SegmentReviewComponents/LabelCheck.js +0 -2
  386. package/dist/cjs/features/SegmentReviewComponents/LabelCheck.js.map +0 -1
  387. package/dist/cjs/features/SegmentReviewComponents/PageCheck.js +0 -2
  388. package/dist/cjs/features/SegmentReviewComponents/PageCheck.js.map +0 -1
  389. package/dist/cjs/features/SegmentReviewComponents/RevertCard.js +0 -2
  390. package/dist/cjs/features/SegmentReviewComponents/RevertCard.js.map +0 -1
  391. package/dist/cjs/features/SegmentReviewComponents/RevertSuccessCard.js +0 -2
  392. package/dist/cjs/features/SegmentReviewComponents/RevertSuccessCard.js.map +0 -1
  393. package/dist/cjs/features/SegmentReviewComponents/RevertSummaryNotice.js +0 -2
  394. package/dist/cjs/features/SegmentReviewComponents/RevertSummaryNotice.js.map +0 -1
  395. package/dist/cjs/features/SegmentReviewComponents/ReviewedBoundaryActions.js +0 -2
  396. package/dist/cjs/features/SegmentReviewComponents/ReviewedBoundaryActions.js.map +0 -1
  397. package/dist/cjs/features/SegmentReviewComponents/ReviewedCard.js +0 -2
  398. package/dist/cjs/features/SegmentReviewComponents/ReviewedCard.js.map +0 -1
  399. package/dist/cjs/features/SegmentReviewComponents/SegmentReviewPdfWrapper.js +0 -2
  400. package/dist/cjs/features/SegmentReviewComponents/SegmentReviewPdfWrapper.js.map +0 -1
  401. package/dist/cjs/features/SegmentReviewComponents/helper.js +0 -2
  402. package/dist/cjs/features/SegmentReviewComponents/helper.js.map +0 -1
  403. package/dist/cjs/features/SegmentReviewComponents/reviewStepAdapters.js +0 -2
  404. package/dist/cjs/features/SegmentReviewComponents/reviewStepAdapters.js.map +0 -1
  405. package/dist/features/ParentCitationComponent/ParentCitationComponent.js +0 -2
  406. package/dist/features/ParentCitationComponent/ParentCitationComponent.js.map +0 -1
  407. package/dist/features/PdfViewer/nyc-components/BoundaryCard.js +0 -2
  408. package/dist/features/PdfViewer/nyc-components/BoundaryCard.js.map +0 -1
  409. package/dist/features/PdfViewer/nyc-components/CardWrapper.js +0 -2
  410. package/dist/features/PdfViewer/nyc-components/CardWrapper.js.map +0 -1
  411. package/dist/features/PdfViewer/nyc-components/CognitiveIcon.js +0 -2
  412. package/dist/features/PdfViewer/nyc-components/CognitiveIcon.js.map +0 -1
  413. package/dist/features/PdfViewer/nyc-components/LabelCheck.js +0 -2
  414. package/dist/features/PdfViewer/nyc-components/LabelCheck.js.map +0 -1
  415. package/dist/features/PdfViewer/nyc-components/SegmentReviewPdfWrapper.js +0 -2
  416. package/dist/features/PdfViewer/nyc-components/SegmentReviewPdfWrapper.js.map +0 -1
  417. package/dist/features/PdfViewer/nyc-components/infoAlert.js +0 -2
  418. package/dist/features/PdfViewer/nyc-components/infoAlert.js.map +0 -1
  419. package/dist/features/PdfViewer/nyc-components/reviewStepAdapters.js +0 -2
  420. package/dist/features/PdfViewer/nyc-components/reviewStepAdapters.js.map +0 -1
  421. package/dist/features/PdfViewer/rotationManager.js +0 -2
  422. package/dist/features/PdfViewer/rotationManager.js.map +0 -1
  423. package/dist/features/ReviewPanel/ReviewPanel.js +0 -2
  424. package/dist/features/ReviewPanel/ReviewPanel.js.map +0 -1
  425. package/dist/features/SegmentReviewComponents/BoundaryCard.js +0 -2
  426. package/dist/features/SegmentReviewComponents/BoundaryCard.js.map +0 -1
  427. package/dist/features/SegmentReviewComponents/CardWrapper.js +0 -2
  428. package/dist/features/SegmentReviewComponents/CardWrapper.js.map +0 -1
  429. package/dist/features/SegmentReviewComponents/ChartBreakoutCircle.js +0 -2
  430. package/dist/features/SegmentReviewComponents/ChartBreakoutCircle.js.map +0 -1
  431. package/dist/features/SegmentReviewComponents/CognitiveIcon.js +0 -2
  432. package/dist/features/SegmentReviewComponents/CognitiveIcon.js.map +0 -1
  433. package/dist/features/SegmentReviewComponents/CognitiveIntegrity.js +0 -2
  434. package/dist/features/SegmentReviewComponents/CognitiveIntegrity.js.map +0 -1
  435. package/dist/features/SegmentReviewComponents/CognitiveScoreBadge.js +0 -2
  436. package/dist/features/SegmentReviewComponents/CognitiveScoreBadge.js.map +0 -1
  437. package/dist/features/SegmentReviewComponents/LabelCheck.js +0 -2
  438. package/dist/features/SegmentReviewComponents/LabelCheck.js.map +0 -1
  439. package/dist/features/SegmentReviewComponents/PageCheck.js +0 -2
  440. package/dist/features/SegmentReviewComponents/PageCheck.js.map +0 -1
  441. package/dist/features/SegmentReviewComponents/RevertCard.js +0 -2
  442. package/dist/features/SegmentReviewComponents/RevertCard.js.map +0 -1
  443. package/dist/features/SegmentReviewComponents/RevertSuccessCard.js +0 -2
  444. package/dist/features/SegmentReviewComponents/RevertSuccessCard.js.map +0 -1
  445. package/dist/features/SegmentReviewComponents/RevertSummaryNotice.js +0 -2
  446. package/dist/features/SegmentReviewComponents/RevertSummaryNotice.js.map +0 -1
  447. package/dist/features/SegmentReviewComponents/ReviewedBoundaryActions.js +0 -2
  448. package/dist/features/SegmentReviewComponents/ReviewedBoundaryActions.js.map +0 -1
  449. package/dist/features/SegmentReviewComponents/ReviewedCard.js +0 -2
  450. package/dist/features/SegmentReviewComponents/ReviewedCard.js.map +0 -1
  451. package/dist/features/SegmentReviewComponents/SegmentReviewPdfWrapper.js +0 -2
  452. package/dist/features/SegmentReviewComponents/SegmentReviewPdfWrapper.js.map +0 -1
  453. package/dist/features/SegmentReviewComponents/helper.js +0 -2
  454. package/dist/features/SegmentReviewComponents/helper.js.map +0 -1
  455. package/dist/features/SegmentReviewComponents/reviewStepAdapters.js +0 -2
  456. package/dist/features/SegmentReviewComponents/reviewStepAdapters.js.map +0 -1
  457. package/dist/types/src/RedlineApprovalCardTest.d.ts +0 -1
  458. package/dist/types/src/RedlineApprovalCardTest.d.ts.map +0 -1
  459. package/dist/types/src/RedlineEditorTest2.d.ts +0 -3
  460. package/dist/types/src/RedlineEditorTest2.d.ts.map +0 -1
  461. package/dist/types/src/assests/icons/ChartSplitIcon.d.ts +0 -3
  462. package/dist/types/src/assests/icons/ChartSplitIcon.d.ts.map +0 -1
  463. package/dist/types/src/assests/icons/InfoAlert.d.ts +0 -3
  464. package/dist/types/src/assests/icons/InfoAlert.d.ts.map +0 -1
  465. package/dist/types/src/commonConstants.d.ts +0 -31103
  466. package/dist/types/src/commonConstants.d.ts.map +0 -1
  467. package/dist/types/src/features/CognitiveCompare/utils/buildComparisonRows.test.d.ts +0 -2
  468. package/dist/types/src/features/CognitiveCompare/utils/buildComparisonRows.test.d.ts.map +0 -1
  469. package/dist/types/src/features/ParentCitationComponent/ParentCitationComponent.d.ts +0 -128
  470. package/dist/types/src/features/ParentCitationComponent/ParentCitationComponent.d.ts.map +0 -1
  471. package/dist/types/src/features/ParentCitationComponent/ParentCitationComponentTest.d.ts +0 -13
  472. package/dist/types/src/features/ParentCitationComponent/ParentCitationComponentTest.d.ts.map +0 -1
  473. package/dist/types/src/features/PdfViewer/coordinateTransformer.d.ts +0 -41
  474. package/dist/types/src/features/PdfViewer/coordinateTransformer.d.ts.map +0 -1
  475. package/dist/types/src/features/PdfViewer/nyc-components/BoundaryCard.d.ts +0 -59
  476. package/dist/types/src/features/PdfViewer/nyc-components/BoundaryCard.d.ts.map +0 -1
  477. package/dist/types/src/features/PdfViewer/nyc-components/CardWrapper.d.ts +0 -19
  478. package/dist/types/src/features/PdfViewer/nyc-components/CardWrapper.d.ts.map +0 -1
  479. package/dist/types/src/features/PdfViewer/nyc-components/CognitiveIcon.d.ts +0 -3
  480. package/dist/types/src/features/PdfViewer/nyc-components/CognitiveIcon.d.ts.map +0 -1
  481. package/dist/types/src/features/PdfViewer/nyc-components/LabelCheck.d.ts +0 -77
  482. package/dist/types/src/features/PdfViewer/nyc-components/LabelCheck.d.ts.map +0 -1
  483. package/dist/types/src/features/PdfViewer/nyc-components/SegmentReviewPdfWrapper.d.ts +0 -47
  484. package/dist/types/src/features/PdfViewer/nyc-components/SegmentReviewPdfWrapper.d.ts.map +0 -1
  485. package/dist/types/src/features/PdfViewer/nyc-components/index.d.ts +0 -15
  486. package/dist/types/src/features/PdfViewer/nyc-components/index.d.ts.map +0 -1
  487. package/dist/types/src/features/PdfViewer/nyc-components/infoAlert.d.ts +0 -3
  488. package/dist/types/src/features/PdfViewer/nyc-components/infoAlert.d.ts.map +0 -1
  489. package/dist/types/src/features/PdfViewer/nyc-components/reviewStepAdapters.d.ts +0 -36
  490. package/dist/types/src/features/PdfViewer/nyc-components/reviewStepAdapters.d.ts.map +0 -1
  491. package/dist/types/src/features/PdfViewer/rotationManager.d.ts +0 -23
  492. package/dist/types/src/features/PdfViewer/rotationManager.d.ts.map +0 -1
  493. package/dist/types/src/features/SegmentReviewComponents/BoundaryCard.d.ts +0 -85
  494. package/dist/types/src/features/SegmentReviewComponents/BoundaryCard.d.ts.map +0 -1
  495. package/dist/types/src/features/SegmentReviewComponents/CardWrapper.d.ts +0 -26
  496. package/dist/types/src/features/SegmentReviewComponents/CardWrapper.d.ts.map +0 -1
  497. package/dist/types/src/features/SegmentReviewComponents/ChartBreakoutCircle.d.ts +0 -3
  498. package/dist/types/src/features/SegmentReviewComponents/ChartBreakoutCircle.d.ts.map +0 -1
  499. package/dist/types/src/features/SegmentReviewComponents/CognitiveIcon.d.ts +0 -3
  500. package/dist/types/src/features/SegmentReviewComponents/CognitiveIcon.d.ts.map +0 -1
  501. package/dist/types/src/features/SegmentReviewComponents/CognitiveIntegrity.d.ts +0 -33
  502. package/dist/types/src/features/SegmentReviewComponents/CognitiveIntegrity.d.ts.map +0 -1
  503. package/dist/types/src/features/SegmentReviewComponents/CognitiveScoreBadge.d.ts +0 -7
  504. package/dist/types/src/features/SegmentReviewComponents/CognitiveScoreBadge.d.ts.map +0 -1
  505. package/dist/types/src/features/SegmentReviewComponents/LabelCheck.d.ts +0 -87
  506. package/dist/types/src/features/SegmentReviewComponents/LabelCheck.d.ts.map +0 -1
  507. package/dist/types/src/features/SegmentReviewComponents/PageCheck.d.ts +0 -51
  508. package/dist/types/src/features/SegmentReviewComponents/PageCheck.d.ts.map +0 -1
  509. package/dist/types/src/features/SegmentReviewComponents/RevertCard.d.ts +0 -37
  510. package/dist/types/src/features/SegmentReviewComponents/RevertCard.d.ts.map +0 -1
  511. package/dist/types/src/features/SegmentReviewComponents/RevertSuccessCard.d.ts +0 -9
  512. package/dist/types/src/features/SegmentReviewComponents/RevertSuccessCard.d.ts.map +0 -1
  513. package/dist/types/src/features/SegmentReviewComponents/RevertSummaryNotice.d.ts +0 -7
  514. package/dist/types/src/features/SegmentReviewComponents/RevertSummaryNotice.d.ts.map +0 -1
  515. package/dist/types/src/features/SegmentReviewComponents/ReviewedBoundaryActions.d.ts +0 -17
  516. package/dist/types/src/features/SegmentReviewComponents/ReviewedBoundaryActions.d.ts.map +0 -1
  517. package/dist/types/src/features/SegmentReviewComponents/ReviewedCard.d.ts +0 -33
  518. package/dist/types/src/features/SegmentReviewComponents/ReviewedCard.d.ts.map +0 -1
  519. package/dist/types/src/features/SegmentReviewComponents/SegmentReviewPdfWrapper.d.ts +0 -124
  520. package/dist/types/src/features/SegmentReviewComponents/SegmentReviewPdfWrapper.d.ts.map +0 -1
  521. package/dist/types/src/features/SegmentReviewComponents/SegmentReviewRedirectionTest.d.ts +0 -13
  522. package/dist/types/src/features/SegmentReviewComponents/SegmentReviewRedirectionTest.d.ts.map +0 -1
  523. package/dist/types/src/features/SegmentReviewComponents/helper.d.ts +0 -53
  524. package/dist/types/src/features/SegmentReviewComponents/helper.d.ts.map +0 -1
  525. package/dist/types/src/features/SegmentReviewComponents/helper.test.d.ts +0 -2
  526. package/dist/types/src/features/SegmentReviewComponents/helper.test.d.ts.map +0 -1
  527. package/dist/types/src/features/SegmentReviewComponents/index.d.ts +0 -23
  528. package/dist/types/src/features/SegmentReviewComponents/index.d.ts.map +0 -1
  529. package/dist/types/src/features/SegmentReviewComponents/reviewStepAdapters.d.ts +0 -242
  530. package/dist/types/src/features/SegmentReviewComponents/reviewStepAdapters.d.ts.map +0 -1
  531. package/dist/types/src/features/SegmentReviewComponents/segmentReviewEdgeCases.test.d.ts +0 -2
  532. package/dist/types/src/features/SegmentReviewComponents/segmentReviewEdgeCases.test.d.ts.map +0 -1
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./BoundaryCard.js"),t=require("./LabelCheck.js"),r=function(e){return"object"==typeof e&&null!==e?e:{}},n=function(e){return"string"==typeof e?e:null},a=function(e){return"number"==typeof e&&Number.isFinite(e)?e:null},u=function(e){return Array.isArray(e)?e.filter(function(e){return"string"==typeof e}):[]},i=function(e){var a=r(e);return{current_label:n(a.current_label),custom_label:n(a.custom_label),group_id:n(a.group_id),user_actions:u(a.user_actions).filter(t.isLabelReviewAction)}};exports.extractSegmentReviewData=function(t){var n=[],o=[];return t.forEach(function(t){t.review_steps.forEach(function(c,s){var l;if("Page Boundary Review"===c.type){var f=function(t){var n=r(t);return{focus_page:a(n.focus_page),boundary_margin:a(n.boundary_margin),user_actions:u(n.user_actions).filter(e.isBoundaryReviewAction)}}(c.metadata);n.push({id:"".concat(t.stable_key,":boundary:").concat(null!==(l=f.focus_page)&&void 0!==l?l:s),segment:t,step:c,metadata:f})}"Label Review"===c.type&&o.push({id:"".concat(t.stable_key,":label:").concat(s),segment:t,step:c,metadata:i(c.metadata)})})}),{boundaryReviews:n,labelReviews:o}};
2
- //# sourceMappingURL=reviewStepAdapters.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"reviewStepAdapters.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var t=function(){function t(){this.rotations=new WeakMap,this.pageMap=new Map,this.rotationChangeListeners=new Set,this.pdfIdentifier=""}return t.prototype.setPdfIdentifier=function(t){this.pdfIdentifier=t},t.prototype.registerPageElement=function(t,e){this.pageMap.get(t),this.pageMap.set(t,e);var o=this.getPersistedRotation(t);0!==o&&this.applyRotation(e,t,o)},t.prototype.unregisterPageElement=function(t){this.pageMap.delete(t)},t.prototype.getRotation=function(t){var e=this.pageMap.get(t);return e&&this.rotations.get(e)||0},t.prototype.rotatePageBy90=function(t){var e=this.pageMap.get(t);if(e){var o=((this.rotations.get(e)||0)+90)%360;this.applyRotation(e,t,o)}},t.prototype.setRotation=function(t,e){var o=(e%360+360)%360,i=this.pageMap.get(t);i&&this.applyRotation(i,t,o)},t.prototype.applyRotation=function(t,e,o){this.rotations.set(t,o);var i=t.closest(".rpv-core__page-layer");i&&(0===o?(i.style.transform="",i.style.transformOrigin="",i.style.transition=""):(i.style.transform="rotate(".concat(o,"deg)"),i.style.transformOrigin="center center",i.style.transition="transform 0.2s ease")),this.notifyRotationChange(e,o),this.persistRotation(e,o)},t.prototype.onRotationChange=function(t){var e=this;return this.rotationChangeListeners.add(t),function(){e.rotationChangeListeners.delete(t)}},t.prototype.notifyRotationChange=function(t,e){this.rotationChangeListeners.forEach(function(o){try{o(t,e)}catch(t){console.error("Error in rotation change listener:",t)}})},t.prototype.getPersistedRotation=function(t){if(!this.pdfIdentifier)return 0;var e="pdf-rotation-".concat(this.pdfIdentifier,"-").concat(t),o=localStorage.getItem(e);if(!o)return 0;var i=parseInt(o,10);return Number.isFinite(i)?i:0},t.prototype.persistRotation=function(t,e){if(this.pdfIdentifier){var o="pdf-rotation-".concat(this.pdfIdentifier,"-").concat(t);0===e?localStorage.removeItem(o):localStorage.setItem(o,e.toString())}},t.prototype.loadPersistedRotations=function(t){var e=this;this.pdfIdentifier&&t.forEach(function(t){var o=e.getPersistedRotation(t);if(0!==o){var i=e.pageMap.get(t);i&&e.applyRotation(i,t,o)}})},t.prototype.clearAll=function(){var t=this;this.pageMap.forEach(function(e,o){var i=e.closest(".rpv-core__page-layer");if(i&&(i.style.transform="",i.style.transformOrigin="",i.style.transition=""),t.pdfIdentifier){var n="pdf-rotation-".concat(t.pdfIdentifier,"-").concat(o);localStorage.removeItem(n)}}),this.pageMap.clear(),this.rotations=new WeakMap},t.prototype.resetPage=function(t){var e=this.pageMap.get(t);e&&this.applyRotation(e,t,0)},t.prototype.getRotatedPages=function(){var t=this,e=new Map;return this.pageMap.forEach(function(o,i){var n=t.rotations.get(o);void 0!==n&&0!==n&&e.set(i,n)}),e},t}(),e=new t;exports.RotationManager=t,exports.rotationManager=e;
2
- //# sourceMappingURL=rotationManager.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"rotationManager.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),t=require("react");function n(){for(var e=[],i=0;i<arguments.length;i++)e[i]=arguments[i];return e.filter(Boolean).join(" ")}var s=function(){return i.jsx("svg",e.__assign({width:"16",height:"16",viewBox:"0 0 24 24",fill:"none"},{children:i.jsx("path",{d:"M6 9l6 6 6-6",stroke:"currentColor",strokeWidth:"2"})}))},r=function(){return i.jsx("svg",e.__assign({width:"16",height:"16",viewBox:"0 0 24 24",fill:"none"},{children:i.jsx("path",{d:"M18 15l-6-6-6 6",stroke:"currentColor",strokeWidth:"2"})}))},o=function(){return i.jsxs("svg",e.__assign({xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",className:"lucide lucide-maximize2-icon lucide-maximize-2 rp-border"},{children:[i.jsx("path",{d:"M15 3h6v6"}),i.jsx("path",{d:"m21 3-7 7"}),i.jsx("path",{d:"m3 21 7-7"}),i.jsx("path",{d:"M9 21H3v-6"})]}))},l=function(){return i.jsxs("svg",e.__assign({xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",className:"lucide lucide-minimize2-icon lucide-minimize-2 rp-border"},{children:[i.jsx("path",{d:"m14 10 7-7"}),i.jsx("path",{d:"M20 10h-6V4"}),i.jsx("path",{d:"m3 21 7-7"}),i.jsx("path",{d:"M4 14h6v6"})]}))},d=function(){return i.jsxs("svg",e.__assign({xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"#87c66b","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",className:"lucide lucide-circle-check-icon lucide-circle-check"},{children:[i.jsx("circle",{cx:"12",cy:"12",r:"10"}),i.jsx("path",{d:"m9 12 2 2 4-4"})]}))},a={dark:{"--rp-bg":"#000","--rp-text":"#fff","--rp-active-bg":"#1f2930","--rp-muted":"#8c8c8c","--rp-border":"#434343","--rp-success":"#4ade80"},light:{"--rp-bg":"#fff","--rp-text":"#000","--rp-active-bg":"#e5eef5","--rp-muted":"#8c8c8c","--rp-border":"#434343","--rp-success":"#16a34a"}};function c(t){var s,r,o,l,a,c,u=t.item,h=t.index,v=t.isActive,x=t.status,g=void 0===x?"pending":x,p=t.config,m=t.classes,f=p.textKey,j=void 0===f?"text":f,_=p.showStatusIcon,w=void 0===_||_,k=p.showRightBadge,b=void 0===k||k,N=p.rightBadgeText;return i.jsxs("div",e.__assign({className:n("rp-item",v&&"rp-item--active","reviewed"===g&&"rp-item--reviewed",null===(s=null==m?void 0:m.item)||void 0===s?void 0:s.root,v&&(null===(r=null==m?void 0:m.item)||void 0===r?void 0:r.active),"reviewed"===g&&(null===(o=null==m?void 0:m.item)||void 0===o?void 0:o.reviewed))},{children:[w&&"reviewed"===g&&i.jsx("span",e.__assign({className:null===(l=null==m?void 0:m.item)||void 0===l?void 0:l.icon},{children:i.jsx(d,{})})),i.jsx("span",e.__assign({className:n("rp-item-text",null===(a=null==m?void 0:m.item)||void 0===a?void 0:a.text)},{children:String(u[j])})),b&&N&&i.jsx("span",e.__assign({className:n("rp-item-badge",null===(c=null==m?void 0:m.item)||void 0===c?void 0:c.rightBadge)},{children:N(u,h)}))]}))}exports.ReviewPanel=function(d){var u=d.data,h=d.renderItem,v=d.itemConfig,x=d.classes,g=d.keyExtractor,p=void 0===g?function(e,i){return i.toString()}:g,m=d.activeIndex,f=d.onActiveChange,j=d.expanded,_=d.onExpandedChange,w=d.headerLeftSlot,k=d.footerSlot,b=d.headerRightSlot,N=d.getItemStatus,C=d.theme,B=void 0===C?"dark":C,M=d.className,S=t.useState(0),I=S[0],y=S[1],E=t.useState(!1),R=E[0],z=E[1],A=null!=m?m:I,q=null!=j?j:R,W=t.useRef([]),P=function(e){null==f||f(e),void 0===m&&y(e)},V=function(e){null==_||_(e),void 0===j&&z(e)};return t.useEffect(function(){var e;q&&(null===(e=W.current[A])||void 0===e||e.scrollIntoView({behavior:"smooth",block:"nearest"}))},[A,q]),i.jsxs("div",e.__assign({className:n("rp-container",M),style:a[B]},{children:[i.jsxs("div",e.__assign({className:n("rp-header",null==x?void 0:x.header)},{children:[i.jsx("div",e.__assign({className:"rp-header-left"},{children:w})),b?b({activeIndex:A,total:u.length,setIndex:P,isExpanded:q,setExpanded:V}):i.jsxs("div",e.__assign({className:n("rp-header-right",null==x?void 0:x.headerRight)},{children:[i.jsxs("span",{children:[A+1," of ",u.length]}),i.jsx("button",e.__assign({onClick:function(){return P(Math.min(A+1,u.length-1))}},{children:i.jsx(s,{})})),i.jsx("button",e.__assign({onClick:function(){return P(Math.max(A-1,0))}},{children:i.jsx(r,{})}))]})),i.jsx("button",e.__assign({onClick:function(){return V(!q)}},{children:q?i.jsx(l,{}):i.jsx(o,{})}))]})),q&&i.jsx("div",e.__assign({className:n("rp-list",null==x?void 0:x.listWrapper)},{children:u.map(function(t,n){var s=null==N?void 0:N(t,n),r=n===A;return i.jsx("div",e.__assign({ref:function(e){return W.current[n]=e},onClick:function(){return P(n)}},{children:h?h({item:t,index:n,isActive:r,status:s}):i.jsx(c,{item:t,index:n,isActive:r,status:s,config:null!=v?v:{},classes:x})}),p(t,n))})})),k&&i.jsx("div",e.__assign({className:"rp-footer"},{children:k}))]}))};
2
- //# sourceMappingURL=ReviewPanel.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ReviewPanel.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),t=require("react"),n=require("@mui/icons-material/ChevronRight"),r=require("@mui/icons-material/Close"),o=require("@mui/icons-material/ExpandMore"),a=require("@mui/material/Box"),l=require("@mui/material/Button"),s=require("@mui/material/ButtonBase"),d=require("@mui/material/Divider"),u=require("@mui/material/IconButton"),c=require("@mui/material/Paper"),x=require("@mui/material/Radio"),g=require("@mui/material/Stack"),f=require("@mui/material/TextField"),p=require("@mui/material/Typography"),h=require("./RevertSummaryNotice.js"),m=require("./CognitiveIcon.js"),_=require("./CognitiveScoreBadge.js"),E=require("../../assests/icons/InfoAlert.js");function b(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var v,C=b(n),j=b(r),F=b(o),y=b(a),S=b(l),w=b(s),R=b(d),A=b(u),M=b(c),I=b(x),B=b(g),z=b(f),T=b(p),k=function(i,t){return e.__spreadArray([i],Array.isArray(t)?t:null==t?[]:[t],!0)},P="MERGE_ADJACENT";exports.BoundaryReviewActionEnum=void 0,(v=exports.BoundaryReviewActionEnum||(exports.BoundaryReviewActionEnum={})).KEEP="KEEP",v.SPLIT_HERE="SPLIT_HERE",v.MERGE_NEXT="MERGE_NEXT",v.MERGE_PREV="MERGE_PREV",v.MERGE_PREVIOUS="MERGE_PREVIOUS",v.SET_RANGE="SET_RANGE";var W=function(e){return Object.values(exports.BoundaryReviewActionEnum).includes(e)},N=function(i,t,n,r){if(!t||!i)return[];var o=t.additional_decisions,a=Array.isArray(o)?o:o?Object.values(o).flat():[],l=Array.from(new Set(e.__spreadArray(e.__spreadArray([],t.allowed_decisions,!0),a,!0)));return l.flatMap(function(e){var t=i.focus_page,o=l.find(function(e){return e.toLowerCase().includes("merge")}),a=null!=t&&null!=n&&null!=r&&t===n&&t===r,s=null!=t&&null!=n&&t===n,d=null!=t&&null!=r&&(t===r||t===r+1),u=s||d||!(null!=t&&(!(null!=n&&null!=r)||t>n&&t<r));switch(e){case exports.BoundaryReviewActionEnum.SET_RANGE:return[];case"KEEP":return[{id:e,title:"Keep as is",description:"Keep the current document boundary unchanged."}];case"SPLIT_HERE":return[{id:e,title:"Split to a separate document",description:u?"A valid page inside the document is required to split it.":t?"Start a new document at page ".concat(t,"."):"Create a new document at this boundary.",disabled:u}];case"MERGE_PREV":case"MERGE_NEXT":case"MERGE_PREVIOUS":return e!==o?[]:a?[{id:P,title:"Merge with an adjacent document",description:"Choose to merge with the previous or next document."}]:s?[{id:exports.BoundaryReviewActionEnum.MERGE_PREVIOUS,title:"Merge with previous document",description:"Combine this document with the previous document."}]:d?[{id:exports.BoundaryReviewActionEnum.MERGE_NEXT,title:"Merge with next document",description:"Combine this document with the next document."}]:[{id:P,title:"Merge with an adjacent document",description:"Choose to merge with the previous or next document."}]}return[]})};exports.createBoundaryCardOptions=N,exports.default=function(n){var r=n.headerName,o=void 0===r?"Boundary Check":r,a=n.title,l=n.pageNo,s=n.content,d=n.revertSummary,u=n.cognitiveScore,c=n.config,x=n.metadata,g=n.previousSegmentTitle,f=n.nextSegmentTitle,p=n.selectedIndex,b=n.defaultSelectedIndex,v=void 0===b?null:b,G=n.defaultStartPage,D=n.defaultEndPage,q=n.onSelectionChange,H=n.onConfirm,O=n.onActionConfirm,V=n.onCognitiveClick,U=n.onAdjustManually,L=n.onClose,X=n.confirmLabel,K=void 0===X?"Confirm":X,$=n.manualPrompt,J=void 0===$?"Didn't find the right option?":$,Y=n.manualActionLabel,Q=void 0===Y?"Adjust Manually":Y,Z=n.cognitiveLabel,ee=void 0===Z?"Cognitive Integrity":Z,ie=n.showAdjustManually,te=void 0===ie||ie,ne=n.showCognitiveIntegrity,re=void 0===ne||ne,oe=n.showCloseButton,ae=void 0===oe||oe,le=n.confirmDisabled,se=void 0!==le&&le,de=n.width,ue=void 0===de?260:de,ce=n.maxWidth,xe=void 0===ce?260:ce,ge=n.className,fe=n.styles,pe=n.reviewAction,he=n.totalPages,me=t.useMemo(function(){return(null!=c?c:x?N(x,pe,G,D):[]).filter(function(e){return e.id!==exports.BoundaryReviewActionEnum.SET_RANGE})},[c,D,G,x,pe]),_e=t.useState(v),Ee=_e[0],be=_e[1],ve=t.useState(null==G?"":String(G)),Ce=ve[0],je=ve[1],Fe=t.useState(null==D?"":String(D)),ye=Fe[0],Se=Fe[1],we=t.useState(!1),Re=we[0],Ae=we[1],Me=t.useState(!1),Ie=Me[0],Be=Me[1],ze=t.useState(null),Te=ze[0],ke=ze[1],Pe=void 0===p?Ee:p,We=null==Pe?void 0:me[Pe],Ne=(null==We?void 0:We.id)===P,Ge=null!=g,De=null!=f,qe=function(e){return!0===e.disabled||e.id===exports.BoundaryReviewActionEnum.MERGE_PREV&&!Ge||e.id===exports.BoundaryReviewActionEnum.MERGE_PREVIOUS&&!Ge||e.id===exports.BoundaryReviewActionEnum.MERGE_NEXT&&!De||e.id===P&&!Ge&&!De},He=Number(Ce),Oe=Number(ye),Ve=Ce.trim().length>0&&ye.trim().length>0&&Number.isInteger(He)&&Number.isInteger(Oe)&&He>0&&Oe>0,Ue=null!=he&&He>he,Le=null!=he&&Oe>he,Xe=Ve&&He<=Oe&&!Ue&&!Le,Ke=se||!We||qe(We)||Ne&&null==Te||!H&&!O;return i.jsx(M.default,e.__assign({className:ge,elevation:4,sx:k({width:ue,maxWidth:xe,borderTop:"4px solid",borderColor:"error.main",borderRadius:2,bgcolor:"background.paper",overflow:"hidden",boxSizing:"border-box","@media (max-width: 372px)":{width:"calc(100vw - 32px)"}},null==fe?void 0:fe.root)},{children:i.jsxs(B.default,e.__assign({spacing:.75,sx:{p:1}},{children:[i.jsxs(B.default,e.__assign({direction:"row",alignItems:"center",spacing:.75,sx:null==fe?void 0:fe.header},{children:[i.jsx(E.default,{color:"error",height:16,width:16}),i.jsx(T.default,e.__assign({sx:{flex:1,color:"error.main",fontSize:12,fontWeight:500,lineHeight:1.25,textTransform:"uppercase"}},{children:o})),ae&&i.jsx(A.default,e.__assign({size:"small",onClick:L,disabled:!L,"aria-label":"Close boundary check",sx:{p:0,"&.Mui-disabled":{color:"text.secondary"}}},{children:i.jsx(j.default,{sx:{fontSize:17}})}))]})),i.jsxs(y.default,{children:[i.jsx(T.default,e.__assign({sx:{color:"text.primary",fontSize:14,fontWeight:500}},{children:a})),null!=l&&i.jsx(T.default,e.__assign({sx:{mt:.125,color:"text.secondary",fontSize:12}},{children:l})),i.jsx(R.default,{sx:{my:.625}}),null!=d?i.jsx(h.default,{children:d}):null!=s&&i.jsx(T.default,e.__assign({component:"div",sx:{color:"text.secondary",fontSize:11.5,lineHeight:1.3}},{children:s}))]}),i.jsxs(B.default,e.__assign({spacing:.625,role:"radiogroup","aria-label":"Boundary options"},{children:[me.map(function(t,n){var r=Pe===n,o=qe(t);return i.jsxs(M.default,e.__assign({variant:"outlined",sx:k({borderColor:r?"#1976d2":"divider",borderRadius:2,bgcolor:o?"#F8FAFC":"background.paper",overflow:"hidden"},null==fe?void 0:fe.option)},{children:[i.jsxs(w.default,e.__assign({role:"radio","aria-checked":r,disabled:se||o,onClick:function(){return function(e,i){se||qe(i)||(void 0===p&&be(e),i.id!==P&&ke(null),Re&&(Ae(!1),Be(!1)),null==q||q(e,i))}(n,t)},sx:{width:"100%",justifyContent:"flex-start",px:.75,py:.5,textAlign:"left"}},{children:[i.jsx(I.default,{checked:r,disabled:se||o,tabIndex:-1,size:"small",sx:{p:.25,mr:.5,"&.Mui-disabled":{color:"#CBD5E1"}}}),i.jsxs(y.default,e.__assign({sx:{minWidth:0}},{children:[i.jsx(T.default,e.__assign({sx:{color:o?"#94A3B8":"text.primary",fontSize:12.5,fontWeight:500}},{children:t.title})),null!=t.description&&i.jsx(T.default,e.__assign({sx:{mt:.125,color:o?"#94A3B8":"text.secondary",fontSize:11}},{children:t.description}))]}))]})),r&&t.id===P&&i.jsx(B.default,e.__assign({direction:"row",spacing:.75,sx:k({px:.75,pb:.75},null==fe?void 0:fe.adjacentSelector)},{children:[{direction:"previous",title:null!=g?g:"No Previous document",caption:"← Merge into Previous",available:Ge},{direction:"next",title:null!=f?f:"No Next document",caption:"Merge into Next →",available:De}].map(function(t){var n=Te===t.direction;return i.jsxs(B.default,e.__assign({sx:{flex:1,minWidth:0}},{children:[i.jsx(w.default,e.__assign({disabled:se||!t.available,onClick:function(){return ke(t.direction)},"aria-pressed":n,sx:{width:"100%",minWidth:0,minHeight:46,alignItems:"flex-start",justifyContent:"flex-start",p:.625,border:"1px solid",borderColor:n?"#7F56D9":"#D0D5DD",borderRadius:1.5,bgcolor:n?"#E0E7FF":"background.paper",color:n?"#7F56D9":t.available?"text.primary":"#98A2B3",textAlign:"left","&.Mui-disabled":{color:"#98A2B3",bgcolor:"#F8FAFC"}}},{children:i.jsx(T.default,e.__assign({sx:{color:"inherit",fontSize:11,fontWeight:500,lineHeight:1.25,overflowWrap:"anywhere"}},{children:t.title}))})),i.jsx(T.default,e.__assign({sx:{mt:.5,color:n?"#5925DC":"text.secondary",fontSize:9.5,lineHeight:1.2,whiteSpace:"nowrap",textAlign:"next"===t.direction?"right":"left"}},{children:t.caption}))]}),t.direction)})}))]}),t.id)}),Ne&&null!=Te&&i.jsxs(B.default,e.__assign({direction:"row",alignItems:"flex-start",spacing:.625,sx:k({p:.75,border:"1px solid #FCA5A5",borderRadius:1.5,bgcolor:"#FEF2F2"},null==fe?void 0:fe.impactWarning)},{children:[i.jsx(E.default,{color:"error",height:14,width:14,sx:{mt:.125}}),i.jsxs(T.default,e.__assign({sx:{color:"#DC2626",fontSize:10.5,lineHeight:1.4}},{children:["This will impact the ",Te," document. Its content and page range will change."]}))]})),i.jsx(S.default,e.__assign({variant:"contained",fullWidth:!0,disabled:Ke,onClick:function(){if(!Ke&&null!=Pe&&We){var i=Ne?"previous"===Te?exports.BoundaryReviewActionEnum.MERGE_PREVIOUS:exports.BoundaryReviewActionEnum.MERGE_NEXT:We.id,t=Ne?e.__assign(e.__assign({},We),{id:i}):We,n={selectedIndex:Pe,option:t,metadata:x};null==H||H(Pe,t,n),O&&W(i)&&O(i,n)}},sx:k({minHeight:32,mt:.25,borderRadius:2,fontSize:13,fontWeight:600,textTransform:"none",backgroundColor:"#5925DC","&:hover":{backgroundColor:"#4A1FB8"},"&.Mui-disabled":{backgroundColor:"#D9D6FE",color:"#FFFFFF"}},null==fe?void 0:fe.confirmButton)},{children:K}))]})),te&&i.jsxs(B.default,e.__assign({spacing:.625,sx:null==fe?void 0:fe.manualSection},{children:[i.jsxs(w.default,e.__assign({disabled:se,onClick:function(){var e=!Re;Ae(e),Be(!1),e&&(void 0===p&&be(null),null==U||U())},"aria-expanded":Re,sx:{width:"100%",justifyContent:"space-between",borderRadius:1,textAlign:"left"}},{children:[i.jsx(y.default,{children:i.jsx(T.default,e.__assign({sx:{color:"text.primary",fontSize:12,fontWeight:600}},{children:J}))}),i.jsx(F.default,{sx:{color:"text.secondary",fontSize:16,transform:Re?"rotate(180deg)":"none",transition:"transform 150ms ease"}})]})),Re&&!Ie&&i.jsxs(y.default,e.__assign({sx:{pt:.5,fontFamily:'Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif'}},{children:[i.jsxs(y.default,e.__assign({sx:{display:"grid",gridTemplateColumns:"1fr 1fr",columnGap:"8px",mb:"4px"}},{children:[i.jsx(T.default,e.__assign({sx:{fontSize:"10.5px",fontWeight:400,lineHeight:"14px",color:"#57697E",margin:0}},{children:"Starts"})),i.jsx(T.default,e.__assign({sx:{fontSize:"10.5px",fontWeight:400,lineHeight:"14px",color:"#57697E",margin:0}},{children:"Ends"}))]})),i.jsxs(y.default,e.__assign({sx:{display:"grid",gridTemplateColumns:"1fr 1fr",columnGap:"8px",mb:"4px"}},{children:[i.jsxs(y.default,{children:[i.jsx(z.default,{size:"small",type:"text",value:Ce,disabled:se,error:Ue,onChange:function(e){var i=e.target.value;/^\d*$/.test(i)&&je(i)},inputProps:{inputMode:"numeric",pattern:"[0-9]*"},sx:{"& .MuiOutlinedInput-root":{height:"30px",backgroundColor:"#FFFFFF","& fieldset":{borderColor:Ue?"#EF4444":"#C3CFDC",borderWidth:"1px",borderRadius:"6px"},"&:hover fieldset":{borderColor:Ue?"#EF4444":"#C3CFDC"},"&.Mui-focused fieldset":{borderColor:Ue?"#EF4444":"#9488F6",borderWidth:"1px"}},"& .MuiOutlinedInput-input":{fontSize:"12px",fontWeight:400,lineHeight:"1",color:"#34445A",padding:"0 10px",height:"30px"}}}),Ue&&i.jsxs(T.default,e.__assign({sx:{fontSize:"10px",color:"#EF4444",marginTop:"2px",fontWeight:500}},{children:["Must be ≤ ",he," (total pages)"]}))]}),i.jsxs(y.default,{children:[i.jsx(z.default,{size:"small",type:"text",value:ye,disabled:se,error:Le||Ce.trim().length>0&&ye.trim().length>0&&He>Oe,onChange:function(e){var i=e.target.value;/^\d*$/.test(i)&&Se(i)},inputProps:{inputMode:"numeric",pattern:"[0-9]*"},sx:{"& .MuiOutlinedInput-root":{height:"30px",backgroundColor:"#FFFFFF","& fieldset":{borderColor:Le||Ce.trim().length>0&&ye.trim().length>0&&He>Oe?"#EF4444":"#C3CFDC",borderWidth:"1px",borderRadius:"6px"},"&:hover fieldset":{borderColor:Le||Ce.trim().length>0&&ye.trim().length>0&&He>Oe?"#EF4444":"#C3CFDC"},"&.Mui-focused fieldset":{borderColor:Le||Ce.trim().length>0&&ye.trim().length>0&&He>Oe?"#EF4444":"#9488F6",borderWidth:"1px"}},"& .MuiOutlinedInput-input":{fontSize:"12px",fontWeight:400,lineHeight:"1",color:"#34445A",padding:"0 10px",height:"30px"}}}),Le&&i.jsxs(T.default,e.__assign({sx:{fontSize:"10px",color:"#EF4444",marginTop:"2px",fontWeight:500}},{children:["Must be ≤ ",he," (total pages)"]})),!Le&&Ce.trim().length>0&&ye.trim().length>0&&He>Oe&&i.jsx(T.default,e.__assign({sx:{fontSize:"10px",color:"#EF4444",marginTop:"2px",fontWeight:500}},{children:"End page must be ≥ start page"}))]})]})),i.jsx(y.default,{children:i.jsx(S.default,e.__assign({onClick:function(){Xe&&Be(!0)},disabled:se||!Xe,sx:{height:"30px",padding:"0 12px",display:"inline-flex",alignItems:"center",justifyContent:"center",boxSizing:"border-box",backgroundColor:"#FFFFFF",border:"1px solid #8E80F3",borderRadius:"6px",fontFamily:'Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif',fontSize:"12px",fontWeight:600,lineHeight:"1",color:"#4A24CF",outline:"none",cursor:"pointer",textTransform:"none",transition:"all 150ms ease-in-out","&:hover":Xe?{backgroundColor:"#FAF9FF",borderColor:"#7F6FF0"}:{},"&:active":Xe?{transform:"translateY(1px)"}:{},"&.Mui-disabled":{backgroundColor:"#FFFFFF",borderColor:"#C3CFDC",color:"#A0ABBE",cursor:"not-allowed"}}},{children:"Apply"}))}),i.jsx(y.default,{sx:{width:"100%",height:"1px",marginTop:"8px",backgroundColor:"#EEF0F2",border:"0"}})]})),Re&&Ie&&i.jsxs(B.default,e.__assign({spacing:.75,sx:k({p:.75,borderRadius:1.5,bgcolor:"#FFF7ED"},null==fe?void 0:fe.manualConfirmation)},{children:[i.jsxs(B.default,e.__assign({direction:"row",alignItems:"center",spacing:.5},{children:[i.jsx(E.default,{color:"warning",height:14,width:14}),i.jsx(T.default,e.__assign({sx:{color:"#EA580C",fontSize:11,fontWeight:600}},{children:"Confirm this change?"}))]})),i.jsxs(T.default,e.__assign({sx:{color:"text.secondary",fontSize:10.5,lineHeight:1.4}},{children:["Pages ",He,"-",Oe," will become part of ",a,", including pages from other documents in this range."]})),i.jsxs(B.default,e.__assign({direction:"row",spacing:.75},{children:[i.jsx(S.default,e.__assign({variant:"outlined",fullWidth:!0,onClick:function(){return Be(!1)},sx:{minHeight:28,borderRadius:1.5,fontSize:11,textTransform:"none"}},{children:"Cancel"})),i.jsx(S.default,e.__assign({variant:"contained",fullWidth:!0,disabled:se||!H,onClick:function(){if(Xe&&H){var e={id:exports.BoundaryReviewActionEnum.SET_RANGE,title:Q};H(-1,e,{selectedIndex:-1,option:e,startPage:He,endPage:Oe,metadata:x})}},sx:{minHeight:28,borderRadius:1.5,bgcolor:"#EA580C",fontSize:11,textTransform:"none","&:hover":{bgcolor:"#C2410C"}}},{children:"Confirm"}))]}))]}))]})),i.jsx(B.default,e.__assign({spacing:.625,sx:null==fe?void 0:fe.footer},{children:re&&i.jsxs(i.Fragment,{children:[i.jsx(R.default,{}),i.jsxs(w.default,e.__assign({onClick:V,disabled:!V,sx:{justifyContent:"space-between",borderRadius:1,textAlign:"left",cursor:V?"pointer":"not-allowed"}},{children:[i.jsxs(B.default,e.__assign({direction:"row",alignItems:"center",spacing:1},{children:[i.jsx(m.default,{sx:{color:"text.secondary"}}),i.jsx(T.default,e.__assign({sx:{color:"text.primary",fontSize:12}},{children:ee}))]})),i.jsxs(B.default,e.__assign({direction:"row",alignItems:"center",spacing:.5},{children:[i.jsx(_.default,{score:u}),i.jsx(C.default,{sx:{color:"text.secondary"}})]}))]}))]})}))]}))}))},exports.isBoundaryReviewAction=W;
2
- //# sourceMappingURL=BoundaryCard.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"BoundaryCard.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),t=require("react/jsx-runtime"),n=require("react"),i=require("@mui/material/Box"),o=require("@mui/material/Popper");function r(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var l=r(i),a=r(o);exports.default=function(i){var o,r,u=i.anchorRef,s=i.anchorElement,d=i.children,c=i.className,f=i.offset,v=void 0===f?{}:f,h=i.placement,m=void 0===h?"bottom-start":h,p=i.width,x=i.maxWidth;i.customStyles;var w=i.fallbackMaxHeightVh,b=void 0===w?85:w,g=i.heightBuffer,y=void 0===g?100:g,E=n.useState(null),S=E[0],z=E[1],R=n.useState(!0),q=R[0],L=R[1],O=n.useState(null),W=O[0],_=O[1],j=n.useState(null),A=j[0],H=j[1],M=n.useRef(null);return n.useLayoutEffect(function(){var e,t=null!==(e=null!=s?s:null==u?void 0:u.current)&&void 0!==e?e:null;z(function(e){return e===t?e:t})},[s,u]),n.useLayoutEffect(function(){if(S){var e=null,t=function(){var t,n,i=S.getBoundingClientRect(),o=null!==(n=null===(t=window.visualViewport)||void 0===t?void 0:t.height)&&void 0!==n?n:window.innerHeight;L(S.isConnected&&"hidden"!==S.style.visibility),_(Math.max(0,window.innerWidth-i.left-8)),H(Math.max(0,o-i.top-2*i.height)),null!=e&&cancelAnimationFrame(e),e=requestAnimationFrame(function(){var t;e=null,null===(t=M.current)||void 0===t||t.update()})},n=new MutationObserver(t);n.observe(S,{attributes:!0,attributeFilter:["style","class"]});var i="undefined"==typeof ResizeObserver?null:new ResizeObserver(t);return null==i||i.observe(S),window.addEventListener("resize",t),window.addEventListener("scroll",t,!0),t(),function(){n.disconnect(),null==i||i.disconnect(),window.removeEventListener("resize",t),window.removeEventListener("scroll",t,!0),null!=e&&cancelAnimationFrame(e)}}L(!1)},[S]),t.jsx(a.default,e.__assign({open:Boolean(S)&&q,anchorEl:S,popperRef:M,placement:m,className:c,popperOptions:{strategy:"fixed"},modifiers:[{name:"offset",options:{offset:[null!==(o=v.left)&&void 0!==o?o:0,null!==(r=v.top)&&void 0!==r?r:0]}},{name:"flip",enabled:!1},{name:"preventOverflow",options:{mainAxis:!1,altAxis:!0,tether:!1}}],sx:{zIndex:function(e){return e.zIndex.tooltip},width:p,maxWidth:null==W?x:"min(".concat("number"==typeof x?"".concat(x,"px"):null!=x?x:"100vw",", ").concat(W,"px)"),minWidth:0,height:"fit-content",maxHeight:null==A?"calc(".concat(b,"vh - 10px)"):"".concat(A-y,"px"),alignSelf:"flex-start",flex:"0 0 auto",overflowX:"hidden",overflowY:"auto",borderRadius:2,boxShadow:function(e){return e.shadows[4]},boxSizing:"border-box"}},{children:t.jsx(l.default,e.__assign({sx:{width:"100%",maxWidth:"100%",minWidth:0,height:"fit-content",minHeight:0,maxHeight:null==A?"calc(".concat(b,"vh - 10px)"):"".concat(A-y,"px"),overflowX:"hidden",overflowY:"auto",pointerEvents:"auto",boxSizing:"border-box"}},{children:d}))}))};
2
- //# sourceMappingURL=CardWrapper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CardWrapper.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),r=require("react/jsx-runtime");exports.default=function(t){return r.jsx("svg",e.__assign({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:r.jsx("path",{d:"M8.9375 1.4375V0.5M11.3996 2.10041L12.0625 1.4375M12.0689 4.5625H13.0064M12.9691 7.375C12.6556 10.5333 9.99084 13 6.75 13C3.29822 13 0.5 10.2018 0.5 6.75C0.5 3.50916 2.96667 0.844437 6.125 0.53086M6.75 4.25H9.25V6.75M9.0123 4.25C7.54083 6.32975 5.11648 7.6875 2.375 7.6875C1.74819 7.6875 1.13795 7.61652 0.551889 7.48216",stroke:"#16A34A","stroke-linecap":"round","stroke-linejoin":"round"})}))};
2
- //# sourceMappingURL=ChartBreakoutCircle.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ChartBreakoutCircle.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var C=require("tslib"),e=require("react/jsx-runtime");function t(C){return C&&"object"==typeof C&&"default"in C?C:{default:C}}var r=t(require("@mui/material/SvgIcon"));exports.default=function(t){return e.jsxs(r.default,C.__assign({},t,{viewBox:"0 0 12 17",sx:C.__assign({width:12,height:17},t.sx)},{children:[e.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M0.778549 6.35498C0.947509 6.06234 1.14047 5.78701 1.35448 5.53127L1.05841 6.77432C0.87679 7.48466 0.80378 8.17502 1.05378 8.73356C1.09106 8.81682 1.13466 8.8951 1.18403 8.96801C1.17505 9.11859 1.17346 9.27007 1.17938 9.42164C1.21133 10.2394 1.46064 11.0339 1.90165 11.7232C2.34265 12.4126 2.95942 12.9719 3.68845 13.3437C3.78702 13.3948 3.86973 13.4719 3.92758 13.5667C3.98544 13.6614 4.01623 13.7702 4.01664 13.8814V16.3427C4.01664 16.422 4.00103 16.5004 3.97071 16.5736C3.94039 16.6468 3.89595 16.7133 3.83993 16.7693C3.78391 16.8253 3.71741 16.8698 3.64421 16.9001C3.57102 16.9305 3.49257 16.946 3.41335 16.946C3.33412 16.946 3.25567 16.9305 3.18248 16.9001C3.10928 16.8698 3.04278 16.8253 2.98676 16.7693C2.93074 16.7133 2.8863 16.6468 2.85598 16.5736C2.82567 16.5004 2.81006 16.422 2.81006 16.3427V14.2366C1.50675 13.4505 0.563809 12.1847 0.18393 10.7109C-0.195948 9.23705 0.017555 7.67304 0.778549 6.35498ZM2.5956 4.4202C2.58489 4.46583 2.57238 4.51587 2.55818 4.57051L2.10596 6.46709C2.4519 6.00902 2.88178 5.61795 3.37484 5.31587C3.45372 5.26755 3.53389 5.2217 3.61524 5.17836L3.91437 4.02581C3.94069 3.92848 3.96334 3.83471 3.98223 3.74482C3.4887 3.90843 3.02287 4.13636 2.5956 4.4202ZM4.97997 3.50929C4.95187 3.76277 4.89721 4.01844 4.83146 4.26296L4.70096 4.7659C5.02368 4.68809 5.35523 4.64508 5.68997 4.63852C6.50816 4.62249 7.31584 4.82482 8.02986 5.22467C8.74387 5.62452 9.33837 6.20745 9.75227 6.91343C10.1661 7.61942 10.3843 8.42296 10.3845 9.24135V13.029C10.3845 13.1201 10.3483 13.2075 10.2838 13.272C10.2193 13.3365 10.132 13.3726 10.0408 13.3726H8.14698C7.98698 13.3726 7.83353 13.4362 7.72039 13.5493C7.60726 13.6625 7.5437 13.816 7.5437 13.9759V16.3427C7.5437 16.5028 7.60726 16.6562 7.72039 16.7693C7.83353 16.8825 7.98698 16.946 8.14698 16.946C8.30699 16.946 8.46043 16.8825 8.57357 16.7693C8.6867 16.6562 8.75027 16.5028 8.75027 16.3427V14.5792H10.0408C10.2444 14.5792 10.446 14.5391 10.634 14.4612C10.8221 14.3833 10.993 14.2691 11.137 14.1252C11.2809 13.9812 11.3951 13.8103 11.473 13.6223C11.551 13.4342 11.591 13.2326 11.591 13.029V9.24224C11.5909 8.20964 11.3155 7.1957 10.7933 6.30483C10.271 5.41397 9.5209 4.67834 8.61996 4.17369C7.50563 3.55832 6.22659 3.32916 4.97997 3.50929ZM3.31096 7.17824C3.06416 7.47379 2.86777 7.81154 2.73281 8.17818C2.67346 8.33942 2.62681 8.50407 2.59287 8.67068C2.96541 8.66305 3.3259 8.58961 4.09408 7.98043L4.4813 7.65806C4.62698 7.53143 4.68583 7.33671 4.65268 7.14949L4.63322 7.06982C4.53815 6.83998 4.24287 6.77137 4.02738 6.89566C3.80462 7.02416 3.56339 7.12021 3.31096 7.17824ZM5.50956 6.70762C5.39307 6.42581 5.2101 6.22391 4.9955 6.09139C5.4636 5.96152 5.95753 5.9332 6.44355 6.01261C7.21223 6.13821 7.9139 6.52554 8.4298 7.10905C8.7773 7.50191 8.68077 8.0666 8.32362 8.38802C7.27342 9.33691 5.53306 10.5666 3.80331 11.0251C3.36315 11.141 2.88052 10.9286 2.71933 10.4749C2.62076 10.1971 2.55967 9.90972 2.53604 9.62C2.82204 9.61857 3.17908 9.5971 3.63183 9.39587C4.05727 9.20681 4.51985 8.88082 5.10381 8.3732C5.58794 7.95226 5.70675 7.30946 5.5355 6.77894L5.52437 6.74281L5.50956 6.70762Z"}),e.jsx("path",{d:"M2.49253 8.67144C1.98274 8.67144 1.60843 8.35663 1.96545 6.97238L2.55084 4.51665C2.65295 4.12345 2.66944 3.96624 2.55084 3.96624C2.1154 4.07601 2.33401 4.00777 1.9654 4.16485L1.71094 3.73988C2.95167 2.68571 2.97363 2.40709 3.58474 2.40709C4.09454 2.40709 4.17978 3.02062 3.92448 3.96464L3.25466 6.54621C3.13565 7.00253 3.18712 7.15973 3.30531 7.15973C3.56398 7.10114 3.81132 7.00404 4.03939 6.87249C4.25773 6.74655 4.55616 6.81591 4.65239 7.04889C4.72106 7.26145 4.66773 7.49745 4.49914 7.64399C3.36616 8.62885 2.9653 8.67144 2.49253 8.67144ZM3.66602 0.00239655C3.7822 -0.00651177 3.89895 0.00947896 4.00846 0.0493006C4.11797 0.0891223 4.21772 0.151858 4.30105 0.233314C4.38438 0.314771 4.44935 0.413073 4.49165 0.521653C4.53394 0.630232 4.55258 0.746588 4.54631 0.862945V0.860752C4.53258 1.15708 4.40525 1.43674 4.19074 1.64164C3.97623 1.84656 3.69104 1.96097 3.39439 1.96112L3.37064 1.96075C3.25288 1.97358 3.13485 1.95962 3.02324 1.91993C2.91164 1.88024 2.81044 1.81584 2.72723 1.73154C2.64402 1.64723 2.58094 1.54522 2.54271 1.43311C2.50477 1.32187 2.49227 1.20356 2.5061 1.08687C2.51738 0.789536 2.64564 0.508673 2.86299 0.305421C3.08056 0.101963 3.36973 -0.00722427 3.66748 0.00166549L3.66602 0.00239655Z"})]}))};
2
- //# sourceMappingURL=CognitiveIcon.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CognitiveIcon.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),n=require("@mui/icons-material/ChevronLeft"),t=require("@mui/icons-material/Close"),a=require("@mui/material/Box"),r=require("@mui/material/Divider"),s=require("@mui/material/IconButton"),l=require("@mui/material/Paper"),o=require("@mui/material/Stack"),d=require("@mui/material/Typography"),u=require("../CitationRenderer/MarkdownRenderer.js"),c=require("./CognitiveIcon.js"),g=require("./CognitiveScoreBadge.js");function h(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var f=h(n),x=h(t),m=h(a),_=h(r),p=h(s),v=h(l),j=h(o),y=h(d),b=function(i,n){return e.__spreadArray([i],Array.isArray(n)?n:null==n?[]:[n],!0)};exports.default=function(n){var t=n.reasons,a=n.reason,r=n.gap,s=n.score,l=n.headerName,o=void 0===l?"Cognitive Integrity":l,d=n.onBack,h=n.onClose,H=n.showCloseButton,C=void 0===H||H,S=n.width,z=void 0===S?260:S,w=n.maxWidth,q=void 0===w?260:w,k=n.className,W=n.styles,A=(null!=t?t:[]).filter(function(e){return"evidence"===e.type.trim().toLowerCase()}).map(function(e){return e.text.trim()}).filter(Boolean),B=(null!=t?t:[]).filter(function(e){return"gap"===e.type.trim().toLowerCase()}).map(function(e){return e.text.trim()}).filter(Boolean),I=null==a?void 0:a.trim(),R=null==r?void 0:r.trim();if(0===A.length&&I&&A.push(I),0===B.length&&R&&B.push(R),0===A.length&&0===B.length)return null;var F,M=(F=null==W?void 0:W.markdown,e.__assign(e.__assign({},F),{containerWrapper:e.__assign(e.__assign({},null==F?void 0:F.containerWrapper),{display:"block",height:"auto",minHeight:0,maxHeight:"fit-content",flex:"0 0 auto"}),mainCard:e.__assign(e.__assign({},null==F?void 0:F.mainCard),{height:"auto",minHeight:0,maxHeight:"none",flex:"0 0 auto",padding:0,border:"none",borderRadius:0,boxShadow:"none",backgroundColor:"transparent"}),scrollArea:e.__assign({height:"auto",minHeight:0,maxHeight:"none",overflowY:"visible",paddingRight:0,color:"#475467",fontSize:11.5,lineHeight:1.3},null==F?void 0:F.scrollArea),list:e.__assign({margin:"0",padding:"0 0 0 18px",fontSize:"11.5px",lineHeight:"1.3"},null==F?void 0:F.list)})),D=e.__assign(e.__assign({},M),{scrollArea:e.__assign(e.__assign({},M.scrollArea),{fontSize:"inherit",lineHeight:"inherit"}),summary:e.__assign(e.__assign({},M.summary),{display:"inline-flex",padding:0,fontSize:"inherit",lineHeight:"inherit"})});return i.jsx(v.default,e.__assign({className:k,elevation:4,sx:b({width:z,maxWidth:q,height:"fit-content",minHeight:0,alignSelf:"flex-start",flex:"0 0 auto",borderRadius:2,bgcolor:"background.paper",overflow:"hidden",boxSizing:"border-box","@media (max-width: 372px)":{width:"calc(100vw - 32px)"}},null==W?void 0:W.root)},{children:i.jsxs(j.default,e.__assign({spacing:.75,sx:{p:1,height:"auto",minHeight:0}},{children:[i.jsxs(j.default,e.__assign({direction:"row",alignItems:"center",spacing:.75,sx:null==W?void 0:W.header},{children:[d&&i.jsx(p.default,e.__assign({size:"small",onClick:d,"aria-label":"Return to review check",sx:{p:0,color:"#6941C6"}},{children:i.jsx(f.default,{sx:{fontSize:17}})})),i.jsx(c.default,{sx:{color:"#6941C6"}}),i.jsx(y.default,e.__assign({sx:{flex:1,fontSize:12,fontWeight:500,alignItems:"center",display:"flex",lineHeight:1.25,textTransform:"capitalise"}},{children:o})),i.jsx(g.default,{score:s}),C&&i.jsx(p.default,e.__assign({size:"small",onClick:h,disabled:!h,"aria-label":"Close cognitive integrity",sx:{p:0,"&.Mui-disabled":{color:"text.secondary"}}},{children:i.jsx(x.default,{sx:{fontSize:17}})}))]})),i.jsx(_.default,{sx:{m:0}}),i.jsx(m.default,e.__assign({sx:b({bgcolor:"#F9FAFB",px:1.5,py:1.25,height:"auto",minHeight:0,flex:"0 0 auto"},null==W?void 0:W.content)},{children:i.jsxs(j.default,e.__assign({spacing:1.5},{children:[A.length>0&&i.jsxs(m.default,{children:[i.jsx(y.default,e.__assign({sx:{mb:1,color:"#344054",fontSize:12,fontWeight:600,lineHeight:1.4}},{children:"Decision Making Factors"})),i.jsx(j.default,e.__assign({spacing:.75},{children:A.map(function(n,t){return i.jsxs(j.default,e.__assign({direction:"row",alignItems:"flex-start",spacing:.75},{children:[i.jsxs(y.default,e.__assign({component:"span",sx:{flex:"0 0 auto",minWidth:14,color:"#475467",fontSize:11.5,lineHeight:1.65}},{children:[t+1,"."]})),i.jsx(m.default,e.__assign({sx:{flex:1,minWidth:0,color:"#667085",fontSize:11.5,lineHeight:1.65,"& p":{m:0,color:"inherit",fontSize:"inherit",lineHeight:"inherit"}}},{children:i.jsx(u.default,{value:"<summary>".concat(n,"</summary>"),styles:D})}))]}),"evidence-".concat(t))})}))]}),A.length>0&&B.length>0&&i.jsx(_.default,{sx:{my:"2px !important",borderColor:"#E4E7EC"}}),B.length>0&&i.jsxs(m.default,{children:[i.jsx(y.default,e.__assign({sx:{mb:1,color:"#344054",fontSize:12,fontWeight:600,lineHeight:1.4}},{children:"Gaps in Decision"})),i.jsx(j.default,e.__assign({spacing:.75},{children:B.map(function(n,t){return i.jsxs(j.default,e.__assign({direction:"row",alignItems:"flex-start",spacing:.75},{children:[i.jsxs(y.default,e.__assign({component:"span",sx:{flex:"0 0 auto",minWidth:14,color:"#475467",fontSize:11.5,lineHeight:1.65}},{children:[t+1,"."]})),i.jsx(m.default,e.__assign({sx:{flex:1,minWidth:0,color:"#667085",fontSize:11.5,lineHeight:1.65,"& p":{m:0,color:"inherit",fontSize:"inherit",lineHeight:"inherit"}}},{children:i.jsx(u.default,{value:"<summary>".concat(n,"</summary>"),styles:D})}))]}),"gap-".concat(t))})}))]})]}))}))]}))}))};
2
- //# sourceMappingURL=CognitiveIntegrity.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CognitiveIntegrity.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),r=require("react/jsx-runtime");function t(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var n=t(require("@mui/material/Box"));exports.default=function(t){var o=t.score;if(null==o||"string"==typeof o&&""===o.trim())return null;var i="number"==typeof o?"".concat(o,"%"):o;return r.jsx(n.default,e.__assign({component:"span",sx:{px:.625,py:0,border:"1.5px solid",borderColor:"secondary.main",borderRadius:10,color:"secondary.main",fontSize:11,lineHeight:1.25}},{children:i}))};
2
- //# sourceMappingURL=CognitiveScoreBadge.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CognitiveScoreBadge.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),t=require("react"),r=require("@mui/icons-material/ChevronRight"),n=require("@mui/icons-material/Close"),o=require("@mui/material/Box"),l=require("@mui/material/Button"),a=require("@mui/material/ButtonBase"),s=require("@mui/material/Divider"),d=require("@mui/material/IconButton"),u=require("@mui/material/Paper"),c=require("@mui/material/Radio"),x=require("@mui/material/Stack"),f=require("@mui/material/TextField"),h=require("@mui/material/Typography"),m=require("./RevertSummaryNotice.js"),p=require("./CognitiveIcon.js"),g=require("./CognitiveScoreBadge.js"),b=require("../../assests/icons/InfoAlert.js");function v(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var _,j=v(r),C=v(n),y=v(o),w=v(l),S=v(a),A=v(s),L=v(d),E=v(u),I=v(c),q=v(x),k=v(f),B=v(h),D=function(i,t){return e.__spreadArray([i],Array.isArray(t)?t:null==t?[]:[t],!0)};exports.LabelReviewActionEnum=void 0,(_=exports.LabelReviewActionEnum||(exports.LabelReviewActionEnum={})).KEEP_LABEL="KEEP_LABEL",_.SET_CUSTOM_LABEL="SET_CUSTOM_LABEL";var z=function(e){return e.user_actions.map(function(i){switch(i){case"KEEP_LABEL":return{id:i,title:"Keep as is",description:e.current_label?'Label stays "'.concat(e.current_label,'"'):"Keep the current document label"};case"SET_CUSTOM_LABEL":return{id:i,title:"Fix a document title",description:"Correct the page title if it's not right",requiresInput:!0,inputPlaceholder:e.current_label?"e.g. ".concat(e.current_label):"Enter a document label"}}})},M=function(e){return Object.values(exports.LabelReviewActionEnum).includes(e)};exports.createLabelCheckOptions=z,exports.default=function(r){var n,o=r.headerName,l=void 0===o?"Title Check":o,a=r.title,s=r.pageNo,d=r.content,u=void 0===d?"We're not fully confident about this label. Confirm it, choose a different type, or add a new one.":d,c=r.revertSummary,x=r.cognitiveScore,f=r.config,h=r.metadata,v=r.selectedIndex,_=r.defaultSelectedIndex,F=void 0===_?null:_,O=r.onSelectionChange,R=r.customLabel,W=r.defaultCustomLabel,T=r.onCustomLabelChange,P=r.onConfirm,K=r.onActionConfirm,H=r.onCognitiveClick;r.onAdjustManually;var N=r.onClose,U=r.confirmLabel,G=void 0===U?"Confirm":U,J=r.customInputAriaLabel,Q=void 0===J?"Custom document label":J;r.manualPrompt,r.manualActionLabel;var V=r.cognitiveLabel,X=void 0===V?"Cognitive Integrity":V;r.showAdjustManually;var Y=r.showCognitiveIntegrity,Z=void 0===Y||Y,$=r.showCloseButton,ee=void 0===$||$,ie=r.confirmDisabled,te=void 0!==ie&&ie,re=r.confirmationBlocked,ne=void 0!==re&&re,oe=r.confirmationWarning,le=r.disableAllActions,ae=void 0!==le&&le,se=r.width,de=void 0===se?260:se,ue=r.maxWidth,ce=void 0===ue?260:ue,xe=r.className,fe=r.styles,he=t.useMemo(function(){return null!=f?f:h?z(h):[]},[f,h]),me=t.useState(F),pe=me[0],ge=me[1],be=t.useState(null!==(n=null!=W?W:null==h?void 0:h.custom_label)&&void 0!==n?n:""),ve=be[0],_e=be[1],je=void 0===v?pe:v,Ce=void 0===R?ve:R,ye=null==je?void 0:he[je],we=Boolean(null==ye?void 0:ye.requiresInput),Se=ne||ae||te||!P&&!K||!ye||!0===ye.disabled||we&&0===Ce.trim().length,Ae=function(){if(!Se&&null!=je&&ye){var e=we?Ce.trim():void 0;null==P||P(je,ye,e),K&&M(ye.id)&&K(ye.id,{selectedIndex:je,option:ye,customLabel:e,metadata:h})}};return i.jsx(E.default,e.__assign({className:xe,elevation:0,sx:D({width:de,maxWidth:ce,borderTop:"4px solid",borderColor:"error.main",borderRadius:2,bgcolor:"background.paper",boxSizing:"border-box",boxShadow:"0 8px 16px rgba(16, 24, 40, 0.2)","@media (max-width: 372px)":{width:"calc(100vw - 32px)"}},null==fe?void 0:fe.root)},{children:i.jsx(y.default,e.__assign({sx:{overflow:"hidden"}},{children:i.jsxs(q.default,e.__assign({spacing:.75,sx:{p:1}},{children:[i.jsxs(q.default,e.__assign({direction:"row",alignItems:"center",spacing:.75,sx:null==fe?void 0:fe.header},{children:[i.jsx(b.default,{color:"error",height:16,width:16}),i.jsx(B.default,e.__assign({sx:{flex:1,color:"error.main",fontSize:12,fontWeight:500,lineHeight:1.25,textTransform:"uppercase"}},{children:l})),ee&&i.jsx(L.default,e.__assign({size:"small",onClick:N,disabled:!N,"aria-label":"Close label check",sx:{p:0,"&.Mui-disabled":{color:"text.secondary"}}},{children:i.jsx(C.default,{sx:{fontSize:17}})}))]})),i.jsxs(y.default,{children:[i.jsx(B.default,e.__assign({sx:{color:"text.primary",fontSize:14,fontWeight:500}},{children:a})),null!=s&&i.jsx(B.default,e.__assign({sx:{mt:.125,color:"text.secondary",fontSize:12}},{children:s})),i.jsx(A.default,{sx:{my:.625}}),null!=c?i.jsx(m.default,{children:c}):null!=u&&i.jsx(B.default,e.__assign({component:"div",sx:{color:"text.secondary",fontSize:11.5,lineHeight:1.3}},{children:u}))]}),i.jsxs(q.default,e.__assign({spacing:.625,role:"radiogroup","aria-label":"Label options"},{children:[null!=oe&&i.jsxs(q.default,e.__assign({direction:"row",alignItems:"flex-start",spacing:.5,role:"alert",sx:D({px:.75,py:.625,borderRadius:1,bgcolor:"#FEFCE8",color:"#CA8A04"},null==fe?void 0:fe.confirmationWarning)},{children:[i.jsx(b.default,{color:"inherit",height:15,width:15}),i.jsx(B.default,e.__assign({sx:{color:"inherit",fontSize:11.5,lineHeight:1.3}},{children:oe}))]})),he.map(function(t,r){var n=je===r;return i.jsxs(E.default,e.__assign({variant:"outlined",sx:D({borderColor:n?"#1976d2":"divider",borderRadius:2,overflow:"hidden"},null==fe?void 0:fe.option)},{children:[i.jsxs(S.default,e.__assign({role:"radio","aria-checked":n,disabled:te||t.disabled||ne,onClick:function(){return function(e,i){te||i.disabled||(void 0===v&&ge(e),null==O||O(e,i))}(r,t)},sx:{width:"100%",justifyContent:"flex-start",px:.75,py:.5,textAlign:"left",cursor:"pointer","&.Mui-disabled":{cursor:"not-allowed"}}},{children:[i.jsx(I.default,{checked:n,disabled:te||t.disabled||ne,tabIndex:-1,size:"small",sx:{p:.25,mr:.5,cursor:"pointer","&.Mui-disabled":{cursor:"not-allowed"}}}),i.jsxs(y.default,e.__assign({sx:{minWidth:0}},{children:[i.jsx(B.default,e.__assign({sx:{color:"text.primary",fontSize:12.5,fontWeight:500}},{children:t.title})),null!=t.description&&i.jsx(B.default,e.__assign({sx:{mt:.125,color:"text.secondary",fontSize:11}},{children:t.description}))]}))]})),n&&t.requiresInput&&i.jsx(y.default,e.__assign({sx:{px:1.25,pb:1}},{children:i.jsx(k.default,{autoFocus:!0,fullWidth:!0,size:"small",value:Ce,disabled:te,placeholder:t.inputPlaceholder,inputProps:{"aria-label":Q},onChange:function(e){return i=e.target.value,void 0===R&&_e(i),void(null==T||T(i));var i},onKeyDown:function(e){"Enter"===e.key&&Ae()},variant:"outlined",InputProps:{sx:{height:36,borderRadius:2,backgroundColor:"background.paper","& .MuiOutlinedInput-notchedOutline":{borderColor:"#D0D5DD",borderWidth:"1px"},"&:hover .MuiOutlinedInput-notchedOutline":{borderColor:"#D0D5DD"},"&.Mui-focused .MuiOutlinedInput-notchedOutline":{borderColor:"#D0D5DD",borderWidth:"1.5px"},"& .MuiOutlinedInput-input":{height:"100%",boxSizing:"border-box",px:1.25,py:0,fontSize:12,lineHeight:1.25},"& .MuiOutlinedInput-input::placeholder":{color:"#98A2B3",opacity:1}}},sx:null==fe?void 0:fe.customInput})}))]}),t.id)}),i.jsx(w.default,e.__assign({variant:"contained",fullWidth:!0,disabled:Se,onClick:Ae,sx:D({minHeight:32,mt:.25,borderRadius:2,fontSize:13,fontWeight:600,textTransform:"none",backgroundColor:"#5925DC","&:hover":{backgroundColor:"#4A1FB8"},"&.Mui-disabled":{backgroundColor:"#D9D6FE",color:"#FFFFFF"}},null==fe?void 0:fe.confirmButton)},{children:G}))]})),i.jsx(q.default,e.__assign({spacing:.625,sx:null==fe?void 0:fe.footer},{children:Z&&i.jsxs(i.Fragment,{children:[i.jsx(A.default,{}),i.jsxs(S.default,e.__assign({onClick:H,disabled:!H,sx:{justifyContent:"space-between",borderRadius:1,textAlign:"left",cursor:H?"pointer":"not-allowed"}},{children:[i.jsxs(q.default,e.__assign({direction:"row",alignItems:"center",spacing:1},{children:[i.jsx(p.default,{sx:{color:"text.secondary"}}),i.jsx(B.default,e.__assign({sx:{color:"text.primary",fontSize:12}},{children:X}))]})),i.jsxs(q.default,e.__assign({direction:"row",alignItems:"center",spacing:.75},{children:[i.jsx(g.default,{score:x}),i.jsx(j.default,{sx:{color:"text.secondary",fontSize:18}})]}))]}))]})}))]}))}))}))},exports.isLabelReviewAction=M;
2
- //# sourceMappingURL=LabelCheck.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"LabelCheck.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),o=require("react"),r=require("@mui/icons-material/ChevronRight"),t=require("@mui/icons-material/Close"),n=require("@mui/material/Box"),a=require("@mui/material/Button"),s=require("@mui/material/Divider"),l=require("@mui/material/IconButton"),d=require("@mui/material/Paper"),c=require("@mui/material/Stack"),u=require("@mui/material/Typography"),x=require("./CognitiveIcon.js"),g=require("./CognitiveScoreBadge.js"),f=require("../../assests/icons/InfoAlert.js");function h(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var m,p=h(r),C=h(t),b=h(n),_=h(a),v=h(s),j=h(l),y=h(d),k=h(c),F=h(u),A=function(i,o){return e.__spreadArray([i],Array.isArray(o)?o:null==o?[]:[o],!0)};exports.PageCheckActionEnum=void 0,(m=exports.PageCheckActionEnum||(exports.PageCheckActionEnum={})).YES="YES",m.NO="NO";exports.default=function(r){var t,n=r.headerName,a=void 0===n?"Page Type Check":n,s=r.title,l=r.pageNo,d=r.content,c=r.cognitiveScore,u=r.pageType,h=r.metadata,m=r.onActionConfirm,S=r.onCognitiveClick,w=r.onClose,E=r.showCognitiveIntegrity,q=void 0===E||E,D=r.showCloseButton,P=void 0===D||D,z=r.confirmDisabled,I=void 0!==z&&z,B=r.disableAllActions,N=void 0!==B&&B,T=r.width,W=void 0===T?260:T,O=r.maxWidth,R=void 0===O?260:O,Y=r.className,H=r.styles,M=null!==(t=null!=u?u:null==h?void 0:h.page_type)&&void 0!==t?t:"table",G=null!=d?d:"We're not fully confident about the type of this page. Is this page a ".concat(M,"?"),J=N||I||!m,K=o.useCallback(function(){J||null==m||m(exports.PageCheckActionEnum.YES,{action:exports.PageCheckActionEnum.YES,pageType:M,metadata:h})},[J,m,M,h]),L=o.useCallback(function(){J||null==m||m(exports.PageCheckActionEnum.NO,{action:exports.PageCheckActionEnum.NO,pageType:M,metadata:h})},[J,m,M,h]);return i.jsx(y.default,e.__assign({className:Y,elevation:0,sx:A({width:W,maxWidth:R,borderTop:"4px solid",borderColor:"error.main",borderRadius:2,bgcolor:"background.paper",boxSizing:"border-box",boxShadow:"0 8px 16px rgba(16, 24, 40, 0.2)","@media (max-width: 372px)":{width:"calc(100vw - 32px)"}},null==H?void 0:H.root)},{children:i.jsx(b.default,e.__assign({sx:{overflow:"hidden"}},{children:i.jsxs(k.default,e.__assign({spacing:.75,sx:{p:1}},{children:[i.jsxs(k.default,e.__assign({direction:"row",alignItems:"center",spacing:.75,sx:null==H?void 0:H.header},{children:[i.jsx(f.default,{color:"error",height:16,width:16}),i.jsx(F.default,e.__assign({sx:{flex:1,color:"error.main",fontSize:12,fontWeight:500,lineHeight:1.25,textTransform:"uppercase"}},{children:a})),P&&i.jsx(j.default,e.__assign({size:"small",onClick:w,disabled:!w,"aria-label":"Close page check",sx:{p:0,"&.Mui-disabled":{color:"text.secondary"}}},{children:i.jsx(C.default,{sx:{fontSize:17}})}))]})),i.jsxs(b.default,{children:[i.jsx(F.default,e.__assign({sx:{color:"text.primary",fontSize:14,fontWeight:500}},{children:s})),null!=l&&i.jsx(F.default,e.__assign({sx:{mt:.125,color:"text.secondary",fontSize:12}},{children:l})),i.jsx(v.default,{sx:{my:.625}}),null!=G&&i.jsx(F.default,e.__assign({component:"div",sx:{color:"text.secondary",fontSize:11.5,lineHeight:1.3}},{children:G}))]}),i.jsxs(k.default,e.__assign({direction:"row",spacing:.75},{children:[i.jsx(_.default,e.__assign({variant:"outlined",fullWidth:!0,disabled:J,onClick:L,sx:A({minHeight:32,borderRadius:2,fontSize:13,fontWeight:600,textTransform:"none",borderColor:"#D0D5DD",color:"#475569",backgroundColor:"#FFFFFF","&:hover":{backgroundColor:"#F8FAFC",borderColor:"#D0D5DD"},"&.Mui-disabled":{backgroundColor:"#F3F4F6",color:"#9CA3AF",borderColor:"#E5E7EB"}},null==H?void 0:H.noButton)},{children:"No"})),i.jsx(_.default,e.__assign({variant:"contained",fullWidth:!0,disabled:J,onClick:K,sx:A({minHeight:32,borderRadius:2,fontSize:13,fontWeight:600,textTransform:"none",backgroundColor:"#5925DC","&:hover":{backgroundColor:"#4A1FB8"},"&.Mui-disabled":{backgroundColor:"#D9D6FE",color:"#FFFFFF"}},null==H?void 0:H.yesButton)},{children:"Yes"}))]})),i.jsx(k.default,e.__assign({spacing:.625,sx:null==H?void 0:H.footer},{children:q&&i.jsxs(i.Fragment,{children:[i.jsx(v.default,{}),i.jsxs(b.default,e.__assign({onClick:S,sx:{display:"flex",justifyContent:"space-between",alignItems:"center",borderRadius:1,cursor:S?"pointer":"not-allowed","&:hover":S?{opacity:.8}:{}}},{children:[i.jsxs(k.default,e.__assign({direction:"row",alignItems:"center",spacing:1},{children:[i.jsx(x.default,{sx:{color:"text.secondary"}}),i.jsx(F.default,e.__assign({sx:{color:"text.primary",fontSize:12}},{children:"Cognitive Integrity"}))]})),i.jsxs(k.default,e.__assign({direction:"row",alignItems:"center",spacing:.75},{children:[i.jsx(g.default,{score:c}),i.jsx(p.default,{sx:{color:"text.secondary",fontSize:18}})]}))]}))]})}))]}))}))}))},exports.isPageCheckAction=function(e){return Object.values(exports.PageCheckActionEnum).includes(e)};
2
- //# sourceMappingURL=PageCheck.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PageCheck.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),r=require("react/jsx-runtime"),t=require("react"),n=require("@mui/material/Box"),i=require("@mui/material/Button"),s=require("@mui/material/ButtonBase"),a=require("@mui/material/Divider"),o=require("@mui/material/Stack"),l=require("@mui/material/Tooltip"),d=require("@mui/material/Typography"),c=require("lucide-react");function u(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var f=u(n),x=u(i),g=u(s),h=u(a),_=u(o),m=u(l),p=u(d),b=function(e){var r=e.startPage,t=e.endPage;return"Pages ".concat(r,"-").concat(t)},v=function(t){var n=t.segment;return r.jsxs(f.default,e.__assign({sx:{px:.75,py:.625,minWidth:0}},{children:[r.jsx(p.default,e.__assign({sx:{color:"text.secondary",fontSize:11,lineHeight:1.3,overflowWrap:"anywhere"}},{children:n.title})),r.jsx(p.default,e.__assign({sx:{color:"text.primary",fontSize:12,fontWeight:400,lineHeight:1.3}},{children:b(n)}))]}))};var j={minHeight:34,borderColor:"#94A3B8",color:"#64748B",borderRadius:"8px",fontSize:12,fontWeight:500,textTransform:"none"},y={minHeight:34,borderRadius:"8px",bgcolor:"#4F46E5",fontSize:12,fontWeight:500,textTransform:"none",boxShadow:"none","&:hover":{bgcolor:"#4338CA",boxShadow:"none"}};exports.default=function(n){var i=this,s=n.icon,a=n.title,o=n.pageRange,l=n.description,d=n.onRevert,u=n.onRevertComplete,b=n.onRevertError,C=n.revertData,S=n.confirmDisabled,w=void 0!==S&&S,R=n.showDocumentHeader,W=void 0===R||R,F=t.useState(!1),z=F[0],k=F[1],H=t.useState(!1),q=H[0],A=H[1],B=C.previousSegments.length>0,E=function(){return e.__awaiter(i,void 0,void 0,function(){var r,t;return e.__generator(this,function(e){switch(e.label){case 0:if(q||w)return[2];A(!0),e.label=1;case 1:return e.trys.push([1,3,4,5]),[4,d()];case 2:return r=e.sent(),null==u||u(r),[3,5];case 3:return t=e.sent(),null==b||b(t),[3,5];case 4:return A(!1),[7];case 5:return[2]}})})};return r.jsxs(_.default,e.__assign({spacing:.875,sx:{minWidth:0}},{children:[W&&r.jsxs(f.default,e.__assign({sx:{minWidth:0}},{children:[r.jsx(p.default,e.__assign({sx:{color:"text.primary",fontSize:14,fontWeight:500,lineHeight:1.4,overflowWrap:"anywhere"}},{children:a})),r.jsx(p.default,e.__assign({sx:{color:"text.secondary",fontSize:12,lineHeight:1.4}},{children:o}))]})),l&&r.jsxs(_.default,e.__assign({direction:"row",alignItems:"flex-start",spacing:.625,sx:{px:.75,py:.625,border:"1px solid #86EFAC",borderRadius:2,bgcolor:"#FFFFFF",color:"#16A34A"}},{children:[r.jsx(f.default,e.__assign({"aria-hidden":"true",sx:{display:"flex",flexShrink:0,mt:"1px",fontSize:14}},{children:s})),r.jsx(p.default,e.__assign({sx:{minWidth:0,color:"inherit",fontSize:11,lineHeight:1.5,overflowWrap:"anywhere"}},{children:l}))]})),r.jsx(h.default,{sx:{borderStyle:"dashed",borderColor:"#CBD5E1"}}),z?r.jsxs(_.default,e.__assign({spacing:.75},{children:[r.jsxs(g.default,e.__assign({onClick:function(){return k(!1)},"aria-label":"Back from revert confirmation",sx:{width:"fit-content",borderRadius:.5,color:"text.primary",fontSize:13,fontWeight:500,lineHeight:1.3,textAlign:"left"}},{children:[r.jsx(f.default,e.__assign({component:"span","aria-hidden":"true",sx:{mr:.625,alignItems:"center",display:"flex"}},{children:r.jsx(c.ChevronLeft,{size:16})})),"Revert"]})),B?r.jsxs(f.default,e.__assign({sx:{p:.75,borderRadius:1,bgcolor:"#F8FAFC"}},{children:[r.jsx(p.default,e.__assign({sx:{mb:.375,color:"text.secondary",fontSize:12}},{children:"Current"})),r.jsx(f.default,e.__assign({sx:{mb:.75,border:"1px solid #E2E8F0",borderRadius:1,bgcolor:"background.paper"}},{children:r.jsx(v,{segment:C.currentSegment})})),r.jsx(p.default,e.__assign({sx:{mb:.375,color:"text.secondary",fontSize:12}},{children:"After Revert"})),r.jsx(f.default,e.__assign({sx:{border:"1px solid #E2E8F0",borderRadius:1,bgcolor:"background.paper",overflow:"hidden"}},{children:C.previousSegments.map(function(e,t){return r.jsxs(f.default,{children:[t>0&&r.jsx(h.default,{sx:{borderColor:"#E2E8F0"}}),r.jsx(v,{segment:e})]},"".concat(e.title,"-").concat(e.startPage,"-").concat(e.endPage,"-").concat(t))})})),r.jsxs(_.default,e.__assign({direction:"row",spacing:1,sx:{mt:.875}},{children:[r.jsx(x.default,e.__assign({variant:"outlined",fullWidth:!0,disabled:q,onClick:function(){return k(!1)},sx:j},{children:"Cancel"})),r.jsx(m.default,e.__assign({title:w?"Revert data is not present, cannot revert this":"",disableHoverListener:!w,arrow:!0},{children:r.jsx("span",e.__assign({style:{flex:1}},{children:r.jsx(x.default,e.__assign({variant:"contained",fullWidth:!0,disabled:q||w,onClick:function(){E()},sx:y},{children:q?"Reverting…":"Confirm"}))}))}))]}))]})):r.jsxs(f.default,e.__assign({sx:{p:.875,borderRadius:1,bgcolor:"#F8FAFC"}},{children:[r.jsx(p.default,e.__assign({sx:{color:"text.secondary",fontSize:12,fontWeight:500}},{children:"Revert approval?"})),r.jsx(p.default,e.__assign({sx:{mt:.75,color:"text.secondary",fontSize:13,lineHeight:1.45}},{children:"This document will be moved back to pending review and will need to be confirmed again."})),r.jsxs(_.default,e.__assign({direction:"row",spacing:1,sx:{mt:1}},{children:[r.jsx(x.default,e.__assign({variant:"outlined",fullWidth:!0,disabled:q,onClick:function(){return k(!1)},sx:j},{children:"Cancel"})),r.jsx(m.default,e.__assign({title:w?"Revert data is not present, cannot revert this":"",disableHoverListener:!w,arrow:!0},{children:r.jsx("span",e.__assign({style:{flex:1}},{children:r.jsx(x.default,e.__assign({variant:"contained",fullWidth:!0,disabled:q||w,onClick:function(){E()},sx:y},{children:q?"Reverting…":"Confirm"}))}))}))]}))]}))]})):r.jsx(x.default,e.__assign({variant:"outlined",fullWidth:!0,onClick:function(){return k(!0)},sx:{minHeight:36,borderColor:"#9B8AFB",color:"#5925DC",borderRadius:2,fontSize:13,fontWeight:600,textTransform:"none","&:hover":{borderColor:"secondary.dark",bgcolor:"rgba(79, 70, 229, 0.04)"}}},{children:"Revert"}))]}))};
2
- //# sourceMappingURL=RevertCard.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"RevertCard.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),r=require("react/jsx-runtime"),i=require("@mui/icons-material/ArrowForward"),t=require("@mui/material/Box"),o=require("@mui/material/Button"),l=require("@mui/material/Paper"),a=require("@mui/material/Stack"),n=require("@mui/material/Typography"),s=require("lucide-react");function d(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var u=d(i),c=d(t),x=d(o),g=d(l),h=d(a),f=d(n);exports.default=function(i){var t=i.title,o=i.description,l=i.onReview,a=i.reviewLabel,n=void 0===a?"Review":a;return r.jsx(g.default,e.__assign({elevation:0,role:"status",sx:{width:"100%",px:1.5,py:1.5,border:"1.5px solid #86EFAC",borderRadius:2,bgcolor:"#F0FDF4",boxSizing:"border-box"}},{children:r.jsxs(h.default,e.__assign({alignItems:"center",spacing:1.5,sx:{textAlign:"center"}},{children:[r.jsx(c.default,e.__assign({sx:{display:"grid",placeItems:"center",width:58,height:58,border:"8px solid rgba(255, 255, 255, 0.9)",borderRadius:"50%",bgcolor:"#DCFCE7",color:"#0A9B49"}},{children:r.jsx(s.CheckCircleIcon,{height:36,width:36})})),r.jsxs(c.default,{children:[r.jsx(f.default,e.__assign({sx:{color:"#166534",fontSize:15,fontWeight:600,lineHeight:1.4}},{children:t})),r.jsx(f.default,e.__assign({sx:{mt:.75,color:"#07883F",fontSize:14,lineHeight:1.55}},{children:o}))]}),r.jsx(x.default,e.__assign({variant:"outlined",fullWidth:!0,onClick:l,endIcon:r.jsx(u.default,{}),sx:{minHeight:42,border:"1.5px solid #CBD5E1",borderRadius:2,bgcolor:"#FFFFFF",color:"#475569",fontSize:16,fontWeight:700,textTransform:"none","&:hover":{borderColor:"#94A3B8",bgcolor:"#FFFFFF"}}},{children:n}))]}))}))};
2
- //# sourceMappingURL=RevertSuccessCard.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"RevertSuccessCard.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),r=require("react/jsx-runtime"),i=require("@mui/material/Box"),t=require("@mui/material/Typography"),a=require("lucide-react");function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var l=o(i),s=o(t);exports.default=function(i){var t=i.children;return r.jsxs(l.default,e.__assign({sx:{display:"flex",alignItems:"flex-start",gap:1,px:1,py:1.125,border:"1px solid #FACC15",borderRadius:1.5,bgcolor:"#FFFBEB",color:"#D18A00"}},{children:[r.jsx(a.GitMerge,{size:18,strokeWidth:2.25,style:{flex:"0 0 auto",marginTop:1}}),r.jsx(s.default,e.__assign({component:"div",sx:{color:"inherit",fontSize:12,lineHeight:1.5,overflowWrap:"anywhere"}},{children:t}))]}))};
2
- //# sourceMappingURL=RevertSummaryNotice.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"RevertSummaryNotice.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),t=require("react"),n=require("@mui/icons-material/ExpandMore"),r=require("@mui/material/Box"),o=require("@mui/material/Button"),s=require("@mui/material/ButtonBase"),a=require("@mui/material/Divider"),d=require("@mui/material/Paper"),l=require("@mui/material/Radio"),u=require("@mui/material/Stack"),c=require("@mui/material/TextField"),f=require("@mui/material/Typography"),x=require("./BoundaryCard.js"),m=require("../../assests/icons/InfoAlert.js");function g(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var p=g(n),h=g(r),_=g(o),b=g(s),E=g(a),v=g(d),C=g(l),j=g(u),F=g(c),y=g(f),A="MERGE_ADJACENT",S=function(e){return(null==e?void 0:e.additional_decisions)?Array.from(new Set(Object.values(e.additional_decisions).flat())).filter(function(e){return Object.values(x.BoundaryReviewActionEnum).includes(e)}):[]};exports.default=function(n){var r=n.metadata,o=n.reviewAction,s=n.startPage,a=n.endPage,d=n.title,l=void 0===d?"this document":d,u=n.previousSegmentTitle,c=n.nextSegmentTitle,f=n.disabled,g=void 0!==f&&f,R=n.onConfirm,w=t.useMemo(function(){return S(o)},[o]),B=t.useMemo(function(){return function(e,i,t,n){var r=i.focus_page,o=null!=r&&r===t,s=null!=r&&(r===n||r===n+1),a=[];if(e.some(function(e){return e.includes("MERGE")})&&a.push(t===n||!o&&!s?{id:A,title:"Merge with an adjacent document",description:"Choose to merge with the previous or next document."}:o?{id:x.BoundaryReviewActionEnum.MERGE_PREVIOUS,title:"Merge with previous document",description:"Combine this document with the previous document."}:{id:x.BoundaryReviewActionEnum.MERGE_NEXT,title:"Merge with next document",description:"Combine this document with the next document."}),e.includes(x.BoundaryReviewActionEnum.SPLIT_HERE)){var d=null!=r&&r>t&&r<n;a.push({id:x.BoundaryReviewActionEnum.SPLIT_HERE,title:"Split to a separate document",description:d?"Start a new document at page ".concat(r,"."):"A valid page inside the document is required to split it.",disabled:!d})}return a}(w,r,s,a)},[w,a,r,s]),M=t.useState(null),T=M[0],z=M[1],I=t.useState(null),q=I[0],G=I[1],P=t.useState(String(s)),W=P[0],D=P[1],N=t.useState(String(a)),k=N[0],H=N[1],O=t.useState(!1),U=O[0],V=O[1],X=t.useState(!1),L=X[0],J=X[1],$=w.includes(x.BoundaryReviewActionEnum.SET_RANGE);if(0===B.length&&!$)return null;var K=null==T?void 0:B[T],Q=(null==K?void 0:K.id)===A,Y=null!=u,Z=null!=c,ee=function(e){return!0===e.disabled||e.id===x.BoundaryReviewActionEnum.MERGE_PREV&&!Y||e.id===x.BoundaryReviewActionEnum.MERGE_PREVIOUS&&!Y||e.id===x.BoundaryReviewActionEnum.MERGE_NEXT&&!Z||e.id===A&&!Y&&!Z},ie=Number(W),te=Number(k),ne=""!==W.trim()&&""!==k.trim()&&Number.isInteger(ie)&&Number.isInteger(te)&&ie>0&&ie<=te,re=g||!K||ee(K)||Q&&null==q;return i.jsxs(j.default,e.__assign({spacing:.75},{children:[i.jsx(E.default,{}),i.jsx(y.default,e.__assign({sx:{color:"text.primary",fontSize:12,fontWeight:600}},{children:"Additional actions"})),i.jsx(j.default,e.__assign({spacing:.625,role:"radiogroup","aria-label":"Additional boundary actions"},{children:B.map(function(t,n){var r=T===n,o=ee(t);return i.jsxs(v.default,e.__assign({variant:"outlined",sx:{borderColor:r?"#7F56D9":"divider",borderRadius:2,bgcolor:o?"#F8FAFC":"background.paper",overflow:"hidden"}},{children:[i.jsxs(b.default,e.__assign({role:"radio","aria-checked":r,disabled:g||o,onClick:function(){z(n),t.id!==A&&G(null)},sx:{width:"100%",justifyContent:"flex-start",px:.75,py:.5,textAlign:"left"}},{children:[i.jsx(C.default,{checked:r,disabled:g||o,tabIndex:-1,size:"small",sx:{p:.25,mr:.5}}),i.jsxs(h.default,e.__assign({sx:{minWidth:0}},{children:[i.jsx(y.default,e.__assign({sx:{color:o?"#94A3B8":"text.primary",fontSize:12.5,fontWeight:500}},{children:t.title})),null!=t.description&&i.jsx(y.default,e.__assign({sx:{mt:.125,color:o?"#94A3B8":"text.secondary",fontSize:11}},{children:t.description}))]}))]})),r&&Q&&i.jsx(j.default,e.__assign({direction:"row",spacing:.75,sx:{px:.75,pb:.75}},{children:[["previous",null!=u?u:"No previous document",Y],["next",null!=c?c:"No next document",Z]].map(function(t){var n=t[0],r=t[1],o=t[2];return i.jsx(b.default,e.__assign({disabled:g||!o,onClick:function(){return G(n)},"aria-pressed":q===n,sx:{flex:1,minWidth:0,minHeight:42,alignItems:"flex-start",justifyContent:"flex-start",p:.625,border:"1px solid",borderColor:q===n?"#7F56D9":"#D0D5DD",borderRadius:1.5,color:o?"text.primary":"#98A2B3",textAlign:"left"}},{children:i.jsx(y.default,e.__assign({sx:{color:"inherit",fontSize:11,fontWeight:500,overflowWrap:"anywhere"}},{children:r}))}),n)})}))]}),t.id)})})),i.jsx(_.default,e.__assign({variant:"contained",fullWidth:!0,disabled:re,onClick:function(){if(!re&&K&&null!=T){var i=Q?"previous"===q?x.BoundaryReviewActionEnum.MERGE_PREVIOUS:x.BoundaryReviewActionEnum.MERGE_NEXT:K.id;R(i,{selectedIndex:T,option:e.__assign(e.__assign({},K),{id:i}),metadata:r})}},sx:{minHeight:32,borderRadius:2,bgcolor:"#5925DC",fontSize:13,fontWeight:600,textTransform:"none","&:hover":{bgcolor:"#4A1FB8"}}},{children:"Confirm"})),$&&i.jsxs(j.default,e.__assign({spacing:.625},{children:[i.jsxs(b.default,e.__assign({disabled:g,onClick:function(){var e=!U;V(e),J(!1),e&&(z(null),G(null))},"aria-expanded":U,sx:{width:"100%",justifyContent:"space-between",borderRadius:1,textAlign:"left"}},{children:[i.jsx(y.default,e.__assign({sx:{color:"text.primary",fontSize:12,fontWeight:600}},{children:"Set a custom boundary"})),i.jsx(p.default,{sx:{color:"text.secondary",fontSize:16,transform:U?"rotate(180deg)":"none",transition:"transform 150ms ease"}})]})),U&&!L&&i.jsxs(h.default,e.__assign({sx:{pt:.5,fontFamily:'Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif'}},{children:[i.jsxs(h.default,e.__assign({sx:{display:"grid",gridTemplateColumns:"1fr 1fr",columnGap:"8px",mb:"4px"}},{children:[i.jsx(y.default,e.__assign({sx:{fontSize:"10.5px",lineHeight:"14px",color:"#57697E"}},{children:"Starts"})),i.jsx(y.default,e.__assign({sx:{fontSize:"10.5px",lineHeight:"14px",color:"#57697E"}},{children:"Ends"}))]})),i.jsx(h.default,e.__assign({sx:{display:"grid",gridTemplateColumns:"1fr 1fr",columnGap:"8px",mb:"4px"}},{children:[[W,D],[k,H]].map(function(e,t){var n=e[0],r=e[1];return i.jsx(F.default,{size:"small",type:"text",value:n,disabled:g,error:1===t&&""!==W.trim()&&""!==k.trim()&&ie>te,onChange:function(e){return/^\d*$/.test(e.target.value)&&r(e.target.value)},inputProps:{inputMode:"numeric",pattern:"[0-9]*"},sx:{"& .MuiOutlinedInput-root":{height:"30px",bgcolor:"#FFFFFF","& fieldset":{borderColor:"#C3CFDC",borderRadius:"6px"},"&:hover fieldset":{borderColor:"#C3CFDC"},"&.Mui-focused fieldset":{borderColor:"#9488F6",borderWidth:"1px"}},"& .MuiOutlinedInput-input":{height:"30px",p:"0 10px",color:"#34445A",fontSize:"12px"}}},0===t?"starts":"ends")})})),i.jsx(_.default,e.__assign({onClick:function(){return J(!0)},disabled:g||!ne,sx:{height:"30px",px:"12px",bgcolor:"#FFFFFF",border:"1px solid #8E80F3",borderRadius:"6px",color:"#4A24CF",fontSize:"12px",fontWeight:600,textTransform:"none","&:hover":{bgcolor:"#FAF9FF",borderColor:"#7F6FF0"},"&.Mui-disabled":{bgcolor:"#FFFFFF",borderColor:"#C3CFDC",color:"#A0ABBE"}}},{children:"Apply"})),i.jsx(h.default,{sx:{width:"100%",height:"1px",mt:"8px",bgcolor:"#EEF0F2"}})]})),U&&L&&i.jsxs(j.default,e.__assign({spacing:.75,sx:{p:.75,borderRadius:1.5,bgcolor:"#FFF7ED"}},{children:[i.jsxs(j.default,e.__assign({direction:"row",alignItems:"center",spacing:.5},{children:[i.jsx(m.default,{color:"warning",height:14,width:14}),i.jsx(y.default,e.__assign({sx:{color:"#EA580C",fontSize:11,fontWeight:600}},{children:"Confirm this change?"}))]})),i.jsxs(y.default,e.__assign({sx:{color:"text.secondary",fontSize:10.5,lineHeight:1.4}},{children:["Pages ",ie,"-",te," will become part of ",l,", including pages from other documents in this range."]})),i.jsxs(j.default,e.__assign({direction:"row",spacing:.75},{children:[i.jsx(_.default,e.__assign({variant:"outlined",fullWidth:!0,onClick:function(){return J(!1)},sx:{minHeight:28,borderRadius:1.5,fontSize:11,textTransform:"none"}},{children:"Cancel"})),i.jsx(_.default,e.__assign({variant:"contained",fullWidth:!0,disabled:g,onClick:function(){if(!g&&ne){var e={id:x.BoundaryReviewActionEnum.SET_RANGE,title:"Set a custom boundary"};R(x.BoundaryReviewActionEnum.SET_RANGE,{selectedIndex:-1,option:e,metadata:r,startPage:ie,endPage:te})}},sx:{minHeight:28,borderRadius:1.5,bgcolor:"#EA580C",fontSize:11,textTransform:"none","&:hover":{bgcolor:"#C2410C"}}},{children:"Confirm"}))]}))]}))]}))]}))},exports.getAdditionalBoundaryActions=S;
2
- //# sourceMappingURL=ReviewedBoundaryActions.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ReviewedBoundaryActions.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),r=require("@mui/icons-material/ChevronRight"),t=require("@mui/icons-material/Close"),s=require("@mui/material/Box"),n=require("@mui/material/ButtonBase"),a=require("@mui/material/Divider"),o=require("@mui/material/IconButton"),l=require("@mui/material/Paper"),d=require("@mui/material/Stack"),c=require("@mui/material/Typography"),u=require("../../assests/icons/InfoAlert.js"),x=require("./CognitiveIcon.js"),f=require("./CognitiveScoreBadge.js");function h(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var g=h(r),m=h(t),p=h(s),v=h(n),_=h(a),j=h(o),w=h(l),y=h(d),b=h(c),C=function(i,r){return e.__spreadArray([i],Array.isArray(r)?r:null==r?[]:[r],!0)};exports.default=function(r){var t=r.headerName,s=void 0===t?"Reviewed":t,n=r.headerIcon,a=r.title,o=r.pageNo,l=r.summary,d=r.additionalActions,c=r.cognitiveScore,h=r.onCognitiveClick,q=r.onClose,W=r.cognitiveLabel,S=void 0===W?"Cognitive Integrity":W,I=r.showCognitiveIntegrity,A=void 0===I||I,k=r.showCloseButton,z=void 0===k||k,B=r.width,N=void 0===B?260:B,R=r.maxWidth,D=void 0===R?260:R,F=r.className,M=r.styles;return i.jsxs(w.default,e.__assign({className:F,elevation:4,sx:C({width:N,maxWidth:"min(".concat(D,"number"==typeof D?"px, 100%)":", 100%)"),minWidth:0,flexShrink:1,borderRadius:2,bgcolor:"background.paper",overflow:"hidden",boxSizing:"border-box",boxShadow:"0 8px 16px rgba(16, 24, 40, 0.16)","@media (max-width: 372px)":{width:"calc(100vw - 32px)"}},null==M?void 0:M.root)},{children:[i.jsxs(y.default,e.__assign({direction:"row",alignItems:"center",spacing:.75,sx:C({minWidth:0,px:1.25,py:1,bgcolor:"#ECFDF5",color:"#16A34A"},null==M?void 0:M.header)},{children:[null!=n?n:i.jsx(u.default,{color:"success",height:16,width:16}),i.jsx(b.default,e.__assign({sx:{flex:1,minWidth:0,color:"inherit",fontSize:13,fontWeight:500,lineHeight:1.25,textTransform:"uppercase",overflowWrap:"anywhere"}},{children:s})),z&&i.jsx(j.default,e.__assign({size:"small",onClick:q,disabled:!q,"aria-label":"Close reviewed card",sx:{p:0,color:"#475569","&.Mui-disabled":{color:"text.secondary"}}},{children:i.jsx(m.default,{sx:{fontSize:17}})}))]})),i.jsxs(y.default,e.__assign({spacing:.875,sx:{px:1.25,pt:1.25,pb:1}},{children:[i.jsxs(p.default,{children:[i.jsx(b.default,e.__assign({sx:{color:"text.primary",fontSize:14,fontWeight:500,overflowWrap:"anywhere"}},{children:a})),null!=o&&i.jsx(b.default,e.__assign({sx:{mt:.125,color:"text.secondary",fontSize:12}},{children:o}))]}),null!=l&&i.jsx(y.default,e.__assign({sx:null==M?void 0:M.content},{children:l})),null!=d&&i.jsx(y.default,{children:d}),A&&i.jsxs(y.default,e.__assign({spacing:.625,sx:null==M?void 0:M.footer},{children:[i.jsx(_.default,{}),i.jsxs(v.default,e.__assign({onClick:h,disabled:!h,sx:{width:"100%",minWidth:0,justifyContent:"space-between",borderRadius:1,textAlign:"left",cursor:h?"pointer":"not-allowed"}},{children:[i.jsxs(y.default,e.__assign({direction:"row",alignItems:"center",spacing:1,sx:{minWidth:0,flex:1}},{children:[i.jsx(x.default,{sx:{color:"text.secondary"}}),i.jsx(b.default,e.__assign({sx:{minWidth:0,color:"text.primary",fontSize:12,overflowWrap:"anywhere"}},{children:S}))]})),i.jsxs(y.default,e.__assign({direction:"row",alignItems:"center",spacing:.5,sx:{flexShrink:0}},{children:[i.jsx(f.default,{score:c}),i.jsx(g.default,{sx:{color:"text.secondary"}})]}))]}))]}))]}))]}))};
2
- //# sourceMappingURL=ReviewedCard.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ReviewedCard.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,n,t=require("tslib"),i=require("react/jsx-runtime"),r=require("react"),o=require("@react-pdf-viewer/core"),a=require("../PdfViewer/PdfViewer.js"),l=require("./BoundaryCard.js"),u=require("./CardWrapper.js"),d=require("./CognitiveIntegrity.js"),s=require("./LabelCheck.js"),g=require("./PageCheck.js"),c=require("./reviewStepAdapters.js"),v=require("lucide-react"),m=require("@mui/material"),p=require("./ReviewedCard.js"),f=require("./ReviewedBoundaryActions.js"),w=require("./RevertCard.js"),_=require("./RevertSuccessCard.js"),h=require("./helper.js"),y=require("./ChartBreakoutCircle.js"),b=260;exports.SegmentPdfSpecialZoomLevel=void 0,(n=exports.SegmentPdfSpecialZoomLevel||(exports.SegmentPdfSpecialZoomLevel={})).ActualSize="ActualSize",n.PageFit="PageFit",n.PageWidth="PageWidth";var S=((e={})[exports.SegmentPdfSpecialZoomLevel.ActualSize]=o.SpecialZoomLevel.ActualSize,e[exports.SegmentPdfSpecialZoomLevel.PageFit]=o.SpecialZoomLevel.PageFit,e[exports.SegmentPdfSpecialZoomLevel.PageWidth]=o.SpecialZoomLevel.PageWidth,e),x=function(e){return{reviewId:e.id,segment:e.segment,pageNumber:e.pageNumber}};exports.default=function(e){var n,R,E,C,P,k,A,M,I,j,B,N,L,F,T,q,K,W,z,G,O,D,V,H,U,Z,X,Y,J,Q,$,ee,ne,te,ie=this,re=e.pdfUrl,oe=e.pdfName,ae=e.segments,le=e.totalPages,ue=e.styles,de=e.pdfViewerProps,se=e.specialZoomLevel,ge=e.showBadges,ce=void 0===ge||ge,ve=e.sortByConfidence,me=void 0===ve?"low":ve,pe=e.filterByConfidence,fe=void 0===pe?"all":pe,we=e.showBadgeNavigation,_e=void 0===we||we,he=e.autoSelectReviewOnPageChange,ye=void 0!==he&&he,be=e.autoAdvanceAfterConfirm,Se=void 0===be||be,xe=e.autoAdvanceScoreBand,Re=e.badgePreloadPages,Ee=void 0===Re?8:Re,Ce=e.badgeOffsetTop,Pe=void 0===Ce?20:Ce,ke=e.badgeOffsetRight,Ae=void 0===ke?68:ke,Me=e.badgeOffsetLeft,Ie=void 0===Me?0:Me,je=e.initialReviewId,Be=e.manualPrompt,Ne=e.heightBuffer,Le=e.onBoundaryAction,Fe=e.onLabelAction,Te=e.onPageAction,qe=e.onPageTypeRevert,Ke=e.onRevert,We=e.onActiveReviewChange,ze=e.onCurrentPageChange,Ge=e.onActionError,Oe=e.disableAllActions,De=void 0!==Oe&&Oe,Ve=e.disablePdfAnnotations,He=void 0!==Ve&&Ve,Ue=e.disablePdfTextLayer,Ze=void 0===Ue||Ue,Xe=e.disableTitleCheckUntilBoundaryCheckCompleted,Ye=void 0!==Xe&&Xe,Je=e.onAdjustManually,Qe=e.onCognitiveClick,$e=e.className,en=e.style,nn=e.viewerStyle,tn=e.railStyle,rn=e.redirectionData,on=e.onBadgeSelected,an=r.useMemo(function(){return c.extractSegmentReviewData(ae)},[ae]),ln=an.boundaryReviews,un=an.labelReviews,dn=an.pageReviews,sn=r.useState(function(){return new Map}),gn=sn[0],cn=sn[1],vn=r.useState(function(){return new Set}),mn=vn[0],pn=vn[1],fn=r.useMemo(function(){var e=new Map,n=1;return ae.forEach(function(t,i){var r=c.getSegmentReviewKey(t,i);e.has(r)||(e.set(r,n),n+=1)}),e},[ae]),wn=r.useMemo(function(){return new Set(un.map(function(e){return c.getSegmentReviewKey(e.segment)}))},[un]),_n=r.useMemo(function(){return h.getPendingMergeImpactedSegmentKeys(ae)},[ae]);r.useEffect(function(){cn(function(e){var n=!1,t=new Map(e);return e.forEach(function(e,i){var r=ae.find(function(e){return c.getSegmentReviewKey(e)===i});r&&!h.hasPolledStructuralAction(r,e)||(t.delete(i),n=!0)}),n?t:e})},[ae]),r.useEffect(function(){pn(function(e){var n=!1,t=new Set(e);return e.forEach(function(e){gn.has(e)||(t.delete(e),n=!0)}),n?t:e})},[gn]);var hn=r.useMemo(function(){return h.getOptimisticMergeImpactedSegmentKeys(ae,gn,mn)},[mn,gn,ae]),yn=r.useRef(null),bn=r.useMemo(function(){return t.__spreadArray(t.__spreadArray(t.__spreadArray([],ln.filter(function(e){return!_n.has(c.getSegmentReviewKey(e.segment))&&!hn.has(c.getSegmentReviewKey(e.segment))&&!h.shouldHideStructuralBoundaryReview(e.review_step,e.segment,wn.has(c.getSegmentReviewKey(e.segment)),gn.get(c.getSegmentReviewKey(e.segment)))}).map(function(e){var n;return t.__assign(t.__assign({},e),{kind:"boundary",pageNumber:null!==(n=e.metadata.focus_page)&&void 0!==n?n:e.segment.start_page})}),!0),un.filter(function(e){return!_n.has(c.getSegmentReviewKey(e.segment))&&!hn.has(c.getSegmentReviewKey(e.segment))}).map(function(e){return t.__assign(t.__assign({},e),{kind:"label",pageNumber:e.segment.start_page})}),!0),dn.filter(function(e){return!_n.has(c.getSegmentReviewKey(e.segment))&&!hn.has(c.getSegmentReviewKey(e.segment))}).map(function(e){var n;return t.__assign(t.__assign({},e),{kind:"page",pageNumber:null!==(n=e.metadata.page_num)&&void 0!==n?n:e.segment.start_page})}),!0).sort(function(e,n){var t,i,r=null!==(t=fn.get(c.getSegmentReviewKey(e.segment)))&&void 0!==t?t:Number.MAX_SAFE_INTEGER,o=null!==(i=fn.get(c.getSegmentReviewKey(n.segment)))&&void 0!==i?i:Number.MAX_SAFE_INTEGER;return e.pageNumber-n.pageNumber||r-o||e.reviewStepIndex-n.reviewStepIndex||e.id.localeCompare(n.id)})},[ln,un,dn,hn,gn,_n,fn,wn]),Sn=r.useMemo(function(){return ae.map(function(e){var n,i;return t.__assign(t.__assign({},e),{title:(null===(n=e.label)||void 0===n?void 0:n.trim())||e.title,page_count:null!==(i=e.page_count)&&void 0!==i?i:e.end_page-e.start_page+1})})},[ae]),xn=r.useState(1),Rn=xn[0],En=xn[1],Cn=r.useState(null!=je?je:null),Pn=Cn[0],kn=Cn[1],An=r.useState(null!=je?je:null),Mn=An[0],In=An[1],jn=r.useState(!1),Bn=jn[0],Nn=jn[1],Ln=r.useState(null),Fn=Ln[0],Tn=Ln[1],qn=r.useState(null),Kn=qn[0],Wn=qn[1],zn=r.useState(function(){return new Set}),Gn=zn[0],On=zn[1],Dn=r.useState(null),Vn=Dn[0],Hn=Dn[1],Un=r.useState(null),Zn=Un[0],Xn=Un[1],Yn=r.useState(null),Jn=Yn[0],Qn=Yn[1],$n=r.useState(!1),et=$n[0],nt=$n[1],tt=r.useRef(0),it=r.useRef(null),rt=r.useRef(null),ot=r.useRef(new Map),at=r.useRef(null),lt=r.useRef(null),ut=r.useRef(null),dt=r.useState(b),st=dt[0],gt=dt[1],ct=null!==(R=null===(n=null==ue?void 0:ue.aside)||void 0===n?void 0:n.width)&&void 0!==R?R:"40%",vt="min(".concat("number"==typeof ct?"".concat(ct,"px"):ct,", ").concat(b,"px, 100%)");r.useEffect(function(){On(function(e){if(0===e.size)return e;var n=new Set(e),t=!1;return bn.forEach(function(e){var i;null!=(null===(i=e.review_step.review)||void 0===i?void 0:i.action)&&n.has(e.id)&&(n.delete(e.id),t=!0)}),t?n:e})},[bn]),r.useEffect(function(){var e=yn.current;if(e&&ce){var n=function(){var n=e.getBoundingClientRect().width;n>0&&gt(n)};n();var t="undefined"==typeof ResizeObserver?null:new ResizeObserver(n);return null==t||t.observe(e),function(){return null==t?void 0:t.disconnect()}}},[ce]);var mt=r.useMemo(function(){var e=new Set;return bn.forEach(function(n){var t;null!=(null===(t=n.review_step.review)||void 0===t?void 0:t.action)&&e.add(n.id)}),e},[bn]),pt=r.useMemo(function(){var e;return null!==(e=bn.find(function(e){return e.id===Pn}))&&void 0!==e?e:null},[Pn,bn]),ft=r.useMemo(function(){return!(!Ye||"label"!==(null==pt?void 0:pt.kind))&&ln.some(function(e){if(c.getSegmentReviewKey(e.segment)!==c.getSegmentReviewKey(pt.segment)||mt.has(e.id))return!1;var n=h.getResolvedScore(e.review_step.score,e.review_step.confidence);return null==n||n<85})},[pt,ln,Ye,mt]),wt=null==pt?-1:ae.findIndex(function(e){return c.getSegmentReviewKey(e)===c.getSegmentReviewKey(pt.segment)}),_t=wt>0?ae[wt-1]:void 0,ht=wt>=0?ae[wt+1]:void 0,yt=(null===(E=null==_t?void 0:_t.label)||void 0===E?void 0:E.trim())||(null==_t?void 0:_t.title),bt=(null===(C=null==ht?void 0:ht.label)||void 0===C?void 0:C.trim())||(null==ht?void 0:ht.title),St=h.getConfidenceColors(null==pt?void 0:pt.review_step.score,null==pt?void 0:pt.review_step.confidence,null===(P=null==pt?void 0:pt.segment.confidence)||void 0===P?void 0:P.awaiting_llm),xt=(null===(k=null==pt?void 0:pt.review_step.reasons)||void 0===k?void 0:k.length)?pt.review_step.reasons:null!==(M=null===(A=null==pt?void 0:pt.segment.confidence)||void 0===A?void 0:A.reasons)&&void 0!==M?M:[],Rt=Boolean(xt.some(function(e){return e.text.trim()&&["evidence","gap"].includes(e.type.trim().toLowerCase())})||(null===(I=null==pt?void 0:pt.review_step.reason)||void 0===I?void 0:I.trim())||(null===(j=null==pt?void 0:pt.review_step.gap)||void 0===j?void 0:j.trim())),Et=null==pt?null:"boundary"===pt.kind?h.getBoundaryReviewActionBadgeLabel(pt.review_step,pt.segment,gn.get(null!==(B=pt.segment.stable_key)&&void 0!==B?B:"")):h.getTitleReviewActionBadgeLabel(pt.review_step,pt.segment,gn.get(null!==(N=pt.segment.stable_key)&&void 0!==N?N:"")),Ct="label"===(null==pt?void 0:pt.kind)?[Et,pt.review_step.human_action_enum,null===(L=pt.review_step.review)||void 0===L?void 0:L.action,null===(F=pt.review_step.human_resolution)||void 0===F?void 0:F.action]:[],Pt="label"===(null==pt?void 0:pt.kind)&&Ct.some(function(e){var n,t=null!==(n=null==e?void 0:e.trim().toUpperCase())&&void 0!==n?n:"";return t.includes("MERGE")||t.includes("SPLIT")}),kt=null!=pt&&bn.some(function(e){return"boundary"===e.kind&&c.getSegmentReviewKey(e.segment)===c.getSegmentReviewKey(pt.segment)}),At=Pt&&!kt,Mt=("boundary"===(null==pt?void 0:pt.kind)||At)&&null!=pt?function(){var e,n,i,r,o,a;if("boundary"===pt.kind)return pt;var l=ln.find(function(e){return c.getSegmentReviewKey(e.segment)===c.getSegmentReviewKey(pt.segment)});return l?t.__assign(t.__assign({},l),{kind:"boundary",pageNumber:null!==(e=l.metadata.focus_page)&&void 0!==e?e:l.segment.start_page}):t.__assign(t.__assign({},pt),{kind:"boundary",pageNumber:null!==(i=null===(n=pt.segment.review_action)||void 0===n?void 0:n.focus_page)&&void 0!==i?i:pt.segment.start_page,metadata:{focus_page:null!==(o=null===(r=pt.segment.review_action)||void 0===r?void 0:r.focus_page)&&void 0!==o?o:null,boundary_margin:null!==(a=pt.segment.boundary_margin)&&void 0!==a?a:null,user_actions:[]}})}():void 0,It=null==pt?"":(null===(T=pt.segment.label)||void 0===T?void 0:T.trim())||pt.segment.title,jt=null==pt?void 0:pt.review_step.revert,Bt=null==pt?void 0:pt.segment.revert,Nt=function(e){return null==e?void 0:e.trim().toLowerCase()},Lt=null==pt||null===(K=t.__spreadArray([],null!==(q=pt.segment.review_steps)&&void 0!==q?q:[],!0).reverse().find(function(e){var n,t,i=null===(n=e.type)||void 0===n?void 0:n.trim().toLowerCase();return("page_boundary"===i||"page boundary review"===i)&&"boundary"===Nt(null===(t=e.revert)||void 0===t?void 0:t.type)}))||void 0===K?void 0:K.revert,Ft=null!==(W=null!=jt?jt:null==pt?void 0:pt.segment.revert)&&void 0!==W?W:Lt,Tt=null==Ft?void 0:Ft.decision.trim().toUpperCase(),qt=null!=Et?Et:(null==Tt?void 0:Tt.includes("SPLIT"))?"Split":(null==Tt?void 0:Tt.includes("MERGE"))?"Merged":null,Kt="label"===(null==pt?void 0:pt.kind)&&"SET_RANGE"===(null===(z=null==Lt?void 0:Lt.decision)||void 0===z?void 0:z.trim().toUpperCase())&&Lt.current_segment_ids.length!==Lt.previous_state.length,Wt="Merged"===Et||"Split"===Et||Kt,zt=null==pt?void 0:Wt?"boundary"===Nt(null==Lt?void 0:Lt.type)?Lt:"boundary"===Nt(null==Bt?void 0:Bt.type)?Bt:"boundary"===Nt(null==jt?void 0:jt.type)?jt:void 0:"label"===pt.kind?"label"===Nt(null==jt?void 0:jt.type)?jt:void 0:"boundary"===pt.kind?"boundary"===Nt(null==jt?void 0:jt.type)?jt:"boundary"===Nt(null==Lt?void 0:Lt.type)?Lt:"boundary"===Nt(null==Bt?void 0:Bt.type)?Bt:void 0:void 0,Gt=Wt&&(null==zt?void 0:zt.operation_id)?ae.flatMap(function(e){var n;return null!==(n=e.review_steps)&&void 0!==n?n:[]}).find(function(e){var n,t,i,r,o,a,l,u=null===(n=e.type)||void 0===n?void 0:n.trim().toLowerCase();return("page_boundary"===u||"page boundary review"===u)&&((null!==(o=null!==(i=null===(t=e.human_resolution)||void 0===t?void 0:t.operation_id)&&void 0!==i?i:null===(r=e.revert)||void 0===r?void 0:r.operation_id)&&void 0!==o?o:e.operation_id)===zt.operation_id&&Boolean(null===(l=null===(a=e.human_resolution)||void 0===a?void 0:a.change_summary)||void 0===l?void 0:l.trim()))}):void 0,Ot=(null===(G=null==zt?void 0:zt.summary)||void 0===G?void 0:G.trim())||null,Dt=Wt?(null===(D=null===(O=null==Gt?void 0:Gt.human_resolution)||void 0===O?void 0:O.change_summary)||void 0===D?void 0:D.trim())||(null===(V=null==zt?void 0:zt.summary)||void 0===V?void 0:V.trim())||"":(null===(Z=null===(U=null===(H=null==pt?void 0:pt.review_step)||void 0===H?void 0:H.human_resolution)||void 0===U?void 0:U.change_summary)||void 0===Z?void 0:Z.trim())||(null===(Y=null===(X=null==pt?void 0:pt.review_step)||void 0===X?void 0:X.summary)||void 0===Y?void 0:Y.trim())||"",Vt=null==pt?null:zt?{currentSegment:{title:It,startPage:pt.segment.start_page,endPage:pt.segment.end_page},previousSegments:zt.previous_state.map(function(e){var n,t;return{title:(null===(n=e.label)||void 0===n?void 0:n.trim())||(null===(t=e.title)||void 0===t?void 0:t.trim())||"Untitled document",startPage:e.start_page,endPage:e.end_page}})}:"Split"===qt?{currentSegment:{title:It,startPage:pt.segment.start_page,endPage:pt.segment.end_page},previousSegments:[{title:"Advice of Award",startPage:1,endPage:25},{title:It,startPage:pt.segment.start_page,endPage:pt.segment.end_page}]}:"Merged"===qt?{currentSegment:{title:It,startPage:pt.segment.start_page,endPage:pt.segment.end_page},previousSegments:[{title:"Advice of Award",startPage:1,endPage:25},{title:"Request for proposal (RFP)",startPage:26,endPage:76}]}:{currentSegment:{title:It,startPage:pt.segment.start_page,endPage:pt.segment.end_page},previousSegments:[]},Ht="page"===(null==pt?void 0:pt.kind)&&null!==(J=pt.metadata.classification_id)&&void 0!==J?J:null,Ut="page"===(null==pt?void 0:pt.kind)?Boolean(qe&&Ht):Boolean((null==zt?void 0:zt.operation_id)&&(null==zt?void 0:zt.type)&&!1!==(null==zt?void 0:zt.revertable));Boolean(Vt&&Ut&&("page"!==(null==pt?void 0:pt.kind)||Ht));var Zt=r.useCallback(function(e,n){tt.current+=1,it.current={requestId:tt.current,pageNumber:e,reviewId:n},Wn({pageNumber:e,requestId:tt.current})},[]),Xt=r.useCallback(function(e){var n,t;!0!==(null===(n=e.segment.confidence)||void 0===n?void 0:n.awaiting_llm)&&(null==on||on({reviewId:e.id,segment_id:null!==(t=e.segment.segment_id)&&void 0!==t?t:null,reviewStepIndex:e.reviewStepIndex,kind:e.kind,pageNumber:e.pageNumber,metadata:e.metadata}),Xn(null),Qn(null),kn(e.id),In(e.id),Nn(!1),Tn(null),Zt(e.pageNumber,e.id),null==We||We(e.id,e.segment))},[We,on,Zt]);r.useEffect(function(){if(Jn){var e=requestAnimationFrame(function(){return nt(!0)}),n=window.setTimeout(function(){nt(!1)},3500),t=window.setTimeout(function(){Qn(null)},4e3);return function(){cancelAnimationFrame(e),window.clearTimeout(n),window.clearTimeout(t)}}},[Jn]),r.useEffect(function(){var e,n,t,i;if(rn){if("pageGroup"===rn.type){var r=null!==(e=rn.pages)&&void 0!==e?e:[],o=null!==(n=rn.pageIndex)&&void 0!==n?n:0,a=r[o];if(null==a)return;return Yt(),Xn({pages:r,index:o,label:null!==(t=rn.groupLabel)&&void 0!==t?t:""}),tt.current+=1,void Wn({pageNumber:a,requestId:tt.current})}if(Xn(null),rn.reviewId){var l=bn.find(function(e){return e.id===rn.reviewId&&(!rn.type||e.kind===rn.type)});if(l)return void Xt(l)}if(rn.classificationId){var u=bn.find(function(e){return!("page"!==e.kind||e.metadata.classification_id!==rn.classificationId||rn.segmentId&&e.segment.segment_id!==rn.segmentId||rn.type&&e.kind!==rn.type)});if(u)return void Xt(u)}if(rn.pageNumber&&rn.type){var d=Number(rn.pageNumber);if(Number.isInteger(d)&&!(d<1)){var s=null===(i=rn.pageType)||void 0===i?void 0:i.trim().toLowerCase(),g=bn.find(function(e){var n="page"===e.kind?e.pageNumber:e.segment.start_page,t="page"!==e.kind||!s||e.metadata.page_type===s;return(!rn.segmentId||e.segment.segment_id===rn.segmentId)&&n===d&&e.kind===rn.type&&t});g?Xt(g):"page"===rn.type&&(Yt(),tt.current+=1,Wn({pageNumber:d,requestId:tt.current}))}}}},[rn,Xt,bn]);var Yt=r.useCallback(function(){it.current=null,Nn(!1),kn(null),Tn(null),null==We||We(null,null)},[We]),Jt=r.useCallback(function(e){var n;nt(!1),Qn(null);var t=null!==(n=bn.find(function(n){return!mt.has(n.id)&&"boundary"===n.kind&&n.segment.start_page===e.startPage&&n.segment.end_page===e.endPage}))&&void 0!==n?n:bn.find(function(n){return!mt.has(n.id)&&n.segment.start_page<=e.startPage&&n.segment.end_page>=e.startPage});t?Xt(t):(Yt(),tt.current+=1,Wn({pageNumber:e.startPage,requestId:tt.current}))},[Yt,mt,bn,Xt]),Qt=r.useCallback(function(e,n){var t,i=h.getReviewScoreBand(e.review_step.score),r=null==xe||i===xe,o=Gn.has(e.id)&&h.isReviewStepResolutionCurrent(e.review_step,e.segment);return e.id!==n&&r&&!0!==(null===(t=e.segment.confidence)||void 0===t?void 0:t.awaiting_llm)&&!h.isReviewStepResolved(e.review_step,e.segment)&&!o},[xe,Gn]),$t=r.useCallback(function(e){var n;if(Se){var t=bn.findIndex(function(n){return n.id===e}),i=null!==(n=bn.find(function(n,i){return i>t&&Qt(n,e)}))&&void 0!==n?n:bn.find(function(n){return Qt(n,e)});i?requestAnimationFrame(function(){return Xt(i)}):Yt()}else Yt()},[Se,Yt,Qt,bn,Xt]),ei=r.useCallback(function(e,n,i){return t.__awaiter(ie,void 0,void 0,function(){var r,o,a,u,d,s,g,v,m,p;return t.__generator(this,function(t){switch(t.label){case 0:if(De)return[2];if("boundary"===e.kind&&!Le)return[2];if("label"===e.kind&&!Fe)return[2];if("page"===e.kind&&!Te)return[2];r=x(e),a=i,u=(o=n)===l.BoundaryReviewActionEnum.SET_RANGE?function(){var n=a.startPage,t=a.endPage;if(null==n||null==t)return null;var i=n<e.segment.start_page||t>e.segment.end_page,r=n>e.segment.start_page||t<e.segment.end_page;return i&&!r?n<e.segment.start_page?l.BoundaryReviewActionEnum.MERGE_PREV:l.BoundaryReviewActionEnum.MERGE_NEXT:r?l.BoundaryReviewActionEnum.SPLIT_HERE:null}():o,d="boundary"===e.kind&&null!=Le&&Se&&(u===l.BoundaryReviewActionEnum.SPLIT_HERE||u===l.BoundaryReviewActionEnum.MERGE_NEXT||u===l.BoundaryReviewActionEnum.MERGE_PREV||u===l.BoundaryReviewActionEnum.MERGE_PREVIOUS),s=d?ae.findIndex(function(n){return c.getSegmentReviewKey(n)===c.getSegmentReviewKey(e.segment)}):-1,d&&s>=0&&u&&(rt.current={action:u,originalSegmentIndex:s,segmentSignature:JSON.stringify(ae.map(function(e,n){var t;return{key:c.getSegmentReviewKey(e,n),startPage:e.start_page,endPage:e.end_page,version:null!==(t=e.version)&&void 0!==t?t:null}})),ready:!1}),Hn(e.id),t.label=1;case 1:return t.trys.push([1,8,9,10]),"boundary"!==e.kind?[3,3]:[4,null==Le?void 0:Le(n,i,r)];case 2:return t.sent(),[3,7];case 3:return"label"!==e.kind?[3,5]:[4,null==Fe?void 0:Fe(n,i,r)];case 4:return t.sent(),[3,7];case 5:return"page"!==e.kind?[3,7]:[4,null==Te?void 0:Te(n,i,r)];case 6:t.sent(),t.label=7;case 7:return On(function(n){var t=new Set(n);return t.add(e.id),t}),g="boundary"===e.kind&&(u===l.BoundaryReviewActionEnum.MERGE_NEXT||u===l.BoundaryReviewActionEnum.MERGE_PREV||u===l.BoundaryReviewActionEnum.MERGE_PREVIOUS),("boundary"===e.kind&&u===l.BoundaryReviewActionEnum.SPLIT_HERE||g)&&u&&(v=c.getSegmentReviewKey(e.segment),pn(function(e){var n=new Set(e);return o===l.BoundaryReviewActionEnum.SET_RANGE?n.add(v):n.delete(v),n}),cn(function(e){var n=new Map(e);return n.set(v,u),n})),rt.current?(rt.current.ready=!0,g&&(m=bn.find(function(n){return"label"===n.kind&&c.getSegmentReviewKey(n.segment)===c.getSegmentReviewKey(e.segment)}))&&requestAnimationFrame(function(){return Xt(m)})):$t(e.id),[3,10];case 8:return p=t.sent(),d&&(rt.current=null),null==Ge||Ge(p,r),[3,10];case 9:return Hn(null),[7];case 10:return[2]}})})},[Se,De,Ge,Le,Fe,Te,qe,bn,ae,Xt,$t]);r.useEffect(function(){var e=rt.current;if(null==e?void 0:e.ready){var n=JSON.stringify(ae.map(function(e,n){var t;return{key:c.getSegmentReviewKey(e,n),startPage:e.start_page,endPage:e.end_page,version:null!==(t=e.version)&&void 0!==t?t:null}}));if(n!==e.segmentSignature){var t=e.action===l.BoundaryReviewActionEnum.SPLIT_HERE?e.originalSegmentIndex+1:e.action===l.BoundaryReviewActionEnum.MERGE_PREV||e.action===l.BoundaryReviewActionEnum.MERGE_PREVIOUS?Math.max(0,e.originalSegmentIndex-1):e.originalSegmentIndex,i=new Map(ae.map(function(e,n){return[c.getSegmentReviewKey(e,n),n]})),r=bn.find(function(e){var n=i.get(c.getSegmentReviewKey(e.segment));return null!=n&&n>=t&&Qt(e)});if(!r)return rt.current=null,void Yt();requestAnimationFrame(function(){rt.current=null,Xt(r)})}}},[Yt,Qt,bn,ae,Xt]),r.useEffect(function(){rt.current||Pn&&!bn.some(function(e){return e.id===Pn})&&Yt()},[Pn,Yt,bn]),r.useEffect(function(){if(ye&&!rt.current){var e=bn.find(function(e){return e.pageNumber===Rn});e&&e.id!==Pn&&Xt(e)}},[Pn,ye,Rn,Xt,bn]),r.useEffect(function(){rt.current||Pn&&!bn.some(function(e){var n;return e.id===Pn&&!0!==(null===(n=e.segment.confidence)||void 0===n?void 0:n.awaiting_llm)})&&Yt()},[Pn,Yt,bn]);var ni=r.useMemo(function(){var e=bn.filter(function(e){var n;return!0!==(null===(n=e.segment.confidence)||void 0===n?void 0:n.awaiting_llm)});if("all"===fe)return e;var n=["low","medium","high"].filter(function(e){return e!==me}),i=t.__spreadArray([me],n,!0),r=new Map(i.map(function(e,n){return[e,n]}));return e.map(function(e,n){return{item:e,index:n}}).sort(function(e,n){var t,o,a,l,u=null===(t=e.item.review_step.confidence)||void 0===t?void 0:t.trim().toLowerCase(),d=null===(o=n.item.review_step.confidence)||void 0===o?void 0:o.trim().toLowerCase();return(null==u?i.length:null!==(a=r.get(u))&&void 0!==a?a:i.length)-(null==d?i.length:null!==(l=r.get(d))&&void 0!==l?l:i.length)||e.index-n.index}).map(function(e){return e.item})},[fe,me,bn]),ti=ni.findIndex(function(e){return e.id===Mn}),ii=r.useState(null),ri=ii[0],oi=ii[1],ai=r.useRef(!1),li=r.useCallback(function(e){var n=ni[e];n&&Xt(n)},[ni,Xt]);r.useCallback(function(e){if(!(!Zn||e<0||e>=Zn.pages.length)){var n=Zn.pages[e];null!=n&&(Yt(),Xn(function(n){return null==n?n:t.__assign(t.__assign({},n),{index:e})}),tt.current+=1,Wn({pageNumber:n,requestId:tt.current}))}},[Zn,Yt]),r.useEffect(function(){Mn&&!ni.some(function(e){return e.id===Mn})&&In(null)},[ni,Mn]),r.useEffect(function(){ai.current=!1,oi(ti>=0?String(ti+1):null)},[ti,ni.length]),r.useEffect(function(){if(ai.current&&null!=ri){var e=window.setTimeout(function(){var e=Number(ri.trim()),n=e-1;Number.isInteger(e)&&n>=0&&n<ni.length&&(ai.current=!1,li(n))},300);return function(){return window.clearTimeout(e)}}},[li,ri,ni.length]);var ui=r.useMemo(function(){var e=new Map;bn.forEach(function(n){var t,i=null!==(t=e.get(c.getSegmentReviewKey(n.segment)))&&void 0!==t?t:[];i.push(n),e.set(c.getSegmentReviewKey(n.segment),i)});var n=new Map;return e.forEach(function(e,t){var i,r=null!==(i=fn.get(t))&&void 0!==i?i:1;e.sort(function(e,n){return e.reviewStepIndex-n.reviewStepIndex}).forEach(function(e,t){n.set(e.id,"".concat(r).concat(function(e){for(var n=e+1,t="";n>0;)n-=1,t=String.fromCharCode(65+n%26)+t,n=Math.floor(n/26);return t}(t)))})}),n},[bn,fn]),di=r.useMemo(function(){var e=new Map;bn.forEach(function(n){var t,i=null!==(t=e.get(n.pageNumber))&&void 0!==t?t:[];i.push(n),e.set(n.pageNumber,i)});var n=new Map;return e.forEach(function(e){e.forEach(function(e,t){return n.set(e.id,t)})}),n},[bn]),si=r.useCallback(function(e){return{startPage:Math.max(0,e.startPage-Ee),endPage:Math.min(e.numPages-1,e.endPage+Ee)}},[Ee]),gi=r.useCallback(function(){var e,n=lt.current,t=ut.current;if(n&&t){var i=n.getBoundingClientRect(),r=t.querySelector(".rpv-core__inner-pages"),o=null!==(e=null==r?void 0:r.getBoundingClientRect())&&void 0!==e?e:t.getBoundingClientRect();bn.forEach(function(e){var n,r=ot.current.get(e.id);if(r){var a=t.querySelector('[data-testid="core__page-layer-'.concat(e.pageNumber-1,'"]'));if(a){var l=a.getBoundingClientRect(),u=null!==(n=di.get(e.id))&&void 0!==n?n:0,d=l.top+Pe+40*u,s=d+(r.offsetHeight||32),g=d>=o.top&&s<=o.bottom;r.style.top="".concat(d-i.top,"px"),r.style.visibility=g?"visible":"hidden"}else r.style.visibility="hidden"}});var a=at.current;if(a){var l=null==Zn?void 0:Zn.pages[Zn.index],u=null==l?null:t.querySelector('[data-testid="core__page-layer-'.concat(l-1,'"]'));if(Zn&&u){var d=u.getBoundingClientRect().top+Pe,s=d+(a.offsetHeight||25),g=d>=o.top&&s<=o.bottom;a.style.top="".concat(d-i.top,"px"),a.style.visibility=g?"visible":"hidden"}else a.style.visibility="hidden"}if(Pn&&null==it.current){var c=ot.current.get(Pn);c&&"hidden"!==c.style.visibility&&Tn(function(e){return e===c?e:c})}}},[Zn,Pn,Pe,di,bn]),ci=r.useCallback(function(e){var n=it.current;n&&n.requestId===e.requestId&&n.pageNumber===e.pageNumber&&(it.current=null,gi(),requestAnimationFrame(function(){if(null==it.current){var e=ot.current.get(n.reviewId);e&&"hidden"!==e.style.visibility&&Tn(e)}}))},[gi]);return r.useEffect(function(){var e=ut.current;if(e&&ce){var n=null,t=function(){null==n&&(n=requestAnimationFrame(function(){n=null,gi()}))};e.addEventListener("scroll",t,!0),window.addEventListener("resize",t);var i=new MutationObserver(t);i.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["style"]});var r="undefined"==typeof ResizeObserver?null:new ResizeObserver(t);return null==r||r.observe(e),t(),function(){null!=n&&cancelAnimationFrame(n),e.removeEventListener("scroll",t,!0),window.removeEventListener("resize",t),i.disconnect(),null==r||r.disconnect()}}},[ce,gi]),i.jsxs("div",t.__assign({ref:lt,className:$e,style:t.__assign(t.__assign({},en),{display:"block",position:"relative",width:"100%",height:"100%",minWidth:0,overflowX:"auto",overflowY:"hidden"})},{children:[i.jsxs("div",t.__assign({className:"segment-review-wrapper__container",style:{display:"flex",alignItems:"stretch",gap:0,width:"100%",minWidth:700,height:"100%"}},{children:[i.jsx("div",t.__assign({ref:ut,style:t.__assign(t.__assign({},nn),{flex:"1 1 auto",width:ce?"auto":"100%",minWidth:0,height:"100%",boxSizing:"border-box"})},{children:i.jsx(a.default,t.__assign({highlightText:[],highlightPages:{},highlightCordinatePages:[],useCoordinates:!1,showRotateButton:!0},de,{defaultScale:void 0===se?null!==(Q=null==de?void 0:de.defaultScale)&&void 0!==Q?Q:o.SpecialZoomLevel.PageFit:S[se],disablePdfAnnotations:He,disablePdfTextLayer:Ze,pdfUrl:re,pdfName:oe,segments:Sn,navigationRequest:Kn,onNavigationSettled:ci,setRenderRange:si,onCurrentPageChange:function(e){En(e),null==it.current&&pt&&pt.pageNumber!==e&&Yt(),null==ze||ze(e)}}))})),ce&&i.jsxs("aside",t.__assign({"aria-label":"Page review badges",ref:yn,style:t.__assign(t.__assign({},tn),{position:"relative",width:vt,maxWidth:b,flex:"0 1 ".concat(vt),minHeight:0,overflow:"hidden",boxSizing:"border-box"})},{children:[Zn&&i.jsx("span",t.__assign({ref:at,style:{position:"absolute",top:0,left:10,visibility:"hidden",zIndex:2,display:"inline-flex",alignItems:"center",justifyContent:"center",gap:4,minHeight:25,padding:"2px 8px",border:"1px solid #E2E8F0",borderRadius:16,backgroundColor:"#F8FAFC",boxSizing:"border-box",boxShadow:"0 1px 2px rgba(16, 24, 40, 0.08)",font:"inherit"}},{children:i.jsxs(m.Typography,t.__assign({fontFamily:"Inter",sx:{fontSize:11,fontWeight:500,color:"#475569",whiteSpace:"nowrap"}},{children:[Zn.label||"Pages"," Pg: ",Zn.index+1]}))})),_e&&ni.length>0&&!Zn&&i.jsxs("nav",t.__assign({"aria-label":"Review badge navigation",style:{position:"absolute",top:8,right:Ae||"auto",left:Ie||"auto",zIndex:2,display:"flex",alignItems:"center",gap:7,width:128,minHeight:40,padding:"4px 6px",border:"1px solid #CBD5E1",borderRadius:6,backgroundColor:"#FFFFFF",boxSizing:"border-box",boxShadow:"0 1px 2px rgba(16, 24, 40, 0.06)",font:"inherit"}},{children:[i.jsx("input",{type:"text",inputMode:"numeric",pattern:"[0-9]*",value:null!=ri?ri:"-","aria-label":"Review badge number",onChange:function(e){ai.current=!0,oi(e.target.value)},style:{width:30,height:28,padding:0,border:"1px solid #A5B4FC",borderRadius:3,color:"#4F46E5",backgroundColor:"#FFFFFF",textAlign:"center",font:"inherit",fontSize:15,outline:"none"}}),i.jsxs("span",t.__assign({"aria-label":"".concat(ni.length," reviews"),style:{flex:1,color:"#4F46E5",fontSize:14,whiteSpace:"nowrap",textAlign:"center"}},{children:["of ",ni.length]})),["previous","next"].map(function(e){var n="previous"===e,r=ti+(n?-1:1),o=r<0||r>=ni.length;return i.jsx("button",t.__assign({type:"button","aria-label":"".concat(n?"Previous":"Next"," review badge"),disabled:o,onClick:function(){return li(r)},style:{display:"grid",placeItems:"center",width:17,height:28,padding:0,border:0,background:"transparent",color:o?"#C7D2FE":"#4F46E5",cursor:o?"default":"pointer"}},{children:i.jsx("svg",t.__assign({width:"12",height:"8",viewBox:"0 0 12 8",fill:"none"},{children:i.jsx("path",{d:n?"M1 7L6 2L11 7":"M1 1L6 6L11 1",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round",strokeLinejoin:"round"})}))}),e)})]})),!Zn&&bn.map(function(e){var n,r,o=Pn===e.id,a=null!==(n=ui.get(e.id))&&void 0!==n?n:"1A",l=e.review_step.score,u=e.review_step.confidence,d=h.formatScore(l,u),s="boundary"===e.kind?h.getBoundaryReviewActionBadgeLabel(e.review_step,e.segment,gn.get(c.getSegmentReviewKey(e.segment))):"label"===e.kind?h.getTitleReviewActionBadgeLabel(e.review_step,e.segment,gn.get(c.getSegmentReviewKey(e.segment))):null,g=null!=s?s:"N/A"===d?d:"".concat(d,"%"),p=!0===(null===(r=e.segment.confidence)||void 0===r?void 0:r.awaiting_llm),f=h.getConfidenceColors(l,u,p),w=mt.has(e.id),_=p;return i.jsx(m.Tooltip,t.__assign({title:p?"data is being processed":"",arrow:!0},{children:i.jsx("span",t.__assign({ref:function(n){n?ot.current.set(e.id,n):ot.current.delete(e.id)},style:{position:"absolute",top:0,left:10,visibility:"hidden",display:"inline-flex",cursor:_?"not-allowed":"pointer"}},{children:i.jsx("button",t.__assign({disabled:_,type:"button","aria-pressed":o,"aria-label":p?"".concat(e.review_step.type," · Page ").concat(e.pageNumber," · Data is being processed"):"".concat(e.review_step.type," · Page ").concat(e.pageNumber),onClick:function(){return Xt(e)},style:{cursor:"inherit",display:"flex",alignItems:"center",justifyContent:"space-around",gap:4,width:s?w&&!p?115:90:w&&!p?105:80,minHeight:25,padding:"2px 5px",border:"1px solid ".concat(w&&!p?"#E2E8F0":f.border),borderRadius:16,backgroundColor:w&&!p?"#F8FAFC":f.background,color:w&&!p?"#475569":f.text,font:"inherit",alignContent:"center",boxShadow:"0 1px 2px rgba(16, 24, 40, 0.08)"}},{children:w&&!p?i.jsxs(m.Typography,t.__assign({fontFamily:"Inter",sx:{display:"flex",gap:1,alignItems:"center",flexDirection:"row"}},{children:[i.jsx("span",t.__assign({style:{fontSize:11,fontWeight:500}},{children:a})),i.jsxs("span",t.__assign({style:{display:"flex",alignItems:"center"}},{children:[i.jsx("svg",t.__assign({width:"2",height:"14",viewBox:"0 0 1 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:i.jsx("path",{d:"M0.399902 0V14",stroke:"#CBD5E1",strokeWidth:"0.8"})})),i.jsx("span",t.__assign({style:{fontSize:11,fontWeight:500,marginLeft:"7px",display:"flex",alignItems:"center"}},{children:g}))]})),i.jsxs("span",t.__assign({style:{fontSize:11,fontWeight:500,display:"flex",alignItems:"center"}},{children:[i.jsx("svg",t.__assign({width:"2",height:"14",viewBox:"0 0 1 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:i.jsx("path",{d:"M0.399902 0V14",stroke:"#CBD5E1",strokeWidth:"0.8"})})),i.jsx("span",t.__assign({style:{display:"flex",marginLeft:"7px",alignItems:"center"}},{children:i.jsx(v.CircleCheck,{height:14,width:14,strokeWidth:2,color:"#16A34A"})}))]}))]})):i.jsxs(m.Typography,t.__assign({fontFamily:"Inter",sx:{display:"flex",gap:1,alignItems:"center",flexDirection:"row"}},{children:[i.jsx("span",t.__assign({style:{fontSize:11,fontWeight:500}},{children:a})),i.jsxs("span",t.__assign({style:{display:"flex",alignItems:"center"}},{children:[i.jsx("svg",t.__assign({width:"2",height:"14",viewBox:"0 0 1 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:i.jsx("path",{d:"M0.399902 0V14",stroke:f.divider,strokeWidth:"0.8"})})),i.jsx("span",t.__assign({style:{fontSize:11,fontWeight:500,marginLeft:"7px",display:"flex",alignItems:"center"}},{children:g}))]}))]}))}))}))}),e.id)})]}))]})),pt&&Fn&&i.jsxs(u.default,t.__assign({anchorElement:Fn,placement:"bottom-start",offset:{top:8},width:Math.min(st,b),maxWidth:b,heightBuffer:null!=Ne?Ne:25},{children:[Bn&&i.jsx(d.default,{width:"100%",maxWidth:"100%",score:pt.review_step.score,reasons:xt,reason:pt.review_step.reason,gap:pt.review_step.gap,onBack:function(){return Nn(!1)},onClose:Yt}),i.jsx("div",t.__assign({style:{display:Bn?"none":"block"}},{children:mt.has(pt.id)?i.jsx(p.default,{width:"100%",maxWidth:"100%",headerName:"page"===pt.kind?"Page format approved":"Split"===Et?"Split approved":"Merged"===Et?"Merge approved":"User approved",headerIcon:"page"===pt.kind?i.jsx(v.Check,{size:18,strokeWidth:2}):"Merged"===Et?i.jsx(v.GitMerge,{size:18,strokeWidth:2}):"Split"===Et?i.jsx(y.default,{width:18,height:18}):i.jsx(v.CircleCheck,{size:18,strokeWidth:2}),title:It,pageNo:"Page ".concat(pt.segment.start_page,"-").concat(pt.segment.end_page),summary:Vt?i.jsx(w.default,{icon:i.jsx(v.CircleCheck,{size:14,strokeWidth:2}),title:It,pageRange:"Page ".concat(pt.segment.start_page,"-").concat(pt.segment.end_page),description:null!=Dt?Dt:null,revertData:Vt,confirmDisabled:"page"===pt.kind?!Ut:null==Ke||!Ut,showDocumentHeader:!1,onRevert:function(){if("page"===pt.kind){if(!qe||!Ht){var e=new Error("SegmentReviewPdfWrapper requires onPageTypeRevert and a classification id to revert a page-type decision.");return null==Ge||Ge(e,x(pt)),Promise.reject(e)}return qe({classification_id:Ht,human_verdict:"No"},x(pt))}if(!Ke)throw new Error("SegmentReviewPdfWrapper requires onRevert to handle a revert confirmation.");if(!zt)throw new Error("There is no valid revert operation for this review.");var n=Wt?"boundary":"label"===pt.kind?"label":"boundary"===pt.kind?"boundary":null,t=Nt(zt.type);if(n&&t!==n)throw new Error("Cannot use ".concat(null!=t?t:"unknown"," revert metadata for this review. Expected ").concat(n,"."));return Ke(zt,x(pt))},onRevertError:function(e){null==Ge||Ge(e,x(pt))},onRevertComplete:function(e){var n,t,i,r,o,a;On(function(){return new Set}),"page"!==pt.kind&&(pn(function(){return new Set}),cn(function(){return new Map})),pt.id;var l=null!==(n=Vt.previousSegments[0])&&void 0!==n?n:Vt.currentSegment,u=null==Fn?void 0:Fn.getBoundingClientRect(),d=null===(t=ut.current)||void 0===t?void 0:t.getBoundingClientRect(),s=Math.min(b,Math.max(220,st)),g=null!==(i=null==u?void 0:u.left)&&void 0!==i?i:(null!==(r=null==d?void 0:d.right)&&void 0!==r?r:window.innerWidth-s-8)+8,c=Math.max(8,Math.min(g,window.innerWidth-s-8)),v=null==(null==u?void 0:u.bottom)?Math.max(8,null!==(o=null==d?void 0:d.top)&&void 0!==o?o:8):u.bottom+8;On(function(){return new Set}),"page"!==pt.kind&&(rt.current=null),nt(!1),Qn({title:"Split"===Et?"Split reverted":"Merged"===Et?"Merge reverted":"Approval reverted",description:(null===(a=null==e?void 0:e.message)||void 0===a?void 0:a.trim())||("Split"===Et?"Pages ".concat(pt.segment.start_page,"-").concat(pt.segment.end_page," are now part of “Advice of Award” again. Review the boundary and title to confirm the document."):"Merged"===Et?"The documents have been separated again. Review their boundaries and titles to confirm them.":"“".concat(It,"” is pending review again. Review the boundary and title to confirm the document.")),segment:l,position:{top:v,left:c,width:s}}),Yt()}},pt.id):void 0,additionalActions:Mt?i.jsx(f.default,{metadata:Mt.metadata,reviewAction:null!==($=pt.segment.review_action)&&void 0!==$?$:void 0,startPage:pt.segment.start_page,endPage:pt.segment.end_page,title:It,previousSegmentTitle:yt,nextSegmentTitle:bt,disabled:De||!Le||Vn===pt.id,onConfirm:function(e,n){ei(Mt,e,n)}}):void 0,cognitiveScore:pt.review_step.score,styles:{root:{borderColor:"#16A34A"},header:{"& > .MuiSvgIcon-root, & .MuiTypography-root":{color:"#16A34A"}}},onCognitiveClick:Rt?function(){Nn(!0),null==Qe||Qe(x(pt))}:void 0,onClose:Yt}):"boundary"===pt.kind?i.jsx(l.default,{width:"100%",maxWidth:"100%",totalPages:le,title:pt.segment.label||pt.segment.title,pageNo:"Page ".concat(pt.pageNumber),content:null!==(ee=pt.review_step.question)&&void 0!==ee?ee:null,revertSummary:Ot,cognitiveScore:pt.review_step.score,metadata:pt.metadata,reviewAction:null!==(ne=pt.segment.review_action)&&void 0!==ne?ne:void 0,previousSegmentTitle:yt,nextSegmentTitle:bt,manualPrompt:null!=Be?Be:"Set a custom boundary",defaultStartPage:pt.segment.start_page,defaultEndPage:pt.segment.end_page,styles:{root:{borderColor:St.cardBorder},header:{"& > .MuiSvgIcon-root, & .MuiTypography-root":{color:St.text}}},confirmDisabled:De||!Le||Vn===pt.id,onConfirm:function(e,n,t){t&&l.isBoundaryReviewAction(n.id)&&ei(pt,n.id,t)},onAdjustManually:function(){return null==Je?void 0:Je(x(pt))},onCognitiveClick:Rt?function(){Nn(!0),null==Qe||Qe(x(pt))}:void 0,onClose:Yt},pt.id):"label"===pt.kind?i.jsx(s.default,{width:"100%",maxWidth:"100%",title:pt.metadata.current_label||pt.segment.label||pt.segment.title,pageNo:"Pages ".concat(pt.segment.start_page,"-").concat(pt.segment.end_page),content:null!==(te=pt.review_step.question)&&void 0!==te?te:null,revertSummary:Ot,cognitiveScore:pt.review_step.score,metadata:pt.metadata,styles:{root:{borderColor:St.cardBorder},header:{"& > .MuiSvgIcon-root, & .MuiTypography-root":{color:St.text}}},confirmDisabled:De||!Fe||Vn===pt.id,confirmationBlocked:ft,confirmationWarning:ft?"Please confirm the boundary before confirming the title.":void 0,onActionConfirm:function(e,n){ei(pt,e,n)},onAdjustManually:function(){return null==Je?void 0:Je(x(pt))},onCognitiveClick:Rt?function(){Nn(!0),null==Qe||Qe(x(pt))}:void 0,onClose:Yt},pt.id):i.jsx(g.default,{width:"100%",maxWidth:"100%",title:pt.segment.label||pt.segment.title,pageNo:"Page ".concat(pt.pageNumber),content:pt.review_step.reason,cognitiveScore:pt.review_step.score,pageType:pt.metadata.page_type,metadata:pt.metadata,styles:{root:{borderColor:St.cardBorder},header:{"& > .MuiSvgIcon-root, & .MuiTypography-root":{color:St.text}}},confirmDisabled:De||!Te||Vn===pt.id,onActionConfirm:function(e,n){ei(pt,e,n)},onCognitiveClick:Rt?function(){Nn(!0),null==Qe||Qe(x(pt))}:void 0,onClose:Yt},pt.id)}))]})),Jn&&i.jsx(m.Portal,{children:i.jsx(m.Box,t.__assign({"aria-live":"polite",sx:{position:"fixed",top:Jn.position.top,left:Jn.position.left,zIndex:1600,width:Jn.position.width,maxWidth:"calc(100vw - 16px)",opacity:et?1:0,transform:et?"translateY(0)":"translateY(-6px)",transition:"opacity 500ms ease, transform 500ms ease",filter:"drop-shadow(0 12px 24px rgba(15, 23, 42, 0.18))",pointerEvents:et?"auto":"none"}},{children:i.jsx(_.default,{title:Jn.title,description:Jn.description,onReview:function(){return Jt(Jn.segment)}})}))})]}))};
2
- //# sourceMappingURL=SegmentReviewPdfWrapper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"SegmentReviewPdfWrapper.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),r=require("./reviewStepAdapters.js"),n=function(e){if(null==e)return null;if("number"==typeof e)return Number.isFinite(e)?e:null;var r=e.trim();if(!r)return null;var n=Number.parseFloat(r);return Number.isFinite(n)?n:null},t=function(e){switch(null==e?void 0:e.trim().toLowerCase()){case"low":return 40;case"medium":return 70;case"high":return 95;default:return null}},i=function(e,r){var i;return null!==(i=n(e))&&void 0!==i?i:t(r)},u=function(e){var r=n(e);return null==r?null:r<=40?"low":r<=70?"medium":"high"},o=function(e){switch(null==e?void 0:e.trim().toUpperCase()){case"SPLIT":case"SPLIT_HERE":return"Split";case"MERGE":case"MERGE_NEXT":case"MERGE_PREV":case"MERGE_PREVIOUS":return"Merged";default:return null}},l=function(e){var r,n,t,i;if(![e.human_action_enum,null===(r=e.human_resolution)||void 0===r?void 0:r.action,null===(n=e.review)||void 0===n?void 0:n.action].some(function(e){return"SET_RANGE"===(null==e?void 0:e.trim().toUpperCase())}))return null;var u=null===(t=e.human_resolution)||void 0===t?void 0:t.before,o=null===(i=e.human_resolution)||void 0===i?void 0:i.after;if(null==(null==u?void 0:u.start_page)||null==u.end_page||null==(null==o?void 0:o.start_page)||null==o.end_page)return null;var l=o.start_page<u.start_page||o.end_page>u.end_page,a=o.start_page>u.start_page||o.end_page<u.end_page;if(l&&!a)return"Merged";if(a&&!l)return"Split";var d=u.end_page-u.start_page+1,v=o.end_page-o.start_page+1;return v>d?"Merged":v<d?"Split":null},a=function(e){switch(null==e?void 0:e.trim().toUpperCase()){case"SPLIT":case"SPLIT_HERE":return"SPLIT_HERE";case"MERGE_NEXT":return"MERGE_NEXT";case"MERGE_PREV":case"MERGE_PREVIOUS":return"MERGE_PREV";case"SET_RANGE":return"SET_RANGE";default:return null}},d=function(e){var r,n=null===(r=e.type)||void 0===r?void 0:r.trim().toLowerCase();return"page_boundary"===n||"page boundary review"===n},v=function(r){var n,t,i,u=(null!==(n=r.review_steps)&&void 0!==n?n:[]).filter(d);return null!==(i=null!==(t=e.__spreadArray([],u,!0).reverse().find(function(e){return null!=o(e.human_action_enum)}))&&void 0!==t?t:e.__spreadArray([],u,!0).reverse().find(c))&&void 0!==i?i:u[u.length-1]},s=function(e){var r,n,t,i,u;return null!==(i=null!==(n=null!==(r=l(e))&&void 0!==r?r:o(e.human_action_enum))&&void 0!==n?n:o(null===(t=e.human_resolution)||void 0===t?void 0:t.action))&&void 0!==i?i:o(null===(u=e.review)||void 0===u?void 0:u.action)},_=function(e,r){var n,t=e.type.trim().toLowerCase();if(!("label"===t||"label review"===t))return!0;var i=null===(n=e.human_resolution)||void 0===n?void 0:n.segment_version,u=r.version;return null==i||null==u||i===u},c=function(e){var r,n,t,i;return null!=o(e.human_action_enum)||null!=o(null===(r=e.human_resolution)||void 0===r?void 0:r.action)||null!=o(null===(n=e.review)||void 0===n?void 0:n.action)||!0===(null===(i=null===(t=e.metadata)||void 0===t?void 0:t.performed_actions)||void 0===i?void 0:i.some(function(e){return null!=o(e.action)}))},p=function(r){var n,t,i,u,d,s,_=v(r);if(!_)return null;var c=a(null===(n=_.human_resolution)||void 0===n?void 0:n.action),p=null===(t=_.human_resolution)||void 0===t?void 0:t.after,g=(null==p?void 0:p.start_page)===r.start_page&&(null==p?void 0:p.end_page)===r.end_page,f=l(_);if(f)return g?f:null;if("SPLIT_HERE"===c)return g?null:"Split";if("MERGE_NEXT"===c||"MERGE_PREV"===c)return g?"Merged":null;var m=function(e,r){var n,t,i,u=e.revert,o=r.revert,l="boundary"===(null===(n=null==u?void 0:u.type)||void 0===n?void 0:n.trim().toLowerCase())?u:"boundary"===(null===(t=null==o?void 0:o.type)||void 0===t?void 0:t.trim().toLowerCase())?o:null;if(!l)return null;var a=null===(i=l.decision)||void 0===i?void 0:i.trim().toUpperCase();if(null==a?void 0:a.includes("SPLIT"))return"Split";if(null==a?void 0:a.includes("MERGE"))return"Merged";if("SET_RANGE"===a){if(l.current_segment_ids.length>l.previous_state.length)return"Split";if(l.current_segment_ids.length<l.previous_state.length)return"Merged"}return null}(_,r);if(m)return m;var E=o(_.human_action_enum);if(E)return E;var R=o(null===(i=_.review)||void 0===i?void 0:i.action);if(R)return R;var h=e.__spreadArray([],null!==(u=r.human_action_log)&&void 0!==u?u:[],!0).filter(function(e){return null!=o(e.action)}).sort(function(e,r){var n,t;return r.human_revision-e.human_revision||(null===(n=r.performed_at)||void 0===n?void 0:n.localeCompare(null!==(t=e.performed_at)&&void 0!==t?t:""))})[0];if(!h)return null;var S=o(h.action),w=(null===(d=h.after)||void 0===d?void 0:d.start_page)===r.start_page&&(null===(s=h.after)||void 0===s?void 0:s.end_page)===r.end_page;return"Split"===S?w?null:S:w?S:null},g=function(e,r){return null!=o(r)||null!=p(e)},f=function(e,r){var n,t,i,u,l,d,s=a(r),_=v(e),c=null!==(i=null!==(n=a(null==_?void 0:_.human_action_enum))&&void 0!==n?n:a(null===(t=null==_?void 0:_.human_resolution)||void 0===t?void 0:t.action))&&void 0!==i?i:a(null===(u=null==_?void 0:_.review)||void 0===u?void 0:u.action),g=o(r),f=null===(l=null==_?void 0:_.human_resolution)||void 0===l?void 0:l.after,m="SPLIT_HERE"===s&&null!=(null===(d=null==_?void 0:_.human_resolution)||void 0===d?void 0:d.action)&&(null==f?void 0:f.start_page)===e.start_page&&(null==f?void 0:f.end_page)===e.end_page;return null!=s&&c===s&&null!=g&&(m||p(e)===g)};exports.formatScore=function(e,r){var n=i(e,r);return null==n?"N/A":Number.isInteger(n)?String(n):n.toFixed(2).replace(/\.?0+$/,"")},exports.getBoundaryReviewActionBadgeLabel=function(e,r,n){var t,i;return null!==(i=null!==(t=o(n))&&void 0!==t?t:s(e))&&void 0!==i?i:p(r)},exports.getConfidenceColors=function(e,r,n){var t={border:"#E5E7EB",cardBorder:"#374151",background:"#F9FAFB",text:"#374151",divider:"#D1D5DB"};if(n)return t;switch(u(e)){case"low":return{border:"#FECACA",cardBorder:"#B91C1C",background:"#FEF2F2",text:"#B91C1C",divider:"#FCA5A5"};case"medium":return{border:"#d9cda2",cardBorder:"#997800",background:"#fff1bf",text:"#997800",divider:"#e6b400"};case"high":return{border:"#16A34A",cardBorder:"#4F9E6C",background:"#F0FDF4",text:"#4F9E6C",divider:"#00A43C"}}return t},exports.getFallbackScore=t,exports.getHumanActionBadgeLabel=o,exports.getNumericScore=n,exports.getOptimisticMergeImpactedSegmentKeys=function(n,t,i){void 0===i&&(i=new Set);var u=e.__spreadArray([],n,!0).sort(function(e,r){return e.start_page-r.start_page||e.end_page-r.end_page}),o=new Set;return t.forEach(function(e,n){if(!i.has(n)){var l=u.findIndex(function(e){return r.getSegmentReviewKey(e)===n});if(!(l<0)){var d=u[l];if(!f(d,e)){var v=a(e),s=u["MERGE_PREV"===v?l-1:"MERGE_NEXT"===v?l+1:-1];if(s){var _=r.getSegmentReviewKey(s);g(s,t.get(_))||o.add(_)}}}}}),o},exports.getPendingMergeImpactedSegmentKeys=function(n){var t=e.__spreadArray([],n,!0).sort(function(e,r){return e.start_page-r.start_page||e.end_page-r.end_page}),i=new Set;return t.forEach(function(e,n){var u,o=(null!==(u=e.review_steps)&&void 0!==u?u:[]).find(function(r){var n,t,i;if(!d(r))return!1;var u=a(r.human_action_enum),o=a(null===(n=r.human_resolution)||void 0===n?void 0:n.action),l=null===(t=r.human_resolution)||void 0===t?void 0:t.before,v=null===(i=r.human_resolution)||void 0===i?void 0:i.after,s=null!=(null==l?void 0:l.start_page)&&null!=l.end_page&&null!=(null==v?void 0:v.start_page)&&null!=v.end_page&&(l.start_page!==v.start_page||l.end_page!==v.end_page),_=(null==v?void 0:v.start_page)===e.start_page&&(null==v?void 0:v.end_page)===e.end_page;return("MERGE_NEXT"===u||"MERGE_PREV"===u)&&!(o===u&&s&&_)});if(o){var l=a(o.human_action_enum),v=t["MERGE_PREV"===l?n-1:n+1];v&&!g(v)&&i.add(r.getSegmentReviewKey(v))}}),i},exports.getResolvedScore=i,exports.getReviewScoreBand=u,exports.getReviewStepActionBadgeLabel=s,exports.getStructuralResultBadgeLabel=p,exports.getTitleReviewActionBadgeLabel=function(e,r,n){var t=o(n);if(t)return t;var i=s(e);return i||p(r)},exports.hasPolledStructuralAction=f,exports.hasStructuralBoundaryAction=c,exports.isReviewStepResolutionCurrent=_,exports.isReviewStepResolved=function(e,r){var n,t,i;if(!_(e,r))return!1;if(null!=(null===(n=e.review)||void 0===n?void 0:n.action))return!0;var u=null===(i=null===(t=e.human_resolution)||void 0===t?void 0:t.state)||void 0===i?void 0:i.trim().toLowerCase();return"resolved_by_human"===u||"approved"===u||"confirmed"===u},exports.shouldHideStructuralBoundaryReview=function(e,r,n,t){var i=o(t);if("Merged"===i)return n;if("Split"===i)return!0;if(function(e,r){var n,t,i;if("affected"!==(null===(n=r.sensitivity)||void 0===n?void 0:n.trim().toLowerCase()))return!1;var u=null!==(t=e.revert)&&void 0!==t?t:r.revert;if(!u)return!1;var o=null===(i=u.decision)||void 0===i?void 0:i.trim().toUpperCase();return u.current_segment_ids.length>u.previous_state.length&&("SET_RANGE"===o||"SPLIT"===o||"SPLIT_HERE"===o)}(e,r))return!0;var u=s(e);if("Split"===u)return!0;var l=p(r);return"Split"===l||"Merged"===u&&("Merged"!==l||n)};
2
- //# sourceMappingURL=helper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"helper.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./BoundaryCard.js"),n=require("./LabelCheck.js"),a=require("./PageCheck.js"),i=function(e){return"object"==typeof e&&null!==e?e:{}},t=function(e){return"string"==typeof e?e:null},o=function(e){return"number"==typeof e&&Number.isFinite(e)?e:null},r=function(e){return Array.isArray(e)?e.filter(function(e){return"string"==typeof e}):[]},l=function(e){var n="string"==typeof e?e.trim().toLowerCase():"";return"table"===n||"drawing"===n?n:null},u=function(e,n){return void 0===n&&(n=0),e.stable_key||e.segment_id||"".concat(e.start_page,"-").concat(e.end_page,"-").concat(n)},c=function(e){var a=i(e);return{current_label:t(a.current_label),custom_label:t(a.custom_label),group_id:t(a.group_id),user_actions:r(a.user_actions).filter(n.isLabelReviewAction)}},s=function(e){var n=i(e);return{page_type:l(n.page_type),page_num:o(n.page_num),classification_id:t(n.classification_id),user_actions:r(n.user_actions).filter(a.isPageCheckAction)}};exports.extractSegmentReviewData=function(n){var t=[],d=[],v=[];return n.forEach(function(n,p){var _,f,g=u(n,p),m=null!==(_=n.review_steps)&&void 0!==_?_:[];m.forEach(function(a,l){var u,p,_=(u=a.type,"page_boundary"===(p=u.trim().toLowerCase())||"page boundary review"===p?"boundary":"label"===p||"label review"===p?"label":"page"===p?"page":null);if("boundary"===_){var f=function(n){var a=i(n);return{focus_page:o(a.focus_page),boundary_margin:o(a.boundary_margin),user_actions:r(a.user_actions).filter(e.isBoundaryReviewAction)}}(a.metadata);t.push({id:"".concat(g,":boundary:").concat(l),reviewStepIndex:l,segment:n,review_step:a,metadata:f})}"label"===_&&d.push({id:"".concat(g,":label:").concat(l),reviewStepIndex:l,segment:n,review_step:a,metadata:c(a.metadata)}),"page"===_&&v.push({id:"".concat(g,":page:").concat(l),reviewStepIndex:l,segment:n,review_step:a,metadata:s(a.metadata)})});var y=0;null===(f=n.page_classifications)||void 0===f||f.forEach(function(e,i){var t,o,r=null!==(t=e.page_num)&&void 0!==t?t:null,u=null!==(o=e.questions)&&void 0!==o?o:[];(u.length>0?u:e.severity?[e]:[]).forEach(function(t,o){var u,c,d,p;if(l(t.page_type)){var _=function(e,n,i,t){var o,r,u,c,s,d,v,p,_,f,g,m,y,b,w,h=l(e.page_type),C=null===(r=null===(o=e.human_action)||void 0===o?void 0:o.verdict)||void 0===r?void 0:r.trim().toUpperCase(),x=C&&a.isPageCheckAction(C)?C:null,S="drawing"===h?"an engineering drawing":h?"a ".concat(h):null;return{type:"page",confirmed:i,title:"Page Type Check",summary:(null==t?void 0:t.trim())||(x&&null!=n&&S?"Page ".concat(n," was confirmed as ").concat("YES"===x?S:"not ".concat(S),"."):void 0),format:"pdf",confidence:null!==(c=null===(u=e.machine_classification)||void 0===u?void 0:u.confidence)&&void 0!==c?c:null,decided_by:null!==(d=null===(s=e.machine_classification)||void 0===s?void 0:s.decisioning_method)&&void 0!==d?d:null,human_action_enum:null,reason:h?"We're not fully confident about the type of this page. Is this page a ".concat(h,"?"):null,reasons:null!==(v=e.reasons)&&void 0!==v?v:[],score:null!==(f=null!==(p=e.score)&&void 0!==p?p:null===(_=e.machine_classification)||void 0===_?void 0:_.score)&&void 0!==f?f:null,review:null==x?null:{action:x,reviewed_by:null!==(m=null===(g=e.human_action)||void 0===g?void 0:g.reviewed_by)&&void 0!==m?m:"",reviewed_at:null!==(b=null===(y=e.human_action)||void 0===y?void 0:y.reviewed_at)&&void 0!==b?b:""},metadata:{page_type:h,page_num:n,classification_id:null!==(w=e.id)&&void 0!==w?w:null,user_actions:["YES","NO"]}}}(t,r,null!==(c=null!==(u=t.confirmed)&&void 0!==u?u:e.confirmed)&&void 0!==c?c:null,null!==(d=e.summary)&&void 0!==d?d:null);v.push({id:"".concat(g,":page-classification:").concat(null!==(p=t.id)&&void 0!==p?p:"".concat(i,"-").concat(o)),reviewStepIndex:m.length+y,segment:n,review_step:_,metadata:s(_.metadata)}),y+=1}})})}),{boundaryReviews:t,labelReviews:d,pageReviews:v}},exports.getSegmentReviewKey=u;
2
- //# sourceMappingURL=reviewStepAdapters.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"reviewStepAdapters.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- import{__assign as t}from"tslib";import{jsxs as o,jsx as i}from"react/jsx-runtime";import{ChevronDown as a,ChevronUp as n,Maximize2 as e,X as l,ExternalLink as r}from"lucide-react";import u from"dayjs";import c from"../ScannedDocCitation/ScannedDocCitation.js";import s from"../InstantLearningCitation/InstantLearningCitationComponent.js";import d from"../InstantLearningCitation/SlashLoader.js";import v from"../CognitiveInternalgptReasoning/CognitiveInternalgptReasoningComponent.js";import m from"../RequirementAiCitations/ImageCitation/ImageCitationContent.js";import g from"../RequirementAiCitations/WebCitation/WebCitationWithImageContent.js";import h from"../ChatCitation/ChatCitationRenderer.js";var _=function(t,o,i){if(!t)throw new Error("[CitationOrchestratorComponent] ".concat(o,': missing required field "').concat(i,'" in customMetaData'))},C=function(t,o){if(!Object.values(t).some(Boolean))throw new Error("[CitationOrchestratorComponent] ".concat(o,': missing one of "').concat(Object.keys(t).join('", "'),'" in customMetaData'))},p=function(p){var D,f,M,b,I,w,S,R,j,k,x,T,y,P,L,U,O,A,F,W,q,z,B,E,G,H,N,$,J,K,Q,V,X,Y,Z,tt,ot,it,at,nt,et,lt,rt=p.href,ut=p.citations,ct=p.children,st=p.isStreaming,dt=p.onCitationToggle,vt=p.chatCitationConfig;if(st)return o("span",t({style:{display:"inline-flex",alignItems:"center",gap:"0.25rem",fontWeight:500,color:"#6D28D9"}},{children:[i("span",{children:ct}),i(d,{})]}));try{var mt=new URL(rt,"http://example.com"),gt=mt.searchParams.get("citationNumber"),ht=mt.searchParams.get("decisionStrength");if(!gt)return null;var _t=(null==ut?void 0:ut.find(function(t){var o;return String(null===(o=null==t?void 0:t.customMetaData)||void 0===o?void 0:o.citation_number)===gt}))||null;if(!_t)return null;var Ct=(null===(D=null==_t?void 0:_t.customMetaData)||void 0===D?void 0:D.citation_type)||((null===(f=_t.customMetaData)||void 0===f?void 0:f.type)||"").replace(/s$/,"");if("scanned_doc_citation"===Ct){var pt=null==_t?void 0:_t.customMetaData.value;if(null==pt?void 0:pt.length)return i(c,{pages:pt,subHeadingText:_t.customMetaData.artifact_title});_(null===(M=null==_t?void 0:_t.customMetaData)||void 0===M?void 0:M.gs_url,"scanned_doc_citation","gs_url");var Dt=[null===(b=null==_t?void 0:_t.customMetaData)||void 0===b?void 0:b.gs_url],ft=(null!==(I=_t.customMetaData.highlighted_coordinates)&&void 0!==I?I:[]).map(function(t,o){return{pageIndex:o,bboxes:[t]}});return i(c,{images:Dt,highlights:ft})}if("IL"===Ct){_(_t.customMetaData.il_learning,"IL","il_learning");var Mt=ct||(null===(w=_t.customMetaData)||void 0===w?void 0:w.link_text)||(null===(S=_t.customMetaData)||void 0===S?void 0:S.citation_source)||String(null!==(R=_t.customMetaData.citation_number)&&void 0!==R?R:1);return i(s,{citation:_t,linkTitle:Mt,onCitationToggle:null!=dt?dt:function(){},decisionStrengthFromUrl:ht||(null===(j=_t.customMetaData)||void 0===j?void 0:j.decision_strength)||""})}if("chat_citation"===Ct){var bt=null!=vt?vt:{},It=null===(T=null!==(x=null===(k=null==_t?void 0:_t.customMetaData)||void 0===k?void 0:k.chat_data)&&void 0!==x?x:[])||void 0===T?void 0:T.map(function(o){return t(t({},o),{timeStamp:u(o.timeStamp)})}),wt=!!(null===(y=null==_t?void 0:_t.customMetaData)||void 0===y?void 0:y.rule_book_content);return i(h,{showRootContainer:null===(P=bt.showRootContainer)||void 0===P||P,reversePanels:bt.reversePanels,isRenderedCustomComponent:bt.isRenderedCustomComponent,modalContainerStyle:bt.modalContainerStyle,additionalData:bt.additionalData,closePreview:bt.closePreview,selectedIdFromReason:null!==(L=bt.selectedIdFromReason)&&void 0!==L?L:void 0,rootContainer:t(t({},bt.rootContainer),{relevanceScore:_t.customMetaData.relevance_score}),chatContainer:t(t({},bt.chatContainer),{chatData:It,summarizedTab:null!==(O=null===(U=bt.chatContainer)||void 0===U?void 0:U.summarizedTab)&&void 0!==O?O:{chip:{isActive:!0,show:!0}},detailedTab:null!==(F=null===(A=bt.chatContainer)||void 0===A?void 0:A.detailedTab)&&void 0!==F?F:{chip:{isActive:!1}}}),ruleBookContainer:wt?t(t({},bt.ruleBookContainer),{data:{content:_t.customMetaData.rule_book_content,highlighted_texts:null!==(W=_t.customMetaData.rule_book_highlights)&&void 0!==W?W:[]}}):void 0})}if("gpt_citation"===Ct){var St=null===(q=_t.customMetaData)||void 0===q?void 0:q.value,Rt=null!==(z=null==St?void 0:St.text)&&void 0!==z?z:null===(E=null===(B=_t.customMetaData)||void 0===B?void 0:B.data_sources)||void 0===E?void 0:E[0],jt=null!==(G=null==St?void 0:St.label)&&void 0!==G?G:null===(N=null===(H=_t.customMetaData)||void 0===H?void 0:H.training_data_title)||void 0===N?void 0:N[0],kt=null!==($=null==St?void 0:St.paraphrase)&&void 0!==$?$:null===(K=null===(J=_t.customMetaData)||void 0===J?void 0:J.paraphrase)||void 0===K?void 0:K[0];return C({data_sources:Rt,training_data_title:jt},"gpt_citation"),i(v,{item:{text:"",dataSource:Rt,trainingDataTitle:jt,paraphrase:kt},headerTitle:"GPT - Gemini 2.5 Flash",iconsConfig:{ChevronDownIcon:a,ChevronUpIcon:n,MaximizeIcon:e,CloseIcon:l}})}if("web_citation"===Ct){!function(t,o,i){_(t,o,i);try{new URL(t)}catch(a){throw new Error("[CitationOrchestratorComponent] ".concat(o,': "').concat(i,'" is not a valid URL: "').concat(t,'"'))}}(null===(Q=_t.customMetaData)||void 0===Q?void 0:Q.link,"web_citation","link");var xt=_t.customMetaData.link,Tt=ct||(null===(V=_t.customMetaData)||void 0===V?void 0:V.citation_source)||xt;return(null===(X=_t.customMetaData)||void 0===X?void 0:X.screenshot_url)?i(g,{url:xt,label:Tt,gsUtilPath:null===(Y=_t.customMetaData)||void 0===Y?void 0:Y.gs_util_path,signedUrl:null===(Z=_t.customMetaData)||void 0===Z?void 0:Z.screenshot_url,relevanceScore:null===(tt=_t.customMetaData)||void 0===tt?void 0:tt.relevance_score,visitIcon:r,PreviewDialogCloseIcon:l}):i("a",t({href:xt,target:"_blank",rel:"noreferrer"},{children:Tt}))}if("image_citation"===Ct)return C({gs_util_path:null===(ot=_t.customMetaData)||void 0===ot?void 0:ot.gs_util_path,signed_url:null===(it=_t.customMetaData)||void 0===it?void 0:it.signed_url},"image_citation"),i(m,{citationTitle:ct||(null===(at=_t.customMetaData)||void 0===at?void 0:at.citation_source),gsUtilPath:null===(nt=_t.customMetaData)||void 0===nt?void 0:nt.gs_util_path,signedUrl:null===(et=_t.customMetaData)||void 0===et?void 0:et.signed_url,relevanceScore:null===(lt=_t.customMetaData)||void 0===lt?void 0:lt.relevance_score})}catch(t){return console.error(t),null}return null};export{p as default};
2
- //# sourceMappingURL=ParentCitationComponent.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ParentCitationComponent.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- import{__assign as e,__spreadArray as i}from"tslib";import{jsx as o,jsxs as t,Fragment as r}from"react/jsx-runtime";import{useMemo as n,useState as a}from"react";import d from"@mui/icons-material/ChevronRight";import l from"@mui/icons-material/Close";import c from"@mui/icons-material/ExpandMore";import s from"@mui/material/Box";import m from"@mui/material/Button";import u from"@mui/material/ButtonBase";import p from"@mui/material/Divider";import h from"@mui/material/IconButton";import f from"@mui/material/Paper";import x from"@mui/material/Radio";import g from"@mui/material/Stack";import b from"@mui/material/Typography";import v from"./CognitiveIcon.js";import y from"./infoAlert.js";var C=function(e,o){return i([e],Array.isArray(o)?o:null==o?[]:[o],!0)},E=function(e){return"KEEP"===e||"SPLIT_HERE"===e||"MERGE_NEXT"===e||"MERGE_PREVIOUS"===e||"SET_RANGE"===e},S=function(e){return e.user_actions.map(function(i){var o=e.focus_page;switch(i){case"KEEP":return{id:i,title:"Keep as is",description:"Keep the current document boundary unchanged."};case"SPLIT_HERE":return{id:i,title:"Create a separate document",description:o?"Start a new document at page ".concat(o,"."):"Create a new document at this boundary."};case"MERGE_NEXT":return{id:i,title:"Merge into next document",description:o?"Move page ".concat(o," onward into the next document."):"Merge this segment into the next document."};case"MERGE_PREVIOUS":return{id:i,title:"Merge into previous document",description:"Merge this segment into the previous document."};case"SET_RANGE":return{id:i,title:"Adjust page range",description:"Set the start and end pages manually."}}})};function w(i){var w=i.headerName,R=void 0===w?"Boundary Check":w,k=i.title,z=i.pageNo,A=i.content,I=i.cognitiveScore,M=i.config,j=i.metadata,B=i.selectedIndex,T=i.defaultSelectedIndex,_=void 0===T?null:T,F=i.onSelectionChange,N=i.onConfirm,P=i.onActionConfirm,W=i.onCognitiveClick,D=i.onAdjustManually,G=i.onClose,H=i.confirmLabel,L=void 0===H?"Confirm":H,K=i.manualPrompt,O=void 0===K?"Didn't find the right option?":K,U=i.manualActionLabel,V=void 0===U?"Adjust Manually":U,X=i.cognitiveLabel,q=void 0===X?"Cognitive Integrity":X,J=i.showAdjustManually,Q=void 0===J||J,Y=i.showCognitiveIntegrity,Z=void 0===Y||Y,$=i.showCloseButton,ee=void 0===$||$,ie=i.confirmDisabled,oe=void 0!==ie&&ie,te=i.width,re=void 0===te?340:te,ne=i.maxWidth,ae=void 0===ne?340:ne,de=i.className,le=i.styles,ce=n(function(){return null!=M?M:j?S(j):[]},[M,j]),se=a(_),me=se[0],ue=se[1],pe=void 0===B?me:B,he=null==pe?void 0:ce[pe],fe=oe||!he||!0===he.disabled||!N&&!P;return o(f,e({className:de,elevation:4,sx:C({width:re,maxWidth:ae,borderTop:"4px solid",borderColor:"error.light",borderRadius:2,bgcolor:"background.paper",overflow:"hidden",boxSizing:"border-box","@media (max-width: 372px)":{width:"calc(100vw - 32px)"}},null==le?void 0:le.root)},{children:t(g,e({spacing:1.5,sx:{p:2}},{children:[t(g,e({direction:"row",alignItems:"center",spacing:1,sx:null==le?void 0:le.header},{children:[o(y,{color:"error"}),o(b,e({sx:{flex:1,color:"error.main",fontSize:16,fontWeight:500,lineHeight:1.25,textTransform:"uppercase"}},{children:R})),ee&&o(h,e({size:"small",onClick:G,disabled:!G,"aria-label":"Close boundary check",sx:{p:.25,"&.Mui-disabled":{color:"text.secondary"}}},{children:o(l,{sx:{fontSize:20}})}))]})),t(s,{children:[o(b,e({sx:{color:"text.primary",fontSize:18,fontWeight:500}},{children:k})),null!=z&&o(b,e({sx:{mt:.25,color:"text.secondary",fontSize:16}},{children:z})),o(p,{sx:{my:1.25}}),null!=A&&o(b,e({component:"div",sx:{color:"text.secondary",fontSize:15,lineHeight:1.45}},{children:A}))]}),t(g,e({spacing:1,role:"radiogroup","aria-label":"Boundary options"},{children:[ce.map(function(i,r){var n=pe===r;return o(f,e({variant:"outlined",sx:C({borderColor:n?"secondary.main":"divider",borderRadius:2,overflow:"hidden"},null==le?void 0:le.option)},{children:t(u,e({role:"radio","aria-checked":n,disabled:i.disabled,onClick:function(){return function(e,i){i.disabled||(void 0===B&&ue(e),null==F||F(e,i))}(r,i)},sx:{width:"100%",justifyContent:"flex-start",px:1.25,py:1.125,textAlign:"left"}},{children:[o(x,{checked:n,disabled:i.disabled,tabIndex:-1,size:"small",sx:{p:.5,mr:1}}),t(s,e({sx:{minWidth:0}},{children:[o(b,e({sx:{color:"text.primary",fontSize:15,fontWeight:500}},{children:i.title})),null!=i.description&&o(b,e({sx:{mt:.25,color:"text.secondary",fontSize:13}},{children:i.description}))]}))]}))}),i.id)}),o(m,e({variant:"contained",fullWidth:!0,disabled:fe,onClick:function(){!fe&&null!=pe&&he&&(null==N||N(pe,he),P&&E(he.id)&&P(he.id,{selectedIndex:pe,option:he,metadata:j}))},sx:C({minHeight:48,mt:.25,borderRadius:2,fontSize:17,fontWeight:600,textTransform:"none",backgroundColor:"#5925DC","&:hover":{backgroundColor:"#4A1FB8"},"&.Mui-disabled":{backgroundColor:"#D9D6FE",color:"#FFFFFF"}},null==le?void 0:le.confirmButton)},{children:L}))]})),t(g,e({spacing:1.25,sx:null==le?void 0:le.footer},{children:[Q&&t(u,e({onClick:D,disabled:!D,sx:{justifyContent:"space-between",borderRadius:1,textAlign:"left"}},{children:[t(s,{children:[o(b,e({sx:{color:"text.primary",fontSize:14}},{children:O})),o(b,e({sx:{mt:.25,color:"text.primary",fontSize:14}},{children:V}))]}),o(c,{sx:{color:"text.secondary"}})]})),Z&&t(r,{children:[o(p,{}),t(u,e({onClick:W,disabled:!0,sx:{justifyContent:"space-between",borderRadius:1,textAlign:"left",cursor:"not-allowed"}},{children:[t(g,e({direction:"row",alignItems:"center",spacing:1},{children:[o(v,{sx:{color:"text.secondary"}}),o(b,e({sx:{color:"text.primary",fontSize:15}},{children:q}))]})),t(g,e({direction:"row",alignItems:"center",spacing:.5},{children:[null!=I&&o(s,e({sx:{px:1,py:.125,border:"1.5px solid",borderColor:"secondary.main",borderRadius:10,color:"secondary.main",fontSize:14,lineHeight:1.25}},{children:I})),o(d,{sx:{color:"text.secondary"}})]}))]}))]})]}))]}))}))}export{S as createBoundaryCardOptions,w as default,E as isBoundaryReviewAction};
2
- //# sourceMappingURL=BoundaryCard.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"BoundaryCard.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- import{__assign as o}from"tslib";import{jsx as t}from"react/jsx-runtime";import{useState as e,useLayoutEffect as r}from"react";import n from"@mui/material/Box";import i from"@mui/material/Popper";function l(l){var a,m,f=l.anchorRef,u=l.anchorElement,p=l.children,c=l.className,s=l.offset,d=void 0===s?{}:s,v=l.placement,x=void 0===v?"bottom-start":v,h=e(null),E=h[0],b=h[1];return r(function(){var o,t=null!==(o=null!=u?u:null==f?void 0:f.current)&&void 0!==o?o:null;b(function(o){return o===t?o:t})}),t(i,o({open:Boolean(E),anchorEl:E,placement:x,className:c,popperOptions:{strategy:"fixed"},modifiers:[{name:"offset",options:{offset:[null!==(a=d.left)&&void 0!==a?a:0,null!==(m=d.top)&&void 0!==m?m:0]}}],sx:{zIndex:function(o){return o.zIndex.tooltip}}},{children:t(n,o({sx:{maxHeight:"calc(85vh - 10px)",overflowY:"auto",pointerEvents:"auto"}},{children:p}))}))}export{l as default};
2
- //# sourceMappingURL=CardWrapper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CardWrapper.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- import{__assign as C}from"tslib";import{jsxs as e,jsx as t}from"react/jsx-runtime";import i from"@mui/material/SvgIcon";function r(r){return e(i,C({},r,{viewBox:"0 0 12 17",sx:C({width:12,height:17},r.sx)},{children:[t("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M0.778549 6.35498C0.947509 6.06234 1.14047 5.78701 1.35448 5.53127L1.05841 6.77432C0.87679 7.48466 0.80378 8.17502 1.05378 8.73356C1.09106 8.81682 1.13466 8.8951 1.18403 8.96801C1.17505 9.11859 1.17346 9.27007 1.17938 9.42164C1.21133 10.2394 1.46064 11.0339 1.90165 11.7232C2.34265 12.4126 2.95942 12.9719 3.68845 13.3437C3.78702 13.3948 3.86973 13.4719 3.92758 13.5667C3.98544 13.6614 4.01623 13.7702 4.01664 13.8814V16.3427C4.01664 16.422 4.00103 16.5004 3.97071 16.5736C3.94039 16.6468 3.89595 16.7133 3.83993 16.7693C3.78391 16.8253 3.71741 16.8698 3.64421 16.9001C3.57102 16.9305 3.49257 16.946 3.41335 16.946C3.33412 16.946 3.25567 16.9305 3.18248 16.9001C3.10928 16.8698 3.04278 16.8253 2.98676 16.7693C2.93074 16.7133 2.8863 16.6468 2.85598 16.5736C2.82567 16.5004 2.81006 16.422 2.81006 16.3427V14.2366C1.50675 13.4505 0.563809 12.1847 0.18393 10.7109C-0.195948 9.23705 0.017555 7.67304 0.778549 6.35498ZM2.5956 4.4202C2.58489 4.46583 2.57238 4.51587 2.55818 4.57051L2.10596 6.46709C2.4519 6.00902 2.88178 5.61795 3.37484 5.31587C3.45372 5.26755 3.53389 5.2217 3.61524 5.17836L3.91437 4.02581C3.94069 3.92848 3.96334 3.83471 3.98223 3.74482C3.4887 3.90843 3.02287 4.13636 2.5956 4.4202ZM4.97997 3.50929C4.95187 3.76277 4.89721 4.01844 4.83146 4.26296L4.70096 4.7659C5.02368 4.68809 5.35523 4.64508 5.68997 4.63852C6.50816 4.62249 7.31584 4.82482 8.02986 5.22467C8.74387 5.62452 9.33837 6.20745 9.75227 6.91343C10.1661 7.61942 10.3843 8.42296 10.3845 9.24135V13.029C10.3845 13.1201 10.3483 13.2075 10.2838 13.272C10.2193 13.3365 10.132 13.3726 10.0408 13.3726H8.14698C7.98698 13.3726 7.83353 13.4362 7.72039 13.5493C7.60726 13.6625 7.5437 13.816 7.5437 13.9759V16.3427C7.5437 16.5028 7.60726 16.6562 7.72039 16.7693C7.83353 16.8825 7.98698 16.946 8.14698 16.946C8.30699 16.946 8.46043 16.8825 8.57357 16.7693C8.6867 16.6562 8.75027 16.5028 8.75027 16.3427V14.5792H10.0408C10.2444 14.5792 10.446 14.5391 10.634 14.4612C10.8221 14.3833 10.993 14.2691 11.137 14.1252C11.2809 13.9812 11.3951 13.8103 11.473 13.6223C11.551 13.4342 11.591 13.2326 11.591 13.029V9.24224C11.5909 8.20964 11.3155 7.1957 10.7933 6.30483C10.271 5.41397 9.5209 4.67834 8.61996 4.17369C7.50563 3.55832 6.22659 3.32916 4.97997 3.50929ZM3.31096 7.17824C3.06416 7.47379 2.86777 7.81154 2.73281 8.17818C2.67346 8.33942 2.62681 8.50407 2.59287 8.67068C2.96541 8.66305 3.3259 8.58961 4.09408 7.98043L4.4813 7.65806C4.62698 7.53143 4.68583 7.33671 4.65268 7.14949L4.63322 7.06982C4.53815 6.83998 4.24287 6.77137 4.02738 6.89566C3.80462 7.02416 3.56339 7.12021 3.31096 7.17824ZM5.50956 6.70762C5.39307 6.42581 5.2101 6.22391 4.9955 6.09139C5.4636 5.96152 5.95753 5.9332 6.44355 6.01261C7.21223 6.13821 7.9139 6.52554 8.4298 7.10905C8.7773 7.50191 8.68077 8.0666 8.32362 8.38802C7.27342 9.33691 5.53306 10.5666 3.80331 11.0251C3.36315 11.141 2.88052 10.9286 2.71933 10.4749C2.62076 10.1971 2.55967 9.90972 2.53604 9.62C2.82204 9.61857 3.17908 9.5971 3.63183 9.39587C4.05727 9.20681 4.51985 8.88082 5.10381 8.3732C5.58794 7.95226 5.70675 7.30946 5.5355 6.77894L5.52437 6.74281L5.50956 6.70762Z"}),t("path",{d:"M2.49253 8.67144C1.98274 8.67144 1.60843 8.35663 1.96545 6.97238L2.55084 4.51665C2.65295 4.12345 2.66944 3.96624 2.55084 3.96624C2.1154 4.07601 2.33401 4.00777 1.9654 4.16485L1.71094 3.73988C2.95167 2.68571 2.97363 2.40709 3.58474 2.40709C4.09454 2.40709 4.17978 3.02062 3.92448 3.96464L3.25466 6.54621C3.13565 7.00253 3.18712 7.15973 3.30531 7.15973C3.56398 7.10114 3.81132 7.00404 4.03939 6.87249C4.25773 6.74655 4.55616 6.81591 4.65239 7.04889C4.72106 7.26145 4.66773 7.49745 4.49914 7.64399C3.36616 8.62885 2.9653 8.67144 2.49253 8.67144ZM3.66602 0.00239655C3.7822 -0.00651177 3.89895 0.00947896 4.00846 0.0493006C4.11797 0.0891223 4.21772 0.151858 4.30105 0.233314C4.38438 0.314771 4.44935 0.413073 4.49165 0.521653C4.53394 0.630232 4.55258 0.746588 4.54631 0.862945V0.860752C4.53258 1.15708 4.40525 1.43674 4.19074 1.64164C3.97623 1.84656 3.69104 1.96097 3.39439 1.96112L3.37064 1.96075C3.25288 1.97358 3.13485 1.95962 3.02324 1.91993C2.91164 1.88024 2.81044 1.81584 2.72723 1.73154C2.64402 1.64723 2.58094 1.54522 2.54271 1.43311C2.50477 1.32187 2.49227 1.20356 2.5061 1.08687C2.51738 0.789536 2.64564 0.508673 2.86299 0.305421C3.08056 0.101963 3.36973 -0.00722427 3.66748 0.00166549L3.66602 0.00239655Z"})]}))}export{r as default};
2
- //# sourceMappingURL=CognitiveIcon.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CognitiveIcon.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- import{__assign as e,__spreadArray as o}from"tslib";import{jsx as i,jsxs as r,Fragment as t}from"react/jsx-runtime";import{useMemo as n,useState as l}from"react";import a from"@mui/icons-material/ChevronRight";import d from"@mui/icons-material/Close";import c from"@mui/icons-material/ExpandMore";import s from"@mui/material/Box";import u from"@mui/material/Button";import m from"@mui/material/ButtonBase";import p from"@mui/material/Divider";import f from"@mui/material/IconButton";import h from"@mui/material/Paper";import x from"@mui/material/Radio";import b from"@mui/material/Stack";import v from"@mui/material/TextField";import g from"@mui/material/Typography";import C from"./CognitiveIcon.js";import y from"./infoAlert.js";var S=function(e,i){return o([e],Array.isArray(i)?i:null==i?[]:[i],!0)},w=function(e){return e.user_actions.map(function(o){switch(o){case"KEEP_LABEL":return{id:o,title:"Keep as is",description:e.current_label?'Label stays "'.concat(e.current_label,'"'):"Keep the current document label"};case"SET_CUSTOM_LABEL":return{id:o,title:"Enter a custom label",description:"Create your own document label",requiresInput:!0,inputPlaceholder:e.current_label?"e.g. ".concat(e.current_label):"Enter a document label"}}})},L=function(e){return"KEEP_LABEL"===e||"SET_CUSTOM_LABEL"===e};function A(o){var A,k=o.headerName,z=void 0===k?"Label Check":k,I=o.title,E=o.pageNo,B=o.content,_=void 0===B?"We're not fully confident about this label. Confirm it, choose a different type, or add a new one.":B,F=o.cognitiveScore,W=o.config,j=o.metadata,T=o.selectedIndex,M=o.defaultSelectedIndex,R=void 0===M?null:M,D=o.onSelectionChange,P=o.customLabel,K=o.defaultCustomLabel,H=o.onCustomLabelChange,N=o.onConfirm,q=o.onActionConfirm,O=o.onCognitiveClick,U=o.onAdjustManually,G=o.onClose,J=o.confirmLabel,Q=void 0===J?"Confirm":J,V=o.customInputAriaLabel,X=void 0===V?"Custom document label":V,Y=o.manualPrompt,Z=void 0===Y?"Didn't find the right option?":Y,$=o.manualActionLabel,ee=void 0===$?"Adjust Manually":$,oe=o.cognitiveLabel,ie=void 0===oe?"Cognitive Integrity":oe,re=o.showAdjustManually,te=void 0===re||re,ne=o.showCognitiveIntegrity,le=void 0===ne||ne,ae=o.showCloseButton,de=void 0===ae||ae,ce=o.confirmDisabled,se=void 0!==ce&&ce,ue=o.width,me=void 0===ue?340:ue,pe=o.maxWidth,fe=void 0===pe?340:pe,he=o.className,xe=o.styles,be=n(function(){return null!=W?W:j?w(j):[]},[W,j]),ve=l(R),ge=ve[0],Ce=ve[1],ye=l(null!==(A=null!=K?K:null==j?void 0:j.custom_label)&&void 0!==A?A:""),Se=ye[0],we=ye[1],Le=void 0===T?ge:T,Ae=void 0===P?Se:P,ke=null==Le?void 0:be[Le],ze=Boolean(null==ke?void 0:ke.requiresInput),Ie=se||!N&&!q||!ke||!0===ke.disabled||ze&&0===Ae.trim().length,Ee=function(){if(!Ie&&null!=Le&&ke){var e=ze?Ae.trim():void 0;null==N||N(Le,ke,e),q&&L(ke.id)&&q(ke.id,{selectedIndex:Le,option:ke,customLabel:e,metadata:j})}};return i(h,e({className:he,elevation:4,sx:S({width:me,maxWidth:fe,borderTop:"4px solid",borderColor:"error.light",borderRadius:2,bgcolor:"background.paper",overflow:"hidden",boxSizing:"border-box","@media (max-width: 372px)":{width:"calc(100vw - 32px)"}},null==xe?void 0:xe.root)},{children:r(b,e({spacing:1.5,sx:{p:2}},{children:[r(b,e({direction:"row",alignItems:"center",spacing:1,sx:null==xe?void 0:xe.header},{children:[i(y,{color:"error"}),i(g,e({sx:{flex:1,color:"error.main",fontSize:16,fontWeight:500,lineHeight:1.25,textTransform:"uppercase"}},{children:z})),de&&i(f,e({size:"small",onClick:G,disabled:!G,"aria-label":"Close label check",sx:{p:.25,"&.Mui-disabled":{color:"text.secondary"}}},{children:i(d,{sx:{fontSize:20}})}))]})),r(s,{children:[i(g,e({sx:{color:"text.primary",fontSize:18,fontWeight:500}},{children:I})),null!=E&&i(g,e({sx:{mt:.25,color:"text.secondary",fontSize:16}},{children:E})),i(p,{sx:{my:1.25}}),null!=_&&i(g,e({component:"div",sx:{color:"text.secondary",fontSize:15,lineHeight:1.45}},{children:_}))]}),r(b,e({spacing:1,role:"radiogroup","aria-label":"Label options"},{children:[be.map(function(o,t){var n=Le===t;return r(h,e({variant:"outlined",sx:S({borderColor:n?"secondary.main":"divider",borderRadius:2,overflow:"hidden"},null==xe?void 0:xe.option)},{children:[r(m,e({role:"radio","aria-checked":n,disabled:o.disabled,onClick:function(){return function(e,o){o.disabled||(void 0===T&&Ce(e),null==D||D(e,o))}(t,o)},sx:{width:"100%",justifyContent:"flex-start",px:1.25,py:1.125,textAlign:"left"}},{children:[i(x,{checked:n,disabled:o.disabled,tabIndex:-1,size:"small",sx:{p:.5,mr:1}}),r(s,e({sx:{minWidth:0}},{children:[i(g,e({sx:{color:"text.primary",fontSize:15,fontWeight:500}},{children:o.title})),null!=o.description&&i(g,e({sx:{mt:.25,color:"text.secondary",fontSize:13}},{children:o.description}))]}))]})),n&&o.requiresInput&&i(s,e({sx:{px:1.75,pb:1.5,pl:5.75}},{children:i(v,{autoFocus:!0,fullWidth:!0,size:"small",value:Ae,placeholder:o.inputPlaceholder,inputProps:{"aria-label":X},onChange:function(e){return o=e.target.value,void 0===P&&we(o),void(null==H||H(o));var o},onKeyDown:function(e){"Enter"===e.key&&Ee()},sx:null==xe?void 0:xe.customInput})}))]}),o.id)}),i(u,e({variant:"contained",fullWidth:!0,disabled:Ie,onClick:Ee,sx:S({minHeight:48,mt:.25,borderRadius:2,fontSize:17,fontWeight:600,textTransform:"none",backgroundColor:"#5925DC","&:hover":{backgroundColor:"#4A1FB8"},"&.Mui-disabled":{backgroundColor:"#D9D6FE",color:"#FFFFFF"}},null==xe?void 0:xe.confirmButton)},{children:Q}))]})),r(b,e({spacing:1.25,sx:null==xe?void 0:xe.footer},{children:[te&&r(m,e({onClick:U,disabled:!U,sx:{justifyContent:"space-between",borderRadius:1,textAlign:"left"}},{children:[r(s,{children:[i(g,e({sx:{color:"text.primary",fontSize:14}},{children:Z})),i(g,e({sx:{mt:.25,color:"text.primary",fontSize:14}},{children:ee}))]}),i(c,{sx:{color:"text.secondary"}})]})),le&&r(t,{children:[i(p,{}),r(m,e({onClick:O,disabled:!O,sx:{justifyContent:"space-between",borderRadius:1,textAlign:"left"}},{children:[r(b,e({direction:"row",alignItems:"center",spacing:1},{children:[i(C,{sx:{color:"text.secondary"}}),i(g,e({sx:{color:"text.primary",fontSize:15}},{children:ie}))]})),r(b,e({direction:"row",alignItems:"center",spacing:.75},{children:[null!=F&&i(s,e({sx:{px:1,py:.125,border:"1.5px solid",borderColor:"secondary.main",borderRadius:10,color:"secondary.main",fontSize:14,lineHeight:1.25}},{children:F})),i(a,{sx:{color:"text.secondary"}})]}))]}))]})]}))]}))}))}export{w as createLabelCheckOptions,A as default,L as isLabelReviewAction};
2
- //# sourceMappingURL=LabelCheck.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"LabelCheck.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}