@microsoft/agents-hosting-dialogs 0.1.49
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +20 -0
- package/dist/src/agentComponent.d.ts +18 -0
- package/dist/src/agentComponent.js +55 -0
- package/dist/src/agentComponent.js.map +1 -0
- package/dist/src/agentStateSet.d.ts +48 -0
- package/dist/src/agentStateSet.js +66 -0
- package/dist/src/agentStateSet.js.map +1 -0
- package/dist/src/choices/choice.d.ts +14 -0
- package/dist/src/choices/choice.js +7 -0
- package/dist/src/choices/choice.js.map +1 -0
- package/dist/src/choices/choiceFactory.d.ts +81 -0
- package/dist/src/choices/choiceFactory.js +133 -0
- package/dist/src/choices/choiceFactory.js.map +1 -0
- package/dist/src/choices/findChoices.d.ts +28 -0
- package/dist/src/choices/findChoices.js +46 -0
- package/dist/src/choices/findChoices.js.map +1 -0
- package/dist/src/choices/findValues.d.ts +36 -0
- package/dist/src/choices/findValues.js +129 -0
- package/dist/src/choices/findValues.js.map +1 -0
- package/dist/src/choices/index.d.ts +11 -0
- package/dist/src/choices/index.js +28 -0
- package/dist/src/choices/index.js.map +1 -0
- package/dist/src/choices/modelResult.d.ts +11 -0
- package/dist/src/choices/modelResult.js +3 -0
- package/dist/src/choices/modelResult.js.map +1 -0
- package/dist/src/choices/recognizeChoices.d.ts +16 -0
- package/dist/src/choices/recognizeChoices.js +81 -0
- package/dist/src/choices/recognizeChoices.js.map +1 -0
- package/dist/src/choices/tokenizer.d.ts +25 -0
- package/dist/src/choices/tokenizer.js +73 -0
- package/dist/src/choices/tokenizer.js.map +1 -0
- package/dist/src/componentDialog.d.ts +178 -0
- package/dist/src/componentDialog.js +252 -0
- package/dist/src/componentDialog.js.map +1 -0
- package/dist/src/componentRegistration.d.ts +22 -0
- package/dist/src/componentRegistration.js +32 -0
- package/dist/src/componentRegistration.js.map +1 -0
- package/dist/src/configurable.d.ts +22 -0
- package/dist/src/configurable.js +60 -0
- package/dist/src/configurable.js.map +1 -0
- package/dist/src/configuration.d.ts +11 -0
- package/dist/src/configuration.js +17 -0
- package/dist/src/configuration.js.map +1 -0
- package/dist/src/converter.d.ts +13 -0
- package/dist/src/converter.js +7 -0
- package/dist/src/converter.js.map +1 -0
- package/dist/src/dialog.d.ts +184 -0
- package/dist/src/dialog.js +201 -0
- package/dist/src/dialog.js.map +1 -0
- package/dist/src/dialogContainer.d.ts +61 -0
- package/dist/src/dialogContainer.js +82 -0
- package/dist/src/dialogContainer.js.map +1 -0
- package/dist/src/dialogContext.d.ts +272 -0
- package/dist/src/dialogContext.js +444 -0
- package/dist/src/dialogContext.js.map +1 -0
- package/dist/src/dialogContextError.d.ts +27 -0
- package/dist/src/dialogContextError.js +39 -0
- package/dist/src/dialogContextError.js.map +1 -0
- package/dist/src/dialogEvent.d.ts +20 -0
- package/dist/src/dialogEvent.js +3 -0
- package/dist/src/dialogEvent.js.map +1 -0
- package/dist/src/dialogEvents.d.ts +15 -0
- package/dist/src/dialogEvents.js +20 -0
- package/dist/src/dialogEvents.js.map +1 -0
- package/dist/src/dialogHelper.d.ts +32 -0
- package/dist/src/dialogHelper.js +116 -0
- package/dist/src/dialogHelper.js.map +1 -0
- package/dist/src/dialogInstance.d.ts +30 -0
- package/dist/src/dialogInstance.js +3 -0
- package/dist/src/dialogInstance.js.map +1 -0
- package/dist/src/dialogManager.d.ts +73 -0
- package/dist/src/dialogManager.js +156 -0
- package/dist/src/dialogManager.js.map +1 -0
- package/dist/src/dialogReason.d.ts +35 -0
- package/dist/src/dialogReason.js +40 -0
- package/dist/src/dialogReason.js.map +1 -0
- package/dist/src/dialogSet.d.ts +85 -0
- package/dist/src/dialogSet.js +138 -0
- package/dist/src/dialogSet.js.map +1 -0
- package/dist/src/dialogTurnResult.d.ts +34 -0
- package/dist/src/dialogTurnResult.js +3 -0
- package/dist/src/dialogTurnResult.js.map +1 -0
- package/dist/src/dialogTurnStateConstants.d.ts +12 -0
- package/dist/src/dialogTurnStateConstants.js +17 -0
- package/dist/src/dialogTurnStateConstants.js.map +1 -0
- package/dist/src/dialogTurnStatus.d.ts +34 -0
- package/dist/src/dialogTurnStatus.js +39 -0
- package/dist/src/dialogTurnStatus.js.map +1 -0
- package/dist/src/dialogsAgentComponent.d.ts +17 -0
- package/dist/src/dialogsAgentComponent.js +65 -0
- package/dist/src/dialogsAgentComponent.js.map +1 -0
- package/dist/src/dialogsComponentRegistration.d.ts +28 -0
- package/dist/src/dialogsComponentRegistration.js +45 -0
- package/dist/src/dialogsComponentRegistration.js.map +1 -0
- package/dist/src/i18n.d.ts +15 -0
- package/dist/src/i18n.js +28 -0
- package/dist/src/i18n.js.map +1 -0
- package/dist/src/index.d.ts +29 -0
- package/dist/src/index.js +48 -0
- package/dist/src/index.js.map +1 -0
- package/dist/src/intentScore.d.ts +11 -0
- package/dist/src/intentScore.js +3 -0
- package/dist/src/intentScore.js.map +1 -0
- package/dist/src/memory/componentMemoryScopes.d.ts +18 -0
- package/dist/src/memory/componentMemoryScopes.js +54 -0
- package/dist/src/memory/componentMemoryScopes.js.map +1 -0
- package/dist/src/memory/componentPathResolvers.d.ts +18 -0
- package/dist/src/memory/componentPathResolvers.js +52 -0
- package/dist/src/memory/componentPathResolvers.js.map +1 -0
- package/dist/src/memory/dialogPath.d.ts +17 -0
- package/dist/src/memory/dialogPath.js +30 -0
- package/dist/src/memory/dialogPath.js.map +1 -0
- package/dist/src/memory/dialogStateManager.d.ts +156 -0
- package/dist/src/memory/dialogStateManager.js +598 -0
- package/dist/src/memory/dialogStateManager.js.map +1 -0
- package/dist/src/memory/index.d.ts +12 -0
- package/dist/src/memory/index.js +29 -0
- package/dist/src/memory/index.js.map +1 -0
- package/dist/src/memory/pathResolvers/aliasPathResolver.d.ts +25 -0
- package/dist/src/memory/pathResolvers/aliasPathResolver.js +37 -0
- package/dist/src/memory/pathResolvers/aliasPathResolver.js.map +1 -0
- package/dist/src/memory/pathResolvers/atAtPathResolver.d.ts +11 -0
- package/dist/src/memory/pathResolvers/atAtPathResolver.js +18 -0
- package/dist/src/memory/pathResolvers/atAtPathResolver.js.map +1 -0
- package/dist/src/memory/pathResolvers/atPathResolver.d.ts +20 -0
- package/dist/src/memory/pathResolvers/atPathResolver.js +46 -0
- package/dist/src/memory/pathResolvers/atPathResolver.js.map +1 -0
- package/dist/src/memory/pathResolvers/dollarPathResolver.d.ts +11 -0
- package/dist/src/memory/pathResolvers/dollarPathResolver.js +18 -0
- package/dist/src/memory/pathResolvers/dollarPathResolver.js.map +1 -0
- package/dist/src/memory/pathResolvers/hashPathResolver.d.ts +11 -0
- package/dist/src/memory/pathResolvers/hashPathResolver.js +18 -0
- package/dist/src/memory/pathResolvers/hashPathResolver.js.map +1 -0
- package/dist/src/memory/pathResolvers/index.d.ts +11 -0
- package/dist/src/memory/pathResolvers/index.js +28 -0
- package/dist/src/memory/pathResolvers/index.js.map +1 -0
- package/dist/src/memory/pathResolvers/pathResolver.d.ts +13 -0
- package/dist/src/memory/pathResolvers/pathResolver.js +7 -0
- package/dist/src/memory/pathResolvers/pathResolver.js.map +1 -0
- package/dist/src/memory/pathResolvers/percentPathResolver.d.ts +11 -0
- package/dist/src/memory/pathResolvers/percentPathResolver.js +18 -0
- package/dist/src/memory/pathResolvers/percentPathResolver.js.map +1 -0
- package/dist/src/memory/scopePath.d.ts +18 -0
- package/dist/src/memory/scopePath.js +23 -0
- package/dist/src/memory/scopePath.js.map +1 -0
- package/dist/src/memory/scopes/agentStateMemoryScope.d.ts +53 -0
- package/dist/src/memory/scopes/agentStateMemoryScope.js +82 -0
- package/dist/src/memory/scopes/agentStateMemoryScope.js.map +1 -0
- package/dist/src/memory/scopes/classMemoryScope.d.ts +29 -0
- package/dist/src/memory/scopes/classMemoryScope.js +65 -0
- package/dist/src/memory/scopes/classMemoryScope.js.map +1 -0
- package/dist/src/memory/scopes/conversationMemoryScope.d.ts +15 -0
- package/dist/src/memory/scopes/conversationMemoryScope.js +23 -0
- package/dist/src/memory/scopes/conversationMemoryScope.js.map +1 -0
- package/dist/src/memory/scopes/dialogClassMemoryScope.d.ts +19 -0
- package/dist/src/memory/scopes/dialogClassMemoryScope.js +42 -0
- package/dist/src/memory/scopes/dialogClassMemoryScope.js.map +1 -0
- package/dist/src/memory/scopes/dialogContextMemoryScope.d.ts +19 -0
- package/dist/src/memory/scopes/dialogContextMemoryScope.js +48 -0
- package/dist/src/memory/scopes/dialogContextMemoryScope.js.map +1 -0
- package/dist/src/memory/scopes/dialogMemoryScope.d.ts +32 -0
- package/dist/src/memory/scopes/dialogMemoryScope.js +74 -0
- package/dist/src/memory/scopes/dialogMemoryScope.js.map +1 -0
- package/dist/src/memory/scopes/index.d.ts +15 -0
- package/dist/src/memory/scopes/index.js +32 -0
- package/dist/src/memory/scopes/index.js.map +1 -0
- package/dist/src/memory/scopes/memoryScope.d.ts +52 -0
- package/dist/src/memory/scopes/memoryScope.js +54 -0
- package/dist/src/memory/scopes/memoryScope.js.map +1 -0
- package/dist/src/memory/scopes/settingsMemoryScope.d.ts +68 -0
- package/dist/src/memory/scopes/settingsMemoryScope.js +216 -0
- package/dist/src/memory/scopes/settingsMemoryScope.js.map +1 -0
- package/dist/src/memory/scopes/thisMemoryScope.d.ts +26 -0
- package/dist/src/memory/scopes/thisMemoryScope.js +43 -0
- package/dist/src/memory/scopes/thisMemoryScope.js.map +1 -0
- package/dist/src/memory/scopes/turnMemoryScope.d.ts +29 -0
- package/dist/src/memory/scopes/turnMemoryScope.js +52 -0
- package/dist/src/memory/scopes/turnMemoryScope.js.map +1 -0
- package/dist/src/memory/scopes/userMemoryScope.d.ts +15 -0
- package/dist/src/memory/scopes/userMemoryScope.js +23 -0
- package/dist/src/memory/scopes/userMemoryScope.js.map +1 -0
- package/dist/src/memory/turnPath.d.ts +21 -0
- package/dist/src/memory/turnPath.js +38 -0
- package/dist/src/memory/turnPath.js.map +1 -0
- package/dist/src/prompts/activityPrompt.d.ts +101 -0
- package/dist/src/prompts/activityPrompt.js +166 -0
- package/dist/src/prompts/activityPrompt.js.map +1 -0
- package/dist/src/prompts/attachmentPrompt.d.ts +37 -0
- package/dist/src/prompts/attachmentPrompt.js +55 -0
- package/dist/src/prompts/attachmentPrompt.js.map +1 -0
- package/dist/src/prompts/choicePrompt.d.ts +83 -0
- package/dist/src/prompts/choicePrompt.js +116 -0
- package/dist/src/prompts/choicePrompt.js.map +1 -0
- package/dist/src/prompts/confirmPrompt.d.ts +82 -0
- package/dist/src/prompts/confirmPrompt.js +163 -0
- package/dist/src/prompts/confirmPrompt.js.map +1 -0
- package/dist/src/prompts/datetimePrompt.d.ts +65 -0
- package/dist/src/prompts/datetimePrompt.js +109 -0
- package/dist/src/prompts/datetimePrompt.js.map +1 -0
- package/dist/src/prompts/index.d.ts +13 -0
- package/dist/src/prompts/index.js +30 -0
- package/dist/src/prompts/index.js.map +1 -0
- package/dist/src/prompts/numberPrompt.d.ts +55 -0
- package/dist/src/prompts/numberPrompt.js +134 -0
- package/dist/src/prompts/numberPrompt.js.map +1 -0
- package/dist/src/prompts/prompt.d.ts +256 -0
- package/dist/src/prompts/prompt.js +260 -0
- package/dist/src/prompts/prompt.js.map +1 -0
- package/dist/src/prompts/promptCultureModels.d.ts +72 -0
- package/dist/src/prompts/promptCultureModels.js +123 -0
- package/dist/src/prompts/promptCultureModels.js.map +1 -0
- package/dist/src/prompts/textPrompt.d.ts +54 -0
- package/dist/src/prompts/textPrompt.js +72 -0
- package/dist/src/prompts/textPrompt.js.map +1 -0
- package/dist/src/recognizer.d.ts +43 -0
- package/dist/src/recognizer.js +104 -0
- package/dist/src/recognizer.js.map +1 -0
- package/dist/src/recognizerResult.d.ts +19 -0
- package/dist/src/recognizerResult.js +24 -0
- package/dist/src/recognizerResult.js.map +1 -0
- package/dist/src/serviceCollection.d.ts +112 -0
- package/dist/src/serviceCollection.js +209 -0
- package/dist/src/serviceCollection.js.map +1 -0
- package/dist/src/stringUtils.d.ts +36 -0
- package/dist/src/stringUtils.js +62 -0
- package/dist/src/stringUtils.js.map +1 -0
- package/dist/src/template.d.ts +18 -0
- package/dist/src/template.js +7 -0
- package/dist/src/template.js.map +1 -0
- package/dist/src/waterfallDialog.d.ts +101 -0
- package/dist/src/waterfallDialog.js +179 -0
- package/dist/src/waterfallDialog.js.map +1 -0
- package/dist/src/waterfallStepContext.d.ts +71 -0
- package/dist/src/waterfallStepContext.js +78 -0
- package/dist/src/waterfallStepContext.js.map +1 -0
- package/package.json +49 -0
- package/src/agentComponent.ts +23 -0
- package/src/agentStateSet.ts +75 -0
- package/src/choices/choice.ts +16 -0
- package/src/choices/choiceFactory.ts +189 -0
- package/src/choices/findChoices.ts +70 -0
- package/src/choices/findValues.ts +179 -0
- package/src/choices/index.ts +11 -0
- package/src/choices/modelResult.ts +11 -0
- package/src/choices/recognizeChoices.ts +94 -0
- package/src/choices/tokenizer.ts +93 -0
- package/src/componentDialog.ts +306 -0
- package/src/componentRegistration.ts +30 -0
- package/src/configurable.ts +55 -0
- package/src/configuration.ts +22 -0
- package/src/converter.ts +15 -0
- package/src/dialog.ts +243 -0
- package/src/dialogContainer.ts +90 -0
- package/src/dialogContext.ts +607 -0
- package/src/dialogContextError.ts +50 -0
- package/src/dialogEvent.ts +23 -0
- package/src/dialogEvents.ts +16 -0
- package/src/dialogHelper.ts +154 -0
- package/src/dialogInstance.ts +32 -0
- package/src/dialogManager.ts +202 -0
- package/src/dialogReason.ts +40 -0
- package/src/dialogSet.ts +168 -0
- package/src/dialogTurnResult.ts +37 -0
- package/src/dialogTurnStateConstants.ts +13 -0
- package/src/dialogTurnStatus.ts +38 -0
- package/src/dialogsAgentComponent.ts +71 -0
- package/src/dialogsComponentRegistration.ts +49 -0
- package/src/i18n.ts +17 -0
- package/src/index.ts +31 -0
- package/src/intentScore.ts +11 -0
- package/src/memory/componentMemoryScopes.ts +28 -0
- package/src/memory/componentPathResolvers.ts +29 -0
- package/src/memory/dialogPath.ts +33 -0
- package/src/memory/dialogStateManager.ts +661 -0
- package/src/memory/index.ts +12 -0
- package/src/memory/pathResolvers/aliasPathResolver.ts +44 -0
- package/src/memory/pathResolvers/atAtPathResolver.ts +14 -0
- package/src/memory/pathResolvers/atPathResolver.ts +45 -0
- package/src/memory/pathResolvers/dollarPathResolver.ts +14 -0
- package/src/memory/pathResolvers/hashPathResolver.ts +14 -0
- package/src/memory/pathResolvers/index.ts +11 -0
- package/src/memory/pathResolvers/pathResolver.ts +14 -0
- package/src/memory/pathResolvers/percentPathResolver.ts +14 -0
- package/src/memory/scopePath.ts +19 -0
- package/src/memory/scopes/agentStateMemoryScope.ts +92 -0
- package/src/memory/scopes/classMemoryScope.ts +71 -0
- package/src/memory/scopes/conversationMemoryScope.ts +19 -0
- package/src/memory/scopes/dialogClassMemoryScope.ts +43 -0
- package/src/memory/scopes/dialogContextMemoryScope.ts +51 -0
- package/src/memory/scopes/dialogMemoryScope.ts +79 -0
- package/src/memory/scopes/index.ts +15 -0
- package/src/memory/scopes/memoryScope.ts +70 -0
- package/src/memory/scopes/settingsMemoryScope.ts +239 -0
- package/src/memory/scopes/thisMemoryScope.ts +44 -0
- package/src/memory/scopes/turnMemoryScope.ts +54 -0
- package/src/memory/scopes/userMemoryScope.ts +19 -0
- package/src/memory/turnPath.ts +45 -0
- package/src/prompts/activityPrompt.ts +202 -0
- package/src/prompts/attachmentPrompt.ts +62 -0
- package/src/prompts/choicePrompt.ts +176 -0
- package/src/prompts/confirmPrompt.ts +182 -0
- package/src/prompts/datetimePrompt.ts +110 -0
- package/src/prompts/index.ts +13 -0
- package/src/prompts/numberPrompt.ts +117 -0
- package/src/prompts/prompt.ts +459 -0
- package/src/prompts/promptCultureModels.ts +178 -0
- package/src/prompts/textPrompt.ts +82 -0
- package/src/recognizer.ts +127 -0
- package/src/recognizerResult.ts +37 -0
- package/src/serviceCollection.ts +305 -0
- package/src/stringUtils.ts +62 -0
- package/src/template.ts +20 -0
- package/src/waterfallDialog.ts +215 -0
- package/src/waterfallStepContext.ts +96 -0
- package/vendor/cldr-data/README.md +5 -0
- package/vendor/cldr-data/main/de/numbers.json +156 -0
- package/vendor/cldr-data/main/en/numbers.json +159 -0
- package/vendor/cldr-data/main/es/numbers.json +156 -0
- package/vendor/cldr-data/main/fr/numbers.json +157 -0
- package/vendor/cldr-data/main/ja/numbers.json +120 -0
- package/vendor/cldr-data/main/nl/numbers.json +156 -0
- package/vendor/cldr-data/main/pt/numbers.json +156 -0
- package/vendor/cldr-data/main/zh/numbers.json +214 -0
- package/vendor/cldr-data/supplemental/likelySubtags.json +1844 -0
- package/vendor/cldr-data/supplemental/numberingSystems.json +343 -0
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
import { v4 as uuidv4 } from 'uuid'
|
|
6
|
+
import { ActivityTypes } from '@microsoft/agents-hosting'
|
|
7
|
+
import { Dialog } from './dialog'
|
|
8
|
+
import { DialogContext } from './dialogContext'
|
|
9
|
+
import { WaterfallStepContext } from './waterfallStepContext'
|
|
10
|
+
import { DialogTurnResult } from './dialogTurnResult'
|
|
11
|
+
import { DialogReason } from './dialogReason'
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* Function signature of an individual waterfall step.
|
|
15
|
+
*
|
|
16
|
+
* @param O (Optional) type of dialog options passed into the step.
|
|
17
|
+
* @param WaterfallStep.step Contextual information for the current step being executed.
|
|
18
|
+
*/
|
|
19
|
+
export type WaterfallStep<O extends object = {}> = (step: WaterfallStepContext<O>) => Promise<DialogTurnResult>
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* A waterfall is a dialog that's optimized for prompting a user with a series of questions.
|
|
23
|
+
*
|
|
24
|
+
*/
|
|
25
|
+
export class WaterfallDialog<O extends object = {}> extends Dialog<O> {
|
|
26
|
+
private readonly steps: WaterfallStep<O>[]
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* Creates a new waterfall dialog containing the given array of steps.
|
|
30
|
+
*
|
|
31
|
+
* @remarks
|
|
32
|
+
* See the addstep function for details on creating a valid step function.
|
|
33
|
+
* @param dialogId Unique ID of the dialog within the component or set its being added to.
|
|
34
|
+
* @param steps (Optional) array of asynchronous waterfall step functions.
|
|
35
|
+
*/
|
|
36
|
+
constructor (dialogId: string, steps?: WaterfallStep<O>[]) {
|
|
37
|
+
super(dialogId)
|
|
38
|
+
this.steps = []
|
|
39
|
+
if (steps) {
|
|
40
|
+
this.steps = steps.slice(0)
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* Gets the dialog version, composed of the ID and number of steps.
|
|
46
|
+
*
|
|
47
|
+
* @returns Dialog version, composed of the ID and number of steps.
|
|
48
|
+
*/
|
|
49
|
+
getVersion (): string {
|
|
50
|
+
// Simply return the id + number of steps to help detect when new steps have
|
|
51
|
+
// been added to a given waterfall.
|
|
52
|
+
return `${this.id}:${this.steps.length}`
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* Adds a new step to the waterfall.
|
|
57
|
+
*
|
|
58
|
+
* @param step Asynchronous step function to call.
|
|
59
|
+
* @returns Waterfall dialog for fluent calls to `addStep()`.
|
|
60
|
+
*/
|
|
61
|
+
addStep (step: WaterfallStep<O>): this {
|
|
62
|
+
this.steps.push(step)
|
|
63
|
+
|
|
64
|
+
return this
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
/**
|
|
68
|
+
* Called when the WaterfallDialog is started and pushed onto the dialog stack.
|
|
69
|
+
*
|
|
70
|
+
* @param dialogContext The DialogContext for the current turn of conversation.
|
|
71
|
+
* @param options Optional, initial information to pass to the Dialog.
|
|
72
|
+
* @returns A Promise representing the asynchronous operation.
|
|
73
|
+
* @remarks
|
|
74
|
+
* If the task is successful, the result indicates whether the Dialog is still
|
|
75
|
+
* active after the turn has been processed by the dialog.
|
|
76
|
+
*/
|
|
77
|
+
async beginDialog (dialogContext: DialogContext, options?: O): Promise<DialogTurnResult> {
|
|
78
|
+
const state: WaterfallDialogState = dialogContext.activeDialog.state as WaterfallDialogState
|
|
79
|
+
state.options = options || {}
|
|
80
|
+
state.values = {
|
|
81
|
+
instanceId: uuidv4(),
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
// Run the first step
|
|
85
|
+
return await this.runStep(dialogContext, 0, DialogReason.beginCalled)
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
/**
|
|
89
|
+
* Called when the WaterfallDialog is _continued_, where it is the active dialog and the
|
|
90
|
+
* user replies with a new Activity.
|
|
91
|
+
*
|
|
92
|
+
* @param dialogContext The DialogContext for the current turn of conversation.
|
|
93
|
+
* @returns A Promise representing the asynchronous operation.
|
|
94
|
+
* @remarks
|
|
95
|
+
* If the task is successful, the result indicates whether the dialog is still
|
|
96
|
+
* active after the turn has been processed by the dialog. The result may also contain a
|
|
97
|
+
* return value.
|
|
98
|
+
*/
|
|
99
|
+
async continueDialog (dialogContext: DialogContext): Promise<DialogTurnResult> {
|
|
100
|
+
// Don't do anything for non-message activities
|
|
101
|
+
if (dialogContext.context.activity.type !== ActivityTypes.Message) {
|
|
102
|
+
return Dialog.EndOfTurn
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
// Run next step with the message text as the result.
|
|
106
|
+
return await this.resumeDialog(dialogContext, DialogReason.continueCalled, dialogContext.context.activity.text)
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
* Called when a child WaterfallDialog completed its turn, returning control to this dialog.
|
|
111
|
+
*
|
|
112
|
+
* @param dc The DialogContext for the current turn of the conversation.
|
|
113
|
+
* @param reason DialogReason why the dialog resumed.
|
|
114
|
+
* @param result Optional, value returned from the dialog that was called. The type
|
|
115
|
+
* of the value returned is dependent on the child dialog.
|
|
116
|
+
* @returns A Promise representing the asynchronous operation.
|
|
117
|
+
*/
|
|
118
|
+
async resumeDialog (dc: DialogContext, reason: DialogReason, result?: any): Promise<DialogTurnResult> {
|
|
119
|
+
// Increment step index and run step
|
|
120
|
+
const state: WaterfallDialogState = dc.activeDialog.state as WaterfallDialogState
|
|
121
|
+
|
|
122
|
+
return await this.runStep(dc, state.stepIndex + 1, reason, result)
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
/**
|
|
126
|
+
* Called when an individual waterfall step is being executed.
|
|
127
|
+
*
|
|
128
|
+
* @remarks
|
|
129
|
+
* SHOULD be overridden by derived class that want to add custom logging semantics.
|
|
130
|
+
*
|
|
131
|
+
* @param step Context object for the waterfall step to execute.
|
|
132
|
+
* @returns A promise with the DialogTurnResult.
|
|
133
|
+
*/
|
|
134
|
+
protected async onStep (step: WaterfallStepContext<O>): Promise<DialogTurnResult> {
|
|
135
|
+
return await this.steps[step.index](step)
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* Executes a step of the WaterfallDialog.
|
|
140
|
+
*
|
|
141
|
+
* @param dc The DialogContext for the current turn of conversation.
|
|
142
|
+
* @param index The index of the current waterfall step to execute.
|
|
143
|
+
* @param reason The DialogReason the waterfall step is being executed.
|
|
144
|
+
* @param result Optional, result returned by a dialog called in the previous waterfall step.
|
|
145
|
+
* @returns A Promise that represents the work queued to execute.
|
|
146
|
+
*/
|
|
147
|
+
protected async runStep (
|
|
148
|
+
dc: DialogContext,
|
|
149
|
+
index: number,
|
|
150
|
+
reason: DialogReason,
|
|
151
|
+
result?: any
|
|
152
|
+
): Promise<DialogTurnResult> {
|
|
153
|
+
if (index < this.steps.length) {
|
|
154
|
+
// Update persisted step index
|
|
155
|
+
const state: WaterfallDialogState = dc.activeDialog.state as WaterfallDialogState
|
|
156
|
+
state.stepIndex = index
|
|
157
|
+
|
|
158
|
+
// Create step context
|
|
159
|
+
let nextCalled = false
|
|
160
|
+
const step: WaterfallStepContext<O> = new WaterfallStepContext<O>(dc, {
|
|
161
|
+
index,
|
|
162
|
+
options: <O>state.options,
|
|
163
|
+
reason,
|
|
164
|
+
result,
|
|
165
|
+
values: state.values,
|
|
166
|
+
onNext: async (stepResult?: any): Promise<DialogTurnResult<any>> => {
|
|
167
|
+
if (nextCalled) {
|
|
168
|
+
throw new Error(
|
|
169
|
+
`WaterfallStepContext.next(): method already called for dialog and step '${this.id}[${index}]'.`
|
|
170
|
+
)
|
|
171
|
+
}
|
|
172
|
+
nextCalled = true
|
|
173
|
+
return await this.resumeDialog(dc, DialogReason.nextCalled, stepResult)
|
|
174
|
+
},
|
|
175
|
+
})
|
|
176
|
+
|
|
177
|
+
// Execute step
|
|
178
|
+
return await this.onStep(step)
|
|
179
|
+
} else {
|
|
180
|
+
// End of waterfall so just return to parent
|
|
181
|
+
return await dc.endDialog(result)
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
/**
|
|
186
|
+
* Identifies the step name by its position index.
|
|
187
|
+
*
|
|
188
|
+
* @param index Step position
|
|
189
|
+
* @returns A string that identifies the step name.
|
|
190
|
+
*/
|
|
191
|
+
private waterfallStepName (index: number): string {
|
|
192
|
+
// Log Waterfall Step event. Each event has a distinct name to hook up
|
|
193
|
+
// to the Application Insights funnel.
|
|
194
|
+
let stepName = ''
|
|
195
|
+
if (this.steps[index]) {
|
|
196
|
+
try {
|
|
197
|
+
stepName = this.steps[index].name
|
|
198
|
+
} finally {
|
|
199
|
+
if (stepName === undefined || stepName === '') {
|
|
200
|
+
stepName = 'Step' + (index + 1) + 'of' + this.steps.length
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
return stepName
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
/**
|
|
209
|
+
* @private
|
|
210
|
+
*/
|
|
211
|
+
interface WaterfallDialogState {
|
|
212
|
+
options: object;
|
|
213
|
+
stepIndex: number;
|
|
214
|
+
values: object;
|
|
215
|
+
}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
import { DialogContext } from './dialogContext'
|
|
6
|
+
import { DialogReason } from './dialogReason'
|
|
7
|
+
import { DialogTurnResult } from './dialogTurnResult'
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Values passed to the `WaterfallStepContext` constructor.
|
|
11
|
+
*/
|
|
12
|
+
export interface WaterfallStepInfo<O extends object> {
|
|
13
|
+
index: number;
|
|
14
|
+
options: O;
|
|
15
|
+
reason: DialogReason;
|
|
16
|
+
result: any;
|
|
17
|
+
values: object;
|
|
18
|
+
onNext(result?: any): Promise<DialogTurnResult>;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* Context object passed in to a `WaterfallStep`.
|
|
23
|
+
*
|
|
24
|
+
* @param O (Optional) type of options passed to the steps waterfall dialog in the call to `DialogContext.beginDialog()`.
|
|
25
|
+
*/
|
|
26
|
+
export class WaterfallStepContext<O extends object = {}> extends DialogContext {
|
|
27
|
+
private _stepInfo: WaterfallStepInfo<O>
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* Creates a new WaterfallStepContext instance.
|
|
31
|
+
*
|
|
32
|
+
* @param dialogContext The dialog context for the current turn of conversation.
|
|
33
|
+
* @param stepInfo Values to initialize the step context with.
|
|
34
|
+
*/
|
|
35
|
+
constructor (dialogContext: DialogContext, stepInfo: WaterfallStepInfo<O>) {
|
|
36
|
+
super(dialogContext.dialogs, dialogContext, { dialogStack: dialogContext.stack })
|
|
37
|
+
this._stepInfo = stepInfo
|
|
38
|
+
this.parent = dialogContext.parent
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* The index of the current waterfall step being executed.
|
|
43
|
+
*
|
|
44
|
+
* @returns The index of the current waterfall step being executed.
|
|
45
|
+
*/
|
|
46
|
+
get index (): number {
|
|
47
|
+
return this._stepInfo.index
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* Any options passed to the steps waterfall dialog when it was started with
|
|
52
|
+
* `DialogContext.beginDialog()`.
|
|
53
|
+
*
|
|
54
|
+
* @returns Any options the waterfall dialog was called with.
|
|
55
|
+
*/
|
|
56
|
+
get options (): O {
|
|
57
|
+
return this._stepInfo.options
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* The reason the waterfall step is being executed.
|
|
62
|
+
*
|
|
63
|
+
* @returns The reason the waterfall step is being executed.
|
|
64
|
+
*/
|
|
65
|
+
get reason (): DialogReason {
|
|
66
|
+
return this._stepInfo.reason
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* Results returned by a dialog or prompt that was called in the previous waterfall step.
|
|
71
|
+
*
|
|
72
|
+
* @returns The result from the previous waterfall step.
|
|
73
|
+
*/
|
|
74
|
+
get result (): any {
|
|
75
|
+
return this._stepInfo.result
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* A dictionary of values which will be persisted across all waterfall steps.
|
|
80
|
+
*
|
|
81
|
+
* @returns A dictionary of values which will be persisted across all waterfall steps.
|
|
82
|
+
*/
|
|
83
|
+
get values (): object {
|
|
84
|
+
return this._stepInfo.values
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* Skips to the next waterfall step.
|
|
89
|
+
*
|
|
90
|
+
* @param result (Optional) result to pass to the next step.
|
|
91
|
+
* @returns A promise with the DialogTurnResult.
|
|
92
|
+
*/
|
|
93
|
+
async next (result?: any): Promise<DialogTurnResult> {
|
|
94
|
+
return await this._stepInfo.onNext(result)
|
|
95
|
+
}
|
|
96
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
All content in this directory (with the exception of this README.md) is derived from the [cldr-data](https://www.npmjs.com/package/cldr-data) package.
|
|
2
|
+
|
|
3
|
+
See the [NOTICE](../../NOTICE) file for further attribution details.
|
|
4
|
+
|
|
5
|
+
We are bundling a subset of the output of this dependency to reduce the install time and size.
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
{
|
|
2
|
+
"main": {
|
|
3
|
+
"de": {
|
|
4
|
+
"identity": {
|
|
5
|
+
"version": {
|
|
6
|
+
"_number": "$Revision: 14842 $",
|
|
7
|
+
"_cldrVersion": "35.1"
|
|
8
|
+
},
|
|
9
|
+
"language": "de"
|
|
10
|
+
},
|
|
11
|
+
"numbers": {
|
|
12
|
+
"defaultNumberingSystem": "latn",
|
|
13
|
+
"otherNumberingSystems": {
|
|
14
|
+
"native": "latn"
|
|
15
|
+
},
|
|
16
|
+
"minimumGroupingDigits": "1",
|
|
17
|
+
"symbols-numberSystem-latn": {
|
|
18
|
+
"decimal": ",",
|
|
19
|
+
"group": ".",
|
|
20
|
+
"list": ";",
|
|
21
|
+
"percentSign": "%",
|
|
22
|
+
"plusSign": "+",
|
|
23
|
+
"minusSign": "-",
|
|
24
|
+
"exponential": "E",
|
|
25
|
+
"superscriptingExponent": "·",
|
|
26
|
+
"perMille": "‰",
|
|
27
|
+
"infinity": "∞",
|
|
28
|
+
"nan": "NaN",
|
|
29
|
+
"timeSeparator": ":"
|
|
30
|
+
},
|
|
31
|
+
"decimalFormats-numberSystem-latn": {
|
|
32
|
+
"standard": "#,##0.###",
|
|
33
|
+
"long": {
|
|
34
|
+
"decimalFormat": {
|
|
35
|
+
"1000-count-one": "0 Tausend",
|
|
36
|
+
"1000-count-other": "0 Tausend",
|
|
37
|
+
"10000-count-one": "00 Tausend",
|
|
38
|
+
"10000-count-other": "00 Tausend",
|
|
39
|
+
"100000-count-one": "000 Tausend",
|
|
40
|
+
"100000-count-other": "000 Tausend",
|
|
41
|
+
"1000000-count-one": "0 Million",
|
|
42
|
+
"1000000-count-other": "0 Millionen",
|
|
43
|
+
"10000000-count-one": "00 Millionen",
|
|
44
|
+
"10000000-count-other": "00 Millionen",
|
|
45
|
+
"100000000-count-one": "000 Millionen",
|
|
46
|
+
"100000000-count-other": "000 Millionen",
|
|
47
|
+
"1000000000-count-one": "0 Milliarde",
|
|
48
|
+
"1000000000-count-other": "0 Milliarden",
|
|
49
|
+
"10000000000-count-one": "00 Milliarden",
|
|
50
|
+
"10000000000-count-other": "00 Milliarden",
|
|
51
|
+
"100000000000-count-one": "000 Milliarden",
|
|
52
|
+
"100000000000-count-other": "000 Milliarden",
|
|
53
|
+
"1000000000000-count-one": "0 Billion",
|
|
54
|
+
"1000000000000-count-other": "0 Billionen",
|
|
55
|
+
"10000000000000-count-one": "00 Billionen",
|
|
56
|
+
"10000000000000-count-other": "00 Billionen",
|
|
57
|
+
"100000000000000-count-one": "000 Billionen",
|
|
58
|
+
"100000000000000-count-other": "000 Billionen"
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
"short": {
|
|
62
|
+
"decimalFormat": {
|
|
63
|
+
"1000-count-one": "0",
|
|
64
|
+
"1000-count-other": "0",
|
|
65
|
+
"10000-count-one": "0",
|
|
66
|
+
"10000-count-other": "0",
|
|
67
|
+
"100000-count-one": "0",
|
|
68
|
+
"100000-count-other": "0",
|
|
69
|
+
"1000000-count-one": "0 Mio'.'",
|
|
70
|
+
"1000000-count-other": "0 Mio'.'",
|
|
71
|
+
"10000000-count-one": "00 Mio'.'",
|
|
72
|
+
"10000000-count-other": "00 Mio'.'",
|
|
73
|
+
"100000000-count-one": "000 Mio'.'",
|
|
74
|
+
"100000000-count-other": "000 Mio'.'",
|
|
75
|
+
"1000000000-count-one": "0 Mrd'.'",
|
|
76
|
+
"1000000000-count-other": "0 Mrd'.'",
|
|
77
|
+
"10000000000-count-one": "00 Mrd'.'",
|
|
78
|
+
"10000000000-count-other": "00 Mrd'.'",
|
|
79
|
+
"100000000000-count-one": "000 Mrd'.'",
|
|
80
|
+
"100000000000-count-other": "000 Mrd'.'",
|
|
81
|
+
"1000000000000-count-one": "0 Bio'.'",
|
|
82
|
+
"1000000000000-count-other": "0 Bio'.'",
|
|
83
|
+
"10000000000000-count-one": "00 Bio'.'",
|
|
84
|
+
"10000000000000-count-other": "00 Bio'.'",
|
|
85
|
+
"100000000000000-count-one": "000 Bio'.'",
|
|
86
|
+
"100000000000000-count-other": "000 Bio'.'"
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
"scientificFormats-numberSystem-latn": {
|
|
91
|
+
"standard": "#E0"
|
|
92
|
+
},
|
|
93
|
+
"percentFormats-numberSystem-latn": {
|
|
94
|
+
"standard": "#,##0 %"
|
|
95
|
+
},
|
|
96
|
+
"currencyFormats-numberSystem-latn": {
|
|
97
|
+
"currencySpacing": {
|
|
98
|
+
"beforeCurrency": {
|
|
99
|
+
"currencyMatch": "[:^S:]",
|
|
100
|
+
"surroundingMatch": "[:digit:]",
|
|
101
|
+
"insertBetween": " "
|
|
102
|
+
},
|
|
103
|
+
"afterCurrency": {
|
|
104
|
+
"currencyMatch": "[:^S:]",
|
|
105
|
+
"surroundingMatch": "[:digit:]",
|
|
106
|
+
"insertBetween": " "
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
"standard": "#,##0.00 ¤",
|
|
110
|
+
"accounting": "#,##0.00 ¤",
|
|
111
|
+
"short": {
|
|
112
|
+
"standard": {
|
|
113
|
+
"1000-count-one": "0",
|
|
114
|
+
"1000-count-other": "0",
|
|
115
|
+
"10000-count-one": "0",
|
|
116
|
+
"10000-count-other": "0",
|
|
117
|
+
"100000-count-one": "0",
|
|
118
|
+
"100000-count-other": "0",
|
|
119
|
+
"1000000-count-one": "0 Mio'.' ¤",
|
|
120
|
+
"1000000-count-other": "0 Mio'.' ¤",
|
|
121
|
+
"10000000-count-one": "00 Mio'.' ¤",
|
|
122
|
+
"10000000-count-other": "00 Mio'.' ¤",
|
|
123
|
+
"100000000-count-one": "000 Mio'.' ¤",
|
|
124
|
+
"100000000-count-other": "000 Mio'.' ¤",
|
|
125
|
+
"1000000000-count-one": "0 Mrd'.' ¤",
|
|
126
|
+
"1000000000-count-other": "0 Mrd'.' ¤",
|
|
127
|
+
"10000000000-count-one": "00 Mrd'.' ¤",
|
|
128
|
+
"10000000000-count-other": "00 Mrd'.' ¤",
|
|
129
|
+
"100000000000-count-one": "000 Mrd'.' ¤",
|
|
130
|
+
"100000000000-count-other": "000 Mrd'.' ¤",
|
|
131
|
+
"1000000000000-count-one": "0 Bio'.' ¤",
|
|
132
|
+
"1000000000000-count-other": "0 Bio'.' ¤",
|
|
133
|
+
"10000000000000-count-one": "00 Bio'.' ¤",
|
|
134
|
+
"10000000000000-count-other": "00 Bio'.' ¤",
|
|
135
|
+
"100000000000000-count-one": "000 Bio'.' ¤",
|
|
136
|
+
"100000000000000-count-other": "000 Bio'.' ¤"
|
|
137
|
+
}
|
|
138
|
+
},
|
|
139
|
+
"unitPattern-count-one": "{0} {1}",
|
|
140
|
+
"unitPattern-count-other": "{0} {1}"
|
|
141
|
+
},
|
|
142
|
+
"miscPatterns-numberSystem-latn": {
|
|
143
|
+
"approximately": "≈{0}",
|
|
144
|
+
"atLeast": "{0}+",
|
|
145
|
+
"atMost": "≤{0}",
|
|
146
|
+
"range": "{0}–{1}"
|
|
147
|
+
},
|
|
148
|
+
"minimalPairs": {
|
|
149
|
+
"pluralMinimalPairs-count-one": "{0} Tag",
|
|
150
|
+
"pluralMinimalPairs-count-other": "{0} Tage",
|
|
151
|
+
"other": "{0}. Abzweigung nach rechts nehmen"
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
}
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
{
|
|
2
|
+
"main": {
|
|
3
|
+
"en": {
|
|
4
|
+
"identity": {
|
|
5
|
+
"version": {
|
|
6
|
+
"_number": "$Revision: 14865 $",
|
|
7
|
+
"_cldrVersion": "35.1"
|
|
8
|
+
},
|
|
9
|
+
"language": "en"
|
|
10
|
+
},
|
|
11
|
+
"numbers": {
|
|
12
|
+
"defaultNumberingSystem": "latn",
|
|
13
|
+
"otherNumberingSystems": {
|
|
14
|
+
"native": "latn"
|
|
15
|
+
},
|
|
16
|
+
"minimumGroupingDigits": "1",
|
|
17
|
+
"symbols-numberSystem-latn": {
|
|
18
|
+
"decimal": ".",
|
|
19
|
+
"group": ",",
|
|
20
|
+
"list": ";",
|
|
21
|
+
"percentSign": "%",
|
|
22
|
+
"plusSign": "+",
|
|
23
|
+
"minusSign": "-",
|
|
24
|
+
"exponential": "E",
|
|
25
|
+
"superscriptingExponent": "×",
|
|
26
|
+
"perMille": "‰",
|
|
27
|
+
"infinity": "∞",
|
|
28
|
+
"nan": "NaN",
|
|
29
|
+
"timeSeparator": ":"
|
|
30
|
+
},
|
|
31
|
+
"decimalFormats-numberSystem-latn": {
|
|
32
|
+
"standard": "#,##0.###",
|
|
33
|
+
"long": {
|
|
34
|
+
"decimalFormat": {
|
|
35
|
+
"1000-count-one": "0 thousand",
|
|
36
|
+
"1000-count-other": "0 thousand",
|
|
37
|
+
"10000-count-one": "00 thousand",
|
|
38
|
+
"10000-count-other": "00 thousand",
|
|
39
|
+
"100000-count-one": "000 thousand",
|
|
40
|
+
"100000-count-other": "000 thousand",
|
|
41
|
+
"1000000-count-one": "0 million",
|
|
42
|
+
"1000000-count-other": "0 million",
|
|
43
|
+
"10000000-count-one": "00 million",
|
|
44
|
+
"10000000-count-other": "00 million",
|
|
45
|
+
"100000000-count-one": "000 million",
|
|
46
|
+
"100000000-count-other": "000 million",
|
|
47
|
+
"1000000000-count-one": "0 billion",
|
|
48
|
+
"1000000000-count-other": "0 billion",
|
|
49
|
+
"10000000000-count-one": "00 billion",
|
|
50
|
+
"10000000000-count-other": "00 billion",
|
|
51
|
+
"100000000000-count-one": "000 billion",
|
|
52
|
+
"100000000000-count-other": "000 billion",
|
|
53
|
+
"1000000000000-count-one": "0 trillion",
|
|
54
|
+
"1000000000000-count-other": "0 trillion",
|
|
55
|
+
"10000000000000-count-one": "00 trillion",
|
|
56
|
+
"10000000000000-count-other": "00 trillion",
|
|
57
|
+
"100000000000000-count-one": "000 trillion",
|
|
58
|
+
"100000000000000-count-other": "000 trillion"
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
"short": {
|
|
62
|
+
"decimalFormat": {
|
|
63
|
+
"1000-count-one": "0K",
|
|
64
|
+
"1000-count-other": "0K",
|
|
65
|
+
"10000-count-one": "00K",
|
|
66
|
+
"10000-count-other": "00K",
|
|
67
|
+
"100000-count-one": "000K",
|
|
68
|
+
"100000-count-other": "000K",
|
|
69
|
+
"1000000-count-one": "0M",
|
|
70
|
+
"1000000-count-other": "0M",
|
|
71
|
+
"10000000-count-one": "00M",
|
|
72
|
+
"10000000-count-other": "00M",
|
|
73
|
+
"100000000-count-one": "000M",
|
|
74
|
+
"100000000-count-other": "000M",
|
|
75
|
+
"1000000000-count-one": "0B",
|
|
76
|
+
"1000000000-count-other": "0B",
|
|
77
|
+
"10000000000-count-one": "00B",
|
|
78
|
+
"10000000000-count-other": "00B",
|
|
79
|
+
"100000000000-count-one": "000B",
|
|
80
|
+
"100000000000-count-other": "000B",
|
|
81
|
+
"1000000000000-count-one": "0T",
|
|
82
|
+
"1000000000000-count-other": "0T",
|
|
83
|
+
"10000000000000-count-one": "00T",
|
|
84
|
+
"10000000000000-count-other": "00T",
|
|
85
|
+
"100000000000000-count-one": "000T",
|
|
86
|
+
"100000000000000-count-other": "000T"
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
"scientificFormats-numberSystem-latn": {
|
|
91
|
+
"standard": "#E0"
|
|
92
|
+
},
|
|
93
|
+
"percentFormats-numberSystem-latn": {
|
|
94
|
+
"standard": "#,##0%"
|
|
95
|
+
},
|
|
96
|
+
"currencyFormats-numberSystem-latn": {
|
|
97
|
+
"currencySpacing": {
|
|
98
|
+
"beforeCurrency": {
|
|
99
|
+
"currencyMatch": "[:^S:]",
|
|
100
|
+
"surroundingMatch": "[:digit:]",
|
|
101
|
+
"insertBetween": " "
|
|
102
|
+
},
|
|
103
|
+
"afterCurrency": {
|
|
104
|
+
"currencyMatch": "[:^S:]",
|
|
105
|
+
"surroundingMatch": "[:digit:]",
|
|
106
|
+
"insertBetween": " "
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
"standard": "¤#,##0.00",
|
|
110
|
+
"accounting": "¤#,##0.00;(¤#,##0.00)",
|
|
111
|
+
"short": {
|
|
112
|
+
"standard": {
|
|
113
|
+
"1000-count-one": "¤0K",
|
|
114
|
+
"1000-count-other": "¤0K",
|
|
115
|
+
"10000-count-one": "¤00K",
|
|
116
|
+
"10000-count-other": "¤00K",
|
|
117
|
+
"100000-count-one": "¤000K",
|
|
118
|
+
"100000-count-other": "¤000K",
|
|
119
|
+
"1000000-count-one": "¤0M",
|
|
120
|
+
"1000000-count-other": "¤0M",
|
|
121
|
+
"10000000-count-one": "¤00M",
|
|
122
|
+
"10000000-count-other": "¤00M",
|
|
123
|
+
"100000000-count-one": "¤000M",
|
|
124
|
+
"100000000-count-other": "¤000M",
|
|
125
|
+
"1000000000-count-one": "¤0B",
|
|
126
|
+
"1000000000-count-other": "¤0B",
|
|
127
|
+
"10000000000-count-one": "¤00B",
|
|
128
|
+
"10000000000-count-other": "¤00B",
|
|
129
|
+
"100000000000-count-one": "¤000B",
|
|
130
|
+
"100000000000-count-other": "¤000B",
|
|
131
|
+
"1000000000000-count-one": "¤0T",
|
|
132
|
+
"1000000000000-count-other": "¤0T",
|
|
133
|
+
"10000000000000-count-one": "¤00T",
|
|
134
|
+
"10000000000000-count-other": "¤00T",
|
|
135
|
+
"100000000000000-count-one": "¤000T",
|
|
136
|
+
"100000000000000-count-other": "¤000T"
|
|
137
|
+
}
|
|
138
|
+
},
|
|
139
|
+
"unitPattern-count-one": "{0} {1}",
|
|
140
|
+
"unitPattern-count-other": "{0} {1}"
|
|
141
|
+
},
|
|
142
|
+
"miscPatterns-numberSystem-latn": {
|
|
143
|
+
"approximately": "~{0}",
|
|
144
|
+
"atLeast": "{0}+",
|
|
145
|
+
"atMost": "≤{0}",
|
|
146
|
+
"range": "{0}–{1}"
|
|
147
|
+
},
|
|
148
|
+
"minimalPairs": {
|
|
149
|
+
"pluralMinimalPairs-count-one": "{0} day",
|
|
150
|
+
"pluralMinimalPairs-count-other": "{0} days",
|
|
151
|
+
"few": "Take the {0}rd right.",
|
|
152
|
+
"one": "Take the {0}st right.",
|
|
153
|
+
"other": "Take the {0}th right.",
|
|
154
|
+
"two": "Take the {0}nd right."
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
}
|