Ladsgroup added a comment.
I made a very WIP PR on this but some notes I figured during the work: - While still w3c <https://www.w3schools.com/howto/howto_js_copy_clipboard.asp> says you need to show the text through input to able to copy to clipboard (and ooui is the same too) but the new API for copying to clipboad is usable for us because we don't support IE11 anyway (https://caniuse.com/?search=writeText) so in my PR I stopped showing the url altogether. F34101243: image.png <https://phabricator.wikimedia.org/F34101243> - OTOH, I think we should not show it on hover. Not just it's complicated to combine with focus state (e.g. user on mouse enter, set it to active, then click on the button and make it focused, it's active again but on mouse leave should trigger hiding it...) and it'll also cause issues in matter of producing short urls all the time, it'll quickly get rate limited if let it generate one per hover. Maybe, we copy the long one on hover but with a different button we copy the short url on click? TASK DETAIL https://phabricator.wikimedia.org/T272887 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Ladsgroup Cc: Ladsgroup, Charlie_WMDE, Aklapper, Lydia_Pintscher, Akuckartz, Nandana, Lahi, Gq86, GoranSMilovanovic, QZanden, LawExplorer, _jensen, rosalieper, Scott_WUaS, Wikidata-bugs, aude, Mbch331
_______________________________________________ Wikidata-bugs mailing list Wikidata-bugs@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs