"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.PasswordBoxStories = void 0;
const jsx_runtime_1 = require("react/jsx-runtime");
// also exported from '@storybook/react' if you can deal with breaking changes in 6.1
const FormConfiguration_1 = require("../../FormConfiguration");
const FormRuntime_1 = require("../../FormRuntime");
const PasswordFormControl_1 = require("../Web/PasswordFormControl");
const Containers_1 = require("../../Containers");
const FormDesignConstants_1 = require("../../Utilities/FormDesignConstants");
const StoryData_1 = require("../../../CommonUI/StoryBook/StoryData");
function getUI() {
    let ui = new FormConfiguration_1.FormConfiguration();
    let container = new Containers_1.XStackContainer();
    ui.add(container);
    let textField = new PasswordFormControl_1.PasswordFormControl();
    textField.label = "Text Field Label";
    textField.valueName = "value";
    textField.requiredOnAllOutcomes = false;
    container.add(textField);
    return { form: ui, control: textField };
}
exports.PasswordBoxStories = [
    new StoryData_1.StoryNode(() => {
        let ui = getUI();
        return (0, jsx_runtime_1.jsx)(FormRuntime_1.FormRuntime, { form: ui.form });
    }, "Form Designer", "Controls", "Password Box", "Default"),
    new StoryData_1.StoryNode(() => {
        let ui = getUI();
        ui.control.confirmPasswordRequired = true;
        return (0, jsx_runtime_1.jsx)(FormRuntime_1.FormRuntime, { form: ui.form });
    }, "Form Designer", "Controls", "Password Box", "With Confirm"),
    new StoryData_1.StoryNode(() => {
        let ui = getUI();
        ui.control.confirmPasswordRequired = true;
        ui.control.overrideStyle = true;
        ui.control.style = FormDesignConstants_1.TextControlStyle.OUTLINE;
        return (0, jsx_runtime_1.jsx)(FormRuntime_1.FormRuntime, { form: ui.form });
    }, "Form Designer", "Controls", "Password Box", "Outline"),
    new StoryData_1.StoryNode(() => {
        let ui = getUI();
        ui.control.confirmPasswordRequired = true;
        ui.control.overrideStyle = true;
        ui.control.style = FormDesignConstants_1.TextControlStyle.SHADED;
        return (0, jsx_runtime_1.jsx)(FormRuntime_1.FormRuntime, { form: ui.form });
    }, "Form Designer", "Controls", "Password Box", "Shaded"),
    new StoryData_1.StoryNode(() => {
        let ui = getUI();
        ui.control.confirmPasswordRequired = true;
        ui.control.overrideStyle = true;
        ui.control.style = FormDesignConstants_1.TextControlStyle.LABELED;
        return (0, jsx_runtime_1.jsx)(FormRuntime_1.FormRuntime, { form: ui.form });
    }, "Form Designer", "Controls", "Password Box", "Labeled"),
    new StoryData_1.StoryNode(() => {
        let ui = getUI();
        ui.control.confirmPasswordRequired = true;
        ui.control.overrideStyle = true;
        ui.control.style = FormDesignConstants_1.TextControlStyle.UNDERLINED;
        return (0, jsx_runtime_1.jsx)(FormRuntime_1.FormRuntime, { form: ui.form });
    }, "Form Designer", "Controls", "Password Box", "Underlined"),
    new StoryData_1.StoryNode(() => {
        let ui = getUI();
        ui.control.confirmPasswordRequired = true;
        ui.control.overrideStyle = true;
        ui.control.style = FormDesignConstants_1.TextControlStyle.UNDERLINED;
        ui.control.confirmPassword = "abc";
        return (0, jsx_runtime_1.jsx)(FormRuntime_1.FormRuntime, { form: ui.form });
    }, "Form Designer", "Controls", "Password Box", "Unmatched Confirm Password ?? - Review"),
];
//# sourceMappingURL=XPasswordBox-stories.js.map