1. guillermooo
  2. stindex

Commits

guillermooo  committed 9082ea5

html looks a wee bit better now.

  • Participants
  • Parent commits 4c1ba7f
  • Branches default

Comments (0)

Files changed (7)

File packageindex/forms.py

View file
 from repoparsers.parsers import parse
 
 class AddPackageForm(forms.ModelForm):
+    checkout_url = forms.CharField(label="Repository url")
 
     class Meta:
         model = STPackage

File static_media/main.css

View file
 body {
     font-family: Arial;
     font-size: 14pt;
+    padding-left: 1em;
 }
 
 
 /* Navigation top-left. */
 ul.nav {
     padding: 0;
-    margin: 0;
+    margin-bottom: 1em;
+    margin-left: 0;
 }
 
 .nav li {
     display: inline;
-    margin-right: .50em;
+/*    margin-right: .50em;*/
+}
+
+.nav span.sep {
+    padding-left: 0.25em;
+    padding-right: 0.25em;
 }
 
 
     border-top: 1px solid gray;
 }
 
-input.search {
-    font-size: 30;
+.search {
+    font-size: 25px;
 }
 
+.search input {
+    font-size: 25px;
+}
+
+.add_form {
+    font-size: 20px;
+}
+
+.add_form input {
+    font-size: 20px;
+}
+
+
+p.checkout_url {
+    font-family: Consolas, Courier New, sans;
+}
+
+
 /* Misc. */
 p.search_help {
     font-size: small;
 
 p.goal {
     font-size: 20px;
-    margin-top: 3em;
-    margin-bottom: 1.5em;
-}
+    margin-top: 2em;
+    margin-bottom: 2em;
+}
+
+p.appeal {
+    font-size: 20px;
+    margin-top: 1.5em;
+    margin-bottom: 3em;
+}

File templates/add_package.html

View file
-<html>
-<head>
-    <title>Sublime Text Info - Add Resource</title>
-    <script type="text/javascript">
+{% extends "base.html" %}
+{% block title %}{{ block.super }} Add Resource{% endblock %}
+
+{% block extrahead %}<script type="text/javascript">
      var RecaptchaOptions = {
         theme : 'clean'
      };
  </script>
-</head>
-<body>
+ {% endblock %}
 
+{% block content%}
 <h1>Add New Resource</h1>
 
-<form action="" method="post">{% csrf_token %}
-    <p>Resources are mainly packages and themes for the Sublime Text editor, but they can also
-    be scripts or anything of value for <a href="http://sublimetext.com">Sublime Text</a> users.
-    </p>
+<p>Resources are mainly packages and themes for the <a href="http://sublimetext.com">Sublime Text</a> editor, but they can also be scripts or anything of value for Sublime Text users.
+</p>
 
-    <p>Resources must meet two requirements:</p>
-    <ul>
-      <li>They must be hosted on a public repository (Bitbucket or Github).</li>
-      <li>Their description field must include the phrase "Sublime Text".</li>
-    </ul>
+<p>Resources must meet two requirements:</p>
+<ul>
+  <li>They must be hosted on a public repository (Bitbucket or Github).</li>
+  <li>Their description field must include the phrase "Sublime Text".</li>
+</ul>
 
+<form class="add_form" action="" method="post">{% csrf_token %}
     {{ form.as_p }}
 
     {% if captcha_error %}
   </noscript>
     <input type="submit" value="Add new resource" />
 </form>
-</body>
-</html>
+{% endblock content %}

File templates/base.html

View file
         <title>{% block title %}Sublime Text Info -{% endblock %}</title>
         <link rel="stylesheet" type="text/css" href="http://yui.yahooapis.com/2.8.1/build/base/base-min.css">
         <link rel="stylesheet" type="text/css" href="/site_media/main.css" />
+        {% block extrahead %}{% endblock %}
     </head>
 
     <body>
         <ul class="nav">
             <li><a href="/">Home</a></li>
-            <li><a href="/packages/">All Resources</a></li>
-            <li><a href="/docs/index.html">Sublime Text Help</a></li>
+            <li><span class="sep"> | </span><a href="/packages/">All Resources</a></li>
+            <li><span class="sep"> | </span><a href="/docs/index.html">Sublime Text Help</a></li>
 <!--             <li><a href="/faq/">FAQ</a></li> -->
 <!--             <li><a href="/about/">About</a></li> -->
         </ul>

File templates/index.html

View file
 	<p class="goal">Resources for <a href="http://www.sublimetext.com">Sublime Text</a> users: packages, themes, documentation and more!<p>
 
 	<form class="search" name="search" action="/packages/search/" method="get">
-		<input class="search" type="text" name="search" id="search_box" autofocus="autofocus" />
+		<input type="text" name="search" id="search_box" autofocus="autofocus" />
 		<input type="submit" value="Search" />
 		<p class="search_help">For documentation, go to <a href="/docs/">Sublime Text Help</a> first.
 	</form>
-	<p>Want to share something useful? <a href="/packages/add/">Add a resource</a>!</p>
+	<p class="appeal">Know something cool you want to share? <a href="/packages/add/">Add a resource</a>!</p>
 	{% endblock content %}

File templates/package_list.html

View file
 {% block title %}{{ block.super }} All Resources{% endblock %}
 
 {% block content %}
-	<form name="search" action="/packages/search/" method="get">
+	<form class="search" name="search" action="/packages/search/" method="get">
 		<input type="text" name="search" id="search_box" autofocus="autofocus" />
 		<input type="submit" value="Search" />
 	</form>

File templates/search_results.html

View file
 {% block title %}{{ block.super }} Search Results{% endblock title %}
 
 {% block content %}
-	<form name="search" action="." method="get">
+	<form class="search" name="search" action="." method="get">
 		<input type="text" name="search" id="search_box" autofocus="autofocus" />
 		<input type="submit" value="Search" />
 	</form>
 	{% for package in results_list %}
 		<div class="resource">
-			<p class="url"><a href="{{ package.get_absolute_url }}"><strong>{{ package.name }}</strong></a></p>
+			<p><a href="{{ package.get_absolute_url }}"><strong>{{ package.name }}</strong></a></p>
 			<p class="description">{{ package.description }}</p>
 		</div>
 	{% endfor %}