Cannot select/copy attendees in Lightning event
Categories
(Calendar :: Dialogs, defect)
Tracking
(Not tracked)
People
(Reporter: mail, Assigned: lasana)
References
Details
Attachments
(2 files)
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:100.0) Gecko/20100101 Firefox/100.0
Steps to reproduce:
Open a meeting in Lightning. See the attendees list. The attendees are shown but cannot be selected or copied. I right clicked, tried click-drag to highlight text.
Expected results:
Right click on attendee name -> copy name, email address, or both.
Click + drag on text of attendee name -> ctrl+c = copy the text.
Updated•2 years ago
|
Assignee | ||
Comment 1•2 years ago
|
||
Not an unreasonable expectation. We could add some css styles for focus but I think handling the shortcuts might affect strings which if that is the case is too late. Maybe these out to be custom elements instead of divs or perhaps we have an element already for this kind of display?
Comment 2•2 years ago
|
||
As a first thought, I don't think just making each item receive focus is necessary or that helpful in this context.
Click + drag on text of attendee name -> ctrl+c = copy the text.
If we want to select the text, then we just need to set user-select: text
to overwrite the inherited rule from the wrapping XUL boxes https://searchfox.org/mozilla-central/rev/3419858c997f422e3e70020a46baae7f0ec6dacc/toolkit/content/minimal-xul.css#20
And I think we need the scripts "chrome://global/content/globalOverlay.js" and "chrome://global/content/editMenuOverlay.js" to enable copy and paste (I'm not 100% sure about this, it is just from memory and a brief look).
If we want mailto links like the other items, then use <a>
, which would be focusable. The links above should do this as well.
Right click on attendee name -> copy name, email address, or both.
I'm not sure we really need this given that it is visible in the text, but we could have a context menu for the <a>
items. This would require new strings, unless we borrow them from the message header https://searchfox.org/comm-central/rev/7923bcceab6029d38d0be76a021424b300997dbe/mail/locales/en-US/chrome/messenger/messenger.dtd#879,881
Comment 3•2 years ago
|
||
Like Henry wrote in the comment above.
If we want to select the text, then we just need to set user-select: text to overwrite the inherited rule from the wrapping XUL boxes https://searchfox.org/mozilla-central/rev/3419858c997f422e3e70020a46baae7f0ec6dacc/toolkit/content/minimal-xul.css#20
And I think we need the scripts "chrome://global/content/globalOverlay.js" and "chrome://global/content/editMenuOverlay.js" to enable copy and paste (I'm not 100% sure about this, it is just from memory and a brief look).
This is the easiest solution as it leverages the generic copy popup components from toolkit
Assignee | ||
Comment 4•2 years ago
|
||
globalOverlay.js
and editMenuOverlay.js
both appear to be in calendar-summary-dialog.xhtml
right click does not seem to bring up the context menu though? Any ideas?
Assignee | ||
Comment 5•2 years ago
|
||
Updated•2 years ago
|
Comment 6•2 years ago
|
||
Thanks for investigating this.
So, if I'm not wrong, the globalOverlay.js and editMenuOverlay.js are needed for the built-in context menu of an input field. With those, we get the standard copy, paste, select all, etc, popup menu.
For items that are not input field, we need to use a custom menu popup with some predefined items.
We'd need something like the simpleCopyPopup
menuitem, but specific for the edit dialog: https://searchfox.org/comm-central/rev/9bf8c72fa3e416d59b24468fb852f69f535ee1fb/mail/base/content/mainPopupSet.inc.xhtml#64
Assignee | ||
Comment 7•2 years ago
|
||
Looking at the event dialog (not the summary one) the attendees are selectable and there is a context menu albeit with specific actions and styles. In the interest of some degree of consistency I'm going to implement this the same way. I'll have to re-use some strings from elsewhere for now because it's too late to introduce new ones.
In the near future we should convert all these html generating functions into configurable custom elements.
Assignee | ||
Updated•2 years ago
|
Updated•2 years ago
|
Assignee | ||
Updated•2 years ago
|
Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/0d93fe4084f0
Make attendees selectable in summary dialog, add context menu. r=aleca
Description
•