mirror of
https://github.com/supabase/supabase.git
synced 2026-10-08 10:55:06 +03:00
changed to ui package and added selected param
This commit is contained in:
1 parent
8cc5f19d9e
commit
30dd26e816
1 file changed
+4
-4
@@ -1,10 +1,10 @@
|
||||
import { Select } from '@supabase/ui'
|
||||
import { Select } from 'ui'
|
||||
import { EditorProps } from '@supabase/react-data-grid'
|
||||
|
||||
import { useTrackedState } from 'components/grid/store'
|
||||
|
||||
interface SelectEditorProps<TRow, TSummaryRow = unknown> extends EditorProps<TRow, TSummaryRow> {
|
||||
options: { label: string; value: string }[]
|
||||
options: { label: string; _value: string }[]
|
||||
}
|
||||
|
||||
export function SelectEditor<TRow, TSummaryRow = unknown>({
|
||||
@@ -45,8 +45,8 @@ export function SelectEditor<TRow, TSummaryRow = unknown>({
|
||||
onBlur={onBlur}
|
||||
>
|
||||
<Select.Option value="">NULL</Select.Option>
|
||||
{options.map(({ label, value }) => (
|
||||
<Select.Option key={value} value={value}>
|
||||
{options.map(({ label, _value }) => (
|
||||
<Select.Option key={_value} value={_value} selected={_value === value}>
|
||||
{label}
|
||||
</Select.Option>
|
||||
))}
|
||||
|
||||
Reference in new issue
Block a user