playbook_ui_docs 15.4.0 → 15.5.0.pre.rc.1
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_date_range_inline/docs/_date_range_inline_show_current_year.html.erb +4 -0
- data/app/pb_kits/playbook/pb_date_range_inline/docs/_date_range_inline_show_current_year.jsx +43 -0
- data/app/pb_kits/playbook/pb_date_range_inline/docs/_date_range_inline_show_current_year.md +1 -0
- data/app/pb_kits/playbook/pb_date_range_inline/docs/_description.md +1 -1
- data/app/pb_kits/playbook/pb_date_range_inline/docs/example.yml +3 -2
- data/app/pb_kits/playbook/pb_date_range_inline/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_date_stacked/docs/_date_stacked_current_year.html.erb +12 -0
- data/app/pb_kits/playbook/pb_date_stacked/docs/{_date_stacked_not_current_year.jsx → _date_stacked_current_year.jsx} +6 -5
- data/app/pb_kits/playbook/pb_date_stacked/docs/_date_stacked_current_year.md +1 -0
- data/app/pb_kits/playbook/pb_date_stacked/docs/_date_stacked_default.html.erb +1 -1
- data/app/pb_kits/playbook/pb_date_stacked/docs/_date_stacked_default.jsx +1 -1
- data/app/pb_kits/playbook/pb_date_stacked/docs/_description.md +1 -1
- data/app/pb_kits/playbook/pb_date_stacked/docs/example.yml +2 -2
- data/app/pb_kits/playbook/pb_date_stacked/docs/index.js +1 -1
- data/app/pb_kits/playbook/pb_dialog/docs/_dialog_compound_components.html.erb +2 -2
- data/app/pb_kits/playbook/pb_flex/docs/_flex_item_example.jsx +1 -0
- data/app/pb_kits/playbook/pb_nav/docs/_horizontal_nav_disabled.html.erb +21 -0
- data/app/pb_kits/playbook/pb_nav/docs/_horizontal_nav_disabled.jsx +113 -0
- data/app/pb_kits/playbook/pb_nav/docs/_horizontal_nav_disabled.md +1 -0
- data/app/pb_kits/playbook/pb_nav/docs/_vertical_nav_disabled.html.erb +30 -0
- data/app/pb_kits/playbook/pb_nav/docs/_vertical_nav_disabled.jsx +117 -0
- data/app/pb_kits/playbook/pb_nav/docs/_vertical_nav_disabled.md +1 -0
- data/app/pb_kits/playbook/pb_nav/docs/example.yml +4 -0
- data/app/pb_kits/playbook/pb_nav/docs/index.js +3 -1
- data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_description.md +3 -1
- data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_default.md +1 -0
- data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_legend_position.html.erb +1 -1
- data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_pb_bar_graph_legend_position.md +11 -0
- data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_description.md +3 -1
- data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_custom_tooltip.md +2 -1
- data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_pb_circle_chart_default.md +1 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_description.md +3 -1
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_color.md +2 -2
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_default.md +1 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_description.md +3 -1
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_default.md +1 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_legend_position.html.erb +1 -1
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_default_rails.md +7 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_focus.html.erb +10 -2
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_inline_rails.md +1 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_preview.html.erb +19 -11
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_simple.html.erb +5 -1
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_sticky.html.erb +1 -1
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_sticky_rails.md +1 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/example.yml +2 -2
- data/dist/playbook-doc.js +1 -19
- metadata +22 -4
- data/app/pb_kits/playbook/pb_date_stacked/docs/_date_stacked_not_current_year.html.erb +0 -5
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 0125f92eb4bea70ff3d240ae16b90b7206d0875e9293e00af19ad1dcb8dca0ee
|
|
4
|
+
data.tar.gz: d77073b4b5a7129aa5bd5717e072f09fb7c790f58f59349d3261baa9ca5567ce
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 72a50b537382360c9f18d2d5938cf6278d47d005f9c7f6cc105839b211a6e119aeb75fe1f60c2dafdf916780c59d8ba892528402306b79ef80c1c8770385e8c0
|
|
7
|
+
data.tar.gz: a613a51446f1c259b199db4845ee53af2927fc9a349549c8fd684648fba1a3a3ae455af6b6a3ef2f72ff4aefd33573fc3b877ab33f0aa0c7276926ba097deee5
|
data/app/pb_kits/playbook/pb_date_range_inline/docs/_date_range_inline_show_current_year.html.erb
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
<%= pb_rails("date_range_inline", props: { start_date: Date.new(Date.current.year, 10, 31), end_date: Date.new(Date.current.year, 12, 7), size: "xs", show_current_year: true }) %>
|
|
2
|
+
<%= pb_rails("date_range_inline", props: { start_date: Date.new(Date.current.year, 10, 31), end_date: Date.new(Date.current.year, 12, 7), show_current_year: true }) %>
|
|
3
|
+
<%= pb_rails("date_range_inline", props: { start_date: Date.new(Date.current.year, 10, 31), end_date: Date.new(Date.current.year, 12, 7), align: "center", icon: true, size: "xs", show_current_year: true }) %>
|
|
4
|
+
<%= pb_rails("date_range_inline", props: { start_date: Date.new(Date.current.year, 10, 31), end_date: Date.new(Date.current.year, 12, 7), align: "center", icon: true, show_current_year: true }) %>
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import DateRangeInline from '../_date_range_inline'
|
|
3
|
+
|
|
4
|
+
const DateRangeInlineShowCurrentYear = (props) => {
|
|
5
|
+
return (
|
|
6
|
+
<div>
|
|
7
|
+
<DateRangeInline
|
|
8
|
+
endDate={new Date(`7 Dec ${new Date().getFullYear()}`)}
|
|
9
|
+
showCurrentYear
|
|
10
|
+
size="xs"
|
|
11
|
+
startDate={new Date(`31 Oct ${new Date().getFullYear()}`)}
|
|
12
|
+
{...props}
|
|
13
|
+
/>
|
|
14
|
+
<DateRangeInline
|
|
15
|
+
endDate={new Date(`7 Dec ${new Date().getFullYear()}`)}
|
|
16
|
+
showCurrentYear
|
|
17
|
+
size="sm"
|
|
18
|
+
startDate={new Date(`31 Oct ${new Date().getFullYear()}`)}
|
|
19
|
+
{...props}
|
|
20
|
+
/>
|
|
21
|
+
<DateRangeInline
|
|
22
|
+
align="center"
|
|
23
|
+
endDate={new Date(`7 Dec ${new Date().getFullYear()}`)}
|
|
24
|
+
icon
|
|
25
|
+
showCurrentYear
|
|
26
|
+
size="xs"
|
|
27
|
+
startDate={new Date(`31 Oct ${new Date().getFullYear()}`)}
|
|
28
|
+
{...props}
|
|
29
|
+
/>
|
|
30
|
+
<DateRangeInline
|
|
31
|
+
align="center"
|
|
32
|
+
endDate={new Date(`7 Dec ${new Date().getFullYear()}`)}
|
|
33
|
+
icon
|
|
34
|
+
showCurrentYear
|
|
35
|
+
size="sm"
|
|
36
|
+
startDate={new Date(`31 Oct ${new Date().getFullYear()}`)}
|
|
37
|
+
{...props}
|
|
38
|
+
/>
|
|
39
|
+
</div>
|
|
40
|
+
)
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export default DateRangeInlineShowCurrentYear
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
By default, the Date Range Inline kit does NOT display the year if it is the current year. If you want to display the current year you can do so by setting `showCurrentYear`/`show_current_year` to true as shown here.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Use to display a date range.
|
|
1
|
+
Use to display a date range.
|
|
@@ -2,11 +2,12 @@ examples:
|
|
|
2
2
|
|
|
3
3
|
rails:
|
|
4
4
|
- date_range_inline_default: Default
|
|
5
|
-
|
|
5
|
+
- date_range_inline_show_current_year: Show Current Year
|
|
6
6
|
|
|
7
7
|
react:
|
|
8
8
|
- date_range_inline_default: Default
|
|
9
|
-
|
|
9
|
+
- date_range_inline_show_current_year: Show Current Year
|
|
10
|
+
|
|
10
11
|
swift:
|
|
11
12
|
- date_range_inline_default_swift: Default
|
|
12
13
|
- date_range_inline_props_swift: ""
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
import DateStacked from '../_date_stacked'
|
|
3
3
|
|
|
4
|
-
const
|
|
4
|
+
const DateStackedCurrentYear = (props) => {
|
|
5
5
|
return (
|
|
6
6
|
<div>
|
|
7
7
|
|
|
8
8
|
<DateStacked
|
|
9
|
-
date={new Date(
|
|
9
|
+
date={new Date()}
|
|
10
|
+
showCurrentYear
|
|
10
11
|
size="sm"
|
|
11
12
|
{...props}
|
|
12
13
|
/>
|
|
@@ -14,13 +15,13 @@ const DateStackedNotCurrentYear = (props) => {
|
|
|
14
15
|
<br />
|
|
15
16
|
|
|
16
17
|
<DateStacked
|
|
17
|
-
date={new Date(
|
|
18
|
+
date={new Date()}
|
|
19
|
+
showCurrentYear
|
|
18
20
|
size="md"
|
|
19
21
|
{...props}
|
|
20
22
|
/>
|
|
21
|
-
|
|
22
23
|
</div>
|
|
23
24
|
)
|
|
24
25
|
}
|
|
25
26
|
|
|
26
|
-
export default
|
|
27
|
+
export default DateStackedCurrentYear
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
By default, the Date Stacked kit does NOT display the year if it is the current year. If you want to display the current year you can do so by setting `showCurrentYear`/`show_current_year` to true as shown here.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Use to display the date, stacking month and day.
|
|
1
|
+
Use to display the date, stacking month and day.
|
|
@@ -2,7 +2,7 @@ examples:
|
|
|
2
2
|
|
|
3
3
|
rails:
|
|
4
4
|
- date_stacked_default: Default
|
|
5
|
-
-
|
|
5
|
+
- date_stacked_current_year: Show Current Year
|
|
6
6
|
- date_stacked_reverse: Day & Month Reverse
|
|
7
7
|
- date_stacked_sizes: Sizes
|
|
8
8
|
- date_stacked_align: Alignment
|
|
@@ -11,7 +11,7 @@ examples:
|
|
|
11
11
|
|
|
12
12
|
react:
|
|
13
13
|
- date_stacked_default: Default
|
|
14
|
-
-
|
|
14
|
+
- date_stacked_current_year: Show Current Year
|
|
15
15
|
- date_stacked_reverse: Day & Month Reverse
|
|
16
16
|
- date_stacked_sizes: Sizes
|
|
17
17
|
- date_stacked_bold: Bold
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export { default as DateStackedBold } from './_date_stacked_bold.jsx'
|
|
2
2
|
export { default as DateStackedDefault } from './_date_stacked_default.jsx'
|
|
3
|
-
export { default as
|
|
3
|
+
export { default as DateStackedCurrentYear } from './_date_stacked_current_year.jsx'
|
|
4
4
|
export { default as DateStackedReverse } from './_date_stacked_reverse.jsx'
|
|
5
5
|
export { default as DateStackedSizes } from './_date_stacked_sizes.jsx'
|
|
6
6
|
export { default as DateStackedAlign } from './_date_stacked_align.jsx'
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<%= pb_rails("button", props: { text: "Open Complex Dialog", data:{"open-dialog": "dialog-complex"} }) %>
|
|
2
2
|
|
|
3
3
|
<%= pb_rails("dialog", props: { id:"dialog-complex", size: "lg", full_height: true }) do %>
|
|
4
|
-
|
|
4
|
+
<%= pb_form_with(scope: :example, method: :get, url: "", options: { remote: true }) do |form| %>
|
|
5
5
|
<%= pb_rails("dialog/dialog_header", props: { id: "dialog-complex" } ) do %>
|
|
6
6
|
<%= pb_rails("body", props: { text: "What do you need us to take care of?" }) %>
|
|
7
7
|
<% end %>
|
|
@@ -13,5 +13,5 @@
|
|
|
13
13
|
|
|
14
14
|
<% end %>
|
|
15
15
|
<%= pb_rails("dialog/dialog_footer", props: {cancel_button: "Back", confirm_button: "Send my Issue", confirm_button_id:"confirm-complex", id: "dialog-complex"}) %>
|
|
16
|
-
|
|
16
|
+
<% end %>
|
|
17
17
|
<% end %>
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
<%= pb_rails("caption", props: { margin_bottom: "sm", text: "Default Variant" }) %>
|
|
2
|
+
<%= pb_rails("nav", props: { orientation: "horizontal" }) do %>
|
|
3
|
+
<%= pb_rails("nav/item", props: { text: "About", link: "#" }) %>
|
|
4
|
+
<%= pb_rails("nav/item", props: { text: "Case Studies", link: "#", active: true }) %>
|
|
5
|
+
<%= pb_rails("nav/item", props: { text: "Service ", link: "#", disabled: true }) %>
|
|
6
|
+
<%= pb_rails("nav/item", props: { text: "Contacts", link: "#" }) %>
|
|
7
|
+
<% end %>
|
|
8
|
+
<%= pb_rails("caption", props: { margin_bottom: "sm", margin_top:"lg", text: "Subtle Variant" }) %>
|
|
9
|
+
<%= pb_rails("nav", props: { orientation: "horizontal", variant: "subtle" }) do %>
|
|
10
|
+
<%= pb_rails("nav/item", props: { text: "About", link: "#" }) %>
|
|
11
|
+
<%= pb_rails("nav/item", props: { text: "Case Studies", link: "#", active: true }) %>
|
|
12
|
+
<%= pb_rails("nav/item", props: { text: "Service ", link: "#", disabled: true }) %>
|
|
13
|
+
<%= pb_rails("nav/item", props: { text: "Contacts", link: "#" }) %>
|
|
14
|
+
<% end %>
|
|
15
|
+
<%= pb_rails("caption", props: { margin_bottom: "sm", margin_top:"lg", text: "Bold Variant" }) %>
|
|
16
|
+
<%= pb_rails("nav", props: { orientation: "horizontal", variant: "bold" }) do %>
|
|
17
|
+
<%= pb_rails("nav/item", props: { text: "About", link: "#" }) %>
|
|
18
|
+
<%= pb_rails("nav/item", props: { text: "Case Studies", link: "#", active: true }) %>
|
|
19
|
+
<%= pb_rails("nav/item", props: { text: "Service ", link: "#", disabled: true }) %>
|
|
20
|
+
<%= pb_rails("nav/item", props: { text: "Contacts", link: "#" }) %>
|
|
21
|
+
<% end %>
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
|
|
3
|
+
import Nav from '../_nav'
|
|
4
|
+
import NavItem from '../_item'
|
|
5
|
+
import Caption from '../../pb_caption/_caption'
|
|
6
|
+
|
|
7
|
+
const HorizontalNavDisabled = (props) => {
|
|
8
|
+
return (
|
|
9
|
+
<>
|
|
10
|
+
<Caption marginBottom="sm">Default Variant</Caption>
|
|
11
|
+
<Nav
|
|
12
|
+
link="#"
|
|
13
|
+
orientation="horizontal"
|
|
14
|
+
{...props}
|
|
15
|
+
>
|
|
16
|
+
<NavItem
|
|
17
|
+
link="#"
|
|
18
|
+
text="About"
|
|
19
|
+
{...props}
|
|
20
|
+
/>
|
|
21
|
+
<NavItem
|
|
22
|
+
active
|
|
23
|
+
link="#"
|
|
24
|
+
text="Case Studies"
|
|
25
|
+
{...props}
|
|
26
|
+
/>
|
|
27
|
+
<NavItem
|
|
28
|
+
disabled
|
|
29
|
+
link="#"
|
|
30
|
+
text="Service"
|
|
31
|
+
{...props}
|
|
32
|
+
/>
|
|
33
|
+
<NavItem
|
|
34
|
+
link="#"
|
|
35
|
+
text="Contacts"
|
|
36
|
+
{...props}
|
|
37
|
+
/>
|
|
38
|
+
</Nav>
|
|
39
|
+
<Caption
|
|
40
|
+
marginBottom="sm"
|
|
41
|
+
marginTop="lg"
|
|
42
|
+
>
|
|
43
|
+
Subtle Variant
|
|
44
|
+
</Caption>
|
|
45
|
+
<Nav
|
|
46
|
+
link="#"
|
|
47
|
+
orientation="horizontal"
|
|
48
|
+
variant="subtle"
|
|
49
|
+
{...props}
|
|
50
|
+
>
|
|
51
|
+
<NavItem
|
|
52
|
+
link="#"
|
|
53
|
+
text="About"
|
|
54
|
+
{...props}
|
|
55
|
+
/>
|
|
56
|
+
<NavItem
|
|
57
|
+
active
|
|
58
|
+
link="#"
|
|
59
|
+
text="Case Studies"
|
|
60
|
+
{...props}
|
|
61
|
+
/>
|
|
62
|
+
<NavItem
|
|
63
|
+
disabled
|
|
64
|
+
link="#"
|
|
65
|
+
text="Service"
|
|
66
|
+
{...props}
|
|
67
|
+
/>
|
|
68
|
+
<NavItem
|
|
69
|
+
link="#"
|
|
70
|
+
text="Contacts"
|
|
71
|
+
{...props}
|
|
72
|
+
/>
|
|
73
|
+
</Nav>
|
|
74
|
+
<Caption
|
|
75
|
+
marginBottom="sm"
|
|
76
|
+
marginTop="lg"
|
|
77
|
+
>
|
|
78
|
+
Bold Variant
|
|
79
|
+
</Caption>
|
|
80
|
+
<Nav
|
|
81
|
+
link="#"
|
|
82
|
+
orientation="horizontal"
|
|
83
|
+
variant="bold"
|
|
84
|
+
{...props}
|
|
85
|
+
>
|
|
86
|
+
<NavItem
|
|
87
|
+
link="#"
|
|
88
|
+
text="About"
|
|
89
|
+
{...props}
|
|
90
|
+
/>
|
|
91
|
+
<NavItem
|
|
92
|
+
active
|
|
93
|
+
link="#"
|
|
94
|
+
text="Case Studies"
|
|
95
|
+
{...props}
|
|
96
|
+
/>
|
|
97
|
+
<NavItem
|
|
98
|
+
disabled
|
|
99
|
+
link="#"
|
|
100
|
+
text="Service"
|
|
101
|
+
{...props}
|
|
102
|
+
/>
|
|
103
|
+
<NavItem
|
|
104
|
+
link="#"
|
|
105
|
+
text="Contacts"
|
|
106
|
+
{...props}
|
|
107
|
+
/>
|
|
108
|
+
</Nav>
|
|
109
|
+
</>
|
|
110
|
+
)
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
export default HorizontalNavDisabled
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Use the `disabled` prop on a `navItem`/`nav_item` within a horizontal nav to set it as disabled. This will render the UI as disabled, prevent clicks and not allow for tabIndex to access the item.
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
<%= pb_rails("flex", props: { justify: "between" }) do %>
|
|
2
|
+
<%= pb_rails("flex", props: { orientation:"column", wrap: true }) do %>
|
|
3
|
+
<%= pb_rails("caption", props: { margin_bottom: "sm", text: "Default Variant" }) %>
|
|
4
|
+
<%= pb_rails("nav") do %>
|
|
5
|
+
<%= pb_rails("nav/item", props: { text: "About", link: "#" }) %>
|
|
6
|
+
<%= pb_rails("nav/item", props: { text: "Case Studies", link: "#", active: true }) %>
|
|
7
|
+
<%= pb_rails("nav/item", props: { text: "Service ", link: "#", disabled: true }) %>
|
|
8
|
+
<%= pb_rails("nav/item", props: { text: "Contacts", link: "#" }) %>
|
|
9
|
+
<% end %>
|
|
10
|
+
<% end %>
|
|
11
|
+
<%= pb_rails("flex", props: { orientation:"column", wrap: true }) do %>
|
|
12
|
+
<%= pb_rails("caption", props: { margin_bottom: "sm", text: "Subtle Variant" }) %>
|
|
13
|
+
<%= pb_rails("nav", props:{variant: "subtle"}) do %>
|
|
14
|
+
<%= pb_rails("nav/item", props: { text: "About", link: "#" }) %>
|
|
15
|
+
<%= pb_rails("nav/item", props: { text: "Case Studies", link: "#", active: true }) %>
|
|
16
|
+
<%= pb_rails("nav/item", props: { text: "Service ", link: "#", disabled: true }) %>
|
|
17
|
+
<%= pb_rails("nav/item", props: { text: "Contacts", link: "#" }) %>
|
|
18
|
+
<% end %>
|
|
19
|
+
<% end %>
|
|
20
|
+
<%= pb_rails("flex", props: { orientation:"column", wrap: true }) do %>
|
|
21
|
+
<%= pb_rails("caption", props: { margin_bottom: "sm", text: "Bold Variant" }) %>
|
|
22
|
+
<%= pb_rails("nav", props:{variant: "bold"}) do %>
|
|
23
|
+
<%= pb_rails("nav/item", props: { text: "About", link: "#" }) %>
|
|
24
|
+
<%= pb_rails("nav/item", props: { text: "Case Studies", link: "#", active: true }) %>
|
|
25
|
+
<%= pb_rails("nav/item", props: { text: "Service ", link: "#", disabled: true }) %>
|
|
26
|
+
<%= pb_rails("nav/item", props: { text: "Contacts", link: "#" }) %>
|
|
27
|
+
<% end %>
|
|
28
|
+
<% end %>
|
|
29
|
+
|
|
30
|
+
<% end %>
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
|
|
3
|
+
import Nav from '../_nav'
|
|
4
|
+
import NavItem from '../_item'
|
|
5
|
+
import Caption from '../../pb_caption/_caption'
|
|
6
|
+
import Flex from '../../pb_flex/_flex'
|
|
7
|
+
|
|
8
|
+
const VerticalNavDisabled = (props) => {
|
|
9
|
+
return (
|
|
10
|
+
<Flex justify="between"
|
|
11
|
+
wrap
|
|
12
|
+
>
|
|
13
|
+
<Flex orientation="column">
|
|
14
|
+
<Caption marginBottom="sm">Default Variant</Caption>
|
|
15
|
+
<Nav
|
|
16
|
+
link="#"
|
|
17
|
+
{...props}
|
|
18
|
+
>
|
|
19
|
+
<NavItem
|
|
20
|
+
link="#"
|
|
21
|
+
text="About"
|
|
22
|
+
{...props}
|
|
23
|
+
/>
|
|
24
|
+
<NavItem
|
|
25
|
+
active
|
|
26
|
+
link="#"
|
|
27
|
+
text="Case Studies"
|
|
28
|
+
{...props}
|
|
29
|
+
/>
|
|
30
|
+
<NavItem
|
|
31
|
+
disabled
|
|
32
|
+
link="#"
|
|
33
|
+
text="Service"
|
|
34
|
+
{...props}
|
|
35
|
+
/>
|
|
36
|
+
<NavItem
|
|
37
|
+
link="#"
|
|
38
|
+
text="Contacts"
|
|
39
|
+
{...props}
|
|
40
|
+
/>
|
|
41
|
+
</Nav>
|
|
42
|
+
</Flex>
|
|
43
|
+
<Flex orientation="column">
|
|
44
|
+
<Caption
|
|
45
|
+
marginBottom="sm"
|
|
46
|
+
>
|
|
47
|
+
Subtle Variant
|
|
48
|
+
</Caption>
|
|
49
|
+
<Nav
|
|
50
|
+
link="#"
|
|
51
|
+
variant="subtle"
|
|
52
|
+
{...props}
|
|
53
|
+
>
|
|
54
|
+
<NavItem
|
|
55
|
+
link="#"
|
|
56
|
+
text="About"
|
|
57
|
+
{...props}
|
|
58
|
+
/>
|
|
59
|
+
<NavItem
|
|
60
|
+
active
|
|
61
|
+
link="#"
|
|
62
|
+
text="Case Studies"
|
|
63
|
+
{...props}
|
|
64
|
+
/>
|
|
65
|
+
<NavItem
|
|
66
|
+
disabled
|
|
67
|
+
link="#"
|
|
68
|
+
text="Service"
|
|
69
|
+
{...props}
|
|
70
|
+
/>
|
|
71
|
+
<NavItem
|
|
72
|
+
link="#"
|
|
73
|
+
text="Contacts"
|
|
74
|
+
{...props}
|
|
75
|
+
/>
|
|
76
|
+
</Nav>
|
|
77
|
+
</Flex>
|
|
78
|
+
<Flex orientation="column">
|
|
79
|
+
<Caption
|
|
80
|
+
marginBottom="sm"
|
|
81
|
+
>
|
|
82
|
+
Bold Variant
|
|
83
|
+
</Caption>
|
|
84
|
+
<Nav
|
|
85
|
+
link="#"
|
|
86
|
+
variant="bold"
|
|
87
|
+
{...props}
|
|
88
|
+
>
|
|
89
|
+
<NavItem
|
|
90
|
+
link="#"
|
|
91
|
+
text="About"
|
|
92
|
+
{...props}
|
|
93
|
+
/>
|
|
94
|
+
<NavItem
|
|
95
|
+
active
|
|
96
|
+
link="#"
|
|
97
|
+
text="Case Studies"
|
|
98
|
+
{...props}
|
|
99
|
+
/>
|
|
100
|
+
<NavItem
|
|
101
|
+
disabled
|
|
102
|
+
link="#"
|
|
103
|
+
text="Service"
|
|
104
|
+
{...props}
|
|
105
|
+
/>
|
|
106
|
+
<NavItem
|
|
107
|
+
link="#"
|
|
108
|
+
text="Contacts"
|
|
109
|
+
{...props}
|
|
110
|
+
/>
|
|
111
|
+
</Nav>
|
|
112
|
+
</Flex>
|
|
113
|
+
</Flex>
|
|
114
|
+
)
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
export default VerticalNavDisabled
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Use the `disabled` prop on a `navItem`/`nav_item` within a vertical nav to set it as disabled. This will render the UI as disabled, prevent clicks and not allow for tabIndex to access the item.
|
|
@@ -18,6 +18,8 @@ examples:
|
|
|
18
18
|
- subtle_horizontal_nav: Subtle Horizontal Nav
|
|
19
19
|
- bold_horizontal_nav: Bold Horizontal Nav
|
|
20
20
|
- horizontal_nav_extendedunderline: Horizontal Nav With Extended Underline
|
|
21
|
+
- horizontal_nav_disabled: Horizontal Nav With Disabled Item
|
|
22
|
+
- vertical_nav_disabled: Vertical Nav With Disabled Item
|
|
21
23
|
- block_nav: Block
|
|
22
24
|
- block_no_title_nav: Without Title
|
|
23
25
|
- new_tab: Open in a New Tab
|
|
@@ -44,6 +46,8 @@ examples:
|
|
|
44
46
|
- subtle_horizontal_nav: Subtle Horizontal Nav
|
|
45
47
|
- bold_horizontal_nav: Bold Horizontal Nav
|
|
46
48
|
- horizontal_nav_extendedunderline: Horizontal Nav With Extended Underline
|
|
49
|
+
- horizontal_nav_disabled: Horizontal Nav With Disabled Item
|
|
50
|
+
- vertical_nav_disabled: Vertical Nav With Disabled Item
|
|
47
51
|
- block_nav: Block
|
|
48
52
|
- block_no_title_nav: Without Title
|
|
49
53
|
- new_tab: Open in a New Tab
|
|
@@ -20,4 +20,6 @@ export { default as NavWithFontControl } from "./_nav_with_font_control.jsx"
|
|
|
20
20
|
export { default as NavWithSpacingControl } from "./_nav_with_spacing_control.jsx"
|
|
21
21
|
export { default as CollapsibleNavItemSpacing } from "./_collapsible_nav_item_spacing.jsx"
|
|
22
22
|
export { default as CollapsibleNavNoIcon } from "./_collapsible_nav_no_icon.jsx"
|
|
23
|
-
export { default as HorizontalNavExtendedunderline } from './_horizontal_nav_extendedunderline.jsx'
|
|
23
|
+
export { default as HorizontalNavExtendedunderline } from './_horizontal_nav_extendedunderline.jsx'
|
|
24
|
+
export { default as HorizontalNavDisabled } from './_horizontal_nav_disabled.jsx'
|
|
25
|
+
export { default as VerticalNavDisabled } from './_vertical_nav_disabled.jsx'
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
**In order to use this kit, 'highcharts' and 'highcharts-react-official' must be installed in your repo.**
|
|
2
|
+
|
|
3
|
+
This kit is a wrapper around the Highcharts library. It applies styling and default settings but does NOT ship Highcharts. Once 'highcharts' and 'highcharts-react-official are installed into your repo, any prop or functionality provided by Highcharts can be used with this kit without requiring specific props from Playbook. The doc examples below showcase a few common usecases but are not a comprehensive list of all the functionalities possible.
|
|
2
4
|
|
|
3
5
|
See the [highcharts API docs](https://api.highcharts.com/highcharts/) for a comprehensive look at what is possible.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
In order to use this kit, 'highcharts' and 'highcharts-react-official' must be installed in your repo.
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
}
|
|
37
37
|
%>
|
|
38
38
|
|
|
39
|
-
<%= pb_rails("title", props: {size: 4, text: "align |
|
|
39
|
+
<%= pb_rails("title", props: {size: 4, text: "align | verticalAlign", padding_top: "sm", padding_bottom: "sm"})%>
|
|
40
40
|
|
|
41
41
|
|
|
42
42
|
<%= pb_rails("pb_bar_graph", props: {options: chart_options_right}) %>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
Highcharts provides many options for customizing the legend display. This example showcases the following:
|
|
2
|
+
|
|
3
|
+
`align` can be used to align the legend left, right or center (defaults to center)
|
|
4
|
+
|
|
5
|
+
`verticalAlign` can be used to place the legend above the graph. Options are top, middle, bottom with default set to bottom
|
|
6
|
+
|
|
7
|
+
`layout` determines the position of the legend items. Options are horizontal, vertical or proximate with default set to horizontal `layout: proximate` will place the legend items as close as possible to the graphs they're representing. It will also determine whether to place the legend above/below or on the side of the plot area, if the legend is in a corner.
|
|
8
|
+
|
|
9
|
+
`x` offsets the legend relative to its horizontal alignment. Negative x moves it to the left, positive x moves it to the right (defaults to 0)
|
|
10
|
+
|
|
11
|
+
`y` offsets the legend relative to its vertical alignment. Negative y moves it up, positive y moves it down (defaults to 0)
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
**In order to use this kit, 'highcharts' and 'highcharts-react-official' must be installed in your repo.**
|
|
2
|
+
|
|
3
|
+
This kit is a wrapper around the Highcharts library. It applies styling and default settings but does NOT ship Highcharts. Once 'highcharts' and 'highcharts-react-official are installed into your repo, any prop or functionality provided by Highcharts can be used with this kit without requiring specific props from Playbook. The doc examples below showcase a few common usecases but are not a comprehensive list of all the functionalities possible.
|
|
2
4
|
|
|
3
5
|
See the [highcharts API docs](https://api.highcharts.com/highcharts/) for a comprehensive look at what is possible.
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
Tooltip options from Highcharts:
|
|
2
|
+
|
|
2
3
|
`headerFormat` **Type**: String | when set to null will disable the header.
|
|
3
4
|
`pointFormat` **Type**: String | defines the HTML template for each data point and supports custom HTML when `useHTML` is enabled.
|
|
4
5
|
`useHTML` **Type**: boolean (default false) | enables HTML rendering in tooltips.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
In order to use this kit, 'highcharts' and 'highcharts-react-official' must be installed in your repo.
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
**In order to use this kit, 'highcharts' and 'highcharts-react-official' must be installed in your repo.**
|
|
2
|
+
|
|
3
|
+
This kit is a wrapper around the Highcharts library. It applies styling and default settings but does NOT ship Highcharts. Once 'highcharts' and 'highcharts-react-official are installed into your repo, any prop or functionality provided by Highcharts can be used with this kit without requiring specific props from Playbook. The doc examples below showcase a few common usecases but are not a comprehensive list of all the functionalities possible.
|
|
2
4
|
|
|
3
5
|
See the [highcharts API docs](https://api.highcharts.com/highcharts/) for a comprehensive look at what is possible.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Highcharts allows for any custom colors to be used. Custom data colors allow for color customization to match the needs of business requirements.
|
|
2
2
|
|
|
3
|
-
For React, pass the
|
|
3
|
+
For React, pass the option `plotOptions.solidgauge.borderColor` with a Playbook token like `colors.` + `data_1 | data_2 | data_3 | data_4 | data_5 | data_6 | data_7 | data_8`. HEX colors are also available `eg: #CA0095`
|
|
4
4
|
|
|
5
|
-
For Rails, the
|
|
5
|
+
For Rails, the option `plotOptions.solidgauge.borderColor` can only be used with HEX values as shown.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
In order to use this kit, 'highcharts' and 'highcharts-react-official' must be installed in your repo.
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
**In order to use this kit, 'highcharts' and 'highcharts-react-official' must be installed in your repo.**
|
|
2
|
+
|
|
3
|
+
This kit is a wrapper around the Highcharts library. It applies styling and default settings but does NOT ship Highcharts. Once 'highcharts' and 'highcharts-react-official are installed into your repo, any prop or functionality provided by Highcharts can be used with this kit without requiring specific props from Playbook. The doc examples below showcase a few common usecases but are not a comprehensive list of all the functionalities possible.
|
|
2
4
|
|
|
3
5
|
See the [highcharts API docs](https://api.highcharts.com/highcharts/) for a comprehensive look at what is possible.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
In order to use this kit, 'highcharts' and 'highcharts-react-official' must be installed in your repo.
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
},
|
|
38
38
|
} %>
|
|
39
39
|
|
|
40
|
-
<%= pb_rails("title", props: {size: 4, text: "align |
|
|
40
|
+
<%= pb_rails("title", props: {size: 4, text: "align | verticalAlign", padding_top: "sm", padding_bottom: "sm"})%>
|
|
41
41
|
<%= pb_rails("pb_line_graph", props: {options: chartOptionsFirst}) %>
|
|
42
42
|
|
|
43
43
|
<% chartOptionsSecond = {
|