playbook_ui 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.
- checksums.yaml +4 -4
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_beta.md +6 -0
- 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
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_selectable_rows_no_subrows_rails.md +1 -5
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_selectable_rows_rails.md +2 -3
- data/app/pb_kits/playbook/pb_advanced_table/docs/example.yml +3 -3
- data/app/pb_kits/playbook/pb_advanced_table/docs/index.js +1 -1
- data/app/pb_kits/playbook/pb_advanced_table/index.js +11 -228
- data/app/pb_kits/playbook/pb_advanced_table/table_body.rb +1 -9
- data/app/pb_kits/playbook/pb_advanced_table/table_header.rb +3 -0
- data/app/pb_kits/playbook/pb_advanced_table/table_row.rb +2 -1
- data/app/pb_kits/playbook/pb_date_picker/docs/_date_picker_error.jsx +1 -4
- data/app/pb_kits/playbook/pb_draggable/docs/example.yml +1 -2
- data/app/pb_kits/playbook/pb_draggable/draggable.rb +1 -9
- data/app/pb_kits/playbook/pb_draggable/index.js +142 -139
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_error.jsx +1 -4
- data/app/pb_kits/playbook/pb_filter/docs/example.yml +0 -1
- data/app/pb_kits/playbook/pb_form_group/_error_state_mixin.scss +18 -22
- data/app/pb_kits/playbook/pb_line_graph/docs/example.yml +0 -1
- data/app/pb_kits/playbook/pb_line_graph/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_phone_number_input/_phone_number_input.scss +0 -13
- data/app/pb_kits/playbook/pb_phone_number_input/_phone_number_input.tsx +1 -3
- data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_validation.jsx +1 -8
- data/app/pb_kits/playbook/pb_phone_number_input/docs/example.yml +0 -2
- data/app/pb_kits/playbook/pb_phone_number_input/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_phone_number_input/phone_number_input.rb +0 -3
- data/app/pb_kits/playbook/pb_phone_number_input/phone_number_input.test.js +0 -19
- data/app/pb_kits/playbook/pb_popover/docs/example.yml +0 -1
- data/app/pb_kits/playbook/pb_popover/index.ts +1 -13
- data/app/pb_kits/playbook/pb_popover/popover.rb +0 -2
- data/app/pb_kits/playbook/pb_select/docs/_select_error.jsx +2 -7
- data/app/pb_kits/playbook/pb_text_input/docs/_text_input_error.jsx +1 -9
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_error.jsx +1 -7
- data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_error_state.jsx +2 -6
- data/dist/chunks/{_typeahead-D8CsVBZO.js → _typeahead-BX8IifKY.js} +2 -2
- data/dist/chunks/{_weekday_stacked-CHQsoCdP.js → _weekday_stacked-DfMD7HJz.js} +1 -1
- data/dist/chunks/{lib-BmTAc7Nc.js → lib-96_ZmvAo.js} +1 -1
- data/dist/chunks/{pb_form_validation-BWjy4bFn.js → pb_form_validation-Vv2TqXVC.js} +1 -1
- data/dist/chunks/vendor.js +1 -1
- data/dist/playbook-doc.js +2 -2
- data/dist/playbook-rails-react-bindings.js +1 -1
- data/dist/playbook-rails.js +1 -1
- data/dist/playbook.css +1 -1
- data/lib/playbook/version.rb +1 -1
- metadata +12 -26
- data/app/pb_kits/playbook/pb_advanced_table/flat_advanced_table.js +0 -106
- data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones.html.erb +0 -43
- data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_colors.html.erb +0 -55
- data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_colors_rails.md +0 -1
- data/app/pb_kits/playbook/pb_filter/docs/_filter_within_turbo_frames.html.erb +0 -41
- data/app/pb_kits/playbook/pb_filter/docs/_filter_within_turbo_frames.md +0 -1
- data/app/pb_kits/playbook/pb_line_graph/docs/_line_graph_pb_styles.jsx +0 -52
- data/app/pb_kits/playbook/pb_line_graph/docs/_line_graph_pb_styles.md +0 -1
- data/app/pb_kits/playbook/pb_line_graph/lineGraphTheme.ts +0 -110
- data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_country_search.html.erb +0 -10
- data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_country_search.jsx +0 -20
- data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_country_search.md +0 -1
- data/app/pb_kits/playbook/pb_popover/docs/_popover_append_to.html.erb +0 -46
- data/app/pb_kits/playbook/pb_popover/docs/_popover_append_to.md +0 -1
- /data/app/pb_kits/playbook/pb_advanced_table/docs/{_advanced_table_selectable_rows_rails.html.erb → _advanced_table_selectable_rows.html.erb} +0 -0
- /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
- /data/app/pb_kits/playbook/pb_advanced_table/docs/{_advanced_table_selectable_rows.md → _advanced_table_selectable_rows_react.md} +0 -0
- /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_drop_zones_react.md → _draggable_drop_zones.md} +0 -0
- /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_drop_zones_colors_react.md → _draggable_drop_zones_colors.md} +0 -0
@@ -13,15 +13,7 @@ export default class PbPopover extends PbEnhancedElement {
|
|
13
13
|
}
|
14
14
|
|
15
15
|
moveTooltip() {
|
16
|
-
|
17
|
-
|
18
|
-
if (this.appendTo === "parent") {
|
19
|
-
container = this.element.parentElement;
|
20
|
-
} else if (this.appendTo) {
|
21
|
-
container = document.querySelector(this.appendTo);
|
22
|
-
}
|
23
|
-
|
24
|
-
(container || document.body).appendChild(this.tooltip);
|
16
|
+
document.querySelector('body').appendChild(this.tooltip)
|
25
17
|
}
|
26
18
|
|
27
19
|
connect() {
|
@@ -116,8 +108,4 @@ export default class PbPopover extends PbEnhancedElement {
|
|
116
108
|
get closeOnClick() {
|
117
109
|
return this.element.dataset.pbPopoverCloseOnClick
|
118
110
|
}
|
119
|
-
|
120
|
-
get appendTo() {
|
121
|
-
return this.element.dataset.pbPopoverAppendTo;
|
122
|
-
}
|
123
111
|
}
|
@@ -3,7 +3,6 @@
|
|
3
3
|
module Playbook
|
4
4
|
module PbPopover
|
5
5
|
class Popover < Playbook::KitBase
|
6
|
-
prop :append_to, type: Playbook::Props::String, default: "body"
|
7
6
|
prop :position, type: Playbook::Props::Enum,
|
8
7
|
values: %w[top bottom left right top-start top-end bottom-start bottom-end right-start right-end left-start left-end],
|
9
8
|
default: "left"
|
@@ -48,7 +47,6 @@ module Playbook
|
|
48
47
|
|
49
48
|
def data
|
50
49
|
Hash(values[:data]).merge(
|
51
|
-
pb_popover_append_to: append_to,
|
52
50
|
pb_popover_kit: true,
|
53
51
|
pb_popover_position: position,
|
54
52
|
pb_popover_trigger_element_id: trigger_element_id,
|
@@ -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=
|
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=
|
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=
|
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=
|
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
|
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(
|
22
|
+
setErrorState("Please make a valid selection")
|
27
23
|
}
|
28
24
|
}, [searchValue])
|
29
25
|
|