sdr_view_components 0.1.3 → 0.1.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: 16f9c65aca5c79312e48c511e61e6b5181de67e763d85b99185d6b558f726124
4
- data.tar.gz: d1b86d685d6a82e90bfc2974906874f57d717d27d1026605ce62cc8bd33d8b9e
3
+ metadata.gz: 28f0e4265213c174a846910079cc532e2d456078629c013544eecd06b0e88d83
4
+ data.tar.gz: 497c87a1a2169ea061bd51803cfda32bb0299730a2c2af122ddc530886710092
5
5
  SHA512:
6
- metadata.gz: 74181bc2ebb10bb5e0b8113041ed135c8fa2e6d3987de57b3d0e562948232a902b5d134f1fc04c1c85f49871b75cd0871efc0bf905dbfa6a5d2a3f30665d45f8
7
- data.tar.gz: b1910536f68eafa46c193b6b94d0c2671d7f53684c40d42c0e5058bb537f4f78dff23f7785805f84594f8de9095a24ab106758027a1ade39745b1e7ae6295689
6
+ metadata.gz: 70221ccf2a70743c14a040723da70b160520df15e4e4defad42332e77eb2555abe90c1bfec25a4c930429d856579e881f10d03bb3aa37a7ed705967bc7fb0750
7
+ data.tar.gz: ff65042ff456e4551f0e5e8ce16352398655c13f3d1cfa0a1ed76574c863be957da71fd34bdaee0f02ac5317f63f1ca5f2eace593c4ac315860c01173f9e64dc
data/README.md CHANGED
@@ -38,7 +38,7 @@ Supported header variations are `:dark`, `:light`, and `:white` (default is `:li
38
38
  <% end %>
39
39
  <% header.with_primary_navigation_link do %>
40
40
  <%= render SdrViewComponents::Elements::Navigation::DropdownMenuComponent.new(text: 'Logged in: amcollie-preview-dropdown') do |dropdown| %>
41
- <% dropdown.with_link do %>
41
+ <% dropdown.with_item do %>
42
42
  <%= link_to 'Logout', '/Shibboleth.sso/Logout', class: 'dropdown-item' %>
43
43
  <% end %>
44
44
  <% end %>
@@ -6,7 +6,7 @@
6
6
  <%= text %>
7
7
  </button>
8
8
  <ul class="dropdown-menu">
9
- <%= items.map do |item| %>
9
+ <% items.each do |item| %>
10
10
  <li><%= item %></li>
11
11
  <% end %>
12
12
  </ul>
@@ -1,40 +1,34 @@
1
- <style>
2
- .toast:not(.show) {
3
- display: block;
4
- }
5
- </style>
6
- <div class="toast-container position-relative bottom-0 end-0 p-3">
1
+ <div
2
+ class="toast align-items-center show"
3
+ role="alert"
4
+ aria-live="assertive"
5
+ aria-atomic="true"
6
+ >
7
+ <%= tag.div class: toast_body_classes do %>
8
+ <div class="d-flex">
7
9
  <div
8
- class="toast align-items-center"
9
- role="alert"
10
- aria-live="assertive"
11
- aria-atomic="true"
12
- >
13
- <div class="<%= toast_class %>">
14
- <div class="d-flex">
15
- <div
16
- class="bi bi-exclamation-circle-fill fs-3 me-3 align-self-center d-flex justify-content-center"
17
- ></div>
18
- <div>
19
- <div class="fw-semibold"><%= title %> </div>
20
- <div><%= text %></div>
21
- </div>
22
- <div class="me-2 m-auto">
23
- <% if close_text.present? %>
24
- <button
25
- type="button"
26
- class="btn btn-text text-uppercase text-white"
27
- >
28
- <%= close_text %>
29
- </button>
30
- <% end %>
31
- <button
32
- type="button"
33
- class="btn btn-close btn-close-white"
34
- aria-label="Close"
35
- ></button>
36
- </div>
37
- </div>
38
- </div>
10
+ class="bi bi-exclamation-circle-fill fs-3 me-3 align-self-center d-flex justify-content-center"
11
+ ></div>
12
+ <div>
13
+ <div class="fw-semibold"><%= title %> </div>
14
+ <div><%= text %></div>
15
+ </div>
16
+ <div class="me-2 m-auto">
17
+ <% if close_text.present? %>
18
+ <button
19
+ type="button"
20
+ class="btn btn-text text-uppercase text-white"
21
+ >
22
+ <%= close_text %>
23
+ </button>
24
+ <% end %>
25
+ <button
26
+ type="button"
27
+ class="btn btn-close btn-close-white"
28
+ aria-label="Close"
29
+ data-bs-dismiss="toast"
30
+ ></button>
39
31
  </div>
40
32
  </div>
33
+ <% end %>
34
+ </div>
@@ -14,7 +14,7 @@ module SdrViewComponents
14
14
 
15
15
  attr_reader :title, :text, :close_text, :variant
16
16
 
17
- def toast_class
17
+ def toast_body_classes
18
18
  merge_classes([background_color], %w[toast-body text-white])
19
19
  end
20
20
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SdrViewComponents
4
- VERSION = '0.1.3'
4
+ VERSION = '0.1.5'
5
5
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sdr_view_components
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aaron Collier
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-12-10 00:00:00.000000000 Z
10
+ date: 2025-12-11 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: rails