@nextcloud/vue
Version:
Nextcloud vue components
244 lines (243 loc) • 8.5 kB
TypeScript
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
/**
* The text of the label element of the select group input
*/
label: {
type: StringConstructor;
required: true;
};
/**
* Placeholder for the input element
* For backwards compatibility it falls back to the `label` value
*/
placeholder: {
type: StringConstructor;
default: string;
};
/**
* id attribute of the select group element
*/
id: {
type: StringConstructor;
default: () => string;
validator: (id: unknown) => boolean;
};
/**
* value of the select group input
* A list of group IDs can be provided
*/
modelValue: {
type: ArrayConstructor;
default: () => never[];
};
/**
* disabled state of the settings select group input
*/
disabled: {
type: BooleanConstructor;
default: boolean;
};
}>, {}, {
/** Temporary store to cache groups */
groups: {};
randId: string;
errorMessage: string;
}, {
/**
* If the error message should be shown
*/
hasError(): boolean;
/**
* Validate input value and only return valid strings (group IDs)
*
* @return {string[]}
*/
filteredValue(): string[];
/**
* value property converted to an array of group objects used as input for the NcSelect
*/
inputValue(): any[];
/**
* Convert groups object to array of groups required for NcSelect.options
* Filter out currently selected values
*
* @return {object[]}
*/
groupsArray(): object[];
}, {
t: (original: string, placeholders?: Record<string, string | number>) => string;
/**
* Called when a new group is selected or previous group is deselected to emit the update event
*
* @param {object[]} updatedValue Array of selected groups
*/
update(updatedValue: object[]): void;
/**
* Use provisioning API to search for given group and save it in the groups object
*
* @param {string} query The query like parts of the id oder display name
* @return {boolean}
*/
loadGroup(query: string): boolean;
/**
* Custom filter function for `NcSelect` to filter by ID *and* display name
*
* @param {object} option One of the groups
* @param {string} label The label property of the group
* @param {string} search The current search string
*/
filterGroups(option: object, label: string, search: string): boolean;
/**
* Debounce the group search (reduce API calls)
*/
onSearch: import('debounce').DebouncedFunction<(query: any) => void>;
}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, ("input" | "error" | "update:modelValue")[], "input" | "error" | "update:modelValue", import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
/**
* The text of the label element of the select group input
*/
label: {
type: StringConstructor;
required: true;
};
/**
* Placeholder for the input element
* For backwards compatibility it falls back to the `label` value
*/
placeholder: {
type: StringConstructor;
default: string;
};
/**
* id attribute of the select group element
*/
id: {
type: StringConstructor;
default: () => string;
validator: (id: unknown) => boolean;
};
/**
* value of the select group input
* A list of group IDs can be provided
*/
modelValue: {
type: ArrayConstructor;
default: () => never[];
};
/**
* disabled state of the settings select group input
*/
disabled: {
type: BooleanConstructor;
default: boolean;
};
}>> & Readonly<{
onInput?: ((...args: any[]) => any) | undefined;
onError?: ((...args: any[]) => any) | undefined;
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
}>, {
id: string;
disabled: boolean;
placeholder: string;
modelValue: unknown[];
}, {}, {
NcSelect: import('vue').DefineComponent<{}, {
avatarSize: number;
isLegacy: boolean;
}, {
search: string;
}, {
inputRequired(): any;
localCalculatePosition(): any;
localFilterBy(): any;
localLabel(): any;
propsToForward(): any;
}, {
t: (original: string, placeholders?: Record<string, string | number>) => string;
}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, (" " | "update:modelValue")[], " " | "update:modelValue", import('vue').PublicProps, Readonly<{}> & Readonly<{
"on "?: ((...args: any[]) => any) | undefined;
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
}>, {} | {
[x: string]: any;
}, {}, {
ChevronDown: any;
NcEllipsisedOption: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
name: {
type: StringConstructor;
default: string;
};
search: {
type: StringConstructor;
default: string;
};
}>, {}, {}, {
needsTruncate(): boolean | "";
split(): number;
part1(): string;
part2(): string;
highlight1(): any[];
highlight2(): any[];
}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
name: {
type: StringConstructor;
default: string;
};
search: {
type: StringConstructor;
default: string;
};
}>> & Readonly<{}>, {
name: string;
search: string;
}, {}, {
NcHighlight: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
text: {
type: StringConstructor;
default: string;
};
search: {
type: StringConstructor;
default: string;
};
highlight: {
type: import('vue').PropType<import('../../utils/findRanges.ts').StringRange[]>;
default: () => never[];
};
}>, {}, {}, {
ranges(): import('../../utils/findRanges.ts').StringRange[];
chunks(): import('../NcHighlight/NcHighlight.vue').HighlightChunk[];
}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
text: {
type: StringConstructor;
default: string;
};
search: {
type: StringConstructor;
default: string;
};
highlight: {
type: import('vue').PropType<import('../../utils/findRanges.ts').StringRange[]>;
default: () => never[];
};
}>> & Readonly<{}>, {
search: string;
text: string;
highlight: import('../../utils/findRanges.ts').StringRange[];
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
NcLoadingIcon: import('vue').DefineComponent<{
appearance?: "auto" | "light" | "dark";
name?: string;
size?: number;
}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{
appearance?: "auto" | "light" | "dark";
name?: string;
size?: number;
}> & Readonly<{}>, {
size: number;
name: string;
appearance: "auto" | "light" | "dark";
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLSpanElement>;
VueSelect: any;
}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
export default _default;