oulu 0.19.1 → 1.0.0.beta1

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 (114) hide show
  1. checksums.yaml +5 -5
  2. data/README.md +0 -30
  3. data/app/assets/stylesheets/_oulu-base.sass +1 -3
  4. data/app/assets/stylesheets/_oulu.sass +9 -24
  5. data/app/assets/stylesheets/helpers/_block.sass +33 -9
  6. data/app/assets/stylesheets/helpers/_margin-padding.sass +108 -33
  7. data/app/assets/stylesheets/helpers/_position.sass +8 -32
  8. data/app/assets/stylesheets/helpers/_typoglaphy.sass +9 -25
  9. data/app/assets/stylesheets/modules/buttons/_button-base.sass +35 -89
  10. data/app/assets/stylesheets/modules/buttons/_button-helper.sass +12 -39
  11. data/app/assets/stylesheets/modules/buttons/_buttons.sass +6 -22
  12. data/app/assets/stylesheets/modules/buttons/styles/_border.sass +8 -6
  13. data/app/assets/stylesheets/modules/buttons/styles/_flat-emboss.sass +10 -8
  14. data/app/assets/stylesheets/modules/buttons/styles/_flat-round.sass +7 -5
  15. data/app/assets/stylesheets/modules/buttons/styles/_material.sass +4 -2
  16. data/app/assets/stylesheets/modules/buttons/styles/_normal.sass +13 -10
  17. data/app/assets/stylesheets/modules/buttons/styles/_super-bold-border.sass +29 -19
  18. data/app/assets/stylesheets/modules/glitch/_glitch.sass +2 -3
  19. data/app/assets/stylesheets/modules/glitch/_glitch.sass~organize-modules +31 -0
  20. data/app/assets/stylesheets/modules/web-fonts/_font-awsome.sass +17 -0
  21. data/app/assets/stylesheets/modules/web-fonts/_icomoon.sass +2 -0
  22. data/app/assets/stylesheets/settings/functions/_animation.sass +90 -0
  23. data/app/assets/stylesheets/settings/functions/_background.sass +16 -31
  24. data/app/assets/stylesheets/settings/functions/_color.sass +29 -15
  25. data/app/assets/stylesheets/settings/functions/_display.sass +1 -1
  26. data/app/assets/stylesheets/settings/functions/_length.sass +0 -7
  27. data/app/assets/stylesheets/settings/functions/_map.sass +0 -52
  28. data/app/assets/stylesheets/settings/functions/_math.sass +0 -12
  29. data/app/assets/stylesheets/settings/functions/_number.sass +2 -18
  30. data/app/assets/stylesheets/settings/functions/_string.sass +0 -19
  31. data/app/assets/stylesheets/settings/initializers/_reboot.sass +2 -24
  32. data/app/assets/stylesheets/settings/initializers/_sanitize.sass +102 -75
  33. data/app/assets/stylesheets/settings/mixins/_animation.sass +32 -0
  34. data/app/assets/stylesheets/settings/mixins/_background.sass +2 -2
  35. data/app/assets/stylesheets/settings/mixins/_balloon-tail.sass +89 -281
  36. data/app/assets/stylesheets/settings/mixins/_basic-font.sass +1 -1
  37. data/app/assets/stylesheets/settings/mixins/_block.sass +1 -29
  38. data/app/assets/stylesheets/settings/mixins/_form.sass +18 -0
  39. data/app/assets/stylesheets/settings/mixins/_grid.sass +44 -151
  40. data/app/assets/stylesheets/settings/mixins/_ie-hacks.sass +1 -7
  41. data/app/assets/stylesheets/settings/mixins/_link.sass +1 -10
  42. data/app/assets/stylesheets/settings/mixins/_list.sass +20 -0
  43. data/app/assets/stylesheets/settings/mixins/_margin-padding.sass +1 -1
  44. data/app/assets/stylesheets/settings/mixins/_rem.sass +3 -1
  45. data/app/assets/stylesheets/settings/mixins/_responsive-utilities.sass +151 -62
  46. data/app/assets/stylesheets/settings/mixins/_text.sass +27 -29
  47. data/app/assets/stylesheets/settings/mixins/grid/_grid-framework.scss +81 -0
  48. data/app/assets/stylesheets/settings/mixins/grid/_grid.scss +122 -0
  49. data/app/assets/stylesheets/settings/variables/_default.sass +115 -29
  50. data/app/assets/stylesheets/settings/variables/_modules.sass +24 -37
  51. data/bower.json +1 -1
  52. data/lib/oulu/version.rb +1 -1
  53. data/lib/oulu.rb +5 -9
  54. data/oulu.gemspec +3 -3
  55. data/package.json +1 -1
  56. metadata +20 -69
  57. data/app/assets/stylesheets/_oulu-functions-after-variables.sass +0 -6
  58. data/app/assets/stylesheets/_oulu-functions-before-variables.sass +0 -20
  59. data/app/assets/stylesheets/_oulu-functions.sass +0 -21
  60. data/app/assets/stylesheets/_oulu-helpers.sass +0 -10
  61. data/app/assets/stylesheets/_oulu-initializers.sass +0 -6
  62. data/app/assets/stylesheets/_oulu-mixins.sass +0 -28
  63. data/app/assets/stylesheets/_oulu-variables.sass +0 -7
  64. data/app/assets/stylesheets/helpers/_margin.sass +0 -36
  65. data/app/assets/stylesheets/helpers/_padding.sass +0 -35
  66. data/app/assets/stylesheets/helpers/_visibility.sass +0 -67
  67. data/app/assets/stylesheets/modules/buttons/_button-sizes.sass +0 -156
  68. data/app/assets/stylesheets/modules/buttons/styles/_flat.sass +0 -61
  69. data/app/assets/stylesheets/modules/buttons/styles/_simple.sass +0 -51
  70. data/app/assets/stylesheets/modules/buttons/styles/_standard.sass +0 -63
  71. data/app/assets/stylesheets/modules/text-style/_amazlet.sass +0 -38
  72. data/app/assets/stylesheets/modules/text-style/_disabled-h1.sass +0 -23
  73. data/app/assets/stylesheets/modules/text-style/_link-card.sass +0 -67
  74. data/app/assets/stylesheets/modules/text-style/_list.sass +0 -16
  75. data/app/assets/stylesheets/modules/text-style/_long-text-style.sass +0 -207
  76. data/app/assets/stylesheets/modules/text-style/_twitter-tweet.sass +0 -9
  77. data/app/assets/stylesheets/modules/themes/admin/_admin.sass +0 -59
  78. data/app/assets/stylesheets/modules/themes/admin/_base.sass +0 -34
  79. data/app/assets/stylesheets/modules/themes/admin/blocks/admin/_admin-page-header.sass +0 -9
  80. data/app/assets/stylesheets/modules/themes/admin/blocks/form/_admin-actions.sass +0 -36
  81. data/app/assets/stylesheets/modules/themes/admin/blocks/form/_admin-flash.sass +0 -58
  82. data/app/assets/stylesheets/modules/themes/admin/blocks/form/_admin-form-file.sass +0 -33
  83. data/app/assets/stylesheets/modules/themes/admin/blocks/form/_admin-form-inputs.sass +0 -13
  84. data/app/assets/stylesheets/modules/themes/admin/blocks/form/_admin-form-radio.sass +0 -82
  85. data/app/assets/stylesheets/modules/themes/admin/blocks/form/_admin-form.sass +0 -117
  86. data/app/assets/stylesheets/modules/themes/admin/blocks/header/_admin-header-nav.sass +0 -22
  87. data/app/assets/stylesheets/modules/themes/admin/blocks/header/_admin-header-show-mobile-nav.sass +0 -8
  88. data/app/assets/stylesheets/modules/themes/admin/blocks/header/_admin-header.sass +0 -19
  89. data/app/assets/stylesheets/modules/themes/admin/blocks/navs/_admin-breadcrumbs.sass +0 -45
  90. data/app/assets/stylesheets/modules/themes/admin/blocks/navs/_admin-stack-nav.sass +0 -51
  91. data/app/assets/stylesheets/modules/themes/admin/blocks/navs/_admin-tabs-nav.sass +0 -49
  92. data/app/assets/stylesheets/modules/themes/admin/blocks/navs/_pagination.sass +0 -63
  93. data/app/assets/stylesheets/modules/themes/admin/blocks/table/_admin-table-form.sass +0 -10
  94. data/app/assets/stylesheets/modules/themes/admin/blocks/table/_admin-table-sort.sass +0 -21
  95. data/app/assets/stylesheets/modules/themes/admin/blocks/table/_admin-table.sass +0 -82
  96. data/app/assets/stylesheets/modules/themes/admin/settings/_admin-colors.sass +0 -101
  97. data/app/assets/stylesheets/modules/themes/style-guide/_base.sass +0 -5
  98. data/app/assets/stylesheets/modules/themes/style-guide/_style-guide.sass +0 -43
  99. data/app/assets/stylesheets/modules/themes/style-guide/blocks/_style-guide-color.sass +0 -42
  100. data/app/assets/stylesheets/modules/themes/style-guide/blocks/_style-guide-global-nav.sass +0 -32
  101. data/app/assets/stylesheets/modules/themes/style-guide/blocks/_style-guide-header.sass +0 -12
  102. data/app/assets/stylesheets/modules/themes/style-guide/blocks/_style-guide-section.sass +0 -8
  103. data/app/assets/stylesheets/modules/themes/style-guide/settings/_style-guide-colors.sass +0 -33
  104. data/app/assets/stylesheets/modules/web-fonts/_playfair.sass +0 -11
  105. data/app/assets/stylesheets/settings/functions/_assign-inputs.sass +0 -35
  106. data/app/assets/stylesheets/settings/functions/_flex.sass +0 -70
  107. data/app/assets/stylesheets/settings/mixins/_break-points.sass +0 -37
  108. data/app/assets/stylesheets/settings/mixins/_flex.sass +0 -5
  109. data/app/assets/stylesheets/settings/mixins/_font-awesome.sass +0 -56
  110. data/app/assets/stylesheets/settings/mixins/_word-wrap.sass +0 -8
  111. data/app/assets/stylesheets/settings/mixins/grid/_grid-framework.sass +0 -42
  112. data/app/assets/stylesheets/settings/mixins/grid/_grid.sass +0 -15
  113. data/app/assets/stylesheets/settings/variables/_sanitize.sass +0 -20
  114. data/circle.yml +0 -13
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA256:
3
- metadata.gz: daad417c12471558fbfc4b24d546123edceddcc66bd0dc9a36b627a5240fcc71
4
- data.tar.gz: 8ca595e4de9c5c5254b42ab085493af307c18c4fb28bfc457431f9bc8f506c8f
2
+ SHA1:
3
+ metadata.gz: 9e18be2efd7f7f3842c69539602d2bf0568be953
4
+ data.tar.gz: 9a3b85be25051b69653ca9478f2ec6b98eb30962
5
5
  SHA512:
6
- metadata.gz: b714a56b1a4a24279ec9541890966753e0732fe71ce5f8362cf7ca5fe96a27d8d580c8a1e9a8af510b3d075bd049e218bb68550a4941e2f5f1165dfa035daa42
7
- data.tar.gz: 5921b06b65e48db8d302fbe1c10bf8681db19f40460414952f1eea9d5661d8f56e32576c723505be429e3db69184298353ca99db1dde54293af1a66714b1bf56
6
+ metadata.gz: dcf0665bef5ea3e6ea48e031b6e63261195eadc355cd83199bc4954ad16f999959942b9fc79591583ff9d463400313330ecab5ac5f939c7a85a314c5561e6a0e
7
+ data.tar.gz: f4779668f609a7e89118357f8c8063a51162216a1ac049f4995e31e9d0dd4914c83e710ed43723b4df80504120286bb281205720d989ba200a432c7a7323d7e3
data/README.md CHANGED
@@ -6,36 +6,6 @@ oulu is a sass mixin libraly.
6
6
 
7
7
  [docs](http://oulu.github.io/)
8
8
 
9
- ## import
10
-
11
- ```
12
- // oulu-functions-before-variables
13
- @import oulu-functions-before-variables
14
-
15
- // oulu-variables and yours
16
- @import {your variables}
17
- @import oulu-variables
18
-
19
- // oulu-functions-after-variables (functions need variables)
20
- @import oulu-functions-after-variables
21
-
22
- // oulu-mixins
23
- @import oulu-mixins
24
-
25
- // oulu-initializers
26
- @import oulu-initializers
27
-
28
- // oulu-helpers
29
- @import oulu-helpers
30
-
31
- // oulu-modules
32
- @import modules/web-fonts/font-awsome
33
- @import modules/web-fonts/montserrat
34
- @import modules/web-fonts/satisfy
35
- @import modules/web-fonts/icomoon
36
-
37
- ```
38
-
39
9
  ## Contributing
40
10
 
41
11
  1. Fork it
@@ -26,7 +26,6 @@
26
26
  // variables
27
27
  ///////////////////
28
28
 
29
- @import settings/variables/sanitize
30
29
  @import settings/variables/default
31
30
  @import settings/variables/modules
32
31
 
@@ -44,19 +43,18 @@
44
43
  @import settings/mixins/border
45
44
  @import settings/mixins/border-radius
46
45
  @import settings/mixins/table
46
+ @import settings/mixins/list
47
47
  @import settings/mixins/overlay
48
48
  @import settings/mixins/balloon-tail
49
49
  @import settings/mixins/margin-padding
50
50
  @import settings/mixins/animation
51
51
  @import settings/mixins/grid/grid-framework
52
52
  @import settings/mixins/grid/grid
53
- @import settings/mixins/break-points
54
53
  @import settings/mixins/grid
55
54
  @import settings/mixins/responsive-utilities
56
55
  @import settings/mixins/background
57
56
  @import settings/mixins/line
58
57
  @import settings/mixins/image
59
- @import settings/mixins/word-wrap
60
58
 
61
59
  // initializers
62
60
  ///////////////////
@@ -1,29 +1,14 @@
1
- @charset "UTF-8"
2
-
3
1
  //////////////
4
2
  //settings
5
3
  //////////////
6
4
 
7
- // functions-before-variables
8
- @import oulu-functions-before-variables
9
-
10
- // variables
11
- @import oulu-variables
12
-
13
- // oulu-functions-after-variables (functions need variables)
14
- @import oulu-functions-after-variables
15
-
16
- // mixins
17
- @import oulu-mixins
18
-
19
- //////////////
20
- // initializers
21
- //////////////
22
-
23
- @import oulu-initializers
24
-
25
- //////////////
26
- // helpers
27
- //////////////
5
+ // oulu-base
6
+ @import oulu-base
28
7
 
29
- @import oulu-helpers
8
+ // helper-classes
9
+ @import helpers/block
10
+ @import helpers/border
11
+ @import helpers/font-awsome
12
+ @import helpers/margin-padding
13
+ @import helpers/position
14
+ @import helpers/typoglaphy
@@ -1,4 +1,7 @@
1
1
  body
2
+ // layout
3
+ .has-no-gutter-grids
4
+ +grid(0)
2
5
  .is-horizontal-center-block
3
6
  display: block
4
7
  +margin(horizontal, auto)
@@ -9,6 +12,19 @@ body
9
12
  .is-clearfix
10
13
  +clearfix
11
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
+
12
28
  // float
13
29
  .is-float-left
14
30
  float: left
@@ -37,29 +53,37 @@ body
37
53
  overflow: hidden
38
54
 
39
55
  // position
40
- .is-position-relative
56
+ .is-relative
41
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)
42
63
 
43
64
  // vertical-align
44
- .is-vertical-align-middle
65
+ .is-vertical-middle
45
66
  vertical-align: middle !important
46
- .is-vertical-align-top
67
+ .is-vertical-top
47
68
  vertical-align: top !important
48
- .is-vertical-align-bottom
69
+ .is-vertical-bottom
49
70
  vertical-align: bottom !important
50
71
 
51
72
  // display
52
- .is-display-block
73
+ .is-block
53
74
  display: block
54
75
  .is-display-none
55
76
  display: none
56
77
  .is-display-none-important
57
78
  display: none !important
58
- .is-display-inline-block
79
+ .is-inline-block
59
80
  display: inline-block
60
- .is-display-inline
81
+ .is-inline
61
82
  display: inline
62
- .is-display-table-row
83
+ .is-table-row
63
84
  display: table-row !important
64
- .is-display-table-cell
85
+ .is-table-cell
65
86
  display: table-cell !important
87
+ .is-inline-blocks
88
+ >*
89
+ display: inline-block
@@ -1,35 +1,110 @@
1
- =assign-margin-padding($direction, $property, $n-px)
2
- @if $direction == horizontal
3
- #{$property}-left: $n-px
4
- #{$property}-right: $n-px
5
- @else if $direction == vertical
6
- #{$property}-top: $n-px
7
- #{$property}-bottom: $n-px
8
- @else
9
- #{$property}-#{$direction}: $n-px
10
1
  body
11
2
  @for $i from 0 through 20
12
- $n: $i*4
13
- $n-px: px_to_rem($n*1px)
14
- $properties: margin, padding
15
- $directions: top, bottom, left, right, horizontal, vertical
16
- $breakpoints: xs, sm, md, lg, xl, false
17
- $scopes: up, down
18
- @each $property in $properties
19
- @each $direction in $directions
20
- @each $breakpoint in $breakpoints
21
- @each $scope in $scopes
22
- @if $breakpoint
23
- .is-#{$property}-#{$direction}-#{$n}-#{$breakpoint}-#{$scope}
24
- @if $scope == up
25
- +media-breakpoint-up($breakpoint)
26
- +assign-margin-padding($direction, $property, $n-px)
27
- @else if $scope == down
28
- +media-breakpoint-down($breakpoint)
29
- +assign-margin-padding($direction, $property, $n-px)
30
- @else if $scope == only
31
- +media-breakpoint-only($breakpoint)
32
- +assign-margin-padding($direction, $property, $n-px)
33
- @else
34
- .is-#{$property}-#{$direction}-#{$n}
35
- +assign-margin-padding($direction, $property, $n-px)
3
+ .is-margin-bottom-#{$i*4px}
4
+ margin-bottom: $i*4px
5
+ .is-margin-top-#{$i*4px}
6
+ margin-top: $i*4px
7
+ .is-margin-left-#{$i*4px}
8
+ margin-left: $i*4px
9
+ .is-margin-right-#{$i*4px}
10
+ margin-right: $i*4px
11
+ .is-margin-horizontal-#{$i*4px}
12
+ +margin(horizontal, $i*4px)
13
+ .is-padding-bottom-#{$i*4px}
14
+ padding-bottom: $i*4px
15
+ .is-padding-top-#{$i*4px}
16
+ padding-top: $i*4px
17
+ .is-padding-left-#{$i*4px}
18
+ padding-left: $i*4px
19
+ .is-padding-right-#{$i*4px}
20
+ padding-right: $i*4px
21
+ .is-padding-horizontal-#{$i*4px}
22
+ +padding(horizontal, $i*4px)
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*4px}
60
+ margin-bottom: $i*4px
61
+ .has-margin-top-#{$i*4}
62
+ margin-top: $i*4px
63
+ .has-margin-left-#{$i*4}
64
+ margin-left: $i*4px
65
+ .has-margin-right-#{$i*4}
66
+ margin-right: $i*4px
67
+ .has-margin-horizontal-#{$i*4}
68
+ +margin(horizontal, $i*4px)
69
+ .has-padding-bottom-#{$i*4px}
70
+ padding-bottom: $i*4px
71
+ .has-padding-top-#{$i*4px}
72
+ padding-top: $i*4px
73
+ .has-padding-left-#{$i*4px}
74
+ padding-left: $i*4px
75
+ .has-padding-right-#{$i*4px}
76
+ padding-right: $i*4px
77
+ .has-padding-horizontal-#{$i*4px}
78
+ +padding(horizontal, $i*4px)
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)
@@ -1,33 +1,9 @@
1
- =assign-position($direction, $n-px)
2
- @if $direction == top
3
- +top($n-px)
4
- @else if $direction == bottom
5
- +bottom($n-px)
6
- @else if $direction == left
7
- +left($n-px)
8
- @else if $direction == right
9
- +right($n-px)
10
-
11
1
  @for $i from -8 through 8
12
- $n: $i*4
13
- $n-px: px_to_rem($n*1px)
14
- $directions: top, bottom, left, right
15
- $breakpoints: xs, sm, md, lg, xl, false
16
- $scopes: up, down
17
- @each $direction in $directions
18
- @each $breakpoint in $breakpoints
19
- @each $scope in $scopes
20
- @if $breakpoint
21
- .is-#{$direction}-#{$n}-#{$breakpoint}-#{$scope}
22
- @if $scope == up
23
- +media-breakpoint-up($breakpoint)
24
- +assign-position($direction, $n-px)
25
- @else if $scope == down
26
- +media-breakpoint-down($breakpoint)
27
- +assign-position($direction, $n-px)
28
- @else if $scope == only
29
- +media-breakpoint-only($breakpoint)
30
- +assign-position($direction, $n-px)
31
- @else
32
- .is-#{$direction}-#{$n}
33
- +assign-position($direction, $n-px)
2
+ .is-top-#{$i}px
3
+ +top(#{$i}px)
4
+ .is-bottom-#{$i}px
5
+ +top(#{$i}px)
6
+ .is-left-#{$i}px
7
+ +left(#{$i}px)
8
+ .is-right-#{$i}px
9
+ +right(#{$i}px)
@@ -2,41 +2,25 @@ body
2
2
  // typoglaphy
3
3
  .is-ja
4
4
  +basic-font
5
+ .is-serif
6
+ +serif
5
7
  .is-bold-ja
6
8
  +bold-ja
7
9
  .is-serif
8
10
  +serif
9
- .is-sans-serif
10
- +sans-serif
11
11
 
12
12
  @for $i from 0 through 24
13
- $value: px_to_rem($i * 1px)
14
- .is-letter-specing-#{$i}
13
+ $value: $i/10
14
+ .is-letter-specing-#{$i}px
15
+ letter-spacing: $value
16
+ .is-letter-specing-center-#{$i}px
15
17
  letter-spacing: $value
16
- .is-letter-specing-center-#{$i}
17
- letter-spacing: $value * -1
18
18
  text-indent: $value
19
19
 
20
20
  .is-white-space-nowrap
21
21
  white-space: nowrap
22
22
 
23
- $breakpoints: xs, sm, md, lg, xl, false
24
23
  $positions: left center right
25
- $scopes: up, down, only
26
- @each $breakpoint in $breakpoints
27
- @each $position in $positions
28
- @if $breakpoint
29
- @each $scope in $scopes
30
- .is-text-align-#{$position}-#{$breakpoint}-#{$scope}
31
- @if $scope == up
32
- +media-breakpoint-up($breakpoint)
33
- text-align: $position
34
- @else if $scope == down
35
- +media-breakpoint-down($breakpoint)
36
- text-align: $position
37
- @else if $scope == only
38
- +media-breakpoint-only($breakpoint)
39
- text-align: $position
40
- @else
41
- .is-text-align-#{$position}
42
- text-align: $position
24
+ @each $position in $positions
25
+ .is-text-align-#{$position}
26
+ text-align: $position
@@ -1,65 +1,40 @@
1
1
  =button-base
2
- line-height: 1.45
3
- display: inline-flex
4
- align-items: center
5
- justify-content: center
2
+ +inline-block(middle)
6
3
  cursor: pointer
7
4
  text-align: center
8
5
  user-select: none
9
6
  touch-action: manipulation
10
7
  text-decoration: none
11
8
  -webkit-tap-highlight-color: transparent
12
- &[type="button"],
13
- &[type="reset"],
14
- &[type="submit"]
15
- display: inline-block
16
- &.is-block
17
- display: block
18
- .is-block
19
- select
20
- display: block
21
- width: 100%
22
9
 
23
- =button-size($size, $border-width: false, $border-radius: .25rem)
10
+ =button-size($size, $border-width: false, $border-radius: 4px)
24
11
  $font-size: ""
25
- $button-height: ""
26
12
  @if $size == 'xs'
27
13
  $font-size: $xs-button-font-size
28
- $button-height: $font-size * $button-xs-height-ratio - if($border-width, $border-width, 0) * 2
29
- +padding(horizontal, ($button-height/$button-xs-width-ratio))
30
14
  @else if $size == 'sm'
31
15
  $font-size: $sm-button-font-size
32
- $button-height: $font-size * $button-sm-height-ratio - if($border-width, $border-width, 0) * 2
33
- +padding(horizontal, ($button-height/$button-sm-width-ratio))
34
16
  @else if $size == 'md'
35
17
  $font-size: $md-button-font-size
36
- $button-height: $font-size * $button-md-height-ratio - if($border-width, $border-width, 0) * 2
37
- +padding(horizontal, ($button-height/$button-md-width-ratio))
38
18
  @else if $size == 'lg'
39
19
  $font-size: $lg-button-font-size
40
- $button-height: $font-size * $button-lg-height-ratio - if($border-width, $border-width, 0) * 2
41
- +padding(horizontal, ($button-height/$button-lg-width-ratio))
42
20
  @else if $size == 'xl'
43
21
  $font-size: $xl-button-font-size
44
- $button-height: $font-size * $button-xl-height-ratio - if($border-width, $border-width, 0) * 2
45
- +padding(horizontal, ($button-height/$button-xl-width-ratio))
22
+ $button-height: round($font-size * 2.5 - if($border-width, $border-width, 0) * 2)
46
23
  @if $border-width
47
- border-width: $border-width
24
+ +border(all, $border-width)
48
25
  @else
49
26
  $border-width: 0
50
- height: auto
51
- min-height: $button-height
52
- $vertical-padding: ($button-height - (($font-size * 1.45) - ($border-width * 2))) / 2
27
+ $vertical-padding: ($button-height - round($font-size * 1.45) - ($border-width* 2)) / 2
53
28
  +padding(vertical, $vertical-padding)
29
+ +text-block($font-size 1.45)
30
+ +padding(horizontal, $button-height/1.6)
54
31
  @if $border-radius
55
- border-radius: $border-radius
56
- @if $font-size > .6875rem and .75rem > $font-size
57
- font-weight: 600
58
- @else if .999999rem < $font-size
59
- font-weight: 700
32
+ +border-radius($border-radius)
33
+ @if $font-size > 12px
34
+ font-weight: bold
60
35
  i,
61
36
  .is-button-icon
62
- @if $font-size > 1.75rem
37
+ @if $font-size > 28
63
38
  margin-right: $font-size/4
64
39
  @else
65
40
  margin-right: $font-size/3
@@ -67,7 +42,7 @@
67
42
  i,
68
43
  .is-button-icon
69
44
  margin-right: 0
70
- @if $font-size > 1.75rem
45
+ @if $font-size > 28
71
46
  margin-left: $font-size/4
72
47
  @else
73
48
  margin-left: $font-size/3
@@ -79,7 +54,7 @@
79
54
  +position(absolute, left $button-height/2, top 0)
80
55
  line-height: $button-height - ($border-width*2)
81
56
  input
82
- +padding(horizontal, ($button-height + if($font-size > 1.75rem, $font-size/4, $font-size/3)) $button-height/2)
57
+ +padding(horizontal, ($button-height + if($font-size > 28, $font-size/4, $font-size/3)) $button-height/2)
83
58
  height: $button-height - ($border-width*2)
84
59
  &.is-dummy-select
85
60
  $icon-width: round($font-size * 2.7)
@@ -87,85 +62,56 @@
87
62
  $button-height: $button-height
88
63
  padding-left: $icon-width
89
64
  &:before
90
- +fa(fas "\f0d7")
65
+ +fa("\f0d7")
91
66
  +position(absolute, left 0, top 0)
92
- border-right: .0625rem solid shade($secondary, 15%)
93
- +text-block($icon-size ($button-height - $border-width * 2), center shade($secondary, 55%))
67
+ border-right: 1px solid shade($secondary, 15%)
68
+ +text-block($icon-size $button-height, center shade($secondary, 55%))
94
69
  +size($icon-width $button-height)
95
70
  &.is-select
96
71
  padding: 0
97
- height: auto
98
- $icon-width: $font-size * 2.7
99
- $icon-size: $font-size * 1.3
72
+ $icon-width: round($font-size * 2.7)
73
+ $icon-size: round($font-size * 1.3)
100
74
  position: relative
101
- overflow: hidden
102
75
  &:after
103
- +fa(fas "\f0d7")
104
- +position(absolute, right 0, top 0, bottom 0, 0)
105
- +text-block($icon-size 1, center flex)
106
- align-items: center
107
- justify-content: center
76
+ +fa("\f0d7")
77
+ +position(absolute, right 0, top 0 bottom 0, 0)
78
+ +text-block($icon-size $button-height, center)
108
79
  +size($icon-width null)
109
80
  select
81
+ padding: 0 (round($font-size * 1.4) + $icon-width) 0 round($font-size * 1.4)
110
82
  font-size: inherit
111
- height: $button-height
112
- +padding(horizontal, (($font-size * 1.4) ($font-size * 1.4) + $icon-width))
83
+ +padding(vertical, $vertical-padding)
113
84
  +position(relative, 1)
114
85
  &.is-radio,
115
86
  &.is-checkbox
116
- $icon-space: $font-size * 3
87
+ $icon-space: round($font-size * 2.2)
117
88
  padding-left: $icon-space
118
89
  position: relative
119
- *
120
- cursor: pointer
121
90
  &:before
122
91
  content: ""
123
92
  display: block
124
- +position(absolute, left 1rem, top 50%)
125
- $check-base-size: $font-size * .9
93
+ +position(absolute, left 16px, top 50%)
94
+ $check-base-size: round($font-size * .9)
126
95
  +size($check-base-size)
127
- margin-top: $check-base-size / -2
96
+ margin-top: round($check-base-size / -2)
128
97
  &:after
129
- $check-icon-size: $font-size * 1.4
130
- +fa(fas "\f00c")
98
+ $check-icon-size: round($font-size * 1.4)
99
+ +fa("\f00c")
131
100
  opacity: 0
132
101
  +size($check-icon-size)
133
- +text-block($check-icon-size 1, $button-checked-icon-color)
134
- text-shadow: rgba(black, .4) 0 .0625rem .0625rem
135
- +position(absolute, left .875rem, top 50%)
136
- margin-top: $check-icon-size / -2 * 1.2
137
- &.is-icon
138
- +padding(horizontal, $button-height/3.5)
139
- font-size: $font-size * 1.4
140
- i,
141
- .is-button-icon
142
- margin-right: 0
102
+ +text-block($check-icon-size 1, $checked-icon)
103
+ text-shadow: rgba(black, .4) 0 1px 1px
104
+ +position(absolute, left 14px, top 50%)
105
+ margin-top: round($check-icon-size / -2 * 1.2)
143
106
 
144
107
  // button-grounp
108
+ .is-button-group >li &
109
+ border-radius: 0
145
110
  .is-button-group >li:first-child &
146
111
  border-radius: $border-radius 0 0 $border-radius
147
112
  .is-button-group >li:last-child &
148
113
  border-radius: 0 $border-radius $border-radius 0
149
- .is-button-group >li:not(:last-child) &
150
- @if $border-width / 2 < 1
151
- border-right-width: 0
152
- @else
153
- border-right-width: $border-width / 2
154
-
155
-
156
- // button-grounp
157
- .is-button-group >li [class*="is-button"]
158
- border-radius: 0
159
-
160
- // multi-lines-button-grounp
161
- .is-multi-lines-button-group
162
- display: flex
163
- flex-wrap: wrap
164
114
 
165
- .is-multi-lines-button-group >li
166
- flex: 0 0 50%
167
- +media-breakpoint-down(sm)
168
- flex: 0 0 100%
169
115
 
170
116
  =button-group
171
117
  .is-button-group