Opened 5 years ago

Closed 5 years ago

#18347 closed defect (fixed)

TextBox: placeholder text disables context "paste" menu item

Reported by: Gordon Smith Owned by: bill
Priority: undecided Milestone: 1.11
Component: Dijit - Form Version: 1.10.2
Keywords: Cc:
Blocked By: Blocking:

Description

Add a placeholder attribute to a TextBox?. Open browser and right click on the TextBox?. The browser now displays the general context menu not the context menu for an entry field. So either no paste option or disabled paste option.

Possible solution - tweak CSS style sheet for placeholder to ignore mouse events.

Change History (4)

comment:1 Changed 5 years ago by bill

Hmm, that's a tough one, since the placeholder is implemented as a <div> over the <input> element, or something like that. I don't understand how we would fix this just by modifying CSS.

The only way I can think of is to rearchitect TextBox? so that the placeholder gets set as the <input>'s value, but that leads to other issues such as if the form is suddenly submitted while the input's value is still set to the placeholder string.

comment:2 Changed 5 years ago by Gordon Smith

The following seems to work for me (but could be a HTML5 only solution): .dijitPlaceHolder {

pointer-events: none;

}

comment:3 Changed 5 years ago by bill

Milestone: tbd1.11
Owner: set to bill
Status: newassigned
Summary: Adding a placeholder to a TextBox disables context "paste" menu itemTextBox: placeholder text disables context "paste" menu item

Thanks, that seems to work on Chrome, FF, and IE11 (but not IE<11). I think that's the best we'll do.

comment:4 Changed 5 years ago by Bill Keese <bill@…>

Resolution: fixed
Status: assignedclosed

In 1eeca25ddcecc79550da0fecc11dab5850f2a2f7/dijit:

Error: Processor CommitTicketReference failed
Unsupported version control system "git": Can't find an appropriate component, maybe the corresponding plugin was not enabled? 
Note: See TracTickets for help on using tickets.