Rename Download to Install and spruce up the madlib a bit.

This commit is contained in:
Chris Eppstein 2011-03-21 00:57:07 -07:00
parent 51e21b08b9
commit 0fdf606ad3
6 changed files with 32 additions and 11 deletions

View File

@ -8,7 +8,7 @@ GIT
PATH PATH
remote: .. remote: ..
specs: specs:
compass (0.11.beta.2.0d29379) compass (0.11.beta.3.5a2ea40)
chunky_png (~> 0.12.0) chunky_png (~> 0.12.0)
sass (>= 3.1.0.alpha.249) sass (>= 3.1.0.alpha.249)

View File

@ -45,7 +45,14 @@ function showInstallCommand() {
create_command = create_command + " --syntax sass"; create_command = create_command + " --syntax sass";
} }
if ($("#options").val() == "customized") { if ($("#options").val() == "customized") {
create_command = create_command + " --sass-dir <sassdir> --css-dir <cssdir> --javascripts-dir <jsdir> --images-dir <imgsdir>"; $("#directories").show();
create_command = create_command +
" --sass-dir \"" + $("#sassdir").val() + "\"" +
" --css-dir \"" + $("#cssdir").val() + "\"" +
" --javascripts-dir \"" + $("#jsdir").val() + "\"" +
" --images-dir \"" + $("#imagesdir").val() + "\"";
} else {
$("#directories").hide();
} }
commands.push(create_command); commands.push(create_command);
var instructions = "<pre><code>" + commands.join("\n") + "</code></pre>"; var instructions = "<pre><code>" + commands.join("\n") + "</code></pre>";
@ -69,6 +76,7 @@ function attachMadlibBehaviors() {
} }
}); });
$("#existence, #app-type, #framework, #syntax, #options").change(showInstallCommand); $("#existence, #app-type, #framework, #syntax, #options").change(showInstallCommand);
$(".madlib input").keyup(function(){setTimeout(showInstallCommand, 0.1)});
} }
function setupMadlib() { function setupMadlib() {

View File

@ -1,10 +1,10 @@
--- ---
title: Download | Compass Documentation title: Install the Compass Stylesheet Authoring Framework
crumb: Download crumb: Install
body_id: download body_id: install
--- ---
- content_for :javascripts do - content_for :javascripts do
%script(src="/javascripts/download.js") %script(src="/javascripts/install.js")
%p %p
Compass runs on any computer that has Compass runs on any computer that has
<a href="http://www.ruby-lang.org/en/downloads/">ruby installed</a>. <a href="http://www.ruby-lang.org/en/downloads/">ruby installed</a>.
@ -36,7 +36,18 @@ body_id: download
%select#options %select#options
%option{:value => "default"} use compass's recommended %option{:value => "default"} use compass's recommended
%option{:value => "customized"} customize my project's %option{:value => "customized"} customize my project's
directory structure</span>. directory structure<span id="directories" style="display:none;">
using
%input#sassdir(value="sass")
for the sass source directory,
%input#cssdir(value="css")
for the css output directory,
%input#jsdir(value="javascripts")
for the javascripts directory,
and
%input#imagesdir(value="images")
for the images directory</span></span>.
%h4 Thanks. Now run the following steps in your terminal: %h4 Thanks. Now run the following steps in your terminal:
%p.note %p.note

View File

@ -1,8 +1,10 @@
body#download { body#install {
#steps, p.madlib, p.note, h4 { margin-top: 1em; } #steps, p.madlib, p.note, h4 { margin-top: 1em; }
p.note { font-size: smaller; font-style: italic; } p.note { font-size: smaller; font-style: italic; }
p.warning { color: #c00; } p.warning { color: #c00; }
.customization { display: none; } .customization { display: none; }
.customizable .customization { display: inline; } .customizable .customization { display: inline; }
blockquote { border-left: 2px solid #ccc; text-indent: 0; padding-left: 0.5em; } blockquote { border-left: 2px solid #ccc;
text-indent: 0; padding-left: 0.5em; }
.customization input { width: 8em; }
} }

View File

@ -16,7 +16,7 @@
@import "partials/main"; @import "partials/main";
@import "partials/code"; @import "partials/code";
@import "partials/example"; @import "partials/example";
@import "partials/download"; @import "partials/install";
@import "syntax/syntax-theme"; @import "syntax/syntax-theme";

View File

@ -13,4 +13,4 @@
%li %li
%a{:href => "/get-involved/", :rel=> "get-involved"} Get Involved %a{:href => "/get-involved/", :rel=> "get-involved"} Get Involved
%li %li
%a{:href => "/download/", :rel=> "download"} Download %a{:href => "/install/", :rel=> "install"} Install