mirror of
https://github.com/CommunityOx/ox_lib.git
synced 2026-08-18 23:46:03 +01:00
feat(web/select): searchable option (#513)
This commit is contained in:
@@ -63,6 +63,7 @@ interface SelectProps extends BaseInput {
|
|||||||
disabled?: boolean;
|
disabled?: boolean;
|
||||||
default?: string | string[];
|
default?: string | string[];
|
||||||
clearable?: boolean;
|
clearable?: boolean;
|
||||||
|
searchable?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
interface SliderProps extends BaseInput {
|
interface SliderProps extends BaseInput {
|
||||||
|
|||||||
@@ -19,6 +19,7 @@ local input
|
|||||||
---@field format? string
|
---@field format? string
|
||||||
---@field returnString? boolean
|
---@field returnString? boolean
|
||||||
---@field clearable? boolean
|
---@field clearable? boolean
|
||||||
|
---@field searchable? boolean
|
||||||
---@field description? string
|
---@field description? string
|
||||||
|
|
||||||
---@class InputDialogOptionsProps
|
---@class InputDialogOptionsProps
|
||||||
|
|||||||
@@ -32,6 +32,7 @@ const SelectField: React.FC<Props> = (props) => {
|
|||||||
description={props.row.description}
|
description={props.row.description}
|
||||||
withAsterisk={props.row.required}
|
withAsterisk={props.row.required}
|
||||||
clearable={props.row.clearable}
|
clearable={props.row.clearable}
|
||||||
|
searchable={props.row.searchable}
|
||||||
icon={props.row.icon && <LibIcon icon={props.row.icon} fixedWidth />}
|
icon={props.row.icon && <LibIcon icon={props.row.icon} fixedWidth />}
|
||||||
/>
|
/>
|
||||||
) : (
|
) : (
|
||||||
@@ -49,6 +50,7 @@ const SelectField: React.FC<Props> = (props) => {
|
|||||||
description={props.row.description}
|
description={props.row.description}
|
||||||
withAsterisk={props.row.required}
|
withAsterisk={props.row.required}
|
||||||
clearable={props.row.clearable}
|
clearable={props.row.clearable}
|
||||||
|
searchable={props.row.searchable}
|
||||||
icon={props.row.icon && <LibIcon icon={props.row.icon} fixedWidth />}
|
icon={props.row.icon && <LibIcon icon={props.row.icon} fixedWidth />}
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
|
|||||||
@@ -37,6 +37,7 @@ export type OptionValue = { value: string; label?: string };
|
|||||||
export interface ISelect extends BaseField<'select' | 'multi-select', string | string[]> {
|
export interface ISelect extends BaseField<'select' | 'multi-select', string | string[]> {
|
||||||
options: Array<OptionValue>;
|
options: Array<OptionValue>;
|
||||||
clearable?: boolean;
|
clearable?: boolean;
|
||||||
|
searchable?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface INumber extends BaseField<'number', number> {
|
export interface INumber extends BaseField<'number', number> {
|
||||||
|
|||||||
Reference in New Issue
Block a user