import { ControlInput } from '../../controls/ControlInput'; import { AplContent, QuestionnaireControl } from './QuestionnaireControl'; export declare namespace QuestionnaireControlAPLPropsBuiltIns { interface QuestionnaireChoice { ordinalText: string; selectedText: string; color: string; selectedIndex: number; } interface QuestionnaireControlAPLContent { caption: string; questionCaptions: string[]; choices: QuestionnaireChoice[]; } interface DefaultAskQuestionProps { /** * Default: 'Please answer the following..' */ title?: string; /** * Default (en-*): 'Submit >' */ submitButtonText?: string; /** * Default: '' */ subtitle?: string; /** * Whether debug information is displayed * * Default: false */ debug?: boolean; /** * Whether the Radio buttons have blocking behavior. * * *Default: true* * * When true, all UI buttons are disabled (blocked) until processing of preceding * radio button press is complete. If the processing takes significant time, a * busy indicator is shown. * * Purpose: * * Alexa does not serialize UserEvents and so there is a risk of UserEvents * racing if the user presses multiple buttons in quick succession, where "quick * succession" means "significantly faster than the UserEvent round-trip * processing latency". Racing UserEvents can cause dropped state and/or * out-of-order event processing. This property provides the option to use * client-side-blocking to avoid the risks and costs of UserEvent races at the * expense of disabling and re-enabling the user input buttons. * * Pros and cons of blocking behavior: * * Pros: the user-interface is disabled which prevents users pressing more * buttons until the server is ready to accept them. This removes the * possibility of race-conditions. * * Cons: causes the input elements to be disabled (shown in grey and inactive) * for a short duration which may be distracting to the user. * * When to use? * * Consider using this if the latency for a UserEvent round trip is high, e.g. * greater than 400ms. * * Consider using this if the cost of dropped inputs is high compared to the UI * friction of disabling/enabling buttons. * * Additional notes: * * The Done button always uses blocking behavior. */ radioButtonPressesBlockUI?: boolean; } function DefaultAskQuestion(props: DefaultAskQuestionProps): (control: QuestionnaireControl, input: ControlInput) => AplContent; /** * The APL dataSource to use when requesting a value * * Default: A TextListLayout data source to bind to an APL document. * See * https://developer.amazon.com/en-US/docs/alexa/alexa-presentation-language/apl-data-source.html */ function questionnaireDataSourceGenerator(control: QuestionnaireControl, input: ControlInput, contentProps: DefaultAskQuestionProps): { wrapper: { general: { controlId: string; dataVersion: number; radioButtonSize: string; buttonColumnWidth: string; headerTitle: string | undefined; headerSubtitle: string; headerBackButton: boolean; nextButtonText: string | undefined; debug: boolean; }; questionData: { primaryText: string | ((control: QuestionnaireControl, input: ControlInput) => string); questionId: string; selectedIndex: string | number; }[]; }; }; } //# sourceMappingURL=QuestionnaireControlBuiltIns.d.ts.map