oulu 0.8.2

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.
Files changed (99) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +4 -0
  3. data/LICENSE.txt +22 -0
  4. data/README.md +15 -0
  5. data/Rakefile +1 -0
  6. data/app/assets/stylesheets/_oulu-base.sass +64 -0
  7. data/app/assets/stylesheets/_oulu.sass +9 -0
  8. data/app/assets/stylesheets/helpers/_block.sass +89 -0
  9. data/app/assets/stylesheets/helpers/_border.sass +16 -0
  10. data/app/assets/stylesheets/helpers/_font-awsome.sass +11 -0
  11. data/app/assets/stylesheets/helpers/_margin-padding.sass +110 -0
  12. data/app/assets/stylesheets/helpers/_position.sass +9 -0
  13. data/app/assets/stylesheets/helpers/_typoglaphy.sass +26 -0
  14. data/app/assets/stylesheets/modules/buttons/_button-base.sass +61 -0
  15. data/app/assets/stylesheets/modules/buttons/_button-helper.sass +33 -0
  16. data/app/assets/stylesheets/modules/buttons/_buttons.sass +59 -0
  17. data/app/assets/stylesheets/modules/buttons/styles/_border.sass +24 -0
  18. data/app/assets/stylesheets/modules/buttons/styles/_flat-emboss.sass +24 -0
  19. data/app/assets/stylesheets/modules/buttons/styles/_flat-round.sass +23 -0
  20. data/app/assets/stylesheets/modules/buttons/styles/_material.sass +89 -0
  21. data/app/assets/stylesheets/modules/buttons/styles/_normal.sass +42 -0
  22. data/app/assets/stylesheets/modules/navs/_tabs-nav.sass +38 -0
  23. data/app/assets/stylesheets/options/amazlet/_amazlet.sass +32 -0
  24. data/app/assets/stylesheets/options/glitch/_glitch.sass +31 -0
  25. data/app/assets/stylesheets/options/web-fonts/_cousine.sass +12 -0
  26. data/app/assets/stylesheets/options/web-fonts/_droid-sans.sass +11 -0
  27. data/app/assets/stylesheets/options/web-fonts/_font-awsome.sass +17 -0
  28. data/app/assets/stylesheets/options/web-fonts/_icomoon.sass +10 -0
  29. data/app/assets/stylesheets/options/web-fonts/_inconsolata.sass +11 -0
  30. data/app/assets/stylesheets/options/web-fonts/_lato.sass +11 -0
  31. data/app/assets/stylesheets/options/web-fonts/_merriweather-sans.sass +11 -0
  32. data/app/assets/stylesheets/options/web-fonts/_montserrat.sass +12 -0
  33. data/app/assets/stylesheets/options/web-fonts/_old-standard.sass +11 -0
  34. data/app/assets/stylesheets/options/web-fonts/_open-sans.sass +11 -0
  35. data/app/assets/stylesheets/options/web-fonts/_podkova.sass +11 -0
  36. data/app/assets/stylesheets/options/web-fonts/_pt-sans.sass +11 -0
  37. data/app/assets/stylesheets/options/web-fonts/_raleway.sass +11 -0
  38. data/app/assets/stylesheets/options/web-fonts/_roboto-condensed.sass +12 -0
  39. data/app/assets/stylesheets/options/web-fonts/_roboto.sass +11 -0
  40. data/app/assets/stylesheets/options/web-fonts/_satisfy.sass +12 -0
  41. data/app/assets/stylesheets/options/web-fonts/_source-code-pro.sass +12 -0
  42. data/app/assets/stylesheets/options/web-fonts/_source-sans-pro.sass +12 -0
  43. data/app/assets/stylesheets/options/web-fonts/_special-elite.sass +11 -0
  44. data/app/assets/stylesheets/options/web-fonts/_tauri.sass +11 -0
  45. data/app/assets/stylesheets/options/web-fonts/_ubuntu-mono.sass +11 -0
  46. data/app/assets/stylesheets/options/web-fonts/_ubuntu.sass +11 -0
  47. data/app/assets/stylesheets/options/web-fonts/_varela-round.sass +12 -0
  48. data/app/assets/stylesheets/options/web-fonts/_vt323.sass +11 -0
  49. data/app/assets/stylesheets/settings/functions/_animation.sass +90 -0
  50. data/app/assets/stylesheets/settings/functions/_background.sass +54 -0
  51. data/app/assets/stylesheets/settings/functions/_bool.sass +5 -0
  52. data/app/assets/stylesheets/settings/functions/_border.sass +45 -0
  53. data/app/assets/stylesheets/settings/functions/_color.sass +79 -0
  54. data/app/assets/stylesheets/settings/functions/_content.sass +5 -0
  55. data/app/assets/stylesheets/settings/functions/_cursor.sass +5 -0
  56. data/app/assets/stylesheets/settings/functions/_display.sass +5 -0
  57. data/app/assets/stylesheets/settings/functions/_image.sass +8 -0
  58. data/app/assets/stylesheets/settings/functions/_length.sass +20 -0
  59. data/app/assets/stylesheets/settings/functions/_list.sass +11 -0
  60. data/app/assets/stylesheets/settings/functions/_map.sass +5 -0
  61. data/app/assets/stylesheets/settings/functions/_math.sass +31 -0
  62. data/app/assets/stylesheets/settings/functions/_number.sass +95 -0
  63. data/app/assets/stylesheets/settings/functions/_position.sass +80 -0
  64. data/app/assets/stylesheets/settings/functions/_reverse.sass +22 -0
  65. data/app/assets/stylesheets/settings/functions/_string.sass +5 -0
  66. data/app/assets/stylesheets/settings/functions/_text.sass +46 -0
  67. data/app/assets/stylesheets/settings/initializers/_reset.sass +84 -0
  68. data/app/assets/stylesheets/settings/initializers/_sanitize.sass +262 -0
  69. data/app/assets/stylesheets/settings/mixins/_animation.sass +28 -0
  70. data/app/assets/stylesheets/settings/mixins/_background.sass +33 -0
  71. data/app/assets/stylesheets/settings/mixins/_balloon-tail.sass +100 -0
  72. data/app/assets/stylesheets/settings/mixins/_basic-font.sass +30 -0
  73. data/app/assets/stylesheets/settings/mixins/_block.sass +61 -0
  74. data/app/assets/stylesheets/settings/mixins/_border-radius.sass +43 -0
  75. data/app/assets/stylesheets/settings/mixins/_border.sass +28 -0
  76. data/app/assets/stylesheets/settings/mixins/_filters.sass +5 -0
  77. data/app/assets/stylesheets/settings/mixins/_form.sass +10 -0
  78. data/app/assets/stylesheets/settings/mixins/_grid.sass +93 -0
  79. data/app/assets/stylesheets/settings/mixins/_ie-hacks.sass +8 -0
  80. data/app/assets/stylesheets/settings/mixins/_image.sass +5 -0
  81. data/app/assets/stylesheets/settings/mixins/_line.sass +32 -0
  82. data/app/assets/stylesheets/settings/mixins/_link.sass +39 -0
  83. data/app/assets/stylesheets/settings/mixins/_list.sass +20 -0
  84. data/app/assets/stylesheets/settings/mixins/_margin-padding.sass +69 -0
  85. data/app/assets/stylesheets/settings/mixins/_overlay.sass +5 -0
  86. data/app/assets/stylesheets/settings/mixins/_positions.sass +33 -0
  87. data/app/assets/stylesheets/settings/mixins/_rem.sass +56 -0
  88. data/app/assets/stylesheets/settings/mixins/_resets.sass +49 -0
  89. data/app/assets/stylesheets/settings/mixins/_responsive-utilities.sass +196 -0
  90. data/app/assets/stylesheets/settings/mixins/_table.sass +32 -0
  91. data/app/assets/stylesheets/settings/mixins/_text.sass +44 -0
  92. data/app/assets/stylesheets/settings/mixins/grid/_grid-framework.scss +81 -0
  93. data/app/assets/stylesheets/settings/mixins/grid/_grid.scss +122 -0
  94. data/app/assets/stylesheets/settings/variables/_default.sass +150 -0
  95. data/bower.json +34 -0
  96. data/index.js +7 -0
  97. data/oulu.gemspec +26 -0
  98. data/package.json +20 -0
  99. metadata +197 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: f8191edb3411886853b354607f9490bff19beb2e
4
+ data.tar.gz: ce22256b6e8d4aa0ecc68b4cef0363aea065b69d
5
+ SHA512:
6
+ metadata.gz: 66ac48438ddf60beda788868ed15e74068f2ffbe6c26191e34f95861aab652f387187138e232692505284c0d484c9f38498b703789c91c0d89bf4ad5af47a95d
7
+ data.tar.gz: dba3350c9549b91ee25389228c0aed6c617b7155c10bc89745e54528a9572eeed4faefecbbbc81863932f841909ebc0791fea25aa6bb6875531ac073ad6b9185
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in middleman-assets.gemspec
4
+ gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2013 machida
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,15 @@
1
+ # oulu
2
+
3
+ oulu is a sass mixin libraly.
4
+
5
+ ## Usage
6
+
7
+ [docs](http://oulu.github.io/)
8
+
9
+ ## Contributing
10
+
11
+ 1. Fork it
12
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
13
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
14
+ 4. Push to the branch (`git push origin my-new-feature`)
15
+ 5. Create new Pull Request
data/Rakefile ADDED
@@ -0,0 +1 @@
1
+ require "bundler/gem_tasks"
@@ -0,0 +1,64 @@
1
+ //////////////
2
+ //settings
3
+ //////////////
4
+
5
+ // bourbon
6
+ ///////////////////
7
+
8
+ @import bourbon
9
+
10
+ // variables
11
+ ///////////////////
12
+
13
+ @import settings/variables/default
14
+
15
+ // functions
16
+ ///////////////////
17
+ @import settings/functions/math
18
+ @import settings/functions/list
19
+ @import settings/functions/number
20
+ @import settings/functions/string
21
+ @import settings/functions/length
22
+ @import settings/functions/map
23
+ @import settings/functions/bool
24
+ @import settings/functions/position
25
+ @import settings/functions/text
26
+ @import settings/functions/reverse
27
+ @import settings/functions/color
28
+ @import settings/functions/image
29
+ @import settings/functions/background
30
+ @import settings/functions/border
31
+ @import settings/functions/animation
32
+ @import settings/functions/display
33
+
34
+ // mixins
35
+ ///////////////////
36
+
37
+ @import settings/mixins/rem
38
+ @import settings/mixins/basic-font
39
+ @import settings/mixins/resets
40
+ @import settings/mixins/text
41
+ @import settings/mixins/positions
42
+ @import settings/mixins/block
43
+ @import settings/mixins/link
44
+ @import settings/mixins/border
45
+ @import settings/mixins/border-radius
46
+ @import settings/mixins/table
47
+ @import settings/mixins/list
48
+ @import settings/mixins/overlay
49
+ @import settings/mixins/balloon-tail
50
+ @import settings/mixins/margin-padding
51
+ @import settings/mixins/animation
52
+ @import settings/mixins/grid/grid-framework
53
+ @import settings/mixins/grid/grid
54
+ @import settings/mixins/grid
55
+ @import settings/mixins/responsive-utilities
56
+ @import settings/mixins/background
57
+ @import settings/mixins/line
58
+ @import settings/mixins/image
59
+
60
+ // initializers
61
+ ///////////////////
62
+
63
+ @import settings/initializers/sanitize
64
+ @import settings/initializers/reset
@@ -0,0 +1,9 @@
1
+ //////////////
2
+ //settings
3
+ //////////////
4
+
5
+ // oulu-base
6
+ @import oulu-base
7
+
8
+ // helper-classes
9
+ @import helpers/**/*
@@ -0,0 +1,89 @@
1
+ body
2
+ // layout
3
+ .has-no-gutter-grids
4
+ +grid(0)
5
+ .is-horizontal-center-block
6
+ display: block
7
+ +margin(horizontal, auto)
8
+
9
+ // clearfix
10
+ .is-clear
11
+ clear: both
12
+ .is-clearfix
13
+ +clearfix
14
+
15
+ // width
16
+ .is-max-width-100
17
+ width: 100%
18
+ display: block
19
+ .is-half
20
+ width: 50%
21
+
22
+ // float
23
+ .is-left
24
+ float: left
25
+ .is-right
26
+ float: right
27
+
28
+ // float
29
+ .is-float-left
30
+ float: left
31
+ .is-float-right
32
+ float: right
33
+
34
+ // block link
35
+ .is-block-link
36
+ display: block
37
+ text-decoration: none
38
+ .is-inline-block-link
39
+ display: inline-block
40
+ text-decoration: none
41
+ .is-clickable
42
+ cursor: pointer
43
+
44
+ // overflow
45
+ .is-scroll-x-wrapper
46
+ +overflow(auto hidden)
47
+ -webkit-overflow-scrolling: touch
48
+ width: 100%
49
+ position: relative
50
+ .is-overflow-visible
51
+ overflow: visible !important
52
+ .is-overflow-hidden
53
+ overflow: hidden
54
+
55
+ // position
56
+ .is-relative
57
+ position: relative
58
+ .is-fixed-default
59
+ +fixed(left 0, top 0)
60
+ width: 100%
61
+ .is-z-index-100
62
+ +position(relative, 100)
63
+
64
+ // vertical-align
65
+ .is-vertical-middle
66
+ vertical-align: middle !important
67
+ .is-vertical-top
68
+ vertical-align: top !important
69
+ .is-vertical-bottom
70
+ vertical-align: bottom !important
71
+
72
+ // display
73
+ .is-block
74
+ display: block
75
+ .is-display-none
76
+ display: none
77
+ .is-display-none-important
78
+ display: none !important
79
+ .is-inline-block
80
+ display: inline-block
81
+ .is-inline
82
+ display: inline
83
+ .is-table-row
84
+ display: table-row !important
85
+ .is-table-cell
86
+ display: table-cell !important
87
+ .is-inline-blocks
88
+ >*
89
+ display: inline-block
@@ -0,0 +1,16 @@
1
+ body
2
+ // border
3
+ .is-border-none
4
+ border: none
5
+ .is-horizontal-border-none
6
+ +border(horizontal, none)
7
+ .is-vertical-border-none
8
+ +border(vertical, none)
9
+ .is-border-left-none
10
+ border-left: none
11
+ .is-border-right-none
12
+ border-right: none
13
+ .is-border-top-none
14
+ border-top: none
15
+ .is-border-bottom-none
16
+ border-bottom: none
@@ -0,0 +1,11 @@
1
+ .fa-hatena
2
+ &:before
3
+ content: "B!"
4
+ font-family: Verdana
5
+ font-weight: bold
6
+ .fa-triangle-o:before
7
+ content: "\0025b3"
8
+ +sans-serif
9
+ .fa-triangle:before
10
+ content: "\0025b2"
11
+ +sans-serif
@@ -0,0 +1,110 @@
1
+ body
2
+ @for $i from 0 through 20
3
+ .is-margin-bottom-#{$i*4}
4
+ +rem('margin-bottom', #{$i*4}px)
5
+ .is-margin-top-#{$i*4}
6
+ +rem('margin-top', #{$i*4}px)
7
+ .is-margin-left-#{$i*4}
8
+ +rem('margin-left', #{$i*4}px)
9
+ .is-margin-right-#{$i*4}
10
+ +rem('margin-right', #{$i*4}px)
11
+ .is-margin-horizontal-#{$i*4}
12
+ +margin(horizontal, #{$i*4}px)
13
+ .is-padding-bottom-#{$i*4}
14
+ +rem('padding-bottom', #{$i*4}px)
15
+ .is-padding-top-#{$i*4}
16
+ +rem('padding-top', #{$i*4}px)
17
+ .is-padding-left-#{$i*4}
18
+ +rem('padding-left', #{$i*4}px)
19
+ .is-padding-right-#{$i*4}
20
+ +rem('padding-right', #{$i*4}px)
21
+ .is-padding-horizontal-#{$i*4}
22
+ +padding(horizontal, #{$i*4}px)
23
+
24
+ // horizontal-margin-0
25
+ .is-horizontal-margin-0
26
+ +margin(horizontal, 0)
27
+ .is-xs-horizontal-margin-0
28
+ +screen-xs
29
+ +margin(horizontal, 0)
30
+ .is-sm-horizontal-margin-0
31
+ +screen-sm
32
+ +margin(horizontal, 0)
33
+ .is-md-horizontal-margin-0
34
+ +screen-md
35
+ +margin(horizontal, 0)
36
+ .is-lg-horizontal-margin-0
37
+ +screen-lg
38
+ +margin(horizontal, 0)
39
+
40
+ // horizontal-padding-0
41
+ .is-horizontal-padding-0
42
+ +padding(horizontal, 0)
43
+ .is-xs-horizontal-padding-0
44
+ +screen-xs
45
+ +padding(horizontal, 0)
46
+ .is-sm-horizontal-padding-0
47
+ +screen-sm
48
+ +padding(horizontal, 0)
49
+ .is-md-horizontal-padding-0
50
+ +screen-md
51
+ +padding(horizontal, 0)
52
+ .is-lg-horizontal-padding-0
53
+ +screen-lg
54
+ +padding(horizontal, 0)
55
+
56
+ // こっちに変更
57
+ body
58
+ @for $i from 0 through 20
59
+ .has-margin-bottom-#{$i*4}
60
+ +rem('margin-bottom', #{$i*4}px)
61
+ .has-margin-top-#{$i*4}
62
+ +rem('margin-top', #{$i*4}px)
63
+ .has-margin-left-#{$i*4}
64
+ +rem('margin-left', #{$i*4}px)
65
+ .has-margin-right-#{$i*4}
66
+ +rem('margin-right', #{$i*4}px)
67
+ .has-margin-horizontal-#{$i*4}
68
+ +margin(horizontal, #{$i*4}px)
69
+ .has-padding-bottom-#{$i*4}
70
+ +rem('padding-bottom', #{$i*4}px)
71
+ .has-padding-top-#{$i*4}
72
+ +rem('padding-top', #{$i*4}px)
73
+ .has-padding-left-#{$i*4}
74
+ +rem('padding-left', #{$i*4}px)
75
+ .has-padding-right-#{$i*4}
76
+ +rem('padding-right', #{$i*4}px)
77
+ .has-padding-horizontal-#{$i*4}
78
+ +padding(horizontal, #{$i*4}px)
79
+
80
+ // horizontal-margin-0
81
+ .has-horizontal-margin-0
82
+ +margin(horizontal, 0)
83
+ .has-xs-horizontal-margin-0
84
+ +screen-xs
85
+ +margin(horizontal, 0)
86
+ .has-sm-horizontal-margin-0
87
+ +screen-sm
88
+ +margin(horizontal, 0)
89
+ .has-md-horizontal-margin-0
90
+ +screen-md
91
+ +margin(horizontal, 0)
92
+ .has-lg-horizontal-margin-0
93
+ +screen-lg
94
+ +margin(horizontal, 0)
95
+
96
+ // horizontal-padding-0
97
+ .has-horizontal-padding-0
98
+ +padding(horizontal, 0)
99
+ .has-xs-horizontal-padding-0
100
+ +screen-xs
101
+ +padding(horizontal, 0)
102
+ .has-sm-horizontal-padding-0
103
+ +screen-sm
104
+ +padding(horizontal, 0)
105
+ .has-md-horizontal-padding-0
106
+ +screen-md
107
+ +padding(horizontal, 0)
108
+ .has-lg-horizontal-padding-0
109
+ +screen-lg
110
+ +padding(horizontal, 0)
@@ -0,0 +1,9 @@
1
+ @for $i from -8 through 8
2
+ .is-top-#{$i}
3
+ +top(#{$i}px)
4
+ .is-bottom-#{$i}
5
+ +top(#{$i}px)
6
+ .is-left-#{$i}
7
+ +left(#{$i}px)
8
+ .is-right-#{$i}
9
+ +right(#{$i}px)
@@ -0,0 +1,26 @@
1
+ body
2
+ // typoglaphy
3
+ .is-ja
4
+ +basic-font
5
+ .is-serif
6
+ +serif
7
+ .is-bold-ja
8
+ +bold-ja
9
+ .is-serif
10
+ +serif
11
+
12
+ @for $i from 0 through 24
13
+ $value: $i/10
14
+ .is-letter-specing-#{$i}px
15
+ letter-spacing: $value
16
+ .is-letter-specing-center-#{$i}px
17
+ letter-spacing: $value
18
+ text-indent: $value
19
+
20
+ .is-white-space-nowrap
21
+ white-space: nowrap
22
+
23
+ $positions: left center right
24
+ @each $position in $positions
25
+ .is-text-align-#{$position}
26
+ text-align: $position
@@ -0,0 +1,61 @@
1
+ =button-base
2
+ +inline-block(middle)
3
+ cursor: pointer
4
+ text-align: center
5
+ +user-select(none)
6
+ touch-action: manipulation
7
+ text-decoration: none
8
+ -webkit-tap-highlight-color: transparent
9
+
10
+ =button-size($size, $border-width: 0, $border-radius: 4px)
11
+ $font-size: ""
12
+ @if $size == 'xs'
13
+ $font-size: 12px
14
+ @else if $size == 'sm'
15
+ $font-size: 14px
16
+ @else if $size == 'md'
17
+ $font-size: 16px
18
+ @else if $size == 'lg'
19
+ $font-size: 18px
20
+ @else if $size == 'xl'
21
+ $font-size: 20px
22
+ $height: round($font-size * 2 + $font-size/2.2)
23
+ @if $border-width
24
+ +border(all, $border-width)
25
+ @else
26
+ $border-width: 0
27
+ +text-block($font-size $height - ($border-width*2))
28
+ +rem('height', $height)
29
+ +padding(horizontal, $height/1.6)
30
+ @if $border-radius
31
+ +border-radius($border-radius)
32
+ @if $font-size > 12px
33
+ font-weight: bold
34
+ i,
35
+ .is-button-icon
36
+ @if $font-size > 28
37
+ +rem('margin-right', $font-size/4)
38
+ @else
39
+ +rem('margin-right', $font-size/3)
40
+ &.has-right-icon
41
+ i,
42
+ .is-button-icon
43
+ margin-right: 0
44
+ @if $font-size > 28
45
+ +rem('margin-left', $font-size/4)
46
+ @else
47
+ +rem('margin-left', $font-size/3)
48
+ &.is-input-container
49
+ padding: 0
50
+ position: relative
51
+ i,
52
+ .is-button-icon
53
+ +position(absolute, left $height/2, top 0)
54
+ +rem('line-height', $height - ($border-width*2))
55
+ input
56
+ +padding(horizontal, ($height + if($font-size > 28, $font-size/4, $font-size/3)) $height/2)
57
+ +rem('height', $height - ($border-width*2))
58
+
59
+ =button-group
60
+ .is-button-group
61
+ @content
@@ -0,0 +1,33 @@
1
+ // button option
2
+ [class^="is-button"]
3
+ &.is-block
4
+ display: block
5
+ width: 100%
6
+ &.has-image
7
+ height: auto
8
+ .is-button-note
9
+ +inline-block
10
+ +rem('font-size', 12px)
11
+ +rem('margin-left', 6px)
12
+ &.is-disabled,
13
+ &:disabled
14
+ pointer-events: none
15
+ cursor: default
16
+ select
17
+ cursor: default
18
+
19
+ // button-group
20
+ .is-button-group
21
+ font-size: 0
22
+ >li
23
+ display: inline
24
+ letter-spacing: normal
25
+ font-size: 0
26
+ [class^="is-button"]
27
+ border-radius: 0
28
+ &:first-child
29
+ [class^="is-button"]
30
+ +border-radius(left, 4px)
31
+ &:last-child
32
+ [class^="is-button"]
33
+ +border-radius(right, 4px)
@@ -0,0 +1,59 @@
1
+ $button-sizes: xs, sm, md, lg, xl !default
2
+ $button-color-names: default, primary, success, warning, danger !default
3
+ $button-styles: normal, border, bold-border, flat-emboss, material, flat-round !default
4
+
5
+ @import button-base
6
+
7
+ // button styles
8
+ @import styles/normal
9
+ @import styles/border
10
+ @import styles/flat-emboss
11
+ @import styles/material
12
+ @import styles/flat-round
13
+
14
+ @import button-helper
15
+
16
+ =button($style, $size, $color, $options: false)
17
+ +button-base
18
+ @if $style == normal
19
+ +button-size($size, 1px, 4px)
20
+ +normal-button($color)
21
+ @else if $style == border
22
+ +button-size($size, 1px, 4px)
23
+ +border-button($color)
24
+ @else if $style == bold-border
25
+ +button-size($size, 2px, 8px)
26
+ +border-button($color)
27
+ @else if $style == flat-emboss
28
+ +button-size($size, false, 4px)
29
+ +flat-emboss-button($color)
30
+ @else if $style == material
31
+ +button-size($size, false, false)
32
+ +material-button($color)
33
+ @else if $style == flat-round
34
+ +button-size($size, false, false)
35
+ +flat-round-button($color)
36
+ @each $option in $options
37
+ @if $option == 'left'
38
+ text-align: left
39
+ @if $option == 'right'
40
+ text-align: right
41
+
42
+ @each $button-size in $button-sizes
43
+ $button-color-name: ''
44
+ $button-color: ''
45
+ $button-style: ''
46
+ @each $button-color-name in $button-color-names
47
+ @each $button-style in $button-styles
48
+ .is-button-#{$button-style}-#{$button-size}-#{$button-color-name}
49
+ @if $button-color-name == default
50
+ $button-color: $default
51
+ @else if $button-color-name == primary
52
+ $button-color: $primary
53
+ @else if $button-color-name == success
54
+ $button-color: $success
55
+ @else if $button-color-name == warning
56
+ $button-color: $warning
57
+ @else if $button-color-name == danger
58
+ $button-color: $danger
59
+ +button($button-style, $button-size, $button-color)
@@ -0,0 +1,24 @@
1
+ =border-button($color)
2
+ +border(all, solid)
3
+ @if $color == $default
4
+ $color: $text-color
5
+ @else
6
+ color: $color
7
+ border-color: $color
8
+ background-color: transparent
9
+ &:link,
10
+ &:visited
11
+ color: $color
12
+ &:hover,
13
+ &.hover,
14
+ &.is-hover
15
+ color: $color
16
+ background-color: rgba($color, .1)
17
+ &:active,
18
+ &.active,
19
+ &.is-active
20
+ color: $color
21
+ background-color: rgba($color, .3)
22
+ &.is-checked
23
+ color: $default-text-reversal
24
+ background-color: $color
@@ -0,0 +1,24 @@
1
+ =flat-emboss-button($color: blue)
2
+ +transition(.5s (background-image))
3
+ background-color: $color
4
+ color: luma_contrast_color($color)
5
+ box-shadow: shade($color, 18%) 0 3px 0
6
+ text-shadow: if(luma_bright($color), lighten($color, 8%) 0 1px 0, darken($color, 8%) 0 -1px 0)
7
+ &:hover,
8
+ &.hover,
9
+ &.is-hover
10
+ $color: lighten($color, 6%)
11
+ @if luma($color) > 90
12
+ background-color: #f2f2f2
13
+ @else
14
+ background-color: $color
15
+ &:active,
16
+ &.active,
17
+ &.is-active
18
+ $color: lighten($color, 6%)
19
+ @if luma($color) > 90
20
+ background-color: #f2f2f2
21
+ @else
22
+ background-color: $color
23
+ box-shadow: shade($color, 18%) 0 2px 0
24
+ +top(1px)
@@ -0,0 +1,23 @@
1
+ =flat-round-button($color: blue)
2
+ +transition(.5s (background-image))
3
+ background-color: $color
4
+ color: luma_contrast_color($color)
5
+ font-weight: bold
6
+ border-radius: 1000px
7
+ &:hover,
8
+ &.hover,
9
+ &.is-hover
10
+ $color: lighten($color, 6%)
11
+ @if luma($color) > 90
12
+ background-color: #f2f2f2
13
+ @else
14
+ background-color: $color
15
+ &:active,
16
+ &.active,
17
+ &.is-active
18
+ $color: lighten($color, 6%)
19
+ @if luma($color) > 90
20
+ background-color: #f2f2f2
21
+ @else
22
+ background-color: $color
23
+ +top(1px)