plinth 0.0.1.beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/.codoopts +10 -0
- data/.env +1 -0
- data/.gitignore +23 -0
- data/.ruby-version +1 -0
- data/CHANGELOG.md +1 -0
- data/Capfile +4 -0
- data/Gemfile +52 -0
- data/Gemfile.lock +243 -0
- data/Guardfile +9 -0
- data/LICENSE +22 -0
- data/Procfile +1 -0
- data/README.md +79 -0
- data/Rakefile +35 -0
- data/app/assets/images/layouts/basic-marketing-site.png +0 -0
- data/app/assets/images/layouts/jumbotron-site.png +0 -0
- data/app/assets/images/rails.png +0 -0
- data/app/assets/javascripts/application.js +17 -0
- data/app/assets/javascripts/base.js.coffee +3 -0
- data/app/assets/javascripts/grids.js.coffee +3 -0
- data/app/assets/javascripts/javascript.js.coffee +3 -0
- data/app/assets/javascripts/lib/modernizr.js +4 -0
- data/app/assets/javascripts/modules.js.coffee +3 -0
- data/app/assets/stylesheets/application-old-ie.css.scss +10 -0
- data/app/assets/stylesheets/application.css.scss +57 -0
- data/app/assets/stylesheets/base/_all.scss +6 -0
- data/app/assets/stylesheets/base/_reset.css.scss +16 -0
- data/app/assets/stylesheets/base/_type.scss +16 -0
- data/app/assets/stylesheets/modules/_coderay.css.scss +171 -0
- data/app/assets/stylesheets/modules/_layout_examples.css.scss +13 -0
- data/app/assets/stylesheets/modules/_webfont_table.css.scss +47 -0
- data/app/assets/stylesheets/vanilla-normal-old-ie.css.scss +11 -0
- data/app/assets/stylesheets/vanilla-normal.css.scss +33 -0
- data/app/controllers/application_controller.rb +5 -0
- data/app/controllers/base_controller.rb +52 -0
- data/app/controllers/grids_controller.rb +48 -0
- data/app/controllers/javascript_controller.rb +20 -0
- data/app/controllers/javascripts_controller.rb +4 -0
- data/app/controllers/modules_controller.rb +43 -0
- data/app/controllers/ui_controller.rb +2 -0
- data/app/helpers/plinth_helper.rb +33 -0
- data/app/views/base/_webfonts_social_standard.html +429 -0
- data/app/views/base/_webfonts_ss_standard.html +2413 -0
- data/app/views/base/buttons.html.haml +20 -0
- data/app/views/base/forms.html.haml +40 -0
- data/app/views/base/images.html.haml +20 -0
- data/app/views/base/index.html.haml +68 -0
- data/app/views/base/labels.html.haml +22 -0
- data/app/views/base/lists.html.haml +20 -0
- data/app/views/base/webfonts.html.haml +17 -0
- data/app/views/grids/index.html.haml +73 -0
- data/app/views/grids/layouts/basic-marketing-site.haml +69 -0
- data/app/views/grids/layouts/jumbotron-site.haml +92 -0
- data/app/views/grids/layouts.html.haml +9 -0
- data/app/views/layouts/_main_nav.html.haml +15 -0
- data/app/views/layouts/application.html.haml +15 -0
- data/app/views/modules/alerts.html.haml +12 -0
- data/app/views/modules/footer.html.haml +2 -0
- data/app/views/modules/index.html.haml +5 -0
- data/app/views/modules/nav.html.haml +12 -0
- data/app/views/modules/panels.html.haml +3 -0
- data/app/views/modules/tabs.html.haml +58 -0
- data/app/views/old_javascript/close.html.haml +2 -0
- data/app/views/old_javascript/forms.html.haml +2 -0
- data/app/views/old_javascript/ga_events.html.haml +2 -0
- data/app/views/old_javascript/index.html.haml +2 -0
- data/app/views/old_javascript/responsive_resize.html.haml +2 -0
- data/app/views/old_javascript/switch.html.haml +2 -0
- data/app/views/parts/base/_button.haml +3 -0
- data/app/views/parts/base/_button_colours.haml +4 -0
- data/app/views/parts/base/_button_group.haml +4 -0
- data/app/views/parts/base/_button_sizing.haml +3 -0
- data/app/views/parts/base/_button_states.haml +3 -0
- data/app/views/parts/base/_form_example.haml +26 -0
- data/app/views/parts/base/_form_example_horizontal.haml +26 -0
- data/app/views/parts/base/_form_group.haml +10 -0
- data/app/views/parts/base/_form_location.haml +3 -0
- data/app/views/parts/base/_labels.haml +5 -0
- data/app/views/parts/base/_labels_sizing.haml +3 -0
- data/app/views/parts/base/_list.haml +10 -0
- data/app/views/parts/base/_list_action.haml +5 -0
- data/app/views/parts/base/_list_nav.haml +12 -0
- data/app/views/parts/base/_list_unset.haml +10 -0
- data/app/views/parts/base/_type_body.haml +2 -0
- data/app/views/parts/base/_type_headings.haml +5 -0
- data/app/views/parts/base/_type_helpers.haml +3 -0
- data/app/views/parts/base/_type_links.haml +9 -0
- data/app/views/parts/base/_type_shouts.haml +4 -0
- data/app/views/parts/grids/_example_layout_1.haml +10 -0
- data/app/views/parts/grids/_live_grid.haml +29 -0
- data/app/views/parts/modules/_alerts.haml +11 -0
- data/app/views/parts/modules/_nav_footer.haml +34 -0
- data/app/views/parts/modules/_nav_header.haml +18 -0
- data/app/views/parts/modules/_panels.haml +9 -0
- data/app/views/parts/modules/_tabs_minimal.haml +11 -0
- data/app/views/parts/modules/_tabs_simple_group.haml +11 -0
- data/app/views/parts/modules/_tabs_simple_group_toggle.haml +11 -0
- data/app/views/parts/modules/_tabs_toggle.haml +5 -0
- data/app/views/parts/modules/_tabs_traditional.haml +11 -0
- data/app/views/shared/_placeholder_text.html.haml +1 -0
- data/app/views/shared/_title.html.haml +8 -0
- data/app/views/shared/_ui_nav.html.haml +5 -0
- data/app/views/ui/alert.html.haml +35 -0
- data/app/views/ui/buttons.html.haml +116 -0
- data/app/views/ui/footer.html.haml +69 -0
- data/app/views/ui/forms/_vertical_form.haml +7 -0
- data/app/views/ui/forms.html.haml +59 -0
- data/app/views/ui/grids.html.haml +18 -0
- data/app/views/ui/index.html.haml +5 -0
- data/app/views/ui/labels.html.haml +15 -0
- data/app/views/ui/modules/panel.html.haml +3 -0
- data/app/views/ui/nav.html.haml +48 -0
- data/app/views/ui/tabs.html.haml +171 -0
- data/app/views/ui/typography.html.haml +118 -0
- data/db/development.sqlite3 +0 -0
- data/db/seeds.rb +7 -0
- data/doc/README_FOR_APP +2 -0
- data/lib/assets/.gitkeep +0 -0
- data/lib/plinth/version.rb +3 -0
- data/lib/plinth.rb +11 -0
- data/lib/tasks/.gitkeep +0 -0
- data/lib/templates/haml/scaffold/_form.html.haml +8 -0
- data/log/.gitkeep +0 -0
- data/plinth.gemspec +33 -0
- data/public/404.html +26 -0
- data/public/422.html +26 -0
- data/public/500.html +25 -0
- data/public/favicon.ico +0 -0
- data/public/javascripts/LICENSE.html +158 -0
- data/public/javascripts/README.md.html +163 -0
- data/public/javascripts/assets/codo.css +1 -0
- data/public/javascripts/assets/codo.js +21 -0
- data/public/javascripts/assets/search_data.js +1 -0
- data/public/javascripts/class_index.html +215 -0
- data/public/javascripts/class_list.html +58 -0
- data/public/javascripts/classes/Close.html +259 -0
- data/public/javascripts/classes/GAEvent.html +231 -0
- data/public/javascripts/classes/ResizeHandler.html +225 -0
- data/public/javascripts/classes/Switch.html +318 -0
- data/public/javascripts/classes/TBGForm.html +373 -0
- data/public/javascripts/extra_list.html +36 -0
- data/public/javascripts/file_list.html +74 -0
- data/public/javascripts/files/styleguide/plugins/tbg-close.js.coffee.html +160 -0
- data/public/javascripts/files/styleguide/plugins/tbg-forms.js.coffee.html +160 -0
- data/public/javascripts/files/styleguide/plugins/tbg-ga-events.js.coffee.html +160 -0
- data/public/javascripts/files/styleguide/plugins/tbg-respinsiveresize.js.coffee.html +160 -0
- data/public/javascripts/files/styleguide/plugins/tbg-switch.js.coffee.html +160 -0
- data/public/javascripts/index.html +14 -0
- data/public/javascripts/method_list.html +187 -0
- data/public/javascripts/mixin_list.html +28 -0
- data/public/robots.txt +5 -0
- data/script/rails +6 -0
- data/spec/javascripts/fixtures/plugins/tbg-close_fixture.html.haml +4 -0
- data/spec/javascripts/fixtures/plugins/tbg-forms_fixture.html.haml +12 -0
- data/spec/javascripts/fixtures/plugins/tbg-ga-events_fixture.html.haml +9 -0
- data/spec/javascripts/fixtures/plugins/tbg-switch_fixture.html.haml +11 -0
- data/spec/javascripts/plugins/tbg-close_spec.js.coffee +54 -0
- data/spec/javascripts/plugins/tbg-forms_spec.js.coffee +87 -0
- data/spec/javascripts/plugins/tbg-ga-events_spec.js.coffee +83 -0
- data/spec/javascripts/plugins/tbg-switch_spec.js.coffee +96 -0
- data/spec/javascripts/spec.js.coffee +2 -0
- data/vendor/assets/fonts/ss-social-circle.eot +0 -0
- data/vendor/assets/fonts/ss-social-circle.svg +139 -0
- data/vendor/assets/fonts/ss-social-circle.ttf +0 -0
- data/vendor/assets/fonts/ss-social-circle.woff +0 -0
- data/vendor/assets/fonts/ss-social-regular.eot +0 -0
- data/vendor/assets/fonts/ss-social-regular.svg +133 -0
- data/vendor/assets/fonts/ss-social-regular.ttf +0 -0
- data/vendor/assets/fonts/ss-social-regular.woff +0 -0
- data/vendor/assets/fonts/ss-social.js +75 -0
- data/vendor/assets/fonts/ss-standard.eot +0 -0
- data/vendor/assets/fonts/ss-standard.js +75 -0
- data/vendor/assets/fonts/ss-standard.svg +207 -0
- data/vendor/assets/fonts/ss-standard.ttf +0 -0
- data/vendor/assets/fonts/ss-standard.woff +0 -0
- data/vendor/assets/images/background.png +0 -0
- data/vendor/assets/images/logos/sb-logo-white.png +0 -0
- data/vendor/assets/images/logos/sb-logo-white.svg +5 -0
- data/vendor/assets/images/middleman.png +0 -0
- data/vendor/assets/index.html.haml +8 -0
- data/vendor/assets/javascripts/.gitkeep +0 -0
- data/vendor/assets/javascripts/plinth/lib/handlebars.js +3 -0
- data/vendor/assets/javascripts/plinth/lib/jquery.fitvids.js +81 -0
- data/vendor/assets/javascripts/plinth/lib/ss-social.js +75 -0
- data/vendor/assets/javascripts/plinth/lib/ss-standard.js +78 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/assets/codo.css +1 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/assets/codo.js +21 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/assets/search_data.js +1 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/class_index.html +194 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/class_list.html +58 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/classes/Close.html +215 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/classes/GAEvent.html +235 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/classes/ResizeHandler.html +192 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/classes/Switch.html +233 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/classes/TBGForm.html +318 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/extra_list.html +30 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/file_list.html +58 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/files/tbg-close.js.coffee.html +154 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/files/tbg-forms.js.coffee.html +154 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/files/tbg-ga-events.js.coffee.html +154 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/files/tbg-respinsiveresize.js.coffee.html +154 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/files/tbg-switch.js.coffee.html +154 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/index.html +14 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/method_list.html +163 -0
- data/vendor/assets/javascripts/plinth/plugins/doc/mixin_list.html +28 -0
- data/vendor/assets/javascripts/plinth/plugins/tbg-close.js.coffee +97 -0
- data/vendor/assets/javascripts/plinth/plugins/tbg-forms.js.coffee +156 -0
- data/vendor/assets/javascripts/plinth/plugins/tbg-ga-events.js.coffee +107 -0
- data/vendor/assets/javascripts/plinth/plugins/tbg-respinsiveresize.js.coffee +73 -0
- data/vendor/assets/javascripts/plinth/plugins/tbg-switch.js.coffee +121 -0
- data/vendor/assets/stylesheets/.gitkeep +0 -0
- data/vendor/assets/stylesheets/_functions.scss +28 -0
- data/vendor/assets/stylesheets/_mixins.css.scss +273 -0
- data/vendor/assets/stylesheets/_settings.css.scss +120 -0
- data/vendor/assets/stylesheets/plinth/base/_all.css.scss +7 -0
- data/vendor/assets/stylesheets/plinth/base/_buttons.css.scss +166 -0
- data/vendor/assets/stylesheets/plinth/base/_form.css.scss +196 -0
- data/vendor/assets/stylesheets/plinth/base/_labels.css.scss +58 -0
- data/vendor/assets/stylesheets/plinth/base/_lists.css.scss +57 -0
- data/vendor/assets/stylesheets/plinth/base/_reset.css.scss +284 -0
- data/vendor/assets/stylesheets/plinth/base/_type.css.scss +328 -0
- data/vendor/assets/stylesheets/plinth/base/webfonts/_all.css.scss +2 -0
- data/vendor/assets/stylesheets/plinth/base/webfonts/ss-social.css.scss +57 -0
- data/vendor/assets/stylesheets/plinth/base/webfonts/ss-standard.css.scss +48 -0
- data/vendor/assets/stylesheets/plinth/grid/_grid.css.scss +127 -0
- data/vendor/assets/stylesheets/plinth/modules/_alert.css.scss +71 -0
- data/vendor/assets/stylesheets/plinth/modules/_all-grid.css.scss +1 -0
- data/vendor/assets/stylesheets/plinth/modules/_all-no-grid.css.scss +4 -0
- data/vendor/assets/stylesheets/plinth/modules/_footer.css.scss +93 -0
- data/vendor/assets/stylesheets/plinth/modules/_nav.css.scss +106 -0
- data/vendor/assets/stylesheets/plinth/modules/_panel.css.scss +28 -0
- data/vendor/assets/stylesheets/plinth/modules/_switch.css.scss +88 -0
- data/vendor/assets/stylesheets/plinth.css.scss +15 -0
- data/vendor/assets/views/buttons/_buttons.haml +9 -0
- data/vendor/assets/views/forms/_vertical_form.haml +7 -0
- data/vendor/assets/views/type/_headings.haml +6 -0
- data/vendor/assets/views/type/_paragraphs.haml +4 -0
- metadata +537 -0
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
.row
|
|
2
|
+
.mother-three.mother-push-one.column= render "ui_nav"
|
|
3
|
+
.mother-seven.mother-pull-one.column
|
|
4
|
+
|
|
5
|
+
%h1 Base#grids
|
|
6
|
+
%p Find me in app/views/base/grids.html.haml
|
|
7
|
+
|
|
8
|
+
%h2 Grid Settings
|
|
9
|
+
%p Setting the breakpoints...
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
%pre
|
|
13
|
+
%code
|
|
14
|
+
$mob: 'mobile-', 1, 20px, "max-width: 780px" ;
|
|
15
|
+
$desk: '', $columns, $column-gutter;
|
|
16
|
+
\// Add breakpoints to grid
|
|
17
|
+
$grids : $desk, $mob !default;
|
|
18
|
+
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
.row
|
|
2
|
+
.mother-three.mother-push-one.column= render "ui_nav"
|
|
3
|
+
.mother-seven.mother-pull-one.column
|
|
4
|
+
%h2 Labels
|
|
5
|
+
|
|
6
|
+
%hr
|
|
7
|
+
|
|
8
|
+
= example do
|
|
9
|
+
- ['','orange','green', 'blue'].each do |color|
|
|
10
|
+
%span{:class=>"label #{color}"}= (color.length > 0) ? ".#{color}.label" : ".label"
|
|
11
|
+
:coderay
|
|
12
|
+
#!haml
|
|
13
|
+
|
|
14
|
+
%span{:class=>"label [color]"} .[color].label
|
|
15
|
+
// end
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
.row
|
|
2
|
+
.mother-three.mother-push-one.column= render "ui_nav"
|
|
3
|
+
.mother-seven.mother-pull-one.column
|
|
4
|
+
|
|
5
|
+
%h2 Navigation
|
|
6
|
+
|
|
7
|
+
%hr
|
|
8
|
+
|
|
9
|
+
%h3.h5 Global Nav
|
|
10
|
+
|
|
11
|
+
%p Simplest form of the switch. In this version the switch is a simple reveal plugin with no off state.
|
|
12
|
+
|
|
13
|
+
= example do
|
|
14
|
+
%nav.nav-global
|
|
15
|
+
#nav-global-2.nav-collapse.baby-switch-content<
|
|
16
|
+
%ul.nav-items.collapse><
|
|
17
|
+
%li.is-active><
|
|
18
|
+
= link_to "stuff", "stuff"
|
|
19
|
+
%li><
|
|
20
|
+
= link_to "things", "things"
|
|
21
|
+
%li><
|
|
22
|
+
= link_to "bits", "bits"
|
|
23
|
+
.nav-mobile-switch.baby-only
|
|
24
|
+
%a{ :href => "#nav-global-2", :data => {:switch => true, :"switch-toggle" => true} }><
|
|
25
|
+
%span>< Show navigation
|
|
26
|
+
%i><
|
|
27
|
+
%i><
|
|
28
|
+
%i><
|
|
29
|
+
|
|
30
|
+
:coderay
|
|
31
|
+
#!haml
|
|
32
|
+
%nav.nav-global
|
|
33
|
+
#nav-global.nav-collapse.baby-switch-content<
|
|
34
|
+
%ul.nav-items.collapse><
|
|
35
|
+
%li.is-active><
|
|
36
|
+
= link_to "stuff", "stuff"
|
|
37
|
+
%li><
|
|
38
|
+
= link_to "things", "things"
|
|
39
|
+
%li><
|
|
40
|
+
= link_to "bits", "bits"
|
|
41
|
+
.nav-mobile-switch.baby-only
|
|
42
|
+
%a{ :href => "#nav-global", :data => {:switch => true, :"switch-toggle" => true} }><
|
|
43
|
+
%span>< Show navigation
|
|
44
|
+
%i><
|
|
45
|
+
%i><
|
|
46
|
+
%i><
|
|
47
|
+
// end
|
|
48
|
+
|
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
.row
|
|
2
|
+
.mother-three.mother-push-one.column= render "ui_nav"
|
|
3
|
+
.mother-seven.mother-pull-one.column
|
|
4
|
+
|
|
5
|
+
%h2 Tabs
|
|
6
|
+
|
|
7
|
+
%p.standout
|
|
8
|
+
Tabs use the
|
|
9
|
+
%code switch
|
|
10
|
+
plugin to manage active state.
|
|
11
|
+
|
|
12
|
+
%h3.h5 data-switch options
|
|
13
|
+
|
|
14
|
+
%dl
|
|
15
|
+
%dt
|
|
16
|
+
%code data-switch="true"
|
|
17
|
+
%dd An event listener will initalise the switch plugin when an element with this attribute is clicked.
|
|
18
|
+
%dt
|
|
19
|
+
%code data-switch-group="[group name]"
|
|
20
|
+
%dd By giving an element a group name then the plugin can change the state of other switches within the same group.
|
|
21
|
+
%dt
|
|
22
|
+
%code data-switch-toggle
|
|
23
|
+
%dd This option enables a switch to toggle it's state upon click.
|
|
24
|
+
|
|
25
|
+
%p= link_to "View Switch Plugin Tests", "/jasmine?spec=Switch%3A"
|
|
26
|
+
|
|
27
|
+
%hr
|
|
28
|
+
|
|
29
|
+
%h3.h5 Minimal switch
|
|
30
|
+
|
|
31
|
+
%p Simplest form of the switch. In this version the switch is a simple reveal plugin with no off state.
|
|
32
|
+
|
|
33
|
+
= example do
|
|
34
|
+
%ul
|
|
35
|
+
%li= link_to "Link 1", "#target1-1", :data => { :switch => true }
|
|
36
|
+
%li= link_to "Link 2", "#target2-1", :data => { :switch => true }
|
|
37
|
+
%li= link_to "Link 3", "#target3-1", :data => { :switch => true }
|
|
38
|
+
%div.switch-content{:id => "target1-1"} switch content 1
|
|
39
|
+
%div.switch-content{:id => "target2-1"} switch content 2
|
|
40
|
+
%div.switch-content{:id => "target3-1<D-s>"} switch content 3
|
|
41
|
+
|
|
42
|
+
:coderay
|
|
43
|
+
#!haml
|
|
44
|
+
|
|
45
|
+
%ul
|
|
46
|
+
%li
|
|
47
|
+
= link_to "Link 1", "#target1", :data => { :switch => true }
|
|
48
|
+
%li
|
|
49
|
+
= link_to "Link 2", "#target2", :data => { :switch => true }
|
|
50
|
+
%li
|
|
51
|
+
= link_to "Link 3", "#target3", :data => { :switch => true }
|
|
52
|
+
%div.switch-content{:id => "target1"} switch content 1
|
|
53
|
+
%div.switch-content{:id => "target2"} switch content 2
|
|
54
|
+
%div.switch-content{:id => "target3"} switch content 3
|
|
55
|
+
// end
|
|
56
|
+
|
|
57
|
+
%hr
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
%h3.h5 Toggle switch
|
|
61
|
+
|
|
62
|
+
%p Content can be toggled and it's state has no effect on other elements.
|
|
63
|
+
|
|
64
|
+
= example do
|
|
65
|
+
%ul
|
|
66
|
+
%li= link_to "Link 1", "#target1-2", :data => { :switch => true, :"switch-toggle" => true }
|
|
67
|
+
%li= link_to "Link 2", "#target2-2", :data => { :switch => true, :"switch-toggle" => true }
|
|
68
|
+
%li= link_to "Link 3", "#target3-2", :data => { :switch => true, :"switch-toggle" => true }
|
|
69
|
+
%div.switch-content{:id => "target1-2"} switch content 1
|
|
70
|
+
%div.switch-content{:id => "target2-2"} switch content 2
|
|
71
|
+
%div.switch-content{:id => "target3-2"} switch content 3
|
|
72
|
+
|
|
73
|
+
:coderay
|
|
74
|
+
#!haml
|
|
75
|
+
|
|
76
|
+
%ul
|
|
77
|
+
%li
|
|
78
|
+
= link_to "Link 1", "#target1", :data => { :switch => true, :"switch-toggle" => true }
|
|
79
|
+
%li
|
|
80
|
+
= link_to "Link 2", "#target2", :data => { :switch => true, :"switch-toggle" => true }
|
|
81
|
+
%li
|
|
82
|
+
= link_to "Link 3", "#target3", :data => { :switch => true, :"switch-toggle" => true }
|
|
83
|
+
%div.switch-content{:id => "target1"} switch content 1
|
|
84
|
+
%div.switch-content{:id => "target2"} switch content 2
|
|
85
|
+
%div.switch-content{:id => "target3"} switch content 3
|
|
86
|
+
// end
|
|
87
|
+
|
|
88
|
+
%hr
|
|
89
|
+
|
|
90
|
+
%h3.h5 Simple Groups
|
|
91
|
+
|
|
92
|
+
%p
|
|
93
|
+
By adding the
|
|
94
|
+
%code switch-group
|
|
95
|
+
data element we can make groups of switches reactive to each others state.
|
|
96
|
+
|
|
97
|
+
= example do
|
|
98
|
+
%ul
|
|
99
|
+
%li.is-active= link_to "Drop down link 1", "#target1-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg1-2"
|
|
100
|
+
%li= link_to "Drop down link 2", "#target2-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg2-2"
|
|
101
|
+
%li= link_to "Drop down link 3", "#target3-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg3-2"
|
|
102
|
+
%div.switch-content.is-active{:id => "target1-3"}= "switch content 1"
|
|
103
|
+
%div.switch-content{:id => "target2-3"}= "switch content 2"
|
|
104
|
+
%div.switch-content{:id => "target3-3"}= "switch content 3"
|
|
105
|
+
|
|
106
|
+
:coderay
|
|
107
|
+
#!haml
|
|
108
|
+
|
|
109
|
+
%ul.tabs
|
|
110
|
+
%li.is-active= link_to "Drop down link 1", "#target1-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg1-2"
|
|
111
|
+
%li= link_to "Drop down link 2", "#target2-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg2-2"
|
|
112
|
+
%li= link_to "Drop down link 3", "#target3-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg3-2"
|
|
113
|
+
%div.switch-content.is-active{:id => "target1-3"}= "switch content 1"
|
|
114
|
+
%div.switch-content{:id => "target2-3"}= "switch content 2"
|
|
115
|
+
%div.switch-content{:id => "target3-3"}= "switch content 3"
|
|
116
|
+
// end
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
|
|
120
|
+
%hr
|
|
121
|
+
|
|
122
|
+
%h3.h5 Simple Groups with toggle
|
|
123
|
+
|
|
124
|
+
= example do
|
|
125
|
+
%ul
|
|
126
|
+
%li= link_to "Link 1", "#target1-5", :data => { :switch => true, :"switch-toggle" => true , :"switch-group" => "group-1" }
|
|
127
|
+
%li= link_to "Link 2", "#target2-5", :data => { :switch => true, :"switch-toggle" => true, :"switch-group" => "group-1" }
|
|
128
|
+
%li= link_to "Link 3", "#target3-5", :data => { :switch => true, :"switch-toggle" => true, :"switch-group" => "group-1" }
|
|
129
|
+
%div.switch-content{:id => "target1-5"} switch content 1
|
|
130
|
+
%div.switch-content{:id => "target2-5"} switch content 2
|
|
131
|
+
%div.switch-content{:id => "target3-5"} switch content 3
|
|
132
|
+
|
|
133
|
+
:coderay
|
|
134
|
+
#!haml
|
|
135
|
+
|
|
136
|
+
%ul.tabs
|
|
137
|
+
%li.is-active= link_to "Drop down link 1", "#target1-3", :data => { :switch => true, :"switch-group" => "group-1", :"switch-toggle" => true }, :id => "eg1-2"
|
|
138
|
+
%li= link_to "Drop down link 2", "#target2-3", :data => { :switch => true, :"switch-group" => "group-1", :"switch-toggle" => true }, :id => "eg2-2"
|
|
139
|
+
%li= link_to "Drop down link 3", "#target3-3", :data => { :switch => true, :"switch-group" => "group-1", :"switch-toggle" => true }, :id => "eg3-2"
|
|
140
|
+
%div.switch-content.is-active{:id => "target1-3"}= "switch content 1"
|
|
141
|
+
%div.switch-content{:id => "target2-3"}= "switch content 2"
|
|
142
|
+
%div.switch-content{:id => "target3-3"}= "switch content 3"
|
|
143
|
+
// end
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
|
|
147
|
+
|
|
148
|
+
%hr
|
|
149
|
+
|
|
150
|
+
%h3.h5 Groups (with tabs)
|
|
151
|
+
|
|
152
|
+
= example do
|
|
153
|
+
%ul.tabs
|
|
154
|
+
%li.is-active= link_to "Drop down link 1", "#target1-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg1-2"
|
|
155
|
+
%li= link_to "Drop down link 2", "#target2-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg2-2"
|
|
156
|
+
%li= link_to "Drop down link 3", "#target3-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg3-2"
|
|
157
|
+
%div.switch-content.is-active{:id => "target1-3"}= "switch content 1"
|
|
158
|
+
%div.switch-content{:id => "target2-3"}= "switch content 2"
|
|
159
|
+
%div.switch-content{:id => "target3-3"}= "switch content 3"
|
|
160
|
+
|
|
161
|
+
:coderay
|
|
162
|
+
#!haml
|
|
163
|
+
|
|
164
|
+
%ul.tabs
|
|
165
|
+
%li.is-active= link_to "Drop down link 1", "#target1-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg1-2"
|
|
166
|
+
%li= link_to "Drop down link 2", "#target2-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg2-2"
|
|
167
|
+
%li= link_to "Drop down link 3", "#target3-3", :data => { :switch => true, :"switch-group" => "group-1" }, :id => "eg3-2"
|
|
168
|
+
%div.switch-content.is-active{:id => "target1-3"}= "switch content 1"
|
|
169
|
+
%div.switch-content{:id => "target2-3"}= "switch content 2"
|
|
170
|
+
%div.switch-content{:id => "target3-3"}= "switch content 3"
|
|
171
|
+
// end
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
|
|
2
|
+
%h2 Basic Typography
|
|
3
|
+
|
|
4
|
+
= render :partial => "shared/placeholder_text"
|
|
5
|
+
|
|
6
|
+
%hr
|
|
7
|
+
|
|
8
|
+
%h3.h5 Headings
|
|
9
|
+
|
|
10
|
+
.h1 Heading 1
|
|
11
|
+
.h2 Heading 2
|
|
12
|
+
.h3 Heading 3
|
|
13
|
+
.h4 Heading 4
|
|
14
|
+
.h5 Heading 5
|
|
15
|
+
:coderay
|
|
16
|
+
#!haml
|
|
17
|
+
|
|
18
|
+
%h1 Heading 1
|
|
19
|
+
%h2 Heading 2
|
|
20
|
+
%h3 Heading 3
|
|
21
|
+
%h4 Heading 4
|
|
22
|
+
%h5 Heading 5
|
|
23
|
+
|
|
24
|
+
// All heading styles can also be reproduced using .h{n}
|
|
25
|
+
%hr
|
|
26
|
+
|
|
27
|
+
%h3.h5 Body text
|
|
28
|
+
|
|
29
|
+
%p Normal Paragraph - Lebowski ipsum I didn't blame anyone for the loss of my legs, some chinaman in Korea took them from me but I went out and achieved anyway. Dolor sit amet, consectetur adipiscing elit praesent ac magna justo.
|
|
30
|
+
|
|
31
|
+
:coderay
|
|
32
|
+
#!haml
|
|
33
|
+
|
|
34
|
+
%p Lebowski ipsum I didn't…
|
|
35
|
+
// end
|
|
36
|
+
|
|
37
|
+
%h3.h5 Standout
|
|
38
|
+
|
|
39
|
+
%p.standout Standout Paragraph - Lebowski ipsum I didn't blame anyone for the loss of my legs, some chinaman in Korea took them from me but I went out and achieved anyway. Dolor sit amet, consectetur adipiscing elit praesent ac magna justo.
|
|
40
|
+
|
|
41
|
+
:coderay
|
|
42
|
+
#!haml
|
|
43
|
+
|
|
44
|
+
%p.standout Lebowski ipsum I didn't…
|
|
45
|
+
// end
|
|
46
|
+
|
|
47
|
+
%h3.h5 Body text helper classes
|
|
48
|
+
|
|
49
|
+
%p.support Support text - Lebowski ipsum I didn't blame anyone for the loss of my legs, some chinaman in Korea took them from me but I went out and achieved anyway. Dolor sit amet, consectetur adipiscing elit praesent ac magna justo.
|
|
50
|
+
%p.secondary Secondary text - Lebowski ipsum I didn't blame anyone for the loss of my legs, some chinaman in Korea took them from me but I went out and achieved anyway. Dolor sit amet, consectetur adipiscing elit praesent ac magna justo. Pellentesque ac lectus quis elit blandit fringilla a ut turpis.
|
|
51
|
+
|
|
52
|
+
:coderay
|
|
53
|
+
#!haml
|
|
54
|
+
|
|
55
|
+
%p.support Lebowski ipsum I didn't…
|
|
56
|
+
%p.secondary Lebowski ipsum I didn't…
|
|
57
|
+
// end
|
|
58
|
+
|
|
59
|
+
%hr
|
|
60
|
+
|
|
61
|
+
%h3.h5 Links
|
|
62
|
+
|
|
63
|
+
%a{:href=>"#my_link"} Text link
|
|
64
|
+
%br
|
|
65
|
+
%a.is-active{:href=>"#my_link"} Text link hover/active
|
|
66
|
+
%br
|
|
67
|
+
%a.prominent{:href=>"#my_link"} Prominent text link
|
|
68
|
+
%br
|
|
69
|
+
%a.prominent.is-active{:href=>"#my_link"} Prominent text link hover/active
|
|
70
|
+
|
|
71
|
+
:coderay
|
|
72
|
+
#!haml
|
|
73
|
+
|
|
74
|
+
%a{:href=>"#my_link"} Text link
|
|
75
|
+
%a.is-active{:href=>"#my_link"} Text link hover/active
|
|
76
|
+
%a.prominent{:href=>"#my_link"} Prominent text link
|
|
77
|
+
%a.prominent.is-active{:href=>"#my_link"} Prominent text link hover/active
|
|
78
|
+
// end
|
|
79
|
+
|
|
80
|
+
%hr
|
|
81
|
+
|
|
82
|
+
%h3.h5 Shouts
|
|
83
|
+
|
|
84
|
+
.shout Shout Text
|
|
85
|
+
.small.shout Small shout text
|
|
86
|
+
.medium.shout Medium shout text
|
|
87
|
+
.large.shout Large shout text
|
|
88
|
+
:coderay
|
|
89
|
+
#!haml
|
|
90
|
+
|
|
91
|
+
.shout Shout Text
|
|
92
|
+
.small.shout Small shout text
|
|
93
|
+
.medium.shout Medium shout text
|
|
94
|
+
.large.shout Large shout text
|
|
95
|
+
// end
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
%hr
|
|
99
|
+
|
|
100
|
+
%h2 Lists
|
|
101
|
+
|
|
102
|
+
%h3.h5 Action lists
|
|
103
|
+
|
|
104
|
+
%ul.action-list
|
|
105
|
+
%li
|
|
106
|
+
%a{:href=>"my_url"} Item 1
|
|
107
|
+
%li
|
|
108
|
+
%a{:href=>"my_url"} item 2
|
|
109
|
+
:coderay
|
|
110
|
+
#!haml
|
|
111
|
+
|
|
112
|
+
%ul.action-list
|
|
113
|
+
%li
|
|
114
|
+
%a{:href=>"my_url"} Item 1
|
|
115
|
+
%li
|
|
116
|
+
%a{:href=>"my_url"} Item 2
|
|
117
|
+
// end
|
|
118
|
+
|
|
File without changes
|
data/db/seeds.rb
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
# This file should contain all the record creation needed to seed the database with its default values.
|
|
2
|
+
# The data can then be loaded with the rake db:seed (or created alongside the db with db:setup).
|
|
3
|
+
#
|
|
4
|
+
# Examples:
|
|
5
|
+
#
|
|
6
|
+
# cities = City.create([{ name: 'Chicago' }, { name: 'Copenhagen' }])
|
|
7
|
+
# Mayor.create(name: 'Emanuel', city: cities.first)
|
data/doc/README_FOR_APP
ADDED
data/lib/assets/.gitkeep
ADDED
|
File without changes
|
data/lib/plinth.rb
ADDED
data/lib/tasks/.gitkeep
ADDED
|
File without changes
|
data/log/.gitkeep
ADDED
|
File without changes
|
data/plinth.gemspec
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
|
2
|
+
require File.expand_path('../lib/plinth/version', __FILE__)
|
|
3
|
+
|
|
4
|
+
Gem::Specification.new do |gem|
|
|
5
|
+
gem.authors = ["Adam Taylor", "Vincent Siebert"]
|
|
6
|
+
gem.email = ["ad@adtaylor.co.uk", "vincent@siebert.im"]
|
|
7
|
+
gem.description = %q{Plinth - basic framework}
|
|
8
|
+
gem.summary = %q{Plinth is used internally at the Beans Group in order
|
|
9
|
+
to facilitate speedy rollouts of new sites using similar interaction libraries
|
|
10
|
+
and patterns. It also allows for rapid prototyping of products.}
|
|
11
|
+
gem.homepage = "https://github.com/thebeansgroup/plinth"
|
|
12
|
+
|
|
13
|
+
gem.files = `git ls-files`.split($\).grep(/^(?!config)/)
|
|
14
|
+
gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
|
|
15
|
+
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
|
16
|
+
gem.name = "plinth"
|
|
17
|
+
gem.require_paths = ["lib"]
|
|
18
|
+
gem.version = Plinth::VERSION
|
|
19
|
+
|
|
20
|
+
gem.add_dependency "haml", [">= 3.1", '< 4.1']
|
|
21
|
+
gem.add_dependency "activesupport", [">= 3.1", '< 4.1']
|
|
22
|
+
gem.add_dependency "actionpack", [">= 3.1", '< 4.1']
|
|
23
|
+
gem.add_dependency "railties", [">= 3.1", '< 4.1']
|
|
24
|
+
gem.add_dependency "modular-scale", [">= 1.0", '< 2.0']
|
|
25
|
+
gem.add_dependency "compass-rails", ['>= 1.0', '< 2.0']
|
|
26
|
+
gem.add_dependency "sass-rails", ['>= 3.1', '< 4.1']
|
|
27
|
+
gem.add_dependency "haml-coderay", ['>= 0.2', '< 0.3']
|
|
28
|
+
|
|
29
|
+
gem.add_development_dependency "rails", [">= 3.1", '< 4.1']
|
|
30
|
+
gem.add_development_dependency "bundler", ['>= 1.3', '< 2.0']
|
|
31
|
+
gem.add_development_dependency "sqlite3", ['>= 1.3', '< 2.0']
|
|
32
|
+
|
|
33
|
+
end
|
data/public/404.html
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html>
|
|
3
|
+
<head>
|
|
4
|
+
<title>The page you were looking for doesn't exist (404)</title>
|
|
5
|
+
<style type="text/css">
|
|
6
|
+
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
|
7
|
+
div.dialog {
|
|
8
|
+
width: 25em;
|
|
9
|
+
padding: 0 4em;
|
|
10
|
+
margin: 4em auto 0 auto;
|
|
11
|
+
border: 1px solid #ccc;
|
|
12
|
+
border-right-color: #999;
|
|
13
|
+
border-bottom-color: #999;
|
|
14
|
+
}
|
|
15
|
+
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
|
16
|
+
</style>
|
|
17
|
+
</head>
|
|
18
|
+
|
|
19
|
+
<body>
|
|
20
|
+
<!-- This file lives in public/404.html -->
|
|
21
|
+
<div class="dialog">
|
|
22
|
+
<h1>The page you were looking for doesn't exist.</h1>
|
|
23
|
+
<p>You may have mistyped the address or the page may have moved.</p>
|
|
24
|
+
</div>
|
|
25
|
+
</body>
|
|
26
|
+
</html>
|
data/public/422.html
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html>
|
|
3
|
+
<head>
|
|
4
|
+
<title>The change you wanted was rejected (422)</title>
|
|
5
|
+
<style type="text/css">
|
|
6
|
+
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
|
7
|
+
div.dialog {
|
|
8
|
+
width: 25em;
|
|
9
|
+
padding: 0 4em;
|
|
10
|
+
margin: 4em auto 0 auto;
|
|
11
|
+
border: 1px solid #ccc;
|
|
12
|
+
border-right-color: #999;
|
|
13
|
+
border-bottom-color: #999;
|
|
14
|
+
}
|
|
15
|
+
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
|
16
|
+
</style>
|
|
17
|
+
</head>
|
|
18
|
+
|
|
19
|
+
<body>
|
|
20
|
+
<!-- This file lives in public/422.html -->
|
|
21
|
+
<div class="dialog">
|
|
22
|
+
<h1>The change you wanted was rejected.</h1>
|
|
23
|
+
<p>Maybe you tried to change something you didn't have access to.</p>
|
|
24
|
+
</div>
|
|
25
|
+
</body>
|
|
26
|
+
</html>
|
data/public/500.html
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html>
|
|
3
|
+
<head>
|
|
4
|
+
<title>We're sorry, but something went wrong (500)</title>
|
|
5
|
+
<style type="text/css">
|
|
6
|
+
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
|
7
|
+
div.dialog {
|
|
8
|
+
width: 25em;
|
|
9
|
+
padding: 0 4em;
|
|
10
|
+
margin: 4em auto 0 auto;
|
|
11
|
+
border: 1px solid #ccc;
|
|
12
|
+
border-right-color: #999;
|
|
13
|
+
border-bottom-color: #999;
|
|
14
|
+
}
|
|
15
|
+
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
|
16
|
+
</style>
|
|
17
|
+
</head>
|
|
18
|
+
|
|
19
|
+
<body>
|
|
20
|
+
<!-- This file lives in public/500.html -->
|
|
21
|
+
<div class="dialog">
|
|
22
|
+
<h1>We're sorry, but something went wrong.</h1>
|
|
23
|
+
</div>
|
|
24
|
+
</body>
|
|
25
|
+
</html>
|
data/public/favicon.ico
ADDED
|
File without changes
|