UNPKG

@open-formulieren/formio-builder

Version:

An opinionated Formio webform builder for Open Forms

17 lines (16 loc) 1.1 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const jsx_runtime_1 = require("react/jsx-runtime"); const react_intl_1 = require("react-intl"); const formio_1 = require("../../formio"); /* * The description contains additional useful information/hints for a given field to * clarify what's expected by the end-user filling out the form. */ const RegexValidation = () => { const intl = (0, react_intl_1.useIntl)(); const tooltip = intl.formatMessage({ id: "wZ99FU", defaultMessage: [{ type: 0, value: "The regular expression pattern test that the field value must pass before the form can be submitted." }] }); const placeholder = intl.formatMessage({ id: "+q3LGC", defaultMessage: [{ type: 0, value: "Regular Expression Pattern" }] }); return ((0, jsx_runtime_1.jsx)(formio_1.TextField, { name: "validate.pattern", label: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: '1WxO/D', defaultMessage: [{ type: 0, value: "Regular Expression Pattern" }] }), tooltip: tooltip, placeholder: placeholder })); }; exports.default = RegexValidation;