UNPKG

@uva-glass/component-library

Version:

React components UvA

44 lines (43 loc) 1.27 kB
import { jsx as t } from "react/jsx-runtime"; import { fn as i } from "../../index-DXR-TB1d.js"; import { FormInput as a } from "./FormInput.js"; import { SelectListbox as o } from "../SelectListbox/SelectListbox.js"; const m = ` // Has all HTMLInputElement props available except "className" and "style" <FormInput /> `, f = { title: "Organisms/FormInput", component: a, argTypes: {}, args: {}, parameters: { inspectComponent: a, codeString: m } }, r = (e) => /* @__PURE__ */ t(a, { ...e }), p = r.bind({}); p.args = { id: "vak", label: "Vaknaam (NL)", labelPosition: "left", required: !0, onChange: i() }; const u = r.bind({}), l = [ { label: "English", value: "EN" }, { label: "Dutch", value: "NL" }, { label: "German", value: "DE" }, { label: "Danish", value: "DK" } ]; u.args = { id: "language", label: "Language", labelPosition: "left", required: !0, customInput: /* @__PURE__ */ t(o, { options: l, defaultValue: "NL", size: "medium", children: l.map(({ label: e, value: n }, s) => /* @__PURE__ */ t(o.SelectOption, { option: { label: e, value: n }, index: s, children: e }, n)) }) }; export { p as FromInputExample, u as WithCustomInputExample, f as default }; //# sourceMappingURL=FormInput.stories.js.map