cactu 0.1.2 → 0.18.0
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.
- checksums.yaml +5 -5
- data/.gitignore +10 -15
- data/.travis.yml +7 -0
- data/CODE_OF_CONDUCT.md +74 -0
- data/Gemfile +1 -1
- data/{LICENSE.txt → LICENSE} +1 -1
- data/README.md +46 -16
- data/Rakefile +9 -0
- data/assets/stylesheets/base/_blocks.scss +24 -0
- data/assets/stylesheets/base/_global-variables.scss +62 -0
- data/assets/stylesheets/base/_reboot.scss +309 -0
- data/assets/stylesheets/cactu.scss +46 -0
- data/assets/stylesheets/components/_alerts.scss +48 -0
- data/assets/stylesheets/components/_buttons.scss +82 -0
- data/assets/stylesheets/components/_collapse.scss +84 -0
- data/assets/stylesheets/components/_dropdowns.scss +172 -0
- data/assets/stylesheets/components/_forms.scss +158 -0
- data/assets/stylesheets/components/_grids.scss +95 -0
- data/assets/stylesheets/components/_lists.scss +75 -0
- data/assets/stylesheets/components/_modals.scss +124 -0
- data/assets/stylesheets/components/_navbars.scss +190 -0
- data/assets/stylesheets/components/_navs.scss +52 -0
- data/assets/stylesheets/components/_paginations.scss +76 -0
- data/assets/stylesheets/components/_tables.scss +49 -0
- data/assets/stylesheets/components/_tooltips.scss +138 -0
- data/assets/stylesheets/elements/_button.scss +94 -0
- data/assets/stylesheets/elements/_code.scss +75 -0
- data/assets/stylesheets/elements/_icon.scss +66 -0
- data/assets/stylesheets/elements/_image.scss +33 -0
- data/assets/stylesheets/elements/_typography.scss +130 -0
- data/assets/stylesheets/functions/_colors.scss +40 -0
- data/assets/stylesheets/functions/_strings.scss +14 -0
- data/assets/stylesheets/mixins/_alerts.scss +18 -0
- data/assets/stylesheets/mixins/_breakpoints.scss +93 -0
- data/assets/stylesheets/mixins/_buttons.scss +96 -0
- data/assets/stylesheets/mixins/_forms.scss +44 -0
- data/assets/stylesheets/mixins/_grid.scss +18 -0
- data/assets/stylesheets/mixins/_hover.scss +27 -0
- data/assets/stylesheets/mixins/_icons.scss +22 -0
- data/assets/stylesheets/mixins/_navbar.scss +60 -0
- data/assets/stylesheets/mixins/_positions.scss +12 -0
- data/assets/stylesheets/mixins/_transition.scss +16 -0
- data/assets/stylesheets/utilities/_classes.scss +69 -0
- data/assets/stylesheets/utilities/_syntax.scss +81 -0
- data/cactu.gemspec +15 -15
- data/lib/cactu.rb +40 -12
- data/lib/cactu/engine.rb +11 -3
- data/lib/cactu/version.rb +1 -1
- metadata +123 -110
- data/app/assets/stylesheets/_cactu.scss +0 -15
- data/app/assets/stylesheets/config/_variables.scss +0 -27
- data/app/assets/stylesheets/functions/_grid.scss +0 -32
- data/app/assets/stylesheets/mixins/_fonts.scss +0 -13
- data/app/assets/stylesheets/mixins/_grid.scss +0 -81
- data/app/assets/stylesheets/mixins/_menu.scss +0 -47
- data/app/assets/stylesheets/ui/_base.scss +0 -53
- data/app/assets/stylesheets/ui/_buttons.scss +0 -13
- data/app/assets/stylesheets/ui/_forms.scss +0 -3
- data/app/assets/stylesheets/ui/_images.scss +0 -3
- data/app/assets/stylesheets/ui/_menus.scss +0 -4
- data/app/assets/stylesheets/ui/_tables.scss +0 -3
- data/app/assets/stylesheets/ui/_text.scss +0 -71
- data/bin/cactu +0 -6
- data/lib/cactu/generator.rb +0 -80
- data/test/cactu_app/.gitignore +0 -16
- data/test/cactu_app/Gemfile +0 -49
- data/test/cactu_app/README.rdoc +0 -28
- data/test/cactu_app/Rakefile +0 -6
- data/test/cactu_app/app/assets/images/.keep +0 -0
- data/test/cactu_app/app/assets/javascripts/application.js +0 -16
- data/test/cactu_app/app/assets/stylesheets/application.css.scss +0 -16
- data/test/cactu_app/app/assets/stylesheets/test/_test.css.scss +0 -10
- data/test/cactu_app/app/assets/stylesheets/test/config/_responsive_large.css.scss +0 -7
- data/test/cactu_app/app/assets/stylesheets/test/config/_responsive_medium.css.scss +0 -7
- data/test/cactu_app/app/assets/stylesheets/test/config/_responsive_short.css.scss +0 -3
- data/test/cactu_app/app/assets/stylesheets/test/config/_variables.css.scss +0 -7
- data/test/cactu_app/app/assets/stylesheets/test/pages/_home.css.scss +0 -2
- data/test/cactu_app/app/assets/stylesheets/test/ui/_anchors.css.scss +0 -0
- data/test/cactu_app/app/assets/stylesheets/test/ui/_base.css.scss +0 -0
- data/test/cactu_app/app/assets/stylesheets/test/ui/_navigations.css.scss +0 -3
- data/test/cactu_app/app/assets/stylesheets/test/ui/_text.css.scss +0 -1
- data/test/cactu_app/app/controllers/application_controller.rb +0 -5
- data/test/cactu_app/app/controllers/concerns/.keep +0 -0
- data/test/cactu_app/app/controllers/home_controller.rb +0 -5
- data/test/cactu_app/app/controllers/usage_controller.rb +0 -13
- data/test/cactu_app/app/helpers/application_helper.rb +0 -2
- data/test/cactu_app/app/mailers/.keep +0 -0
- data/test/cactu_app/app/models/.keep +0 -0
- data/test/cactu_app/app/models/concerns/.keep +0 -0
- data/test/cactu_app/app/views/home/index.html.haml +0 -7
- data/test/cactu_app/app/views/layouts/application.html.haml +0 -20
- data/test/cactu_app/app/views/usage/base.html.haml +0 -19
- data/test/cactu_app/app/views/usage/components.html.haml +0 -4
- data/test/cactu_app/app/views/usage/started.html.haml +0 -4
- data/test/cactu_app/bin/bundle +0 -3
- data/test/cactu_app/bin/rails +0 -4
- data/test/cactu_app/bin/rake +0 -4
- data/test/cactu_app/config.ru +0 -4
- data/test/cactu_app/config/application.rb +0 -23
- data/test/cactu_app/config/boot.rb +0 -4
- data/test/cactu_app/config/database.yml +0 -25
- data/test/cactu_app/config/environment.rb +0 -5
- data/test/cactu_app/config/environments/development.rb +0 -29
- data/test/cactu_app/config/environments/production.rb +0 -80
- data/test/cactu_app/config/environments/test.rb +0 -36
- data/test/cactu_app/config/initializers/backtrace_silencers.rb +0 -7
- data/test/cactu_app/config/initializers/filter_parameter_logging.rb +0 -4
- data/test/cactu_app/config/initializers/inflections.rb +0 -16
- data/test/cactu_app/config/initializers/mime_types.rb +0 -5
- data/test/cactu_app/config/initializers/secret_token.rb +0 -12
- data/test/cactu_app/config/initializers/session_store.rb +0 -3
- data/test/cactu_app/config/initializers/wrap_parameters.rb +0 -14
- data/test/cactu_app/config/locales/en.yml +0 -23
- data/test/cactu_app/config/routes.rb +0 -6
- data/test/cactu_app/db/seeds.rb +0 -7
- data/test/cactu_app/lib/assets/.keep +0 -0
- data/test/cactu_app/lib/tasks/.keep +0 -0
- data/test/cactu_app/log/.keep +0 -0
- data/test/cactu_app/public/404.html +0 -58
- data/test/cactu_app/public/422.html +0 -58
- data/test/cactu_app/public/500.html +0 -57
- data/test/cactu_app/public/favicon.ico +0 -0
- data/test/cactu_app/public/robots.txt +0 -5
- data/test/cactu_app/test/controllers/.keep +0 -0
- data/test/cactu_app/test/fixtures/.keep +0 -0
- data/test/cactu_app/test/helpers/.keep +0 -0
- data/test/cactu_app/test/integration/.keep +0 -0
- data/test/cactu_app/test/mailers/.keep +0 -0
- data/test/cactu_app/test/models/.keep +0 -0
- data/test/cactu_app/test/test_helper.rb +0 -15
- data/test/cactu_app/vendor/assets/javascripts/.keep +0 -0
- data/test/cactu_app/vendor/assets/stylesheets/.keep +0 -0
@@ -0,0 +1,46 @@
|
|
1
|
+
/*!
|
2
|
+
* Cactu v0.18.0 (http://cactu.site/)
|
3
|
+
* Copyright 2018 Giovanni Mendoza
|
4
|
+
* Licensed under MIT (https://github.com/mendozagioo/cactu/blob/master/LICENSE)
|
5
|
+
*/
|
6
|
+
|
7
|
+
@import "base/global-variables";
|
8
|
+
@import "base/reboot";
|
9
|
+
@import "base/blocks";
|
10
|
+
|
11
|
+
@import "functions/colors";
|
12
|
+
@import "functions/strings";
|
13
|
+
|
14
|
+
@import "mixins/alerts";
|
15
|
+
@import "mixins/breakpoints";
|
16
|
+
@import "mixins/buttons";
|
17
|
+
@import "mixins/forms";
|
18
|
+
@import "mixins/grid";
|
19
|
+
@import "mixins/hover";
|
20
|
+
@import "mixins/icons";
|
21
|
+
@import "mixins/navbar";
|
22
|
+
@import "mixins/positions";
|
23
|
+
@import "mixins/transition";
|
24
|
+
|
25
|
+
@import "elements/button";
|
26
|
+
@import "elements/code";
|
27
|
+
@import "elements/icon";
|
28
|
+
@import "elements/image";
|
29
|
+
@import "elements/typography";
|
30
|
+
|
31
|
+
@import "components/alerts";
|
32
|
+
@import "components/buttons";
|
33
|
+
@import "components/collapse";
|
34
|
+
@import "components/dropdowns";
|
35
|
+
@import "components/forms";
|
36
|
+
@import "components/grids";
|
37
|
+
@import "components/lists";
|
38
|
+
@import "components/modals";
|
39
|
+
@import "components/navbars";
|
40
|
+
@import "components/navs";
|
41
|
+
@import "components/paginations";
|
42
|
+
@import "components/tables";
|
43
|
+
@import "components/tooltips";
|
44
|
+
|
45
|
+
@import "utilities/classes";
|
46
|
+
@import "utilities/syntax";
|
@@ -0,0 +1,48 @@
|
|
1
|
+
//
|
2
|
+
// Alerts
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
// Variables
|
7
|
+
//
|
8
|
+
$alert-padding: 1rem !default;
|
9
|
+
$alert-radius: $radius !default;
|
10
|
+
$alert-background-level: -10 !default;
|
11
|
+
$alert-border-level: -2 !default;
|
12
|
+
$alert-color-level: 6 !default;
|
13
|
+
$alert-color-base: $yellow !default;
|
14
|
+
$alert-background: theme-color-level($alert-color-base, $alert-background-level) !default;
|
15
|
+
$alert-border: theme-color-level($alert-color-base, $alert-border-level) !default;
|
16
|
+
$alert-color: theme-color-level($alert-color-base, $alert-color-level) !default;
|
17
|
+
|
18
|
+
|
19
|
+
.alert,
|
20
|
+
.alert-dismissible {
|
21
|
+
position: relative;
|
22
|
+
padding: $alert-padding;
|
23
|
+
border-radius: $alert-radius;
|
24
|
+
@include alert-theme($alert-background, $alert-border, $alert-color);
|
25
|
+
|
26
|
+
h1, h2, h3, h4, h5, h6 {
|
27
|
+
margin-top: 0;
|
28
|
+
}
|
29
|
+
}
|
30
|
+
|
31
|
+
.alert-dismissible {
|
32
|
+
padding-right: 2.625rem;
|
33
|
+
|
34
|
+
.close {
|
35
|
+
position: absolute;
|
36
|
+
top: 5px;
|
37
|
+
right: 0;
|
38
|
+
font-size: 1.625rem;
|
39
|
+
line-height: 1;
|
40
|
+
color: inherit;
|
41
|
+
box-shadow: none !important;
|
42
|
+
background-color: transparent;
|
43
|
+
|
44
|
+
@include hover-focus {
|
45
|
+
color: darken($alert-background, 80%);
|
46
|
+
}
|
47
|
+
}
|
48
|
+
}
|
@@ -0,0 +1,82 @@
|
|
1
|
+
//
|
2
|
+
// Buttons
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
// Variables
|
7
|
+
//
|
8
|
+
$button-first-radius: $radius 0 0 $radius !default;
|
9
|
+
$button-last-radius: 0 $radius $radius 0 !default;
|
10
|
+
$vertical-button-first-radius: $radius $radius 0 0 !default;
|
11
|
+
$vertical-button-last-radius: 0 0 $radius $radius !default;
|
12
|
+
$button-background-selected: darken($gray-200, 10%) !default;
|
13
|
+
|
14
|
+
|
15
|
+
.button-group,
|
16
|
+
.button-group-vertical {
|
17
|
+
button,
|
18
|
+
.button {
|
19
|
+
z-index: 2;
|
20
|
+
|
21
|
+
&:focus,
|
22
|
+
&:active,
|
23
|
+
&.active {
|
24
|
+
z-index: 1;
|
25
|
+
}
|
26
|
+
|
27
|
+
&.selected {
|
28
|
+
background-color: $button-background-selected;
|
29
|
+
}
|
30
|
+
|
31
|
+
& ~ button,
|
32
|
+
& ~ .button {
|
33
|
+
margin-left: 0;
|
34
|
+
}
|
35
|
+
}
|
36
|
+
}
|
37
|
+
|
38
|
+
.button-group {
|
39
|
+
display: inline-flex;
|
40
|
+
|
41
|
+
button,
|
42
|
+
.button {
|
43
|
+
&:not(:first-child):not(:last-child) {
|
44
|
+
border-radius: 0;
|
45
|
+
}
|
46
|
+
|
47
|
+
&:not(:first-child) {
|
48
|
+
margin-left: -$border-width;
|
49
|
+
}
|
50
|
+
|
51
|
+
&:first-child {
|
52
|
+
border-radius: $button-first-radius;
|
53
|
+
}
|
54
|
+
|
55
|
+
&:last-child {
|
56
|
+
border-radius: $button-last-radius;
|
57
|
+
}
|
58
|
+
}
|
59
|
+
}
|
60
|
+
|
61
|
+
.button-group-vertical {
|
62
|
+
display: inline-grid;
|
63
|
+
|
64
|
+
button,
|
65
|
+
.button {
|
66
|
+
&:not(:first-child):not(:last-child) {
|
67
|
+
border-radius: 0;
|
68
|
+
}
|
69
|
+
|
70
|
+
&:not(:first-child) {
|
71
|
+
margin-top: -$border-width;
|
72
|
+
}
|
73
|
+
|
74
|
+
&:first-child {
|
75
|
+
border-radius: $vertical-button-first-radius;
|
76
|
+
}
|
77
|
+
|
78
|
+
&:last-child {
|
79
|
+
border-radius: $vertical-button-last-radius;
|
80
|
+
}
|
81
|
+
}
|
82
|
+
}
|
@@ -0,0 +1,84 @@
|
|
1
|
+
//
|
2
|
+
// Collapse
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
// Variables
|
7
|
+
//
|
8
|
+
$content-collaspse-padding: 1rem !default;
|
9
|
+
$accordion-collapse-border: $border-base !default;
|
10
|
+
$accordion-collapse-first-radius: $radius $radius 0 0 !default;
|
11
|
+
$accordion-collapse-last-radius: 0 0 $radius $radius !default;
|
12
|
+
$accordion-header-padding: 1rem !default;
|
13
|
+
$accordion-header-background: lighten($gray-200, 5%) !default;
|
14
|
+
$accordion-header-hover-background: darken($accordion-header-background, 3%) !default;
|
15
|
+
|
16
|
+
|
17
|
+
// Blocks
|
18
|
+
//
|
19
|
+
%basic-collapse {
|
20
|
+
height: 100%;
|
21
|
+
opacity: 1;
|
22
|
+
padding: $content-collaspse-padding;
|
23
|
+
}
|
24
|
+
|
25
|
+
|
26
|
+
.collapse {
|
27
|
+
.collapse-container {
|
28
|
+
height: 0;
|
29
|
+
opacity: 0;
|
30
|
+
margin: 0;
|
31
|
+
padding: 0;
|
32
|
+
border: 0;
|
33
|
+
overflow: hidden;
|
34
|
+
@include transition($transition-all);
|
35
|
+
|
36
|
+
&.collapsed {
|
37
|
+
@extend %basic-collapse;
|
38
|
+
}
|
39
|
+
}
|
40
|
+
|
41
|
+
[type="checkbox"],
|
42
|
+
[type="radio"] {
|
43
|
+
display: none;
|
44
|
+
|
45
|
+
&:checked {
|
46
|
+
~ .collapse-container {
|
47
|
+
@extend %basic-collapse;
|
48
|
+
}
|
49
|
+
}
|
50
|
+
}
|
51
|
+
}
|
52
|
+
|
53
|
+
.accordion {
|
54
|
+
overflow: hidden;
|
55
|
+
|
56
|
+
.collapse {
|
57
|
+
border: $accordion-collapse-border;
|
58
|
+
overflow: hidden;
|
59
|
+
|
60
|
+
.header {
|
61
|
+
display: block;
|
62
|
+
padding: $accordion-header-padding;
|
63
|
+
margin: 0;
|
64
|
+
cursor: pointer;
|
65
|
+
background-color: $accordion-header-background;
|
66
|
+
|
67
|
+
&:hover {
|
68
|
+
background-color: $accordion-header-hover-background;
|
69
|
+
}
|
70
|
+
}
|
71
|
+
|
72
|
+
&:not(:first-child) {
|
73
|
+
margin-top: -$border-width;
|
74
|
+
}
|
75
|
+
|
76
|
+
&:first-child {
|
77
|
+
border-radius: $accordion-collapse-first-radius;
|
78
|
+
}
|
79
|
+
|
80
|
+
&:last-child {
|
81
|
+
border-radius: $accordion-collapse-last-radius;
|
82
|
+
}
|
83
|
+
}
|
84
|
+
}
|
@@ -0,0 +1,172 @@
|
|
1
|
+
//
|
2
|
+
// Dropdowns
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
// Variables
|
7
|
+
//
|
8
|
+
$dropdown-menu-border: $border-base !default;
|
9
|
+
$dropdown-item-padding: .3125rem 1rem !default;
|
10
|
+
$dropdown-menu-top: 1.625rem + .75rem + .125rem !default;
|
11
|
+
$drop-dow-open-shadow: 0 0 0 $outline-width darken($gray-200, 20%) !default;
|
12
|
+
$triangle-width: 5px !default;
|
13
|
+
$triangle-transition: transform .1s ease-in-out !default;
|
14
|
+
$drop-menu-min-width: 12.5rem !default;
|
15
|
+
$drop-menu-padding: .5rem 0 !default;
|
16
|
+
$drop-menu-radius: $radius !default;
|
17
|
+
$drop-menu-color: $text-color !default;
|
18
|
+
$drop-menu-background: $white !default;
|
19
|
+
$drop-menu-transition: color $speed ease-in-out, background-color $speed ease-in-out !default;
|
20
|
+
$drop-active-color: $text-color !default;
|
21
|
+
$drop-active-background: $gray-200 !default;
|
22
|
+
$separator-color: $border-color !default;
|
23
|
+
|
24
|
+
|
25
|
+
.dropdown,
|
26
|
+
.dropup,
|
27
|
+
.dropright,
|
28
|
+
.dropleft {
|
29
|
+
position: relative;
|
30
|
+
|
31
|
+
[type="checkbox"] {
|
32
|
+
display: none;
|
33
|
+
|
34
|
+
&:checked {
|
35
|
+
& ~ .drop-menu {
|
36
|
+
display: inline-block;
|
37
|
+
}
|
38
|
+
|
39
|
+
& ~ .toggle {
|
40
|
+
&:after {
|
41
|
+
transform: rotate(180deg);
|
42
|
+
}
|
43
|
+
}
|
44
|
+
}
|
45
|
+
}
|
46
|
+
|
47
|
+
.toggle {
|
48
|
+
padding: .5rem;
|
49
|
+
margin: 0;
|
50
|
+
|
51
|
+
&:after {
|
52
|
+
@extend %shape-base;
|
53
|
+
margin-left: .4375rem;
|
54
|
+
@include transition($triangle-transition);
|
55
|
+
}
|
56
|
+
|
57
|
+
@include hover-focus {
|
58
|
+
cursor: pointer;
|
59
|
+
}
|
60
|
+
}
|
61
|
+
|
62
|
+
.drop-menu {
|
63
|
+
position: absolute;
|
64
|
+
display: none;
|
65
|
+
min-width: $drop-menu-min-width;
|
66
|
+
flex-direction: column;
|
67
|
+
padding: $drop-menu-padding;
|
68
|
+
border: $dropdown-menu-border;
|
69
|
+
border-radius: $drop-menu-radius;
|
70
|
+
background-color: $drop-menu-background;
|
71
|
+
z-index: 10;
|
72
|
+
|
73
|
+
* {
|
74
|
+
|
75
|
+
color: $drop-menu-color;
|
76
|
+
padding: $dropdown-item-padding;
|
77
|
+
margin: 0;
|
78
|
+
@include transition($drop-menu-transition);
|
79
|
+
}
|
80
|
+
|
81
|
+
a {
|
82
|
+
display: block;
|
83
|
+
@include hover-focus {
|
84
|
+
text-decoration: none;
|
85
|
+
background-color: darken($drop-menu-background, 5%);
|
86
|
+
}
|
87
|
+
}
|
88
|
+
|
89
|
+
.drop-active {
|
90
|
+
color: $drop-active-color;
|
91
|
+
background-color: $drop-active-background;
|
92
|
+
}
|
93
|
+
|
94
|
+
.drop-separator {
|
95
|
+
height: 1px;
|
96
|
+
background: $separator-color;
|
97
|
+
margin: .375rem 0;
|
98
|
+
padding: 0;
|
99
|
+
}
|
100
|
+
|
101
|
+
.drop-item {
|
102
|
+
* {
|
103
|
+
display: inline-block;
|
104
|
+
padding: 0;
|
105
|
+
}
|
106
|
+
}
|
107
|
+
}
|
108
|
+
|
109
|
+
&.dropped {
|
110
|
+
.toggle {
|
111
|
+
&:after {
|
112
|
+
transform: rotate(180deg);
|
113
|
+
}
|
114
|
+
}
|
115
|
+
|
116
|
+
.drop-menu { display: inline-block; }
|
117
|
+
}
|
118
|
+
}
|
119
|
+
|
120
|
+
.dropdown {
|
121
|
+
.toggle:after {
|
122
|
+
@include triangle-icon($triangle-width, 'down');
|
123
|
+
}
|
124
|
+
|
125
|
+
.drop-menu {
|
126
|
+
left: 0;
|
127
|
+
top: $dropdown-menu-top;
|
128
|
+
}
|
129
|
+
}
|
130
|
+
|
131
|
+
.dropup {
|
132
|
+
.toggle:after {
|
133
|
+
@include triangle-icon($triangle-width, 'up');
|
134
|
+
}
|
135
|
+
|
136
|
+
.drop-menu {
|
137
|
+
left: 0;
|
138
|
+
bottom: 3rem;
|
139
|
+
}
|
140
|
+
}
|
141
|
+
|
142
|
+
.dropright {
|
143
|
+
.toggle:after {
|
144
|
+
@include triangle-icon($triangle-width, 'right');
|
145
|
+
}
|
146
|
+
|
147
|
+
.drop-menu {
|
148
|
+
margin-left: .125rem;
|
149
|
+
}
|
150
|
+
}
|
151
|
+
|
152
|
+
.dropleft {
|
153
|
+
input:checked ~ .button:before {
|
154
|
+
transform: rotate(180deg);
|
155
|
+
}
|
156
|
+
|
157
|
+
.toggle {
|
158
|
+
&:after {
|
159
|
+
display: none;
|
160
|
+
}
|
161
|
+
&:before {
|
162
|
+
@extend %shape-base;
|
163
|
+
margin-right: .4375rem;
|
164
|
+
@include triangle-icon($triangle-width, 'left');
|
165
|
+
@include transition($triangle-transition);
|
166
|
+
}
|
167
|
+
}
|
168
|
+
|
169
|
+
.drop-menu {
|
170
|
+
left: -$drop-menu-min-width - .125;
|
171
|
+
}
|
172
|
+
}
|
@@ -0,0 +1,158 @@
|
|
1
|
+
//
|
2
|
+
// Forms
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
// Variables
|
7
|
+
//
|
8
|
+
$input-color: $text-color !default;
|
9
|
+
$input-background: $white !default;
|
10
|
+
$input-padding: .375rem .75rem !default;
|
11
|
+
$input-border: $border-base !default;
|
12
|
+
$input-radius: $radius !default;
|
13
|
+
$input-box-shadow: inset 0 1px 2px rgba($black, .075) !default;
|
14
|
+
$input-placeholder-color: $gray-600 !default;
|
15
|
+
$input-disabled-background: $gray-200 !default;
|
16
|
+
$input-transition: border-color $speed ease-in-out, box-shadow $speed ease-in-out !default;
|
17
|
+
$disabled-color: darken($gray-500, 15%) !default;
|
18
|
+
$help-font-size: .75rem !default;
|
19
|
+
$help-margin-top: .25rem !default;
|
20
|
+
$select-height: calc(2.25rem + 2px) !default;
|
21
|
+
$custom-select-padding-x: .75rem !default;
|
22
|
+
$custom-select-indicator-padding: 1rem !default;
|
23
|
+
$custom-select-indicator-color: $gray-800 !default;
|
24
|
+
$custom-select-indicator: str-replace(url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'%3E%3Cpath fill='#{$custom-select-indicator-color}' d='M2 0L0 2h4zm0 5L0 3h4z'/%3E%3C/svg%3E"), "#", "%23") !default;
|
25
|
+
$custom-select-background-size: 8px 10px !default; // In pixels because image dimensions
|
26
|
+
$select-background: $input-background $custom-select-indicator no-repeat right $custom-select-padding-x center !default;
|
27
|
+
$valid-color: $green !default;
|
28
|
+
$invalid-color: $red !default;
|
29
|
+
|
30
|
+
|
31
|
+
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]),
|
32
|
+
select,
|
33
|
+
textarea {
|
34
|
+
color: $input-color;
|
35
|
+
padding: $input-padding;
|
36
|
+
border: $input-border;
|
37
|
+
border-radius: $input-radius;
|
38
|
+
box-shadow: $input-box-shadow;
|
39
|
+
background-color: $input-background;
|
40
|
+
|
41
|
+
@include transition($input-transition);
|
42
|
+
|
43
|
+
&:focus {
|
44
|
+
outline: 0;
|
45
|
+
@include input-focus;
|
46
|
+
}
|
47
|
+
|
48
|
+
&::placeholder {
|
49
|
+
color: $input-placeholder-color;
|
50
|
+
opacity: 1;
|
51
|
+
}
|
52
|
+
|
53
|
+
&:disabled {
|
54
|
+
color: $disabled-color;
|
55
|
+
background-color: $input-disabled-background;
|
56
|
+
cursor: not-allowed;
|
57
|
+
opacity: .57;
|
58
|
+
}
|
59
|
+
|
60
|
+
&[readonly] {
|
61
|
+
background-color: $input-disabled-background;
|
62
|
+
opacity: 1;
|
63
|
+
}
|
64
|
+
}
|
65
|
+
|
66
|
+
input[type="range"] {
|
67
|
+
&:focus {
|
68
|
+
outline: none;
|
69
|
+
}
|
70
|
+
|
71
|
+
&::-moz-focus-outer {
|
72
|
+
border: 0;
|
73
|
+
}
|
74
|
+
}
|
75
|
+
|
76
|
+
select:not([size]):not([multiple]) {
|
77
|
+
height: $select-height;
|
78
|
+
padding: .375rem 1.75rem .375rem .75rem;
|
79
|
+
background: $select-background;
|
80
|
+
background-size: $custom-select-background-size;
|
81
|
+
appearance: none;
|
82
|
+
|
83
|
+
&:disabled { background-color: $input-disabled-background; }
|
84
|
+
|
85
|
+
&::-ms-value {
|
86
|
+
// For visual consistency with IE and (under certain conditions) Edge.
|
87
|
+
color: $input-color;
|
88
|
+
background-color: $input-background;
|
89
|
+
}
|
90
|
+
}
|
91
|
+
|
92
|
+
select {
|
93
|
+
// Remove the outline focus on Firefox
|
94
|
+
&:-moz-focusring {
|
95
|
+
color: transparent;
|
96
|
+
text-shadow: 0 0 0 $text-color;
|
97
|
+
}
|
98
|
+
|
99
|
+
// Hides the default caret in IE11
|
100
|
+
&::-ms-expand {
|
101
|
+
opacity: 0;
|
102
|
+
}
|
103
|
+
}
|
104
|
+
|
105
|
+
.form-group {
|
106
|
+
margin-bottom: 1rem;
|
107
|
+
|
108
|
+
input,
|
109
|
+
select,
|
110
|
+
textarea {
|
111
|
+
width: 100%;
|
112
|
+
}
|
113
|
+
|
114
|
+
[type="checkbox"],
|
115
|
+
[type="radio"] {
|
116
|
+
display: inline;
|
117
|
+
width: .8125rem;
|
118
|
+
height: 1rem;
|
119
|
+
margin-right: .125rem;
|
120
|
+
}
|
121
|
+
|
122
|
+
.help,
|
123
|
+
[class$="-feedback"] {
|
124
|
+
display: block;
|
125
|
+
font-size: $help-font-size;
|
126
|
+
margin-top: $help-margin-top;
|
127
|
+
}
|
128
|
+
|
129
|
+
.checkbox + .checkbox,
|
130
|
+
.radio + .radio {
|
131
|
+
margin-left: 1rem;
|
132
|
+
}
|
133
|
+
}
|
134
|
+
|
135
|
+
@include validation-states("valid", $valid-color);
|
136
|
+
@include validation-states("invalid", $invalid-color);
|
137
|
+
|
138
|
+
.form-columns {
|
139
|
+
display: flex;
|
140
|
+
flex-wrap: wrap;
|
141
|
+
|
142
|
+
.column,
|
143
|
+
[class*="column-of-"] {
|
144
|
+
padding: 0 .5rem;
|
145
|
+
|
146
|
+
&:first-child {
|
147
|
+
padding-left: 0;
|
148
|
+
}
|
149
|
+
|
150
|
+
&:last-child {
|
151
|
+
padding-right: 0;
|
152
|
+
}
|
153
|
+
|
154
|
+
@include breakpoint-cellphone {
|
155
|
+
padding: 0;
|
156
|
+
}
|
157
|
+
}
|
158
|
+
}
|