playbook_ui 14.14.0.pre.alpha.revert4339revert4242play1633displaytitle6456 → 14.14.0.pre.rc.0

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.
Files changed (175) hide show
  1. checksums.yaml +4 -4
  2. data/app/pb_kits/playbook/_playbook.scss +1 -0
  3. data/app/pb_kits/playbook/pb_advanced_table/_advanced_table.scss +0 -3
  4. data/app/pb_kits/playbook/pb_advanced_table/_advanced_table.tsx +5 -6
  5. data/app/pb_kits/playbook/pb_advanced_table/advanced_table.rb +1 -8
  6. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_table_props.html.erb +1 -1
  7. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_table_props_rails.md +1 -3
  8. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_table_props_react.md +1 -1
  9. data/app/pb_kits/playbook/pb_advanced_table/docs/example.yml +0 -2
  10. data/app/pb_kits/playbook/pb_advanced_table/docs/index.js +1 -2
  11. data/app/pb_kits/playbook/pb_avatar_action_button/_avatar_action_button.scss +66 -0
  12. data/app/pb_kits/playbook/pb_avatar_action_button/_avatar_action_button.tsx +98 -0
  13. data/app/pb_kits/playbook/pb_avatar_action_button/avatar_action_button.html.erb +28 -0
  14. data/app/pb_kits/playbook/pb_avatar_action_button/avatar_action_button.rb +42 -0
  15. data/app/pb_kits/playbook/pb_avatar_action_button/docs/_avatar_action_button_actions.html.erb +19 -0
  16. data/app/pb_kits/playbook/pb_avatar_action_button/docs/_avatar_action_button_actions.jsx +26 -0
  17. data/app/pb_kits/playbook/pb_avatar_action_button/docs/_avatar_action_button_default.html.erb +10 -0
  18. data/app/pb_kits/playbook/pb_avatar_action_button/docs/_avatar_action_button_default.jsx +17 -0
  19. data/app/pb_kits/playbook/pb_avatar_action_button/docs/_avatar_action_button_on_click.jsx +19 -0
  20. data/app/pb_kits/playbook/pb_avatar_action_button/docs/_avatar_action_button_onclick.html.erb +16 -0
  21. data/app/pb_kits/playbook/pb_avatar_action_button/docs/_avatar_action_button_placement.html.erb +35 -0
  22. data/app/pb_kits/playbook/pb_avatar_action_button/docs/_avatar_action_button_placement.jsx +42 -0
  23. data/app/pb_kits/playbook/pb_avatar_action_button/docs/_avatar_action_button_tooltip.html.erb +13 -0
  24. data/app/pb_kits/playbook/pb_avatar_action_button/docs/example.yml +15 -0
  25. data/app/pb_kits/playbook/pb_avatar_action_button/docs/index.js +4 -0
  26. data/app/pb_kits/playbook/pb_avatar_action_button/pb_avatar_action_button.test.js +31 -0
  27. data/app/pb_kits/playbook/pb_bar_graph/docs/example.yml +0 -1
  28. data/app/pb_kits/playbook/pb_bar_graph/docs/index.js +0 -1
  29. data/app/pb_kits/playbook/pb_checkbox/_checkbox.tsx +8 -17
  30. data/app/pb_kits/playbook/pb_checkbox/checkbox.test.js +0 -16
  31. data/app/pb_kits/playbook/pb_checkbox/docs/example.yml +1 -2
  32. data/app/pb_kits/playbook/pb_checkbox/docs/index.js +0 -1
  33. data/app/pb_kits/playbook/pb_currency/_currency.tsx +31 -46
  34. data/app/pb_kits/playbook/pb_currency/currency.html.erb +8 -15
  35. data/app/pb_kits/playbook/pb_currency/currency.rb +2 -17
  36. data/app/pb_kits/playbook/pb_currency/docs/example.yml +0 -2
  37. data/app/pb_kits/playbook/pb_currency/docs/index.js +1 -2
  38. data/app/pb_kits/playbook/pb_date_picker/_date_picker.tsx +1 -3
  39. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table.html.erb +2 -2
  40. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table.md +1 -4
  41. data/app/pb_kits/playbook/pb_draggable/docs/example.yml +0 -2
  42. data/app/pb_kits/playbook/pb_draggable/docs/index.js +1 -2
  43. data/app/pb_kits/playbook/pb_draggable/subcomponents/DraggableContainer.tsx +4 -7
  44. data/app/pb_kits/playbook/pb_draggable/subcomponents/DraggableItem.tsx +3 -6
  45. data/app/pb_kits/playbook/pb_drawer/_drawer.scss +8 -32
  46. data/app/pb_kits/playbook/pb_drawer/docs/_drawer_default.html.erb +1 -20
  47. data/app/pb_kits/playbook/pb_drawer/docs/example.yml +0 -5
  48. data/app/pb_kits/playbook/pb_drawer/drawer.html.erb +12 -20
  49. data/app/pb_kits/playbook/pb_drawer/drawer.rb +1 -49
  50. data/app/pb_kits/playbook/pb_form/docs/_form_form_with.html.erb +0 -1
  51. data/app/pb_kits/playbook/pb_form/docs/_form_form_with_validate.html.erb +1 -2
  52. data/app/pb_kits/playbook/pb_icon_button/docs/_icon_button_default.html.erb +2 -1
  53. data/app/pb_kits/playbook/pb_icon_button/docs/example.yml +3 -5
  54. data/app/pb_kits/playbook/pb_icon_button/icon_button.html.erb +1 -1
  55. data/app/pb_kits/playbook/pb_icon_button/icon_button.rb +0 -3
  56. data/app/pb_kits/playbook/pb_multi_level_select/multi_level_select.html.erb +6 -1
  57. data/app/pb_kits/playbook/pb_nav/item.html.erb +19 -7
  58. data/app/pb_kits/playbook/pb_nav/nav.html.erb +8 -3
  59. data/app/pb_kits/playbook/pb_online_status/online_status.html.erb +6 -1
  60. data/app/pb_kits/playbook/pb_overlay/_overlay.tsx +0 -4
  61. data/app/pb_kits/playbook/pb_overlay/docs/example.yml +0 -2
  62. data/app/pb_kits/playbook/pb_overlay/docs/index.js +0 -1
  63. data/app/pb_kits/playbook/pb_overlay/overlay.html.erb +3 -5
  64. data/app/pb_kits/playbook/pb_overlay/overlay.rb +0 -9
  65. data/app/pb_kits/playbook/pb_overlay/subcomponents/_overlay_token.tsx +10 -48
  66. data/app/pb_kits/playbook/pb_popover/popover.html.erb +6 -1
  67. data/app/pb_kits/playbook/pb_progress_pills/_progress_pills.scss +1 -6
  68. data/app/pb_kits/playbook/pb_progress_pills/_progress_pills.tsx +5 -7
  69. data/app/pb_kits/playbook/pb_progress_pills/docs/_progress_pills_default.html.erb +0 -1
  70. data/app/pb_kits/playbook/pb_progress_pills/docs/_progress_pills_default.jsx +0 -7
  71. data/app/pb_kits/playbook/pb_progress_pills/docs/example.yml +0 -2
  72. data/app/pb_kits/playbook/pb_progress_pills/docs/index.js +0 -1
  73. data/app/pb_kits/playbook/pb_progress_pills/progress_pills.html.erb +7 -2
  74. data/app/pb_kits/playbook/pb_progress_pills/progress_pills.rb +0 -6
  75. data/app/pb_kits/playbook/pb_progress_pills/progress_pills.test.js +1 -26
  76. data/app/pb_kits/playbook/pb_progress_simple/progress_simple.html.erb +5 -1
  77. data/app/pb_kits/playbook/pb_progress_step/progress_step.html.erb +5 -1
  78. data/app/pb_kits/playbook/pb_progress_step/progress_step_item.html.erb +7 -3
  79. data/app/pb_kits/playbook/pb_radio/radio.html.erb +11 -6
  80. data/app/pb_kits/playbook/pb_select/select.rb +0 -8
  81. data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible.jsx +1 -1
  82. data/app/pb_kits/playbook/pb_table/docs/example.yml +0 -5
  83. data/app/pb_kits/playbook/pb_table/docs/index.js +1 -3
  84. data/app/pb_kits/playbook/pb_table/index.ts +9 -41
  85. data/app/pb_kits/playbook/pb_table/styles/_collapsible.scss +0 -4
  86. data/app/pb_kits/playbook/pb_table/subcomponents/_table_body.tsx +2 -29
  87. data/app/pb_kits/playbook/pb_table/subcomponents/_table_row.tsx +3 -31
  88. data/app/pb_kits/playbook/pb_table/table_body.html.erb +7 -13
  89. data/app/pb_kits/playbook/pb_table/table_body.rb +0 -2
  90. data/app/pb_kits/playbook/pb_table/table_row.html.erb +7 -14
  91. data/app/pb_kits/playbook/pb_table/table_row.rb +1 -14
  92. data/app/pb_kits/playbook/pb_text_input/docs/_text_input_mask.html.erb +0 -14
  93. data/app/pb_kits/playbook/pb_text_input/index.js +0 -9
  94. data/app/pb_kits/playbook/pb_text_input/text_input.rb +2 -5
  95. data/app/pb_kits/playbook/pb_title/_title.scss +0 -32
  96. data/app/pb_kits/playbook/pb_title/_title.tsx +1 -10
  97. data/app/pb_kits/playbook/pb_title/docs/_title_default.html.erb +2 -1
  98. data/app/pb_kits/playbook/pb_title/docs/_title_default.jsx +1 -1
  99. data/app/pb_kits/playbook/pb_title/docs/example.yml +0 -2
  100. data/app/pb_kits/playbook/pb_title/docs/index.js +0 -1
  101. data/app/pb_kits/playbook/pb_title/title.rb +1 -10
  102. data/app/pb_kits/playbook/pb_tooltip/_tooltip.scss +3 -0
  103. data/app/pb_kits/playbook/pb_tooltip/docs/example.yml +0 -2
  104. data/app/pb_kits/playbook/pb_tooltip/index.js +2 -2
  105. data/app/pb_kits/playbook/pb_tooltip/tooltip.rb +2 -10
  106. data/dist/chunks/{_typeahead-_d2af7Id.js → _typeahead-btjo1UN5.js} +4 -4
  107. data/dist/chunks/_weekday_stacked-TIh9nTmZ.js +45 -0
  108. data/dist/chunks/{lib-Fr78pbpF.js → lib-DjpLC8uO.js} +2 -2
  109. data/dist/chunks/{pb_form_validation-CN51bfsD.js → pb_form_validation-S56UaHZl.js} +1 -1
  110. data/dist/chunks/vendor.js +1 -1
  111. data/dist/menu.yml +10 -3
  112. data/dist/playbook-doc.js +1 -1
  113. data/dist/playbook-rails-react-bindings.js +1 -1
  114. data/dist/playbook-rails.js +1 -1
  115. data/dist/playbook.css +1 -1
  116. data/lib/playbook/forms/builder.rb +0 -1
  117. data/lib/playbook/version.rb +2 -2
  118. metadata +23 -62
  119. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_headers_custom_cell.jsx +0 -75
  120. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_table_props_sticky_header.html.erb +0 -33
  121. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_table_props_sticky_header_rails.md +0 -3
  122. data/app/pb_kits/playbook/pb_bar_graph/BarGraphStyles.scss +0 -58
  123. data/app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_pb_styles.jsx +0 -64
  124. data/app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_pb_styles.md +0 -1
  125. data/app/pb_kits/playbook/pb_checkbox/docs/_checkbox_react_hook.jsx +0 -69
  126. data/app/pb_kits/playbook/pb_checkbox/docs/_checkbox_react_hook.md +0 -1
  127. data/app/pb_kits/playbook/pb_currency/docs/_currency_null_display.html.erb +0 -22
  128. data/app/pb_kits/playbook/pb_currency/docs/_currency_null_display.jsx +0 -34
  129. data/app/pb_kits/playbook/pb_currency/docs/_currency_null_display_rails.md +0 -1
  130. data/app/pb_kits/playbook/pb_currency/docs/_currency_null_display_react.md +0 -1
  131. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table_react.jsx +0 -90
  132. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table_react.md +0 -5
  133. data/app/pb_kits/playbook/pb_drawer/docs/_drawer_behavior.html.erb +0 -8
  134. data/app/pb_kits/playbook/pb_drawer/docs/_drawer_borders.html.erb +0 -33
  135. data/app/pb_kits/playbook/pb_drawer/docs/_drawer_breakpoints.html.erb +0 -0
  136. data/app/pb_kits/playbook/pb_drawer/docs/_drawer_menu.html.erb +0 -24
  137. data/app/pb_kits/playbook/pb_drawer/docs/_drawer_overlay.html.erb +0 -21
  138. data/app/pb_kits/playbook/pb_drawer/docs/_drawer_overlay.md +0 -1
  139. data/app/pb_kits/playbook/pb_drawer/docs/_drawer_sizes.html.erb +0 -49
  140. data/app/pb_kits/playbook/pb_drawer/index.js +0 -257
  141. data/app/pb_kits/playbook/pb_icon_button/_icon_button.tsx +0 -71
  142. data/app/pb_kits/playbook/pb_icon_button/docs/_icon_button_default.jsx +0 -17
  143. data/app/pb_kits/playbook/pb_icon_button/docs/_icon_button_sizes.html.erb +0 -27
  144. data/app/pb_kits/playbook/pb_icon_button/docs/_icon_button_sizes.jsx +0 -61
  145. data/app/pb_kits/playbook/pb_icon_button/docs/index.js +0 -2
  146. data/app/pb_kits/playbook/pb_icon_button/icon_button.test.jsx +0 -39
  147. data/app/pb_kits/playbook/pb_overlay/docs/_overlay_vertical_dynamic_multi_directional.html.erb +0 -11
  148. data/app/pb_kits/playbook/pb_overlay/docs/_overlay_vertical_dynamic_multi_directional.jsx +0 -37
  149. data/app/pb_kits/playbook/pb_overlay/docs/_overlay_vertical_dynamic_multi_directional.md +0 -1
  150. data/app/pb_kits/playbook/pb_overlay/docs/_overlay_vertical_dynamic_multi_directional_react.md +0 -1
  151. data/app/pb_kits/playbook/pb_overlay/index.js +0 -61
  152. data/app/pb_kits/playbook/pb_progress_pills/docs/_progress_pills_default.md +0 -1
  153. data/app/pb_kits/playbook/pb_progress_pills/docs/_progress_pills_full_width.html.erb +0 -1
  154. data/app/pb_kits/playbook/pb_progress_pills/docs/_progress_pills_full_width.jsx +0 -18
  155. data/app/pb_kits/playbook/pb_progress_pills/docs/_progress_pills_full_width_rails.md +0 -1
  156. data/app/pb_kits/playbook/pb_progress_pills/docs/_progress_pills_full_width_react.md +0 -1
  157. data/app/pb_kits/playbook/pb_select/index.js +0 -38
  158. data/app/pb_kits/playbook/pb_table/docs/_table_with_clickable_rows.html.erb +0 -47
  159. data/app/pb_kits/playbook/pb_table/docs/_table_with_clickable_rows.jsx +0 -88
  160. data/app/pb_kits/playbook/pb_table/docs/_table_with_clickable_rows.md +0 -1
  161. data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible_with_custom_click.html.erb +0 -51
  162. data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible_with_custom_click_rails.md +0 -2
  163. data/app/pb_kits/playbook/pb_table/docs/_table_with_selectable_rows.html.erb +0 -96
  164. data/app/pb_kits/playbook/pb_table/docs/_table_with_selectable_rows.jsx +0 -101
  165. data/app/pb_kits/playbook/pb_table/docs/_table_with_selectable_rows.md +0 -1
  166. data/app/pb_kits/playbook/pb_title/docs/_title_display_size.html.erb +0 -7
  167. data/app/pb_kits/playbook/pb_title/docs/_title_display_size.jsx +0 -54
  168. data/app/pb_kits/playbook/pb_title/docs/_title_display_size.md +0 -1
  169. data/app/pb_kits/playbook/pb_tooltip/docs/_tooltip_delay_rails.html.erb +0 -39
  170. data/app/pb_kits/playbook/pb_tooltip/docs/_tooltip_delay_rails.md +0 -3
  171. data/app/pb_kits/playbook/pb_tooltip/docs/_tooltip_interaction.html.erb +0 -26
  172. data/app/pb_kits/playbook/pb_tooltip/floating_ui.js +0 -282
  173. data/dist/chunks/_weekday_stacked-BZe1DgW-.js +0 -45
  174. data/lib/playbook/forms/builder/time_zone_select_field.rb +0 -19
  175. /data/app/pb_kits/playbook/pb_table/docs/{_table_with_collapsible_with_custom_click_react.md → _table_with_collapsible_with_custom_click.md} +0 -0
@@ -32,12 +32,11 @@
32
32
  <%= form.url_field :example_url_field_validation, props: { label: true, required: true } %>
33
33
  <%= form.text_area :example_text_area_validation, props: { label: true, required: true } %>
34
34
  <%= form.dropdown_field :example_dropdown_validation, props: { label: true, options: example_dropdown_options, required: true } %>
35
- <%= form.select :example_select_validation, [ ["Yes", 1], ["No", 2] ], props: { label: true, blank_selection: "Select One...", required: true, validation_message: "Please, select an option." } %>
35
+ <%= form.select :example_select_validation, [ ["Yes", 1], ["No", 2] ], props: { label: true, blank_selection: "Select One...", required: true } %>
36
36
  <%= form.collection_select :example_collection_select_validation, example_collection, :value, :name, props: { label: true, blank_selection: "Select One...", required: true } %>
37
37
  <%= form.check_box :example_checkbox, props: { text: "Example Checkbox", label: true, required: true } %>
38
38
  <%= form.date_picker :example_date_picker_2, props: { label: true, required: true } %>
39
39
  <%= form.star_rating_field :example_star_rating_validation, props: { variant: "interactive", label: true, required: true } %>
40
- <%= form.time_zone_select_field :example_time_zone_select, ActiveSupport::TimeZone.us_zones, { default: "Eastern Time (US & Canada)" }, props: { label: true, blank_selection: "Select a Time Zone...", required: true } %>
41
40
 
42
41
  <%= form.actions do |action| %>
43
42
  <%= action.submit %>
@@ -1,2 +1,3 @@
1
1
  <%= pb_rails("icon_button") %>
2
- <%= pb_rails("icon_button", props: {variant: "link", margin_top: "md" }) %>
2
+ </br>
3
+ <%= pb_rails("icon_button", props: {variant: "link"}) %>
@@ -2,8 +2,6 @@ examples:
2
2
 
3
3
  rails:
4
4
  - icon_button_default: Default
5
- - icon_button_sizes: Sizes
6
-
7
- react:
8
- - icon_button_default: Default
9
- - icon_button_sizes: Sizes
5
+
6
+
7
+
@@ -8,7 +8,7 @@
8
8
  <%= pb_rails("icon", props: { icon: object.icon,
9
9
  fixed_width: true,
10
10
  dark: object.dark,
11
- size: object.size,
11
+ size: "2x",
12
12
  color: "text_lt_default",
13
13
  classname: "icon_button_icon",
14
14
  padding_x: "xxs", padding_y: "xs" }) %>
@@ -14,9 +14,6 @@ module Playbook
14
14
  prop :variant, type: Playbook::Props::Enum,
15
15
  values: %w[default link],
16
16
  default: "default"
17
- prop :size, type: Playbook::Props::Enum,
18
- values: %w[1x 2x 3x 4x 5x 6x 7x 8x 9x 10x xs sm lg],
19
- default: "2x"
20
17
  def classname
21
18
  generate_classname("pb_icon_button_kit", variant)
22
19
  end
@@ -1,3 +1,8 @@
1
- <%= pb_content_tag do %>
1
+ <%= content_tag(:div,
2
+ aria: object.aria,
3
+ data: object.data,
4
+ id: object.id,
5
+ class: object.classname,
6
+ **combined_html_options) do %>
2
7
  <%= react_component("MultiLevelSelect", object.multi_level_select_options) %>
3
8
  <% end %>
@@ -1,9 +1,15 @@
1
1
  <% if object.collapsible %>
2
2
  <%= pb_rails("collapsible", props: { name: "collapsible-nav-example", classname: object.collapsible_nav_classname }) do %>
3
3
  <%= pb_rails("collapsible/collapsible_main", props: { name: "default-collapsible-nav", icon: object.collapsible_icons, size: "xs", dark: object.dark, classname:object.margin_classes }) do %>
4
- <%= pb_content_tag( object.tag,
5
- href: object.link && object.link,
6
- target: object.link && object.target
4
+ <%= content_tag(object.tag,
5
+ aria: object.aria,
6
+ class: object.classname,
7
+ data: object.data,
8
+ dark: object.dark,
9
+ id: object.id,
10
+ href: object.link && object.link,
11
+ target: object.link && object.target,
12
+ **combined_html_options
7
13
  ) do %>
8
14
  <% if object.image_url %>
9
15
  <%= pb_rails("image", props: { url: object.image_url, classname: "pb_nav_img_wrapper_collapsible" }) %>
@@ -14,16 +20,22 @@
14
20
  <span class="pb_nav_list_item_text_collapsible">
15
21
  <%= object.text %>
16
22
  </span>
17
- <% end %>
23
+ <% end %>
18
24
  <% end %>
19
25
  <%= pb_rails("collapsible/collapsible_content", props: {collapsed: object.collapsed}) do %>
20
26
  <%= content.presence %>
21
27
  <% end %>
22
28
  <% end %>
23
29
  <% else %>
24
- <%= pb_content_tag( object.tag,
25
- href: object.link && object.link,
26
- target: object.link && object.target
30
+ <%= content_tag(object.tag,
31
+ aria: object.aria,
32
+ class: object.classname,
33
+ **combined_html_options,
34
+ data: object.data,
35
+ dark: object.dark,
36
+ id: object.id,
37
+ href: object.link && object.link,
38
+ target: object.link && object.target
27
39
  ) do %>
28
40
  <% if object.image_url %>
29
41
  <%= pb_rails("image", props: { url: object.image_url, classname: "pb_nav_img_wrapper" }) %>
@@ -1,7 +1,12 @@
1
- <%= pb_content_tag(:nav) do %>
1
+ <%= content_tag(:nav,
2
+ aria: object.aria,
3
+ class: object.classname,
4
+ data: object.data,
5
+ id: object.id,
6
+ **combined_html_options) do %>
2
7
  <% if object.title %>
3
- <%= pb_content_tag do %>
4
- <%= pb_content_tag(:a) do %>
8
+ <%= content_tag(:div, class: "pb_nav_list_title") do %>
9
+ <%= content_tag(:a, class: "pb_nav_list_item_link_text", href: object.link) do %>
5
10
  <%= pb_rails("caption", props: { text: object.title, dark: dark }) %>
6
11
  <% end %>
7
12
  <% end %>
@@ -1,2 +1,7 @@
1
- <%= pb_content_tag do %>
1
+ <%= content_tag(:div,
2
+ aria: object.aria.merge!(label: object.status),
3
+ class: object.classname,
4
+ data: object.data,
5
+ id: object.id,
6
+ **combined_html_options) do %>
2
7
  <% end %>
@@ -8,7 +8,6 @@ import OverlayToken from './subcomponents/_overlay_token'
8
8
  export type OverlayChildrenProps = {
9
9
  children: React.ReactNode[] | React.ReactNode,
10
10
  color: "card_light" | "bg_light" | "card_dark" | "bg_dark",
11
- dynamic?: boolean,
12
11
  position: string,
13
12
  size: string,
14
13
  }
@@ -19,7 +18,6 @@ type OverlayProps = {
19
18
  children: React.ReactNode[] | React.ReactNode,
20
19
  color: "card_light" | "bg_light" | "card_dark" | "bg_dark",
21
20
  data?: { [key: string]: string },
22
- dynamic?: false,
23
21
  htmlOptions?: { [key: string]: string | number | boolean | (() => void) },
24
22
  id?: string,
25
23
  layout: { [key: string]: string },
@@ -32,7 +30,6 @@ const Overlay = (props: OverlayProps) => {
32
30
  children,
33
31
  color = "card_light",
34
32
  data = {},
35
- dynamic = false,
36
33
  htmlOptions = {},
37
34
  id,
38
35
  layout = { "bottom": "full" },
@@ -72,7 +69,6 @@ const Overlay = (props: OverlayProps) => {
72
69
  }) : OverlayToken({
73
70
  children,
74
71
  color,
75
- dynamic: dynamic,
76
72
  position: getPosition(),
77
73
  size: getSize()
78
74
  })
@@ -2,11 +2,9 @@ examples:
2
2
  react:
3
3
  - overlay_default: Default
4
4
  - overlay_multi_directional: Multi-directional
5
- - overlay_vertical_dynamic_multi_directional: Vertical Dynamic Multi-directional
6
5
  - overlay_toggle: Toggle
7
6
 
8
7
  rails:
9
8
  - overlay_default: Default
10
9
  - overlay_multi_directional: Multi-directional
11
- - overlay_vertical_dynamic_multi_directional: Vertical Dynamic Multi-directional
12
10
  - overlay_toggle: Toggle
@@ -1,4 +1,3 @@
1
1
  export { default as OverlayDefault } from './_overlay_default.jsx'
2
2
  export { default as OverlayMultiDirectional } from './_overlay_multi_directional.jsx'
3
3
  export { default as OverlayToggle } from './_overlay_toggle.jsx'
4
- export { default as OverlayVerticalDynamicMultiDirectional } from './_overlay_vertical_dynamic_multi_directional.jsx'
@@ -16,14 +16,12 @@ id: object.id,
16
16
  <% end %>
17
17
 
18
18
  <% else %>
19
- <div class="<%= previous_overlay_class_name %>" data-previous-overlay-classname="<%= previous_overlay_class_name %>"></div>
19
+ <div class="<%= previous_overlay_class_name %>"></div>
20
20
 
21
- <div data-overlay-scroll-element="true">
22
- <%= content.presence %>
23
- </div>
21
+ <%= content.presence %>
24
22
 
25
23
  <% if has_subsequent_overlay %>
26
- <div class="<%= subsequent_overlay_class_name %>" data-subsequent-overlay-classname="<%= subsequent_overlay_class_name %>"></div>
24
+ <div class="<%= subsequent_overlay_class_name %>"></div>
27
25
  <% end %>
28
26
  <% end %>
29
27
  <% end %>
@@ -8,8 +8,6 @@ module Playbook
8
8
  default: "card_light"
9
9
  prop :layout, type: Playbook::Props::HashProp,
10
10
  default: { "bottom": "full" }
11
- prop :dynamic, type: Playbook::Props::Boolean,
12
- default: false
13
11
 
14
12
  def classname
15
13
  generate_classname("pb_overlay")
@@ -107,13 +105,6 @@ module Playbook
107
105
  "bg_dark": "#0a0527",
108
106
  }
109
107
  end
110
-
111
- def data_attributes
112
- data ||= {}
113
- data.merge!("data-pb-overlay" => true)
114
- data.merge!("data-overlay-dynamic" => true) if dynamic
115
- data
116
- end
117
108
  end
118
109
  end
119
110
  end
@@ -1,5 +1,5 @@
1
- import React, { useRef, useEffect, useState } from 'react';
2
- import { OverlayChildrenProps } from '../_overlay';
1
+ import React from 'react'
2
+ import { OverlayChildrenProps } from '../_overlay'
3
3
 
4
4
  const previousOverlayDirectionMap: { [key: string]: string } = {
5
5
  "x": "left",
@@ -15,40 +15,11 @@ const OverlayToken = (props: OverlayChildrenProps) => {
15
15
  const {
16
16
  children,
17
17
  color,
18
- dynamic,
19
18
  position,
20
19
  size,
21
20
  } = props
22
21
 
23
- const scrollContainerRef = useRef<HTMLDivElement>(null);
24
- const [isAtStart, setIsAtStart] = useState(true);
25
- const [isAtEnd, setIsAtEnd] = useState(false);
26
-
27
-
28
- const handleScroll = () => {
29
- const container = scrollContainerRef.current;
30
- if (container) {
31
- const { scrollLeft, scrollWidth, clientWidth } = container;
32
- const atStart = scrollLeft === 0;
33
- const atEnd = scrollLeft + clientWidth >= scrollWidth - 1;
34
-
35
- setIsAtStart(atStart);
36
- setIsAtEnd(atEnd);
37
- }
38
- };
39
-
40
- useEffect(() => {
41
- const container = scrollContainerRef.current;
42
- if (container) {
43
- container.addEventListener('scroll', handleScroll);
44
- handleScroll();
45
- return () => {
46
- container.removeEventListener('scroll', handleScroll);
47
- };
48
- }
49
- }, []);
50
-
51
- const hasSubsequentOverlay = position === "x" || position === "y";
22
+ const hasSubsequentOverlay = position === "x" || position === "y"
52
23
 
53
24
  const getPreviousOverlayDirection = () => {
54
25
  return hasSubsequentOverlay ? previousOverlayDirectionMap[position] : position
@@ -63,24 +34,15 @@ const OverlayToken = (props: OverlayChildrenProps) => {
63
34
 
64
35
  return (
65
36
  <>
66
- <div className={dynamic ? isAtStart ? '' : previousOverlayClassName : previousOverlayClassName} />
67
- {dynamic ?
68
- <div
69
- ref={scrollContainerRef}
70
- style={{
71
- overflowX: 'auto',
72
- }}
73
- >
74
- {children}
75
- </div>
76
- :
77
- children
78
- }
79
- {hasSubsequentOverlay &&
80
- <div className={dynamic ? isAtEnd ? '' : subsequentOverlayClassName : subsequentOverlayClassName} />
37
+ <div className={previousOverlayClassName} />
38
+
39
+ {children}
40
+
41
+ { hasSubsequentOverlay &&
42
+ <div className={subsequentOverlayClassName} />
81
43
  }
82
44
  </>
83
45
  )
84
46
  }
85
47
 
86
- export default OverlayToken;
48
+ export default OverlayToken
@@ -1,4 +1,9 @@
1
- <%= pb_content_tag do %>
1
+ <%= content_tag(:div,
2
+ aria: object.aria,
3
+ class: object.classname,
4
+ data: object.data,
5
+ id: object.id,
6
+ **combined_html_options) do %>
2
7
  <div class="pb_popover_tooltip hide" id="<%= object.tooltip_id %>" role="tooltip" style="<%= object.z_index_helper %>">
3
8
  <div class="pb_popover_body <%= object.width_height_class_helper %> <%= object.popover_spacing_helper %>" style="<%= object.width_height_helper %>">
4
9
  <%= content.presence %>
@@ -3,8 +3,7 @@
3
3
  @import "../tokens/border_radius";
4
4
 
5
5
  @mixin pb_progress_pill {
6
- width: 100%;
7
- max-width: 45px;
6
+ width: 45px;
8
7
  height: 4px;
9
8
  border-radius: $border_rad_light;
10
9
  margin-right: $space_xs;
@@ -28,10 +27,6 @@
28
27
  [class*=pb_progress_pill] {
29
28
  @include pb_progress_pill;
30
29
 
31
- &.full_width_pill {
32
- max-width: none;
33
- }
34
-
35
30
  &[class*=_inactive] {
36
31
  background-color: $border_light;
37
32
  &.dark {
@@ -13,7 +13,6 @@ type ProgressPillsProps = {
13
13
  className?: string,
14
14
  data?: { [key: string]: string },
15
15
  dark?: boolean,
16
- fullWidthPill?: boolean,
17
16
  htmlOptions?: {[key: string]: string | number | boolean | (() => void)},
18
17
  id?: string,
19
18
  steps?: number,
@@ -21,19 +20,19 @@ type ProgressPillsProps = {
21
20
  value?: string,
22
21
  }
23
22
 
24
- const ProgressPill = ({ active, dark, steps: step, fullWidthPill }: ProgressPillsProps) => (
23
+ const ProgressPill = ({ active, dark, steps: step }: ProgressPillsProps) => (
25
24
  <div
26
25
  className={`pb_progress_pill${step <= active ? '_active' : '_inactive'}${dark ? ' dark' : ''
27
- }${fullWidthPill ? ' full_width_pill' : ''}`}
26
+ }`}
28
27
  key={step}
29
28
  />
30
29
  )
31
30
 
32
- const showSteps = (steps: number, active: number, dark: boolean, fullWidthPill: boolean) => {
31
+ const showSteps = (steps: number, active: number, dark: boolean) => {
33
32
  const items = []
34
33
 
35
34
  for (let step = 1; step <= steps; step++) {
36
- items.push(ProgressPill({ steps: step, active, dark, fullWidthPill }))
35
+ items.push(ProgressPill({ steps: step, active, dark }))
37
36
  }
38
37
 
39
38
  return items
@@ -45,7 +44,6 @@ const ProgressPills = (props: ProgressPillsProps) => {
45
44
  aria = { hidden: 'true' },
46
45
  className,
47
46
  data = {},
48
- fullWidthPill = false,
49
47
  htmlOptions = {},
50
48
  id,
51
49
  steps = 3,
@@ -81,7 +79,7 @@ const ProgressPills = (props: ProgressPillsProps) => {
81
79
  text={value}
82
80
  />
83
81
  </div>}
84
- <div className="progress_pills">{showSteps(steps, active, dark, fullWidthPill)}</div>
82
+ <div className="progress_pills">{showSteps(steps, active, dark)}</div>
85
83
  </div>
86
84
  )
87
85
  }
@@ -1,2 +1 @@
1
1
  <%= pb_rails("progress_pills", props: { aria: { label: "2 out of 3 steps complete" }, steps: 3, active: 2 }) %>
2
- <%= pb_rails("progress_pills", props: { aria: { label: "9 out of 18 steps complete" }, steps: 18, active: 9, margin_top: "md" }) %>
@@ -10,13 +10,6 @@ const ProgressPillsDefault = (props) => {
10
10
  steps={3}
11
11
  {...props}
12
12
  />
13
- <ProgressPills
14
- active={9}
15
- aria={{ label: '9 out of 18 steps complete' }}
16
- marginTop="md"
17
- steps={18}
18
- {...props}
19
- />
20
13
  </>
21
14
  )
22
15
  }
@@ -3,11 +3,9 @@ examples:
3
3
  rails:
4
4
  - progress_pills_default: Default
5
5
  - progress_pills_status: Status
6
- - progress_pills_full_width: Full Container Width
7
6
 
8
7
 
9
8
 
10
9
  react:
11
10
  - progress_pills_default: Default
12
11
  - progress_pills_status: Status
13
- - progress_pills_full_width: Full Container Width
@@ -1,3 +1,2 @@
1
1
  export { default as ProgressPillsDefault } from './_progress_pills_default.jsx'
2
2
  export { default as ProgressPillsStatus } from './_progress_pills_status.jsx'
3
- export { default as ProgressPillsFullWidth } from './_progress_pills_full_width.jsx'
@@ -1,4 +1,9 @@
1
- <%= pb_content_tag do %>
1
+ <%= content_tag(:div,
2
+ aria: object.aria_attributes,
3
+ id: object.id,
4
+ data: object.data,
5
+ class: object.classname,
6
+ **combined_html_options) do %>
2
7
 
3
8
  <div class="progress_pills_status">
4
9
  <% object.with_status do |status| %>
@@ -9,7 +14,7 @@
9
14
 
10
15
  <div class="progress_pills">
11
16
  <% object.each_step do |step| %>
12
- <span class="pb_progress_pill<%= object.active_step(step) %><%= object.make_full_width %><%= object.dark_pill %>"></span>
17
+ <span class="pb_progress_pill<%= object.active_step(step) %><%= object.dark_pill %>"></span>
13
18
  <% end %>
14
19
  </div>
15
20
 
@@ -9,8 +9,6 @@ module Playbook
9
9
  prop :steps, type: Playbook::Props::Number,
10
10
  default: 3
11
11
  prop :title
12
- prop :full_width_pill, type: Playbook::Props::Boolean,
13
- default: false
14
12
 
15
13
  def classname
16
14
  generate_classname("pb_progress_pills_kit")
@@ -28,10 +26,6 @@ module Playbook
28
26
  step <= active ? "_active" : "_inactive"
29
27
  end
30
28
 
31
- def make_full_width
32
- full_width_pill ? " full_width_pill" : nil
33
- end
34
-
35
29
  def aria_attributes
36
30
  return aria if aria.present?
37
31
 
@@ -23,20 +23,6 @@ const ProgressPillsDefault = () => {
23
23
  )
24
24
  }
25
25
 
26
- const ProgressPillsFullWidth = () => {
27
- return (
28
- <ProgressPills
29
- active={2}
30
- aria={{ label: ariaLabel }}
31
- data={{ testid: testId }}
32
- fullWidthPill
33
- steps={3}
34
- title={title}
35
- value={value}
36
- />
37
- )
38
- }
39
-
40
26
  test('should pass data prop', () => {
41
27
  render(<ProgressPillsDefault />)
42
28
  const kit = screen.getByTestId(testId)
@@ -65,15 +51,4 @@ test('should render value', () => {
65
51
  render(<ProgressPillsDefault />)
66
52
  const kit = screen.getByText(value)
67
53
  expect(kit).toBeInTheDocument()
68
- })
69
-
70
- test('should apply fullWidthPill styling when fullWidthPill prop is true', () => {
71
- render(<ProgressPillsFullWidth />)
72
- const container = screen.getByTestId(testId)
73
- const pillElements = container.querySelectorAll('.full_width_pill')
74
-
75
- expect(pillElements.length).toBeGreaterThan(0)
76
- pillElements.forEach((pill) => {
77
- expect(pill).toHaveClass('full_width_pill')
78
- })
79
- })
54
+ })
@@ -1,7 +1,11 @@
1
1
  <%= content_tag(:div,
2
2
  class: object.wrapper_classname,
3
3
  style: object.style) do %>
4
- <%= pb_content_tag do %>
4
+ <%= content_tag(:div,
5
+ id: object.id,
6
+ data: object.data_values,
7
+ class: object.classname,
8
+ **combined_html_options) do %>
5
9
  <%= content_tag(:div, "",
6
10
  class: "progress_simple_value",
7
11
  style: object.value_style) %>
@@ -1,3 +1,7 @@
1
- <%= pb_content_tag(:ul) do %>
1
+ <%= content_tag(:ul,
2
+ id: object.id,
3
+ data: object.data,
4
+ class: object.classname,
5
+ **combined_html_options) do %>
2
6
  <%= content.presence %>
3
7
  <% end %>
@@ -1,6 +1,10 @@
1
- <%= pb_content_tag(:li) do %>
2
- <div class="box" style="max-width: min-content;">
3
- <div class="circle" id="<%= object.tooltip_trigger_class %>" >
1
+ <%= content_tag(:li,
2
+ id: object.id,
3
+ data: object.data,
4
+ class: object.classname,
5
+ **combined_html_options) do %>
6
+ <div class="box" style="max-width: min-content;" id="<%= object.tooltip_trigger_class %>">
7
+ <div class="circle">
4
8
  <%= pb_rails("icon", props: { icon: object.icon, size: "xs" }) if object.icon.present? %>
5
9
  </div>
6
10
  <% if object.tooltip.present? %>
@@ -7,21 +7,26 @@
7
7
  data: object.data,
8
8
  **combined_html_options
9
9
  }) do %>
10
- <%= pb_content_tag(:label,
10
+ <%= content_tag(:label,
11
11
  'data-pb-radio-children': 'true',
12
12
  checked: object.checked,
13
- value: object.value
14
- ) do %>
13
+ class: object.classname,
14
+ id: object.id,
15
+ value: object.value) do %>
15
16
  <%= input %>
16
17
  <span class="pb_radio_button"></span>
17
18
  <% end %>
18
19
  <div data-pb-radio-children-wrapper="true"> <%= content %> </div>
19
20
  <% end %>
20
21
  <% else %>
21
- <%= pb_content_tag(:label,
22
+ <%= content_tag(:label,
23
+ aria: object.aria,
22
24
  checked: object.checked,
25
+ class: object.classname,
26
+ data: object.data,
27
+ id: object.id,
23
28
  value: object.value,
24
- ) do %>
29
+ **combined_html_options) do %>
25
30
 
26
31
  <% if content.present? %>
27
32
  <%= content %>
@@ -32,4 +37,4 @@
32
37
  <span class="pb_radio_button"></span>
33
38
  <%= pb_rails("body", props: { status: object.body_status, text: object.text, dark: object.dark }) %>
34
39
  <% end %>
35
- <% end %>
40
+ <% end %>
@@ -21,7 +21,6 @@ module Playbook
21
21
  prop :options, type: Playbook::Props::HashArray, required: false, default: []
22
22
  prop :show_arrow, type: Playbook::Props::Boolean, default: false
23
23
  prop :required, type: Playbook::Props::Boolean, default: false
24
- prop :validation_message, type: Playbook::Props::String, default: ""
25
24
 
26
25
  def classnames
27
26
  classname + inline_class + compact_class + show_arrow_class
@@ -89,13 +88,6 @@ module Playbook
89
88
  "app/pb_kits/playbook/utilities/icons/angle-down.svg"
90
89
  end
91
90
 
92
- def data_attributes
93
- data = attributes[:data] || {}
94
- data.merge!("data-pb-select" => true)
95
- data.merge!("data-validation-message" => validation_message) if validation_message.present?
96
- data
97
- end
98
-
99
91
  private
100
92
 
101
93
  def error_class
@@ -16,7 +16,7 @@ const TableWithCollapsible = (props) => {
16
16
  );
17
17
  };
18
18
 
19
- return (
19
+ return (
20
20
  <Table
21
21
  size="sm"
22
22
  {...props}
@@ -31,12 +31,9 @@ examples:
31
31
  - table_with_subcomponents_as_divs: Table with Sub Components (Divs)
32
32
  - table_outer_padding: Outer Padding
33
33
  - table_with_collapsible: Table with Collapsible
34
- - table_with_collapsible_with_custom_click: Table with Collapsible with Custom Click
35
34
  - table_with_collapsible_with_custom_content_rails: Table with Collapsible with Custom Content
36
35
  - table_with_collapsible_with_nested_rows_rails: Table with Collapsible with Nested Rows
37
36
  - table_with_collapsible_with_nested_table_rails: Table with Collapsible with Nested Table
38
- - table_with_clickable_rows: Table with Clickable Rows
39
- - table_with_selectable_rows: Table with Selectable Rows
40
37
 
41
38
  react:
42
39
  - table_sm: Small
@@ -73,5 +70,3 @@ examples:
73
70
  - table_with_collapsible_with_custom_content: Table with Collapsible with Custom Content
74
71
  - table_with_collapsible_with_nested_rows: Table with Collapsible with Nested Rows
75
72
  - table_with_collapsible_with_nested_table: Table with Collapsible with Nested Table
76
- - table_with_clickable_rows: Table with Clickable Rows
77
- - table_with_selectable_rows: Table with Selectable Rows
@@ -32,6 +32,4 @@ export { default as TableWithCollapsible } from './_table_with_collapsible.jsx'
32
32
  export { default as TableWithCollapsibleWithCustomContent } from './_table_with_collapsible_with_custom_content.jsx'
33
33
  export { default as TableWithCollapsibleWithNestedTable } from './_table_with_collapsible_with_nested_table.jsx'
34
34
  export { default as TableWithCollapsibleWithNestedRows } from './_table_with_collapsible_with_nested_rows.jsx'
35
- export { default as TableWithCollapsibleWithCustomClick } from './_table_with_collapsible_with_custom_click.jsx'
36
- export { default as TableWithSelectableRows } from './_table_with_selectable_rows.jsx'
37
- export { default as TableWithClickableRows } from './_table_with_clickable_rows.jsx'
35
+ export { default as TableWithCollapsibleWithCustomClick } from './_table_with_collapsible_with_custom_click.jsx'