Skip to content
This repository was archived by the owner on Mar 18, 2026. It is now read-only.

Hr dev#23

Merged
CocoRoF merged 7 commits into
mainfrom
hr_dev
Jul 19, 2025
Merged

Hr dev#23
CocoRoF merged 7 commits into
mainfrom
hr_dev

Conversation

@CocoRoF
Copy link
Copy Markdown
Collaborator

@CocoRoF CocoRoF commented Jul 19, 2025

This pull request introduces several changes, focusing on replacing the chat functionality with a node refresh feature, improving workflow execution, and enhancing the Node component with better logging and support for boolean parameters. Additionally, unused chat-related components and APIs have been removed to streamline the codebase.

Removal of Chat Functionality:

  • Removed the ChatPanel component and its associated logic, including the sendMessage and executeChatMessage functions from src/app/api/chatAPI.js. This also involved removing references to chat functionality in SideMenu.tsx and ChatInterface.tsx. [1] [2] [3] [4] [5] [6]

Addition of Node Refresh Feature:

  • Added a new refreshNodes function in src/app/api/nodeAPI.js, which fetches the latest node list after a forced refresh. Updated the useNodes hook in nodeHook.ts to use this new function instead of apiExportNodes. [1] [2] [3]

Workflow Execution Enhancements:

  • Enhanced the executeWorkflowById function in src/app/api/workflowAPI.js to optionally include a selectedCollection parameter for better customization during workflow execution. [1] [2]

Node Component Improvements:

  • Improved logging in the Node component (Node.tsx) by adding detailed logs for parameter changes, including support for boolean parameters. Introduced a default placeholder option for dropdowns. [1] [2] [3]

Code Cleanup:

  • Removed the unused ChatPanel component and its styles, along with related imports and dependencies in various files. This simplifies the codebase and removes unnecessary functionality. [1] [2] [3] [4]

CocoRoF added 5 commits July 19, 2025 09:23
…ze it for refreshing node data

refactor: Enhance parameter selection logging in Node component for better debugging
style: Fix SCSS formatting issues in Settings.module.scss
…d improve attachment handling in DefaultChatInterface
…Interface and DefaultChatInterface for enhanced workflow execution
@CocoRoF CocoRoF requested a review from Copilot July 19, 2025 15:23
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR removes chat functionality and replaces it with node refresh capabilities, while enhancing workflow execution with collection support and improving Node component parameter handling. Key changes include removing chat-related components, APIs, and references while adding new node refresh functionality and better logging.

  • Removed all chat-related components, APIs, and UI elements
  • Added node refresh functionality to replace chat features
  • Enhanced workflow execution with optional collection parameter support

Reviewed Changes

Copilot reviewed 9 out of 10 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
DefaultChatInterface.tsx Enhanced with collection modal, attachment menu, and updated to use workflow API instead of chat API
ChatInterface.tsx Simplified by removing chat API dependency and using only workflow execution
ChatPanel.tsx Completely removed chat panel component
SideMenu.tsx Commented out chat menu item and removed ChatPanel import
Node.tsx Added boolean parameter support, enhanced logging, and default placeholder for dropdowns
workflowAPI.js Added selectedCollection parameter to executeWorkflowById function
nodeAPI.js Added refreshNodes function for node list refresh functionality
chatAPI.js Completely removed chat API file
nodeHook.ts Updated to use refreshNodes instead of exportNodes


const attachmentButtonRef = useRef<HTMLDivElement>(null);

// localStorage에서 선택된 컬렉션 정보 가져오기
Copy link

Copilot AI Jul 19, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] Comments should be in English to maintain consistency with the codebase. Consider translating Korean comments to English.

Suggested change
// localStorage에서 선택된 컬렉션 정보 가져오기
// Retrieve selected collection information from localStorage

Copilot uses AI. Check for mistakes.
Comment on lines +87 to +100
const checkSelectedCollection = () => {
try {
const storedCollection = localStorage.getItem('selectedCollection');
if (storedCollection) {
const collectionData = JSON.parse(storedCollection);
setSelectedCollection(collectionData.name);
} else {
setSelectedCollection(null);
}
} catch (err) {
console.error('Failed to load selected collection:', err);
setSelectedCollection(null);
}
};
Copy link

Copilot AI Jul 19, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The collection checking logic is duplicated in two useEffect hooks (lines 54-83 and 85-103). Consider extracting this into a single reusable function to reduce code duplication.

Suggested change
const checkSelectedCollection = () => {
try {
const storedCollection = localStorage.getItem('selectedCollection');
if (storedCollection) {
const collectionData = JSON.parse(storedCollection);
setSelectedCollection(collectionData.name);
} else {
setSelectedCollection(null);
}
} catch (err) {
console.error('Failed to load selected collection:', err);
setSelectedCollection(null);
}
};

Copilot uses AI. Check for mistakes.
}
}, [showCollectionModal]);

// 첨부 메뉴 외부 클릭 시 닫기
Copy link

Copilot AI Jul 19, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] Korean comment should be in English for consistency. Consider: '// Close attachment menu when clicking outside'

Suggested change
// 첨부 메뉴 외부 클릭 시 닫기
// Close attachment menu when clicking outside

Copilot uses AI. Check for mistakes.
if (option === 'collection') {
setShowCollectionModal(true);
}
// TODO: 다른 옵션들에 대한 구현
Copy link

Copilot AI Jul 19, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] TODO comment should be in English for consistency. Consider: '// TODO: Implementation for other options'

Suggested change
// TODO: 다른 옵션들에 대한 구현
// TODO: Implementation for other options

Copilot uses AI. Check for mistakes.
}}
className={`${styles.paramSelect} paramSelect`}
>
<option value="" disabled>-- Select --</option>
Copy link

Copilot AI Jul 19, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The default placeholder option is duplicated in both the regular select (line 128) and boolean select (line 170). Consider extracting this into a constant or component to maintain consistency.

Suggested change
<option value="" disabled>-- Select --</option>
<PlaceholderOption />

Copilot uses AI. Check for mistakes.
@CocoRoF CocoRoF merged commit 9bb2256 into main Jul 19, 2025
4 checks passed
@CocoRoF CocoRoF deleted the hr_dev branch July 22, 2025 01:07
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants