playbook_ui 13.12.0.pre.alpha.play10281596 → 13.12.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.tsx +1 -5
- data/app/pb_kits/playbook/pb_avatar_action_button/_avatar_action_button.tsx +2 -6
- data/app/pb_kits/playbook/pb_background/_background.tsx +5 -9
- data/app/pb_kits/playbook/pb_badge/_badge.tsx +1 -5
- data/app/pb_kits/playbook/pb_bar_graph/_bar_graph.tsx +2 -6
- data/app/pb_kits/playbook/pb_body/_body.tsx +1 -5
- data/app/pb_kits/playbook/pb_bread_crumbs/_bread_crumb_item.tsx +1 -5
- data/app/pb_kits/playbook/pb_bread_crumbs/_bread_crumbs.tsx +2 -5
- data/app/pb_kits/playbook/pb_button/_button.tsx +1 -8
- data/app/pb_kits/playbook/pb_button_toolbar/_button_toolbar.tsx +1 -5
- data/app/pb_kits/playbook/pb_caption/_caption.tsx +1 -6
- data/app/pb_kits/playbook/pb_card/_card.tsx +1 -5
- data/app/pb_kits/playbook/pb_checkbox/_checkbox.tsx +2 -7
- data/app/pb_kits/playbook/pb_circle_chart/_circle_chart.tsx +2 -7
- data/app/pb_kits/playbook/pb_circle_icon_button/_circle_icon_button.tsx +3 -5
- data/app/pb_kits/playbook/pb_collapsible/_collapsible.tsx +1 -5
- data/app/pb_kits/playbook/pb_contact/_contact.tsx +1 -5
- data/app/pb_kits/playbook/pb_currency/_currency.tsx +1 -5
- data/app/pb_kits/playbook/pb_dashboard_value/_dashboard_value.tsx +1 -5
- data/app/pb_kits/playbook/pb_date/_date.tsx +7 -12
- data/app/pb_kits/playbook/pb_date_picker/_date_picker.tsx +1 -5
- data/app/pb_kits/playbook/pb_date_range_inline/_date_range_inline.tsx +1 -5
- data/app/pb_kits/playbook/pb_date_range_stacked/_date_range_stacked.tsx +4 -15
- data/app/pb_kits/playbook/pb_date_stacked/_date_stacked.tsx +5 -12
- data/app/pb_kits/playbook/pb_date_time/_date_time.tsx +1 -5
- data/app/pb_kits/playbook/pb_date_time_stacked/_date_time_stacked.tsx +1 -5
- data/app/pb_kits/playbook/pb_date_year_stacked/_date_year_stacked.tsx +4 -15
- data/app/pb_kits/playbook/pb_detail/_detail.tsx +1 -5
- data/app/pb_kits/playbook/pb_dialog/_dialog.tsx +3 -11
- data/app/pb_kits/playbook/pb_dialog/child_kits/_dialog_footer.tsx +3 -8
- data/app/pb_kits/playbook/pb_dialog/child_kits/_dialog_header.tsx +1 -5
- data/app/pb_kits/playbook/pb_distribution_bar/_distribution_bar.tsx +1 -8
- data/app/pb_kits/playbook/pb_file_upload/_file_upload.tsx +2 -6
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/_fixed_confirmation_toast.tsx +1 -6
- data/app/pb_kits/playbook/pb_flex/_flex.tsx +1 -6
- data/app/pb_kits/playbook/pb_flex/_flex_item.tsx +1 -6
- data/app/pb_kits/playbook/pb_form_group/_form_group.tsx +1 -5
- data/app/pb_kits/playbook/pb_form_pill/_form_pill.tsx +1 -7
- data/app/pb_kits/playbook/pb_gauge/_gauge.tsx +2 -6
- data/app/pb_kits/playbook/pb_hashtag/_hashtag.tsx +1 -5
- data/app/pb_kits/playbook/pb_highlight/_highlight.tsx +0 -5
- data/app/pb_kits/playbook/pb_home_address_street/_home_address_street.tsx +3 -10
- data/app/pb_kits/playbook/pb_icon/_icon.tsx +1 -7
- data/app/pb_kits/playbook/pb_icon_circle/_icon_circle.tsx +1 -5
- data/app/pb_kits/playbook/pb_icon_stat_value/_icon_stat_value.tsx +1 -5
- data/app/pb_kits/playbook/pb_icon_value/_icon_value.tsx +1 -5
- data/app/pb_kits/playbook/pb_image/_image.tsx +1 -6
- data/app/pb_kits/playbook/pb_label_pill/_label_pill.tsx +1 -5
- data/app/pb_kits/playbook/pb_label_value/_label_value.tsx +2 -6
- data/app/pb_kits/playbook/pb_layout/_layout.tsx +1 -6
- data/app/pb_kits/playbook/pb_legend/_legend.tsx +1 -5
- data/app/pb_kits/playbook/pb_lightbox/Header/_lightbox_header.tsx +1 -6
- data/app/pb_kits/playbook/pb_lightbox/_lightbox.tsx +1 -5
- data/app/pb_kits/playbook/pb_line_graph/_line_graph.tsx +3 -9
- data/app/pb_kits/playbook/pb_list/_list.tsx +2 -7
- data/app/pb_kits/playbook/pb_list/_list_item.tsx +1 -5
- data/app/pb_kits/playbook/pb_loading_inline/_loading_inline.tsx +1 -5
- data/app/pb_kits/playbook/pb_map/_map.tsx +1 -6
- data/app/pb_kits/playbook/pb_message/_message.tsx +1 -5
- data/app/pb_kits/playbook/pb_message/_message_mention.tsx +1 -5
- data/app/pb_kits/playbook/pb_multi_level_select/_multi_level_select.tsx +1 -5
- data/app/pb_kits/playbook/pb_multiple_users/_multiple_users.tsx +1 -5
- data/app/pb_kits/playbook/pb_multiple_users/docs/example.yml +0 -6
- data/app/pb_kits/playbook/pb_multiple_users_stacked/_multiple_users_stacked.tsx +1 -5
- data/app/pb_kits/playbook/pb_multiple_users_stacked/docs/example.yml +0 -6
- data/app/pb_kits/playbook/pb_nav/_item.tsx +2 -7
- data/app/pb_kits/playbook/pb_nav/_nav.tsx +1 -5
- data/app/pb_kits/playbook/pb_online_status/_online_status.tsx +1 -5
- data/app/pb_kits/playbook/pb_passphrase/_passphrase.tsx +2 -6
- data/app/pb_kits/playbook/pb_person/_person.tsx +0 -5
- data/app/pb_kits/playbook/pb_person_contact/_person_contact.tsx +1 -5
- data/app/pb_kits/playbook/pb_phone_number_input/_phone_number_input.tsx +2 -8
- data/app/pb_kits/playbook/pb_pill/_pill.tsx +1 -5
- data/app/pb_kits/playbook/pb_popover/_popover.tsx +1 -6
- data/app/pb_kits/playbook/pb_progress_pills/_progress_pills.tsx +1 -5
- data/app/pb_kits/playbook/pb_progress_simple/_progress_simple.tsx +3 -9
- data/app/pb_kits/playbook/pb_progress_step/_progress_step.tsx +1 -5
- data/app/pb_kits/playbook/pb_progress_step/_progress_step_item.tsx +2 -6
- data/app/pb_kits/playbook/pb_radio/_radio.tsx +1 -5
- data/app/pb_kits/playbook/pb_rich_text_editor/_rich_text_editor.tsx +1 -7
- data/app/pb_kits/playbook/pb_section_separator/_section_separator.tsx +1 -5
- data/app/pb_kits/playbook/pb_section_separator/docs/example.yml +0 -8
- data/app/pb_kits/playbook/pb_select/_select.tsx +1 -6
- data/app/pb_kits/playbook/pb_selectable_card/_selectable_card.tsx +2 -6
- data/app/pb_kits/playbook/pb_selectable_card_icon/_selectable_card_icon.tsx +0 -5
- data/app/pb_kits/playbook/pb_selectable_icon/_selectable_icon.tsx +0 -5
- data/app/pb_kits/playbook/pb_selectable_list/_item.tsx +3 -11
- data/app/pb_kits/playbook/pb_selectable_list/_selectable_list.tsx +1 -5
- data/app/pb_kits/playbook/pb_source/_source.tsx +1 -5
- data/app/pb_kits/playbook/pb_star_rating/_star_rating.tsx +1 -5
- data/app/pb_kits/playbook/pb_stat_change/_stat_change.tsx +2 -14
- data/app/pb_kits/playbook/pb_stat_value/_stat_value.tsx +0 -6
- data/app/pb_kits/playbook/pb_table/_table.tsx +1 -5
- data/app/pb_kits/playbook/pb_table/_table_row.tsx +1 -5
- data/app/pb_kits/playbook/pb_text_input/_text_input.tsx +1 -5
- data/app/pb_kits/playbook/pb_text_input/docs/example.yml +0 -7
- data/app/pb_kits/playbook/pb_textarea/_textarea.tsx +2 -5
- data/app/pb_kits/playbook/pb_textarea/docs/example.yml +0 -5
- data/app/pb_kits/playbook/pb_time/_time.tsx +2 -9
- data/app/pb_kits/playbook/pb_time_range_inline/_time_range_inline.tsx +1 -5
- data/app/pb_kits/playbook/pb_time_stacked/_time_stacked.tsx +2 -6
- data/app/pb_kits/playbook/pb_timeline/_item.tsx +2 -9
- data/app/pb_kits/playbook/pb_timeline/_timeline.tsx +1 -5
- data/app/pb_kits/playbook/pb_timestamp/_timestamp.tsx +1 -5
- data/app/pb_kits/playbook/pb_title/_title.tsx +1 -5
- data/app/pb_kits/playbook/pb_title_count/_title_count.tsx +1 -5
- data/app/pb_kits/playbook/pb_title_detail/_title_detail.tsx +3 -16
- data/app/pb_kits/playbook/pb_toggle/_toggle.tsx +0 -5
- data/app/pb_kits/playbook/pb_toggle/docs/example.yml +0 -4
- data/app/pb_kits/playbook/pb_tooltip/_tooltip.tsx +1 -5
- data/app/pb_kits/playbook/pb_treemap_chart/_treemap_chart.tsx +3 -9
- data/app/pb_kits/playbook/pb_typeahead/_typeahead.tsx +2 -7
- data/app/pb_kits/playbook/pb_user/_user.tsx +1 -5
- data/app/pb_kits/playbook/pb_user_badge/_user_badge.tsx +1 -5
- data/app/pb_kits/playbook/pb_walkthrough/_walkthrough.tsx +1 -5
- data/app/pb_kits/playbook/pb_weekday_stacked/_weekday_stacked.tsx +1 -5
- data/app/pb_kits/playbook/utilities/props.ts +0 -16
- data/dist/playbook-rails.js +5 -5
- data/lib/playbook/version.rb +2 -2
- metadata +7 -32
- data/app/pb_kits/playbook/pb_multiple_users/docs/_multiple_users_default_swift.md +0 -11
- data/app/pb_kits/playbook/pb_multiple_users/docs/_multiple_users_props_swift.md +0 -7
- data/app/pb_kits/playbook/pb_multiple_users/docs/_multiple_users_reverse_swift.md +0 -13
- data/app/pb_kits/playbook/pb_multiple_users/docs/_multiple_users_size_swift.md +0 -11
- data/app/pb_kits/playbook/pb_multiple_users_stacked/docs/_multiple_users_stacked_default_swift.md +0 -15
- data/app/pb_kits/playbook/pb_multiple_users_stacked/docs/_multiple_users_stacked_props_swift.md +0 -5
- data/app/pb_kits/playbook/pb_multiple_users_stacked/docs/_multiple_users_stacked_small_swift.md +0 -15
- data/app/pb_kits/playbook/pb_multiple_users_stacked/docs/_multiple_users_stacked_xsmall_swift.md +0 -15
- data/app/pb_kits/playbook/pb_section_separator/docs/_section_separator_children_swift.md +0 -14
- data/app/pb_kits/playbook/pb_section_separator/docs/_section_separator_dashed_swift.md +0 -7
- data/app/pb_kits/playbook/pb_section_separator/docs/_section_separator_line_swift.md +0 -8
- data/app/pb_kits/playbook/pb_section_separator/docs/_section_separator_props_swift.md +0 -8
- data/app/pb_kits/playbook/pb_section_separator/docs/_section_separator_text_swift.md +0 -7
- data/app/pb_kits/playbook/pb_section_separator/docs/_section_separator_vertical_swift.md +0 -18
- data/app/pb_kits/playbook/pb_text_input/docs/_text_input_add_on_swift.md +0 -35
- data/app/pb_kits/playbook/pb_text_input/docs/_text_input_default_swift.md +0 -29
- data/app/pb_kits/playbook/pb_text_input/docs/_text_input_disabled_swift.md +0 -13
- data/app/pb_kits/playbook/pb_text_input/docs/_text_input_error_swift.md +0 -24
- data/app/pb_kits/playbook/pb_text_input/docs/_text_input_props_swift.md +0 -13
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_default_swift.md +0 -27
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_error_swift.md +0 -11
- data/app/pb_kits/playbook/pb_textarea/docs/_textarea_props_swift.md +0 -9
- data/app/pb_kits/playbook/pb_toggle/docs/_toggle_default_swift.md +0 -11
- data/app/pb_kits/playbook/pb_toggle/docs/_toggle_name_swift.md +0 -10
- data/app/pb_kits/playbook/pb_toggle/docs/_toggle_props_swift.md +0 -6
@@ -1,7 +1,7 @@
|
|
1
1
|
import React from 'react'
|
2
2
|
import classnames from 'classnames'
|
3
3
|
|
4
|
-
import { buildAriaProps, buildCss, buildDataProps
|
4
|
+
import { buildAriaProps, buildCss, buildDataProps } from '../utilities/props'
|
5
5
|
import { globalProps, GlobalProps } from '../utilities/globalProps'
|
6
6
|
|
7
7
|
import Caption from '../pb_caption/_caption'
|
@@ -15,7 +15,6 @@ type NavProps = {
|
|
15
15
|
data?: object,
|
16
16
|
dark?: boolean,
|
17
17
|
highlight?: boolean,
|
18
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
19
18
|
id?: string,
|
20
19
|
onClick?: React.MouseEventHandler<HTMLElement>,
|
21
20
|
orientation?: "vertical" | "horizontal",
|
@@ -34,7 +33,6 @@ const Nav = (props: NavProps) => {
|
|
34
33
|
data = {},
|
35
34
|
dark = false,
|
36
35
|
highlight = true,
|
37
|
-
htmlOptions = {},
|
38
36
|
id,
|
39
37
|
link = '#',
|
40
38
|
onClick = () => { },
|
@@ -46,7 +44,6 @@ const Nav = (props: NavProps) => {
|
|
46
44
|
|
47
45
|
const ariaProps = buildAriaProps(aria)
|
48
46
|
const dataProps = buildDataProps(data)
|
49
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
50
47
|
const cardCss = classnames(
|
51
48
|
buildCss('pb_nav_list', variant, orientation, {
|
52
49
|
highlight: highlight,
|
@@ -73,7 +70,6 @@ const childrenWithProps = React.Children.map(children, (child) => {
|
|
73
70
|
<nav
|
74
71
|
{...ariaProps}
|
75
72
|
{...dataProps}
|
76
|
-
{...htmlProps}
|
77
73
|
className={cardCss}
|
78
74
|
id={id}
|
79
75
|
>
|
@@ -2,13 +2,12 @@ import React from 'react'
|
|
2
2
|
import classnames from 'classnames'
|
3
3
|
import { GlobalProps, globalProps } from '../utilities/globalProps'
|
4
4
|
|
5
|
-
import { buildAriaProps, buildCss, buildDataProps
|
5
|
+
import { buildAriaProps, buildCss, buildDataProps } from '../utilities/props'
|
6
6
|
|
7
7
|
type OnlineStatusProps = {
|
8
8
|
aria?: {[key: string]: string},
|
9
9
|
className?: string,
|
10
10
|
data?: {[key: string]: string | number},
|
11
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
12
11
|
id?: string,
|
13
12
|
status?: "online" | "offline" | "away",
|
14
13
|
} & GlobalProps
|
@@ -18,7 +17,6 @@ const OnlineStatus = (props: OnlineStatusProps) => {
|
|
18
17
|
aria = {},
|
19
18
|
className,
|
20
19
|
data = {},
|
21
|
-
htmlOptions = {},
|
22
20
|
id,
|
23
21
|
status = 'offline',
|
24
22
|
} = props
|
@@ -27,14 +25,12 @@ const OnlineStatus = (props: OnlineStatusProps) => {
|
|
27
25
|
|
28
26
|
const ariaProps = buildAriaProps(aria)
|
29
27
|
const dataProps = buildDataProps(data)
|
30
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
31
28
|
const classes = classnames(buildCss('pb_online_status_kit', status), globalProps(props), className)
|
32
29
|
|
33
30
|
return (
|
34
31
|
<div
|
35
32
|
{...ariaProps}
|
36
33
|
{...dataProps}
|
37
|
-
{...htmlProps}
|
38
34
|
className={classes}
|
39
35
|
id={id}
|
40
36
|
/>
|
@@ -3,7 +3,7 @@
|
|
3
3
|
import React, { useCallback, useMemo, useState } from "react"
|
4
4
|
import classnames from "classnames"
|
5
5
|
|
6
|
-
import { buildAriaProps, buildCss, buildDataProps
|
6
|
+
import { buildAriaProps, buildCss, buildDataProps } from "../utilities/props"
|
7
7
|
import { globalProps } from "../utilities/globalProps"
|
8
8
|
|
9
9
|
import Body from '../pb_body/_body'
|
@@ -20,7 +20,6 @@ type PassphraseProps = {
|
|
20
20
|
className?: string,
|
21
21
|
data?: object,
|
22
22
|
dark?: boolean,
|
23
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
24
23
|
id?: string,
|
25
24
|
inputProps?: {},
|
26
25
|
label?: string,
|
@@ -38,7 +37,6 @@ const Passphrase = (props: PassphraseProps) => {
|
|
38
37
|
confirmation = false,
|
39
38
|
data = {},
|
40
39
|
dark = false,
|
41
|
-
htmlOptions = {},
|
42
40
|
id,
|
43
41
|
inputProps = {},
|
44
42
|
label = confirmation ? "Confirm Passphrase" : "Passphrase",
|
@@ -84,8 +82,7 @@ const Passphrase = (props: PassphraseProps) => {
|
|
84
82
|
globalProps(props),
|
85
83
|
className
|
86
84
|
)
|
87
|
-
|
88
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
85
|
+
const dataProps = buildDataProps(data)
|
89
86
|
|
90
87
|
const popoverReference = (
|
91
88
|
<CircleIconButton
|
@@ -101,7 +98,6 @@ const Passphrase = (props: PassphraseProps) => {
|
|
101
98
|
<div
|
102
99
|
{...ariaProps}
|
103
100
|
{...dataProps}
|
104
|
-
{...htmlProps}
|
105
101
|
className={classes}
|
106
102
|
id={id}
|
107
103
|
>
|
@@ -6,7 +6,6 @@ import {
|
|
6
6
|
buildAriaProps,
|
7
7
|
buildCss,
|
8
8
|
buildDataProps,
|
9
|
-
buildHtmlProps
|
10
9
|
} from '../utilities/props'
|
11
10
|
|
12
11
|
import Body from '../pb_body/_body'
|
@@ -17,7 +16,6 @@ type PersonProps = {
|
|
17
16
|
className?: string | string[],
|
18
17
|
data?: { [key: string]: string },
|
19
18
|
firstName: string,
|
20
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
21
19
|
id?: string,
|
22
20
|
lastName: string,
|
23
21
|
}
|
@@ -27,14 +25,12 @@ const Person = (props: PersonProps): React.ReactElement => {
|
|
27
25
|
aria = {},
|
28
26
|
className,
|
29
27
|
data = {},
|
30
|
-
htmlOptions = {},
|
31
28
|
firstName,
|
32
29
|
id,
|
33
30
|
lastName } = props
|
34
31
|
|
35
32
|
const ariaProps = buildAriaProps(aria)
|
36
33
|
const dataProps = buildDataProps(data)
|
37
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
38
34
|
const classes = classnames(
|
39
35
|
buildCss('pb_person_kit'),
|
40
36
|
globalProps(props),
|
@@ -45,7 +41,6 @@ const Person = (props: PersonProps): React.ReactElement => {
|
|
45
41
|
<div
|
46
42
|
{...ariaProps}
|
47
43
|
{...dataProps}
|
48
|
-
{...htmlProps}
|
49
44
|
className={classes}
|
50
45
|
id={id}
|
51
46
|
>
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import React from 'react'
|
2
2
|
import classnames from 'classnames'
|
3
3
|
|
4
|
-
import { buildAriaProps, buildCss, buildDataProps
|
4
|
+
import { buildAriaProps, buildCss, buildDataProps } from '../utilities/props'
|
5
5
|
import { globalProps } from '../utilities/globalProps'
|
6
6
|
|
7
7
|
import Caption from '../pb_caption/_caption'
|
@@ -19,7 +19,6 @@ type PersonContactProps = {
|
|
19
19
|
className?: string | string[],
|
20
20
|
data?: object,
|
21
21
|
firstName: string,
|
22
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
23
22
|
id?: string,
|
24
23
|
lastName: string,
|
25
24
|
contacts?: ContactItem[],
|
@@ -32,14 +31,12 @@ const PersonContact = (props: PersonContactProps) => {
|
|
32
31
|
contacts = [],
|
33
32
|
data = {},
|
34
33
|
firstName,
|
35
|
-
htmlOptions = {},
|
36
34
|
id,
|
37
35
|
lastName,
|
38
36
|
} = props
|
39
37
|
|
40
38
|
const ariaProps = buildAriaProps(aria)
|
41
39
|
const dataProps = buildDataProps(data)
|
42
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
43
40
|
const classes = classnames(
|
44
41
|
buildCss('pb_person_contact_kit'),
|
45
42
|
globalProps(props),
|
@@ -62,7 +59,6 @@ const PersonContact = (props: PersonContactProps) => {
|
|
62
59
|
<div
|
63
60
|
{...ariaProps}
|
64
61
|
{...dataProps}
|
65
|
-
{...htmlProps}
|
66
62
|
className={classes}
|
67
63
|
id={id}
|
68
64
|
>
|
@@ -5,7 +5,7 @@ import intlTelInput from 'intl-tel-input'
|
|
5
5
|
import 'intl-tel-input/build/css/intlTelInput.css'
|
6
6
|
import 'intl-tel-input/build/js/utils.js'
|
7
7
|
|
8
|
-
import { buildAriaProps, buildCss, buildDataProps
|
8
|
+
import { buildAriaProps, buildCss, buildDataProps } from '../utilities/props'
|
9
9
|
import { globalProps } from '../utilities/globalProps'
|
10
10
|
|
11
11
|
import TextInput from '../pb_text_input/_text_input'
|
@@ -25,7 +25,6 @@ type PhoneNumberInputProps = {
|
|
25
25
|
data?: { [key: string]: string },
|
26
26
|
disabled?: boolean,
|
27
27
|
error?: string,
|
28
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
29
28
|
id?: string,
|
30
29
|
initialCountry?: string,
|
31
30
|
isValid?: (valid: boolean) => void,
|
@@ -72,7 +71,6 @@ const PhoneNumberInput = (props: PhoneNumberInputProps, ref?: React.MutableRefOb
|
|
72
71
|
dark = false,
|
73
72
|
data = {},
|
74
73
|
disabled = false,
|
75
|
-
htmlOptions = {},
|
76
74
|
id = "",
|
77
75
|
initialCountry = "",
|
78
76
|
isValid = () => {
|
@@ -92,7 +90,6 @@ const PhoneNumberInput = (props: PhoneNumberInputProps, ref?: React.MutableRefOb
|
|
92
90
|
|
93
91
|
const ariaProps = buildAriaProps(aria)
|
94
92
|
const dataProps = buildDataProps(data)
|
95
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
96
93
|
const classes = classnames(
|
97
94
|
buildCss("pb_phone_number_input"),
|
98
95
|
globalProps(props),
|
@@ -259,10 +256,7 @@ const PhoneNumberInput = (props: PhoneNumberInputProps, ref?: React.MutableRefOb
|
|
259
256
|
if (required) textInputProps.required = true
|
260
257
|
|
261
258
|
return (
|
262
|
-
<div
|
263
|
-
{...wrapperProps}
|
264
|
-
{...htmlProps}
|
265
|
-
>
|
259
|
+
<div {...wrapperProps}>
|
266
260
|
<TextInput
|
267
261
|
ref={
|
268
262
|
inputNode => {
|
@@ -2,14 +2,13 @@ import React from 'react'
|
|
2
2
|
|
3
3
|
import classnames from 'classnames'
|
4
4
|
import Title from '../pb_title/_title'
|
5
|
-
import { buildAriaProps, buildCss, buildDataProps
|
5
|
+
import { buildAriaProps, buildCss, buildDataProps } from '../utilities/props'
|
6
6
|
import { GlobalProps, globalProps } from '../utilities/globalProps'
|
7
7
|
|
8
8
|
type PillProps = {
|
9
9
|
aria?: {[key: string]: string},
|
10
10
|
className?: string,
|
11
11
|
data?: {[key: string]: string},
|
12
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
13
12
|
id?: string,
|
14
13
|
text: string,
|
15
14
|
variant?: "success" | "warning" | "error" | "info" | "neutral" | "primary",
|
@@ -21,7 +20,6 @@ const Pill = (props: PillProps) => {
|
|
21
20
|
aria = {},
|
22
21
|
className,
|
23
22
|
data = {},
|
24
|
-
htmlOptions = {},
|
25
23
|
id,
|
26
24
|
text,
|
27
25
|
variant = 'neutral',
|
@@ -30,14 +28,12 @@ const Pill = (props: PillProps) => {
|
|
30
28
|
|
31
29
|
const ariaProps = buildAriaProps(aria)
|
32
30
|
const dataProps = buildDataProps(data)
|
33
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
34
31
|
const classes = classnames(buildCss('pb_pill_kit', variant, textTransform), globalProps(props), className)
|
35
32
|
|
36
33
|
return (
|
37
34
|
<div
|
38
35
|
{...ariaProps}
|
39
36
|
{...dataProps}
|
40
|
-
{...htmlProps}
|
41
37
|
className={classes}
|
42
38
|
id={id}
|
43
39
|
>
|
@@ -12,7 +12,6 @@ import {
|
|
12
12
|
buildAriaProps,
|
13
13
|
buildCss,
|
14
14
|
buildDataProps,
|
15
|
-
buildHtmlProps,
|
16
15
|
noop,
|
17
16
|
} from "../utilities/props";
|
18
17
|
|
@@ -25,7 +24,6 @@ type PbPopoverProps = {
|
|
25
24
|
className?: string;
|
26
25
|
closeOnClick?: "outside" | "inside" | "any";
|
27
26
|
data?: { [key: string]: string },
|
28
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
29
27
|
id?: string;
|
30
28
|
offset?: boolean;
|
31
29
|
reference: PopperReference & any;
|
@@ -65,7 +63,6 @@ const Popover = (props: PbPopoverProps) => {
|
|
65
63
|
className,
|
66
64
|
children,
|
67
65
|
data = {},
|
68
|
-
htmlOptions = {},
|
69
66
|
id,
|
70
67
|
modifiers,
|
71
68
|
offset,
|
@@ -95,8 +92,7 @@ const Popover = (props: PbPopoverProps) => {
|
|
95
92
|
);
|
96
93
|
};
|
97
94
|
const ariaProps = buildAriaProps(aria);
|
98
|
-
const dataProps = buildDataProps(data)
|
99
|
-
const htmlProps = buildHtmlProps(htmlOptions);
|
95
|
+
const dataProps = buildDataProps(data);
|
100
96
|
const classes = classnames(
|
101
97
|
buildCss("pb_popover_kit"),
|
102
98
|
globalProps(props),
|
@@ -114,7 +110,6 @@ const Popover = (props: PbPopoverProps) => {
|
|
114
110
|
<div
|
115
111
|
{...ariaProps}
|
116
112
|
{...dataProps}
|
117
|
-
{...htmlProps}
|
118
113
|
className={classes}
|
119
114
|
data-placement={placement}
|
120
115
|
id={id}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import React from 'react'
|
2
2
|
import classnames from 'classnames'
|
3
3
|
|
4
|
-
import { buildAriaProps, buildCss, buildDataProps
|
4
|
+
import { buildAriaProps, buildCss, buildDataProps } from '../utilities/props'
|
5
5
|
import { globalProps } from '../utilities/globalProps'
|
6
6
|
|
7
7
|
import Body from '../pb_body/_body'
|
@@ -13,7 +13,6 @@ type ProgressPillsProps = {
|
|
13
13
|
className?: string,
|
14
14
|
data?: { [key: string]: string },
|
15
15
|
dark?: boolean,
|
16
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
17
16
|
id?: string,
|
18
17
|
steps?: number,
|
19
18
|
title?: string,
|
@@ -44,7 +43,6 @@ const ProgressPills = (props: ProgressPillsProps) => {
|
|
44
43
|
aria = { hidden: 'true' },
|
45
44
|
className,
|
46
45
|
data = {},
|
47
|
-
htmlOptions = {},
|
48
46
|
id,
|
49
47
|
steps = 3,
|
50
48
|
title,
|
@@ -54,14 +52,12 @@ const ProgressPills = (props: ProgressPillsProps) => {
|
|
54
52
|
|
55
53
|
const ariaProps = buildAriaProps(aria)
|
56
54
|
const dataProps = buildDataProps(data)
|
57
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
58
55
|
const classes = classnames(buildCss('pb_progress_pills_kit'), globalProps(props), className)
|
59
56
|
|
60
57
|
return (
|
61
58
|
<div
|
62
59
|
{...ariaProps}
|
63
60
|
{...dataProps}
|
64
|
-
{...htmlProps}
|
65
61
|
className={classes}
|
66
62
|
id={id}
|
67
63
|
>
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import React from 'react'
|
2
2
|
import classnames from 'classnames'
|
3
|
-
import { buildCss, buildDataProps
|
3
|
+
import { buildCss, buildDataProps } from '../utilities/props'
|
4
4
|
import { globalProps } from '../utilities/globalProps'
|
5
5
|
|
6
6
|
type ProgressSimpleProps = {
|
@@ -8,7 +8,6 @@ type ProgressSimpleProps = {
|
|
8
8
|
className?: string | string[],
|
9
9
|
dark?: boolean,
|
10
10
|
data?: string,
|
11
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
12
11
|
id?: string,
|
13
12
|
max?: number,
|
14
13
|
muted: boolean,
|
@@ -24,7 +23,6 @@ const ProgressSimple = (props: ProgressSimpleProps) => {
|
|
24
23
|
className,
|
25
24
|
dark = false,
|
26
25
|
data ={},
|
27
|
-
htmlOptions = {},
|
28
26
|
max,
|
29
27
|
muted = false,
|
30
28
|
percent = '',
|
@@ -37,7 +35,6 @@ const ProgressSimple = (props: ProgressSimpleProps) => {
|
|
37
35
|
}
|
38
36
|
|
39
37
|
const dataProps = buildDataProps(data)
|
40
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
41
38
|
const variantStyle = variant == 'default' ? '' : variant
|
42
39
|
|
43
40
|
const valueStyles = {
|
@@ -56,11 +53,8 @@ const ProgressSimple = (props: ProgressSimpleProps) => {
|
|
56
53
|
)
|
57
54
|
|
58
55
|
return (
|
59
|
-
<div
|
60
|
-
{
|
61
|
-
{...htmlProps}
|
62
|
-
className={wrapperClass}
|
63
|
-
>
|
56
|
+
<div {...dataProps}
|
57
|
+
className={wrapperClass}>
|
64
58
|
<div
|
65
59
|
className={kitClass}
|
66
60
|
data-value={value}
|
@@ -1,13 +1,12 @@
|
|
1
1
|
import React from 'react'
|
2
2
|
import classnames from 'classnames'
|
3
|
-
import { buildAriaProps, buildCss, buildDataProps
|
3
|
+
import { buildAriaProps, buildCss, buildDataProps } from '../utilities/props'
|
4
4
|
import { globalProps } from '../utilities/globalProps'
|
5
5
|
|
6
6
|
type ProgressStepProps = {
|
7
7
|
aria?: { [key: string]: string },
|
8
8
|
className?: string,
|
9
9
|
data?: { [key: string]: string },
|
10
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
11
10
|
id?: string,
|
12
11
|
children?: React.ReactChild[] | React.ReactChild,
|
13
12
|
orientation?: "horizontal" | "vertical",
|
@@ -25,7 +24,6 @@ const ProgressStep = (props: ProgressStepProps): React.ReactElement => {
|
|
25
24
|
color,
|
26
25
|
data = {},
|
27
26
|
orientation = 'horizontal',
|
28
|
-
htmlOptions = {},
|
29
27
|
icon = false,
|
30
28
|
showIcon = false,
|
31
29
|
variant,
|
@@ -33,7 +31,6 @@ const ProgressStep = (props: ProgressStepProps): React.ReactElement => {
|
|
33
31
|
|
34
32
|
const ariaProps = buildAriaProps(aria)
|
35
33
|
const dataProps = buildDataProps(data)
|
36
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
37
34
|
const iconStyle = icon === true || showIcon === true ? 'icon' : ''
|
38
35
|
const progressStepCss = buildCss(
|
39
36
|
'pb_progress_step_kit',
|
@@ -47,7 +44,6 @@ const ProgressStep = (props: ProgressStepProps): React.ReactElement => {
|
|
47
44
|
<ul
|
48
45
|
{...ariaProps}
|
49
46
|
{...dataProps}
|
50
|
-
{...htmlProps}
|
51
47
|
className={classnames(progressStepCss, globalProps(props), className)}
|
52
48
|
>
|
53
49
|
{children}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import React from 'react'
|
2
2
|
import classnames from 'classnames'
|
3
3
|
|
4
|
-
import { buildCss, buildDataProps
|
4
|
+
import { buildCss, buildDataProps } from '../utilities/props'
|
5
5
|
|
6
6
|
import Icon from '../pb_icon/_icon'
|
7
7
|
|
@@ -10,7 +10,6 @@ type ProgressStepItemProps = {
|
|
10
10
|
data?: { [key: string]: string },
|
11
11
|
status?: "complete" | "active" | "inactive" | "hidden",
|
12
12
|
children?: React.ReactNode | React.ReactNode[],
|
13
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
14
13
|
icon?: string,
|
15
14
|
}
|
16
15
|
|
@@ -20,18 +19,15 @@ const ProgressStepItem = (props: ProgressStepItemProps): React.ReactElement => {
|
|
20
19
|
data = {},
|
21
20
|
status = 'inactive',
|
22
21
|
children,
|
23
|
-
htmlOptions = {},
|
24
22
|
icon = 'check',
|
25
23
|
} = props
|
26
24
|
|
27
25
|
const progressStepItem = buildCss('pb_progress_step_item', status)
|
28
|
-
|
29
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
26
|
+
const dataProps = buildDataProps(data)
|
30
27
|
|
31
28
|
return (
|
32
29
|
<li
|
33
30
|
{...dataProps}
|
34
|
-
{...htmlProps}
|
35
31
|
className={classnames(progressStepItem, className)}
|
36
32
|
>
|
37
33
|
<div className="box">
|
@@ -3,7 +3,7 @@
|
|
3
3
|
import React, { forwardRef } from 'react'
|
4
4
|
import Body from '../pb_body/_body'
|
5
5
|
import classnames from 'classnames'
|
6
|
-
import { buildAriaProps, buildCss, buildDataProps
|
6
|
+
import { buildAriaProps, buildCss, buildDataProps } from '../utilities/props'
|
7
7
|
import { globalProps, GlobalProps } from '../utilities/globalProps'
|
8
8
|
|
9
9
|
type RadioProps = {
|
@@ -15,7 +15,6 @@ type RadioProps = {
|
|
15
15
|
dark?: boolean,
|
16
16
|
data?: {[key: string]: string},
|
17
17
|
error?: boolean,
|
18
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
19
18
|
id?: string,
|
20
19
|
label: string,
|
21
20
|
name?: string,
|
@@ -32,7 +31,6 @@ const Radio = ({
|
|
32
31
|
dark = false,
|
33
32
|
data = {},
|
34
33
|
error = false,
|
35
|
-
htmlOptions = {},
|
36
34
|
id,
|
37
35
|
label,
|
38
36
|
name = 'radio_name',
|
@@ -43,7 +41,6 @@ const Radio = ({
|
|
43
41
|
}: RadioProps, ref: any) => {
|
44
42
|
const ariaProps = buildAriaProps(aria)
|
45
43
|
const dataProps = buildDataProps(data)
|
46
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
47
44
|
const classes = classnames(
|
48
45
|
buildCss('pb_radio_kit', alignment ),
|
49
46
|
dark ? 'dark': null, error ? 'error': null,
|
@@ -71,7 +68,6 @@ const Radio = ({
|
|
71
68
|
<label
|
72
69
|
{...ariaProps}
|
73
70
|
{...dataProps}
|
74
|
-
{...htmlProps}
|
75
71
|
className={classes}
|
76
72
|
htmlFor={id}
|
77
73
|
>
|
@@ -3,7 +3,7 @@ import classnames from 'classnames'
|
|
3
3
|
import inlineFocus from './inlineFocus'
|
4
4
|
import useFocus from './useFocus'
|
5
5
|
import { globalProps, GlobalProps } from '../utilities/globalProps'
|
6
|
-
import { buildAriaProps, buildDataProps, noop
|
6
|
+
import { buildAriaProps, buildDataProps, noop } from '../utilities/props'
|
7
7
|
|
8
8
|
try {
|
9
9
|
const Trix = require('trix')
|
@@ -35,7 +35,6 @@ type RichTextEditorProps = {
|
|
35
35
|
className?: string,
|
36
36
|
data?: { [key: string]: string },
|
37
37
|
focus?: boolean,
|
38
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
39
38
|
id?: string,
|
40
39
|
inline?: boolean,
|
41
40
|
extensions?: { [key: string]: string }[],
|
@@ -59,7 +58,6 @@ const RichTextEditor = (props: RichTextEditorProps) => {
|
|
59
58
|
className,
|
60
59
|
data = {},
|
61
60
|
focus = false,
|
62
|
-
htmlOptions = {},
|
63
61
|
inline = false,
|
64
62
|
extensions,
|
65
63
|
name,
|
@@ -76,12 +74,9 @@ const RichTextEditor = (props: RichTextEditorProps) => {
|
|
76
74
|
dataProps = buildDataProps(data),
|
77
75
|
[editor, setEditor] = useState<Editor>()
|
78
76
|
|
79
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
80
|
-
|
81
77
|
const handleOnEditorReady = (editorInstance: Editor) => setEditor(editorInstance),
|
82
78
|
element = editor?.element
|
83
79
|
|
84
|
-
|
85
80
|
// DOM manipulation must wait for editor to be ready
|
86
81
|
if (editor) {
|
87
82
|
const toolbarElement = element.parentElement.querySelector('trix-toolbar') as HTMLElement,
|
@@ -166,7 +161,6 @@ const RichTextEditor = (props: RichTextEditorProps) => {
|
|
166
161
|
<div
|
167
162
|
{...ariaProps}
|
168
163
|
{...dataProps}
|
169
|
-
{...htmlProps}
|
170
164
|
className={css}
|
171
165
|
>
|
172
166
|
{
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import React from 'react'
|
2
2
|
import classnames from 'classnames'
|
3
3
|
|
4
|
-
import { buildAriaProps, buildCss, buildDataProps
|
4
|
+
import { buildAriaProps, buildCss, buildDataProps } from '../utilities/props'
|
5
5
|
import { globalProps } from '../utilities/globalProps'
|
6
6
|
|
7
7
|
import Caption from '../pb_caption/_caption'
|
@@ -12,7 +12,6 @@ type SectionSeparatorProps = {
|
|
12
12
|
className?: string,
|
13
13
|
dark?: boolean,
|
14
14
|
data?: { [key: string]: string; },
|
15
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
16
15
|
id?: string,
|
17
16
|
lineStyle?: "solid" | "dashed",
|
18
17
|
orientation?: "horizontal" | "vertical",
|
@@ -26,7 +25,6 @@ const SectionSeparator = (props: SectionSeparatorProps) => {
|
|
26
25
|
children,
|
27
26
|
className,
|
28
27
|
data = {},
|
29
|
-
htmlOptions = {},
|
30
28
|
id,
|
31
29
|
lineStyle = 'solid',
|
32
30
|
orientation = 'horizontal',
|
@@ -36,7 +34,6 @@ const SectionSeparator = (props: SectionSeparatorProps) => {
|
|
36
34
|
} = props
|
37
35
|
const ariaProps = buildAriaProps(aria)
|
38
36
|
const dataProps = buildDataProps(data)
|
39
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
40
37
|
const classes = classnames(buildCss('pb_section_separator_kit', variant, orientation, lineStyle === "dashed" ? lineStyle : ""), globalProps(props), className)
|
41
38
|
|
42
39
|
return (
|
@@ -44,7 +41,6 @@ const SectionSeparator = (props: SectionSeparatorProps) => {
|
|
44
41
|
<div
|
45
42
|
{...ariaProps}
|
46
43
|
{...dataProps}
|
47
|
-
{...htmlProps}
|
48
44
|
className={classes}
|
49
45
|
id={id}
|
50
46
|
>
|
@@ -13,11 +13,3 @@ examples:
|
|
13
13
|
- section_separator_text: Text Separator
|
14
14
|
- section_separator_vertical: Vertical
|
15
15
|
- section_separator_children: Children
|
16
|
-
|
17
|
-
swift:
|
18
|
-
- section_separator_line_swift: Line Separator
|
19
|
-
- section_separator_dashed_swift: Dashed Separator
|
20
|
-
- section_separator_text_swift: Text Separator
|
21
|
-
- section_separator_vertical_swift: Vertical
|
22
|
-
- section_separator_children_swift: Children
|
23
|
-
- section_separator_props_swift: ""
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import React, { forwardRef } from 'react'
|
2
2
|
import classnames from 'classnames'
|
3
3
|
|
4
|
-
import { buildAriaProps, buildCss, buildDataProps
|
4
|
+
import { buildAriaProps, buildCss, buildDataProps } from '../utilities/props'
|
5
5
|
import { globalProps, GlobalProps, domSafeProps } from '../utilities/globalProps'
|
6
6
|
import type { InputCallback } from '../types'
|
7
7
|
|
@@ -24,7 +24,6 @@ type SelectProps = {
|
|
24
24
|
data?: { [key: string]: string },
|
25
25
|
disabled?: boolean,
|
26
26
|
error?: string,
|
27
|
-
htmlOptions?: {[key: string]: string | number | boolean | Function},
|
28
27
|
id?: string,
|
29
28
|
includeBlank?: string,
|
30
29
|
inline?: boolean,
|
@@ -59,7 +58,6 @@ const Select = ({
|
|
59
58
|
disabled = false,
|
60
59
|
error,
|
61
60
|
label,
|
62
|
-
htmlOptions = {},
|
63
61
|
inline = false,
|
64
62
|
multiple = false,
|
65
63
|
name,
|
@@ -71,7 +69,6 @@ const Select = ({
|
|
71
69
|
}: SelectProps, ref: React.LegacyRef<HTMLSelectElement>) => {
|
72
70
|
const ariaProps = buildAriaProps(aria)
|
73
71
|
const dataProps = buildDataProps(data)
|
74
|
-
const htmlProps = buildHtmlProps(htmlOptions)
|
75
72
|
const optionsList = createOptions(options)
|
76
73
|
|
77
74
|
const inlineClass = inline ? 'inline' : null
|
@@ -92,7 +89,6 @@ const Select = ({
|
|
92
89
|
if (children) return children
|
93
90
|
return (
|
94
91
|
<select
|
95
|
-
{...htmlOptions}
|
96
92
|
{...domSafeProps(props)}
|
97
93
|
disabled={disabled}
|
98
94
|
id={name}
|
@@ -113,7 +109,6 @@ const Select = ({
|
|
113
109
|
<div
|
114
110
|
{...ariaProps}
|
115
111
|
{...dataProps}
|
116
|
-
{...htmlProps}
|
117
112
|
className={classes}
|
118
113
|
>
|
119
114
|
{label &&
|