Skip to content
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

feat: auto-scroll to the bottom of the conversation #1049

Merged
merged 16 commits into from
Oct 16, 2023

Conversation

berry-13
Copy link
Collaborator

@berry-13 berry-13 commented Oct 14, 2023

added a switch to enable and disable "auto-scroll to bottom of conversation when opening"

on

image

off

image

issue:

- [ ] when you open a conversation with images, the conversation scrolls afterward

Change Type

  • New feature (non-breaking change which adds functionality)

Testing

Check if the button works on different browser and with npm or docker.
Check if after refreshing the page it works

Checklist

  • My code adheres to this project's style guidelines
  • I have performed a self-review of my own code
  • I have commented in any complex areas of my code
  • I have made pertinent documentation changes
  • My changes do not introduce new warnings
  • I have written tests demonstrating that my changes are effective or that my feature works
  • Local unit tests pass with my changes
  • Any changes dependent on mine have been merged and published in downstream modules.

Sorry, something went wrong.

@berry-13 berry-13 linked an issue Oct 14, 2023 that may be closed by this pull request
1 task
@berry-13
Copy link
Collaborator Author

@danny-avila, I'm not sure, but I believe the issue "when you open a conversation with images, the conversation scrolls afterward" can only be fixed by doing something like in #910.

@berry-13 berry-13 marked this pull request as ready for review October 14, 2023 12:09
@danny-avila
Copy link
Owner

@danny-avila, I'm not sure, but I believe the issue "when you open a conversation with images, the conversation scrolls afterward" can only be fixed by doing something like in #910.

what do you mean by this?

@berry-13
Copy link
Collaborator Author

what do you mean by this?

I mean that when you open a conversation with images generated by stable diffusion or dall-e, first it load the images and then scroll down

@danny-avila
Copy link
Owner

what do you mean by this?

I mean that when you open a conversation with images generated by stable diffusion or dall-e, first it load the images and then scroll down

so the auto scroll you made doesn't happen in this case?

@danny-avila
Copy link
Owner

For context, got a reply on discord:

when you open a conversation with images, for a fraction of a second you see the text or images at the beginning and after about half a second it scrolls down to the bottom of the conversation, this ONLY when there are images in the chat
so, yeah it's ready

@berry-13 berry-13 force-pushed the auto-scroll-to-bottom-of-conversation branch from d57fb79 to bf7b6c5 Compare October 14, 2023 23:08
@berry-13 berry-13 requested a review from danny-avila October 15, 2023 13:55
@danny-avila danny-avila merged commit b1a96ec into main Oct 16, 2023
@danny-avila danny-avila deleted the auto-scroll-to-bottom-of-conversation branch October 16, 2023 15:01
cnkang pushed a commit to cnkang/LibreChat that referenced this pull request Feb 6, 2024
* added button for autoscroll

* fix(General) removed bold

* fix(General) typescript error with checked={autoScroll}

* added return condition for new conversations

* refactor(Message) limit nesting

* fix(settings) used effects

* fix(Message) disabled autoscroll when search

* test(AutoScrollSwitch)

* fix(AutoScrollSwitch) test

* fix(ci): attempt to debug workflow

* refactor: move AutoScrollSwitch from General file, don't use cache for npm

* fix(ci): add test config to avoid redirects and silentRefresh

* chore: add back workflow caching

* chore(AutoScrollSwitch): remove comments, fix type issues, clarify switch intent

* refactor(Message): remove unnecessary message prop form scrolling condition

* fix(AutoScrollSwitch.spec): do not get by text

---------

Co-authored-by: Danny Avila <messagedaniel@protonmail.com>
BertKiv pushed a commit to BertKiv/LibreChat that referenced this pull request Dec 10, 2024
* added button for autoscroll

* fix(General) removed bold

* fix(General) typescript error with checked={autoScroll}

* added return condition for new conversations

* refactor(Message) limit nesting

* fix(settings) used effects

* fix(Message) disabled autoscroll when search

* test(AutoScrollSwitch)

* fix(AutoScrollSwitch) test

* fix(ci): attempt to debug workflow

* refactor: move AutoScrollSwitch from General file, don't use cache for npm

* fix(ci): add test config to avoid redirects and silentRefresh

* chore: add back workflow caching

* chore(AutoScrollSwitch): remove comments, fix type issues, clarify switch intent

* refactor(Message): remove unnecessary message prop form scrolling condition

* fix(AutoScrollSwitch.spec): do not get by text

---------

Co-authored-by: Danny Avila <messagedaniel@protonmail.com>
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.

Enhancement: Auto scroll to bottom of conversation when opening
2 participants