diff --git a/autoassign.php b/autoassign.php index 35d874fff..e42a1ba8e 100644 --- a/autoassign.php +++ b/autoassign.php @@ -613,11 +613,12 @@ function divClass($name, $classes = null) { if (!isset($Qreq->q)) { // XXX redundant $Qreq->q = join(" ", $SSel->selection()); } -echo Ht::entry("q", $Qreq->q, - array("id" => "autoassignq", "placeholder" => "(All)", - "size" => 40, "title" => "Enter paper numbers or search terms", - "class" => Ht::control_class("q", "papersearch js-autosubmit need-suggest"), - "data-autosubmit-type" => "requery")), "  in  "; +echo Ht::entry("q", $Qreq->q, [ + "id" => "autoassignq", "placeholder" => "(All)", + "size" => 40, "aria-label" => "Search", + "class" => Ht::control_class("q", "papersearch js-autosubmit need-suggest"), + "data-autosubmit-type" => "requery", "spellcheck" => false + ]), "  in  "; if (count($tOpt) > 1) { echo Ht::select("t", $tOpt, $Qreq->t); } else { diff --git a/conflictassign.php b/conflictassign.php index 9b04d4080..6c481a7f6 100644 --- a/conflictassign.php +++ b/conflictassign.php @@ -3,9 +3,9 @@ // Copyright (c) 2006-2020 Eddie Kohler; see LICENSE. require_once("src/initweb.php"); -require_once("src/papersearch.php"); -if (!$Me->is_manager()) +if (!$Me->is_manager()) { $Me->escape(); +} $Me->add_overrides(Contact::OVERRIDE_CONFLICT); $Conf->header("Assignments", "assignpc", ["subtitle" => "Conflicts"]); diff --git a/graph.php b/graph.php index 865e8044b..64b5db0c4 100644 --- a/graph.php +++ b/graph.php @@ -3,7 +3,6 @@ // Copyright (c) 2006-2020 Eddie Kohler; see LICENSE. require_once("src/initweb.php"); -require_once("src/papersearch.php"); $Graph = $Qreq->g; if (!$Graph @@ -43,7 +42,7 @@ function echo_graph($searchable, $fg, $h2) { echo '
'; if ($searchable) { - echo Ht::entry("q", "", ["placeholder" => "Find on graph", "class" => "uii js-hotgraph-highlight papersearch float-right need-autogrow need-suggest"]); + echo Ht::entry("q", "", ["placeholder" => "Find on graph", "class" => "uii js-hotgraph-highlight papersearch float-right need-autogrow need-suggest", "spellcheck" => false]); } if ($h2) { echo "

", $h2, "

\n"; @@ -70,7 +69,7 @@ function formulas_qrow($i, $q, $s, $status) { $q = ""; } $klass = MessageSet::status_class($status, "papersearch"); - $t = '' . Ht::entry("q$i", $q, array("size" => 40, "placeholder" => "(All)", "class" => $klass, "id" => "q$i")); + $t = '' . Ht::entry("q$i", $q, ["size" => 40, "placeholder" => "(All)", "class" => $klass, "id" => "q$i", "spellcheck" => false]); $t .= " Style:  " . Ht::select("s$i", array("default" => "default", "plain" => "plain", "redtag" => "red", "orangetag" => "orange", "yellowtag" => "yellow", "greentag" => "green", "bluetag" => "blue", "purpletag" => "purple", "graytag" => "gray"), $s !== "" ? $s : "by-tag"); $t .= ' ' . Icons::ui_triangle(0) diff --git a/log.php b/log.php index fb79aae15..ba80add45 100644 --- a/log.php +++ b/log.php @@ -616,7 +616,7 @@ function searchbar(LogRowGenerator $lrg, $page) { '
', Ht::render_feedback_at("p"), - Ht::entry("p", $Qreq->p, ["id" => "p", "class" => "need-suggest papersearch", "autocomplete" => "off", "size" => 40]), + Ht::entry("p", $Qreq->p, ["id" => "p", "class" => "need-suggest papersearch", "autocomplete" => "off", "size" => 40, "spellcheck" => false]), '
', Ht::render_feedback_at("u"), diff --git a/mail.php b/mail.php index 225dd5196..28ee6ea39 100644 --- a/mail.php +++ b/mail.php @@ -3,7 +3,6 @@ // Copyright (c) 2006-2021 Eddie Kohler; see LICENSE. require_once("src/initweb.php"); -require_once("src/papersearch.php"); require_once("src/mailclasses.php"); if (!$Me->is_manager() && !$Me->isPC) { $Me->escape(); @@ -667,10 +666,10 @@ private function run() { else echo 'Papers:  ', Ht::hidden("plimit", 1), ''; -echo Ht::entry("q", (string) $Qreq->q, - array("id" => "q", "placeholder" => "(All)", - "class" => "papersearch need-suggest", "size" => 36)), - "  in "; +echo Ht::entry("q", (string) $Qreq->q, [ + "id" => "q", "placeholder" => "(All)", "spellcheck" => false, + "class" => "papersearch need-suggest", "size" => 36 + ]), "  in "; if (count($tOpt) == 1) { echo htmlspecialchars($tOpt[$Qreq->t]); } else { diff --git a/manualassign.php b/manualassign.php index e947a02b7..728cfd40b 100644 --- a/manualassign.php +++ b/manualassign.php @@ -3,7 +3,6 @@ // Copyright (c) 2006-2021 Eddie Kohler; see LICENSE. require_once("src/initweb.php"); -require_once("src/papersearch.php"); if (!$Me->is_manager()) { $Me->escape(); } @@ -173,10 +172,11 @@ function saveAssignments($qreq, $reviewer) { // Paper selection echo "Paper selection:  ", - Ht::entry("q", $Qreq->q, - ["id" => "manualassignq", "size" => 40, "placeholder" => "(All)", - "title" => "Paper numbers or search terms"]), - "  in  "; + Ht::entry("q", $Qreq->q, [ + "id" => "manualassignq", "size" => 40, "placeholder" => "(All)", + "class" => "papersearch want-focus need-suggest", "aria-label" => "Search", + "spellcheck" => false + ]), "  in  "; if (count($tOpt) > 1) { echo Ht::select("t", $tOpt, $Qreq->t); } else { diff --git a/reviewprefs.php b/reviewprefs.php index ca154a23d..ad294ab55 100644 --- a/reviewprefs.php +++ b/reviewprefs.php @@ -3,7 +3,6 @@ // Copyright (c) 2006-2021 Eddie Kohler; see LICENSE. require_once("src/initweb.php"); -require_once("src/papersearch.php"); if (!$Me->privChair && !$Me->isPC) { $Me->escape(); } @@ -282,8 +281,10 @@ function parseUploadedPreferences($text, $filename, $apply) { } echo '
', - Ht::entry("q", $Qreq->q, ["id" => "htctl-prefs-q", "size" => 32]), - '  ', Ht::submit("redisplay", "Redisplay"), '
'; + Ht::entry("q", $Qreq->q, [ + "id" => "htctl-prefs-q", "size" => 32, "placeholder" => "(All)", + "class" => "papersearch want-focus need-suggest", "spellcheck" => false + ]), '  ', Ht::submit("redisplay", "Redisplay"), '
'; function show_pref_element($pl, $name, $text, $extra = []) { return '
  • is_empty()) { $Me->escape(); } @@ -308,11 +307,11 @@ function checkbox_item($column, $type, $title, $options = []) { '
    ', Ht::select("qt", $qtOpt, $Qreq->get("qt", "n"), ["id" => "htctl-advanced-qt"]), '
    ', '
    ', - Ht::entry("qa", $Qreq->get("qa", $Qreq->get("q", "")), ["id" => "htctl-advanced-qa", "size" => 60, "class" => "papersearch want-focus need-suggest"]), '
    ', + Ht::entry("qa", $Qreq->get("qa", $Qreq->get("q", "")), ["id" => "htctl-advanced-qa", "size" => 60, "class" => "papersearch want-focus need-suggest", "spellcheck" => false]), '', '
    ', - Ht::entry("qo", $Qreq->get("qo", ""), ["id" => "htctl-advanced-qo", "size" => 60]), '
    ', + Ht::entry("qo", $Qreq->get("qo", ""), ["id" => "htctl-advanced-qo", "size" => 60, "spellcheck" => false]), '', '
    ', - Ht::entry("qx", $Qreq->get("qx", ""), ["id" => "htctl-advanced-qx", "size" => 60]), '
    '; + Ht::entry("qx", $Qreq->get("qx", ""), ["id" => "htctl-advanced-qx", "size" => 60, "spellcheck" => false]), ''; if (!$Search->limit_explicit()) { echo '
    ', PaperSearch::limit_selector($tOpt, $Search->limit(), ["id" => "htctl-advanced-q"]), '
    '; diff --git a/src/helpers.php b/src/helpers.php index 2a3cdc4ab..ef7b1261c 100644 --- a/src/helpers.php +++ b/src/helpers.php @@ -252,9 +252,9 @@ function goPaperForm($baseUrl = null, $args = array()) { $list = Conf::$main->active_list(); $x = Ht::form(Conf::$main->hoturl($baseUrl ? : "paper"), ["method" => "get", "class" => "gopaper"]); if ($baseUrl == "profile") { - $x .= Ht::entry("u", "", array("id" => "quicklink-search", "size" => 15, "placeholder" => "User search", "aria-label" => "User search", "class" => "usersearch need-autogrow")); + $x .= Ht::entry("u", "", ["id" => "quicklink-search", "size" => 15, "placeholder" => "User search", "aria-label" => "User search", "class" => "usersearch need-autogrow", "spellcheck" => false]); } else { - $x .= Ht::entry("p", "", array("id" => "quicklink-search", "size" => 10, "placeholder" => "(All)", "aria-label" => "Search", "class" => "papersearch need-suggest need-autogrow")); + $x .= Ht::entry("p", "", ["id" => "quicklink-search", "size" => 10, "placeholder" => "(All)", "aria-label" => "Search", "class" => "papersearch need-suggest need-autogrow", "spellcheck" => false]); } foreach ($args as $k => $v) { $x .= Ht::hidden($k, $v); diff --git a/src/partials/p_home.php b/src/partials/p_home.php index 1185c52b4..efbf31378 100644 --- a/src/partials/p_home.php +++ b/src/partials/p_home.php @@ -167,7 +167,7 @@ function render_search(Contact $user, Qrequest $qreq, $gx) { Ht::entry("q", (string) $qreq->q, [ "id" => "homeq", "size" => 32, "title" => "Enter paper numbers or search terms", "class" => "papersearch need-suggest flex-grow-1", - "placeholder" => "(All)", + "placeholder" => "(All)", "spellcheck" => false, "aria-labelledby" => "homesearch-label" ]), '
    in ', PaperSearch::limit_selector($tOpt, key($tOpt), ["class" => "ml-1"]), diff --git a/src/settings/s_reviewform.php b/src/settings/s_reviewform.php index eaeff27c3..ce69d888c 100644 --- a/src/settings/s_reviewform.php +++ b/src/settings/s_reviewform.php @@ -602,7 +602,7 @@ static function render_presence_property(SettingValues $sv, ReviewField $f, $xpo . Ht::select("rf_{$xpos}_ec", $ecsel, $ecv, ["id" => "rf_{$xpos}_ec", "class" => "uich js-foldup"]) . '  ' . Ht::entry("rf_{$xpos}_ecs", $ecs, - $sv->sjs("rf_{$xpos}_ecs", ["class" => "papersearch fx need-autogrow need-tooltip", "placeholder" => "Search", "data-tooltip-info" => "settings-review-form", "data-tooltip-type" => "focus", "size" => 30])) + $sv->sjs("rf_{$xpos}_ecs", ["class" => "papersearch fx need-autogrow need-tooltip", "placeholder" => "Search", "data-tooltip-info" => "settings-review-form", "data-tooltip-type" => "focus", "size" => 30, "spellcheck" => false])) . '
    '; }