playbook_ui_docs 14.6.0.pre.rc.21 → 14.6.0.pre.rc.22
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_dropdown/docs/_dropdown_separators_hidden.html.erb +9 -0
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_separators_hidden.jsx +33 -0
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_subtle_variant.html.erb +10 -0
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_subtle_variant.jsx +34 -0
- data/app/pb_kits/playbook/pb_dropdown/docs/_dropdown_subtle_variant.md +1 -0
- data/app/pb_kits/playbook/pb_dropdown/docs/example.yml +4 -0
- data/app/pb_kits/playbook/pb_dropdown/docs/index.js +2 -0
- data/dist/playbook-doc.js +1 -1
- metadata +7 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a19049ed47cd3246a79beaa93c6e3c9080e6500d517fa6c436574a205fd66ba7
|
4
|
+
data.tar.gz: abc9e42f14cfcff13dde1d8ae1aa8a327d604fbfcc5762d0aef4d2712c9f3112
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6f480c41cce3295a22f23f293af0a76c7bc72c4bfc7f6113dd4f049bff4d9b3ef9a8e3fac7f21c852b318eefe4f9071afc21fa24bfa5139c710b712f02a5b4cc
|
7
|
+
data.tar.gz: 2af4d41e1e8314a94c54ded237905ee8d433ce56c2c550469fbdcf462e02981cea2750c9177a144210b76a7aeed24fe97710c8c2971d7b2666e069e87ab80311
|
@@ -0,0 +1,9 @@
|
|
1
|
+
<%
|
2
|
+
options = [
|
3
|
+
{ label: 'United States', value: 'United States', 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, separators: false}) %>
|
@@ -0,0 +1,33 @@
|
|
1
|
+
import React from 'react'
|
2
|
+
import { Dropdown } from 'playbook-ui'
|
3
|
+
|
4
|
+
const DropdownSeparatorsHidden = (props) => {
|
5
|
+
|
6
|
+
const options = [
|
7
|
+
{
|
8
|
+
label: "United States",
|
9
|
+
value: "United States",
|
10
|
+
},
|
11
|
+
{
|
12
|
+
label: "Canada",
|
13
|
+
value: "Canada",
|
14
|
+
},
|
15
|
+
{
|
16
|
+
label: "Pakistan",
|
17
|
+
value: "Pakistan",
|
18
|
+
}
|
19
|
+
];
|
20
|
+
|
21
|
+
|
22
|
+
return (
|
23
|
+
<div>
|
24
|
+
<Dropdown
|
25
|
+
options={options}
|
26
|
+
separators={false}
|
27
|
+
{...props}
|
28
|
+
/>
|
29
|
+
</div>
|
30
|
+
)
|
31
|
+
}
|
32
|
+
|
33
|
+
export default DropdownSeparatorsHidden
|
@@ -0,0 +1,10 @@
|
|
1
|
+
<%
|
2
|
+
options = [
|
3
|
+
{ label: 'United States', value: 'United States', id: 'us' },
|
4
|
+
{ label: 'Canada', value: 'Canada', id: 'ca' },
|
5
|
+
{ label: 'Pakistan', value: 'Pakistan', id: 'pk' },
|
6
|
+
]
|
7
|
+
|
8
|
+
%>
|
9
|
+
|
10
|
+
<%= pb_rails("dropdown", props: { options: options, variant: "subtle", separators: false }) %>
|
@@ -0,0 +1,34 @@
|
|
1
|
+
import React from 'react'
|
2
|
+
import { Dropdown } from 'playbook-ui'
|
3
|
+
|
4
|
+
const DropdownSubtleVariant = (props) => {
|
5
|
+
|
6
|
+
const options = [
|
7
|
+
{
|
8
|
+
label: "United States",
|
9
|
+
value: "United States",
|
10
|
+
},
|
11
|
+
{
|
12
|
+
label: "Canada",
|
13
|
+
value: "Canada",
|
14
|
+
},
|
15
|
+
{
|
16
|
+
label: "Pakistan",
|
17
|
+
value: "Pakistan",
|
18
|
+
}
|
19
|
+
];
|
20
|
+
|
21
|
+
|
22
|
+
return (
|
23
|
+
<>
|
24
|
+
<Dropdown
|
25
|
+
options={options}
|
26
|
+
separators={false}
|
27
|
+
variant="subtle"
|
28
|
+
{...props}
|
29
|
+
/>
|
30
|
+
</>
|
31
|
+
)
|
32
|
+
}
|
33
|
+
|
34
|
+
export default DropdownSubtleVariant
|
@@ -0,0 +1 @@
|
|
1
|
+
For the `subtle` variant, it is recommended that you set the `Separators` prop to `false` to remove the separator lines between the options for a more cleaner look.
|
@@ -1,6 +1,7 @@
|
|
1
1
|
examples:
|
2
2
|
rails:
|
3
3
|
- dropdown_default: Default
|
4
|
+
- dropdown_subtle_variant: Subtle Variant
|
4
5
|
- dropdown_subcomponent_structure_rails: Subcomponent Structure
|
5
6
|
- dropdown_with_label: With Label
|
6
7
|
- dropdown_with_custom_options_rails: Custom Options
|
@@ -10,9 +11,11 @@ examples:
|
|
10
11
|
- dropdown_error: Dropdown with Error
|
11
12
|
- dropdown_default_value: Default Value
|
12
13
|
- dropdown_blank_selection: Blank Selection
|
14
|
+
- dropdown_separators_hidden: Separators Hidden
|
13
15
|
|
14
16
|
react:
|
15
17
|
- dropdown_default: Default
|
18
|
+
- dropdown_subtle_variant: Subtle Variant
|
16
19
|
- dropdown_subcomponent_structure: Subcomponent Structure
|
17
20
|
- dropdown_with_label: With Label
|
18
21
|
- dropdown_with_custom_options: Custom Options
|
@@ -23,6 +26,7 @@ examples:
|
|
23
26
|
- dropdown_default_value: Default Value
|
24
27
|
- dropdown_blank_selection: Blank Selection
|
25
28
|
- dropdown_clear_selection: Clear Selection
|
29
|
+
- dropdown_separators_hidden: Separators Hidden
|
26
30
|
# - dropdown_with_autocomplete: Autocomplete
|
27
31
|
# - dropdown_with_autocomplete_and_custom_display: Autocomplete with Custom Display
|
28
32
|
# - dropdown_with_external_control: useDropdown Hook
|
@@ -13,3 +13,5 @@ export { default as DropdownError } from './_dropdown_error.jsx'
|
|
13
13
|
export { default as DropdownDefaultValue } from './_dropdown_default_value.jsx'
|
14
14
|
export { default as DropdownBlankSelection } from './_dropdown_blank_selection.jsx'
|
15
15
|
export { default as DropdownClearSelection } from './_dropdown_clear_selection.jsx'
|
16
|
+
export { default as DropdownSubtleVariant } from './_dropdown_subtle_variant.jsx'
|
17
|
+
export { default as DropdownSeparatorsHidden } from './_dropdown_separators_hidden.jsx'
|