parent
2362ec7d55
commit
7ca9ad4aae
4 changed files with 44 additions and 0 deletions
@ -0,0 +1,8 @@ |
||||
import React from "react"; |
||||
import Slider from "rc-slider"; |
||||
|
||||
function RcSlider({}) { |
||||
return <Slider />; |
||||
} |
||||
|
||||
export default RcSlider; |
@ -0,0 +1,25 @@ |
||||
import React, { useState } from "react"; |
||||
|
||||
import Range2Sar from "./Range2Sar"; |
||||
|
||||
function Advertisements() { |
||||
const list = { |
||||
1: <Range2Sar />, |
||||
}; |
||||
const [type, setType] = useState(1); |
||||
return ( |
||||
<div className="w-full flex flex-col items-center"> |
||||
<select |
||||
className="mb-10 w-20 bg-gray-200" |
||||
onChange={(e) => setType(e.target.value)} |
||||
> |
||||
{Object.keys(list).map((option, index) => ( |
||||
<option key={index}>{option}</option> |
||||
))} |
||||
</select> |
||||
{list[type]} |
||||
</div> |
||||
); |
||||
} |
||||
|
||||
export default Advertisements; |
Loading…
Reference in new issue