"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ExpressionViewLogicStories = void 0;
const jsx_runtime_1 = require("react/jsx-runtime");
const ExpressionView_1 = require("../Builder/ExpressionView");
const LogicData_1 = require("../Testing/LogicData");
const ExpressionData_1 = require("../Testing/ExpressionData");
const DataTestData_1 = require("@appglue/common/dist/Common/Data/DataTestData");
const StoryData_1 = require("../../CommonUI/StoryBook/StoryData");
exports.ExpressionViewLogicStories = [
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getLogicExpression)();
        exp.inputData = ExpressionData_1.expressionStoryData;
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Then"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getLogicExpression)();
        exp.expression.showElseAsDefault = true;
        exp.inputData = ExpressionData_1.expressionStoryData;
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Then Default"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getLogicExpressionElseIf)();
        exp.inputData = ExpressionData_1.expressionStoryData;
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Then Else If"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getLogicExpressionElseIf)();
        exp.inputData = ExpressionData_1.expressionStoryData;
        exp.expression.thenText = "Bonus Paid Is";
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Then Else If Replaced Then"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getLogicExpressionElseIf)();
        exp.inputData = ExpressionData_1.expressionStoryData;
        exp.expression.showElseAsDefault = true;
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Then Else If Default"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getLogicExpressionElseIf)();
        exp.inputData = ExpressionData_1.expressionStoryData;
        exp.expression.showElseAsDefault = true;
        exp.expression.thenText = "company pays";
        exp.expression.defaultText = "everyone else gets";
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Then Else If Default If"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getLogicExpressionElseIfElseWithSub)();
        exp.inputData = ExpressionData_1.expressionStoryData;
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Then Else If With Sub"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getLogicExpressionElseIfElseWithSubWithBlanks)();
        exp.inputData = ExpressionData_1.expressionStoryData;
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Then Else If Sub With Blanks"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getLogicExpressionResultAtEnd)();
        exp.inputData = ExpressionData_1.expressionStoryData;
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Then Results At End"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getLogicExpressionResultElseIfAtEnd)();
        exp.inputData = ExpressionData_1.expressionStoryData;
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Then Else If Results At End"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getIfSimpleRule)();
        exp.inputData = ExpressionData_1.expressionStoryData;
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Simple Rule"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getIfSimpleRule)();
        exp.inputData = ExpressionData_1.expressionStoryData;
        exp.expression.showSimpleReturn = false;
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Simple Rule No Return"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getIfElseSimpleRule)();
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Else Simple Rule"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getIfElseSimpleRule)();
        exp.expression.showSimpleReturn = false;
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If Else Simple Rule No Return"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getExistsSimpleRule)();
        exp.inputData = () => {
            return (0, DataTestData_1.getFilledDataDefinition)();
        };
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "Exists Read Only"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.getExistsSimpleRule)();
        exp.inputData = (0, DataTestData_1.getFilledDataDefinition)();
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "Exists Writable"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.isFalseSimpleRule)();
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If False Simple Rule"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.isTrueSimpleRule)();
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "If True Simple Rule"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.lessThanSimpleRule)();
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "Less Than"),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.lessThanEqualToSimpleRule)();
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "Less Than Equal To "),
    new StoryData_1.StoryNode(() => {
        let exp = (0, LogicData_1.notSimpleRule)();
        return (0, jsx_runtime_1.jsx)(ExpressionView_1.ExpressionView, { expression: exp });
    }, "Expression Builder", "Expression View", "Logic", "Not"),
];
//# sourceMappingURL=ExpressionView.Logic-stories.js.map