monkrb 0.27.0 → 0.28.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 +4 -4
- data/CHANGELOG.md +55 -0
- data/README.md +3 -3
- data/lib/monk/auth/helpers.rb +41 -9
- data/lib/monk/auth/send_login_link.rb +7 -4
- data/lib/monk/auth.rb +248 -21
- data/lib/monk/generators/auth.rb +3 -1
- data/lib/monk/push/store.rb +17 -10
- data/lib/monk/push.rb +3 -2
- data/lib/monk/pwa/client/platform.js +21 -0
- data/lib/monk/pwa/client/register.js +93 -0
- data/lib/monk/pwa/helpers.rb +38 -0
- data/lib/monk/templates/auth/agents.md +20 -11
- data/lib/monk/templates/auth/app/mailers/auth_mailer.rb +8 -4
- data/lib/monk/templates/auth/app/routes/auth.rb +35 -7
- data/lib/monk/templates/auth/app/views/auth/login.erb +20 -6
- data/lib/monk/templates/auth/app/views/mail/magic_link.erb +3 -2
- data/lib/monk/templates/auth/config/auth.rb +4 -2
- data/lib/monk/templates/auth/db/migrate/00000000000007_add_login_codes.down.sql +5 -0
- data/lib/monk/templates/auth/db/migrate/00000000000007_add_login_codes.up.sql +16 -0
- data/lib/monk/templates/auth/setup.md +19 -14
- data/lib/monk/templates/auth/test/auth_test.rb +20 -7
- data/lib/monk/templates/base/Gemfile +1 -1
- data/lib/monk/templates/push/agents.md +3 -2
- data/lib/monk/templates/pwa/agents.md +6 -2
- data/lib/monk/templates/pwa/setup.md +7 -0
- data/lib/monk/version.rb +1 -1
- metadata +4 -1
|
@@ -16,6 +16,13 @@ reaches an app installed this way. Nothing to start: the files are in
|
|
|
16
16
|
content inside the middle 80%, since Android crops it to a circle or a
|
|
17
17
|
rounded square) and `apple-touch-icon.png` (180×180, iOS).
|
|
18
18
|
|
|
19
|
+
### Helping people install
|
|
20
|
+
|
|
21
|
+
Add `<%= monk_install %>` to `app/views/layouts/app.erb` (or a page): a
|
|
22
|
+
banner, hidden until it applies, inviting people to install the app. On
|
|
23
|
+
iOS its button shows how to Add to Home Screen; on Android it opens
|
|
24
|
+
Chrome's prompt. It has no styles: style its `monk-install` classes.
|
|
25
|
+
|
|
19
26
|
### Before production
|
|
20
27
|
|
|
21
28
|
Service workers need https (or localhost): a phone opening the dev server
|
data/lib/monk/version.rb
CHANGED
|
@@ -5,5 +5,5 @@ module Monk
|
|
|
5
5
|
# class of bug .freeze! guards against for routes/error handlers/models,
|
|
6
6
|
# just on a top-level constant that every worker Ractor reads on boot
|
|
7
7
|
# (found live under kino: GET /hello 500'd until this was frozen).
|
|
8
|
-
VERSION = "0.
|
|
8
|
+
VERSION = "0.28.0".freeze
|
|
9
9
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: monkrb
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.28.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Matteo Folin
|
|
@@ -274,6 +274,7 @@ files:
|
|
|
274
274
|
- lib/monk/push/subscription.rb
|
|
275
275
|
- lib/monk/push/vapid.rb
|
|
276
276
|
- lib/monk/pwa.rb
|
|
277
|
+
- lib/monk/pwa/client/platform.js
|
|
277
278
|
- lib/monk/pwa/client/register.js
|
|
278
279
|
- lib/monk/pwa/errors.rb
|
|
279
280
|
- lib/monk/pwa/helpers.rb
|
|
@@ -303,6 +304,8 @@ files:
|
|
|
303
304
|
- lib/monk/templates/auth/db/migrate/00000000000001_create_auth_tables.up.sql
|
|
304
305
|
- lib/monk/templates/auth/db/migrate/00000000000004_create_login_requests.down.sql
|
|
305
306
|
- lib/monk/templates/auth/db/migrate/00000000000004_create_login_requests.up.sql
|
|
307
|
+
- lib/monk/templates/auth/db/migrate/00000000000007_add_login_codes.down.sql
|
|
308
|
+
- lib/monk/templates/auth/db/migrate/00000000000007_add_login_codes.up.sql
|
|
306
309
|
- lib/monk/templates/auth/deploy/env.production
|
|
307
310
|
- lib/monk/templates/auth/setup.md
|
|
308
311
|
- lib/monk/templates/auth/test/auth_test.rb
|