mirror of
https://github.com/vercel/commerce.git
synced 2025-07-22 20:26:49 +00:00
feat: SelectCommon
This commit is contained in:
@@ -1,18 +1,28 @@
|
||||
|
||||
import { Layout } from 'src/components/common'
|
||||
import { Layout, SelectCommon } from 'src/components/common'
|
||||
import { HomeBanner, HomeCollection, HomeCTA, HomeSubscribe, HomeVideo, HomeCategories, HomeFeature, HomeRecipe } from 'src/components/modules/home';
|
||||
|
||||
const OPTION_TEST = [
|
||||
{
|
||||
name: "By Name",
|
||||
value: "Name"
|
||||
},
|
||||
{
|
||||
name: "Price (High to Low)",
|
||||
value: "Price"
|
||||
},
|
||||
{
|
||||
name: "On Sale",
|
||||
value: "Sale"
|
||||
}
|
||||
]
|
||||
const handleChange = (value:string) => {
|
||||
console.log(value)
|
||||
}
|
||||
export default function Home() {
|
||||
return (
|
||||
<>
|
||||
<HomeBanner />
|
||||
<HomeFeature />
|
||||
<HomeCategories />
|
||||
<HomeCollection />
|
||||
<HomeVideo />
|
||||
<HomeCTA />
|
||||
<HomeRecipe />
|
||||
<HomeSubscribe />
|
||||
<SelectCommon option={OPTION_TEST} placeholder="Sort By" onChange={handleChange} />
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
Reference in New Issue
Block a user