{"action":"created","issue":{"url":"https://api.github.com/repos/marslan390/BeautifyMarker/issues/22","repository_url":"https://api.github.com/repos/marslan390/BeautifyMarker","labels_url":"https://api.github.com/repos/marslan390/BeautifyMarker/issues/22/labels{/name}","comments_url":"https://api.github.com/repos/marslan390/BeautifyMarker/issues/22/comments","events_url":"https://api.github.com/repos/marslan390/BeautifyMarker/issues/22/events","html_url":"https://github.com/marslan390/BeautifyMarker/issues/22","id":339918426,"node_id":"MDU6SXNzdWUzMzk5MTg0MjY=","number":22,"title":"marker-shaped icon breaks z-index","user":{"login":"nnseva","id":496812,"node_id":"MDQ6VXNlcjQ5NjgxMg==","avatar_url":"https://avatars3.githubusercontent.com/u/496812?v=4","gravatar_id":"","url":"https://api.github.com/users/nnseva","html_url":"https://github.com/nnseva","followers_url":"https://api.github.com/users/nnseva/followers","following_url":"https://api.github.com/users/nnseva/following{/other_user}","gists_url":"https://api.github.com/users/nnseva/gists{/gist_id}","starred_url":"https://api.github.com/users/nnseva/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nnseva/subscriptions","organizations_url":"https://api.github.com/users/nnseva/orgs","repos_url":"https://api.github.com/users/nnseva/repos","events_url":"https://api.github.com/users/nnseva/events{/privacy}","received_events_url":"https://api.github.com/users/nnseva/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-07-10T16:29:46Z","updated_at":"2018-07-18T08:13:15Z","closed_at":"2018-07-16T18:39:14Z","author_association":"NONE","body":"When the icon is marker-shaped it breaks the `z-index` style attribute which is ignored by the marker.\r\n\r\nThe reason is that the wrapperDiv built around a marker in the following piece of your code has no `position` style attribute, so the `z-index` is ignored as described in the html documentation.\r\n\r\n```javascript\r\n                // having a marker requires an extra parent div for rotation correction\r\n                if (this.options.iconShape === 'marker') { \r\n                    var wrapperDiv = document.createElement('div');\r\n                    wrapperDiv.appendChild(iconDiv);\r\n                    return wrapperDiv;\r\n                }\r\n```\r\n\r\nSee [here](https://jsfiddle.net/redtfhk2/1/) the example. The top 2 markers are circle-shaped and z-index works. The next 2 markers are marker-shaped and z-index is not working.\r\n\r\nThe recommended fix is to setup `position` style attribute to the `absolute` value, either directly, or by the special class.\r\n"},"comment":{"url":"https://api.github.com/repos/marslan390/BeautifyMarker/issues/comments/405848272","html_url":"https://github.com/marslan390/BeautifyMarker/issues/22#issuecomment-405848272","issue_url":"https://api.github.com/repos/marslan390/BeautifyMarker/issues/22","id":405848272,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNTg0ODI3Mg==","user":{"login":"nnseva","id":496812,"node_id":"MDQ6VXNlcjQ5NjgxMg==","avatar_url":"https://avatars3.githubusercontent.com/u/496812?v=4","gravatar_id":"","url":"https://api.github.com/users/nnseva","html_url":"https://github.com/nnseva","followers_url":"https://api.github.com/users/nnseva/followers","following_url":"https://api.github.com/users/nnseva/following{/other_user}","gists_url":"https://api.github.com/users/nnseva/gists{/gist_id}","starred_url":"https://api.github.com/users/nnseva/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nnseva/subscriptions","organizations_url":"https://api.github.com/users/nnseva/orgs","repos_url":"https://api.github.com/users/nnseva/repos","events_url":"https://api.github.com/users/nnseva/events{/privacy}","received_events_url":"https://api.github.com/users/nnseva/received_events","type":"User","site_admin":false},"created_at":"2018-07-18T08:13:15Z","updated_at":"2018-07-18T08:13:15Z","author_association":"NONE","body":"Sorry @marslan390, but neither iconStyle, nor innerIconStyle is applied to the icon wrapper div when the iconShape option is 'marker'.\r\n\r\nWhen the iconShape is 'marker', the iconStyle option is applied to the immediate children of the icon wrapper div, and innerIconShape is applied to the children div ot the icon wrapper immediate children.\r\n\r\nYou can play with iconShape and innerIconShape [here](https://jsfiddle.net/redtfhk2/1/) to be sure. No one option is applied to the icon wrapper div. It always stay free of additional styles except leaflet own styles assigned for all icon markers.\r\n\r\nThis situation is unique for the only 'marker' iconShape option. Icons having other shapes don't have an icon wrapper div as the 'marker' does (because of the code citated in the issue). It is a reason why they behave slightly different and particularly, accept z-index as expected.\r\n"}}
{"actor":{"display_login":"nnseva"}}