rails_onboarding 0.8.3 → 0.8.5
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:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: f8afb9ad8022edcb79752a590ddc52652c947b42be298065194aa28399347fcc
|
|
4
|
+
data.tar.gz: 46d9cfba7ca062ea59075ab52d796a250691e1fcddc58f53438f049af131d2e3
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: d933e36a68ab7d438a06c2dea6dcbf7536d90ae9e5df4e060bf5bd2bccd503f24ff0061c2a1fb40046fbeefd2d211552c0750b9f48bac05e61db027ba02936df
|
|
7
|
+
data.tar.gz: 295d2dc68da00f371d82a592f3355a691d49732270fb45dcc3992958a3cb9d1501cd2433bae931a2b15d661a7b1b9925e9727023f1d7a7759a42d2640bd200c1
|
|
@@ -242,12 +242,23 @@ module RailsOnboarding
|
|
|
242
242
|
|
|
243
243
|
# Check if milestone-based feature is ready
|
|
244
244
|
def milestone_based_ready?(feature)
|
|
245
|
-
|
|
245
|
+
# Onboardable exposes the awarded keys as #achieved_milestones. This used
|
|
246
|
+
# to guard on #earned_milestones, which the engine has never defined, so
|
|
247
|
+
# the guard was false for every host and a :milestone_based feature was
|
|
248
|
+
# never revealed to anyone - silently, since a reveal that does not happen
|
|
249
|
+
# looks exactly like one whose condition is not met yet. #earned_milestones
|
|
250
|
+
# is still honoured for any host that defines it itself.
|
|
251
|
+
milestones = if respond_to?(:achieved_milestones)
|
|
252
|
+
achieved_milestones
|
|
253
|
+
elsif respond_to?(:earned_milestones)
|
|
254
|
+
earned_milestones
|
|
255
|
+
end
|
|
256
|
+
return false unless milestones
|
|
246
257
|
|
|
247
258
|
required_milestone = feature[:required_milestone]
|
|
248
259
|
return false unless required_milestone
|
|
249
260
|
|
|
250
|
-
|
|
261
|
+
milestones.map(&:to_s).include?(required_milestone.to_s)
|
|
251
262
|
end
|
|
252
263
|
|
|
253
264
|
# Check if engagement-based feature is ready
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
viewport and zooms out to fit the physical screen - everything (text,
|
|
7
7
|
buttons, spacing) looks shrunk even though the CSS itself is correct. %>
|
|
8
8
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
9
|
-
<title><%= Rails.application.class.module_parent.name %> Onboarding</title>
|
|
9
|
+
<title><%= RailsOnboarding.configuration.app_name.presence || Rails.application.class.module_parent.name %> Onboarding</title>
|
|
10
10
|
<%= csrf_meta_tags %>
|
|
11
11
|
<%= csp_meta_tag %>
|
|
12
12
|
|
|
@@ -33,7 +33,8 @@ module RailsOnboarding
|
|
|
33
33
|
include RateLimiting
|
|
34
34
|
include Templates
|
|
35
35
|
|
|
36
|
-
attr_accessor :
|
|
36
|
+
attr_accessor :app_name,
|
|
37
|
+
:user_class_name,
|
|
37
38
|
:include_host_styles,
|
|
38
39
|
:redirect_after_completion,
|
|
39
40
|
:redirect_after_skip,
|
|
@@ -45,6 +46,11 @@ module RailsOnboarding
|
|
|
45
46
|
:admin_user_search
|
|
46
47
|
|
|
47
48
|
def initialize
|
|
49
|
+
# What to call the host product on onboarding pages. Defaults to the Rails
|
|
50
|
+
# application's module name, which is a code identifier and often not what
|
|
51
|
+
# the product is actually called - "Gift" for an app called Gift Posse.
|
|
52
|
+
# nil keeps the derived name.
|
|
53
|
+
@app_name = nil
|
|
48
54
|
@user_class_name = "User"
|
|
49
55
|
@include_host_styles = true # Default to including host app css
|
|
50
56
|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: rails_onboarding
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.8.
|
|
4
|
+
version: 0.8.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- David Lewis
|
|
@@ -282,7 +282,7 @@ licenses:
|
|
|
282
282
|
metadata:
|
|
283
283
|
allowed_push_host: https://rubygems.org
|
|
284
284
|
homepage_uri: https://github.com/bunnahabhain/rails_onboarding
|
|
285
|
-
source_code_uri: https://github.com/bunnahabhain/rails_onboarding/tree/v0.8.
|
|
285
|
+
source_code_uri: https://github.com/bunnahabhain/rails_onboarding/tree/v0.8.5
|
|
286
286
|
changelog_uri: https://github.com/bunnahabhain/rails_onboarding/blob/master/docs/CHANGELOG.md
|
|
287
287
|
rdoc_options: []
|
|
288
288
|
require_paths:
|