{"action":"created","issue":{"url":"https://api.github.com/repos/elastic/kibana/issues/26092","repository_url":"https://api.github.com/repos/elastic/kibana","labels_url":"https://api.github.com/repos/elastic/kibana/issues/26092/labels{/name}","comments_url":"https://api.github.com/repos/elastic/kibana/issues/26092/comments","events_url":"https://api.github.com/repos/elastic/kibana/issues/26092/events","html_url":"https://github.com/elastic/kibana/pull/26092","id":383571306,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMzMDA3NjYz","number":26092,"title":"[Layout Engine] Feat: add self-snapping of canvas elements","user":{"login":"monfera","id":1548516,"node_id":"MDQ6VXNlcjE1NDg1MTY=","avatar_url":"https://avatars0.githubusercontent.com/u/1548516?v=4","gravatar_id":"","url":"https://api.github.com/users/monfera","html_url":"https://github.com/monfera","followers_url":"https://api.github.com/users/monfera/followers","following_url":"https://api.github.com/users/monfera/following{/other_user}","gists_url":"https://api.github.com/users/monfera/gists{/gist_id}","starred_url":"https://api.github.com/users/monfera/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/monfera/subscriptions","organizations_url":"https://api.github.com/users/monfera/orgs","repos_url":"https://api.github.com/users/monfera/repos","events_url":"https://api.github.com/users/monfera/events{/privacy}","received_events_url":"https://api.github.com/users/monfera/received_events","type":"User","site_admin":false},"labels":[{"id":912981985,"node_id":"MDU6TGFiZWw5MTI5ODE5ODU=","url":"https://api.github.com/repos/elastic/kibana/labels/:Canvas","name":":Canvas","color":"fef2c0","default":false},{"id":135307740,"node_id":"MDU6TGFiZWwxMzUzMDc3NDA=","url":"https://api.github.com/repos/elastic/kibana/labels/review","name":"review","color":"0052cc","default":false}],"state":"closed","locked":false,"assignee":{"login":"monfera","id":1548516,"node_id":"MDQ6VXNlcjE1NDg1MTY=","avatar_url":"https://avatars0.githubusercontent.com/u/1548516?v=4","gravatar_id":"","url":"https://api.github.com/users/monfera","html_url":"https://github.com/monfera","followers_url":"https://api.github.com/users/monfera/followers","following_url":"https://api.github.com/users/monfera/following{/other_user}","gists_url":"https://api.github.com/users/monfera/gists{/gist_id}","starred_url":"https://api.github.com/users/monfera/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/monfera/subscriptions","organizations_url":"https://api.github.com/users/monfera/orgs","repos_url":"https://api.github.com/users/monfera/repos","events_url":"https://api.github.com/users/monfera/events{/privacy}","received_events_url":"https://api.github.com/users/monfera/received_events","type":"User","site_admin":false},"assignees":[{"login":"monfera","id":1548516,"node_id":"MDQ6VXNlcjE1NDg1MTY=","avatar_url":"https://avatars0.githubusercontent.com/u/1548516?v=4","gravatar_id":"","url":"https://api.github.com/users/monfera","html_url":"https://github.com/monfera","followers_url":"https://api.github.com/users/monfera/followers","following_url":"https://api.github.com/users/monfera/following{/other_user}","gists_url":"https://api.github.com/users/monfera/gists{/gist_id}","starred_url":"https://api.github.com/users/monfera/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/monfera/subscriptions","organizations_url":"https://api.github.com/users/monfera/orgs","repos_url":"https://api.github.com/users/monfera/repos","events_url":"https://api.github.com/users/monfera/events{/privacy}","received_events_url":"https://api.github.com/users/monfera/received_events","type":"User","site_admin":false}],"milestone":null,"comments":6,"created_at":"2018-11-22T15:01:26Z","updated_at":"2018-11-28T08:57:25Z","closed_at":"2018-11-28T08:56:58Z","author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/elastic/kibana/pulls/26092","html_url":"https://github.com/elastic/kibana/pull/26092","diff_url":"https://github.com/elastic/kibana/pull/26092.diff","patch_url":"https://github.com/elastic/kibana/pull/26092.patch"},"body":"Closes https://github.com/elastic/kibana/issues/23978\r\n\r\n## Summary\r\n\r\nNow, when dragging or resizing a Canvas element, its landmark points snap to landmark X/Y values of other shapes. So far, however, the element hasn't snapped to its former self. Reasons for adding self-snapping with this PR:\r\n\r\n1. Comparable software does it too\r\n2. A main purpose is that an element selection do not introduce an accidental drag of a couple of pixels\r\n3. It's also good to let users exactly reposition the element to its original place (without relying undo, ie. another way for achieving a rollback)\r\n4. Often, the user may want to purposefully move the element such that only the X or Y values would change; we'll eventually have a modifier key but it helps to have this means too\r\n\r\nAs with snapping in general, it can be deactivated with `Command` on the mac or `Alt` on the PC (the snap lines still show).\r\n\r\nA future PR may add an actual indicator border for the former place of the element. But it'd be useful to merge as is, because every accidental minor drag&drop incurred on element selection incurs network traffic. So this issue partly addresses performance issues reported by @timroes \r\n\r\n![selfsnap](https://user-images.githubusercontent.com/1548516/48910147-78c8b480-ee6f-11e8-8d11-f1c58dd2bb4c.gif)\r\n\r\ncc: @ryankeairns @alexfrancoeur \r\n\r\n### Checklist\r\n\r\nUse ~~strikethroughs~~ to remove checklist items you don't feel are applicable to this PR.\r\n\r\n- [X] This was checked for cross-browser compatibility, [including a check against IE11](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility)\r\n~~- [ ] Any text added follows [EUI's writing guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses sentence case text and includes [i18n support](https://github.com/elastic/kibana/blob/master/packages/kbn-i18n/README.md)~~\r\n~~- [ ] [Documentation](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#writing-documentation) was added for features that require explanation or tutorials~~\r\n~~- [ ] [Unit or functional tests](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility) were updated or added to match the most common scenarios~~\r\n~~- [ ] This was checked for [keyboard-only and screenreader accessibility](https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Accessibility#Accessibility_testing_checklist)~~\r\n\r\n### For maintainers\r\n\r\n~~- [ ] This was checked for breaking API changes and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)~~\r\n~~- [ ] This includes a feature addition or change that requires a release note and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)~~\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/elastic/kibana/issues/comments/442369510","html_url":"https://github.com/elastic/kibana/pull/26092#issuecomment-442369510","issue_url":"https://api.github.com/repos/elastic/kibana/issues/26092","id":442369510,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0MjM2OTUxMA==","user":{"login":"monfera","id":1548516,"node_id":"MDQ6VXNlcjE1NDg1MTY=","avatar_url":"https://avatars0.githubusercontent.com/u/1548516?v=4","gravatar_id":"","url":"https://api.github.com/users/monfera","html_url":"https://github.com/monfera","followers_url":"https://api.github.com/users/monfera/followers","following_url":"https://api.github.com/users/monfera/following{/other_user}","gists_url":"https://api.github.com/users/monfera/gists{/gist_id}","starred_url":"https://api.github.com/users/monfera/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/monfera/subscriptions","organizations_url":"https://api.github.com/users/monfera/orgs","repos_url":"https://api.github.com/users/monfera/repos","events_url":"https://api.github.com/users/monfera/events{/privacy}","received_events_url":"https://api.github.com/users/monfera/received_events","type":"User","site_admin":false},"created_at":"2018-11-28T08:57:25Z","updated_at":"2018-11-28T08:57:25Z","author_association":"MEMBER","body":"@rashidkpc @timroes should it be backported to 6.5 and 6.x?"}}
{"actor":{"display_login":"monfera"}}