playbook_ui 6.1.0 → 6.2.0
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_avatar/_avatar.jsx +4 -4
- data/app/pb_kits/playbook/pb_avatar_action_button/_avatar_action_button.jsx +9 -9
- data/app/pb_kits/playbook/pb_badge/_badge.jsx +4 -4
- data/app/pb_kits/playbook/pb_bar_graph/_bar_graph.jsx +16 -16
- data/app/pb_kits/playbook/pb_body/_body.jsx +7 -7
- data/app/pb_kits/playbook/pb_button/_button.jsx +15 -15
- data/app/pb_kits/playbook/pb_button_toolbar/_button_toolbar.jsx +6 -6
- data/app/pb_kits/playbook/pb_caption/_caption.jsx +4 -4
- data/app/pb_kits/playbook/pb_card/_card.jsx +15 -16
- data/app/pb_kits/playbook/pb_card/_card.scss +1 -1
- data/app/pb_kits/playbook/pb_card/_card_mixin.scss +4 -4
- data/app/pb_kits/playbook/pb_card/card_header.rb +3 -3
- data/app/pb_kits/playbook/pb_card/docs/_card_header.html.erb +38 -7
- data/app/pb_kits/playbook/pb_card/docs/_card_header.jsx +54 -6
- data/app/pb_kits/playbook/pb_card/docs/_card_header.md +1 -1
- data/app/pb_kits/playbook/pb_checkbox/_checkbox.jsx +9 -9
- data/app/pb_kits/playbook/pb_circle_icon_button/_circle_icon_button.jsx +7 -7
- data/app/pb_kits/playbook/pb_contact/_contact.jsx +5 -5
- data/app/pb_kits/playbook/pb_currency/_currency.jsx +7 -7
- data/app/pb_kits/playbook/pb_dashboard_value/_dashboard_value.jsx +7 -7
- data/app/pb_kits/playbook/pb_date/_date.jsx +2 -2
- data/app/pb_kits/playbook/pb_date_range_inline/_date_range_inline.jsx +5 -5
- data/app/pb_kits/playbook/pb_date_range_stacked/_date_range_stacked.jsx +6 -6
- data/app/pb_kits/playbook/pb_date_stacked/_date_stacked.jsx +6 -6
- data/app/pb_kits/playbook/pb_date_time_stacked/_date_time_stacked.jsx +4 -4
- data/app/pb_kits/playbook/pb_date_year_stacked/_date_year_stacked.jsx +5 -5
- data/app/pb_kits/playbook/pb_distribution_bar/_distribution_bar.jsx +4 -4
- data/app/pb_kits/playbook/pb_file_upload/_file_upload.jsx +2 -2
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/_fixed_confirmation_toast.jsx +4 -4
- data/app/pb_kits/playbook/pb_flex/_flex.jsx +6 -6
- data/app/pb_kits/playbook/pb_flex/_flex_item.jsx +4 -4
- data/app/pb_kits/playbook/pb_form_pill/_form_pill.jsx +6 -6
- data/app/pb_kits/playbook/pb_gauge/_gauge.jsx +14 -14
- data/app/pb_kits/playbook/pb_hashtag/_hashtag.jsx +6 -6
- data/app/pb_kits/playbook/pb_highlight/_highlight.jsx +5 -5
- data/app/pb_kits/playbook/pb_home_address_street/_home_address_street.jsx +11 -11
- data/app/pb_kits/playbook/pb_icon/_icon.jsx +9 -9
- data/app/pb_kits/playbook/pb_image/_image.jsx +4 -4
- data/app/pb_kits/playbook/pb_label_pill/_label_pill.jsx +4 -4
- data/app/pb_kits/playbook/pb_label_value/_label_value.jsx +10 -10
- data/app/pb_kits/playbook/pb_layout/_layout.jsx +14 -14
- data/app/pb_kits/playbook/pb_legend/_legend.jsx +5 -5
- data/app/pb_kits/playbook/pb_line_graph/_line_graph.jsx +17 -17
- data/app/pb_kits/playbook/pb_list/_list.jsx +10 -10
- data/app/pb_kits/playbook/pb_list/_list_item.jsx +4 -4
- data/app/pb_kits/playbook/pb_loading_inline/_loading_inline.jsx +4 -4
- data/app/pb_kits/playbook/pb_logistic/_logistic.jsx +7 -7
- data/app/pb_kits/playbook/pb_message/_message.jsx +8 -8
- data/app/pb_kits/playbook/pb_multiple_users/_multiple_users.jsx +5 -5
- data/app/pb_kits/playbook/pb_multiple_users_stacked/_multiple_users_stacked.jsx +3 -3
- data/app/pb_kits/playbook/pb_nav/_item.jsx +5 -5
- data/app/pb_kits/playbook/pb_nav/_nav.jsx +4 -4
- data/app/pb_kits/playbook/pb_online_status/_online_status.jsx +2 -2
- data/app/pb_kits/playbook/pb_person/_person.jsx +4 -4
- data/app/pb_kits/playbook/pb_person_contact/_person_contact.jsx +9 -9
- data/app/pb_kits/playbook/pb_pill/_pill.jsx +3 -3
- data/app/pb_kits/playbook/pb_popover/_popover.jsx +4 -4
- data/app/pb_kits/playbook/pb_progress_pills/_progress_pills.jsx +7 -7
- data/app/pb_kits/playbook/pb_progress_simple/_progress_simple.jsx +9 -9
- data/app/pb_kits/playbook/pb_progress_step/_progress_step.jsx +6 -6
- data/app/pb_kits/playbook/pb_progress_step/_progress_step.scss +178 -1
- data/app/pb_kits/playbook/pb_progress_step/_progress_step_item.jsx +1 -1
- data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_child.html.erb +11 -0
- data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_child.jsx +23 -0
- data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_default.html.erb +0 -12
- data/app/pb_kits/playbook/pb_progress_step/docs/_progress_step_default.jsx +0 -12
- data/app/pb_kits/playbook/pb_progress_step/docs/example.yml +2 -0
- data/app/pb_kits/playbook/pb_progress_step/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_progress_step/progress_step.rb +1 -1
- data/app/pb_kits/playbook/pb_radio/_radio.jsx +11 -11
- data/app/pb_kits/playbook/pb_section_separator/_section_separator.jsx +4 -4
- data/app/pb_kits/playbook/pb_selectable_card/_selectable_card.jsx +11 -11
- data/app/pb_kits/playbook/pb_selectable_card_icon/_selectable_card_icon.jsx +12 -12
- data/app/pb_kits/playbook/pb_selectable_icon/_selectable_icon.jsx +10 -10
- data/app/pb_kits/playbook/pb_source/_source.jsx +4 -4
- data/app/pb_kits/playbook/pb_star_rating/_star_rating.jsx +6 -6
- data/app/pb_kits/playbook/pb_stat_change/_stat_change.jsx +3 -3
- data/app/pb_kits/playbook/pb_stat_value/_stat_value.jsx +4 -4
- data/app/pb_kits/playbook/pb_table/_table.jsx +1 -1
- data/app/pb_kits/playbook/pb_table/_table_row.jsx +3 -3
- data/app/pb_kits/playbook/pb_text_input/_text_input.html.erb +1 -0
- data/app/pb_kits/playbook/pb_text_input/_text_input.jsx +17 -14
- data/app/pb_kits/playbook/pb_text_input/_text_input.scss +1 -1
- data/app/pb_kits/playbook/pb_text_input/docs/_text_input_disabled.html.erb +1 -0
- data/app/pb_kits/playbook/pb_text_input/docs/_text_input_disabled.jsx +18 -0
- data/app/pb_kits/playbook/pb_text_input/docs/example.yml +2 -0
- data/app/pb_kits/playbook/pb_text_input/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_text_input/text_input.rb +1 -7
- data/app/pb_kits/playbook/pb_textarea/_textarea.jsx +22 -20
- data/app/pb_kits/playbook/pb_textarea/_textarea.scss +1 -3
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_dark.jsx +0 -1
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_dark_error.jsx +0 -1
- data/app/pb_kits/playbook/pb_textarea/textarea.rb +1 -7
- data/app/pb_kits/playbook/pb_time/_time.jsx +5 -5
- data/app/pb_kits/playbook/pb_time_range_inline/_time_range_inline.jsx +8 -8
- data/app/pb_kits/playbook/pb_time_stacked/_time_stacked.jsx +5 -5
- data/app/pb_kits/playbook/pb_timeline/_item.jsx +2 -2
- data/app/pb_kits/playbook/pb_timeline/_timeline.jsx +6 -6
- data/app/pb_kits/playbook/pb_timestamp/_timestamp.jsx +3 -3
- data/app/pb_kits/playbook/pb_title/_title.jsx +4 -4
- data/app/pb_kits/playbook/pb_title_count/_title_count.jsx +3 -3
- data/app/pb_kits/playbook/pb_title_detail/docs/_title_detail_dark.html.erb +19 -0
- data/app/pb_kits/playbook/pb_title_detail/docs/_title_detail_dark.jsx +29 -0
- data/app/pb_kits/playbook/pb_toggle/_toggle.jsx +5 -5
- data/app/pb_kits/playbook/pb_typeahead/_typeahead.html.erb +2 -3
- data/app/pb_kits/playbook/pb_typeahead/_typeahead.scss +1 -1
- data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_with_context_dark.html.erb +0 -1
- data/app/pb_kits/playbook/pb_typeahead/typeahead.rb +1 -9
- data/app/pb_kits/playbook/pb_user/_user.jsx +7 -7
- data/app/pb_kits/playbook/pb_user_badge/_user_badge.jsx +2 -2
- data/app/pb_kits/playbook/pb_weekday_stacked/_weekday_stacked.jsx +5 -5
- data/lib/generators/kit/templates/kit_jsx.erb.tt +2 -2
- data/lib/playbook/version.rb +1 -1
- metadata +24 -3
@@ -13,19 +13,19 @@ import {
|
|
13
13
|
|
14
14
|
type SelectableCardIconProps = {
|
15
15
|
aria?: Object,
|
16
|
-
checked?:
|
17
|
-
checkmark:
|
18
|
-
className?:
|
19
|
-
dark?:
|
16
|
+
checked?: boolean,
|
17
|
+
checkmark: boolean,
|
18
|
+
className?: string,
|
19
|
+
dark?: boolean,
|
20
20
|
data?: Object,
|
21
|
-
disabled?:
|
22
|
-
icon?:
|
23
|
-
inputId?:
|
24
|
-
multi?:
|
25
|
-
name?:
|
26
|
-
titleText?:
|
27
|
-
bodyText?:
|
28
|
-
value?:
|
21
|
+
disabled?: boolean,
|
22
|
+
icon?: string,
|
23
|
+
inputId?: string,
|
24
|
+
multi?: boolean,
|
25
|
+
name?: string,
|
26
|
+
titleText?: string,
|
27
|
+
bodyText?: string,
|
28
|
+
value?: string,
|
29
29
|
onChange?: (e) => void,
|
30
30
|
}
|
31
31
|
|
@@ -14,17 +14,17 @@ import { globalProps } from '../utilities/globalProps.js'
|
|
14
14
|
|
15
15
|
type SelectableIconProps = {
|
16
16
|
aria?: Object,
|
17
|
-
checked?:
|
18
|
-
className?:
|
19
|
-
disabled?:
|
17
|
+
checked?: boolean,
|
18
|
+
className?: string,
|
19
|
+
disabled?: boolean,
|
20
20
|
data?: Object,
|
21
|
-
icon:
|
22
|
-
inputId:
|
23
|
-
inputs:
|
24
|
-
multi?:
|
25
|
-
name:
|
26
|
-
text:
|
27
|
-
value?:
|
21
|
+
icon: string,
|
22
|
+
inputId: string,
|
23
|
+
inputs: string,
|
24
|
+
multi?: boolean,
|
25
|
+
name: string,
|
26
|
+
text: string,
|
27
|
+
value?: string
|
28
28
|
}
|
29
29
|
|
30
30
|
const SelectableIcon = ({
|
@@ -18,11 +18,11 @@ import {
|
|
18
18
|
} from '../'
|
19
19
|
|
20
20
|
type SourceProps = {
|
21
|
-
className?:
|
21
|
+
className?: string,
|
22
22
|
data?: object,
|
23
|
-
hideIcon:
|
24
|
-
id?:
|
25
|
-
source?:
|
23
|
+
hideIcon: boolean,
|
24
|
+
id?: string,
|
25
|
+
source?: string,
|
26
26
|
type: "events" | "inbound" | "outbound" | "prospecting" | "referral" | "retail" | "user",
|
27
27
|
user: object,
|
28
28
|
}
|
@@ -14,13 +14,13 @@ import {
|
|
14
14
|
|
15
15
|
type StarRatingProps = {
|
16
16
|
aria?: object,
|
17
|
-
className?:
|
17
|
+
className?: string,
|
18
18
|
data?: object,
|
19
|
-
fixedWidth?:
|
20
|
-
hideRating:
|
21
|
-
icon?:
|
22
|
-
id?:
|
23
|
-
rating:
|
19
|
+
fixedWidth?: boolean,
|
20
|
+
hideRating: boolean,
|
21
|
+
icon?: string,
|
22
|
+
id?: string,
|
23
|
+
rating: number,
|
24
24
|
}
|
25
25
|
|
26
26
|
const StarRating = ({
|
@@ -19,9 +19,9 @@ const iconMap = {
|
|
19
19
|
|
20
20
|
type StatChangeProps = {
|
21
21
|
change?: "increase" | "decrease" | "neutral",
|
22
|
-
className?:
|
23
|
-
id?:
|
24
|
-
value?:
|
22
|
+
className?: string,
|
23
|
+
id?: string,
|
24
|
+
value?: string | number,
|
25
25
|
}
|
26
26
|
|
27
27
|
const StatChange = (props: StatChangeProps) => {
|
@@ -6,10 +6,10 @@ import { Title } from '../'
|
|
6
6
|
import { globalProps } from '../utilities/globalProps.js'
|
7
7
|
|
8
8
|
type StatValueProps = {
|
9
|
-
className?:
|
10
|
-
id?:
|
11
|
-
unit?:
|
12
|
-
value:
|
9
|
+
className?: string,
|
10
|
+
id?: string,
|
11
|
+
unit?: string,
|
12
|
+
value: string | number
|
13
13
|
}
|
14
14
|
|
15
15
|
const StatValue = (props: StatValueProps) => {
|
@@ -5,9 +5,9 @@ import { buildCss } from '../utilities/props'
|
|
5
5
|
import { globalProps } from '../utilities/globalProps.js'
|
6
6
|
|
7
7
|
type TableRowPropTypes = {
|
8
|
-
children:
|
9
|
-
className:
|
10
|
-
sideHighlightColor:
|
8
|
+
children: array<React.ReactNode> | React.ReactNode,
|
9
|
+
className: string,
|
10
|
+
sideHighlightColor: string,
|
11
11
|
}
|
12
12
|
|
13
13
|
const TableRow = (props: TableRowPropTypes) => {
|
@@ -11,31 +11,33 @@ import {
|
|
11
11
|
|
12
12
|
type TextInputProps = {
|
13
13
|
aria?: object,
|
14
|
-
className:
|
15
|
-
dark: boolean,
|
14
|
+
className: string,
|
16
15
|
data?: object,
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
16
|
+
disabled?: boolean,
|
17
|
+
error?: string,
|
18
|
+
id?: string,
|
19
|
+
name: string,
|
20
|
+
label: string,
|
21
21
|
onChange: (String) => void,
|
22
|
-
placeholder:
|
23
|
-
|
24
|
-
|
22
|
+
placeholder: string,
|
23
|
+
required?: boolean,
|
24
|
+
type: string,
|
25
|
+
value: string | number,
|
25
26
|
children: Node,
|
26
27
|
}
|
27
28
|
|
28
29
|
const TextInput = ({
|
29
30
|
aria = {},
|
30
31
|
className,
|
31
|
-
dark = false,
|
32
32
|
data = {},
|
33
|
+
disabled,
|
33
34
|
error,
|
34
35
|
id,
|
35
36
|
name,
|
36
37
|
label,
|
37
38
|
onChange = () => {},
|
38
39
|
placeholder,
|
40
|
+
required,
|
39
41
|
type = 'text',
|
40
42
|
value,
|
41
43
|
children = null,
|
@@ -44,9 +46,10 @@ const TextInput = ({
|
|
44
46
|
const ariaProps = buildAriaProps(aria)
|
45
47
|
const dataProps = buildDataProps(data)
|
46
48
|
const css = classnames([
|
47
|
-
|
49
|
+
'pb_text_input_kit',
|
48
50
|
className,
|
49
51
|
error ? 'error' : null,
|
52
|
+
globalProps(props),
|
50
53
|
])
|
51
54
|
|
52
55
|
return (
|
@@ -57,26 +60,26 @@ const TextInput = ({
|
|
57
60
|
>
|
58
61
|
<Caption
|
59
62
|
className="pb_text_input_kit_label"
|
60
|
-
dark={dark}
|
61
63
|
text={label}
|
62
64
|
/>
|
63
|
-
<div className=
|
65
|
+
<div className="text_input_wrapper">
|
64
66
|
<If condition={children}>
|
65
67
|
{children}
|
66
68
|
<Else />
|
67
69
|
<input
|
68
70
|
{...props}
|
69
71
|
className="text_input"
|
72
|
+
disabled={disabled}
|
70
73
|
id={id}
|
71
74
|
name={name}
|
72
75
|
onChange={onChange}
|
73
76
|
placeholder={placeholder}
|
77
|
+
required={required}
|
74
78
|
type={type}
|
75
79
|
value={value}
|
76
80
|
/>
|
77
81
|
<If condition={error}>
|
78
82
|
<Body
|
79
|
-
dark={dark}
|
80
83
|
status="negative"
|
81
84
|
text={error}
|
82
85
|
/>
|
@@ -0,0 +1 @@
|
|
1
|
+
<%= pb_rails("text_input", props: { label: "Last Name", placeholder: "Enter last name", disabled: true }) %>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
import React from 'react'
|
2
|
+
import { TextInput } from '../../'
|
3
|
+
|
4
|
+
class TextInputDisabled extends React.Component {
|
5
|
+
render() {
|
6
|
+
return (
|
7
|
+
<div>
|
8
|
+
<TextInput
|
9
|
+
disabled
|
10
|
+
label="Last Name"
|
11
|
+
placeholder="Enter last name"
|
12
|
+
/>
|
13
|
+
</div>
|
14
|
+
)
|
15
|
+
}
|
16
|
+
}
|
17
|
+
|
18
|
+
export default TextInputDisabled
|
@@ -5,10 +5,12 @@ examples:
|
|
5
5
|
- text_input_error: With Error
|
6
6
|
- text_input_dark_error: Dark With Error
|
7
7
|
- text_input_custom: Custom
|
8
|
+
- text_input_disabled: Disabled
|
8
9
|
react:
|
9
10
|
- text_input_default: Default
|
10
11
|
- text_input_dark: Dark
|
11
12
|
- text_input_error: With Error
|
12
13
|
- text_input_dark_error: Dark With Error
|
13
14
|
- text_input_custom: Custom
|
15
|
+
- text_input_disabled: Disabled
|
14
16
|
|
@@ -3,3 +3,4 @@ export { default as TextInputDark } from './_text_input_dark.jsx'
|
|
3
3
|
export { default as TextInputDarkError } from './_text_input_dark_error.jsx'
|
4
4
|
export { default as TextInputCustom } from './_text_input_custom.jsx'
|
5
5
|
export { default as TextInputError } from './_text_input_error.jsx'
|
6
|
+
export { default as TextInputDisabled } from './_text_input_disabled.jsx'
|
@@ -7,8 +7,6 @@ module Playbook
|
|
7
7
|
|
8
8
|
partial "pb_text_input/text_input"
|
9
9
|
|
10
|
-
prop :dark, type: Playbook::Props::Boolean,
|
11
|
-
default: false
|
12
10
|
prop :disabled, type: Playbook::Props::Boolean,
|
13
11
|
default: false
|
14
12
|
prop :error
|
@@ -23,7 +21,7 @@ module Playbook
|
|
23
21
|
prop :value
|
24
22
|
|
25
23
|
def classname
|
26
|
-
generate_classname("pb_text_input_kit"
|
24
|
+
generate_classname("pb_text_input_kit") + error_class
|
27
25
|
end
|
28
26
|
|
29
27
|
def validation_message
|
@@ -45,10 +43,6 @@ module Playbook
|
|
45
43
|
def error_class
|
46
44
|
error ? " error" : ""
|
47
45
|
end
|
48
|
-
|
49
|
-
def dark_class
|
50
|
-
dark ? "dark" : nil
|
51
|
-
end
|
52
46
|
end
|
53
47
|
end
|
54
48
|
end
|
@@ -7,19 +7,20 @@ import type { InputCallback } from '../types.js'
|
|
7
7
|
import { globalProps } from '../utilities/globalProps.js'
|
8
8
|
|
9
9
|
type TextareaProps = {
|
10
|
-
className?:
|
11
|
-
children?:
|
12
|
-
data?:
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
10
|
+
className?: string,
|
11
|
+
children?: array<React.ReactChild>,
|
12
|
+
data?: string,
|
13
|
+
disabled?: boolean,
|
14
|
+
error?: string,
|
15
|
+
id?: string,
|
16
|
+
object?: string,
|
17
|
+
method?: string,
|
18
|
+
label?: string,
|
19
|
+
placeholder?: string,
|
20
|
+
value?: string,
|
21
|
+
name?: string,
|
22
|
+
required?: boolean,
|
23
|
+
rows?: number,
|
23
24
|
resize: 'none' | 'both' | 'horizontal' | 'vertical',
|
24
25
|
onChange?: InputCallback<HTMLTextAreaElement>,
|
25
26
|
}
|
@@ -27,25 +28,25 @@ type TextareaProps = {
|
|
27
28
|
const Textarea = ({
|
28
29
|
className,
|
29
30
|
children,
|
30
|
-
|
31
|
+
disabled,
|
31
32
|
resize = 'none',
|
32
33
|
error,
|
33
34
|
label,
|
34
35
|
name,
|
35
36
|
onChange = () => {},
|
36
37
|
placeholder,
|
38
|
+
required,
|
37
39
|
rows = 4,
|
38
40
|
value,
|
39
41
|
...props
|
40
42
|
}: TextareaProps) => {
|
41
|
-
const textareaClass = `pb_textarea_kit${dark ? '_dark' : ''}`
|
42
43
|
const errorClass = error ? 'error' : null
|
43
|
-
const resizeClass = `
|
44
|
+
const resizeClass = `resize_${resize}`
|
45
|
+
const classes = classnames('pb_textarea_kit', className, errorClass, resizeClass, globalProps(props))
|
44
46
|
|
45
47
|
return (
|
46
|
-
<div className={
|
48
|
+
<div className={classes}>
|
47
49
|
<Caption
|
48
|
-
dark={dark}
|
49
50
|
text={label}
|
50
51
|
/>
|
51
52
|
<If condition={children}>
|
@@ -53,16 +54,17 @@ const Textarea = ({
|
|
53
54
|
<Else />
|
54
55
|
<textarea
|
55
56
|
{...props}
|
56
|
-
className=
|
57
|
+
className="pb_textarea_kit"
|
58
|
+
disabled={disabled}
|
57
59
|
name={name}
|
58
60
|
onChange={onChange}
|
59
61
|
placeholder={placeholder}
|
62
|
+
required={required}
|
60
63
|
rows={rows}
|
61
64
|
value={value}
|
62
65
|
/>
|
63
66
|
<If condition={error}>
|
64
67
|
<Body
|
65
|
-
dark={dark}
|
66
68
|
status="negative"
|
67
69
|
text={error}
|
68
70
|
/>
|
@@ -7,8 +7,6 @@ module Playbook
|
|
7
7
|
|
8
8
|
partial "pb_textarea/textarea"
|
9
9
|
|
10
|
-
prop :dark, type: Playbook::Props::Boolean,
|
11
|
-
default: false
|
12
10
|
prop :error
|
13
11
|
prop :object
|
14
12
|
prop :label
|
@@ -23,15 +21,11 @@ module Playbook
|
|
23
21
|
prop :value
|
24
22
|
|
25
23
|
def classname
|
26
|
-
generate_classname("pb_textarea_kit"
|
24
|
+
generate_classname("pb_textarea_kit") + error_class + resize_class
|
27
25
|
end
|
28
26
|
|
29
27
|
private
|
30
28
|
|
31
|
-
def dark_class
|
32
|
-
dark ? "dark" : nil
|
33
|
-
end
|
34
|
-
|
35
29
|
def error_class
|
36
30
|
error ? " error" : ""
|
37
31
|
end
|