mirror of https://github.com/buster-so/buster.git
Update Select.tsx
This commit is contained in:
parent
2f7289fe85
commit
a19e672899
|
@ -1,4 +1,4 @@
|
|||
import React, { useState } from 'react';
|
||||
import React from 'react';
|
||||
import {
|
||||
Select as SelectBase,
|
||||
SelectContent,
|
||||
|
@ -113,26 +113,3 @@ SelectItemSelector.displayName = 'SelectItemSelector';
|
|||
const SelectItemSecondaryText: React.FC<{ children: React.ReactNode }> = ({ children }) => {
|
||||
return <span className="text-gray-light text2xs">{children}</span>;
|
||||
};
|
||||
|
||||
const ExampleUsage = () => {
|
||||
const [value, setValue] = useState<string>('');
|
||||
const values: SelectItem<'1' | '2'>[] = [
|
||||
{
|
||||
value: '1',
|
||||
label: '1'
|
||||
},
|
||||
{
|
||||
value: '2',
|
||||
label: '2'
|
||||
}
|
||||
];
|
||||
|
||||
return (
|
||||
<Select
|
||||
items={values}
|
||||
onChange={(v) => {
|
||||
console.log(v);
|
||||
}}
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue