{"action":"created","issue":{"url":"https://api.github.com/repos/webcompat/web-bugs/issues/304","labels_url":"https://api.github.com/repos/webcompat/web-bugs/issues/304/labels{/name}","comments_url":"https://api.github.com/repos/webcompat/web-bugs/issues/304/comments","events_url":"https://api.github.com/repos/webcompat/web-bugs/issues/304/events","html_url":"https://github.com/webcompat/web-bugs/issues/304","id":41998772,"number":304,"title":"macys.com - Mouse-Overs: On mouse hover submenus are not displaying [msft ref# 261772]","user":{"login":"TheWebJustWorks","id":8117557,"avatar_url":"https://avatars.githubusercontent.com/u/8117557?v=3","gravatar_id":"","url":"https://api.github.com/users/TheWebJustWorks","html_url":"https://github.com/TheWebJustWorks","followers_url":"https://api.github.com/users/TheWebJustWorks/followers","following_url":"https://api.github.com/users/TheWebJustWorks/following{/other_user}","gists_url":"https://api.github.com/users/TheWebJustWorks/gists{/gist_id}","starred_url":"https://api.github.com/users/TheWebJustWorks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TheWebJustWorks/subscriptions","organizations_url":"https://api.github.com/users/TheWebJustWorks/orgs","repos_url":"https://api.github.com/users/TheWebJustWorks/repos","events_url":"https://api.github.com/users/TheWebJustWorks/events{/privacy}","received_events_url":"https://api.github.com/users/TheWebJustWorks/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/webcompat/web-bugs/labels/browser-chrome","name":"browser-chrome","color":"F16A5A"},{"url":"https://api.github.com/repos/webcompat/web-bugs/labels/browser-firefox","name":"browser-firefox","color":"FF4E00"},{"url":"https://api.github.com/repos/webcompat/web-bugs/labels/browser-ie","name":"browser-ie","color":"00B9EC"},{"url":"https://api.github.com/repos/webcompat/web-bugs/labels/status-sitewait","name":"status-sitewait","color":"006b75"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2014-09-04T23:47:42Z","updated_at":"2015-08-11T06:05:14Z","closed_at":null,"body":"<!-- @browser: IE 11.0/ Firefox / Chrome  -->\n\n**URL**: macys.com\n**Browser / Version**: IE 11.0/ Firefox / Chrome \n**Operating System**: Windows \n**Problem type**: Looks like the website has a bug.\n**Site owner**: Unknown\n\n**Steps to Reproduce**\nThis issue can only be observed in desktop IE when using a prototype built that exposes Touch Events. However, you typically should be able to see these issues in Chrome by enabling Touch Events in the developer tools or using a mouse in Chrome on a device that also has a touchscreen. \r\n\r\n1.Navigate to URL: http://www1.macys.com/\r\n2.Observe that on mouse hover on menus in menubar submenus are not displaying.\r\n\r\nActual:\r\nOn mouse hover submenus are not displaying.\r\n\r\nExpected Result:\r\nOn mouse hover submenus should be displayed properly.\r\n\r\nDiagnosis feedback:\r\nInternet Explorer for Windows Phone 8.1 Update now supports both Pointer Events and Touch Events. However, Internet Explorer does not yet support Touch Events on Windows (desktops, laptops, tablets, hybrids, etc). Web developers have asked us to also bring Touch Events to Internet Explorer on Windows, and we want to do that. However, we’ve identified a particular coding pattern that causes compatibility issues that prevent us from following through on this. Similarly, other desktop browsers have also seen these issues and would like to work to resolve them. This site was identified as one of several sites that may have compatibility issues due to this coding pattern. We’d like your help in updating this code so that Touch Events can be brought to all browsers on mobile and desktop.\r\n\r\nCode Details:\r\n The following coding pattern (or something very similar) was observed: \r\n\r\nif('touchstart' in document.body) {\r\n elm.addEventListener('touchstart',fn1);\r\n }else{\r\n elm.addEventListener('mousedown', fn2); //only registered on browsers/devices without Touch Events\r\n }\r\n\r\nThis pattern assumes that the Touch Event API is only exposed on devices that are touch-only. As a result, devices that expose the Touch Event API but have a mouse attached may not function correctly since the mouse event handlers are not registered. Changing this pattern to use both Touch and Mouse Event handlers together will resolve this issue:\r\n\r\nelm.addEventListener('touchstart',fn1);\r\n elm.addEventListener('mousedown', fn2);\r\n Alternatively, you might consider using Pointer Events to share code across event handlers:\r\n if (window.PointerEvent) {\r\n elm.addEventListener('pointerdown', fn);\r\n } else {\r\n //Fallback support for browsers that do not yet support Pointer Events\r\n elm.addEventListener('touchstart',fn);\r\n elm.addEventListener('mousedown',fn);\r\n }\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/webcompat/web-bugs/issues/comments/129718604","html_url":"https://github.com/webcompat/web-bugs/issues/304#issuecomment-129718604","issue_url":"https://api.github.com/repos/webcompat/web-bugs/issues/304","id":129718604,"user":{"login":"karlcow","id":505230,"avatar_url":"https://avatars.githubusercontent.com/u/505230?v=3","gravatar_id":"","url":"https://api.github.com/users/karlcow","html_url":"https://github.com/karlcow","followers_url":"https://api.github.com/users/karlcow/followers","following_url":"https://api.github.com/users/karlcow/following{/other_user}","gists_url":"https://api.github.com/users/karlcow/gists{/gist_id}","starred_url":"https://api.github.com/users/karlcow/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/karlcow/subscriptions","organizations_url":"https://api.github.com/users/karlcow/orgs","repos_url":"https://api.github.com/users/karlcow/repos","events_url":"https://api.github.com/users/karlcow/events{/privacy}","received_events_url":"https://api.github.com/users/karlcow/received_events","type":"User","site_admin":false},"created_at":"2015-08-11T06:05:14Z","updated_at":"2015-08-11T06:05:14Z","body":"Did the web site change?\nOr maybe I don't fully understand the issue.\n\nIs it fixed?"}}