playbook_ui 14.10.0.pre.alpha.play16825301 → 14.10.0.pre.rc.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/_playbook.scss +0 -1
- data/app/pb_kits/playbook/pb_advanced_table/Components/CollapsibleTrail.tsx +6 -1
- data/app/pb_kits/playbook/pb_advanced_table/Components/TableHeaderCell.tsx +19 -32
- data/app/pb_kits/playbook/pb_advanced_table/SubKits/TableBody.tsx +1 -3
- data/app/pb_kits/playbook/pb_advanced_table/_advanced_table.scss +6 -46
- data/app/pb_kits/playbook/pb_advanced_table/_advanced_table.tsx +36 -94
- data/app/pb_kits/playbook/pb_advanced_table/advanced_table.html.erb +1 -1
- data/app/pb_kits/playbook/pb_advanced_table/advanced_table.rb +1 -8
- data/app/pb_kits/playbook/pb_advanced_table/advanced_table.test.jsx +2 -2
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_beta_sort.html.erb +3 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_beta_subrow_headers.html.erb +1 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_beta_subrow_headers.md +1 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/example.yml +0 -8
- data/app/pb_kits/playbook/pb_advanced_table/docs/index.js +0 -4
- data/app/pb_kits/playbook/pb_advanced_table/index.js +92 -185
- data/app/pb_kits/playbook/pb_advanced_table/table_body.html.erb +1 -1
- data/app/pb_kits/playbook/pb_advanced_table/table_body.rb +8 -57
- data/app/pb_kits/playbook/pb_advanced_table/table_header.html.erb +13 -18
- data/app/pb_kits/playbook/pb_advanced_table/table_header.rb +0 -78
- data/app/pb_kits/playbook/pb_advanced_table/table_row.html.erb +3 -12
- data/app/pb_kits/playbook/pb_advanced_table/table_row.rb +2 -15
- data/app/pb_kits/playbook/pb_advanced_table/table_subrow_header.html.erb +6 -10
- data/app/pb_kits/playbook/pb_advanced_table/table_subrow_header.rb +4 -8
- data/app/pb_kits/playbook/pb_avatar/_avatar.scss +2 -0
- data/app/pb_kits/playbook/pb_avatar_action_button/_avatar_action_button.scss +9 -11
- data/app/pb_kits/playbook/pb_badge/_badge.scss +2 -4
- data/app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom.jsx +49 -53
- data/app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb +36 -29
- data/app/pb_kits/playbook/pb_body/_body.scss +13 -14
- data/app/pb_kits/playbook/pb_body/_body_mixins.scss +16 -22
- data/app/pb_kits/playbook/pb_bread_crumbs/_bread_crumbs.scss +1 -3
- data/app/pb_kits/playbook/pb_bread_crumbs/docs/_bread_crumbs_default.jsx +0 -6
- data/app/pb_kits/playbook/pb_button/_button.scss +1 -3
- data/app/pb_kits/playbook/pb_caption/_caption_mixin.scss +1 -2
- data/app/pb_kits/playbook/pb_card/_card.scss +3 -21
- data/app/pb_kits/playbook/pb_card/_card.tsx +7 -7
- data/app/pb_kits/playbook/pb_card/_card_mixin.scss +2 -2
- data/app/pb_kits/playbook/pb_card/docs/_card_header.html.erb +1 -39
- data/app/pb_kits/playbook/pb_card/docs/_card_header.jsx +0 -90
- data/app/pb_kits/playbook/pb_card/docs/_card_header.md +1 -1
- data/app/pb_kits/playbook/pb_circle_icon_button/_circle_icon_button.scss +2 -4
- data/app/pb_kits/playbook/pb_circle_icon_button/_circle_icon_button.tsx +0 -3
- data/app/pb_kits/playbook/pb_circle_icon_button/circle_icon_button.html.erb +1 -1
- data/app/pb_kits/playbook/pb_circle_icon_button/circle_icon_button.rb +0 -1
- data/app/pb_kits/playbook/pb_circle_icon_button/docs/_circle_icon_button_link.html.erb +0 -8
- data/app/pb_kits/playbook/pb_circle_icon_button/docs/_circle_icon_button_link.jsx +0 -9
- data/app/pb_kits/playbook/pb_collapsible/_collapsible.tsx +4 -9
- data/app/pb_kits/playbook/pb_collapsible/child_kits/CollapsibleContent.tsx +2 -2
- data/app/pb_kits/playbook/pb_collapsible/child_kits/CollapsibleMain.tsx +2 -2
- data/app/pb_kits/playbook/pb_date_picker/sass_partials/_input_styles.scss +1 -3
- data/app/pb_kits/playbook/pb_date_picker/sass_partials/_overrides.scss +3 -5
- data/app/pb_kits/playbook/pb_date_range_inline/_date_range_inline.scss +4 -6
- data/app/pb_kits/playbook/pb_date_time_stacked/_date_time_stacked.scss +2 -4
- data/app/pb_kits/playbook/pb_drawer/_drawer.tsx +2 -2
- data/app/pb_kits/playbook/pb_dropdown/_dropdown.scss +8 -10
- data/app/pb_kits/playbook/pb_file_upload/_file_upload.scss +0 -5
- data/app/pb_kits/playbook/pb_file_upload/_file_upload.tsx +17 -31
- data/app/pb_kits/playbook/pb_file_upload/docs/_file_upload_accept.jsx +1 -3
- data/app/pb_kits/playbook/pb_file_upload/docs/_file_upload_custom_description.jsx +1 -4
- data/app/pb_kits/playbook/pb_file_upload/docs/_file_upload_max_size.jsx +1 -1
- data/app/pb_kits/playbook/pb_file_upload/file_upload.html.erb +2 -8
- data/app/pb_kits/playbook/pb_form_group/_form_group.scss +2 -11
- data/app/pb_kits/playbook/pb_form_pill/_form_pill.scss +4 -6
- data/app/pb_kits/playbook/pb_gauge/_gauge.scss +1 -31
- data/app/pb_kits/playbook/pb_gauge/_gauge.tsx +3 -3
- data/app/pb_kits/playbook/pb_gauge/docs/_gauge_complex.jsx +5 -25
- data/app/pb_kits/playbook/pb_home_address_street/_home_address_street.tsx +1 -17
- data/app/pb_kits/playbook/pb_home_address_street/docs/_home_address_street_emphasis.html.erb +1 -17
- data/app/pb_kits/playbook/pb_home_address_street/docs/_home_address_street_emphasis.jsx +0 -15
- data/app/pb_kits/playbook/pb_home_address_street/docs/_home_address_street_emphasis.md +1 -2
- data/app/pb_kits/playbook/pb_home_address_street/home_address_street.rb +1 -15
- data/app/pb_kits/playbook/pb_icon_circle/_icon_circle.scss +14 -4
- data/app/pb_kits/playbook/pb_label_value/_label_value.scss +2 -4
- data/app/pb_kits/playbook/pb_layout/_layout.tsx +11 -30
- data/app/pb_kits/playbook/pb_link/_link.scss +3 -3
- data/app/pb_kits/playbook/pb_message/_message_mixins.scss +1 -3
- data/app/pb_kits/playbook/pb_multiple_users/_multiple_users.scss +1 -3
- data/app/pb_kits/playbook/pb_nav/_bold_mixin.scss +1 -11
- data/app/pb_kits/playbook/pb_nav/_collapsible_nav.scss +2 -16
- data/app/pb_kits/playbook/pb_nav/_vertical_nav.scss +1 -1
- data/app/pb_kits/playbook/pb_pagination/_pagination.tsx +2 -2
- data/app/pb_kits/playbook/pb_passphrase/_passphrase.scss +3 -5
- data/app/pb_kits/playbook/pb_phone_number_input/_phone_number_input.scss +8 -10
- data/app/pb_kits/playbook/pb_pill/_pill.scss +2 -4
- data/app/pb_kits/playbook/pb_progress_simple/_progress_simple.scss +2 -4
- data/app/pb_kits/playbook/pb_rich_text_editor/_rich_text_editor.scss +2 -4
- data/app/pb_kits/playbook/pb_section_separator/_section_separator.scss +1 -64
- data/app/pb_kits/playbook/pb_section_separator/_section_separator.tsx +1 -3
- data/app/pb_kits/playbook/pb_section_separator/docs/example.yml +0 -2
- data/app/pb_kits/playbook/pb_section_separator/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_section_separator/section_separator.rb +1 -4
- data/app/pb_kits/playbook/pb_select/_select.scss +3 -5
- data/app/pb_kits/playbook/pb_selectable_card/_selectable_card.scss +7 -9
- data/app/pb_kits/playbook/pb_selectable_card/selectable_card.html.erb +1 -1
- data/app/pb_kits/playbook/pb_skeleton_loading/_skeleton_loading.scss +2 -2
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_default.html.erb +1 -1
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_height_width.jsx +2 -8
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/example.yml +3 -9
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/index.js +0 -2
- data/app/pb_kits/playbook/pb_skeleton_loading/skeleton_loading.html.erb +12 -8
- data/app/pb_kits/playbook/pb_skeleton_loading/skeleton_loading.rb +1 -48
- data/app/pb_kits/playbook/pb_stat_change/_stat_change.tsx +36 -44
- data/app/pb_kits/playbook/pb_stat_change/stat_change.html.erb +4 -4
- data/app/pb_kits/playbook/pb_table/_table.tsx +24 -80
- data/app/pb_kits/playbook/pb_table/docs/_table_sticky_left_columns.jsx +1 -1
- data/app/pb_kits/playbook/pb_table/docs/_table_sticky_left_columns_react.md +1 -4
- data/app/pb_kits/playbook/pb_table/docs/example.yml +0 -9
- data/app/pb_kits/playbook/pb_table/docs/index.js +0 -7
- data/app/pb_kits/playbook/pb_table/index.ts +26 -102
- data/app/pb_kits/playbook/pb_table/styles/_all.scss +1 -2
- data/app/pb_kits/playbook/pb_table/styles/_scroll.scss +2 -63
- data/app/pb_kits/playbook/pb_table/styles/_sticky_columns.scss +4 -17
- data/app/pb_kits/playbook/pb_table/subcomponents/_table_row.tsx +1 -106
- data/app/pb_kits/playbook/pb_table/table.html.erb +2 -8
- data/app/pb_kits/playbook/pb_table/table.rb +2 -21
- data/app/pb_kits/playbook/pb_text_input/_text_input.scss +1 -3
- data/app/pb_kits/playbook/pb_text_input/_text_input.tsx +4 -43
- data/app/pb_kits/playbook/pb_text_input/docs/example.yml +0 -1
- data/app/pb_kits/playbook/pb_text_input/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_text_input/text_input.test.js +2 -219
- data/app/pb_kits/playbook/pb_textarea/_textarea.scss +1 -3
- data/app/pb_kits/playbook/pb_time_range_inline/_time_range_inline.scss +4 -5
- data/app/pb_kits/playbook/pb_timeline/_timeline.scss +2 -4
- data/app/pb_kits/playbook/pb_timeline/_timeline.tsx +5 -5
- data/app/pb_kits/playbook/pb_timeline/docs/_timeline_with_gap.html.erb +5 -4
- data/app/pb_kits/playbook/pb_timeline/docs/_timeline_with_gap.jsx +4 -4
- data/app/pb_kits/playbook/pb_timeline/docs/_timeline_with_gap.md +1 -1
- data/app/pb_kits/playbook/pb_timeline/timeline.rb +6 -6
- data/app/pb_kits/playbook/pb_title/_title.scss +5 -6
- data/app/pb_kits/playbook/pb_title/_title_mixin.scss +0 -13
- data/app/pb_kits/playbook/pb_toggle/_toggle.scss +3 -5
- data/app/pb_kits/playbook/pb_typeahead/_typeahead.scss +46 -115
- data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_with_highlight.jsx +2 -9
- data/app/pb_kits/playbook/pb_typeahead/typeahead.html.erb +2 -3
- data/app/pb_kits/playbook/tokens/_titles.scss +8 -0
- data/app/pb_kits/playbook/utilities/_hover.scss +2 -11
- data/app/pb_kits/playbook/utilities/globalPropNames.mjs +0 -1
- data/app/pb_kits/playbook/utilities/globalProps.ts +9 -20
- data/app/pb_kits/playbook/utilities/test/globalProps/hover.test.js +0 -15
- data/dist/chunks/_typeahead-B8fkIeXA.js +22 -0
- data/dist/chunks/_weekday_stacked-CiL8BjKa.js +45 -0
- data/dist/chunks/{lib-B7sgJtGS.js → lib-SyD3buPZ.js} +3 -3
- data/dist/chunks/{pb_form_validation-C5Cc0-1v.js → pb_form_validation-Dt8UJgrJ.js} +1 -1
- data/dist/chunks/vendor.js +1 -1
- data/dist/menu.yml +2 -2
- data/dist/playbook-doc.js +1 -1
- data/dist/playbook-rails-react-bindings.js +1 -1
- data/dist/playbook-rails.js +1 -1
- data/dist/playbook.css +1 -1
- data/lib/playbook/classnames.rb +0 -1
- data/lib/playbook/hover.rb +1 -7
- data/lib/playbook/spacing.rb +0 -21
- data/lib/playbook/version.rb +2 -2
- metadata +8 -59
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_collapsible_trail_rails.html.erb +0 -36
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_collapsible_trail_rails.md +0 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_headers.html.erb +0 -43
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_headers.jsx +0 -60
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_headers.md +0 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_headers_multiple.html.erb +0 -58
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_headers_multiple.jsx +0 -74
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_headers_multiple.md +0 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_pagination.jsx +0 -50
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_pagination.md +0 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_pagination_with_props.jsx +0 -57
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_pagination_with_props.md +0 -5
- data/app/pb_kits/playbook/pb_advanced_table/docs/advanced_table_pagination_mock_data.json +0 -5600
- data/app/pb_kits/playbook/pb_circle_icon_button/docs/_circle_icon_button_link.md +0 -1
- data/app/pb_kits/playbook/pb_form_group/_error_state_mixin.scss +0 -57
- data/app/pb_kits/playbook/pb_home_address_street/none_emphasis.html.erb +0 -32
- data/app/pb_kits/playbook/pb_home_address_street/none_emphasis.rb +0 -29
- data/app/pb_kits/playbook/pb_section_separator/docs/_section_separator_color.html.erb +0 -10
- data/app/pb_kits/playbook/pb_section_separator/docs/_section_separator_color.jsx +0 -42
- data/app/pb_kits/playbook/pb_section_separator/docs/_section_separator_color.md +0 -3
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_description.md +0 -3
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_border_radius.html.erb +0 -9
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_border_radius_rails.md +0 -1
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_color.html.erb +0 -7
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_filter.html.erb +0 -119
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_filter.jsx +0 -174
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_height_width.html.erb +0 -15
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_height_width_rails.md +0 -3
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_layout.html.erb +0 -3
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_user.html.erb +0 -63
- data/app/pb_kits/playbook/pb_skeleton_loading/docs/_skeleton_loading_user.jsx +0 -97
- data/app/pb_kits/playbook/pb_table/docs/_table_sticky_columns.jsx +0 -88
- data/app/pb_kits/playbook/pb_table/docs/_table_sticky_columns_react.md +0 -3
- data/app/pb_kits/playbook/pb_table/docs/_table_sticky_left_columns.html.erb +0 -77
- data/app/pb_kits/playbook/pb_table/docs/_table_sticky_left_columns_rails.md +0 -3
- data/app/pb_kits/playbook/pb_table/docs/_table_sticky_right_columns.jsx +0 -87
- data/app/pb_kits/playbook/pb_table/docs/_table_sticky_right_columns_react.md +0 -5
- data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible.jsx +0 -75
- data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible.md +0 -1
- data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible_with_custom_click.jsx +0 -108
- data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible_with_custom_click.md +0 -2
- data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible_with_custom_content.jsx +0 -94
- data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible_with_custom_content.md +0 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible_with_nested_rows.jsx +0 -83
- data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible_with_nested_rows.md +0 -3
- data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible_with_nested_table.jsx +0 -120
- data/app/pb_kits/playbook/pb_table/docs/_table_with_collapsible_with_nested_table.md +0 -1
- data/app/pb_kits/playbook/pb_table/styles/_collapsible.scss +0 -35
- data/app/pb_kits/playbook/pb_text_input/docs/_text_input_mask.jsx +0 -106
- data/app/pb_kits/playbook/pb_text_input/inputMask.ts +0 -108
- data/app/pb_kits/playbook/utilities/_gap.scss +0 -29
- data/dist/chunks/_typeahead-C2iCBqxQ.js +0 -36
- data/dist/chunks/_weekday_stacked-CWnbnW7m.js +0 -45
- /data/app/pb_kits/playbook/pb_skeleton_loading/docs/{_skeleton_loading_border_radius_react.md → _skeleton_loading_border_radius.md} +0 -0
- /data/app/pb_kits/playbook/pb_skeleton_loading/docs/{_skeleton_loading_height_width_react.md → _skeleton_loading_height_width.md} +0 -0
@@ -31,12 +31,14 @@ $avatar-sizes: (
|
|
31
31
|
[class^=pb_card_kit].overlay_top_center {
|
32
32
|
left: 50%;
|
33
33
|
transform: translateX(-50%);
|
34
|
+
padding: 2px !important;
|
34
35
|
}
|
35
36
|
|
36
37
|
[class^=pb_card_kit].overlay_left_center,
|
37
38
|
[class^=pb_card_kit].overlay_right_center {
|
38
39
|
top: 50%;
|
39
40
|
transform: translateY(-50%);
|
41
|
+
padding: 2px !important;
|
40
42
|
}
|
41
43
|
}
|
42
44
|
|
@@ -1,5 +1,3 @@
|
|
1
|
-
@use "sass:math";
|
2
|
-
|
3
1
|
[class^=pb_avatar_action_button_kit] {
|
4
2
|
|
5
3
|
$icon_size: 0px;
|
@@ -15,7 +13,7 @@
|
|
15
13
|
color: $value;
|
16
14
|
}
|
17
15
|
}
|
18
|
-
|
16
|
+
|
19
17
|
@mixin icon-base {
|
20
18
|
&.dark{
|
21
19
|
background-color: $bg_dark
|
@@ -33,22 +31,22 @@
|
|
33
31
|
}
|
34
32
|
|
35
33
|
@each $name, $size in $avatar-sizes {
|
36
|
-
|
34
|
+
|
37
35
|
&[class*=_#{$name}] {
|
38
|
-
|
36
|
+
|
39
37
|
$avatar_size: map-get($avatar-sizes, $name);
|
40
|
-
$icon_size:
|
41
|
-
$border_size:
|
38
|
+
$icon_size: $avatar_size / 2;
|
39
|
+
$border_size: $icon_size / 10;
|
42
40
|
|
43
41
|
position: relative;
|
44
42
|
width: $avatar_size * 1.25;
|
45
43
|
height: $avatar_size * 1.1;
|
46
44
|
display: flex;
|
47
|
-
|
45
|
+
|
48
46
|
[class^=pb_tooltip_kit] {
|
49
47
|
justify-self: center;
|
50
48
|
}
|
51
|
-
|
49
|
+
|
52
50
|
&[class*=_bottom] .icon {
|
53
51
|
@include icon-base;
|
54
52
|
top: $icon_size * 1.27;
|
@@ -61,8 +59,8 @@
|
|
61
59
|
left: $icon_size * 1.5;
|
62
60
|
}
|
63
61
|
&[class*=_left] [class^=pb_avatar_kit] {
|
64
|
-
padding-left:
|
62
|
+
padding-left: $icon_size / 2;
|
65
63
|
}
|
66
64
|
}
|
67
65
|
}
|
68
|
-
}
|
66
|
+
}
|
@@ -1,5 +1,3 @@
|
|
1
|
-
@use "sass:math";
|
2
|
-
|
3
1
|
@import "../tokens/border_radius";
|
4
2
|
@import "../tokens/colors";
|
5
3
|
@import "../tokens/opacity";
|
@@ -13,7 +11,7 @@
|
|
13
11
|
align-items: center;
|
14
12
|
justify-content: center;
|
15
13
|
border-radius: $border_rad_light;
|
16
|
-
padding: 0
|
14
|
+
padding: 0 $space_xs/2;
|
17
15
|
border-width: 1px;
|
18
16
|
border-style: solid;
|
19
17
|
border-color: $card_light;
|
@@ -36,7 +34,7 @@
|
|
36
34
|
height: $pb_badge_height;
|
37
35
|
min-height: $pb_badge_height;
|
38
36
|
min-width: $pb_badge_height;
|
39
|
-
border-radius:
|
37
|
+
border-radius: $pb_badge_height / 2;
|
40
38
|
}
|
41
39
|
|
42
40
|
&[class*=_notification] {
|
@@ -1,70 +1,66 @@
|
|
1
1
|
import React from 'react'
|
2
|
-
import ReactDOMServer from 'react-dom/server'
|
3
|
-
import BarGraph from '../_bar_graph'
|
4
|
-
import Icon from '../../pb_icon/_icon'
|
5
2
|
|
6
|
-
|
7
|
-
{
|
8
|
-
name: 'Role',
|
9
|
-
data: [0, 200, 300, 654, 656],
|
10
|
-
},
|
11
|
-
{
|
12
|
-
name: 'Company',
|
13
|
-
data: [150, 524, 320, 440, 500],
|
14
|
-
},
|
15
|
-
]
|
3
|
+
import BarGraph from '../_bar_graph'
|
16
4
|
|
17
|
-
const
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
}
|
5
|
+
const chartData = [{
|
6
|
+
name: 'Installation',
|
7
|
+
data: [1475, 200, 3000, 654, 656],
|
8
|
+
}, {
|
9
|
+
name: 'Manufacturing',
|
10
|
+
data: [4434, 524, 2320, 440, 500],
|
11
|
+
}, {
|
12
|
+
name: 'Sales & Distribution',
|
13
|
+
data: [3387, 743, 1344, 434, 440],
|
14
|
+
}, {
|
15
|
+
name: 'Project Development',
|
16
|
+
data: [3227, 878, 999, 780, 1000],
|
17
|
+
}, {
|
18
|
+
name: 'Other',
|
19
|
+
data: [1111, 677, 3245, 500, 200],
|
20
|
+
}]
|
24
21
|
|
25
22
|
const barGraphOptions = {
|
26
|
-
|
27
|
-
|
23
|
+
subtitle: {
|
24
|
+
text: "Overwritten subtitle",
|
25
|
+
style: {
|
26
|
+
color: "red"
|
27
|
+
}
|
28
28
|
},
|
29
29
|
xAxis: {
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
}
|
49
|
-
|
50
|
-
fontSize: '1.4em',
|
51
|
-
},
|
52
|
-
y: 42,
|
53
|
-
},
|
54
|
-
},
|
55
|
-
legend: {
|
56
|
-
itemMarginTop: 62,
|
57
|
-
},
|
30
|
+
labels: {
|
31
|
+
useHTML: true,
|
32
|
+
formatter: function() {
|
33
|
+
switch (this.value) {
|
34
|
+
case 'Jan':
|
35
|
+
return `<i class="far fa-apple-whole"></i> ${this.value}`
|
36
|
+
case 'Feb':
|
37
|
+
return `<i class="far fa-strawberry"></i> ${this.value}`
|
38
|
+
case 'Mar':
|
39
|
+
return `<i class="far fa-lemon"></i> ${this.value}`
|
40
|
+
case 'Apr':
|
41
|
+
return `<i class="far fa-pear"></i> ${this.value}`
|
42
|
+
case 'May':
|
43
|
+
return `<i class="far fa-peach"></i> ${this.value}`
|
44
|
+
default:
|
45
|
+
return ''
|
46
|
+
}
|
47
|
+
}
|
48
|
+
}
|
49
|
+
}
|
58
50
|
}
|
59
51
|
|
60
|
-
const BarGraphCustom = () => (
|
52
|
+
const BarGraphCustom = (props) => (
|
61
53
|
<div>
|
62
54
|
<BarGraph
|
55
|
+
axisTitle="Number of Employees"
|
63
56
|
chartData={chartData}
|
64
57
|
customOptions={barGraphOptions}
|
65
|
-
id="
|
66
|
-
|
58
|
+
id="bar-custom"
|
59
|
+
subTitle="Subtitle to replace"
|
67
60
|
title="Bar Graph with Custom Overrides"
|
61
|
+
xAxisCategories={['Jan', 'Feb', 'Mar', 'Apr', 'May']}
|
62
|
+
yAxisMin={0}
|
63
|
+
{...props}
|
68
64
|
/>
|
69
65
|
</div>
|
70
66
|
)
|
@@ -1,42 +1,49 @@
|
|
1
1
|
<% data = [{
|
2
|
-
|
3
|
-
|
2
|
+
name: 'Installation',
|
3
|
+
data: [1475,200,3000,654,656]
|
4
4
|
}, {
|
5
|
-
|
6
|
-
|
5
|
+
name: 'Manufacturing',
|
6
|
+
data: [4434,524,2320,440,500]
|
7
|
+
}, {
|
8
|
+
name: 'Sales & Distribution',
|
9
|
+
data: [3387,743,1344,434,440,]
|
10
|
+
}, {
|
11
|
+
name: 'Project Development',
|
12
|
+
data: [3227,878,999,780,1000]
|
13
|
+
}, {
|
14
|
+
name: 'Other',
|
15
|
+
data: [1111,677,3245,500,200]
|
7
16
|
}] %>
|
8
17
|
|
9
18
|
<% bar_graph_options = {
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
raw(pb_rails("icon", props: { icon: "frown", color: "error", size: "2x" })),
|
17
|
-
raw(pb_rails("icon", props: { icon: "frown", color: "warning", size: "2x" })),
|
18
|
-
raw(pb_rails("icon", props: { icon: "frown-open", color: "neutral", size: "2x" })),
|
19
|
-
raw(pb_rails("icon", props: { icon: "smile", color: "category_7", size: "2x" })),
|
20
|
-
raw(pb_rails("icon", props: { icon: "smile-beam", color: "success", size: "2x" }))
|
21
|
-
],
|
22
|
-
labels: {
|
23
|
-
useHTML: true,
|
24
|
-
sytle: {
|
25
|
-
fontSize: '1.4em',
|
19
|
+
customOptions: {
|
20
|
+
subtitle: {
|
21
|
+
text: "Overwritten subtitle",
|
22
|
+
style: {
|
23
|
+
color: "red"
|
24
|
+
}
|
26
25
|
},
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
26
|
+
xAxis: {
|
27
|
+
categories: [
|
28
|
+
'<i class="far fa-apple-whole"></i> Jan',
|
29
|
+
'<i class="far fa-strawberry"></i> Feb',
|
30
|
+
'<i class="far fa-lemon"></i> Mar',
|
31
|
+
'<i class="far fa-pear"></i> Apr',
|
32
|
+
'<i class="far fa-peach"></i> May'
|
33
|
+
],
|
34
|
+
labels: {
|
35
|
+
useHTML: true,
|
36
|
+
}
|
37
|
+
}
|
38
|
+
}
|
34
39
|
} %>
|
35
40
|
|
36
41
|
<%= pb_rails("bar_graph", props: {
|
42
|
+
axis_title: 'Number of Employees',
|
37
43
|
chart_data: data,
|
38
44
|
id: "bar-default",
|
39
|
-
|
45
|
+
y_axis_min: 0,
|
46
|
+
subtitle: 'Subtitle to replace',
|
40
47
|
title: 'Bar Graph with Custom Overrides',
|
41
48
|
custom_options: bar_graph_options
|
42
|
-
}) %>
|
49
|
+
}) %>
|
@@ -1,25 +1,24 @@
|
|
1
1
|
@import "./body_mixins";
|
2
2
|
@import "../tokens/titles";
|
3
3
|
|
4
|
-
[class^=
|
4
|
+
[class^=pb_body_kit]{
|
5
5
|
@include pb_body($text_lt_default);
|
6
6
|
@each $color_name, $color_value in $pb_body_colors {
|
7
7
|
&[class*=_#{"" + $color_name}] {
|
8
8
|
@include pb_body($color_value);
|
9
9
|
}
|
10
10
|
@each $status_name, $status_value in $pb_body_status {
|
11
|
-
&[class*=
|
11
|
+
&[class*=_default_#{$status_name}] {
|
12
12
|
@include pb_body($status_value);
|
13
13
|
}
|
14
14
|
}
|
15
15
|
}
|
16
|
-
@each $dark_color_name, $dark_color_value in $pb_dark_body_colors
|
17
|
-
&[class*=
|
16
|
+
@each $dark_color_name, $dark_color_value in $pb_dark_body_colors{
|
17
|
+
&[class*=_#{$dark_color_name}][class*=dark]{
|
18
18
|
@include pb_body($dark_color_value);
|
19
19
|
}
|
20
20
|
}
|
21
|
-
b,
|
22
|
-
strong {
|
21
|
+
b, strong {
|
23
22
|
font-weight: $bold;
|
24
23
|
}
|
25
24
|
|
@@ -30,8 +29,7 @@
|
|
30
29
|
}
|
31
30
|
}
|
32
31
|
|
33
|
-
em,
|
34
|
-
i {
|
32
|
+
em, i {
|
35
33
|
font-style: italic;
|
36
34
|
}
|
37
35
|
|
@@ -41,25 +39,26 @@
|
|
41
39
|
}
|
42
40
|
|
43
41
|
@each $status_name, $status_value in $pb_body_status {
|
44
|
-
&[class
|
42
|
+
&[class*=#{$status_name}] {
|
45
43
|
@include pb_body($status_value);
|
46
44
|
}
|
47
45
|
}
|
48
46
|
|
49
|
-
&[class*=
|
47
|
+
&[class*=dark] {
|
50
48
|
a {
|
51
49
|
color: $active_dark;
|
52
50
|
}
|
53
51
|
@include pb_body_dark();
|
54
|
-
@each $dark_color_name, $dark_color_value in $pb_dark_body_colors
|
55
|
-
&[class*=
|
52
|
+
@each $dark_color_name, $dark_color_value in $pb_dark_body_colors{
|
53
|
+
&[class*=_#{$dark_color_name}][class*=dark]{
|
56
54
|
@include pb_body($dark_color_value);
|
57
55
|
}
|
58
56
|
}
|
59
|
-
@each $status_name, $status_value in $
|
60
|
-
&[class*=
|
57
|
+
@each $status_name, $status_value in $pb_body_status {
|
58
|
+
&[class*=_#{$status_name}] {
|
61
59
|
@include pb_body($status_value);
|
62
60
|
}
|
63
61
|
}
|
64
62
|
}
|
63
|
+
|
65
64
|
}
|
@@ -3,35 +3,29 @@
|
|
3
3
|
@import "../tokens/typography";
|
4
4
|
|
5
5
|
$pb_body_colors: (
|
6
|
-
default:
|
7
|
-
light:
|
8
|
-
lighter:
|
9
|
-
link:
|
10
|
-
error:
|
11
|
-
success:
|
6
|
+
default: $text_lt_default,
|
7
|
+
light: $text_lt_light,
|
8
|
+
lighter: $text_lt_lighter,
|
9
|
+
link: $primary,
|
10
|
+
error: $error,
|
11
|
+
success: $text_lt_success_sm,
|
12
12
|
);
|
13
13
|
|
14
14
|
$pb_dark_body_colors: (
|
15
|
-
default:
|
16
|
-
light:
|
17
|
-
lighter:
|
18
|
-
link:
|
19
|
-
error:
|
20
|
-
success:
|
15
|
+
default: $text_dk_default,
|
16
|
+
light: $text_dk_light,
|
17
|
+
lighter: $text_dk_lighter,
|
18
|
+
link: $active_dark,
|
19
|
+
error: $error,
|
20
|
+
success: $text_dk_success_sm,
|
21
21
|
);
|
22
22
|
|
23
23
|
// Order is important here!
|
24
24
|
$pb_body_status: (
|
25
|
-
default:
|
26
|
-
negative:
|
27
|
-
dark_error:
|
28
|
-
positive:
|
29
|
-
);
|
30
|
-
|
31
|
-
$pb_dark_body_status: (
|
32
|
-
default: $text_dk_default,
|
33
|
-
negative: $error_dark,
|
34
|
-
positive: $text_dk_success_sm,
|
25
|
+
default: $text_lt_default,
|
26
|
+
negative: $error,
|
27
|
+
dark_error: $error_dark_body,
|
28
|
+
positive: $text_lt_success_sm,
|
35
29
|
);
|
36
30
|
|
37
31
|
@mixin pb_body($color: $text_lt_default) {
|
@@ -1,5 +1,3 @@
|
|
1
|
-
@use "sass:math";
|
2
|
-
|
3
1
|
@import "../tokens/colors";
|
4
2
|
@import "../tokens/opacity";
|
5
3
|
@import "../tokens/spacing";
|
@@ -11,7 +9,7 @@
|
|
11
9
|
display: inline-flex;
|
12
10
|
align-items: center;
|
13
11
|
justify-content: center;
|
14
|
-
padding: 0
|
12
|
+
padding: 0 $space_xs/2;
|
15
13
|
|
16
14
|
svg {
|
17
15
|
margin-right: 8px;
|
@@ -13,7 +13,6 @@ const BreadCrumbsDefault = (props) => {
|
|
13
13
|
<Icon
|
14
14
|
icon="home"
|
15
15
|
size="1x"
|
16
|
-
{...props}
|
17
16
|
/>
|
18
17
|
<BreadCrumbItem
|
19
18
|
{...props}
|
@@ -23,13 +22,11 @@ const BreadCrumbsDefault = (props) => {
|
|
23
22
|
size="4"
|
24
23
|
tag="span"
|
25
24
|
text="Home"
|
26
|
-
{...props}
|
27
25
|
/>
|
28
26
|
</BreadCrumbItem>
|
29
27
|
<Icon
|
30
28
|
icon="users"
|
31
29
|
size="1x"
|
32
|
-
{...props}
|
33
30
|
/>
|
34
31
|
<Link
|
35
32
|
{...props}
|
@@ -39,20 +36,17 @@ const BreadCrumbsDefault = (props) => {
|
|
39
36
|
size="4"
|
40
37
|
tag="span"
|
41
38
|
text="Users"
|
42
|
-
{...props}
|
43
39
|
/>
|
44
40
|
</Link>
|
45
41
|
<Icon
|
46
42
|
icon="user"
|
47
43
|
size="1x"
|
48
|
-
{...props}
|
49
44
|
/>
|
50
45
|
<Link {...props}>
|
51
46
|
<Title
|
52
47
|
size="4"
|
53
48
|
tag="span"
|
54
49
|
text="User"
|
55
|
-
{...props}
|
56
50
|
/>
|
57
51
|
</Link>
|
58
52
|
</BreadCrumbs>
|
@@ -1,5 +1,3 @@
|
|
1
|
-
@use "sass:math";
|
2
|
-
|
3
1
|
@import "./button_mixins";
|
4
2
|
@import "../tokens/colors";
|
5
3
|
@import "../tokens/border_radius";
|
@@ -19,7 +17,7 @@ $pb_button_sizes: (
|
|
19
17
|
@each $name, $size in $pb_button_sizes {
|
20
18
|
&[class*=size_#{$name}] {
|
21
19
|
font-size: $size;
|
22
|
-
padding:
|
20
|
+
padding: $size / 2 $size * 2.42;
|
23
21
|
@if $name == "sm" {
|
24
22
|
min-height: 0;
|
25
23
|
}
|
@@ -21,14 +21,6 @@
|
|
21
21
|
border-width: 0px;
|
22
22
|
}
|
23
23
|
|
24
|
-
@function ends-with($string, $suffix) {
|
25
|
-
$suffix-length: str-length($suffix);
|
26
|
-
@if $suffix-length == 0 {
|
27
|
-
@return true;
|
28
|
-
}
|
29
|
-
@return str-slice($string, -$suffix-length) == $suffix;
|
30
|
-
}
|
31
|
-
|
32
24
|
[class^=pb_card_header_kit] {
|
33
25
|
flex-grow: 0;
|
34
26
|
flex-shrink: 0;
|
@@ -38,19 +30,9 @@
|
|
38
30
|
border: 0;
|
39
31
|
border-radius: $pb_card_header_border_radius $pb_card_header_border_radius 0px 0px;
|
40
32
|
@each $color_name, $color_value in $pb_card_header_colors {
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
color: lightenText($color_value);
|
45
|
-
}
|
46
|
-
}
|
47
|
-
}
|
48
|
-
@each $color_name, $color_value in $pb_card_header_colors {
|
49
|
-
@if ends-with($color_name, '_subtle') {
|
50
|
-
&[class*="_#{$color_name}"] {
|
51
|
-
@include pb_card_header_color($color_value);
|
52
|
-
color: lightenText($color_value);
|
53
|
-
}
|
33
|
+
&[class*=_#{"" + $color_name}] {
|
34
|
+
@include pb_card_header_color($color_value);
|
35
|
+
color: lightenText($color_value);
|
54
36
|
}
|
55
37
|
}
|
56
38
|
@each $color_name, $color_value in $pb_card_header_colors {
|
@@ -6,7 +6,7 @@ import classnames from 'classnames'
|
|
6
6
|
|
7
7
|
import { buildAriaProps, buildCss, buildDataProps, buildHtmlProps } from '../utilities/props'
|
8
8
|
import { GlobalProps, globalProps, globalInlineProps } from '../utilities/globalProps'
|
9
|
-
import type { ProductColors, CategoryColors, BackgroundColors
|
9
|
+
import type { ProductColors, CategoryColors, BackgroundColors } from '../types/colors'
|
10
10
|
|
11
11
|
import Icon from '../pb_icon/_icon'
|
12
12
|
import Flex from '../pb_flex/_flex'
|
@@ -36,7 +36,7 @@ type CardPropTypes = {
|
|
36
36
|
} & GlobalProps
|
37
37
|
|
38
38
|
type CardHeaderProps = {
|
39
|
-
headerColor?: BackgroundColors | ProductColors | CategoryColors |
|
39
|
+
headerColor?: BackgroundColors | ProductColors | CategoryColors | "none",
|
40
40
|
headerColorStriped?: boolean,
|
41
41
|
children: React.ReactChild[] | React.ReactChild,
|
42
42
|
className?: string,
|
@@ -127,12 +127,12 @@ const Card = (props: CardPropTypes): React.ReactElement => {
|
|
127
127
|
|
128
128
|
const tagOptions = ['div', 'section', 'footer', 'header', 'article', 'aside', 'main', 'nav']
|
129
129
|
const Tag = tagOptions.includes(tag) ? tag : 'div'
|
130
|
-
|
130
|
+
|
131
131
|
return (
|
132
132
|
<>
|
133
133
|
{
|
134
134
|
draggableItem ? (
|
135
|
-
<Draggable.Item dragId={dragId}
|
135
|
+
<Draggable.Item dragId={dragId}
|
136
136
|
key={dragId}
|
137
137
|
>
|
138
138
|
<Tag
|
@@ -140,14 +140,14 @@ const Card = (props: CardPropTypes): React.ReactElement => {
|
|
140
140
|
{...dataProps}
|
141
141
|
className={classnames(cardCss, globalProps(props), className)}
|
142
142
|
{...restHtmlProps}
|
143
|
-
style={mergedStyles}
|
143
|
+
style={mergedStyles}
|
144
144
|
>
|
145
145
|
{subComponentTags('Header')}
|
146
146
|
{
|
147
147
|
dragHandle ? (
|
148
148
|
<Flex>
|
149
149
|
<span className="card_draggable_handle">
|
150
|
-
<Icon
|
150
|
+
<Icon
|
151
151
|
icon="grip-dots-vertical"
|
152
152
|
paddingRight="xs"
|
153
153
|
verticalAlign="middle"
|
@@ -169,7 +169,7 @@ const Card = (props: CardPropTypes): React.ReactElement => {
|
|
169
169
|
{...dataProps}
|
170
170
|
className={classnames(cardCss, globalProps(props), className)}
|
171
171
|
{...restHtmlProps}
|
172
|
-
style={mergedStyles}
|
172
|
+
style={mergedStyles}
|
173
173
|
>
|
174
174
|
{subComponentTags('Header')}
|
175
175
|
{nonHeaderChildren}
|
@@ -24,7 +24,7 @@ $additional_colors: (
|
|
24
24
|
"neutral_subtle": $neutral_subtle,
|
25
25
|
);
|
26
26
|
$background_colors: map-merge($product_colors, $additional_colors);
|
27
|
-
$pb_card_header_colors: map-merge(map-merge(
|
27
|
+
$pb_card_header_colors: map-merge(map-merge($product_colors, $additional_colors), $category_colors);
|
28
28
|
|
29
29
|
@mixin pb_card_selected($border_color: $primary) {
|
30
30
|
border-color: $border_color;
|
@@ -32,7 +32,7 @@ $pb_card_header_colors: map-merge(map-merge(map-merge($product_colors, $addition
|
|
32
32
|
}
|
33
33
|
|
34
34
|
@mixin pb_card_selected_dark {
|
35
|
-
@include pb_card_selected($
|
35
|
+
@include pb_card_selected($primary_action);
|
36
36
|
}
|
37
37
|
|
38
38
|
@mixin pb_card($background: $card_light, $border_color: $border_light) {
|
@@ -67,42 +67,4 @@
|
|
67
67
|
<%= pb_rails("card/card_body", props: { padding: "md", }) do %>
|
68
68
|
Body
|
69
69
|
<% end %>
|
70
|
-
<% end %>
|
71
|
-
|
72
|
-
<%= pb_rails("title", props: { text: "Status Colors", tag: "h4", size: 4, margin_bottom: "sm" }) %>
|
73
|
-
|
74
|
-
<%= pb_rails("card", props: { padding: "none", header: true, margin_bottom: "sm"}) do %>
|
75
|
-
<%= pb_rails("card/card_header", props: { padding: "sm", header_color: "success" }) do %>
|
76
|
-
<%= pb_rails("body", props: { text: "Success", dark: true }) %>
|
77
|
-
<% end %>
|
78
|
-
<%= pb_rails("card/card_body", props: { padding: "md" }) do %>
|
79
|
-
Body
|
80
|
-
<% end %>
|
81
|
-
<% end %>
|
82
|
-
|
83
|
-
<%= pb_rails("card", props: { padding: "none", header: true, margin_bottom: "sm"}) do %>
|
84
|
-
<%= pb_rails("card/card_header", props: { padding: "sm", header_color: "error" }) do %>
|
85
|
-
<%= pb_rails("body", props: { text: "Error", dark: true }) %>
|
86
|
-
<% end %>
|
87
|
-
<%= pb_rails("card/card_body", props: { padding: "md" }) do %>
|
88
|
-
Body
|
89
|
-
<% end %>
|
90
|
-
<% end %>
|
91
|
-
|
92
|
-
<%= pb_rails("card", props: { padding: "none", header: true, margin_bottom: "sm"}) do %>
|
93
|
-
<%= pb_rails("card/card_header", props: { padding: "sm", header_color: "success_subtle" }) do %>
|
94
|
-
<%= pb_rails("body", props: { text: "Success Subtle" }) %>
|
95
|
-
<% end %>
|
96
|
-
<%= pb_rails("card/card_body", props: { padding: "md" }) do %>
|
97
|
-
Body
|
98
|
-
<% end %>
|
99
|
-
<% end %>
|
100
|
-
|
101
|
-
<%= pb_rails("card", props: { padding: "none", header: true, margin_bottom: "sm"}) do %>
|
102
|
-
<%= pb_rails("card/card_header", props: { padding: "sm", header_color: "error_subtle" }) do %>
|
103
|
-
<%= pb_rails("body", props: { text: "Error Subtle"}) %>
|
104
|
-
<% end %>
|
105
|
-
<%= pb_rails("card/card_body", props: { padding: "md" }) do %>
|
106
|
-
Body
|
107
|
-
<% end %>
|
108
|
-
<% end %>
|
70
|
+
<% end %>
|