"use strict";
var __importStar = (this && this.__importStar) || function (mod) {
    if (mod && mod.__esModule) return mod;
    var result = {};
    if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
    result["default"] = mod;
    return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
var React = __importStar(require("react"));
var icons_1 = require("../icons");
var Button_1 = require("../Button");
var input_1 = require("../input");
var EmailStyledComponents_1 = require("./EmailStyledComponents");
exports.EmailSignup = function (props) {
    var SignUpButton = (React.createElement(Button_1.Button, { size: Button_1.buttonSizes.SMALL, onClick: props.onSubmit }, !!props.isRequestPending ? "Saving" : "Sign Up"));
    var email = props.email, errorMessage = props.errorMessage;
    return (React.createElement(EmailStyledComponents_1.StyledEmailSignupContainer, null,
        React.createElement(EmailStyledComponents_1.StyledEmailSignupTitle, null,
            React.createElement(icons_1.BellIcon, null),
            " Get the Civil Registry Alerts"),
        React.createElement(EmailStyledComponents_1.StyledEmailSignupCopy, null, "Receive real-time email alerts when a new event occurs on the Civil Registry. These events include new applications, challenges, when voting begins / ends and more. By subscribing, you'll ensure you have maximum time to make decisions about how you will participate in Civil's governance."),
        React.createElement(input_1.InputGroup, { append: SignUpButton, noAppendPadding: true, noLabel: true, placeholder: "Email address", onChange: props.onChange, name: "EmailSignupTextInput", type: "text", value: email, invalid: !!errorMessage, invalidMessage: errorMessage }),
        React.createElement(EmailStyledComponents_1.StyledEmailSignupCopy, null,
            React.createElement("b", null,
                "Follow us on twitter for alerts",
                " ",
                React.createElement("a", { href: "https://twitter.com/civil_alerts", target: "_blank" }, "@Civil_Alerts")))));
};
//# sourceMappingURL=EmailSignup.js.map