playbook_ui 10.19.0.pre.popover.alpha1 → 10.19.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_button/_button.jsx +3 -3
- data/app/pb_kits/playbook/pb_button/_button.scss +0 -17
- data/app/pb_kits/playbook/pb_button/button.rb +3 -6
- data/app/pb_kits/playbook/pb_button/button.test.js +0 -13
- data/app/pb_kits/playbook/pb_button/docs/example.yml +0 -2
- data/app/pb_kits/playbook/pb_button/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_date_picker/_date_picker.jsx +3 -0
- data/app/pb_kits/playbook/pb_date_picker/_date_picker.scss +1 -0
- data/app/pb_kits/playbook/pb_date_picker/date_picker.rb +3 -0
- data/app/pb_kits/playbook/pb_date_picker/date_picker_helper.js +10 -1
- data/app/pb_kits/playbook/pb_date_picker/docs/_date_picker_month_and_year.html.erb +5 -0
- data/app/pb_kits/playbook/pb_date_picker/docs/_date_picker_month_and_year.jsx +18 -0
- data/app/pb_kits/playbook/pb_date_picker/docs/_date_picker_month_and_year.md +1 -0
- data/app/pb_kits/playbook/pb_date_picker/docs/example.yml +2 -0
- data/app/pb_kits/playbook/pb_date_picker/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_date_picker/sass_partials/_month_and_year_styles.scss +127 -0
- data/app/pb_kits/playbook/pb_image/_image.jsx +12 -14
- data/app/pb_kits/playbook/pb_image/docs/_custom_error_image.html.erb +1 -0
- data/app/pb_kits/playbook/pb_image/docs/_default_image.jsx +48 -35
- data/app/pb_kits/playbook/pb_image/docs/_rounded_image.jsx +46 -35
- data/app/pb_kits/playbook/pb_legend/_legend.jsx +1 -7
- data/app/pb_kits/playbook/pb_legend/_legend.scss +6 -2
- data/app/pb_kits/playbook/pb_legend/docs/_legend_colors.html.erb +4 -0
- data/app/pb_kits/playbook/pb_legend/docs/_legend_colors.jsx +29 -0
- data/app/pb_kits/playbook/pb_legend/docs/_legend_colors.md +2 -0
- data/app/pb_kits/playbook/pb_legend/docs/_legend_default.html.erb +2 -2
- data/app/pb_kits/playbook/pb_legend/docs/_legend_default.jsx +1 -1
- data/app/pb_kits/playbook/pb_legend/docs/example.yml +4 -4
- data/app/pb_kits/playbook/pb_legend/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_legend/legend.rb +1 -2
- data/app/pb_kits/playbook/pb_legend/legend.test.js +29 -0
- data/app/pb_kits/playbook/pb_popover/_popover.jsx +4 -2
- data/app/pb_kits/playbook/pb_popover/docs/_popover_close.html.erb +7 -7
- data/app/pb_kits/playbook/pb_popover/index.js +9 -4
- data/app/pb_kits/playbook/pb_popover/popover.html.erb +1 -1
- data/app/pb_kits/playbook/pb_section_separator/_section_separator.scss +6 -2
- data/app/pb_kits/playbook/pb_section_separator/_section_separator_mixin.scss +0 -2
- data/app/pb_kits/playbook/pb_text_input/_text_input.scss +3 -3
- data/app/pb_kits/playbook/pb_title/title.html.erb +2 -3
- data/lib/playbook/version.rb +2 -2
- metadata +12 -7
- data/app/pb_kits/playbook/pb_button/docs/_button_size.html.erb +0 -3
- data/app/pb_kits/playbook/pb_button/docs/_button_size.jsx +0 -26
- data/app/pb_kits/playbook/pb_button/docs/_button_size.md +0 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 2aee1f2c048d8521387c720ec1de805f4b141ac36d596a51cd785cda18964425
|
|
4
|
+
data.tar.gz: c66e833a6eae63f445b75cb3c89845a9096e57c45771c085102d1f2ee1b5dac0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e232f695466a3fa606ef20b3416d2c4684e613ae6a278c3d7c957e502dcebecb6ad28109db1422a89928451bee0df24728d2e0bdfc30143ca5422e314bfc6c45
|
|
7
|
+
data.tar.gz: 45904dac97847a942877f532d363552702f762bee32c97e096a346efeb32d0fb8e55e7fc7b81ebcf767a0fb1b95ec722669eb989fe85b7f4f13606d130e2a16a
|
|
@@ -22,7 +22,7 @@ type ButtonPropTypes = {
|
|
|
22
22
|
loading?: boolean,
|
|
23
23
|
newWindow?: boolean,
|
|
24
24
|
onClick?: EventHandler,
|
|
25
|
-
size
|
|
25
|
+
size: 'large' | 'medium' | 'small',
|
|
26
26
|
text?: string,
|
|
27
27
|
type: 'inline' | null,
|
|
28
28
|
htmlType: string | 'button',
|
|
@@ -36,16 +36,16 @@ const buttonClassName = (props: ButtonPropTypes) => {
|
|
|
36
36
|
disabled = false,
|
|
37
37
|
fullWidth = false,
|
|
38
38
|
loading = false,
|
|
39
|
+
size = null,
|
|
39
40
|
type = 'inline',
|
|
40
41
|
variant = 'primary',
|
|
41
|
-
size = null,
|
|
42
42
|
} = props
|
|
43
43
|
|
|
44
44
|
let className = 'pb_button_kit'
|
|
45
45
|
|
|
46
|
-
className += `${size !== null ? `_${size}` : ''}`
|
|
47
46
|
className += `${variant !== null ? `_${variant}` : ''}`
|
|
48
47
|
className += `${type !== null ? `_${type}` : ''}`
|
|
48
|
+
className += `${size !== null ? `_${size}` : ''}`
|
|
49
49
|
className += `${fullWidth ? '_block' : ''}`
|
|
50
50
|
className += disabled ? '_disabled' : '_enabled'
|
|
51
51
|
className += loading ? '_loading' : ''
|
|
@@ -1,24 +1,7 @@
|
|
|
1
1
|
@import "./button_mixins";
|
|
2
2
|
|
|
3
|
-
$pb_button_sizes: (
|
|
4
|
-
"sm": 0.75rem,
|
|
5
|
-
"md": 0.875rem,
|
|
6
|
-
"lg": 1.125rem,
|
|
7
|
-
);
|
|
8
|
-
|
|
9
3
|
[class^=pb_button_kit]{
|
|
10
4
|
@include pb_button;
|
|
11
|
-
// Size =================
|
|
12
|
-
@each $name, $size in $pb_button_sizes {
|
|
13
|
-
&[class*=_#{$name}] {
|
|
14
|
-
font-size: $size;
|
|
15
|
-
padding: calc(#{$size} / 2) calc(#{$size} * 2.42) !important;
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
&[class*=_sm] {
|
|
19
|
-
min-height: 0;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
5
|
// Variants =================
|
|
23
6
|
&[class*=_primary] {
|
|
24
7
|
@include pb_button_primary;
|
|
@@ -18,9 +18,6 @@ module Playbook
|
|
|
18
18
|
prop :text
|
|
19
19
|
prop :type
|
|
20
20
|
prop :value
|
|
21
|
-
prop :size, type: Playbook::Props::Enum,
|
|
22
|
-
values: ["sm", "md", "lg", nil],
|
|
23
|
-
default: nil
|
|
24
21
|
|
|
25
22
|
def options
|
|
26
23
|
{
|
|
@@ -47,12 +44,12 @@ module Playbook
|
|
|
47
44
|
link ? "a" : "button"
|
|
48
45
|
end
|
|
49
46
|
|
|
47
|
+
private
|
|
48
|
+
|
|
50
49
|
def classname
|
|
51
|
-
generate_classname("pb_button_kit",
|
|
50
|
+
generate_classname("pb_button_kit", variant, full_width_class, disabled_class, loading_class)
|
|
52
51
|
end
|
|
53
52
|
|
|
54
|
-
private
|
|
55
|
-
|
|
56
53
|
def disabled_class
|
|
57
54
|
disabled ? "disabled" : "enabled"
|
|
58
55
|
end
|
|
@@ -89,16 +89,3 @@ test('click event', async () => {
|
|
|
89
89
|
|
|
90
90
|
expect(screen.getByText('clicked button!')).toBeInTheDocument()
|
|
91
91
|
})
|
|
92
|
-
|
|
93
|
-
test('size prop', () => {
|
|
94
|
-
render(
|
|
95
|
-
<Button
|
|
96
|
-
data={{ testid: 'size-test' }}
|
|
97
|
-
size="sm"
|
|
98
|
-
/>
|
|
99
|
-
)
|
|
100
|
-
|
|
101
|
-
const kit = screen.getByTestId('size-test')
|
|
102
|
-
|
|
103
|
-
expect(kit).toHaveClass('pb_button_kit_sm_primary_inline_enabled')
|
|
104
|
-
})
|
|
@@ -7,7 +7,6 @@ examples:
|
|
|
7
7
|
- button_block_content: Button Block Content
|
|
8
8
|
- button_accessibility: Button Accessibility Options
|
|
9
9
|
- button_options: Button Additional Options
|
|
10
|
-
- button_size: Button Size
|
|
11
10
|
react:
|
|
12
11
|
- button_default: Button Variants
|
|
13
12
|
- button_full_width: Button Full Width
|
|
@@ -16,4 +15,3 @@ examples:
|
|
|
16
15
|
- button_block_content: Button Block Content
|
|
17
16
|
- button_accessibility: Button Accessibility Options
|
|
18
17
|
- button_options: Button Additional Options (onClick)
|
|
19
|
-
- button_size: Button Size
|
|
@@ -5,4 +5,3 @@ export { default as ButtonLoading } from './_button_loading.jsx'
|
|
|
5
5
|
export { default as ButtonBlockContent } from './_button_block_content.jsx'
|
|
6
6
|
export { default as ButtonAccessibility } from './_button_accessibility.jsx'
|
|
7
7
|
export { default as ButtonOptions } from './_button_options.jsx'
|
|
8
|
-
export { default as ButtonSize } from './_button_size.jsx'
|
|
@@ -40,6 +40,7 @@ type DatePickerProps = {
|
|
|
40
40
|
onChange: (String) => void,
|
|
41
41
|
pickerId?: String,
|
|
42
42
|
placeholder?: String,
|
|
43
|
+
plugins?: Boolean,
|
|
43
44
|
type?: String,
|
|
44
45
|
yearRange?: Array,
|
|
45
46
|
}
|
|
@@ -73,6 +74,7 @@ const DatePicker = (props: DatePickerProps) => {
|
|
|
73
74
|
onChange = () => {},
|
|
74
75
|
pickerId,
|
|
75
76
|
placeholder = 'Select Date',
|
|
77
|
+
plugins = false,
|
|
76
78
|
yearRange = [ 1900, 2100 ],
|
|
77
79
|
} = props
|
|
78
80
|
|
|
@@ -100,6 +102,7 @@ const DatePicker = (props: DatePickerProps) => {
|
|
|
100
102
|
mode: mode,
|
|
101
103
|
onChange: onChange,
|
|
102
104
|
pickerId: pickerId,
|
|
105
|
+
plugins: plugins,
|
|
103
106
|
yearRange: yearRange,
|
|
104
107
|
})
|
|
105
108
|
}, [])
|
|
@@ -41,6 +41,8 @@ module Playbook
|
|
|
41
41
|
required: true
|
|
42
42
|
prop :placeholder, type: Playbook::Props::String,
|
|
43
43
|
default: "Select Date"
|
|
44
|
+
prop :plugins, type: Playbook::Props::Boolean,
|
|
45
|
+
default: false
|
|
44
46
|
prop :required, type: Playbook::Props::Boolean,
|
|
45
47
|
default: false
|
|
46
48
|
prop :year_range, type: Playbook::Props::Array,
|
|
@@ -64,6 +66,7 @@ module Playbook
|
|
|
64
66
|
minDate: min_date,
|
|
65
67
|
mode: mode,
|
|
66
68
|
pickerId: picker_id,
|
|
69
|
+
plugins: plugins,
|
|
67
70
|
required: required,
|
|
68
71
|
yearRange: year_range,
|
|
69
72
|
}.to_json.html_safe
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import flatpickr from 'flatpickr'
|
|
2
|
+
import monthSelectPlugin from 'flatpickr/dist/plugins/monthSelect'
|
|
2
3
|
|
|
3
4
|
const datePickerHelper = (config) => {
|
|
4
5
|
const {
|
|
@@ -13,6 +14,7 @@ const datePickerHelper = (config) => {
|
|
|
13
14
|
mode,
|
|
14
15
|
onChange = () => {},
|
|
15
16
|
pickerId,
|
|
17
|
+
plugins,
|
|
16
18
|
required,
|
|
17
19
|
yearRange,
|
|
18
20
|
} = config
|
|
@@ -50,6 +52,10 @@ const datePickerHelper = (config) => {
|
|
|
50
52
|
}
|
|
51
53
|
}
|
|
52
54
|
|
|
55
|
+
const setMonthAndYearPlugin = () => (
|
|
56
|
+
plugins ? [ monthSelectPlugin({ shorthand: true, dateFormat: 'F Y', altFormat: 'F Y' }) ] : []
|
|
57
|
+
)
|
|
58
|
+
|
|
53
59
|
// ===========================================================
|
|
54
60
|
// | Flatpickr initializer w/ config |
|
|
55
61
|
// ===========================================================
|
|
@@ -97,6 +103,7 @@ const datePickerHelper = (config) => {
|
|
|
97
103
|
onYearChange: [() => {
|
|
98
104
|
yearChangeHook()
|
|
99
105
|
}],
|
|
106
|
+
plugins: setMonthAndYearPlugin(),
|
|
100
107
|
prevArrow: '<i class="far fa-angle-left"></i>',
|
|
101
108
|
static: true,
|
|
102
109
|
})
|
|
@@ -153,8 +160,10 @@ const datePickerHelper = (config) => {
|
|
|
153
160
|
}
|
|
154
161
|
|
|
155
162
|
// Adding dropdown icons to year and month selects
|
|
156
|
-
picker.monthElements[0].insertAdjacentHTML('afterend', '<i class="far fa-angle-down month-dropdown-icon"></i>')
|
|
157
163
|
dropdown.insertAdjacentHTML('afterend', '<i class="far fa-angle-down year-dropdown-icon" id="test-id"></i>')
|
|
164
|
+
if (picker.monthElements[0].parentElement) {
|
|
165
|
+
return picker.monthElements[0].insertAdjacentHTML('afterend', '<i class="far fa-angle-down month-dropdown-icon"></i>')
|
|
166
|
+
}
|
|
158
167
|
|
|
159
168
|
// Remove readonly attribute for validation and or text input
|
|
160
169
|
if (allowInput){
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
|
|
3
|
+
import DatePicker from '../_date_picker'
|
|
4
|
+
|
|
5
|
+
const DatePickerMonthAndYear = (props) => {
|
|
6
|
+
return (
|
|
7
|
+
<div>
|
|
8
|
+
<DatePicker
|
|
9
|
+
label="Date Picker"
|
|
10
|
+
pickerId="disabled-date"
|
|
11
|
+
plugins
|
|
12
|
+
{...props}
|
|
13
|
+
/>
|
|
14
|
+
</div>
|
|
15
|
+
)
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export default DatePickerMonthAndYear
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
By default month&year plugin is disabled. To activate it set `plugins` prop to `true`. If you're using React just pass a `plugins` prop to the kit.
|
|
@@ -16,6 +16,7 @@ examples:
|
|
|
16
16
|
- date_picker_year_range: Year Range
|
|
17
17
|
- date_picker_anti_patterns: Anti-Patterns
|
|
18
18
|
- date_picker_inline: Inline
|
|
19
|
+
- date_picker_month_and_year: Month & Year Only
|
|
19
20
|
|
|
20
21
|
|
|
21
22
|
react:
|
|
@@ -34,3 +35,4 @@ examples:
|
|
|
34
35
|
- date_picker_hooks: Hooks
|
|
35
36
|
- date_picker_year_range: Year Range
|
|
36
37
|
- date_picker_inline: Inline
|
|
38
|
+
- date_picker_month_and_year: Month & Year Only
|
|
@@ -13,3 +13,4 @@ export { default as DatePickerHooks } from './_date_picker_hooks.jsx'
|
|
|
13
13
|
export { default as DatePickerFlatpickrMethods } from './_date_picker_flatpickr_methods.jsx'
|
|
14
14
|
export { default as DatePickerYearRange } from './_date_picker_year_range.jsx'
|
|
15
15
|
export { default as DatePickerInline } from './_date_picker_inline.jsx'
|
|
16
|
+
export { default as DatePickerMonthAndYear } from './_date_picker_month_and_year.jsx'
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
@import "../../tokens/colors";
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
.numInput {
|
|
5
|
+
border-left: none !important;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
// Manual Import
|
|
9
|
+
.flatpickr-monthSelect-months {
|
|
10
|
+
margin: 10px 1px 3px 1px;
|
|
11
|
+
flex-wrap: wrap;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.flatpickr-monthSelect-month {
|
|
15
|
+
background: none;
|
|
16
|
+
border: 1px solid transparent;
|
|
17
|
+
border-radius: 4px;
|
|
18
|
+
-webkit-box-sizing: border-box;
|
|
19
|
+
box-sizing: border-box;
|
|
20
|
+
color: $text_lt_default;
|
|
21
|
+
cursor: pointer;
|
|
22
|
+
display: inline-block;
|
|
23
|
+
font-weight: 400;
|
|
24
|
+
margin: 0.5px;
|
|
25
|
+
justify-content: center;
|
|
26
|
+
padding: 10px;
|
|
27
|
+
position: relative;
|
|
28
|
+
-webkit-box-pack: center;
|
|
29
|
+
-webkit-justify-content: center;
|
|
30
|
+
-ms-flex-pack: center;
|
|
31
|
+
text-align: center;
|
|
32
|
+
width: 33%;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.flatpickr-monthSelect-month.flatpickr-disabled {
|
|
36
|
+
color: #eee;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.flatpickr-monthSelect-month.flatpickr-disabled:hover,
|
|
40
|
+
.flatpickr-monthSelect-month.flatpickr-disabled:focus {
|
|
41
|
+
cursor: not-allowed;
|
|
42
|
+
background: none !important;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.flatpickr-monthSelect-theme-dark {
|
|
46
|
+
background: #3f4458;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.flatpickr-monthSelect-theme-dark .flatpickr-current-month input.cur-year {
|
|
50
|
+
color: #fff;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.flatpickr-monthSelect-theme-dark .flatpickr-months .flatpickr-prev-month,
|
|
54
|
+
.flatpickr-monthSelect-theme-dark .flatpickr-months .flatpickr-next-month {
|
|
55
|
+
color: #fff;
|
|
56
|
+
fill: #fff;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.flatpickr-monthSelect-theme-dark .flatpickr-monthSelect-month {
|
|
60
|
+
color: rgba(255, 255, 255, 0.95);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.flatpickr-monthSelect-month.today {
|
|
64
|
+
border-color: #959ea9;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
.flatpickr-monthSelect-month.inRange,
|
|
68
|
+
.flatpickr-monthSelect-month.inRange.today,
|
|
69
|
+
.flatpickr-monthSelect-month:hover,
|
|
70
|
+
.flatpickr-monthSelect-month:focus {
|
|
71
|
+
background: $active_light;
|
|
72
|
+
font-weight: $bold;
|
|
73
|
+
color: $text_lt_default;
|
|
74
|
+
cursor: pointer;
|
|
75
|
+
outline: 0;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.flatpickr-monthSelect-theme-dark .flatpickr-monthSelect-month.inRange,
|
|
79
|
+
.flatpickr-monthSelect-theme-dark .flatpickr-monthSelect-month:hover,
|
|
80
|
+
.flatpickr-monthSelect-theme-dark .flatpickr-monthSelect-month:focus {
|
|
81
|
+
background: #646c8c;
|
|
82
|
+
border-color: #646c8c;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.flatpickr-monthSelect-month.today:hover,
|
|
86
|
+
.flatpickr-monthSelect-month.today:focus {
|
|
87
|
+
background: #959ea9;
|
|
88
|
+
border-color: #959ea9;
|
|
89
|
+
color: #fff;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.flatpickr-monthSelect-month.selected,
|
|
93
|
+
.flatpickr-monthSelect-month.startRange,
|
|
94
|
+
.flatpickr-monthSelect-month.endRange {
|
|
95
|
+
background-color: $primary;
|
|
96
|
+
font-weight: $bold;
|
|
97
|
+
box-shadow: none;
|
|
98
|
+
color: #fff;
|
|
99
|
+
border-color: $primary;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.flatpickr-monthSelect-month.startRange {
|
|
103
|
+
border-radius: 50px 0 0 50px;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
.flatpickr-monthSelect-month.endRange {
|
|
107
|
+
border-radius: 0 50px 50px 0;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.flatpickr-monthSelect-month.startRange.endRange {
|
|
111
|
+
border-radius: 50px;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.flatpickr-monthSelect-month.inRange {
|
|
115
|
+
border-radius: 0;
|
|
116
|
+
box-shadow: -5px 0 0 #e6e6e6, 5px 0 0 #e6e6e6;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.flatpickr-monthSelect-theme-dark .flatpickr-monthSelect-month.selected,
|
|
120
|
+
.flatpickr-monthSelect-theme-dark .flatpickr-monthSelect-month.startRange,
|
|
121
|
+
.flatpickr-monthSelect-theme-dark .flatpickr-monthSelect-month.endRange {
|
|
122
|
+
background: #80cbc4;
|
|
123
|
+
-webkit-box-shadow: none;
|
|
124
|
+
box-shadow: none;
|
|
125
|
+
color: #fff;
|
|
126
|
+
border-color: #80cbc4;
|
|
127
|
+
}
|
|
@@ -44,20 +44,18 @@ const Image = (props: ImageProps) => {
|
|
|
44
44
|
const dataProps = buildDataProps(data)
|
|
45
45
|
|
|
46
46
|
return (
|
|
47
|
-
<
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
/>
|
|
60
|
-
</div>
|
|
47
|
+
<img
|
|
48
|
+
{...ariaProps}
|
|
49
|
+
{...dataProps}
|
|
50
|
+
alt={alt}
|
|
51
|
+
className={classes}
|
|
52
|
+
data-src={url}
|
|
53
|
+
id={id}
|
|
54
|
+
onError={onError}
|
|
55
|
+
rounded={+rounded}
|
|
56
|
+
src={url}
|
|
57
|
+
transition={transition}
|
|
58
|
+
/>
|
|
61
59
|
)
|
|
62
60
|
}
|
|
63
61
|
|
|
@@ -5,41 +5,54 @@ import Image from '../_image'
|
|
|
5
5
|
const DefaultImage = (props) => {
|
|
6
6
|
return (
|
|
7
7
|
<>
|
|
8
|
-
<
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
8
|
+
<br />
|
|
9
|
+
<div>
|
|
10
|
+
<Image
|
|
11
|
+
alt="picture of a misty forest"
|
|
12
|
+
size="xs"
|
|
13
|
+
url="https://unsplash.it/500/400/?image=634"
|
|
14
|
+
{...props}
|
|
15
|
+
/>
|
|
16
|
+
</div>
|
|
17
|
+
<div>
|
|
18
|
+
<Image
|
|
19
|
+
alt="picture of a misty forest"
|
|
20
|
+
size="sm"
|
|
21
|
+
url="https://unsplash.it/500/400/?image=634"
|
|
22
|
+
{...props}
|
|
23
|
+
/>
|
|
24
|
+
</div>
|
|
25
|
+
<div>
|
|
26
|
+
<Image
|
|
27
|
+
alt="picture of a misty forest"
|
|
28
|
+
size="md"
|
|
29
|
+
url="https://unsplash.it/500/400/?image=634"
|
|
30
|
+
{...props}
|
|
31
|
+
/>
|
|
32
|
+
</div>
|
|
33
|
+
<div>
|
|
34
|
+
<Image
|
|
35
|
+
alt="picture of a misty forest"
|
|
36
|
+
size="lg"
|
|
37
|
+
url="https://unsplash.it/500/400/?image=634"
|
|
38
|
+
{...props}
|
|
39
|
+
/>
|
|
40
|
+
</div>
|
|
41
|
+
<div>
|
|
42
|
+
<Image
|
|
43
|
+
alt="picture of a misty forest"
|
|
44
|
+
size="xl"
|
|
45
|
+
url="https://unsplash.it/500/400/?image=634"
|
|
46
|
+
{...props}
|
|
47
|
+
/>
|
|
48
|
+
</div>
|
|
49
|
+
<div>
|
|
50
|
+
<Image
|
|
51
|
+
alt="picture of a misty forest"
|
|
52
|
+
url="https://unsplash.it/500/400/?image=634"
|
|
53
|
+
{...props}
|
|
54
|
+
/>
|
|
55
|
+
</div>
|
|
43
56
|
</>
|
|
44
57
|
)
|
|
45
58
|
}
|
|
@@ -5,41 +5,52 @@ import Image from '../_image'
|
|
|
5
5
|
const RoundedImage = (props) => {
|
|
6
6
|
return (
|
|
7
7
|
<>
|
|
8
|
-
<
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
<
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
8
|
+
<br />
|
|
9
|
+
<div>
|
|
10
|
+
<Image
|
|
11
|
+
alt=""
|
|
12
|
+
rounded
|
|
13
|
+
size="xs"
|
|
14
|
+
url="https://unsplash.it/500/400/?image=634"
|
|
15
|
+
{...props}
|
|
16
|
+
/>
|
|
17
|
+
</div>
|
|
18
|
+
<div>
|
|
19
|
+
<Image
|
|
20
|
+
alt=""
|
|
21
|
+
rounded
|
|
22
|
+
size="sm"
|
|
23
|
+
url="https://unsplash.it/500/400/?image=634"
|
|
24
|
+
{...props}
|
|
25
|
+
/>
|
|
26
|
+
</div>
|
|
27
|
+
<div>
|
|
28
|
+
<Image
|
|
29
|
+
alt=""
|
|
30
|
+
rounded
|
|
31
|
+
size="md"
|
|
32
|
+
url="https://unsplash.it/500/400/?image=634"
|
|
33
|
+
{...props}
|
|
34
|
+
/>
|
|
35
|
+
</div>
|
|
36
|
+
<div>
|
|
37
|
+
<Image
|
|
38
|
+
alt=""
|
|
39
|
+
rounded
|
|
40
|
+
size="lg"
|
|
41
|
+
url="https://unsplash.it/500/400/?image=634"
|
|
42
|
+
{...props}
|
|
43
|
+
/>
|
|
44
|
+
</div>
|
|
45
|
+
<div>
|
|
46
|
+
<Image
|
|
47
|
+
alt=""
|
|
48
|
+
rounded
|
|
49
|
+
size="xl"
|
|
50
|
+
url="https://unsplash.it/500/400/?image=634"
|
|
51
|
+
{...props}
|
|
52
|
+
/>
|
|
53
|
+
</div>
|
|
43
54
|
</>
|
|
44
55
|
)
|
|
45
56
|
}
|
|
@@ -12,13 +12,7 @@ import Title from '../pb_title/_title'
|
|
|
12
12
|
type LegendProps = {
|
|
13
13
|
aria?: object,
|
|
14
14
|
className?: string,
|
|
15
|
-
color?:
|
|
16
|
-
| "data_2"
|
|
17
|
-
| "data_3"
|
|
18
|
-
| "data_4"
|
|
19
|
-
| "data_5"
|
|
20
|
-
| "data_6"
|
|
21
|
-
| "data_7",
|
|
15
|
+
color?: string,
|
|
22
16
|
dark?: boolean,
|
|
23
17
|
data?: object,
|
|
24
18
|
id?: string,
|
|
@@ -20,5 +20,9 @@
|
|
|
20
20
|
}
|
|
21
21
|
|
|
22
22
|
[class^=pb_legend_kit] {
|
|
23
|
-
@include indicator-colors($data_colors)
|
|
24
|
-
|
|
23
|
+
@include indicator-colors($data_colors);
|
|
24
|
+
@include indicator-colors($status_colors);
|
|
25
|
+
@include indicator-colors($product_colors);
|
|
26
|
+
@include indicator-colors($category_colors)
|
|
27
|
+
|
|
28
|
+
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
<%= pb_rails("legend", props: { color: "data_8", text: "Windows" }) %>
|
|
2
|
+
<%= pb_rails("legend", props: { color: "warning", text: "Windows" }) %>
|
|
3
|
+
<%= pb_rails("legend", props: { color: "windows", text: "Windows" }) %>
|
|
4
|
+
<%= pb_rails("legend", props: { color: "category_7", text: "Windows" }) %>
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import { Legend } from '../..'
|
|
3
|
+
|
|
4
|
+
const LegendColors = (props) => (
|
|
5
|
+
<div>
|
|
6
|
+
<Legend
|
|
7
|
+
color="data_8"
|
|
8
|
+
text="Windows"
|
|
9
|
+
{...props}
|
|
10
|
+
/>
|
|
11
|
+
<Legend
|
|
12
|
+
color="warning"
|
|
13
|
+
text="Windows"
|
|
14
|
+
{...props}
|
|
15
|
+
/>
|
|
16
|
+
<Legend
|
|
17
|
+
color="windows"
|
|
18
|
+
text="Windows"
|
|
19
|
+
{...props}
|
|
20
|
+
/>
|
|
21
|
+
<Legend
|
|
22
|
+
color="category_7"
|
|
23
|
+
text="Windows"
|
|
24
|
+
{...props}
|
|
25
|
+
/>
|
|
26
|
+
</div>
|
|
27
|
+
)
|
|
28
|
+
|
|
29
|
+
export default LegendColors
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<% labels = %W[Windows Doors Roofing Siding Solar Gutters Insulation Other] %>
|
|
2
2
|
|
|
3
|
-
<% (
|
|
4
|
-
<%= pb_rails("legend", props: { color: "data_#{n}", text: "#{labels[n]}" }) %>
|
|
3
|
+
<% (0..7).each do |n, i| %>
|
|
4
|
+
<%= pb_rails("legend", props: { color: "data_#{n + 1}", text: "#{labels[n]}" }) %>
|
|
5
5
|
<% end %>
|
|
@@ -2,7 +2,7 @@ import React from 'react'
|
|
|
2
2
|
|
|
3
3
|
import Legend from '../_legend'
|
|
4
4
|
|
|
5
|
-
const products = ['Windows', 'Doors', 'Roofing', 'Siding', 'Solar Gutters', 'Insulation', 'Other']
|
|
5
|
+
const products = ['Windows', 'Doors', 'Roofing', 'Siding', 'Solar', 'Gutters', 'Insulation', 'Other']
|
|
6
6
|
|
|
7
7
|
const LegendDefault = (props) => (
|
|
8
8
|
<div>
|
|
@@ -3,8 +3,7 @@
|
|
|
3
3
|
module Playbook
|
|
4
4
|
module PbLegend
|
|
5
5
|
class Legend < Playbook::KitBase
|
|
6
|
-
prop :color, type: Playbook::Props::
|
|
7
|
-
values: (1..7).map { |n| "data_#{n}" },
|
|
6
|
+
prop :color, type: Playbook::Props::String,
|
|
8
7
|
default: "data_1"
|
|
9
8
|
prop :prefix_text
|
|
10
9
|
prop :text, required: true
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import { render, screen } from '../utilities/test-utils'
|
|
3
|
+
|
|
4
|
+
import Legend from './_legend'
|
|
5
|
+
|
|
6
|
+
test('returns namespaced class name', () => {
|
|
7
|
+
render(
|
|
8
|
+
<Legend
|
|
9
|
+
data={{ testid: 'primary-test' }}
|
|
10
|
+
text="Test colors"
|
|
11
|
+
/>
|
|
12
|
+
)
|
|
13
|
+
|
|
14
|
+
const kit = screen.getByTestId('primary-test')
|
|
15
|
+
expect(kit).toHaveClass('pb_legend_kit_data_1')
|
|
16
|
+
})
|
|
17
|
+
|
|
18
|
+
test('color prop', () => {
|
|
19
|
+
render(
|
|
20
|
+
<Legend
|
|
21
|
+
color="category_17"
|
|
22
|
+
data={{ testid: 'primary-test' }}
|
|
23
|
+
text="Test colors"
|
|
24
|
+
/>
|
|
25
|
+
)
|
|
26
|
+
|
|
27
|
+
const kit = screen.getByTestId('primary-test')
|
|
28
|
+
expect(kit).toHaveClass('pb_legend_kit_category_17')
|
|
29
|
+
})
|
|
@@ -150,14 +150,16 @@ export default class PbReactPopover extends React.Component<PbPopoverProps> {
|
|
|
150
150
|
const targetIsReference =
|
|
151
151
|
target.closest('.pb_popover_reference_wrapper') !== null
|
|
152
152
|
|
|
153
|
+
if (targetIsReference) return
|
|
154
|
+
|
|
153
155
|
switch (closeOnClick) {
|
|
154
156
|
case 'outside':
|
|
155
|
-
if (!targetIsPopover
|
|
157
|
+
if (!targetIsPopover) {
|
|
156
158
|
shouldClosePopover(true)
|
|
157
159
|
}
|
|
158
160
|
break
|
|
159
161
|
case 'inside':
|
|
160
|
-
if (targetIsPopover
|
|
162
|
+
if (targetIsPopover) {
|
|
161
163
|
shouldClosePopover(true)
|
|
162
164
|
}
|
|
163
165
|
break
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
<%= pb_rails("flex", props: {classname: "flex-container", spacing: "between"}) do %>
|
|
2
2
|
<span>
|
|
3
|
-
<%= pb_rails("button", props: { text: "Click Inside", variant: "secondary", id:
|
|
3
|
+
<%= pb_rails("button", props: { text: "Click Inside", variant: "secondary", id: 'inside-popover-1' }) %>
|
|
4
4
|
<%= pb_rails("popover", props: {
|
|
5
5
|
close_on_click: "inside",
|
|
6
6
|
trigger_element_id: "inside-popover-1",
|
|
7
7
|
tooltip_id: "inside-tooltip-1",
|
|
8
|
-
position:
|
|
8
|
+
position: 'bottom',
|
|
9
9
|
offset: true
|
|
10
10
|
}) do %>
|
|
11
11
|
Click on me!
|
|
12
12
|
<% end %>
|
|
13
13
|
</span>
|
|
14
14
|
<span>
|
|
15
|
-
<%= pb_rails("button", props: { text: "Click Outside", variant: "secondary", id:
|
|
15
|
+
<%= pb_rails("button", props: { text: "Click Outside", variant: "secondary", id: 'outside-popover-1' }) %>
|
|
16
16
|
<%= pb_rails("popover", props: {
|
|
17
17
|
close_on_click: "outside",
|
|
18
18
|
trigger_element_id: "outside-popover-1",
|
|
19
19
|
tooltip_id: "outside-tooltip-1",
|
|
20
|
-
position:
|
|
20
|
+
position: 'left',
|
|
21
21
|
offset: true
|
|
22
22
|
}) do %>
|
|
23
23
|
Click anywhere but me!
|
|
@@ -27,16 +27,16 @@
|
|
|
27
27
|
<%= pb_rails("button", props: {
|
|
28
28
|
text: "Click Anywhere",
|
|
29
29
|
variant: "secondary",
|
|
30
|
-
id:
|
|
30
|
+
id: 'any-popover-1'
|
|
31
31
|
}) %>
|
|
32
32
|
<%= pb_rails("popover", props: {
|
|
33
33
|
close_on_click: "any",
|
|
34
34
|
trigger_element_id: "any-popover-1",
|
|
35
35
|
tooltip_id: "any-tooltip-1",
|
|
36
|
-
position:
|
|
36
|
+
position: 'top',
|
|
37
37
|
offset: true
|
|
38
38
|
}) do %>
|
|
39
39
|
Click anything!
|
|
40
40
|
<% end %>
|
|
41
41
|
</span>
|
|
42
|
-
<% end %>
|
|
42
|
+
<% end %>
|
|
@@ -36,14 +36,15 @@ export default class PbPopover extends PbEnhancedElement {
|
|
|
36
36
|
}
|
|
37
37
|
|
|
38
38
|
setTimeout(() => {
|
|
39
|
-
this.toggleTooltip()
|
|
40
39
|
this.popper.update()
|
|
40
|
+
this.toggleTooltip()
|
|
41
41
|
}, 0)
|
|
42
42
|
})
|
|
43
43
|
}
|
|
44
44
|
|
|
45
45
|
checkCloseTooltip() {
|
|
46
46
|
document.querySelector('body').addEventListener('click', ({ target }) => {
|
|
47
|
+
const isTriggerElement = target.closest(`#${this.triggerElementId}`) !== null
|
|
47
48
|
const isTooltipElement = target.closest(`#${this.tooltipId}`) !== null
|
|
48
49
|
|
|
49
50
|
switch (this.closeOnClick) {
|
|
@@ -51,17 +52,21 @@ export default class PbPopover extends PbEnhancedElement {
|
|
|
51
52
|
this.hideTooltip()
|
|
52
53
|
break
|
|
53
54
|
case 'outside':
|
|
54
|
-
if (
|
|
55
|
+
if (isTooltipElement) {
|
|
56
|
+
this.checkCloseTooltip()
|
|
57
|
+
} else {
|
|
55
58
|
this.hideTooltip()
|
|
56
59
|
}
|
|
57
60
|
break
|
|
58
61
|
case 'inside':
|
|
59
|
-
if (isTooltipElement) {
|
|
62
|
+
if (isTooltipElement || isTriggerElement) {
|
|
60
63
|
this.hideTooltip()
|
|
64
|
+
} else {
|
|
65
|
+
this.checkCloseTooltip()
|
|
61
66
|
}
|
|
62
67
|
break
|
|
63
68
|
}
|
|
64
|
-
}, { once: true
|
|
69
|
+
}, { once: true })
|
|
65
70
|
}
|
|
66
71
|
|
|
67
72
|
hideTooltip() {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
class: object.classname,
|
|
4
4
|
data: object.data,
|
|
5
5
|
id: object.id) do %>
|
|
6
|
-
<div class="pb_popover_tooltip
|
|
6
|
+
<div class="pb_popover_tooltip" id="<%= object.tooltip_id %>" role="tooltip" style="<%= object.z_index_helper %>">
|
|
7
7
|
<div class="pb_popover_body <%= object.width_height_class_helper %> <%= object.popover_spacing_helper %>" style="<%= object.width_height_helper %>">
|
|
8
8
|
<%= content.presence %>
|
|
9
9
|
</div>
|
|
@@ -36,13 +36,15 @@ $section_colors_dark: (
|
|
|
36
36
|
justify-content: center;
|
|
37
37
|
}
|
|
38
38
|
&[class*=_vertical] {
|
|
39
|
+
margin-left: $space_xs;
|
|
40
|
+
margin-right: $space_xs;
|
|
39
41
|
&::after {
|
|
40
42
|
@include section_separator_vertical(false);
|
|
41
43
|
}
|
|
42
44
|
}
|
|
43
|
-
|
|
45
|
+
|
|
44
46
|
// Dark =========================
|
|
45
|
-
|
|
47
|
+
|
|
46
48
|
&.dark {
|
|
47
49
|
&::after {
|
|
48
50
|
@include section_separator_horizontal(true);
|
|
@@ -59,6 +61,8 @@ $section_colors_dark: (
|
|
|
59
61
|
}
|
|
60
62
|
}
|
|
61
63
|
&[class*=_vertical] {
|
|
64
|
+
margin-left: $space_xs;
|
|
65
|
+
margin-right: $space_xs;
|
|
62
66
|
&::after {
|
|
63
67
|
@include section_separator_vertical(true);
|
|
64
68
|
}
|
|
@@ -92,13 +92,13 @@
|
|
|
92
92
|
.add-on {
|
|
93
93
|
&-right {
|
|
94
94
|
.add-on-card {
|
|
95
|
-
border: 1px solid
|
|
95
|
+
border: 1px solid $error;
|
|
96
96
|
border-left: 0;
|
|
97
97
|
}
|
|
98
98
|
}
|
|
99
99
|
&-left {
|
|
100
100
|
.add-on-card {
|
|
101
|
-
border: 1px solid
|
|
101
|
+
border: 1px solid $error;
|
|
102
102
|
border-right: 0;
|
|
103
103
|
}
|
|
104
104
|
}
|
|
@@ -169,7 +169,7 @@
|
|
|
169
169
|
&-card {
|
|
170
170
|
height: 45px;
|
|
171
171
|
margin: 0;
|
|
172
|
-
padding: 0;
|
|
172
|
+
padding: 0 !important;
|
|
173
173
|
align-items: center;
|
|
174
174
|
justify-content: center;
|
|
175
175
|
width: 45px;
|
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: 10.19.0
|
|
4
|
+
version: 10.19.0
|
|
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: 2022-01-
|
|
12
|
+
date: 2022-01-31 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: actionpack
|
|
@@ -426,9 +426,6 @@ files:
|
|
|
426
426
|
- app/pb_kits/playbook/pb_button/docs/_button_loading.md
|
|
427
427
|
- app/pb_kits/playbook/pb_button/docs/_button_options.html.erb
|
|
428
428
|
- app/pb_kits/playbook/pb_button/docs/_button_options.jsx
|
|
429
|
-
- app/pb_kits/playbook/pb_button/docs/_button_size.html.erb
|
|
430
|
-
- app/pb_kits/playbook/pb_button/docs/_button_size.jsx
|
|
431
|
-
- app/pb_kits/playbook/pb_button/docs/_button_size.md
|
|
432
429
|
- app/pb_kits/playbook/pb_button/docs/_footer.md
|
|
433
430
|
- app/pb_kits/playbook/pb_button/docs/example.yml
|
|
434
431
|
- app/pb_kits/playbook/pb_button/docs/index.js
|
|
@@ -669,6 +666,9 @@ files:
|
|
|
669
666
|
- app/pb_kits/playbook/pb_date_picker/docs/_date_picker_label.md
|
|
670
667
|
- app/pb_kits/playbook/pb_date_picker/docs/_date_picker_min_max.html.erb
|
|
671
668
|
- app/pb_kits/playbook/pb_date_picker/docs/_date_picker_min_max.jsx
|
|
669
|
+
- app/pb_kits/playbook/pb_date_picker/docs/_date_picker_month_and_year.html.erb
|
|
670
|
+
- app/pb_kits/playbook/pb_date_picker/docs/_date_picker_month_and_year.jsx
|
|
671
|
+
- app/pb_kits/playbook/pb_date_picker/docs/_date_picker_month_and_year.md
|
|
672
672
|
- app/pb_kits/playbook/pb_date_picker/docs/_date_picker_on_change.jsx
|
|
673
673
|
- app/pb_kits/playbook/pb_date_picker/docs/_date_picker_on_change.md
|
|
674
674
|
- app/pb_kits/playbook/pb_date_picker/docs/_date_picker_range.html.erb
|
|
@@ -684,6 +684,7 @@ files:
|
|
|
684
684
|
- app/pb_kits/playbook/pb_date_picker/sass_partials/_flatpickr_styles.scss
|
|
685
685
|
- app/pb_kits/playbook/pb_date_picker/sass_partials/_header_styles.scss
|
|
686
686
|
- app/pb_kits/playbook/pb_date_picker/sass_partials/_inline_styles.scss
|
|
687
|
+
- app/pb_kits/playbook/pb_date_picker/sass_partials/_month_and_year_styles.scss
|
|
687
688
|
- app/pb_kits/playbook/pb_date_picker/sass_partials/_overrides.scss
|
|
688
689
|
- app/pb_kits/playbook/pb_date_range_inline/_date_range_inline.jsx
|
|
689
690
|
- app/pb_kits/playbook/pb_date_range_inline/_date_range_inline.scss
|
|
@@ -1163,6 +1164,9 @@ files:
|
|
|
1163
1164
|
- app/pb_kits/playbook/pb_legend/_legend.scss
|
|
1164
1165
|
- app/pb_kits/playbook/pb_legend/docs/_description.md
|
|
1165
1166
|
- app/pb_kits/playbook/pb_legend/docs/_footer.md
|
|
1167
|
+
- app/pb_kits/playbook/pb_legend/docs/_legend_colors.html.erb
|
|
1168
|
+
- app/pb_kits/playbook/pb_legend/docs/_legend_colors.jsx
|
|
1169
|
+
- app/pb_kits/playbook/pb_legend/docs/_legend_colors.md
|
|
1166
1170
|
- app/pb_kits/playbook/pb_legend/docs/_legend_default.html.erb
|
|
1167
1171
|
- app/pb_kits/playbook/pb_legend/docs/_legend_default.jsx
|
|
1168
1172
|
- app/pb_kits/playbook/pb_legend/docs/_legend_prefix.html.erb
|
|
@@ -1171,6 +1175,7 @@ files:
|
|
|
1171
1175
|
- app/pb_kits/playbook/pb_legend/docs/index.js
|
|
1172
1176
|
- app/pb_kits/playbook/pb_legend/legend.html.erb
|
|
1173
1177
|
- app/pb_kits/playbook/pb_legend/legend.rb
|
|
1178
|
+
- app/pb_kits/playbook/pb_legend/legend.test.js
|
|
1174
1179
|
- app/pb_kits/playbook/pb_line_graph/_line_graph.jsx
|
|
1175
1180
|
- app/pb_kits/playbook/pb_line_graph/_line_graph.scss
|
|
1176
1181
|
- app/pb_kits/playbook/pb_line_graph/docs/_description.md
|
|
@@ -2125,9 +2130,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
2125
2130
|
version: '0'
|
|
2126
2131
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
2127
2132
|
requirements:
|
|
2128
|
-
- - "
|
|
2133
|
+
- - ">="
|
|
2129
2134
|
- !ruby/object:Gem::Version
|
|
2130
|
-
version:
|
|
2135
|
+
version: '0'
|
|
2131
2136
|
requirements: []
|
|
2132
2137
|
rubygems_version: 3.1.6
|
|
2133
2138
|
signing_key:
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
|
-
import { Button } from '../../'
|
|
3
|
-
|
|
4
|
-
const ButtonSize = (props) => (
|
|
5
|
-
<div>
|
|
6
|
-
<Button
|
|
7
|
-
size="sm"
|
|
8
|
-
text="Button sm size"
|
|
9
|
-
{...props}
|
|
10
|
-
/>
|
|
11
|
-
{' '}
|
|
12
|
-
<Button
|
|
13
|
-
size="md"
|
|
14
|
-
text="Button md size"
|
|
15
|
-
{...props}
|
|
16
|
-
/>
|
|
17
|
-
{' '}
|
|
18
|
-
<Button
|
|
19
|
-
size="lg"
|
|
20
|
-
text="Button lg size"
|
|
21
|
-
{...props}
|
|
22
|
-
/>
|
|
23
|
-
</div>
|
|
24
|
-
)
|
|
25
|
-
|
|
26
|
-
export default ButtonSize
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
By default button has the `md` size style, even if you don't explicitly pass a size prop.
|