ngx-ui-builder
Version:
Angular - Render component ui with configurations
43 lines (42 loc) • 1.29 kB
TypeScript
import { FormGroup } from '@angular/forms';
export interface NubStepConfig {
/** formGroup child name */
name: string;
/** Step title name */
title?: string;
/** Step container */
component: any;
/** CSS class for container */
class?: string;
/** CSS class for step */
stepClass?: string;
/** Provide step name that current step depends on */
dependsOn?: string | string[];
}
export interface NubStepperConfig {
id?: string | number;
/** Stepper's caption */
caption?: string;
/** Setup position for step header */
stepPosition?: 'top' | 'bottom' | 'left' | 'right';
/** CSS class for stepper */
class?: string;
/** CSS class for stepper's cover */
coverClass?: string;
/** Config customs information for what you want, and you can access from step of stepper */
metadata?: any;
/** Config default step base on index or step name */
defaultStep?: string | number;
/** Config enable linear step */
isLinear?: boolean;
/** List step definitions */
stepOptions: NubStepConfig[];
/** Provide reactive form for step */
formGroup: FormGroup;
/** Footer configs */
footer?: {
class?: string;
backTitle?: string;
nextTitle?: string;
};
}