Open J-Son89 opened 1 year ago
cc @qfrank
Hello @vkjr ! are you going to modify the corresponding part on status-go
also or just fix the part of UI ?
@qfrank, not sure yet, currently figuring out the best way to implement this. Do you have something in mind regarding status-go
?
The status-go mention-related API will return an input-segments array, which should include which parts are text and which are mentions. For example, for the text message: ‘hello @john1 , how are you’, the input-segments should contain [[:text 'hello ‘] [:mention ‘@john1’] [:text ’ ,how are you’]]. So the front-end only needs to traverse the input-segments to render the interface. But I need to verify whether the relevant status-go code works as I expected. @vkjr
@qfrank, yes, you talk more about messages that we already store in status-go
, and when I touched that part of the code, splitting the text into sections worked well. This issue is about writing the new message and displaying it correctly while user still types and before message was sent, so most probably status-go
won't be involved
splitting the text into sections worked well
okay, glad to know this! so you may reuse it as it will calculate suggestion( input-segments will get updated) while typing, there is also something like AtIdxs
in state
you could use, it's up to you
Oh, i proberbly missunderstand you, are you familiar with on-change-text ? it involved with status-go
, relate PR
Oh, I misunderstood you too) I thought you are talking about already existing messages! No, wasn't aware of this status-go
call, thank you for pointing to it, will dig deeper! :)
I can help check if InputSegments
works as expected so that you may reuse it , the implementation for mention is complex :) , i rewrote it , I will check it tomorrow
Thank you!
Hi @vkjr , I've made a simple test, in general, input-segments
should work just like this example:
For example, for the text message: ‘hello @John1 , how are you’, the input-segments should contain [[:text 'hello ‘] [:mention ‘@John1’] [:text ’ ,how are you’]]
Hi @vkjr , I've made a simple test, in general,
input-segments
should work just like this example:
Thank you!
Should be reimplemented taking into account https://github.com/status-im/status-mobile/pull/16330#issuecomment-1691405548
cc @vkjr
Currently the mentions show no clear UI to the user that the mention has been correctly resolved.
See the designs for how this should look: https://www.figma.com/file/wA8Epdki2OWa8Vr067PCNQ/Composer-for-Mobile?type=design&node-id=5530-358489&t=1xpxUi8twtiGgxdm-0