0

I want the user of an App edit text with prepared modular text parts. The behaviour should be as in the mail app of iOS. If you hit enter on the keyboard the mail adress becomes a block, which can be grabbed, moved and deleted only together. You can't edit the block's inner content. I only need these kind blocks to move around on a large UITextView.

I started trying out several things: - Placed a UIView over the UITextField and by adding exclusivePaths, I managed to move the view on top of the textfield. I don't see how I can detect the position of the view related to the text of the UITextField to insert on the right position. - I played around with attributed texts and text backgrounds. Looks good, but the text blocks don't stay together and I can't move them around.

Am I on the right way or is there an easier way?

Has anyone of you worked on a similar topic? I can't find anythings related to that. Although it is realised in the Mail App, there don't seem to be too many use cases for that? Any tips are welcome!

1 Answers1

0

I've found for you some other StackOverflow answers that can lead you in the right direction:

Based on these answers, I suggest you take a look at these third-party components on GitHub:

Andrea Corsini
  • 197
  • 1
  • 9