Skip to content

Commit e61dcb4

Browse files
committed
refactor: failing tests fix and improvements
1 parent 24360a3 commit e61dcb4

File tree

4 files changed

+26
-40
lines changed

4 files changed

+26
-40
lines changed

src/components/identicon/identicon.stories.ts

Lines changed: 0 additions & 37 deletions
This file was deleted.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
// @ts-check
2+
import { Identicon } from './identicon'
3+
4+
const meta = {
5+
title: 'Identicon',
6+
component: Identicon,
7+
parameters: {
8+
actions: { disable: false, handles: ['click'] }
9+
},
10+
args: {
11+
cid: 'QmYPNmahJAvkMTU6tDx5zvhEkoLzEFeTDz6azDCSNqzKkW',
12+
className: 'ma2',
13+
size: 14
14+
}
15+
} as const
16+
17+
export default meta
18+
19+
export const Default = {}
20+
21+
export const Large = {
22+
args: { size: 64 }
23+
}

src/types/react-identicons.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
declare module 'react-identicons' {
22
import { FC } from 'react'
3-
3+
44
interface ReactIdenticonProps {
55
string: string
66
size?: number
77
palette?: string[]
88
className?: string
99
}
10-
10+
1111
const ReactIdenticon: FC<ReactIdenticonProps>
1212
export default ReactIdenticon
1313
}

tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@
9898
"src/components/box/Box.js",
9999
"src/components/shell/Shell.js",
100100
"src/components/identicon/identicon.tsx",
101-
"src/components/identicon/identicon.stories.ts",
101+
"src/components/identicon/identicon.stories.tsx",
102102
"src/i18n-decorator.js",
103103
"src/i18n.js",
104104
"src/lib/i18n-localeParser.js"

0 commit comments

Comments
 (0)