primeng
Version:
PrimeNG is a premium UI library for Angular featuring a rich set of 90+ components, a theme designer, various theme alternatives such as Material, Bootstrap, Tailwind, premium templates and professional support. In addition, it integrates with PrimeBlock,
187 lines (184 loc) • 6 kB
TypeScript
import { MotionOptions } from '@primeuix/motion';
import { PassThrough, PassThroughOption } from 'primeng/api';
/**
* Defines valid pass-through options in Stepper component.
* @template I Type of instance.
*
* @group Interface
*/
interface StepperPassThroughOptions<I = unknown> {
/**
* Used to pass attributes to the root's DOM element.
*/
root?: PassThroughOption<HTMLElement, I>;
/**
* Used to pass options to the motion component/directive.
*/
motion?: MotionOptions;
}
/**
* Defines valid pass-through options in Stepper component.
* @see {@link StepperPassThroughOptions}
*
* @template I Type of instance.
*/
type StepperPassThrough<I = unknown> = PassThrough<I, StepperPassThroughOptions<I>>;
/**
* Defines valid pass-through options in StepList component.
* @template I Type of instance.
*
* @group Interface
*/
interface StepListPassThroughOptions<I = unknown> {
/**
* Used to pass attributes to the root's DOM element.
*/
root?: PassThroughOption<HTMLElement, I>;
}
/**
* Defines valid pass-through options in StepList component.
* @see {@link StepListPassThroughOptions}
*
* @template I Type of instance.
*/
type StepListPassThrough<I = unknown> = PassThrough<I, StepListPassThroughOptions<I>>;
/**
* Defines valid pass-through options in StepperSeparator component.
* @template I Type of instance.
*
* @group Interface
*/
interface StepperSeparatorPassThroughOptions<I = unknown> {
/**
* Used to pass attributes to the separator's DOM element.
*/
root?: PassThroughOption<HTMLElement, I>;
}
/**
* Defines valid pass-through options in StepperSeparator component.
* @see {@link StepperSeparatorPassThroughOptions}
*
* @template I Type of instance.
*/
type StepperSeparatorPassThrough<I = unknown> = PassThrough<I, StepperSeparatorPassThroughOptions<I>>;
/**
* Defines valid pass-through options in StepItem component.
* @template I Type of instance.
*
* @group Interface
*/
interface StepItemPassThroughOptions<I = unknown> {
/**
* Used to pass attributes to the root's DOM element.
*/
root?: PassThroughOption<HTMLElement, I>;
}
/**
* Defines valid pass-through options in StepItem component.
* @see {@link StepItemPassThroughOptions}
*
* @template I Type of instance.
*/
type StepItemPassThrough<I = unknown> = PassThrough<I, StepItemPassThroughOptions<I>>;
/**
* Defines valid pass-through options in Step component.
* @template I Type of instance.
*
* @group Interface
*/
interface StepPassThroughOptions<I = unknown> {
/**
* Used to pass attributes to the root's DOM element.
*/
root?: PassThroughOption<HTMLElement, I>;
/**
* Used to pass attributes to the header's DOM element.
*/
header?: PassThroughOption<HTMLButtonElement, I>;
/**
* Used to pass attributes to the number's DOM element.
*/
number?: PassThroughOption<HTMLSpanElement, I>;
/**
* Used to pass attributes to the title's DOM element.
*/
title?: PassThroughOption<HTMLSpanElement, I>;
}
/**
* Defines valid pass-through options in Step component.
* @see {@link StepPassThroughOptions}
*
* @template I Type of instance.
*/
type StepPassThrough<I = unknown> = PassThrough<I, StepPassThroughOptions<I>>;
/**
* Defines valid pass-through options in StepPanel component.
* @template I Type of instance.
*
* @group Interface
*/
interface StepPanelPassThroughOptions<I = unknown> {
/**
* Used to pass attributes to the root's DOM element.
*/
root?: PassThroughOption<HTMLElement, I>;
/**
* Used to pass attributes to the content wrapper DOM element.
*/
contentWrapper?: PassThroughOption<HTMLDivElement, I>;
/**
* Used to pass attributes to the content's DOM element.
*/
content?: PassThroughOption<HTMLDivElement, I>;
}
/**
* Defines valid pass-through options in StepPanel component.
* @see {@link StepPanelPassThroughOptions}
*
* @template I Type of instance.
*/
type StepPanelPassThrough<I = unknown> = PassThrough<I, StepPanelPassThroughOptions<I>>;
/**
* Defines valid pass-through options in StepPanels component.
* @template I Type of instance.
*
* @group Interface
*/
interface StepPanelsPassThroughOptions<I = unknown> {
/**
* Used to pass attributes to the root's DOM element.
*/
root?: PassThroughOption<HTMLElement, I>;
}
/**
* Defines valid pass-through options in StepPanels component.
* @see {@link StepPanelsPassThroughOptions}
*
* @template I Type of instance.
*/
type StepPanelsPassThrough<I = unknown> = PassThrough<I, StepPanelsPassThroughOptions<I>>;
/**
* Context interface for the StepPanel content template.
* @property {() => void} activateCallback - Callback function to activate a step.
* @property {number} value - The value associated with the step.
* @property {boolean} active - A flag indicating whether the step is active.
* @group Interface
*/
interface StepContentTemplateContext {
activateCallback: () => void;
value: number | undefined;
active: boolean;
}
/**
* Context interface for the StepPanel content template.
* @property {(index: number) => void} activateCallback - Callback function to activate a step.
* @property {number} value - The value associated with the step.
* @property {boolean} active - A flag indicating whether the step is active.
* @group Interface
*/
interface StepPanelContentTemplateContext {
activateCallback: (index: number) => void;
value: number | undefined;
active: boolean;
}
export type { StepContentTemplateContext, StepItemPassThrough, StepItemPassThroughOptions, StepListPassThrough, StepListPassThroughOptions, StepPanelContentTemplateContext, StepPanelPassThrough, StepPanelPassThroughOptions, StepPanelsPassThrough, StepPanelsPassThroughOptions, StepPassThrough, StepPassThroughOptions, StepperPassThrough, StepperPassThroughOptions, StepperSeparatorPassThrough, StepperSeparatorPassThroughOptions };