toadstool 0.0.0.1 → 0.0.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (163) hide show
  1. data/lib/bin/toadstool +80 -33
  2. data/lib/stylesheets/_toadstool-styleguide.scss +33 -0
  3. data/lib/stylesheets/toadstool/_buttons.scss +22 -0
  4. data/lib/stylesheets/toadstool/_config.scss +228 -0
  5. data/lib/stylesheets/toadstool/_design.scss +55 -0
  6. data/lib/stylesheets/toadstool/_forms.scss +18 -0
  7. data/lib/stylesheets/toadstool/_grids.scss +48 -0
  8. data/lib/stylesheets/toadstool/_modules.scss +3 -0
  9. data/{sass → lib/stylesheets/toadstool}/_typography.scss +43 -11
  10. data/lib/stylesheets/toadstool/_ui_patterns.scss +3 -0
  11. data/lib/stylesheets/toadstool/_web_fonts.scss +11 -0
  12. data/lib/stylesheets/toadstool/modules/_footer.scss +7 -0
  13. data/lib/stylesheets/toadstool/modules/_header.scss +41 -0
  14. data/lib/stylesheets/toadstool/modules/_main_nav.scss +49 -0
  15. data/lib/stylesheets/toadstool/ui_patterns/_color_grid.scss +220 -0
  16. data/lib/stylesheets/toadstool/ui_patterns/_emBox.scss +16 -0
  17. data/lib/stylesheets/toadstool/ui_patterns/_prettify.scss +136 -0
  18. data/lib/templates/module/sass/_example_module.scss +4 -0
  19. data/{sass/modules/example_module → lib/templates/module/sass}/_extends.scss +0 -0
  20. data/{sass/modules/example_module → lib/templates/module/sass}/_mixins.scss +0 -0
  21. data/{views/modules/example_module → lib/templates/module/views}/module.erb +0 -0
  22. data/{views/modules/example_module → lib/templates/module/views}/module.js +0 -0
  23. data/{views/modules/example_module → lib/templates/module/views}/view.erb +0 -0
  24. data/{Gemfile → lib/templates/project/Gemfile} +1 -3
  25. data/lib/templates/project/Rakefile +21 -0
  26. data/{config.rb → lib/templates/project/config.rb} +5 -3
  27. data/lib/templates/project/config.ru +8 -0
  28. data/{doc-src → lib/templates/project/doc-src}/SASS-Guidelines.md +0 -0
  29. data/lib/templates/project/doc-src/changelog.md +22 -0
  30. data/{doc-src → lib/templates/project/doc-src}/mit_license.md +0 -0
  31. data/{sass/modules/example_module/readme.md → lib/templates/project/doc-src/module-sass-readme.md} +0 -0
  32. data/{public → lib/templates/project/public}/images/toadstool-logo.png +0 -0
  33. data/{public → lib/templates/project/public}/javascripts/application.js +12 -1
  34. data/lib/templates/project/public/javascripts/jquery-1.8.3.min.js +2 -0
  35. data/{public → lib/templates/project/public}/javascripts/lang-css.js +0 -0
  36. data/{public → lib/templates/project/public}/javascripts/lang-yaml.js +0 -0
  37. data/lib/templates/project/public/javascripts/modernizr-2.6.1.js +1384 -0
  38. data/{public → lib/templates/project/public}/javascripts/modernizr.mods.js +0 -0
  39. data/{public → lib/templates/project/public}/javascripts/prettify.js +0 -0
  40. data/lib/templates/project/readme.md +79 -0
  41. data/lib/templates/project/sass/_buttons.scss +37 -0
  42. data/{sass → lib/templates/project/sass}/_config.scss +81 -74
  43. data/{sass → lib/templates/project/sass}/_design.scss +0 -0
  44. data/lib/templates/project/sass/_forms.scss +41 -0
  45. data/{sass → lib/templates/project/sass}/_reset.scss +0 -0
  46. data/lib/templates/project/sass/_typography.scss +98 -0
  47. data/lib/templates/project/sass/buttons/_extends.scss +3 -0
  48. data/lib/templates/project/sass/buttons/_mixins.scss +2 -0
  49. data/lib/templates/project/sass/color/_color_defaults.scss +98 -0
  50. data/{sass → lib/templates/project/sass}/color/_color_math.scss +1 -1
  51. data/lib/templates/project/sass/color/_extends.scss +109 -0
  52. data/{sass → lib/templates/project/sass}/color/_grayscale_math.scss +0 -0
  53. data/lib/templates/project/sass/color/readme.md +63 -0
  54. data/lib/templates/project/sass/forms/_extends.scss +3 -0
  55. data/lib/templates/project/sass/forms/_mixins.scss +3 -0
  56. data/{sass/_ui_patterns.scss → lib/templates/project/sass/layouts/_example_layout.scss} +0 -0
  57. data/lib/templates/project/sass/readme.md +142 -0
  58. data/{sass → lib/templates/project/sass}/style.scss +6 -10
  59. data/{sass → lib/templates/project/sass}/toadstool.scss +1 -1
  60. data/lib/templates/project/sass/typography/_extends.scss +13 -0
  61. data/lib/templates/project/sass/typography/_mixins.scss +2 -0
  62. data/{sass → lib/templates/project/sass/typography}/_web_fonts.scss +2 -5
  63. data/lib/templates/project/toadstool.rb +94 -0
  64. data/lib/templates/project/views/color_palettes.erb +371 -0
  65. data/lib/templates/project/views/forms.erb +40 -0
  66. data/lib/templates/project/views/forms/disabled_button.erb +18 -0
  67. data/lib/templates/project/views/forms/password_input.erb +22 -0
  68. data/lib/templates/project/views/forms/primary_button.erb +18 -0
  69. data/lib/templates/project/views/forms/readme.md +2 -0
  70. data/{views → lib/templates/project/views}/forms/username_input.erb +0 -0
  71. data/{views → lib/templates/project/views}/grid.erb +0 -0
  72. data/{views → lib/templates/project/views}/grid24.erb +0 -0
  73. data/{views → lib/templates/project/views}/grids/grid_arguments.erb +0 -0
  74. data/{views → lib/templates/project/views}/grids/use_definition.erb +0 -0
  75. data/{views → lib/templates/project/views}/layout.erb +2 -2
  76. data/{views/modules/example_module → lib/templates/project/views/modules}/readme.md +6 -4
  77. data/lib/templates/project/views/shared/_code_toggle.erb +10 -0
  78. data/lib/templates/project/views/shared/_html_example.erb +5 -0
  79. data/{views → lib/templates/project/views}/shared/_main_footer.erb +0 -0
  80. data/{views → lib/templates/project/views}/shared/_main_header.erb +0 -0
  81. data/{views → lib/templates/project/views}/shared/_main_nav.erb +0 -0
  82. data/{views → lib/templates/project/views}/shared/_toadstool_subheader.erb +0 -0
  83. data/lib/templates/project/views/typography.erb +35 -0
  84. data/lib/templates/project/views/typography/body_copy.erb +2 -0
  85. data/{views → lib/templates/project/views}/typography/body_links.erb +0 -0
  86. data/{sass/ui_patterns/_example.scss → lib/templates/project/views/typography/general_typography.erb} +0 -0
  87. data/{views → lib/templates/project/views}/typography/headings.erb +0 -0
  88. data/{views → lib/templates/project/views}/typography/vertical_rhythm.erb +0 -0
  89. data/{views → lib/templates/project/views}/typography/web_fonts.erb +0 -0
  90. data/lib/templates/project/views/ui_patterns/forms/primary_buttons.erb +8 -0
  91. data/lib/templates/project/views/ui_patterns/forms/text_input.erb +11 -0
  92. data/lib/templates/project/views/ui_patterns/forms/text_input_error.erb +11 -0
  93. data/{views → lib/templates/project/views}/ui_patterns/readme.md +4 -3
  94. data/lib/templates/project/views/ui_patterns/typography/_body_copy.erb +2 -0
  95. data/lib/templates/project/views/ui_patterns/typography/_headings.erb +6 -0
  96. data/lib/templates/ui_pattern/sass/_example_pattern.scss +4 -0
  97. data/lib/templates/ui_pattern/sass/_extends.scss +0 -0
  98. data/lib/templates/ui_pattern/sass/_mixins.scss +0 -0
  99. data/{views/ui_patterns → lib/templates/ui_pattern/views}/example.erb +0 -0
  100. data/lib/toadstool.rb +4 -0
  101. data/lib/toadstool/version.rb +3 -0
  102. metadata +120 -109
  103. data/Rakefile +0 -4
  104. data/config.ru +0 -6
  105. data/doc-src/What-Is-Toadstool.md +0 -44
  106. data/doc-src/changelog.md +0 -29
  107. data/doc-src/config.md +0 -18
  108. data/doc-src/mixin_directory.md +0 -17
  109. data/doc-src/sass.md +0 -4
  110. data/lib/RackServer.rb +0 -93
  111. data/public/fonts/fontawesome-webfont.eot +0 -0
  112. data/public/fonts/fontawesome-webfont.svg +0 -255
  113. data/public/fonts/fontawesome-webfont.ttf +0 -0
  114. data/public/fonts/fontawesome-webfont.woff +0 -0
  115. data/public/fonts/zocial-regular-webfont.eot +0 -0
  116. data/public/fonts/zocial-regular-webfont.svg +0 -138
  117. data/public/fonts/zocial-regular-webfont.ttf +0 -0
  118. data/public/fonts/zocial-regular-webfont.woff +0 -0
  119. data/public/javascripts/css_browser_selector.js +0 -8
  120. data/public/javascripts/lang-apollo.js +0 -2
  121. data/public/javascripts/lang-clj.js +0 -18
  122. data/public/javascripts/lang-go.js +0 -1
  123. data/public/javascripts/lang-hs.js +0 -2
  124. data/public/javascripts/lang-lisp.js +0 -3
  125. data/public/javascripts/lang-lua.js +0 -2
  126. data/public/javascripts/lang-ml.js +0 -2
  127. data/public/javascripts/lang-n.js +0 -4
  128. data/public/javascripts/lang-proto.js +0 -1
  129. data/public/javascripts/lang-scala.js +0 -2
  130. data/public/javascripts/lang-sql.js +0 -2
  131. data/public/javascripts/lang-tex.js +0 -1
  132. data/public/javascripts/lang-vb.js +0 -2
  133. data/public/javascripts/lang-vhdl.js +0 -3
  134. data/public/javascripts/lang-wiki.js +0 -2
  135. data/public/javascripts/lang-xq.js +0 -3
  136. data/public/javascripts/selectivizr-min.js +0 -5
  137. data/public/stylesheets/style.css +0 -615
  138. data/public/stylesheets/toadstool.css +0 -1643
  139. data/readme.md +0 -37
  140. data/sass/_buttons.scss +0 -20
  141. data/sass/_forms.scss +0 -18
  142. data/sass/_modules.scss +0 -12
  143. data/sass/buttons/_cupid_config.scss +0 -20
  144. data/sass/buttons/_minimal_config.scss +0 -15
  145. data/sass/color/_extends.scss +0 -291
  146. data/sass/ui_patterns/_color_grid.scss +0 -286
  147. data/toadstool.rb +0 -84
  148. data/views/abstract_colors.erb +0 -1
  149. data/views/alerts.erb +0 -1
  150. data/views/buttons.erb +0 -1
  151. data/views/color_palettes.erb +0 -221
  152. data/views/forms.erb +0 -24
  153. data/views/forms/disabled_button.erb +0 -18
  154. data/views/forms/password_input.erb +0 -22
  155. data/views/forms/primary_button.erb +0 -18
  156. data/views/modules/readme.md +0 -10
  157. data/views/semantic_colors.erb +0 -1
  158. data/views/shared/_html_example.erb +0 -31
  159. data/views/shared/_sass_example.erb +0 -10
  160. data/views/typography.erb +0 -17
  161. data/views/typography/body_copy.erb +0 -19
  162. data/views/typography/general_typography.erb +0 -19
  163. data/views/ui_patterns/forms/text_input.erb +0 -10
@@ -0,0 +1,3 @@
1
+ // Use this to build custom extends for your project
2
+ // -----------------------------------------------------------------------
3
+
@@ -0,0 +1,2 @@
1
+ // Use this to build custom extends for your project
2
+ // -----------------------------------------------------------------------
@@ -0,0 +1,98 @@
1
+ /////// Toadstool's semantic variables ///////
2
+ // Semantic variables should always be matched up with abstract values, never semantic to semantic
3
+ // -----------------------------------------------------------------------------
4
+
5
+ // primary header font color
6
+ $primary_header_color: $alpha_gray;
7
+
8
+ // default heading font weight
9
+ $heading_font_weight: normal;
10
+
11
+ // primary font color for the app
12
+ $primary_text: $bravo_gray;
13
+ $secondary_text: $bravo_gray;
14
+
15
+ // default `href` link color
16
+ $href_color: $delta_color;
17
+ $href_color_alt: $delta_color_bravo;
18
+
19
+ // default shadow colors
20
+ $shadow_color: fade-out($alpha_gray, 0.5);
21
+
22
+ // default border color
23
+ $border_color: $charlie_gray;
24
+
25
+
26
+
27
+ /////// HTML 5 feature colors ///////
28
+ // -----------------------------------------------------------------------------
29
+ // used with the `ins` tag
30
+ // http://www.w3schools.com/tags/tag_ins.asp
31
+ $ins_color: $charlie_color;
32
+
33
+ // used with the `mark` tag
34
+ // http://www.w3schools.com/html5/tag_mark.asp
35
+ $mark_color: $charlie_color;
36
+
37
+ // webkit tap highlight color
38
+ $webkit_tap_hightlight: $delta_color_bravo;
39
+
40
+ // overrides the default content selection color in the browser
41
+ $selection_color: lighten($alpha_color, 50%);
42
+ $selection_text_color: $primary_text;
43
+
44
+
45
+
46
+ /////// Config defaults for forms ///////
47
+ // -----------------------------------------------------------------------------
48
+ $alert_background_color: $alpha_color;
49
+
50
+ $input_disabled: $bravo_gray;
51
+ $input_disabled_bkg: lighten($input_disabled, 75%);
52
+ $input_disabled_border: lighten($input_disabled, 50%);
53
+ $input_disabled_text: lighten($input_disabled, 50%);
54
+
55
+ $form_field_background_color: $white;
56
+ $form_field_focus_color: $white;
57
+ $form_field_fail_bkg: $alpha_color_juliet;
58
+
59
+ $form_field_border: $charlie_gray;
60
+ $form_field_border_fail: $alpha_color_echo;
61
+ $form_field_focus_border_color: $charlie_gray;
62
+
63
+ $form_field_text_fail: $alpha_color_echo;
64
+ $form_label_color: $alpha_gray;
65
+ $optional_field_text_color: $delta_gray;
66
+ $instructional_text: $charlie_gray;
67
+ $placeholder_text: $hotel_gray;
68
+ $inline_alert_bkg_color: $alpha_color_delta;
69
+ $inline_alert_text_color: $white;
70
+
71
+ // Non-color defaults (currently not represented in the SG view)
72
+ // ---------------------------------------------------------
73
+ $form_field_text: $primary_text;
74
+
75
+
76
+
77
+ /////// Config defaults for buttons ///////
78
+ // -----------------------------------------------------------------------------
79
+ $button-color: $delta-color;
80
+ $secondary_button_border_color: $bravo_gray;
81
+ $button_text: $white;
82
+
83
+ // Depricated variable
84
+ $primary_button_border_color: $bravo_color;
85
+
86
+
87
+
88
+ /////// Config defaults for ``standard_rounded_border`` mixin ///////
89
+ // -----------------------------------------------------------------------------
90
+ $standard_border_color: $border_color; // sets default border color
91
+
92
+ /////// Config defaults for ``standard_hr`` mixin ///////
93
+ // -----------------------------------------------------------------------------
94
+ $standard_hr_color: $delta_gray;
95
+
96
+ /////// Config values for all default shadows ///////
97
+ // -----------------------------------------------------------------------------
98
+ $inset_color: $shadow_color; // for use with ``dual_box_shadow`` mixin
@@ -1,4 +1,4 @@
1
- @import "stipe/color/default_color_pallet"; // do not edit, necessary dependency for cascading defaults
1
+ @import "stipe/color/default_color_palette"; // do not edit, necessary dependency for cascading defaults
2
2
 
3
3
  $alpha_color:$alpha_primary;
4
4
  $alpha_color_bravo:scale-color($alpha_color,$lightness:10%);
@@ -0,0 +1,109 @@
1
+ // OOCSS Color placeholders are necessary at the style guide level as to ensure that
2
+ // the colors are being generated from the proper context.
3
+
4
+ @import "../config";
5
+
6
+
7
+ // This mixin loops through a list of values to produce the necessary silent placeholders
8
+ @mixin name_color_loop {
9
+ @each $name in $color_names {
10
+ $i: index($color_names, $name);
11
+ %#{$name} {
12
+ background: nth($color_var, $i);
13
+ }
14
+ }
15
+ }
16
+
17
+ /////// OOCSS color blocks ////////
18
+ // ----------------------------------------------
19
+
20
+ //* Standard grayscale objects */
21
+ //* -------------------------- */
22
+ %white {
23
+ background-color: $white;
24
+ }
25
+
26
+ $color_names: alpha_gray bravo_gray charlie_gray delta_gray echo_gray fox_gray golf_gray hotel_gray india_gray;
27
+ $color_var: $alpha_gray $bravo_gray $charlie_gray $delta_gray $echo_gray $fox_gray $golf_gray $hotel_gray $india_gray;
28
+ @each $name in $color_names {
29
+ $i: index($color_names, $name);
30
+ %#{$name} {
31
+ background: nth($color_var, $i);
32
+ }
33
+ }
34
+
35
+ @include name_color_loop;
36
+
37
+
38
+ // Alpha and Bravo color objects
39
+ // ----------------------------------------------
40
+ $alpha_color_names: alpha_color alpha_color_bravo alpha_color_charlie alpha_color_delta alpha_color_echo alpha_color_fox alpha_color_golf alpha_color_hotel alpha_color_india alpha_color_juliet;
41
+ $alpha_color_var: $alpha_color $alpha_color_bravo $alpha_color_charlie $alpha_color_delta $alpha_color_echo $alpha_color_fox $alpha_color_golf $alpha_color_hotel $alpha_color_india $alpha_color_juliet;
42
+
43
+ $bravo_color_names: bravo_color bravo_color_bravo bravo_color_charlie bravo_color_delta bravo_color_echo bravo_color_fox bravo_color_golf bravo_color_hotel bravo_color_india bravo_color_juliet;
44
+ $bravo_color_var: $bravo_color $bravo_color_bravo $bravo_color_charlie $bravo_color_delta $bravo_color_echo $bravo_color_fox $bravo_color_golf $bravo_color_hotel $bravo_color_india $bravo_color_juliet;
45
+
46
+ // Sass' join function can only jpin two lists.
47
+ // Until I get a better idea, this is what I get.
48
+
49
+ $color_names: join($alpha_color_names, $bravo_color_names);
50
+ $color_var: join($alpha_color_var, $bravo_color_var);
51
+
52
+ @include name_color_loop;
53
+
54
+ // Charlie and Delta color objects
55
+ // ----------------------------------------------
56
+ $charlie_color_names: charlie_color charlie_color_bravo charlie_color_charlie charlie_color_delta charlie_color_echo charlie_color_fox charlie_color_golf charlie_color_hotel charlie_color_india charlie_color_juliet;
57
+ $charlie_color_var: $charlie_color $charlie_color_bravo $charlie_color_charlie $charlie_color_delta $charlie_color_echo $charlie_color_fox $charlie_color_golf $charlie_color_hotel $charlie_color_india $charlie_color_juliet;
58
+
59
+ $delta_color_names: delta_color delta_color_bravo delta_color_charlie delta_color_delta delta_color_echo delta_color_fox delta_color_golf delta_color_hotel delta_color_india delta_color_juliet;
60
+ $delta_color_var: $delta_color $delta_color_bravo $delta_color_charlie $delta_color_delta $delta_color_echo $delta_color_fox $delta_color_golf $delta_color_hotel $delta_color_india $delta_color_juliet;
61
+
62
+ $color_names: join($charlie_color_names, $delta_color_names);
63
+ $color_var: join($charlie_color_var, $delta_color_var);
64
+
65
+ @include name_color_loop;
66
+
67
+ // Echo color objects
68
+ // ----------------------------------------------
69
+ $color_names: echo_color echo_color_bravo echo_color_charlie echo_color_delta echo_color_echo echo_color_fox echo_color_golf echo_color_hotel echo_color_india echo_color_juliet;
70
+ $color_var: $echo_color $echo_color_bravo $echo_color_charlie $echo_color_delta $echo_color_echo $echo_color_fox $echo_color_golf $echo_color_hotel $echo_color_india $echo_color_juliet;
71
+
72
+ @include name_color_loop;
73
+
74
+
75
+ /////// semantic color blocks ////////
76
+ // ----------------------------------------------
77
+ $color_names: 'white' shadow_color primary_header_color heading_font_weight primary_text secondary_text href_color ins_color mark_color webkit_tap_hightlight selection_color selection_text_color border_color primary_button_border_color secondary_button_border_color button_text standard_hr_color standard_border_color;
78
+ $color_var: $white $shadow_color $primary_header_color $heading_font_weight $primary_text $secondary_text $href_color $ins_color $mark_color $webkit_tap_hightlight $selection_color $selection_text_color $border_color $primary_button_border_color $secondary_button_border_color $button_text $standard_hr_color $standard_border_color;
79
+
80
+ @include name_color_loop;
81
+
82
+
83
+ /////// Config defaults for forms ///////
84
+ // -----------------------------------------------------------------------------
85
+
86
+ $color_names: alert_background_color input_disabled input_disabled_bkg input_disabled_border input_disabled_text form_field_background_color form_field_focus_color form_field_fail_bkg form_field_border form_field_border_fail form_field_focus_border_color form_field_text_fail form_label_color optional_field_text_color instructional_text placeholder_text inline_alert_bkg_color inline_alert_text_color;
87
+ $color_var: $alert_background_color $input_disabled $input_disabled_bkg $input_disabled_border $input_disabled_text $form_field_background_color $form_field_focus_color $form_field_fail_bkg $form_field_border $form_field_border_fail $form_field_focus_border_color $form_field_text_fail $form_label_color $optional_field_text_color $instructional_text $placeholder_text $inline_alert_bkg_color $inline_alert_text_color;
88
+
89
+ @include name_color_loop;
90
+
91
+
92
+
93
+ /////// Config defaults for buttons ///////
94
+ // -----------------------------------------------------------------------------
95
+
96
+ $color_names: button_color primary_button_border_color secondary_button_border_color button_text;
97
+ $color_var: $button_color $primary_button_border_color $secondary_button_border_color $button_text;
98
+
99
+ @include name_color_loop;
100
+
101
+
102
+
103
+
104
+
105
+
106
+
107
+
108
+
109
+
@@ -0,0 +1,63 @@
1
+ #How does Toadstool manage colors?
2
+ The goal of Toadstool and Stipe are to use colors in an intelligent manor, versus CSS with hex values randomly applied throughout the code.
3
+
4
+ Nested in the [config.scss](http://goo.gl/rmCQP) file of your Toadstool style guide will be options to change Stipe's default colors. Simply uncomment these lines and replace the hex values with the color palette you wish.
5
+
6
+ ```scss
7
+ // $alphaprimary: #5a2e2e; // red
8
+ // $bravoprimary: #3e4147; // green
9
+ // $charlieprimary: #fffedf; // yellow
10
+ // $deltaprimary: #2a2c31; // blue
11
+ // $echoprimary: #dfba69; // accent
12
+
13
+ // $alphagray: #333; //black
14
+ ```
15
+
16
+ These primary color values will be processed through your style guide's `color_math.scss` and `grayscale_math.scss` files. In these files you will see an array of new abstract color values being created using Sass' [scale-color](http://goo.gl/SQisc) function. Like the following example:
17
+
18
+ ```scss
19
+ $alpha_color:$alpha_primary !default;
20
+ $alpha_color_bravo:scale-color($alpha_color,$lightness:10%) !default;
21
+ $alpha_color_charlie:scale-color($alpha_color,$lightness:20%) !default;
22
+ $alpha_color_delta:scale-color($alpha_color,$lightness:30%) !default;
23
+ $alpha_color_echo:scale-color($alpha_color,$lightness:40%) !default;
24
+ $alpha_color_fox:scale-color($alpha_color,$lightness:50%) !default;
25
+ $alpha_color_golf:scale-color($alpha_color,$lightness:60%) !default;
26
+ $alpha_color_hotel:scale-color($alpha_color,$lightness:70%) !default;
27
+ $alpha_color_india:scale-color($alpha_color,$lightness:80%) !default;
28
+ $alpha_color_juliet:scale-color($alpha_color,$lightness:90%) !default;
29
+ ```
30
+
31
+ ##Color application
32
+ As you develop your site's CSS, you are encouraged to make use of these abstract color values. In your style guide's [config.scss](http://goo.gl/mi2UC) file there is an array of semantically named color variables using Stipe's abstract color variables as their values like so:
33
+
34
+ ```scss
35
+ // default shadow colors
36
+ $shadow_color: fade-out($alphagray, 0.5);
37
+
38
+ // primary header font color
39
+ $primary_header_color: $alphagray;
40
+
41
+ // primary font color for the app
42
+ $primary_text: $bravogray;
43
+ ```
44
+
45
+ You are encouraged to update the `_config.scss` file values to better suit your site. As new color values are needed, add them to the `_config.scss` file.
46
+
47
+ There may be times when you will want to simply refer to the abstract color like the following:
48
+ ```scss
49
+ block {
50
+ background: $alpha_color_golf;
51
+ }
52
+ ```
53
+
54
+ While this is perfectly acceptable, I would encourage you to create a semantically named variable and apply the abstract name as the value in the `_config.scss` file.
55
+
56
+ ##Why the abstraction?
57
+ Some may ask, _"Why would you want to make these abstractions versus simply applying the hex value?"_
58
+
59
+ Even if you are creating a list of semantically names variables, not using this array of abstract values means that you will be applying repeated hex values to all your semantically named variables. Hex values are not names that easily roll off the tongue and can easily become confused.
60
+
61
+ Using abstract naming gives the color values personality and thus makes it easier to discuss. It is easier to say, _"Please use alpha_color_charlie."_ versus saying, _"Please use #8C4747."_
62
+
63
+ Another benefit is that all these abstract variables are gnerated by using Sass' color functions. This keeps all the color editing in one place. Then if at any time that the color palette needs to be updated, simply update the primary color hex values and then all your site's colors are updated in the cascading fashion they were applied.
@@ -0,0 +1,3 @@
1
+ // Use this Sass file to create custom form silent placeholder extends per your project
2
+ // -----------------------------------------------------------------------
3
+
@@ -0,0 +1,3 @@
1
+ // Use this Sass file to create custom form mixins per your project
2
+ // -----------------------------------------------------------------------
3
+
@@ -0,0 +1,142 @@
1
+ #Toadstool and Sass
2
+ The Toadstool style guide framework makes heavy use of Sass as it's primary styling language. Primary features of Sass not only include the ability to modularize your UI code, but also engineer your UI code in an abstract manor that allows for infinite reusability.
3
+
4
+ The look of your Toadstool style guide is driven from the [Stipe](http://goo.gl/68RPd) gem. All the Sass files you see in this directory are to be used to generate the final CSS for your project.
5
+
6
+ ##Sass manifest files
7
+ In your project there are two Sass manifest files, `style.scss` and `toadstool.scss`. Your `style.scss` is what will be used for your production project while the `toadstool.scss` will only be used for the style guide view.
8
+
9
+ For the most part there will be no need to edit the `toadstool.scss` file. All the UI that you see in the Toadstool views is being generated from Sass written in the [Stipe](http://goo.gl/68RPd) gem.
10
+
11
+ The `style.scss` on the other hand is the principal manifest of your generated CSS. Let's go step-by-step into this file so that we understand what is happening here.
12
+
13
+ ###The _config.scss file.
14
+
15
+ ```scss
16
+ // App Config - this is where most of your magic will happen
17
+ // ------------------------------------------------------------------------------
18
+ @import "config"; // Editing defaults here will override any set in the Stipe gem
19
+
20
+ ```
21
+
22
+ The `_config.scss` file serves as the core UI configuration for your new UI. In this document are a series of pre-set variables. Including, but not limited to the following. [Read more](http://goo.gl/iLR3o) about how the config file works.
23
+ * Typography
24
+ * Images directory
25
+ * Color palette
26
+ * Grid configuration
27
+ * Semantic color variables
28
+ * Form UI variables
29
+ * Buttons
30
+ * Borders
31
+ * Spacing
32
+ * Shadows
33
+ * Breakpoints
34
+
35
+ ###CSS reset
36
+ Toadstool comes pre-set with a Toadstool specific CSS reset. This reset address the most common UI settings. Stipe comes pre-loaded with Eric Meyer's reset as well and since we are using Compass, if you want, you could use that reset as well. Simply address the lines below in your `_config.scss` file.
37
+
38
+ If you have your own reset, you can use that too. Simply uncomment the local `@import "reset";` line and in the file structure of the style guide put your reset.
39
+
40
+ ```scss
41
+ // Choose the CSS reset by selectively commenting/uncommenting the import files
42
+ // ------------------------------------------------------------------------------
43
+ @import "stipe/resets/toadstool"; // Default toadstool reset
44
+ // @import "stipe/resets/eric_meyer"; // http://meyerweb.com/eric/tools/css/reset/reset.css
45
+ // @import "compass/reset"; // Reset supported by the Compass gem
46
+
47
+ // Don't want to use any of these? Kool, we can respect that
48
+ // ------------------------------------------------------------------------------
49
+ // @import "reset";
50
+
51
+ ```
52
+
53
+ ###Web fonts
54
+ Web fonts in Stipe and Toadstool are really easy to manage. In the `_config.scss` file you are already importing the `_web_fonts.scss` file.
55
+
56
+ ```scss
57
+ // Want web fonts? We got those too.
58
+ // ------------------------------------------------------------------------------
59
+ @import "web_fonts";
60
+
61
+ ```
62
+
63
+ The `_web_fonts.scss` file itself is your manifest for all imported web fonts. Zocial and Font-Awesome are already installed for your use. Simply uncomment the following to take advantage:
64
+
65
+ ```scss
66
+ // Pre-loaded web fonts for your use, enjoy!
67
+ // Fonts needed to be loaded in path specified above in relation to the rendered CSS file
68
+ // -----------------------------------------------------------
69
+ // To activate 'zocial' uncomment both lines
70
+ // @import "stipe/typography/web_fonts/zocial";
71
+ // @import "stipe/typography/web_fonts/zocial_characters";
72
+
73
+ // To activate 'font_awesome' uncomment both lines
74
+ // @import "stipe/typography/web_fonts/font_awesome";
75
+ // @import "stipe/typography/web_fonts/font_awesome_pua";
76
+ ```
77
+
78
+ To install your own, simply use the `font-face` mixin:
79
+ ```scss
80
+ @font-face {
81
+ @include font-face ($font_family: [name of family], $font-file: [name of file], $font_weight: [value], $font_style: [value]);
82
+ ```
83
+
84
+ If you prefer to use a Google Font, use the following as example:
85
+ ```scss
86
+ // Install google fonts
87
+ // -----------------------------------------------------------
88
+ @import url(http://fonts.googleapis.com/css?family=Emblema+One);
89
+ ```
90
+
91
+ ###Using the Stipe gem
92
+ The Stipe gem will be installed on your machine and the following line calles in the necessary libraries.
93
+ ```scss
94
+ // Following sequence will load the necessary Stipe libraries
95
+ // ------------------------------------------------------------------------------
96
+ @import "stipe/manifest";
97
+ ```
98
+
99
+ Color management is a little tricky as the placeholder classes that are extended into your project need to be processed in context with the color specifications dictated in your `_config.scss` file. So, the following is included:
100
+ ```scss
101
+ @import "color/extends";
102
+ ```
103
+
104
+ ###Your styles
105
+ Finally we have your styles included in the manifest.
106
+ ```scss
107
+ // This where you start building your own styles.
108
+ // ------------------------------------------------------------------------------
109
+ @import "typography";
110
+ @import "forms";
111
+ @import "buttons";
112
+ @import "design";
113
+ @import "ui_patterns"; // manifest files
114
+ @import "modules"; // manifest files
115
+ @import "layouts"; // manifest files
116
+ ```
117
+
118
+ Elemental files include `typography`, `forms`, `buttons`, `design`. The Sass necessary for the site's design are to be edited directly in these files.
119
+
120
+ Collective manifest files include `ui_patterns`, `modules` and `layouts`. No Sass is ever to be written in these files. They are only to `@import` the various UI Patterns, Modules and Layouts.
121
+
122
+ ##Typography
123
+ Setting basic typography is a pretty simple task, so this is why I set out to make this a consistent pattern so I never have to do this again. Toadstool's typography pulls a lot of CSS rules from the Stipe gem. These rules are represented in your local Toadstool style guide, but the rules are commented out.
124
+
125
+ Core typography settings for your style guide require little intervention. By simply updating the correct variables in the `_config.scss` file, you can effect great change. But if needed, you can either edit the CSS rule directly with the selector or actually over-ride the extended silent placeholder that drives the UI for that block element.
126
+
127
+ If these typography settings are unwanted, simply remove `@import "stipe/typography/default";` from the manifest file and populate the Sass file with the appropriate CSS rules.
128
+
129
+ It should also be noted that neither Toadstool or Stipe use pixles. EMs are the preferred way to draw relationships between elements in the UI. Again Toadstool/Stipe aim to make life easier, so deep in the Stipe's core are [typography functions](http://goo.gl/g2sPk) to address integer conversion to em value.
130
+
131
+ ```scss
132
+ @function em($target, $context: $font_size) {
133
+ @return ($target / $context) * 1em;
134
+ }
135
+ ```
136
+
137
+ ##Forms
138
+ Toadstool comes pre-loaded with the basic elements that make up a form UI. You will find very basic CSS rules in your version of the Toadstool style guide.
139
+
140
+ ##Buttons
141
+
142
+ ##The design dumping ground