activeadmin_materialize_theme 0.1.2 → 0.1.4

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6549ff445c844c97a9da951f609bc9dc831a2d4f2105e79821cc35d628f0c35b
4
- data.tar.gz: e0b3ee1c6de8d2ec07cf450b694f1c82f96dd7749d39a88ad282dd697693e64c
3
+ metadata.gz: 0335e4467d41b420ae51d5f670bd8c112b2caf2a4f6b59d3e417c9802db976b8
4
+ data.tar.gz: 643e6978620b3f680118669d61bc25488e5f60b01475ef690c0268492eaf3fe7
5
5
  SHA512:
6
- metadata.gz: 4f7d306351a90d3f58526c5cc4f373226649fa9ddae22aa7cb94d8aae923aabff227bf891810be8b536d7f2f367d00cd7029863e10e07c84552e52f3fd166d63
7
- data.tar.gz: 0dd6a6f8710dc9b980cf0791348ad9d898b7fa26ece978194f6f36dff7ebf0c660b73db0c76bd84288c357b11077b148d50d4905eacb5fc8f93fdfd1aa9eb1ce
6
+ metadata.gz: 1b4d6a75e3967b1447be97167f0de47342cccb0ce707f8e94b99859c8c2fcaf641781fa69f30a52d5a8aba9e9a673069126290e58bbf437584cf26533c5084e0
7
+ data.tar.gz: c44687eae71031414fc9d0481a4f0d86f75c203402bbf0ccad29379b2c48317d4699ab7f25c278e58c76421f169d85146041339a4ace31689e41d1cb1429bb5d
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # Active Admin Materialize Theme
1
+ # Active Admin Materialize Theme [![Gem Version](https://badge.fury.io/rb/activeadmin_materialize_theme.svg)](https://badge.fury.io/rb/activeadmin_materialize_theme)
2
2
  A theme for Active Admin based on Materialize framework.
3
3
 
4
4
  > NOTICE: this is still a beta version
@@ -9,11 +9,18 @@ A theme for Active Admin based on Materialize framework.
9
9
  ```scss
10
10
  @import 'activeadmin_materialize_theme/theme';
11
11
  ```
12
+ - (optionally) Enable Roboto font:
13
+ ```scss
14
+ @import 'activeadmin_materialize_theme/roboto';
15
+ ```
12
16
  - Add at the end of your Active Admin javascripts (_app/assets/javascripts/active_admin.js_):
13
17
  ```js
14
18
  //= require activeadmin_materialize_theme
15
19
  ```
16
20
 
21
+ ## Screenshot
22
+ ![form](extra/screenshot.png)
23
+
17
24
  ## Do you like it? Star it!
18
25
  If you use this component just star it. A developer is more motivated to improve a project when there is some interest.
19
26
 
@@ -57,9 +57,11 @@
57
57
  // --- events ----------------------------------------------------------------
58
58
  document.addEventListener('DOMContentLoaded', () => {
59
59
  setup()
60
- })
61
-
62
- $(document).on('has_many_add:after', '.has_many_container', () => {
63
- setup()
60
+ document.querySelectorAll('body.active_admin .has_many_container').forEach((el) => {
61
+ const observer = new MutationObserver((_mutationsList, _observer) => {
62
+ initFormFields()
63
+ })
64
+ observer.observe(el, { childList: true, subtree: true });
65
+ })
64
66
  })
65
67
  })()
@@ -19,7 +19,21 @@ body.active_admin {
19
19
  padding: 0.5rem 0.6rem;
20
20
 
21
21
  &::after {
22
- content: ' ';
22
+ content: ' ';
23
+ font-size: 2rem;
24
+ }
25
+ }
26
+
27
+ .dropdown-content {
28
+ width: auto !important;
29
+ height: auto !important;
30
+ }
31
+
32
+ .dropdown_menu_list {
33
+ margin: 0;
34
+
35
+ a.batch_action {
36
+ color: $link-color;
23
37
  }
24
38
  }
25
39
 
@@ -17,6 +17,11 @@ body.active_admin.index {
17
17
  thead >tr {
18
18
  border-bottom: 1px solid #aaa;
19
19
  }
20
+
21
+ th, td {
22
+ padding-bottom: 0.3rem !important;
23
+ padding-top: 0.3rem !important;
24
+ }
20
25
  }
21
26
 
22
27
  .paginated_collection {
@@ -0,0 +1,172 @@
1
+ /* cyrillic-ext */
2
+ @font-face {
3
+ font-family: 'Roboto';
4
+ font-style: normal;
5
+ font-weight: 300;
6
+ src: local('Roboto Light'), local('Roboto-Light'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmSU5fCRc4AMP6lbBP.woff2) format('woff2');
7
+ unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
8
+ }
9
+ /* cyrillic */
10
+ @font-face {
11
+ font-family: 'Roboto';
12
+ font-style: normal;
13
+ font-weight: 300;
14
+ src: local('Roboto Light'), local('Roboto-Light'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmSU5fABc4AMP6lbBP.woff2) format('woff2');
15
+ unicode-range: U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
16
+ }
17
+ /* greek-ext */
18
+ @font-face {
19
+ font-family: 'Roboto';
20
+ font-style: normal;
21
+ font-weight: 300;
22
+ src: local('Roboto Light'), local('Roboto-Light'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmSU5fCBc4AMP6lbBP.woff2) format('woff2');
23
+ unicode-range: U+1F00-1FFF;
24
+ }
25
+ /* greek */
26
+ @font-face {
27
+ font-family: 'Roboto';
28
+ font-style: normal;
29
+ font-weight: 300;
30
+ src: local('Roboto Light'), local('Roboto-Light'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmSU5fBxc4AMP6lbBP.woff2) format('woff2');
31
+ unicode-range: U+0370-03FF;
32
+ }
33
+ /* vietnamese */
34
+ @font-face {
35
+ font-family: 'Roboto';
36
+ font-style: normal;
37
+ font-weight: 300;
38
+ src: local('Roboto Light'), local('Roboto-Light'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmSU5fCxc4AMP6lbBP.woff2) format('woff2');
39
+ unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+1EA0-1EF9, U+20AB;
40
+ }
41
+ /* latin-ext */
42
+ @font-face {
43
+ font-family: 'Roboto';
44
+ font-style: normal;
45
+ font-weight: 300;
46
+ src: local('Roboto Light'), local('Roboto-Light'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmSU5fChc4AMP6lbBP.woff2) format('woff2');
47
+ unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
48
+ }
49
+ /* latin */
50
+ @font-face {
51
+ font-family: 'Roboto';
52
+ font-style: normal;
53
+ font-weight: 300;
54
+ src: local('Roboto Light'), local('Roboto-Light'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmSU5fBBc4AMP6lQ.woff2) format('woff2');
55
+ unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
56
+ }
57
+ /* cyrillic-ext */
58
+ @font-face {
59
+ font-family: 'Roboto';
60
+ font-style: normal;
61
+ font-weight: 400;
62
+ src: local('Roboto'), local('Roboto-Regular'), url(https://fonts.gstatic.com/s/roboto/v20/KFOmCnqEu92Fr1Mu72xKKTU1Kvnz.woff2) format('woff2');
63
+ unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
64
+ }
65
+ /* cyrillic */
66
+ @font-face {
67
+ font-family: 'Roboto';
68
+ font-style: normal;
69
+ font-weight: 400;
70
+ src: local('Roboto'), local('Roboto-Regular'), url(https://fonts.gstatic.com/s/roboto/v20/KFOmCnqEu92Fr1Mu5mxKKTU1Kvnz.woff2) format('woff2');
71
+ unicode-range: U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
72
+ }
73
+ /* greek-ext */
74
+ @font-face {
75
+ font-family: 'Roboto';
76
+ font-style: normal;
77
+ font-weight: 400;
78
+ src: local('Roboto'), local('Roboto-Regular'), url(https://fonts.gstatic.com/s/roboto/v20/KFOmCnqEu92Fr1Mu7mxKKTU1Kvnz.woff2) format('woff2');
79
+ unicode-range: U+1F00-1FFF;
80
+ }
81
+ /* greek */
82
+ @font-face {
83
+ font-family: 'Roboto';
84
+ font-style: normal;
85
+ font-weight: 400;
86
+ src: local('Roboto'), local('Roboto-Regular'), url(https://fonts.gstatic.com/s/roboto/v20/KFOmCnqEu92Fr1Mu4WxKKTU1Kvnz.woff2) format('woff2');
87
+ unicode-range: U+0370-03FF;
88
+ }
89
+ /* vietnamese */
90
+ @font-face {
91
+ font-family: 'Roboto';
92
+ font-style: normal;
93
+ font-weight: 400;
94
+ src: local('Roboto'), local('Roboto-Regular'), url(https://fonts.gstatic.com/s/roboto/v20/KFOmCnqEu92Fr1Mu7WxKKTU1Kvnz.woff2) format('woff2');
95
+ unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+1EA0-1EF9, U+20AB;
96
+ }
97
+ /* latin-ext */
98
+ @font-face {
99
+ font-family: 'Roboto';
100
+ font-style: normal;
101
+ font-weight: 400;
102
+ src: local('Roboto'), local('Roboto-Regular'), url(https://fonts.gstatic.com/s/roboto/v20/KFOmCnqEu92Fr1Mu7GxKKTU1Kvnz.woff2) format('woff2');
103
+ unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
104
+ }
105
+ /* latin */
106
+ @font-face {
107
+ font-family: 'Roboto';
108
+ font-style: normal;
109
+ font-weight: 400;
110
+ src: local('Roboto'), local('Roboto-Regular'), url(https://fonts.gstatic.com/s/roboto/v20/KFOmCnqEu92Fr1Mu4mxKKTU1Kg.woff2) format('woff2');
111
+ unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
112
+ }
113
+ /* cyrillic-ext */
114
+ @font-face {
115
+ font-family: 'Roboto';
116
+ font-style: normal;
117
+ font-weight: 500;
118
+ src: local('Roboto Medium'), local('Roboto-Medium'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmEU9fCRc4AMP6lbBP.woff2) format('woff2');
119
+ unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
120
+ }
121
+ /* cyrillic */
122
+ @font-face {
123
+ font-family: 'Roboto';
124
+ font-style: normal;
125
+ font-weight: 500;
126
+ src: local('Roboto Medium'), local('Roboto-Medium'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmEU9fABc4AMP6lbBP.woff2) format('woff2');
127
+ unicode-range: U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
128
+ }
129
+ /* greek-ext */
130
+ @font-face {
131
+ font-family: 'Roboto';
132
+ font-style: normal;
133
+ font-weight: 500;
134
+ src: local('Roboto Medium'), local('Roboto-Medium'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmEU9fCBc4AMP6lbBP.woff2) format('woff2');
135
+ unicode-range: U+1F00-1FFF;
136
+ }
137
+ /* greek */
138
+ @font-face {
139
+ font-family: 'Roboto';
140
+ font-style: normal;
141
+ font-weight: 500;
142
+ src: local('Roboto Medium'), local('Roboto-Medium'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmEU9fBxc4AMP6lbBP.woff2) format('woff2');
143
+ unicode-range: U+0370-03FF;
144
+ }
145
+ /* vietnamese */
146
+ @font-face {
147
+ font-family: 'Roboto';
148
+ font-style: normal;
149
+ font-weight: 500;
150
+ src: local('Roboto Medium'), local('Roboto-Medium'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmEU9fCxc4AMP6lbBP.woff2) format('woff2');
151
+ unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+1EA0-1EF9, U+20AB;
152
+ }
153
+ /* latin-ext */
154
+ @font-face {
155
+ font-family: 'Roboto';
156
+ font-style: normal;
157
+ font-weight: 500;
158
+ src: local('Roboto Medium'), local('Roboto-Medium'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmEU9fChc4AMP6lbBP.woff2) format('woff2');
159
+ unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
160
+ }
161
+ /* latin */
162
+ @font-face {
163
+ font-family: 'Roboto';
164
+ font-style: normal;
165
+ font-weight: 500;
166
+ src: local('Roboto Medium'), local('Roboto-Medium'), url(https://fonts.gstatic.com/s/roboto/v20/KFOlCnqEu92Fr1MmEU9fBBc4AMP6lQ.woff2) format('woff2');
167
+ unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
168
+ }
169
+
170
+ body.active_admin {
171
+ font-family: Roboto, Ubuntu, "Segoe UI", "Helvetica Neue", sans-serif;
172
+ }
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ActiveadminMaterializeTheme
4
- VERSION = '0.1.2'
4
+ VERSION = '0.1.4'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: activeadmin_materialize_theme
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mattia Roccoberton
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-09-07 00:00:00.000000000 Z
11
+ date: 2020-09-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activeadmin
@@ -118,6 +118,7 @@ files:
118
118
  - app/assets/stylesheets/activeadmin_materialize_theme/materialize/components/forms/_switches.scss
119
119
  - app/assets/stylesheets/activeadmin_materialize_theme/materialize/materialize.scss
120
120
  - app/assets/stylesheets/activeadmin_materialize_theme/normalize.css
121
+ - app/assets/stylesheets/activeadmin_materialize_theme/roboto.scss
121
122
  - app/assets/stylesheets/activeadmin_materialize_theme/theme.scss
122
123
  - app/assets/stylesheets/activeadmin_materialize_theme/variables.scss
123
124
  - lib/activeadmin_materialize_theme.rb