@empathyco/x-components
Version:
Empathy X Components
90 lines • 2.91 kB
TypeScript
import type { PropType } from 'vue';
import type { VueCSSClasses } from '../utils/types';
/**
* This component allows for any other component or element inside it to be horizontally
* navigable. It also implements customizable buttons as well as other minor customizations to its
* general behavior.
*
* Additionally, this component exposes the following props to modify the classes of the
* elements: `buttonClass`.
*
* @public
*/
declare const _default: import("vue").DefineComponent<{
/**
* Scroll factor that will dictate how much the scroll moves when pressing a navigation button.
*/
scrollFactor: {
type: NumberConstructor;
default: number;
};
/** Would make the navigation buttons visible when they're needed or always hide them. */
showButtons: {
type: BooleanConstructor;
default: boolean;
};
/**
* When true, whenever the DOM content in the sliding panel slot changes, it will reset
* the scroll position to 0.
*/
resetOnContentChange: {
type: BooleanConstructor;
default: boolean;
};
buttonClass: {
type: PropType<VueCSSClasses>;
};
scrollContainerClass: {
type: PropType<VueCSSClasses>;
};
}, {
arrivedState: {
left: boolean;
right: boolean;
top: boolean;
bottom: boolean;
};
cssClasses: import("vue").ComputedRef<{
'x-sliding-panel-at-start': boolean;
'x-sliding-panel-at-end': boolean;
}>;
scrollContainerRef: import("vue").Ref<HTMLDivElement | undefined>;
slotContainerWidth: import("vue").Ref<number>;
xScroll: import("vue").WritableComputedRef<number>;
slots: Readonly<{
[name: string]: import("vue").Slot<any> | undefined;
}>;
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
/**
* Scroll factor that will dictate how much the scroll moves when pressing a navigation button.
*/
scrollFactor: {
type: NumberConstructor;
default: number;
};
/** Would make the navigation buttons visible when they're needed or always hide them. */
showButtons: {
type: BooleanConstructor;
default: boolean;
};
/**
* When true, whenever the DOM content in the sliding panel slot changes, it will reset
* the scroll position to 0.
*/
resetOnContentChange: {
type: BooleanConstructor;
default: boolean;
};
buttonClass: {
type: PropType<VueCSSClasses>;
};
scrollContainerClass: {
type: PropType<VueCSSClasses>;
};
}>>, {
scrollFactor: number;
showButtons: boolean;
resetOnContentChange: boolean;
}, {}>;
export default _default;
//# sourceMappingURL=sliding-panel.vue?vue&type=script&lang.d.ts.map