@wikimedia/wvui
Version:
Wikimedia Vue UI (WVUI) – Wikimedia Foundation's Vue.js shared user-interface components for Wikipedia, MediaWiki, and beyond.
97 lines (96 loc) • 3.56 kB
TypeScript
import Vue from 'vue';
declare const _default: import("vue").ComponentOptions<Vue, import("@vue/composition-api").ShallowUnwrapRef<{
rootClasses: import("@vue/composition-api").ComputedRef<Record<string, boolean>>;
input: import("@vue/composition-api").Ref<HTMLInputElement | undefined>;
focusInput: () => void;
wrappedModel: import("@vue/composition-api").WritableComputedRef<import("../../composables/useModelWrapper").ModelValue>;
}> & import("@vue/composition-api").Data, {}, {}, {
/**
* Value provided by v-model in a parent component.
*
* Rather than directly binding a value prop to this component, use
* v-model to bind a string, number, or boolean value. This value
* represents the value of the radio input that is currently on.
*/
modelValue: {
type: (StringConstructor | BooleanConstructor | NumberConstructor | ArrayConstructor)[];
default: boolean;
};
/**
* HTML "value" attribute to assign to the input.
*
* Required for input groups.
*/
inputValue: {
type: (StringConstructor | BooleanConstructor | NumberConstructor)[];
default: boolean;
};
/**
* Whether the disabled attribute should be added to the input.
*/
disabled: {
type: BooleanConstructor;
default: boolean;
};
/**
* HTML "name" attribute to assign to the input.
*
* Required for input groups
*/
name: {
type: StringConstructor;
default: string;
};
/**
* Whether the component should display inline.
*
* By default, `display: block` is set and a margin exists between
* sibling components, for a stacked layout.
*/
inline: {
type: BooleanConstructor;
default: boolean;
};
}, {
name: string;
modelValue: import("../../composables/useModelWrapper").ModelValue;
inputValue: string | number | boolean;
disabled: boolean;
inline: boolean;
} & {}> & import("vue").VueConstructor<Vue> & (new (...args: any[]) => import("@vue/composition-api").ComponentRenderProxy<{
name: string;
modelValue: import("../../composables/useModelWrapper").ModelValue;
inputValue: string | number | boolean;
disabled: boolean;
inline: boolean;
} & {}, import("@vue/composition-api").ShallowUnwrapRef<{
rootClasses: import("@vue/composition-api").ComputedRef<Record<string, boolean>>;
input: import("@vue/composition-api").Ref<HTMLInputElement | undefined>;
focusInput: () => void;
wrappedModel: import("@vue/composition-api").WritableComputedRef<import("../../composables/useModelWrapper").ModelValue>;
}>, import("@vue/composition-api").Data, {}, {}, {
name: string;
modelValue: import("../../composables/useModelWrapper").ModelValue;
inputValue: string | number | boolean;
disabled: boolean;
inline: boolean;
} & {}, {
name: string;
modelValue: import("../../composables/useModelWrapper").ModelValue;
inputValue: string | number | boolean;
disabled: boolean;
inline: boolean;
}, true>);
/**
* A binary input that always exists in a group, in which only one input can be
* on at a time.
*
* Typical use will involve using v-for to loop through an array of items and
* output a Radio component for each one. Each Radio will have the same v-model
* and name props, but different inputValue props and label content.
*
* The v-model value is the inputValue of the Radio that is currently on.
*
* @fires {Event} input
*/
export default _default;