@e-llm-studio/requirement-ai 0.0.238 → 0.0.239
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/features/CitationRenderer/CitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/CustomPopover/CustomPopover.js +1 -1
- package/dist/cjs/features/RequirementAI/components/GapRiskSidebar/GapRiskSidebar.js +1 -1
- package/dist/cjs/features/RequirementAI/components/GapRiskSidebar/components/GapItem/GapItem.js +1 -1
- package/dist/cjs/features/RequirementAI/components/GapRiskSidebar/components/RiskCategorySection/RiskCategorySection.js +1 -1
- package/dist/cjs/features/RequirementAI/components/GapRiskSidebar/components/RiskSidebarCategorySection/RiskSidebarCategorySection.js +1 -1
- package/dist/cjs/features/RequirementAI/components/GapRiskSidebar/components/StoryNode/StoryNode.js +1 -1
- package/dist/cjs/features/RequirementAI/components/GapRiskSidebar/utils/buildStoryWithGap.js +1 -1
- package/dist/cjs/features/RequirementAI/components/GapRiskSidebar/utils/buildStoryWithRisk.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RecommendationBlock/RecommendationBlock.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RequirementAIWrapper/RequirementAIWrapper.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/Editor.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/components/Context/ContextMenu.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/components/EditorContainer/EditorContainer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/components/EditorPlaceholder/EditorPlaceholder.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/components/EditorToolbar/EditorToolbar.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/components/EditorToolbar/components/ToolbarButton/ToolbarButton.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/components/Icons/Icon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/DeleteNode.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/HighlightNode.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/InitialHtml.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/InsertNode.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/InvisibleNode.js +2 -0
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/InvisibleNode.js.map +1 -0
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/ManualNode.js +2 -0
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/ManualNode.js.map +1 -0
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/PreservedNode.js +2 -0
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/PreservedNode.js.map +1 -0
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/UpdateNode.js +2 -0
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/plugins/UpdateNode.js.map +1 -0
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/Editor/theme/theme.css.js +1 -1
- package/dist/cjs/features/RequirementAI/components/RichTextEditor/RichTextEditor.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UnsavedChangesPopup/UnsavedChangesPopup.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/AttachedContext.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/ClinicalTrialSection.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CitationAnchor.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CognitiveComponent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/CognitiveComponents/ResizableSplitPane.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/DeviationSummary.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/EditBlockPopup.js +2 -0
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/EditBlockPopup.js.map +1 -0
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/IterateComponent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/ManualEditPopup.js +2 -0
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/ManualEditPopup.js.map +1 -0
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/PopupDefaults.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/RedlineStatusCard.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/Popups/ToneToggle.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/TitleEditor/TitleEditor.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/UserStoryCard.js +1 -1
- package/dist/cjs/features/RequirementAI/components/UserStoryCard/icons/PdfViewerIcons.js +1 -1
- package/dist/cjs/features/RequirementAI/components/ai-reasoning/AIReasonAccordion.js +1 -1
- package/dist/cjs/features/RequirementAI/components/ai-reasoning/AiReasonMarkdownWrapper.js +1 -1
- package/dist/cjs/features/RequirementAI/components/ai-reasoning/AiReasoningCitation.js +1 -1
- package/dist/cjs/features/RequirementAI/components/ai-reasoning/AiReasoningCitationContent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/ai-reasoning/BigEnoughComponent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/ai-reasoning/CitationPdfRendererWrapper.js +1 -1
- package/dist/cjs/features/RequirementAI/components/ai-reasoning/CitationPdfViewer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/ai-reasoning/ScannedCitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/appmod-citation/AppmodCitationContent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/appmod-citation/AppmodCitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/appmod-citation/components/CodeLinkHandler.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/appmod-citation/icons/AppmodIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/appmod-citation/icons/ChatBubbleIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/appmod-citation/icons/SparkleIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/SearchWaveFromWrapper.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/WaveformCitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/components/AudioCitationIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/components/AudioTimeLineSlider.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/components/SegmentByWordsViral.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/components/videoPlayer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/icons/AudioLinesIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/icons/MaximizeIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/icons/MinimizeIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/icons/PauseIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/icons/PlayIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/icons/PlaybackSpeedIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/icons/VideoIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/searchwaveform.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/audio-citation/store/autoplay.wavefrom.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/big-enough/BigEnoughCitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/chat-citation/ChatCitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/file-citation/DocumentCitationIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/file-citation/FileCitationContent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/file-citation/FileCitationRender.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/gpt-web-citation/GptWebCitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/gpt-web-citation/GptWebcitationPanel.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/image-citation/ImageCitationContent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/image-citation/ImageCitationIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/image-citation/ImageCitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/rca-citation/RCACitationContent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/rca-citation/RCACitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/readfile-citation/CustomFileIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/readfile-citation/ReadFileCitationContent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/readfile-citation/ReadFileCitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/readfile-citation/icons/ExternalLinkIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/readfile-citation/icons/FileCodeIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/stormee-citation/StormeeCitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/stormee-citation/StormeeContent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/stormee-citation/components/GradientButton.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/stormee-citation/components/ProblemStatementCard.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/web-citation/FullScreenIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/web-citation/ImagePreviewDialog.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/web-citation/WebCitation.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/web-citation/WebCitationIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/web-citation/WebCitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/web-citation/WebCitationWithImageContent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/citations/web-citation/WebCitationWithImageRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/components/cra/PartialRequirementContent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/lsc-reason-gap/CustomChatCrRedirection.js +1 -1
- package/dist/cjs/features/RequirementAI/components/lsc-reason-gap/GapFilterBlock.js +1 -1
- package/dist/cjs/features/RequirementAI/components/lsc-reason-gap/GapFilterContentWrapper.js +1 -1
- package/dist/cjs/features/RequirementAI/components/lsc-reason-gap/GapFilterItem.js +1 -1
- package/dist/cjs/features/RequirementAI/components/lsc-reason-gap/gapFilterSvgs.js +1 -1
- package/dist/cjs/features/RequirementAI/components/segment/DeleteSegmentsDialog.js +1 -1
- package/dist/cjs/features/RequirementAI/components/segment/EditSegmentDialog.js +1 -1
- package/dist/cjs/features/RequirementAI/components/segment/ExampleComponentWrapper.js +1 -1
- package/dist/cjs/features/RequirementAI/components/segment/Segment.js +1 -1
- package/dist/cjs/features/RequirementAI/components/segment/SegmentLoader.js +1 -1
- package/dist/cjs/features/RequirementAI/components/segment/SegmentWrapper.js +1 -1
- package/dist/cjs/features/RequirementAI/components/story-screen/BigEnoughPanel.js +1 -1
- package/dist/cjs/features/RequirementAI/components/story-screen/CompletionPanel.js +1 -1
- package/dist/cjs/features/RequirementAI/components/story-screen/ReplaceLearnedTags.js +1 -1
- package/dist/cjs/features/RequirementAI/components/story-screen/StreamingScreenSidebar.js +1 -1
- package/dist/cjs/features/RequirementAI/components/story-screen/SubfeatureBlock.js +1 -1
- package/dist/cjs/features/RequirementAI/components/story-screen/UserStoryScreen.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-approval-screen/UserStoryApprovalScreen.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-approval-screen/components/ApprovalBadge/ApprovalBadge.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-approval-screen/components/ApprovalSidebar/ApprovalSidebar.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-approval-screen/components/ApprovalSidebarItem/ApprovalSidebarItem.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-approval-screen/components/ApprovalStatusBadge/ApprovalStatusBadge.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-approval-screen/components/ContentBlock/ContentBlock.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-approval-screen/components/ContentSegment/ContentSegment.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.module.css.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-with-citation/components/HighlightButtonComponent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-with-citation/components/InlineManualComponent.js +2 -0
- package/dist/cjs/features/RequirementAI/components/userstory-with-citation/components/InlineManualComponent.js.map +1 -0
- package/dist/cjs/features/RequirementAI/components/userstory-with-citation/components/InlineManualComponent.module.css.js +2 -0
- package/dist/cjs/features/RequirementAI/components/userstory-with-citation/components/InlineManualComponent.module.css.js.map +1 -0
- package/dist/cjs/features/RequirementAI/components/userstory-with-citation/components/InlineUpdatedComponent.js +1 -1
- package/dist/cjs/features/RequirementAI/components/userstory-with-citation/components/InlineUpdatedComponent.module.css.js +1 -1
- package/dist/cjs/features/RequirementAI/hooks/useApprovalStatus.js +1 -1
- package/dist/cjs/features/RequirementAI/hooks/useStreamContentHandler.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/AiGapIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/AiReasoningIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/BigEnoughIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/BookmarkIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/BrainRed.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/CDIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/CheckIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/ChevronDownIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/ChevronUpIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/CognitiveDecision.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/MeetingHighlightsIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/MenuUnfoldIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/PencilIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/ReasoningBulbIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/RelevanceScoreIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/SidebarCloseIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/SidebarOpenIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/icons/TrashIcon.js +1 -1
- package/dist/cjs/features/RequirementAI/shared/Accordian.js +1 -1
- package/dist/cjs/features/RequirementAI/shared/AtomicButton.js +1 -1
- package/dist/cjs/features/RequirementAI/shared/CitationAIConfidenceDisplay.js +1 -1
- package/dist/cjs/features/RequirementAI/shared/CitationLoadingIndicator.js +1 -1
- package/dist/cjs/features/RequirementAI/shared/CodeViewer.js +1 -1
- package/dist/cjs/features/RequirementAI/shared/ExpandableOl.js +1 -1
- package/dist/cjs/features/RequirementAI/shared/GeneratedCodeCitation.js +1 -1
- package/dist/cjs/features/RequirementAI/shared/ReqAiCitationRenderer.js +1 -1
- package/dist/cjs/features/RequirementAI/shared/UpdatedAnimationContent.js +1 -1
- package/dist/cjs/features/RequirementAI/store/markdown-context.js +1 -1
- package/dist/cjs/features/RequirementAI/store/ref.context.js +1 -1
- package/dist/cjs/features/RequirementAI/utils/diff-edit.utils.js +1 -1
- package/dist/cjs/features/RequirementAI/utils/helpers.js +1 -1
- package/dist/cjs/features/RequirementAI/utils/learned-tag.utils.js +1 -1
- package/dist/cjs/features/RequirementAI/utils/userstory-approval.utils.js +1 -1
- package/dist/cjs/features/RequirementAiCitations/AiReasoning/components/AIConfidenceDisplay.js +1 -1
- package/dist/cjs/features/RequirementAiCitations/AiReasoning/components/icons/DocumentCitationIcon.js +1 -1
- package/dist/cjs/features/RequirementAiCitations/AiReasoning/components/icons/RelevanceScoreIcon.js +1 -1
- package/dist/cjs/features/UserStoryImport/UserStoryPicker.js +1 -1
- package/dist/cjs/features/UserStoryImport/UserStoryPicker.theme.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/BackNav.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/Badge.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/BrowseProjectsButton.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/CardGrid.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/CardProceedButton.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/ContentArea.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/Footer.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/Header.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/NavRow.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/ProceedButton.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/ProjectCard.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/ResizeHandle.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/ScopeDropdown.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/SearchInput.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/SectionHeading.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/ShowMore.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/Sidebar.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/SidebarFavoritesList.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/SidebarProjectList.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/SidebarSection.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/SortDropdown.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/SplitLayout.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/Toolbar.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/TypeDropdown.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/UserStoryCard.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/UserStoryImportDialog.js +1 -1
- package/dist/cjs/features/UserStoryImport/components/UserStoryScopeDropdown.js +1 -1
- package/dist/cjs/features/UserStoryImport/hooks/useUSPData.js +1 -1
- package/dist/cjs/features/UserStoryImport/hooks/useUserStoryPickerState.js +1 -1
- package/dist/cjs/features/UserStoryImport/lib/CustomTooltip.js +1 -1
- package/dist/cjs/features/UserStoryImport/lib/Tooltip.js +1 -1
- package/dist/cjs/features/UserStoryImport/lib/dialog.js +1 -1
- package/dist/cjs/index.js +1 -1
- package/dist/cjs/service/redlineService.js +2 -0
- package/dist/cjs/service/redlineService.js.map +1 -0
- package/dist/cjs/utils/tagHelper.js +2 -0
- package/dist/cjs/utils/tagHelper.js.map +1 -0
- package/dist/features/CitationRenderer/CitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/CustomPopover/CustomPopover.js +1 -1
- package/dist/features/RequirementAI/components/GapRiskSidebar/GapRiskSidebar.js +1 -1
- package/dist/features/RequirementAI/components/GapRiskSidebar/components/GapItem/GapItem.js +1 -1
- package/dist/features/RequirementAI/components/GapRiskSidebar/components/RiskCategorySection/RiskCategorySection.js +1 -1
- package/dist/features/RequirementAI/components/GapRiskSidebar/components/RiskSidebarCategorySection/RiskSidebarCategorySection.js +1 -1
- package/dist/features/RequirementAI/components/GapRiskSidebar/components/StoryNode/StoryNode.js +1 -1
- package/dist/features/RequirementAI/components/GapRiskSidebar/utils/buildStoryWithGap.js +1 -1
- package/dist/features/RequirementAI/components/GapRiskSidebar/utils/buildStoryWithRisk.js +1 -1
- package/dist/features/RequirementAI/components/RecommendationBlock/RecommendationBlock.js +1 -1
- package/dist/features/RequirementAI/components/RequirementAIWrapper/RequirementAIWrapper.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/Editor.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/components/Context/ContextMenu.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/components/EditorContainer/EditorContainer.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/components/EditorPlaceholder/EditorPlaceholder.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/components/EditorToolbar/EditorToolbar.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/components/EditorToolbar/components/ToolbarButton/ToolbarButton.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/components/Icons/Icon.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/DeleteNode.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/HighlightNode.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/InitialHtml.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/InsertNode.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/InvisibleNode.js +2 -0
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/InvisibleNode.js.map +1 -0
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/ManualNode.js +2 -0
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/ManualNode.js.map +1 -0
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/PreservedNode.js +2 -0
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/PreservedNode.js.map +1 -0
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/UpdateNode.js +2 -0
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/plugins/UpdateNode.js.map +1 -0
- package/dist/features/RequirementAI/components/RichTextEditor/Editor/theme/theme.css.js +1 -1
- package/dist/features/RequirementAI/components/RichTextEditor/RichTextEditor.js +1 -1
- package/dist/features/RequirementAI/components/UnsavedChangesPopup/UnsavedChangesPopup.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/AttachedContext.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/ClinicalTrialSection.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CitationAnchor.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CognitiveComponent.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/CognitiveComponents/ResizableSplitPane.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/Popups/DeviationSummary.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/Popups/EditBlockPopup.js +2 -0
- package/dist/features/RequirementAI/components/UserStoryCard/Popups/EditBlockPopup.js.map +1 -0
- package/dist/features/RequirementAI/components/UserStoryCard/Popups/IterateComponent.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/Popups/ManualEditPopup.js +2 -0
- package/dist/features/RequirementAI/components/UserStoryCard/Popups/ManualEditPopup.js.map +1 -0
- package/dist/features/RequirementAI/components/UserStoryCard/Popups/PopupDefaults.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/Popups/RedlineStatusCard.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/Popups/ToneToggle.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/TitleEditor/TitleEditor.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/UserStoryCard.js +1 -1
- package/dist/features/RequirementAI/components/UserStoryCard/icons/PdfViewerIcons.js +1 -1
- package/dist/features/RequirementAI/components/ai-reasoning/AIReasonAccordion.js +1 -1
- package/dist/features/RequirementAI/components/ai-reasoning/AiReasonMarkdownWrapper.js +1 -1
- package/dist/features/RequirementAI/components/ai-reasoning/AiReasoningCitation.js +1 -1
- package/dist/features/RequirementAI/components/ai-reasoning/AiReasoningCitationContent.js +1 -1
- package/dist/features/RequirementAI/components/ai-reasoning/BigEnoughComponent.js +1 -1
- package/dist/features/RequirementAI/components/ai-reasoning/CitationPdfRendererWrapper.js +1 -1
- package/dist/features/RequirementAI/components/ai-reasoning/CitationPdfViewer.js +1 -1
- package/dist/features/RequirementAI/components/ai-reasoning/ScannedCitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/citations/appmod-citation/AppmodCitationContent.js +1 -1
- package/dist/features/RequirementAI/components/citations/appmod-citation/AppmodCitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/citations/appmod-citation/components/CodeLinkHandler.js +1 -1
- package/dist/features/RequirementAI/components/citations/appmod-citation/icons/AppmodIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/appmod-citation/icons/ChatBubbleIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/appmod-citation/icons/SparkleIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/SearchWaveFromWrapper.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/WaveformCitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/components/AudioCitationIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/components/AudioTimeLineSlider.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/components/SegmentByWordsViral.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/components/videoPlayer.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/icons/AudioLinesIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/icons/MaximizeIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/icons/MinimizeIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/icons/PauseIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/icons/PlayIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/icons/PlaybackSpeedIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/icons/VideoIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/searchwaveform.js +1 -1
- package/dist/features/RequirementAI/components/citations/audio-citation/store/autoplay.wavefrom.js +1 -1
- package/dist/features/RequirementAI/components/citations/big-enough/BigEnoughCitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/citations/chat-citation/ChatCitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/citations/file-citation/DocumentCitationIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/file-citation/FileCitationContent.js +1 -1
- package/dist/features/RequirementAI/components/citations/file-citation/FileCitationRender.js +1 -1
- package/dist/features/RequirementAI/components/citations/gpt-web-citation/GptWebCitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/citations/gpt-web-citation/GptWebcitationPanel.js +1 -1
- package/dist/features/RequirementAI/components/citations/image-citation/ImageCitationContent.js +1 -1
- package/dist/features/RequirementAI/components/citations/image-citation/ImageCitationIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/image-citation/ImageCitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/citations/rca-citation/RCACitationContent.js +1 -1
- package/dist/features/RequirementAI/components/citations/rca-citation/RCACitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/citations/readfile-citation/CustomFileIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/readfile-citation/ReadFileCitationContent.js +1 -1
- package/dist/features/RequirementAI/components/citations/readfile-citation/ReadFileCitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/citations/readfile-citation/icons/ExternalLinkIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/readfile-citation/icons/FileCodeIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/stormee-citation/StormeeCitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/citations/stormee-citation/StormeeContent.js +1 -1
- package/dist/features/RequirementAI/components/citations/stormee-citation/components/GradientButton.js +1 -1
- package/dist/features/RequirementAI/components/citations/stormee-citation/components/ProblemStatementCard.js +1 -1
- package/dist/features/RequirementAI/components/citations/web-citation/FullScreenIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/web-citation/ImagePreviewDialog.js +1 -1
- package/dist/features/RequirementAI/components/citations/web-citation/WebCitation.js +1 -1
- package/dist/features/RequirementAI/components/citations/web-citation/WebCitationIcon.js +1 -1
- package/dist/features/RequirementAI/components/citations/web-citation/WebCitationRenderer.js +1 -1
- package/dist/features/RequirementAI/components/citations/web-citation/WebCitationWithImageContent.js +1 -1
- package/dist/features/RequirementAI/components/citations/web-citation/WebCitationWithImageRenderer.js +1 -1
- package/dist/features/RequirementAI/components/cra/PartialRequirementContent.js +1 -1
- package/dist/features/RequirementAI/components/lsc-reason-gap/CustomChatCrRedirection.js +1 -1
- package/dist/features/RequirementAI/components/lsc-reason-gap/GapFilterBlock.js +1 -1
- package/dist/features/RequirementAI/components/lsc-reason-gap/GapFilterContentWrapper.js +1 -1
- package/dist/features/RequirementAI/components/lsc-reason-gap/GapFilterItem.js +1 -1
- package/dist/features/RequirementAI/components/lsc-reason-gap/gapFilterSvgs.js +1 -1
- package/dist/features/RequirementAI/components/segment/DeleteSegmentsDialog.js +1 -1
- package/dist/features/RequirementAI/components/segment/EditSegmentDialog.js +1 -1
- package/dist/features/RequirementAI/components/segment/ExampleComponentWrapper.js +1 -1
- package/dist/features/RequirementAI/components/segment/Segment.js +1 -1
- package/dist/features/RequirementAI/components/segment/SegmentLoader.js +1 -1
- package/dist/features/RequirementAI/components/segment/SegmentWrapper.js +1 -1
- package/dist/features/RequirementAI/components/story-screen/BigEnoughPanel.js +1 -1
- package/dist/features/RequirementAI/components/story-screen/CompletionPanel.js +1 -1
- package/dist/features/RequirementAI/components/story-screen/ReplaceLearnedTags.js +1 -1
- package/dist/features/RequirementAI/components/story-screen/StreamingScreenSidebar.js +1 -1
- package/dist/features/RequirementAI/components/story-screen/SubfeatureBlock.js +1 -1
- package/dist/features/RequirementAI/components/story-screen/UserStoryScreen.js +1 -1
- package/dist/features/RequirementAI/components/userstory-approval-screen/UserStoryApprovalScreen.js +1 -1
- package/dist/features/RequirementAI/components/userstory-approval-screen/components/ApprovalBadge/ApprovalBadge.js +1 -1
- package/dist/features/RequirementAI/components/userstory-approval-screen/components/ApprovalSidebar/ApprovalSidebar.js +1 -1
- package/dist/features/RequirementAI/components/userstory-approval-screen/components/ApprovalSidebarItem/ApprovalSidebarItem.js +1 -1
- package/dist/features/RequirementAI/components/userstory-approval-screen/components/ApprovalStatusBadge/ApprovalStatusBadge.js +1 -1
- package/dist/features/RequirementAI/components/userstory-approval-screen/components/ContentBlock/ContentBlock.js +1 -1
- package/dist/features/RequirementAI/components/userstory-approval-screen/components/ContentSegment/ContentSegment.js +1 -1
- package/dist/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.js +1 -1
- package/dist/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.module.css.js +1 -1
- package/dist/features/RequirementAI/components/userstory-with-citation/components/HighlightButtonComponent.js +1 -1
- package/dist/features/RequirementAI/components/userstory-with-citation/components/InlineManualComponent.js +2 -0
- package/dist/features/RequirementAI/components/userstory-with-citation/components/InlineManualComponent.js.map +1 -0
- package/dist/features/RequirementAI/components/userstory-with-citation/components/InlineManualComponent.module.css.js +2 -0
- package/dist/features/RequirementAI/components/userstory-with-citation/components/InlineManualComponent.module.css.js.map +1 -0
- package/dist/features/RequirementAI/components/userstory-with-citation/components/InlineUpdatedComponent.js +1 -1
- package/dist/features/RequirementAI/components/userstory-with-citation/components/InlineUpdatedComponent.module.css.js +1 -1
- package/dist/features/RequirementAI/hooks/useApprovalStatus.js +1 -1
- package/dist/features/RequirementAI/hooks/useStreamContentHandler.js +1 -1
- package/dist/features/RequirementAI/icons/AiGapIcon.js +1 -1
- package/dist/features/RequirementAI/icons/AiReasoningIcon.js +1 -1
- package/dist/features/RequirementAI/icons/BigEnoughIcon.js +1 -1
- package/dist/features/RequirementAI/icons/BookmarkIcon.js +1 -1
- package/dist/features/RequirementAI/icons/BrainRed.js +1 -1
- package/dist/features/RequirementAI/icons/CDIcon.js +1 -1
- package/dist/features/RequirementAI/icons/CheckIcon.js +1 -1
- package/dist/features/RequirementAI/icons/ChevronDownIcon.js +1 -1
- package/dist/features/RequirementAI/icons/ChevronUpIcon.js +1 -1
- package/dist/features/RequirementAI/icons/CognitiveDecision.js +1 -1
- package/dist/features/RequirementAI/icons/MeetingHighlightsIcon.js +1 -1
- package/dist/features/RequirementAI/icons/MenuUnfoldIcon.js +1 -1
- package/dist/features/RequirementAI/icons/PencilIcon.js +1 -1
- package/dist/features/RequirementAI/icons/ReasoningBulbIcon.js +1 -1
- package/dist/features/RequirementAI/icons/RelevanceScoreIcon.js +1 -1
- package/dist/features/RequirementAI/icons/SidebarCloseIcon.js +1 -1
- package/dist/features/RequirementAI/icons/SidebarOpenIcon.js +1 -1
- package/dist/features/RequirementAI/icons/TrashIcon.js +1 -1
- package/dist/features/RequirementAI/shared/Accordian.js +1 -1
- package/dist/features/RequirementAI/shared/AtomicButton.js +1 -1
- package/dist/features/RequirementAI/shared/CitationAIConfidenceDisplay.js +1 -1
- package/dist/features/RequirementAI/shared/CitationLoadingIndicator.js +1 -1
- package/dist/features/RequirementAI/shared/CodeViewer.js +1 -1
- package/dist/features/RequirementAI/shared/ExpandableOl.js +1 -1
- package/dist/features/RequirementAI/shared/GeneratedCodeCitation.js +1 -1
- package/dist/features/RequirementAI/shared/ReqAiCitationRenderer.js +1 -1
- package/dist/features/RequirementAI/shared/UpdatedAnimationContent.js +1 -1
- package/dist/features/RequirementAI/store/markdown-context.js +1 -1
- package/dist/features/RequirementAI/store/ref.context.js +1 -1
- package/dist/features/RequirementAI/utils/diff-edit.utils.js +1 -1
- package/dist/features/RequirementAI/utils/helpers.js +1 -1
- package/dist/features/RequirementAI/utils/learned-tag.utils.js +1 -1
- package/dist/features/RequirementAI/utils/userstory-approval.utils.js +1 -1
- package/dist/features/RequirementAiCitations/AiReasoning/components/AIConfidenceDisplay.js +1 -1
- package/dist/features/RequirementAiCitations/AiReasoning/components/icons/DocumentCitationIcon.js +1 -1
- package/dist/features/RequirementAiCitations/AiReasoning/components/icons/RelevanceScoreIcon.js +1 -1
- package/dist/features/UserStoryImport/UserStoryPicker.js +1 -1
- package/dist/features/UserStoryImport/UserStoryPicker.theme.js +1 -1
- package/dist/features/UserStoryImport/components/BackNav.js +1 -1
- package/dist/features/UserStoryImport/components/Badge.js +1 -1
- package/dist/features/UserStoryImport/components/BrowseProjectsButton.js +1 -1
- package/dist/features/UserStoryImport/components/CardGrid.js +1 -1
- package/dist/features/UserStoryImport/components/CardProceedButton.js +1 -1
- package/dist/features/UserStoryImport/components/ContentArea.js +1 -1
- package/dist/features/UserStoryImport/components/Footer.js +1 -1
- package/dist/features/UserStoryImport/components/Header.js +1 -1
- package/dist/features/UserStoryImport/components/NavRow.js +1 -1
- package/dist/features/UserStoryImport/components/ProceedButton.js +1 -1
- package/dist/features/UserStoryImport/components/ProjectCard.js +1 -1
- package/dist/features/UserStoryImport/components/ResizeHandle.js +1 -1
- package/dist/features/UserStoryImport/components/ScopeDropdown.js +1 -1
- package/dist/features/UserStoryImport/components/SearchInput.js +1 -1
- package/dist/features/UserStoryImport/components/SectionHeading.js +1 -1
- package/dist/features/UserStoryImport/components/ShowMore.js +1 -1
- package/dist/features/UserStoryImport/components/Sidebar.js +1 -1
- package/dist/features/UserStoryImport/components/SidebarFavoritesList.js +1 -1
- package/dist/features/UserStoryImport/components/SidebarProjectList.js +1 -1
- package/dist/features/UserStoryImport/components/SidebarSection.js +1 -1
- package/dist/features/UserStoryImport/components/SortDropdown.js +1 -1
- package/dist/features/UserStoryImport/components/SplitLayout.js +1 -1
- package/dist/features/UserStoryImport/components/Toolbar.js +1 -1
- package/dist/features/UserStoryImport/components/TypeDropdown.js +1 -1
- package/dist/features/UserStoryImport/components/UserStoryCard.js +1 -1
- package/dist/features/UserStoryImport/components/UserStoryImportDialog.js +1 -1
- package/dist/features/UserStoryImport/components/UserStoryScopeDropdown.js +1 -1
- package/dist/features/UserStoryImport/hooks/useUSPData.js +1 -1
- package/dist/features/UserStoryImport/hooks/useUserStoryPickerState.js +1 -1
- package/dist/features/UserStoryImport/lib/CustomTooltip.js +1 -1
- package/dist/features/UserStoryImport/lib/Tooltip.js +1 -1
- package/dist/features/UserStoryImport/lib/dialog.js +1 -1
- package/dist/index.js +1 -1
- package/dist/service/redlineService.js +2 -0
- package/dist/service/redlineService.js.map +1 -0
- package/dist/types/src/App.d.ts.map +1 -1
- package/dist/types/src/RedlineEditorTest.d.ts +3 -0
- package/dist/types/src/RedlineEditorTest.d.ts.map +1 -0
- package/dist/types/src/RequirementAiTest.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/RequirementAIWrapper/RequirementAIWrapper.d.ts +40 -1
- package/dist/types/src/features/RequirementAI/components/RequirementAIWrapper/RequirementAIWrapper.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/Editor.d.ts +2 -1
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/Editor.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/DeleteNode.d.ts +1 -4
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/DeleteNode.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/InitialHtml.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/InsertNode.d.ts +4 -3
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/InsertNode.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/InvisibleNode.d.ts +35 -0
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/InvisibleNode.d.ts.map +1 -0
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/ManualNode.d.ts +26 -0
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/ManualNode.d.ts.map +1 -0
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/PreservedNode.d.ts +23 -0
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/PreservedNode.d.ts.map +1 -0
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/UpdateNode.d.ts +26 -0
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/Editor/plugins/UpdateNode.d.ts.map +1 -0
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/RichTextEditor.d.ts +1 -0
- package/dist/types/src/features/RequirementAI/components/RichTextEditor/RichTextEditor.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CognitiveComponent.d.ts +9 -4
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/CognitiveComponents/CognitiveComponent.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/DeviationSummary.d.ts +45 -11
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/DeviationSummary.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/EditBlockPopup.d.ts +7 -0
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/EditBlockPopup.d.ts.map +1 -0
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/ManualEditPopup.d.ts +25 -0
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/ManualEditPopup.d.ts.map +1 -0
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/RedlineStatusCard.d.ts +15 -3
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/Popups/RedlineStatusCard.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/UserStoryCard.d.ts +9 -2
- package/dist/types/src/features/RequirementAI/components/UserStoryCard/UserStoryCard.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.d.ts +4 -0
- package/dist/types/src/features/RequirementAI/components/userstory-with-citation/UserStoryWithCitation.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/components/userstory-with-citation/components/InlineManualComponent.d.ts +11 -0
- package/dist/types/src/features/RequirementAI/components/userstory-with-citation/components/InlineManualComponent.d.ts.map +1 -0
- package/dist/types/src/features/RequirementAI/components/userstory-with-citation/components/InlineUpdatedComponent.d.ts +3 -1
- package/dist/types/src/features/RequirementAI/components/userstory-with-citation/components/InlineUpdatedComponent.d.ts.map +1 -1
- package/dist/types/src/features/RequirementAI/types/aiReasoning.type.d.ts +22 -13
- package/dist/types/src/features/RequirementAI/types/aiReasoning.type.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +2 -0
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/service/redlineService.d.ts +33 -0
- package/dist/types/src/service/redlineService.d.ts.map +1 -0
- package/dist/types/src/utils/tagHelper.d.ts +5 -0
- package/dist/types/src/utils/tagHelper.d.ts.map +1 -0
- package/dist/utils/tagHelper.js +2 -0
- package/dist/utils/tagHelper.js.map +1 -0
- package/package.json +17 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsxs as t,jsx as e}from"react/jsx-runtime";import{Check as n,X as
|
|
1
|
+
import{jsxs as t,jsx as e}from"react/jsx-runtime";import{Check as n,X as l}from"lucide-react";import{useState as i,useRef as o,useEffect as r}from"react";import a from"../UserStoryCard.module.css.js";const s=({title:s,onSave:c,onCancel:u,inputStyle:p,confirmButtonStyle:m,cancelButtonStyle:d})=>{const[y,f]=i(s),C=o(null);r(()=>{var t,e;null===(t=C.current)||void 0===t||t.focus(),null===(e=C.current)||void 0===e||e.select()},[]);return t("div",{className:a.inlineTitleEditor,style:p,onClick:t=>t.stopPropagation(),onMouseDown:t=>{t.stopPropagation()},children:[e("input",{ref:C,type:"text",value:y,onChange:t=>f(t.target.value),onClick:t=>{t.stopPropagation()},onMouseDown:t=>{t.stopPropagation()},onKeyDown:t=>{if("Enter"===t.key){t.preventDefault();const e=y.trim();e&&c(e)}else"Escape"===t.key&&(t.preventDefault(),u())},className:a.inlineTitleInput,style:p,maxLength:200,"aria-label":"Edit title"}),e("button",{type:"button",className:a.inlineTitleConfirm,style:m,onClick:()=>{const t=y.trim();t&&c(t)},disabled:!y.trim(),"aria-label":"Confirm title",title:"Confirm (Enter)",children:e(n,{size:14})}),e("button",{type:"button",className:a.inlineTitleCancel,style:d,onClick:u,"aria-label":"Cancel edit",title:"Cancel (Escape)",children:e(l,{size:14})})]})};export{s as InlineTitleEditor};
|
|
2
2
|
//# sourceMappingURL=TitleEditor.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__awaiter as e}from"tslib";import{jsxs as t,jsx as n,Fragment as i}from"react/jsx-runtime";import{useState as l,useRef as o,useEffect as s}from"react";import{ChevronUp as a,ChevronDown as r,ExternalLink as d,Download as c,Share2 as u,Copy as v,LoaderCircle as g,PencilIcon as p,Plus as m,Trash2 as y,X as h,Ellipsis as b,Hourglass as S,Check as f,ChevronUpIcon as C,ChevronDownIcon as O,Info as j,Bookmark as I}from"lucide-react";import N from"showdown";import{Tooltip as w,Menu as E,MenuItem as D}from"@mui/material";import B from"../../icons/Illustration.svg.js";import{v4 as T}from"uuid";import x from"./UserStoryCard.module.css.js";import{formatMarkdown as U,indentMarkdown as A}from"../../utils/helpers.js";import{preprocessUserStoryForEdit as P,replaceTitleSection as k,postprocessUserStoryAfterEdit as R}from"../../utils/user-story.utils.js";import M from"../../shared/AtomicButton.js";import _ from"../RichTextEditor/RichTextEditor.js";import L from"../userstory-with-citation/UserStoryWithCitation.js";import{SectionStatus as z,useRequirementAI as G}from"../RequirementAIWrapper/RequirementAIWrapper.js";import{BigEnoughPanel as V}from"../story-screen/BigEnoughPanel.js";import{InlineTitleEditor as W}from"./TitleEditor/TitleEditor.js";import H from"./ClinicalTrialSection.js";import{CompletionPanel as $}from"../story-screen/CompletionPanel.js";import F from"../../icons/CDIcon.js";const q={[z.WAITING]:"WAITING TO GENERATE",[z.IN_PROGRESS]:"IN PROGRESS",[z.GENERATED]:"GENERATED",[z.FAILED]:"FAILED",[z.GENERATE]:"GENERATE",[z.APPROVED]:"APPROVED"};function Q(e){const t=[],i=/<learned>(.*?)<\/learned>/g;let l,o=0,s=0;for(;null!==(l=i.exec(e));){const[,a]=l,r=l.index;r>o&&t.push(n("span",{children:e.slice(o,r)},"text-pre-"+s++)),t.push(n(w,Object.assign({title:a,placement:"top"},{children:n(j,{size:16,className:"inline-block mx-1 text-blue-500 hover:text-blue-700 cursor"})}),`tooltip-${T()}`)),o=i.lastIndex}return o<(null==e?void 0:e.length)&&t.push(n("span",{children:e.slice(o)},"text-post-"+s++)),t}function Y(e,t,n){var i;if(!e)return{};if(t)return Object.assign({},e.parentConfig);const l=Object.assign({},e.childConfig);return n&&(null===(i=e.subFeatureOverrides)||void 0===i?void 0:i[n])?Object.assign(Object.assign({},l),e.subFeatureOverrides[n]):l}const Z=({displayName:e})=>{var i;const{customStyles:l}=G(),o=null===(i=null==l?void 0:l.userStoryCardStyles)||void 0===i?void 0:i.showDisplayName;return t("div",Object.assign({className:x.displayName,style:null==o?void 0:o.wrapper},{children:[n(I,{className:x.displayNameIcon,style:null==o?void 0:o.displayNameIcon}),t("span",Object.assign({style:null==o?void 0:o.label},{children:[e,":"]}))]}))},J=({isUserStoryCurrentlyUpdated:C,artifactId:O,artifactTitleId:j,parentUserStory:I,currentUserStory:K,onUserStoryChange:X,parentIndex:ee,currentIndex:te,enableDownload:ne,isDiffEditReviewMode:ie,showUserStoryDiff:le,handleDownloadUserStory:oe,handleOpenSendDialog:se,updateUserStoryArtifact:ae,selectedArtifactId:re,isDisplayHighlightControl:de,elementDisplayConfig:ce,_resolvedConfig:ue,showWrapper:ve=!1,defaultExpanded:ge,actionItemsConfig:pe,onDelete:me,contextVariant:ye,expandedSubFeatures:he,showDisplayName:be=!0,allowTitleEdit:Se=!0,showConfidenceScore:fe=!0,showBorderTop:Ce=!0,sectionStatusConfig:Oe,showCompletionPanel:je=!1,completionPanelConfig:Ie,showAddSectionButton:Ne=!1,disableEditPlan:we=!1,useMuiTooltip:Ee=!1,approveButtonConfig:De,editButtonConfig:Be,CDNeededInChip:Te,blockNumber:xe})=>{var Ue,Ae,Pe,ke,Re,Me,_e,Le,ze,Ge,Ve,We,He,$e,Fe,qe,Qe,Ye,Ze,Je,Ke,Xe,et,tt;const{isLoadingSectionData:nt=!1,onLoadSectionData:it,status:lt,onStatusClick:ot,completedCount:st,totalCount:at,isNoDataAvailable:rt=!1}=null!=Oe?Oe:{},{searchQueryList:dt,citations:ct,customStyles:ut,customSectionConfig:vt}=G(),gt=null==ut?void 0:ut.userStoryCardStyles,pt=null==gt?void 0:gt.customSectionEditButton,mt=null==gt?void 0:gt.statusStyles,yt=null===(Ue=null==ut?void 0:ut.userStoryCardStyles)||void 0===Ue?void 0:Ue.userStoryEditStyles,ht=null===(Ae=null==ut?void 0:ut.userStoryScreenStyles)||void 0===Ae?void 0:Ae.userStoryContentStyles,bt=null==gt?void 0:gt.progressHeaderStyles,St=null==gt?void 0:gt.clinicalTrialSectionStyles,ft=null==gt?void 0:gt.CompletionStyles,Ct=null==gt?void 0:gt.noDataStyles,Ot=null==gt?void 0:gt.approveButtonStyles,jt=null!==(ke=null===(Pe=null==vt?void 0:vt.shouldRender)||void 0===Pe?void 0:Pe.call(vt,K))&&void 0!==ke&&ke,It=null===(Re=null==vt?void 0:vt.getValue)||void 0===Re?void 0:Re.call(vt,K),Nt=null!==(_e=null===(Me=null==vt?void 0:vt.getFields)||void 0===Me?void 0:Me.call(vt,K))&&void 0!==_e?_e:[],wt=null!==(Le=null==vt?void 0:vt.isEditDisabled)&&void 0!==Le&&Le,Et=null!==(Ge=null===(ze=null==vt?void 0:vt.isSaving)||void 0===ze?void 0:ze.call(vt,K))&&void 0!==Ge&&Ge,Dt=((e,t)=>e>=80?null==t?void 0:t.highCompletion:e>=50?null==t?void 0:t.mediumCompletion:null==t?void 0:t.lowCompletion)(null!==(Ve=K.completion_percentage)&&void 0!==Ve?Ve:0,ft),Bt={[z.WAITING]:null==mt?void 0:mt.waiting,[z.IN_PROGRESS]:null==mt?void 0:mt.inProgress,[z.GENERATED]:null==mt?void 0:mt.generated,[z.FAILED]:null==mt?void 0:mt.failed,[z.GENERATE]:null==mt?void 0:mt.generate,[z.APPROVED]:null==mt?void 0:mt.approved},[Tt,xt]=l(Object.assign(Object.assign({},structuredClone(K)),{value:U(K.value)||""})),[Ut,At]=l({userStory:!!K.isDefaultEdit}),[Pt,kt]=l(!1),[Rt,Mt]=l(!1),[_t,Lt]=l(null),[zt,Gt]=l(null),{userStory:Vt,customIcons:Wt}=G(),[Ht,$t]=l(null!=ge?ge:""===ee||re===K.artifactId||!!K.isDefaultOpen),[Ft,qt]=l(!1),[Qt,Yt]=l(null),[Zt,Jt]=l(null),[Kt,Xt]=l(!1),en=o(null),tn=o(null),[nn,ln]=l(!1),[on,sn]=l(!1),an=o(null),[rn,dn]=l(!1);s(()=>{C&&$t(C)},[C]),s(()=>{xt(Object.assign(Object.assign({},structuredClone(K)),{value:U(K.value)||""}))},[K]),s(()=>{dt.length>0?$t(!0):void 0===ge&&re&&$t(re===K.artifactId)},[dt,re,K.artifactId]),s(()=>{he&&he.length>0&&$t(he.includes(K.artifactId)||""===ee||re===K.artifactId||!!K.isDefaultOpen)},[he]);const cn=()=>{Yt(null)},un=()=>{Jt(null)},vn=()=>{Ht&&Ut.userStory&&tn.current&&!tn.current.requestClose()||$t(e=>!e)},gn=()=>e(void 0,void 0,void 0,function*(){var e,t;Xt(!0);try{"userStory"==="userStory"&&(X(Tt),console.log("I am changing RTE editor values",Tt)),yield null===(e=null==Be?void 0:Be.onSaveEditedSection)||void 0===e?void 0:e.call(Be,Tt),yield ae(ct,Vt,O,null===(t=an.current)||void 0===t?void 0:t.signal),X(Object.assign(Object.assign({},Tt),{isDefaultEdit:!1})),At(e=>Object.assign(Object.assign({},e),{userStory:!1}))}finally{Xt(!1)}});const pn=null!=(null==K?void 0:K.big_enough)&&!Number.isNaN(K.big_enough)&&!!(null==K?void 0:K.big_enough_decision_factors),mn=null!==(We=null==K?void 0:K.completion_percentage)&&void 0!==We?We:0,yn=!!(null==K?void 0:K.completion_decision_factors),hn=""===ee,bn=null!=ue?ue:Y(ce,hn),Sn=!ie&&!le;return s(()=>{if(!zt)return;const e=setTimeout(()=>{const e=document.getElementById(`story-card-${zt}`);null==e||e.scrollIntoView({behavior:"smooth",block:"start"})},100);return()=>clearTimeout(e)},[zt]),s(()=>{K.isDefaultEdit&&At(e=>Object.assign(Object.assign({},e),{userStory:!0}))},[K.isDefaultEdit]),console.log("block number in userstory card ",xe),console.log("[TESTING-CURRENT-USER-STORY] \n",K,"\n[TESTING-USER-STORY] \n",Vt),t("div",Object.assign({className:x.card,"data-block-id":"user-story-card-wrapper-"+xe,style:null==gt?void 0:gt.cardStyle,id:`story-card-${K.title}`,"data-expanded":Ht},{children:[t("div",Object.assign({className:x.titleSection,style:null==gt?void 0:gt.titleSection},{children:[t("div",Object.assign({className:x.titleRow,style:null==gt?void 0:gt.titleRow,onClick:vn},{children:[t("div",Object.assign({className:x.titleLeft,style:null==gt?void 0:gt.titleLeft,onMouseEnter:()=>ln(!0),onMouseLeave:()=>ln(!1)},{children:[be&&n(Z,{displayName:j}),Pt&&Sn?n(W,{title:K.title,onSave:t=>((t,n)=>e(void 0,void 0,void 0,function*(){var e;try{let i=Object.assign({},K);K.artifactId===n?i.title=t:i.sub_features=(null===(e=K.sub_features)||void 0===e?void 0:e.map(e=>e.artifactId===n?Object.assign(Object.assign({},e),{title:t}):e))||[],xt(i),X(i),kt(!1)}catch(e){console.error("Failed to save title",e)}}))(t,K.artifactId),onCancel:()=>{kt(!1)},inputStyle:null==yt?void 0:yt.inlineTitleInput,confirmButtonStyle:null==yt?void 0:yt.inlineTitleConfirm,cancelButtonStyle:null==yt?void 0:yt.inlineTitleCancel},"inline-title-editor"):t("div",Object.assign({className:x.storyTitleWrapper},{children:[n(w,Object.assign({title:Q(K.title),arrow:!0},{children:n("h2",Object.assign({title:Ee?void 0:K.title,className:x.storyTitle,style:null==gt?void 0:gt.storyTitle},{children:Q(K.title)}),K.artifactId)})),je&&(yn?n($,Object.assign({customIcons:null==Wt?void 0:Wt.userStoryIcons,customStyles:null==gt?void 0:gt.aiReasoningCitaionStyles,currentUserStory:K,panelStyles:null==gt?void 0:gt.CompletionStyles,onToggleStateChange:sn,completionPanelConfig:Ie},{children:t("div",Object.assign({style:Object.assign(Object.assign({display:"inline-flex",alignItems:"center",gap:"4px"},null==ft?void 0:ft.badge),Dt)},{children:[t("span",{children:[mn,"% Completed"]}),n("span",Object.assign({style:{display:"flex",alignItems:"center"}},{children:n(F,{color:"currentColor"})})),n(on?a:r,{size:14,style:null==ft?void 0:ft.chevronStyle})]}))})):n("div",Object.assign({style:Object.assign(Object.assign({display:"inline-flex",alignItems:"center",gap:"4px"},null==ft?void 0:ft.badge),Dt)},{children:t("span",{children:[mn,"% Completed"]})}))),Se&&n("button",Object.assign({type:"button",className:x.titleEditButton,style:null==yt?void 0:yt.titleEditButton,onClick:e=>{e.stopPropagation(),kt(!0),Ht||$t(!0)},"aria-label":"Edit title",title:"Edit title"},{children:n("svg",Object.assign({width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:n("path",{d:"M8.99998 14.9992H15.75M2.25 14.9992H3.50591C3.87279 14.9992 4.05624 14.9992 4.22887 14.9577C4.38192 14.921 4.52824 14.8604 4.66245 14.7782C4.81382 14.6854 4.94354 14.5557 5.20296 14.2962L14.625 4.87419C15.2463 4.25287 15.2463 3.24551 14.625 2.62419C14.0037 2.00287 12.9963 2.00287 12.375 2.62419L2.95295 12.0462C2.69352 12.3057 2.5638 12.4354 2.47104 12.5868C2.3888 12.721 2.32819 12.8673 2.29145 13.0203C2.25 13.193 2.25 13.3764 2.25 13.7433V14.9992Z",stroke:"#94A3B8","stroke-width":"1.54286","stroke-linecap":"round","stroke-linejoin":"round"})}))}))]}))]})),(lt||void 0!==st&&void 0!==at)&&t("div",Object.assign({className:x.statusContainer},{children:[void 0!==st&&void 0!==at&&t("div",Object.assign({className:x.completedBadge},{children:["Completed: ",st,"/",at]})),lt&&n("button",Object.assign({type:"button",onClick:e=>{e.stopPropagation(),null==ot||ot()},onMouseEnter:()=>dn(!0),onMouseLeave:()=>dn(!1),className:x.statusButton,style:Object.assign(Object.assign({},null===(He=Bt[lt])||void 0===He?void 0:He.default),rn&&(null===($e=Bt[lt])||void 0===$e?void 0:$e.hover))},{children:q[lt]}))]})),t("div",Object.assign({className:x.titleActions,style:null==gt?void 0:gt.titleActions,onClick:e=>e.stopPropagation()},{children:[(bn.showProgressPercentage||bn.showGapBox)&&ve&&t("div",Object.assign({className:x.progressHeader,style:null==bt?void 0:bt.wrapper},{children:[bn.showProgressPercentage&&t("div",Object.assign({className:x.progressPercentage,style:null==bt?void 0:bt.percentage},{children:[null!==(qe=null!==(Fe=null==K?void 0:K.confidenceScore)&&void 0!==Fe?Fe:null==bn?void 0:bn.confidenceValue)&&void 0!==qe?qe:"0","%"]})),bn.showGapBox&&t("div",Object.assign({className:x.gapBox,style:null==bt?void 0:bt.gapBox},{children:[null!==(Ye=null!==(Qe=null==K?void 0:K.gapValue)&&void 0!==Qe?Qe:null==bn?void 0:bn.gapBoxValue)&&void 0!==Ye?Ye:"2"," ","Gaps"]}))]})),pn&&n(V,{customIcons:null==Wt?void 0:Wt.userStoryIcons,customStyles:null==gt?void 0:gt.aiReasoningCitaionStyles,currentUserStory:K,panelStyles:null==gt?void 0:gt.BigEnoughStyles}),!Ut.userStory&&t(i,{children:[!1!==(null==bn?void 0:bn.showShareButton)&&n("button",Object.assign({className:x.iconButton,style:null==gt?void 0:gt.iconButton,onClick:e=>{Yt(e.currentTarget)}},{children:n(d,{size:16})})),t(E,Object.assign({id:"user-story-share-menu",anchorEl:Qt,open:!!Qt,onClose:()=>Yt(null),style:null==gt?void 0:gt.userStoryShareMenu},{children:[ne&&n(D,Object.assign({style:null==gt?void 0:gt.userStoryMenuItem,onClick:()=>e(void 0,void 0,void 0,function*(){qt(!0),oe&&(yield Promise.all([oe("pdf"),oe("doc")]),qt(!1))})},{children:t("div",Object.assign({ref:en,className:x.menuItemContent,style:null==gt?void 0:gt.menuItemContent},{children:[n(c,{size:16,color:null==gt?void 0:gt.menuIconColor}),n("p",Object.assign({style:null==gt?void 0:gt.menuLabel},{children:"Download"}))]}))})),n(D,Object.assign({style:null==gt?void 0:gt.userStoryMenuItem,onClick:()=>e(void 0,void 0,void 0,function*(){let e=K;I&&(e=Object.assign(Object.assign({},K),{value:`${k(null==I?void 0:I.value,K.title)} \n${K.value}`})),null==se||se(!0,[e],K.artifactId),cn()})},{children:t("div",Object.assign({style:null==gt?void 0:gt.menuItemContent,className:x.menuItemContentPadded},{children:[n(u,{size:16,color:null==gt?void 0:gt.menuIconColor}),n("p",Object.assign({style:null==gt?void 0:gt.menuLabel},{children:"Send"}))]}))})),n(D,Object.assign({style:null==gt?void 0:gt.userStoryMenuItem,onClick:()=>e(void 0,void 0,void 0,function*(){const e=(new N.Converter).makeHtml(U(K.value)||K.value),t=function(e){const t=(new N.Converter).makeHtml(e),n=document.createElement("div");return n.innerHTML=t,n.textContent||n.innerText||""}(U(K.value)||K.value),n=new ClipboardItem({"text/plain":new Blob([t],{type:"text/plain"}),"text/html":new Blob([e],{type:"text/html"})});try{yield navigator.clipboard.write([n]),console.log("Copied User Story")}catch(e){console.error("Failed to copy user story:",e)}finally{cn()}})},{children:t("div",Object.assign({style:null==gt?void 0:gt.menuItemContent,className:x.menuItemContentPadded},{children:[n(v,{size:16,color:null==gt?void 0:gt.menuIconColor}),n("p",Object.assign({style:null==gt?void 0:gt.menuLabel},{children:"Copy"}))]}))}))]}))]}),Ut.userStory&&Ht?n(M,{type:"outline",children:"Cancel",style:null==gt?void 0:gt.cancelButton,onClick:()=>{var e;null===(e=an.current)||void 0===e||e.abort(),At(e=>Object.assign(Object.assign({},e),{userStory:!1}))}}):n(i,{}),Ut.userStory&&Ht?n(M,{type:"fill",children:Kt?t("span",Object.assign({className:x.savingSpinner,style:null==gt?void 0:gt.savingSpinner},{children:[n(g,{className:x.spinAnimation,style:null==gt?void 0:gt.spinAnimation}),n("span",{children:"Saving..."})]})):"Save",isDisable:Kt,style:Kt?null==gt?void 0:gt.savingButton:null==gt?void 0:gt.saveButton,onClick:()=>e(void 0,void 0,void 0,function*(){yield gn()})}):!ie&&!le&&!we&&Ht&&!1!==(null==bn?void 0:bn.showEditButton)&&n("button",Object.assign({className:x.iconButton,style:null==gt?void 0:gt.editButton,onClick:()=>At(e=>Object.assign(Object.assign({},e),{userStory:!0}))},{children:n(p,{color:null==gt?void 0:gt.pencilIconColor,size:16})})),Ne&&hn&&Ht&&!ie&&!le&&!1!==(null==bn?void 0:bn.showEditButton)&&t("button",Object.assign({type:"button",className:x.addSectionButton,style:null==yt?void 0:yt.addSectionButton,onClick:e=>{var t,n,i;e.stopPropagation();const l=(null!==(n=null===(t=K.sub_features)||void 0===t?void 0:t.length)&&void 0!==n?n:0)+1,o={artifactId:T(),title:`New Section ${l}`,value:"Please add details for this section.",section:"subfeature",isDefaultOpen:!0},s=Object.assign(Object.assign({},K),{sub_features:[...null!==(i=K.sub_features)&&void 0!==i?i:[],o]});xt(s),X(s),$t(!0),Gt(o.title)},"aria-label":"Add section",title:"Add section"},{children:[n(m,{size:14}),n("span",Object.assign({className:x.addSectionLabel},{children:"Add Section"}))]})),!hn&&!ie&&!we&&!le&&n("button",Object.assign({type:"button",onClick:e=>{e.stopPropagation(),null==me||me()},className:x.iconButton,style:null==yt?void 0:yt.deleteButton,"aria-label":"Delete section",title:"Delete section"},{children:n(y,{size:16})})),jt&&n("button",Object.assign({type:"button",className:x.iconButton,style:null==pt?void 0:pt.button,disabled:wt,onClick:e=>{if(e.stopPropagation(),Rt)return Lt(null),void Mt(!1);Lt(structuredClone(null!=It?It:{})),$t(!0),Mt(!0)}},{children:Rt?n(h,{size:16,color:null==gt?void 0:gt.pencilIconColor,style:null==pt?void 0:pt.cancelIcon}):n(p,{size:16,color:null==gt?void 0:gt.pencilIconColor,style:null==pt?void 0:pt.editIcon})})),(null==bn?void 0:bn.actionItemsButton)&&t(i,{children:[n("span",Object.assign({className:x.actionItemBtn,style:null==gt?void 0:gt.actionItemBtn,onClick:e=>{e.stopPropagation(),Jt(e.currentTarget)}},{children:n(b,{})})),n(E,Object.assign({id:"user-story-action-menu",anchorEl:Zt,open:!!Zt,onClose:un,style:null==gt?void 0:gt.userStoryShareMenu},{children:null==pe?void 0:pe.items.map((e,i)=>n(D,Object.assign({style:null==gt?void 0:gt.userStoryMenuItem,onClick:()=>{e.onclick(K),un()}},{children:t("div",Object.assign({className:x.menuItemContent,style:Object.assign(Object.assign({},null==gt?void 0:gt.menuItemContent),!e.isActive&&{cursor:"not-allowed",opacity:.5})},{children:[n("span",Object.assign({className:x.menuItemIcon,style:null==gt?void 0:gt.menuItemIcon},{children:e.icon})),n("p",Object.assign({style:null==gt?void 0:gt.menuLabel},{children:e.name})),n("span",{className:x.menuItemRight,style:null==gt?void 0:gt.menuItemRight})]}))}),`action-item-${i}-${e.name}`))}))]}),n("button",Object.assign({type:"button",onClick:e=>{e.stopPropagation(),vn()},style:null==gt?void 0:gt.chevronButton,className:x.chevronButton},{children:n(Ht?a:r,{className:x.chevronIcon,color:null==gt?void 0:gt.chevronIconColor})}))]}))]})),n("div",{className:x.divider,style:null==gt?void 0:gt.dividerStyle})]})),Ht&&n("div",Object.assign({className:x.cardContent,style:Object.assign(Object.assign({},null==gt?void 0:gt.cardContentStyle),{borderTop:Ce?"1px solid #E5E5E5":"none"})},{children:t("div",nt?Object.assign({className:x.loadingContainer},{children:[n("div",Object.assign({className:x.loadingIconWrapper},{children:n(S,{size:28,color:"#5B3DF5",className:x.spinAnimation})})),t("div",{children:[n("h3",Object.assign({className:x.loadingTitle},{children:"Section generation in progress.."})),n("p",Object.assign({className:x.loadingSubtitle},{children:"This may take a few minutes"}))]}),n("button",Object.assign({type:"button",onClick:()=>null==it?void 0:it(),className:x.viewStatusButton},{children:"View Status"}))]}):rt?Object.assign({className:x.noDataContainer,style:null==Ct?void 0:Ct.container},{children:[n("img",{src:B,alt:"No data available",className:x.noDataIllustration,style:null==Ct?void 0:Ct.illustration}),n("h3",Object.assign({className:x.noDataTitle,style:null==Ct?void 0:Ct.title},{children:"No Data Available for This Section"})),n("p",Object.assign({className:x.noDataSubtitle,style:null==Ct?void 0:Ct.subtitle},{children:"We couldn't find data for this section yet. Upload the required document from the Documents tab to generate content."}))]}):Object.assign({className:x.contentInner,style:null==gt?void 0:gt.contentInner},{children:[t("div",Object.assign({className:x.descriptionSection,style:null==gt?void 0:gt.descriptionSection},{children:[n("div",{className:x.justifyBetween,style:null==gt?void 0:gt.justifyBetween}),Ut.userStory?n(_,{ref:tn,minHeight:"100%",height:"100%",type:"string",value:P(U(K.value)||""),handleUpdateState:(e,t)=>{const n=R(A(t));xt(e=>Object.assign(Object.assign({},e),{value:n||""}))},doNotShowBorderInViewMode:!1,onBlur:()=>{},mode:Ut.userStory?"edit":"readOnly",onSaveUnsavedChanges:()=>e(void 0,void 0,void 0,function*(){yield gn(),$t(!1)}),onDiscardUnsavedChanges:()=>{xt(Object.assign(Object.assign({},structuredClone(K)),{value:U(K.value)||""})),At(e=>Object.assign(Object.assign({},e),{userStory:!1})),$t(!1)},isSavingUnsavedChanges:Kt}):jt?n(H,{styles:St,fields:Nt,readonly:!Rt,isSaving:Et,value:null!==(Ze=null!=_t?_t:It)&&void 0!==Ze?Ze:{},onChange:Lt,onSave:()=>e(void 0,void 0,void 0,function*(){var e;_t&&(yield null===(e=null==vt?void 0:vt.onSave)||void 0===e?void 0:e.call(vt,K,_t),Lt(null),Mt(!1))}),onCancel:()=>{Lt(null),Mt(!1)}}):t(i,{children:[n(L,{showUserStoryDiff:le,isParent:""===ee,message:U(K.value)||"",artifactId:K.artifactId,customStyles:ht,isDisplayHighlightControl:de,contextVariant:ye,showConfidenceScore:fe,CDNeededInChip:Te,blockId:xe}),(De||Be)&&t("div",Object.assign({className:x.actionButtonsContainer,style:null==Ot?void 0:Ot.container},{children:[Be&&!Ut.userStory&&t(i,{children:[n("button",Object.assign({type:"button",className:x.actionButton,style:null==Ot?void 0:Ot.button,disabled:Be.disabled||Be.isLoading,onClick:e=>{var t;e.stopPropagation(),null===(t=Be.onClick)||void 0===t||t.call(Be),At(e=>Object.assign(Object.assign({},e),{userStory:!0})),$t(!0)}},{children:Be.isLoading?t(i,{children:[n(g,{size:16,className:x.actionButtonSpinner,style:null==Ot?void 0:Ot.icon}),n("span",Object.assign({style:null==Ot?void 0:Ot.text},{children:null!==(Je=Be.label)&&void 0!==Je?Je:"Edit"}))]}):t(i,{children:[n(p,{size:16,style:null==Ot?void 0:Ot.icon}),n("span",Object.assign({style:null==Ot?void 0:Ot.text},{children:null!==(Ke=Be.label)&&void 0!==Ke?Ke:"Edit"}))]})})),De&&n("span",{className:x.actionButtonDivider})]}),De&&n("button",Object.assign({type:"button",className:x.actionButton,style:null==Ot?void 0:Ot.button,disabled:De.disabled||De.isLoading,onClick:e=>{var t;e.stopPropagation(),null===(t=De.onClick)||void 0===t||t.call(De)}},{children:De.isLoading?t(i,{children:[n(g,{size:16,className:x.actionButtonSpinner,style:null==Ot?void 0:Ot.icon}),n("span",Object.assign({style:null==Ot?void 0:Ot.text},{children:null!==(Xe=De.label)&&void 0!==Xe?Xe:"Approve"}))]}):t(i,{children:[n(f,{size:16,style:null==Ot?void 0:Ot.icon}),n("span",Object.assign({style:null==Ot?void 0:Ot.text},{children:null!==(et=De.label)&&void 0!==et?et:"Approve"}))]})}))]}))]})]})),null===(tt=Tt.sub_features)||void 0===tt?void 0:tt.map((e,t)=>{console.log("UserStoryCardWrapper: sub",e);const i=Y(ce,!1,e.artifactId);return n(J,{artifactId:O,isUserStoryCurrentlyUpdated:C,artifactTitleId:`${j}-${String.fromCharCode(65+t)}`,parentUserStory:K,parentIndex:`${ee}${ee&&"."}${te}`,currentIndex:`${t+1}`,doNotShowBorderInViewMode:!1,currentUserStory:e,onUserStoryChange:e=>((e,t)=>{const n=[...K.sub_features||[]];n[e]=t,X(Object.assign(Object.assign({},K),{sub_features:n}))})(t,e),enableDownload:!0,isDiffEditReviewMode:ie,showUserStoryDiff:le,updateUserStoryArtifact:ae,handleDownloadUserStory:oe,handleOpenSendDialog:se,isDisplayHighlightControl:de,elementDisplayConfig:ce,_resolvedConfig:i,actionItemsConfig:pe,onDelete:()=>(e=>{const t=(K.sub_features||[]).filter((t,n)=>n!==e),n=Object.assign(Object.assign({},K),{sub_features:t});xt(n),X(n)})(t),expandedSubFeatures:he,disableEditPlan:we,useMuiTooltip:Ee,blockNumber:e.blockNumber},e.artifactId)})]}))}))]}))},K=({artifactTitleIDs:e,expandedSubFeatures:l,isDiffEditReviewMode:o,showUserStoryDiff:s,updateUserStoryArtifact:a,isUserStoryCurrentlyUpdated:r,artifactId:d,handleOpenSendDialog:c,handleDownloadUserStory:u,selectedArtifactId:v,isDisplayHighlightControl:g,elementDisplayConfig:p,showWrapper:m,actionItemsConfig:y,contextVariant:h,showDisplayName:b,allowTitleEdit:S,showConfidenceScore:f,showBorderTop:j,defaultExpanded:I,showCompletionPanel:N=!1,completionPanelConfig:w,showAddSectionButton:E=!1,disableEditPlan:D=!1,useMuiTooltip:B=!1,approveButtonConfig:T,editButtonConfig:U,CDNeededInChip:A})=>{const{userStory:P,setUserStory:k,customStyles:R,searchQueryList:M,currentHighlightIndex:_,setCurrentHighlightIndex:L,segmentComponentConfig:z,sectionStatusConfig:V}=G(),W=null==R?void 0:R.userStoryCardStyles,H=0===_,$=_===M.length-1;return t("div",Object.assign({className:x.userStoryCardWrapper,style:g?Object.assign(Object.assign({},null==W?void 0:W.userStoryCardWrapper),{position:"relative"}):null==W?void 0:W.userStoryCardWrapper},{children:[g&&n(i,{children:M.length>0&&n("div",Object.assign({className:x.wrapper},{children:n("div",Object.assign({className:x.highlightNavigation},{children:t("div",Object.assign({className:x.navigationContainer},{children:[t("span",Object.assign({className:x.navCounter},{children:[_+1," of ",M.length]})),t("div",Object.assign({className:x.navButtons},{children:[n("button",Object.assign({onClick:()=>{_>0&&L(e=>e-1)},className:x.navButton,disabled:H},{children:n(C,{size:20,className:x.navIcon})})),n("button",Object.assign({onClick:()=>{_<M.length-1&&L(e=>e+1)},className:x.navButton,disabled:$},{children:n(O,{size:20,className:x.navIcon})}))]}))]}))}))}))}),P.map((t,i)=>{console.log("UserStoryCardWrapper: userstory",t);const C=Y(p,!0);return n(J,{isUserStoryCurrentlyUpdated:r,artifactId:d,artifactTitleId:e[i]||"",expandedSubFeatures:l,currentUserStory:t,onUserStoryChange:e=>{k(t=>(t[i]=e,[...t]))},parentIndex:"",currentIndex:`${i+1}`,doNotShowBorderInViewMode:!0,enableDownload:!0,isDiffEditReviewMode:o,showUserStoryDiff:s,updateUserStoryArtifact:a,handleOpenSendDialog:c,handleDownloadUserStory:u,selectedArtifactId:v,isDisplayHighlightControl:g,elementDisplayConfig:p,_resolvedConfig:C,showWrapper:m,defaultExpanded:I,actionItemsConfig:y,contextVariant:h,showDisplayName:b,allowTitleEdit:S,showConfidenceScore:f,showBorderTop:j,sectionStatusConfig:V,showCompletionPanel:N,completionPanelConfig:w,showAddSectionButton:E,disableEditPlan:D,useMuiTooltip:B,approveButtonConfig:T,CDNeededInChip:A,editButtonConfig:U},t.artifactId)})]}))};export{J as StoryCard,K as UserStoryCardWrapper,J as default,Q as replaceLearnedTagsWithInfo};
|
|
1
|
+
import{jsxs as e,jsx as l,Fragment as t}from"react/jsx-runtime";import{useState as n,useRef as o,useEffect as i}from"react";import{ChevronUp as a,ChevronDown as s,Users as r,ExternalLink as d,Download as u,Share2 as c,Copy as v,LoaderCircle as p,PencilIcon as m,Plus as y,Trash2 as h,X as g,Ellipsis as S,Hourglass as f,Check as C,ChevronUpIcon as I,ChevronDownIcon as b,Info as N,Bookmark as w}from"lucide-react";import E from"showdown";import{Tooltip as D,Menu as B,MenuItem as A}from"@mui/material";import T from"../../icons/Illustration.svg.js";import{v4 as x}from"uuid";import U from"./UserStoryCard.module.css.js";import{formatMarkdown as k,indentMarkdown as P}from"../../utils/helpers.js";import{replaceTitleSection as R,postprocessUserStoryAfterEdit as _}from"../../utils/user-story.utils.js";import M from"../../shared/AtomicButton.js";import L from"../RichTextEditor/RichTextEditor.js";import O from"../userstory-with-citation/UserStoryWithCitation.js";import{SectionStatus as z,useRequirementAI as V}from"../RequirementAIWrapper/RequirementAIWrapper.js";import{BigEnoughPanel as j}from"../story-screen/BigEnoughPanel.js";import{InlineTitleEditor as G}from"./TitleEditor/TitleEditor.js";import{updateRedlineDocument as W,getRedlineDocumentId as $,createRedlineDocument as H}from"../../../../service/redlineService.js";import F from"./ClinicalTrialSection.js";import{CompletionPanel as q}from"../story-screen/CompletionPanel.js";import Q from"../../icons/CDIcon.js";const Y={[z.WAITING]:"WAITING TO GENERATE",[z.IN_PROGRESS]:"IN PROGRESS",[z.GENERATED]:"GENERATED",[z.FAILED]:"FAILED",[z.GENERATE]:"GENERATE",[z.APPROVED]:"APPROVED"};function Z(e){const t=[],n=/<learned>(.*?)<\/learned>/g;let o,i=0,a=0;for(;null!==(o=n.exec(e));){const[,s]=o,r=o.index;r>i&&t.push(l("span",{children:e.slice(i,r)},"text-pre-"+a++)),t.push(l(D,{title:s,placement:"top",children:l(N,{size:16,className:"inline-block mx-1 text-blue-500 hover:text-blue-700 cursor"})},`tooltip-${x()}`)),i=n.lastIndex}return i<(null==e?void 0:e.length)&&t.push(l("span",{children:e.slice(i)},"text-post-"+a++)),t}function J(e,l,t){var n;if(!e)return{};if(l)return{...e.parentConfig};const o={...e.childConfig};return t&&(null===(n=e.subFeatureOverrides)||void 0===n?void 0:n[t])?{...o,...e.subFeatureOverrides[t]}:o}const K=({displayName:t})=>{var n;const{customStyles:o}=V(),i=null===(n=null==o?void 0:o.userStoryCardStyles)||void 0===n?void 0:n.showDisplayName;return e("div",{className:U.displayName,style:null==i?void 0:i.wrapper,children:[l(w,{className:U.displayNameIcon,style:null==i?void 0:i.displayNameIcon}),e("span",{style:null==i?void 0:i.label,children:[t,":"]})]})},X=({isUserStoryCurrentlyUpdated:I,artifactId:b,artifactTitleId:N,parentUserStory:w,currentUserStory:$,onUserStoryChange:H,parentIndex:ee,currentIndex:le,enableDownload:te,isDiffEditReviewMode:ne,showUserStoryDiff:oe,handleDownloadUserStory:ie,handleOpenSendDialog:ae,updateUserStoryArtifact:se,selectedArtifactId:re,isDisplayHighlightControl:de,elementDisplayConfig:ue,_resolvedConfig:ce,showWrapper:ve=!1,defaultExpanded:pe,actionItemsConfig:me,onDelete:ye,contextVariant:he,expandedSubFeatures:ge,showDisplayName:Se=!0,allowTitleEdit:fe=!0,showConfidenceScore:Ce=!0,showBorderTop:Ie=!0,sectionStatusConfig:be,showCompletionPanel:Ne=!1,completionPanelConfig:we,showAddSectionButton:Ee=!1,disableEditPlan:De=!1,useMuiTooltip:Be=!1,approveButtonConfig:Ae,editButtonConfig:Te,CDNeededInChip:xe,blockNumber:Ue,showAssignSection:ke=!1,disableAssignSection:Pe=!1,onAssignSectionClick:Re})=>{var _e,Me,Le,Oe,ze,Ve,je,Ge,We,$e,He,Fe,qe,Qe,Ye,Ze,Je,Ke,Xe,el,ll,tl,nl,ol;const{isLoadingSectionData:il=!1,onLoadSectionData:al,status:sl,onStatusClick:rl,completedCount:dl,totalCount:ul,isNoDataAvailable:cl=!1}=null!=be?be:{},{searchQueryList:vl,citations:pl,customStyles:ml,onEditBlocked:yl,redlineDcoumentId:hl,redlineConfig:gl,customSectionConfig:Sl,updateRedlineDataParent:fl,aiReasoning:Cl}=V(),Il=null==ml?void 0:ml.userStoryCardStyles,bl=null==Il?void 0:Il.customSectionEditButton,Nl=null==Il?void 0:Il.statusStyles,wl=null===(_e=null==ml?void 0:ml.userStoryCardStyles)||void 0===_e?void 0:_e.userStoryEditStyles,El=null===(Me=null==ml?void 0:ml.userStoryScreenStyles)||void 0===Me?void 0:Me.userStoryContentStyles,Dl=null==Il?void 0:Il.progressHeaderStyles,Bl=null==Il?void 0:Il.clinicalTrialSectionStyles,Al=null==Il?void 0:Il.CompletionStyles,Tl=null==Il?void 0:Il.noDataStyles,xl=null==Il?void 0:Il.approveButtonStyles,Ul=null!==(Oe=null===(Le=null==Sl?void 0:Sl.shouldRender)||void 0===Le?void 0:Le.call(Sl,$))&&void 0!==Oe&&Oe,kl=null===(ze=null==Sl?void 0:Sl.getValue)||void 0===ze?void 0:ze.call(Sl,$),Pl=null!==(je=null===(Ve=null==Sl?void 0:Sl.getFields)||void 0===Ve?void 0:Ve.call(Sl,$))&&void 0!==je?je:[],Rl=null!==(Ge=null==Sl?void 0:Sl.isEditDisabled)&&void 0!==Ge&&Ge,_l=null!==($e=null===(We=null==Sl?void 0:Sl.isSaving)||void 0===We?void 0:We.call(Sl,$))&&void 0!==$e&&$e,Ml=((e,l)=>e>=80?null==l?void 0:l.highCompletion:e>=50?null==l?void 0:l.mediumCompletion:null==l?void 0:l.lowCompletion)(null!==(He=$.completion_percentage)&&void 0!==He?He:0,Al),Ll={[z.WAITING]:null==Nl?void 0:Nl.waiting,[z.IN_PROGRESS]:null==Nl?void 0:Nl.inProgress,[z.GENERATED]:null==Nl?void 0:Nl.generated,[z.FAILED]:null==Nl?void 0:Nl.failed,[z.GENERATE]:null==Nl?void 0:Nl.generate,[z.APPROVED]:null==Nl?void 0:Nl.approved},[Ol,zl]=n({...structuredClone($),value:k($.value)||""}),[Vl,jl]=n({userStory:!!$.isDefaultEdit}),[Gl,Wl]=n(!1),[$l,Hl]=n(!1),[Fl,ql]=n(null),[Ql,Yl]=n(null),{userStory:Zl,customIcons:Jl}=V(),[Kl,Xl]=n(null!=pe?pe:""===ee||re===$.artifactId||!!$.isDefaultOpen),[et,lt]=n(!1),[tt,nt]=n(null),[ot,it]=n(null),[at,st]=n(!1),rt=o(null),dt=o(null),[ut,ct]=n(!1),[vt,pt]=n(!1),mt=o(null),[yt,ht]=n(!1),[gt,St]=n($.value);i(()=>{I&&Xl(I)},[I]),i(()=>{zl({...structuredClone($),value:k($.value)||""})},[$]),i(()=>{vl.length>0?Xl(!0):void 0===pe&&re&&Xl(re===$.artifactId)},[vl,re,$.artifactId]),i(()=>{ge&&ge.length>0&&Xl(ge.includes($.artifactId)||""===ee||re===$.artifactId||!!$.isDefaultOpen)},[ge]);const ft=()=>{nt(null)},Ct=()=>{it(null)},It=()=>{Kl&&Vl.userStory&&dt.current&&!dt.current.requestClose()||Xl(e=>!e)},bt=async()=>{var e,l;try{"userStory"==="userStory"&&(H(Ol),console.log("I am changing RTE editor values",Ol)),await(null===(e=null==Te?void 0:Te.onSaveEditedSection)||void 0===e?void 0:e.call(Te,Ol)),await se(pl,Zl,b,null===(l=mt.current)||void 0===l?void 0:l.signal)}finally{}};const Nt=null!=(null==$?void 0:$.big_enough)&&!Number.isNaN($.big_enough)&&!!(null==$?void 0:$.big_enough_decision_factors),wt=null!==(Fe=null==$?void 0:$.completion_percentage)&&void 0!==Fe?Fe:0,Et=!!(null==$?void 0:$.completion_decision_factors),Dt=""===ee,Bt=null!=ce?ce:J(ue,Dt),At=!ne&&!oe;i(()=>{if(!Ql)return;const e=setTimeout(()=>{const e=document.getElementById(`story-card-${Ql}`);null==e||e.scrollIntoView({behavior:"smooth",block:"start"})},100);return()=>clearTimeout(e)},[Ql]),i(()=>{$.isDefaultEdit&&jl(e=>({...e,userStory:!0}))},[$.isDefaultEdit]),console.log("block number in userstory card ",Ue),console.log("[TESTING-CURRENT-USER-STORY] \n",$,"\n[TESTING-USER-STORY] \n",Zl);return i(()=>St($.value),[$.value]),e("div",{className:U.card,"data-block-id":"user-story-card-wrapper-"+Ue,style:null==Il?void 0:Il.cardStyle,id:`story-card-${$.title}`,"data-expanded":Kl,children:[e("div",{className:U.titleSection,style:null==Il?void 0:Il.titleSection,children:[e("div",{className:U.titleRow,style:null==Il?void 0:Il.titleRow,onClick:It,children:[e("div",{className:U.titleLeft,style:null==Il?void 0:Il.titleLeft,onMouseEnter:()=>ct(!0),onMouseLeave:()=>ct(!1),children:[Se&&l(K,{displayName:N}),Gl&&At?l(G,{title:$.title,onSave:e=>(async(e,l)=>{var t;try{let n={...$};$.artifactId===l?n.title=e:n.sub_features=(null===(t=$.sub_features)||void 0===t?void 0:t.map(t=>t.artifactId===l?{...t,title:e}:t))||[],zl(n),H(n),Wl(!1)}catch(e){console.error("Failed to save title",e)}})(e,$.artifactId),onCancel:()=>{Wl(!1)},inputStyle:null==wl?void 0:wl.inlineTitleInput,confirmButtonStyle:null==wl?void 0:wl.inlineTitleConfirm,cancelButtonStyle:null==wl?void 0:wl.inlineTitleCancel},"inline-title-editor"):e("div",{className:U.storyTitleWrapper,children:[l(D,{title:Z($.title),arrow:!0,children:l("h2",{title:Be?void 0:$.title,className:U.storyTitle,style:null==Il?void 0:Il.storyTitle,children:Z($.title)},$.artifactId)}),Ne&&(Et?l(q,{customIcons:null==Jl?void 0:Jl.userStoryIcons,customStyles:null==Il?void 0:Il.aiReasoningCitaionStyles,currentUserStory:$,panelStyles:null==Il?void 0:Il.CompletionStyles,onToggleStateChange:pt,completionPanelConfig:we,children:e("div",{style:{display:"inline-flex",alignItems:"center",gap:"4px",...null==Al?void 0:Al.badge,...Ml},children:[e("span",{children:[wt,"% Completed"]}),l("span",{style:{display:"flex",alignItems:"center"},children:l(Q,{color:"currentColor"})}),l(vt?a:s,{size:14,style:null==Al?void 0:Al.chevronStyle})]})}):l("div",{style:{display:"inline-flex",alignItems:"center",gap:"4px",...null==Al?void 0:Al.badge,...Ml},children:e("span",{children:[wt,"% Completed"]})})),fe&&l("button",{type:"button",className:U.titleEditButton,style:null==wl?void 0:wl.titleEditButton,onClick:e=>{e.stopPropagation(),Wl(!0),Kl||Xl(!0)},"aria-label":"Edit title",title:"Edit title",children:l("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:l("path",{d:"M8.99998 14.9992H15.75M2.25 14.9992H3.50591C3.87279 14.9992 4.05624 14.9992 4.22887 14.9577C4.38192 14.921 4.52824 14.8604 4.66245 14.7782C4.81382 14.6854 4.94354 14.5557 5.20296 14.2962L14.625 4.87419C15.2463 4.25287 15.2463 3.24551 14.625 2.62419C14.0037 2.00287 12.9963 2.00287 12.375 2.62419L2.95295 12.0462C2.69352 12.3057 2.5638 12.4354 2.47104 12.5868C2.3888 12.721 2.32819 12.8673 2.29145 13.0203C2.25 13.193 2.25 13.3764 2.25 13.7433V14.9992Z",stroke:"#94A3B8","stroke-width":"1.54286","stroke-linecap":"round","stroke-linejoin":"round"})})})]})]}),(sl||void 0!==dl&&void 0!==ul)&&e("div",{className:U.statusContainer,children:[void 0!==dl&&void 0!==ul&&e("div",{className:U.completedBadge,children:["Completed: ",dl,"/",ul]}),sl&&l("button",{type:"button",onClick:e=>{e.stopPropagation(),null==rl||rl()},onMouseEnter:()=>ht(!0),onMouseLeave:()=>ht(!1),className:U.statusButton,style:{...null===(qe=Ll[sl])||void 0===qe?void 0:qe.default,...yt&&(null===(Qe=Ll[sl])||void 0===Qe?void 0:Qe.hover)},children:Y[sl]})]}),e("div",{className:U.titleActions,style:null==Il?void 0:Il.titleActions,onClick:e=>e.stopPropagation(),children:[(Bt.showProgressPercentage||Bt.showGapBox)&&ve&&e("div",{className:U.progressHeader,style:null==Dl?void 0:Dl.wrapper,children:[Bt.showProgressPercentage&&e("div",{className:U.progressPercentage,style:null==Dl?void 0:Dl.percentage,children:[null!==(Ze=null!==(Ye=null==$?void 0:$.confidenceScore)&&void 0!==Ye?Ye:null==Bt?void 0:Bt.confidenceValue)&&void 0!==Ze?Ze:"0","%"]}),Bt.showGapBox&&e("div",{className:U.gapBox,style:null==Dl?void 0:Dl.gapBox,children:[null!==(Ke=null!==(Je=null==$?void 0:$.gapValue)&&void 0!==Je?Je:null==Bt?void 0:Bt.gapBoxValue)&&void 0!==Ke?Ke:"2"," ","Gaps"]})]}),Nt&&l(j,{customIcons:null==Jl?void 0:Jl.userStoryIcons,customStyles:null==Il?void 0:Il.aiReasoningCitaionStyles,currentUserStory:$,panelStyles:null==Il?void 0:Il.BigEnoughStyles}),ke&&l("button",{type:"button",className:U.iconButton,style:null==Il?void 0:Il.iconButton,disabled:Pe,onClick:e=>{e.stopPropagation(),null==Re||Re($)},"aria-label":"Assign section users",title:"Assign section users",children:l(r,{size:16})}),!Vl.userStory&&e(t,{children:[!1!==(null==Bt?void 0:Bt.showShareButton)&&l("button",{className:U.iconButton,style:null==Il?void 0:Il.iconButton,onClick:e=>{nt(e.currentTarget)},children:l(d,{size:16})}),e(B,{id:"user-story-share-menu",anchorEl:tt,open:!!tt,onClose:()=>nt(null),style:null==Il?void 0:Il.userStoryShareMenu,children:[te&&l(A,{style:null==Il?void 0:Il.userStoryMenuItem,onClick:async()=>{lt(!0),ie&&(await Promise.all([ie("pdf"),ie("doc")]),lt(!1))},children:e("div",{ref:rt,className:U.menuItemContent,style:null==Il?void 0:Il.menuItemContent,children:[l(u,{size:16,color:null==Il?void 0:Il.menuIconColor}),l("p",{style:null==Il?void 0:Il.menuLabel,children:"Download"})]})}),l(A,{style:null==Il?void 0:Il.userStoryMenuItem,onClick:async()=>{let e=$;w&&(e={...$,value:`${R(null==w?void 0:w.value,$.title)} \n${$.value}`}),null==ae||ae(!0,[e],$.artifactId),ft()},children:e("div",{style:null==Il?void 0:Il.menuItemContent,className:U.menuItemContentPadded,children:[l(c,{size:16,color:null==Il?void 0:Il.menuIconColor}),l("p",{style:null==Il?void 0:Il.menuLabel,children:"Send"})]})}),l(A,{style:null==Il?void 0:Il.userStoryMenuItem,onClick:async()=>{const e=(new E.Converter).makeHtml(k($.value)||$.value),l=function(e){const l=(new E.Converter).makeHtml(e),t=document.createElement("div");return t.innerHTML=l,t.textContent||t.innerText||""}(k($.value)||$.value),t=new ClipboardItem({"text/plain":new Blob([l],{type:"text/plain"}),"text/html":new Blob([e],{type:"text/html"})});try{await navigator.clipboard.write([t]),console.log("Copied User Story")}catch(e){console.error("Failed to copy user story:",e)}finally{ft()}},children:e("div",{style:null==Il?void 0:Il.menuItemContent,className:U.menuItemContentPadded,children:[l(v,{size:16,color:null==Il?void 0:Il.menuIconColor}),l("p",{style:null==Il?void 0:Il.menuLabel,children:"Copy"})]})})]})]}),!at&&Vl.userStory&&Kl?l(M,{type:"outline",children:"Cancel",style:null==Il?void 0:Il.cancelButton,onClick:()=>{var e;null===(e=mt.current)||void 0===e||e.abort(),jl(e=>({...e,userStory:!1}))}}):l(t,{}),Vl.userStory&&Kl?l(M,{type:"fill",children:at?e("span",{className:U.savingSpinner,style:null==Il?void 0:Il.savingSpinner,children:[l(p,{className:U.spinAnimation,style:null==Il?void 0:Il.spinAnimation}),l("span",{children:"Saving..."})]}):"Save",isDisable:at,style:at?null==Il?void 0:Il.savingButton:null==Il?void 0:Il.saveButton,onClick:async()=>{st(!0),await bt();let e=await(async()=>{var e,l,t,n,o;let i=Ol.value;console.log("[V] valueToUpdate before",i),i=i.replace(/<invisible\s+id="([^"]+)"\s*><\/invisible>/gi,"\x3c!-- $1 --\x3e"),console.log("[V] valueToUpdate after",i);try{if(null==gl?void 0:gl.callUpdateDocument){const{updated_reqai:a}=await W({documentId:hl,sectionId:$.artifactId,baseApiUrl:null==gl?void 0:gl.baseApiUrl,updatedContent:i,userEmail:gl.userEmail,userName:gl.userName,redlineConfigId:null!==(e=gl.redlineConfigId)&&void 0!==e?e:""},null!==(l=null==gl?void 0:gl.token)&&void 0!==l?l:"");i=null===(o=null===(n=null===(t=null==a?void 0:a.artifactData)||void 0===t?void 0:t.userStorySnapshot)||void 0===n?void 0:n[0])||void 0===o?void 0:o.value,await(null==fl?void 0:fl(a))}}catch(e){console.error("failed to update redline document",e),i=gt}return i=i.replace(/<!--\s*([0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})\s*-->/gi,'<invisible id="$1"></invisible>'),i})();const l={...Ol,value:e};H({...l,isDefaultEdit:!1}),St(l.value),jl(e=>({...e,userStory:!1})),st(!1)}}):!ne&&!oe&&!De&&Kl&&!1!==(null==Bt?void 0:Bt.showEditButton)&&l("button",{className:U.iconButton,style:null==Il?void 0:Il.editButton,onClick:()=>jl(e=>({...e,userStory:!0})),children:l(m,{color:null==Il?void 0:Il.pencilIconColor,size:16})}),Ee&&Dt&&Kl&&!ne&&!oe&&!1!==(null==Bt?void 0:Bt.showEditButton)&&e("button",{type:"button",className:U.addSectionButton,style:null==wl?void 0:wl.addSectionButton,onClick:e=>{var l,t,n;e.stopPropagation();const o=(null!==(t=null===(l=$.sub_features)||void 0===l?void 0:l.length)&&void 0!==t?t:0)+1,i={artifactId:x(),title:`New Section ${o}`,value:"Please add details for this section.",section:"subfeature",isDefaultOpen:!0},a={...$,sub_features:[...null!==(n=$.sub_features)&&void 0!==n?n:[],i]};zl(a),H(a),Xl(!0),Yl(i.title)},"aria-label":"Add section",title:"Add section",children:[l(y,{size:14}),l("span",{className:U.addSectionLabel,children:"Add Section"})]}),!Dt&&!ne&&!De&&!oe&&l("button",{type:"button",onClick:e=>{e.stopPropagation(),null==ye||ye()},className:U.iconButton,style:null==wl?void 0:wl.deleteButton,"aria-label":"Delete section",title:"Delete section",children:l(h,{size:16})}),Ul&&l("button",{type:"button",className:U.iconButton,style:null==bl?void 0:bl.button,disabled:Rl,onClick:e=>{if(e.stopPropagation(),$l)return ql(null),void Hl(!1);ql(structuredClone(null!=kl?kl:{})),Xl(!0),Hl(!0)},children:$l?l(g,{size:16,color:null==Il?void 0:Il.pencilIconColor,style:null==bl?void 0:bl.cancelIcon}):l(m,{size:16,color:null==Il?void 0:Il.pencilIconColor,style:null==bl?void 0:bl.editIcon})}),(null==Bt?void 0:Bt.actionItemsButton)&&e(t,{children:[l("span",{className:U.actionItemBtn,style:null==Il?void 0:Il.actionItemBtn,onClick:e=>{e.stopPropagation(),it(e.currentTarget)},children:l(S,{})}),l(B,{id:"user-story-action-menu",anchorEl:ot,open:!!ot,onClose:Ct,style:null==Il?void 0:Il.userStoryShareMenu,children:null==me?void 0:me.items.map((t,n)=>l(A,{style:null==Il?void 0:Il.userStoryMenuItem,onClick:()=>{t.onclick($),Ct()},children:e("div",{className:U.menuItemContent,style:{...null==Il?void 0:Il.menuItemContent,...!t.isActive&&{cursor:"not-allowed",opacity:.5}},children:[l("span",{className:U.menuItemIcon,style:null==Il?void 0:Il.menuItemIcon,children:t.icon}),l("p",{style:null==Il?void 0:Il.menuLabel,children:t.name}),l("span",{className:U.menuItemRight,style:null==Il?void 0:Il.menuItemRight})]})},`action-item-${n}-${t.name}`))})]}),l("button",{type:"button",onClick:e=>{e.stopPropagation(),It()},style:null==Il?void 0:Il.chevronButton,className:U.chevronButton,children:l(Kl?a:s,{className:U.chevronIcon,color:null==Il?void 0:Il.chevronIconColor})})]})]}),l("div",{className:U.divider,style:null==Il?void 0:Il.dividerStyle})]}),Kl&&l("div",{className:U.cardContent,style:{...null==Il?void 0:Il.cardContentStyle,borderTop:Ie?"1px solid #E5E5E5":"none"},children:e("div",il?{className:U.loadingContainer,children:[l("div",{className:U.loadingIconWrapper,children:l(f,{size:28,color:"#5B3DF5",className:U.spinAnimation})}),e("div",{children:[l("h3",{className:U.loadingTitle,children:"Section generation in progress.."}),l("p",{className:U.loadingSubtitle,children:"This may take a few minutes"})]}),l("button",{type:"button",onClick:()=>null==al?void 0:al(),className:U.viewStatusButton,children:"View Status"})]}:cl?{className:U.noDataContainer,style:null==Tl?void 0:Tl.container,children:[l("img",{src:T,alt:"No data available",className:U.noDataIllustration,style:null==Tl?void 0:Tl.illustration}),l("h3",{className:U.noDataTitle,style:null==Tl?void 0:Tl.title,children:"No Data Available for This Section"}),l("p",{className:U.noDataSubtitle,style:null==Tl?void 0:Tl.subtitle,children:"We couldn't find data for this section yet. Upload the required document from the Documents tab to generate content."})]}:{className:U.contentInner,style:null==Il?void 0:Il.contentInner,children:[e("div",{className:U.descriptionSection,style:null==Il?void 0:Il.descriptionSection,children:[l("div",{className:U.justifyBetween,style:null==Il?void 0:Il.justifyBetween}),Vl.userStory?l(L,{ref:dt,minHeight:"100%",height:"100%",type:"string",value:k(gt)||"",handleUpdateState:(e,l)=>{const t=_(P(l));zl(e=>({...e,value:t||""}))},doNotShowBorderInViewMode:!1,onBlur:()=>{},mode:Vl.userStory?"edit":"readOnly",onEditBlocked:yl,onSaveUnsavedChanges:async()=>{await bt(),Xl(!1)},onDiscardUnsavedChanges:()=>{zl({...structuredClone($),value:k($.value)||""}),jl(e=>({...e,userStory:!1})),Xl(!1)},isSavingUnsavedChanges:at}):Ul?l(F,{styles:Bl,fields:Pl,readonly:!$l,isSaving:_l,value:null!==(Xe=null!=Fl?Fl:kl)&&void 0!==Xe?Xe:{},onChange:ql,onSave:async()=>{var e;Fl&&(await(null===(e=null==Sl?void 0:Sl.onSave)||void 0===e?void 0:e.call(Sl,$,Fl)),ql(null),Hl(!1))},onCancel:()=>{ql(null),Hl(!1)}}):e(t,{children:[l(O,{showUserStoryDiff:oe,isParent:""===ee,message:k($.value)||"",artifactId:$.artifactId,customStyles:El,isDisplayHighlightControl:de,contextVariant:he,showConfidenceScore:Ce,CDNeededInChip:xe,blockId:Ue}),(Ae||Te)&&e("div",{className:U.actionButtonsContainer,style:null==xl?void 0:xl.container,children:[Te&&!Vl.userStory&&e(t,{children:[l("button",{type:"button",className:U.actionButton,style:null==xl?void 0:xl.button,disabled:Te.disabled||Te.isLoading,onClick:e=>{var l;e.stopPropagation(),null===(l=Te.onClick)||void 0===l||l.call(Te),jl(e=>({...e,userStory:!0})),Xl(!0)},children:Te.isLoading?e(t,{children:[l(p,{size:16,className:U.actionButtonSpinner,style:null==xl?void 0:xl.icon}),l("span",{style:null==xl?void 0:xl.text,children:null!==(el=Te.label)&&void 0!==el?el:"Edit"})]}):e(t,{children:[l(m,{size:16,style:null==xl?void 0:xl.icon}),l("span",{style:null==xl?void 0:xl.text,children:null!==(ll=Te.label)&&void 0!==ll?ll:"Edit"})]})}),Ae&&l("span",{className:U.actionButtonDivider})]}),Ae&&l("button",{type:"button",className:U.actionButton,style:null==xl?void 0:xl.button,disabled:Ae.disabled||Ae.isLoading,onClick:e=>{var l;e.stopPropagation(),null===(l=Ae.onClick)||void 0===l||l.call(Ae)},children:Ae.isLoading?e(t,{children:[l(p,{size:16,className:U.actionButtonSpinner,style:null==xl?void 0:xl.icon}),l("span",{style:null==xl?void 0:xl.text,children:null!==(tl=Ae.label)&&void 0!==tl?tl:"Approve"})]}):e(t,{children:[l(C,{size:16,style:null==xl?void 0:xl.icon}),l("span",{style:null==xl?void 0:xl.text,children:null!==(nl=Ae.label)&&void 0!==nl?nl:"Approve"})]})})]})]})]}),null===(ol=Ol.sub_features)||void 0===ol?void 0:ol.map((e,t)=>{console.log("UserStoryCardWrapper: sub",e);const n=J(ue,!1,e.artifactId);return l(X,{artifactId:b,isUserStoryCurrentlyUpdated:I,artifactTitleId:`${N}-${String.fromCharCode(65+t)}`,parentUserStory:$,parentIndex:`${ee}${ee&&"."}${le}`,currentIndex:`${t+1}`,doNotShowBorderInViewMode:!1,currentUserStory:e,onUserStoryChange:e=>((e,l)=>{const t=[...$.sub_features||[]];t[e]=l,H({...$,sub_features:t})})(t,e),enableDownload:!0,isDiffEditReviewMode:ne,showUserStoryDiff:oe,updateUserStoryArtifact:se,handleDownloadUserStory:ie,handleOpenSendDialog:ae,isDisplayHighlightControl:de,elementDisplayConfig:ue,_resolvedConfig:n,actionItemsConfig:me,onDelete:()=>(e=>{const l=($.sub_features||[]).filter((l,t)=>t!==e),t={...$,sub_features:l};zl(t),H(t)})(t),expandedSubFeatures:ge,disableEditPlan:De,useMuiTooltip:Be,blockNumber:e.blockNumber,showAssignSection:ke,onAssignSectionClick:Re},e.artifactId)})]})})]})},ee=({artifactTitleIDs:n,expandedSubFeatures:o,isDiffEditReviewMode:a,showUserStoryDiff:s,updateUserStoryArtifact:r,isUserStoryCurrentlyUpdated:d,artifactId:u,handleOpenSendDialog:c,handleDownloadUserStory:v,selectedArtifactId:p,isDisplayHighlightControl:m,elementDisplayConfig:y,showWrapper:h,actionItemsConfig:g,contextVariant:S,showDisplayName:f,allowTitleEdit:C,showConfidenceScore:N,showBorderTop:w,defaultExpanded:E,showCompletionPanel:D=!1,completionPanelConfig:B,showAddSectionButton:A=!1,disableEditPlan:T=!1,useMuiTooltip:x=!1,approveButtonConfig:k,editButtonConfig:P,CDNeededInChip:R,setRedlineDocumentIdParent:_,showAssignSection:M,onAssignSectionClick:L,disableAssignSection:O})=>{const{userStory:z,setUserStory:j,customStyles:G,searchQueryList:W,currentHighlightIndex:F,setCurrentHighlightIndex:q,segmentComponentConfig:Q,sectionStatusConfig:Y,redlineConfig:Z,setRedlineDocumentId:K}=V(),ee=null==G?void 0:G.userStoryCardStyles,le=0===F,te=F===W.length-1;return i(()=>{if(!(null==Z?void 0:Z.callCreateDocumentOnInit))return;(async()=>{var e;const{redline_document_id:l}=await $({baseApiUrl:Z.documentBaseApiUrl||"",comparisonId:Z.documentComparisonId||""});if(l)K(l);else{const{document_id:l}=await H({baseApiUrl:Z.baseApiUrl,changelogConfigId:Z.changelogConfigId,comparisonId:Z.documentComparisonId,artifactId:Z.artifactId,inputData:Z.inputData,redlineConfigId:Z.redlineConfigId,userEmail:Z.userEmail,userName:Z.userName},null!==(e=null==Z?void 0:Z.token)&&void 0!==e?e:"");l&&(K(l),null==_||_(l))}})()},[]),e("div",{className:U.userStoryCardWrapper,style:m?{...null==ee?void 0:ee.userStoryCardWrapper,position:"relative"}:null==ee?void 0:ee.userStoryCardWrapper,children:[m&&l(t,{children:W.length>0&&l("div",{className:U.wrapper,children:l("div",{className:U.highlightNavigation,children:e("div",{className:U.navigationContainer,children:[e("span",{className:U.navCounter,children:[F+1," of ",W.length]}),e("div",{className:U.navButtons,children:[l("button",{onClick:()=>{F>0&&q(e=>e-1)},className:U.navButton,disabled:le,children:l(I,{size:20,className:U.navIcon})}),l("button",{onClick:()=>{F<W.length-1&&q(e=>e+1)},className:U.navButton,disabled:te,children:l(b,{size:20,className:U.navIcon})})]})]})})})}),z.map((e,t)=>{console.log("UserStoryCardWrapper: userstory",e);const i=J(y,!0);return l(X,{isUserStoryCurrentlyUpdated:d,artifactId:u,artifactTitleId:n[t]||"",expandedSubFeatures:o,currentUserStory:e,onUserStoryChange:e=>{j(l=>(l[t]=e,[...l]))},parentIndex:"",currentIndex:`${t+1}`,doNotShowBorderInViewMode:!0,enableDownload:!0,isDiffEditReviewMode:a,showUserStoryDiff:s,updateUserStoryArtifact:r,handleOpenSendDialog:c,handleDownloadUserStory:v,selectedArtifactId:p,isDisplayHighlightControl:m,elementDisplayConfig:y,_resolvedConfig:i,showWrapper:h,defaultExpanded:E,actionItemsConfig:g,contextVariant:S,showDisplayName:f,allowTitleEdit:C,showConfidenceScore:N,showBorderTop:w,sectionStatusConfig:Y,showCompletionPanel:D,completionPanelConfig:B,showAddSectionButton:A,disableEditPlan:T,useMuiTooltip:x,approveButtonConfig:k,CDNeededInChip:R,editButtonConfig:P,showAssignSection:M,disableAssignSection:O,onAssignSectionClick:L},e.artifactId)})]})};export{X as StoryCard,ee as UserStoryCardWrapper,X as default,Z as replaceLearnedTagsWithInfo};
|
|
2
2
|
//# sourceMappingURL=UserStoryCard.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as e}from"react/jsx-runtime";const
|
|
1
|
+
import{jsx as e}from"react/jsx-runtime";const o=()=>e("svg",{width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"#475467",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:e("path",{d:"M8 3H5a2 2 0 0 0-2 2v3m18 0V5a2 2 0 0 0-2-2h-3m0 18h3a2 2 0 0 0 2-2v-3M3 16v3a2 2 0 0 0 2 2h3"})}),t=()=>e("svg",{width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"#475467",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:e("path",{d:"M8 3v3a2 2 0 0 1-2 2H3m18 0h-3a2 2 0 0 1-2-2V3m0 18v-3a2 2 0 0 1 2-2h3M3 16h3a2 2 0 0 1 2 2v3"})});export{t as DefaultFullScreenCloseIcon,o as DefaultFullScreenIcon};
|
|
2
2
|
//# sourceMappingURL=PdfViewerIcons.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsxs as e,jsx as
|
|
1
|
+
import{jsxs as e,jsx as l,Fragment as n}from"react/jsx-runtime";import{ChevronUp as i,ChevronDown as t,ExternalLink as a}from"lucide-react";import{useState as r}from"react";import s from"./AiReasonAccoridon.module.css.js";function o({icon:o,title:d,content:c,subTitle:m,scenario:p,className:u="",customStyles:h,alwaysOpen:v=!1,defaultOpen:y=!0,isSegmentExplanation:B=!1,handleViewExample:N,handleViewGlossary:x,isUpdatedSegment:$}){const[f,k]=r(y);return e("div",{className:`${"riskSideBar"!==p&&s.wrapperBorder} ${s.wrapper} ${u}`,style:null==h?void 0:h.wrapper,children:[e("div",{className:`${s.header} ${"riskSideBar"===p?s.headerPaddingRisk:s.headerPadding}`,style:null==h?void 0:h.header,onClick:()=>{v||k(!f)},children:[e("div",{className:s.headerLeft,style:null==h?void 0:h.iconWrapper,children:[o,e("div",{className:s.titleBlock,children:[l("h1",{className:s.title,style:null==h?void 0:h.title,children:d}),l("p",{className:s.subTitle,style:null==h?void 0:h.subTitle,children:m})]})]}),"riskSideBar"!==p&&!v&&l("div",{className:s.chevronWrapper,style:null==h?void 0:h.chevronWrapper,children:l(f?i:t,{className:s.chevronIcon})})]}),f&&e("div",{className:`${"riskSideBar"!==p&&s.content} ${s.contentBase}`,style:{...null==h?void 0:h.contentContainerWrapper},children:[l("div",{style:null==h?void 0:h.contentWrapper,children:c}),(N||x)&&B&&e("div",{className:`${s.segmentExplanationButtonContainer} flex-row`,style:{...null==h?void 0:h.segmentExplanationButtonContainer},children:[N&&l("button",{className:`${s.segmentButton}`,onClick:()=>null==N?void 0:N(),style:{...null==h?void 0:h.explanationButton},children:"Show Example"}),x&&l("button",{className:`${s.segmentButton}`,onClick:()=>null==x?void 0:x(),style:{...null==h?void 0:h.explanationButton},children:!$&&e(n,{children:["View in Glossary ",l(a,{size:14})]})})]})]})]})}export{o as default};
|
|
2
2
|
//# sourceMappingURL=AIReasonAccordion.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__rest as i}from"tslib";import{jsx as t,Fragment as o,jsxs as n}from"react/jsx-runtime";import{useRef as e,useMemo as a,Suspense as l}from"react";import c from"react-markdown";import d from"rehype-raw";import{ChevronDown as s,ChevronUp as r,Maximize2 as u,X as m,Info as v}from"lucide-react";import{Tooltip as p}from"@mui/material";import g from"./AiReasonMarkdownWrapper.module.css.js";import h from"../../shared/ExpandableOl.js";import _ from"../citations/web-citation/WebCitationWithImageRenderer.js";import b from"../citations/web-citation/WebCitationRenderer.js";import f from"../citations/image-citation/ImageCitationRenderer.js";import C from"../citations/file-citation/FileCitationRender.js";import{useRequirementAI as j}from"../RequirementAIWrapper/RequirementAIWrapper.js";import y from"../citations/stormee-citation/StormeeCitationRenderer.js";import O from"../citations/audio-citation/WaveformCitationRenderer.js";import I from"../citations/appmod-citation/AppmodCitationRenderer.js";import k from"../citations/rca-citation/RCACitationRenderer.js";import S from"../citations/readfile-citation/ReadFileCitationRenderer.js";import w from"../citations/chat-citation/ChatCitationRenderer.js";import{NonWebReasoningComponent as M}from"@e-llm-studio/citation";import N from"../citations/big-enough/BigEnoughCitationRenderer.js";import R from"./ScannedCitationRenderer.js";import F from"../citations/gpt-web-citation/GptWebCitationRenderer.js";const $=["appmode_citation","appmode_citations","appmod_citation","appmod_citations","image_citation","image_citations","audio_citation","audio_citations","document_citation","document_citations","rca_citation","rca_citations","web_citation","web_citations","code_generated","chat_citation","readfile_citation","readfile_citations","gpt_citation","gpt_citations","big_enough_block","scanned_doc_citation","scanned_doc_citations"],x=(i,t,o)=>{const n=Number.isFinite(t)&&Number.isFinite(o);return[...i.map((i,e)=>{const a=e>=t&&e<=o;return Object.assign(Object.assign({},i),{highlighted_text:n?a?i.message:"":i.highlighted_text})})]},W=({label:W,message:L,isExpandableOrderedListEnabled:P,customStyles:T,citationStyles:A,customIcons:E,onSelectProceed:D,isDisableProceedButton:G,big_enough_block:H})=>{const q=e(null),{citations:z,citationConfig:B,chatHistory:U,chatCitationConfigs:V,gptCitationConfigs:J}=j();console.log("Testing::Citations in Lib",z);const K=a(()=>({h1:o=>{var n=i(o,["node"]);return t("h1",Object.assign({className:g.h1,style:null==T?void 0:T.h1},{children:null==n?void 0:n.children}))},h2:o=>{var n=i(o,["node"]);return t("h2",Object.assign({className:g.h2,style:null==T?void 0:T.h2},{children:null==n?void 0:n.children}))},h3:o=>{var n=i(o,["node"]);return t("h2",Object.assign({className:g.h3,style:null==T?void 0:T.h3},{children:null==n?void 0:n.children}))},b:o=>(i(o,["node"]),t("b",{className:g.bold,style:null==T?void 0:T.b})),p:o=>{var n=i(o,["node"]);return t("p",Object.assign({},n,{className:g.paragraph,style:null==T?void 0:T.p},{children:null==n?void 0:n.children}))},ol:o=>{var n=i(o,["node"]);return P?t(h,Object.assign({label:W,customStyles:null==T?void 0:T.expandOlStyle,onProceed:D,isProceedDisabled:G,aiReasoningCitation:z,citationStyles:A,customIcons:E},{children:null==n?void 0:n.children})):t("ol",Object.assign({className:g.orderedList,style:null==T?void 0:T.ol},{children:null==n?void 0:n.children}))},ul:o=>{var n=i(o,["node"]);return t("ul",Object.assign({className:g.unorderedList},{children:null==n?void 0:n.children}))},a:e=>{var a,c,d,v,h,j,W,P,D,G,q,K,Q,X,Y,Z,ii,ti,oi,ni,ei,ai,li,ci,di,si,ri,ui,mi,{inline:vi,children:pi,node:gi}=e,hi=i(e,["inline","children","node"]);const _i="true"===(null==hi?void 0:hi.table),bi=`${null==hi?void 0:hi.href}`,fi=null===(a=bi.split("$"))||void 0===a?void 0:a[0],Ci=null===(c=bi.split("$"))||void 0===c?void 0:c[1],ji=("appmode_citation"===fi||"appmode_citations"===fi?(null==z?void 0:z.appmod_citations)||[]:"image_citation"===fi||"image_citations"===fi?(null==z?void 0:z.image_citations)||[]:"audio_citation"===fi||"audio_citations"===fi?(null==z?void 0:z.audio_citations)||[]:"document_citation"===fi||"document_citations"===fi?(null==z?void 0:z.file_citations)||[]:"rca_citation"===fi||"rca_citations"===fi?(null==z?void 0:z.rca_citations)||[]:"web_citation"===fi||"web_citations"===fi?(null==z?void 0:z.web_citations)||[]:"code_generated"===fi?(null==z?void 0:z.code_generated)||[]:"readfile_citation"===fi||"readfile_citations"===fi?(null==z?void 0:z.readfile_citations)||[]:"gpt_citation"===fi||"gpt_citations"===fi?(null==z?void 0:z.gpt_citations)||[]:"scanned_doc_citation"===fi||"scanned_doc_citations"===fi?(null==z?void 0:z.scanned_doc_citations)||[]:"big_enough_block"===fi&&H||[]).find(i=>i.citation_number===decodeURIComponent(Ci));console.log("TESTING::citation",ji);const yi=$.includes(fi);if("big_enough_block"===fi&&ji)return console.log("Rendering big enough block with citation:",A),t(N,{title:pi,citation:ji,customStyles:null==A?void 0:A.bigEnoughCitation,customIcons:E});if("chat_citation"===fi){if(!U||0===U.length)return null;let i=0,o=U.length-1;if("all"!==Ci){const[t,n]=Ci.split("-").map(Number);i=Number.isFinite(t)?t:0,o=Number.isFinite(n)?n:i,i=i>0?i-1:i,o=o<U.length-1?o+1:o}return t(w,{customIcon:null==E?void 0:E.chatCitationIcon,title:pi,chatHistory:x(U,i,o),isTable:_i,chatCitationProps:null==V?void 0:V.chatCitationProps,onCitationClick:null==V?void 0:V.handleCitationClicked,customStyles:null==A?void 0:A.chatCitation,openInFullscreenOnClick:null==V?void 0:V.openInFullscreenOnClick})}if(("gpt_citation"===fi||"gpt_citations"===fi)&&ji)return(null===(d=null==ji?void 0:ji.customMetadata)||void 0===d?void 0:d.value)?t(F,{title:pi,citation:ji,customStyles:null==A?void 0:A.webCitation,customIcons:E,content:L}):t(M,Object.assign({item:{text:"",dataSource:null===(h=null===(v=ji.customMetadata)||void 0===v?void 0:v.data_sources)||void 0===h?void 0:h[0],trainingDataTitle:null===(W=null===(j=ji.customMetadata)||void 0===j?void 0:j.training_data_title)||void 0===W?void 0:W[0],paraphrase:null===(D=null===(P=ji.customMetadata)||void 0===P?void 0:P.paraphrase)||void 0===D?void 0:D[0]},headerTitle:(null==J?void 0:J.title)||"GPT - Gemini 2.5 Flash",iconsConfig:{ChevronDownIcon:s,ChevronUpIcon:r,MaximizeIcon:u,CloseIcon:m}},null==J?void 0:J.gptCitationProps));if("image_citation"===fi&&!ji)return null;if("web_citation"===(null===(G=null==ji?void 0:ji.customMetadata)||void 0===G?void 0:G.type))return(null===(q=ji.customMetadata)||void 0===q?void 0:q.screenshot_url)?t(_,{title:pi,citation:ji,customStyles:null==A?void 0:A.webCitation,customIcons:E}):t(b,{label:pi,url:null===(K=ji.customMetadata)||void 0===K?void 0:K.link,customStyles:null==A?void 0:A.webCitation,customIcons:E});if("audio_transcript"===(null===(Q=null==ji?void 0:ji.customMetadata)||void 0===Q?void 0:Q.type))return"stormee"===(null==ji?void 0:ji.customMetadata.audio_citation_mode)?t(l,Object.assign({fallback:t(o,{})},{children:t(y,{title:`${pi}`,citation:ji,customStyles:null==A?void 0:A.stormeeCitation,customIcons:E})})):t(l,Object.assign({fallback:t(o,{})},{children:t(O,{title:`${pi}`,citation:ji,customStyles:null==A?void 0:A.waveformCitation,customIcons:E})}));if("scanned_doc_citations"===(null===(X=null==ji?void 0:ji.customMetadata)||void 0===X?void 0:X.type)||"scanned_doc_citation"===(null===(Y=null==ji?void 0:ji.customMetadata)||void 0===Y?void 0:Y.type))return t(l,Object.assign({fallback:t(o,{})},{children:t(R,{title:pi,citation:ji,customIcons:E,customStyles:null==A?void 0:A.scannedDocumentCitation,pdfViewHeaderAction:null==B?void 0:B.pdfViewHeaderAction})}));if("image_citation"===(null==ji?void 0:ji.customMetadata.type))return t(l,Object.assign({fallback:t(o,{})},{children:t(f,{title:`${pi}`,citation:ji,customIcons:E,customStyles:null==A?void 0:A.imageCitation})}));if("book_citation_doc"===(null===(Z=null==ji?void 0:ji.customMetadata)||void 0===Z?void 0:Z.type)||"book_citation_pdf"===(null==ji?void 0:ji.customMetadata.type))return t(l,Object.assign({fallback:t(o,{})},{children:t(C,{title:`${pi}`,citation:ji,customIcons:E,customStyles:null==A?void 0:A.fileCitation})}));if("app_mod_rag_question"===(null===(ii=null==ji?void 0:ji.customMetadata)||void 0===ii?void 0:ii.type))return t(l,Object.assign({fallback:t(o,{})},{children:t(I,{title:`${pi}`,citation:ji,customIcons:E,customStyles:null==A?void 0:A.appModCitation,codeLinkConfig:null===(ti=null==B?void 0:B.appMod)||void 0===ti?void 0:ti.codeLinkConfig,isLoading:null===(oi=null==B?void 0:B.appMod)||void 0===oi?void 0:oi.isLoading})}));if("rca_citation"===(null===(ni=null==ji?void 0:ji.customMetadata)||void 0===ni?void 0:ni.type))return t(l,Object.assign({fallback:t(o,{})},{children:t(k,{title:`${pi}`,citation:ji,customIcons:E,customStyles:null==A?void 0:A.rcaCitation})}));if("readfile_citation"===(null===(ei=null==ji?void 0:ji.customMetadata)||void 0===ei?void 0:ei.type))return t(l,Object.assign({fallback:t(o,{})},{children:t(S,{title:`${pi}`,citation:ji,customIcons:E,customStyles:null==A?void 0:A.readFileCitation,fileCallback:null===(ai=null==B?void 0:B.readFile)||void 0===ai?void 0:ai.fileCallback,editorConfig:null===(li=null==B?void 0:B.readFile)||void 0===li?void 0:li.editorConfig,customColors:null===(ci=null==B?void 0:B.readFile)||void 0===ci?void 0:ci.customColors})}));if(yi&&!ji){const i=null!==(di=null==E?void 0:E.citationLoadingIcon)&&void 0!==di?di:t("span",{className:g.citationSpinner,style:null===(si=null==A?void 0:A.loadingCitations)||void 0===si?void 0:si.citationSpinner});return t(p,Object.assign({title:null!==(ui=null===(ri=null==A?void 0:A.loadingCitations)||void 0===ri?void 0:ri.tooltipTitle)&&void 0!==ui?ui:`source ${fi.split("_")[0]} citations`,arrow:!0},{children:n("span",Object.assign({className:g.citationSpinnerWrapper,style:null===(mi=null==A?void 0:A.loadingCitations)||void 0===mi?void 0:mi.citationSpinnerWrapper},{children:[pi,i]}))}))}return t("span",Object.assign({},hi,{className:g.paragraph,style:null==T?void 0:T.p},{children:null==hi?void 0:hi.children}))},code:o=>{var{inline:n,children:e,className:a,node:l}=o;i(o,["inline","children","className","node"]);return/language-(\w+)/.exec(a||"")||(null==a?void 0:a.includes("language-"))?t("div",{children:t("code",Object.assign({className:g.blockCode},{children:e}))}):t("code",Object.assign({className:g.inlineCode,style:null==T?void 0:T.code},{children:e}))},learned:({children:i})=>t(o,{children:t(p,Object.assign({title:i,placement:"top"},{children:t(v,{size:16,className:g.learnedIcon})}))})}),[z,P,B,U,H]);return t("div",Object.assign({ref:q,className:"w-full"},{children:t(c,Object.assign({components:K,rehypePlugins:[d]},{children:L}))}))};export{W as AiReasonMarkdownWrapper,x as formatChatData};
|
|
1
|
+
import{jsx as i,Fragment as t,jsxs as o}from"react/jsx-runtime";import{useRef as n,useMemo as e,Suspense as l}from"react";import a from"react-markdown";import c from"rehype-raw";import{ChevronDown as d,ChevronUp as s,Maximize2 as r,X as u,Info as m}from"lucide-react";import{Tooltip as v}from"@mui/material";import p from"./AiReasonMarkdownWrapper.module.css.js";import _ from"../../shared/ExpandableOl.js";import h from"../citations/web-citation/WebCitationWithImageRenderer.js";import g from"../citations/web-citation/WebCitationRenderer.js";import f from"../citations/image-citation/ImageCitationRenderer.js";import C from"../citations/file-citation/FileCitationRender.js";import{useRequirementAI as b}from"../RequirementAIWrapper/RequirementAIWrapper.js";import y from"../citations/stormee-citation/StormeeCitationRenderer.js";import I from"../citations/audio-citation/WaveformCitationRenderer.js";import k from"../citations/appmod-citation/AppmodCitationRenderer.js";import S from"../citations/rca-citation/RCACitationRenderer.js";import w from"../citations/readfile-citation/ReadFileCitationRenderer.js";import M from"../citations/chat-citation/ChatCitationRenderer.js";import{NonWebReasoningComponent as N}from"@e-llm-studio/citation";import R from"../citations/big-enough/BigEnoughCitationRenderer.js";import j from"./ScannedCitationRenderer.js";import F from"../citations/gpt-web-citation/GptWebCitationRenderer.js";const $=["appmode_citation","appmode_citations","appmod_citation","appmod_citations","image_citation","image_citations","audio_citation","audio_citations","document_citation","document_citations","rca_citation","rca_citations","web_citation","web_citations","code_generated","chat_citation","readfile_citation","readfile_citations","gpt_citation","gpt_citations","big_enough_block","scanned_doc_citation","scanned_doc_citations"],x=(i,t,o)=>{const n=Number.isFinite(t)&&Number.isFinite(o);return[...i.map((i,e)=>{const l=e>=t&&e<=o;return{...i,highlighted_text:n?l?i.message:"":i.highlighted_text}})]},W=({label:W,message:L,isExpandableOrderedListEnabled:P,customStyles:T,citationStyles:A,customIcons:E,onSelectProceed:D,isDisableProceedButton:O,big_enough_block:G})=>{const H=n(null),{citations:q,citationConfig:z,chatHistory:B,chatCitationConfigs:U,gptCitationConfigs:V}=b();console.log("Testing::Citations in Lib",q);const J=e(()=>({h1:({node:t,...o})=>i("h1",{className:p.h1,style:null==T?void 0:T.h1,children:null==o?void 0:o.children}),h2:({node:t,...o})=>i("h2",{className:p.h2,style:null==T?void 0:T.h2,children:null==o?void 0:o.children}),h3:({node:t,...o})=>i("h2",{className:p.h3,style:null==T?void 0:T.h3,children:null==o?void 0:o.children}),b:({node:t,...o})=>i("b",{className:p.bold,style:null==T?void 0:T.b}),p:({node:t,...o})=>i("p",{...o,className:p.paragraph,style:null==T?void 0:T.p,children:null==o?void 0:o.children}),ol:({node:t,...o})=>P?i(_,{label:W,customStyles:null==T?void 0:T.expandOlStyle,onProceed:D,isProceedDisabled:O,aiReasoningCitation:q,citationStyles:A,customIcons:E,children:null==o?void 0:o.children}):i("ol",{className:p.orderedList,style:null==T?void 0:T.ol,children:null==o?void 0:o.children}),ul:({node:t,...o})=>i("ul",{className:p.unorderedList,children:null==o?void 0:o.children}),a:({inline:n,children:e,node:a,...c})=>{var m,_,b,W,P,D,O,H,J,K,Q,X,Y,Z,ii,ti,oi,ni,ei,li,ai,ci,di,si,ri,ui,mi,vi,pi;const _i="true"===(null==c?void 0:c.table),hi=`${null==c?void 0:c.href}`,gi=null===(m=hi.split("$"))||void 0===m?void 0:m[0],fi=null===(_=hi.split("$"))||void 0===_?void 0:_[1],Ci=("appmode_citation"===gi||"appmode_citations"===gi?(null==q?void 0:q.appmod_citations)||[]:"image_citation"===gi||"image_citations"===gi?(null==q?void 0:q.image_citations)||[]:"audio_citation"===gi||"audio_citations"===gi?(null==q?void 0:q.audio_citations)||[]:"document_citation"===gi||"document_citations"===gi?(null==q?void 0:q.file_citations)||[]:"rca_citation"===gi||"rca_citations"===gi?(null==q?void 0:q.rca_citations)||[]:"web_citation"===gi||"web_citations"===gi?(null==q?void 0:q.web_citations)||[]:"code_generated"===gi?(null==q?void 0:q.code_generated)||[]:"readfile_citation"===gi||"readfile_citations"===gi?(null==q?void 0:q.readfile_citations)||[]:"gpt_citation"===gi||"gpt_citations"===gi?(null==q?void 0:q.gpt_citations)||[]:"scanned_doc_citation"===gi||"scanned_doc_citations"===gi?(null==q?void 0:q.scanned_doc_citations)||[]:"big_enough_block"===gi&&G||[]).find(i=>i.citation_number===decodeURIComponent(fi));console.log("TESTING::citation",Ci);const bi=$.includes(gi);if("big_enough_block"===gi&&Ci)return console.log("Rendering big enough block with citation:",A),i(R,{title:e,citation:Ci,customStyles:null==A?void 0:A.bigEnoughCitation,customIcons:E});if("chat_citation"===gi){if(!B||0===B.length)return null;let t=0,o=B.length-1;if("all"!==fi){const[i,n]=fi.split("-").map(Number);t=Number.isFinite(i)?i:0,o=Number.isFinite(n)?n:t,t=t>0?t-1:t,o=o<B.length-1?o+1:o}return i(M,{customIcon:null==E?void 0:E.chatCitationIcon,title:e,chatHistory:x(B,t,o),isTable:_i,chatCitationProps:null==U?void 0:U.chatCitationProps,onCitationClick:null==U?void 0:U.handleCitationClicked,customStyles:null==A?void 0:A.chatCitation,openInFullscreenOnClick:null==U?void 0:U.openInFullscreenOnClick})}if(("gpt_citation"===gi||"gpt_citations"===gi)&&Ci)return(null===(b=null==Ci?void 0:Ci.customMetadata)||void 0===b?void 0:b.value)?i(F,{title:e,citation:Ci,customStyles:null==A?void 0:A.webCitation,customIcons:E,content:L}):i(N,{item:{text:"",dataSource:null===(P=null===(W=Ci.customMetadata)||void 0===W?void 0:W.data_sources)||void 0===P?void 0:P[0],trainingDataTitle:null===(O=null===(D=Ci.customMetadata)||void 0===D?void 0:D.training_data_title)||void 0===O?void 0:O[0],paraphrase:null===(J=null===(H=Ci.customMetadata)||void 0===H?void 0:H.paraphrase)||void 0===J?void 0:J[0]},headerTitle:(null==V?void 0:V.title)||"GPT - Gemini 2.5 Flash",iconsConfig:{ChevronDownIcon:d,ChevronUpIcon:s,MaximizeIcon:r,CloseIcon:u},...null==V?void 0:V.gptCitationProps});if("image_citation"===gi&&!Ci)return null;if("web_citation"===(null===(K=null==Ci?void 0:Ci.customMetadata)||void 0===K?void 0:K.type))return(null===(Q=Ci.customMetadata)||void 0===Q?void 0:Q.screenshot_url)?i(h,{title:e,citation:Ci,customStyles:null==A?void 0:A.webCitation,customIcons:E}):i(g,{label:e,url:null===(X=Ci.customMetadata)||void 0===X?void 0:X.link,customStyles:null==A?void 0:A.webCitation,customIcons:E});if("audio_transcript"===(null===(Y=null==Ci?void 0:Ci.customMetadata)||void 0===Y?void 0:Y.type))return"stormee"===(null==Ci?void 0:Ci.customMetadata.audio_citation_mode)?i(l,{fallback:i(t,{}),children:i(y,{title:`${e}`,citation:Ci,customStyles:null==A?void 0:A.stormeeCitation,customIcons:E})}):i(l,{fallback:i(t,{}),children:i(I,{title:`${e}`,citation:Ci,customStyles:null==A?void 0:A.waveformCitation,customIcons:E})});if("scanned_doc_citations"===(null===(Z=null==Ci?void 0:Ci.customMetadata)||void 0===Z?void 0:Z.type)||"scanned_doc_citation"===(null===(ii=null==Ci?void 0:Ci.customMetadata)||void 0===ii?void 0:ii.type))return i(l,{fallback:i(t,{}),children:i(j,{title:e,citation:Ci,customIcons:E,customStyles:null==A?void 0:A.scannedDocumentCitation,pdfViewHeaderAction:null==z?void 0:z.pdfViewHeaderAction})});if("image_citation"===(null==Ci?void 0:Ci.customMetadata.type))return i(l,{fallback:i(t,{}),children:i(f,{title:`${e}`,citation:Ci,customIcons:E,customStyles:null==A?void 0:A.imageCitation})});if("book_citation_doc"===(null===(ti=null==Ci?void 0:Ci.customMetadata)||void 0===ti?void 0:ti.type)||"book_citation_pdf"===(null==Ci?void 0:Ci.customMetadata.type))return i(l,{fallback:i(t,{}),children:i(C,{title:`${e}`,citation:Ci,customIcons:E,customStyles:null==A?void 0:A.fileCitation})});if("app_mod_rag_question"===(null===(oi=null==Ci?void 0:Ci.customMetadata)||void 0===oi?void 0:oi.type))return i(l,{fallback:i(t,{}),children:i(k,{title:`${e}`,citation:Ci,customIcons:E,customStyles:null==A?void 0:A.appModCitation,codeLinkConfig:null===(ni=null==z?void 0:z.appMod)||void 0===ni?void 0:ni.codeLinkConfig,isLoading:null===(ei=null==z?void 0:z.appMod)||void 0===ei?void 0:ei.isLoading})});if("rca_citation"===(null===(li=null==Ci?void 0:Ci.customMetadata)||void 0===li?void 0:li.type))return i(l,{fallback:i(t,{}),children:i(S,{title:`${e}`,citation:Ci,customIcons:E,customStyles:null==A?void 0:A.rcaCitation})});if("readfile_citation"===(null===(ai=null==Ci?void 0:Ci.customMetadata)||void 0===ai?void 0:ai.type))return i(l,{fallback:i(t,{}),children:i(w,{title:`${e}`,citation:Ci,customIcons:E,customStyles:null==A?void 0:A.readFileCitation,fileCallback:null===(ci=null==z?void 0:z.readFile)||void 0===ci?void 0:ci.fileCallback,editorConfig:null===(di=null==z?void 0:z.readFile)||void 0===di?void 0:di.editorConfig,customColors:null===(si=null==z?void 0:z.readFile)||void 0===si?void 0:si.customColors})});if(bi&&!Ci){const t=null!==(ri=null==E?void 0:E.citationLoadingIcon)&&void 0!==ri?ri:i("span",{className:p.citationSpinner,style:null===(ui=null==A?void 0:A.loadingCitations)||void 0===ui?void 0:ui.citationSpinner});return i(v,{title:null!==(vi=null===(mi=null==A?void 0:A.loadingCitations)||void 0===mi?void 0:mi.tooltipTitle)&&void 0!==vi?vi:`source ${gi.split("_")[0]} citations`,arrow:!0,children:o("span",{className:p.citationSpinnerWrapper,style:null===(pi=null==A?void 0:A.loadingCitations)||void 0===pi?void 0:pi.citationSpinnerWrapper,children:[e,t]})})}return i("span",{...c,className:p.paragraph,style:null==T?void 0:T.p,children:null==c?void 0:c.children})},code:({inline:t,children:o,className:n,node:e,...l})=>/language-(\w+)/.exec(n||"")||(null==n?void 0:n.includes("language-"))?i("div",{children:i("code",{className:p.blockCode,children:o})}):i("code",{className:p.inlineCode,style:null==T?void 0:T.code,children:o}),learned:({children:o})=>i(t,{children:i(v,{title:o,placement:"top",children:i(m,{size:16,className:p.learnedIcon})})})}),[q,P,z,B,G]);return i("div",{ref:H,className:"w-full",children:i(a,{components:J,rehypePlugins:[c],children:L})})};export{W as AiReasonMarkdownWrapper,x as formatChatData};
|
|
2
2
|
//# sourceMappingURL=AiReasonMarkdownWrapper.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as i}from"react/jsx-runtime";import n from"./AiReasoningCitationContent.js";import e from"../../icons/CognitiveDecision.js";import t from"../../../CitationRenderer/CitationRenderer.js";const o=()=>i("svg",
|
|
1
|
+
import{jsx as i}from"react/jsx-runtime";import n from"./AiReasoningCitationContent.js";import e from"../../icons/CognitiveDecision.js";import t from"../../../CitationRenderer/CitationRenderer.js";const o=()=>i("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"#4B5563",strokeWidth:"2.5",style:{verticalAlign:"bottom",marginLeft:"1px"},children:i("polyline",{points:"18 15 12 9 6 15"})}),l=()=>i("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"#4B5563",strokeWidth:"2.5",style:{verticalAlign:"bottom",marginLeft:"1px"},children:i("polyline",{points:"6 9 12 15 18 9"})}),r=75,s=({isSourceHasHighlight:r,aiReason:s,citationTitle:a="",customStyles:c,customIcons:d,onSelectProceed:p,isDisableProceedButton:f,inlineLabel:g,isInlineCitation:m})=>{const h=(s.relevance_score>=75?null==d?void 0:d.highConfidence:null==d?void 0:d.lowConfidence)||i(e,{});return i("span",{children:i(t,{inLineCitation:!0,citationId:`ai-reasoning-${s.id}`,citationTitle:m?g||"":a||"",citationIcon:m?null:h,defaultExpanded:(null==s?void 0:s.isOpen)||r||!1,citationComponent:i(n,{aiReason:s,customStyles:c,customIcons:d,onSelectProceed:p,isDisableProceedButton:f}),chevronDownComponent:m?null:i(l,{}),chevronUpComponent:m?null:i(o,{}),styles:{pillButton:{margin:"0px",padding:m?"0":"4px 8px",fontSize:"15px",color:"#526eff",cursor:"pointer",verticalAlign:"middle",whiteSpace:"nowrap",display:"inline-flex",alignItems:m?"center":"flex-end",background:"#ffffffff",fontWeight:"700",gap:"1.5px",border:"none",...null==c?void 0:c.aiReasoningPill},citationContent:{width:"100%",background:"transparent",minHeight:"10px",height:"fit-content"}}})})};export{r as SHOW_CONFIDENCE_SCORE_THRESHOLD_IN_AI_REASONING,s as default};
|
|
2
2
|
//# sourceMappingURL=AiReasoningCitation.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as i,jsxs as
|
|
1
|
+
import{jsx as i,jsxs as o,Fragment as n}from"react/jsx-runtime";import e from"../../icons/AiReasoningIcon.js";import l from"./AIReasonAccordion.js";import a from"../../icons/ReasoningBulbIcon.js";import{AiReasonMarkdownWrapper as t}from"./AiReasonMarkdownWrapper.js";import d from"../../icons/AiGapIcon.js";import{useState as s}from"react";import{ChevronUp as r,ChevronDown as v}from"lucide-react";import c from"./AiReasoningCitationContent.module.css.js";import{renderAIConfidenceDisplay as u}from"../../shared/CitationAIConfidenceDisplay.js";import{useRequirementAI as C}from"../RequirementAIWrapper/RequirementAIWrapper.js";const m=({label:m,aiReason:p,scenario:g,customStyles:h,customIcons:f,cognitiveDecisionHeaders:b,onSelectProceed:y,isDisableProceedButton:R,big_enough_block:w,isSegmentExplanation:S,handleViewExample:I,handleViewGlossary:N,isUpdatedSegment:A,footer:B})=>{var k,x,D,E,_,M,O,j,W,F,$,G,H,P,T,U,V,q,L,z,J,K;const{aiReasoningAccordionOpenStates:Q}=C(),X=(null==f?void 0:f.aireasonIcon)||i(e,{}),Y=(null==f?void 0:f.reasoningIcon)||i(a,{}),Z=(null==f?void 0:f.gapIcon)||i(d,{}),[ii,oi]=s(null!==(k=null==Q?void 0:Q.isBottomComponentDefaultOpen)&&void 0!==k&&k);return o("div",{className:`${c.container} ${"riskSideBar"===g?"":c.containerBordered}`,style:null===(x=null==h?void 0:h.aiReasoningContent)||void 0===x?void 0:x.container,children:[(null==p?void 0:p.explanation)&&i("div",{className:`${(null==p?void 0:p.explanation)&&"riskSideBar"!==g?"":c.explanationDivider}`,style:null===(D=null==h?void 0:h.aiReasoningContent)||void 0===D?void 0:D.explanationDivider,children:i(l,{icon:i(n,{}),title:"Explanation",subTitle:"",customStyles:null==h?void 0:h.aiReasoningAccordion,content:i(t,{label:m,message:p.explanation,isExpandableOrderedListEnabled:!0,customStyles:null==h?void 0:h.aiReasoningMarkdown,citationStyles:{webCitation:null==h?void 0:h.webCitation,stormeeCitation:null==h?void 0:h.stormeeCitation,waveformCitation:null==h?void 0:h.waveformCitation,imageCitation:null==h?void 0:h.imageCitation,fileCitation:null==h?void 0:h.fileCitation,appModCitation:null==h?void 0:h.appModCitation,rcaCitation:null==h?void 0:h.rcaCitation,readFileCitation:null==h?void 0:h.readFileCitation,loadingCitations:null==h?void 0:h.loadingCitations,chatCitation:null==h?void 0:h.chatCitation,bigEnoughCitation:null==h?void 0:h.bigEnoughCitation},customIcons:f,onSelectProceed:y,isDisableProceedButton:R,big_enough_block:w}),isSegmentExplanation:S,scenario:g,handleViewExample:I,handleViewGlossary:N,isUpdatedSegment:A})}),"riskSideBar"!==g&&o("div",{onClick:()=>{(null==Q?void 0:Q.isBottomComponentCollapsed)&&oi(i=>!i)},className:`${c.headerBar} ${"riskSideBar"===g?"":c.headerBarRounded}`,style:null===(E=null==h?void 0:h.aiReasoningContent)||void 0===E?void 0:E.headerBar,children:[o("div",{className:c.headerBrand,style:null===(_=null==h?void 0:h.aiReasoningContent)||void 0===_?void 0:_.headerBrand,children:[X,i("p",{children:null!==(M=null==b?void 0:b.mainHeader)&&void 0!==M?M:"Cognitive Decisioning AI"})]}),o("div",{className:c.headerScore,style:null===(O=null==h?void 0:h.aiReasoningContent)||void 0===O?void 0:O.headerScore,children:[!isNaN(null==p?void 0:p.relevance_score)&&u(p.relevance_score,p.relevance_score_diff,null===(j=null==h?void 0:h.aiReasoningContent)||void 0===j?void 0:j.confidenceDisplay,f),(null==Q?void 0:Q.isBottomComponentCollapsed)&&i("button",{className:c.chevronWrapper,style:null===(W=null==h?void 0:h.aiReasoningContent)||void 0===W?void 0:W.chevronWrapper,children:ii?i(r,{className:null==c?void 0:c.chevronIcon,style:null===(F=null==h?void 0:h.aiReasoningContent)||void 0===F?void 0:F.chevronIcon}):i(v,{className:null==c?void 0:c.chevronIcon,style:null===($=null==h?void 0:h.aiReasoningContent)||void 0===$?void 0:$.chevronIcon})})]})]}),"riskSideBar"!==g&&ii&&i("div",{className:c.bodyRow,style:{width:"100%",...null===(G=null==h?void 0:h.aiReasoningContent)||void 0===G?void 0:G.bodyRow},children:o("div",{className:`flex flex-col ${c.bodyFull}`,children:[i(l,{icon:i("div",{className:c.iconWrapper,style:null===(H=null==h?void 0:h.aiReasoningContent)||void 0===H?void 0:H.iconWrapper,children:Y}),isUpdatedSegment:A,title:null!==(P=null==b?void 0:b.decisionHeader)&&void 0!==P?P:"Decision Making Factors",subTitle:"",customStyles:null==h?void 0:h.aiReasoningAccordion,alwaysOpen:null===(T=null==Q?void 0:Q.reasoningAlwaysOpen)||void 0===T||T,defaultOpen:null===(U=null==Q?void 0:Q.reasoningDefaultOpen)||void 0===U||U,content:i(t,{message:(null==p?void 0:p.reason)||"No reasoning available.",customStyles:null==h?void 0:h.aiReasoningMarkdown,citationStyles:{webCitation:null==h?void 0:h.webCitation,stormeeCitation:null==h?void 0:h.stormeeCitation,waveformCitation:null==h?void 0:h.waveformCitation,imageCitation:null==h?void 0:h.imageCitation,fileCitation:null==h?void 0:h.fileCitation,appModCitation:null==h?void 0:h.appModCitation,rcaCitation:null==h?void 0:h.rcaCitation,readFileCitation:null==h?void 0:h.readFileCitation,loadingCitations:null==h?void 0:h.loadingCitations,chatCitation:null==h?void 0:h.chatCitation,bigEnoughCitation:null==h?void 0:h.bigEnoughCitation},customIcons:f,big_enough_block:w})}),i("div",{className:c.divider,style:null===(V=null==h?void 0:h.aiReasoningContent)||void 0===V?void 0:V.divider}),i(l,{icon:i("div",{className:c.iconWrapper,style:null===(q=null==h?void 0:h.aiReasoningContent)||void 0===q?void 0:q.iconWrapper,children:Z}),title:null!==(L=null==b?void 0:b.gapHeader)&&void 0!==L?L:"Gaps in Decision",subTitle:"",customStyles:null==h?void 0:h.aiReasoningAccordion,alwaysOpen:null!==(z=null==Q?void 0:Q.gapAlwaysOpen)&&void 0!==z&&z,defaultOpen:null!==(J=null==Q?void 0:Q.gapDefaultOpen)&&void 0!==J&&J,isUpdatedSegment:A,content:i(t,{message:(ni=p.relevance_score,ei=(null==p?void 0:p.gap)||"No gap available.",ni<100?`The decision strength is ${ni}% because: \n${ei}`:ei),customStyles:null==h?void 0:h.aiReasoningMarkdown,citationStyles:{webCitation:null==h?void 0:h.webCitation,stormeeCitation:null==h?void 0:h.stormeeCitation,waveformCitation:null==h?void 0:h.waveformCitation,imageCitation:null==h?void 0:h.imageCitation,fileCitation:null==h?void 0:h.fileCitation,appModCitation:null==h?void 0:h.appModCitation,rcaCitation:null==h?void 0:h.rcaCitation,readFileCitation:null==h?void 0:h.readFileCitation,loadingCitations:null==h?void 0:h.loadingCitations,chatCitation:null==h?void 0:h.chatCitation,bigEnoughCitation:null==h?void 0:h.bigEnoughCitation},customIcons:f,big_enough_block:w}),className:c.gapAccordion})]})}),B&&i("div",{className:c.footer,style:null===(K=null==h?void 0:h.aiReasoningContent)||void 0===K?void 0:K.footer,children:B})]});var ni,ei};export{m as default};
|
|
2
2
|
//# sourceMappingURL=AiReasoningCitationContent.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsxs as i,jsx as n}from"react/jsx-runtime";import e from"./BigEnoughComponent.module.css.js";import{ChevronDown as l,ChevronUp as o,Maximize2 as
|
|
1
|
+
import{jsxs as i,jsx as n}from"react/jsx-runtime";import e from"./BigEnoughComponent.module.css.js";import{ChevronDown as l,ChevronUp as o,Maximize2 as u,X as t}from"lucide-react";import{CognitiveInternalgptCoreComponent as s}from"@e-llm-studio/citation";import{useRequirementAI as g}from"../RequirementAIWrapper/RequirementAIWrapper.js";const a=({customStyles:a,big_enough_decision_factors:d})=>{var c,r,h,m,v,b;const{gptCitationConfigs:p}=g(),E=i=>({...(null==d?void 0:d.big_enough_score)===i?{...null==a?void 0:a.bigEnoughGuidelinePoints,...null==a?void 0:a.bigEnoughGuidelinePointsActive}:null==a?void 0:a.bigEnoughGuidelinePoints});return i("div",{className:e.bigEnoughContainer,style:null==a?void 0:a.bigEnoughContainer,children:[i("div",{className:e.bigEnoughColumn,style:null==a?void 0:a.bigEnoughColumn,children:[n("p",{className:e.bigEnoughColumnLabel,style:null==a?void 0:a.bigEnoughColumnLabel,children:"Guideline"}),i("div",{className:e.bigEnoughBlock,style:null==a?void 0:a.bigEnoughBlock,children:[n("p",{className:`${e.bigEnoughGuidelinePoints} ${0===(null==d?void 0:d.big_enough_score)?e.bigEnoughGuidelinePointsActive:""}`,style:E(0),children:"0 - Micro : 1-2 line changes single step"}),n("p",{className:`${e.bigEnoughGuidelinePoints} ${1===(null==d?void 0:d.big_enough_score)?e.bigEnoughGuidelinePointsActive:""}`,style:E(1),children:"1 - Small task : one function change 1-2 steps max"}),n("p",{className:`${e.bigEnoughGuidelinePoints} ${2===(null==d?void 0:d.big_enough_score)?e.bigEnoughGuidelinePointsActive:""}`,style:E(2),children:"2 - Mid-small : 3-5 step task encompasses within a single file"}),n("p",{className:`${e.bigEnoughGuidelinePoints} ${3===(null==d?void 0:d.big_enough_score)?e.bigEnoughGuidelinePointsActive:""}`,style:E(3),children:"3 - Medium : 3-7 steps encompassing multiple files"}),n("p",{className:`${e.bigEnoughGuidelinePoints} ${4===(null==d?void 0:d.big_enough_score)?e.bigEnoughGuidelinePointsActive:""}`,style:E(4),children:"4 - Large : A full blown big feature implementation"}),n("p",{className:`${e.bigEnoughGuidelinePoints} ${5===(null==d?void 0:d.big_enough_score)?e.bigEnoughGuidelinePointsActive:""}`,style:E(5),children:"5 - Very Large : Full blown multi-repo feature implementation"})]})]}),n("div",{className:e.bigEnoughColumnDivider,style:null==a?void 0:a.bigEnoughColumnDivider}),i("div",{className:e.bigEnoughColumn,style:null==a?void 0:a.bigEnoughColumn,children:[n("p",{className:e.bigEnoughColumnLabel,style:null==a?void 0:a.bigEnoughColumnLabel,children:"GPT Citation"}),n("div",{className:e.bigEnoughBlock,style:null==a?void 0:a.bigEnoughBlock,children:n(s,{item:{text:"",dataSource:null===(r=null===(c=null==d?void 0:d.customMetadata)||void 0===c?void 0:c.data_sources)||void 0===r?void 0:r[0],trainingDataTitle:null===(m=null===(h=null==d?void 0:d.customMetadata)||void 0===h?void 0:h.training_data_title)||void 0===m?void 0:m[0],paraphrase:null===(b=null===(v=null==d?void 0:d.customMetadata)||void 0===v?void 0:v.paraphrase)||void 0===b?void 0:b[0]},headerTitle:(null==p?void 0:p.title)||"GPT - Gemini 2.5 Flash",iconsConfig:{ChevronDownIcon:l,ChevronUpIcon:o,MaximizeIcon:u,CloseIcon:t},...null==p?void 0:p.gptCitationProps})})]})]})};export{a as default};
|
|
2
2
|
//# sourceMappingURL=BigEnoughComponent.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as e}from"react/jsx-runtime";import{Loader2 as i}from"lucide-react";import{useState as t,useEffect as a}from"react";import{mapToHighlightAreas as o,citationViewerStyles as r}from"./pdfCitationUtils.js";import{useRequirementAI as n}from"../RequirementAIWrapper/RequirementAIWrapper.js";import l from"./pdfCitation.module.css.js";import d from"./CitationPdfViewer.js";function s({citation:s,isCitationLoading:c=!1,renderMode:
|
|
1
|
+
import{jsx as e}from"react/jsx-runtime";import{Loader2 as i}from"lucide-react";import{useState as t,useEffect as a}from"react";import{mapToHighlightAreas as o,citationViewerStyles as r}from"./pdfCitationUtils.js";import{useRequirementAI as n}from"../RequirementAIWrapper/RequirementAIWrapper.js";import l from"./pdfCitation.module.css.js";import d from"./CitationPdfViewer.js";function s({citation:s,isCitationLoading:c=!1,renderMode:u,pdfViewHeaderAction:g,citationId:f}){var h,m,p,v,C;const{queryClient:U,useGetSignedUrlQuery:w,useGetSignedUrlMutation:P}=n().apiCachingConfig,[V,_]=t(!1),x=null==s?void 0:s.customMetadata,y=null!==(h=null==x?void 0:x.value)&&void 0!==h?h:[],A=null!==(m=null==x?void 0:x.artifact_url)&&void 0!==m?m:"",j=null!==(p=null==x?void 0:x.artifact_title)&&void 0!==p?p:"",I=null!==(v=null==x?void 0:x.artifact_format)&&void 0!==v?v:"pdf",M=y.flatMap(e=>e.highlighted_text.map(e=>e.text)),N="docx"===I,S=["getSignedUrl",A],{data:D}=w(A,S),{mutate:H,isPending:q}=P(A),G=null!=D?D:"",R=!!A&&q&&!G;A||console.warn("Artifact preview details not found in header message or message data",A);return a(()=>{if(!A)return void _(!0);const e=U.getQueryData(S);e||q||H({gsUtilPath:A}),e&&_(!1)},[A,U,S,q,H]),a(()=>{G&&_(!1)},[G]),null!==(C=(()=>{try{const t=o(y),a=t.length>0;if(R||c)return e("div",{className:l.loaderContainer,children:e(i,{className:l.loaderIcon,size:28})});const n=y.some(e=>!!e.gs_url),s=y.some(e=>null!==e.page_no&&void 0!==e.page_no),h=y.some(e=>Array.isArray(e.highlighted_coordinates)&&e.highlighted_coordinates.length>0),m=t.length>0;return!(n||s||h||m)&&console.warn("No valid coordinates or gs_url found for this citation.",{hasValidGsUrl:n,hasValidPageNo:s,hasHighlightedCoords:h,hasCoordinatesPages:m,pages:y,artifactUrl:A}),(a||!s||V)&&(V||!a)?(console.warn("Error in loading PDF or no valid highlight coordinates found. Rendering fallback viewer without highlights.",{artifactUrl:A,hasValidCoordinates:a,coordinatesPages:t,pages:y}),e(d,{artifactUrl:A,pdfUrl:"",pdfName:j,pages:y,coordinatesPages:[],pdfViewHeaderAction:g,renderMode:null!=u?u:"fallback",isDocx:N,hasValidCoordinates:!1,customStyles:r,highlightText:M,citationId:f})):e(d,{artifactUrl:A,pdfUrl:G,pdfName:j,pages:y,coordinatesPages:t,pdfViewHeaderAction:g,renderMode:null!=u?u:"default",isDocx:N,hasValidCoordinates:a,jumpToPageValue:1,customStyles:r,highlightText:M,citationId:f})}catch(e){return console.warn("Error rendering citation",e),null}})())&&void 0!==C?C:null}export{s as default};
|
|
2
2
|
//# sourceMappingURL=CitationPdfRendererWrapper.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as e}from"react/jsx-runtime";import{Loader2 as i}from"lucide-react";import{PdfViewer as t}from"@e-llm-studio/citation";import{stringToNumber as o}from"./pdfCitationUtils.js";const a={pdfViewer:{height:"50%",maxHeight:"50%",display:"flex",flexDirection:"column",backgroundColor:"#FAFAFA",border:"1px solid #e5e7eb",borderRadius:"8px",overflow:"hidden"},pdfContainer:{flex:1,overflowY:"auto",padding:"8px"},header:{borderBottom:"1px solid #e5e7eb"}},l={pdfViewerWrapper:"shadow-sm"},r=()=>e("div",
|
|
1
|
+
import{jsx as e}from"react/jsx-runtime";import{Loader2 as i}from"lucide-react";import{PdfViewer as t}from"@e-llm-studio/citation";import{stringToNumber as o}from"./pdfCitationUtils.js";const a={pdfViewer:{height:"50%",maxHeight:"50%",display:"flex",flexDirection:"column",backgroundColor:"#FAFAFA",border:"1px solid #e5e7eb",borderRadius:"8px",overflow:"hidden"},pdfContainer:{flex:1,overflowY:"auto",padding:"8px"},header:{borderBottom:"1px solid #e5e7eb"}},l={pdfViewerWrapper:"shadow-sm"},r=()=>e("div",{className:"h-full flex items-center justify-center",children:e(i,{className:"animate-spin text-purple-500",size:28})}),n=({artifactUrl:i,pdfUrl:n,pdfName:s,pages:d,coordinatesPages:c,activeCitationIndex:f,onActiveCitationChange:h,pdfViewHeaderAction:p,isLoading:u,hasValidCoordinates:g,renderMode:m="default",useCoordinates:C=!0,jumpToPageValue:x,customStyles:b,customClasses:k,isDocx:v=!1,highlightText:A,citationId:w})=>{if(u)return e(r,{});const P=v||"fallback"===m?"":n,V="fallback"===m||!1===g?[]:c,j="fallback"!==m&&C,I=o(w),N=p?{icon:p.icon,tooltip:p.tooltip,onClick:()=>{p.onClick({artifactUrl:i,artifactId:i,fileName:null!=s?s:"",pages:d,currentCitationIndex:null!=I?I:0})}}:void 0;return e(t,{pdfUrl:P,pdfName:s,fallbackPages:d,highlightCordinatePages:V,highlightText:null!=A?A:[],highlightPages:{},useCoordinates:j,activeCitationIndex:f,headerAction:N,onActiveCitationChange:h,highlightColor:"oklch(0.78 0.16 95 / 0.35)",activeHighlightColor:"oklch(0.75 0.17 95 / 0.45)",jumpToPageValue:x,customStyles:null!=b?b:a,customClasses:null!=k?k:l})};export{n as default};
|
|
2
2
|
//# sourceMappingURL=CitationPdfViewer.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as n}from"react/jsx-runtime";import t from"../../../CitationRenderer/CitationRenderer.js";import i from"../../../RequirementAiCitations/AiReasoning/components/icons/DocumentCitationIcon.js";import o from"./CitationPdfRendererWrapper.js";const e=({title:e,citation:r,customIcons:c,customStyles:a,pdfViewHeaderAction:
|
|
1
|
+
import{jsx as n}from"react/jsx-runtime";import t from"../../../CitationRenderer/CitationRenderer.js";import i from"../../../RequirementAiCitations/AiReasoning/components/icons/DocumentCitationIcon.js";import o from"./CitationPdfRendererWrapper.js";const e=({title:e,citation:r,customIcons:c,customStyles:a,pdfViewHeaderAction:d})=>{var l;const m=null!==(l=null==c?void 0:c.ScannedDocumentIcon)&&void 0!==l?l:n(i,{});return n(t,{inLineCitation:!0,citationTitle:e,citationId:`scanned-doc-${r.citation_number}`,citationComponent:n(o,{citation:r,citationId:`${r.citation_number}`,pdfViewHeaderAction:d}),chevronDownComponent:m,chevronUpComponent:m,styles:{pillButton:{fontSize:"14px",margin:"0px",background:"#ffffff",color:"#526eff",cursor:"pointer",verticalAlign:"middle",whiteSpace:"nowrap",display:"inline-flex",alignItems:"center",border:"none",...null==a?void 0:a.pill},citationContent:{width:"100%",background:"transparent",minHeight:"10px",height:"fit-content",...null==a?void 0:a.content}}})};export{e as default};
|
|
2
2
|
//# sourceMappingURL=ScannedCitationRenderer.js.map
|
package/dist/features/RequirementAI/components/citations/appmod-citation/AppmodCitationContent.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as e,jsxs as
|
|
1
|
+
import{jsx as e,jsxs as l}from"react/jsx-runtime";import{useRef as n,useMemo as r,useEffect as i}from"react";import a from"react-markdown";import o from"rehype-raw";import d from"./AppModCitationContent.module.css.js";import s from"./components/CodeLinkHandler.js";import{DEFAULT_HIGHLIGHT_THEME as t}from"./types.js";import{renderAIConfidenceDisplay as c}from"../../../../RequirementAiCitations/AiReasoning/components/AIConfidenceDisplay.js";import{SparkleIcon as m}from"./icons/SparkleIcon.js";const h=(l,n,r,i)=>{const a=(null==n?void 0:n.highlight)||t,o=()=>l?{backgroundColor:a.background,color:a.text,padding:"2px 3px",borderRadius:"2px",boxDecorationBreak:"clone",WebkitBoxDecorationBreak:"clone"}:{},c=()=>({...o(),display:"inline"});return{h1:({children:r})=>{var i;return e("h1",{className:d.heading1,style:null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.heading1,children:l?e("span",{style:o(),children:r}):r})},h2:({children:r})=>{var i;return e("h2",{className:d.heading2,style:null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.heading2,children:l?e("span",{style:o(),children:r}):r})},h3:({children:r})=>{var i;return e("h3",{className:d.heading3,style:null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.heading3,children:l?e("span",{style:o(),children:r}):r})},h4:({children:r})=>{var i;return e("h4",{className:d.heading4,style:null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.heading4,children:l?e("span",{style:o(),children:r}):r})},h5:({children:r})=>{var i;return e("h5",{className:d.heading5,style:null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.heading5,children:l?e("span",{style:o(),children:r}):r})},h6:({children:r})=>{var i;return e("h6",{className:d.heading6,style:null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.heading6,children:l?e("span",{style:o(),children:r}):r})},p:({children:r})=>{var i;return e("p",{className:d.paragraph,style:null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.paragraph,children:l?e("span",{style:c(),children:r}):r})},ol:({children:l})=>{var r;return e("ol",{className:d.orderedList,style:null===(r=null==n?void 0:n.markdown)||void 0===r?void 0:r.list,children:l})},ul:({children:l})=>{var r;return e("ul",{className:d.unorderedList,style:null===(r=null==n?void 0:n.markdown)||void 0===r?void 0:r.list,children:l})},li:({children:r})=>{var i;return e("li",{className:d.listItem,style:null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.listItem,children:l?e("span",{style:c(),children:r}):r})},strong:({children:r})=>{var i;return e("strong",{className:d.strong,style:{...null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.strong,...l?o():{}},children:r})},em:({children:r})=>{var i;return e("em",{className:d.emphasis,style:{...null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.emphasis,...l?o():{}},children:r})},a:({children:o,href:d})=>e(s,{href:d,codeLinkConfig:i,isHighlighted:l,highlightTheme:a,customStyles:null==n?void 0:n.markdown,customIcon:null==r?void 0:r.appModCitationLinkIcon,children:o}),code:({children:r,className:i})=>{var o,s;const t=null==i?void 0:i.includes("language-"),c=l?{backgroundColor:a.codeBackground,color:a.codeText,border:`1px solid ${a.codeBorder}`}:{};return t?e("div",{children:e("code",{className:d.codeBlock,style:{...null===(s=null==n?void 0:n.markdown)||void 0===s?void 0:s.codeBlock,...c},children:r})}):e("code",{className:d.inlineCode,style:{...null===(o=null==n?void 0:n.markdown)||void 0===o?void 0:o.code,...c},children:r})},pre:({children:l})=>e("pre",{className:d.preBlock,children:l}),blockquote:({children:r})=>{var i;return e("blockquote",{className:d.blockquote,style:{...null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.blockquote,...l?{borderColor:a.border}:{}},children:l?e("span",{style:c(),children:r}):r})},table:({children:r})=>{var i;return e("div",{className:d.tableWrapper,children:e("table",{className:d.table,style:{...null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.table,...l?o():{}},children:r})})},thead:({children:l})=>e("thead",{className:d.tableHead,children:l}),tbody:({children:l})=>e("tbody",{className:d.tableBody,children:l}),tr:({children:n})=>e("tr",{className:d.tableRow,style:l?o():{},children:n}),th:({children:r})=>{var i;return e("th",{className:d.tableHeader,style:{...null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.tableHeader,...l?o():{}},children:r})},td:({children:r})=>{var i;return e("td",{className:d.tableCell,style:{...null===(i=null==n?void 0:n.markdown)||void 0===i?void 0:i.tableCell,...l?o():{}},children:r})},details:({children:l})=>e("details",{className:d.details,children:l}),summary:({children:n})=>{const r=e=>{var l;return"string"==typeof e?e:Array.isArray(e)?e.map(r).join(""):(null===(l=null==e?void 0:e.props)||void 0===l?void 0:l.children)?r(e.props.children):""},i=r(n).replace(/:$/,"").trim();return e("summary",{className:d.summary,style:l?o():{},children:i})}}},u=({citation:s,customStyles:t,customIcons:u,codeLinkConfig:v,isLoading:p=!1,shouldAutoScroll:y=!1})=>{var g,b;const N=n(null),k=n(null),w=s.description||"",f=s.customMetadata.question||"",C=s.customMetadata.highlighted_text,x=s.customMetadata.relevance_score,I=r(()=>h(!1,t,u,v),[t,u,v]),q=r(()=>h(!0,t,u,v),[t,u,v]);i(()=>{if(!y||!(null==C?void 0:C.trim())||!(null==w?void 0:w.trim())||p)return;const e=k.current;if(!e)return;const l=()=>{e.scrollIntoView({behavior:"smooth",block:"center",inline:"nearest"})},n=window.requestAnimationFrame(()=>{l(),window.setTimeout(l,120)});return()=>{window.cancelAnimationFrame(n)}},[w,C,p,y]);const A=(null==u?void 0:u.appModCitationIcon)||e("div",{children:e(m,{className:d.headerIcon})});return l("div",{ref:N,className:d.container,style:null==t?void 0:t.container,children:[l("div",{className:d.header,style:null==t?void 0:t.header,children:[l("div",{className:d.headerLeft,style:null==t?void 0:t.headerLeft,children:[e("span",{style:null==t?void 0:t.headerIcon,children:A}),e("span",{className:d.headerTitle,style:null==t?void 0:t.headerTitle,children:"AskMod Response"})]}),c(x,null==t?void 0:t.confidenceDisplay)]}),l("div",{className:d.questionContainer,style:null==t?void 0:t.questionContainer,children:[e("p",{className:d.questionLabel,style:null==t?void 0:t.questionLabel,children:"Me"}),e("div",{className:d.questionText,style:null==t?void 0:t.questionText,children:f||"Ask question to get response"})]}),e("div",{className:d.answerIconRow,style:null==t?void 0:t.answerIconRow,children:l("p",{className:d.assistantName,style:null==t?void 0:t.assistantName,children:["Askmod",e("span",{className:d.assistantNameInner,style:null==t?void 0:t.assistantNameInner,children:".AI"})]})}),e("div",{className:d.answerContainer,style:null==t?void 0:t.answerContainer,children:p?e("span",{className:d.loadingText,style:null===(g=null==t?void 0:t.loading)||void 0===g?void 0:g.text,children:"Generating..."}):w?((n,r)=>{const i=((e="")=>e.replace(/<details\b([^>]*)>/gi,(e,l)=>/\bopen\b/i.test(l)?"<details open>":"<details>").replace(/<summary\b[^>]*>\s*<codebasename>([^<]*)<\/codebasename>\s*<\/summary>/gi,(e,l)=>`<summary class="codebase-summary codebasename">From ${l.trim()} codebase</summary>`).replace(/<\/summary>/g,"</summary>\n").replace(/```codebasename\s*([\s\S]{0,2000}?)```/gi,(e,l)=>`<codebasename>${l.trim()}</codebasename>`).trim())(n.replace(/\\n/g,"\n"));if(r&&i.includes(r)){const n=i.indexOf(r),s=i.substring(0,n),t=i.substring(n,n+r.length),c=i.substring(n+r.length),m=!t.trim();return l("div",{className:d.markdownContent,children:[s&&e(a,{rehypePlugins:[o],components:I,children:s}),t&&!m&&e("div",{ref:k,"data-appmod-highlight-anchor":"true",children:e(a,{rehypePlugins:[o],components:q,children:t})}),t&&m&&t,c&&e(a,{rehypePlugins:[o],components:I,children:c})]})}return e(a,{className:d.markdownContent,rehypePlugins:[o],components:I,children:i})})(w,C):e("span",{className:d.errorText,style:null===(b=null==t?void 0:t.error)||void 0===b?void 0:b.text,children:"Oops! Can't generate your response now."})})]})};export{u as default};
|
|
2
2
|
//# sourceMappingURL=AppmodCitationContent.js.map
|
package/dist/features/RequirementAI/components/citations/appmod-citation/AppmodCitationRenderer.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as t,Fragment as n}from"react/jsx-runtime";import{SparkleIcon as i}from"lucide-react";import{useState as o,useCallback as e}from"react";import
|
|
1
|
+
import{jsx as t,Fragment as n}from"react/jsx-runtime";import{SparkleIcon as i}from"lucide-react";import{useState as o,useCallback as e}from"react";import r from"../../../../CitationRenderer/CitationRenderer.js";import a from"./AppmodCitationContent.js";const c=({title:c,citation:l,customStyles:p,customIcons:s,codeLinkConfig:m,isLoading:d=!1,isOpen:u})=>{const[g,f]=o(!1),C=void 0!==u,h=C?!!u:g,x=e(()=>{C||f(t=>!t)},[C]),b=(null==s?void 0:s.appModCitationIcon)||t(i,{className:"inline align-super mb-1 ml-1",style:{width:"12px",height:"12px"}});return t(r,{inLineCitation:!0,citationTitle:c+"",citationIcon:t(n,{}),citationId:`appmod-ai-${l.citation_number}`,citationComponent:t(a,{citation:l,customStyles:p,customIcons:s,codeLinkConfig:m,isLoading:d,shouldAutoScroll:h}),isOpen:h,onToggle:x,chevronDownComponent:b,chevronUpComponent:b,styles:{pillButton:{fontSize:"13px",margin:"0px",padding:"0px 4px",color:"#3b82f6",cursor:"pointer",verticalAlign:"baseline",whiteSpace:"normal",wordBreak:"break-all",display:"inline-flex",alignItems:"unset",background:"transparent",border:"none",...null==p?void 0:p.pill},citationContent:{width:"100%",background:"transparent",minHeight:"10px",height:"fit-content"}}})};export{c as default};
|
|
2
2
|
//# sourceMappingURL=AppmodCitationRenderer.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as e,jsxs as n}from"react/jsx-runtime";import i from"./CodeLinkHandler.module.css.js";import{ExternalLinkIcon as t,ChevronUpIcon as o,ChevronDownIcon as a}from"lucide-react";import{CodeCitation as r}from"@e-llm-studio/citation";import{DEFAULT_HIGHLIGHT_THEME as l}from"../types.js";const s=({href:s,children:d,codeLinkConfig:c,isHighlighted:m=!1,highlightTheme:h=l,customStyles:u,customIcon:f})=>{var p,g;if(!s)return e("span",{children:d});const C=(e=>{try{const n=new URL(e,"http://example.com"),i=n.searchParams.get("startLine"),t=n.searchParams.get("endLine"),o=n.searchParams.get("validation");n.searchParams.delete("startLine"),n.searchParams.delete("endLine"),n.searchParams.delete("validation");const a=n.pathname+n.search;return{filePath:decodeURIComponent(a.replace(/^\//,"")),fullPath:decodeURIComponent(e),startLine:i,endLine:t,validation:o}}catch(n){return{filePath:e,fullPath:e,startLine:null,endLine:null,validation:null}}})(s),
|
|
1
|
+
import{jsx as e,jsxs as n}from"react/jsx-runtime";import i from"./CodeLinkHandler.module.css.js";import{ExternalLinkIcon as t,ChevronUpIcon as o,ChevronDownIcon as a}from"lucide-react";import{CodeCitation as r}from"@e-llm-studio/citation";import{DEFAULT_HIGHLIGHT_THEME as l}from"../types.js";const s=({href:s,children:d,codeLinkConfig:c,isHighlighted:m=!1,highlightTheme:h=l,customStyles:u,customIcon:f})=>{var p,g;if(!s)return e("span",{children:d});const C=(e=>{try{const n=new URL(e,"http://example.com"),i=n.searchParams.get("startLine"),t=n.searchParams.get("endLine"),o=n.searchParams.get("validation");n.searchParams.delete("startLine"),n.searchParams.delete("endLine"),n.searchParams.delete("validation");const a=n.pathname+n.search;return{filePath:decodeURIComponent(a.replace(/^\//,"")),fullPath:decodeURIComponent(e),startLine:i,endLine:t,validation:o}}catch(n){return{filePath:e,fullPath:e,startLine:null,endLine:null,validation:null}}})(s),k="string"==typeof d?d.split("\n").length>1?"Generated Code":d:(null===(p=null==d?void 0:d.props)||void 0===p?void 0:p.children)||s||"Generated Code";if("vscode"===(null==c?void 0:c.mode)){const o=e=>{e.preventDefault(),(null==c?void 0:c.onCodeLinkClick)&&c.onCodeLinkClick({filePath:C.filePath,startLine:C.startLine,endLine:C.endLine,validation:C.validation})},a=m?{backgroundColor:h.linkBackground,borderColor:h.linkBorder}:void 0,r=m?{color:h.linkText}:void 0,l=m?{color:h.linkIconColor}:null==u?void 0:u.linkIcon,p=f||e(t,{className:i.linkIcon,style:l});return e("a",{href:s,title:s,onClick:o,className:i.linkContainer,style:null==u?void 0:u.link,children:n("span",{className:i.linkWrapper,style:a,children:[p,e("span",{className:i.linkText,style:r,children:d})]})})}if("web"===(null==c?void 0:c.mode)&&c.webConfig){const n=(e=>{const n=/\.(\w+)$/.exec(e);return n?n[1]:"plaintext"})(C.filePath);return e(r,{baseUrlForCodeRetrieval:c.baseUrlForCodeRetrieval||"",filepath:C.fullPath,assistantName:c.webConfig.assistantName,organizationName:c.webConfig.organizationName,userId:c.webConfig.userId,taskId:c.webConfig.taskId,repoUrl:c.webConfig.repoUrl,inLineCitation:!0,citationTitle:k,filename:"Generated Code"!==k?C.filePath:`.${n}`,fileSummarySectionTitle:"File Summary",citationContainerTitle:"Code Preview",showFileSummaryIButton:!0,showFullscreenIcon:!0,showThemeToggle:!0,isDarkModeEnabled:null===(g=c.webConfig.isDarkModeEnabled)||void 0===g||g,chevronUpComponent:c.webConfig.chevronUpComponent||e(o,{}),chevronDownComponent:c.webConfig.chevronDownComponent||e(a,{}),isHighlightingEnabled:!0,editorHeight:"95%",editorWidth:"100%",startIndex:C.startLine?Number(C.startLine):void 0,endIndex:C.endLine?Number(C.endLine):void 0,datasource:c.webConfig.datasource,styles:{pillButton:{display:"inline-flex",alignItems:"center",fontFamily:"Plus Jakarta Sans, sans-serif",backgroundColor:"transparent",padding:"0px",fontSize:"13px",borderRadius:"9999px",cursor:"pointer",color:"#d63384",border:"none",textDecoration:"none",wordBreak:"break-word",whiteSpace:"normal",...null==u?void 0:u.link},citationWrapper:{justifyContent:"flex-start",width:"100%"},citationContent:{width:"100%",height:"500px",backgroundColor:"#eff6ff",border:"1px solid #000",padding:"8px",borderRadius:"4px"},citationContainerTitle:{fontFamily:"Plus Jakarta Sans, sans-serif",display:"flex",justifyContent:"space-between",alignItems:"center",color:"#000",fontSize:"16px",fontWeight:"bold",marginBottom:"8px"}}})}return e("a",{href:s,target:"_blank",rel:"noopener noreferrer",className:i.regularLink,style:null==u?void 0:u.link,children:d})};export{s as default};
|
|
2
2
|
//# sourceMappingURL=CodeLinkHandler.js.map
|
package/dist/features/RequirementAI/components/citations/appmod-citation/icons/AppmodIcon.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsxs as o,jsx as r}from"react/jsx-runtime";const e=({className:e,style:t})=>o("svg",
|
|
1
|
+
import{jsxs as o,jsx as r}from"react/jsx-runtime";const e=({className:e,style:t})=>o("svg",{className:e,style:t,width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[r("path",{d:"M12 2L2 7L12 12L22 7L12 2Z",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),r("path",{d:"M2 17L12 22L22 17",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),r("path",{d:"M2 12L12 17L22 12",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]});export{e as AppModIcon};
|
|
2
2
|
//# sourceMappingURL=AppmodIcon.js.map
|
package/dist/features/RequirementAI/components/citations/appmod-citation/icons/ChatBubbleIcon.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as t}from"react/jsx-runtime";const e=({className:e,style:s})=>t("svg",
|
|
1
|
+
import{jsx as t}from"react/jsx-runtime";const e=({className:e,style:s})=>t("svg",{className:e,style:s,width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",xmlns:"http://www.w3.org/2000/svg",children:t("path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z"})});export{e as ChatBubbleIcon};
|
|
2
2
|
//# sourceMappingURL=ChatBubbleIcon.js.map
|
package/dist/features/RequirementAI/components/citations/appmod-citation/icons/SparkleIcon.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as
|
|
1
|
+
import{jsx as t}from"react/jsx-runtime";const s=({className:s,style:e})=>t("svg",{className:s,style:e,width:"12",height:"12",viewBox:"0 0 24 24",fill:"#3b82f6",xmlns:"http://www.w3.org/2000/svg",children:t("path",{d:"M12 0L14.59 9.41L24 12L14.59 14.59L12 24L9.41 14.59L0 12L9.41 9.41L12 0Z"})});export{s as SparkleIcon};
|
|
2
2
|
//# sourceMappingURL=SparkleIcon.js.map
|
package/dist/features/RequirementAI/components/citations/audio-citation/SearchWaveFromWrapper.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{jsx as e,jsxs as i}from"react/jsx-runtime";import{memo as t,useState as o,useRef as a,useCallback as n,useEffect as l}from"react";import r from"./searchwaveform.js";import s from"./components/videoPlayer.js";import{sortTopicsByCheckedStatus as d}from"./utils/word-segment-util.js";import c from"./components/SegmentByWordsViral.js";import u from"./SearchWaveFromWrapper.module.css.js";import m from"./icons/AudioLinesIcon.js";import v from"./icons/VideoIcon.js";import{CircularProgress as p}from"@mui/material";import{renderCitationAIConfidenceDisplay as g}from"../../../shared/CitationAIConfidenceDisplay.js";import{useRequirementAI as h}from"../../RequirementAIWrapper/RequirementAIWrapper.js";import{AudioPlayProvider as y}from"./store/autoplay.wavefrom.js";const f=e=>{const i=Math.floor(e/3600),t=Math.floor(e%3600/60),o=Math.floor(e%60),a=e=>String(e).padStart(2,"0");return`${a(i)}:${a(t)}:${o.toFixed(0)}`},S=t(({title:t,segments:S,gsUtilPath:P,citationNumber:w,relevanceScore:N,customStyles:A})=>{const[U,L]=o(0),[j,B]=o(S.length>0),[$,k]=o(!1),[C,M]=o(!1),[T,W]=o(""),[b,I]=o(!0),[x,V]=o("audio"),{queryClient:D,useGetSignedUrlQuery:Q,useGetSignedUrlMutation:q,useExtractAudioPeaksMutation:E,useExtractAudioPeaksQuery:G,useGetVideoSignedUrlQuery:O,useGetVideoSignedUrlMutation:R}=h().apiCachingConfig,_=a(null),z=P.replace(/\.wav$|\.mp3$/i,".mp4"),F=["getSignedUrl",P],H=["extractAudioPeaks",P],J=["getVideoSignedUrl",z],{data:K}=Q(P,F),{data:X}=G(P,H),{data:Y}=O(z,J),{mutate:Z,isPending:ee}=q(P),{mutate:ie,isPending:te}=E(P),{mutate:oe}=R(z),ae=n(e=>{L(e)},[]);l(()=>{if(!P)return void console.error("Error -> SearchWaveformWrapper: gsUtilPath is required to fetch signed URL");const e=D.getQueryData(F),i=D.getQueryData(H),t=D.getQueryData(J);e||Z({gsUtilPath:P}),i||ie({gsUtilPath:P}),t||oe({gsUtilPath:z})},[P]),l(()=>{Y&&(async()=>{const e=await fetch(Y);W(e.ok?Y:"")})()},[Y]);return e(y,{children:i("div",{className:u.wrapper,style:null==A?void 0:A.wrapper,children:[i("div",{className:u.header,style:null==A?void 0:A.header,children:[e("h2",{className:u.title,style:null==A?void 0:A.title,children:t||"Audio Snippet"}),g(N,!0,null==A?void 0:A.confidenceDisplay)]}),i("div",{className:u.content,style:null==A?void 0:A.content,children:["audio"!==x&&T?i("div",{className:u.videoSection,style:null==A?void 0:A.videoSection,children:[b&&i("div",{className:u.videoLoader,style:null==A?void 0:A.videoLoader,children:[e(p,{size:40}),e("p",{children:"Loading video..."})]}),e("div",{style:{visibility:b?"hidden":"visible",position:b?"absolute":"relative"},children:e(s,{videoSrc:T,currentTime:U,isWaveformPlaying:C,onBufferingStart:()=>{k(!0),C&&M(!1)},onBufferingEnd:()=>{k(!1)},onVideoPlayPause:e=>{_.current?e?C||_.current.togglePlayPause():C&&_.current.togglePlayPause():M(e)},className:"w-full aspect-video rounded-lg overflow-hidden shadow-lg mb-2",onVideoLoadingStateChange:e=>(e=>{I(e)})(e),isUrlPending:ee,isPeaksPending:te,signedUrl:K,AudioData:X,showOnlyMatched:j,wavesurferRef:_,handleAudioTimeUpdate:ae,segments:S,setIsAudioPlaying:M,setShowOnlyMatched:B,customStyles:null==A?void 0:A.videoPlayer,waveformStyles:null==A?void 0:A.waveform},`video-${w}`)})]}):e("div",{className:u.audioSection,style:null==A?void 0:A.audioSection,children:ee||te?i("div",{className:u.audioLoader,style:null==A?void 0:A.audioLoader,children:[e(p,{size:48}),e("span",{children:"Loading audio peaks..."})]}):K&&X&&e(r,{ref:_,audio_file_name:K,matchedSegments:S,peaks:X.peaks,duration:X.duration,setIsAudioPlaying:M,onTimeUpdate:ae,currentAudioTime:U,showOnlyMatched:j,setShowOnlyMatched:B,customStyles:null==A?void 0:A.waveform},`audio-${w}`)}),i("div",{className:u.controls,style:null==A?void 0:A.controls,children:[T&&i("div",{className:u.mediaToggle,style:null==A?void 0:A.mediaToggle,children:[e("span",{className:`\n ${u.mediaButton}\n ${"video"===x&&u.mediaButtonActive}\n `,style:"video"===x?null==A?void 0:A.mediaButtonActive:null==A?void 0:A.mediaButton,onClick:()=>V("video"),children:e(v,{})}),e("span",{className:`\n ${u.mediaButton}\n ${"audio"===x&&u.mediaButtonActive}\n `,style:"audio"===x?null==A?void 0:A.mediaButtonActive:null==A?void 0:A.mediaButton,onClick:()=>V("audio"),children:e(m,{})})]}),e("label",{className:u.switchLabel,style:null==A?void 0:A.switchLabel,children:e("span",{children:"play only matched segments"})})]}),i("div",{className:u.transcript,style:null==A?void 0:A.transcriptContainer,children:[e("div",{className:u.transcriptHeader,style:null==A?void 0:A.transcriptHeader,children:"Transcript"}),(i=>{const t=d(i);return e("div",{className:u.segmentList,style:null==A?void 0:A.segmentList,children:null==t?void 0:t.map(i=>e("div",{id:i.segment_id,className:u.segmentItem,style:null==A?void 0:A.transcriptSegment,children:e(c,{content:i.text,startTime:f(i.start),endTime:f(i.end),words:i.words||[],currentTime:U,containerStyle:null==A?void 0:A.transcriptContainer,customStyles:null==A?void 0:A.segmentWords})},i.segment_id))})})(S)]})]})]})})});export{S as default,f as formatTime};
|
|
2
2
|
//# sourceMappingURL=SearchWaveFromWrapper.js.map
|
package/dist/features/RequirementAI/components/citations/audio-citation/WaveformCitationRenderer.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as t}from"react/jsx-runtime";import i from"react";import o from"./components/AudioCitationIcon.js";import n from"./SearchWaveFromWrapper.js";import e from"../../../../CitationRenderer/CitationRenderer.js";const a=a=>{var c,r,l,s,
|
|
1
|
+
import{jsx as t}from"react/jsx-runtime";import i from"react";import o from"./components/AudioCitationIcon.js";import n from"./SearchWaveFromWrapper.js";import e from"../../../../CitationRenderer/CitationRenderer.js";const a=a=>{var c,r,l,d,s,m,u;const p=(null===(c=a.customIcons)||void 0===c?void 0:c.waveformCitationIcon)||t(o,{});return t(e,{inLineCitation:!0,citationTitle:a.title,citationId:`audio-citation-${a.citation.citation_number}`,citationComponent:t(n,{citationNumber:a.citation.citation_number,gsUtilPath:"audio_transcript"===a.citation.customMetadata.type?null===(r=a.citation.customMetadata)||void 0===r?void 0:r.gs_util_url:"",relevanceScore:"audio_transcript"===a.citation.customMetadata.type?null===(l=a.citation.customMetadata)||void 0===l?void 0:l.relevance_score:0,title:"audio_transcript"===a.citation.customMetadata.type?null===(d=a.citation.customMetadata)||void 0===d?void 0:d.file_name:"",segments:"audio_transcript"===a.citation.customMetadata.type?null===(s=a.citation.customMetadata)||void 0===s?void 0:s.segments:[],customStyles:a.customStyles}),chevronDownComponent:(null==a?void 0:a.citationIcon)?i.createElement(a.citationIcon):p,chevronUpComponent:(null==a?void 0:a.citationIcon)?i.createElement(a.citationIcon):p,styles:{pillButton:{margin:"0px",padding:"0px",fontSize:"14px",color:"#526eff",cursor:"pointer",verticalAlign:"middle",whiteSpace:"nowrap",display:"inline-flex",alignItems:"center",background:"white",border:"none",...null===(m=a.customStyles)||void 0===m?void 0:m.pill},citationContent:{width:"100%",background:"transparent",minHeight:"10px",height:"fit-content",...null===(u=a.customStyles)||void 0===u?void 0:u.content}}})};export{a as default};
|
|
2
2
|
//# sourceMappingURL=WaveformCitationRenderer.js.map
|