{"action":"created","issue":{"url":"https://api.github.com/repos/Dimox/jQueryFormStyler/issues/83","labels_url":"https://api.github.com/repos/Dimox/jQueryFormStyler/issues/83/labels{/name}","comments_url":"https://api.github.com/repos/Dimox/jQueryFormStyler/issues/83/comments","events_url":"https://api.github.com/repos/Dimox/jQueryFormStyler/issues/83/events","html_url":"https://github.com/Dimox/jQueryFormStyler/issues/83","id":101889519,"number":83,"title":"Возможность открытия селекта по событию.","user":{"login":"pafnuty","id":1635679,"avatar_url":"https://avatars.githubusercontent.com/u/1635679?v=3","gravatar_id":"","url":"https://api.github.com/users/pafnuty","html_url":"https://github.com/pafnuty","followers_url":"https://api.github.com/users/pafnuty/followers","following_url":"https://api.github.com/users/pafnuty/following{/other_user}","gists_url":"https://api.github.com/users/pafnuty/gists{/gist_id}","starred_url":"https://api.github.com/users/pafnuty/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pafnuty/subscriptions","organizations_url":"https://api.github.com/users/pafnuty/orgs","repos_url":"https://api.github.com/users/pafnuty/repos","events_url":"https://api.github.com/users/pafnuty/events{/privacy}","received_events_url":"https://api.github.com/users/pafnuty/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-08-19T13:12:02Z","updated_at":"2015-09-05T12:24:25Z","closed_at":null,"body":"Хотел сегодня реализовать открытие селекта при нажатии на кнопку (физически это спан), для чего попробовал в консольке код:\r\n`$('#city-styler .jq-selectbox__select').trigger('click');`? как и ожидалось селект открылся, однако, при пользовательском действии такой трюк не сработал:\r\n```javascript\r\n$(document).on('click', '.city', function () {\r\n\t$('#city-styler .jq-selectbox__select').trigger('click');\r\n});\r\n```\r\n\r\nТоже самое происходит с [демкой](http://dimox.github.io/jQueryFormStyler/demo/#select):\r\n`$('.width-auto .jq-selectbox__select').trigger('click');` так в консоли работает, а вот так (прямо в консоль писал) нет:\r\n```\r\n$(document).on('click', '.add-select', function () {\r\n\t$('.width-auto .jq-selectbox__select').trigger('click');\r\n\tconsole.log('кнопка действительно нажата');\r\n});\r\n```\r\n\r\nПризняться я теряюсь в догадках."},"comment":{"url":"https://api.github.com/repos/Dimox/jQueryFormStyler/issues/comments/137949072","html_url":"https://github.com/Dimox/jQueryFormStyler/issues/83#issuecomment-137949072","issue_url":"https://api.github.com/repos/Dimox/jQueryFormStyler/issues/83","id":137949072,"user":{"login":"Dimox","id":2348058,"avatar_url":"https://avatars.githubusercontent.com/u/2348058?v=3","gravatar_id":"","url":"https://api.github.com/users/Dimox","html_url":"https://github.com/Dimox","followers_url":"https://api.github.com/users/Dimox/followers","following_url":"https://api.github.com/users/Dimox/following{/other_user}","gists_url":"https://api.github.com/users/Dimox/gists{/gist_id}","starred_url":"https://api.github.com/users/Dimox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Dimox/subscriptions","organizations_url":"https://api.github.com/users/Dimox/orgs","repos_url":"https://api.github.com/users/Dimox/repos","events_url":"https://api.github.com/users/Dimox/events{/privacy}","received_events_url":"https://api.github.com/users/Dimox/received_events","type":"User","site_admin":false},"created_at":"2015-09-05T12:24:25Z","updated_at":"2015-09-05T12:24:25Z","body":"Так-с, интересно получается. Когда запускаем твой код, селект на самом деле открывается, но, поскольку дальше срабатывает функция \"прячем выпадающий список при клике за пределами селекта\", то селект сразу же и закрывается =)\r\n\r\nНужно придумать, как это дело обойти."}}