-
-
Notifications
You must be signed in to change notification settings - Fork 222
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FE: Refactor chat control tooltips #797
Conversation
zeroliu
commented
Nov 9, 2024
- Use radix tooltip to implement tooltips in the chat control. It's easier to maintain and handles more edge cases.
- Made chat control icon bigger.
- Made "unsaved history will be lost" message display conditionally based on auto save settings
@@ -247,40 +242,24 @@ const ChatInput: React.FC<ChatInputProps> = ({ | |||
|
|||
<div className="chat-input-buttons"> | |||
{isGenerating && ( | |||
<Tooltip.Provider delayDuration={0}> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
removed because there is no tooltip for these buttons
</button> */} | ||
</> | ||
<TooltipActionButton | ||
onClick={onSaveAsNote} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this be onRefreshVaultContext
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good catch
</> | ||
<TooltipActionButton | ||
onClick={onSaveAsNote} | ||
Icon={<UseActiveNoteAsContextIcon className="icon-scaler" />} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since we are updating this, UseActiveNoteAsContextIcon
is a legacy name, we can rename it to "RefreshIndexIcon" or something.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I saw we are using lucide icons. I updated them to use the library instead of custom Icons. WDYT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can follow up to replace the rest of icons in the app.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@zeroliu That would be great! These were added by a total frontend noob - me. Glad this will be cleaned up now!
2d5220d
to
c458837
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!