playbook_ui 15.5.0.pre.alpha.play260612706 → 15.5.0.pre.alpha.typeaheadfix12605

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 68e50dc389b41862430cc0615991fb9e83f733981412aeb7ce348cc851f19325
4
- data.tar.gz: a59b600809d8eac2c4d1718c904196de1879fd1c4307433734fd90e77a27d48c
3
+ metadata.gz: 55ff4c659b41354c334f4269d707a68355d197f2107bd6ad30538c3db3a79a9e
4
+ data.tar.gz: 88be26fddd7ab5bb775fcb638bde6adabb5e9a8114dfdf91a9996e465bcf9034
5
5
  SHA512:
6
- metadata.gz: 512a1c1bc6effa4642eaa6c75f95e0403ecd1f6c33bb87bb8cb2270f9758b6f1d2f103b96180dc4303d74991a176820ba351521fa677c288e0df7d838517b380
7
- data.tar.gz: 6a9959a608a5aae7a45bb4f98afb1e54feca7a1b6fe5a8a70a2fa4edb60f31e01c27bba37dbfc0feabd41dc7370b23be6152ab43f1e2579e1d0863fc3bf2dc08
6
+ metadata.gz: e514df0fe3dd24face52c69bde8fe96fbbc2631b9e2d7e0d884ebc37415dc2b5dc0582b9603a6ddc6f06dd2751f30a312d7f2ad3f487f82d42d8a482ed4858b4
7
+ data.tar.gz: dd28cc4eb240e9036eeedc425360e4a1931b425d27d8514702d377ff58e30a3af3f66a85a22c06ce599bc92e47e18fb8d69ef12027020f19b71155e08f818172
@@ -102,16 +102,16 @@ const Background = (props: BackgroundProps): React.ReactElement => {
102
102
  useEffect(() => {
103
103
  const updateResponsiveProps = () => {
104
104
  setResponsiveProps({
105
- backgroundSize: getResponsiveValue(backgroundSize),
106
- backgroundPosition: getResponsiveValue(backgroundPosition),
107
- backgroundRepeat: getResponsiveValue(backgroundRepeat),
108
- backgroundColor: getResponsiveValue(backgroundColor),
109
- imageUrl: getResponsiveValue(imageUrl),
105
+ backgroundSize: getResponsiveValue(props.backgroundSize),
106
+ backgroundPosition: getResponsiveValue(props.backgroundPosition),
107
+ backgroundRepeat: getResponsiveValue(props.backgroundRepeat),
108
+ backgroundColor: getResponsiveValue(props.backgroundColor),
109
+ imageUrl: getResponsiveValue(props.imageUrl),
110
110
  });
111
111
  };
112
112
  window.addEventListener('resize', updateResponsiveProps);
113
113
  return () => window.removeEventListener('resize', updateResponsiveProps);
114
- }, [backgroundSize, backgroundPosition, backgroundRepeat, backgroundColor, imageUrl]);
114
+ }, [props]);
115
115
 
116
116
 
117
117
  // Extract currently applicable responsive values.
@@ -4,6 +4,7 @@ import Background from './_background'
4
4
 
5
5
  const props = {
6
6
  data: { testid: 'background' },
7
+ backgroundColor: null,
7
8
  }
8
9
 
9
10
  it('Should be accessible', async () => {
@@ -41,8 +42,3 @@ test('applies correct overlay class when imageOverlay prop is provided', () => {
41
42
  const kit = renderKit(Background, props, { imageOverlay: 'opacity_6' });
42
43
  expect(kit).toHaveClass('imageoverlay_opacity_6');
43
44
  });
44
-
45
- test('Sets backgroundColor to light as default when no backgroundColor prop is provided', () => {
46
- const kit = renderKit(Background, props);
47
- expect(kit).toHaveClass('pb_background_color_light');
48
- });
@@ -1,3 +1,3 @@
1
- <%= pb_rails("background", props: { padding: "xl" }) do %>
1
+ <%= pb_rails("background", props: { background_color: "light", padding: "xl" }) do %>
2
2
 
3
3
  <% end %>
@@ -3,6 +3,7 @@ import Background from '../../pb_background/_background'
3
3
 
4
4
  const BackgroundLight = (props) => (
5
5
  <Background
6
+ backgroundColor="light"
6
7
  padding="xl"
7
8
  {...props}
8
9
  />
@@ -1,7 +1,7 @@
1
1
  examples:
2
2
 
3
3
  rails:
4
- - background_light: Default
4
+ - background_light: Light
5
5
  - background_white: White
6
6
  - background_gradient: Gradient
7
7
  - background_image: Image
@@ -11,7 +11,7 @@ examples:
11
11
  - background_size: Size
12
12
 
13
13
  react:
14
- - background_light: Default
14
+ - background_light: Light
15
15
  - background_white: White
16
16
  - background_gradient: Gradient
17
17
  - background_image: Image
@@ -1,5 +1,5 @@
1
1
  .pb_file_upload_kit {
2
- .pb_card_kit {
2
+ .pb_card_kit_deselected_border_radius_md {
3
3
  border: 1px #ccc dashed;
4
4
  text-align: center;
5
5
  }
@@ -11,7 +11,7 @@
11
11
  }
12
12
  &.error,
13
13
  &.pb_file_upload_kit_error {
14
- .pb_card_kit {
14
+ .pb_card_kit_deselected_border_radius_md {
15
15
  border-color: $error;
16
16
  }
17
17
  .pb_body_kit_negative {
@@ -30,12 +30,12 @@
30
30
  }
31
31
 
32
32
  .dark .pb_file_upload_kit {
33
- .pb_card_kit {
33
+ .pb_card_kit_deselected_border_radius_md {
34
34
  border: 1px $text_dk_lighter dashed;
35
35
  }
36
36
  &.error,
37
37
  &.pb_file_upload_kit_error {
38
- .pb_card_kit {
38
+ .pb_card_kit_deselected_border_radius_md {
39
39
  border-color: $error_dark;
40
40
  }
41
41
  }