mirror of
https://github.com/primefaces/primevue.git
synced 2025-05-10 17:32:36 +00:00
Refactor #5426 - For MultiSelect
This commit is contained in:
parent
d79ef6767d
commit
89e01ffe77
3 changed files with 34 additions and 38 deletions
34
components/lib/multiselect/MultiSelect.d.ts
vendored
34
components/lib/multiselect/MultiSelect.d.ts
vendored
|
@ -9,8 +9,9 @@
|
|||
*/
|
||||
import { ButtonHTMLAttributes, HTMLAttributes, InputHTMLAttributes, TransitionProps, VNode } from 'vue';
|
||||
import { ComponentHooks } from '../basecomponent';
|
||||
import { InputTextPassThroughOptions } from '../inputtext';
|
||||
import { PassThroughOptions } from '../passthrough';
|
||||
import { ClassComponent, GlobalComponentConstructor, PassThrough, HintedString } from '../ts-helpers';
|
||||
import { ClassComponent, GlobalComponentConstructor, HintedString, PassThrough } from '../ts-helpers';
|
||||
import { VirtualScrollerItemOptions, VirtualScrollerPassThroughOptionType, VirtualScrollerProps } from '../virtualscroller';
|
||||
|
||||
export declare type MultiSelectPassThroughOptionType = MultiSelectPassThroughAttributes | ((options: MultiSelectPassThroughMethodOptions) => MultiSelectPassThroughAttributes | string) | string | null | undefined;
|
||||
|
@ -51,6 +52,20 @@ export interface MultiSelectPassThroughMethodOptions {
|
|||
global: object | undefined;
|
||||
}
|
||||
|
||||
/**
|
||||
* Custom shared passthrough(pt) option method.
|
||||
*/
|
||||
export interface MultiSelectSharedPassThroughMethodOptions {
|
||||
/**
|
||||
* Defines valid properties.
|
||||
*/
|
||||
props: MultiSelectProps;
|
||||
/**
|
||||
* Defines current inline state.
|
||||
*/
|
||||
state: MultiSelectState;
|
||||
}
|
||||
|
||||
/**
|
||||
* Custom change event.
|
||||
* @see {@link MultiSelectEmits.change}
|
||||
|
@ -154,21 +169,14 @@ export interface MultiSelectPassThroughOptions {
|
|||
*/
|
||||
filterContainer?: MultiSelectPassThroughOptionType;
|
||||
/**
|
||||
* Used to pass attributes to the filter input's DOM element.
|
||||
* Used to pass attributes to the InputText component.
|
||||
* @see {@link InputTextPassThroughOptions}
|
||||
*/
|
||||
filterInput?: MultiSelectPassThroughOptionType;
|
||||
filterInput?: InputTextPassThroughOptions<MultiSelectSharedPassThroughMethodOptions>;
|
||||
/**
|
||||
* Used to pass attributes to the filter icon's DOM element.
|
||||
*/
|
||||
filterIcon?: MultiSelectPassThroughOptionType;
|
||||
/**
|
||||
* Used to pass attributes to the close button's DOM element.
|
||||
*/
|
||||
closeButton?: MultiSelectPassThroughOptionType;
|
||||
/**
|
||||
* Used to pass attributes to the close icon's DOM element.
|
||||
*/
|
||||
closeIcon?: MultiSelectPassThroughOptionType;
|
||||
/**
|
||||
* Used to pass attributes to the wrapper's DOM element.
|
||||
*/
|
||||
|
@ -255,7 +263,7 @@ export interface MultiSelectState {
|
|||
focused: boolean;
|
||||
/**
|
||||
* Current focused item index as a number.
|
||||
* @defaultvalue -1
|
||||
* @defaultValue -1
|
||||
*/
|
||||
focusedOptionIndex: number;
|
||||
/**
|
||||
|
@ -299,7 +307,7 @@ export interface MultiSelectProps {
|
|||
*/
|
||||
modelValue?: any;
|
||||
/**
|
||||
* An array of selectitems to display as the available options.
|
||||
* An array of select items to display as the available options.
|
||||
*/
|
||||
options?: any[] | undefined;
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue