Преглед на файлове

Input field for specifying a revision ID.

pull/24/head
Ben Kurtovic преди 11 години
родител
ревизия
c1810ee269
променени са 3 файла, в които са добавени 65 реда и са изтрити 36 реда
  1. +39
    -24
      pages/index.mako
  2. +1
    -2
      pages/settings.mako
  3. +25
    -10
      static/style.css

+ 39
- 24
pages/index.mako Целия файл

@@ -19,10 +19,10 @@
<p>This tool attempts to detect <a href="//en.wikipedia.org/wiki/WP:COPYVIO">copyright violations</a> in articles. Simply give the title of the page or ID of the revision you want to check and hit Submit. The tool will search for similar content elsewhere on the web and display a report if a match is found. If you also provide a URL, it will not query any search engines and instead display a report comparing the article to that particular webpage, like the <a href="//toolserver.org/~dcoetzee/duplicationdetector/">Duplication Detector</a>. Check out the <a href="//en.wikipedia.org/wiki/User:EarwigBot/Copyvios/FAQ">FAQ</a> for more information and technical details.</p>
<p><i>Note:</i> The tool is still in beta. You are completely welcome to use it and provide <a href="//en.wikipedia.org/wiki/User_talk:The_Earwig">feedback</a>, but be aware that it may produce strange or broken results.</p>
<form action="${environ['SCRIPT_URL']}" method="get">
<table>
<table id="cv-form">
<tr>
<td>Site:</td>
<td>
<td colspan="3">
<span class="mono">http://</span>
<select name="lang">
<% selected_lang = query.orig_lang if query.orig_lang else cookies["CopyviosDefaultLang"].value if "CopyviosDefaultLang" in cookies else bot.wiki.get_site().lang %>\
@@ -49,36 +49,51 @@
</td>
</tr>
<tr>
<td>Page title:</td>
% if page:
<td><input type="text" name="title" size="60" value="${page.title | h}" /></td>
% elif query.title:
<td><input type="text" name="title" size="60" value="${query.title | h}" /></td>
% else:
<td><input type="text" name="title" size="60" /></td>
% endif
<td id="cv-col1">Page&nbsp;title:</td>
<td id="cv-col2">
% if page:
<input class="cv-text" type="text" name="title" value="${page.title | h}" />
% elif query.title:
<input class="cv-text" type="text" name="title" value="${query.title | h}" />
% else:
<input class="cv-text" type="text" name="title" />
% endif
</td>
<td id="cv-col3">or&nbsp;revision&nbsp;ID:</td>
<td id="cv-col4">
% if query.oldid:
<input class="cv-text" type="text" name="oldid" value="${query.oldid | h}" />
% else:
<input class="cv-text" type="text" name="oldid" />
%endif
</td>
</tr>
<tr>
<td>URL (optional):</td>
% if query.url:
<td><input type="text" name="url" size="120" value="${query.url | h}" /></td>
% else:
<td><input type="text" name="url" size="120" /></td>
% endif
<td>URL&nbsp;(optional):</td>
<td colspan="3">
% if query.url:
<input class="cv-text" type="text" name="url" value="${query.url | h}" />
% else:
<input class="cv-text" type="text" name="url" />
% endif
</td>
</tr>
% if query.nocache or (result and result.cached):
<tr>
<td>Bypass cache:</td>
% if query.nocache:
<td><input type="checkbox" name="nocache" value="1" checked="checked" /></td>
% else:
<td><input type="checkbox" name="nocache" value="1" /></td>
% endif
<td>Bypass&nbsp;cache:</td>
<td colspan="3">
% if query.nocache:
<input type="checkbox" name="nocache" value="1" checked="checked" />
% else:
<input type="checkbox" name="nocache" value="1" />
% endif
</td>
</tr>
% endif
<tr>
<td><button type="submit">Submit</button></td>
<td></td>
<td colspan="4">
<button type="submit">Submit</button>
</td>
</tr>
</table>
</form>


+ 1
- 2
pages/settings.mako Целия файл

@@ -60,11 +60,10 @@
</tr>
% endfor
<tr>
<td>
<td colspan="2">
<input type="hidden" name="action" value="set"/>
<button type="submit">Save</button>
</td>
<td></td>
</tr>
</table>
</form>


+ 25
- 10
static/style.css Целия файл

@@ -78,11 +78,32 @@ p#links {
margin: 8px 0 10px 0;
}

table#cv-form {
width: 750px;
}

table#cv-chain-table {
width: 100%;
border-spacing: 10px;
}

td#cv-col1 {
width: 15%;
}

td#cv-col2 {
width: 55%;
}

td#cv-col3 {
width: 15%;
text-align: center;
}

td#cv-col4 {
width: 15%;
}

h2#cv-result-header {
margin-bottom: 0;
}
@@ -149,21 +170,15 @@ div.cv-chain-detail {
border: 1px solid #BBB;
}

p.toolname {
font-size: 18px;
margin: 6px 0 6px 0;
background-color: #E7E7E7;
}

p.tooldesc {
margin: 6px 0 6px 0;
}

td.cv-chain-cell {
width: 50%;
vertical-align: top;
}

input.cv-text {
width: 100%;
}

span.cv-hl {
background: #FAA;
}


Зареждане…
Отказ
Запис