Skip to content

Commit 7cf9c0d

Browse files
authored
Merge pull request #11002 from marmelab/fix-array-input-stories
Fix array input stories
2 parents 501d26e + ba29cd1 commit 7cf9c0d

File tree

2 files changed

+18
-13
lines changed

2 files changed

+18
-13
lines changed

packages/ra-core/src/controller/input/ArrayInputBase.stories.tsx

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -18,19 +18,23 @@ export default { title: 'ra-core/controller/input/ArrayInputBase' };
1818
export const Basic = () => (
1919
<TestMemoryRouter initialEntries={['/posts/1']}>
2020
<Admin
21-
dataProvider={fakeRestDataProvider({
22-
posts: [
23-
{
24-
id: 1,
25-
title: 'Post 1',
26-
tags: [
27-
{ name: 'Tag 1', color: 'red' },
28-
{ name: 'Tag 2', color: 'blue' },
29-
],
30-
},
31-
{ id: 2, title: 'Post 2' },
32-
],
33-
})}
21+
dataProvider={fakeRestDataProvider(
22+
{
23+
posts: [
24+
{
25+
id: 1,
26+
title: 'Post 1',
27+
tags: [
28+
{ name: 'Tag 1', color: 'red' },
29+
{ name: 'Tag 2', color: 'blue' },
30+
],
31+
},
32+
{ id: 2, title: 'Post 2', tags: [] },
33+
],
34+
},
35+
process.env.NODE_ENV !== 'test',
36+
process.env.NODE_ENV !== 'test' ? 300 : 0
37+
)}
3438
>
3539
<Resource
3640
name="posts"

packages/ra-core/src/test-ui/SimpleFormIterator.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -282,6 +282,7 @@ export const SimpleFormIterator = (props: SimpleFormIteratorProps) => {
282282
}
283283
/>
284284
<button
285+
type="button"
285286
onClick={() =>
286287
setConfirmIsOpen(true)
287288
}

0 commit comments

Comments
 (0)