polaris_view_helpers 1.2.2 → 1.2.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2448ca1ba9913f0413b03ce27ccdfd1ff34833553aa15d4838cdd5d3d244a4d8
4
- data.tar.gz: 7b2676af21a0c093426358fa11deee64bc016df35c42a06177365690484cf3ca
3
+ metadata.gz: fac9689210b6815bf6ad86a7e7b58a15b45adb1b201c53f6d942c4fdac7e04b6
4
+ data.tar.gz: da09acc4db0ed923fc852afda548f822de4e0a5f8d45e77b30527434f6d3a677
5
5
  SHA512:
6
- metadata.gz: 196f046e44331e62f4403c254846e4244e93f828c62b044031ab03315b2cbbcb5cdaea4e1a6edec823d1bbb16a9891747a79e2b5bafbda942b456bbccb585664
7
- data.tar.gz: ccec7561b62e3e6b2fae3edbeb0d07a547582ce5d88c4dd7c3597ea714602866782c6d85341ca4a1617c3a45ca2137cc696ac829589a65cdc5fa1ad5438f0af8
6
+ metadata.gz: 7e1b3d57a06acf391d06116121a9555601adc51fd21ef537c9f5fe7d0ad19fb8d9841868f88c12b8ad9f63286d8dd3fee273e3842812fcddb1f6449dc822b8e8
7
+ data.tar.gz: 111b283d891c7d803b9e6f40eb7eaca8044f633901024bc566dba3a4157cd8d230c4d7c1d33e551b53a0783f53751ecc6261277152b8049d524f28a0fcc63293
@@ -1,3 +1,3 @@
1
- <%= link_to link_destination, data: { method: method, remote: remote }, confirm: confirm, class: "Polaris-Button #{additional_classes}", 'data-polaris-unstyled': true do %>
1
+ <%= link_to link_destination, data: { method: method, remote: remote }, confirm: confirm, class: "Polaris-Button #{additional_classes}", target: target, 'data-polaris-unstyled': true do %>
2
2
  <span class="Polaris-Button__Content"><span><%= name || capture(&block) %></span></span>
3
3
  <% end %>
@@ -1,3 +1,4 @@
1
- <%= button_tag type: type, class: "Polaris-Button #{additional_classes}" do %>
1
+ <% data ||= nil %>
2
+ <%= button_tag type: type, class: "Polaris-Button #{additional_classes}", data: data do %>
2
3
  <span class="Polaris-Button__Content"><span><%= name %></span></span>
3
4
  <% end %>
@@ -10,7 +10,7 @@
10
10
  <label class="Polaris-Choice" for="<%= inputname %>">
11
11
  <span class="Polaris-Choice__Control">
12
12
  <span class="Polaris-RadioButton">
13
- <%= form.radio_button attribute, choice[:value], checked: selected == choice[:value], class: 'Polaris-RadioButton__Input', id: inputname %>
13
+ <%= form.radio_button attribute, choice[:value], checked: selected == choice[:value], class: 'Polaris-RadioButton__Input', id: inputname, data: data %>
14
14
  <span class="Polaris-RadioButton__Backdrop"></span>
15
15
  <span class="Polaris-RadioButton__Icon"></span>
16
16
  </span>
@@ -9,7 +9,7 @@
9
9
  </div>
10
10
  <% end %>
11
11
  <div class="Polaris-TextField">
12
- <%= form.send element_type, att, id: "#{form.object.class.name.tableize.singularize}_#{att}", class: "Polaris-TextField__Input", placeholder: options[:placeholder], value: options[:value] || form.object&.send(att) %>
12
+ <%= form.send element_type, att, id: "#{form.object.class.name.tableize.singularize}_#{att}", class: "Polaris-TextField__Input", placeholder: options[:placeholder], value: (options[:value] || form.object&.send(att)), data: options[:data] %>
13
13
  <div class="Polaris-TextField__Backdrop"></div>
14
14
  </div>
15
15
  </div>
@@ -14,7 +14,7 @@ module PolarisViewHelpers
14
14
  "pri-#{SecureRandom.hex(8)}"
15
15
  end
16
16
 
17
- def polaris_choice_list(form:, attribute:, title:, selected:, choices:)
17
+ def polaris_choice_list(form:, attribute:, title:, selected:, choices:, data:)
18
18
  render(
19
19
  partial: 'polaris/choice_list',
20
20
  locals: {
@@ -22,7 +22,8 @@ module PolarisViewHelpers
22
22
  attribute: attribute,
23
23
  title: title,
24
24
  selected: selected,
25
- choices: choices
25
+ choices: choices,
26
+ data: data
26
27
  }
27
28
  )
28
29
  end
@@ -1,3 +1,3 @@
1
1
  module PolarisViewHelpers
2
- VERSION = "1.2.2"
2
+ VERSION = "1.2.5"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: polaris_view_helpers
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.2
4
+ version: 1.2.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jeremy Green
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-02-02 00:00:00.000000000 Z
11
+ date: 2022-08-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails