playbook_ui 15.5.0.pre.alpha.draggablefix12589 → 15.5.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 (177) hide show
  1. checksums.yaml +4 -4
  2. data/app/pb_kits/playbook/pb_advanced_table/_advanced_table.scss +6 -96
  3. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_styling.jsx +1 -2
  4. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_styling_column_headers.jsx +1 -1
  5. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_fullscreen.jsx +1 -3
  6. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_infinite_scroll.jsx +1 -1
  7. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_inline_editing.jsx +1 -3
  8. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_row_styling.jsx +1 -2
  9. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_table_props.html.erb +1 -1
  10. data/app/pb_kits/playbook/pb_bar_graph/BarGraphStyles.scss +58 -0
  11. data/app/pb_kits/playbook/pb_copy_button/_copy_button.tsx +8 -21
  12. data/app/pb_kits/playbook/pb_copy_button/copy_button.html.erb +2 -6
  13. data/app/pb_kits/playbook/pb_copy_button/copy_button.rb +0 -3
  14. data/app/pb_kits/playbook/pb_copy_button/copy_button.test.jsx +0 -24
  15. data/app/pb_kits/playbook/pb_copy_button/docs/_copy_button_default.html.erb +2 -2
  16. data/app/pb_kits/playbook/pb_copy_button/docs/_copy_button_default.jsx +2 -1
  17. data/app/pb_kits/playbook/pb_copy_button/docs/_copy_button_from.html.erb +2 -2
  18. data/app/pb_kits/playbook/pb_copy_button/docs/_copy_button_from.jsx +0 -2
  19. data/app/pb_kits/playbook/pb_copy_button/docs/example.yml +0 -2
  20. data/app/pb_kits/playbook/pb_copy_button/docs/index.js +0 -1
  21. data/app/pb_kits/playbook/pb_currency/docs/_currency_negative.html.erb +0 -10
  22. data/app/pb_kits/playbook/pb_currency/docs/_currency_negative.jsx +0 -10
  23. data/app/pb_kits/playbook/pb_currency/docs/_currency_variants.html.erb +0 -7
  24. data/app/pb_kits/playbook/pb_currency/docs/_currency_variants.jsx +0 -7
  25. data/app/pb_kits/playbook/pb_currency/docs/_description.md +2 -2
  26. data/app/pb_kits/playbook/pb_date_picker/date_picker_helper.ts +3 -44
  27. data/app/pb_kits/playbook/pb_date_time/_date_time.tsx +0 -3
  28. data/app/pb_kits/playbook/pb_date_time/date_time.html.erb +0 -1
  29. data/app/pb_kits/playbook/pb_date_time/date_time.rb +0 -1
  30. data/app/pb_kits/playbook/pb_date_time/docs/example.yml +1 -3
  31. data/app/pb_kits/playbook/pb_date_time/docs/index.js +0 -1
  32. data/app/pb_kits/playbook/pb_date_time_stacked/_date_time_stacked.tsx +0 -3
  33. data/app/pb_kits/playbook/pb_date_time_stacked/date_time_stacked.html.erb +2 -2
  34. data/app/pb_kits/playbook/pb_date_time_stacked/date_time_stacked.rb +0 -2
  35. data/app/pb_kits/playbook/pb_date_time_stacked/date_time_stacked.test.js +0 -33
  36. data/app/pb_kits/playbook/pb_date_time_stacked/docs/example.yml +1 -3
  37. data/app/pb_kits/playbook/pb_date_time_stacked/docs/index.js +0 -1
  38. data/app/pb_kits/playbook/pb_dialog/docs/_dialog_compound_components.html.erb +2 -2
  39. data/app/pb_kits/playbook/pb_draggable/context/index.tsx +6 -156
  40. data/app/pb_kits/playbook/pb_draggable/context/types.ts +3 -8
  41. data/app/pb_kits/playbook/pb_draggable/docs/example.yml +2 -3
  42. data/app/pb_kits/playbook/pb_draggable/docs/index.js +1 -2
  43. data/app/pb_kits/playbook/pb_draggable/draggable.test.jsx +1 -77
  44. data/app/pb_kits/playbook/pb_dropdown/index.js +13 -31
  45. data/app/pb_kits/playbook/pb_empty_state/docs/_empty_state_alignment.jsx +1 -2
  46. data/app/pb_kits/playbook/pb_empty_state/docs/_empty_state_default.jsx +1 -2
  47. data/app/pb_kits/playbook/pb_empty_state/docs/_empty_state_orientation.jsx +1 -2
  48. data/app/pb_kits/playbook/pb_empty_state/docs/_empty_state_size.jsx +1 -2
  49. data/app/pb_kits/playbook/pb_form_pill/docs/_form_pill_wrapped.jsx +1 -4
  50. data/app/pb_kits/playbook/pb_loading_inline/docs/_loading_inline_variant.jsx +1 -1
  51. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_description.md +1 -3
  52. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_colors.jsx +1 -1
  53. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_default.jsx +1 -1
  54. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_height.jsx +1 -1
  55. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_horizontal.jsx +1 -1
  56. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_legend.jsx +1 -1
  57. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_legend_non_clickable.jsx +2 -1
  58. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_legend_position.html.erb +1 -1
  59. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_legend_position.jsx +1 -1
  60. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_negative_numbers.jsx +1 -1
  61. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_secondary_y_axis.jsx +1 -1
  62. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_spline.jsx +2 -1
  63. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_stacked.jsx +2 -1
  64. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_description.md +1 -3
  65. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_block_content.jsx +1 -2
  66. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_color_overrides.jsx +1 -2
  67. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_custom_tooltip.jsx +1 -1
  68. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_custom_tooltip.md +1 -2
  69. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_data_legend_position.jsx +1 -2
  70. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_data_with_labels.jsx +1 -1
  71. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_data_with_legend.jsx +1 -1
  72. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_default.jsx +1 -1
  73. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_inner_sizes.jsx +1 -1
  74. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_live_data.jsx +1 -2
  75. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_rounded.jsx +1 -1
  76. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_with_title.jsx +1 -1
  77. data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_description.md +1 -3
  78. data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_color.jsx +1 -1
  79. data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_color.md +2 -2
  80. data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_complex.jsx +1 -2
  81. data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_full_circle.jsx +1 -2
  82. data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_height.jsx +1 -2
  83. data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_min_max.jsx +1 -2
  84. data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_units.jsx +1 -2
  85. data/app/pb_kits/playbook/pb_pb_line_graph/docs/_description.md +1 -3
  86. data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_colors.jsx +1 -1
  87. data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_legend_position.html.erb +1 -1
  88. data/app/pb_kits/playbook/pb_popover/docs/_popover_append_to.jsx +1 -4
  89. data/app/pb_kits/playbook/pb_progress_step/_progress_step.scss +262 -384
  90. data/app/pb_kits/playbook/pb_progress_step/docs/_description.md +5 -1
  91. data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_default.html.erb +1 -4
  92. data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_default.jsx +3 -14
  93. data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_vertical.html.erb +7 -1
  94. data/app/pb_kits/playbook/pb_progress_step/docs/example.yml +0 -3
  95. data/app/pb_kits/playbook/pb_progress_step/docs/index.js +0 -2
  96. data/app/pb_kits/playbook/pb_progress_step/progress_step.test.js +0 -41
  97. data/app/pb_kits/playbook/pb_radio/docs/_radio_react_hook.jsx +1 -3
  98. data/app/pb_kits/playbook/pb_rich_text_editor/TipTap/Toolbar.tsx +1 -1
  99. data/app/pb_kits/playbook/pb_rich_text_editor/_rich_text_editor.tsx +61 -8
  100. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_default_rails.md +7 -0
  101. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_focus.html.erb +10 -2
  102. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_inline_rails.md +1 -0
  103. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_preview.html.erb +19 -11
  104. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_simple.html.erb +5 -1
  105. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_sticky.html.erb +1 -1
  106. data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_sticky_rails.md +1 -0
  107. data/app/pb_kits/playbook/pb_rich_text_editor/docs/example.yml +2 -2
  108. data/app/pb_kits/playbook/pb_rich_text_editor/rich_text_editor.rb +16 -7
  109. data/app/pb_kits/playbook/pb_select/docs/_select_react_hook.jsx +1 -3
  110. data/app/pb_kits/playbook/pb_table/_table.tsx +26 -28
  111. data/app/pb_kits/playbook/pb_table/styles/_vertical_border.scss +0 -49
  112. data/app/pb_kits/playbook/pb_tooltip/docs/_tooltip_sizing.jsx +1 -4
  113. data/app/pb_kits/playbook/pb_typeahead/_typeahead.scss +0 -4
  114. data/app/pb_kits/playbook/pb_typeahead/components/MultiValue.tsx +0 -1
  115. data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_react_hook.jsx +1 -2
  116. data/app/pb_kits/playbook/pb_user/docs/_user_font_options.jsx +1 -1
  117. data/app/pb_kits/playbook/utilities/_truncate.scss +0 -2
  118. data/app/pb_kits/playbook/utilities/globalProps.ts +8 -26
  119. data/app/pb_kits/playbook/utilities/test/globalProps/alignContent.test.js +0 -18
  120. data/app/pb_kits/playbook/utilities/test/globalProps/alignItems.test.js +0 -18
  121. data/app/pb_kits/playbook/utilities/test/globalProps/alignSelf.test.js +0 -18
  122. data/app/pb_kits/playbook/utilities/test/globalProps/display.test.js +0 -18
  123. data/app/pb_kits/playbook/utilities/test/globalProps/flex.test.js +0 -18
  124. data/app/pb_kits/playbook/utilities/test/globalProps/flexDirection.test.js +0 -18
  125. data/app/pb_kits/playbook/utilities/test/globalProps/flexGrow.test.js +0 -18
  126. data/app/pb_kits/playbook/utilities/test/globalProps/flexShrink.test.js +0 -18
  127. data/app/pb_kits/playbook/utilities/test/globalProps/flexWrap.test.js +0 -18
  128. data/app/pb_kits/playbook/utilities/test/globalProps/justifyContent.test.js +0 -18
  129. data/app/pb_kits/playbook/utilities/test/globalProps/justifySelf.test.js +0 -18
  130. data/app/pb_kits/playbook/utilities/test/globalProps/order.test.js +0 -18
  131. data/dist/chunks/_line_graph-eQNOB_GQ.js +1 -0
  132. data/dist/chunks/_typeahead-vbfetkuE.js +24 -0
  133. data/dist/chunks/_weekday_stacked-CvJHyUq6.js +37 -0
  134. data/dist/chunks/componentRegistry-DzmmLR2x.js +1 -0
  135. data/dist/chunks/lib-BCrK6CFU.js +29 -0
  136. data/dist/chunks/pb_form_validation-Cj4vdjWI.js +1 -0
  137. data/dist/chunks/vendor.js +1 -37
  138. data/dist/playbook-doc.js +1 -0
  139. data/dist/playbook-rails-react-bindings.js +1 -1
  140. data/dist/playbook-rails.js +1 -1
  141. data/dist/playbook.css +1 -1
  142. data/lib/playbook/version.rb +2 -2
  143. metadata +13 -36
  144. data/app/pb_kits/playbook/pb_copy_button/docs/_copy_button_button_variant.html.erb +0 -9
  145. data/app/pb_kits/playbook/pb_copy_button/docs/_copy_button_button_variant.jsx +0 -24
  146. data/app/pb_kits/playbook/pb_copy_button/docs/_copy_button_button_variant_rails.md +0 -1
  147. data/app/pb_kits/playbook/pb_copy_button/docs/_copy_button_button_variant_react.md +0 -1
  148. data/app/pb_kits/playbook/pb_currency/docs/_currency_abbreviated.md +0 -1
  149. data/app/pb_kits/playbook/pb_currency/docs/_currency_matching_decimals_rails.md +0 -1
  150. data/app/pb_kits/playbook/pb_currency/docs/_currency_matching_decimals_react.md +0 -1
  151. data/app/pb_kits/playbook/pb_currency/docs/_currency_negative.md +0 -1
  152. data/app/pb_kits/playbook/pb_currency/docs/_currency_no_symbol_rails.md +0 -1
  153. data/app/pb_kits/playbook/pb_currency/docs/_currency_no_symbol_react.md +0 -1
  154. data/app/pb_kits/playbook/pb_date_time/docs/_date_time_show_current_year.html.erb +0 -4
  155. data/app/pb_kits/playbook/pb_date_time/docs/_date_time_show_current_year.jsx +0 -14
  156. data/app/pb_kits/playbook/pb_date_time/docs/_date_time_show_current_year_rails.md +0 -1
  157. data/app/pb_kits/playbook/pb_date_time/docs/_date_time_show_current_year_react.md +0 -1
  158. data/app/pb_kits/playbook/pb_date_time_stacked/docs/_date_time_stacked_show_current_year.html.erb +0 -4
  159. data/app/pb_kits/playbook/pb_date_time_stacked/docs/_date_time_stacked_show_current_year.jsx +0 -22
  160. data/app/pb_kits/playbook/pb_date_time_stacked/docs/_date_time_stacked_show_current_year.md +0 -1
  161. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers_dropzone.jsx +0 -180
  162. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers_dropzone.md +0 -20
  163. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_default.md +0 -1
  164. data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_legend_position.md +0 -11
  165. data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_default.md +0 -1
  166. data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_default.md +0 -1
  167. data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_default.md +0 -1
  168. data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_color.html.erb +0 -14
  169. data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_color.jsx +0 -29
  170. data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_color.md +0 -3
  171. data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_custom_icon.jsx +0 -31
  172. data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_custom_icon.md +0 -1
  173. data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_default.md +0 -3
  174. data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_tracker.md +0 -3
  175. data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_vertical.md +0 -1
  176. data/dist/chunks/_typeahead-DUmTKJUc.js +0 -6
  177. data/dist/chunks/lib-CgpqUb6l.js +0 -29
@@ -0,0 +1 @@
1
+ import{P as PbEnhancedElement,d as debounce}from"./lib-BCrK6CFU.js";const KIT_SELECTOR='[class^="pb_"][class*="_kit"]';const ERROR_MESSAGE_SELECTOR=".pb_body_kit_negative";const FORM_SELECTOR='form[data-pb-form-validation="true"]';const REQUIRED_FIELDS_SELECTOR="input[required],textarea[required],select[required]";const PHONE_NUMBER_VALIDATION_ERROR_SELECTOR='[data-pb-phone-validation-error="true"]';const FIELD_EVENTS=["change","valid","invalid"];class PbFormValidation extends PbEnhancedElement{static get selector(){return FORM_SELECTOR}connect(){this.formValidationFields.forEach((field=>{const isPhoneNumberInput=field.closest(".pb_phone_number_input");if(isPhoneNumberInput)return;FIELD_EVENTS.forEach((e=>{field.addEventListener(e,debounce((event=>{this.validateFormField(event)}),250),false)}))}));this.element.addEventListener("submit",(event=>{setTimeout((()=>{if(this.hasPhoneNumberValidationErrors()){event.preventDefault();return false}}),0)}))}validateFormField(event){event.preventDefault();const{target:target}=event;target.setCustomValidity("");const isValid=event.target.validity.valid;if(isValid){this.clearError(target)}else{this.showValidationMessage(target)}}showValidationMessage(target){const{parentElement:parentElement}=target;const kitElement=parentElement.closest(KIT_SELECTOR);if(!kitElement)return;const isPhoneNumberInput=kitElement.classList.contains("pb_phone_number_input");this.clearError(target);kitElement.classList.add("error");if(!isPhoneNumberInput){const errorMessageContainer=this.errorMessageContainer;if(target.dataset.message)target.setCustomValidity(target.dataset.message);errorMessageContainer.innerHTML=target.validationMessage;parentElement.appendChild(errorMessageContainer)}}clearError(target){const{parentElement:parentElement}=target;const kitElement=parentElement.closest(KIT_SELECTOR);if(kitElement)kitElement.classList.remove("error");const errorMessageContainer=parentElement.querySelector(ERROR_MESSAGE_SELECTOR);if(errorMessageContainer)errorMessageContainer.remove()}hasPhoneNumberValidationErrors(){const phoneNumberErrors=this.element.querySelectorAll(PHONE_NUMBER_VALIDATION_ERROR_SELECTOR);return phoneNumberErrors.length>0}get errorMessageContainer(){const errorContainer=document.createElement("div");const kitClassName=ERROR_MESSAGE_SELECTOR.replace(/\./,"");errorContainer.classList.add(kitClassName);return errorContainer}get formValidationFields(){return this._formValidationFields=this._formValidationFields||this.element.querySelectorAll(REQUIRED_FIELDS_SELECTOR)}}window.PbFormValidation=PbFormValidation;