cm-admin 0.2.0 → 0.4.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 (132) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +12 -0
  3. data/.rspec +3 -0
  4. data/.travis.yml +6 -0
  5. data/Gemfile +7 -1
  6. data/Gemfile.lock +121 -0
  7. data/LICENSE.txt +21 -0
  8. data/README.md +8 -19
  9. data/app/assets/images/logo.png +0 -0
  10. data/{lib/generators/cm_admin/templates/assets/stylesheets → app/assets/stylesheets/cm_admin}/base/auth.scss +4 -6
  11. data/app/assets/stylesheets/cm_admin/base/common.scss +237 -0
  12. data/app/assets/stylesheets/cm_admin/base/filters.scss +200 -0
  13. data/{lib/generators/cm_admin/templates/assets/stylesheets → app/assets/stylesheets/cm_admin}/base/form.scss +83 -11
  14. data/app/assets/stylesheets/cm_admin/base/main-nav.scss +47 -0
  15. data/app/assets/stylesheets/cm_admin/base/navbar.scss +65 -0
  16. data/app/assets/stylesheets/cm_admin/base/quicksearch.scss +76 -0
  17. data/app/assets/stylesheets/cm_admin/base/scaffold.scss +96 -0
  18. data/app/assets/stylesheets/cm_admin/base/show.scss +76 -0
  19. data/app/assets/stylesheets/cm_admin/base/sidebar.scss +225 -0
  20. data/app/assets/stylesheets/cm_admin/base/table.scss +320 -0
  21. data/app/assets/stylesheets/cm_admin/base/tabs.scss +26 -0
  22. data/app/assets/stylesheets/cm_admin/cm_admin.css.scss +26 -0
  23. data/app/assets/stylesheets/cm_admin/components/_alerts.scss +101 -0
  24. data/app/assets/stylesheets/cm_admin/components/_buttons.scss +135 -0
  25. data/app/assets/stylesheets/cm_admin/components/_dropdown-popup.scss +153 -0
  26. data/app/assets/stylesheets/cm_admin/components/_input.scss +274 -0
  27. data/app/assets/stylesheets/cm_admin/components/_modal.scss +34 -0
  28. data/app/assets/stylesheets/cm_admin/components/_range.scss +31 -0
  29. data/app/assets/stylesheets/cm_admin/components/_status-tag.scss +68 -0
  30. data/app/assets/stylesheets/cm_admin/components/index.scss +7 -0
  31. data/app/assets/stylesheets/cm_admin/dependency/bootstrap.min.css +7 -0
  32. data/app/assets/stylesheets/cm_admin/helpers/_mixins.scss +20 -0
  33. data/app/assets/stylesheets/cm_admin/helpers/_variable.scss +87 -0
  34. data/app/assets/stylesheets/cm_admin/helpers/index.scss +2 -0
  35. data/app/controllers/cm_admin/application_controller.rb +11 -0
  36. data/app/controllers/cm_admin/exports_controller.rb +16 -0
  37. data/app/controllers/cm_admin/static_controller.rb +12 -0
  38. data/app/helpers/cm_admin/application_helper.rb +11 -0
  39. data/app/helpers/cm_admin/custom_helper.rb +4 -0
  40. data/app/javascript/packs/cm_admin/application.js +22 -0
  41. data/app/javascript/packs/cm_admin/filters.js +347 -0
  42. data/app/javascript/packs/cm_admin/quick_search.js +67 -0
  43. data/app/javascript/packs/cm_admin/scaffolds.js +43 -0
  44. data/app/javascript/stylesheets/cm_admin/application.scss +3 -0
  45. data/app/views/cm_admin/main/_associated_table.html.slim +60 -0
  46. data/app/views/cm_admin/main/_cm_pagy_nav.html.slim +23 -0
  47. data/app/views/cm_admin/main/_filters.html.slim +1 -0
  48. data/app/views/cm_admin/main/_nested_fields.html.slim +7 -0
  49. data/app/views/cm_admin/main/_nested_table_form.html.slim +6 -0
  50. data/app/views/cm_admin/main/_table.html.slim +60 -0
  51. data/app/views/cm_admin/main/_tabs.html.slim +5 -0
  52. data/app/views/cm_admin/main/_top_navbar.html.slim +25 -0
  53. data/app/views/cm_admin/main/associated_index.html.slim +6 -0
  54. data/app/views/cm_admin/main/associated_show.html.slim +6 -0
  55. data/app/views/cm_admin/main/dashboard.html.slim +1 -0
  56. data/app/views/cm_admin/main/edit.html.slim +19 -0
  57. data/app/views/cm_admin/main/index.html.slim +12 -0
  58. data/app/views/cm_admin/main/new.html.slim +22 -0
  59. data/app/views/cm_admin/main/show.html.slim +12 -0
  60. data/app/views/cm_admin/static/error_401.html.slim +4 -0
  61. data/app/views/layouts/_left_sidebar_nav.html.slim +34 -0
  62. data/app/views/layouts/_quick_links.html.slim +25 -0
  63. data/app/views/layouts/cm_admin.html.slim +41 -0
  64. data/app/views/layouts/static.html.slim +18 -0
  65. data/bin/webpack +18 -0
  66. data/bin/webpack-dev-server +18 -0
  67. data/cm_admin.gemspec +21 -31
  68. data/config/.DS_Store +0 -0
  69. data/config/initializers/active_record_extension.rb +9 -0
  70. data/config/routes.rb +19 -0
  71. data/config/webpack/development.js +5 -0
  72. data/config/webpack/environment.js +13 -0
  73. data/config/webpack/production.js +5 -0
  74. data/config/webpack/test.js +5 -0
  75. data/config/webpacker.yml +92 -0
  76. data/lib/cm_admin/constants.rb +33 -0
  77. data/lib/cm_admin/engine.rb +38 -0
  78. data/lib/cm_admin/model.rb +152 -0
  79. data/lib/cm_admin/models/action.rb +36 -0
  80. data/lib/cm_admin/models/actions/blocks.rb +25 -0
  81. data/lib/cm_admin/models/blocks.rb +19 -0
  82. data/lib/cm_admin/models/cm_show_section.rb +20 -0
  83. data/lib/cm_admin/models/column.rb +61 -0
  84. data/lib/cm_admin/models/controller_method.rb +75 -0
  85. data/lib/cm_admin/models/dsl_method.rb +122 -0
  86. data/lib/cm_admin/models/export.rb +54 -0
  87. data/lib/cm_admin/models/field.rb +15 -0
  88. data/lib/cm_admin/models/filter.rb +95 -0
  89. data/lib/cm_admin/models/form_field.rb +21 -0
  90. data/lib/cm_admin/models/tab.rb +13 -0
  91. data/lib/cm_admin/utils.rb +67 -0
  92. data/lib/cm_admin/version.rb +1 -1
  93. data/lib/cm_admin/view_helpers/column_field_helper.rb +29 -0
  94. data/lib/cm_admin/view_helpers/field_display_helper.rb +65 -0
  95. data/lib/cm_admin/view_helpers/filter_helper.rb +190 -0
  96. data/lib/cm_admin/view_helpers/form_field_helper.rb +33 -0
  97. data/lib/cm_admin/view_helpers/form_helper.rb +65 -0
  98. data/lib/cm_admin/view_helpers/manage_column_popup_helper.rb +75 -0
  99. data/lib/cm_admin/view_helpers/navigation_helper.rb +34 -0
  100. data/lib/cm_admin/view_helpers/page_info_helper.rb +57 -0
  101. data/lib/cm_admin/view_helpers.rb +74 -0
  102. data/lib/cm_admin.rb +33 -2
  103. data/lib/generators/cm_admin/install_generator.rb +3 -13
  104. data/lib/tasks/webpack_install.rake +63 -0
  105. data/package.json +23 -0
  106. data/postcss.config.js +12 -0
  107. data/tmp/cache/webpacker/last-compilation-digest-development +1 -0
  108. data/yarn.lock +6933 -0
  109. metadata +155 -46
  110. data/lib/generators/cm_admin/USAGE +0 -8
  111. data/lib/generators/cm_admin/templates/assets/images/cm.png +0 -0
  112. data/lib/generators/cm_admin/templates/assets/stylesheets/application.css.scss +0 -33
  113. data/lib/generators/cm_admin/templates/assets/stylesheets/base/_variable.scss +0 -14
  114. data/lib/generators/cm_admin/templates/assets/stylesheets/base/input-styles.scss +0 -72
  115. data/lib/generators/cm_admin/templates/assets/stylesheets/base/main-nav.scss +0 -79
  116. data/lib/generators/cm_admin/templates/assets/stylesheets/base/scaffold.scss +0 -95
  117. data/lib/generators/cm_admin/templates/assets/stylesheets/base/show.scss +0 -88
  118. data/lib/generators/cm_admin/templates/assets/stylesheets/base/sidebar.scss +0 -69
  119. data/lib/generators/cm_admin/templates/assets/stylesheets/base/table.scss +0 -246
  120. data/lib/generators/cm_admin/templates/layouts/_navbar.html.slim +0 -8
  121. data/lib/generators/cm_admin/templates/layouts/_side_navbar.html.slim +0 -12
  122. data/lib/generators/cm_admin/templates/layouts/application.html.slim +0 -20
  123. data/lib/generators/cm_admin/templates/layouts/initializer.rb +0 -2
  124. data/lib/generators/cm_admin/templates/views/_form.erb +0 -67
  125. data/lib/generators/cm_admin/templates/views/_table.erb +0 -22
  126. data/lib/generators/cm_admin/templates/views/edit.erb +0 -10
  127. data/lib/generators/cm_admin/templates/views/index.erb +0 -11
  128. data/lib/generators/cm_admin/templates/views/new.erb +0 -10
  129. data/lib/generators/cm_admin/templates/views/reset_password.erb +0 -12
  130. data/lib/generators/cm_admin/templates/views/show.erb +0 -18
  131. data/lib/generators/cm_admin/templates/views/sign_in.erb +0 -18
  132. data/lib/generators/cm_admin/view_generator.rb +0 -78
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 208e7113a6556a94cdba5289db7d672f6ba3443189c49789fc4f3c95d6a14dc2
4
- data.tar.gz: b9201bb6da693871e2a3708bb8ac76ba352ee68b92c58413bd17038225b39ca9
3
+ metadata.gz: 7d3c3ae7aac9de6be7c89c6f074c9b2634e1091e89328daa100281aac6fd868b
4
+ data.tar.gz: 62c6e179d26f54873a1fca654b29c4721e1e4c2e455d0b268c8f75a93776af59
5
5
  SHA512:
6
- metadata.gz: 8b6937bc74d0aebd0220271d096b914e70183af91fa5ec2908d3d16b32afebb97d5a1fad1f049d2234f308b27e9a843a1b4a5df649290897c20dc4635217d870
7
- data.tar.gz: 65146543054360dec133299268ae94e8579403d4a962c031835d449199dd7009271b85c31d59c8b46a42507e1ed41ad85d19dae953135789a9f10f5a488f5e28
6
+ metadata.gz: 06fb9aa911f2ed904725fa3c8d653e7468b9e800f0bf3c26843c3b275b16ba691587e8e6d62dcf01a5797cdc5360d0c65f538e08aa61d3bfdad63a184200d425
7
+ data.tar.gz: a2a35fbcc0cd41aa3db83296ddc307668561bb963c5e1caab6649c01b9d478edaf74f17c7f2e9791a94821acffb46d17caaf7d1f777a1f96c99b4cf884db9933
data/.gitignore ADDED
@@ -0,0 +1,12 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /_yardoc/
4
+ /coverage/
5
+ /doc/
6
+ /pkg/
7
+ /spec/reports/
8
+ /tmp/
9
+ node_modules/
10
+ public/cm-admin-packs/
11
+ # rspec failure tracking
12
+ .rspec_status
data/.rspec ADDED
@@ -0,0 +1,3 @@
1
+ --format documentation
2
+ --color
3
+ --require spec_helper
data/.travis.yml ADDED
@@ -0,0 +1,6 @@
1
+ ---
2
+ language: ruby
3
+ cache: bundler
4
+ rvm:
5
+ - 2.7.2
6
+ before_install: gem install bundler -v 2.1.4
data/Gemfile CHANGED
@@ -1,4 +1,10 @@
1
1
  source "https://rubygems.org"
2
2
 
3
- # Specify your gem's dependencies in cm_coupon.gemspec
3
+ gem 'pagy', '~> 4.11.0'
4
+ gem 'slim'
5
+ gem "rake", "~> 12.0"
6
+ gem "rspec", "~> 3.0"
7
+ gem 'cocoon'
8
+
9
+ # Specify your gem's dependencies in cm_admin.gemspec
4
10
  gemspec
data/Gemfile.lock ADDED
@@ -0,0 +1,121 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ cm-admin (0.3.0)
5
+ axlsx_rails (~> 0.6.1)
6
+ cocoon (~> 1.2.15)
7
+ pagy (~> 4.11.0)
8
+ slim (~> 4.1.0)
9
+ webpacker (~> 5.2.1)
10
+
11
+ GEM
12
+ remote: https://rubygems.org/
13
+ specs:
14
+ actionpack (6.1.4.1)
15
+ actionview (= 6.1.4.1)
16
+ activesupport (= 6.1.4.1)
17
+ rack (~> 2.0, >= 2.0.9)
18
+ rack-test (>= 0.6.3)
19
+ rails-dom-testing (~> 2.0)
20
+ rails-html-sanitizer (~> 1.0, >= 1.2.0)
21
+ actionview (6.1.4.1)
22
+ activesupport (= 6.1.4.1)
23
+ builder (~> 3.1)
24
+ erubi (~> 1.4)
25
+ rails-dom-testing (~> 2.0)
26
+ rails-html-sanitizer (~> 1.1, >= 1.2.0)
27
+ activesupport (6.1.4.1)
28
+ concurrent-ruby (~> 1.0, >= 1.0.2)
29
+ i18n (>= 1.6, < 2)
30
+ minitest (>= 5.1)
31
+ tzinfo (~> 2.0)
32
+ zeitwerk (~> 2.3)
33
+ axlsx_rails (0.6.1)
34
+ actionpack (>= 3.1)
35
+ caxlsx (>= 3.0)
36
+ builder (3.2.4)
37
+ caxlsx (3.1.1)
38
+ htmlentities (~> 4.3, >= 4.3.4)
39
+ marcel (~> 1.0)
40
+ nokogiri (~> 1.10, >= 1.10.4)
41
+ rubyzip (>= 1.3.0, < 3)
42
+ cocoon (1.2.15)
43
+ concurrent-ruby (1.1.9)
44
+ crass (1.0.6)
45
+ diff-lcs (1.4.4)
46
+ erubi (1.10.0)
47
+ htmlentities (4.3.4)
48
+ i18n (1.8.10)
49
+ concurrent-ruby (~> 1.0)
50
+ loofah (2.12.0)
51
+ crass (~> 1.0.2)
52
+ nokogiri (>= 1.5.9)
53
+ marcel (1.0.2)
54
+ method_source (1.0.0)
55
+ mini_portile2 (2.6.1)
56
+ minitest (5.14.4)
57
+ nokogiri (1.12.5)
58
+ mini_portile2 (~> 2.6.1)
59
+ racc (~> 1.4)
60
+ pagy (4.11.0)
61
+ racc (1.5.2)
62
+ rack (2.2.3)
63
+ rack-proxy (0.7.0)
64
+ rack
65
+ rack-test (1.1.0)
66
+ rack (>= 1.0, < 3)
67
+ rails-dom-testing (2.0.3)
68
+ activesupport (>= 4.2.0)
69
+ nokogiri (>= 1.6)
70
+ rails-html-sanitizer (1.4.2)
71
+ loofah (~> 2.3)
72
+ railties (6.1.4.1)
73
+ actionpack (= 6.1.4.1)
74
+ activesupport (= 6.1.4.1)
75
+ method_source
76
+ rake (>= 0.13)
77
+ thor (~> 1.0)
78
+ rake (12.3.3)
79
+ rspec (3.10.0)
80
+ rspec-core (~> 3.10.0)
81
+ rspec-expectations (~> 3.10.0)
82
+ rspec-mocks (~> 3.10.0)
83
+ rspec-core (3.10.1)
84
+ rspec-support (~> 3.10.0)
85
+ rspec-expectations (3.10.1)
86
+ diff-lcs (>= 1.2.0, < 2.0)
87
+ rspec-support (~> 3.10.0)
88
+ rspec-mocks (3.10.2)
89
+ diff-lcs (>= 1.2.0, < 2.0)
90
+ rspec-support (~> 3.10.0)
91
+ rspec-support (3.10.2)
92
+ rubyzip (2.3.2)
93
+ semantic_range (3.0.0)
94
+ slim (4.1.0)
95
+ temple (>= 0.7.6, < 0.9)
96
+ tilt (>= 2.0.6, < 2.1)
97
+ temple (0.8.2)
98
+ thor (1.1.0)
99
+ tilt (2.0.10)
100
+ tzinfo (2.0.4)
101
+ concurrent-ruby (~> 1.0)
102
+ webpacker (5.2.2)
103
+ activesupport (>= 5.2)
104
+ rack-proxy (>= 0.6.1)
105
+ railties (>= 5.2)
106
+ semantic_range (>= 2.3.0)
107
+ zeitwerk (2.4.2)
108
+
109
+ PLATFORMS
110
+ ruby
111
+
112
+ DEPENDENCIES
113
+ cm-admin!
114
+ cocoon
115
+ pagy (~> 4.11.0)
116
+ rake (~> 12.0)
117
+ rspec (~> 3.0)
118
+ slim
119
+
120
+ BUNDLED WITH
121
+ 2.0.2
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2021 sajinmp
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md CHANGED
@@ -1,12 +1,6 @@
1
1
  # CmAdmin
2
2
 
3
- Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/cm_admin`. To experiment with that code, run `bin/console` for an interactive prompt.
4
-
5
- First create a new rails project with the following command. If you are adding to existing project skip this
6
-
7
- ```
8
- rails new blog -m https://raw.githubusercontent.com/commutatus/cm-rails-template/devise_integration/template.rb
9
- ```
3
+ New CmAdmin gem
10
4
 
11
5
  ## Installation
12
6
 
@@ -18,20 +12,15 @@ gem 'cm_admin'
18
12
 
19
13
  And then execute:
20
14
 
21
- $ bundle
15
+ $ bundle install
22
16
 
23
17
  Or install it yourself as:
24
18
 
25
19
  $ gem install cm_admin
26
20
 
27
- Assuming we have a model created already or we can create one
28
-
29
- $ rails g user first_name:string last_name:string
30
-
31
-
32
21
  ## Usage
33
22
 
34
- For copying layout such as CSS and the layout files
23
+ Install the gem
35
24
 
36
25
  $ rails g cm_admin:install
37
26
 
@@ -56,6 +45,9 @@ Following field types are acceted
56
45
  * checkbox
57
46
  * radio
58
47
 
48
+ ## Usage
49
+
50
+ For demo check [here](http://cm-admin.labs.commutatus.com/admin/users/)
59
51
 
60
52
  ## Development
61
53
 
@@ -65,12 +57,9 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
65
57
 
66
58
  ## Contributing
67
59
 
68
- Bug reports and pull requests are welcome on GitHub at https://github.com/commutatus/cm-admin. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
60
+ Bug reports and pull requests are welcome on [GitHub](https://github.com/commutatus/cm-admin).
61
+
69
62
 
70
63
  ## License
71
64
 
72
65
  The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
73
-
74
- ## Code of Conduct
75
-
76
- Everyone interacting in the CmAdmin project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/cm-admin/blob/master/CODE_OF_CONDUCT.md).
Binary file
@@ -1,4 +1,4 @@
1
- @import "_variable.scss";
1
+ @import '../helpers/index.scss';
2
2
 
3
3
  .auth {
4
4
  display: flex;
@@ -48,8 +48,7 @@
48
48
  margin-bottom: 8px;
49
49
  text-align: right;
50
50
  a {
51
- color: #20b5ff;
52
- font-size: 14px;
51
+ @include font($size: $t4-text, $color: $brand-color);
53
52
  }
54
53
  }
55
54
 
@@ -58,11 +57,10 @@
58
57
  width: 100%;
59
58
  height: 39px;
60
59
  padding: 6px 12px;
61
- font-size: 16px;
62
- color: #555555;
60
+ @include font($size: $t3-text, $color: #555555);
63
61
  background-color: $white;
64
62
  border: 1px solid #ccc;
65
- border-radius: 2px;
63
+ border-radius: $radius-2;
66
64
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
67
65
  transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
68
66
  &:focus {
@@ -0,0 +1,237 @@
1
+ @import "../helpers/index.scss";
2
+
3
+ @function size($size) {
4
+ @return map-get($font-size, $size);
5
+ }
6
+
7
+ @function weight($weight) {
8
+ @return map-get($font-weight, $weight);
9
+ }
10
+
11
+ /* common popup styles */
12
+ .popup-card {
13
+ position: absolute;
14
+ background-color: $white;
15
+ filter: drop-shadow(0px 4px 16px rgba(0, 0, 0, 0.16));
16
+ border-radius: $radius-4;
17
+ z-index: 1;
18
+ &.table-export-popup {
19
+ top: 50px;
20
+ right: 10px;
21
+ width: 156px;
22
+ padding: 8px 0;
23
+ animation: fadeIn .2s ease-in-out;
24
+ .popup-option {
25
+ padding: 8px 16px;
26
+ @include font($size: $t4-text, $color: $primary-text-clr);
27
+ line-height: 22px;
28
+ transition: all .2s linear;
29
+ cursor: pointer;
30
+ &:hover {
31
+ background-color: $grey-lighter-clr;
32
+ }
33
+ span {
34
+ margin-right: 8px;
35
+ }
36
+ }
37
+ }
38
+ }
39
+
40
+ /* text alignment styles */
41
+ .text-right {
42
+ text-align: right;
43
+ }
44
+
45
+ .text-center {
46
+ text-align: center !important;
47
+ }
48
+
49
+ .text-left {
50
+ text-align: left;
51
+ }
52
+
53
+ /* typography styles */
54
+ .f12 {
55
+ font-size: size(12);
56
+ }
57
+ .f14 {
58
+ font-size: size(14) !important;
59
+ }
60
+ .f16 {
61
+ font-size: size(16);
62
+ }
63
+ .f20 {
64
+ font-size: size(20);
65
+ }
66
+ .f24 {
67
+ font-size: size(24);
68
+ }
69
+ .bold {
70
+ font-weight: weight(bold);
71
+ }
72
+ .bolder {
73
+ font-weight: weight(bolder) !important;
74
+ }
75
+
76
+ /* padding styles */
77
+
78
+ // @for $i from 1 to 39 {
79
+ // .p-#{$i} {
80
+ // padding: #{$i}px !important;
81
+ // }
82
+ // .pb-#{$i} {
83
+ // padding-bottom: #{$i}px !important;
84
+ // }
85
+ // .pt-#{$i} {
86
+ // padding-top: #{$i}px !important;
87
+ // }
88
+ // }
89
+
90
+ // @for $i from 1 to 21 {
91
+ // .pr-#{$i*2} {
92
+ // padding-right: #{$i*2}px !important;
93
+ // }
94
+ // .pl-#{$i*2} {
95
+ // padding-left: #{$i*2}px !important;
96
+ // }
97
+ // }
98
+
99
+ /* margin styles */
100
+ .m-auto {
101
+ margin: auto;
102
+ }
103
+ .mt-10 {
104
+ margin-top: 10px;
105
+ }
106
+ .mt-20 {
107
+ margin-top: 20px;
108
+ }
109
+ .mt-50 {
110
+ margin-top: 50px;
111
+ }
112
+ .mb-10 {
113
+ margin-bottom: 20px;
114
+ }
115
+ .mb-24 {
116
+ margin-bottom: 24px;
117
+ }
118
+
119
+ .mr-10 {
120
+ margin-right: 10px;
121
+ }
122
+ .mr-20 {
123
+ margin-right: 20px;
124
+ }
125
+
126
+ .ml-10 {
127
+ margin-left: 10px;
128
+ }
129
+ .ml-20 {
130
+ margin-left: 20px;
131
+ }
132
+ .ml-35 {
133
+ margin-left: 35px;
134
+ }
135
+
136
+ /* width styles in pixel */
137
+ .w-120 {
138
+ width: 120px;
139
+ }
140
+ .w-130 {
141
+ width: 130px;
142
+ }
143
+ .w-160 {
144
+ width: 160px;
145
+ }
146
+ .w-400 {
147
+ width: 400px !important;
148
+ }
149
+ .w-500 {
150
+ width: 500px;
151
+ }
152
+ .w-600 {
153
+ width: 600px;
154
+ }
155
+
156
+ /* width styles in % */
157
+ .w100 {
158
+ width: 100% !important;
159
+ }
160
+
161
+ /* border styles */
162
+ .circular-border {
163
+ border-radius: $circle;
164
+ }
165
+ .border-top {
166
+ border-top: 1px solid #ccc;
167
+ }
168
+ .border-bottom {
169
+ border-bottom: 1px solid #ccc;
170
+ }
171
+
172
+ //common styles gose here
173
+ .active {
174
+ a {
175
+ color: white !important;
176
+ }
177
+ }
178
+
179
+ .hidden {
180
+ display: none !important;
181
+ }
182
+
183
+ .pointer {
184
+ cursor: pointer;
185
+ }
186
+
187
+ .error-text {
188
+ font-size: 14px;
189
+ color: $error-clr;
190
+ margin: 5px 0;
191
+ animation: shakeError 0.82s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
192
+ transform: translate3d(0, 0, 0);
193
+ backface-visibility: hidden;
194
+ perspective: 1000px;
195
+ }
196
+
197
+ .required-symbol {
198
+ color: $brand-color;
199
+ margin-left: 2px;
200
+ }
201
+
202
+ .text-ellipsis {
203
+ overflow: hidden;
204
+ text-overflow: ellipsis;
205
+ }
206
+
207
+ @keyframes shakeError {
208
+ 10%,
209
+ 90% {
210
+ transform: translate3d(-1px, 0, 0);
211
+ }
212
+
213
+ 20%,
214
+ 80% {
215
+ transform: translate3d(2px, 0, 0);
216
+ }
217
+
218
+ 30%,
219
+ 50%,
220
+ 70% {
221
+ transform: translate3d(-4px, 0, 0);
222
+ }
223
+
224
+ 40%,
225
+ 60% {
226
+ transform: translate3d(4px, 0, 0);
227
+ }
228
+ }
229
+
230
+ @keyframes fadeIn {
231
+ from {
232
+ opacity: 0;
233
+ }
234
+ to {
235
+ opacity: 1;
236
+ }
237
+ }