playbook_ui 7.14.0.pre.alpha1 → 7.14.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/helpers/playbook/pb_sample_helper.rb +1 -1
- data/app/pb_kits/playbook/pb_background/docs/_background_dark.html.erb +3 -0
- data/app/pb_kits/playbook/pb_background/docs/_background_dark.jsx +12 -0
- data/app/pb_kits/playbook/pb_background/docs/example.yml +2 -0
- data/app/pb_kits/playbook/pb_background/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_checkbox/_checkbox.html.erb +0 -1
- data/app/pb_kits/playbook/pb_checkbox/_checkbox.jsx +10 -36
- data/app/pb_kits/playbook/pb_checkbox/_checkbox.scss +20 -26
- data/app/pb_kits/playbook/pb_checkbox/checkbox.rb +0 -5
- data/app/pb_kits/playbook/pb_checkbox/docs/_checkbox_custom.jsx +1 -0
- data/app/pb_kits/playbook/pb_checkbox/docs/example.yml +0 -2
- data/app/pb_kits/playbook/pb_checkbox/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_date_range_stacked/docs/_date_range_stacked_dark.html.erb +1 -0
- data/app/pb_kits/playbook/pb_date_range_stacked/docs/_date_range_stacked_dark.jsx +15 -0
- data/app/pb_kits/playbook/pb_date_range_stacked/docs/example.yml +4 -0
- data/app/pb_kits/playbook/pb_date_range_stacked/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_date_stacked/docs/_date_stacked_dark.html.erb +5 -0
- data/app/pb_kits/playbook/pb_date_stacked/docs/_date_stacked_dark.jsx +26 -0
- data/app/pb_kits/playbook/pb_date_stacked/docs/example.yml +7 -0
- data/app/pb_kits/playbook/pb_date_stacked/docs/index.js +2 -0
- data/app/pb_kits/playbook/pb_date_time_stacked/docs/_date_time_stacked_dark.html.erb +1 -0
- data/app/pb_kits/playbook/pb_date_time_stacked/docs/_date_time_stacked_dark.jsx +14 -0
- data/app/pb_kits/playbook/pb_date_time_stacked/docs/example.yml +4 -0
- data/app/pb_kits/playbook/pb_date_time_stacked/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_date_year_stacked/docs/_date_year_stacked_dark.html.erb +5 -0
- data/app/pb_kits/playbook/pb_date_year_stacked/docs/_date_year_stacked_dark.jsx +28 -0
- data/app/pb_kits/playbook/pb_date_year_stacked/docs/example.yml +2 -0
- data/app/pb_kits/playbook/pb_date_year_stacked/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_distribution_bar/_distribution_bar.jsx +4 -9
- data/app/pb_kits/playbook/pb_distribution_bar/_distribution_bar.scss +7 -12
- data/app/pb_kits/playbook/pb_distribution_bar/distribution_bar.rb +1 -4
- data/app/pb_kits/playbook/pb_distribution_bar/docs/example.yml +0 -2
- data/app/pb_kits/playbook/pb_distribution_bar/docs/index.js +0 -1
- data/app/pb_kits/playbook/pb_filter/Filter/CurrentFilters.jsx +1 -12
- data/app/pb_kits/playbook/pb_filter/docs/_filter_default.html.erb +0 -41
- data/app/pb_kits/playbook/pb_filter/docs/_filter_default.jsx +37 -84
- data/app/pb_kits/playbook/pb_filter/templates/_core.html.erb +7 -18
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/docs/_fixed_confirmation_toast_dark.html.erb +21 -0
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/docs/_fixed_confirmation_toast_dark.jsx +43 -0
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/docs/_fixed_confirmation_toast_multi_line_dark.html.erb +5 -0
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/docs/_fixed_confirmation_toast_multi_line_dark.jsx +17 -0
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/docs/example.yml +5 -0
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/docs/index.js +2 -0
- data/app/pb_kits/playbook/pb_flex/_flex.jsx +9 -25
- data/app/pb_kits/playbook/pb_flex/_flex.scss +7 -40
- data/app/pb_kits/playbook/pb_flex/_flex_item.jsx +2 -6
- data/app/pb_kits/playbook/pb_flex/_flex_item.scss +0 -10
- data/app/pb_kits/playbook/pb_flex/docs/_description.md +0 -6
- data/app/pb_kits/playbook/pb_flex/docs/_flex_default.html.erb +15 -15
- data/app/pb_kits/playbook/pb_flex/docs/_flex_default.jsx +15 -17
- data/app/pb_kits/playbook/pb_flex/docs/_flex_default.md +1 -3
- data/app/pb_kits/playbook/pb_flex/docs/{_flex_justify.html.erb → _flex_horizontal.html.erb} +21 -19
- data/app/pb_kits/playbook/pb_flex/docs/{_flex_align.jsx → _flex_horizontal.jsx} +77 -71
- data/app/pb_kits/playbook/pb_flex/docs/_flex_inline.html.erb +8 -8
- data/app/pb_kits/playbook/pb_flex/docs/_flex_inline.md +1 -5
- data/app/pb_kits/playbook/pb_flex/docs/_flex_reverse.html.erb +9 -9
- data/app/pb_kits/playbook/pb_flex/docs/_flex_reverse.jsx +2 -2
- data/app/pb_kits/playbook/pb_flex/docs/_flex_spacing.html.erb +8 -23
- data/app/pb_kits/playbook/pb_flex/docs/_flex_spacing.jsx +4 -4
- data/app/pb_kits/playbook/pb_flex/docs/_flex_vertical.html.erb +68 -0
- data/app/pb_kits/playbook/pb_flex/docs/{_flex_justify.jsx → _flex_vertical.jsx} +99 -41
- data/app/pb_kits/playbook/pb_flex/docs/_flex_wrap.jsx +1 -1
- data/app/pb_kits/playbook/pb_flex/docs/example.yml +4 -9
- data/app/pb_kits/playbook/pb_flex/docs/index.js +2 -4
- data/app/pb_kits/playbook/pb_flex/flex.rb +12 -79
- data/app/pb_kits/playbook/pb_flex/flex_item.rb +1 -18
- data/app/pb_kits/playbook/pb_form_pill/_form_pill.jsx +1 -7
- data/app/pb_kits/playbook/pb_icon/docs/_icon_default_dark.html.erb +3 -0
- data/app/pb_kits/playbook/pb_icon/docs/_icon_default_dark.jsx +18 -0
- data/app/pb_kits/playbook/pb_icon/docs/example.yml +2 -1
- data/app/pb_kits/playbook/pb_icon/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/_icon_circle_color_dark.html.erb +42 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/_icon_circle_color_dark.jsx +66 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/_icon_circle_dark.html.erb +4 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/_icon_circle_dark.jsx +17 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/_icon_circle_sizes_dark.html.erb +29 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/_icon_circle_sizes_dark.jsx +38 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/example.yml +7 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/index.js +3 -0
- data/app/pb_kits/playbook/pb_icon_value/docs/_icon_value_align_dark.html.erb +23 -0
- data/app/pb_kits/playbook/pb_icon_value/docs/_icon_value_align_dark.jsx +37 -0
- data/app/pb_kits/playbook/pb_icon_value/docs/_icon_value_dark.html.erb +21 -0
- data/app/pb_kits/playbook/pb_icon_value/docs/_icon_value_dark.jsx +35 -0
- data/app/pb_kits/playbook/pb_icon_value/docs/example.yml +5 -0
- data/app/pb_kits/playbook/pb_icon_value/docs/index.js +2 -0
- data/app/pb_kits/playbook/pb_layout/_layout.scss +9 -9
- data/app/pb_kits/playbook/pb_layout/docs/_layout_sizes_dark.html.erb +32 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_sizes_dark.jsx +97 -0
- data/app/pb_kits/playbook/pb_layout/docs/example.yml +4 -0
- data/app/pb_kits/playbook/pb_layout/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_popover/docs/_popover_close_dark.html.erb +43 -0
- data/app/pb_kits/playbook/pb_popover/docs/_popover_close_dark.jsx +105 -0
- data/app/pb_kits/playbook/pb_popover/docs/_popover_dark.html.erb +25 -0
- data/app/pb_kits/playbook/pb_popover/docs/_popover_dark.jsx +51 -0
- data/app/pb_kits/playbook/pb_popover/docs/_popover_list_dark.html.erb +13 -0
- data/app/pb_kits/playbook/pb_popover/docs/_popover_list_dark.jsx +54 -0
- data/app/pb_kits/playbook/pb_popover/docs/_popover_scroll_height_dark.html.erb +25 -0
- data/app/pb_kits/playbook/pb_popover/docs/_popover_scroll_height_dark.jsx +57 -0
- data/app/pb_kits/playbook/pb_popover/docs/_popover_z_index_dark.html.erb +14 -0
- data/app/pb_kits/playbook/pb_popover/docs/_popover_z_index_dark.jsx +54 -0
- data/app/pb_kits/playbook/pb_popover/docs/example.yml +13 -0
- data/app/pb_kits/playbook/pb_popover/docs/index.js +5 -0
- data/app/pb_kits/playbook/pb_select/_select.scss +4 -6
- data/app/pb_kits/playbook/pb_table/_table.jsx +0 -8
- data/app/pb_kits/playbook/pb_table/docs/_table_responsive_table.html.erb +4 -56
- data/app/pb_kits/playbook/pb_table/docs/_table_responsive_table.jsx +3 -64
- data/app/pb_kits/playbook/pb_table/styles/_all.scss +0 -3
- data/app/pb_kits/playbook/pb_table/table.rb +1 -8
- data/app/pb_kits/playbook/pb_timestamp/_timestamp.html.erb +4 -6
- data/app/pb_kits/playbook/pb_timestamp/_timestamp.jsx +16 -92
- data/app/pb_kits/playbook/pb_timestamp/_timestamp.scss +1 -12
- data/app/pb_kits/playbook/pb_timestamp/docs/_description.md +1 -1
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_align.jsx +18 -26
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_default.html.erb +1 -21
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_default.jsx +8 -40
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_elapsed.jsx +4 -12
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_elapsed_align.html.erb +54 -0
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_elapsed_align.jsx +73 -0
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_timezones.jsx +18 -26
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_timezones_align.html.erb +177 -0
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_timezones_align.jsx +209 -0
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_updated.html.erb +21 -0
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_updated.jsx +28 -6
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_updated_align.html.erb +123 -0
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_updated_align.jsx +146 -0
- data/app/pb_kits/playbook/pb_timestamp/docs/example.yml +0 -8
- data/app/pb_kits/playbook/pb_timestamp/docs/index.js +0 -4
- data/app/pb_kits/playbook/pb_timestamp/timestamp.rb +1 -83
- data/app/pb_kits/playbook/pb_typeahead/components/MultiValue.jsx +4 -2
- data/app/pb_kits/playbook/pb_user_badge/docs/_user_badge_size_dark.html.erb +21 -0
- data/app/pb_kits/playbook/pb_user_badge/docs/_user_badge_size_dark.jsx +36 -0
- data/app/pb_kits/playbook/pb_user_badge/docs/index.js +1 -0
- data/lib/playbook/version.rb +1 -1
- metadata +57 -31
- data/app/pb_kits/playbook/pb_checkbox/checkbox.test.js +0 -51
- data/app/pb_kits/playbook/pb_checkbox/docs/_checkbox_indeterminate.html.erb +0 -77
- data/app/pb_kits/playbook/pb_checkbox/docs/_checkbox_indeterminate.jsx +0 -78
- data/app/pb_kits/playbook/pb_distribution_bar/docs/_distribution_bar_custom_colors.html.erb +0 -4
- data/app/pb_kits/playbook/pb_distribution_bar/docs/_distribution_bar_custom_colors.jsx +0 -18
- data/app/pb_kits/playbook/pb_distribution_bar/docs/_distribution_bar_custom_colors.md +0 -1
- data/app/pb_kits/playbook/pb_flex/docs/_flex_align.html.erb +0 -101
- data/app/pb_kits/playbook/pb_flex/docs/_flex_align.md +0 -7
- data/app/pb_kits/playbook/pb_flex/docs/_flex_gap.html.erb +0 -33
- data/app/pb_kits/playbook/pb_flex/docs/_flex_gap.jsx +0 -75
- data/app/pb_kits/playbook/pb_flex/docs/_flex_gap.md +0 -9
- data/app/pb_kits/playbook/pb_flex/docs/_flex_item.html.erb +0 -49
- data/app/pb_kits/playbook/pb_flex/docs/_flex_item.md +0 -11
- data/app/pb_kits/playbook/pb_flex/docs/_flex_item_example.jsx +0 -113
- data/app/pb_kits/playbook/pb_flex/docs/_flex_justify.md +0 -7
- data/app/pb_kits/playbook/pb_flex/docs/_flex_reverse.md +0 -5
- data/app/pb_kits/playbook/pb_flex/docs/_flex_spacing.md +0 -7
- data/app/pb_kits/playbook/pb_flex/docs/_flex_wrap.md +0 -5
- data/app/pb_kits/playbook/pb_table/styles/_desktop_collapse.scss +0 -135
- data/app/pb_kits/playbook/pb_table/styles/_mobile_collapse.scss +0 -135
- data/app/pb_kits/playbook/pb_table/styles/_tablet_collapse.scss +0 -135
@@ -6,7 +6,6 @@ import { globalProps } from '../utilities/globalProps.js'
|
|
6
6
|
|
7
7
|
type DistributionBarProps = {
|
8
8
|
className?: string,
|
9
|
-
colors: array,
|
10
9
|
data?: string,
|
11
10
|
id?: string,
|
12
11
|
size?: "lg" | "sm",
|
@@ -19,13 +18,13 @@ const normalizeCharacters = (widths) => {
|
|
19
18
|
})
|
20
19
|
}
|
21
20
|
|
22
|
-
const barValues = (normalizedValues
|
21
|
+
const barValues = (normalizedValues) => {
|
23
22
|
const arrSum = (value) => value.reduce((a, b) => a + b, 0)
|
24
23
|
const widthSum = arrSum(normalizedValues)
|
25
24
|
return normalizedValues.map((value, i) => {
|
26
25
|
return (
|
27
26
|
<div
|
28
|
-
className=
|
27
|
+
className="pb_distribution_width"
|
29
28
|
key={i}
|
30
29
|
style={{ width: `${(value * 100) / widthSum}%` }}
|
31
30
|
/>
|
@@ -34,16 +33,12 @@ const barValues = (normalizedValues, colors) => {
|
|
34
33
|
}
|
35
34
|
|
36
35
|
const DistributionBar = (props: DistributionBarProps) => {
|
37
|
-
const {
|
38
|
-
size = 'lg',
|
39
|
-
widths = [1],
|
40
|
-
colors = [],
|
41
|
-
} = props
|
36
|
+
const { size = 'lg', widths = [1] } = props
|
42
37
|
const normalizedValues = normalizeCharacters(widths)
|
43
38
|
|
44
39
|
return (
|
45
40
|
<div className={classnames(`pb_distribution_bar_${size}`, globalProps(props))}>
|
46
|
-
{barValues(normalizedValues
|
41
|
+
{barValues(normalizedValues)}
|
47
42
|
</div>
|
48
43
|
)
|
49
44
|
}
|
@@ -5,26 +5,21 @@
|
|
5
5
|
$small_bar: 8px;
|
6
6
|
$large_bar: 36px;
|
7
7
|
display: flex;
|
8
|
-
border-radius: $large_bar;
|
9
|
-
overflow: auto;
|
10
8
|
.pb_distribution_width {
|
11
9
|
height: 100%;
|
12
10
|
display: inline-block;
|
13
|
-
@
|
14
|
-
&:nth-child(#{length($
|
15
|
-
background-color: $
|
16
|
-
}
|
17
|
-
&.color_#{$name} {
|
18
|
-
background-color: $color !important;
|
11
|
+
@for $i from 1 through length($bar_colors) {
|
12
|
+
&:nth-child(#{length($bar_colors)}n+#{$i}) {
|
13
|
+
background-color: nth($bar_colors, $i);
|
19
14
|
}
|
20
15
|
}
|
21
16
|
&:first-child {
|
22
|
-
border-top-left-radius:
|
23
|
-
border-bottom-left-radius:
|
17
|
+
border-top-left-radius: 18px;
|
18
|
+
border-bottom-left-radius: 18px;
|
24
19
|
}
|
25
20
|
&:last-child {
|
26
|
-
border-top-right-radius:
|
27
|
-
border-bottom-right-radius:
|
21
|
+
border-top-right-radius: 18px;
|
22
|
+
border-bottom-right-radius: 18px;
|
28
23
|
}
|
29
24
|
}
|
30
25
|
&[class*=_sm] {
|
@@ -11,9 +11,7 @@ module Playbook
|
|
11
11
|
values: %w[lg sm],
|
12
12
|
default: "lg"
|
13
13
|
prop :widths, type: Playbook::Props::NumberArray,
|
14
|
-
|
15
|
-
prop :colors, type: Playbook::Props::Array,
|
16
|
-
default: []
|
14
|
+
default: [1]
|
17
15
|
|
18
16
|
def classname
|
19
17
|
generate_classname("pb_distribution_bar", size)
|
@@ -29,7 +27,6 @@ module Playbook
|
|
29
27
|
{
|
30
28
|
size: size,
|
31
29
|
widths: widths,
|
32
|
-
colors: colors,
|
33
30
|
}
|
34
31
|
end
|
35
32
|
end
|
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
import React from 'react'
|
4
4
|
import { isEmpty, map, omitBy } from 'lodash'
|
5
|
-
import {
|
5
|
+
import { Caption, Title } from '../../'
|
6
6
|
|
7
7
|
export type FilterDescription = {
|
8
8
|
[key: string]: ?string | boolean,
|
@@ -20,17 +20,6 @@ const CurrentFilters = ({ dark, filters }: CurrentFiltersProps) => {
|
|
20
20
|
|
21
21
|
return (
|
22
22
|
<div className="maskContainer">
|
23
|
-
<If condition={isEmpty(filters)}>
|
24
|
-
<div className="filters">
|
25
|
-
<Body
|
26
|
-
color="light"
|
27
|
-
paddingLeft="xs"
|
28
|
-
size={4}
|
29
|
-
tag="h4"
|
30
|
-
text="No Filter Selected"
|
31
|
-
/>
|
32
|
-
</div>
|
33
|
-
</If>
|
34
23
|
<If condition={!isEmpty(filters)}>
|
35
24
|
<div className="filters">
|
36
25
|
<div className="left_gradient" />
|
@@ -38,44 +38,3 @@
|
|
38
38
|
<% end %>
|
39
39
|
<% end %>
|
40
40
|
<% end %>
|
41
|
-
|
42
|
-
<br>
|
43
|
-
<br>
|
44
|
-
|
45
|
-
<%=
|
46
|
-
pb_rails("filter", props: {
|
47
|
-
id: "def2",
|
48
|
-
|
49
|
-
sort_menu: [
|
50
|
-
{ item: "Popularity", link: "?q[sorts]=managers_popularity+asc", active: true, direction: "desc" },
|
51
|
-
{ item: "Mananger's Title", link: "?q[sorts]=managers_title+asc", active: false },
|
52
|
-
{ item: "Manager's Name", link: "?q[sorts]=managers_name+asc", active: false },
|
53
|
-
],
|
54
|
-
template: "default",
|
55
|
-
results: 0,
|
56
|
-
}) do
|
57
|
-
%>
|
58
|
-
<%
|
59
|
-
example_collection = [
|
60
|
-
OpenStruct.new(name: "Alabama", value: 1),
|
61
|
-
OpenStruct.new(name: "Alaska", value: 2),
|
62
|
-
OpenStruct.new(name: "Arizona", value: 3),
|
63
|
-
OpenStruct.new(name: "Arkansas", value: 4),
|
64
|
-
OpenStruct.new(name: "California", value: 5),
|
65
|
-
OpenStruct.new(name: "Colorado", value: 6),
|
66
|
-
OpenStruct.new(name: "Connecticut", value: 7),
|
67
|
-
OpenStruct.new(name: "Delaware", value: 8),
|
68
|
-
OpenStruct.new(name: "Florida", value: 9),
|
69
|
-
OpenStruct.new(name: "Georgia", value: 10),
|
70
|
-
]
|
71
|
-
%>
|
72
|
-
<%= pb_rails("form", props: { form_system_options: { scope: :example, method: :get } }) do |form| %>
|
73
|
-
<%= form.text_field :example_text_field, props: { label: true } %>
|
74
|
-
<%= form.collection_select :example_collection_select, example_collection, :value, :name, props: { label: true } %>
|
75
|
-
|
76
|
-
<%= form.actions do |action| %>
|
77
|
-
<%= action.submit props: { text: "Apply", data: { disable_with: "<i class='far fa-spinner fa-spin mr-3'></i>Searching...".html_safe },}%>
|
78
|
-
<%= action.button props: { type: "reset", text: "Clear", variant: "secondary" } %>
|
79
|
-
<% end %>
|
80
|
-
<% end %>
|
81
|
-
<% end %>
|
@@ -10,98 +10,51 @@ const FilterDefault = (props) => {
|
|
10
10
|
{ value: 'A Galaxy Far Far Away Like Really Far Away' },
|
11
11
|
]
|
12
12
|
return (
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
13
|
+
<Filter
|
14
|
+
double
|
15
|
+
filters={{
|
16
|
+
'Full Name': 'John Wick',
|
17
|
+
'City': 'San Francisco',
|
18
|
+
}}
|
19
|
+
results={1}
|
20
|
+
sortOptions={{
|
21
|
+
popularity: 'Popularity',
|
22
|
+
// eslint-disable-next-line
|
23
|
+
manager_title: 'Manager\'s Title',
|
24
|
+
// eslint-disable-next-line
|
25
|
+
manager_name: 'Manager\'s Name',
|
26
|
+
}}
|
27
|
+
sortValue={[{ name: 'popularity', dir: 'desc' }]}
|
28
|
+
{...props}
|
29
|
+
>
|
30
|
+
<TextInput
|
31
|
+
label="Full Name"
|
32
|
+
placeholder="Enter name"
|
30
33
|
{...props}
|
31
|
-
|
32
|
-
<TextInput
|
33
|
-
label="Full Name"
|
34
|
-
placeholder="Enter name"
|
35
|
-
{...props}
|
36
|
-
/>
|
37
|
-
|
38
|
-
<Select
|
39
|
-
blankSelection="Select One..."
|
40
|
-
label="Territory"
|
41
|
-
name="location"
|
42
|
-
options={options}
|
43
|
-
{...props}
|
44
|
-
/>
|
45
|
-
<Flex
|
46
|
-
spacing="between"
|
47
|
-
{...props}
|
48
|
-
>
|
49
|
-
<Button
|
50
|
-
text="Apply"
|
51
|
-
{...props}
|
52
|
-
/>
|
53
|
-
<Button
|
54
|
-
text="Clear"
|
55
|
-
variant="secondary"
|
56
|
-
{...props}
|
57
|
-
/>
|
58
|
-
</Flex>
|
59
|
-
</Filter>
|
60
|
-
|
61
|
-
<br />
|
34
|
+
/>
|
62
35
|
|
63
|
-
<
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
}}
|
73
|
-
sortValue={[{ name: 'popularity', dir: 'desc' }]}
|
36
|
+
<Select
|
37
|
+
blankSelection="Select One..."
|
38
|
+
label="Territory"
|
39
|
+
name="location"
|
40
|
+
options={options}
|
41
|
+
{...props}
|
42
|
+
/>
|
43
|
+
<Flex
|
44
|
+
spacing="between"
|
74
45
|
{...props}
|
75
46
|
>
|
76
|
-
<
|
77
|
-
|
78
|
-
placeholder="Enter Text"
|
47
|
+
<Button
|
48
|
+
text="Apply"
|
79
49
|
{...props}
|
80
50
|
/>
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
label="Example Collection Select"
|
85
|
-
name="Collection Select"
|
86
|
-
options={options}
|
51
|
+
<Button
|
52
|
+
text="Clear"
|
53
|
+
variant="secondary"
|
87
54
|
{...props}
|
88
55
|
/>
|
89
|
-
|
90
|
-
|
91
|
-
{...props}
|
92
|
-
>
|
93
|
-
<Button
|
94
|
-
text="Apply"
|
95
|
-
{...props}
|
96
|
-
/>
|
97
|
-
<Button
|
98
|
-
text="Clear"
|
99
|
-
variant="secondary"
|
100
|
-
{...props}
|
101
|
-
/>
|
102
|
-
</Flex>
|
103
|
-
</Filter>
|
104
|
-
</>
|
56
|
+
</Flex>
|
57
|
+
</Filter>
|
105
58
|
)
|
106
59
|
}
|
107
60
|
|
@@ -6,24 +6,12 @@
|
|
6
6
|
<div class="maskContainer">
|
7
7
|
<div class="filters">
|
8
8
|
<div class="left_gradient"></div>
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
size: 4,
|
16
|
-
tag:"h4",
|
17
|
-
text: "No Filter Selected"
|
18
|
-
}) %>
|
19
|
-
</div>
|
20
|
-
<% else %>
|
21
|
-
<div class="filter">
|
22
|
-
<%= pb_rails("caption", props: { text: filter[:name]}) %>
|
23
|
-
<%= pb_rails("title", props: { size: 4, tag:"h4", text: filter[:value]}) %>
|
24
|
-
</div>
|
25
|
-
<% end %>
|
26
|
-
<% end %>
|
9
|
+
<% object.filters.each do |filter| %>
|
10
|
+
<div class="filter">
|
11
|
+
<%= pb_rails("caption", props: { text: filter[:name]}) %>
|
12
|
+
<%= pb_rails("title", props: { size: 4, tag:"h4", text: filter[:value]}) %>
|
13
|
+
</div>
|
14
|
+
<% end %>
|
27
15
|
<div class="right_gradient"></div>
|
28
16
|
</div>
|
29
17
|
</div>
|
@@ -32,6 +20,7 @@
|
|
32
20
|
<% end %>
|
33
21
|
<% end %>
|
34
22
|
|
23
|
+
|
35
24
|
<% if (object.template == "single" ) || (object.template == "sort_only") %>
|
36
25
|
<% unless object.sort_menu == [{}] %>
|
37
26
|
<%= pb_rails("button", props: {variant: "link",id: "sort-button#{object.id}",padding_right: "none"}) do %>
|
data/app/pb_kits/playbook/pb_fixed_confirmation_toast/docs/_fixed_confirmation_toast_dark.html.erb
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
<%= pb_rails("fixed_confirmation_toast", props: {
|
2
|
+
dark: true,
|
3
|
+
text: "Error Message",
|
4
|
+
status: "error"
|
5
|
+
})%>
|
6
|
+
|
7
|
+
<br><br>
|
8
|
+
|
9
|
+
<%= pb_rails("fixed_confirmation_toast", props: {
|
10
|
+
dark: true,
|
11
|
+
text: "Items Successfully Moved",
|
12
|
+
status: "success"
|
13
|
+
})%>
|
14
|
+
|
15
|
+
<br><br>
|
16
|
+
|
17
|
+
<%= pb_rails("fixed_confirmation_toast", props: {
|
18
|
+
dark: true,
|
19
|
+
text: "Scan to Assign Selected Items",
|
20
|
+
status: "neutral"
|
21
|
+
})%>
|
@@ -0,0 +1,43 @@
|
|
1
|
+
import React from 'react'
|
2
|
+
import { FixedConfirmationToast } from '../..'
|
3
|
+
|
4
|
+
const FixedConfirmationToastDark = (props) => {
|
5
|
+
return (
|
6
|
+
<div>
|
7
|
+
<div>
|
8
|
+
<FixedConfirmationToast
|
9
|
+
dark
|
10
|
+
status="error"
|
11
|
+
text="Error Message"
|
12
|
+
{...props}
|
13
|
+
/>
|
14
|
+
</div>
|
15
|
+
|
16
|
+
<br />
|
17
|
+
<br />
|
18
|
+
|
19
|
+
<div>
|
20
|
+
<FixedConfirmationToast
|
21
|
+
dark
|
22
|
+
status="success"
|
23
|
+
text="Items Successfully Moved"
|
24
|
+
{...props}
|
25
|
+
/>
|
26
|
+
</div>
|
27
|
+
|
28
|
+
<br />
|
29
|
+
<br />
|
30
|
+
|
31
|
+
<div>
|
32
|
+
<FixedConfirmationToast
|
33
|
+
dark
|
34
|
+
status="neutral"
|
35
|
+
text="Scan to Assign Selected Items"
|
36
|
+
{...props}
|
37
|
+
/>
|
38
|
+
</div>
|
39
|
+
</div>
|
40
|
+
)
|
41
|
+
}
|
42
|
+
|
43
|
+
export default FixedConfirmationToastDark
|