{"action":"opened","issue":{"url":"https://api.github.com/repos/ichord/At.js/issues/282","labels_url":"https://api.github.com/repos/ichord/At.js/issues/282/labels{/name}","comments_url":"https://api.github.com/repos/ichord/At.js/issues/282/comments","events_url":"https://api.github.com/repos/ichord/At.js/issues/282/events","html_url":"https://github.com/ichord/At.js/issues/282","id":72127008,"number":282,"title":"Callback will brake At.js","user":{"login":"RokSiEu","id":2094036,"avatar_url":"https://avatars.githubusercontent.com/u/2094036?v=3","gravatar_id":"","url":"https://api.github.com/users/RokSiEu","html_url":"https://github.com/RokSiEu","followers_url":"https://api.github.com/users/RokSiEu/followers","following_url":"https://api.github.com/users/RokSiEu/following{/other_user}","gists_url":"https://api.github.com/users/RokSiEu/gists{/gist_id}","starred_url":"https://api.github.com/users/RokSiEu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RokSiEu/subscriptions","organizations_url":"https://api.github.com/users/RokSiEu/orgs","repos_url":"https://api.github.com/users/RokSiEu/repos","events_url":"https://api.github.com/users/RokSiEu/events{/privacy}","received_events_url":"https://api.github.com/users/RokSiEu/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-04-30T10:52:13Z","updated_at":"2015-04-30T10:52:13Z","closed_at":null,"body":"When using callback beforeInsert it won't insert selected values into editable text field.\r\n\r\nCode:\r\n```\r\n$(function(){\r\nvar names = [\"Jacob\",\"Isabella\",\"Ethan\",\"Emma\",\"Michael\",\"Olivia\",\"Alexander\",\"Sophia\",\"William\",\"Ava\",\"Joshua\",\"Emily\",\"Daniel\",\"Madison\",\"Jayden\",\"Abigail\",\"Noah\",\"Chloe\",\"你好\",\"你你你\",];\r\n  var at_config = {\r\n      at: \"@\",\r\n      data: names,\r\n      displayTpl: \"<li>${name}</li>\",\r\n      limit: 200,\r\n      callbacks: {\r\n      beforeInsert: function(value, $li)\r\n      {\r\n        console.log(value); //value in console is OK! \r\n      } \r\n    }, \r\n    }\r\n  \r\n   $('.note-editable').atwho(at_config);\r\n   \r\n  });\r\n```\r\n\r\nSteps to reproduce:\r\n1. use above code\r\n2. type \"Jac\" and press \"tab\",enter or mouse click on selected item\r\n3. In .note-editable only \"jac\" will be inserted without missing part \"ob\""}}