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

Prolong maximum chat message length to 1000 characters #1135

Merged

Conversation

JosefSchoenberger
Copy link
Contributor

Motivation and Context

We want longer chat messages! I can't answer to the questions of our students if I'm not able to write a long prose with at least 800 characters! :-P
Resolves #778.

Description

I replaced the chat input box with a multiline text area and extended the maximum message length from 200 to 1000 characters.

Steps for Testing

  1. Log in
  2. Find a stream or VOD you can comment on
  3. Write a long text message with more then 200 characters. May include multiple lines with Shift+Enter.

Copy link
Member

@joschahenningsen joschahenningsen left a comment

Choose a reason for hiding this comment

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

Looks reasonable, just a quick remark found by eslint:

web/ts/components/chat-prompt.ts Outdated Show resolved Hide resolved
@joschahenningsen
Copy link
Member

BTW, there also is server side validation: https://github.com/joschahenningsen/TUM-Live/blob/dev/model/chat.go#L40

@JosefSchoenberger
Copy link
Contributor Author

Alright, thanks – I was already wondering, but the server accepted messages with ~220 characters and did not find any other occurence of "200" related to chat messages, so I assumed there was no server-side check.
Btw., was there a reason for why the server-side limit was higher?

@joschahenningsen
Copy link
Member

Btw., was there a reason for why the server-side limit was higher?

I can't think of any reason why we would have done this on purpose. I assume it was just an oversight.

Copy link
Member

@joschahenningsen joschahenningsen left a comment

Choose a reason for hiding this comment

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

Thanks!

@joschahenningsen joschahenningsen merged commit 721f5cc into TUM-Dev:dev Aug 23, 2023
7 of 8 checks passed
@MatthiasReumann MatthiasReumann mentioned this pull request Aug 28, 2023
alexanderstephan pushed a commit that referenced this pull request Aug 30, 2023
In #1135 the textarea tag hasn't been closed. As a result the chat UI doesn't work properly. Furthermore, it broke the polls. This is fixed by closing the tag.
SebiWrn pushed a commit that referenced this pull request May 7, 2024
* Prolong maximum chat message length to 1000 characters

* Fix ESLint and server-side check
SebiWrn pushed a commit that referenced this pull request May 7, 2024
In #1135 the textarea tag hasn't been closed. As a result the chat UI doesn't work properly. Furthermore, it broke the polls. This is fixed by closing the tag.
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.

Increase Chat character limit
2 participants