playbook_ui 16.1.0.pre.alpha.play277814027 → 16.1.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.
- checksums.yaml +4 -4
- data/app/pb_kits/playbook/pb_advanced_table/Components/RegularTableView.tsx +2 -12
- data/app/pb_kits/playbook/pb_advanced_table/advanced_table.html.erb +2 -2
- data/app/pb_kits/playbook/pb_advanced_table/advanced_table.rb +0 -4
- data/app/pb_kits/playbook/pb_advanced_table/advanced_table.test.jsx +0 -33
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_inline_row_loading.md +2 -2
- data/app/pb_kits/playbook/pb_advanced_table/docs/example.yml +0 -2
- data/app/pb_kits/playbook/pb_advanced_table/docs/index.js +1 -2
- data/app/pb_kits/playbook/pb_advanced_table/table_body.rb +1 -51
- data/app/pb_kits/playbook/pb_advanced_table/table_header.html.erb +1 -1
- data/app/pb_kits/playbook/pb_advanced_table/table_header.rb +0 -34
- data/app/pb_kits/playbook/pb_advanced_table/table_row.html.erb +1 -1
- data/app/pb_kits/playbook/pb_advanced_table/table_row.rb +0 -19
- data/app/pb_kits/playbook/pb_background/docs/example.yml +0 -1
- data/app/pb_kits/playbook/pb_background/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_date_picker/_date_picker.tsx +5 -14
- data/app/pb_kits/playbook/pb_dialog/_dialog.scss +6 -8
- data/app/pb_kits/playbook/pb_dropdown/_dropdown.scss +0 -6
- data/app/pb_kits/playbook/pb_dropdown/_dropdown.tsx +2 -37
- data/app/pb_kits/playbook/pb_dropdown/docs/example.yml +0 -6
- data/app/pb_kits/playbook/pb_dropdown/docs/index.js +1 -4
- data/app/pb_kits/playbook/pb_dropdown/dropdown.html.erb +2 -2
- data/app/pb_kits/playbook/pb_dropdown/dropdown.rb +0 -6
- data/app/pb_kits/playbook/pb_dropdown/dropdown.test.jsx +0 -94
- data/app/pb_kits/playbook/pb_dropdown/dropdown_container.rb +1 -5
- data/app/pb_kits/playbook/pb_dropdown/index.js +4 -59
- data/app/pb_kits/playbook/pb_dropdown/subcomponents/DropdownContainer.tsx +0 -3
- data/app/pb_kits/playbook/pb_dropdown/subcomponents/DropdownTrigger.tsx +1 -2
- data/app/pb_kits/playbook/pb_filter/Filter/SortMenu.tsx +1 -1
- data/app/pb_kits/playbook/pb_filter/docs/_filter_default.html.erb +2 -2
- data/app/pb_kits/playbook/pb_filter/docs/_filter_default.jsx +9 -16
- data/app/pb_kits/playbook/pb_filter/filter.rb +2 -2
- data/app/pb_kits/playbook/pb_form/docs/_form_with_required_indicator.html.erb +1 -5
- data/app/pb_kits/playbook/pb_form/pb_form_validation.js +2 -9
- data/app/pb_kits/playbook/pb_form_pill/docs/_form_pill_truncated_text.html.erb +5 -5
- data/app/pb_kits/playbook/pb_form_pill/docs/_form_pill_truncated_text.jsx +4 -4
- data/app/pb_kits/playbook/pb_form_pill/form_pill.rb +0 -4
- data/app/pb_kits/playbook/pb_icon/icon.rb +1 -6
- data/app/pb_kits/playbook/pb_multi_level_select/docs/example.yml +33 -35
- data/app/pb_kits/playbook/pb_multi_level_select/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_multiple_users/docs/_multiple_users_with_tooltip.jsx +1 -1
- data/app/pb_kits/playbook/pb_multiple_users/docs/_multiple_users_with_tooltip.md +1 -1
- data/app/pb_kits/playbook/pb_multiple_users/docs/example.yml +0 -1
- data/app/pb_kits/playbook/pb_multiple_users/multiple_users.html.erb +7 -51
- data/app/pb_kits/playbook/pb_multiple_users/multiple_users.rb +0 -1
- data/app/pb_kits/playbook/pb_passphrase/_passphrase.tsx +5 -20
- data/app/pb_kits/playbook/pb_passphrase/docs/_passphrase_meter_settings.jsx +0 -1
- data/app/pb_kits/playbook/pb_passphrase/docs/example.yml +0 -2
- data/app/pb_kits/playbook/pb_passphrase/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_passphrase/passphrase.rb +0 -2
- data/app/pb_kits/playbook/pb_passphrase/passphrase.test.jsx +1 -30
- data/app/pb_kits/playbook/pb_phone_number_input/_phone_number_input.tsx +0 -3
- 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 +3 -34
- data/app/pb_kits/playbook/pb_rich_text_editor/_rich_text_editor.tsx +6 -33
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/example.yml +0 -3
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/index.js +0 -2
- data/app/pb_kits/playbook/pb_rich_text_editor/rich_text_editor.rb +0 -5
- data/app/pb_kits/playbook/pb_rich_text_editor/rich_text_editor.test.js +18 -33
- data/app/pb_kits/playbook/pb_textarea/_textarea.tsx +11 -39
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_default.html.erb +3 -3
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_default.jsx +0 -3
- data/app/pb_kits/playbook/pb_textarea/docs/example.yml +1 -4
- data/app/pb_kits/playbook/pb_textarea/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_textarea/index.ts +5 -12
- data/app/pb_kits/playbook/pb_textarea/textarea.html.erb +14 -30
- data/app/pb_kits/playbook/pb_textarea/textarea.rb +0 -36
- data/app/pb_kits/playbook/pb_textarea/textarea.test.js +1 -18
- data/app/pb_kits/playbook/pb_time_picker/_time_picker.tsx +11 -97
- data/app/pb_kits/playbook/pb_time_picker/docs/_time_picker_on_handler.jsx +2 -5
- data/app/pb_kits/playbook/pb_time_picker/docs/example.yml +0 -2
- data/app/pb_kits/playbook/pb_time_picker/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_time_picker/time_picker.rb +0 -3
- data/app/pb_kits/playbook/pb_time_picker/time_picker.test.jsx +1 -47
- data/app/pb_kits/playbook/pb_typeahead/_typeahead.test.jsx +1 -24
- data/app/pb_kits/playbook/pb_typeahead/_typeahead.tsx +1 -2
- data/app/pb_kits/playbook/pb_typeahead/components/MultiValue.tsx +1 -4
- data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_truncated_text.html.erb +1 -1
- data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_truncated_text.jsx +1 -1
- data/app/pb_kits/playbook/pb_typeahead/typeahead.rb +0 -4
- data/dist/chunks/{_pb_line_graph-BgKF_zz1.js → _pb_line_graph-hxi01lk7.js} +1 -1
- data/dist/chunks/_typeahead-BgLnlhzP.js +1 -0
- data/dist/chunks/{globalProps-BhVYCqRf.js → globalProps-DgYwLYNx.js} +1 -1
- data/dist/chunks/{lib-DD34ZrWL.js → lib-NLxTo8OB.js} +1 -1
- data/dist/chunks/vendor.js +3 -3
- data/dist/menu.yml +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/align_content.rb +3 -13
- data/lib/playbook/align_items.rb +3 -13
- data/lib/playbook/align_self.rb +3 -13
- data/lib/playbook/display.rb +0 -5
- data/lib/playbook/flex.rb +3 -13
- data/lib/playbook/flex_direction.rb +3 -13
- data/lib/playbook/flex_grow.rb +3 -13
- data/lib/playbook/flex_shrink.rb +3 -13
- data/lib/playbook/flex_wrap.rb +3 -13
- data/lib/playbook/forms/builder/phone_number_field.rb +0 -9
- data/lib/playbook/justify_content.rb +3 -13
- data/lib/playbook/justify_self.rb +3 -13
- data/lib/playbook/order.rb +3 -13
- data/lib/playbook/spacing.rb +9 -39
- data/lib/playbook/text_align.rb +3 -13
- data/lib/playbook/truncate.rb +1 -1
- data/lib/playbook/version.rb +2 -2
- data/lib/playbook/vertical_align.rb +3 -13
- data/lib/playbook/z_index.rb +0 -5
- metadata +6 -72
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_styling_background_custom.jsx +0 -71
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_styling_background_custom.md +0 -4
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_inline_row_loading_rails.html.erb +0 -64
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_inline_row_loading_rails.md +0 -18
- data/app/pb_kits/playbook/pb_background/docs/_background_responsive.jsx +0 -30
- data/app/pb_kits/playbook/pb_background/docs/_background_responsive.md +0 -1
- data/app/pb_kits/playbook/pb_date_picker/docs/_date_picker_default.md +0 -1
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_blank_selection_rails.md +0 -3
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_blank_selection_react.md +0 -3
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_clearable.html.erb +0 -52
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_clearable.jsx +0 -72
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_clearable.md +0 -5
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_constrain_height.jsx +0 -33
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_constrain_height_rails.html.erb +0 -20
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_constrain_height_rails.md +0 -8
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_constrain_height_react.md +0 -8
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_placeholder.html.erb +0 -9
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_placeholder.jsx +0 -33
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_with_placeholder.md +0 -3
- data/app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_input_display.html.erb +0 -74
- data/app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_input_display.jsx +0 -87
- data/app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_input_display.md +0 -3
- data/app/pb_kits/playbook/pb_multiple_users/docs/_multiple_users_with_tooltip.html.erb +0 -30
- data/app/pb_kits/playbook/pb_passphrase/docs/_passphrase_required_indicator.html.erb +0 -7
- data/app/pb_kits/playbook/pb_passphrase/docs/_passphrase_required_indicator.jsx +0 -24
- data/app/pb_kits/playbook/pb_passphrase/docs/_passphrase_required_indicator.md +0 -3
- data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_required_indicator.html.erb +0 -5
- data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_required_indicator.jsx +0 -14
- data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_required_indicator.md +0 -3
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_required_indicator.jsx +0 -35
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_required_indicator.md +0 -3
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_required_indicator.html.erb +0 -10
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_required_indicator.jsx +0 -21
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_required_indicator.md +0 -3
- data/app/pb_kits/playbook/pb_table/docs/_sections.yml +0 -68
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_default.md +0 -1
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_input_options.html.erb +0 -39
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_input_options.md +0 -3
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_required_indicator.html.erb +0 -5
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_required_indicator.jsx +0 -25
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_required_indicator.md +0 -3
- data/app/pb_kits/playbook/pb_time_picker/docs/_time_picker_required_indicator.html.erb +0 -6
- data/app/pb_kits/playbook/pb_time_picker/docs/_time_picker_required_indicator.jsx +0 -16
- data/app/pb_kits/playbook/pb_time_picker/docs/_time_picker_required_indicator.md +0 -3
- data/app/pb_kits/playbook/utilities/test/globalProps/borderRadius.test.js +0 -33
- data/app/pb_kits/playbook/utilities/test/globalProps/bottom.test.js +0 -60
- data/app/pb_kits/playbook/utilities/test/globalProps/cursor.test.js +0 -42
- data/app/pb_kits/playbook/utilities/test/globalProps/dark.test.js +0 -33
- data/app/pb_kits/playbook/utilities/test/globalProps/gap.test.js +0 -87
- data/app/pb_kits/playbook/utilities/test/globalProps/globalProps.integration.test.js +0 -936
- data/app/pb_kits/playbook/utilities/test/globalProps/height.test.js +0 -68
- data/app/pb_kits/playbook/utilities/test/globalProps/htmlOptions.test.js +0 -510
- data/app/pb_kits/playbook/utilities/test/globalProps/left.test.js +0 -60
- data/app/pb_kits/playbook/utilities/test/globalProps/lineHeight.test.js +0 -33
- data/app/pb_kits/playbook/utilities/test/globalProps/margin.test.js +0 -95
- data/app/pb_kits/playbook/utilities/test/globalProps/numberSpacing.test.js +0 -33
- data/app/pb_kits/playbook/utilities/test/globalProps/overflow.test.js +0 -68
- data/app/pb_kits/playbook/utilities/test/globalProps/padding.test.js +0 -95
- data/app/pb_kits/playbook/utilities/test/globalProps/position.test.js +0 -33
- data/app/pb_kits/playbook/utilities/test/globalProps/right.test.js +0 -60
- data/app/pb_kits/playbook/utilities/test/globalProps/shadow.test.js +0 -33
- data/app/pb_kits/playbook/utilities/test/globalProps/textAlign.test.js +0 -41
- data/app/pb_kits/playbook/utilities/test/globalProps/top.test.js +0 -60
- data/app/pb_kits/playbook/utilities/test/globalProps/verticalAlign.test.js +0 -40
- data/app/pb_kits/playbook/utilities/test/globalProps/width.test.js +0 -66
- data/app/pb_kits/playbook/utilities/test/globalProps/zIndex.test.js +0 -50
- data/dist/chunks/_typeahead-CWA5wlah.js +0 -1
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
<%
|
|
2
|
-
options = [
|
|
3
|
-
{ label: 'United States', value: 'unitedStates', id: 'us' },
|
|
4
|
-
{ label: 'Canada', value: 'canada', id: 'ca' },
|
|
5
|
-
{ label: 'Pakistan', value: 'pakistan', id: 'pk' },
|
|
6
|
-
]
|
|
7
|
-
%>
|
|
8
|
-
|
|
9
|
-
<%= pb_rails("dropdown", props: { options: options, placeholder: "Choose a country" }) %>
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
|
-
import Dropdown from '../../pb_dropdown/_dropdown'
|
|
3
|
-
|
|
4
|
-
const DropdownWithPlaceholder = (props) => {
|
|
5
|
-
|
|
6
|
-
const options = [
|
|
7
|
-
{
|
|
8
|
-
label: "United States",
|
|
9
|
-
value: "unitedStates",
|
|
10
|
-
id: "us"
|
|
11
|
-
},
|
|
12
|
-
{
|
|
13
|
-
label: "Canada",
|
|
14
|
-
value: "canada",
|
|
15
|
-
id: "ca"
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
label: "Pakistan",
|
|
19
|
-
value: "pakistan",
|
|
20
|
-
id: "pk"
|
|
21
|
-
}
|
|
22
|
-
];
|
|
23
|
-
|
|
24
|
-
return (
|
|
25
|
-
<Dropdown
|
|
26
|
-
options={options}
|
|
27
|
-
placeholder="Choose a country"
|
|
28
|
-
{...props}
|
|
29
|
-
/>
|
|
30
|
-
)
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
export default DropdownWithPlaceholder
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
The `placeholder` prop allows you to customize the placeholder text that appears when no option is selected in the dropdown.
|
|
2
|
-
|
|
3
|
-
The placeholder prop works with all dropdown variants (`default`, `subtle`, and `quickpick`). When no option is selected, the placeholder text is displayed. When an option is selected, the placeholder is replaced by the selected option's label. The default placeholder text is "Select..." if no placeholder is provided.
|
data/app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_input_display.html.erb
DELETED
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
<% treeData = [{
|
|
2
|
-
label: "Power Home Remodeling",
|
|
3
|
-
value: "powerHomeRemodeling",
|
|
4
|
-
id: "100",
|
|
5
|
-
expanded: true,
|
|
6
|
-
children: [
|
|
7
|
-
{
|
|
8
|
-
label: "People",
|
|
9
|
-
value: "people",
|
|
10
|
-
id: "101",
|
|
11
|
-
expanded: true,
|
|
12
|
-
children: [
|
|
13
|
-
{
|
|
14
|
-
label: "Talent Acquisition",
|
|
15
|
-
value: "talentAcquisition",
|
|
16
|
-
id: "102",
|
|
17
|
-
},
|
|
18
|
-
{
|
|
19
|
-
label: "Business Affairs",
|
|
20
|
-
value: "businessAffairs",
|
|
21
|
-
id: "103",
|
|
22
|
-
children: [
|
|
23
|
-
{
|
|
24
|
-
label: "Initiatives",
|
|
25
|
-
value: "initiatives",
|
|
26
|
-
id: "104",
|
|
27
|
-
},
|
|
28
|
-
{
|
|
29
|
-
label: "Learning & Development",
|
|
30
|
-
value: "learningAndDevelopment",
|
|
31
|
-
id: "105",
|
|
32
|
-
},
|
|
33
|
-
],
|
|
34
|
-
},
|
|
35
|
-
{
|
|
36
|
-
label: "People Experience",
|
|
37
|
-
value: "peopleExperience",
|
|
38
|
-
id: "106",
|
|
39
|
-
},
|
|
40
|
-
],
|
|
41
|
-
},
|
|
42
|
-
{
|
|
43
|
-
label: "Contact Center",
|
|
44
|
-
value: "contactCenter",
|
|
45
|
-
id: "107",
|
|
46
|
-
children: [
|
|
47
|
-
{
|
|
48
|
-
label: "Appointment Management",
|
|
49
|
-
value: "appointmentManagement",
|
|
50
|
-
id: "108",
|
|
51
|
-
},
|
|
52
|
-
{
|
|
53
|
-
label: "Customer Service",
|
|
54
|
-
value: "customerService",
|
|
55
|
-
id: "109",
|
|
56
|
-
},
|
|
57
|
-
{
|
|
58
|
-
label: "Energy",
|
|
59
|
-
value: "energy",
|
|
60
|
-
id: "110",
|
|
61
|
-
},
|
|
62
|
-
],
|
|
63
|
-
},
|
|
64
|
-
],
|
|
65
|
-
}] %>
|
|
66
|
-
|
|
67
|
-
<%= pb_rails("multi_level_select", props: {
|
|
68
|
-
id: "multi-level-select-input-display-none",
|
|
69
|
-
name: :foo,
|
|
70
|
-
tree_data: treeData,
|
|
71
|
-
input_display: "none",
|
|
72
|
-
return_all_selected: true,
|
|
73
|
-
})
|
|
74
|
-
%>
|
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import MultiLevelSelect from "../_multi_level_select";
|
|
3
|
-
|
|
4
|
-
const treeData = [
|
|
5
|
-
{
|
|
6
|
-
label: "Power Home Remodeling",
|
|
7
|
-
value: "powerHomeRemodeling",
|
|
8
|
-
id: "powerhome1",
|
|
9
|
-
expanded: true,
|
|
10
|
-
children: [
|
|
11
|
-
{
|
|
12
|
-
label: "People",
|
|
13
|
-
value: "people",
|
|
14
|
-
id: "people1",
|
|
15
|
-
expanded: true,
|
|
16
|
-
children: [
|
|
17
|
-
{
|
|
18
|
-
label: "Talent Acquisition",
|
|
19
|
-
value: "talentAcquisition",
|
|
20
|
-
id: "talent1",
|
|
21
|
-
},
|
|
22
|
-
{
|
|
23
|
-
label: "Business Affairs",
|
|
24
|
-
value: "businessAffairs",
|
|
25
|
-
id: "business1",
|
|
26
|
-
children: [
|
|
27
|
-
{
|
|
28
|
-
label: "Initiatives",
|
|
29
|
-
value: "initiatives",
|
|
30
|
-
id: "initiative1",
|
|
31
|
-
},
|
|
32
|
-
{
|
|
33
|
-
label: "Learning & Development",
|
|
34
|
-
value: "learningAndDevelopment",
|
|
35
|
-
id: "development1",
|
|
36
|
-
},
|
|
37
|
-
],
|
|
38
|
-
},
|
|
39
|
-
{
|
|
40
|
-
label: "People Experience",
|
|
41
|
-
value: "peopleExperience",
|
|
42
|
-
id: "experience1",
|
|
43
|
-
},
|
|
44
|
-
],
|
|
45
|
-
},
|
|
46
|
-
{
|
|
47
|
-
label: "Contact Center",
|
|
48
|
-
value: "contactCenter",
|
|
49
|
-
id: "contact1",
|
|
50
|
-
children: [
|
|
51
|
-
{
|
|
52
|
-
label: "Appointment Management",
|
|
53
|
-
value: "appointmentManagement",
|
|
54
|
-
id: "appointment1",
|
|
55
|
-
},
|
|
56
|
-
{
|
|
57
|
-
label: "Customer Service",
|
|
58
|
-
value: "customerService",
|
|
59
|
-
id: "customer1",
|
|
60
|
-
},
|
|
61
|
-
{
|
|
62
|
-
label: "Energy",
|
|
63
|
-
value: "energy",
|
|
64
|
-
id: "energy1",
|
|
65
|
-
},
|
|
66
|
-
],
|
|
67
|
-
},
|
|
68
|
-
],
|
|
69
|
-
},
|
|
70
|
-
];
|
|
71
|
-
|
|
72
|
-
const MultiLevelSelectInputDisplay = (props) => {
|
|
73
|
-
return (
|
|
74
|
-
<MultiLevelSelect
|
|
75
|
-
id="multi-level-select-input-display-none"
|
|
76
|
-
inputDisplay="none"
|
|
77
|
-
onSelect={(selectedNodes) =>
|
|
78
|
-
console.log("Selected Items", selectedNodes)
|
|
79
|
-
}
|
|
80
|
-
returnAllSelected
|
|
81
|
-
treeData={treeData}
|
|
82
|
-
{...props}
|
|
83
|
-
/>
|
|
84
|
-
);
|
|
85
|
-
};
|
|
86
|
-
|
|
87
|
-
export default MultiLevelSelectInputDisplay;
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
Use the `inputDisplay`/`input_display` prop to optionally display only the count in the display as opposed to multiple pills. This prop is set to 'pills' by default.
|
|
2
|
-
|
|
3
|
-
**NOTE**: `inputDisplay`/`input_display` is particularly useful for larger trees that may return many pill selections, helping to keep the input field clean and compact. This prop should not be used with the Single Select variant.
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
<%= pb_rails("multiple_users", props: {
|
|
2
|
-
with_tooltip: true,
|
|
3
|
-
users: [
|
|
4
|
-
{
|
|
5
|
-
name: "Patrick Welch",
|
|
6
|
-
image_url: "https://randomuser.me/api/portraits/men/9.jpg",
|
|
7
|
-
tooltip: "Patrick Welch - Online"
|
|
8
|
-
},
|
|
9
|
-
{
|
|
10
|
-
name: "Lucille Sanchez",
|
|
11
|
-
image_url: "https://randomuser.me/api/portraits/women/6.jpg",
|
|
12
|
-
tooltip: "Lucille Sanchez - Offline"
|
|
13
|
-
},
|
|
14
|
-
{
|
|
15
|
-
name: "Beverly Reyes",
|
|
16
|
-
image_url: "https://randomuser.me/api/portraits/women/74.jpg",
|
|
17
|
-
tooltip: "Beverly Reyes - Online"
|
|
18
|
-
},
|
|
19
|
-
{
|
|
20
|
-
name: "Keith Craig",
|
|
21
|
-
image_url: "https://randomuser.me/api/portraits/men/40.jpg",
|
|
22
|
-
tooltip: "Keith Craig - Away"
|
|
23
|
-
},
|
|
24
|
-
{
|
|
25
|
-
name: "Alicia Cooper",
|
|
26
|
-
image_url: "https://randomuser.me/api/portraits/women/46.jpg",
|
|
27
|
-
tooltip: "Alicia Cooper - Busy"
|
|
28
|
-
}
|
|
29
|
-
]
|
|
30
|
-
}) %>
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import React, { useState } from 'react'
|
|
2
|
-
|
|
3
|
-
import Passphrase from '../_passphrase'
|
|
4
|
-
|
|
5
|
-
const PassphraseRequiredIndicator = (props) => {
|
|
6
|
-
const [passphrase, setPassphrase] = useState('')
|
|
7
|
-
const handleOnChangePassphrase = (e) => {
|
|
8
|
-
setPassphrase(e.target ? e.target.value : e)
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
return (
|
|
12
|
-
<Passphrase
|
|
13
|
-
id="passphrase_required_indicator"
|
|
14
|
-
label="Passphrase"
|
|
15
|
-
name="passphrase"
|
|
16
|
-
onChange={handleOnChangePassphrase}
|
|
17
|
-
requiredIndicator
|
|
18
|
-
value={passphrase}
|
|
19
|
-
{...props}
|
|
20
|
-
/>
|
|
21
|
-
)
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
export default PassphraseRequiredIndicator
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
The `requiredIndicator`/`required_indicator` prop displays a red asterisk (*) next to the label, visually indicating that the field is required. This is purely visual and does not enforce validation.
|
|
2
|
-
|
|
3
|
-
You can use `requiredIndicator`/`required_indicator` with any validation approach: HTML5 validation via the `required` prop, client-side validation, or backend validation. For this reason, it works independently and doesn't need to be paired with the `required` prop.
|
data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_required_indicator.jsx
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
|
-
import PhoneNumberInput from '../../pb_phone_number_input/_phone_number_input'
|
|
3
|
-
|
|
4
|
-
const PhoneNumberInputRequiredIndicator = (props) => (
|
|
5
|
-
<>
|
|
6
|
-
<PhoneNumberInput
|
|
7
|
-
id='phone_number_input_required_indicator'
|
|
8
|
-
label='Phone Number'
|
|
9
|
-
requiredIndicator
|
|
10
|
-
{...props} />
|
|
11
|
-
</>
|
|
12
|
-
)
|
|
13
|
-
|
|
14
|
-
export default PhoneNumberInputRequiredIndicator
|
data/app/pb_kits/playbook/pb_phone_number_input/docs/_phone_number_input_required_indicator.md
DELETED
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
The `requiredIndicator`/`required_indicator` prop displays a red asterisk (*) next to the label, visually indicating that the field is required. This is purely visual and does not enforce validation.
|
|
2
|
-
|
|
3
|
-
You can use `requiredIndicator`/`required_indicator` with any validation approach: HTML5 validation via the `required` prop, client-side validation, or backend validation. For this reason, it works independently and doesn't need to be paired with the `required` prop.
|
data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_required_indicator.jsx
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
|
-
import RichTextEditor from '../../pb_rich_text_editor/_rich_text_editor'
|
|
3
|
-
import { useEditor, EditorContent } from "@tiptap/react"
|
|
4
|
-
import StarterKit from "@tiptap/starter-kit"
|
|
5
|
-
import Link from '@tiptap/extension-link'
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
const RichTextEditorAdvancedRequiredIndicator = (props) => {
|
|
9
|
-
|
|
10
|
-
const editor = useEditor({
|
|
11
|
-
extensions: [
|
|
12
|
-
StarterKit,
|
|
13
|
-
Link
|
|
14
|
-
],
|
|
15
|
-
content:"Add your text here. You can format your text, add links, quotes, and bullets."
|
|
16
|
-
})
|
|
17
|
-
if (!editor) {
|
|
18
|
-
return null
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
return (
|
|
22
|
-
<div>
|
|
23
|
-
<RichTextEditor
|
|
24
|
-
advancedEditor={editor}
|
|
25
|
-
label="Label"
|
|
26
|
-
requiredIndicator
|
|
27
|
-
{...props}
|
|
28
|
-
>
|
|
29
|
-
<EditorContent editor={editor}/>
|
|
30
|
-
</RichTextEditor>
|
|
31
|
-
</div>
|
|
32
|
-
)
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
export default RichTextEditorAdvancedRequiredIndicator
|
data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_required_indicator.md
DELETED
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
The `requiredIndicator`/`required_indicator` prop displays a red asterisk (*) next to the label, visually indicating that the field is required. This is purely visual and does not enforce validation.
|
|
2
|
-
|
|
3
|
-
You can use `requiredIndicator`/`required_indicator` with any validation approach: HTML5 validation via the `required` prop, client-side validation, or backend validation. For this reason, it works independently and doesn't need to be paired with the `required` prop.
|
data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_required_indicator.html.erb
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
<%= pb_rails("rich_text_editor", props: {
|
|
2
|
-
id: "required-indicator",
|
|
3
|
-
input_options: {
|
|
4
|
-
id: 'hidden_input_id',
|
|
5
|
-
name: "hidden_input_name"
|
|
6
|
-
},
|
|
7
|
-
label: "Label",
|
|
8
|
-
required_indicator: true,
|
|
9
|
-
value: "Add your text here. You can format your text, add links, quotes, and bullets."
|
|
10
|
-
}) %>
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import React, { useState } from 'react'
|
|
2
|
-
import RichTextEditor from '../../pb_rich_text_editor/_rich_text_editor'
|
|
3
|
-
|
|
4
|
-
const RichTextEditorRequiredIndicator = (props) => {
|
|
5
|
-
const [value, setValue] = useState('Add your text here. You can format your text, add links, quotes, and bullets.'),
|
|
6
|
-
handleOnChange = (html) => setValue(html)
|
|
7
|
-
|
|
8
|
-
return (
|
|
9
|
-
<div>
|
|
10
|
-
<RichTextEditor
|
|
11
|
-
label="Label"
|
|
12
|
-
onChange={handleOnChange}
|
|
13
|
-
requiredIndicator
|
|
14
|
-
value={value}
|
|
15
|
-
{...props}
|
|
16
|
-
/>
|
|
17
|
-
</div>
|
|
18
|
-
)
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
export default RichTextEditorRequiredIndicator
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
The `requiredIndicator`/`required_indicator` prop displays a red asterisk (*) next to the label, visually indicating that the field is required. This is purely visual and does not enforce validation.
|
|
2
|
-
|
|
3
|
-
You can use `requiredIndicator`/`required_indicator` with any validation approach: HTML5 validation via the `required` prop, client-side validation, or backend validation. For this reason, it works independently and doesn't need to be paired with the `required` prop.
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
sections:
|
|
2
|
-
- title: "Size & Density"
|
|
3
|
-
examples:
|
|
4
|
-
- table_sm
|
|
5
|
-
- table_md
|
|
6
|
-
- table_lg
|
|
7
|
-
- table_multiline
|
|
8
|
-
- table_single_line
|
|
9
|
-
- table_outer_padding
|
|
10
|
-
|
|
11
|
-
- title: "Layout & Structure"
|
|
12
|
-
examples:
|
|
13
|
-
- table_responsive_table
|
|
14
|
-
- table_with_subcomponents
|
|
15
|
-
- table_with_subcomponents_as_divs
|
|
16
|
-
- table_with_background_kit
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
- title: "Sticky & Positional Behaviors"
|
|
20
|
-
examples:
|
|
21
|
-
- table_sticky
|
|
22
|
-
- table_sticky_left_columns
|
|
23
|
-
- table_sticky_right_columns
|
|
24
|
-
- table_sticky_columns
|
|
25
|
-
- table_alignment_row
|
|
26
|
-
- table_alignment_column
|
|
27
|
-
- table_alignment_shift_row
|
|
28
|
-
- table_alignment_shift_data
|
|
29
|
-
- table_side_highlight
|
|
30
|
-
- table_container
|
|
31
|
-
|
|
32
|
-
- title: "Collapsible & Nested Behaviors"
|
|
33
|
-
examples:
|
|
34
|
-
- table_with_collapsible
|
|
35
|
-
- table_with_dynamic_collapsible
|
|
36
|
-
- table_with_collapsible_with_custom_click
|
|
37
|
-
- table_with_collapsible_with_custom_content
|
|
38
|
-
- table_with_collapsible_with_nested_rows
|
|
39
|
-
- table_with_collapsible_with_nested_table
|
|
40
|
-
|
|
41
|
-
- title: "Data Presentation"
|
|
42
|
-
examples:
|
|
43
|
-
- table_data_table
|
|
44
|
-
- table_vertical_border
|
|
45
|
-
- table_striped
|
|
46
|
-
|
|
47
|
-
- title: "Header Variants"
|
|
48
|
-
examples:
|
|
49
|
-
- table_header
|
|
50
|
-
- table_with_header_style_borderless
|
|
51
|
-
- table_with_header_style_floating
|
|
52
|
-
|
|
53
|
-
- title: "Interactive Tables"
|
|
54
|
-
examples:
|
|
55
|
-
- table_with_clickable_rows
|
|
56
|
-
- table_with_selectable_rows
|
|
57
|
-
- table_with_filter_variant
|
|
58
|
-
- table_with_filter_variant_with_pagination
|
|
59
|
-
- table_disable_hover
|
|
60
|
-
|
|
61
|
-
- title: "Table Actions"
|
|
62
|
-
examples:
|
|
63
|
-
- table_one_action
|
|
64
|
-
- table_two_actions
|
|
65
|
-
- table_two_plus_actions
|
|
66
|
-
- table_action_middle
|
|
67
|
-
- table_icon_buttons
|
|
68
|
-
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
Add an `id` to your Textarea so that clicking the label will move focus directly to the input.
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
<%= pb_rails("textarea", props: {
|
|
2
|
-
label: "ID on Container",
|
|
3
|
-
id: "container-id",
|
|
4
|
-
name: "comment",
|
|
5
|
-
rows: 4
|
|
6
|
-
}) %>
|
|
7
|
-
|
|
8
|
-
<br/>
|
|
9
|
-
|
|
10
|
-
<%= pb_rails("textarea", props: {
|
|
11
|
-
label: "ID on Textarea via input_options",
|
|
12
|
-
input_options: { id: "textarea-id" },
|
|
13
|
-
name: "comment",
|
|
14
|
-
rows: 4
|
|
15
|
-
}) %>
|
|
16
|
-
|
|
17
|
-
<br/>
|
|
18
|
-
|
|
19
|
-
<%= pb_rails("textarea", props: {
|
|
20
|
-
label: "Both Container and Textarea IDs",
|
|
21
|
-
id: "container-id-2",
|
|
22
|
-
input_options: { id: "textarea-id-2" },
|
|
23
|
-
name: "comment",
|
|
24
|
-
rows: 4
|
|
25
|
-
}) %>
|
|
26
|
-
|
|
27
|
-
<br/>
|
|
28
|
-
|
|
29
|
-
<%= pb_rails("textarea", props: {
|
|
30
|
-
label: "Data and ARIA Attributes",
|
|
31
|
-
name: "description",
|
|
32
|
-
rows: 4,
|
|
33
|
-
input_options: {
|
|
34
|
-
'aria-label': "Enter description",
|
|
35
|
-
'aria-describedby': "help-text",
|
|
36
|
-
data: { controller: "textarea", action: "focus->handleFocus" },
|
|
37
|
-
id: "description-textarea"
|
|
38
|
-
}
|
|
39
|
-
}) %>
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
Use the `input_options` / `inputOptions` prop to pass additional attributes directly to the underlying `<textarea>` element instead of the outer wrapper. This is useful for applying data attributes, custom IDs, ARIA attributes, or other HTML attributes that need to be on the textarea element itself.
|
|
2
|
-
|
|
3
|
-
Additional HTML attributes (e.g. data or ARIA attributes) can also be passed directly to the `<textarea>` via `input_options`.
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import React, {useState} from 'react'
|
|
2
|
-
|
|
3
|
-
import Textarea from '../_textarea'
|
|
4
|
-
|
|
5
|
-
const TextareaRequiredIndicator = (props) => {
|
|
6
|
-
const [value, setValue] = useState('Default value text')
|
|
7
|
-
const handleChange = (event) => {
|
|
8
|
-
setValue(event.target.value)
|
|
9
|
-
}
|
|
10
|
-
return (
|
|
11
|
-
<div>
|
|
12
|
-
<Textarea
|
|
13
|
-
label="Label"
|
|
14
|
-
name="comment"
|
|
15
|
-
onChange={(e) => handleChange(e)}
|
|
16
|
-
placeholder="Placeholder text"
|
|
17
|
-
requiredIndicator
|
|
18
|
-
value={value}
|
|
19
|
-
{...props}
|
|
20
|
-
/>
|
|
21
|
-
</div>
|
|
22
|
-
)
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export default TextareaRequiredIndicator
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
The `requiredIndicator`/`required_indicator` prop displays a red asterisk (*) next to the label, visually indicating that the field is required. This is purely visual and does not enforce validation.
|
|
2
|
-
|
|
3
|
-
You can use `requiredIndicator`/`required_indicator` with any validation approach: HTML5 validation via the `required` prop, client-side validation, or backend validation. For this reason, it works independently and doesn't need to be paired with the `required` prop.
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
|
-
import TimePicker from '../_time_picker'
|
|
3
|
-
|
|
4
|
-
const TimePickerRequiredIndicator = (props) => (
|
|
5
|
-
<div>
|
|
6
|
-
<TimePicker
|
|
7
|
-
id="time-picker-required-indicator"
|
|
8
|
-
label="Select Time"
|
|
9
|
-
requiredIndicator
|
|
10
|
-
{...props}
|
|
11
|
-
/>
|
|
12
|
-
</div>
|
|
13
|
-
)
|
|
14
|
-
|
|
15
|
-
export default TimePickerRequiredIndicator
|
|
16
|
-
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
The `requiredIndicator`/`required_indicator` prop displays a red asterisk (*) next to the label, visually indicating that the field is required. This is purely visual and does not enforce validation.
|
|
2
|
-
|
|
3
|
-
You can use `requiredIndicator`/`required_indicator` with any validation approach: HTML5 validation via the `required` prop, client-side validation, or backend validation. For this reason, it works independently and doesn't need to be paired with the `required` prop.
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { testGlobalProp, testGlobalPropAbsence, testGlobalPropInvalidValues } from './globalPropsTestHelper'
|
|
2
|
-
import Body from '../../../pb_body/_body'
|
|
3
|
-
import Button from '../../../pb_button/_button'
|
|
4
|
-
import Card from '../../../pb_card/_card'
|
|
5
|
-
import Title from '../../../pb_title/_title'
|
|
6
|
-
import Flex from '../../../pb_flex/_flex'
|
|
7
|
-
import Link from '../../../pb_link/_link'
|
|
8
|
-
import Badge from '../../../pb_badge/_badge'
|
|
9
|
-
|
|
10
|
-
// NOTE: TextInput excluded - borderRadius is not a valid prop for input elements
|
|
11
|
-
testGlobalProp(
|
|
12
|
-
'borderRadius',
|
|
13
|
-
['none', 'xs', 'sm', 'md', 'lg', 'xl', 'rounded'],
|
|
14
|
-
(v) => `border_radius_${v}`,
|
|
15
|
-
null,
|
|
16
|
-
[Body, Button, Card, Title, Flex, Link, Badge]
|
|
17
|
-
)
|
|
18
|
-
|
|
19
|
-
testGlobalPropAbsence(
|
|
20
|
-
'borderRadius',
|
|
21
|
-
['border_radius_none', 'border_radius_xs', 'border_radius_sm', 'border_radius_md', 'border_radius_lg', 'border_radius_xl', 'border_radius_rounded'],
|
|
22
|
-
undefined,
|
|
23
|
-
{ skipNull: true }
|
|
24
|
-
)
|
|
25
|
-
|
|
26
|
-
// NOTE: Currently using skipKnownIssues: true because globalProps.ts generates classes for invalid values
|
|
27
|
-
testGlobalPropInvalidValues(
|
|
28
|
-
'borderRadius',
|
|
29
|
-
['invalid', 'bad_value', 'not_a_radius', 'special-chars!@#'],
|
|
30
|
-
['border_radius_invalid', 'border_radius_bad_value', 'border_radius_not_a_radius', 'border_radius_special-chars!@#'],
|
|
31
|
-
undefined,
|
|
32
|
-
{ skipKnownIssues: true }
|
|
33
|
-
)
|