-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: List V9 - update stories to work with dark themes (#32392)
- Loading branch information
Showing
7 changed files
with
57 additions
and
13 deletions.
There are no files selected for viewing
7 changes: 7 additions & 0 deletions
7
change/@fluentui-react-list-preview-0fea1476-770a-41e9-9823-8a0aee6c8a76.json
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,7 @@ | ||
{ | ||
"type": "none", | ||
"comment": "fix: List V9 - update stories to work with dark themes", | ||
"packageName": "@fluentui/react-list-preview", | ||
"email": "[email protected]", | ||
"dependentChangeType": "none" | ||
} |
44 changes: 33 additions & 11 deletions
44
packages/react-components/react-list-preview/stories/src/List/ListDefault.stories.tsx
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,14 +1,36 @@ | ||
import * as React from 'react'; | ||
import { List, ListItem } from '@fluentui/react-list-preview'; | ||
import { tokens, Text, makeResetStyles } from '@fluentui/react-components'; | ||
|
||
export const Default = () => ( | ||
<List> | ||
<ListItem>Asia</ListItem> | ||
<ListItem>Africa</ListItem> | ||
<ListItem>Europe</ListItem> | ||
<ListItem>North America</ListItem> | ||
<ListItem>South America</ListItem> | ||
<ListItem>Australia/Oceania</ListItem> | ||
<ListItem>Antarctica</ListItem> | ||
</List> | ||
); | ||
const useTextStyle = makeResetStyles({ | ||
color: tokens.colorNeutralForeground1, | ||
}); | ||
|
||
export const Default = () => { | ||
const textStyle = useTextStyle(); | ||
return ( | ||
<List> | ||
<ListItem> | ||
<Text className={textStyle}>Asia</Text> | ||
</ListItem> | ||
<ListItem> | ||
<Text className={textStyle}>Africa</Text> | ||
</ListItem> | ||
<ListItem> | ||
<Text className={textStyle}>Europe</Text> | ||
</ListItem> | ||
<ListItem> | ||
<Text className={textStyle}>North America</Text> | ||
</ListItem> | ||
<ListItem> | ||
<Text className={textStyle}>South America</Text> | ||
</ListItem> | ||
<ListItem> | ||
<Text className={textStyle}>Australia/Oceania</Text> | ||
</ListItem> | ||
<ListItem> | ||
<Text className={textStyle}>Antarctica</Text> | ||
</ListItem> | ||
</List> | ||
); | ||
}; |
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
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