bullet_train-themes 1.3.21 → 1.3.22

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: 26307dd4e92314814e835b8c9220e15f36f135f58fe9ec2ca19394c867ee270e
4
- data.tar.gz: 336891ff14f53846be067f93d56e5a696d191cf91e64a9fbd969aac61f79a752
3
+ metadata.gz: ee048dfd5be441574396fde0a145fed25bdf0693ff49b3bc6d7da9900a9323be
4
+ data.tar.gz: 752dd1fe7f4514110a62ab00e1e690cec6623508a045ba9f21d3d980df806550
5
5
  SHA512:
6
- metadata.gz: 97d0c026b256bfdfc1f25b9e981074b922aa01c0549805157122b9f8a3977ae32b1f4194c967ad02d2738eef438f6f9cf74ac926ac791e8949a8e4e2c299ab1b
7
- data.tar.gz: 14f205e04a9e3e8a425277f9fd22a8877a7fe793194c0314c0e9f741d3ebd64f0d2bd3ced5cc93b28ae06fd30b98045179ede0341098af40934bb445059b3a4a
6
+ metadata.gz: 4294e5d49abe2ea0a6fc8cbb1c209e3e0e45e0fc65b42d4a5206a4c6e6801aa021a7c7dbbb62d0a0301494f400918363d1d0b3326c5c4418852e2cc581f1587b
7
+ data.tar.gz: 213bae56d3c3ddb0b851ed192f7bcbb2604e834cefb3d3d7b18e11eb2262283f672b0128a3d9923bb9bf66fcad7b4abf3d27eb72fb93394997c715f38e795152
@@ -0,0 +1,12 @@
1
+ <% object ||= current_attributes_object %>
2
+ <% strategy ||= current_attributes_strategy || :none %>
3
+ <% url ||= nil %>
4
+ <% one_line ||= false %>
5
+
6
+ <% if object.send(attribute).present? && !object.send(attribute).all_blank? %>
7
+ <%= render 'shared/attributes/attribute', object: object, attribute: attribute, strategy: strategy, url: url do %>
8
+ <address class="not-italic">
9
+ <%= address_formatted(object.send(attribute), one_line: one_line) %>
10
+ </address>
11
+ <% end %>
12
+ <% end %>
@@ -21,7 +21,10 @@ else
21
21
  end
22
22
  end
23
23
 
24
- wrapper_options = { data: { controller: stimulus_controller }}
24
+ wrapper_options ||= {}
25
+ wrapper_options[:data] ||= {}
26
+ wrapper_options[:data][:controller] ||= ""
27
+ wrapper_options[:data][:controller] += " #{stimulus_controller}"
25
28
  wrapper_options[:data]["#{stimulus_controller}-enable-search-value"] = true if (other_options[:search] || other_options[:accepts_new])
26
29
  wrapper_options[:data]["#{stimulus_controller}-accepts-new-value"] = true if other_options[:accepts_new]
27
30
  wrapper_options[:data]["#{stimulus_controller}-search-url-value"] = choices_url if choices_url.present?
@@ -39,7 +42,7 @@ html_options[:data].merge!("#{stimulus_controller}-target": 'select')
39
42
 
40
43
  <%= render 'shared/fields/field', form: form, method: method, options: html_options, other_options: other_options do %>
41
44
  <% content_for :field do %>
42
- <%= content_tag :div, data: wrapper_options[:data] do %>
45
+ <%= content_tag :div, wrapper_options do %>
43
46
  <%= form.select method, choices, options, html_options %>
44
47
  <% end %>
45
48
  <% end %>
@@ -1,5 +1,5 @@
1
1
  module BulletTrain
2
2
  module Themes
3
- VERSION = "1.3.21"
3
+ VERSION = "1.3.22"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bullet_train-themes
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.21
4
+ version: 1.3.22
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Culver
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-08-31 00:00:00.000000000 Z
11
+ date: 2023-09-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: standard
@@ -51,6 +51,7 @@ files:
51
51
  - Rakefile
52
52
  - app/assets/config/bullet_train_themes_manifest.js
53
53
  - app/helpers/theme_helper.rb
54
+ - app/views/themes/base/attributes/_address.html.erb
54
55
  - app/views/themes/base/attributes/_attribute.html.erb
55
56
  - app/views/themes/base/attributes/_belongs_to.html.erb
56
57
  - app/views/themes/base/attributes/_block.html.erb