dlegr250_material_design 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (72) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +9 -0
  3. data/.rspec +2 -0
  4. data/.travis.yml +4 -0
  5. data/Gemfile +4 -0
  6. data/README.md +66 -0
  7. data/Rakefile +6 -0
  8. data/app/controllers/styleguide_controller.rb +5 -0
  9. data/app/views/styleguide/_buttons.html.erb +79 -0
  10. data/app/views/styleguide/_menus.html.erb +189 -0
  11. data/app/views/styleguide/_navigation.html.erb +28 -0
  12. data/app/views/styleguide/index.html.erb +9 -0
  13. data/bin/console +14 -0
  14. data/bin/setup +7 -0
  15. data/dlegr250_material_design.gemspec +34 -0
  16. data/lib/dlegr250_material_design.rb +6 -0
  17. data/lib/dlegr250_material_design/version.rb +3 -0
  18. data/vendor/assets/javascripts/base/init.js.coffee +14 -0
  19. data/vendor/assets/javascripts/components/dialog.coffee +54 -0
  20. data/vendor/assets/javascripts/components/forms.coffee +17 -0
  21. data/vendor/assets/javascripts/components/layout.coffee +76 -0
  22. data/vendor/assets/javascripts/components/menus.coffee +87 -0
  23. data/vendor/assets/javascripts/components/snackbar_handler.coffee +8 -0
  24. data/vendor/assets/javascripts/components/tabs.coffee +18 -0
  25. data/vendor/assets/javascripts/components/utility.coffee +8 -0
  26. data/vendor/assets/javascripts/dlegr250_material_design.js +20 -0
  27. data/vendor/assets/javascripts/extensions/coffeescript.js.coffee +9 -0
  28. data/vendor/assets/javascripts/extensions/jquery.js.coffee +30 -0
  29. data/vendor/assets/javascripts/third_party/hammer.min.js +7 -0
  30. data/vendor/assets/javascripts/third_party/handlebars.latest.js +4454 -0
  31. data/vendor/assets/javascripts/third_party/jquery.hammer.js +33 -0
  32. data/vendor/assets/javascripts/third_party/snackbarlight.js +218 -0
  33. data/vendor/assets/stylesheets/base/base.scss +73 -0
  34. data/vendor/assets/stylesheets/base/global_classes.scss +261 -0
  35. data/vendor/assets/stylesheets/base/mixins.scss +202 -0
  36. data/vendor/assets/stylesheets/base/normalize.scss +229 -0
  37. data/vendor/assets/stylesheets/base/variables.scss +177 -0
  38. data/vendor/assets/stylesheets/components/badges.scss +28 -0
  39. data/vendor/assets/stylesheets/components/blank_slates.scss +58 -0
  40. data/vendor/assets/stylesheets/components/boxes.scss +34 -0
  41. data/vendor/assets/stylesheets/components/buttons.scss +225 -0
  42. data/vendor/assets/stylesheets/components/cards.scss +110 -0
  43. data/vendor/assets/stylesheets/components/code.scss +13 -0
  44. data/vendor/assets/stylesheets/components/dialogs.scss +57 -0
  45. data/vendor/assets/stylesheets/components/dividers.scss +35 -0
  46. data/vendor/assets/stylesheets/components/forms/error_messages.scss +27 -0
  47. data/vendor/assets/stylesheets/components/forms/fields.scss +56 -0
  48. data/vendor/assets/stylesheets/components/forms/labels.scss +17 -0
  49. data/vendor/assets/stylesheets/components/forms/radios.scss +90 -0
  50. data/vendor/assets/stylesheets/components/forms/selects.scss +15 -0
  51. data/vendor/assets/stylesheets/components/forms/text_fields.scss +38 -0
  52. data/vendor/assets/stylesheets/components/forms/toggles.scss +70 -0
  53. data/vendor/assets/stylesheets/components/lists.scss +242 -0
  54. data/vendor/assets/stylesheets/components/menus.scss +164 -0
  55. data/vendor/assets/stylesheets/components/overlay.scss +27 -0
  56. data/vendor/assets/stylesheets/components/snackbarlight.scss +77 -0
  57. data/vendor/assets/stylesheets/components/spinners.scss +67 -0
  58. data/vendor/assets/stylesheets/components/tabs.scss +62 -0
  59. data/vendor/assets/stylesheets/components/tooltips.scss +75 -0
  60. data/vendor/assets/stylesheets/dlegr250_material_design.scss +47 -0
  61. data/vendor/assets/stylesheets/fonts/material_design_iconic_font.scss +5168 -0
  62. data/vendor/assets/stylesheets/fonts/material_design_iconic_font/Material-Design-Iconic-Font.eot +0 -0
  63. data/vendor/assets/stylesheets/fonts/material_design_iconic_font/Material-Design-Iconic-Font.svg +787 -0
  64. data/vendor/assets/stylesheets/fonts/material_design_iconic_font/Material-Design-Iconic-Font.ttf +0 -0
  65. data/vendor/assets/stylesheets/fonts/material_design_iconic_font/Material-Design-Iconic-Font.woff +0 -0
  66. data/vendor/assets/stylesheets/fonts/material_design_iconic_font/Material-Design-Iconic-Font.woff2 +0 -0
  67. data/vendor/assets/stylesheets/layouts/application/appbar.scss +93 -0
  68. data/vendor/assets/stylesheets/layouts/application/base.scss +27 -0
  69. data/vendor/assets/stylesheets/layouts/application/main.scss +26 -0
  70. data/vendor/assets/stylesheets/layouts/application/sidebars.scss +85 -0
  71. data/vendor/assets/stylesheets/layouts/authentication/base.scss +53 -0
  72. metadata +155 -0
@@ -0,0 +1,93 @@
1
+ //======================================================================
2
+ // EXAMPLE:
3
+ // <div class="appbar">
4
+ // <div class="appbar-nav-icon">
5
+ // <i class="zmdi zmdi-menu appbar-button" role="left-sidebar-toggle"></i>
6
+ // </div>
7
+ // <div class="appbar-title">
8
+ // Title...
9
+ // </div>
10
+ // <div class="appbar-actions">
11
+ // <i class="zmdi zmdi-menu appbar-button" role="right-sidebar-toggle"></i>
12
+ // </div>
13
+ // </div>
14
+ //======================================================================
15
+
16
+ // appbar - base
17
+ //----------------------------------------------------------------------
18
+
19
+ .appbar {
20
+ background-color: $primary-color;
21
+ bottom: auto;
22
+ box-sizing: border-box;
23
+ color: $appbar-text-color;
24
+ height: $appbar-height;
25
+ padding: 0 $spacing-small;
26
+ width: 100%;
27
+ z-index: $layout-depth + 1;
28
+ @include box-shadow(0 2px 5px rgba(0, 0, 0, 0.30));
29
+ @include flex-parent-row();
30
+ }
31
+
32
+ // appbar - nav icon
33
+ //----------------------------------------------------------------------
34
+
35
+ .appbar-nav-icon {
36
+ width: $appbar-button-height;
37
+ margin-right: $spacing-normal;
38
+ }
39
+
40
+ // appbar - title
41
+ //----------------------------------------------------------------------
42
+
43
+ .appbar-title {
44
+ flex: 1; // To fill empty gaps
45
+ font-size: $font-size-large;
46
+ margin-right: $spacing-small;
47
+ overflow: hidden;
48
+ text-overflow: ellipsis;
49
+ white-space: nowrap;
50
+ }
51
+
52
+ // appbar - actions
53
+ //----------------------------------------------------------------------
54
+
55
+ .appbar-actions {
56
+ text-align: right;
57
+
58
+ // TODO test this in multiple browsers to see if it works everywhere...
59
+ // Since standard buttons are not as tall as the appbar-button,
60
+ // there is leftover space and the button clings to the baseline.
61
+ .button {
62
+ margin-top: -10px;
63
+ }
64
+ }
65
+
66
+ // appbar - buttons
67
+ //----------------------------------------------------------------------
68
+
69
+ .appbar-button {
70
+ background-color: $primary-color;
71
+ box-sizing: border-box;
72
+ color: $appbar-button-color;
73
+ cursor: pointer;
74
+ display: inline-block;
75
+ font-size: $font-size-icon;
76
+ height: $appbar-button-height;
77
+ line-height: $appbar-button-height;
78
+ width: $appbar-button-height;
79
+ text-align: center;
80
+ text-decoration: none;
81
+
82
+ @include no-touch-highlight;
83
+ @include rounded-corners(250px);
84
+ @include transition(background 0.2s ease-in-out);
85
+
86
+ &:hover {
87
+ background-color: darken($primary-color, 7%);
88
+ }
89
+
90
+ &:active {
91
+ background-color: darken($primary-color, 12%);
92
+ }
93
+ }
@@ -0,0 +1,27 @@
1
+ //======================================================================
2
+ // Shared styles for all major layout elements.
3
+ //======================================================================
4
+
5
+ // Layouts - base
6
+ //----------------------------------------------------------------------
7
+
8
+ #container,
9
+ #appbar,
10
+ #left-sidebar,
11
+ #right-sidebar,
12
+ #main {
13
+ bottom: 0;
14
+ left: 0;
15
+ position: absolute;
16
+ right: 0;
17
+ top: 0;
18
+ @include transition(transform .35s cubic-bezier(0.24, 1, 0.32, 1), visibility 0s);
19
+ }
20
+
21
+ // Layouts - container
22
+ //----------------------------------------------------------------------
23
+
24
+ #container {
25
+ min-width: $application-container-min-width;
26
+ width: 100%;
27
+ }
@@ -0,0 +1,26 @@
1
+ // Main - base
2
+ //----------------------------------------------------------------------
3
+
4
+ #main {
5
+ left: 0;
6
+ overflow-y: auto;
7
+ padding: 0;
8
+ top: $main-top;
9
+ z-index: $layout-depth;
10
+ }
11
+
12
+ // On large (desktop) size, add padding to main area.
13
+ @media (min-width: $large-width) {
14
+ #main {
15
+ left: $main-left;
16
+ padding: $spacing-normal;
17
+ }
18
+
19
+ // If you have a right sidebar to show on large, you have to
20
+ // make #main leave a gap for the right sidebar.
21
+ body.has-right-sidebar {
22
+ #main {
23
+ right: $main-left;
24
+ }
25
+ }
26
+ }
@@ -0,0 +1,85 @@
1
+ //======================================================================
2
+ // EXAMPLE:
3
+ // <div class="sidebar" id="left-sidebar">
4
+ // <div class="sidebar-header">Header</div>
5
+ // Content for sidebar...
6
+ // <nav id="navigation">
7
+ // ...list component for navigation...
8
+ // </nav>
9
+ // </div>
10
+ //======================================================================
11
+
12
+ // Sidebars - base
13
+ //----------------------------------------------------------------------
14
+
15
+ .sidebar {
16
+ background: color("white");
17
+ max-width: 98%;
18
+ overflow-y: auto;
19
+ top: 0;
20
+ width: $sidebar-width;
21
+ will-change: transform;
22
+ z-index: $sidebar-depth;
23
+ }
24
+
25
+ // Sidebars - header
26
+ //----------------------------------------------------------------------
27
+
28
+ .sidebar-header {
29
+ border-bottom: 1px solid color("divider");
30
+ color: color("hint");
31
+ font-size: $font-size-large;
32
+ height: $appbar-height;
33
+ line-height: $appbar-height;
34
+ margin-bottom: $spacing-normal;
35
+ padding: 0 $spacing-normal;
36
+ }
37
+
38
+ // Sidebars - left sidebar
39
+ //----------------------------------------------------------------------
40
+
41
+ #left-sidebar {
42
+ border: none;
43
+ @include transform(translateX(-100%));
44
+ @include box-shadow(1px 0 5px rgba(0, 0, 0, 0.2));
45
+
46
+ &.visible {
47
+ @include transform(translateX(0));
48
+ }
49
+ }
50
+
51
+ // Sidebars - right sidebar
52
+ //----------------------------------------------------------------------
53
+
54
+ #right-sidebar {
55
+ border: none;
56
+ left: auto;
57
+ right: 0;
58
+ @include transform(translateX(100%));
59
+ @include box-shadow(1px 0 5px rgba(0, 0, 0, 0.2));
60
+
61
+ &.visible {
62
+ @include transform(translateX(0));
63
+ }
64
+ }
65
+
66
+ // Sidebars - media queries
67
+ //----------------------------------------------------------------------
68
+
69
+ @media (min-width: $large-width) {
70
+ #left-sidebar {
71
+ border-right: 1px solid color("divider");
72
+ z-index: $layout-depth;
73
+ @include transform(translateX(0));
74
+ @include box-shadow(none);
75
+ }
76
+
77
+ #right-sidebar {
78
+ border-left: 1px solid color("divider");
79
+ left: auto;
80
+ right: 0;
81
+ z-index: $layout-depth;
82
+ @include transform(translateX(0));
83
+ @include box-shadow(none);
84
+ }
85
+ }
@@ -0,0 +1,53 @@
1
+ // Authentication - container
2
+ //----------------------------------------------------------------------
3
+
4
+ #authentication-container {
5
+ padding: $spacing-normal;
6
+
7
+ .authentication-flash {
8
+ @extend .box;
9
+ margin-bottom: $spacing-normal;
10
+ }
11
+
12
+ .authentication-flash-notice {
13
+ @extend .box-green;
14
+ }
15
+
16
+ .authentication-flash-error {
17
+ @extend .box-red;
18
+ }
19
+ }
20
+
21
+ @media (min-width: $medium-width) {
22
+ #authentication-container {
23
+ padding-top: $spacing-xlarge * 3;
24
+ }
25
+ }
26
+
27
+ // Authentication - branding
28
+ //----------------------------------------------------------------------
29
+
30
+ #authentication-branding {
31
+ font-size: $font-size-large;
32
+ font-weight: bold;
33
+ margin-bottom: $spacing-normal;
34
+ text-align: center;
35
+ }
36
+
37
+ // Authentication - footer links
38
+ //----------------------------------------------------------------------
39
+
40
+ #authentication-footer {
41
+ padding: $spacing-large;
42
+ text-align: center;
43
+
44
+ a {
45
+ color: color("grey");
46
+ margin: $spacing-xsmall;
47
+ text-decoration: none;
48
+
49
+ &:hover {
50
+ text-decoration: underline;
51
+ }
52
+ }
53
+ }
metadata ADDED
@@ -0,0 +1,155 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: dlegr250_material_design
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Daniel LeGrand
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2016-02-16 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.10'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.10'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '10.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '10.0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ description: Implement Google Material Design spec with modern browsers in mind.
56
+ email:
57
+ - dan.legrand@gmail.com
58
+ executables: []
59
+ extensions: []
60
+ extra_rdoc_files: []
61
+ files:
62
+ - ".gitignore"
63
+ - ".rspec"
64
+ - ".travis.yml"
65
+ - Gemfile
66
+ - README.md
67
+ - Rakefile
68
+ - app/controllers/styleguide_controller.rb
69
+ - app/views/styleguide/_buttons.html.erb
70
+ - app/views/styleguide/_menus.html.erb
71
+ - app/views/styleguide/_navigation.html.erb
72
+ - app/views/styleguide/index.html.erb
73
+ - bin/console
74
+ - bin/setup
75
+ - dlegr250_material_design.gemspec
76
+ - lib/dlegr250_material_design.rb
77
+ - lib/dlegr250_material_design/version.rb
78
+ - vendor/assets/javascripts/base/init.js.coffee
79
+ - vendor/assets/javascripts/components/dialog.coffee
80
+ - vendor/assets/javascripts/components/forms.coffee
81
+ - vendor/assets/javascripts/components/layout.coffee
82
+ - vendor/assets/javascripts/components/menus.coffee
83
+ - vendor/assets/javascripts/components/snackbar_handler.coffee
84
+ - vendor/assets/javascripts/components/tabs.coffee
85
+ - vendor/assets/javascripts/components/utility.coffee
86
+ - vendor/assets/javascripts/dlegr250_material_design.js
87
+ - vendor/assets/javascripts/extensions/coffeescript.js.coffee
88
+ - vendor/assets/javascripts/extensions/jquery.js.coffee
89
+ - vendor/assets/javascripts/third_party/hammer.min.js
90
+ - vendor/assets/javascripts/third_party/handlebars.latest.js
91
+ - vendor/assets/javascripts/third_party/jquery.hammer.js
92
+ - vendor/assets/javascripts/third_party/snackbarlight.js
93
+ - vendor/assets/stylesheets/base/base.scss
94
+ - vendor/assets/stylesheets/base/global_classes.scss
95
+ - vendor/assets/stylesheets/base/mixins.scss
96
+ - vendor/assets/stylesheets/base/normalize.scss
97
+ - vendor/assets/stylesheets/base/variables.scss
98
+ - vendor/assets/stylesheets/components/badges.scss
99
+ - vendor/assets/stylesheets/components/blank_slates.scss
100
+ - vendor/assets/stylesheets/components/boxes.scss
101
+ - vendor/assets/stylesheets/components/buttons.scss
102
+ - vendor/assets/stylesheets/components/cards.scss
103
+ - vendor/assets/stylesheets/components/code.scss
104
+ - vendor/assets/stylesheets/components/dialogs.scss
105
+ - vendor/assets/stylesheets/components/dividers.scss
106
+ - vendor/assets/stylesheets/components/forms/error_messages.scss
107
+ - vendor/assets/stylesheets/components/forms/fields.scss
108
+ - vendor/assets/stylesheets/components/forms/labels.scss
109
+ - vendor/assets/stylesheets/components/forms/radios.scss
110
+ - vendor/assets/stylesheets/components/forms/selects.scss
111
+ - vendor/assets/stylesheets/components/forms/text_fields.scss
112
+ - vendor/assets/stylesheets/components/forms/toggles.scss
113
+ - vendor/assets/stylesheets/components/lists.scss
114
+ - vendor/assets/stylesheets/components/menus.scss
115
+ - vendor/assets/stylesheets/components/overlay.scss
116
+ - vendor/assets/stylesheets/components/snackbarlight.scss
117
+ - vendor/assets/stylesheets/components/spinners.scss
118
+ - vendor/assets/stylesheets/components/tabs.scss
119
+ - vendor/assets/stylesheets/components/tooltips.scss
120
+ - vendor/assets/stylesheets/dlegr250_material_design.scss
121
+ - vendor/assets/stylesheets/fonts/material_design_iconic_font.scss
122
+ - vendor/assets/stylesheets/fonts/material_design_iconic_font/Material-Design-Iconic-Font.eot
123
+ - vendor/assets/stylesheets/fonts/material_design_iconic_font/Material-Design-Iconic-Font.svg
124
+ - vendor/assets/stylesheets/fonts/material_design_iconic_font/Material-Design-Iconic-Font.ttf
125
+ - vendor/assets/stylesheets/fonts/material_design_iconic_font/Material-Design-Iconic-Font.woff
126
+ - vendor/assets/stylesheets/fonts/material_design_iconic_font/Material-Design-Iconic-Font.woff2
127
+ - vendor/assets/stylesheets/layouts/application/appbar.scss
128
+ - vendor/assets/stylesheets/layouts/application/base.scss
129
+ - vendor/assets/stylesheets/layouts/application/main.scss
130
+ - vendor/assets/stylesheets/layouts/application/sidebars.scss
131
+ - vendor/assets/stylesheets/layouts/authentication/base.scss
132
+ homepage: http://www.github.com/dlegr250/dlegr250_material_design
133
+ licenses: []
134
+ metadata: {}
135
+ post_install_message:
136
+ rdoc_options: []
137
+ require_paths:
138
+ - lib
139
+ required_ruby_version: !ruby/object:Gem::Requirement
140
+ requirements:
141
+ - - ">="
142
+ - !ruby/object:Gem::Version
143
+ version: '0'
144
+ required_rubygems_version: !ruby/object:Gem::Requirement
145
+ requirements:
146
+ - - ">="
147
+ - !ruby/object:Gem::Version
148
+ version: '0'
149
+ requirements: []
150
+ rubyforge_project:
151
+ rubygems_version: 2.4.5.1
152
+ signing_key:
153
+ specification_version: 4
154
+ summary: Customized implementation of Google Material Design User Interface.
155
+ test_files: []