feat(client/renderer): added open event to the listeners to perform o…#1323
feat(client/renderer): added open event to the listeners to perform o…#1323
Conversation
|
@CodiumAI-Agent /describe |
|
@CodiumAI-Agent /review |
Titlefeat(client/renderer): added open event to the listeners to perform o… User description…pen action DescriptionChanges MadeHow to Test
NotesPR TypeEnhancement Description
Changes walkthrough 📝
|
|
@CodiumAI-Agent /improve |
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
PR Code Suggestions ✨
|
…reate-onClick-action-for-open-page
RNubla
left a comment
There was a problem hiding this comment.
Reviewed and tested changes. Some minor changes suggestion should be made for better readability.
| @@ -102,6 +103,16 @@ export const ListenerActionOverlay = observer( | |||
| }, | |||
There was a problem hiding this comment.
can this whole section be refactored for better readability like
const { control, handleSubmit, reset, watch, setValue } = useForm<ListenerActionForm>({
defaultValues: (() => {
if (lis) {
if (lis.message === ActionMessages.RUN_CELL) {
return {
message: ActionMessages.RUN_CELL,
payload: { queryId: "", cellId: "" },
};
}if (
lis.message === ActionMessages.DISPATCH_OPEN_EVENT
) {
return {
message: ActionMessages.DISPATCH_OPEN_EVENT,
payload: { destinationType: "", destination: "" },
};
}
}
return {
message: ActionMessages.RUN_QUERY,
payload: { queryId: "" },
};
})(),
});|
|
||
| // the type | ||
| const message = watch("message"); | ||
| const distinationType = watch("payload.destinationType"); |
There was a problem hiding this comment.
please be mindful when using watch(), this will re-render at the root level, which can cause performance issues. As a rule of thumb, use the useWatch hook as much possible
| {content} | ||
| {isLink(content) ? ( | ||
| <Link | ||
| target="_blank" |
There was a problem hiding this comment.
add rel="noopener noreferrer" attribute to <Link/>
|
@CodiumAI-Agent /update_changelog |
|
Changelog updates: 🔄 2025-06-19 *Added
|
…pen action
Description
Changes Made
How to Test
Notes