VladP
VladP

Reputation: 901

how to prevent dojo name text box remove/delete name onclick

I want prevent users from possibility to delete a name by accident from the list.. It should be possible to delete a name by clicking only on [x]...

Dojo Name Text Box

Thanks

Upvotes: 0

Views: 151

Answers (2)

Frantisek Kossuth
Frantisek Kossuth

Reputation: 3524

Reconsider the plan as Stephan says. My advice: you have used filter elements from OneUI framework. That's not a good choice in my opinion.

My suggestion is to use list element of OneUI instead, for example: enter image description here

Upvotes: 1

stwissel
stwissel

Reputation: 20384

You might want to reconsider that plan :-) - the behavior of the dojo value picker in any other application is to make the full entry a click target - since you don't control other applications, you create an interaction inconsistency that will rather annoy users.

... But if you have to:

The Dojo UI interaction is deeply wired into that control and can't be changed easily. Your sensible option is to take the source of the control and create your own dojo/dijiit widget. Since dojo supports name spaces, that can coexist with the default control. Check the dojo documentation. It contains tutorials how to do that.

You might find there are better uses for your time.

Upvotes: 0

Related Questions