-
-
Notifications
You must be signed in to change notification settings - Fork 430
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(list component): develop new horizontal state of list component (#…
…1178) * feat(list component): develop new horizontal state of list component * refactor(list.ts): change the order of classes in twmerge
- Loading branch information
Showing
5 changed files
with
85 additions
and
1 deletion.
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
import { type CodeData } from '~/components/code-demo'; | ||
import { List, ListItem } from '~/src'; | ||
|
||
const code = ` | ||
'use client'; | ||
import { List } from 'flowbite-react'; | ||
function Component() { | ||
return ( | ||
<List horizontal> | ||
<List.Item>About</List.Item> | ||
<List.Item>Premium</List.Item> | ||
<List.Item>Campaigns</List.Item> | ||
<List.Item>Blog</List.Item> | ||
<List.Item>Affiliate Program</List.Item> | ||
<List.Item>FAQs</List.Item> | ||
<List.Item>Contact</List.Item> | ||
</List> | ||
); | ||
} | ||
`; | ||
|
||
const codeRSC = ` | ||
import { List, ListItem } from 'flowbite-react'; | ||
function Component() { | ||
return ( | ||
<List horizontal> | ||
<ListItem>About</ListItem> | ||
<ListItem>Premium</ListItem> | ||
<ListItem>Campaigns</ListItem> | ||
<ListItem>Blog</ListItem> | ||
<ListItem>Affiliate Program</ListItem> | ||
<ListItem>FAQs</ListItem> | ||
<ListItem>Contact</ListItem> | ||
</List> | ||
); | ||
} | ||
`; | ||
|
||
function Component() { | ||
return ( | ||
<List horizontal> | ||
<ListItem>About</ListItem> | ||
<ListItem>Premium</ListItem> | ||
<ListItem>Campaigns</ListItem> | ||
<ListItem>Blog</ListItem> | ||
<ListItem>Affiliate Program</ListItem> | ||
<ListItem>FAQs</ListItem> | ||
<ListItem>Contact</ListItem> | ||
</List> | ||
); | ||
} | ||
|
||
export const horizontal: CodeData = { | ||
type: 'single', | ||
code: [ | ||
{ | ||
fileName: 'client', | ||
language: 'tsx', | ||
code, | ||
}, | ||
{ | ||
fileName: 'server', | ||
language: 'tsx', | ||
code: codeRSC, | ||
}, | ||
], | ||
githubSlug: 'list/list.horizontal.tsx', | ||
component: <Component />, | ||
}; |
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
1fbe6ca
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
flowbite-react – ./
flowbite-react-git-main-themesberg.vercel.app
www.flowbite-react.com
flowbite-react-phi.vercel.app
flowbite-react-themesberg.vercel.app
flowbite-react.com