"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.withError = exports.readonly = exports.disabled = exports.preselectedValue = exports.defaultState = void 0;
const react_1 = __importDefault(require("react"));
const addon_knobs_1 = require("@storybook/addon-knobs");
const storybook_utilities_1 = require("../../storybook-utilities");
const Select_1 = require("./Select");
const meta = {
    component: Select_1.Select,
    title: 'checkout-web-ui/Select',
    decorators: [addon_knobs_1.withKnobs, storybook_utilities_1.themeWithKnobs('select')],
};
exports.default = meta;
const defaultProps = {
    label: 'Country',
    options: [
        {
            value: 'CA',
            label: 'Canada',
        },
        {
            value: 'US',
            label: 'United States',
        },
        {
            value: 'UK',
            label: 'United Kingdom',
        },
    ],
};
exports.defaultState = () => <Select_1.Select {...defaultProps}/>;
exports.preselectedValue = () => <Select_1.Select {...defaultProps} value="UK"/>;
exports.disabled = () => <Select_1.Select {...defaultProps} disabled/>;
exports.readonly = () => <Select_1.Select {...defaultProps} readonly/>;
exports.withError = () => (<Select_1.Select {...defaultProps} error="Select a country"/>);
