-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(documentation): edit on Github breaks page without stories attach…
…ed (#2267) Fix Changelog and search for icons page after #2132. If `storyIdToCSFFile` is not defined for example on docs page without stories attached, it breaks the whole page. ![image](https://github.com/swisspost/design-system/assets/12294151/0fea4b6e-ee95-4300-8c5c-17c0af0600ae)
- Loading branch information
Showing
9 changed files
with
44 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@swisspost/design-system-documentation': patch | ||
--- | ||
|
||
Added attached stories to changelog and search-icons pages to fix "Edit this page on Github" feature. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
packages/documentation/src/stories/icons/search-icons/search-icons.docs.mdx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
packages/documentation/src/stories/icons/search-icons/search-icons.stories.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import { Meta, StoryObj } from '@storybook/web-components'; | ||
|
||
const meta: Meta = { | ||
title: 'Icons/Search for Icons', | ||
}; | ||
|
||
export default meta; | ||
|
||
type Story = StoryObj; | ||
|
||
export const Default: Story = {}; |
5 changes: 2 additions & 3 deletions
5
packages/documentation/src/stories/misc/changelog/changelog.docs.mdx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,8 @@ | ||
import { Markdown, Meta } from '@storybook/blocks'; | ||
import changelog from '../../../../../styles/CHANGELOG.md?raw'; | ||
import { CodeOrSourceMdx } from '../../utilities/markdown/CodeOrSourceMdx'; | ||
import ChangelogStories from './changelog.stories'; | ||
|
||
<Meta | ||
title="Misc/Changelog" | ||
/> | ||
<Meta of={ChangelogStories}/> | ||
|
||
<Markdown options={{ overrides: { code: CodeOrSourceMdx } }}>{changelog}</Markdown> |
11 changes: 11 additions & 0 deletions
11
packages/documentation/src/stories/misc/changelog/changelog.stories.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import { Meta, StoryObj } from '@storybook/web-components'; | ||
|
||
const meta: Meta = { | ||
title: 'Misc/Changelog', | ||
}; | ||
|
||
export default meta; | ||
|
||
type Story = StoryObj; | ||
|
||
export const Default: Story = {}; |