fix misplaced minLength; decrease minLength to 1
This commit is contained in:
@@ -13,6 +13,7 @@
|
|||||||
|
|
||||||
Danbooru.Artist.initialize_auto_complete = function() {
|
Danbooru.Artist.initialize_auto_complete = function() {
|
||||||
$("#quick_search_name").autocomplete({
|
$("#quick_search_name").autocomplete({
|
||||||
|
minLength: 1,
|
||||||
source: function(req, resp) {
|
source: function(req, resp) {
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: "/artists.json",
|
url: "/artists.json",
|
||||||
@@ -20,7 +21,6 @@
|
|||||||
"search[name]": "*" + req.term + "*"
|
"search[name]": "*" + req.term + "*"
|
||||||
},
|
},
|
||||||
method: "get",
|
method: "get",
|
||||||
minLength: 2,
|
|
||||||
success: function(data) {
|
success: function(data) {
|
||||||
resp($.map(data, function(tag) {
|
resp($.map(data, function(tag) {
|
||||||
return {
|
return {
|
||||||
|
|||||||
@@ -15,6 +15,7 @@
|
|||||||
$("#add-to-pool-dialog").dialog({autoOpen: false});
|
$("#add-to-pool-dialog").dialog({autoOpen: false});
|
||||||
|
|
||||||
$("#c-pool-elements #a-new input[type=text]").autocomplete({
|
$("#c-pool-elements #a-new input[type=text]").autocomplete({
|
||||||
|
minLength: 1,
|
||||||
source: function(req, resp) {
|
source: function(req, resp) {
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: "/pools.json",
|
url: "/pools.json",
|
||||||
@@ -23,7 +24,6 @@
|
|||||||
"search[name_matches]": req.term
|
"search[name_matches]": req.term
|
||||||
},
|
},
|
||||||
method: "get",
|
method: "get",
|
||||||
minLength: 2,
|
|
||||||
success: function(data) {
|
success: function(data) {
|
||||||
resp($.map(data, function(tag) {
|
resp($.map(data, function(tag) {
|
||||||
return {
|
return {
|
||||||
|
|||||||
@@ -37,6 +37,7 @@
|
|||||||
|
|
||||||
Danbooru.Post.initialize_tag_autocomplete = function() {
|
Danbooru.Post.initialize_tag_autocomplete = function() {
|
||||||
$("#tags,#post_tag_string,#upload_tag_string").autocomplete({
|
$("#tags,#post_tag_string,#upload_tag_string").autocomplete({
|
||||||
|
minLength: 1,
|
||||||
focus: function() {
|
focus: function() {
|
||||||
return false;
|
return false;
|
||||||
},
|
},
|
||||||
@@ -56,7 +57,6 @@
|
|||||||
"search[name_matches]": term + "*"
|
"search[name_matches]": term + "*"
|
||||||
},
|
},
|
||||||
method: "get",
|
method: "get",
|
||||||
minLength: 2,
|
|
||||||
success: function(data) {
|
success: function(data) {
|
||||||
resp($.map(data, function(tag) {
|
resp($.map(data, function(tag) {
|
||||||
return {
|
return {
|
||||||
|
|||||||
@@ -10,6 +10,7 @@
|
|||||||
Danbooru.WikiPage.initialize_typeahead = function() {
|
Danbooru.WikiPage.initialize_typeahead = function() {
|
||||||
if (Danbooru.meta("enable-auto-complete") === "true") {
|
if (Danbooru.meta("enable-auto-complete") === "true") {
|
||||||
$("#quick_search_title,#wiki_page_title").autocomplete({
|
$("#quick_search_title,#wiki_page_title").autocomplete({
|
||||||
|
minLength: 1,
|
||||||
source: function(req, resp) {
|
source: function(req, resp) {
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: "/wiki_pages.json",
|
url: "/wiki_pages.json",
|
||||||
@@ -17,7 +18,6 @@
|
|||||||
"search[title]": "*" + req.term + "*"
|
"search[title]": "*" + req.term + "*"
|
||||||
},
|
},
|
||||||
method: "get",
|
method: "get",
|
||||||
minLength: 2,
|
|
||||||
success: function(data) {
|
success: function(data) {
|
||||||
resp($.map(data, function(tag) {
|
resp($.map(data, function(tag) {
|
||||||
return {
|
return {
|
||||||
|
|||||||
Reference in New Issue
Block a user