playbook_ui_docs 14.18.0.pre.alpha.PLAY20397473 → 14.18.0.pre.alpha.PLAY20787400

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 (40) hide show
  1. checksums.yaml +4 -4
  2. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_beta.md +6 -0
  3. data/app/pb_kits/playbook/pb_advanced_table/docs/{_advanced_table_selectable_rows_no_subrows_react.jsx → _advanced_table_selectable_rows_no_subrows.jsx} +2 -2
  4. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_selectable_rows_no_subrows_rails.md +1 -5
  5. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_selectable_rows_rails.md +2 -3
  6. data/app/pb_kits/playbook/pb_advanced_table/docs/example.yml +3 -3
  7. data/app/pb_kits/playbook/pb_advanced_table/docs/index.js +1 -1
  8. data/app/pb_kits/playbook/pb_date_picker/docs/_date_picker_error.jsx +1 -4
  9. data/app/pb_kits/playbook/pb_draggable/docs/example.yml +1 -2
  10. data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_error.jsx +1 -4
  11. data/app/pb_kits/playbook/pb_filter/docs/example.yml +0 -1
  12. data/app/pb_kits/playbook/pb_line_graph/docs/example.yml +0 -1
  13. data/app/pb_kits/playbook/pb_line_graph/docs/index.js +0 -1
  14. data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_validation.jsx +1 -8
  15. data/app/pb_kits/playbook/pb_phone_number_input/docs/example.yml +0 -2
  16. data/app/pb_kits/playbook/pb_phone_number_input/docs/index.js +0 -1
  17. data/app/pb_kits/playbook/pb_popover/docs/example.yml +0 -1
  18. data/app/pb_kits/playbook/pb_select/docs/_select_error.jsx +2 -7
  19. data/app/pb_kits/playbook/pb_text_input/docs/_text_input_error.jsx +1 -9
  20. data/app/pb_kits/playbook/pb_textarea/docs/_textarea_error.jsx +1 -7
  21. data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_error_state.jsx +2 -6
  22. data/dist/playbook-doc.js +2 -2
  23. metadata +8 -20
  24. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones.html.erb +0 -43
  25. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_colors.html.erb +0 -55
  26. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_colors_rails.md +0 -1
  27. data/app/pb_kits/playbook/pb_filter/docs/_filter_within_turbo_frames.html.erb +0 -41
  28. data/app/pb_kits/playbook/pb_filter/docs/_filter_within_turbo_frames.md +0 -1
  29. data/app/pb_kits/playbook/pb_line_graph/docs/_line_graph_pb_styles.jsx +0 -52
  30. data/app/pb_kits/playbook/pb_line_graph/docs/_line_graph_pb_styles.md +0 -1
  31. data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_country_search.html.erb +0 -10
  32. data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_country_search.jsx +0 -20
  33. data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_country_search.md +0 -1
  34. data/app/pb_kits/playbook/pb_popover/docs/_popover_append_to.html.erb +0 -46
  35. data/app/pb_kits/playbook/pb_popover/docs/_popover_append_to.md +0 -1
  36. /data/app/pb_kits/playbook/pb_advanced_table/docs/{_advanced_table_selectable_rows_rails.html.erb → _advanced_table_selectable_rows.html.erb} +0 -0
  37. /data/app/pb_kits/playbook/pb_advanced_table/docs/{_advanced_table_selectable_rows_no_subrows_rails.html.erb → _advanced_table_selectable_rows_no_subrows.html.erb} +0 -0
  38. /data/app/pb_kits/playbook/pb_advanced_table/docs/{_advanced_table_selectable_rows.md → _advanced_table_selectable_rows_react.md} +0 -0
  39. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_drop_zones_react.md → _draggable_drop_zones.md} +0 -0
  40. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_drop_zones_colors_react.md → _draggable_drop_zones_colors.md} +0 -0
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d04d890d023d5b5d8f0a5b4936dc6a07c600d3f37fcc89a50e06448dfc604b87
4
- data.tar.gz: b592431b6a1472e075ed04f31f596286ae5c8b17ff5d8ae4d1dcf14bf0dee815
3
+ metadata.gz: b3e7d47a9299088d750906643acac266d30471dfea3e97e02d840a8cc7707f03
4
+ data.tar.gz: ebcc74afbe19ac073c894c1d73545ab932e36f9f10d850eec84431c20ec4fb24
5
5
  SHA512:
6
- metadata.gz: 2a56d0e706215ce38261a76d02158313f3ac55a99744232bd6d6cb0cc670b9e5731543419e8c37aac382cbe09faa824a60b6720cafb3e82a59a90db5e483255b
7
- data.tar.gz: 81474b64ae663d1ef381a795415a48bb83ca8b44e28114e9bc382cebbc49948e22eaeacf951aac00a65768fef7249cefb4f75819dda49f0dfae77c81cfbc6bea
6
+ metadata.gz: caaa753b1c2df935c91ed8576f78af9c52f1f30dd64095ab88cb1447b69a576d6f1984ba2a98ce7563d2b095ead8a247b0f6fdbe51795d8f12b00b6fb4a1e7a5
7
+ data.tar.gz: b933dc82f82e408a2de8abe712cb3bb9b415db080126748c53cacbd31252394b8951104c77ea1e68ad2ce3c039eefa933bac40ef7ff7139558f338b7060e96d2
@@ -1,3 +1,9 @@
1
+ **BETA VERSION**
2
+ This kit's Rails version is currently under development. Some features may not work as expected, and breaking changes may still occur; use with caution.
3
+ <br />
4
+ <br />
5
+ <br />
6
+
1
7
  The AdvancedTable kit accepts tree data and automatically renders expansion controls for nested subrows, to any depth, based on the data it is given. In it's simplest form, __the kit has two required props__:
2
8
 
3
9
  ### table_data
@@ -2,7 +2,7 @@ import React from "react"
2
2
  import AdvancedTable from '../../pb_advanced_table/_advanced_table'
3
3
  import MOCK_DATA from "./advanced_table_mock_data_no_subrows.json"
4
4
 
5
- const AdvancedTableSelectableRowsNoSubrowsReact = (props) => {
5
+ const AdvancedTableSelectableRowsNoSubrows = (props) => {
6
6
  const columnDefinitions = [
7
7
  {
8
8
  accessor: "year",
@@ -49,4 +49,4 @@ const AdvancedTableSelectableRowsNoSubrowsReact = (props) => {
49
49
  )
50
50
  }
51
51
 
52
- export default AdvancedTableSelectableRowsNoSubrowsReact
52
+ export default AdvancedTableSelectableRowsNoSubrows
@@ -1,5 +1 @@
1
- `selectable_rows` can also be used with tables without nested row data. Set `enable_toggle_expansion: none` to adjust the Advanced Table styling to fit a table without subrows.
2
-
3
- The data attribute `data-selected-rows` on the parent `pb_advanced_table` div will update dynamically with each selection to show an array of ids corresponding to the current selection.
4
-
5
- __NOTE__: Each object within the `table_data` Array must contain a unique id in order to attach an id to all Rows for this to function.
1
+ `selectable_rows` can also be used with tables without nested row data. Set `enable_toggle_expansion: none` to adjust the Advanced Table styling to fit a table without subrows.
@@ -2,6 +2,5 @@
2
2
 
3
3
  When a parent row is clicked, it will check all nested children rows, Children rows can be manually checked or unchecked as well.
4
4
 
5
- The data attribute `data-selected-rows` on the parent `pb_advanced_table` div will update dynamically with each selection to show an array of ids corresponding to the current selection.
6
-
7
- __NOTE__: Each object within the `table_data` Array must contain a unique id in order to attach an id to all Rows for this to function.
5
+ __ALERT TO DEVS__: UPDATE THIS PARAGRAPH IN THE FOLLOW UP STORY WHEN CHECKBOX FUNCTIONALITY IS SET PLEASE
6
+ The `onRowSelectionChange` prop returns an array of ids of all Rows that have been selected. Open the console on this example and check and uncheck checkboxes to see this is action! __NOTE__: Each object within the `tableData`Array must contain a unique id in order to attach an id to all Rows for this to function.
@@ -12,8 +12,8 @@ examples:
12
12
  - advanced_table_custom_cell_rails: Custom Components for Cells
13
13
  - advanced_table_column_headers: Multi-Header Columns
14
14
  - advanced_table_column_headers_multiple: Multi-Header Columns (Multiple Levels)
15
- - advanced_table_selectable_rows_rails: Selectable Rows
16
- - advanced_table_selectable_rows_no_subrows_rails: Selectable Rows (No Subrows)
15
+ # - advanced_table_selectable_rows: Selectable Rows
16
+ # - advanced_table_selectable_rows_no_subrows: Selectable Rows (No Subrows)
17
17
 
18
18
 
19
19
  react:
@@ -41,7 +41,7 @@ examples:
41
41
  - advanced_table_column_headers_custom_cell: Multi-Header Columns with Custom Cells
42
42
  # - advanced_table_no_subrows: Table with No Subrows
43
43
  - advanced_table_selectable_rows: Selectable Rows
44
- - advanced_table_selectable_rows_no_subrows_react: Selectable Rows (No Subrows)
44
+ - advanced_table_selectable_rows_no_subrows: Selectable Rows (No Subrows)
45
45
  - advanced_table_selectable_rows_actions: Selectable Rows (With Actions)
46
46
  - advanced_table_selectable_rows_header: Selectable Rows (No Actions Bar)
47
47
  - advanced_table_inline_editing: Inline Cell Editing
@@ -15,7 +15,7 @@ export { default as AdvancedTablePaginationWithProps } from './_advanced_table_p
15
15
  export { default as AdvancedTableColumnHeaders } from './_advanced_table_column_headers.jsx'
16
16
  export { default as AdvancedTableColumnHeadersMultiple } from './_advanced_table_column_headers_multiple.jsx'
17
17
  export { default as AdvancedTableSelectableRows } from './_advanced_table_selectable_rows.jsx'
18
- export { default as AdvancedTableSelectableRowsNoSubrowsReact } from './_advanced_table_selectable_rows_no_subrows_react.jsx'
18
+ export { default as AdvancedTableSelectableRowsNoSubrows } from './_advanced_table_selectable_rows_no_subrows.jsx'
19
19
  export { default as AdvancedTableNoSubrows } from './_advanced_table_no_subrows.jsx'
20
20
  export { default as AdvancedTableSelectableRowsHeader } from './_advanced_table_selectable_rows_header.jsx'
21
21
  export { default as AdvancedTableSelectableRowsActions } from './_advanced_table_selectable_rows_actions.jsx'
@@ -1,14 +1,11 @@
1
1
  import React from 'react'
2
2
 
3
3
  import DatePicker from '../_date_picker'
4
- import Icon from '../../pb_icon/_icon'
5
4
 
6
5
  const DatePickerError = (props) => (
7
6
  <div>
8
7
  <DatePicker
9
- error={<>
10
- <Icon icon="warning" /> Invalid date. Please pick a valid date.
11
- </>}
8
+ error="Invalid date. Please pick a valid date."
12
9
  pickerId="date-picker-error"
13
10
  {...props}
14
11
  />
@@ -17,6 +17,5 @@ examples:
17
17
  - draggable_with_cards: Draggable with Cards
18
18
  - draggable_with_table: Draggable with Table
19
19
  - draggable_multiple_containers: Dragging Across Multiple Containers
20
- - draggable_drop_zones: Draggable Drop Zones
21
- - draggable_drop_zones_colors: Draggable Drop Zones Colors
22
20
  - draggable_event_listeners: Draggable Event Listeners
21
+
@@ -1,12 +1,9 @@
1
1
  import React, { useState } from 'react'
2
2
  import Dropdown from '../../pb_dropdown/_dropdown'
3
- import Icon from '../../pb_icon/_icon'
4
3
 
5
4
  const DropdownError = (props) => {
6
5
  const [selectedOption, setSelectedOption] = useState()
7
- const error = selectedOption?.value ? null : (<>
8
- <Icon icon="warning" /> Please make a valid selection
9
- </>)
6
+ const error = selectedOption?.value ? null : "Please make a valid selection"
10
7
  const options = [
11
8
  {
12
9
  label: "United States",
@@ -11,7 +11,6 @@ examples:
11
11
  - filter_max_height: Max Height for Popover Inside of Filter
12
12
  - filter_placement: Filter Placement
13
13
  - filter_popover_props: Popover Props
14
- - filter_within_turbo_frames: Within Turbo Frames
15
14
 
16
15
  react:
17
16
  - filter_default: Default
@@ -11,7 +11,6 @@ examples:
11
11
 
12
12
  react:
13
13
  - line_graph_default: Default
14
- - line_graph_pb_styles: Playbook Styles
15
14
  - line_graph_legend: Legend
16
15
  - line_graph_legend_position: Legend Position
17
16
  - line_graph_legend_nonclickable: Legend Nonclickable
@@ -4,4 +4,3 @@ export { default as LineGraphLegendPosition } from './_line_graph_legend_positio
4
4
  export { default as LineGraphLegendNonclickable } from './_line_graph_legend_nonclickable.jsx'
5
5
  export { default as LineGraphHeight } from './_line_graph_height.jsx'
6
6
  export { default as LineGraphColors } from './_line_graph_colors.jsx'
7
- export { default as LineGraphPbStyles } from './_line_graph_pb_styles.jsx'
@@ -3,7 +3,6 @@ import React, { useEffect, useState } from "react";
3
3
  import Button from '../../pb_button/_button'
4
4
  import FixedConfirmationToast from '../../pb_fixed_confirmation_toast/_fixed_confirmation_toast'
5
5
  import PhoneNumberInput from '../../pb_phone_number_input/_phone_number_input'
6
- import Icon from '../../pb_icon/_icon'
7
6
 
8
7
  const PhoneNumberInputValidation = (props) => {
9
8
  const [formErrors, setFormErrors] = useState("");
@@ -30,12 +29,6 @@ const PhoneNumberInputValidation = (props) => {
30
29
  setShowFormErrors(formErrors.length > 0);
31
30
  }, [formErrors]);
32
31
 
33
- const error = (
34
- <>
35
- <Icon icon="warning" /> Missing phone number.
36
- </>
37
- )
38
-
39
32
  return (
40
33
  <form
41
34
  action=""
@@ -50,7 +43,7 @@ const PhoneNumberInputValidation = (props) => {
50
43
  />
51
44
  )}
52
45
  <PhoneNumberInput
53
- error={error}
46
+ error="Missing phone number."
54
47
  id="validation"
55
48
  initialCountry={countryCode}
56
49
  onChange={handleOnChange}
@@ -9,7 +9,6 @@ examples:
9
9
  - phone_number_input_clear_field: Clearing the Input Field
10
10
  - phone_number_input_access_input_element: Accessing the Input Element
11
11
  - phone_number_input_format: Format as You Type
12
- - phone_number_input_country_search: Country Search
13
12
 
14
13
  rails:
15
14
  - phone_number_input_default: Default
@@ -19,5 +18,4 @@ examples:
19
18
  - phone_number_input_validation: Form Validation
20
19
  - phone_number_input_format: Format as You Type
21
20
  - phone_number_input_hidden_inputs: Hidden Inputs
22
- - phone_number_input_country_search: Country Search
23
21
 
@@ -6,4 +6,3 @@ export { default as PhoneNumberInputValidation } from './_phone_number_input_val
6
6
  export { default as PhoneNumberInputClearField } from './_phone_number_input_clear_field'
7
7
  export { default as PhoneNumberInputAccessInputElement } from './_phone_number_input_access_input_element'
8
8
  export { default as PhoneNumberInputFormat } from './_phone_number_input_format'
9
- export { default as PhoneNumberInputCountrySearch } from './_phone_number_input_country_search'
@@ -6,7 +6,6 @@ examples:
6
6
  - popover_z_index: Set Z-Index
7
7
  - popover_scroll_height: Scroll and Height Settings
8
8
  - popover_actionable_content: With Actionable Content
9
- - popover_append_to: Append To
10
9
 
11
10
  react:
12
11
  - popover_default: Default
@@ -1,7 +1,6 @@
1
1
  import React from 'react'
2
2
  import Body from '../../pb_body/_body'
3
3
  import Select from '../../pb_select/_select'
4
- import Icon from '../../pb_icon/_icon'
5
4
 
6
5
  const SelectError = (props) => {
7
6
  const options = [
@@ -19,14 +18,10 @@ const SelectError = (props) => {
19
18
  },
20
19
  ]
21
20
 
22
- const error = (<>
23
- <Icon icon="warning" /> Please make a valid selection
24
- </>)
25
-
26
21
  return (
27
22
  <div>
28
23
  <Select
29
- error={error}
24
+ error="Please make a valid selection"
30
25
  label="Favorite Food"
31
26
  name="food"
32
27
  options={options}
@@ -34,7 +29,7 @@ const SelectError = (props) => {
34
29
  {...props}
35
30
  />
36
31
  <Body
37
- error={error}
32
+ error="Please make a valid selection"
38
33
  status="negative"
39
34
  {...props}
40
35
  />
@@ -1,7 +1,6 @@
1
1
  import React, { useState } from 'react'
2
2
 
3
3
  import TextInput from '../_text_input'
4
- import Icon from '../../pb_icon/_icon'
5
4
 
6
5
  const TextInputError = (props) => {
7
6
  const [email, setEmail] = useState('')
@@ -9,18 +8,11 @@ const TextInputError = (props) => {
9
8
  const handleUpdateEmail = ({ target }) => {
10
9
  setEmail(target.value)
11
10
  }
12
-
13
- const error = (
14
- <>
15
- <Icon icon="warning" /> Please enter a valid email address
16
- </>
17
- )
18
-
19
11
  return (
20
12
  <div>
21
13
  <TextInput
22
14
  addOn={{ icon: 'user', alignment: 'left', border: true }}
23
- error={error}
15
+ error="Please enter a valid email address"
24
16
  label="Email Address"
25
17
  onChange={handleUpdateEmail}
26
18
  placeholder="Enter email address"
@@ -1,21 +1,15 @@
1
1
  import React, {useState} from 'react'
2
2
  import Textarea from '../../pb_textarea/_textarea'
3
- import Icon from '../../pb_icon/_icon'
4
3
 
5
4
  const TextareaError = (props) => {
6
5
  const [value, setValue] = useState('default value text')
7
6
  const handleChange = (event) => {
8
7
  setValue(event.target.value)
9
8
  }
10
- const error = (
11
- <>
12
- <Icon icon="warning" /> This field has an error!
13
- </>
14
- )
15
9
  return (
16
10
  <div>
17
11
  <Textarea
18
- error={error}
12
+ error="This field has an error!"
19
13
  label="Label"
20
14
  name="comment"
21
15
  onChange={(e)=> handleChange(e)}
@@ -1,7 +1,6 @@
1
1
  import React, { useState, useEffect } from 'react'
2
2
 
3
3
  import Typeahead from '../_typeahead'
4
- import Icon from '../../pb_icon/_icon'
5
4
 
6
5
  const options = [
7
6
  { label: 'Orange', value: '#FFA500' },
@@ -11,10 +10,7 @@ const options = [
11
10
  ]
12
11
 
13
12
  const TypeaheadErrorState = (props) => {
14
- const error = (<>
15
- <Icon icon="warning" /> Please make a valid selection
16
- </>)
17
- const [errorState, setErrorState] = useState(error);
13
+ const [errorState, setErrorState] = useState("Please make a valid selection");
18
14
  const [searchValue, setSearchValue] = useState(null);
19
15
 
20
16
  const handleOnChange = (value) => setSearchValue(value)
@@ -23,7 +19,7 @@ const TypeaheadErrorState = (props) => {
23
19
  if(searchValue) {
24
20
  setErrorState("")
25
21
  } else {
26
- setErrorState(error)
22
+ setErrorState("Please make a valid selection")
27
23
  }
28
24
  }, [searchValue])
29
25