@cognigy/rest-api-client
Version:
Cognigy REST-Client
28 lines • 841 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.RESET_STATE = void 0;
/* Custom modules */
const createNodeDescriptor_1 = require("../../createNodeDescriptor");
/**
* Node name: 'resetState'
*
* Purpose:
* Resets the state of the current brain to default
*/
exports.RESET_STATE = (0, createNodeDescriptor_1.createNodeDescriptor)({
type: "resetState",
defaultLabel: "Reset State",
summary: "UI__NODE_EDITOR__RESET_STATE__SUMMARY",
appearance: {
showIcon: false
},
fields: [],
tags: ["logic"],
function: async ({ cognigy }) => {
const { api, input } = cognigy;
const state = await api.resetState();
input.state = state;
api.logDebugMessage(`UI__DEBUG_MODE__RESET_STATE__MESSAGE`);
}
});
//# sourceMappingURL=resetState.js.map