cm-admin 0.1.0 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +12 -0
- data/.rspec +3 -0
- data/.travis.yml +6 -0
- data/Gemfile +7 -1
- data/Gemfile.lock +121 -0
- data/LICENSE.txt +21 -0
- data/README.md +20 -21
- data/app/assets/images/logo.png +0 -0
- data/app/assets/stylesheets/cm_admin/base/auth.scss +73 -0
- data/app/assets/stylesheets/cm_admin/base/common.scss +237 -0
- data/app/assets/stylesheets/cm_admin/base/filters.scss +200 -0
- data/app/assets/stylesheets/cm_admin/base/form.scss +197 -0
- data/app/assets/stylesheets/cm_admin/base/main-nav.scss +47 -0
- data/app/assets/stylesheets/cm_admin/base/navbar.scss +65 -0
- data/app/assets/stylesheets/cm_admin/base/quicksearch.scss +76 -0
- data/app/assets/stylesheets/cm_admin/base/scaffold.scss +96 -0
- data/app/assets/stylesheets/cm_admin/base/show.scss +76 -0
- data/app/assets/stylesheets/cm_admin/base/sidebar.scss +225 -0
- data/app/assets/stylesheets/cm_admin/base/table.scss +320 -0
- data/app/assets/stylesheets/cm_admin/base/tabs.scss +26 -0
- data/{lib/generators/cm_admin/templates/assets/stylesheets/application.css.scss → app/assets/stylesheets/cm_admin/cm_admin.css.scss} +12 -16
- data/app/assets/stylesheets/cm_admin/components/_alerts.scss +101 -0
- data/app/assets/stylesheets/cm_admin/components/_buttons.scss +135 -0
- data/app/assets/stylesheets/cm_admin/components/_dropdown-popup.scss +153 -0
- data/app/assets/stylesheets/cm_admin/components/_input.scss +274 -0
- data/app/assets/stylesheets/cm_admin/components/_modal.scss +34 -0
- data/app/assets/stylesheets/cm_admin/components/_range.scss +31 -0
- data/app/assets/stylesheets/cm_admin/components/_status-tag.scss +68 -0
- data/app/assets/stylesheets/cm_admin/components/index.scss +7 -0
- data/app/assets/stylesheets/cm_admin/dependency/bootstrap.min.css +7 -0
- data/app/assets/stylesheets/cm_admin/helpers/_mixins.scss +20 -0
- data/app/assets/stylesheets/cm_admin/helpers/_variable.scss +87 -0
- data/app/assets/stylesheets/cm_admin/helpers/index.scss +2 -0
- data/app/controllers/cm_admin/application_controller.rb +11 -0
- data/app/controllers/cm_admin/exports_controller.rb +16 -0
- data/app/controllers/cm_admin/static_controller.rb +12 -0
- data/app/helpers/cm_admin/application_helper.rb +11 -0
- data/app/helpers/cm_admin/custom_helper.rb +4 -0
- data/app/javascript/packs/cm_admin/application.js +22 -0
- data/app/javascript/packs/cm_admin/filters.js +347 -0
- data/app/javascript/packs/cm_admin/quick_search.js +67 -0
- data/app/javascript/packs/cm_admin/scaffolds.js +43 -0
- data/app/javascript/stylesheets/cm_admin/application.scss +3 -0
- data/app/views/cm_admin/main/_associated_table.html.slim +60 -0
- data/app/views/cm_admin/main/_cm_pagy_nav.html.slim +23 -0
- data/app/views/cm_admin/main/_filters.html.slim +1 -0
- data/app/views/cm_admin/main/_nested_fields.html.slim +7 -0
- data/app/views/cm_admin/main/_nested_table_form.html.slim +6 -0
- data/app/views/cm_admin/main/_table.html.slim +60 -0
- data/app/views/cm_admin/main/_tabs.html.slim +5 -0
- data/app/views/cm_admin/main/_top_navbar.html.slim +25 -0
- data/app/views/cm_admin/main/associated_index.html.slim +6 -0
- data/app/views/cm_admin/main/associated_show.html.slim +6 -0
- data/app/views/cm_admin/main/dashboard.html.slim +1 -0
- data/app/views/cm_admin/main/edit.html.slim +19 -0
- data/app/views/cm_admin/main/index.html.slim +12 -0
- data/app/views/cm_admin/main/new.html.slim +22 -0
- data/app/views/cm_admin/main/show.html.slim +12 -0
- data/app/views/cm_admin/static/error_401.html.slim +4 -0
- data/app/views/layouts/_left_sidebar_nav.html.slim +34 -0
- data/app/views/layouts/_quick_links.html.slim +25 -0
- data/app/views/layouts/cm_admin.html.slim +41 -0
- data/app/views/layouts/static.html.slim +18 -0
- data/bin/webpack +18 -0
- data/bin/webpack-dev-server +18 -0
- data/cm_admin.gemspec +21 -31
- data/config/.DS_Store +0 -0
- data/config/initializers/active_record_extension.rb +9 -0
- data/config/routes.rb +19 -0
- data/config/webpack/development.js +5 -0
- data/config/webpack/environment.js +13 -0
- data/config/webpack/production.js +5 -0
- data/config/webpack/test.js +5 -0
- data/config/webpacker.yml +92 -0
- data/lib/cm_admin/constants.rb +33 -0
- data/lib/cm_admin/engine.rb +38 -0
- data/lib/cm_admin/model.rb +152 -0
- data/lib/cm_admin/models/action.rb +36 -0
- data/lib/cm_admin/models/actions/blocks.rb +25 -0
- data/lib/cm_admin/models/blocks.rb +19 -0
- data/lib/cm_admin/models/cm_show_section.rb +20 -0
- data/lib/cm_admin/models/column.rb +61 -0
- data/lib/cm_admin/models/controller_method.rb +75 -0
- data/lib/cm_admin/models/dsl_method.rb +122 -0
- data/lib/cm_admin/models/export.rb +54 -0
- data/lib/cm_admin/models/field.rb +15 -0
- data/lib/cm_admin/models/filter.rb +95 -0
- data/lib/cm_admin/models/form_field.rb +21 -0
- data/lib/cm_admin/models/tab.rb +13 -0
- data/lib/cm_admin/utils.rb +67 -0
- data/lib/cm_admin/version.rb +1 -1
- data/lib/cm_admin/view_helpers/column_field_helper.rb +29 -0
- data/lib/cm_admin/view_helpers/field_display_helper.rb +65 -0
- data/lib/cm_admin/view_helpers/filter_helper.rb +190 -0
- data/lib/cm_admin/view_helpers/form_field_helper.rb +33 -0
- data/lib/cm_admin/view_helpers/form_helper.rb +65 -0
- data/lib/cm_admin/view_helpers/manage_column_popup_helper.rb +75 -0
- data/lib/cm_admin/view_helpers/navigation_helper.rb +34 -0
- data/lib/cm_admin/view_helpers/page_info_helper.rb +57 -0
- data/lib/cm_admin/view_helpers.rb +74 -0
- data/lib/cm_admin.rb +33 -2
- data/lib/generators/cm_admin/install_generator.rb +11 -13
- data/lib/tasks/webpack_install.rake +63 -0
- data/package.json +23 -0
- data/postcss.config.js +12 -0
- data/tmp/cache/webpacker/last-compilation-digest-development +1 -0
- data/yarn.lock +6933 -0
- metadata +155 -42
- data/lib/generators/cm_admin/USAGE +0 -8
- data/lib/generators/cm_admin/templates/assets/images/same-logo.png +0 -0
- data/lib/generators/cm_admin/templates/assets/stylesheets/_variable.scss +0 -11
- data/lib/generators/cm_admin/templates/assets/stylesheets/alignment.scss +0 -111
- data/lib/generators/cm_admin/templates/assets/stylesheets/devise.scss +0 -98
- data/lib/generators/cm_admin/templates/assets/stylesheets/form.scss +0 -131
- data/lib/generators/cm_admin/templates/assets/stylesheets/products.scss +0 -21
- data/lib/generators/cm_admin/templates/assets/stylesheets/scaffold.scss +0 -241
- data/lib/generators/cm_admin/templates/assets/stylesheets/table.scss +0 -90
- data/lib/generators/cm_admin/templates/assets/stylesheets/user.scss +0 -25
- data/lib/generators/cm_admin/templates/layouts/_navbar.html.slim +0 -9
- data/lib/generators/cm_admin/templates/layouts/_side_navbar.html.slim +0 -16
- data/lib/generators/cm_admin/templates/layouts/application.html.slim +0 -25
- data/lib/generators/cm_admin/templates/layouts/initializer.rb +0 -2
- data/lib/generators/cm_admin/templates/views/_filters.html.slim +0 -0
- data/lib/generators/cm_admin/templates/views/_form.erb +0 -38
- data/lib/generators/cm_admin/templates/views/_table.erb +0 -14
- data/lib/generators/cm_admin/templates/views/index.erb +0 -11
- data/lib/generators/cm_admin/templates/views/show.erb +0 -8
- data/lib/generators/cm_admin/view_generator.rb +0 -57
@@ -0,0 +1,101 @@
|
|
1
|
+
@import "../helpers/index.scss";
|
2
|
+
|
3
|
+
.flag-alert {
|
4
|
+
max-width: 752px;
|
5
|
+
padding: 24px;
|
6
|
+
background: $red-lightest-clr;
|
7
|
+
border-radius: $radius-4;
|
8
|
+
.alert-header {
|
9
|
+
@include font($size: $t6-text, $color: $red-regular-clr, $weight: bold);
|
10
|
+
line-height: 16px;
|
11
|
+
text-transform: uppercase;
|
12
|
+
margin: 0;
|
13
|
+
span {
|
14
|
+
margin-right: 4px;
|
15
|
+
}
|
16
|
+
}
|
17
|
+
.alert-body {
|
18
|
+
margin-top: 16px;
|
19
|
+
.body-title {
|
20
|
+
@include font($size: $t3-text, $color: $primary-text-clr, $weight: bold);
|
21
|
+
line-height: 24px;
|
22
|
+
margin: 0 0 8px;
|
23
|
+
}
|
24
|
+
.body-info {
|
25
|
+
@include font($size: $t4-text, $color: $primary-text-clr);
|
26
|
+
line-height: 22px;
|
27
|
+
margin: 0;
|
28
|
+
}
|
29
|
+
.body-list-info {
|
30
|
+
padding-inline-start: 20px;
|
31
|
+
margin: 0;
|
32
|
+
li {
|
33
|
+
@include font($size: $t4-text, $color: $primary-text-clr);
|
34
|
+
line-height: 22px;
|
35
|
+
margin-bottom: 8px;
|
36
|
+
&:nth-last-child(1) {
|
37
|
+
margin-bottom: 0;
|
38
|
+
}
|
39
|
+
}
|
40
|
+
}
|
41
|
+
}
|
42
|
+
}
|
43
|
+
|
44
|
+
.toast-alert {
|
45
|
+
display: flex;
|
46
|
+
align-items: center;
|
47
|
+
max-width: 225px;
|
48
|
+
padding: 8px 16px;
|
49
|
+
border-radius: $radius-4;
|
50
|
+
&.informative {
|
51
|
+
background: $blue-light-clr;
|
52
|
+
}
|
53
|
+
&.successful {
|
54
|
+
background: $green-light-clr;
|
55
|
+
}
|
56
|
+
&.warning {
|
57
|
+
background: $yellow-light-clr;
|
58
|
+
}
|
59
|
+
&.error {
|
60
|
+
background: $red-light-clr;
|
61
|
+
}
|
62
|
+
.toast-info {
|
63
|
+
@include font($size: $t4-text, $color: $primary-text-clr);
|
64
|
+
line-height: 22px;
|
65
|
+
margin: 0;
|
66
|
+
}
|
67
|
+
.toast-close {
|
68
|
+
@include font($size: $t4-text, $color: $ink-lighter-clr);
|
69
|
+
margin-left: 24px;
|
70
|
+
cursor: pointer;
|
71
|
+
}
|
72
|
+
}
|
73
|
+
|
74
|
+
.inline-alert {
|
75
|
+
@include font($size: $t4-text, $color: $primary-text-clr);
|
76
|
+
line-height: 22px;
|
77
|
+
span {
|
78
|
+
margin-right: 4px;
|
79
|
+
}
|
80
|
+
&.informative {
|
81
|
+
span {
|
82
|
+
color: $blue-regular-clr;
|
83
|
+
}
|
84
|
+
}
|
85
|
+
&.successful {
|
86
|
+
span {
|
87
|
+
color: $green-regular-clr;
|
88
|
+
}
|
89
|
+
}
|
90
|
+
&.warning {
|
91
|
+
span {
|
92
|
+
color: $yellow-regular-clr;
|
93
|
+
}
|
94
|
+
}
|
95
|
+
&.error {
|
96
|
+
color: $red-regular-clr;
|
97
|
+
span {
|
98
|
+
color: $red-regular-clr;
|
99
|
+
}
|
100
|
+
}
|
101
|
+
}
|
@@ -0,0 +1,135 @@
|
|
1
|
+
@import '../helpers/index.scss';
|
2
|
+
|
3
|
+
.cta-btn {
|
4
|
+
padding: 8px 16px;
|
5
|
+
@include font($size: $t4-text, $color: $white, $weight: bold);
|
6
|
+
background-color: $brand-color;
|
7
|
+
border: none;
|
8
|
+
border-radius: $radius-4;
|
9
|
+
transition: all .2s linear;
|
10
|
+
&:hover {
|
11
|
+
background-color: #4D40AA;
|
12
|
+
}
|
13
|
+
&:focus {
|
14
|
+
outline: 3px auto rgba(47, 128, 237, 0.3);
|
15
|
+
outline-offset: 1px;
|
16
|
+
}
|
17
|
+
&.disabled {
|
18
|
+
color: $disabled-clr;
|
19
|
+
background: $grey-lighter-clr;
|
20
|
+
cursor: not-allowed !important;
|
21
|
+
&:hover {
|
22
|
+
background-color: $grey-lighter-clr;
|
23
|
+
}
|
24
|
+
}
|
25
|
+
}
|
26
|
+
|
27
|
+
.primary-btn {
|
28
|
+
padding: 8px 16px;
|
29
|
+
@include font($size: $t4-text, $color: $brand-color, $weight: bold);
|
30
|
+
background-color: $white;
|
31
|
+
border: 1px solid $brand-color;
|
32
|
+
border-radius: $radius-4;
|
33
|
+
transition: all .2s linear;
|
34
|
+
&:hover {
|
35
|
+
background-color: #E6E4FA;
|
36
|
+
}
|
37
|
+
&:focus {
|
38
|
+
outline: 3px auto rgba(47, 128, 237, 0.3);
|
39
|
+
outline-offset: 2px;
|
40
|
+
}
|
41
|
+
&.disabled {
|
42
|
+
color: $disabled-clr;
|
43
|
+
background: $white;
|
44
|
+
border: 1px solid $grey-regular-clr;
|
45
|
+
cursor: not-allowed !important;
|
46
|
+
&:hover {
|
47
|
+
background-color: $white;
|
48
|
+
}
|
49
|
+
}
|
50
|
+
}
|
51
|
+
|
52
|
+
.secondary-btn {
|
53
|
+
padding: 8px 16px;
|
54
|
+
@include font($size: $t4-text, $color: $primary-text-clr, $weight: bold);
|
55
|
+
background-color: $white;
|
56
|
+
border: 1px solid $ink-regular-clr;
|
57
|
+
border-radius: $radius-4;
|
58
|
+
transition: all .2s linear;
|
59
|
+
&:hover {
|
60
|
+
background-color: $grey-light-clr;
|
61
|
+
}
|
62
|
+
&:focus {
|
63
|
+
outline: 3px auto rgba(47, 128, 237, 0.3);
|
64
|
+
outline-offset: 2px;
|
65
|
+
}
|
66
|
+
&.disabled {
|
67
|
+
color: $disabled-clr;
|
68
|
+
background: $white;
|
69
|
+
border: 1px solid $grey-regular-clr;
|
70
|
+
cursor: not-allowed !important;
|
71
|
+
&:hover {
|
72
|
+
background-color: $white;
|
73
|
+
}
|
74
|
+
}
|
75
|
+
span:nth-child(2) {
|
76
|
+
margin: 0 4px 0 8px;
|
77
|
+
}
|
78
|
+
}
|
79
|
+
|
80
|
+
.gray-border-btn {
|
81
|
+
padding: 7px 16px;
|
82
|
+
@include font($size: $t4-text, $color: $primary-text-clr, $weight: bold);
|
83
|
+
background-color: $white;
|
84
|
+
border: 1px solid $ink-regular-clr;
|
85
|
+
border-radius: $radius-4;
|
86
|
+
transition: all .2s linear;
|
87
|
+
&:hover {
|
88
|
+
background-color: $grey-light-clr;
|
89
|
+
}
|
90
|
+
&:focus {
|
91
|
+
outline: 3px auto rgba(47, 128, 237, 0.3);
|
92
|
+
outline-offset: 2px;
|
93
|
+
}
|
94
|
+
&.disabled {
|
95
|
+
color: $disabled-clr;
|
96
|
+
background: $white;
|
97
|
+
border: 1px solid $grey-regular-clr;
|
98
|
+
cursor: not-allowed !important;
|
99
|
+
&:hover {
|
100
|
+
background-color: $white;
|
101
|
+
}
|
102
|
+
}
|
103
|
+
}
|
104
|
+
|
105
|
+
.ghost-btn {
|
106
|
+
padding: 8px 16px;
|
107
|
+
@include font($size: $t4-text, $color: $primary-text-clr, $weight: bold);
|
108
|
+
background-color: transparent;
|
109
|
+
border: none;
|
110
|
+
border-radius: $radius-4;
|
111
|
+
transition: all .2s linear;
|
112
|
+
&:hover {
|
113
|
+
background: $grey-light-clr;
|
114
|
+
}
|
115
|
+
&:focus {
|
116
|
+
outline: 3px auto rgba(47, 128, 237, 0.3);
|
117
|
+
}
|
118
|
+
&.disabled {
|
119
|
+
color: $disabled-clr;
|
120
|
+
background: $grey-light-clr;
|
121
|
+
border: none;
|
122
|
+
cursor: not-allowed !important;
|
123
|
+
&:hover {
|
124
|
+
background-color: $grey-light-clr;
|
125
|
+
}
|
126
|
+
}
|
127
|
+
}
|
128
|
+
|
129
|
+
.text-btn {
|
130
|
+
border: none;
|
131
|
+
background-color: transparent;
|
132
|
+
&:focus {
|
133
|
+
outline: none;
|
134
|
+
}
|
135
|
+
}
|
@@ -0,0 +1,153 @@
|
|
1
|
+
@import "../helpers/index.scss";
|
2
|
+
|
3
|
+
.dropdown-popup {
|
4
|
+
border: none !important;
|
5
|
+
.popup-base {
|
6
|
+
position: absolute;
|
7
|
+
min-width: 256px;
|
8
|
+
height: 56px;
|
9
|
+
padding: 8px;
|
10
|
+
background: $white;
|
11
|
+
border: 1px solid $grey-lighter-clr;
|
12
|
+
box-shadow: 0px 4px 16px rgba(0, 0, 0, 0.16);
|
13
|
+
border-radius: $radius-4;
|
14
|
+
}
|
15
|
+
.popup-inner {
|
16
|
+
position: relative;
|
17
|
+
min-width: 240px;
|
18
|
+
margin: 0 auto;
|
19
|
+
background-color: $white;
|
20
|
+
border: 1px solid #e0e0e0;
|
21
|
+
box-shadow: 0px 4px 16px rgba(0, 0, 0, 0.16);
|
22
|
+
border-radius: $radius-4;
|
23
|
+
.search-area {
|
24
|
+
input {
|
25
|
+
width: 100%;
|
26
|
+
min-height: 40px;
|
27
|
+
padding: 9px 16px;
|
28
|
+
font-size: $t4-text;
|
29
|
+
border: none;
|
30
|
+
border-radius: 4px 4px 0 0;
|
31
|
+
&::placeholder {
|
32
|
+
color: $ink-lightest-clr;
|
33
|
+
}
|
34
|
+
&:focus {
|
35
|
+
outline: none;
|
36
|
+
border: 1px solid $brand-color;
|
37
|
+
}
|
38
|
+
}
|
39
|
+
}
|
40
|
+
.search-with-chips {
|
41
|
+
display: flex;
|
42
|
+
flex-wrap: wrap;
|
43
|
+
padding: 8px 16px;
|
44
|
+
.chip {
|
45
|
+
display: inline-flex;
|
46
|
+
align-items: center;
|
47
|
+
margin: 2px;
|
48
|
+
padding: 0 4px;
|
49
|
+
background: $grey-lighter-clr;
|
50
|
+
border-radius: $radius-4;
|
51
|
+
span:nth-child(1) {
|
52
|
+
@include font($size: $t4-text, $color: $primary-text-clr);
|
53
|
+
line-height: 22px;
|
54
|
+
}
|
55
|
+
span:nth-child(2) {
|
56
|
+
@include font($size: 10px, $color: $ink-lightest-clr);
|
57
|
+
margin-left: 4px;
|
58
|
+
cursor: pointer;
|
59
|
+
}
|
60
|
+
}
|
61
|
+
input {
|
62
|
+
border: none;
|
63
|
+
font-size: $t4-text;
|
64
|
+
margin: 2px;
|
65
|
+
&:focus {
|
66
|
+
outline: 3px auto rgba(47, 128, 237, 0.3);
|
67
|
+
}
|
68
|
+
}
|
69
|
+
}
|
70
|
+
.list-area {
|
71
|
+
max-height: 240px;
|
72
|
+
overflow-y: auto;
|
73
|
+
border-top: 1px solid #e0e0e0;
|
74
|
+
.list-item {
|
75
|
+
display: flex;
|
76
|
+
align-items: center;
|
77
|
+
padding: 9px 16px;
|
78
|
+
@include font($size: $t4-text, $color: $primary-text-clr);
|
79
|
+
line-height: 22px;
|
80
|
+
label {
|
81
|
+
margin: 0 0 0 8px;
|
82
|
+
}
|
83
|
+
&:hover {
|
84
|
+
background: $grey-lighter-clr;
|
85
|
+
&:nth-last-child(1) {
|
86
|
+
border-radius: 0 0 4px 4px;
|
87
|
+
}
|
88
|
+
}
|
89
|
+
}
|
90
|
+
.selected {
|
91
|
+
color: $brand-color;
|
92
|
+
}
|
93
|
+
}
|
94
|
+
.apply-area {
|
95
|
+
@include font($size: $t4-text, $color: $ink-lightest-clr, $weight: 600);
|
96
|
+
line-height: 22px;
|
97
|
+
text-align: center;
|
98
|
+
padding: 9px 16px;
|
99
|
+
box-shadow: inset 0px 1px 0px rgba(148, 151, 155, 0.15);
|
100
|
+
cursor: not-allowed;
|
101
|
+
&.active {
|
102
|
+
cursor: pointer;
|
103
|
+
color: $blue-regular-clr;
|
104
|
+
}
|
105
|
+
}
|
106
|
+
}
|
107
|
+
}
|
108
|
+
|
109
|
+
.applied-select {
|
110
|
+
margin-left: 20rem;
|
111
|
+
}
|
112
|
+
|
113
|
+
.column-popup {
|
114
|
+
display: inline-block;
|
115
|
+
min-width: 156px;
|
116
|
+
max-height: 295px;
|
117
|
+
background-color: $white;
|
118
|
+
filter: drop-shadow(0px 4px 16px rgba(0, 0, 0, 0.16));
|
119
|
+
border-radius: $radius-4;
|
120
|
+
z-index: 1;
|
121
|
+
.column-option {
|
122
|
+
.option-title {
|
123
|
+
@include font($size: $t6-text, $color: $ink-lightest-clr, $weight: 600);
|
124
|
+
line-height: 16px;
|
125
|
+
text-transform: uppercase;
|
126
|
+
margin: 0;
|
127
|
+
padding: 18px 16px 9px;
|
128
|
+
}
|
129
|
+
.option-action {
|
130
|
+
padding: 9px 16px;
|
131
|
+
cursor: pointer;
|
132
|
+
@include transition-linear;
|
133
|
+
&:hover {
|
134
|
+
background-color: $grey-lighter-clr;
|
135
|
+
}
|
136
|
+
.action-icon {
|
137
|
+
font-size: $t4-text;
|
138
|
+
}
|
139
|
+
.action-name {
|
140
|
+
@include font($size: $t4-text, $color: $primary-text-clr);
|
141
|
+
line-height: 22px;
|
142
|
+
margin-left: 8px;
|
143
|
+
}
|
144
|
+
}
|
145
|
+
.cannot-sort {
|
146
|
+
font-size: $t6-text;
|
147
|
+
line-height: 16px;
|
148
|
+
color: $ink-lightest-clr;
|
149
|
+
margin-bottom: 9px;
|
150
|
+
padding: 0 16px;
|
151
|
+
}
|
152
|
+
}
|
153
|
+
}
|
@@ -0,0 +1,274 @@
|
|
1
|
+
@import "../helpers/index.scss";
|
2
|
+
|
3
|
+
.form-field {
|
4
|
+
.field-label-wrapper {
|
5
|
+
.field-label {
|
6
|
+
@include font($size: $t4-text, $color: $primary-text-clr);
|
7
|
+
line-height: 22px;
|
8
|
+
margin: 0 0 4px;
|
9
|
+
span {
|
10
|
+
color: $ink-lightest-clr;
|
11
|
+
margin-left: 4px;
|
12
|
+
}
|
13
|
+
}
|
14
|
+
.field-helper-text {
|
15
|
+
@include font($size: $t4-text, $color: $ink-lighter-clr);
|
16
|
+
line-height: 22px;
|
17
|
+
margin: 0 0 4px;
|
18
|
+
}
|
19
|
+
}
|
20
|
+
.field-input-wrapper {
|
21
|
+
position: relative;
|
22
|
+
.error-msg {
|
23
|
+
@include font($size: $t4-text, $color: $error-clr);
|
24
|
+
line-height: 22px;
|
25
|
+
margin: 4px 0 0;
|
26
|
+
animation: shakeError 0.5s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
|
27
|
+
transform: translate3d(0, 0, 0);
|
28
|
+
backface-visibility: hidden;
|
29
|
+
perspective: 1000px;
|
30
|
+
span {
|
31
|
+
margin-right: 4px;
|
32
|
+
}
|
33
|
+
}
|
34
|
+
}
|
35
|
+
}
|
36
|
+
|
37
|
+
//Search input styles
|
38
|
+
.search-input {
|
39
|
+
position: relative;
|
40
|
+
width: 100%;
|
41
|
+
padding: 8px 0 8px 40px;
|
42
|
+
@include font($size: $t4-text, $color: $primary-text-clr);
|
43
|
+
line-height: 22px;
|
44
|
+
background-color: $white;
|
45
|
+
border: 1px solid $grey-light-clr;
|
46
|
+
border-radius: $radius-4;
|
47
|
+
&::placeholder {
|
48
|
+
color: $ink-lightest-clr;
|
49
|
+
}
|
50
|
+
&:focus {
|
51
|
+
outline: 3px auto rgba(47, 128, 237, 0.3);
|
52
|
+
}
|
53
|
+
}
|
54
|
+
.search-input-icon {
|
55
|
+
position: absolute;
|
56
|
+
top: 8px;
|
57
|
+
left: 16px;
|
58
|
+
@include font($size: $t4-text, $color: $ink-lightest-clr);
|
59
|
+
}
|
60
|
+
|
61
|
+
//Normal input styles
|
62
|
+
.normal-input {
|
63
|
+
width: 100%;
|
64
|
+
padding: 8px 16px;
|
65
|
+
@include font($size: $t4-text, $color: $primary-text-clr);
|
66
|
+
line-height: 22px;
|
67
|
+
background-color: $white;
|
68
|
+
border: 1px solid $grey-light-clr;
|
69
|
+
border-radius: $radius-4;
|
70
|
+
&::placeholder {
|
71
|
+
color: $ink-lightest-clr;
|
72
|
+
}
|
73
|
+
&:focus {
|
74
|
+
outline: 3px auto rgba(47, 128, 237, 0.3);
|
75
|
+
}
|
76
|
+
&.error {
|
77
|
+
border: 1px solid $error-clr;
|
78
|
+
&:focus {
|
79
|
+
outline: 3px auto rgba(248, 54, 54, 0.3);
|
80
|
+
}
|
81
|
+
}
|
82
|
+
}
|
83
|
+
|
84
|
+
.file-upload-wrapper {
|
85
|
+
display: inline-flex;
|
86
|
+
align-items: center;
|
87
|
+
.file-upload-input {
|
88
|
+
position: relative;
|
89
|
+
display: flex;
|
90
|
+
justify-content: center;
|
91
|
+
align-items: center;
|
92
|
+
padding: 5px 16px;
|
93
|
+
border: 1px solid $primary-text-clr;
|
94
|
+
border-radius: $radius-4;
|
95
|
+
cursor: pointer;
|
96
|
+
input[type="file"] {
|
97
|
+
position: absolute;
|
98
|
+
top: 0;
|
99
|
+
right: 0;
|
100
|
+
bottom: 0;
|
101
|
+
left: 0;
|
102
|
+
width: 100%;
|
103
|
+
height: 100%;
|
104
|
+
opacity: 0;
|
105
|
+
cursor: pointer;
|
106
|
+
&::-webkit-file-upload-button {
|
107
|
+
cursor: pointer;
|
108
|
+
}
|
109
|
+
}
|
110
|
+
|
111
|
+
.upload-placeholder-1 {
|
112
|
+
@include font($size: $t4-text, $color: $ink-lighter-clr, $weight: 600);
|
113
|
+
}
|
114
|
+
.upload-placeholder-2 {
|
115
|
+
@include font($size: $t4-text, $color: $primary-text-clr, $weight: 600);
|
116
|
+
margin-left: 4px;
|
117
|
+
}
|
118
|
+
}
|
119
|
+
.file-name {
|
120
|
+
@include font($size: $t4-text, $color: $primary-text-clr);
|
121
|
+
margin: 0 0 0 8px;
|
122
|
+
}
|
123
|
+
}
|
124
|
+
|
125
|
+
//checkbox-style
|
126
|
+
input.cm-checkbox[type="checkbox"] {
|
127
|
+
position: relative;
|
128
|
+
// display: block;
|
129
|
+
display: inline-block;
|
130
|
+
width: 16px;
|
131
|
+
height: 16px;
|
132
|
+
// float: left;
|
133
|
+
-webkit-font-smoothing: antialiased;
|
134
|
+
text-rendering: optimizeSpeed;
|
135
|
+
&:hover::after {
|
136
|
+
background: $grey-lighter-clr;
|
137
|
+
}
|
138
|
+
&:after {
|
139
|
+
content: "";
|
140
|
+
vertical-align: middle;
|
141
|
+
text-align: center;
|
142
|
+
position: absolute;
|
143
|
+
height: 16px;
|
144
|
+
width: 16px;
|
145
|
+
font-size: 11px;
|
146
|
+
line-height: 17px;
|
147
|
+
background: $white;
|
148
|
+
border: 1.5px solid $grey-regular-clr;
|
149
|
+
border-radius: $radius-2;
|
150
|
+
cursor: pointer;
|
151
|
+
}
|
152
|
+
&:checked:after {
|
153
|
+
background: $brand-color;
|
154
|
+
content: "\f00c";
|
155
|
+
font-family: FontAwesome !important;
|
156
|
+
color: $white;
|
157
|
+
border: none;
|
158
|
+
}
|
159
|
+
&.disabled {
|
160
|
+
&:hover::after {
|
161
|
+
background: transparent;
|
162
|
+
cursor: not-allowed;
|
163
|
+
}
|
164
|
+
&:checked:after {
|
165
|
+
background: $grey-light-clr;
|
166
|
+
content: "\f00c";
|
167
|
+
font-family: FontAwesome !important;
|
168
|
+
color: $white;
|
169
|
+
border: none;
|
170
|
+
}
|
171
|
+
}
|
172
|
+
}
|
173
|
+
|
174
|
+
//Radio button styles
|
175
|
+
input.cm-radio[type="radio"] {
|
176
|
+
position: relative;
|
177
|
+
display: inline-block;
|
178
|
+
width: 16px;
|
179
|
+
height: 14px;
|
180
|
+
-webkit-font-smoothing: antialiased;
|
181
|
+
text-rendering: optimizeSpeed;
|
182
|
+
&:focus {
|
183
|
+
outline: none;
|
184
|
+
}
|
185
|
+
&:hover::after {
|
186
|
+
background: $grey-lighter-clr;
|
187
|
+
}
|
188
|
+
&:after {
|
189
|
+
content: "";
|
190
|
+
vertical-align: middle;
|
191
|
+
text-align: center;
|
192
|
+
position: absolute;
|
193
|
+
height: 16px;
|
194
|
+
width: 16px;
|
195
|
+
background-color: $white;
|
196
|
+
border: 1.5px solid $grey-regular-clr;
|
197
|
+
border-radius: $circle;
|
198
|
+
cursor: pointer;
|
199
|
+
}
|
200
|
+
&:checked:after {
|
201
|
+
background: $brand-color;
|
202
|
+
content: "\25CF";
|
203
|
+
color: $white;
|
204
|
+
font-size: 9px;
|
205
|
+
line-height: 16px;
|
206
|
+
border: none;
|
207
|
+
}
|
208
|
+
&.disabled {
|
209
|
+
&:hover::after {
|
210
|
+
background: transparent;
|
211
|
+
cursor: not-allowed;
|
212
|
+
}
|
213
|
+
&:checked:after {
|
214
|
+
background: $grey-light-clr;
|
215
|
+
content: "\25CF";
|
216
|
+
color: $white;
|
217
|
+
font-size: 9px;
|
218
|
+
line-height: 16px;
|
219
|
+
border: none;
|
220
|
+
}
|
221
|
+
}
|
222
|
+
}
|
223
|
+
|
224
|
+
//Switch styles
|
225
|
+
.cm-switch {
|
226
|
+
position: relative;
|
227
|
+
display: inline-block;
|
228
|
+
width: 36px;
|
229
|
+
height: 22px;
|
230
|
+
|
231
|
+
input {
|
232
|
+
display: none;
|
233
|
+
}
|
234
|
+
|
235
|
+
.slider {
|
236
|
+
position: absolute;
|
237
|
+
cursor: pointer;
|
238
|
+
top: 0;
|
239
|
+
left: 0;
|
240
|
+
right: 0;
|
241
|
+
bottom: 0;
|
242
|
+
background: $grey-light-clr;
|
243
|
+
transition: all .2s linear;
|
244
|
+
}
|
245
|
+
|
246
|
+
.slider:before {
|
247
|
+
position: absolute;
|
248
|
+
content: "";
|
249
|
+
width: 18px;
|
250
|
+
height: 18px;
|
251
|
+
left: 2px;
|
252
|
+
bottom: 2px;
|
253
|
+
background-color: $white;
|
254
|
+
transition: all .2s linear;
|
255
|
+
}
|
256
|
+
|
257
|
+
input:checked + .slider {
|
258
|
+
background: $brand-color;
|
259
|
+
}
|
260
|
+
|
261
|
+
input:checked + .slider:before {
|
262
|
+
-webkit-transform: translateX(14px);
|
263
|
+
-ms-transform: translateX(14px);
|
264
|
+
transform: translateX(14px);
|
265
|
+
}
|
266
|
+
|
267
|
+
.slider.round {
|
268
|
+
border-radius: 12px;
|
269
|
+
}
|
270
|
+
|
271
|
+
.slider.round:before {
|
272
|
+
border-radius: $circle;
|
273
|
+
}
|
274
|
+
}
|
@@ -0,0 +1,34 @@
|
|
1
|
+
@import "../helpers/index.scss";
|
2
|
+
|
3
|
+
// Confirm modal styles
|
4
|
+
.confirm-modal {
|
5
|
+
.modal-dialog {
|
6
|
+
max-width: 520px;
|
7
|
+
.modal-content {
|
8
|
+
padding: 32px 32px 16px;
|
9
|
+
box-shadow: 0px 4px 16px rgba(0, 0, 0, 0.16);
|
10
|
+
border: none;
|
11
|
+
.modal-header {
|
12
|
+
margin: 0 0 24px;
|
13
|
+
padding: 0;
|
14
|
+
border: none;
|
15
|
+
.modal-title {
|
16
|
+
@include font($size: 24px, $color: $primary-text-clr, $weight: 600);
|
17
|
+
line-height: 32px;
|
18
|
+
}
|
19
|
+
}
|
20
|
+
.modal-body {
|
21
|
+
padding: 0 0 16px;
|
22
|
+
.body-content {
|
23
|
+
@include font($size: $t4-text, $color: #0D102B);
|
24
|
+
line-height: 22px;
|
25
|
+
margin: 0;
|
26
|
+
}
|
27
|
+
}
|
28
|
+
.modal-footer {
|
29
|
+
padding: 16px 0 0;
|
30
|
+
border: none;
|
31
|
+
}
|
32
|
+
}
|
33
|
+
}
|
34
|
+
}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
@import "../helpers/index.scss";
|
2
|
+
|
3
|
+
.range-container {
|
4
|
+
display: flex;
|
5
|
+
width: 424px;
|
6
|
+
height: 54px;
|
7
|
+
padding: 8px;
|
8
|
+
background: $white;
|
9
|
+
border: 1px solid $grey-lighter-clr;
|
10
|
+
box-shadow: 0px 4px 16px rgba(0, 0, 0, 0.16);
|
11
|
+
border-radius: $radius-4;
|
12
|
+
.range-item {
|
13
|
+
width: 200px;
|
14
|
+
border: 1px solid $grey-light-clr;
|
15
|
+
border-radius: $radius-4;
|
16
|
+
padding: 8px 0 8px 16px;
|
17
|
+
&:nth-child(1) {
|
18
|
+
margin-right: 4px;
|
19
|
+
}
|
20
|
+
&:nth-child(2) {
|
21
|
+
margin-left: 4px;
|
22
|
+
}
|
23
|
+
&:hover {
|
24
|
+
border: 1px solid $grey-dark-clr;
|
25
|
+
}
|
26
|
+
&:focus {
|
27
|
+
outline: none;
|
28
|
+
border: 1px solid $brand-color;
|
29
|
+
}
|
30
|
+
}
|
31
|
+
}
|