maquina 0.1.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.overmind.env +1 -0
- data/Gemfile +20 -0
- data/Gemfile.lock +346 -0
- data/Procfile.dev +3 -0
- data/app/assets/images/maquina/.keep +0 -0
- data/app/assets/javascripts/maquina/controllers/file_controller.js +1 -1
- data/app/assets/javascripts/maquina/controllers/modal_controller.js +1 -1
- data/app/assets/javascripts/maquina/controllers/modal_open_controller.js +3 -8
- data/app/assets/stylesheets/maquina/application.tailwind.css +96 -97
- data/app/controllers/concerns/.keep +0 -0
- data/app/controllers/concerns/maquina/authenticate.rb +8 -1
- data/app/controllers/concerns/maquina/resourceful.rb +9 -9
- data/app/models/concerns/.keep +0 -0
- data/app/models/concerns/maquina/blockeable.rb +13 -3
- data/app/models/concerns/maquina/searchable.rb +2 -2
- data/app/models/maquina/application_record.rb +3 -3
- data/app/models/maquina/current.rb +2 -1
- data/app/models/maquina/membership.rb +10 -0
- data/app/models/maquina/organization.rb +7 -0
- data/app/models/maquina/plan.rb +1 -3
- data/app/models/maquina/user.rb +8 -3
- data/app/policies/maquina/application_policy.rb +3 -6
- data/app/policies/maquina/invitation_policy.rb +2 -2
- data/app/policies/maquina/navigation_policy.rb +2 -2
- data/app/policies/maquina/user_policy.rb +7 -3
- data/app/views/layouts/maquina/application.html.erb +1 -2
- data/app/views/layouts/maquina/sessions.html.erb +1 -2
- data/app/views/maquina/application/_navbar.html.erb +1 -1
- data/app/views/maquina/application/components/file_component.rb +38 -5
- data/app/views/maquina/application/form.rb +3 -2
- data/app/views/maquina/application/index_header.rb +1 -1
- data/app/views/maquina/application/index_modal.rb +1 -3
- data/config/importmap.rb +12 -0
- data/db/migrate/20230829183530_create_maquina_organizations.rb +11 -0
- data/db/migrate/20230829192656_create_maquina_memberships.rb +15 -0
- data/lib/generators/maquina/install_generator.rb +0 -4
- data/lib/generators/maquina/tailwind_config/USAGE +14 -0
- data/lib/generators/maquina/tailwind_config/tailwind_config_generator.rb +17 -3
- data/lib/generators/maquina/tailwind_config/templates/app/assets/stylesheets/maquina.css +96 -0
- data/lib/generators/maquina/tailwind_config/templates/lib/generators/tailwind_config/tailwind_config_generator.rb.tt +11 -0
- data/lib/generators/maquina/tailwind_config/templates/{app/assets/config/maquina → lib/generators/tailwind_config/templates/config}/tailwind.config.js.tt +4 -0
- data/lib/generators/maquina/tailwind_config/templates/lib/tasks/tailwind.rake.tt +11 -0
- data/lib/generators/maquina/templates/config/initializers/maquina.rb.tt +6 -0
- data/lib/maquina/engine.rb +0 -4
- data/lib/maquina/version.rb +1 -1
- data/lib/maquina.rb +11 -4
- metadata +23 -10
- data/config/definitions.rb +0 -1
- data/config/initializers/importmap.rb +0 -17
- data/lib/generators/maquina/templates/config/initializers/maquina.rb +0 -3
- data/lib/tasks/tailwind.rake +0 -25
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 253e32217b0c2f5e0a8a352ff4ac26a1e0d904184293205135f1d60fd43392d2
|
4
|
+
data.tar.gz: a347016c5e76c08fc3165662b47684ff181667a4bea70c25e340bc71e760b1cc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 77c5d7eb9e6927194b0ea5635f8a535b898010b755e42e254258e2af675c6c4ba08c70372141056e2fd296008d7a120d938019f5fa55966d3d3314cc61744621
|
7
|
+
data.tar.gz: 1013008ff3b86923b4d055c894d62e01ba23e84c4cad7d029454d1d8f9e80865ac038be1f5693c39a9828cebec1fc57c0a6591d6b16c4c7d134a83d321ef4acd
|
data/.overmind.env
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
OVERMIND_PROCFILE=Procfile.dev
|
data/Gemfile
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
source "https://rubygems.org"
|
2
|
+
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
|
3
|
+
|
4
|
+
# Specify your gem's dependencies in maquina.gemspec.
|
5
|
+
gemspec
|
6
|
+
|
7
|
+
gem "irb"
|
8
|
+
gem "pg"
|
9
|
+
gem "puma"
|
10
|
+
gem "propshaft"
|
11
|
+
gem "tailwindcss-rails"
|
12
|
+
gem "turbo-rails"
|
13
|
+
|
14
|
+
# Start debugger with binding.b [https://github.com/ruby/debug]
|
15
|
+
#
|
16
|
+
group :development do
|
17
|
+
gem "debug", ">= 1.0.0"
|
18
|
+
gem "letter_opener"
|
19
|
+
# gem "ruby-lsp", require: false
|
20
|
+
end
|
data/Gemfile.lock
ADDED
@@ -0,0 +1,346 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
maquina (0.2.1)
|
5
|
+
action_policy (~> 0.6.3)
|
6
|
+
bcrypt (~> 3.1.7)
|
7
|
+
importmap-rails (~> 1.2.0)
|
8
|
+
money-rails (~> 1.15.0)
|
9
|
+
pagy (~> 5.10, >= 5.10.1)
|
10
|
+
pg_search (~> 2.3.0)
|
11
|
+
phlex-rails (~> 1.0.0)
|
12
|
+
rails (>= 7.0.4)
|
13
|
+
rotp (~> 6.2, >= 6.2.1)
|
14
|
+
stimulus-rails (~> 1.2.0)
|
15
|
+
tailwindcss-rails (~> 2.0.0)
|
16
|
+
turbo-rails (~> 1.3.0)
|
17
|
+
|
18
|
+
GEM
|
19
|
+
remote: https://rubygems.org/
|
20
|
+
specs:
|
21
|
+
action_policy (0.6.5)
|
22
|
+
ruby-next-core (>= 0.14.0)
|
23
|
+
actioncable (7.0.7.2)
|
24
|
+
actionpack (= 7.0.7.2)
|
25
|
+
activesupport (= 7.0.7.2)
|
26
|
+
nio4r (~> 2.0)
|
27
|
+
websocket-driver (>= 0.6.1)
|
28
|
+
actionmailbox (7.0.7.2)
|
29
|
+
actionpack (= 7.0.7.2)
|
30
|
+
activejob (= 7.0.7.2)
|
31
|
+
activerecord (= 7.0.7.2)
|
32
|
+
activestorage (= 7.0.7.2)
|
33
|
+
activesupport (= 7.0.7.2)
|
34
|
+
mail (>= 2.7.1)
|
35
|
+
net-imap
|
36
|
+
net-pop
|
37
|
+
net-smtp
|
38
|
+
actionmailer (7.0.7.2)
|
39
|
+
actionpack (= 7.0.7.2)
|
40
|
+
actionview (= 7.0.7.2)
|
41
|
+
activejob (= 7.0.7.2)
|
42
|
+
activesupport (= 7.0.7.2)
|
43
|
+
mail (~> 2.5, >= 2.5.4)
|
44
|
+
net-imap
|
45
|
+
net-pop
|
46
|
+
net-smtp
|
47
|
+
rails-dom-testing (~> 2.0)
|
48
|
+
actionpack (7.0.7.2)
|
49
|
+
actionview (= 7.0.7.2)
|
50
|
+
activesupport (= 7.0.7.2)
|
51
|
+
rack (~> 2.0, >= 2.2.4)
|
52
|
+
rack-test (>= 0.6.3)
|
53
|
+
rails-dom-testing (~> 2.0)
|
54
|
+
rails-html-sanitizer (~> 1.0, >= 1.2.0)
|
55
|
+
actiontext (7.0.7.2)
|
56
|
+
actionpack (= 7.0.7.2)
|
57
|
+
activerecord (= 7.0.7.2)
|
58
|
+
activestorage (= 7.0.7.2)
|
59
|
+
activesupport (= 7.0.7.2)
|
60
|
+
globalid (>= 0.6.0)
|
61
|
+
nokogiri (>= 1.8.5)
|
62
|
+
actionview (7.0.7.2)
|
63
|
+
activesupport (= 7.0.7.2)
|
64
|
+
builder (~> 3.1)
|
65
|
+
erubi (~> 1.4)
|
66
|
+
rails-dom-testing (~> 2.0)
|
67
|
+
rails-html-sanitizer (~> 1.1, >= 1.2.0)
|
68
|
+
activejob (7.0.7.2)
|
69
|
+
activesupport (= 7.0.7.2)
|
70
|
+
globalid (>= 0.3.6)
|
71
|
+
activemodel (7.0.7.2)
|
72
|
+
activesupport (= 7.0.7.2)
|
73
|
+
activerecord (7.0.7.2)
|
74
|
+
activemodel (= 7.0.7.2)
|
75
|
+
activesupport (= 7.0.7.2)
|
76
|
+
activestorage (7.0.7.2)
|
77
|
+
actionpack (= 7.0.7.2)
|
78
|
+
activejob (= 7.0.7.2)
|
79
|
+
activerecord (= 7.0.7.2)
|
80
|
+
activesupport (= 7.0.7.2)
|
81
|
+
marcel (~> 1.0)
|
82
|
+
mini_mime (>= 1.1.0)
|
83
|
+
activesupport (7.0.7.2)
|
84
|
+
concurrent-ruby (~> 1.0, >= 1.0.2)
|
85
|
+
i18n (>= 1.6, < 2)
|
86
|
+
minitest (>= 5.1)
|
87
|
+
tzinfo (~> 2.0)
|
88
|
+
addressable (2.8.5)
|
89
|
+
public_suffix (>= 2.0.2, < 6.0)
|
90
|
+
ast (2.4.2)
|
91
|
+
backport (1.2.0)
|
92
|
+
base64 (0.1.1)
|
93
|
+
bcrypt (3.1.19)
|
94
|
+
benchmark (0.2.1)
|
95
|
+
brakeman (6.0.1)
|
96
|
+
builder (3.2.4)
|
97
|
+
bundle-audit (0.1.0)
|
98
|
+
bundler-audit
|
99
|
+
bundler-audit (0.9.1)
|
100
|
+
bundler (>= 1.2.0, < 3)
|
101
|
+
thor (~> 1.0)
|
102
|
+
cgi (0.3.6)
|
103
|
+
concurrent-ruby (1.2.2)
|
104
|
+
crass (1.0.6)
|
105
|
+
date (3.3.3)
|
106
|
+
debug (1.8.0)
|
107
|
+
irb (>= 1.5.0)
|
108
|
+
reline (>= 0.3.1)
|
109
|
+
diff-lcs (1.5.0)
|
110
|
+
e2mmap (0.1.0)
|
111
|
+
erb (4.0.3)
|
112
|
+
cgi (>= 0.3.3)
|
113
|
+
erubi (1.12.0)
|
114
|
+
globalid (1.1.0)
|
115
|
+
activesupport (>= 5.0)
|
116
|
+
i18n (1.14.1)
|
117
|
+
concurrent-ruby (~> 1.0)
|
118
|
+
importmap-rails (1.2.1)
|
119
|
+
actionpack (>= 6.0.0)
|
120
|
+
railties (>= 6.0.0)
|
121
|
+
io-console (0.6.0)
|
122
|
+
irb (1.7.4)
|
123
|
+
reline (>= 0.3.6)
|
124
|
+
jaro_winkler (1.5.6)
|
125
|
+
json (2.6.3)
|
126
|
+
kramdown (2.4.0)
|
127
|
+
rexml
|
128
|
+
kramdown-parser-gfm (1.1.0)
|
129
|
+
kramdown (~> 2.0)
|
130
|
+
language_server-protocol (3.17.0.3)
|
131
|
+
launchy (2.5.2)
|
132
|
+
addressable (~> 2.8)
|
133
|
+
letter_opener (1.8.1)
|
134
|
+
launchy (>= 2.2, < 3)
|
135
|
+
lint_roller (1.1.0)
|
136
|
+
loofah (2.21.3)
|
137
|
+
crass (~> 1.0.2)
|
138
|
+
nokogiri (>= 1.12.0)
|
139
|
+
mail (2.8.1)
|
140
|
+
mini_mime (>= 0.1.1)
|
141
|
+
net-imap
|
142
|
+
net-pop
|
143
|
+
net-smtp
|
144
|
+
marcel (1.0.2)
|
145
|
+
method_source (1.0.0)
|
146
|
+
mini_mime (1.1.5)
|
147
|
+
minitest (5.19.0)
|
148
|
+
monetize (1.12.0)
|
149
|
+
money (~> 6.12)
|
150
|
+
money (6.16.0)
|
151
|
+
i18n (>= 0.6.4, <= 2)
|
152
|
+
money-rails (1.15.0)
|
153
|
+
activesupport (>= 3.0)
|
154
|
+
monetize (~> 1.9)
|
155
|
+
money (~> 6.13)
|
156
|
+
railties (>= 3.0)
|
157
|
+
net-imap (0.3.7)
|
158
|
+
date
|
159
|
+
net-protocol
|
160
|
+
net-pop (0.1.2)
|
161
|
+
net-protocol
|
162
|
+
net-protocol (0.2.1)
|
163
|
+
timeout
|
164
|
+
net-smtp (0.3.3)
|
165
|
+
net-protocol
|
166
|
+
nio4r (2.5.9)
|
167
|
+
nokogiri (1.15.4-arm64-darwin)
|
168
|
+
racc (~> 1.4)
|
169
|
+
pagy (5.10.1)
|
170
|
+
activesupport
|
171
|
+
parallel (1.23.0)
|
172
|
+
parser (3.2.2.3)
|
173
|
+
ast (~> 2.4.1)
|
174
|
+
racc
|
175
|
+
pg (1.5.3)
|
176
|
+
pg_search (2.3.6)
|
177
|
+
activerecord (>= 5.2)
|
178
|
+
activesupport (>= 5.2)
|
179
|
+
phlex (1.8.1)
|
180
|
+
concurrent-ruby (~> 1.2)
|
181
|
+
erb (>= 4)
|
182
|
+
zeitwerk (~> 2.6)
|
183
|
+
phlex-rails (1.0.0)
|
184
|
+
phlex (~> 1.7)
|
185
|
+
rails (>= 6.1, < 8)
|
186
|
+
zeitwerk (~> 2.6)
|
187
|
+
prettier_print (1.2.1)
|
188
|
+
propshaft (0.7.0)
|
189
|
+
actionpack (>= 7.0.0)
|
190
|
+
activesupport (>= 7.0.0)
|
191
|
+
rack
|
192
|
+
railties (>= 7.0.0)
|
193
|
+
public_suffix (5.0.3)
|
194
|
+
puma (6.3.1)
|
195
|
+
nio4r (~> 2.0)
|
196
|
+
racc (1.7.1)
|
197
|
+
rack (2.2.8)
|
198
|
+
rack-test (2.1.0)
|
199
|
+
rack (>= 1.3)
|
200
|
+
rails (7.0.7.2)
|
201
|
+
actioncable (= 7.0.7.2)
|
202
|
+
actionmailbox (= 7.0.7.2)
|
203
|
+
actionmailer (= 7.0.7.2)
|
204
|
+
actionpack (= 7.0.7.2)
|
205
|
+
actiontext (= 7.0.7.2)
|
206
|
+
actionview (= 7.0.7.2)
|
207
|
+
activejob (= 7.0.7.2)
|
208
|
+
activemodel (= 7.0.7.2)
|
209
|
+
activerecord (= 7.0.7.2)
|
210
|
+
activestorage (= 7.0.7.2)
|
211
|
+
activesupport (= 7.0.7.2)
|
212
|
+
bundler (>= 1.15.0)
|
213
|
+
railties (= 7.0.7.2)
|
214
|
+
rails-dom-testing (2.2.0)
|
215
|
+
activesupport (>= 5.0.0)
|
216
|
+
minitest
|
217
|
+
nokogiri (>= 1.6)
|
218
|
+
rails-html-sanitizer (1.6.0)
|
219
|
+
loofah (~> 2.21)
|
220
|
+
nokogiri (~> 1.14)
|
221
|
+
railties (7.0.7.2)
|
222
|
+
actionpack (= 7.0.7.2)
|
223
|
+
activesupport (= 7.0.7.2)
|
224
|
+
method_source
|
225
|
+
rake (>= 12.2)
|
226
|
+
thor (~> 1.0)
|
227
|
+
zeitwerk (~> 2.5)
|
228
|
+
rainbow (3.1.1)
|
229
|
+
rake (13.0.6)
|
230
|
+
rbs (2.8.4)
|
231
|
+
regexp_parser (2.8.1)
|
232
|
+
reline (0.3.8)
|
233
|
+
io-console (~> 0.5)
|
234
|
+
reverse_markdown (2.1.1)
|
235
|
+
nokogiri
|
236
|
+
rexml (3.2.6)
|
237
|
+
rotp (6.2.2)
|
238
|
+
rubocop (1.56.2)
|
239
|
+
base64 (~> 0.1.1)
|
240
|
+
json (~> 2.3)
|
241
|
+
language_server-protocol (>= 3.17.0)
|
242
|
+
parallel (~> 1.10)
|
243
|
+
parser (>= 3.2.2.3)
|
244
|
+
rainbow (>= 2.2.2, < 4.0)
|
245
|
+
regexp_parser (>= 1.8, < 3.0)
|
246
|
+
rexml (>= 3.2.5, < 4.0)
|
247
|
+
rubocop-ast (>= 1.28.1, < 2.0)
|
248
|
+
ruby-progressbar (~> 1.7)
|
249
|
+
unicode-display_width (>= 2.4.0, < 3.0)
|
250
|
+
rubocop-ast (1.29.0)
|
251
|
+
parser (>= 3.2.1.0)
|
252
|
+
rubocop-performance (1.19.0)
|
253
|
+
rubocop (>= 1.7.0, < 2.0)
|
254
|
+
rubocop-ast (>= 0.4.0)
|
255
|
+
rubocop-rails (2.19.1)
|
256
|
+
activesupport (>= 4.2.0)
|
257
|
+
rack (>= 1.1)
|
258
|
+
rubocop (>= 1.33.0, < 2.0)
|
259
|
+
ruby-lsp (0.9.2)
|
260
|
+
language_server-protocol (~> 3.17.0)
|
261
|
+
sorbet-runtime
|
262
|
+
syntax_tree (>= 6.1.1, < 7)
|
263
|
+
yarp (>= 0.9, < 0.10)
|
264
|
+
ruby-next-core (0.15.3)
|
265
|
+
ruby-progressbar (1.13.0)
|
266
|
+
solargraph (0.49.0)
|
267
|
+
backport (~> 1.2)
|
268
|
+
benchmark
|
269
|
+
bundler (~> 2.0)
|
270
|
+
diff-lcs (~> 1.4)
|
271
|
+
e2mmap
|
272
|
+
jaro_winkler (~> 1.5)
|
273
|
+
kramdown (~> 2.3)
|
274
|
+
kramdown-parser-gfm (~> 1.1)
|
275
|
+
parser (~> 3.0)
|
276
|
+
rbs (~> 2.0)
|
277
|
+
reverse_markdown (~> 2.0)
|
278
|
+
rubocop (~> 1.38)
|
279
|
+
thor (~> 1.0)
|
280
|
+
tilt (~> 2.0)
|
281
|
+
yard (~> 0.9, >= 0.9.24)
|
282
|
+
solargraph-rails (1.1.0)
|
283
|
+
activesupport
|
284
|
+
solargraph
|
285
|
+
sorbet-runtime (0.5.10990)
|
286
|
+
standard (1.31.0)
|
287
|
+
language_server-protocol (~> 3.17.0.2)
|
288
|
+
lint_roller (~> 1.0)
|
289
|
+
rubocop (~> 1.56.0)
|
290
|
+
standard-custom (~> 1.0.0)
|
291
|
+
standard-performance (~> 1.2)
|
292
|
+
standard-custom (1.0.2)
|
293
|
+
lint_roller (~> 1.0)
|
294
|
+
rubocop (~> 1.50)
|
295
|
+
standard-performance (1.2.0)
|
296
|
+
lint_roller (~> 1.1)
|
297
|
+
rubocop-performance (~> 1.19.0)
|
298
|
+
standard-rails (0.1.0)
|
299
|
+
lint_roller (~> 1.0)
|
300
|
+
rubocop-rails (~> 2.19.0)
|
301
|
+
stimulus-rails (1.2.2)
|
302
|
+
railties (>= 6.0.0)
|
303
|
+
syntax_tree (6.1.1)
|
304
|
+
prettier_print (>= 1.2.0)
|
305
|
+
tailwindcss-rails (2.0.30-arm64-darwin)
|
306
|
+
railties (>= 6.0.0)
|
307
|
+
thor (1.2.2)
|
308
|
+
tilt (2.2.0)
|
309
|
+
timeout (0.4.0)
|
310
|
+
turbo-rails (1.3.3)
|
311
|
+
actionpack (>= 6.0.0)
|
312
|
+
activejob (>= 6.0.0)
|
313
|
+
railties (>= 6.0.0)
|
314
|
+
tzinfo (2.0.6)
|
315
|
+
concurrent-ruby (~> 1.0)
|
316
|
+
unicode-display_width (2.4.2)
|
317
|
+
websocket-driver (0.7.6)
|
318
|
+
websocket-extensions (>= 0.1.0)
|
319
|
+
websocket-extensions (0.1.5)
|
320
|
+
yard (0.9.34)
|
321
|
+
yarp (0.9.0)
|
322
|
+
zeitwerk (2.6.11)
|
323
|
+
|
324
|
+
PLATFORMS
|
325
|
+
arm64-darwin-22
|
326
|
+
|
327
|
+
DEPENDENCIES
|
328
|
+
brakeman
|
329
|
+
bundle-audit
|
330
|
+
debug (>= 1.0.0)
|
331
|
+
irb
|
332
|
+
letter_opener
|
333
|
+
maquina!
|
334
|
+
pg
|
335
|
+
propshaft
|
336
|
+
puma
|
337
|
+
ruby-lsp
|
338
|
+
solargraph
|
339
|
+
solargraph-rails
|
340
|
+
standard
|
341
|
+
standard-rails
|
342
|
+
tailwindcss-rails
|
343
|
+
turbo-rails
|
344
|
+
|
345
|
+
BUNDLED WITH
|
346
|
+
2.4.18
|
data/Procfile.dev
ADDED
File without changes
|
@@ -2,7 +2,7 @@ import { Controller } from "@hotwired/stimulus"
|
|
2
2
|
|
3
3
|
export default class extends Controller {
|
4
4
|
static targets = ["fileInput", "container", "preview", "placeholder"]
|
5
|
-
static values = { maxSize: Number, image: String, validationMessage: String }
|
5
|
+
static values = { maxSize: Number, image: String, validationMessage: String, url: String }
|
6
6
|
|
7
7
|
connect() {
|
8
8
|
if (this.hasFileInputTarget) {
|
@@ -25,7 +25,7 @@ export default class extends Controller {
|
|
25
25
|
event.preventDefault()
|
26
26
|
|
27
27
|
if (this.hasFrameTarget && this.contentTarget.classList.contains("hidden")) {
|
28
|
-
let url = event
|
28
|
+
let url = event.target.getAttribute("href") || this.element.dataset["frameSrc"]
|
29
29
|
this.frameTarget.setAttribute("src", url)
|
30
30
|
} else if (!this.contentTarget.classList.contains("hidden")) {
|
31
31
|
this.frameTarget.setAttribute("src", "")
|
@@ -1,15 +1,10 @@
|
|
1
1
|
import { Controller } from "@hotwired/stimulus";
|
2
|
-
import { useDispatch } from "stimulus-use";
|
3
2
|
|
4
3
|
export default class extends Controller {
|
5
|
-
static
|
6
|
-
|
7
|
-
connect() {
|
8
|
-
useDispatch(this)
|
9
|
-
}
|
4
|
+
static outlets = ["modal"];
|
10
5
|
|
11
6
|
open(event) {
|
12
|
-
event.preventDefault()
|
13
|
-
this.
|
7
|
+
event.preventDefault()
|
8
|
+
this.modalOutlets.forEach(modal => modal.toggleModal(event))
|
14
9
|
}
|
15
10
|
}
|
@@ -3,100 +3,99 @@
|
|
3
3
|
@tailwind utilities;
|
4
4
|
|
5
5
|
/* @layer base { */
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
/* } */
|
6
|
+
:root {
|
7
|
+
--color-base: 31 27 54;
|
8
|
+
--color-accented: 37 99 235;
|
9
|
+
--color-inverted: 255 255 255;
|
10
|
+
--color-accented-hover: 59 130 246;
|
11
|
+
--color-muted: 55 65 81;
|
12
|
+
--color-dimmed: 75 85 99;
|
13
|
+
--color-error: 220 38 38;
|
14
|
+
|
15
|
+
--color-border-base: 209 213 219;
|
16
|
+
--color-border-accented: 37 99 235;
|
17
|
+
}
|
18
|
+
|
19
|
+
.label {
|
20
|
+
@apply text-sm font-medium text-skin-muted;
|
21
|
+
}
|
22
|
+
|
23
|
+
.input {
|
24
|
+
@apply appearance-none rounded-md border border-skin-base px-3 py-2 placeholder-gray-400 shadow-sm focus:border-skin-accented focus:outline-none focus:ring-skin-accented sm:text-sm;
|
25
|
+
}
|
26
|
+
|
27
|
+
.link {
|
28
|
+
@apply font-medium text-skin-accented hover:text-skin-accented-hover;
|
29
|
+
}
|
30
|
+
|
31
|
+
.check {
|
32
|
+
@apply border-skin-base h-4 w-4 text-skin-accented focus:ring-skin-accented rounded;
|
33
|
+
}
|
34
|
+
|
35
|
+
.button {
|
36
|
+
@apply inline-flex justify-center py-2 px-4 border border-skin-base rounded-md shadow-sm text-sm font-medium text-skin-muted bg-white hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-skin-accented;
|
37
|
+
}
|
38
|
+
|
39
|
+
.control-error .label {
|
40
|
+
@apply text-skin-error;
|
41
|
+
}
|
42
|
+
|
43
|
+
.control-error .input {
|
44
|
+
@apply border-skin-error focus:border-skin-error focus:ring-skin-error;
|
45
|
+
}
|
46
|
+
|
47
|
+
.help {
|
48
|
+
@apply mt-2 text-sm text-skin-dimmed;
|
49
|
+
}
|
50
|
+
|
51
|
+
.help-error {
|
52
|
+
@apply text-skin-error;
|
53
|
+
}
|
54
|
+
|
55
|
+
.button[disabled] {
|
56
|
+
@apply bg-gray-50 text-skin-dimmed cursor-default;
|
57
|
+
}
|
58
|
+
|
59
|
+
.button-accented {
|
60
|
+
@apply rounded-md border border-transparent bg-skin-accented py-2 px-4 text-sm font-medium text-skin-inverted shadow-sm hover:bg-skin-accented-hover focus:outline-none focus:ring-2 focus:ring-skin-accented focus:ring-offset-2;
|
61
|
+
}
|
62
|
+
|
63
|
+
input[type="search"] {
|
64
|
+
@apply block w-full rounded-md border border-skin-base pl-10 leading-5 placeholder-gray-400 focus:placeholder-gray-300 focus:outline-none focus:ring-1 focus:ring-skin-accented focus:border-skin-accented sm:text-sm;
|
65
|
+
}
|
66
|
+
|
67
|
+
.desktop-menu {
|
68
|
+
@apply hidden lg:ml-6 lg:flex lg:space-x-8;
|
69
|
+
}
|
70
|
+
|
71
|
+
.desktop-menu-item {
|
72
|
+
@apply font-sans uppercase border-transparent text-skin-dimmed underline-offset-4 decoration-2 hover:underline hover:decoration-skin-accented hover:text-skin-muted inline-flex items-center px-1 pt-1 text-sm font-medium;
|
73
|
+
}
|
74
|
+
|
75
|
+
.desktop-menu-item__active {
|
76
|
+
@apply decoration-skin-accented underline text-skin-base;
|
77
|
+
}
|
78
|
+
|
79
|
+
.mobile-menu {
|
80
|
+
@apply pt-2 pb-3 space-y-1;
|
81
|
+
}
|
82
|
+
|
83
|
+
.mobile-menu-item {
|
84
|
+
@apply font-sans border-transparent text-skin-dimmed hover:bg-gray-200 hover:border-gray-300 hover:text-skin-muted block pl-3 pr-4 py-2 border-l-4 text-base font-medium;
|
85
|
+
}
|
86
|
+
|
87
|
+
.mobile-menu-item__active {
|
88
|
+
@apply bg-skin-accented-hover border-skin-accented text-skin-accented hover:text-skin-accented hover:bg-skin-accented-hover hover:border-skin-accented;
|
89
|
+
}
|
90
|
+
|
91
|
+
.desktop-profile-menu-item {
|
92
|
+
@apply block w-full text-left font-sans px-4 py-2 text-sm text-skin-dimmed hover:bg-gray-200 hover:text-skin-muted;
|
93
|
+
}
|
94
|
+
|
95
|
+
.mobile-profile-menu-item {
|
96
|
+
@apply block font-sans px-4 py-2 text-base font-medium text-skin-dimmed hover:text-skin-muted hover:bg-gray-200;
|
97
|
+
}
|
98
|
+
|
99
|
+
.mobile-button {
|
100
|
+
@apply inline-flex items-center justify-center p-2 rounded-md text-skin-dimmed hover:text-skin-muted hover:bg-gray-100 focus:outline-none focus:ring-2 focus:ring-inset focus:ring-skin-accented;
|
101
|
+
}
|
File without changes
|
@@ -32,7 +32,14 @@ module Maquina
|
|
32
32
|
active_session_id = session["--active_session"]
|
33
33
|
return if active_session_id.blank?
|
34
34
|
|
35
|
-
active_session = ActiveSession.eager_load(
|
35
|
+
active_session = ActiveSession.eager_load(user: {memberships: :organization})
|
36
|
+
.where(maquina_memberships: {blocked_at: nil})
|
37
|
+
.where(maquina_organizations: {active: true})
|
38
|
+
.or(
|
39
|
+
ActiveSession.where(maquina_users: {management: true})
|
40
|
+
)
|
41
|
+
.find_by(id: active_session_id)
|
42
|
+
|
36
43
|
return if active_session.blank?
|
37
44
|
|
38
45
|
Maquina::Current.active_session = active_session
|