[
+ Story.storyName || 'Story',
+ Story,
+]);
-describe('[Sidebar Default story]', () => {
- it('renders without crashing', () => {
- render(
);
- });
- it('should have no a11y violations', async () => {
- const { container } = render(
);
+test.each(testCases)(
+ `renders %s without crashing`,
+ async (_storyname, Story) => {
+ const tree = render(
);
+ expect(tree.baseElement).toMatchSnapshot();
+ },
+);
+
+test.each(testCases)(
+ '%s should have no a11y violations',
+ async (_storyname, Story) => {
+ const { container } = render(
);
const results = await axe(container);
expect(results).toHaveNoViolations();
- });
-});
+ },
+);
diff --git a/packages/fuselage/src/components/Sidepanel/Sidepanel.stories.tsx b/packages/fuselage/src/components/Sidepanel/Sidepanel.stories.tsx
index af2ae8909e..42c770a251 100644
--- a/packages/fuselage/src/components/Sidepanel/Sidepanel.stories.tsx
+++ b/packages/fuselage/src/components/Sidepanel/Sidepanel.stories.tsx
@@ -6,11 +6,16 @@ import {
Icon,
IconButton,
InputBox,
- SidebarItem,
- SidebarItemBadge,
- SidebarItemIcon,
- SidebarItemMenu,
- SidebarItemTitle,
+ SidebarV2ItemTitle,
+ SidebarV2ItemCol,
+ SidebarV2ItemBadge,
+ SidebarV2ItemIcon,
+ SidebarV2ItemMenu,
+ SidebarV2ItemContent,
+ SidebarV2ItemRow,
+ SidebarV2Item,
+ SidebarV2ItemTimestamp,
+ Tag,
} from '../..';
import { SidebarItemAvatarWrapper } from '../SidebarV2/SidebarItem/SidebarItemAvatarWrapper';
import { MenuTemplate, leterAvatarUrls, names } from '../SidebarV2/helpers';
@@ -53,23 +58,52 @@ const Template: StoryFn
= (args) => (
- {new Array(20).fill(null).map((_, index) => (
-
-
-
-
-
-
- {names[index % 10]}
-
- } />
-
-
- ))}
+ {new Array(20).fill(null).map((_, index) => {
+ return (
+
+
+
+
+
+
+
+
+
+ {names[index % 10]}
+
+ 11:22:21 AM
+
+
+
+ Lorem Ipsum Indolor Dolor Ipsum Ipsum
+
+
+
+ Team title
+
+
+ } />
+
+
+
+
+ );
+ })}
diff --git a/packages/fuselage/src/components/Sidepanel/Sidepanel.styles.scss b/packages/fuselage/src/components/Sidepanel/Sidepanel.styles.scss
index eb05b8b154..28cc67f37f 100644
--- a/packages/fuselage/src/components/Sidepanel/Sidepanel.styles.scss
+++ b/packages/fuselage/src/components/Sidepanel/Sidepanel.styles.scss
@@ -48,5 +48,9 @@ $sidepanel-color-default: colors.font(default);
&-list {
padding-block: lengths.padding(8);
+
+ &__item {
+ padding-block: lengths.padding(4);
+ }
}
}
diff --git a/packages/fuselage/src/components/Sidepanel/__snapshots__/Sidepanel.spec.tsx.snap b/packages/fuselage/src/components/Sidepanel/__snapshots__/Sidepanel.spec.tsx.snap
new file mode 100644
index 0000000000..356bb8a69a
--- /dev/null
+++ b/packages/fuselage/src/components/Sidepanel/__snapshots__/Sidepanel.spec.tsx.snap
@@ -0,0 +1,2197 @@
+// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
+
+exports[`renders Default without crashing 1`] = `
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+`;