@awsui/components-react
Version:
AWS UI is a collection of [React](https://reactjs.org/) components that help create intuitive, responsive, and accessible user experiences for web applications. It is developed by Amazon Web Services (AWS). This work is available under the terms of the [A
37 lines (36 loc) • 1.55 kB
TypeScript
import { NonCancelableEventHandler } from '../internal/events';
import { TutorialPanelProps } from '../tutorial-panel';
export interface AnnotationContextProps {
currentTutorial: AnnotationContextProps.Tutorial | null;
onStepChange?: NonCancelableEventHandler<AnnotationContextProps.StepChangeDetail>;
onStartTutorial: NonCancelableEventHandler<TutorialPanelProps.TutorialDetail>;
onExitTutorial: NonCancelableEventHandler<TutorialPanelProps.TutorialDetail>;
onFinish?: NonCancelableEventHandler<void>;
children: React.ReactNode;
announcementPopoverHeader?: string;
announcementPopoverBody?: string;
onDismissAnnouncementPopover?: NonCancelableEventHandler<void>;
i18nStrings: AnnotationContextProps.I18nStrings;
}
export declare namespace AnnotationContextProps {
interface StepChangeDetail {
step: number;
reason: 'next' | 'previous' | 'open' | 'auto-fallback';
}
interface OpenChangeDetail {
open: boolean;
}
type Task = TutorialPanelProps.Task;
type Step = TutorialPanelProps.Step;
type Tutorial = TutorialPanelProps.Tutorial;
interface I18nStrings {
nextButtonText: string;
previousButtonText: string;
finishButtonText: string;
labelDismissAnnotation: string;
labelHotspot: (openState: boolean) => string;
labelDismissAnnouncementPopover: string;
stepCounterText: (stepIndex: number, totalStepCount: number) => string;
taskTitle: (taskIndex: number, taskTitle: string) => string;
}
}