From ad88a5806a1fe41a6956df44eac73c4288b51711 Mon Sep 17 00:00:00 2001 From: Daniel Gaytan Date: Fri, 4 Mar 2016 13:32:50 -0600 Subject: [PATCH 1/2] Fix broken github links --- compass-style.org/README.markdown | 4 ++-- .../content/reference/compass/helpers/cross-browser.haml | 8 ++++---- compass-style.org/tasks/generators.thor | 8 ++++---- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/compass-style.org/README.markdown b/compass-style.org/README.markdown index aa92508b81..77b3245fc0 100644 --- a/compass-style.org/README.markdown +++ b/compass-style.org/README.markdown @@ -291,7 +291,7 @@ All of these are optional and have reasonable defaults, you can use them when un **Note**: When generating examples or references, Thor is searching for the appropriate module stylesheet. If it doesn't find one, it raises an error and doesn't generate anything. So before generating anything make sure the stylesheet exists and is -under `../frameworks/compass/stylesheets/compass/path/to/module` (relative to the `compass-style.org` directory). If the path confuses you, just take a few minutes to study how other modules are organized and you'll quickly get the hang of it. +under `../core/stylesheets/compass/path/to/module` (relative to the `compass-style.org` directory). If the path confuses you, just take a few minutes to study how other modules are organized and you'll quickly get the hang of it. Let's do an example: @@ -345,7 +345,7 @@ After adding the example and adjusting the metadata, go to the reference page in Existing modules already have reference files, so you'll most likely be adding reference files to new modules. -So we got a great idea for an awesome module, and after a lot of thinking we decided to name it `super-awesome-module`. The first step to adding a new module is creating the stylesheet. Let's say this will be a Compass CSS3 module, so we'll create a new file as `../frameworks/compass/stylesheets/compass/css3/_super-awesome-module.scss` (relative to the `compass-style.org` directory). Keep in mind that the comments inside those stylesheets are parsed with Markdown and output into the reference. +So we got a great idea for an awesome module, and after a lot of thinking we decided to name it `super-awesome-module`. The first step to adding a new module is creating the stylesheet. Let's say this will be a Compass CSS3 module, so we'll create a new file as `../core/stylesheets/compass/css3/_super-awesome-module.scss` (relative to the `compass-style.org` directory). Keep in mind that the comments inside those stylesheets are parsed with Markdown and output into the reference. The easiest way to find out how you should write your stylesheet is to take a look at some existing modules. This module won't be very useful, but you'll get the point: diff --git a/compass-style.org/content/reference/compass/helpers/cross-browser.haml b/compass-style.org/content/reference/compass/helpers/cross-browser.haml index 323964762f..ca5fa70630 100644 --- a/compass-style.org/content/reference/compass/helpers/cross-browser.haml +++ b/compass-style.org/content/reference/compass/helpers/cross-browser.haml @@ -1,4 +1,4 @@ ---- +--- title: Compass Cross Browser Helpers crumb: Cross Browser framework: compass @@ -24,15 +24,15 @@ documented_functions: :markdown These helpers are used by compass to create mixins that can insulate the user from cross browser syntax and vendor prefix complexities. - + If you need to support a new experimental (prefixed) function in your project using these helpers, you can add support for it adding the following to your compass configuration file: - + Compass::BrowserSupport.add_support("function-name", "webkit", "moz") For an example of how to use these functions see the - [compass images module](https://github.com/chriseppstein/compass/blob/master/frameworks/compass/stylesheets/compass/css3/_images.scss). + [compass images module](https://github.com/chriseppstein/compass/blob/master/core/stylesheets/compass/css3/_images.scss). #prefixed.helper %h3 diff --git a/compass-style.org/tasks/generators.thor b/compass-style.org/tasks/generators.thor index feeddfe109..0d38323492 100644 --- a/compass-style.org/tasks/generators.thor +++ b/compass-style.org/tasks/generators.thor @@ -61,10 +61,10 @@ class Generate < Thor open(file_name, "w") do |example_file| example_contents = <<-EXAMPLE | @import "#{module_path}"; - | + | | // This file is used to style the example markup. | // And the source is shown to the user as SCSS, Sass and as CSS. - | + | | .example { | .title { | font-size: 36px; @@ -72,7 +72,7 @@ class Generate < Thor | color: #333; | border: none; | } - | + | | p { color: #666; } | } EXAMPLE @@ -128,7 +128,7 @@ class Generate < Thor stylesheet_name = array.pop prefix = array.join("/") - stylesheet = Dir["../frameworks/compass/stylesheets/#{prefix}/_#{stylesheet_name}.{scss,sass}"].first + stylesheet = Dir["../core/stylesheets/#{prefix}/_#{stylesheet_name}.{scss,sass}"].first raise "no stylesheet found for module #{module_path}" if stylesheet.nil? stylesheet = File.expand_path(stylesheet) From 53c529372eb9e5076256b98814ebf6cedf152b6b Mon Sep 17 00:00:00 2001 From: Daniel Gaytan Date: Fri, 4 Mar 2016 13:46:58 -0600 Subject: [PATCH 2/2] Compass stable does not use the frameworks folder anymore --- compass-style.org/layouts/reference.haml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/compass-style.org/layouts/reference.haml b/compass-style.org/layouts/reference.haml index 8dd4721629..2965145f18 100644 --- a/compass-style.org/layouts/reference.haml +++ b/compass-style.org/layouts/reference.haml @@ -1,5 +1,5 @@ -- gh_url = "http://github.com/chriseppstein/compass/blob/stable/frameworks/" -- gh_url << "#{item[:framework]}/stylesheets/#{item[:stylesheet]}" +- gh_url = "http://github.com/chriseppstein/compass/blob/stable/core/" +- gh_url << "stylesheets/#{item[:stylesheet]}" %a{:href => gh_url, :rel=>"github-source", :title=>"view source for this module on github"} Source on Github %h1= item[:title]