You've already forked authentication-service
mirror of
https://github.com/matrix-org/matrix-authentication-service.git
synced 2025-07-29 22:01:14 +03:00
Support the autocorrect and autocapitalize attributes in the field macro
This commit is contained in:
@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
#}
|
||||
|
||||
{% macro input(label, name, type="text", form_state=false, autocomplete=false, class="", inputmode="text") %}
|
||||
{% macro input(label, name, type="text", form_state=false, autocomplete=false, class="", inputmode="text", autocorrect=false, autocapitalize=false) %}
|
||||
{% if not form_state %}
|
||||
{% set form_state = dict(errors=[], fields=dict()) %}
|
||||
{% endif %}
|
||||
@ -37,6 +37,8 @@ limitations under the License.
|
||||
inputmode="{{ inputmode }}"
|
||||
{% if autocomplete %} autocomplete="{{ autocomplete }}" {% endif %}
|
||||
{% if state.value %} value="{{ state.value }}" {% endif %}
|
||||
{% if autocorrect %} autocorrect="{{ autocorrect }}" {% endif %}
|
||||
{% if autocapitalize %} autocapitalize="{{ autocapitalize }}" {% endif %}
|
||||
/>
|
||||
|
||||
{% if state.errors is not empty %}
|
||||
|
Reference in New Issue
Block a user