Skip to content

Commit d4f500c

Browse files
committed
docs(cypress): fix loading of queries and commands
1 parent 130de5c commit d4f500c

File tree

2 files changed

+10
-6
lines changed

2 files changed

+10
-6
lines changed
Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import { CommandsAndQueries } from './CommandsAndQueries.tsx';
1+
import { Footer, TableOfContent } from '@sb/components';
22
import { Meta } from '@storybook/addon-docs';
33
import API from './api.json';
4-
import { Footer, TableOfContent } from '@sb/components';
4+
import { CommandsAndQueries } from './CommandsAndQueries.tsx';
55

66
<Meta title="Commands" />
77

@@ -11,6 +11,8 @@ import { Footer, TableOfContent } from '@sb/components';
1111

1212
Here you can find all available Commands of the `@ui5/webcomponents-cypress-commands` package.
1313

14-
<CommandsAndQueries api={API.children[1].children[0].children[0].children} />
14+
<CommandsAndQueries
15+
api={API.children.find((file) => file.name === 'src/commands')?.children?.[0]?.children?.[0]?.children ?? []}
16+
/>
1517

1618
<Footer />

packages/cypress-commands/Queries.mdx

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import { CommandsAndQueries } from './CommandsAndQueries.tsx';
1+
import { Footer, TableOfContent } from '@sb/components';
22
import { Meta } from '@storybook/addon-docs';
33
import API from './api.json';
4-
import { Footer, TableOfContent } from '@sb/components';
4+
import { CommandsAndQueries } from './CommandsAndQueries.tsx';
55

66
<Meta title="Queries" />
77

@@ -11,6 +11,8 @@ import { Footer, TableOfContent } from '@sb/components';
1111

1212
Here you can find all available Queries of the `@ui5/webcomponents-cypress-commands` package.
1313

14-
<CommandsAndQueries api={API.children[2].children[0].children[0].children} />
14+
<CommandsAndQueries
15+
api={API.children.find((file) => file.name === 'src/queries')?.children?.[0]?.children?.[0]?.children ?? []}
16+
/>
1517

1618
<Footer />

0 commit comments

Comments
 (0)