From: Matthias Schmidt Date: Tue, 22 Dec 2020 12:59:57 +0000 (+0100) Subject: Add `IPatternFormField` X-Git-Tag: 5.4.0_Alpha_1~515^2~8 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=dab5ee08b06ad397e6c0c82f2fb09358873a0fc3;p=GitHub%2FWoltLab%2FWCF.git Add `IPatternFormField` --- diff --git a/wcfsetup/install/files/lib/system/form/builder/field/IPatternFormField.class.php b/wcfsetup/install/files/lib/system/form/builder/field/IPatternFormField.class.php new file mode 100644 index 0000000000..577e221dcc --- /dev/null +++ b/wcfsetup/install/files/lib/system/form/builder/field/IPatternFormField.class.php @@ -0,0 +1,28 @@ + + * @package WoltLabSuite\Core\System\Form\Builder\Field + * @see https://html.spec.whatwg.org/multipage/input.html#attr-input-pattern + * @since 5.4 + */ +interface IPatternFormField { + /** + * Returns the `pattern` attribute of the form field. + * + * If `null` is returned, no `pattern` attribute will be set. + */ + public function getPattern(): ?string; + + /** + * Sets the `pattern` attribute of the form field. + * + * If `null` is given, the attribute is unset. + */ + public function pattern(?string $pattern): self; +}