rails_onboarding 0.8.6 → 0.8.7

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: 1eb640c48091d5cc3028c5563bbdd22d3b5a2b2a32e3ce6079f20afb99b14cec
4
- data.tar.gz: b85af1963ce35f84da739613dc6168179ea0e548bc90d11a91e7a01be2c5c484
3
+ metadata.gz: 735f78958744dc1965b60dbbe1fd195bcf252c179b7ef5b582462410ec1af3ea
4
+ data.tar.gz: 302e224c0b4c63800c7f7eec5f49a63063dd4cbf8bd47b5d739a897d021f5d07
5
5
  SHA512:
6
- metadata.gz: 1f76a6f1b8d8ec877f5efe98026c2f75039d6a6102bc3eda76cbdbabb36d9926b9b2fe3f88044e0a515fcb76053eb087d7929b7fa62799acdd5ab2abafacb476
7
- data.tar.gz: b58edc5a568ad4691982422fe8a21c557d074fed14c91990fbda23ef2e8cdd9584eee8b54241ac5996f97578eeffdbdcd6250c5812d8880e2753ed644893fab8
6
+ metadata.gz: dddebe786b830ba2ae4fe7cfaa0897e2eeec2b0a35b697ca9ffdf8a62df56702c4d4b86580396e40c19a9c15fa49b3fdf0ff94e5afde9c94008755a62de47123
7
+ data.tar.gz: d8c1a9c239d9567f9474563d196163c3108d65cdd260a4278e41065469db5136b9faa8d72cf328a969bcea472c81856bb31ab9d9514774f63c89c28fc34a9b6b
@@ -19,12 +19,46 @@
19
19
  font-size: 2.5rem;
20
20
  font-weight: 700;
21
21
  color: #2c3e50;
22
- margin: 0;
22
+ margin: 0 1rem;
23
+ }
24
+
25
+ .milestone-header-actions {
26
+ display: flex;
27
+ align-items: center;
28
+ gap: 1.5rem;
23
29
  }
24
30
 
25
31
  .milestone-stats {
26
32
  display: flex;
27
- gap: 2rem;
33
+ gap: 1rem;
34
+ }
35
+
36
+ .milestone-home-link {
37
+ display: inline-flex;
38
+ align-items: center;
39
+ gap: 0.5rem;
40
+ padding: 0.75rem 1.25rem;
41
+ border: 2px solid #e5e7eb;
42
+ border-radius: 12px;
43
+ background: white;
44
+ color: #2c3e50;
45
+ font-size: 0.9375rem;
46
+ font-weight: 600;
47
+ text-decoration: none;
48
+ white-space: nowrap;
49
+ transition: border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
50
+ }
51
+
52
+ .milestone-home-link:hover,
53
+ .milestone-home-link:focus-visible {
54
+ border-color: #667eea;
55
+ color: #667eea;
56
+ transform: translateY(-1px);
57
+ }
58
+
59
+ .milestone-home-icon {
60
+ font-size: 1.125rem;
61
+ line-height: 1;
28
62
  }
29
63
 
30
64
  .total-points,
@@ -490,6 +524,11 @@
490
524
  text-align: center;
491
525
  }
492
526
 
527
+ .milestone-header-actions {
528
+ flex-direction: column;
529
+ gap: 1rem;
530
+ }
531
+
493
532
  .milestone-stats {
494
533
  justify-content: center;
495
534
  }
@@ -6,15 +6,27 @@
6
6
  data-milestone-dashboard-milestones-path-value="<%= milestones_path %>">
7
7
  <div class="milestone-header">
8
8
  <h1 class="milestone-title">🏆 Your Achievements</h1>
9
- <div class="milestone-stats">
10
- <div class="total-points">
11
- <span class="points-value" data-milestone-dashboard-target="pointsValue"><%= @total_points %></span>
12
- <span class="points-label">Total Points</span>
13
- </div>
14
- <div class="achievement-count">
15
- <span class="count-value" data-milestone-dashboard-target="countValue"><%= @achieved_milestones.length %></span>
16
- <span class="count-label">Milestones</span>
9
+ <div class="milestone-header-actions">
10
+ <div class="milestone-stats">
11
+ <div class="total-points">
12
+ <span class="points-value" data-milestone-dashboard-target="pointsValue"><%= @total_points %></span>
13
+ <span class="points-label">Total Points</span>
14
+ </div>
15
+ <div class="achievement-count">
16
+ <span class="count-value" data-milestone-dashboard-target="countValue"><%= @achieved_milestones.length %></span>
17
+ <span class="count-label">Milestones</span>
18
+ </div>
17
19
  </div>
20
+
21
+ <%# Leaves the engine for the host app's root. Guarded because a host app
22
+ is not required to define a root route, and a missing one here would
23
+ break the whole page - same reasoning as the admin layout's Home link. %>
24
+ <% if main_app.respond_to?(:root_path) %>
25
+ <%= link_to main_app.root_path, class: "milestone-home-link" do %>
26
+ <span class="milestone-home-icon" aria-hidden="true">🏠</span>
27
+ Home
28
+ <% end %>
29
+ <% end %>
18
30
  </div>
19
31
  </div>
20
32
 
@@ -1,3 +1,3 @@
1
1
  module RailsOnboarding
2
- VERSION = "0.8.6"
2
+ VERSION = "0.8.7"
3
3
  end
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.6
4
+ version: 0.8.7
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.6
285
+ source_code_uri: https://github.com/bunnahabhain/rails_onboarding/tree/v0.8.7
286
286
  changelog_uri: https://github.com/bunnahabhain/rails_onboarding/blob/master/docs/CHANGELOG.md
287
287
  rdoc_options: []
288
288
  require_paths: