I made a chrome extension where if certain conditions occur it navigates you to logging page. Chrome automatically fills input fields with saved login and password, and content script clicks "login" button, but the page states that "login and password field can't be empty". Script that executes on this page is just: document.getElementById('submit_button').click();. I tried making script wait few seconds before executing, but it doesn't help. Is chrome prohibiting script to login with saved login details? Is there some workaroud, to force chrome to behave the same way as a user would click login button manually?
EDIT: Fields are filled in by chrome before my script clicks login, and I tried to focus/click any input field.