From: Matthias Schmidt Date: Wed, 23 Dec 2020 14:46:40 +0000 (+0100) Subject: Add field attribute support for `UserPasswordField` X-Git-Tag: 5.4.0_Alpha_1~507^2~5 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=6bb9a1c5c01e47958f7ca2c2b525e3a5b7869c40;p=GitHub%2FWoltLab%2FWCF.git Add field attribute support for `UserPasswordField` --- diff --git a/com.woltlab.wcf/templates/__userPasswordFormField.tpl b/com.woltlab.wcf/templates/__userPasswordFormField.tpl index a0a4594f1b..9eebaa0cc2 100644 --- a/com.woltlab.wcf/templates/__userPasswordFormField.tpl +++ b/com.woltlab.wcf/templates/__userPasswordFormField.tpl @@ -8,4 +8,5 @@ *}{if $field->isRequired()} required{/if}{* *}{if $field->getPlaceholder() !== null} placeholder="{$field->getPlaceholder()}"{/if}{* *}{if $field->getDocument()->isAjax()} data-dialog-submit-on-enter="true"{/if}{* + *}{foreach from=$field->getFieldAttributes() key='attributeName' item='attributeValue'} {$attributeName}="{$attributeValue}"{/foreach}{* *}> diff --git a/wcfsetup/install/files/acp/templates/__userPasswordFormField.tpl b/wcfsetup/install/files/acp/templates/__userPasswordFormField.tpl index a0a4594f1b..9eebaa0cc2 100644 --- a/wcfsetup/install/files/acp/templates/__userPasswordFormField.tpl +++ b/wcfsetup/install/files/acp/templates/__userPasswordFormField.tpl @@ -8,4 +8,5 @@ *}{if $field->isRequired()} required{/if}{* *}{if $field->getPlaceholder() !== null} placeholder="{$field->getPlaceholder()}"{/if}{* *}{if $field->getDocument()->isAjax()} data-dialog-submit-on-enter="true"{/if}{* + *}{foreach from=$field->getFieldAttributes() key='attributeName' item='attributeValue'} {$attributeName}="{$attributeValue}"{/foreach}{* *}> diff --git a/wcfsetup/install/files/lib/system/form/builder/field/user/UserPasswordField.class.php b/wcfsetup/install/files/lib/system/form/builder/field/user/UserPasswordField.class.php index 669b068b55..1e9dd4625c 100644 --- a/wcfsetup/install/files/lib/system/form/builder/field/user/UserPasswordField.class.php +++ b/wcfsetup/install/files/lib/system/form/builder/field/user/UserPasswordField.class.php @@ -1,12 +1,14 @@