From 069222749604e967e8a6bda0d5e02fdb70ffb939 Mon Sep 17 00:00:00 2001 From: Ben Kurtovic Date: Wed, 20 Jan 2016 00:13:54 -0600 Subject: [PATCH] Cleanup/tweaks, mainly to rendering. --- README.md | 1 + copyvios/turnitin.py | 2 +- static/style.css | 11 +++++------ templates/index.mako | 12 +++++++----- 4 files changed, 14 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index 7d7992d..f4dd625 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,7 @@ Dependencies * [mako](http://www.makotemplates.org/) >= 0.7.2 * [mwparserfromhell](https://github.com/earwig/mwparserfromhell) >= 0.3 * [oursql](http://packages.python.org/oursql/) >= 0.9.3.1 +* [requests](http://python-requests.org/) >= 2.9.1 * [SQLAlchemy](http://sqlalchemy.org/) >= 0.9.6 * [uglifycss](https://github.com/fmarcia/UglifyCSS/) * [uglifyjs](https://github.com/mishoo/UglifyJS/) >= 1.3.3 diff --git a/copyvios/turnitin.py b/copyvios/turnitin.py index 72568c6..1b6c5fe 100644 --- a/copyvios/turnitin.py +++ b/copyvios/turnitin.py @@ -31,7 +31,7 @@ def _make_api_request(page_title, lang): 'report': 1} result = requests.get(TURNITIN_API_ENDPOINT, params=api_parameters) - # use literal_eval to *safely* parse the resulting dict-containing string + # use json.loads to *safely* parse the resulting dict-containing string parsed_api_result = json.loads(result.text) return parsed_api_result diff --git a/static/style.css b/static/style.css index 5ff70b9..8233a10 100644 --- a/static/style.css +++ b/static/style.css @@ -111,7 +111,7 @@ table#heading { } table#cv-form-outer { - width: 750px; + width: 800px; } table#cv-form-inner { @@ -314,14 +314,13 @@ input.cv-text { width: 100%; } -input#cv-cb-engine { - margin-left: 0; +input.cv-search { + margin-left: 20px; margin-right: 5px; } -input#cv-cb-links { - margin-left: 20px; - margin-right: 5px; +input.cv-search:first-of-type { + margin-left: 0; } span.cv-hl { diff --git a/templates/index.mako b/templates/index.mako index 0add639..42aaa50 100644 --- a/templates/index.mako +++ b/templates/index.mako @@ -107,15 +107,17 @@ - + - + + - - - + + + +