Mercurial > public > mercurial-scm > hg
diff tests/test-hgweb-filelog.t @ 32758:cba4461aa0a0
hgweb: consolidate search form for paper
AFAICT this was mostly a bunch of copy pasta. The only variation is
some pages defined a "value" attribute. The "query" variable will
just be empty on pages that don't accept it. So let's consolidate
the template and remove the redundancy.
author | Gregory Szorc <gregory.szorc@gmail.com> |
---|---|
date | Fri, 09 Jun 2017 13:59:13 -0700 |
parents | befefdd34cf8 |
children | 9acc0360ff67 |
line wrap: on
line diff
--- a/tests/test-hgweb-filelog.t Fri Jun 09 23:56:50 2017 -0400 +++ b/tests/test-hgweb-filelog.t Fri Jun 09 13:59:13 2017 -0700 @@ -193,9 +193,10 @@ </h3> + <form class="search" action="/log"> - <p><input name="rev" id="search1" type="text" size="30" /></p> + <p><input name="rev" id="search1" type="text" size="30" value="" /></p> <div id="hint">Find changesets by keywords (author, files, the commit message), revision number or hash, or <a href="/help/revsets">revset expression</a>.</div> </form> @@ -315,9 +316,10 @@ </h3> + <form class="search" action="/log"> - <p><input name="rev" id="search1" type="text" size="30" /></p> + <p><input name="rev" id="search1" type="text" size="30" value="" /></p> <div id="hint">Find changesets by keywords (author, files, the commit message), revision number or hash, or <a href="/help/revsets">revset expression</a>.</div> </form> @@ -437,9 +439,10 @@ </h3> + <form class="search" action="/log"> - <p><input name="rev" id="search1" type="text" size="30" /></p> + <p><input name="rev" id="search1" type="text" size="30" value="" /></p> <div id="hint">Find changesets by keywords (author, files, the commit message), revision number or hash, or <a href="/help/revsets">revset expression</a>.</div> </form> @@ -550,9 +553,10 @@ </h3> + <form class="search" action="/log"> - <p><input name="rev" id="search1" type="text" size="30" /></p> + <p><input name="rev" id="search1" type="text" size="30" value="" /></p> <div id="hint">Find changesets by keywords (author, files, the commit message), revision number or hash, or <a href="/help/revsets">revset expression</a>.</div> </form> @@ -639,9 +643,10 @@ <h2 class="breadcrumb"><a href="/">Mercurial</a> </h2> <h3>error</h3> + <form class="search" action="/log"> - <p><input name="rev" id="search1" type="text" size="30"></p> + <p><input name="rev" id="search1" type="text" size="30" value="" /></p> <div id="hint">Find changesets by keywords (author, files, the commit message), revision number or hash, or <a href="/help/revsets">revset expression</a>.</div> </form> @@ -739,9 +744,10 @@ (following lines 1:2 <a href="/log/tip/c">back to filelog</a>) </h3> + <form class="search" action="/log"> - <p><input name="rev" id="search1" type="text" size="30" /></p> + <p><input name="rev" id="search1" type="text" size="30" value="" /></p> <div id="hint">Find changesets by keywords (author, files, the commit message), revision number or hash, or <a href="/help/revsets">revset expression</a>.</div> </form> @@ -858,9 +864,10 @@ (following lines 1:2 <a href="/log/tip/c?revcount=1">back to filelog</a>) </h3> + <form class="search" action="/log"> <input type="hidden" name="revcount" value="1" /> - <p><input name="rev" id="search1" type="text" size="30" /></p> + <p><input name="rev" id="search1" type="text" size="30" value="" /></p> <div id="hint">Find changesets by keywords (author, files, the commit message), revision number or hash, or <a href="/help/revsets">revset expression</a>.</div> </form> @@ -1094,9 +1101,10 @@ </h3> + <form class="search" action="/log"> - <p><input name="rev" id="search1" type="text" size="30" /></p> + <p><input name="rev" id="search1" type="text" size="30" value="" /></p> <div id="hint">Find changesets by keywords (author, files, the commit message), revision number or hash, or <a href="/help/revsets">revset expression</a>.</div> </form> @@ -1375,9 +1383,10 @@ (following lines 3:4 <a href="/log/tip/c">back to filelog</a>) </h3> + <form class="search" action="/log"> - <p><input name="rev" id="search1" type="text" size="30" /></p> + <p><input name="rev" id="search1" type="text" size="30" value="" /></p> <div id="hint">Find changesets by keywords (author, files, the commit message), revision number or hash, or <a href="/help/revsets">revset expression</a>.</div> </form> @@ -1631,9 +1640,10 @@ (following lines 3:4, descending <a href="/log/8/c">back to filelog</a>) </h3> + <form class="search" action="/log"> - <p><input name="rev" id="search1" type="text" size="30" /></p> + <p><input name="rev" id="search1" type="text" size="30" value="" /></p> <div id="hint">Find changesets by keywords (author, files, the commit message), revision number or hash, or <a href="/help/revsets">revset expression</a>.</div> </form>