Skip to content

Alina/user design updates#343

Merged
kcarnold merged 11 commits intomainfrom
alina/user-design-updates
Feb 20, 2026
Merged

Alina/user design updates#343
kcarnold merged 11 commits intomainfrom
alina/user-design-updates

Conversation

@Alina086
Copy link
Contributor

@Alina086 Alina086 commented Feb 17, 2026

Features and Fixes:

  • (feat) New Suggestion Type introduced: Example Rewording (of selected text only)
  • (feat) New 'Delete suggestion' affordance and positioning (Draft panel)
  • (fix) Saved suggestions are scrollable while suggestion buttons stay fixed at top (Draft panel)
  • (feat) Chat input box components (Send + Clear Chat) rearrangement with new icons
  • (fix) Chat input box stays fixed as conversation becomes scrollable
  • (feat) Chat input box sends message on Enter and new line on Shift + Enter
  • (fix) Message in chat input box immediately clears after being sent
  • (feat) Scroll-to-bottom floating button when there are new chat messages hidden
  • (feat) Auto-scrolls to bottom when new messages arrive in chat
  • (feat) Chat avatars removed

For PR review, changes are obvious when looking side-by-side with current UX.

@jooha-yoo
Copy link
Contributor

tested all changes and looks good so far- especially the new suggestion seems to work as expected, returning empty list when none is selected. (chat user icon thing may still need attention- I'll follow up after taking a closer look at it)

Copy link
Contributor

@kcarnold kcarnold left a comment

Choose a reason for hiding this comment

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

I've only looked at the code, not actually tried it.

- Vary the sentence structure, word choice, and tone across the three options.
- Maintain the writer's overall voice and style.
- Each rewording should be approximately the same length as the original text.
- If no text is selected, return an empty list.
Copy link
Contributor

Choose a reason for hiding this comment

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

How about use the word or phrase (up to N words) nearest the cursor?

This prompt is ambiguous about whether it's ok or desired to reword other parts of the sentence (you say both "selected text" and "sentence structure"). Maybe that's ok?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've removed "sentence structure" from the prompt and gave explicit instruction to only rephrase the selected text.

Copy link
Contributor

Choose a reason for hiding this comment

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

Can you show some examples? (Maybe we could have an EXAMPLES.md or even an examples folder where we show examples of good (and not so good) outputs?)

if prompt_name == "example_rewording" and doc_context.selectedText.strip() == "":
return GenerationResult(
generation_type=prompt_name,
result="Please select some text to get rewording suggestions.",
Copy link
Contributor

Choose a reason for hiding this comment

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

does this display correctly?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Screenshot 2026-02-19 191708

const scrollToBottom = useCallback(() => {
const container = messagesContainerRef.current;
if (container) {
container.scrollTop = container.scrollHeight;
Copy link
Contributor

Choose a reason for hiding this comment

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

Could use smooth scroll. I do this here: https://github.com/kcarnold/live-notes/blob/908146dc819f0994fca011932a788e1274ac9fa6/src/reactUtils.tsx#L30 (I forget exactly why I used a target element at the bottom instead of clientHeightlike you do here).

const messagesContainerRef = useRef<HTMLDivElement>(null);
const [showScrollButton, setShowScrollButton] = useState(false);

const handleScroll = useCallback(() => {
Copy link
Contributor

Choose a reason for hiding this comment

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

maybe have a discussion around resize observers, since resizing the window could trigger need to scroll without actually firing onScroll.

type="button"
title="Scroll to bottom"
onClick={scrollToBottom}
className="absolute bottom-[8px] left-1/2 -translate-x-1/2 bg-white border border-gray-300 rounded-full p-[6px] cursor-pointer shadow-md transition duration-150 hover:bg-gray-100"
Copy link
Contributor

Choose a reason for hiding this comment

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

curiosity, what does starting a classname with - do?

Copy link
Contributor

Choose a reason for hiding this comment

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

It looks like tailwind allows - to apply negative version of that; i.e., that would be a negative transform.

@kcarnold
Copy link
Contributor

To be clear, I'm ok with merge, my comments are just ideas/suggestions/low-priority issues.

@Alina086 Alina086 requested a review from kcarnold February 20, 2026 01:36
@kcarnold kcarnold merged commit 847046e into main Feb 20, 2026
7 checks passed
@kcarnold kcarnold deleted the alina/user-design-updates branch February 20, 2026 14:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants