(
gap="sm"
wrap
>
+
+
+
\ No newline at end of file
+/>
+
+
diff --git a/playbook/app/pb_kits/playbook/utilities/_hover.scss b/playbook/app/pb_kits/playbook/utilities/_hover.scss
index 853d835123..1974908e43 100644
--- a/playbook/app/pb_kits/playbook/utilities/_hover.scss
+++ b/playbook/app/pb_kits/playbook/utilities/_hover.scss
@@ -2,11 +2,11 @@
@mixin hover-color-classes($colors-list) {
@each $name, $color in $colors-list {
- .hover_background_#{"" + $name}:hover {
+ .hover_background-#{"" + $name}:hover {
background-color: $color !important;
transition: background-color $transition-speed ease;
}
- .hover_color_#{"" + $name}:hover {
+ .hover_color-#{"" + $name}:hover {
color: $color !important;
transition: color $transition-speed ease;
}
@@ -48,4 +48,4 @@
@include hover-color-classes($hover_colors);
@include hover-color-classes($border_colors);
@include hover-color-classes($text_colors);
- @include hover-color-classes($category_colors);
\ No newline at end of file
+ @include hover-color-classes($category_colors);
diff --git a/playbook/app/pb_kits/playbook/utilities/globalProps.ts b/playbook/app/pb_kits/playbook/utilities/globalProps.ts
index 9dd67b7223..02338294bc 100644
--- a/playbook/app/pb_kits/playbook/utilities/globalProps.ts
+++ b/playbook/app/pb_kits/playbook/utilities/globalProps.ts
@@ -213,9 +213,9 @@ const PROP_CATEGORIES: {[key:string]: (props: {[key: string]: any}) => string} =
let css = '';
if (!hover) return css;
css += hover.shadow ? `hover_shadow_${hover.shadow} ` : '';
- css += hover.background ? `hover_background_${hover.background } ` : '';
+ css += hover.background ? `hover_background-${hover.background } ` : '';
css += hover.scale ? `hover_scale_${hover.scale} ` : '';
- css += hover.color ? `hover_color_${hover.color } ` : '';
+ css += hover.color ? `hover_color-${hover.color } ` : '';
return css;
},
diff --git a/playbook/app/pb_kits/playbook/utilities/test/globalProps/hover.test.js b/playbook/app/pb_kits/playbook/utilities/test/globalProps/hover.test.js
new file mode 100644
index 0000000000..237b279bd4
--- /dev/null
+++ b/playbook/app/pb_kits/playbook/utilities/test/globalProps/hover.test.js
@@ -0,0 +1,79 @@
+import React from 'react';
+import { render, screen } from '../../test-utils';
+import Body from '../../../pb_body/_body';
+
+const testSubject = 'body';
+
+test('Hover Props: returns proper class name', () => {
+ const testIdColor = `${testSubject}-hover-color-red`;
+ render(
+ |
+ );
+
+ let kit = screen.getByTestId(testIdColor);
+ let expectedClassName = `hover_color-red`;
+ expect(kit).toHaveClass(expectedClassName);
+
+ const testIdBackground = `${testSubject}-hover-background-blue`;
+ render(
+
+ );
+
+ kit = screen.getByTestId(testIdBackground);
+ expectedClassName = `hover_background-blue`;
+ expect(kit).toHaveClass(expectedClassName);
+
+ const testIdShadow = `${testSubject}-hover-shadow-deep`;
+ render(
+