playbook_ui 13.10.0.pre.alpha.PLAY1046multilevelsingleselectphase21328 → 13.10.0.pre.alpha.play845addswiftkitspage1332
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/pb_kits/playbook/pb_multi_level_select/_multi_level_select.scss +0 -4
- data/app/pb_kits/playbook/pb_multi_level_select/_multi_level_select.tsx +0 -14
- data/app/pb_kits/playbook/pb_multi_level_select/docs/example.yml +0 -2
- data/app/pb_kits/playbook/pb_multi_level_select/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_multi_level_select/multi_level_select.rb +0 -3
- data/dist/menu.yml +281 -110
- data/dist/playbook-rails.js +4 -4
- data/lib/playbook/pb_doc_helper.rb +12 -1
- data/lib/playbook/version.rb +1 -1
- metadata +2 -4
- data/app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_single_children_only.html.erb +0 -74
- data/app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_single_children_only.jsx +0 -88
@@ -46,7 +46,18 @@ module Playbook
|
|
46
46
|
# rubocop:disable Naming/AccessorMethodName
|
47
47
|
def get_kits
|
48
48
|
menu = YAML.load_file(Playbook::Engine.root.join("dist/menu.yml"))
|
49
|
-
|
49
|
+
all_kits = []
|
50
|
+
menu["kits"].each do |kit|
|
51
|
+
kit_name = kit["name"]
|
52
|
+
components = kit["components"].map { |c| c["name"] }
|
53
|
+
|
54
|
+
all_kits << if components.size == 1
|
55
|
+
components.first
|
56
|
+
else
|
57
|
+
{ kit_name => components }
|
58
|
+
end
|
59
|
+
end
|
60
|
+
all_kits
|
50
61
|
end
|
51
62
|
|
52
63
|
def get_kits_pb_website
|
data/lib/playbook/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: playbook_ui
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 13.10.0.pre.alpha.
|
4
|
+
version: 13.10.0.pre.alpha.play845addswiftkitspage1332
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Power UX
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2023-10-
|
12
|
+
date: 2023-10-25 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: actionpack
|
@@ -1502,8 +1502,6 @@ files:
|
|
1502
1502
|
- app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_selected_ids.md
|
1503
1503
|
- app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_single.html.erb
|
1504
1504
|
- app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_single.jsx
|
1505
|
-
- app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_single_children_only.html.erb
|
1506
|
-
- app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_single_children_only.jsx
|
1507
1505
|
- app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_with_form.html.erb
|
1508
1506
|
- app/pb_kits/playbook/pb_multi_level_select/docs/example.yml
|
1509
1507
|
- app/pb_kits/playbook/pb_multi_level_select/docs/index.js
|
@@ -1,74 +0,0 @@
|
|
1
|
-
<% treeData = [{
|
2
|
-
label: "Power Home Remodeling",
|
3
|
-
value: "Power Home Remodeling",
|
4
|
-
id: "300",
|
5
|
-
expanded: true,
|
6
|
-
children: [
|
7
|
-
{
|
8
|
-
label: "People",
|
9
|
-
value: "People",
|
10
|
-
id: "301",
|
11
|
-
expanded: true,
|
12
|
-
children: [
|
13
|
-
{
|
14
|
-
label: "Talent Acquisition",
|
15
|
-
value: "Talent Acquisition",
|
16
|
-
id: "302",
|
17
|
-
},
|
18
|
-
{
|
19
|
-
label: "Business Affairs",
|
20
|
-
value: "Business Affairs",
|
21
|
-
id: "303",
|
22
|
-
children: [
|
23
|
-
{
|
24
|
-
label: "Initiatives",
|
25
|
-
value: "Initiatives",
|
26
|
-
id: "304",
|
27
|
-
},
|
28
|
-
{
|
29
|
-
label: "Learning & Development",
|
30
|
-
value: "Learning & Development",
|
31
|
-
id: "305",
|
32
|
-
},
|
33
|
-
],
|
34
|
-
},
|
35
|
-
{
|
36
|
-
label: "People Experience",
|
37
|
-
value: "People Experience",
|
38
|
-
id: "306",
|
39
|
-
},
|
40
|
-
],
|
41
|
-
},
|
42
|
-
{
|
43
|
-
label: "Contact Center",
|
44
|
-
value: "Contact Center",
|
45
|
-
id: "307",
|
46
|
-
children: [
|
47
|
-
{
|
48
|
-
label: "Appointment Management",
|
49
|
-
value: "Appointment Management",
|
50
|
-
id: "308",
|
51
|
-
},
|
52
|
-
{
|
53
|
-
label: "Customer Service",
|
54
|
-
value: "Customer Service",
|
55
|
-
id: "309",
|
56
|
-
},
|
57
|
-
{
|
58
|
-
label: "Energy",
|
59
|
-
value: "Energy",
|
60
|
-
id: "310",
|
61
|
-
},
|
62
|
-
],
|
63
|
-
},
|
64
|
-
],
|
65
|
-
}] %>
|
66
|
-
|
67
|
-
<%= pb_rails("multi_level_select", props: {
|
68
|
-
id: "multi-level-select-single-children-only-rails",
|
69
|
-
name: "my_single_children_only_select_array",
|
70
|
-
tree_data: treeData,
|
71
|
-
input_name: "PowerChildren",
|
72
|
-
ultimate_children_only: true,
|
73
|
-
variant: "single"
|
74
|
-
}) %>
|
data/app/pb_kits/playbook/pb_multi_level_select/docs/_multi_level_select_single_children_only.jsx
DELETED
@@ -1,88 +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: "Power Home Remodeling",
|
8
|
-
id: "powerhome3",
|
9
|
-
expanded: true,
|
10
|
-
children: [
|
11
|
-
{
|
12
|
-
label: "People",
|
13
|
-
value: "People",
|
14
|
-
id: "people3",
|
15
|
-
expanded: true,
|
16
|
-
children: [
|
17
|
-
{
|
18
|
-
label: "Talent Acquisition",
|
19
|
-
value: "Talent Acquisition",
|
20
|
-
id: "talent3",
|
21
|
-
},
|
22
|
-
{
|
23
|
-
label: "Business Affairs",
|
24
|
-
value: "Business Affairs",
|
25
|
-
id: "business3",
|
26
|
-
children: [
|
27
|
-
{
|
28
|
-
label: "Initiatives",
|
29
|
-
value: "Initiatives",
|
30
|
-
id: "initiative3",
|
31
|
-
},
|
32
|
-
{
|
33
|
-
label: "Learning & Development",
|
34
|
-
value: "Learning & Development",
|
35
|
-
id: "development3",
|
36
|
-
},
|
37
|
-
],
|
38
|
-
},
|
39
|
-
{
|
40
|
-
label: "People Experience",
|
41
|
-
value: "People Experience",
|
42
|
-
id: "experience3",
|
43
|
-
},
|
44
|
-
],
|
45
|
-
},
|
46
|
-
{
|
47
|
-
label: "Contact Center",
|
48
|
-
value: "Contact Center",
|
49
|
-
id: "contact3",
|
50
|
-
children: [
|
51
|
-
{
|
52
|
-
label: "Appointment Management",
|
53
|
-
value: "Appointment Management",
|
54
|
-
id: "appointment3",
|
55
|
-
},
|
56
|
-
{
|
57
|
-
label: "Customer Service",
|
58
|
-
value: "Customer Service",
|
59
|
-
id: "customer3",
|
60
|
-
},
|
61
|
-
{
|
62
|
-
label: "Energy",
|
63
|
-
value: "Energy",
|
64
|
-
id: "energy3",
|
65
|
-
},
|
66
|
-
],
|
67
|
-
},
|
68
|
-
],
|
69
|
-
},
|
70
|
-
];
|
71
|
-
|
72
|
-
const MultiLevelSelectSingleChildrenOnly = (props) => {
|
73
|
-
return (
|
74
|
-
<div>
|
75
|
-
<MultiLevelSelect
|
76
|
-
id="multiselect-single-children-only"
|
77
|
-
inputName="PowerChildren"
|
78
|
-
onSelect={(selectedNode) => console.log("Selected Node", selectedNode)}
|
79
|
-
treeData={treeData}
|
80
|
-
ultimateChildrenOnly
|
81
|
-
variant="single"
|
82
|
-
{...props}
|
83
|
-
/>
|
84
|
-
</div>
|
85
|
-
)
|
86
|
-
};
|
87
|
-
|
88
|
-
export default MultiLevelSelectSingleChildrenOnly;
|