Skip to content

Focus after input text delete #8

@grlicaa

Description

@grlicaa

Problem was because IE has option icon "X" to empty input field.
Due to that legacy code bug appears.

In order to fix bug you have 2 options :

  1. Add additional code inside plug-in file :"searchNavMenu.js"
    image
	//----- Clear field IE problem, it's not on KEYUP
	$("input.srch_input").bind('input propertychange', function(e, pageEvent) {
		if (this.value == "") {
			var currItem = document.activeElement;
			setCurrentNav(item_id);
			if (!pageEvent)
				saveSesSateNav(""); 
			if (SNMOptions.UseFocus)
				currItem.focus();			
			else
				$(this).focus();
		}
	});
  1. Or option if you will not use anymore IE 11 even better in that case remove that part of code :
    image

In next release issue will be fixed with first option. (release > 2.1)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions