playbook_ui 14.3.2.pre.alpha.PBNTR480radiocustomchildrenprop3759 → 14.3.2.pre.alpha.PBNTR490multilevelselect3766

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: cdd1dded7ae1ba871ee3d9c6301c8157a59069e5b30bd4192aa3923cda2f470f
4
- data.tar.gz: f9a6884a3c4fbc00c1cacb9706fcfa02c166c5bcd81c394e37489a953f29b099
3
+ metadata.gz: 56cc8bebe81321d102489cd0ed941908032f49bbe82b696ab050e25a7fcdf606
4
+ data.tar.gz: 188c456256607f3bd8f5e8a54987d42f1b246572ecddd32f673d2ac8b9d5e356
5
5
  SHA512:
6
- metadata.gz: cb419c98c99095e28a2b17fef5e5f9a5dd258a2d75b26d46a34182af3c56396f3ac60de61e40f9fec9afc6dd38ef00341e54f02bc762f9d4eae31d5d5b783550
7
- data.tar.gz: ad8e3e17e90704d2f8ee7f4ff4665e0a195cfc83c0a4908ae19f8cbf3edfbd79930a221d23ba714b9272053c1514e95753dfad4b56722ce1bbbfcb44ac2d07a2
6
+ metadata.gz: 5aa3f3d6515004b93eda38afdc9e0d36c863b886772c19f24da5612840367a6781bcf9882cbf3751f3a4fedd3e2bfe327566e01d4ccebec57f373c039812b17a
7
+ data.tar.gz: ce83ff82f4e7c1ebe2ca8a917d15200d5c5280d693ded092ef1435bfaa3fe510edcf0475429e8e8de0b5530ed5924b95165e1fcb80a0230c9848545c09f60a43
@@ -9,7 +9,7 @@ module Playbook
9
9
  prop :border, type: Playbook::Props::Boolean,
10
10
  default: false
11
11
  prop :fixed_width, type: Playbook::Props::Boolean,
12
- default: false
12
+ default: true
13
13
  prop :flip, type: Playbook::Props::Enum,
14
14
  values: ["horizontal", "vertical", "both", nil],
15
15
  default: nil
@@ -258,7 +258,6 @@ const MultiLevelSelect = (props: MultiLevelSelectProps) => {
258
258
 
259
259
  // Handle click on input wrapper(entire div with pills, typeahead, etc) so it doesn't close when input or form pill is clicked
260
260
  const handleInputWrapperClick = (e: any) => {
261
- e.stopPropagation()
262
261
  if (
263
262
  e.target.id === "multiselect_input" ||
264
263
  e.target.classList.contains("pb_form_pill_tag")
@@ -266,6 +265,7 @@ const MultiLevelSelect = (props: MultiLevelSelectProps) => {
266
265
  return
267
266
  }
268
267
  setIsDropdownClosed(!isDropdownClosed)
268
+ e.stopPropagation()
269
269
  }
270
270
 
271
271
  // Main function to handle any click inside dropdown
@@ -7,7 +7,6 @@ examples:
7
7
  - radio_options: With Options
8
8
  - radio_alignment: Alignment
9
9
  - radio_disabled: Disabled
10
- - radio_custom_children: Custom Children
11
10
 
12
11
  react:
13
12
  - radio_default: Default
@@ -1,42 +1,18 @@
1
- <% if object.custom_children %>
2
- <div data-pb-radio-children="true">
3
- <%= pb_rails("flex", props: {
4
- aria: object.aria,
5
- align: "center",
6
- class: object.classname,
7
- cursor: "pointer",
8
- **combined_html_options
9
- }) do %>
10
- <%= content_tag(:label,
11
- checked: object.checked,
12
- class: object.classname,
13
- data: object.data,
14
- id: object.id,
15
- value: object.value,
16
- **combined_html_options) do %>
17
- <%= input %>
18
- <span class="pb_radio_button"></span>
19
- <% end %>
20
- <div data-pb-radio-children-wrapper="true"> <%= content %> </div>
21
- <% end %>
22
- </div>
23
- <% else %>
24
- <%= content_tag(:label,
25
- aria: object.aria,
26
- checked: object.checked,
27
- class: object.classname,
28
- data: object.data,
29
- id: object.id,
30
- value: object.value,
31
- **combined_html_options) do %>
1
+ <%= content_tag(:label,
2
+ aria: object.aria,
3
+ checked: object.checked,
4
+ class: object.classname,
5
+ data: object.data,
6
+ id: object.id,
7
+ value: object.value,
8
+ **combined_html_options) do %>
32
9
 
33
- <% if content.present? %>
34
- <%= content %>
35
- <% else %>
36
- <%= radio_button_tag object.name, object.value, object.selected, object.input_options %>
37
- <% end %>
10
+ <% if content.present? %>
11
+ <%= content %>
12
+ <% else %>
13
+ <%= radio_button_tag object.name, object.value, object.selected, object.input_options %>
14
+ <% end %>
38
15
 
39
- <span class="pb_radio_button"></span>
40
- <%= pb_rails("body", props: { status: object.body_status, text: object.text, dark: object.dark }) %>
41
- <% end %>
42
- <% end %>
16
+ <span class="pb_radio_button"></span>
17
+ <%= pb_rails("body", props: { status: object.body_status, text: object.text, dark: object.dark }) %>
18
+ <% end %>
@@ -20,8 +20,6 @@ module Playbook
20
20
  default: "Radio Text"
21
21
  prop :value, type: Playbook::Props::String,
22
22
  default: "radio_text"
23
- prop :custom_children, type: Playbook::Props::Boolean,
24
- default: false
25
23
 
26
24
  def classname
27
25
  generate_classname("pb_radio_kit") + error_class + alignment_class
@@ -36,7 +34,7 @@ module Playbook
36
34
  end
37
35
 
38
36
  def input
39
- radio_button_tag(name, value, checked, input_options.merge(disabled: disabled || input_options[:disabled]))
37
+ radio_button_tag(name, value, checked, input_options.merge(disabled: disabled))
40
38
  end
41
39
 
42
40
  private