This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// sketch-systems like statechart description | |
// docusign | |
// start* | |
// SELECT_DOCUMENT -> detailspane | |
// detailspane | |
// is_versioned* | |
// -> versioned; isVersioned | |
// -> unversioned; isNotVersioned | |
// versioned |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// sketch-systems like statechart description | |
// docusign | |
// detailspane* | |
// is_versioned* | |
// -> versioned; isVersioned | |
// -> unversioned; isNotVersioned | |
// versioned | |
// CLICK_SIGN_BUTTON -> #docusign.modal | |
// unversioned |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Docusign | |
Detailspane* | |
Check versioned or not? | |
is versioned? -> Versioned | |
is not versioned? -> Unversioned | |
Versioned | |
Click sign button -> Modal | |
Unversioned | |
click enable versioning -> Versioned | |
Modal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Phone Number section | |
Add phone number | |
Add button disabled* | |
input phone number -> Check phone input | |
Add button enabled | |
input phone number -> Check phone input | |
click add -> Verify phone number | |
Check phone input | |
input empty? -> Add button disabled | |
input not empty? -> Add button enabled |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# chat model | |
Chat | |
No chats | |
new chat arrival -> chats loaded | |
chats loaded*& | |
selection state | |
nothing selected | |
conv selected | |
no dialogs open | |
delete dialog open |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// grammar for custom text based language to describe statecharts | |
{ | |
var INDENT_STEP = 2; | |
var indentLevel = 0; | |
function arrayOfObjToObj(arr) { | |
return arr.reduce((acc, item) => ({...acc, ...item}), {}) | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Chat | |
check conv count | |
conv count 0 -> no chats | |
* -> chats loaded | |
no chats | |
new chat arrival -> chats loaded | |
chats loaded*& | |
# transient state to select type of active conv | |
check active conv type | |
is normal conv -> active conv for normal ad |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const nameList = ['Rithwik', 'Mukesh']; | |
function matches(ctx, e) { | |
return nameList.some(name => name.toLowerCase().includes(ctx.text.toLowerCase())) | |
} | |
function doesNotMatch(ctx, e) { | |
return !matches(ctx) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Chat model | |
function someConvSelected(context) { | |
return context.selected_conv_count > 0; | |
} | |
function noConvSelected(context) { | |
return !someConvSelected(context); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions |
NewerOlder