Chat Message Feature

Hello to all!

I would like to know if anyone has ever made or tried to make this.

I would like that in my chatroom, when the CURRENT USER is writing, this lottie file + message is displayed (circled in green on the picture).

I managed to do it by doing this: sometimes visible > text imput > not egal > empty, but the problem is that it is displayed all the time (even when the logged-in user is writing).

Does anyone have a solution?

Thanks team

Hi! Nice idea. I am also looking for solution for that.

1 Like

Could you clarify what “not egal” means?

1 Like

“Not equal to”

1 Like

Of course! I should have considered this, but a four year old is climbing on my back while I write these! :slight_smile:

I just added this to one of my apps to see if I had the same problem. It’s actually a very clever little animation idea. Mine worked using the same parameters you used, even a Lottie. It appeared when I started writing, and disappeared when I erased it all. Did you group them properly?

yes it works, but I would like it to appear only when the other user is writing

You can do this by adding a true/false parameter to the logged-in user. Call this true/false parameter “Typing”

Add a countdown timer to your chat message screen and set it to 1 second. Change the visibility to only visible if the input is not empty. Set this to update the logged-in user’s typing value to “true”. Add another countdown timer set to 1 second and only visible if the input IS empty. Set this to update the logged-in user’s typing to “false”.

Make the lottie file a list of chatroom users with a filter where email is not equal to the logged-in user’s email. Set this to only visible if current user > typing > is true.

2 Likes

i will try this and tell you, thanx a lot

Just thinking about it, this might show that the user is typing to all chat users they have conversations with…

So if a user has 2 conversations with 2 separate users, it would show that the user is typing to both users, regardless which conversation they are in.

Let me put more thought into this a little later.

1 Like

Ok, I didn’t find how to do “Set this to visible only if current user > input > is true.” in your advice anyway… Maybe you have already made something like this that can be cloned? Thanks anyway for your help, this community and you are amazing!

I don’t have a cloneable app with this feature yet… but it’s on my roadmap for templates, a really nice chat UI template.

I can promise you there’s a way. Just have to tinker around with it a bit to figure it out.

I’m thinking maybe a new many-to-many relationship between users and conversations called “Users Typing” would do the trick instead.

2 Likes

This is excellent.

ok thanks i have also been havingsame problem

I was right. Adding another many-to-many relationship between users and conversations was the solution. Add user when typing (countdown timer updates conversation to add users to “users typing” relationship when message input is not empty) and Remove user from users typing conversation relationship when input is empty.

So you’d add the animation within a list of users > current conversation > users > where email is not equal to logged-in user email.

This is a desktop PWA chat template that will be available for purchase next week from my website :wink:

2 Likes

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.